import{V as h}from"./Video-DgoV3B-X.js";import"./index-D6iiusuW.js";import"./file-url-DulxDZ3L.js";import"./Index-DvJ399W-.js";import"./_commonjsHelpers-BosuxZz1.js";import"./svelte/svelte.js";const{SvelteComponent:w,add_flush_callback:V,append:q,attr:z,bind:A,binding_callbacks:C,check_outros:E,create_component:I,destroy_component:N,detach:d,element:v,empty:k,flush:m,group_outros:S,init:j,insert:p,is_function:b,mount_component:B,noop:g,safe_not_equal:D,set_data:F,text:G,toggle_class:f,transition_in:c,transition_out:_}=window.__gradio__svelte__internal;function y(l){let e,n,t,i;const a=[J,H],r=[];function u(o,s){return 0}return e=u(),n=r[e]=a[e](l),{c(){n.c(),t=k()},m(o,s){r[e].m(o,s),p(o,t,s),i=!0},p(o,s){n.p(o,s)},i(o){i||(c(n),i=!0)},o(o){_(n),i=!1},d(o){o&&d(t),r[e].d(o)}}}function H(l){let e,n;return{c(){e=v("div"),n=G(l[2])},m(t,i){p(t,e,i),q(e,n)},p(t,i){i&4&&F(n,t[2])},i:g,o:g,d(t){t&&d(e)}}}function J(l){let e,n,t,i;function a(u){l[5](u)}let r={muted:!0,playsinline:!0,src:l[2]?.video.url};return l[3]!==void 0&&(r.node=l[3]),n=new h({props:r}),C.push(()=>A(n,"node",a)),n.$on("loadeddata",l[4]),n.$on("mouseover",function(){b(l[3].play.bind(l[3]))&&l[3].play.bind(l[3]).apply(this,arguments)}),n.$on("mouseout",function(){b(l[3].pause.bind(l[3]))&&l[3].pause.bind(l[3]).apply(this,arguments)}),{c(){e=v("div"),I(n.$$.fragment),z(e,"class","container svelte-1de9zxs"),f(e,"table",l[0]==="table"),f(e,"gallery",l[0]==="gallery"),f(e,"selected",l[1])},m(u,o){p(u,e,o),B(n,e,null),i=!0},p(u,o){l=u;const s={};o&4&&(s.src=l[2]?.video.url),!t&&o&8&&(t=!0,s.node=l[3],V(()=>t=!1)),n.$set(s),(!i||o&1)&&f(e,"table",l[0]==="table"),(!i||o&1)&&f(e,"gallery",l[0]==="gallery"),(!i||o&2)&&f(e,"selected",l[1])},i(u){i||(c(n.$$.fragment,u),i=!0)},o(u){_(n.$$.fragment,u),i=!1},d(u){u&&d(e),N(n)}}}function K(l){let e,n,t=l[2]&&y(l);return{c(){t&&t.c(),e=k()},m(i,a){t&&t.m(i,a),p(i,e,a),n=!0},p(i,[a]){i[2]?t?(t.p(i,a),a&4&&c(t,1)):(t=y(i),t.c(),c(t,1),t.m(e.parentNode,e)):t&&(S(),_(t,1,1,()=>{t=null}),E())},i(i){n||(c(t),n=!0)},o(i){_(t),n=!1},d(i){i&&d(e),t&&t.d(i)}}}function L(l,e,n){let{type:t}=e,{selected:i=!1}=e,{value:a}=e,r;async function u(){n(3,r.muted=!0,r),n(3,r.playsInline=!0,r),n(3,r.controls=!1,r),r.setAttribute("muted",""),await r.play(),r.pause()}function o(s){r=s,n(3,r)}return l.$$set=s=>{"type"in s&&n(0,t=s.type),"selected"in s&&n(1,i=s.selected),"value"in s&&n(2,a=s.value)},[t,i,a,r,u,o]}class U extends w{constructor(e){super(),j(this,e,L,K,D,{type:0,selected:1,value:2})}get type(){return this.$$.ctx[0]}set type(e){this.$$set({type:e}),m()}get selected(){return this.$$.ctx[1]}set selected(e){this.$$set({selected:e}),m()}get value(){return this.$$.ctx[2]}set value(e){this.$$set({value:e}),m()}}export{U as default};
//# sourceMappingURL=Example-CIm9Zvy8.js.map
