import{o as e}from"./rolldown-runtime-Bhmf7a9N.js";import{KM as t,n}from"./lucide-7srpeIMw.js";import{t as r}from"./custom-media-element-CD3dqe7e.js";var i=e(t(),1),a=class extends r{static shadowRootOptions={...r.shadowRootOptions};static getTemplateHTML=e=>{let{src:t,...n}=e;return r.getTemplateHTML(n)};#e;attributeChangedCallback(e,t,n){e!==`src`&&super.attributeChangedCallback(e,t,n),e===`src`&&t!=n&&this.load()}async load(){this.#e?this.api.attachSource(this.src):(this.#e=!0,this.api=(await n(()=>import(`./dash.all.min-vqALov19.js`),[])).MediaPlayer().create(),this.api.initialize(this.nativeEl,this.src,this.autoplay))}};globalThis.customElements&&!globalThis.customElements.get(`dash-video`)&&globalThis.customElements.define(`dash-video`,a);var o=a,s=new Set([`style`,`children`,`ref`,`key`,`suppressContentEditableWarning`,`suppressHydrationWarning`,`dangerouslySetInnerHTML`]),c={className:`class`,htmlFor:`for`};function l(e){return e.toLowerCase()}function u(e){if(typeof e==`boolean`)return e?``:void 0;if(typeof e!=`function`&&!(typeof e==`object`&&e))return e}function d({react:e,tagName:t,elementClass:n,events:r,displayName:i,defaultProps:a,toAttributeName:o=l,toAttributeValue:d=u}){let p=Number.parseInt(e.version)>=19,m=e.forwardRef((i,l)=>{let m=e.useRef(null),h=e.useRef(new Map),g={},_={},v={},y={};for(let[e,t]of Object.entries(i)){if(s.has(e)){v[e]=t;continue}let r=o(c[e]??e);if(e in n.prototype&&!(e in(globalThis.HTMLElement?.prototype??{}))&&!n.observedAttributes?.some(e=>e===r)){y[e]=t;continue}if(e.startsWith(`on`)){g[e]=t;continue}let i=d(t);r&&i!=null&&(_[r]=String(i),p||(v[r]=i)),r&&p&&(i===u(t)?v[r]=t:v[r]=i)}if(typeof window<`u`){for(let t in g){let n=g[t],i=t.endsWith(`Capture`),a=(r?.[t]??t.slice(2).toLowerCase()).slice(0,i?-7:void 0);e.useLayoutEffect(()=>{let e=m?.current;if(!(!e||typeof n!=`function`))return e.addEventListener(a,n,i),()=>{e.removeEventListener(a,n,i)}},[m?.current,n])}e.useLayoutEffect(()=>{if(m.current===null)return;let e=new Map;for(let t in y)f(m.current,t,y[t]),h.current.delete(t),e.set(t,y[t]);for(let[e,t]of h.current)f(m.current,e,void 0);h.current=e})}if(typeof window>`u`&&n?.getTemplateHTML&&n?.shadowRootOptions){let{mode:t,delegatesFocus:r}=n.shadowRootOptions;v.children=[e.createElement(`template`,{shadowrootmode:t,shadowrootdelegatesfocus:r,dangerouslySetInnerHTML:{__html:n.getTemplateHTML(_,i)}}),v.children]}return e.createElement(t,{...a,...v,ref:e.useCallback(e=>{m.current=e,typeof l==`function`?l(e):l!==null&&(l.current=e)},[l])})});return m.displayName=i??n.name,m}function f(e,t,n){e[t]=n,n==null&&t in(globalThis.HTMLElement?.prototype??{})&&e.removeAttribute(t)}var p=d({react:i.default,tagName:`dash-video`,elementClass:o,toAttributeName(e){return e===`muted`?``:e===`defaultMuted`?`muted`:l(e)}});export{p as default};