@opendesign-plus-test/components 0.0.1-rc.21 → 0.0.1-rc.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-OElCookieNotice.cjs.js +1 -1
- package/dist/chunk-OElCookieNotice.es.js +428 -137
- package/dist/components/OBanner.vue.d.ts +10 -1
- package/dist/components/OFooter.vue.d.ts +1 -1
- package/dist/components/OHeaderSearch.vue.d.ts +4 -4
- package/dist/components/activity/OActivityApproval.vue.d.ts +277 -0
- package/dist/components/activity/OActivityForm.vue.d.ts +140 -0
- package/dist/components/activity/OMyActivityCalendar.vue.d.ts +2 -0
- package/dist/components/activity/config.d.ts +15 -0
- package/dist/components/activity/data.d.ts +51 -0
- package/dist/components/activity/index.d.ts +332 -0
- package/dist/components/activity/types.d.ts +72 -0
- package/dist/components/meeting/OMeetingCalendar.vue.d.ts +309 -0
- package/dist/components/meeting/OMeetingForm.vue.d.ts +156 -0
- package/dist/components/meeting/OMyMeetingCalendar.vue.d.ts +582 -0
- package/dist/components/meeting/OSigMeetingCalendar.vue.d.ts +24 -0
- package/dist/components/meeting/components/OMeetingCalendarList.vue.d.ts +27 -0
- package/dist/components/meeting/components/OMeetingCalendarSelector.vue.d.ts +664 -0
- package/dist/components/meeting/components/OMeetingDetail.vue.d.ts +12 -0
- package/dist/components/meeting/components/OMeetingPlaybackSubtitles.vue.d.ts +5 -0
- package/dist/components/meeting/components/OMeetingPlaybackVideo.vue.d.ts +17 -0
- package/dist/components/meeting/components/OSigMeetingAside.vue.d.ts +16 -0
- package/dist/components/meeting/config.d.ts +27 -0
- package/dist/components/meeting/types.d.ts +140 -0
- package/dist/components/meeting/utils.d.ts +21 -0
- package/dist/components.cjs.js +224 -3
- package/dist/components.css +1 -1
- package/dist/components.es.js +43019 -2293
- package/dist/index.d.ts +2 -0
- package/package.json +6 -3
- package/scripts/generate-components-index.js +4 -0
- package/src/assets/meeting/svg-icons/icon-all.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-backward.svg +4 -0
- package/src/assets/meeting/svg-icons/icon-calendar.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-cancel.svg +4 -0
- package/src/assets/meeting/svg-icons/icon-captions.svg +4 -0
- package/src/assets/meeting/svg-icons/icon-close-captions.svg +6 -0
- package/src/assets/meeting/svg-icons/icon-close-fullscreen.svg +6 -0
- package/src/assets/meeting/svg-icons/icon-copy.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-create.svg +5 -0
- package/src/assets/meeting/svg-icons/icon-delete.svg +7 -0
- package/src/assets/meeting/svg-icons/icon-empty.svg +31 -0
- package/src/assets/meeting/svg-icons/icon-empty_dark.svg +49 -0
- package/src/assets/meeting/svg-icons/icon-event.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-export.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-forward.svg +4 -0
- package/src/assets/meeting/svg-icons/icon-fullscreen.svg +6 -0
- package/src/assets/meeting/svg-icons/icon-help.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-important.svg +4 -0
- package/src/assets/meeting/svg-icons/icon-info.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-meet.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-meeting-message.svg +5 -0
- package/src/assets/meeting/svg-icons/icon-meeting.svg +4 -0
- package/src/assets/meeting/svg-icons/icon-play.svg +5 -0
- package/src/assets/meeting/svg-icons/icon-playing-tip.svg +7 -0
- package/src/assets/meeting/svg-icons/icon-playing.svg +5 -0
- package/src/assets/meeting/svg-icons/icon-question.svg +4 -0
- package/src/assets/meeting/svg-icons/icon-sound.svg +5 -0
- package/src/assets/meeting/svg-icons/icon-speaker.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-summit.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-telligent.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-tip.svg +3 -0
- package/src/assets/meeting/svg-icons/icon-todo.svg +4 -0
- package/src/assets/meeting/transparent.png +0 -0
- package/src/assets/svg-icons/icon-chevron-up.svg +3 -0
- package/src/assets/svg-icons/icon-filter.svg +3 -0
- package/src/assets/svg-icons/icon-loading.svg +4 -0
- package/src/assets/svg-icons/icon-search.svg +3 -0
- package/src/assets/svg-icons/icon-tips.svg +3 -0
- package/src/components/OBanner.vue +11 -3
- package/src/components/OFooter.vue +1 -1
- package/src/components/activity/OActivityApproval.vue +775 -0
- package/src/components/activity/OActivityForm.vue +540 -0
- package/src/components/activity/OMyActivityCalendar.vue +13 -0
- package/src/components/activity/config.ts +130 -0
- package/src/components/activity/data.ts +365 -0
- package/src/components/activity/index.ts +24 -0
- package/src/components/activity/types.ts +78 -0
- package/src/components/common/MoreText.vue +119 -0
- package/src/components/common/ThFilter.vue +326 -0
- package/src/components/events/OEventsApply.vue +2 -86
- package/src/components/events/OEventsCalendar.vue +0 -25
- package/src/components/events/OEventsList.vue +0 -51
- package/src/components/events/index.ts +1 -0
- package/src/components/meeting/OMeetingCalendar.vue +865 -0
- package/src/components/meeting/OMeetingForm.vue +1035 -0
- package/src/components/meeting/OMeetingPlayback.vue +439 -0
- package/src/components/meeting/OMyMeetingCalendar.vue +1534 -0
- package/src/components/meeting/OSigMeetingCalendar.vue +411 -0
- package/src/components/meeting/components/OMeetingCalendarList.vue +462 -0
- package/src/components/meeting/components/OMeetingCalendarSelector.vue +206 -0
- package/src/components/meeting/components/OMeetingDetail.vue +176 -0
- package/src/components/meeting/components/OMeetingPlaybackSubtitles.vue +611 -0
- package/src/components/meeting/components/OMeetingPlaybackVideo.vue +741 -0
- package/src/components/meeting/components/OSigMeetingAside.vue +197 -0
- package/src/components/meeting/config.ts +110 -0
- package/src/components/meeting/index.ts +45 -0
- package/src/components/meeting/types.ts +167 -0
- package/src/components/meeting/utils.ts +106 -0
- package/src/draft/Footer.vue +4 -4
- package/src/env.d.ts +15 -0
- package/src/i18n/en.ts +140 -0
- package/src/i18n/index.ts +18 -4
- package/src/i18n/zh.ts +140 -0
- package/src/index.ts +2 -0
- package/tsconfig.json +6 -2
- package/vite.config.ts +25 -9
- package/npmcachae/_cacache/content-v2/sha512/05/f7/dd881de8b21208ea65cfce17c65f29964c3897505819f81151b9798a3a6ab1a1114324192354ead15cd2c8d93f76cc9929af168066ec9cc7878d0fd87578 +0 -1
- package/npmcachae/_cacache/content-v2/sha512/08/b7/879230f8c2f3765920a6fd6113f4687141f1f645f96af7d95a0dee9113d1095d000fb78a5dd55c1860bbfb9b698ef6281b3874b03b2384222f61fe055fc4 +0 -1
- package/npmcachae/_cacache/content-v2/sha512/10/a0/a6626613c03ee052925a762e8675878efdf83dac64fafea43beb2a875f7d7c3907bb0ee30761253cd16021fd58911449594e1d3358675cbb7c48e62f220a +0 -1
- package/npmcachae/_cacache/content-v2/sha512/2e/a6/7cbcf55a98bbe2ca881d10e982ebf59211a0ec051eaf46eb1914df66cc35ae502ed6888850e51d8f45cd92695bac16961a642bc41508f8d5160a9ab617ab +0 -1
- package/npmcachae/_cacache/content-v2/sha512/92/8d/e5259c5d5cc2a625247f3c4d809192ca9482467e23683d74924a11e91a7997ad890b3d26adaf34df66d5329cc7a5fbde6713110cad05107a0b504e4fd4e8 +0 -1
- package/npmcachae/_cacache/content-v2/sha512/e9/45/9597d870127c35681155cec5fe52fde4e1aa0f778b996ee371e856aca850ee4c13aba74b0c3d3a89ff0ea4c9e1d33e64e53c31dc9cede0b31012695ee659 +0 -1
- package/npmcachae/_cacache/index-v5/16/4a/7195fcc6857299c4ab7e26014a8ae6e3c396507a2c8db3da1b74b005d574 +0 -3
- package/npmcachae/_cacache/index-v5/58/f0/4fe556f104b09be642895a82afa463fe560d9a0dc8f507efeef825a6905e +0 -3
- package/npmcachae/_cacache/index-v5/67/7d/0b50dc4c09555fc922ccf43c46994f1a0a5ff47dc0a5d5cf41437ac2d3e6 +0 -3
- package/npmcachae/_cacache/index-v5/8f/28/353f8839e030ab11aab3e7d9f1b8c053403e9f593cf6d4aa6ec8fdd7610d +0 -3
- package/npmcachae/_cacache/index-v5/97/10/0fcf20eb29d0726bd820822f6729718464b591b0e6901217c956740e943c +0 -3
- package/npmcachae/_cacache/index-v5/db/89/a0a4f35f593105624ab39339962d9e9b5cc65ed0c346b0732fb8dd73721d +0 -3
- package/npmcachae/_logs/2026-03-26T14_10_35_885Z-debug-0.log +0 -171
- package/npmcachae/_logs/2026-03-26T14_10_38_617Z-debug-0.log +0 -4227
- package/npmcachae/_logs/2026-03-26T14_10_45_316Z-debug-0.log +0 -4228
- package/npmcachae/_logs/2026-03-26T14_10_48_169Z-debug-0.log +0 -4228
- package/npmcachae/_logs/2026-03-26T14_10_51_306Z-debug-0.log +0 -464
- package/npmcachae/_logs/2026-03-26T14_10_53_911Z-debug-0.log +0 -464
- package/npmcachae/_logs/2026-03-26T14_10_56_398Z-debug-0.log +0 -464
- package/npmcachae/_logs/2026-03-26T14_10_58_861Z-debug-0.log +0 -464
- package/npmcachae/_logs/2026-03-26T14_11_01_337Z-debug-0.log +0 -464
- package/npmcachae/_logs/2026-03-26T14_11_03_851Z-debug-0.log +0 -464
- package/npmcachae/_logs/2026-03-26T14_11_08_024Z-debug-0.log +0 -464
- package/npmcachae/_update-notifier-last-checked +0 -0
- package/src/components/meeting/npmcachae/_cacache/content-v2/sha512/3e/17/1865217b9acb9f4921c53a09b5c76587cd2ab748beb2699ff6cfb1341d73b1aa56ed91ffc5ab2c9c9b3fbe626103b35d9a79ff29ff6b8cbb8d89755fe1a2 +0 -1
- package/src/components/meeting/npmcachae/_cacache/content-v2/sha512/a6/15/47bb7552ec9248079e839a5feecc1742d4de19524fdf041cf581701cf4760a5025106036145e279ba193b07c8fa5b07ae3d75f1b6032f0cb2219115b6167 +0 -1
- package/src/components/meeting/npmcachae/_cacache/content-v2/sha512/d1/4c/133b32e09c97101a27a07cc4432f94e470cff02d120d21babcea77c3f5cd436793516dc1a8e282ee1a568f923c148b1a48f4a43233462a530d35e8b41c67 +0 -1
- package/src/components/meeting/npmcachae/_cacache/index-v5/54/0d/a4909047714a0a7198bb9bd37020992464e47c79a791889919b84d90aab0 +0 -3
- package/src/components/meeting/npmcachae/_cacache/index-v5/8e/2b/21a79778e2ac08cf5663baf83cb35f951995a496007eb2e2f7fba54021a4 +0 -3
- package/src/components/meeting/npmcachae/_cacache/index-v5/eb/a0/b70c8132e5b57a0f1e129b8cc941796420a9c147c0baa680710083740898 +0 -2
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_03_54_955Z-debug-0.log +0 -277
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_03_57_842Z-debug-0.log +0 -277
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_04_00_016Z-debug-0.log +0 -277
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_04_02_191Z-debug-0.log +0 -277
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_04_04_425Z-debug-0.log +0 -277
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_04_06_642Z-debug-0.log +0 -277
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_04_08_826Z-debug-0.log +0 -277
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_25_36_140Z-debug-0.log +0 -433
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_25_39_573Z-debug-0.log +0 -433
- package/src/components/meeting/npmcachae/_logs/2026-03-20T07_25_42_134Z-debug-0.log +0 -212
- package/src/components/meeting/npmcachae/_update-notifier-last-checked +0 -0
package/dist/components.cjs.js
CHANGED
|
@@ -1,3 +1,224 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),i=require("@opensig/opendesign"),Q=require("@opendesign-plus/composables"),H=require("./chunk-OElCookieNotice.cjs.js"),pt=require("@vueuse/core"),_o=require("element-plus"),yo=e.defineComponent({__name:"ContentWrapper",props:{verticalPadding:{type:[Boolean,String,Array],default:void 0}},setup(o){const t=Symbol("default"),r=o,l=e.computed(()=>r.verticalPadding?i.isBoolean(r.verticalPadding)?t:i.isString(r.verticalPadding)?r.verticalPadding:r.verticalPadding[0]:0),a=e.computed(()=>r.verticalPadding?i.isBoolean(r.verticalPadding)?t:i.isString(r.verticalPadding)?r.verticalPadding:i.isUndefined(r.verticalPadding[1])?r.verticalPadding[0]:r.verticalPadding[1]:0);return(c,m)=>(e.openBlock(),e.createElementBlock("div",{class:"content-wrapper",style:e.normalizeStyle({"--content-wrapper-vertical-paddingTop":l.value===e.unref(t)?void 0:l.value,"--content-wrapper-vertical-paddingBottom":a.value===e.unref(t)?void 0:a.value})},[e.renderSlot(c.$slots,"default",{},void 0,!0)],4))}}),ve=H._export_sfc(yo,[["__scopeId","data-v-29de9f52"]]),Eo={key:0},Bo={class:"banner-content"},No=["src"],wo={key:1,class:"banner-title"},Vo={key:2,class:"banner-subtitle"},So={key:4,class:"banner-opts"},bo=e.defineComponent({__name:"OBanner",props:{options:void 0,size:"large",contentJustifyCenter:!1},setup(o){const t=o,{isLight:r}=Q.useTheme("opendesignplus",document.domain||"localhost"),{isPhone:l}=Q.useScreen(),a=e.computed(()=>t.options),c=e.ref(""),m=s=>{setTimeout(()=>{c.value=a.value[s].bg_theme??"light"},100)},p=(s,y)=>{s&&!y&&window.open(s)};return(s,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["home-banner",o.size])},[o.size==="tiny"?(e.openBlock(),e.createElementBlock("div",Eo,e.toDisplayString(a.value[1].title),1)):e.unref(l)?(e.openBlock(),e.createBlock(e.unref(i.OCarousel),{key:2,class:"banner-carousel",effect:"gallery","indicator-click":"","data-o-theme":c.value,arrow:"never","auto-play":!0,onBeforeChange:m},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.value,(u,h)=>(e.openBlock(),e.createBlock(e.unref(i.OCarouselItem),{class:e.normalizeClass(["banner-item",`banner-item${h}`])},{default:e.withCtx(()=>[e.createVNode(ve,{class:"banner-wrapper"},{default:e.withCtx(()=>[e.createVNode(e.unref(i.OFigure),{class:"banner-bg",src:u.bg,onClick:V=>p(u.href)},null,8,["src","onClick"])]),_:2},1024)]),_:2},1032,["class"]))),256))]),_:1},8,["data-o-theme"])):(e.openBlock(),e.createBlock(e.unref(i.OCarousel),{key:1,class:"banner-carousel",effect:"toggle","active-class":"current-slide","indicator-click":"","auto-play":!0,"data-o-theme":c.value,onBeforeChange:m},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.value,(u,h)=>(e.openBlock(),e.createBlock(e.unref(i.OCarouselItem),{key:h,class:e.normalizeClass(["banner-item",`banner-item${h}`])},{default:e.withCtx(()=>[e.createVNode(e.unref(i.OFigure),{class:e.normalizeClass(["banner-bg",{"with-sticky-bg":u.withStickyBg,"in-dark":!e.unref(r),"cursor-pointer":u.href&&!u.btn}]),src:u.bg,style:e.normalizeStyle({"--pad-offset":u.pad_offset}),onClick:V=>p(u.href,u.btn)},{default:e.withCtx(()=>[e.createVNode(ve,{class:e.normalizeClass(["banner-wrapper",["banner-wrapper",o.contentJustifyCenter?"content-center":""]])},{default:e.withCtx(()=>[e.createElementVNode("div",Bo,[!e.unref(l)&&u.attach?(e.openBlock(),e.createElementBlock("img",{key:0,src:u.attach,class:"banner-attach"},null,8,No)):e.createCommentVNode("",!0),u.title?(e.openBlock(),e.createElementBlock("div",wo,e.toDisplayString(u.title),1)):e.createCommentVNode("",!0),u.subtitle?(e.openBlock(),e.createElementBlock("div",Vo,e.toDisplayString(u.subtitle),1)):e.createCommentVNode("",!0),u.bg_text?(e.openBlock(),e.createElementBlock("div",{key:3,class:"banner-text",style:e.normalizeStyle({backgroundImage:`url(${u.bg_text})`,"--pc-width":u.pc_text_width,"--pc-height":u.pc_text_height,"--pad-width":u.pad_text_width,"--pad-height":u.pad_text_height})},null,4)):e.createCommentVNode("",!0),u.btn?(e.openBlock(),e.createElementBlock("div",So,[e.createVNode(e.unref(i.OButton),{href:u.href,target:"_blank",variant:"solid",color:"primary",size:o.size},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(u.btn),1)]),_:2},1032,["href","size"])])):e.createCommentVNode("",!0)])]),_:2},1032,["class"])]),_:2},1032,["src","class","style","onClick"])]),_:2},1032,["class"]))),128))]),_:1},8,["data-o-theme"]))],2))}}),Zt=H._export_sfc(bo,[["__scopeId","data-v-a5902620"]]),Lo={key:0,class:"cookie-notice"},Oo={class:"cookie-notice-content"},$o=["type"],Do={class:"cookie-notice-left"},xo={key:0,class:"cookie-desc",style:{"margin-top":"0"}},To=["href"],Ao={class:"cookie-title"},Io={class:"cookie-desc"},Mo=["href"],Ro={key:0,class:"cookie-notice-right"},zo={class:"cookie-dlg-title"},Fo={class:"cookie-dlg-content"},Po={class:"content-item"},Ho={class:"item-header"},Uo={class:"item-title"},Wo={class:"item-extra"},Go={class:"item-detail"},jo={class:"content-item"},qo={class:"item-header"},Ko={class:"item-title"},Zo={class:"item-extra"},Yo={class:"item-detail"},Xo="0",At="1",Jo="2",Ae="3",Qo="agreed-cookiepolicy-zh",en="agreed-cookiepolicy-en",tn=e.defineComponent({__name:"OCookieNotice",props:{visible:{type:Boolean},enableGrid:{type:Boolean},community:{},detailUrl:{},wrapper:{},cookieDomain:{}},emits:["update:visible"],setup(o,{expose:t,emit:r}){const l=o,a=r,{lePadV:c,leLaptop:m}=Q.useScreen(),{locale:p,t:s}=H.useI18n(),y=e.computed(()=>p.value==="zh"),u=e.computed(()=>y.value?Qo:en),h=e.ref(!1),V=pt.useVModel(l,"visible",a,{defaultValue:!1}),E=z=>{const I=document.cookie.split(";").find(D=>D.split("=")[0].trim()===encodeURIComponent(z));return I?decodeURIComponent(I.split("=")[1]):null},N=(z,I,D,C)=>{const B=`; max-age=${D*24*60*60}`;document.cookie=`${encodeURIComponent(z)}=${encodeURIComponent(I)}${B}; path=/; domain=${C}`},w=(z,I)=>{document.cookie=`${encodeURIComponent(z)}=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/; domain=${I}`},k=z=>{typeof z=="boolean"?V.value=z:V.value=!V.value,e.nextTick(()=>{!V.value&&y.value&&E(u.value)!==Ae&&N(u.value,Ae,180,l.cookieDomain??location.hostname)})},S=e.ref(!1),R=z=>{typeof z=="boolean"?S.value=z:S.value=!S.value},g=()=>y.value?E(u.value)!==Ae:(E(u.value)??"0")===Xo,L=()=>y.value?E(u.value)===Ae:E(u.value)===At;e.onMounted(()=>{g()&&k(!0)}),e.watch(p,()=>{k(g())});const O=()=>{h.value=!0,w(u.value,l.cookieDomain??location.hostname),N(u.value,At,180,l.cookieDomain??location.hostname),k(!1)},$=()=>{h.value=!1,w(u.value,l.cookieDomain??location.hostname),N(u.value,Jo,180,l.cookieDomain??location.hostname),k(!1)},F=e.computed(()=>[{id:"save",color:"primary",label:s("cookie.saveSetting"),variant:"outline",size:"large",round:"pill",onClick:()=>{h.value?O():$(),R(!1)}},{id:"allowAll",color:"primary",label:s("cookie.acceptAll"),variant:"outline",size:"large",round:"pill",onClick:()=>{h.value=!0,O(),R(!1)}}]),ne=z=>{z&&(h.value=L())};return t({check(){L()===V.value&&k()}}),(z,I)=>(e.openBlock(),e.createBlock(e.unref(H.ClientOnly),null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.Teleport,{to:o.wrapper||"#app"},[e.unref(V)?(e.openBlock(),e.createElementBlock("div",Lo,[e.createElementVNode("div",Oo,[e.createElementVNode("div",{type:e.unref(p),class:e.normalizeClass({"cookie-notice-wrap-grid":o.enableGrid,"cookie-notice-wrap":!o.enableGrid})},[e.createElementVNode("div",Do,[y.value?(e.openBlock(),e.createElementBlock("p",xo,[e.createTextVNode(e.toDisplayString(e.unref(s)("cookie.desc"))+" ",1),e.createElementVNode("a",{href:o.detailUrl,target:"_blank",rel:"noopener noreferrer"},e.toDisplayString(e.unref(s)("cookie.about")),9,To)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("p",Ao,e.toDisplayString(e.unref(s)("cookie.title",[o.community])),1),e.createElementVNode("p",Io,[e.createTextVNode(e.toDisplayString(e.unref(s)("cookie.desc"))+" ",1),e.createElementVNode("a",{href:o.detailUrl,target:"_blank",rel:"noopener noreferrer"},e.toDisplayString(e.unref(s)("cookie.about")),9,Mo),I[4]||(I[4]=e.createTextVNode(". ",-1))])],64))]),y.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Ro,[e.createVNode(e.unref(i.OButton),{round:"pill",variant:"outline",color:"primary",onClick:O},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(s)("cookie.acceptAll")),1)]),_:1}),e.createVNode(e.unref(i.OButton),{round:"pill",variant:"outline",color:"primary",onClick:$},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(s)("cookie.rejectAll")),1)]),_:1}),e.createVNode(e.unref(i.OButton),{round:"pill",variant:"outline",color:"primary",onClick:I[0]||(I[0]=D=>R(!0))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(s)("cookie.manage")),1)]),_:1})])),e.createVNode(e.unref(i.OIcon),{class:"cookie-notice-close",type:e.unref(p),onClick:I[1]||(I[1]=D=>k(!1))},{default:e.withCtx(()=>[e.createVNode(e.unref(i.OIconClose))]),_:1},8,["type"])],10,$o)]),e.createVNode(e.unref(i.ODialog),{visible:S.value,"onUpdate:visible":I[3]||(I[3]=D=>S.value=D),size:e.unref(m)?"medium":"large","phone-half-full":e.unref(c),class:"cookie-dlg",actions:F.value,onChange:ne},{header:e.withCtx(()=>[e.createElementVNode("span",zo,e.toDisplayString(e.unref(s)("cookie.manage")),1)]),default:e.withCtx(()=>[e.createElementVNode("div",Fo,[e.createElementVNode("div",Po,[e.createElementVNode("div",Ho,[e.createElementVNode("span",Uo,e.toDisplayString(e.unref(s)("cookie.necessaryCookie")),1),e.createElementVNode("span",Wo,e.toDisplayString(e.unref(s)("cookie.alwaysOn")),1)]),e.createElementVNode("div",Go,e.toDisplayString(e.unref(s)("cookie.necessaryCookieDetail")),1)]),e.createElementVNode("div",jo,[e.createElementVNode("div",qo,[e.createElementVNode("span",Ko,e.toDisplayString(e.unref(s)("cookie.analyticalCookie")),1),e.createElementVNode("span",Zo,[e.createVNode(e.unref(i.OSwitch),{modelValue:h.value,"onUpdate:modelValue":I[2]||(I[2]=D=>h.value=D)},null,8,["modelValue"])])]),e.createElementVNode("div",Yo,e.toDisplayString(e.unref(s)("cookie.analyticalCookieDetail")),1)])])]),_:1},8,["visible","size","phone-half-full","actions"])])):e.createCommentVNode("",!0)],8,["to"]))]),_:1}))}}),Yt=H._export_sfc(tn,[["__scopeId","data-v-f1dd144c"]]),on={key:0,class:"atom"},nn={class:"atom-text"},rn=["href"],an=["src"],ln={key:0,class:"quick-nav"},cn={class:"category-title"},sn={class:"navs"},dn=["href"],un={key:0,class:"friendship-link"},mn={class:"friendship-link-title"},pn={class:"friendship-link-box"},fn=["href"],hn={key:0,class:"footer-logo"},vn=["src"],kn=["src"],gn=["href"],Cn={key:1,class:"footer-option"},_n={class:"footer-option-item"},yn=["href"],En={class:"license"},Bn={class:"copyright"},Nn={class:"filing"},wn=["href"],Vn=["src"],Sn={key:2,class:"footer-right"},bn={key:0,class:"code-box"},Ln=["src"],On={class:"code-layer"},$n=["src"],Dn={class:"txt"},xn={class:"app-footer-pc"},Tn={key:0,class:"footer-left"},An=["href"],In=["src"],Mn={key:0,class:"footer-right"},Rn=["href"],zn={class:"app-footer-mb"},Fn={key:0,class:"links"},Pn=["href"],Hn={class:"copyright"},Un={key:0,class:"approval"},Wn=["href"],Gn=["src"],jn=e.defineComponent({__name:"OFooter",props:{simple:!1,atom:void 0,lang:void 0,quickNav:void 0,friendshipLink:void 0,footerLogo:void 0,footerOption:void 0,qrcode:void 0,footerBg:void 0},setup(o){const t=o;return(r,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([t.simple?"app-footer-simple":"app-footer"])},[t.simple?(e.openBlock(),e.createBlock(ve,{key:1},{default:e.withCtx(()=>[e.createElementVNode("div",xn,[r.$slots.left||t.footerOption?e.renderSlot(r.$slots,"left",{key:0},()=>[t.footerOption?(e.openBlock(),e.createElementBlock("div",Tn,[e.createElementVNode("span",null,e.toDisplayString(t.footerOption[t.lang].copyright),1),e.createElementVNode("a",{class:"approval",href:t.footerOption[t.lang].beianLink,target:"_blank",rel:"noopener noreferrer"},e.toDisplayString(t.footerOption[t.lang].beianInfo1),9,An),e.createElementVNode("img",{class:"police-img",src:t.footerOption[t.lang].policeIcon},null,8,In),e.createElementVNode("span",null,e.toDisplayString(t.footerOption[t.lang].beianInfo2),1)])):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0),r.$slots.right||t.footerOption?e.renderSlot(r.$slots,"right",{key:1},()=>[t.footerOption?(e.openBlock(),e.createElementBlock("div",Mn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.footerOption[t.lang].link,(a,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:a.url},[e.createElementVNode("a",{target:"_blank",href:a.url,class:"link"},e.toDisplayString(a.name),9,Rn),c!==t.footerOption[t.lang].link.length-1?(e.openBlock(),e.createBlock(e.unref(i.ODivider),{key:0,direction:"v"})):e.createCommentVNode("",!0)],64))),128))])):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0)]),e.createElementVNode("div",zn,[r.$slots.right||t.footerOption?e.renderSlot(r.$slots,"right",{key:0},()=>[t.footerOption?(e.openBlock(),e.createElementBlock("div",Fn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.footerOption[t.lang].link,(a,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:a.url},[e.createElementVNode("a",{target:"_blank",href:a.url,class:"link"},e.toDisplayString(a.name),9,Pn),c!==t.footerOption[t.lang].link.length-1?(e.openBlock(),e.createBlock(e.unref(i.ODivider),{key:0,direction:"v"})):e.createCommentVNode("",!0)],64))),128))])):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0),e.renderSlot(r.$slots,"copyright",{},()=>[e.createElementVNode("div",Hn,e.toDisplayString(t.footerOption[t.lang].copyright),1)],!0),r.$slots.left||t.footerOption?e.renderSlot(r.$slots,"left",{key:1},()=>[t.footerOption?(e.openBlock(),e.createElementBlock("div",Un,[e.createElementVNode("a",{href:t.footerOption[t.lang].beianLink,target:"_blank",rel:"noopener noreferrer"},e.toDisplayString(t.footerOption[t.lang].beianInfo1),9,Wn),e.createElementVNode("img",{class:"police-img",src:t.footerOption[t.lang].policeIcon},null,8,Gn),e.createElementVNode("span",null,e.toDisplayString(t.footerOption[t.lang].beianInfo2),1)])):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0)])]),_:3})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[r.$slots.atom||t.atom?(e.openBlock(),e.createBlock(ve,{key:0},{default:e.withCtx(()=>[e.renderSlot(r.$slots,"atom",{},()=>[t.atom?(e.openBlock(),e.createElementBlock("div",on,[e.createElementVNode("p",nn,e.toDisplayString(t.atom[t.lang].title),1),e.createElementVNode("a",{href:t.atom[t.lang].href,target:"_blank"},[e.createElementVNode("img",{src:t.atom[t.lang].img,class:"atom-logo",alt:""},null,8,an)],8,rn)])):e.createCommentVNode("",!0),e.createVNode(e.unref(i.ODivider),{class:"atom-divider"})],!0)]),_:3})):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"footer-content",style:e.normalizeStyle({backgroundImage:`url(${t.footerBg})`})},[e.createVNode(ve,null,{default:e.withCtx(()=>[r.$slots.quickNav||t.quickNav?e.renderSlot(r.$slots,"quickNav",{key:0},()=>[t.quickNav?(e.openBlock(),e.createElementBlock("div",ln,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.quickNav[t.lang],a=>(e.openBlock(),e.createElementBlock("div",{key:a.title,class:"category"},[e.createElementVNode("div",cn,e.toDisplayString(a.title),1),e.createElementVNode("ul",sn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.list,c=>(e.openBlock(),e.createElementBlock("li",{key:c.title,class:"nav"},[e.createElementVNode("a",{href:c.link,target:"_blank",rel:"noopener noreferrer"},e.toDisplayString(c.title),9,dn)]))),128))])]))),128))])):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0),r.$slots.friendshipLink||t.friendshipLink?e.renderSlot(r.$slots,"friendshipLink",{key:1},()=>[t.friendshipLink?(e.openBlock(),e.createElementBlock("div",un,[e.createElementVNode("div",mn,e.toDisplayString(t.friendshipLink.title[t.lang]),1),e.createElementVNode("div",pn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.friendshipLink.link[t.lang],a=>(e.openBlock(),e.createElementBlock("a",{href:a.link,key:a.link,target:"_blank"},e.toDisplayString(a.title),9,fn))),128))])])):e.createCommentVNode("",!0)],!0):e.createCommentVNode("",!0),e.renderSlot(r.$slots,"footer",{},()=>[e.createElementVNode("div",{class:e.normalizeClass(["inner",{"inner-en":t.lang==="en"}])},[t.footerLogo?(e.openBlock(),e.createElementBlock("div",hn,[e.createElementVNode("img",{class:"show-pc",src:t.footerLogo.logo,alt:""},null,8,vn),e.createElementVNode("img",{class:"show-mo",src:t.footerLogo.logoMb,alt:""},null,8,kn),e.createElementVNode("p",null,[e.createElementVNode("a",{class:"email",href:`mailto:${t.footerLogo.email}`,target:"_blank"},e.toDisplayString(t.footerLogo.email),9,gn)])])):e.createCommentVNode("",!0),t.footerOption?(e.openBlock(),e.createElementBlock("div",Cn,[e.createElementVNode("div",_n,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.footerOption[t.lang].link,(a,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:a.url},[e.createElementVNode("a",{target:"_blank",href:a.url},e.toDisplayString(a.name),9,yn),c!==t.footerOption[t.lang].link.length-1?(e.openBlock(),e.createBlock(e.unref(i.ODivider),{key:0,style:{"--o-divider-bd-color":"var(--o-color-info3-inverse)","--o-divider-label-gap":"0 8px"},direction:"v"})):e.createCommentVNode("",!0)],64))),128))]),e.createElementVNode("p",En,[e.createElementVNode("span",null,e.toDisplayString(t.footerOption[t.lang].licenseText),1),e.createTextVNode(" "+e.toDisplayString(t.footerOption[t.lang].licenseInfo),1)]),e.createElementVNode("div",Bn,[e.createElementVNode("p",null,e.toDisplayString(t.footerOption[t.lang].copyright),1),e.createElementVNode("div",Nn,[e.createElementVNode("a",{href:t.footerOption[t.lang].beianLink,target:"_blank"},e.toDisplayString(t.footerOption[t.lang].beianInfo1),9,wn),e.createElementVNode("img",{src:t.footerOption[t.lang].policeIcon,class:"filing-img"},null,8,Vn),e.createElementVNode("p",null,e.toDisplayString(t.footerOption[t.lang].beianInfo2),1)])])])):e.createCommentVNode("",!0),t.qrcode?(e.openBlock(),e.createElementBlock("div",Sn,[t.lang==="zh"?(e.openBlock(),e.createElementBlock("div",bn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.qrcode,(a,c)=>(e.openBlock(),e.createElementBlock("div",{key:c,class:"code-pop"},[e.createElementVNode("img",{src:a.img,class:"code-img",alt:""},null,8,Ln),e.createElementVNode("div",On,[e.createElementVNode("img",{src:a.code,alt:""},null,8,$n),e.createElementVNode("p",Dn,e.toDisplayString(a.label),1)])]))),128))])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],2)],!0)]),_:3})],4)],64))],2))}}),Xt=H._export_sfc(jn,[["__scopeId","data-v-f095d641"]]),qn={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function Kn(o,t){return e.openBlock(),e.createElementBlock("svg",qn,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"currentColor",d:"M9.461 11.616l4.719-3.932c0.212-0.177 0.527-0.148 0.704 0.064 0.075 0.090 0.116 0.203 0.116 0.32v7.865c0 0.276-0.224 0.5-0.5 0.5-0.117 0-0.23-0.041-0.32-0.116l-4.719-3.932c-0.212-0.177-0.241-0.492-0.064-0.704 0.019-0.023 0.041-0.045 0.064-0.064z"},null,-1)])])}const Zn={name:"components-icon-caret-left",render:Kn},Yn={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function Xn(o,t){return e.openBlock(),e.createElementBlock("svg",Yn,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"currentColor",d:"M14.539 11.616l-4.719-3.932c-0.212-0.177-0.527-0.148-0.704 0.064-0.075 0.090-0.116 0.203-0.116 0.32v7.865c0 0.276 0.224 0.5 0.5 0.5 0.117 0 0.23-0.041 0.32-0.116l4.719-3.932c0.212-0.177 0.241-0.492 0.064-0.704-0.019-0.023-0.041-0.045-0.064-0.064z"},null,-1)])])}const Jn={name:"components-icon-caret-right",render:Xn},Qn={class:"header-content"},er={key:0,class:"right-icon"},tr=["onMouseenter"],or=["id"],nr={class:"nav-drop-content"},rr={class:"nav-sub-content"},ar={class:"content-left"},lr={class:"content-label"},cr={class:"content-container"},sr=["onClick"],ir={class:"item-name"},dr={key:0,class:"desc-container"},ur=["title"],mr={key:0,class:"split-line"},pr={key:1,class:"content-right"},fr=["onClick"],hr=["onClick"],vr=["src"],kr={class:"review-content"},gr={class:"review-label"},Cr={class:"review-property"},_r={key:1,class:"right-icon"},yr=e.defineComponent({__name:"HeaderEulerNav",props:{navData:void 0,bgLeft:void 0,bgRight:void 0},setup(o){const t=o,{locale:r}=Q.useLocale(),{theme:l,isDark:a}=Q.useTheme(),c=e.ref(),m=e.ref(),p=e.ref(null),s=e.ref(!1),y=e.ref(!1),u=e.ref(!1),h=e.ref(),V=e.ref([]),E=e.ref([]),N=e.ref(!1),w=pt.useDebounceFn(function($){$===null?(h.value="",u.value=!1,N.value=!1):(h.value=$.id,u.value=!0,V.value=$.children,E.value=$.shortcut,N.value=$.withPicture)},100),k=($,F)=>{window.open($,F),h.value="",u.value=!1},S=e.ref(!1),R=$=>{!$||!$.target||(S.value=$.target.clientHeight<$.target.scrollHeight)},g=()=>{y.value=!0,e.nextTick(()=>{c.value.scrollTo({left:c.value.clientWidth,behavior:"smooth"})})},L=()=>{c.value.scrollTo({left:0,behavior:"smooth"}),y.value=!1},O=()=>{var $,F;(($=c.value)==null?void 0:$.clientWidth)<((F=m.value)==null?void 0:F.clientWidth)&&(s.value=!0)};return e.onMounted(()=>{window.addEventListener("resize",O),e.nextTick(()=>{O(),p.value=setTimeout(()=>{O()},1e3)})}),e.onUnmounted(()=>{window.removeEventListener("resize",O),clearTimeout(p.value)}),($,F)=>(e.openBlock(),e.createElementBlock("div",Qn,[e.createElementVNode("div",{class:e.normalizeClass(["header-nav",{"header-nav-scroll":y.value}])},[y.value?(e.openBlock(),e.createElementBlock("div",er,[e.createVNode(e.unref(i.OIcon),{onClick:L},{default:e.withCtx(()=>[e.createVNode(e.unref(Zn))]),_:1})])):e.createCommentVNode("",!0),e.createElementVNode("nav",{ref_key:"navRef",ref:c,class:e.normalizeClass(["o-nav",{"o-nav-scroll":y.value||!s.value,dark:e.unref(a)}])},[e.createElementVNode("ul",{ref_key:"navListRef",ref:m,class:"o-nav-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.navData,ne=>(e.openBlock(),e.createElementBlock("li",{key:ne.id,onMouseenter:z=>e.unref(w)(ne),onMouseleave:F[1]||(F[1]=z=>e.unref(w)(null))},[e.createElementVNode("span",{id:"tour_headerNav_"+ne.ID,class:"nav-item"},e.toDisplayString(ne.label),9,or),e.createVNode(e.Transition,{name:"transition"},{default:e.withCtx(()=>[u.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["nav-dropdown",h.value,e.unref(l),`${h.value}-${e.unref(r)}`])},[e.createElementVNode("div",nr,[e.createElementVNode("div",{class:"nav-background-left",style:e.normalizeStyle({backgroundImage:`url(${t.bgLeft})`})},null,4),e.createElementVNode("div",{class:"nav-background-right",style:e.normalizeStyle({backgroundImage:`url(${t.bgRight})`})},null,4),e.createVNode(e.unref(i.OScroller),{class:"nav-scroller","show-type":"always",size:"small","disabled-y":""},{default:e.withCtx(()=>{var z,I;return[e.createElementVNode("div",rr,[e.createElementVNode("div",ar,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(V.value,(D,C)=>(e.openBlock(),e.createElementBlock("div",{class:"item-sub",key:C},[e.createElementVNode("span",lr,e.toDisplayString(D.label),1),e.createElementVNode("div",cr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(D.children,B=>(e.openBlock(),e.createElementBlock("div",{key:B.label,class:"content-item"},[e.createElementVNode("a",{onClick:M=>k(B.href,"_self"),rel:"noopener noreferrer",class:"item-label"},[e.createElementVNode("span",ir,e.toDisplayString(B.label),1),B.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(B.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0),B.tag?(e.openBlock(),e.createBlock(e.unref(i.OTag),{key:1,round:"pill",color:"danger",size:"small",class:"content-tag"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(B.tag),1)]),_:2},1024)):e.createCommentVNode("",!0)],8,sr),B.description?(e.openBlock(),e.createElementBlock("div",dr,[e.createElementVNode("p",{class:"item-desc",title:S.value?B.description:null,onMouseenter:F[0]||(F[0]=M=>R(M))},e.toDisplayString(B.description),41,ur)])):e.createCommentVNode("",!0)]))),128))])]))),128))]),(z=E.value)!=null&&z.length?(e.openBlock(),e.createElementBlock("div",mr)):e.createCommentVNode("",!0),(I=E.value)!=null&&I.length?(e.openBlock(),e.createElementBlock("div",pr,[F[2]||(F[2]=e.createElementVNode("span",{class:"content-label"},"快捷链接",-1)),N.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(E.value,D=>(e.openBlock(),e.createElementBlock("a",{key:D.label,onClick:C=>k(D.href,"_self"),rel:"noopener noreferrer",class:"review"},[e.createElementVNode("img",{src:D.picture,class:"review-picture"},null,8,vr),e.createElementVNode("div",kr,[e.createElementVNode("p",gr,e.toDisplayString(D.label),1),e.createElementVNode("div",Cr,[e.createElementVNode("span",null,e.toDisplayString(D.remark),1)])])],8,hr))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(E.value,D=>(e.openBlock(),e.createElementBlock("div",{key:D.label,class:"shortcut"},[e.createElementVNode("a",{onClick:C=>k(D.href,"_self"),rel:"noopener noreferrer",class:"shortcut-link"},[e.createElementVNode("span",null,e.toDisplayString(D.label),1),D.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(D.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0)],8,fr)]))),128))])):e.createCommentVNode("",!0)])]}),_:1})])],2)):e.createCommentVNode("",!0)]),_:1})],40,tr))),128))],512)],2),s.value&&!y.value?(e.openBlock(),e.createElementBlock("div",_r,[e.createVNode(e.unref(i.OIcon),{onClick:g},{default:e.withCtx(()=>[e.createVNode(e.unref(Jn))]),_:1})])):e.createCommentVNode("",!0)],2)]))}}),Er=H._export_sfc(yr,[["__scopeId","data-v-d3d0a9ef"]]),Br=["id","onMouseenter","onMouseleave"],Nr=["href"],wr={key:1,class:"info-wrap"},Vr={class:"dropdown-wrapper"},Sr={key:0,class:"tab-disabled"},br={key:1,class:"tab-expand"},Lr=["href","target","rel"],Or={class:"dropdown-body-wrapper",style:{display:"none !important"}},$r=["onMouseenter"],Dr={key:0,class:"dropdown-item"},xr={class:"tab-disabled"},Tr={key:1,class:"dropdown-item"},Ar=["href","target","rel"],Be="more",Ir=e.defineComponent({__name:"HeaderUbmcNav",props:{navData:void 0,hasPerm:void 0,tagMap:void 0,currentPath:void 0},setup(o){const t=o,{locale:r}=Q.useLocale(),{lePadV:l}=Q.useScreen(),a={},c=e.ref({}),m=e.ref(-1),p=C=>{m.value=C},s=C=>{var B;m.value=-1,(B=c.value[C])==null||B.clearCheckedNodes()},y=e.ref(-1),u=()=>{var B;const C=(B=a==null?void 0:a.fullPath)==null?void 0:B.split("/").slice(0,3).join("/");y.value=[...N.value,E.value].findIndex(M=>{var A,X;const x=C==null?void 0:C.indexOf("#");return F.value.length&&!F.value.includes(M.id)&&M.id!==Be?!1:D(M.href)===C||((A=M.children)==null?void 0:A.some(_=>{var ce;return(ce=_.children)!=null&&ce.length?_.children.some(le=>D(le.href)===C):D(_.href)===C}))||((X=M.keys)==null?void 0:X.includes(C==null?void 0:C.slice(1,x!==-1?x:C==null?void 0:C.length)))})};e.onMounted(()=>{u()}),e.watch(()=>a.path,()=>{u()});const h=(C,B)=>{let M=!0;return C&&(M=M&&new Date(C).getTime()>=Date.now()),B&&(M=M&&r.value===B),M},V=(C,B)=>C.checkPermKey?B[C.checkPermKey]:!0,E=e.computed(()=>({id:Be,label:"更多",children:N.value.filter(C=>!F.value.includes(C.id))||[]})),N=e.computed(()=>{const C=[];let B=[];const M={meeting:t.hasPerm};try{B=t.navData.filter(x=>V(x,M)).map(function x(A){C.push(A.label);const X={...A,_path:[...C]};return A.children&&(X.children=A.children.filter(_=>V(_,M)).map(x)),C.pop(),X})}catch{B=t.navData}return B});let w=0,k=0;const S=C=>{const B=Date.now()-w,M=k+1;if(w=0,k=0,C._path){const x={};return C._path.forEach((A,X)=>{x[`level${X+1}`]=A}),{properties:{module:"navigation",timeUsed:B,steps:M,...x}}}},R=C=>{if(k++,!w)return w=Date.now(),{event:"hover",properties:{module:"navigation",target:C.label}}},g=()=>{w=0,k=0},L=C=>C?C.startsWith("http"):!1,O=e.ref(null),$=e.ref(null),F=e.ref([]),ne=e.ref(null),z=e.ref(0),I=()=>{if(!O.value)return;if(F.value=[],z.value=O.value.clientWidth,l.value&&(F.value=N.value.map(A=>A.id)),O.value.clientWidth>=$.value.clientWidth){F.value=N.value.map(A=>A.id);return}z.value=0;const C=$.value.querySelector(`li.nav-item#${Be}`);let B=O.value.clientWidth-C.clientWidth;const M=$.value.querySelectorAll("li.nav-item");let x=!1;[...M].forEach((A,X)=>{A.id!==Be&&B>A.clientWidth&&!x?(B-=A.clientWidth,F.value.push(N.value[X].id),z.value+=A.clientWidth):x=!0})};e.onMounted(()=>{window.addEventListener("resize",I),e.nextTick(()=>{I(),ne.value=setTimeout(()=>{I()},1e3)})}),e.onUnmounted(()=>{window.removeEventListener("resize",I),clearTimeout(ne.value)}),e.watch(()=>N.value,()=>{e.nextTick(()=>{I()})},{deep:!0});const D=C=>(C==="/"&&(C=""),L(C)?C:`/${r.value}${C}`);return(C,B)=>{const M=e.resolveDirective("analytics");return e.openBlock(),e.createElementBlock("nav",{class:"header-nav-ubmc",ref_key:"wrapperRef",ref:O},[e.createElementVNode("ul",{class:"nav-list",onMouseleave:g,ref_key:"listRef",ref:$,style:e.normalizeStyle({"--more-left":z.value})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList([...N.value,E.value],(x,A)=>{var X;return e.withDirectives((e.openBlock(),e.createElementBlock("li",{key:x.id,id:x.id,class:e.normalizeClass(["nav-item",{"is-selected":y.value===A,"is-active":m.value===A,hidden:!F.value.includes(x.id)&&x.id!==Be||x.id===Be&&x.children.length===0}]),onMouseenter:_=>p(A),onMouseleave:_=>s(A)},[!((X=x.children)!=null&&X.length)&&x.href?(e.openBlock(),e.createElementBlock("a",{key:0,class:"info-wrap clickable",href:D(x.href)},[e.createElementVNode("span",null,[e.createElementVNode("span",null,e.toDisplayString(x.label),1)])],8,Nr)):(e.openBlock(),e.createElementBlock("div",wr,[e.createElementVNode("span",null,[e.createElementVNode("span",null,e.toDisplayString(x.label),1)]),e.createElementVNode("div",Vr,[e.createVNode(e.unref(_o.ElCascaderPanel),{options:x.children,value:"id",expandTrigger:"hover",ref_for:!0,ref:_=>c.value[A]=_},{default:e.withCtx(({data:_})=>{var ce;return[_.disabled?(e.openBlock(),e.createElementBlock("div",Sr,[e.createElementVNode("span",null,e.toDisplayString(_.label),1),B[0]||(B[0]=e.createElementVNode("span",{class:"disabled-tag"},"待上线",-1))])):_!=null&&_.children?(e.openBlock(),e.createElementBlock("div",br,[e.createElementVNode("span",null,e.toDisplayString(_.label),1),e.createVNode(e.unref(i.OIcon),null,{default:e.withCtx(()=>[e.createVNode(e.unref(i.OIconChevronRight))]),_:1})])):(e.openBlock(),e.createElementBlock("a",{key:2,href:D(_.href),class:"dropdown-link",target:L(_.href)?"_blank":"_self",rel:L(_.href)?"noopener noreferrer":""},[e.createElementVNode("span",null,e.toDisplayString(_.label),1),(o.tagMap[(ce=_==null?void 0:_.href)==null?void 0:ce.slice(1)]||_.tag)&&h(_.tagExpire,_.tagLang)?(e.openBlock(),e.createBlock(e.unref(i.OTag),{key:0,color:"danger",size:"small",round:"pill"},{default:e.withCtx(()=>{var le;return[e.createTextVNode(e.toDisplayString(o.tagMap[(le=_==null?void 0:_.href)==null?void 0:le.slice(1)]||_.tag),1)]}),_:2},1024)):e.createCommentVNode("",!0),_.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:1,class:"jump-out-icon"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0)],8,Lr))]}),_:1},8,["options"]),e.createElementVNode("div",Or,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.children,(_,ce)=>{var le;return e.openBlock(),e.createElementBlock("div",{class:"dropdown-body",key:ce,onMouseenter:Ne=>p(A),onMouseleave:s},[_.disabled?(e.openBlock(),e.createElementBlock("div",Dr,[e.createElementVNode("div",xr,[e.createElementVNode("span",null,e.toDisplayString(_.label),1),B[1]||(B[1]=e.createElementVNode("span",{class:"disabled-tag"},"待上线",-1))])])):e.withDirectives((e.openBlock(),e.createElementBlock("div",Tr,[e.createElementVNode("a",{href:D(_.href),class:"dropdown-link",target:L(_.href)?"_blank":"_self",rel:L(_.href)?"noopener noreferrer":""},[e.createElementVNode("span",null,e.toDisplayString(_.label),1),(o.tagMap[(le=_==null?void 0:_.href)==null?void 0:le.slice(1)]||_.tag)&&h(_.tagExpire,_.tagLang)?(e.openBlock(),e.createBlock(e.unref(i.OTag),{key:0,color:"danger",size:"small",round:"pill"},{default:e.withCtx(()=>{var Ne;return[e.createTextVNode(e.toDisplayString(o.tagMap[(Ne=_==null?void 0:_.href)==null?void 0:Ne.slice(1)]||_.tag),1)]}),_:2},1024)):e.createCommentVNode("",!0),_.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:1,class:"jump-out-icon"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0)],8,Ar)])),[[M,()=>S(_)]])],40,$r)}),128))])])]))],42,Br)),[[M,()=>R(x),"mouseenter"]])}),128))],36)],512)}}}),Mr=H._export_sfc(Ir,[["__scopeId","data-v-d7d33a36"]]),Rr={class:"header"},zr=["src"],Fr={key:0,class:"header-nav"},Pr={key:1,class:"header-content"},Hr={key:2,class:"header-toolbar"},Ur=e.defineComponent({__name:"OHeader",props:{logo:void 0,lang:void 0,community:void 0,navData:void 0,bgLeft:void 0,bgRight:void 0,tagMap:void 0},emits:["go-home"],setup(o,{emit:t}){const r=t,l=o,a=()=>{r("go-home")};return(c,m)=>(e.openBlock(),e.createElementBlock("div",Rr,[e.createVNode(ve,{class:"header-wrap"},{default:e.withCtx(()=>[e.createElementVNode("div",{class:"header-logo",onClick:a},[e.renderSlot(c.$slots,"logo",{},()=>[l.logo?(e.openBlock(),e.createElementBlock("img",{key:0,class:"logo",alt:"logo",src:l.logo},null,8,zr)):e.createCommentVNode("",!0)],!0)]),l.community==="openEuler"?(e.openBlock(),e.createElementBlock("div",Fr,[e.renderSlot(c.$slots,"nav",{},()=>[l.navData?(e.openBlock(),e.createBlock(Er,{key:0,"nav-data":l.navData,"bg-left":l.bgLeft,"bg-right":l.bgRight},null,8,["nav-data","bg-left","bg-right"])):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0),l.community==="openUBMC"?(e.openBlock(),e.createElementBlock("div",Pr,[e.renderSlot(c.$slots,"nav",{},()=>[l.navData?(e.openBlock(),e.createBlock(Mr,{key:0,"nav-data":l.navData,"has-perm":!0,"tag-map":o.tagMap},null,8,["nav-data","tag-map"])):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0),c.$slots.toolbar?(e.openBlock(),e.createElementBlock("div",Hr,[e.renderSlot(c.$slots,"toolbar",{},void 0,!0)])):e.createCommentVNode("",!0)]),_:3})]))}}),Jt=H._export_sfc(Ur,[["__scopeId","data-v-af43105c"]]),Wr={class:"header-content-mb"},Gr={class:"o-nav"},jr={class:"o-nav-list"},qr=["onClick"],Kr={class:"nav-aside"},Zr={key:0,class:"nav-aside-wrapper"},Yr=["value","title"],Xr={class:"content-label"},Jr={class:"container-mobile"},Qr=["onClick"],ea={class:"item-label"},ta={class:"desc-container"},oa={class:"item-desc"},na=["onClick"],ra={class:"item-label"},aa={key:1,class:"nav-aside-wrapper"},la=["onClick"],ca={class:"header-tool"},sa={key:1},ia=e.defineComponent({__name:"HeaderNavMoblie",props:{menuShow:{type:Boolean,default(){return!1}},navData:void 0,codeData:void 0},emits:["link-click"],setup(o,{emit:t}){const r=o,l=e.ref(""),a=e.ref({}),c=s=>{s?(l.value=s.id,a.value=s):(l.value="source_code",a.value=r.codeData)},m=t,p=(s,y)=>{window.open(s,y),m("link-click")};return e.onMounted(()=>{l.value=r.navData[0].id,a.value=r.navData[0]}),e.watch(()=>r.navData||r.codeData,()=>{a.value=l.value==="source_code"?r.codeData:r.navData.find(s=>s.id===l.value)},{deep:!0}),(s,y)=>(e.openBlock(),e.createElementBlock("div",Wr,[e.createElementVNode("div",{class:e.normalizeClass(["header-nav",{active:o.menuShow}])},[e.createElementVNode("div",Gr,[e.createElementVNode("ul",jr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.navData,u=>(e.openBlock(),e.createElementBlock("li",{key:u.id,class:e.normalizeClass({active:l.value===u.id})},[e.createElementVNode("span",{onClick:h=>c(u)},e.toDisplayString(u.label),9,qr)],2))),128))]),e.createElementVNode("div",Kr,[l.value!=="source_code"?(e.openBlock(),e.createElementBlock("ul",Zr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.value.children,u=>(e.openBlock(),e.createElementBlock("li",{value:u.label,title:u.label,key:u.label,class:"nav-aside-content"},[u!=null&&u.children?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("p",Xr,e.toDisplayString(u.label),1),e.createElementVNode("div",Jr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u==null?void 0:u.children,h=>(e.openBlock(),e.createElementBlock("div",{key:h.label,class:"content-container-mobile"},[e.createElementVNode("a",{onClick:V=>p(h.href,"_blank"),rel:"noopener noreferrer",class:"content-subtitle"},[e.createElementVNode("span",ea,e.toDisplayString(h.label),1),h.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0),h.tag?(e.openBlock(),e.createBlock(e.unref(i.OTag),{key:1,round:"pill",color:"danger",size:"small",class:"content-tag"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h.tag),1)]),_:2},1024)):e.createCommentVNode("",!0)],8,Qr),e.createElementVNode("div",ta,[e.createElementVNode("p",oa,e.toDisplayString(h.description),1)])]))),128))])],64)):(e.openBlock(),e.createElementBlock("a",{key:1,onClick:h=>p(u.href,"_blank"),rel:"noopener noreferrer",class:"content-subtitle item-not-children"},[e.createElementVNode("span",ra,e.toDisplayString(u.label),1),u.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0),u.tag?(e.openBlock(),e.createBlock(e.unref(i.OTag),{key:1,round:"pill",color:"danger",size:"small"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(u.tag),1)]),_:2},1024)):e.createCommentVNode("",!0)],8,na))],8,Yr))),128))])):(e.openBlock(),e.createElementBlock("div",aa,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.value,u=>(e.openBlock(),e.createElementBlock("a",{key:u.label,onClick:h=>p(u.href,"_blank"),class:"source-code-item"},[e.createElementVNode("span",null,e.toDisplayString(u.label),1),u.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0)],8,la))),128))]))])]),e.createElementVNode("div",ca,[o.codeData?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["header-tool-code",{active:l.value==="source_code"}]),onClick:y[0]||(y[0]=u=>c(null))}," 源码 ",2)):e.createCommentVNode("",!0),s.$slots.tool?(e.openBlock(),e.createElementBlock("div",sa,[e.renderSlot(s.$slots,"tool",{},void 0,!0)])):e.createCommentVNode("",!0)])],2)]))}}),da=H._export_sfc(ia,[["__scopeId","data-v-bd38af58"]]),ua={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function ma(o,t){return e.openBlock(),e.createElementBlock("svg",ua,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"currentColor",d:"M18.528 5.472c0.246 0.246 0.271 0.63 0.074 0.903l-0.074 0.087-5.54 5.538 0.006 0.006-0.989 0.989-0.006-0.006-5.538 5.54c-0.273 0.273-0.717 0.273-0.99 0-0.246-0.246-0.271-0.63-0.074-0.903l0.074-0.087 5.538-5.539-5.538-5.538-0.074-0.087c-0.197-0.274-0.172-0.657 0.074-0.903s0.63-0.271 0.903-0.074l0.087 0.074 5.538 5.539 5.539-5.539c0.273-0.273 0.717-0.273 0.99 0zM14.551 13.561l3.978 3.978 0.074 0.087c0.197 0.274 0.172 0.657-0.074 0.903s-0.63 0.271-0.903 0.074l-0.087-0.074-3.978-3.978c-0.273-0.273-0.273-0.717 0-0.99v0c0.273-0.273 0.717-0.273 0.99 0z"},null,-1)])])}const Qt={name:"components-icon-close",render:ma},pa={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function fa(o,t){return e.openBlock(),e.createElementBlock("svg",pa,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"currentColor",d:"M3.8 5h16.4c0.442 0 0.8 0.359 0.8 0.8s-0.358 0.8-0.8 0.8h-16.4c-0.442 0-0.8-0.358-0.8-0.8s0.358-0.8 0.8-0.8zM3.8 11h16.4c0.442 0 0.8 0.359 0.8 0.8s-0.358 0.8-0.8 0.8h-16.4c-0.442 0-0.8-0.358-0.8-0.8s0.358-0.8 0.8-0.8zM3.8 17h16.4c0.442 0 0.8 0.358 0.8 0.8s-0.358 0.8-0.8 0.8h-16.4c-0.442 0-0.8-0.359-0.8-0.8s0.358-0.8 0.8-0.8z"},null,-1)])])}const ha={name:"components-icon-header-menu",render:fa},va={class:"header"},ka={key:0,class:"header-simple"},ga={class:"simple-header-left"},Ca={key:0,class:"header-title"},_a={key:0,class:"simple-header-right"},ya={class:"header-left"},Ea={class:"header-center"},Ba=["src"],Na={class:"header-right"},wa=e.defineComponent({__name:"OHeaderMoblie",props:{logo:void 0,navData:void 0,codeData:void 0,isSimpleHeader:void 0,headerTitle:void 0},emits:["go-back","go-home"],setup(o,{emit:t}){const r=t,l=o,a=()=>{r("go-back")},c=()=>{r("go-home")},m=e.ref(!1),p=()=>{setTimeout(()=>{m.value=!m.value,document.body.style.overflow=m.value?"hidden":""},200)},s=()=>{p()};return(y,u)=>(e.openBlock(),e.createElementBlock("div",va,[e.createVNode(ve,{class:"header-wrap"},{default:e.withCtx(()=>[o.isSimpleHeader?(e.openBlock(),e.createElementBlock("div",ka,[e.createElementVNode("div",ga,[e.createVNode(e.unref(i.OIcon),{onClick:a},{default:e.withCtx(()=>[e.createVNode(e.unref(i.OIconArrowLeft))]),_:1}),o.headerTitle?(e.openBlock(),e.createElementBlock("div",Ca,e.toDisplayString(o.headerTitle),1)):e.createCommentVNode("",!0)]),y.$slots.rightConfig?(e.openBlock(),e.createElementBlock("div",_a,[e.renderSlot(y.$slots,"rightConfig",{},void 0,!0)])):e.createCommentVNode("",!0)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",ya,[e.createVNode(e.unref(i.OIcon),{onClick:p},{default:e.withCtx(()=>[m.value?(e.openBlock(),e.createBlock(e.unref(Qt),{key:1})):(e.openBlock(),e.createBlock(e.unref(ha),{key:0}))]),_:1})]),e.createVNode(da,{ref:"mobileNav","nav-data":o.navData,"code-data":o.codeData,"menu-show":m.value,onLinkClick:s},{tool:e.withCtx(()=>[e.renderSlot(y.$slots,"tool",{},void 0,!0)]),_:3},8,["nav-data","code-data","menu-show"]),e.createElementVNode("div",Ea,[e.createElementVNode("div",{class:"header-logo",onClick:c},[e.renderSlot(y.$slots,"logo",{},()=>[l.logo?(e.openBlock(),e.createElementBlock("img",{key:0,class:"logo",alt:"logo",src:l.logo},null,8,Ba)):e.createCommentVNode("",!0)],!0)])]),e.createElementVNode("div",Na,[e.renderSlot(y.$slots,"toolbar",{},void 0,!0)])],64))]),_:3})]))}}),eo=H._export_sfc(wa,[["__scopeId","data-v-bf633ce0"]]),Va={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function Sa(o,t){return e.openBlock(),e.createElementBlock("svg",Va,[...t[0]||(t[0]=[e.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M13.215 0.524c-7.048 0-12.762 5.714-12.762 12.762s5.714 12.762 12.762 12.762c7.048 0 12.762-5.714 12.762-12.762s-5.714-12.762-12.762-12.762zM13.215 2.809c5.786 0 10.476 4.69 10.476 10.476s-4.69 10.476-10.476 10.476c-5.786 0-10.476-4.69-10.476-10.476s4.69-10.476 10.476-10.476z"},null,-1),e.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M23.33 23.22c0.446-0.447 1.169-0.448 1.616-0.002l4.771 4.759c0.447 0.446 0.448 1.169 0.002 1.616s-1.169 0.448-1.616 0.002l-4.771-4.759c-0.447-0.446-0.448-1.169-0.002-1.616z"},null,-1)])])}const It={name:"components-icon-header-search",render:Sa},ba={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function La(o,t){return e.openBlock(),e.createElementBlock("svg",ba,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"currentColor",d:"M10.858 22.41c-0.349 0.349-0.915 0.349-1.263 0-0.314-0.314-0.345-0.804-0.094-1.153l0.094-0.111 5.146-5.15-5.177-5.178c-0.274-0.305-0.3-0.755-0.077-1.087l0.111-0.135c0.347-0.347 0.91-0.347 1.257 0l5.142 5.143 5.15-5.146c0.349-0.349 0.915-0.349 1.263 0 0.314 0.314 0.345 0.804 0.094 1.153l-0.094 0.111-11.552 11.552zM17.89 16.634l4.551 4.552c0.313 0.349 0.302 0.886-0.034 1.222-0.347 0.347-0.91 0.347-1.257 0l-4.516-4.518 1.256-1.256z"},null,-1)])])}const Oa={name:"components-icon-header-delete",render:La},$a={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function Da(o,t){return e.openBlock(),e.createElementBlock("svg",$a,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"currentColor",d:"M19.154 5.295c0.387 0 0.7 0.313 0.7 0.7 0 0.354-0.263 0.647-0.605 0.694l-0.095 0.006-12.201-0.001 0.001 12.413c0 0.17 0.12 0.311 0.28 0.344l0.071 0.007h9.39c0.17 0 0.311-0.12 0.344-0.28l0.007-0.071v-10.47c0-0.387 0.313-0.7 0.7-0.7 0.354 0 0.647 0.263 0.694 0.605l0.006 0.095v10.47c0 0.919-0.708 1.672-1.608 1.745l-0.144 0.006h-9.39c-0.919 0-1.672-0.708-1.745-1.608l-0.006-0.144-0.001-12.413-0.707 0.001c-0.387 0-0.7-0.313-0.7-0.7 0-0.354 0.263-0.647 0.605-0.694l0.095-0.006h14.308zM10.011 9.744c0.354 0 0.647 0.263 0.694 0.605l0.006 0.095v5.68c0 0.387-0.313 0.7-0.7 0.7-0.354 0-0.647-0.263-0.694-0.605l-0.006-0.095v-5.68c0-0.387 0.313-0.7 0.7-0.7zM13.953 9.744c0.354 0 0.647 0.263 0.694 0.605l0.006 0.095v5.68c0 0.387-0.313 0.7-0.7 0.7-0.354 0-0.647-0.263-0.694-0.605l-0.006-0.095v-5.68c0-0.387 0.313-0.7 0.7-0.7zM13.652 3.189c0.387 0 0.7 0.313 0.7 0.7 0 0.354-0.263 0.647-0.605 0.694l-0.095 0.006h-3.972c-0.387 0-0.7-0.313-0.7-0.7 0-0.354 0.263-0.647 0.605-0.694l0.095-0.006h3.972z"},null,-1)])])}const xa={name:"components-icon-delete",render:Da},Ta={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"36",height:"32",viewBox:"0 0 36 32"};function Aa(o,t){return e.openBlock(),e.createElementBlock("svg",Ta,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"currentColor",d:"M5.886 19.111l10.672 10.677c0.46 0.524 0.44 1.322-0.060 1.822s-1.298 0.52-1.822 0.060l-0.064-0.060-12.498-12.498h3.772zM14.613 0.391c0.521-0.521 1.365-0.521 1.886 0 0.5 0.5 0.52 1.298 0.060 1.822l-0.060 0.064-12.391 12.391h29.67c0.71 0 1.291 0.555 1.331 1.255l0.002 0.078c0 0.71-0.555 1.291-1.255 1.331l-0.078 0.002h-31.816c-0.472 0-0.924-0.187-1.257-0.521-0.671-0.671-0.694-1.745-0.067-2.443l0.067-0.071 13.908-13.908z"},null,-1)])])}const Ia={name:"components-icon-header-back",render:Aa},Ma={class:"o-header-search"},Ra={class:"o-header-search-drawer"},za={key:0,class:"o-header-search-recommend-container"},Fa=["onClick"],Pa={key:1,class:"o-header-search-history-container"},Ha={class:"o-header-search-history-header"},Ua={class:"o-header-search-history-header-title"},Wa={class:"o-header-search-history-item-container"},Ga=["onClick"],ja={class:"o-header-search-history-item-text"},qa={key:3,class:"o-header-search-hot-container"},Ka={class:"o-header-search-hot-header"},Za={class:"o-header-search-hot-item-container"},Ya=["onClick"],Xa=e.defineComponent({__name:"OHeaderSearch",props:{modelValue:{default:""},placeholder:{},expandedPlaceholder:{},expandDirection:{default:"left"},clearable:{type:Boolean,default:!0},historyItems:{default:()=>[]},maxHistoryCount:{default:6},storeHistory:{type:Boolean,default:!1},historyTitle:{},storageKey:{default:"search-history"},hotItems:{default:()=>[]},hotTitle:{},recommendItems:{default:()=>[]},searchUrl:{},searchUrlOpenBlank:{type:Boolean,default:!0},searchTextMobile:{}},emits:["update:modelValue","update:historyItems","clear","search","delete-history","delete-history-item"],setup(o,{emit:t}){const{lePadV:r}=Q.useScreen(),{t:l}=H.useI18n(),a=o,c=t,m=e.ref(a.modelValue),p=e.ref(a.historyItems),s=e.ref(!1),y=e.ref(),u=e.computed(()=>!r.value&&s.value||r.value&&m.value);e.watch(()=>a.modelValue,g=>{m.value!==g&&(m.value=g)}),e.watch(()=>m.value,g=>{c("update:modelValue",g)}),e.watch(()=>a.historyItems,g=>{p.value!==g&&(p.value=g)}),e.watch(()=>p.value,g=>{c("update:historyItems",g)}),e.onMounted(()=>{if(a.storeHistory&&a.storageKey)try{const g=JSON.parse(localStorage.getItem(a.storageKey)||"[]");Array.isArray(g)&&g.length&&(p.value=Array.from(new Set([...p.value,...g])))}catch{}});const h=()=>{s.value=!0},V=()=>{const g=m.value.trim();g&&(s.value=!1,p.value.unshift(g),p.value=Array.from(new Set(p.value)),p.value.length>a.maxHistoryCount&&p.value.pop(),a.storeHistory&&a.storeHistory&&localStorage.setItem(a.storageKey,JSON.stringify(p.value)),c("search",g),a.searchUrl&&window.open(a.searchUrl+g,a.searchUrlOpenBlank?"_blank":"_self","noopener noreferrer"))},E=()=>{m.value="",c("clear"),r.value||(s.value=!1)},N=()=>{const g=[...p.value];p.value=[],a.storeHistory&&a.storeHistory&&localStorage.removeItem(a.storageKey),c("delete-history",g)},w=g=>{p.value=p.value.filter(L=>L!==g),a.storeHistory&&a.storeHistory&&(p.value.length?localStorage.setItem(a.storageKey,JSON.stringify(p.value)):localStorage.removeItem(a.storageKey)),c("delete-history-item",g)},k=g=>{m.value=g,V()},S=()=>{m.value="",s.value=!1},R=e.ref();return pt.onClickOutside(R,E),(g,L)=>(e.openBlock(),e.createElementBlock("div",Ma,[e.createElementVNode("div",{ref_key:"posWrapper",ref:R,class:e.normalizeClass({"o-header-search-input-pc-wrapper":!e.unref(r),"o-header-search-input-pc-wrapper-left":!e.unref(r)&&o.expandDirection==="left","o-header-search-input-pc-wrapper-right":!e.unref(r)&&o.expandDirection==="right","o-header-search-input-mobile-wrapper":e.unref(r),focus:s.value})},[e.createElementVNode("div",{class:e.normalizeClass(["o-header-search-input-wrapper",{focus:s.value}])},[e.unref(r)&&s.value?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0,class:"o-header-search-icon",onClick:S},{default:e.withCtx(()=>[e.createVNode(e.unref(Ia))]),_:1})):e.createCommentVNode("",!0),e.createVNode(e.unref(i.OInput),{ref_key:"inputRef",ref:y,modelValue:m.value,"onUpdate:modelValue":L[0]||(L[0]=O=>m.value=O),class:"o-header-search-input",placeholder:s.value?o.expandedPlaceholder??e.unref(l)("search.expandedPlaceholder"):o.placeholder??e.unref(l)("search.placeholder"),onFocus:h,onKeyup:e.withKeys(V,["enter"])},{prefix:e.withCtx(()=>[e.renderSlot(g.$slots,"input-prefix",{},()=>[e.createVNode(e.unref(i.OIcon),{class:"o-header-search-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(It))]),_:1})],!0)]),suffix:e.withCtx(()=>[e.renderSlot(g.$slots,"input-suffix",{},()=>[o.clearable&&u.value?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0,class:"o-header-search-icon close",onClick:E},{default:e.withCtx(()=>[e.createVNode(e.unref(Qt))]),_:1})):e.createCommentVNode("",!0)],!0)]),_:3},8,["modelValue","placeholder"]),e.unref(r)&&s.value?(e.openBlock(),e.createElementBlock("span",{key:1,class:"o-header-search-text",onClick:V},e.toDisplayString(o.searchTextMobile??e.unref(l)("search")),1)):e.createCommentVNode("",!0)],2),e.withDirectives(e.createElementVNode("div",Ra,[e.renderSlot(g.$slots,"drawer",{recommendItems:o.recommendItems,historyItems:p.value,hotItems:o.hotItems},()=>[o.recommendItems.length?(e.openBlock(),e.createElementBlock("div",za,[e.renderSlot(g.$slots,"recommend-header",{recommend:o.recommendItems},void 0,!0),e.renderSlot(g.$slots,"recommend-content",{recommend:o.recommendItems},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.recommendItems,O=>(e.openBlock(),e.createElementBlock("div",{class:"o-header-search-recommend-item",key:O,onClick:$=>k(O)},e.toDisplayString(O),9,Fa))),128))],!0)])):p.value.length?(e.openBlock(),e.createElementBlock("div",Pa,[e.renderSlot(g.$slots,"history-header",{history:p.value},()=>[e.createElementVNode("div",Ha,[e.createElementVNode("span",Ua,e.toDisplayString(o.historyTitle??e.unref(l)("search.history")),1),e.createVNode(e.unref(i.OIcon),{class:"o-header-search-icon",onClick:N},{default:e.withCtx(()=>[e.createVNode(e.unref(xa))]),_:1})])],!0),e.renderSlot(g.$slots,"history-content",{history:p.value},()=>[e.createElementVNode("div",Wa,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,O=>(e.openBlock(),e.createElementBlock("div",{key:O,class:"o-header-search-history-item",onClick:$=>k(O)},[e.createElementVNode("span",ja,e.toDisplayString(O),1),e.createVNode(e.unref(i.OIcon),{class:"o-header-search-history-item-icon",onClick:e.withModifiers($=>w(O),["stop"])},{default:e.withCtx(()=>[e.createVNode(e.unref(Oa),{class:"icon-delete"})]),_:1},8,["onClick"])],8,Ga))),128))])],!0)])):e.createCommentVNode("",!0),(o.recommendItems.length||p.value.length)&&o.hotItems.length?(e.openBlock(),e.createBlock(e.unref(i.ODivider),{key:2,class:"o-header-search-drawer-divider"})):e.createCommentVNode("",!0),o.hotItems.length?(e.openBlock(),e.createElementBlock("div",qa,[e.renderSlot(g.$slots,"hot-header",{hot:o.hotItems},()=>[e.createElementVNode("div",Ka,e.toDisplayString(o.hotTitle??e.unref(l)("search.hot")),1)],!0),e.renderSlot(g.$slots,"hot-content",{hot:o.hotItems},()=>[e.createElementVNode("div",Za,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.hotItems,O=>(e.openBlock(),e.createElementBlock("div",{key:O,class:"o-header-search-hot-item",onClick:$=>k(O)},e.toDisplayString(O),9,Ya))),128))])],!0)])):e.createCommentVNode("",!0)],!0)],512),[[e.vShow,s.value]])],2),e.unref(r)?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0,class:"o-header-search-icon-mobile",onClick:h},{default:e.withCtx(()=>[e.createVNode(e.unref(It))]),_:1})):e.createCommentVNode("",!0)]))}}),to=H._export_sfc(Xa,[["__scopeId","data-v-9f1bd8fc"]]),Ja=["src"],Qa=e.defineComponent({__name:"AppAvatar",props:{avatar:{type:String,default:""},name:{type:String,default:"",required:!0},size:{type:String,default:"medium"},customSize:{type:Number,default:0},variant:{type:String,default:"round"}},setup(o){const t=o,r=["#058EF0","#FA7305","#03B5A5"],l=e.computed(()=>{var c;return(c=t.name)==null?void 0:c.charAt(0).toUpperCase()}),a=e.computed(()=>{var p;const c={"background-color":"",width:"32px",height:"32px","font-size":"20px"};c["background-color"]=t.name?r[((p=t.name)==null?void 0:p.length)%r.length]:"transparent";let m=0;return t.customSize?m=Number(t.customSize):m={mini:16,small:24,medium:40,large:64}[t.size],c.height=`${m}px`,c.width=`${m}px`,c["font-size"]=`${m/2}px`,c});return(c,m)=>o.avatar&&!o.avatar.includes("gitcode")?(e.openBlock(),e.createElementBlock("img",{key:0,src:o.avatar,class:e.normalizeClass(["img-avatar",o.variant]),style:e.normalizeStyle(a.value),alt:""},null,14,Ja)):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["word-avatar",o.variant]),style:e.normalizeStyle(a.value)},e.toDisplayString(l.value),7))}}),Mt=H._export_sfc(Qa,[["__scopeId","data-v-340348ce"]]),el={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function tl(o,t){return e.openBlock(),e.createElementBlock("svg",el,[...t[0]||(t[0]=[e.createElementVNode("path",{opacity:"0.8",fill:"#000",d:"M9.412 10.332c0 2.188 1.066 4.127 2.708 5.326-4.858 1.582-8.364 6.052-8.364 11.328 0 0.515 0.418 0.933 0.933 0.933s0.933-0.418 0.933-0.933c0-5.465 4.487-9.922 10.092-10.070 0.095 0.004 0.191 0.006 0.288 0.006 3.639 0 6.59-2.95 6.59-6.59s-2.951-6.59-6.59-6.59-6.59 2.95-6.59 6.59zM16.088 15.049c-0.028-0.003-0.057-0.004-0.087-0.004-0.061 0-0.122 0-0.183 0.001-2.524-0.096-4.541-2.172-4.541-4.72 0-2.608 2.115-4.723 4.723-4.723s4.723 2.115 4.723 4.723c0 2.579-2.067 4.676-4.635 4.722zM21.784 16.465c3.945 2.064 6.463 6.077 6.463 10.528 0 0.515-0.418 0.933-0.933 0.933s-0.933-0.418-0.933-0.933c0-3.744-2.123-7.127-5.462-8.874-0.457-0.239-0.633-0.803-0.394-1.26s0.803-0.633 1.26-0.394z"},null,-1)])])}const ol={name:"components-icon-avatar-line",render:tl},nl={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function rl(o,t){return e.openBlock(),e.createElementBlock("svg",nl,[...t[0]||(t[0]=[e.createElementVNode("path",{d:"M5.759 8.873c0.251-0.251 0.644-0.271 0.918-0.063l0.072 0.063 5.016 5.016c0.1 0.1 0.254 0.115 0.37 0.043l0.054-0.043 5.062-5.062c0.273-0.273 0.717-0.273 0.99 0 0.251 0.251 0.271 0.644 0.063 0.918l-0.063 0.072-5.062 5.062c-0.629 0.629-1.628 0.662-2.296 0.099l-0.108-0.099-5.016-5.016c-0.273-0.273-0.273-0.717 0-0.99z"},null,-1)])])}const oo={name:"components-icon-chevron-down",render:rl},al={class:"header-user"},ll={key:0,class:"user-info"},cl={class:"info-wrap hover-icon-rotate"},sl={class:"user-account"},il={key:0,class:"user-info-dropdown"},dl={class:"right-info"},ul={class:"user-account"},ml={key:1},pl=e.defineComponent({__name:"OHeaderUser",props:{token:{default:void 0},lang:{default:void 0},noticeTotal:{default:void 0},userInfo:{default:void 0},userInfoVisible:{type:Boolean,default:void 0},options:{default:void 0}},emits:["login","logout"],setup(o,{emit:t}){const{lePadV:r}=Q.useScreen(),l=t,a=()=>{l("login")},c=m=>{m!=null&&m.logout?l("logout"):window.open(m.url,m.target)};return(m,p)=>(e.openBlock(),e.createElementBlock("div",al,[o.token?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0,onClick:a,class:"avatar-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(ol))]),_:1})),e.createVNode(e.Transition,{name:"header-user-zoom-in"},{default:e.withCtx(()=>[o.token?(e.openBlock(),e.createElementBlock("div",ll,[e.createVNode(e.unref(i.ODropdown),{trigger:e.unref(r)?"click":"hover",optionPosition:e.unref(r)?"br":"bottom","option-wrap-class":`user-dropdown ${o.lang==="en"?"is-en":""} user-dropdown${o.userInfoVisible?"-info":""}`},{dropdown:e.withCtx(()=>[o.userInfoVisible?(e.openBlock(),e.createElementBlock("div",il,[e.createVNode(Mt,{avatar:o.userInfo.photo,name:o.userInfo.username,"custom-size":32},null,8,["avatar","name"]),e.createElementVNode("div",dl,[p[0]||(p[0]=e.createElementVNode("p",{class:"user-fullname"},"用户名",-1)),e.createElementVNode("p",ul,e.toDisplayString(o.userInfo.username),1)])])):e.createCommentVNode("",!0),o.userInfoVisible?(e.openBlock(),e.createBlock(e.unref(i.ODivider),{key:1,style:{"--o-divider-gap":"6px"}})):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.options,s=>(e.openBlock(),e.createBlock(e.unref(i.ODropdownItem),{key:s.label,style:e.normalizeStyle({"--dropdown-item-justify":o.userInfoVisible?"flex-start":"center"}),onClick:y=>c(s)},{default:e.withCtx(()=>[s!=null&&s.icon?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(e.unref(i.OBadge),{value:s.total,color:"danger",class:e.normalizeClass(["header-message icon-message",{"notice-not":!s.total}])},{default:e.withCtx(()=>[e.createVNode(e.unref(i.OIcon),null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(s.icon),{class:"icon"}))]),_:2},1024)]),_:2},1032,["value","class"]),e.createElementVNode("span",null,e.toDisplayString(s.label),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[s!=null&&s.total?(e.openBlock(),e.createBlock(e.unref(i.OBadge),{key:0,value:s.total,color:"danger",class:e.normalizeClass(["header-message message",{"notice-not":!s.total}])},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(s.label),1)]),_:2},1032,["value","class"])):(e.openBlock(),e.createElementBlock("span",ml,e.toDisplayString(s.label),1))],64))]),_:2},1032,["style","onClick"]))),128))]),default:e.withCtx(()=>[e.createElementVNode("div",cl,[e.createVNode(e.unref(i.OBadge),{value:o.noticeTotal,color:"danger",class:e.normalizeClass(["header-message user-avatar",{"notice-not":!o.noticeTotal}])},{default:e.withCtx(()=>[e.createVNode(Mt,{avatar:o.userInfo.photo,name:o.userInfo.username,"custom-size":e.unref(r)?24:32},null,8,["avatar","name","custom-size"])]),_:1},8,["value","class"]),e.createElementVNode("p",sl,e.toDisplayString(o.userInfo.username),1),e.createVNode(e.unref(i.OIcon),{class:"icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(oo))]),_:1})])]),_:1},8,["trigger","optionPosition","option-wrap-class"])])):e.createCommentVNode("",!0)]),_:1})]))}}),no=H._export_sfc(pl,[["__scopeId","data-v-66736d3f"]]),fl={locale:"zh-CN","common.empty":"暂无数据","common.loading":"加载中...","pagination.goto":"前往","pagination.page":"页","pagination.countPerPage":"条/页","pagination.total":"共 {0} 条","upload.buttonLabel":"点击上传","upload.drag":"点击或拖拽文件到此处上传","upload.dragHover":"释放文件并开始上传","upload.retry":"点击重试","upload.delete":"删除","upload.preview":"预览","upload.edit":"编辑","select.cancel":"取消","select.confirm":"确定","input.limit":"<b>{0}</b>/{1}"},hl={locale:"en-US","common.empty":"No Data","common.loading":"Loading...","pagination.goto":"Go to","pagination.page":"Page","pagination.countPerPage":"/page","pagination.total":"Total: {0}","upload.buttonLabel":"Upload","upload.drag":"Click or drag file to this area to upload","upload.dragHover":"Release to upload","upload.retry":"Click to retry","upload.delete":"Delete","upload.preview":"Preview","upload.edit":"Edit","select.cancel":"Cancel","select.confirm":"Ok","input.limit":"<b>{0}</b>/{1}"},ro=e.defineComponent({__name:"OPlusConfigProvider",props:{locale:{},theme:{default:"light"}},setup(o){const t=o,r=e.reactive({locale:e.computed(()=>t.locale),theme:e.computed(()=>t.theme)});return e.provide(H.configProviderInjectKey,r),(l,a)=>(e.openBlock(),e.createBlock(e.unref(i.OConfigProvider),{locale:o.locale==="zh"?e.unref(fl):e.unref(hl)},{default:e.withCtx(()=>[e.renderSlot(l.$slots,"default")]),_:3},8,["locale"]))}}),vl={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function kl(o,t){return e.openBlock(),e.createElementBlock("svg",vl,[...t[0]||(t[0]=[e.createElementVNode("path",{d:"M9.246 5.764c-0.251 0.251-0.271 0.644-0.063 0.918l0.063 0.072 5.016 5.016c0.1 0.1 0.115 0.254 0.043 0.37l-0.043 0.054-5.062 5.062c-0.273 0.273-0.273 0.717 0 0.99 0.251 0.251 0.644 0.271 0.918 0.063l0.072-0.063 5.062-5.062c0.629-0.629 0.662-1.628 0.099-2.296l-0.099-0.108-5.016-5.016c-0.273-0.273-0.717-0.273-0.99 0z"},null,-1)])])}const gl={name:"components-icon-chevron-right",render:kl},Cl={class:"section-wrapper"},_l={key:1,class:"section-title"},yl={key:2,class:"section-subtitle"},El={key:1,class:"section-body"},Bl={key:2,class:"section-footer"},Nl=e.defineComponent({__name:"OSection",props:{title:{default:void 0},subtitle:{default:void 0},full:{type:Boolean,default:!1},headerJustifyCenter:{type:Boolean,default:!0},footer:{default:void 0},footerHref:{default:void 0}},setup(o){const t=o;return(r,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["app-section",{"is-full":t.full}])},[e.createElementVNode("div",Cl,[e.renderSlot(r.$slots,"main",{},()=>[r.$slots.header||t.title||t.subtitle?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["section-header",{"is-left":!t.headerJustifyCenter}])},[e.renderSlot(r.$slots,"header",{},()=>[e.unref(i.isArray)(t.title)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.title,a=>(e.openBlock(),e.createElementBlock("h2",{key:a,class:"section-title"},e.toDisplayString(a),1))),128)):r.$slots.title||t.title?(e.openBlock(),e.createElementBlock("h2",_l,[e.renderSlot(r.$slots,"title",{},()=>[e.createTextVNode(e.toDisplayString(t.title),1)],!0)])):e.createCommentVNode("",!0),r.$slots.subtitle||t.subtitle?(e.openBlock(),e.createElementBlock("p",yl,[e.renderSlot(r.$slots,"subtitle",{},()=>[e.createTextVNode(e.toDisplayString(t.subtitle),1)],!0)])):e.createCommentVNode("",!0)],!0)],2)):e.createCommentVNode("",!0),r.$slots.default?(e.openBlock(),e.createElementBlock("div",El,[e.renderSlot(r.$slots,"default",{},void 0,!0)])):e.createCommentVNode("",!0),r.$slots.footer||t.footer?(e.openBlock(),e.createElementBlock("div",Bl,[e.renderSlot(r.$slots,"footer",{},()=>[e.createVNode(e.unref(i.OLink),{href:t.footerHref,target:"_blank"},{suffix:e.withCtx(()=>[e.createVNode(e.unref(i.OIcon),{class:"footer-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(gl))]),_:1})]),default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.footer)+" ",1)]),_:1},8,["href"])],!0)])):e.createCommentVNode("",!0)],!0)])],2))}}),ao=H._export_sfc(Nl,[["__scopeId","data-v-2fc90e8a"]]),wl={class:"source-code"},Vl={key:0,class:"info-wrap"},Sl={class:"title"},bl={class:"info-wrap hover-icon-rotate"},Ll={class:"title"},Ol=e.defineComponent({__name:"OSourceCode",props:{title:{default:void 0},options:{default:void 0},url:{default:void 0},icon:{default:void 0},justify:{default:"center"}},setup(o){const t=a=>{window.open(a.url,"_blank")},r=e.ref(!1),l=a=>{r.value=a};return(a,c)=>(e.openBlock(),e.createElementBlock("div",wl,[o.url?(e.openBlock(),e.createElementBlock("div",Vl,[e.createElementVNode("span",Sl,e.toDisplayString(o.title),1),o.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.icon),{class:"icon"}))]),_:1})):e.createCommentVNode("",!0)])):(e.openBlock(),e.createBlock(e.unref(i.ODropdown),{key:1,trigger:"hover",optionPosition:"bottom","option-wrap-class":"dropdown",class:e.normalizeClass({"dropdown-active":r.value}),onVisibleChange:l},{dropdown:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.options,m=>(e.openBlock(),e.createBlock(e.unref(i.ODropdownItem),{onClick:p=>t(m),key:m.url,class:"list",style:e.normalizeStyle({"--dropdown-item-justify":o.justify})},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m.label)+" ",1),m.icon?(e.openBlock(),e.createBlock(e.unref(i.OIcon),{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.icon),{class:"icon"}))]),_:2},1024)):e.createCommentVNode("",!0)]),_:2},1032,["onClick","style"]))),128))]),default:e.withCtx(()=>[e.createElementVNode("div",bl,[e.createElementVNode("span",Ll,e.toDisplayString(o.title),1),e.createVNode(e.unref(i.OIcon),{class:"icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(oo))]),_:1})])]),_:1},8,["class"]))]))}}),lo=H._export_sfc(Ol,[["__scopeId","data-v-bbe28df5"]]),$l={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function Dl(o,t){return e.openBlock(),e.createElementBlock("svg",$l,[...t[0]||(t[0]=[e.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M12 1.992c0.387 0 0.7 0.313 0.7 0.7v1.2c0 0.387-0.313 0.7-0.7 0.7s-0.7-0.313-0.7-0.7v-1.2c0-0.387 0.313-0.7 0.7-0.7zM6.769 6.747c-0.273 0.273-0.717 0.273-0.99 0l-0.849-0.849c-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495c0.273-0.273 0.717-0.273 0.99 0l0.849 0.849c0.136 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495zM18.192 6.747c-0.273 0.273-0.717 0.273-0.99 0-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495l0.849-0.849c0.273-0.273 0.717-0.273 0.99 0 0.137 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495l-0.849 0.849zM5.3 12c0-3.7 3-6.7 6.7-6.7s6.7 3 6.7 6.7-3 6.7-6.7 6.7c-3.7 0-6.7-3-6.7-6.7zM17.3 12c0-2.927-2.373-5.3-5.3-5.3s-5.3 2.373-5.3 5.3c0 2.927 2.373 5.3 5.3 5.3s5.3-2.373 5.3-5.3zM4.594 11.969c0 0.387-0.313 0.7-0.7 0.7h-1.2c-0.387 0-0.7-0.313-0.7-0.7s0.313-0.7 0.7-0.7h1.2c0.386 0 0.7 0.313 0.7 0.7zM21.977 11.999c0 0.387-0.314 0.7-0.7 0.7h-1.2c-0.387 0-0.7-0.313-0.7-0.7s0.313-0.7 0.7-0.7h1.2c0.387 0 0.7 0.313 0.7 0.7zM5.921 19.060c-0.273 0.273-0.717 0.273-0.99 0-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495l0.849-0.849c0.273-0.273 0.717-0.273 0.99 0 0.137 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495l-0.849 0.849zM19.041 19.060c-0.273 0.273-0.717 0.273-0.99 0l-0.849-0.849c-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495c0.273-0.273 0.717-0.273 0.99 0l0.849 0.849c0.137 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495zM11.971 19.376c0.387 0 0.7 0.313 0.7 0.7v1.2c0 0.387-0.313 0.7-0.7 0.7s-0.7-0.313-0.7-0.7v-1.2c0-0.387 0.313-0.7 0.7-0.7z"},null,-1)])])}const ot={name:"components-icon-sun",render:Dl},xl={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function Tl(o,t){return e.openBlock(),e.createElementBlock("svg",xl,[...t[0]||(t[0]=[e.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M12 2.3c5.357 0 9.7 4.343 9.7 9.7s-4.343 9.7-9.7 9.7c-4.651 0-8.622-3.298-9.515-7.806-0.101-0.509 0.369-0.948 0.87-0.812 0.531 0.144 1.082 0.218 1.645 0.218 3.479 0 6.3-2.82 6.3-6.3 0-1.276-0.379-2.494-1.079-3.527-0.291-0.43-0.029-1.016 0.486-1.086 0.425-0.057 0.857-0.086 1.293-0.086zM12 3.7l-0.042 0.001 0.058 0.121c0.402 0.887 0.634 1.85 0.677 2.845l0.007 0.333c0 4.253-3.447 7.7-7.7 7.7-0.229 0-0.457-0.010-0.682-0.030l-0.186-0.021 0.076 0.218c1.147 3.123 4.102 5.321 7.528 5.429l0.264 0.004c4.584 0 8.3-3.716 8.3-8.3s-3.716-8.3-8.3-8.3z"},null,-1)])])}const nt={name:"components-icon-moon",render:Tl},Al={class:"o-theme-switcher"},Il={key:1,class:"o-theme-switcher-mobile"},Ml=e.defineComponent({__name:"OThemeSwitcher",props:{theme:{default:"light"},type:{default:"auto"},lightValue:{default:"light"},darkValue:{default:"dark"},lightIcon:{default:ot},darkIcon:{default:nt}},emits:["update:theme","change"],setup(o,{emit:t}){const r=o,l=t,{gtPhone:a}=Q.useScreen(),c=e.computed({get(){return r.theme},set(s){l("update:theme",s),l("change",s)}}),m=e.computed(()=>r.type==="common"||r.type==="auto"&&a.value),p=()=>{c.value=c.value===r.lightValue?r.darkValue:r.lightValue};return(s,y)=>(e.openBlock(),e.createElementBlock("div",Al,[m.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"o-theme-switcher-common",onClick:p},[e.createVNode(e.unref(i.OIcon),{class:"o-theme-icon"},{default:e.withCtx(()=>[c.value===o.lightValue?(e.openBlock(),e.createBlock(e.unref(nt),{key:0})):(e.openBlock(),e.createBlock(e.unref(ot),{key:1}))]),_:1})])):(e.openBlock(),e.createElementBlock("div",Il,[e.createVNode(e.unref(i.OSwitch),{modelValue:c.value,"onUpdate:modelValue":y[0]||(y[0]=u=>c.value=u),class:"o-theme-switch","checked-value":o.darkValue,"unchecked-value":o.lightValue},{on:e.withCtx(()=>[e.createVNode(e.unref(i.OIcon),{class:"o-theme-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(ot))]),_:1})]),off:e.withCtx(()=>[e.createVNode(e.unref(i.OIcon),{class:"o-theme-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(nt))]),_:1})]),_:1},8,["modelValue","checked-value","unchecked-value"])]))]))}}),co=H._export_sfc(Ml,[["__scopeId","data-v-9aaa2610"]]);/*! @license DOMPurify 2.5.9 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.5.9/LICENSE */function ue(o){"@babel/helpers - typeof";return ue=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ue(o)}function dt(o,t){return dt=Object.setPrototypeOf||function(l,a){return l.__proto__=a,l},dt(o,t)}function Rl(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ze(o,t,r){return Rl()?ze=Reflect.construct:ze=function(a,c,m){var p=[null];p.push.apply(p,c);var s=Function.bind.apply(a,p),y=new s;return m&&dt(y,m.prototype),y},ze.apply(null,arguments)}function ae(o){return zl(o)||Fl(o)||Pl(o)||Hl()}function zl(o){if(Array.isArray(o))return ut(o)}function Fl(o){if(typeof Symbol<"u"&&o[Symbol.iterator]!=null||o["@@iterator"]!=null)return Array.from(o)}function Pl(o,t){if(o){if(typeof o=="string")return ut(o,t);var r=Object.prototype.toString.call(o).slice(8,-1);if(r==="Object"&&o.constructor&&(r=o.constructor.name),r==="Map"||r==="Set")return Array.from(o);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ut(o,t)}}function ut(o,t){(t==null||t>o.length)&&(t=o.length);for(var r=0,l=new Array(t);r<t;r++)l[r]=o[r];return l}function Hl(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
2
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Ul=Object.hasOwnProperty,Rt=Object.setPrototypeOf,Wl=Object.isFrozen,Gl=Object.getPrototypeOf,jl=Object.getOwnPropertyDescriptor,Y=Object.freeze,te=Object.seal,ql=Object.create,so=typeof Reflect<"u"&&Reflect,Pe=so.apply,mt=so.construct;Pe||(Pe=function(t,r,l){return t.apply(r,l)});Y||(Y=function(t){return t});te||(te=function(t){return t});mt||(mt=function(t,r){return ze(t,ae(r))});var Kl=oe(Array.prototype.forEach),zt=oe(Array.prototype.pop),be=oe(Array.prototype.push),Fe=oe(String.prototype.toLowerCase),rt=oe(String.prototype.toString),Ft=oe(String.prototype.match),re=oe(String.prototype.replace),Zl=oe(String.prototype.indexOf),Yl=oe(String.prototype.trim),K=oe(RegExp.prototype.test),at=Xl(TypeError);function oe(o){return function(t){for(var r=arguments.length,l=new Array(r>1?r-1:0),a=1;a<r;a++)l[a-1]=arguments[a];return Pe(o,t,l)}}function Xl(o){return function(){for(var t=arguments.length,r=new Array(t),l=0;l<t;l++)r[l]=arguments[l];return mt(o,r)}}function b(o,t,r){var l;r=(l=r)!==null&&l!==void 0?l:Fe,Rt&&Rt(o,null);for(var a=t.length;a--;){var c=t[a];if(typeof c=="string"){var m=r(c);m!==c&&(Wl(t)||(t[a]=m),c=m)}o[c]=!0}return o}function he(o){var t=ql(null),r;for(r in o)Pe(Ul,o,[r])===!0&&(t[r]=o[r]);return t}function Ie(o,t){for(;o!==null;){var r=jl(o,t);if(r){if(r.get)return oe(r.get);if(typeof r.value=="function")return oe(r.value)}o=Gl(o)}function l(a){return console.warn("fallback value for",a),null}return l}var Pt=Y(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),lt=Y(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),ct=Y(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Jl=Y(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),st=Y(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),Ql=Y(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Ht=Y(["#text"]),Ut=Y(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),it=Y(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Wt=Y(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Me=Y(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),e1=te(/\{\{[\w\W]*|[\w\W]*\}\}/gm),t1=te(/<%[\w\W]*|[\w\W]*%>/gm),o1=te(/\${[\w\W]*}/gm),n1=te(/^data-[\-\w.\u00B7-\uFFFF]+$/),r1=te(/^aria-[\-\w]+$/),a1=te(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),l1=te(/^(?:\w+script|data):/i),c1=te(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),s1=te(/^html$/i),i1=te(/^[a-z][.\w]*(-[.\w]+)+$/i),d1=function(){return typeof window>"u"?null:window},u1=function(t,r){if(ue(t)!=="object"||typeof t.createPolicy!="function")return null;var l=null,a="data-tt-policy-suffix";r.currentScript&&r.currentScript.hasAttribute(a)&&(l=r.currentScript.getAttribute(a));var c="dompurify"+(l?"#"+l:"");try{return t.createPolicy(c,{createHTML:function(p){return p},createScriptURL:function(p){return p}})}catch{return console.warn("TrustedTypes policy "+c+" could not be created."),null}};function io(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:d1(),t=function(n){return io(n)};if(t.version="2.5.9",t.removed=[],!o||!o.document||o.document.nodeType!==9)return t.isSupported=!1,t;var r=o.document,l=o.document,a=o.DocumentFragment,c=o.HTMLTemplateElement,m=o.Node,p=o.Element,s=o.NodeFilter,y=o.NamedNodeMap,u=y===void 0?o.NamedNodeMap||o.MozNamedAttrMap:y,h=o.HTMLFormElement,V=o.DOMParser,E=o.trustedTypes,N=p.prototype,w=Ie(N,"cloneNode"),k=Ie(N,"nextSibling"),S=Ie(N,"childNodes"),R=Ie(N,"parentNode");if(typeof c=="function"){var g=l.createElement("template");g.content&&g.content.ownerDocument&&(l=g.content.ownerDocument)}var L=u1(E,r),O=L?L.createHTML(""):"",$=l,F=$.implementation,ne=$.createNodeIterator,z=$.createDocumentFragment,I=$.getElementsByTagName,D=r.importNode,C={};try{C=he(l).documentMode?l.documentMode:{}}catch{}var B={};t.isSupported=typeof R=="function"&&F&&F.createHTMLDocument!==void 0&&C!==9;var M=e1,x=t1,A=o1,X=n1,_=r1,ce=l1,le=c1,Ne=i1,He=a1,W=null,ft=b({},[].concat(ae(Pt),ae(lt),ae(ct),ae(st),ae(Ht))),G=null,ht=b({},[].concat(ae(Ut),ae(it),ae(Wt),ae(Me))),P=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),we=null,Ue=null,vt=!0,We=!0,kt=!1,gt=!0,ke=!1,Ge=!0,me=!1,je=!1,qe=!1,ge=!1,Le=!1,Oe=!1,Ct=!0,_t=!1,mo="user-content-",Ke=!0,Ve=!1,Ce={},_e=null,yt=b({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Et=null,Bt=b({},["audio","video","img","source","image","track"]),Ze=null,Nt=b({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),$e="http://www.w3.org/1998/Math/MathML",De="http://www.w3.org/2000/svg",se="http://www.w3.org/1999/xhtml",ye=se,Ye=!1,Xe=null,po=b({},[$e,De,se],rt),pe,fo=["application/xhtml+xml","text/html"],ho="text/html",j,Ee=null,vo=l.createElement("form"),wt=function(n){return n instanceof RegExp||n instanceof Function},Je=function(n){Ee&&Ee===n||((!n||ue(n)!=="object")&&(n={}),n=he(n),pe=fo.indexOf(n.PARSER_MEDIA_TYPE)===-1?pe=ho:pe=n.PARSER_MEDIA_TYPE,j=pe==="application/xhtml+xml"?rt:Fe,W="ALLOWED_TAGS"in n?b({},n.ALLOWED_TAGS,j):ft,G="ALLOWED_ATTR"in n?b({},n.ALLOWED_ATTR,j):ht,Xe="ALLOWED_NAMESPACES"in n?b({},n.ALLOWED_NAMESPACES,rt):po,Ze="ADD_URI_SAFE_ATTR"in n?b(he(Nt),n.ADD_URI_SAFE_ATTR,j):Nt,Et="ADD_DATA_URI_TAGS"in n?b(he(Bt),n.ADD_DATA_URI_TAGS,j):Bt,_e="FORBID_CONTENTS"in n?b({},n.FORBID_CONTENTS,j):yt,we="FORBID_TAGS"in n?b({},n.FORBID_TAGS,j):{},Ue="FORBID_ATTR"in n?b({},n.FORBID_ATTR,j):{},Ce="USE_PROFILES"in n?n.USE_PROFILES:!1,vt=n.ALLOW_ARIA_ATTR!==!1,We=n.ALLOW_DATA_ATTR!==!1,kt=n.ALLOW_UNKNOWN_PROTOCOLS||!1,gt=n.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ke=n.SAFE_FOR_TEMPLATES||!1,Ge=n.SAFE_FOR_XML!==!1,me=n.WHOLE_DOCUMENT||!1,ge=n.RETURN_DOM||!1,Le=n.RETURN_DOM_FRAGMENT||!1,Oe=n.RETURN_TRUSTED_TYPE||!1,qe=n.FORCE_BODY||!1,Ct=n.SANITIZE_DOM!==!1,_t=n.SANITIZE_NAMED_PROPS||!1,Ke=n.KEEP_CONTENT!==!1,Ve=n.IN_PLACE||!1,He=n.ALLOWED_URI_REGEXP||He,ye=n.NAMESPACE||se,P=n.CUSTOM_ELEMENT_HANDLING||{},n.CUSTOM_ELEMENT_HANDLING&&wt(n.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(P.tagNameCheck=n.CUSTOM_ELEMENT_HANDLING.tagNameCheck),n.CUSTOM_ELEMENT_HANDLING&&wt(n.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(P.attributeNameCheck=n.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),n.CUSTOM_ELEMENT_HANDLING&&typeof n.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(P.allowCustomizedBuiltInElements=n.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ke&&(We=!1),Le&&(ge=!0),Ce&&(W=b({},ae(Ht)),G=[],Ce.html===!0&&(b(W,Pt),b(G,Ut)),Ce.svg===!0&&(b(W,lt),b(G,it),b(G,Me)),Ce.svgFilters===!0&&(b(W,ct),b(G,it),b(G,Me)),Ce.mathMl===!0&&(b(W,st),b(G,Wt),b(G,Me))),n.ADD_TAGS&&(W===ft&&(W=he(W)),b(W,n.ADD_TAGS,j)),n.ADD_ATTR&&(G===ht&&(G=he(G)),b(G,n.ADD_ATTR,j)),n.ADD_URI_SAFE_ATTR&&b(Ze,n.ADD_URI_SAFE_ATTR,j),n.FORBID_CONTENTS&&(_e===yt&&(_e=he(_e)),b(_e,n.FORBID_CONTENTS,j)),Ke&&(W["#text"]=!0),me&&b(W,["html","head","body"]),W.table&&(b(W,["tbody"]),delete we.tbody),Y&&Y(n),Ee=n)},Vt=b({},["mi","mo","mn","ms","mtext"]),St=b({},["annotation-xml"]),ko=b({},["title","style","font","a","script"]),xe=b({},lt);b(xe,ct),b(xe,Jl);var Qe=b({},st);b(Qe,Ql);var go=function(n){var d=R(n);(!d||!d.tagName)&&(d={namespaceURI:ye,tagName:"template"});var f=Fe(n.tagName),T=Fe(d.tagName);return Xe[n.namespaceURI]?n.namespaceURI===De?d.namespaceURI===se?f==="svg":d.namespaceURI===$e?f==="svg"&&(T==="annotation-xml"||Vt[T]):!!xe[f]:n.namespaceURI===$e?d.namespaceURI===se?f==="math":d.namespaceURI===De?f==="math"&&St[T]:!!Qe[f]:n.namespaceURI===se?d.namespaceURI===De&&!St[T]||d.namespaceURI===$e&&!Vt[T]?!1:!Qe[f]&&(ko[f]||!xe[f]):!!(pe==="application/xhtml+xml"&&Xe[n.namespaceURI]):!1},ee=function(n){be(t.removed,{element:n});try{n.parentNode.removeChild(n)}catch{try{n.outerHTML=O}catch{n.remove()}}},Te=function(n,d){try{be(t.removed,{attribute:d.getAttributeNode(n),from:d})}catch{be(t.removed,{attribute:null,from:d})}if(d.removeAttribute(n),n==="is"&&!G[n])if(ge||Le)try{ee(d)}catch{}else try{d.setAttribute(n,"")}catch{}},bt=function(n){var d,f;if(qe)n="<remove></remove>"+n;else{var T=Ft(n,/^[\r\n\t ]+/);f=T&&T[0]}pe==="application/xhtml+xml"&&ye===se&&(n='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+n+"</body></html>");var J=L?L.createHTML(n):n;if(ye===se)try{d=new V().parseFromString(J,pe)}catch{}if(!d||!d.documentElement){d=F.createDocument(ye,"template",null);try{d.documentElement.innerHTML=Ye?O:J}catch{}}var Z=d.body||d.documentElement;return n&&f&&Z.insertBefore(l.createTextNode(f),Z.childNodes[0]||null),ye===se?I.call(d,me?"html":"body")[0]:me?d.documentElement:Z},Lt=function(n){return ne.call(n.ownerDocument||n,n,s.SHOW_ELEMENT|s.SHOW_COMMENT|s.SHOW_TEXT|s.SHOW_PROCESSING_INSTRUCTION|s.SHOW_CDATA_SECTION,null,!1)},et=function(n){return n instanceof h&&(typeof n.nodeName!="string"||typeof n.textContent!="string"||typeof n.removeChild!="function"||!(n.attributes instanceof u)||typeof n.removeAttribute!="function"||typeof n.setAttribute!="function"||typeof n.namespaceURI!="string"||typeof n.insertBefore!="function"||typeof n.hasChildNodes!="function")},Se=function(n){return ue(m)==="object"?n instanceof m:n&&ue(n)==="object"&&typeof n.nodeType=="number"&&typeof n.nodeName=="string"},ie=function(n,d,f){B[n]&&Kl(B[n],function(T){T.call(t,d,f,Ee)})},Ot=function(n){var d;if(ie("beforeSanitizeElements",n,null),et(n)||K(/[\u0080-\uFFFF]/,n.nodeName))return ee(n),!0;var f=j(n.nodeName);if(ie("uponSanitizeElement",n,{tagName:f,allowedTags:W}),n.hasChildNodes()&&!Se(n.firstElementChild)&&(!Se(n.content)||!Se(n.content.firstElementChild))&&K(/<[/\w]/g,n.innerHTML)&&K(/<[/\w]/g,n.textContent)||f==="select"&&K(/<template/i,n.innerHTML)||n.nodeType===7||Ge&&n.nodeType===8&&K(/<[/\w]/g,n.data))return ee(n),!0;if(!W[f]||we[f]){if(!we[f]&&Dt(f)&&(P.tagNameCheck instanceof RegExp&&K(P.tagNameCheck,f)||P.tagNameCheck instanceof Function&&P.tagNameCheck(f)))return!1;if(Ke&&!_e[f]){var T=R(n)||n.parentNode,J=S(n)||n.childNodes;if(J&&T)for(var Z=J.length,q=Z-1;q>=0;--q){var fe=w(J[q],!0);fe.__removalCount=(n.__removalCount||0)+1,T.insertBefore(fe,k(n))}}return ee(n),!0}return n instanceof p&&!go(n)||(f==="noscript"||f==="noembed"||f==="noframes")&&K(/<\/no(script|embed|frames)/i,n.innerHTML)?(ee(n),!0):(ke&&n.nodeType===3&&(d=n.textContent,d=re(d,M," "),d=re(d,x," "),d=re(d,A," "),n.textContent!==d&&(be(t.removed,{element:n.cloneNode()}),n.textContent=d)),ie("afterSanitizeElements",n,null),!1)},$t=function(n,d,f){if(Ct&&(d==="id"||d==="name")&&(f in l||f in vo))return!1;if(!(We&&!Ue[d]&&K(X,d))){if(!(vt&&K(_,d))){if(!G[d]||Ue[d]){if(!(Dt(n)&&(P.tagNameCheck instanceof RegExp&&K(P.tagNameCheck,n)||P.tagNameCheck instanceof Function&&P.tagNameCheck(n))&&(P.attributeNameCheck instanceof RegExp&&K(P.attributeNameCheck,d)||P.attributeNameCheck instanceof Function&&P.attributeNameCheck(d))||d==="is"&&P.allowCustomizedBuiltInElements&&(P.tagNameCheck instanceof RegExp&&K(P.tagNameCheck,f)||P.tagNameCheck instanceof Function&&P.tagNameCheck(f))))return!1}else if(!Ze[d]){if(!K(He,re(f,le,""))){if(!((d==="src"||d==="xlink:href"||d==="href")&&n!=="script"&&Zl(f,"data:")===0&&Et[n])){if(!(kt&&!K(ce,re(f,le,"")))){if(f)return!1}}}}}}return!0},Dt=function(n){return n!=="annotation-xml"&&Ft(n,Ne)},xt=function(n){var d,f,T,J;ie("beforeSanitizeAttributes",n,null);var Z=n.attributes;if(!(!Z||et(n))){var q={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:G};for(J=Z.length;J--;){d=Z[J];var fe=d,U=fe.name,tt=fe.namespaceURI;if(f=U==="value"?d.value:Yl(d.value),T=j(U),q.attrName=T,q.attrValue=f,q.keepAttr=!0,q.forceKeepAttr=void 0,ie("uponSanitizeAttribute",n,q),f=q.attrValue,!q.forceKeepAttr&&(Te(U,n),!!q.keepAttr)){if(!gt&&K(/\/>/i,f)){Te(U,n);continue}ke&&(f=re(f,M," "),f=re(f,x," "),f=re(f,A," "));var Tt=j(n.nodeName);if($t(Tt,T,f)){if(_t&&(T==="id"||T==="name")&&(Te(U,n),f=mo+f),Ge&&K(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)){Te(U,n);continue}if(L&&ue(E)==="object"&&typeof E.getAttributeType=="function"&&!tt)switch(E.getAttributeType(Tt,T)){case"TrustedHTML":{f=L.createHTML(f);break}case"TrustedScriptURL":{f=L.createScriptURL(f);break}}try{tt?n.setAttributeNS(tt,U,f):n.setAttribute(U,f),et(n)?ee(n):zt(t.removed)}catch{}}}}ie("afterSanitizeAttributes",n,null)}},Co=function v(n){var d,f=Lt(n);for(ie("beforeSanitizeShadowDOM",n,null);d=f.nextNode();)ie("uponSanitizeShadowNode",d,null),Ot(d),xt(d),d.content instanceof a&&v(d.content);ie("afterSanitizeShadowDOM",n,null)};return t.sanitize=function(v){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},d,f,T,J,Z;if(Ye=!v,Ye&&(v="<!-->"),typeof v!="string"&&!Se(v))if(typeof v.toString=="function"){if(v=v.toString(),typeof v!="string")throw at("dirty is not a string, aborting")}else throw at("toString is not a function");if(!t.isSupported){if(ue(o.toStaticHTML)==="object"||typeof o.toStaticHTML=="function"){if(typeof v=="string")return o.toStaticHTML(v);if(Se(v))return o.toStaticHTML(v.outerHTML)}return v}if(je||Je(n),t.removed=[],typeof v=="string"&&(Ve=!1),Ve){if(v.nodeName){var q=j(v.nodeName);if(!W[q]||we[q])throw at("root node is forbidden and cannot be sanitized in-place")}}else if(v instanceof m)d=bt("<!---->"),f=d.ownerDocument.importNode(v,!0),f.nodeType===1&&f.nodeName==="BODY"||f.nodeName==="HTML"?d=f:d.appendChild(f);else{if(!ge&&!ke&&!me&&v.indexOf("<")===-1)return L&&Oe?L.createHTML(v):v;if(d=bt(v),!d)return ge?null:Oe?O:""}d&&qe&&ee(d.firstChild);for(var fe=Lt(Ve?v:d);T=fe.nextNode();)T.nodeType===3&&T===J||(Ot(T),xt(T),T.content instanceof a&&Co(T.content),J=T);if(J=null,Ve)return v;if(ge){if(Le)for(Z=z.call(d.ownerDocument);d.firstChild;)Z.appendChild(d.firstChild);else Z=d;return(G.shadowroot||G.shadowrootmod)&&(Z=D.call(r,Z,!0)),Z}var U=me?d.outerHTML:d.innerHTML;return me&&W["!doctype"]&&d.ownerDocument&&d.ownerDocument.doctype&&d.ownerDocument.doctype.name&&K(s1,d.ownerDocument.doctype.name)&&(U="<!DOCTYPE "+d.ownerDocument.doctype.name+`>
|
|
3
|
-
`+U),ke&&(U=re(U,M," "),U=re(U,x," "),U=re(U,A," ")),L&&Oe?L.createHTML(U):U},t.setConfig=function(v){Je(v),je=!0},t.clearConfig=function(){Ee=null,je=!1},t.isValidAttribute=function(v,n,d){Ee||Je({});var f=j(v),T=j(n);return $t(f,T,d)},t.addHook=function(v,n){typeof n=="function"&&(B[v]=B[v]||[],be(B[v],n))},t.removeHook=function(v){if(B[v])return zt(B[v])},t.removeHooks=function(v){B[v]&&(B[v]=[])},t.removeAllHooks=function(){B={}},t}var m1=io();function p1(o,t){const r=o.hooks??{};let l;for(l in r){const a=r[l];a!==void 0&&t.addHook(l,a)}}function f1(){return m1()}function uo(o={},t=f1){const r=t();p1(o,r);const l=function(a,c){const m=c.value;if(c.oldValue===m)return;const p=`${m}`,s=c.arg,y=o.namedConfigurations,u=o.default??{};if(y&&s!==void 0){a.innerHTML=r.sanitize(p,y[s]??u);return}a.innerHTML=r.sanitize(p,u)};return{mounted:l,updated:l}}const h1={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function v1(o,t){return e.openBlock(),e.createElementBlock("svg",h1,[...t[0]||(t[0]=[e.createElementVNode("rect",{id:"峰会",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),e.createElementVNode("path",{id:"矢量 425",d:"M8.36719 4.75439L8.36523 4.75537L8.36523 4.75537C7.63184 5.05518 6.93555 5.44629 6.27734 5.9292C6.00098 6.13184 5.94238 6.5083 6.14551 6.78516C6.34766 7.06201 6.72461 7.11963 7.00098 6.91699C7.61035 6.47119 8.25391 6.11475 8.93262 5.84766C9.05371 5.7998 9.17676 5.75488 9.30078 5.71289C9.73242 5.56641 10.1699 5.45752 10.6143 5.38672C10.6191 5.38574 10.624 5.38525 10.6289 5.38428L10.6289 5.38428C11.0439 5.31836 11.4639 5.28564 11.8896 5.28564C12.3193 5.28564 12.7451 5.31934 13.1641 5.38672L13.165 5.38672C13.6084 5.45752 14.0459 5.56641 14.4775 5.71289C14.6016 5.75488 14.7246 5.7998 14.8457 5.84766C15.5254 6.11475 16.1689 6.47119 16.7773 6.91699C17.0537 7.11963 17.4307 7.06201 17.6328 6.78516C17.8359 6.5083 17.7783 6.13184 17.501 5.9292C16.8418 5.4458 16.1455 5.0542 15.4111 4.75439C15.2334 4.68213 15.0537 4.61475 14.8711 4.55273C14.376 4.38477 13.873 4.25977 13.3643 4.17773C12.8789 4.09961 12.3877 4.06055 11.8896 4.06055C11.3916 4.06055 10.8994 4.09961 10.4141 4.17773L10.4141 4.17773C9.90527 4.25977 9.40332 4.38477 8.90723 4.55273C8.72559 4.61475 8.54492 4.68213 8.36719 4.75439L8.36719 4.75439ZM20.377 14.2979L20.377 13.4229C20.377 13.0801 20.1074 12.8105 19.7646 12.8105C19.4219 12.8105 19.1523 13.0801 19.1523 13.4229L19.1523 14.2979C19.1523 14.334 19.1455 14.3677 19.1328 14.3984L19.1328 14.3989C19.1074 14.4243 19.0215 14.5283 18.9902 14.5415C18.96 14.5542 18.9258 14.5605 18.8896 14.5605L4.88965 14.5605C4.85352 14.5605 4.82031 14.5542 4.78906 14.5415C4.76367 14.5156 4.65918 14.4297 4.64648 14.3989C4.63379 14.3677 4.62695 14.3345 4.62695 14.2979L4.62695 9.04785C4.62695 9.01172 4.63379 8.97803 4.64648 8.94727C4.67188 8.92188 4.75781 8.81738 4.78906 8.80469L4.78906 8.80469C4.82031 8.79199 4.85352 8.78564 4.88965 8.78564L18.8896 8.78564C18.9258 8.78564 18.96 8.79199 18.9902 8.80469C19.0166 8.83057 19.1201 8.9165 19.1328 8.94727C19.1455 8.97803 19.1523 9.01172 19.1523 9.04785L19.1523 11.6729C19.1523 12.0161 19.4219 12.2856 19.7646 12.2856C20.1074 12.2856 20.377 12.0161 20.377 11.6729L20.377 9.04785C20.377 8.94141 20.3662 8.83691 20.3447 8.73535L20.3447 8.73438L20.3447 8.73389C20.3252 8.64355 20.2969 8.55518 20.2598 8.46875C20.2236 8.3833 20.1807 8.30225 20.1299 8.22559C20.0752 8.14355 20.0127 8.06738 19.9414 7.99609C19.8701 7.92529 19.7939 7.8623 19.7119 7.80811C19.6357 7.75732 19.5547 7.71387 19.4688 7.67773C19.3828 7.64111 19.2939 7.61328 19.2041 7.59375C19.1016 7.57178 18.9971 7.56055 18.8896 7.56055L4.88965 7.56055C4.78418 7.56055 4.68066 7.57129 4.5791 7.59277L4.5791 7.59277C4.57812 7.59326 4.57715 7.59326 4.57617 7.59375L4.5752 7.59375C4.48535 7.61328 4.39746 7.64111 4.31055 7.67773C4.22461 7.71387 4.14355 7.75732 4.06738 7.80811C3.98535 7.8623 3.90918 7.92529 3.83789 7.99609C3.7666 8.06738 3.7041 8.14355 3.64941 8.22559C3.64941 8.22656 3.64844 8.22705 3.64844 8.22803C3.59863 8.30371 3.55566 8.38379 3.51953 8.46875C3.48242 8.55518 3.45508 8.64355 3.43555 8.73389C3.41309 8.83643 3.40234 8.94092 3.40234 9.04785L3.40234 14.2979C3.40234 14.4053 3.41309 14.5098 3.43555 14.6123C3.45508 14.7021 3.48242 14.7905 3.51953 14.8774C3.55566 14.9629 3.59961 15.0439 3.64941 15.1201C3.7041 15.2021 3.7666 15.2788 3.83789 15.3501C3.90918 15.4209 3.98535 15.4834 4.06738 15.5381C4.14355 15.5889 4.22461 15.6323 4.31055 15.6685C4.39746 15.7051 4.48535 15.7329 4.5752 15.7524C4.67773 15.7744 4.78223 15.7856 4.88965 15.7856L18.8896 15.7856C18.9971 15.7856 19.1016 15.7744 19.2041 15.7524C19.2939 15.7329 19.3828 15.7051 19.4688 15.6685C19.5547 15.6318 19.6357 15.5889 19.7119 15.5381C19.7939 15.4834 19.8701 15.4209 19.9414 15.3501C20.0127 15.2788 20.0752 15.2021 20.1299 15.1201C20.1807 15.0439 20.2236 14.9629 20.2598 14.8774C20.2969 14.7905 20.3252 14.7021 20.3447 14.6123C20.3662 14.5098 20.377 14.4053 20.377 14.2979ZM14.8291 16.3438L14.8291 16.3438C14.9189 16.3633 15.0078 16.3911 15.0938 16.4277C15.1797 16.4639 15.2607 16.5073 15.3369 16.5581C15.4189 16.6123 15.4951 16.6753 15.5664 16.7461C15.6377 16.8174 15.7002 16.8936 15.7549 16.9756C15.8057 17.0522 15.8486 17.1328 15.8848 17.2188C15.9219 17.3052 15.9502 17.3936 15.9697 17.4839C15.9912 17.5864 16.002 17.6909 16.002 17.7979C16.002 17.9053 15.9912 18.0098 15.9697 18.1123C15.9502 18.2021 15.9219 18.2905 15.8848 18.3774C15.8486 18.4629 15.8057 18.5439 15.7549 18.6201C15.7002 18.7021 15.6377 18.7788 15.5664 18.8501C15.4951 18.9209 15.4189 18.9834 15.3369 19.0381C15.2607 19.0889 15.1797 19.1318 15.0938 19.1685C15.0078 19.2051 14.9189 19.2329 14.8291 19.2524C14.7266 19.2744 14.6221 19.2856 14.5146 19.2856L9.26465 19.2856C9.1582 19.2856 9.05273 19.2744 8.9502 19.2524C8.86035 19.2329 8.77246 19.2051 8.68555 19.1685C8.59961 19.1318 8.51855 19.0889 8.44238 19.0381C8.36035 18.9834 8.28418 18.9209 8.21289 18.8501C8.1416 18.7788 8.0791 18.7021 8.02441 18.6201C7.97461 18.5439 7.93066 18.4629 7.89453 18.3774C7.85742 18.2905 7.83008 18.2021 7.81055 18.1123C7.78809 18.0098 7.77734 17.9053 7.77734 17.7979C7.77734 17.6909 7.78809 17.5864 7.81055 17.4839C7.83008 17.3936 7.85742 17.3052 7.89453 17.2188C7.93066 17.1328 7.97461 17.0522 8.02441 16.9756C8.0791 16.8936 8.1416 16.8174 8.21289 16.7461C8.28418 16.6753 8.36035 16.6123 8.44238 16.5581C8.51855 16.5073 8.59961 16.4639 8.68555 16.4277C8.77246 16.3911 8.86035 16.3633 8.9502 16.3438C9.05273 16.3218 9.1582 16.3105 9.26465 16.3105L14.5146 16.3105C14.6221 16.3105 14.7266 16.3218 14.8291 16.3438ZM9.2666 17.5352L14.5166 17.5352C14.5527 17.5352 14.5859 17.5415 14.6172 17.5547C14.6426 17.5801 14.7471 17.666 14.7598 17.6973C14.7725 17.728 14.7793 17.7617 14.7793 17.7979C14.7793 17.834 14.7725 17.8677 14.7598 17.8984C14.7344 17.9243 14.6484 18.0283 14.6172 18.041C14.5859 18.0542 14.5527 18.0605 14.5166 18.0605L9.2666 18.0605C9.23047 18.0605 9.19629 18.0542 9.16602 18.041C9.13965 18.0156 9.03613 17.9297 9.02344 17.8984C9.01074 17.8677 9.00391 17.834 9.00391 17.7979C9.00391 17.7617 9.01074 17.728 9.02344 17.6973C9.04883 17.6714 9.13477 17.5674 9.16602 17.5547C9.19629 17.5415 9.23047 17.5352 9.2666 17.5352Z",fill:"rgb(255,255,255)","fill-rule":"evenodd"},null,-1)])])}const k1={name:"events-icon-summit",render:v1},g1={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function C1(o,t){return e.openBlock(),e.createElementBlock("svg",g1,[...t[0]||(t[0]=[e.createElementVNode("rect",{id:"活动",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),e.createElementVNode("path",{id:"矢量 426",d:"M18.3065 11.0924L17.7206 11.6295C17.455 11.8722 17.4384 12.2711 17.6806 12.5362C17.9237 12.8009 18.3221 12.8185 18.5868 12.5758L19.1737 12.0387L20.0418 11.2433C20.1746 11.1217 20.2811 10.9859 20.3631 10.8365C20.4256 10.7198 20.4735 10.5948 20.5057 10.4615C20.5369 10.3316 20.5516 10.2017 20.5496 10.0723C20.5467 9.92 20.5213 9.76765 20.4725 9.61531C20.4237 9.46345 20.3553 9.32478 20.2684 9.19978C20.1942 9.09333 20.1063 8.99665 20.0057 8.90925C19.9012 8.81989 19.7899 8.74616 19.6698 8.68854C19.5165 8.61481 19.3504 8.56744 19.1717 8.54645L15.3212 8.09185C15.2997 8.08355 15.2119 8.05572 15.1923 8.04156C15.1777 8.02398 15.1142 7.9566 15.1044 7.93511L13.4697 4.43751C13.3945 4.27638 13.2978 4.13477 13.1816 4.0127L13.1816 4.0127C13.0898 3.91797 12.9853 3.83496 12.8691 3.76416C12.7549 3.69531 12.6367 3.64209 12.5137 3.60498L12.5137 3.60498C12.3682 3.56104 12.2168 3.53906 12.0586 3.53906C11.8994 3.53906 11.7481 3.56104 11.6025 3.60498L11.6025 3.60498C11.4795 3.64209 11.3613 3.69531 11.2471 3.76416C11.1309 3.83496 11.0264 3.91797 10.9356 4.0127C10.8184 4.13477 10.7217 4.27589 10.6465 4.43751L9.01178 7.93511C8.99713 7.95269 8.94342 8.0274 8.92389 8.04156C8.90241 8.04986 8.81843 8.08892 8.79499 8.09185L4.94448 8.54645C4.76577 8.56744 4.59976 8.61481 4.44644 8.68854L4.44644 8.68854C4.32731 8.74616 4.215 8.81989 4.11149 8.90925C4.00993 8.99665 3.92204 9.09333 3.8488 9.19978C3.76091 9.32478 3.69353 9.46345 3.64373 9.61531C3.5949 9.76765 3.56951 9.92 3.56658 10.0723C3.56463 10.2017 3.57927 10.3316 3.61052 10.4615C3.64275 10.5948 3.6906 10.7198 3.75407 10.8365C3.83513 10.9859 3.94157 11.1217 4.07438 11.2433L6.90635 13.837C6.91807 13.8566 6.97374 13.9313 6.98155 13.9542C6.98155 13.9606 6.98252 13.9713 6.98448 13.9845L6.98448 13.986C6.98838 14.0226 6.99327 14.0763 6.98936 14.0939L6.2384 17.8488C6.20324 18.0241 6.19738 18.196 6.21985 18.3635C6.23645 18.4948 6.2716 18.6232 6.32434 18.7497C6.37512 18.8727 6.43957 18.986 6.51671 19.0891C6.60851 19.2106 6.71788 19.3181 6.84679 19.4118C6.97471 19.5061 7.11045 19.5778 7.254 19.6281C7.37607 19.6711 7.50302 19.698 7.63583 19.7097C7.77157 19.7209 7.90438 19.7155 8.03524 19.6926L8.03524 19.6926C8.20223 19.6628 8.36336 19.6047 8.52058 19.5183L11.9248 17.6369C11.9473 17.631 12.0342 17.6022 12.0586 17.6022C12.0801 17.6081 12.1709 17.6252 12.1914 17.6369L15.5117 19.4719C15.6718 19.5603 15.8368 19.6189 16.0068 19.6481L16.0077 19.6481C16.1396 19.6706 16.2743 19.675 16.412 19.6618C16.5468 19.6491 16.6747 19.6203 16.7968 19.5754C16.9423 19.5222 17.079 19.447 17.2079 19.3488C17.3368 19.2512 17.4462 19.1394 17.537 19.0139C17.6132 18.9079 17.6747 18.7917 17.7235 18.6662C17.7733 18.5368 17.8046 18.4055 17.8182 18.2722C17.8368 18.1008 17.8241 17.926 17.7821 17.7482L16.3495 11.7125C16.2665 11.3629 15.9267 11.1534 15.5771 11.2359C15.2275 11.3189 15.0175 11.6593 15.1005 12.0089L16.5331 18.0446C16.5468 18.1027 16.5458 18.155 16.5292 18.2023C16.5116 18.2492 16.4794 18.2907 16.4325 18.3268C16.3847 18.363 16.3359 18.383 16.286 18.3864C16.2362 18.3903 16.1855 18.3776 16.1327 18.3488L12.8115 16.5133C12.6943 16.4489 12.5732 16.4001 12.4473 16.3678L12.4473 16.3678C12.3223 16.3351 12.1924 16.319 12.0586 16.319C11.9238 16.319 11.794 16.3351 11.669 16.3678C11.543 16.4001 11.4219 16.4489 11.3047 16.5133L7.8995 18.3952C7.84872 18.4235 7.79794 18.4362 7.74911 18.4328C7.69931 18.4299 7.65146 18.4108 7.60458 18.3762C7.55673 18.342 7.52451 18.3015 7.50693 18.2556C7.48837 18.2097 7.48545 18.1579 7.49716 18.1003L8.24813 14.3453C8.27449 14.2116 8.28426 14.0792 8.27644 13.9474C8.26863 13.816 8.24324 13.6852 8.20125 13.5558C8.15926 13.4259 8.10262 13.3058 8.03036 13.1949C7.95907 13.0841 7.87313 12.983 7.77255 12.8907L4.94155 10.297C4.89761 10.2569 4.87026 10.213 4.85757 10.1651C4.84487 10.1173 4.8478 10.0655 4.86538 10.0094C4.88393 9.95369 4.91128 9.90975 4.94936 9.8785C4.98842 9.84676 5.03628 9.82771 5.09487 9.82088L8.94538 9.36628C9.07916 9.35066 9.20709 9.31892 9.32916 9.27155C9.45025 9.22419 9.56646 9.16071 9.67583 9.0821C9.7852 9.003 9.8809 8.91315 9.96391 8.81256C10.0479 8.71198 10.1172 8.60065 10.1748 8.47858L11.8086 4.98097C11.834 4.92824 11.8672 4.88869 11.9082 4.86183C11.9502 4.83546 12 4.82228 12.0586 4.82228C12.1162 4.82228 12.166 4.83546 12.208 4.86183C12.25 4.88869 12.2822 4.92824 12.3076 4.98097L13.9414 8.47858C13.999 8.60065 14.0693 8.71198 14.1523 8.81256C14.2353 8.91315 14.332 9.003 14.4414 9.0821C14.5507 9.16071 14.666 9.22419 14.7871 9.27155C14.9091 9.31892 15.0371 9.35066 15.1708 9.36628L19.0213 9.82088C19.0799 9.82771 19.1278 9.84676 19.1668 9.8785C19.2049 9.90975 19.2333 9.95369 19.2508 10.0094C19.2694 10.0655 19.2713 10.1173 19.2586 10.1651C19.2459 10.213 19.2186 10.2569 19.1747 10.297L18.3065 11.0924ZM9.31256 13.2311L7.93856 11.8561C7.68368 11.6017 7.68368 11.2027 7.93856 10.9483C8.19246 10.6944 8.59187 10.6944 8.84577 10.9483L10.2207 12.3233C10.4746 12.5777 10.4746 12.9772 10.2207 13.2311C9.96586 13.485 9.56743 13.485 9.31256 13.2311Z",fill:"rgb(255,255,255)","fill-rule":"evenodd"},null,-1)])])}const _1={name:"events-icon-events",render:C1},y1={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function E1(o,t){return e.openBlock(),e.createElementBlock("svg",y1,[...t[0]||(t[0]=[e.createElementVNode("rect",{id:"高校 & 比赛",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),e.createElementVNode("path",{id:"矢量 578",d:"M3.05078 7.51904L11.6914 4.13965C11.8086 4.09424 11.9219 4.07178 12.0391 4.07178C12.1523 4.07178 12.2695 4.09473 12.3867 4.14062L20.9609 7.51953C21.0625 7.55957 21.1523 7.61328 21.2305 7.67969C21.2969 7.73779 21.3555 7.80566 21.4062 7.88379C21.5078 8.03857 21.5586 8.20898 21.5625 8.39502C21.5625 8.58057 21.5156 8.75195 21.418 8.9082C21.3125 9.07861 21.1641 9.20264 20.9766 9.28076L19.457 9.91309L19.457 12.2915C19.457 12.6558 19.168 12.9419 18.8047 12.9419C18.4414 12.9419 18.1562 12.6558 18.1562 12.292L18.1562 10.4531L16.0742 11.3188L16.0742 14.7134C16.2852 14.897 16.418 15.1675 16.418 15.4692C16.418 16.0215 15.9688 16.4692 15.418 16.4692C14.8672 16.4692 14.418 16.0215 14.418 15.4692C14.418 15.1626 14.5547 14.8887 14.7734 14.7051L14.7734 11.8589L12.4023 12.8442C12.2852 12.8926 12.1641 12.917 12.0391 12.917C11.9141 12.9175 11.793 12.8936 11.6758 12.8452L5.63281 10.354L5.61328 17.6836C5.61328 17.7285 5.62109 17.771 5.63281 17.8101C5.65234 17.854 5.67969 17.894 5.71484 17.9307C5.75 17.9658 5.78906 17.9917 5.83203 18.0088C5.87109 18.0259 5.91797 18.0342 5.96484 18.0342L17.7812 18.0342C17.832 18.0342 17.875 18.0254 17.918 18.0083C17.957 17.9912 17.9961 17.9658 18.0312 17.9316C18.0625 17.8975 18.0898 17.8599 18.1055 17.8184C18.125 17.7773 18.1328 17.7324 18.1328 17.6841L18.1328 14.1411C18.1328 13.7773 18.418 13.4912 18.7812 13.4912C19.1445 13.4912 19.4336 13.7773 19.4336 14.1411L19.4336 17.6841C19.4336 17.8032 19.418 17.9194 19.3945 18.0332C19.375 18.1333 19.3438 18.231 19.3008 18.3267C19.2188 18.5239 19.1016 18.6987 18.9492 18.8511C18.8711 18.9297 18.7852 18.9995 18.6953 19.0596C18.6094 19.1157 18.5195 19.1641 18.4258 19.2041C18.3281 19.2446 18.2305 19.2759 18.1328 19.2974L18.1328 19.2974C18.0156 19.3218 17.9023 19.334 17.7812 19.334L5.96484 19.334C5.84375 19.334 5.73047 19.3218 5.61719 19.2979C5.51562 19.2759 5.41797 19.2446 5.32031 19.2036C5.12109 19.1201 4.94922 19.002 4.79688 18.8501C4.64453 18.6978 4.52734 18.5225 4.44141 18.3252C4.35547 18.1196 4.3125 17.9048 4.3125 17.6797L4.33594 9.81836L3.03125 9.28174C2.84375 9.2041 2.69531 9.08008 2.58984 8.90967C2.54297 8.83496 2.50781 8.75684 2.48438 8.67578C2.45703 8.58643 2.44531 8.49268 2.44531 8.39502C2.44531 8.29736 2.46094 8.20361 2.48828 8.11475C2.51562 8.03369 2.55078 7.95654 2.59766 7.8833C2.65234 7.80469 2.71094 7.73682 2.77734 7.67871C2.85547 7.61182 2.94922 7.55859 3.05078 7.51904ZM18.5547 8.87891L15.457 10.1665L11.5 8.05322C11.1758 7.88184 10.7891 7.99951 10.6172 8.32031C10.4492 8.6416 10.5664 9.02832 10.8867 9.19971L13.9062 10.8115L12.0352 11.5884L5.23438 8.78271L4.33594 8.41211L12.0352 5.40039L19.6797 8.41211L18.5547 8.87891Z",fill:"rgb(255,254.745,254.745)","fill-rule":"evenodd"},null,-1)])])}const B1={name:"events-icon-competition",render:E1},N1={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function w1(o,t){return e.openBlock(),e.createElementBlock("svg",N1,[...t[0]||(t[0]=[e.createElementVNode("rect",{id:"版本发布计划",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),e.createElementVNode("path",{id:"矢量 579",d:"M8.94922 6.90332L8.94922 6.3335C8.94922 6.23779 8.95703 6.14404 8.97656 6.05225L8.97656 6.05225C8.99609 5.97119 9.01953 5.89209 9.05469 5.81396C9.08594 5.7373 9.125 5.66455 9.17188 5.59619C9.21875 5.52246 9.27734 5.4541 9.33984 5.39062C9.40234 5.32715 9.47266 5.271 9.54297 5.22217L9.54297 5.22217L9.54297 5.22217C9.61328 5.17676 9.6875 5.1377 9.76172 5.10498C9.83984 5.07227 9.91797 5.04688 10 5.02979L10 5.02979C10.0938 5.00977 10.1875 5 10.2812 5L18.668 5C18.7617 5 18.8555 5.00977 18.9492 5.02979L18.9492 5.02979C19.0273 5.04688 19.1094 5.07227 19.1875 5.10498C19.2617 5.1377 19.3359 5.17676 19.4023 5.22217C19.4766 5.271 19.5469 5.32715 19.6094 5.39062C19.6719 5.4541 19.7305 5.52246 19.7773 5.59619L19.7773 5.59619C19.8242 5.66455 19.8633 5.7373 19.8945 5.81396C19.9297 5.89209 19.9531 5.97119 19.9688 6.05225C19.9883 6.14404 20 6.23779 20 6.3335L20 12.2441C20 12.3398 19.9883 12.4336 19.9688 12.5249C19.9531 12.606 19.9297 12.6855 19.8945 12.7632C19.8633 12.8403 19.8242 12.9131 19.7773 12.9814C19.7305 13.0547 19.6719 13.123 19.6094 13.187C19.5469 13.2505 19.4766 13.3066 19.4023 13.3555C19.3359 13.4009 19.2617 13.4399 19.1875 13.4722C19.1094 13.5054 19.0273 13.5303 18.9492 13.5479C18.8555 13.5674 18.7617 13.5771 18.668 13.5771L18.3906 13.5771C18.0664 13.5771 17.8125 13.3232 17.8125 13C17.8125 12.6768 18.0664 12.4229 18.3906 12.4229L18.668 12.4229C18.6914 12.4229 18.7734 12.3789 18.793 12.3701C18.8086 12.353 18.8359 12.2651 18.8438 12.2441L18.8438 6.3335C18.8438 6.30859 18.8008 6.22803 18.793 6.20703C18.7773 6.18945 18.6875 6.16357 18.668 6.15479L10.2812 6.15479C10.2578 6.15479 10.1758 6.19824 10.1562 6.20703C10.1367 6.22461 10.1133 6.3125 10.1016 6.3335L10.1016 6.90332C10.1016 7.22656 9.84766 7.48047 9.52734 7.48047C9.20312 7.48047 8.94922 7.22656 8.94922 6.90332ZM6.47266 9.39307L6.47266 9.21973C6.47266 9.12402 6.48438 9.03027 6.50391 8.93896C6.51953 8.85791 6.54688 8.77832 6.57812 8.70068C6.61328 8.62354 6.65234 8.55127 6.69531 8.48242C6.74609 8.40918 6.80078 8.34082 6.86328 8.27734C6.92969 8.21338 6.99609 8.15723 7.07031 8.10889C7.13672 8.06299 7.21094 8.02441 7.28906 7.9917C7.36719 7.9585 7.44531 7.93359 7.52734 7.91602C7.61719 7.89648 7.71094 7.88672 7.80859 7.88672L16.1914 7.88672C16.2891 7.88672 16.3828 7.89648 16.4727 7.91602C16.5547 7.93359 16.6328 7.9585 16.7109 7.9917C16.7891 8.02441 16.8594 8.06299 16.9297 8.1084C17.0039 8.15723 17.0703 8.21338 17.1367 8.27734C17.1992 8.34082 17.2539 8.40918 17.3047 8.48242C17.3477 8.55127 17.3867 8.62354 17.4219 8.70068C17.4531 8.77832 17.4805 8.85791 17.4961 8.93896C17.5156 9.03027 17.5273 9.12402 17.5273 9.21973L17.5273 15.1304C17.5273 15.2266 17.5156 15.3198 17.4961 15.4116C17.4805 15.4927 17.4531 15.5718 17.4219 15.6499C17.3867 15.7266 17.3477 15.7993 17.3047 15.8682C17.2539 15.9414 17.1992 16.0098 17.1367 16.0732C17.0703 16.1367 17.0039 16.1929 16.9297 16.2417C16.8633 16.2871 16.7891 16.3262 16.7109 16.3589C16.6328 16.3916 16.5547 16.417 16.4727 16.4346C16.3828 16.4541 16.2891 16.4639 16.1914 16.4639L15.8789 16.4639C15.5547 16.4639 15.3008 16.21 15.3008 15.8867C15.3008 15.5635 15.5547 15.3091 15.8789 15.3091L16.1914 15.3091C16.2188 15.3091 16.2969 15.2656 16.3203 15.2568C16.3359 15.2393 16.3633 15.1519 16.3711 15.1304L16.3711 9.21973C16.3711 9.19531 16.3281 9.11475 16.3203 9.09375C16.3008 9.07617 16.2148 9.0498 16.1914 9.04102L7.80859 9.04102C7.78125 9.04102 7.70312 9.08496 7.67969 9.09375C7.66406 9.11084 7.63672 9.19873 7.62891 9.21973L7.62891 9.39307C7.62891 9.71631 7.375 9.97021 7.05078 9.97021C6.72656 9.97021 6.47266 9.71631 6.47266 9.39307ZM14 10.3901C13.9062 10.3706 13.8125 10.3608 13.7188 10.3608L5.33203 10.3608C5.23828 10.3608 5.14453 10.3706 5.05078 10.3901L5.05078 10.3901C4.97266 10.4077 4.89062 10.4331 4.8125 10.4658C4.73828 10.4985 4.66406 10.5376 4.59766 10.583L4.59766 10.583L4.59766 10.583C4.52344 10.6318 4.45312 10.688 4.39062 10.7515C4.32812 10.8149 4.26953 10.8833 4.22266 10.957C4.17578 11.0254 4.13672 11.0981 4.10547 11.1748C4.07031 11.2529 4.04688 11.332 4.03125 11.4131L4.03125 11.4131C4.01172 11.5049 4 11.5981 4 11.6943L4 17.605C4 17.7007 4.01172 17.7944 4.03125 17.8857C4.04688 17.9668 4.07031 18.0464 4.10547 18.124C4.13672 18.2012 4.17578 18.2739 4.22266 18.3423C4.26953 18.4155 4.32812 18.4839 4.39062 18.5479C4.45312 18.6113 4.52344 18.6675 4.59766 18.7163C4.66406 18.7617 4.73828 18.8008 4.8125 18.833C4.89062 18.8662 4.97266 18.8911 5.05078 18.9087L5.05078 18.9087C5.14453 18.9282 5.23828 18.938 5.33203 18.938L13.7188 18.938C13.8125 18.938 13.9062 18.9282 14 18.9087C14.082 18.8911 14.1602 18.8662 14.2383 18.833C14.3125 18.8008 14.3867 18.7617 14.457 18.7163C14.5273 18.6675 14.5977 18.6113 14.6602 18.5479C14.7227 18.4839 14.7812 18.4155 14.8281 18.3423C14.875 18.2739 14.9141 18.2012 14.9453 18.124C14.9805 18.0464 15.0039 17.9668 15.0234 17.8857C15.043 17.7944 15.0508 17.7007 15.0508 17.605L15.0508 11.6943C15.0508 11.5981 15.043 11.5049 15.0234 11.4131C15.0039 11.332 14.9805 11.2529 14.9453 11.1748C14.9141 11.0981 14.875 11.0254 14.8281 10.957C14.7812 10.8833 14.7227 10.8149 14.6602 10.7515C14.5977 10.688 14.5273 10.6318 14.457 10.583C14.3867 10.5376 14.3125 10.4985 14.2383 10.4658C14.1602 10.4331 14.082 10.4077 14 10.3901ZM5.33203 11.5156L13.7188 11.5156C13.7383 11.5244 13.8281 11.5503 13.8438 11.5679C13.8516 11.5889 13.8984 11.6694 13.8984 11.6943L13.8984 17.605C13.8867 17.626 13.8633 17.7139 13.8438 17.731C13.8242 17.7397 13.7422 17.7837 13.7188 17.7837L5.33203 17.7837C5.3125 17.7749 5.22266 17.7485 5.20703 17.731C5.19922 17.71 5.15625 17.6294 5.15625 17.605L5.15625 11.6943C5.16406 11.6733 5.19141 11.5854 5.20703 11.5679C5.22266 11.5503 5.3125 11.5244 5.33203 11.5156ZM11 12.7754C10.8086 12.5776 10.5 12.5742 10.3008 12.7676C10.1055 12.9614 10.1016 13.2695 10.293 13.4678L11 14.1875L8.36719 14.1875C8.08984 14.1875 7.87109 14.4053 7.87109 14.6826C7.87109 14.9595 8.08984 15.1772 8.36719 15.1772L10.9414 15.1772L10.2969 15.8286C10.1016 16.0254 10.1016 16.3335 10.3008 16.5283C10.4961 16.7236 10.8047 16.7222 11 16.5254L12.5039 15.0078C12.6172 14.8926 12.6758 14.7769 12.6758 14.6611C12.6758 14.5459 12.6172 14.4297 12.5039 14.3135L11 12.7754ZM7.39453 13.6792L7.39453 15.9336C7.39453 16.2109 7.17969 16.4287 6.90234 16.4287C6.625 16.4287 6.40625 16.2109 6.40625 15.9336L6.40625 13.6792C6.40625 13.4019 6.625 13.1841 6.90234 13.1841C7.17969 13.1841 7.39453 13.4019 7.39453 13.6792Z",fill:"rgb(255,255,255)","fill-rule":"evenodd"},null,-1)])])}const V1={name:"events-icon-release",render:w1},S1={summit:"--o-orange-6",events:"--o-cyan-6",competition:"--o-blue-6",release:"--o-purple-6"},b1={events:_1,competition:B1,release:V1,summit:k1},Re={上海:"https://infrastructure-website.osinfra.cn/picture/city/shanghai.jpg",北京:"https://infrastructure-website.osinfra.cn/picture/city/beijing.jpg",南京:"https://infrastructure-website.osinfra.cn/picture/city/nanjing.jpg",天津:"https://infrastructure-website.osinfra.cn/picture/city/tianjin.jpg",成都:"https://infrastructure-website.osinfra.cn/picture/city/chengdu.jpg",无锡:"https://infrastructure-website.osinfra.cn/picture/city/wuxi.jpg",杭州:"https://infrastructure-website.osinfra.cn/picture/city/hangzhou.jpg",深圳:["https://infrastructure-website.osinfra.cn/picture/city/shenzhen1.jpg","https://infrastructure-website.osinfra.cn/picture/city/shenzhen2.jpg"],苏州:"https://infrastructure-website.osinfra.cn/picture/city/suzhou.jpg",西安:"https://infrastructure-website.osinfra.cn/picture/city/xian.jpg",郑州:"https://infrastructure-website.osinfra.cn/picture/city/zhengzhou.jpg",武汉:"https://infrastructure-website.osinfra.cn/picture/city/wuhan.jpg"},L1="https://infrastructure-website.osinfra.cn/picture/city/default-cover.jpg",O1={class:"o-events-calendar"},$1={key:0,class:"month-list"},D1={class:"collapse-header"},x1={class:"collapse-title"},T1={key:0,class:"collapse-desc"},A1={key:0,class:"month-content month-content-span"},I1={key:0,class:"event-location"},M1={class:"event-name"},R1={key:1},z1={key:0,class:"month-content-row"},F1={class:"month-name"},P1={class:"event-name"},H1={class:"event-location"},U1={class:"event-name"},W1={class:"event-location"},G1={key:1,class:"month-content month-content-column"},j1={class:"event-location"},q1={class:"event-name"},K1={key:1},Gt=e.defineComponent({__name:"OEventsCalendar",props:{data:{default:()=>[]}},setup(o){const t=uo(),{lePadV:r}=Q.useScreen(),l=o,a=["JAN","FEB","MAR","Apr","May","JUN","Jul","Aug","Sep","Oct","Nov","Dec"],c=e.ref([]);e.watch([()=>l.data,()=>r.value],()=>{var h;l.data.length?r.value?c.value=[(h=l.data[0])==null?void 0:h.name]:c.value=l.data.map(V=>V.name):c.value=[]},{immediate:!0});const m=h=>{const V=h.split("/");return parseInt(V[1],10)},p=h=>{const V=new Array(12).fill(0),E=[];return h.forEach((N,w)=>{const[k,S]=Array.isArray(N.date)?[m(N.date[0]),m(N.date[1])]:[m(N.date),m(N.date)];let R=0;for(let L=k-1;L<S;L++)R=Math.max(R,V[L]);const g=R+1;for(let L=k-1;L<S;L++)V[L]=g;E.push({event:N,row:g,eventIndex:w,start:k,end:S})}),E},s=h=>{const V=Array.from({length:12},()=>[]);return h.forEach(E=>{const N=Array.isArray(E.date)?m(E.date[0]):m(E.date);V[N-1].push(E)}),V},y=h=>{const V=h.color||S1[h.type];return V!=null&&V.startsWith("--")?`var(${V})`:V},u=h=>h.icon?h.icon:b1[h.type];return(h,V)=>(e.openBlock(),e.createElementBlock("div",O1,[e.unref(r)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",$1,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(a,E=>e.createElementVNode("div",{class:"month-header",key:E},e.toDisplayString(E),1)),64))])),e.createVNode(e.unref(i.OCollapse),{modelValue:c.value,"onUpdate:modelValue":V[0]||(V[0]=E=>c.value=E)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.data,(E,N)=>(e.openBlock(),e.createBlock(e.unref(i.OCollapseItem),{key:N,value:E.name},{title:e.withCtx(()=>[e.createElementVNode("div",D1,[e.createElementVNode("div",x1,[e.createElementVNode("div",{class:"title-icon",style:e.normalizeStyle({"--bg-color":y(E)})},[e.createVNode(e.unref(i.OIcon),null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u(E))))]),_:2},1024)],4),e.createElementVNode("span",null,e.toDisplayString(E.name),1)]),E.desc?(e.openBlock(),e.createElementBlock("div",T1,[e.withDirectives(e.createElementVNode("div",null,null,512),[[e.unref(t),E.desc]])])):e.createCommentVNode("",!0)])]),default:e.withCtx(()=>[E.isSpanMonth?(e.openBlock(),e.createElementBlock("div",A1,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p(E.data),({event:w,row:k,eventIndex:S,start:R,end:g})=>(e.openBlock(),e.createElementBlock("div",{key:S,class:e.normalizeClass(["event-item",{"event-item-center":w.align==="center","has-link":w.link}]),style:e.normalizeStyle({gridColumn:`${R} / ${g+1}`,gridRow:k,"--bg-color":y(E)||void 0})},[w.location?(e.openBlock(),e.createElementBlock("div",I1,e.toDisplayString(w.location),1)):e.createCommentVNode("",!0),e.createElementVNode("div",M1,[w.link?(e.openBlock(),e.createBlock(e.unref(i.OLink),e.mergeProps({key:0,href:w.link,target:"_blank"},{ref_for:!0},w.linkProps||{}),{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(w.name),1)]),_:2},1040,["href"])):(e.openBlock(),e.createElementBlock("span",R1,e.toDisplayString(w.name),1))])],6))),128))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.unref(r)?(e.openBlock(),e.createElementBlock("div",z1,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s(E.data),(w,k)=>(e.openBlock(),e.createElementBlock("div",{key:k,class:e.normalizeClass(["month-row",{"empty-month":w.length===0}])},[e.createElementVNode("div",F1,e.toDisplayString(a[k]),1),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w,(S,R)=>(e.openBlock(),e.createElementBlock("div",{key:R,class:e.normalizeClass(["event-item",S.link?"has-link":""]),style:e.normalizeStyle({"--bd-color":y(E)||void 0})},[S.link?(e.openBlock(),e.createBlock(e.unref(i.OLink),{key:0,href:S.link,target:"_blank"},{default:e.withCtx(()=>[e.createElementVNode("div",null,[e.createElementVNode("div",P1,[e.createElementVNode("span",null,e.toDisplayString(S.name),1)]),e.createElementVNode("div",H1,e.toDisplayString(S.location),1)]),e.createVNode(e.unref(i.OIcon),null,{default:e.withCtx(()=>[e.createVNode(e.unref(i.OIconChevronRight))]),_:1})]),_:2},1032,["href"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",U1,e.toDisplayString(S.name),1),e.createElementVNode("div",W1,e.toDisplayString(S.location),1)],64))],6))),128))],2))),128))])):(e.openBlock(),e.createElementBlock("div",G1,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s(E.data),(w,k)=>(e.openBlock(),e.createElementBlock("div",{key:k,class:"month-column"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w,(S,R)=>(e.openBlock(),e.createElementBlock("div",{key:R,class:e.normalizeClass(["event-item",S.link?"has-link":""]),style:e.normalizeStyle({"--bg-color":y(E)||void 0})},[e.createElementVNode("div",j1,e.toDisplayString(S.location),1),e.createElementVNode("div",q1,[S.link?(e.openBlock(),e.createBlock(e.unref(i.OLink),{key:0,href:S.link,target:"_blank"},{suffix:e.withCtx(()=>[e.createVNode(e.unref(i.OIcon),null,{default:e.withCtx(()=>[e.createVNode(e.unref(i.OIconChevronRight))]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(S.name),1)]),_:2},1032,["href"])):(e.openBlock(),e.createElementBlock("span",K1,e.toDisplayString(S.name),1))])],6))),128))]))),128))]))],64))]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]))}});var de=(o=>(o.FINISH="finish",o.ING="ing",o.ALL="",o))(de||{});const jt=(o,t)=>new Date(o).getTime()>new Date(t).getTime(),Z1={class:"o-events-list"},Y1={class:"filter-wrapper"},X1={class:"filter-left"},J1={class:"list-content"},Q1={class:"event-name"},ec={class:"event-desc"},tc={class:"event-date"},oc={key:0,class:"event-location"},qt=e.defineComponent({__name:"OEventsList",props:{data:{default:()=>[]},page:{},pageSize:{},total:{}},emits:["search"],setup(o,{emit:t}){const{t:r}=H.useI18n(),{lePadV:l}=Q.useScreen(),a=o,c=[{label:r("events.statusAll"),value:de.ALL},{label:r("events.statusIng"),value:de.ING},{label:r("events.statusFinish"),value:de.FINISH}],m=t,p=e.ref(de.ALL),s=e.ref(""),y=e.ref(""),u=(N={})=>{m("search",Object.assign({page:a.page,pageSize:a.pageSize,status:p.value,keyword:y.value},N))},h=()=>{u()},V=()=>{y.value=s.value,u()},E=e.computed(()=>a.data.map(N=>({...N,status:jt(new Date,N.date)?de.FINISH:de.ING})).sort((N,w)=>jt(N.date,w.date)?-1:1).map(N=>{var S,R,g;const w=(g=(R=(S=N.city)==null?void 0:S.replace("市",""))==null?void 0:R.replace("中国",""))==null?void 0:g.replaceAll(" ","");let k=null;return Array.isArray(Re[w])?k=Re[w][N.name.length%Re[w].length]:k=Re[w],k||(k=L1),{...N,cover:k}}));return(N,w)=>(e.openBlock(),e.createElementBlock("div",Z1,[e.createElementVNode("div",Y1,[e.createElementVNode("div",X1,[e.createElementVNode("span",null,e.toDisplayString(e.unref(r)("events.status")),1),e.createVNode(e.unref(i.ORadioGroup),{modelValue:p.value,"onUpdate:modelValue":w[0]||(w[0]=k=>p.value=k),style:{"--radio-group-gap":"8px"},onChange:h},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(c,k=>e.createVNode(e.unref(i.ORadio),{key:k.value,value:k.value},{radio:e.withCtx(({checked:S})=>[e.createVNode(e.unref(i.OToggle),{checked:S},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(k.label),1)]),_:2},1032,["checked"])]),_:2},1032,["value"])),64))]),_:1},8,["modelValue"])]),e.createVNode(e.unref(i.OInput),{modelValue:s.value,"onUpdate:modelValue":w[1]||(w[1]=k=>s.value=k),placeholder:e.unref(r)("events.searchPlaceholder"),onPressEnter:V,onClear:V,clearable:""},{prefix:e.withCtx(()=>[e.createVNode(e.unref(i.OIcon),{class:"input-icon"},{default:e.withCtx(()=>[e.createVNode(e.unref(i.OIconSearch))]),_:1})]),_:1},8,["modelValue","placeholder"])]),e.createElementVNode("div",J1,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,k=>(e.openBlock(),e.createBlock(e.unref(i.OCard),{key:k.name,cover:k.cover,href:k.link},{default:e.withCtx(()=>[e.createVNode(e.unref(i.OTag),{class:"event-status"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(k.status===e.unref(de).ING?e.unref(r)("events.statusIng"):e.unref(r)("events.statusFinish")),1)]),_:2},1024),e.createElementVNode("div",Q1,e.toDisplayString(k.name),1),e.createElementVNode("div",ec,[e.createElementVNode("div",tc,e.toDisplayString(k.date),1),e.createVNode(e.unref(i.ODivider),{direction:"v"}),k.city?(e.openBlock(),e.createElementBlock("div",oc,e.toDisplayString(k.city),1)):e.createCommentVNode("",!0)])]),_:2},1032,["cover","href"]))),128))]),E.value.length?e.createCommentVNode("",!0):e.renderSlot(N.$slots,"empty",{key:0}),o.total>8?(e.openBlock(),e.createBlock(e.unref(i.OPagination),{key:1,page:o.page,simple:e.unref(l),"show-total":!0,pageSize:o.pageSize,total:o.total,onChange:u,pageSizes:[4,12,24,36,48]},null,8,["page","simple","pageSize","total"])):e.createCommentVNode("",!0)]))}}),nc={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function rc(o,t){return e.openBlock(),e.createElementBlock("svg",nc,[...t[0]||(t[0]=[e.createElementVNode("path",{fill:"#1da9ff",d:"M20.4 5.95c0.27-0.27 0.71-0.27 0.99 0 0.24 0.25 0.27 0.63 0.070 0.91l-0.070 0.080-10.5 10.47c-0.53 0.53-1.36 0.56-1.93 0.1l-0.11-0.1-5.23-5.2c-0.28-0.28-0.28-0.72-0.010-0.99 0.25-0.25 0.63-0.28 0.91-0.080l0.080 0.070 5.24 5.21c0.010 0.010 0.030 0.010 0.040 0.010l0.030-0.010 10.49-10.47z"},null,-1)])])}const ac={name:"events-icon-checked",render:rc},lc={class:"o-events-apply"},cc={class:"events-apply-grid"},sc={class:"timeline-number"},ic={class:"number-circle"},dc={class:"step-title"},uc={class:"step-idx"},mc={class:"step-desc"},pc={key:0},fc={class:"desc-list-wrapper"},hc={key:0,class:"desc-list-title"},vc={class:"desc-list-content"},kc={class:"desc-list-item-title"},gc={class:"desc-list-item-desc"},Kt=e.defineComponent({__name:"OEventsApply",props:{steps:{}},setup(o){const{isDark:t}=Q.useTheme(),r=uo();return(l,a)=>(e.openBlock(),e.createElementBlock("div",lc,[e.createElementVNode("div",cc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.steps,(c,m)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:m},[e.createElementVNode("div",sc,[e.createElementVNode("div",ic,e.toDisplayString(m+1),1)]),e.createElementVNode("div",{class:e.normalizeClass(["step-item",`step-${m+1} ${e.unref(t)?"is-dark":""}`]),style:{}},[e.createElementVNode("div",dc,[e.createElementVNode("div",uc,e.toDisplayString(m+1),1),e.createElementVNode("span",null,e.toDisplayString(c.title),1)]),e.createElementVNode("div",mc,[c.desc?e.withDirectives((e.openBlock(),e.createElementBlock("div",pc,null,512)),[[e.unref(r),c.desc]]):e.createCommentVNode("",!0),e.renderSlot(l.$slots,`step${m+1}`),e.createElementVNode("div",fc,[c.listTitle?(e.openBlock(),e.createElementBlock("div",hc,e.toDisplayString(c.listTitle),1)):e.createCommentVNode("",!0),e.createElementVNode("div",vc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.list,(p,s)=>(e.openBlock(),e.createElementBlock("div",{class:"desc-list-item",key:s},[e.createElementVNode("div",kc,[e.createVNode(e.unref(i.OIcon),null,{default:e.withCtx(()=>[e.createVNode(e.unref(ac))]),_:1}),e.createElementVNode("span",null,e.toDisplayString(p.title),1)]),e.createElementVNode("div",gc,e.toDisplayString(p.desc),1)]))),128))])])]),c.img?(e.openBlock(),e.createElementBlock("div",{key:0,class:"img-wrapper",style:e.normalizeStyle({backgroundImage:`url(${c.img})`})},null,4)):e.createCommentVNode("",!0),c.imgPhone?(e.openBlock(),e.createElementBlock("div",{key:1,class:"img-wrapper-phone",style:e.normalizeStyle({backgroundImage:`url(${c.imgPhone})`})},null,4)):e.createCommentVNode("",!0)],2)],64))),128))])]))}}),Cc=Object.assign(Gt,{install(o){o.component("OEventsCalendar",Gt)}}),_c=Object.assign(qt,{install(o){o.component("OEventsList",qt)}}),yc=Object.assign(Kt,{install(o){o.component("OEventsApply",Kt)}}),Ec={OBanner:Zt,OCookieNotice:Yt,OFooter:Xt,OHeader:Jt,OHeaderMoblie:eo,OHeaderSearch:to,OHeaderUser:no,OPlusConfigProvider:ro,OSection:ao,OSourceCode:lo,OThemeSwitcher:co},Bc={install:o=>{Object.entries(Ec).forEach(([t,r])=>{o.component(t,r)})}};exports.OElCookieNotice=H.OElCookieNotice;exports.EventsStatusT=de;exports.OBanner=Zt;exports.OCookieNotice=Yt;exports.OEventsApply=yc;exports.OEventsCalendar=Cc;exports.OEventsList=_c;exports.OFooter=Xt;exports.OHeader=Jt;exports.OHeaderMoblie=eo;exports.OHeaderSearch=to;exports.OHeaderUser=no;exports.OPlusConfigProvider=ro;exports.OSection=ao;exports.OSourceCode=lo;exports.OThemeSwitcher=co;exports.default=Bc;
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const n=require("vue"),O=require("@opensig/opendesign"),wt=require("@opendesign-plus/composables"),Ue=require("./chunk-OElCookieNotice.cjs.js"),Mn=require("@vueuse/core"),et=require("element-plus"),Km=require("@opensig/opendesign/es/locale/lang/zh-cn"),Qm=require("@opensig/opendesign/es/locale/lang/en-us"),Zm=n.defineComponent({__name:"ContentWrapper",props:{verticalPadding:{type:[Boolean,String,Array],default:void 0}},setup(s){const e=Symbol("default"),i=s,r=n.computed(()=>i.verticalPadding?O.isBoolean(i.verticalPadding)?e:O.isString(i.verticalPadding)?i.verticalPadding:i.verticalPadding[0]:0),a=n.computed(()=>i.verticalPadding?O.isBoolean(i.verticalPadding)?e:O.isString(i.verticalPadding)?i.verticalPadding:O.isUndefined(i.verticalPadding[1])?i.verticalPadding[0]:i.verticalPadding[1]:0);return(o,l)=>(n.openBlock(),n.createElementBlock("div",{class:"content-wrapper",style:n.normalizeStyle({"--content-wrapper-vertical-paddingTop":r.value===n.unref(e)?void 0:r.value,"--content-wrapper-vertical-paddingBottom":a.value===n.unref(e)?void 0:a.value})},[n.renderSlot(o.$slots,"default",{},void 0,!0)],4))}}),In=Ue._export_sfc(Zm,[["__scopeId","data-v-29de9f52"]]),Jm={key:0},eg={class:"banner-content"},tg=["src"],ig={key:1,class:"banner-title"},ng={key:2,class:"banner-subtitle"},rg={key:4,class:"banner-opts"},sg=n.defineComponent({__name:"OBanner",props:{options:{default:void 0},size:{default:"large"},contentJustifyCenter:{type:Boolean,default:!1}},setup(s){const e=s,{isLight:i}=wt.useTheme("opendesignplus",document.domain||"localhost"),{isPhone:r}=wt.useScreen(),a=n.computed(()=>e.options),o=n.ref(""),l=d=>{setTimeout(()=>{o.value=a.value[d].bg_theme??"light"},100)},u=(d,f)=>{d&&!f&&window.open(d)};return(d,f)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["home-banner",s.size])},[s.size==="tiny"?(n.openBlock(),n.createElementBlock("div",Jm,n.toDisplayString(a.value[1].title),1)):n.unref(r)?n.unref(r)?(n.openBlock(),n.createBlock(n.unref(O.OCarousel),{key:2,class:"banner-carousel",effect:"gallery","indicator-click":"","data-o-theme":o.value,arrow:"never","auto-play":!0,onBeforeChange:l},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,(g,y)=>(n.openBlock(),n.createBlock(n.unref(O.OCarouselItem),{class:n.normalizeClass(["banner-item",`banner-item${y}`]),key:y},{default:n.withCtx(()=>[n.createVNode(In,{class:"banner-wrapper"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OFigure),{class:"banner-bg",src:g.bg,onClick:E=>u(g.href)},null,8,["src","onClick"])]),_:2},1024)]),_:2},1032,["class"]))),128))]),_:1},8,["data-o-theme"])):n.createCommentVNode("",!0):(n.openBlock(),n.createBlock(n.unref(O.OCarousel),{key:1,class:"banner-carousel",effect:"toggle","active-class":"current-slide","indicator-click":"","auto-play":!0,"data-o-theme":o.value,onBeforeChange:l},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,(g,y)=>(n.openBlock(),n.createBlock(n.unref(O.OCarouselItem),{key:y,class:n.normalizeClass(["banner-item",`banner-item${y}`])},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OFigure),{class:n.normalizeClass(["banner-bg",{"with-sticky-bg":g.withStickyBg,"in-dark":!n.unref(i),"cursor-pointer":g.href&&!g.btn}]),src:g.bg,style:n.normalizeStyle({"--pad-offset":g.pad_offset}),onClick:E=>u(g.href,g.btn)},{default:n.withCtx(()=>[n.createVNode(In,{class:n.normalizeClass(["banner-wrapper",["banner-wrapper",s.contentJustifyCenter?"content-center":""]])},{default:n.withCtx(()=>[n.createElementVNode("div",eg,[!n.unref(r)&&g.attach?(n.openBlock(),n.createElementBlock("img",{key:0,src:g.attach,class:"banner-attach"},null,8,tg)):n.createCommentVNode("",!0),g.title?(n.openBlock(),n.createElementBlock("div",ig,n.toDisplayString(g.title),1)):n.createCommentVNode("",!0),g.subtitle?(n.openBlock(),n.createElementBlock("div",ng,n.toDisplayString(g.subtitle),1)):n.createCommentVNode("",!0),g.bg_text?(n.openBlock(),n.createElementBlock("div",{key:3,class:"banner-text",style:n.normalizeStyle({backgroundImage:`url(${g.bg_text})`,"--pc-width":g.pc_text_width,"--pc-height":g.pc_text_height,"--pad-width":g.pad_text_width,"--pad-height":g.pad_text_height})},null,4)):n.createCommentVNode("",!0),g.btn?(n.openBlock(),n.createElementBlock("div",rg,[n.createVNode(n.unref(O.OButton),{href:g.href,target:"_blank",variant:"solid",color:"primary",size:s.size},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(g.btn),1)]),_:2},1032,["href","size"])])):n.createCommentVNode("",!0)])]),_:2},1032,["class"])]),_:2},1032,["src","class","style","onClick"])]),_:2},1032,["class"]))),128))]),_:1},8,["data-o-theme"]))],2))}}),oh=Ue._export_sfc(sg,[["__scopeId","data-v-2356da15"]]),ag={key:0,class:"cookie-notice"},og={class:"cookie-notice-content"},lg=["type"],ug={class:"cookie-notice-left"},cg={key:0,class:"cookie-desc",style:{"margin-top":"0"}},dg=["href"],hg={class:"cookie-title"},fg={class:"cookie-desc"},pg=["href"],mg={key:0,class:"cookie-notice-right"},gg={class:"cookie-dlg-title"},_g={class:"cookie-dlg-content"},yg={class:"content-item"},vg={class:"item-header"},Tg={class:"item-title"},bg={class:"item-extra"},xg={class:"item-detail"},Cg={class:"content-item"},Sg={class:"item-header"},Eg={class:"item-title"},kg={class:"item-extra"},wg={class:"item-detail"},Dg="0",tc="1",Ag="2",Ls="3",Ig="agreed-cookiepolicy-zh",Ng="agreed-cookiepolicy-en",Og=n.defineComponent({__name:"OCookieNotice",props:{visible:{type:Boolean},enableGrid:{type:Boolean},community:{},detailUrl:{},wrapper:{},cookieDomain:{}},emits:["update:visible"],setup(s,{expose:e,emit:i}){const r=s,a=i,{lePadV:o,leLaptop:l}=wt.useScreen(),{locale:u,t:d}=Ue.useI18n(),f=n.computed(()=>u.value==="zh"),g=n.computed(()=>f.value?Ig:Ng),y=n.ref(!1),E=Mn.useVModel(r,"visible",a,{defaultValue:!1}),x=b=>{const C=document.cookie.split(";").find(U=>U.split("=")[0].trim()===encodeURIComponent(b));return C?decodeURIComponent(C.split("=")[1]):null},B=(b,C,U,j)=>{const k=`; max-age=${U*24*60*60}`;document.cookie=`${encodeURIComponent(b)}=${encodeURIComponent(C)}${k}; path=/; domain=${j}`},T=(b,C)=>{document.cookie=`${encodeURIComponent(b)}=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/; domain=${C}`},w=b=>{typeof b=="boolean"?E.value=b:E.value=!E.value,n.nextTick(()=>{!E.value&&f.value&&x(g.value)!==Ls&&B(g.value,Ls,180,r.cookieDomain??location.hostname)})},F=n.ref(!1),P=b=>{typeof b=="boolean"?F.value=b:F.value=!F.value},I=()=>f.value?x(g.value)!==Ls:(x(g.value)??"0")===Dg,K=()=>f.value?x(g.value)===Ls:x(g.value)===tc;n.onMounted(()=>{I()&&w(!0)}),n.watch(u,()=>{w(I())});const q=()=>{y.value=!0,T(g.value,r.cookieDomain??location.hostname),B(g.value,tc,180,r.cookieDomain??location.hostname),w(!1)},M=()=>{y.value=!1,T(g.value,r.cookieDomain??location.hostname),B(g.value,Ag,180,r.cookieDomain??location.hostname),w(!1)},N=n.computed(()=>[{id:"save",color:"primary",label:d("cookie.saveSetting"),variant:"outline",size:"large",round:"pill",onClick:()=>{y.value?q():M(),P(!1)}},{id:"allowAll",color:"primary",label:d("cookie.acceptAll"),variant:"outline",size:"large",round:"pill",onClick:()=>{y.value=!0,q(),P(!1)}}]),J=b=>{b&&(y.value=K())};return e({check(){K()===E.value&&w()}}),(b,C)=>(n.openBlock(),n.createBlock(n.unref(Ue.ClientOnly),null,{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.Teleport,{to:s.wrapper||"#app"},[n.unref(E)?(n.openBlock(),n.createElementBlock("div",ag,[n.createElementVNode("div",og,[n.createElementVNode("div",{type:n.unref(u),class:n.normalizeClass({"cookie-notice-wrap-grid":s.enableGrid,"cookie-notice-wrap":!s.enableGrid})},[n.createElementVNode("div",ug,[f.value?(n.openBlock(),n.createElementBlock("p",cg,[n.createTextVNode(n.toDisplayString(n.unref(d)("cookie.desc"))+" ",1),n.createElementVNode("a",{href:s.detailUrl,target:"_blank",rel:"noopener noreferrer"},n.toDisplayString(n.unref(d)("cookie.about")),9,dg)])):(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createElementVNode("p",hg,n.toDisplayString(n.unref(d)("cookie.title",[s.community])),1),n.createElementVNode("p",fg,[n.createTextVNode(n.toDisplayString(n.unref(d)("cookie.desc"))+" ",1),n.createElementVNode("a",{href:s.detailUrl,target:"_blank",rel:"noopener noreferrer"},n.toDisplayString(n.unref(d)("cookie.about")),9,pg),C[4]||(C[4]=n.createTextVNode(". ",-1))])],64))]),f.value?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",mg,[n.createVNode(n.unref(O.OButton),{round:"pill",variant:"outline",color:"primary",onClick:q},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(d)("cookie.acceptAll")),1)]),_:1}),n.createVNode(n.unref(O.OButton),{round:"pill",variant:"outline",color:"primary",onClick:M},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(d)("cookie.rejectAll")),1)]),_:1}),n.createVNode(n.unref(O.OButton),{round:"pill",variant:"outline",color:"primary",onClick:C[0]||(C[0]=U=>P(!0))},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(d)("cookie.manage")),1)]),_:1})])),n.createVNode(n.unref(O.OIcon),{class:"cookie-notice-close",type:n.unref(u),onClick:C[1]||(C[1]=U=>w(!1))},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconClose))]),_:1},8,["type"])],10,lg)]),n.createVNode(n.unref(O.ODialog),{visible:F.value,"onUpdate:visible":C[3]||(C[3]=U=>F.value=U),size:n.unref(l)?"medium":"large","phone-half-full":n.unref(o),class:"cookie-dlg",actions:N.value,onChange:J},{header:n.withCtx(()=>[n.createElementVNode("span",gg,n.toDisplayString(n.unref(d)("cookie.manage")),1)]),default:n.withCtx(()=>[n.createElementVNode("div",_g,[n.createElementVNode("div",yg,[n.createElementVNode("div",vg,[n.createElementVNode("span",Tg,n.toDisplayString(n.unref(d)("cookie.necessaryCookie")),1),n.createElementVNode("span",bg,n.toDisplayString(n.unref(d)("cookie.alwaysOn")),1)]),n.createElementVNode("div",xg,n.toDisplayString(n.unref(d)("cookie.necessaryCookieDetail")),1)]),n.createElementVNode("div",Cg,[n.createElementVNode("div",Sg,[n.createElementVNode("span",Eg,n.toDisplayString(n.unref(d)("cookie.analyticalCookie")),1),n.createElementVNode("span",kg,[n.createVNode(n.unref(O.OSwitch),{modelValue:y.value,"onUpdate:modelValue":C[2]||(C[2]=U=>y.value=U)},null,8,["modelValue"])])]),n.createElementVNode("div",wg,n.toDisplayString(n.unref(d)("cookie.analyticalCookieDetail")),1)])])]),_:1},8,["visible","size","phone-half-full","actions"])])):n.createCommentVNode("",!0)],8,["to"]))]),_:1}))}}),lh=Ue._export_sfc(Og,[["__scopeId","data-v-f1dd144c"]]),Bg={key:0,class:"atom"},Lg={class:"atom-text"},Pg=["href"],Mg=["src"],Rg={key:0,class:"quick-nav"},Vg={class:"category-title"},Fg={class:"navs"},$g=["href"],Ug={key:0,class:"friendship-link"},qg={class:"friendship-link-title"},jg={class:"friendship-link-box"},Hg=["href"],zg={key:0,class:"footer-logo"},Gg=["src"],Wg=["src"],Yg=["href"],Xg={key:1,class:"footer-option"},Kg={class:"footer-option-item"},Qg=["href"],Zg={class:"license"},Jg={class:"copyright"},e1={class:"filing"},t1=["href"],i1=["src"],n1={key:2,class:"footer-right"},r1={key:0,class:"code-box"},s1=["src"],a1={class:"code-layer"},o1=["src"],l1={class:"txt"},u1={class:"app-footer-pc"},c1={key:0,class:"footer-left"},d1=["href"],h1=["src"],f1={key:0,class:"footer-right"},p1=["href"],m1={class:"app-footer-mb"},g1={key:0,class:"links"},_1=["href"],y1={class:"copyright"},v1={key:0,class:"approval"},T1=["href"],b1=["src"],x1=n.defineComponent({__name:"OFooter",setup(s){const e=s;return(i,r)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass([e.simple?"app-footer-simple":"app-footer"])},[e.simple?(n.openBlock(),n.createBlock(In,{key:1},{default:n.withCtx(()=>[n.createElementVNode("div",u1,[i.$slots.left||e.footerOption?n.renderSlot(i.$slots,"left",{key:0},()=>[e.footerOption?(n.openBlock(),n.createElementBlock("div",c1,[n.createElementVNode("span",null,n.toDisplayString(e.footerOption[e.lang].copyright),1),n.createElementVNode("a",{class:"approval",href:e.footerOption[e.lang].beianLink,target:"_blank",rel:"noopener noreferrer"},n.toDisplayString(e.footerOption[e.lang].beianInfo1),9,d1),n.createElementVNode("img",{class:"police-img",src:e.footerOption[e.lang].policeIcon},null,8,h1),n.createElementVNode("span",null,n.toDisplayString(e.footerOption[e.lang].beianInfo2),1)])):n.createCommentVNode("",!0)],!0):n.createCommentVNode("",!0),i.$slots.right||e.footerOption?n.renderSlot(i.$slots,"right",{key:1},()=>[e.footerOption?(n.openBlock(),n.createElementBlock("div",f1,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.footerOption[e.lang].link,(a,o)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:a.url},[n.createElementVNode("a",{target:"_blank",href:a.url,class:"link"},n.toDisplayString(a.name),9,p1),o!==e.footerOption[e.lang].link.length-1?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:0,direction:"v"})):n.createCommentVNode("",!0)],64))),128))])):n.createCommentVNode("",!0)],!0):n.createCommentVNode("",!0)]),n.createElementVNode("div",m1,[i.$slots.right||e.footerOption?n.renderSlot(i.$slots,"right",{key:0},()=>[e.footerOption?(n.openBlock(),n.createElementBlock("div",g1,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.footerOption[e.lang].link,(a,o)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:a.url},[n.createElementVNode("a",{target:"_blank",href:a.url,class:"link"},n.toDisplayString(a.name),9,_1),o!==e.footerOption[e.lang].link.length-1?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:0,direction:"v"})):n.createCommentVNode("",!0)],64))),128))])):n.createCommentVNode("",!0)],!0):n.createCommentVNode("",!0),n.renderSlot(i.$slots,"copyright",{},()=>[n.createElementVNode("div",y1,n.toDisplayString(e.footerOption[e.lang].copyright),1)],!0),i.$slots.left||e.footerOption?n.renderSlot(i.$slots,"left",{key:1},()=>[e.footerOption?(n.openBlock(),n.createElementBlock("div",v1,[n.createElementVNode("a",{href:e.footerOption[e.lang].beianLink,target:"_blank",rel:"noopener noreferrer"},n.toDisplayString(e.footerOption[e.lang].beianInfo1),9,T1),n.createElementVNode("img",{class:"police-img",src:e.footerOption[e.lang].policeIcon},null,8,b1),n.createElementVNode("span",null,n.toDisplayString(e.footerOption[e.lang].beianInfo2),1)])):n.createCommentVNode("",!0)],!0):n.createCommentVNode("",!0)])]),_:3})):(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[i.$slots.atom||e.atom?(n.openBlock(),n.createBlock(In,{key:0},{default:n.withCtx(()=>[n.renderSlot(i.$slots,"atom",{},()=>[e.atom?(n.openBlock(),n.createElementBlock("div",Bg,[n.createElementVNode("p",Lg,n.toDisplayString(e.atom[e.lang].title),1),n.createElementVNode("a",{href:e.atom[e.lang].href,target:"_blank"},[n.createElementVNode("img",{src:e.atom[e.lang].img,class:"atom-logo",alt:""},null,8,Mg)],8,Pg)])):n.createCommentVNode("",!0),n.createVNode(n.unref(O.ODivider),{class:"atom-divider"})],!0)]),_:3})):n.createCommentVNode("",!0),n.createElementVNode("div",{class:"footer-content",style:n.normalizeStyle({backgroundImage:`url(${e.footerBg})`})},[n.createVNode(In,null,{default:n.withCtx(()=>[i.$slots.quickNav||e.quickNav?n.renderSlot(i.$slots,"quickNav",{key:0},()=>[e.quickNav?(n.openBlock(),n.createElementBlock("div",Rg,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.quickNav[e.lang],a=>(n.openBlock(),n.createElementBlock("div",{key:a.title,class:"category"},[n.createElementVNode("div",Vg,n.toDisplayString(a.title),1),n.createElementVNode("ul",Fg,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.list,o=>(n.openBlock(),n.createElementBlock("li",{key:o.title,class:"nav"},[n.createElementVNode("a",{href:o.link,target:"_blank",rel:"noopener noreferrer"},n.toDisplayString(o.title),9,$g)]))),128))])]))),128))])):n.createCommentVNode("",!0)],!0):n.createCommentVNode("",!0),i.$slots.friendshipLink||e.friendshipLink?n.renderSlot(i.$slots,"friendshipLink",{key:1},()=>[e.friendshipLink?(n.openBlock(),n.createElementBlock("div",Ug,[n.createElementVNode("div",qg,n.toDisplayString(e.friendshipLink.title[e.lang]),1),n.createElementVNode("div",jg,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.friendshipLink.link[e.lang],a=>(n.openBlock(),n.createElementBlock("a",{href:a.link,key:a.link,target:"_blank"},n.toDisplayString(a.title),9,Hg))),128))])])):n.createCommentVNode("",!0)],!0):n.createCommentVNode("",!0),n.renderSlot(i.$slots,"footer",{},()=>[n.createElementVNode("div",{class:n.normalizeClass(["inner",{"inner-en":e.lang==="en"}])},[e.footerLogo?(n.openBlock(),n.createElementBlock("div",zg,[n.createElementVNode("img",{class:"show-pc",src:e.footerLogo.logo,alt:""},null,8,Gg),n.createElementVNode("img",{class:"show-mo",src:e.footerLogo.logoMb,alt:""},null,8,Wg),n.createElementVNode("p",null,[n.createElementVNode("a",{class:"email",href:`mailto:${e.footerLogo.email}`,target:"_blank"},n.toDisplayString(e.footerLogo.email),9,Yg)])])):n.createCommentVNode("",!0),e.footerOption?(n.openBlock(),n.createElementBlock("div",Xg,[n.createElementVNode("div",Kg,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.footerOption[e.lang].link,(a,o)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:a.url},[n.createElementVNode("a",{target:"_blank",href:a.url},n.toDisplayString(a.name),9,Qg),o!==e.footerOption[e.lang].link.length-1?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:0,style:{"--o-divider-bd-color":"var(--o-color-info3-inverse)","--o-divider-label-gap":"0 8px"},direction:"v"})):n.createCommentVNode("",!0)],64))),128))]),n.createElementVNode("p",Zg,[n.createElementVNode("span",null,n.toDisplayString(e.footerOption[e.lang].licenseText),1),n.createTextVNode(" "+n.toDisplayString(e.footerOption[e.lang].licenseInfo),1)]),n.createElementVNode("div",Jg,[n.createElementVNode("p",null,n.toDisplayString(e.footerOption[e.lang].copyright),1),n.createElementVNode("div",e1,[n.createElementVNode("a",{href:e.footerOption[e.lang].beianLink,target:"_blank"},n.toDisplayString(e.footerOption[e.lang].beianInfo1),9,t1),n.createElementVNode("img",{src:e.footerOption[e.lang].policeIcon,class:"filing-img"},null,8,i1),n.createElementVNode("p",null,n.toDisplayString(e.footerOption[e.lang].beianInfo2),1)])])])):n.createCommentVNode("",!0),e.qrcode?(n.openBlock(),n.createElementBlock("div",n1,[e.lang==="zh"?(n.openBlock(),n.createElementBlock("div",r1,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.qrcode,(a,o)=>(n.openBlock(),n.createElementBlock("div",{key:o,class:"code-pop"},[n.createElementVNode("img",{src:a.img,class:"code-img",alt:""},null,8,s1),n.createElementVNode("div",a1,[n.createElementVNode("img",{src:a.code,alt:""},null,8,o1),n.createElementVNode("p",l1,n.toDisplayString(a.label),1)])]))),128))])):n.createCommentVNode("",!0)])):n.createCommentVNode("",!0)],2)],!0)]),_:3})],4)],64))],2))}}),uh=Ue._export_sfc(x1,[["__scopeId","data-v-e3abaa88"]]),C1={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function S1(s,e){return n.openBlock(),n.createElementBlock("svg",C1,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M9.461 11.616l4.719-3.932c0.212-0.177 0.527-0.148 0.704 0.064 0.075 0.090 0.116 0.203 0.116 0.32v7.865c0 0.276-0.224 0.5-0.5 0.5-0.117 0-0.23-0.041-0.32-0.116l-4.719-3.932c-0.212-0.177-0.241-0.492-0.064-0.704 0.019-0.023 0.041-0.045 0.064-0.064z"},null,-1)])])}const E1={name:"components-icon-caret-left",render:S1},k1={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function w1(s,e){return n.openBlock(),n.createElementBlock("svg",k1,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M14.539 11.616l-4.719-3.932c-0.212-0.177-0.527-0.148-0.704 0.064-0.075 0.090-0.116 0.203-0.116 0.32v7.865c0 0.276 0.224 0.5 0.5 0.5 0.117 0 0.23-0.041 0.32-0.116l4.719-3.932c0.212-0.177 0.241-0.492 0.064-0.704-0.019-0.023-0.041-0.045-0.064-0.064z"},null,-1)])])}const D1={name:"components-icon-caret-right",render:w1},A1={class:"header-content"},I1={key:0,class:"right-icon"},N1=["onMouseenter"],O1=["id"],B1={class:"nav-drop-content"},L1={class:"nav-sub-content"},P1={class:"content-left"},M1={class:"content-label"},R1={class:"content-container"},V1=["onClick"],F1={class:"item-name"},$1={key:0,class:"desc-container"},U1=["title"],q1={key:0,class:"split-line"},j1={key:1,class:"content-right"},H1=["onClick"],z1=["onClick"],G1=["src"],W1={class:"review-content"},Y1={class:"review-label"},X1={class:"review-property"},K1={key:1,class:"right-icon"},Q1=n.defineComponent({__name:"HeaderEulerNav",props:{navData:void 0,bgLeft:void 0,bgRight:void 0},setup(s){const e=s,{locale:i}=wt.useLocale(),{theme:r,isDark:a}=wt.useTheme(),o=n.ref(),l=n.ref(),u=n.ref(null),d=n.ref(!1),f=n.ref(!1),g=n.ref(!1),y=n.ref(),E=n.ref([]),x=n.ref([]),B=n.ref(!1),T=Mn.useDebounceFn(function(M){M===null?(y.value="",g.value=!1,B.value=!1):(y.value=M.id,g.value=!0,E.value=M.children,x.value=M.shortcut,B.value=M.withPicture)},100),w=(M,N)=>{window.open(M,N),y.value="",g.value=!1},F=n.ref(!1),P=M=>{!M||!M.target||(F.value=M.target.clientHeight<M.target.scrollHeight)},I=()=>{f.value=!0,n.nextTick(()=>{o.value.scrollTo({left:o.value.clientWidth,behavior:"smooth"})})},K=()=>{o.value.scrollTo({left:0,behavior:"smooth"}),f.value=!1},q=()=>{var M,N;((M=o.value)==null?void 0:M.clientWidth)<((N=l.value)==null?void 0:N.clientWidth)&&(d.value=!0)};return n.onMounted(()=>{window.addEventListener("resize",q),n.nextTick(()=>{q(),u.value=setTimeout(()=>{q()},1e3)})}),n.onUnmounted(()=>{window.removeEventListener("resize",q),clearTimeout(u.value)}),(M,N)=>(n.openBlock(),n.createElementBlock("div",A1,[n.createElementVNode("div",{class:n.normalizeClass(["header-nav",{"header-nav-scroll":f.value}])},[f.value?(n.openBlock(),n.createElementBlock("div",I1,[n.createVNode(n.unref(O.OIcon),{onClick:K},{default:n.withCtx(()=>[n.createVNode(n.unref(E1))]),_:1})])):n.createCommentVNode("",!0),n.createElementVNode("nav",{ref_key:"navRef",ref:o,class:n.normalizeClass(["o-nav",{"o-nav-scroll":f.value||!d.value,dark:n.unref(a)}])},[n.createElementVNode("ul",{ref_key:"navListRef",ref:l,class:"o-nav-list"},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.navData,J=>(n.openBlock(),n.createElementBlock("li",{key:J.id,onMouseenter:b=>n.unref(T)(J),onMouseleave:N[1]||(N[1]=b=>n.unref(T)(null))},[n.createElementVNode("span",{id:"tour_headerNav_"+J.ID,class:"nav-item"},n.toDisplayString(J.label),9,O1),n.createVNode(n.Transition,{name:"transition"},{default:n.withCtx(()=>[g.value?(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass(["nav-dropdown",y.value,n.unref(r),`${y.value}-${n.unref(i)}`])},[n.createElementVNode("div",B1,[n.createElementVNode("div",{class:"nav-background-left",style:n.normalizeStyle({backgroundImage:`url(${e.bgLeft})`})},null,4),n.createElementVNode("div",{class:"nav-background-right",style:n.normalizeStyle({backgroundImage:`url(${e.bgRight})`})},null,4),n.createVNode(n.unref(O.OScroller),{class:"nav-scroller","show-type":"always",size:"small","disabled-y":""},{default:n.withCtx(()=>{var b,C;return[n.createElementVNode("div",L1,[n.createElementVNode("div",P1,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(E.value,(U,j)=>(n.openBlock(),n.createElementBlock("div",{class:"item-sub",key:j},[n.createElementVNode("span",M1,n.toDisplayString(U.label),1),n.createElementVNode("div",R1,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(U.children,k=>(n.openBlock(),n.createElementBlock("div",{key:k.label,class:"content-item"},[n.createElementVNode("a",{onClick:A=>w(k.href,"_self"),rel:"noopener noreferrer",class:"item-label"},[n.createElementVNode("span",F1,n.toDisplayString(k.label),1),k.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(k.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0),k.tag?(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:1,round:"pill",color:"danger",size:"small",class:"content-tag"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(k.tag),1)]),_:2},1024)):n.createCommentVNode("",!0)],8,V1),k.description?(n.openBlock(),n.createElementBlock("div",$1,[n.createElementVNode("p",{class:"item-desc",title:F.value?k.description:null,onMouseenter:N[0]||(N[0]=A=>P(A))},n.toDisplayString(k.description),41,U1)])):n.createCommentVNode("",!0)]))),128))])]))),128))]),(b=x.value)!=null&&b.length?(n.openBlock(),n.createElementBlock("div",q1)):n.createCommentVNode("",!0),(C=x.value)!=null&&C.length?(n.openBlock(),n.createElementBlock("div",j1,[N[2]||(N[2]=n.createElementVNode("span",{class:"content-label"},"快捷链接",-1)),B.value?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:1},n.renderList(x.value,U=>(n.openBlock(),n.createElementBlock("a",{key:U.label,onClick:j=>w(U.href,"_self"),rel:"noopener noreferrer",class:"review"},[n.createElementVNode("img",{src:U.picture,class:"review-picture"},null,8,G1),n.createElementVNode("div",W1,[n.createElementVNode("p",Y1,n.toDisplayString(U.label),1),n.createElementVNode("div",X1,[n.createElementVNode("span",null,n.toDisplayString(U.remark),1)])])],8,z1))),128)):(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:0},n.renderList(x.value,U=>(n.openBlock(),n.createElementBlock("div",{key:U.label,class:"shortcut"},[n.createElementVNode("a",{onClick:j=>w(U.href,"_self"),rel:"noopener noreferrer",class:"shortcut-link"},[n.createElementVNode("span",null,n.toDisplayString(U.label),1),U.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(U.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0)],8,H1)]))),128))])):n.createCommentVNode("",!0)])]}),_:1})])],2)):n.createCommentVNode("",!0)]),_:1})],40,N1))),128))],512)],2),d.value&&!f.value?(n.openBlock(),n.createElementBlock("div",K1,[n.createVNode(n.unref(O.OIcon),{onClick:I},{default:n.withCtx(()=>[n.createVNode(n.unref(D1))]),_:1})])):n.createCommentVNode("",!0)],2)]))}}),Z1=Ue._export_sfc(Q1,[["__scopeId","data-v-d3d0a9ef"]]),J1=["id","onMouseenter","onMouseleave"],e2=["href"],t2={key:1,class:"info-wrap"},i2={class:"dropdown-wrapper"},n2={key:0,class:"tab-disabled"},r2={key:1,class:"tab-expand"},s2=["href","target","rel"],a2={class:"dropdown-body-wrapper",style:{display:"none !important"}},o2=["onMouseenter"],l2={key:0,class:"dropdown-item"},u2={class:"tab-disabled"},c2={key:1,class:"dropdown-item"},d2=["href","target","rel"],qn="more",h2=n.defineComponent({__name:"HeaderUbmcNav",props:{navData:void 0,hasPerm:void 0,tagMap:void 0,currentPath:void 0},setup(s){const e=s,{locale:i}=wt.useLocale(),{lePadV:r}=wt.useScreen(),a={},o=n.ref({}),l=n.ref(-1),u=j=>{l.value=j},d=j=>{var k;l.value=-1,(k=o.value[j])==null||k.clearCheckedNodes()},f=n.ref(-1),g=()=>{var k;const j=(k=a==null?void 0:a.fullPath)==null?void 0:k.split("/").slice(0,3).join("/");f.value=[...B.value,x.value].findIndex(A=>{var Q,H;const $=j==null?void 0:j.indexOf("#");return N.value.length&&!N.value.includes(A.id)&&A.id!==qn?!1:U(A.href)===j||((Q=A.children)==null?void 0:Q.some(V=>{var G;return(G=V.children)!=null&&G.length?V.children.some(Z=>U(Z.href)===j):U(V.href)===j}))||((H=A.keys)==null?void 0:H.includes(j==null?void 0:j.slice(1,$!==-1?$:j==null?void 0:j.length)))})};n.onMounted(()=>{g()}),n.watch(()=>a.path,()=>{g()});const y=(j,k)=>{let A=!0;return j&&(A=A&&new Date(j).getTime()>=Date.now()),k&&(A=A&&i.value===k),A},E=(j,k)=>j.checkPermKey?k[j.checkPermKey]:!0,x=n.computed(()=>({id:qn,label:"更多",children:B.value.filter(j=>!N.value.includes(j.id))||[]})),B=n.computed(()=>{const j=[];let k=[];const A={meeting:e.hasPerm};try{k=e.navData.filter($=>E($,A)).map(function $(Q){j.push(Q.label);const H={...Q,_path:[...j]};return Q.children&&(H.children=Q.children.filter(V=>E(V,A)).map($)),j.pop(),H})}catch{k=e.navData}return k});let T=0,w=0;const F=j=>{const k=Date.now()-T,A=w+1;if(T=0,w=0,j._path){const $={};return j._path.forEach((Q,H)=>{$[`level${H+1}`]=Q}),{properties:{module:"navigation",timeUsed:k,steps:A,...$}}}},P=j=>{if(w++,!T)return T=Date.now(),{event:"hover",properties:{module:"navigation",target:j.label}}},I=()=>{T=0,w=0},K=j=>j?j.startsWith("http"):!1,q=n.ref(null),M=n.ref(null),N=n.ref([]),J=n.ref(null),b=n.ref(0),C=()=>{if(!q.value)return;if(N.value=[],b.value=q.value.clientWidth,r.value&&(N.value=B.value.map(Q=>Q.id)),q.value.clientWidth>=M.value.clientWidth){N.value=B.value.map(Q=>Q.id);return}b.value=0;const j=M.value.querySelector(`li.nav-item#${qn}`);let k=q.value.clientWidth-j.clientWidth;const A=M.value.querySelectorAll("li.nav-item");let $=!1;[...A].forEach((Q,H)=>{Q.id!==qn&&k>Q.clientWidth&&!$?(k-=Q.clientWidth,N.value.push(B.value[H].id),b.value+=Q.clientWidth):$=!0})};n.onMounted(()=>{window.addEventListener("resize",C),n.nextTick(()=>{C(),J.value=setTimeout(()=>{C()},1e3)})}),n.onUnmounted(()=>{window.removeEventListener("resize",C),clearTimeout(J.value)}),n.watch(()=>B.value,()=>{n.nextTick(()=>{C()})},{deep:!0});const U=j=>(j==="/"&&(j=""),K(j)?j:`/${i.value}${j}`);return(j,k)=>{const A=n.resolveDirective("analytics");return n.openBlock(),n.createElementBlock("nav",{class:"header-nav-ubmc",ref_key:"wrapperRef",ref:q},[n.createElementVNode("ul",{class:"nav-list",onMouseleave:I,ref_key:"listRef",ref:M,style:n.normalizeStyle({"--more-left":b.value})},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList([...B.value,x.value],($,Q)=>{var H;return n.withDirectives((n.openBlock(),n.createElementBlock("li",{key:$.id,id:$.id,class:n.normalizeClass(["nav-item",{"is-selected":f.value===Q,"is-active":l.value===Q,hidden:!N.value.includes($.id)&&$.id!==qn||$.id===qn&&$.children.length===0}]),onMouseenter:V=>u(Q),onMouseleave:V=>d(Q)},[!((H=$.children)!=null&&H.length)&&$.href?(n.openBlock(),n.createElementBlock("a",{key:0,class:"info-wrap clickable",href:U($.href)},[n.createElementVNode("span",null,[n.createElementVNode("span",null,n.toDisplayString($.label),1)])],8,e2)):(n.openBlock(),n.createElementBlock("div",t2,[n.createElementVNode("span",null,[n.createElementVNode("span",null,n.toDisplayString($.label),1)]),n.createElementVNode("div",i2,[n.createVNode(n.unref(et.ElCascaderPanel),{options:$.children,value:"id",expandTrigger:"hover",ref_for:!0,ref:V=>o.value[Q]=V},{default:n.withCtx(({data:V})=>{var G;return[V.disabled?(n.openBlock(),n.createElementBlock("div",n2,[n.createElementVNode("span",null,n.toDisplayString(V.label),1),k[0]||(k[0]=n.createElementVNode("span",{class:"disabled-tag"},"待上线",-1))])):V!=null&&V.children?(n.openBlock(),n.createElementBlock("div",r2,[n.createElementVNode("span",null,n.toDisplayString(V.label),1),n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})])):(n.openBlock(),n.createElementBlock("a",{key:2,href:U(V.href),class:"dropdown-link",target:K(V.href)?"_blank":"_self",rel:K(V.href)?"noopener noreferrer":""},[n.createElementVNode("span",null,n.toDisplayString(V.label),1),(s.tagMap[(G=V==null?void 0:V.href)==null?void 0:G.slice(1)]||V.tag)&&y(V.tagExpire,V.tagLang)?(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:0,color:"danger",size:"small",round:"pill"},{default:n.withCtx(()=>{var Z;return[n.createTextVNode(n.toDisplayString(s.tagMap[(Z=V==null?void 0:V.href)==null?void 0:Z.slice(1)]||V.tag),1)]}),_:2},1024)):n.createCommentVNode("",!0),V.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:1,class:"jump-out-icon"},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(V.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0)],8,s2))]}),_:1},8,["options"]),n.createElementVNode("div",a2,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList($.children,(V,G)=>{var Z;return n.openBlock(),n.createElementBlock("div",{class:"dropdown-body",key:G,onMouseenter:te=>u(Q),onMouseleave:d},[V.disabled?(n.openBlock(),n.createElementBlock("div",l2,[n.createElementVNode("div",u2,[n.createElementVNode("span",null,n.toDisplayString(V.label),1),k[1]||(k[1]=n.createElementVNode("span",{class:"disabled-tag"},"待上线",-1))])])):n.withDirectives((n.openBlock(),n.createElementBlock("div",c2,[n.createElementVNode("a",{href:U(V.href),class:"dropdown-link",target:K(V.href)?"_blank":"_self",rel:K(V.href)?"noopener noreferrer":""},[n.createElementVNode("span",null,n.toDisplayString(V.label),1),(s.tagMap[(Z=V==null?void 0:V.href)==null?void 0:Z.slice(1)]||V.tag)&&y(V.tagExpire,V.tagLang)?(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:0,color:"danger",size:"small",round:"pill"},{default:n.withCtx(()=>{var te;return[n.createTextVNode(n.toDisplayString(s.tagMap[(te=V==null?void 0:V.href)==null?void 0:te.slice(1)]||V.tag),1)]}),_:2},1024)):n.createCommentVNode("",!0),V.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:1,class:"jump-out-icon"},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(V.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0)],8,d2)])),[[A,()=>F(V)]])],40,o2)}),128))])])]))],42,J1)),[[A,()=>P($),"mouseenter"]])}),128))],36)],512)}}}),f2=Ue._export_sfc(h2,[["__scopeId","data-v-d7d33a36"]]),p2={class:"header"},m2=["src"],g2={key:0,class:"header-nav"},_2={key:1,class:"header-content"},y2={key:2,class:"header-toolbar"},v2=n.defineComponent({__name:"OHeader",props:{logo:void 0,lang:void 0,community:void 0,navData:void 0,bgLeft:void 0,bgRight:void 0,tagMap:void 0},emits:["go-home"],setup(s,{emit:e}){const i=e,r=s,a=()=>{i("go-home")};return(o,l)=>(n.openBlock(),n.createElementBlock("div",p2,[n.createVNode(In,{class:"header-wrap"},{default:n.withCtx(()=>[n.createElementVNode("div",{class:"header-logo",onClick:a},[n.renderSlot(o.$slots,"logo",{},()=>[r.logo?(n.openBlock(),n.createElementBlock("img",{key:0,class:"logo",alt:"logo",src:r.logo},null,8,m2)):n.createCommentVNode("",!0)],!0)]),r.community==="openEuler"?(n.openBlock(),n.createElementBlock("div",g2,[n.renderSlot(o.$slots,"nav",{},()=>[r.navData?(n.openBlock(),n.createBlock(Z1,{key:0,"nav-data":r.navData,"bg-left":r.bgLeft,"bg-right":r.bgRight},null,8,["nav-data","bg-left","bg-right"])):n.createCommentVNode("",!0)],!0)])):n.createCommentVNode("",!0),r.community==="openUBMC"?(n.openBlock(),n.createElementBlock("div",_2,[n.renderSlot(o.$slots,"nav",{},()=>[r.navData?(n.openBlock(),n.createBlock(f2,{key:0,"nav-data":r.navData,"has-perm":!0,"tag-map":s.tagMap},null,8,["nav-data","tag-map"])):n.createCommentVNode("",!0)],!0)])):n.createCommentVNode("",!0),o.$slots.toolbar?(n.openBlock(),n.createElementBlock("div",y2,[n.renderSlot(o.$slots,"toolbar",{},void 0,!0)])):n.createCommentVNode("",!0)]),_:3})]))}}),ch=Ue._export_sfc(v2,[["__scopeId","data-v-af43105c"]]),T2={class:"header-content-mb"},b2={class:"o-nav"},x2={class:"o-nav-list"},C2=["onClick"],S2={class:"nav-aside"},E2={key:0,class:"nav-aside-wrapper"},k2=["value","title"],w2={class:"content-label"},D2={class:"container-mobile"},A2=["onClick"],I2={class:"item-label"},N2={class:"desc-container"},O2={class:"item-desc"},B2=["onClick"],L2={class:"item-label"},P2={key:1,class:"nav-aside-wrapper"},M2=["onClick"],R2={class:"header-tool"},V2={key:1},F2=n.defineComponent({__name:"HeaderNavMoblie",props:{menuShow:{type:Boolean,default(){return!1}},navData:void 0,codeData:void 0},emits:["link-click"],setup(s,{emit:e}){const i=s,r=n.ref(""),a=n.ref({}),o=d=>{d?(r.value=d.id,a.value=d):(r.value="source_code",a.value=i.codeData)},l=e,u=(d,f)=>{window.open(d,f),l("link-click")};return n.onMounted(()=>{r.value=i.navData[0].id,a.value=i.navData[0]}),n.watch(()=>i.navData||i.codeData,()=>{a.value=r.value==="source_code"?i.codeData:i.navData.find(d=>d.id===r.value)},{deep:!0}),(d,f)=>(n.openBlock(),n.createElementBlock("div",T2,[n.createElementVNode("div",{class:n.normalizeClass(["header-nav",{active:s.menuShow}])},[n.createElementVNode("div",b2,[n.createElementVNode("ul",x2,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.navData,g=>(n.openBlock(),n.createElementBlock("li",{key:g.id,class:n.normalizeClass({active:r.value===g.id})},[n.createElementVNode("span",{onClick:y=>o(g)},n.toDisplayString(g.label),9,C2)],2))),128))]),n.createElementVNode("div",S2,[r.value!=="source_code"?(n.openBlock(),n.createElementBlock("ul",E2,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value.children,g=>(n.openBlock(),n.createElementBlock("li",{value:g.label,title:g.label,key:g.label,class:"nav-aside-content"},[g!=null&&g.children?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createElementVNode("p",w2,n.toDisplayString(g.label),1),n.createElementVNode("div",D2,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(g==null?void 0:g.children,y=>(n.openBlock(),n.createElementBlock("div",{key:y.label,class:"content-container-mobile"},[n.createElementVNode("a",{onClick:E=>u(y.href,"_blank"),rel:"noopener noreferrer",class:"content-subtitle"},[n.createElementVNode("span",I2,n.toDisplayString(y.label),1),y.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(y.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0),y.tag?(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:1,round:"pill",color:"danger",size:"small",class:"content-tag"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(y.tag),1)]),_:2},1024)):n.createCommentVNode("",!0)],8,A2),n.createElementVNode("div",N2,[n.createElementVNode("p",O2,n.toDisplayString(y.description),1)])]))),128))])],64)):(n.openBlock(),n.createElementBlock("a",{key:1,onClick:y=>u(g.href,"_blank"),rel:"noopener noreferrer",class:"content-subtitle item-not-children"},[n.createElementVNode("span",L2,n.toDisplayString(g.label),1),g.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(g.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0),g.tag?(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:1,round:"pill",color:"danger",size:"small"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(g.tag),1)]),_:2},1024)):n.createCommentVNode("",!0)],8,B2))],8,k2))),128))])):(n.openBlock(),n.createElementBlock("div",P2,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,g=>(n.openBlock(),n.createElementBlock("a",{key:g.label,onClick:y=>u(g.href,"_blank"),class:"source-code-item"},[n.createElementVNode("span",null,n.toDisplayString(g.label),1),g.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(g.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0)],8,M2))),128))]))])]),n.createElementVNode("div",R2,[s.codeData?(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass(["header-tool-code",{active:r.value==="source_code"}]),onClick:f[0]||(f[0]=g=>o(null))}," 源码 ",2)):n.createCommentVNode("",!0),d.$slots.tool?(n.openBlock(),n.createElementBlock("div",V2,[n.renderSlot(d.$slots,"tool",{},void 0,!0)])):n.createCommentVNode("",!0)])],2)]))}}),$2=Ue._export_sfc(F2,[["__scopeId","data-v-bd38af58"]]),U2={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function q2(s,e){return n.openBlock(),n.createElementBlock("svg",U2,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M18.528 5.472c0.246 0.246 0.271 0.63 0.074 0.903l-0.074 0.087-5.54 5.538 0.006 0.006-0.989 0.989-0.006-0.006-5.538 5.54c-0.273 0.273-0.717 0.273-0.99 0-0.246-0.246-0.271-0.63-0.074-0.903l0.074-0.087 5.538-5.539-5.538-5.538-0.074-0.087c-0.197-0.274-0.172-0.657 0.074-0.903s0.63-0.271 0.903-0.074l0.087 0.074 5.538 5.539 5.539-5.539c0.273-0.273 0.717-0.273 0.99 0zM14.551 13.561l3.978 3.978 0.074 0.087c0.197 0.274 0.172 0.657-0.074 0.903s-0.63 0.271-0.903 0.074l-0.087-0.074-3.978-3.978c-0.273-0.273-0.273-0.717 0-0.99v0c0.273-0.273 0.717-0.273 0.99 0z"},null,-1)])])}const wl={name:"components-icon-close",render:q2},j2={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function H2(s,e){return n.openBlock(),n.createElementBlock("svg",j2,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M3.8 5h16.4c0.442 0 0.8 0.359 0.8 0.8s-0.358 0.8-0.8 0.8h-16.4c-0.442 0-0.8-0.358-0.8-0.8s0.358-0.8 0.8-0.8zM3.8 11h16.4c0.442 0 0.8 0.359 0.8 0.8s-0.358 0.8-0.8 0.8h-16.4c-0.442 0-0.8-0.358-0.8-0.8s0.358-0.8 0.8-0.8zM3.8 17h16.4c0.442 0 0.8 0.358 0.8 0.8s-0.358 0.8-0.8 0.8h-16.4c-0.442 0-0.8-0.359-0.8-0.8s0.358-0.8 0.8-0.8z"},null,-1)])])}const z2={name:"components-icon-header-menu",render:H2},G2={class:"header"},W2={key:0,class:"header-simple"},Y2={class:"simple-header-left"},X2={key:0,class:"header-title"},K2={key:0,class:"simple-header-right"},Q2={class:"header-left"},Z2={class:"header-center"},J2=["src"],e_={class:"header-right"},t_=n.defineComponent({__name:"OHeaderMoblie",props:{logo:void 0,navData:void 0,codeData:void 0,isSimpleHeader:void 0,headerTitle:void 0},emits:["go-back","go-home"],setup(s,{emit:e}){const i=e,r=s,a=()=>{i("go-back")},o=()=>{i("go-home")},l=n.ref(!1),u=()=>{setTimeout(()=>{l.value=!l.value,document.body.style.overflow=l.value?"hidden":""},200)},d=()=>{u()};return(f,g)=>(n.openBlock(),n.createElementBlock("div",G2,[n.createVNode(In,{class:"header-wrap"},{default:n.withCtx(()=>[s.isSimpleHeader?(n.openBlock(),n.createElementBlock("div",W2,[n.createElementVNode("div",Y2,[n.createVNode(n.unref(O.OIcon),{onClick:a},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconArrowLeft))]),_:1}),s.headerTitle?(n.openBlock(),n.createElementBlock("div",X2,n.toDisplayString(s.headerTitle),1)):n.createCommentVNode("",!0)]),f.$slots.rightConfig?(n.openBlock(),n.createElementBlock("div",K2,[n.renderSlot(f.$slots,"rightConfig",{},void 0,!0)])):n.createCommentVNode("",!0)])):(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createElementVNode("div",Q2,[n.createVNode(n.unref(O.OIcon),{onClick:u},{default:n.withCtx(()=>[l.value?(n.openBlock(),n.createBlock(n.unref(wl),{key:1})):(n.openBlock(),n.createBlock(n.unref(z2),{key:0}))]),_:1})]),n.createVNode($2,{ref:"mobileNav","nav-data":s.navData,"code-data":s.codeData,"menu-show":l.value,onLinkClick:d},{tool:n.withCtx(()=>[n.renderSlot(f.$slots,"tool",{},void 0,!0)]),_:3},8,["nav-data","code-data","menu-show"]),n.createElementVNode("div",Z2,[n.createElementVNode("div",{class:"header-logo",onClick:o},[n.renderSlot(f.$slots,"logo",{},()=>[r.logo?(n.openBlock(),n.createElementBlock("img",{key:0,class:"logo",alt:"logo",src:r.logo},null,8,J2)):n.createCommentVNode("",!0)],!0)])]),n.createElementVNode("div",e_,[n.renderSlot(f.$slots,"toolbar",{},void 0,!0)])],64))]),_:3})]))}}),dh=Ue._export_sfc(t_,[["__scopeId","data-v-bf633ce0"]]),i_={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function n_(s,e){return n.openBlock(),n.createElementBlock("svg",i_,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M13.215 0.524c-7.048 0-12.762 5.714-12.762 12.762s5.714 12.762 12.762 12.762c7.048 0 12.762-5.714 12.762-12.762s-5.714-12.762-12.762-12.762zM13.215 2.809c5.786 0 10.476 4.69 10.476 10.476s-4.69 10.476-10.476 10.476c-5.786 0-10.476-4.69-10.476-10.476s4.69-10.476 10.476-10.476z"},null,-1),n.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M23.33 23.22c0.446-0.447 1.169-0.448 1.616-0.002l4.771 4.759c0.447 0.446 0.448 1.169 0.002 1.616s-1.169 0.448-1.616 0.002l-4.771-4.759c-0.447-0.446-0.448-1.169-0.002-1.616z"},null,-1)])])}const ic={name:"components-icon-header-search",render:n_},r_={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function s_(s,e){return n.openBlock(),n.createElementBlock("svg",r_,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M10.858 22.41c-0.349 0.349-0.915 0.349-1.263 0-0.314-0.314-0.345-0.804-0.094-1.153l0.094-0.111 5.146-5.15-5.177-5.178c-0.274-0.305-0.3-0.755-0.077-1.087l0.111-0.135c0.347-0.347 0.91-0.347 1.257 0l5.142 5.143 5.15-5.146c0.349-0.349 0.915-0.349 1.263 0 0.314 0.314 0.345 0.804 0.094 1.153l-0.094 0.111-11.552 11.552zM17.89 16.634l4.551 4.552c0.313 0.349 0.302 0.886-0.034 1.222-0.347 0.347-0.91 0.347-1.257 0l-4.516-4.518 1.256-1.256z"},null,-1)])])}const a_={name:"components-icon-header-delete",render:s_},o_={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function l_(s,e){return n.openBlock(),n.createElementBlock("svg",o_,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M19.154 5.295c0.387 0 0.7 0.313 0.7 0.7 0 0.354-0.263 0.647-0.605 0.694l-0.095 0.006-12.201-0.001 0.001 12.413c0 0.17 0.12 0.311 0.28 0.344l0.071 0.007h9.39c0.17 0 0.311-0.12 0.344-0.28l0.007-0.071v-10.47c0-0.387 0.313-0.7 0.7-0.7 0.354 0 0.647 0.263 0.694 0.605l0.006 0.095v10.47c0 0.919-0.708 1.672-1.608 1.745l-0.144 0.006h-9.39c-0.919 0-1.672-0.708-1.745-1.608l-0.006-0.144-0.001-12.413-0.707 0.001c-0.387 0-0.7-0.313-0.7-0.7 0-0.354 0.263-0.647 0.605-0.694l0.095-0.006h14.308zM10.011 9.744c0.354 0 0.647 0.263 0.694 0.605l0.006 0.095v5.68c0 0.387-0.313 0.7-0.7 0.7-0.354 0-0.647-0.263-0.694-0.605l-0.006-0.095v-5.68c0-0.387 0.313-0.7 0.7-0.7zM13.953 9.744c0.354 0 0.647 0.263 0.694 0.605l0.006 0.095v5.68c0 0.387-0.313 0.7-0.7 0.7-0.354 0-0.647-0.263-0.694-0.605l-0.006-0.095v-5.68c0-0.387 0.313-0.7 0.7-0.7zM13.652 3.189c0.387 0 0.7 0.313 0.7 0.7 0 0.354-0.263 0.647-0.605 0.694l-0.095 0.006h-3.972c-0.387 0-0.7-0.313-0.7-0.7 0-0.354 0.263-0.647 0.605-0.694l0.095-0.006h3.972z"},null,-1)])])}const u_={name:"components-icon-delete",render:l_},c_={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"36",height:"32",viewBox:"0 0 36 32"};function d_(s,e){return n.openBlock(),n.createElementBlock("svg",c_,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M5.886 19.111l10.672 10.677c0.46 0.524 0.44 1.322-0.060 1.822s-1.298 0.52-1.822 0.060l-0.064-0.060-12.498-12.498h3.772zM14.613 0.391c0.521-0.521 1.365-0.521 1.886 0 0.5 0.5 0.52 1.298 0.060 1.822l-0.060 0.064-12.391 12.391h29.67c0.71 0 1.291 0.555 1.331 1.255l0.002 0.078c0 0.71-0.555 1.291-1.255 1.331l-0.078 0.002h-31.816c-0.472 0-0.924-0.187-1.257-0.521-0.671-0.671-0.694-1.745-0.067-2.443l0.067-0.071 13.908-13.908z"},null,-1)])])}const h_={name:"components-icon-header-back",render:d_},f_={class:"o-header-search"},p_={class:"o-header-search-drawer"},m_={key:0,class:"o-header-search-recommend-container"},g_=["onClick"],__={key:1,class:"o-header-search-history-container"},y_={class:"o-header-search-history-header"},v_={class:"o-header-search-history-header-title"},T_={class:"o-header-search-history-item-container"},b_=["onClick"],x_={class:"o-header-search-history-item-text"},C_={key:3,class:"o-header-search-hot-container"},S_={class:"o-header-search-hot-header"},E_={class:"o-header-search-hot-item-container"},k_=["onClick"],w_=n.defineComponent({__name:"OHeaderSearch",props:{modelValue:{default:""},placeholder:{},expandedPlaceholder:{},expandDirection:{default:"left"},clearable:{type:Boolean,default:!0},historyItems:{default:()=>[]},maxHistoryCount:{default:6},storeHistory:{type:Boolean,default:!1},historyTitle:{},storageKey:{default:"search-history"},hotItems:{default:()=>[]},hotTitle:{},recommendItems:{default:()=>[]},searchUrl:{},searchUrlOpenBlank:{type:Boolean,default:!0},searchTextMobile:{}},emits:["update:modelValue","update:historyItems","clear","search","delete-history","delete-history-item"],setup(s,{emit:e}){const{lePadV:i}=wt.useScreen(),{t:r}=Ue.useI18n(),a=s,o=e,l=n.ref(a.modelValue),u=n.ref(a.historyItems),d=n.ref(!1),f=n.ref(),g=n.computed(()=>!i.value&&d.value||i.value&&l.value);n.watch(()=>a.modelValue,I=>{l.value!==I&&(l.value=I)}),n.watch(()=>l.value,I=>{o("update:modelValue",I)}),n.watch(()=>a.historyItems,I=>{u.value!==I&&(u.value=I)}),n.watch(()=>u.value,I=>{o("update:historyItems",I)}),n.onMounted(()=>{if(a.storeHistory&&a.storageKey)try{const I=JSON.parse(localStorage.getItem(a.storageKey)||"[]");Array.isArray(I)&&I.length&&(u.value=Array.from(new Set([...u.value,...I])))}catch{}});const y=()=>{d.value=!0},E=()=>{const I=l.value.trim();I&&(d.value=!1,u.value.unshift(I),u.value=Array.from(new Set(u.value)),u.value.length>a.maxHistoryCount&&u.value.pop(),a.storeHistory&&a.storeHistory&&localStorage.setItem(a.storageKey,JSON.stringify(u.value)),o("search",I),a.searchUrl&&window.open(a.searchUrl+I,a.searchUrlOpenBlank?"_blank":"_self","noopener noreferrer"))},x=()=>{l.value="",o("clear"),i.value||(d.value=!1)},B=()=>{const I=[...u.value];u.value=[],a.storeHistory&&a.storeHistory&&localStorage.removeItem(a.storageKey),o("delete-history",I)},T=I=>{u.value=u.value.filter(K=>K!==I),a.storeHistory&&a.storeHistory&&(u.value.length?localStorage.setItem(a.storageKey,JSON.stringify(u.value)):localStorage.removeItem(a.storageKey)),o("delete-history-item",I)},w=I=>{l.value=I,E()},F=()=>{l.value="",d.value=!1},P=n.ref();return Mn.onClickOutside(P,x),(I,K)=>(n.openBlock(),n.createElementBlock("div",f_,[n.createElementVNode("div",{ref_key:"posWrapper",ref:P,class:n.normalizeClass({"o-header-search-input-pc-wrapper":!n.unref(i),"o-header-search-input-pc-wrapper-left":!n.unref(i)&&s.expandDirection==="left","o-header-search-input-pc-wrapper-right":!n.unref(i)&&s.expandDirection==="right","o-header-search-input-mobile-wrapper":n.unref(i),focus:d.value})},[n.createElementVNode("div",{class:n.normalizeClass(["o-header-search-input-wrapper",{focus:d.value}])},[n.unref(i)&&d.value?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0,class:"o-header-search-icon",onClick:F},{default:n.withCtx(()=>[n.createVNode(n.unref(h_))]),_:1})):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OInput),{ref_key:"inputRef",ref:f,modelValue:l.value,"onUpdate:modelValue":K[0]||(K[0]=q=>l.value=q),class:"o-header-search-input",placeholder:d.value?s.expandedPlaceholder??n.unref(r)("search.expandedPlaceholder"):s.placeholder??n.unref(r)("search.placeholder"),onFocus:y,onKeyup:n.withKeys(E,["enter"])},{prefix:n.withCtx(()=>[n.renderSlot(I.$slots,"input-prefix",{},()=>[n.createVNode(n.unref(O.OIcon),{class:"o-header-search-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(ic))]),_:1})],!0)]),suffix:n.withCtx(()=>[n.renderSlot(I.$slots,"input-suffix",{},()=>[s.clearable&&g.value?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0,class:"o-header-search-icon close",onClick:x},{default:n.withCtx(()=>[n.createVNode(n.unref(wl))]),_:1})):n.createCommentVNode("",!0)],!0)]),_:3},8,["modelValue","placeholder"]),n.unref(i)&&d.value?(n.openBlock(),n.createElementBlock("span",{key:1,class:"o-header-search-text",onClick:E},n.toDisplayString(s.searchTextMobile??n.unref(r)("search")),1)):n.createCommentVNode("",!0)],2),n.withDirectives(n.createElementVNode("div",p_,[n.renderSlot(I.$slots,"drawer",{recommendItems:s.recommendItems,historyItems:u.value,hotItems:s.hotItems},()=>[s.recommendItems.length?(n.openBlock(),n.createElementBlock("div",m_,[n.renderSlot(I.$slots,"recommend-header",{recommend:s.recommendItems},void 0,!0),n.renderSlot(I.$slots,"recommend-content",{recommend:s.recommendItems},()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.recommendItems,q=>(n.openBlock(),n.createElementBlock("div",{class:"o-header-search-recommend-item",key:q,onClick:M=>w(q)},n.toDisplayString(q),9,g_))),128))],!0)])):u.value.length?(n.openBlock(),n.createElementBlock("div",__,[n.renderSlot(I.$slots,"history-header",{history:u.value},()=>[n.createElementVNode("div",y_,[n.createElementVNode("span",v_,n.toDisplayString(s.historyTitle??n.unref(r)("search.history")),1),n.createVNode(n.unref(O.OIcon),{class:"o-header-search-icon",onClick:B},{default:n.withCtx(()=>[n.createVNode(n.unref(u_))]),_:1})])],!0),n.renderSlot(I.$slots,"history-content",{history:u.value},()=>[n.createElementVNode("div",T_,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(u.value,q=>(n.openBlock(),n.createElementBlock("div",{key:q,class:"o-header-search-history-item",onClick:M=>w(q)},[n.createElementVNode("span",x_,n.toDisplayString(q),1),n.createVNode(n.unref(O.OIcon),{class:"o-header-search-history-item-icon",onClick:n.withModifiers(M=>T(q),["stop"])},{default:n.withCtx(()=>[n.createVNode(n.unref(a_),{class:"icon-delete"})]),_:1},8,["onClick"])],8,b_))),128))])],!0)])):n.createCommentVNode("",!0),(s.recommendItems.length||u.value.length)&&s.hotItems.length?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:2,class:"o-header-search-drawer-divider"})):n.createCommentVNode("",!0),s.hotItems.length?(n.openBlock(),n.createElementBlock("div",C_,[n.renderSlot(I.$slots,"hot-header",{hot:s.hotItems},()=>[n.createElementVNode("div",S_,n.toDisplayString(s.hotTitle??n.unref(r)("search.hot")),1)],!0),n.renderSlot(I.$slots,"hot-content",{hot:s.hotItems},()=>[n.createElementVNode("div",E_,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.hotItems,q=>(n.openBlock(),n.createElementBlock("div",{key:q,class:"o-header-search-hot-item",onClick:M=>w(q)},n.toDisplayString(q),9,k_))),128))])],!0)])):n.createCommentVNode("",!0)],!0)],512),[[n.vShow,d.value]])],2),n.unref(i)?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0,class:"o-header-search-icon-mobile",onClick:y},{default:n.withCtx(()=>[n.createVNode(n.unref(ic))]),_:1})):n.createCommentVNode("",!0)]))}}),hh=Ue._export_sfc(w_,[["__scopeId","data-v-9f1bd8fc"]]),D_=["src"],A_=n.defineComponent({__name:"AppAvatar",props:{avatar:{type:String,default:""},name:{type:String,default:"",required:!0},size:{type:String,default:"medium"},customSize:{type:Number,default:0},variant:{type:String,default:"round"}},setup(s){const e=s,i=["#058EF0","#FA7305","#03B5A5"],r=n.computed(()=>{var o;return(o=e.name)==null?void 0:o.charAt(0).toUpperCase()}),a=n.computed(()=>{var u;const o={"background-color":"",width:"32px",height:"32px","font-size":"20px"};o["background-color"]=e.name?i[((u=e.name)==null?void 0:u.length)%i.length]:"transparent";let l=0;return e.customSize?l=Number(e.customSize):l={mini:16,small:24,medium:40,large:64}[e.size],o.height=`${l}px`,o.width=`${l}px`,o["font-size"]=`${l/2}px`,o});return(o,l)=>s.avatar&&!s.avatar.includes("gitcode")?(n.openBlock(),n.createElementBlock("img",{key:0,src:s.avatar,class:n.normalizeClass(["img-avatar",s.variant]),style:n.normalizeStyle(a.value),alt:""},null,14,D_)):(n.openBlock(),n.createElementBlock("div",{key:1,class:n.normalizeClass(["word-avatar",s.variant]),style:n.normalizeStyle(a.value)},n.toDisplayString(r.value),7))}}),nc=Ue._export_sfc(A_,[["__scopeId","data-v-340348ce"]]),I_={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function N_(s,e){return n.openBlock(),n.createElementBlock("svg",I_,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.8",fill:"#000",d:"M9.412 10.332c0 2.188 1.066 4.127 2.708 5.326-4.858 1.582-8.364 6.052-8.364 11.328 0 0.515 0.418 0.933 0.933 0.933s0.933-0.418 0.933-0.933c0-5.465 4.487-9.922 10.092-10.070 0.095 0.004 0.191 0.006 0.288 0.006 3.639 0 6.59-2.95 6.59-6.59s-2.951-6.59-6.59-6.59-6.59 2.95-6.59 6.59zM16.088 15.049c-0.028-0.003-0.057-0.004-0.087-0.004-0.061 0-0.122 0-0.183 0.001-2.524-0.096-4.541-2.172-4.541-4.72 0-2.608 2.115-4.723 4.723-4.723s4.723 2.115 4.723 4.723c0 2.579-2.067 4.676-4.635 4.722zM21.784 16.465c3.945 2.064 6.463 6.077 6.463 10.528 0 0.515-0.418 0.933-0.933 0.933s-0.933-0.418-0.933-0.933c0-3.744-2.123-7.127-5.462-8.874-0.457-0.239-0.633-0.803-0.394-1.26s0.803-0.633 1.26-0.394z"},null,-1)])])}const O_={name:"components-icon-avatar-line",render:N_},B_={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function L_(s,e){return n.openBlock(),n.createElementBlock("svg",B_,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M5.759 8.873c0.251-0.251 0.644-0.271 0.918-0.063l0.072 0.063 5.016 5.016c0.1 0.1 0.254 0.115 0.37 0.043l0.054-0.043 5.062-5.062c0.273-0.273 0.717-0.273 0.99 0 0.251 0.251 0.271 0.644 0.063 0.918l-0.063 0.072-5.062 5.062c-0.629 0.629-1.628 0.662-2.296 0.099l-0.108-0.099-5.016-5.016c-0.273-0.273-0.273-0.717 0-0.99z"},null,-1)])])}const Dl={name:"components-icon-chevron-down",render:L_},P_={class:"header-user"},M_={key:0,class:"user-info"},R_={class:"info-wrap hover-icon-rotate"},V_={class:"user-account"},F_={key:0,class:"user-info-dropdown"},$_={class:"right-info"},U_={class:"user-account"},q_={key:1},j_=n.defineComponent({__name:"OHeaderUser",props:{token:{default:void 0},lang:{default:void 0},noticeTotal:{default:void 0},userInfo:{default:void 0},userInfoVisible:{type:Boolean,default:void 0},options:{default:void 0}},emits:["login","logout"],setup(s,{emit:e}){const{lePadV:i}=wt.useScreen(),r=e,a=()=>{r("login")},o=l=>{l!=null&&l.logout?r("logout"):window.open(l.url,l.target)};return(l,u)=>(n.openBlock(),n.createElementBlock("div",P_,[s.token?n.createCommentVNode("",!0):(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0,onClick:a,class:"avatar-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(O_))]),_:1})),n.createVNode(n.Transition,{name:"header-user-zoom-in"},{default:n.withCtx(()=>[s.token?(n.openBlock(),n.createElementBlock("div",M_,[n.createVNode(n.unref(O.ODropdown),{trigger:n.unref(i)?"click":"hover",optionPosition:n.unref(i)?"br":"bottom","option-wrap-class":`user-dropdown ${s.lang==="en"?"is-en":""} user-dropdown${s.userInfoVisible?"-info":""}`},{dropdown:n.withCtx(()=>[s.userInfoVisible?(n.openBlock(),n.createElementBlock("div",F_,[n.createVNode(nc,{avatar:s.userInfo.photo,name:s.userInfo.username,"custom-size":32},null,8,["avatar","name"]),n.createElementVNode("div",$_,[u[0]||(u[0]=n.createElementVNode("p",{class:"user-fullname"},"用户名",-1)),n.createElementVNode("p",U_,n.toDisplayString(s.userInfo.username),1)])])):n.createCommentVNode("",!0),s.userInfoVisible?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:1,style:{"--o-divider-gap":"6px"}})):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.options,d=>(n.openBlock(),n.createBlock(n.unref(O.ODropdownItem),{key:d.label,style:n.normalizeStyle({"--dropdown-item-justify":s.userInfoVisible?"flex-start":"center"}),onClick:f=>o(d)},{default:n.withCtx(()=>[d!=null&&d.icon?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createVNode(n.unref(O.OBadge),{value:d.total,color:"danger",class:n.normalizeClass(["header-message icon-message",{"notice-not":!d.total}])},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(d.icon),{class:"icon"}))]),_:2},1024)]),_:2},1032,["value","class"]),n.createElementVNode("span",null,n.toDisplayString(d.label),1)],64)):(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[d!=null&&d.total?(n.openBlock(),n.createBlock(n.unref(O.OBadge),{key:0,value:d.total,color:"danger",class:n.normalizeClass(["header-message message",{"notice-not":!d.total}])},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(d.label),1)]),_:2},1032,["value","class"])):(n.openBlock(),n.createElementBlock("span",q_,n.toDisplayString(d.label),1))],64))]),_:2},1032,["style","onClick"]))),128))]),default:n.withCtx(()=>[n.createElementVNode("div",R_,[n.createVNode(n.unref(O.OBadge),{value:s.noticeTotal,color:"danger",class:n.normalizeClass(["header-message user-avatar",{"notice-not":!s.noticeTotal}])},{default:n.withCtx(()=>[n.createVNode(nc,{avatar:s.userInfo.photo,name:s.userInfo.username,"custom-size":n.unref(i)?24:32},null,8,["avatar","name","custom-size"])]),_:1},8,["value","class"]),n.createElementVNode("p",V_,n.toDisplayString(s.userInfo.username),1),n.createVNode(n.unref(O.OIcon),{class:"icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(Dl))]),_:1})])]),_:1},8,["trigger","optionPosition","option-wrap-class"])])):n.createCommentVNode("",!0)]),_:1})]))}}),fh=Ue._export_sfc(j_,[["__scopeId","data-v-66736d3f"]]),ph=n.defineComponent({__name:"OPlusConfigProvider",props:{locale:{},theme:{default:"light"}},setup(s){const e=s,i=n.reactive({locale:n.computed(()=>e.locale),theme:n.computed(()=>e.theme)});return n.provide(Ue.configProviderInjectKey,i),(r,a)=>(n.openBlock(),n.createBlock(n.unref(O.OConfigProvider),{locale:s.locale==="zh"?n.unref(Km):n.unref(Qm)},{default:n.withCtx(()=>[n.renderSlot(r.$slots,"default")]),_:3},8,["locale"]))}}),H_={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function z_(s,e){return n.openBlock(),n.createElementBlock("svg",H_,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M9.246 5.764c-0.251 0.251-0.271 0.644-0.063 0.918l0.063 0.072 5.016 5.016c0.1 0.1 0.115 0.254 0.043 0.37l-0.043 0.054-5.062 5.062c-0.273 0.273-0.273 0.717 0 0.99 0.251 0.251 0.644 0.271 0.918 0.063l0.072-0.063 5.062-5.062c0.629-0.629 0.662-1.628 0.099-2.296l-0.099-0.108-5.016-5.016c-0.273-0.273-0.717-0.273-0.99 0z"},null,-1)])])}const Ws={name:"components-icon-chevron-right",render:z_},G_={class:"section-wrapper"},W_={key:1,class:"section-title"},Y_={key:2,class:"section-subtitle"},X_={key:1,class:"section-body"},K_={key:2,class:"section-footer"},Q_=n.defineComponent({__name:"OSection",props:{title:{default:void 0},subtitle:{default:void 0},full:{type:Boolean,default:!1},headerJustifyCenter:{type:Boolean,default:!0},footer:{default:void 0},footerHref:{default:void 0}},setup(s){const e=s;return(i,r)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["app-section",{"is-full":e.full}])},[n.createElementVNode("div",G_,[n.renderSlot(i.$slots,"main",{},()=>[i.$slots.header||e.title||e.subtitle?(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass(["section-header",{"is-left":!e.headerJustifyCenter}])},[n.renderSlot(i.$slots,"header",{},()=>[n.unref(O.isArray)(e.title)?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:0},n.renderList(e.title,a=>(n.openBlock(),n.createElementBlock("h2",{key:a,class:"section-title"},n.toDisplayString(a),1))),128)):i.$slots.title||e.title?(n.openBlock(),n.createElementBlock("h2",W_,[n.renderSlot(i.$slots,"title",{},()=>[n.createTextVNode(n.toDisplayString(e.title),1)],!0)])):n.createCommentVNode("",!0),i.$slots.subtitle||e.subtitle?(n.openBlock(),n.createElementBlock("p",Y_,[n.renderSlot(i.$slots,"subtitle",{},()=>[n.createTextVNode(n.toDisplayString(e.subtitle),1)],!0)])):n.createCommentVNode("",!0)],!0)],2)):n.createCommentVNode("",!0),i.$slots.default?(n.openBlock(),n.createElementBlock("div",X_,[n.renderSlot(i.$slots,"default",{},void 0,!0)])):n.createCommentVNode("",!0),i.$slots.footer||e.footer?(n.openBlock(),n.createElementBlock("div",K_,[n.renderSlot(i.$slots,"footer",{},()=>[n.createVNode(n.unref(O.OLink),{href:e.footerHref,target:"_blank"},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),{class:"footer-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(Ws))]),_:1})]),default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.footer)+" ",1)]),_:1},8,["href"])],!0)])):n.createCommentVNode("",!0)],!0)])],2))}}),mh=Ue._export_sfc(Q_,[["__scopeId","data-v-2fc90e8a"]]),Z_={class:"source-code"},J_={key:0,class:"info-wrap"},ey={class:"title"},ty={class:"info-wrap hover-icon-rotate"},iy={class:"title"},ny=n.defineComponent({__name:"OSourceCode",props:{title:{default:void 0},options:{default:void 0},url:{default:void 0},icon:{default:void 0},justify:{default:"center"}},setup(s){const e=a=>{window.open(a.url,"_blank")},i=n.ref(!1),r=a=>{i.value=a};return(a,o)=>(n.openBlock(),n.createElementBlock("div",Z_,[s.url?(n.openBlock(),n.createElementBlock("div",J_,[n.createElementVNode("span",ey,n.toDisplayString(s.title),1),s.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(s.icon),{class:"icon"}))]),_:1})):n.createCommentVNode("",!0)])):(n.openBlock(),n.createBlock(n.unref(O.ODropdown),{key:1,trigger:"hover",optionPosition:"bottom","option-wrap-class":"dropdown",class:n.normalizeClass({"dropdown-active":i.value}),onVisibleChange:r},{dropdown:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.options,l=>(n.openBlock(),n.createBlock(n.unref(O.ODropdownItem),{onClick:u=>e(l),key:l.url,class:"list",style:n.normalizeStyle({"--dropdown-item-justify":s.justify})},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(l.label)+" ",1),l.icon?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(l.icon),{class:"icon"}))]),_:2},1024)):n.createCommentVNode("",!0)]),_:2},1032,["onClick","style"]))),128))]),default:n.withCtx(()=>[n.createElementVNode("div",ty,[n.createElementVNode("span",iy,n.toDisplayString(s.title),1),n.createVNode(n.unref(O.OIcon),{class:"icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(Dl))]),_:1})])]),_:1},8,["class"]))]))}}),gh=Ue._export_sfc(ny,[["__scopeId","data-v-bbe28df5"]]),ry={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function sy(s,e){return n.openBlock(),n.createElementBlock("svg",ry,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M12 1.992c0.387 0 0.7 0.313 0.7 0.7v1.2c0 0.387-0.313 0.7-0.7 0.7s-0.7-0.313-0.7-0.7v-1.2c0-0.387 0.313-0.7 0.7-0.7zM6.769 6.747c-0.273 0.273-0.717 0.273-0.99 0l-0.849-0.849c-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495c0.273-0.273 0.717-0.273 0.99 0l0.849 0.849c0.136 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495zM18.192 6.747c-0.273 0.273-0.717 0.273-0.99 0-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495l0.849-0.849c0.273-0.273 0.717-0.273 0.99 0 0.137 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495l-0.849 0.849zM5.3 12c0-3.7 3-6.7 6.7-6.7s6.7 3 6.7 6.7-3 6.7-6.7 6.7c-3.7 0-6.7-3-6.7-6.7zM17.3 12c0-2.927-2.373-5.3-5.3-5.3s-5.3 2.373-5.3 5.3c0 2.927 2.373 5.3 5.3 5.3s5.3-2.373 5.3-5.3zM4.594 11.969c0 0.387-0.313 0.7-0.7 0.7h-1.2c-0.387 0-0.7-0.313-0.7-0.7s0.313-0.7 0.7-0.7h1.2c0.386 0 0.7 0.313 0.7 0.7zM21.977 11.999c0 0.387-0.314 0.7-0.7 0.7h-1.2c-0.387 0-0.7-0.313-0.7-0.7s0.313-0.7 0.7-0.7h1.2c0.387 0 0.7 0.313 0.7 0.7zM5.921 19.060c-0.273 0.273-0.717 0.273-0.99 0-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495l0.849-0.849c0.273-0.273 0.717-0.273 0.99 0 0.137 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495l-0.849 0.849zM19.041 19.060c-0.273 0.273-0.717 0.273-0.99 0l-0.849-0.849c-0.137-0.137-0.205-0.316-0.205-0.495s0.068-0.358 0.205-0.495c0.273-0.273 0.717-0.273 0.99 0l0.849 0.849c0.137 0.137 0.205 0.316 0.205 0.495s-0.068 0.358-0.205 0.495zM11.971 19.376c0.387 0 0.7 0.313 0.7 0.7v1.2c0 0.387-0.313 0.7-0.7 0.7s-0.7-0.313-0.7-0.7v-1.2c0-0.387 0.313-0.7 0.7-0.7z"},null,-1)])])}const so={name:"components-icon-sun",render:sy},ay={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function oy(s,e){return n.openBlock(),n.createElementBlock("svg",ay,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.8",fill:"currentColor",d:"M12 2.3c5.357 0 9.7 4.343 9.7 9.7s-4.343 9.7-9.7 9.7c-4.651 0-8.622-3.298-9.515-7.806-0.101-0.509 0.369-0.948 0.87-0.812 0.531 0.144 1.082 0.218 1.645 0.218 3.479 0 6.3-2.82 6.3-6.3 0-1.276-0.379-2.494-1.079-3.527-0.291-0.43-0.029-1.016 0.486-1.086 0.425-0.057 0.857-0.086 1.293-0.086zM12 3.7l-0.042 0.001 0.058 0.121c0.402 0.887 0.634 1.85 0.677 2.845l0.007 0.333c0 4.253-3.447 7.7-7.7 7.7-0.229 0-0.457-0.010-0.682-0.030l-0.186-0.021 0.076 0.218c1.147 3.123 4.102 5.321 7.528 5.429l0.264 0.004c4.584 0 8.3-3.716 8.3-8.3s-3.716-8.3-8.3-8.3z"},null,-1)])])}const ao={name:"components-icon-moon",render:oy},ly={class:"o-theme-switcher"},uy={key:1,class:"o-theme-switcher-mobile"},cy=n.defineComponent({__name:"OThemeSwitcher",props:{theme:{default:"light"},type:{default:"auto"},lightValue:{default:"light"},darkValue:{default:"dark"},lightIcon:{default:so},darkIcon:{default:ao}},emits:["update:theme","change"],setup(s,{emit:e}){const i=s,r=e,{gtPhone:a}=wt.useScreen(),o=n.computed({get(){return i.theme},set(d){r("update:theme",d),r("change",d)}}),l=n.computed(()=>i.type==="common"||i.type==="auto"&&a.value),u=()=>{o.value=o.value===i.lightValue?i.darkValue:i.lightValue};return(d,f)=>(n.openBlock(),n.createElementBlock("div",ly,[l.value?(n.openBlock(),n.createElementBlock("div",{key:0,class:"o-theme-switcher-common",onClick:u},[n.createVNode(n.unref(O.OIcon),{class:"o-theme-icon"},{default:n.withCtx(()=>[o.value===s.lightValue?(n.openBlock(),n.createBlock(n.unref(ao),{key:0})):(n.openBlock(),n.createBlock(n.unref(so),{key:1}))]),_:1})])):(n.openBlock(),n.createElementBlock("div",uy,[n.createVNode(n.unref(O.OSwitch),{modelValue:o.value,"onUpdate:modelValue":f[0]||(f[0]=g=>o.value=g),class:"o-theme-switch","checked-value":s.darkValue,"unchecked-value":s.lightValue},{on:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),{class:"o-theme-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(so))]),_:1})]),off:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),{class:"o-theme-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(ao))]),_:1})]),_:1},8,["modelValue","checked-value","unchecked-value"])]))]))}}),_h=Ue._export_sfc(cy,[["__scopeId","data-v-9aaa2610"]]),rc=new Map([[1,{label:"线下",value:1}],[2,{label:"线上",value:2}],[3,{label:"线上与线下",value:3}]]),sc=/^http(s)?:\/\/([\w-]+\.)+[\w-]+(\/[\w ./?%&=-]*)?$/,Ps=new Map([[1,{id:"draft",label:"草稿",text:"草稿",value:1}],[2,{id:"under-review",label:"审核中",text:"未审核",value:2}],[3,{id:"registration",label:"报名中",text:"审核通过",value:3}],[4,{id:"in-progress",label:"进行中",text:"审核通过",value:4}],[5,{id:"ended",label:"已结束",text:"已结束",value:5}],[6,{id:"modified",label:"已修改",text:"已修改",value:6}],[7,{id:"reject",label:"审核驳回",text:"审核驳回",value:7}]]),dy=new Map([["all",{label:"全部",value:"all"}],["rejected",{label:"审核驳回",value:"rejected"}],["approved",{label:"审核通过",value:"approved"}],["publish",{label:"未审核",value:"publish"}],["cancel",{label:"已取消",value:"cancel"}]]),hy={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function fy(s,e){return n.openBlock(),n.createElementBlock("svg",hy,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M10 14.267c-0.413 0-0.817-0.043-1.211-0.131h-0.001c-0.329-0.073-0.652-0.176-0.968-0.31-0.318-0.135-0.618-0.295-0.902-0.482-0.314-0.207-0.607-0.446-0.878-0.718s-0.511-0.564-0.718-0.878c-0.187-0.283-0.348-0.584-0.482-0.902-0.134-0.316-0.237-0.639-0.31-0.968v0c-0.087-0.394-0.131-0.798-0.131-1.211s0.044-0.817 0.131-1.212v0c0.073-0.33 0.176-0.652 0.31-0.968 0.134-0.318 0.295-0.618 0.482-0.902v0c0.207-0.314 0.446-0.607 0.718-0.878s0.564-0.511 0.878-0.718c0.283-0.187 0.584-0.347 0.902-0.482 0.316-0.134 0.639-0.237 0.968-0.31v0c0.394-0.087 0.798-0.131 1.211-0.131s0.817 0.044 1.212 0.131v0c0.33 0.073 0.652 0.176 0.968 0.31 0.318 0.134 0.618 0.295 0.902 0.482 0.314 0.207 0.607 0.446 0.878 0.718s0.511 0.564 0.718 0.878v0c0.187 0.283 0.347 0.584 0.482 0.902 0.134 0.316 0.237 0.639 0.31 0.968v0.001c0.087 0.394 0.131 0.798 0.131 1.211v4.667c0 0.129-0.023 0.248-0.068 0.358v0c-0.046 0.11-0.114 0.21-0.205 0.302s-0.192 0.159-0.302 0.205v0c-0.11 0.046-0.229 0.068-0.358 0.068h-4.667zM16.4 13.333c0 0.129 0.023 0.248 0.068 0.358s0.114 0.211 0.205 0.302c0.091 0.091 0.192 0.159 0.302 0.205v0c0.11 0.046 0.229 0.068 0.358 0.068h4.667c0.413 0 0.817-0.044 1.212-0.131v0c0.329-0.073 0.652-0.176 0.968-0.31 0.318-0.134 0.618-0.295 0.902-0.482 0.314-0.207 0.607-0.446 0.878-0.718s0.511-0.564 0.718-0.878v0c0.187-0.283 0.347-0.584 0.482-0.902 0.134-0.316 0.237-0.639 0.31-0.968v0c0.087-0.394 0.131-0.798 0.131-1.211s-0.044-0.817-0.131-1.212c-0.073-0.33-0.176-0.652-0.31-0.968-0.134-0.318-0.295-0.618-0.482-0.902v0c-0.207-0.314-0.447-0.607-0.718-0.878s-0.564-0.511-0.878-0.718c-0.283-0.187-0.584-0.347-0.902-0.482-0.316-0.134-0.639-0.237-0.968-0.31-0.394-0.087-0.798-0.131-1.212-0.131s-0.817 0.044-1.212 0.131c-0.33 0.073-0.652 0.176-0.968 0.31-0.318 0.134-0.618 0.295-0.902 0.482-0.314 0.207-0.607 0.446-0.878 0.718s-0.511 0.564-0.718 0.878c-0.187 0.283-0.348 0.584-0.482 0.902-0.134 0.316-0.237 0.639-0.31 0.968-0.087 0.394-0.131 0.798-0.131 1.212v4.667zM22 12.4h-3.733v-3.733c0-0.287 0.031-0.568 0.094-0.84 0.048-0.208 0.114-0.413 0.199-0.612 0.087-0.206 0.191-0.401 0.311-0.586 0.14-0.215 0.303-0.416 0.489-0.601s0.386-0.349 0.601-0.489l0.001-0.001c0.184-0.12 0.379-0.224 0.585-0.311 0.2-0.085 0.404-0.151 0.612-0.199 0.273-0.063 0.553-0.094 0.84-0.094s0.567 0.031 0.84 0.094c0.208 0.048 0.413 0.114 0.613 0.199 0.206 0.087 0.401 0.191 0.586 0.311 0.215 0.14 0.416 0.304 0.601 0.489s0.349 0.386 0.489 0.601c0.12 0.184 0.224 0.38 0.311 0.586 0.085 0.2 0.151 0.404 0.199 0.612 0.063 0.273 0.094 0.553 0.094 0.84s-0.031 0.568-0.094 0.84c-0.048 0.208-0.114 0.413-0.199 0.612-0.087 0.206-0.191 0.401-0.311 0.586v0c-0.14 0.215-0.303 0.416-0.489 0.601s-0.386 0.349-0.601 0.489c-0.184 0.12-0.38 0.224-0.586 0.311-0.2 0.085-0.404 0.151-0.613 0.199h-0.001c-0.273 0.063-0.552 0.094-0.84 0.094zM13.733 12.4v-3.733c0-0.287-0.031-0.568-0.094-0.84-0.048-0.208-0.114-0.413-0.199-0.612-0.087-0.206-0.191-0.401-0.311-0.586-0.14-0.215-0.303-0.416-0.489-0.601s-0.386-0.349-0.601-0.489c-0.184-0.12-0.38-0.224-0.586-0.311-0.2-0.085-0.404-0.151-0.612-0.199-0.273-0.063-0.553-0.094-0.841-0.094s-0.567 0.031-0.84 0.094c-0.208 0.048-0.413 0.114-0.612 0.199-0.206 0.087-0.401 0.191-0.586 0.311v0c-0.215 0.14-0.416 0.303-0.601 0.489s-0.349 0.386-0.489 0.601v0c-0.12 0.184-0.224 0.38-0.311 0.586-0.085 0.2-0.151 0.404-0.199 0.612-0.063 0.273-0.094 0.553-0.094 0.84s0.031 0.568 0.094 0.84c0.048 0.208 0.114 0.413 0.199 0.612 0.087 0.206 0.191 0.401 0.311 0.586 0.14 0.215 0.304 0.416 0.489 0.601s0.386 0.349 0.601 0.489c0.184 0.12 0.38 0.224 0.586 0.311 0.2 0.085 0.404 0.151 0.612 0.199v0c0.273 0.063 0.553 0.094 0.84 0.094h3.733zM16.4 16c0-0.258 0.091-0.478 0.273-0.66 0.091-0.091 0.192-0.159 0.302-0.205s0.229-0.068 0.358-0.068h4.667c0.414 0 0.817 0.044 1.212 0.131 0.329 0.073 0.652 0.176 0.968 0.31 0.318 0.134 0.618 0.295 0.902 0.482 0.314 0.207 0.607 0.446 0.878 0.718s0.511 0.564 0.718 0.878c0.187 0.283 0.347 0.584 0.482 0.902 0.134 0.316 0.237 0.639 0.31 0.968 0.087 0.394 0.131 0.798 0.131 1.212s-0.044 0.817-0.131 1.212c-0.073 0.33-0.176 0.652-0.31 0.968-0.134 0.318-0.295 0.618-0.482 0.902-0.207 0.314-0.447 0.607-0.718 0.878s-0.564 0.511-0.878 0.718c-0.283 0.187-0.584 0.347-0.902 0.482-0.316 0.134-0.639 0.237-0.968 0.31-0.394 0.087-0.798 0.131-1.212 0.131s-0.817-0.044-1.212-0.131c-0.33-0.073-0.652-0.176-0.968-0.31-0.318-0.134-0.618-0.295-0.902-0.482-0.314-0.207-0.607-0.446-0.878-0.718s-0.511-0.564-0.718-0.878c-0.187-0.283-0.348-0.584-0.482-0.902-0.134-0.316-0.237-0.639-0.31-0.968v0c-0.087-0.394-0.131-0.798-0.131-1.212v-4.667zM10 15.067c-0.413 0-0.817 0.044-1.212 0.131v0c-0.329 0.073-0.652 0.176-0.968 0.31-0.318 0.134-0.618 0.295-0.902 0.482-0.314 0.207-0.607 0.446-0.878 0.718s-0.511 0.564-0.718 0.878c-0.187 0.283-0.348 0.584-0.482 0.901-0.134 0.316-0.237 0.639-0.31 0.968-0.087 0.394-0.131 0.798-0.131 1.212s0.044 0.817 0.131 1.212c0.073 0.329 0.176 0.652 0.31 0.968 0.134 0.318 0.295 0.618 0.482 0.902v0c0.207 0.314 0.446 0.607 0.718 0.878s0.564 0.511 0.878 0.718c0.283 0.187 0.584 0.347 0.902 0.482 0.316 0.134 0.639 0.237 0.968 0.31 0.394 0.087 0.798 0.131 1.212 0.131s0.817-0.044 1.212-0.131v0c0.33-0.073 0.652-0.176 0.968-0.31 0.318-0.134 0.618-0.295 0.902-0.482 0.314-0.207 0.607-0.446 0.878-0.718s0.511-0.564 0.718-0.878v0c0.187-0.283 0.347-0.584 0.482-0.902 0.134-0.316 0.237-0.639 0.31-0.968 0.087-0.394 0.131-0.798 0.131-1.212v-4.667c0-0.258-0.091-0.478-0.273-0.66-0.091-0.091-0.192-0.159-0.302-0.205s-0.229-0.068-0.358-0.068h-4.667zM13.733 16.933v3.733c0 0.287-0.031 0.567-0.094 0.84-0.048 0.208-0.114 0.413-0.199 0.612-0.087 0.206-0.191 0.401-0.311 0.585v0c-0.14 0.215-0.303 0.416-0.489 0.601s-0.386 0.349-0.601 0.489c-0.184 0.12-0.38 0.224-0.586 0.311-0.2 0.085-0.404 0.151-0.612 0.199-0.273 0.063-0.553 0.094-0.841 0.094s-0.567-0.031-0.84-0.094h-0.001c-0.208-0.048-0.412-0.114-0.612-0.199-0.206-0.087-0.401-0.191-0.586-0.311v0c-0.215-0.14-0.416-0.303-0.601-0.489s-0.349-0.386-0.489-0.601c-0.12-0.184-0.224-0.38-0.311-0.586-0.085-0.2-0.151-0.404-0.199-0.612-0.063-0.273-0.094-0.553-0.094-0.84s0.031-0.568 0.094-0.841c0.048-0.208 0.114-0.412 0.199-0.612 0.087-0.206 0.191-0.401 0.311-0.586 0.14-0.215 0.304-0.416 0.489-0.601s0.386-0.349 0.601-0.489c0.184-0.12 0.38-0.224 0.586-0.311 0.2-0.085 0.404-0.151 0.612-0.199h0.001c0.273-0.063 0.553-0.094 0.84-0.094h3.733zM22 16.933h-3.733v3.733c0 0.287 0.031 0.567 0.094 0.84 0.048 0.208 0.114 0.413 0.199 0.612 0.087 0.206 0.191 0.401 0.311 0.586 0.14 0.215 0.303 0.416 0.489 0.601s0.386 0.349 0.601 0.489c0.184 0.12 0.379 0.224 0.586 0.311 0.2 0.085 0.404 0.151 0.612 0.199 0.273 0.063 0.553 0.094 0.84 0.094s0.567-0.031 0.84-0.094c0.208-0.048 0.413-0.114 0.613-0.199 0.206-0.087 0.401-0.191 0.586-0.311 0.215-0.141 0.416-0.304 0.601-0.489s0.349-0.386 0.489-0.601c0.12-0.184 0.224-0.38 0.311-0.586 0.085-0.2 0.151-0.404 0.199-0.612 0.063-0.273 0.094-0.553 0.094-0.84s-0.031-0.568-0.094-0.841c-0.048-0.208-0.114-0.412-0.199-0.612-0.087-0.206-0.191-0.401-0.311-0.586-0.141-0.215-0.304-0.416-0.489-0.601s-0.386-0.349-0.601-0.489c-0.184-0.12-0.38-0.224-0.586-0.311-0.2-0.085-0.404-0.151-0.613-0.199-0.273-0.063-0.553-0.094-0.84-0.094z"},null,-1)])])}const py={name:"meeting-icon-all",render:fy},my={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function gy(s,e){return n.openBlock(),n.createElementBlock("svg",my,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M25.088 14.216l-0.852 0.781c-0.385 0.353-0.411 0.933-0.058 1.319s0.933 0.411 1.319 0.058l2.116-1.938c0.193-0.177 0.349-0.374 0.467-0.591 0.092-0.17 0.162-0.351 0.208-0.546 0.045-0.189 0.067-0.378 0.063-0.566-0.004-0.222-0.041-0.444-0.112-0.665s-0.17-0.423-0.297-0.605c-0.107-0.155-0.235-0.295-0.382-0.422-0.151-0.13-0.314-0.237-0.488-0.321-0.223-0.107-0.464-0.176-0.724-0.207l-5.601-0.661c-0.031-0.012-0.159-0.053-0.187-0.073-0.021-0.026-0.113-0.124-0.128-0.155l-2.377-5.087c-0.11-0.235-0.25-0.441-0.42-0.618v0c-0.133-0.138-0.285-0.259-0.454-0.362-0.165-0.1-0.338-0.177-0.517-0.232v0c-0.211-0.064-0.432-0.096-0.662-0.096s-0.451 0.032-0.662 0.096v0c-0.179 0.054-0.352 0.131-0.517 0.232-0.17 0.103-0.321 0.224-0.454 0.362-0.17 0.177-0.31 0.383-0.42 0.618l-2.377 5.087c-0.021 0.026-0.1 0.135-0.128 0.155-0.031 0.012-0.153 0.069-0.187 0.073l-5.601 0.661c-0.26 0.031-0.501 0.1-0.724 0.207v0c-0.174 0.084-0.336 0.191-0.488 0.321-0.147 0.127-0.275 0.267-0.382 0.422-0.127 0.182-0.226 0.384-0.297 0.605s-0.109 0.443-0.112 0.665c-0.003 0.188 0.018 0.377 0.063 0.566 0.047 0.194 0.116 0.376 0.208 0.546 0.118 0.217 0.274 0.414 0.467 0.591l4.119 3.773c0.018 0.029 0.099 0.137 0.11 0.171 0.001 0.009 0.002 0.025 0.004 0.044 0.005 0.054 0.013 0.133 0.008 0.159l-1.093 5.462c-0.051 0.255-0.060 0.505-0.028 0.749 0.025 0.191 0.076 0.378 0.152 0.562 0.074 0.179 0.168 0.343 0.28 0.493 0.133 0.177 0.293 0.333 0.479 0.47s0.384 0.241 0.593 0.315c0.177 0.062 0.362 0.101 0.555 0.118 0.198 0.017 0.392 0.009 0.581-0.025h0.001c0.242-0.043 0.478-0.127 0.705-0.253l4.953-2.737c0.032-0.008 0.159-0.050 0.193-0.050 0.032 0.008 0.163 0.033 0.193 0.050l4.831 2.669c0.233 0.129 0.473 0.214 0.72 0.256h0.001c0.192 0.033 0.388 0.039 0.588 0.020 0.195-0.019 0.382-0.061 0.56-0.126v0c0.211-0.077 0.411-0.187 0.598-0.329s0.347-0.305 0.478-0.488c0.111-0.154 0.201-0.323 0.271-0.506 0.072-0.188 0.119-0.379 0.139-0.573 0.026-0.25 0.008-0.504-0.053-0.762l-2.084-8.779c-0.121-0.509-0.615-0.813-1.124-0.693s-0.813 0.615-0.693 1.124l2.084 8.779c0.020 0.084 0.018 0.161-0.007 0.229s-0.071 0.129-0.141 0.181c-0.069 0.053-0.14 0.081-0.213 0.087s-0.147-0.013-0.223-0.055l-4.831-2.669c-0.171-0.094-0.347-0.165-0.53-0.212v0c-0.183-0.047-0.372-0.071-0.566-0.071s-0.384 0.024-0.566 0.071c-0.183 0.047-0.359 0.118-0.53 0.212l-4.953 2.737c-0.075 0.041-0.148 0.059-0.219 0.055s-0.142-0.032-0.21-0.082c-0.069-0.050-0.116-0.109-0.142-0.176s-0.031-0.142-0.014-0.226l1.093-5.462c0.039-0.195 0.053-0.387 0.041-0.579s-0.048-0.381-0.109-0.57c-0.062-0.189-0.144-0.363-0.248-0.525s-0.229-0.309-0.375-0.443l-4.119-3.773c-0.063-0.058-0.104-0.122-0.122-0.191s-0.014-0.145 0.012-0.227c0.026-0.081 0.067-0.145 0.123-0.191s0.126-0.074 0.211-0.084l5.601-0.661c0.195-0.023 0.381-0.069 0.558-0.138s0.345-0.161 0.504-0.276c0.159-0.115 0.299-0.245 0.42-0.392s0.223-0.308 0.306-0.486l2.377-5.087c0.036-0.077 0.084-0.135 0.145-0.173s0.133-0.058 0.218-0.058c0.085 0 0.157 0.019 0.218 0.058s0.109 0.096 0.144 0.173l2.377 5.087c0.083 0.178 0.185 0.34 0.306 0.486s0.261 0.277 0.42 0.392c0.159 0.115 0.327 0.207 0.504 0.276s0.363 0.115 0.558 0.138l5.601 0.661c0.085 0.010 0.155 0.038 0.211 0.084s0.097 0.109 0.123 0.191c0.026 0.081 0.030 0.157 0.012 0.227s-0.059 0.133-0.122 0.191l-1.263 1.157zM10.007 15.327l2 2c0.369 0.37 0.95 0.37 1.32 0s0.37-0.95 0-1.32l-2-2c-0.369-0.37-0.95-0.37-1.32 0s-0.37 0.95 0 1.32z"},null,-1)])])}const yh={name:"meeting-icon-event",render:gy},_y={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function yy(s,e){return n.openBlock(),n.createElementBlock("svg",_y,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M16.933 4v1.733h8.4c0.163 0 0.323 0.017 0.479 0.050 0.137 0.030 0.272 0.072 0.404 0.128 0.131 0.055 0.254 0.122 0.37 0.199 0.125 0.083 0.242 0.179 0.35 0.287s0.204 0.225 0.287 0.35c0.077 0.116 0.143 0.24 0.199 0.37 0.056 0.132 0.098 0.266 0.128 0.404 0.034 0.156 0.050 0.315 0.050 0.479v7.222c0 0.523-0.411 0.933-0.933 0.933s-0.933-0.411-0.933-0.933v-7.222c0-0.055-0.010-0.106-0.029-0.154s-0.178-0.178-0.217-0.217c-0.047-0.020-0.098-0.029-0.154-0.029h-18.667c-0.055 0-0.106 0.010-0.153 0.029v0 0 0c-0.047 0.020-0.178 0.178-0.217 0.217-0.020 0.047-0.029 0.098-0.029 0.154v13.333c0 0.055 0.010 0.106 0.029 0.153v0c0.020 0.047 0.178 0.178 0.217 0.217 0.047 0.020 0.098 0.029 0.153 0.029h18.667c0.055 0 0.107-0.010 0.154-0.029s0.178-0.178 0.217-0.217c0.019-0.047 0.029-0.098 0.029-0.153v-2.953c0-0.523 0.411-0.933 0.933-0.933s0.933 0.411 0.933 0.933v2.953c0 0.163-0.017 0.323-0.050 0.479-0.030 0.137-0.072 0.272-0.128 0.404-0.055 0.131-0.121 0.254-0.199 0.37-0.083 0.125-0.179 0.242-0.287 0.35s-0.225 0.204-0.35 0.287c-0.116 0.077-0.24 0.143-0.37 0.199-0.132 0.056-0.266 0.098-0.404 0.128-0.156 0.034-0.316 0.051-0.479 0.051h-0.44l2.42 2.42c0.37 0.37 0.37 0.95 0 1.32s-0.95 0.37-1.32 0l-3.74-3.74h-12.507l-3.74 3.74c-0.37 0.37-0.95 0.37-1.32 0s-0.369-0.95 0-1.32l2.42-2.42h-0.44c-0.163 0-0.323-0.017-0.479-0.050v0c-0.137-0.030-0.272-0.072-0.404-0.128-0.131-0.055-0.254-0.122-0.37-0.199v0c-0.125-0.083-0.242-0.178-0.35-0.287s-0.204-0.225-0.287-0.35v0c-0.077-0.116-0.143-0.24-0.199-0.37-0.056-0.132-0.098-0.266-0.128-0.404v0c-0.034-0.156-0.050-0.315-0.050-0.479v-13.333c0-0.163 0.017-0.323 0.050-0.479 0.030-0.137 0.072-0.272 0.128-0.404 0.055-0.131 0.121-0.254 0.199-0.37 0.083-0.125 0.179-0.242 0.287-0.35s0.225-0.204 0.35-0.287c0.116-0.077 0.24-0.143 0.37-0.199 0.132-0.056 0.266-0.098 0.404-0.128v0c0.156-0.034 0.315-0.050 0.479-0.050h8.4v-1.733c0-0.523 0.411-0.933 0.933-0.933s0.933 0.411 0.933 0.933zM18.72 17.392l4.615-4.741c0.365-0.374 0.357-0.955-0.018-1.32s-0.955-0.357-1.32 0.018l-3.906 4.012-3.532-4.067c-0.195-0.169-0.421-0.244-0.678-0.225s-0.47 0.125-0.639 0.32l-4.615 5.333c-0.342 0.395-0.3 0.975 0.095 1.317s0.974 0.3 1.316-0.095l3.91-4.518 3.397 3.925c0.169 0.195 0.381 0.302 0.639 0.32s0.541-0.111 0.736-0.28z"},null,-1)])])}const Al={name:"meeting-icon-meet",render:yy},vy={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function Ty(s,e){return n.openBlock(),n.createElementBlock("svg",vy,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M10.633 5.457c-1.119 0.457-2.181 1.053-3.185 1.79-0.422 0.309-0.51 0.883-0.201 1.305s0.883 0.51 1.305 0.201c0.927-0.68 1.908-1.223 2.943-1.629 0.185-0.073 0.373-0.141 0.562-0.205 0.658-0.223 1.325-0.389 2.001-0.497 0.64-0.103 1.287-0.154 1.943-0.154s1.304 0.051 1.943 0.154v0c0.676 0.108 1.343 0.274 2.001 0.497 0.189 0.064 0.376 0.133 0.562 0.205v0c1.035 0.407 2.015 0.95 2.943 1.629 0.421 0.309 0.996 0.221 1.305-0.201s0.221-0.996-0.201-1.305c-1.005-0.736-2.067-1.333-3.185-1.79-0.271-0.111-0.545-0.213-0.823-0.307-0.755-0.256-1.52-0.447-2.297-0.572-0.739-0.119-1.488-0.179-2.247-0.179s-1.508 0.060-2.247 0.179v0c-0.776 0.125-1.541 0.316-2.296 0.572-0.277 0.094-0.552 0.197-0.823 0.307v0zM28.933 18.667v1.333c0 0.163-0.017 0.323-0.051 0.479-0.030 0.137-0.072 0.272-0.128 0.404-0.055 0.131-0.121 0.254-0.199 0.37-0.083 0.125-0.179 0.242-0.287 0.35s-0.225 0.204-0.35 0.287c-0.116 0.077-0.24 0.143-0.37 0.199-0.132 0.056-0.267 0.099-0.404 0.128-0.156 0.034-0.315 0.050-0.479 0.050h-21.333c-0.163 0-0.323-0.017-0.479-0.050-0.137-0.030-0.272-0.072-0.404-0.128-0.131-0.055-0.254-0.121-0.37-0.199-0.125-0.083-0.242-0.178-0.35-0.287s-0.204-0.225-0.287-0.35c-0.077-0.116-0.143-0.24-0.199-0.37s-0.098-0.266-0.128-0.404c-0.034-0.156-0.050-0.315-0.050-0.479v-8c0-0.163 0.017-0.323 0.050-0.479 0.030-0.137 0.072-0.272 0.128-0.404s0.121-0.254 0.199-0.37c0.083-0.125 0.179-0.242 0.287-0.35s0.225-0.204 0.35-0.287c0.116-0.077 0.24-0.143 0.37-0.199 0.132-0.056 0.266-0.098 0.404-0.128v0c0.156-0.034 0.315-0.050 0.479-0.050h21.333c0.163 0 0.323 0.017 0.479 0.050 0.137 0.030 0.272 0.072 0.404 0.128 0.131 0.055 0.254 0.122 0.37 0.199 0.125 0.083 0.241 0.178 0.35 0.287s0.204 0.225 0.287 0.35c0.077 0.116 0.143 0.24 0.199 0.37 0.056 0.132 0.099 0.266 0.128 0.404v0c0.034 0.156 0.050 0.315 0.050 0.478v4c0 0.523-0.411 0.933-0.933 0.933s-0.933-0.411-0.933-0.933v-4c0-0.055-0.010-0.106-0.029-0.154s-0.178-0.178-0.217-0.217c-0.047-0.020-0.098-0.029-0.154-0.029h-21.333c-0.055 0-0.106 0.010-0.153 0.029v0 0c-0.047 0.020-0.178 0.178-0.217 0.217-0.020 0.047-0.029 0.098-0.029 0.154v8c0 0.055 0.010 0.106 0.029 0.154s0.178 0.178 0.217 0.217c0.047 0.020 0.098 0.029 0.153 0.029h21.333c0.055 0 0.106-0.010 0.154-0.029s0.178-0.178 0.217-0.217c0.019-0.047 0.029-0.098 0.029-0.154v-1.333c0-0.523 0.411-0.933 0.933-0.933s0.933 0.411 0.933 0.933zM20.479 23.117v0c0.137 0.030 0.272 0.072 0.404 0.128 0.131 0.055 0.254 0.121 0.37 0.199 0.125 0.083 0.241 0.179 0.35 0.287s0.204 0.225 0.287 0.35c0.077 0.116 0.143 0.24 0.199 0.37 0.056 0.132 0.099 0.266 0.128 0.404v0c0.034 0.156 0.051 0.316 0.051 0.479s-0.017 0.323-0.051 0.479c-0.030 0.137-0.072 0.272-0.128 0.404-0.055 0.131-0.121 0.254-0.199 0.37-0.083 0.125-0.179 0.242-0.287 0.35s-0.225 0.204-0.35 0.287c-0.116 0.077-0.24 0.143-0.37 0.199-0.132 0.056-0.267 0.098-0.404 0.128-0.156 0.034-0.316 0.051-0.479 0.051h-8c-0.163 0-0.323-0.017-0.479-0.051-0.137-0.030-0.272-0.072-0.404-0.128-0.131-0.055-0.254-0.121-0.37-0.199-0.125-0.083-0.242-0.179-0.35-0.287s-0.204-0.225-0.287-0.35c-0.077-0.116-0.143-0.24-0.199-0.37-0.056-0.132-0.098-0.266-0.128-0.404-0.034-0.156-0.050-0.315-0.050-0.479s0.017-0.323 0.050-0.479c0.030-0.137 0.072-0.272 0.128-0.404 0.055-0.131 0.121-0.254 0.199-0.37 0.083-0.125 0.179-0.241 0.287-0.35s0.225-0.204 0.35-0.287c0.116-0.077 0.24-0.143 0.37-0.199 0.132-0.056 0.266-0.099 0.404-0.128 0.156-0.034 0.316-0.050 0.479-0.050h8c0.163 0 0.323 0.017 0.479 0.050zM20 24.933h-8c-0.055 0-0.106 0.010-0.153 0.029s-0.178 0.178-0.217 0.217c-0.020 0.047-0.029 0.098-0.029 0.154s0.010 0.106 0.029 0.153c0.020 0.047 0.178 0.178 0.217 0.217 0.047 0.020 0.098 0.029 0.153 0.029h8c0.055 0 0.106-0.010 0.154-0.029s0.178-0.178 0.217-0.217c0.019-0.047 0.029-0.098 0.029-0.153s-0.010-0.106-0.029-0.154v0c-0.020-0.047-0.178-0.178-0.217-0.217-0.047-0.019-0.098-0.029-0.154-0.029z"},null,-1)])])}const vh={name:"meeting-icon-summit",render:Ty};var Ke=(s=>(s.ALL="all",s.MEETING="meeting",s.EVENTS="events",s.SUMMIT="summit",s))(Ke||{});const{t:Pt}=Ue.useI18n(),oo={summit:"var(--o-color-warning1)",events:"rgba(var(--o-cyan-6))",meeting:"var(--o-color-primary1)"},ta=[{label:Pt("meeting.meetingTypeAll"),value:Ke.ALL,icon:py},{label:Pt("meeting.meetingTypeMeet"),value:Ke.MEETING,icon:Al,color:oo.meeting,zIndex:3},{label:Pt("meeting.meetingTypeEvents"),value:Ke.EVENTS,icon:yh,color:oo.events,zIndex:2},{label:Pt("meeting.meetingTypeSummit"),value:Ke.SUMMIT,icon:vh,color:oo.summit,zIndex:1}],mn=0,gn=1,nn=2,by=[{label:Pt("meeting.day0"),value:mn,max:7},{label:Pt("meeting.week0"),value:gn,max:2},{label:Pt("meeting.month0"),value:nn,max:1}];Pt("meeting.day"),Pt("meeting.week"),Pt("meeting.month");const Th=[Pt("meeting.sunday"),Pt("meeting.monday"),Pt("meeting.tuesday"),Pt("meeting.wednesday"),Pt("meeting.thursday"),Pt("meeting.friday"),Pt("meeting.saturday")],xy=()=>{const s=[];for(let e=1;e<=7;e++){const i=e%7;s.push({value:i,label:Th[i]})}return s},Ys=xy(),bh=/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/,Cy=["var(--o-color-primary1)","var(--o-color-warning1)","var(--o-color-success1)"],Sy={class:"o-activity-form"},Ey={class:"time-config"},ky={class:"form-btns"},ac=n.defineComponent({__name:"OActivityForm",props:{data:{},creatActivity:{},editActivity:{},admins:{},status:{}},emits:["confirm","close"],setup(s,{expose:e,emit:i}){const r=i,a=O.useMessage(null),{lePadV:o}=wt.useScreen(),{t:l}=Ue.useI18n(),u=l,d=s,f=n.computed(()=>!!d.data),g=n.ref({title:"",organizer:"",start_date:"",end_date:"",register_end_date:"",activity_type:"",synopsis:"",register_url:"",content_url:"",address:"",start:"",end:"",is_publish:"true",email_list:"",content:"",approver:""}),y=n.ref(),E=n.ref(!1),x=n.ref({title:[{required:!0,message:"请输入活动名称"},{validator:q=>{if(q.length>50)return{type:"danger",message:"活动名称不能超过50个字符"}}}],activity_type:[{required:!0,message:"请选择活动类型"}],organizer:[{required:!0,message:"请选择活动类型"}],start_date:[{required:!0,message:"请选择活动时间"},{validator:()=>{const{start_date:q,end_date:M}=g.value,N=q.split(" "),J=M.split(" ");if(!q||!M)return{type:"danger",message:"请选择活动日期"};const b=N[1].split(":").map(Number),C=J[1].split(":").map(Number);if(b[0]<8||b[0]>21||C[0]<8||C[0]>21)return{type:"danger",message:"开始和结束时间必须在8:00-22:00点之间"};if(et.dayjs(q).valueOf()>et.dayjs(M).valueOf())return{type:"danger",message:"结束日期必须大于起始日期"};g.value.start_date=N[0],g.value.end_date=J[0],g.value.start=N[1],g.value.end=J[1]},triggers:["blur","change"]}],register_end_date:[{required:!0,message:"请选择报名截止时间"},{validator:()=>{const{register_end_date:q,end_date:M,end:N}=g.value;if(et.dayjs(`${M} ${N}`).valueOf()<et.dayjs(q).valueOf())return{type:"danger",message:"报名截止日期必须小于结束日期"}},triggers:["blur","change"]}],address:[{required:!0,message:"请输入活动地点"},{validator:q=>{if(q.length>255)return{type:"danger",message:"活动名称不能超过255个字符"}}}],register_url:[{required:!0,message:"请输入活动报名网址"},{validator:q=>{const M=q.replaceAll(" ","")||"";if(M.length&&(M.split(";")||[]).some(J=>!sc.test(J)))return{type:"danger",message:"请输入正确的报名网址"}},triggers:["blur","change"]}],content_url:[{required:!0,message:"请输入活动详情介绍网址"},{validator:q=>{const M=q.replaceAll(" ","")||"";if(M.length&&(M.split(";")||[]).some(J=>!sc.test(J)))return{type:"danger",message:"请输入正确的活动详情网址"}},triggers:["blur","change"]}],content:[{validator:q=>{if(q.length>1e3)return{type:"danger",message:"活动内容不能超过1000个字符"}}}],email_list:[{validator:q=>{const M=q.replaceAll(" ","")||"";if(M.length){if(M.length>1020)return{type:"danger",message:l("meeting.emailTooLong")};const N=M.split(";")||[];if(N.some(J=>!bh.test(J)))return{type:"danger",message:l("meeting.emailInvalid")};if(N.some(J=>J.length>50))return{type:"danger",message:l("meeting.singleEmailTooLong")};if(N.length>20)return{type:"danger",message:l("meeting.emailCountTooLong")}}},triggers:["blur","change"]}],approver:[{required:!0,message:"请选择活动审批人"}]}),B=n.computed(()=>d.admins||[]),T=n.ref(""),w=n.ref([]);rc.forEach(q=>{w.value.push(q)});const F=q=>{const M=w.value.find(N=>N.label===q);g.value.activity_type=M==null?void 0:M.value},P=q=>q.getTime()<Date.now()-1440*60*1e3;n.watch(()=>d.data,q=>{var M;if(q){const{title:N,start_date:J,end_date:b,register_end_date:C,activity_type:U,register_url:j,content_url:k,address:A,start:$,end:Q,is_publish:H,approver:V,update_activity_id:G}=q;let Z={title:N,start_date:J,end_date:b,register_end_date:C,activity_type:U,register_url:j,content_url:k,address:A,start:$,end:Q,is_publish:H,approver:V,update_activity_id:G};g.value={...Z},T.value=(M=rc.get(q.activity_type))==null?void 0:M.label,g.value.start_date=`${g.value.start_date} ${g.value.start}`,g.value.end_date=`${g.value.end_date} ${g.value.end}`}},{immediate:!0,deep:!0});const I=async q=>{var N,J,b,C,U;let M=f.value?"修改":q?"创建":"保存草稿";try{if((await((N=y.value)==null?void 0:N.validate())).some(A=>!!A))return;E.value=!0,g.value.is_publish=`${q}`,f.value&&d.status===3?(g.value.update_activity_id=(J=d.data)==null?void 0:J.id,await((b=d.creatActivity)==null?void 0:b.call(d,g.value))):f.value?await((C=d.editActivity)==null?void 0:C.call(d,d.data.id,g.value)):await((U=d.creatActivity)==null?void 0:U.call(d,g.value));const k=`“${g.value.title}”活动${M}成功`;a.success({content:k}),K(),r("confirm")}catch{E.value=!1,g.value.start_date=`${g.value.start_date} ${g.value.start}`,g.value.end_date=`${g.value.end_date} ${g.value.end}`;const j=`“${g.value.title}”活动${M}失败`;a.danger({content:j})}},K=()=>{g.value={},r("close")};return e({confirm:I}),(q,M)=>(n.openBlock(),n.createElementBlock("div",Sy,[n.createVNode(n.unref(O.OForm),{model:g.value,ref_key:"formRef",ref:y,"has-required":"","label-width":"108px",layout:n.unref(o)?"v":"h",class:"form-wrapper"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OFormItem),{rules:x.value.title,label:"活动名称",field:"title"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OInput),{size:"large",placeholder:"请输入活动名称",modelValue:g.value.title,"onUpdate:modelValue":M[0]||(M[0]=N=>g.value.title=N)},null,8,["modelValue"])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{rules:x.value.organizer,label:"活动主办方",field:"organizer"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OInput),{size:"large",placeholder:"请选择活动主办方",modelValue:g.value.organizer,"onUpdate:modelValue":M[1]||(M[1]=N=>g.value.organizer=N)},null,8,["modelValue"])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{rules:x.value.activity_type,label:"活动类型",field:"activity_type"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OSelect),{placeholder:"请选择活动类型",size:"large",modelValue:T.value,"onUpdate:modelValue":M[2]||(M[2]=N=>T.value=N),onChange:F},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(w.value,N=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{key:N.value,value:N.label},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(N.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["rules"]),g.value.activity_type===1||g.value.activity_type===3?(n.openBlock(),n.createBlock(n.unref(O.OFormItem),{key:0,rules:x.value.address,label:"活动地点",field:"address"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OInput),{size:"large",placeholder:"请输入活动地点",modelValue:g.value.address,"onUpdate:modelValue":M[3]||(M[3]=N=>g.value.address=N)},null,8,["modelValue"])]),_:1},8,["rules"])):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OFormItem),{rules:x.value.start_date,label:"活动时间",field:"start_date",required:""},{default:n.withCtx(()=>[n.createElementVNode("div",Ey,[n.createVNode(n.unref(O.OFormItem),{label:"起始日期",field:"start_date"},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElDatePicker),{size:"large",modelValue:g.value.start_date,"onUpdate:modelValue":M[4]||(M[4]=N=>g.value.start_date=N),type:"datetime",placeholder:"请选择日期",format:"YYYY/MM/DD HH:mm","value-format":"YYYY-MM-DD HH:mm","disabled-date":P,clearable:!1,class:"date-activity"},null,8,["modelValue"])]),_:1}),n.createVNode(n.unref(O.OFormItem),{label:"结束日期",field:"end_date"},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElDatePicker),{size:"large",modelValue:g.value.end_date,"onUpdate:modelValue":M[5]||(M[5]=N=>g.value.end_date=N),type:"datetime",placeholder:"请选择日期",format:"YYYY/MM/DD HH:mm","value-format":"YYYY-MM-DD HH:mm","disabled-date":P,clearable:!1,class:"date-activity"},null,8,["modelValue"])]),_:1})])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{rules:x.value.register_end_date,label:"报名截止时间",field:"register_end_date"},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElDatePicker),{size:"large",modelValue:g.value.register_end_date,"onUpdate:modelValue":M[6]||(M[6]=N=>g.value.register_end_date=N),type:"datetime",placeholder:"请选择报名截止时间",format:"YYYY/MM/DD HH:mm","value-format":"YYYY-MM-DD HH:mm",clearable:!1,class:"date-activity"},null,8,["modelValue"])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{rules:x.value.register_url,label:"报名网址",field:"register_url"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OInput),{size:"large",placeholder:"请输入活动报名网址",modelValue:g.value.register_url,"onUpdate:modelValue":M[7]||(M[7]=N=>g.value.register_url=N)},null,8,["modelValue"])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{rules:x.value.content_url,label:"活动详情网址",field:"content_url"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OInput),{size:"large",placeholder:"请输入活动详情介绍网址",modelValue:g.value.content_url,"onUpdate:modelValue":M[8]||(M[8]=N=>g.value.content_url=N)},null,8,["modelValue"])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{rules:x.value.content,label:"活动内容",field:"content"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OTextarea),{size:"large",placeholder:"请输入活动内容",modelValue:g.value.content,"onUpdate:modelValue":M[9]||(M[9]=N=>g.value.content=N)},null,8,["modelValue"])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{field:"email_list",rules:x.value.email_list,label:"邮件地址"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OTextarea),{disabled:f.value,size:"large",placeholder:n.unref(u)("meeting.enterEmail"),rows:4,modelValue:g.value.email_list,"onUpdate:modelValue":M[10]||(M[10]=N=>g.value.email_list=N)},null,8,["disabled","placeholder","modelValue"])]),_:1},8,["rules"]),n.createVNode(n.unref(O.OFormItem),{rules:x.value.approver,label:"活动审批人",field:"approver"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OSelect),{placeholder:"请选择活动审批人",size:"large",modelValue:g.value.approver,"onUpdate:modelValue":M[11]||(M[11]=N=>g.value.approver=N)},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(B.value,N=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{key:N,value:N},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(N),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["rules"])]),_:1},8,["model","layout"]),n.createElementVNode("div",ky,[n.createVNode(n.unref(O.OButton),{color:"primary",variant:"solid",size:"large",round:"pill",onClick:M[12]||(M[12]=N=>I(!0)),loading:E.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.value?"保存":"创建"),1)]),_:1},8,["loading"]),f.value?n.createCommentVNode("",!0):(n.openBlock(),n.createBlock(n.unref(O.OButton),{key:0,color:"primary",variant:"outline",round:"pill",size:"large",onClick:M[13]||(M[13]=N=>I(!1)),loading:E.value},{default:n.withCtx(()=>[...M[14]||(M[14]=[n.createTextVNode(" 保存草稿 ",-1)])]),_:1},8,["loading"])),n.createVNode(n.unref(O.OButton),{color:"primary",variant:"outline",size:"large",round:"pill",onClick:K},{default:n.withCtx(()=>[...M[15]||(M[15]=[n.createTextVNode("取消",-1)])]),_:1})])]))}}),wy={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function Dy(s,e){return n.openBlock(),n.createElementBlock("svg",wy,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.8",fill:"#000",d:"M17.286 5c0.676 0 1.213 0.546 1.213 1.21 0 0.227-0.064 0.449-0.184 0.641l-0.065 0.093-1.24 1.62c-0.149 0.194-0.433 0.236-0.634 0.092-0.181-0.129-0.234-0.364-0.134-0.551l0.039-0.060 1.24-1.62c0.046-0.060 0.071-0.136 0.071-0.214 0-0.169-0.113-0.302-0.253-0.329l-0.054-0.005h-10.573c-0.064 0-0.126 0.022-0.179 0.064-0.126 0.099-0.162 0.281-0.092 0.426l0.036 0.059 4.207 5.495c0.138 0.18 0.221 0.394 0.243 0.617l0.006 0.112 0.015 3.985c0 0.088 0.033 0.171 0.087 0.232l0.045 0.042 1.525 1.158c0.052 0.040 0.114 0.060 0.176 0.060 0.146-0.001 0.274-0.116 0.301-0.275l0.005-0.062-0.020-5.134c-0.001-0.228 0.063-0.452 0.184-0.645l0.065-0.094 1.804-2.357c0.149-0.194 0.433-0.236 0.634-0.092 0.181 0.129 0.234 0.364 0.134 0.551l-0.039 0.060-1.805 2.357c-0.035 0.045-0.058 0.099-0.067 0.157l-0.005 0.059 0.020 5.134c0.003 0.663-0.533 1.212-1.209 1.214-0.23 0.001-0.454-0.063-0.647-0.183l-0.094-0.064-1.525-1.158c-0.267-0.203-0.436-0.506-0.471-0.834l-0.007-0.124-0.015-3.985c-0-0.059-0.015-0.115-0.041-0.165l-0.030-0.047-4.207-5.495c-0.401-0.523-0.308-1.272 0.211-1.682 0.183-0.145 0.405-0.234 0.637-0.256l0.117-0.006h10.573z"},null,-1)])])}const oc={name:"components-icon-filter",render:Dy},Ay={class:"th-filter-wrapper",ref:"filterRef"},Iy={key:1,class:"list-content-wrapper"},Ny={class:"btn-wrapper"},lc=n.defineComponent({__name:"ThFilter",props:{modelValue:{},list:{default:()=>[]},multiple:{type:Boolean,default:!1},tableWidth:{}},emits:["update:model-value","confirm"],setup(s,{emit:e}){const{t:i}=wt.useLocale(),r=s,a=e,o=n.computed(()=>r.list.some(I=>{var K;return(K=I.children)==null?void 0:K.length})),l=n.computed(()=>r.list.map(I=>{const K=(I.children||[]).map(q=>({label:q.label,value:q.value}));return{label:I.label,value:I.value,children:o.value?K:void 0}})),u=n.ref(!1);n.watch(()=>r.modelValue,I=>{r.multiple?d.value=I:y.value=I});const d=n.ref([]),f=I=>{d.value=I},g=n.ref([]),y=n.ref(null),E=I=>{y.value===I?y.value=null:y.value=I,B()},x=()=>{d.value=[],g.value=[],y.value=null,B()},B=()=>{let I=null;r.multiple?o.value?I=g.value:I=d.value:I=y.value,a("update:model-value",I),u.value=!0,n.nextTick(()=>{a("confirm"),u.value=!1})},T=n.computed(()=>d.value.length||g.value.length||y.value||r.modelValue),w=n.ref(null),F=async I=>{var M,N;const K=I.target.parentElement.parentElement;await n.nextTick();const q=K.querySelector("input");q.click(),await n.nextTick(),(M=q.change)==null||M.call(q,q),await n.nextTick(),(N=w.value)==null||N.$forceUpdate(),g.value=JSON.parse(JSON.stringify(g.value))},P=({data:I})=>n.h("span",{onclick:F},I.label);return(I,K)=>{const q=n.resolveComponent("ElCascaderPanel"),M=n.resolveDirective("dompurify-html");return n.openBlock(),n.createElementBlock("div",Ay,[n.createElementVNode("span",null,[n.renderSlot(I.$slots,"default")]),s.multiple?(n.openBlock(),n.createBlock(n.unref(O.OPopover),{key:0,visible:u.value,position:"bottom",wrapClass:"th-filter-popover",trigger:"click",anchor:!1},{target:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(["filter-wrapper",T.value&&"has-checked"])},[n.createVNode(n.unref(O.OIcon),{class:"filter-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(oc))]),_:1})],2)]),default:n.withCtx(()=>[o.value?(n.openBlock(),n.createElementBlock("div",Iy,[n.createVNode(q,{ref_key:"aref",ref:w,expandTrigger:"hover",renderLabel:P,modelValue:g.value,"onUpdate:modelValue":K[1]||(K[1]=N=>g.value=N),style:{width:"fit-content"},options:l.value,props:{multiple:!0,expandTrigger:"hover"}},null,8,["modelValue","options"])])):(n.openBlock(),n.createBlock(n.unref(O.OScroller),{key:0,class:"content-wrapper","show-type":"hover","disabled-x":""},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OCheckboxGroup),{direction:"v",onChange:f,modelValue:d.value,"onUpdate:modelValue":K[0]||(K[0]=N=>d.value=N)},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(l.value,N=>(n.openBlock(),n.createBlock(n.unref(O.OCheckbox),{key:N.value,value:N.value},{default:n.withCtx(()=>[n.withDirectives(n.createElementVNode("span",null,null,512),[[M,N.label]])]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]),_:1})),n.createVNode(n.unref(O.ODivider)),n.createElementVNode("div",Ny,[n.createVNode(n.unref(O.OLink),{onClick:x},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(i)("common.reset")),1)]),_:1}),n.createVNode(n.unref(O.OLink),{onClick:B},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(i)("common.confirm")),1)]),_:1})])]),_:1},8,["visible"])):(n.openBlock(),n.createBlock(n.unref(O.ODropdown),{key:1,optionPosition:"bottom",optionWrapClass:"th-filter-dropdown",modelValue:y.value,"onUpdate:modelValue":K[3]||(K[3]=N=>y.value=N)},{dropdown:n.withCtx(()=>[l.value.length?(n.openBlock(),n.createBlock(n.unref(O.OScroller),{key:0,"disabled-x":"",style:{"max-height":"300px"},"show-type":"always"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.ODropdownItem),{style:n.normalizeStyle({"--table-width":s.tableWidth}),class:n.normalizeClass([{"is-active":s.modelValue===""}]),value:"''",label:n.unref(i)("common.all"),onClick:K[2]||(K[2]=N=>E(""))},null,8,["style","class","label"]),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(l.value,N=>(n.openBlock(),n.createBlock(n.unref(O.ODropdownItem),{style:n.normalizeStyle({"--table-width":s.tableWidth}),class:n.normalizeClass([{"is-active":N.value===s.modelValue}]),key:N.value,value:N.value,onClick:J=>E(N.value)},{default:n.withCtx(()=>[n.withDirectives(n.createElementVNode("span",null,null,512),[[M,N.label]])]),_:2},1032,["style","class","value","onClick"]))),128))]),_:1})):n.createCommentVNode("",!0),l.value.length?n.createCommentVNode("",!0):n.renderSlot(I.$slots,"empty",{key:1})]),default:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(["filter-wrapper",T.value&&"has-checked"])},[n.createVNode(n.unref(O.OIcon),{class:"filter-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(oc))]),_:1})],2)]),_:3},8,["modelValue"]))],512)}}}),Oy={class:"o-activity-table"},By={key:0,class:"table-wrapper"},Ly={class:"expand-detail"},Py={class:"sort-btn"},My={class:"activity-btn"},Ry={key:0,class:"pagination-wrapper"},Vy={key:1,class:"collapse-wrapper"},Fy={class:"title-top"},$y={class:"act-title"},Uy={class:"act-sponsor"},qy={class:"sponsor"},jy={class:"activity-btn"},Hy={class:"activity-detail"},zy={key:0,class:"pagination"},Gy={class:"dialog-content"},Wy={class:"dialog-footer"},Yy={class:"dialog-content"},Xy={class:"dialog-footer"},Ky=n.defineComponent({__name:"OActivityApproval",props:{getTableDataRequest:{},applicantList:{},cancelActivityRequest:{},deleteActivityRequest:{},approveActivityRequest:{},rejectActivityRequest:{},getActivityDetailRequest:{}},setup(s){const e=O.useMessage(null),{isPhone:i,lePadV:r}=wt.useScreen(),a=s,o=n.reactive({page:1,size:10,status:"",is_delete:0,search:"",sponsor:"",order_by:""}),l=n.ref(""),u=n.ref([]),d=()=>{o.sponsor=l.value.join(",")},f=n.ref("desc"),g=()=>{f.value=f.value==="asc"?"desc":"asc",o.order_by=f.value},y=n.ref(),E=n.ref([]);dy.forEach(Se=>{E.value.push(Se)});const x=()=>{o.status=y.value,y.value==="cancel"?o.is_delete=1:o.is_delete=0},B=n.ref([]),T=n.ref(0),w=[10,20,30,40],F=async()=>{const{page:Se,size:me,status:ke,sponsor:Ve,order_by:be,search:Le,is_delete:ht}=o;let Ze={page:Se,size:me,sponsor:Ve,order_by:be,search:Le};if(ke==="cancel"?(Ze.is_delete=ht,Ze.status=""):Ze.status=ke,!a.getTableDataRequest)return;const at=await a.getTableDataRequest(Ze);B.value=(at.data||[]).map(Pe=>{const{start_date:Fe,end_date:ot,start:Ct,end:fe}=Pe;return[{...Pe,time:`${Fe}-${fe}`,start_date_time:`${Fe} ${Ct}`,end_date_time:`${ot} ${fe}`,type:"activity",dateRange:`${Fe} ${Ct}-${ot} ${fe}`}]}).flat(),T.value=at.total},P=Se=>{Se.pageSize!==o.size?o.page=1:o.page=Se.page,o.size=Se.pageSize,F()},I=n.ref({reason:""}),K=n.ref(),q=n.ref(!1),M=n.ref(null),N=n.ref(""),J=n.ref(0),b=n.ref(!1),C=n.ref({reason:[{required:!0,message:"请输入审核的备注信息"}]}),U=async()=>{var me,ke,Ve;if(!a.approveActivityRequest||!a.rejectActivityRequest)return;const Se=J.value===1?"审核通过":"审核驳回";try{if(q.value=!0,(await((me=K.value)==null?void 0:me.validate())).some(Le=>!!Le)){q.value=!1;return}J.value===1?await a.approveActivityRequest(M.value.id,I.value):await a.rejectActivityRequest(M.value.id,I.value),F(),j(),e.success({content:`“${(ke=M.value)==null?void 0:ke.title}”活动${Se}成功`})}catch{b.value=!1,q.value=!1,e.danger({content:`“${(Ve=M.value)==null?void 0:Ve.title}”活动${Se}失败`})}},j=()=>{b.value=!1,A.value=!1,q.value=!1,I.value.reason=""},k=async()=>{var Se,me;if(!a.deleteActivityRequest||!a.cancelActivityRequest)try{q.value=!0,H.value===1?await a.cancelActivityRequest(M.value.id,I.value):await a.deleteActivityRequest(M.value.id,I.value),F(),j(),e.success({content:`“${(Se=M.value)==null?void 0:Se.title}”活动${Q.value}成功`})}catch{q.value=!1,A.value=!1,e.danger({content:`“${(me=M.value)==null?void 0:me.title}”活动${Q.value}失败`})}},A=n.ref(!1),$=n.ref(""),Q=n.ref(""),H=n.ref(0),V=Se=>{$.value="删除活动",Q.value="删除",M.value=Se,H.value=0,A.value=!0},G=Se=>{$.value="取消活动",Q.value="取消",M.value=Se,H.value=1,A.value=!0},Z=Se=>{M.value=Se,N.value="审核通过",J.value=1,b.value=!0},te=Se=>{M.value=Se,N.value="审核驳回",J.value=0,b.value=!0},se=n.ref([]),ue=n.ref([]),ce=Se=>{if(!a.getActivityDetailRequest)return;se.value.includes(Se)||(se.value.push(Se),a.getActivityDetailRequest(Se).then(ke=>{var Ve;(Ve=B.value)==null||Ve.forEach(be=>{be.id===ke.id&&(be.approve_record=ke.approve_record,be.approver=ke.approver)})}));const me=ue.value.indexOf(Se);ue.value.includes(Se)?ue.value.splice(me,1):ue.value.push(Se)},de=Se=>{ce(Se.id)},qe=Se=>Se.id,De=n.ref([]),Oe=Se=>{Se.length&&Se.forEach(me=>{ce(me)})},We=n.ref({}),Me=(Se,me)=>{Se&&me&&(We.value[me]=Se)};return n.onMounted(()=>{F()}),n.watch(()=>[o.status,o.sponsor,o.order_by,o.search,o.is_delete],()=>{F()},{deep:!0}),(Se,me)=>{const ke=n.resolveComponent("MeetingDetail"),Ve=n.resolveComponent("OCollapseItem");return n.openBlock(),n.createElementBlock("div",Oy,[n.unref(i)?(n.openBlock(),n.createElementBlock("div",Vy,[n.createVNode(n.unref(O.OCollapse),{modelValue:De.value,"onUpdate:modelValue":me[2]||(me[2]=be=>De.value=be),accordion:n.unref(i),onChange:Oe},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(B.value,(be,Le)=>{var ht;return n.openBlock(),n.createElementBlock(n.Fragment,{key:be.id},[n.createElementVNode("div",Fy,[n.createElementVNode("p",$y,n.toDisplayString(be.title),1),be.is_delete!==1?(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:0,color:"primary",variant:"outline",class:n.normalizeClass([`tag-${(ht=n.unref(Ps).get(be.status))==null?void 0:ht.id}`])},{default:n.withCtx(()=>{var Ze;return[n.createTextVNode(n.toDisplayString((Ze=n.unref(Ps).get(be.status))==null?void 0:Ze.text),1)]}),_:2},1032,["class"])):(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:1,color:"primary",variant:"outline",class:"tag-calcel"},{default:n.withCtx(()=>[...me[14]||(me[14]=[n.createTextVNode("已取消",-1)])]),_:1}))]),n.createVNode(Ve,{value:be.id},{title:n.withCtx(()=>[n.createElementVNode("div",Uy,[n.createElementVNode("p",qy,n.toDisplayString(be.sponsor),1),n.createElementVNode("p",null,n.toDisplayString(n.unref(et.dayjs)(be.create_time).format("YYYY/MM/DD HH:mm:ss")),1)]),n.createElementVNode("div",jy,[be.status===7||be.is_delete?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:0,color:"danger",variant:"text",onClick:n.withModifiers(Ze=>V(be),["stop"])},{default:n.withCtx(()=>[...me[15]||(me[15]=[n.createTextVNode(" 删除 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0),(be.status===3||be.status===4)&&be.is_delete!==1?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:1,color:"danger",variant:"text",onClick:n.withModifiers(Ze=>G(be),["stop"])},{default:n.withCtx(()=>[...me[16]||(me[16]=[n.createTextVNode(" 取消活动 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0),be.status===2?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:2,color:"primary",variant:"text",onClick:n.withModifiers(Ze=>Z(be),["stop"])},{default:n.withCtx(()=>[...me[17]||(me[17]=[n.createTextVNode(" 通过 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0),be.status===2?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:3,color:"primary",variant:"text",onClick:n.withModifiers(Ze=>te(be),["stop"])},{default:n.withCtx(()=>[...me[18]||(me[18]=[n.createTextVNode(" 驳回 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0)])]),default:n.withCtx(()=>[n.createElementVNode("div",Hy,[n.createVNode(ke,{show:De.value.includes(be.id),data:be,ref_for:!0,ref:Ze=>Me(Ze,be.id),page:"approval"},null,8,["show","data"])])]),_:2},1032,["value"])],64)}),128))]),_:1},8,["modelValue","accordion"]),T.value>w[0]?(n.openBlock(),n.createElementBlock("div",zy,[n.createVNode(n.unref(O.OPagination),{total:T.value,page:o.page,"page-size":o.size,"page-sizes":w,layout:["total","jumper","pager","pagesize"],"show-more":!1,simple:!0,onChange:P},null,8,["total","page","page-size"])])):n.createCommentVNode("",!0)])):(n.openBlock(),n.createElementBlock("div",By,[n.createVNode(n.unref(et.ElTable),{data:B.value,onExpandChange:de,"row-key":qe,"expand-row-keys":ue.value},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElTableColumn),{type:"expand"},{default:n.withCtx(be=>[n.createElementVNode("div",Ly,[n.createVNode(ke,{data:be.row,page:"approval"},null,8,["data"])])]),_:1}),n.createVNode(n.unref(et.ElTableColumn),{label:"活动名称",prop:"title"}),n.createVNode(n.unref(et.ElTableColumn),{prop:"sponsor"},{header:n.withCtx(()=>[n.createVNode(lc,{modelValue:l.value,"onUpdate:modelValue":me[0]||(me[0]=be=>l.value=be),onConfirm:d,list:u.value,multiple:!0},{empty:n.withCtx(()=>[n.renderSlot(Se.$slots,"filter-empty",{},void 0,!0)]),default:n.withCtx(()=>[me[6]||(me[6]=n.createTextVNode(" 申请人 ",-1))]),_:3},8,["modelValue","list"])]),_:3}),n.createVNode(n.unref(et.ElTableColumn),{prop:"create_time"},{header:n.withCtx(()=>[n.createElementVNode("div",{class:"sort-time",onClick:g},[me[7]||(me[7]=n.createElementVNode("span",null,"申请时间",-1)),n.createElementVNode("div",Py,[n.createElementVNode("div",{class:n.normalizeClass(["sort-asc sort-item",{active:f.value==="asc"}])},null,2),n.createElementVNode("div",{class:n.normalizeClass(["sort-desc sort-item",{active:f.value==="desc"}])},null,2)])])]),default:n.withCtx(be=>[n.createTextVNode(n.toDisplayString(n.unref(et.dayjs)(be.row.create_time).format("YYYY/MM/DD HH:mm:ss")),1)]),_:1}),n.createVNode(n.unref(et.ElTableColumn),{prop:"status",width:"90px"},{header:n.withCtx(()=>[n.createVNode(lc,{modelValue:y.value,"onUpdate:modelValue":me[1]||(me[1]=be=>y.value=be),onConfirm:x,list:E.value},{empty:n.withCtx(()=>[n.renderSlot(Se.$slots,"filter-empty",{},void 0,!0)]),default:n.withCtx(()=>[me[8]||(me[8]=n.createTextVNode(" 状态 ",-1))]),_:3},8,["modelValue","list"])]),default:n.withCtx(be=>{var Le;return[be.row.is_delete!==1?(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:0,color:"primary",variant:"outline",class:n.normalizeClass([`tag-${(Le=n.unref(Ps).get(be.row.status))==null?void 0:Le.id}`])},{default:n.withCtx(()=>{var ht;return[n.createTextVNode(n.toDisplayString((ht=n.unref(Ps).get(be.row.status))==null?void 0:ht.text),1)]}),_:2},1032,["class"])):(n.openBlock(),n.createBlock(n.unref(O.OTag),{key:1,color:"primary",variant:"outline",class:"tag-calcel"},{default:n.withCtx(()=>[...me[9]||(me[9]=[n.createTextVNode("已取消",-1)])]),_:1}))]}),_:3}),n.createVNode(n.unref(et.ElTableColumn),{label:"操作"},{default:n.withCtx(be=>[n.createElementVNode("div",My,[be.row.status===7||be.row.is_delete?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:0,color:"danger",onClick:Le=>V(be.row)},{default:n.withCtx(()=>[...me[10]||(me[10]=[n.createTextVNode(" 删除 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0),(be.row.status===3||be.row.status===4)&&be.row.is_delete!==1?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:1,color:"danger",onClick:Le=>G(be.row)},{default:n.withCtx(()=>[...me[11]||(me[11]=[n.createTextVNode(" 取消活动 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0),be.row.status===2?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:2,color:"primary",onClick:Le=>Z(be.row)},{default:n.withCtx(()=>[...me[12]||(me[12]=[n.createTextVNode(" 通过 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0),be.row.status===2?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:3,color:"primary",onClick:Le=>te(be.row)},{default:n.withCtx(()=>[...me[13]||(me[13]=[n.createTextVNode(" 驳回 ",-1)])]),_:1},8,["onClick"])):n.createCommentVNode("",!0)])]),_:1})]),_:3},8,["data","expand-row-keys"]),T.value>w[0]?(n.openBlock(),n.createElementBlock("div",Ry,[n.createVNode(n.unref(O.OPagination),{total:T.value,page:o.page,"page-size":o.size,"page-sizes":w,layout:["total","jumper","pager","pagesize"],"show-more":!1,onChange:P},null,8,["total","page","page-size"])])):n.createCommentVNode("",!0)])),n.createVNode(n.unref(O.ODialog),{visible:b.value,"onUpdate:visible":me[4]||(me[4]=be=>b.value=be),"phone-half-full":n.unref(r),"main-class":"handle-dialog-approval review-dialog"},{header:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(N.value),1)]),footer:n.withCtx(()=>[n.createElementVNode("div",Wy,[n.createVNode(n.unref(O.OButton),{color:"primary",variant:n.unref(r)?"text":"solid",size:"large",onClick:U,loading:q.value},{default:n.withCtx(()=>[...me[19]||(me[19]=[n.createTextVNode("确定 ",-1)])]),_:1},8,["variant","loading"]),n.unref(r)?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:0,direction:"v"})):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OButton),{color:"primary",variant:n.unref(r)?"text":"outline",size:"large",onClick:j},{default:n.withCtx(()=>[...me[20]||(me[20]=[n.createTextVNode("取消",-1)])]),_:1},8,["variant"])])]),default:n.withCtx(()=>[n.createElementVNode("div",Gy,[n.createVNode(n.unref(O.OForm),{model:I.value,ref_key:"formRef",ref:K,"has-required":"",layout:"v",class:"form-wrapper"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OFormItem),{rules:C.value.reason,label:"审核备注:",field:"reason"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OTextarea),{size:"large",placeholder:"请输入审核的备注信息",style:{width:"100%"},rows:4,resize:"none","max-length":1e3,"input-on-outlimit":!1,modelValue:I.value.reason,"onUpdate:modelValue":me[3]||(me[3]=be=>I.value.reason=be)},null,8,["modelValue"])]),_:1},8,["rules"])]),_:1},8,["model"])])]),_:1},8,["visible","phone-half-full"]),n.createVNode(n.unref(O.ODialog),{visible:A.value,"onUpdate:visible":me[5]||(me[5]=be=>A.value=be),"phone-half-full":n.unref(r),"main-class":"handle-dialog-approval"},{header:n.withCtx(()=>[n.createTextVNode(n.toDisplayString($.value),1)]),footer:n.withCtx(()=>[n.createElementVNode("div",Xy,[n.createVNode(n.unref(O.OButton),{color:"primary",variant:n.unref(r)?"text":"outline",size:"large",onClick:k,loading:q.value},{default:n.withCtx(()=>[...me[21]||(me[21]=[n.createTextVNode("确定 ",-1)])]),_:1},8,["variant","loading"]),n.unref(r)?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:0,direction:"v"})):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OButton),{color:"primary",variant:n.unref(r)?"text":"solid",size:"large",onClick:j},{default:n.withCtx(()=>[...me[22]||(me[22]=[n.createTextVNode("取消",-1)])]),_:1},8,["variant"])])]),default:n.withCtx(()=>[n.createElementVNode("div",Yy,"是否确认"+n.toDisplayString(Q.value)+"“"+n.toDisplayString(M.value.title)+"”活动?取消后将不在会议首页呈现,且已报名的数据也会被清空,请谨慎操作。 ",1)]),_:1},8,["visible","phone-half-full"])])}}}),uc=Ue._export_sfc(Ky,[["__scopeId","data-v-a5030c38"]]),Qy={},Zy={class:"o-my-activity-calendar"};function Jy(s,e){return n.openBlock(),n.createElementBlock("div",Zy)}const cc=Ue._export_sfc(Qy,[["render",Jy]]),ev=Object.assign(ac,{install(s){s.component("OActivityForm",ac)}}),tv=Object.assign(uc,{install(s){s.component("OActivityApproval",uc)}}),iv=Object.assign(cc,{install(s){s.component("OMyActivityCalendar",cc)}});/*! @license DOMPurify 2.5.9 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.5.9/LICENSE */function pn(s){"@babel/helpers - typeof";return pn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},pn(s)}function Ko(s,e){return Ko=Object.setPrototypeOf||function(r,a){return r.__proto__=a,r},Ko(s,e)}function nv(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Xs(s,e,i){return nv()?Xs=Reflect.construct:Xs=function(a,o,l){var u=[null];u.push.apply(u,o);var d=Function.bind.apply(a,u),f=new d;return l&&Ko(f,l.prototype),f},Xs.apply(null,arguments)}function Ni(s){return rv(s)||sv(s)||av(s)||ov()}function rv(s){if(Array.isArray(s))return Qo(s)}function sv(s){if(typeof Symbol<"u"&&s[Symbol.iterator]!=null||s["@@iterator"]!=null)return Array.from(s)}function av(s,e){if(s){if(typeof s=="string")return Qo(s,e);var i=Object.prototype.toString.call(s).slice(8,-1);if(i==="Object"&&s.constructor&&(i=s.constructor.name),i==="Map"||i==="Set")return Array.from(s);if(i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return Qo(s,e)}}function Qo(s,e){(e==null||e>s.length)&&(e=s.length);for(var i=0,r=new Array(e);i<e;i++)r[i]=s[i];return r}function ov(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
2
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var lv=Object.hasOwnProperty,dc=Object.setPrototypeOf,uv=Object.isFrozen,cv=Object.getPrototypeOf,dv=Object.getOwnPropertyDescriptor,Jt=Object.freeze,_i=Object.seal,hv=Object.create,xh=typeof Reflect<"u"&&Reflect,ia=xh.apply,Zo=xh.construct;ia||(ia=function(e,i,r){return e.apply(i,r)});Jt||(Jt=function(e){return e});_i||(_i=function(e){return e});Zo||(Zo=function(e,i){return Xs(e,Ni(i))});var fv=yi(Array.prototype.forEach),hc=yi(Array.prototype.pop),$r=yi(Array.prototype.push),Ks=yi(String.prototype.toLowerCase),lo=yi(String.prototype.toString),fc=yi(String.prototype.match),Ii=yi(String.prototype.replace),pv=yi(String.prototype.indexOf),mv=yi(String.prototype.trim),Bt=yi(RegExp.prototype.test),uo=gv(TypeError);function yi(s){return function(e){for(var i=arguments.length,r=new Array(i>1?i-1:0),a=1;a<i;a++)r[a-1]=arguments[a];return ia(s,e,r)}}function gv(s){return function(){for(var e=arguments.length,i=new Array(e),r=0;r<e;r++)i[r]=arguments[r];return Zo(s,i)}}function ze(s,e,i){var r;i=(r=i)!==null&&r!==void 0?r:Ks,dc&&dc(s,null);for(var a=e.length;a--;){var o=e[a];if(typeof o=="string"){var l=i(o);l!==o&&(uv(e)||(e[a]=l),o=l)}s[o]=!0}return s}function Cn(s){var e=hv(null),i;for(i in s)ia(lv,s,[i])===!0&&(e[i]=s[i]);return e}function Ms(s,e){for(;s!==null;){var i=dv(s,e);if(i){if(i.get)return yi(i.get);if(typeof i.value=="function")return yi(i.value)}s=cv(s)}function r(a){return console.warn("fallback value for",a),null}return r}var pc=Jt(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),co=Jt(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),ho=Jt(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),_v=Jt(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),fo=Jt(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),yv=Jt(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),mc=Jt(["#text"]),gc=Jt(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),po=Jt(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),_c=Jt(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Rs=Jt(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),vv=_i(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Tv=_i(/<%[\w\W]*|[\w\W]*%>/gm),bv=_i(/\${[\w\W]*}/gm),xv=_i(/^data-[\-\w.\u00B7-\uFFFF]+$/),Cv=_i(/^aria-[\-\w]+$/),Sv=_i(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Ev=_i(/^(?:\w+script|data):/i),kv=_i(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),wv=_i(/^html$/i),Dv=_i(/^[a-z][.\w]*(-[.\w]+)+$/i),Av=function(){return typeof window>"u"?null:window},Iv=function(e,i){if(pn(e)!=="object"||typeof e.createPolicy!="function")return null;var r=null,a="data-tt-policy-suffix";i.currentScript&&i.currentScript.hasAttribute(a)&&(r=i.currentScript.getAttribute(a));var o="dompurify"+(r?"#"+r:"");try{return e.createPolicy(o,{createHTML:function(u){return u},createScriptURL:function(u){return u}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}};function Ch(){var s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Av(),e=function(ee){return Ch(ee)};if(e.version="2.5.9",e.removed=[],!s||!s.document||s.document.nodeType!==9)return e.isSupported=!1,e;var i=s.document,r=s.document,a=s.DocumentFragment,o=s.HTMLTemplateElement,l=s.Node,u=s.Element,d=s.NodeFilter,f=s.NamedNodeMap,g=f===void 0?s.NamedNodeMap||s.MozNamedAttrMap:f,y=s.HTMLFormElement,E=s.DOMParser,x=s.trustedTypes,B=u.prototype,T=Ms(B,"cloneNode"),w=Ms(B,"nextSibling"),F=Ms(B,"childNodes"),P=Ms(B,"parentNode");if(typeof o=="function"){var I=r.createElement("template");I.content&&I.content.ownerDocument&&(r=I.content.ownerDocument)}var K=Iv(x,i),q=K?K.createHTML(""):"",M=r,N=M.implementation,J=M.createNodeIterator,b=M.createDocumentFragment,C=M.getElementsByTagName,U=i.importNode,j={};try{j=Cn(r).documentMode?r.documentMode:{}}catch{}var k={};e.isSupported=typeof P=="function"&&N&&N.createHTMLDocument!==void 0&&j!==9;var A=vv,$=Tv,Q=bv,H=xv,V=Cv,G=Ev,Z=kv,te=Dv,se=Sv,ue=null,ce=ze({},[].concat(Ni(pc),Ni(co),Ni(ho),Ni(fo),Ni(mc))),de=null,qe=ze({},[].concat(Ni(gc),Ni(po),Ni(_c),Ni(Rs))),De=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Oe=null,We=null,Me=!0,Se=!0,me=!1,ke=!0,Ve=!1,be=!0,Le=!1,ht=!1,Ze=!1,at=!1,Pe=!1,Fe=!1,ot=!0,Ct=!1,fe="user-content-",ye=!0,_e=!1,je={},we=null,_t=ze({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Mt=null,Pi=ze({},["audio","video","img","source","image","track"]),Ye=null,xi=ze({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),jt="http://www.w3.org/1998/Math/MathML",Ci="http://www.w3.org/2000/svg",yt="http://www.w3.org/1999/xhtml",ei=yt,li=!1,Ht=null,Yi=ze({},[jt,Ci,yt],lo),Rt,Si=["application/xhtml+xml","text/html"],S="text/html",D,X=null,re=r.createElement("form"),ge=function(ee){return ee instanceof RegExp||ee instanceof Function},Ie=function(ee){X&&X===ee||((!ee||pn(ee)!=="object")&&(ee={}),ee=Cn(ee),Rt=Si.indexOf(ee.PARSER_MEDIA_TYPE)===-1?Rt=S:Rt=ee.PARSER_MEDIA_TYPE,D=Rt==="application/xhtml+xml"?lo:Ks,ue="ALLOWED_TAGS"in ee?ze({},ee.ALLOWED_TAGS,D):ce,de="ALLOWED_ATTR"in ee?ze({},ee.ALLOWED_ATTR,D):qe,Ht="ALLOWED_NAMESPACES"in ee?ze({},ee.ALLOWED_NAMESPACES,lo):Yi,Ye="ADD_URI_SAFE_ATTR"in ee?ze(Cn(xi),ee.ADD_URI_SAFE_ATTR,D):xi,Mt="ADD_DATA_URI_TAGS"in ee?ze(Cn(Pi),ee.ADD_DATA_URI_TAGS,D):Pi,we="FORBID_CONTENTS"in ee?ze({},ee.FORBID_CONTENTS,D):_t,Oe="FORBID_TAGS"in ee?ze({},ee.FORBID_TAGS,D):{},We="FORBID_ATTR"in ee?ze({},ee.FORBID_ATTR,D):{},je="USE_PROFILES"in ee?ee.USE_PROFILES:!1,Me=ee.ALLOW_ARIA_ATTR!==!1,Se=ee.ALLOW_DATA_ATTR!==!1,me=ee.ALLOW_UNKNOWN_PROTOCOLS||!1,ke=ee.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Ve=ee.SAFE_FOR_TEMPLATES||!1,be=ee.SAFE_FOR_XML!==!1,Le=ee.WHOLE_DOCUMENT||!1,at=ee.RETURN_DOM||!1,Pe=ee.RETURN_DOM_FRAGMENT||!1,Fe=ee.RETURN_TRUSTED_TYPE||!1,Ze=ee.FORCE_BODY||!1,ot=ee.SANITIZE_DOM!==!1,Ct=ee.SANITIZE_NAMED_PROPS||!1,ye=ee.KEEP_CONTENT!==!1,_e=ee.IN_PLACE||!1,se=ee.ALLOWED_URI_REGEXP||se,ei=ee.NAMESPACE||yt,De=ee.CUSTOM_ELEMENT_HANDLING||{},ee.CUSTOM_ELEMENT_HANDLING&&ge(ee.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(De.tagNameCheck=ee.CUSTOM_ELEMENT_HANDLING.tagNameCheck),ee.CUSTOM_ELEMENT_HANDLING&&ge(ee.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(De.attributeNameCheck=ee.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),ee.CUSTOM_ELEMENT_HANDLING&&typeof ee.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(De.allowCustomizedBuiltInElements=ee.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Ve&&(Se=!1),Pe&&(at=!0),je&&(ue=ze({},Ni(mc)),de=[],je.html===!0&&(ze(ue,pc),ze(de,gc)),je.svg===!0&&(ze(ue,co),ze(de,po),ze(de,Rs)),je.svgFilters===!0&&(ze(ue,ho),ze(de,po),ze(de,Rs)),je.mathMl===!0&&(ze(ue,fo),ze(de,_c),ze(de,Rs))),ee.ADD_TAGS&&(ue===ce&&(ue=Cn(ue)),ze(ue,ee.ADD_TAGS,D)),ee.ADD_ATTR&&(de===qe&&(de=Cn(de)),ze(de,ee.ADD_ATTR,D)),ee.ADD_URI_SAFE_ATTR&&ze(Ye,ee.ADD_URI_SAFE_ATTR,D),ee.FORBID_CONTENTS&&(we===_t&&(we=Cn(we)),ze(we,ee.FORBID_CONTENTS,D)),ye&&(ue["#text"]=!0),Le&&ze(ue,["html","head","body"]),ue.table&&(ze(ue,["tbody"]),delete Oe.tbody),Jt&&Jt(ee),X=ee)},Je=ze({},["mi","mo","mn","ms","mtext"]),St=ze({},["annotation-xml"]),zt=ze({},["title","style","font","a","script"]),Vt=ze({},co);ze(Vt,ho),ze(Vt,_v);var Ot=ze({},fo);ze(Ot,yv);var ti=function(ee){var he=P(ee);(!he||!he.tagName)&&(he={namespaceURI:ei,tagName:"template"});var xe=Ks(ee.tagName),Qe=Ks(he.tagName);return Ht[ee.namespaceURI]?ee.namespaceURI===Ci?he.namespaceURI===yt?xe==="svg":he.namespaceURI===jt?xe==="svg"&&(Qe==="annotation-xml"||Je[Qe]):!!Vt[xe]:ee.namespaceURI===jt?he.namespaceURI===yt?xe==="math":he.namespaceURI===Ci?xe==="math"&&St[Qe]:!!Ot[xe]:ee.namespaceURI===yt?he.namespaceURI===Ci&&!St[Qe]||he.namespaceURI===jt&&!Je[Qe]?!1:!Ot[xe]&&(zt[xe]||!Vt[xe]):!!(Rt==="application/xhtml+xml"&&Ht[ee.namespaceURI]):!1},Xe=function(ee){$r(e.removed,{element:ee});try{ee.parentNode.removeChild(ee)}catch{try{ee.outerHTML=q}catch{ee.remove()}}},ii=function(ee,he){try{$r(e.removed,{attribute:he.getAttributeNode(ee),from:he})}catch{$r(e.removed,{attribute:null,from:he})}if(he.removeAttribute(ee),ee==="is"&&!de[ee])if(at||Pe)try{Xe(he)}catch{}else try{he.setAttribute(ee,"")}catch{}},Gt=function(ee){var he,xe;if(Ze)ee="<remove></remove>"+ee;else{var Qe=fc(ee,/^[\r\n\t ]+/);xe=Qe&&Qe[0]}Rt==="application/xhtml+xml"&&ei===yt&&(ee='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+ee+"</body></html>");var Ft=K?K.createHTML(ee):ee;if(ei===yt)try{he=new E().parseFromString(Ft,Rt)}catch{}if(!he||!he.documentElement){he=N.createDocument(ei,"template",null);try{he.documentElement.innerHTML=li?q:Ft}catch{}}var kt=he.body||he.documentElement;return ee&&xe&&kt.insertBefore(r.createTextNode(xe),kt.childNodes[0]||null),ei===yt?C.call(he,Le?"html":"body")[0]:Le?he.documentElement:kt},Wt=function(ee){return J.call(ee.ownerDocument||ee,ee,d.SHOW_ELEMENT|d.SHOW_COMMENT|d.SHOW_TEXT|d.SHOW_PROCESSING_INSTRUCTION|d.SHOW_CDATA_SECTION,null,!1)},Et=function(ee){return ee instanceof y&&(typeof ee.nodeName!="string"||typeof ee.textContent!="string"||typeof ee.removeChild!="function"||!(ee.attributes instanceof g)||typeof ee.removeAttribute!="function"||typeof ee.setAttribute!="function"||typeof ee.namespaceURI!="string"||typeof ee.insertBefore!="function"||typeof ee.hasChildNodes!="function")},st=function(ee){return pn(l)==="object"?ee instanceof l:ee&&pn(ee)==="object"&&typeof ee.nodeType=="number"&&typeof ee.nodeName=="string"},He=function(ee,he,xe){k[ee]&&fv(k[ee],function(Qe){Qe.call(e,he,xe,X)})},Ei=function(ee){var he;if(He("beforeSanitizeElements",ee,null),Et(ee)||Bt(/[\u0080-\uFFFF]/,ee.nodeName))return Xe(ee),!0;var xe=D(ee.nodeName);if(He("uponSanitizeElement",ee,{tagName:xe,allowedTags:ue}),ee.hasChildNodes()&&!st(ee.firstElementChild)&&(!st(ee.content)||!st(ee.content.firstElementChild))&&Bt(/<[/\w]/g,ee.innerHTML)&&Bt(/<[/\w]/g,ee.textContent)||xe==="select"&&Bt(/<template/i,ee.innerHTML)||ee.nodeType===7||be&&ee.nodeType===8&&Bt(/<[/\w]/g,ee.data))return Xe(ee),!0;if(!ue[xe]||Oe[xe]){if(!Oe[xe]&&Tn(xe)&&(De.tagNameCheck instanceof RegExp&&Bt(De.tagNameCheck,xe)||De.tagNameCheck instanceof Function&&De.tagNameCheck(xe)))return!1;if(ye&&!we[xe]){var Qe=P(ee)||ee.parentNode,Ft=F(ee)||ee.childNodes;if(Ft&&Qe)for(var kt=Ft.length,vt=kt-1;vt>=0;--vt){var ki=T(Ft[vt],!0);ki.__removalCount=(ee.__removalCount||0)+1,Qe.insertBefore(ki,w(ee))}}return Xe(ee),!0}return ee instanceof u&&!ti(ee)||(xe==="noscript"||xe==="noembed"||xe==="noframes")&&Bt(/<\/no(script|embed|frames)/i,ee.innerHTML)?(Xe(ee),!0):(Ve&&ee.nodeType===3&&(he=ee.textContent,he=Ii(he,A," "),he=Ii(he,$," "),he=Ii(he,Q," "),ee.textContent!==he&&($r(e.removed,{element:ee.cloneNode()}),ee.textContent=he)),He("afterSanitizeElements",ee,null),!1)},Mi=function(ee,he,xe){if(ot&&(he==="id"||he==="name")&&(xe in r||xe in re))return!1;if(!(Se&&!We[he]&&Bt(H,he))){if(!(Me&&Bt(V,he))){if(!de[he]||We[he]){if(!(Tn(ee)&&(De.tagNameCheck instanceof RegExp&&Bt(De.tagNameCheck,ee)||De.tagNameCheck instanceof Function&&De.tagNameCheck(ee))&&(De.attributeNameCheck instanceof RegExp&&Bt(De.attributeNameCheck,he)||De.attributeNameCheck instanceof Function&&De.attributeNameCheck(he))||he==="is"&&De.allowCustomizedBuiltInElements&&(De.tagNameCheck instanceof RegExp&&Bt(De.tagNameCheck,xe)||De.tagNameCheck instanceof Function&&De.tagNameCheck(xe))))return!1}else if(!Ye[he]){if(!Bt(se,Ii(xe,Z,""))){if(!((he==="src"||he==="xlink:href"||he==="href")&&ee!=="script"&&pv(xe,"data:")===0&&Mt[ee])){if(!(me&&!Bt(G,Ii(xe,Z,"")))){if(xe)return!1}}}}}}return!0},Tn=function(ee){return ee!=="annotation-xml"&&fc(ee,te)},fs=function(ee){var he,xe,Qe,Ft;He("beforeSanitizeAttributes",ee,null);var kt=ee.attributes;if(!(!kt||Et(ee))){var vt={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:de};for(Ft=kt.length;Ft--;){he=kt[Ft];var ki=he,mt=ki.name,xr=ki.namespaceURI;if(xe=mt==="value"?he.value:mv(he.value),Qe=D(mt),vt.attrName=Qe,vt.attrValue=xe,vt.keepAttr=!0,vt.forceKeepAttr=void 0,He("uponSanitizeAttribute",ee,vt),xe=vt.attrValue,!vt.forceKeepAttr&&(ii(mt,ee),!!vt.keepAttr)){if(!ke&&Bt(/\/>/i,xe)){ii(mt,ee);continue}Ve&&(xe=Ii(xe,A," "),xe=Ii(xe,$," "),xe=Ii(xe,Q," "));var ps=D(ee.nodeName);if(Mi(ps,Qe,xe)){if(Ct&&(Qe==="id"||Qe==="name")&&(ii(mt,ee),xe=fe+xe),be&&Bt(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,xe)){ii(mt,ee);continue}if(K&&pn(x)==="object"&&typeof x.getAttributeType=="function"&&!xr)switch(x.getAttributeType(ps,Qe)){case"TrustedHTML":{xe=K.createHTML(xe);break}case"TrustedScriptURL":{xe=K.createScriptURL(xe);break}}try{xr?ee.setAttributeNS(xr,mt,xe):ee.setAttribute(mt,xe),Et(ee)?Xe(ee):hc(e.removed)}catch{}}}}He("afterSanitizeAttributes",ee,null)}},Xi=function ve(ee){var he,xe=Wt(ee);for(He("beforeSanitizeShadowDOM",ee,null);he=xe.nextNode();)He("uponSanitizeShadowNode",he,null),Ei(he),fs(he),he.content instanceof a&&ve(he.content);He("afterSanitizeShadowDOM",ee,null)};return e.sanitize=function(ve){var ee=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},he,xe,Qe,Ft,kt;if(li=!ve,li&&(ve="<!-->"),typeof ve!="string"&&!st(ve))if(typeof ve.toString=="function"){if(ve=ve.toString(),typeof ve!="string")throw uo("dirty is not a string, aborting")}else throw uo("toString is not a function");if(!e.isSupported){if(pn(s.toStaticHTML)==="object"||typeof s.toStaticHTML=="function"){if(typeof ve=="string")return s.toStaticHTML(ve);if(st(ve))return s.toStaticHTML(ve.outerHTML)}return ve}if(ht||Ie(ee),e.removed=[],typeof ve=="string"&&(_e=!1),_e){if(ve.nodeName){var vt=D(ve.nodeName);if(!ue[vt]||Oe[vt])throw uo("root node is forbidden and cannot be sanitized in-place")}}else if(ve instanceof l)he=Gt("<!---->"),xe=he.ownerDocument.importNode(ve,!0),xe.nodeType===1&&xe.nodeName==="BODY"||xe.nodeName==="HTML"?he=xe:he.appendChild(xe);else{if(!at&&!Ve&&!Le&&ve.indexOf("<")===-1)return K&&Fe?K.createHTML(ve):ve;if(he=Gt(ve),!he)return at?null:Fe?q:""}he&&Ze&&Xe(he.firstChild);for(var ki=Wt(_e?ve:he);Qe=ki.nextNode();)Qe.nodeType===3&&Qe===Ft||(Ei(Qe),fs(Qe),Qe.content instanceof a&&Xi(Qe.content),Ft=Qe);if(Ft=null,_e)return ve;if(at){if(Pe)for(kt=b.call(he.ownerDocument);he.firstChild;)kt.appendChild(he.firstChild);else kt=he;return(de.shadowroot||de.shadowrootmod)&&(kt=U.call(i,kt,!0)),kt}var mt=Le?he.outerHTML:he.innerHTML;return Le&&ue["!doctype"]&&he.ownerDocument&&he.ownerDocument.doctype&&he.ownerDocument.doctype.name&&Bt(wv,he.ownerDocument.doctype.name)&&(mt="<!DOCTYPE "+he.ownerDocument.doctype.name+`>
|
|
3
|
+
`+mt),Ve&&(mt=Ii(mt,A," "),mt=Ii(mt,$," "),mt=Ii(mt,Q," ")),K&&Fe?K.createHTML(mt):mt},e.setConfig=function(ve){Ie(ve),ht=!0},e.clearConfig=function(){X=null,ht=!1},e.isValidAttribute=function(ve,ee,he){X||Ie({});var xe=D(ve),Qe=D(ee);return Mi(xe,Qe,he)},e.addHook=function(ve,ee){typeof ee=="function"&&(k[ve]=k[ve]||[],$r(k[ve],ee))},e.removeHook=function(ve){if(k[ve])return hc(k[ve])},e.removeHooks=function(ve){k[ve]&&(k[ve]=[])},e.removeAllHooks=function(){k={}},e}var Nv=Ch();function Ov(s,e){const i=s.hooks??{};let r;for(r in i){const a=i[r];a!==void 0&&e.addHook(r,a)}}function Bv(){return Nv()}function Il(s={},e=Bv){const i=e();Ov(s,i);const r=function(a,o){const l=o.value;if(o.oldValue===l)return;const u=`${l}`,d=o.arg,f=s.namedConfigurations,g=s.default??{};if(f&&d!==void 0){a.innerHTML=i.sanitize(u,f[d]??g);return}a.innerHTML=i.sanitize(u,g)};return{mounted:r,updated:r}}const Lv={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function Pv(s,e){return n.openBlock(),n.createElementBlock("svg",Lv,[...e[0]||(e[0]=[n.createElementVNode("rect",{id:"峰会",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),n.createElementVNode("path",{id:"矢量 425",d:"M8.36719 4.75439L8.36523 4.75537L8.36523 4.75537C7.63184 5.05518 6.93555 5.44629 6.27734 5.9292C6.00098 6.13184 5.94238 6.5083 6.14551 6.78516C6.34766 7.06201 6.72461 7.11963 7.00098 6.91699C7.61035 6.47119 8.25391 6.11475 8.93262 5.84766C9.05371 5.7998 9.17676 5.75488 9.30078 5.71289C9.73242 5.56641 10.1699 5.45752 10.6143 5.38672C10.6191 5.38574 10.624 5.38525 10.6289 5.38428L10.6289 5.38428C11.0439 5.31836 11.4639 5.28564 11.8896 5.28564C12.3193 5.28564 12.7451 5.31934 13.1641 5.38672L13.165 5.38672C13.6084 5.45752 14.0459 5.56641 14.4775 5.71289C14.6016 5.75488 14.7246 5.7998 14.8457 5.84766C15.5254 6.11475 16.1689 6.47119 16.7773 6.91699C17.0537 7.11963 17.4307 7.06201 17.6328 6.78516C17.8359 6.5083 17.7783 6.13184 17.501 5.9292C16.8418 5.4458 16.1455 5.0542 15.4111 4.75439C15.2334 4.68213 15.0537 4.61475 14.8711 4.55273C14.376 4.38477 13.873 4.25977 13.3643 4.17773C12.8789 4.09961 12.3877 4.06055 11.8896 4.06055C11.3916 4.06055 10.8994 4.09961 10.4141 4.17773L10.4141 4.17773C9.90527 4.25977 9.40332 4.38477 8.90723 4.55273C8.72559 4.61475 8.54492 4.68213 8.36719 4.75439L8.36719 4.75439ZM20.377 14.2979L20.377 13.4229C20.377 13.0801 20.1074 12.8105 19.7646 12.8105C19.4219 12.8105 19.1523 13.0801 19.1523 13.4229L19.1523 14.2979C19.1523 14.334 19.1455 14.3677 19.1328 14.3984L19.1328 14.3989C19.1074 14.4243 19.0215 14.5283 18.9902 14.5415C18.96 14.5542 18.9258 14.5605 18.8896 14.5605L4.88965 14.5605C4.85352 14.5605 4.82031 14.5542 4.78906 14.5415C4.76367 14.5156 4.65918 14.4297 4.64648 14.3989C4.63379 14.3677 4.62695 14.3345 4.62695 14.2979L4.62695 9.04785C4.62695 9.01172 4.63379 8.97803 4.64648 8.94727C4.67188 8.92188 4.75781 8.81738 4.78906 8.80469L4.78906 8.80469C4.82031 8.79199 4.85352 8.78564 4.88965 8.78564L18.8896 8.78564C18.9258 8.78564 18.96 8.79199 18.9902 8.80469C19.0166 8.83057 19.1201 8.9165 19.1328 8.94727C19.1455 8.97803 19.1523 9.01172 19.1523 9.04785L19.1523 11.6729C19.1523 12.0161 19.4219 12.2856 19.7646 12.2856C20.1074 12.2856 20.377 12.0161 20.377 11.6729L20.377 9.04785C20.377 8.94141 20.3662 8.83691 20.3447 8.73535L20.3447 8.73438L20.3447 8.73389C20.3252 8.64355 20.2969 8.55518 20.2598 8.46875C20.2236 8.3833 20.1807 8.30225 20.1299 8.22559C20.0752 8.14355 20.0127 8.06738 19.9414 7.99609C19.8701 7.92529 19.7939 7.8623 19.7119 7.80811C19.6357 7.75732 19.5547 7.71387 19.4688 7.67773C19.3828 7.64111 19.2939 7.61328 19.2041 7.59375C19.1016 7.57178 18.9971 7.56055 18.8896 7.56055L4.88965 7.56055C4.78418 7.56055 4.68066 7.57129 4.5791 7.59277L4.5791 7.59277C4.57812 7.59326 4.57715 7.59326 4.57617 7.59375L4.5752 7.59375C4.48535 7.61328 4.39746 7.64111 4.31055 7.67773C4.22461 7.71387 4.14355 7.75732 4.06738 7.80811C3.98535 7.8623 3.90918 7.92529 3.83789 7.99609C3.7666 8.06738 3.7041 8.14355 3.64941 8.22559C3.64941 8.22656 3.64844 8.22705 3.64844 8.22803C3.59863 8.30371 3.55566 8.38379 3.51953 8.46875C3.48242 8.55518 3.45508 8.64355 3.43555 8.73389C3.41309 8.83643 3.40234 8.94092 3.40234 9.04785L3.40234 14.2979C3.40234 14.4053 3.41309 14.5098 3.43555 14.6123C3.45508 14.7021 3.48242 14.7905 3.51953 14.8774C3.55566 14.9629 3.59961 15.0439 3.64941 15.1201C3.7041 15.2021 3.7666 15.2788 3.83789 15.3501C3.90918 15.4209 3.98535 15.4834 4.06738 15.5381C4.14355 15.5889 4.22461 15.6323 4.31055 15.6685C4.39746 15.7051 4.48535 15.7329 4.5752 15.7524C4.67773 15.7744 4.78223 15.7856 4.88965 15.7856L18.8896 15.7856C18.9971 15.7856 19.1016 15.7744 19.2041 15.7524C19.2939 15.7329 19.3828 15.7051 19.4688 15.6685C19.5547 15.6318 19.6357 15.5889 19.7119 15.5381C19.7939 15.4834 19.8701 15.4209 19.9414 15.3501C20.0127 15.2788 20.0752 15.2021 20.1299 15.1201C20.1807 15.0439 20.2236 14.9629 20.2598 14.8774C20.2969 14.7905 20.3252 14.7021 20.3447 14.6123C20.3662 14.5098 20.377 14.4053 20.377 14.2979ZM14.8291 16.3438L14.8291 16.3438C14.9189 16.3633 15.0078 16.3911 15.0938 16.4277C15.1797 16.4639 15.2607 16.5073 15.3369 16.5581C15.4189 16.6123 15.4951 16.6753 15.5664 16.7461C15.6377 16.8174 15.7002 16.8936 15.7549 16.9756C15.8057 17.0522 15.8486 17.1328 15.8848 17.2188C15.9219 17.3052 15.9502 17.3936 15.9697 17.4839C15.9912 17.5864 16.002 17.6909 16.002 17.7979C16.002 17.9053 15.9912 18.0098 15.9697 18.1123C15.9502 18.2021 15.9219 18.2905 15.8848 18.3774C15.8486 18.4629 15.8057 18.5439 15.7549 18.6201C15.7002 18.7021 15.6377 18.7788 15.5664 18.8501C15.4951 18.9209 15.4189 18.9834 15.3369 19.0381C15.2607 19.0889 15.1797 19.1318 15.0938 19.1685C15.0078 19.2051 14.9189 19.2329 14.8291 19.2524C14.7266 19.2744 14.6221 19.2856 14.5146 19.2856L9.26465 19.2856C9.1582 19.2856 9.05273 19.2744 8.9502 19.2524C8.86035 19.2329 8.77246 19.2051 8.68555 19.1685C8.59961 19.1318 8.51855 19.0889 8.44238 19.0381C8.36035 18.9834 8.28418 18.9209 8.21289 18.8501C8.1416 18.7788 8.0791 18.7021 8.02441 18.6201C7.97461 18.5439 7.93066 18.4629 7.89453 18.3774C7.85742 18.2905 7.83008 18.2021 7.81055 18.1123C7.78809 18.0098 7.77734 17.9053 7.77734 17.7979C7.77734 17.6909 7.78809 17.5864 7.81055 17.4839C7.83008 17.3936 7.85742 17.3052 7.89453 17.2188C7.93066 17.1328 7.97461 17.0522 8.02441 16.9756C8.0791 16.8936 8.1416 16.8174 8.21289 16.7461C8.28418 16.6753 8.36035 16.6123 8.44238 16.5581C8.51855 16.5073 8.59961 16.4639 8.68555 16.4277C8.77246 16.3911 8.86035 16.3633 8.9502 16.3438C9.05273 16.3218 9.1582 16.3105 9.26465 16.3105L14.5146 16.3105C14.6221 16.3105 14.7266 16.3218 14.8291 16.3438ZM9.2666 17.5352L14.5166 17.5352C14.5527 17.5352 14.5859 17.5415 14.6172 17.5547C14.6426 17.5801 14.7471 17.666 14.7598 17.6973C14.7725 17.728 14.7793 17.7617 14.7793 17.7979C14.7793 17.834 14.7725 17.8677 14.7598 17.8984C14.7344 17.9243 14.6484 18.0283 14.6172 18.041C14.5859 18.0542 14.5527 18.0605 14.5166 18.0605L9.2666 18.0605C9.23047 18.0605 9.19629 18.0542 9.16602 18.041C9.13965 18.0156 9.03613 17.9297 9.02344 17.8984C9.01074 17.8677 9.00391 17.834 9.00391 17.7979C9.00391 17.7617 9.01074 17.728 9.02344 17.6973C9.04883 17.6714 9.13477 17.5674 9.16602 17.5547C9.19629 17.5415 9.23047 17.5352 9.2666 17.5352Z",fill:"rgb(255,255,255)","fill-rule":"evenodd"},null,-1)])])}const Mv={name:"events-icon-summit",render:Pv},Rv={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function Vv(s,e){return n.openBlock(),n.createElementBlock("svg",Rv,[...e[0]||(e[0]=[n.createElementVNode("rect",{id:"活动",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),n.createElementVNode("path",{id:"矢量 426",d:"M18.3065 11.0924L17.7206 11.6295C17.455 11.8722 17.4384 12.2711 17.6806 12.5362C17.9237 12.8009 18.3221 12.8185 18.5868 12.5758L19.1737 12.0387L20.0418 11.2433C20.1746 11.1217 20.2811 10.9859 20.3631 10.8365C20.4256 10.7198 20.4735 10.5948 20.5057 10.4615C20.5369 10.3316 20.5516 10.2017 20.5496 10.0723C20.5467 9.92 20.5213 9.76765 20.4725 9.61531C20.4237 9.46345 20.3553 9.32478 20.2684 9.19978C20.1942 9.09333 20.1063 8.99665 20.0057 8.90925C19.9012 8.81989 19.7899 8.74616 19.6698 8.68854C19.5165 8.61481 19.3504 8.56744 19.1717 8.54645L15.3212 8.09185C15.2997 8.08355 15.2119 8.05572 15.1923 8.04156C15.1777 8.02398 15.1142 7.9566 15.1044 7.93511L13.4697 4.43751C13.3945 4.27638 13.2978 4.13477 13.1816 4.0127L13.1816 4.0127C13.0898 3.91797 12.9853 3.83496 12.8691 3.76416C12.7549 3.69531 12.6367 3.64209 12.5137 3.60498L12.5137 3.60498C12.3682 3.56104 12.2168 3.53906 12.0586 3.53906C11.8994 3.53906 11.7481 3.56104 11.6025 3.60498L11.6025 3.60498C11.4795 3.64209 11.3613 3.69531 11.2471 3.76416C11.1309 3.83496 11.0264 3.91797 10.9356 4.0127C10.8184 4.13477 10.7217 4.27589 10.6465 4.43751L9.01178 7.93511C8.99713 7.95269 8.94342 8.0274 8.92389 8.04156C8.90241 8.04986 8.81843 8.08892 8.79499 8.09185L4.94448 8.54645C4.76577 8.56744 4.59976 8.61481 4.44644 8.68854L4.44644 8.68854C4.32731 8.74616 4.215 8.81989 4.11149 8.90925C4.00993 8.99665 3.92204 9.09333 3.8488 9.19978C3.76091 9.32478 3.69353 9.46345 3.64373 9.61531C3.5949 9.76765 3.56951 9.92 3.56658 10.0723C3.56463 10.2017 3.57927 10.3316 3.61052 10.4615C3.64275 10.5948 3.6906 10.7198 3.75407 10.8365C3.83513 10.9859 3.94157 11.1217 4.07438 11.2433L6.90635 13.837C6.91807 13.8566 6.97374 13.9313 6.98155 13.9542C6.98155 13.9606 6.98252 13.9713 6.98448 13.9845L6.98448 13.986C6.98838 14.0226 6.99327 14.0763 6.98936 14.0939L6.2384 17.8488C6.20324 18.0241 6.19738 18.196 6.21985 18.3635C6.23645 18.4948 6.2716 18.6232 6.32434 18.7497C6.37512 18.8727 6.43957 18.986 6.51671 19.0891C6.60851 19.2106 6.71788 19.3181 6.84679 19.4118C6.97471 19.5061 7.11045 19.5778 7.254 19.6281C7.37607 19.6711 7.50302 19.698 7.63583 19.7097C7.77157 19.7209 7.90438 19.7155 8.03524 19.6926L8.03524 19.6926C8.20223 19.6628 8.36336 19.6047 8.52058 19.5183L11.9248 17.6369C11.9473 17.631 12.0342 17.6022 12.0586 17.6022C12.0801 17.6081 12.1709 17.6252 12.1914 17.6369L15.5117 19.4719C15.6718 19.5603 15.8368 19.6189 16.0068 19.6481L16.0077 19.6481C16.1396 19.6706 16.2743 19.675 16.412 19.6618C16.5468 19.6491 16.6747 19.6203 16.7968 19.5754C16.9423 19.5222 17.079 19.447 17.2079 19.3488C17.3368 19.2512 17.4462 19.1394 17.537 19.0139C17.6132 18.9079 17.6747 18.7917 17.7235 18.6662C17.7733 18.5368 17.8046 18.4055 17.8182 18.2722C17.8368 18.1008 17.8241 17.926 17.7821 17.7482L16.3495 11.7125C16.2665 11.3629 15.9267 11.1534 15.5771 11.2359C15.2275 11.3189 15.0175 11.6593 15.1005 12.0089L16.5331 18.0446C16.5468 18.1027 16.5458 18.155 16.5292 18.2023C16.5116 18.2492 16.4794 18.2907 16.4325 18.3268C16.3847 18.363 16.3359 18.383 16.286 18.3864C16.2362 18.3903 16.1855 18.3776 16.1327 18.3488L12.8115 16.5133C12.6943 16.4489 12.5732 16.4001 12.4473 16.3678L12.4473 16.3678C12.3223 16.3351 12.1924 16.319 12.0586 16.319C11.9238 16.319 11.794 16.3351 11.669 16.3678C11.543 16.4001 11.4219 16.4489 11.3047 16.5133L7.8995 18.3952C7.84872 18.4235 7.79794 18.4362 7.74911 18.4328C7.69931 18.4299 7.65146 18.4108 7.60458 18.3762C7.55673 18.342 7.52451 18.3015 7.50693 18.2556C7.48837 18.2097 7.48545 18.1579 7.49716 18.1003L8.24813 14.3453C8.27449 14.2116 8.28426 14.0792 8.27644 13.9474C8.26863 13.816 8.24324 13.6852 8.20125 13.5558C8.15926 13.4259 8.10262 13.3058 8.03036 13.1949C7.95907 13.0841 7.87313 12.983 7.77255 12.8907L4.94155 10.297C4.89761 10.2569 4.87026 10.213 4.85757 10.1651C4.84487 10.1173 4.8478 10.0655 4.86538 10.0094C4.88393 9.95369 4.91128 9.90975 4.94936 9.8785C4.98842 9.84676 5.03628 9.82771 5.09487 9.82088L8.94538 9.36628C9.07916 9.35066 9.20709 9.31892 9.32916 9.27155C9.45025 9.22419 9.56646 9.16071 9.67583 9.0821C9.7852 9.003 9.8809 8.91315 9.96391 8.81256C10.0479 8.71198 10.1172 8.60065 10.1748 8.47858L11.8086 4.98097C11.834 4.92824 11.8672 4.88869 11.9082 4.86183C11.9502 4.83546 12 4.82228 12.0586 4.82228C12.1162 4.82228 12.166 4.83546 12.208 4.86183C12.25 4.88869 12.2822 4.92824 12.3076 4.98097L13.9414 8.47858C13.999 8.60065 14.0693 8.71198 14.1523 8.81256C14.2353 8.91315 14.332 9.003 14.4414 9.0821C14.5507 9.16071 14.666 9.22419 14.7871 9.27155C14.9091 9.31892 15.0371 9.35066 15.1708 9.36628L19.0213 9.82088C19.0799 9.82771 19.1278 9.84676 19.1668 9.8785C19.2049 9.90975 19.2333 9.95369 19.2508 10.0094C19.2694 10.0655 19.2713 10.1173 19.2586 10.1651C19.2459 10.213 19.2186 10.2569 19.1747 10.297L18.3065 11.0924ZM9.31256 13.2311L7.93856 11.8561C7.68368 11.6017 7.68368 11.2027 7.93856 10.9483C8.19246 10.6944 8.59187 10.6944 8.84577 10.9483L10.2207 12.3233C10.4746 12.5777 10.4746 12.9772 10.2207 13.2311C9.96586 13.485 9.56743 13.485 9.31256 13.2311Z",fill:"rgb(255,255,255)","fill-rule":"evenodd"},null,-1)])])}const Fv={name:"events-icon-events",render:Vv},$v={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function Uv(s,e){return n.openBlock(),n.createElementBlock("svg",$v,[...e[0]||(e[0]=[n.createElementVNode("rect",{id:"高校 & 比赛",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),n.createElementVNode("path",{id:"矢量 578",d:"M3.05078 7.51904L11.6914 4.13965C11.8086 4.09424 11.9219 4.07178 12.0391 4.07178C12.1523 4.07178 12.2695 4.09473 12.3867 4.14062L20.9609 7.51953C21.0625 7.55957 21.1523 7.61328 21.2305 7.67969C21.2969 7.73779 21.3555 7.80566 21.4062 7.88379C21.5078 8.03857 21.5586 8.20898 21.5625 8.39502C21.5625 8.58057 21.5156 8.75195 21.418 8.9082C21.3125 9.07861 21.1641 9.20264 20.9766 9.28076L19.457 9.91309L19.457 12.2915C19.457 12.6558 19.168 12.9419 18.8047 12.9419C18.4414 12.9419 18.1562 12.6558 18.1562 12.292L18.1562 10.4531L16.0742 11.3188L16.0742 14.7134C16.2852 14.897 16.418 15.1675 16.418 15.4692C16.418 16.0215 15.9688 16.4692 15.418 16.4692C14.8672 16.4692 14.418 16.0215 14.418 15.4692C14.418 15.1626 14.5547 14.8887 14.7734 14.7051L14.7734 11.8589L12.4023 12.8442C12.2852 12.8926 12.1641 12.917 12.0391 12.917C11.9141 12.9175 11.793 12.8936 11.6758 12.8452L5.63281 10.354L5.61328 17.6836C5.61328 17.7285 5.62109 17.771 5.63281 17.8101C5.65234 17.854 5.67969 17.894 5.71484 17.9307C5.75 17.9658 5.78906 17.9917 5.83203 18.0088C5.87109 18.0259 5.91797 18.0342 5.96484 18.0342L17.7812 18.0342C17.832 18.0342 17.875 18.0254 17.918 18.0083C17.957 17.9912 17.9961 17.9658 18.0312 17.9316C18.0625 17.8975 18.0898 17.8599 18.1055 17.8184C18.125 17.7773 18.1328 17.7324 18.1328 17.6841L18.1328 14.1411C18.1328 13.7773 18.418 13.4912 18.7812 13.4912C19.1445 13.4912 19.4336 13.7773 19.4336 14.1411L19.4336 17.6841C19.4336 17.8032 19.418 17.9194 19.3945 18.0332C19.375 18.1333 19.3438 18.231 19.3008 18.3267C19.2188 18.5239 19.1016 18.6987 18.9492 18.8511C18.8711 18.9297 18.7852 18.9995 18.6953 19.0596C18.6094 19.1157 18.5195 19.1641 18.4258 19.2041C18.3281 19.2446 18.2305 19.2759 18.1328 19.2974L18.1328 19.2974C18.0156 19.3218 17.9023 19.334 17.7812 19.334L5.96484 19.334C5.84375 19.334 5.73047 19.3218 5.61719 19.2979C5.51562 19.2759 5.41797 19.2446 5.32031 19.2036C5.12109 19.1201 4.94922 19.002 4.79688 18.8501C4.64453 18.6978 4.52734 18.5225 4.44141 18.3252C4.35547 18.1196 4.3125 17.9048 4.3125 17.6797L4.33594 9.81836L3.03125 9.28174C2.84375 9.2041 2.69531 9.08008 2.58984 8.90967C2.54297 8.83496 2.50781 8.75684 2.48438 8.67578C2.45703 8.58643 2.44531 8.49268 2.44531 8.39502C2.44531 8.29736 2.46094 8.20361 2.48828 8.11475C2.51562 8.03369 2.55078 7.95654 2.59766 7.8833C2.65234 7.80469 2.71094 7.73682 2.77734 7.67871C2.85547 7.61182 2.94922 7.55859 3.05078 7.51904ZM18.5547 8.87891L15.457 10.1665L11.5 8.05322C11.1758 7.88184 10.7891 7.99951 10.6172 8.32031C10.4492 8.6416 10.5664 9.02832 10.8867 9.19971L13.9062 10.8115L12.0352 11.5884L5.23438 8.78271L4.33594 8.41211L12.0352 5.40039L19.6797 8.41211L18.5547 8.87891Z",fill:"rgb(255,254.745,254.745)","fill-rule":"evenodd"},null,-1)])])}const qv={name:"events-icon-competition",render:Uv},jv={viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",width:"24.000000",height:"24.000000",fill:"none",customFrame:"#000000"};function Hv(s,e){return n.openBlock(),n.createElementBlock("svg",jv,[...e[0]||(e[0]=[n.createElementVNode("rect",{id:"版本发布计划",width:"24.000000",height:"24.000000",x:"0.000000",y:"0.000000"},null,-1),n.createElementVNode("path",{id:"矢量 579",d:"M8.94922 6.90332L8.94922 6.3335C8.94922 6.23779 8.95703 6.14404 8.97656 6.05225L8.97656 6.05225C8.99609 5.97119 9.01953 5.89209 9.05469 5.81396C9.08594 5.7373 9.125 5.66455 9.17188 5.59619C9.21875 5.52246 9.27734 5.4541 9.33984 5.39062C9.40234 5.32715 9.47266 5.271 9.54297 5.22217L9.54297 5.22217L9.54297 5.22217C9.61328 5.17676 9.6875 5.1377 9.76172 5.10498C9.83984 5.07227 9.91797 5.04688 10 5.02979L10 5.02979C10.0938 5.00977 10.1875 5 10.2812 5L18.668 5C18.7617 5 18.8555 5.00977 18.9492 5.02979L18.9492 5.02979C19.0273 5.04688 19.1094 5.07227 19.1875 5.10498C19.2617 5.1377 19.3359 5.17676 19.4023 5.22217C19.4766 5.271 19.5469 5.32715 19.6094 5.39062C19.6719 5.4541 19.7305 5.52246 19.7773 5.59619L19.7773 5.59619C19.8242 5.66455 19.8633 5.7373 19.8945 5.81396C19.9297 5.89209 19.9531 5.97119 19.9688 6.05225C19.9883 6.14404 20 6.23779 20 6.3335L20 12.2441C20 12.3398 19.9883 12.4336 19.9688 12.5249C19.9531 12.606 19.9297 12.6855 19.8945 12.7632C19.8633 12.8403 19.8242 12.9131 19.7773 12.9814C19.7305 13.0547 19.6719 13.123 19.6094 13.187C19.5469 13.2505 19.4766 13.3066 19.4023 13.3555C19.3359 13.4009 19.2617 13.4399 19.1875 13.4722C19.1094 13.5054 19.0273 13.5303 18.9492 13.5479C18.8555 13.5674 18.7617 13.5771 18.668 13.5771L18.3906 13.5771C18.0664 13.5771 17.8125 13.3232 17.8125 13C17.8125 12.6768 18.0664 12.4229 18.3906 12.4229L18.668 12.4229C18.6914 12.4229 18.7734 12.3789 18.793 12.3701C18.8086 12.353 18.8359 12.2651 18.8438 12.2441L18.8438 6.3335C18.8438 6.30859 18.8008 6.22803 18.793 6.20703C18.7773 6.18945 18.6875 6.16357 18.668 6.15479L10.2812 6.15479C10.2578 6.15479 10.1758 6.19824 10.1562 6.20703C10.1367 6.22461 10.1133 6.3125 10.1016 6.3335L10.1016 6.90332C10.1016 7.22656 9.84766 7.48047 9.52734 7.48047C9.20312 7.48047 8.94922 7.22656 8.94922 6.90332ZM6.47266 9.39307L6.47266 9.21973C6.47266 9.12402 6.48438 9.03027 6.50391 8.93896C6.51953 8.85791 6.54688 8.77832 6.57812 8.70068C6.61328 8.62354 6.65234 8.55127 6.69531 8.48242C6.74609 8.40918 6.80078 8.34082 6.86328 8.27734C6.92969 8.21338 6.99609 8.15723 7.07031 8.10889C7.13672 8.06299 7.21094 8.02441 7.28906 7.9917C7.36719 7.9585 7.44531 7.93359 7.52734 7.91602C7.61719 7.89648 7.71094 7.88672 7.80859 7.88672L16.1914 7.88672C16.2891 7.88672 16.3828 7.89648 16.4727 7.91602C16.5547 7.93359 16.6328 7.9585 16.7109 7.9917C16.7891 8.02441 16.8594 8.06299 16.9297 8.1084C17.0039 8.15723 17.0703 8.21338 17.1367 8.27734C17.1992 8.34082 17.2539 8.40918 17.3047 8.48242C17.3477 8.55127 17.3867 8.62354 17.4219 8.70068C17.4531 8.77832 17.4805 8.85791 17.4961 8.93896C17.5156 9.03027 17.5273 9.12402 17.5273 9.21973L17.5273 15.1304C17.5273 15.2266 17.5156 15.3198 17.4961 15.4116C17.4805 15.4927 17.4531 15.5718 17.4219 15.6499C17.3867 15.7266 17.3477 15.7993 17.3047 15.8682C17.2539 15.9414 17.1992 16.0098 17.1367 16.0732C17.0703 16.1367 17.0039 16.1929 16.9297 16.2417C16.8633 16.2871 16.7891 16.3262 16.7109 16.3589C16.6328 16.3916 16.5547 16.417 16.4727 16.4346C16.3828 16.4541 16.2891 16.4639 16.1914 16.4639L15.8789 16.4639C15.5547 16.4639 15.3008 16.21 15.3008 15.8867C15.3008 15.5635 15.5547 15.3091 15.8789 15.3091L16.1914 15.3091C16.2188 15.3091 16.2969 15.2656 16.3203 15.2568C16.3359 15.2393 16.3633 15.1519 16.3711 15.1304L16.3711 9.21973C16.3711 9.19531 16.3281 9.11475 16.3203 9.09375C16.3008 9.07617 16.2148 9.0498 16.1914 9.04102L7.80859 9.04102C7.78125 9.04102 7.70312 9.08496 7.67969 9.09375C7.66406 9.11084 7.63672 9.19873 7.62891 9.21973L7.62891 9.39307C7.62891 9.71631 7.375 9.97021 7.05078 9.97021C6.72656 9.97021 6.47266 9.71631 6.47266 9.39307ZM14 10.3901C13.9062 10.3706 13.8125 10.3608 13.7188 10.3608L5.33203 10.3608C5.23828 10.3608 5.14453 10.3706 5.05078 10.3901L5.05078 10.3901C4.97266 10.4077 4.89062 10.4331 4.8125 10.4658C4.73828 10.4985 4.66406 10.5376 4.59766 10.583L4.59766 10.583L4.59766 10.583C4.52344 10.6318 4.45312 10.688 4.39062 10.7515C4.32812 10.8149 4.26953 10.8833 4.22266 10.957C4.17578 11.0254 4.13672 11.0981 4.10547 11.1748C4.07031 11.2529 4.04688 11.332 4.03125 11.4131L4.03125 11.4131C4.01172 11.5049 4 11.5981 4 11.6943L4 17.605C4 17.7007 4.01172 17.7944 4.03125 17.8857C4.04688 17.9668 4.07031 18.0464 4.10547 18.124C4.13672 18.2012 4.17578 18.2739 4.22266 18.3423C4.26953 18.4155 4.32812 18.4839 4.39062 18.5479C4.45312 18.6113 4.52344 18.6675 4.59766 18.7163C4.66406 18.7617 4.73828 18.8008 4.8125 18.833C4.89062 18.8662 4.97266 18.8911 5.05078 18.9087L5.05078 18.9087C5.14453 18.9282 5.23828 18.938 5.33203 18.938L13.7188 18.938C13.8125 18.938 13.9062 18.9282 14 18.9087C14.082 18.8911 14.1602 18.8662 14.2383 18.833C14.3125 18.8008 14.3867 18.7617 14.457 18.7163C14.5273 18.6675 14.5977 18.6113 14.6602 18.5479C14.7227 18.4839 14.7812 18.4155 14.8281 18.3423C14.875 18.2739 14.9141 18.2012 14.9453 18.124C14.9805 18.0464 15.0039 17.9668 15.0234 17.8857C15.043 17.7944 15.0508 17.7007 15.0508 17.605L15.0508 11.6943C15.0508 11.5981 15.043 11.5049 15.0234 11.4131C15.0039 11.332 14.9805 11.2529 14.9453 11.1748C14.9141 11.0981 14.875 11.0254 14.8281 10.957C14.7812 10.8833 14.7227 10.8149 14.6602 10.7515C14.5977 10.688 14.5273 10.6318 14.457 10.583C14.3867 10.5376 14.3125 10.4985 14.2383 10.4658C14.1602 10.4331 14.082 10.4077 14 10.3901ZM5.33203 11.5156L13.7188 11.5156C13.7383 11.5244 13.8281 11.5503 13.8438 11.5679C13.8516 11.5889 13.8984 11.6694 13.8984 11.6943L13.8984 17.605C13.8867 17.626 13.8633 17.7139 13.8438 17.731C13.8242 17.7397 13.7422 17.7837 13.7188 17.7837L5.33203 17.7837C5.3125 17.7749 5.22266 17.7485 5.20703 17.731C5.19922 17.71 5.15625 17.6294 5.15625 17.605L5.15625 11.6943C5.16406 11.6733 5.19141 11.5854 5.20703 11.5679C5.22266 11.5503 5.3125 11.5244 5.33203 11.5156ZM11 12.7754C10.8086 12.5776 10.5 12.5742 10.3008 12.7676C10.1055 12.9614 10.1016 13.2695 10.293 13.4678L11 14.1875L8.36719 14.1875C8.08984 14.1875 7.87109 14.4053 7.87109 14.6826C7.87109 14.9595 8.08984 15.1772 8.36719 15.1772L10.9414 15.1772L10.2969 15.8286C10.1016 16.0254 10.1016 16.3335 10.3008 16.5283C10.4961 16.7236 10.8047 16.7222 11 16.5254L12.5039 15.0078C12.6172 14.8926 12.6758 14.7769 12.6758 14.6611C12.6758 14.5459 12.6172 14.4297 12.5039 14.3135L11 12.7754ZM7.39453 13.6792L7.39453 15.9336C7.39453 16.2109 7.17969 16.4287 6.90234 16.4287C6.625 16.4287 6.40625 16.2109 6.40625 15.9336L6.40625 13.6792C6.40625 13.4019 6.625 13.1841 6.90234 13.1841C7.17969 13.1841 7.39453 13.4019 7.39453 13.6792Z",fill:"rgb(255,255,255)","fill-rule":"evenodd"},null,-1)])])}const zv={name:"events-icon-release",render:Hv},Gv={summit:"--o-orange-6",events:"--o-cyan-6",competition:"--o-blue-6",release:"--o-purple-6"},Wv={events:Fv,competition:qv,release:zv,summit:Mv},Vs={上海:"https://infrastructure-website.osinfra.cn/picture/city/shanghai.jpg",北京:"https://infrastructure-website.osinfra.cn/picture/city/beijing.jpg",南京:"https://infrastructure-website.osinfra.cn/picture/city/nanjing.jpg",天津:"https://infrastructure-website.osinfra.cn/picture/city/tianjin.jpg",成都:"https://infrastructure-website.osinfra.cn/picture/city/chengdu.jpg",无锡:"https://infrastructure-website.osinfra.cn/picture/city/wuxi.jpg",杭州:"https://infrastructure-website.osinfra.cn/picture/city/hangzhou.jpg",深圳:["https://infrastructure-website.osinfra.cn/picture/city/shenzhen1.jpg","https://infrastructure-website.osinfra.cn/picture/city/shenzhen2.jpg"],苏州:"https://infrastructure-website.osinfra.cn/picture/city/suzhou.jpg",西安:"https://infrastructure-website.osinfra.cn/picture/city/xian.jpg",郑州:"https://infrastructure-website.osinfra.cn/picture/city/zhengzhou.jpg",武汉:"https://infrastructure-website.osinfra.cn/picture/city/wuhan.jpg"},Yv="https://infrastructure-website.osinfra.cn/picture/city/default-cover.jpg",Xv={class:"o-events-calendar"},Kv={key:0,class:"month-list"},Qv={class:"collapse-header"},Zv={class:"collapse-title"},Jv={key:0,class:"collapse-desc"},e3={key:0,class:"month-content month-content-span"},t3={key:0,class:"event-location"},i3={class:"event-name"},n3={key:1},r3={key:0,class:"month-content-row"},s3={class:"month-name"},a3={class:"event-name"},o3={class:"event-location"},l3={class:"event-name"},u3={class:"event-location"},c3={key:1,class:"month-content month-content-column"},d3={class:"event-location"},h3={class:"event-name"},f3={key:1},yc=n.defineComponent({__name:"OEventsCalendar",props:{data:{default:()=>[]}},setup(s){const e=Il(),{lePadV:i}=wt.useScreen(),r=s,a=["JAN","FEB","MAR","Apr","May","JUN","Jul","Aug","Sep","Oct","Nov","Dec"],o=n.ref([]);n.watch([()=>r.data,()=>i.value],()=>{var y;r.data.length?i.value?o.value=[(y=r.data[0])==null?void 0:y.name]:o.value=r.data.map(E=>E.name):o.value=[]},{immediate:!0});const l=y=>{const E=y.split("/");return parseInt(E[1],10)},u=y=>{const E=new Array(12).fill(0),x=[];return y.forEach((B,T)=>{const[w,F]=Array.isArray(B.date)?[l(B.date[0]),l(B.date[1])]:[l(B.date),l(B.date)];let P=0;for(let K=w-1;K<F;K++)P=Math.max(P,E[K]);const I=P+1;for(let K=w-1;K<F;K++)E[K]=I;x.push({event:B,row:I,eventIndex:T,start:w,end:F})}),x},d=y=>{const E=Array.from({length:12},()=>[]);return y.forEach(x=>{const B=Array.isArray(x.date)?l(x.date[0]):l(x.date);E[B-1].push(x)}),E},f=y=>{const E=y.color||Gv[y.type];return E!=null&&E.startsWith("--")?`var(${E})`:E},g=y=>y.icon?y.icon:Wv[y.type];return(y,E)=>(n.openBlock(),n.createElementBlock("div",Xv,[n.unref(i)?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",Kv,[(n.openBlock(),n.createElementBlock(n.Fragment,null,n.renderList(a,x=>n.createElementVNode("div",{class:"month-header",key:x},n.toDisplayString(x),1)),64))])),n.createVNode(n.unref(O.OCollapse),{modelValue:o.value,"onUpdate:modelValue":E[0]||(E[0]=x=>o.value=x)},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.data,(x,B)=>(n.openBlock(),n.createBlock(n.unref(O.OCollapseItem),{key:B,value:x.name},{title:n.withCtx(()=>[n.createElementVNode("div",Qv,[n.createElementVNode("div",Zv,[n.createElementVNode("div",{class:"title-icon",style:n.normalizeStyle({"--bg-color":f(x)})},[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(g(x))))]),_:2},1024)],4),n.createElementVNode("span",null,n.toDisplayString(x.name),1)]),x.desc?(n.openBlock(),n.createElementBlock("div",Jv,[n.withDirectives(n.createElementVNode("div",null,null,512),[[n.unref(e),x.desc]])])):n.createCommentVNode("",!0)])]),default:n.withCtx(()=>[x.isSpanMonth?(n.openBlock(),n.createElementBlock("div",e3,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(u(x.data),({event:T,row:w,eventIndex:F,start:P,end:I})=>(n.openBlock(),n.createElementBlock("div",{key:F,class:n.normalizeClass(["event-item",{"event-item-center":T.align==="center","has-link":T.link}]),style:n.normalizeStyle({gridColumn:`${P} / ${I+1}`,gridRow:w,"--bg-color":f(x)||void 0})},[T.location?(n.openBlock(),n.createElementBlock("div",t3,n.toDisplayString(T.location),1)):n.createCommentVNode("",!0),n.createElementVNode("div",i3,[T.link?(n.openBlock(),n.createBlock(n.unref(O.OLink),n.mergeProps({key:0,href:T.link,target:"_blank"},{ref_for:!0},T.linkProps||{}),{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(T.name),1)]),_:2},1040,["href"])):(n.openBlock(),n.createElementBlock("span",n3,n.toDisplayString(T.name),1))])],6))),128))])):(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.unref(i)?(n.openBlock(),n.createElementBlock("div",r3,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(d(x.data),(T,w)=>(n.openBlock(),n.createElementBlock("div",{key:w,class:n.normalizeClass(["month-row",{"empty-month":T.length===0}])},[n.createElementVNode("div",s3,n.toDisplayString(a[w]),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(T,(F,P)=>(n.openBlock(),n.createElementBlock("div",{key:P,class:n.normalizeClass(["event-item",F.link?"has-link":""]),style:n.normalizeStyle({"--bd-color":f(x)||void 0})},[F.link?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:0,href:F.link,target:"_blank"},{default:n.withCtx(()=>[n.createElementVNode("div",null,[n.createElementVNode("div",a3,[n.createElementVNode("span",null,n.toDisplayString(F.name),1)]),n.createElementVNode("div",o3,n.toDisplayString(F.location),1)]),n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})]),_:2},1032,["href"])):(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createElementVNode("div",l3,n.toDisplayString(F.name),1),n.createElementVNode("div",u3,n.toDisplayString(F.location),1)],64))],6))),128))],2))),128))])):(n.openBlock(),n.createElementBlock("div",c3,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(d(x.data),(T,w)=>(n.openBlock(),n.createElementBlock("div",{key:w,class:"month-column"},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(T,(F,P)=>(n.openBlock(),n.createElementBlock("div",{key:P,class:n.normalizeClass(["event-item",F.link?"has-link":""]),style:n.normalizeStyle({"--bg-color":f(x)||void 0})},[n.createElementVNode("div",d3,n.toDisplayString(F.location),1),n.createElementVNode("div",h3,[F.link?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:0,href:F.link,target:"_blank"},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})]),default:n.withCtx(()=>[n.createElementVNode("span",null,n.toDisplayString(F.name),1)]),_:2},1032,["href"])):(n.openBlock(),n.createElementBlock("span",f3,n.toDisplayString(F.name),1))])],6))),128))]))),128))]))],64))]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]))}});var Ji=(s=>(s.FINISH="finish",s.ING="ing",s.ALL="",s))(Ji||{});const vc=(s,e)=>new Date(s).getTime()>new Date(e).getTime(),p3={class:"o-events-list"},m3={class:"filter-wrapper"},g3={class:"filter-left"},_3={class:"list-content"},y3={class:"event-name"},v3={class:"event-desc"},T3={class:"event-date"},b3={key:0,class:"event-location"},Tc=n.defineComponent({__name:"OEventsList",props:{data:{default:()=>[]},page:{},pageSize:{},total:{}},emits:["search"],setup(s,{emit:e}){const{t:i}=Ue.useI18n(),{lePadV:r}=wt.useScreen(),a=s,o=[{label:i("events.statusAll"),value:Ji.ALL},{label:i("events.statusIng"),value:Ji.ING},{label:i("events.statusFinish"),value:Ji.FINISH}],l=e,u=n.ref(Ji.ALL),d=n.ref(""),f=n.ref(""),g=(B={})=>{l("search",Object.assign({page:a.page,pageSize:a.pageSize,status:u.value,keyword:f.value},B))},y=()=>{g()},E=()=>{f.value=d.value,g()},x=n.computed(()=>a.data.map(B=>({...B,status:vc(new Date,B.date)?Ji.FINISH:Ji.ING})).sort((B,T)=>vc(B.date,T.date)?-1:1).map(B=>{var F,P,I;const T=(I=(P=(F=B.city)==null?void 0:F.replace("市",""))==null?void 0:P.replace("中国",""))==null?void 0:I.replaceAll(" ","");let w=null;return Array.isArray(Vs[T])?w=Vs[T][B.name.length%Vs[T].length]:w=Vs[T],w||(w=Yv),{...B,cover:w}}));return(B,T)=>(n.openBlock(),n.createElementBlock("div",p3,[n.createElementVNode("div",m3,[n.createElementVNode("div",g3,[n.createElementVNode("span",null,n.toDisplayString(n.unref(i)("events.status")),1),n.createVNode(n.unref(O.ORadioGroup),{modelValue:u.value,"onUpdate:modelValue":T[0]||(T[0]=w=>u.value=w),style:{"--radio-group-gap":"8px"},onChange:y},{default:n.withCtx(()=>[(n.openBlock(),n.createElementBlock(n.Fragment,null,n.renderList(o,w=>n.createVNode(n.unref(O.ORadio),{key:w.value,value:w.value},{radio:n.withCtx(({checked:F})=>[n.createVNode(n.unref(O.OToggle),{checked:F},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(w.label),1)]),_:2},1032,["checked"])]),_:2},1032,["value"])),64))]),_:1},8,["modelValue"])]),n.createVNode(n.unref(O.OInput),{modelValue:d.value,"onUpdate:modelValue":T[1]||(T[1]=w=>d.value=w),placeholder:n.unref(i)("events.searchPlaceholder"),onPressEnter:E,onClear:E,clearable:""},{prefix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),{class:"input-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconSearch))]),_:1})]),_:1},8,["modelValue","placeholder"])]),n.createElementVNode("div",_3,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(x.value,w=>(n.openBlock(),n.createBlock(n.unref(O.OCard),{key:w.name,cover:w.cover,href:w.link},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OTag),{class:"event-status"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(w.status===n.unref(Ji).ING?n.unref(i)("events.statusIng"):n.unref(i)("events.statusFinish")),1)]),_:2},1024),n.createElementVNode("div",y3,n.toDisplayString(w.name),1),n.createElementVNode("div",v3,[n.createElementVNode("div",T3,n.toDisplayString(w.date),1),n.createVNode(n.unref(O.ODivider),{direction:"v"}),w.city?(n.openBlock(),n.createElementBlock("div",b3,n.toDisplayString(w.city),1)):n.createCommentVNode("",!0)])]),_:2},1032,["cover","href"]))),128))]),x.value.length?n.createCommentVNode("",!0):n.renderSlot(B.$slots,"empty",{key:0}),s.total>8?(n.openBlock(),n.createBlock(n.unref(O.OPagination),{key:1,page:s.page,simple:n.unref(r),"show-total":!0,pageSize:s.pageSize,total:s.total,onChange:g,pageSizes:[4,12,24,36,48]},null,8,["page","simple","pageSize","total"])):n.createCommentVNode("",!0)]))}}),x3={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function C3(s,e){return n.openBlock(),n.createElementBlock("svg",x3,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"#1da9ff",d:"M20.4 5.95c0.27-0.27 0.71-0.27 0.99 0 0.24 0.25 0.27 0.63 0.070 0.91l-0.070 0.080-10.5 10.47c-0.53 0.53-1.36 0.56-1.93 0.1l-0.11-0.1-5.23-5.2c-0.28-0.28-0.28-0.72-0.010-0.99 0.25-0.25 0.63-0.28 0.91-0.080l0.080 0.070 5.24 5.21c0.010 0.010 0.030 0.010 0.040 0.010l0.030-0.010 10.49-10.47z"},null,-1)])])}const S3={name:"events-icon-checked",render:C3},E3={class:"o-events-apply"},k3={class:"events-apply-grid"},w3={class:"timeline-number"},D3={class:"number-circle"},A3={class:"step-title"},I3={class:"step-idx"},N3={class:"step-desc"},O3={key:0},B3={class:"desc-list-wrapper"},L3={key:0,class:"desc-list-title"},P3={class:"desc-list-content"},M3={class:"desc-list-item-title"},R3={class:"desc-list-item-desc"},bc=n.defineComponent({__name:"OEventsApply",props:{steps:{}},setup(s){const{isDark:e}=wt.useTheme(),i=Il();return(r,a)=>(n.openBlock(),n.createElementBlock("div",E3,[n.createElementVNode("div",k3,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.steps,(o,l)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:l},[n.createElementVNode("div",w3,[n.createElementVNode("div",D3,n.toDisplayString(l+1),1)]),n.createElementVNode("div",{class:n.normalizeClass(["step-item",`step-${l+1} ${n.unref(e)?"is-dark":""}`]),style:{}},[n.createElementVNode("div",A3,[n.createElementVNode("div",I3,n.toDisplayString(l+1),1),n.createElementVNode("span",null,n.toDisplayString(o.title),1)]),n.createElementVNode("div",N3,[o.desc?n.withDirectives((n.openBlock(),n.createElementBlock("div",O3,null,512)),[[n.unref(i),o.desc]]):n.createCommentVNode("",!0),n.renderSlot(r.$slots,`step${l+1}`),n.createElementVNode("div",B3,[o.listTitle?(n.openBlock(),n.createElementBlock("div",L3,n.toDisplayString(o.listTitle),1)):n.createCommentVNode("",!0),n.createElementVNode("div",P3,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(o.list,(u,d)=>(n.openBlock(),n.createElementBlock("div",{class:"desc-list-item",key:d},[n.createElementVNode("div",M3,[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(S3))]),_:1}),n.createElementVNode("span",null,n.toDisplayString(u.title),1)]),n.createElementVNode("div",R3,n.toDisplayString(u.desc),1)]))),128))])])]),o.img?(n.openBlock(),n.createElementBlock("div",{key:0,class:"img-wrapper",style:n.normalizeStyle({backgroundImage:`url(${o.img})`})},null,4)):n.createCommentVNode("",!0),o.imgPhone?(n.openBlock(),n.createElementBlock("div",{key:1,class:"img-wrapper-phone",style:n.normalizeStyle({backgroundImage:`url(${o.imgPhone})`})},null,4)):n.createCommentVNode("",!0)],2)],64))),128))])]))}}),V3=Object.assign(yc,{install(s){s.component("OEventsCalendar",yc)}}),F3=Object.assign(Tc,{install(s){s.component("OEventsList",Tc)}}),$3=Object.assign(bc,{install(s){s.component("OEventsApply",bc)}});var na=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function pr(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}function U3(s){if(Object.prototype.hasOwnProperty.call(s,"__esModule"))return s;var e=s.default;if(typeof e=="function"){var i=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};i.prototype=e.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(s).forEach(function(r){var a=Object.getOwnPropertyDescriptor(s,r);Object.defineProperty(i,r,a.get?a:{enumerable:!0,get:function(){return s[r]}})}),i}var Qs={exports:{}},q3=Qs.exports,xc;function j3(){return xc||(xc=1,(function(s,e){(function(i,r){s.exports=r()})(q3,(function(){var i=1e3,r=6e4,a=36e5,o="millisecond",l="second",u="minute",d="hour",f="day",g="week",y="month",E="quarter",x="year",B="date",T="Invalid Date",w=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,F=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,P={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(A){var $=["th","st","nd","rd"],Q=A%100;return"["+A+($[(Q-20)%10]||$[Q]||$[0])+"]"}},I=function(A,$,Q){var H=String(A);return!H||H.length>=$?A:""+Array($+1-H.length).join(Q)+A},K={s:I,z:function(A){var $=-A.utcOffset(),Q=Math.abs($),H=Math.floor(Q/60),V=Q%60;return($<=0?"+":"-")+I(H,2,"0")+":"+I(V,2,"0")},m:function A($,Q){if($.date()<Q.date())return-A(Q,$);var H=12*(Q.year()-$.year())+(Q.month()-$.month()),V=$.clone().add(H,y),G=Q-V<0,Z=$.clone().add(H+(G?-1:1),y);return+(-(H+(Q-V)/(G?V-Z:Z-V))||0)},a:function(A){return A<0?Math.ceil(A)||0:Math.floor(A)},p:function(A){return{M:y,y:x,w:g,d:f,D:B,h:d,m:u,s:l,ms:o,Q:E}[A]||String(A||"").toLowerCase().replace(/s$/,"")},u:function(A){return A===void 0}},q="en",M={};M[q]=P;var N="$isDayjsObject",J=function(A){return A instanceof j||!(!A||!A[N])},b=function A($,Q,H){var V;if(!$)return q;if(typeof $=="string"){var G=$.toLowerCase();M[G]&&(V=G),Q&&(M[G]=Q,V=G);var Z=$.split("-");if(!V&&Z.length>1)return A(Z[0])}else{var te=$.name;M[te]=$,V=te}return!H&&V&&(q=V),V||!H&&q},C=function(A,$){if(J(A))return A.clone();var Q=typeof $=="object"?$:{};return Q.date=A,Q.args=arguments,new j(Q)},U=K;U.l=b,U.i=J,U.w=function(A,$){return C(A,{locale:$.$L,utc:$.$u,x:$.$x,$offset:$.$offset})};var j=(function(){function A(Q){this.$L=b(Q.locale,null,!0),this.parse(Q),this.$x=this.$x||Q.x||{},this[N]=!0}var $=A.prototype;return $.parse=function(Q){this.$d=(function(H){var V=H.date,G=H.utc;if(V===null)return new Date(NaN);if(U.u(V))return new Date;if(V instanceof Date)return new Date(V);if(typeof V=="string"&&!/Z$/i.test(V)){var Z=V.match(w);if(Z){var te=Z[2]-1||0,se=(Z[7]||"0").substring(0,3);return G?new Date(Date.UTC(Z[1],te,Z[3]||1,Z[4]||0,Z[5]||0,Z[6]||0,se)):new Date(Z[1],te,Z[3]||1,Z[4]||0,Z[5]||0,Z[6]||0,se)}}return new Date(V)})(Q),this.init()},$.init=function(){var Q=this.$d;this.$y=Q.getFullYear(),this.$M=Q.getMonth(),this.$D=Q.getDate(),this.$W=Q.getDay(),this.$H=Q.getHours(),this.$m=Q.getMinutes(),this.$s=Q.getSeconds(),this.$ms=Q.getMilliseconds()},$.$utils=function(){return U},$.isValid=function(){return this.$d.toString()!==T},$.isSame=function(Q,H){var V=C(Q);return this.startOf(H)<=V&&V<=this.endOf(H)},$.isAfter=function(Q,H){return C(Q)<this.startOf(H)},$.isBefore=function(Q,H){return this.endOf(H)<C(Q)},$.$g=function(Q,H,V){return U.u(Q)?this[H]:this.set(V,Q)},$.unix=function(){return Math.floor(this.valueOf()/1e3)},$.valueOf=function(){return this.$d.getTime()},$.startOf=function(Q,H){var V=this,G=!!U.u(H)||H,Z=U.p(Q),te=function(We,Me){var Se=U.w(V.$u?Date.UTC(V.$y,Me,We):new Date(V.$y,Me,We),V);return G?Se:Se.endOf(f)},se=function(We,Me){return U.w(V.toDate()[We].apply(V.toDate("s"),(G?[0,0,0,0]:[23,59,59,999]).slice(Me)),V)},ue=this.$W,ce=this.$M,de=this.$D,qe="set"+(this.$u?"UTC":"");switch(Z){case x:return G?te(1,0):te(31,11);case y:return G?te(1,ce):te(0,ce+1);case g:var De=this.$locale().weekStart||0,Oe=(ue<De?ue+7:ue)-De;return te(G?de-Oe:de+(6-Oe),ce);case f:case B:return se(qe+"Hours",0);case d:return se(qe+"Minutes",1);case u:return se(qe+"Seconds",2);case l:return se(qe+"Milliseconds",3);default:return this.clone()}},$.endOf=function(Q){return this.startOf(Q,!1)},$.$set=function(Q,H){var V,G=U.p(Q),Z="set"+(this.$u?"UTC":""),te=(V={},V[f]=Z+"Date",V[B]=Z+"Date",V[y]=Z+"Month",V[x]=Z+"FullYear",V[d]=Z+"Hours",V[u]=Z+"Minutes",V[l]=Z+"Seconds",V[o]=Z+"Milliseconds",V)[G],se=G===f?this.$D+(H-this.$W):H;if(G===y||G===x){var ue=this.clone().set(B,1);ue.$d[te](se),ue.init(),this.$d=ue.set(B,Math.min(this.$D,ue.daysInMonth())).$d}else te&&this.$d[te](se);return this.init(),this},$.set=function(Q,H){return this.clone().$set(Q,H)},$.get=function(Q){return this[U.p(Q)]()},$.add=function(Q,H){var V,G=this;Q=Number(Q);var Z=U.p(H),te=function(ce){var de=C(G);return U.w(de.date(de.date()+Math.round(ce*Q)),G)};if(Z===y)return this.set(y,this.$M+Q);if(Z===x)return this.set(x,this.$y+Q);if(Z===f)return te(1);if(Z===g)return te(7);var se=(V={},V[u]=r,V[d]=a,V[l]=i,V)[Z]||1,ue=this.$d.getTime()+Q*se;return U.w(ue,this)},$.subtract=function(Q,H){return this.add(-1*Q,H)},$.format=function(Q){var H=this,V=this.$locale();if(!this.isValid())return V.invalidDate||T;var G=Q||"YYYY-MM-DDTHH:mm:ssZ",Z=U.z(this),te=this.$H,se=this.$m,ue=this.$M,ce=V.weekdays,de=V.months,qe=V.meridiem,De=function(Me,Se,me,ke){return Me&&(Me[Se]||Me(H,G))||me[Se].slice(0,ke)},Oe=function(Me){return U.s(te%12||12,Me,"0")},We=qe||function(Me,Se,me){var ke=Me<12?"AM":"PM";return me?ke.toLowerCase():ke};return G.replace(F,(function(Me,Se){return Se||(function(me){switch(me){case"YY":return String(H.$y).slice(-2);case"YYYY":return U.s(H.$y,4,"0");case"M":return ue+1;case"MM":return U.s(ue+1,2,"0");case"MMM":return De(V.monthsShort,ue,de,3);case"MMMM":return De(de,ue);case"D":return H.$D;case"DD":return U.s(H.$D,2,"0");case"d":return String(H.$W);case"dd":return De(V.weekdaysMin,H.$W,ce,2);case"ddd":return De(V.weekdaysShort,H.$W,ce,3);case"dddd":return ce[H.$W];case"H":return String(te);case"HH":return U.s(te,2,"0");case"h":return Oe(1);case"hh":return Oe(2);case"a":return We(te,se,!0);case"A":return We(te,se,!1);case"m":return String(se);case"mm":return U.s(se,2,"0");case"s":return String(H.$s);case"ss":return U.s(H.$s,2,"0");case"SSS":return U.s(H.$ms,3,"0");case"Z":return Z}return null})(Me)||Z.replace(":","")}))},$.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},$.diff=function(Q,H,V){var G,Z=this,te=U.p(H),se=C(Q),ue=(se.utcOffset()-this.utcOffset())*r,ce=this-se,de=function(){return U.m(Z,se)};switch(te){case x:G=de()/12;break;case y:G=de();break;case E:G=de()/3;break;case g:G=(ce-ue)/6048e5;break;case f:G=(ce-ue)/864e5;break;case d:G=ce/a;break;case u:G=ce/r;break;case l:G=ce/i;break;default:G=ce}return V?G:U.a(G)},$.daysInMonth=function(){return this.endOf(y).$D},$.$locale=function(){return M[this.$L]},$.locale=function(Q,H){if(!Q)return this.$L;var V=this.clone(),G=b(Q,H,!0);return G&&(V.$L=G),V},$.clone=function(){return U.w(this.$d,this)},$.toDate=function(){return new Date(this.valueOf())},$.toJSON=function(){return this.isValid()?this.toISOString():null},$.toISOString=function(){return this.$d.toISOString()},$.toString=function(){return this.$d.toUTCString()},A})(),k=j.prototype;return C.prototype=k,[["$ms",o],["$s",l],["$m",u],["$H",d],["$W",f],["$M",y],["$y",x],["$D",B]].forEach((function(A){k[A[1]]=function($){return this.$g($,A[0],A[1])}})),C.extend=function(A,$){return A.$i||(A($,j,C),A.$i=!0),C},C.locale=b,C.isDayjs=J,C.unix=function(A){return C(1e3*A)},C.en=M[q],C.Ls=M,C.p={},C}))})(Qs)),Qs.exports}var H3=j3();const Ee=pr(H3),z3={class:"more-text-wrapper"},G3={key:0},W3={key:1},Y3=n.defineComponent({__name:"MoreText",props:{text:{default:""},link:{type:Boolean,default:!1},lines:{default:3},show:{type:Boolean,default:!1}},setup(s){const e=s,i=n.ref(!1),r=n.ref(!1),a=n.ref(0),o=n.ref(null);n.onMounted(()=>{l()}),n.watch([()=>e.text,()=>e.show],()=>{l()});const l=()=>{n.nextTick(()=>{const d=o.value;if(d){const f=document.createRange();f.setStart(d,0),f.setEnd(d,d.childNodes.length),r.value=f.getBoundingClientRect().height>d.offsetHeight+10||d.scrollHeight>d.offsetHeight+10,a.value=f.getBoundingClientRect().height||d.scrollHeight}else r.value=!1})},u=()=>{console.log(e.link),console.log("判断是否使用a标签")};return(d,f)=>(n.openBlock(),n.createElementBlock("div",z3,[n.createElementVNode("div",{class:n.normalizeClass(["more-text-content",s.link&&"is-link"]),ref_key:"contentRef",ref:o,style:n.normalizeStyle({"max-height":i.value?a.value+"px":"66px","-webkit-line-clamp":i.value?"initial":s.lines}),onClick:u},n.toDisplayString(s.text),7),r.value?(n.openBlock(),n.createElementBlock("div",{key:0,class:"more-text-btn",onClick:f[0]||(f[0]=g=>i.value=!i.value)},[i.value?(n.openBlock(),n.createElementBlock("div",W3,[n.createElementVNode("span",null,n.toDisplayString(d.t("common.collapse")),1),n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronUp))]),_:1})])):(n.openBlock(),n.createElementBlock("div",G3,[n.createElementVNode("span",null,n.toDisplayString(d.t("common.expand")),1),n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronDown))]),_:1})]))])):n.createCommentVNode("",!0)]))}}),X3=Ue._export_sfc(Y3,[["__scopeId","data-v-51795609"]]),K3={class:"o-meeting-detail"},Q3={class:"label"},Z3={key:2,class:"value"},J3={key:0,class:"extra"},eT=n.defineComponent({__name:"OMeetingDetail",props:{data:{},from:{},show:{type:Boolean}},setup(s,{expose:e}){const i=s,{t:r,locale:a}=Ue.useI18n(),o=n.computed(()=>a.value===Ue.Locales.ZH),l=n.computed(()=>[{label:r("meeting.meetingDetail"),key:"agenda",ellipsis:!0},{label:r("meeting.meetingCreator"),key:"sponsor"},{label:r("meeting.meetingDate2"),key:"timeRange",extra:"date"},{label:r("meeting.meetingId"),key:"mid"},{label:r("meeting.meetingPlatform"),key:"platform"},{label:r("meeting.meetingLink"),key:"join_url",isLink:!0},{label:r("meeting.meetingEtherpad"),key:"etherpad",isLink:!0},{label:r("meeting.meetingReplay"),key:"replay_url",isLink:!0}].slice(0,i.from==="my"?7:8)),u=n.ref([{label:r("meeting.startDate"),key:"start_date"},{label:r("meeting.endDate"),key:"end_date"},{label:r("meeting.activityAddress"),key:"address"}]),d=n.computed(()=>["events","summit"].includes(i.data.type)?u.value:l.value),f=n.ref([]);return e({copyInfo:()=>{try{let y=`${r("meeting.meetingTopic")+i.data.topic}
|
|
4
|
+
`;return y+=[...f.value].reduce((E,x)=>`${E}${x.textContent}
|
|
5
|
+
`,""),navigator.clipboard.writeText(y),Promise.resolve()}catch(y){return Promise.reject(y)}}}),(y,E)=>(n.openBlock(),n.createElementBlock("div",K3,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(d.value,(x,B)=>(n.openBlock(),n.createElementBlock("div",{ref_for:!0,ref_key:"domRef",ref:f,class:n.normalizeClass(["label-item",`label-item_${s.data.id} type_${s.data.type} `]),key:B},[s.data[x.key]?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createElementVNode("span",Q3,[n.createTextVNode(n.toDisplayString(x.label),1),n.createElementVNode("i",null,n.toDisplayString(o.value?":":":"),1)]),x.ellipsis?(n.openBlock(),n.createBlock(X3,{key:0,show:s.show,text:s.data[x.key]||"-"},null,8,["show","text"])):x.isLink?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:1,target:"_blank",class:"value",color:"primary","hover-underline":"",href:s.data[x.key]},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(s.data[x.key]),1)]),_:2},1032,["href"])):(n.openBlock(),n.createElementBlock("span",Z3,[x.extra?(n.openBlock(),n.createElementBlock("i",J3,n.toDisplayString(s.data[x.extra]),1)):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(s.data[x.key]||"-"),1)]))],64)):n.createCommentVNode("",!0)],2))),128))]))}}),Sh=Ue._export_sfc(eT,[["__scopeId","data-v-5d2e0003"]]),tT={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"30",height:"32",viewBox:"0 0 30 32"};function iT(s,e){return n.openBlock(),n.createElementBlock("svg",tT,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.8",fill:"#000",d:"M12.983 5.523c0.341 0 0.667 0.14 0.902 0.388l6.569 6.917c0.142 0.15 0.243 0.331 0.297 0.526 0.054 0.141 0.085 0.295 0.085 0.457 0 0.108-0.014 0.213-0.040 0.314l-0 13.942c0 1.964-1.592 3.556-3.556 3.556h-13.296c-1.964 0-3.556-1.592-3.556-3.556v-18.987c0-1.964 1.592-3.556 3.556-3.556zM11.528 8.011l-7.582 0.001c-0.589 0-1.067 0.478-1.067 1.067v18.987c0 0.589 0.478 1.067 1.067 1.067h13.296c0.589 0 1.067-0.478 1.067-1.067l-0.002-13.012-3.149 0.002c-1.935 0-3.515-1.547-3.555-3.482l-0.075-3.561zM9.777 24.987c0.491 0 0.889 0.398 0.889 0.889s-0.398 0.889-0.889 0.889h-4.432c-0.491 0-0.889-0.398-0.889-0.889s0.398-0.889 0.889-0.889h4.432zM26.256 0.269c1.964 0 3.556 1.592 3.556 3.556v18.012c0 1.964-1.592 3.556-3.556 3.556h-2.586c-0.687 0-1.244-0.557-1.244-1.244s0.557-1.244 1.244-1.244h2.586c0.589 0 1.067-0.478 1.067-1.067v-18.012c0-0.589-0.478-1.067-1.067-1.067h-13.27c-0.496 0-0.912 0.338-1.032 0.796l-2.514 0.002c0.137-1.838 1.672-3.287 3.546-3.287h13.27zM12.112 21.432c0.491 0 0.889 0.398 0.889 0.889s-0.398 0.889-0.889 0.889h-6.743c-0.491 0-0.889-0.398-0.889-0.889s0.398-0.889 0.889-0.889h6.743zM14.234 17.876c0.491 0 0.889 0.398 0.889 0.889s-0.398 0.889-0.889 0.889h-8.853c-0.491 0-0.889-0.398-0.889-0.889s0.398-0.889 0.889-0.889h8.853zM14.052 9.7l0.039 1.821c0.012 0.58 0.486 1.045 1.066 1.045l1.617-0.002-2.722-2.864z"},null,-1)])])}const Eh={name:"meeting-icon-copy",render:iT},{t:Cc}=Ue.useI18n(),hi=(s=new Date,e="YYYY-MM-DD")=>{let i=s;return i||(i=new Date),Ee(new Date(i)).isValid()?Ee(new Date(i)).format(e):i},kh=(s,e,i="label",r="value")=>{const a=e.find(o=>o[r]===s);return(a==null?void 0:a[i])||s},Xn=(s,e)=>s===gn?e.sort((i,r)=>{const a=Ys.findIndex(l=>l.value===i),o=Ys.findIndex(l=>l.value===r);return a-o}).map(i=>kh(i,Ys)).join(Cc("meeting.cycleSplit")):s===nn?e.join(Cc("meeting.cycleSplit")):"",nT=s=>{const e=/\d+/g,i=s.match(e)||"";return parseInt(i[0])},Xr=s=>{const e=s.split(":");if(e.length>3||!e.length)return 0;let i=0,r=1;for(;e.length>0;){const a=e.pop();i+=parseInt(a)*r,r*=60}return i},mo=s=>s<0?"Invalid number":s>=10?`${s}`:`0${s}`,Sc=s=>{if(s>1440*60)return"Invalid date";const e=Math.floor(s/60/60),i=Math.floor((s-e*60*60)/60),r=s%60;return`${mo(e)}:${mo(i)}:${mo(r)}`},Jo=s=>{const e=s.split(":"),i=e[e.length-3]?parseInt(e[e.length-3]):0,r=parseInt(e[e.length-2]),a=parseFloat(e[e.length-1]);return i*60*60+r*60+a},rT=s=>{const e=Math.floor(s/3600),i=Math.floor((s-e*3600)/60),r=Math.floor(s-e*3600-i*60);return`${e?`${e.toString().padStart(2,"0")}:`:""}${i.toString().padStart(2,"0")}:${r.toString().padStart(2,"0")}`},ri=(s,e)=>{const i=ta.find(r=>r.value===s);return(i==null?void 0:i[e])||""},sT=["title"],aT={class:"text"},oT={key:0,class:"tag-wrapper"},lT={class:"start-time"},uT={class:"calendar-info"},wh=n.defineComponent({__name:"OMeetingCalendarList",props:{list:{default:()=>[]}},setup(s){const e=s,{t:i,locale:r}=Ue.useI18n(),a=n.ref([]),o=O.useMessage(),l=async E=>{await a.value[E].copyInfo(),o.success({content:i("common.copySuccess")})},u=n.ref([]),d={SIG_GROUP:`${i("meeting.sigs")}: `,NEW_DATE:i("meeting.latestMeeting"),EMPTY_TEXT:i("meeting.meetingEmptyText"),LEARN_MORE:i("common.seeMore"),JOIN_MEETING:i("meeting.joinMeeting"),SIGN:i("meeting.sign")},f=n.ref(),g=new ResizeObserver(E=>{for(let x of E){const{height:B}=x.contentRect;x.target.classList.remove("hidden-divider"),B>=30&&x.target.classList.add("hidden-divider")}});n.watch(()=>e.list,()=>{e.list.length===1?u.value=[e.list[0].id]:u.value=[],n.nextTick(()=>{var E;(E=f.value)==null||E.forEach(x=>{g.observe(x)})})});const y=n.computed(()=>e.list.map(E=>{var A;const x=E.type;let B="";if(["events","summit"].includes(x))return B=`${hi(E.start_date,"YYYY/MM/DD HH:mm")} ${hi(E.end_date,"YYYY/MM/DD HH:mm")}`,{...E,dateRange:B};const{is_cycle:T,date:w,start:F,end:P,cycle_start_date:I,cycle_end_date:K,cycle_start:q,cycle_end:M,cycle_type:N,cycle_interval:J,cycle_point:b}=E;B=`${hi(w)} ${F} - ${P}`,T&&(B=`${hi(I)} - ${hi(K)}`);let C=`${F} - ${P}`,U=null,j=!1;const k=((A=E.obs_data)==null?void 0:A.filter($=>$.text_video_url))||[];if(T){let $="";N===mn&&($=i("meeting.cycleDay")),N===gn&&(J>1?$=i("meeting.cycleWeek.other",[Xn(N,b),J]):$=i("meeting.cycleWeek.one",[Xn(N,b)])),N===nn&&($=i("meeting.cycleMonth",[Xn(N,b)])),C=i("meeting.cycleMeetingText2",{startDate:I,endDate:K,startTime:q,endTime:M,cycleType:$}),j=k.some(Q=>{var H;return Q.sub_id===((H=E.cycle_sub.find(V=>V.date===w))==null?void 0:H.sub_id)})}else j=k.length>0;return j&&(U=`${location.origin}/${r.value}/video/${E.group_name}/${E.mid}/${w}`),{...E,dateRange:B,timeRange:C,replay_url:U}}));return(E,x)=>{var B,T;return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["o-meeting-calendar-list",(B=y.value)!=null&&B.length?"":"is-empty"])},[(T=y.value)!=null&&T.length?(n.openBlock(),n.createBlock(n.unref(O.OCollapse),{key:1,modelValue:u.value,"onUpdate:modelValue":x[0]||(x[0]=w=>u.value=w),style:{"--collapse-padding":"0"}},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(y.value,(w,F)=>(n.openBlock(),n.createBlock(n.unref(O.OCollapseItem),{key:w.id,value:w.id},{title:n.withCtx(()=>[n.createElementVNode("div",{class:"meet-title",title:w.topic||w.name},[n.createVNode(n.unref(O.OIcon),{style:n.normalizeStyle({backgroundColor:`${n.unref(ri)(w.type,"color")}`})},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(n.unref(ri)(w.type,"icon"))))]),_:2},1032,["style"]),n.createElementVNode("div",aT,n.toDisplayString(w.topic||w.name),1),w.is_cycle?(n.openBlock(),n.createElementBlock("div",oT,[n.createVNode(n.unref(O.OTag),{color:"primary",variant:"outline"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(i)("meeting.cycle")),1)]),_:1})])):n.createCommentVNode("",!0)],8,sT),n.createElementVNode("div",{class:"meet-info",ref_for:!0,ref_key:"meetInfoRef",ref:f},[n.createElementVNode("span",lT,[n.createElementVNode("span",null,n.toDisplayString(w.dateRange),1)]),n.createVNode(n.unref(O.ODivider),{direction:"v"}),n.createElementVNode("div",null,[w.group_name?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createTextVNode(n.toDisplayString(d.SIG_GROUP)+" "+n.toDisplayString(w.group_name),1)],64)):n.createCommentVNode("",!0),w.activity_type?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createTextVNode(n.toDisplayString(w.activity_type),1)],64)):n.createCommentVNode("",!0)])],512),w.url?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:0,href:w.url,target:"_blank",class:"jump-detail-link"},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(Ws))]),_:1})]),default:n.withCtx(()=>[n.createElementVNode("span",null,n.toDisplayString(d.LEARN_MORE),1)]),_:1},8,["href"])):n.createCommentVNode("",!0),w.join_url?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:1,href:w.join_url,target:"_blank",class:"jump-detail-link"},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(Ws))]),_:1})]),default:n.withCtx(()=>[n.createElementVNode("span",null,n.toDisplayString(d.JOIN_MEETING),1)]),_:1},8,["href"])):n.createCommentVNode("",!0),w.signUrl?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:2,href:w.signUrl,target:"_blank",class:"jump-detail-link"},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(Ws))]),_:1})]),default:n.withCtx(()=>[n.createElementVNode("span",null,n.toDisplayString(d.SIGN),1)]),_:1},8,["href"])):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OIcon),{onClick:n.withModifiers(()=>l(F),["stop"]),class:"copy-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(Eh))]),_:1},8,["onClick"])]),default:n.withCtx(()=>[n.createElementVNode("div",uT,[n.createVNode(Sh,{show:u.value.includes(w.id),data:w,ref_for:!0,ref:P=>a.value[F]=P,from:"home"},null,8,["show","data"])])]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])):n.renderSlot(E.$slots,"empty",{key:0})],2)}}}),cT={class:"o-meeting-calendar"},dT={class:"calendar-header"},hT={class:"calendar-body"},fT={class:"calender-header-left"},pT={class:"left-title"},mT={class:"month-date"},gT={class:"right-title"},_T=["onClick"],yT={class:"day-box"},vT={class:"icon-box"},TT={class:"detail-list"},bT={class:"current-day"},xT={class:"right-title"},CT={class:"title-list"},ST="2021-01-01",Ec=n.defineComponent({__name:"OMeetingCalendar",props:{getDateListRequest:{},getMeetingListRequest:{},getSummitListRequest:{default:async()=>[]},getEventsListRequest:{default:async()=>[]},hiddenEvents:{type:Boolean,default:!1},hiddenSummit:{type:Boolean,default:!1},createDesc:{}},emits:["create"],setup(s,{emit:e}){n.useCssVars(G=>({v3b57d20e:T.value}));const i=s,{t:r,locale:a}=Ue.useI18n(),o=n.computed(()=>a.value===Ue.Locales.EN);n.computed(()=>a.value===Ue.Locales.ZH);const l=n.ref(""),u=n.ref([]),d=n.ref([]),f=n.ref([]),g=n.ref([]),y=n.ref([]),E=n.ref(ta[0].value),x=n.computed(()=>{let G=ta;return i.hiddenEvents&&(G=G.filter(Z=>Z.value!==Ke.EVENTS)),i.hiddenSummit&&(G=G.filter(Z=>Z.value!==Ke.SUMMIT)),G.filter(Z=>Z.value!==Ke.ALL).length===1?[]:G});n.watch(()=>x.value,()=>{var G;E.value=((G=x.value[0])==null?void 0:G.value)??Ke.MEETING});const B=n.ref(),T=n.ref("407px"),w=n.ref(!1),F=n.ref(""),P=n.ref(""),I=n.ref([]),K=async G=>{i.getSummitListRequest?d.value=await i.getSummitListRequest(G):d.value=[]},q=async G=>{i.getEventsListRequest?f.value=await i.getEventsListRequest(G):f.value=[]},M=async G=>{i.getDateListRequest?u.value=await i.getDateListRequest(G):u.value=[]},N=async G=>{if(i.getMeetingListRequest&&G.date)try{const Z=await i.getMeetingListRequest(G.date,P.value);y.value=Z.map(te=>({...te,time:`${te.start}-${te.end}`,type:"meeting",date:te.date||G.date})).sort((te,se)=>{var ue,ce;return parseInt((ue=te.start||te.cycle_start)==null?void 0:ue.replace(":",""))-parseInt(se.end||((ce=se.cycle_end)==null?void 0:ce.replace(":","")))}),I.value=[...new Set(y.value.map(te=>te.group_name))].map(te=>({group_name:te})),I.value.find(te=>te.group_name===P.value)||(P.value="")}catch{y.value=[]}},J=n.computed(()=>[...y.value.filter(G=>!P.value||G.group_name===P.value),...f.value.filter(G=>G.dates.includes(F.value)),...d.value.filter(G=>G.dates.includes(F.value))].filter(G=>E.value==="all"?!0:G.type===E.value)),b=async G=>{const Z=Ee(G).format("YYYY-MM-DD");if(K(Z),q(Z),M(Z),g.value=[...new Set([...u.value,...d.value.map(te=>te.dates),...f.value.map(te=>te.dates)])].flat().sort((te,se)=>Ee(te).isAfter(Ee(se))?1:-1),!G)if(!g.value.length)l.value=hi(new Date);else{let te=[...g.value].reverse().find(se=>Ee().isAfter(Ee(se)));te||(te=g.value.find(se=>Ee(se).isAfter(Ee()))),l.value=hi(te)}N({date:Z,type:E.value}),F.value=Z};n.watch([()=>E.value,()=>x.value],()=>{C()});function C(){n.nextTick(()=>{N({date:F.value,type:E.value})})}function U(G,Z){if(new Date(G).getTime()/1e3<1610380800){Z==null||Z.stopPropagation();return}b(G)}const j=(G,Z)=>{if(hi(Z)===hi(ST)&&G==="prev-month"){w.value=!0;return}w.value=!1,B.value.selectDate(G),U(B.value.selectedDay)},k=G=>G.replace(/^0+(?=\d)/,""),A=G=>{new MutationObserver(function(){T.value=`${G.offsetHeight-2}px`}).observe(G,{childList:!0,subtree:!0,characterData:!0})};n.onMounted(()=>{const G=document.querySelector(".calendar-body .el-calendar__body");G&&(A(G),T.value=`${G.offsetHeight-2}px`),b()});const $=n.watch(()=>g.value.length,()=>{O.isClient&&n.nextTick(()=>{const G=document.querySelector(".is-today .out-box");G&&(G.click(),$())})}),Q=G=>o.value?G.split(" ").reverse().join(" "):G,H=e,V=()=>{H("create")};return(G,Z)=>(n.openBlock(),n.createElementBlock("div",cT,[n.createElementVNode("div",dT,[n.createElementVNode("span",null,n.toDisplayString(s.createDesc||""),1),n.createVNode(n.unref(O.OButton),{color:"primary",variant:"solid",round:"pill",onClick:V},{default:n.withCtx(()=>[...Z[3]||(Z[3]=[n.createTextVNode("预定会议",-1)])]),_:1})]),n.createElementVNode("div",hT,[n.createVNode(n.unref(et.ElCalendar),{ref_key:"calendar",ref:B,class:"calender"},{header:n.withCtx(({date:te})=>[n.createElementVNode("div",fT,[n.createElementVNode("div",pT,[n.createVNode(n.unref(O.OIcon),{onClick:se=>j("prev-month",te)},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronLeft),{class:n.normalizeClass({disable:w.value})},null,8,["class"])]),_:1},8,["onClick"]),n.createElementVNode("span",mT,n.toDisplayString(Q(te)),1),n.createVNode(n.unref(O.OIcon),{onClick:se=>j("next-month",te)},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1},8,["onClick"])]),n.createVNode(n.unref(O.OSelect),{modelValue:P.value,"onUpdate:modelValue":Z[0]||(Z[0]=se=>P.value=se),placeholder:n.unref(r)("meeting.allSigs"),clearable:""},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(I.value,se=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{value:se.group_name,key:se.group_name},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(se.group_name),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue","placeholder"])]),n.createElementVNode("div",gT,[n.createTextVNode(n.toDisplayString(n.unref(r)("meeting.latestMeeting"))+" ",1),n.createElementVNode("span",null,n.toDisplayString(n.unref(Ee)(l.value).format("YYYY/MM/DD")),1)])]),"date-cell":n.withCtx(({data:te})=>[n.createElementVNode("div",{class:n.normalizeClass(["out-box",{"has-calender":g.value.includes(te.day)}]),onClick:se=>U(te.day,se)},[n.createElementVNode("div",yT,[n.createElementVNode("p",{class:n.normalizeClass([te.isSelected?"is-selected":"","date-calender"])},n.toDisplayString(k(te.day.split("-").at(-1)||"")),3),n.createElementVNode("div",vT,[(E.value===n.unref(Ke).ALL||E.value===n.unref(Ke).MEETING)&&u.value.includes(te.day)?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0,class:"meeting",style:n.normalizeStyle({zIndex:n.unref(ri)(n.unref(Ke).MEETING,"zIndex"),backgroundColor:n.unref(ri)(n.unref(Ke).MEETING,"color")})},{default:n.withCtx(()=>[n.createVNode(n.unref(Al))]),_:1},8,["style"])):n.createCommentVNode("",!0),(E.value===n.unref(Ke).ALL||E.value===n.unref(Ke).EVENTS)&&f.value.some(se=>se.dates.includes(te.day))?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:1,class:"events",style:n.normalizeStyle({zIndex:n.unref(ri)(n.unref(Ke).EVENTS,"zIndex"),backgroundColor:n.unref(ri)(n.unref(Ke).EVENTS,"color")})},{default:n.withCtx(()=>[n.createVNode(n.unref(yh))]),_:1},8,["style"])):n.createCommentVNode("",!0),(E.value===n.unref(Ke).ALL||E.value===n.unref(Ke).SUMMIT)&&d.value.some(se=>se.dates.includes(te.day))?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:2,class:"summit",style:n.normalizeStyle({zIndex:n.unref(ri)(n.unref(Ke).SUMMIT,"zIndex"),backgroundColor:n.unref(ri)(n.unref(Ke).SUMMIT,"color")})},{default:n.withCtx(()=>[n.createVNode(n.unref(vh))]),_:1},8,["style"])):n.createCommentVNode("",!0)])])],10,_T)]),_:1},512),n.createElementVNode("div",TT,[n.createElementVNode("div",bT,[n.createTextVNode(n.toDisplayString(n.unref(r)("meeting.latestMeeting"))+" ",1),n.createElementVNode("span",null,n.toDisplayString(n.unref(Ee)(F.value).format("YYYY/MM/DD")),1)]),n.createElementVNode("div",xT,[n.createElementVNode("div",CT,[n.createVNode(n.unref(O.OSelect),{modelValue:P.value,"onUpdate:modelValue":Z[1]||(Z[1]=te=>P.value=te),placeholder:n.unref(r)("meeting.allSigs"),clearable:""},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(I.value,te=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{value:te.group_name,key:te.group_name},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(te.group_name),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue","placeholder"]),n.createVNode(n.unref(O.OTab),{modelValue:E.value,"onUpdate:modelValue":Z[2]||(Z[2]=te=>E.value=te),line:!1},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(x.value,te=>(n.openBlock(),n.createBlock(n.unref(O.OTabPane),{key:te.value,value:te.value},{nav:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(te.icon)))]),_:2},1024),n.createTextVNode(" "+n.toDisplayString(te.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])])]),n.createElementVNode("div",null,[n.createVNode(n.unref(O.OScroller),{class:"meeting-list","show-type":"hover",size:"small"},{default:n.withCtx(()=>[n.createVNode(wh,{list:J.value},{empty:n.withCtx(()=>[n.renderSlot(G.$slots,"empty")]),_:3},8,["list"])]),_:3})])])])]))}}),ET={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function kT(s,e){return n.openBlock(),n.createElementBlock("svg",ET,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.8",fill:"#000",d:"M16 0.371c1.623 0 3.214 0.248 4.731 0.729 0.59 0.187 0.916 0.817 0.729 1.406s-0.817 0.916-1.406 0.729c-1.299-0.412-2.662-0.624-4.054-0.624-7.394 0-13.389 5.994-13.389 13.389s5.994 13.389 13.389 13.389c7.394 0 13.389-5.994 13.389-13.389 0-4.287-2.027-8.235-5.402-10.747-0.496-0.369-0.599-1.071-0.23-1.567s1.071-0.599 1.567-0.23c3.937 2.931 6.305 7.541 6.305 12.544 0 8.632-6.997 15.629-15.629 15.629s-15.629-6.997-15.629-15.629c0-8.632 6.997-15.629 15.629-15.629zM16 22.816c1.002 0 1.814 0.812 1.814 1.814s-0.812 1.814-1.814 1.814c-1.002 0-1.814-0.812-1.814-1.814s0.812-1.814 1.814-1.814zM16.349 6.831c3.423 0 6.198 2.775 6.198 6.198 0 3.086-2.268 5.689-5.196 6.114-0.085 0.020-0.255 0.278-0.302 0.479 0 0-0.004 0.031-0.012 0.094v1.317c0 0.619-0.501 1.12-1.12 1.12-0.567 0-1.036-0.421-1.11-0.968 0 0-0.003-0.051-0.010-0.152v-1.317c0-1.154 0.814-2.461 2.133-2.77 1.929-0.283 3.378-1.946 3.378-3.916 0-2.186-1.772-3.958-3.958-3.958s-3.958 1.772-3.958 3.958c0 0.619-0.501 1.12-1.12 1.12s-1.12-0.501-1.12-1.12c0-3.423 2.775-6.198 6.198-6.198z"},null,-1)])])}const kc={name:"meeting-icon-help",render:kT},wT={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function DT(s,e){return n.openBlock(),n.createElementBlock("svg",wT,[...e[0]||(e[0]=[n.createElementVNode("path",{opacity:"0.6",fill:"#000",d:"M16.050 0.559c2.61 0 5.13 0.646 7.377 1.862 0.544 0.294 0.746 0.974 0.452 1.518s-0.974 0.746-1.518 0.452c-1.922-1.040-4.075-1.592-6.31-1.592-7.334 0-13.28 5.946-13.28 13.28s5.946 13.28 13.28 13.28c7.334 0 13.28-5.946 13.28-13.28 0-3.3-1.207-6.409-3.355-8.824-0.411-0.462-0.37-1.17 0.092-1.581s1.17-0.37 1.581 0.092c2.51 2.821 3.922 6.459 3.922 10.313 0 8.571-6.949 15.52-15.52 15.52s-15.52-6.949-15.52-15.52c0-8.571 6.949-15.52 15.52-15.52zM16.024 11.822c0.567 0.002 1.034 0.425 1.106 0.972l0.010 0.152-0.040 10.822c-0.002 0.619-0.506 1.118-1.124 1.116-0.567-0.002-1.034-0.425-1.106-0.972l-0.010-0.152 0.040-10.822c0.002-0.619 0.506-1.118 1.124-1.116zM16 7.232c1.001 0 1.813 0.812 1.813 1.813s-0.812 1.813-1.813 1.813c-1.001 0-1.813-0.812-1.813-1.813s0.812-1.813 1.813-1.813z"},null,-1)])])}const wc={name:"meeting-icon-tip",render:DT},AT=n.defineComponent({__name:"OMeetingCalendarSelector",props:{modelValue:{default:()=>[]},multiple:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(s,{emit:e}){const{t:i}=Ue.useI18n(),r=s,a=e,o=()=>{let T=[];for(let w=1;w<=31;w++)T.push(w);return T},l=n.computed(()=>o()),u=n.ref([]),d=n.ref([]),f=n.ref(null),g=()=>{u.value=[...r.modelValue],d.value=[...r.modelValue]};n.watchEffect(()=>{g()});const y=()=>{a("update:modelValue",d.value),f.value.expanded=!1},E=()=>{g(),f.value.expanded=!1},x=T=>{if(r.multiple){const w=d.value.indexOf(T);w===-1?d.value.push(T):d.value.splice(w,1),d.value.sort()}else d.value=[T],y()},B=T=>{r.multiple?x(T):d.value=[],y()};return(T,w)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["calendar-selector",!s.multiple&&"is-single"])},[n.createVNode(n.unref(et.ElSelect),{ref_key:"selectorRef",ref:f,"popper-class":"calendar-selector-popper",placeholder:n.unref(i)("meeting.selectRepeatDate"),size:"large",multiple:"",collapseTags:"",maxCollapseTags:"3",modelValue:u.value,onRemoveTag:B},n.createSlots({default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(l.value,F=>(n.openBlock(),n.createBlock(n.unref(et.ElOption),{key:F,label:F,value:F,onClick:P=>x(F),class:n.normalizeClass(d.value.includes(F)&&"is-checked")},null,8,["label","value","onClick","class"]))),128))]),_:2},[s.multiple?{name:"footer",fn:n.withCtx(()=>[n.createVNode(n.unref(O.OButton),{round:"pill",color:"primary",variant:"outline",onClick:y},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(i)("common.confirm")),1)]),_:1}),n.createVNode(n.unref(O.OButton),{variant:"text",onClick:E},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(i)("common.cancel")),1)]),_:1})]),key:"0"}:void 0]),1032,["placeholder","modelValue"])],2))}}),IT=Ue._export_sfc(AT,[["__scopeId","data-v-7b619c59"]]),NT={class:"o-meeting-form"},OT={class:"label-wrapper"},BT={class:"o-meeting-form-popover-content etherpad"},LT={class:"repeat-config-wrapper"},PT={class:"repeat-config"},MT={class:"repeat-config-item"},RT={class:"time-select-wrapper"},VT={key:1},FT={key:1,class:"switch-wrapper"},$T={class:"switch-text"},UT={key:1,class:"switch-wrapper"},qT={class:"switch-text"},jT={class:"label-wrapper"},HT={class:"o-meeting-form-popover-content"},zT=["href"],GT={key:0,class:"form-btns"},Dc=n.defineComponent({__name:"OMeetingForm",props:{data:{},isSub:{type:Boolean,default:!1},isEdit:{type:Boolean,default:!1},subId:{},createMeetingRequest:{},editMeetingRequest:{},editSubMeetingRequest:{},getPlatformsRequest:{},getGroupsRequest:{},showBtns:{type:Boolean,default:!0}},emits:["confirm","cancel"],setup(s,{expose:e,emit:i}){const{t:r,locale:a}=Ue.useI18n(),o=s,l=O.useMessage(),u=n.ref(by),d=n.ref(Ys),f=n.computed(()=>kh(y.value.cycle_type,u.value,"max")),g={is_record:!1,agenda:"",email_list:"",platform:"",topic:"",group_name:"",etherpad:"",date:"",date_range:[],start:"",end:"",time:"",is_cycle:!1,cycle_interval:1,cycle_type:mn,cycle_point:[]},y=n.ref(Object.assign({},g)),E=n.ref(null),x=n.ref(!1),B=n.ref({topic:[{required:!0,message:r("meeting.enterMeetingName")},{validator:j=>{if(j.length>128)return{type:"danger",message:r("meeting.meetingNameTooLong")}}}],agenda:[{validator:j=>{if(j.length>4096)return{type:"danger",message:r("meeting.meetingAgendaTooLong")}}}],group_name:[{required:!0,message:r("meeting.selectSig")}],etherpad:[{required:!0,message:r("meeting.enterEtherpad")}],date:[{required:!0,message:r("meeting.selectDate")}],time:[{validator:j=>{var Z;const{is_cycle:k,cycle_type:A,cycle_interval:$,cycle_point:Q,date:H,date_range:V}=y.value;if(k){const te={type:"danger",message:r("meeting.finishMeetingConfig")};if(A===mn&&!$||A===gn&&(!$||!(Q!=null&&Q.length))||A===nn&&(!$||!(Q!=null&&Q.length)))return te;if(!(V!=null&&V.length))return{type:"danger",message:r("meeting.selectMeetingDate")};const se=r("meeting.invalidMeetingDuration");let ue=V[0];const ce=V[1];if(A===gn){const de=new Set;for(;!Ee(ue).isAfter(Ee(ce));)de.add(Ee(ue).day()),ue=Ee(ue).add(1,"day");if(Q.every(qe=>!de.has(qe)))return{type:"danger",message:se}}if(A===nn){const de=new Set;for(;!Ee(ue).isAfter(Ee(ce));)de.add(Ee(ue).date()),ue=Ee(ue).add(1,"day");if(Q.every(qe=>!de.has(qe)))return{type:"danger",message:se}}}else if(!H)return{type:"danger",message:r("meeting.selectMeetingDate")};if(!((Z=j==null?void 0:j.trim())!=null&&Z.length))return{type:"danger",message:r("meeting.selectMeetingTime")};const G=j.split("-").map(te=>te.split(":").map(Number));if(G[0][0]>G[1][0]||G[0][0]===G[1][0]&&G[0][1]>=G[1][1])return{type:"danger",message:r("meeting.endTimeAfterStartTime")};if(!y.value.is_cycle&&y.value.date&&y.value.start){const te=Ee(`${y.value.date} ${y.value.start}`);if(new Date(te).getTime()<new Date().getTime())return{type:"danger",message:r("meeting.startTimeBeforeEndTime")}}},triggers:["blur","change"]}],platform:[{required:!0,message:r("meeting.selectPlatform")}],email_list:[{validator:j=>{if(o.isEdit)return{};const k=j.replaceAll(" ","")||"";if(k.length){if(k.length>1020)return{type:"danger",message:r("meeting.emailTooLong")};const A=k.split(";")||[];if(A.some($=>!bh.test($)))return{type:"danger",message:r("meeting.emailInvalid")};if(A.some($=>$.length>50))return{type:"danger",message:r("meeting.singleEmailTooLong")};if(A.length>20)return{type:"danger",message:r("meeting.emailCountTooLong")}}},triggers:["blur","change"]}]}),T=n.ref([]),w=async()=>{if(!o.getGroupsRequest)return;const j=await o.getGroupsRequest();T.value=j.map(k=>({label:k.group_name,value:k.group_name,...k})),o.data&&b(y.value.group_name)},F=n.ref([]),P=async()=>{if(!o.getPlatformsRequest)return;const j=await o.getPlatformsRequest();F.value=j.map(k=>({label:k,value:k})),o.data||(y.value.platform=F.value[0].value)},I=i;n.watch(()=>o.data,j=>{var k;if(j){const A=((k=j==null?void 0:j.cycle_sub)==null?void 0:k.find(Z=>Z.sub_id===o.subId))||{},{mid:$,date:Q,start:H,end:V,sub_id:G}=A;Object.assign(y.value,j,o.isSub?{is_cycle:!1,mid:$,date:Q,start:H,end:V,sub_id:G}:{})}else{const A=Ee().format("YYYY-MM-DD"),$=Ee().format("HH:mm");let Q="",H="";const V=Xr($);if(V<=Xr("08:00"))Q="08:00",H="09:00";else if(Xr("22:15")<=V)Q="08:00",H="09:00";else{let[Z,te]=$.split(":").map(Number);te>=45?(Z++,te=0):te=(Math.floor(te/15)+1)*15,Q=Sc(Z*60+te).slice(3),H=Sc(Z*60+te+60).slice(3)}const G=[Ee().format("YYYY-MM-DD"),Ee().add(1,"month").format("YYYY-MM-DD")];Object.assign(y.value,{date:A,start:Q,end:H,time:`${Q}-${H}`,date_range:G})}},{immediate:!0,deep:!0});const K=()=>{y.value=Object.assign({},g),E.value.clearValidate(),E.value.resetFields(),I("cancel")},q=()=>{y.value.cycle_point=[],y.value.cycle_interval=1},M=()=>{y.value.platform="WELINK"},{lePadV:N}=wt.useScreen(),J=async()=>{let j=o.isEdit?r("meeting.editSuccess"):r("meeting.booSuccess");try{if(x.value=!0,(await E.value.validate()).some(Me=>!!Me))return;const{topic:A,etherpad:$,group_name:Q,platform:H,date:V,start:G,end:Z,agenda:te,is_record:se,is_cycle:ue,date_range:ce,cycle_type:de,cycle_interval:qe,cycle_point:De}=y.value;let Oe={topic:A,etherpad:$,agenda:te,is_record:se,group_name:Q,platform:H,is_cycle:ue};if(ue?(Oe={...Oe,cycle_interval:qe,cycle_type:de,cycle_start_date:(ce==null?void 0:ce[0])||"",cycle_end_date:(ce==null?void 0:ce[1])||"",cycle_start:G,cycle_end:Z},de!==mn&&(Oe={...Oe,cycle_point:De.join(",")})):Oe={...Oe,date:(V==null?void 0:V.split(" ")[0])||"",start:G,end:Z},o.isEdit)if(o.isSub){const{mid:Me,sub_id:Se}=y.value,{date:me,start:ke,end:Ve}=Oe;await(o==null?void 0:o.editSubMeetingRequest(Se,{mid:Me,date:me,start:ke,end:Ve,is_notify:!0}))}else{const{email_list:Me,platform:Se,group_name:me,etherpad:ke,...Ve}=Oe;await(o==null?void 0:o.editMeetingRequest(o.data.id,{...Ve,is_notify:!0}))}else await(o==null?void 0:o.creatMeetingRequest({...Oe,email_list:y.value.email_list.replaceAll(" ","")}));const We=r("meeting.meetingHandleSuccess",[y.value.topic,j]);l.success({content:We}),I("confirm")}finally{x.value=!1}};n.onMounted(()=>{w(),P()});const b=j=>{const k=T.value.find(A=>A.value===j);o.isEdit||(y.value.etherpad=(k==null?void 0:k.etherpad)||"",y.value.email_list=(k==null?void 0:k.email_list)||"")},C=j=>j.getTime()<Date.now()-1440*60*1e3,U=()=>{y.value.start&&y.value.end?y.value.time=`${y.value.start}-${y.value.end}`:y.value.time=""};return e({confirm:J}),(j,k)=>(n.openBlock(),n.createElementBlock("div",NT,[n.createVNode(n.unref(O.OForm),{model:y.value,ref_key:"formRef",ref:E,"has-required":"",layout:n.unref(N)?"v":"h",class:"form-wrapper"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OFormItem),{rules:B.value.topic,label:n.unref(r)("meeting.meetingName"),field:"topic"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OInput),{disabled:s.isSub,size:"large",placeholder:n.unref(r)("meeting.enterMeetingName"),style:{width:"100%"},modelValue:y.value.topic,"onUpdate:modelValue":k[0]||(k[0]=A=>y.value.topic=A)},null,8,["disabled","placeholder","modelValue"])]),_:1},8,["rules","label"]),n.createVNode(n.unref(O.OFormItem),{rules:B.value.group_name,label:n.unref(r)("meeting.meetingSig"),field:"group_name"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OSelect),{disabled:s.isEdit,placeholder:n.unref(r)("meeting.selectSig"),size:"large",style:{width:"100%"},modelValue:y.value.group_name,"onUpdate:modelValue":k[1]||(k[1]=A=>y.value.group_name=A),onChange:b},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(T.value,A=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{key:A.value,value:A.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(A.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["disabled","placeholder","modelValue"])]),_:1},8,["rules","label"]),y.value.group_name?(n.openBlock(),n.createBlock(n.unref(O.OFormItem),{key:0,rules:B.value.etherpad,label:"Etherpad",field:"etherpad"},{label:n.withCtx(()=>[n.createElementVNode("div",OT,[k[17]||(k[17]=n.createElementVNode("span",null,"Etherpad ",-1)),n.createVNode(n.unref(O.OPopover),null,{target:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(kc))]),_:1})]),default:n.withCtx(()=>[n.createElementVNode("div",BT,n.toDisplayString(n.unref(r)("meeting.etherpadDesc")),1)]),_:1})])]),default:n.withCtx(()=>[n.createVNode(n.unref(O.OInput),{disabled:s.isEdit,size:"large",placeholder:n.unref(r)("meeting.enterEtherpad"),style:{width:"100%"},modelValue:y.value.etherpad,"onUpdate:modelValue":k[2]||(k[2]=A=>y.value.etherpad=A)},null,8,["disabled","placeholder","modelValue"])]),_:1},8,["rules"])):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OFormItem),{label:n.unref(r)("meeting.meetingTime"),field:"time",rules:B.value.time,class:"repeat-row",required:""},{default:n.withCtx(()=>[n.createElementVNode("div",LT,[s.isSub?n.createCommentVNode("",!0):(n.openBlock(),n.createBlock(n.unref(O.OFormItem),{key:0,field:"repeat",class:"repeat-item"},{default:n.withCtx(()=>[n.createVNode(n.unref(O.ORadioGroup),{modelValue:y.value.is_cycle,"onUpdate:modelValue":k[3]||(k[3]=A=>y.value.is_cycle=A),onChange:M,disabled:s.isEdit},{default:n.withCtx(()=>[n.createVNode(n.unref(O.ORadio),{value:!1},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(r)("meeting.nonRepeat")),1)]),_:1}),n.createVNode(n.unref(O.ORadio),{value:!0},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(r)("meeting.isRepeat")),1)]),_:1})]),_:1},8,["modelValue","disabled"])]),_:1})),n.createElementVNode("div",PT,[y.value.is_cycle?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createVNode(n.unref(O.OFormItem),{label:n.unref(r)("meeting.every"),class:"full-width-item"},{default:n.withCtx(()=>[n.createElementVNode("div",MT,[y.value.cycle_type!==n.unref(nn)?(n.openBlock(),n.createBlock(n.unref(O.OFormItem),{key:0},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElInputNumber),{size:"large",modelValue:y.value.cycle_interval,"onUpdate:modelValue":k[4]||(k[4]=A=>y.value.cycle_interval=A),min:1,max:f.value},null,8,["modelValue","max"])]),_:1})):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OFormItem),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OSelect),{size:"large",modelValue:y.value.cycle_type,"onUpdate:modelValue":k[5]||(k[5]=A=>y.value.cycle_type=A),class:"interval-select",optionWrapClass:"o-meeting-form-interval-select-options",onChange:q},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(u.value,A=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{key:A.value,value:A.value,label:A.label},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1})])]),_:1},8,["label"]),y.value.cycle_type!==n.unref(mn)?(n.openBlock(),n.createBlock(n.unref(O.OFormItem),{key:0,label:n.unref(r)("meeting.in"),field:"cycle_point",class:"point-item"},{default:n.withCtx(()=>[y.value.cycle_type===n.unref(gn)?(n.openBlock(),n.createBlock(n.unref(O.OSelect),{key:0,size:"large",multiple:"",modelValue:y.value.cycle_point,"onUpdate:modelValue":k[6]||(k[6]=A=>y.value.cycle_point=A),placeholder:n.unref(r)("meeting.selectRepeatDate"),"max-tag-count":1},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(d.value,A=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{key:A.value,value:A.value,label:A.label},null,8,["value","label"]))),128))]),_:1},8,["modelValue","placeholder"])):n.createCommentVNode("",!0),y.value.cycle_type===n.unref(nn)?(n.openBlock(),n.createBlock(IT,{key:1,modelValue:y.value.cycle_point,"onUpdate:modelValue":k[7]||(k[7]=A=>y.value.cycle_point=A)},null,8,["modelValue"])):n.createCommentVNode("",!0)]),_:1},8,["label"])):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OFormItem),{label:n.unref(r)("meeting.meetingDuration"),field:"date_range"},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElDatePicker),{size:"large",modelValue:y.value.date_range,"onUpdate:modelValue":k[8]||(k[8]=A=>y.value.date_range=A),"start-placeholder":n.unref(r)("meeting.startDate"),"end-placeholder":n.unref(r)("meeting.endDate"),style:{width:"100%"},"value-format":"YYYY-MM-DD","disabled-date":C,clearable:!1,type:"daterange","popper-class":"o-meeting-form-date-picker-popper"},null,8,["modelValue","start-placeholder","end-placeholder"])]),_:1},8,["label"])],64)):(n.openBlock(),n.createBlock(n.unref(O.OFormItem),{key:1,label:n.unref(r)("meeting.meetingDate"),field:"date"},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElDatePicker),{"popper-class":"o-meeting-form-date-picker-popper",size:"large",modelValue:y.value.date,"onUpdate:modelValue":k[9]||(k[9]=A=>y.value.date=A),placeholder:n.unref(r)("meeting.selectDate"),style:{width:"100%"},"value-format":"YYYY-MM-DD","disabled-date":C,clearable:!1},null,8,["modelValue","placeholder"])]),_:1},8,["label"])),n.createVNode(n.unref(O.OFormItem),{label:n.unref(r)("meeting.meetingTime")},{default:n.withCtx(()=>[n.createElementVNode("div",RT,[n.createVNode(n.unref(O.OFormItem),{field:"start"},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElTimeSelect),{"popper-class":"meeting-form-time-popover",step:"00:15",start:"08:00",end:"22:45",placeholder:n.unref(r)("meeting.startTime"),modelValue:y.value.start,"onUpdate:modelValue":k[10]||(k[10]=A=>y.value.start=A),size:"large",clearable:!1,onChange:U},null,8,["placeholder","modelValue"])]),_:1}),k[18]||(k[18]=n.createElementVNode("span",null,"-",-1)),n.createVNode(n.unref(O.OFormItem),{field:"end"},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElTimeSelect),{"popper-class":"meeting-form-time-popover",step:"00:15",start:"08:00",end:"22:45",placeholder:n.unref(r)("meeting.endTime"),modelValue:y.value.end,"onUpdate:modelValue":k[11]||(k[11]=A=>y.value.end=A),size:"large",clearable:!1,onChange:U},null,8,["placeholder","modelValue"])]),_:1}),n.createVNode(n.unref(O.OIconTime))])]),_:1},8,["label"])])])]),_:1},8,["label","rules"]),n.createVNode(n.unref(O.OFormItem),{label:n.unref(r)("meeting.meetingPlatform"),field:"platform",rules:B.value.platform},{default:n.withCtx(()=>[s.data?(n.openBlock(),n.createElementBlock("span",VT,n.toDisplayString(y.value.platform),1)):(n.openBlock(),n.createBlock(n.unref(O.ORadioGroup),{key:0,modelValue:y.value.platform,"onUpdate:modelValue":k[12]||(k[12]=A=>y.value.platform=A),disabled:y.value.is_cycle},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(F.value,A=>(n.openBlock(),n.createBlock(n.unref(O.ORadio),{key:A.value,value:A.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(A.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue","disabled"]))]),_:1},8,["label","rules"]),n.createVNode(n.unref(O.OFormItem),{field:"agenda",label:n.unref(r)("meeting.meetingAgenda"),rules:B.value.genda},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OTextarea),{disabled:s.isSub,size:"large",placeholder:n.unref(r)("meeting.enterMeetingAgenda"),style:{width:"100%"},rows:4,modelValue:y.value.agenda,"onUpdate:modelValue":k[13]||(k[13]=A=>y.value.agenda=A)},null,8,["disabled","placeholder","modelValue"])]),_:1},8,["label","rules"]),n.createVNode(n.unref(O.OFormItem),{label:n.unref(r)("meeting.meetingRecord"),field:"is_record",class:"record-item full-width-item"},{default:n.withCtx(()=>[n.unref(N)?(n.openBlock(),n.createBlock(n.unref(O.OSwitch),{key:0,modelValue:y.value.is_record,"onUpdate:modelValue":k[14]||(k[14]=A=>y.value.is_record=A),disabled:s.isSub},null,8,["modelValue","disabled"])):(n.openBlock(),n.createElementBlock("div",FT,[n.createVNode(n.unref(O.OSwitch),{modelValue:y.value.is_record,"onUpdate:modelValue":k[15]||(k[15]=A=>y.value.is_record=A),disabled:s.isSub},null,8,["modelValue","disabled"]),n.createElementVNode("div",$T,[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(wc))]),_:1}),n.createElementVNode("span",null,n.toDisplayString(n.unref(r)("meeting.meetingRecordDesc",[y.value.platform])),1)])]))]),_:1},8,["label"]),n.unref(N)?(n.openBlock(),n.createElementBlock("div",UT,[n.createElementVNode("div",qT,[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(wc))]),_:1}),n.createElementVNode("span",null,n.toDisplayString(n.unref(r)("meeting.meetingRecordDesc",[y.value.platform])),1)])])):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OFormItem),{field:"email_list",rules:B.value.email_list},{label:n.withCtx(()=>[n.createElementVNode("div",jT,[n.createElementVNode("span",null,n.toDisplayString(n.unref(r)("meeting.meetingEmail"))+" ",1),n.createVNode(n.unref(O.OPopover),null,{target:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(kc))]),_:1})]),default:n.withCtx(()=>[n.createElementVNode("div",HT,[n.createTextVNode(n.toDisplayString(n.unref(r)("meeting.meetingEmailDesc"))+" ",1),n.createElementVNode("a",{class:"link-text",href:`/${n.unref(a)}/sig`},n.toDisplayString(n.unref(r)("meeting.sigGroupEmail")),9,zT)])]),_:1})])]),default:n.withCtx(()=>[n.createVNode(n.unref(O.OTextarea),{disabled:s.isEdit,size:"large",placeholder:n.unref(r)("meeting.enterEmail"),style:{width:"100%"},rows:4,modelValue:y.value.email_list,"onUpdate:modelValue":k[16]||(k[16]=A=>y.value.email_list=A)},null,8,["disabled","placeholder","modelValue"])]),_:1},8,["rules"])]),_:1},8,["model","layout"]),s.showBtns?(n.openBlock(),n.createElementBlock("div",GT,[n.createVNode(n.unref(O.OButton),{color:"primary",variant:"solid",size:"large",onClick:J,loading:x.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(s.isEdit?n.unref(r)("common.save"):n.unref(r)("meeting.book")),1)]),_:1},8,["loading"]),n.createVNode(n.unref(O.OButton),{color:"primary",variant:"outline",size:"large",onClick:K},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(r)("common.cancel")),1)]),_:1})])):n.createCommentVNode("",!0)]))}}),WT={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function YT(s,e){return n.openBlock(),n.createElementBlock("svg",WT,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"#0071f3",d:"M9.669 4.029l-0.034-0.034c0-0.48 0.377-0.857 0.857-0.857s0.857 0.377 0.857 0.857l-0.034 0.034h-1.646zM12.669 7.526l-0.034-0.034c0-0.48 0.377-0.857 0.857-0.857s0.857 0.377 0.857 0.857l-0.034 0.034h-1.646zM6.669 8.52l-0.034-0.034c0-0.48 0.377-0.857 0.857-0.857s0.857 0.377 0.857 0.857l-0.034 0.034h-1.646zM15.669 9.531l-0.034-0.034c0-0.48 0.377-0.857 0.857-0.857s0.857 0.377 0.857 0.857l-0.034 0.034h-1.646zM3.669 11.023l-0.034-0.034c0-0.48 0.377-0.857 0.857-0.857s0.857 0.377 0.857 0.857l-0.034 0.034h-1.646zM18.669 11.777l-0.034-0.034c0-0.48 0.377-0.857 0.857-0.857s0.857 0.377 0.857 0.857l-0.034 0.034h-1.646zM20.349 13.234l-0.034-0.034h-1.646l-0.034 0.034c0 0.48 0.377 0.857 0.857 0.857s0.857-0.377 0.857-0.857zM5.349 13.989l-0.034-0.034h-1.646l-0.034 0.034c0 0.48 0.377 0.857 0.857 0.857s0.857-0.377 0.857-0.857zM17.349 15.497l-0.034-0.034h-1.646l-0.034 0.034c0 0.48 0.377 0.857 0.857 0.857s0.857-0.377 0.857-0.857zM8.349 16.474l-0.034-0.034h-1.646l-0.034 0.034c0 0.48 0.377 0.857 0.857 0.857s0.857-0.377 0.857-0.857zM14.349 17.486l-0.034-0.034h-1.646l-0.034 0.034c0 0.48 0.377 0.857 0.857 0.857s0.857-0.377 0.857-0.857zM11.349 20.486l-0.034-0.034h-1.646l-0.034 0.034c0 0.48 0.377 0.857 0.857 0.857s0.857-0.377 0.857-0.857z"},null,-1),n.createElementVNode("path",{fill:"none",stroke:"#0071f3","stroke-linejoin":"round","stroke-linecap":"round","stroke-miterlimit":"4","stroke-width":"1.71",d:"M4.491 10.989v3M7.491 8.486v7.989M10.491 3.994v16.491M13.491 7.491v9.994M16.491 9.497v6M19.491 11.743v1.491"},null,-1),n.createElementVNode("path",{fill:"#0071f3",d:"M22.491 12.994c0.274 0 0.497-0.223 0.497-0.497s-0.223-0.497-0.497-0.497c-0.274 0-0.497 0.223-0.497 0.497s0.223 0.497 0.497 0.497zM1.491 12.994c0.274 0 0.497-0.223 0.497-0.497s-0.223-0.497-0.497-0.497c-0.274 0-0.497 0.223-0.497 0.497s0.223 0.497 0.497 0.497z"},null,-1)])])}const XT={name:"meeting-icon-playing",render:YT},KT={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32"};function QT(s,e){return n.openBlock(),n.createElementBlock("svg",KT,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M23.399 22.031l0.116 0.099 3.68 3.672c0.365 0.364 0.365 0.955 0.001 1.32-0.328 0.328-0.839 0.361-1.204 0.1l-0.116-0.099-3.68-3.672c-0.365-0.364-0.365-0.955-0.001-1.32 0.328-0.328 0.839-0.361 1.204-0.1zM14.428 4.605c5.465 0 9.897 4.431 9.897 9.897s-4.431 9.897-9.897 9.897c-5.465 0-9.897-4.431-9.897-9.897s4.431-9.897 9.897-9.897zM14.428 6.472c-4.435 0-8.031 3.595-8.031 8.031s3.595 8.031 8.031 8.031c4.435 0 8.031-3.595 8.031-8.031s-3.595-8.031-8.031-8.031z"},null,-1)])])}const ZT={name:"components-icon-search",render:QT},JT={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function eb(s,e){return n.openBlock(),n.createElementBlock("svg",JT,[...e[0]||(e[0]=[n.createElementVNode("path",{fill:"currentColor",d:"M5.759 15.127c0.251 0.251 0.644 0.271 0.918 0.063l0.072-0.063 5.016-5.016c0.1-0.1 0.254-0.115 0.37-0.043l0.054 0.043 5.062 5.062c0.273 0.273 0.717 0.273 0.99 0 0.251-0.251 0.271-0.644 0.063-0.918l-0.063-0.072-5.062-5.062c-0.629-0.629-1.628-0.662-2.296-0.099l-0.108 0.099-5.016 5.016c-0.273 0.273-0.273 0.717 0 0.99z"},null,-1)])])}const tb={name:"components-icon-chevron-up",render:eb},ib={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function nb(s,e){return n.openBlock(),n.createElementBlock("svg",ib,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M3.42 6.060c0-2.52 2.040-4.575 4.575-4.575 2.52 0 4.575 2.055 4.575 4.575s-2.055 4.575-4.575 4.575c-2.535 0-4.575-2.055-4.575-4.575zM15.015 10.47c0-1.8 1.455-3.27 3.255-3.27 1.815 0 3.27 1.47 3.27 3.27s-1.455 3.27-3.27 3.27c-1.8 0-3.255-1.47-3.255-3.27zM4.56 12.915h6.855c2.535 0 4.575 2.055 4.575 4.575 0 0.255-0.015 0.51-0.060 0.75-0.36 2.16-2.235 3.825-4.515 3.825h-6.855c-2.52 0-4.575-2.055-4.575-4.575s2.055-4.575 4.575-4.575zM17.595 17.49c0-0.75-0.135-1.455-0.375-2.115h3.51c1.8 0 3.255 1.455 3.255 3.255s-1.455 3.27-3.255 3.27h-4.995c1.155-1.125 1.86-2.685 1.86-4.41z"},null,-1)])])}const rb={name:"meeting-icon-speaker",render:nb},sb={class:"o-meeting-playback-subtitles"},ab={class:"search-captions"},ob={key:0,class:"suffix-box"},lb={class:"right-handle"},ub=["onClick"],cb={class:"info"},db={class:"num"},hb={class:"speaker"},fb={class:"start-time"},pb={class:"text"},mb={key:1},gb=n.defineComponent({__name:"OMeetingPlaybackSubtitles",props:{captions:{default:()=>[]},instance:{},trackIdx:{}},setup(s){const e=Il(),i=s,{t:r}=Ue.useI18n(),a=n.computed(()=>i.trackIdx),o=n.ref(),l=n.ref(!1),u=()=>{l.value=!0},d=Mn.useDebounceFn(()=>{l.value=!1},3e3);n.watch(()=>l.value,k=>{k&&d()});const f=n.ref([]);n.watch(()=>i.captions,()=>{f.value=i.captions||[],n.nextTick(()=>{var k;o.value&&((k=o.value)==null||k.scrollTo({top:0,behavior:"smooth"}))})},{immediate:!0,deep:!0});const g=k=>`00:${k.split(".")[0]}`.slice(-8),y=k=>{const A=k.split(":"),$=A[A.length-3]?parseInt(A[A.length-3]):0,Q=parseInt(A[A.length-2]),H=parseFloat(A[A.length-1]);return $*60*60+Q*60+H};n.onMounted(()=>{var k;o.value=document.querySelector("#captionsScrollDom > .o-scroller-container"),(k=o.value)==null||k.addEventListener("wheel",u)}),n.watch(()=>f.value,()=>{var k;o.value=document.querySelector("#captionsScrollDom > .o-scroller-container"),(k=o.value)==null||k.addEventListener("wheel",u)});const E=n.ref(0),x=()=>{},B=k=>{const A=i.instance;if(!A)return;const $=y(k);A.currentTime($)},T=n.ref(""),w=n.ref(0),F=n.ref(0),P=n.ref([]),I=r("common.all"),K=n.computed(()=>[...new Set(i.captions.map(k=>k.speakerLabel).sort().reverse())]);n.watch(()=>a.value,()=>{var A,$;if(l.value&&T.value)return;const k=(A=o.value)==null?void 0:A.querySelectorAll(".captions-item")[a.value-1];($=o.value)==null||$.scrollTo({top:(k==null?void 0:k.offsetTop)-16,behavior:"smooth"})}),n.onUnmounted(()=>{o.value&&o.value.removeEventListener("wheel",u)});const q=(k,A)=>{var G,Z,te,se,ue,ce;const $=document.getElementsByClassName("light-keyword")[k-1],Q=document.getElementsByClassName("light-keyword")[k-A];Q==null||Q.classList.remove("light-keyword-active"),$==null||$.classList.add("light-keyword-active");const H=$.offsetTop+$.offsetHeight<((G=o.value)==null?void 0:G.scrollTop),V=$.offsetTop>((Z=o.value)==null?void 0:Z.offsetHeight)+((te=o.value)==null?void 0:te.scrollTop);(H||V)&&((ce=o.value)==null||ce.scrollTo({top:(ue=(se=$.parentElement)==null?void 0:se.parentElement)==null?void 0:ue.offsetTop,behavior:"smooth"}))},M=()=>{!w.value||F.value===1||(F.value--,q(F.value,0))},N=k=>{k!=null&&k.shiftKey||!w.value||F.value===w.value||(F.value++,q(F.value,2))},J=k=>{f.value=i.captions.filter(A=>P.value.includes(A.speakerLabel)).map(A=>({...A,contentHtml:k?A.contentHtml.replaceAll(k,`<span class="light-keyword">${k}</span>`):A.contentHtml})),n.nextTick(()=>{var $;const A=document.getElementsByClassName("light-keyword");w.value=A.length,w.value?N():($=o.value)==null||$.scrollTo({top:0,behavior:"smooth"})})},b=Mn.useDebounceFn(J,300);n.watch(()=>T.value,k=>{F.value=0,b(k)}),n.watch(()=>K.value,k=>{P.value=k},{immediate:!0});const C=n.ref(!1),U=n.ref(!1),j=k=>{U.value=!1,k?P.value=K.value:P.value=[]};return n.watch(()=>P.value,k=>{k.length===0?(C.value=!1,U.value=!1):k.length===K.value.length?(C.value=!0,U.value=!1):U.value=!0,b(T.value)},{deep:!0}),(k,A)=>(n.openBlock(),n.createElementBlock("div",sb,[n.createElementVNode("div",ab,[n.createVNode(n.unref(O.OInput),{modelValue:T.value,"onUpdate:modelValue":A[1]||(A[1]=$=>T.value=$),onKeydown:[n.withKeys(N,["enter"]),n.withKeys(n.withModifiers(M,["shift","stop"]),["enter"])],placeholder:n.unref(r)("meeting.searchSubtitlePlaceholder"),size:"large",class:"input-captions"},{prefix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(ZT))]),_:1})]),suffix:n.withCtx(()=>[T.value?(n.openBlock(),n.createElementBlock("div",ob,[n.createElementVNode("span",null,n.toDisplayString(F.value)+"/"+n.toDisplayString(w.value),1),n.createVNode(n.unref(O.OIcon),{onClick:M},{default:n.withCtx(()=>[n.createVNode(n.unref(tb))]),_:1}),n.createVNode(n.unref(O.OIcon),{onClick:N},{default:n.withCtx(()=>[n.createVNode(n.unref(Dl))]),_:1}),n.createVNode(n.unref(O.ODivider),{direction:"v"}),n.createVNode(n.unref(O.OIcon),{class:"hover-close",onClick:A[0]||(A[0]=$=>T.value="")},{default:n.withCtx(()=>[n.createVNode(n.unref(wl))]),_:1})])):n.createCommentVNode("",!0)]),_:1},8,["modelValue","onKeydown","placeholder"]),n.createElementVNode("div",lb,[n.createVNode(n.unref(et.ElSelect),{multiple:"",modelValue:P.value,"onUpdate:modelValue":A[3]||(A[3]=$=>P.value=$),"popper-class":"speakers-selector-popper",class:"speakers-selector",placement:"bottom"},{prefix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(rb))]),_:1})]),header:n.withCtx(()=>[n.createVNode(n.unref(et.ElCheckbox),{modelValue:C.value,"onUpdate:modelValue":A[2]||(A[2]=$=>C.value=$),indeterminate:U.value,onChange:j},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(I)),1)]),_:1},8,["modelValue","indeterminate"])]),default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(K.value,$=>(n.openBlock(),n.createBlock(n.unref(et.ElOption),{key:$,label:$,value:$},{default:n.withCtx(()=>[n.createVNode(n.unref(et.ElCheckbox),{"model-value":P.value.includes($)},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString($),1)]),_:2},1032,["model-value"])]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue"])])]),n.createVNode(n.unref(O.OTab),{modelValue:E.value,"onUpdate:modelValue":A[4]||(A[4]=$=>E.value=$),variant:"text",class:"captions-tab",onChange:x},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OTabPane),{value:0,label:n.unref(r)("meeting.audioToText")},{default:n.withCtx(()=>[f.value.length?(n.openBlock(),n.createBlock(n.unref(O.OScroller),{key:0,id:"captionsScrollDom",class:"captions-scroller","show-type":"hover",size:"small","disabled-x":""},{default:n.withCtx(()=>[n.createVNode(n.unref(O.ORow),{gap:"0 12px",wrap:"wrap"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(f.value,($,Q)=>(n.openBlock(),n.createBlock(n.unref(O.OCol),{flex:"0 0 100%",key:Q},{default:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(["captions-item",{"captions-item-active":a.value===Q+1}]),onClick:H=>B($.start_time)},[n.createElementVNode("div",cb,[n.createElementVNode("div",db,n.toDisplayString($.speakerIdx),1),n.createElementVNode("div",hb,n.toDisplayString($.speakerLabel),1),n.createElementVNode("div",fb,n.toDisplayString(g($.start_time)),1),a.value===Q+1?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0,class:"playing initial-fill"},{default:n.withCtx(()=>[n.createVNode(n.unref(XT))]),_:1})):n.createCommentVNode("",!0)]),n.withDirectives(n.createElementVNode("div",pb,null,512),[[n.unref(e),$.contentHtml]])],10,ub)]),_:2},1024))),128))]),_:1})]),_:1})):(n.openBlock(),n.createElementBlock("div",mb,"111"))]),_:1},8,["label"])]),_:1},8,["modelValue"])]))}});var go,Ac;function Sa(){if(Ac)return go;Ac=1;var s;return typeof window<"u"?s=window:typeof na<"u"?s=na:typeof self<"u"?s=self:s={},go=s,go}var _b=Sa();const W=pr(_b),yb={},vb=Object.freeze(Object.defineProperty({__proto__:null,default:yb},Symbol.toStringTag,{value:"Module"})),Tb=U3(vb);var _o,Ic;function Dh(){if(Ic)return _o;Ic=1;var s=typeof na<"u"?na:typeof window<"u"?window:{},e=Tb,i;return typeof document<"u"?i=document:(i=s["__GLOBAL_DOCUMENT_CACHE@4"],i||(i=s["__GLOBAL_DOCUMENT_CACHE@4"]=e)),_o=i,_o}var bb=Dh();const pe=pr(bb);var Fs={exports:{}},yo={exports:{}},Nc;function xb(){return Nc||(Nc=1,(function(s){function e(){return s.exports=e=Object.assign?Object.assign.bind():function(i){for(var r=1;r<arguments.length;r++){var a=arguments[r];for(var o in a)({}).hasOwnProperty.call(a,o)&&(i[o]=a[o])}return i},s.exports.__esModule=!0,s.exports.default=s.exports,e.apply(null,arguments)}s.exports=e,s.exports.__esModule=!0,s.exports.default=s.exports})(yo)),yo.exports}var vo,Oc;function Cb(){if(Oc)return vo;Oc=1,vo=e;var s=Object.prototype.toString;function e(i){if(!i)return!1;var r=s.call(i);return r==="[object Function]"||typeof i=="function"&&r!=="[object RegExp]"||typeof window<"u"&&(i===window.setTimeout||i===window.alert||i===window.confirm||i===window.prompt)}return vo}var To,Bc;function Sb(){if(Bc)return To;Bc=1;function s(a,o){var l=typeof Symbol<"u"&&a[Symbol.iterator]||a["@@iterator"];if(l)return(l=l.call(a)).next.bind(l);if(Array.isArray(a)||(l=e(a))||o){l&&(a=l);var u=0;return function(){return u>=a.length?{done:!0}:{done:!1,value:a[u++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
6
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function e(a,o){if(a){if(typeof a=="string")return i(a,o);var l=Object.prototype.toString.call(a).slice(8,-1);if(l==="Object"&&a.constructor&&(l=a.constructor.name),l==="Map"||l==="Set")return Array.from(a);if(l==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l))return i(a,o)}}function i(a,o){(o==null||o>a.length)&&(o=a.length);for(var l=0,u=new Array(o);l<o;l++)u[l]=a[l];return u}var r=(function(){function a(){this.typeToInterceptorsMap_=new Map,this.enabled_=!1}var o=a.prototype;return o.getIsEnabled=function(){return this.enabled_},o.enable=function(){this.enabled_=!0},o.disable=function(){this.enabled_=!1},o.reset=function(){this.typeToInterceptorsMap_=new Map,this.enabled_=!1},o.addInterceptor=function(u,d){this.typeToInterceptorsMap_.has(u)||this.typeToInterceptorsMap_.set(u,new Set);var f=this.typeToInterceptorsMap_.get(u);return f.has(d)?!1:(f.add(d),!0)},o.removeInterceptor=function(u,d){var f=this.typeToInterceptorsMap_.get(u);return f&&f.has(d)?(f.delete(d),!0):!1},o.clearInterceptorsByType=function(u){var d=this.typeToInterceptorsMap_.get(u);return d?(this.typeToInterceptorsMap_.delete(u),this.typeToInterceptorsMap_.set(u,new Set),!0):!1},o.clear=function(){return this.typeToInterceptorsMap_.size?(this.typeToInterceptorsMap_=new Map,!0):!1},o.getForType=function(u){return this.typeToInterceptorsMap_.get(u)||new Set},o.execute=function(u,d){for(var f=this.getForType(u),g=s(f),y;!(y=g()).done;){var E=y.value;try{d=E(d)}catch{}}return d},a})();return To=r,To}var bo,Lc;function Eb(){if(Lc)return bo;Lc=1;var s=(function(){function i(){this.maxAttempts_=1,this.delayFactor_=.1,this.fuzzFactor_=.1,this.initialDelay_=1e3,this.enabled_=!1}var r=i.prototype;return r.getIsEnabled=function(){return this.enabled_},r.enable=function(){this.enabled_=!0},r.disable=function(){this.enabled_=!1},r.reset=function(){this.maxAttempts_=1,this.delayFactor_=.1,this.fuzzFactor_=.1,this.initialDelay_=1e3,this.enabled_=!1},r.getMaxAttempts=function(){return this.maxAttempts_},r.setMaxAttempts=function(o){this.maxAttempts_=o},r.getDelayFactor=function(){return this.delayFactor_},r.setDelayFactor=function(o){this.delayFactor_=o},r.getFuzzFactor=function(){return this.fuzzFactor_},r.setFuzzFactor=function(o){this.fuzzFactor_=o},r.getInitialDelay=function(){return this.initialDelay_},r.setInitialDelay=function(o){this.initialDelay_=o},r.createRetry=function(o){var l=o===void 0?{}:o,u=l.maxAttempts,d=l.delayFactor,f=l.fuzzFactor,g=l.initialDelay;return new e({maxAttempts:u||this.maxAttempts_,delayFactor:d||this.delayFactor_,fuzzFactor:f||this.fuzzFactor_,initialDelay:g||this.initialDelay_})},i})(),e=(function(){function i(a){this.maxAttempts_=a.maxAttempts,this.delayFactor_=a.delayFactor,this.fuzzFactor_=a.fuzzFactor,this.currentDelay_=a.initialDelay,this.currentAttempt_=1}var r=i.prototype;return r.moveToNextAttempt=function(){this.currentAttempt_++;var o=this.currentDelay_*this.delayFactor_;this.currentDelay_=this.currentDelay_+o},r.shouldRetry=function(){return this.currentAttempt_<this.maxAttempts_},r.getCurrentDelay=function(){return this.currentDelay_},r.getCurrentMinPossibleDelay=function(){return(1-this.fuzzFactor_)*this.currentDelay_},r.getCurrentMaxPossibleDelay=function(){return(1+this.fuzzFactor_)*this.currentDelay_},r.getCurrentFuzzedDelay=function(){var o=this.getCurrentMinPossibleDelay(),l=this.getCurrentMaxPossibleDelay();return o+Math.random()*(l-o)},i})();return bo=s,bo}var xo,Pc;function kb(){if(Pc)return xo;Pc=1;var s=Sa(),e=function(a,o){return o===void 0&&(o=!1),function(l,u,d){if(l){a(l);return}if(u.statusCode>=400&&u.statusCode<=599){var f=d;if(o)if(s.TextDecoder){var g=i(u.headers&&u.headers["content-type"]);try{f=new TextDecoder(g).decode(d)}catch{}}else f=String.fromCharCode.apply(null,new Uint8Array(d));a({cause:f});return}a(null,d)}};function i(r){return r===void 0&&(r=""),r.toLowerCase().split(";").reduce(function(a,o){var l=o.split("="),u=l[0],d=l[1];return u.trim()==="charset"?d.trim():a},"utf-8")}return xo=e,xo}var Mc;function wb(){if(Mc)return Fs.exports;Mc=1;var s=Sa(),e=xb(),i=Cb(),r=Sb(),a=Eb();f.httpHandler=kb(),f.requestInterceptorsStorage=new r,f.responseInterceptorsStorage=new r,f.retryManager=new a;/**
|
|
7
|
+
* @license
|
|
8
|
+
* slighly modified parse-headers 2.0.2 <https://github.com/kesla/parse-headers/>
|
|
9
|
+
* Copyright (c) 2014 David Björklund
|
|
10
|
+
* Available under the MIT license
|
|
11
|
+
* <https://github.com/kesla/parse-headers/blob/master/LICENCE>
|
|
12
|
+
*/var o=function(B){var T={};return B&&B.trim().split(`
|
|
13
|
+
`).forEach(function(w){var F=w.indexOf(":"),P=w.slice(0,F).trim().toLowerCase(),I=w.slice(F+1).trim();typeof T[P]>"u"?T[P]=I:Array.isArray(T[P])?T[P].push(I):T[P]=[T[P],I]}),T};Fs.exports=f,Fs.exports.default=f,f.XMLHttpRequest=s.XMLHttpRequest||E,f.XDomainRequest="withCredentials"in new f.XMLHttpRequest?f.XMLHttpRequest:s.XDomainRequest,l(["get","put","post","patch","head","delete"],function(x){f[x==="delete"?"del":x]=function(B,T,w){return T=d(B,T,w),T.method=x.toUpperCase(),g(T)}});function l(x,B){for(var T=0;T<x.length;T++)B(x[T])}function u(x){for(var B in x)if(x.hasOwnProperty(B))return!1;return!0}function d(x,B,T){var w=x;return i(B)?(T=B,typeof x=="string"&&(w={uri:x})):w=e({},B,{uri:x}),w.callback=T,w}function f(x,B,T){return B=d(x,B,T),g(B)}function g(x){if(typeof x.callback>"u")throw new Error("callback argument missing");if(x.requestType&&f.requestInterceptorsStorage.getIsEnabled()){var B={uri:x.uri||x.url,headers:x.headers||{},body:x.body,metadata:x.metadata||{},retry:x.retry,timeout:x.timeout},T=f.requestInterceptorsStorage.execute(x.requestType,B);x.uri=T.uri,x.headers=T.headers,x.body=T.body,x.metadata=T.metadata,x.retry=T.retry,x.timeout=T.timeout}var w=!1,F=function(V,G,Z){w||(w=!0,x.callback(V,G,Z))};function P(){M.readyState===4&&!f.responseInterceptorsStorage.getIsEnabled()&&setTimeout(q,0)}function I(){var H=void 0;if(M.response?H=M.response:H=M.responseText||y(M),A)try{H=JSON.parse(H)}catch{}return H}function K(H){if(clearTimeout($),clearTimeout(x.retryTimeout),H instanceof Error||(H=new Error(""+(H||"Unknown XMLHttpRequest Error"))),H.statusCode=0,!J&&f.retryManager.getIsEnabled()&&x.retry&&x.retry.shouldRetry()){x.retryTimeout=setTimeout(function(){x.retry.moveToNextAttempt(),x.xhr=M,g(x)},x.retry.getCurrentFuzzedDelay());return}if(x.requestType&&f.responseInterceptorsStorage.getIsEnabled()){var V={headers:Q.headers||{},body:Q.body,responseUrl:M.responseURL,responseType:M.responseType},G=f.responseInterceptorsStorage.execute(x.requestType,V);Q.body=G.body,Q.headers=G.headers}return F(H,Q)}function q(){if(!J){var H;clearTimeout($),clearTimeout(x.retryTimeout),x.useXDR&&M.status===void 0?H=200:H=M.status===1223?204:M.status;var V=Q,G=null;if(H!==0?(V={body:I(),statusCode:H,method:C,headers:{},url:b,rawRequest:M},M.getAllResponseHeaders&&(V.headers=o(M.getAllResponseHeaders()))):G=new Error("Internal XMLHttpRequest Error"),x.requestType&&f.responseInterceptorsStorage.getIsEnabled()){var Z={headers:V.headers||{},body:V.body,responseUrl:M.responseURL,responseType:M.responseType},te=f.responseInterceptorsStorage.execute(x.requestType,Z);V.body=te.body,V.headers=te.headers}return F(G,V,V.body)}}var M=x.xhr||null;M||(x.cors||x.useXDR?M=new f.XDomainRequest:M=new f.XMLHttpRequest);var N,J,b=M.url=x.uri||x.url,C=M.method=x.method||"GET",U=x.body||x.data,j=M.headers=x.headers||{},k=!!x.sync,A=!1,$,Q={body:void 0,headers:{},statusCode:0,method:C,url:b,rawRequest:M};if("json"in x&&x.json!==!1&&(A=!0,j.accept||j.Accept||(j.Accept="application/json"),C!=="GET"&&C!=="HEAD"&&(j["content-type"]||j["Content-Type"]||(j["Content-Type"]="application/json"),U=JSON.stringify(x.json===!0?U:x.json))),M.onreadystatechange=P,M.onload=q,M.onerror=K,M.onprogress=function(){},M.onabort=function(){J=!0,clearTimeout(x.retryTimeout)},M.ontimeout=K,M.open(C,b,!k,x.username,x.password),k||(M.withCredentials=!!x.withCredentials),!k&&x.timeout>0&&($=setTimeout(function(){if(!J){J=!0,M.abort("timeout");var H=new Error("XMLHttpRequest timeout");H.code="ETIMEDOUT",K(H)}},x.timeout)),M.setRequestHeader)for(N in j)j.hasOwnProperty(N)&&M.setRequestHeader(N,j[N]);else if(x.headers&&!u(x.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in x&&(M.responseType=x.responseType),"beforeSend"in x&&typeof x.beforeSend=="function"&&x.beforeSend(M),M.send(U||null),M}function y(x){try{if(x.responseType==="document")return x.responseXML;var B=x.responseXML&&x.responseXML.documentElement.nodeName==="parsererror";if(x.responseType===""&&!B)return x.responseXML}catch{}return null}function E(){}return Fs.exports}var Db=wb();const Ah=pr(Db);var Co={exports:{}},So,Rc;function Ab(){if(Rc)return So;Rc=1;var s=Dh(),e=Object.create||(function(){function b(){}return function(C){if(arguments.length!==1)throw new Error("Object.create shim only accepts one parameter.");return b.prototype=C,new b}})();function i(b,C){this.name="ParsingError",this.code=b.code,this.message=C||b.message}i.prototype=e(Error.prototype),i.prototype.constructor=i,i.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}};function r(b){function C(j,k,A,$){return(j|0)*3600+(k|0)*60+(A|0)+($|0)/1e3}var U=b.match(/^(\d+):(\d{1,2})(:\d{1,2})?\.(\d{3})/);return U?U[3]?C(U[1],U[2],U[3].replace(":",""),U[4]):U[1]>59?C(U[1],U[2],0,U[4]):C(0,U[1],U[2],U[4]):null}function a(){this.values=e(null)}a.prototype={set:function(b,C){!this.get(b)&&C!==""&&(this.values[b]=C)},get:function(b,C,U){return U?this.has(b)?this.values[b]:C[U]:this.has(b)?this.values[b]:C},has:function(b){return b in this.values},alt:function(b,C,U){for(var j=0;j<U.length;++j)if(C===U[j]){this.set(b,C);break}},integer:function(b,C){/^-?\d+$/.test(C)&&this.set(b,parseInt(C,10))},percent:function(b,C){return C.match(/^([\d]{1,3})(\.[\d]*)?%$/)&&(C=parseFloat(C),C>=0&&C<=100)?(this.set(b,C),!0):!1}};function o(b,C,U,j){var k=j?b.split(j):[b];for(var A in k)if(typeof k[A]=="string"){var $=k[A].split(U);if($.length===2){var Q=$[0].trim(),H=$[1].trim();C(Q,H)}}}function l(b,C,U){var j=b;function k(){var Q=r(b);if(Q===null)throw new i(i.Errors.BadTimeStamp,"Malformed timestamp: "+j);return b=b.replace(/^[^\sa-zA-Z-]+/,""),Q}function A(Q,H){var V=new a;o(Q,function(G,Z){switch(G){case"region":for(var te=U.length-1;te>=0;te--)if(U[te].id===Z){V.set(G,U[te].region);break}break;case"vertical":V.alt(G,Z,["rl","lr"]);break;case"line":var se=Z.split(","),ue=se[0];V.integer(G,ue),V.percent(G,ue)&&V.set("snapToLines",!1),V.alt(G,ue,["auto"]),se.length===2&&V.alt("lineAlign",se[1],["start","center","end"]);break;case"position":se=Z.split(","),V.percent(G,se[0]),se.length===2&&V.alt("positionAlign",se[1],["start","center","end"]);break;case"size":V.percent(G,Z);break;case"align":V.alt(G,Z,["start","center","end","left","right"]);break}},/:/,/\s/),H.region=V.get("region",null),H.vertical=V.get("vertical","");try{H.line=V.get("line","auto")}catch{}H.lineAlign=V.get("lineAlign","start"),H.snapToLines=V.get("snapToLines",!0),H.size=V.get("size",100);try{H.align=V.get("align","center")}catch{H.align=V.get("align","middle")}try{H.position=V.get("position","auto")}catch{H.position=V.get("position",{start:0,left:0,center:50,middle:50,end:100,right:100},H.align)}H.positionAlign=V.get("positionAlign",{start:"start",left:"start",center:"center",middle:"center",end:"end",right:"end"},H.align)}function $(){b=b.replace(/^\s+/,"")}if($(),C.startTime=k(),$(),b.substr(0,3)!=="-->")throw new i(i.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '-->'): "+j);b=b.substr(3),$(),C.endTime=k(),$(),A(b,C)}var u=s.createElement&&s.createElement("textarea"),d={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},f={white:"rgba(255,255,255,1)",lime:"rgba(0,255,0,1)",cyan:"rgba(0,255,255,1)",red:"rgba(255,0,0,1)",yellow:"rgba(255,255,0,1)",magenta:"rgba(255,0,255,1)",blue:"rgba(0,0,255,1)",black:"rgba(0,0,0,1)"},g={v:"title",lang:"lang"},y={rt:"ruby"};function E(b,C){function U(){if(!C)return null;function ue(de){return C=C.substr(de.length),de}var ce=C.match(/^([^<]*)(<[^>]*>?)?/);return ue(ce[1]?ce[1]:ce[2])}function j(ue){return u.innerHTML=ue,ue=u.textContent,u.textContent="",ue}function k(ue,ce){return!y[ce.localName]||y[ce.localName]===ue.localName}function A(ue,ce){var de=d[ue];if(!de)return null;var qe=b.document.createElement(de),De=g[ue];return De&&ce&&(qe[De]=ce.trim()),qe}for(var $=b.document.createElement("div"),Q=$,H,V=[];(H=U())!==null;){if(H[0]==="<"){if(H[1]==="/"){V.length&&V[V.length-1]===H.substr(2).replace(">","")&&(V.pop(),Q=Q.parentNode);continue}var G=r(H.substr(1,H.length-2)),Z;if(G){Z=b.document.createProcessingInstruction("timestamp",G),Q.appendChild(Z);continue}var te=H.match(/^<([^.\s/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!te||(Z=A(te[1],te[3]),!Z)||!k(Q,Z))continue;if(te[2]){var se=te[2].split(".");se.forEach(function(ue){var ce=/^bg_/.test(ue),de=ce?ue.slice(3):ue;if(f.hasOwnProperty(de)){var qe=ce?"background-color":"color",De=f[de];Z.style[qe]=De}}),Z.className=se.join(" ")}V.push(te[1]),Q.appendChild(Z),Q=Z;continue}Q.appendChild(b.document.createTextNode(j(H)))}return $}var x=[[1470,1470],[1472,1472],[1475,1475],[1478,1478],[1488,1514],[1520,1524],[1544,1544],[1547,1547],[1549,1549],[1563,1563],[1566,1610],[1645,1647],[1649,1749],[1765,1766],[1774,1775],[1786,1805],[1807,1808],[1810,1839],[1869,1957],[1969,1969],[1984,2026],[2036,2037],[2042,2042],[2048,2069],[2074,2074],[2084,2084],[2088,2088],[2096,2110],[2112,2136],[2142,2142],[2208,2208],[2210,2220],[8207,8207],[64285,64285],[64287,64296],[64298,64310],[64312,64316],[64318,64318],[64320,64321],[64323,64324],[64326,64449],[64467,64829],[64848,64911],[64914,64967],[65008,65020],[65136,65140],[65142,65276],[67584,67589],[67592,67592],[67594,67637],[67639,67640],[67644,67644],[67647,67669],[67671,67679],[67840,67867],[67872,67897],[67903,67903],[67968,68023],[68030,68031],[68096,68096],[68112,68115],[68117,68119],[68121,68147],[68160,68167],[68176,68184],[68192,68223],[68352,68405],[68416,68437],[68440,68466],[68472,68479],[68608,68680],[126464,126467],[126469,126495],[126497,126498],[126500,126500],[126503,126503],[126505,126514],[126516,126519],[126521,126521],[126523,126523],[126530,126530],[126535,126535],[126537,126537],[126539,126539],[126541,126543],[126545,126546],[126548,126548],[126551,126551],[126553,126553],[126555,126555],[126557,126557],[126559,126559],[126561,126562],[126564,126564],[126567,126570],[126572,126578],[126580,126583],[126585,126588],[126590,126590],[126592,126601],[126603,126619],[126625,126627],[126629,126633],[126635,126651],[1114109,1114109]];function B(b){for(var C=0;C<x.length;C++){var U=x[C];if(b>=U[0]&&b<=U[1])return!0}return!1}function T(b){var C=[],U="",j;if(!b||!b.childNodes)return"ltr";function k(Q,H){for(var V=H.childNodes.length-1;V>=0;V--)Q.push(H.childNodes[V])}function A(Q){if(!Q||!Q.length)return null;var H=Q.pop(),V=H.textContent||H.innerText;if(V){var G=V.match(/^.*(\n|\r)/);return G?(Q.length=0,G[0]):V}if(H.tagName==="ruby")return A(Q);if(H.childNodes)return k(Q,H),A(Q)}for(k(C,b);U=A(C);)for(var $=0;$<U.length;$++)if(j=U.charCodeAt($),B(j))return"rtl";return"ltr"}function w(b){if(typeof b.line=="number"&&(b.snapToLines||b.line>=0&&b.line<=100))return b.line;if(!b.track||!b.track.textTrackList||!b.track.textTrackList.mediaElement)return-1;for(var C=b.track,U=C.textTrackList,j=0,k=0;k<U.length&&U[k]!==C;k++)U[k].mode==="showing"&&j++;return++j*-1}function F(){}F.prototype.applyStyles=function(b,C){C=C||this.div;for(var U in b)b.hasOwnProperty(U)&&(C.style[U]=b[U])},F.prototype.formatStyle=function(b,C){return b===0?0:b+C};function P(b,C,U){F.call(this),this.cue=C,this.cueDiv=E(b,C.text);var j={color:"rgba(255, 255, 255, 1)",backgroundColor:"rgba(0, 0, 0, 0.8)",position:"relative",left:0,right:0,top:0,bottom:0,display:"inline",writingMode:C.vertical===""?"horizontal-tb":C.vertical==="lr"?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext"};this.applyStyles(j,this.cueDiv),this.div=b.document.createElement("div"),j={direction:T(this.cueDiv),writingMode:C.vertical===""?"horizontal-tb":C.vertical==="lr"?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext",textAlign:C.align==="middle"?"center":C.align,font:U.font,whiteSpace:"pre-line",position:"absolute"},this.applyStyles(j),this.div.appendChild(this.cueDiv);var k=0;switch(C.positionAlign){case"start":case"line-left":k=C.position;break;case"center":k=C.position-C.size/2;break;case"end":case"line-right":k=C.position-C.size;break}C.vertical===""?this.applyStyles({left:this.formatStyle(k,"%"),width:this.formatStyle(C.size,"%")}):this.applyStyles({top:this.formatStyle(k,"%"),height:this.formatStyle(C.size,"%")}),this.move=function(A){this.applyStyles({top:this.formatStyle(A.top,"px"),bottom:this.formatStyle(A.bottom,"px"),left:this.formatStyle(A.left,"px"),right:this.formatStyle(A.right,"px"),height:this.formatStyle(A.height,"px"),width:this.formatStyle(A.width,"px")})}}P.prototype=e(F.prototype),P.prototype.constructor=P;function I(b){var C,U,j,k;if(b.div){U=b.div.offsetHeight,j=b.div.offsetWidth,k=b.div.offsetTop;var A=(A=b.div.childNodes)&&(A=A[0])&&A.getClientRects&&A.getClientRects();b=b.div.getBoundingClientRect(),C=A?Math.max(A[0]&&A[0].height||0,b.height/A.length):0}this.left=b.left,this.right=b.right,this.top=b.top||k,this.height=b.height||U,this.bottom=b.bottom||k+(b.height||U),this.width=b.width||j,this.lineHeight=C!==void 0?C:b.lineHeight}I.prototype.move=function(b,C){switch(C=C!==void 0?C:this.lineHeight,b){case"+x":this.left+=C,this.right+=C;break;case"-x":this.left-=C,this.right-=C;break;case"+y":this.top+=C,this.bottom+=C;break;case"-y":this.top-=C,this.bottom-=C;break}},I.prototype.overlaps=function(b){return this.left<b.right&&this.right>b.left&&this.top<b.bottom&&this.bottom>b.top},I.prototype.overlapsAny=function(b){for(var C=0;C<b.length;C++)if(this.overlaps(b[C]))return!0;return!1},I.prototype.within=function(b){return this.top>=b.top&&this.bottom<=b.bottom&&this.left>=b.left&&this.right<=b.right},I.prototype.overlapsOppositeAxis=function(b,C){switch(C){case"+x":return this.left<b.left;case"-x":return this.right>b.right;case"+y":return this.top<b.top;case"-y":return this.bottom>b.bottom}},I.prototype.intersectPercentage=function(b){var C=Math.max(0,Math.min(this.right,b.right)-Math.max(this.left,b.left)),U=Math.max(0,Math.min(this.bottom,b.bottom)-Math.max(this.top,b.top)),j=C*U;return j/(this.height*this.width)},I.prototype.toCSSCompatValues=function(b){return{top:this.top-b.top,bottom:b.bottom-this.bottom,left:this.left-b.left,right:b.right-this.right,height:this.height,width:this.width}},I.getSimpleBoxPosition=function(b){var C=b.div?b.div.offsetHeight:b.tagName?b.offsetHeight:0,U=b.div?b.div.offsetWidth:b.tagName?b.offsetWidth:0,j=b.div?b.div.offsetTop:b.tagName?b.offsetTop:0;b=b.div?b.div.getBoundingClientRect():b.tagName?b.getBoundingClientRect():b;var k={left:b.left,right:b.right,top:b.top||j,height:b.height||C,bottom:b.bottom||j+(b.height||C),width:b.width||U};return k};function K(b,C,U,j){function k(de,qe){for(var De,Oe=new I(de),We=1,Me=0;Me<qe.length;Me++){for(;de.overlapsOppositeAxis(U,qe[Me])||de.within(U)&&de.overlapsAny(j);)de.move(qe[Me]);if(de.within(U))return de;var Se=de.intersectPercentage(U);We>Se&&(De=new I(de),We=Se),de=new I(Oe)}return De||Oe}var A=new I(C),$=C.cue,Q=w($),H=[];if($.snapToLines){var V;switch($.vertical){case"":H=["+y","-y"],V="height";break;case"rl":H=["+x","-x"],V="width";break;case"lr":H=["-x","+x"],V="width";break}var G=A.lineHeight,Z=G*Math.round(Q),te=U[V]+G,se=H[0];Math.abs(Z)>te&&(Z=Z<0?-1:1,Z*=Math.ceil(te/G)*G),Q<0&&(Z+=$.vertical===""?U.height:U.width,H=H.reverse()),A.move(se,Z)}else{var ue=A.lineHeight/U.height*100;switch($.lineAlign){case"center":Q-=ue/2;break;case"end":Q-=ue;break}switch($.vertical){case"":C.applyStyles({top:C.formatStyle(Q,"%")});break;case"rl":C.applyStyles({left:C.formatStyle(Q,"%")});break;case"lr":C.applyStyles({right:C.formatStyle(Q,"%")});break}H=["+y","-x","+x","-y"],A=new I(C)}var ce=k(A,H);C.move(ce.toCSSCompatValues(U))}function q(){}q.StringDecoder=function(){return{decode:function(b){if(!b)return"";if(typeof b!="string")throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(b))}}},q.convertCueToDOMTree=function(b,C){return!b||!C?null:E(b,C)};var M=.05,N="sans-serif",J="1.5%";return q.processCues=function(b,C,U){if(!b||!C||!U)return null;for(;U.firstChild;)U.removeChild(U.firstChild);var j=b.document.createElement("div");j.style.position="absolute",j.style.left="0",j.style.right="0",j.style.top="0",j.style.bottom="0",j.style.margin=J,U.appendChild(j);function k(G){for(var Z=0;Z<G.length;Z++)if(G[Z].hasBeenReset||!G[Z].displayState)return!0;return!1}if(!k(C)){for(var A=0;A<C.length;A++)j.appendChild(C[A].displayState);return}var $=[],Q=I.getSimpleBoxPosition(j),H=Math.round(Q.height*M*100)/100,V={font:H+"px "+N};(function(){for(var G,Z,te=0;te<C.length;te++)Z=C[te],G=new P(b,Z,V),j.appendChild(G.div),K(b,G,Q,$),Z.displayState=G.div,$.push(I.getSimpleBoxPosition(G))})()},q.Parser=function(b,C,U){U||(U=C,C={}),C||(C={}),this.window=b,this.vttjs=C,this.state="INITIAL",this.buffer="",this.decoder=U||new TextDecoder("utf8"),this.regionList=[]},q.Parser.prototype={reportOrThrowError:function(b){if(b instanceof i)this.onparsingerror&&this.onparsingerror(b);else throw b},parse:function(b){var C=this;b&&(C.buffer+=C.decoder.decode(b,{stream:!0}));function U(){for(var G=C.buffer,Z=0;Z<G.length&&G[Z]!=="\r"&&G[Z]!==`
|
|
14
|
+
`;)++Z;var te=G.substr(0,Z);return G[Z]==="\r"&&++Z,G[Z]===`
|
|
15
|
+
`&&++Z,C.buffer=G.substr(Z),te}function j(G){var Z=new a;if(o(G,function(se,ue){switch(se){case"id":Z.set(se,ue);break;case"width":Z.percent(se,ue);break;case"lines":Z.integer(se,ue);break;case"regionanchor":case"viewportanchor":var ce=ue.split(",");if(ce.length!==2)break;var de=new a;if(de.percent("x",ce[0]),de.percent("y",ce[1]),!de.has("x")||!de.has("y"))break;Z.set(se+"X",de.get("x")),Z.set(se+"Y",de.get("y"));break;case"scroll":Z.alt(se,ue,["up"]);break}},/=/,/\s/),Z.has("id")){var te=new(C.vttjs.VTTRegion||C.window.VTTRegion);te.width=Z.get("width",100),te.lines=Z.get("lines",3),te.regionAnchorX=Z.get("regionanchorX",0),te.regionAnchorY=Z.get("regionanchorY",100),te.viewportAnchorX=Z.get("viewportanchorX",0),te.viewportAnchorY=Z.get("viewportanchorY",100),te.scroll=Z.get("scroll",""),C.onregion&&C.onregion(te),C.regionList.push({id:Z.get("id"),region:te})}}function k(G){var Z=new a;o(G,function(te,se){switch(te){case"MPEGT":Z.integer(te+"S",se);break;case"LOCA":Z.set(te+"L",r(se));break}},/[^\d]:/,/,/),C.ontimestampmap&&C.ontimestampmap({MPEGTS:Z.get("MPEGTS"),LOCAL:Z.get("LOCAL")})}function A(G){G.match(/X-TIMESTAMP-MAP/)?o(G,function(Z,te){switch(Z){case"X-TIMESTAMP-MAP":k(te);break}},/=/):o(G,function(Z,te){switch(Z){case"Region":j(te);break}},/:/)}try{var $;if(C.state==="INITIAL"){if(!/\r\n|\n/.test(C.buffer))return this;$=U();var Q=$.match(/^WEBVTT([ \t].*)?$/);if(!Q||!Q[0])throw new i(i.Errors.BadSignature);C.state="HEADER"}for(var H=!1;C.buffer;){if(!/\r\n|\n/.test(C.buffer))return this;switch(H?H=!1:$=U(),C.state){case"HEADER":/:/.test($)?A($):$||(C.state="ID");continue;case"NOTE":$||(C.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test($)){C.state="NOTE";break}if(!$)continue;C.cue=new(C.vttjs.VTTCue||C.window.VTTCue)(0,0,"");try{C.cue.align="center"}catch{C.cue.align="middle"}if(C.state="CUE",$.indexOf("-->")===-1){C.cue.id=$;continue}case"CUE":try{l($,C.cue,C.regionList)}catch(G){C.reportOrThrowError(G),C.cue=null,C.state="BADCUE";continue}C.state="CUETEXT";continue;case"CUETEXT":var V=$.indexOf("-->")!==-1;if(!$||V&&(H=!0)){C.oncue&&C.oncue(C.cue),C.cue=null,C.state="ID";continue}C.cue.text&&(C.cue.text+=`
|
|
16
|
+
`),C.cue.text+=$.replace(/\u2028/g,`
|
|
17
|
+
`).replace(/u2029/g,`
|
|
18
|
+
`);continue;case"BADCUE":$||(C.state="ID");continue}}}catch(G){C.reportOrThrowError(G),C.state==="CUETEXT"&&C.cue&&C.oncue&&C.oncue(C.cue),C.cue=null,C.state=C.state==="INITIAL"?"BADWEBVTT":"BADCUE"}return this},flush:function(){var b=this;try{if(b.buffer+=b.decoder.decode(),(b.cue||b.state==="HEADER")&&(b.buffer+=`
|
|
19
|
+
|
|
20
|
+
`,b.parse()),b.state==="INITIAL")throw new i(i.Errors.BadSignature)}catch(C){b.reportOrThrowError(C)}return b.onflush&&b.onflush(),this}},So=q,So}var Eo,Vc;function Ib(){if(Vc)return Eo;Vc=1;var s="auto",e={"":1,lr:1,rl:1},i={start:1,center:1,end:1,left:1,right:1,auto:1,"line-left":1,"line-right":1};function r(l){if(typeof l!="string")return!1;var u=e[l.toLowerCase()];return u?l.toLowerCase():!1}function a(l){if(typeof l!="string")return!1;var u=i[l.toLowerCase()];return u?l.toLowerCase():!1}function o(l,u,d){this.hasBeenReset=!1;var f="",g=!1,y=l,E=u,x=d,B=null,T="",w=!0,F="auto",P="start",I="auto",K="auto",q=100,M="center";Object.defineProperties(this,{id:{enumerable:!0,get:function(){return f},set:function(N){f=""+N}},pauseOnExit:{enumerable:!0,get:function(){return g},set:function(N){g=!!N}},startTime:{enumerable:!0,get:function(){return y},set:function(N){if(typeof N!="number")throw new TypeError("Start time must be set to a number.");y=N,this.hasBeenReset=!0}},endTime:{enumerable:!0,get:function(){return E},set:function(N){if(typeof N!="number")throw new TypeError("End time must be set to a number.");E=N,this.hasBeenReset=!0}},text:{enumerable:!0,get:function(){return x},set:function(N){x=""+N,this.hasBeenReset=!0}},region:{enumerable:!0,get:function(){return B},set:function(N){B=N,this.hasBeenReset=!0}},vertical:{enumerable:!0,get:function(){return T},set:function(N){var J=r(N);if(J===!1)throw new SyntaxError("Vertical: an invalid or illegal direction string was specified.");T=J,this.hasBeenReset=!0}},snapToLines:{enumerable:!0,get:function(){return w},set:function(N){w=!!N,this.hasBeenReset=!0}},line:{enumerable:!0,get:function(){return F},set:function(N){if(typeof N!="number"&&N!==s)throw new SyntaxError("Line: an invalid number or illegal string was specified.");F=N,this.hasBeenReset=!0}},lineAlign:{enumerable:!0,get:function(){return P},set:function(N){var J=a(N);J?(P=J,this.hasBeenReset=!0):console.warn("lineAlign: an invalid or illegal string was specified.")}},position:{enumerable:!0,get:function(){return I},set:function(N){if(N<0||N>100)throw new Error("Position must be between 0 and 100.");I=N,this.hasBeenReset=!0}},positionAlign:{enumerable:!0,get:function(){return K},set:function(N){var J=a(N);J?(K=J,this.hasBeenReset=!0):console.warn("positionAlign: an invalid or illegal string was specified.")}},size:{enumerable:!0,get:function(){return q},set:function(N){if(N<0||N>100)throw new Error("Size must be between 0 and 100.");q=N,this.hasBeenReset=!0}},align:{enumerable:!0,get:function(){return M},set:function(N){var J=a(N);if(!J)throw new SyntaxError("align: an invalid or illegal alignment string was specified.");M=J,this.hasBeenReset=!0}}}),this.displayState=void 0}return o.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)},Eo=o,Eo}var ko,Fc;function Nb(){if(Fc)return ko;Fc=1;var s={"":!0,up:!0};function e(a){if(typeof a!="string")return!1;var o=s[a.toLowerCase()];return o?a.toLowerCase():!1}function i(a){return typeof a=="number"&&a>=0&&a<=100}function r(){var a=100,o=3,l=0,u=100,d=0,f=100,g="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return a},set:function(y){if(!i(y))throw new Error("Width must be between 0 and 100.");a=y}},lines:{enumerable:!0,get:function(){return o},set:function(y){if(typeof y!="number")throw new TypeError("Lines must be set to a number.");o=y}},regionAnchorY:{enumerable:!0,get:function(){return u},set:function(y){if(!i(y))throw new Error("RegionAnchorX must be between 0 and 100.");u=y}},regionAnchorX:{enumerable:!0,get:function(){return l},set:function(y){if(!i(y))throw new Error("RegionAnchorY must be between 0 and 100.");l=y}},viewportAnchorY:{enumerable:!0,get:function(){return f},set:function(y){if(!i(y))throw new Error("ViewportAnchorY must be between 0 and 100.");f=y}},viewportAnchorX:{enumerable:!0,get:function(){return d},set:function(y){if(!i(y))throw new Error("ViewportAnchorX must be between 0 and 100.");d=y}},scroll:{enumerable:!0,get:function(){return g},set:function(y){var E=e(y);E===!1?console.warn("Scroll: an invalid or illegal string was specified."):g=E}}})}return ko=r,ko}var $c;function Ob(){if($c)return Co.exports;$c=1;var s=Sa(),e=Co.exports={WebVTT:Ab(),VTTCue:Ib(),VTTRegion:Nb()};s.vttjs=e,s.WebVTT=e.WebVTT;var i=e.VTTCue,r=e.VTTRegion,a=s.VTTCue,o=s.VTTRegion;return e.shim=function(){s.VTTCue=i,s.VTTRegion=r},e.restore=function(){s.VTTCue=a,s.VTTRegion=o},s.VTTCue||e.shim(),Co.exports}var Bb=Ob();const Uc=pr(Bb);function bt(){return bt=Object.assign?Object.assign.bind():function(s){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var r in i)({}).hasOwnProperty.call(i,r)&&(s[r]=i[r])}return s},bt.apply(null,arguments)}var qc="https://example.com",Ea=function(e,i){if(/^[a-z]+:/i.test(i))return i;/^data:/.test(e)&&(e=W.location&&W.location.href||"");var r=/^\/\//.test(e),a=!W.location&&!/\/\//i.test(e);e=new W.URL(e,W.location||qc);var o=new URL(i,e);return a?o.href.slice(qc.length):r?o.href.slice(o.protocol.length):o.href},Nl=(function(){function s(){this.listeners={}}var e=s.prototype;return e.on=function(r,a){this.listeners[r]||(this.listeners[r]=[]),this.listeners[r].push(a)},e.off=function(r,a){if(!this.listeners[r])return!1;var o=this.listeners[r].indexOf(a);return this.listeners[r]=this.listeners[r].slice(0),this.listeners[r].splice(o,1),o>-1},e.trigger=function(r){var a=this.listeners[r];if(a)if(arguments.length===2)for(var o=a.length,l=0;l<o;++l)a[l].call(this,arguments[1]);else for(var u=Array.prototype.slice.call(arguments,1),d=a.length,f=0;f<d;++f)a[f].apply(this,u)},e.dispose=function(){this.listeners={}},e.pipe=function(r){this.on("data",function(a){r.push(a)})},s})(),Lb=function(e){return W.atob?W.atob(e):Buffer.from(e,"base64").toString("binary")};function Ih(s){for(var e=Lb(s),i=new Uint8Array(e.length),r=0;r<e.length;r++)i[r]=e.charCodeAt(r);return i}/*! @name m3u8-parser @version 7.2.0 @license Apache-2.0 */class Pb extends Nl{constructor(){super(),this.buffer=""}push(e){let i;for(this.buffer+=e,i=this.buffer.indexOf(`
|
|
21
|
+
`);i>-1;i=this.buffer.indexOf(`
|
|
22
|
+
`))this.trigger("data",this.buffer.substring(0,i)),this.buffer=this.buffer.substring(i+1)}}const Mb=" ",wo=function(s){const e=/([0-9.]*)?@?([0-9.]*)?/.exec(s||""),i={};return e[1]&&(i.length=parseInt(e[1],10)),e[2]&&(i.offset=parseInt(e[2],10)),i},Rb=function(){const i="(?:"+"[^=]*"+")=(?:"+'"[^"]*"|[^,]*'+")";return new RegExp("(?:^|,)("+i+")")},Xt=function(s){const e={};if(!s)return e;const i=s.split(Rb());let r=i.length,a;for(;r--;)i[r]!==""&&(a=/([^=]*)=(.*)/.exec(i[r]).slice(1),a[0]=a[0].replace(/^\s+|\s+$/g,""),a[1]=a[1].replace(/^\s+|\s+$/g,""),a[1]=a[1].replace(/^['"](.*)['"]$/g,"$1"),e[a[0]]=a[1]);return e},jc=s=>{const e=s.split("x"),i={};return e[0]&&(i.width=parseInt(e[0],10)),e[1]&&(i.height=parseInt(e[1],10)),i};class Vb extends Nl{constructor(){super(),this.customParsers=[],this.tagMappers=[]}push(e){let i,r;if(e=e.trim(),e.length===0)return;if(e[0]!=="#"){this.trigger("data",{type:"uri",uri:e});return}this.tagMappers.reduce((o,l)=>{const u=l(e);return u===e?o:o.concat([u])},[e]).forEach(o=>{for(let l=0;l<this.customParsers.length;l++)if(this.customParsers[l].call(this,o))return;if(o.indexOf("#EXT")!==0){this.trigger("data",{type:"comment",text:o.slice(1)});return}if(o=o.replace("\r",""),i=/^#EXTM3U/.exec(o),i){this.trigger("data",{type:"tag",tagType:"m3u"});return}if(i=/^#EXTINF:([0-9\.]*)?,?(.*)?$/.exec(o),i){r={type:"tag",tagType:"inf"},i[1]&&(r.duration=parseFloat(i[1])),i[2]&&(r.title=i[2]),this.trigger("data",r);return}if(i=/^#EXT-X-TARGETDURATION:([0-9.]*)?/.exec(o),i){r={type:"tag",tagType:"targetduration"},i[1]&&(r.duration=parseInt(i[1],10)),this.trigger("data",r);return}if(i=/^#EXT-X-VERSION:([0-9.]*)?/.exec(o),i){r={type:"tag",tagType:"version"},i[1]&&(r.version=parseInt(i[1],10)),this.trigger("data",r);return}if(i=/^#EXT-X-MEDIA-SEQUENCE:(\-?[0-9.]*)?/.exec(o),i){r={type:"tag",tagType:"media-sequence"},i[1]&&(r.number=parseInt(i[1],10)),this.trigger("data",r);return}if(i=/^#EXT-X-DISCONTINUITY-SEQUENCE:(\-?[0-9.]*)?/.exec(o),i){r={type:"tag",tagType:"discontinuity-sequence"},i[1]&&(r.number=parseInt(i[1],10)),this.trigger("data",r);return}if(i=/^#EXT-X-PLAYLIST-TYPE:(.*)?$/.exec(o),i){r={type:"tag",tagType:"playlist-type"},i[1]&&(r.playlistType=i[1]),this.trigger("data",r);return}if(i=/^#EXT-X-BYTERANGE:(.*)?$/.exec(o),i){r=bt(wo(i[1]),{type:"tag",tagType:"byterange"}),this.trigger("data",r);return}if(i=/^#EXT-X-ALLOW-CACHE:(YES|NO)?/.exec(o),i){r={type:"tag",tagType:"allow-cache"},i[1]&&(r.allowed=!/NO/.test(i[1])),this.trigger("data",r);return}if(i=/^#EXT-X-MAP:(.*)$/.exec(o),i){if(r={type:"tag",tagType:"map"},i[1]){const l=Xt(i[1]);l.URI&&(r.uri=l.URI),l.BYTERANGE&&(r.byterange=wo(l.BYTERANGE))}this.trigger("data",r);return}if(i=/^#EXT-X-STREAM-INF:(.*)$/.exec(o),i){r={type:"tag",tagType:"stream-inf"},i[1]&&(r.attributes=Xt(i[1]),r.attributes.RESOLUTION&&(r.attributes.RESOLUTION=jc(r.attributes.RESOLUTION)),r.attributes.BANDWIDTH&&(r.attributes.BANDWIDTH=parseInt(r.attributes.BANDWIDTH,10)),r.attributes["FRAME-RATE"]&&(r.attributes["FRAME-RATE"]=parseFloat(r.attributes["FRAME-RATE"])),r.attributes["PROGRAM-ID"]&&(r.attributes["PROGRAM-ID"]=parseInt(r.attributes["PROGRAM-ID"],10))),this.trigger("data",r);return}if(i=/^#EXT-X-MEDIA:(.*)$/.exec(o),i){r={type:"tag",tagType:"media"},i[1]&&(r.attributes=Xt(i[1])),this.trigger("data",r);return}if(i=/^#EXT-X-ENDLIST/.exec(o),i){this.trigger("data",{type:"tag",tagType:"endlist"});return}if(i=/^#EXT-X-DISCONTINUITY/.exec(o),i){this.trigger("data",{type:"tag",tagType:"discontinuity"});return}if(i=/^#EXT-X-PROGRAM-DATE-TIME:(.*)$/.exec(o),i){r={type:"tag",tagType:"program-date-time"},i[1]&&(r.dateTimeString=i[1],r.dateTimeObject=new Date(i[1])),this.trigger("data",r);return}if(i=/^#EXT-X-KEY:(.*)$/.exec(o),i){r={type:"tag",tagType:"key"},i[1]&&(r.attributes=Xt(i[1]),r.attributes.IV&&(r.attributes.IV.substring(0,2).toLowerCase()==="0x"&&(r.attributes.IV=r.attributes.IV.substring(2)),r.attributes.IV=r.attributes.IV.match(/.{8}/g),r.attributes.IV[0]=parseInt(r.attributes.IV[0],16),r.attributes.IV[1]=parseInt(r.attributes.IV[1],16),r.attributes.IV[2]=parseInt(r.attributes.IV[2],16),r.attributes.IV[3]=parseInt(r.attributes.IV[3],16),r.attributes.IV=new Uint32Array(r.attributes.IV))),this.trigger("data",r);return}if(i=/^#EXT-X-START:(.*)$/.exec(o),i){r={type:"tag",tagType:"start"},i[1]&&(r.attributes=Xt(i[1]),r.attributes["TIME-OFFSET"]=parseFloat(r.attributes["TIME-OFFSET"]),r.attributes.PRECISE=/YES/.test(r.attributes.PRECISE)),this.trigger("data",r);return}if(i=/^#EXT-X-CUE-OUT-CONT:(.*)?$/.exec(o),i){r={type:"tag",tagType:"cue-out-cont"},i[1]?r.data=i[1]:r.data="",this.trigger("data",r);return}if(i=/^#EXT-X-CUE-OUT:(.*)?$/.exec(o),i){r={type:"tag",tagType:"cue-out"},i[1]?r.data=i[1]:r.data="",this.trigger("data",r);return}if(i=/^#EXT-X-CUE-IN:?(.*)?$/.exec(o),i){r={type:"tag",tagType:"cue-in"},i[1]?r.data=i[1]:r.data="",this.trigger("data",r);return}if(i=/^#EXT-X-SKIP:(.*)$/.exec(o),i&&i[1]){r={type:"tag",tagType:"skip"},r.attributes=Xt(i[1]),r.attributes.hasOwnProperty("SKIPPED-SEGMENTS")&&(r.attributes["SKIPPED-SEGMENTS"]=parseInt(r.attributes["SKIPPED-SEGMENTS"],10)),r.attributes.hasOwnProperty("RECENTLY-REMOVED-DATERANGES")&&(r.attributes["RECENTLY-REMOVED-DATERANGES"]=r.attributes["RECENTLY-REMOVED-DATERANGES"].split(Mb)),this.trigger("data",r);return}if(i=/^#EXT-X-PART:(.*)$/.exec(o),i&&i[1]){r={type:"tag",tagType:"part"},r.attributes=Xt(i[1]),["DURATION"].forEach(function(l){r.attributes.hasOwnProperty(l)&&(r.attributes[l]=parseFloat(r.attributes[l]))}),["INDEPENDENT","GAP"].forEach(function(l){r.attributes.hasOwnProperty(l)&&(r.attributes[l]=/YES/.test(r.attributes[l]))}),r.attributes.hasOwnProperty("BYTERANGE")&&(r.attributes.byterange=wo(r.attributes.BYTERANGE)),this.trigger("data",r);return}if(i=/^#EXT-X-SERVER-CONTROL:(.*)$/.exec(o),i&&i[1]){r={type:"tag",tagType:"server-control"},r.attributes=Xt(i[1]),["CAN-SKIP-UNTIL","PART-HOLD-BACK","HOLD-BACK"].forEach(function(l){r.attributes.hasOwnProperty(l)&&(r.attributes[l]=parseFloat(r.attributes[l]))}),["CAN-SKIP-DATERANGES","CAN-BLOCK-RELOAD"].forEach(function(l){r.attributes.hasOwnProperty(l)&&(r.attributes[l]=/YES/.test(r.attributes[l]))}),this.trigger("data",r);return}if(i=/^#EXT-X-PART-INF:(.*)$/.exec(o),i&&i[1]){r={type:"tag",tagType:"part-inf"},r.attributes=Xt(i[1]),["PART-TARGET"].forEach(function(l){r.attributes.hasOwnProperty(l)&&(r.attributes[l]=parseFloat(r.attributes[l]))}),this.trigger("data",r);return}if(i=/^#EXT-X-PRELOAD-HINT:(.*)$/.exec(o),i&&i[1]){r={type:"tag",tagType:"preload-hint"},r.attributes=Xt(i[1]),["BYTERANGE-START","BYTERANGE-LENGTH"].forEach(function(l){if(r.attributes.hasOwnProperty(l)){r.attributes[l]=parseInt(r.attributes[l],10);const u=l==="BYTERANGE-LENGTH"?"length":"offset";r.attributes.byterange=r.attributes.byterange||{},r.attributes.byterange[u]=r.attributes[l],delete r.attributes[l]}}),this.trigger("data",r);return}if(i=/^#EXT-X-RENDITION-REPORT:(.*)$/.exec(o),i&&i[1]){r={type:"tag",tagType:"rendition-report"},r.attributes=Xt(i[1]),["LAST-MSN","LAST-PART"].forEach(function(l){r.attributes.hasOwnProperty(l)&&(r.attributes[l]=parseInt(r.attributes[l],10))}),this.trigger("data",r);return}if(i=/^#EXT-X-DATERANGE:(.*)$/.exec(o),i&&i[1]){r={type:"tag",tagType:"daterange"},r.attributes=Xt(i[1]),["ID","CLASS"].forEach(function(u){r.attributes.hasOwnProperty(u)&&(r.attributes[u]=String(r.attributes[u]))}),["START-DATE","END-DATE"].forEach(function(u){r.attributes.hasOwnProperty(u)&&(r.attributes[u]=new Date(r.attributes[u]))}),["DURATION","PLANNED-DURATION"].forEach(function(u){r.attributes.hasOwnProperty(u)&&(r.attributes[u]=parseFloat(r.attributes[u]))}),["END-ON-NEXT"].forEach(function(u){r.attributes.hasOwnProperty(u)&&(r.attributes[u]=/YES/i.test(r.attributes[u]))}),["SCTE35-CMD"," SCTE35-OUT","SCTE35-IN"].forEach(function(u){r.attributes.hasOwnProperty(u)&&(r.attributes[u]=r.attributes[u].toString(16))});const l=/^X-([A-Z]+-)+[A-Z]+$/;for(const u in r.attributes){if(!l.test(u))continue;const d=/[0-9A-Fa-f]{6}/g.test(r.attributes[u]),f=/^\d+(\.\d+)?$/.test(r.attributes[u]);r.attributes[u]=d?r.attributes[u].toString(16):f?parseFloat(r.attributes[u]):String(r.attributes[u])}this.trigger("data",r);return}if(i=/^#EXT-X-INDEPENDENT-SEGMENTS/.exec(o),i){this.trigger("data",{type:"tag",tagType:"independent-segments"});return}if(i=/^#EXT-X-I-FRAMES-ONLY/.exec(o),i){this.trigger("data",{type:"tag",tagType:"i-frames-only"});return}if(i=/^#EXT-X-CONTENT-STEERING:(.*)$/.exec(o),i){r={type:"tag",tagType:"content-steering"},r.attributes=Xt(i[1]),this.trigger("data",r);return}if(i=/^#EXT-X-I-FRAME-STREAM-INF:(.*)$/.exec(o),i){r={type:"tag",tagType:"i-frame-playlist"},r.attributes=Xt(i[1]),r.attributes.URI&&(r.uri=r.attributes.URI),r.attributes.BANDWIDTH&&(r.attributes.BANDWIDTH=parseInt(r.attributes.BANDWIDTH,10)),r.attributes.RESOLUTION&&(r.attributes.RESOLUTION=jc(r.attributes.RESOLUTION)),r.attributes["AVERAGE-BANDWIDTH"]&&(r.attributes["AVERAGE-BANDWIDTH"]=parseInt(r.attributes["AVERAGE-BANDWIDTH"],10)),r.attributes["FRAME-RATE"]&&(r.attributes["FRAME-RATE"]=parseFloat(r.attributes["FRAME-RATE"])),this.trigger("data",r);return}if(i=/^#EXT-X-DEFINE:(.*)$/.exec(o),i){r={type:"tag",tagType:"define"},r.attributes=Xt(i[1]),this.trigger("data",r);return}this.trigger("data",{type:"tag",data:o.slice(4)})})}addParser({expression:e,customType:i,dataParser:r,segment:a}){typeof r!="function"&&(r=o=>o),this.customParsers.push(o=>{if(e.exec(o))return this.trigger("data",{type:"custom",data:r(o),customType:i,segment:a}),!0})}addTagMapper({expression:e,map:i}){const r=a=>e.test(a)?i(a):a;this.tagMappers.push(r)}}const Fb=s=>s.toLowerCase().replace(/-(\w)/g,e=>e[1].toUpperCase()),un=function(s){const e={};return Object.keys(s).forEach(function(i){e[Fb(i)]=s[i]}),e},Do=function(s){const{serverControl:e,targetDuration:i,partTargetDuration:r}=s;if(!e)return;const a="#EXT-X-SERVER-CONTROL",o="holdBack",l="partHoldBack",u=i&&i*3,d=r&&r*2;i&&!e.hasOwnProperty(o)&&(e[o]=u,this.trigger("info",{message:`${a} defaulting HOLD-BACK to targetDuration * 3 (${u}).`})),u&&e[o]<u&&(this.trigger("warn",{message:`${a} clamping HOLD-BACK (${e[o]}) to targetDuration * 3 (${u})`}),e[o]=u),r&&!e.hasOwnProperty(l)&&(e[l]=r*3,this.trigger("info",{message:`${a} defaulting PART-HOLD-BACK to partTargetDuration * 3 (${e[l]}).`})),r&&e[l]<d&&(this.trigger("warn",{message:`${a} clamping PART-HOLD-BACK (${e[l]}) to partTargetDuration * 2 (${d}).`}),e[l]=d)};class $b extends Nl{constructor(e={}){super(),this.lineStream=new Pb,this.parseStream=new Vb,this.lineStream.pipe(this.parseStream),this.mainDefinitions=e.mainDefinitions||{},this.params=new URL(e.uri,"https://a.com").searchParams,this.lastProgramDateTime=null;const i=this,r=[];let a={},o,l,u=!1;const d=function(){},f={AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},g="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed";let y=0;this.manifest={allowCache:!0,discontinuityStarts:[],dateRanges:[],iFramePlaylists:[],segments:[]};let E=0,x=0;const B={};this.on("end",()=>{a.uri||!a.parts&&!a.preloadHints||(!a.map&&o&&(a.map=o),!a.key&&l&&(a.key=l),!a.timeline&&typeof y=="number"&&(a.timeline=y),this.manifest.preloadSegment=a)}),this.parseStream.on("data",function(T){let w,F;if(i.manifest.definitions){for(const P in i.manifest.definitions)if(T.uri&&(T.uri=T.uri.replace(`{$${P}}`,i.manifest.definitions[P])),T.attributes)for(const I in T.attributes)typeof T.attributes[I]=="string"&&(T.attributes[I]=T.attributes[I].replace(`{$${P}}`,i.manifest.definitions[P]))}({tag(){({version(){T.version&&(this.manifest.version=T.version)},"allow-cache"(){this.manifest.allowCache=T.allowed,"allowed"in T||(this.trigger("info",{message:"defaulting allowCache to YES"}),this.manifest.allowCache=!0)},byterange(){const P={};"length"in T&&(a.byterange=P,P.length=T.length,"offset"in T||(T.offset=E)),"offset"in T&&(a.byterange=P,P.offset=T.offset),E=P.offset+P.length},endlist(){this.manifest.endList=!0},inf(){"mediaSequence"in this.manifest||(this.manifest.mediaSequence=0,this.trigger("info",{message:"defaulting media sequence to zero"})),"discontinuitySequence"in this.manifest||(this.manifest.discontinuitySequence=0,this.trigger("info",{message:"defaulting discontinuity sequence to zero"})),T.title&&(a.title=T.title),T.duration>0&&(a.duration=T.duration),T.duration===0&&(a.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=r},key(){if(!T.attributes){this.trigger("warn",{message:"ignoring key declaration without attribute list"});return}if(T.attributes.METHOD==="NONE"){l=null;return}if(!T.attributes.URI){this.trigger("warn",{message:"ignoring key declaration without URI"});return}if(T.attributes.KEYFORMAT==="com.apple.streamingkeydelivery"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.apple.fps.1_0"]={attributes:T.attributes};return}if(T.attributes.KEYFORMAT==="com.microsoft.playready"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.microsoft.playready"]={uri:T.attributes.URI};return}if(T.attributes.KEYFORMAT===g){if(["SAMPLE-AES","SAMPLE-AES-CTR","SAMPLE-AES-CENC"].indexOf(T.attributes.METHOD)===-1){this.trigger("warn",{message:"invalid key method provided for Widevine"});return}if(T.attributes.METHOD==="SAMPLE-AES-CENC"&&this.trigger("warn",{message:"SAMPLE-AES-CENC is deprecated, please use SAMPLE-AES-CTR instead"}),T.attributes.URI.substring(0,23)!=="data:text/plain;base64,"){this.trigger("warn",{message:"invalid key URI provided for Widevine"});return}if(!(T.attributes.KEYID&&T.attributes.KEYID.substring(0,2)==="0x")){this.trigger("warn",{message:"invalid key ID provided for Widevine"});return}this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.widevine.alpha"]={attributes:{schemeIdUri:T.attributes.KEYFORMAT,keyId:T.attributes.KEYID.substring(2)},pssh:Ih(T.attributes.URI.split(",")[1])};return}T.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),l={method:T.attributes.METHOD||"AES-128",uri:T.attributes.URI},typeof T.attributes.IV<"u"&&(l.iv=T.attributes.IV)},"media-sequence"(){if(!isFinite(T.number)){this.trigger("warn",{message:"ignoring invalid media sequence: "+T.number});return}this.manifest.mediaSequence=T.number},"discontinuity-sequence"(){if(!isFinite(T.number)){this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+T.number});return}this.manifest.discontinuitySequence=T.number,y=T.number},"playlist-type"(){if(!/VOD|EVENT/.test(T.playlistType)){this.trigger("warn",{message:"ignoring unknown playlist type: "+T.playlist});return}this.manifest.playlistType=T.playlistType},map(){o={},T.uri&&(o.uri=T.uri),T.byterange&&(o.byterange=T.byterange),l&&(o.key=l)},"stream-inf"(){if(this.manifest.playlists=r,this.manifest.mediaGroups=this.manifest.mediaGroups||f,!T.attributes){this.trigger("warn",{message:"ignoring empty stream-inf attributes"});return}a.attributes||(a.attributes={}),bt(a.attributes,T.attributes)},media(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||f,!(T.attributes&&T.attributes.TYPE&&T.attributes["GROUP-ID"]&&T.attributes.NAME)){this.trigger("warn",{message:"ignoring incomplete or missing media group"});return}const P=this.manifest.mediaGroups[T.attributes.TYPE];P[T.attributes["GROUP-ID"]]=P[T.attributes["GROUP-ID"]]||{},w=P[T.attributes["GROUP-ID"]],F={default:/yes/i.test(T.attributes.DEFAULT)},F.default?F.autoselect=!0:F.autoselect=/yes/i.test(T.attributes.AUTOSELECT),T.attributes.LANGUAGE&&(F.language=T.attributes.LANGUAGE),T.attributes.URI&&(F.uri=T.attributes.URI),T.attributes["INSTREAM-ID"]&&(F.instreamId=T.attributes["INSTREAM-ID"]),T.attributes.CHARACTERISTICS&&(F.characteristics=T.attributes.CHARACTERISTICS),T.attributes.FORCED&&(F.forced=/yes/i.test(T.attributes.FORCED)),w[T.attributes.NAME]=F},discontinuity(){y+=1,a.discontinuity=!0,this.manifest.discontinuityStarts.push(r.length)},"program-date-time"(){typeof this.manifest.dateTimeString>"u"&&(this.manifest.dateTimeString=T.dateTimeString,this.manifest.dateTimeObject=T.dateTimeObject),a.dateTimeString=T.dateTimeString,a.dateTimeObject=T.dateTimeObject;const{lastProgramDateTime:P}=this;this.lastProgramDateTime=new Date(T.dateTimeString).getTime(),P===null&&this.manifest.segments.reduceRight((I,K)=>(K.programDateTime=I-K.duration*1e3,K.programDateTime),this.lastProgramDateTime)},targetduration(){if(!isFinite(T.duration)||T.duration<0){this.trigger("warn",{message:"ignoring invalid target duration: "+T.duration});return}this.manifest.targetDuration=T.duration,Do.call(this,this.manifest)},start(){if(!T.attributes||isNaN(T.attributes["TIME-OFFSET"])){this.trigger("warn",{message:"ignoring start declaration without appropriate attribute list"});return}this.manifest.start={timeOffset:T.attributes["TIME-OFFSET"],precise:T.attributes.PRECISE}},"cue-out"(){a.cueOut=T.data},"cue-out-cont"(){a.cueOutCont=T.data},"cue-in"(){a.cueIn=T.data},skip(){this.manifest.skip=un(T.attributes),this.warnOnMissingAttributes_("#EXT-X-SKIP",T.attributes,["SKIPPED-SEGMENTS"])},part(){u=!0;const P=this.manifest.segments.length,I=un(T.attributes);a.parts=a.parts||[],a.parts.push(I),I.byterange&&(I.byterange.hasOwnProperty("offset")||(I.byterange.offset=x),x=I.byterange.offset+I.byterange.length);const K=a.parts.length-1;this.warnOnMissingAttributes_(`#EXT-X-PART #${K} for segment #${P}`,T.attributes,["URI","DURATION"]),this.manifest.renditionReports&&this.manifest.renditionReports.forEach((q,M)=>{q.hasOwnProperty("lastPart")||this.trigger("warn",{message:`#EXT-X-RENDITION-REPORT #${M} lacks required attribute(s): LAST-PART`})})},"server-control"(){const P=this.manifest.serverControl=un(T.attributes);P.hasOwnProperty("canBlockReload")||(P.canBlockReload=!1,this.trigger("info",{message:"#EXT-X-SERVER-CONTROL defaulting CAN-BLOCK-RELOAD to false"})),Do.call(this,this.manifest),P.canSkipDateranges&&!P.hasOwnProperty("canSkipUntil")&&this.trigger("warn",{message:"#EXT-X-SERVER-CONTROL lacks required attribute CAN-SKIP-UNTIL which is required when CAN-SKIP-DATERANGES is set"})},"preload-hint"(){const P=this.manifest.segments.length,I=un(T.attributes),K=I.type&&I.type==="PART";a.preloadHints=a.preloadHints||[],a.preloadHints.push(I),I.byterange&&(I.byterange.hasOwnProperty("offset")||(I.byterange.offset=K?x:0,K&&(x=I.byterange.offset+I.byterange.length)));const q=a.preloadHints.length-1;if(this.warnOnMissingAttributes_(`#EXT-X-PRELOAD-HINT #${q} for segment #${P}`,T.attributes,["TYPE","URI"]),!!I.type)for(let M=0;M<a.preloadHints.length-1;M++){const N=a.preloadHints[M];N.type&&N.type===I.type&&this.trigger("warn",{message:`#EXT-X-PRELOAD-HINT #${q} for segment #${P} has the same TYPE ${I.type} as preload hint #${M}`})}},"rendition-report"(){const P=un(T.attributes);this.manifest.renditionReports=this.manifest.renditionReports||[],this.manifest.renditionReports.push(P);const I=this.manifest.renditionReports.length-1,K=["LAST-MSN","URI"];u&&K.push("LAST-PART"),this.warnOnMissingAttributes_(`#EXT-X-RENDITION-REPORT #${I}`,T.attributes,K)},"part-inf"(){this.manifest.partInf=un(T.attributes),this.warnOnMissingAttributes_("#EXT-X-PART-INF",T.attributes,["PART-TARGET"]),this.manifest.partInf.partTarget&&(this.manifest.partTargetDuration=this.manifest.partInf.partTarget),Do.call(this,this.manifest)},daterange(){this.manifest.dateRanges.push(un(T.attributes));const P=this.manifest.dateRanges.length-1;this.warnOnMissingAttributes_(`#EXT-X-DATERANGE #${P}`,T.attributes,["ID","START-DATE"]);const I=this.manifest.dateRanges[P];I.endDate&&I.startDate&&new Date(I.endDate)<new Date(I.startDate)&&this.trigger("warn",{message:"EXT-X-DATERANGE END-DATE must be equal to or later than the value of the START-DATE"}),I.duration&&I.duration<0&&this.trigger("warn",{message:"EXT-X-DATERANGE DURATION must not be negative"}),I.plannedDuration&&I.plannedDuration<0&&this.trigger("warn",{message:"EXT-X-DATERANGE PLANNED-DURATION must not be negative"});const K=!!I.endOnNext;if(K&&!I.class&&this.trigger("warn",{message:"EXT-X-DATERANGE with an END-ON-NEXT=YES attribute must have a CLASS attribute"}),K&&(I.duration||I.endDate)&&this.trigger("warn",{message:"EXT-X-DATERANGE with an END-ON-NEXT=YES attribute must not contain DURATION or END-DATE attributes"}),I.duration&&I.endDate){const M=I.startDate.getTime()+I.duration*1e3;this.manifest.dateRanges[P].endDate=new Date(M)}if(!B[I.id])B[I.id]=I;else{for(const M in B[I.id])if(I[M]&&JSON.stringify(B[I.id][M])!==JSON.stringify(I[M])){this.trigger("warn",{message:"EXT-X-DATERANGE tags with the same ID in a playlist must have the same attributes values"});break}const q=this.manifest.dateRanges.findIndex(M=>M.id===I.id);this.manifest.dateRanges[q]=bt(this.manifest.dateRanges[q],I),B[I.id]=bt(B[I.id],I),this.manifest.dateRanges.pop()}},"independent-segments"(){this.manifest.independentSegments=!0},"i-frames-only"(){this.manifest.iFramesOnly=!0,this.requiredCompatibilityversion(this.manifest.version,4)},"content-steering"(){this.manifest.contentSteering=un(T.attributes),this.warnOnMissingAttributes_("#EXT-X-CONTENT-STEERING",T.attributes,["SERVER-URI"])},define(){this.manifest.definitions=this.manifest.definitions||{};const P=(I,K)=>{if(I in this.manifest.definitions){this.trigger("error",{message:`EXT-X-DEFINE: Duplicate name ${I}`});return}this.manifest.definitions[I]=K};if("QUERYPARAM"in T.attributes){if("NAME"in T.attributes||"IMPORT"in T.attributes){this.trigger("error",{message:"EXT-X-DEFINE: Invalid attributes"});return}const I=this.params.get(T.attributes.QUERYPARAM);if(!I){this.trigger("error",{message:`EXT-X-DEFINE: No query param ${T.attributes.QUERYPARAM}`});return}P(T.attributes.QUERYPARAM,decodeURIComponent(I));return}if("NAME"in T.attributes){if("IMPORT"in T.attributes){this.trigger("error",{message:"EXT-X-DEFINE: Invalid attributes"});return}if(!("VALUE"in T.attributes)||typeof T.attributes.VALUE!="string"){this.trigger("error",{message:`EXT-X-DEFINE: No value for ${T.attributes.NAME}`});return}P(T.attributes.NAME,T.attributes.VALUE);return}if("IMPORT"in T.attributes){if(!this.mainDefinitions[T.attributes.IMPORT]){this.trigger("error",{message:`EXT-X-DEFINE: No value ${T.attributes.IMPORT} to import, or IMPORT used on main playlist`});return}P(T.attributes.IMPORT,this.mainDefinitions[T.attributes.IMPORT]);return}this.trigger("error",{message:"EXT-X-DEFINE: No attribute"})},"i-frame-playlist"(){this.manifest.iFramePlaylists.push({attributes:T.attributes,uri:T.uri,timeline:y}),this.warnOnMissingAttributes_("#EXT-X-I-FRAME-STREAM-INF",T.attributes,["BANDWIDTH","URI"])}}[T.tagType]||d).call(i)},uri(){a.uri=T.uri,r.push(a),this.manifest.targetDuration&&!("duration"in a)&&(this.trigger("warn",{message:"defaulting segment duration to the target duration"}),a.duration=this.manifest.targetDuration),l&&(a.key=l),a.timeline=y,o&&(a.map=o),x=0,this.lastProgramDateTime!==null&&(a.programDateTime=this.lastProgramDateTime,this.lastProgramDateTime+=a.duration*1e3),a={}},comment(){},custom(){T.segment?(a.custom=a.custom||{},a.custom[T.customType]=T.data):(this.manifest.custom=this.manifest.custom||{},this.manifest.custom[T.customType]=T.data)}})[T.type].call(i)})}requiredCompatibilityversion(e,i){(e<i||!e)&&this.trigger("warn",{message:`manifest must be at least version ${i}`})}warnOnMissingAttributes_(e,i,r){const a=[];r.forEach(function(o){i.hasOwnProperty(o)||a.push(o)}),a.length&&this.trigger("warn",{message:`${e} lacks required attribute(s): ${a.join(", ")}`})}push(e){this.lineStream.push(e)}end(){this.lineStream.push(`
|
|
23
|
+
`),this.manifest.dateRanges.length&&this.lastProgramDateTime===null&&this.trigger("warn",{message:"A playlist with EXT-X-DATERANGE tag must contain atleast one EXT-X-PROGRAM-DATE-TIME tag"}),this.lastProgramDateTime=null,this.trigger("end")}addParser(e){this.parseStream.addParser(e)}addTagMapper(e){this.parseStream.addTagMapper(e)}}var Nn={mp4:/^(av0?1|avc0?[1234]|vp0?9|flac|opus|mp3|mp4a|mp4v|stpp.ttml.im1t)/,webm:/^(vp0?[89]|av0?1|opus|vorbis)/,ogg:/^(vp0?[89]|theora|flac|opus|vorbis)/,video:/^(av0?1|avc0?[1234]|vp0?[89]|hvc1|hev1|theora|mp4v)/,audio:/^(mp4a|flac|vorbis|opus|ac-[34]|ec-3|alac|mp3|speex|aac)/,text:/^(stpp.ttml.im1t)/,muxerVideo:/^(avc0?1)/,muxerAudio:/^(mp4a)/,muxerText:/a^/},Ub=["video","audio","text"],Hc=["Video","Audio","Text"],Nh=function(e){return e&&e.replace(/avc1\.(\d+)\.(\d+)/i,function(i,r,a){var o=("00"+Number(r).toString(16)).slice(-2),l=("00"+Number(a).toString(16)).slice(-2);return"avc1."+o+"00"+l})},Fi=function(e){e===void 0&&(e="");var i=e.split(","),r=[];return i.forEach(function(a){a=a.trim();var o;Ub.forEach(function(l){var u=Nn[l].exec(a.toLowerCase());if(!(!u||u.length<=1)){o=l;var d=a.substring(0,u[1].length),f=a.replace(d,"");r.push({type:d,details:f,mediaType:l})}}),o||r.push({type:a,details:"",mediaType:"unknown"})}),r},qb=function(e,i){if(!e.mediaGroups.AUDIO||!i)return null;var r=e.mediaGroups.AUDIO[i];if(!r)return null;for(var a in r){var o=r[a];if(o.default&&o.playlists)return Fi(o.playlists[0].attributes.CODECS)}return null},Oh=function(e){return e===void 0&&(e=""),Nn.audio.test(e.trim().toLowerCase())},jb=function(e){return e===void 0&&(e=""),Nn.text.test(e.trim().toLowerCase())},sr=function(e){if(!(!e||typeof e!="string")){var i=e.toLowerCase().split(",").map(function(o){return Nh(o.trim())}),r="video";i.length===1&&Oh(i[0])?r="audio":i.length===1&&jb(i[0])&&(r="application");var a="mp4";return i.every(function(o){return Nn.mp4.test(o)})?a="mp4":i.every(function(o){return Nn.webm.test(o)})?a="webm":i.every(function(o){return Nn.ogg.test(o)})&&(a="ogg"),r+"/"+a+';codecs="'+e+'"'}},Kr=function(e,i){return e===void 0&&(e=""),i===void 0&&(i=!1),W.MediaSource&&W.MediaSource.isTypeSupported&&W.MediaSource.isTypeSupported(sr(e))||i&&W.ManagedMediaSource&&W.ManagedMediaSource.isTypeSupported&&W.ManagedMediaSource.isTypeSupported(sr(e))||!1},Ao=function(e){return e===void 0&&(e=""),e.toLowerCase().split(",").every(function(i){i=i.trim();for(var r=0;r<Hc.length;r++){var a=Hc[r];if(Nn["muxer"+a].test(i))return!0}return!1})},zc="mp4a.40.2",Hb="avc1.4d400d",zb=/^(audio|video|application)\/(x-|vnd\.apple\.)?mpegurl/i,Gb=/^application\/dash\+xml/i,Bh=function(e){return zb.test(e)?"hls":Gb.test(e)?"dash":e==="application/vnd.videojs.vhs+json"?"vhs-json":null},Wb=function(e){return e.toString(2).length},Yb=function(e){return Math.ceil(Wb(e)/8)},Lh=function(e){return ArrayBuffer.isView==="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer},Xb=function(e){return Lh(e)},Ne=function(e){return e instanceof Uint8Array?e:(!Array.isArray(e)&&!Xb(e)&&!(e instanceof ArrayBuffer)&&(typeof e!="number"||typeof e=="number"&&e!==e?e=0:e=[e]),new Uint8Array(e&&e.buffer||e,e&&e.byteOffset||0,e&&e.byteLength||0))},Lt=W.BigInt||Number,el=[Lt("0x1"),Lt("0x100"),Lt("0x10000"),Lt("0x1000000"),Lt("0x100000000"),Lt("0x10000000000"),Lt("0x1000000000000"),Lt("0x100000000000000"),Lt("0x10000000000000000")];(function(){var s=new Uint16Array([65484]),e=new Uint8Array(s.buffer,s.byteOffset,s.byteLength);return e[0]===255?"big":e[0]===204?"little":"unknown"})();var Kb=function(e,i){var r=i===void 0?{}:i,a=r.signed,o=a===void 0?!1:a,l=r.le,u=l===void 0?!1:l;e=Ne(e);var d=u?"reduce":"reduceRight",f=e[d]?e[d]:Array.prototype[d],g=f.call(e,function(E,x,B){var T=u?B:Math.abs(B+1-e.length);return E+Lt(x)*el[T]},Lt(0));if(o){var y=el[e.length]/Lt(2)-Lt(1);g=Lt(g),g>y&&(g-=y,g-=y,g-=Lt(2))}return Number(g)},Qb=function(e,i){var r={},a=r.le,o=a===void 0?!1:a;(typeof e!="bigint"&&typeof e!="number"||typeof e=="number"&&e!==e)&&(e=0),e=Lt(e);for(var l=Yb(e),u=new Uint8Array(new ArrayBuffer(l)),d=0;d<l;d++){var f=o?d:Math.abs(d+1-u.length);u[f]=Number(e/el[d]&Lt(255)),e<0&&(u[f]=Math.abs(~u[f]),u[f]-=d===0?1:2)}return u},Ph=function(e,i){if(typeof e!="string"&&e&&typeof e.toString=="function"&&(e=e.toString()),typeof e!="string")return new Uint8Array;i||(e=unescape(encodeURIComponent(e)));for(var r=new Uint8Array(e.length),a=0;a<e.length;a++)r[a]=e.charCodeAt(a);return r},Zb=function(){for(var e=arguments.length,i=new Array(e),r=0;r<e;r++)i[r]=arguments[r];if(i=i.filter(function(u){return u&&(u.byteLength||u.length)&&typeof u!="string"}),i.length<=1)return Ne(i[0]);var a=i.reduce(function(u,d,f){return u+(d.byteLength||d.length)},0),o=new Uint8Array(a),l=0;return i.forEach(function(u){u=Ne(u),o.set(u,l),l+=u.byteLength}),o},ct=function(e,i,r){var a=r===void 0?{}:r,o=a.offset,l=o===void 0?0:o,u=a.mask,d=u===void 0?[]:u;e=Ne(e),i=Ne(i);var f=i.every?i.every:Array.prototype.every;return i.length&&e.length-l>=i.length&&f.call(i,function(g,y){var E=d[y]?d[y]&e[l+y]:e[l+y];return g===E})},Jb=function(e,i,r){i.forEach(function(a){for(var o in e.mediaGroups[a])for(var l in e.mediaGroups[a][o]){var u=e.mediaGroups[a][o][l];r(u,a,o,l)}})},Ur={},Qi={},Sn={},Gc;function ka(){if(Gc)return Sn;Gc=1;function s(o,l,u){if(u===void 0&&(u=Array.prototype),o&&typeof u.find=="function")return u.find.call(o,l);for(var d=0;d<o.length;d++)if(Object.prototype.hasOwnProperty.call(o,d)){var f=o[d];if(l.call(void 0,f,d,o))return f}}function e(o,l){return l===void 0&&(l=Object),l&&typeof l.freeze=="function"?l.freeze(o):o}function i(o,l){if(o===null||typeof o!="object")throw new TypeError("target is not an object");for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(o[u]=l[u]);return o}var r=e({HTML:"text/html",isHTML:function(o){return o===r.HTML},XML_APPLICATION:"application/xml",XML_TEXT:"text/xml",XML_XHTML_APPLICATION:"application/xhtml+xml",XML_SVG_IMAGE:"image/svg+xml"}),a=e({HTML:"http://www.w3.org/1999/xhtml",isHTML:function(o){return o===a.HTML},SVG:"http://www.w3.org/2000/svg",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/"});return Sn.assign=i,Sn.find=s,Sn.freeze=e,Sn.MIME_TYPE=r,Sn.NAMESPACE=a,Sn}var Wc;function Mh(){if(Wc)return Qi;Wc=1;var s=ka(),e=s.find,i=s.NAMESPACE;function r(S){return S!==""}function a(S){return S?S.split(/[\t\n\f\r ]+/).filter(r):[]}function o(S,D){return S.hasOwnProperty(D)||(S[D]=!0),S}function l(S){if(!S)return[];var D=a(S);return Object.keys(D.reduce(o,{}))}function u(S){return function(D){return S&&S.indexOf(D)!==-1}}function d(S,D){for(var X in S)Object.prototype.hasOwnProperty.call(S,X)&&(D[X]=S[X])}function f(S,D){var X=S.prototype;if(!(X instanceof D)){let re=function(){};re.prototype=D.prototype,re=new re,d(X,re),S.prototype=X=re}X.constructor!=S&&(typeof S!="function"&&console.error("unknown Class:"+S),X.constructor=S)}var g={},y=g.ELEMENT_NODE=1,E=g.ATTRIBUTE_NODE=2,x=g.TEXT_NODE=3,B=g.CDATA_SECTION_NODE=4,T=g.ENTITY_REFERENCE_NODE=5,w=g.ENTITY_NODE=6,F=g.PROCESSING_INSTRUCTION_NODE=7,P=g.COMMENT_NODE=8,I=g.DOCUMENT_NODE=9,K=g.DOCUMENT_TYPE_NODE=10,q=g.DOCUMENT_FRAGMENT_NODE=11,M=g.NOTATION_NODE=12,N={},J={};N.INDEX_SIZE_ERR=(J[1]="Index size error",1),N.DOMSTRING_SIZE_ERR=(J[2]="DOMString size error",2);var b=N.HIERARCHY_REQUEST_ERR=(J[3]="Hierarchy request error",3);N.WRONG_DOCUMENT_ERR=(J[4]="Wrong document",4);var C=N.INVALID_CHARACTER_ERR=(J[5]="Invalid character",5);N.NO_DATA_ALLOWED_ERR=(J[6]="No data allowed",6),N.NO_MODIFICATION_ALLOWED_ERR=(J[7]="No modification allowed",7);var U=N.NOT_FOUND_ERR=(J[8]="Not found",8);N.NOT_SUPPORTED_ERR=(J[9]="Not supported",9);var j=N.INUSE_ATTRIBUTE_ERR=(J[10]="Attribute in use",10);N.INVALID_STATE_ERR=(J[11]="Invalid state",11),N.SYNTAX_ERR=(J[12]="Syntax error",12),N.INVALID_MODIFICATION_ERR=(J[13]="Invalid modification",13),N.NAMESPACE_ERR=(J[14]="Invalid namespace",14),N.INVALID_ACCESS_ERR=(J[15]="Invalid access",15);function k(S,D){if(D instanceof Error)var X=D;else X=this,Error.call(this,J[S]),this.message=J[S],Error.captureStackTrace&&Error.captureStackTrace(this,k);return X.code=S,D&&(this.message=this.message+": "+D),X}k.prototype=Error.prototype,d(N,k);function A(){}A.prototype={length:0,item:function(S){return S>=0&&S<this.length?this[S]:null},toString:function(S,D){for(var X=[],re=0;re<this.length;re++)Ht(this[re],X,S,D);return X.join("")},filter:function(S){return Array.prototype.filter.call(this,S)},indexOf:function(S){return Array.prototype.indexOf.call(this,S)}};function $(S,D){this._node=S,this._refresh=D,Q(this)}function Q(S){var D=S._node._inc||S._node.ownerDocument._inc;if(S._inc!==D){var X=S._refresh(S._node);if(Si(S,"length",X.length),!S.$$length||X.length<S.$$length)for(var re=X.length;re in S;re++)Object.prototype.hasOwnProperty.call(S,re)&&delete S[re];d(X,S),S._inc=D}}$.prototype.item=function(S){return Q(this),this[S]||null},f($,A);function H(){}function V(S,D){for(var X=S.length;X--;)if(S[X]===D)return X}function G(S,D,X,re){if(re?D[V(D,re)]=X:D[D.length++]=X,S){X.ownerElement=S;var ge=S.ownerDocument;ge&&(re&&De(ge,S,re),qe(ge,S,X))}}function Z(S,D,X){var re=V(D,X);if(re>=0){for(var ge=D.length-1;re<ge;)D[re]=D[++re];if(D.length=ge,S){var Ie=S.ownerDocument;Ie&&(De(Ie,S,X),X.ownerElement=null)}}else throw new k(U,new Error(S.tagName+"@"+X))}H.prototype={length:0,item:A.prototype.item,getNamedItem:function(S){for(var D=this.length;D--;){var X=this[D];if(X.nodeName==S)return X}},setNamedItem:function(S){var D=S.ownerElement;if(D&&D!=this._ownerElement)throw new k(j);var X=this.getNamedItem(S.nodeName);return G(this._ownerElement,this,S,X),X},setNamedItemNS:function(S){var D=S.ownerElement,X;if(D&&D!=this._ownerElement)throw new k(j);return X=this.getNamedItemNS(S.namespaceURI,S.localName),G(this._ownerElement,this,S,X),X},removeNamedItem:function(S){var D=this.getNamedItem(S);return Z(this._ownerElement,this,D),D},removeNamedItemNS:function(S,D){var X=this.getNamedItemNS(S,D);return Z(this._ownerElement,this,X),X},getNamedItemNS:function(S,D){for(var X=this.length;X--;){var re=this[X];if(re.localName==D&&re.namespaceURI==S)return re}return null}};function te(){}te.prototype={hasFeature:function(S,D){return!0},createDocument:function(S,D,X){var re=new de;if(re.implementation=this,re.childNodes=new A,re.doctype=X||null,X&&re.appendChild(X),D){var ge=re.createElementNS(S,D);re.appendChild(ge)}return re},createDocumentType:function(S,D,X){var re=new _t;return re.name=S,re.nodeName=S,re.publicId=D||"",re.systemId=X||"",re}};function se(){}se.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(S,D){return Pe(this,S,D)},replaceChild:function(S,D){Pe(this,S,D,at),D&&this.removeChild(D)},removeChild:function(S){return We(this,S)},appendChild:function(S){return this.insertBefore(S,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(S){return Rt(this.ownerDocument||this,this,S)},normalize:function(){for(var S=this.firstChild;S;){var D=S.nextSibling;D&&D.nodeType==x&&S.nodeType==x?(this.removeChild(D),S.appendData(D.data)):(S.normalize(),S=D)}},isSupported:function(S,D){return this.ownerDocument.implementation.hasFeature(S,D)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(S){for(var D=this;D;){var X=D._nsMap;if(X){for(var re in X)if(Object.prototype.hasOwnProperty.call(X,re)&&X[re]===S)return re}D=D.nodeType==E?D.ownerDocument:D.parentNode}return null},lookupNamespaceURI:function(S){for(var D=this;D;){var X=D._nsMap;if(X&&Object.prototype.hasOwnProperty.call(X,S))return X[S];D=D.nodeType==E?D.ownerDocument:D.parentNode}return null},isDefaultNamespace:function(S){var D=this.lookupPrefix(S);return D==null}};function ue(S){return S=="<"&&"<"||S==">"&&">"||S=="&"&&"&"||S=='"'&&"""||"&#"+S.charCodeAt()+";"}d(g,se),d(g,se.prototype);function ce(S,D){if(D(S))return!0;if(S=S.firstChild)do if(ce(S,D))return!0;while(S=S.nextSibling)}function de(){this.ownerDocument=this}function qe(S,D,X){S&&S._inc++;var re=X.namespaceURI;re===i.XMLNS&&(D._nsMap[X.prefix?X.localName:""]=X.value)}function De(S,D,X,re){S&&S._inc++;var ge=X.namespaceURI;ge===i.XMLNS&&delete D._nsMap[X.prefix?X.localName:""]}function Oe(S,D,X){if(S&&S._inc){S._inc++;var re=D.childNodes;if(X)re[re.length++]=X;else{for(var ge=D.firstChild,Ie=0;ge;)re[Ie++]=ge,ge=ge.nextSibling;re.length=Ie,delete re[re.length]}}}function We(S,D){var X=D.previousSibling,re=D.nextSibling;return X?X.nextSibling=re:S.firstChild=re,re?re.previousSibling=X:S.lastChild=X,D.parentNode=null,D.previousSibling=null,D.nextSibling=null,Oe(S.ownerDocument,S),D}function Me(S){return S&&(S.nodeType===se.DOCUMENT_NODE||S.nodeType===se.DOCUMENT_FRAGMENT_NODE||S.nodeType===se.ELEMENT_NODE)}function Se(S){return S&&(ke(S)||Ve(S)||me(S)||S.nodeType===se.DOCUMENT_FRAGMENT_NODE||S.nodeType===se.COMMENT_NODE||S.nodeType===se.PROCESSING_INSTRUCTION_NODE)}function me(S){return S&&S.nodeType===se.DOCUMENT_TYPE_NODE}function ke(S){return S&&S.nodeType===se.ELEMENT_NODE}function Ve(S){return S&&S.nodeType===se.TEXT_NODE}function be(S,D){var X=S.childNodes||[];if(e(X,ke)||me(D))return!1;var re=e(X,me);return!(D&&re&&X.indexOf(re)>X.indexOf(D))}function Le(S,D){var X=S.childNodes||[];function re(Ie){return ke(Ie)&&Ie!==D}if(e(X,re))return!1;var ge=e(X,me);return!(D&&ge&&X.indexOf(ge)>X.indexOf(D))}function ht(S,D,X){if(!Me(S))throw new k(b,"Unexpected parent node type "+S.nodeType);if(X&&X.parentNode!==S)throw new k(U,"child not in parent");if(!Se(D)||me(D)&&S.nodeType!==se.DOCUMENT_NODE)throw new k(b,"Unexpected node type "+D.nodeType+" for parent node type "+S.nodeType)}function Ze(S,D,X){var re=S.childNodes||[],ge=D.childNodes||[];if(D.nodeType===se.DOCUMENT_FRAGMENT_NODE){var Ie=ge.filter(ke);if(Ie.length>1||e(ge,Ve))throw new k(b,"More than one element or text in fragment");if(Ie.length===1&&!be(S,X))throw new k(b,"Element in fragment can not be inserted before doctype")}if(ke(D)&&!be(S,X))throw new k(b,"Only one element can be added and only after doctype");if(me(D)){if(e(re,me))throw new k(b,"Only one doctype is allowed");var Je=e(re,ke);if(X&&re.indexOf(Je)<re.indexOf(X))throw new k(b,"Doctype can only be inserted before an element");if(!X&&Je)throw new k(b,"Doctype can not be appended since element is present")}}function at(S,D,X){var re=S.childNodes||[],ge=D.childNodes||[];if(D.nodeType===se.DOCUMENT_FRAGMENT_NODE){var Ie=ge.filter(ke);if(Ie.length>1||e(ge,Ve))throw new k(b,"More than one element or text in fragment");if(Ie.length===1&&!Le(S,X))throw new k(b,"Element in fragment can not be inserted before doctype")}if(ke(D)&&!Le(S,X))throw new k(b,"Only one element can be added and only after doctype");if(me(D)){if(e(re,function(zt){return me(zt)&&zt!==X}))throw new k(b,"Only one doctype is allowed");var Je=e(re,ke);if(X&&re.indexOf(Je)<re.indexOf(X))throw new k(b,"Doctype can only be inserted before an element")}}function Pe(S,D,X,re){ht(S,D,X),S.nodeType===se.DOCUMENT_NODE&&(re||Ze)(S,D,X);var ge=D.parentNode;if(ge&&ge.removeChild(D),D.nodeType===q){var Ie=D.firstChild;if(Ie==null)return D;var Je=D.lastChild}else Ie=Je=D;var St=X?X.previousSibling:S.lastChild;Ie.previousSibling=St,Je.nextSibling=X,St?St.nextSibling=Ie:S.firstChild=Ie,X==null?S.lastChild=Je:X.previousSibling=Je;do{Ie.parentNode=S;var zt=S.ownerDocument||S;Fe(Ie,zt)}while(Ie!==Je&&(Ie=Ie.nextSibling));return Oe(S.ownerDocument||S,S),D.nodeType==q&&(D.firstChild=D.lastChild=null),D}function Fe(S,D){if(S.ownerDocument!==D){if(S.ownerDocument=D,S.nodeType===y&&S.attributes)for(var X=0;X<S.attributes.length;X++){var re=S.attributes.item(X);re&&(re.ownerDocument=D)}for(var ge=S.firstChild;ge;)Fe(ge,D),ge=ge.nextSibling}}function ot(S,D){D.parentNode&&D.parentNode.removeChild(D),D.parentNode=S,D.previousSibling=S.lastChild,D.nextSibling=null,D.previousSibling?D.previousSibling.nextSibling=D:S.firstChild=D,S.lastChild=D,Oe(S.ownerDocument,S,D);var X=S.ownerDocument||S;return Fe(D,X),D}de.prototype={nodeName:"#document",nodeType:I,doctype:null,documentElement:null,_inc:1,insertBefore:function(S,D){if(S.nodeType==q){for(var X=S.firstChild;X;){var re=X.nextSibling;this.insertBefore(X,D),X=re}return S}return Pe(this,S,D),Fe(S,this),this.documentElement===null&&S.nodeType===y&&(this.documentElement=S),S},removeChild:function(S){return this.documentElement==S&&(this.documentElement=null),We(this,S)},replaceChild:function(S,D){Pe(this,S,D,at),Fe(S,this),D&&this.removeChild(D),ke(S)&&(this.documentElement=S)},importNode:function(S,D){return Yi(this,S,D)},getElementById:function(S){var D=null;return ce(this.documentElement,function(X){if(X.nodeType==y&&X.getAttribute("id")==S)return D=X,!0}),D},getElementsByClassName:function(S){var D=l(S);return new $(this,function(X){var re=[];return D.length>0&&ce(X.documentElement,function(ge){if(ge!==X&&ge.nodeType===y){var Ie=ge.getAttribute("class");if(Ie){var Je=S===Ie;if(!Je){var St=l(Ie);Je=D.every(u(St))}Je&&re.push(ge)}}}),re})},createElement:function(S){var D=new Ct;D.ownerDocument=this,D.nodeName=S,D.tagName=S,D.localName=S,D.childNodes=new A;var X=D.attributes=new H;return X._ownerElement=D,D},createDocumentFragment:function(){var S=new xi;return S.ownerDocument=this,S.childNodes=new A,S},createTextNode:function(S){var D=new _e;return D.ownerDocument=this,D.appendData(S),D},createComment:function(S){var D=new je;return D.ownerDocument=this,D.appendData(S),D},createCDATASection:function(S){if(S.indexOf("]]>")!==-1)throw new k(C,'data contains "]]>"');var D=new we;return D.ownerDocument=this,D.appendData(S),D},createProcessingInstruction:function(S,D){var X=new jt;return X.ownerDocument=this,X.tagName=X.nodeName=X.target=S,X.nodeValue=X.data=D,X},createAttribute:function(S){var D=new fe;return D.ownerDocument=this,D.name=S,D.nodeName=S,D.localName=S,D.specified=!0,D},createEntityReference:function(S){var D=new Ye;return D.ownerDocument=this,D.nodeName=S,D},createElementNS:function(S,D){var X=new Ct,re=D.split(":"),ge=X.attributes=new H;return X.childNodes=new A,X.ownerDocument=this,X.nodeName=D,X.tagName=D,X.namespaceURI=S,re.length==2?(X.prefix=re[0],X.localName=re[1]):X.localName=D,ge._ownerElement=X,X},createAttributeNS:function(S,D){var X=new fe,re=D.split(":");return X.ownerDocument=this,X.nodeName=D,X.name=D,X.namespaceURI=S,X.specified=!0,re.length==2?(X.prefix=re[0],X.localName=re[1]):X.localName=D,X}},f(de,se);function Ct(){this._nsMap={}}Ct.prototype={nodeType:y,hasAttribute:function(S){return this.getAttributeNode(S)!=null},getAttribute:function(S){var D=this.getAttributeNode(S);return D&&D.value||""},getAttributeNode:function(S){return this.attributes.getNamedItem(S)},setAttribute:function(S,D){var X=this.ownerDocument.createAttribute(S);X.value=X.nodeValue=""+D,this.setAttributeNode(X)},removeAttribute:function(S){var D=this.getAttributeNode(S);D&&this.removeAttributeNode(D)},appendChild:function(S){return S.nodeType===q?this.insertBefore(S,null):ot(this,S)},setAttributeNode:function(S){return this.attributes.setNamedItem(S)},setAttributeNodeNS:function(S){return this.attributes.setNamedItemNS(S)},removeAttributeNode:function(S){return this.attributes.removeNamedItem(S.nodeName)},removeAttributeNS:function(S,D){var X=this.getAttributeNodeNS(S,D);X&&this.removeAttributeNode(X)},hasAttributeNS:function(S,D){return this.getAttributeNodeNS(S,D)!=null},getAttributeNS:function(S,D){var X=this.getAttributeNodeNS(S,D);return X&&X.value||""},setAttributeNS:function(S,D,X){var re=this.ownerDocument.createAttributeNS(S,D);re.value=re.nodeValue=""+X,this.setAttributeNode(re)},getAttributeNodeNS:function(S,D){return this.attributes.getNamedItemNS(S,D)},getElementsByTagName:function(S){return new $(this,function(D){var X=[];return ce(D,function(re){re!==D&&re.nodeType==y&&(S==="*"||re.tagName==S)&&X.push(re)}),X})},getElementsByTagNameNS:function(S,D){return new $(this,function(X){var re=[];return ce(X,function(ge){ge!==X&&ge.nodeType===y&&(S==="*"||ge.namespaceURI===S)&&(D==="*"||ge.localName==D)&&re.push(ge)}),re})}},de.prototype.getElementsByTagName=Ct.prototype.getElementsByTagName,de.prototype.getElementsByTagNameNS=Ct.prototype.getElementsByTagNameNS,f(Ct,se);function fe(){}fe.prototype.nodeType=E,f(fe,se);function ye(){}ye.prototype={data:"",substringData:function(S,D){return this.data.substring(S,S+D)},appendData:function(S){S=this.data+S,this.nodeValue=this.data=S,this.length=S.length},insertData:function(S,D){this.replaceData(S,0,D)},appendChild:function(S){throw new Error(J[b])},deleteData:function(S,D){this.replaceData(S,D,"")},replaceData:function(S,D,X){var re=this.data.substring(0,S),ge=this.data.substring(S+D);X=re+X+ge,this.nodeValue=this.data=X,this.length=X.length}},f(ye,se);function _e(){}_e.prototype={nodeName:"#text",nodeType:x,splitText:function(S){var D=this.data,X=D.substring(S);D=D.substring(0,S),this.data=this.nodeValue=D,this.length=D.length;var re=this.ownerDocument.createTextNode(X);return this.parentNode&&this.parentNode.insertBefore(re,this.nextSibling),re}},f(_e,ye);function je(){}je.prototype={nodeName:"#comment",nodeType:P},f(je,ye);function we(){}we.prototype={nodeName:"#cdata-section",nodeType:B},f(we,ye);function _t(){}_t.prototype.nodeType=K,f(_t,se);function Mt(){}Mt.prototype.nodeType=M,f(Mt,se);function Pi(){}Pi.prototype.nodeType=w,f(Pi,se);function Ye(){}Ye.prototype.nodeType=T,f(Ye,se);function xi(){}xi.prototype.nodeName="#document-fragment",xi.prototype.nodeType=q,f(xi,se);function jt(){}jt.prototype.nodeType=F,f(jt,se);function Ci(){}Ci.prototype.serializeToString=function(S,D,X){return yt.call(S,D,X)},se.prototype.toString=yt;function yt(S,D){var X=[],re=this.nodeType==9&&this.documentElement||this,ge=re.prefix,Ie=re.namespaceURI;if(Ie&&ge==null){var ge=re.lookupPrefix(Ie);if(ge==null)var Je=[{namespace:Ie,prefix:null}]}return Ht(this,X,S,D,Je),X.join("")}function ei(S,D,X){var re=S.prefix||"",ge=S.namespaceURI;if(!ge||re==="xml"&&ge===i.XML||ge===i.XMLNS)return!1;for(var Ie=X.length;Ie--;){var Je=X[Ie];if(Je.prefix===re)return Je.namespace!==ge}return!0}function li(S,D,X){S.push(" ",D,'="',X.replace(/[<>&"\t\n\r]/g,ue),'"')}function Ht(S,D,X,re,ge){if(ge||(ge=[]),re)if(S=re(S),S){if(typeof S=="string"){D.push(S);return}}else return;switch(S.nodeType){case y:var Ie=S.attributes,Je=Ie.length,st=S.firstChild,St=S.tagName;X=i.isHTML(S.namespaceURI)||X;var zt=St;if(!X&&!S.prefix&&S.namespaceURI){for(var Vt,Ot=0;Ot<Ie.length;Ot++)if(Ie.item(Ot).name==="xmlns"){Vt=Ie.item(Ot).value;break}if(!Vt)for(var ti=ge.length-1;ti>=0;ti--){var Xe=ge[ti];if(Xe.prefix===""&&Xe.namespace===S.namespaceURI){Vt=Xe.namespace;break}}if(Vt!==S.namespaceURI)for(var ti=ge.length-1;ti>=0;ti--){var Xe=ge[ti];if(Xe.namespace===S.namespaceURI){Xe.prefix&&(zt=Xe.prefix+":"+St);break}}}D.push("<",zt);for(var ii=0;ii<Je;ii++){var Gt=Ie.item(ii);Gt.prefix=="xmlns"?ge.push({prefix:Gt.localName,namespace:Gt.value}):Gt.nodeName=="xmlns"&&ge.push({prefix:"",namespace:Gt.value})}for(var ii=0;ii<Je;ii++){var Gt=Ie.item(ii);if(ei(Gt,X,ge)){var Wt=Gt.prefix||"",Et=Gt.namespaceURI;li(D,Wt?"xmlns:"+Wt:"xmlns",Et),ge.push({prefix:Wt,namespace:Et})}Ht(Gt,D,X,re,ge)}if(St===zt&&ei(S,X,ge)){var Wt=S.prefix||"",Et=S.namespaceURI;li(D,Wt?"xmlns:"+Wt:"xmlns",Et),ge.push({prefix:Wt,namespace:Et})}if(st||X&&!/^(?:meta|link|img|br|hr|input)$/i.test(St)){if(D.push(">"),X&&/^script$/i.test(St))for(;st;)st.data?D.push(st.data):Ht(st,D,X,re,ge.slice()),st=st.nextSibling;else for(;st;)Ht(st,D,X,re,ge.slice()),st=st.nextSibling;D.push("</",zt,">")}else D.push("/>");return;case I:case q:for(var st=S.firstChild;st;)Ht(st,D,X,re,ge.slice()),st=st.nextSibling;return;case E:return li(D,S.name,S.value);case x:return D.push(S.data.replace(/[<&>]/g,ue));case B:return D.push("<![CDATA[",S.data.replace(/]]>/g,"]]]]><![CDATA[>"),"]]>");case P:return D.push("<!--",S.data,"-->");case K:var He=S.publicId,Ei=S.systemId;if(D.push("<!DOCTYPE ",S.name),He)D.push(" PUBLIC ",He),Ei&&Ei!="."&&D.push(" ",Ei),D.push(">");else if(Ei&&Ei!=".")D.push(" SYSTEM ",Ei,">");else{var Mi=S.internalSubset;Mi&&D.push(" [",Mi,"]"),D.push(">")}return;case F:return D.push("<?",S.target," ",S.data,"?>");case T:return D.push("&",S.nodeName,";");default:D.push("??",S.nodeName)}}function Yi(S,D,X){var re;switch(D.nodeType){case y:re=D.cloneNode(!1),re.ownerDocument=S;case q:break;case E:X=!0;break}if(re||(re=D.cloneNode(!1)),re.ownerDocument=S,re.parentNode=null,X)for(var ge=D.firstChild;ge;)re.appendChild(Yi(S,ge,X)),ge=ge.nextSibling;return re}function Rt(S,D,X){var re=new D.constructor;for(var ge in D)if(Object.prototype.hasOwnProperty.call(D,ge)){var Ie=D[ge];typeof Ie!="object"&&Ie!=re[ge]&&(re[ge]=Ie)}switch(D.childNodes&&(re.childNodes=new A),re.ownerDocument=S,re.nodeType){case y:var Je=D.attributes,St=re.attributes=new H,zt=Je.length;St._ownerElement=re;for(var Vt=0;Vt<zt;Vt++)re.setAttributeNode(Rt(S,Je.item(Vt),!0));break;case E:X=!0}if(X)for(var Ot=D.firstChild;Ot;)re.appendChild(Rt(S,Ot,X)),Ot=Ot.nextSibling;return re}function Si(S,D,X){S[D]=X}try{if(Object.defineProperty){let S=function(D){switch(D.nodeType){case y:case q:var X=[];for(D=D.firstChild;D;)D.nodeType!==7&&D.nodeType!==8&&X.push(S(D)),D=D.nextSibling;return X.join("");default:return D.nodeValue}};Object.defineProperty($.prototype,"length",{get:function(){return Q(this),this.$$length}}),Object.defineProperty(se.prototype,"textContent",{get:function(){return S(this)},set:function(D){switch(this.nodeType){case y:case q:for(;this.firstChild;)this.removeChild(this.firstChild);(D||String(D))&&this.appendChild(this.ownerDocument.createTextNode(D));break;default:this.data=D,this.value=D,this.nodeValue=D}}}),Si=function(D,X,re){D["$$"+X]=re}}}catch{}return Qi.DocumentType=_t,Qi.DOMException=k,Qi.DOMImplementation=te,Qi.Element=Ct,Qi.Node=se,Qi.NodeList=A,Qi.XMLSerializer=Ci,Qi}var qr={},Io={},Yc;function e4(){return Yc||(Yc=1,(function(s){var e=ka().freeze;s.XML_ENTITIES=e({amp:"&",apos:"'",gt:">",lt:"<",quot:'"'}),s.HTML_ENTITIES=e({Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",AMP:"&",amp:"&",And:"⩓",and:"∧",andand:"⩕",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsd:"∡",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",ap:"≈",apacir:"⩯",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",Barwed:"⌆",barwed:"⌅",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",Because:"∵",because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxDL:"╗",boxDl:"╖",boxdL:"╕",boxdl:"┐",boxDR:"╔",boxDr:"╓",boxdR:"╒",boxdr:"┌",boxH:"═",boxh:"─",boxHD:"╦",boxHd:"╤",boxhD:"╥",boxhd:"┬",boxHU:"╩",boxHu:"╧",boxhU:"╨",boxhu:"┴",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxUL:"╝",boxUl:"╜",boxuL:"╛",boxul:"┘",boxUR:"╚",boxUr:"╙",boxuR:"╘",boxur:"└",boxV:"║",boxv:"│",boxVH:"╬",boxVh:"╫",boxvH:"╪",boxvh:"┼",boxVL:"╣",boxVl:"╢",boxvL:"╡",boxvl:"┤",boxVR:"╠",boxVr:"╟",boxvR:"╞",boxvr:"├",bprime:"‵",Breve:"˘",breve:"˘",brvbar:"¦",Bscr:"ℬ",bscr:"𝒷",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsol:"\\",bsolb:"⧅",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",Cap:"⋒",cap:"∩",capand:"⩄",capbrcup:"⩉",capcap:"⩋",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",CenterDot:"·",centerdot:"·",Cfr:"ℭ",cfr:"𝔠",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",cir:"○",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",Colon:"∷",colon:":",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",Conint:"∯",conint:"∮",ContourIntegral:"∮",Copf:"ℂ",copf:"𝕔",coprod:"∐",Coproduct:"∐",COPY:"©",copy:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",Cross:"⨯",cross:"✗",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",Cup:"⋓",cup:"∪",cupbrcap:"⩈",CupCap:"≍",cupcap:"⩆",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",Dagger:"‡",dagger:"†",daleth:"ℸ",Darr:"↡",dArr:"⇓",darr:"↓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",DD:"ⅅ",dd:"ⅆ",ddagger:"‡",ddarr:"⇊",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",Diamond:"⋄",diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrow:"↓",Downarrow:"⇓",downarrow:"↓",DownArrowBar:"⤓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVector:"↽",DownLeftVectorBar:"⥖",DownRightTeeVector:"⥟",DownRightVector:"⇁",DownRightVectorBar:"⥗",DownTee:"⊤",DownTeeArrow:"↧",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",ecir:"≖",Ecirc:"Ê",ecirc:"ê",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",eDot:"≑",edot:"ė",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp:" ",emsp13:" ",emsp14:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",Escr:"ℰ",escr:"ℯ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",ExponentialE:"ⅇ",exponentiale:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",ForAll:"∀",forall:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",Fscr:"ℱ",fscr:"𝒻",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",gE:"≧",ge:"≥",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",ges:"⩾",gescc:"⪩",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",Gg:"⋙",gg:"≫",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gl:"≷",gla:"⪥",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gnE:"≩",gne:"⪈",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",Gt:"≫",GT:">",gt:">",gtcc:"⪧",gtcir:"⩺",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",hArr:"⇔",harr:"↔",harrcir:"⥈",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",Hfr:"ℌ",hfr:"𝔥",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",Hopf:"ℍ",hopf:"𝕙",horbar:"―",HorizontalLine:"─",Hscr:"ℋ",hscr:"𝒽",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",Ifr:"ℑ",ifr:"𝔦",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Im:"ℑ",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",imof:"⊷",imped:"Ƶ",Implies:"⇒",in:"∈",incare:"℅",infin:"∞",infintie:"⧝",inodot:"ı",Int:"∬",int:"∫",intcal:"⊺",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"",InvisibleTimes:"",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",Iscr:"ℐ",iscr:"𝒾",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",Lang:"⟪",lang:"⟨",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",Larr:"↞",lArr:"⇐",larr:"←",larrb:"⇤",larrbfs:"⤟",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",lat:"⪫",lAtail:"⤛",latail:"⤙",late:"⪭",lates:"⪭︀",lBarr:"⤎",lbarr:"⤌",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",lE:"≦",le:"≤",LeftAngleBracket:"⟨",LeftArrow:"←",Leftarrow:"⇐",leftarrow:"←",LeftArrowBar:"⇤",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVector:"⇃",LeftDownVectorBar:"⥙",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrow:"↔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTee:"⊣",LeftTeeArrow:"↤",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangle:"⊲",LeftTriangleBar:"⧏",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVector:"↿",LeftUpVectorBar:"⥘",LeftVector:"↼",LeftVectorBar:"⥒",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",les:"⩽",lescc:"⪨",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",Ll:"⋘",ll:"≪",llarr:"⇇",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoust:"⎰",lmoustache:"⎰",lnap:"⪉",lnapprox:"⪉",lnE:"≨",lne:"⪇",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftarrow:"⟵",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longleftrightarrow:"⟷",longmapsto:"⟼",LongRightArrow:"⟶",Longrightarrow:"⟹",longrightarrow:"⟶",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"",lrtri:"⊿",lsaquo:"‹",Lscr:"ℒ",lscr:"𝓁",Lsh:"↰",lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",Lt:"≪",LT:"<",lt:"<",ltcc:"⪦",ltcir:"⩹",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",mid:"∣",midast:"*",midcir:"⫰",middot:"·",minus:"−",minusb:"⊟",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",Mscr:"ℳ",mscr:"𝓂",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natur:"♮",natural:"♮",naturals:"ℕ",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",ne:"≠",nearhk:"⤤",neArr:"⇗",nearr:"↗",nearrow:"↗",nedot:"≐̸",NegativeMediumSpace:"",NegativeThickSpace:"",NegativeThinSpace:"",NegativeVeryThinSpace:"",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:`
|
|
24
|
+
`,nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nhArr:"⇎",nharr:"↮",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlArr:"⇍",nlarr:"↚",nldr:"‥",nlE:"≦̸",nle:"≰",nLeftarrow:"⇍",nleftarrow:"↚",nLeftrightarrow:"⇎",nleftrightarrow:"↮",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"",NonBreakingSpace:" ",Nopf:"ℕ",nopf:"𝕟",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangle:"⋪",NotLeftTriangleBar:"⧏̸",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangle:"⋫",NotRightTriangleBar:"⧐̸",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",npar:"∦",nparallel:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",npre:"⪯̸",nprec:"⊀",npreceq:"⪯̸",nrArr:"⇏",nrarr:"↛",nrarrc:"⤳̸",nrarrw:"↝̸",nRightarrow:"⇏",nrightarrow:"↛",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nVDash:"⊯",nVdash:"⊮",nvDash:"⊭",nvdash:"⊬",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwArr:"⇖",nwarr:"↖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",ocir:"⊚",Ocirc:"Ô",ocirc:"ô",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",Or:"⩔",or:"∨",orarr:"↻",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",Otimes:"⨷",otimes:"⊗",otimesas:"⨶",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",par:"∥",para:"¶",parallel:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plus:"+",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",Popf:"ℙ",popf:"𝕡",pound:"£",Pr:"⪻",pr:"≺",prap:"⪷",prcue:"≼",prE:"⪳",pre:"⪯",prec:"≺",precapprox:"⪷",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",precsim:"≾",Prime:"″",prime:"′",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportion:"∷",Proportional:"∝",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",Qopf:"ℚ",qopf:"𝕢",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",QUOT:'"',quot:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",Rang:"⟫",rang:"⟩",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",Rarr:"↠",rArr:"⇒",rarr:"→",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",rAtail:"⤜",ratail:"⤚",ratio:"∶",rationals:"ℚ",RBarr:"⤐",rBarr:"⤏",rbarr:"⤍",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",Re:"ℜ",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",rect:"▭",REG:"®",reg:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",Rfr:"ℜ",rfr:"𝔯",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrow:"→",Rightarrow:"⇒",rightarrow:"→",RightArrowBar:"⇥",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVector:"⇂",RightDownVectorBar:"⥕",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTee:"⊢",RightTeeArrow:"↦",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangle:"⊳",RightTriangleBar:"⧐",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVector:"↾",RightUpVectorBar:"⥔",RightVector:"⇀",RightVectorBar:"⥓",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"",rmoust:"⎱",rmoustache:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",Ropf:"ℝ",ropf:"𝕣",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",Rscr:"ℛ",rscr:"𝓇",Rsh:"↱",rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",Sc:"⪼",sc:"≻",scap:"⪸",Scaron:"Š",scaron:"š",sccue:"≽",scE:"⪴",sce:"⪰",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdot:"⋅",sdotb:"⊡",sdote:"⩦",searhk:"⤥",seArr:"⇘",searr:"↘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",sol:"/",solb:"⧄",solbar:"⌿",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",squ:"□",Square:"□",square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",Sub:"⋐",sub:"⊂",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",Subset:"⋐",subset:"⊂",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succ:"≻",succapprox:"⪸",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",Sum:"∑",sum:"∑",sung:"♪",Sup:"⋑",sup:"⊃",sup1:"¹",sup2:"²",sup3:"³",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",Supset:"⋑",supset:"⊃",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swArr:"⇙",swarr:"↙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:" ",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",Therefore:"∴",therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:" ",thinsp:" ",ThinSpace:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",Tilde:"∼",tilde:"˜",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",times:"×",timesb:"⊠",timesbar:"⨱",timesd:"⨰",tint:"∭",toea:"⤨",top:"⊤",topbot:"⌶",topcir:"⫱",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",TRADE:"™",trade:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",Uarr:"↟",uArr:"⇑",uarr:"↑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrow:"↑",Uparrow:"⇑",uparrow:"↑",UpArrowBar:"⤒",UpArrowDownArrow:"⇅",UpDownArrow:"↕",Updownarrow:"⇕",updownarrow:"↕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",Upsi:"ϒ",upsi:"υ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTee:"⊥",UpTeeArrow:"↥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",vArr:"⇕",varr:"↕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",Vbar:"⫫",vBar:"⫨",vBarv:"⫩",Vcy:"В",vcy:"в",VDash:"⊫",Vdash:"⊩",vDash:"⊨",vdash:"⊢",Vdashl:"⫦",Vee:"⋁",vee:"∨",veebar:"⊻",veeeq:"≚",vellip:"⋮",Verbar:"‖",verbar:"|",Vert:"‖",vert:"|",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",Wedge:"⋀",wedge:"∧",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xhArr:"⟺",xharr:"⟷",Xi:"Ξ",xi:"ξ",xlArr:"⟸",xlarr:"⟵",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrArr:"⟹",xrarr:"⟶",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",Yuml:"Ÿ",yuml:"ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"",Zeta:"Ζ",zeta:"ζ",Zfr:"ℨ",zfr:"𝔷",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",Zopf:"ℤ",zopf:"𝕫",Zscr:"𝒵",zscr:"𝓏",zwj:"",zwnj:""}),s.entityMap=s.HTML_ENTITIES})(Io)),Io}var $s={},Xc;function t4(){if(Xc)return $s;Xc=1;var s=ka().NAMESPACE,e=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,i=new RegExp("[\\-\\.0-9"+e.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),r=new RegExp("^"+e.source+i.source+"*(?::"+e.source+i.source+"*)?$"),a=0,o=1,l=2,u=3,d=4,f=5,g=6,y=7;function E(b,C){this.message=b,this.locator=C,Error.captureStackTrace&&Error.captureStackTrace(this,E)}E.prototype=new Error,E.prototype.name=E.name;function x(){}x.prototype={parse:function(b,C,U){var j=this.domBuilder;j.startDocument(),K(C,C={}),B(b,C,U,j,this.errorHandler),j.endDocument()}};function B(b,C,U,j,k){function A(Fe){if(Fe>65535){Fe-=65536;var ot=55296+(Fe>>10),Ct=56320+(Fe&1023);return String.fromCharCode(ot,Ct)}else return String.fromCharCode(Fe)}function $(Fe){var ot=Fe.slice(1,-1);return Object.hasOwnProperty.call(U,ot)?U[ot]:ot.charAt(0)==="#"?A(parseInt(ot.substr(1).replace("x","0x"))):(k.error("entity not found:"+Fe),Fe)}function Q(Fe){if(Fe>ce){var ot=b.substring(ce,Fe).replace(/&#?\w+;/g,$);te&&H(ce),j.characters(ot,0,Fe-ce),ce=Fe}}function H(Fe,ot){for(;Fe>=G&&(ot=Z.exec(b));)V=ot.index,G=V+ot[0].length,te.lineNumber++;te.columnNumber=Fe-V+1}for(var V=0,G=0,Z=/.*(?:\r\n?|\n)|.*$/g,te=j.locator,se=[{currentNSMap:C}],ue={},ce=0;;){try{var de=b.indexOf("<",ce);if(de<0){if(!b.substr(ce).match(/^\s*$/)){var qe=j.doc,De=qe.createTextNode(b.substr(ce));qe.appendChild(De),j.currentElement=De}return}switch(de>ce&&Q(de),b.charAt(de+1)){case"/":var Le=b.indexOf(">",de+3),Oe=b.substring(de+2,Le).replace(/[ \t\n\r]+$/g,""),We=se.pop();Le<0?(Oe=b.substring(de+2).replace(/[\s<].*/,""),k.error("end tag name: "+Oe+" is not complete:"+We.tagName),Le=de+1+Oe.length):Oe.match(/\s</)&&(Oe=Oe.replace(/[\s<].*/,""),k.error("end tag name: "+Oe+" maybe not complete"),Le=de+1+Oe.length);var Me=We.localNSMap,Se=We.tagName==Oe,me=Se||We.tagName&&We.tagName.toLowerCase()==Oe.toLowerCase();if(me){if(j.endElement(We.uri,We.localName,Oe),Me)for(var ke in Me)Object.prototype.hasOwnProperty.call(Me,ke)&&j.endPrefixMapping(ke);Se||k.fatalError("end tag name: "+Oe+" is not match the current start tagName:"+We.tagName)}else se.push(We);Le++;break;case"?":te&&H(de),Le=M(b,de,j);break;case"!":te&&H(de),Le=q(b,de,j,k);break;default:te&&H(de);var Ve=new N,be=se[se.length-1].currentNSMap,Le=w(b,de,Ve,be,$,k),ht=Ve.length;if(!Ve.closed&&I(b,Le,Ve.tagName,ue)&&(Ve.closed=!0,U.nbsp||k.warning("unclosed xml attribute")),te&&ht){for(var Ze=T(te,{}),at=0;at<ht;at++){var Pe=Ve[at];H(Pe.offset),Pe.locator=T(te,{})}j.locator=Ze,F(Ve,j,be)&&se.push(Ve),j.locator=te}else F(Ve,j,be)&&se.push(Ve);s.isHTML(Ve.uri)&&!Ve.closed?Le=P(b,Le,Ve.tagName,$,j):Le++}}catch(Fe){if(Fe instanceof E)throw Fe;k.error("element parse error: "+Fe),Le=-1}Le>ce?ce=Le:Q(Math.max(de,ce)+1)}}function T(b,C){return C.lineNumber=b.lineNumber,C.columnNumber=b.columnNumber,C}function w(b,C,U,j,k,A){function $(te,se,ue){U.attributeNames.hasOwnProperty(te)&&A.fatalError("Attribute "+te+" redefined"),U.addValue(te,se.replace(/[\t\n\r]/g," ").replace(/&#?\w+;/g,k),ue)}for(var Q,H,V=++C,G=a;;){var Z=b.charAt(V);switch(Z){case"=":if(G===o)Q=b.slice(C,V),G=u;else if(G===l)G=u;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(G===u||G===o)if(G===o&&(A.warning('attribute value must after "="'),Q=b.slice(C,V)),C=V+1,V=b.indexOf(Z,C),V>0)H=b.slice(C,V),$(Q,H,C-1),G=f;else throw new Error("attribute value no end '"+Z+"' match");else if(G==d)H=b.slice(C,V),$(Q,H,C),A.warning('attribute "'+Q+'" missed start quot('+Z+")!!"),C=V+1,G=f;else throw new Error('attribute value must after "="');break;case"/":switch(G){case a:U.setTagName(b.slice(C,V));case f:case g:case y:G=y,U.closed=!0;case d:case o:break;case l:U.closed=!0;break;default:throw new Error("attribute invalid close char('/')")}break;case"":return A.error("unexpected end of input"),G==a&&U.setTagName(b.slice(C,V)),V;case">":switch(G){case a:U.setTagName(b.slice(C,V));case f:case g:case y:break;case d:case o:H=b.slice(C,V),H.slice(-1)==="/"&&(U.closed=!0,H=H.slice(0,-1));case l:G===l&&(H=Q),G==d?(A.warning('attribute "'+H+'" missed quot(")!'),$(Q,H,C)):((!s.isHTML(j[""])||!H.match(/^(?:disabled|checked|selected)$/i))&&A.warning('attribute "'+H+'" missed value!! "'+H+'" instead!!'),$(H,H,C));break;case u:throw new Error("attribute value missed!!")}return V;case"":Z=" ";default:if(Z<=" ")switch(G){case a:U.setTagName(b.slice(C,V)),G=g;break;case o:Q=b.slice(C,V),G=l;break;case d:var H=b.slice(C,V);A.warning('attribute "'+H+'" missed quot(")!!'),$(Q,H,C);case f:G=g;break}else switch(G){case l:U.tagName,(!s.isHTML(j[""])||!Q.match(/^(?:disabled|checked|selected)$/i))&&A.warning('attribute "'+Q+'" missed value!! "'+Q+'" instead2!!'),$(Q,Q,C),C=V,G=o;break;case f:A.warning('attribute space is required"'+Q+'"!!');case g:G=o,C=V;break;case u:G=d,C=V;break;case y:throw new Error("elements closed character '/' and '>' must be connected to")}}V++}}function F(b,C,U){for(var j=b.tagName,k=null,Z=b.length;Z--;){var A=b[Z],$=A.qName,Q=A.value,te=$.indexOf(":");if(te>0)var H=A.prefix=$.slice(0,te),V=$.slice(te+1),G=H==="xmlns"&&V;else V=$,H=null,G=$==="xmlns"&&"";A.localName=V,G!==!1&&(k==null&&(k={},K(U,U={})),U[G]=k[G]=Q,A.uri=s.XMLNS,C.startPrefixMapping(G,Q))}for(var Z=b.length;Z--;){A=b[Z];var H=A.prefix;H&&(H==="xml"&&(A.uri=s.XML),H!=="xmlns"&&(A.uri=U[H||""]))}var te=j.indexOf(":");te>0?(H=b.prefix=j.slice(0,te),V=b.localName=j.slice(te+1)):(H=null,V=b.localName=j);var se=b.uri=U[H||""];if(C.startElement(se,V,j,b),b.closed){if(C.endElement(se,V,j),k)for(H in k)Object.prototype.hasOwnProperty.call(k,H)&&C.endPrefixMapping(H)}else return b.currentNSMap=U,b.localNSMap=k,!0}function P(b,C,U,j,k){if(/^(?:script|textarea)$/i.test(U)){var A=b.indexOf("</"+U+">",C),$=b.substring(C+1,A);if(/[&<]/.test($))return/^script$/i.test(U)?(k.characters($,0,$.length),A):($=$.replace(/&#?\w+;/g,j),k.characters($,0,$.length),A)}return C+1}function I(b,C,U,j){var k=j[U];return k==null&&(k=b.lastIndexOf("</"+U+">"),k<C&&(k=b.lastIndexOf("</"+U)),j[U]=k),k<C}function K(b,C){for(var U in b)Object.prototype.hasOwnProperty.call(b,U)&&(C[U]=b[U])}function q(b,C,U,j){var k=b.charAt(C+2);switch(k){case"-":if(b.charAt(C+3)==="-"){var A=b.indexOf("-->",C+4);return A>C?(U.comment(b,C+4,A-C-4),A+3):(j.error("Unclosed comment"),-1)}else return-1;default:if(b.substr(C+3,6)=="CDATA["){var A=b.indexOf("]]>",C+9);return U.startCDATA(),U.characters(b,C+9,A-C-9),U.endCDATA(),A+3}var $=J(b,C),Q=$.length;if(Q>1&&/!doctype/i.test($[0][0])){var H=$[1][0],V=!1,G=!1;Q>3&&(/^public$/i.test($[2][0])?(V=$[3][0],G=Q>4&&$[4][0]):/^system$/i.test($[2][0])&&(G=$[3][0]));var Z=$[Q-1];return U.startDTD(H,V,G),U.endDTD(),Z.index+Z[0].length}}return-1}function M(b,C,U){var j=b.indexOf("?>",C);if(j){var k=b.substring(C,j).match(/^<\?(\S*)\s*([\s\S]*?)$/);return k?(k[0].length,U.processingInstruction(k[1],k[2]),j+2):-1}return-1}function N(){this.attributeNames={}}N.prototype={setTagName:function(b){if(!r.test(b))throw new Error("invalid tagName:"+b);this.tagName=b},addValue:function(b,C,U){if(!r.test(b))throw new Error("invalid attribute:"+b);this.attributeNames[b]=this.length,this[this.length++]={qName:b,value:C,offset:U}},length:0,getLocalName:function(b){return this[b].localName},getLocator:function(b){return this[b].locator},getQName:function(b){return this[b].qName},getURI:function(b){return this[b].uri},getValue:function(b){return this[b].value}};function J(b,C){var U,j=[],k=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(k.lastIndex=C,k.exec(b);U=k.exec(b);)if(j.push(U),U[1])return j}return $s.XMLReader=x,$s.ParseError=E,$s}var Kc;function i4(){if(Kc)return qr;Kc=1;var s=ka(),e=Mh(),i=e4(),r=t4(),a=e.DOMImplementation,o=s.NAMESPACE,l=r.ParseError,u=r.XMLReader;function d(w){return w.replace(/\r[\n\u0085]/g,`
|
|
25
|
+
`).replace(/[\r\u0085\u2028]/g,`
|
|
26
|
+
`)}function f(w){this.options=w||{locator:{}}}f.prototype.parseFromString=function(w,F){var P=this.options,I=new u,K=P.domBuilder||new y,q=P.errorHandler,M=P.locator,N=P.xmlns||{},J=/\/x?html?$/.test(F),b=J?i.HTML_ENTITIES:i.XML_ENTITIES;M&&K.setDocumentLocator(M),I.errorHandler=g(q,K,M),I.domBuilder=P.domBuilder||K,J&&(N[""]=o.HTML),N.xml=N.xml||o.XML;var C=P.normalizeLineEndings||d;return w&&typeof w=="string"?I.parse(C(w),N,b):I.errorHandler.error("invalid doc source"),K.doc};function g(w,F,P){if(!w){if(F instanceof y)return F;w=F}var I={},K=w instanceof Function;P=P||{};function q(M){var N=w[M];!N&&K&&(N=w.length==2?function(J){w(M,J)}:w),I[M]=N&&function(J){N("[xmldom "+M+"] "+J+x(P))}||function(){}}return q("warning"),q("error"),q("fatalError"),I}function y(){this.cdata=!1}function E(w,F){F.lineNumber=w.lineNumber,F.columnNumber=w.columnNumber}y.prototype={startDocument:function(){this.doc=new a().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(w,F,P,I){var K=this.doc,q=K.createElementNS(w,P||F),M=I.length;T(this,q),this.currentElement=q,this.locator&&E(this.locator,q);for(var N=0;N<M;N++){var w=I.getURI(N),J=I.getValue(N),P=I.getQName(N),b=K.createAttributeNS(w,P);this.locator&&E(I.getLocator(N),b),b.value=b.nodeValue=J,q.setAttributeNode(b)}},endElement:function(w,F,P){var I=this.currentElement;I.tagName,this.currentElement=I.parentNode},startPrefixMapping:function(w,F){},endPrefixMapping:function(w){},processingInstruction:function(w,F){var P=this.doc.createProcessingInstruction(w,F);this.locator&&E(this.locator,P),T(this,P)},ignorableWhitespace:function(w,F,P){},characters:function(w,F,P){if(w=B.apply(this,arguments),w){if(this.cdata)var I=this.doc.createCDATASection(w);else var I=this.doc.createTextNode(w);this.currentElement?this.currentElement.appendChild(I):/^\s*$/.test(w)&&this.doc.appendChild(I),this.locator&&E(this.locator,I)}},skippedEntity:function(w){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(w){(this.locator=w)&&(w.lineNumber=0)},comment:function(w,F,P){w=B.apply(this,arguments);var I=this.doc.createComment(w);this.locator&&E(this.locator,I),T(this,I)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(w,F,P){var I=this.doc.implementation;if(I&&I.createDocumentType){var K=I.createDocumentType(w,F,P);this.locator&&E(this.locator,K),T(this,K),this.doc.doctype=K}},warning:function(w){console.warn("[xmldom warning] "+w,x(this.locator))},error:function(w){console.error("[xmldom error] "+w,x(this.locator))},fatalError:function(w){throw new l(w,this.locator)}};function x(w){if(w)return`
|
|
27
|
+
@`+(w.systemId||"")+"#[line:"+w.lineNumber+",col:"+w.columnNumber+"]"}function B(w,F,P){return typeof w=="string"?w.substr(F,P):w.length>=F+P||F?new java.lang.String(w,F,P)+"":w}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(w){y.prototype[w]=function(){return null}});function T(w,F){w.currentElement?w.currentElement.appendChild(F):w.doc.appendChild(F)}return qr.__DOMHandler=y,qr.normalizeLineEndings=d,qr.DOMParser=f,qr}var Qc;function n4(){if(Qc)return Ur;Qc=1;var s=Mh();return Ur.DOMImplementation=s.DOMImplementation,Ur.XMLSerializer=s.XMLSerializer,Ur.DOMParser=i4().DOMParser,Ur}var r4=n4();/*! @name mpd-parser @version 1.3.1 @license Apache-2.0 */const Zc=s=>!!s&&typeof s=="object",It=(...s)=>s.reduce((e,i)=>(typeof i!="object"||Object.keys(i).forEach(r=>{Array.isArray(e[r])&&Array.isArray(i[r])?e[r]=e[r].concat(i[r]):Zc(e[r])&&Zc(i[r])?e[r]=It(e[r],i[r]):e[r]=i[r]}),e),{}),Rh=s=>Object.keys(s).map(e=>s[e]),s4=(s,e)=>{const i=[];for(let r=s;r<e;r++)i.push(r);return i},ar=s=>s.reduce((e,i)=>e.concat(i),[]),Vh=s=>{if(!s.length)return[];const e=[];for(let i=0;i<s.length;i++)e.push(s[i]);return e},a4=(s,e)=>s.reduce((i,r,a)=>(r[e]&&i.push(a),i),[]),o4=(s,e)=>Rh(s.reduce((i,r)=>(r.forEach(a=>{i[e(a)]=a}),i),{}));var or={INVALID_NUMBER_OF_PERIOD:"INVALID_NUMBER_OF_PERIOD",DASH_EMPTY_MANIFEST:"DASH_EMPTY_MANIFEST",DASH_INVALID_XML:"DASH_INVALID_XML",NO_BASE_URL:"NO_BASE_URL",SEGMENT_TIME_UNSPECIFIED:"SEGMENT_TIME_UNSPECIFIED",UNSUPPORTED_UTC_TIMING_SCHEME:"UNSUPPORTED_UTC_TIMING_SCHEME"};const is=({baseUrl:s="",source:e="",range:i="",indexRange:r=""})=>{const a={uri:e,resolvedUri:Ea(s||"",e)};if(i||r){const l=(i||r).split("-");let u=W.BigInt?W.BigInt(l[0]):parseInt(l[0],10),d=W.BigInt?W.BigInt(l[1]):parseInt(l[1],10);u<Number.MAX_SAFE_INTEGER&&typeof u=="bigint"&&(u=Number(u)),d<Number.MAX_SAFE_INTEGER&&typeof d=="bigint"&&(d=Number(d));let f;typeof d=="bigint"||typeof u=="bigint"?f=W.BigInt(d)-W.BigInt(u)+W.BigInt(1):f=d-u+1,typeof f=="bigint"&&f<Number.MAX_SAFE_INTEGER&&(f=Number(f)),a.byterange={length:f,offset:u}}return a},l4=s=>{let e;return typeof s.offset=="bigint"||typeof s.length=="bigint"?e=W.BigInt(s.offset)+W.BigInt(s.length)-W.BigInt(1):e=s.offset+s.length-1,`${s.offset}-${e}`},Jc=s=>(s&&typeof s!="number"&&(s=parseInt(s,10)),isNaN(s)?null:s),u4={static(s){const{duration:e,timescale:i=1,sourceDuration:r,periodDuration:a}=s,o=Jc(s.endNumber),l=e/i;return typeof o=="number"?{start:0,end:o}:typeof a=="number"?{start:0,end:a/l}:{start:0,end:r/l}},dynamic(s){const{NOW:e,clientOffset:i,availabilityStartTime:r,timescale:a=1,duration:o,periodStart:l=0,minimumUpdatePeriod:u=0,timeShiftBufferDepth:d=1/0}=s,f=Jc(s.endNumber),g=(e+i)/1e3,y=r+l,x=g+u-y,B=Math.ceil(x*a/o),T=Math.floor((g-y-d)*a/o),w=Math.floor((g-y)*a/o);return{start:Math.max(0,T),end:typeof f=="number"?f:Math.min(B,w)}}},c4=s=>e=>{const{duration:i,timescale:r=1,periodStart:a,startNumber:o=1}=s;return{number:o+e,duration:i/r,timeline:a,time:e*i}},Ol=s=>{const{type:e,duration:i,timescale:r=1,periodDuration:a,sourceDuration:o}=s,{start:l,end:u}=u4[e](s),d=s4(l,u).map(c4(s));if(e==="static"){const f=d.length-1,g=typeof a=="number"?a:o;d[f].duration=g-i/r*f}return d},Fh=s=>{const{baseUrl:e,initialization:i={},sourceDuration:r,indexRange:a="",periodStart:o,presentationTime:l,number:u=0,duration:d}=s;if(!e)throw new Error(or.NO_BASE_URL);const f=is({baseUrl:e,source:i.sourceURL,range:i.range}),g=is({baseUrl:e,source:e,indexRange:a});if(g.map=f,d){const y=Ol(s);y.length&&(g.duration=y[0].duration,g.timeline=y[0].timeline)}else r&&(g.duration=r,g.timeline=o);return g.presentationTime=l||o,g.number=u,[g]},Bl=(s,e,i)=>{const r=s.sidx.map?s.sidx.map:null,a=s.sidx.duration,o=s.timeline||0,l=s.sidx.byterange,u=l.offset+l.length,d=e.timescale,f=e.references.filter(w=>w.referenceType!==1),g=[],y=s.endList?"static":"dynamic",E=s.sidx.timeline;let x=E,B=s.mediaSequence||0,T;typeof e.firstOffset=="bigint"?T=W.BigInt(u)+e.firstOffset:T=u+e.firstOffset;for(let w=0;w<f.length;w++){const F=e.references[w],P=F.referencedSize,I=F.subsegmentDuration;let K;typeof T=="bigint"?K=T+W.BigInt(P)-W.BigInt(1):K=T+P-1;const q=`${T}-${K}`,N=Fh({baseUrl:i,timescale:d,timeline:o,periodStart:E,presentationTime:x,number:B,duration:I,sourceDuration:a,indexRange:q,type:y})[0];r&&(N.map=r),g.push(N),typeof T=="bigint"?T+=W.BigInt(P):T+=P,x+=I/d,B++}return s.segments=g,s},d4=["AUDIO","SUBTITLES"],h4=1/60,$h=s=>o4(s,({timeline:e})=>e).sort((e,i)=>e.timeline>i.timeline?1:-1),f4=(s,e)=>{for(let i=0;i<s.length;i++)if(s[i].attributes.NAME===e)return s[i];return null},ed=s=>{let e=[];return Jb(s,d4,(i,r,a,o)=>{e=e.concat(i.playlists||[])}),e},td=({playlist:s,mediaSequence:e})=>{s.mediaSequence=e,s.segments.forEach((i,r)=>{i.number=s.mediaSequence+r})},p4=({oldPlaylists:s,newPlaylists:e,timelineStarts:i})=>{e.forEach(r=>{r.discontinuitySequence=i.findIndex(function({timeline:d}){return d===r.timeline});const a=f4(s,r.attributes.NAME);if(!a||r.sidx)return;const o=r.segments[0],l=a.segments.findIndex(function(d){return Math.abs(d.presentationTime-o.presentationTime)<h4});if(l===-1){td({playlist:r,mediaSequence:a.mediaSequence+a.segments.length}),r.segments[0].discontinuity=!0,r.discontinuityStarts.unshift(0),(!a.segments.length&&r.timeline>a.timeline||a.segments.length&&r.timeline>a.segments[a.segments.length-1].timeline)&&r.discontinuitySequence--;return}a.segments[l].discontinuity&&!o.discontinuity&&(o.discontinuity=!0,r.discontinuityStarts.unshift(0),r.discontinuitySequence--),td({playlist:r,mediaSequence:a.segments[l].number})})},m4=({oldManifest:s,newManifest:e})=>{const i=s.playlists.concat(ed(s)),r=e.playlists.concat(ed(e));return e.timelineStarts=$h([s.timelineStarts,e.timelineStarts]),p4({oldPlaylists:i,newPlaylists:r,timelineStarts:e.timelineStarts}),e},wa=s=>s&&s.uri+"-"+l4(s.byterange),No=s=>{const e=s.reduce(function(r,a){return r[a.attributes.baseUrl]||(r[a.attributes.baseUrl]=[]),r[a.attributes.baseUrl].push(a),r},{});let i=[];return Object.values(e).forEach(r=>{const a=Rh(r.reduce((o,l)=>{const u=l.attributes.id+(l.attributes.lang||"");return o[u]?(l.segments&&(l.segments[0]&&(l.segments[0].discontinuity=!0),o[u].segments.push(...l.segments)),l.attributes.contentProtection&&(o[u].attributes.contentProtection=l.attributes.contentProtection)):(o[u]=l,o[u].attributes.timelineStarts=[]),o[u].attributes.timelineStarts.push({start:l.attributes.periodStart,timeline:l.attributes.periodStart}),o},{}));i=i.concat(a)}),i.map(r=>(r.discontinuityStarts=a4(r.segments||[],"discontinuity"),r))},Ll=(s,e)=>{const i=wa(s.sidx),r=i&&e[i]&&e[i].sidx;return r&&Bl(s,r,s.sidx.resolvedUri),s},g4=(s,e={})=>{if(!Object.keys(e).length)return s;for(const i in s)s[i]=Ll(s[i],e);return s},_4=({attributes:s,segments:e,sidx:i,mediaSequence:r,discontinuitySequence:a,discontinuityStarts:o},l)=>{const u={attributes:{NAME:s.id,BANDWIDTH:s.bandwidth,CODECS:s.codecs,"PROGRAM-ID":1},uri:"",endList:s.type==="static",timeline:s.periodStart,resolvedUri:s.baseUrl||"",targetDuration:s.duration,discontinuitySequence:a,discontinuityStarts:o,timelineStarts:s.timelineStarts,mediaSequence:r,segments:e};return s.contentProtection&&(u.contentProtection=s.contentProtection),s.serviceLocation&&(u.attributes.serviceLocation=s.serviceLocation),i&&(u.sidx=i),l&&(u.attributes.AUDIO="audio",u.attributes.SUBTITLES="subs"),u},y4=({attributes:s,segments:e,mediaSequence:i,discontinuityStarts:r,discontinuitySequence:a})=>{typeof e>"u"&&(e=[{uri:s.baseUrl,timeline:s.periodStart,resolvedUri:s.baseUrl||"",duration:s.sourceDuration,number:0}],s.duration=s.sourceDuration);const o={NAME:s.id,BANDWIDTH:s.bandwidth,"PROGRAM-ID":1};s.codecs&&(o.CODECS=s.codecs);const l={attributes:o,uri:"",endList:s.type==="static",timeline:s.periodStart,resolvedUri:s.baseUrl||"",targetDuration:s.duration,timelineStarts:s.timelineStarts,discontinuityStarts:r,discontinuitySequence:a,mediaSequence:i,segments:e};return s.serviceLocation&&(l.attributes.serviceLocation=s.serviceLocation),l},v4=(s,e={},i=!1)=>{let r;const a=s.reduce((o,l)=>{const u=l.attributes.role&&l.attributes.role.value||"",d=l.attributes.lang||"";let f=l.attributes.label||"main";if(d&&!l.attributes.label){const y=u?` (${u})`:"";f=`${l.attributes.lang}${y}`}o[f]||(o[f]={language:d,autoselect:!0,default:u==="main",playlists:[],uri:""});const g=Ll(_4(l,i),e);return o[f].playlists.push(g),typeof r>"u"&&u==="main"&&(r=l,r.default=!0),o},{});if(!r){const o=Object.keys(a)[0];a[o].default=!0}return a},T4=(s,e={})=>s.reduce((i,r)=>{const a=r.attributes.label||r.attributes.lang||"text",o=r.attributes.lang||"und";return i[a]||(i[a]={language:o,default:!1,autoselect:!1,playlists:[],uri:""}),i[a].playlists.push(Ll(y4(r),e)),i},{}),b4=s=>s.reduce((e,i)=>(i&&i.forEach(r=>{const{channel:a,language:o}=r;e[o]={autoselect:!1,default:!1,instreamId:a,language:o},r.hasOwnProperty("aspectRatio")&&(e[o].aspectRatio=r.aspectRatio),r.hasOwnProperty("easyReader")&&(e[o].easyReader=r.easyReader),r.hasOwnProperty("3D")&&(e[o]["3D"]=r["3D"])}),e),{}),x4=({attributes:s,segments:e,sidx:i,discontinuityStarts:r})=>{const a={attributes:{NAME:s.id,AUDIO:"audio",SUBTITLES:"subs",RESOLUTION:{width:s.width,height:s.height},CODECS:s.codecs,BANDWIDTH:s.bandwidth,"PROGRAM-ID":1},uri:"",endList:s.type==="static",timeline:s.periodStart,resolvedUri:s.baseUrl||"",targetDuration:s.duration,discontinuityStarts:r,timelineStarts:s.timelineStarts,segments:e};return s.frameRate&&(a.attributes["FRAME-RATE"]=s.frameRate),s.contentProtection&&(a.contentProtection=s.contentProtection),s.serviceLocation&&(a.attributes.serviceLocation=s.serviceLocation),i&&(a.sidx=i),a},C4=({attributes:s})=>s.mimeType==="video/mp4"||s.mimeType==="video/webm"||s.contentType==="video",S4=({attributes:s})=>s.mimeType==="audio/mp4"||s.mimeType==="audio/webm"||s.contentType==="audio",E4=({attributes:s})=>s.mimeType==="text/vtt"||s.contentType==="text",k4=(s,e)=>{s.forEach(i=>{i.mediaSequence=0,i.discontinuitySequence=e.findIndex(function({timeline:r}){return r===i.timeline}),i.segments&&i.segments.forEach((r,a)=>{r.number=a})})},id=s=>s?Object.keys(s).reduce((e,i)=>{const r=s[i];return e.concat(r.playlists)},[]):[],w4=({dashPlaylists:s,locations:e,contentSteering:i,sidxMapping:r={},previousManifest:a,eventStream:o})=>{if(!s.length)return{};const{sourceDuration:l,type:u,suggestedPresentationDelay:d,minimumUpdatePeriod:f}=s[0].attributes,g=No(s.filter(C4)).map(x4),y=No(s.filter(S4)),E=No(s.filter(E4)),x=s.map(K=>K.attributes.captionServices).filter(Boolean),B={allowCache:!0,discontinuityStarts:[],segments:[],endList:!0,mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:"",duration:l,playlists:g4(g,r)};f>=0&&(B.minimumUpdatePeriod=f*1e3),e&&(B.locations=e),i&&(B.contentSteering=i),u==="dynamic"&&(B.suggestedPresentationDelay=d),o&&o.length>0&&(B.eventStream=o);const T=B.playlists.length===0,w=y.length?v4(y,r,T):null,F=E.length?T4(E,r):null,P=g.concat(id(w),id(F)),I=P.map(({timelineStarts:K})=>K);return B.timelineStarts=$h(I),k4(P,B.timelineStarts),w&&(B.mediaGroups.AUDIO.audio=w),F&&(B.mediaGroups.SUBTITLES.subs=F),x.length&&(B.mediaGroups["CLOSED-CAPTIONS"].cc=b4(x)),a?m4({oldManifest:a,newManifest:B}):B},D4=(s,e,i)=>{const{NOW:r,clientOffset:a,availabilityStartTime:o,timescale:l=1,periodStart:u=0,minimumUpdatePeriod:d=0}=s,f=(r+a)/1e3,g=o+u,E=f+d-g;return Math.ceil((E*l-e)/i)},Uh=(s,e)=>{const{type:i,minimumUpdatePeriod:r=0,media:a="",sourceDuration:o,timescale:l=1,startNumber:u=1,periodStart:d}=s,f=[];let g=-1;for(let y=0;y<e.length;y++){const E=e[y],x=E.d,B=E.r||0,T=E.t||0;g<0&&(g=T),T&&T>g&&(g=T);let w;if(B<0){const I=y+1;I===e.length?i==="dynamic"&&r>0&&a.indexOf("$Number$")>0?w=D4(s,g,x):w=(o*l-g)/x:w=(e[I].t-g)/x}else w=B+1;const F=u+f.length+w;let P=u+f.length;for(;P<F;)f.push({number:P,duration:x/l,time:g,timeline:d}),g+=x,P++}return f},A4=/\$([A-z]*)(?:(%0)([0-9]+)d)?\$/g,I4=s=>(e,i,r,a)=>{if(e==="$$")return"$";if(typeof s[i]>"u")return e;const o=""+s[i];return i==="RepresentationID"||(r?a=parseInt(a,10):a=1,o.length>=a)?o:`${new Array(a-o.length+1).join("0")}${o}`},nd=(s,e)=>s.replace(A4,I4(e)),N4=(s,e)=>!s.duration&&!e?[{number:s.startNumber||1,duration:s.sourceDuration,time:0,timeline:s.periodStart}]:s.duration?Ol(s):Uh(s,e),O4=(s,e)=>{const i={RepresentationID:s.id,Bandwidth:s.bandwidth||0},{initialization:r={sourceURL:"",range:""}}=s,a=is({baseUrl:s.baseUrl,source:nd(r.sourceURL,i),range:r.range});return N4(s,e).map(l=>{i.Number=l.number,i.Time=l.time;const u=nd(s.media||"",i),d=s.timescale||1,f=s.presentationTimeOffset||0,g=s.periodStart+(l.time-f)/d;return{uri:u,timeline:l.timeline,duration:l.duration,resolvedUri:Ea(s.baseUrl||"",u),map:a,number:l.number,presentationTime:g}})},B4=(s,e)=>{const{baseUrl:i,initialization:r={}}=s,a=is({baseUrl:i,source:r.sourceURL,range:r.range}),o=is({baseUrl:i,source:e.media,range:e.mediaRange});return o.map=a,o},L4=(s,e)=>{const{duration:i,segmentUrls:r=[],periodStart:a}=s;if(!i&&!e||i&&e)throw new Error(or.SEGMENT_TIME_UNSPECIFIED);const o=r.map(d=>B4(s,d));let l;return i&&(l=Ol(s)),e&&(l=Uh(s,e)),l.map((d,f)=>{if(o[f]){const g=o[f],y=s.timescale||1,E=s.presentationTimeOffset||0;return g.timeline=d.timeline,g.duration=d.duration,g.number=d.number,g.presentationTime=a+(d.time-E)/y,g}}).filter(d=>d)},P4=({attributes:s,segmentInfo:e})=>{let i,r;e.template?(r=O4,i=It(s,e.template)):e.base?(r=Fh,i=It(s,e.base)):e.list&&(r=L4,i=It(s,e.list));const a={attributes:s};if(!r)return a;const o=r(i,e.segmentTimeline);if(i.duration){const{duration:l,timescale:u=1}=i;i.duration=l/u}else o.length?i.duration=o.reduce((l,u)=>Math.max(l,Math.ceil(u.duration)),0):i.duration=0;return a.attributes=i,a.segments=o,e.base&&i.indexRange&&(a.sidx=o[0],a.segments=[]),a},M4=s=>s.map(P4),dt=(s,e)=>Vh(s.childNodes).filter(({tagName:i})=>i===e),os=s=>s.textContent.trim(),R4=s=>parseFloat(s.split("/").reduce((e,i)=>e/i)),jn=s=>{const u=/P(?:(\d*)Y)?(?:(\d*)M)?(?:(\d*)D)?(?:T(?:(\d*)H)?(?:(\d*)M)?(?:([\d.]*)S)?)?/.exec(s);if(!u)return 0;const[d,f,g,y,E,x]=u.slice(1);return parseFloat(d||0)*31536e3+parseFloat(f||0)*2592e3+parseFloat(g||0)*86400+parseFloat(y||0)*3600+parseFloat(E||0)*60+parseFloat(x||0)},V4=s=>(/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(s)&&(s+="Z"),Date.parse(s)),rd={mediaPresentationDuration(s){return jn(s)},availabilityStartTime(s){return V4(s)/1e3},minimumUpdatePeriod(s){return jn(s)},suggestedPresentationDelay(s){return jn(s)},type(s){return s},timeShiftBufferDepth(s){return jn(s)},start(s){return jn(s)},width(s){return parseInt(s,10)},height(s){return parseInt(s,10)},bandwidth(s){return parseInt(s,10)},frameRate(s){return R4(s)},startNumber(s){return parseInt(s,10)},timescale(s){return parseInt(s,10)},presentationTimeOffset(s){return parseInt(s,10)},duration(s){const e=parseInt(s,10);return isNaN(e)?jn(s):e},d(s){return parseInt(s,10)},t(s){return parseInt(s,10)},r(s){return parseInt(s,10)},presentationTime(s){return parseInt(s,10)},DEFAULT(s){return s}},xt=s=>s&&s.attributes?Vh(s.attributes).reduce((e,i)=>{const r=rd[i.name]||rd.DEFAULT;return e[i.name]=r(i.value),e},{}):{},F4={"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb":"com.adobe.primetime","urn:mpeg:dash:mp4protection:2011":"mp4protection"},Da=(s,e)=>e.length?ar(s.map(function(i){return e.map(function(r){const a=os(r),o=Ea(i.baseUrl,a),l=It(xt(r),{baseUrl:o});return o!==a&&!l.serviceLocation&&i.serviceLocation&&(l.serviceLocation=i.serviceLocation),l})})):s,Pl=s=>{const e=dt(s,"SegmentTemplate")[0],i=dt(s,"SegmentList")[0],r=i&&dt(i,"SegmentURL").map(y=>It({tag:"SegmentURL"},xt(y))),a=dt(s,"SegmentBase")[0],o=i||e,l=o&&dt(o,"SegmentTimeline")[0],u=i||a||e,d=u&&dt(u,"Initialization")[0],f=e&&xt(e);f&&d?f.initialization=d&&xt(d):f&&f.initialization&&(f.initialization={sourceURL:f.initialization});const g={template:f,segmentTimeline:l&&dt(l,"S").map(y=>xt(y)),list:i&&It(xt(i),{segmentUrls:r,initialization:xt(d)}),base:a&&It(xt(a),{initialization:xt(d)})};return Object.keys(g).forEach(y=>{g[y]||delete g[y]}),g},$4=(s,e,i)=>r=>{const a=dt(r,"BaseURL"),o=Da(e,a),l=It(s,xt(r)),u=Pl(r);return o.map(d=>({segmentInfo:It(i,u),attributes:It(l,d)}))},U4=s=>s.reduce((e,i)=>{const r=xt(i);r.schemeIdUri&&(r.schemeIdUri=r.schemeIdUri.toLowerCase());const a=F4[r.schemeIdUri];if(a){e[a]={attributes:r};const o=dt(i,"cenc:pssh")[0];if(o){const l=os(o);e[a].pssh=l&&Ih(l)}}return e},{}),q4=s=>{if(s.schemeIdUri==="urn:scte:dash:cc:cea-608:2015")return(typeof s.value!="string"?[]:s.value.split(";")).map(i=>{let r,a;return a=i,/^CC\d=/.test(i)?[r,a]=i.split("="):/^CC\d$/.test(i)&&(r=i),{channel:r,language:a}});if(s.schemeIdUri==="urn:scte:dash:cc:cea-708:2015")return(typeof s.value!="string"?[]:s.value.split(";")).map(i=>{const r={channel:void 0,language:void 0,aspectRatio:1,easyReader:0,"3D":0};if(/=/.test(i)){const[a,o=""]=i.split("=");r.channel=a,r.language=i,o.split(",").forEach(l=>{const[u,d]=l.split(":");u==="lang"?r.language=d:u==="er"?r.easyReader=Number(d):u==="war"?r.aspectRatio=Number(d):u==="3D"&&(r["3D"]=Number(d))})}else r.language=i;return r.channel&&(r.channel="SERVICE"+r.channel),r})},j4=s=>ar(dt(s.node,"EventStream").map(e=>{const i=xt(e),r=i.schemeIdUri;return dt(e,"Event").map(a=>{const o=xt(a),l=o.presentationTime||0,u=i.timescale||1,d=o.duration||0,f=l/u+s.attributes.start;return{schemeIdUri:r,value:i.value,id:o.id,start:f,end:f+d/u,messageData:os(a)||o.messageData,contentEncoding:i.contentEncoding,presentationTimeOffset:i.presentationTimeOffset||0}})})),H4=(s,e,i)=>r=>{const a=xt(r),o=Da(e,dt(r,"BaseURL")),l=dt(r,"Role")[0],u={role:xt(l)};let d=It(s,a,u);const f=dt(r,"Accessibility")[0],g=q4(xt(f));g&&(d=It(d,{captionServices:g}));const y=dt(r,"Label")[0];if(y&&y.childNodes.length){const w=y.childNodes[0].nodeValue.trim();d=It(d,{label:w})}const E=U4(dt(r,"ContentProtection"));Object.keys(E).length&&(d=It(d,{contentProtection:E}));const x=Pl(r),B=dt(r,"Representation"),T=It(i,x);return ar(B.map($4(d,o,T)))},z4=(s,e)=>(i,r)=>{const a=Da(e,dt(i.node,"BaseURL")),o=It(s,{periodStart:i.attributes.start});typeof i.attributes.duration=="number"&&(o.periodDuration=i.attributes.duration);const l=dt(i.node,"AdaptationSet"),u=Pl(i.node);return ar(l.map(H4(o,a,u)))},G4=(s,e)=>{if(s.length>1&&e({type:"warn",message:"The MPD manifest should contain no more than one ContentSteering tag"}),!s.length)return null;const i=It({serverURL:os(s[0])},xt(s[0]));return i.queryBeforeStart=i.queryBeforeStart==="true",i},W4=({attributes:s,priorPeriodAttributes:e,mpdType:i})=>typeof s.start=="number"?s.start:e&&typeof e.start=="number"&&typeof e.duration=="number"?e.start+e.duration:!e&&i==="static"?0:null,Y4=(s,e={})=>{const{manifestUri:i="",NOW:r=Date.now(),clientOffset:a=0,eventHandler:o=function(){}}=e,l=dt(s,"Period");if(!l.length)throw new Error(or.INVALID_NUMBER_OF_PERIOD);const u=dt(s,"Location"),d=xt(s),f=Da([{baseUrl:i}],dt(s,"BaseURL")),g=dt(s,"ContentSteering");d.type=d.type||"static",d.sourceDuration=d.mediaPresentationDuration||0,d.NOW=r,d.clientOffset=a,u.length&&(d.locations=u.map(os));const y=[];return l.forEach((E,x)=>{const B=xt(E),T=y[x-1];B.start=W4({attributes:B,priorPeriodAttributes:T?T.attributes:null,mpdType:d.type}),y.push({node:E,attributes:B})}),{locations:d.locations,contentSteeringInfo:G4(g,o),representationInfo:ar(y.map(z4(d,f))),eventStream:ar(y.map(j4))}},qh=s=>{if(s==="")throw new Error(or.DASH_EMPTY_MANIFEST);const e=new r4.DOMParser;let i,r;try{i=e.parseFromString(s,"application/xml"),r=i&&i.documentElement.tagName==="MPD"?i.documentElement:null}catch{}if(!r||r&&r.getElementsByTagName("parsererror").length>0)throw new Error(or.DASH_INVALID_XML);return r},X4=s=>{const e=dt(s,"UTCTiming")[0];if(!e)return null;const i=xt(e);switch(i.schemeIdUri){case"urn:mpeg:dash:utc:http-head:2014":case"urn:mpeg:dash:utc:http-head:2012":i.method="HEAD";break;case"urn:mpeg:dash:utc:http-xsdate:2014":case"urn:mpeg:dash:utc:http-iso:2014":case"urn:mpeg:dash:utc:http-xsdate:2012":case"urn:mpeg:dash:utc:http-iso:2012":i.method="GET";break;case"urn:mpeg:dash:utc:direct:2014":case"urn:mpeg:dash:utc:direct:2012":i.method="DIRECT",i.value=Date.parse(i.value);break;case"urn:mpeg:dash:utc:http-ntp:2014":case"urn:mpeg:dash:utc:ntp:2014":case"urn:mpeg:dash:utc:sntp:2014":default:throw new Error(or.UNSUPPORTED_UTC_TIMING_SCHEME)}return i},K4=(s,e={})=>{const i=Y4(qh(s),e),r=M4(i.representationInfo);return w4({dashPlaylists:r,locations:i.locations,contentSteering:i.contentSteeringInfo,sidxMapping:e.sidxMapping,previousManifest:e.previousManifest,eventStream:i.eventStream})},Q4=s=>X4(qh(s));var Oo,sd;function Z4(){if(sd)return Oo;sd=1;var s=Math.pow(2,32),e=function(i){var r=new DataView(i.buffer,i.byteOffset,i.byteLength),a;return r.getBigUint64?(a=r.getBigUint64(0),a<Number.MAX_SAFE_INTEGER?Number(a):a):r.getUint32(0)*s+r.getUint32(4)};return Oo={getUint64:e,MAX_UINT32:s},Oo}var Bo,ad;function J4(){if(ad)return Bo;ad=1;var s=Z4().getUint64,e=function(i){var r=new DataView(i.buffer,i.byteOffset,i.byteLength),a={version:i[0],flags:new Uint8Array(i.subarray(1,4)),references:[],referenceId:r.getUint32(4),timescale:r.getUint32(8)},o=12;a.version===0?(a.earliestPresentationTime=r.getUint32(o),a.firstOffset=r.getUint32(o+4),o+=8):(a.earliestPresentationTime=s(i.subarray(o)),a.firstOffset=s(i.subarray(o+8)),o+=16),o+=2;var l=r.getUint16(o);for(o+=2;l>0;o+=12,l--)a.references.push({referenceType:(i[o]&128)>>>7,referencedSize:r.getUint32(o)&2147483647,subsegmentDuration:r.getUint32(o+4),startsWithSap:!!(i[o+8]&128),sapType:(i[o+8]&112)>>>4,sapDeltaTime:r.getUint32(o+8)&268435455});return a};return Bo=e,Bo}var e8=J4();const t8=pr(e8);var i8=Ne([73,68,51]),n8=function(e,i){i===void 0&&(i=0),e=Ne(e);var r=e[i+5],a=e[i+6]<<21|e[i+7]<<14|e[i+8]<<7|e[i+9],o=(r&16)>>4;return o?a+20:a+10},Gr=function s(e,i){return i===void 0&&(i=0),e=Ne(e),e.length-i<10||!ct(e,i8,{offset:i})?i:(i+=n8(e,i),s(e,i))},od=function(e){return typeof e=="string"?Ph(e):e},r8=function(e){return Array.isArray(e)?e.map(function(i){return od(i)}):[od(e)]},s8=function s(e,i,r){r===void 0&&(r=!1),i=r8(i),e=Ne(e);var a=[];if(!i.length)return a;for(var o=0;o<e.length;){var l=(e[o]<<24|e[o+1]<<16|e[o+2]<<8|e[o+3])>>>0,u=e.subarray(o+4,o+8);if(l===0)break;var d=o+l;if(d>e.length){if(r)break;d=e.length}var f=e.subarray(o+8,d);ct(u,i[0])&&(i.length===1?a.push(f):a.push.apply(a,s(f,i.slice(1),r))),o=d}return a},Us={EBML:Ne([26,69,223,163]),DocType:Ne([66,130]),Segment:Ne([24,83,128,103]),SegmentInfo:Ne([21,73,169,102]),Tracks:Ne([22,84,174,107]),Track:Ne([174]),TrackNumber:Ne([215]),DefaultDuration:Ne([35,227,131]),TrackEntry:Ne([174]),TrackType:Ne([131]),FlagDefault:Ne([136]),CodecID:Ne([134]),CodecPrivate:Ne([99,162]),VideoTrack:Ne([224]),AudioTrack:Ne([225]),Cluster:Ne([31,67,182,117]),Timestamp:Ne([231]),TimestampScale:Ne([42,215,177]),BlockGroup:Ne([160]),BlockDuration:Ne([155]),Block:Ne([161]),SimpleBlock:Ne([163])},tl=[128,64,32,16,8,4,2,1],a8=function(e){for(var i=1,r=0;r<tl.length&&!(e&tl[r]);r++)i++;return i},ra=function(e,i,r,a){r===void 0&&(r=!0),a===void 0&&(a=!1);var o=a8(e[i]),l=e.subarray(i,i+o);return r&&(l=Array.prototype.slice.call(e,i,i+o),l[0]^=tl[o-1]),{length:o,value:Kb(l,{signed:a}),bytes:l}},ld=function s(e){return typeof e=="string"?e.match(/.{1,2}/g).map(function(i){return s(i)}):typeof e=="number"?Qb(e):e},o8=function(e){return Array.isArray(e)?e.map(function(i){return ld(i)}):[ld(e)]},l8=function s(e,i,r){if(r>=i.length)return i.length;var a=ra(i,r,!1);if(ct(e.bytes,a.bytes))return r;var o=ra(i,r+a.length);return s(e,i,r+o.length+o.value+a.length)},ud=function s(e,i){i=o8(i),e=Ne(e);var r=[];if(!i.length)return r;for(var a=0;a<e.length;){var o=ra(e,a,!1),l=ra(e,a+o.length),u=a+o.length+l.length;l.value===127&&(l.value=l8(o,e,u),l.value!==e.length&&(l.value-=u));var d=u+l.value>e.length?e.length:u+l.value,f=e.subarray(u,d);ct(i[0],o.bytes)&&(i.length===1?r.push(f):r=r.concat(s(f,i.slice(1))));var g=o.length+l.length+f.length;a+=g}return r},u8=Ne([0,0,0,1]),c8=Ne([0,0,1]),d8=Ne([0,0,3]),h8=function(e){for(var i=[],r=1;r<e.length-2;)ct(e.subarray(r,r+3),d8)&&(i.push(r+2),r++),r++;if(i.length===0)return e;var a=e.length-i.length,o=new Uint8Array(a),l=0;for(r=0;r<a;l++,r++)l===i[0]&&(l++,i.shift()),o[r]=e[l];return o},jh=function(e,i,r,a){e=Ne(e),r=[].concat(r);for(var o=0,l,u=0;o<e.length&&(u<a||l);){var d=void 0;if(ct(e.subarray(o),u8)?d=4:ct(e.subarray(o),c8)&&(d=3),!d){o++;continue}if(u++,l)return h8(e.subarray(l,o));var f=void 0;i==="h264"?f=e[o+d]&31:i==="h265"&&(f=e[o+d]>>1&63),r.indexOf(f)!==-1&&(l=o+d),o+=d+(i==="h264"?1:2)}return e.subarray(0,0)},f8=function(e,i,r){return jh(e,"h264",i,r)},p8=function(e,i,r){return jh(e,"h265",i,r)},Kt={webm:Ne([119,101,98,109]),matroska:Ne([109,97,116,114,111,115,107,97]),flac:Ne([102,76,97,67]),ogg:Ne([79,103,103,83]),ac3:Ne([11,119]),riff:Ne([82,73,70,70]),avi:Ne([65,86,73]),wav:Ne([87,65,86,69]),"3gp":Ne([102,116,121,112,51,103]),mp4:Ne([102,116,121,112]),fmp4:Ne([115,116,121,112]),mov:Ne([102,116,121,112,113,116]),moov:Ne([109,111,111,118]),moof:Ne([109,111,111,102])},lr={aac:function(e){var i=Gr(e);return ct(e,[255,16],{offset:i,mask:[255,22]})},mp3:function(e){var i=Gr(e);return ct(e,[255,2],{offset:i,mask:[255,6]})},webm:function(e){var i=ud(e,[Us.EBML,Us.DocType])[0];return ct(i,Kt.webm)},mkv:function(e){var i=ud(e,[Us.EBML,Us.DocType])[0];return ct(i,Kt.matroska)},mp4:function(e){if(lr["3gp"](e)||lr.mov(e))return!1;if(ct(e,Kt.mp4,{offset:4})||ct(e,Kt.fmp4,{offset:4})||ct(e,Kt.moof,{offset:4})||ct(e,Kt.moov,{offset:4}))return!0},mov:function(e){return ct(e,Kt.mov,{offset:4})},"3gp":function(e){return ct(e,Kt["3gp"],{offset:4})},ac3:function(e){var i=Gr(e);return ct(e,Kt.ac3,{offset:i})},ts:function(e){if(e.length<189&&e.length>=1)return e[0]===71;for(var i=0;i+188<e.length&&i<188;){if(e[i]===71&&e[i+188]===71)return!0;i+=1}return!1},flac:function(e){var i=Gr(e);return ct(e,Kt.flac,{offset:i})},ogg:function(e){return ct(e,Kt.ogg)},avi:function(e){return ct(e,Kt.riff)&&ct(e,Kt.avi,{offset:8})},wav:function(e){return ct(e,Kt.riff)&&ct(e,Kt.wav,{offset:8})},h264:function(e){return f8(e,7,3).length},h265:function(e){return p8(e,[32,33],3).length}},il=Object.keys(lr).filter(function(s){return s!=="ts"&&s!=="h264"&&s!=="h265"}).concat(["ts","h264","h265"]);il.forEach(function(s){var e=lr[s];lr[s]=function(i){return e(Ne(i))}});var m8=lr,Ml=function(e){e=Ne(e);for(var i=0;i<il.length;i++){var r=il[i];if(m8[r](e))return r}return""},g8=function(e){return s8(e,["moof"]).length>0},Lo,cd;function _8(){if(cd)return Lo;cd=1;var s=9e4,e,i,r,a,o,l,u;return e=function(d){return d*s},i=function(d,f){return d*f},r=function(d){return d/s},a=function(d,f){return d/f},o=function(d,f){return e(a(d,f))},l=function(d,f){return i(r(d),f)},u=function(d,f,g){return r(g?d:d-f)},Lo={ONE_SECOND_IN_TS:s,secondsToVideoTs:e,secondsToAudioTs:i,videoTsToSeconds:r,audioTsToSeconds:a,audioTsToVideoTs:o,videoTsToAudioTs:l,metadataTsToSeconds:u},Lo}var Dn=_8();/**
|
|
28
|
+
* @license
|
|
29
|
+
* Video.js 8.23.7 <http://videojs.com/>
|
|
30
|
+
* Copyright 2010-present Video.js contributors
|
|
31
|
+
* Available under Apache License Version 2.0
|
|
32
|
+
* <https://github.com/videojs/video.js/blob/main/LICENSE>
|
|
33
|
+
*
|
|
34
|
+
* Includes vtt.js <https://github.com/mozilla/vtt.js>
|
|
35
|
+
* Available under Apache License Version 2.0
|
|
36
|
+
* <https://github.com/mozilla/vtt.js/blob/main/LICENSE>
|
|
37
|
+
*/var nl="8.23.7";const en={},_n=function(s,e){return en[s]=en[s]||[],e&&(en[s]=en[s].concat(e)),en[s]},y8=function(s,e){_n(s,e)},Hh=function(s,e){const i=_n(s).indexOf(e);return i<=-1?!1:(en[s]=en[s].slice(),en[s].splice(i,1),!0)},v8=function(s,e){_n(s,[].concat(e).map(i=>{const r=(...a)=>(Hh(s,r),i(...a));return r}))},sa={prefixed:!0},Zs=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror","fullscreen"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror","-webkit-full-screen"]],dd=Zs[0];let Wr;for(let s=0;s<Zs.length;s++)if(Zs[s][1]in pe){Wr=Zs[s];break}if(Wr){for(let s=0;s<Wr.length;s++)sa[dd[s]]=Wr[s];sa.prefixed=Wr[0]!==dd[0]}let ni=[];const T8=(s,e,i)=>(r,a,o)=>{const l=e.levels[a],u=new RegExp(`^(${l})$`);let d=s;if(r!=="log"&&o.unshift(r.toUpperCase()+":"),i&&(d=`%c${s}`,o.unshift(i)),o.unshift(d+":"),ni){ni.push([].concat(o));const g=ni.length-1e3;ni.splice(0,g>0?g:0)}if(!W.console)return;let f=W.console[r];!f&&r==="debug"&&(f=W.console.info||W.console.log),!(!f||!l||!u.test(r))&&f[Array.isArray(o)?"apply":"call"](W.console,o)};function rl(s,e=":",i=""){let r="info",a;function o(...l){a("log",r,l)}return a=T8(s,o,i),o.createLogger=(l,u,d)=>{const f=u!==void 0?u:e,g=d!==void 0?d:i,y=`${s} ${f} ${l}`;return rl(y,f,g)},o.createNewLogger=(l,u,d)=>rl(l,u,d),o.levels={all:"debug|log|warn|error",off:"",debug:"debug|log|warn|error",info:"log|warn|error",warn:"warn|error",error:"error",DEFAULT:r},o.level=l=>{if(typeof l=="string"){if(!o.levels.hasOwnProperty(l))throw new Error(`"${l}" in not a valid log level`);r=l}return r},o.history=()=>ni?[].concat(ni):[],o.history.filter=l=>(ni||[]).filter(u=>new RegExp(`.*${l}.*`).test(u[0])),o.history.clear=()=>{ni&&(ni.length=0)},o.history.disable=()=>{ni!==null&&(ni.length=0,ni=null)},o.history.enable=()=>{ni===null&&(ni=[])},o.error=(...l)=>a("error",r,l),o.warn=(...l)=>a("warn",r,l),o.debug=(...l)=>a("debug",r,l),o}const Ge=rl("VIDEOJS"),zh=Ge.createLogger,b8=Object.prototype.toString,Gh=function(s){return zi(s)?Object.keys(s):[]};function Kn(s,e){Gh(s).forEach(i=>e(s[i],i))}function Wh(s,e,i=0){return Gh(s).reduce((r,a)=>e(r,s[a],a),i)}function zi(s){return!!s&&typeof s=="object"}function ur(s){return zi(s)&&b8.call(s)==="[object Object]"&&s.constructor===Object}function rt(...s){const e={};return s.forEach(i=>{i&&Kn(i,(r,a)=>{if(!ur(r)){e[a]=r;return}ur(e[a])||(e[a]={}),e[a]=rt(e[a],r)})}),e}function Yh(s={}){const e=[];for(const i in s)if(s.hasOwnProperty(i)){const r=s[i];e.push(r)}return e}function Aa(s,e,i,r=!0){const a=l=>Object.defineProperty(s,e,{value:l,enumerable:!0,writable:!0}),o={configurable:!0,enumerable:!0,get(){const l=i();return a(l),l}};return r&&(o.set=a),Object.defineProperty(s,e,o)}var x8=Object.freeze({__proto__:null,each:Kn,reduce:Wh,isObject:zi,isPlain:ur,merge:rt,values:Yh,defineLazyProperty:Aa});let Rl=!1,Xh=null,Bi=!1,Kh,Qh=!1,Qn=!1,Zn=!1,Gi=!1,Vl=null,Ia=null;const C8=!!(W.cast&&W.cast.framework&&W.cast.framework.CastReceiverContext);let Zh=null,aa=!1,Na=!1,oa=!1,Oa=!1,la=!1,ua=!1,ca=!1;const ns=!!(mr()&&("ontouchstart"in W||W.navigator.maxTouchPoints||W.DocumentTouch&&W.document instanceof W.DocumentTouch)),cn=W.navigator&&W.navigator.userAgentData;cn&&cn.platform&&cn.brands&&(Bi=cn.platform==="Android",Qn=!!cn.brands.find(s=>s.brand==="Microsoft Edge"),Zn=!!cn.brands.find(s=>s.brand==="Chromium"),Gi=!Qn&&Zn,Vl=Ia=(cn.brands.find(s=>s.brand==="Chromium")||{}).version||null,Na=cn.platform==="Windows");if(!Zn){const s=W.navigator&&W.navigator.userAgent||"";Rl=/iPod/i.test(s),Xh=(function(){const e=s.match(/OS (\d+)_/i);return e&&e[1]?e[1]:null})(),Bi=/Android/i.test(s),Kh=(function(){const e=s.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!e)return null;const i=e[1]&&parseFloat(e[1]),r=e[2]&&parseFloat(e[2]);return i&&r?parseFloat(e[1]+"."+e[2]):i||null})(),Qh=/Firefox/i.test(s),Qn=/Edg/i.test(s),Zn=/Chrome/i.test(s)||/CriOS/i.test(s),Gi=!Qn&&Zn,Vl=Ia=(function(){const e=s.match(/(Chrome|CriOS)\/(\d+)/);return e&&e[2]?parseFloat(e[2]):null})(),Zh=(function(){const e=/MSIE\s(\d+)\.\d/.exec(s);let i=e&&parseFloat(e[1]);return!i&&/Trident\/7.0/i.test(s)&&/rv:11.0/.test(s)&&(i=11),i})(),la=/Tizen/i.test(s),ua=/Web0S/i.test(s),ca=la||ua,aa=/Safari/i.test(s)&&!Gi&&!Bi&&!Qn&&!ca,Na=/Windows/i.test(s),oa=/iPad/i.test(s)||aa&&ns&&!/iPhone/i.test(s),Oa=/iPhone/i.test(s)&&!oa}const $t=Oa||oa||Rl,Ba=(aa||$t)&&!Gi;var Jh=Object.freeze({__proto__:null,get IS_IPOD(){return Rl},get IOS_VERSION(){return Xh},get IS_ANDROID(){return Bi},get ANDROID_VERSION(){return Kh},get IS_FIREFOX(){return Qh},get IS_EDGE(){return Qn},get IS_CHROMIUM(){return Zn},get IS_CHROME(){return Gi},get CHROMIUM_VERSION(){return Vl},get CHROME_VERSION(){return Ia},IS_CHROMECAST_RECEIVER:C8,get IE_VERSION(){return Zh},get IS_SAFARI(){return aa},get IS_WINDOWS(){return Na},get IS_IPAD(){return oa},get IS_IPHONE(){return Oa},get IS_TIZEN(){return la},get IS_WEBOS(){return ua},get IS_SMART_TV(){return ca},TOUCH_ENABLED:ns,IS_IOS:$t,IS_ANY_SAFARI:Ba});function hd(s){return typeof s=="string"&&!!s.trim()}function S8(s){if(s.indexOf(" ")>=0)throw new Error("class has illegal whitespace characters")}function mr(){return pe===W.document}function gr(s){return zi(s)&&s.nodeType===1}function e0(){try{return W.parent!==W.self}catch{return!0}}function t0(s){return function(e,i){if(!hd(e))return pe[s](null);hd(i)&&(i=pe.querySelector(i));const r=gr(i)?i:pe;return r[s]&&r[s](e)}}function Be(s="div",e={},i={},r){const a=pe.createElement(s);return Object.getOwnPropertyNames(e).forEach(function(o){const l=e[o];o==="textContent"?vn(a,l):(a[o]!==l||o==="tabIndex")&&(a[o]=l)}),Object.getOwnPropertyNames(i).forEach(function(o){a.setAttribute(o,i[o])}),r&&Fl(a,r),a}function vn(s,e){return typeof s.textContent>"u"?s.innerText=e:s.textContent=e,s}function sl(s,e){e.firstChild?e.insertBefore(s,e.firstChild):e.appendChild(s)}function Qr(s,e){return S8(e),s.classList.contains(e)}function On(s,...e){return s.classList.add(...e.reduce((i,r)=>i.concat(r.split(/\s+/)),[])),s}function La(s,...e){return s?(s.classList.remove(...e.reduce((i,r)=>i.concat(r.split(/\s+/)),[])),s):(Ge.warn("removeClass was called with an element that doesn't exist"),null)}function i0(s,e,i){return typeof i=="function"&&(i=i(s,e)),typeof i!="boolean"&&(i=void 0),e.split(/\s+/).forEach(r=>s.classList.toggle(r,i)),s}function n0(s,e){Object.getOwnPropertyNames(e).forEach(function(i){const r=e[i];r===null||typeof r>"u"||r===!1?s.removeAttribute(i):s.setAttribute(i,r===!0?"":r)})}function hn(s){const e={},i=["autoplay","controls","playsinline","loop","muted","default","defaultMuted"];if(s&&s.attributes&&s.attributes.length>0){const r=s.attributes;for(let a=r.length-1;a>=0;a--){const o=r[a].name;let l=r[a].value;i.includes(o)&&(l=l!==null),e[o]=l}}return e}function r0(s,e){return s.getAttribute(e)}function cr(s,e,i){s.setAttribute(e,i)}function Pa(s,e){s.removeAttribute(e)}function s0(){pe.body.focus(),pe.onselectstart=function(){return!1}}function a0(){pe.onselectstart=function(){return!0}}function dr(s){if(s&&s.getBoundingClientRect&&s.parentNode){const e=s.getBoundingClientRect(),i={};return["bottom","height","left","right","top","width"].forEach(r=>{e[r]!==void 0&&(i[r]=e[r])}),i.height||(i.height=parseFloat(hr(s,"height"))),i.width||(i.width=parseFloat(hr(s,"width"))),i}}function rs(s){if(!s||s&&!s.offsetParent)return{left:0,top:0,width:0,height:0};const e=s.offsetWidth,i=s.offsetHeight;let r=0,a=0;for(;s.offsetParent&&s!==pe[sa.fullscreenElement];)r+=s.offsetLeft,a+=s.offsetTop,s=s.offsetParent;return{left:r,top:a,width:e,height:i}}function Ma(s,e){const i={x:0,y:0};if($t){let g=s;for(;g&&g.nodeName.toLowerCase()!=="html";){const y=hr(g,"transform");if(/^matrix/.test(y)){const E=y.slice(7,-1).split(/,\s/).map(Number);i.x+=E[4],i.y+=E[5]}else if(/^matrix3d/.test(y)){const E=y.slice(9,-1).split(/,\s/).map(Number);i.x+=E[12],i.y+=E[13]}if(g.assignedSlot&&g.assignedSlot.parentElement&&W.WebKitCSSMatrix){const E=W.getComputedStyle(g.assignedSlot.parentElement).transform,x=new W.WebKitCSSMatrix(E);i.x+=x.m41,i.y+=x.m42}g=g.parentNode||g.host}}const r={},a=rs(e.target),o=rs(s),l=o.width,u=o.height;let d=e.offsetY-(o.top-a.top),f=e.offsetX-(o.left-a.left);return e.changedTouches&&(f=e.changedTouches[0].pageX-o.left,d=e.changedTouches[0].pageY+o.top,$t&&(f-=i.x,d-=i.y)),r.y=1-Math.max(0,Math.min(1,d/u)),r.x=Math.max(0,Math.min(1,f/l)),r}function o0(s){return zi(s)&&s.nodeType===3}function Ra(s){for(;s.firstChild;)s.removeChild(s.firstChild);return s}function l0(s){return typeof s=="function"&&(s=s()),(Array.isArray(s)?s:[s]).map(e=>{if(typeof e=="function"&&(e=e()),gr(e)||o0(e))return e;if(typeof e=="string"&&/\S/.test(e))return pe.createTextNode(e)}).filter(e=>e)}function Fl(s,e){return l0(e).forEach(i=>s.appendChild(i)),s}function u0(s,e){return Fl(Ra(s),e)}function ss(s){return s.button===void 0&&s.buttons===void 0||s.button===0&&s.buttons===void 0||s.type==="mouseup"&&s.button===0&&s.buttons===0||s.type==="mousedown"&&s.button===0&&s.buttons===0?!0:!(s.button!==0||s.buttons!==1)}const yn=t0("querySelector"),c0=t0("querySelectorAll");function hr(s,e){if(!s||!e)return"";if(typeof W.getComputedStyle=="function"){let i;try{i=W.getComputedStyle(s)}catch{return""}return i?i.getPropertyValue(e)||i[e]:""}return""}function d0(s){[...pe.styleSheets].forEach(e=>{try{const i=[...e.cssRules].map(a=>a.cssText).join(""),r=pe.createElement("style");r.textContent=i,s.document.head.appendChild(r)}catch{const r=pe.createElement("link");r.rel="stylesheet",r.type=e.type,r.media=e.media.mediaText,r.href=e.href,s.document.head.appendChild(r)}})}var h0=Object.freeze({__proto__:null,isReal:mr,isEl:gr,isInFrame:e0,createEl:Be,textContent:vn,prependTo:sl,hasClass:Qr,addClass:On,removeClass:La,toggleClass:i0,setAttributes:n0,getAttributes:hn,getAttribute:r0,setAttribute:cr,removeAttribute:Pa,blockTextSelection:s0,unblockTextSelection:a0,getBoundingClientRect:dr,findPosition:rs,getPointerPosition:Ma,isTextNode:o0,emptyEl:Ra,normalizeContent:l0,appendContent:Fl,insertContent:u0,isSingleLeftClick:ss,$:yn,$$:c0,computedStyle:hr,copyStyleSheetsToWindow:d0});let f0=!1,al;const E8=function(){if(al.options.autoSetup===!1)return;const s=Array.prototype.slice.call(pe.getElementsByTagName("video")),e=Array.prototype.slice.call(pe.getElementsByTagName("audio")),i=Array.prototype.slice.call(pe.getElementsByTagName("video-js")),r=s.concat(e,i);if(r&&r.length>0)for(let a=0,o=r.length;a<o;a++){const l=r[a];if(l&&l.getAttribute)l.player===void 0&&l.getAttribute("data-setup")!==null&&al(l);else{ol(1);break}}else f0||ol(1)};function ol(s,e){mr()&&(e&&(al=e),W.setTimeout(E8,s))}function ll(){f0=!0,W.removeEventListener("load",ll)}mr()&&(pe.readyState==="complete"?ll():W.addEventListener("load",ll));const p0=function(s){const e=pe.createElement("style");return e.className=s,e},m0=function(s,e){s.styleSheet?s.styleSheet.cssText=e:s.textContent=e};var Zt=new WeakMap;const k8=3;let w8=k8;function vi(){return w8++}function fd(s,e){if(!Zt.has(s))return;const i=Zt.get(s);i.handlers[e].length===0&&(delete i.handlers[e],s.removeEventListener?s.removeEventListener(e,i.dispatcher,!1):s.detachEvent&&s.detachEvent("on"+e,i.dispatcher)),Object.getOwnPropertyNames(i.handlers).length<=0&&(delete i.handlers,delete i.dispatcher,delete i.disabled),Object.getOwnPropertyNames(i).length===0&&Zt.delete(s)}function $l(s,e,i,r){i.forEach(function(a){s(e,a,r)})}function Va(s){if(s.fixed_)return s;function e(){return!0}function i(){return!1}if(!s||!s.isPropagationStopped||!s.isImmediatePropagationStopped){const r=s||W.event;s={};const a=["layerX","layerY","keyLocation","path","webkitMovementX","webkitMovementY","mozPressure","mozInputSource"];for(const o in r)a.includes(o)||o==="returnValue"&&r.preventDefault||(s[o]=r[o]);if(s.target||(s.target=s.srcElement||pe),s.relatedTarget||(s.relatedTarget=s.fromElement===s.target?s.toElement:s.fromElement),s.preventDefault=function(){r.preventDefault&&r.preventDefault(),s.returnValue=!1,r.returnValue=!1,s.defaultPrevented=!0},s.defaultPrevented=!1,s.stopPropagation=function(){r.stopPropagation&&r.stopPropagation(),s.cancelBubble=!0,r.cancelBubble=!0,s.isPropagationStopped=e},s.isPropagationStopped=i,s.stopImmediatePropagation=function(){r.stopImmediatePropagation&&r.stopImmediatePropagation(),s.isImmediatePropagationStopped=e,s.stopPropagation()},s.isImmediatePropagationStopped=i,s.clientX!==null&&s.clientX!==void 0){const o=pe.documentElement,l=pe.body;s.pageX=s.clientX+(o&&o.scrollLeft||l&&l.scrollLeft||0)-(o&&o.clientLeft||l&&l.clientLeft||0),s.pageY=s.clientY+(o&&o.scrollTop||l&&l.scrollTop||0)-(o&&o.clientTop||l&&l.clientTop||0)}s.which=s.charCode||s.keyCode,s.button!==null&&s.button!==void 0&&(s.button=s.button&1?0:s.button&4?1:s.button&2?2:0)}return s.fixed_=!0,s}let qs;const D8=function(){if(typeof qs!="boolean"){qs=!1;try{const s=Object.defineProperty({},"passive",{get(){qs=!0}});W.addEventListener("test",null,s),W.removeEventListener("test",null,s)}catch{}}return qs},A8=["touchstart","touchmove"];function fi(s,e,i){if(Array.isArray(e))return $l(fi,s,e,i);Zt.has(s)||Zt.set(s,{});const r=Zt.get(s);if(r.handlers||(r.handlers={}),r.handlers[e]||(r.handlers[e]=[]),i.guid||(i.guid=vi()),r.handlers[e].push(i),r.dispatcher||(r.disabled=!1,r.dispatcher=function(a,o){if(r.disabled)return;a=Va(a);const l=r.handlers[a.type];if(l){const u=l.slice(0);for(let d=0,f=u.length;d<f&&!a.isImmediatePropagationStopped();d++)try{u[d].call(s,a,o)}catch(g){Ge.error(g)}}}),r.handlers[e].length===1)if(s.addEventListener){let a=!1;D8()&&A8.indexOf(e)>-1&&(a={passive:!0}),s.addEventListener(e,r.dispatcher,a)}else s.attachEvent&&s.attachEvent("on"+e,r.dispatcher)}function Ut(s,e,i){if(!Zt.has(s))return;const r=Zt.get(s);if(!r.handlers)return;if(Array.isArray(e))return $l(Ut,s,e,i);const a=function(l,u){r.handlers[u]=[],fd(l,u)};if(e===void 0){for(const l in r.handlers)Object.prototype.hasOwnProperty.call(r.handlers||{},l)&&a(s,l);return}const o=r.handlers[e];if(o){if(!i){a(s,e);return}if(i.guid)for(let l=0;l<o.length;l++)o[l].guid===i.guid&&o.splice(l--,1);fd(s,e)}}function _r(s,e,i){const r=Zt.has(s)?Zt.get(s):{},a=s.parentNode||s.ownerDocument;if(typeof e=="string"?e={type:e,target:s}:e.target||(e.target=s),e=Va(e),r.dispatcher&&r.dispatcher.call(s,e,i),a&&!e.isPropagationStopped()&&e.bubbles===!0)_r.call(null,a,e,i);else if(!a&&!e.defaultPrevented&&e.target&&e.target[e.type]){Zt.has(e.target)||Zt.set(e.target,{});const o=Zt.get(e.target);e.target[e.type]&&(o.disabled=!0,typeof e.target[e.type]=="function"&&e.target[e.type](),o.disabled=!1)}return!e.defaultPrevented}function Fa(s,e,i){if(Array.isArray(e))return $l(Fa,s,e,i);const r=function(){Ut(s,e,r),i.apply(this,arguments)};r.guid=i.guid=i.guid||vi(),fi(s,e,r)}function Ul(s,e,i){const r=function(){Ut(s,e,r),i.apply(this,arguments)};r.guid=i.guid=i.guid||vi(),fi(s,e,r)}var I8=Object.freeze({__proto__:null,fixEvent:Va,on:fi,off:Ut,trigger:_r,one:Fa,any:Ul});const Ti=30,lt=function(s,e,i){e.guid||(e.guid=vi());const r=e.bind(s);return r.guid=i?i+"_"+e.guid:e.guid,r},Wi=function(s,e){let i=W.performance.now();return function(...a){const o=W.performance.now();o-i>=e&&(s(...a),i=o)}},g0=function(s,e,i,r=W){let a;const o=()=>{r.clearTimeout(a),a=null},l=function(){const u=this,d=arguments;let f=function(){a=null,f=null,i||s.apply(u,d)};!a&&i&&s.apply(u,d),r.clearTimeout(a),a=r.setTimeout(f,e)};return l.cancel=o,l};var N8=Object.freeze({__proto__:null,UPDATE_REFRESH_INTERVAL:Ti,bind_:lt,throttle:Wi,debounce:g0});let jr;class pi{on(e,i){const r=this.addEventListener;this.addEventListener=()=>{},fi(this,e,i),this.addEventListener=r}off(e,i){Ut(this,e,i)}one(e,i){const r=this.addEventListener;this.addEventListener=()=>{},Fa(this,e,i),this.addEventListener=r}any(e,i){const r=this.addEventListener;this.addEventListener=()=>{},Ul(this,e,i),this.addEventListener=r}trigger(e){const i=e.type||e;typeof e=="string"&&(e={type:i}),e=Va(e),this.allowedEvents_[i]&&this["on"+i]&&this["on"+i](e),_r(this,e)}queueTrigger(e){jr||(jr=new Map);const i=e.type||e;let r=jr.get(this);r||(r=new Map,jr.set(this,r));const a=r.get(i);r.delete(i),W.clearTimeout(a);const o=W.setTimeout(()=>{r.delete(i),r.size===0&&(r=null,jr.delete(this)),this.trigger(e)},0);r.set(i,o)}}pi.prototype.allowedEvents_={};pi.prototype.addEventListener=pi.prototype.on;pi.prototype.removeEventListener=pi.prototype.off;pi.prototype.dispatchEvent=pi.prototype.trigger;const $a=s=>typeof s.name=="function"?s.name():typeof s.name=="string"?s.name:s.name_?s.name_:s.constructor&&s.constructor.name?s.constructor.name:typeof s,rn=s=>s instanceof pi||!!s.eventBusEl_&&["on","one","off","trigger"].every(e=>typeof s[e]=="function"),O8=(s,e)=>{rn(s)?e():(s.eventedCallbacks||(s.eventedCallbacks=[]),s.eventedCallbacks.push(e))},ul=s=>typeof s=="string"&&/\S/.test(s)||Array.isArray(s)&&!!s.length,da=(s,e,i)=>{if(!s||!s.nodeName&&!rn(s))throw new Error(`Invalid target for ${$a(e)}#${i}; must be a DOM node or evented object.`)},_0=(s,e,i)=>{if(!ul(s))throw new Error(`Invalid event type for ${$a(e)}#${i}; must be a non-empty string or array.`)},y0=(s,e,i)=>{if(typeof s!="function")throw new Error(`Invalid listener for ${$a(e)}#${i}; must be a function.`)},Po=(s,e,i)=>{const r=e.length<3||e[0]===s||e[0]===s.eventBusEl_;let a,o,l;return r?(a=s.eventBusEl_,e.length>=3&&e.shift(),[o,l]=e):(a=e[0],o=e[1],l=e[2]),da(a,s,i),_0(o,s,i),y0(l,s,i),l=lt(s,l),{isTargetingSelf:r,target:a,type:o,listener:l}},En=(s,e,i,r)=>{da(s,s,e),s.nodeName?I8[e](s,i,r):s[e](i,r)},B8={on(...s){const{isTargetingSelf:e,target:i,type:r,listener:a}=Po(this,s,"on");if(En(i,"on",r,a),!e){const o=()=>this.off(i,r,a);o.guid=a.guid;const l=()=>this.off("dispose",o);l.guid=a.guid,En(this,"on","dispose",o),En(i,"on","dispose",l)}},one(...s){const{isTargetingSelf:e,target:i,type:r,listener:a}=Po(this,s,"one");if(e)En(i,"one",r,a);else{const o=(...l)=>{this.off(i,r,o),a.apply(null,l)};o.guid=a.guid,En(i,"one",r,o)}},any(...s){const{isTargetingSelf:e,target:i,type:r,listener:a}=Po(this,s,"any");if(e)En(i,"any",r,a);else{const o=(...l)=>{this.off(i,r,o),a.apply(null,l)};o.guid=a.guid,En(i,"any",r,o)}},off(s,e,i){if(!s||ul(s))Ut(this.eventBusEl_,s,e);else{const r=s,a=e;da(r,this,"off"),_0(a,this,"off"),y0(i,this,"off"),i=lt(this,i),this.off("dispose",i),r.nodeName?(Ut(r,a,i),Ut(r,"dispose",i)):rn(r)&&(r.off(a,i),r.off("dispose",i))}},trigger(s,e){da(this.eventBusEl_,this,"trigger");const i=s&&typeof s!="string"?s.type:s;if(!ul(i))throw new Error(`Invalid event type for ${$a(this)}#trigger; must be a non-empty string or object with a type key that has a non-empty value.`);return _r(this.eventBusEl_,s,e)}};function ql(s,e={}){const{eventBusKey:i}=e;if(i){if(!s[i].nodeName)throw new Error(`The eventBusKey "${i}" does not refer to an element.`);s.eventBusEl_=s[i]}else s.eventBusEl_=Be("span",{className:"vjs-event-bus"});return Object.assign(s,B8),s.eventedCallbacks&&s.eventedCallbacks.forEach(r=>{r()}),s.on("dispose",()=>{s.off(),[s,s.el_,s.eventBusEl_].forEach(function(r){r&&Zt.has(r)&&Zt.delete(r)}),W.setTimeout(()=>{s.eventBusEl_=null},0)}),s}const L8={state:{},setState(s){typeof s=="function"&&(s=s());let e;return Kn(s,(i,r)=>{this.state[r]!==i&&(e=e||{},e[r]={from:this.state[r],to:i}),this.state[r]=i}),e&&rn(this)&&this.trigger({changes:e,type:"statechanged"}),e}};function v0(s,e){return Object.assign(s,L8),s.state=Object.assign({},s.state,e),typeof s.handleStateChanged=="function"&&rn(s)&&s.on("statechanged",s.handleStateChanged),s}const Zr=function(s){return typeof s!="string"?s:s.replace(/./,e=>e.toLowerCase())},gt=function(s){return typeof s!="string"?s:s.replace(/./,e=>e.toUpperCase())},T0=function(s,e){return gt(s)===gt(e)};var P8=Object.freeze({__proto__:null,toLowerCase:Zr,toTitleCase:gt,titleCaseEquals:T0});class oe{constructor(e,i,r){if(!e&&this.play?this.player_=e=this:this.player_=e,this.isDisposed_=!1,this.parentComponent_=null,this.options_=rt({},this.options_),i=this.options_=rt(this.options_,i),this.id_=i.id||i.el&&i.el.id,!this.id_){const a=e&&e.id&&e.id()||"no_player";this.id_=`${a}_component_${vi()}`}this.name_=i.name||null,i.el?this.el_=i.el:i.createEl!==!1&&(this.el_=this.createEl()),i.className&&this.el_&&i.className.split(" ").forEach(a=>this.addClass(a)),["on","off","one","any","trigger"].forEach(a=>{this[a]=void 0}),i.evented!==!1&&(ql(this,{eventBusKey:this.el_?"el_":null}),this.handleLanguagechange=this.handleLanguagechange.bind(this),this.on(this.player_,"languagechange",this.handleLanguagechange)),v0(this,this.constructor.defaultState),this.children_=[],this.childIndex_={},this.childNameIndex_={},this.setTimeoutIds_=new Set,this.setIntervalIds_=new Set,this.rafIds_=new Set,this.namedRafs_=new Map,this.clearingTimersOnDispose_=!1,i.initChildren!==!1&&this.initChildren(),this.ready(r),i.reportTouchActivity!==!1&&this.enableTouchActivity()}dispose(e={}){if(!this.isDisposed_){if(this.readyQueue_&&(this.readyQueue_.length=0),this.trigger({type:"dispose",bubbles:!1}),this.isDisposed_=!0,this.children_)for(let i=this.children_.length-1;i>=0;i--)this.children_[i].dispose&&this.children_[i].dispose();this.children_=null,this.childIndex_=null,this.childNameIndex_=null,this.parentComponent_=null,this.el_&&(this.el_.parentNode&&(e.restoreEl?this.el_.parentNode.replaceChild(e.restoreEl,this.el_):this.el_.parentNode.removeChild(this.el_)),this.el_=null),this.player_=null}}isDisposed(){return!!this.isDisposed_}player(){return this.player_}options(e){return e?(this.options_=rt(this.options_,e),this.options_):this.options_}el(){return this.el_}createEl(e,i,r){return Be(e,i,r)}localize(e,i,r=e){const a=this.player_.language&&this.player_.language(),o=this.player_.languages&&this.player_.languages(),l=o&&o[a],u=a&&a.split("-")[0],d=o&&o[u];let f=r;return l&&l[e]?f=l[e]:d&&d[e]&&(f=d[e]),i&&(f=f.replace(/\{(\d+)\}/g,function(g,y){const E=i[y-1];let x=E;return typeof E>"u"&&(x=g),x})),f}handleLanguagechange(){}contentEl(){return this.contentEl_||this.el_}id(){return this.id_}name(){return this.name_}children(){return this.children_}getChildById(e){return this.childIndex_[e]}getChild(e){if(e)return this.childNameIndex_[e]}getDescendant(...e){e=e.reduce((r,a)=>r.concat(a),[]);let i=this;for(let r=0;r<e.length;r++)if(i=i.getChild(e[r]),!i||!i.getChild)return;return i}setIcon(e,i=this.el()){if(!this.player_.options_.experimentalSvgIcons)return;const r="http://www.w3.org/2000/svg",a=Be("span",{className:"vjs-icon-placeholder vjs-svg-icon"},{"aria-hidden":"true"}),o=pe.createElementNS(r,"svg");o.setAttributeNS(null,"viewBox","0 0 512 512");const l=pe.createElementNS(r,"use");return o.appendChild(l),l.setAttributeNS(null,"href",`#vjs-icon-${e}`),a.appendChild(o),this.iconIsSet_?i.replaceChild(a,i.querySelector(".vjs-icon-placeholder")):i.appendChild(a),this.iconIsSet_=!0,a}addChild(e,i={},r=this.children_.length){let a,o;if(typeof e=="string"){o=gt(e);const l=i.componentClass||o;i.name=o;const u=oe.getComponent(l);if(!u)throw new Error(`Component ${l} does not exist`);if(typeof u!="function")return null;a=new u(this.player_||this,i)}else a=e;if(a.parentComponent_&&a.parentComponent_.removeChild(a),this.children_.splice(r,0,a),a.parentComponent_=this,typeof a.id=="function"&&(this.childIndex_[a.id()]=a),o=o||a.name&>(a.name()),o&&(this.childNameIndex_[o]=a,this.childNameIndex_[Zr(o)]=a),typeof a.el=="function"&&a.el()){let l=null;this.children_[r+1]&&(this.children_[r+1].el_?l=this.children_[r+1].el_:gr(this.children_[r+1])&&(l=this.children_[r+1])),this.contentEl().insertBefore(a.el(),l)}return a}removeChild(e){if(typeof e=="string"&&(e=this.getChild(e)),!e||!this.children_)return;let i=!1;for(let a=this.children_.length-1;a>=0;a--)if(this.children_[a]===e){i=!0,this.children_.splice(a,1);break}if(!i)return;e.parentComponent_=null,this.childIndex_[e.id()]=null,this.childNameIndex_[gt(e.name())]=null,this.childNameIndex_[Zr(e.name())]=null;const r=e.el();r&&r.parentNode===this.contentEl()&&this.contentEl().removeChild(e.el())}initChildren(){const e=this.options_.children;if(e){const i=this.options_,r=l=>{const u=l.name;let d=l.opts;if(i[u]!==void 0&&(d=i[u]),d===!1)return;d===!0&&(d={}),d.playerOptions=this.options_.playerOptions;const f=this.addChild(u,d);f&&(this[u]=f)};let a;const o=oe.getComponent("Tech");Array.isArray(e)?a=e:a=Object.keys(e),a.concat(Object.keys(this.options_).filter(function(l){return!a.some(function(u){return typeof u=="string"?l===u:l===u.name})})).map(l=>{let u,d;return typeof l=="string"?(u=l,d=e[u]||this.options_[u]||{}):(u=l.name,d=l),{name:u,opts:d}}).filter(l=>{const u=oe.getComponent(l.opts.componentClass||gt(l.name));return u&&!o.isTech(u)}).forEach(r)}}buildCSSClass(){return""}ready(e,i=!1){if(e){if(!this.isReady_){this.readyQueue_=this.readyQueue_||[],this.readyQueue_.push(e);return}i?e.call(this):this.setTimeout(e,1)}}triggerReady(){this.isReady_=!0,this.setTimeout(function(){const e=this.readyQueue_;this.readyQueue_=[],e&&e.length>0&&e.forEach(function(i){i.call(this)},this),this.trigger("ready")},1)}$(e,i){return yn(e,i||this.contentEl())}$$(e,i){return c0(e,i||this.contentEl())}hasClass(e){return Qr(this.el_,e)}addClass(...e){On(this.el_,...e)}removeClass(...e){La(this.el_,...e)}toggleClass(e,i){i0(this.el_,e,i)}show(){this.removeClass("vjs-hidden")}hide(){this.addClass("vjs-hidden")}lockShowing(){this.addClass("vjs-lock-showing")}unlockShowing(){this.removeClass("vjs-lock-showing")}getAttribute(e){return r0(this.el_,e)}setAttribute(e,i){cr(this.el_,e,i)}removeAttribute(e){Pa(this.el_,e)}width(e,i){return this.dimension("width",e,i)}height(e,i){return this.dimension("height",e,i)}dimensions(e,i){this.width(e,!0),this.height(i)}dimension(e,i,r){if(i!==void 0){(i===null||i!==i)&&(i=0),(""+i).indexOf("%")!==-1||(""+i).indexOf("px")!==-1?this.el_.style[e]=i:i==="auto"?this.el_.style[e]="":this.el_.style[e]=i+"px",r||this.trigger("componentresize");return}if(!this.el_)return 0;const a=this.el_.style[e],o=a.indexOf("px");return parseInt(o!==-1?a.slice(0,o):this.el_["offset"+gt(e)],10)}currentDimension(e){let i=0;if(e!=="width"&&e!=="height")throw new Error("currentDimension only accepts width or height value");if(i=hr(this.el_,e),i=parseFloat(i),i===0||isNaN(i)){const r=`offset${gt(e)}`;i=this.el_[r]}return i}currentDimensions(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}}currentWidth(){return this.currentDimension("width")}currentHeight(){return this.currentDimension("height")}getPositions(){const e=this.el_.getBoundingClientRect(),i={x:e.x,y:e.y,width:e.width,height:e.height,top:e.top,right:e.right,bottom:e.bottom,left:e.left},r={x:e.left+e.width/2,y:e.top+e.height/2,width:0,height:0,top:e.top+e.height/2,right:e.left+e.width/2,bottom:e.top+e.height/2,left:e.left+e.width/2};return{boundingClientRect:i,center:r}}focus(){this.el_.focus()}blur(){this.el_.blur()}handleKeyDown(e){this.player_&&(e.key!=="Tab"&&!(this.player_.options_.playerOptions.spatialNavigation&&this.player_.options_.playerOptions.spatialNavigation.enabled)&&e.stopPropagation(),this.player_.handleKeyDown(e))}handleKeyPress(e){this.handleKeyDown(e)}emitTapEvents(){let e=0,i=null;const r=10,a=200;let o;this.on("touchstart",function(u){u.touches.length===1&&(i={pageX:u.touches[0].pageX,pageY:u.touches[0].pageY},e=W.performance.now(),o=!0)}),this.on("touchmove",function(u){if(u.touches.length>1)o=!1;else if(i){const d=u.touches[0].pageX-i.pageX,f=u.touches[0].pageY-i.pageY;Math.sqrt(d*d+f*f)>r&&(o=!1)}});const l=function(){o=!1};this.on("touchleave",l),this.on("touchcancel",l),this.on("touchend",function(u){i=null,o===!0&&W.performance.now()-e<a&&(u.preventDefault(),this.trigger("tap"))})}enableTouchActivity(){if(!this.player()||!this.player().reportUserActivity)return;const e=lt(this.player(),this.player().reportUserActivity);let i;this.on("touchstart",function(){e(),this.clearInterval(i),i=this.setInterval(e,250)});const r=function(a){e(),this.clearInterval(i)};this.on("touchmove",e),this.on("touchend",r),this.on("touchcancel",r)}setTimeout(e,i){var r;return e=lt(this,e),this.clearTimersOnDispose_(),r=W.setTimeout(()=>{this.setTimeoutIds_.has(r)&&this.setTimeoutIds_.delete(r),e()},i),this.setTimeoutIds_.add(r),r}clearTimeout(e){return this.setTimeoutIds_.has(e)&&(this.setTimeoutIds_.delete(e),W.clearTimeout(e)),e}setInterval(e,i){e=lt(this,e),this.clearTimersOnDispose_();const r=W.setInterval(e,i);return this.setIntervalIds_.add(r),r}clearInterval(e){return this.setIntervalIds_.has(e)&&(this.setIntervalIds_.delete(e),W.clearInterval(e)),e}requestAnimationFrame(e){this.clearTimersOnDispose_();var i;return e=lt(this,e),i=W.requestAnimationFrame(()=>{this.rafIds_.has(i)&&this.rafIds_.delete(i),e()}),this.rafIds_.add(i),i}requestNamedAnimationFrame(e,i){this.namedRafs_.has(e)&&this.cancelNamedAnimationFrame(e),this.clearTimersOnDispose_(),i=lt(this,i);const r=this.requestAnimationFrame(()=>{i(),this.namedRafs_.has(e)&&this.namedRafs_.delete(e)});return this.namedRafs_.set(e,r),e}cancelNamedAnimationFrame(e){this.namedRafs_.has(e)&&(this.cancelAnimationFrame(this.namedRafs_.get(e)),this.namedRafs_.delete(e))}cancelAnimationFrame(e){return this.rafIds_.has(e)&&(this.rafIds_.delete(e),W.cancelAnimationFrame(e)),e}clearTimersOnDispose_(){this.clearingTimersOnDispose_||(this.clearingTimersOnDispose_=!0,this.one("dispose",()=>{[["namedRafs_","cancelNamedAnimationFrame"],["rafIds_","cancelAnimationFrame"],["setTimeoutIds_","clearTimeout"],["setIntervalIds_","clearInterval"]].forEach(([e,i])=>{this[e].forEach((r,a)=>this[i](a))}),this.clearingTimersOnDispose_=!1}))}getIsDisabled(){return!!this.el_.disabled}getIsExpresslyInert(){return this.el_.inert&&!this.el_.ownerDocument.documentElement.inert}getIsFocusable(e){return(e||this.el_).tabIndex>=0&&!(this.getIsDisabled()||this.getIsExpresslyInert())}getIsAvailableToBeFocused(e){function i(o){const l=W.getComputedStyle(o,null),u=l.getPropertyValue("visibility");return l.getPropertyValue("display")!=="none"&&!["hidden","collapse"].includes(u)}function r(o){return!(!i(o.parentElement)||!i(o)||o.style.opacity==="0"||W.getComputedStyle(o).height==="0px"||W.getComputedStyle(o).width==="0px")}function a(o){if(o.offsetWidth+o.offsetHeight+o.getBoundingClientRect().height+o.getBoundingClientRect().width===0)return!1;const l={x:o.getBoundingClientRect().left+o.offsetWidth/2,y:o.getBoundingClientRect().top+o.offsetHeight/2};if(l.x<0||l.x>(pe.documentElement.clientWidth||W.innerWidth)||l.y<0||l.y>(pe.documentElement.clientHeight||W.innerHeight))return!1;let u=pe.elementFromPoint(l.x,l.y);for(;u;){if(u===o)return!0;if(u.parentNode)u=u.parentNode;else return!1}}return e||(e=this.el()),!!(a(e)&&r(e)&&(!e.parentElement||e.tabIndex>=0))}static registerComponent(e,i){if(typeof e!="string"||!e)throw new Error(`Illegal component name, "${e}"; must be a non-empty string.`);const r=oe.getComponent("Tech"),a=r&&r.isTech(i),o=oe===i||oe.prototype.isPrototypeOf(i.prototype);if(a||!o){let u;throw a?u="techs must be registered using Tech.registerTech()":u="must be a Component subclass",new Error(`Illegal component, "${e}"; ${u}.`)}e=gt(e),oe.components_||(oe.components_={});const l=oe.getComponent("Player");if(e==="Player"&&l&&l.players){const u=l.players,d=Object.keys(u);if(u&&d.length>0){for(let f=0;f<d.length;f++)if(u[d[f]]!==null)throw new Error("Can not register Player component after player has been created.")}}return oe.components_[e]=i,oe.components_[Zr(e)]=i,i}static getComponent(e){if(!(!e||!oe.components_))return oe.components_[e]}}oe.registerComponent("Component",oe);function M8(s,e,i){if(typeof e!="number"||e<0||e>i)throw new Error(`Failed to execute '${s}' on 'TimeRanges': The index provided (${e}) is non-numeric or out of bounds (0-${i}).`)}function pd(s,e,i,r){return M8(s,r,i.length-1),i[r][e]}function Mo(s){let e;return s===void 0||s.length===0?e={length:0,start(){throw new Error("This TimeRanges object is empty")},end(){throw new Error("This TimeRanges object is empty")}}:e={length:s.length,start:pd.bind(null,"start",0,s),end:pd.bind(null,"end",1,s)},W.Symbol&&W.Symbol.iterator&&(e[W.Symbol.iterator]=()=>(s||[]).values()),e}function Oi(s,e){return Array.isArray(s)?Mo(s):s===void 0||e===void 0?Mo():Mo([[s,e]])}const b0=function(s,e){s=s<0?0:s;let i=Math.floor(s%60),r=Math.floor(s/60%60),a=Math.floor(s/3600);const o=Math.floor(e/60%60),l=Math.floor(e/3600);return(isNaN(s)||s===1/0)&&(a=r=i="-"),a=a>0||l>0?a+":":"",r=((a||o>=10)&&r<10?"0"+r:r)+":",i=i<10?"0"+i:i,a+r+i};let jl=b0;function x0(s){jl=s}function C0(){jl=b0}function Rn(s,e=s){return jl(s,e)}var R8=Object.freeze({__proto__:null,createTimeRanges:Oi,createTimeRange:Oi,setFormatTime:x0,resetFormatTime:C0,formatTime:Rn});function S0(s,e){let i=0,r,a;if(!e)return 0;(!s||!s.length)&&(s=Oi(0,0));for(let o=0;o<s.length;o++)r=s.start(o),a=s.end(o),a>e&&(a=e),i+=a-r;return i/e}function pt(s){if(s instanceof pt)return s;typeof s=="number"?this.code=s:typeof s=="string"?this.message=s:zi(s)&&(typeof s.code=="number"&&(this.code=s.code),Object.assign(this,s)),this.message||(this.message=pt.defaultMessages[this.code]||"")}pt.prototype.code=0;pt.prototype.message="";pt.prototype.status=null;pt.prototype.metadata=null;pt.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"];pt.defaultMessages={1:"You aborted the media playback",2:"A network error caused the media download to fail part-way.",3:"The media playback was aborted due to a corruption problem or because the media used features your browser did not support.",4:"The media could not be loaded, either because the server or network failed or because the format is not supported.",5:"The media is encrypted and we do not have the keys to decrypt it."};pt.MEDIA_ERR_CUSTOM=0;pt.prototype.MEDIA_ERR_CUSTOM=0;pt.MEDIA_ERR_ABORTED=1;pt.prototype.MEDIA_ERR_ABORTED=1;pt.MEDIA_ERR_NETWORK=2;pt.prototype.MEDIA_ERR_NETWORK=2;pt.MEDIA_ERR_DECODE=3;pt.prototype.MEDIA_ERR_DECODE=3;pt.MEDIA_ERR_SRC_NOT_SUPPORTED=4;pt.prototype.MEDIA_ERR_SRC_NOT_SUPPORTED=4;pt.MEDIA_ERR_ENCRYPTED=5;pt.prototype.MEDIA_ERR_ENCRYPTED=5;function Jr(s){return s!=null&&typeof s.then=="function"}function Ui(s){Jr(s)&&s.then(null,e=>{})}const cl=function(s){return["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce((i,r,a)=>(s[r]&&(i[r]=s[r]),i),{cues:s.cues&&Array.prototype.map.call(s.cues,function(i){return{startTime:i.startTime,endTime:i.endTime,text:i.text,id:i.id}})})},V8=function(s){const e=s.$$("track"),i=Array.prototype.map.call(e,a=>a.track);return Array.prototype.map.call(e,function(a){const o=cl(a.track);return a.src&&(o.src=a.src),o}).concat(Array.prototype.filter.call(s.textTracks(),function(a){return i.indexOf(a)===-1}).map(cl))},F8=function(s,e){return s.forEach(function(i){const r=e.addRemoteTextTrack(i).track;!i.src&&i.cues&&i.cues.forEach(a=>r.addCue(a))}),e.textTracks()};var dl={textTracksToJson:V8,jsonToTextTracks:F8,trackToJson:cl};const Ro="vjs-modal-dialog";class yr extends oe{constructor(e,i){super(e,i),this.handleKeyDown_=r=>this.handleKeyDown(r),this.close_=r=>this.close(r),this.opened_=this.hasBeenOpened_=this.hasBeenFilled_=!1,this.closeable(!this.options_.uncloseable),this.content(this.options_.content),this.contentEl_=Be("div",{className:`${Ro}-content`},{role:"document"}),this.descEl_=Be("p",{className:`${Ro}-description vjs-control-text`,id:this.el().getAttribute("aria-describedby")}),vn(this.descEl_,this.description()),this.el_.appendChild(this.descEl_),this.el_.appendChild(this.contentEl_)}createEl(){return super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-describedby":`${this.id()}_description`,"aria-hidden":"true","aria-label":this.label(),role:"dialog","aria-live":"polite"})}dispose(){this.contentEl_=null,this.descEl_=null,this.previouslyActiveEl_=null,super.dispose()}buildCSSClass(){return`${Ro} vjs-hidden ${super.buildCSSClass()}`}label(){return this.localize(this.options_.label||"Modal Window")}description(){let e=this.options_.description||this.localize("This is a modal window.");return this.closeable()&&(e+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),e}open(){if(this.opened_){this.options_.fillAlways&&this.fill();return}const e=this.player();this.trigger("beforemodalopen"),this.opened_=!0,(this.options_.fillAlways||!this.hasBeenOpened_&&!this.hasBeenFilled_)&&this.fill(),this.wasPlaying_=!e.paused(),this.options_.pauseOnOpen&&this.wasPlaying_&&e.pause(),this.on("keydown",this.handleKeyDown_),this.hadControls_=e.controls(),e.controls(!1),this.show(),this.conditionalFocus_(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.hasBeenOpened_=!0}opened(e){return typeof e=="boolean"&&this[e?"open":"close"](),this.opened_}close(){if(!this.opened_)return;const e=this.player();this.trigger("beforemodalclose"),this.opened_=!1,this.wasPlaying_&&this.options_.pauseOnOpen&&e.play(),this.off("keydown",this.handleKeyDown_),this.hadControls_&&e.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger({type:"modalclose",bubbles:!0}),this.conditionalBlur_(),this.options_.temporary&&this.dispose()}closeable(e){if(typeof e=="boolean"){const i=this.closeable_=!!e;let r=this.getChild("closeButton");if(i&&!r){const a=this.contentEl_;this.contentEl_=this.el_,r=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.contentEl_=a,this.on(r,"close",this.close_)}!i&&r&&(this.off(r,"close",this.close_),this.removeChild(r),r.dispose())}return this.closeable_}fill(){this.fillWith(this.content())}fillWith(e){const i=this.contentEl(),r=i.parentNode,a=i.nextSibling;this.trigger("beforemodalfill"),this.hasBeenFilled_=!0,r.removeChild(i),this.empty(),u0(i,e),this.trigger("modalfill"),a?r.insertBefore(i,a):r.appendChild(i);const o=this.getChild("closeButton");o&&r.appendChild(o.el_),this.trigger("aftermodalfill")}empty(){this.trigger("beforemodalempty"),Ra(this.contentEl()),this.trigger("modalempty")}content(e){return typeof e<"u"&&(this.content_=e),this.content_}conditionalFocus_(){const e=pe.activeElement,i=this.player_.el_;this.previouslyActiveEl_=null,(i.contains(e)||i===e)&&(this.previouslyActiveEl_=e,this.focus())}conditionalBlur_(){this.previouslyActiveEl_&&(this.previouslyActiveEl_.focus(),this.previouslyActiveEl_=null)}handleKeyDown(e){if(this.trigger({type:"modalKeydown",originalEvent:e,target:this,bubbles:!0}),e.stopPropagation(),e.key==="Escape"&&this.closeable()){e.preventDefault(),this.close();return}if(e.key!=="Tab")return;const i=this.focusableEls_(),r=this.el_.querySelector(":focus");let a;for(let o=0;o<i.length;o++)if(r===i[o]){a=o;break}pe.activeElement===this.el_&&(a=0),e.shiftKey&&a===0?(i[i.length-1].focus(),e.preventDefault()):!e.shiftKey&&a===i.length-1&&(i[0].focus(),e.preventDefault())}focusableEls_(){const e=this.el_.querySelectorAll("*");return Array.prototype.filter.call(e,i=>(i instanceof W.HTMLAnchorElement||i instanceof W.HTMLAreaElement)&&i.hasAttribute("href")||(i instanceof W.HTMLInputElement||i instanceof W.HTMLSelectElement||i instanceof W.HTMLTextAreaElement||i instanceof W.HTMLButtonElement)&&!i.hasAttribute("disabled")||i instanceof W.HTMLIFrameElement||i instanceof W.HTMLObjectElement||i instanceof W.HTMLEmbedElement||i.hasAttribute("tabindex")&&i.getAttribute("tabindex")!==-1||i.hasAttribute("contenteditable"))}}yr.prototype.options_={pauseOnOpen:!0,temporary:!0};oe.registerComponent("ModalDialog",yr);class Vn extends pi{constructor(e=[]){super(),this.tracks_=[];for(let i=0;i<e.length;i++)this.addTrack(e[i])}get length(){return this.tracks_.length}addTrack(e){const i=this.tracks_.length;""+i in this||Object.defineProperty(this,i,{get(){return this.tracks_[i]}}),this.tracks_.indexOf(e)===-1&&(this.tracks_.push(e),this.trigger({track:e,type:"addtrack",target:this})),e.labelchange_=()=>{this.trigger({track:e,type:"labelchange",target:this})},rn(e)&&e.addEventListener("labelchange",e.labelchange_)}removeTrack(e){let i;for(let r=0,a=this.length;r<a;r++)if(this[r]===e){i=this[r],i.off&&i.off(),this.tracks_.splice(r,1);break}i&&this.trigger({track:i,type:"removetrack",target:this})}getTrackById(e){let i=null;for(let r=0,a=this.length;r<a;r++){const o=this[r];if(o.id===e){i=o;break}}return i}}Vn.prototype.allowedEvents_={change:"change",addtrack:"addtrack",removetrack:"removetrack",labelchange:"labelchange"};for(const s in Vn.prototype.allowedEvents_)Vn.prototype["on"+s]=null;const Vo=function(s,e){for(let i=0;i<s.length;i++)!Object.keys(s[i]).length||e.id===s[i].id||(s[i].enabled=!1)};class E0 extends Vn{constructor(e=[]){for(let i=e.length-1;i>=0;i--)if(e[i].enabled){Vo(e,e[i]);break}super(e),this.changing_=!1}addTrack(e){e.enabled&&Vo(this,e),super.addTrack(e),e.addEventListener&&(e.enabledChange_=()=>{this.changing_||(this.changing_=!0,Vo(this,e),this.changing_=!1,this.trigger("change"))},e.addEventListener("enabledchange",e.enabledChange_))}removeTrack(e){super.removeTrack(e),e.removeEventListener&&e.enabledChange_&&(e.removeEventListener("enabledchange",e.enabledChange_),e.enabledChange_=null)}}const Fo=function(s,e){for(let i=0;i<s.length;i++)!Object.keys(s[i]).length||e.id===s[i].id||(s[i].selected=!1)};class k0 extends Vn{constructor(e=[]){for(let i=e.length-1;i>=0;i--)if(e[i].selected){Fo(e,e[i]);break}super(e),this.changing_=!1,Object.defineProperty(this,"selectedIndex",{get(){for(let i=0;i<this.length;i++)if(this[i].selected)return i;return-1},set(){}})}addTrack(e){e.selected&&Fo(this,e),super.addTrack(e),e.addEventListener&&(e.selectedChange_=()=>{this.changing_||(this.changing_=!0,Fo(this,e),this.changing_=!1,this.trigger("change"))},e.addEventListener("selectedchange",e.selectedChange_))}removeTrack(e){super.removeTrack(e),e.removeEventListener&&e.selectedChange_&&(e.removeEventListener("selectedchange",e.selectedChange_),e.selectedChange_=null)}}class Hl extends Vn{addTrack(e){super.addTrack(e),this.queueChange_||(this.queueChange_=()=>this.queueTrigger("change")),this.triggerSelectedlanguagechange||(this.triggerSelectedlanguagechange_=()=>this.trigger("selectedlanguagechange")),e.addEventListener("modechange",this.queueChange_),["metadata","chapters"].indexOf(e.kind)===-1&&e.addEventListener("modechange",this.triggerSelectedlanguagechange_)}removeTrack(e){super.removeTrack(e),e.removeEventListener&&(this.queueChange_&&e.removeEventListener("modechange",this.queueChange_),this.selectedlanguagechange_&&e.removeEventListener("modechange",this.triggerSelectedlanguagechange_))}toJSON(){return this.tracks_.map(e=>e.toJSON())}}class $8{constructor(e=[]){this.trackElements_=[],Object.defineProperty(this,"length",{get(){return this.trackElements_.length}});for(let i=0,r=e.length;i<r;i++)this.addTrackElement_(e[i])}addTrackElement_(e){const i=this.trackElements_.length;""+i in this||Object.defineProperty(this,i,{get(){return this.trackElements_[i]}}),this.trackElements_.indexOf(e)===-1&&this.trackElements_.push(e)}getTrackElementByTrack_(e){let i;for(let r=0,a=this.trackElements_.length;r<a;r++)if(e===this.trackElements_[r].track){i=this.trackElements_[r];break}return i}removeTrackElement_(e){for(let i=0,r=this.trackElements_.length;i<r;i++)if(e===this.trackElements_[i]){this.trackElements_[i].track&&typeof this.trackElements_[i].track.off=="function"&&this.trackElements_[i].track.off(),typeof this.trackElements_[i].off=="function"&&this.trackElements_[i].off(),this.trackElements_.splice(i,1);break}}}class ha{constructor(e){ha.prototype.setCues_.call(this,e),Object.defineProperty(this,"length",{get(){return this.length_}})}setCues_(e){const i=this.length||0;let r=0;const a=e.length;this.cues_=e,this.length_=e.length;const o=function(l){""+l in this||Object.defineProperty(this,""+l,{get(){return this.cues_[l]}})};if(i<a)for(r=i;r<a;r++)o.call(this,r)}getCueById(e){let i=null;for(let r=0,a=this.length;r<a;r++){const o=this[r];if(o.id===e){i=o;break}}return i}}const U8={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},q8={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},j8={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},md={disabled:"disabled",hidden:"hidden",showing:"showing"};class zl extends pi{constructor(e={}){super();const i={id:e.id||"vjs_track_"+vi(),kind:e.kind||"",language:e.language||""};let r=e.label||"";for(const a in i)Object.defineProperty(this,a,{get(){return i[a]},set(){}});Object.defineProperty(this,"label",{get(){return r},set(a){a!==r&&(r=a,this.trigger("labelchange"))}})}}const Gl=function(s){return new URL(s,pe.baseURI)},w0=function(s){return new URL(s,pe.baseURI).href},Wl=function(s){if(typeof s=="string"){const i=s.split("?")[0].replace(/\/+$/,"").match(/\.([^.\/]+)$/);return i?i[1].toLowerCase():""}return""},Ua=function(s,e=W.location){return Gl(s).origin!==e.origin};var H8=Object.freeze({__proto__:null,parseUrl:Gl,getAbsoluteURL:w0,getFileExtension:Wl,isCrossOrigin:Ua});const gd=function(s,e){const i=new W.WebVTT.Parser(W,W.vttjs,W.WebVTT.StringDecoder()),r=[];i.oncue=function(a){e.addCue(a)},i.onparsingerror=function(a){r.push(a)},i.onflush=function(){e.trigger({type:"loadeddata",target:e})},i.parse(s),r.length>0&&(W.console&&W.console.groupCollapsed&&W.console.groupCollapsed(`Text Track parsing errors for ${e.src}`),r.forEach(a=>Ge.error(a)),W.console&&W.console.groupEnd&&W.console.groupEnd()),i.flush()},_d=function(s,e){const i={uri:s},r=Ua(s);r&&(i.cors=r);const a=e.tech_.crossOrigin()==="use-credentials";a&&(i.withCredentials=a),Ah(i,lt(this,function(o,l,u){if(o)return Ge.error(o,l);e.loaded_=!0,typeof W.WebVTT!="function"?e.tech_&&e.tech_.any(["vttjsloaded","vttjserror"],d=>{if(d.type==="vttjserror"){Ge.error(`vttjs failed to load, stopping trying to process ${e.src}`);return}return gd(u,e)}):gd(u,e)}))};class ls extends zl{constructor(e={}){if(!e.tech)throw new Error("A tech was not provided.");const i=rt(e,{kind:j8[e.kind]||"subtitles",language:e.language||e.srclang||""});let r=md[i.mode]||"disabled";const a=i.default;(i.kind==="metadata"||i.kind==="chapters")&&(r="hidden"),super(i),this.tech_=i.tech,this.cues_=[],this.activeCues_=[],this.preload_=this.tech_.preloadTextTracks!==!1;const o=new ha(this.cues_),l=new ha(this.activeCues_);let u=!1;this.timeupdateHandler=lt(this,function(f={}){if(!this.tech_.isDisposed()){if(!this.tech_.isReady_){f.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler));return}this.activeCues=this.activeCues,u&&(this.trigger("cuechange"),u=!1),f.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler))}});const d=()=>{this.stopTracking()};this.tech_.one("dispose",d),r!=="disabled"&&this.startTracking(),Object.defineProperties(this,{default:{get(){return a},set(){}},mode:{get(){return r},set(f){md[f]&&r!==f&&(r=f,!this.preload_&&r!=="disabled"&&this.cues.length===0&&_d(this.src,this),this.stopTracking(),r!=="disabled"&&this.startTracking(),this.trigger("modechange"))}},cues:{get(){return this.loaded_?o:null},set(){}},activeCues:{get(){if(!this.loaded_)return null;if(this.cues.length===0)return l;const f=this.tech_.currentTime(),g=[];for(let y=0,E=this.cues.length;y<E;y++){const x=this.cues[y];x.startTime<=f&&x.endTime>=f&&g.push(x)}if(u=!1,g.length!==this.activeCues_.length)u=!0;else for(let y=0;y<g.length;y++)this.activeCues_.indexOf(g[y])===-1&&(u=!0);return this.activeCues_=g,l.setCues_(this.activeCues_),l},set(){}}}),i.src?(this.src=i.src,this.preload_||(this.loaded_=!0),(this.preload_||i.kind!=="subtitles"&&i.kind!=="captions")&&_d(this.src,this)):this.loaded_=!0}startTracking(){this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler),this.tech_.on("timeupdate",this.timeupdateHandler)}stopTracking(){this.rvf_&&(this.tech_.cancelVideoFrameCallback(this.rvf_),this.rvf_=void 0),this.tech_.off("timeupdate",this.timeupdateHandler)}addCue(e){let i=e;if(!("getCueAsHTML"in i)){i=new W.vttjs.VTTCue(e.startTime,e.endTime,e.text);for(const a in e)a in i||(i[a]=e[a]);i.id=e.id,i.originalCue_=e}const r=this.tech_.textTracks();for(let a=0;a<r.length;a++)r[a]!==this&&r[a].removeCue(i);this.cues_.push(i),this.cues.setCues_(this.cues_)}toJSON(){return dl.trackToJson(this)}removeCue(e){let i=this.cues_.length;for(;i--;){const r=this.cues_[i];if(r===e||r.originalCue_&&r.originalCue_===e){this.cues_.splice(i,1),this.cues.setCues_(this.cues_);break}}}}ls.prototype.allowedEvents_={cuechange:"cuechange"};class D0 extends zl{constructor(e={}){const i=rt(e,{kind:q8[e.kind]||""});super(i);let r=!1;Object.defineProperty(this,"enabled",{get(){return r},set(a){typeof a!="boolean"||a===r||(r=a,this.trigger("enabledchange"))}}),i.enabled&&(this.enabled=i.enabled),this.loaded_=!0}}class A0 extends zl{constructor(e={}){const i=rt(e,{kind:U8[e.kind]||""});super(i);let r=!1;Object.defineProperty(this,"selected",{get(){return r},set(a){typeof a!="boolean"||a===r||(r=a,this.trigger("selectedchange"))}}),i.selected&&(this.selected=i.selected)}}class sn extends pi{constructor(e={}){super();let i;const r=new ls(e);this.kind=r.kind,this.src=r.src,this.srclang=r.language,this.label=r.label,this.default=r.default,Object.defineProperties(this,{readyState:{get(){return i}},track:{get(){return r}}}),i=sn.NONE,r.addEventListener("loadeddata",()=>{i=sn.LOADED,this.trigger({type:"load",target:this})})}}sn.prototype.allowedEvents_={load:"load"};sn.NONE=0;sn.LOADING=1;sn.LOADED=2;sn.ERROR=3;const gi={audio:{ListClass:E0,TrackClass:D0,capitalName:"Audio"},video:{ListClass:k0,TrackClass:A0,capitalName:"Video"},text:{ListClass:Hl,TrackClass:ls,capitalName:"Text"}};Object.keys(gi).forEach(function(s){gi[s].getterName=`${s}Tracks`,gi[s].privateName=`${s}Tracks_`});const fr={remoteText:{ListClass:Hl,TrackClass:ls,capitalName:"RemoteText",getterName:"remoteTextTracks",privateName:"remoteTextTracks_"},remoteTextEl:{ListClass:$8,TrackClass:sn,capitalName:"RemoteTextTrackEls",getterName:"remoteTextTrackEls",privateName:"remoteTextTrackEls_"}},Qt=Object.assign({},gi,fr);fr.names=Object.keys(fr);gi.names=Object.keys(gi);Qt.names=[].concat(fr.names).concat(gi.names);function z8(s,e,i,r,a={}){const o=s.textTracks();a.kind=e,i&&(a.label=i),r&&(a.language=r),a.tech=s;const l=new Qt.text.TrackClass(a);return o.addTrack(l),l}class Re extends oe{constructor(e={},i=function(){}){e.reportTouchActivity=!1,super(null,e,i),this.onDurationChange_=r=>this.onDurationChange(r),this.trackProgress_=r=>this.trackProgress(r),this.trackCurrentTime_=r=>this.trackCurrentTime(r),this.stopTrackingCurrentTime_=r=>this.stopTrackingCurrentTime(r),this.disposeSourceHandler_=r=>this.disposeSourceHandler(r),this.queuedHanders_=new Set,this.hasStarted_=!1,this.on("playing",function(){this.hasStarted_=!0}),this.on("loadstart",function(){this.hasStarted_=!1}),Qt.names.forEach(r=>{const a=Qt[r];e&&e[a.getterName]&&(this[a.privateName]=e[a.getterName])}),this.featuresProgressEvents||this.manualProgressOn(),this.featuresTimeupdateEvents||this.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach(r=>{e[`native${r}Tracks`]===!1&&(this[`featuresNative${r}Tracks`]=!1)}),e.nativeCaptions===!1||e.nativeTextTracks===!1?this.featuresNativeTextTracks=!1:(e.nativeCaptions===!0||e.nativeTextTracks===!0)&&(this.featuresNativeTextTracks=!0),this.featuresNativeTextTracks||this.emulateTextTracks(),this.preloadTextTracks=e.preloadTextTracks!==!1,this.autoRemoteTextTracks_=new Qt.text.ListClass,this.initTrackListeners(),e.nativeControlsForTouch||this.emitTapEvents(),this.constructor&&(this.name_=this.constructor.name||"Unknown Tech")}triggerSourceset(e){this.isReady_||this.one("ready",()=>this.setTimeout(()=>this.triggerSourceset(e),1)),this.trigger({src:e,type:"sourceset"})}manualProgressOn(){this.on("durationchange",this.onDurationChange_),this.manualProgress=!0,this.one("ready",this.trackProgress_)}manualProgressOff(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange_)}trackProgress(e){this.stopTrackingProgress(),this.progressInterval=this.setInterval(lt(this,function(){const i=this.bufferedPercent();this.bufferedPercent_!==i&&this.trigger("progress"),this.bufferedPercent_=i,i===1&&this.stopTrackingProgress()}),500)}onDurationChange(e){this.duration_=this.duration()}buffered(){return Oi(0,0)}bufferedPercent(){return S0(this.buffered(),this.duration_)}stopTrackingProgress(){this.clearInterval(this.progressInterval)}manualTimeUpdatesOn(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime_),this.on("pause",this.stopTrackingCurrentTime_)}manualTimeUpdatesOff(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime_),this.off("pause",this.stopTrackingCurrentTime_)}trackCurrentTime(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval(function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},250)}stopTrackingCurrentTime(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}dispose(){this.clearTracks(gi.names),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),super.dispose()}clearTracks(e){e=[].concat(e),e.forEach(i=>{const r=this[`${i}Tracks`]()||[];let a=r.length;for(;a--;){const o=r[a];i==="text"&&this.removeRemoteTextTrack(o),r.removeTrack(o)}})}cleanupAutoTextTracks(){const e=this.autoRemoteTextTracks_||[];let i=e.length;for(;i--;){const r=e[i];this.removeRemoteTextTrack(r)}}reset(){}crossOrigin(){}setCrossOrigin(){}error(e){return e!==void 0&&(this.error_=new pt(e),this.trigger("error")),this.error_}played(){return this.hasStarted_?Oi(0,0):Oi()}play(){}setScrubbing(e){}scrubbing(){}setCurrentTime(e){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}initTrackListeners(){gi.names.forEach(e=>{const i=gi[e],r=()=>{this.trigger(`${e}trackchange`)},a=this[i.getterName]();a.addEventListener("removetrack",r),a.addEventListener("addtrack",r),this.on("dispose",()=>{a.removeEventListener("removetrack",r),a.removeEventListener("addtrack",r)})})}addWebVttScript_(){if(!W.WebVTT)if(pe.body.contains(this.el())){if(!this.options_["vtt.js"]&&ur(Uc)&&Object.keys(Uc).length>0){this.trigger("vttjsloaded");return}const e=pe.createElement("script");e.src=this.options_["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.14.1/vtt.min.js",e.onload=()=>{this.trigger("vttjsloaded")},e.onerror=()=>{this.trigger("vttjserror")},this.on("dispose",()=>{e.onload=null,e.onerror=null}),W.WebVTT=!0,this.el().parentNode.appendChild(e)}else this.ready(this.addWebVttScript_)}emulateTextTracks(){const e=this.textTracks(),i=this.remoteTextTracks(),r=u=>e.addTrack(u.track),a=u=>e.removeTrack(u.track);i.on("addtrack",r),i.on("removetrack",a),this.addWebVttScript_();const o=()=>this.trigger("texttrackchange"),l=()=>{o();for(let u=0;u<e.length;u++){const d=e[u];d.removeEventListener("cuechange",o),d.mode==="showing"&&d.addEventListener("cuechange",o)}};l(),e.addEventListener("change",l),e.addEventListener("addtrack",l),e.addEventListener("removetrack",l),this.on("dispose",function(){i.off("addtrack",r),i.off("removetrack",a),e.removeEventListener("change",l),e.removeEventListener("addtrack",l),e.removeEventListener("removetrack",l);for(let u=0;u<e.length;u++)e[u].removeEventListener("cuechange",o)})}addTextTrack(e,i,r){if(!e)throw new Error("TextTrack kind is required but was not provided");return z8(this,e,i,r)}createRemoteTextTrack(e){const i=rt(e,{tech:this});return new fr.remoteTextEl.TrackClass(i)}addRemoteTextTrack(e={},i){const r=this.createRemoteTextTrack(e);return typeof i!="boolean"&&(i=!1),this.remoteTextTrackEls().addTrackElement_(r),this.remoteTextTracks().addTrack(r.track),i===!1&&this.ready(()=>this.autoRemoteTextTracks_.addTrack(r.track)),r}removeRemoteTextTrack(e){const i=this.remoteTextTrackEls().getTrackElementByTrack_(e);this.remoteTextTrackEls().removeTrackElement_(i),this.remoteTextTracks().removeTrack(e),this.autoRemoteTextTracks_.removeTrack(e)}getVideoPlaybackQuality(){return{}}requestPictureInPicture(){return Promise.reject()}disablePictureInPicture(){return!0}setDisablePictureInPicture(){}requestVideoFrameCallback(e){const i=vi();return!this.isReady_||this.paused()?(this.queuedHanders_.add(i),this.one("playing",()=>{this.queuedHanders_.has(i)&&(this.queuedHanders_.delete(i),e())})):this.requestNamedAnimationFrame(i,e),i}cancelVideoFrameCallback(e){this.queuedHanders_.has(e)?this.queuedHanders_.delete(e):this.cancelNamedAnimationFrame(e)}setPoster(){}playsinline(){}setPlaysinline(){}overrideNativeAudioTracks(e){}overrideNativeVideoTracks(e){}canPlayType(e){return""}static canPlayType(e){return""}static canPlaySource(e,i){return Re.canPlayType(e.type)}static isTech(e){return e.prototype instanceof Re||e instanceof Re||e===Re}static registerTech(e,i){if(Re.techs_||(Re.techs_={}),!Re.isTech(i))throw new Error(`Tech ${e} must be a Tech`);if(!Re.canPlayType)throw new Error("Techs must have a static canPlayType method on them");if(!Re.canPlaySource)throw new Error("Techs must have a static canPlaySource method on them");return e=gt(e),Re.techs_[e]=i,Re.techs_[Zr(e)]=i,e!=="Tech"&&Re.defaultTechOrder_.push(e),i}static getTech(e){if(e){if(Re.techs_&&Re.techs_[e])return Re.techs_[e];if(e=gt(e),W&&W.videojs&&W.videojs[e])return Ge.warn(`The ${e} tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)`),W.videojs[e]}}}Qt.names.forEach(function(s){const e=Qt[s];Re.prototype[e.getterName]=function(){return this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName]}});Re.prototype.featuresVolumeControl=!0;Re.prototype.featuresMuteControl=!0;Re.prototype.featuresFullscreenResize=!1;Re.prototype.featuresPlaybackRate=!1;Re.prototype.featuresProgressEvents=!1;Re.prototype.featuresSourceset=!1;Re.prototype.featuresTimeupdateEvents=!1;Re.prototype.featuresNativeTextTracks=!1;Re.prototype.featuresVideoFrameCallback=!1;Re.withSourceHandlers=function(s){s.registerSourceHandler=function(i,r){let a=s.sourceHandlers;a||(a=s.sourceHandlers=[]),r===void 0&&(r=a.length),a.splice(r,0,i)},s.canPlayType=function(i){const r=s.sourceHandlers||[];let a;for(let o=0;o<r.length;o++)if(a=r[o].canPlayType(i),a)return a;return""},s.selectSourceHandler=function(i,r){const a=s.sourceHandlers||[];let o;for(let l=0;l<a.length;l++)if(o=a[l].canHandleSource(i,r),o)return a[l];return null},s.canPlaySource=function(i,r){const a=s.selectSourceHandler(i,r);return a?a.canHandleSource(i,r):""},["seekable","seeking","duration"].forEach(function(i){const r=this[i];typeof r=="function"&&(this[i]=function(){return this.sourceHandler_&&this.sourceHandler_[i]?this.sourceHandler_[i].apply(this.sourceHandler_,arguments):r.apply(this,arguments)})},s.prototype),s.prototype.setSource=function(i){let r=s.selectSourceHandler(i,this.options_);r||(s.nativeSourceHandler?r=s.nativeSourceHandler:Ge.error("No source handler found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler_),r!==s.nativeSourceHandler&&(this.currentSource_=i),this.sourceHandler_=r.handleSource(i,this,this.options_),this.one("dispose",this.disposeSourceHandler_)},s.prototype.disposeSourceHandler=function(){this.currentSource_&&(this.clearTracks(["audio","video"]),this.currentSource_=null),this.cleanupAutoTextTracks(),this.sourceHandler_&&(this.sourceHandler_.dispose&&this.sourceHandler_.dispose(),this.sourceHandler_=null)}};oe.registerComponent("Tech",Re);Re.registerTech("Tech",Re);Re.defaultTechOrder_=[];const Bn={},fa={},pa={};function G8(s,e){Bn[s]=Bn[s]||[],Bn[s].push(e)}function W8(s,e,i){s.setTimeout(()=>kn(e,Bn[e.type],i,s),1)}function Y8(s,e){s.forEach(i=>i.setTech&&i.setTech(e))}function X8(s,e,i){return s.reduceRight(Yl(i),e[i]())}function K8(s,e,i,r){return e[i](s.reduce(Yl(i),r))}function yd(s,e,i,r=null){const a="call"+gt(i),o=s.reduce(Yl(a),r),l=o===pa,u=l?null:e[i](o);return J8(s,i,u,l),u}const Q8={buffered:1,currentTime:1,duration:1,muted:1,played:1,paused:1,seekable:1,volume:1,ended:1},Z8={setCurrentTime:1,setMuted:1,setVolume:1},vd={play:1,pause:1};function Yl(s){return(e,i)=>e===pa?pa:i[s]?i[s](e):e}function J8(s,e,i,r){for(let a=s.length-1;a>=0;a--){const o=s[a];o[e]&&o[e](r,i)}}function ex(s){fa.hasOwnProperty(s.id())&&delete fa[s.id()]}function tx(s,e){const i=fa[s.id()];let r=null;if(i==null)return r=e(s),fa[s.id()]=[[e,r]],r;for(let a=0;a<i.length;a++){const[o,l]=i[a];o===e&&(r=l)}return r===null&&(r=e(s),i.push([e,r])),r}function kn(s={},e=[],i,r,a=[],o=!1){const[l,...u]=e;if(typeof l=="string")kn(s,Bn[l],i,r,a,o);else if(l){const d=tx(r,l);if(!d.setSource)return a.push(d),kn(s,u,i,r,a,o);d.setSource(Object.assign({},s),function(f,g){if(f)return kn(s,u,i,r,a,o);a.push(d),kn(g,s.type===g.type?u:Bn[g.type],i,r,a,o)})}else u.length?kn(s,u,i,r,a,o):o?i(s,a):kn(s,Bn["*"],i,r,a,!0)}const ix={opus:"video/ogg",ogv:"video/ogg",mp4:"video/mp4",mov:"video/mp4",m4v:"video/mp4",mkv:"video/x-matroska",m4a:"audio/mp4",mp3:"audio/mpeg",aac:"audio/aac",caf:"audio/x-caf",flac:"audio/flac",oga:"audio/ogg",wav:"audio/wav",m3u8:"application/x-mpegURL",mpd:"application/dash+xml",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",png:"image/png",svg:"image/svg+xml",webp:"image/webp"},ma=function(s=""){const e=Wl(s);return ix[e.toLowerCase()]||""},nx=(s,e)=>{if(!e)return"";if(s.cache_.source.src===e&&s.cache_.source.type)return s.cache_.source.type;const i=s.cache_.sources.filter(a=>a.src===e);if(i.length)return i[0].type;const r=s.$$("source");for(let a=0;a<r.length;a++){const o=r[a];if(o.type&&o.src&&o.src===e)return o.type}return ma(e)},I0=function(s){if(Array.isArray(s)){let e=[];s.forEach(function(i){i=I0(i),Array.isArray(i)?e=e.concat(i):zi(i)&&e.push(i)}),s=e}else typeof s=="string"&&s.trim()?s=[Td({src:s})]:zi(s)&&typeof s.src=="string"&&s.src&&s.src.trim()?s=[Td(s)]:s=[];return s};function Td(s){if(!s.type){const e=ma(s.src);e&&(s.type=e)}return s}var rx=`<svg xmlns="http://www.w3.org/2000/svg">
|
|
38
|
+
<defs>
|
|
39
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-play">
|
|
40
|
+
<path d="M16 10v28l22-14z"></path>
|
|
41
|
+
</symbol>
|
|
42
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-pause">
|
|
43
|
+
<path d="M12 38h8V10h-8v28zm16-28v28h8V10h-8z"></path>
|
|
44
|
+
</symbol>
|
|
45
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-audio">
|
|
46
|
+
<path d="M24 2C14.06 2 6 10.06 6 20v14c0 3.31 2.69 6 6 6h6V24h-8v-4c0-7.73 6.27-14 14-14s14 6.27 14 14v4h-8v16h6c3.31 0 6-2.69 6-6V20c0-9.94-8.06-18-18-18z"></path>
|
|
47
|
+
</symbol>
|
|
48
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-captions">
|
|
49
|
+
<path d="M38 8H10c-2.21 0-4 1.79-4 4v24c0 2.21 1.79 4 4 4h28c2.21 0 4-1.79 4-4V12c0-2.21-1.79-4-4-4zM22 22h-3v-1h-4v6h4v-1h3v2a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v2zm14 0h-3v-1h-4v6h4v-1h3v2a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v2z"></path>
|
|
50
|
+
</symbol>
|
|
51
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-subtitles">
|
|
52
|
+
<path d="M40 8H8c-2.21 0-4 1.79-4 4v24c0 2.21 1.79 4 4 4h32c2.21 0 4-1.79 4-4V12c0-2.21-1.79-4-4-4zM8 24h8v4H8v-4zm20 12H8v-4h20v4zm12 0h-8v-4h8v4zm0-8H20v-4h20v4z"></path>
|
|
53
|
+
</symbol>
|
|
54
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-fullscreen-enter">
|
|
55
|
+
<path d="M14 28h-4v10h10v-4h-6v-6zm-4-8h4v-6h6v-4H10v10zm24 14h-6v4h10V28h-4v6zm-6-24v4h6v6h4V10H28z"></path>
|
|
56
|
+
</symbol>
|
|
57
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-fullscreen-exit">
|
|
58
|
+
<path d="M10 32h6v6h4V28H10v4zm6-16h-6v4h10V10h-4v6zm12 22h4v-6h6v-4H28v10zm4-22v-6h-4v10h10v-4h-6z"></path>
|
|
59
|
+
</symbol>
|
|
60
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-play-circle">
|
|
61
|
+
<path d="M20 33l12-9-12-9v18zm4-29C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05 4 24 4zm0 36c-8.82 0-16-7.18-16-16S15.18 8 24 8s16 7.18 16 16-7.18 16-16 16z"></path>
|
|
62
|
+
</symbol>
|
|
63
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-volume-mute">
|
|
64
|
+
<path d="M33 24c0-3.53-2.04-6.58-5-8.05v4.42l4.91 4.91c.06-.42.09-.85.09-1.28zm5 0c0 1.88-.41 3.65-1.08 5.28l3.03 3.03C41.25 29.82 42 27 42 24c0-8.56-5.99-15.72-14-17.54v4.13c5.78 1.72 10 7.07 10 13.41zM8.55 6L6 8.55 15.45 18H6v12h8l10 10V26.55l8.51 8.51c-1.34 1.03-2.85 1.86-4.51 2.36v4.13a17.94 17.94 0 0 0 7.37-3.62L39.45 42 42 39.45l-18-18L8.55 6zM24 8l-4.18 4.18L24 16.36V8z"></path>
|
|
65
|
+
</symbol>
|
|
66
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-volume-low">
|
|
67
|
+
<path d="M14 18v12h8l10 10V8L22 18h-8z"></path>
|
|
68
|
+
</symbol>
|
|
69
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-volume-medium">
|
|
70
|
+
<path d="M37 24c0-3.53-2.04-6.58-5-8.05v16.11c2.96-1.48 5-4.53 5-8.06zm-27-6v12h8l10 10V8L18 18h-8z"></path>
|
|
71
|
+
</symbol>
|
|
72
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-volume-high">
|
|
73
|
+
<path d="M6 18v12h8l10 10V8L14 18H6zm27 6c0-3.53-2.04-6.58-5-8.05v16.11c2.96-1.48 5-4.53 5-8.06zM28 6.46v4.13c5.78 1.72 10 7.07 10 13.41s-4.22 11.69-10 13.41v4.13c8.01-1.82 14-8.97 14-17.54S36.01 8.28 28 6.46z"></path>
|
|
74
|
+
</symbol>
|
|
75
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-spinner">
|
|
76
|
+
<path d="M18.8 21l9.53-16.51C26.94 4.18 25.49 4 24 4c-4.8 0-9.19 1.69-12.64 4.51l7.33 12.69.11-.2zm24.28-3c-1.84-5.85-6.3-10.52-11.99-12.68L23.77 18h19.31zm.52 2H28.62l.58 1 9.53 16.5C41.99 33.94 44 29.21 44 24c0-1.37-.14-2.71-.4-4zm-26.53 4l-7.8-13.5C6.01 14.06 4 18.79 4 24c0 1.37.14 2.71.4 4h14.98l-2.31-4zM4.92 30c1.84 5.85 6.3 10.52 11.99 12.68L24.23 30H4.92zm22.54 0l-7.8 13.51c1.4.31 2.85.49 4.34.49 4.8 0 9.19-1.69 12.64-4.51L29.31 26.8 27.46 30z"></path>
|
|
77
|
+
</symbol>
|
|
78
|
+
<symbol viewBox="0 0 24 24" id="vjs-icon-hd">
|
|
79
|
+
<path d="M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-8 12H9.5v-2h-2v2H6V9h1.5v2.5h2V9H11v6zm2-6h4c.55 0 1 .45 1 1v4c0 .55-.45 1-1 1h-4V9zm1.5 4.5h2v-3h-2v3z"></path>
|
|
80
|
+
</symbol>
|
|
81
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-chapters">
|
|
82
|
+
<path d="M6 26h4v-4H6v4zm0 8h4v-4H6v4zm0-16h4v-4H6v4zm8 8h28v-4H14v4zm0 8h28v-4H14v4zm0-20v4h28v-4H14z"></path>
|
|
83
|
+
</symbol>
|
|
84
|
+
<symbol viewBox="0 0 40 40" id="vjs-icon-downloading">
|
|
85
|
+
<path d="M18.208 36.875q-3.208-.292-5.979-1.729-2.771-1.438-4.812-3.729-2.042-2.292-3.188-5.229-1.146-2.938-1.146-6.23 0-6.583 4.334-11.416 4.333-4.834 10.833-5.5v3.166q-5.167.75-8.583 4.646Q6.25 14.75 6.25 19.958q0 5.209 3.396 9.104 3.396 3.896 8.562 4.646zM20 28.417L11.542 20l2.083-2.083 4.917 4.916v-11.25h2.916v11.25l4.875-4.916L28.417 20zm1.792 8.458v-3.167q1.833-.25 3.541-.958 1.709-.708 3.167-1.875l2.333 2.292q-1.958 1.583-4.25 2.541-2.291.959-4.791 1.167zm6.791-27.792q-1.541-1.125-3.25-1.854-1.708-.729-3.541-1.021V3.042q2.5.25 4.77 1.208 2.271.958 4.271 2.5zm4.584 21.584l-2.25-2.25q1.166-1.5 1.854-3.209.687-1.708.937-3.541h3.209q-.292 2.5-1.229 4.791-.938 2.292-2.521 4.209zm.541-12.417q-.291-1.833-.958-3.562-.667-1.73-1.833-3.188l2.375-2.208q1.541 1.916 2.458 4.208.917 2.292 1.167 4.75z"></path>
|
|
86
|
+
</symbol>
|
|
87
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-file-download">
|
|
88
|
+
<path d="M10.8 40.55q-1.35 0-2.375-1T7.4 37.15v-7.7h3.4v7.7h26.35v-7.7h3.4v7.7q0 1.4-1 2.4t-2.4 1zM24 32.1L13.9 22.05l2.45-2.45 5.95 5.95V7.15h3.4v18.4l5.95-5.95 2.45 2.45z"></path>
|
|
89
|
+
</symbol>
|
|
90
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-file-download-done">
|
|
91
|
+
<path d="M9.8 40.5v-3.45h28.4v3.45zm9.2-9.05L7.4 19.85l2.45-2.35L19 26.65l19.2-19.2 2.4 2.4z"></path>
|
|
92
|
+
</symbol>
|
|
93
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-file-download-off">
|
|
94
|
+
<path d="M4.9 4.75L43.25 43.1 41 45.3l-4.75-4.75q-.05.05-.075.025-.025-.025-.075-.025H10.8q-1.35 0-2.375-1T7.4 37.15v-7.7h3.4v7.7h22.05l-7-7-1.85 1.8L13.9 21.9l1.85-1.85L2.7 7zm26.75 14.7l2.45 2.45-3.75 3.8-2.45-2.5zM25.7 7.15V21.1l-3.4-3.45V7.15z"></path>
|
|
95
|
+
</symbol>
|
|
96
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-share">
|
|
97
|
+
<path d="M36 32.17c-1.52 0-2.89.59-3.93 1.54L17.82 25.4c.11-.45.18-.92.18-1.4s-.07-.95-.18-1.4l14.1-8.23c1.07 1 2.5 1.62 4.08 1.62 3.31 0 6-2.69 6-6s-2.69-6-6-6-6 2.69-6 6c0 .48.07.95.18 1.4l-14.1 8.23c-1.07-1-2.5-1.62-4.08-1.62-3.31 0-6 2.69-6 6s2.69 6 6 6c1.58 0 3.01-.62 4.08-1.62l14.25 8.31c-.1.42-.16.86-.16 1.31A5.83 5.83 0 1 0 36 32.17z"></path>
|
|
98
|
+
</symbol>
|
|
99
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-cog">
|
|
100
|
+
<path d="M38.86 25.95c.08-.64.14-1.29.14-1.95s-.06-1.31-.14-1.95l4.23-3.31c.38-.3.49-.84.24-1.28l-4-6.93c-.25-.43-.77-.61-1.22-.43l-4.98 2.01c-1.03-.79-2.16-1.46-3.38-1.97L29 4.84c-.09-.47-.5-.84-1-.84h-8c-.5 0-.91.37-.99.84l-.75 5.3a14.8 14.8 0 0 0-3.38 1.97L9.9 10.1a1 1 0 0 0-1.22.43l-4 6.93c-.25.43-.14.97.24 1.28l4.22 3.31C9.06 22.69 9 23.34 9 24s.06 1.31.14 1.95l-4.22 3.31c-.38.3-.49.84-.24 1.28l4 6.93c.25.43.77.61 1.22.43l4.98-2.01c1.03.79 2.16 1.46 3.38 1.97l.75 5.3c.08.47.49.84.99.84h8c.5 0 .91-.37.99-.84l.75-5.3a14.8 14.8 0 0 0 3.38-1.97l4.98 2.01a1 1 0 0 0 1.22-.43l4-6.93c.25-.43.14-.97-.24-1.28l-4.22-3.31zM24 31c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"></path>
|
|
101
|
+
</symbol>
|
|
102
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-square">
|
|
103
|
+
<path d="M36 8H12c-2.21 0-4 1.79-4 4v24c0 2.21 1.79 4 4 4h24c2.21 0 4-1.79 4-4V12c0-2.21-1.79-4-4-4zm0 28H12V12h24v24z"></path>
|
|
104
|
+
</symbol>
|
|
105
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-circle">
|
|
106
|
+
<circle cx="24" cy="24" r="20"></circle>
|
|
107
|
+
</symbol>
|
|
108
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-circle-outline">
|
|
109
|
+
<path d="M24 4C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05 4 24 4zm0 36c-8.82 0-16-7.18-16-16S15.18 8 24 8s16 7.18 16 16-7.18 16-16 16z"></path>
|
|
110
|
+
</symbol>
|
|
111
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-circle-inner-circle">
|
|
112
|
+
<path d="M24 4C12.97 4 4 12.97 4 24s8.97 20 20 20 20-8.97 20-20S35.03 4 24 4zm0 36c-8.82 0-16-7.18-16-16S15.18 8 24 8s16 7.18 16 16-7.18 16-16 16zm6-16c0 3.31-2.69 6-6 6s-6-2.69-6-6 2.69-6 6-6 6 2.69 6 6z"></path>
|
|
113
|
+
</symbol>
|
|
114
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-cancel">
|
|
115
|
+
<path d="M24 4C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05 4 24 4zm10 27.17L31.17 34 24 26.83 16.83 34 14 31.17 21.17 24 14 16.83 16.83 14 24 21.17 31.17 14 34 16.83 26.83 24 34 31.17z"></path>
|
|
116
|
+
</symbol>
|
|
117
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-replay">
|
|
118
|
+
<path d="M24 10V2L14 12l10 10v-8c6.63 0 12 5.37 12 12s-5.37 12-12 12-12-5.37-12-12H8c0 8.84 7.16 16 16 16s16-7.16 16-16-7.16-16-16-16z"></path>
|
|
119
|
+
</symbol>
|
|
120
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-repeat">
|
|
121
|
+
<path d="M14 14h20v6l8-8-8-8v6H10v12h4v-8zm20 20H14v-6l-8 8 8 8v-6h24V26h-4v8z"></path>
|
|
122
|
+
</symbol>
|
|
123
|
+
<symbol viewBox="0 96 48 48" id="vjs-icon-replay-5">
|
|
124
|
+
<path d="M17.689 98l-8.697 8.696 8.697 8.697 2.486-2.485-4.32-4.319h1.302c4.93 0 9.071 1.722 12.424 5.165 3.352 3.443 5.029 7.638 5.029 12.584h3.55c0-2.958-.553-5.73-1.658-8.313-1.104-2.583-2.622-4.841-4.555-6.774-1.932-1.932-4.19-3.45-6.773-4.555-2.584-1.104-5.355-1.657-8.313-1.657H15.5l4.615-4.615zm-8.08 21.659v13.861h11.357v5.008H9.609V143h12.7c.834 0 1.55-.298 2.146-.894.596-.597.895-1.31.895-2.145v-7.781c0-.835-.299-1.55-.895-2.147a2.929 2.929 0 0 0-2.147-.894h-8.227v-5.096H25.35v-4.384z"></path>
|
|
125
|
+
</symbol>
|
|
126
|
+
<symbol viewBox="0 96 48 48" id="vjs-icon-replay-10">
|
|
127
|
+
<path d="M42.315 125.63c0-4.997-1.694-9.235-5.08-12.713-3.388-3.479-7.571-5.218-12.552-5.218h-1.315l4.363 4.363-2.51 2.51-8.787-8.786L25.221 97l2.45 2.45-4.662 4.663h1.375c2.988 0 5.788.557 8.397 1.673 2.61 1.116 4.892 2.65 6.844 4.602 1.953 1.953 3.487 4.234 4.602 6.844 1.116 2.61 1.674 5.41 1.674 8.398zM8.183 142v-19.657H3.176V117.8h9.643V142zm13.63 0c-1.156 0-2.127-.393-2.912-1.178-.778-.778-1.168-1.746-1.168-2.902v-16.04c0-1.156.393-2.127 1.178-2.912.779-.779 1.746-1.168 2.902-1.168h7.696c1.156 0 2.126.392 2.911 1.177.779.78 1.168 1.747 1.168 2.903v16.04c0 1.156-.392 2.127-1.177 2.912-.779.779-1.746 1.168-2.902 1.168zm.556-4.636h6.583v-15.02H22.37z"></path>
|
|
128
|
+
</symbol>
|
|
129
|
+
<symbol viewBox="0 96 48 48" id="vjs-icon-replay-30">
|
|
130
|
+
<path d="M26.047 97l-8.733 8.732 8.733 8.733 2.496-2.494-4.336-4.338h1.307c4.95 0 9.108 1.73 12.474 5.187 3.367 3.458 5.051 7.668 5.051 12.635h3.565c0-2.97-.556-5.751-1.665-8.346-1.109-2.594-2.633-4.862-4.574-6.802-1.94-1.941-4.208-3.466-6.803-4.575-2.594-1.109-5.375-1.664-8.345-1.664H23.85l4.634-4.634zM2.555 117.531v4.688h10.297v5.25H5.873v4.687h6.979v5.156H2.555V142H13.36c1.061 0 1.95-.395 2.668-1.186.718-.79 1.076-1.772 1.076-2.94v-16.218c0-1.168-.358-2.149-1.076-2.94-.717-.79-1.607-1.185-2.668-1.185zm22.482.14c-1.149 0-2.11.39-2.885 1.165-.78.78-1.172 1.744-1.172 2.893v15.943c0 1.149.388 2.11 1.163 2.885.78.78 1.745 1.172 2.894 1.172h7.649c1.148 0 2.11-.388 2.884-1.163.78-.78 1.17-1.745 1.17-2.894v-15.943c0-1.15-.386-2.111-1.16-2.885-.78-.78-1.746-1.172-2.894-1.172zm.553 4.518h6.545v14.93H25.59z"></path>
|
|
131
|
+
</symbol>
|
|
132
|
+
<symbol viewBox="0 96 48 48" id="vjs-icon-forward-5">
|
|
133
|
+
<path d="M29.508 97l-2.431 2.43 4.625 4.625h-1.364c-2.965 0-5.742.554-8.332 1.66-2.589 1.107-4.851 2.629-6.788 4.566-1.937 1.937-3.458 4.2-4.565 6.788-1.107 2.59-1.66 5.367-1.66 8.331h3.557c0-4.957 1.68-9.16 5.04-12.611 3.36-3.45 7.51-5.177 12.451-5.177h1.304l-4.326 4.33 2.49 2.49 8.715-8.716zm-9.783 21.61v13.89h11.382v5.018H19.725V142h12.727a2.93 2.93 0 0 0 2.15-.896 2.93 2.93 0 0 0 .896-2.15v-7.798c0-.837-.299-1.554-.896-2.152a2.93 2.93 0 0 0-2.15-.896h-8.245V123h11.29v-4.392z"></path>
|
|
134
|
+
</symbol>
|
|
135
|
+
<symbol viewBox="0 96 48 48" id="vjs-icon-forward-10">
|
|
136
|
+
<path d="M23.119 97l-2.386 2.383 4.538 4.538h-1.339c-2.908 0-5.633.543-8.173 1.63-2.54 1.085-4.76 2.577-6.66 4.478-1.9 1.9-3.392 4.12-4.478 6.66-1.085 2.54-1.629 5.264-1.629 8.172h3.49c0-4.863 1.648-8.986 4.944-12.372 3.297-3.385 7.368-5.078 12.216-5.078h1.279l-4.245 4.247 2.443 2.442 8.55-8.55zm-9.52 21.45v4.42h4.871V142h4.513v-23.55zm18.136 0c-1.125 0-2.066.377-2.824 1.135-.764.764-1.148 1.709-1.148 2.834v15.612c0 1.124.38 2.066 1.139 2.824.764.764 1.708 1.145 2.833 1.145h7.489c1.125 0 2.066-.378 2.824-1.136.764-.764 1.145-1.709 1.145-2.833v-15.612c0-1.125-.378-2.067-1.136-2.825-.764-.764-1.708-1.145-2.833-1.145zm.54 4.42h6.408v14.617h-6.407z"></path>
|
|
137
|
+
</symbol>
|
|
138
|
+
<symbol viewBox="0 96 48 48" id="vjs-icon-forward-30">
|
|
139
|
+
<path d="M25.549 97l-2.437 2.434 4.634 4.635H26.38c-2.97 0-5.753.555-8.347 1.664-2.594 1.109-4.861 2.633-6.802 4.574-1.94 1.94-3.465 4.207-4.574 6.802-1.109 2.594-1.664 5.377-1.664 8.347h3.565c0-4.967 1.683-9.178 5.05-12.636 3.366-3.458 7.525-5.187 12.475-5.187h1.307l-4.335 4.338 2.495 2.494 8.732-8.732zm-11.553 20.53v4.689h10.297v5.249h-6.978v4.688h6.978v5.156H13.996V142h10.808c1.06 0 1.948-.395 2.666-1.186.718-.79 1.077-1.771 1.077-2.94v-16.217c0-1.169-.36-2.15-1.077-2.94-.718-.79-1.605-1.186-2.666-1.186zm21.174.168c-1.149 0-2.11.389-2.884 1.163-.78.78-1.172 1.745-1.172 2.894v15.942c0 1.15.388 2.11 1.162 2.885.78.78 1.745 1.17 2.894 1.17h7.649c1.149 0 2.11-.386 2.885-1.16.78-.78 1.17-1.746 1.17-2.895v-15.942c0-1.15-.387-2.11-1.161-2.885-.78-.78-1.745-1.172-2.894-1.172zm.552 4.516h6.542v14.931h-6.542z"></path>
|
|
140
|
+
</symbol>
|
|
141
|
+
<symbol viewBox="0 0 512 512" id="vjs-icon-audio-description">
|
|
142
|
+
<g fill-rule="evenodd"><path d="M227.29 381.351V162.993c50.38-1.017 89.108-3.028 117.631 17.126 27.374 19.342 48.734 56.965 44.89 105.325-4.067 51.155-41.335 94.139-89.776 98.475-24.085 2.155-71.972 0-71.972 0s-.84-1.352-.773-2.568m48.755-54.804c31.43 1.26 53.208-16.633 56.495-45.386 4.403-38.51-21.188-63.552-58.041-60.796v103.612c-.036 1.466.575 2.22 1.546 2.57"></path><path d="M383.78 381.328c13.336 3.71 17.387-11.06 23.215-21.408 12.722-22.571 22.294-51.594 22.445-84.774.221-47.594-18.343-82.517-35.6-106.182h-8.51c-.587 3.874 2.226 7.315 3.865 10.276 13.166 23.762 25.367 56.553 25.54 94.194.2 43.176-14.162 79.278-30.955 107.894"></path><path d="M425.154 381.328c13.336 3.71 17.384-11.061 23.215-21.408 12.721-22.571 22.291-51.594 22.445-84.774.221-47.594-18.343-82.517-35.6-106.182h-8.511c-.586 3.874 2.226 7.315 3.866 10.276 13.166 23.762 25.367 56.553 25.54 94.194.2 43.176-14.162 79.278-30.955 107.894"></path><path d="M466.26 381.328c13.337 3.71 17.385-11.061 23.216-21.408 12.722-22.571 22.292-51.594 22.445-84.774.221-47.594-18.343-82.517-35.6-106.182h-8.51c-.587 3.874 2.225 7.315 3.865 10.276 13.166 23.762 25.367 56.553 25.54 94.194.2 43.176-14.162 79.278-30.955 107.894M4.477 383.005H72.58l18.573-28.484 64.169-.135s.065 19.413.065 28.62h48.756V160.307h-58.816c-5.653 9.537-140.85 222.697-140.85 222.697zm152.667-145.282v71.158l-40.453-.27 40.453-70.888z"></path></g>
|
|
143
|
+
</symbol>
|
|
144
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-next-item">
|
|
145
|
+
<path d="M12 36l17-12-17-12v24zm20-24v24h4V12h-4z"></path>
|
|
146
|
+
</symbol>
|
|
147
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-previous-item">
|
|
148
|
+
<path d="M12 12h4v24h-4zm7 12l17 12V12z"></path>
|
|
149
|
+
</symbol>
|
|
150
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-shuffle">
|
|
151
|
+
<path d="M21.17 18.34L10.83 8 8 10.83l10.34 10.34 2.83-2.83zM29 8l4.09 4.09L8 37.17 10.83 40l25.09-25.09L40 19V8H29zm.66 18.83l-2.83 2.83 6.26 6.26L29 40h11V29l-4.09 4.09-6.25-6.26z"></path>
|
|
152
|
+
</symbol>
|
|
153
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-cast">
|
|
154
|
+
<path d="M42 6H6c-2.21 0-4 1.79-4 4v6h4v-6h36v28H28v4h14c2.21 0 4-1.79 4-4V10c0-2.21-1.79-4-4-4zM2 36v6h6c0-3.31-2.69-6-6-6zm0-8v4c5.52 0 10 4.48 10 10h4c0-7.73-6.27-14-14-14zm0-8v4c9.94 0 18 8.06 18 18h4c0-12.15-9.85-22-22-22z"></path>
|
|
155
|
+
</symbol>
|
|
156
|
+
<symbol viewBox="0 0 48 48" id="vjs-icon-picture-in-picture-enter">
|
|
157
|
+
<path d="M38 22H22v11.99h16V22zm8 16V9.96C46 7.76 44.2 6 42 6H6C3.8 6 2 7.76 2 9.96V38c0 2.2 1.8 4 4 4h36c2.2 0 4-1.8 4-4zm-4 .04H6V9.94h36v28.1z"></path>
|
|
158
|
+
</symbol>
|
|
159
|
+
<symbol viewBox="0 0 22 18" id="vjs-icon-picture-in-picture-exit">
|
|
160
|
+
<path d="M18 4H4v10h14V4zm4 12V1.98C22 .88 21.1 0 20 0H2C.9 0 0 .88 0 1.98V16c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2zm-2 .02H2V1.97h18v14.05z"></path>
|
|
161
|
+
<path fill="none" d="M-1-3h24v24H-1z"></path>
|
|
162
|
+
</symbol>
|
|
163
|
+
<symbol viewBox="0 0 1792 1792" id="vjs-icon-facebook">
|
|
164
|
+
<path d="M1343 12v264h-157q-86 0-116 36t-30 108v189h293l-39 296h-254v759H734V905H479V609h255V391q0-186 104-288.5T1115 0q147 0 228 12z"></path>
|
|
165
|
+
</symbol>
|
|
166
|
+
<symbol viewBox="0 0 1792 1792" id="vjs-icon-linkedin">
|
|
167
|
+
<path d="M477 625v991H147V625h330zm21-306q1 73-50.5 122T312 490h-2q-82 0-132-49t-50-122q0-74 51.5-122.5T314 148t133 48.5T498 319zm1166 729v568h-329v-530q0-105-40.5-164.5T1168 862q-63 0-105.5 34.5T999 982q-11 30-11 81v553H659q2-399 2-647t-1-296l-1-48h329v144h-2q20-32 41-56t56.5-52 87-43.5T1285 602q171 0 275 113.5t104 332.5z"></path>
|
|
168
|
+
</symbol>
|
|
169
|
+
<symbol viewBox="0 0 1200 1227" id="vjs-icon-twitter">
|
|
170
|
+
<path d="M714.163 519.284L1160.89 0H1055.03L667.137 450.887L357.328 0H0L468.492 681.821L0 1226.37H105.866L515.491 750.218L842.672 1226.37H1200L714.137 519.284H714.163ZM569.165 687.828L521.697 619.934L144.011 79.6944H306.615L611.412 515.685L658.88 583.579L1055.08 1150.3H892.476L569.165 687.854V687.828Z"/>
|
|
171
|
+
</symbol>
|
|
172
|
+
<symbol viewBox="0 0 1792 1792" id="vjs-icon-tumblr">
|
|
173
|
+
<path d="M1328 1329l80 237q-23 35-111 66t-177 32q-104 2-190.5-26T787 1564t-95-106-55.5-120-16.5-118V676H452V461q72-26 129-69.5t91-90 58-102 34-99T779 12q1-5 4.5-8.5T791 0h244v424h333v252h-334v518q0 30 6.5 56t22.5 52.5 49.5 41.5 81.5 14q78-2 134-29z"></path>
|
|
174
|
+
</symbol>
|
|
175
|
+
<symbol viewBox="0 0 1792 1792" id="vjs-icon-pinterest">
|
|
176
|
+
<path d="M1664 896q0 209-103 385.5T1281.5 1561 896 1664q-111 0-218-32 59-93 78-164 9-34 54-211 20 39 73 67.5t114 28.5q121 0 216-68.5t147-188.5 52-270q0-114-59.5-214T1180 449t-255-63q-105 0-196 29t-154.5 77-109 110.5-67 129.5T377 866q0 104 40 183t117 111q30 12 38-20 2-7 8-31t8-30q6-23-11-43-51-61-51-151 0-151 104.5-259.5T904 517q151 0 235.5 82t84.5 213q0 170-68.5 289T980 1220q-61 0-98-43.5T859 1072q8-35 26.5-93.5t30-103T927 800q0-50-27-83t-77-33q-62 0-105 57t-43 142q0 73 25 122l-99 418q-17 70-13 177-206-91-333-281T128 896q0-209 103-385.5T510.5 231 896 128t385.5 103T1561 510.5 1664 896z"></path>
|
|
177
|
+
</symbol>
|
|
178
|
+
</defs>
|
|
179
|
+
</svg>`;const bd=la?10009:ua?461:8,Hn={codes:{play:415,pause:19,ff:417,rw:412,back:bd},names:{415:"play",19:"pause",417:"ff",412:"rw",[bd]:"back"},isEventKey(s,e){return e=e.toLowerCase(),!!(this.names[s.keyCode]&&this.names[s.keyCode]===e)},getEventName(s){if(this.names[s.keyCode])return this.names[s.keyCode];if(this.codes[s.code]){const e=this.codes[s.code];return this.names[e]}return null}},xd=5;class sx extends pi{constructor(e){super(),this.player_=e,this.focusableComponents=[],this.isListening_=!1,this.isPaused_=!1,this.onKeyDown_=this.onKeyDown_.bind(this),this.lastFocusedComponent_=null}start(){this.isListening_||(this.player_.on("keydown",this.onKeyDown_),this.player_.on("modalKeydown",this.onKeyDown_),this.player_.on("loadedmetadata",()=>{this.focus(this.updateFocusableComponents()[0])}),this.player_.on("modalclose",()=>{this.refocusComponent()}),this.player_.on("focusin",this.handlePlayerFocus_.bind(this)),this.player_.on("focusout",this.handlePlayerBlur_.bind(this)),this.isListening_=!0,this.player_.errorDisplay&&this.player_.errorDisplay.on("aftermodalfill",()=>{this.updateFocusableComponents(),this.focusableComponents.length&&(this.focusableComponents.length>1?this.focusableComponents[1].focus():this.focusableComponents[0].focus())}))}stop(){this.player_.off("keydown",this.onKeyDown_),this.isListening_=!1}onKeyDown_(e){const i=e.originalEvent?e.originalEvent:e;if(["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(i.key)){if(this.isPaused_)return;i.preventDefault();const r=i.key.substring(5).toLowerCase();this.move(r)}else if(Hn.isEventKey(i,"play")||Hn.isEventKey(i,"pause")||Hn.isEventKey(i,"ff")||Hn.isEventKey(i,"rw")){i.preventDefault();const r=Hn.getEventName(i);this.performMediaAction_(r)}else Hn.isEventKey(i,"Back")&&e.target&&typeof e.target.closeable=="function"&&e.target.closeable()&&(i.preventDefault(),e.target.close())}performMediaAction_(e){if(this.player_)switch(e){case"play":this.player_.paused()&&this.player_.play();break;case"pause":this.player_.paused()||this.player_.pause();break;case"ff":this.userSeek_(this.player_.currentTime()+xd);break;case"rw":this.userSeek_(this.player_.currentTime()-xd);break}}userSeek_(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&this.player_.liveTracker.nextSeekedFromUser(),this.player_.currentTime(e)}pause(){this.isPaused_=!0}resume(){this.isPaused_=!1}handlePlayerBlur_(e){const i=e.relatedTarget;let r=null;const a=this.getCurrentComponent(e.target);i&&(r=!!i.closest(".video-js"),i.classList.contains("vjs-text-track-settings")&&!this.isPaused_&&this.searchForTrackSelect_()),(!e.currentTarget.contains(e.relatedTarget)&&!r||!i)&&(a&&a.name()==="CloseButton"?this.refocusComponent():(this.pause(),a&&a.el()&&(this.lastFocusedComponent_=a)))}handlePlayerFocus_(){this.getCurrentComponent()&&this.getCurrentComponent().getIsFocusable()&&this.resume()}updateFocusableComponents(){const e=this.player_,i=[];function r(a){for(const o of a)o.hasOwnProperty("el_")&&o.getIsFocusable()&&o.getIsAvailableToBeFocused(o.el())&&i.push(o),o.hasOwnProperty("children_")&&o.children_.length>0&&r(o.children_)}return e.children_.forEach(a=>{if(a.hasOwnProperty("el_"))if(a.getIsFocusable&&a.getIsAvailableToBeFocused&&a.getIsFocusable()&&a.getIsAvailableToBeFocused(a.el())){i.push(a);return}else a.hasOwnProperty("children_")&&a.children_.length>0?r(a.children_):a.hasOwnProperty("items")&&a.items.length>0?r(a.items):this.findSuitableDOMChild(a)&&i.push(a);if(a.name_==="ErrorDisplay"&&a.opened_){const o=a.el_.querySelector(".vjs-errors-ok-button-container");o&&o.querySelectorAll("button").forEach((u,d)=>{i.push({name:()=>"ModalButton"+(d+1),el:()=>u,getPositions:()=>{const f=u.getBoundingClientRect(),g={x:f.x,y:f.y,width:f.width,height:f.height,top:f.top,right:f.right,bottom:f.bottom,left:f.left},y={x:f.left+f.width/2,y:f.top+f.height/2,width:0,height:0,top:f.top+f.height/2,right:f.left+f.width/2,bottom:f.top+f.height/2,left:f.left+f.width/2};return{boundingClientRect:g,center:y}},getIsAvailableToBeFocused:()=>!0,getIsFocusable:f=>!0,focus:()=>u.focus()})})}}),this.focusableComponents=i,this.focusableComponents}findSuitableDOMChild(e){function i(r){if(e.getIsFocusable(r)&&e.getIsAvailableToBeFocused(r))return r;for(let a=0;a<r.children.length;a++){const o=r.children[a],l=i(o);if(l)return l}return null}return e.el()?i(e.el()):null}getCurrentComponent(e){this.updateFocusableComponents();const i=e||document.activeElement;if(this.focusableComponents.length){for(const r of this.focusableComponents)if(r.el()===i)return r}}add(e){const i=[...this.focusableComponents];e.hasOwnProperty("el_")&&e.getIsFocusable()&&e.getIsAvailableToBeFocused(e.el())&&i.push(e),this.focusableComponents=i,this.trigger({type:"focusableComponentsChanged",focusableComponents:this.focusableComponents})}remove(e){for(let i=0;i<this.focusableComponents.length;i++)if(this.focusableComponents[i].name()===e.name()){this.focusableComponents.splice(i,1),this.trigger({type:"focusableComponentsChanged",focusableComponents:this.focusableComponents});return}}clear(){this.focusableComponents.length>0&&(this.focusableComponents=[],this.trigger({type:"focusableComponentsChanged",focusableComponents:this.focusableComponents}))}move(e){const i=this.getCurrentComponent();if(!i)return;const r=i.getPositions(),a=this.focusableComponents.filter(l=>l!==i&&this.isInDirection_(r.boundingClientRect,l.getPositions().boundingClientRect,e)),o=this.findBestCandidate_(r.center,a,e);o?this.focus(o):this.trigger({type:"endOfFocusableComponents",direction:e,focusedComponent:i})}findBestCandidate_(e,i,r){let a=1/0,o=null;for(const l of i){const u=l.getPositions().center,d=this.calculateDistance_(e,u,r);d<a&&(a=d,o=l)}return o}isInDirection_(e,i,r){switch(r){case"right":return i.left>=e.right;case"left":return i.right<=e.left;case"down":return i.top>=e.bottom;case"up":return i.bottom<=e.top;default:return!1}}refocusComponent(){if(this.lastFocusedComponent_){this.player_.userActive()||this.player_.userActive(!0),this.updateFocusableComponents();for(let e=0;e<this.focusableComponents.length;e++)if(this.focusableComponents[e].name()===this.lastFocusedComponent_.name()){this.focus(this.focusableComponents[e]);return}}else this.focus(this.updateFocusableComponents()[0])}focus(e){typeof e=="object"&&(e.getIsAvailableToBeFocused(e.el())?e.focus():this.findSuitableDOMChild(e)&&this.findSuitableDOMChild(e).focus())}calculateDistance_(e,i,r){const a=Math.abs(e.x-i.x),o=Math.abs(e.y-i.y);let l;switch(r){case"right":case"left":l=a+o*100;break;case"up":l=o*2+a*.5;break;case"down":l=o*5+a;break;default:l=a+o}return l}searchForTrackSelect_(){const e=this;for(const i of e.updateFocusableComponents())if(i.constructor.name==="TextTrackSelect"){e.focus(i);break}}}class ax extends oe{constructor(e,i,r){const a=rt({createEl:!1},i);if(super(e,a,r),!i.playerOptions.sources||i.playerOptions.sources.length===0)for(let o=0,l=i.playerOptions.techOrder;o<l.length;o++){const u=gt(l[o]);let d=Re.getTech(u);if(u||(d=oe.getComponent(u)),d&&d.isSupported()){e.loadTech_(u);break}}else e.src(i.playerOptions.sources)}}oe.registerComponent("MediaLoader",ax);class qa extends oe{constructor(e,i){super(e,i),this.options_.controlText&&this.controlText(this.options_.controlText),this.handleMouseOver_=r=>this.handleMouseOver(r),this.handleMouseOut_=r=>this.handleMouseOut(r),this.handleClick_=r=>this.handleClick(r),this.handleKeyDown_=r=>this.handleKeyDown(r),this.emitTapEvents(),this.enable()}createEl(e="div",i={},r={}){i=Object.assign({className:this.buildCSSClass(),tabIndex:0},i),e==="button"&&Ge.error(`Creating a ClickableComponent with an HTML element of ${e} is not supported; use a Button instead.`),r=Object.assign({role:"button"},r),this.tabIndex_=i.tabIndex;const a=Be(e,i,r);return this.player_.options_.experimentalSvgIcons||a.appendChild(Be("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),this.createControlTextEl(a),a}dispose(){this.controlTextEl_=null,super.dispose()}createControlTextEl(e){return this.controlTextEl_=Be("span",{className:"vjs-control-text"},{"aria-live":"polite"}),e&&e.appendChild(this.controlTextEl_),this.controlText(this.controlText_,e),this.controlTextEl_}controlText(e,i=this.el()){if(e===void 0)return this.controlText_||"Need Text";const r=this.localize(e);this.controlText_=e,vn(this.controlTextEl_,r),!this.nonIconControl&&!this.player_.options_.noUITitleAttributes&&i.setAttribute("title",r)}buildCSSClass(){return`vjs-control vjs-button ${super.buildCSSClass()}`}enable(){this.enabled_||(this.enabled_=!0,this.removeClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","false"),typeof this.tabIndex_<"u"&&this.el_.setAttribute("tabIndex",this.tabIndex_),this.on(["tap","click"],this.handleClick_),this.on("keydown",this.handleKeyDown_))}disable(){this.enabled_=!1,this.addClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","true"),typeof this.tabIndex_<"u"&&this.el_.removeAttribute("tabIndex"),this.off("mouseover",this.handleMouseOver_),this.off("mouseout",this.handleMouseOut_),this.off(["tap","click"],this.handleClick_),this.off("keydown",this.handleKeyDown_)}handleLanguagechange(){this.controlText(this.controlText_)}handleClick(e){this.options_.clickHandler&&this.options_.clickHandler.call(this,arguments)}handleKeyDown(e){e.key===" "||e.key==="Enter"?(e.preventDefault(),e.stopPropagation(),this.trigger("click")):super.handleKeyDown(e)}}oe.registerComponent("ClickableComponent",qa);class hl extends qa{constructor(e,i){super(e,i),this.update(),this.update_=r=>this.update(r),e.on("posterchange",this.update_)}dispose(){this.player().off("posterchange",this.update_),super.dispose()}createEl(){return Be("div",{className:"vjs-poster"})}crossOrigin(e){if(typeof e>"u")return this.$("img")?this.$("img").crossOrigin:this.player_.tech_&&this.player_.tech_.isReady_?this.player_.crossOrigin():this.player_.options_.crossOrigin||this.player_.options_.crossorigin||null;if(e!==null&&e!=="anonymous"&&e!=="use-credentials"){this.player_.log.warn(`crossOrigin must be null, "anonymous" or "use-credentials", given "${e}"`);return}this.$("img")&&(this.$("img").crossOrigin=e)}update(e){const i=this.player().poster();this.setSrc(i),i?this.show():this.hide()}setSrc(e){if(!e){this.el_.textContent="";return}this.$("img")||this.el_.appendChild(Be("picture",{className:"vjs-poster",tabIndex:-1},{},Be("img",{loading:"lazy",crossOrigin:this.crossOrigin()},{alt:""}))),this.$("img").src=e}handleClick(e){this.player_.controls()&&(this.player_.tech(!0)&&this.player_.tech(!0).focus(),this.player_.paused()?Ui(this.player_.play()):this.player_.pause())}}hl.prototype.crossorigin=hl.prototype.crossOrigin;oe.registerComponent("PosterImage",hl);const mi="#222",Cd="#ccc",ox={monospace:"monospace",sansSerif:"sans-serif",serif:"serif",monospaceSansSerif:'"Andale Mono", "Lucida Console", monospace',monospaceSerif:'"Courier New", monospace',proportionalSansSerif:"sans-serif",proportionalSerif:"serif",casual:'"Comic Sans MS", Impact, fantasy',script:'"Monotype Corsiva", cursive',smallcaps:'"Andale Mono", "Lucida Console", monospace, sans-serif'};function $o(s,e){let i;if(s.length===4)i=s[1]+s[1]+s[2]+s[2]+s[3]+s[3];else if(s.length===7)i=s.slice(1);else throw new Error("Invalid color code provided, "+s+"; must be formatted as e.g. #f0e or #f604e2.");return"rgba("+parseInt(i.slice(0,2),16)+","+parseInt(i.slice(2,4),16)+","+parseInt(i.slice(4,6),16)+","+e+")"}function Vi(s,e,i){try{s.style[e]=i}catch{return}}function Sd(s){return s?`${s}px`:""}class lx extends oe{constructor(e,i,r){super(e,i,r);const a=l=>this.updateDisplay(l),o=l=>{this.updateDisplayOverlay(),this.updateDisplay(l)};e.on("loadstart",l=>this.toggleDisplay(l)),e.on("useractive",a),e.on("userinactive",a),e.on("texttrackchange",a),e.on("loadedmetadata",l=>{this.updateDisplayOverlay(),this.preselectTrack(l)}),e.ready(lt(this,function(){if(e.tech_&&e.tech_.featuresNativeTextTracks){this.hide();return}e.on("fullscreenchange",o),e.on("playerresize",o);const l=W.screen.orientation||W,u=W.screen.orientation?"change":"orientationchange";l.addEventListener(u,o),e.on("dispose",()=>l.removeEventListener(u,o));const d=this.options_.playerOptions.tracks||[];for(let f=0;f<d.length;f++)this.player_.addRemoteTextTrack(d[f],!0);this.preselectTrack()}))}preselectTrack(){const e={captions:1,subtitles:1},i=this.player_.textTracks(),r=this.player_.cache_.selectedLanguage;let a,o,l;for(let u=0;u<i.length;u++){const d=i[u];r&&r.enabled&&r.language&&r.language===d.language&&d.kind in e?d.kind===r.kind?l=d:l||(l=d):r&&!r.enabled?(l=null,a=null,o=null):d.default&&(d.kind==="descriptions"&&!a?a=d:d.kind in e&&!o&&(o=d))}l?l.mode="showing":o?o.mode="showing":a&&(a.mode="showing")}toggleDisplay(){this.player_.tech_&&this.player_.tech_.featuresNativeTextTracks?this.hide():this.show()}createEl(){return super.createEl("div",{className:"vjs-text-track-display"},{translate:"yes","aria-live":"off","aria-atomic":"true"})}clearDisplay(){typeof W.WebVTT=="function"&&W.WebVTT.processCues(W,[],this.el_)}updateDisplay(){const e=this.player_.textTracks(),i=this.options_.allowMultipleShowingTracks;if(this.clearDisplay(),i){const l=[];for(let u=0;u<e.length;++u){const d=e[u];d.mode==="showing"&&l.push(d)}this.updateForTrack(l);return}let r=null,a=null,o=e.length;for(;o--;){const l=e[o];l.mode==="showing"&&(l.kind==="descriptions"?r=l:a=l)}if(a?(this.getAttribute("aria-live")!=="off"&&this.setAttribute("aria-live","off"),this.updateForTrack(a)):r&&(this.getAttribute("aria-live")!=="assertive"&&this.setAttribute("aria-live","assertive"),this.updateForTrack(r)),!(W.CSS!==void 0&&W.CSS.supports("inset","10px"))){const l=this.el_,u=l.querySelectorAll(".vjs-text-track-cue"),d=this.player_.controlBar.el_.getBoundingClientRect().height,f=this.player_.el_.getBoundingClientRect().height;l.style="",Vi(l,"position","relative"),Vi(l,"height",f-d+"px"),Vi(l,"top","unset"),ca?Vi(l,"bottom",f+"px"):Vi(l,"bottom","0px"),u.length>0&&u.forEach(g=>{if(g.style.inset){const y=g.style.inset.split(" ");y.length===3&&Object.assign(g.style,{top:y[0],right:y[1],bottom:y[2],left:"unset"})}})}}updateDisplayOverlay(){if(!this.player_.videoHeight()||!(W.CSS!==void 0&&W.CSS.supports("inset-inline: 10px")))return;const e=this.player_.currentWidth(),i=this.player_.currentHeight(),r=e/i,a=this.player_.videoWidth()/this.player_.videoHeight();let o=0,l=0;Math.abs(r-a)>.1&&(r>a?o=Math.round((e-i*a)/2):l=Math.round((i-e/a)/2)),Vi(this.el_,"insetInline",Sd(o)),Vi(this.el_,"insetBlock",Sd(l))}updateDisplayState(e){const i=this.player_.textTrackSettings.getValues(),r=e.activeCues;let a=r.length;for(;a--;){const o=r[a];if(!o)continue;const l=o.displayState;if(i.color&&(l.firstChild.style.color=i.color),i.textOpacity&&Vi(l.firstChild,"color",$o(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(l.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&Vi(l.firstChild,"backgroundColor",$o(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?Vi(l,"backgroundColor",$o(i.windowColor,i.windowOpacity)):l.style.backgroundColor=i.windowColor),i.edgeStyle&&(i.edgeStyle==="dropshadow"?l.firstChild.style.textShadow=`2px 2px 3px ${mi}, 2px 2px 4px ${mi}, 2px 2px 5px ${mi}`:i.edgeStyle==="raised"?l.firstChild.style.textShadow=`1px 1px ${mi}, 2px 2px ${mi}, 3px 3px ${mi}`:i.edgeStyle==="depressed"?l.firstChild.style.textShadow=`1px 1px ${Cd}, 0 1px ${Cd}, -1px -1px ${mi}, 0 -1px ${mi}`:i.edgeStyle==="uniform"&&(l.firstChild.style.textShadow=`0 0 4px ${mi}, 0 0 4px ${mi}, 0 0 4px ${mi}, 0 0 4px ${mi}`)),i.fontPercent&&i.fontPercent!==1){const u=W.parseFloat(l.style.fontSize);l.style.fontSize=u*i.fontPercent+"px",l.style.height="auto",l.style.top="auto"}i.fontFamily&&i.fontFamily!=="default"&&(i.fontFamily==="small-caps"?l.firstChild.style.fontVariant="small-caps":l.firstChild.style.fontFamily=ox[i.fontFamily])}}updateForTrack(e){if(Array.isArray(e)||(e=[e]),typeof W.WebVTT!="function"||e.every(r=>!r.activeCues))return;const i=[];for(let r=0;r<e.length;++r){const a=e[r];for(let o=0;o<a.activeCues.length;++o)i.push(a.activeCues[o])}W.WebVTT.processCues(W,i,this.el_);for(let r=0;r<e.length;++r){const a=e[r];for(let o=0;o<a.activeCues.length;++o){const l=a.activeCues[o].displayState;On(l,"vjs-text-track-cue","vjs-text-track-cue-"+(a.language?a.language:r)),a.language&&cr(l,"lang",a.language)}this.player_.textTrackSettings&&this.updateDisplayState(a)}}}oe.registerComponent("TextTrackDisplay",lx);class ux extends oe{createEl(){const e=this.player_.isAudio(),i=this.localize(e?"Audio Player":"Video Player"),r=Be("span",{className:"vjs-control-text",textContent:this.localize("{1} is loading.",[i])}),a=super.createEl("div",{className:"vjs-loading-spinner",dir:"ltr"});return a.appendChild(r),a}handleLanguagechange(){this.$(".vjs-control-text").textContent=this.localize("{1} is loading.",[this.player_.isAudio()?"Audio Player":"Video Player"])}}oe.registerComponent("LoadingSpinner",ux);class qt extends qa{createEl(e,i={},r={}){e="button",i=Object.assign({className:this.buildCSSClass()},i),r=Object.assign({type:"button"},r);const a=Be(e,i,r);return this.player_.options_.experimentalSvgIcons||a.appendChild(Be("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),this.createControlTextEl(a),a}addChild(e,i={}){const r=this.constructor.name;return Ge.warn(`Adding an actionable (user controllable) child to a Button (${r}) is not supported; use a ClickableComponent instead.`),oe.prototype.addChild.call(this,e,i)}enable(){super.enable(),this.el_.removeAttribute("disabled")}disable(){super.disable(),this.el_.setAttribute("disabled","disabled")}handleKeyDown(e){if(e.key===" "||e.key==="Enter"){e.stopPropagation();return}super.handleKeyDown(e)}}oe.registerComponent("Button",qt);class N0 extends qt{constructor(e,i){super(e,i),this.mouseused_=!1,this.setIcon("play"),this.on("mousedown",r=>this.handleMouseDown(r))}buildCSSClass(){return"vjs-big-play-button"}handleClick(e){const i=this.player_.play();if(e.type==="tap"||this.mouseused_&&"clientX"in e&&"clientY"in e){Ui(i),this.player_.tech(!0)&&this.player_.tech(!0).focus();return}const r=this.player_.getChild("controlBar"),a=r&&r.getChild("playToggle");if(!a){this.player_.tech(!0).focus();return}const o=()=>a.focus();Jr(i)?i.then(o,()=>{}):this.setTimeout(o,1)}handleKeyDown(e){this.mouseused_=!1,super.handleKeyDown(e)}handleMouseDown(e){this.mouseused_=!0}}N0.prototype.controlText_="Play Video";oe.registerComponent("BigPlayButton",N0);class cx extends qt{constructor(e,i){super(e,i),this.setIcon("cancel"),this.controlText(i&&i.controlText||this.localize("Close"))}buildCSSClass(){return`vjs-close-button ${super.buildCSSClass()}`}handleClick(e){this.trigger({type:"close",bubbles:!1})}handleKeyDown(e){e.key==="Escape"?(e.preventDefault(),e.stopPropagation(),this.trigger("click")):super.handleKeyDown(e)}}oe.registerComponent("CloseButton",cx);class O0 extends qt{constructor(e,i={}){super(e,i),i.replay=i.replay===void 0||i.replay,this.setIcon("play"),this.on(e,"play",r=>this.handlePlay(r)),this.on(e,"pause",r=>this.handlePause(r)),i.replay&&this.on(e,"ended",r=>this.handleEnded(r))}buildCSSClass(){return`vjs-play-control ${super.buildCSSClass()}`}handleClick(e){this.player_.paused()?Ui(this.player_.play()):this.player_.pause()}handleSeeked(e){this.removeClass("vjs-ended"),this.player_.paused()?this.handlePause(e):this.handlePlay(e)}handlePlay(e){this.removeClass("vjs-ended","vjs-paused"),this.addClass("vjs-playing"),this.setIcon("pause"),this.controlText("Pause")}handlePause(e){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.setIcon("play"),this.controlText("Play")}handleEnded(e){this.removeClass("vjs-playing"),this.addClass("vjs-ended"),this.setIcon("replay"),this.controlText("Replay"),this.one(this.player_,"seeked",i=>this.handleSeeked(i))}}O0.prototype.controlText_="Play";oe.registerComponent("PlayToggle",O0);class vr extends oe{constructor(e,i){super(e,i),this.on(e,["timeupdate","ended","seeking"],r=>this.update(r)),this.updateTextNode_()}createEl(){const e=this.buildCSSClass(),i=super.createEl("div",{className:`${e} vjs-time-control vjs-control`}),r=Be("span",{className:"vjs-control-text",textContent:`${this.localize(this.labelText_)} `},{role:"presentation"});return i.appendChild(r),this.contentEl_=Be("span",{className:`${e}-display`},{role:"presentation"}),i.appendChild(this.contentEl_),i}dispose(){this.contentEl_=null,this.textNode_=null,super.dispose()}update(e){!this.player_.options_.enableSmoothSeeking&&e.type==="seeking"||this.updateContent(e)}updateTextNode_(e=0){e=Rn(e),this.formattedTime_!==e&&(this.formattedTime_=e,this.requestNamedAnimationFrame("TimeDisplay#updateTextNode_",()=>{if(!this.contentEl_)return;let i=this.textNode_;i&&this.contentEl_.firstChild!==i&&(i=null,Ge.warn("TimeDisplay#updateTextnode_: Prevented replacement of text node element since it was no longer a child of this node. Appending a new node instead.")),this.textNode_=pe.createTextNode(this.formattedTime_),this.textNode_&&(i?this.contentEl_.replaceChild(this.textNode_,i):this.contentEl_.appendChild(this.textNode_))}))}updateContent(e){}}vr.prototype.labelText_="Time";vr.prototype.controlText_="Time";oe.registerComponent("TimeDisplay",vr);class Xl extends vr{buildCSSClass(){return"vjs-current-time"}updateContent(e){let i;this.player_.ended()?i=this.player_.duration():e&&e.target&&typeof e.target.pendingSeekTime=="function"&&e.target.pendingSeekTime()!==null?i=e.target.pendingSeekTime():i=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime(),this.updateTextNode_(i)}}Xl.prototype.labelText_="Current Time";Xl.prototype.controlText_="Current Time";oe.registerComponent("CurrentTimeDisplay",Xl);class Kl extends vr{constructor(e,i){super(e,i);const r=a=>this.updateContent(a);this.on(e,"durationchange",r),this.on(e,"loadstart",r),this.on(e,"loadedmetadata",r)}buildCSSClass(){return"vjs-duration"}updateContent(e){const i=this.player_.duration();this.updateTextNode_(i)}}Kl.prototype.labelText_="Duration";Kl.prototype.controlText_="Duration";oe.registerComponent("DurationDisplay",Kl);class dx extends oe{createEl(){const e=super.createEl("div",{className:"vjs-time-control vjs-time-divider"},{"aria-hidden":!0}),i=super.createEl("div"),r=super.createEl("span",{textContent:"/"});return i.appendChild(r),e.appendChild(i),e}}oe.registerComponent("TimeDivider",dx);class Ql extends vr{constructor(e,i){super(e,i),this.on(e,"durationchange",r=>this.updateContent(r))}buildCSSClass(){return"vjs-remaining-time"}createEl(){const e=super.createEl();return this.options_.displayNegative!==!1&&e.insertBefore(Be("span",{},{"aria-hidden":!0},"-"),this.contentEl_),e}updateContent(e){if(typeof this.player_.duration()!="number")return;let i;this.player_.ended()?i=0:this.player_.remainingTimeDisplay?i=this.player_.remainingTimeDisplay():i=this.player_.remainingTime(),this.updateTextNode_(i)}}Ql.prototype.labelText_="Remaining Time";Ql.prototype.controlText_="Remaining Time";oe.registerComponent("RemainingTimeDisplay",Ql);class hx extends oe{constructor(e,i){super(e,i),this.updateShowing(),this.on(this.player(),"durationchange",r=>this.updateShowing(r))}createEl(){const e=super.createEl("div",{className:"vjs-live-control vjs-control"});return this.contentEl_=Be("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.contentEl_.appendChild(Be("span",{className:"vjs-control-text",textContent:`${this.localize("Stream Type")} `})),this.contentEl_.appendChild(pe.createTextNode(this.localize("LIVE"))),e.appendChild(this.contentEl_),e}dispose(){this.contentEl_=null,super.dispose()}updateShowing(e){this.player().duration()===1/0?this.show():this.hide()}}oe.registerComponent("LiveDisplay",hx);class B0 extends qt{constructor(e,i){super(e,i),this.updateLiveEdgeStatus(),this.player_.liveTracker&&(this.updateLiveEdgeStatusHandler_=r=>this.updateLiveEdgeStatus(r),this.on(this.player_.liveTracker,"liveedgechange",this.updateLiveEdgeStatusHandler_))}createEl(){const e=super.createEl("button",{className:"vjs-seek-to-live-control vjs-control"});return this.setIcon("circle",e),this.textEl_=Be("span",{className:"vjs-seek-to-live-text",textContent:this.localize("LIVE")},{"aria-hidden":"true"}),e.appendChild(this.textEl_),e}updateLiveEdgeStatus(){!this.player_.liveTracker||this.player_.liveTracker.atLiveEdge()?(this.setAttribute("aria-disabled",!0),this.addClass("vjs-at-live-edge"),this.controlText("Seek to live, currently playing live")):(this.setAttribute("aria-disabled",!1),this.removeClass("vjs-at-live-edge"),this.controlText("Seek to live, currently behind live"))}handleClick(){this.player_.liveTracker.seekToLiveEdge()}dispose(){this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.updateLiveEdgeStatusHandler_),this.textEl_=null,super.dispose()}}B0.prototype.controlText_="Seek to live, currently playing live";oe.registerComponent("SeekToLive",B0);function us(s,e,i){return s=Number(s),Math.min(i,Math.max(e,isNaN(s)?e:s))}var fx=Object.freeze({__proto__:null,clamp:us});class Zl extends oe{constructor(e,i){super(e,i),this.handleMouseDown_=r=>this.handleMouseDown(r),this.handleMouseUp_=r=>this.handleMouseUp(r),this.handleKeyDown_=r=>this.handleKeyDown(r),this.handleClick_=r=>this.handleClick(r),this.handleMouseMove_=r=>this.handleMouseMove(r),this.update_=r=>this.update(r),this.bar=this.getChild(this.options_.barName),this.vertical(!!this.options_.vertical),this.enable()}enabled(){return this.enabled_}enable(){this.enabled()||(this.on("mousedown",this.handleMouseDown_),this.on("touchstart",this.handleMouseDown_),this.on("keydown",this.handleKeyDown_),this.on("click",this.handleClick_),this.on(this.player_,"controlsvisible",this.update),this.playerEvent&&this.on(this.player_,this.playerEvent,this.update),this.removeClass("disabled"),this.setAttribute("tabindex",0),this.enabled_=!0)}disable(){if(!this.enabled())return;const e=this.bar.el_.ownerDocument;this.off("mousedown",this.handleMouseDown_),this.off("touchstart",this.handleMouseDown_),this.off("keydown",this.handleKeyDown_),this.off("click",this.handleClick_),this.off(this.player_,"controlsvisible",this.update_),this.off(e,"mousemove",this.handleMouseMove_),this.off(e,"mouseup",this.handleMouseUp_),this.off(e,"touchmove",this.handleMouseMove_),this.off(e,"touchend",this.handleMouseUp_),this.removeAttribute("tabindex"),this.addClass("disabled"),this.playerEvent&&this.off(this.player_,this.playerEvent,this.update),this.enabled_=!1}createEl(e,i={},r={}){return i.className=i.className+" vjs-slider",i=Object.assign({tabIndex:0},i),r=Object.assign({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100},r),super.createEl(e,i,r)}handleMouseDown(e){const i=this.bar.el_.ownerDocument;e.type==="mousedown"&&e.preventDefault(),e.type==="touchstart"&&!Gi&&e.preventDefault(),s0(),this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(i,"mousemove",this.handleMouseMove_),this.on(i,"mouseup",this.handleMouseUp_),this.on(i,"touchmove",this.handleMouseMove_),this.on(i,"touchend",this.handleMouseUp_),this.handleMouseMove(e,!0)}handleMouseMove(e){}handleMouseUp(e){const i=this.bar.el_.ownerDocument;a0(),this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(i,"mousemove",this.handleMouseMove_),this.off(i,"mouseup",this.handleMouseUp_),this.off(i,"touchmove",this.handleMouseMove_),this.off(i,"touchend",this.handleMouseUp_),this.update()}update(){if(!this.el_||!this.bar)return;const e=this.getProgress();return e===this.progress_||(this.progress_=e,this.requestNamedAnimationFrame("Slider#update",()=>{const i=this.vertical()?"height":"width";this.bar.el().style[i]=(e*100).toFixed(2)+"%"})),e}getProgress(){return Number(us(this.getPercent(),0,1).toFixed(4))}calculateDistance(e){const i=Ma(this.el_,e);return this.vertical()?i.y:i.x}handleKeyDown(e){const i=this.options_.playerOptions.spatialNavigation,r=i&&i.enabled,a=i&&i.horizontalSeek;r?a&&e.key==="ArrowLeft"||!a&&e.key==="ArrowDown"?(e.preventDefault(),e.stopPropagation(),this.stepBack()):a&&e.key==="ArrowRight"||!a&&e.key==="ArrowUp"?(e.preventDefault(),e.stopPropagation(),this.stepForward()):(this.pendingSeekTime()&&(this.pendingSeekTime(null),this.userSeek_(this.player_.currentTime())),super.handleKeyDown(e)):e.key==="ArrowLeft"||e.key==="ArrowDown"?(e.preventDefault(),e.stopPropagation(),this.stepBack()):e.key==="ArrowUp"||e.key==="ArrowRight"?(e.preventDefault(),e.stopPropagation(),this.stepForward()):super.handleKeyDown(e)}handleClick(e){e.stopPropagation(),e.preventDefault()}vertical(e){if(e===void 0)return this.vertical_||!1;this.vertical_=!!e,this.vertical_?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal")}}oe.registerComponent("Slider",Zl);const Uo=(s,e)=>us(s/e*100,0,100).toFixed(2)+"%";class px extends oe{constructor(e,i){super(e,i),this.partEls_=[],this.on(e,"progress",r=>this.update(r))}createEl(){const e=super.createEl("div",{className:"vjs-load-progress"}),i=Be("span",{className:"vjs-control-text"}),r=Be("span",{textContent:this.localize("Loaded")}),a=pe.createTextNode(": ");return this.percentageEl_=Be("span",{className:"vjs-control-text-loaded-percentage",textContent:"0%"}),e.appendChild(i),i.appendChild(r),i.appendChild(a),i.appendChild(this.percentageEl_),e}dispose(){this.partEls_=null,this.percentageEl_=null,super.dispose()}update(e){this.requestNamedAnimationFrame("LoadProgressBar#update",()=>{const i=this.player_.liveTracker,r=this.player_.buffered(),a=i&&i.isLive()?i.seekableEnd():this.player_.duration(),o=this.player_.bufferedEnd(),l=this.partEls_,u=Uo(o,a);this.percent_!==u&&(this.el_.style.width=u,vn(this.percentageEl_,u),this.percent_=u);for(let d=0;d<r.length;d++){const f=r.start(d),g=r.end(d);let y=l[d];y||(y=this.el_.appendChild(Be()),l[d]=y),!(y.dataset.start===f&&y.dataset.end===g)&&(y.dataset.start=f,y.dataset.end=g,y.style.left=Uo(f,o),y.style.width=Uo(g-f,o))}for(let d=l.length;d>r.length;d--)this.el_.removeChild(l[d-1]);l.length=r.length})}}oe.registerComponent("LoadProgressBar",px);class mx extends oe{constructor(e,i){super(e,i),this.update=Wi(lt(this,this.update),Ti)}createEl(){return super.createEl("div",{className:"vjs-time-tooltip"},{"aria-hidden":"true"})}update(e,i,r){const a=rs(this.el_),o=dr(this.player_.el()),l=e.width*i;if(!o||!a)return;let u=e.left-o.left+l,d=e.width-l+(o.right-e.right);d||(d=e.width-l,u=l);let f=a.width/2;u<f?f+=f-u:d<f&&(f=d),f<0?f=0:f>a.width&&(f=a.width),f=Math.round(f),this.el_.style.right=`-${f}px`,this.write(r)}write(e){vn(this.el_,e)}updateTime(e,i,r,a){this.requestNamedAnimationFrame("TimeTooltip#updateTime",()=>{let o;const l=this.player_.duration();if(this.player_.liveTracker&&this.player_.liveTracker.isLive()){const u=this.player_.liveTracker.liveWindow(),d=u-i*u;o=(d<1?"":"-")+Rn(d,u)}else o=Rn(r,l);this.update(e,i,o),a&&a()})}}oe.registerComponent("TimeTooltip",mx);class Jl extends oe{constructor(e,i){super(e,i),this.setIcon("circle"),this.update=Wi(lt(this,this.update),Ti)}createEl(){return super.createEl("div",{className:"vjs-play-progress vjs-slider-bar"},{"aria-hidden":"true"})}update(e,i,r){const a=this.getChild("timeTooltip");if(!a)return;const o=r&&r.target&&typeof r.target.pendingSeekTime=="function"?r.target.pendingSeekTime():this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();a.updateTime(e,i,o)}}Jl.prototype.options_={children:[]};!$t&&!Bi&&Jl.prototype.options_.children.push("timeTooltip");oe.registerComponent("PlayProgressBar",Jl);class L0 extends oe{constructor(e,i){super(e,i),this.update=Wi(lt(this,this.update),Ti)}createEl(){return super.createEl("div",{className:"vjs-mouse-display"})}update(e,i){const r=i*this.player_.duration();this.getChild("timeTooltip").updateTime(e,i,r,()=>{this.el_.style.left=`${e.width*i}px`})}}L0.prototype.options_={children:["timeTooltip"]};oe.registerComponent("MouseTimeDisplay",L0);class ja extends Zl{constructor(e,i){i=rt(ja.prototype.options_,i),i.children=[...i.children];const r=e.options_.disableSeekWhileScrubbingOnMobile&&($t||Bi)||e.options_.disableSeekWhileScrubbingOnSTV;(!$t&&!Bi||r)&&i.children.splice(1,0,"mouseTimeDisplay"),super(e,i),this.shouldDisableSeekWhileScrubbing_=r,this.pendingSeekTime_=null,this.setEventHandlers_()}setEventHandlers_(){this.update_=lt(this,this.update),this.update=Wi(this.update_,Ti),this.on(this.player_,["durationchange","timeupdate"],this.update),this.on(this.player_,["ended"],this.update_),this.player_.liveTracker&&this.on(this.player_.liveTracker,"liveedgechange",this.update),this.updateInterval=null,this.enableIntervalHandler_=e=>this.enableInterval_(e),this.disableIntervalHandler_=e=>this.disableInterval_(e),this.on(this.player_,["playing"],this.enableIntervalHandler_),this.on(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in pe&&"visibilityState"in pe&&this.on(pe,"visibilitychange",this.toggleVisibility_)}toggleVisibility_(e){pe.visibilityState==="hidden"?(this.cancelNamedAnimationFrame("SeekBar#update"),this.cancelNamedAnimationFrame("Slider#update"),this.disableInterval_(e)):(!this.player_.ended()&&!this.player_.paused()&&this.enableInterval_(),this.update())}enableInterval_(){this.updateInterval||(this.updateInterval=this.setInterval(this.update,Ti))}disableInterval_(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&e&&e.type!=="ended"||this.updateInterval&&(this.clearInterval(this.updateInterval),this.updateInterval=null)}createEl(){return super.createEl("div",{className:"vjs-progress-holder"},{"aria-label":this.localize("Progress Bar")})}update(e){if(pe.visibilityState==="hidden")return;const i=super.update();return this.requestNamedAnimationFrame("SeekBar#update",()=>{const r=this.player_.ended()?this.player_.duration():this.getCurrentTime_(),a=this.player_.liveTracker;let o=this.player_.duration();a&&a.isLive()&&(o=this.player_.liveTracker.liveCurrentTime()),this.percent_!==i&&(this.el_.setAttribute("aria-valuenow",(i*100).toFixed(2)),this.percent_=i),(this.currentTime_!==r||this.duration_!==o)&&(this.el_.setAttribute("aria-valuetext",this.localize("progress bar timing: currentTime={1} duration={2}",[Rn(r,o),Rn(o,o)],"{1} of {2}")),this.currentTime_=r,this.duration_=o),this.bar&&this.bar.update(dr(this.el()),this.getProgress(),e)}),i}userSeek_(e){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&this.player_.liveTracker.nextSeekedFromUser(),this.player_.currentTime(e)}getCurrentTime_(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()}pendingSeekTime(e){if(e!==void 0)if(e!==null){const i=this.player_.duration();this.pendingSeekTime_=Math.max(0,Math.min(e,i))}else this.pendingSeekTime_=null;return this.pendingSeekTime_}getPercent(){if(this.pendingSeekTime()!==null)return this.pendingSeekTime()/this.player_.duration();const e=this.getCurrentTime_();let i;const r=this.player_.liveTracker;return r&&r.isLive()?(i=(e-r.seekableStart())/r.liveWindow(),r.atLiveEdge()&&(i=1)):i=e/this.player_.duration(),i}handleMouseDown(e){ss(e)&&(e.stopPropagation(),this.videoWasPlaying=!this.player_.paused(),this.shouldDisableSeekWhileScrubbing_||this.player_.pause(),super.handleMouseDown(e))}handleMouseMove(e,i=!1){if(!ss(e)||isNaN(this.player_.duration()))return;!i&&!this.player_.scrubbing()&&this.player_.scrubbing(!0);let r;const a=this.calculateDistance(e),o=this.player_.liveTracker;if(!o||!o.isLive())r=a*this.player_.duration(),r===this.player_.duration()&&(r=r-.1);else{if(a>=.99){o.seekToLiveEdge();return}const l=o.seekableStart(),u=o.liveCurrentTime();if(r=l+a*o.liveWindow(),r>=u&&(r=u),r<=l&&(r=l+.1),r===1/0)return}this.shouldDisableSeekWhileScrubbing_?this.pendingSeekTime(r):this.userSeek_(r),this.player_.options_.enableSmoothSeeking&&this.update()}enable(){super.enable();const e=this.getChild("mouseTimeDisplay");e&&e.show()}disable(){super.disable();const e=this.getChild("mouseTimeDisplay");e&&e.hide()}handleMouseUp(e){super.handleMouseUp(e),e&&e.stopPropagation(),this.player_.scrubbing(!1),this.pendingSeekTime()!==null&&(this.userSeek_(this.pendingSeekTime()),this.pendingSeekTime(null)),this.player_.trigger({type:"timeupdate",target:this,manuallyTriggered:!0}),this.videoWasPlaying?Ui(this.player_.play()):this.update_()}handlePendingSeek_(e){this.player_.paused()||this.player_.pause();const i=this.pendingSeekTime()!==null?this.pendingSeekTime():this.player_.currentTime();this.pendingSeekTime(i+e),this.player_.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}stepForward(){this.shouldDisableSeekWhileScrubbing_?this.handlePendingSeek_(this.options().stepSeconds):this.userSeek_(this.player_.currentTime()+this.options().stepSeconds)}stepBack(){this.shouldDisableSeekWhileScrubbing_?this.handlePendingSeek_(-this.options().stepSeconds):this.userSeek_(this.player_.currentTime()-this.options().stepSeconds)}handleAction(e){this.pendingSeekTime()!==null&&(this.userSeek_(this.pendingSeekTime()),this.pendingSeekTime(null)),this.player_.paused()?this.player_.play():this.player_.pause()}handleKeyDown(e){const i=this.player_.liveTracker;if(e.key===" "||e.key==="Enter")e.preventDefault(),e.stopPropagation(),this.handleAction(e);else if(e.key==="Home")e.preventDefault(),e.stopPropagation(),this.userSeek_(0);else if(e.key==="End")e.preventDefault(),e.stopPropagation(),i&&i.isLive()?this.userSeek_(i.liveCurrentTime()):this.userSeek_(this.player_.duration());else if(/^[0-9]$/.test(e.key)){e.preventDefault(),e.stopPropagation();const r=parseInt(e.key,10)*.1;i&&i.isLive()?this.userSeek_(i.seekableStart()+i.liveWindow()*r):this.userSeek_(this.player_.duration()*r)}else e.key==="PageDown"?(e.preventDefault(),e.stopPropagation(),this.userSeek_(this.player_.currentTime()-this.options().stepSeconds*this.options().pageMultiplier)):e.key==="PageUp"?(e.preventDefault(),e.stopPropagation(),this.userSeek_(this.player_.currentTime()+this.options().stepSeconds*this.options().pageMultiplier)):super.handleKeyDown(e)}dispose(){this.disableInterval_(),this.off(this.player_,["durationchange","timeupdate"],this.update),this.off(this.player_,["ended"],this.update_),this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.update),this.off(this.player_,["playing"],this.enableIntervalHandler_),this.off(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in pe&&"visibilityState"in pe&&this.off(pe,"visibilitychange",this.toggleVisibility_),super.dispose()}}ja.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar",stepSeconds:5,pageMultiplier:12};oe.registerComponent("SeekBar",ja);class P0 extends oe{constructor(e,i){super(e,i),this.handleMouseMove=Wi(lt(this,this.handleMouseMove),Ti),this.throttledHandleMouseSeek=Wi(lt(this,this.handleMouseSeek),Ti),this.handleMouseUpHandler_=r=>this.handleMouseUp(r),this.handleMouseDownHandler_=r=>this.handleMouseDown(r),this.enable()}createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(e){const i=this.getChild("seekBar");if(!i)return;const r=i.getChild("playProgressBar"),a=i.getChild("mouseTimeDisplay");if(!r&&!a)return;const o=i.el(),l=rs(o);let u=Ma(o,e).x;u=us(u,0,1),a&&a.update(l,u),r&&r.update(l,i.getProgress())}handleMouseSeek(e){const i=this.getChild("seekBar");i&&i.handleMouseMove(e)}enabled(){return this.enabled_}disable(){if(this.children().forEach(e=>e.disable&&e.disable()),!!this.enabled()&&(this.off(["mousedown","touchstart"],this.handleMouseDownHandler_),this.off(this.el_,["mousemove","touchmove"],this.handleMouseMove),this.removeListenersAddedOnMousedownAndTouchstart(),this.addClass("disabled"),this.enabled_=!1,this.player_.scrubbing())){const e=this.getChild("seekBar");this.player_.scrubbing(!1),e.videoWasPlaying&&Ui(this.player_.play())}}enable(){this.children().forEach(e=>e.enable&&e.enable()),!this.enabled()&&(this.on(["mousedown","touchstart"],this.handleMouseDownHandler_),this.on(this.el_,["mousemove","touchmove"],this.handleMouseMove),this.removeClass("disabled"),this.enabled_=!0)}removeListenersAddedOnMousedownAndTouchstart(){const e=this.el_.ownerDocument;this.off(e,"mousemove",this.throttledHandleMouseSeek),this.off(e,"touchmove",this.throttledHandleMouseSeek),this.off(e,"mouseup",this.handleMouseUpHandler_),this.off(e,"touchend",this.handleMouseUpHandler_)}handleMouseDown(e){const i=this.el_.ownerDocument,r=this.getChild("seekBar");r&&r.handleMouseDown(e),this.on(i,"mousemove",this.throttledHandleMouseSeek),this.on(i,"touchmove",this.throttledHandleMouseSeek),this.on(i,"mouseup",this.handleMouseUpHandler_),this.on(i,"touchend",this.handleMouseUpHandler_)}handleMouseUp(e){const i=this.getChild("seekBar");i&&i.handleMouseUp(e),this.removeListenersAddedOnMousedownAndTouchstart()}}P0.prototype.options_={children:["seekBar"]};oe.registerComponent("ProgressControl",P0);class M0 extends qt{constructor(e,i){super(e,i),this.setIcon("picture-in-picture-enter"),this.on(e,["enterpictureinpicture","leavepictureinpicture"],r=>this.handlePictureInPictureChange(r)),this.on(e,["disablepictureinpicturechanged","loadedmetadata"],r=>this.handlePictureInPictureEnabledChange(r)),this.on(e,["loadedmetadata","audioonlymodechange","audiopostermodechange"],()=>this.handlePictureInPictureAudioModeChange()),this.disable()}buildCSSClass(){return`vjs-picture-in-picture-control vjs-hidden ${super.buildCSSClass()}`}handlePictureInPictureAudioModeChange(){if(!(this.player_.currentType().substring(0,5)==="audio"||this.player_.audioPosterMode()||this.player_.audioOnlyMode())){this.show();return}this.player_.isInPictureInPicture()&&this.player_.exitPictureInPicture(),this.hide()}handlePictureInPictureEnabledChange(){pe.pictureInPictureEnabled&&this.player_.disablePictureInPicture()===!1||this.player_.options_.enableDocumentPictureInPicture&&"documentPictureInPicture"in W?this.enable():this.disable()}handlePictureInPictureChange(e){this.player_.isInPictureInPicture()?(this.setIcon("picture-in-picture-exit"),this.controlText("Exit Picture-in-Picture")):(this.setIcon("picture-in-picture-enter"),this.controlText("Picture-in-Picture")),this.handlePictureInPictureEnabledChange()}handleClick(e){this.player_.isInPictureInPicture()?this.player_.exitPictureInPicture():this.player_.requestPictureInPicture()}show(){typeof pe.exitPictureInPicture=="function"&&super.show()}}M0.prototype.controlText_="Picture-in-Picture";oe.registerComponent("PictureInPictureToggle",M0);class R0 extends qt{constructor(e,i){super(e,i),this.setIcon("fullscreen-enter"),this.on(e,"fullscreenchange",r=>this.handleFullscreenChange(r)),pe[e.fsApi_.fullscreenEnabled]===!1&&this.disable()}buildCSSClass(){return`vjs-fullscreen-control ${super.buildCSSClass()}`}handleFullscreenChange(e){this.player_.isFullscreen()?(this.controlText("Exit Fullscreen"),this.setIcon("fullscreen-exit")):(this.controlText("Fullscreen"),this.setIcon("fullscreen-enter"))}handleClick(e){this.player_.isFullscreen()?this.player_.exitFullscreen():this.player_.requestFullscreen()}}R0.prototype.controlText_="Fullscreen";oe.registerComponent("FullscreenToggle",R0);const gx=function(s,e){e.tech_&&!e.tech_.featuresVolumeControl&&s.addClass("vjs-hidden"),s.on(e,"loadstart",function(){e.tech_.featuresVolumeControl?s.removeClass("vjs-hidden"):s.addClass("vjs-hidden")})};class _x extends oe{createEl(){const e=super.createEl("div",{className:"vjs-volume-level"});return this.setIcon("circle",e),e.appendChild(super.createEl("span",{className:"vjs-control-text"})),e}}oe.registerComponent("VolumeLevel",_x);class yx extends oe{constructor(e,i){super(e,i),this.update=Wi(lt(this,this.update),Ti)}createEl(){return super.createEl("div",{className:"vjs-volume-tooltip"},{"aria-hidden":"true"})}update(e,i,r,a){if(!r){const o=dr(this.el_),l=dr(this.player_.el()),u=e.width*i;if(!l||!o)return;const d=e.left-l.left+u,f=e.width-u+(l.right-e.right);let g=o.width/2;d<g?g+=g-d:f<g&&(g=f),g<0?g=0:g>o.width&&(g=o.width),this.el_.style.right=`-${g}px`}this.write(`${a}%`)}write(e){vn(this.el_,e)}updateVolume(e,i,r,a,o){this.requestNamedAnimationFrame("VolumeLevelTooltip#updateVolume",()=>{this.update(e,i,r,a.toFixed(0)),o&&o()})}}oe.registerComponent("VolumeLevelTooltip",yx);class V0 extends oe{constructor(e,i){super(e,i),this.update=Wi(lt(this,this.update),Ti)}createEl(){return super.createEl("div",{className:"vjs-mouse-display"})}update(e,i,r){const a=100*i;this.getChild("volumeLevelTooltip").updateVolume(e,i,r,a,()=>{r?this.el_.style.bottom=`${e.height*i}px`:this.el_.style.left=`${e.width*i}px`})}}V0.prototype.options_={children:["volumeLevelTooltip"]};oe.registerComponent("MouseVolumeLevelDisplay",V0);class Ha extends Zl{constructor(e,i){super(e,i),this.on("slideractive",r=>this.updateLastVolume_(r)),this.on(e,"volumechange",r=>this.updateARIAAttributes(r)),e.ready(()=>this.updateARIAAttributes())}createEl(){return super.createEl("div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":this.localize("Volume Level"),"aria-live":"polite"})}handleMouseDown(e){ss(e)&&super.handleMouseDown(e)}handleMouseMove(e){const i=this.getChild("mouseVolumeLevelDisplay");if(i){const r=this.el(),a=dr(r),o=this.vertical();let l=Ma(r,e);l=o?l.y:l.x,l=us(l,0,1),i.update(a,l,o)}ss(e)&&(this.checkMuted(),this.player_.volume(this.calculateDistance(e)))}checkMuted(){this.player_.muted()&&this.player_.muted(!1)}getPercent(){return this.player_.muted()?0:this.player_.volume()}stepForward(){this.checkMuted(),this.player_.volume(this.player_.volume()+.1)}stepBack(){this.checkMuted(),this.player_.volume(this.player_.volume()-.1)}updateARIAAttributes(e){const i=this.player_.muted()?0:this.volumeAsPercentage_();this.el_.setAttribute("aria-valuenow",i),this.el_.setAttribute("aria-valuetext",i+"%")}volumeAsPercentage_(){return Math.round(this.player_.volume()*100)}updateLastVolume_(){const e=this.player_.volume();this.one("sliderinactive",()=>{this.player_.volume()===0&&this.player_.lastVolume_(e)})}}Ha.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"};!$t&&!Bi&&Ha.prototype.options_.children.splice(0,0,"mouseVolumeLevelDisplay");Ha.prototype.playerEvent="volumechange";oe.registerComponent("VolumeBar",Ha);class F0 extends oe{constructor(e,i={}){i.vertical=i.vertical||!1,(typeof i.volumeBar>"u"||ur(i.volumeBar))&&(i.volumeBar=i.volumeBar||{},i.volumeBar.vertical=i.vertical),super(e,i),gx(this,e),this.throttledHandleMouseMove=Wi(lt(this,this.handleMouseMove),Ti),this.handleMouseUpHandler_=r=>this.handleMouseUp(r),this.on("mousedown",r=>this.handleMouseDown(r)),this.on("touchstart",r=>this.handleMouseDown(r)),this.on("mousemove",r=>this.handleMouseMove(r)),this.on(this.volumeBar,["focus","slideractive"],()=>{this.volumeBar.addClass("vjs-slider-active"),this.addClass("vjs-slider-active"),this.trigger("slideractive")}),this.on(this.volumeBar,["blur","sliderinactive"],()=>{this.volumeBar.removeClass("vjs-slider-active"),this.removeClass("vjs-slider-active"),this.trigger("sliderinactive")})}createEl(){let e="vjs-volume-horizontal";return this.options_.vertical&&(e="vjs-volume-vertical"),super.createEl("div",{className:`vjs-volume-control vjs-control ${e}`})}handleMouseDown(e){const i=this.el_.ownerDocument;this.on(i,"mousemove",this.throttledHandleMouseMove),this.on(i,"touchmove",this.throttledHandleMouseMove),this.on(i,"mouseup",this.handleMouseUpHandler_),this.on(i,"touchend",this.handleMouseUpHandler_)}handleMouseUp(e){const i=this.el_.ownerDocument;this.off(i,"mousemove",this.throttledHandleMouseMove),this.off(i,"touchmove",this.throttledHandleMouseMove),this.off(i,"mouseup",this.handleMouseUpHandler_),this.off(i,"touchend",this.handleMouseUpHandler_)}handleMouseMove(e){this.volumeBar.handleMouseMove(e)}}F0.prototype.options_={children:["volumeBar"]};oe.registerComponent("VolumeControl",F0);const vx=function(s,e){e.tech_&&!e.tech_.featuresMuteControl&&s.addClass("vjs-hidden"),s.on(e,"loadstart",function(){e.tech_.featuresMuteControl?s.removeClass("vjs-hidden"):s.addClass("vjs-hidden")})};class $0 extends qt{constructor(e,i){super(e,i),vx(this,e),this.on(e,["loadstart","volumechange"],r=>this.update(r))}buildCSSClass(){return`vjs-mute-control ${super.buildCSSClass()}`}handleClick(e){const i=this.player_.volume(),r=this.player_.lastVolume_();if(i===0){const a=r<.1?.1:r;this.player_.volume(a),this.player_.muted(!1)}else this.player_.muted(!this.player_.muted())}update(e){this.updateIcon_(),this.updateControlText_()}updateIcon_(){const e=this.player_.volume();let i=3;this.setIcon("volume-high"),$t&&this.player_.tech_&&this.player_.tech_.el_&&this.player_.muted(this.player_.tech_.el_.muted),e===0||this.player_.muted()?(this.setIcon("volume-mute"),i=0):e<.33?(this.setIcon("volume-low"),i=1):e<.67&&(this.setIcon("volume-medium"),i=2),La(this.el_,[0,1,2,3].reduce((r,a)=>r+`${a?" ":""}vjs-vol-${a}`,"")),On(this.el_,`vjs-vol-${i}`)}updateControlText_(){const i=this.player_.muted()||this.player_.volume()===0?"Unmute":"Mute";this.controlText()!==i&&this.controlText(i)}}$0.prototype.controlText_="Mute";oe.registerComponent("MuteToggle",$0);class U0 extends oe{constructor(e,i={}){typeof i.inline<"u"?i.inline=i.inline:i.inline=!0,(typeof i.volumeControl>"u"||ur(i.volumeControl))&&(i.volumeControl=i.volumeControl||{},i.volumeControl.vertical=!i.inline),super(e,i),this.handleKeyPressHandler_=r=>this.handleKeyPress(r),this.on(e,["loadstart"],r=>this.volumePanelState_(r)),this.on(this.muteToggle,"keyup",r=>this.handleKeyPress(r)),this.on(this.volumeControl,"keyup",r=>this.handleVolumeControlKeyUp(r)),this.on("keydown",r=>this.handleKeyPress(r)),this.on("mouseover",r=>this.handleMouseOver(r)),this.on("mouseout",r=>this.handleMouseOut(r)),this.on(this.volumeControl,["slideractive"],this.sliderActive_),this.on(this.volumeControl,["sliderinactive"],this.sliderInactive_)}sliderActive_(){this.addClass("vjs-slider-active")}sliderInactive_(){this.removeClass("vjs-slider-active")}volumePanelState_(){this.volumeControl.hasClass("vjs-hidden")&&this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-hidden"),this.volumeControl.hasClass("vjs-hidden")&&!this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-mute-toggle-only")}createEl(){let e="vjs-volume-panel-horizontal";return this.options_.inline||(e="vjs-volume-panel-vertical"),super.createEl("div",{className:`vjs-volume-panel vjs-control ${e}`})}dispose(){this.handleMouseOut(),super.dispose()}handleVolumeControlKeyUp(e){e.key==="Escape"&&this.muteToggle.focus()}handleMouseOver(e){this.addClass("vjs-hover"),fi(pe,"keyup",this.handleKeyPressHandler_)}handleMouseOut(e){this.removeClass("vjs-hover"),Ut(pe,"keyup",this.handleKeyPressHandler_)}handleKeyPress(e){e.key==="Escape"&&this.handleMouseOut()}}U0.prototype.options_={children:["muteToggle","volumeControl"]};oe.registerComponent("VolumePanel",U0);class q0 extends qt{constructor(e,i){super(e,i),this.validOptions=[5,10,30],this.skipTime=this.getSkipForwardTime(),this.skipTime&&this.validOptions.includes(this.skipTime)?(this.setIcon(`forward-${this.skipTime}`),this.controlText(this.localize("Skip forward {1} seconds",[this.skipTime.toLocaleString(e.language())])),this.show()):this.hide()}getSkipForwardTime(){const e=this.options_.playerOptions;return e.controlBar&&e.controlBar.skipButtons&&e.controlBar.skipButtons.forward}buildCSSClass(){return`vjs-skip-forward-${this.getSkipForwardTime()} ${super.buildCSSClass()}`}handleClick(e){if(isNaN(this.player_.duration()))return;const i=this.player_.currentTime(),r=this.player_.liveTracker,a=r&&r.isLive()?r.seekableEnd():this.player_.duration();let o;i+this.skipTime<=a?o=i+this.skipTime:o=a,this.player_.currentTime(o)}handleLanguagechange(){this.controlText(this.localize("Skip forward {1} seconds",[this.skipTime]))}}q0.prototype.controlText_="Skip Forward";oe.registerComponent("SkipForward",q0);class j0 extends qt{constructor(e,i){super(e,i),this.validOptions=[5,10,30],this.skipTime=this.getSkipBackwardTime(),this.skipTime&&this.validOptions.includes(this.skipTime)?(this.setIcon(`replay-${this.skipTime}`),this.controlText(this.localize("Skip backward {1} seconds",[this.skipTime.toLocaleString(e.language())])),this.show()):this.hide()}getSkipBackwardTime(){const e=this.options_.playerOptions;return e.controlBar&&e.controlBar.skipButtons&&e.controlBar.skipButtons.backward}buildCSSClass(){return`vjs-skip-backward-${this.getSkipBackwardTime()} ${super.buildCSSClass()}`}handleClick(e){const i=this.player_.currentTime(),r=this.player_.liveTracker,a=r&&r.isLive()&&r.seekableStart();let o;a&&i-this.skipTime<=a?o=a:i>=this.skipTime?o=i-this.skipTime:o=0,this.player_.currentTime(o)}handleLanguagechange(){this.controlText(this.localize("Skip backward {1} seconds",[this.skipTime]))}}j0.prototype.controlText_="Skip Backward";oe.registerComponent("SkipBackward",j0);class H0 extends oe{constructor(e,i){super(e,i),i&&(this.menuButton_=i.menuButton),this.focusedChild_=-1,this.on("keydown",r=>this.handleKeyDown(r)),this.boundHandleBlur_=r=>this.handleBlur(r),this.boundHandleTapClick_=r=>this.handleTapClick(r)}addEventListenerForItem(e){e instanceof oe&&(this.on(e,"blur",this.boundHandleBlur_),this.on(e,["tap","click"],this.boundHandleTapClick_))}removeEventListenerForItem(e){e instanceof oe&&(this.off(e,"blur",this.boundHandleBlur_),this.off(e,["tap","click"],this.boundHandleTapClick_))}removeChild(e){typeof e=="string"&&(e=this.getChild(e)),this.removeEventListenerForItem(e),super.removeChild(e)}addItem(e){const i=this.addChild(e);i&&this.addEventListenerForItem(i)}createEl(){const e=this.options_.contentElType||"ul";this.contentEl_=Be(e,{className:"vjs-menu-content"}),this.contentEl_.setAttribute("role","menu");const i=super.createEl("div",{append:this.contentEl_,className:"vjs-menu"});return i.appendChild(this.contentEl_),fi(i,"click",function(r){r.preventDefault(),r.stopImmediatePropagation()}),i}dispose(){this.contentEl_=null,this.boundHandleBlur_=null,this.boundHandleTapClick_=null,super.dispose()}handleBlur(e){const i=e.relatedTarget||pe.activeElement;if(!this.children().some(r=>r.el()===i)){const r=this.menuButton_;r&&r.buttonPressed_&&i!==r.el().firstChild&&r.unpressButton()}}handleTapClick(e){if(this.menuButton_){this.menuButton_.unpressButton();const i=this.children();if(!Array.isArray(i))return;const r=i.filter(a=>a.el()===e.target)[0];if(!r)return;r.name()!=="CaptionSettingsMenuItem"&&this.menuButton_.focus()}}handleKeyDown(e){e.key==="ArrowLeft"||e.key==="ArrowDown"?(e.preventDefault(),e.stopPropagation(),this.stepForward()):(e.key==="ArrowRight"||e.key==="ArrowUp")&&(e.preventDefault(),e.stopPropagation(),this.stepBack())}stepForward(){let e=0;this.focusedChild_!==void 0&&(e=this.focusedChild_+1),this.focus(e)}stepBack(){let e=0;this.focusedChild_!==void 0&&(e=this.focusedChild_-1),this.focus(e)}focus(e=0){const i=this.children().slice();i.length&&i[0].hasClass("vjs-menu-title")&&i.shift(),i.length>0&&(e<0?e=0:e>=i.length&&(e=i.length-1),this.focusedChild_=e,i[e].el_.focus())}}oe.registerComponent("Menu",H0);class eu extends oe{constructor(e,i={}){super(e,i),this.menuButton_=new qt(e,i),this.menuButton_.controlText(this.controlText_),this.menuButton_.el_.setAttribute("aria-haspopup","true");const r=qt.prototype.buildCSSClass();this.menuButton_.el_.className=this.buildCSSClass()+" "+r,this.menuButton_.removeClass("vjs-control"),this.addChild(this.menuButton_),this.update(),this.enabled_=!0;const a=o=>this.handleClick(o);this.handleMenuKeyUp_=o=>this.handleMenuKeyUp(o),this.on(this.menuButton_,"tap",a),this.on(this.menuButton_,"click",a),this.on(this.menuButton_,"keydown",o=>this.handleKeyDown(o)),this.on(this.menuButton_,"mouseenter",()=>{this.addClass("vjs-hover"),this.menu.show(),fi(pe,"keyup",this.handleMenuKeyUp_)}),this.on("mouseleave",o=>this.handleMouseLeave(o)),this.on("keydown",o=>this.handleSubmenuKeyDown(o))}update(){const e=this.createMenu();this.menu&&(this.menu.dispose(),this.removeChild(this.menu)),this.menu=e,this.addChild(e),this.buttonPressed_=!1,this.menuButton_.el_.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.hideThreshold_?(this.hide(),this.menu.contentEl_.removeAttribute("role")):(this.show(),this.menu.contentEl_.setAttribute("role","menu"))}createMenu(){const e=new H0(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){const i=Be("li",{className:"vjs-menu-title",textContent:gt(this.options_.title),tabIndex:-1}),r=new oe(this.player_,{el:i});e.addItem(r)}if(this.items=this.createItems(),this.items)for(let i=0;i<this.items.length;i++)e.addItem(this.items[i]);return e}createItems(){}createEl(){return super.createEl("div",{className:this.buildWrapperCSSClass()},{})}setIcon(e){return super.setIcon(e,this.menuButton_.el_)}buildWrapperCSSClass(){let e="vjs-menu-button";this.options_.inline===!0?e+="-inline":e+="-popup";const i=qt.prototype.buildCSSClass();return`vjs-menu-button ${e} ${i} ${super.buildCSSClass()}`}buildCSSClass(){let e="vjs-menu-button";return this.options_.inline===!0?e+="-inline":e+="-popup",`vjs-menu-button ${e} ${super.buildCSSClass()}`}controlText(e,i=this.menuButton_.el()){return this.menuButton_.controlText(e,i)}dispose(){this.handleMouseLeave(),super.dispose()}handleClick(e){this.buttonPressed_?this.unpressButton():this.pressButton()}handleMouseLeave(e){this.removeClass("vjs-hover"),Ut(pe,"keyup",this.handleMenuKeyUp_)}focus(){this.menuButton_.focus()}blur(){this.menuButton_.blur()}handleKeyDown(e){e.key==="Escape"||e.key==="Tab"?(this.buttonPressed_&&this.unpressButton(),!e.key==="Tab"&&(e.preventDefault(),this.menuButton_.focus())):(e.key==="Up"||e.key==="Down"&&!(this.player_.options_.playerOptions.spatialNavigation&&this.player_.options_.playerOptions.spatialNavigation.enabled))&&(this.buttonPressed_||(e.preventDefault(),this.pressButton()))}handleMenuKeyUp(e){(e.key==="Escape"||e.key==="Tab")&&this.removeClass("vjs-hover")}handleSubmenuKeyPress(e){this.handleSubmenuKeyDown(e)}handleSubmenuKeyDown(e){(e.key==="Escape"||e.key==="Tab")&&(this.buttonPressed_&&this.unpressButton(),!e.key==="Tab"&&(e.preventDefault(),this.menuButton_.focus()))}pressButton(){if(this.enabled_){if(this.buttonPressed_=!0,this.menu.show(),this.menu.lockShowing(),this.menuButton_.el_.setAttribute("aria-expanded","true"),$t&&e0())return;this.menu.focus()}}unpressButton(){this.enabled_&&(this.buttonPressed_=!1,this.menu.unlockShowing(),this.menu.hide(),this.menuButton_.el_.setAttribute("aria-expanded","false"))}disable(){this.unpressButton(),this.enabled_=!1,this.addClass("vjs-disabled"),this.menuButton_.disable()}enable(){this.enabled_=!0,this.removeClass("vjs-disabled"),this.menuButton_.enable()}}oe.registerComponent("MenuButton",eu);class tu extends eu{constructor(e,i){const r=i.tracks;if(super(e,i),this.items.length<=1&&this.hide(),!r)return;const a=lt(this,this.update);r.addEventListener("removetrack",a),r.addEventListener("addtrack",a),r.addEventListener("labelchange",a),this.player_.on("ready",a),this.player_.on("dispose",function(){r.removeEventListener("removetrack",a),r.removeEventListener("addtrack",a),r.removeEventListener("labelchange",a)})}}oe.registerComponent("TrackButton",tu);class cs extends qa{constructor(e,i){super(e,i),this.selectable=i.selectable,this.isSelected_=i.selected||!1,this.multiSelectable=i.multiSelectable,this.selected(this.isSelected_),this.selectable?this.multiSelectable?this.el_.setAttribute("role","menuitemcheckbox"):this.el_.setAttribute("role","menuitemradio"):this.el_.setAttribute("role","menuitem")}createEl(e,i,r){this.nonIconControl=!0;const a=super.createEl("li",Object.assign({className:"vjs-menu-item",tabIndex:-1},i),r),o=Be("span",{className:"vjs-menu-item-text",textContent:this.localize(this.options_.label)});return this.player_.options_.experimentalSvgIcons?a.appendChild(o):a.replaceChild(o,a.querySelector(".vjs-icon-placeholder")),a}handleKeyDown(e){["Tab","Escape","ArrowUp","ArrowLeft","ArrowRight","ArrowDown"].includes(e.key)||super.handleKeyDown(e)}handleClick(e){this.selected(!0)}selected(e){this.selectable&&(e?(this.addClass("vjs-selected"),this.el_.setAttribute("aria-checked","true"),this.controlText(", selected"),this.isSelected_=!0):(this.removeClass("vjs-selected"),this.el_.setAttribute("aria-checked","false"),this.controlText(""),this.isSelected_=!1))}}oe.registerComponent("MenuItem",cs);class ds extends cs{constructor(e,i){const r=i.track,a=e.textTracks();i.label=r.label||r.language||"Unknown",i.selected=r.mode==="showing",super(e,i),this.track=r,this.kinds=(i.kinds||[i.kind||this.track.kind]).filter(Boolean);const o=(...u)=>{this.handleTracksChange.apply(this,u)},l=(...u)=>{this.handleSelectedLanguageChange.apply(this,u)};if(e.on(["loadstart","texttrackchange"],o),a.addEventListener("change",o),a.addEventListener("selectedlanguagechange",l),this.on("dispose",function(){e.off(["loadstart","texttrackchange"],o),a.removeEventListener("change",o),a.removeEventListener("selectedlanguagechange",l)}),a.onchange===void 0){let u;this.on(["tap","click"],function(){if(typeof W.Event!="object")try{u=new W.Event("change")}catch{}u||(u=pe.createEvent("Event"),u.initEvent("change",!0,!0)),a.dispatchEvent(u)})}this.handleTracksChange()}handleClick(e){const i=this.track,r=this.player_.textTracks();if(super.handleClick(e),!!r)for(let a=0;a<r.length;a++){const o=r[a];this.kinds.indexOf(o.kind)!==-1&&(o===i?o.mode!=="showing"&&(o.mode="showing"):o.mode!=="disabled"&&(o.mode="disabled"))}}handleTracksChange(e){const i=this.track.mode==="showing";i!==this.isSelected_&&this.selected(i)}handleSelectedLanguageChange(e){if(this.track.mode==="showing"){const i=this.player_.cache_.selectedLanguage;if(i&&i.enabled&&i.language===this.track.language&&i.kind!==this.track.kind)return;this.player_.cache_.selectedLanguage={enabled:!0,language:this.track.language,kind:this.track.kind}}}dispose(){this.track=null,super.dispose()}}oe.registerComponent("TextTrackMenuItem",ds);class z0 extends ds{constructor(e,i){i.track={player:e,kind:i.kind,kinds:i.kinds,default:!1,mode:"disabled"},i.kinds||(i.kinds=[i.kind]),i.label?i.track.label=i.label:i.track.label=i.kinds.join(" and ")+" off",i.selectable=!0,i.multiSelectable=!1,super(e,i)}handleTracksChange(e){const i=this.player().textTracks();let r=!0;for(let a=0,o=i.length;a<o;a++){const l=i[a];if(this.options_.kinds.indexOf(l.kind)>-1&&l.mode==="showing"){r=!1;break}}r!==this.isSelected_&&this.selected(r)}handleSelectedLanguageChange(e){const i=this.player().textTracks();let r=!0;for(let a=0,o=i.length;a<o;a++){const l=i[a];if(["captions","descriptions","subtitles"].indexOf(l.kind)>-1&&l.mode==="showing"){r=!1;break}}r&&(this.player_.cache_.selectedLanguage={enabled:!1})}handleLanguagechange(){this.$(".vjs-menu-item-text").textContent=this.player_.localize(this.options_.label),super.handleLanguagechange()}}oe.registerComponent("OffTextTrackMenuItem",z0);class Tr extends tu{constructor(e,i={}){i.tracks=e.textTracks(),super(e,i)}createItems(e=[],i=ds){let r;this.label_&&(r=`${this.label_} off`),e.push(new z0(this.player_,{kinds:this.kinds_,kind:this.kind_,label:r})),this.hideThreshold_+=1;const a=this.player_.textTracks();Array.isArray(this.kinds_)||(this.kinds_=[this.kind_]);for(let o=0;o<a.length;o++){const l=a[o];if(this.kinds_.indexOf(l.kind)>-1){const u=new i(this.player_,{track:l,kinds:this.kinds_,kind:this.kind_,selectable:!0,multiSelectable:!1});u.addClass(`vjs-${l.kind}-menu-item`),e.push(u)}}return e}}oe.registerComponent("TextTrackButton",Tr);class G0 extends cs{constructor(e,i){const r=i.track,a=i.cue,o=e.currentTime();i.selectable=!0,i.multiSelectable=!1,i.label=a.text,i.selected=a.startTime<=o&&o<a.endTime,super(e,i),this.track=r,this.cue=a}handleClick(e){super.handleClick(),this.player_.currentTime(this.cue.startTime)}}oe.registerComponent("ChaptersTrackMenuItem",G0);class iu extends Tr{constructor(e,i,r){super(e,i,r),this.setIcon("chapters"),this.selectCurrentItem_=()=>{this.items.forEach(a=>{a.selected(this.track_.activeCues[0]===a.cue)})}}buildCSSClass(){return`vjs-chapters-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-chapters-button ${super.buildWrapperCSSClass()}`}update(e){if(e&&e.track&&e.track.kind!=="chapters")return;const i=this.findChaptersTrack();i!==this.track_?(this.setTrack(i),super.update()):(!this.items||i&&i.cues&&i.cues.length!==this.items.length)&&super.update()}setTrack(e){if(this.track_!==e){if(this.updateHandler_||(this.updateHandler_=this.update.bind(this)),this.track_){const i=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);i&&i.removeEventListener("load",this.updateHandler_),this.track_.removeEventListener("cuechange",this.selectCurrentItem_),this.track_=null}if(this.track_=e,this.track_){this.track_.mode="hidden";const i=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);i&&i.addEventListener("load",this.updateHandler_),this.track_.addEventListener("cuechange",this.selectCurrentItem_)}}}findChaptersTrack(){const e=this.player_.textTracks()||[];for(let i=e.length-1;i>=0;i--){const r=e[i];if(r.kind===this.kind_)return r}}getMenuCaption(){return this.track_&&this.track_.label?this.track_.label:this.localize(gt(this.kind_))}createMenu(){return this.options_.title=this.getMenuCaption(),super.createMenu()}createItems(){const e=[];if(!this.track_)return e;const i=this.track_.cues;if(!i)return e;for(let r=0,a=i.length;r<a;r++){const o=i[r],l=new G0(this.player_,{track:this.track_,cue:o});e.push(l)}return e}}iu.prototype.kind_="chapters";iu.prototype.controlText_="Chapters";oe.registerComponent("ChaptersButton",iu);class nu extends Tr{constructor(e,i,r){super(e,i,r),this.setIcon("audio-description");const a=e.textTracks(),o=lt(this,this.handleTracksChange);a.addEventListener("change",o),this.on("dispose",function(){a.removeEventListener("change",o)})}handleTracksChange(e){const i=this.player().textTracks();let r=!1;for(let a=0,o=i.length;a<o;a++){const l=i[a];if(l.kind!==this.kind_&&l.mode==="showing"){r=!0;break}}r?this.disable():this.enable()}buildCSSClass(){return`vjs-descriptions-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-descriptions-button ${super.buildWrapperCSSClass()}`}}nu.prototype.kind_="descriptions";nu.prototype.controlText_="Descriptions";oe.registerComponent("DescriptionsButton",nu);class ru extends Tr{constructor(e,i,r){super(e,i,r),this.setIcon("subtitles")}buildCSSClass(){return`vjs-subtitles-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-subtitles-button ${super.buildWrapperCSSClass()}`}}ru.prototype.kind_="subtitles";ru.prototype.controlText_="Subtitles";oe.registerComponent("SubtitlesButton",ru);class su extends ds{constructor(e,i){i.track={player:e,kind:i.kind,label:i.kind+" settings",selectable:!1,default:!1,mode:"disabled"},i.selectable=!1,i.name="CaptionSettingsMenuItem",super(e,i),this.addClass("vjs-texttrack-settings"),this.controlText(", opens "+i.kind+" settings dialog")}handleClick(e){this.player().getChild("textTrackSettings").open()}handleLanguagechange(){this.$(".vjs-menu-item-text").textContent=this.player_.localize(this.options_.kind+" settings"),super.handleLanguagechange()}}oe.registerComponent("CaptionSettingsMenuItem",su);class au extends Tr{constructor(e,i,r){super(e,i,r),this.setIcon("captions")}buildCSSClass(){return`vjs-captions-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-captions-button ${super.buildWrapperCSSClass()}`}createItems(){const e=[];return!(this.player().tech_&&this.player().tech_.featuresNativeTextTracks)&&this.player().getChild("textTrackSettings")&&(e.push(new su(this.player_,{kind:this.kind_})),this.hideThreshold_+=1),super.createItems(e)}}au.prototype.kind_="captions";au.prototype.controlText_="Captions";oe.registerComponent("CaptionsButton",au);class W0 extends ds{createEl(e,i,r){const a=super.createEl(e,i,r),o=a.querySelector(".vjs-menu-item-text");return this.options_.track.kind==="captions"&&(this.player_.options_.experimentalSvgIcons?this.setIcon("captions",a):o.appendChild(Be("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),o.appendChild(Be("span",{className:"vjs-control-text",textContent:` ${this.localize("Captions")}`}))),a}}oe.registerComponent("SubsCapsMenuItem",W0);class ou extends Tr{constructor(e,i={}){super(e,i),this.label_="subtitles",this.setIcon("subtitles"),["en","en-us","en-ca","fr-ca"].indexOf(this.player_.language_)>-1&&(this.label_="captions",this.setIcon("captions")),this.menuButton_.controlText(gt(this.label_))}buildCSSClass(){return`vjs-subs-caps-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-subs-caps-button ${super.buildWrapperCSSClass()}`}createItems(){let e=[];return!(this.player().tech_&&this.player().tech_.featuresNativeTextTracks)&&this.player().getChild("textTrackSettings")&&(e.push(new su(this.player_,{kind:this.label_})),this.hideThreshold_+=1),e=super.createItems(e,W0),e}}ou.prototype.kinds_=["captions","subtitles"];ou.prototype.controlText_="Subtitles";oe.registerComponent("SubsCapsButton",ou);class Y0 extends cs{constructor(e,i){const r=i.track,a=e.audioTracks();i.label=r.label||r.language||"Unknown",i.selected=r.enabled,super(e,i),this.track=r,this.addClass(`vjs-${r.kind}-menu-item`);const o=(...l)=>{this.handleTracksChange.apply(this,l)};a.addEventListener("change",o),this.on("dispose",()=>{a.removeEventListener("change",o)})}createEl(e,i,r){const a=super.createEl(e,i,r),o=a.querySelector(".vjs-menu-item-text");return["main-desc","descriptions"].indexOf(this.options_.track.kind)>=0&&(o.appendChild(Be("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),o.appendChild(Be("span",{className:"vjs-control-text",textContent:" "+this.localize("Descriptions")}))),a}handleClick(e){if(super.handleClick(e),this.track.enabled=!0,this.player_.tech_.featuresNativeAudioTracks){const i=this.player_.audioTracks();for(let r=0;r<i.length;r++){const a=i[r];a!==this.track&&(a.enabled=a===this.track)}}}handleTracksChange(e){this.selected(this.track.enabled)}}oe.registerComponent("AudioTrackMenuItem",Y0);class X0 extends tu{constructor(e,i={}){i.tracks=e.audioTracks(),super(e,i),this.setIcon("audio")}buildCSSClass(){return`vjs-audio-button ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-audio-button ${super.buildWrapperCSSClass()}`}createItems(e=[]){this.hideThreshold_=1;const i=this.player_.audioTracks();for(let r=0;r<i.length;r++){const a=i[r];e.push(new Y0(this.player_,{track:a,selectable:!0,multiSelectable:!1}))}return e}}X0.prototype.controlText_="Audio Track";oe.registerComponent("AudioTrackButton",X0);class lu extends cs{constructor(e,i){const r=i.rate,a=parseFloat(r,10);i.label=r,i.selected=a===e.playbackRate(),i.selectable=!0,i.multiSelectable=!1,super(e,i),this.label=r,this.rate=a,this.on(e,"ratechange",o=>this.update(o))}handleClick(e){super.handleClick(),this.player().playbackRate(this.rate)}update(e){this.selected(this.player().playbackRate()===this.rate)}}lu.prototype.contentElType="button";oe.registerComponent("PlaybackRateMenuItem",lu);class K0 extends eu{constructor(e,i){super(e,i),this.menuButton_.el_.setAttribute("aria-describedby",this.labelElId_),this.updateVisibility(),this.updateLabel(),this.on(e,"loadstart",r=>this.updateVisibility(r)),this.on(e,"ratechange",r=>this.updateLabel(r)),this.on(e,"playbackrateschange",r=>this.handlePlaybackRateschange(r))}createEl(){const e=super.createEl();return this.labelElId_="vjs-playback-rate-value-label-"+this.id_,this.labelEl_=Be("div",{className:"vjs-playback-rate-value",id:this.labelElId_,textContent:"1x"}),e.appendChild(this.labelEl_),e}dispose(){this.labelEl_=null,super.dispose()}buildCSSClass(){return`vjs-playback-rate ${super.buildCSSClass()}`}buildWrapperCSSClass(){return`vjs-playback-rate ${super.buildWrapperCSSClass()}`}createItems(){const e=this.playbackRates(),i=[];for(let r=e.length-1;r>=0;r--)i.push(new lu(this.player(),{rate:e[r]+"x"}));return i}handlePlaybackRateschange(e){this.update()}playbackRates(){const e=this.player();return e.playbackRates&&e.playbackRates()||[]}playbackRateSupported(){return this.player().tech_&&this.player().tech_.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0}updateVisibility(e){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")}updateLabel(e){this.playbackRateSupported()&&(this.labelEl_.textContent=this.player().playbackRate()+"x")}}K0.prototype.controlText_="Playback Rate";oe.registerComponent("PlaybackRateMenuButton",K0);class Q0 extends oe{buildCSSClass(){return`vjs-spacer ${super.buildCSSClass()}`}createEl(e="div",i={},r={}){return i.className||(i.className=this.buildCSSClass()),super.createEl(e,i,r)}}oe.registerComponent("Spacer",Q0);class Tx extends Q0{buildCSSClass(){return`vjs-custom-control-spacer ${super.buildCSSClass()}`}createEl(){return super.createEl("div",{className:this.buildCSSClass(),textContent:" "})}}oe.registerComponent("CustomControlSpacer",Tx);class Z0 extends oe{createEl(){return super.createEl("div",{className:"vjs-control-bar",dir:"ltr"})}}Z0.prototype.options_={children:["playToggle","skipBackward","skipForward","volumePanel","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","seekToLive","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subsCapsButton","audioTrackButton","pictureInPictureToggle","fullscreenToggle"]};oe.registerComponent("ControlBar",Z0);class J0 extends yr{constructor(e,i){super(e,i),this.on(e,"error",r=>{this.open(r)})}buildCSSClass(){return`vjs-error-display ${super.buildCSSClass()}`}content(){const e=this.player().error();return e?this.localize(e.message):""}}J0.prototype.options_=Object.assign({},yr.prototype.options_,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0});oe.registerComponent("ErrorDisplay",J0);class ef extends oe{constructor(e,i={}){super(e,i),this.el_.setAttribute("aria-labelledby",this.selectLabelledbyIds)}createEl(){return this.selectLabelledbyIds=[this.options_.legendId,this.options_.labelId].join(" ").trim(),Be("select",{id:this.options_.id},{},this.options_.SelectOptions.map(i=>{const r=(this.options_.labelId?this.options_.labelId:`vjs-track-option-${vi()}`)+"-"+i[1].replace(/\W+/g,""),a=Be("option",{id:r,value:this.localize(i[0]),textContent:this.localize(i[1])});return a.setAttribute("aria-labelledby",`${this.selectLabelledbyIds} ${r}`),a}))}}oe.registerComponent("TextTrackSelect",ef);class Ln extends oe{constructor(e,i={}){super(e,i);const r=Be("legend",{textContent:this.localize(this.options_.legendText),id:this.options_.legendId});this.el().appendChild(r);const a=this.options_.selects;for(const o of a){const l=this.options_.selectConfigs[o],u=l.className,d=l.id.replace("%s",this.options_.id_);let f=null;const g=`vjs_select_${vi()}`;if(this.options_.type==="colors"){f=Be("span",{className:u});const E=Be("label",{id:d,className:"vjs-label",textContent:this.localize(l.label)});E.setAttribute("for",g),f.appendChild(E)}const y=new ef(e,{SelectOptions:l.options,legendId:this.options_.legendId,id:g,labelId:d});this.addChild(y),this.options_.type==="colors"&&(f.appendChild(y.el()),this.el().appendChild(f))}}createEl(){return Be("fieldset",{className:this.options_.className})}}oe.registerComponent("TextTrackFieldset",Ln);class tf extends oe{constructor(e,i={}){super(e,i);const r=this.options_.textTrackComponentid,a=new Ln(e,{id_:r,legendId:`captions-text-legend-${r}`,legendText:this.localize("Text"),className:"vjs-fg vjs-track-setting",selects:this.options_.fieldSets[0],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(a);const o=new Ln(e,{id_:r,legendId:`captions-background-${r}`,legendText:this.localize("Text Background"),className:"vjs-bg vjs-track-setting",selects:this.options_.fieldSets[1],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(o);const l=new Ln(e,{id_:r,legendId:`captions-window-${r}`,legendText:this.localize("Caption Area Background"),className:"vjs-window vjs-track-setting",selects:this.options_.fieldSets[2],selectConfigs:this.options_.selectConfigs,type:"colors"});this.addChild(l)}createEl(){return Be("div",{className:"vjs-track-settings-colors"})}}oe.registerComponent("TextTrackSettingsColors",tf);class nf extends oe{constructor(e,i={}){super(e,i);const r=this.options_.textTrackComponentid,a=new Ln(e,{id_:r,legendId:`captions-font-size-${r}`,legendText:"Font Size",className:"vjs-font-percent vjs-track-setting",selects:this.options_.fieldSets[0],selectConfigs:this.options_.selectConfigs,type:"font"});this.addChild(a);const o=new Ln(e,{id_:r,legendId:`captions-edge-style-${r}`,legendText:this.localize("Text Edge Style"),className:"vjs-edge-style vjs-track-setting",selects:this.options_.fieldSets[1],selectConfigs:this.options_.selectConfigs,type:"font"});this.addChild(o);const l=new Ln(e,{id_:r,legendId:`captions-font-family-${r}`,legendText:this.localize("Font Family"),className:"vjs-font-family vjs-track-setting",selects:this.options_.fieldSets[2],selectConfigs:this.options_.selectConfigs,type:"font"});this.addChild(l)}createEl(){return Be("div",{className:"vjs-track-settings-font"})}}oe.registerComponent("TextTrackSettingsFont",nf);class rf extends oe{constructor(e,i={}){super(e,i);const r=new qt(e,{controlText:this.localize("restore all settings to the default values"),className:"vjs-default-button"});r.el().classList.remove("vjs-control","vjs-button"),r.el().textContent=this.localize("Reset"),this.addChild(r);const a=this.localize("Done"),o=new qt(e,{controlText:a,className:"vjs-done-button"});o.el().classList.remove("vjs-control","vjs-button"),o.el().textContent=a,this.addChild(o)}createEl(){return Be("div",{className:"vjs-track-settings-controls"})}}oe.registerComponent("TrackSettingsControls",rf);const qo="vjs-text-track-settings",Ed=["#000","Black"],kd=["#00F","Blue"],wd=["#0FF","Cyan"],Dd=["#0F0","Green"],Ad=["#F0F","Magenta"],Id=["#F00","Red"],Nd=["#FFF","White"],Od=["#FF0","Yellow"],jo=["1","Opaque"],Ho=["0.5","Semi-Transparent"],Bd=["0","Transparent"],fn={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[Ed,Nd,Id,Dd,kd,Od,Ad,wd],className:"vjs-bg-color"},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Opacity",options:[jo,Ho,Bd],className:"vjs-bg-opacity vjs-opacity"},color:{selector:".vjs-text-color > select",id:"captions-foreground-color-%s",label:"Color",options:[Nd,Ed,Id,Dd,kd,Od,Ad,wd],className:"vjs-text-color"},edgeStyle:{selector:".vjs-edge-style > select",id:"",label:"Text Edge Style",options:[["none","None"],["raised","Raised"],["depressed","Depressed"],["uniform","Uniform"],["dropshadow","Drop shadow"]]},fontFamily:{selector:".vjs-font-family > select",id:"",label:"Font Family",options:[["proportionalSansSerif","Proportional Sans-Serif"],["monospaceSansSerif","Monospace Sans-Serif"],["proportionalSerif","Proportional Serif"],["monospaceSerif","Monospace Serif"],["casual","Casual"],["script","Script"],["small-caps","Small Caps"]]},fontPercent:{selector:".vjs-font-percent > select",id:"",label:"Font Size",options:[["0.50","50%"],["0.75","75%"],["1.00","100%"],["1.25","125%"],["1.50","150%"],["1.75","175%"],["2.00","200%"],["3.00","300%"],["4.00","400%"]],default:2,parser:s=>s==="1.00"?null:Number(s)},textOpacity:{selector:".vjs-text-opacity > select",id:"captions-foreground-opacity-%s",label:"Opacity",options:[jo,Ho],className:"vjs-text-opacity vjs-opacity"},windowColor:{selector:".vjs-window-color > select",id:"captions-window-color-%s",label:"Color",className:"vjs-window-color"},windowOpacity:{selector:".vjs-window-opacity > select",id:"captions-window-opacity-%s",label:"Opacity",options:[Bd,Ho,jo],className:"vjs-window-opacity vjs-opacity"}};fn.windowColor.options=fn.backgroundColor.options;function sf(s,e){if(e&&(s=e(s)),s&&s!=="none")return s}function bx(s,e){const i=s.options[s.options.selectedIndex].value;return sf(i,e)}function xx(s,e,i){if(e){for(let r=0;r<s.options.length;r++)if(sf(s.options[r].value,i)===e){s.selectedIndex=r;break}}}class Cx extends yr{constructor(e,i){i.temporary=!1,super(e,i),this.updateDisplay=this.updateDisplay.bind(this),this.fill(),this.hasBeenOpened_=this.hasBeenFilled_=!0,this.renderModalComponents(e),this.endDialog=Be("p",{className:"vjs-control-text",textContent:this.localize("End of dialog window.")}),this.el().appendChild(this.endDialog),this.setDefaults(),i.persistTextTrackSettings===void 0&&(this.options_.persistTextTrackSettings=this.options_.playerOptions.persistTextTrackSettings),this.bindFunctionsToSelectsAndButtons(),this.options_.persistTextTrackSettings&&this.restoreSettings()}renderModalComponents(e){const i=new tf(e,{textTrackComponentid:this.id_,selectConfigs:fn,fieldSets:[["color","textOpacity"],["backgroundColor","backgroundOpacity"],["windowColor","windowOpacity"]]});this.addChild(i);const r=new nf(e,{textTrackComponentid:this.id_,selectConfigs:fn,fieldSets:[["fontPercent"],["edgeStyle"],["fontFamily"]]});this.addChild(r);const a=new rf(e);this.addChild(a)}bindFunctionsToSelectsAndButtons(){this.on(this.$(".vjs-done-button"),["click","tap"],()=>{this.saveSettings(),this.close()}),this.on(this.$(".vjs-default-button"),["click","tap"],()=>{this.setDefaults(),this.updateDisplay()}),Kn(fn,e=>{this.on(this.$(e.selector),"change",this.updateDisplay)})}dispose(){this.endDialog=null,super.dispose()}label(){return this.localize("Caption Settings Dialog")}description(){return this.localize("Beginning of dialog window. Escape will cancel and close the window.")}buildCSSClass(){return super.buildCSSClass()+" vjs-text-track-settings"}getValues(){return Wh(fn,(e,i,r)=>{const a=bx(this.$(i.selector),i.parser);return a!==void 0&&(e[r]=a),e},{})}setValues(e){Kn(fn,(i,r)=>{xx(this.$(i.selector),e[r],i.parser)})}setDefaults(){Kn(fn,e=>{const i=e.hasOwnProperty("default")?e.default:0;this.$(e.selector).selectedIndex=i})}restoreSettings(){let e;try{e=JSON.parse(W.localStorage.getItem(qo))}catch(i){Ge.warn(i)}e&&this.setValues(e)}saveSettings(){if(!this.options_.persistTextTrackSettings)return;const e=this.getValues();try{Object.keys(e).length?W.localStorage.setItem(qo,JSON.stringify(e)):W.localStorage.removeItem(qo)}catch(i){Ge.warn(i)}}updateDisplay(){const e=this.player_.getChild("textTrackDisplay");e&&e.updateDisplay()}handleLanguagechange(){this.fill(),this.renderModalComponents(this.player_),this.bindFunctionsToSelectsAndButtons()}}oe.registerComponent("TextTrackSettings",Cx);class Sx extends oe{constructor(e,i){let r=i.ResizeObserver||W.ResizeObserver;i.ResizeObserver===null&&(r=!1);const a=rt({createEl:!r,reportTouchActivity:!1},i);super(e,a),this.ResizeObserver=i.ResizeObserver||W.ResizeObserver,this.loadListener_=null,this.resizeObserver_=null,this.debouncedHandler_=g0(()=>{this.resizeHandler()},100,!1,this),r?(this.resizeObserver_=new this.ResizeObserver(this.debouncedHandler_),this.resizeObserver_.observe(e.el())):(this.loadListener_=()=>{if(!this.el_||!this.el_.contentWindow)return;const o=this.debouncedHandler_;let l=this.unloadListener_=function(){Ut(this,"resize",o),Ut(this,"unload",l),l=null};fi(this.el_.contentWindow,"unload",l),fi(this.el_.contentWindow,"resize",o)},this.one("load",this.loadListener_))}createEl(){return super.createEl("iframe",{className:"vjs-resize-manager",tabIndex:-1,title:this.localize("No content")},{"aria-hidden":"true"})}resizeHandler(){!this.player_||!this.player_.trigger||this.player_.trigger("playerresize")}dispose(){this.debouncedHandler_&&this.debouncedHandler_.cancel(),this.resizeObserver_&&(this.player_.el()&&this.resizeObserver_.unobserve(this.player_.el()),this.resizeObserver_.disconnect()),this.loadListener_&&this.off("load",this.loadListener_),this.el_&&this.el_.contentWindow&&this.unloadListener_&&this.unloadListener_.call(this.el_.contentWindow),this.ResizeObserver=null,this.resizeObserver=null,this.debouncedHandler_=null,this.loadListener_=null,super.dispose()}}oe.registerComponent("ResizeManager",Sx);const Ex={trackingThreshold:20,liveTolerance:15};class kx extends oe{constructor(e,i){const r=rt(Ex,i,{createEl:!1});super(e,r),this.trackLiveHandler_=()=>this.trackLive_(),this.handlePlay_=a=>this.handlePlay(a),this.handleFirstTimeupdate_=a=>this.handleFirstTimeupdate(a),this.handleSeeked_=a=>this.handleSeeked(a),this.seekToLiveEdge_=a=>this.seekToLiveEdge(a),this.reset_(),this.on(this.player_,"durationchange",a=>this.handleDurationchange(a)),this.on(this.player_,"canplay",()=>this.toggleTracking())}trackLive_(){const e=this.player_.seekable();if(!e||!e.length)return;const i=Number(W.performance.now().toFixed(4)),r=this.lastTime_===-1?0:(i-this.lastTime_)/1e3;this.lastTime_=i,this.pastSeekEnd_=this.pastSeekEnd()+r;const a=this.liveCurrentTime(),o=this.player_.currentTime();let l=this.player_.paused()||this.seekedBehindLive_||Math.abs(a-o)>this.options_.liveTolerance;(!this.timeupdateSeen_||a===1/0)&&(l=!1),l!==this.behindLiveEdge_&&(this.behindLiveEdge_=l,this.trigger("liveedgechange"))}handleDurationchange(){this.toggleTracking()}toggleTracking(){this.player_.duration()===1/0&&this.liveWindow()>=this.options_.trackingThreshold?(this.player_.options_.liveui&&this.player_.addClass("vjs-liveui"),this.startTracking()):(this.player_.removeClass("vjs-liveui"),this.stopTracking())}startTracking(){this.isTracking()||(this.timeupdateSeen_||(this.timeupdateSeen_=this.player_.hasStarted()),this.trackingInterval_=this.setInterval(this.trackLiveHandler_,Ti),this.trackLive_(),this.on(this.player_,["play","pause"],this.trackLiveHandler_),this.timeupdateSeen_?this.on(this.player_,"seeked",this.handleSeeked_):(this.one(this.player_,"play",this.handlePlay_),this.one(this.player_,"timeupdate",this.handleFirstTimeupdate_)))}handleFirstTimeupdate(){this.timeupdateSeen_=!0,this.on(this.player_,"seeked",this.handleSeeked_)}handleSeeked(){const e=Math.abs(this.liveCurrentTime()-this.player_.currentTime());this.seekedBehindLive_=this.nextSeekedFromUser_&&e>2,this.nextSeekedFromUser_=!1,this.trackLive_()}handlePlay(){this.one(this.player_,"timeupdate",this.seekToLiveEdge_)}reset_(){this.lastTime_=-1,this.pastSeekEnd_=0,this.lastSeekEnd_=-1,this.behindLiveEdge_=!0,this.timeupdateSeen_=!1,this.seekedBehindLive_=!1,this.nextSeekedFromUser_=!1,this.clearInterval(this.trackingInterval_),this.trackingInterval_=null,this.off(this.player_,["play","pause"],this.trackLiveHandler_),this.off(this.player_,"seeked",this.handleSeeked_),this.off(this.player_,"play",this.handlePlay_),this.off(this.player_,"timeupdate",this.handleFirstTimeupdate_),this.off(this.player_,"timeupdate",this.seekToLiveEdge_)}nextSeekedFromUser(){this.nextSeekedFromUser_=!0}stopTracking(){this.isTracking()&&(this.reset_(),this.trigger("liveedgechange"))}seekableEnd(){const e=this.player_.seekable(),i=[];let r=e?e.length:0;for(;r--;)i.push(e.end(r));return i.length?i.sort()[i.length-1]:1/0}seekableStart(){const e=this.player_.seekable(),i=[];let r=e?e.length:0;for(;r--;)i.push(e.start(r));return i.length?i.sort()[0]:0}liveWindow(){const e=this.liveCurrentTime();return e===1/0?0:e-this.seekableStart()}isLive(){return this.isTracking()}atLiveEdge(){return!this.behindLiveEdge()}liveCurrentTime(){return this.pastSeekEnd()+this.seekableEnd()}pastSeekEnd(){const e=this.seekableEnd();return this.lastSeekEnd_!==-1&&e!==this.lastSeekEnd_&&(this.pastSeekEnd_=0),this.lastSeekEnd_=e,this.pastSeekEnd_}behindLiveEdge(){return this.behindLiveEdge_}isTracking(){return typeof this.trackingInterval_=="number"}seekToLiveEdge(){this.seekedBehindLive_=!1,!this.atLiveEdge()&&(this.nextSeekedFromUser_=!1,this.player_.currentTime(this.liveCurrentTime()))}dispose(){this.stopTracking(),super.dispose()}}oe.registerComponent("LiveTracker",kx);class wx extends oe{constructor(e,i){super(e,i),this.on("statechanged",r=>this.updateDom_()),this.updateDom_()}createEl(){return this.els={title:Be("div",{className:"vjs-title-bar-title",id:`vjs-title-bar-title-${vi()}`}),description:Be("div",{className:"vjs-title-bar-description",id:`vjs-title-bar-description-${vi()}`})},Be("div",{className:"vjs-title-bar"},{},Yh(this.els))}updateDom_(){const e=this.player_.tech_,i=e&&e.el_,r={title:"aria-labelledby",description:"aria-describedby"};["title","description"].forEach(a=>{const o=this.state[a],l=this.els[a],u=r[a];Ra(l),o&&vn(l,o),i&&(i.removeAttribute(u),o&&i.setAttribute(u,l.id))}),this.state.title||this.state.description?this.show():this.hide()}update(e){this.setState(e)}dispose(){const e=this.player_.tech_,i=e&&e.el_;i&&(i.removeAttribute("aria-labelledby"),i.removeAttribute("aria-describedby")),super.dispose(),this.els=null}}oe.registerComponent("TitleBar",wx);const Dx={initialDisplay:4e3,position:[],takeFocus:!1};class Ax extends qt{constructor(e,i){i=rt(Dx,i),super(e,i),this.controlText(i.controlText),this.hide(),this.on(this.player_,["useractive","userinactive"],r=>{this.removeClass("force-display")})}buildCSSClass(){return`vjs-transient-button focus-visible ${this.options_.position.map(e=>`vjs-${e}`).join(" ")}`}createEl(){const e=Be("button",{},{type:"button",class:this.buildCSSClass()},Be("span"));return this.controlTextEl_=e.querySelector("span"),e}show(){super.show(),this.addClass("force-display"),this.options_.takeFocus&&this.el().focus({preventScroll:!0}),this.forceDisplayTimeout=this.player_.setTimeout(()=>{this.removeClass("force-display")},this.options_.initialDisplay)}hide(){this.removeClass("force-display"),super.hide()}dispose(){this.player_.clearTimeout(this.forceDisplayTimeout),super.dispose()}}oe.registerComponent("TransientButton",Ax);const fl=s=>{const e=s.el();if(e.hasAttribute("src"))return s.triggerSourceset(e.src),!0;const i=s.$$("source"),r=[];let a="";if(!i.length)return!1;for(let o=0;o<i.length;o++){const l=i[o].src;l&&r.indexOf(l)===-1&&r.push(l)}return r.length?(r.length===1&&(a=r[0]),s.triggerSourceset(a),!0):!1},Ix=Object.defineProperty({},"innerHTML",{get(){return this.cloneNode(!0).innerHTML},set(s){const e=pe.createElement(this.nodeName.toLowerCase());e.innerHTML=s;const i=pe.createDocumentFragment();for(;e.childNodes.length;)i.appendChild(e.childNodes[0]);return this.innerText="",W.Element.prototype.appendChild.call(this,i),this.innerHTML}}),af=(s,e)=>{let i={};for(let r=0;r<s.length&&(i=Object.getOwnPropertyDescriptor(s[r],e),!(i&&i.set&&i.get));r++);return i.enumerable=!0,i.configurable=!0,i},Nx=s=>af([s.el(),W.HTMLMediaElement.prototype,W.Element.prototype,Ix],"innerHTML"),Ld=function(s){const e=s.el();if(e.resetSourceWatch_)return;const i={},r=Nx(s),a=o=>(...l)=>{const u=o.apply(e,l);return fl(s),u};["append","appendChild","insertAdjacentHTML"].forEach(o=>{e[o]&&(i[o]=e[o],e[o]=a(i[o]))}),Object.defineProperty(e,"innerHTML",rt(r,{set:a(r.set)})),e.resetSourceWatch_=()=>{e.resetSourceWatch_=null,Object.keys(i).forEach(o=>{e[o]=i[o]}),Object.defineProperty(e,"innerHTML",r)},s.one("sourceset",e.resetSourceWatch_)},Ox=Object.defineProperty({},"src",{get(){return this.hasAttribute("src")?w0(W.Element.prototype.getAttribute.call(this,"src")):""},set(s){return W.Element.prototype.setAttribute.call(this,"src",s),s}}),Bx=s=>af([s.el(),W.HTMLMediaElement.prototype,Ox],"src"),Lx=function(s){if(!s.featuresSourceset)return;const e=s.el();if(e.resetSourceset_)return;const i=Bx(s),r=e.setAttribute,a=e.load;Object.defineProperty(e,"src",rt(i,{set:o=>{const l=i.set.call(e,o);return s.triggerSourceset(e.src),l}})),e.setAttribute=(o,l)=>{const u=r.call(e,o,l);return/src/i.test(o)&&s.triggerSourceset(e.src),u},e.load=()=>{const o=a.call(e);return fl(s)||(s.triggerSourceset(""),Ld(s)),o},e.currentSrc?s.triggerSourceset(e.currentSrc):fl(s)||Ld(s),e.resetSourceset_=()=>{e.resetSourceset_=null,e.load=a,e.setAttribute=r,Object.defineProperty(e,"src",i),e.resetSourceWatch_&&e.resetSourceWatch_()}};class Ce extends Re{constructor(e,i){super(e,i);const r=e.source;let a=!1;if(this.featuresVideoFrameCallback=this.featuresVideoFrameCallback&&this.el_.tagName==="VIDEO",r&&(this.el_.currentSrc!==r.src||e.tag&&e.tag.initNetworkState_===3)?this.setSource(r):this.handleLateInit_(this.el_),e.enableSourceset&&this.setupSourcesetHandling_(),this.isScrubbing_=!1,this.el_.hasChildNodes()){const o=this.el_.childNodes;let l=o.length;const u=[];for(;l--;){const d=o[l];d.nodeName.toLowerCase()==="track"&&(this.featuresNativeTextTracks?(this.remoteTextTrackEls().addTrackElement_(d),this.remoteTextTracks().addTrack(d.track),this.textTracks().addTrack(d.track),!a&&!this.el_.hasAttribute("crossorigin")&&Ua(d.src)&&(a=!0)):u.push(d))}for(let d=0;d<u.length;d++)this.el_.removeChild(u[d])}this.proxyNativeTracks_(),this.featuresNativeTextTracks&&a&&Ge.warn(`Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.
|
|
180
|
+
This may prevent text tracks from loading.`),this.restoreMetadataTracksInIOSNativePlayer_(),(ns||Oa)&&e.nativeControlsForTouch===!0&&this.setControls(!0),this.proxyWebkitFullscreen_(),this.triggerReady()}dispose(){this.el_&&this.el_.resetSourceset_&&this.el_.resetSourceset_(),Ce.disposeMediaElement(this.el_),this.options_=null,super.dispose()}setupSourcesetHandling_(){Lx(this)}restoreMetadataTracksInIOSNativePlayer_(){const e=this.textTracks();let i;const r=()=>{i=[];for(let o=0;o<e.length;o++){const l=e[o];l.kind==="metadata"&&i.push({track:l,storedMode:l.mode})}};r(),e.addEventListener("change",r),this.on("dispose",()=>e.removeEventListener("change",r));const a=()=>{for(let o=0;o<i.length;o++){const l=i[o];l.track.mode==="disabled"&&l.track.mode!==l.storedMode&&(l.track.mode=l.storedMode)}e.removeEventListener("change",a)};this.on("webkitbeginfullscreen",()=>{e.removeEventListener("change",r),e.removeEventListener("change",a),e.addEventListener("change",a)}),this.on("webkitendfullscreen",()=>{e.removeEventListener("change",r),e.addEventListener("change",r),e.removeEventListener("change",a)})}overrideNative_(e,i){if(i!==this[`featuresNative${e}Tracks`])return;const r=e.toLowerCase();this[`${r}TracksListeners_`]&&Object.keys(this[`${r}TracksListeners_`]).forEach(a=>{this.el()[`${r}Tracks`].removeEventListener(a,this[`${r}TracksListeners_`][a])}),this[`featuresNative${e}Tracks`]=!i,this[`${r}TracksListeners_`]=null,this.proxyNativeTracksForType_(r)}overrideNativeAudioTracks(e){this.overrideNative_("Audio",e)}overrideNativeVideoTracks(e){this.overrideNative_("Video",e)}proxyNativeTracksForType_(e){const i=gi[e],r=this.el()[i.getterName],a=this[i.getterName]();if(!this[`featuresNative${i.capitalName}Tracks`]||!r||!r.addEventListener)return;const o={change:u=>{const d={type:"change",target:a,currentTarget:a,srcElement:a};a.trigger(d),e==="text"&&this[fr.remoteText.getterName]().trigger(d)},addtrack(u){a.addTrack(u.track)},removetrack(u){a.removeTrack(u.track)}},l=function(){const u=[];for(let d=0;d<a.length;d++){let f=!1;for(let g=0;g<r.length;g++)if(r[g]===a[d]){f=!0;break}f||u.push(a[d])}for(;u.length;)a.removeTrack(u.shift())};this[i.getterName+"Listeners_"]=o,Object.keys(o).forEach(u=>{const d=o[u];r.addEventListener(u,d),this.on("dispose",f=>r.removeEventListener(u,d))}),this.on("loadstart",l),this.on("dispose",u=>this.off("loadstart",l))}proxyNativeTracks_(){gi.names.forEach(e=>{this.proxyNativeTracksForType_(e)})}createEl(){let e=this.options_.tag;if(!e||!(this.options_.playerElIngest||this.movingMediaElementInDOM)){if(e){const r=e.cloneNode(!0);e.parentNode&&e.parentNode.insertBefore(r,e),Ce.disposeMediaElement(e),e=r}else{e=pe.createElement("video");const r=this.options_.tag&&hn(this.options_.tag),a=rt({},r);(!ns||this.options_.nativeControlsForTouch!==!0)&&delete a.controls,n0(e,Object.assign(a,{id:this.options_.techId,class:"vjs-tech"}))}e.playerId=this.options_.playerId}typeof this.options_.preload<"u"&&cr(e,"preload",this.options_.preload),this.options_.disablePictureInPicture!==void 0&&(e.disablePictureInPicture=this.options_.disablePictureInPicture);const i=["loop","muted","playsinline","autoplay"];for(let r=0;r<i.length;r++){const a=i[r],o=this.options_[a];typeof o<"u"&&(o?cr(e,a,a):Pa(e,a),e[a]=o)}return e}handleLateInit_(e){if(e.networkState===0||e.networkState===3)return;if(e.readyState===0){let r=!1;const a=function(){r=!0};this.on("loadstart",a);const o=function(){r||this.trigger("loadstart")};this.on("loadedmetadata",o),this.ready(function(){this.off("loadstart",a),this.off("loadedmetadata",o),r||this.trigger("loadstart")});return}const i=["loadstart"];i.push("loadedmetadata"),e.readyState>=2&&i.push("loadeddata"),e.readyState>=3&&i.push("canplay"),e.readyState>=4&&i.push("canplaythrough"),this.ready(function(){i.forEach(function(r){this.trigger(r)},this)})}setScrubbing(e){this.isScrubbing_=e}scrubbing(){return this.isScrubbing_}setCurrentTime(e){try{this.isScrubbing_&&this.el_.fastSeek&&Ba?this.el_.fastSeek(e):this.el_.currentTime=e}catch(i){Ge(i,"Video is not ready. (Video.js)")}}duration(){if(this.el_.duration===1/0&&Bi&&Gi&&this.el_.currentTime===0){const e=()=>{this.el_.currentTime>0&&(this.el_.duration===1/0&&this.trigger("durationchange"),this.off("timeupdate",e))};return this.on("timeupdate",e),NaN}return this.el_.duration||NaN}width(){return this.el_.offsetWidth}height(){return this.el_.offsetHeight}proxyWebkitFullscreen_(){if(!("webkitDisplayingFullscreen"in this.el_))return;const e=function(){this.trigger("fullscreenchange",{isFullscreen:!1}),this.el_.controls&&!this.options_.nativeControlsForTouch&&this.controls()&&(this.el_.controls=!1)},i=function(){"webkitPresentationMode"in this.el_&&this.el_.webkitPresentationMode!=="picture-in-picture"&&(this.one("webkitendfullscreen",e),this.trigger("fullscreenchange",{isFullscreen:!0,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",i),this.on("dispose",()=>{this.off("webkitbeginfullscreen",i),this.off("webkitendfullscreen",e)})}supportsFullScreen(){return typeof this.el_.webkitEnterFullScreen=="function"}enterFullScreen(){const e=this.el_;if(e.paused&&e.networkState<=e.HAVE_METADATA)Ui(this.el_.play()),this.setTimeout(function(){e.pause();try{e.webkitEnterFullScreen()}catch(i){this.trigger("fullscreenerror",i)}},0);else try{e.webkitEnterFullScreen()}catch(i){this.trigger("fullscreenerror",i)}}exitFullScreen(){if(!this.el_.webkitDisplayingFullscreen){this.trigger("fullscreenerror",new Error("The video is not fullscreen"));return}this.el_.webkitExitFullScreen()}requestPictureInPicture(){return this.el_.requestPictureInPicture()}requestVideoFrameCallback(e){return this.featuresVideoFrameCallback&&!this.el_.webkitKeys?this.el_.requestVideoFrameCallback(e):super.requestVideoFrameCallback(e)}cancelVideoFrameCallback(e){this.featuresVideoFrameCallback&&!this.el_.webkitKeys?this.el_.cancelVideoFrameCallback(e):super.cancelVideoFrameCallback(e)}src(e){if(e===void 0)return this.el_.src;this.setSrc(e)}addSourceElement(e,i){if(!e)return Ge.error("Invalid source URL."),!1;const r={src:e};i&&(r.type=i);const a=Be("source",{},r);return this.el_.appendChild(a),!0}removeSourceElement(e){if(!e)return Ge.error("Source URL is required to remove the source element."),!1;const i=this.el_.querySelectorAll("source");for(const r of i)if(r.src===e)return this.el_.removeChild(r),!0;return Ge.warn(`No matching source element found with src: ${e}`),!1}reset(){Ce.resetMediaElement(this.el_)}currentSrc(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc}setControls(e){this.el_.controls=!!e}addTextTrack(e,i,r){return this.featuresNativeTextTracks?this.el_.addTextTrack(e,i,r):super.addTextTrack(e,i,r)}createRemoteTextTrack(e){if(!this.featuresNativeTextTracks)return super.createRemoteTextTrack(e);const i=pe.createElement("track");return e.kind&&(i.kind=e.kind),e.label&&(i.label=e.label),(e.language||e.srclang)&&(i.srclang=e.language||e.srclang),e.default&&(i.default=e.default),e.id&&(i.id=e.id),e.src&&(i.src=e.src),i}addRemoteTextTrack(e,i){const r=super.addRemoteTextTrack(e,i);return this.featuresNativeTextTracks&&this.el().appendChild(r),r}removeRemoteTextTrack(e){if(super.removeRemoteTextTrack(e),this.featuresNativeTextTracks){const i=this.$$("track");let r=i.length;for(;r--;)(e===i[r]||e===i[r].track)&&this.el().removeChild(i[r])}}getVideoPlaybackQuality(){if(typeof this.el().getVideoPlaybackQuality=="function")return this.el().getVideoPlaybackQuality();const e={};return typeof this.el().webkitDroppedFrameCount<"u"&&typeof this.el().webkitDecodedFrameCount<"u"&&(e.droppedVideoFrames=this.el().webkitDroppedFrameCount,e.totalVideoFrames=this.el().webkitDecodedFrameCount),W.performance&&(e.creationTime=W.performance.now()),e}}Aa(Ce,"TEST_VID",function(){if(!mr())return;const s=pe.createElement("video"),e=pe.createElement("track");return e.kind="captions",e.srclang="en",e.label="English",s.appendChild(e),s});Ce.isSupported=function(){try{Ce.TEST_VID.volume=.5}catch{return!1}return!!(Ce.TEST_VID&&Ce.TEST_VID.canPlayType)};Ce.canPlayType=function(s){return Ce.TEST_VID.canPlayType(s)};Ce.canPlaySource=function(s,e){return Ce.canPlayType(s.type)};Ce.canControlVolume=function(){try{const s=Ce.TEST_VID.volume;Ce.TEST_VID.volume=s/2+.1;const e=s!==Ce.TEST_VID.volume;return e&&$t?(W.setTimeout(()=>{Ce&&Ce.prototype&&(Ce.prototype.featuresVolumeControl=s!==Ce.TEST_VID.volume)}),!1):e}catch{return!1}};Ce.canMuteVolume=function(){try{const s=Ce.TEST_VID.muted;return Ce.TEST_VID.muted=!s,Ce.TEST_VID.muted?cr(Ce.TEST_VID,"muted","muted"):Pa(Ce.TEST_VID,"muted","muted"),s!==Ce.TEST_VID.muted}catch{return!1}};Ce.canControlPlaybackRate=function(){if(Bi&&Gi&&Ia<58)return!1;try{const s=Ce.TEST_VID.playbackRate;return Ce.TEST_VID.playbackRate=s/2+.1,s!==Ce.TEST_VID.playbackRate}catch{return!1}};Ce.canOverrideAttributes=function(){try{const s=()=>{};Object.defineProperty(pe.createElement("video"),"src",{get:s,set:s}),Object.defineProperty(pe.createElement("audio"),"src",{get:s,set:s}),Object.defineProperty(pe.createElement("video"),"innerHTML",{get:s,set:s}),Object.defineProperty(pe.createElement("audio"),"innerHTML",{get:s,set:s})}catch{return!1}return!0};Ce.supportsNativeTextTracks=function(){return Ba||$t&&Gi};Ce.supportsNativeVideoTracks=function(){return!!(Ce.TEST_VID&&Ce.TEST_VID.videoTracks)};Ce.supportsNativeAudioTracks=function(){return!!(Ce.TEST_VID&&Ce.TEST_VID.audioTracks)};Ce.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"];[["featuresMuteControl","canMuteVolume"],["featuresPlaybackRate","canControlPlaybackRate"],["featuresSourceset","canOverrideAttributes"],["featuresNativeTextTracks","supportsNativeTextTracks"],["featuresNativeVideoTracks","supportsNativeVideoTracks"],["featuresNativeAudioTracks","supportsNativeAudioTracks"]].forEach(function([s,e]){Aa(Ce.prototype,s,()=>Ce[e](),!0)});Ce.prototype.featuresVolumeControl=Ce.canControlVolume();Ce.prototype.movingMediaElementInDOM=!$t;Ce.prototype.featuresFullscreenResize=!0;Ce.prototype.featuresProgressEvents=!0;Ce.prototype.featuresTimeupdateEvents=!0;Ce.prototype.featuresVideoFrameCallback=!!(Ce.TEST_VID&&Ce.TEST_VID.requestVideoFrameCallback);Ce.disposeMediaElement=function(s){if(s){for(s.parentNode&&s.parentNode.removeChild(s);s.hasChildNodes();)s.removeChild(s.firstChild);s.removeAttribute("src"),typeof s.load=="function"&&(function(){try{s.load()}catch{}})()}};Ce.resetMediaElement=function(s){if(!s)return;const e=s.querySelectorAll("source");let i=e.length;for(;i--;)s.removeChild(e[i]);s.removeAttribute("src"),typeof s.load=="function"&&(function(){try{s.load()}catch{}})()};["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach(function(s){Ce.prototype[s]=function(){return this.el_[s]||this.el_.hasAttribute(s)}});["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(s){Ce.prototype["set"+gt(s)]=function(e){this.el_[s]=e,e?this.el_.setAttribute(s,s):this.el_.removeAttribute(s)}});["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","defaultPlaybackRate","disablePictureInPicture","played","networkState","readyState","videoWidth","videoHeight","crossOrigin"].forEach(function(s){Ce.prototype[s]=function(){return this.el_[s]}});["volume","src","poster","preload","playbackRate","defaultPlaybackRate","disablePictureInPicture","crossOrigin"].forEach(function(s){Ce.prototype["set"+gt(s)]=function(e){this.el_[s]=e}});["pause","load","play"].forEach(function(s){Ce.prototype[s]=function(){return this.el_[s]()}});Re.withSourceHandlers(Ce);Ce.nativeSourceHandler={};Ce.nativeSourceHandler.canPlayType=function(s){try{return Ce.TEST_VID.canPlayType(s)}catch{return""}};Ce.nativeSourceHandler.canHandleSource=function(s,e){if(s.type)return Ce.nativeSourceHandler.canPlayType(s.type);if(s.src){const i=Wl(s.src);return Ce.nativeSourceHandler.canPlayType(`video/${i}`)}return""};Ce.nativeSourceHandler.handleSource=function(s,e,i){e.setSrc(s.src)};Ce.nativeSourceHandler.dispose=function(){};Ce.registerSourceHandler(Ce.nativeSourceHandler);Re.registerTech("Html5",Ce);const of=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","resize","volumechange","texttrackchange"],zo={canplay:"CanPlay",canplaythrough:"CanPlayThrough",playing:"Playing",seeked:"Seeked"},pl=["tiny","xsmall","small","medium","large","xlarge","huge"],Js={};pl.forEach(s=>{const e=s.charAt(0)==="x"?`x-${s.substring(1)}`:s;Js[s]=`vjs-layout-${e}`});const Px={tiny:210,xsmall:320,small:425,medium:768,large:1440,xlarge:2560,huge:1/0};class tt extends oe{constructor(e,i,r){if(e.id=e.id||i.id||`vjs_video_${vi()}`,i=Object.assign(tt.getTagSettings(e),i),i.initChildren=!1,i.createEl=!1,i.evented=!1,i.reportTouchActivity=!1,!i.language){const l=e.closest("[lang]");l&&(i.language=l.getAttribute("lang"))}if(super(null,i,r),this.boundDocumentFullscreenChange_=l=>this.documentFullscreenChange_(l),this.boundFullWindowOnEscKey_=l=>this.fullWindowOnEscKey(l),this.boundUpdateStyleEl_=l=>this.updateStyleEl_(l),this.boundApplyInitTime_=l=>this.applyInitTime_(l),this.boundUpdateCurrentBreakpoint_=l=>this.updateCurrentBreakpoint_(l),this.boundHandleTechClick_=l=>this.handleTechClick_(l),this.boundHandleTechDoubleClick_=l=>this.handleTechDoubleClick_(l),this.boundHandleTechTouchStart_=l=>this.handleTechTouchStart_(l),this.boundHandleTechTouchMove_=l=>this.handleTechTouchMove_(l),this.boundHandleTechTouchEnd_=l=>this.handleTechTouchEnd_(l),this.boundHandleTechTap_=l=>this.handleTechTap_(l),this.boundUpdatePlayerHeightOnAudioOnlyMode_=l=>this.updatePlayerHeightOnAudioOnlyMode_(l),this.isFullscreen_=!1,this.log=zh(this.id_),this.fsApi_=sa,this.isPosterFromTech_=!1,this.queuedCallbacks_=[],this.isReady_=!1,this.hasStarted_=!1,this.userActive_=!1,this.debugEnabled_=!1,this.audioOnlyMode_=!1,this.audioPosterMode_=!1,this.audioOnlyCache_={controlBarHeight:null,playerHeight:null,hiddenChildren:[]},!this.options_||!this.options_.techOrder||!this.options_.techOrder.length)throw new Error("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(this.tag=e,this.tagAttributes=e&&hn(e),this.language(this.options_.language),i.languages){const l={};Object.getOwnPropertyNames(i.languages).forEach(function(u){l[u.toLowerCase()]=i.languages[u]}),this.languages_=l}else this.languages_=tt.prototype.options_.languages;this.resetCache_(),this.poster_=i.poster||"",this.controls_=!!i.controls,e.controls=!1,e.removeAttribute("controls"),this.changingSrc_=!1,this.playCallbacks_=[],this.playTerminatedQueue_=[],e.hasAttribute("autoplay")?this.autoplay(!0):this.autoplay(this.options_.autoplay),i.plugins&&Object.keys(i.plugins).forEach(l=>{if(typeof this[l]!="function")throw new Error(`plugin "${l}" does not exist`)}),this.scrubbing_=!1,this.el_=this.createEl(),ql(this,{eventBusKey:"el_"}),this.fsApi_.requestFullscreen&&(fi(pe,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),this.on(this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_)),this.fluid_&&this.on(["playerreset","resize"],this.boundUpdateStyleEl_);const a=rt(this.options_);if(i.plugins&&Object.keys(i.plugins).forEach(l=>{this[l](i.plugins[l])}),i.debug&&this.debug(!0),this.options_.playerOptions=a,this.middleware_=[],this.playbackRates(i.playbackRates),i.experimentalSvgIcons){const u=new W.DOMParser().parseFromString(rx,"image/svg+xml");if(u.querySelector("parsererror"))Ge.warn("Failed to load SVG Icons. Falling back to Font Icons."),this.options_.experimentalSvgIcons=null;else{const f=u.documentElement;f.style.display="none",this.el_.appendChild(f),this.addClass("vjs-svg-icons-enabled")}}this.initChildren(),this.isAudio(e.nodeName.toLowerCase()==="audio"),this.controls()?this.addClass("vjs-controls-enabled"):this.addClass("vjs-controls-disabled"),this.el_.setAttribute("role","region"),this.isAudio()?this.el_.setAttribute("aria-label",this.localize("Audio Player")):this.el_.setAttribute("aria-label",this.localize("Video Player")),this.isAudio()&&this.addClass("vjs-audio"),i.spatialNavigation&&i.spatialNavigation.enabled&&(this.spatialNavigation=new sx(this),this.addClass("vjs-spatial-navigation-enabled")),ns&&this.addClass("vjs-touch-enabled"),$t||this.addClass("vjs-workinghover"),tt.players[this.id_]=this;const o=nl.split(".")[0];this.addClass(`vjs-v${o}`),this.userActive(!0),this.reportUserActivity(),this.one("play",l=>this.listenForUserActivity_(l)),this.on("keydown",l=>this.handleKeyDown(l)),this.on("languagechange",l=>this.handleLanguagechange(l)),this.breakpoints(this.options_.breakpoints),this.responsive(this.options_.responsive),this.on("ready",()=>{this.audioPosterMode(this.options_.audioPosterMode),this.audioOnlyMode(this.options_.audioOnlyMode)})}dispose(){this.trigger("dispose"),this.off("dispose"),Ut(pe,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),Ut(pe,"keydown",this.boundFullWindowOnEscKey_),this.styleEl_&&this.styleEl_.parentNode&&(this.styleEl_.parentNode.removeChild(this.styleEl_),this.styleEl_=null),tt.players[this.id_]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.el_&&this.el_.player&&(this.el_.player=null),this.tech_&&(this.tech_.dispose(),this.isPosterFromTech_=!1,this.poster_=""),this.playerElIngest_&&(this.playerElIngest_=null),this.tag&&(this.tag=null),ex(this),Qt.names.forEach(e=>{const i=Qt[e],r=this[i.getterName]();r&&r.off&&r.off()}),super.dispose({restoreEl:this.options_.restoreEl})}createEl(){let e=this.tag,i,r=this.playerElIngest_=e.parentNode&&e.parentNode.hasAttribute&&e.parentNode.hasAttribute("data-vjs-player");const a=this.tag.tagName.toLowerCase()==="video-js";r?i=this.el_=e.parentNode:a||(i=this.el_=super.createEl("div"));const o=hn(e);if(a){for(i=this.el_=e,e=this.tag=pe.createElement("video");i.children.length;)e.appendChild(i.firstChild);Qr(i,"video-js")||On(i,"video-js"),i.appendChild(e),r=this.playerElIngest_=i,Object.keys(i).forEach(d=>{try{e[d]=i[d]}catch{}})}e.setAttribute("tabindex","-1"),o.tabindex="-1",Gi&&Na&&(e.setAttribute("role","application"),o.role="application"),e.removeAttribute("width"),e.removeAttribute("height"),"width"in o&&delete o.width,"height"in o&&delete o.height,Object.getOwnPropertyNames(o).forEach(function(d){a&&d==="class"||i.setAttribute(d,o[d]),a&&e.setAttribute(d,o[d])}),e.playerId=e.id,e.id+="_html5_api",e.className="vjs-tech",e.player=i.player=this,this.addClass("vjs-paused");const l=["IS_SMART_TV","IS_TIZEN","IS_WEBOS","IS_ANDROID","IS_IPAD","IS_IPHONE","IS_CHROMECAST_RECEIVER"].filter(d=>Jh[d]).map(d=>"vjs-device-"+d.substring(3).toLowerCase().replace(/\_/g,"-"));if(this.addClass(...l),W.VIDEOJS_NO_DYNAMIC_STYLE!==!0){this.styleEl_=p0("vjs-styles-dimensions");const d=yn(".vjs-styles-defaults"),f=yn("head");f.insertBefore(this.styleEl_,d?d.nextSibling:f.firstChild)}this.fill_=!1,this.fluid_=!1,this.width(this.options_.width),this.height(this.options_.height),this.fill(this.options_.fill),this.fluid(this.options_.fluid),this.aspectRatio(this.options_.aspectRatio),this.crossOrigin(this.options_.crossOrigin||this.options_.crossorigin);const u=e.getElementsByTagName("a");for(let d=0;d<u.length;d++){const f=u.item(d);On(f,"vjs-hidden"),f.setAttribute("hidden","hidden")}return e.initNetworkState_=e.networkState,e.parentNode&&!r&&e.parentNode.insertBefore(i,e),sl(e,i),this.children_.unshift(e),this.el_.setAttribute("lang",this.language_),this.el_.setAttribute("translate","no"),this.el_=i,i}crossOrigin(e){if(typeof e>"u")return this.techGet_("crossOrigin");if(e!==null&&e!=="anonymous"&&e!=="use-credentials"){Ge.warn(`crossOrigin must be null, "anonymous" or "use-credentials", given "${e}"`);return}this.techCall_("setCrossOrigin",e),this.posterImage&&this.posterImage.crossOrigin(e)}width(e){return this.dimension("width",e)}height(e){return this.dimension("height",e)}dimension(e,i){const r=e+"_";if(i===void 0)return this[r]||0;if(i===""||i==="auto"){this[r]=void 0,this.updateStyleEl_();return}const a=parseFloat(i);if(isNaN(a)){Ge.error(`Improper value "${i}" supplied for for ${e}`);return}this[r]=a,this.updateStyleEl_()}fluid(e){if(e===void 0)return!!this.fluid_;this.fluid_=!!e,rn(this)&&this.off(["playerreset","resize"],this.boundUpdateStyleEl_),e?(this.addClass("vjs-fluid"),this.fill(!1),O8(this,()=>{this.on(["playerreset","resize"],this.boundUpdateStyleEl_)})):this.removeClass("vjs-fluid"),this.updateStyleEl_()}fill(e){if(e===void 0)return!!this.fill_;this.fill_=!!e,e?(this.addClass("vjs-fill"),this.fluid(!1)):this.removeClass("vjs-fill")}aspectRatio(e){if(e===void 0)return this.aspectRatio_;if(!/^\d+\:\d+$/.test(e))throw new Error("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.aspectRatio_=e,this.fluid(!0),this.updateStyleEl_()}updateStyleEl_(){if(W.VIDEOJS_NO_DYNAMIC_STYLE===!0){const u=typeof this.width_=="number"?this.width_:this.options_.width,d=typeof this.height_=="number"?this.height_:this.options_.height,f=this.tech_&&this.tech_.el();f&&(u>=0&&(f.width=u),d>=0&&(f.height=d));return}let e,i,r,a;this.aspectRatio_!==void 0&&this.aspectRatio_!=="auto"?r=this.aspectRatio_:this.videoWidth()>0?r=this.videoWidth()+":"+this.videoHeight():r="16:9";const o=r.split(":"),l=o[1]/o[0];this.width_!==void 0?e=this.width_:this.height_!==void 0?e=this.height_/l:e=this.videoWidth()||300,this.height_!==void 0?i=this.height_:i=e*l,/^[^a-zA-Z]/.test(this.id())?a="dimensions-"+this.id():a=this.id()+"-dimensions",this.addClass(a),m0(this.styleEl_,`
|
|
181
|
+
.${a} {
|
|
182
|
+
width: ${e}px;
|
|
183
|
+
height: ${i}px;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.${a}.vjs-fluid:not(.vjs-audio-only-mode) {
|
|
187
|
+
padding-top: ${l*100}%;
|
|
188
|
+
}
|
|
189
|
+
`)}loadTech_(e,i){this.tech_&&this.unloadTech_();const r=gt(e),a=e.charAt(0).toLowerCase()+e.slice(1);r!=="Html5"&&this.tag&&(Re.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.techName_=r,this.isReady_=!1;let o=this.autoplay();(typeof this.autoplay()=="string"||this.autoplay()===!0&&this.options_.normalizeAutoplay)&&(o=!1);const l={source:i,autoplay:o,nativeControlsForTouch:this.options_.nativeControlsForTouch,playerId:this.id(),techId:`${this.id()}_${a}_api`,playsinline:this.options_.playsinline,preload:this.options_.preload,loop:this.options_.loop,disablePictureInPicture:this.options_.disablePictureInPicture,muted:this.options_.muted,poster:this.poster(),language:this.language(),playerElIngest:this.playerElIngest_||!1,"vtt.js":this.options_["vtt.js"],canOverridePoster:!!this.options_.techCanOverridePoster,enableSourceset:this.options_.enableSourceset};Qt.names.forEach(d=>{const f=Qt[d];l[f.getterName]=this[f.privateName]}),Object.assign(l,this.options_[r]),Object.assign(l,this.options_[a]),Object.assign(l,this.options_[e.toLowerCase()]),this.tag&&(l.tag=this.tag),i&&i.src===this.cache_.src&&this.cache_.currentTime>0&&(l.startTime=this.cache_.currentTime);const u=Re.getTech(e);if(!u)throw new Error(`No Tech named '${r}' exists! '${r}' should be registered using videojs.registerTech()'`);this.tech_=new u(l),this.tech_.ready(lt(this,this.handleTechReady_),!0),dl.jsonToTextTracks(this.textTracksJson_||[],this.tech_),of.forEach(d=>{this.on(this.tech_,d,f=>this[`handleTech${gt(d)}_`](f))}),Object.keys(zo).forEach(d=>{this.on(this.tech_,d,f=>{if(this.tech_.playbackRate()===0&&this.tech_.seeking()){this.queuedCallbacks_.push({callback:this[`handleTech${zo[d]}_`].bind(this),event:f});return}this[`handleTech${zo[d]}_`](f)})}),this.on(this.tech_,"loadstart",d=>this.handleTechLoadStart_(d)),this.on(this.tech_,"sourceset",d=>this.handleTechSourceset_(d)),this.on(this.tech_,"waiting",d=>this.handleTechWaiting_(d)),this.on(this.tech_,"ended",d=>this.handleTechEnded_(d)),this.on(this.tech_,"seeking",d=>this.handleTechSeeking_(d)),this.on(this.tech_,"play",d=>this.handleTechPlay_(d)),this.on(this.tech_,"pause",d=>this.handleTechPause_(d)),this.on(this.tech_,"durationchange",d=>this.handleTechDurationChange_(d)),this.on(this.tech_,"fullscreenchange",(d,f)=>this.handleTechFullscreenChange_(d,f)),this.on(this.tech_,"fullscreenerror",(d,f)=>this.handleTechFullscreenError_(d,f)),this.on(this.tech_,"enterpictureinpicture",d=>this.handleTechEnterPictureInPicture_(d)),this.on(this.tech_,"leavepictureinpicture",d=>this.handleTechLeavePictureInPicture_(d)),this.on(this.tech_,"error",d=>this.handleTechError_(d)),this.on(this.tech_,"posterchange",d=>this.handleTechPosterChange_(d)),this.on(this.tech_,"textdata",d=>this.handleTechTextData_(d)),this.on(this.tech_,"ratechange",d=>this.handleTechRateChange_(d)),this.on(this.tech_,"loadedmetadata",this.boundUpdateStyleEl_),this.usingNativeControls(this.techGet_("controls")),this.controls()&&!this.usingNativeControls()&&this.addTechControlsListeners_(),this.tech_.el().parentNode!==this.el()&&(r!=="Html5"||!this.tag)&&sl(this.tech_.el(),this.el()),this.tag&&(this.tag.player=null,this.tag=null)}unloadTech_(){Qt.names.forEach(e=>{const i=Qt[e];this[i.privateName]=this[i.getterName]()}),this.textTracksJson_=dl.textTracksToJson(this.tech_),this.isReady_=!1,this.tech_.dispose(),this.tech_=!1,this.isPosterFromTech_&&(this.poster_="",this.trigger("posterchange")),this.isPosterFromTech_=!1}tech(e){return e===void 0&&Ge.warn(`Using the tech directly can be dangerous. I hope you know what you're doing.
|
|
190
|
+
See https://github.com/videojs/video.js/issues/2617 for more info.
|
|
191
|
+
`),this.tech_}version(){return{"video.js":nl}}addTechControlsListeners_(){this.removeTechControlsListeners_(),this.on(this.tech_,"click",this.boundHandleTechClick_),this.on(this.tech_,"dblclick",this.boundHandleTechDoubleClick_),this.on(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.on(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.on(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.on(this.tech_,"tap",this.boundHandleTechTap_)}removeTechControlsListeners_(){this.off(this.tech_,"tap",this.boundHandleTechTap_),this.off(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.off(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.off(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.off(this.tech_,"click",this.boundHandleTechClick_),this.off(this.tech_,"dblclick",this.boundHandleTechDoubleClick_)}handleTechReady_(){this.triggerReady(),this.cache_.volume&&this.techCall_("setVolume",this.cache_.volume),this.handleTechPosterChange_(),this.handleTechDurationChange_()}handleTechLoadStart_(){this.removeClass("vjs-ended","vjs-seeking"),this.error(null),this.handleTechDurationChange_(),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):this.trigger("loadstart"),this.manualAutoplay_(this.autoplay()===!0&&this.options_.normalizeAutoplay?"play":this.autoplay())}manualAutoplay_(e){if(!this.tech_||typeof e!="string")return;const i=()=>{const a=this.muted();this.muted(!0);const o=()=>{this.muted(a)};this.playTerminatedQueue_.push(o);const l=this.play();if(Jr(l))return l.catch(u=>{throw o(),new Error(`Rejection at manualAutoplay. Restoring muted value. ${u||""}`)})};let r;if(e==="any"&&!this.muted()?(r=this.play(),Jr(r)&&(r=r.catch(i))):e==="muted"&&!this.muted()?r=i():r=this.play(),!!Jr(r))return r.then(()=>{this.trigger({type:"autoplay-success",autoplay:e})}).catch(()=>{this.trigger({type:"autoplay-failure",autoplay:e})})}updateSourceCaches_(e=""){let i=e,r="";typeof i!="string"&&(i=e.src,r=e.type),this.cache_.source=this.cache_.source||{},this.cache_.sources=this.cache_.sources||[],i&&!r&&(r=nx(this,i)),this.cache_.source=rt({},e,{src:i,type:r});const a=this.cache_.sources.filter(d=>d.src&&d.src===i),o=[],l=this.$$("source"),u=[];for(let d=0;d<l.length;d++){const f=hn(l[d]);o.push(f),f.src&&f.src===i&&u.push(f.src)}u.length&&!a.length?this.cache_.sources=o:a.length||(this.cache_.sources=[this.cache_.source]),this.cache_.src=i}handleTechSourceset_(e){if(!this.changingSrc_){let i=o=>this.updateSourceCaches_(o);const r=this.currentSource().src,a=e.src;r&&!/^blob:/.test(r)&&/^blob:/.test(a)&&(!this.lastSource_||this.lastSource_.tech!==a&&this.lastSource_.player!==r)&&(i=()=>{}),i(a),e.src||this.tech_.any(["sourceset","loadstart"],o=>{if(o.type==="sourceset")return;const l=this.techGet_("currentSrc");this.lastSource_.tech=l,this.updateSourceCaches_(l)})}this.lastSource_={player:this.currentSource().src,tech:e.src},this.trigger({src:e.src,type:"sourceset"})}hasStarted(e){if(e===void 0)return this.hasStarted_;e!==this.hasStarted_&&(this.hasStarted_=e,this.hasStarted_?this.addClass("vjs-has-started"):this.removeClass("vjs-has-started"))}handleTechPlay_(){this.removeClass("vjs-ended","vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")}handleTechRateChange_(){this.tech_.playbackRate()>0&&this.cache_.lastPlaybackRate===0&&(this.queuedCallbacks_.forEach(e=>e.callback(e.event)),this.queuedCallbacks_=[]),this.cache_.lastPlaybackRate=this.tech_.playbackRate(),this.trigger("ratechange")}handleTechWaiting_(){this.addClass("vjs-waiting"),this.trigger("waiting");const e=this.currentTime(),i=()=>{e!==this.currentTime()&&(this.removeClass("vjs-waiting"),this.off("timeupdate",i))};this.on("timeupdate",i)}handleTechCanPlay_(){this.removeClass("vjs-waiting"),this.trigger("canplay")}handleTechCanPlayThrough_(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")}handleTechPlaying_(){this.removeClass("vjs-waiting"),this.trigger("playing")}handleTechSeeking_(){this.addClass("vjs-seeking"),this.trigger("seeking")}handleTechSeeked_(){this.removeClass("vjs-seeking","vjs-ended"),this.trigger("seeked")}handleTechPause_(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")}handleTechEnded_(){this.addClass("vjs-ended"),this.removeClass("vjs-waiting"),this.options_.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")}handleTechDurationChange_(){this.duration(this.techGet_("duration"))}handleTechClick_(e){this.controls_&&(this.options_===void 0||this.options_.userActions===void 0||this.options_.userActions.click===void 0||this.options_.userActions.click!==!1)&&(this.options_!==void 0&&this.options_.userActions!==void 0&&typeof this.options_.userActions.click=="function"?this.options_.userActions.click.call(this,e):this.paused()?Ui(this.play()):this.pause())}handleTechDoubleClick_(e){if(!this.controls_)return;Array.prototype.some.call(this.$$(".vjs-control-bar, .vjs-modal-dialog"),r=>r.contains(e.target))||(this.options_===void 0||this.options_.userActions===void 0||this.options_.userActions.doubleClick===void 0||this.options_.userActions.doubleClick!==!1)&&(this.options_!==void 0&&this.options_.userActions!==void 0&&typeof this.options_.userActions.doubleClick=="function"?this.options_.userActions.doubleClick.call(this,e):this.isInPictureInPicture()&&!pe.pictureInPictureElement?this.exitPictureInPicture():this.isFullscreen()?this.exitFullscreen():this.requestFullscreen())}handleTechTap_(){this.userActive(!this.userActive())}handleTechTouchStart_(){this.userWasActive=this.userActive()}handleTechTouchMove_(){this.userWasActive&&this.reportUserActivity()}handleTechTouchEnd_(e){e.cancelable&&e.preventDefault()}toggleFullscreenClass_(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")}documentFullscreenChange_(e){const i=e.target.player;if(i&&i!==this)return;const r=this.el();let a=pe[this.fsApi_.fullscreenElement]===r;!a&&r.matches&&(a=r.matches(":"+this.fsApi_.fullscreen)),this.isFullscreen(a)}handleTechFullscreenChange_(e,i){i&&(i.nativeIOSFullscreen&&(this.addClass("vjs-ios-native-fs"),this.tech_.one("webkitendfullscreen",()=>{this.removeClass("vjs-ios-native-fs")})),this.isFullscreen(i.isFullscreen))}handleTechFullscreenError_(e,i){this.trigger("fullscreenerror",i)}togglePictureInPictureClass_(){this.isInPictureInPicture()?this.addClass("vjs-picture-in-picture"):this.removeClass("vjs-picture-in-picture")}handleTechEnterPictureInPicture_(e){this.isInPictureInPicture(!0)}handleTechLeavePictureInPicture_(e){this.isInPictureInPicture(!1)}handleTechError_(){const e=this.tech_.error();e&&this.error(e)}handleTechTextData_(){let e=null;arguments.length>1&&(e=arguments[1]),this.trigger("textdata",e)}getCache(){return this.cache_}resetCache_(){this.cache_={currentTime:0,initTime:0,inactivityTimeout:this.options_.inactivityTimeout,duration:NaN,lastVolume:1,lastPlaybackRate:this.defaultPlaybackRate(),media:null,src:"",source:{},sources:[],playbackRates:[],volume:1}}techCall_(e,i){this.ready(function(){if(e in Z8)return K8(this.middleware_,this.tech_,e,i);if(e in vd)return yd(this.middleware_,this.tech_,e,i);try{this.tech_&&this.tech_[e](i)}catch(r){throw Ge(r),r}},!0)}techGet_(e){if(!(!this.tech_||!this.tech_.isReady_)){if(e in Q8)return X8(this.middleware_,this.tech_,e);if(e in vd)return yd(this.middleware_,this.tech_,e);try{return this.tech_[e]()}catch(i){throw this.tech_[e]===void 0?(Ge(`Video.js: ${e} method not defined for ${this.techName_} playback technology.`,i),i):i.name==="TypeError"?(Ge(`Video.js: ${e} unavailable on ${this.techName_} playback technology element.`,i),this.tech_.isReady_=!1,i):(Ge(i),i)}}}play(){return new Promise(e=>{this.play_(e)})}play_(e=Ui){this.playCallbacks_.push(e);const i=!!(!this.changingSrc_&&(this.src()||this.currentSrc())),r=!!(Ba||$t);if(this.waitToPlay_&&(this.off(["ready","loadstart"],this.waitToPlay_),this.waitToPlay_=null),!this.isReady_||!i){this.waitToPlay_=l=>{this.play_()},this.one(["ready","loadstart"],this.waitToPlay_),!i&&r&&this.load();return}const a=this.techGet_("play");r&&this.hasClass("vjs-ended")&&this.resetProgressBar_(),a===null?this.runPlayTerminatedQueue_():this.runPlayCallbacks_(a)}runPlayTerminatedQueue_(){const e=this.playTerminatedQueue_.slice(0);this.playTerminatedQueue_=[],e.forEach(function(i){i()})}runPlayCallbacks_(e){const i=this.playCallbacks_.slice(0);this.playCallbacks_=[],this.playTerminatedQueue_=[],i.forEach(function(r){r(e)})}pause(){this.techCall_("pause")}paused(){return this.techGet_("paused")!==!1}played(){return this.techGet_("played")||Oi(0,0)}scrubbing(e){if(typeof e>"u")return this.scrubbing_;this.scrubbing_=!!e,this.techCall_("setScrubbing",this.scrubbing_),e?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing")}currentTime(e){if(e===void 0)return this.cache_.currentTime=this.techGet_("currentTime")||0,this.cache_.currentTime;if(e<0&&(e=0),!this.isReady_||this.changingSrc_||!this.tech_||!this.tech_.isReady_){this.cache_.initTime=e,this.off("canplay",this.boundApplyInitTime_),this.one("canplay",this.boundApplyInitTime_);return}this.techCall_("setCurrentTime",e),this.cache_.initTime=0,isFinite(e)&&(this.cache_.currentTime=Number(e))}applyInitTime_(){this.currentTime(this.cache_.initTime)}duration(e){if(e===void 0)return this.cache_.duration!==void 0?this.cache_.duration:NaN;e=parseFloat(e),e<0&&(e=1/0),e!==this.cache_.duration&&(this.cache_.duration=e,e===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),isNaN(e)||this.trigger("durationchange"))}remainingTime(){return this.duration()-this.currentTime()}remainingTimeDisplay(){return Math.floor(this.duration())-Math.floor(this.currentTime())}buffered(){let e=this.techGet_("buffered");return(!e||!e.length)&&(e=Oi(0,0)),e}seekable(){let e=this.techGet_("seekable");return(!e||!e.length)&&(e=Oi(0,0)),e}seeking(){return this.techGet_("seeking")}ended(){return this.techGet_("ended")}networkState(){return this.techGet_("networkState")}readyState(){return this.techGet_("readyState")}bufferedPercent(){return S0(this.buffered(),this.duration())}bufferedEnd(){const e=this.buffered(),i=this.duration();let r=e.end(e.length-1);return r>i&&(r=i),r}volume(e){let i;if(e!==void 0){i=Math.max(0,Math.min(1,e)),this.cache_.volume=i,this.techCall_("setVolume",i),i>0&&this.lastVolume_(i);return}return i=parseFloat(this.techGet_("volume")),isNaN(i)?1:i}muted(e){if(e!==void 0){this.techCall_("setMuted",e);return}return this.techGet_("muted")||!1}defaultMuted(e){return e!==void 0&&this.techCall_("setDefaultMuted",e),this.techGet_("defaultMuted")||!1}lastVolume_(e){if(e!==void 0&&e!==0){this.cache_.lastVolume=e;return}return this.cache_.lastVolume}supportsFullScreen(){return this.techGet_("supportsFullScreen")||!1}isFullscreen(e){if(e!==void 0){const i=this.isFullscreen_;this.isFullscreen_=!!e,this.isFullscreen_!==i&&this.fsApi_.prefixed&&this.trigger("fullscreenchange"),this.toggleFullscreenClass_();return}return this.isFullscreen_}requestFullscreen(e){this.isInPictureInPicture()&&this.exitPictureInPicture();const i=this;return new Promise((r,a)=>{function o(){i.off("fullscreenerror",u),i.off("fullscreenchange",l)}function l(){o(),r()}function u(f,g){o(),a(g)}i.one("fullscreenchange",l),i.one("fullscreenerror",u);const d=i.requestFullscreenHelper_(e);d&&(d.then(o,o),d.then(r,a))})}requestFullscreenHelper_(e){let i;if(this.fsApi_.prefixed||(i=this.options_.fullscreen&&this.options_.fullscreen.options||{},e!==void 0&&(i=e)),this.fsApi_.requestFullscreen){const r=this.el_[this.fsApi_.requestFullscreen](i);return r&&r.then(()=>this.isFullscreen(!0),()=>this.isFullscreen(!1)),r}else this.tech_.supportsFullScreen()&&!this.options_.preferFullWindow?this.techCall_("enterFullScreen"):this.enterFullWindow()}exitFullscreen(){const e=this;return new Promise((i,r)=>{function a(){e.off("fullscreenerror",l),e.off("fullscreenchange",o)}function o(){a(),i()}function l(d,f){a(),r(f)}e.one("fullscreenchange",o),e.one("fullscreenerror",l);const u=e.exitFullscreenHelper_();u&&(u.then(a,a),u.then(i,r))})}exitFullscreenHelper_(){if(this.fsApi_.requestFullscreen){const e=pe[this.fsApi_.exitFullscreen]();return e&&Ui(e.then(()=>this.isFullscreen(!1))),e}else this.tech_.supportsFullScreen()&&!this.options_.preferFullWindow?this.techCall_("exitFullScreen"):this.exitFullWindow()}enterFullWindow(){this.isFullscreen(!0),this.isFullWindow=!0,this.docOrigOverflow=pe.documentElement.style.overflow,fi(pe,"keydown",this.boundFullWindowOnEscKey_),pe.documentElement.style.overflow="hidden",On(pe.body,"vjs-full-window"),this.trigger("enterFullWindow")}fullWindowOnEscKey(e){e.key==="Escape"&&this.isFullscreen()===!0&&(this.isFullWindow?this.exitFullWindow():this.exitFullscreen())}exitFullWindow(){this.isFullscreen(!1),this.isFullWindow=!1,Ut(pe,"keydown",this.boundFullWindowOnEscKey_),pe.documentElement.style.overflow=this.docOrigOverflow,La(pe.body,"vjs-full-window"),this.trigger("exitFullWindow")}disablePictureInPicture(e){if(e===void 0)return this.techGet_("disablePictureInPicture");this.techCall_("setDisablePictureInPicture",e),this.options_.disablePictureInPicture=e,this.trigger("disablepictureinpicturechanged")}isInPictureInPicture(e){if(e!==void 0){this.isInPictureInPicture_=!!e,this.togglePictureInPictureClass_();return}return!!this.isInPictureInPicture_}requestPictureInPicture(){if(this.options_.enableDocumentPictureInPicture&&W.documentPictureInPicture){const e=pe.createElement(this.el().tagName);return e.classList=this.el().classList,e.classList.add("vjs-pip-container"),this.posterImage&&e.appendChild(this.posterImage.el().cloneNode(!0)),this.titleBar&&e.appendChild(this.titleBar.el().cloneNode(!0)),e.appendChild(Be("p",{className:"vjs-pip-text"},{},this.localize("Playing in picture-in-picture"))),W.documentPictureInPicture.requestWindow({width:this.videoWidth(),height:this.videoHeight()}).then(i=>(d0(i),this.el_.parentNode.insertBefore(e,this.el_),i.document.body.appendChild(this.el_),i.document.body.classList.add("vjs-pip-window"),this.player_.isInPictureInPicture(!0),this.player_.trigger({type:"enterpictureinpicture",pipWindow:i}),i.addEventListener("pagehide",r=>{const a=r.target.querySelector(".video-js");e.parentNode.replaceChild(a,e),this.player_.isInPictureInPicture(!1),this.player_.trigger("leavepictureinpicture")}),i))}return"pictureInPictureEnabled"in pe&&this.disablePictureInPicture()===!1?this.techGet_("requestPictureInPicture"):Promise.reject("No PiP mode is available")}exitPictureInPicture(){if(W.documentPictureInPicture&&W.documentPictureInPicture.window)return W.documentPictureInPicture.window.close(),Promise.resolve();if("pictureInPictureEnabled"in pe)return pe.exitPictureInPicture()}handleKeyDown(e){const{userActions:i}=this.options_;!i||!i.hotkeys||(a=>{const o=a.tagName.toLowerCase();if(a.isContentEditable)return!0;const l=["button","checkbox","hidden","radio","reset","submit"];return o==="input"?l.indexOf(a.type)===-1:["textarea"].indexOf(o)!==-1})(this.el_.ownerDocument.activeElement)||(typeof i.hotkeys=="function"?i.hotkeys.call(this,e):this.handleHotkeys(e))}handleHotkeys(e){const i=this.options_.userActions?this.options_.userActions.hotkeys:{},{fullscreenKey:r=l=>e.key.toLowerCase()==="f",muteKey:a=l=>e.key.toLowerCase()==="m",playPauseKey:o=l=>e.key.toLowerCase()==="k"||e.key.toLowerCase()===" "}=i;if(r.call(this,e)){e.preventDefault(),e.stopPropagation();const l=oe.getComponent("FullscreenToggle");pe[this.fsApi_.fullscreenEnabled]!==!1&&l.prototype.handleClick.call(this,e)}else a.call(this,e)?(e.preventDefault(),e.stopPropagation(),oe.getComponent("MuteToggle").prototype.handleClick.call(this,e)):o.call(this,e)&&(e.preventDefault(),e.stopPropagation(),oe.getComponent("PlayToggle").prototype.handleClick.call(this,e))}canPlayType(e){let i;for(let r=0,a=this.options_.techOrder;r<a.length;r++){const o=a[r];let l=Re.getTech(o);if(l||(l=oe.getComponent(o)),!l){Ge.error(`The "${o}" tech is undefined. Skipped browser support check for that tech.`);continue}if(l.isSupported()&&(i=l.canPlayType(e),i))return i}return""}selectSource(e){const i=this.options_.techOrder.map(u=>[u,Re.getTech(u)]).filter(([u,d])=>d?d.isSupported():(Ge.error(`The "${u}" tech is undefined. Skipped browser support check for that tech.`),!1)),r=function(u,d,f){let g;return u.some(y=>d.some(E=>{if(g=f(y,E),g)return!0})),g};let a;const o=u=>(d,f)=>u(f,d),l=([u,d],f)=>{if(d.canPlaySource(f,this.options_[u.toLowerCase()]))return{source:f,tech:u}};return this.options_.sourceOrder?a=r(e,i,o(l)):a=r(i,e,l),a||!1}handleSrc_(e,i){if(typeof e>"u")return this.cache_.src||"";this.resetRetryOnError_&&this.resetRetryOnError_();const r=I0(e);if(!r.length){this.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0);return}if(this.changingSrc_=!0,i||(this.cache_.sources=r),this.updateSourceCaches_(r[0]),W8(this,r[0],(a,o)=>{if(this.middleware_=o,i||(this.cache_.sources=r),this.updateSourceCaches_(a),this.src_(a)){if(r.length>1)return this.handleSrc_(r.slice(1));this.changingSrc_=!1,this.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0),this.triggerReady();return}Y8(o,this.tech_)}),r.length>1){const a=()=>{this.error(null),this.handleSrc_(r.slice(1),!0)},o=()=>{this.off("error",a)};this.one("error",a),this.one("playing",o),this.resetRetryOnError_=()=>{this.off("error",a),this.off("playing",o)}}}src(e){return this.handleSrc_(e,!1)}src_(e){const i=this.selectSource([e]);return i?T0(i.tech,this.techName_)?(this.ready(function(){this.tech_.constructor.prototype.hasOwnProperty("setSource")?this.techCall_("setSource",e):this.techCall_("src",e.src),this.changingSrc_=!1},!0),!1):(this.changingSrc_=!0,this.loadTech_(i.tech,i.source),this.tech_.ready(()=>{this.changingSrc_=!1}),!1):!0}addSourceElement(e,i){return this.tech_?this.tech_.addSourceElement(e,i):!1}removeSourceElement(e){return this.tech_?this.tech_.removeSourceElement(e):!1}load(){if(this.tech_&&this.tech_.vhs){this.src(this.currentSource());return}this.techCall_("load")}reset(){if(this.paused())this.doReset_();else{const e=this.play();Ui(e.then(()=>this.doReset_()))}}doReset_(){this.tech_&&this.tech_.clearTracks("text"),this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.resetCache_(),this.poster(""),this.loadTech_(this.options_.techOrder[0],null),this.techCall_("reset"),this.resetControlBarUI_(),this.error(null),this.titleBar&&this.titleBar.update({title:void 0,description:void 0}),rn(this)&&this.trigger("playerreset")}resetControlBarUI_(){this.resetProgressBar_(),this.resetPlaybackRate_(),this.resetVolumeBar_()}resetProgressBar_(){this.currentTime(0);const{currentTimeDisplay:e,durationDisplay:i,progressControl:r,remainingTimeDisplay:a}=this.controlBar||{},{seekBar:o}=r||{};e&&e.updateContent(),i&&i.updateContent(),a&&a.updateContent(),o&&(o.update(),o.loadProgressBar&&o.loadProgressBar.update())}resetPlaybackRate_(){this.playbackRate(this.defaultPlaybackRate()),this.handleTechRateChange_()}resetVolumeBar_(){this.volume(1),this.trigger("volumechange")}currentSources(){const e=this.currentSource(),i=[];return Object.keys(e).length!==0&&i.push(e),this.cache_.sources||i}currentSource(){return this.cache_.source||{}}currentSrc(){return this.currentSource()&&this.currentSource().src||""}currentType(){return this.currentSource()&&this.currentSource().type||""}preload(e){if(e!==void 0){this.techCall_("setPreload",e),this.options_.preload=e;return}return this.techGet_("preload")}autoplay(e){if(e===void 0)return this.options_.autoplay||!1;let i;typeof e=="string"&&/(any|play|muted)/.test(e)||e===!0&&this.options_.normalizeAutoplay?(this.options_.autoplay=e,this.manualAutoplay_(typeof e=="string"?e:"play"),i=!1):e?this.options_.autoplay=!0:this.options_.autoplay=!1,i=typeof i>"u"?this.options_.autoplay:i,this.tech_&&this.techCall_("setAutoplay",i)}playsinline(e){return e!==void 0&&(this.techCall_("setPlaysinline",e),this.options_.playsinline=e),this.techGet_("playsinline")}loop(e){if(e!==void 0){this.techCall_("setLoop",e),this.options_.loop=e;return}return this.techGet_("loop")}poster(e){if(e===void 0)return this.poster_;e||(e=""),e!==this.poster_&&(this.poster_=e,this.techCall_("setPoster",e),this.isPosterFromTech_=!1,this.trigger("posterchange"))}handleTechPosterChange_(){if((!this.poster_||this.options_.techCanOverridePoster)&&this.tech_&&this.tech_.poster){const e=this.tech_.poster()||"";e!==this.poster_&&(this.poster_=e,this.isPosterFromTech_=!0,this.trigger("posterchange"))}}controls(e){if(e===void 0)return!!this.controls_;e=!!e,this.controls_!==e&&(this.controls_=e,this.usingNativeControls()&&this.techCall_("setControls",e),this.controls_?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.addTechControlsListeners_()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.removeTechControlsListeners_()))}usingNativeControls(e){if(e===void 0)return!!this.usingNativeControls_;e=!!e,this.usingNativeControls_!==e&&(this.usingNativeControls_=e,this.usingNativeControls_?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols")))}error(e){if(e===void 0)return this.error_||null;if(_n("beforeerror").forEach(i=>{const r=i(this,e);if(!(zi(r)&&!Array.isArray(r)||typeof r=="string"||typeof r=="number"||r===null)){this.log.error("please return a value that MediaError expects in beforeerror hooks");return}e=r}),this.options_.suppressNotSupportedError&&e&&e.code===4){const i=function(){this.error(e)};this.options_.suppressNotSupportedError=!1,this.any(["click","touchstart"],i),this.one("loadstart",function(){this.off(["click","touchstart"],i)});return}if(e===null){this.error_=null,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close();return}this.error_=new pt(e),this.addClass("vjs-error"),Ge.error(`(CODE:${this.error_.code} ${pt.errorTypes[this.error_.code]})`,this.error_.message,this.error_),this.trigger("error"),_n("error").forEach(i=>i(this,this.error_))}reportUserActivity(e){this.userActivity_=!0}userActive(e){if(e===void 0)return this.userActive_;if(e=!!e,e!==this.userActive_){if(this.userActive_=e,this.userActive_){this.userActivity_=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive");return}this.tech_&&this.tech_.one("mousemove",function(i){i.stopPropagation(),i.preventDefault()}),this.userActivity_=!1,this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive")}}listenForUserActivity_(){let e,i,r;const a=lt(this,this.reportUserActivity),o=function(y){(y.screenX!==i||y.screenY!==r)&&(i=y.screenX,r=y.screenY,a())},l=function(){a(),this.clearInterval(e),e=this.setInterval(a,250)},u=function(y){a(),this.clearInterval(e)};this.on("mousedown",l),this.on("mousemove",o),this.on("mouseup",u),this.on("mouseleave",u);const d=this.getChild("controlBar");d&&!$t&&!Bi&&(d.on("mouseenter",function(y){this.player().options_.inactivityTimeout!==0&&(this.player().cache_.inactivityTimeout=this.player().options_.inactivityTimeout),this.player().options_.inactivityTimeout=0}),d.on("mouseleave",function(y){this.player().options_.inactivityTimeout=this.player().cache_.inactivityTimeout})),this.on("keydown",a),this.on("keyup",a);let f;const g=function(){if(!this.userActivity_)return;this.userActivity_=!1,this.userActive(!0),this.clearTimeout(f);const y=this.options_.inactivityTimeout;y<=0||(f=this.setTimeout(function(){this.userActivity_||this.userActive(!1)},y))};this.setInterval(g,250)}playbackRate(e){if(e!==void 0){this.techCall_("setPlaybackRate",e);return}return this.tech_&&this.tech_.featuresPlaybackRate?this.cache_.lastPlaybackRate||this.techGet_("playbackRate"):1}defaultPlaybackRate(e){return e!==void 0?this.techCall_("setDefaultPlaybackRate",e):this.tech_&&this.tech_.featuresPlaybackRate?this.techGet_("defaultPlaybackRate"):1}isAudio(e){if(e!==void 0){this.isAudio_=!!e;return}return!!this.isAudio_}updatePlayerHeightOnAudioOnlyMode_(){const e=this.getChild("ControlBar");!e||this.audioOnlyCache_.controlBarHeight===e.currentHeight()||(this.audioOnlyCache_.controlBarHeight=e.currentHeight(),this.height(this.audioOnlyCache_.controlBarHeight))}enableAudioOnlyUI_(){this.addClass("vjs-audio-only-mode");const e=this.children(),i=this.getChild("ControlBar"),r=i&&i.currentHeight();e.forEach(a=>{a!==i&&a.el_&&!a.hasClass("vjs-hidden")&&(a.hide(),this.audioOnlyCache_.hiddenChildren.push(a))}),this.audioOnlyCache_.playerHeight=this.currentHeight(),this.audioOnlyCache_.controlBarHeight=r,this.on("playerresize",this.boundUpdatePlayerHeightOnAudioOnlyMode_),this.height(r),this.trigger("audioonlymodechange")}disableAudioOnlyUI_(){this.removeClass("vjs-audio-only-mode"),this.off("playerresize",this.boundUpdatePlayerHeightOnAudioOnlyMode_),this.audioOnlyCache_.hiddenChildren.forEach(e=>e.show()),this.height(this.audioOnlyCache_.playerHeight),this.trigger("audioonlymodechange")}audioOnlyMode(e){if(typeof e!="boolean"||e===this.audioOnlyMode_)return this.audioOnlyMode_;if(this.audioOnlyMode_=e,e){const i=[];return this.isInPictureInPicture()&&i.push(this.exitPictureInPicture()),this.isFullscreen()&&i.push(this.exitFullscreen()),this.audioPosterMode()&&i.push(this.audioPosterMode(!1)),Promise.all(i).then(()=>this.enableAudioOnlyUI_())}return Promise.resolve().then(()=>this.disableAudioOnlyUI_())}enablePosterModeUI_(){(this.tech_&&this.tech_).hide(),this.addClass("vjs-audio-poster-mode"),this.trigger("audiopostermodechange")}disablePosterModeUI_(){(this.tech_&&this.tech_).show(),this.removeClass("vjs-audio-poster-mode"),this.trigger("audiopostermodechange")}audioPosterMode(e){return typeof e!="boolean"||e===this.audioPosterMode_?this.audioPosterMode_:(this.audioPosterMode_=e,e?this.audioOnlyMode()?this.audioOnlyMode(!1).then(()=>{this.enablePosterModeUI_()}):Promise.resolve().then(()=>{this.enablePosterModeUI_()}):Promise.resolve().then(()=>{this.disablePosterModeUI_()}))}addTextTrack(e,i,r){if(this.tech_)return this.tech_.addTextTrack(e,i,r)}addRemoteTextTrack(e,i){if(this.tech_)return this.tech_.addRemoteTextTrack(e,i)}removeRemoteTextTrack(e={}){let{track:i}=e;if(i||(i=e),this.tech_)return this.tech_.removeRemoteTextTrack(i)}getVideoPlaybackQuality(){return this.techGet_("getVideoPlaybackQuality")}videoWidth(){return this.tech_&&this.tech_.videoWidth&&this.tech_.videoWidth()||0}videoHeight(){return this.tech_&&this.tech_.videoHeight&&this.tech_.videoHeight()||0}language(e){if(e===void 0)return this.language_;this.language_!==String(e).toLowerCase()&&(this.language_=String(e).toLowerCase(),rn(this)&&this.trigger("languagechange"))}languages(){return rt(tt.prototype.options_.languages,this.languages_)}toJSON(){const e=rt(this.options_),i=e.tracks;e.tracks=[];for(let r=0;r<i.length;r++){let a=i[r];a=rt(a),a.player=void 0,e.tracks[r]=a}return e}createModal(e,i){i=i||{},i.content=e||"";const r=new yr(this,i);return this.addChild(r),r.on("dispose",()=>{this.removeChild(r)}),r.open(),r}updateCurrentBreakpoint_(){if(!this.responsive())return;const e=this.currentBreakpoint(),i=this.currentWidth();for(let r=0;r<pl.length;r++){const a=pl[r],o=this.breakpoints_[a];if(i<=o){if(e===a)return;e&&this.removeClass(Js[e]),this.addClass(Js[a]),this.breakpoint_=a;break}}}removeCurrentBreakpoint_(){const e=this.currentBreakpointClass();this.breakpoint_="",e&&this.removeClass(e)}breakpoints(e){return e===void 0?Object.assign(this.breakpoints_):(this.breakpoint_="",this.breakpoints_=Object.assign({},Px,e),this.updateCurrentBreakpoint_(),Object.assign(this.breakpoints_))}responsive(e){if(e===void 0)return this.responsive_;e=!!e;const i=this.responsive_;if(e!==i)return this.responsive_=e,e?(this.on("playerresize",this.boundUpdateCurrentBreakpoint_),this.updateCurrentBreakpoint_()):(this.off("playerresize",this.boundUpdateCurrentBreakpoint_),this.removeCurrentBreakpoint_()),e}currentBreakpoint(){return this.breakpoint_}currentBreakpointClass(){return Js[this.breakpoint_]||""}loadMedia(e,i){if(!e||typeof e!="object")return;const r=this.crossOrigin();this.reset(),this.cache_.media=rt(e);const{artist:a,artwork:o,description:l,poster:u,src:d,textTracks:f,title:g}=this.cache_.media;!o&&u&&(this.cache_.media.artwork=[{src:u,type:ma(u)}]),r&&this.crossOrigin(r),d&&this.src(d),u&&this.poster(u),Array.isArray(f)&&f.forEach(y=>this.addRemoteTextTrack(y,!1)),this.titleBar&&this.titleBar.update({title:g,description:l||a||""}),this.ready(i)}getMedia(){if(!this.cache_.media){const e=this.poster(),i=this.currentSources(),r=Array.prototype.map.call(this.remoteTextTracks(),o=>({kind:o.kind,label:o.label,language:o.language,src:o.src})),a={src:i,textTracks:r};return e&&(a.poster=e,a.artwork=[{src:a.poster,type:ma(a.poster)}]),a}return rt(this.cache_.media)}static getTagSettings(e){const i={sources:[],tracks:[]},r=hn(e),a=r["data-setup"];if(Qr(e,"vjs-fill")&&(r.fill=!0),Qr(e,"vjs-fluid")&&(r.fluid=!0),a!==null)try{Object.assign(r,JSON.parse(a||"{}"))}catch(o){Ge.error("data-setup",o)}if(Object.assign(i,r),e.hasChildNodes()){const o=e.childNodes;for(let l=0,u=o.length;l<u;l++){const d=o[l],f=d.nodeName.toLowerCase();f==="source"?i.sources.push(hn(d)):f==="track"&&i.tracks.push(hn(d))}}return i}debug(e){if(e===void 0)return this.debugEnabled_;e?(this.trigger("debugon"),this.previousLogLevel_=this.log.level,this.log.level("debug"),this.debugEnabled_=!0):(this.trigger("debugoff"),this.log.level(this.previousLogLevel_),this.previousLogLevel_=void 0,this.debugEnabled_=!1)}playbackRates(e){if(e===void 0)return this.cache_.playbackRates;Array.isArray(e)&&e.every(i=>typeof i=="number")&&(this.cache_.playbackRates=e,this.trigger("playbackrateschange"))}}tt.prototype.videoTracks=()=>{};tt.prototype.audioTracks=()=>{};tt.prototype.textTracks=()=>{};tt.prototype.remoteTextTracks=()=>{};tt.prototype.remoteTextTrackEls=()=>{};Qt.names.forEach(function(s){const e=Qt[s];tt.prototype[e.getterName]=function(){return this.tech_?this.tech_[e.getterName]():(this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName])}});tt.prototype.crossorigin=tt.prototype.crossOrigin;tt.players={};const Hr=W.navigator;tt.prototype.options_={techOrder:Re.defaultTechOrder_,html5:{},enableSourceset:!0,inactivityTimeout:2e3,playbackRates:[],liveui:!1,children:["mediaLoader","posterImage","titleBar","textTrackDisplay","loadingSpinner","bigPlayButton","liveTracker","controlBar","errorDisplay","textTrackSettings","resizeManager"],language:Hr&&(Hr.languages&&Hr.languages[0]||Hr.userLanguage||Hr.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",normalizeAutoplay:!1,fullscreen:{options:{navigationUI:"hide"}},breakpoints:{},responsive:!1,audioOnlyMode:!1,audioPosterMode:!1,spatialNavigation:{enabled:!1,horizontalSeek:!1},enableSmoothSeeking:!1,disableSeekWhileScrubbingOnMobile:!1,disableSeekWhileScrubbingOnSTV:!1};of.forEach(function(s){tt.prototype[`handleTech${gt(s)}_`]=function(){return this.trigger(s)}});oe.registerComponent("Player",tt);const ga="plugin",Jn="activePlugins_",Gn={},_a=s=>Gn.hasOwnProperty(s),ea=s=>_a(s)?Gn[s]:void 0,lf=(s,e)=>{s[Jn]=s[Jn]||{},s[Jn][e]=!0},ya=(s,e,i)=>{const r=(i?"before":"")+"pluginsetup";s.trigger(r,e),s.trigger(r+":"+e.name,e)},Mx=function(s,e){const i=function(){ya(this,{name:s,plugin:e,instance:null},!0);const r=e.apply(this,arguments);return lf(this,s),ya(this,{name:s,plugin:e,instance:r}),r};return Object.keys(e).forEach(function(r){i[r]=e[r]}),i},Pd=(s,e)=>(e.prototype.name=s,function(...i){ya(this,{name:s,plugin:e,instance:null},!0);const r=new e(this,...i);return this[s]=()=>r,ya(this,r.getEventHash()),r});class oi{constructor(e){if(this.constructor===oi)throw new Error("Plugin must be sub-classed; not directly instantiated.");this.player=e,this.log||(this.log=this.player.log.createLogger(this.name)),ql(this),delete this.trigger,v0(this,this.constructor.defaultState),lf(e,this.name),this.dispose=this.dispose.bind(this),e.on("dispose",this.dispose)}version(){return this.constructor.VERSION}getEventHash(e={}){return e.name=this.name,e.plugin=this.constructor,e.instance=this,e}trigger(e,i={}){return _r(this.eventBusEl_,e,this.getEventHash(i))}handleStateChanged(e){}dispose(){const{name:e,player:i}=this;this.trigger("dispose"),this.off(),i.off("dispose",this.dispose),i[Jn][e]=!1,this.player=this.state=null,i[e]=Pd(e,Gn[e])}static isBasic(e){const i=typeof e=="string"?ea(e):e;return typeof i=="function"&&!oi.prototype.isPrototypeOf(i.prototype)}static registerPlugin(e,i){if(typeof e!="string")throw new Error(`Illegal plugin name, "${e}", must be a string, was ${typeof e}.`);if(_a(e))Ge.warn(`A plugin named "${e}" already exists. You may want to avoid re-registering plugins!`);else if(tt.prototype.hasOwnProperty(e))throw new Error(`Illegal plugin name, "${e}", cannot share a name with an existing player method!`);if(typeof i!="function")throw new Error(`Illegal plugin for "${e}", must be a function, was ${typeof i}.`);return Gn[e]=i,e!==ga&&(oi.isBasic(i)?tt.prototype[e]=Mx(e,i):tt.prototype[e]=Pd(e,i)),i}static deregisterPlugin(e){if(e===ga)throw new Error("Cannot de-register base plugin.");_a(e)&&(delete Gn[e],delete tt.prototype[e])}static getPlugins(e=Object.keys(Gn)){let i;return e.forEach(r=>{const a=ea(r);a&&(i=i||{},i[r]=a)}),i}static getPluginVersion(e){const i=ea(e);return i&&i.VERSION||""}}oi.getPlugin=ea;oi.BASE_PLUGIN_NAME=ga;oi.registerPlugin(ga,oi);tt.prototype.usingPlugin=function(s){return!!this[Jn]&&this[Jn][s]===!0};tt.prototype.hasPlugin=function(s){return!!_a(s)};function Rx(s,e){let i=!1;return function(...r){return i||Ge.warn(s),i=!0,e.apply(this,r)}}function Li(s,e,i,r){return Rx(`${e} is deprecated and will be removed in ${s}.0; please use ${i} instead.`,r)}var Vx={NetworkBadStatus:"networkbadstatus",NetworkRequestFailed:"networkrequestfailed",NetworkRequestAborted:"networkrequestaborted",NetworkRequestTimeout:"networkrequesttimeout",NetworkBodyParserFailed:"networkbodyparserfailed",StreamingHlsPlaylistParserError:"streaminghlsplaylistparsererror",StreamingDashManifestParserError:"streamingdashmanifestparsererror",StreamingContentSteeringParserError:"streamingcontentsteeringparsererror",StreamingVttParserError:"streamingvttparsererror",StreamingFailedToSelectNextSegment:"streamingfailedtoselectnextsegment",StreamingFailedToDecryptSegment:"streamingfailedtodecryptsegment",StreamingFailedToTransmuxSegment:"streamingfailedtotransmuxsegment",StreamingFailedToAppendSegment:"streamingfailedtoappendsegment",StreamingCodecsChangeError:"streamingcodecschangeerror"};const uf=s=>s.indexOf("#")===0?s.slice(1):s;function ne(s,e,i){let r=ne.getPlayer(s);if(r)return e&&Ge.warn(`Player "${s}" is already initialised. Options will not be applied.`),i&&r.ready(i),r;const a=typeof s=="string"?yn("#"+uf(s)):s;if(!gr(a))throw new TypeError("The element or ID supplied is not valid. (videojs)");const l=("getRootNode"in a?a.getRootNode()instanceof W.ShadowRoot:!1)?a.getRootNode():a.ownerDocument.body;(!a.ownerDocument.defaultView||!l.contains(a))&&Ge.warn("The element supplied is not included in the DOM"),e=e||{},e.restoreEl===!0&&(e.restoreEl=(a.parentNode&&a.parentNode.hasAttribute&&a.parentNode.hasAttribute("data-vjs-player")?a.parentNode:a).cloneNode(!0)),_n("beforesetup").forEach(d=>{const f=d(a,rt(e));if(!zi(f)||Array.isArray(f)){Ge.error("please return an object in beforesetup hooks");return}e=rt(e,f)});const u=oe.getComponent("Player");return r=new u(a,e,i),_n("setup").forEach(d=>d(r)),r}ne.hooks_=en;ne.hooks=_n;ne.hook=y8;ne.hookOnce=v8;ne.removeHook=Hh;if(W.VIDEOJS_NO_DYNAMIC_STYLE!==!0&&mr()){let s=yn(".vjs-styles-defaults");if(!s){s=p0("vjs-styles-defaults");const e=yn("head");e&&e.insertBefore(s,e.firstChild),m0(s,`
|
|
192
|
+
.video-js {
|
|
193
|
+
width: 300px;
|
|
194
|
+
height: 150px;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
.vjs-fluid:not(.vjs-audio-only-mode) {
|
|
198
|
+
padding-top: 56.25%
|
|
199
|
+
}
|
|
200
|
+
`)}}ol(1,ne);ne.VERSION=nl;ne.options=tt.prototype.options_;ne.getPlayers=()=>tt.players;ne.getPlayer=s=>{const e=tt.players;let i;if(typeof s=="string"){const r=uf(s),a=e[r];if(a)return a;i=yn("#"+r)}else i=s;if(gr(i)){const{player:r,playerId:a}=i;if(r||e[a])return r||e[a]}};ne.getAllPlayers=()=>Object.keys(tt.players).map(s=>tt.players[s]).filter(Boolean);ne.players=tt.players;ne.getComponent=oe.getComponent;ne.registerComponent=(s,e)=>(Re.isTech(e)&&Ge.warn(`The ${s} tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)`),oe.registerComponent.call(oe,s,e));ne.getTech=Re.getTech;ne.registerTech=Re.registerTech;ne.use=G8;Object.defineProperty(ne,"middleware",{value:{},writeable:!1,enumerable:!0});Object.defineProperty(ne.middleware,"TERMINATOR",{value:pa,writeable:!1,enumerable:!0});ne.browser=Jh;ne.obj=x8;ne.mergeOptions=Li(9,"videojs.mergeOptions","videojs.obj.merge",rt);ne.defineLazyProperty=Li(9,"videojs.defineLazyProperty","videojs.obj.defineLazyProperty",Aa);ne.bind=Li(9,"videojs.bind","native Function.prototype.bind",lt);ne.registerPlugin=oi.registerPlugin;ne.deregisterPlugin=oi.deregisterPlugin;ne.plugin=(s,e)=>(Ge.warn("videojs.plugin() is deprecated; use videojs.registerPlugin() instead"),oi.registerPlugin(s,e));ne.getPlugins=oi.getPlugins;ne.getPlugin=oi.getPlugin;ne.getPluginVersion=oi.getPluginVersion;ne.addLanguage=function(s,e){return s=(""+s).toLowerCase(),ne.options.languages=rt(ne.options.languages,{[s]:e}),ne.options.languages[s]};ne.log=Ge;ne.createLogger=zh;ne.time=R8;ne.createTimeRange=Li(9,"videojs.createTimeRange","videojs.time.createTimeRanges",Oi);ne.createTimeRanges=Li(9,"videojs.createTimeRanges","videojs.time.createTimeRanges",Oi);ne.formatTime=Li(9,"videojs.formatTime","videojs.time.formatTime",Rn);ne.setFormatTime=Li(9,"videojs.setFormatTime","videojs.time.setFormatTime",x0);ne.resetFormatTime=Li(9,"videojs.resetFormatTime","videojs.time.resetFormatTime",C0);ne.parseUrl=Li(9,"videojs.parseUrl","videojs.url.parseUrl",Gl);ne.isCrossOrigin=Li(9,"videojs.isCrossOrigin","videojs.url.isCrossOrigin",Ua);ne.EventTarget=pi;ne.any=Ul;ne.on=fi;ne.one=Fa;ne.off=Ut;ne.trigger=_r;ne.xhr=Ah;ne.TrackList=Vn;ne.TextTrack=ls;ne.TextTrackList=Hl;ne.AudioTrack=D0;ne.AudioTrackList=E0;ne.VideoTrack=A0;ne.VideoTrackList=k0;["isEl","isTextNode","createEl","hasClass","addClass","removeClass","toggleClass","setAttributes","getAttributes","emptyEl","appendContent","insertContent"].forEach(s=>{ne[s]=function(){return Ge.warn(`videojs.${s}() is deprecated; use videojs.dom.${s}() instead`),h0[s].apply(null,arguments)}});ne.computedStyle=Li(9,"videojs.computedStyle","videojs.dom.computedStyle",hr);ne.dom=h0;ne.fn=N8;ne.num=fx;ne.str=P8;ne.url=H8;ne.Error=Vx;/*! @name videojs-contrib-quality-levels @version 4.1.0 @license Apache-2.0 */class Fx{constructor(e){let i=this;return i.id=e.id,i.label=i.id,i.width=e.width,i.height=e.height,i.bitrate=e.bandwidth,i.frameRate=e.frameRate,i.enabled_=e.enabled,Object.defineProperty(i,"enabled",{get(){return i.enabled_()},set(r){i.enabled_(r)}}),i}}class va extends ne.EventTarget{constructor(){super();let e=this;return e.levels_=[],e.selectedIndex_=-1,Object.defineProperty(e,"selectedIndex",{get(){return e.selectedIndex_}}),Object.defineProperty(e,"length",{get(){return e.levels_.length}}),e[Symbol.iterator]=()=>e.levels_.values(),e}addQualityLevel(e){let i=this.getQualityLevelById(e.id);if(i)return i;const r=this.levels_.length;return i=new Fx(e),""+r in this||Object.defineProperty(this,r,{get(){return this.levels_[r]}}),this.levels_.push(i),this.trigger({qualityLevel:i,type:"addqualitylevel"}),i}removeQualityLevel(e){let i=null;for(let r=0,a=this.length;r<a;r++)if(this[r]===e){i=this.levels_.splice(r,1)[0],this.selectedIndex_===r?this.selectedIndex_=-1:this.selectedIndex_>r&&this.selectedIndex_--;break}return i&&this.trigger({qualityLevel:e,type:"removequalitylevel"}),i}getQualityLevelById(e){for(let i=0,r=this.length;i<r;i++){const a=this[i];if(a.id===e)return a}return null}dispose(){this.selectedIndex_=-1,this.levels_.length=0}}va.prototype.allowedEvents_={change:"change",addqualitylevel:"addqualitylevel",removequalitylevel:"removequalitylevel"};for(const s in va.prototype.allowedEvents_)va.prototype["on"+s]=null;var cf="4.1.0";const $x=function(s,e){const i=s.qualityLevels,r=new va,a=function(){r.dispose(),s.qualityLevels=i,s.off("dispose",a)};return s.on("dispose",a),s.qualityLevels=()=>r,s.qualityLevels.VERSION=cf,r},df=function(s){return $x(this,ne.obj.merge({},s))};ne.registerPlugin("qualityLevels",df);df.VERSION=cf;/*! @name @videojs/http-streaming @version 3.17.3 @license Apache-2.0 */const si=Ea,Ta=(s,e)=>e&&e.responseURL&&s!==e.responseURL?e.responseURL:s,bi=s=>ne.log.debug?ne.log.debug.bind(ne,"VHS:",`${s} >`):function(){};function it(...s){const e=ne.obj||ne;return(e.merge||e.mergeOptions).apply(e,s)}function Nt(...s){const e=ne.time||ne;return(e.createTimeRanges||e.createTimeRanges).apply(e,s)}function Ux(s){if(s.length===0)return"Buffered Ranges are empty";let e=`Buffered Ranges:
|
|
201
|
+
`;for(let i=0;i<s.length;i++){const r=s.start(i),a=s.end(i);e+=`${r} --> ${a}. Duration (${a-r})
|
|
202
|
+
`}return e}const qi=1/30,ji=qi*3,hf=function(s,e){const i=[];let r;if(s&&s.length)for(r=0;r<s.length;r++)e(s.start(r),s.end(r))&&i.push([s.start(r),s.end(r)]);return Nt(i)},Wn=function(s,e){return hf(s,function(i,r){return i-ji<=e&&r+ji>=e})},js=function(s,e){return hf(s,function(i){return i-qi>=e})},qx=function(s){if(s.length<2)return Nt();const e=[];for(let i=1;i<s.length;i++){const r=s.end(i-1),a=s.start(i);e.push([r,a])}return Nt(e)},jx=function(s,e){let i=null,r=null,a=0;const o=[],l=[];if(!s||!s.length||!e||!e.length)return Nt();let u=s.length;for(;u--;)o.push({time:s.start(u),type:"start"}),o.push({time:s.end(u),type:"end"});for(u=e.length;u--;)o.push({time:e.start(u),type:"start"}),o.push({time:e.end(u),type:"end"});for(o.sort(function(d,f){return d.time-f.time}),u=0;u<o.length;u++)o[u].type==="start"?(a++,a===2&&(i=o[u].time)):o[u].type==="end"&&(a--,a===1&&(r=o[u].time)),i!==null&&r!==null&&(l.push([i,r]),i=null,r=null);return Nt(l)},ff=s=>{const e=[];if(!s||!s.length)return"";for(let i=0;i<s.length;i++)e.push(s.start(i)+" => "+s.end(i));return e.join(", ")},Hx=function(s,e,i=1){return((s.length?s.end(s.length-1):0)-e)/i},An=s=>{const e=[];for(let i=0;i<s.length;i++)e.push({start:s.start(i),end:s.end(i)});return e},zx=function(s,e){if(s===e)return!1;if(!s&&e||!e&&s||s.length!==e.length)return!0;for(let i=0;i<s.length;i++)if(s.start(i)!==e.start(i)||s.end(i)!==e.end(i))return!0;return!1},Go=function(s){if(!(!s||!s.length||!s.end))return s.end(s.length-1)},uu=function(s,e){let i=0;if(!s||!s.length)return i;for(let r=0;r<s.length;r++){const a=s.start(r),o=s.end(r);if(!(e>o)){if(e>a&&e<=o){i+=o-e;continue}i+=o-a}}return i},cu=(s,e)=>{if(!e.preload)return e.duration;let i=0;return(e.parts||[]).forEach(function(r){i+=r.duration}),(e.preloadHints||[]).forEach(function(r){r.type==="PART"&&(i+=s.partTargetDuration)}),i},ml=s=>(s.segments||[]).reduce((e,i,r)=>(i.parts?i.parts.forEach(function(a,o){e.push({duration:a.duration,segmentIndex:r,partIndex:o,part:a,segment:i})}):e.push({duration:i.duration,segmentIndex:r,partIndex:null,segment:i,part:null}),e),[]),pf=s=>{const e=s.segments&&s.segments.length&&s.segments[s.segments.length-1];return e&&e.parts||[]},mf=({preloadSegment:s})=>{if(!s)return;const{parts:e,preloadHints:i}=s;let r=(i||[]).reduce((a,o)=>a+(o.type==="PART"?1:0),0);return r+=e&&e.length?e.length:0,r},gf=(s,e)=>{if(e.endList)return 0;if(s&&s.suggestedPresentationDelay)return s.suggestedPresentationDelay;const i=pf(e).length>0;return i&&e.serverControl&&e.serverControl.partHoldBack?e.serverControl.partHoldBack:i&&e.partTargetDuration?e.partTargetDuration*3:e.serverControl&&e.serverControl.holdBack?e.serverControl.holdBack:e.targetDuration?e.targetDuration*3:0},Gx=function(s,e){let i=0,r=e-s.mediaSequence,a=s.segments[r];if(a){if(typeof a.start<"u")return{result:a.start,precise:!0};if(typeof a.end<"u")return{result:a.end-a.duration,precise:!0}}for(;r--;){if(a=s.segments[r],typeof a.end<"u")return{result:i+a.end,precise:!0};if(i+=cu(s,a),typeof a.start<"u")return{result:i+a.start,precise:!0}}return{result:i,precise:!1}},Wx=function(s,e){let i=0,r,a=e-s.mediaSequence;for(;a<s.segments.length;a++){if(r=s.segments[a],typeof r.start<"u")return{result:r.start-i,precise:!0};if(i+=cu(s,r),typeof r.end<"u")return{result:r.end-i,precise:!0}}return{result:-1,precise:!1}},_f=function(s,e,i){if(typeof e>"u"&&(e=s.mediaSequence+s.segments.length),e<s.mediaSequence)return 0;const r=Gx(s,e);if(r.precise)return r.result;const a=Wx(s,e);return a.precise?a.result:r.result+i},yf=function(s,e,i){if(!s)return 0;if(typeof i!="number"&&(i=0),typeof e>"u"){if(s.totalDuration)return s.totalDuration;if(!s.endList)return W.Infinity}return _f(s,e,i)},es=function({defaultDuration:s,durationList:e,startIndex:i,endIndex:r}){let a=0;if(i>r&&([i,r]=[r,i]),i<0){for(let o=i;o<Math.min(0,r);o++)a+=s;i=0}for(let o=i;o<r;o++)a+=e[o].duration;return a},vf=function(s,e,i,r){if(!s||!s.segments)return null;if(s.endList)return yf(s);if(e===null)return null;e=e||0;let a=_f(s,s.mediaSequence+s.segments.length,e);return i&&(r=typeof r=="number"?r:gf(null,s),a-=r),Math.max(0,a)},Yx=function(s,e,i){const a=e||0;let o=vf(s,e,!0,i);return o===null?Nt():(o<a&&(o=a),Nt(a,o))},Xx=function({playlist:s,currentTime:e,startingSegmentIndex:i,startingPartIndex:r,startTime:a,exactManifestTimings:o}){let l=e-a;const u=ml(s);let d=0;for(let f=0;f<u.length;f++){const g=u[f];if(i===g.segmentIndex&&!(typeof r=="number"&&typeof g.partIndex=="number"&&r!==g.partIndex)){d=f;break}}if(l<0){if(d>0)for(let f=d-1;f>=0;f--){const g=u[f];if(l+=g.duration,o){if(l<0)continue}else if(l+qi<=0)continue;return{partIndex:g.partIndex,segmentIndex:g.segmentIndex,startTime:a-es({defaultDuration:s.targetDuration,durationList:u,startIndex:d,endIndex:f})}}return{partIndex:u[0]&&u[0].partIndex||null,segmentIndex:u[0]&&u[0].segmentIndex||0,startTime:e}}if(d<0){for(let f=d;f<0;f++)if(l-=s.targetDuration,l<0)return{partIndex:u[0]&&u[0].partIndex||null,segmentIndex:u[0]&&u[0].segmentIndex||0,startTime:e};d=0}for(let f=d;f<u.length;f++){const g=u[f];l-=g.duration;const y=g.duration>qi,E=l===0,x=y&&l+qi>=0;if(!((E||x)&&f!==u.length-1)){if(o){if(l>0)continue}else if(l-qi>=0)continue;return{partIndex:g.partIndex,segmentIndex:g.segmentIndex,startTime:a+es({defaultDuration:s.targetDuration,durationList:u,startIndex:d,endIndex:f})}}}return{segmentIndex:u[u.length-1].segmentIndex,partIndex:u[u.length-1].partIndex,startTime:e}},Tf=function(s){return s.excludeUntil&&s.excludeUntil>Date.now()},du=function(s){return s.excludeUntil&&s.excludeUntil===1/0},za=function(s){const e=Tf(s);return!s.disabled&&!e},Kx=function(s){return s.disabled},Qx=function(s){for(let e=0;e<s.segments.length;e++)if(s.segments[e].key)return!0;return!1},bf=function(s,e){return e.attributes&&e.attributes[s]},Zx=function(s,e,i,r=0){return bf("BANDWIDTH",i)?(s*i.attributes.BANDWIDTH-r*8)/e:NaN},gl=(s,e)=>{if(s.playlists.length===1)return!0;const i=e.attributes.BANDWIDTH||Number.MAX_VALUE;return s.playlists.filter(r=>za(r)?(r.attributes.BANDWIDTH||0)<i:!1).length===0},hu=(s,e)=>!s&&!e||!s&&e||s&&!e?!1:!!(s===e||s.id&&e.id&&s.id===e.id||s.resolvedUri&&e.resolvedUri&&s.resolvedUri===e.resolvedUri||s.uri&&e.uri&&s.uri===e.uri),Md=function(s,e){const i=s&&s.mediaGroups&&s.mediaGroups.AUDIO||{};let r=!1;for(const a in i){for(const o in i[a])if(r=e(i[a][o]),r)break;if(r)break}return!!r},hs=s=>{if(!s||!s.playlists||!s.playlists.length)return Md(s,i=>i.playlists&&i.playlists.length||i.uri);for(let e=0;e<s.playlists.length;e++){const i=s.playlists[e],r=i.attributes&&i.attributes.CODECS;if(!(r&&r.split(",").every(o=>Oh(o))||Md(s,o=>hu(i,o))))return!1}return!0};var ai={liveEdgeDelay:gf,duration:yf,seekable:Yx,getMediaInfoForTime:Xx,isEnabled:za,isDisabled:Kx,isExcluded:Tf,isIncompatible:du,playlistEnd:vf,isAes:Qx,hasAttribute:bf,estimateSegmentRequestTime:Zx,isLowestEnabledRendition:gl,isAudioOnly:hs,playlistMatch:hu,segmentDurationWithParts:cu};const{log:xf}=ne,er=(s,e)=>`${s}-${e}`,Cf=(s,e,i)=>`placeholder-uri-${s}-${e}-${i}`,Jx=({onwarn:s,oninfo:e,manifestString:i,customTagParsers:r=[],customTagMappers:a=[],llhls:o})=>{const l=new $b;s&&l.on("warn",s),e&&l.on("info",e),r.forEach(f=>l.addParser(f)),a.forEach(f=>l.addTagMapper(f)),l.push(i),l.end();const u=l.manifest;if(o||(["preloadSegment","skip","serverControl","renditionReports","partInf","partTargetDuration"].forEach(function(f){u.hasOwnProperty(f)&&delete u[f]}),u.segments&&u.segments.forEach(function(f){["parts","preloadHints"].forEach(function(g){f.hasOwnProperty(g)&&delete f[g]})})),!u.targetDuration){let f=10;u.segments&&u.segments.length&&(f=u.segments.reduce((g,y)=>Math.max(g,y.duration),0)),s&&s({message:`manifest has no targetDuration defaulting to ${f}`}),u.targetDuration=f}const d=pf(u);if(d.length&&!u.partTargetDuration){const f=d.reduce((g,y)=>Math.max(g,y.duration),0);s&&(s({message:`manifest has no partTargetDuration defaulting to ${f}`}),xf.error("LL-HLS manifest has parts but lacks required #EXT-X-PART-INF:PART-TARGET value. See https://datatracker.ietf.org/doc/html/draft-pantos-hls-rfc8216bis-09#section-4.4.3.7. Playback is not guaranteed.")),u.partTargetDuration=f}return u},br=(s,e)=>{s.mediaGroups&&["AUDIO","SUBTITLES"].forEach(i=>{if(s.mediaGroups[i])for(const r in s.mediaGroups[i])for(const a in s.mediaGroups[i][r]){const o=s.mediaGroups[i][r][a];e(o,i,r,a)}})},Sf=({playlist:s,uri:e,id:i})=>{s.id=i,s.playlistErrors_=0,e&&(s.uri=e),s.attributes=s.attributes||{}},eC=s=>{let e=s.playlists.length;for(;e--;){const i=s.playlists[e];Sf({playlist:i,id:er(e,i.uri)}),i.resolvedUri=si(s.uri,i.uri),s.playlists[i.id]=i,s.playlists[i.uri]=i,i.attributes.BANDWIDTH||xf.warn("Invalid playlist STREAM-INF detected. Missing BANDWIDTH attribute.")}},tC=s=>{br(s,e=>{e.uri&&(e.resolvedUri=si(s.uri,e.uri))})},iC=(s,e)=>{const i=er(0,e),r={mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:W.location.href,resolvedUri:W.location.href,playlists:[{uri:e,id:i,resolvedUri:e,attributes:{}}]};return r.playlists[i]=r.playlists[0],r.playlists[e]=r.playlists[0],r},Ef=(s,e,i=Cf)=>{s.uri=e;for(let a=0;a<s.playlists.length;a++)if(!s.playlists[a].uri){const o=`placeholder-uri-${a}`;s.playlists[a].uri=o}const r=hs(s);br(s,(a,o,l,u)=>{if(!a.playlists||!a.playlists.length){if(r&&o==="AUDIO"&&!a.uri)for(let d=0;d<s.playlists.length;d++){const f=s.playlists[d];if(f.attributes&&f.attributes.AUDIO&&f.attributes.AUDIO===l)return}a.playlists=[bt({},a)]}a.playlists.forEach(function(d,f){const g=i(o,l,u,d),y=er(f,g);d.uri?d.resolvedUri=d.resolvedUri||si(s.uri,d.uri):(d.uri=f===0?g:y,d.resolvedUri=d.uri),d.id=d.id||y,d.attributes=d.attributes||{},s.playlists[d.id]=d,s.playlists[d.uri]=d})}),eC(s),tC(s)};class Rd{constructor(){this.offset_=null,this.pendingDateRanges_=new Map,this.processedDateRanges_=new Map}setOffset(e=[]){if(this.offset_!==null||!e.length)return;const[i]=e;i.programDateTime!==void 0&&(this.offset_=i.programDateTime/1e3)}setPendingDateRanges(e=[]){if(!e.length)return;const[i]=e,r=i.startDate.getTime();this.trimProcessedDateRanges_(r),this.pendingDateRanges_=e.reduce((a,o)=>(a.set(o.id,o),a),new Map)}processDateRange(e){this.pendingDateRanges_.delete(e.id),this.processedDateRanges_.set(e.id,e)}getDateRangesToProcess(){if(this.offset_===null)return[];const e={},i=[];this.pendingDateRanges_.forEach((r,a)=>{if(!this.processedDateRanges_.has(a)&&(r.startTime=r.startDate.getTime()/1e3-this.offset_,r.processDateRange=()=>this.processDateRange(r),i.push(r),!!r.class))if(e[r.class]){const o=e[r.class].push(r);r.classListIndex=o-1}else e[r.class]=[r],r.classListIndex=0});for(const r of i){const a=e[r.class]||[];r.endDate?r.endTime=r.endDate.getTime()/1e3-this.offset_:r.endOnNext&&a[r.classListIndex+1]?r.endTime=a[r.classListIndex+1].startTime:r.duration?r.endTime=r.startTime+r.duration:r.plannedDuration?r.endTime=r.startTime+r.plannedDuration:r.endTime=r.startTime}return i}trimProcessedDateRanges_(e){new Map(this.processedDateRanges_).forEach((r,a)=>{r.startDate.getTime()<e&&this.processedDateRanges_.delete(a)})}}const kf=22,Pn=({requestType:s,request:e,error:i,parseFailure:r})=>{const a=e.status<200||e.status>299,o=e.status>=400&&e.status<=499,l={uri:e.uri,requestType:s},u=a&&!o||r;if(i&&o)l.error=bt({},i),l.errorType=ne.Error.NetworkRequestFailed;else if(e.aborted)l.errorType=ne.Error.NetworkRequestAborted;else if(e.timedout)l.errorType=ne.Error.NetworkRequestTimeout;else if(u){const d=r?ne.Error.NetworkBodyParserFailed:ne.Error.NetworkBadStatus;l.errorType=d,l.status=e.status,l.headers=e.headers}return l},nC=bi("CodecUtils"),wf=function(s){const e=s.attributes||{};if(e.CODECS)return Fi(e.CODECS)},Df=(s,e)=>{const i=e.attributes||{};return s&&s.mediaGroups&&s.mediaGroups.AUDIO&&i.AUDIO&&s.mediaGroups.AUDIO[i.AUDIO]},rC=(s,e)=>{if(!Df(s,e))return!0;const i=e.attributes||{},r=s.mediaGroups.AUDIO[i.AUDIO];for(const a in r)if(!r[a].uri&&!r[a].playlists)return!0;return!1},as=function(s){const e={};return s.forEach(({mediaType:i,type:r,details:a})=>{e[i]=e[i]||[],e[i].push(Nh(`${r}${a}`))}),Object.keys(e).forEach(function(i){if(e[i].length>1){nC(`multiple ${i} codecs found as attributes: ${e[i].join(", ")}. Setting playlist codecs to null so that we wait for mux.js to probe segments for real codecs.`),e[i]=null;return}e[i]=e[i][0]}),e},Vd=function(s){let e=0;return s.audio&&e++,s.video&&e++,e},ts=function(s,e){const i=e.attributes||{},r=as(wf(e)||[]);if(Df(s,e)&&!r.audio&&!rC(s,e)){const a=as(qb(s,i.AUDIO)||[]);a.audio&&(r.audio=a.audio)}return r},{EventTarget:sC}=ne,aC=(s,e)=>{if(e.endList||!e.serverControl)return s;const i={};if(e.serverControl.canBlockReload){const{preloadSegment:r}=e;let a=e.mediaSequence+e.segments.length;if(r){const o=r.parts||[],l=mf(e)-1;l>-1&&l!==o.length-1&&(i._HLS_part=l),(l>-1||o.length)&&a--}i._HLS_msn=a}if(e.serverControl&&e.serverControl.canSkipUntil&&(i._HLS_skip=e.serverControl.canSkipDateranges?"v2":"YES"),Object.keys(i).length){const r=new W.URL(s);["_HLS_skip","_HLS_msn","_HLS_part"].forEach(function(a){i.hasOwnProperty(a)&&r.searchParams.set(a,i[a])}),s=r.toString()}return s},oC=(s,e)=>{if(!s)return e;const i=it(s,e);if(s.preloadHints&&!e.preloadHints&&delete i.preloadHints,s.parts&&!e.parts)delete i.parts;else if(s.parts&&e.parts)for(let r=0;r<e.parts.length;r++)s.parts&&s.parts[r]&&(i.parts[r]=it(s.parts[r],e.parts[r]));return!s.skipped&&e.skipped&&(i.skipped=!1),s.preload&&!e.preload&&(i.preload=!1),i},lC=(s,e,i)=>{const r=s.slice(),a=e.slice();i=i||0;const o=[];let l;for(let u=0;u<a.length;u++){const d=r[u+i],f=a[u];d?(l=d.map||l,o.push(oC(d,f))):(l&&!f.map&&(f.map=l),o.push(f))}return o},Af=(s,e)=>{!s.resolvedUri&&s.uri&&(s.resolvedUri=si(e,s.uri)),s.key&&!s.key.resolvedUri&&(s.key.resolvedUri=si(e,s.key.uri)),s.map&&!s.map.resolvedUri&&(s.map.resolvedUri=si(e,s.map.uri)),s.map&&s.map.key&&!s.map.key.resolvedUri&&(s.map.key.resolvedUri=si(e,s.map.key.uri)),s.parts&&s.parts.length&&s.parts.forEach(i=>{i.resolvedUri||(i.resolvedUri=si(e,i.uri))}),s.preloadHints&&s.preloadHints.length&&s.preloadHints.forEach(i=>{i.resolvedUri||(i.resolvedUri=si(e,i.uri))})},If=function(s){const e=s.segments||[],i=s.preloadSegment;if(i&&i.parts&&i.parts.length){if(i.preloadHints){for(let r=0;r<i.preloadHints.length;r++)if(i.preloadHints[r].type==="MAP")return e}i.duration=s.targetDuration,i.preload=!0,e.push(i)}return e},Nf=(s,e)=>s===e||s.segments&&e.segments&&s.segments.length===e.segments.length&&s.endList===e.endList&&s.mediaSequence===e.mediaSequence&&s.preloadSegment===e.preloadSegment,_l=(s,e,i=Nf)=>{const r=it(s,{}),a=r.playlists[e.id];if(!a||i(a,e))return null;e.segments=If(e);const o=it(a,e);if(o.preloadSegment&&!e.preloadSegment&&delete o.preloadSegment,a.segments){if(e.skip){e.segments=e.segments||[];for(let l=0;l<e.skip.skippedSegments;l++)e.segments.unshift({skipped:!0})}o.segments=lC(a.segments,e.segments,e.mediaSequence-a.mediaSequence)}o.segments.forEach(l=>{Af(l,o.resolvedUri)});for(let l=0;l<r.playlists.length;l++)r.playlists[l].id===e.id&&(r.playlists[l]=o);return r.playlists[e.id]=o,r.playlists[e.uri]=o,br(s,(l,u,d,f)=>{if(l.playlists)for(let g=0;g<l.playlists.length;g++)e.id===l.playlists[g].id&&(l.playlists[g]=o)}),r},yl=(s,e)=>{const i=s.segments||[],r=i[i.length-1],a=r&&r.parts&&r.parts[r.parts.length-1],o=a&&a.duration||r&&r.duration;return e&&o?o*1e3:(s.partTargetDuration||s.targetDuration||10)*500},Fd=(s,e,i)=>{if(!s)return;const r=[];return s.forEach(a=>{if(!a.attributes)return;const{BANDWIDTH:o,RESOLUTION:l,CODECS:u}=a.attributes;r.push({id:a.id,bandwidth:o,resolution:l,codecs:u})}),{type:e,isLive:i,renditions:r}};class Yn extends sC{constructor(e,i,r={}){if(super(),!e)throw new Error("A non-empty playlist URL or object is required");this.logger_=bi("PlaylistLoader");const{withCredentials:a=!1}=r;this.src=e,this.vhs_=i,this.withCredentials=a,this.addDateRangesToTextTrack_=r.addDateRangesToTextTrack;const o=i.options_;this.customTagParsers=o&&o.customTagParsers||[],this.customTagMappers=o&&o.customTagMappers||[],this.llhls=o&&o.llhls,this.dateRangesStorage_=new Rd,this.state="HAVE_NOTHING",this.handleMediaupdatetimeout_=this.handleMediaupdatetimeout_.bind(this),this.on("mediaupdatetimeout",this.handleMediaupdatetimeout_),this.on("loadedplaylist",this.handleLoadedPlaylist_.bind(this))}handleLoadedPlaylist_(){const e=this.media();if(!e)return;this.dateRangesStorage_.setOffset(e.segments),this.dateRangesStorage_.setPendingDateRanges(e.dateRanges);const i=this.dateRangesStorage_.getDateRangesToProcess();!i.length||!this.addDateRangesToTextTrack_||this.addDateRangesToTextTrack_(i)}handleMediaupdatetimeout_(){if(this.state!=="HAVE_METADATA")return;const e=this.media();let i=si(this.main.uri,e.uri);this.llhls&&(i=aC(i,e)),this.state="HAVE_CURRENT_METADATA",this.request=this.vhs_.xhr({uri:i,withCredentials:this.withCredentials,requestType:"hls-playlist"},(r,a)=>{if(this.request){if(r)return this.playlistRequestError(this.request,this.media(),"HAVE_METADATA");this.haveMetadata({playlistString:this.request.responseText,url:this.media().uri,id:this.media().id})}})}playlistRequestError(e,i,r){const{uri:a,id:o}=i;this.request=null,r&&(this.state=r),this.error={playlist:this.main.playlists[o],status:e.status,message:`HLS playlist request error at URL: ${a}.`,responseText:e.responseText,code:e.status>=500?4:2,metadata:Pn({requestType:e.requestType,request:e,error:e.error})},this.trigger("error")}parseManifest_({url:e,manifestString:i}){try{const r=Jx({onwarn:({message:a})=>this.logger_(`m3u8-parser warn for ${e}: ${a}`),oninfo:({message:a})=>this.logger_(`m3u8-parser info for ${e}: ${a}`),manifestString:i,customTagParsers:this.customTagParsers,customTagMappers:this.customTagMappers,llhls:this.llhls});return!r.playlists||!r.playlists.length||this.excludeAudioOnlyVariants(r.playlists),r}catch(r){this.error=r,this.error.metadata={errorType:ne.Error.StreamingHlsPlaylistParserError,error:r}}}excludeAudioOnlyVariants(e){const i=r=>{const a=r.attributes||{},{width:o,height:l}=a.RESOLUTION||{};if(o&&l)return!0;const u=wf(r)||[];return!!as(u).video};e.some(i)&&e.forEach(r=>{i(r)||(r.excludeUntil=1/0)})}haveMetadata({playlistString:e,playlistObject:i,url:r,id:a}){this.request=null,this.state="HAVE_METADATA";const o={playlistInfo:{type:"media",uri:r}};this.trigger({type:"playlistparsestart",metadata:o});const l=i||this.parseManifest_({url:r,manifestString:e});l.lastRequest=Date.now(),Sf({playlist:l,uri:r,id:a});const u=_l(this.main,l);this.targetDuration=l.partTargetDuration||l.targetDuration,this.pendingMedia_=null,u?(this.main=u,this.media_=this.main.playlists[a]):this.trigger("playlistunchanged"),this.updateMediaUpdateTimeout_(yl(this.media(),!!u)),o.parsedPlaylist=Fd(this.main.playlists,o.playlistInfo.type,!this.media_.endList),this.trigger({type:"playlistparsecomplete",metadata:o}),this.trigger("loadedplaylist")}dispose(){this.trigger("dispose"),this.stopRequest(),W.clearTimeout(this.mediaUpdateTimeout),W.clearTimeout(this.finalRenditionTimeout),this.dateRangesStorage_=new Rd,this.off()}stopRequest(){if(this.request){const e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}media(e,i){if(!e)return this.media_;if(this.state==="HAVE_NOTHING")throw new Error("Cannot switch media playlist from "+this.state);if(typeof e=="string"){if(!this.main.playlists[e])throw new Error("Unknown playlist URI: "+e);e=this.main.playlists[e]}if(W.clearTimeout(this.finalRenditionTimeout),i){const u=(e.partTargetDuration||e.targetDuration)/2*1e3||5e3;this.finalRenditionTimeout=W.setTimeout(this.media.bind(this,e,!1),u);return}const r=this.state,a=!this.media_||e.id!==this.media_.id,o=this.main.playlists[e.id];if(o&&o.endList||e.endList&&e.segments.length){this.request&&(this.request.onreadystatechange=null,this.request.abort(),this.request=null),this.state="HAVE_METADATA",this.media_=e,a&&(this.trigger("mediachanging"),r==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange"));return}if(this.updateMediaUpdateTimeout_(yl(e,!0)),!a)return;if(this.state="SWITCHING_MEDIA",this.request){if(e.resolvedUri===this.request.url)return;this.request.onreadystatechange=null,this.request.abort(),this.request=null}this.media_&&this.trigger("mediachanging"),this.pendingMedia_=e;const l={playlistInfo:{type:"media",uri:e.uri}};this.trigger({type:"playlistrequeststart",metadata:l}),this.request=this.vhs_.xhr({uri:e.resolvedUri,withCredentials:this.withCredentials,requestType:"hls-playlist"},(u,d)=>{if(this.request){if(e.lastRequest=Date.now(),e.resolvedUri=Ta(e.resolvedUri,d),u)return this.playlistRequestError(this.request,e,r);this.trigger({type:"playlistrequestcomplete",metadata:l}),this.haveMetadata({playlistString:d.responseText,url:e.uri,id:e.id}),r==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange")}})}pause(){this.mediaUpdateTimeout&&(W.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),this.stopRequest(),this.state==="HAVE_NOTHING"&&(this.started=!1),this.state==="SWITCHING_MEDIA"?this.media_?this.state="HAVE_METADATA":this.state="HAVE_MAIN_MANIFEST":this.state==="HAVE_CURRENT_METADATA"&&(this.state="HAVE_METADATA")}load(e){this.mediaUpdateTimeout&&(W.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null);const i=this.media();if(e){const r=i?(i.partTargetDuration||i.targetDuration)/2*1e3:5e3;this.mediaUpdateTimeout=W.setTimeout(()=>{this.mediaUpdateTimeout=null,this.load()},r);return}if(!this.started){this.start();return}i&&!i.endList?this.trigger("mediaupdatetimeout"):this.trigger("loadedplaylist")}updateMediaUpdateTimeout_(e){this.mediaUpdateTimeout&&(W.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),!(!this.media()||this.media().endList)&&(this.mediaUpdateTimeout=W.setTimeout(()=>{this.mediaUpdateTimeout=null,this.trigger("mediaupdatetimeout"),this.updateMediaUpdateTimeout_(e)},e))}start(){if(this.started=!0,typeof this.src=="object"){this.src.uri||(this.src.uri=W.location.href),this.src.resolvedUri=this.src.uri,setTimeout(()=>{this.setupInitialPlaylist(this.src)},0);return}const e={playlistInfo:{type:"multivariant",uri:this.src}};this.trigger({type:"playlistrequeststart",metadata:e}),this.request=this.vhs_.xhr({uri:this.src,withCredentials:this.withCredentials,requestType:"hls-playlist"},(i,r)=>{if(!this.request)return;if(this.request=null,i)return this.error={status:r.status,message:`HLS playlist request error at URL: ${this.src}.`,responseText:r.responseText,code:2,metadata:Pn({requestType:r.requestType,request:r,error:i})},this.state==="HAVE_NOTHING"&&(this.started=!1),this.trigger("error");this.trigger({type:"playlistrequestcomplete",metadata:e}),this.src=Ta(this.src,r),this.trigger({type:"playlistparsestart",metadata:e});const a=this.parseManifest_({manifestString:r.responseText,url:this.src});e.parsedPlaylist=Fd(a.playlists,e.playlistInfo.type,!1),this.trigger({type:"playlistparsecomplete",metadata:e}),this.setupInitialPlaylist(a)})}srcUri(){return typeof this.src=="string"?this.src:this.src.uri}setupInitialPlaylist(e){if(this.state="HAVE_MAIN_MANIFEST",e.playlists){this.main=e,Ef(this.main,this.srcUri()),e.playlists.forEach(r=>{r.segments=If(r),r.segments.forEach(a=>{Af(a,r.resolvedUri)})}),this.trigger("loadedplaylist"),this.request||this.media(this.main.playlists[0]);return}const i=this.srcUri()||W.location.href;this.main=iC(e,i),this.haveMetadata({playlistObject:e,url:i,id:this.main.playlists[0].id}),this.trigger("loadedmetadata")}updateOrDeleteClone(e,i){const r=this.main,a=e.ID;let o=r.playlists.length;for(;o--;){const l=r.playlists[o];if(l.attributes["PATHWAY-ID"]===a){const u=l.resolvedUri,d=l.id;if(i){const f=this.createCloneURI_(l.resolvedUri,e),g=er(a,f),y=this.createCloneAttributes_(a,l.attributes),E=this.createClonePlaylist_(l,g,e,y);r.playlists[o]=E,r.playlists[g]=E,r.playlists[f]=E}else r.playlists.splice(o,1);delete r.playlists[d],delete r.playlists[u]}}this.updateOrDeleteCloneMedia(e,i)}updateOrDeleteCloneMedia(e,i){const r=this.main,a=e.ID;["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(o=>{if(!(!r.mediaGroups[o]||!r.mediaGroups[o][a])){for(const l in r.mediaGroups[o])if(l===a){for(const u in r.mediaGroups[o][l])r.mediaGroups[o][l][u].playlists.forEach((f,g)=>{const y=r.playlists[f.id],E=y.id,x=y.resolvedUri;delete r.playlists[E],delete r.playlists[x]});delete r.mediaGroups[o][l]}}}),i&&this.createClonedMediaGroups_(e)}addClonePathway(e,i={}){const r=this.main,a=r.playlists.length,o=this.createCloneURI_(i.resolvedUri,e),l=er(e.ID,o),u=this.createCloneAttributes_(e.ID,i.attributes),d=this.createClonePlaylist_(i,l,e,u);r.playlists[a]=d,r.playlists[l]=d,r.playlists[o]=d,this.createClonedMediaGroups_(e)}createClonedMediaGroups_(e){const i=e.ID,r=e["BASE-ID"],a=this.main;["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(o=>{if(!(!a.mediaGroups[o]||a.mediaGroups[o][i]))for(const l in a.mediaGroups[o]){if(l===r)a.mediaGroups[o][i]={};else continue;for(const u in a.mediaGroups[o][l]){const d=a.mediaGroups[o][l][u];a.mediaGroups[o][i][u]=bt({},d);const f=a.mediaGroups[o][i][u],g=this.createCloneURI_(d.resolvedUri,e);f.resolvedUri=g,f.uri=g,f.playlists=[],d.playlists.forEach((y,E)=>{const x=a.playlists[y.id],B=Cf(o,i,u),T=er(i,B);if(x&&!a.playlists[T]){const w=this.createClonePlaylist_(x,T,e),F=w.resolvedUri;a.playlists[T]=w,a.playlists[F]=w}f.playlists[E]=this.createClonePlaylist_(y,T,e)})}}})}createClonePlaylist_(e,i,r,a){const o=this.createCloneURI_(e.resolvedUri,r),l={resolvedUri:o,uri:o,id:i};return e.segments&&(l.segments=[]),a&&(l.attributes=a),it(e,l)}createCloneURI_(e,i){const r=new URL(e);r.hostname=i["URI-REPLACEMENT"].HOST;const a=i["URI-REPLACEMENT"].PARAMS;for(const o of Object.keys(a))r.searchParams.set(o,a[o]);return r.href}createCloneAttributes_(e,i){const r={"PATHWAY-ID":e};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(a=>{i[a]&&(r[a]=e)}),r}getKeyIdSet(e){const i=new Set;if(!e||!e.contentProtection)return i;for(const r in e.contentProtection)if(e.contentProtection[r]&&e.contentProtection[r].attributes&&e.contentProtection[r].attributes.keyId){const a=e.contentProtection[r].attributes.keyId;i.add(a.toLowerCase())}return i}}const vl=function(s,e,i,r){const a=s.responseType==="arraybuffer"?s.response:s.responseText;!e&&a&&(s.responseTime=Date.now(),s.roundTripTime=s.responseTime-s.requestTime,s.bytesReceived=a.byteLength||a.length,s.bandwidth||(s.bandwidth=Math.floor(s.bytesReceived/s.roundTripTime*8*1e3))),i.headers&&(s.responseHeaders=i.headers),e&&e.code==="ETIMEDOUT"&&(s.timedout=!0),!e&&!s.aborted&&i.statusCode!==200&&i.statusCode!==206&&i.statusCode!==0&&(e=new Error("XHR Failed with a response of: "+(s&&(a||s.responseText)))),r(e,s)},uC=(s,e)=>{if(!s||!s.size)return;let i=e;return s.forEach(r=>{i=r(i)}),i},cC=(s,e,i,r)=>{!s||!s.size||s.forEach(a=>{a(e,i,r)})},Of=function(){const s=function e(i,r){i=it({timeout:45e3},i);const a=e.beforeRequest||ne.Vhs.xhr.beforeRequest,o=e._requestCallbackSet||ne.Vhs.xhr._requestCallbackSet||new Set,l=e._responseCallbackSet||ne.Vhs.xhr._responseCallbackSet;a&&typeof a=="function"&&(ne.log.warn("beforeRequest is deprecated, use onRequest instead."),o.add(a));const u=ne.Vhs.xhr.original===!0?ne.xhr:ne.Vhs.xhr,d=uC(o,i);o.delete(a);const f=u(d||i,function(y,E){return cC(l,f,y,E),vl(f,y,E,r)}),g=f.abort;return f.abort=function(){return f.aborted=!0,g.apply(f,arguments)},f.uri=i.uri,f.requestType=i.requestType,f.requestTime=Date.now(),f};return s.original=!0,s},dC=function(s){let e;const i=s.offset;return typeof s.offset=="bigint"||typeof s.length=="bigint"?e=W.BigInt(s.offset)+W.BigInt(s.length)-W.BigInt(1):e=s.offset+s.length-1,"bytes="+i+"-"+e},Tl=function(s){const e={};return s.byterange&&(e.Range=dC(s.byterange)),e},hC=function(s,e){return s.start(e)+"-"+s.end(e)},fC=function(s,e){const i=s.toString(16);return"00".substring(0,2-i.length)+i+(e%2?" ":"")},pC=function(s){return s>=32&&s<126?String.fromCharCode(s):"."},Bf=function(s){const e={};return Object.keys(s).forEach(i=>{const r=s[i];Lh(r)?e[i]={bytes:r.buffer,byteOffset:r.byteOffset,byteLength:r.byteLength}:e[i]=r}),e},ba=function(s){const e=s.byterange||{length:1/0,offset:0};return[e.length,e.offset,s.resolvedUri].join(",")},Lf=function(s){return s.resolvedUri},Pf=s=>{const e=Array.prototype.slice.call(s),i=16;let r="",a,o;for(let l=0;l<e.length/i;l++)a=e.slice(l*i,l*i+i).map(fC).join(""),o=e.slice(l*i,l*i+i).map(pC).join(""),r+=a+" "+o+`
|
|
203
|
+
`;return r},mC=({bytes:s})=>Pf(s),gC=s=>{let e="",i;for(i=0;i<s.length;i++)e+=hC(s,i)+" ";return e};var _C=Object.freeze({__proto__:null,createTransferableMessage:Bf,initSegmentId:ba,segmentKeyId:Lf,hexDump:Pf,tagDump:mC,textRanges:gC});const Mf=.25,yC=(s,e)=>{if(!e.dateTimeObject)return null;const i=e.videoTimingInfo.transmuxerPrependedSeconds,a=e.videoTimingInfo.transmuxedPresentationStart+i,o=s-a;return new Date(e.dateTimeObject.getTime()+o*1e3)},vC=s=>s.transmuxedPresentationEnd-s.transmuxedPresentationStart-s.transmuxerPrependedSeconds,TC=(s,e)=>{let i;try{i=new Date(s)}catch{return null}if(!e||!e.segments||e.segments.length===0)return null;let r=e.segments[0];if(i<new Date(r.dateTimeObject))return null;for(let d=0;d<e.segments.length-1;d++){r=e.segments[d];const f=new Date(e.segments[d+1].dateTimeObject);if(i<f)break}const a=e.segments[e.segments.length-1],o=a.dateTimeObject,l=a.videoTimingInfo?vC(a.videoTimingInfo):a.duration+a.duration*Mf,u=new Date(o.getTime()+l*1e3);return i>u?null:(i>new Date(o)&&(r=a),{segment:r,estimatedStart:r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationStart:ai.duration(e,e.mediaSequence+e.segments.indexOf(r)),type:r.videoTimingInfo?"accurate":"estimate"})},bC=(s,e)=>{if(!e||!e.segments||e.segments.length===0)return null;let i=0,r;for(let o=0;o<e.segments.length&&(r=e.segments[o],i=r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationEnd:i+r.duration,!(s<=i));o++);const a=e.segments[e.segments.length-1];if(a.videoTimingInfo&&a.videoTimingInfo.transmuxedPresentationEnd<s)return null;if(s>i){if(s>i+a.duration*Mf)return null;r=a}return{segment:r,estimatedStart:r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationStart:i-r.duration,type:r.videoTimingInfo?"accurate":"estimate"}},xC=(s,e)=>{let i,r;try{i=new Date(s),r=new Date(e)}catch{}const a=i.getTime();return(r.getTime()-a)/1e3},CC=s=>{if(!s.segments||s.segments.length===0)return!1;for(let e=0;e<s.segments.length;e++)if(!s.segments[e].dateTimeObject)return!1;return!0},SC=({playlist:s,time:e=void 0,callback:i})=>{if(!i)throw new Error("getProgramTime: callback must be provided");if(!s||e===void 0)return i({message:"getProgramTime: playlist and time must be provided"});const r=bC(e,s);if(!r)return i({message:"valid programTime was not found"});if(r.type==="estimate")return i({message:"Accurate programTime could not be determined. Please seek to e.seekTime and try again",seekTime:r.estimatedStart});const a={mediaSeconds:e},o=yC(e,r.segment);return o&&(a.programDateTime=o.toISOString()),i(null,a)},Rf=({programTime:s,playlist:e,retryCount:i=2,seekTo:r,pauseAfterSeek:a=!0,tech:o,callback:l})=>{if(!l)throw new Error("seekToProgramTime: callback must be provided");if(typeof s>"u"||!e||!r)return l({message:"seekToProgramTime: programTime, seekTo and playlist must be provided"});if(!e.endList&&!o.hasStarted_)return l({message:"player must be playing a live stream to start buffering"});if(!CC(e))return l({message:"programDateTime tags must be provided in the manifest "+e.resolvedUri});const u=TC(s,e);if(!u)return l({message:`${s} was not found in the stream`});const d=u.segment,f=xC(d.dateTimeObject,s);if(u.type==="estimate"){if(i===0)return l({message:`${s} is not buffered yet. Try again`});r(u.estimatedStart+f),o.one("seeked",()=>{Rf({programTime:s,playlist:e,retryCount:i-1,seekTo:r,pauseAfterSeek:a,tech:o,callback:l})});return}const g=d.start+f,y=()=>l(null,o.currentTime());o.one("seeked",y),a&&o.pause(),r(g)},Wo=(s,e)=>{if(s.readyState===4)return e()},EC=(s,e,i,r)=>{let a=[],o,l=!1;const u=function(y,E,x,B){return E.abort(),l=!0,i(y,E,x,B)},d=function(y,E){if(l)return;if(y)return y.metadata=Pn({requestType:r,request:E,error:y}),u(y,E,"",a);const x=E.responseText.substring(a&&a.byteLength||0,E.responseText.length);if(a=Zb(a,Ph(x,!0)),o=o||Gr(a),a.length<10||o&&a.length<o+2)return Wo(E,()=>u(y,E,"",a));const B=Ml(a);return B==="ts"&&a.length<188?Wo(E,()=>u(y,E,"",a)):!B&&a.length<376?Wo(E,()=>u(y,E,"",a)):u(null,E,B,a)},g=e({uri:s,beforeSend(y){y.overrideMimeType("text/plain; charset=x-user-defined"),y.addEventListener("progress",function({total:E,loaded:x}){return vl(y,null,{statusCode:y.status},d)})}},function(y,E){return vl(g,y,E,d)});return g},{EventTarget:kC}=ne,$d=function(s,e){if(!Nf(s,e)||s.sidx&&e.sidx&&(s.sidx.offset!==e.sidx.offset||s.sidx.length!==e.sidx.length))return!1;if(!s.sidx&&e.sidx||s.sidx&&!e.sidx||s.segments&&!e.segments||!s.segments&&e.segments)return!1;if(!s.segments&&!e.segments)return!0;for(let i=0;i<s.segments.length;i++){const r=s.segments[i],a=e.segments[i];if(r.uri!==a.uri)return!1;if(!r.byterange&&!a.byterange)continue;const o=r.byterange,l=a.byterange;if(o&&!l||!o&&l||o.offset!==l.offset||o.length!==l.length)return!1}return!0},wC=(s,e,i,r)=>{const a=r.attributes.NAME||i;return`placeholder-uri-${s}-${e}-${a}`},DC=({mainXml:s,srcUrl:e,clientOffset:i,sidxMapping:r,previousManifest:a})=>{const o=K4(s,{manifestUri:e,clientOffset:i,sidxMapping:r,previousManifest:a});return Ef(o,e,wC),o},AC=(s,e)=>{br(s,(i,r,a,o)=>{(!e.mediaGroups[r][a]||!(o in e.mediaGroups[r][a]))&&delete s.mediaGroups[r][a][o]})},IC=(s,e,i)=>{let r=!0,a=it(s,{duration:e.duration,minimumUpdatePeriod:e.minimumUpdatePeriod,timelineStarts:e.timelineStarts});for(let o=0;o<e.playlists.length;o++){const l=e.playlists[o];if(l.sidx){const d=wa(l.sidx);i&&i[d]&&i[d].sidx&&Bl(l,i[d].sidx,l.sidx.resolvedUri)}const u=_l(a,l,$d);u&&(a=u,r=!1)}return br(e,(o,l,u,d)=>{if(o.playlists&&o.playlists.length){const f=o.playlists[0].id,g=_l(a,o.playlists[0],$d);g&&(a=g,d in a.mediaGroups[l][u]||(a.mediaGroups[l][u][d]=o),a.mediaGroups[l][u][d].playlists[0]=a.playlists[f],r=!1)}}),AC(a,e),e.minimumUpdatePeriod!==s.minimumUpdatePeriod&&(r=!1),r?null:a},NC=(s,e)=>(!s.map&&!e.map||!!(s.map&&e.map&&s.map.byterange.offset===e.map.byterange.offset&&s.map.byterange.length===e.map.byterange.length))&&s.uri===e.uri&&s.byterange.offset===e.byterange.offset&&s.byterange.length===e.byterange.length,Ud=(s,e)=>{const i={};for(const r in s){const o=s[r].sidx;if(o){const l=wa(o);if(!e[l])break;const u=e[l].sidxInfo;NC(u,o)&&(i[l]=e[l])}}return i},OC=(s,e)=>{let r=Ud(s.playlists,e);return br(s,(a,o,l,u)=>{if(a.playlists&&a.playlists.length){const d=a.playlists;r=it(r,Ud(d,e))}}),r};class bl extends kC{constructor(e,i,r={},a){super(),this.isPaused_=!0,this.mainPlaylistLoader_=a||this,a||(this.isMain_=!0);const{withCredentials:o=!1}=r;if(this.vhs_=i,this.withCredentials=o,this.addMetadataToTextTrack=r.addMetadataToTextTrack,!e)throw new Error("A non-empty playlist URL or object is required");this.on("minimumUpdatePeriod",()=>{this.refreshXml_()}),this.on("mediaupdatetimeout",()=>{this.refreshMedia_(this.media().id)}),this.state="HAVE_NOTHING",this.loadedPlaylists_={},this.logger_=bi("DashPlaylistLoader"),this.isMain_?(this.mainPlaylistLoader_.srcUrl=e,this.mainPlaylistLoader_.sidxMapping_={}):this.childPlaylist_=e}get isPaused(){return this.isPaused_}requestErrored_(e,i,r){if(!this.request)return!0;if(this.request=null,e)return this.error=typeof e=="object"&&!(e instanceof Error)?e:{status:i.status,message:"DASH request error at URL: "+i.uri,response:i.response,code:2,metadata:e.metadata},r&&(this.state=r),this.trigger("error"),!0}addSidxSegments_(e,i,r){const a=e.sidx&&wa(e.sidx);if(!e.sidx||!a||this.mainPlaylistLoader_.sidxMapping_[a]){W.clearTimeout(this.mediaRequest_),this.mediaRequest_=W.setTimeout(()=>r(!1),0);return}const o=Ta(e.sidx.resolvedUri),l=(d,f)=>{if(this.requestErrored_(d,f,i))return;const g=this.mainPlaylistLoader_.sidxMapping_,{requestType:y}=f;let E;try{E=t8(Ne(f.response).subarray(8))}catch(x){x.metadata=Pn({requestType:y,request:f,parseFailure:!0}),this.requestErrored_(x,f,i);return}return g[a]={sidxInfo:e.sidx,sidx:E},Bl(e,E,e.sidx.resolvedUri),r(!0)},u="dash-sidx";this.request=EC(o,this.vhs_.xhr,(d,f,g,y)=>{if(d)return l(d,f);if(!g||g!=="mp4"){const B=g||"unknown";return l({status:f.status,message:`Unsupported ${B} container type for sidx segment at URL: ${o}`,response:"",playlist:e,internal:!0,playlistExclusionDuration:1/0,code:2},f)}const{offset:E,length:x}=e.sidx.byterange;if(y.length>=x+E)return l(d,{response:y.subarray(E,E+x),status:f.status,uri:f.uri});this.request=this.vhs_.xhr({uri:o,responseType:"arraybuffer",requestType:"dash-sidx",headers:Tl({byterange:e.sidx.byterange})},l)},u)}dispose(){this.isPaused_=!0,this.trigger("dispose"),this.stopRequest(),this.loadedPlaylists_={},W.clearTimeout(this.minimumUpdatePeriodTimeout_),W.clearTimeout(this.mediaRequest_),W.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.mediaRequest_=null,this.minimumUpdatePeriodTimeout_=null,this.mainPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.mainPlaylistLoader_.createMupOnMedia_),this.mainPlaylistLoader_.createMupOnMedia_=null),this.off()}hasPendingRequest(){return this.request||this.mediaRequest_}stopRequest(){if(this.request){const e=this.request;this.request=null,e.onreadystatechange=null,e.abort()}}media(e){if(!e)return this.media_;if(this.state==="HAVE_NOTHING")throw new Error("Cannot switch media playlist from "+this.state);const i=this.state;if(typeof e=="string"){if(!this.mainPlaylistLoader_.main.playlists[e])throw new Error("Unknown playlist URI: "+e);e=this.mainPlaylistLoader_.main.playlists[e]}const r=!this.media_||e.id!==this.media_.id;if(r&&this.loadedPlaylists_[e.id]&&this.loadedPlaylists_[e.id].endList){this.state="HAVE_METADATA",this.media_=e,r&&(this.trigger("mediachanging"),this.trigger("mediachange"));return}r&&(this.media_&&this.trigger("mediachanging"),this.addSidxSegments_(e,i,a=>{this.haveMetadata({startingState:i,playlist:e})}))}haveMetadata({startingState:e,playlist:i}){this.state="HAVE_METADATA",this.loadedPlaylists_[i.id]=i,W.clearTimeout(this.mediaRequest_),this.mediaRequest_=null,this.refreshMedia_(i.id),e==="HAVE_MAIN_MANIFEST"?this.trigger("loadedmetadata"):this.trigger("mediachange")}pause(){this.isPaused_=!0,this.mainPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.mainPlaylistLoader_.createMupOnMedia_),this.mainPlaylistLoader_.createMupOnMedia_=null),this.stopRequest(),W.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.isMain_&&(W.clearTimeout(this.mainPlaylistLoader_.minimumUpdatePeriodTimeout_),this.mainPlaylistLoader_.minimumUpdatePeriodTimeout_=null),this.state==="HAVE_NOTHING"&&(this.started=!1)}load(e){this.isPaused_=!1,W.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null;const i=this.media();if(e){const r=i?i.targetDuration/2*1e3:5e3;this.mediaUpdateTimeout=W.setTimeout(()=>this.load(),r);return}if(!this.started){this.start();return}i&&!i.endList?(this.isMain_&&!this.minimumUpdatePeriodTimeout_&&(this.trigger("minimumUpdatePeriod"),this.updateMinimumUpdatePeriodTimeout_()),this.trigger("mediaupdatetimeout")):this.trigger("loadedplaylist")}start(){if(this.started=!0,!this.isMain_){W.clearTimeout(this.mediaRequest_),this.mediaRequest_=W.setTimeout(()=>this.haveMain_(),0);return}this.requestMain_((e,i)=>{this.haveMain_(),!this.hasPendingRequest()&&!this.media_&&this.media(this.mainPlaylistLoader_.main.playlists[0])})}requestMain_(e){const i={manifestInfo:{uri:this.mainPlaylistLoader_.srcUrl}};this.trigger({type:"manifestrequeststart",metadata:i}),this.request=this.vhs_.xhr({uri:this.mainPlaylistLoader_.srcUrl,withCredentials:this.withCredentials,requestType:"dash-manifest"},(r,a)=>{if(r){const{requestType:l}=a;r.metadata=Pn({requestType:l,request:a,error:r})}if(this.requestErrored_(r,a)){this.state==="HAVE_NOTHING"&&(this.started=!1);return}this.trigger({type:"manifestrequestcomplete",metadata:i});const o=a.responseText!==this.mainPlaylistLoader_.mainXml_;if(this.mainPlaylistLoader_.mainXml_=a.responseText,a.responseHeaders&&a.responseHeaders.date?this.mainLoaded_=Date.parse(a.responseHeaders.date):this.mainLoaded_=Date.now(),this.mainPlaylistLoader_.srcUrl=Ta(this.mainPlaylistLoader_.srcUrl,a),o){this.handleMain_(),this.syncClientServerClock_(()=>e(a,o));return}return e(a,o)})}syncClientServerClock_(e){const i=Q4(this.mainPlaylistLoader_.mainXml_);if(i===null)return this.mainPlaylistLoader_.clientOffset_=this.mainLoaded_-Date.now(),e();if(i.method==="DIRECT")return this.mainPlaylistLoader_.clientOffset_=i.value-Date.now(),e();this.request=this.vhs_.xhr({uri:si(this.mainPlaylistLoader_.srcUrl,i.value),method:i.method,withCredentials:this.withCredentials,requestType:"dash-clock-sync"},(r,a)=>{if(!this.request)return;if(r){const{requestType:l}=a;return this.error.metadata=Pn({requestType:l,request:a,error:r}),this.mainPlaylistLoader_.clientOffset_=this.mainLoaded_-Date.now(),e()}let o;i.method==="HEAD"?!a.responseHeaders||!a.responseHeaders.date?o=this.mainLoaded_:o=Date.parse(a.responseHeaders.date):o=Date.parse(a.responseText),this.mainPlaylistLoader_.clientOffset_=o-Date.now(),e()})}haveMain_(){this.state="HAVE_MAIN_MANIFEST",this.isMain_?this.trigger("loadedplaylist"):this.media_||this.media(this.childPlaylist_)}handleMain_(){W.clearTimeout(this.mediaRequest_),this.mediaRequest_=null;const e=this.mainPlaylistLoader_.main,i={manifestInfo:{uri:this.mainPlaylistLoader_.srcUrl}};this.trigger({type:"manifestparsestart",metadata:i});let r;try{r=DC({mainXml:this.mainPlaylistLoader_.mainXml_,srcUrl:this.mainPlaylistLoader_.srcUrl,clientOffset:this.mainPlaylistLoader_.clientOffset_,sidxMapping:this.mainPlaylistLoader_.sidxMapping_,previousManifest:e})}catch(o){this.error=o,this.error.metadata={errorType:ne.Error.StreamingDashManifestParserError,error:o},this.trigger("error")}e&&(r=IC(e,r,this.mainPlaylistLoader_.sidxMapping_)),this.mainPlaylistLoader_.main=r||e;const a=this.mainPlaylistLoader_.main.locations&&this.mainPlaylistLoader_.main.locations[0];if(a&&a!==this.mainPlaylistLoader_.srcUrl&&(this.mainPlaylistLoader_.srcUrl=a),(!e||r&&r.minimumUpdatePeriod!==e.minimumUpdatePeriod)&&this.updateMinimumUpdatePeriodTimeout_(),this.addEventStreamToMetadataTrack_(r),r){const{duration:o,endList:l}=r,u=[];r.playlists.forEach(f=>{u.push({id:f.id,bandwidth:f.attributes.BANDWIDTH,resolution:f.attributes.RESOLUTION,codecs:f.attributes.CODECS})});const d={duration:o,isLive:!l,renditions:u};i.parsedManifest=d,this.trigger({type:"manifestparsecomplete",metadata:i})}return!!r}updateMinimumUpdatePeriodTimeout_(){const e=this.mainPlaylistLoader_;e.createMupOnMedia_&&(e.off("loadedmetadata",e.createMupOnMedia_),e.createMupOnMedia_=null),e.minimumUpdatePeriodTimeout_&&(W.clearTimeout(e.minimumUpdatePeriodTimeout_),e.minimumUpdatePeriodTimeout_=null);let i=e.main&&e.main.minimumUpdatePeriod;if(i===0&&(e.media()?i=e.media().targetDuration*1e3:(e.createMupOnMedia_=e.updateMinimumUpdatePeriodTimeout_,e.one("loadedmetadata",e.createMupOnMedia_))),typeof i!="number"||i<=0){i<0&&this.logger_(`found invalid minimumUpdatePeriod of ${i}, not setting a timeout`);return}this.createMUPTimeout_(i)}createMUPTimeout_(e){const i=this.mainPlaylistLoader_;i.minimumUpdatePeriodTimeout_=W.setTimeout(()=>{i.minimumUpdatePeriodTimeout_=null,i.trigger("minimumUpdatePeriod"),i.createMUPTimeout_(e)},e)}refreshXml_(){this.requestMain_((e,i)=>{i&&(this.media_&&(this.media_=this.mainPlaylistLoader_.main.playlists[this.media_.id]),this.mainPlaylistLoader_.sidxMapping_=OC(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.sidxMapping_),this.addSidxSegments_(this.media(),this.state,r=>{this.refreshMedia_(this.media().id)}))})}refreshMedia_(e){if(!e)throw new Error("refreshMedia_ must take a media id");this.media_&&this.isMain_&&this.handleMain_();const i=this.mainPlaylistLoader_.main.playlists,r=!this.media_||this.media_!==i[e];if(r?this.media_=i[e]:this.trigger("playlistunchanged"),!this.mediaUpdateTimeout){const a=()=>{this.media().endList||(this.mediaUpdateTimeout=W.setTimeout(()=>{this.trigger("mediaupdatetimeout"),a()},yl(this.media(),!!r)))};a()}this.trigger("loadedplaylist")}addEventStreamToMetadataTrack_(e){if(e&&this.mainPlaylistLoader_.main.eventStream){const i=this.mainPlaylistLoader_.main.eventStream.map(r=>({cueTime:r.start,frames:[{data:r.messageData}]}));this.addMetadataToTextTrack("EventStream",i,this.mainPlaylistLoader_.main.duration)}}getKeyIdSet(e){if(e.contentProtection){const i=new Set;for(const r in e.contentProtection){const a=e.contentProtection[r].attributes["cenc:default_KID"];a&&i.add(a.replace(/-/g,"").toLowerCase())}return i}}}var At={GOAL_BUFFER_LENGTH:30,MAX_GOAL_BUFFER_LENGTH:60,BACK_BUFFER_LENGTH:30,GOAL_BUFFER_LENGTH_RATE:1,INITIAL_BANDWIDTH:4194304,BANDWIDTH_VARIANCE:1.2,BUFFER_LOW_WATER_LINE:0,MAX_BUFFER_LOW_WATER_LINE:30,EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:16,BUFFER_LOW_WATER_LINE_RATE:1,BUFFER_HIGH_WATER_LINE:30};const BC=s=>{const e=new Uint8Array(new ArrayBuffer(s.length));for(let i=0;i<s.length;i++)e[i]=s.charCodeAt(i);return e.buffer},Vf=function(s){return s.on=s.addEventListener,s.off=s.removeEventListener,s},LC=function(s){try{return URL.createObjectURL(new Blob([s],{type:"application/javascript"}))}catch{const i=new BlobBuilder;return i.append(s),URL.createObjectURL(i.getBlob())}},Ff=function(s){return function(){const e=LC(s),i=Vf(new Worker(e));i.objURL=e;const r=i.terminate;return i.on=i.addEventListener,i.off=i.removeEventListener,i.terminate=function(){return URL.revokeObjectURL(e),r.call(this)},i}},$f=function(s){return`var browserWorkerPolyFill = ${Vf.toString()};
|
|
204
|
+
browserWorkerPolyFill(self);
|
|
205
|
+
`+s},Uf=function(s){return s.toString().replace(/^function.+?{/,"").slice(0,-1)},PC=$f(Uf(function(){var s=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},e=function(){this.init=function(){var c={};this.on=function(h,m){c[h]||(c[h]=[]),c[h]=c[h].concat(m)},this.off=function(h,m){var p;return c[h]?(p=c[h].indexOf(m),c[h]=c[h].slice(),c[h].splice(p,1),p>-1):!1},this.trigger=function(h){var m,p,_,v;if(m=c[h],!!m)if(arguments.length===2)for(_=m.length,p=0;p<_;++p)m[p].call(this,arguments[1]);else{for(v=[],p=arguments.length,p=1;p<arguments.length;++p)v.push(arguments[p]);for(_=m.length,p=0;p<_;++p)m[p].apply(this,v)}},this.dispose=function(){c={}}}};e.prototype.pipe=function(c){return this.on("data",function(h){c.push(h)}),this.on("done",function(h){c.flush(h)}),this.on("partialdone",function(h){c.partialFlush(h)}),this.on("endedtimeline",function(h){c.endTimeline(h)}),this.on("reset",function(h){c.reset(h)}),c},e.prototype.push=function(c){this.trigger("data",c)},e.prototype.flush=function(c){this.trigger("done",c)},e.prototype.partialFlush=function(c){this.trigger("partialdone",c)},e.prototype.endTimeline=function(c){this.trigger("endedtimeline",c)},e.prototype.reset=function(c){this.trigger("reset",c)};var i=e,r=Math.pow(2,32),a=function(c){var h=new DataView(c.buffer,c.byteOffset,c.byteLength),m;return h.getBigUint64?(m=h.getBigUint64(0),m<Number.MAX_SAFE_INTEGER?Number(m):m):h.getUint32(0)*r+h.getUint32(4)},o={getUint64:a,MAX_UINT32:r},l=o.MAX_UINT32,u,d,f,g,y,E,x,B,T,w,F,P,I,K,q,M,N,J,b,C,U,j,k,A,$,Q,H,V,G,Z,te,se,ue,ce,de,qe;(function(){var c;if(k={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],pasp:[],sdtp:[],smhd:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],styp:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[]},!(typeof Uint8Array>"u")){for(c in k)k.hasOwnProperty(c)&&(k[c]=[c.charCodeAt(0),c.charCodeAt(1),c.charCodeAt(2),c.charCodeAt(3)]);A=new Uint8Array([105,115,111,109]),Q=new Uint8Array([97,118,99,49]),$=new Uint8Array([0,0,0,1]),H=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),V=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),G={video:H,audio:V},se=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),te=new Uint8Array([0,0,0,0,0,0,0,0]),ue=new Uint8Array([0,0,0,0,0,0,0,0]),ce=ue,de=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),qe=ue,Z=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}})(),u=function(c){var h=[],m=0,p,_,v;for(p=1;p<arguments.length;p++)h.push(arguments[p]);for(p=h.length;p--;)m+=h[p].byteLength;for(_=new Uint8Array(m+8),v=new DataView(_.buffer,_.byteOffset,_.byteLength),v.setUint32(0,_.byteLength),_.set(c,4),p=0,m=8;p<h.length;p++)_.set(h[p],m),m+=h[p].byteLength;return _},d=function(){return u(k.dinf,u(k.dref,se))},f=function(c){return u(k.esds,new Uint8Array([0,0,0,0,3,25,0,0,0,4,17,64,21,0,6,0,0,0,218,192,0,0,218,192,5,2,c.audioobjecttype<<3|c.samplingfrequencyindex>>>1,c.samplingfrequencyindex<<7|c.channelcount<<3,6,1,2]))},g=function(){return u(k.ftyp,A,$,A,Q)},M=function(c){return u(k.hdlr,G[c])},y=function(c){return u(k.mdat,c)},q=function(c){var h=new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,0,1,95,144,c.duration>>>24&255,c.duration>>>16&255,c.duration>>>8&255,c.duration&255,85,196,0,0]);return c.samplerate&&(h[12]=c.samplerate>>>24&255,h[13]=c.samplerate>>>16&255,h[14]=c.samplerate>>>8&255,h[15]=c.samplerate&255),u(k.mdhd,h)},K=function(c){return u(k.mdia,q(c),M(c.type),x(c))},E=function(c){return u(k.mfhd,new Uint8Array([0,0,0,0,(c&4278190080)>>24,(c&16711680)>>16,(c&65280)>>8,c&255]))},x=function(c){return u(k.minf,c.type==="video"?u(k.vmhd,Z):u(k.smhd,te),d(),J(c))},B=function(c,h){for(var m=[],p=h.length;p--;)m[p]=C(h[p]);return u.apply(null,[k.moof,E(c)].concat(m))},T=function(c){for(var h=c.length,m=[];h--;)m[h]=P(c[h]);return u.apply(null,[k.moov,F(4294967295)].concat(m).concat(w(c)))},w=function(c){for(var h=c.length,m=[];h--;)m[h]=U(c[h]);return u.apply(null,[k.mvex].concat(m))},F=function(c){var h=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,0,1,95,144,(c&4278190080)>>24,(c&16711680)>>16,(c&65280)>>8,c&255,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return u(k.mvhd,h)},N=function(c){var h=c.samples||[],m=new Uint8Array(4+h.length),p,_;for(_=0;_<h.length;_++)p=h[_].flags,m[_+4]=p.dependsOn<<4|p.isDependedOn<<2|p.hasRedundancy;return u(k.sdtp,m)},J=function(c){return u(k.stbl,b(c),u(k.stts,qe),u(k.stsc,ce),u(k.stsz,de),u(k.stco,ue))},(function(){var c,h;b=function(m){return u(k.stsd,new Uint8Array([0,0,0,0,0,0,0,1]),m.type==="video"?c(m):h(m))},c=function(m){var p=m.sps||[],_=m.pps||[],v=[],L=[],R,z;for(R=0;R<p.length;R++)v.push((p[R].byteLength&65280)>>>8),v.push(p[R].byteLength&255),v=v.concat(Array.prototype.slice.call(p[R]));for(R=0;R<_.length;R++)L.push((_[R].byteLength&65280)>>>8),L.push(_[R].byteLength&255),L=L.concat(Array.prototype.slice.call(_[R]));if(z=[k.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,(m.width&65280)>>8,m.width&255,(m.height&65280)>>8,m.height&255,0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),u(k.avcC,new Uint8Array([1,m.profileIdc,m.profileCompatibility,m.levelIdc,255].concat([p.length],v,[_.length],L))),u(k.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192]))],m.sarRatio){var Y=m.sarRatio[0],ie=m.sarRatio[1];z.push(u(k.pasp,new Uint8Array([(Y&4278190080)>>24,(Y&16711680)>>16,(Y&65280)>>8,Y&255,(ie&4278190080)>>24,(ie&16711680)>>16,(ie&65280)>>8,ie&255])))}return u.apply(null,z)},h=function(m){return u(k.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,(m.channelcount&65280)>>8,m.channelcount&255,(m.samplesize&65280)>>8,m.samplesize&255,0,0,0,0,(m.samplerate&65280)>>8,m.samplerate&255,0,0]),f(m))}})(),I=function(c){var h=new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,(c.id&4278190080)>>24,(c.id&16711680)>>16,(c.id&65280)>>8,c.id&255,0,0,0,0,(c.duration&4278190080)>>24,(c.duration&16711680)>>16,(c.duration&65280)>>8,c.duration&255,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,(c.width&65280)>>8,c.width&255,0,0,(c.height&65280)>>8,c.height&255,0,0]);return u(k.tkhd,h)},C=function(c){var h,m,p,_,v,L,R;return h=u(k.tfhd,new Uint8Array([0,0,0,58,(c.id&4278190080)>>24,(c.id&16711680)>>16,(c.id&65280)>>8,c.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0])),L=Math.floor(c.baseMediaDecodeTime/l),R=Math.floor(c.baseMediaDecodeTime%l),m=u(k.tfdt,new Uint8Array([1,0,0,0,L>>>24&255,L>>>16&255,L>>>8&255,L&255,R>>>24&255,R>>>16&255,R>>>8&255,R&255])),v=92,c.type==="audio"?(p=j(c,v),u(k.traf,h,m,p)):(_=N(c),p=j(c,_.length+v),u(k.traf,h,m,p,_))},P=function(c){return c.duration=c.duration||4294967295,u(k.trak,I(c),K(c))},U=function(c){var h=new Uint8Array([0,0,0,0,(c.id&4278190080)>>24,(c.id&16711680)>>16,(c.id&65280)>>8,c.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return c.type!=="video"&&(h[h.length-1]=0),u(k.trex,h)},(function(){var c,h,m;m=function(p,_){var v=0,L=0,R=0,z=0;return p.length&&(p[0].duration!==void 0&&(v=1),p[0].size!==void 0&&(L=2),p[0].flags!==void 0&&(R=4),p[0].compositionTimeOffset!==void 0&&(z=8)),[0,0,v|L|R|z,1,(p.length&4278190080)>>>24,(p.length&16711680)>>>16,(p.length&65280)>>>8,p.length&255,(_&4278190080)>>>24,(_&16711680)>>>16,(_&65280)>>>8,_&255]},h=function(p,_){var v,L,R,z,Y,ie;for(z=p.samples||[],_+=20+16*z.length,R=m(z,_),L=new Uint8Array(R.length+z.length*16),L.set(R),v=R.length,ie=0;ie<z.length;ie++)Y=z[ie],L[v++]=(Y.duration&4278190080)>>>24,L[v++]=(Y.duration&16711680)>>>16,L[v++]=(Y.duration&65280)>>>8,L[v++]=Y.duration&255,L[v++]=(Y.size&4278190080)>>>24,L[v++]=(Y.size&16711680)>>>16,L[v++]=(Y.size&65280)>>>8,L[v++]=Y.size&255,L[v++]=Y.flags.isLeading<<2|Y.flags.dependsOn,L[v++]=Y.flags.isDependedOn<<6|Y.flags.hasRedundancy<<4|Y.flags.paddingValue<<1|Y.flags.isNonSyncSample,L[v++]=Y.flags.degradationPriority&61440,L[v++]=Y.flags.degradationPriority&15,L[v++]=(Y.compositionTimeOffset&4278190080)>>>24,L[v++]=(Y.compositionTimeOffset&16711680)>>>16,L[v++]=(Y.compositionTimeOffset&65280)>>>8,L[v++]=Y.compositionTimeOffset&255;return u(k.trun,L)},c=function(p,_){var v,L,R,z,Y,ie;for(z=p.samples||[],_+=20+8*z.length,R=m(z,_),v=new Uint8Array(R.length+z.length*8),v.set(R),L=R.length,ie=0;ie<z.length;ie++)Y=z[ie],v[L++]=(Y.duration&4278190080)>>>24,v[L++]=(Y.duration&16711680)>>>16,v[L++]=(Y.duration&65280)>>>8,v[L++]=Y.duration&255,v[L++]=(Y.size&4278190080)>>>24,v[L++]=(Y.size&16711680)>>>16,v[L++]=(Y.size&65280)>>>8,v[L++]=Y.size&255;return u(k.trun,v)},j=function(p,_){return p.type==="audio"?c(p,_):h(p,_)}})();var De={ftyp:g,mdat:y,moof:B,moov:T,initSegment:function(c){var h=g(),m=T(c),p;return p=new Uint8Array(h.byteLength+m.byteLength),p.set(h),p.set(m,h.byteLength),p}},Oe=function(c){var h,m,p=[],_=[];for(_.byteLength=0,_.nalCount=0,_.duration=0,p.byteLength=0,h=0;h<c.length;h++)m=c[h],m.nalUnitType==="access_unit_delimiter_rbsp"?(p.length&&(p.duration=m.dts-p.dts,_.byteLength+=p.byteLength,_.nalCount+=p.length,_.duration+=p.duration,_.push(p)),p=[m],p.byteLength=m.data.byteLength,p.pts=m.pts,p.dts=m.dts):(m.nalUnitType==="slice_layer_without_partitioning_rbsp_idr"&&(p.keyFrame=!0),p.duration=m.dts-p.dts,p.byteLength+=m.data.byteLength,p.push(m));return _.length&&(!p.duration||p.duration<=0)&&(p.duration=_[_.length-1].duration),_.byteLength+=p.byteLength,_.nalCount+=p.length,_.duration+=p.duration,_.push(p),_},We=function(c){var h,m,p=[],_=[];for(p.byteLength=0,p.nalCount=0,p.duration=0,p.pts=c[0].pts,p.dts=c[0].dts,_.byteLength=0,_.nalCount=0,_.duration=0,_.pts=c[0].pts,_.dts=c[0].dts,h=0;h<c.length;h++)m=c[h],m.keyFrame?(p.length&&(_.push(p),_.byteLength+=p.byteLength,_.nalCount+=p.nalCount,_.duration+=p.duration),p=[m],p.nalCount=m.length,p.byteLength=m.byteLength,p.pts=m.pts,p.dts=m.dts,p.duration=m.duration):(p.duration+=m.duration,p.nalCount+=m.length,p.byteLength+=m.byteLength,p.push(m));return _.length&&p.duration<=0&&(p.duration=_[_.length-1].duration),_.byteLength+=p.byteLength,_.nalCount+=p.nalCount,_.duration+=p.duration,_.push(p),_},Me=function(c){var h;return!c[0][0].keyFrame&&c.length>1&&(h=c.shift(),c.byteLength-=h.byteLength,c.nalCount-=h.nalCount,c[0][0].dts=h.dts,c[0][0].pts=h.pts,c[0][0].duration+=h.duration),c},Se=function(){return{size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0,isNonSyncSample:1}}},me=function(c,h){var m=Se();return m.dataOffset=h,m.compositionTimeOffset=c.pts-c.dts,m.duration=c.duration,m.size=4*c.length,m.size+=c.byteLength,c.keyFrame&&(m.flags.dependsOn=2,m.flags.isNonSyncSample=0),m},ke=function(c,h){var m,p,_,v,L,R=h||0,z=[];for(m=0;m<c.length;m++)for(v=c[m],p=0;p<v.length;p++)L=v[p],_=me(L,R),R+=_.size,z.push(_);return z},Ve=function(c){var h,m,p,_,v,L,R=0,z=c.byteLength,Y=c.nalCount,ie=z+4*Y,ae=new Uint8Array(ie),Te=new DataView(ae.buffer);for(h=0;h<c.length;h++)for(_=c[h],m=0;m<_.length;m++)for(v=_[m],p=0;p<v.length;p++)L=v[p],Te.setUint32(R,L.data.byteLength),R+=4,ae.set(L.data,R),R+=L.data.byteLength;return ae},be=function(c,h){var m,p=h||0,_=[];return m=me(c,p),_.push(m),_},Le=function(c){var h,m,p=0,_=c.byteLength,v=c.length,L=_+4*v,R=new Uint8Array(L),z=new DataView(R.buffer);for(h=0;h<c.length;h++)m=c[h],z.setUint32(p,m.data.byteLength),p+=4,R.set(m.data,p),p+=m.data.byteLength;return R},ht={groupNalsIntoFrames:Oe,groupFramesIntoGops:We,extendFirstKeyFrame:Me,generateSampleTable:ke,concatenateNalData:Ve,generateSampleTableForFrame:be,concatenateNalDataForFrame:Le},Ze=[33,16,5,32,164,27],at=[33,65,108,84,1,2,4,8,168,2,4,8,17,191,252],Pe=function(c){for(var h=[];c--;)h.push(0);return h},Fe=function(c){return Object.keys(c).reduce(function(h,m){return h[m]=new Uint8Array(c[m].reduce(function(p,_){return p.concat(_)},[])),h},{})},ot,Ct=function(){if(!ot){var c={96e3:[Ze,[227,64],Pe(154),[56]],88200:[Ze,[231],Pe(170),[56]],64e3:[Ze,[248,192],Pe(240),[56]],48e3:[Ze,[255,192],Pe(268),[55,148,128],Pe(54),[112]],44100:[Ze,[255,192],Pe(268),[55,163,128],Pe(84),[112]],32e3:[Ze,[255,192],Pe(268),[55,234],Pe(226),[112]],24e3:[Ze,[255,192],Pe(268),[55,255,128],Pe(268),[111,112],Pe(126),[224]],16e3:[Ze,[255,192],Pe(268),[55,255,128],Pe(268),[111,255],Pe(269),[223,108],Pe(195),[1,192]],12e3:[at,Pe(268),[3,127,248],Pe(268),[6,255,240],Pe(268),[13,255,224],Pe(268),[27,253,128],Pe(259),[56]],11025:[at,Pe(268),[3,127,248],Pe(268),[6,255,240],Pe(268),[13,255,224],Pe(268),[27,255,192],Pe(268),[55,175,128],Pe(108),[112]],8e3:[at,Pe(268),[3,121,16],Pe(47),[7]]};ot=Fe(c)}return ot},fe=9e4,ye,_e,je,we,_t,Mt,Pi;ye=function(c){return c*fe},_e=function(c,h){return c*h},je=function(c){return c/fe},we=function(c,h){return c/h},_t=function(c,h){return ye(we(c,h))},Mt=function(c,h){return _e(je(c),h)},Pi=function(c,h,m){return je(m?c:c-h)};var Ye={ONE_SECOND_IN_TS:fe,secondsToVideoTs:ye,secondsToAudioTs:_e,videoTsToSeconds:je,audioTsToSeconds:we,audioTsToVideoTs:_t,videoTsToAudioTs:Mt,metadataTsToSeconds:Pi},xi=Ct,jt=Ye,Ci=function(c){var h,m,p=0;for(h=0;h<c.length;h++)m=c[h],p+=m.data.byteLength;return p},yt=function(c,h,m,p){var _,v=0,L=0,R=0,z=0,Y,ie,ae;if(h.length&&(_=jt.audioTsToVideoTs(c.baseMediaDecodeTime,c.samplerate),v=Math.ceil(jt.ONE_SECOND_IN_TS/(c.samplerate/1024)),m&&p&&(L=_-Math.max(m,p),R=Math.floor(L/v),z=R*v),!(R<1||z>jt.ONE_SECOND_IN_TS/2))){for(Y=xi()[c.samplerate],Y||(Y=h[0].data),ie=0;ie<R;ie++)ae=h[0],h.splice(0,0,{data:Y,dts:ae.dts-v,pts:ae.pts-v});return c.baseMediaDecodeTime-=Math.floor(jt.videoTsToAudioTs(z,c.samplerate)),z}},ei=function(c,h,m){return h.minSegmentDts>=m?c:(h.minSegmentDts=1/0,c.filter(function(p){return p.dts>=m?(h.minSegmentDts=Math.min(h.minSegmentDts,p.dts),h.minSegmentPts=h.minSegmentDts,!0):!1}))},li=function(c){var h,m,p=[];for(h=0;h<c.length;h++)m=c[h],p.push({size:m.data.byteLength,duration:1024});return p},Ht=function(c){var h,m,p=0,_=new Uint8Array(Ci(c));for(h=0;h<c.length;h++)m=c[h],_.set(m.data,p),p+=m.data.byteLength;return _},Yi={prefixWithSilence:yt,trimAdtsFramesByEarliestDts:ei,generateSampleTable:li,concatenateFrameData:Ht},Rt=Ye.ONE_SECOND_IN_TS,Si=function(c,h){typeof h.pts=="number"&&(c.timelineStartInfo.pts===void 0&&(c.timelineStartInfo.pts=h.pts),c.minSegmentPts===void 0?c.minSegmentPts=h.pts:c.minSegmentPts=Math.min(c.minSegmentPts,h.pts),c.maxSegmentPts===void 0?c.maxSegmentPts=h.pts:c.maxSegmentPts=Math.max(c.maxSegmentPts,h.pts)),typeof h.dts=="number"&&(c.timelineStartInfo.dts===void 0&&(c.timelineStartInfo.dts=h.dts),c.minSegmentDts===void 0?c.minSegmentDts=h.dts:c.minSegmentDts=Math.min(c.minSegmentDts,h.dts),c.maxSegmentDts===void 0?c.maxSegmentDts=h.dts:c.maxSegmentDts=Math.max(c.maxSegmentDts,h.dts))},S=function(c){delete c.minSegmentDts,delete c.maxSegmentDts,delete c.minSegmentPts,delete c.maxSegmentPts},D=function(c,h){var m,p,_=c.minSegmentDts;return h||(_-=c.timelineStartInfo.dts),m=c.timelineStartInfo.baseMediaDecodeTime,m+=_,m=Math.max(0,m),c.type==="audio"&&(p=c.samplerate/Rt,m*=p,m=Math.floor(m)),m},X={clearDtsInfo:S,calculateTrackBaseMediaDecodeTime:D,collectDtsInfo:Si},re=4,ge=128,Ie=function(c){for(var h=0,m={payloadType:-1,payloadSize:0},p=0,_=0;h<c.byteLength&&c[h]!==ge;){for(;c[h]===255;)p+=255,h++;for(p+=c[h++];c[h]===255;)_+=255,h++;if(_+=c[h++],!m.payload&&p===re){var v=String.fromCharCode(c[h+3],c[h+4],c[h+5],c[h+6]);if(v==="GA94"){m.payloadType=p,m.payloadSize=_,m.payload=c.subarray(h,h+_);break}else m.payload=void 0}h+=_,p=0,_=0}return m},Je=function(c){return c.payload[0]!==181||(c.payload[1]<<8|c.payload[2])!==49||String.fromCharCode(c.payload[3],c.payload[4],c.payload[5],c.payload[6])!=="GA94"||c.payload[7]!==3?null:c.payload.subarray(8,c.payload.length-1)},St=function(c,h){var m=[],p,_,v,L;if(!(h[0]&64))return m;for(_=h[0]&31,p=0;p<_;p++)v=p*3,L={type:h[v+2]&3,pts:c},h[v+2]&4&&(L.ccData=h[v+3]<<8|h[v+4],m.push(L));return m},zt=function(c){for(var h=c.byteLength,m=[],p=1,_,v;p<h-2;)c[p]===0&&c[p+1]===0&&c[p+2]===3?(m.push(p+2),p+=2):p++;if(m.length===0)return c;_=h-m.length,v=new Uint8Array(_);var L=0;for(p=0;p<_;L++,p++)L===m[0]&&(L++,m.shift()),v[p]=c[L];return v},Vt={parseSei:Ie,parseUserData:Je,parseCaptionPackets:St,discardEmulationPreventionBytes:zt,USER_DATA_REGISTERED_ITU_T_T35:re},Ot=i,ti=Vt,Xe=function(c){c=c||{},Xe.prototype.init.call(this),this.parse708captions_=typeof c.parse708captions=="boolean"?c.parse708captions:!0,this.captionPackets_=[],this.ccStreams_=[new ve(0,0),new ve(0,1),new ve(1,0),new ve(1,1)],this.parse708captions_&&(this.cc708Stream_=new He({captionServices:c.captionServices})),this.reset(),this.ccStreams_.forEach(function(h){h.on("data",this.trigger.bind(this,"data")),h.on("partialdone",this.trigger.bind(this,"partialdone")),h.on("done",this.trigger.bind(this,"done"))},this),this.parse708captions_&&(this.cc708Stream_.on("data",this.trigger.bind(this,"data")),this.cc708Stream_.on("partialdone",this.trigger.bind(this,"partialdone")),this.cc708Stream_.on("done",this.trigger.bind(this,"done")))};Xe.prototype=new Ot,Xe.prototype.push=function(c){var h,m,p;if(c.nalUnitType==="sei_rbsp"&&(h=ti.parseSei(c.escapedRBSP),!!h.payload&&h.payloadType===ti.USER_DATA_REGISTERED_ITU_T_T35&&(m=ti.parseUserData(h),!!m))){if(c.dts<this.latestDts_){this.ignoreNextEqualDts_=!0;return}else if(c.dts===this.latestDts_&&this.ignoreNextEqualDts_){this.numSameDts_--,this.numSameDts_||(this.ignoreNextEqualDts_=!1);return}p=ti.parseCaptionPackets(c.pts,m),this.captionPackets_=this.captionPackets_.concat(p),this.latestDts_!==c.dts&&(this.numSameDts_=0),this.numSameDts_++,this.latestDts_=c.dts}},Xe.prototype.flushCCStreams=function(c){this.ccStreams_.forEach(function(h){return c==="flush"?h.flush():h.partialFlush()},this)},Xe.prototype.flushStream=function(c){if(!this.captionPackets_.length){this.flushCCStreams(c);return}this.captionPackets_.forEach(function(h,m){h.presortIndex=m}),this.captionPackets_.sort(function(h,m){return h.pts===m.pts?h.presortIndex-m.presortIndex:h.pts-m.pts}),this.captionPackets_.forEach(function(h){h.type<2?this.dispatchCea608Packet(h):this.dispatchCea708Packet(h)},this),this.captionPackets_.length=0,this.flushCCStreams(c)},Xe.prototype.flush=function(){return this.flushStream("flush")},Xe.prototype.partialFlush=function(){return this.flushStream("partialFlush")},Xe.prototype.reset=function(){this.latestDts_=null,this.ignoreNextEqualDts_=!1,this.numSameDts_=0,this.activeCea608Channel_=[null,null],this.ccStreams_.forEach(function(c){c.reset()})},Xe.prototype.dispatchCea608Packet=function(c){this.setsTextOrXDSActive(c)?this.activeCea608Channel_[c.type]=null:this.setsChannel1Active(c)?this.activeCea608Channel_[c.type]=0:this.setsChannel2Active(c)&&(this.activeCea608Channel_[c.type]=1),this.activeCea608Channel_[c.type]!==null&&this.ccStreams_[(c.type<<1)+this.activeCea608Channel_[c.type]].push(c)},Xe.prototype.setsChannel1Active=function(c){return(c.ccData&30720)===4096},Xe.prototype.setsChannel2Active=function(c){return(c.ccData&30720)===6144},Xe.prototype.setsTextOrXDSActive=function(c){return(c.ccData&28928)===256||(c.ccData&30974)===4138||(c.ccData&30974)===6186},Xe.prototype.dispatchCea708Packet=function(c){this.parse708captions_&&this.cc708Stream_.push(c)};var ii={127:9834,4128:32,4129:160,4133:8230,4138:352,4140:338,4144:9608,4145:8216,4146:8217,4147:8220,4148:8221,4149:8226,4153:8482,4154:353,4156:339,4157:8480,4159:376,4214:8539,4215:8540,4216:8541,4217:8542,4218:9168,4219:9124,4220:9123,4221:9135,4222:9126,4223:9121,4256:12600},Gt=function(c){var h=ii[c]||c;return c&4096&&c===h?"":String.fromCharCode(h)},Wt=function(c){return 32<=c&&c<=127||160<=c&&c<=255},Et=function(c){this.windowNum=c,this.reset()};Et.prototype.reset=function(){this.clearText(),this.pendingNewLine=!1,this.winAttr={},this.penAttr={},this.penLoc={},this.penColor={},this.visible=0,this.rowLock=0,this.columnLock=0,this.priority=0,this.relativePositioning=0,this.anchorVertical=0,this.anchorHorizontal=0,this.anchorPoint=0,this.rowCount=1,this.virtualRowCount=this.rowCount+1,this.columnCount=41,this.windowStyle=0,this.penStyle=0},Et.prototype.getText=function(){return this.rows.join(`
|
|
206
|
+
`)},Et.prototype.clearText=function(){this.rows=[""],this.rowIdx=0},Et.prototype.newLine=function(c){for(this.rows.length>=this.virtualRowCount&&typeof this.beforeRowOverflow=="function"&&this.beforeRowOverflow(c),this.rows.length>0&&(this.rows.push(""),this.rowIdx++);this.rows.length>this.virtualRowCount;)this.rows.shift(),this.rowIdx--},Et.prototype.isEmpty=function(){return this.rows.length===0?!0:this.rows.length===1?this.rows[0]==="":!1},Et.prototype.addText=function(c){this.rows[this.rowIdx]+=c},Et.prototype.backspace=function(){if(!this.isEmpty()){var c=this.rows[this.rowIdx];this.rows[this.rowIdx]=c.substr(0,c.length-1)}};var st=function(c,h,m){this.serviceNum=c,this.text="",this.currentWindow=new Et(-1),this.windows=[],this.stream=m,typeof h=="string"&&this.createTextDecoder(h)};st.prototype.init=function(c,h){this.startPts=c;for(var m=0;m<8;m++)this.windows[m]=new Et(m),typeof h=="function"&&(this.windows[m].beforeRowOverflow=h)},st.prototype.setCurrentWindow=function(c){this.currentWindow=this.windows[c]},st.prototype.createTextDecoder=function(c){if(typeof TextDecoder>"u")this.stream.trigger("log",{level:"warn",message:"The `encoding` option is unsupported without TextDecoder support"});else try{this.textDecoder_=new TextDecoder(c)}catch(h){this.stream.trigger("log",{level:"warn",message:"TextDecoder could not be created with "+c+" encoding. "+h})}};var He=function(c){c=c||{},He.prototype.init.call(this);var h=this,m=c.captionServices||{},p={},_;Object.keys(m).forEach(v=>{_=m[v],/^SERVICE/.test(v)&&(p[v]=_.encoding)}),this.serviceEncodings=p,this.current708Packet=null,this.services={},this.push=function(v){v.type===3?(h.new708Packet(),h.add708Bytes(v)):(h.current708Packet===null&&h.new708Packet(),h.add708Bytes(v))}};He.prototype=new Ot,He.prototype.new708Packet=function(){this.current708Packet!==null&&this.push708Packet(),this.current708Packet={data:[],ptsVals:[]}},He.prototype.add708Bytes=function(c){var h=c.ccData,m=h>>>8,p=h&255;this.current708Packet.ptsVals.push(c.pts),this.current708Packet.data.push(m),this.current708Packet.data.push(p)},He.prototype.push708Packet=function(){var c=this.current708Packet,h=c.data,m=null,p=null,_=0,v=h[_++];for(c.seq=v>>6,c.sizeCode=v&63;_<h.length;_++)v=h[_++],m=v>>5,p=v&31,m===7&&p>0&&(v=h[_++],m=v),this.pushServiceBlock(m,_,p),p>0&&(_+=p-1)},He.prototype.pushServiceBlock=function(c,h,m){var p,_=h,v=this.current708Packet.data,L=this.services[c];for(L||(L=this.initService(c,_));_<h+m&&_<v.length;_++)p=v[_],Wt(p)?_=this.handleText(_,L):p===24?_=this.multiByteCharacter(_,L):p===16?_=this.extendedCommands(_,L):128<=p&&p<=135?_=this.setCurrentWindow(_,L):152<=p&&p<=159?_=this.defineWindow(_,L):p===136?_=this.clearWindows(_,L):p===140?_=this.deleteWindows(_,L):p===137?_=this.displayWindows(_,L):p===138?_=this.hideWindows(_,L):p===139?_=this.toggleWindows(_,L):p===151?_=this.setWindowAttributes(_,L):p===144?_=this.setPenAttributes(_,L):p===145?_=this.setPenColor(_,L):p===146?_=this.setPenLocation(_,L):p===143?L=this.reset(_,L):p===8?L.currentWindow.backspace():p===12?L.currentWindow.clearText():p===13?L.currentWindow.pendingNewLine=!0:p===14?L.currentWindow.clearText():p===141&&_++},He.prototype.extendedCommands=function(c,h){var m=this.current708Packet.data,p=m[++c];return Wt(p)&&(c=this.handleText(c,h,{isExtended:!0})),c},He.prototype.getPts=function(c){return this.current708Packet.ptsVals[Math.floor(c/2)]},He.prototype.initService=function(c,h){var p="SERVICE"+c,m=this,p,_;return p in this.serviceEncodings&&(_=this.serviceEncodings[p]),this.services[c]=new st(c,_,m),this.services[c].init(this.getPts(h),function(v){m.flushDisplayed(v,m.services[c])}),this.services[c]},He.prototype.handleText=function(c,h,m){var p=m&&m.isExtended,_=m&&m.isMultiByte,v=this.current708Packet.data,L=p?4096:0,R=v[c],z=v[c+1],Y=h.currentWindow,ie,ae;function Te(le){return le.map(Ae=>("0"+(Ae&255).toString(16)).slice(-2)).join("")}if(_?(ae=[R,z],c++):ae=[R],h.textDecoder_&&!p)ie=h.textDecoder_.decode(new Uint8Array(ae));else if(_){const le=Te(ae);ie=String.fromCharCode(parseInt(le,16))}else ie=Gt(L|R);return Y.pendingNewLine&&!Y.isEmpty()&&Y.newLine(this.getPts(c)),Y.pendingNewLine=!1,Y.addText(ie),c},He.prototype.multiByteCharacter=function(c,h){var m=this.current708Packet.data,p=m[c+1],_=m[c+2];return Wt(p)&&Wt(_)&&(c=this.handleText(++c,h,{isMultiByte:!0})),c},He.prototype.setCurrentWindow=function(c,h){var m=this.current708Packet.data,p=m[c],_=p&7;return h.setCurrentWindow(_),c},He.prototype.defineWindow=function(c,h){var m=this.current708Packet.data,p=m[c],_=p&7;h.setCurrentWindow(_);var v=h.currentWindow;return p=m[++c],v.visible=(p&32)>>5,v.rowLock=(p&16)>>4,v.columnLock=(p&8)>>3,v.priority=p&7,p=m[++c],v.relativePositioning=(p&128)>>7,v.anchorVertical=p&127,p=m[++c],v.anchorHorizontal=p,p=m[++c],v.anchorPoint=(p&240)>>4,v.rowCount=p&15,p=m[++c],v.columnCount=p&63,p=m[++c],v.windowStyle=(p&56)>>3,v.penStyle=p&7,v.virtualRowCount=v.rowCount+1,c},He.prototype.setWindowAttributes=function(c,h){var m=this.current708Packet.data,p=m[c],_=h.currentWindow.winAttr;return p=m[++c],_.fillOpacity=(p&192)>>6,_.fillRed=(p&48)>>4,_.fillGreen=(p&12)>>2,_.fillBlue=p&3,p=m[++c],_.borderType=(p&192)>>6,_.borderRed=(p&48)>>4,_.borderGreen=(p&12)>>2,_.borderBlue=p&3,p=m[++c],_.borderType+=(p&128)>>5,_.wordWrap=(p&64)>>6,_.printDirection=(p&48)>>4,_.scrollDirection=(p&12)>>2,_.justify=p&3,p=m[++c],_.effectSpeed=(p&240)>>4,_.effectDirection=(p&12)>>2,_.displayEffect=p&3,c},He.prototype.flushDisplayed=function(c,h){for(var m=[],p=0;p<8;p++)h.windows[p].visible&&!h.windows[p].isEmpty()&&m.push(h.windows[p].getText());h.endPts=c,h.text=m.join(`
|
|
207
|
+
|
|
208
|
+
`),this.pushCaption(h),h.startPts=c},He.prototype.pushCaption=function(c){c.text!==""&&(this.trigger("data",{startPts:c.startPts,endPts:c.endPts,text:c.text,stream:"cc708_"+c.serviceNum}),c.text="",c.startPts=c.endPts)},He.prototype.displayWindows=function(c,h){var m=this.current708Packet.data,p=m[++c],_=this.getPts(c);this.flushDisplayed(_,h);for(var v=0;v<8;v++)p&1<<v&&(h.windows[v].visible=1);return c},He.prototype.hideWindows=function(c,h){var m=this.current708Packet.data,p=m[++c],_=this.getPts(c);this.flushDisplayed(_,h);for(var v=0;v<8;v++)p&1<<v&&(h.windows[v].visible=0);return c},He.prototype.toggleWindows=function(c,h){var m=this.current708Packet.data,p=m[++c],_=this.getPts(c);this.flushDisplayed(_,h);for(var v=0;v<8;v++)p&1<<v&&(h.windows[v].visible^=1);return c},He.prototype.clearWindows=function(c,h){var m=this.current708Packet.data,p=m[++c],_=this.getPts(c);this.flushDisplayed(_,h);for(var v=0;v<8;v++)p&1<<v&&h.windows[v].clearText();return c},He.prototype.deleteWindows=function(c,h){var m=this.current708Packet.data,p=m[++c],_=this.getPts(c);this.flushDisplayed(_,h);for(var v=0;v<8;v++)p&1<<v&&h.windows[v].reset();return c},He.prototype.setPenAttributes=function(c,h){var m=this.current708Packet.data,p=m[c],_=h.currentWindow.penAttr;return p=m[++c],_.textTag=(p&240)>>4,_.offset=(p&12)>>2,_.penSize=p&3,p=m[++c],_.italics=(p&128)>>7,_.underline=(p&64)>>6,_.edgeType=(p&56)>>3,_.fontStyle=p&7,c},He.prototype.setPenColor=function(c,h){var m=this.current708Packet.data,p=m[c],_=h.currentWindow.penColor;return p=m[++c],_.fgOpacity=(p&192)>>6,_.fgRed=(p&48)>>4,_.fgGreen=(p&12)>>2,_.fgBlue=p&3,p=m[++c],_.bgOpacity=(p&192)>>6,_.bgRed=(p&48)>>4,_.bgGreen=(p&12)>>2,_.bgBlue=p&3,p=m[++c],_.edgeRed=(p&48)>>4,_.edgeGreen=(p&12)>>2,_.edgeBlue=p&3,c},He.prototype.setPenLocation=function(c,h){var m=this.current708Packet.data,p=m[c],_=h.currentWindow.penLoc;return h.currentWindow.pendingNewLine=!0,p=m[++c],_.row=p&15,p=m[++c],_.column=p&63,c},He.prototype.reset=function(c,h){var m=this.getPts(c);return this.flushDisplayed(m,h),this.initService(h.serviceNum,c)};var Ei={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,304:174,305:176,306:189,307:191,308:8482,309:162,310:163,311:9834,312:224,313:160,314:232,315:226,316:234,317:238,318:244,319:251,544:193,545:201,546:211,547:218,548:220,549:252,550:8216,551:161,552:42,553:39,554:8212,555:169,556:8480,557:8226,558:8220,559:8221,560:192,561:194,562:199,563:200,564:202,565:203,566:235,567:206,568:207,569:239,570:212,571:217,572:249,573:219,574:171,575:187,800:195,801:227,802:205,803:204,804:236,805:210,806:242,807:213,808:245,809:123,810:125,811:92,812:94,813:95,814:124,815:126,816:196,817:228,818:214,819:246,820:223,821:165,822:164,823:9474,824:197,825:229,826:216,827:248,828:9484,829:9488,830:9492,831:9496},Mi=function(c){return c===null?"":(c=Ei[c]||c,String.fromCharCode(c))},Tn=14,fs=[4352,4384,4608,4640,5376,5408,5632,5664,5888,5920,4096,4864,4896,5120,5152],Xi=function(){for(var c=[],h=Tn+1;h--;)c.push({text:"",indent:0,offset:0});return c},ve=function(c,h){ve.prototype.init.call(this),this.field_=c||0,this.dataChannel_=h||0,this.name_="CC"+((this.field_<<1|this.dataChannel_)+1),this.setConstants(),this.reset(),this.push=function(m){var p,_,v,L,R;if(p=m.ccData&32639,p===this.lastControlCode_){this.lastControlCode_=null;return}if((p&61440)===4096?this.lastControlCode_=p:p!==this.PADDING_&&(this.lastControlCode_=null),v=p>>>8,L=p&255,p!==this.PADDING_)if(p===this.RESUME_CAPTION_LOADING_)this.mode_="popOn";else if(p===this.END_OF_CAPTION_)this.mode_="popOn",this.clearFormatting(m.pts),this.flushDisplayed(m.pts),_=this.displayed_,this.displayed_=this.nonDisplayed_,this.nonDisplayed_=_,this.startPts_=m.pts;else if(p===this.ROLL_UP_2_ROWS_)this.rollUpRows_=2,this.setRollUp(m.pts);else if(p===this.ROLL_UP_3_ROWS_)this.rollUpRows_=3,this.setRollUp(m.pts);else if(p===this.ROLL_UP_4_ROWS_)this.rollUpRows_=4,this.setRollUp(m.pts);else if(p===this.CARRIAGE_RETURN_)this.clearFormatting(m.pts),this.flushDisplayed(m.pts),this.shiftRowsUp_(),this.startPts_=m.pts;else if(p===this.BACKSPACE_)this.mode_==="popOn"?this.nonDisplayed_[this.row_].text=this.nonDisplayed_[this.row_].text.slice(0,-1):this.displayed_[this.row_].text=this.displayed_[this.row_].text.slice(0,-1);else if(p===this.ERASE_DISPLAYED_MEMORY_)this.flushDisplayed(m.pts),this.displayed_=Xi();else if(p===this.ERASE_NON_DISPLAYED_MEMORY_)this.nonDisplayed_=Xi();else if(p===this.RESUME_DIRECT_CAPTIONING_)this.mode_!=="paintOn"&&(this.flushDisplayed(m.pts),this.displayed_=Xi()),this.mode_="paintOn",this.startPts_=m.pts;else if(this.isSpecialCharacter(v,L))v=(v&3)<<8,R=Mi(v|L),this[this.mode_](m.pts,R),this.column_++;else if(this.isExtCharacter(v,L))this.mode_==="popOn"?this.nonDisplayed_[this.row_].text=this.nonDisplayed_[this.row_].text.slice(0,-1):this.displayed_[this.row_].text=this.displayed_[this.row_].text.slice(0,-1),v=(v&3)<<8,R=Mi(v|L),this[this.mode_](m.pts,R),this.column_++;else if(this.isMidRowCode(v,L))this.clearFormatting(m.pts),this[this.mode_](m.pts," "),this.column_++,(L&14)===14&&this.addFormatting(m.pts,["i"]),(L&1)===1&&this.addFormatting(m.pts,["u"]);else if(this.isOffsetControlCode(v,L)){const Y=L&3;this.nonDisplayed_[this.row_].offset=Y,this.column_+=Y}else if(this.isPAC(v,L)){var z=fs.indexOf(p&7968);if(this.mode_==="rollUp"&&(z-this.rollUpRows_+1<0&&(z=this.rollUpRows_-1),this.setRollUp(m.pts,z)),z!==this.row_&&z>=0&&z<=14&&(this.clearFormatting(m.pts),this.row_=z),L&1&&this.formatting_.indexOf("u")===-1&&this.addFormatting(m.pts,["u"]),(p&16)===16){const Y=(p&14)>>1;this.column_=Y*4,this.nonDisplayed_[this.row_].indent+=Y}this.isColorPAC(L)&&(L&14)===14&&this.addFormatting(m.pts,["i"])}else this.isNormalChar(v)&&(L===0&&(L=null),R=Mi(v),R+=Mi(L),this[this.mode_](m.pts,R),this.column_+=R.length)}};ve.prototype=new Ot,ve.prototype.flushDisplayed=function(c){const h=p=>{this.trigger("log",{level:"warn",message:"Skipping a malformed 608 caption at index "+p+"."})},m=[];this.displayed_.forEach((p,_)=>{if(p&&p.text&&p.text.length){try{p.text=p.text.trim()}catch{h(_)}p.text.length&&m.push({text:p.text,line:_+1,position:10+Math.min(70,p.indent*10)+p.offset*2.5})}else p==null&&h(_)}),m.length&&this.trigger("data",{startPts:this.startPts_,endPts:c,content:m,stream:this.name_})},ve.prototype.reset=function(){this.mode_="popOn",this.topRow_=0,this.startPts_=0,this.displayed_=Xi(),this.nonDisplayed_=Xi(),this.lastControlCode_=null,this.column_=0,this.row_=Tn,this.rollUpRows_=2,this.formatting_=[]},ve.prototype.setConstants=function(){this.dataChannel_===0?(this.BASE_=16,this.EXT_=17,this.CONTROL_=(20|this.field_)<<8,this.OFFSET_=23):this.dataChannel_===1&&(this.BASE_=24,this.EXT_=25,this.CONTROL_=(28|this.field_)<<8,this.OFFSET_=31),this.PADDING_=0,this.RESUME_CAPTION_LOADING_=this.CONTROL_|32,this.END_OF_CAPTION_=this.CONTROL_|47,this.ROLL_UP_2_ROWS_=this.CONTROL_|37,this.ROLL_UP_3_ROWS_=this.CONTROL_|38,this.ROLL_UP_4_ROWS_=this.CONTROL_|39,this.CARRIAGE_RETURN_=this.CONTROL_|45,this.RESUME_DIRECT_CAPTIONING_=this.CONTROL_|41,this.BACKSPACE_=this.CONTROL_|33,this.ERASE_DISPLAYED_MEMORY_=this.CONTROL_|44,this.ERASE_NON_DISPLAYED_MEMORY_=this.CONTROL_|46},ve.prototype.isSpecialCharacter=function(c,h){return c===this.EXT_&&h>=48&&h<=63},ve.prototype.isExtCharacter=function(c,h){return(c===this.EXT_+1||c===this.EXT_+2)&&h>=32&&h<=63},ve.prototype.isMidRowCode=function(c,h){return c===this.EXT_&&h>=32&&h<=47},ve.prototype.isOffsetControlCode=function(c,h){return c===this.OFFSET_&&h>=33&&h<=35},ve.prototype.isPAC=function(c,h){return c>=this.BASE_&&c<this.BASE_+8&&h>=64&&h<=127},ve.prototype.isColorPAC=function(c){return c>=64&&c<=79||c>=96&&c<=127},ve.prototype.isNormalChar=function(c){return c>=32&&c<=127},ve.prototype.setRollUp=function(c,h){if(this.mode_!=="rollUp"&&(this.row_=Tn,this.mode_="rollUp",this.flushDisplayed(c),this.nonDisplayed_=Xi(),this.displayed_=Xi()),h!==void 0&&h!==this.row_)for(var m=0;m<this.rollUpRows_;m++)this.displayed_[h-m]=this.displayed_[this.row_-m],this.displayed_[this.row_-m]={text:"",indent:0,offset:0};h===void 0&&(h=this.row_),this.topRow_=h-this.rollUpRows_+1},ve.prototype.addFormatting=function(c,h){this.formatting_=this.formatting_.concat(h);var m=h.reduce(function(p,_){return p+"<"+_+">"},"");this[this.mode_](c,m)},ve.prototype.clearFormatting=function(c){if(this.formatting_.length){var h=this.formatting_.reverse().reduce(function(m,p){return m+"</"+p+">"},"");this.formatting_=[],this[this.mode_](c,h)}},ve.prototype.popOn=function(c,h){var m=this.nonDisplayed_[this.row_].text;m+=h,this.nonDisplayed_[this.row_].text=m},ve.prototype.rollUp=function(c,h){var m=this.displayed_[this.row_].text;m+=h,this.displayed_[this.row_].text=m},ve.prototype.shiftRowsUp_=function(){var c;for(c=0;c<this.topRow_;c++)this.displayed_[c]={text:"",indent:0,offset:0};for(c=this.row_+1;c<Tn+1;c++)this.displayed_[c]={text:"",indent:0,offset:0};for(c=this.topRow_;c<this.row_;c++)this.displayed_[c]=this.displayed_[c+1];this.displayed_[this.row_]={text:"",indent:0,offset:0}},ve.prototype.paintOn=function(c,h){var m=this.displayed_[this.row_].text;m+=h,this.displayed_[this.row_].text=m};var ee={CaptionStream:Xe,Cea608Stream:ve,Cea708Stream:He},he={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21},xe=i,Qe=8589934592,Ft=4294967296,kt="shared",vt=function(c,h){var m=1;for(c>h&&(m=-1);Math.abs(h-c)>Ft;)c+=m*Qe;return c},ki=function(c){var h,m;ki.prototype.init.call(this),this.type_=c||kt,this.push=function(p){if(p.type==="metadata"){this.trigger("data",p);return}this.type_!==kt&&p.type!==this.type_||(m===void 0&&(m=p.dts),p.dts=vt(p.dts,m),p.pts=vt(p.pts,m),h=p.dts,this.trigger("data",p))},this.flush=function(){m=h,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.discontinuity=function(){m=void 0,h=void 0},this.reset=function(){this.discontinuity(),this.trigger("reset")}};ki.prototype=new xe;var mt={TimestampRolloverStream:ki,handleRollover:vt},xr=(c,h,m)=>{if(!c)return-1;for(var p=m;p<c.length;p++)if(c[p]===h)return p;return-1},ps={typedArrayIndexOf:xr},Cr=ps.typedArrayIndexOf,ms={Utf8:3},mu=function(c,h,m){var p,_="";for(p=h;p<m;p++)_+="%"+("00"+c[p].toString(16)).slice(-2);return _},Sr=function(c,h,m){return decodeURIComponent(mu(c,h,m))},Er=function(c,h,m){return unescape(mu(c,h,m))},kr=function(c){return c[0]<<21|c[1]<<14|c[2]<<7|c[3]},wr={APIC:function(c){var h=1,m,p,_="-->";c.data[0]===ms.Utf8&&(m=Cr(c.data,0,h),!(m<0)&&(c.mimeType=Er(c.data,h,m),h=m+1,c.pictureType=c.data[h],h++,p=Cr(c.data,0,h),!(p<0)&&(c.description=Sr(c.data,h,p),h=p+1,c.mimeType===_?c.url=Er(c.data,h,c.data.length):c.pictureData=c.data.subarray(h,c.data.length))))},"T*":function(c){c.data[0]===ms.Utf8&&(c.value=Sr(c.data,1,c.data.length).replace(/\0*$/,""),c.values=c.value.split("\0"))},TXXX:function(c){var h;c.data[0]===ms.Utf8&&(h=Cr(c.data,0,1),h!==-1&&(c.description=Sr(c.data,1,h),c.value=Sr(c.data,h+1,c.data.length).replace(/\0*$/,""),c.data=c.value))},"W*":function(c){c.url=Er(c.data,0,c.data.length).replace(/\0.*$/,"")},WXXX:function(c){var h;c.data[0]===ms.Utf8&&(h=Cr(c.data,0,1),h!==-1&&(c.description=Sr(c.data,1,h),c.url=Er(c.data,h+1,c.data.length).replace(/\0.*$/,"")))},PRIV:function(c){var h;for(h=0;h<c.data.length;h++)if(c.data[h]===0){c.owner=Er(c.data,0,h);break}c.privateData=c.data.subarray(h+1),c.data=c.privateData}},pp=function(c){var h,m,p=10,_=0,v=[];if(!(c.length<10||c[0]!==73||c[1]!==68||c[2]!==51)){_=kr(c.subarray(6,10)),_+=10;var L=c[5]&64;L&&(p+=4,p+=kr(c.subarray(10,14)),_-=kr(c.subarray(16,20)));do{if(h=kr(c.subarray(p+4,p+8)),h<1)break;m=String.fromCharCode(c[p],c[p+1],c[p+2],c[p+3]);var R={id:m,data:c.subarray(p+10,p+h+10)};R.key=R.id,wr[R.id]?wr[R.id](R):R.id[0]==="T"?wr["T*"](R):R.id[0]==="W"&&wr["W*"](R),v.push(R),p+=10,p+=h}while(p<_);return v}},gu={parseId3Frames:pp,parseSyncSafeInteger:kr,frameParsers:wr},mp=i,gp=he,an=gu,gs;gs=function(c){var h={descriptor:c&&c.descriptor},m=0,p=[],_=0,v;if(gs.prototype.init.call(this),this.dispatchType=gp.METADATA_STREAM_TYPE.toString(16),h.descriptor)for(v=0;v<h.descriptor.length;v++)this.dispatchType+=("00"+h.descriptor[v].toString(16)).slice(-2);this.push=function(L){var R,z,Y,ie,ae,Te;if(L.type==="timed-metadata"){if(L.dataAlignmentIndicator&&(_=0,p.length=0),p.length===0&&(L.data.length<10||L.data[0]!==73||L.data[1]!==68||L.data[2]!==51)){this.trigger("log",{level:"warn",message:"Skipping unrecognized metadata packet"});return}if(p.push(L),_+=L.data.byteLength,p.length===1&&(m=an.parseSyncSafeInteger(L.data.subarray(6,10)),m+=10),!(_<m)){for(R={data:new Uint8Array(m),frames:[],pts:p[0].pts,dts:p[0].dts},ae=0;ae<m;)R.data.set(p[0].data.subarray(0,m-ae),ae),ae+=p[0].data.byteLength,_-=p[0].data.byteLength,p.shift();z=10,R.data[5]&64&&(z+=4,z+=an.parseSyncSafeInteger(R.data.subarray(10,14)),m-=an.parseSyncSafeInteger(R.data.subarray(16,20)));do{if(Y=an.parseSyncSafeInteger(R.data.subarray(z+4,z+8)),Y<1){this.trigger("log",{level:"warn",message:"Malformed ID3 frame encountered. Skipping remaining metadata parsing."});break}if(Te=String.fromCharCode(R.data[z],R.data[z+1],R.data[z+2],R.data[z+3]),ie={id:Te,data:R.data.subarray(z+10,z+Y+10)},ie.key=ie.id,an.frameParsers[ie.id]?an.frameParsers[ie.id](ie):ie.id[0]==="T"?an.frameParsers["T*"](ie):ie.id[0]==="W"&&an.frameParsers["W*"](ie),ie.owner==="com.apple.streaming.transportStreamTimestamp"){var le=ie.data,Ae=(le[3]&1)<<30|le[4]<<22|le[5]<<14|le[6]<<6|le[7]>>>2;Ae*=4,Ae+=le[7]&3,ie.timeStamp=Ae,R.pts===void 0&&R.dts===void 0&&(R.pts=ie.timeStamp,R.dts=ie.timeStamp),this.trigger("timestamp",ie)}R.frames.push(ie),z+=10,z+=Y}while(z<m);this.trigger("data",R)}}}},gs.prototype=new mp;var _p=gs,Ga=i,Wa=ee,wi=he,yp=mt.TimestampRolloverStream,_s,Dr,ys,Fn=188,Ya=71;_s=function(){var c=new Uint8Array(Fn),h=0;_s.prototype.init.call(this),this.push=function(m){var p=0,_=Fn,v;for(h?(v=new Uint8Array(m.byteLength+h),v.set(c.subarray(0,h)),v.set(m,h),h=0):v=m;_<v.byteLength;){if(v[p]===Ya&&v[_]===Ya){this.trigger("data",v.subarray(p,_)),p+=Fn,_+=Fn;continue}p++,_++}p<v.byteLength&&(c.set(v.subarray(p),0),h=v.byteLength-p)},this.flush=function(){h===Fn&&c[0]===Ya&&(this.trigger("data",c),h=0),this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.reset=function(){h=0,this.trigger("reset")}},_s.prototype=new Ga,Dr=function(){var c,h,m,p;Dr.prototype.init.call(this),p=this,this.packetsWaitingForPmt=[],this.programMapTable=void 0,c=function(_,v){var L=0;v.payloadUnitStartIndicator&&(L+=_[L]+1),v.type==="pat"?h(_.subarray(L),v):m(_.subarray(L),v)},h=function(_,v){v.section_number=_[7],v.last_section_number=_[8],p.pmtPid=(_[10]&31)<<8|_[11],v.pmtPid=p.pmtPid},m=function(_,v){var L,R,z,Y;if(_[5]&1){for(p.programMapTable={video:null,audio:null,"timed-metadata":{}},L=(_[1]&15)<<8|_[2],R=3+L-4,z=(_[10]&15)<<8|_[11],Y=12+z;Y<R;){var ie=_[Y],ae=(_[Y+1]&31)<<8|_[Y+2];ie===wi.H264_STREAM_TYPE&&p.programMapTable.video===null?p.programMapTable.video=ae:ie===wi.ADTS_STREAM_TYPE&&p.programMapTable.audio===null?p.programMapTable.audio=ae:ie===wi.METADATA_STREAM_TYPE&&(p.programMapTable["timed-metadata"][ae]=ie),Y+=((_[Y+3]&15)<<8|_[Y+4])+5}v.programMapTable=p.programMapTable}},this.push=function(_){var v={},L=4;if(v.payloadUnitStartIndicator=!!(_[1]&64),v.pid=_[1]&31,v.pid<<=8,v.pid|=_[2],(_[3]&48)>>>4>1&&(L+=_[L]+1),v.pid===0)v.type="pat",c(_.subarray(L),v),this.trigger("data",v);else if(v.pid===this.pmtPid)for(v.type="pmt",c(_.subarray(L),v),this.trigger("data",v);this.packetsWaitingForPmt.length;)this.processPes_.apply(this,this.packetsWaitingForPmt.shift());else this.programMapTable===void 0?this.packetsWaitingForPmt.push([_,L,v]):this.processPes_(_,L,v)},this.processPes_=function(_,v,L){L.pid===this.programMapTable.video?L.streamType=wi.H264_STREAM_TYPE:L.pid===this.programMapTable.audio?L.streamType=wi.ADTS_STREAM_TYPE:L.streamType=this.programMapTable["timed-metadata"][L.pid],L.type="pes",L.data=_.subarray(v),this.trigger("data",L)}},Dr.prototype=new Ga,Dr.STREAM_TYPES={h264:27,adts:15},ys=function(){var c=this,h=!1,m={data:[],size:0},p={data:[],size:0},_={data:[],size:0},v,L=function(z,Y){var ie;const ae=z[0]<<16|z[1]<<8|z[2];Y.data=new Uint8Array,ae===1&&(Y.packetLength=6+(z[4]<<8|z[5]),Y.dataAlignmentIndicator=(z[6]&4)!==0,ie=z[7],ie&192&&(Y.pts=(z[9]&14)<<27|(z[10]&255)<<20|(z[11]&254)<<12|(z[12]&255)<<5|(z[13]&254)>>>3,Y.pts*=4,Y.pts+=(z[13]&6)>>>1,Y.dts=Y.pts,ie&64&&(Y.dts=(z[14]&14)<<27|(z[15]&255)<<20|(z[16]&254)<<12|(z[17]&255)<<5|(z[18]&254)>>>3,Y.dts*=4,Y.dts+=(z[18]&6)>>>1)),Y.data=z.subarray(9+z[8]))},R=function(z,Y,ie){var ae=new Uint8Array(z.size),Te={type:Y},le=0,Ae=0,$e=!1,Dt;if(!(!z.data.length||z.size<9)){for(Te.trackId=z.data[0].pid,le=0;le<z.data.length;le++)Dt=z.data[le],ae.set(Dt.data,Ae),Ae+=Dt.data.byteLength;L(ae,Te),$e=Y==="video"||Te.packetLength<=z.size,(ie||$e)&&(z.size=0,z.data.length=0),$e&&c.trigger("data",Te)}};ys.prototype.init.call(this),this.push=function(z){({pat:function(){},pes:function(){var Y,ie;switch(z.streamType){case wi.H264_STREAM_TYPE:Y=m,ie="video";break;case wi.ADTS_STREAM_TYPE:Y=p,ie="audio";break;case wi.METADATA_STREAM_TYPE:Y=_,ie="timed-metadata";break;default:return}z.payloadUnitStartIndicator&&R(Y,ie,!0),Y.data.push(z),Y.size+=z.data.byteLength},pmt:function(){var Y={type:"metadata",tracks:[]};v=z.programMapTable,v.video!==null&&Y.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+v.video,codec:"avc",type:"video"}),v.audio!==null&&Y.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+v.audio,codec:"adts",type:"audio"}),h=!0,c.trigger("data",Y)}})[z.type]()},this.reset=function(){m.size=0,m.data.length=0,p.size=0,p.data.length=0,this.trigger("reset")},this.flushStreams_=function(){R(m,"video"),R(p,"audio"),R(_,"timed-metadata")},this.flush=function(){if(!h&&v){var z={type:"metadata",tracks:[]};v.video!==null&&z.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+v.video,codec:"avc",type:"video"}),v.audio!==null&&z.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+v.audio,codec:"adts",type:"audio"}),c.trigger("data",z)}h=!1,this.flushStreams_(),this.trigger("done")}},ys.prototype=new Ga;var _u={PAT_PID:0,MP2T_PACKET_LENGTH:Fn,TransportPacketStream:_s,TransportParseStream:Dr,ElementaryStream:ys,TimestampRolloverStream:yp,CaptionStream:Wa.CaptionStream,Cea608Stream:Wa.Cea608Stream,Cea708Stream:Wa.Cea708Stream,MetadataStream:_p};for(var Xa in wi)wi.hasOwnProperty(Xa)&&(_u[Xa]=wi[Xa]);var vp=_u,Tp=i,bp=Ye.ONE_SECOND_IN_TS,vs,yu=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];vs=function(c){var h,m=0;vs.prototype.init.call(this),this.skipWarn_=function(p,_){this.trigger("log",{level:"warn",message:`adts skiping bytes ${p} to ${_} in frame ${m} outside syncword`})},this.push=function(p){var _=0,v,L,R,z,Y;if(c||(m=0),p.type==="audio"){h&&h.length?(R=h,h=new Uint8Array(R.byteLength+p.data.byteLength),h.set(R),h.set(p.data,R.byteLength)):h=p.data;for(var ie;_+7<h.length;){if(h[_]!==255||(h[_+1]&246)!==240){typeof ie!="number"&&(ie=_),_++;continue}if(typeof ie=="number"&&(this.skipWarn_(ie,_),ie=null),L=(~h[_+1]&1)*2,v=(h[_+3]&3)<<11|h[_+4]<<3|(h[_+5]&224)>>5,z=((h[_+6]&3)+1)*1024,Y=z*bp/yu[(h[_+2]&60)>>>2],h.byteLength-_<v)break;this.trigger("data",{pts:p.pts+m*Y,dts:p.dts+m*Y,sampleCount:z,audioobjecttype:(h[_+2]>>>6&3)+1,channelcount:(h[_+2]&1)<<2|(h[_+3]&192)>>>6,samplerate:yu[(h[_+2]&60)>>>2],samplingfrequencyindex:(h[_+2]&60)>>>2,samplesize:16,data:h.subarray(_+7+L,_+v)}),m++,_+=v}typeof ie=="number"&&(this.skipWarn_(ie,_),ie=null),h=h.subarray(_)}},this.flush=function(){m=0,this.trigger("done")},this.reset=function(){h=void 0,this.trigger("reset")},this.endTimeline=function(){h=void 0,this.trigger("endedtimeline")}},vs.prototype=new Tp;var xp=vs,vu;vu=function(c){var h=c.byteLength,m=0,p=0;this.length=function(){return 8*h},this.bitsAvailable=function(){return 8*h+p},this.loadWord=function(){var _=c.byteLength-h,v=new Uint8Array(4),L=Math.min(4,h);if(L===0)throw new Error("no bytes available");v.set(c.subarray(_,_+L)),m=new DataView(v.buffer).getUint32(0),p=L*8,h-=L},this.skipBits=function(_){var v;p>_?(m<<=_,p-=_):(_-=p,v=Math.floor(_/8),_-=v*8,h-=v,this.loadWord(),m<<=_,p-=_)},this.readBits=function(_){var v=Math.min(p,_),L=m>>>32-v;return p-=v,p>0?m<<=v:h>0&&this.loadWord(),v=_-v,v>0?L<<v|this.readBits(v):L},this.skipLeadingZeros=function(){var _;for(_=0;_<p;++_)if((m&2147483648>>>_)!==0)return m<<=_,p-=_,_;return this.loadWord(),_+this.skipLeadingZeros()},this.skipUnsignedExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.skipExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.readUnsignedExpGolomb=function(){var _=this.skipLeadingZeros();return this.readBits(_+1)-1},this.readExpGolomb=function(){var _=this.readUnsignedExpGolomb();return 1&_?1+_>>>1:-1*(_>>>1)},this.readBoolean=function(){return this.readBits(1)===1},this.readUnsignedByte=function(){return this.readBits(8)},this.loadWord()};var Cp=vu,Tu=i,Sp=Cp,Ts,bs,bu;bs=function(){var c=0,h,m;bs.prototype.init.call(this),this.push=function(p){var _;m?(_=new Uint8Array(m.byteLength+p.data.byteLength),_.set(m),_.set(p.data,m.byteLength),m=_):m=p.data;for(var v=m.byteLength;c<v-3;c++)if(m[c+2]===1){h=c+5;break}for(;h<v;)switch(m[h]){case 0:if(m[h-1]!==0){h+=2;break}else if(m[h-2]!==0){h++;break}c+3!==h-2&&this.trigger("data",m.subarray(c+3,h-2));do h++;while(m[h]!==1&&h<v);c=h-2,h+=3;break;case 1:if(m[h-1]!==0||m[h-2]!==0){h+=3;break}this.trigger("data",m.subarray(c+3,h-2)),c=h-2,h+=3;break;default:h+=3;break}m=m.subarray(c),h-=c,c=0},this.reset=function(){m=null,c=0,this.trigger("reset")},this.flush=function(){m&&m.byteLength>3&&this.trigger("data",m.subarray(c+3)),m=null,c=0,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")}},bs.prototype=new Tu,bu={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},Ts=function(){var c=new bs,h,m,p,_,v,L,R;Ts.prototype.init.call(this),h=this,this.push=function(z){z.type==="video"&&(m=z.trackId,p=z.pts,_=z.dts,c.push(z))},c.on("data",function(z){var Y={trackId:m,pts:p,dts:_,data:z,nalUnitTypeCode:z[0]&31};switch(Y.nalUnitTypeCode){case 5:Y.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:Y.nalUnitType="sei_rbsp",Y.escapedRBSP=v(z.subarray(1));break;case 7:Y.nalUnitType="seq_parameter_set_rbsp",Y.escapedRBSP=v(z.subarray(1)),Y.config=L(Y.escapedRBSP);break;case 8:Y.nalUnitType="pic_parameter_set_rbsp";break;case 9:Y.nalUnitType="access_unit_delimiter_rbsp";break}h.trigger("data",Y)}),c.on("done",function(){h.trigger("done")}),c.on("partialdone",function(){h.trigger("partialdone")}),c.on("reset",function(){h.trigger("reset")}),c.on("endedtimeline",function(){h.trigger("endedtimeline")}),this.flush=function(){c.flush()},this.partialFlush=function(){c.partialFlush()},this.reset=function(){c.reset()},this.endTimeline=function(){c.endTimeline()},R=function(z,Y){var ie=8,ae=8,Te,le;for(Te=0;Te<z;Te++)ae!==0&&(le=Y.readExpGolomb(),ae=(ie+le+256)%256),ie=ae===0?ie:ae},v=function(z){for(var Y=z.byteLength,ie=[],ae=1,Te,le;ae<Y-2;)z[ae]===0&&z[ae+1]===0&&z[ae+2]===3?(ie.push(ae+2),ae+=2):ae++;if(ie.length===0)return z;Te=Y-ie.length,le=new Uint8Array(Te);var Ae=0;for(ae=0;ae<Te;Ae++,ae++)Ae===ie[0]&&(Ae++,ie.shift()),le[ae]=z[Ae];return le},L=function(z){var Y=0,ie=0,ae=0,Te=0,le,Ae,$e,Dt,ui,ln,Pr,Mr,Rr,Vr,Bs,ut=[1,1],Fr,Ai;if(le=new Sp(z),Ae=le.readUnsignedByte(),Dt=le.readUnsignedByte(),$e=le.readUnsignedByte(),le.skipUnsignedExpGolomb(),bu[Ae]&&(ui=le.readUnsignedExpGolomb(),ui===3&&le.skipBits(1),le.skipUnsignedExpGolomb(),le.skipUnsignedExpGolomb(),le.skipBits(1),le.readBoolean()))for(Bs=ui!==3?8:12,Ai=0;Ai<Bs;Ai++)le.readBoolean()&&(Ai<6?R(16,le):R(64,le));if(le.skipUnsignedExpGolomb(),ln=le.readUnsignedExpGolomb(),ln===0)le.readUnsignedExpGolomb();else if(ln===1)for(le.skipBits(1),le.skipExpGolomb(),le.skipExpGolomb(),Pr=le.readUnsignedExpGolomb(),Ai=0;Ai<Pr;Ai++)le.skipExpGolomb();if(le.skipUnsignedExpGolomb(),le.skipBits(1),Mr=le.readUnsignedExpGolomb(),Rr=le.readUnsignedExpGolomb(),Vr=le.readBits(1),Vr===0&&le.skipBits(1),le.skipBits(1),le.readBoolean()&&(Y=le.readUnsignedExpGolomb(),ie=le.readUnsignedExpGolomb(),ae=le.readUnsignedExpGolomb(),Te=le.readUnsignedExpGolomb()),le.readBoolean()&&le.readBoolean()){switch(Fr=le.readUnsignedByte(),Fr){case 1:ut=[1,1];break;case 2:ut=[12,11];break;case 3:ut=[10,11];break;case 4:ut=[16,11];break;case 5:ut=[40,33];break;case 6:ut=[24,11];break;case 7:ut=[20,11];break;case 8:ut=[32,11];break;case 9:ut=[80,33];break;case 10:ut=[18,11];break;case 11:ut=[15,11];break;case 12:ut=[64,33];break;case 13:ut=[160,99];break;case 14:ut=[4,3];break;case 15:ut=[3,2];break;case 16:ut=[2,1];break;case 255:{ut=[le.readUnsignedByte()<<8|le.readUnsignedByte(),le.readUnsignedByte()<<8|le.readUnsignedByte()];break}}ut&&ut[0]/ut[1]}return{profileIdc:Ae,levelIdc:$e,profileCompatibility:Dt,width:(Mr+1)*16-Y*2-ie*2,height:(2-Vr)*(Rr+1)*16-ae*2-Te*2,sarRatio:ut}}},Ts.prototype=new Tu;var Ep={H264Stream:Ts},kp=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],xu=function(c,h){var m=c[h+6]<<21|c[h+7]<<14|c[h+8]<<7|c[h+9],p=c[h+5],_=(p&16)>>4;return m=m>=0?m:0,_?m+20:m+10},Cu=function(c,h){return c.length-h<10||c[h]!==73||c[h+1]!==68||c[h+2]!==51?h:(h+=xu(c,h),Cu(c,h))},wp=function(c){var h=Cu(c,0);return c.length>=h+2&&(c[h]&255)===255&&(c[h+1]&240)===240&&(c[h+1]&22)===16},Su=function(c){return c[0]<<21|c[1]<<14|c[2]<<7|c[3]},Dp=function(c,h,m){var p,_="";for(p=h;p<m;p++)_+="%"+("00"+c[p].toString(16)).slice(-2);return _},Ap=function(c,h,m){return unescape(Dp(c,h,m))},Ip=function(c,h){var m=(c[h+5]&224)>>5,p=c[h+4]<<3,_=c[h+3]&6144;return _|p|m},Np=function(c,h){return c[h]===73&&c[h+1]===68&&c[h+2]===51?"timed-metadata":c[h]&!0&&(c[h+1]&240)===240?"audio":null},Op=function(c){for(var h=0;h+5<c.length;){if(c[h]!==255||(c[h+1]&246)!==240){h++;continue}return kp[(c[h+2]&60)>>>2]}return null},Bp=function(c){var h,m,p,_;h=10,c[5]&64&&(h+=4,h+=Su(c.subarray(10,14)));do{if(m=Su(c.subarray(h+4,h+8)),m<1)return null;if(_=String.fromCharCode(c[h],c[h+1],c[h+2],c[h+3]),_==="PRIV"){p=c.subarray(h+10,h+m+10);for(var v=0;v<p.byteLength;v++)if(p[v]===0){var L=Ap(p,0,v);if(L==="com.apple.streaming.transportStreamTimestamp"){var R=p.subarray(v+1),z=(R[3]&1)<<30|R[4]<<22|R[5]<<14|R[6]<<6|R[7]>>>2;return z*=4,z+=R[7]&3,z}break}}h+=10,h+=m}while(h<c.byteLength);return null},Ka={isLikelyAacData:wp,parseId3TagSize:xu,parseAdtsSize:Ip,parseType:Np,parseSampleRate:Op,parseAacTimestamp:Bp},Lp=i,Eu=Ka,xs;xs=function(){var c=new Uint8Array,h=0;xs.prototype.init.call(this),this.setTimestamp=function(m){h=m},this.push=function(m){var p=0,_=0,v,L,R,z;for(c.length?(z=c.length,c=new Uint8Array(m.byteLength+z),c.set(c.subarray(0,z)),c.set(m,z)):c=m;c.length-_>=3;){if(c[_]===73&&c[_+1]===68&&c[_+2]===51){if(c.length-_<10||(p=Eu.parseId3TagSize(c,_),_+p>c.length))break;L={type:"timed-metadata",data:c.subarray(_,_+p)},this.trigger("data",L),_+=p;continue}else if((c[_]&255)===255&&(c[_+1]&240)===240){if(c.length-_<7||(p=Eu.parseAdtsSize(c,_),_+p>c.length))break;R={type:"audio",data:c.subarray(_,_+p),pts:h,dts:h},this.trigger("data",R),_+=p;continue}_++}v=c.length-_,v>0?c=c.subarray(_):c=new Uint8Array},this.reset=function(){c=new Uint8Array,this.trigger("reset")},this.endTimeline=function(){c=new Uint8Array,this.trigger("endedtimeline")}},xs.prototype=new Lp;var Pp=xs,Mp=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],Rp=Mp,Vp=["width","height","profileIdc","levelIdc","profileCompatibility","sarRatio"],Fp=Vp,Cs=i,Ar=De,Ir=ht,Ss=Yi,Di=X,Ki=vp,Es=Ye,ku=xp,$p=Ep.H264Stream,Up=Pp,qp=Ka.isLikelyAacData,jp=Ye.ONE_SECOND_IN_TS,wu=Rp,Du=Fp,ks,Nr,ws,bn,Hp=function(c,h){h.stream=c,this.trigger("log",h)},Au=function(c,h){for(var m=Object.keys(h),p=0;p<m.length;p++){var _=m[p];_==="headOfPipeline"||!h[_].on||h[_].on("log",Hp.bind(c,_))}},Iu=function(c,h){var m;if(c.length!==h.length)return!1;for(m=0;m<c.length;m++)if(c[m]!==h[m])return!1;return!0},Nu=function(c,h,m,p,_,v){var L=m-h,R=p-h,z=_-m;return{start:{dts:c,pts:c+L},end:{dts:c+R,pts:c+z},prependedContentDuration:v,baseMediaDecodeTime:c}};Nr=function(c,h){var m=[],p,_=0,v=0,L=1/0;h=h||{},p=h.firstSequenceNumber||0,Nr.prototype.init.call(this),this.push=function(R){Di.collectDtsInfo(c,R),c&&wu.forEach(function(z){c[z]=R[z]}),m.push(R)},this.setEarliestDts=function(R){_=R},this.setVideoBaseMediaDecodeTime=function(R){L=R},this.setAudioAppendStart=function(R){v=R},this.flush=function(){var R,z,Y,ie,ae,Te,le;if(m.length===0){this.trigger("done","AudioSegmentStream");return}R=Ss.trimAdtsFramesByEarliestDts(m,c,_),c.baseMediaDecodeTime=Di.calculateTrackBaseMediaDecodeTime(c,h.keepOriginalTimestamps),le=Ss.prefixWithSilence(c,R,v,L),c.samples=Ss.generateSampleTable(R),Y=Ar.mdat(Ss.concatenateFrameData(R)),m=[],z=Ar.moof(p,[c]),ie=new Uint8Array(z.byteLength+Y.byteLength),p++,ie.set(z),ie.set(Y,z.byteLength),Di.clearDtsInfo(c),ae=Math.ceil(jp*1024/c.samplerate),R.length&&(Te=R.length*ae,this.trigger("segmentTimingInfo",Nu(Es.audioTsToVideoTs(c.baseMediaDecodeTime,c.samplerate),R[0].dts,R[0].pts,R[0].dts+Te,R[0].pts+Te,le||0)),this.trigger("timingInfo",{start:R[0].pts,end:R[0].pts+Te})),this.trigger("data",{track:c,boxes:ie}),this.trigger("done","AudioSegmentStream")},this.reset=function(){Di.clearDtsInfo(c),m=[],this.trigger("reset")}},Nr.prototype=new Cs,ks=function(c,h){var m,p=[],_=[],v,L;h=h||{},m=h.firstSequenceNumber||0,ks.prototype.init.call(this),delete c.minPTS,this.gopCache_=[],this.push=function(R){Di.collectDtsInfo(c,R),R.nalUnitType==="seq_parameter_set_rbsp"&&!v&&(v=R.config,c.sps=[R.data],Du.forEach(function(z){c[z]=v[z]},this)),R.nalUnitType==="pic_parameter_set_rbsp"&&!L&&(L=R.data,c.pps=[R.data]),p.push(R)},this.flush=function(){for(var R,z,Y,ie,ae,Te,le=0,Ae,$e;p.length&&p[0].nalUnitType!=="access_unit_delimiter_rbsp";)p.shift();if(p.length===0){this.resetStream_(),this.trigger("done","VideoSegmentStream");return}if(R=Ir.groupNalsIntoFrames(p),Y=Ir.groupFramesIntoGops(R),Y[0][0].keyFrame||(z=this.getGopForFusion_(p[0],c),z?(le=z.duration,Y.unshift(z),Y.byteLength+=z.byteLength,Y.nalCount+=z.nalCount,Y.pts=z.pts,Y.dts=z.dts,Y.duration+=z.duration):Y=Ir.extendFirstKeyFrame(Y)),_.length){var Dt;if(h.alignGopsAtEnd?Dt=this.alignGopsAtEnd_(Y):Dt=this.alignGopsAtStart_(Y),!Dt){this.gopCache_.unshift({gop:Y.pop(),pps:c.pps,sps:c.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),p=[],this.resetStream_(),this.trigger("done","VideoSegmentStream");return}Di.clearDtsInfo(c),Y=Dt}Di.collectDtsInfo(c,Y),c.samples=Ir.generateSampleTable(Y),ae=Ar.mdat(Ir.concatenateNalData(Y)),c.baseMediaDecodeTime=Di.calculateTrackBaseMediaDecodeTime(c,h.keepOriginalTimestamps),this.trigger("processedGopsInfo",Y.map(function(ui){return{pts:ui.pts,dts:ui.dts,byteLength:ui.byteLength}})),Ae=Y[0],$e=Y[Y.length-1],this.trigger("segmentTimingInfo",Nu(c.baseMediaDecodeTime,Ae.dts,Ae.pts,$e.dts+$e.duration,$e.pts+$e.duration,le)),this.trigger("timingInfo",{start:Y[0].pts,end:Y[Y.length-1].pts+Y[Y.length-1].duration}),this.gopCache_.unshift({gop:Y.pop(),pps:c.pps,sps:c.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),p=[],this.trigger("baseMediaDecodeTime",c.baseMediaDecodeTime),this.trigger("timelineStartInfo",c.timelineStartInfo),ie=Ar.moof(m,[c]),Te=new Uint8Array(ie.byteLength+ae.byteLength),m++,Te.set(ie),Te.set(ae,ie.byteLength),this.trigger("data",{track:c,boxes:Te}),this.resetStream_(),this.trigger("done","VideoSegmentStream")},this.reset=function(){this.resetStream_(),p=[],this.gopCache_.length=0,_.length=0,this.trigger("reset")},this.resetStream_=function(){Di.clearDtsInfo(c),v=void 0,L=void 0},this.getGopForFusion_=function(R){var z=45e3,Y=1/0,ie,ae,Te,le,Ae;for(Ae=0;Ae<this.gopCache_.length;Ae++)le=this.gopCache_[Ae],Te=le.gop,!(!(c.pps&&Iu(c.pps[0],le.pps[0]))||!(c.sps&&Iu(c.sps[0],le.sps[0])))&&(Te.dts<c.timelineStartInfo.dts||(ie=R.dts-Te.dts-Te.duration,ie>=-1e4&&ie<=z&&(!ae||Y>ie)&&(ae=le,Y=ie)));return ae?ae.gop:null},this.alignGopsAtStart_=function(R){var z,Y,ie,ae,Te,le,Ae,$e;for(Te=R.byteLength,le=R.nalCount,Ae=R.duration,z=Y=0;z<_.length&&Y<R.length&&(ie=_[z],ae=R[Y],ie.pts!==ae.pts);){if(ae.pts>ie.pts){z++;continue}Y++,Te-=ae.byteLength,le-=ae.nalCount,Ae-=ae.duration}return Y===0?R:Y===R.length?null:($e=R.slice(Y),$e.byteLength=Te,$e.duration=Ae,$e.nalCount=le,$e.pts=$e[0].pts,$e.dts=$e[0].dts,$e)},this.alignGopsAtEnd_=function(R){var z,Y,ie,ae,Te,le;for(z=_.length-1,Y=R.length-1,Te=null,le=!1;z>=0&&Y>=0;){if(ie=_[z],ae=R[Y],ie.pts===ae.pts){le=!0;break}if(ie.pts>ae.pts){z--;continue}z===_.length-1&&(Te=Y),Y--}if(!le&&Te===null)return null;var Ae;if(le?Ae=Y:Ae=Te,Ae===0)return R;var $e=R.slice(Ae),Dt=$e.reduce(function(ui,ln){return ui.byteLength+=ln.byteLength,ui.duration+=ln.duration,ui.nalCount+=ln.nalCount,ui},{byteLength:0,duration:0,nalCount:0});return $e.byteLength=Dt.byteLength,$e.duration=Dt.duration,$e.nalCount=Dt.nalCount,$e.pts=$e[0].pts,$e.dts=$e[0].dts,$e},this.alignGopsWith=function(R){_=R}},ks.prototype=new Cs,bn=function(c,h){this.numberOfTracks=0,this.metadataStream=h,c=c||{},typeof c.remux<"u"?this.remuxTracks=!!c.remux:this.remuxTracks=!0,typeof c.keepOriginalTimestamps=="boolean"?this.keepOriginalTimestamps=c.keepOriginalTimestamps:this.keepOriginalTimestamps=!1,this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,bn.prototype.init.call(this),this.push=function(m){if(m.content||m.text)return this.pendingCaptions.push(m);if(m.frames)return this.pendingMetadata.push(m);this.pendingTracks.push(m.track),this.pendingBytes+=m.boxes.byteLength,m.track.type==="video"&&(this.videoTrack=m.track,this.pendingBoxes.push(m.boxes)),m.track.type==="audio"&&(this.audioTrack=m.track,this.pendingBoxes.unshift(m.boxes))}},bn.prototype=new Cs,bn.prototype.flush=function(c){var h=0,m={captions:[],captionStreams:{},metadata:[],info:{}},p,_,v,L=0,R;if(this.pendingTracks.length<this.numberOfTracks){if(c!=="VideoSegmentStream"&&c!=="AudioSegmentStream")return;if(this.remuxTracks)return;if(this.pendingTracks.length===0){this.emittedTracks++,this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0);return}}if(this.videoTrack?(L=this.videoTrack.timelineStartInfo.pts,Du.forEach(function(z){m.info[z]=this.videoTrack[z]},this)):this.audioTrack&&(L=this.audioTrack.timelineStartInfo.pts,wu.forEach(function(z){m.info[z]=this.audioTrack[z]},this)),this.videoTrack||this.audioTrack){for(this.pendingTracks.length===1?m.type=this.pendingTracks[0].type:m.type="combined",this.emittedTracks+=this.pendingTracks.length,v=Ar.initSegment(this.pendingTracks),m.initSegment=new Uint8Array(v.byteLength),m.initSegment.set(v),m.data=new Uint8Array(this.pendingBytes),R=0;R<this.pendingBoxes.length;R++)m.data.set(this.pendingBoxes[R],h),h+=this.pendingBoxes[R].byteLength;for(R=0;R<this.pendingCaptions.length;R++)p=this.pendingCaptions[R],p.startTime=Es.metadataTsToSeconds(p.startPts,L,this.keepOriginalTimestamps),p.endTime=Es.metadataTsToSeconds(p.endPts,L,this.keepOriginalTimestamps),m.captionStreams[p.stream]=!0,m.captions.push(p);for(R=0;R<this.pendingMetadata.length;R++)_=this.pendingMetadata[R],_.cueTime=Es.metadataTsToSeconds(_.pts,L,this.keepOriginalTimestamps),m.metadata.push(_);for(m.metadata.dispatchType=this.metadataStream.dispatchType,this.pendingTracks.length=0,this.videoTrack=null,this.pendingBoxes.length=0,this.pendingCaptions.length=0,this.pendingBytes=0,this.pendingMetadata.length=0,this.trigger("data",m),R=0;R<m.captions.length;R++)p=m.captions[R],this.trigger("caption",p);for(R=0;R<m.metadata.length;R++)_=m.metadata[R],this.trigger("id3Frame",_)}this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},bn.prototype.setRemux=function(c){this.remuxTracks=c},ws=function(c){var h=this,m=!0,p,_;ws.prototype.init.call(this),c=c||{},this.baseMediaDecodeTime=c.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var v={};this.transmuxPipeline_=v,v.type="aac",v.metadataStream=new Ki.MetadataStream,v.aacStream=new Up,v.audioTimestampRolloverStream=new Ki.TimestampRolloverStream("audio"),v.timedMetadataTimestampRolloverStream=new Ki.TimestampRolloverStream("timed-metadata"),v.adtsStream=new ku,v.coalesceStream=new bn(c,v.metadataStream),v.headOfPipeline=v.aacStream,v.aacStream.pipe(v.audioTimestampRolloverStream).pipe(v.adtsStream),v.aacStream.pipe(v.timedMetadataTimestampRolloverStream).pipe(v.metadataStream).pipe(v.coalesceStream),v.metadataStream.on("timestamp",function(L){v.aacStream.setTimestamp(L.timeStamp)}),v.aacStream.on("data",function(L){L.type!=="timed-metadata"&&L.type!=="audio"||v.audioSegmentStream||(_=_||{timelineStartInfo:{baseMediaDecodeTime:h.baseMediaDecodeTime},codec:"adts",type:"audio"},v.coalesceStream.numberOfTracks++,v.audioSegmentStream=new Nr(_,c),v.audioSegmentStream.on("log",h.getLogTrigger_("audioSegmentStream")),v.audioSegmentStream.on("timingInfo",h.trigger.bind(h,"audioTimingInfo")),v.adtsStream.pipe(v.audioSegmentStream).pipe(v.coalesceStream),h.trigger("trackinfo",{hasAudio:!!_,hasVideo:!!p}))}),v.coalesceStream.on("data",this.trigger.bind(this,"data")),v.coalesceStream.on("done",this.trigger.bind(this,"done")),Au(this,v)},this.setupTsPipeline=function(){var v={};this.transmuxPipeline_=v,v.type="ts",v.metadataStream=new Ki.MetadataStream,v.packetStream=new Ki.TransportPacketStream,v.parseStream=new Ki.TransportParseStream,v.elementaryStream=new Ki.ElementaryStream,v.timestampRolloverStream=new Ki.TimestampRolloverStream,v.adtsStream=new ku,v.h264Stream=new $p,v.captionStream=new Ki.CaptionStream(c),v.coalesceStream=new bn(c,v.metadataStream),v.headOfPipeline=v.packetStream,v.packetStream.pipe(v.parseStream).pipe(v.elementaryStream).pipe(v.timestampRolloverStream),v.timestampRolloverStream.pipe(v.h264Stream),v.timestampRolloverStream.pipe(v.adtsStream),v.timestampRolloverStream.pipe(v.metadataStream).pipe(v.coalesceStream),v.h264Stream.pipe(v.captionStream).pipe(v.coalesceStream),v.elementaryStream.on("data",function(L){var R;if(L.type==="metadata"){for(R=L.tracks.length;R--;)!p&&L.tracks[R].type==="video"?(p=L.tracks[R],p.timelineStartInfo.baseMediaDecodeTime=h.baseMediaDecodeTime):!_&&L.tracks[R].type==="audio"&&(_=L.tracks[R],_.timelineStartInfo.baseMediaDecodeTime=h.baseMediaDecodeTime);p&&!v.videoSegmentStream&&(v.coalesceStream.numberOfTracks++,v.videoSegmentStream=new ks(p,c),v.videoSegmentStream.on("log",h.getLogTrigger_("videoSegmentStream")),v.videoSegmentStream.on("timelineStartInfo",function(z){_&&!c.keepOriginalTimestamps&&(_.timelineStartInfo=z,v.audioSegmentStream.setEarliestDts(z.dts-h.baseMediaDecodeTime))}),v.videoSegmentStream.on("processedGopsInfo",h.trigger.bind(h,"gopInfo")),v.videoSegmentStream.on("segmentTimingInfo",h.trigger.bind(h,"videoSegmentTimingInfo")),v.videoSegmentStream.on("baseMediaDecodeTime",function(z){_&&v.audioSegmentStream.setVideoBaseMediaDecodeTime(z)}),v.videoSegmentStream.on("timingInfo",h.trigger.bind(h,"videoTimingInfo")),v.h264Stream.pipe(v.videoSegmentStream).pipe(v.coalesceStream)),_&&!v.audioSegmentStream&&(v.coalesceStream.numberOfTracks++,v.audioSegmentStream=new Nr(_,c),v.audioSegmentStream.on("log",h.getLogTrigger_("audioSegmentStream")),v.audioSegmentStream.on("timingInfo",h.trigger.bind(h,"audioTimingInfo")),v.audioSegmentStream.on("segmentTimingInfo",h.trigger.bind(h,"audioSegmentTimingInfo")),v.adtsStream.pipe(v.audioSegmentStream).pipe(v.coalesceStream)),h.trigger("trackinfo",{hasAudio:!!_,hasVideo:!!p})}}),v.coalesceStream.on("data",this.trigger.bind(this,"data")),v.coalesceStream.on("id3Frame",function(L){L.dispatchType=v.metadataStream.dispatchType,h.trigger("id3Frame",L)}),v.coalesceStream.on("caption",this.trigger.bind(this,"caption")),v.coalesceStream.on("done",this.trigger.bind(this,"done")),Au(this,v)},this.setBaseMediaDecodeTime=function(v){var L=this.transmuxPipeline_;c.keepOriginalTimestamps||(this.baseMediaDecodeTime=v),_&&(_.timelineStartInfo.dts=void 0,_.timelineStartInfo.pts=void 0,Di.clearDtsInfo(_),L.audioTimestampRolloverStream&&L.audioTimestampRolloverStream.discontinuity()),p&&(L.videoSegmentStream&&(L.videoSegmentStream.gopCache_=[]),p.timelineStartInfo.dts=void 0,p.timelineStartInfo.pts=void 0,Di.clearDtsInfo(p),L.captionStream.reset()),L.timestampRolloverStream&&L.timestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(v){_&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(v)},this.setRemux=function(v){var L=this.transmuxPipeline_;c.remux=v,L&&L.coalesceStream&&L.coalesceStream.setRemux(v)},this.alignGopsWith=function(v){p&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(v)},this.getLogTrigger_=function(v){var L=this;return function(R){R.stream=v,L.trigger("log",R)}},this.push=function(v){if(m){var L=qp(v);L&&this.transmuxPipeline_.type!=="aac"?this.setupAacPipeline():!L&&this.transmuxPipeline_.type!=="ts"&&this.setupTsPipeline(),m=!1}this.transmuxPipeline_.headOfPipeline.push(v)},this.flush=function(){m=!0,this.transmuxPipeline_.headOfPipeline.flush()},this.endTimeline=function(){this.transmuxPipeline_.headOfPipeline.endTimeline()},this.reset=function(){this.transmuxPipeline_.headOfPipeline&&this.transmuxPipeline_.headOfPipeline.reset()},this.resetCaptions=function(){this.transmuxPipeline_.captionStream&&this.transmuxPipeline_.captionStream.reset()}},ws.prototype=new Cs;var zp={Transmuxer:ws},Gp=function(c){return c>>>0},Wp=function(c){return("00"+c.toString(16)).slice(-2)},Ds={toUnsigned:Gp,toHexString:Wp},Yp=function(c){var h="";return h+=String.fromCharCode(c[0]),h+=String.fromCharCode(c[1]),h+=String.fromCharCode(c[2]),h+=String.fromCharCode(c[3]),h},Ou=Yp,Xp=Ds.toUnsigned,Kp=Ou,Bu=function(c,h){var m=[],p,_,v,L,R;if(!h.length)return null;for(p=0;p<c.byteLength;)_=Xp(c[p]<<24|c[p+1]<<16|c[p+2]<<8|c[p+3]),v=Kp(c.subarray(p+4,p+8)),L=_>1?p+_:c.byteLength,v===h[0]&&(h.length===1?m.push(c.subarray(p+8,L)):(R=Bu(c.subarray(p+8,L),h.slice(1)),R.length&&(m=m.concat(R)))),p=L;return m},Qa=Bu,Qp=Ds.toUnsigned,Zp=o.getUint64,Jp=function(c){var h={version:c[0],flags:new Uint8Array(c.subarray(1,4))};return h.version===1?h.baseMediaDecodeTime=Zp(c.subarray(4)):h.baseMediaDecodeTime=Qp(c[4]<<24|c[5]<<16|c[6]<<8|c[7]),h},Za=Jp,em=function(c){var h=new DataView(c.buffer,c.byteOffset,c.byteLength),m={version:c[0],flags:new Uint8Array(c.subarray(1,4)),trackId:h.getUint32(4)},p=m.flags[2]&1,_=m.flags[2]&2,v=m.flags[2]&8,L=m.flags[2]&16,R=m.flags[2]&32,z=m.flags[0]&65536,Y=m.flags[0]&131072,ie;return ie=8,p&&(ie+=4,m.baseDataOffset=h.getUint32(12),ie+=4),_&&(m.sampleDescriptionIndex=h.getUint32(ie),ie+=4),v&&(m.defaultSampleDuration=h.getUint32(ie),ie+=4),L&&(m.defaultSampleSize=h.getUint32(ie),ie+=4),R&&(m.defaultSampleFlags=h.getUint32(ie)),z&&(m.durationIsEmpty=!0),!p&&Y&&(m.baseDataOffsetIsMoof=!0),m},Lu=em,tm=function(c){return{isLeading:(c[0]&12)>>>2,dependsOn:c[0]&3,isDependedOn:(c[1]&192)>>>6,hasRedundancy:(c[1]&48)>>>4,paddingValue:(c[1]&14)>>>1,isNonSyncSample:c[1]&1,degradationPriority:c[2]<<8|c[3]}},im=tm,Pu=im,nm=function(c){var h={version:c[0],flags:new Uint8Array(c.subarray(1,4)),samples:[]},m=new DataView(c.buffer,c.byteOffset,c.byteLength),p=h.flags[2]&1,_=h.flags[2]&4,v=h.flags[1]&1,L=h.flags[1]&2,R=h.flags[1]&4,z=h.flags[1]&8,Y=m.getUint32(4),ie=8,ae;for(p&&(h.dataOffset=m.getInt32(ie),ie+=4),_&&Y&&(ae={flags:Pu(c.subarray(ie,ie+4))},ie+=4,v&&(ae.duration=m.getUint32(ie),ie+=4),L&&(ae.size=m.getUint32(ie),ie+=4),z&&(h.version===1?ae.compositionTimeOffset=m.getInt32(ie):ae.compositionTimeOffset=m.getUint32(ie),ie+=4),h.samples.push(ae),Y--);Y--;)ae={},v&&(ae.duration=m.getUint32(ie),ie+=4),L&&(ae.size=m.getUint32(ie),ie+=4),R&&(ae.flags=Pu(c.subarray(ie,ie+4)),ie+=4),z&&(h.version===1?ae.compositionTimeOffset=m.getInt32(ie):ae.compositionTimeOffset=m.getUint32(ie),ie+=4),h.samples.push(ae);return h},Mu=nm,Ru={tfdt:Za,trun:Mu},Vu={parseTfdt:Ru.tfdt,parseTrun:Ru.trun},rm=function(c){for(var h=0,m=String.fromCharCode(c[h]),p="";m!=="\0";)p+=m,h++,m=String.fromCharCode(c[h]);return p+=m,p},sm={uint8ToCString:rm},As=sm.uint8ToCString,am=o.getUint64,om=function(c){var h=4,m=c[0],p,_,v,L,R,z,Y,ie;if(m===0){p=As(c.subarray(h)),h+=p.length,_=As(c.subarray(h)),h+=_.length;var ae=new DataView(c.buffer);v=ae.getUint32(h),h+=4,R=ae.getUint32(h),h+=4,z=ae.getUint32(h),h+=4,Y=ae.getUint32(h),h+=4}else if(m===1){var ae=new DataView(c.buffer);v=ae.getUint32(h),h+=4,L=am(c.subarray(h)),h+=8,z=ae.getUint32(h),h+=4,Y=ae.getUint32(h),h+=4,p=As(c.subarray(h)),h+=p.length,_=As(c.subarray(h)),h+=_.length}ie=new Uint8Array(c.subarray(h,c.byteLength));var Te={scheme_id_uri:p,value:_,timescale:v||1,presentation_time:L,presentation_time_delta:R,event_duration:z,id:Y,message_data:ie};return um(m,Te)?Te:void 0},lm=function(c,h,m,p){return c||c===0?c/h:p+m/h},um=function(c,h){var m=h.scheme_id_uri!=="\0",p=c===0&&Fu(h.presentation_time_delta)&&m,_=c===1&&Fu(h.presentation_time)&&m;return!(c>1)&&p||_},Fu=function(c){return c!==void 0||c!==null},cm={parseEmsgBox:om,scaleTime:lm},Or;typeof window<"u"?Or=window:typeof s<"u"?Or=s:typeof self<"u"?Or=self:Or={};var $u=Or,Is=Ds.toUnsigned,Br=Ds.toHexString,Tt=Qa,$n=Ou,Ja=cm,dm=Lu,hm=Mu,fm=Za,pm=o.getUint64,Uu,qu,ju,Hu,zu,eo,Gu,to=$u,mm=gu.parseId3Frames;Uu=function(c){var h={},m=Tt(c,["moov","trak"]);return m.reduce(function(p,_){var v,L,R,z,Y;return v=Tt(_,["tkhd"])[0],!v||(L=v[0],R=L===0?12:20,z=Is(v[R]<<24|v[R+1]<<16|v[R+2]<<8|v[R+3]),Y=Tt(_,["mdia","mdhd"])[0],!Y)?null:(L=Y[0],R=L===0?12:20,p[z]=Is(Y[R]<<24|Y[R+1]<<16|Y[R+2]<<8|Y[R+3]),p)},h)},qu=function(c,h){var m;m=Tt(h,["moof","traf"]);var p=m.reduce(function(_,v){var L=Tt(v,["tfhd"])[0],R=Is(L[4]<<24|L[5]<<16|L[6]<<8|L[7]),z=c[R]||9e4,Y=Tt(v,["tfdt"])[0],ie=new DataView(Y.buffer,Y.byteOffset,Y.byteLength),ae;Y[0]===1?ae=pm(Y.subarray(4,12)):ae=ie.getUint32(4);let Te;return typeof ae=="bigint"?Te=ae/to.BigInt(z):typeof ae=="number"&&!isNaN(ae)&&(Te=ae/z),Te<Number.MAX_SAFE_INTEGER&&(Te=Number(Te)),Te<_&&(_=Te),_},1/0);return typeof p=="bigint"||isFinite(p)?p:0},ju=function(c,h){var m=Tt(h,["moof","traf"]),p=0,_=0,v;if(m&&m.length){var L=Tt(m[0],["tfhd"])[0],R=Tt(m[0],["trun"])[0],z=Tt(m[0],["tfdt"])[0];if(L){var Y=dm(L);v=Y.trackId}if(z){var ie=fm(z);p=ie.baseMediaDecodeTime}if(R){var ae=hm(R);ae.samples&&ae.samples.length&&(_=ae.samples[0].compositionTimeOffset||0)}}var Te=c[v]||9e4;typeof p=="bigint"&&(_=to.BigInt(_),Te=to.BigInt(Te));var le=(p+_)/Te;return typeof le=="bigint"&&le<Number.MAX_SAFE_INTEGER&&(le=Number(le)),le},Hu=function(c){var h=Tt(c,["moov","trak"]),m=[];return h.forEach(function(p){var _=Tt(p,["mdia","hdlr"]),v=Tt(p,["tkhd"]);_.forEach(function(L,R){var z=$n(L.subarray(8,12)),Y=v[R],ie,ae,Te;z==="vide"&&(ie=new DataView(Y.buffer,Y.byteOffset,Y.byteLength),ae=ie.getUint8(0),Te=ae===0?ie.getUint32(12):ie.getUint32(20),m.push(Te))})}),m},eo=function(c){var h=c[0],m=h===0?12:20;return Is(c[m]<<24|c[m+1]<<16|c[m+2]<<8|c[m+3])},zu=function(c){var h=Tt(c,["moov","trak"]),m=[];return h.forEach(function(p){var _={},v=Tt(p,["tkhd"])[0],L,R;v&&(L=new DataView(v.buffer,v.byteOffset,v.byteLength),R=L.getUint8(0),_.id=R===0?L.getUint32(12):L.getUint32(20));var z=Tt(p,["mdia","hdlr"])[0];if(z){var Y=$n(z.subarray(8,12));Y==="vide"?_.type="video":Y==="soun"?_.type="audio":_.type=Y}var ie=Tt(p,["mdia","minf","stbl","stsd"])[0];if(ie){var ae=ie.subarray(8);_.codec=$n(ae.subarray(4,8));var Te=Tt(ae,[_.codec])[0],le,Ae;Te&&(/^[asm]vc[1-9]$/i.test(_.codec)?(le=Te.subarray(78),Ae=$n(le.subarray(4,8)),Ae==="avcC"&&le.length>11?(_.codec+=".",_.codec+=Br(le[9]),_.codec+=Br(le[10]),_.codec+=Br(le[11])):_.codec="avc1.4d400d"):/^mp4[a,v]$/i.test(_.codec)?(le=Te.subarray(28),Ae=$n(le.subarray(4,8)),Ae==="esds"&&le.length>20&&le[19]!==0?(_.codec+="."+Br(le[19]),_.codec+="."+Br(le[20]>>>2&63).replace(/^0/,"")):_.codec="mp4a.40.2"):_.codec=_.codec.toLowerCase())}var $e=Tt(p,["mdia","mdhd"])[0];$e&&(_.timescale=eo($e)),m.push(_)}),m},Gu=function(c,h=0){var m=Tt(c,["emsg"]);return m.map(p=>{var _=Ja.parseEmsgBox(new Uint8Array(p)),v=mm(_.message_data);return{cueTime:Ja.scaleTime(_.presentation_time,_.timescale,_.presentation_time_delta,h),duration:Ja.scaleTime(_.event_duration,_.timescale),frames:v}})};var Lr={findBox:Tt,parseType:$n,timescale:Uu,startTime:qu,compositionStartTime:ju,videoTrackIds:Hu,tracks:zu,getTimescaleFromMediaHeader:eo,getEmsgID3:Gu};const{parseTrun:gm}=Vu,{findBox:Wu}=Lr;var Yu=$u,_m=function(c){var h=Wu(c,["moof","traf"]),m=Wu(c,["mdat"]),p=[];return m.forEach(function(_,v){var L=h[v];p.push({mdat:_,traf:L})}),p},ym=function(c,h,m){var p=h,_=m.defaultSampleDuration||0,v=m.defaultSampleSize||0,L=m.trackId,R=[];return c.forEach(function(z){var Y=gm(z),ie=Y.samples;ie.forEach(function(ae){ae.duration===void 0&&(ae.duration=_),ae.size===void 0&&(ae.size=v),ae.trackId=L,ae.dts=p,ae.compositionTimeOffset===void 0&&(ae.compositionTimeOffset=0),typeof p=="bigint"?(ae.pts=p+Yu.BigInt(ae.compositionTimeOffset),p+=Yu.BigInt(ae.duration)):(ae.pts=p+ae.compositionTimeOffset,p+=ae.duration)}),R=R.concat(ie)}),R},Xu={getMdatTrafPairs:_m,parseSamples:ym},vm=Vt.discardEmulationPreventionBytes,Tm=ee.CaptionStream,io=Qa,bm=Za,xm=Lu,{getMdatTrafPairs:Cm,parseSamples:Sm}=Xu,Em=function(c,h){for(var m=c,p=0;p<h.length;p++){var _=h[p];if(m<_.size)return _;m-=_.size}return null},km=function(c,h,m){var p=new DataView(c.buffer,c.byteOffset,c.byteLength),_={logs:[],seiNals:[]},v,L,R,z;for(L=0;L+4<c.length;L+=R)if(R=p.getUint32(L),L+=4,!(R<=0))switch(c[L]&31){case 6:var Y=c.subarray(L+1,L+1+R),ie=Em(L,h);if(v={nalUnitType:"sei_rbsp",size:R,data:Y,escapedRBSP:vm(Y),trackId:m},ie)v.pts=ie.pts,v.dts=ie.dts,z=ie;else if(z)v.pts=z.pts,v.dts=z.dts;else{_.logs.push({level:"warn",message:"We've encountered a nal unit without data at "+L+" for trackId "+m+". See mux.js#223."});break}_.seiNals.push(v);break}return _},wm=function(c,h){var m={},p=Cm(c);return p.forEach(function(_){var v=_.mdat,L=_.traf,R=io(L,["tfhd"]),z=xm(R[0]),Y=z.trackId,ie=io(L,["tfdt"]),ae=ie.length>0?bm(ie[0]).baseMediaDecodeTime:0,Te=io(L,["trun"]),le,Ae;h===Y&&Te.length>0&&(le=Sm(Te,ae,z),Ae=km(v,le,Y),m[Y]||(m[Y]={seiNals:[],logs:[]}),m[Y].seiNals=m[Y].seiNals.concat(Ae.seiNals),m[Y].logs=m[Y].logs.concat(Ae.logs))}),m},Dm=function(c,h,m){var p;if(h===null)return null;p=wm(c,h);var _=p[h]||{};return{seiNals:_.seiNals,logs:_.logs,timescale:m}},Am=function(){var c=!1,h,m,p,_,v,L;this.isInitialized=function(){return c},this.init=function(R){h=new Tm,c=!0,L=R?R.isPartial:!1,h.on("data",function(z){z.startTime=z.startPts/_,z.endTime=z.endPts/_,v.captions.push(z),v.captionStreams[z.stream]=!0}),h.on("log",function(z){v.logs.push(z)})},this.isNewInit=function(R,z){return R&&R.length===0||z&&typeof z=="object"&&Object.keys(z).length===0?!1:p!==R[0]||_!==z[p]},this.parse=function(R,z,Y){var ie;if(this.isInitialized()){if(!z||!Y)return null;if(this.isNewInit(z,Y))p=z[0],_=Y[p];else if(p===null||!_)return m.push(R),null}else return null;for(;m.length>0;){var ae=m.shift();this.parse(ae,z,Y)}return ie=Dm(R,p,_),ie&&ie.logs&&(v.logs=v.logs.concat(ie.logs)),ie===null||!ie.seiNals?v.logs.length?{logs:v.logs,captions:[],captionStreams:[]}:null:(this.pushNals(ie.seiNals),this.flushStream(),v)},this.pushNals=function(R){if(!this.isInitialized()||!R||R.length===0)return null;R.forEach(function(z){h.push(z)})},this.flushStream=function(){if(!this.isInitialized())return null;L?h.partialFlush():h.flush()},this.clearParsedCaptions=function(){v.captions=[],v.captionStreams={},v.logs=[]},this.resetCaptionStream=function(){if(!this.isInitialized())return null;h.reset()},this.clearAllCaptions=function(){this.clearParsedCaptions(),this.resetCaptionStream()},this.reset=function(){m=[],p=null,_=null,v?this.clearParsedCaptions():v={captions:[],captionStreams:{},logs:[]},this.resetCaptionStream()},this.reset()},Im=Am;const{parseTfdt:Nm}=Vu,on=Qa,{getTimescaleFromMediaHeader:Om}=Lr,{parseSamples:Bm,getMdatTrafPairs:Lm}=Xu;var Ku=function(){let c=9e4;this.init=function(h){const m=on(h,["moov","trak","mdia","mdhd"])[0];m&&(c=Om(m))},this.parseSegment=function(h){const m=[],p=Lm(h);let _=0;return p.forEach(function(v){const L=v.mdat,R=v.traf,z=on(R,["tfdt"])[0],Y=on(R,["tfhd"])[0],ie=on(R,["trun"]);if(z&&(_=Nm(z).baseMediaDecodeTime),ie.length&&Y){const ae=Bm(ie,_,Y);let Te=0;ae.forEach(function(le){const Ae="utf-8",$e=new TextDecoder(Ae),Dt=L.slice(Te,Te+le.size);if(on(Dt,["vtte"])[0]){Te+=le.size;return}on(Dt,["vttc"]).forEach(function(Pr){const Mr=on(Pr,["payl"])[0],Rr=on(Pr,["sttg"])[0],Vr=le.pts/c,Bs=(le.pts+le.duration)/c;let ut,Fr;if(Mr)try{ut=$e.decode(Mr)}catch(Ai){console.error(Ai)}if(Rr)try{Fr=$e.decode(Rr)}catch(Ai){console.error(Ai)}le.duration&&ut&&m.push({cueText:ut,start:Vr,end:Bs,settings:Fr})}),Te+=le.size})}}),m}},no=he,Qu=function(c){var h=c[1]&31;return h<<=8,h|=c[2],h},Ns=function(c){return!!(c[1]&64)},Os=function(c){var h=0;return(c[3]&48)>>>4>1&&(h+=c[4]+1),h},Pm=function(c,h){var m=Qu(c);return m===0?"pat":m===h?"pmt":h?"pes":null},Mm=function(c){var h=Ns(c),m=4+Os(c);return h&&(m+=c[m]+1),(c[m+10]&31)<<8|c[m+11]},Rm=function(c){var h={},m=Ns(c),p=4+Os(c);if(m&&(p+=c[p]+1),!!(c[p+5]&1)){var _,v,L;_=(c[p+1]&15)<<8|c[p+2],v=3+_-4,L=(c[p+10]&15)<<8|c[p+11];for(var R=12+L;R<v;){var z=p+R;h[(c[z+1]&31)<<8|c[z+2]]=c[z],R+=((c[z+3]&15)<<8|c[z+4])+5}return h}},Vm=function(c,h){var m=Qu(c),p=h[m];switch(p){case no.H264_STREAM_TYPE:return"video";case no.ADTS_STREAM_TYPE:return"audio";case no.METADATA_STREAM_TYPE:return"timed-metadata";default:return null}},Fm=function(c){var h=Ns(c);if(!h)return null;var m=4+Os(c);if(m>=c.byteLength)return null;var p=null,_;return _=c[m+7],_&192&&(p={},p.pts=(c[m+9]&14)<<27|(c[m+10]&255)<<20|(c[m+11]&254)<<12|(c[m+12]&255)<<5|(c[m+13]&254)>>>3,p.pts*=4,p.pts+=(c[m+13]&6)>>>1,p.dts=p.pts,_&64&&(p.dts=(c[m+14]&14)<<27|(c[m+15]&255)<<20|(c[m+16]&254)<<12|(c[m+17]&255)<<5|(c[m+18]&254)>>>3,p.dts*=4,p.dts+=(c[m+18]&6)>>>1)),p},ro=function(c){switch(c){case 5:return"slice_layer_without_partitioning_rbsp_idr";case 6:return"sei_rbsp";case 7:return"seq_parameter_set_rbsp";case 8:return"pic_parameter_set_rbsp";case 9:return"access_unit_delimiter_rbsp";default:return null}},$m=function(c){for(var h=4+Os(c),m=c.subarray(h),p=0,_=0,v=!1,L;_<m.byteLength-3;_++)if(m[_+2]===1){p=_+5;break}for(;p<m.byteLength;)switch(m[p]){case 0:if(m[p-1]!==0){p+=2;break}else if(m[p-2]!==0){p++;break}_+3!==p-2&&(L=ro(m[_+3]&31),L==="slice_layer_without_partitioning_rbsp_idr"&&(v=!0));do p++;while(m[p]!==1&&p<m.length);_=p-2,p+=3;break;case 1:if(m[p-1]!==0||m[p-2]!==0){p+=3;break}L=ro(m[_+3]&31),L==="slice_layer_without_partitioning_rbsp_idr"&&(v=!0),_=p-2,p+=3;break;default:p+=3;break}return m=m.subarray(_),p-=_,_=0,m&&m.byteLength>3&&(L=ro(m[_+3]&31),L==="slice_layer_without_partitioning_rbsp_idr"&&(v=!0)),v},Um={parseType:Pm,parsePat:Mm,parsePmt:Rm,parsePayloadUnitStartIndicator:Ns,parsePesType:Vm,parsePesTime:Fm,videoPacketContainsKeyFrame:$m},Zu=he,Un=mt.handleRollover,nt={};nt.ts=Um,nt.aac=Ka;var xn=Ye.ONE_SECOND_IN_TS,Yt=188,Ri=71,qm=function(c,h){for(var m=0,p=Yt,_,v;p<c.byteLength;){if(c[m]===Ri&&c[p]===Ri){switch(_=c.subarray(m,p),v=nt.ts.parseType(_,h.pid),v){case"pat":h.pid=nt.ts.parsePat(_);break;case"pmt":var L=nt.ts.parsePmt(_);h.table=h.table||{},Object.keys(L).forEach(function(R){h.table[R]=L[R]});break}m+=Yt,p+=Yt;continue}m++,p++}},Ju=function(c,h,m){for(var p=0,_=Yt,v,L,R,z,Y,ie=!1;_<=c.byteLength;){if(c[p]===Ri&&(c[_]===Ri||_===c.byteLength)){switch(v=c.subarray(p,_),L=nt.ts.parseType(v,h.pid),L){case"pes":R=nt.ts.parsePesType(v,h.table),z=nt.ts.parsePayloadUnitStartIndicator(v),R==="audio"&&z&&(Y=nt.ts.parsePesTime(v),Y&&(Y.type="audio",m.audio.push(Y),ie=!0));break}if(ie)break;p+=Yt,_+=Yt;continue}p++,_++}for(_=c.byteLength,p=_-Yt,ie=!1;p>=0;){if(c[p]===Ri&&(c[_]===Ri||_===c.byteLength)){switch(v=c.subarray(p,_),L=nt.ts.parseType(v,h.pid),L){case"pes":R=nt.ts.parsePesType(v,h.table),z=nt.ts.parsePayloadUnitStartIndicator(v),R==="audio"&&z&&(Y=nt.ts.parsePesTime(v),Y&&(Y.type="audio",m.audio.push(Y),ie=!0));break}if(ie)break;p-=Yt,_-=Yt;continue}p--,_--}},jm=function(c,h,m){for(var p=0,_=Yt,v,L,R,z,Y,ie,ae,Te,le=!1,Ae={data:[],size:0};_<c.byteLength;){if(c[p]===Ri&&c[_]===Ri){switch(v=c.subarray(p,_),L=nt.ts.parseType(v,h.pid),L){case"pes":if(R=nt.ts.parsePesType(v,h.table),z=nt.ts.parsePayloadUnitStartIndicator(v),R==="video"&&(z&&!le&&(Y=nt.ts.parsePesTime(v),Y&&(Y.type="video",m.video.push(Y),le=!0)),!m.firstKeyFrame)){if(z&&Ae.size!==0){for(ie=new Uint8Array(Ae.size),ae=0;Ae.data.length;)Te=Ae.data.shift(),ie.set(Te,ae),ae+=Te.byteLength;if(nt.ts.videoPacketContainsKeyFrame(ie)){var $e=nt.ts.parsePesTime(ie);$e?(m.firstKeyFrame=$e,m.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}Ae.size=0}Ae.data.push(v),Ae.size+=v.byteLength}break}if(le&&m.firstKeyFrame)break;p+=Yt,_+=Yt;continue}p++,_++}for(_=c.byteLength,p=_-Yt,le=!1;p>=0;){if(c[p]===Ri&&c[_]===Ri){switch(v=c.subarray(p,_),L=nt.ts.parseType(v,h.pid),L){case"pes":R=nt.ts.parsePesType(v,h.table),z=nt.ts.parsePayloadUnitStartIndicator(v),R==="video"&&z&&(Y=nt.ts.parsePesTime(v),Y&&(Y.type="video",m.video.push(Y),le=!0));break}if(le)break;p-=Yt,_-=Yt;continue}p--,_--}},Hm=function(c,h){if(c.audio&&c.audio.length){var m=h;(typeof m>"u"||isNaN(m))&&(m=c.audio[0].dts),c.audio.forEach(function(v){v.dts=Un(v.dts,m),v.pts=Un(v.pts,m),v.dtsTime=v.dts/xn,v.ptsTime=v.pts/xn})}if(c.video&&c.video.length){var p=h;if((typeof p>"u"||isNaN(p))&&(p=c.video[0].dts),c.video.forEach(function(v){v.dts=Un(v.dts,p),v.pts=Un(v.pts,p),v.dtsTime=v.dts/xn,v.ptsTime=v.pts/xn}),c.firstKeyFrame){var _=c.firstKeyFrame;_.dts=Un(_.dts,p),_.pts=Un(_.pts,p),_.dtsTime=_.dts/xn,_.ptsTime=_.pts/xn}}},zm=function(c){for(var h=!1,m=0,p=null,_=null,v=0,L=0,R;c.length-L>=3;){var z=nt.aac.parseType(c,L);switch(z){case"timed-metadata":if(c.length-L<10){h=!0;break}if(v=nt.aac.parseId3TagSize(c,L),v>c.length){h=!0;break}_===null&&(R=c.subarray(L,L+v),_=nt.aac.parseAacTimestamp(R)),L+=v;break;case"audio":if(c.length-L<7){h=!0;break}if(v=nt.aac.parseAdtsSize(c,L),v>c.length){h=!0;break}p===null&&(R=c.subarray(L,L+v),p=nt.aac.parseSampleRate(R)),m++,L+=v;break;default:L++;break}if(h)return null}if(p===null||_===null)return null;var Y=xn/p,ie={audio:[{type:"audio",dts:_,pts:_},{type:"audio",dts:_+m*1024*Y,pts:_+m*1024*Y}]};return ie},Gm=function(c){var h={pid:null,table:null},m={};qm(c,h);for(var p in h.table)if(h.table.hasOwnProperty(p)){var _=h.table[p];switch(_){case Zu.H264_STREAM_TYPE:m.video=[],jm(c,h,m),m.video.length===0&&delete m.video;break;case Zu.ADTS_STREAM_TYPE:m.audio=[],Ju(c,h,m),m.audio.length===0&&delete m.audio;break}}return m},Wm=function(c,h){var m=nt.aac.isLikelyAacData(c),p;return m?p=zm(c):p=Gm(c),!p||!p.audio&&!p.video?null:(Hm(p,h),p)},Ym={inspect:Wm,parseAudioPes_:Ju};const Xm=function(c,h){h.on("data",function(m){const p=m.initSegment;m.initSegment={data:p.buffer,byteOffset:p.byteOffset,byteLength:p.byteLength};const _=m.data;m.data=_.buffer,c.postMessage({action:"data",segment:m,byteOffset:_.byteOffset,byteLength:_.byteLength},[m.data])}),h.on("done",function(m){c.postMessage({action:"done"})}),h.on("gopInfo",function(m){c.postMessage({action:"gopInfo",gopInfo:m})}),h.on("videoSegmentTimingInfo",function(m){const p={start:{decode:Ye.videoTsToSeconds(m.start.dts),presentation:Ye.videoTsToSeconds(m.start.pts)},end:{decode:Ye.videoTsToSeconds(m.end.dts),presentation:Ye.videoTsToSeconds(m.end.pts)},baseMediaDecodeTime:Ye.videoTsToSeconds(m.baseMediaDecodeTime)};m.prependedContentDuration&&(p.prependedContentDuration=Ye.videoTsToSeconds(m.prependedContentDuration)),c.postMessage({action:"videoSegmentTimingInfo",videoSegmentTimingInfo:p})}),h.on("audioSegmentTimingInfo",function(m){const p={start:{decode:Ye.videoTsToSeconds(m.start.dts),presentation:Ye.videoTsToSeconds(m.start.pts)},end:{decode:Ye.videoTsToSeconds(m.end.dts),presentation:Ye.videoTsToSeconds(m.end.pts)},baseMediaDecodeTime:Ye.videoTsToSeconds(m.baseMediaDecodeTime)};m.prependedContentDuration&&(p.prependedContentDuration=Ye.videoTsToSeconds(m.prependedContentDuration)),c.postMessage({action:"audioSegmentTimingInfo",audioSegmentTimingInfo:p})}),h.on("id3Frame",function(m){c.postMessage({action:"id3Frame",id3Frame:m})}),h.on("caption",function(m){c.postMessage({action:"caption",caption:m})}),h.on("trackinfo",function(m){c.postMessage({action:"trackinfo",trackInfo:m})}),h.on("audioTimingInfo",function(m){c.postMessage({action:"audioTimingInfo",audioTimingInfo:{start:Ye.videoTsToSeconds(m.start),end:Ye.videoTsToSeconds(m.end)}})}),h.on("videoTimingInfo",function(m){c.postMessage({action:"videoTimingInfo",videoTimingInfo:{start:Ye.videoTsToSeconds(m.start),end:Ye.videoTsToSeconds(m.end)}})}),h.on("log",function(m){c.postMessage({action:"log",log:m})})};class ec{constructor(h,m){this.options=m||{},this.self=h,this.init()}init(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new zp.Transmuxer(this.options),Xm(this.self,this.transmuxer)}pushMp4Captions(h){this.captionParser||(this.captionParser=new Im,this.captionParser.init());const m=new Uint8Array(h.data,h.byteOffset,h.byteLength),p=this.captionParser.parse(m,h.trackIds,h.timescales);this.self.postMessage({action:"mp4Captions",captions:p&&p.captions||[],logs:p&&p.logs||[],data:m.buffer},[m.buffer])}initMp4WebVttParser(h){this.webVttParser||(this.webVttParser=new Ku);const m=new Uint8Array(h.data,h.byteOffset,h.byteLength);this.webVttParser.init(m)}getMp4WebVttText(h){this.webVttParser||(this.webVttParser=new Ku);const m=new Uint8Array(h.data,h.byteOffset,h.byteLength),p=this.webVttParser.parseSegment(m);this.self.postMessage({action:"getMp4WebVttText",mp4VttCues:p||[],data:m.buffer},[m.buffer])}probeMp4StartTime({timescales:h,data:m}){const p=Lr.startTime(h,m);this.self.postMessage({action:"probeMp4StartTime",startTime:p,data:m},[m.buffer])}probeMp4Tracks({data:h}){const m=Lr.tracks(h);this.self.postMessage({action:"probeMp4Tracks",tracks:m,data:h},[h.buffer])}probeEmsgID3({data:h,offset:m}){const p=Lr.getEmsgID3(h,m);this.self.postMessage({action:"probeEmsgID3",id3Frames:p,emsgData:h},[h.buffer])}probeTs({data:h,baseStartTime:m}){const p=typeof m=="number"&&!isNaN(m)?m*Ye.ONE_SECOND_IN_TS:void 0,_=Ym.inspect(h,p);let v=null;_&&(v={hasVideo:_.video&&_.video.length===2||!1,hasAudio:_.audio&&_.audio.length===2||!1},v.hasVideo&&(v.videoStart=_.video[0].ptsTime),v.hasAudio&&(v.audioStart=_.audio[0].ptsTime)),this.self.postMessage({action:"probeTs",result:v,data:h},[h.buffer])}clearAllMp4Captions(){this.captionParser&&this.captionParser.clearAllCaptions()}clearParsedMp4Captions(){this.captionParser&&this.captionParser.clearParsedCaptions()}push(h){const m=new Uint8Array(h.data,h.byteOffset,h.byteLength);this.transmuxer.push(m)}reset(){this.transmuxer.reset()}setTimestampOffset(h){const m=h.timestampOffset||0;this.transmuxer.setBaseMediaDecodeTime(Math.round(Ye.secondsToVideoTs(m)))}setAudioAppendStart(h){this.transmuxer.setAudioAppendStart(Math.ceil(Ye.secondsToVideoTs(h.appendStart)))}setRemux(h){this.transmuxer.setRemux(h.remux)}flush(h){this.transmuxer.flush(),self.postMessage({action:"done",type:"transmuxed"})}endTimeline(){this.transmuxer.endTimeline(),self.postMessage({action:"endedtimeline",type:"transmuxed"})}alignGopsWith(h){this.transmuxer.alignGopsWith(h.gopsToAlignWith.slice())}}self.onmessage=function(c){if(c.data.action==="init"&&c.data.options){this.messageHandlers=new ec(self,c.data.options);return}this.messageHandlers||(this.messageHandlers=new ec(self)),c.data&&c.data.action&&c.data.action!=="init"&&this.messageHandlers[c.data.action]&&this.messageHandlers[c.data.action](c.data)}}));var MC=Ff(PC);const RC=(s,e,i)=>{const{type:r,initSegment:a,captions:o,captionStreams:l,metadata:u,videoFrameDtsTime:d,videoFramePtsTime:f}=s.data.segment;e.buffer.push({captions:o,captionStreams:l,metadata:u});const g=s.data.segment.boxes||{data:s.data.segment.data},y={type:r,data:new Uint8Array(g.data,g.data.byteOffset,g.data.byteLength),initSegment:new Uint8Array(a.data,a.byteOffset,a.byteLength)};typeof d<"u"&&(y.videoFrameDtsTime=d),typeof f<"u"&&(y.videoFramePtsTime=f),i(y)},VC=({transmuxedData:s,callback:e})=>{s.buffer=[],e(s)},FC=(s,e)=>{e.gopInfo=s.data.gopInfo},qf=s=>{const{transmuxer:e,bytes:i,audioAppendStart:r,gopsToAlignWith:a,remux:o,onData:l,onTrackInfo:u,onAudioTimingInfo:d,onVideoTimingInfo:f,onVideoSegmentTimingInfo:g,onAudioSegmentTimingInfo:y,onId3:E,onCaptions:x,onDone:B,onEndedTimeline:T,onTransmuxerLog:w,isEndOfTimeline:F,segment:P,triggerSegmentEventFn:I}=s,K={buffer:[]};let q=F;const M=J=>{e.currentTransmux===s&&(J.data.action==="data"&&RC(J,K,l),J.data.action==="trackinfo"&&u(J.data.trackInfo),J.data.action==="gopInfo"&&FC(J,K),J.data.action==="audioTimingInfo"&&d(J.data.audioTimingInfo),J.data.action==="videoTimingInfo"&&f(J.data.videoTimingInfo),J.data.action==="videoSegmentTimingInfo"&&g(J.data.videoSegmentTimingInfo),J.data.action==="audioSegmentTimingInfo"&&y(J.data.audioSegmentTimingInfo),J.data.action==="id3Frame"&&E([J.data.id3Frame],J.data.id3Frame.dispatchType),J.data.action==="caption"&&x(J.data.caption),J.data.action==="endedtimeline"&&(q=!1,T()),J.data.action==="log"&&w(J.data.log),J.data.type==="transmuxed"&&(q||(e.onmessage=null,VC({transmuxedData:K,callback:B}),jf(e))))},N=()=>{const J={message:"Received an error message from the transmuxer worker",metadata:{errorType:ne.Error.StreamingFailedToTransmuxSegment,segmentInfo:wn({segment:P})}};B(null,J)};if(e.onmessage=M,e.onerror=N,r&&e.postMessage({action:"setAudioAppendStart",appendStart:r}),Array.isArray(a)&&e.postMessage({action:"alignGopsWith",gopsToAlignWith:a}),typeof o<"u"&&e.postMessage({action:"setRemux",remux:o}),i.byteLength){const J=i instanceof ArrayBuffer?i:i.buffer,b=i instanceof ArrayBuffer?0:i.byteOffset;I({type:"segmenttransmuxingstart",segment:P}),e.postMessage({action:"push",data:J,byteOffset:b,byteLength:i.byteLength},[J])}F&&e.postMessage({action:"endTimeline"}),e.postMessage({action:"flush"})},jf=s=>{s.currentTransmux=null,s.transmuxQueue.length&&(s.currentTransmux=s.transmuxQueue.shift(),typeof s.currentTransmux=="function"?s.currentTransmux():qf(s.currentTransmux))},qd=(s,e)=>{s.postMessage({action:e}),jf(s)},Hf=(s,e)=>{if(!e.currentTransmux){e.currentTransmux=s,qd(e,s);return}e.transmuxQueue.push(qd.bind(null,e,s))},$C=s=>{Hf("reset",s)},UC=s=>{Hf("endTimeline",s)},zf=s=>{if(!s.transmuxer.currentTransmux){s.transmuxer.currentTransmux=s,qf(s);return}s.transmuxer.transmuxQueue.push(s)},qC=s=>{const e=new MC;e.currentTransmux=null,e.transmuxQueue=[];const i=e.terminate;return e.terminate=()=>(e.currentTransmux=null,e.transmuxQueue.length=0,i.call(e)),e.postMessage({action:"init",options:s}),e};var Yo={reset:$C,endTimeline:UC,transmux:zf,createTransmuxer:qC};const tr=function(s){const e=s.transmuxer,i=s.endAction||s.action,r=s.callback,a=bt({},s,{endAction:null,transmuxer:null,callback:null}),o=l=>{l.data.action===i&&(e.removeEventListener("message",o),l.data.data&&(l.data.data=new Uint8Array(l.data.data,s.byteOffset||0,s.byteLength||l.data.data.byteLength),s.data&&(s.data=l.data.data)),r(l.data))};if(e.addEventListener("message",o),s.data){const l=s.data instanceof ArrayBuffer;a.byteOffset=l?0:s.data.byteOffset,a.byteLength=s.data.byteLength;const u=[l?s.data:s.data.buffer];e.postMessage(a,u)}else e.postMessage(a)},Hi={FAILURE:2,TIMEOUT:-101,ABORTED:-102},Gf="wvtt",xl=s=>{s.forEach(e=>{e.abort()})},jC=s=>({bandwidth:s.bandwidth,bytesReceived:s.bytesReceived||0,roundTripTime:s.roundTripTime||0}),HC=s=>{const e=s.target,r={bandwidth:1/0,bytesReceived:0,roundTripTime:Date.now()-e.requestTime||0};return r.bytesReceived=s.loaded,r.bandwidth=Math.floor(r.bytesReceived/r.roundTripTime*8*1e3),r},fu=(s,e)=>{const{requestType:i}=e,r=Pn({requestType:i,request:e,error:s});return e.timedout?{status:e.status,message:"HLS request timed-out at URL: "+e.uri,code:Hi.TIMEOUT,xhr:e,metadata:r}:e.aborted?{status:e.status,message:"HLS request aborted at URL: "+e.uri,code:Hi.ABORTED,xhr:e,metadata:r}:s?{status:e.status,message:"HLS request errored at URL: "+e.uri,code:Hi.FAILURE,xhr:e,metadata:r}:e.responseType==="arraybuffer"&&e.response.byteLength===0?{status:e.status,message:"Empty HLS response at URL: "+e.uri,code:Hi.FAILURE,xhr:e,metadata:r}:null},jd=(s,e,i,r)=>(a,o)=>{const l=o.response,u=fu(a,o);if(u)return i(u,s);if(l.byteLength!==16)return i({status:o.status,message:"Invalid HLS key at URL: "+o.uri,code:Hi.FAILURE,xhr:o},s);const d=new DataView(l),f=new Uint32Array([d.getUint32(0),d.getUint32(4),d.getUint32(8),d.getUint32(12)]);for(let y=0;y<e.length;y++)e[y].bytes=f;const g={uri:o.uri};return r({type:"segmentkeyloadcomplete",segment:s,keyInfo:g}),i(null,s)},zC=(s,e)=>{e===Gf&&s.transmuxer.postMessage({action:"initMp4WebVttParser",data:s.map.bytes})},GC=(s,e,i)=>{e===Gf&&tr({action:"getMp4WebVttText",data:s.bytes,transmuxer:s.transmuxer,callback:({data:r,mp4VttCues:a})=>{s.bytes=r,i(null,s,{mp4VttCues:a})}})},Wf=(s,e)=>{const i=Ml(s.map.bytes);if(i!=="mp4"){const r=s.map.resolvedUri||s.map.uri,a=i||"unknown";return e({internal:!0,message:`Found unsupported ${a} container for initialization segment at URL: ${r}`,code:Hi.FAILURE,metadata:{mediaType:a}})}tr({action:"probeMp4Tracks",data:s.map.bytes,transmuxer:s.transmuxer,callback:({tracks:r,data:a})=>(s.map.bytes=a,r.forEach(function(o){s.map.tracks=s.map.tracks||{},!s.map.tracks[o.type]&&(s.map.tracks[o.type]=o,typeof o.id=="number"&&o.timescale&&(s.map.timescales=s.map.timescales||{},s.map.timescales[o.id]=o.timescale),o.type==="text"&&zC(s,o.codec))}),e(null))})},WC=({segment:s,finishProcessingFn:e,triggerSegmentEventFn:i})=>(r,a)=>{const o=fu(r,a);if(o)return e(o,s);const l=new Uint8Array(a.response);if(i({type:"segmentloaded",segment:s}),s.map.key)return s.map.encryptedBytes=l,e(null,s);s.map.bytes=l,Wf(s,function(u){if(u)return u.xhr=a,u.status=a.status,e(u,s);e(null,s)})},YC=({segment:s,finishProcessingFn:e,responseType:i,triggerSegmentEventFn:r})=>(a,o)=>{const l=fu(a,o);if(l)return e(l,s);r({type:"segmentloaded",segment:s});const u=i==="arraybuffer"||!o.responseText?o.response:BC(o.responseText.substring(s.lastReachedChar||0));return s.stats=jC(o),s.key?s.encryptedBytes=new Uint8Array(u):s.bytes=new Uint8Array(u),e(null,s)},XC=({segment:s,bytes:e,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x})=>{const B=s.map&&s.map.tracks||{},T=!!(B.audio&&B.video);let w=r.bind(null,s,"audio","start");const F=r.bind(null,s,"audio","end");let P=r.bind(null,s,"video","start");const I=r.bind(null,s,"video","end"),K=()=>zf({bytes:e,transmuxer:s.transmuxer,audioAppendStart:s.audioAppendStart,gopsToAlignWith:s.gopsToAlignWith,remux:T,onData:q=>{q.type=q.type==="combined"?"video":q.type,g(s,q)},onTrackInfo:q=>{i&&(T&&(q.isMuxed=!0),i(s,q))},onAudioTimingInfo:q=>{w&&typeof q.start<"u"&&(w(q.start),w=null),F&&typeof q.end<"u"&&F(q.end)},onVideoTimingInfo:q=>{P&&typeof q.start<"u"&&(P(q.start),P=null),I&&typeof q.end<"u"&&I(q.end)},onVideoSegmentTimingInfo:q=>{const M={pts:{start:q.start.presentation,end:q.end.presentation},dts:{start:q.start.decode,end:q.end.decode}};x({type:"segmenttransmuxingtiminginfoavailable",segment:s,timingInfo:M}),a(q)},onAudioSegmentTimingInfo:q=>{const M={pts:{start:q.start.pts,end:q.end.pts},dts:{start:q.start.dts,end:q.end.dts}};x({type:"segmenttransmuxingtiminginfoavailable",segment:s,timingInfo:M}),o(q)},onId3:(q,M)=>{l(s,q,M)},onCaptions:q=>{u(s,[q])},isEndOfTimeline:d,onEndedTimeline:()=>{f()},onTransmuxerLog:E,onDone:(q,M)=>{y&&(q.type=q.type==="combined"?"video":q.type,x({type:"segmenttransmuxingcomplete",segment:s}),y(M,s,q))},segment:s,triggerSegmentEventFn:x});tr({action:"probeTs",transmuxer:s.transmuxer,data:e,baseStartTime:s.baseStartTime,callback:q=>{s.bytes=e=q.data;const M=q.result;M&&(i(s,{hasAudio:M.hasAudio,hasVideo:M.hasVideo,isMuxed:T}),i=null),K()}})},Yf=({segment:s,bytes:e,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x})=>{let B=new Uint8Array(e);if(g8(B)){s.isFmp4=!0;const{tracks:T}=s.map;if(T.text&&(!T.audio||!T.video)){g(s,{data:B,type:"text"}),GC(s,T.text.codec,y);return}const F={isFmp4:!0,hasVideo:!!T.video,hasAudio:!!T.audio};T.audio&&T.audio.codec&&T.audio.codec!=="enca"&&(F.audioCodec=T.audio.codec),T.video&&T.video.codec&&T.video.codec!=="encv"&&(F.videoCodec=T.video.codec),T.video&&T.audio&&(F.isMuxed=!0),i(s,F);const P=(I,K)=>{g(s,{data:B,type:F.hasAudio&&!F.isMuxed?"audio":"video"}),K&&K.length&&l(s,K),I&&I.length&&u(s,I),y(null,s,{})};tr({action:"probeMp4StartTime",timescales:s.map.timescales,data:B,transmuxer:s.transmuxer,callback:({data:I,startTime:K})=>{e=I.buffer,s.bytes=B=I,F.hasAudio&&!F.isMuxed&&r(s,"audio","start",K),F.hasVideo&&r(s,"video","start",K),tr({action:"probeEmsgID3",data:B,transmuxer:s.transmuxer,offset:K,callback:({emsgData:q,id3Frames:M})=>{if(e=q.buffer,s.bytes=B=q,!T.video||!q.byteLength||!s.transmuxer){P(void 0,M);return}tr({action:"pushMp4Captions",endAction:"mp4Captions",transmuxer:s.transmuxer,data:B,timescales:s.map.timescales,trackIds:[T.video.id],callback:N=>{e=N.data.buffer,s.bytes=B=N.data,N.logs.forEach(function(J){E(it(J,{stream:"mp4CaptionParser"}))}),P(N.captions,M)}})}})}});return}if(!s.transmuxer){y(null,s,{});return}if(typeof s.container>"u"&&(s.container=Ml(B)),s.container!=="ts"&&s.container!=="aac"){i(s,{hasAudio:!1,hasVideo:!1}),y(null,s,{});return}XC({segment:s,bytes:e,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x})},Xf=function({id:s,key:e,encryptedBytes:i,decryptionWorker:r,segment:a,doneFn:o},l){const u=f=>{if(f.data.source===s){r.removeEventListener("message",u);const g=f.data.decrypted;l(new Uint8Array(g.bytes,g.byteOffset,g.byteLength))}};r.onerror=()=>{const f="An error occurred in the decryption worker",g=wn({segment:a}),y={message:f,metadata:{error:new Error(f),errorType:ne.Error.StreamingFailedToDecryptSegment,segmentInfo:g,keyInfo:{uri:a.key.resolvedUri||a.map.key.resolvedUri}}};o(y,a)},r.addEventListener("message",u);let d;e.bytes.slice?d=e.bytes.slice():d=new Uint32Array(Array.prototype.slice.call(e.bytes)),r.postMessage(Bf({source:s,encrypted:i,key:d,iv:e.iv}),[i.buffer,d.buffer])},KC=({decryptionWorker:s,segment:e,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x})=>{x({type:"segmentdecryptionstart"}),Xf({id:e.requestId,key:e.key,encryptedBytes:e.encryptedBytes,decryptionWorker:s,segment:e,doneFn:y},B=>{e.bytes=B,x({type:"segmentdecryptioncomplete",segment:e}),Yf({segment:e,bytes:e.bytes,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x})})},QC=({activeXhrs:s,decryptionWorker:e,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x})=>{let B=0,T=!1;return(w,F)=>{if(!T){if(w)return T=!0,xl(s),y(w,F);if(B+=1,B===s.length){const P=function(){if(F.encryptedBytes)return KC({decryptionWorker:e,segment:F,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x});Yf({segment:F,bytes:F.bytes,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g,doneFn:y,onTransmuxerLog:E,triggerSegmentEventFn:x})};if(F.endOfAllRequests=Date.now(),F.map&&F.map.encryptedBytes&&!F.map.bytes)return x({type:"segmentdecryptionstart",segment:F}),Xf({decryptionWorker:e,id:F.requestId+"-init",encryptedBytes:F.map.encryptedBytes,key:F.map.key,segment:F,doneFn:y},I=>{F.map.bytes=I,x({type:"segmentdecryptioncomplete",segment:F}),Wf(F,K=>{if(K)return xl(s),y(K,F);P()})});P()}}}},ZC=({loadendState:s,abortFn:e})=>i=>{i.target.aborted&&e&&!s.calledAbortFn&&(e(),s.calledAbortFn=!0)},JC=({segment:s,progressFn:e,trackInfoFn:i,timingInfoFn:r,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:o,id3Fn:l,captionsFn:u,isEndOfTimeline:d,endedTimelineFn:f,dataFn:g})=>y=>{if(!y.target.aborted)return s.stats=it(s.stats,HC(y)),!s.stats.firstBytesReceivedAt&&s.stats.bytesReceived&&(s.stats.firstBytesReceivedAt=Date.now()),e(y,s)},e5=({xhr:s,xhrOptions:e,decryptionWorker:i,segment:r,abortFn:a,progressFn:o,trackInfoFn:l,timingInfoFn:u,videoSegmentTimingInfoFn:d,audioSegmentTimingInfoFn:f,id3Fn:g,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:x,dataFn:B,doneFn:T,onTransmuxerLog:w,triggerSegmentEventFn:F})=>{const P=[],I=QC({activeXhrs:P,decryptionWorker:i,trackInfoFn:l,timingInfoFn:u,videoSegmentTimingInfoFn:d,audioSegmentTimingInfoFn:f,id3Fn:g,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:x,dataFn:B,doneFn:T,onTransmuxerLog:w,triggerSegmentEventFn:F});if(r.key&&!r.key.bytes){const J=[r.key];r.map&&!r.map.bytes&&r.map.key&&r.map.key.resolvedUri===r.key.resolvedUri&&J.push(r.map.key);const b=it(e,{uri:r.key.resolvedUri,responseType:"arraybuffer",requestType:"segment-key"}),C=jd(r,J,I,F),U={uri:r.key.resolvedUri};F({type:"segmentkeyloadstart",segment:r,keyInfo:U});const j=s(b,C);P.push(j)}if(r.map&&!r.map.bytes){if(r.map.key&&(!r.key||r.key.resolvedUri!==r.map.key.resolvedUri)){const j=it(e,{uri:r.map.key.resolvedUri,responseType:"arraybuffer",requestType:"segment-key"}),k=jd(r,[r.map.key],I,F),A={uri:r.map.key.resolvedUri};F({type:"segmentkeyloadstart",segment:r,keyInfo:A});const $=s(j,k);P.push($)}const b=it(e,{uri:r.map.resolvedUri,responseType:"arraybuffer",headers:Tl(r.map),requestType:"segment-media-initialization"}),C=WC({segment:r,finishProcessingFn:I,triggerSegmentEventFn:F});F({type:"segmentloadstart",segment:r});const U=s(b,C);P.push(U)}const K=it(e,{uri:r.part&&r.part.resolvedUri||r.resolvedUri,responseType:"arraybuffer",headers:Tl(r),requestType:"segment"}),q=YC({segment:r,finishProcessingFn:I,responseType:K.responseType,triggerSegmentEventFn:F});F({type:"segmentloadstart",segment:r});const M=s(K,q);M.addEventListener("progress",JC({segment:r,progressFn:o,trackInfoFn:l,timingInfoFn:u,videoSegmentTimingInfoFn:d,audioSegmentTimingInfoFn:f,id3Fn:g,captionsFn:y,isEndOfTimeline:E,endedTimelineFn:x,dataFn:B})),P.push(M);const N={};return P.forEach(J=>{J.addEventListener("loadend",ZC({loadendState:N,abortFn:a}))}),()=>xl(P)},Hs=bi("PlaylistSelector"),Hd=function(s){if(!s||!s.playlist)return;const e=s.playlist;return JSON.stringify({id:e.id,bandwidth:s.bandwidth,width:s.width,height:s.height,codecs:e.attributes&&e.attributes.CODECS||""})},ir=function(s,e){if(!s)return"";const i=W.getComputedStyle(s);return i?i[e]:""},nr=function(s,e){const i=s.slice();s.sort(function(r,a){const o=e(r,a);return o===0?i.indexOf(r)-i.indexOf(a):o})},pu=function(s,e){let i,r;return s.attributes.BANDWIDTH&&(i=s.attributes.BANDWIDTH),i=i||W.Number.MAX_VALUE,e.attributes.BANDWIDTH&&(r=e.attributes.BANDWIDTH),r=r||W.Number.MAX_VALUE,i-r},t5=function(s,e){let i,r;return s.attributes.RESOLUTION&&s.attributes.RESOLUTION.width&&(i=s.attributes.RESOLUTION.width),i=i||W.Number.MAX_VALUE,e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width&&(r=e.attributes.RESOLUTION.width),r=r||W.Number.MAX_VALUE,i===r&&s.attributes.BANDWIDTH&&e.attributes.BANDWIDTH?s.attributes.BANDWIDTH-e.attributes.BANDWIDTH:i-r};let Kf=function(s){const{main:e,bandwidth:i,playerWidth:r,playerHeight:a,playerObjectFit:o,limitRenditionByPlayerDimensions:l,playlistController:u}=s;if(!e)return;const d={bandwidth:i,width:r,height:a,limitRenditionByPlayerDimensions:l};let f=e.playlists;ai.isAudioOnly(e)&&(f=u.getAudioTrackPlaylists_(),d.audioOnly=!0);let g=f.map(N=>{let J;const b=N.attributes&&N.attributes.RESOLUTION&&N.attributes.RESOLUTION.width,C=N.attributes&&N.attributes.RESOLUTION&&N.attributes.RESOLUTION.height;return J=N.attributes&&N.attributes.BANDWIDTH,J=J||W.Number.MAX_VALUE,{bandwidth:J,width:b,height:C,playlist:N}});nr(g,(N,J)=>N.bandwidth-J.bandwidth),g=g.filter(N=>!ai.isIncompatible(N.playlist));let y=g.filter(N=>ai.isEnabled(N.playlist));y.length||(y=g.filter(N=>!ai.isDisabled(N.playlist)));const E=y.filter(N=>N.bandwidth*At.BANDWIDTH_VARIANCE<i);let x=E[E.length-1];const B=E.filter(N=>N.bandwidth===x.bandwidth)[0];if(l===!1){const N=B||y[0]||g[0];if(N&&N.playlist){let J="sortedPlaylistReps";return B&&(J="bandwidthBestRep"),y[0]&&(J="enabledPlaylistReps"),Hs(`choosing ${Hd(N)} using ${J} with options`,d),N.playlist}return Hs("could not choose a playlist with options",d),null}const T=E.filter(N=>N.width&&N.height);nr(T,(N,J)=>N.width-J.width);const w=T.filter(N=>N.width===r&&N.height===a);x=w[w.length-1];const F=w.filter(N=>N.bandwidth===x.bandwidth)[0];let P,I,K;F||(P=T.filter(N=>o==="cover"?N.width>r&&N.height>a:N.width>r||N.height>a),I=P.filter(N=>N.width===P[0].width&&N.height===P[0].height),x=I[I.length-1],K=I.filter(N=>N.bandwidth===x.bandwidth)[0]);let q;if(u.leastPixelDiffSelector){const N=T.map(J=>(J.pixelDiff=Math.abs(J.width-r)+Math.abs(J.height-a),J));nr(N,(J,b)=>J.pixelDiff===b.pixelDiff?b.bandwidth-J.bandwidth:J.pixelDiff-b.pixelDiff),q=N[0]}const M=q||K||F||B||y[0]||g[0];if(M&&M.playlist){let N="sortedPlaylistReps";return q?N="leastPixelDiffRep":K?N="resolutionPlusOneRep":F?N="resolutionBestRep":B?N="bandwidthBestRep":y[0]&&(N="enabledPlaylistReps"),Hs(`choosing ${Hd(M)} using ${N} with options`,d),M.playlist}return Hs("could not choose a playlist with options",d),null};const zd=function(){let s=this.useDevicePixelRatio&&W.devicePixelRatio||1;return isNaN(this.customPixelRatio)||(s=this.customPixelRatio),Kf({main:this.playlists.main,bandwidth:this.systemBandwidth,playerWidth:parseInt(ir(this.tech_.el(),"width"),10)*s,playerHeight:parseInt(ir(this.tech_.el(),"height"),10)*s,playerObjectFit:this.usePlayerObjectFit?ir(this.tech_.el(),"objectFit"):"",limitRenditionByPlayerDimensions:this.limitRenditionByPlayerDimensions,playlistController:this.playlistController_})},i5=function(s){let e=-1,i=-1;if(s<0||s>1)throw new Error("Moving average bandwidth decay must be between 0 and 1.");return function(){let r=this.useDevicePixelRatio&&W.devicePixelRatio||1;return isNaN(this.customPixelRatio)||(r=this.customPixelRatio),e<0&&(e=this.systemBandwidth,i=this.systemBandwidth),this.systemBandwidth>0&&this.systemBandwidth!==i&&(e=s*this.systemBandwidth+(1-s)*e,i=this.systemBandwidth),Kf({main:this.playlists.main,bandwidth:e,playerWidth:parseInt(ir(this.tech_.el(),"width"),10)*r,playerHeight:parseInt(ir(this.tech_.el(),"height"),10)*r,playerObjectFit:this.usePlayerObjectFit?ir(this.tech_.el(),"objectFit"):"",limitRenditionByPlayerDimensions:this.limitRenditionByPlayerDimensions,playlistController:this.playlistController_})}},n5=function(s){const{main:e,currentTime:i,bandwidth:r,duration:a,segmentDuration:o,timeUntilRebuffer:l,currentTimeline:u,syncController:d}=s,f=e.playlists.filter(B=>!ai.isIncompatible(B));let g=f.filter(ai.isEnabled);g.length||(g=f.filter(B=>!ai.isDisabled(B)));const E=g.filter(ai.hasAttribute.bind(null,"BANDWIDTH")).map(B=>{const w=d.getSyncPoint(B,a,u,i)?1:2,P=ai.estimateSegmentRequestTime(o,r,B)*w-l;return{playlist:B,rebufferingImpact:P}}),x=E.filter(B=>B.rebufferingImpact<=0);return nr(x,(B,T)=>pu(T.playlist,B.playlist)),x.length?x[0]:(nr(E,(B,T)=>B.rebufferingImpact-T.rebufferingImpact),E[0]||null)},r5=function(){const s=this.playlists.main.playlists.filter(ai.isEnabled);return nr(s,(i,r)=>pu(i,r)),s.filter(i=>!!ts(this.playlists.main,i).video)[0]||null},s5=s=>{let e=0,i;return s.bytes&&(i=new Uint8Array(s.bytes),s.segments.forEach(r=>{i.set(r,e),e+=r.byteLength})),i};function Qf(s){try{return new URL(s).pathname.split("/").slice(-2).join("/")}catch{return""}}const a5=function(s,e,i){if(!s[i]){e.trigger({type:"usage",name:"vhs-608"});let r=i;/^cc708_/.test(i)&&(r="SERVICE"+i.split("_")[1]);const a=e.textTracks().getTrackById(r);if(a)s[i]=a;else{const o=e.options_.vhs&&e.options_.vhs.captionServices||{};let l=i,u=i,d=!1;const f=o[r];f&&(l=f.label,u=f.language,d=f.default),s[i]=e.addRemoteTextTrack({kind:"captions",id:r,default:d,label:l,language:u},!1).track}}},o5=function({inbandTextTracks:s,captionArray:e,timestampOffset:i}){if(!e)return;const r=W.WebKitDataCue||W.VTTCue;e.forEach(a=>{const o=a.stream;a.content?a.content.forEach(l=>{const u=new r(a.startTime+i,a.endTime+i,l.text);u.line=l.line,u.align="left",u.position=l.position,u.positionAlign="line-left",s[o].addCue(u)}):s[o].addCue(new r(a.startTime+i,a.endTime+i,a.text))})},l5=function(s){Object.defineProperties(s.frame,{id:{get(){return ne.log.warn("cue.frame.id is deprecated. Use cue.value.key instead."),s.value.key}},value:{get(){return ne.log.warn("cue.frame.value is deprecated. Use cue.value.data instead."),s.value.data}},privateData:{get(){return ne.log.warn("cue.frame.privateData is deprecated. Use cue.value.data instead."),s.value.data}}})},u5=({inbandTextTracks:s,metadataArray:e,timestampOffset:i,videoDuration:r})=>{if(!e)return;const a=W.WebKitDataCue||W.VTTCue,o=s.metadataTrack_;if(!o||(e.forEach(g=>{const y=g.cueTime+i;typeof y!="number"||W.isNaN(y)||y<0||!(y<1/0)||!g.frames||!g.frames.length||g.frames.forEach(E=>{const x=new a(y,y,E.value||E.url||E.data||"");x.frame=E,x.value=E,l5(x),o.addCue(x)})}),!o.cues||!o.cues.length))return;const l=o.cues,u=[];for(let g=0;g<l.length;g++)l[g]&&u.push(l[g]);const d=u.reduce((g,y)=>{const E=g[y.startTime]||[];return E.push(y),g[y.startTime]=E,g},{}),f=Object.keys(d).sort((g,y)=>Number(g)-Number(y));f.forEach((g,y)=>{const E=d[g],x=isFinite(r)?r:g,B=Number(f[y+1])||x;E.forEach(T=>{T.endTime=B})})},c5={id:"ID",class:"CLASS",startDate:"START-DATE",duration:"DURATION",endDate:"END-DATE",endOnNext:"END-ON-NEXT",plannedDuration:"PLANNED-DURATION",scte35Out:"SCTE35-OUT",scte35In:"SCTE35-IN"},d5=new Set(["id","class","startDate","duration","endDate","endOnNext","startTime","endTime","processDateRange"]),h5=({inbandTextTracks:s,dateRanges:e})=>{const i=s.metadataTrack_;if(!i)return;const r=W.WebKitDataCue||W.VTTCue;e.forEach(a=>{for(const o of Object.keys(a)){if(d5.has(o))continue;const l=new r(a.startTime,a.endTime,"");l.id=a.id,l.type="com.apple.quicktime.HLS",l.value={key:c5[o],data:a[o]},(o==="scte35Out"||o==="scte35In")&&(l.value.data=new Uint8Array(l.value.data.match(/[\da-f]{2}/gi)).buffer),i.addCue(l)}a.processDateRange()})},Gd=(s,e,i)=>{s.metadataTrack_||(s.metadataTrack_=i.addRemoteTextTrack({kind:"metadata",label:"Timed Metadata"},!1).track,ne.browser.IS_ANY_SAFARI||(s.metadataTrack_.inBandMetadataTrackDispatchType=e))},Yr=function(s,e,i){let r,a;if(i&&i.cues)for(r=i.cues.length;r--;)a=i.cues[r],a.startTime>=s&&a.endTime<=e&&i.removeCue(a)},f5=function(s){const e=s.cues;if(!e)return;const i={};for(let r=e.length-1;r>=0;r--){const a=e[r],o=`${a.startTime}-${a.endTime}-${a.text}`;i[o]?s.removeCue(a):i[o]=a}},p5=(s,e,i)=>{if(typeof e>"u"||e===null||!s.length)return[];const r=Math.ceil((e-i+3)*Dn.ONE_SECOND_IN_TS);let a;for(a=0;a<s.length&&!(s[a].pts>r);a++);return s.slice(a)},m5=(s,e,i)=>{if(!e.length)return s;if(i)return e.slice();const r=e[0].pts;let a=0;for(a;a<s.length&&!(s[a].pts>=r);a++);return s.slice(0,a).concat(e)},g5=(s,e,i,r)=>{const a=Math.ceil((e-r)*Dn.ONE_SECOND_IN_TS),o=Math.ceil((i-r)*Dn.ONE_SECOND_IN_TS),l=s.slice();let u=s.length;for(;u--&&!(s[u].pts<=o););if(u===-1)return l;let d=u+1;for(;d--&&!(s[d].pts<=a););return d=Math.max(d,0),l.splice(d,u-d+1),l},_5=function(s,e){if(!s&&!e||!s&&e||s&&!e)return!1;if(s===e)return!0;const i=Object.keys(s).sort(),r=Object.keys(e).sort();if(i.length!==r.length)return!1;for(let a=0;a<i.length;a++){const o=i[a];if(o!==r[a]||s[o]!==e[o])return!1}return!0},y5=function(s,e,i){e=e||[];const r=[];let a=0;for(let o=0;o<e.length;o++){const l=e[o];if(s===l.timeline&&(r.push(o),a+=l.duration,a>i))return o}return r.length===0?0:r[r.length-1]},zr=1,v5=500,Wd=s=>typeof s=="number"&&isFinite(s),zs=1/60,T5=(s,e,i)=>s!=="main"||!e||!i?null:!i.hasAudio&&!i.hasVideo?"Neither audio nor video found in segment.":e.hasVideo&&!i.hasVideo?"Only audio found in segment when we expected video. We can't switch to audio only from a stream that had video. To get rid of this message, please add codec information to the manifest.":!e.hasVideo&&i.hasVideo?"Video found in segment when we expected only audio. We can't switch to a stream with video from an audio only stream. To get rid of this message, please add codec information to the manifest.":null,b5=(s,e,i)=>{let r=e-At.BACK_BUFFER_LENGTH;s.length&&(r=Math.max(r,s.start(0)));const a=e-i;return Math.min(a,r)},zn=s=>{const{startOfSegment:e,duration:i,segment:r,part:a,playlist:{mediaSequence:o,id:l,segments:u=[]},mediaIndex:d,partIndex:f,timeline:g}=s,y=u.length-1;let E="mediaIndex/partIndex increment";s.getMediaInfoForTime?E=`getMediaInfoForTime (${s.getMediaInfoForTime})`:s.isSyncRequest&&(E="getSyncSegmentCandidate (isSyncRequest)"),s.independent&&(E+=` with independent ${s.independent}`);const x=typeof f=="number",B=s.segment.uri?"segment":"pre-segment",T=x?mf({preloadSegment:r})-1:0;return`${B} [${o+d}/${o+y}]`+(x?` part [${f}/${T}]`:"")+` segment start/end [${r.start} => ${r.end}]`+(x?` part start/end [${a.start} => ${a.end}]`:"")+` startOfSegment [${e}] duration [${i}] timeline [${g}] selected by [${E}] playlist [${l}]`},Yd=s=>`${s}TimingInfo`,x5=({segmentTimeline:s,currentTimeline:e,startOfSegment:i,buffered:r,overrideCheck:a})=>!a&&s===e?null:s<e?i:r.length?r.end(r.length-1):i,Cl=({timelineChangeController:s,currentTimeline:e,segmentTimeline:i,loaderType:r,audioDisabled:a})=>{if(e===i)return!1;if(r==="audio"){const o=s.lastTimelineChange({type:"main"});return!o||o.to!==i}if(r==="main"&&a){const o=s.pendingTimelineChange({type:"audio"});return!(o&&o.to===i)}return!1},C5=s=>{if(!s)return!1;const e=s.pendingTimelineChange({type:"audio"}),i=s.pendingTimelineChange({type:"main"}),r=e&&i,a=r&&e.to!==i.to;return!!(r&&e.from!==-1&&i.from!==-1&&a)},S5=s=>{const e=s.timelineChangeController_.pendingTimelineChange({type:"audio"}),i=s.timelineChangeController_.pendingTimelineChange({type:"main"});return e&&i&&e.to<i.to},dn=s=>{const e=s.pendingSegment_;if(!e)return;if(Cl({timelineChangeController:s.timelineChangeController_,currentTimeline:s.currentTimeline_,segmentTimeline:e.timeline,loaderType:s.loaderType_,audioDisabled:s.audioDisabled_})&&C5(s.timelineChangeController_)){if(S5(s)){s.timelineChangeController_.trigger("audioTimelineBehind");return}s.timelineChangeController_.trigger("fixBadTimelineChange")}},E5=s=>{let e=0;return["video","audio"].forEach(function(i){const r=s[`${i}TimingInfo`];if(!r)return;const{start:a,end:o}=r;let l;typeof a=="bigint"||typeof o=="bigint"?l=W.BigInt(o)-W.BigInt(a):typeof a=="number"&&typeof o=="number"&&(l=o-a),typeof l<"u"&&l>e&&(e=l)}),typeof e=="bigint"&&e<Number.MAX_SAFE_INTEGER&&(e=Number(e)),e},Xd=({segmentDuration:s,maxDuration:e})=>s?Math.round(s)>e+qi:!1,k5=(s,e)=>{if(e!=="hls")return null;const i=E5({audioTimingInfo:s.audioTimingInfo,videoTimingInfo:s.videoTimingInfo});if(!i)return null;const r=s.playlist.targetDuration,a=Xd({segmentDuration:i,maxDuration:r*2}),o=Xd({segmentDuration:i,maxDuration:r}),l=`Segment with index ${s.mediaIndex} from playlist ${s.playlist.id} has a duration of ${i} when the reported duration is ${s.duration} and the target duration is ${r}. For HLS content, a duration in excess of the target duration may result in playback issues. See the HLS specification section on EXT-X-TARGETDURATION for more details: https://tools.ietf.org/html/draft-pantos-http-live-streaming-23#section-4.3.3.1`;return a||o?{severity:a?"warn":"info",message:l}:null},wn=({type:s,segment:e})=>{if(!e)return;const i=!!(e.key||e.map&&e.map.ke),r=!!(e.map&&!e.map.bytes),a=e.startOfSegment===void 0?e.start:e.startOfSegment;return{type:s||e.type,uri:e.resolvedUri||e.uri,start:a,duration:e.duration,isEncrypted:i,isMediaInitialization:r}};class Sl extends ne.EventTarget{constructor(e,i={}){if(super(),!e)throw new TypeError("Initialization settings are required");if(typeof e.currentTime!="function")throw new TypeError("No currentTime getter specified");if(!e.mediaSource)throw new TypeError("No MediaSource specified");this.bandwidth=e.bandwidth,this.throughput={rate:0,count:0},this.roundTrip=NaN,this.resetStats_(),this.mediaIndex=null,this.partIndex=null,this.hasPlayed_=e.hasPlayed,this.currentTime_=e.currentTime,this.seekable_=e.seekable,this.seeking_=e.seeking,this.duration_=e.duration,this.mediaSource_=e.mediaSource,this.vhs_=e.vhs,this.loaderType_=e.loaderType,this.currentMediaInfo_=void 0,this.startingMediaInfo_=void 0,this.segmentMetadataTrack_=e.segmentMetadataTrack,this.goalBufferLength_=e.goalBufferLength,this.sourceType_=e.sourceType,this.sourceUpdater_=e.sourceUpdater,this.inbandTextTracks_=e.inbandTextTracks,this.state_="INIT",this.timelineChangeController_=e.timelineChangeController,this.shouldSaveSegmentTimingInfo_=!0,this.parse708captions_=e.parse708captions,this.useDtsForTimestampOffset_=e.useDtsForTimestampOffset,this.captionServices_=e.captionServices,this.exactManifestTimings=e.exactManifestTimings,this.addMetadataToTextTrack=e.addMetadataToTextTrack,this.checkBufferTimeout_=null,this.error_=void 0,this.currentTimeline_=-1,this.shouldForceTimestampOffsetAfterResync_=!1,this.pendingSegment_=null,this.xhrOptions_=null,this.pendingSegments_=[],this.audioDisabled_=!1,this.isPendingTimestampOffset_=!1,this.gopBuffer_=[],this.timeMapping_=0,this.safeAppend_=!1,this.appendInitSegment_={audio:!0,video:!0},this.playlistOfLastInitSegment_={audio:null,video:null},this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_={id3:[],caption:[]},this.waitingOnRemove_=!1,this.quotaExceededErrorRetryTimeout_=null,this.activeInitSegmentId_=null,this.initSegments_={},this.cacheEncryptionKeys_=e.cacheEncryptionKeys,this.keyCache_={},this.decrypter_=e.decrypter,this.syncController_=e.syncController,this.syncPoint_={segmentIndex:0,time:0},this.transmuxer_=this.createTransmuxer_(),this.triggerSyncInfoUpdate_=()=>this.trigger("syncinfoupdate"),this.syncController_.on("syncinfoupdate",this.triggerSyncInfoUpdate_),this.mediaSource_.addEventListener("sourceopen",()=>{this.isEndOfStream_()||(this.ended_=!1)}),this.fetchAtBuffer_=!1,this.logger_=bi(`SegmentLoader[${this.loaderType_}]`),Object.defineProperty(this,"state",{get(){return this.state_},set(r){r!==this.state_&&(this.logger_(`${this.state_} -> ${r}`),this.state_=r,this.trigger("statechange"))}}),this.sourceUpdater_.on("ready",()=>{this.hasEnoughInfoToAppend_()?this.processCallQueue_():dn(this)}),this.sourceUpdater_.on("codecschange",r=>{this.trigger(bt({type:"codecschange"},r))}),this.loaderType_==="main"&&this.timelineChangeController_.on("pendingtimelinechange",()=>{this.hasEnoughInfoToAppend_()?this.processCallQueue_():dn(this)}),this.loaderType_==="audio"&&this.timelineChangeController_.on("timelinechange",r=>{this.trigger(bt({type:"timelinechange"},r)),this.hasEnoughInfoToLoad_()?this.processLoadQueue_():dn(this),this.hasEnoughInfoToAppend_()?this.processCallQueue_():dn(this)})}get mediaSequenceSync_(){return this.syncController_.getMediaSequenceSync(this.loaderType_)}createTransmuxer_(){return Yo.createTransmuxer({remux:!1,alignGopsAtEnd:this.safeAppend_,keepOriginalTimestamps:!0,parse708captions:this.parse708captions_,captionServices:this.captionServices_})}resetStats_(){this.mediaBytesTransferred=0,this.mediaRequests=0,this.mediaRequestsAborted=0,this.mediaRequestsTimedout=0,this.mediaRequestsErrored=0,this.mediaTransferDuration=0,this.mediaSecondsLoaded=0,this.mediaAppends=0}dispose(){this.trigger("dispose"),this.state="DISPOSED",this.pause(),this.abort_(),this.transmuxer_&&this.transmuxer_.terminate(),this.resetStats_(),this.checkBufferTimeout_&&W.clearTimeout(this.checkBufferTimeout_),this.syncController_&&this.triggerSyncInfoUpdate_&&this.syncController_.off("syncinfoupdate",this.triggerSyncInfoUpdate_),this.off()}setAudio(e){this.audioDisabled_=!e,e?this.appendInitSegment_.audio=!0:this.sourceUpdater_.removeAudio(0,this.duration_())}abort(){if(this.state!=="WAITING"){this.pendingSegment_&&(this.pendingSegment_=null),this.timelineChangeController_.clearPendingTimelineChange(this.loaderType_);return}this.abort_(),this.state="READY",this.paused()||this.monitorBuffer_()}abort_(){this.pendingSegment_&&this.pendingSegment_.abortRequests&&this.pendingSegment_.abortRequests(),this.pendingSegment_=null,this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.timelineChangeController_.clearPendingTimelineChange(this.loaderType_),this.waitingOnRemove_=!1,W.clearTimeout(this.quotaExceededErrorRetryTimeout_),this.quotaExceededErrorRetryTimeout_=null}checkForAbort_(e){return this.state==="APPENDING"&&!this.pendingSegment_?(this.state="READY",!0):!this.pendingSegment_||this.pendingSegment_.requestId!==e}error(e){return typeof e<"u"&&(this.logger_("error occurred:",e),this.error_=e),this.pendingSegment_=null,this.error_}endOfStream(){this.ended_=!0,this.transmuxer_&&Yo.reset(this.transmuxer_),this.gopBuffer_.length=0,this.pause(),this.trigger("ended")}buffered_(){const e=this.getMediaInfo_();if(!this.sourceUpdater_||!e)return Nt();if(this.loaderType_==="main"){const{hasAudio:i,hasVideo:r,isMuxed:a}=e;if(r&&i&&!this.audioDisabled_&&!a)return this.sourceUpdater_.buffered();if(r)return this.sourceUpdater_.videoBuffered()}return this.sourceUpdater_.audioBuffered()}initSegmentForMap(e,i=!1){if(!e)return null;const r=ba(e);let a=this.initSegments_[r];return i&&!a&&e.bytes&&(this.initSegments_[r]=a={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:e.bytes,tracks:e.tracks,timescales:e.timescales}),a||e}segmentKey(e,i=!1){if(!e)return null;const r=Lf(e);let a=this.keyCache_[r];this.cacheEncryptionKeys_&&i&&!a&&e.bytes&&(this.keyCache_[r]=a={resolvedUri:e.resolvedUri,bytes:e.bytes});const o={resolvedUri:(a||e).resolvedUri};return a&&(o.bytes=a.bytes),o}couldBeginLoading_(){return this.playlist_&&!this.paused()}load(){if(this.monitorBuffer_(),!!this.playlist_){if(this.state==="INIT"&&this.couldBeginLoading_())return this.init_();!this.couldBeginLoading_()||this.state!=="READY"&&this.state!=="INIT"||(this.state="READY")}}init_(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()}playlist(e,i={}){if(!e||this.playlist_&&this.playlist_.endList&&e.endList&&this.playlist_.uri===e.uri)return;const r=this.playlist_,a=this.pendingSegment_;this.playlist_=e,this.xhrOptions_=i,this.state==="INIT"&&(e.syncInfo={mediaSequence:e.mediaSequence,time:0},this.loaderType_==="main"&&this.syncController_.setDateTimeMappingForStart(e));let o=null;if(r&&(r.id?o=r.id:r.uri&&(o=r.uri)),this.logger_(`playlist update [${o} => ${e.id||e.uri}]`),this.mediaSequenceSync_&&(this.mediaSequenceSync_.update(e,this.currentTime_()),this.logger_(`Playlist update:
|
|
209
|
+
currentTime: ${this.currentTime_()}
|
|
210
|
+
bufferedEnd: ${Go(this.buffered_())}
|
|
211
|
+
`,this.mediaSequenceSync_.diagnostics)),this.trigger("syncinfoupdate"),this.state==="INIT"&&this.couldBeginLoading_())return this.init_();if(!r||r.uri!==e.uri){this.mediaIndex!==null&&(!e.endList&&typeof e.partTargetDuration=="number"?this.resetLoader():this.resyncLoader()),this.currentMediaInfo_=void 0,this.trigger("playlistupdate");return}const l=e.mediaSequence-r.mediaSequence;if(this.logger_(`live window shift [${l}]`),this.mediaIndex!==null)if(this.mediaIndex-=l,this.mediaIndex<0)this.mediaIndex=null,this.partIndex=null;else{const u=this.playlist_.segments[this.mediaIndex];if(this.partIndex&&(!u.parts||!u.parts.length||!u.parts[this.partIndex])){const d=this.mediaIndex;this.logger_(`currently processing part (index ${this.partIndex}) no longer exists.`),this.resetLoader(),this.mediaIndex=d}}a&&(a.mediaIndex-=l,a.mediaIndex<0?(a.mediaIndex=null,a.partIndex=null):(a.mediaIndex>=0&&(a.segment=e.segments[a.mediaIndex]),a.partIndex>=0&&a.segment.parts&&(a.part=a.segment.parts[a.partIndex]))),this.syncController_.saveExpiredSegmentInfo(r,e)}pause(){this.checkBufferTimeout_&&(W.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=null)}paused(){return this.checkBufferTimeout_===null}resetEverything(e){this.ended_=!1,this.activeInitSegmentId_=null,this.appendInitSegment_={audio:!0,video:!0},this.resetLoader(),this.remove(0,1/0,e),this.transmuxer_&&(this.transmuxer_.postMessage({action:"clearAllMp4Captions"}),this.transmuxer_.postMessage({action:"reset"}))}resetLoader(){this.fetchAtBuffer_=!1,this.mediaSequenceSync_&&this.mediaSequenceSync_.resetAppendedStatus(),this.resyncLoader()}resyncLoader(){this.transmuxer_&&Yo.reset(this.transmuxer_),this.mediaIndex=null,this.partIndex=null,this.syncPoint_=null,this.isPendingTimestampOffset_=!1;const e=this.currentMediaInfo_&&this.currentMediaInfo_.isFmp4;this.sourceType_==="hls"&&!e&&(this.shouldForceTimestampOffsetAfterResync_=!0),this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.abort(),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})}remove(e,i,r=()=>{},a=!1){if(i===1/0&&(i=this.duration_()),i<=e){this.logger_("skipping remove because end ${end} is <= start ${start}");return}if(!this.sourceUpdater_||!this.getMediaInfo_()){this.logger_("skipping remove because no source updater or starting media info");return}let o=1;const l=()=>{o--,o===0&&r()};(a||!this.audioDisabled_)&&(o++,this.sourceUpdater_.removeAudio(e,i,l)),(a||this.loaderType_==="main")&&(this.gopBuffer_=g5(this.gopBuffer_,e,i,this.timeMapping_),o++,this.sourceUpdater_.removeVideo(e,i,l));for(const u in this.inbandTextTracks_)Yr(e,i,this.inbandTextTracks_[u]);Yr(e,i,this.segmentMetadataTrack_),l()}monitorBuffer_(){this.checkBufferTimeout_&&W.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=W.setTimeout(this.monitorBufferTick_.bind(this),1)}monitorBufferTick_(){this.state==="READY"&&this.fillBuffer_(),this.checkBufferTimeout_&&W.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=W.setTimeout(this.monitorBufferTick_.bind(this),v5)}fillBuffer_(){if(this.sourceUpdater_.updating())return;const e=this.chooseNextRequest_();if(!e)return;const i={segmentInfo:wn({type:this.loaderType_,segment:e})};this.trigger({type:"segmentselected",metadata:i}),typeof e.timestampOffset=="number"&&(this.isPendingTimestampOffset_=!1,this.timelineChangeController_.pendingTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:e.timeline})),this.loadSegment_(e)}isEndOfStream_(e=this.mediaIndex,i=this.playlist_,r=this.partIndex){if(!i||!this.mediaSource_)return!1;const a=typeof e=="number"&&i.segments[e],o=e+1===i.segments.length,l=!a||!a.parts||r+1===a.parts.length;return i.endList&&this.mediaSource_.readyState==="open"&&o&&l}chooseNextRequest_(){const e=this.buffered_(),i=Go(e)||0,r=uu(e,this.currentTime_()),a=!this.hasPlayed_()&&r>=1,o=r>=this.goalBufferLength_(),l=this.playlist_.segments;if(!l.length||a||o)return null;this.syncPoint_=this.syncPoint_||this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_(),this.loaderType_);const u={partIndex:null,mediaIndex:null,startOfSegment:null,playlist:this.playlist_,isSyncRequest:!this.syncPoint_};if(u.isSyncRequest)u.mediaIndex=y5(this.currentTimeline_,l,i),this.logger_(`choose next request. Can not find sync point. Fallback to media Index: ${u.mediaIndex}`);else if(this.mediaIndex!==null){const E=l[this.mediaIndex],x=typeof this.partIndex=="number"?this.partIndex:-1;u.startOfSegment=E.end?E.end:i,E.parts&&E.parts[x+1]?(u.mediaIndex=this.mediaIndex,u.partIndex=x+1):u.mediaIndex=this.mediaIndex+1}else{let E,x,B;const T=this.fetchAtBuffer_?i:this.currentTime_();if(this.mediaSequenceSync_&&this.logger_(`chooseNextRequest_ request after Quality Switch:
|
|
212
|
+
For TargetTime: ${T}.
|
|
213
|
+
CurrentTime: ${this.currentTime_()}
|
|
214
|
+
BufferedEnd: ${i}
|
|
215
|
+
Fetch At Buffer: ${this.fetchAtBuffer_}
|
|
216
|
+
`,this.mediaSequenceSync_.diagnostics),this.mediaSequenceSync_&&this.mediaSequenceSync_.isReliable){const w=this.getSyncInfoFromMediaSequenceSync_(T);if(!w){const F="No sync info found while using media sequence sync";return this.error({message:F,metadata:{errorType:ne.Error.StreamingFailedToSelectNextSegment,error:new Error(F)}}),this.logger_("chooseNextRequest_ - no sync info found using media sequence sync"),null}this.logger_(`chooseNextRequest_ mediaSequence syncInfo (${w.start} --> ${w.end})`),E=w.segmentIndex,x=w.partIndex,B=w.start}else{this.logger_("chooseNextRequest_ - fallback to a regular segment selection algorithm, based on a syncPoint.");const w=ai.getMediaInfoForTime({exactManifestTimings:this.exactManifestTimings,playlist:this.playlist_,currentTime:T,startingPartIndex:this.syncPoint_.partIndex,startingSegmentIndex:this.syncPoint_.segmentIndex,startTime:this.syncPoint_.time});E=w.segmentIndex,x=w.partIndex,B=w.startTime}u.getMediaInfoForTime=this.fetchAtBuffer_?`bufferedEnd ${T}`:`currentTime ${T}`,u.mediaIndex=E,u.startOfSegment=B,u.partIndex=x,this.logger_(`choose next request. Playlist switched and we have a sync point. Media Index: ${u.mediaIndex} `)}const d=l[u.mediaIndex];let f=d&&typeof u.partIndex=="number"&&d.parts&&d.parts[u.partIndex];if(!d||typeof u.partIndex=="number"&&!f)return null;typeof u.partIndex!="number"&&d.parts&&(u.partIndex=0,f=d.parts[0]);const g=this.vhs_.playlists&&this.vhs_.playlists.main&&this.vhs_.playlists.main.independentSegments||this.playlist_.independentSegments;if(!r&&f&&!g&&!f.independent)if(u.partIndex===0){const E=l[u.mediaIndex-1],x=E.parts&&E.parts.length&&E.parts[E.parts.length-1];x&&x.independent&&(u.mediaIndex-=1,u.partIndex=E.parts.length-1,u.independent="previous segment")}else d.parts[u.partIndex-1].independent&&(u.partIndex-=1,u.independent="previous part");const y=this.mediaSource_&&this.mediaSource_.readyState==="ended";return u.mediaIndex>=l.length-1&&y&&!this.seeking_()?null:(this.shouldForceTimestampOffsetAfterResync_&&(this.shouldForceTimestampOffsetAfterResync_=!1,u.forceTimestampOffset=!0,this.logger_("choose next request. Force timestamp offset after loader resync")),this.generateSegmentInfo_(u))}getSyncInfoFromMediaSequenceSync_(e){if(!this.mediaSequenceSync_)return null;const i=Math.max(e,this.mediaSequenceSync_.start);e!==i&&this.logger_(`getSyncInfoFromMediaSequenceSync_. Pulled target time from ${e} to ${i}`);const r=this.mediaSequenceSync_.getSyncInfoForTime(i);if(!r)return null;if(!r.isAppended)return r;const a=this.mediaSequenceSync_.getSyncInfoForTime(r.end);return a?(a.isAppended&&this.logger_("getSyncInfoFromMediaSequenceSync_: We encounter unexpected scenario where next media sequence sync info is also appended!"),a):null}generateSegmentInfo_(e){const{independent:i,playlist:r,mediaIndex:a,startOfSegment:o,isSyncRequest:l,partIndex:u,forceTimestampOffset:d,getMediaInfoForTime:f}=e,g=r.segments[a],y=typeof u=="number"&&g.parts[u],E={requestId:"segment-loader-"+Math.random(),uri:y&&y.resolvedUri||g.resolvedUri,mediaIndex:a,partIndex:y?u:null,isSyncRequest:l,startOfSegment:o,playlist:r,bytes:null,encryptedBytes:null,timestampOffset:null,timeline:g.timeline,duration:y&&y.duration||g.duration,segment:g,part:y,byteLength:0,transmuxer:this.transmuxer_,getMediaInfoForTime:f,independent:i},x=typeof d<"u"?d:this.isPendingTimestampOffset_;E.timestampOffset=this.timestampOffsetForSegment_({segmentTimeline:g.timeline,currentTimeline:this.currentTimeline_,startOfSegment:o,buffered:this.buffered_(),overrideCheck:x});const B=Go(this.sourceUpdater_.audioBuffered());return typeof B=="number"&&(E.audioAppendStart=B-this.sourceUpdater_.audioTimestampOffset()),this.sourceUpdater_.videoBuffered().length&&(E.gopsToAlignWith=p5(this.gopBuffer_,this.currentTime_()-this.sourceUpdater_.videoTimestampOffset(),this.timeMapping_)),E}timestampOffsetForSegment_(e){return x5(e)}earlyAbortWhenNeeded_(e){if(this.vhs_.tech_.paused()||!this.xhrOptions_.timeout||!this.playlist_.attributes.BANDWIDTH||Date.now()-(e.firstBytesReceivedAt||Date.now())<1e3)return;const i=this.currentTime_(),r=e.bandwidth,a=this.pendingSegment_.duration,o=ai.estimateSegmentRequestTime(a,r,this.playlist_,e.bytesReceived),l=Hx(this.buffered_(),i,this.vhs_.tech_.playbackRate())-1;if(o<=l)return;const u=n5({main:this.vhs_.playlists.main,currentTime:i,bandwidth:r,duration:this.duration_(),segmentDuration:a,timeUntilRebuffer:l,currentTimeline:this.currentTimeline_,syncController:this.syncController_});if(!u)return;const f=o-l-u.rebufferingImpact;let g=.5;l<=qi&&(g=1),!(!u.playlist||u.playlist.uri===this.playlist_.uri||f<g)&&(this.bandwidth=u.playlist.attributes.BANDWIDTH*At.BANDWIDTH_VARIANCE+1,this.trigger("earlyabort"))}handleAbort_(e){this.logger_(`Aborting ${zn(e)}`),this.mediaRequestsAborted+=1}handleProgress_(e,i){this.earlyAbortWhenNeeded_(i.stats),!this.checkForAbort_(i.requestId)&&this.trigger("progress")}handleTrackInfo_(e,i){const{hasAudio:r,hasVideo:a}=i,o={segmentInfo:wn({type:this.loaderType_,segment:e}),trackInfo:{hasAudio:r,hasVideo:a}};this.trigger({type:"segmenttransmuxingtrackinfoavailable",metadata:o}),this.earlyAbortWhenNeeded_(e.stats),!this.checkForAbort_(e.requestId)&&(this.checkForIllegalMediaSwitch(i)||(i=i||{},_5(this.currentMediaInfo_,i)||(this.appendInitSegment_={audio:!0,video:!0},this.startingMediaInfo_=i,this.currentMediaInfo_=i,this.logger_("trackinfo update",i),this.trigger("trackinfo")),!this.checkForAbort_(e.requestId)&&(this.pendingSegment_.trackInfo=i,this.hasEnoughInfoToAppend_()?this.processCallQueue_():dn(this))))}handleTimingInfo_(e,i,r,a){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;const o=this.pendingSegment_,l=Yd(i);o[l]=o[l]||{},o[l][r]=a,this.logger_(`timinginfo: ${i} - ${r} - ${a}`),this.hasEnoughInfoToAppend_()?this.processCallQueue_():dn(this)}handleCaptions_(e,i){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(i.length===0){this.logger_("SegmentLoader received no captions from a caption event");return}if(!this.pendingSegment_.hasAppendedData_){this.metadataQueue_.caption.push(this.handleCaptions_.bind(this,e,i));return}const a=this.sourceUpdater_.videoTimestampOffset()===null?this.sourceUpdater_.audioTimestampOffset():this.sourceUpdater_.videoTimestampOffset(),o={};i.forEach(l=>{o[l.stream]=o[l.stream]||{startTime:1/0,captions:[],endTime:0};const u=o[l.stream];u.startTime=Math.min(u.startTime,l.startTime+a),u.endTime=Math.max(u.endTime,l.endTime+a),u.captions.push(l)}),Object.keys(o).forEach(l=>{const{startTime:u,endTime:d,captions:f}=o[l],g=this.inbandTextTracks_;this.logger_(`adding cues from ${u} -> ${d} for ${l}`),a5(g,this.vhs_.tech_,l),Yr(u,d,g[l]),o5({captionArray:f,inbandTextTracks:g,timestampOffset:a})}),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})}handleId3_(e,i,r){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(!this.pendingSegment_.hasAppendedData_){this.metadataQueue_.id3.push(this.handleId3_.bind(this,e,i,r));return}this.addMetadataToTextTrack(r,i,this.duration_())}processMetadataQueue_(){this.metadataQueue_.id3.forEach(e=>e()),this.metadataQueue_.caption.forEach(e=>e()),this.metadataQueue_.id3=[],this.metadataQueue_.caption=[]}processCallQueue_(){const e=this.callQueue_;this.callQueue_=[],e.forEach(i=>i())}processLoadQueue_(){const e=this.loadQueue_;this.loadQueue_=[],e.forEach(i=>i())}hasEnoughInfoToLoad_(){if(this.loaderType_!=="audio")return!0;const e=this.pendingSegment_;return e?this.getCurrentMediaInfo_()?!Cl({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:e.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}):!0:!1}getCurrentMediaInfo_(e=this.pendingSegment_){return e&&e.trackInfo||this.currentMediaInfo_}getMediaInfo_(e=this.pendingSegment_){return this.getCurrentMediaInfo_(e)||this.startingMediaInfo_}getPendingSegmentPlaylist(){return this.pendingSegment_?this.pendingSegment_.playlist:null}hasEnoughInfoToAppend_(){if(!this.sourceUpdater_.ready()||this.waitingOnRemove_||this.quotaExceededErrorRetryTimeout_)return!1;const e=this.pendingSegment_,i=this.getCurrentMediaInfo_();if(!e||!i)return!1;const{hasAudio:r,hasVideo:a,isMuxed:o}=i;return!(a&&!e.videoTimingInfo||r&&!this.audioDisabled_&&!o&&!e.audioTimingInfo||Cl({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:e.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}))}handleData_(e,i){if(this.earlyAbortWhenNeeded_(e.stats),this.checkForAbort_(e.requestId))return;if(this.callQueue_.length||!this.hasEnoughInfoToAppend_()){dn(this),this.callQueue_.push(this.handleData_.bind(this,e,i));return}const r=this.pendingSegment_;if(this.setTimeMapping_(r.timeline),this.updateMediaSecondsLoaded_(r.part||r.segment),this.mediaSource_.readyState!=="closed"){if(e.map&&(e.map=this.initSegmentForMap(e.map,!0),r.segment.map=e.map),e.key&&this.segmentKey(e.key,!0),r.isFmp4=e.isFmp4,r.timingInfo=r.timingInfo||{},r.isFmp4)this.trigger("fmp4"),r.timingInfo.start=r[Yd(i.type)].start;else{const a=this.getCurrentMediaInfo_(),o=this.loaderType_==="main"&&a&&a.hasVideo;let l;o&&(l=r.videoTimingInfo.start),r.timingInfo.start=this.trueSegmentStart_({currentStart:r.timingInfo.start,playlist:r.playlist,mediaIndex:r.mediaIndex,currentVideoTimestampOffset:this.sourceUpdater_.videoTimestampOffset(),useVideoTimingInfo:o,firstVideoFrameTimeForData:l,videoTimingInfo:r.videoTimingInfo,audioTimingInfo:r.audioTimingInfo})}if(this.updateAppendInitSegmentStatus(r,i.type),this.updateSourceBufferTimestampOffset_(r),r.isSyncRequest){this.updateTimingInfoEnd_(r),this.syncController_.saveSegmentTimingInfo({segmentInfo:r,shouldSaveTimelineMapping:this.loaderType_==="main"});const a=this.chooseNextRequest_();if(a.mediaIndex!==r.mediaIndex||a.partIndex!==r.partIndex){this.logger_("sync segment was incorrect, not appending");return}this.logger_("sync segment was correct, appending")}r.hasAppendedData_=!0,this.processMetadataQueue_(),this.appendData_(r,i)}}updateAppendInitSegmentStatus(e,i){this.loaderType_==="main"&&typeof e.timestampOffset=="number"&&!e.changedTimestampOffset&&(this.appendInitSegment_={audio:!0,video:!0}),this.playlistOfLastInitSegment_[i]!==e.playlist&&(this.appendInitSegment_[i]=!0)}getInitSegmentAndUpdateState_({type:e,initSegment:i,map:r,playlist:a}){if(r){const o=ba(r);if(this.activeInitSegmentId_===o)return null;i=this.initSegmentForMap(r,!0).bytes,this.activeInitSegmentId_=o}return i&&this.appendInitSegment_[e]?(this.playlistOfLastInitSegment_[e]=a,this.appendInitSegment_[e]=!1,this.activeInitSegmentId_=null,i):null}handleQuotaExceededError_({segmentInfo:e,type:i,bytes:r},a){const o=this.sourceUpdater_.audioBuffered(),l=this.sourceUpdater_.videoBuffered();o.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the audio buffer: "+An(o).join(", ")),l.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the video buffer: "+An(l).join(", "));const u=o.length?o.start(0):0,d=o.length?o.end(o.length-1):0,f=l.length?l.start(0):0,g=l.length?l.end(l.length-1):0;if(d-u<=zr&&g-f<=zr){this.logger_(`On QUOTA_EXCEEDED_ERR, single segment too large to append to buffer, triggering an error. Appended byte length: ${r.byteLength}, audio buffer: ${An(o).join(", ")}, video buffer: ${An(l).join(", ")}, `),this.error({message:"Quota exceeded error with append of a single segment of content",excludeUntil:1/0}),this.trigger("error");return}this.waitingOnRemove_=!0,this.callQueue_.push(this.appendToSourceBuffer_.bind(this,{segmentInfo:e,type:i,bytes:r}));const E=this.currentTime_()-zr;this.logger_(`On QUOTA_EXCEEDED_ERR, removing audio/video from 0 to ${E}`),this.remove(0,E,()=>{this.logger_(`On QUOTA_EXCEEDED_ERR, retrying append in ${zr}s`),this.waitingOnRemove_=!1,this.quotaExceededErrorRetryTimeout_=W.setTimeout(()=>{this.logger_("On QUOTA_EXCEEDED_ERR, re-processing call queue"),this.quotaExceededErrorRetryTimeout_=null,this.processCallQueue_()},zr*1e3)},!0)}handleAppendError_({segmentInfo:e,type:i,bytes:r},a){if(a){if(a.code===kf){this.handleQuotaExceededError_({segmentInfo:e,type:i,bytes:r});return}this.logger_("Received non QUOTA_EXCEEDED_ERR on append",a),this.error({message:`${i} append of ${r.length}b failed for segment #${e.mediaIndex} in playlist ${e.playlist.id}`,metadata:{errorType:ne.Error.StreamingFailedToAppendSegment}}),this.trigger("appenderror")}}appendToSourceBuffer_({segmentInfo:e,type:i,initSegment:r,data:a,bytes:o}){if(!o){const u=[a];let d=a.byteLength;r&&(u.unshift(r),d+=r.byteLength),o=s5({bytes:d,segments:u})}const l={segmentInfo:wn({type:this.loaderType_,segment:e})};this.trigger({type:"segmentappendstart",metadata:l}),this.sourceUpdater_.appendBuffer({segmentInfo:e,type:i,bytes:o},this.handleAppendError_.bind(this,{segmentInfo:e,type:i,bytes:o}))}handleSegmentTimingInfo_(e,i,r){if(!this.pendingSegment_||i!==this.pendingSegment_.requestId)return;const a=this.pendingSegment_.segment,o=`${e}TimingInfo`;a[o]||(a[o]={}),a[o].transmuxerPrependedSeconds=r.prependedContentDuration||0,a[o].transmuxedPresentationStart=r.start.presentation,a[o].transmuxedDecodeStart=r.start.decode,a[o].transmuxedPresentationEnd=r.end.presentation,a[o].transmuxedDecodeEnd=r.end.decode,a[o].baseMediaDecodeTime=r.baseMediaDecodeTime}appendData_(e,i){const{type:r,data:a}=i;if(!a||!a.byteLength||r==="audio"&&this.audioDisabled_)return;const o=this.getInitSegmentAndUpdateState_({type:r,initSegment:i.initSegment,playlist:e.playlist,map:e.isFmp4?e.segment.map:null});this.appendToSourceBuffer_({segmentInfo:e,type:r,initSegment:o,data:a})}loadSegment_(e){if(this.state="WAITING",this.pendingSegment_=e,this.trimBackBuffer_(e),typeof e.timestampOffset=="number"&&this.transmuxer_&&this.transmuxer_.postMessage({action:"clearAllMp4Captions"}),!this.hasEnoughInfoToLoad_()){dn(this),this.loadQueue_.push(()=>{const i=bt({},e,{forceTimestampOffset:!0});bt(e,this.generateSegmentInfo_(i)),this.isPendingTimestampOffset_=!1,this.updateTransmuxerAndRequestSegment_(e)});return}this.updateTransmuxerAndRequestSegment_(e)}updateTransmuxerAndRequestSegment_(e){this.shouldUpdateTransmuxerTimestampOffset_(e.timestampOffset)&&(this.gopBuffer_.length=0,e.gopsToAlignWith=[],this.timeMapping_=0,this.transmuxer_.postMessage({action:"reset"}),this.transmuxer_.postMessage({action:"setTimestampOffset",timestampOffset:e.timestampOffset}));const i=this.createSimplifiedSegmentObj_(e),r=this.isEndOfStream_(e.mediaIndex,e.playlist,e.partIndex),a=this.mediaIndex!==null,o=e.timeline!==this.currentTimeline_&&e.timeline>0,l=r||a&&o;this.logger_(`Requesting
|
|
217
|
+
${Qf(e.uri)}
|
|
218
|
+
${zn(e)}`),i.map&&!i.map.bytes&&(this.logger_("going to request init segment."),this.appendInitSegment_={video:!0,audio:!0}),e.abortRequests=e5({xhr:this.vhs_.xhr,xhrOptions:this.xhrOptions_,decryptionWorker:this.decrypter_,segment:i,abortFn:this.handleAbort_.bind(this,e),progressFn:this.handleProgress_.bind(this),trackInfoFn:this.handleTrackInfo_.bind(this),timingInfoFn:this.handleTimingInfo_.bind(this),videoSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"video",e.requestId),audioSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"audio",e.requestId),captionsFn:this.handleCaptions_.bind(this),isEndOfTimeline:l,endedTimelineFn:()=>{this.logger_("received endedtimeline callback")},id3Fn:this.handleId3_.bind(this),dataFn:this.handleData_.bind(this),doneFn:this.segmentRequestFinished_.bind(this),onTransmuxerLog:({message:u,level:d,stream:f})=>{this.logger_(`${zn(e)} logged from transmuxer stream ${f} as a ${d}: ${u}`)},triggerSegmentEventFn:({type:u,segment:d,keyInfo:f,trackInfo:g,timingInfo:y})=>{const x={segmentInfo:wn({segment:d})};f&&(x.keyInfo=f),g&&(x.trackInfo=g),y&&(x.timingInfo=y),this.trigger({type:u,metadata:x})}})}trimBackBuffer_(e){const i=b5(this.seekable_(),this.currentTime_(),this.playlist_.targetDuration||10);i>0&&this.remove(0,i)}createSimplifiedSegmentObj_(e){const i=e.segment,r=e.part,a=e.segment.key||e.segment.map&&e.segment.map.key,o=e.segment.map&&!e.segment.map.bytes,l={resolvedUri:r?r.resolvedUri:i.resolvedUri,byterange:r?r.byterange:i.byterange,requestId:e.requestId,transmuxer:e.transmuxer,audioAppendStart:e.audioAppendStart,gopsToAlignWith:e.gopsToAlignWith,part:e.part,type:this.loaderType_,start:e.startOfSegment,duration:e.duration,isEncrypted:a,isMediaInitialization:o},u=e.playlist.segments[e.mediaIndex-1];if(u&&u.timeline===i.timeline&&(u.videoTimingInfo?l.baseStartTime=u.videoTimingInfo.transmuxedDecodeEnd:u.audioTimingInfo&&(l.baseStartTime=u.audioTimingInfo.transmuxedDecodeEnd)),i.key){const d=i.key.iv||new Uint32Array([0,0,0,e.mediaIndex+e.playlist.mediaSequence]);l.key=this.segmentKey(i.key),l.key.iv=d}return i.map&&(l.map=this.initSegmentForMap(i.map)),l}saveTransferStats_(e){this.mediaRequests+=1,e&&(this.mediaBytesTransferred+=e.bytesReceived,this.mediaTransferDuration+=e.roundTripTime)}saveBandwidthRelatedStats_(e,i){if(this.pendingSegment_.byteLength=i.bytesReceived,e<zs){this.logger_(`Ignoring segment's bandwidth because its duration of ${e} is less than the min to record ${zs}`);return}const r={bandwidthInfo:{from:this.bandwidth,to:i.bandwidth}};this.trigger({type:"bandwidthupdated",metadata:r}),this.bandwidth=i.bandwidth,this.roundTrip=i.roundTripTime}handleTimeout_(){this.mediaRequestsTimedout+=1,this.bandwidth=1,this.roundTrip=NaN,this.trigger("bandwidthupdate"),this.trigger("timeout")}segmentRequestFinished_(e,i,r){if(this.callQueue_.length){this.callQueue_.push(this.segmentRequestFinished_.bind(this,e,i,r));return}if(this.saveTransferStats_(i.stats),!this.pendingSegment_||i.requestId!==this.pendingSegment_.requestId)return;if(e){if(this.pendingSegment_=null,this.state="READY",e.code===Hi.ABORTED)return;if(this.pause(),e.code===Hi.TIMEOUT){this.handleTimeout_();return}this.mediaRequestsErrored+=1,this.error(e),this.trigger("error");return}const a=this.pendingSegment_;this.saveBandwidthRelatedStats_(a.duration,i.stats),a.endOfAllRequests=i.endOfAllRequests,r.gopInfo&&(this.gopBuffer_=m5(this.gopBuffer_,r.gopInfo,this.safeAppend_)),this.state="APPENDING",this.trigger("appending"),this.waitForAppendsToComplete_(a)}setTimeMapping_(e){const i=this.syncController_.mappingForTimeline(e);i!==null&&(this.timeMapping_=i)}updateMediaSecondsLoaded_(e){typeof e.start=="number"&&typeof e.end=="number"?this.mediaSecondsLoaded+=e.end-e.start:this.mediaSecondsLoaded+=e.duration}shouldUpdateTransmuxerTimestampOffset_(e){return e===null?!1:this.loaderType_==="main"&&e!==this.sourceUpdater_.videoTimestampOffset()||!this.audioDisabled_&&e!==this.sourceUpdater_.audioTimestampOffset()}trueSegmentStart_({currentStart:e,playlist:i,mediaIndex:r,firstVideoFrameTimeForData:a,currentVideoTimestampOffset:o,useVideoTimingInfo:l,videoTimingInfo:u,audioTimingInfo:d}){if(typeof e<"u")return e;if(!l)return d.start;const f=i.segments[r-1];return r===0||!f||typeof f.start>"u"||f.end!==a+o?a:u.start}waitForAppendsToComplete_(e){const i=this.getCurrentMediaInfo_(e);if(!i){this.error({message:"No starting media returned, likely due to an unsupported media format.",playlistExclusionDuration:1/0}),this.trigger("error");return}const{hasAudio:r,hasVideo:a,isMuxed:o}=i,l=this.loaderType_==="main"&&a,u=!this.audioDisabled_&&r&&!o;if(e.waitingOnAppends=0,!e.hasAppendedData_){!e.timingInfo&&typeof e.timestampOffset=="number"&&(this.isPendingTimestampOffset_=!0),e.timingInfo={start:0},e.waitingOnAppends++,this.isPendingTimestampOffset_||(this.updateSourceBufferTimestampOffset_(e),this.processMetadataQueue_()),this.checkAppendsDone_(e);return}l&&e.waitingOnAppends++,u&&e.waitingOnAppends++,l&&this.sourceUpdater_.videoQueueCallback(this.checkAppendsDone_.bind(this,e)),u&&this.sourceUpdater_.audioQueueCallback(this.checkAppendsDone_.bind(this,e))}checkAppendsDone_(e){this.checkForAbort_(e.requestId)||(e.waitingOnAppends--,e.waitingOnAppends===0&&this.handleAppendsDone_())}checkForIllegalMediaSwitch(e){const i=T5(this.loaderType_,this.getCurrentMediaInfo_(),e);return i?(this.error({message:i,playlistExclusionDuration:1/0}),this.trigger("error"),!0):!1}updateSourceBufferTimestampOffset_(e){if(e.timestampOffset===null||typeof e.timingInfo.start!="number"||e.changedTimestampOffset||this.loaderType_!=="main")return;let i=!1;e.timestampOffset-=this.getSegmentStartTimeForTimestampOffsetCalculation_({videoTimingInfo:e.segment.videoTimingInfo,audioTimingInfo:e.segment.audioTimingInfo,timingInfo:e.timingInfo}),e.changedTimestampOffset=!0,e.timestampOffset!==this.sourceUpdater_.videoTimestampOffset()&&(this.sourceUpdater_.videoTimestampOffset(e.timestampOffset),i=!0),e.timestampOffset!==this.sourceUpdater_.audioTimestampOffset()&&(this.sourceUpdater_.audioTimestampOffset(e.timestampOffset),i=!0),i&&this.trigger("timestampoffset")}getSegmentStartTimeForTimestampOffsetCalculation_({videoTimingInfo:e,audioTimingInfo:i,timingInfo:r}){return this.useDtsForTimestampOffset_?e&&typeof e.transmuxedDecodeStart=="number"?e.transmuxedDecodeStart:i&&typeof i.transmuxedDecodeStart=="number"?i.transmuxedDecodeStart:r.start:r.start}updateTimingInfoEnd_(e){e.timingInfo=e.timingInfo||{};const i=this.getMediaInfo_(),a=this.loaderType_==="main"&&i&&i.hasVideo&&e.videoTimingInfo?e.videoTimingInfo:e.audioTimingInfo;a&&(e.timingInfo.end=typeof a.end=="number"?a.end:a.start+e.duration)}handleAppendsDone_(){if(this.pendingSegment_){const d={segmentInfo:wn({type:this.loaderType_,segment:this.pendingSegment_})};this.trigger({type:"appendsdone",metadata:d})}if(!this.pendingSegment_){this.state="READY",this.paused()||this.monitorBuffer_();return}const e=this.pendingSegment_;e.part&&e.part.syncInfo?e.part.syncInfo.markAppended():e.segment.syncInfo&&e.segment.syncInfo.markAppended(),this.updateTimingInfoEnd_(e),this.shouldSaveSegmentTimingInfo_&&this.syncController_.saveSegmentTimingInfo({segmentInfo:e,shouldSaveTimelineMapping:this.loaderType_==="main"});const i=k5(e,this.sourceType_);if(i&&(i.severity==="warn"?ne.log.warn(i.message):this.logger_(i.message)),this.recordThroughput_(e),this.pendingSegment_=null,this.state="READY",e.isSyncRequest&&(this.trigger("syncinfoupdate"),!e.hasAppendedData_)){this.logger_(`Throwing away un-appended sync request ${zn(e)}`);return}this.logger_(`Appended ${zn(e)}`),this.addSegmentMetadataCue_(e),this.fetchAtBuffer_=!0,this.currentTimeline_!==e.timeline&&(this.timelineChangeController_.lastTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:e.timeline}),this.loaderType_==="main"&&!this.audioDisabled_&&this.timelineChangeController_.lastTimelineChange({type:"audio",from:this.currentTimeline_,to:e.timeline})),this.currentTimeline_=e.timeline,this.trigger("syncinfoupdate");const r=e.segment,a=e.part,o=r.end&&this.currentTime_()-r.end>e.playlist.targetDuration*3,l=a&&a.end&&this.currentTime_()-a.end>e.playlist.partTargetDuration*3;if(o||l){this.logger_(`bad ${o?"segment":"part"} ${zn(e)}`),this.resetEverything();return}this.mediaIndex!==null&&this.trigger("bandwidthupdate"),this.trigger("progress"),this.mediaIndex=e.mediaIndex,this.partIndex=e.partIndex,this.isEndOfStream_(e.mediaIndex,e.playlist,e.partIndex)&&this.endOfStream(),this.trigger("appended"),e.hasAppendedData_&&this.mediaAppends++,this.paused()||this.monitorBuffer_()}recordThroughput_(e){if(e.duration<zs){this.logger_(`Ignoring segment's throughput because its duration of ${e.duration} is less than the min to record ${zs}`);return}const i=this.throughput.rate,r=Date.now()-e.endOfAllRequests+1,a=Math.floor(e.byteLength/r*8*1e3);this.throughput.rate+=(a-i)/++this.throughput.count}addSegmentMetadataCue_(e){if(!this.segmentMetadataTrack_)return;const i=e.segment,r=i.start,a=i.end;if(!Wd(r)||!Wd(a))return;Yr(r,a,this.segmentMetadataTrack_);const o=W.WebKitDataCue||W.VTTCue,l={custom:i.custom,dateTimeObject:i.dateTimeObject,dateTimeString:i.dateTimeString,programDateTime:i.programDateTime,bandwidth:e.playlist.attributes.BANDWIDTH,resolution:e.playlist.attributes.RESOLUTION,codecs:e.playlist.attributes.CODECS,byteLength:e.byteLength,uri:e.uri,timeline:e.timeline,playlist:e.playlist.id,start:r,end:a},u=JSON.stringify(l),d=new o(r,a,u);d.value=l,this.segmentMetadataTrack_.addCue(d)}}function tn(){}const Zf=function(s){return typeof s!="string"?s:s.replace(/./,e=>e.toUpperCase())},w5=["video","audio"],El=(s,e)=>{const i=e[`${s}Buffer`];return i&&i.updating||e.queuePending[s]},D5=(s,e)=>{for(let i=0;i<e.length;i++){const r=e[i];if(r.type==="mediaSource")return null;if(r.type===s)return i}return null},rr=(s,e)=>{if(e.queue.length===0)return;let i=0,r=e.queue[i];if(r.type==="mediaSource"){!e.updating()&&e.mediaSource.readyState!=="closed"&&(e.queue.shift(),r.action(e),r.doneFn&&r.doneFn(),rr("audio",e),rr("video",e));return}if(s!=="mediaSource"&&!(!e.ready()||e.mediaSource.readyState==="closed"||El(s,e))){if(r.type!==s){if(i=D5(s,e.queue),i===null)return;r=e.queue[i]}if(e.queue.splice(i,1),e.queuePending[s]=r,r.action(s,e),!r.doneFn){e.queuePending[s]=null,rr(s,e);return}}},Jf=(s,e)=>{const i=e[`${s}Buffer`],r=Zf(s);i&&(i.removeEventListener("updateend",e[`on${r}UpdateEnd_`]),i.removeEventListener("error",e[`on${r}Error_`]),e.codecs[s]=null,e[`${s}Buffer`]=null)},$i=(s,e)=>s&&e&&Array.prototype.indexOf.call(s.sourceBuffers,e)!==-1,ci={appendBuffer:(s,e,i)=>(r,a)=>{const o=a[`${r}Buffer`];if($i(a.mediaSource,o)){a.logger_(`Appending segment ${e.mediaIndex}'s ${s.length} bytes to ${r}Buffer`);try{o.appendBuffer(s)}catch(l){a.logger_(`Error with code ${l.code} `+(l.code===kf?"(QUOTA_EXCEEDED_ERR) ":"")+`when appending segment ${e.mediaIndex} to ${r}Buffer`),a.queuePending[r]=null,i(l)}}},remove:(s,e)=>(i,r)=>{const a=r[`${i}Buffer`];if($i(r.mediaSource,a)){r.logger_(`Removing ${s} to ${e} from ${i}Buffer`);try{a.remove(s,e)}catch{r.logger_(`Remove ${s} to ${e} from ${i}Buffer failed`)}}},timestampOffset:s=>(e,i)=>{const r=i[`${e}Buffer`];$i(i.mediaSource,r)&&(i.logger_(`Setting ${e}timestampOffset to ${s}`),r.timestampOffset=s)},callback:s=>(e,i)=>{s()},endOfStream:s=>e=>{if(e.mediaSource.readyState==="open"){e.logger_(`Calling mediaSource endOfStream(${s||""})`);try{e.mediaSource.endOfStream(s)}catch(i){ne.log.warn("Failed to call media source endOfStream",i)}}},duration:s=>e=>{e.logger_(`Setting mediaSource duration to ${s}`);try{e.mediaSource.duration=s}catch(i){ne.log.warn("Failed to set media source duration",i)}},abort:()=>(s,e)=>{if(e.mediaSource.readyState!=="open")return;const i=e[`${s}Buffer`];if($i(e.mediaSource,i)){e.logger_(`calling abort on ${s}Buffer`);try{i.abort()}catch(r){ne.log.warn(`Failed to abort on ${s}Buffer`,r)}}},addSourceBuffer:(s,e)=>i=>{const r=Zf(s),a=sr(e);i.logger_(`Adding ${s}Buffer with codec ${e} to mediaSource`);const o=i.mediaSource.addSourceBuffer(a);o.addEventListener("updateend",i[`on${r}UpdateEnd_`]),o.addEventListener("error",i[`on${r}Error_`]),i.codecs[s]=e,i[`${s}Buffer`]=o},removeSourceBuffer:s=>e=>{const i=e[`${s}Buffer`];if(Jf(s,e),!!$i(e.mediaSource,i)){e.logger_(`Removing ${s}Buffer with codec ${e.codecs[s]} from mediaSource`);try{e.mediaSource.removeSourceBuffer(i)}catch(r){ne.log.warn(`Failed to removeSourceBuffer ${s}Buffer`,r)}}},changeType:s=>(e,i)=>{const r=i[`${e}Buffer`],a=sr(s);if(!$i(i.mediaSource,r))return;const o=s.substring(0,s.indexOf(".")),l=i.codecs[e];if(l.substring(0,l.indexOf("."))===o)return;const d={codecsChangeInfo:{from:l,to:s}};i.trigger({type:"codecschange",metadata:d}),i.logger_(`changing ${e}Buffer codec from ${l} to ${s}`);try{r.changeType(a),i.codecs[e]=s}catch(f){d.errorType=ne.Error.StreamingCodecsChangeError,d.error=f,f.metadata=d,i.error_=f,i.trigger("error"),ne.log.warn(`Failed to changeType on ${e}Buffer`,f)}}},di=({type:s,sourceUpdater:e,action:i,doneFn:r,name:a})=>{e.queue.push({type:s,action:i,doneFn:r,name:a}),rr(s,e)},Kd=(s,e)=>i=>{const r=e[`${s}Buffered`](),a=Ux(r);if(e.logger_(`received "updateend" event for ${s} Source Buffer: `,a),e.queuePending[s]){const o=e.queuePending[s].doneFn;e.queuePending[s]=null,o&&o(e[`${s}Error_`])}rr(s,e)};class ep extends ne.EventTarget{constructor(e){super(),this.mediaSource=e,this.sourceopenListener_=()=>rr("mediaSource",this),this.mediaSource.addEventListener("sourceopen",this.sourceopenListener_),this.logger_=bi("SourceUpdater"),this.audioTimestampOffset_=0,this.videoTimestampOffset_=0,this.queue=[],this.queuePending={audio:null,video:null},this.delayedAudioAppendQueue_=[],this.videoAppendQueued_=!1,this.codecs={},this.onVideoUpdateEnd_=Kd("video",this),this.onAudioUpdateEnd_=Kd("audio",this),this.onVideoError_=i=>{this.videoError_=i},this.onAudioError_=i=>{this.audioError_=i},this.createdSourceBuffers_=!1,this.initializedEme_=!1,this.triggeredReady_=!1}initializedEme(){this.initializedEme_=!0,this.triggerReady()}hasCreatedSourceBuffers(){return this.createdSourceBuffers_}hasInitializedAnyEme(){return this.initializedEme_}ready(){return this.hasCreatedSourceBuffers()&&this.hasInitializedAnyEme()}createSourceBuffers(e){this.hasCreatedSourceBuffers()||(this.addOrChangeSourceBuffers(e),this.createdSourceBuffers_=!0,this.trigger("createdsourcebuffers"),this.triggerReady())}triggerReady(){this.ready()&&!this.triggeredReady_&&(this.triggeredReady_=!0,this.trigger("ready"))}addSourceBuffer(e,i){di({type:"mediaSource",sourceUpdater:this,action:ci.addSourceBuffer(e,i),name:"addSourceBuffer"})}abort(e){di({type:e,sourceUpdater:this,action:ci.abort(e),name:"abort"})}removeSourceBuffer(e){if(!this.canRemoveSourceBuffer()){ne.log.error("removeSourceBuffer is not supported!");return}di({type:"mediaSource",sourceUpdater:this,action:ci.removeSourceBuffer(e),name:"removeSourceBuffer"})}canRemoveSourceBuffer(){return!ne.browser.IS_FIREFOX&&W.MediaSource&&W.MediaSource.prototype&&typeof W.MediaSource.prototype.removeSourceBuffer=="function"}static canChangeType(){return W.SourceBuffer&&W.SourceBuffer.prototype&&typeof W.SourceBuffer.prototype.changeType=="function"}canChangeType(){return this.constructor.canChangeType()}changeType(e,i){if(!this.canChangeType()){ne.log.error("changeType is not supported!");return}di({type:e,sourceUpdater:this,action:ci.changeType(i),name:"changeType"})}addOrChangeSourceBuffers(e){if(!e||typeof e!="object"||Object.keys(e).length===0)throw new Error("Cannot addOrChangeSourceBuffers to undefined codecs");Object.keys(e).forEach(i=>{const r=e[i];if(!this.hasCreatedSourceBuffers())return this.addSourceBuffer(i,r);this.canChangeType()&&this.changeType(i,r)})}appendBuffer(e,i){const{segmentInfo:r,type:a,bytes:o}=e;if(this.processedAppend_=!0,a==="audio"&&this.videoBuffer&&!this.videoAppendQueued_){this.delayedAudioAppendQueue_.push([e,i]),this.logger_(`delayed audio append of ${o.length} until video append`);return}const l=i;if(di({type:a,sourceUpdater:this,action:ci.appendBuffer(o,r||{mediaIndex:-1},l),doneFn:i,name:"appendBuffer"}),a==="video"){if(this.videoAppendQueued_=!0,!this.delayedAudioAppendQueue_.length)return;const u=this.delayedAudioAppendQueue_.slice();this.logger_(`queuing delayed audio ${u.length} appendBuffers`),this.delayedAudioAppendQueue_.length=0,u.forEach(d=>{this.appendBuffer.apply(this,d)})}}audioBuffered(){return $i(this.mediaSource,this.audioBuffer)&&this.audioBuffer.buffered?this.audioBuffer.buffered:Nt()}videoBuffered(){return $i(this.mediaSource,this.videoBuffer)&&this.videoBuffer.buffered?this.videoBuffer.buffered:Nt()}buffered(){const e=$i(this.mediaSource,this.videoBuffer)?this.videoBuffer:null,i=$i(this.mediaSource,this.audioBuffer)?this.audioBuffer:null;return i&&!e?this.audioBuffered():e&&!i?this.videoBuffered():jx(this.audioBuffered(),this.videoBuffered())}setDuration(e,i=tn){di({type:"mediaSource",sourceUpdater:this,action:ci.duration(e),name:"duration",doneFn:i})}endOfStream(e=null,i=tn){typeof e!="string"&&(e=void 0),di({type:"mediaSource",sourceUpdater:this,action:ci.endOfStream(e),name:"endOfStream",doneFn:i})}removeAudio(e,i,r=tn){if(!this.audioBuffered().length||this.audioBuffered().end(0)===0){r();return}di({type:"audio",sourceUpdater:this,action:ci.remove(e,i),doneFn:r,name:"remove"})}removeVideo(e,i,r=tn){if(!this.videoBuffered().length||this.videoBuffered().end(0)===0){r();return}di({type:"video",sourceUpdater:this,action:ci.remove(e,i),doneFn:r,name:"remove"})}updating(){return!!(El("audio",this)||El("video",this))}audioTimestampOffset(e){return typeof e<"u"&&this.audioBuffer&&this.audioTimestampOffset_!==e&&(di({type:"audio",sourceUpdater:this,action:ci.timestampOffset(e),name:"timestampOffset"}),this.audioTimestampOffset_=e),this.audioTimestampOffset_}videoTimestampOffset(e){return typeof e<"u"&&this.videoBuffer&&this.videoTimestampOffset_!==e&&(di({type:"video",sourceUpdater:this,action:ci.timestampOffset(e),name:"timestampOffset"}),this.videoTimestampOffset_=e),this.videoTimestampOffset_}audioQueueCallback(e){this.audioBuffer&&di({type:"audio",sourceUpdater:this,action:ci.callback(e),name:"callback"})}videoQueueCallback(e){this.videoBuffer&&di({type:"video",sourceUpdater:this,action:ci.callback(e),name:"callback"})}dispose(){this.trigger("dispose"),w5.forEach(e=>{this.abort(e),this.canRemoveSourceBuffer()?this.removeSourceBuffer(e):this[`${e}QueueCallback`](()=>Jf(e,this))}),this.videoAppendQueued_=!1,this.delayedAudioAppendQueue_.length=0,this.sourceopenListener_&&this.mediaSource.removeEventListener("sourceopen",this.sourceopenListener_),this.off()}}const Qd=s=>decodeURIComponent(escape(String.fromCharCode.apply(null,s))),A5=s=>{const e=new Uint8Array(s);return Array.from(e).map(i=>i.toString(16).padStart(2,"0")).join("")},Zd=new Uint8Array(`
|
|
219
|
+
|
|
220
|
+
`.split("").map(s=>s.charCodeAt(0)));class I5 extends Error{constructor(){super("Trying to parse received VTT cues, but there is no WebVTT. Make sure vtt.js is loaded.")}}class N5 extends Sl{constructor(e,i={}){super(e,i),this.mediaSource_=null,this.subtitlesTrack_=null,this.featuresNativeTextTracks_=e.featuresNativeTextTracks,this.loadVttJs=e.loadVttJs,this.shouldSaveSegmentTimingInfo_=!1}buffered_(){if(!this.subtitlesTrack_||!this.subtitlesTrack_.cues||!this.subtitlesTrack_.cues.length)return Nt();const e=this.subtitlesTrack_.cues,i=e[0].startTime,r=e[e.length-1].startTime;return Nt([[i,r]])}initSegmentForMap(e,i=!1){if(!e)return null;const r=ba(e);let a=this.initSegments_[r];if(i&&!a&&e.bytes){const o=Zd.byteLength+e.bytes.byteLength,l=new Uint8Array(o);l.set(e.bytes),l.set(Zd,e.bytes.byteLength),this.initSegments_[r]=a={resolvedUri:e.resolvedUri,byterange:e.byterange,bytes:l}}return a||e}couldBeginLoading_(){return this.playlist_&&this.subtitlesTrack_&&!this.paused()}init_(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()}track(e){return typeof e>"u"?this.subtitlesTrack_:(this.subtitlesTrack_=e,this.state==="INIT"&&this.couldBeginLoading_()&&this.init_(),this.subtitlesTrack_)}remove(e,i){Yr(e,i,this.subtitlesTrack_)}fillBuffer_(){const e=this.chooseNextRequest_();if(e){if(this.syncController_.timestampOffsetForTimeline(e.timeline)===null){const i=()=>{this.state="READY",this.paused()||this.monitorBuffer_()};this.syncController_.one("timestampoffset",i),this.state="WAITING_ON_TIMELINE";return}this.loadSegment_(e)}}timestampOffsetForSegment_(){return null}chooseNextRequest_(){return this.skipEmptySegments_(super.chooseNextRequest_())}skipEmptySegments_(e){for(;e&&e.segment.empty;){if(e.mediaIndex+1>=e.playlist.segments.length){e=null;break}e=this.generateSegmentInfo_({playlist:e.playlist,mediaIndex:e.mediaIndex+1,startOfSegment:e.startOfSegment+e.duration,isSyncRequest:e.isSyncRequest})}return e}stopForError(e){this.error(e),this.state="READY",this.pause(),this.trigger("error")}segmentRequestFinished_(e,i,r){if(!this.subtitlesTrack_){this.state="READY";return}if(this.saveTransferStats_(i.stats),!this.pendingSegment_){this.state="READY",this.mediaRequestsAborted+=1;return}if(e){e.code===Hi.TIMEOUT&&this.handleTimeout_(),e.code===Hi.ABORTED?this.mediaRequestsAborted+=1:this.mediaRequestsErrored+=1,this.stopForError(e);return}const a=this.pendingSegment_,o=r.mp4VttCues&&r.mp4VttCues.length;o&&(a.mp4VttCues=r.mp4VttCues),this.saveBandwidthRelatedStats_(a.duration,i.stats),i.key&&this.segmentKey(i.key,!0),this.state="APPENDING",this.trigger("appending");const l=a.segment;if(l.map&&(l.map.bytes=i.map.bytes),a.bytes=i.bytes,typeof W.WebVTT!="function"&&typeof this.loadVttJs=="function"){this.state="WAITING_ON_VTTJS",this.loadVttJs().then(()=>this.segmentRequestFinished_(e,i,r),()=>this.stopForError({message:"Error loading vtt.js"}));return}l.requested=!0;try{this.parseVTTCues_(a)}catch(u){this.stopForError({message:u.message,metadata:{errorType:ne.Error.StreamingVttParserError,error:u}});return}if(o||this.updateTimeMapping_(a,this.syncController_.timelines[a.timeline],this.playlist_),a.cues.length?a.timingInfo={start:a.cues[0].startTime,end:a.cues[a.cues.length-1].endTime}:a.timingInfo={start:a.startOfSegment,end:a.startOfSegment+a.duration},a.isSyncRequest){this.trigger("syncinfoupdate"),this.pendingSegment_=null,this.state="READY";return}a.byteLength=a.bytes.byteLength,this.mediaSecondsLoaded+=l.duration,a.cues.forEach(u=>{this.subtitlesTrack_.addCue(this.featuresNativeTextTracks_?new W.VTTCue(u.startTime,u.endTime,u.text):u)}),f5(this.subtitlesTrack_),this.handleAppendsDone_()}handleData_(e,i){const r=e&&e.type==="vtt",a=i&&i.type==="text";r&&a&&super.handleData_(e,i)}updateTimingInfoEnd_(){}parseMp4VttCues_(e){const i=this.sourceUpdater_.videoTimestampOffset()===null?this.sourceUpdater_.audioTimestampOffset():this.sourceUpdater_.videoTimestampOffset();e.mp4VttCues.forEach(r=>{const a=r.start+i,o=r.end+i,l=new W.VTTCue(a,o,r.cueText);r.settings&&r.settings.split(" ").forEach(u=>{const d=u.split(":"),f=d[0],g=d[1];l[f]=isNaN(g)?g:Number(g)}),e.cues.push(l)})}parseVTTCues_(e){let i,r=!1;if(typeof W.WebVTT!="function")throw new I5;if(e.cues=[],e.timestampmap={MPEGTS:0,LOCAL:0},e.mp4VttCues){this.parseMp4VttCues_(e);return}typeof W.TextDecoder=="function"?i=new W.TextDecoder("utf8"):(i=W.WebVTT.StringDecoder(),r=!0);const a=new W.WebVTT.Parser(W,W.vttjs,i);if(a.oncue=e.cues.push.bind(e.cues),a.ontimestampmap=l=>{e.timestampmap=l},a.onparsingerror=l=>{ne.log.warn("Error encountered when parsing cues: "+l.message)},e.segment.map){let l=e.segment.map.bytes;r&&(l=Qd(l)),a.parse(l)}let o=e.bytes;r&&(o=Qd(o)),a.parse(o),a.flush()}updateTimeMapping_(e,i,r){const a=e.segment;if(!i)return;if(!e.cues.length){a.empty=!0;return}const{MPEGTS:o,LOCAL:l}=e.timestampmap,d=o/Dn.ONE_SECOND_IN_TS-l+i.mapping;if(e.cues.forEach(f=>{const g=f.endTime-f.startTime,y=this.handleRollover_(f.startTime+d,i.time);f.startTime=Math.max(y,0),f.endTime=Math.max(y+g,0)}),!r.syncInfo){const f=e.cues[0].startTime,g=e.cues[e.cues.length-1].startTime;r.syncInfo={mediaSequence:r.mediaSequence+e.mediaIndex,time:Math.min(f,g-a.duration)}}}handleRollover_(e,i){if(i===null)return e;let r=e*Dn.ONE_SECOND_IN_TS;const a=i*Dn.ONE_SECOND_IN_TS;let o;for(a<r?o=-8589934592:o=8589934592;Math.abs(r-a)>4294967296;)r+=o;return r/Dn.ONE_SECOND_IN_TS}}const O5=function(s,e){const i=s.cues;for(let r=0;r<i.length;r++){const a=i[r];if(e>=a.adStartTime&&e<=a.adEndTime)return a}return null},B5=function(s,e,i=0){if(!s.segments)return;let r=i,a;for(let o=0;o<s.segments.length;o++){const l=s.segments[o];if(a||(a=O5(e,r+l.duration/2)),a){if("cueIn"in l){a.endTime=r,a.adEndTime=r,r+=l.duration,a=null;continue}if(r<a.endTime){r+=l.duration;continue}a.endTime+=l.duration}else if("cueOut"in l&&(a=new W.VTTCue(r,r+l.duration,l.cueOut),a.adStartTime=r,a.adEndTime=r+parseFloat(l.cueOut),e.addCue(a)),"cueOutCont"in l){const[u,d]=l.cueOutCont.split("/").map(parseFloat);a=new W.VTTCue(r,r+l.duration,""),a.adStartTime=r-u,a.adEndTime=a.adStartTime+d,e.addCue(a)}r+=l.duration}};class Jd{constructor({start:e,end:i,segmentIndex:r,partIndex:a=null,appended:o=!1}){this.start_=e,this.end_=i,this.segmentIndex_=r,this.partIndex_=a,this.appended_=o}isInRange(e){return e>=this.start&&e<this.end}markAppended(){this.appended_=!0}resetAppendedStatus(){this.appended_=!1}get isAppended(){return this.appended_}get start(){return this.start_}get end(){return this.end_}get segmentIndex(){return this.segmentIndex_}get partIndex(){return this.partIndex_}}class L5{constructor(e,i=[]){this.segmentSyncInfo_=e,this.partsSyncInfo_=i}get segmentSyncInfo(){return this.segmentSyncInfo_}get partsSyncInfo(){return this.partsSyncInfo_}get hasPartsSyncInfo(){return this.partsSyncInfo_.length>0}resetAppendStatus(){this.segmentSyncInfo_.resetAppendedStatus(),this.partsSyncInfo_.forEach(e=>e.resetAppendedStatus())}}class tp{constructor(){this.storage_=new Map,this.diagnostics_="",this.isReliable_=!1,this.start_=-1/0,this.end_=1/0}get start(){return this.start_}get end(){return this.end_}get diagnostics(){return this.diagnostics_}get isReliable(){return this.isReliable_}resetAppendedStatus(){this.storage_.forEach(e=>e.resetAppendStatus())}update(e,i){const{mediaSequence:r,segments:a}=e;if(this.isReliable_=this.isReliablePlaylist_(r,a),!!this.isReliable_)return this.updateStorage_(a,r,this.calculateBaseTime_(r,a,i))}getSyncInfoForTime(e){for(const{segmentSyncInfo:i,partsSyncInfo:r}of this.storage_.values())if(r.length){for(const a of r)if(a.isInRange(e))return a}else if(i.isInRange(e))return i;return null}getSyncInfoForMediaSequence(e){return this.storage_.get(e)}updateStorage_(e,i,r){const a=new Map;let o=`
|
|
221
|
+
`,l=r,u=i;this.start_=l,e.forEach((d,f)=>{const g=this.storage_.get(u),y=l,E=y+d.duration,x=!!(g&&g.segmentSyncInfo&&g.segmentSyncInfo.isAppended),B=new Jd({start:y,end:E,appended:x,segmentIndex:f});d.syncInfo=B;let T=l;const w=(d.parts||[]).map((F,P)=>{const I=T,K=T+F.duration,q=!!(g&&g.partsSyncInfo&&g.partsSyncInfo[P]&&g.partsSyncInfo[P].isAppended),M=new Jd({start:I,end:K,appended:q,segmentIndex:f,partIndex:P});return T=K,o+=`Media Sequence: ${u}.${P} | Range: ${I} --> ${K} | Appended: ${q}
|
|
222
|
+
`,F.syncInfo=M,M});a.set(u,new L5(B,w)),o+=`${Qf(d.resolvedUri)} | Media Sequence: ${u} | Range: ${y} --> ${E} | Appended: ${x}
|
|
223
|
+
`,u++,l=E}),this.end_=l,this.storage_=a,this.diagnostics_=o}calculateBaseTime_(e,i,r){if(!this.storage_.size)return 0;if(this.storage_.has(e))return this.storage_.get(e).segmentSyncInfo.start;const a=Math.min(...this.storage_.keys());if(e<a){const o=a-e;let l=this.storage_.get(a).segmentSyncInfo.start;for(let u=0;u<o;u++){const d=i[u];l-=d.duration}return l}return r}isReliablePlaylist_(e,i){return e!=null&&Array.isArray(i)&&i.length}}class eh extends tp{constructor(e){super(),this.parent_=e}calculateBaseTime_(e,i,r){if(!this.storage_.size){const a=this.parent_.getSyncInfoForMediaSequence(e);return a?a.segmentSyncInfo.start:0}return super.calculateBaseTime_(e,i,r)}}const P5=86400,Xo=[{name:"VOD",run:(s,e,i,r,a)=>i!==1/0?{time:0,segmentIndex:0,partIndex:null}:null},{name:"MediaSequence",run:(s,e,i,r,a,o)=>{const l=s.getMediaSequenceSync(o);if(!l||!l.isReliable)return null;const u=l.getSyncInfoForTime(a);return u?{time:u.start,partIndex:u.partIndex,segmentIndex:u.segmentIndex}:null}},{name:"ProgramDateTime",run:(s,e,i,r,a)=>{if(!Object.keys(s.timelineToDatetimeMappings).length)return null;let o=null,l=null;const u=ml(e);a=a||0;for(let d=0;d<u.length;d++){const f=e.endList||a===0?d:u.length-(d+1),g=u[f],y=g.segment,E=s.timelineToDatetimeMappings[y.timeline];if(!E||!y.dateTimeObject)continue;let B=y.dateTimeObject.getTime()/1e3+E;if(y.parts&&typeof g.partIndex=="number")for(let w=0;w<g.partIndex;w++)B+=y.parts[w].duration;const T=Math.abs(a-B);if(l!==null&&(T===0||l<T))break;l=T,o={time:B,segmentIndex:g.segmentIndex,partIndex:g.partIndex}}return o}},{name:"Segment",run:(s,e,i,r,a)=>{let o=null,l=null;a=a||0;const u=ml(e);for(let d=0;d<u.length;d++){const f=e.endList||a===0?d:u.length-(d+1),g=u[f],y=g.segment,E=g.part&&g.part.start||y&&y.start;if(y.timeline===r&&typeof E<"u"){const x=Math.abs(a-E);if(l!==null&&l<x)break;(!o||l===null||l>=x)&&(l=x,o={time:E,segmentIndex:g.segmentIndex,partIndex:g.partIndex})}}return o}},{name:"Discontinuity",run:(s,e,i,r,a)=>{let o=null;if(a=a||0,e.discontinuityStarts&&e.discontinuityStarts.length){let l=null;for(let u=0;u<e.discontinuityStarts.length;u++){const d=e.discontinuityStarts[u],f=e.discontinuitySequence+u+1,g=s.discontinuities[f];if(g){const y=Math.abs(a-g.time);if(l!==null&&l<y)break;(!o||l===null||l>=y)&&(l=y,o={time:g.time,segmentIndex:d,partIndex:null})}}}return o}},{name:"Playlist",run:(s,e,i,r,a)=>e.syncInfo?{time:e.syncInfo.time,segmentIndex:e.syncInfo.mediaSequence-e.mediaSequence,partIndex:null}:null}];class M5 extends ne.EventTarget{constructor(e={}){super(),this.timelines=[],this.discontinuities=[],this.timelineToDatetimeMappings={};const i=new tp,r=new eh(i),a=new eh(i);this.mediaSequenceStorage_={main:i,audio:r,vtt:a},this.logger_=bi("SyncController")}getMediaSequenceSync(e){return this.mediaSequenceStorage_[e]||null}getSyncPoint(e,i,r,a,o){if(i!==1/0)return Xo.find(({name:d})=>d==="VOD").run(this,e,i);const l=this.runStrategies_(e,i,r,a,o);if(!l.length)return null;for(const u of l){const{syncPoint:d,strategy:f}=u,{segmentIndex:g,time:y}=d;if(g<0)continue;const E=e.segments[g],x=y,B=x+E.duration;if(this.logger_(`Strategy: ${f}. Current time: ${a}. selected segment: ${g}. Time: [${x} -> ${B}]}`),a>=x&&a<B)return this.logger_("Found sync point with exact match: ",d),d}return this.selectSyncPoint_(l,{key:"time",value:a})}getExpiredTime(e,i){if(!e||!e.segments)return null;const r=this.runStrategies_(e,i,e.discontinuitySequence,0);if(!r.length)return null;const a=this.selectSyncPoint_(r,{key:"segmentIndex",value:0});return a.segmentIndex>0&&(a.time*=-1),Math.abs(a.time+es({defaultDuration:e.targetDuration,durationList:e.segments,startIndex:a.segmentIndex,endIndex:0}))}runStrategies_(e,i,r,a,o){const l=[];for(let u=0;u<Xo.length;u++){const d=Xo[u],f=d.run(this,e,i,r,a,o);f&&(f.strategy=d.name,l.push({strategy:d.name,syncPoint:f}))}return l}selectSyncPoint_(e,i){let r=e[0].syncPoint,a=Math.abs(e[0].syncPoint[i.key]-i.value),o=e[0].strategy;for(let l=1;l<e.length;l++){const u=Math.abs(e[l].syncPoint[i.key]-i.value);u<a&&(a=u,r=e[l].syncPoint,o=e[l].strategy)}return this.logger_(`syncPoint for [${i.key}: ${i.value}] chosen with strategy [${o}]: [time:${r.time}, segmentIndex:${r.segmentIndex}`+(typeof r.partIndex=="number"?`,partIndex:${r.partIndex}`:"")+"]"),r}saveExpiredSegmentInfo(e,i){const r=i.mediaSequence-e.mediaSequence;if(r>P5){ne.log.warn(`Not saving expired segment info. Media sequence gap ${r} is too large.`);return}for(let a=r-1;a>=0;a--){const o=e.segments[a];if(o&&typeof o.start<"u"){i.syncInfo={mediaSequence:e.mediaSequence+a,time:o.start},this.logger_(`playlist refresh sync: [time:${i.syncInfo.time}, mediaSequence: ${i.syncInfo.mediaSequence}]`),this.trigger("syncinfoupdate");break}}}setDateTimeMappingForStart(e){if(this.timelineToDatetimeMappings={},e.segments&&e.segments.length&&e.segments[0].dateTimeObject){const i=e.segments[0],r=i.dateTimeObject.getTime()/1e3;this.timelineToDatetimeMappings[i.timeline]=-r}}saveSegmentTimingInfo({segmentInfo:e,shouldSaveTimelineMapping:i}){const r=this.calculateSegmentTimeMapping_(e,e.timingInfo,i),a=e.segment;r&&(this.saveDiscontinuitySyncInfo_(e),e.playlist.syncInfo||(e.playlist.syncInfo={mediaSequence:e.playlist.mediaSequence+e.mediaIndex,time:a.start}));const o=a.dateTimeObject;a.discontinuity&&i&&o&&(this.timelineToDatetimeMappings[a.timeline]=-(o.getTime()/1e3))}timestampOffsetForTimeline(e){return typeof this.timelines[e]>"u"?null:this.timelines[e].time}mappingForTimeline(e){return typeof this.timelines[e]>"u"?null:this.timelines[e].mapping}calculateSegmentTimeMapping_(e,i,r){const a=e.segment,o=e.part;let l=this.timelines[e.timeline],u,d;if(typeof e.timestampOffset=="number")l={time:e.startOfSegment,mapping:e.startOfSegment-i.start},r&&(this.timelines[e.timeline]=l,this.trigger("timestampoffset"),this.logger_(`time mapping for timeline ${e.timeline}: [time: ${l.time}] [mapping: ${l.mapping}]`)),u=e.startOfSegment,d=i.end+l.mapping;else if(l)u=i.start+l.mapping,d=i.end+l.mapping;else return!1;return o&&(o.start=u,o.end=d),(!a.start||u<a.start)&&(a.start=u),a.end=d,!0}saveDiscontinuitySyncInfo_(e){const i=e.playlist,r=e.segment;if(r.discontinuity)this.discontinuities[r.timeline]={time:r.start,accuracy:0};else if(i.discontinuityStarts&&i.discontinuityStarts.length)for(let a=0;a<i.discontinuityStarts.length;a++){const o=i.discontinuityStarts[a],l=i.discontinuitySequence+a+1,u=o-e.mediaIndex,d=Math.abs(u);if(!this.discontinuities[l]||this.discontinuities[l].accuracy>d){let f;u<0?f=r.start-es({defaultDuration:i.targetDuration,durationList:i.segments,startIndex:e.mediaIndex,endIndex:o}):f=r.end+es({defaultDuration:i.targetDuration,durationList:i.segments,startIndex:e.mediaIndex+1,endIndex:o}),this.discontinuities[l]={time:f,accuracy:d}}}}dispose(){this.trigger("dispose"),this.off()}}class R5 extends ne.EventTarget{constructor(){super(),this.pendingTimelineChanges_={},this.lastTimelineChanges_={}}clearPendingTimelineChange(e){this.pendingTimelineChanges_[e]=null,this.trigger("pendingtimelinechange")}pendingTimelineChange({type:e,from:i,to:r}){return typeof i=="number"&&typeof r=="number"&&(this.pendingTimelineChanges_[e]={type:e,from:i,to:r},this.trigger("pendingtimelinechange")),this.pendingTimelineChanges_[e]}lastTimelineChange({type:e,from:i,to:r}){if(typeof i=="number"&&typeof r=="number"){this.lastTimelineChanges_[e]={type:e,from:i,to:r},delete this.pendingTimelineChanges_[e];const a={timelineChangeInfo:{from:i,to:r}};this.trigger({type:"timelinechange",metadata:a})}return this.lastTimelineChanges_[e]}dispose(){this.trigger("dispose"),this.pendingTimelineChanges_={},this.lastTimelineChanges_={},this.off()}}const V5=$f(Uf(function(){var s=(function(){function T(){this.listeners={}}var w=T.prototype;return w.on=function(P,I){this.listeners[P]||(this.listeners[P]=[]),this.listeners[P].push(I)},w.off=function(P,I){if(!this.listeners[P])return!1;var K=this.listeners[P].indexOf(I);return this.listeners[P]=this.listeners[P].slice(0),this.listeners[P].splice(K,1),K>-1},w.trigger=function(P){var I=this.listeners[P];if(I)if(arguments.length===2)for(var K=I.length,q=0;q<K;++q)I[q].call(this,arguments[1]);else for(var M=Array.prototype.slice.call(arguments,1),N=I.length,J=0;J<N;++J)I[J].apply(this,M)},w.dispose=function(){this.listeners={}},w.pipe=function(P){this.on("data",function(I){P.push(I)})},T})();/*! @name pkcs7 @version 1.0.4 @license Apache-2.0 */function e(T){return T.subarray(0,T.byteLength-T[T.byteLength-1])}/*! @name aes-decrypter @version 4.0.2 @license Apache-2.0 */const i=function(){const T=[[[],[],[],[],[]],[[],[],[],[],[]]],w=T[0],F=T[1],P=w[4],I=F[4];let K,q,M;const N=[],J=[];let b,C,U,j,k,A;for(K=0;K<256;K++)J[(N[K]=K<<1^(K>>7)*283)^K]=K;for(q=M=0;!P[q];q^=b||1,M=J[M]||1)for(j=M^M<<1^M<<2^M<<3^M<<4,j=j>>8^j&255^99,P[q]=j,I[j]=q,U=N[C=N[b=N[q]]],A=U*16843009^C*65537^b*257^q*16843008,k=N[j]*257^j*16843008,K=0;K<4;K++)w[K][q]=k=k<<24^k>>>8,F[K][j]=A=A<<24^A>>>8;for(K=0;K<5;K++)w[K]=w[K].slice(0),F[K]=F[K].slice(0);return T};let r=null;class a{constructor(w){r||(r=i()),this._tables=[[r[0][0].slice(),r[0][1].slice(),r[0][2].slice(),r[0][3].slice(),r[0][4].slice()],[r[1][0].slice(),r[1][1].slice(),r[1][2].slice(),r[1][3].slice(),r[1][4].slice()]];let F,P,I;const K=this._tables[0][4],q=this._tables[1],M=w.length;let N=1;if(M!==4&&M!==6&&M!==8)throw new Error("Invalid aes key size");const J=w.slice(0),b=[];for(this._key=[J,b],F=M;F<4*M+28;F++)I=J[F-1],(F%M===0||M===8&&F%M===4)&&(I=K[I>>>24]<<24^K[I>>16&255]<<16^K[I>>8&255]<<8^K[I&255],F%M===0&&(I=I<<8^I>>>24^N<<24,N=N<<1^(N>>7)*283)),J[F]=J[F-M]^I;for(P=0;F;P++,F--)I=J[P&3?F:F-4],F<=4||P<4?b[P]=I:b[P]=q[0][K[I>>>24]]^q[1][K[I>>16&255]]^q[2][K[I>>8&255]]^q[3][K[I&255]]}decrypt(w,F,P,I,K,q){const M=this._key[1];let N=w^M[0],J=I^M[1],b=P^M[2],C=F^M[3],U,j,k;const A=M.length/4-2;let $,Q=4;const H=this._tables[1],V=H[0],G=H[1],Z=H[2],te=H[3],se=H[4];for($=0;$<A;$++)U=V[N>>>24]^G[J>>16&255]^Z[b>>8&255]^te[C&255]^M[Q],j=V[J>>>24]^G[b>>16&255]^Z[C>>8&255]^te[N&255]^M[Q+1],k=V[b>>>24]^G[C>>16&255]^Z[N>>8&255]^te[J&255]^M[Q+2],C=V[C>>>24]^G[N>>16&255]^Z[J>>8&255]^te[b&255]^M[Q+3],Q+=4,N=U,J=j,b=k;for($=0;$<4;$++)K[(3&-$)+q]=se[N>>>24]<<24^se[J>>16&255]<<16^se[b>>8&255]<<8^se[C&255]^M[Q++],U=N,N=J,J=b,b=C,C=U}}class o extends s{constructor(){super(s),this.jobs=[],this.delay=1,this.timeout_=null}processJob_(){this.jobs.shift()(),this.jobs.length?this.timeout_=setTimeout(this.processJob_.bind(this),this.delay):this.timeout_=null}push(w){this.jobs.push(w),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))}}const l=function(T){return T<<24|(T&65280)<<8|(T&16711680)>>8|T>>>24},u=function(T,w,F){const P=new Int32Array(T.buffer,T.byteOffset,T.byteLength>>2),I=new a(Array.prototype.slice.call(w)),K=new Uint8Array(T.byteLength),q=new Int32Array(K.buffer);let M,N,J,b,C,U,j,k,A;for(M=F[0],N=F[1],J=F[2],b=F[3],A=0;A<P.length;A+=4)C=l(P[A]),U=l(P[A+1]),j=l(P[A+2]),k=l(P[A+3]),I.decrypt(C,U,j,k,q,A),q[A]=l(q[A]^M),q[A+1]=l(q[A+1]^N),q[A+2]=l(q[A+2]^J),q[A+3]=l(q[A+3]^b),M=C,N=U,J=j,b=k;return K};class d{constructor(w,F,P,I){const K=d.STEP,q=new Int32Array(w.buffer),M=new Uint8Array(w.byteLength);let N=0;for(this.asyncStream_=new o,this.asyncStream_.push(this.decryptChunk_(q.subarray(N,N+K),F,P,M)),N=K;N<q.length;N+=K)P=new Uint32Array([l(q[N-4]),l(q[N-3]),l(q[N-2]),l(q[N-1])]),this.asyncStream_.push(this.decryptChunk_(q.subarray(N,N+K),F,P,M));this.asyncStream_.push(function(){I(null,e(M))})}static get STEP(){return 32e3}decryptChunk_(w,F,P,I){return function(){const K=u(w,F,P);I.set(K,w.byteOffset)}}}var f=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},g;typeof window<"u"?g=window:typeof f<"u"?g=f:typeof self<"u"?g=self:g={};var y=g,E=function(w){return ArrayBuffer.isView==="function"?ArrayBuffer.isView(w):w&&w.buffer instanceof ArrayBuffer},x=y.BigInt||Number;x("0x1"),x("0x100"),x("0x10000"),x("0x1000000"),x("0x100000000"),x("0x10000000000"),x("0x1000000000000"),x("0x100000000000000"),x("0x10000000000000000"),(function(){var T=new Uint16Array([65484]),w=new Uint8Array(T.buffer,T.byteOffset,T.byteLength);return w[0]===255?"big":w[0]===204?"little":"unknown"})();const B=function(T){const w={};return Object.keys(T).forEach(F=>{const P=T[F];E(P)?w[F]={bytes:P.buffer,byteOffset:P.byteOffset,byteLength:P.byteLength}:w[F]=P}),w};self.onmessage=function(T){const w=T.data,F=new Uint8Array(w.encrypted.bytes,w.encrypted.byteOffset,w.encrypted.byteLength),P=new Uint32Array(w.key.bytes,w.key.byteOffset,w.key.byteLength/4),I=new Uint32Array(w.iv.bytes,w.iv.byteOffset,w.iv.byteLength/4);new d(F,P,I,function(K,q){self.postMessage(B({source:w.source,decrypted:q}),[q.buffer])})}}));var F5=Ff(V5);const $5=s=>{let e=s.default?"main":"alternative";return s.characteristics&&s.characteristics.indexOf("public.accessibility.describes-video")>=0&&(e="main-desc"),e},ip=(s,e)=>{s.abort(),s.pause(),e&&e.activePlaylistLoader&&(e.activePlaylistLoader.pause(),e.activePlaylistLoader=null)},kl=(s,e)=>{e.activePlaylistLoader=s,s.load()},U5=(s,e)=>()=>{const{segmentLoaders:{[s]:i,main:r},mediaTypes:{[s]:a}}=e,o=a.activeTrack(),l=a.getActiveGroup(),u=a.activePlaylistLoader,d=a.lastGroup_;if(!(l&&d&&l.id===d.id)&&(a.lastGroup_=l,a.lastTrack_=o,ip(i,a),!(!l||l.isMainPlaylist))){if(!l.playlistLoader){u&&r.resetEverything();return}i.resyncLoader(),kl(l.playlistLoader,a)}},q5=(s,e)=>()=>{const{segmentLoaders:{[s]:i},mediaTypes:{[s]:r}}=e;r.lastGroup_=null,i.abort(),i.pause()},j5=(s,e)=>()=>{const{mainPlaylistLoader:i,segmentLoaders:{[s]:r,main:a},mediaTypes:{[s]:o}}=e,l=o.activeTrack(),u=o.getActiveGroup(),d=o.activePlaylistLoader,f=o.lastTrack_;if(!(f&&l&&f.id===l.id)&&(o.lastGroup_=u,o.lastTrack_=l,ip(r,o),!!u)){if(u.isMainPlaylist){if(!l||!f||l.id===f.id)return;const g=e.vhs.playlistController_,y=g.selectPlaylist();if(g.media()===y)return;o.logger_(`track change. Switching main audio from ${f.id} to ${l.id}`),i.pause(),a.resetEverything(),g.fastQualityChange_(y);return}if(s==="AUDIO"){if(!u.playlistLoader){a.setAudio(!0),a.resetEverything();return}r.setAudio(!0),a.setAudio(!1)}if(d===u.playlistLoader){kl(u.playlistLoader,o);return}r.track&&r.track(l),r.resetEverything(),kl(u.playlistLoader,o)}},xa={AUDIO:(s,e)=>()=>{const{mediaTypes:{[s]:i},excludePlaylist:r}=e,a=i.activeTrack(),o=i.activeGroup(),l=(o.filter(d=>d.default)[0]||o[0]).id,u=i.tracks[l];if(a===u){r({error:{message:"Problem encountered loading the default audio track."}});return}ne.log.warn("Problem encountered loading the alternate audio track.Switching back to default.");for(const d in i.tracks)i.tracks[d].enabled=i.tracks[d]===u;i.onTrackChanged()},SUBTITLES:(s,e)=>()=>{const{mediaTypes:{[s]:i}}=e;ne.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track.");const r=i.activeTrack();r&&(r.mode="disabled"),i.onTrackChanged()}},th={AUDIO:(s,e,i)=>{if(!e)return;const{tech:r,requestOptions:a,segmentLoaders:{[s]:o}}=i;e.on("loadedmetadata",()=>{const l=e.media();o.playlist(l,a),(!r.paused()||l.endList&&r.preload()!=="none")&&o.load()}),e.on("loadedplaylist",()=>{o.playlist(e.media(),a),r.paused()||o.load()}),e.on("error",xa[s](s,i))},SUBTITLES:(s,e,i)=>{const{tech:r,requestOptions:a,segmentLoaders:{[s]:o},mediaTypes:{[s]:l}}=i;e.on("loadedmetadata",()=>{const u=e.media();o.playlist(u,a),o.track(l.activeTrack()),(!r.paused()||u.endList&&r.preload()!=="none")&&o.load()}),e.on("loadedplaylist",()=>{o.playlist(e.media(),a),r.paused()||o.load()}),e.on("error",xa[s](s,i))}},H5={AUDIO:(s,e)=>{const{vhs:i,sourceType:r,segmentLoaders:{[s]:a},requestOptions:o,main:{mediaGroups:l},mediaTypes:{[s]:{groups:u,tracks:d,logger_:f}},mainPlaylistLoader:g}=e,y=hs(g.main);(!l[s]||Object.keys(l[s]).length===0)&&(l[s]={main:{default:{default:!0}}},y&&(l[s].main.default.playlists=g.main.playlists));for(const E in l[s]){u[E]||(u[E]=[]);for(const x in l[s][E]){let B=l[s][E][x],T;if(y?(f(`AUDIO group '${E}' label '${x}' is a main playlist`),B.isMainPlaylist=!0,T=null):r==="vhs-json"&&B.playlists?T=new Yn(B.playlists[0],i,o):B.resolvedUri?T=new Yn(B.resolvedUri,i,o):B.playlists&&r==="dash"?T=new bl(B.playlists[0],i,o,g):T=null,B=it({id:x,playlistLoader:T},B),th[s](s,B.playlistLoader,e),u[E].push(B),typeof d[x]>"u"){const w=new ne.AudioTrack({id:x,kind:$5(B),enabled:!1,language:B.language,default:B.default,label:x});d[x]=w}}}a.on("error",xa[s](s,e))},SUBTITLES:(s,e)=>{const{tech:i,vhs:r,sourceType:a,segmentLoaders:{[s]:o},requestOptions:l,main:{mediaGroups:u},mediaTypes:{[s]:{groups:d,tracks:f}},mainPlaylistLoader:g}=e;for(const y in u[s]){d[y]||(d[y]=[]);for(const E in u[s][y]){if(!r.options_.useForcedSubtitles&&u[s][y][E].forced)continue;let x=u[s][y][E],B;if(a==="hls")B=new Yn(x.resolvedUri,r,l);else if(a==="dash"){if(!x.playlists.filter(w=>w.excludeUntil!==1/0).length)return;B=new bl(x.playlists[0],r,l,g)}else a==="vhs-json"&&(B=new Yn(x.playlists?x.playlists[0]:x.resolvedUri,r,l));if(x=it({id:E,playlistLoader:B},x),th[s](s,x.playlistLoader,e),d[y].push(x),typeof f[E]>"u"){const T=i.addRemoteTextTrack({id:E,kind:"subtitles",default:x.default&&x.autoselect,language:x.language,label:E},!1).track;f[E]=T}}}o.on("error",xa[s](s,e))},"CLOSED-CAPTIONS":(s,e)=>{const{tech:i,main:{mediaGroups:r},mediaTypes:{[s]:{groups:a,tracks:o}}}=e;for(const l in r[s]){a[l]||(a[l]=[]);for(const u in r[s][l]){const d=r[s][l][u];if(!/^(?:CC|SERVICE)/.test(d.instreamId))continue;const f=i.options_.vhs&&i.options_.vhs.captionServices||{};let g={label:u,language:d.language,instreamId:d.instreamId,default:d.default&&d.autoselect};if(f[g.instreamId]&&(g=it(g,f[g.instreamId])),g.default===void 0&&delete g.default,a[l].push(it({id:u},d)),typeof o[u]>"u"){const y=i.addRemoteTextTrack({id:g.instreamId,kind:"captions",default:g.default,language:g.language,label:g.label},!1).track;o[u]=y}}}}},np=(s,e)=>{for(let i=0;i<s.length;i++)if(hu(e,s[i])||s[i].playlists&&np(s[i].playlists,e))return!0;return!1},z5=(s,e)=>i=>{const{mainPlaylistLoader:r,mediaTypes:{[s]:{groups:a}}}=e,o=r.media();if(!o)return null;let l=null;o.attributes[s]&&(l=a[o.attributes[s]]);const u=Object.keys(a);if(!l)if(s==="AUDIO"&&u.length>1&&hs(e.main))for(let d=0;d<u.length;d++){const f=a[u[d]];if(np(f,o)){l=f;break}}else a.main?l=a.main:u.length===1&&(l=a[u[0]]);return typeof i>"u"?l:i===null||!l?null:l.filter(d=>d.id===i.id)[0]||null},G5={AUDIO:(s,e)=>()=>{const{mediaTypes:{[s]:{tracks:i}}}=e;for(const r in i)if(i[r].enabled)return i[r];return null},SUBTITLES:(s,e)=>()=>{const{mediaTypes:{[s]:{tracks:i}}}=e;for(const r in i)if(i[r].mode==="showing"||i[r].mode==="hidden")return i[r];return null}},W5=(s,{mediaTypes:e})=>()=>{const i=e[s].activeTrack();return i?e[s].activeGroup(i):null},Y5=s=>{["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(f=>{H5[f](f,s)});const{mediaTypes:e,mainPlaylistLoader:i,tech:r,vhs:a,segmentLoaders:{["AUDIO"]:o,main:l}}=s;["AUDIO","SUBTITLES"].forEach(f=>{e[f].activeGroup=z5(f,s),e[f].activeTrack=G5[f](f,s),e[f].onGroupChanged=U5(f,s),e[f].onGroupChanging=q5(f,s),e[f].onTrackChanged=j5(f,s),e[f].getActiveGroup=W5(f,s)});const u=e.AUDIO.activeGroup();if(u){const f=(u.filter(y=>y.default)[0]||u[0]).id;e.AUDIO.tracks[f].enabled=!0,e.AUDIO.onGroupChanged(),e.AUDIO.onTrackChanged(),e.AUDIO.getActiveGroup().playlistLoader?(l.setAudio(!1),o.setAudio(!0)):l.setAudio(!0)}i.on("mediachange",()=>{["AUDIO","SUBTITLES"].forEach(f=>e[f].onGroupChanged())}),i.on("mediachanging",()=>{["AUDIO","SUBTITLES"].forEach(f=>e[f].onGroupChanging())});const d=()=>{e.AUDIO.onTrackChanged(),r.trigger({type:"usage",name:"vhs-audio-change"})};r.audioTracks().addEventListener("change",d),r.remoteTextTracks().addEventListener("change",e.SUBTITLES.onTrackChanged),a.on("dispose",()=>{r.audioTracks().removeEventListener("change",d),r.remoteTextTracks().removeEventListener("change",e.SUBTITLES.onTrackChanged)}),r.clearTracks("audio");for(const f in e.AUDIO.tracks)r.audioTracks().addTrack(e.AUDIO.tracks[f])},X5=()=>{const s={};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(e=>{s[e]={groups:{},tracks:{},activePlaylistLoader:null,activeGroup:tn,activeTrack:tn,getActiveGroup:tn,onGroupChanged:tn,onTrackChanged:tn,lastTrack_:null,logger_:bi(`MediaGroups[${e}]`)}}),s};class ih{constructor(){this.priority_=[],this.pathwayClones_=new Map}set version(e){e===1&&(this.version_=e)}set ttl(e){this.ttl_=e||300}set reloadUri(e){e&&(this.reloadUri_=si(this.reloadUri_,e))}set priority(e){e&&e.length&&(this.priority_=e)}set pathwayClones(e){e&&e.length&&(this.pathwayClones_=new Map(e.map(i=>[i.ID,i])))}get version(){return this.version_}get ttl(){return this.ttl_}get reloadUri(){return this.reloadUri_}get priority(){return this.priority_}get pathwayClones(){return this.pathwayClones_}}class K5 extends ne.EventTarget{constructor(e,i){super(),this.currentPathway=null,this.defaultPathway=null,this.queryBeforeStart=!1,this.availablePathways_=new Set,this.steeringManifest=new ih,this.proxyServerUrl_=null,this.manifestType_=null,this.ttlTimeout_=null,this.request_=null,this.currentPathwayClones=new Map,this.nextPathwayClones=new Map,this.excludedSteeringManifestURLs=new Set,this.logger_=bi("Content Steering"),this.xhr_=e,this.getBandwidth_=i}assignTagProperties(e,i){this.manifestType_=i.serverUri?"HLS":"DASH";const r=i.serverUri||i.serverURL;if(!r){this.logger_(`steering manifest URL is ${r}, cannot request steering manifest.`),this.trigger("error");return}if(r.startsWith("data:")){this.decodeDataUriManifest_(r.substring(r.indexOf(",")+1));return}this.steeringManifest.reloadUri=si(e,r),this.defaultPathway=i.pathwayId||i.defaultServiceLocation,this.queryBeforeStart=i.queryBeforeStart,this.proxyServerUrl_=i.proxyServerURL,this.defaultPathway&&!this.queryBeforeStart&&this.trigger("content-steering")}requestSteeringManifest(e){const i=this.steeringManifest.reloadUri;if(!i)return;const r=e?i:this.getRequestURI(i);if(!r){this.logger_("No valid content steering manifest URIs. Stopping content steering."),this.trigger("error"),this.dispose();return}const a={contentSteeringInfo:{uri:r}};this.trigger({type:"contentsteeringloadstart",metadata:a}),this.request_=this.xhr_({uri:r,requestType:"content-steering-manifest"},(o,l)=>{if(o){if(l.status===410){this.logger_(`manifest request 410 ${o}.`),this.logger_(`There will be no more content steering requests to ${r} this session.`),this.excludedSteeringManifestURLs.add(r);return}if(l.status===429){const f=l.responseHeaders["retry-after"];this.logger_(`manifest request 429 ${o}.`),this.logger_(`content steering will retry in ${f} seconds.`),this.startTTLTimeout_(parseInt(f,10));return}this.logger_(`manifest failed to load ${o}.`),this.startTTLTimeout_();return}this.trigger({type:"contentsteeringloadcomplete",metadata:a});let u;try{u=JSON.parse(this.request_.responseText)}catch(f){const g={errorType:ne.Error.StreamingContentSteeringParserError,error:f};this.trigger({type:"error",metadata:g})}this.assignSteeringProperties_(u);const d={contentSteeringInfo:a.contentSteeringInfo,contentSteeringManifest:{version:this.steeringManifest.version,reloadUri:this.steeringManifest.reloadUri,priority:this.steeringManifest.priority}};this.trigger({type:"contentsteeringparsed",metadata:d}),this.startTTLTimeout_()})}setProxyServerUrl_(e){const i=new W.URL(e),r=new W.URL(this.proxyServerUrl_);return r.searchParams.set("url",encodeURI(i.toString())),this.setSteeringParams_(r.toString())}decodeDataUriManifest_(e){const i=JSON.parse(W.atob(e));this.assignSteeringProperties_(i)}setSteeringParams_(e){const i=new W.URL(e),r=this.getPathway(),a=this.getBandwidth_();if(r){const o=`_${this.manifestType_}_pathway`;i.searchParams.set(o,r)}if(a){const o=`_${this.manifestType_}_throughput`;i.searchParams.set(o,a)}return i.toString()}assignSteeringProperties_(e){if(this.steeringManifest.version=e.VERSION,!this.steeringManifest.version){this.logger_(`manifest version is ${e.VERSION}, which is not supported.`),this.trigger("error");return}this.steeringManifest.ttl=e.TTL,this.steeringManifest.reloadUri=e["RELOAD-URI"],this.steeringManifest.priority=e["PATHWAY-PRIORITY"]||e["SERVICE-LOCATION-PRIORITY"],this.steeringManifest.pathwayClones=e["PATHWAY-CLONES"],this.nextPathwayClones=this.steeringManifest.pathwayClones,this.availablePathways_.size||(this.logger_("There are no available pathways for content steering. Ending content steering."),this.trigger("error"),this.dispose());const r=(a=>{for(const o of a)if(this.availablePathways_.has(o))return o;return[...this.availablePathways_][0]})(this.steeringManifest.priority);this.currentPathway!==r&&(this.currentPathway=r,this.trigger("content-steering"))}getPathway(){return this.currentPathway||this.defaultPathway}getRequestURI(e){if(!e)return null;const i=a=>this.excludedSteeringManifestURLs.has(a);if(this.proxyServerUrl_){const a=this.setProxyServerUrl_(e);if(!i(a))return a}const r=this.setSteeringParams_(e);return i(r)?null:r}startTTLTimeout_(e=this.steeringManifest.ttl){const i=e*1e3;this.ttlTimeout_=W.setTimeout(()=>{this.requestSteeringManifest()},i)}clearTTLTimeout_(){W.clearTimeout(this.ttlTimeout_),this.ttlTimeout_=null}abort(){this.request_&&this.request_.abort(),this.request_=null}dispose(){this.off("content-steering"),this.off("error"),this.abort(),this.clearTTLTimeout_(),this.currentPathway=null,this.defaultPathway=null,this.queryBeforeStart=null,this.proxyServerUrl_=null,this.manifestType_=null,this.ttlTimeout_=null,this.request_=null,this.excludedSteeringManifestURLs=new Set,this.availablePathways_=new Set,this.steeringManifest=new ih}addAvailablePathway(e){e&&this.availablePathways_.add(e)}clearAvailablePathways(){this.availablePathways_.clear()}excludePathway(e){return this.availablePathways_.delete(e)}didDASHTagChange(e,i){return!i&&this.steeringManifest.reloadUri||i&&(si(e,i.serverURL)!==this.steeringManifest.reloadUri||i.defaultServiceLocation!==this.defaultPathway||i.queryBeforeStart!==this.queryBeforeStart||i.proxyServerURL!==this.proxyServerUrl_)}getAvailablePathways(){return this.availablePathways_}}const Q5=(s,e)=>{let i=null;return(...r)=>{clearTimeout(i),i=setTimeout(()=>{s.apply(null,r)},e)}},Z5=10;let Zi;const J5=["mediaRequests","mediaRequestsAborted","mediaRequestsTimedout","mediaRequestsErrored","mediaTransferDuration","mediaBytesTransferred","mediaAppends"],eS=function(s){return this.audioSegmentLoader_[s]+this.mainSegmentLoader_[s]},tS=function({currentPlaylist:s,buffered:e,currentTime:i,nextPlaylist:r,bufferLowWaterLine:a,bufferHighWaterLine:o,duration:l,bufferBasedABR:u,log:d}){if(!r)return ne.log.warn("We received no playlist to switch to. Please check your stream."),!1;const f=`allowing switch ${s&&s.id||"null"} -> ${r.id}`;if(!s)return d(`${f} as current playlist is not set`),!0;if(r.id===s.id)return!1;const g=!!Wn(e,i).length;if(!s.endList)return!g&&typeof s.partTargetDuration=="number"?(d(`not ${f} as current playlist is live llhls, but currentTime isn't in buffered.`),!1):(d(`${f} as current playlist is live`),!0);const y=uu(e,i),E=u?At.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:At.MAX_BUFFER_LOW_WATER_LINE;if(l<E)return d(`${f} as duration < max low water line (${l} < ${E})`),!0;const x=r.attributes.BANDWIDTH,B=s.attributes.BANDWIDTH;if(x<B&&(!u||y<o)){let T=`${f} as next bandwidth < current bandwidth (${x} < ${B})`;return u&&(T+=` and forwardBuffer < bufferHighWaterLine (${y} < ${o})`),d(T),!0}if((!u||x>B)&&y>=a){let T=`${f} as forwardBuffer >= bufferLowWaterLine (${y} >= ${a})`;return u&&(T+=` and next bandwidth > current bandwidth (${x} > ${B})`),d(T),!0}return d(`not ${f} as no switching criteria met`),!1};class iS extends ne.EventTarget{constructor(e){super(),this.fastQualityChange_=Q5(this.fastQualityChange_.bind(this),100);const{src:i,withCredentials:r,tech:a,bandwidth:o,externVhs:l,useCueTags:u,playlistExclusionDuration:d,enableLowInitialPlaylist:f,sourceType:g,cacheEncryptionKeys:y,bufferBasedABR:E,leastPixelDiffSelector:x,captionServices:B,experimentalUseMMS:T}=e;if(!i)throw new Error("A non-empty playlist URL or JSON manifest string is required");let{maxPlaylistRetries:w}=e;(w===null||typeof w>"u")&&(w=1/0),Zi=l,this.bufferBasedABR=!!E,this.leastPixelDiffSelector=!!x,this.withCredentials=r,this.tech_=a,this.vhs_=a.vhs,this.player_=e.player_,this.sourceType_=g,this.useCueTags_=u,this.playlistExclusionDuration=d,this.maxPlaylistRetries=w,this.enableLowInitialPlaylist=f,this.usingManagedMediaSource_=!1,this.useCueTags_&&(this.cueTagsTrack_=this.tech_.addTextTrack("metadata","ad-cues"),this.cueTagsTrack_.inBandMetadataTrackDispatchType=""),this.requestOptions_={withCredentials:r,maxPlaylistRetries:w,timeout:null},this.on("error",this.pauseLoading),this.mediaTypes_=X5(),T&&W.ManagedMediaSource?(this.tech_.el_.disableRemotePlayback=!0,this.mediaSource=new W.ManagedMediaSource,this.usingManagedMediaSource_=!0,ne.log("Using ManagedMediaSource")):W.MediaSource&&(this.mediaSource=new W.MediaSource),this.handleDurationChange_=this.handleDurationChange_.bind(this),this.handleSourceOpen_=this.handleSourceOpen_.bind(this),this.handleSourceEnded_=this.handleSourceEnded_.bind(this),this.load=this.load.bind(this),this.pause=this.pause.bind(this),this.mediaSource.addEventListener("durationchange",this.handleDurationChange_),this.mediaSource.addEventListener("sourceopen",this.handleSourceOpen_),this.mediaSource.addEventListener("sourceended",this.handleSourceEnded_),this.mediaSource.addEventListener("startstreaming",this.load),this.mediaSource.addEventListener("endstreaming",this.pause),this.seekable_=Nt(),this.hasPlayed_=!1,this.syncController_=new M5(e),this.segmentMetadataTrack_=a.addRemoteTextTrack({kind:"metadata",label:"segment-metadata"},!1).track,this.segmentMetadataTrack_.mode="hidden",this.decrypter_=new F5,this.sourceUpdater_=new ep(this.mediaSource),this.inbandTextTracks_={},this.timelineChangeController_=new R5,this.keyStatusMap_=new Map;const F={vhs:this.vhs_,parse708captions:e.parse708captions,useDtsForTimestampOffset:e.useDtsForTimestampOffset,captionServices:B,mediaSource:this.mediaSource,currentTime:this.tech_.currentTime.bind(this.tech_),seekable:()=>this.seekable(),seeking:()=>this.tech_.seeking(),duration:()=>this.duration(),hasPlayed:()=>this.hasPlayed_,goalBufferLength:()=>this.goalBufferLength(),bandwidth:o,syncController:this.syncController_,decrypter:this.decrypter_,sourceType:this.sourceType_,inbandTextTracks:this.inbandTextTracks_,cacheEncryptionKeys:y,sourceUpdater:this.sourceUpdater_,timelineChangeController:this.timelineChangeController_,exactManifestTimings:e.exactManifestTimings,addMetadataToTextTrack:this.addMetadataToTextTrack.bind(this)};this.mainPlaylistLoader_=this.sourceType_==="dash"?new bl(i,this.vhs_,it(this.requestOptions_,{addMetadataToTextTrack:this.addMetadataToTextTrack.bind(this)})):new Yn(i,this.vhs_,it(this.requestOptions_,{addDateRangesToTextTrack:this.addDateRangesToTextTrack_.bind(this)})),this.setupMainPlaylistLoaderListeners_(),this.mainSegmentLoader_=new Sl(it(F,{segmentMetadataTrack:this.segmentMetadataTrack_,loaderType:"main"}),e),this.audioSegmentLoader_=new Sl(it(F,{loaderType:"audio"}),e),this.subtitleSegmentLoader_=new N5(it(F,{loaderType:"vtt",featuresNativeTextTracks:this.tech_.featuresNativeTextTracks,loadVttJs:()=>new Promise((K,q)=>{function M(){a.off("vttjserror",N),K()}function N(){a.off("vttjsloaded",M),q()}a.one("vttjsloaded",M),a.one("vttjserror",N),a.addWebVttScript_()})}),e);const P=()=>this.mainSegmentLoader_.bandwidth;this.contentSteeringController_=new K5(this.vhs_.xhr,P),this.setupSegmentLoaderListeners_(),this.bufferBasedABR&&(this.mainPlaylistLoader_.one("loadedplaylist",()=>this.startABRTimer_()),this.tech_.on("pause",()=>this.stopABRTimer_()),this.tech_.on("play",()=>this.startABRTimer_())),J5.forEach(K=>{this[K+"_"]=eS.bind(this,K)}),this.logger_=bi("pc"),this.triggeredFmp4Usage=!1,this.tech_.preload()==="none"?(this.loadOnPlay_=()=>{this.loadOnPlay_=null,this.mainPlaylistLoader_.load()},this.tech_.one("play",this.loadOnPlay_)):this.mainPlaylistLoader_.load(),this.timeToLoadedData__=-1,this.mainAppendsToLoadedData__=-1,this.audioAppendsToLoadedData__=-1;const I=this.tech_.preload()==="none"?"play":"loadstart";this.tech_.one(I,()=>{const K=Date.now();this.tech_.one("loadeddata",()=>{this.timeToLoadedData__=Date.now()-K,this.mainAppendsToLoadedData__=this.mainSegmentLoader_.mediaAppends,this.audioAppendsToLoadedData__=this.audioSegmentLoader_.mediaAppends})})}mainAppendsToLoadedData_(){return this.mainAppendsToLoadedData__}audioAppendsToLoadedData_(){return this.audioAppendsToLoadedData__}appendsToLoadedData_(){const e=this.mainAppendsToLoadedData_(),i=this.audioAppendsToLoadedData_();return e===-1||i===-1?-1:e+i}timeToLoadedData_(){return this.timeToLoadedData__}checkABR_(e="abr"){const i=this.selectPlaylist();i&&this.shouldSwitchToMedia_(i)&&this.switchMedia_(i,e)}switchMedia_(e,i,r){const a=this.media(),o=a&&(a.id||a.uri),l=e&&(e.id||e.uri);if(o&&o!==l){this.logger_(`switch media ${o} -> ${l} from ${i}`);const u={renditionInfo:{id:l,bandwidth:e.attributes.BANDWIDTH,resolution:e.attributes.RESOLUTION,codecs:e.attributes.CODECS},cause:i};this.trigger({type:"renditionselected",metadata:u}),this.tech_.trigger({type:"usage",name:`vhs-rendition-change-${i}`})}this.mainPlaylistLoader_.media(e,r)}switchMediaForDASHContentSteering_(){["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(e=>{const i=this.mediaTypes_[e],r=i?i.activeGroup():null,a=this.contentSteeringController_.getPathway();if(r&&a){const l=(r.length?r[0].playlists:r.playlists).filter(u=>u.attributes.serviceLocation===a);l.length&&this.mediaTypes_[e].activePlaylistLoader.media(l[0])}})}startABRTimer_(){this.stopABRTimer_(),this.abrTimer_=W.setInterval(()=>this.checkABR_(),250)}stopABRTimer_(){this.tech_.scrubbing&&this.tech_.scrubbing()||(W.clearInterval(this.abrTimer_),this.abrTimer_=null)}getAudioTrackPlaylists_(){const e=this.main(),i=e&&e.playlists||[];if(!e||!e.mediaGroups||!e.mediaGroups.AUDIO)return i;const r=e.mediaGroups.AUDIO,a=Object.keys(r);let o;if(Object.keys(this.mediaTypes_.AUDIO.groups).length)o=this.mediaTypes_.AUDIO.activeTrack();else{const u=r.main||a.length&&r[a[0]];for(const d in u)if(u[d].default){o={label:d};break}}if(!o)return i;const l=[];for(const u in r)if(r[u][o.label]){const d=r[u][o.label];if(d.playlists&&d.playlists.length)l.push.apply(l,d.playlists);else if(d.uri)l.push(d);else if(e.playlists.length)for(let f=0;f<e.playlists.length;f++){const g=e.playlists[f];g.attributes&&g.attributes.AUDIO&&g.attributes.AUDIO===u&&l.push(g)}}return l.length?l:i}setupMainPlaylistLoaderListeners_(){this.mainPlaylistLoader_.on("loadedmetadata",()=>{const i=this.mainPlaylistLoader_.media(),r=i.targetDuration*1.5*1e3;gl(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.media())?this.requestOptions_.timeout=0:this.requestOptions_.timeout=r,i.endList&&this.tech_.preload()!=="none"&&(this.mainSegmentLoader_.playlist(i,this.requestOptions_),this.mainSegmentLoader_.load()),Y5({sourceType:this.sourceType_,segmentLoaders:{AUDIO:this.audioSegmentLoader_,SUBTITLES:this.subtitleSegmentLoader_,main:this.mainSegmentLoader_},tech:this.tech_,requestOptions:this.requestOptions_,mainPlaylistLoader:this.mainPlaylistLoader_,vhs:this.vhs_,main:this.main(),mediaTypes:this.mediaTypes_,excludePlaylist:this.excludePlaylist.bind(this)}),this.triggerPresenceUsage_(this.main(),i),this.setupFirstPlay(),!this.mediaTypes_.AUDIO.activePlaylistLoader||this.mediaTypes_.AUDIO.activePlaylistLoader.media()?this.trigger("selectedinitialmedia"):this.mediaTypes_.AUDIO.activePlaylistLoader.one("loadedmetadata",()=>{this.trigger("selectedinitialmedia")})}),this.mainPlaylistLoader_.on("loadedplaylist",()=>{this.loadOnPlay_&&this.tech_.off("play",this.loadOnPlay_);let i=this.mainPlaylistLoader_.media();if(!i){this.attachContentSteeringListeners_(),this.initContentSteeringController_(),this.excludeUnsupportedVariants_();let r;if(this.enableLowInitialPlaylist&&(r=this.selectInitialPlaylist()),r||(r=this.selectPlaylist()),!r||!this.shouldSwitchToMedia_(r)||(this.initialMedia_=r,this.switchMedia_(this.initialMedia_,"initial"),!(this.sourceType_==="vhs-json"&&this.initialMedia_.segments)))return;i=this.initialMedia_}this.handleUpdatedMediaPlaylist(i)}),this.mainPlaylistLoader_.on("error",()=>{const i=this.mainPlaylistLoader_.error;this.excludePlaylist({playlistToExclude:i.playlist,error:i})}),this.mainPlaylistLoader_.on("mediachanging",()=>{this.mainSegmentLoader_.abort(),this.mainSegmentLoader_.pause()}),this.mainPlaylistLoader_.on("mediachange",()=>{const i=this.mainPlaylistLoader_.media(),r=i.targetDuration*1.5*1e3;gl(this.mainPlaylistLoader_.main,this.mainPlaylistLoader_.media())?this.requestOptions_.timeout=0:this.requestOptions_.timeout=r,this.sourceType_==="dash"&&this.mainPlaylistLoader_.isPaused&&this.mainPlaylistLoader_.load(),this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.playlist(i,this.requestOptions_),this.waitingForFastQualityPlaylistReceived_?this.runFastQualitySwitch_():this.mainSegmentLoader_.load(),this.tech_.trigger({type:"mediachange",bubbles:!0})}),this.mainPlaylistLoader_.on("playlistunchanged",()=>{const i=this.mainPlaylistLoader_.media();if(i.lastExcludeReason_==="playlist-unchanged")return;this.stuckAtPlaylistEnd_(i)&&(this.excludePlaylist({error:{message:"Playlist no longer updating.",reason:"playlist-unchanged"}}),this.tech_.trigger("playliststuck"))}),this.mainPlaylistLoader_.on("renditiondisabled",()=>{this.tech_.trigger({type:"usage",name:"vhs-rendition-disabled"})}),this.mainPlaylistLoader_.on("renditionenabled",()=>{this.tech_.trigger({type:"usage",name:"vhs-rendition-enabled"})}),["manifestrequeststart","manifestrequestcomplete","manifestparsestart","manifestparsecomplete","playlistrequeststart","playlistrequestcomplete","playlistparsestart","playlistparsecomplete","renditiondisabled","renditionenabled"].forEach(i=>{this.mainPlaylistLoader_.on(i,r=>{this.player_.trigger(bt({},r))})})}handleUpdatedMediaPlaylist(e){this.useCueTags_&&this.updateAdCues_(e),this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.playlist(e,this.requestOptions_),this.waitingForFastQualityPlaylistReceived_&&this.runFastQualitySwitch_(),this.updateDuration(!e.endList),this.tech_.paused()||(this.mainSegmentLoader_.load(),this.audioSegmentLoader_&&this.audioSegmentLoader_.load())}triggerPresenceUsage_(e,i){const r=e.mediaGroups||{};let a=!0;const o=Object.keys(r.AUDIO);for(const l in r.AUDIO)for(const u in r.AUDIO[l])r.AUDIO[l][u].uri||(a=!1);a&&this.tech_.trigger({type:"usage",name:"vhs-demuxed"}),Object.keys(r.SUBTITLES).length&&this.tech_.trigger({type:"usage",name:"vhs-webvtt"}),Zi.Playlist.isAes(i)&&this.tech_.trigger({type:"usage",name:"vhs-aes"}),o.length&&Object.keys(r.AUDIO[o[0]]).length>1&&this.tech_.trigger({type:"usage",name:"vhs-alternate-audio"}),this.useCueTags_&&this.tech_.trigger({type:"usage",name:"vhs-playlist-cue-tags"})}shouldSwitchToMedia_(e){const i=this.mainPlaylistLoader_.media()||this.mainPlaylistLoader_.pendingMedia_,r=this.tech_.currentTime(),a=this.bufferLowWaterLine(),o=this.bufferHighWaterLine(),l=this.tech_.buffered();return tS({buffered:l,currentTime:r,currentPlaylist:i,nextPlaylist:e,bufferLowWaterLine:a,bufferHighWaterLine:o,duration:this.duration(),bufferBasedABR:this.bufferBasedABR,log:this.logger_})}setupSegmentLoaderListeners_(){this.mainSegmentLoader_.on("bandwidthupdate",()=>{this.checkABR_("bandwidthupdate"),this.tech_.trigger("bandwidthupdate")}),this.mainSegmentLoader_.on("timeout",()=>{this.bufferBasedABR&&this.mainSegmentLoader_.load()}),this.bufferBasedABR||this.mainSegmentLoader_.on("progress",()=>{this.trigger("progress")}),this.mainSegmentLoader_.on("error",()=>{const r=this.mainSegmentLoader_.error();this.excludePlaylist({playlistToExclude:r.playlist,error:r})}),this.mainSegmentLoader_.on("appenderror",()=>{this.error=this.mainSegmentLoader_.error_,this.trigger("error")}),this.mainSegmentLoader_.on("syncinfoupdate",()=>{this.onSyncInfoUpdate_()}),this.mainSegmentLoader_.on("timestampoffset",()=>{this.tech_.trigger({type:"usage",name:"vhs-timestamp-offset"})}),this.audioSegmentLoader_.on("syncinfoupdate",()=>{this.onSyncInfoUpdate_()}),this.audioSegmentLoader_.on("appenderror",()=>{this.error=this.audioSegmentLoader_.error_,this.trigger("error")}),this.mainSegmentLoader_.on("ended",()=>{this.logger_("main segment loader ended"),this.onEndOfStream()}),this.timelineChangeController_.on("audioTimelineBehind",()=>{const r=this.audioSegmentLoader_.pendingSegment_;if(!r||!r.segment||!r.segment.syncInfo)return;const a=r.segment.syncInfo.end+.01;this.tech_.setCurrentTime(a)}),this.timelineChangeController_.on("fixBadTimelineChange",()=>{this.logger_("Fix bad timeline change. Restarting al segment loaders..."),this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.resetEverything(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.pause(),this.audioSegmentLoader_.resetEverything()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.pause(),this.subtitleSegmentLoader_.resetEverything()),this.load()}),this.mainSegmentLoader_.on("earlyabort",r=>{this.bufferBasedABR||(this.delegateLoaders_("all",["abort"]),this.excludePlaylist({error:{message:"Aborted early because there isn't enough bandwidth to complete the request without rebuffering."},playlistExclusionDuration:Z5}))});const e=()=>{if(!this.sourceUpdater_.hasCreatedSourceBuffers())return this.tryToCreateSourceBuffers_();const r=this.getCodecsOrExclude_();r&&this.sourceUpdater_.addOrChangeSourceBuffers(r)};this.mainSegmentLoader_.on("trackinfo",e),this.audioSegmentLoader_.on("trackinfo",e),this.mainSegmentLoader_.on("fmp4",()=>{this.triggeredFmp4Usage||(this.tech_.trigger({type:"usage",name:"vhs-fmp4"}),this.triggeredFmp4Usage=!0)}),this.audioSegmentLoader_.on("fmp4",()=>{this.triggeredFmp4Usage||(this.tech_.trigger({type:"usage",name:"vhs-fmp4"}),this.triggeredFmp4Usage=!0)}),this.audioSegmentLoader_.on("ended",()=>{this.logger_("audioSegmentLoader ended"),this.onEndOfStream()}),["segmentselected","segmentloadstart","segmentloaded","segmentkeyloadstart","segmentkeyloadcomplete","segmentdecryptionstart","segmentdecryptioncomplete","segmenttransmuxingstart","segmenttransmuxingcomplete","segmenttransmuxingtrackinfoavailable","segmenttransmuxingtiminginfoavailable","segmentappendstart","appendsdone","bandwidthupdated","timelinechange","codecschange"].forEach(r=>{this.mainSegmentLoader_.on(r,a=>{this.player_.trigger(bt({},a))}),this.audioSegmentLoader_.on(r,a=>{this.player_.trigger(bt({},a))}),this.subtitleSegmentLoader_.on(r,a=>{this.player_.trigger(bt({},a))})})}mediaSecondsLoaded_(){return Math.max(this.audioSegmentLoader_.mediaSecondsLoaded+this.mainSegmentLoader_.mediaSecondsLoaded)}load(){this.mainSegmentLoader_.load(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.load(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.load()}pause(){this.mainSegmentLoader_.pause(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.pause(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.pause()}fastQualityChange_(e=this.selectPlaylist()){if(e&&e===this.mainPlaylistLoader_.media()){this.logger_("skipping fastQualityChange because new media is same as old");return}this.switchMedia_(e,"fast-quality"),this.waitingForFastQualityPlaylistReceived_=!0}runFastQualitySwitch_(){this.waitingForFastQualityPlaylistReceived_=!1,this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.resetEverything(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.pause(),this.audioSegmentLoader_.resetEverything()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.pause(),this.subtitleSegmentLoader_.resetEverything()),this.load()}play(){if(this.setupFirstPlay())return;this.tech_.ended()&&this.tech_.setCurrentTime(0),this.hasPlayed_&&this.load();const e=this.tech_.seekable();if(this.tech_.duration()===1/0&&this.tech_.currentTime()<e.start(0))return this.tech_.setCurrentTime(e.end(e.length-1))}setupFirstPlay(){const e=this.mainPlaylistLoader_.media();if(!e||this.tech_.paused()||this.hasPlayed_)return!1;if(!e.endList||e.start){const i=this.seekable();if(!i.length)return!1;const r=i.end(0);let a=r;if(e.start){const o=e.start.timeOffset;if(o<0){const l=this.mainPlaylistLoader_.main,u=Zi.Playlist.liveEdgeDelay(l,e),d=r+u;a=Math.max(Math.min(d+o,r),i.start(0))}else a=Math.min(r,o)}this.trigger("firstplay"),this.tech_.setCurrentTime(a)}return this.hasPlayed_=!0,this.load(),!0}handleSourceOpen_(){if(this.tryToCreateSourceBuffers_(),this.tech_.autoplay()){const e=this.tech_.play();typeof e<"u"&&typeof e.then=="function"&&e.then(null,i=>{})}this.trigger("sourceopen")}handleSourceEnded_(){if(!this.inbandTextTracks_.metadataTrack_)return;const e=this.inbandTextTracks_.metadataTrack_.cues;if(!e||!e.length)return;const i=this.duration();e[e.length-1].endTime=isNaN(i)||Math.abs(i)===1/0?Number.MAX_VALUE:i}handleDurationChange_(){this.tech_.trigger("durationchange")}onEndOfStream(){let e=this.mainSegmentLoader_.ended_;if(this.mediaTypes_.AUDIO.activePlaylistLoader){const i=this.mainSegmentLoader_.getCurrentMediaInfo_();!i||i.hasVideo?e=e&&this.audioSegmentLoader_.ended_:e=this.audioSegmentLoader_.ended_}e&&(this.stopABRTimer_(),this.sourceUpdater_.endOfStream())}stuckAtPlaylistEnd_(e){if(!this.seekable().length)return!1;const r=this.syncController_.getExpiredTime(e,this.duration());if(r===null)return!1;const a=Zi.Playlist.playlistEnd(e,r),o=this.tech_.currentTime(),l=this.tech_.buffered();if(!l.length)return a-o<=ji;const u=l.end(l.length-1);return u-o<=ji&&a-u<=ji}excludePlaylist({playlistToExclude:e=this.mainPlaylistLoader_.media(),error:i={},playlistExclusionDuration:r}){if(e=e||this.mainPlaylistLoader_.media(),r=r||i.playlistExclusionDuration||this.playlistExclusionDuration,!e){this.error=i,this.mediaSource.readyState!=="open"?this.trigger("error"):this.sourceUpdater_.endOfStream("network");return}e.playlistErrors_++;const a=this.mainPlaylistLoader_.main.playlists,o=a.filter(za),l=o.length===1&&o[0]===e;if(a.length===1&&r!==1/0)return ne.log.warn(`Problem encountered with playlist ${e.id}. Trying again since it is the only playlist.`),this.tech_.trigger("retryplaylist"),this.mainPlaylistLoader_.load(l);if(l){if(this.main().contentSteering){const B=this.pathwayAttribute_(e),T=this.contentSteeringController_.steeringManifest.ttl*1e3;this.contentSteeringController_.excludePathway(B),this.excludeThenChangePathway_(),setTimeout(()=>{this.contentSteeringController_.addAvailablePathway(B)},T);return}let x=!1;a.forEach(B=>{if(B===e)return;const T=B.excludeUntil;typeof T<"u"&&T!==1/0&&(x=!0,delete B.excludeUntil)}),x&&(ne.log.warn("Removing other playlists from the exclusion list because the last rendition is about to be excluded."),this.tech_.trigger("retryplaylist"))}let u;e.playlistErrors_>this.maxPlaylistRetries?u=1/0:u=Date.now()+r*1e3,e.excludeUntil=u,i.reason&&(e.lastExcludeReason_=i.reason),this.tech_.trigger("excludeplaylist"),this.tech_.trigger({type:"usage",name:"vhs-rendition-excluded"});const d=this.selectPlaylist();if(!d){this.error="Playback cannot continue. No available working or supported playlists.",this.trigger("error");return}const f=i.internal?this.logger_:ne.log.warn,g=i.message?" "+i.message:"";f(`${i.internal?"Internal problem":"Problem"} encountered with playlist ${e.id}.${g} Switching to playlist ${d.id}.`),d.attributes.AUDIO!==e.attributes.AUDIO&&this.delegateLoaders_("audio",["abort","pause"]),d.attributes.SUBTITLES!==e.attributes.SUBTITLES&&this.delegateLoaders_("subtitle",["abort","pause"]),this.delegateLoaders_("main",["abort","pause"]);const y=d.targetDuration/2*1e3||5*1e3,E=typeof d.lastRequest=="number"&&Date.now()-d.lastRequest<=y;return this.switchMedia_(d,"exclude",l||E)}pauseLoading(){this.delegateLoaders_("all",["abort","pause"]),this.stopABRTimer_()}delegateLoaders_(e,i){const r=[],a=e==="all";(a||e==="main")&&r.push(this.mainPlaylistLoader_);const o=[];(a||e==="audio")&&o.push("AUDIO"),(a||e==="subtitle")&&(o.push("CLOSED-CAPTIONS"),o.push("SUBTITLES")),o.forEach(l=>{const u=this.mediaTypes_[l]&&this.mediaTypes_[l].activePlaylistLoader;u&&r.push(u)}),["main","audio","subtitle"].forEach(l=>{const u=this[`${l}SegmentLoader_`];u&&(e===l||e==="all")&&r.push(u)}),r.forEach(l=>i.forEach(u=>{typeof l[u]=="function"&&l[u]()}))}setCurrentTime(e){const i=Wn(this.tech_.buffered(),e);if(!(this.mainPlaylistLoader_&&this.mainPlaylistLoader_.media())||!this.mainPlaylistLoader_.media().segments)return 0;if(i&&i.length)return e;this.mainSegmentLoader_.pause(),this.mainSegmentLoader_.resetEverything(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.pause(),this.audioSegmentLoader_.resetEverything()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.pause(),this.subtitleSegmentLoader_.resetEverything()),this.load()}duration(){if(!this.mainPlaylistLoader_)return 0;const e=this.mainPlaylistLoader_.media();return e?e.endList?this.mediaSource?this.mediaSource.duration:Zi.Playlist.duration(e):1/0:0}seekable(){return this.seekable_}getSeekableRange_(e,i){const r=e.media();if(!r)return null;const a=this.syncController_.getMediaSequenceSync(i);if(a&&a.isReliable){const u=a.start,d=a.end;if(!isFinite(u)||!isFinite(d))return null;const f=Zi.Playlist.liveEdgeDelay(this.mainPlaylistLoader_.main,r),g=Math.max(u,d-f);return Nt([[u,g]])}const o=this.syncController_.getExpiredTime(r,this.duration());if(o===null)return null;const l=Zi.Playlist.seekable(r,o,Zi.Playlist.liveEdgeDelay(this.mainPlaylistLoader_.main,r));return l.length?l:null}computeFinalSeekable_(e,i){if(!i)return e;const r=e.start(0),a=e.end(0),o=i.start(0),l=i.end(0);return o>a||r>l?e:Nt([[Math.max(r,o),Math.min(a,l)]])}onSyncInfoUpdate_(){if(!this.mainPlaylistLoader_)return;const e=this.getSeekableRange_(this.mainPlaylistLoader_,"main");if(!e)return;let i;if(this.mediaTypes_.AUDIO.activePlaylistLoader&&(i=this.getSeekableRange_(this.mediaTypes_.AUDIO.activePlaylistLoader,"audio"),!i))return;const r=this.seekable_;if(this.seekable_=this.computeFinalSeekable_(e,i),!this.seekable_||r&&r.length&&this.seekable_.length&&r.start(0)===this.seekable_.start(0)&&r.end(0)===this.seekable_.end(0))return;this.logger_(`seekable updated [${ff(this.seekable_)}]`);const a={seekableRanges:this.seekable_};this.trigger({type:"seekablerangeschanged",metadata:a}),this.tech_.trigger("seekablechanged")}updateDuration(e){if(this.updateDuration_&&(this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.updateDuration_=null),this.mediaSource.readyState!=="open"){this.updateDuration_=this.updateDuration.bind(this,e),this.mediaSource.addEventListener("sourceopen",this.updateDuration_);return}if(e){const a=this.seekable();if(!a.length)return;(isNaN(this.mediaSource.duration)||this.mediaSource.duration<a.end(a.length-1))&&this.sourceUpdater_.setDuration(a.end(a.length-1));return}const i=this.tech_.buffered();let r=Zi.Playlist.duration(this.mainPlaylistLoader_.media());i.length>0&&(r=Math.max(r,i.end(i.length-1))),this.mediaSource.duration!==r&&this.sourceUpdater_.setDuration(r)}dispose(){this.trigger("dispose"),this.decrypter_.terminate(),this.mainPlaylistLoader_.dispose(),this.mainSegmentLoader_.dispose(),this.contentSteeringController_.dispose(),this.keyStatusMap_.clear(),this.loadOnPlay_&&this.tech_.off("play",this.loadOnPlay_),["AUDIO","SUBTITLES"].forEach(e=>{const i=this.mediaTypes_[e].groups;for(const r in i)i[r].forEach(a=>{a.playlistLoader&&a.playlistLoader.dispose()})}),this.audioSegmentLoader_.dispose(),this.subtitleSegmentLoader_.dispose(),this.sourceUpdater_.dispose(),this.timelineChangeController_.dispose(),this.stopABRTimer_(),this.updateDuration_&&this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.mediaSource.removeEventListener("durationchange",this.handleDurationChange_),this.mediaSource.removeEventListener("sourceopen",this.handleSourceOpen_),this.mediaSource.removeEventListener("sourceended",this.handleSourceEnded_),this.off()}main(){return this.mainPlaylistLoader_.main}media(){return this.mainPlaylistLoader_.media()||this.initialMedia_}areMediaTypesKnown_(){const e=!!this.mediaTypes_.AUDIO.activePlaylistLoader,i=!!this.mainSegmentLoader_.getCurrentMediaInfo_(),r=e?!!this.audioSegmentLoader_.getCurrentMediaInfo_():!0;return!(!i||!r)}getCodecsOrExclude_(){const e={main:this.mainSegmentLoader_.getCurrentMediaInfo_()||{},audio:this.audioSegmentLoader_.getCurrentMediaInfo_()||{}},i=this.mainSegmentLoader_.getPendingSegmentPlaylist()||this.media();e.video=e.main;const r=ts(this.main(),i),a={},o=!!this.mediaTypes_.AUDIO.activePlaylistLoader;if(e.main.hasVideo&&(a.video=r.video||e.main.videoCodec||Hb),e.main.isMuxed&&(a.video+=`,${r.audio||e.main.audioCodec||zc}`),(e.main.hasAudio&&!e.main.isMuxed||e.audio.hasAudio||o)&&(a.audio=r.audio||e.main.audioCodec||e.audio.audioCodec||zc,e.audio.isFmp4=e.main.hasAudio&&!e.main.isMuxed?e.main.isFmp4:e.audio.isFmp4),!a.audio&&!a.video){this.excludePlaylist({playlistToExclude:i,error:{message:"Could not determine codecs for playlist."},playlistExclusionDuration:1/0});return}const l=(f,g)=>f?Kr(g,this.usingManagedMediaSource_):Ao(g),u={};let d;if(["video","audio"].forEach(function(f){if(a.hasOwnProperty(f)&&!l(e[f].isFmp4,a[f])){const g=e[f].isFmp4?"browser":"muxer";u[g]=u[g]||[],u[g].push(a[f]),f==="audio"&&(d=g)}}),o&&d&&i.attributes.AUDIO){const f=i.attributes.AUDIO;this.main().playlists.forEach(g=>{(g.attributes&&g.attributes.AUDIO)===f&&g!==i&&(g.excludeUntil=1/0)}),this.logger_(`excluding audio group ${f} as ${d} does not support codec(s): "${a.audio}"`)}if(Object.keys(u).length){const f=Object.keys(u).reduce((g,y)=>(g&&(g+=", "),g+=`${y} does not support codec(s): "${u[y].join(",")}"`,g),"")+".";this.excludePlaylist({playlistToExclude:i,error:{internal:!0,message:f},playlistExclusionDuration:1/0});return}if(this.sourceUpdater_.hasCreatedSourceBuffers()&&!this.sourceUpdater_.canChangeType()){const f=[];if(["video","audio"].forEach(g=>{const y=(Fi(this.sourceUpdater_.codecs[g]||"")[0]||{}).type,E=(Fi(a[g]||"")[0]||{}).type;y&&E&&y.toLowerCase()!==E.toLowerCase()&&f.push(`"${this.sourceUpdater_.codecs[g]}" -> "${a[g]}"`)}),f.length){this.excludePlaylist({playlistToExclude:i,error:{message:`Codec switching not supported: ${f.join(", ")}.`,internal:!0},playlistExclusionDuration:1/0});return}}return a}tryToCreateSourceBuffers_(){if(this.mediaSource.readyState!=="open"||this.sourceUpdater_.hasCreatedSourceBuffers()||!this.areMediaTypesKnown_())return;const e=this.getCodecsOrExclude_();if(!e)return;this.sourceUpdater_.createSourceBuffers(e);const i=[e.video,e.audio].filter(Boolean).join(",");this.excludeIncompatibleVariants_(i)}excludeUnsupportedVariants_(){const e=this.main().playlists,i=[];Object.keys(e).forEach(r=>{const a=e[r];if(i.indexOf(a.id)!==-1)return;i.push(a.id);const o=ts(this.main,a),l=[];o.audio&&!Ao(o.audio)&&!Kr(o.audio,this.usingManagedMediaSource_)&&l.push(`audio codec ${o.audio}`),o.video&&!Ao(o.video)&&!Kr(o.video,this.usingManagedMediaSource_)&&l.push(`video codec ${o.video}`),o.text&&o.text==="stpp.ttml.im1t"&&l.push(`text codec ${o.text}`),l.length&&(a.excludeUntil=1/0,this.logger_(`excluding ${a.id} for unsupported: ${l.join(", ")}`))})}excludeIncompatibleVariants_(e){const i=[],r=this.main().playlists,a=as(Fi(e)),o=Vd(a),l=a.video&&Fi(a.video)[0]||null,u=a.audio&&Fi(a.audio)[0]||null;Object.keys(r).forEach(d=>{const f=r[d];if(i.indexOf(f.id)!==-1||f.excludeUntil===1/0)return;i.push(f.id);const g=[],y=ts(this.mainPlaylistLoader_.main,f),E=Vd(y);if(!(!y.audio&&!y.video)){if(E!==o&&g.push(`codec count "${E}" !== "${o}"`),!this.sourceUpdater_.canChangeType()){const x=y.video&&Fi(y.video)[0]||null,B=y.audio&&Fi(y.audio)[0]||null;x&&l&&x.type.toLowerCase()!==l.type.toLowerCase()&&g.push(`video codec "${x.type}" !== "${l.type}"`),B&&u&&B.type.toLowerCase()!==u.type.toLowerCase()&&g.push(`audio codec "${B.type}" !== "${u.type}"`)}g.length&&(f.excludeUntil=1/0,this.logger_(`excluding ${f.id}: ${g.join(" && ")}`))}})}updateAdCues_(e){let i=0;const r=this.seekable();r.length&&(i=r.start(0)),B5(e,this.cueTagsTrack_,i)}goalBufferLength(){const e=this.tech_.currentTime(),i=At.GOAL_BUFFER_LENGTH,r=At.GOAL_BUFFER_LENGTH_RATE,a=Math.max(i,At.MAX_GOAL_BUFFER_LENGTH);return Math.min(i+e*r,a)}bufferLowWaterLine(){const e=this.tech_.currentTime(),i=At.BUFFER_LOW_WATER_LINE,r=At.BUFFER_LOW_WATER_LINE_RATE,a=Math.max(i,At.MAX_BUFFER_LOW_WATER_LINE),o=Math.max(i,At.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE);return Math.min(i+e*r,this.bufferBasedABR?o:a)}bufferHighWaterLine(){return At.BUFFER_HIGH_WATER_LINE}addDateRangesToTextTrack_(e){Gd(this.inbandTextTracks_,"com.apple.streaming",this.tech_),h5({inbandTextTracks:this.inbandTextTracks_,dateRanges:e})}addMetadataToTextTrack(e,i,r){const a=this.sourceUpdater_.videoBuffer?this.sourceUpdater_.videoTimestampOffset():this.sourceUpdater_.audioTimestampOffset();Gd(this.inbandTextTracks_,e,this.tech_),u5({inbandTextTracks:this.inbandTextTracks_,metadataArray:i,timestampOffset:a,videoDuration:r})}pathwayAttribute_(e){return e.attributes["PATHWAY-ID"]||e.attributes.serviceLocation}initContentSteeringController_(){const e=this.main();if(e.contentSteering){for(const i of e.playlists)this.contentSteeringController_.addAvailablePathway(this.pathwayAttribute_(i));if(this.contentSteeringController_.assignTagProperties(e.uri,e.contentSteering),this.contentSteeringController_.queryBeforeStart){this.contentSteeringController_.requestSteeringManifest(!0);return}this.tech_.one("canplay",()=>{this.contentSteeringController_.requestSteeringManifest()})}}resetContentSteeringController_(){this.contentSteeringController_.clearAvailablePathways(),this.contentSteeringController_.dispose(),this.initContentSteeringController_()}attachContentSteeringListeners_(){this.contentSteeringController_.on("content-steering",this.excludeThenChangePathway_.bind(this)),["contentsteeringloadstart","contentsteeringloadcomplete","contentsteeringparsed"].forEach(i=>{this.contentSteeringController_.on(i,r=>{this.trigger(bt({},r))})}),this.sourceType_==="dash"&&this.mainPlaylistLoader_.on("loadedplaylist",()=>{const i=this.main();(this.contentSteeringController_.didDASHTagChange(i.uri,i.contentSteering)||(()=>{const o=this.contentSteeringController_.getAvailablePathways(),l=[];for(const u of i.playlists){const d=u.attributes.serviceLocation;if(d&&(l.push(d),!o.has(d)))return!0}return!!(!l.length&&o.size)})())&&this.resetContentSteeringController_()})}excludeThenChangePathway_(){const e=this.contentSteeringController_.getPathway();if(!e)return;this.handlePathwayClones_();const r=this.main().playlists,a=new Set;let o=!1;Object.keys(r).forEach(l=>{const u=r[l],d=this.pathwayAttribute_(u),f=d&&e!==d;u.excludeUntil===1/0&&u.lastExcludeReason_==="content-steering"&&!f&&(delete u.excludeUntil,delete u.lastExcludeReason_,o=!0);const y=!u.excludeUntil&&u.excludeUntil!==1/0;!a.has(u.id)&&f&&y&&(a.add(u.id),u.excludeUntil=1/0,u.lastExcludeReason_="content-steering",this.logger_(`excluding ${u.id} for ${u.lastExcludeReason_}`))}),this.contentSteeringController_.manifestType_==="DASH"&&Object.keys(this.mediaTypes_).forEach(l=>{const u=this.mediaTypes_[l];if(u.activePlaylistLoader){const d=u.activePlaylistLoader.media_;d&&d.attributes.serviceLocation!==e&&(o=!0)}}),o&&this.changeSegmentPathway_()}handlePathwayClones_(){const i=this.main().playlists,r=this.contentSteeringController_.currentPathwayClones,a=this.contentSteeringController_.nextPathwayClones;if(r&&r.size||a&&a.size){for(const[l,u]of r.entries())a.get(l)||(this.mainPlaylistLoader_.updateOrDeleteClone(u),this.contentSteeringController_.excludePathway(l));for(const[l,u]of a.entries()){const d=r.get(l);if(!d){i.filter(g=>g.attributes["PATHWAY-ID"]===u["BASE-ID"]).forEach(g=>{this.mainPlaylistLoader_.addClonePathway(u,g)}),this.contentSteeringController_.addAvailablePathway(l);continue}this.equalPathwayClones_(d,u)||(this.mainPlaylistLoader_.updateOrDeleteClone(u,!0),this.contentSteeringController_.addAvailablePathway(l))}this.contentSteeringController_.currentPathwayClones=new Map(JSON.parse(JSON.stringify([...a])))}}equalPathwayClones_(e,i){if(e["BASE-ID"]!==i["BASE-ID"]||e.ID!==i.ID||e["URI-REPLACEMENT"].HOST!==i["URI-REPLACEMENT"].HOST)return!1;const r=e["URI-REPLACEMENT"].PARAMS,a=i["URI-REPLACEMENT"].PARAMS;for(const o in r)if(r[o]!==a[o])return!1;for(const o in a)if(r[o]!==a[o])return!1;return!0}changeSegmentPathway_(){const e=this.selectPlaylist();this.pauseLoading(),this.contentSteeringController_.manifestType_==="DASH"&&this.switchMediaForDASHContentSteering_(),this.switchMedia_(e,"content-steering")}excludeNonUsablePlaylistsByKeyId_(){if(!this.mainPlaylistLoader_||!this.mainPlaylistLoader_.main)return;let e=0;const i="non-usable";this.mainPlaylistLoader_.main.playlists.forEach(r=>{const a=this.mainPlaylistLoader_.getKeyIdSet(r);!a||!a.size||a.forEach(o=>{const l="usable",u=this.keyStatusMap_.has(o)&&this.keyStatusMap_.get(o)===l,d=r.lastExcludeReason_===i&&r.excludeUntil===1/0;u?u&&d&&(delete r.excludeUntil,delete r.lastExcludeReason_,this.logger_(`enabling playlist ${r.id} because key ID ${o} is ${l}`)):(r.excludeUntil!==1/0&&r.lastExcludeReason_!==i&&(r.excludeUntil=1/0,r.lastExcludeReason_=i,this.logger_(`excluding playlist ${r.id} because the key ID ${o} doesn't exist in the keyStatusMap or is not ${l}`)),e++)})}),e>=this.mainPlaylistLoader_.main.playlists.length&&this.mainPlaylistLoader_.main.playlists.forEach(r=>{const a=r&&r.attributes&&r.attributes.RESOLUTION&&r.attributes.RESOLUTION.height<720,o=r.excludeUntil===1/0&&r.lastExcludeReason_===i;a&&o&&(delete r.excludeUntil,ne.log.warn(`enabling non-HD playlist ${r.id} because all playlists were excluded due to ${i} key IDs`))})}addKeyStatus_(e,i){const o=(typeof e=="string"?e:A5(e)).slice(0,32).toLowerCase();this.logger_(`KeyStatus '${i}' with key ID ${o} added to the keyStatusMap`),this.keyStatusMap_.set(o,i)}updatePlaylistByKeyStatus(e,i){this.addKeyStatus_(e,i),this.waitingForFastQualityPlaylistReceived_||this.excludeNonUsableThenChangePlaylist_(),this.mainPlaylistLoader_.off("loadedplaylist",this.excludeNonUsableThenChangePlaylist_.bind(this)),this.mainPlaylistLoader_.on("loadedplaylist",this.excludeNonUsableThenChangePlaylist_.bind(this))}excludeNonUsableThenChangePlaylist_(){this.excludeNonUsablePlaylistsByKeyId_(),this.fastQualityChange_()}}const nS=(s,e,i)=>r=>{const a=s.main.playlists[e],o=du(a),l=za(a);if(typeof r>"u")return l;r?delete a.disabled:a.disabled=!0;const u={renditionInfo:{id:e,bandwidth:a.attributes.BANDWIDTH,resolution:a.attributes.RESOLUTION,codecs:a.attributes.CODECS},cause:"fast-quality"};return r!==l&&!o&&(r?(i(a),s.trigger({type:"renditionenabled",metadata:u})):s.trigger({type:"renditiondisabled",metadata:u})),r};class rS{constructor(e,i,r){const{playlistController_:a}=e,o=a.fastQualityChange_.bind(a);if(i.attributes){const l=i.attributes.RESOLUTION;this.width=l&&l.width,this.height=l&&l.height,this.bandwidth=i.attributes.BANDWIDTH,this.frameRate=i.attributes["FRAME-RATE"]}this.codecs=ts(a.main(),i),this.playlist=i,this.id=r,this.enabled=nS(e.playlists,i.id,o)}}const sS=function(s){s.representations=()=>{const e=s.playlistController_.main(),i=hs(e)?s.playlistController_.getAudioTrackPlaylists_():e.playlists;return i?i.filter(r=>!du(r)).map((r,a)=>new rS(s,r,r.id)):[]}},nh=["seeking","seeked","pause","playing","error"];class aS extends ne.EventTarget{constructor(e){super(),this.playlistController_=e.playlistController,this.tech_=e.tech,this.seekable=e.seekable,this.allowSeeksWithinUnsafeLiveWindow=e.allowSeeksWithinUnsafeLiveWindow,this.liveRangeSafeTimeDelta=e.liveRangeSafeTimeDelta,this.media=e.media,this.playedRanges_=[],this.consecutiveUpdates=0,this.lastRecordedTime=null,this.checkCurrentTimeTimeout_=null,this.logger_=bi("PlaybackWatcher"),this.logger_("initialize");const i=()=>this.monitorCurrentTime_(),r=()=>this.monitorCurrentTime_(),a=()=>this.techWaiting_(),o=()=>this.resetTimeUpdate_(),l=this.playlistController_,u=["main","subtitle","audio"],d={};u.forEach(g=>{d[g]={reset:()=>this.resetSegmentDownloads_(g),updateend:()=>this.checkSegmentDownloads_(g)},l[`${g}SegmentLoader_`].on("appendsdone",d[g].updateend),l[`${g}SegmentLoader_`].on("playlistupdate",d[g].reset),this.tech_.on(["seeked","seeking"],d[g].reset)});const f=g=>{["main","audio"].forEach(y=>{l[`${y}SegmentLoader_`][g]("appended",this.seekingAppendCheck_)})};this.seekingAppendCheck_=()=>{this.fixesBadSeeks_()&&(this.consecutiveUpdates=0,this.lastRecordedTime=this.tech_.currentTime(),f("off"))},this.clearSeekingAppendCheck_=()=>f("off"),this.watchForBadSeeking_=()=>{this.clearSeekingAppendCheck_(),f("on")},this.tech_.on("seeked",this.clearSeekingAppendCheck_),this.tech_.on("seeking",this.watchForBadSeeking_),this.tech_.on("waiting",a),this.tech_.on(nh,o),this.tech_.on("canplay",r),this.tech_.one("play",i),this.dispose=()=>{this.clearSeekingAppendCheck_(),this.logger_("dispose"),this.tech_.off("waiting",a),this.tech_.off(nh,o),this.tech_.off("canplay",r),this.tech_.off("play",i),this.tech_.off("seeking",this.watchForBadSeeking_),this.tech_.off("seeked",this.clearSeekingAppendCheck_),u.forEach(g=>{l[`${g}SegmentLoader_`].off("appendsdone",d[g].updateend),l[`${g}SegmentLoader_`].off("playlistupdate",d[g].reset),this.tech_.off(["seeked","seeking"],d[g].reset)}),this.checkCurrentTimeTimeout_&&W.clearTimeout(this.checkCurrentTimeTimeout_),this.resetTimeUpdate_()}}monitorCurrentTime_(){this.checkCurrentTime_(),this.checkCurrentTimeTimeout_&&W.clearTimeout(this.checkCurrentTimeTimeout_),this.checkCurrentTimeTimeout_=W.setTimeout(this.monitorCurrentTime_.bind(this),250)}resetSegmentDownloads_(e){const i=this.playlistController_[`${e}SegmentLoader_`];this[`${e}StalledDownloads_`]>0&&this.logger_(`resetting possible stalled download count for ${e} loader`),this[`${e}StalledDownloads_`]=0,this[`${e}Buffered_`]=i.buffered_()}checkSegmentDownloads_(e){const i=this.playlistController_,r=i[`${e}SegmentLoader_`],a=r.buffered_(),o=zx(this[`${e}Buffered_`],a);if(this[`${e}Buffered_`]=a,o){const l={bufferedRanges:a};i.trigger({type:"bufferedrangeschanged",metadata:l}),this.resetSegmentDownloads_(e);return}this[`${e}StalledDownloads_`]++,this.logger_(`found #${this[`${e}StalledDownloads_`]} ${e} appends that did not increase buffer (possible stalled download)`,{playlistId:r.playlist_&&r.playlist_.id,buffered:An(a)}),!(this[`${e}StalledDownloads_`]<10)&&(this.logger_(`${e} loader stalled download exclusion`),this.resetSegmentDownloads_(e),this.tech_.trigger({type:"usage",name:`vhs-${e}-download-exclusion`}),e!=="subtitle"&&i.excludePlaylist({error:{message:`Excessive ${e} segment downloading detected.`},playlistExclusionDuration:1/0}))}checkCurrentTime_(){if(this.tech_.paused()||this.tech_.seeking())return;const e=this.tech_.currentTime(),i=this.tech_.buffered();if(this.lastRecordedTime===e&&(!i.length||e+ji>=i.end(i.length-1)))return this.techWaiting_();if(this.consecutiveUpdates>=5&&e===this.lastRecordedTime)this.consecutiveUpdates++,this.waiting_();else if(e===this.lastRecordedTime)this.consecutiveUpdates++;else{this.playedRanges_.push(Nt([this.lastRecordedTime,e]));const r={playedRanges:this.playedRanges_};this.playlistController_.trigger({type:"playedrangeschanged",metadata:r}),this.consecutiveUpdates=0,this.lastRecordedTime=e}}resetTimeUpdate_(){this.consecutiveUpdates=0}fixesBadSeeks_(){if(!this.tech_.seeking())return!1;const i=this.seekable(),r=this.tech_.currentTime(),a=this.afterSeekableWindow_(i,r,this.media(),this.allowSeeksWithinUnsafeLiveWindow);let o;if(a&&(o=i.end(i.length-1)),this.beforeSeekableWindow_(i,r)){const B=i.start(0);o=B+(B===i.end(0)?0:ji)}if(typeof o<"u")return this.logger_(`Trying to seek outside of seekable at time ${r} with seekable range ${ff(i)}. Seeking to ${o}.`),this.tech_.setCurrentTime(o),!0;const l=this.playlistController_.sourceUpdater_,u=this.tech_.buffered(),d=l.audioBuffer?l.audioBuffered():null,f=l.videoBuffer?l.videoBuffered():null,g=this.media(),y=g.partTargetDuration?g.partTargetDuration:(g.targetDuration-qi)*2,E=[d,f];for(let B=0;B<E.length;B++){if(!E[B])continue;if(uu(E[B],r)<y)return!1}const x=js(u,r);return x.length===0?!1:(o=x.start(0)+ji,this.logger_(`Buffered region starts (${x.start(0)}) just beyond seek point (${r}). Seeking to ${o}.`),this.tech_.setCurrentTime(o),!0)}waiting_(){if(this.techWaiting_())return;const e=this.tech_.currentTime(),i=this.tech_.buffered(),r=Wn(i,e);if(r.length&&e+3<=r.end(0)){this.resetTimeUpdate_(),this.tech_.setCurrentTime(e),this.logger_(`Stopped at ${e} while inside a buffered region [${r.start(0)} -> ${r.end(0)}]. Attempting to resume playback by seeking to the current time.`),this.tech_.trigger({type:"usage",name:"vhs-unknown-waiting"});return}}techWaiting_(){const e=this.seekable(),i=this.tech_.currentTime();if(this.tech_.seeking())return!0;if(this.beforeSeekableWindow_(e,i)){const u=e.end(e.length-1);return this.logger_(`Fell out of live window at time ${i}. Seeking to live point (seekable end) ${u}`),this.resetTimeUpdate_(),this.tech_.setCurrentTime(u),this.tech_.trigger({type:"usage",name:"vhs-live-resync"}),!0}const r=this.tech_.vhs.playlistController_.sourceUpdater_,a=this.tech_.buffered();if(this.videoUnderflow_({audioBuffered:r.audioBuffered(),videoBuffered:r.videoBuffered(),currentTime:i}))return this.resetTimeUpdate_(),this.tech_.setCurrentTime(i),this.tech_.trigger({type:"usage",name:"vhs-video-underflow"}),!0;const l=js(a,i);return l.length>0?(this.logger_(`Stopped at ${i} and seeking to ${l.start(0)}`),this.resetTimeUpdate_(),this.skipTheGap_(i),!0):!1}afterSeekableWindow_(e,i,r,a=!1){if(!e.length)return!1;let o=e.end(e.length-1)+ji;const l=!r.endList,u=typeof r.partTargetDuration=="number";return l&&(u||a)&&(o=e.end(e.length-1)+r.targetDuration*3),i>o}beforeSeekableWindow_(e,i){return!!(e.length&&e.start(0)>0&&i<e.start(0)-this.liveRangeSafeTimeDelta)}videoUnderflow_({videoBuffered:e,audioBuffered:i,currentTime:r}){if(!e)return;let a;if(e.length&&i.length){const o=Wn(e,r-3),l=Wn(e,r),u=Wn(i,r);u.length&&!l.length&&o.length&&(a={start:o.end(0),end:u.end(0)})}else js(e,r).length||(a=this.gapFromVideoUnderflow_(e,r));return a?(this.logger_(`Encountered a gap in video from ${a.start} to ${a.end}. Seeking to current time ${r}`),!0):!1}skipTheGap_(e){const i=this.tech_.buffered(),r=this.tech_.currentTime(),a=js(i,r);if(this.resetTimeUpdate_(),a.length===0||r!==e)return;this.logger_("skipTheGap_:","currentTime:",r,"scheduled currentTime:",e,"nextRange start:",a.start(0)),this.tech_.setCurrentTime(a.start(0)+qi);const o={gapInfo:{from:r,to:a.start(0)}};this.playlistController_.trigger({type:"gapjumped",metadata:o}),this.tech_.trigger({type:"usage",name:"vhs-gap-skip"})}gapFromVideoUnderflow_(e,i){const r=qx(e);for(let a=0;a<r.length;a++){const o=r.start(a),l=r.end(a);if(i-o<4&&i-o>2)return{start:o,end:l}}return null}}const oS={errorInterval:30,getSource(s){const i=this.tech({IWillNotUseThisInPlugins:!0}).currentSource_||this.currentSource();return s(i)}},rp=function(s,e){let i=0,r=0;const a=it(oS,e);s.ready(()=>{s.trigger({type:"usage",name:"vhs-error-reload-initialized"})});const o=function(){r&&s.currentTime(r)},l=function(g){g!=null&&(r=s.duration()!==1/0&&s.currentTime()||0,s.one("loadedmetadata",o),s.src(g),s.trigger({type:"usage",name:"vhs-error-reload"}),s.play())},u=function(){if(Date.now()-i<a.errorInterval*1e3){s.trigger({type:"usage",name:"vhs-error-reload-canceled"});return}if(!a.getSource||typeof a.getSource!="function"){ne.log.error("ERROR: reloadSourceOnError - The option getSource must be a function!");return}return i=Date.now(),a.getSource.call(s,l)},d=function(){s.off("loadedmetadata",o),s.off("error",u),s.off("dispose",d)},f=function(g){d(),rp(s,g)};s.on("error",u),s.on("dispose",d),s.reloadSourceOnError=f},lS=function(s){rp(this,s)};var sp="3.17.3",uS="7.1.0",cS="1.3.1",dS="7.2.0",hS="4.0.2";const ft={PlaylistLoader:Yn,Playlist:ai,utils:_C,STANDARD_PLAYLIST_SELECTOR:zd,INITIAL_PLAYLIST_SELECTOR:r5,lastBandwidthSelector:zd,movingAverageBandwidthSelector:i5,comparePlaylistBandwidth:pu,comparePlaylistResolution:t5,xhr:Of()};Object.keys(At).forEach(s=>{Object.defineProperty(ft,s,{get(){return ne.log.warn(`using Vhs.${s} is UNSAFE be sure you know what you are doing`),At[s]},set(e){if(ne.log.warn(`using Vhs.${s} is UNSAFE be sure you know what you are doing`),typeof e!="number"||e<0){ne.log.warn(`value of Vhs.${s} must be greater than or equal to 0`);return}At[s]=e}})});const ap="videojs-vhs",op=function(s,e){const i=e.media();let r=-1;for(let a=0;a<s.length;a++)if(s[a].id===i.id){r=a;break}s.selectedIndex_=r,s.trigger({selectedIndex:r,type:"change"})},fS=function(s,e){e.representations().forEach(i=>{s.addQualityLevel(i)}),op(s,e.playlists)};ft.canPlaySource=function(){return ne.log.warn("VHS is no longer a tech. Please remove it from your player's techOrder.")};const pS=(s,e,i)=>{if(!s)return s;let r={};e&&e.attributes&&e.attributes.CODECS&&(r=as(Fi(e.attributes.CODECS))),i&&i.attributes&&i.attributes.CODECS&&(r.audio=i.attributes.CODECS);const a=sr(r.video),o=sr(r.audio),l={};for(const u in s)l[u]={},o&&(l[u].audioContentType=o),a&&(l[u].videoContentType=a),e.contentProtection&&e.contentProtection[u]&&e.contentProtection[u].pssh&&(l[u].pssh=e.contentProtection[u].pssh),typeof s[u]=="string"&&(l[u].url=s[u]);return it(s,l)},mS=(s,e)=>s.reduce((i,r)=>{if(!r.contentProtection)return i;const a=e.reduce((o,l)=>{const u=r.contentProtection[l];return u&&u.pssh&&(o[l]={pssh:u.pssh}),o},{});return Object.keys(a).length&&i.push(a),i},[]),gS=({player:s,sourceKeySystems:e,audioMedia:i,mainPlaylists:r})=>{if(!s.eme.initializeMediaKeys)return Promise.resolve();const a=i?r.concat([i]):r,o=mS(a,Object.keys(e)),l=[],u=[];return o.forEach(d=>{u.push(new Promise((f,g)=>{s.tech_.one("keysessioncreated",f)})),l.push(new Promise((f,g)=>{s.eme.initializeMediaKeys({keySystems:d},y=>{if(y){g(y);return}f()})}))}),Promise.race([Promise.all(l),Promise.race(u)])},_S=({player:s,sourceKeySystems:e,media:i,audioMedia:r})=>{const a=pS(e,i,r);return a?(s.currentSource().keySystems=a,a&&!s.eme?(ne.log.warn("DRM encrypted source cannot be decrypted without a DRM plugin"),!1):!0):!1},lp=()=>{if(!W.localStorage)return null;const s=W.localStorage.getItem(ap);if(!s)return null;try{return JSON.parse(s)}catch{return null}},yS=s=>{if(!W.localStorage)return!1;let e=lp();e=e?it(e,s):s;try{W.localStorage.setItem(ap,JSON.stringify(e))}catch{return!1}return e},vS=s=>s.toLowerCase().indexOf("data:application/vnd.videojs.vhs+json,")===0?JSON.parse(s.substring(s.indexOf(",")+1)):s,up=(s,e)=>{s._requestCallbackSet||(s._requestCallbackSet=new Set),s._requestCallbackSet.add(e)},cp=(s,e)=>{s._responseCallbackSet||(s._responseCallbackSet=new Set),s._responseCallbackSet.add(e)},dp=(s,e)=>{s._requestCallbackSet&&(s._requestCallbackSet.delete(e),s._requestCallbackSet.size||delete s._requestCallbackSet)},hp=(s,e)=>{s._responseCallbackSet&&(s._responseCallbackSet.delete(e),s._responseCallbackSet.size||delete s._responseCallbackSet)};ft.supportsNativeHls=(function(){if(!pe||!pe.createElement)return!1;const s=pe.createElement("video");return ne.getTech("Html5").isSupported()?["application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","application/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"].some(function(i){return/maybe|probably/i.test(s.canPlayType(i))}):!1})();ft.supportsNativeDash=(function(){return!pe||!pe.createElement||!ne.getTech("Html5").isSupported()?!1:/maybe|probably/i.test(pe.createElement("video").canPlayType("application/dash+xml"))})();ft.supportsTypeNatively=s=>s==="hls"?ft.supportsNativeHls:s==="dash"?ft.supportsNativeDash:!1;ft.isSupported=function(){return ne.log.warn("VHS is no longer a tech. Please remove it from your player's techOrder.")};ft.xhr.onRequest=function(s){up(ft.xhr,s)};ft.xhr.onResponse=function(s){cp(ft.xhr,s)};ft.xhr.offRequest=function(s){dp(ft.xhr,s)};ft.xhr.offResponse=function(s){hp(ft.xhr,s)};const TS=ne.getComponent("Component");class fp extends TS{constructor(e,i,r){if(super(i,r.vhs),typeof r.initialBandwidth=="number"&&(this.options_.bandwidth=r.initialBandwidth),this.logger_=bi("VhsHandler"),i.options_&&i.options_.playerId){const a=ne.getPlayer(i.options_.playerId);this.player_=a}if(this.tech_=i,this.source_=e,this.stats={},this.ignoreNextSeekingEvent_=!1,this.setOptions_(),this.options_.overrideNative&&i.overrideNativeAudioTracks&&i.overrideNativeVideoTracks)i.overrideNativeAudioTracks(!0),i.overrideNativeVideoTracks(!0);else if(this.options_.overrideNative&&(i.featuresNativeVideoTracks||i.featuresNativeAudioTracks))throw new Error("Overriding native VHS requires emulated tracks. See https://git.io/vMpjB");this.on(pe,["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],a=>{const o=pe.fullscreenElement||pe.webkitFullscreenElement||pe.mozFullScreenElement||pe.msFullscreenElement;o&&o.contains(this.tech_.el())?this.playlistController_.fastQualityChange_():this.playlistController_.checkABR_()}),this.on(this.tech_,"seeking",function(){if(this.ignoreNextSeekingEvent_){this.ignoreNextSeekingEvent_=!1;return}this.setCurrentTime(this.tech_.currentTime())}),this.on(this.tech_,"error",function(){this.tech_.error()&&this.playlistController_&&this.playlistController_.pauseLoading()}),this.on(this.tech_,"play",this.play)}setOptions_(e={}){if(this.options_=it(this.options_,e),this.options_.withCredentials=this.options_.withCredentials||!1,this.options_.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions!==!1,this.options_.useDevicePixelRatio=this.options_.useDevicePixelRatio||!1,this.options_.usePlayerObjectFit=this.options_.usePlayerObjectFit||!1,this.options_.useBandwidthFromLocalStorage=typeof this.source_.useBandwidthFromLocalStorage<"u"?this.source_.useBandwidthFromLocalStorage:this.options_.useBandwidthFromLocalStorage||!1,this.options_.useForcedSubtitles=this.options_.useForcedSubtitles||!1,this.options_.useNetworkInformationApi=typeof this.options_.useNetworkInformationApi<"u"?this.options_.useNetworkInformationApi:!0,this.options_.useDtsForTimestampOffset=this.options_.useDtsForTimestampOffset||!1,this.options_.customTagParsers=this.options_.customTagParsers||[],this.options_.customTagMappers=this.options_.customTagMappers||[],this.options_.cacheEncryptionKeys=this.options_.cacheEncryptionKeys||!1,this.options_.llhls=this.options_.llhls!==!1,this.options_.bufferBasedABR=this.options_.bufferBasedABR||!1,typeof this.options_.playlistExclusionDuration!="number"&&(this.options_.playlistExclusionDuration=60),typeof this.options_.bandwidth!="number"&&this.options_.useBandwidthFromLocalStorage){const r=lp();r&&r.bandwidth&&(this.options_.bandwidth=r.bandwidth,this.tech_.trigger({type:"usage",name:"vhs-bandwidth-from-local-storage"})),r&&r.throughput&&(this.options_.throughput=r.throughput,this.tech_.trigger({type:"usage",name:"vhs-throughput-from-local-storage"}))}typeof this.options_.bandwidth!="number"&&(this.options_.bandwidth=At.INITIAL_BANDWIDTH),this.options_.enableLowInitialPlaylist=this.options_.enableLowInitialPlaylist&&this.options_.bandwidth===At.INITIAL_BANDWIDTH,["withCredentials","useDevicePixelRatio","usePlayerObjectFit","customPixelRatio","limitRenditionByPlayerDimensions","bandwidth","customTagParsers","customTagMappers","cacheEncryptionKeys","playlistSelector","initialPlaylistSelector","bufferBasedABR","liveRangeSafeTimeDelta","llhls","useForcedSubtitles","useNetworkInformationApi","useDtsForTimestampOffset","exactManifestTimings","leastPixelDiffSelector"].forEach(r=>{typeof this.source_[r]<"u"&&(this.options_[r]=this.source_[r])}),this.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions,this.useDevicePixelRatio=this.options_.useDevicePixelRatio,this.usePlayerObjectFit=this.options_.usePlayerObjectFit;const i=this.options_.customPixelRatio;typeof i=="number"&&i>=0&&(this.customPixelRatio=i)}setOptions(e={}){this.setOptions_(e)}src(e,i){if(!e)return;this.setOptions_(),this.options_.src=vS(this.source_.src),this.options_.tech=this.tech_,this.options_.externVhs=ft,this.options_.sourceType=Bh(i),this.options_.seekTo=o=>{this.tech_.setCurrentTime(o)},this.options_.player_=this.player_,this.playlistController_=new iS(this.options_);const r=it({liveRangeSafeTimeDelta:ji},this.options_,{seekable:()=>this.seekable(),media:()=>this.playlistController_.media(),playlistController:this.playlistController_});this.playbackWatcher_=new aS(r),this.attachStreamingEventListeners_(),this.playlistController_.on("error",()=>{const o=ne.players[this.tech_.options_.playerId];let l=this.playlistController_.error;typeof l=="object"&&!l.code?l.code=3:typeof l=="string"&&(l={message:l,code:3}),o.error(l)});const a=this.options_.bufferBasedABR?ft.movingAverageBandwidthSelector(.55):ft.STANDARD_PLAYLIST_SELECTOR;this.playlistController_.selectPlaylist=this.selectPlaylist?this.selectPlaylist.bind(this):a.bind(this),this.playlistController_.selectInitialPlaylist=ft.INITIAL_PLAYLIST_SELECTOR.bind(this),this.playlists=this.playlistController_.mainPlaylistLoader_,this.mediaSource=this.playlistController_.mediaSource,Object.defineProperties(this,{selectPlaylist:{get(){return this.playlistController_.selectPlaylist},set(o){this.playlistController_.selectPlaylist=o.bind(this)}},throughput:{get(){return this.playlistController_.mainSegmentLoader_.throughput.rate},set(o){this.playlistController_.mainSegmentLoader_.throughput.rate=o,this.playlistController_.mainSegmentLoader_.throughput.count=1}},bandwidth:{get(){let o=this.playlistController_.mainSegmentLoader_.bandwidth;const l=W.navigator.connection||W.navigator.mozConnection||W.navigator.webkitConnection,u=1e7;if(this.options_.useNetworkInformationApi&&l){const d=l.downlink*1e3*1e3;d>=u&&o>=u?o=Math.max(o,d):o=d}return o},set(o){this.playlistController_.mainSegmentLoader_.bandwidth=o,this.playlistController_.mainSegmentLoader_.throughput={rate:0,count:0}}},systemBandwidth:{get(){const o=1/(this.bandwidth||1);let l;return this.throughput>0?l=1/this.throughput:l=0,Math.floor(1/(o+l))},set(){ne.log.error('The "systemBandwidth" property is read-only')}}}),this.options_.bandwidth&&(this.bandwidth=this.options_.bandwidth),this.options_.throughput&&(this.throughput=this.options_.throughput),Object.defineProperties(this.stats,{bandwidth:{get:()=>this.bandwidth||0,enumerable:!0},mediaRequests:{get:()=>this.playlistController_.mediaRequests_()||0,enumerable:!0},mediaRequestsAborted:{get:()=>this.playlistController_.mediaRequestsAborted_()||0,enumerable:!0},mediaRequestsTimedout:{get:()=>this.playlistController_.mediaRequestsTimedout_()||0,enumerable:!0},mediaRequestsErrored:{get:()=>this.playlistController_.mediaRequestsErrored_()||0,enumerable:!0},mediaTransferDuration:{get:()=>this.playlistController_.mediaTransferDuration_()||0,enumerable:!0},mediaBytesTransferred:{get:()=>this.playlistController_.mediaBytesTransferred_()||0,enumerable:!0},mediaSecondsLoaded:{get:()=>this.playlistController_.mediaSecondsLoaded_()||0,enumerable:!0},mediaAppends:{get:()=>this.playlistController_.mediaAppends_()||0,enumerable:!0},mainAppendsToLoadedData:{get:()=>this.playlistController_.mainAppendsToLoadedData_()||0,enumerable:!0},audioAppendsToLoadedData:{get:()=>this.playlistController_.audioAppendsToLoadedData_()||0,enumerable:!0},appendsToLoadedData:{get:()=>this.playlistController_.appendsToLoadedData_()||0,enumerable:!0},timeToLoadedData:{get:()=>this.playlistController_.timeToLoadedData_()||0,enumerable:!0},buffered:{get:()=>An(this.tech_.buffered()),enumerable:!0},currentTime:{get:()=>this.tech_.currentTime(),enumerable:!0},currentSource:{get:()=>this.tech_.currentSource_,enumerable:!0},currentTech:{get:()=>this.tech_.name_,enumerable:!0},duration:{get:()=>this.tech_.duration(),enumerable:!0},main:{get:()=>this.playlists.main,enumerable:!0},playerDimensions:{get:()=>this.tech_.currentDimensions(),enumerable:!0},seekable:{get:()=>An(this.tech_.seekable()),enumerable:!0},timestamp:{get:()=>Date.now(),enumerable:!0},videoPlaybackQuality:{get:()=>this.tech_.getVideoPlaybackQuality(),enumerable:!0}}),this.tech_.one("canplay",this.playlistController_.setupFirstPlay.bind(this.playlistController_)),this.tech_.on("bandwidthupdate",()=>{this.options_.useBandwidthFromLocalStorage&&yS({bandwidth:this.bandwidth,throughput:Math.round(this.throughput)})}),this.playlistController_.on("selectedinitialmedia",()=>{sS(this)}),this.playlistController_.sourceUpdater_.on("createdsourcebuffers",()=>{this.setupEme_()}),this.on(this.playlistController_,"progress",function(){this.tech_.trigger("progress")}),this.on(this.playlistController_,"firstplay",function(){this.ignoreNextSeekingEvent_=!0}),this.setupQualityLevels_(),this.tech_.el()&&(this.mediaSourceUrl_=W.URL.createObjectURL(this.playlistController_.mediaSource),(ne.browser.IS_ANY_SAFARI||ne.browser.IS_IOS)&&this.options_.overrideNative&&this.options_.sourceType==="hls"&&typeof this.tech_.addSourceElement=="function"?(this.tech_.addSourceElement(this.mediaSourceUrl_),this.tech_.addSourceElement(this.source_.src)):this.tech_.src(this.mediaSourceUrl_))}createKeySessions_(){const e=this.playlistController_.mediaTypes_.AUDIO.activePlaylistLoader;this.logger_("waiting for EME key session creation"),gS({player:this.player_,sourceKeySystems:this.source_.keySystems,audioMedia:e&&e.media(),mainPlaylists:this.playlists.main.playlists}).then(()=>{this.logger_("created EME key session"),this.playlistController_.sourceUpdater_.initializedEme()}).catch(i=>{this.logger_("error while creating EME key session",i),this.player_.error({message:"Failed to initialize media keys for EME",code:3})})}handleWaitingForKey_(){this.logger_("waitingforkey fired, attempting to create any new key sessions"),this.createKeySessions_()}setupEme_(){const e=this.playlistController_.mediaTypes_.AUDIO.activePlaylistLoader,i=_S({player:this.player_,sourceKeySystems:this.source_.keySystems,media:this.playlists.media(),audioMedia:e&&e.media()});if(this.player_.tech_.on("keystatuschange",r=>{this.playlistController_.updatePlaylistByKeyStatus(r.keyId,r.status)}),this.handleWaitingForKey_=this.handleWaitingForKey_.bind(this),this.player_.tech_.on("waitingforkey",this.handleWaitingForKey_),!i){this.playlistController_.sourceUpdater_.initializedEme();return}this.createKeySessions_()}setupQualityLevels_(){const e=ne.players[this.tech_.options_.playerId];!e||!e.qualityLevels||this.qualityLevels_||(this.qualityLevels_=e.qualityLevels(),this.playlistController_.on("selectedinitialmedia",()=>{fS(this.qualityLevels_,this)}),this.playlists.on("mediachange",()=>{op(this.qualityLevels_,this.playlists)}))}static version(){return{"@videojs/http-streaming":sp,"mux.js":uS,"mpd-parser":cS,"m3u8-parser":dS,"aes-decrypter":hS}}version(){return this.constructor.version()}canChangeType(){return ep.canChangeType()}play(){this.playlistController_.play()}setCurrentTime(e){this.playlistController_.setCurrentTime(e)}duration(){return this.playlistController_.duration()}seekable(){return this.playlistController_.seekable()}dispose(){this.playbackWatcher_&&this.playbackWatcher_.dispose(),this.playlistController_&&this.playlistController_.dispose(),this.qualityLevels_&&this.qualityLevels_.dispose(),this.tech_&&this.tech_.vhs&&delete this.tech_.vhs,this.mediaSourceUrl_&&W.URL.revokeObjectURL&&(W.URL.revokeObjectURL(this.mediaSourceUrl_),this.mediaSourceUrl_=null),this.tech_&&this.tech_.off("waitingforkey",this.handleWaitingForKey_),super.dispose()}convertToProgramTime(e,i){return SC({playlist:this.playlistController_.media(),time:e,callback:i})}seekToProgramTime(e,i,r=!0,a=2){return Rf({programTime:e,playlist:this.playlistController_.media(),retryCount:a,pauseAfterSeek:r,seekTo:this.options_.seekTo,tech:this.options_.tech,callback:i})}setupXhrHooks_(){this.xhr.onRequest=e=>{up(this.xhr,e)},this.xhr.onResponse=e=>{cp(this.xhr,e)},this.xhr.offRequest=e=>{dp(this.xhr,e)},this.xhr.offResponse=e=>{hp(this.xhr,e)},this.player_.trigger("xhr-hooks-ready")}attachStreamingEventListeners_(){const e=["seekablerangeschanged","bufferedrangeschanged","contentsteeringloadstart","contentsteeringloadcomplete","contentsteeringparsed"],i=["gapjumped","playedrangeschanged"];e.forEach(r=>{this.playlistController_.on(r,a=>{this.player_.trigger(bt({},a))})}),i.forEach(r=>{this.playbackWatcher_.on(r,a=>{this.player_.trigger(bt({},a))})})}}const Ca={name:"videojs-http-streaming",VERSION:sp,canHandleSource(s,e={}){const i=it(ne.options,e);return!i.vhs.experimentalUseMMS&&!Kr("avc1.4d400d,mp4a.40.2",!1)?!1:Ca.canPlayType(s.type,i)},handleSource(s,e,i={}){const r=it(ne.options,i);return e.vhs=new fp(s,e,r),e.vhs.xhr=Of(),e.vhs.setupXhrHooks_(),e.vhs.src(s.src,s.type),e.vhs},canPlayType(s,e){const i=Bh(s);if(!i)return"";const r=Ca.getOverrideNative(e);return!ft.supportsTypeNatively(i)||r?"maybe":""},getOverrideNative(s={}){const{vhs:e={}}=s,i=!(ne.browser.IS_ANY_SAFARI||ne.browser.IS_IOS),{overrideNative:r=i}=e;return r}},bS=()=>Kr("avc1.4d400d,mp4a.40.2",!0);bS()&&ne.getTech("Html5").registerSourceHandler(Ca,0);ne.VhsHandler=fp;ne.VhsSourceHandler=Ca;ne.Vhs=ft;ne.use||ne.registerComponent("Vhs",ft);ne.options.vhs=ne.options.vhs||{};(!ne.getPlugin||!ne.getPlugin("reloadSourceOnError"))&&ne.registerPlugin("reloadSourceOnError",lS);const xS="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAB4AAAAQ4AQMAAADSHVMAAAAAAXNSR0IB2cksfwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAANQTFRFAAAAp3o92gAAAAF0Uk5TAEDm2GYAAASYSURBVHic7c8BDQAgDMAw7t80Lk5SVgXbnM/M64BtDesa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNaxrWNewrmFdw7qGdQ3rGtY1rGtY17CuYV3DuoZ1Desa1jWsa1jXsK5hXcO6hnUN6xrWNay7Fz0EOVPDeGwAAAAASUVORK5CYII=",CS={class:"o-meeting-playback-video"},SS={key:0,class:"poster-title"},ES=n.defineComponent({__name:"OMeetingPlaybackVideo",props:{src:{default:""},vtt:{default:""},captions:{default:()=>[]},poster:{},posterTitle:{},instance:{},trackIdx:{}},emits:["getDuration","getInstance","setTrackIdx"],setup(s,{expose:e,emit:i}){const r=s,a=n.ref(),o=n.ref(),l=n.ref(),u=i,d=n.ref(!1),f=()=>{d.value=!1},g=(T,w=!1)=>{var I,K;const F=r.instance;if(!F)return;const P=(I=T.activeCues)==null?void 0:I[0];if(a.value&&clearInterval(a.value),P){P.text=((K=P==null?void 0:P.text)==null?void 0:K.replace(/\[(SPEAKER_)\d+]: /g,""))||"";const q=P.text.split(`
|
|
224
|
+
`),M=q.length,N=P.endTime-P.startTime,J=parseFloat((N/M).toFixed(3));let b=0;if(w){const j=(F.currentTime()-P.startTime)/(P.endTime-P.startTime);for(;(b+1)/M<j;)b++}b<M?P.text=q.length?q[b]:P==null?void 0:P.text:P.text=q.length?q[0]:P==null?void 0:P.text;let C=J*1e3;const U=()=>{a.value=setInterval(()=>{T.mode="hidden",b++,b>q.length-1?clearInterval(a.value):b===q.length-1?(P.text=q[b],clearInterval(a.value),C=J*(M-b)*1e3,U()):P.text=q[b],T.mode="showing"},C)};U()}},y=n.ref([]);n.watch(()=>y.value,T=>{const w=r.instance;if(w){const F=w.textTracks();for(let P=0;P<F.length;P++)F[P].kind==="subtitles"&&(g(F[P],!0),F[P].mode=T.length?"showing":"hidden")}},{deep:!0});const E=n.ref(!1),x=n.ref("init"),B=async()=>{if(!r.src)return;const T=ne("playerId",{controls:!0,autoplay:!1,preload:"auto",fluid:!0,poster:r.poster||xS,playbackRates:[.5,.75,1,1.25,1.5,2],controlBar:{skipButtons:{backward:5,forward:5},children:{playToggle:!0,SkipBackward:{backward:5},skipForward:{forward:5},currentTimeDisplay:!0,timeDivider:!0,durationDisplay:!0,progressControl:!0,PlaybackRateMenuButton:!0,volumePanel:{inline:!1},FullscreenToggle:!0}}});u("getInstance",T),T.src(r.src),T.addRemoteTextTrack({kind:"subtitles",src:r.vtt,srclang:"zh",label:"中文",default:!1}),E.value=!0;class w extends ne.getComponent("Button"){constructor(I,K){super(I,K),this.addClass("vjs-subtitle-toggle-button","vjs-subtitle-hidden"),this.controlText("Toggle Subtitles")}buildCSSClass(){return`vjs-subtitle-toggle-button ${super.buildCSSClass()}`}handleClick(){const I=this.player().textTracks();for(let K=0;K<I.length;K++)I[K].kind==="subtitles"&&(g(I[K],!0),I[K].mode=I[K].mode==="showing"?"hidden":"showing",I[K].mode==="showing"?(this.removeClass("vjs-subtitle-hidden"),this.addClass("vjs-subtitle-showing")):(this.removeClass("vjs-subtitle-showing"),this.addClass("vjs-subtitle-hidden")))}}r.vtt&&(ne.registerComponent("SubtitleToggleButton",w),T.controlBar.children_.some(P=>P.name_==="SubtitleToggleButton")||T.controlBar.addChild("SubtitleToggleButton",{},8)),(T==null?void 0:T.textTracks().tracks_).forEach(P=>{P==null||P.addEventListener("cuechange",()=>{g(P)})}),T.on("play",()=>{x.value="playing"}),T.on("timeupdate",()=>{const P=T.currentTime()||0,I=r.captions.findIndex(K=>Jo(K.start_time)>P);u("setTrackIdx",I)}),T.one("loadedmetadata",()=>{u("getDuration",T.duration())}),n.nextTick(()=>{const P=document.getElementsByClassName("o-meeting-playback-video")[0];o.value=P.offsetHeight}),l.value=T};return n.onMounted(()=>{B(),document.addEventListener("click",f)}),n.watch(()=>r.src,()=>{B()}),n.onUnmounted(()=>{var T;(T=r==null?void 0:r.instance)==null||T.dispose(),document.removeEventListener("click",f)}),e({changeTime:T=>{var w;(w=l.value)==null||w.currentTime(T)}}),(T,w)=>(n.openBlock(),n.createElementBlock("div",CS,[n.createElementVNode("div",{class:n.normalizeClass(["video-placeholder",{loaded:E.value,"no-poster":!s.poster,[x.value]:!0}])},[w[0]||(w[0]=n.createElementVNode("video",{class:"video-js",id:"playerId"},null,-1)),s.posterTitle?(n.openBlock(),n.createElementBlock("div",SS,n.toDisplayString(s.posterTitle),1)):n.createCommentVNode("",!0)],2)]))}}),kS={class:"o-meeting-playback"},wS={class:"video-header"},DS={class:"video-title"},AS={class:"video-content"},IS={class:"info-wrapper"},NS={class:"tab-content"},OS={key:0,class:"base-info"},BS={class:"info-item"},LS={class:"info-item"},PS={class:"info-item"},MS={class:"info-item"},RS={key:1,class:"subject-list"},VS={class:"subject-title"},FS={key:0,class:"subject-progress"},$S=["data-start","data-end"],rh=n.defineComponent({__name:"OMeetingPlayback",props:{dates:{default:()=>[]},detail:{default:()=>({})},data:{default:()=>({})}},emits:["change-date"],setup(s,{emit:e}){const i=s,r=e,a=n.ref(null),o=H=>{a.value=H},l=n.ref(0),u=H=>{l.value=H},d=n.ref([]),f=async H=>{const G=await(await fetch(H)).json();d.value=(G.segments||[]).map(Z=>{const te=nT(Z.speaker);return{...Z,contentHtml:Z.content,speakerIdx:te,speakerLabel:`${t("meeting.speaker")}${te}`}})},g=n.ref([]),y=H=>Cy[H%3],E=n.ref(0),x=H=>{E.value=H},B=n.ref(),T=n.ref(""),w=n.ref([0,0]);function F(H,V){const G=V.getBoundingClientRect(),te=(H.clientX-G.left)/G.width;return w.value[1]=`${V.offsetTop+V.parentElement.offsetTop}px`,w.value[0]=`${te*100}%`,te*E.value}const P=H=>{let V=H;for(;V&&V.className!=="subject-progress";)V=V.parentElement;return V},I=H=>{let V=P(H.target);V&&(T.value=rT(F(H,V)))},K=()=>{T.value=""},q=H=>{var G;let V=P(H.target);V&&((G=B.value)==null||G.changeTime(F(H,V)))},M=async H=>{const G=await(await fetch(H)).json();g.value=(G||[]).map(Z=>({...Z,startTime:Jo(Z.startTime),endTime:Jo(Z.endTime)}))},N=n.ref("info"),J=n.computed(()=>{const H=[{label:t("meeting.baseInfo"),value:"info"}];return g.value.length&&H.push({label:t("meeting.subject"),value:"subject"}),H}),b=()=>{i.data&&(i.data.textJson&&f(i.data.textJson),i.data.topicJson&&M(i.data.topicJson))};n.watchEffect(()=>{b()});const C=H=>{r("change-date",H)},U=n.ref(null),j=n.ref("auto");let k=null,A=null;const $=()=>{U.value&&(j.value=`${U.value.offsetHeight}px`)},Q=()=>{cancelAnimationFrame(A),A=requestAnimationFrame($)};return n.onMounted(()=>{U.value&&(k=new ResizeObserver(Q),k.observe(U.value),$())}),n.onUnmounted(()=>{cancelAnimationFrame(A),k==null||k.disconnect()}),(H,V)=>{var G,Z,te,se,ue;return n.openBlock(),n.createElementBlock("div",kS,[n.createElementVNode("div",{class:"left-card card-wrapper",ref_key:"leftRef",ref:U},[n.createElementVNode("div",wS,[n.createElementVNode("div",DS,n.toDisplayString((G=s.detail)==null?void 0:G.topic)+"("+n.toDisplayString((Z=s.detail)==null?void 0:Z.date)+")",1),(te=s.dates)!=null&&te.length?(n.openBlock(),n.createBlock(n.unref(O.OSelect),{key:0,size:"large",clearable:!1,"model-value":(se=s.detail)==null?void 0:se.date,placeholder:H.t("meeting.selectDate"),onChange:C},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.dates,ce=>(n.openBlock(),n.createBlock(n.unref(O.OOption),{key:ce,value:ce,label:ce},null,8,["value","label"]))),128))]),_:1},8,["model-value","placeholder"])):n.createCommentVNode("",!0)]),n.createElementVNode("div",AS,[s.data?(n.openBlock(),n.createBlock(ES,{key:0,ref_key:"playerRef",ref:B,src:s.data.video,vtt:s.data.textVtt,poster:s.data.poster,captions:d.value,onGetDuration:x,instance:a.value,onGetInstance:o,trackIdx:l.value,onSetTrackIdx:u},null,8,["src","vtt","poster","captions","instance","trackIdx"])):n.createCommentVNode("",!0)]),n.createElementVNode("div",IS,[n.createVNode(n.unref(O.OTab),{modelValue:N.value,"onUpdate:modelValue":V[0]||(V[0]=ce=>N.value=ce)},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(J.value,ce=>(n.openBlock(),n.createBlock(n.unref(O.OTabPane),{key:ce.value,value:ce.value,label:ce.label},null,8,["value","label"]))),128))]),_:1},8,["modelValue"]),n.createElementVNode("div",NS,[N.value===J.value[0].value?(n.openBlock(),n.createElementBlock("div",OS,[n.createElementVNode("div",BS,[n.createElementVNode("span",null,n.toDisplayString(H.t("meeting.item1")),1),n.createElementVNode("span",null,n.toDisplayString(s.detail.sponsor),1)]),n.createElementVNode("div",LS,[n.createElementVNode("span",null,n.toDisplayString(H.t("meeting.item2")),1),n.createElementVNode("span",null,n.toDisplayString(s.detail.groupName),1)]),n.createElementVNode("div",PS,[n.createElementVNode("span",null,n.toDisplayString(H.t("meeting.item3")),1),n.createElementVNode("span",null,n.toDisplayString(s.detail.date)+" "+n.toDisplayString(s.detail.start)+"~"+n.toDisplayString(s.detail.end),1)]),n.createElementVNode("div",MS,[n.createElementVNode("span",null,n.toDisplayString(H.t("meeting.item4")),1),n.createElementVNode("span",null,n.toDisplayString(s.detail.agenda||"-"),1)])])):n.createCommentVNode("",!0),N.value===((ue=J.value[1])==null?void 0:ue.value)?(n.openBlock(),n.createElementBlock("div",RS,[T.value?(n.openBlock(),n.createElementBlock("div",{key:0,class:"mouse-current-time",style:n.normalizeStyle({top:w.value[1],left:w.value[0]})},n.toDisplayString(T.value),5)):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(g.value,(ce,de)=>(n.openBlock(),n.createElementBlock("div",{class:"subject-item",key:ce.title},[n.createElementVNode("div",VS,n.toDisplayString(ce.title),1),E.value?(n.openBlock(),n.createElementBlock("div",FS,[n.createElementVNode("div",{class:"subject-progress-item",onClick:q,onMousemove:I,onMouseleave:K,"data-start":ce.startTime,"data-end":ce.endTime,style:n.normalizeStyle({"--start":(ce.startTime<0?0:ce.startTime)/E.value,"--end":(ce.endTime>E.value?E.value:ce.endTime)/E.value,background:y(de)})},null,44,$S)])):n.createCommentVNode("",!0)]))),128))])):n.createCommentVNode("",!0)])])],512),n.createElementVNode("div",{class:"right-card card-wrapper",style:n.normalizeStyle({height:j.value})},[n.createVNode(gb,{captions:d.value,trackIdx:l.value,instance:a.value},null,8,["captions","trackIdx","instance"])],4)])}}}),US={version:"1.1",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"};function qS(s,e){return n.openBlock(),n.createElementBlock("svg",US,[...e[0]||(e[0]=[n.createElementVNode("path",{d:"M12.032 2.355c1.632 0 3.205 0.404 4.611 1.166 0.34 0.182 0.466 0.609 0.281 0.949s-0.609 0.463-0.949 0.281c-1.201-0.65-2.546-0.996-3.943-0.996-4.585 0-8.3 3.715-8.3 8.297 0 4.588 3.715 8.303 8.3 8.303s8.3-3.715 8.3-8.303c0-2.063-0.753-4.002-2.098-5.514-0.258-0.287-0.231-0.732 0.059-0.984 0.287-0.258 0.729-0.234 0.987 0.053 1.57 1.764 2.452 4.037 2.452 6.445 0 5.361-4.342 9.703-9.7 9.703s-9.7-4.342-9.7-9.703c0-5.355 4.342-9.697 9.7-9.697zM10.866 7.658c0-0.627 0.507-1.131 1.134-1.131s1.134 0.504 1.134 1.131c0 0.627-0.507 1.131-1.134 1.131s-1.134-0.504-1.134-1.131zM12.706 10.002c-0.044-0.346-0.337-0.609-0.691-0.609-0.387 0-0.7 0.311-0.703 0.697l-0.023 6.762 0.006 0.1c0.044 0.34 0.337 0.603 0.691 0.603 0.387 0.006 0.7-0.311 0.703-0.697l0.023-6.762-0.006-0.094z"},null,-1)])])}const jS={name:"components-icon-tips",render:qS},HS={class:"o-sig-meeting-aside"},zS={class:"month"},GS={class:"days"},WS=["onClick"],YS={class:"day-d"},XS={class:"day-c"},KS={class:"arrow-wrapper"},Gs=1,QS=n.defineComponent({__name:"OSigMeetingAside",props:{data:{},current:{},total:{},active:{},meetingDates:{},eventsDates:{}},emits:["click-date","change-month"],setup(s,{emit:e}){const i=s,r=e,a=l=>{r("click-date",l)},o=l=>{i.current+l>=i.total||i.current+l<0||r("change-month",l)};return(l,u)=>(n.openBlock(),n.createElementBlock("div",HS,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.data,(d,f)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:f},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(d,g=>(n.openBlock(),n.createElementBlock("div",{key:g.month,class:"month-item"},[n.createElementVNode("div",zS,n.toDisplayString(g.month.replace(/-/g,"/")),1),n.createElementVNode("div",GS,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(g.days,y=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["day-item",s.active===`${g.month}-${y}`&&"active"]),key:y,onClick:E=>a(`${g.month}-${y}`)},[n.createElementVNode("div",YS,n.toDisplayString(y),1),n.createElementVNode("div",XS,[s.meetingDates.includes(`${g.month}-${y}`)?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:0,style:n.normalizeStyle({zIndex:n.unref(ri)(n.unref(Ke).MEETING,"zIndex"),backgroundColor:n.unref(ri)(n.unref(Ke).MEETING,"color")})},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(n.unref(ri)(n.unref(Ke).MEETING,"icon"))))]),_:1},8,["style"])):n.createCommentVNode("",!0),s.eventsDates.includes(`${g.month}-${y}`)?(n.openBlock(),n.createBlock(n.unref(O.OIcon),{key:1,style:n.normalizeStyle({zIndex:n.unref(ri)(n.unref(Ke).EVENTS,"zIndex"),backgroundColor:n.unref(ri)(n.unref(Ke).EVENTS,"color")})},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(n.unref(ri)(n.unref(Ke).EVENTS,"icon"))))]),_:1},8,["style"])):n.createCommentVNode("",!0)])],10,WS))),128))])]))),128))],64))),128)),n.createElementVNode("div",KS,[n.createVNode(n.unref(O.OIcon),{onClick:u[0]||(u[0]=d=>o(0-Gs)),class:n.normalizeClass(s.current-Gs<0&&"disabled")},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconArrowLeft))]),_:1},8,["class"]),n.createVNode(n.unref(O.OIcon),{onClick:u[1]||(u[1]=d=>o(Gs)),class:n.normalizeClass(s.current+Gs>=s.total&&"disabled")},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconArrowRight))]),_:1},8,["class"])])]))}}),ZS={class:"o-sig-meeting-calendar"},JS={key:0,class:"meeting-card-header"},eE={key:0,class:"header-left"},tE={key:1,class:"date-select"},iE={class:"meeting-card-content"},nE={class:"list-content"},sh=n.defineComponent({__name:"OSigMeetingCalendar",props:{sigName:{},getMeetingListRequest:{},getDateListRequest:{},getEventsListRequest:{},dates:{}},setup(s){const e=s,{t:i}=Ue.useI18n(),{lePadV:r}=wt.useScreen(),a=n.ref(""),o=n.ref(!1),l=n.ref([]),u=n.computed(()=>r.value?100:5),d=n.ref(""),f=n.ref([]),g=n.ref([]),y=n.ref([]),E=n.ref(-1),x=C=>{T(C)},B=C=>{T(C)},T=async C=>{if(e.getMeetingListRequest)try{o.value=!0,a.value=Ee(C).format("YYYY-MM-DD");const U=await e.getMeetingListRequest(a.value,e.sigName);l.value=U.map(j=>({...j,time:`${j.start}-${j.end}`,date:j.date||a.value,type:Ke.MEETING}))}finally{o.value=!1,y.value.forEach(U=>{U.dates.includes(a.value)&&l.value.push(U)})}},w=async()=>{e.getDateListRequest&&(f.value=await e.getDateListRequest()),e.getEventsListRequest&&(y.value=await e.getEventsListRequest(),g.value=(y.value||[]).map(C=>C.dates).flat())},F=n.ref(Ke.ALL),P=()=>{w()};n.watch(()=>r.value,()=>{r.value&&P(Ke.ALL)});const I=C=>{const U=Ee(C).format("YYYY-MM-DD");return[U.slice(0,7),U.slice(8,10)]},K=n.computed(()=>{let C=[];return F.value===Ke.ALL?C=[...f.value||[],...g.value]:F.value===Ke.MEETING?C=f.value||[]:C=g.value,[...new Set(C)].sort((U,j)=>Ee(U).isAfter(Ee(j))?1:-1).map(U=>Ee(U).format("YYYY-MM-DD"))}),q=()=>{let C=K.value.find(U=>U===Ee().format("YYYY-MM-DD"));C||(C=K.value.find(U=>Ee(U).isAfter(Ee()))||[...K.value].reverse().find(U=>Ee().isAfter(Ee(U)))),d.value=C};n.watch(()=>K.value,C=>{C.length&&(q(),n.nextTick(()=>{T(d.value)}))});const M=n.computed(()=>{const C=K.value.reduce((A,$)=>{var V,G;const[Q,H]=I($);return A[Q]={count:(((V=A[Q])==null?void 0:V.count)||0)+1,days:[...((G=A[Q])==null?void 0:G.days)||[],H]},A},{}),U=Object.keys(C).map(A=>({...C[A],month:A})),j=[];let k=[];return U.forEach(A=>{for(;A.days.length;)if(!k.length)A.days.splice(0,6).forEach($=>{k.push({month:A.month,day:$})}),k.length>=5&&(j.push(k),k=[]);else{let $=k.length;$%2===1&&($+=1),A.days.length+k.length<=6?(A.days.splice(0,6).forEach(Q=>{k.push({month:A.month,day:Q})}),k.length>=5&&(j.push(k),k=[])):(A.days.splice(0,6-$).forEach(Q=>{k.push({month:A.month,day:Q})}),k.length>=5&&(j.push(k),k=[]))}}),k.length&&(j.push(k),k=[]),j}),N=n.computed(()=>M.value.map(C=>{const U=C.reduce((j,k)=>(j[k.month]=j[k.month]||[],j[k.month].push(k.day),j),{});return Object.keys(U).map(j=>({month:j,days:U[j]||[]}))})),J=()=>{M.value.length?(E.value=M.value.findIndex(C=>C.some(U=>d.value===`${U.month}-${U.day}`)),E.value===-1&&(E.value=M.value.findIndex(C=>C.some(U=>d.value.includes(U.month))))):E.value=-1};n.watch([()=>M.value,()=>d.value],()=>{J()},{deep:!0});const b=C=>{E.value+=C};return n.onMounted(()=>{w()}),(C,U)=>{const j=n.resolveComponent("ElOption"),k=n.resolveComponent("ElSelect");return n.openBlock(),n.createElementBlock("div",ZS,[n.unref(r)?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",JS,[d.value?(n.openBlock(),n.createElementBlock("div",eE,[n.createElementVNode("span",null,n.toDisplayString(n.unref(i)("meeting.latestMeeting")),1),n.createElementVNode("span",null,n.toDisplayString(n.unref(Ee)(d.value).format("YYYY/MM/DD")),1),n.createVNode(n.unref(O.OPopover),null,{target:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),{class:"tips"},{default:n.withCtx(()=>[n.createVNode(n.unref(jS))]),_:1})]),default:n.withCtx(()=>[n.createElementVNode("div",null,[n.createElementVNode("p",null,n.toDisplayString(n.unref(i)("meeting.detailHalfYearMeetings")),1)])]),_:1})])):n.createCommentVNode("",!0),n.createVNode(n.unref(O.OTab),{modelValue:F.value,"onUpdate:modelValue":U[0]||(U[0]=A=>F.value=A),onChange:P,line:!1},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(ta).slice(0,-1),A=>(n.openBlock(),n.createBlock(n.unref(O.OTabPane),{key:A.value,value:A.value},{nav:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(A.icon)))]),_:2},1024),n.createTextVNode(" "+n.toDisplayString(A.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])])),n.unref(r)&&K.value.length?(n.openBlock(),n.createElementBlock("div",tE,[n.createVNode(k,{modelValue:a.value,"onUpdate:modelValue":U[1]||(U[1]=A=>a.value=A),onChange:B},{label:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(i)("meeting.latestMeeting"))+" "+n.toDisplayString(a.value),1)]),default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(K.value,A=>(n.openBlock(),n.createBlock(j,{key:A,value:A,label:n.unref(Ee)(A).format("YYYY/MM/DD")},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])])):n.createCommentVNode("",!0),!n.unref(r)||n.unref(r)&&K.value.length?(n.openBlock(),n.createBlock(n.unref(O.ODivider),{key:2,class:"meeting-divider"})):n.createCommentVNode("",!0),n.createElementVNode("div",iE,[!n.unref(r)&&E.value!==-1?(n.openBlock(),n.createBlock(QS,{key:0,data:N.value.slice(E.value,E.value+1),meetingDates:F.value!==n.unref(Ke).EVENTS?f.value:[],eventsDates:F.value!==n.unref(Ke).MEETING?g.value:[],onClickDate:x,onChangeMonth:b,current:E.value,total:N.value.length,active:a.value},null,8,["data","meetingDates","eventsDates","current","total","active"])):n.createCommentVNode("",!0),n.createElementVNode("div",nE,[n.createVNode(wh,{list:l.value,rows:u.value},{empty:n.withCtx(()=>[n.renderSlot(C.$slots,"empty")]),_:3},8,["list","rows"])])])])}}}),rE={class:"o-my-meeting-calendar"},sE={class:"meeting-list"},aE={class:"list-calendar-mb"},oE={class:"list-calendar"},lE=["onClick"],uE={class:"date-cell-text"},cE={class:"list-body"},dE=["id"],hE={class:"item-header-left"},fE={class:"meeting-icon"},pE={class:"header-info"},mE={key:0},gE={class:"title-wrapper"},_E={class:"title-text"},yE={key:1,class:"tag-wrapper"},vE={class:"meeting-info"},TE={key:0,class:"item-header-right"},bE={class:"meeting-detail"},xE={key:0,class:"meeting-btn"},CE={key:0,class:"load-text"},SE={class:"dialog-content"},ah=n.defineComponent({__name:"OMyMeetingCalendar",props:{cancelSubMeetingRequest:{},deleteMeetingRequest:{},getMeetingListRequest:{}},emits:["edit"],setup(s,{emit:e}){const i=O.useMessage(null),r=n.ref(!1),a=n.ref(1),o=n.ref(50),l=n.ref(null),u=n.ref([]),d=n.ref([]),f=n.computed(()=>l.value===null||d.value.length<l.value),g=n.ref(!1),{t:y,locale:E}=Ue.useI18n(),x=n.computed(()=>E.value===Ue.Locales.EN),B=s,T=n.ref(!1),{isPhone:w}=wt.useScreen(),F=n.ref([]),P=e,I=n.ref(!1),K=n.ref(!1),q=n.ref(),M=n.ref(0),N=()=>{var fe;M.value=((fe=q.value)==null?void 0:fe.clientHeight)||0},J=async()=>{if(B.getMeetingListRequest&&!I.value)try{if(l.value>0&&(a.value-1)*o.value>l.value)return;if(!f.value&&w.value){Le("next-month");return}r.value=!0,I.value=!0;const fe=await B.getMeetingListRequest({page:a.value,size:o.value,order_by:"date",order_type:"asc",month:Ee(ke.value).format("YYYY-MM")}),ye=(fe.data||[]).map(_e=>{var Ht,Yi,Rt;const{is_cycle:je,date:we,start:_t,end:Mt,cycle_sub:Pi,cycle_start_date:Ye,cycle_end_date:xi,cycle_start:jt,cycle_end:Ci,cycle_type:yt,cycle_interval:ei,cycle_point:li}=_e;if(je){let Si="",S="";yt===mn&&(S=y("meeting.cycleDay")),yt===gn&&(ei>1?S=y("meeting.cycleWeek.other",[Xn(yt,li),ei]):S=y("meeting.cycleWeek.one",[Xn(yt,li)])),yt===nn&&(S=y("meeting.cycleMonth",[Xn(yt,li)])),Si=y("meeting.cycleMeetingText2",{startDate:Ye,endDate:xi,startTime:jt,endTime:Ci,cycleType:S});const D=(Ht=_e.obs_data)==null?void 0:Ht.filter(X=>X.text_video_url);return Pi.filter(X=>Ee(X.date).isBefore(Ee(ke.value).add(1,"month").format("YYYY-MM-01"))&&!Ee(X.date).isBefore(Ee(ke.value).format("YYYY-MM-01"))).map(({id:X,...re})=>({..._e,...re,timeRange:Si,dateRange:`${re.start}-${re.end}`,hasObsData:D.find(ge=>ge.sub_id===re.sub_id),time:`${re.start}-${re.end}`,isExpired:Ee(`${re.date} ${re.start}`).isBefore(Ee())}))}return[{..._e,dateRange:`${_t} - ${Mt}`,timeRange:`${_t} - ${Mt}`,hasObsData:((Rt=(Yi=_e.obs_data)==null?void 0:Yi.filter(Si=>Si.text_video_url))==null?void 0:Rt.length)>0,time:`${_t}-${Mt}`,isExpired:Ee(`${we} ${_t}`).isBefore(Ee())}]}).flat().filter(_e=>_e.date.slice(0,7)===hi(ke.value,"YYYY-MM-DD").slice(0,7));g.value?(d.value=fe.data||[],u.value=ye):a.value===1&&!w.value?(d.value=fe.data||[],u.value=ye):(d.value=[...d.value,...fe.data||[]],u.value=[...u.value,...ye]),u.value.sort((_e,je)=>_e.date===je.date?Xr(_e.start)>Xr(je.start)?1:-1:Ee(_e.date).isAfter(Ee(je.date))?1:-1),l.value=(fe==null?void 0:fe.total)||0,n.nextTick(()=>{Ve(),at.value&&!w.value&&k()})}finally{r.value=!1,I.value=!1,K.value=!1,g.value=!1}},b=Mn.useDebounceFn(()=>{f.value&&(w.value||(K.value=!0,a.value++,J()))},200),C=Mn.useDebounceFn(()=>{if(!f.value||!w.value)return;const fe=window.scrollY||window.pageYOffset,ye=window.innerHeight;document.documentElement.scrollHeight-(fe+ye)<=300&&!I.value&&(K.value=!0,a.value++,J())},200),U=fe=>{const ye=u.value.filter(_e=>_e.date===fe);return ye.length&&ye.every(_e=>_e.is_delete)},j=fe=>{const ye=fe.target;if(!ye)return;const _e=ye.scrollTop,je=ye.scrollHeight,we=ye.clientHeight;_e+we>=je&&b()},k=()=>{at.value.getContainerEl().addEventListener("scroll",j)},A=n.ref({}),$=(fe,ye)=>{fe&&ye&&(A.value[ye]=fe)},Q=async fe=>{await A.value[fe].copyInfo(),i.success({content:y("common.copySuccess")})},H=n.ref(!1),V=n.ref(null),G=fe=>{P("edit",fe,"whole")},Z=fe=>{V.value=fe,H.value=!0},te=async()=>{if(B.deleteMeetingRequest)try{T.value=!0,await B.deleteMeetingRequest(V.value.id),H.value=!1,i.success({content:`${y("meeting.meetingCancel",[V.value.topic])}`}),g.value=!0,J()}finally{T.value=!1}},se=n.ref(!1),ue=n.ref(""),ce=n.ref(null),de=[{label:y("meeting.meetingSingle"),value:"single"},{label:y("meeting.meetingCycle"),value:"whole"}],qe=n.ref("single"),De=(fe,ye)=>{fe.is_cycle?(ce.value=fe,ue.value=ye,se.value=!0):ye==="cancel"?Z(fe):G(fe)},Oe=()=>{se.value=!1,ce.value=null,ue.value="",qe.value="single"},We=async()=>{const fe=ce.value;if(ue.value==="cancel")try{if(T.value=!0,qe.value==="single"&&fe.is_cycle){if(!B.cancelSubMeetingRequest)return;await B.cancelSubMeetingRequest(fe.sub_id),i.success({content:`${y("meeting.meetingCancel",[fe.topic])}`})}else{if(!B.deleteMeetingRequest)return;await B.deleteMeetingRequest(fe.id),i.success({content:`${y("meeting.meetingCancel",[fe.topic])}`})}Oe(),g.value=!0,J()}finally{T.value=!1}else P("edit",fe,qe.value),Oe()},Me=n.ref(),Se=n.computed(()=>[...new Set(u.value.map(fe=>fe.date))].sort((fe,ye)=>Ee(fe).isBefore(Ee(ye))?-1:1)),me=n.computed(()=>[...new Set(u.value.filter(fe=>!fe.isExpired&&!fe.is_delete).map(fe=>fe.date))].sort((fe,ye)=>Ee(fe).isBefore(Ee(ye))?-1:1)),ke=n.ref(),Ve=()=>{var _e;const fe=me.value.find(je=>!Ee(je).isBefore(Ee(new Date).format("YYYY-MM-DD")));fe?ke.value=fe:ke.value||(ke.value=Ee().format("YYYY-MM-DD")),(_e=Me.value)==null||_e.pickDay(Ee(ke.value)),ke.value=Ee(ke.value).format("YYYY-MM-DD");const ye=u.value.find(je=>je.date===ke.value&&!je.isExpired&&!je.is_delete);ye&&(F.value=[ye.sub_id||ye.id])},be=(fe,ye)=>{var _e;(!ye||!((_e=fe.target)!=null&&_e.className.includes("date-cell-text")))&&(fe.stopPropagation(),fe.preventDefault())},Le=fe=>{Me.value&&(a.value=1,l.value=null,window.scrollTo({top:0,behavior:"smooth"}),Me.value.selectDate(fe),g.value=!0,n.nextTick(()=>{ke.value=Ee(Me.value.selectedDay).format("YYYY-MM-DD"),J()}))},ht=n.computed(()=>u.value.reduce((fe,ye)=>{if(fe.length){const _e=fe.at(-1);return _e.date===ye.date?_e.list.push(ye):fe.push({date:ye.date,list:[ye]}),fe}else return[{date:ye.date,list:[ye]}]},[])),Ze=fe=>Th[Ee(fe).day()],at=n.ref();n.watch(()=>ke.value,()=>{Pe(ke.value)});const Pe=fe=>{var je,we,_t;const ye=Ee(fe).format("YYYY-MM-DD"),_e=document.querySelector(`#group-title-${ye}`);_e&&(w.value?window.scrollTo({top:(((je=_e.parentElement)==null?void 0:je.offsetTop)||0)-52,behavior:"smooth"}):(_t=at.value)==null||_t.scrollTo({top:((we=_e.parentElement)==null?void 0:we.offsetTop)||0,behavior:"smooth"}))};n.onMounted(()=>{J(),window.addEventListener("scroll",C),window.addEventListener("resize",C),N(),window.addEventListener("resize",N)}),n.onUnmounted(()=>{var ye;window.removeEventListener("scroll",C),window.removeEventListener("resize",C),window.removeEventListener("resize",N);const fe=(ye=at.value)==null?void 0:ye.getContainerEl();fe==null||fe.removeEventListener("scroll",j)});const Fe=fe=>(fe=Ee(fe||void 0),x.value?fe.format("MMMM YYYY"):fe.format("YYYY MM月")),ot=n.computed(()=>[{id:"confirm",color:"primary",label:y("common.confirm"),variant:"solid",size:"large",round:"pill",loading:T.value,onClick:()=>{We()}},{id:"cancel",color:"primary",label:y("common.cancel"),variant:"outline",size:"large",round:"pill",onClick:()=>{Oe()}}]),Ct=n.computed(()=>[{id:"confirm",color:"primary",label:y("common.confirm"),variant:"solid",size:"large",round:"pill",loading:T.value,onClick:()=>{te()}},{id:"cancel",color:"primary",label:y("common.cancel"),variant:"outline",size:"large",round:"pill",onClick:()=>{H.value=!1}}]);return(fe,ye)=>(n.openBlock(),n.createElementBlock("div",rE,[n.createElementVNode("div",sE,[n.createElementVNode("div",aE,[n.createElementVNode("span",null,n.toDisplayString(Fe(ke.value)),1),n.createElementVNode("span",null,[n.createVNode(n.unref(O.OIcon),{onClick:ye[0]||(ye[0]=_e=>Le("prev-month"))},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronLeft))]),_:1}),n.createVNode(n.unref(O.OIcon),{onClick:ye[1]||(ye[1]=_e=>Le("next-month"))},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})])]),n.createElementVNode("div",oE,[n.createVNode(n.unref(et.ElCalendar),{ref_key:"calendarRef",ref:Me,modelValue:ke.value,"onUpdate:modelValue":ye[4]||(ye[4]=_e=>ke.value=_e)},{header:n.withCtx(()=>[n.createElementVNode("span",null,n.toDisplayString(Fe(ke.value)),1),n.createElementVNode("div",null,[n.createVNode(n.unref(O.OIcon),{onClick:ye[2]||(ye[2]=_e=>Le("prev-month"))},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronLeft))]),_:1}),n.createVNode(n.unref(O.OIcon),{onClick:ye[3]||(ye[3]=_e=>Le("next-month"))},{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})])]),"date-cell":n.withCtx(({data:_e})=>[n.createElementVNode("div",{onClick:je=>be(je,Se.value.includes(_e.day)),class:n.normalizeClass({"date-cell":!0,"is-selected":_e.isSelected,"is-today":n.unref(hi)(_e.day)===n.unref(hi)(),clickable:Se.value.includes(_e.day),expired:n.unref(Ee)(n.unref(hi)()).isAfter(n.unref(Ee)(_e.day)),"all-deleted":U(_e.day)})},[n.createElementVNode("div",uE,n.toDisplayString(Number(_e.day.split("-")[2])),1)],10,lE)]),_:1},8,["modelValue"])]),n.createElementVNode("div",{class:n.normalizeClass(["list-wrapper",u.value.length?"":"is-empty"])},[u.value.length?(n.openBlock(),n.createBlock(n.unref(O.OScroller),{key:0,ref_key:"scrollerRef",ref:at,onScrollend:n.unref(b),style:n.normalizeStyle({"--header-height":M.value}),class:"scroller-container","show-type":"hover"},{default:n.withCtx(()=>[n.createElementVNode("div",cE,[n.createVNode(n.unref(O.OCollapse),{modelValue:F.value,"onUpdate:modelValue":ye[7]||(ye[7]=_e=>F.value=_e),accordion:n.unref(w)},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(ht.value,(_e,je)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:_e.date},[je===0?(n.openBlock(),n.createElementBlock("div",{key:0,class:"list-month-change prev-month",onClick:ye[5]||(ye[5]=we=>Le("prev-month"))},[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconArrowLeft))]),_:1}),n.createElementVNode("span",null,n.toDisplayString(n.unref(y)("meeting.preMonth")),1)])):n.createCommentVNode("",!0),n.createElementVNode("div",{class:n.normalizeClass(["group-item",je===ht.value.length-1&&"last-item"])},[n.createElementVNode("div",{class:n.normalizeClass({"group-bar":!0,"is-active":n.unref(Ee)(ke.value).format("YYYY-MM-DD")===_e.date,"is-end":_e.list.every(we=>we.isExpired)})},[...ye[11]||(ye[11]=[n.createElementVNode("div",{class:"group-bar-line"},null,-1),n.createElementVNode("div",{class:"group-bar-dot"},null,-1)])],2),n.createElementVNode("div",{class:n.normalizeClass({"group-title":!0,"is-end":_e.list.every(we=>we.isExpired)}),id:`group-title-${n.unref(Ee)(new Date(_e.date)).format("YYYY-MM-DD")}`},n.toDisplayString(n.unref(Ee)(_e.date).format("MM/DD"))+" "+n.toDisplayString(Ze(_e.date)),11,dE),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(_e.list,(we,_t)=>(n.openBlock(),n.createBlock(n.unref(O.OCollapseItem),{key:we.sub_id||we.id,value:we.sub_id||we.id,class:n.normalizeClass({"last-item":je===ht.value.length-1&&_t===_e.list.length-1})},{title:n.withCtx(()=>[n.createElementVNode("div",hE,[n.createElementVNode("div",fE,[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(Al))]),_:1})]),n.createElementVNode("div",pE,[n.createElementVNode("div",{class:n.normalizeClass({"meeting-title":!0,"is-delete":we.is_delete,"is-end":we.isExpired})},[we.is_delete?(n.openBlock(),n.createElementBlock("div",mE,n.toDisplayString(n.unref(y)("meeting.meetingCancelled")),1)):n.createCommentVNode("",!0),n.createElementVNode("div",gE,[n.createElementVNode("div",_E,n.toDisplayString(we.topic),1)]),we.is_cycle?(n.openBlock(),n.createElementBlock("div",yE,[n.createVNode(n.unref(O.OTag),{color:"primary",variant:"outline"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.cycle")),1)]),_:1})])):n.createCommentVNode("",!0)],2),n.createElementVNode("div",vE,[n.createElementVNode("span",null,n.toDisplayString(we.dateRange),1),n.createVNode(n.unref(O.ODivider),{direction:"v"}),n.createElementVNode("span",null,n.toDisplayString(n.unref(y)("meeting.sigs"))+": "+n.toDisplayString(we.group_name),1)])])]),we.is_delete?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",TE,[we.isExpired?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[we.etherpad?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:0,target:"_blank",href:we.etherpad},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})]),default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.meetingSummary"))+" ",1)]),_:1},8,["href"])):n.createCommentVNode("",!0),we.hasObsData?(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:1,target:"_blank",href:`/${n.unref(E)}/video/${we.group_name}/${we.mid}/${we.date}`},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})]),default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.viewRecord"))+" ",1)]),_:1},8,["href"])):n.createCommentVNode("",!0)],64)):(n.openBlock(),n.createBlock(n.unref(O.OLink),{key:0,target:"_blank",href:we.join_url,rel:"noopener noreferrer"},{suffix:n.withCtx(()=>[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconChevronRight))]),_:1})]),default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.joinMeeting"))+" ",1)]),_:1},8,["href"]))])),n.createVNode(n.unref(O.OIcon),{onClick:n.withModifiers(()=>Q(_t),["stop"]),class:"copy-icon"},{default:n.withCtx(()=>[n.createVNode(n.unref(Eh))]),_:1},8,["onClick"])]),default:n.withCtx(()=>[n.createElementVNode("div",bE,[n.createVNode(Sh,{show:F.value.includes(we.sub_id||we.id),data:we,ref_for:!0,ref:Mt=>$(Mt,we.id),from:"my"},null,8,["show","data"]),!we.isExpired&&!we.is_delete?(n.openBlock(),n.createElementBlock("div",xE,[n.createVNode(n.unref(O.OLink),{onClick:Mt=>De(we,"edit")},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.editMeeting")),1)]),_:1},8,["onClick"]),n.createVNode(n.unref(O.OLink),{onClick:Mt=>De(we,"cancel")},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.cancelMeeting")),1)]),_:1},8,["onClick"])])):n.createCommentVNode("",!0)])]),_:2},1032,["value","class"]))),128)),ye[12]||(ye[12]=n.createElementVNode("div",{class:"height-placeholder"},null,-1))],2),je===ht.value.length-1?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[K.value?(n.openBlock(),n.createElementBlock("div",CE,n.toDisplayString(n.unref(y)("common.loading")),1)):n.createCommentVNode("",!0),n.createElementVNode("div",{class:"list-month-change next-month",onClick:ye[6]||(ye[6]=we=>Le("next-month"))},[n.createVNode(n.unref(O.OIcon),null,{default:n.withCtx(()=>[n.createVNode(n.unref(O.OIconArrowRight))]),_:1}),n.createElementVNode("span",null,n.toDisplayString(n.unref(y)("meeting.nextMonth")),1)])],64)):n.createCommentVNode("",!0)],64))),128))]),_:1},8,["modelValue","accordion"])])]),_:1},8,["onScrollend","style"])):r.value?n.createCommentVNode("",!0):n.renderSlot(fe.$slots,"empty",{key:1})],2),n.createVNode(n.unref(O.ODialog),{visible:se.value,"onUpdate:visible":ye[9]||(ye[9]=_e=>se.value=_e),"main-class":"handle-dialog",onClose:Oe,actions:ot.value},{header:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.meetingHandleText",[ue.value==="edit"?n.unref(y)("meeting.edit"):n.unref(y)("meeting.cancel2")])),1)]),default:n.withCtx(()=>[n.createVNode(n.unref(O.ORadioGroup),{modelValue:qe.value,"onUpdate:modelValue":ye[8]||(ye[8]=_e=>qe.value=_e)},{default:n.withCtx(()=>[(n.openBlock(),n.createElementBlock(n.Fragment,null,n.renderList(de,_e=>n.createVNode(n.unref(O.ORadio),{value:_e.value,key:_e.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(_e.label),1)]),_:2},1032,["value"])),64))]),_:1},8,["modelValue"])]),_:1},8,["visible","actions"]),n.createVNode(n.unref(O.ODialog),{visible:H.value,"onUpdate:visible":ye[10]||(ye[10]=_e=>H.value=_e),"main-class":"cancel-dialog",actions:Ct.value},{header:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(n.unref(y)("meeting.confirmCancel")),1)]),default:n.withCtx(()=>{var _e;return[n.createElementVNode("div",SE,n.toDisplayString(n.unref(y)("meeting.confirmCancelDesc",[(_e=V.value)==null?void 0:_e.topic])),1)]}),_:1},8,["visible","actions"])])]))}}),EE=Object.assign(Ec,{install(s){s.component("OMeetingCalendar",Ec)}}),kE=Object.assign(Dc,{install(s){s.component("OMeetingCalendar",Dc)}}),wE=Object.assign(rh,{install(s){s.component("OMeetingPlayback",rh)}}),DE=Object.assign(sh,{install(s){s.component("OSigMeetingCalendar",sh)}}),AE=Object.assign(ah,{install(s){s.component("OMyMeetingCalendar",ah)}}),IE={OBanner:oh,OCookieNotice:lh,OFooter:uh,OHeader:ch,OHeaderMoblie:dh,OHeaderSearch:hh,OHeaderUser:fh,OPlusConfigProvider:ph,OSection:mh,OSourceCode:gh,OThemeSwitcher:_h},NE={install:s=>{Object.entries(IE).forEach(([e,i])=>{s.component(e,i)})}};exports.OElCookieNotice=Ue.OElCookieNotice;exports.CalendarDataType=Ke;exports.EventsStatusT=Ji;exports.OActivityApproval=tv;exports.OActivityForm=ev;exports.OBanner=oh;exports.OCookieNotice=lh;exports.OEventsApply=$3;exports.OEventsCalendar=V3;exports.OEventsList=F3;exports.OFooter=uh;exports.OHeader=ch;exports.OHeaderMoblie=dh;exports.OHeaderSearch=hh;exports.OHeaderUser=fh;exports.OMeetingCalendar=EE;exports.OMeetingForm=kE;exports.OMeetingPlayback=wE;exports.OMyActivityCalendar=iv;exports.OMyMeetingCalendar=AE;exports.OPlusConfigProvider=ph;exports.OSection=mh;exports.OSigMeetingCalendar=DE;exports.OSourceCode=gh;exports.OThemeSwitcher=_h;exports.default=NE;
|