simpler init, added fllback (classic)
This commit is contained in:
parent
eb5a1c189f
commit
a62bf7ea4c
27
app.classic.js
Normal file
27
app.classic.js
Normal file
@ -0,0 +1,27 @@
|
||||
import 'https://js.boxcast.com/v3.min.js';
|
||||
|
||||
const Channels = {
|
||||
Basics: "sfz7ja3rlpoous6usu8a",
|
||||
Sunday: "gzahmhugrzogttfdtbjj",
|
||||
Dev: "r3os2zfdnhlquhuypgtp"
|
||||
};
|
||||
|
||||
const Player = boxcast("#boxcast");
|
||||
Player.loadChannel(Channels.Basics,
|
||||
{
|
||||
showTitle: true,
|
||||
showDescription: true,
|
||||
showRelated: true,
|
||||
showDocuments: true,
|
||||
showIndex :true,
|
||||
showDonations: false,
|
||||
showCountdown: true,
|
||||
relatedBroadcastsQuery:
|
||||
{
|
||||
s: "starts_at",
|
||||
l: 100,
|
||||
q: "timeframe:next starts_at:[2022-04-01T00:00:00 TO 2022-06-01T00:00:00]"
|
||||
},
|
||||
autoplay: true,
|
||||
defaultVideo: "next",
|
||||
});
|
7
app.js
7
app.js
@ -424,5 +424,8 @@ const DateParse = (inDateString) =>
|
||||
return obj;
|
||||
};
|
||||
|
||||
/** @type {(inChannel:string, inSelector:string)=>void} */
|
||||
export default (inChannel, inSelector) => createRoot(document.querySelector(inSelector)).render(h(App, {channel:inChannel, interval:5000}));
|
||||
/** @type {(inChannel:string, inSelector:string, inInterval:number)=>void} */
|
||||
const Init = (inChannel, inSelector, inInterval) => createRoot(document.querySelector(inSelector)).render(h(App, {channel:inChannel, interval:inInterval}));
|
||||
|
||||
const Channel = { Basics: "sfz7ja3rlpoous6usu8a", Sunday: "gzahmhugrzogttfdtbjj", Dev: "r3os2zfdnhlquhuypgtp" };
|
||||
Init(Channel.Basics, "#boxcast", 5000);
|
@ -8,9 +8,7 @@
|
||||
<div style="max-width:1100px; margin: 0 auto;">
|
||||
<div id="boxcast"></div>
|
||||
<script type="module">
|
||||
import Init from "./app.js";
|
||||
const Channel = { Basics: "sfz7ja3rlpoous6usu8a", Sunday: "gzahmhugrzogttfdtbjj", Dev: "r3os2zfdnhlquhuypgtp" };
|
||||
Init(Channel.Basics, "#boxcast");
|
||||
import "./app.js";
|
||||
</script>
|
||||
</div>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user