@qratilabs/qrati-connect 2.23.8 → 2.24.0
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/README.md +84 -54
- package/element/2CMH9VMM.js +4 -0
- package/element/BKDqpSN62.js +3 -0
- package/element/{lrjV8c1G2.js → BM9ujORR2.js} +1 -1
- package/element/BOQzjiMV.js +9 -0
- package/element/{BYEF5Khs.js → BOqkzZ92.js} +1 -1
- package/{umd/BpVacqmD2.js → element/BP2rYgya2.js} +10 -10
- package/element/BZu3c37u.js +1 -0
- package/{umd/ls36Q8v0.js → element/Bb7nx5xF.js} +5 -5
- package/element/Bh8kXbe92.js +93 -0
- package/{umd/NwT4xmUR2.js → element/Bow6F3212.js} +29 -29
- package/{umd/BkvtmX4K.js → element/BsYbcfkG.js} +1 -1
- package/element/{C8_zGNAf.js → C12iSy3L.js} +1 -1
- package/element/{D9NypPiv.js → C3dOFk9A.js} +1 -1
- package/element/C52SUIvC2.js +35 -0
- package/element/{DIYUC8M3.js → CAETItHr.js} +1 -1
- package/element/{Cb1JRT_1.js → CATr-3VW.js} +1 -1
- package/element/{Byk0pccK.js → CFnGGYmq.js} +1 -1
- package/element/CHTzn6mh2.js +4 -0
- package/element/CL_evx_l.js +1 -0
- package/element/{e_wwJ5wx2.js → CLdpUOLk2.js} +4 -4
- package/element/{qWp4ucdT.js → CM46vluW.js} +1 -1
- package/{umd/BtN9y353.js → element/CVRTTCyF.js} +1 -1
- package/element/{9QY9BKOL2.js → CWhnvMey2.js} +8 -8
- package/{umd/B14kCOq8.js → element/CZ9iaxjO.js} +1 -1
- package/element/CaX2xgrP.js +41 -0
- package/element/{b6CwQBFC.js → ChJXhA9c.js} +5 -5
- package/element/{4VTPoA38.js → CqBk9L5O.js} +1 -1
- package/{umd/CiiNqDJq.js → element/CsfDBJh72.js} +1 -1
- package/element/{_ty2jtjs.js → D35mTuTT.js} +1 -1
- package/element/D5TKEdBd2.js +3 -0
- package/element/{CCLXmMXp.js → DF0LxcV7.js} +1 -1
- package/element/{DvTRhlvs.js → DGGc10Cy.js} +1 -1
- package/element/{ekog7y-V.js → DGbyGc8b.js} +1 -1
- package/element/DN26AtHL2.js +4 -0
- package/element/{DsvRTvCp.js → DWBbTgnB.js} +1 -1
- package/element/{BQuhYd4G2.js → DZtaQWVG2.js} +1 -1
- package/element/{D0VKfxwE.js → DdOwRfWG.js} +2 -2
- package/element/DkG0zv7_2.js +9 -0
- package/{umd/gk4TX_a62.js → element/DlRUi0u42.js} +1 -1
- package/element/{DXx41__x2.js → DlqJDAie2.js} +1 -1
- package/element/DnIueBGr2.js +1 -0
- package/element/{BglDIiFp.js → DnQ6XaLR.js} +2 -2
- package/element/DrrpB4Om.js +1 -0
- package/element/DtRwaUYF2.js +85 -0
- package/element/{CSO2IaJ1.js → LYboLIEU.js} +2 -2
- package/element/{DNG5BSHx2.js → N4HKgEC52.js} +1 -1
- package/element/Rcen6i0h.js +80 -0
- package/{umd/MpvHkxaz2.js → element/Z0-Tddye2.js} +1 -1
- package/element/dT6WSX65.js +1 -0
- package/element/h4ZjZXfe2.js +1 -0
- package/element/kiL9JENf2.js +3 -0
- package/element/{BdOzsWR32.js → lcKuIs2T2.js} +1 -1
- package/element/{CXg838Gr2.js → mIANlVHi2.js} +8 -8
- package/element/mQzpzQ_t.js +3 -0
- package/element/web.es.js +26 -108
- package/package.json +3 -15
- package/react/index.d.mts +182 -6
- package/react/index.d.ts +182 -6
- package/element/B14kCOq8.js +0 -2
- package/element/BItJQVdK.js +0 -41
- package/element/BYoa-kpQ2.js +0 -9
- package/element/Be1e_ATJ.js +0 -1
- package/element/BfkCwRAR2.js +0 -3
- package/element/BkvtmX4K.js +0 -2
- package/element/BpVacqmD2.js +0 -14
- package/element/BsT0vqml.js +0 -1
- package/element/BtN9y353.js +0 -1
- package/element/C030L_Hu2.js +0 -4
- package/element/C0MGOytI.js +0 -1
- package/element/C3tT7YRo2.js +0 -37
- package/element/C3uDEVBt.js +0 -1
- package/element/CiiNqDJq.js +0 -3
- package/element/CnoPTYOO.js +0 -1
- package/element/D4apO9G62.js +0 -4
- package/element/DB1jhaAe2.js +0 -85
- package/element/Do2aldFH.js +0 -9
- package/element/Drl8BMLL2.js +0 -93
- package/element/LJWh_4Di.js +0 -2
- package/element/MpvHkxaz2.js +0 -16
- package/element/NwT4xmUR2.js +0 -39
- package/element/gjXXuILV2.js +0 -3
- package/element/gk4TX_a62.js +0 -7
- package/element/ls36Q8v0.js +0 -9
- package/element/qNDy94Dr2.js +0 -3
- package/element/styles.css +0 -288
- package/umd/4VTPoA38.js +0 -1
- package/umd/9QY9BKOL2.js +0 -8
- package/umd/BCTYvPrD.js +0 -1
- package/umd/BItJQVdK.js +0 -41
- package/umd/BQuhYd4G2.js +0 -2
- package/umd/BYEF5Khs.js +0 -1
- package/umd/BYoa-kpQ2.js +0 -9
- package/umd/BdOzsWR32.js +0 -9
- package/umd/Be1e_ATJ.js +0 -1
- package/umd/BfkCwRAR2.js +0 -3
- package/umd/BglDIiFp.js +0 -3
- package/umd/BkIDQGIs.js +0 -1
- package/umd/Bki5T_lb.js +0 -1
- package/umd/BsT0vqml.js +0 -1
- package/umd/Byk0pccK.js +0 -1
- package/umd/C030L_Hu2.js +0 -4
- package/umd/C0MGOytI.js +0 -1
- package/umd/C3tT7YRo2.js +0 -37
- package/umd/C3uDEVBt.js +0 -1
- package/umd/C8_zGNAf.js +0 -1
- package/umd/CCLXmMXp.js +0 -3
- package/umd/CSO2IaJ1.js +0 -2
- package/umd/CXg838Gr2.js +0 -13
- package/umd/Cb1JRT_1.js +0 -1
- package/umd/CfMNBPpx2.js +0 -1
- package/umd/CgUphJWo.js +0 -1
- package/umd/Cko4QHwX.js +0 -1
- package/umd/CnoPTYOO.js +0 -1
- package/umd/D0VKfxwE.js +0 -10
- package/umd/D4apO9G62.js +0 -4
- package/umd/D9NypPiv.js +0 -7
- package/umd/DB1jhaAe2.js +0 -85
- package/umd/DIYUC8M3.js +0 -2
- package/umd/DNG5BSHx2.js +0 -2
- package/umd/DXx41__x2.js +0 -2
- package/umd/Do2aldFH.js +0 -9
- package/umd/Drl8BMLL2.js +0 -93
- package/umd/DsvRTvCp.js +0 -8
- package/umd/DvTRhlvs.js +0 -2
- package/umd/LJWh_4Di.js +0 -2
- package/umd/_ty2jtjs.js +0 -2
- package/umd/b6CwQBFC.js +0 -5
- package/umd/e_wwJ5wx2.js +0 -5
- package/umd/ekog7y-V.js +0 -1
- package/umd/gjXXuILV2.js +0 -3
- package/umd/index.d.ts +0 -14
- package/umd/lrjV8c1G2.js +0 -8
- package/umd/qNDy94Dr2.js +0 -3
- package/umd/qWp4ucdT.js +0 -1
- package/umd/rtH8O6Hc.js +0 -1
- package/umd/web.es.js +0 -125
- package/umd/web.umd.js +0 -1
package/umd/C3tT7YRo2.js
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import{C as t,D as e,E as n,T as i,_ as s,b as o,f as r,g as l,h as a,i as c,m as d,n as h,p as u,t as p,v as m,w as g,y as f}from"./C3uDEVBt.js";import{C as w,D as T,L as y,N as b,O as v,S as k,a as q,i as x,l as E,m as N,n as _,u as S,v as I}from"./BItJQVdK.js";import{n as C,r as L,t as M}from"./CnoPTYOO.js";import{t as R}from"./b6CwQBFC.js";import{t as B}from"./Cb1JRT_1.js";import{t as A}from"./D9NypPiv.js";import{n as V,t as z}from"./CSO2IaJ1.js";import{n as O}from"./BkIDQGIs.js";import{t as F}from"./Bki5T_lb.js";import{n as P,r as D,t as U}from"./BYEF5Khs.js";import{n as H}from"./BtN9y353.js";import{a as j,i as $,n as G,o as W,r as Q,s as K,t as Y}from"./CiiNqDJq.js";import{a as Z,n as J,o as X,r as tt,t as et}from"./BQuhYd4G2.js";function nt(t){return["react-photo-album",t].filter(Boolean).join("--")}function it({width:t,height:e}){const n=t/e;return Number.isFinite(n)?n:1}var st=Object.freeze([1200,600,300,0]);function ot(t,e){return"function"==typeof t?t(e):t}function rt(t,e){return void 0!==e?ot(t,e):void 0}function lt(t,e,n,i=0){if(void 0===e)return;const s=rt(t,e);return Math.round(Math.max(void 0===s?function(t,e){const n=st.findIndex(t=>t<=e);return ot(t[Math.max(n,0)],e)}(n,e):s,i))}function at(t,{spacing:e,padding:n,componentsProps:i,render:s}){return{spacing:lt(e,t,[20,15,10,5]),padding:lt(n,t,[0,0,0,0]),componentsProps:ot(i,t)||{},render:ot(s,t)}}function ct(t,e=0){const n=10**e;return Math.round((t+Number.EPSILON)*n)/n}function dt(t,e,n,i,s,o,r){let l,a;const c=t=>{const e=o*(s-1)+2*r*s;return`calc((${t.match(/^\s*calc\((.*)\)\s*$/)?.[1]??t} - ${e}px) / ${ct((i-e)/n,5)})`},d=t.srcSet;return d&&d.length>0&&(l=d.concat(d.some(({width:e})=>e===t.width)?[]:[{src:t.src,width:t.width,height:t.height}]).sort((t,e)=>t.width-e.width).map(t=>`${t.src} ${t.width}w`).join(", ")),a=e?.size?(e.sizes||[]).map(({viewport:t,size:e})=>`${t} ${c(e)}`).concat(c(e.size)).join(", "):`${Math.ceil(n/i*100)}vw`,{srcSet:l,sizes:a}}var ht=c(function({as:t,render:e,context:n,classes:i=[],variables:s={},style:o,className:r,children:l,...a},c){const d=function(...t){return t.filter(Boolean).join(" ")}(...(Array.isArray(i)?i:[i]).filter(t=>"string"==typeof t).map(nt),r),h={style:{...Object.fromEntries(Object.entries(s).map(([t,e])=>{return[(n=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),`--${nt(n)}`),"number"==typeof e?ct(e,5):e];var n})),...o},className:d,children:l,...a};if(e){const t=e({ref:c,...h},n);if(t)return t}return p(t||"div",{ref:c,...h})}),ut=c(function({photo:t,index:e,width:n,height:i,onClick:s,render:{wrapper:o,link:r,button:l,image:a,extras:c}={},componentsProps:{link:d,button:h,wrapper:u,image:m}={}},g){const{href:f}=t,w={photo:t,index:e,width:ct(n,3),height:ct(i,3)};let T;return T=f?{...d,as:"a",render:r,classes:["photo","link"],href:f,onClick:s}:s?{...h,as:"button",type:"button",render:l,classes:["photo","button"],onClick:s}:{...u,render:o,classes:"photo"},p(ht,{ref:g,variables:{photoWidth:w.width,photoHeight:w.height},context:w,...T,children:[p(ht,{as:"img",classes:"image",render:a,context:w,...m}),c?.({},w)]})}),pt=c(function({layout:t,sizes:n,model:i,skeleton:s,onClick:o,render:{container:r,track:l,photo:a,...c}={},componentsProps:{container:d,track:h,link:u,button:m,wrapper:g,image:f}={}},w){const{spacing:T,padding:y,containerWidth:b,tracks:v,variables:k,horizontal:q}=i||{};return p(ht,{role:"group","aria-label":"Photo album",...d,variables:{spacing:T,padding:y,containerWidth:b,...k},classes:["",t],render:r,ref:w,children:[void 0!==T&&void 0!==y&&void 0!==b&&v?.map(({photos:t,variables:i},s)=>{const r=t.length,d=q?r:v.length;return e(ht,{...h,key:s,render:l,classes:"track",variables:{trackSize:r,...i}},t.map(t=>{const{photo:e,index:i,width:s}=t,{key:r,src:l,alt:h="",title:w,label:v}=e,k=o?t=>{o({event:t,photo:e,index:i})}:void 0;if(a){const e=a({onClick:k},t);if(e)return e}const q=t=>v?{"aria-label":v,...t}:t;return p(ut,{onClick:k,render:c,componentsProps:{image:{loading:"lazy",decoding:"async",src:l,alt:h,title:w,...dt(e,n,s,b,d,T,y),...ot(f,t)},link:q(ot(u,t)),button:q(ot(m,t)),wrapper:ot(g,t)},...t},r??i)}))}),void 0===b&&s]})});function mt(t,e,n,i){return(e-(t.length-1)*n-2*i*t.length)/t.reduce((t,e)=>t+it(e),0)}function gt(t,e,n,i,s,o,r){const l=t.slice(e,n),a=mt(l,i,s,o);return a>0?(a-r)**2*l.length:void 0}function ft(t,e){const[n,i]=t;if(n===e)return t;if(void 0!==i&&void 0!==e&&void 0!==n&&e===i&&Math.abs(e-n)<=20){const s=Math.min(n,e),o=Math.max(n,e);return s===n&&o===i?t:[s,o]}return[e,n]}function wt(t,e,n){const[[i],o]=s(ft,[n]),l=function(t){const[e,n]=a(t);return t===e||t&&e&&t.length===e.length&&!t.some((t,n)=>t!==e[n])?e:(n(t),t)}(e),c=r(void 0);return{containerRef:m(e=>{c.current?.disconnect(),c.current=void 0;const n=()=>o(function(t,e){let n=t?.clientWidth;if(void 0!==n&&e&&e.length>0){const t=[...e.filter(t=>t>0)].sort((t,e)=>e-t);t.push(Math.floor(t[t.length-1]/2)),n=t.find((e,i)=>e<=n||i===t.length-1)}return n}(e,l));n(),e&&"undefined"!=typeof ResizeObserver&&(c.current=new ResizeObserver(n),c.current.observe(e)),"function"==typeof t?t(e):t&&(t.current=e)},[t,l]),containerWidth:i}}var Tt=c(function({photos:t,breakpoints:e,defaultContainerWidth:n,...i},s){const{containerRef:o,containerWidth:r}=wt(s,e,n),{spacing:l,padding:a,targetRowHeight:c,minPhotos:d,maxPhotos:h,...m}=function(t,{photos:e,targetRowHeight:n,rowConstraints:i,...s}){const{spacing:o,padding:r,componentsProps:l,render:a}=at(t,s),{singleRowMaxHeight:c,minPhotos:d,maxPhotos:h}=rt(i,t)||{};if(void 0!==c&&void 0!==o&&void 0!==r){const t=Math.floor(e.reduce((t,{width:e,height:n})=>t+e/n*c+2*r,o*(e.length-1)));t>0&&(l.container={...l.container},l.container.style={maxWidth:t,...l.container.style})}return{...s,targetRowHeight:lt(n,t,[t=>t/5,t=>t/4,t=>t/3,t=>t/2]),render:a,spacing:o,padding:r,minPhotos:d,maxPhotos:h,componentsProps:l}}(r,{photos:t,...i});return p(pt,{layout:"rows",ref:o,model:u(()=>void 0!==r&&void 0!==l&&void 0!==a&&void 0!==c?function(t,e,n,i,s,o,r){const l=Math.min(function(t,e,n,i){return ct(e/n/Math.min(...t.map(t=>it(t))))+(i||0)+2}(t,i,s,o),r||1/0),a=o||1,c=t.length,d=new Array(c+1).fill(1/0),h=new Array(c+1).fill(-1);d[0]=0;for(let m=1;m<=c;m+=1)for(let o=m-a;o>=Math.max(0,m-l);o-=1){if(d[o]===1/0)continue;const r=gt(t,o,m,i,e,n,s);if(void 0===r)break;const l=d[o]+r;(d[m]===1/0||d[m]>l&&(d[m]/l>1.005||-1!==h[m]&&h[m]<o))&&(d[m]=l,h[m]=o)}if(d[c]===1/0)return;const u=[];for(let m=c;0!==m;m=h[m])u.push(m);u.push(0),u.reverse();const p=[];for(let m=1;m<u.length;m+=1){const s=t.slice(u[m-1],u[m]).map((t,e)=>({photo:t,index:u[m-1]+e})),o=mt(s.map(({photo:t})=>t),i,e,n);p.push({photos:s.map(({photo:t,index:e})=>({photo:t,index:e,width:o*it(t),height:o}))})}return{spacing:e,padding:n,containerWidth:i,tracks:p,horizontal:!0}}(t,l,a,r,c,d,h):void 0,[t,l,a,r,c,d,h]),...m})});function yt(t,e,n,i,s,o,r){const l=[],a=r.reduce((t,e)=>t+e,0);for(let c=0;c<t.length-1;c+=1){const d=e.slice(t[c],t[c+1]).map((e,n)=>({photo:e,index:t[c]+n})),h=r.reduce((t,e,n)=>t+(o[c]-o[n])*e,0),u=(s-(t.length-2)*n-2*(t.length-1)*i-h)*r[c]/a;l.push({photos:d.map(({photo:t,index:e})=>({photo:t,index:e,width:u,height:u/it(t)})),variables:{adjustedGaps:h,columnRatio:r[c]}})}return{tracks:l,variables:{totalRatio:a}}}function bt(t,e,n,i,s,o){const r=[],l=[];if(t.length<=o){const s=t.length>0?t.reduce((t,e)=>t+it(e),0)/t.length:1;for(let e=0;e<o;e+=1)r[e]=2*n,l[e]=e<t.length?it(t[e]):s;return yt(Array.from({length:o+1},(e,n)=>Math.min(n,t.length)),t,e,n,i,r,l)}const a=(c=function(t,e,n,i,s){return o=>{const r=[],l=1.5*s;let a=i/it(t[o])+2*n;for(let c=o+1;c<t.length+1&&(r.push([c,(s-a)**2]),!(a>l||c===t.length));c+=1)a+=i/it(t[c])+e+2*n;return r}}(t,e,n,s,(t.reduce((t,e)=>t+s/it(e),0)+e*(t.length-o)+2*n*t.length)/o),d=o,h=0,u=t.length,function(t,e,n){const i=[n];for(let s=n,o=e;o>0;o-=1)[s]=t.get(s)[o],i.push(s);return i.reverse()}(function(t,e,n,i){const s=/* @__PURE__ */new Map,o=/* @__PURE__ */new Set;o.add(n);for(let r=0;r<e;r+=1){const n=[...o.keys()];o.clear(),n.forEach(n=>{const l=r>0?s.get(n)[r][1]:0;t(n).forEach(([t,a])=>{let c=s.get(t);c||(c=[],s.set(t,c));const d=l+a,h=c[r+1];(!h||h[1]>d&&(h[1]/d>1.0001||n<h[0]))&&(c[r+1]=[n,d]),r<e-1&&t!==i&&o.add(t)})})}return s}(c,d,h,u),d,u));var c,d,h,u;for(let p=0;p<a.length-1;p+=1){const i=t.slice(a[p],a[p+1]);r[p]=e*(i.length-1)+2*n*i.length,l[p]=1/i.reduce((t,e)=>t+1/it(e),0)}return yt(a,t,e,n,i,r,l)}function vt(t,e,n,i,s){const{tracks:o,variables:r}=bt(t,e,n,i,(i-e*(s-1)-2*n*s)/s,s);return o.some(t=>t.photos.some(({width:t,height:e})=>t<=0||e<=0))?s>1?vt(t,e,n,i,s-1):void 0:{tracks:o,spacing:e,padding:n,containerWidth:i,variables:{columns:s,...r}}}var kt=c(function({photos:t,breakpoints:e,defaultContainerWidth:n,...i},s){const{containerRef:o,containerWidth:r}=wt(s,e,n),{spacing:l,padding:a,columns:c,...d}=function(t,{columns:e,...n}){return{...n,...at(t,n),columns:lt(e,t,[5,4,3,2],1)}}(r,{photos:t,...i});return p(pt,{layout:"columns",ref:o,model:u(()=>void 0!==r&&void 0!==l&&void 0!==a&&void 0!==c?vt(t,l,a,r,c):void 0,[t,l,a,r,c]),...d})});function qt(t,e,n,i,s){const o=(i-e*(s-1)-2*n*s)/s;if(o<=0)return s>1?qt(t,e,n,i,s-1):void 0;const r=[];for(let a=0;a<s;a+=1)r[a]=0;const l=t.reduce((t,i,s)=>{const l=r.reduce((t,e,n)=>e<r[t]-1?n:t,0);return r[l]=r[l]+o/it(i)+e+2*n,t[l].push({photo:i,index:s}),t},Array.from({length:s},()=>[]));return{spacing:e,padding:n,containerWidth:i,variables:{columns:s},tracks:l.map(t=>({photos:t.map(({photo:t,index:e})=>({photo:t,index:e,width:o,height:o/it(t)}))}))}}var xt=c(function({photos:t,breakpoints:e,defaultContainerWidth:n,...i},s){const{containerRef:o,containerWidth:r}=wt(s,e,n),{spacing:l,padding:a,columns:c,...d}=function(t,{columns:e,...n}){return{...n,...at(t,n),columns:lt(e,t,[5,4,3,2],1)}}(r,{photos:t,...i});return p(pt,{layout:"masonry",ref:o,model:u(()=>void 0!==r&&void 0!==l&&void 0!==a&&void 0!==c?qt(t,l,a,r,c):void 0,[t,l,a,r,c]),...d})}),Et='url("https://res.cloudinary.com/dectzk2b2/image/upload/v1736933014/black_rpie3v.png")',Nt=class{constructor(t){this.backdropOn=!1,this.lightbox=t,this.backgroundElement=null,this.backgroundVideoElement=null,this.referenceVideoElement=null,this.options={toggleBackdropButtonOrder:7},t.on("init",()=>{this.initPswpEvents(t.pswp)})}getRootNode(){return this.lightbox?.pswp?.element?.getRootNode?.()||document}querySelector(t){return this.getRootNode().querySelector?.(t)||document.querySelector(t)}initPswpEvents(t){t.on("afterInit",()=>{setTimeout(()=>{this.backgroundElement.style.display="block",this.backgroundVideoElement.style.display="block"},[500])}),t.on("uiRegister",()=>{t.ui.registerElement({name:"toggle-backdrop-button",title:"Toggle blur backdrop",order:this.options.toggleBackdropButtonOrder,isButton:!0,html:'<svg aria-hidden="true" class="pswp__icn p-0.5" viewBox="0 0 24 24"><use class="pswp__icn-shadow" xlink:href="#pswp__icn-show-backdrop"/><use class="pswp__icn-shadow" xlink:href="#pswp__icn-hide-backdrop"/><path id="pswp__icn-show-backdrop" style="display:none" d="M3 14.5q-.2 0-.35-.15T2.5 14t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m0-4q-.2 0-.35-.15T2.5 10t.15-.35T3 9.5t.35.15t.15.35t-.15.35t-.35.15M6 19q-.425 0-.712-.288T5 18t.288-.712T6 17t.713.288T7 18t-.288.713T6 19m0-4q-.425 0-.712-.288T5 14t.288-.712T6 13t.713.288T7 14t-.288.713T6 15m0-4q-.425 0-.712-.288T5 10t.288-.712T6 9t.713.288T7 10t-.288.713T6 11m0-4q-.425 0-.712-.288T5 6t.288-.712T6 5t.713.288T7 6t-.288.713T6 7m4 8.5q-.625 0-1.062-.437T8.5 14t.438-1.062T10 12.5t1.063.438T11.5 14t-.437 1.063T10 15.5m0-4q-.625 0-1.062-.437T8.5 10t.438-1.062T10 8.5t1.063.438T11.5 10t-.437 1.063T10 11.5m0 7.5q-.425 0-.712-.288T9 18t.288-.712T10 17t.713.288T11 18t-.288.713T10 19m0-12q-.425 0-.712-.288T9 6t.288-.712T10 5t.713.288T11 6t-.288.713T10 7m0 14.5q-.2 0-.35-.15T9.5 21t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m0-18q-.2 0-.35-.15T9.5 3t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m4 12q-.625 0-1.062-.437T12.5 14t.438-1.062T14 12.5t1.063.438T15.5 14t-.437 1.063T14 15.5m0-4q-.625 0-1.062-.437T12.5 10t.438-1.062T14 8.5t1.063.438T15.5 10t-.437 1.063T14 11.5m0 7.5q-.425 0-.712-.288T13 18t.288-.712T14 17t.713.288T15 18t-.288.713T14 19m0-12q-.425 0-.712-.288T13 6t.288-.712T14 5t.713.288T15 6t-.288.713T14 7m0 14.5q-.2 0-.35-.15T13.5 21t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m0-18q-.2 0-.35-.15T13.5 3t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15M18 19q-.425 0-.712-.288T17 18t.288-.712T18 17t.713.288T19 18t-.288.713T18 19m0-4q-.425 0-.712-.288T17 14t.288-.712T18 13t.713.288T19 14t-.288.713T18 15m0-4q-.425 0-.712-.288T17 10t.288-.712T18 9t.713.288T19 10t-.288.713T18 11m0-4q-.425 0-.712-.288T17 6t.288-.712T18 5t.713.288T19 6t-.288.713T18 7m3 7.5q-.2 0-.35-.15T20.5 14t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m0-4q-.2 0-.35-.15T20.5 10t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15"/><path id="pswp__icn-hide-backdrop" d="m19.1 21.9l-17-17q-.275-.275-.275-.7t.275-.7t.7-.275t.7.275l17 17q.275.275.275.7t-.275.7t-.7.275t-.7-.275m-9.1-.4q-.2 0-.35-.15T9.5 21t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m4 0q-.2 0-.35-.15T13.5 21t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15M6 19q-.425 0-.712-.288T5 18t.288-.712T6 17t.713.288T7 18t-.288.713T6 19m4 0q-.425 0-.712-.288T9 18t.288-.712T10 17t.713.288T11 18t-.288.713T10 19m4 0q-.425 0-.712-.288T13 18t.288-.712T14 17t.713.288T15 18t-.288.713T14 19m-4-3.5q-.65 0-1.075-.425T8.5 14t.425-1.075T10 12.5t1.075.425T11.5 14t-.425 1.075T10 15.5M6 15q-.425 0-.712-.288T5 14t.288-.712T6 13t.713.288T7 14t-.288.713T6 15m11.8-.025l-.775-.775q-.1-.5.213-.85T18 13q.425 0 .713.288T19 14q0 .45-.35.763t-.85.212M3 14.5q-.2 0-.35-.15T2.5 14t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m18 0q-.2 0-.35-.15T20.5 14t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m-6.7-3.05L12.55 9.7q.125-.525.5-.862T14 8.5q.65 0 1.075.425T15.5 10q0 .575-.35.963t-.85.487M6 11q-.425 0-.712-.287T5 10t.288-.712T6 9t.713.288T7 10t-.288.713T6 11m12 0q-.425 0-.712-.288T17 10t.288-.712T18 9t.713.288T19 10t-.288.713T18 11m-15-.5q-.2 0-.35-.15T2.5 10t.15-.35T3 9.5t.35.15t.15.35t-.15.35t-.35.15m18 0q-.2 0-.35-.15T20.5 10t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15M14 7q-.425 0-.712-.288T13 6t.288-.712T14 5t.713.288T15 6t-.288.713T14 7m-4.175-.025l-.8-.8q-.075-.5.225-.837T10 5q.425 0 .712.287T11 6q0 .45-.337.75t-.838.225M18 7q-.425 0-.712-.288T17 6t.288-.712T18 5t.713.288T19 6t-.288.713T18 7m-8-3.5q-.2 0-.35-.15T9.5 3t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15m4 0q-.2 0-.35-.15T13.5 3t.15-.35t.35-.15t.35.15t.15.35t-.15.35t-.35.15" /></svg>',onClick:()=>{this.toggleBackdrop(t)}}),this.createBlurBackground(t)}),t.on("change",()=>{this.backdropOn&&this.updateBlurBackground(t)}),t.on("close",()=>{this.removeBlurBackground(),this.backdropOn=!1})}createBlurBackground(t){const e=t.element;if(!this.backgroundElement){const t=document.createElement("div");t.style.position="fixed",t.style.top=0,t.style.left=0,t.style.width="100vw",t.style.height="100vh",t.style.backgroundSize="cover",t.style.backgroundPosition="center",t.style.filter="blur(44px)",t.style.zIndex=-1,t.style.transition="background-image 0.5s ease, opacity 0.5s ease",t.style.display="none",t.style.backgroundImage=Et,e.append(t),this.backgroundElement=t}if(!this.backgroundVideoElement){const t=document.createElement("video");t.style.position="fixed",t.style.top=0,t.style.left=0,t.style.width="100vw",t.style.height="100vh",t.style.objectFit="cover",t.style.filter="blur(44px)",t.style.zIndex=-1,t.style.display="none",t.style.transition="opacity 0.5s ease",t.muted=!0,t.loop=!0,t.autoplay=!1,t.muted=!0,t.volume=0,e.append(t),this.backgroundVideoElement=t}}toggleBackdrop(t){this.backdropOn?(this.backgroundElement.style.backgroundImage=Et,this.backgroundVideoElement.style.opacity=0,this.backgroundVideoElement.pause(),this.backdropOn=!1):(this.updateBlurBackground(t),this.backdropOn=!0);const e=this.querySelector("#pswp__icn-hide-backdrop"),n=this.querySelector("#pswp__icn-show-backdrop");e&&(e.style.display=this.backdropOn?"none":"inline"),n&&(n.style.display=this.backdropOn?"inline":"none")}updateBlurBackground(t){const e=t.currSlide;if(e?.data)if("video"===e.data.type){const t=this.backgroundVideoElement,n=e.content.element;"video"===n?.tagName?.toLowerCase()&&(this.referenceVideoElement=n,this.registerVideoEvents(n,t)),t.style.opacity=0,setTimeout(()=>{t.src=e.data.src,t.load(),this.initBackgroundVideo(),t.style.opacity=1},500),this.backgroundElement&&(this.backgroundElement.style.opacity=0)}else{if(this.backgroundElement){const t=((t,e=32,n=32)=>{if(!t||t.length<6||"undefined"==typeof document)return null;try{const i=O(t,e,n),s=document.createElement("canvas");s.width=e,s.height=n;const o=s.getContext("2d");if(!o)return null;const r=o.createImageData(e,n);return r.data.set(i),o.putImageData(r,0,0),s.toDataURL()}catch(i){return console.warn("[PhotoSwipeBackdrop] Failed to decode blurhash:",i),null}})(e.data.blurhash)||e.data.thumbnailUrl||e.data.src;this.backgroundElement.style.backgroundImage=t?`url("${t}")`:Et,this.backgroundElement.style.backgroundColor="transparent",this.backgroundElement.style.opacity=1}this.backgroundVideoElement&&(this.backgroundVideoElement.style.opacity=0,this.backgroundVideoElement.src="")}}initBackgroundVideo(){this.referenceVideoElement&&(this.backgroundVideoElement.currentTime=this.referenceVideoElement.currentTime,this.referenceVideoElement.currentTime>0&&!this.referenceVideoElement.paused&&!this.referenceVideoElement.ended&&this.referenceVideoElement.readyState>2&&this.backgroundVideoElement.play())}removeBlurBackground(){this.backgroundElement&&(this.backgroundElement.remove(),this.backgroundVideoElement.remove(),this.backgroundElement=null,this.backgroundVideoElement=null)}registerVideoEvents(t,e){this.foregroundVideoElement=t,t.addEventListener("play",()=>{e.currentTime=t.currentTime,e.play()}),t.addEventListener("pause",()=>{e.pause()}),t.addEventListener("ended",()=>{e.pause(),e.currentTime=0})}},_t=({contents:t=[],selectedIndex:e,onClick:n})=>{const i=r(null);o(()=>{i.current&&s(e)},[e,i.current]);const s=t=>{if(!i.current)return;const e=i.current,n=e.children;if(t<0||t>=n.length)return;const s=n[t],o=e.offsetWidth/2,r=s.offsetLeft+s.offsetWidth/2-o;e.scrollTo({left:r,behavior:"smooth"})};/* @__PURE__ */
|
|
2
|
-
return p("div",{ref:i,className:"scrollbar-hide flex h-28 w-auto items-center justify-center overflow-x-auto bg-black/50",style:{scrollBehavior:"smooth",userSelect:"none",whiteSpace:"nowrap"},children:t.map((t,i)=>/* @__PURE__ */p("button",{className:"relative mx-0.5 inline-block [contain-intrinsic-size:6rem_5rem] [content-visibility:auto] lg:mx-1.5",onClick:()=>((t,e)=>{n(e)})(0,i),children:[
|
|
3
|
-
/* @__PURE__ */p(z,{wrapperClassName:x("h-16 w-24 rounded-md lg:h-20 lg:w-20",i===e&&"border-2 border-[#ff4800]"),src:t.thumbnailUrl,placeholderSrc:t.blurImageUrl,alt:t.caption}),t.type===N.VIDEO&&/* @__PURE__ */p("div",{className:"absolute top-0 left-0 flex size-full items-center justify-center opacity-75",children:/* @__PURE__ */p("svg",{xmlns:"http://www.w3.org/2000/svg",className:"size-6 text-white lg:size-9",viewBox:"0 0 24 24",children:/* @__PURE__ */p("path",{fill:"currentColor",d:"M8 17.175V6.825q0-.425.3-.713t.7-.287q.125 0 .263.037t.262.113l8.15 5.175q.225.15.338.375t.112.475t-.112.475t-.338.375l-8.15 5.175q-.125.075-.262.113T9 18.175q-.4 0-.7-.288t-.3-.712"})})}),t.type===N.AD&&/* @__PURE__ */p("div",{className:"absolute top-1 left-1 text-xs",children:"Ad"})]},`filmstrip-thumbnail-${i}`))})},St=class{constructor(t){this.lightbox=t,this.filmstripVisible=!0,this.options={filmstripButtonOrder:7},t.on("init",()=>{this.initPswpEvents(t.pswp)})}getRootNode(){return this.lightbox?.pswp?.element?.getRootNode?.()||document}getElementById(t){const e=this.getRootNode();return"function"==typeof e.getElementById?e.getElementById(t):e.querySelector?.(`#${t}`)||document.getElementById(t)}querySelector(t){return this.getRootNode().querySelector?.(t)||document.querySelector(t)}initPswpEvents(t){t.on("uiRegister",()=>{t.ui.registerElement({name:"filmstrip-toggle-button",title:"Toggle filmstrip view",order:this.options.filmstripButtonOrder,isButton:!0,html:'<svg aria-hidden="true" class="pswp__icn p-0.5" viewBox="0 0 24 24" id="pswp__icn-show-filmstrip"><use class="pswp__icn-shadow" xlink:href="#pswp__icn-show-filmstrip"/>\n <path\n d="M4 20q-.825 0-1.412-.587T2 18V6q0-.825.588-1.412T4 4h16q.825 0 1.413.588T22 6v12q0 .825-.587 1.413T20 20zm0-2h16V8H4z" />\n <path\n d="m 5.100795,16.58464 q -0.165328,0 -0.282961,-0.116899 Q 4.700201,16.350842 4.7,16.186347 V 13.398294 Q 4.7,13.233997 4.817834,13.117098 4.935667,13.000199 5.100795,13 h 2.805561 q 0.165328,0 0.283161,0.117098 0.117834,0.117099 0.117633,0.281196 v 2.788053 q 0,0.164296 -0.117633,0.281394 -0.117633,0.117099 -0.283161,0.116899 z"\n\n style="stroke-width:0.199771" />\n <path\n\n d="m 10.572144,16.65489 q -0.165329,0 -0.282961,-0.116899 -0.117633,-0.116899 -0.117834,-0.281394 v -2.788053 q 0,-0.164297 0.117834,-0.281196 0.117832,-0.116899 0.282961,-0.117098 h 2.805561 q 0.165328,0 0.283161,0.117098 0.117834,0.117099 0.117633,0.281196 v 2.788053 q 0,0.164296 -0.117633,0.281394 -0.117633,0.117099 -0.283161,0.116899 z"\n\n style="stroke-width:0.199771" />\n <path\n\n d="m 16.049385,16.724729 q -0.165328,0 -0.282961,-0.116899 -0.117633,-0.116899 -0.117834,-0.281394 v -2.788053 q 0,-0.164297 0.117834,-0.281196 0.117833,-0.116899 0.282961,-0.117098 h 2.805561 q 0.165328,0 0.283161,0.117098 0.117834,0.117099 0.117634,0.281196 v 2.788053 q 0,0.164296 -0.117634,0.281394 -0.117633,0.117099 -0.283161,0.116899 z"\n\n style="stroke-width:0.199771" />\n </svg>\n <svg aria-hidden="true" class="pswp__icn p-0.5" viewBox="0 0 24 24" id="pswp__icn-hide-filmstrip" style="display:none"><use class="pswp__icn-shadow" xlink:href="#pswp__icn-hide-filmstrip"/>\n <path\n d="M4 20q-.825 0-1.412-.587T2 18V6q0-.825.588-1.412T4 4v2.85L1.35 4.2q-.3-.3-.3-.712t.3-.713t.713-.3t.712.3l18.4 18.4q.3.3.3.7t-.3.7t-.712.3t-.713-.3L17.15 20zm0-2h11.15l-10-10H4zM22 6v11q0 .5-.312.75T21 18t-.687-.262t-.313-.763V8h-8.325q-.4 0-.763-.15t-.637-.425L8.55 5.7q-.225-.25-.275-.525t.075-.55t.35-.45T9.275 4H20q.825 0 1.413.588T22 6"\n />\n <path\n\n d="m 5.100795,16.58464 q -0.165328,0 -0.282961,-0.116899 Q 4.700201,16.350842 4.7,16.186347 V 13.398294 Q 4.7,13.233997 4.817834,13.117098 4.935667,13.000199 5.100795,13 h 2.805561 q 0.165328,0 0.283161,0.117098 0.117834,0.117099 0.117633,0.281196 v 2.788053 q 0,0.164296 -0.117633,0.281394 -0.117633,0.117099 -0.283161,0.116899 z"\n\n style="stroke-width:0.199771" />\n <path\n\n d="m 10.572143,16.65489 q -0.165327,0 -0.282961,-0.116899 -0.117632,-0.116899 -0.117833,-0.281394 v -2.788053 q 0,-0.164297 0.117833,-0.281196 0.117834,-0.116899 0.282961,-0.117098 h 2.805562 q 0.165328,0 0.283161,0.117098 0.117834,0.117099 0.117633,0.281196 v 2.788053 q 0,0.164296 -0.117633,0.281394 -0.117633,0.117099 -0.283161,0.116899 z"\n\n style="stroke-width:0.199771" />\n <path\n\n d="m 16.049385,16.724729 q -0.165327,0 -0.282961,-0.116899 -0.117632,-0.116899 -0.117833,-0.281394 v -2.788053 q 0,-0.164297 0.117833,-0.281196 0.117834,-0.116899 0.282961,-0.117098 h 2.805561 q 0.165328,0 0.283161,0.117098 0.117834,0.117099 0.117634,0.281196 v 2.788053 q 0,0.164296 -0.117634,0.281394 -0.117633,0.117099 -0.283161,0.116899 z"\n\n style="stroke-width:0.199771" />\n </svg>\n\n ',onClick:()=>{this.toggleFilmstrip()}}),t.ui.registerElement({name:"filmstrip",isButton:!1,appendTo:"root",html:'\n <div id="filmstrip-container" class="w-full absolute bottom-0">\n </div>\n '})}),t.on("change",()=>{this.filmstripVisible&&this.updateFilmstrip(t)}),t.on("close",()=>{this.cleanupFilmstrip()})}onThumbnailClcik(t){this.lightbox.pswp.goTo(t)}getFilmstripContents(t){const e=t?.options?.dataSource?.items,n=e?.length??0;return this.filmstripContents&&this.filmstripContents.length===n||(this.filmstripContents=(e??[]).map(t=>({id:t.getAttribute("data-pswp-id"),type:t.getAttribute("data-pswp-type"),thumbnailUrl:t.getAttribute("data-pswp-thumbnail-url"),blurImageUrl:t.getAttribute("data-pswp-blur-image-url")||t.getAttribute("data-pswp-blurhash")}))),this.filmstripContents}updateFilmstrip(e){const n=this.getElementById("filmstrip-container");if(!n)return;t(/* @__PURE__ */p(_t,{contents:this.getFilmstripContents(e),selectedIndex:e.currSlide.index,onClick:t=>this.onThumbnailClcik(t)}),n);const i=this.getElementById("pswp-caption-container");i&&"7rem"!==i.style.bottom&&(i.style.bottom="7rem")}toggleFilmstrip(){this.filmstripVisible?this.cleanupFilmstrip():this.updateFilmstrip(this.lightbox.pswp),this.filmstripVisible=!this.filmstripVisible;const t=this.querySelector("#pswp__icn-show-filmstrip"),e=this.querySelector("#pswp__icn-hide-filmstrip");t&&(t.style.display=this.filmstripVisible?"inline":"none"),e&&(e.style.display=this.filmstripVisible?"none":"inline")}cleanupFilmstrip(){const e=this.getElementById("filmstrip-container"),n=this.getElementById("pswp-caption-container");n&&(n.style.bottom="0"),e&&t(null,e),this.filmstripContents=null}},It=class{constructor(t){this.lightbox=t,this.fullscreen=!1,this.options={fullScreenButtonOrder:7},t.on("init",()=>{this.initPswpEvents(t.pswp)})}getRootNode(){return this.lightbox?.pswp?.element?.getRootNode?.()||document}querySelector(t){return this.getRootNode().querySelector?.(t)||document.querySelector(t)}syncFullscreenState(){const t=document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement;this.fullscreen=Boolean(t);const e=this.querySelector("#pswp__icn-exit-fullscreen"),n=this.querySelector("#pswp__icn-fullscreen");e&&(e.style.display=this.fullscreen?"inline":"none"),n&&(n.style.display=this.fullscreen?"none":"inline")}initPswpEvents(t){const e=()=>this.syncFullscreenState();t.events.add(document,"fullscreenchange",e),t.events.add(document,"webkitfullscreenchange",e),t.on("uiRegister",()=>{(document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled)&&t.ui.registerElement({name:"fullscreen-button",title:"Toggle fullscreen view",order:this.options.fullScreenButtonOrder,isButton:!0,html:'<svg aria-hidden="true" class="pswp__icn p-1" viewBox="0 0 24 24"><use class="pswp__icn-shadow" xlink:href="#pswp__icn-fullscreen"/><use class="pswp__icn-shadow" xlink:href="#pswp__icn-exit-fullscreen"/><path id="pswp__icn-fullscreen" d="M5 19h2q.425 0 .713.288T8 20t-.288.713T7 21H4q-.425 0-.712-.288T3 20v-3q0-.425.288-.712T4 16t.713.288T5 17zm14 0v-2q0-.425.288-.712T20 16t.713.288T21 17v3q0 .425-.288.713T20 21h-3q-.425 0-.712-.288T16 20t.288-.712T17 19zM5 5v2q0 .425-.288.713T4 8t-.712-.288T3 7V4q0-.425.288-.712T4 3h3q.425 0 .713.288T8 4t-.288.713T7 5zm14 0h-2q-.425 0-.712-.288T16 4t.288-.712T17 3h3q.425 0 .713.288T21 4v3q0 .425-.288.713T20 8t-.712-.288T19 7z"/><path id="pswp__icn-exit-fullscreen" style="display:none" d="M6 18H4q-.425 0-.712-.288T3 17t.288-.712T4 16h3q.425 0 .713.288T8 17v3q0 .425-.288.713T7 21t-.712-.288T6 20zm12 0v2q0 .425-.288.713T17 21t-.712-.288T16 20v-3q0-.425.288-.712T17 16h3q.425 0 .713.288T21 17t-.288.713T20 18zM6 6V4q0-.425.288-.712T7 3t.713.288T8 4v3q0 .425-.288.713T7 8H4q-.425 0-.712-.288T3 7t.288-.712T4 6zm12 0h2q.425 0 .713.288T21 7t-.288.713T20 8h-3q-.425 0-.712-.288T16 7V4q0-.425.288-.712T17 3t.713.288T18 4z"/></svg>',onClick:()=>{this.toggleFullscreen(t)}})})}toggleFullscreen(t){const e=t.element;this.fullscreen?(document.exitFullscreen?document.exitFullscreen():document.webkitExitFullscreen?document.webkitExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen(),t.options.showHideAnimationType="zoom",this.fullscreen=!1):(e.requestFullscreen?e.requestFullscreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.msRequestFullscreen&&e.msRequestFullscreen(),t.options.showHideAnimationType="fade",this.fullscreen=!0);const n=this.querySelector("#pswp__icn-exit-fullscreen"),i=this.querySelector("#pswp__icn-fullscreen");n&&(n.style.display=this.fullscreen?"inline":"none"),i&&(i.style.display=this.fullscreen?"none":"inline")}},Ct=class{constructor(t,e={}){this.lightbox=t,this.autoHideTimer=null,this.uiVisible=!0,this.options=Object.assign({defaultDelayMs:4e3,playPauseButtonOrder:9,progressBarPosition:"top",progressBarTransition:"ease",restartOnSlideChange:!0,autoHideProgressBar:!0},e),this.setSlideshowLength(Number(localStorage.getItem("pswp_delay"))||this.options.defaultDelayMs),this.slideshowIsRunning=!1,this.slideshowTimerID=null,this.wakeLockIsRunning=!1,this.wakeLockSentinel=null,this.lightbox.on("init",()=>{this.init(this.lightbox.pswp)})}getRootNode(){return this.lightbox?.pswp?.element?.getRootNode?.()||document}querySelector(t){return this.getRootNode().querySelector?.(t)||document.querySelector(t)}injectProgressBarStyles(){const t=this.getRootNode(),e=t===document?document.head:t;if(!e||e.querySelector("style[data-pswp-slideshow]"))return;const n=document.createElement("style");n.setAttribute("data-pswp-slideshow",""),n.textContent=`.pswp__progress-bar{position:fixed;${this.options.progressBarPosition}:0;width:0;height:0}.pswp__progress-bar.running{width:100%;height:2px;transition-property:width;background:#ff4800}`,e.appendChild(n)}init(t){t.on("uiRegister",()=>{this.injectProgressBarStyles(),t.ui.registerElement({name:"playpause-button",title:"Toggle slideshow (Space)\nChange delay with +/- while running",order:this.options.playPauseButtonOrder,isButton:!0,html:'<svg aria-hidden="true" class="pswp__icn" viewBox="0 0 24 24"><use class="pswp__icn-shadow" xlink:href="#pswp__icn-play"/><use class="pswp__icn-shadow" xlink:href="#pswp__icn-stop"/><path id="pswp__icn-play" d="M8 17.175V6.825q0-.425.3-.713t.7-.287q.125 0 .263.037t.262.113l8.15 5.175q.225.15.338.375t.112.475t-.112.475t-.338.375l-8.15 5.175q-.125.075-.262.113T9 18.175q-.4 0-.7-.288t-.3-.712"/><path id="pswp__icn-stop" style="display:none" d="M16 19q-.825 0-1.412-.587T14 17V7q0-.825.588-1.412T16 5t1.413.588T18 7v10q0 .825-.587 1.413T16 19m-8 0q-.825 0-1.412-.587T6 17V7q0-.825.588-1.412T8 5t1.413.588T10 7v10q0 .825-.587 1.413T8 19"/></svg>',onClick:()=>{this.setSlideshowState()}}),t.ui.registerElement({name:"playtime",appendTo:"wrapper",tagName:"div",className:"pswp__progress-bar"}),t.events.add(document,"keydown",t=>{switch(t.code){case"Space":this.setSlideshowState(),t.preventDefault();break;case"ArrowUp":case"NumpadAdd":case"Equal":this.changeSlideshowLength(1e3),t.preventDefault();break;case"ArrowDown":case"NumpadSubtract":case"Minus":this.changeSlideshowLength(-1e3),t.preventDefault()}})}),this.lightbox.on("change",()=>{this.slideshowIsRunning&&this.options.restartOnSlideChange&&this.goToNextSlideAfterTimeout()}),this.lightbox.on("close",()=>{this.slideshowIsRunning&&this.setSlideshowState()})}showUI(){this.lightbox&&this.lightbox.pswp&&this.lightbox.pswp.element&&this.lightbox.pswp.element.classList.add("pswp--ui-visible"),this.uiVisible=!0}stopAutoHideTimer(){this.autoHideTimer&&(clearTimeout(this.autoHideTimer),this.autoHideTimer=null)}hideUI(){this.lightbox&&this.lightbox.pswp&&this.lightbox.pswp.element&&this.lightbox.pswp.element.classList.remove("pswp--ui-visible"),this.uiVisible=!1}resetAutoHideTimer(){this.autoHideTimer&&clearTimeout(this.autoHideTimer),this.autoHideTimer=setTimeout(()=>{this.slideshowIsRunning&&this.hideUI(),this.autoHideTimer=null},[3e3])}setSlideshowState(){this.slideshowIsRunning=!this.slideshowIsRunning,this.slideshowIsRunning?(this.goToNextSlideAfterTimeout(),this.showUI(),this.resetAutoHideTimer(),document.addEventListener("touchstart",()=>{this.stopAutoHideTimer(),this.showUI()}),document.addEventListener("touchend",()=>{this.resetAutoHideTimer()}),document.addEventListener("mousemove",()=>{this.uiVisible||this.showUI(),this.resetAutoHideTimer()})):(this.showUI(),this.resetSlideshow(),this.stopAutoHideTimer());const t=this.querySelector("#pswp__icn-stop"),e=this.querySelector("#pswp__icn-play");t&&(t.style.display=this.slideshowIsRunning?"inline":"none"),e&&(e.style.display=this.slideshowIsRunning?"none":"inline");const n=this.querySelector(".pswp__progress-bar");n&&(n.style.opacity=this.options.autoHideProgressBar?null:1),this.toggleWakeLock()}setSlideshowLength(t){this.options.defaultDelayMs=Math.min(Math.max(t,1e3),2147483647),this.options.defaultDelayMs!=t&&localStorage.setItem("pswp_delay",this.options.defaultDelayMs)}changeSlideshowLength(t){if(!this.slideshowIsRunning)return;this.setSlideshowLength(this.options.defaultDelayMs+t),localStorage.setItem("pswp_delay",this.options.defaultDelayMs);const e=this.querySelector(".pswp__counter");e&&(e.innerHTML=this.options.defaultDelayMs/1e3+"s"),this.goToNextSlideAfterTimeout()}isVideoContent(t){return"video"===t?.data?.type}getSlideTimeout(){const t=this.lightbox.pswp.currSlide.content;if(this.isVideoContent(t)){const e=t.element;if(e.paused)return this.options.defaultDelayMs;const n=e.duration,i=e.currentTime;return isNaN(n)||isNaN(i)?this.options.defaultDelayMs:1e3*(n-i)}return this.options.defaultDelayMs}slideContentHasLoaded(){const t=this.lightbox.pswp.currSlide.content;if(this.isVideoContent(t)){const e=t.element;return e.ended||e.readyState===HTMLMediaElement.HAVE_ENOUGH_DATA&&[HTMLMediaElement.NETWORK_IDLE,HTMLMediaElement.NETWORK_LOADING].includes(e.networkState)}return!t.isLoading()}goToNextSlideAfterTimeout(){if(this.resetSlideshow(),this.slideContentHasLoaded()){const t=this.getSlideTimeout();this.slideshowTimerID=setTimeout(()=>{this.lightbox.pswp.next(),this.options.restartOnSlideChange||this.goToNextSlideAfterTimeout()},t),setTimeout(()=>{this.slideshowIsRunning&&this.toggleProgressBar(t)},100)}else this.slideshowTimerID=setTimeout(()=>{this.goToNextSlideAfterTimeout()},200)}getSlideTransition(){return this.isVideoContent(this.lightbox.pswp.currSlide.content)?"linear":this.options.progressBarTransition}toggleProgressBar(t){const e=this.querySelector(".pswp__progress-bar");e&&(t?(e.style.transitionTimingFunction=this.getSlideTransition(),e.style.transitionDuration=`${t}ms`,e.classList.add("running")):e.classList.remove("running"))}toggleWakeLock(){this.wakeLockIsRunning!=this.slideshowIsRunning&&("keepAwake"in screen?screen.keepAwake=this.slideshowIsRunning:"wakeLock"in navigator&&(this.wakeLockSentinel?this.wakeLockSentinel.release().then(()=>(this.wakeLockSentinel=null,!0)).catch(t=>console.error(t)):navigator.wakeLock.request("screen").then(t=>(this.wakeLockSentinel=t,this.wakeLockSentinel.addEventListener("release",()=>{this.wakeLockSentinel=null,this.wakeLockIsRunning=!1}),!0)).catch(t=>{})),this.wakeLockIsRunning=this.slideshowIsRunning)}resetSlideshow(){this.toggleProgressBar(),this.slideshowTimerID&&(clearTimeout(this.slideshowTimerID),this.slideshowTimerID=null)}},Lt={[String(E.NONE)]:function({className:t}){/* @__PURE__ */
|
|
4
|
-
return p("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:t,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */p("path",{fill:"currentColor",d:"M5 21q-.825 0-1.412-.587T3 19V5q0-.825.588-1.412T5 3h14q.825 0 1.413.588T21 5v14q0 .825-.587 1.413T19 21zm0-2h14V5H5z"})})},[E.LINK]:function({className:t}){/* @__PURE__ */
|
|
5
|
-
return p("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:t,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */p("path",{fill:"currentColor",d:"M7.95 21q-2.05 0-3.5-1.45T3 16.05q0-1 .375-1.9t1.075-1.6l2.625-2.625q.3-.3.713-.3t.712.3t.3.7t-.3.7l-2.65 2.65q-.425.425-.637.963T5 16.05q0 1.225.863 2.088T7.95 19q.575 0 1.125-.213t.975-.637l2.625-2.65q.3-.275.7-.275t.7.3t.3.7t-.3.7L11.45 19.55q-.7.7-1.6 1.075T7.95 21m1.25-6.2q-.3-.3-.3-.712t.3-.713L13.375 9.2q.3-.3.713-.3t.712.3t.3.713t-.3.712L10.625 14.8q-.3.3-.712.3t-.713-.3m6.3-.725q-.3-.3-.3-.7t.3-.7l2.65-2.625q.425-.425.625-.95t.2-1.1q0-1.25-.85-2.125T16.025 5q-.575 0-1.112.213t-.963.637L11.325 8.5q-.3.3-.7.3t-.7-.3t-.3-.712t.3-.713L12.55 4.45q.7-.7 1.6-1.075T16.05 3q2.05 0 3.488 1.45t1.437 3.525q0 .975-.363 1.875t-1.062 1.6l-2.625 2.625q-.3.3-.712.3t-.713-.3"})})},[E.EMAIL]:function({className:t}){/* @__PURE__ */
|
|
6
|
-
return p("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:t,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */p("path",{fill:"currentColor",d:"M12 22q-2.075 0-3.9-.788t-3.175-2.137T2.788 15.9T2 12t.788-3.9t2.137-3.175T8.1 2.788T12 2t3.9.788t3.175 2.137T21.213 8.1T22 12v1.45q0 1.475-1.012 2.513T18.5 17q-.875 0-1.65-.375t-1.3-1.075q-.725.725-1.638 1.088T12 17q-2.075 0-3.537-1.463T7 12t1.463-3.537T12 7t3.538 1.463T17 12v1.45q0 .65.425 1.1T18.5 15t1.075-.45t.425-1.1V12q0-3.35-2.325-5.675T12 4T6.325 6.325T4 12t2.325 5.675T12 20h4q.425 0 .713.288T17 21t-.288.713T16 22zm2.125-7.875Q15 13.25 15 12t-.875-2.125T12 9t-2.125.875T9 12t.875 2.125T12 15t2.125-.875"})})},[E.PHONE]:function({className:t}){/* @__PURE__ */
|
|
7
|
-
return p("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:t,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */p("path",{fill:"currentColor",d:"M19.95 21q-3.125 0-6.175-1.362t-5.55-3.863t-3.862-5.55T3 4.05q0-.45.3-.75t.75-.3H8.1q.35 0 .625.238t.325.562l.65 3.5q.05.4-.025.675T9.4 8.45L6.975 10.9q.5.925 1.187 1.787t1.513 1.663q.775.775 1.625 1.438T13.1 17l2.35-2.35q.225-.225.588-.337t.712-.063l3.45.7q.35.1.575.363T21 15.9v4.05q0 .45-.3.75t-.75.3M6.025 9l1.65-1.65L7.25 5H5.025q.125 1.025.35 2.025T6.025 9m8.95 8.95q.975.425 1.988.675T19 18.95v-2.2l-2.35-.475zm0 0"})})},[E.SMS]:function({className:t}){/* @__PURE__ */
|
|
8
|
-
return p("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:t,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */p("path",{fill:"currentColor",d:"m6 18l-2.3 2.3q-.475.475-1.088.213T2 19.575V4q0-.825.588-1.412T4 2h16q.825 0 1.413.588T22 4v12q0 .825-.587 1.413T20 18zm-.85-2H20V4H4v13.125zM4 16V4zm4.713-5.288Q9 10.425 9 10t-.288-.712T8 9t-.712.288T7 10t.288.713T8 11t.713-.288m4 0Q13 10.426 13 10t-.288-.712T12 9t-.712.288T11 10t.288.713T12 11t.713-.288m4 0Q17 10.426 17 10t-.288-.712T16 9t-.712.288T15 10t.288.713T16 11t.713-.288"})})},[E.WHATSAPP]:function({className:t}){/* @__PURE__ */
|
|
9
|
-
return p("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 256 258",className:t,"aria-hidden":"true",focusable:"false",children:[
|
|
10
|
-
/* @__PURE__ */p("defs",{children:[/* @__PURE__ */p("linearGradient",{id:"SVGK3KZq49U",x1:"50%",x2:"50%",y1:"100%",y2:"0%",children:[/* @__PURE__ */p("stop",{offset:"0%","stop-color":"#1faf38"}),/* @__PURE__ */p("stop",{offset:"100%","stop-color":"#60d669"})]}),/* @__PURE__ */p("linearGradient",{id:"SVGefMkoEOd",x1:"50%",x2:"50%",y1:"100%",y2:"0%",children:[/* @__PURE__ */p("stop",{offset:"0%","stop-color":"#f9f9f9"}),/* @__PURE__ */p("stop",{offset:"100%","stop-color":"#fff"})]})]}),
|
|
11
|
-
/* @__PURE__ */p("path",{fill:"url(#SVGK3KZq49U)",d:"M5.463 127.456c-.006 21.677 5.658 42.843 16.428 61.499L4.433 252.697l65.232-17.104a123 123 0 0 0 58.8 14.97h.054c67.815 0 123.018-55.183 123.047-123.01c.013-32.867-12.775-63.773-36.009-87.025c-23.23-23.25-54.125-36.061-87.043-36.076c-67.823 0-123.022 55.18-123.05 123.004"}),
|
|
12
|
-
/* @__PURE__ */p("path",{fill:"url(#SVGefMkoEOd)",d:"M1.07 127.416c-.007 22.457 5.86 44.38 17.014 63.704L0 257.147l67.571-17.717c18.618 10.151 39.58 15.503 60.91 15.511h.055c70.248 0 127.434-57.168 127.464-127.423c.012-34.048-13.236-66.065-37.3-90.15C194.633 13.286 162.633.014 128.536 0C58.276 0 1.099 57.16 1.071 127.416m40.24 60.376l-2.523-4.005c-10.606-16.864-16.204-36.352-16.196-56.363C22.614 69.029 70.138 21.52 128.576 21.52c28.3.012 54.896 11.044 74.9 31.06c20.003 20.018 31.01 46.628 31.003 74.93c-.026 58.395-47.551 105.91-105.943 105.91h-.042c-19.013-.01-37.66-5.116-53.922-14.765l-3.87-2.295l-40.098 10.513z"}),
|
|
13
|
-
/* @__PURE__ */p("path",{fill:"#fff",d:"M96.678 74.148c-2.386-5.303-4.897-5.41-7.166-5.503c-1.858-.08-3.982-.074-6.104-.074c-2.124 0-5.575.799-8.492 3.984c-2.92 3.188-11.148 10.892-11.148 26.561s11.413 30.813 13.004 32.94c1.593 2.123 22.033 35.307 54.405 48.073c26.904 10.609 32.379 8.499 38.218 7.967c5.84-.53 18.844-7.702 21.497-15.139c2.655-7.436 2.655-13.81 1.859-15.142c-.796-1.327-2.92-2.124-6.105-3.716s-18.844-9.298-21.763-10.361c-2.92-1.062-5.043-1.592-7.167 1.597c-2.124 3.184-8.223 10.356-10.082 12.48c-1.857 2.129-3.716 2.394-6.9.801c-3.187-1.598-13.444-4.957-25.613-15.806c-9.468-8.442-15.86-18.867-17.718-22.056c-1.858-3.184-.199-4.91 1.398-6.497c1.431-1.427 3.186-3.719 4.78-5.578c1.588-1.86 2.118-3.187 3.18-5.311c1.063-2.126.531-3.986-.264-5.579c-.798-1.593-6.987-17.343-9.819-23.64"})]})},[E.MESSENGER]:function({className:t}){/* @__PURE__ */
|
|
14
|
-
return p("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 256 256",className:t,"aria-hidden":"true",focusable:"false",children:[
|
|
15
|
-
/* @__PURE__ */p("defs",{children:/* @__PURE__ */p("radialGradient",{id:"SVGhphmYc3G",cx:"19.247%",cy:"99.465%",r:"108.96%",fx:"19.247%",fy:"99.465%",children:[
|
|
16
|
-
/* @__PURE__ */p("stop",{offset:"0%","stop-color":"#09f"}),
|
|
17
|
-
/* @__PURE__ */p("stop",{offset:"60.975%","stop-color":"#a033ff"}),
|
|
18
|
-
/* @__PURE__ */p("stop",{offset:"93.482%","stop-color":"#ff5280"}),
|
|
19
|
-
/* @__PURE__ */p("stop",{offset:"100%","stop-color":"#ff7061"})]})}),
|
|
20
|
-
/* @__PURE__ */p("path",{fill:"url(#SVGhphmYc3G)",d:"M128 0C55.894 0 0 52.818 0 124.16c0 37.317 15.293 69.562 40.2 91.835c2.09 1.871 3.352 4.493 3.438 7.298l.697 22.77c.223 7.262 7.724 11.988 14.37 9.054L84.111 243.9a10.22 10.22 0 0 1 6.837-.501c11.675 3.21 24.1 4.92 37.052 4.92c72.106 0 128-52.818 128-124.16S200.106 0 128 0"}),
|
|
21
|
-
/* @__PURE__ */p("path",{fill:"#fff",d:"m51.137 160.47l37.6-59.653c5.98-9.49 18.788-11.853 27.762-5.123l29.905 22.43a7.68 7.68 0 0 0 9.252-.027l40.388-30.652c5.39-4.091 12.428 2.36 8.82 8.085l-37.6 59.654c-5.981 9.489-18.79 11.852-27.763 5.122l-29.906-22.43a7.68 7.68 0 0 0-9.25.027l-40.39 30.652c-5.39 4.09-12.427-2.36-8.818-8.085"})]})}},Mt=({open:t,ad:e,onClose:n,captureAdClick:i})=>{const s=Boolean(e?.targetType&&e.targetType!==E.NONE),o=Lt[e?.targetType]??Lt[E.LINK],r=e?.imageUrl&&F(e.imageUrl,["http:","https:"])?e.imageUrl:void 0;/* @__PURE__ */
|
|
22
|
-
return p(et,{open:Boolean(t&&e),onOpenChange:t=>!t&&n?.(),children:/* @__PURE__ */p(J,{className:"border-none p-0",children:[/* @__PURE__ */p(Z,{className:"sr-only",children:[/* @__PURE__ */p(X,{children:e?.title}),/* @__PURE__ */p(tt,{children:e?.description})]}),/* @__PURE__ */p("div",{className:"flex max-w-2xl flex-col overflow-hidden",children:[r&&/* @__PURE__ */p("img",{className:"h-auto w-full object-contain sm:max-h-96",src:r,alt:e?.title||"Advertisement"}),
|
|
23
|
-
/* @__PURE__ */p("div",{className:"flex flex-col gap-2 p-3",children:[/* @__PURE__ */p(B,{variant:"h4",align:"center",lines:2,children:e?.title}),/* @__PURE__ */p(B,{variant:"body3",color:"secondary",align:"center",lines:4,children:e?.description})]}),s&&/* @__PURE__ */p(A,{fullWidth:!0,className:"rounded-none",onClick:()=>{i?.(e?._id,e?.targetType??E.LINK,e?.targetUrl),n?.()},icon:/* @__PURE__ */p(o,{className:"size-5"}),children:e?.targetText})]})]})})},Rt=({style:t,content:e,curateLink:n,onAdClick:i,hideControls:s})=>{const{captureAdImpression:o,captureAdEngagement:r,captureAdClick:l}=G(),a=Boolean(n&&i),c=e.ctaBg||"#ff4800",d=e.ctaForeground||"#FFFFFF",h=Lt[e?.targetType??E.LINK];/* @__PURE__ */
|
|
24
|
-
return p("div",{style:t,className:"group relative mb-1 overflow-hidden rounded",children:[
|
|
25
|
-
/* @__PURE__ */p(V,{className:"size-full",threshold:.8,triggerOnce:!0,onChange:t=>{t&&o(e._id)},onClick:()=>r(e._id),children:/* @__PURE__ */p(D,{url:e.src||e.imageUrl,thumbnailUrl:e.src||e.imageUrl,blurhash:e.blurhash,alt:e.caption,onClick:a?i:void 0,pswpData:{id:e._id,type:N.AD,hash:e._id,width:e.width,height:e.height,title:e.title,description:e.description,targetType:e.targetType,targetText:e.targetText,targetUrl:e.targetUrl,thumbnailUrl:e.imageUrl,blurhash:e.blurhash}})}),
|
|
26
|
-
/* @__PURE__ */p("span",{className:"bg-background/70 absolute top-1 right-1 rounded px-1 text-xs font-medium",children:"Ad"}),!s&&(e.title||e.targetType!==E.NONE)&&/* @__PURE__ */p("div",{className:"absolute bottom-0 flex w-full flex-col lg:opacity-0 lg:transition-opacity lg:group-hover:opacity-100",children:[e.title&&/* @__PURE__ */p("div",{className:"bg-background/60 px-3 py-1",children:/* @__PURE__ */p("h3",{className:"line-clamp-1 text-sm font-medium",children:e.title})}),e?.targetType!==E.NONE&&/* @__PURE__ */p("button",{className:"flex w-full items-center justify-center gap-1 rounded-none border-0 py-2 text-nowrap sm:gap-2",style:{backgroundColor:c,color:d},onClick:()=>{a?i?.():l(e._id,e.targetType,e.targetUrl)},children:[/* @__PURE__ */p("span",{style:{color:d},children:/* @__PURE__ */p(h,{})}),e?.targetText]})]})]})},Bt=({style:t,gamConfig:e,slotIndex:n,eventId:i,organizationId:s})=>{const l=r(null),a=r(null),{trackGamAnalytics:c}=G(),d=`gam-slot-${i??"ev"}-${n}`,h=Math.max(1,Math.round(t?.width||e.sizes[0]?.[0]||300)),u=Math.max(1,Math.round(t?.height||e.sizes[0]?.[1]||250)),m=r({w:h,h:u});return o(()=>{let t=!1,n=null,o=null,r=null,h=null;return(async()=>{await j(),!t&&l.current&&window.googletag.cmd.push(()=>{if(t)return;Q(d);const{w:u,h:p}=m.current,g=[[u,p],...e.sizes],f=window.googletag.defineSlot(e.adUnitPath,g,d)?.addService(window.googletag.pubads());if(!f)return;a.current=f,o=window.googletag.pubads(),i?f.setConfig({targeting:{qrati_event:i,...e.categories.length>0?{qrati_category:e.categories}:{}}}):e.categories.length>0&&f.setConfig({targeting:{qrati_category:e.categories}}),r=t=>{t.slot===f&&c({eventId:i,organizationId:s,type:w.GAM_IMPRESSION,creativeId:String(t.creativeId??""),lineItemId:String(t.lineItemId??""),advertiserId:String(t.advertiserId??""),isEmpty:t.isEmpty??!1})},o.addEventListener("slotRenderEnded",r),h=t=>{t.slot===f&&c({eventId:i,organizationId:s,type:w.GAM_VIEWABLE})},o.addEventListener("impressionViewable",h);const T=l.current;T&&(n=Y({container:T,onClick:()=>{c({eventId:i,organizationId:s,type:w.GAM_CLICK})}}),$(),window.googletag.display(d))})})(),()=>{t=!0,n?.(),o&&"function"==typeof o.removeEventListener&&(r&&o.removeEventListener("slotRenderEnded",r),h&&o.removeEventListener("impressionViewable",h));const e=a.current;a.current=null,e&&window.googletag?.cmd?.push(()=>{window.googletag.destroySlots([e])})}},[i,e.adUnitPath,e.categories,s,d]),/* @__PURE__ */p("div",{style:{width:h,height:u},className:"relative overflow-hidden rounded bg-neutral-100 dark:bg-neutral-800","data-gam-slot-index":n,children:/* @__PURE__ */p("div",{id:d,ref:l,style:{width:h,height:u},className:"gam-ad-slot"})})},At=(t,e)=>{if(!t||!e)return null;const n=e[t];if(!n)return null;try{const t=new Date(String(n)),e=/* @__PURE__ */new Date,i=t.getFullYear()===e.getFullYear(),s={weekday:"long",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit",hour12:!0};return i||(s.year="numeric"),t.toLocaleString("en-US",s).replace(","," •")}catch{return null}},Vt=n(null),zt=()=>{const t=f(Vt);if(!t)throw new Error("Popover components must be used within a Popover");return t},Ot=({children:t,className:e,open:n,onOpenChange:i})=>{const[s,o]=a(!1),c="boolean"==typeof n,d=c?n:s,h=l(),u=`popover-trigger-${h}`,m=`popover-content-${h}`,g=r(null);/* @__PURE__ */
|
|
27
|
-
return p(Vt.Provider,{value:{isOpen:d,setIsOpen:t=>{c||o(t),i?.(t)},triggerId:u,contentId:m,triggerRef:g},children:/* @__PURE__ */p("div",{"data-slot":"popover",className:x("relative inline-block",e),children:t})})},Ft=({children:t,asChild:e,className:n,onClick:s,...o})=>{const{isOpen:r,setIsOpen:l,triggerId:a,contentId:c,triggerRef:d}=zt();if(e){const e=Array.isArray(t)?t[0]:t;if(e&&e.type){const t=e.props?.className;return i(e,{ref:t=>{d.current=t},id:a,className:n?t?`${t} ${n}`:n:t,"aria-haspopup":"dialog","aria-expanded":r,"aria-controls":r?c:void 0,onClick:t=>{l(!r),e.props?.onClick?.(t)},"data-state":r?"open":"closed"})}}/* @__PURE__ */
|
|
28
|
-
return p("button",{ref:d,id:a,type:"button","aria-haspopup":"dialog","aria-expanded":r,"aria-controls":r?c:void 0,"data-slot":"popover-trigger","data-state":r?"open":"closed",className:n,onClick:t=>{l(!r),s?.(t)},...o,children:t})},Pt=({children:t,className:e,align:n="center",side:i="top",sideOffset:s=4,...l})=>{const{isOpen:c,setIsOpen:u,contentId:m,triggerRef:g}=zt(),{organization:f,portalContainer:w}=_(),T=r(null),[y,b]=a(null);if(d(()=>{if(!c)return;const t=()=>{if(!g.current||!T.current)return;const t=g.current.getBoundingClientRect(),e=T.current.getBoundingClientRect();let o=t.left,r=t.bottom+s;"center"===n&&(o=t.left+t.width/2-e.width/2),"end"===n&&(o=t.right-e.width),"top"===i&&(r=t.top-e.height-s),"left"===i&&(o=t.left-e.width-s,r=t.top+t.height/2-e.height/2),"right"===i&&(o=t.right+s,r=t.top+t.height/2-e.height/2),"bottom"===i&&(r=t.bottom+s),b({top:r,left:o})},e=requestAnimationFrame(t);return window.addEventListener("resize",t),window.addEventListener("scroll",t,!0),()=>{cancelAnimationFrame(e),window.removeEventListener("resize",t),window.removeEventListener("scroll",t,!0)}},[n,c,i,s,g]),o(()=>{if(!c)return;const t=t=>{const e="function"==typeof t.composedPath?t.composedPath():[],n=t.target,i=T.current&&(T.current.contains(n)||e.includes(T.current)),s=g.current&&(g.current.contains(n)||e.includes(g.current));i||s||u(!1)},e=t=>{"Escape"===t.key&&(u(!1),g.current?.focus())},n=window.setTimeout(()=>{document.addEventListener("mousedown",t)},0);return document.addEventListener("keydown",e),()=>{window.clearTimeout(n),document.removeEventListener("mousedown",t),document.removeEventListener("keydown",e)}},[c,u,g]),!c)return null;const v=/* @__PURE__ */p("div",{ref:T,id:m,role:"dialog","aria-modal":"false","data-state":c?"open":"closed",className:x("bg-background text-foreground border-border shadow-outer rounded outline-none",e),style:{position:"fixed",top:y?.top??0,left:y?.left??0,zIndex:2010,...q(f)},...l,children:t});return"undefined"!=typeof document?h(v,w??document.body):v},Dt=({eventId:t,contentId:e,emojis:n=[],counts:i={},userReaction:s})=>{const{user:l,props:c,organization:d}=_(),h=c?.loginUrl,{handleReactionClick:u,isPending:m}=(()=>{const t=y(),{props:e,user:n}=_(),i=e?.organizationId,s=L({mutationFn:async({eventId:t,contentId:e,emoji:s})=>{await b.post(S.UPDATE_REACTION,{json:{eventId:t,contentId:e,reaction:s},headers:{"x-org-id":i,Authorization:`Bearer ${n?.token}`}})},onMutate:async({eventId:e,contentId:n,emoji:i})=>{const s=[v.CONTENTS_BY_EVENT(e)];await t.cancelQueries({queryKey:s});const o=t.getQueriesData({queryKey:s});return t.setQueriesData({queryKey:s},t=>((t,e,n)=>t?.pages&&Array.isArray(t.pages)?{...t,pages:t.pages.map(t=>t.data?{...t,data:t.data.map(t=>{if(t._id!==e)return t;const i={...t.reactionCounts??{}};return t.userReaction&&t.userReaction!==n&&(i[t.userReaction]=Math.max(0,(i[t.userReaction]??1)-1)),t.userReaction===n?(i[n]=Math.max(0,(i[n]??1)-1),{...t,reactionCounts:i,userReaction:void 0}):(i[n]=(i[n]??0)+1,{...t,reactionCounts:i,userReaction:n})})}:t)}:t)(t,n,i)),{previousData:o}},onError:(e,n,i)=>{i?.previousData?.forEach(([e,n])=>{t.setQueryData(e,n)}),H.error("Failed to add reaction"),console.error("Error handling reaction click:",e,n)}});return{handleReactionClick:async(t,e,i)=>{if(!t||!e||!i)return!1;if(!n)return H.error("Please login to react"),!1;try{return await s.mutateAsync({eventId:t,contentId:e,emoji:i}),!0}catch(o){return!1}},isPending:s.isPending}})(),[g,f]=a(!1),[w,k]=a(null),q=r(null),E=Object.values(i).reduce((t,e)=>t+e,0);return o(()=>()=>{q.current&&clearTimeout(q.current)},[]),/* @__PURE__ */p(Ot,{open:g,onOpenChange:f,children:[/* @__PURE__ */p(Ft,{asChild:!0,children:/* @__PURE__ */p("button",{type:"button",className:x("bg-background/50 flex items-center gap-1 rounded px-2 py-1 backdrop-blur-sm transition-transform duration-150 ease-out will-change-transform active:scale-95 sm:gap-2 sm:py-0",w&&"scale-[1.03] shadow-sm"),children:[(n||[]).slice().sort((t,e)=>(i[e]||0)-(i[t]||0)).slice(0,1).map(t=>/* @__PURE__ */p("span",{className:x("text-sm transition-transform duration-150 ease-out sm:text-lg",w===(s||t)&&"scale-125"),children:s||t},`${e}-${t}-1`)),E>0&&/* @__PURE__ */p("span",{className:"text-xs font-bold sm:text-sm",children:E||0})]})}),/* @__PURE__ */p(Pt,{side:"top",align:"end",children:[l?null:/* @__PURE__ */p("div",d?.customAuth?{className:"p-2 font-semibold",children:["Please"," ",
|
|
29
|
-
/* @__PURE__ */p("a",{className:"text-info underline",href:h,children:"Login"})," ","to react"]}:{className:"p-2 font-semibold",children:["Please"," ",
|
|
30
|
-
/* @__PURE__ */p(R,{className:"text-info underline",to:T.LOGIN,children:"Login"})," ","to react"]}),l&&/* @__PURE__ */p("div",{className:"flex gap-1 p-2",children:n.map(n=>{const o=s===n;/* @__PURE__ */
|
|
31
|
-
return p("div",{className:"flex flex-col items-center",children:[/* @__PURE__ */p("span",{className:"text-xs font-medium",children:i[n]||0}),/* @__PURE__ */p("button",{type:"button",disabled:m,className:x("text-3xl transition-transform duration-150 ease-out disabled:opacity-50",o?"scale-125":"hover:scale-110",w===n&&"scale-125",m&&"cursor-not-allowed"),onClick:()=>(async n=>{!m&&u&&(k(n),f(!1),q.current&&clearTimeout(q.current),q.current=setTimeout(()=>k(null),180),u(t,e,n))})(n),children:n})]},`${e}-${n}-2`)})})]})]})},Ut=({event:t={},content:e,curateLink:n})=>t.engagementStyle===I.CONTEST?/* @__PURE__ */p("button",{className:"bg-background/75 flex items-center gap-1 rounded px-2 py-1",children:[/* @__PURE__ */p(K,{className:"size-4"}),/* @__PURE__ */p("span",{className:"text-xs font-semibold",children:parseFloat(String(e.score||0)).toFixed(1)})]}):t.engagementStyle===I.REACTION&&t.reactionEmojis?.length?/* @__PURE__ */p(Dt,{eventId:t?._id,contentId:e._id,emojis:t?.reactionEmojis,engagementStyle:t?.engagementStyle,counts:e.reactionCounts||{},userReaction:e.userReaction}):null,Ht=({content:t})=>/* @__PURE__ */p("div",{className:"w-full space-y-3 px-3 pb-3",children:[t?.caption&&/* @__PURE__ */p("span",{"data-tooltip-target":"tooltip-default",className:"hidden w-full text-xs drop-shadow-[0_1.2px_1.2px_rgba(0,0,0,0.8)] sm:block",children:/* @__PURE__ */p("div",{role:"note",title:t?.caption,className:"lg:text-md line-clamp-1 text-xs text-white lg:font-medium",children:t?.caption})}),/* @__PURE__ */p("div",{className:"flex items-center justify-between",children:/* @__PURE__ */p("span",{className:"lg:text-md line-clamp-1 text-sm font-medium text-white drop-shadow-[0_1.2px_1.2px_rgba(0,0,0,0.8)]",children:t?.user?.name})})]}),jt=({event:t,content:e,style:n,timestampField:i,curateLink:s,onChangeFaceUrl:o,hideControls:r,showQuickSearch:l})=>{const a=`content-${e._id}`,c=u(()=>At(i,e),[i,e]),d=m(()=>{o?.(e?.url);const t=document.getElementById("media-gallery-container");t&&t.scrollIntoView({behavior:"smooth",block:"start"})},[o,e?.url]),h=u(()=>({id:e._id,type:N.IMAGE,hash:e._id,width:e.width,height:e.height,thumbnailUrl:e.thumbnailUrl,blurhash:e.blurhash,caption:e.caption}),[e._id,e.width,e.height,e.thumbnailUrl,e.blurhash,e.caption]);/* @__PURE__ */
|
|
32
|
-
return p("div",{id:a,style:n,className:"group relative mb-1 overflow-hidden rounded [content-visibility:auto]",children:[/* @__PURE__ */p(D,{url:e.src,alt:e.caption,blurhash:e.blurhash,thumbnailUrl:e.thumbnailUrl,curateLink:s,pswpData:h}),!r&&/* @__PURE__ */p(g,{children:[c&&/* @__PURE__ */p("div",{className:"absolute top-2 left-2 max-w-[calc(100%-80px)] truncate rounded bg-black/50 px-2 py-0.5 text-xs text-white backdrop-blur-sm",children:c}),l&&(e.faces?.length??0)>0&&/* @__PURE__ */p("button",{className:"bg-primary absolute top-2 right-2 rounded-full p-1 text-gray-200 opacity-50 transition-all sm:p-1.5 sm:hover:scale-110 sm:hover:opacity-100",onClick:d,children:/* @__PURE__ */p(W,{className:"text-primary-foreground"})}),
|
|
33
|
-
/* @__PURE__ */p("div",{className:"",children:[/* @__PURE__ */p("div",{className:"absolute bottom-0 w-full rounded-b",children:/* @__PURE__ */p(Ht,{content:e})}),/* @__PURE__ */p("div",{className:"absolute right-2 bottom-2",children:/* @__PURE__ */p(Ut,{event:t,content:e,curateLink:s})})]})]})]})},$t=({content:t,style:e,event:n,timestampField:i,curateLink:s,hideControls:o})=>{const r=u(()=>At(i,t),[i,t]);/* @__PURE__ */
|
|
34
|
-
return p("div",{id:`content-${t._id}`,className:"group relative mb-1 overflow-hidden rounded [content-visibility:auto]",style:e,children:[/* @__PURE__ */p(D,{url:t.src??t.url,thumbnailUrl:t.thumbnailUrl,blurhash:t.blurhash,alt:t.caption,curateLink:s,pswpData:{id:t._id,type:N.VIDEO,hash:t._id,width:t.width,height:t.height,thumbnailUrl:t.thumbnailUrl,blurhash:t.blurhash,caption:t.caption}}),!o&&/* @__PURE__ */p("div",{className:"transition-opacity duration-500",children:[r&&/* @__PURE__ */p("div",{className:"absolute top-2 left-2 max-w-[calc(100%-80px)] truncate rounded bg-black/50 px-2 py-0.5 text-xs text-white backdrop-blur-sm",children:r}),
|
|
35
|
-
/* @__PURE__ */p("div",{className:"absolute bottom-0 w-full rounded-b",children:/* @__PURE__ */p(Ht,{content:t})}),
|
|
36
|
-
/* @__PURE__ */p("div",{className:"absolute right-2 bottom-2",children:/* @__PURE__ */p(Ut,{event:n,content:t,curateLink:s})})]})]})},Gt=({event:t,contents:e=[],gamConfig:n,singleColumnMode:i,kioskMode:s,timestampField:l,curateLink:c,onChangeFaceUrl:d,showQuickSearch:h})=>{const m=r(null),f=r(null),w=u(()=>`gallery-${t?._id??""}`,[t?._id]),{captureAdImpression:T,captureAdClick:y}=G(),{portalContainer:b,organization:v}=_(),q=v?._id,[E,S]=a(null);o(()=>{const t=f.current;if(!c&&t){const e=new P({gallery:t,children:"a",counter:!1,bgOpacity:1,wheelToZoom:!0,pinchToClose:!0,zoom:!1,pswpModule:U,appendToEl:b??document.body});m.current=e,new M(e),new St(e),new Nt(e),new C(e,T,y),new It(e),new Ct(e),e.init()}return()=>{m.current?.destroy?.(),m.current=null}},[t?.galleryLayout,c,y,T,w,b]);const I=u(()=>{switch(t?.galleryLayout){case k.ROW:return Tt;case k.COLUMN:return kt;case k.MASONRY:return xt;default:return Tt}},[t?.galleryLayout]),L=u(()=>e.map(t=>({src:t.type===N.IMAGE||t.type===N.VIDEO?t.url:t.type===N.GAM_AD?"":t.imageUrl,...t,width:t.dimension?.width||t.width||4,height:t.dimension?.height||t.height||3})),[e]),R=u(()=>({container:({ref:t,className:e,children:n})=>/* @__PURE__ */p("div",{ref:t,className:e??"",children:n}),photo:(e,{photo:i,width:o,height:r,index:a})=>{const u=i;let m=null;switch(u.type){case N.IMAGE:m=jt;break;case N.VIDEO:m=$t;break;case N.AD:m=Rt;break;case N.GAM_AD:return n?/* @__PURE__ */p(Bt,{style:{width:o,height:r},gamConfig:n,slotIndex:u.slotIndex??a,eventId:t?._id,organizationId:q},`${u._id??a}-${a}`):null;default:m=null}return m&&/* @__PURE__ */p(m,{style:{width:o,height:r},event:t,content:u,timestampField:l,onAdClick:c?()=>S(u):void 0,hideControls:s,curateLink:c?`${c}/${u._id}`:null,onChangeFaceUrl:d,showQuickSearch:h},`${u._id??a}-${a}`)}}),[t,n,q,l,c,s,d,h]);/* @__PURE__ */
|
|
37
|
-
return p(g,{children:[/* @__PURE__ */p("div",{id:w,ref:f,className:x(i?"w-full lg:w-1/3":"w-full"),children:/* @__PURE__ */p(I,{spacing:4,rowConstraints:t=>{const e={minPhotos:1,maxPhotos:4,singleRowMaxHeight:400};return i&&(e.minPhotos=1,e.maxPhotos=t<400?2:t<800?3:4),e},columns:t=>i?1:t<400?2:t<800?3:4,photos:L,render:R})}),/* @__PURE__ */p(Mt,{open:Boolean(E),ad:E,onClose:()=>S(null),captureAdClick:y})]})};export{Gt as default};
|
package/umd/C3uDEVBt.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var n,e,t,_,r,o,u,l,i,c,a,f,s,p,d,h={},v=[],m=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function g(n,e){for(var t in e)n[t]=e[t];return n}function b(n){n&&n.parentNode&&n.parentNode.removeChild(n)}function k(e,t,_){var r,o,u,l={};for(u in t)"key"==u?r=t[u]:"ref"==u?o=t[u]:l[u]=t[u];if(arguments.length>2&&(l.children=arguments.length>3?n.call(arguments,2):_),"function"==typeof e&&null!=e.defaultProps)for(u in e.defaultProps)void 0===l[u]&&(l[u]=e.defaultProps[u]);return C(e,l,r,o,null)}function C(n,_,r,o,u){var l={type:n,props:_,key:r,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:null==u?++t:u,__i:-1,__u:0};return null==u&&null!=e.vnode&&e.vnode(l),l}function w(n){return n.children}function x(n,e){this.props=n,this.context=e}function S(n,e){if(null==e)return n.__?S(n.__,n.__i+1):null;for(var t;e<n.__k.length;e++)if(null!=(t=n.__k[e])&&null!=t.__e)return t.__e;return"function"==typeof n.type?S(n):null}function P(n){if(n.__P&&n.__d){var t=n.__v,_=t.__e,r=[],o=[],u=g({},t);u.__v=t.__v+1,e.vnode&&e.vnode(u),W(n.__P,u,t,n.__n,n.__P.namespaceURI,32&t.__u?[_]:null,r,null==_?S(t):_,!!(32&t.__u),o),u.__v=t.__v,u.__.__k[u.__i]=u,I(r,u,o),t.__e=t.__=null,u.__e!=_&&N(u)}}function N(n){if(null!=(n=n.__)&&null!=n.__c)return n.__e=n.__c.base=null,n.__k.some(function(e){if(null!=e&&null!=e.__e)return n.__e=n.__c.base=e.__e}),N(n)}function E(n){(!n.__d&&(n.__d=!0)&&_.push(n)&&!U.__r++||r!=e.debounceRendering)&&((r=e.debounceRendering)||o)(U)}function U(){try{for(var n,e=1;_.length;)_.length>e&&_.sort(u),n=_.shift(),e=_.length,P(n)}finally{_.length=U.__r=0}}function R(n,e,t,_,r,o,u,l,i,c,a){var f,s,p,d,m,g,b,k=_&&_.__k||v,x=e.length;for(i=function(n,e,t,_,r){var o,u,l,i,c,a=t.length,f=a,s=0;for(n.__k=new Array(r),o=0;o<r;o++)null!=(u=e[o])&&"boolean"!=typeof u&&"function"!=typeof u?("string"==typeof u||"number"==typeof u||"bigint"==typeof u||u.constructor==String?u=n.__k[o]=C(null,u,null,null,null):y(u)?u=n.__k[o]=C(w,{children:u},null,null,null):void 0===u.constructor&&u.__b>0?u=n.__k[o]=C(u.type,u.props,u.key,u.ref?u.ref:null,u.__v):n.__k[o]=u,i=o+s,u.__=n,u.__b=n.__b+1,l=null,-1!=(c=u.__i=D(u,t,i,f))&&(f--,(l=t[c])&&(l.__u|=2)),null==l||null==l.__v?(-1==c&&(r>a?s--:r<a&&s++),"function"!=typeof u.type&&(u.__u|=4)):c!=i&&(c==i-1?s--:c==i+1?s++:(c>i?s--:s++,u.__u|=4))):n.__k[o]=null;if(f)for(o=0;o<a;o++)null!=(l=t[o])&&!(2&l.__u)&&(l.__e==_&&(_=S(l)),B(l,l));return _}(t,e,k,i,x),f=0;f<x;f++)null!=(p=t.__k[f])&&(s=-1!=p.__i&&k[p.__i]||h,p.__i=f,g=W(n,p,s,r,o,u,l,i,c,a),d=p.__e,p.ref&&s.ref!=p.ref&&(s.ref&&$(s.ref,null,p),a.push(p.ref,p.__c||d,p)),null==m&&null!=d&&(m=d),(b=!!(4&p.__u))||s.__k===p.__k?(i=H(p,i,n,b),b&&s.__e&&(s.__e=null)):"function"==typeof p.type&&void 0!==g?i=g:d&&(i=d.nextSibling),p.__u&=-7);return t.__e=m,i}function H(n,e,t,_){var r,o;if("function"==typeof n.type){for(r=n.__k,o=0;r&&o<r.length;o++)r[o]&&(r[o].__=n,e=H(r[o],e,t,_));return e}n.__e!=e&&(_&&(e&&n.type&&!e.parentNode&&(e=S(n)),t.insertBefore(n.__e,e||null)),e=n.__e);do{e=e&&e.nextSibling}while(null!=e&&8==e.nodeType);return e}function T(n,e){return e=e||[],null==n||"boolean"==typeof n||(y(n)?n.some(function(n){T(n,e)}):e.push(n)),e}function D(n,e,t,_){var r,o,u,l=n.key,i=n.type,c=e[t],a=null!=c&&!(2&c.__u);if(null===c&&null==l||a&&l==c.key&&i==c.type)return t;if(_>(a?1:0))for(r=t-1,o=t+1;r>=0||o<e.length;)if(null!=(c=e[u=r>=0?r--:o++])&&!(2&c.__u)&&l==c.key&&i==c.type)return u;return-1}function A(n,e,t){"-"==e[0]?n.setProperty(e,null==t?"":t):n[e]=null==t?"":"number"!=typeof t||m.test(e)?t:t+"px"}function M(n,e,t,_,r){var o,u;n:if("style"==e)if("string"==typeof t)n.style.cssText=t;else{if("string"==typeof _&&(n.style.cssText=_=""),_)for(e in _)t&&e in t||A(n.style,e,"");if(t)for(e in t)_&&t[e]==_[e]||A(n.style,e,t[e])}else if("o"==e[0]&&"n"==e[1])o=e!=(e=e.replace(a,"$1")),u=e.toLowerCase(),e=u in n||"onFocusOut"==e||"onFocusIn"==e?u.slice(2):e.slice(2),n.l||(n.l={}),n.l[e+o]=t,t?_?t[c]=_[c]:(t[c]=f,n.addEventListener(e,o?p:s,o)):n.removeEventListener(e,o?p:s,o);else{if("http://www.w3.org/2000/svg"==r)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=e&&"height"!=e&&"href"!=e&&"list"!=e&&"form"!=e&&"tabIndex"!=e&&"download"!=e&&"rowSpan"!=e&&"colSpan"!=e&&"role"!=e&&"popover"!=e&&e in n)try{n[e]=null==t?"":t;break n}catch(n){}"function"==typeof t||(null==t||!1===t&&"-"!=e[4]?n.removeAttribute(e):n.setAttribute(e,"popover"==e&&1==t?"":t))}}function O(n){return function(t){if(this.l){var _=this.l[t.type+n];if(null==t[i])t[i]=f++;else if(t[i]<_[c])return;return _(e.event?e.event(t):t)}}}function W(n,t,_,r,o,u,l,i,c,a){var f,s,p,d,h,m,k,C,S,P,N,E,U,H,T,D=t.type;if(void 0!==t.constructor)return null;128&_.__u&&(c=!!(32&_.__u),u=[i=t.__e=_.__e]),(f=e.__b)&&f(t);n:if("function"==typeof D)try{if(C=t.props,S=D.prototype&&D.prototype.render,P=(f=D.contextType)&&r[f.__c],N=f?P?P.props.value:f.__:r,_.__c?k=(s=t.__c=_.__c).__=s.__E:(S?t.__c=s=new D(C,N):(t.__c=s=new x(C,N),s.constructor=D,s.render=z),P&&P.sub(s),s.state||(s.state={}),s.__n=r,p=s.__d=!0,s.__h=[],s._sb=[]),S&&null==s.__s&&(s.__s=s.state),S&&null!=D.getDerivedStateFromProps&&(s.__s==s.state&&(s.__s=g({},s.__s)),g(s.__s,D.getDerivedStateFromProps(C,s.__s))),d=s.props,h=s.state,s.__v=t,p)S&&null==D.getDerivedStateFromProps&&null!=s.componentWillMount&&s.componentWillMount(),S&&null!=s.componentDidMount&&s.__h.push(s.componentDidMount);else{if(S&&null==D.getDerivedStateFromProps&&C!==d&&null!=s.componentWillReceiveProps&&s.componentWillReceiveProps(C,N),t.__v==_.__v||!s.__e&&null!=s.shouldComponentUpdate&&!1===s.shouldComponentUpdate(C,s.__s,N)){t.__v!=_.__v&&(s.props=C,s.state=s.__s,s.__d=!1),t.__e=_.__e,t.__k=_.__k,t.__k.some(function(n){n&&(n.__=t)}),v.push.apply(s.__h,s._sb),s._sb=[],s.__h.length&&l.push(s);break n}null!=s.componentWillUpdate&&s.componentWillUpdate(C,s.__s,N),S&&null!=s.componentDidUpdate&&s.__h.push(function(){s.componentDidUpdate(d,h,m)})}if(s.context=N,s.props=C,s.__P=n,s.__e=!1,E=e.__r,U=0,S)s.state=s.__s,s.__d=!1,E&&E(t),f=s.render(s.props,s.state,s.context),v.push.apply(s.__h,s._sb),s._sb=[];else do{s.__d=!1,E&&E(t),f=s.render(s.props,s.state,s.context),s.state=s.__s}while(s.__d&&++U<25);s.state=s.__s,null!=s.getChildContext&&(r=g(g({},r),s.getChildContext())),S&&!p&&null!=s.getSnapshotBeforeUpdate&&(m=s.getSnapshotBeforeUpdate(d,h)),H=null!=f&&f.type===w&&null==f.key?L(f.props.children):f,i=R(n,y(H)?H:[H],t,_,r,o,u,l,i,c,a),s.base=t.__e,t.__u&=-161,s.__h.length&&l.push(s),k&&(s.__E=s.__=null)}catch(n){if(t.__v=null,c||null!=u)if(n.then){for(t.__u|=c?160:128;i&&8==i.nodeType&&i.nextSibling;)i=i.nextSibling;u[u.indexOf(i)]=null,t.__e=i}else{for(T=u.length;T--;)b(u[T]);F(t)}else t.__e=_.__e,t.__k=_.__k,n.then||F(t);e.__e(n,t,_)}else null==u&&t.__v==_.__v?(t.__k=_.__k,t.__e=_.__e):i=t.__e=V(_.__e,t,_,r,o,u,l,c,a);return(f=e.diffed)&&f(t),128&t.__u?void 0:i}function F(n){n&&(n.__c&&(n.__c.__e=!0),n.__k&&n.__k.some(F))}function I(n,t,_){for(var r=0;r<_.length;r++)$(_[r],_[++r],_[++r]);e.__c&&e.__c(t,n),n.some(function(t){try{n=t.__h,t.__h=[],n.some(function(n){n.call(t)})}catch(n){e.__e(n,t.__v)}})}function L(n){return"object"!=typeof n||null==n||n.__b>0?n:y(n)?n.map(L):void 0!==n.constructor?null:g({},n)}function V(t,_,r,o,u,l,i,c,a){var f,s,p,d,v,m,g,k=r.props||h,C=_.props,w=_.type;if("svg"==w?u="http://www.w3.org/2000/svg":"math"==w?u="http://www.w3.org/1998/Math/MathML":u||(u="http://www.w3.org/1999/xhtml"),null!=l)for(f=0;f<l.length;f++)if((v=l[f])&&"setAttribute"in v==!!w&&(w?v.localName==w:3==v.nodeType)){t=v,l[f]=null;break}if(null==t){if(null==w)return document.createTextNode(C);t=document.createElementNS(u,w,C.is&&C),c&&(e.__m&&e.__m(_,l),c=!1),l=null}if(null==w)k===C||c&&t.data==C||(t.data=C);else{if(l="textarea"==w&&null!=C.defaultValue?null:l&&n.call(t.childNodes),!c&&null!=l)for(k={},f=0;f<t.attributes.length;f++)k[(v=t.attributes[f]).name]=v.value;for(f in k)v=k[f],"dangerouslySetInnerHTML"==f?p=v:"children"==f||f in C||"value"==f&&"defaultValue"in C||"checked"==f&&"defaultChecked"in C||M(t,f,null,v,u);for(f in C)v=C[f],"children"==f?d=v:"dangerouslySetInnerHTML"==f?s=v:"value"==f?m=v:"checked"==f?g=v:c&&"function"!=typeof v||k[f]===v||M(t,f,v,k[f],u);if(s)c||p&&(s.__html==p.__html||s.__html==t.innerHTML)||(t.innerHTML=s.__html),_.__k=[];else if(p&&(t.innerHTML=""),R("template"==_.type?t.content:t,y(d)?d:[d],_,r,o,"foreignObject"==w?"http://www.w3.org/1999/xhtml":u,l,i,l?l[0]:r.__k&&S(r,0),c,a),null!=l)for(f=l.length;f--;)b(l[f]);c&&"textarea"!=w||(f="value","progress"==w&&null==m?t.removeAttribute("value"):null!=m&&(m!==t[f]||"progress"==w&&!m||"option"==w&&m!=k[f])&&M(t,f,m,k[f],u),f="checked",null!=g&&g!=t[f]&&M(t,f,g,k[f],u))}return t}function $(n,t,_){try{if("function"==typeof n){var r="function"==typeof n.__u;r&&n.__u(),r&&null==t||(n.__u=n(t))}else n.current=t}catch(n){e.__e(n,_)}}function B(n,t,_){var r,o;if(e.unmount&&e.unmount(n),(r=n.ref)&&(r.current&&r.current!=n.__e||$(r,null,t)),null!=(r=n.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(n){e.__e(n,t)}r.base=r.__P=null}if(r=n.__k)for(o=0;o<r.length;o++)r[o]&&B(r[o],t,_||"function"!=typeof n.type);_||b(n.__e),n.__c=n.__=n.__e=void 0}function z(n,e,t){return this.constructor(n,t)}function j(t,_,r){var o,u,l,i;_==document&&(_=document.documentElement),e.__&&e.__(t,_),u=(o="function"==typeof r)?null:r&&r.__k||_.__k,l=[],i=[],W(_,t=(!o&&r||_).__k=k(w,null,[t]),u||h,h,_.namespaceURI,!o&&r?[r]:u?null:_.firstChild?n.call(_.childNodes):null,l,!o&&r?r:u?u.__e:_.firstChild,o,i),I(l,t,i)}function q(n,e){j(n,e,q)}function Z(e,t,_){var r,o,u,l,i=g({},e.props);for(u in e.type&&e.type.defaultProps&&(l=e.type.defaultProps),t)"key"==u?r=t[u]:"ref"==u?o=t[u]:i[u]=void 0===t[u]&&null!=l?l[u]:t[u];return arguments.length>2&&(i.children=arguments.length>3?n.call(arguments,2):_),C(e.type,i,r||e.key,o||e.ref,null)}function Y(n){function e(n){var t,_;return this.getChildContext||(t=/* @__PURE__ */new Set,(_={})[e.__c]=this,this.getChildContext=function(){return _},this.componentWillUnmount=function(){t=null},this.shouldComponentUpdate=function(n){this.props.value!=n.value&&t.forEach(function(n){n.__e=!0,E(n)})},this.sub=function(n){t.add(n);var e=n.componentWillUnmount;n.componentWillUnmount=function(){t&&t.delete(n),e&&e.call(n)}}),n.children}return e.__c="__cC"+d++,e.__=n,e.Provider=e.__l=(e.Consumer=function(n,e){return n.children(e)}).contextType=e,e}n=v.slice,e={__e:function(n,e,t,_){for(var r,o,u;e=e.__;)if((r=e.__c)&&!r.__)try{if((o=r.constructor)&&null!=o.getDerivedStateFromError&&(r.setState(o.getDerivedStateFromError(n)),u=r.__d),null!=r.componentDidCatch&&(r.componentDidCatch(n,_||{}),u=r.__d),u)return r.__E=r}catch(e){n=e}throw n}},t=0,x.prototype.setState=function(n,e){var t=null!=this.__s&&this.__s!=this.state?this.__s:this.__s=g({},this.state);"function"==typeof n&&(n=n(g({},t),this.props)),n&&g(t,n),null!=n&&this.__v&&(e&&this._sb.push(e),E(this))},x.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),E(this))},x.prototype.render=w,_=[],o="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,u=function(n,e){return n.__v.__b-e.__v.__b},U.__r=0,l=Math.random().toString(8),i="__d"+l,c="__a"+l,a=/(PointerCapture)$|Capture$/i,f=0,s=O(!1),p=O(!0),d=0;var G,J,K,Q,X=0,nn=[],en=e,tn=en.__b,_n=en.__r,rn=en.diffed,on=en.__c,un=en.unmount,ln=en.__;function cn(n,e){en.__h&&en.__h(J,n,X||e),X=0;var t=J.__H||(J.__H={__:[],__h:[]});return n>=t.__.length&&t.__.push({}),t.__[n]}function an(n){return X=1,fn(Nn,n)}function fn(n,e,t){var _=cn(G++,2);if(_.t=n,!_.__c&&(_.__=[t?t(e):Nn(void 0,e),function(n){var e=_.__N?_.__N[0]:_.__[0],t=_.t(e,n);e!==t&&(_.__N=[t,_.__[1]],_.__c.setState({}))}],_.__c=J,!J.__f)){var r=function(n,e,t){if(!_.__c.__H)return!0;var r=_.__c.__H.__.filter(function(n){return n.__c});if(r.every(function(n){return!n.__N}))return!o||o.call(this,n,e,t);var u=_.__c.props!==n;return r.some(function(n){if(n.__N){var e=n.__[0];n.__=n.__N,n.__N=void 0,e!==n.__[0]&&(u=!0)}}),o&&o.call(this,n,e,t)||u};J.__f=!0;var o=J.shouldComponentUpdate,u=J.componentWillUpdate;J.componentWillUpdate=function(n,e,t){if(this.__e){var _=o;o=void 0,r(n,e,t),o=_}u&&u.call(this,n,e,t)},J.shouldComponentUpdate=r}return _.__N||_.__}function sn(n,e){var t=cn(G++,3);!en.__s&&Pn(t.__H,e)&&(t.__=n,t.u=e,J.__H.__h.push(t))}function pn(n,e){var t=cn(G++,4);!en.__s&&Pn(t.__H,e)&&(t.__=n,t.u=e,J.__h.push(t))}function dn(n){return X=5,vn(function(){return{current:n}},[])}function hn(n,e,t){X=6,pn(function(){if("function"==typeof n){var t=n(e());return function(){n(null),t&&"function"==typeof t&&t()}}if(n)return n.current=e(),function(){return n.current=null}},null==t?t:t.concat(n))}function vn(n,e){var t=cn(G++,7);return Pn(t.__H,e)&&(t.__=n(),t.__H=e,t.__h=n),t.__}function mn(n,e){return X=8,vn(function(){return n},e)}function yn(n){var e=J.context[n.__c],t=cn(G++,9);return t.c=n,e?(t.__??(t.__=!0,e.sub(J)),e.props.value):n.__}function gn(n,e){en.useDebugValue&&en.useDebugValue(e?e(n):n)}function bn(){var n=cn(G++,11);if(!n.__){for(var e=J.__v;null!==e&&!e.__m&&null!==e.__;)e=e.__;var t=e.__m||(e.__m=[0,0]);n.__="P"+t[0]+"-"+t[1]++}return n.__}function kn(){for(var n;n=nn.shift();){var e=n.__H;if(n.__P&&e)try{e.__h.some(xn),e.__h.some(Sn),e.__h=[]}catch(J){e.__h=[],en.__e(J,n.__v)}}}en.__b=function(n){J=null,tn&&tn(n)},en.__=function(n,e){n&&e.__k&&e.__k.__m&&(n.__m=e.__k.__m),ln&&ln(n,e)},en.__r=function(n){_n&&_n(n),G=0;var e=(J=n.__c).__H;e&&(K===J?(e.__h=[],J.__h=[],e.__.some(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0})):(e.__h.some(xn),e.__h.some(Sn),e.__h=[],G=0)),K=J},en.diffed=function(n){rn&&rn(n);var e=n.__c;e&&e.__H&&(e.__H.__h.length&&(1!==nn.push(e)&&Q===en.requestAnimationFrame||((Q=en.requestAnimationFrame)||wn)(kn)),e.__H.__.some(function(n){n.u&&(n.__H=n.u),n.u=void 0})),K=J=null},en.__c=function(n,e){e.some(function(n){try{n.__h.some(xn),n.__h=n.__h.filter(function(n){return!n.__||Sn(n)})}catch(J){e.some(function(n){n.__h&&(n.__h=[])}),e=[],en.__e(J,n.__v)}}),on&&on(n,e)},en.unmount=function(n){un&&un(n);var e,t=n.__c;t&&t.__H&&(t.__H.__.some(function(n){try{xn(n)}catch(n){e=n}}),t.__H=void 0,e&&en.__e(e,t.__v))};var Cn="function"==typeof requestAnimationFrame;function wn(n){var e,t=function(){clearTimeout(_),Cn&&cancelAnimationFrame(e),setTimeout(n)},_=setTimeout(t,35);Cn&&(e=requestAnimationFrame(t))}function xn(n){var e=J,t=n.__c;"function"==typeof t&&(n.__c=void 0,t()),J=e}function Sn(n){var e=J;n.__c=n.__(),J=e}function Pn(n,e){return!n||n.length!==e.length||e.some(function(e,t){return e!==n[t]})}function Nn(n,e){return"function"==typeof e?e(n):e}function En(n,e){for(var t in e)n[t]=e[t];return n}function Un(n,e){for(var t in n)if("__source"!==t&&!(t in e))return!0;for(var _ in e)if("__source"!==_&&n[_]!==e[_])return!0;return!1}function Rn(n,e){var t=e(),_=an({t:{__:t,u:e}}),r=_[0].t,o=_[1];return pn(function(){r.__=t,r.u=e,Hn(r)&&o({t:r})},[n,t,e]),sn(function(){return Hn(r)&&o({t:r}),n(function(){Hn(r)&&o({t:r})})},[n]),t}function Hn(n){try{return!((e=n.__)===(t=n.u())&&(0!==e||1/e==1/t)||e!=e&&t!=t)}catch(n){return!0}var e,t}function Tn(n){n()}function Dn(n){return n}function An(){return[!1,Tn]}var Mn=pn;function On(n,e){this.props=n,this.context=e}function Wn(n,e){function t(n){var t=this.props.ref;return t!=n.ref&&t&&("function"==typeof t?t(null):t.current=null),e?!e(this.props,n)||t!=n.ref:Un(this.props,n)}function _(e){return this.shouldComponentUpdate=t,k(n,e)}return _.displayName="Memo("+(n.displayName||n.name)+")",_.__f=_.prototype.isReactComponent=!0,_.type=n,_}(On.prototype=new x).isPureReactComponent=!0,On.prototype.shouldComponentUpdate=function(n,e){return Un(this.props,n)||Un(this.state,e)};var Fn=e.__b;e.__b=function(n){n.type&&n.type.__f&&n.ref&&(n.props.ref=n.ref,n.ref=null),Fn&&Fn(n)};var In="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function Ln(n){function e(e){var t=En({},e);return delete t.ref,n(t,e.ref||null)}return e.$$typeof=In,e.render=n,e.prototype.isReactComponent=e.__f=!0,e.displayName="ForwardRef("+(n.displayName||n.name)+")",e}var Vn=function(n,e){return null==n?null:T(T(n).map(e))},$n={map:Vn,forEach:Vn,count:function(n){return n?T(n).length:0},only:function(n){var e=T(n);if(1!==e.length)throw"Children.only";return e[0]},toArray:T},Bn=e.__e;e.__e=function(n,e,t,_){if(n.then)for(var r,o=e;o=o.__;)if((r=o.__c)&&r.__c)return e.__e??(e.__e=t.__e,e.__k=t.__k),r.__c(n,e);Bn(n,e,t,_)};var zn=e.unmount;function jn(n,e,t){return n&&(n.__c&&n.__c.__H&&(n.__c.__H.__.forEach(function(n){"function"==typeof n.__c&&n.__c()}),n.__c.__H=null),null!=(n=En({},n)).__c&&(n.__c.__P===t&&(n.__c.__P=e),n.__c.__e=!0,n.__c=null),n.__k=n.__k&&n.__k.map(function(n){return jn(n,e,t)})),n}function qn(n,e,t){return n&&t&&(n.__v=null,n.__k=n.__k&&n.__k.map(function(n){return qn(n,e,t)}),n.__c&&n.__c.__P===e&&(n.__e&&t.appendChild(n.__e),n.__c.__e=!0,n.__c.__P=t)),n}function Zn(){this.__u=0,this.o=null,this.__b=null}function Yn(n){var e=n.__&&n.__.__c;return e&&e.__a&&e.__a(n)}function Gn(n){var e,t,_,r=null;function o(o){if(e||(e=n()).then(function(n){n&&(r=n.default||n),_=!0},function(n){t=n,_=!0}),t)throw t;if(!_)throw e;return r?k(r,o):null}return o.displayName="Lazy",o.__f=!0,o}function Jn(){this.i=null,this.l=null}e.unmount=function(n){var e=n.__c;e&&(e.__z=!0),e&&e.__R&&e.__R(),e&&32&n.__u&&(n.type=null),zn&&zn(n)},(Zn.prototype=new x).__c=function(n,e){var t=e.__c,_=this;_.o??=[],_.o.push(t);var r=Yn(_.__v),o=!1,u=function(){o||_.__z||(o=!0,t.__R=null,r?r(i):i())};t.__R=u;var l=t.__P;t.__P=null;var i=function(){if(! --_.__u){if(_.state.__a){var n=_.state.__a;_.__v.__k[0]=qn(n,n.__c.__P,n.__c.__O)}var e;for(_.setState({__a:_.__b=null});e=_.o.pop();)e.__P=l,e.forceUpdate()}};_.__u++||32&e.__u||_.setState({__a:_.__b=_.__v.__k[0]}),n.then(u,u)},Zn.prototype.componentWillUnmount=function(){this.o=[]},Zn.prototype.render=function(n,e){if(this.__b){if(this.__v.__k){var t=document.createElement("div"),_=this.__v.__k[0].__c;this.__v.__k[0]=jn(this.__b,t,_.__O=_.__P)}this.__b=null}var r=e.__a&&k(w,null,n.fallback);return r&&(r.__u&=-33),[k(w,null,e.__a?null:n.children),r]};var Kn=function(n,e,t){if(++t[1]===t[0]&&n.l.delete(e),n.props.revealOrder&&("t"!==n.props.revealOrder[0]||!n.l.size))for(t=n.i;t;){for(;t.length>3;)t.pop()();if(t[1]<t[0])break;n.i=t=t[2]}};function Qn(n){return this.getChildContext=function(){return n.context},n.children}function Xn(n){var e=this,t=n.h;if(e.componentWillUnmount=function(){j(null,e.v),e.v=null,e.h=null},e.h&&e.h!==t&&e.componentWillUnmount(),!e.v){for(var _=e.__v;null!==_&&!_.__m&&null!==_.__;)_=_.__;e.h=t,e.v={nodeType:1,parentNode:t,childNodes:[],__k:{__m:_.__m},contains:function(){return!0},namespaceURI:t.namespaceURI,insertBefore:function(n,t){this.childNodes.push(n),e.h.insertBefore(n,t)},removeChild:function(n){this.childNodes.splice(this.childNodes.indexOf(n)>>>1,1),e.h.removeChild(n)}}}j(k(Qn,{context:e.context},n.__v),e.v)}function ne(n,e){var t=k(Xn,{__v:n,h:e});return t.containerInfo=e,t}(Jn.prototype=new x).__a=function(n){var e=this,t=Yn(e.__v),_=e.l.get(n);return _[0]++,function(r){var o=function(){e.props.revealOrder?(_.push(r),Kn(e,n,_)):r()};t?t(o):o()}},Jn.prototype.render=function(n){this.i=null,this.l=/* @__PURE__ */new Map;var e=T(n.children);n.revealOrder&&"b"===n.revealOrder[0]&&e.reverse();for(var t=e.length;t--;)this.l.set(e[t],this.i=[1,0,this.i]);return n.children},Jn.prototype.componentDidUpdate=Jn.prototype.componentDidMount=function(){var n=this;this.l.forEach(function(e,t){Kn(n,t,e)})};var ee="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,te=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,_e=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,re=/[A-Z0-9]/g,oe="undefined"!=typeof document,ue=function(n){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(n)};x.prototype.isReactComponent=!0,["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(n){Object.defineProperty(x.prototype,n,{configurable:!0,get:function(){return this["UNSAFE_"+n]},set:function(e){Object.defineProperty(this,n,{configurable:!0,writable:!0,value:e})}})});var le=e.event;e.event=function(n){return le&&(n=le(n)),n.persist=function(){},n.isPropagationStopped=function(){return this.cancelBubble},n.isDefaultPrevented=function(){return this.defaultPrevented},n.nativeEvent=n};var ie,ce={configurable:!0,get:function(){return this.class}},ae=e.vnode;e.vnode=function(n){"string"==typeof n.type&&function(n){var e=n.props,t=n.type,_={},r=-1==t.indexOf("-");for(var o in e){var u=e[o];if(!("value"===o&&"defaultValue"in e&&null==u||oe&&"children"===o&&"noscript"===t||"class"===o||"className"===o)){var l=o.toLowerCase();"defaultValue"===o&&"value"in e&&null==e.value?o="value":"download"===o&&!0===u?u="":"translate"===l&&"no"===u?u=!1:"o"===l[0]&&"n"===l[1]?"ondoubleclick"===l?o="ondblclick":"onchange"!==l||"input"!==t&&"textarea"!==t||ue(e.type)?"onfocus"===l?o="onfocusin":"onblur"===l?o="onfocusout":_e.test(o)&&(o=l):l=o="oninput":r&&te.test(o)?o=o.replace(re,"-$&").toLowerCase():null===u&&(u=void 0),"oninput"===l&&_[o=l]&&(o="oninputCapture"),_[o]=u}}"select"==t&&(_.multiple&&Array.isArray(_.value)&&(_.value=T(e.children).forEach(function(n){n.props.selected=-1!=_.value.indexOf(n.props.value)})),null!=_.defaultValue&&(_.value=T(e.children).forEach(function(n){n.props.selected=_.multiple?-1!=_.defaultValue.indexOf(n.props.value):_.defaultValue==n.props.value}))),e.class&&!e.className?(_.class=e.class,Object.defineProperty(_,"className",ce)):e.className&&(_.class=_.className=e.className),n.props=_}(n),n.$$typeof=ee,ae&&ae(n)};var fe=e.__r;e.__r=function(n){fe&&fe(n),ie=n.__c};var se=e.diffed;e.diffed=function(n){se&&se(n);var e=n.props,t=n.__e;null!=t&&"textarea"===n.type&&"value"in e&&e.value!==t.value&&(t.value=null==e.value?"":e.value),ie=null};var pe={ReactCurrentDispatcher:{current:{readContext:function(n){return ie.__n[n.__c].props.value},useCallback:mn,useContext:yn,useDebugValue:gn,useDeferredValue:Dn,useEffect:sn,useId:bn,useImperativeHandle:hn,useInsertionEffect:Mn,useLayoutEffect:pn,useMemo:vn,useReducer:fn,useRef:dn,useState:an,useSyncExternalStore:Rn,useTransition:An}}};function de(n){return!!n&&n.$$typeof===ee}function he(n){return de(n)?Z.apply(null,arguments):n}var ve={useState:an,useId:bn,useReducer:fn,useEffect:sn,useLayoutEffect:pn,useInsertionEffect:Mn,useTransition:An,useDeferredValue:Dn,useSyncExternalStore:Rn,startTransition:Tn,useRef:dn,useImperativeHandle:hn,useMemo:vn,useCallback:mn,useContext:yn,useDebugValue:gn,version:"18.3.1",Children:$n,render:function(n,e,t){return e.__k??(e.textContent=""),j(n,e),"function"==typeof t&&t(),n?n.__c:null},hydrate:function(n,e,t){return q(n,e),"function"==typeof t&&t(),n?n.__c:null},unmountComponentAtNode:function(n){return!!n.__k&&(j(null,n),!0)},createPortal:ne,createElement:k,createContext:Y,createFactory:function(n){return k.bind(null,n)},cloneElement:he,createRef:function(){return{current:null}},Fragment:w,isValidElement:de,isElement:de,isFragment:function(n){return de(n)&&n.type===w},isMemo:function(n){return!!n&&"string"==typeof n.displayName&&0==n.displayName.indexOf("Memo(")},findDOMNode:function(n){return n&&(n.base||1===n.nodeType&&n)||null},Component:x,PureComponent:On,memo:Wn,forwardRef:Ln,flushSync:function(n,t){var _=e.debounceRendering;e.debounceRendering=function(n){return n()};var r=n(t);return e.debounceRendering=_,r},unstable_batchedUpdates:function(n,e){return n(e)},StrictMode:w,Suspense:Zn,SuspenseList:Jn,lazy:Gn,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:pe},me=0;function ye(n,t,_,r,o,u){t||(t={});var l,i,c=t;if("ref"in c)for(i in c={},t)"ref"==i?l=t[i]:c[i]=t[i];var a={type:n,props:c,key:_,ref:l,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--me,__i:-1,__u:0,__source:o,__self:u};if("function"==typeof n&&(l=n.defaultProps))for(i in l)void 0===c[i]&&(c[i]=l[i]);return e.vnode&&e.vnode(a),a}Array.isArray;export{j as C,k as D,Y as E,T as S,Z as T,fn as _,On as a,sn as b,ve as c,Gn as d,dn as f,bn as g,an as h,Ln as i,de as l,pn as m,ne as n,Wn as o,vn as p,Rn as r,Zn as s,ye as t,he as u,mn as v,w,x,yn as y};
|
package/umd/C8_zGNAf.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{B as e,F as t,R as r,V as s}from"./BItJQVdK.js";var i=class extends r{constructor(e,t){super(e,t)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(e){e._type="infinite",super.setOptions(e)}getOptimisticResult(e){return e._type="infinite",super.getOptimisticResult(e)}fetchNextPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"forward"}}})}fetchPreviousPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"backward"}}})}createResult(t,r){const{state:i}=t,a=super.createResult(t,r),{isFetching:c,isRefetching:h,isError:o,isRefetchError:n}=a,P=i.fetchMeta?.fetchMore?.direction,g=o&&"forward"===P,u=c&&"forward"===P,f=o&&"backward"===P,d=c&&"backward"===P;return{...a,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:e(r,i.data),hasPreviousPage:s(r,i.data),isFetchNextPageError:g,isFetchingNextPage:u,isFetchPreviousPageError:f,isFetchingPreviousPage:d,isRefetchError:n&&!g&&!f,isRefetching:h&&!u&&!d}}};function a(e,r){return t(e,i,r)}var c=e=>e?.meta?.currentPage>1?e.meta.currentPage-1:void 0,h=e=>e?.meta?.currentPage<e?.meta?.totalPages?e.meta.currentPage+1:void 0;export{c as n,a as r,h as t};
|
package/umd/CCLXmMXp.js
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import{t}from"./C3uDEVBt.js";import{i as a,n as e}from"./BItJQVdK.js";import{t as i}from"./Cb1JRT_1.js";var r=({title:r,description:s,iconSvg:o,className:l})=>{const{props:n,organization:c}=e(),m=n?.emptyStateImage;/* @__PURE__ */
|
|
2
|
-
return t("div",{className:a("mx-auto flex w-full max-w-md flex-col items-center justify-center gap-8",l),children:[c?.integrationSettings?.showLogo?/* @__PURE__ */t("img",{className:"h-44 w-auto",src:c?.logoUrl||"/images/qrati-logo.svg",alt:r}):m?/* @__PURE__ */t("img",{className:"h-44 w-auto",src:m,alt:r}):o?/* @__PURE__ */t("div",{className:"text-primary h-44 w-auto",children:o}):null,/* @__PURE__ */t("div",{className:"space-y-2",children:[
|
|
3
|
-
/* @__PURE__ */t(i,{variant:"h4",align:"center",children:r}),"string"==typeof s&&/* @__PURE__ */t(i,{variant:"body2",color:"muted",align:"center",children:s}),"string"!=typeof s&&s]})]})};export{r as t};
|
package/umd/CSO2IaJ1.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{D as e,a as t,b as r,f as o,h as n,t as s}from"./C3uDEVBt.js";import{i}from"./BItJQVdK.js";import{n as a}from"./BkIDQGIs.js";var l=({as:t="div",className:n,threshold:s=.5,rootMargin:i="0px",triggerOnce:a,onChange:l,onClick:h,children:c})=>{const u=o(null),d=o(!1),p=o(l);return p.current=l,r(()=>{const e=u.current;if(!e)return;d.current=!1;const t=new IntersectionObserver(e=>{e.forEach(e=>{a&&d.current||(e.isIntersecting&&(d.current=!0),p.current?.(e.isIntersecting))})},{threshold:s,rootMargin:i});return t.observe(e),()=>t.disconnect()},[s,i,a]),e(t,{ref:u,className:n,onClick:h},c)},h=Object.defineProperty,c=Object.defineProperties,u=Object.getOwnPropertyDescriptors,d=Object.getOwnPropertySymbols,p=Object.prototype.hasOwnProperty,f=Object.prototype.propertyIsEnumerable,g=(e,t,r)=>t in e?h(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,m=(e,t)=>{for(var r in t||(t={}))p.call(t,r)&&g(e,r,t[r]);if(d)for(var r of d(t))f.call(t,r)&&g(e,r,t[r]);return e},b=(e,t)=>c(e,u(t)),w=(e,t)=>{var r={};for(var o in e)p.call(e,o)&&t.indexOf(o)<0&&(r[o]=e[o]);if(null!=e&&d)for(var o of d(e))t.indexOf(o)<0&&f.call(e,o)&&(r[o]=e[o]);return r},v=class extends t{constructor(){super(...arguments),this.canvas=null,this.handleRef=e=>{this.canvas=e,this.draw()},this.draw=()=>{let{hash:e,height:t,punch:r,width:o}=this.props;if(this.canvas){let n=a(e,o,t,r),s=this.canvas.getContext("2d"),i=s.createImageData(o,t);i.data.set(n),s.putImageData(i,0,0)}}}componentDidUpdate(){this.draw()}render(){let t=this.props,{hash:r,height:o,width:n}=t,s=w(t,["hash","height","width"]);return e("canvas",b(m({},s),{height:o,width:n,ref:this.handleRef}))}};v.defaultProps={height:128,width:128};var y={position:"absolute",top:0,bottom:0,left:0,right:0,width:"100%",height:"100%"};(class extends t{componentDidUpdate(){if(this.props.resolutionX<=0)throw new Error("resolutionX must be larger than zero");if(this.props.resolutionY<=0)throw new Error("resolutionY must be larger than zero")}render(){let t=this.props,{hash:r,height:o,width:n,punch:s,resolutionX:i,resolutionY:a,style:l}=t,h=w(t,["hash","height","width","punch","resolutionX","resolutionY","style"]);return e("div",b(m({},h),{style:b(m({display:"inline-block",height:o,width:n},l),{position:"relative"})}),e(v,{hash:r,height:a,width:i,punch:s,style:y}))}}).defaultProps={height:128,width:128,resolutionX:32,resolutionY:32};var j=v,O=({src:e,alt:t,threshold:a=.1,rootMargin:h="600px 0px",blurhash:c,containerClassName:u="size-full",wrapperClassName:d,imgClassName:p="",sizeMode:f="cover",position:g="center",delayMs:m=100,delayTime:b,onClick:w})=>{const v=c&&c.length>=6?c:"LEHV6nWB2yk8pyo0adR*.7kCMdnj",[y,O]=n(!1),[C,x]=n(!1),[N,k]=n(!1),z=o(null);r(()=>{O(!1),x(!1)},[e]);const M="number"==typeof b?b:m,P=d??u;r(()=>{if(!y)return N?z.current=window.setTimeout(()=>{x(!0)},M):z.current&&(clearTimeout(z.current),z.current=null),()=>{z.current&&clearTimeout(z.current)}},[N,y,M]);const D=C&&N||y;/* @__PURE__ */
|
|
2
|
-
return s(l,{as:"div",className:i(P,"relative overflow-hidden"),threshold:a,rootMargin:h,onChange:e=>k(e),children:[N&&!y&&/* @__PURE__ */s(j,{className:"size-full blur-2xl",hash:v}),D&&e&&/* @__PURE__ */s("img",{alt:t,src:e,loading:"lazy",decoding:"async",onLoad:()=>O(!0),className:i("absolute top-0 left-0 size-full object-center transition-all duration-300",y?"scale-100 opacity-100":"scale-95 opacity-0","contain"===f?"object-contain":"object-cover","top"===g?"object-top":"bottom"===g?"object-bottom":"object-center",p),onClick:e=>w?.(e)})]})};export{l as n,O as t};
|
package/umd/CXg838Gr2.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import{t as e,v as r}from"./C3uDEVBt.js";import{N as a,P as t,i as l,n as i,u as n,v as o}from"./BItJQVdK.js";import{u as s}from"./b6CwQBFC.js";import{t as d}from"./ekog7y-V.js";import{t as c}from"./Cb1JRT_1.js";import{n as m}from"./DvTRhlvs.js";import{t as g}from"./qWp4ucdT.js";import{t as h}from"./B14kCOq8.js";import{t as f}from"./DNG5BSHx2.js";function p({className:r}){/* @__PURE__ */
|
|
2
|
-
return e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 256 256",className:r,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */e("path",{fill:"currentColor",d:"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24m12 152a8 8 0 0 1-16 0V95l-11.56 7.71a8 8 0 1 1-8.88-13.32l24-16A8 8 0 0 1 140 80Z"})})}function b({className:r}){/* @__PURE__ */
|
|
3
|
-
return e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 256 256",className:r,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */e("path",{fill:"currentColor",d:"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24m-4 164a35.7 35.7 0 0 1-25.71-10.81A8 8 0 1 1 109.71 166A20 20 0 1 0 124 132a8 8 0 0 1-6.55-12.59L136.63 92H104a8 8 0 0 1 0-16h48a8 8 0 0 1 6.55 12.59l-21 30A36 36 0 0 1 124 188"})})}function x({className:r}){/* @__PURE__ */
|
|
4
|
-
return e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 256 256",className:r,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */e("path",{fill:"currentColor",d:"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24m24 144a8 8 0 0 1 0 16h-48a8 8 0 0 1-6.4-12.8l43.17-57.56a16 16 0 1 0-27.86-15a8 8 0 0 1-15.09-5.34a32 32 0 1 1 55.74 29.93L120 168Z"})})}var u=e=>{if(!e)return"";const r=e.trim().split(/\s+/);return 1===r.length?r[0]:`${r[0]} ${r[1]?.[0]?`${r[1][0]}.`:""}`},v={first:{size:"size-28",imageSize:"size-24",borderColor:"border-amber-400",gradient:"from-amber-400/20 via-yellow-300/10 to-transparent"},second:{size:"size-20",imageSize:"size-16",borderColor:"border-slate-400",gradient:"from-slate-400/20 via-slate-300/10 to-transparent"},third:{size:"size-20",imageSize:"size-16",borderColor:"border-amber-600",gradient:"from-amber-600/20 via-amber-500/10 to-transparent"}},N=(e,r)=>{const a=void 0===e.totalPoint?e.maxScore:e.totalPoint;return void 0===a?"—":a.toFixed(r?2:0)},w=({entry:a,position:t,showFloatingPoint:i,hidePictures:n})=>{const o=1===t?v.first:2===t?v.second:v.third,s={1:p,2:x,3:b}[t],d={1:{bg:"bg-amber-400",border:"border-amber-600",text:"text-amber-900"},2:{bg:"bg-slate-300",border:"border-slate-500",text:"text-slate-700"},3:{bg:"bg-amber-600",border:"border-amber-800",text:"text-amber-100"}},m=r(e=>{e.currentTarget.style.display="none"},[]);/* @__PURE__ */
|
|
5
|
-
return e("div",{className:l("flex w-full flex-col items-center justify-center rounded-xl p-4 text-center sm:min-w-36","bg-linear-to-b",o.gradient),children:[n?/* @__PURE__ */e(s,{className:l(o.size,{1:"text-amber-400",2:"text-slate-400",3:"text-amber-600"}[t])}):/* @__PURE__ */e("div",{className:"relative",children:[/* @__PURE__ */e("img",{className:l(o.imageSize,"shadow-card scale-100 rounded-full border-4 object-cover",o.borderColor),src:a.image,alt:a.name??"",loading:"lazy",onError:m}),/* @__PURE__ */e("span",{className:l("shadow-card absolute -bottom-2 left-1/2 z-10 flex size-7 -translate-x-1/2 items-center justify-center rounded-full border-2 text-sm font-bold",d[t].bg,d[t].border,d[t].text),children:t})]}),/* @__PURE__ */e("div",{className:"mt-3 space-y-3 text-center",children:[/* @__PURE__ */e(c,{variant:"h6",lines:2,className:"max-w-24",align:"center",children:u(a.name)}),/* @__PURE__ */e("div",{className:"text-primary text-lg font-bold",children:N(a,i)})]})]})},y=({title:a,entries:t=[],showFloatingPoint:i=!1,hidePictures:n=!0})=>{const{t:o}=m(),s=a.replace(/\s+/g,"-").toLowerCase(),d=r(e=>{e.currentTarget.style.display="none"},[]);/* @__PURE__ */
|
|
6
|
-
return e("div",{className:"border-border mx-auto flex max-w-2xl flex-col rounded border p-4 sm:p-5 lg:p-6",children:[/* @__PURE__ */e("div",{className:"mb-4 flex items-center justify-center gap-2",children:[/* @__PURE__ */e(h,{className:"text-primary size-6"}),/* @__PURE__ */e(c,{variant:"h4",align:"center",color:"primary",children:a})]}),0===t.length?/* @__PURE__ */e("div",{className:"py-16 text-center",children:[/* @__PURE__ */e(c,{variant:"h5",align:"center",color:"error",children:o("leaderboard.not_available","No data available")}),/* @__PURE__ */e(c,{variant:"body2",align:"center",color:"muted",className:"mt-2",children:o("leaderboard.come_back_later","Check back later for updates.")})]}):/* @__PURE__ */e("div",{children:[/* @__PURE__ */e("div",{className:"flex items-end justify-center gap-2 lg:gap-8",children:[t.length>1&&/* @__PURE__ */e(w,{entry:t[1],position:2,showFloatingPoint:i,hidePictures:n}),t.length>0&&/* @__PURE__ */e(w,{entry:t[0],position:1,showFloatingPoint:i,hidePictures:n}),t.length>2&&/* @__PURE__ */e(w,{entry:t[2],position:3,showFloatingPoint:i,hidePictures:n})]}),/* @__PURE__ */e("div",{className:"mt-6 overflow-hidden rounded ring-1 ring-black/5",children:/* @__PURE__ */e("div",{className:"divide-border divide-y",children:t.slice(3).map((r,a)=>/* @__PURE__ */e("div",{className:l("hover:bg-primary/5 flex items-center gap-4 px-4 py-3",a%2==0?"bg-primary/5":"bg-background"),children:[
|
|
7
|
-
/* @__PURE__ */e("span",{className:"text-muted-foreground w-8 text-center text-sm font-medium",children:a+4}),!n&&/* @__PURE__ */e("img",{className:"ring-border size-10 rounded-full object-cover ring-2",src:r.image,alt:r.name??"",loading:"lazy",onError:d}),
|
|
8
|
-
/* @__PURE__ */e("div",{className:"min-w-0 flex-1",children:/* @__PURE__ */e("div",{className:"truncate font-medium",children:u(r.name)})}),
|
|
9
|
-
/* @__PURE__ */e("div",{className:"text-primary text-right font-semibold",children:N(r,i)})]},`${s}-${a}`))})})]})]})},z=()=>{const{eventSlug:r}=s(),{props:h}=i(),{t:p}=m(),b=h?.organizationId,{event:x,loading:u}=g({eventSlug:r}),{isLoading:v,isError:N,error:w,data:z}=t({queryKey:[`leaderboard-${b}-${x?._id}`],queryFn:async()=>(await a.get(n.GET_LEADERBOARD,{headers:{"x-org-id":b??""},searchParams:{eventId:x?._id??"",projection:"connect"}}).json()).data,enabled:Boolean(x),staleTime:3e4,gcTime:3e5});/* @__PURE__ */
|
|
10
|
-
return e("div",u||v?{className:"bg-background mt-4 flex min-h-[80vh] w-full flex-col gap-6 px-2 py-4 sm:px-0 lg:py-8",children:[/* @__PURE__ */e("div",{className:"flex flex-col items-center gap-2 text-center",children:[/* @__PURE__ */e(d,{className:"h-5 w-28 rounded-full"}),/* @__PURE__ */e(d,{className:"h-10 w-64 rounded"})]}),/* @__PURE__ */e("div",{className:l("flex w-full gap-8 lg:gap-0",x?.engagementStyle===o.REACTION?"flex-col-reverse md:flex-row-reverse md:justify-between":"flex-col md:flex-row"),children:[/* @__PURE__ */e("div",{className:"flex-1",children:[/* @__PURE__ */e(d,{className:"h-72 w-full rounded"}),/* @__PURE__ */e(d,{className:"mt-4 h-72 w-full rounded"})]}),/* @__PURE__ */e("div",{className:"flex-1",children:/* @__PURE__ */e(d,{className:"h-72 w-full rounded"})})]})]}:N?{className:"bg-background mt-4 flex min-h-[80vh] w-full flex-col items-center justify-center gap-4 px-2 py-4 text-center sm:px-0 lg:py-8",children:[
|
|
11
|
-
/* @__PURE__ */e(f,{className:"size-9 text-destructive"}),
|
|
12
|
-
/* @__PURE__ */e(c,{variant:"h4",color:"error",align:"center",children:p("common.error","Something went wrong")}),
|
|
13
|
-
/* @__PURE__ */e(c,{variant:"body2",color:"muted",align:"center",children:w instanceof Error?w.message:p("common.try_again","Please try again later.")})]}:{className:"bg-background mt-4 flex min-h-[80vh] w-full flex-col gap-6 px-2 py-4 sm:px-0 lg:py-8",children:[/* @__PURE__ */e("div",{className:"flex flex-col items-center gap-2 text-center",children:[/* @__PURE__ */e("div",{className:"text-primary flex items-center gap-2",children:/* @__PURE__ */e(c,{variant:"h5",color:"primary",children:p("leaderboard.leaderboard","Leaderboard")})}),/* @__PURE__ */e(c,{variant:"h4",align:"center",color:"foreground",children:x?.name})]}),/* @__PURE__ */e("div",{className:l("flex w-full gap-8 lg:gap-0",x?.engagementStyle===o.REACTION?"flex-col-reverse md:flex-row-reverse md:justify-between":"flex-col md:flex-row"),children:[/* @__PURE__ */e("div",{className:"flex-1",children:/* @__PURE__ */e(y,{title:p("leaderboard.point_leaders","Top Points Leaders"),entries:z?.leaderboardByPoint?.topRankers||[],pointName:x?.pointName})}),/* @__PURE__ */e("div",{className:"flex-1",children:/* @__PURE__ */e(y,{title:x?.engagementStyle===o.REACTION?p("leaderboard.reaction_counts","Top Reactions"):p("leaderboard.top_rated_photos","Top Rated Photos"),showFloatingPoint:x?.engagementStyle===o.CONTEST,entries:z?.leaderboardByScore?.topRankers||[],pointName:x?.pointName})})]})]})};export{z as default};
|
package/umd/Cb1JRT_1.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t}from"./C3uDEVBt.js";import{i as e,o as r}from"./BItJQVdK.js";var l=t=>"boolean"==typeof t?`${t}`:0===t?"0":t,o=r,a=(t,e)=>r=>{var a;if(null==(null==e?void 0:e.variants))return o(t,null==r?void 0:r.class,null==r?void 0:r.className);const{variants:n,defaultVariants:i}=e,s=Object.keys(n).map(t=>{const e=null==r?void 0:r[t],o=null==i?void 0:i[t];if(null===e)return null;const a=l(e)||l(o);return n[t][a]}),d=r&&Object.entries(r).reduce((t,e)=>{let[r,l]=e;return void 0===l||(t[r]=l),t},{});return o(t,s,null==e||null===(a=e.compoundVariants)||void 0===a?void 0:a.reduce((t,e)=>{let{class:r,className:l,...o}=e;return Object.entries(o).every(t=>{let[e,r]=t;return Array.isArray(r)?r.includes({...i,...d}[e]):{...i,...d}[e]===r})?[...t,r,l]:t},[]),null==r?void 0:r.class,null==r?void 0:r.className)},n={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",p:"p",blockquote:"blockquote",body1:"p",body2:"p",body3:"p",caption:"span",overline:"span",lead:"p"},i=a("antialiased",{variants:{variant:{h1:"scroll-m-20 text-4xl font-bold tracking-tight lg:text-5xl",h2:"scroll-m-20 text-3xl font-bold tracking-tight lg:text-4xl",h3:"scroll-m-20 text-2xl font-semibold tracking-tight",h4:"scroll-m-20 text-xl font-semibold",h5:"scroll-m-20 text-lg font-semibold",h6:"scroll-m-20 text-base font-semibold",body1:"text-base leading-relaxed font-medium",body2:"text-sm leading-relaxed",body3:"text-sm leading-relaxed sm:text-base",p:"text-base leading-7",lead:"text-muted-foreground text-xl leading-relaxed",blockquote:"border-primary/30 text-muted-foreground border-l-4 pl-4 text-base italic",caption:"text-muted-foreground text-xs",overline:"text-muted-foreground text-xs font-medium tracking-widest uppercase"},color:{foreground:"text-foreground",muted:"text-muted-foreground",primary:"text-primary",info:"text-info",warning:"text-warning",success:"text-success",error:"text-destructive",inherit:"text-inherit",secondary:"text-muted-foreground",white:"text-white",black:"text-black",a11y:"text-primary-foreground",light:"text-text-primary-light"},align:{left:"text-left",right:"text-right",center:"text-center",justify:"text-justify"},weight:{normal:"font-normal",medium:"font-medium",semibold:"font-semibold",bold:"font-bold"}},defaultVariants:{variant:"body1",color:"foreground",align:"left"}}),s=({variant:r="body1",color:l,align:o,weight:a,transform:s,lines:d,shadow:u,noWrap:x,className:c,immutable:m,...g})=>/* @__PURE__ */t(n[r],{className:e(i({variant:r,color:l,align:o,weight:a}),s,d&&d>0?`line-clamp-${d}`:void 0,u&&"drop-shadow-[0_1px_2px_rgba(0,0,0,0.5)]",x&&"truncate",c),...g,children:g.children});export{i as n,a as r,s as t};
|
package/umd/CfMNBPpx2.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var t=/* @__PURE__ */new Set;function e(e,n){if(t.has(e))return;const o=document.querySelector("qrati-connect")?.shadowRoot;if(!o)return;const r=o.querySelector("style");if(r)r.textContent+=`\n${n}`;else{const t=document.createElement("style");t.id=e,t.textContent=n,o.appendChild(t)}t.add(e)}export{e as t};
|
package/umd/CgUphJWo.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./Cko4QHwX.js";var t=/* @__PURE__ */e((e,t)=>{var i,r;i=e,r=function(e){var t=L.MarkerClusterGroup=L.FeatureGroup.extend({options:{maxClusterRadius:80,iconCreateFunction:null,clusterPane:L.Marker.prototype.options.pane,spiderfyOnEveryZoom:!1,spiderfyOnMaxZoom:!0,showCoverageOnHover:!0,zoomToBoundsOnClick:!0,singleMarkerMode:!1,disableClusteringAtZoom:null,removeOutsideVisibleBounds:!0,animate:!0,animateAddingMarkers:!1,spiderfyShapePositions:null,spiderfyDistanceMultiplier:1,spiderLegPolylineOptions:{weight:1.5,color:"#222",opacity:.5},chunkedLoading:!1,chunkInterval:200,chunkDelay:50,chunkProgress:null,polygonOptions:{}},initialize:function(e){L.Util.setOptions(this,e),this.options.iconCreateFunction||(this.options.iconCreateFunction=this._defaultIconCreateFunction),this._featureGroup=L.featureGroup(),this._featureGroup.addEventParent(this),this._nonPointGroup=L.featureGroup(),this._nonPointGroup.addEventParent(this),this._inZoomAnimation=0,this._needsClustering=[],this._needsRemoving=[],this._currentShownBounds=null,this._queue=[],this._childMarkerEventHandlers={dragstart:this._childMarkerDragStart,move:this._childMarkerMoved,dragend:this._childMarkerDragEnd};var t=L.DomUtil.TRANSITION&&this.options.animate;L.extend(this,t?this._withAnimation:this._noAnimation),this._markerCluster=t?L.MarkerCluster:L.MarkerClusterNonAnimated},addLayer:function(e){if(e instanceof L.LayerGroup)return this.addLayers([e]);if(!e.getLatLng)return this._nonPointGroup.addLayer(e),this.fire("layeradd",{layer:e}),this;if(!this._map)return this._needsClustering.push(e),this.fire("layeradd",{layer:e}),this;if(this.hasLayer(e))return this;this._unspiderfy&&this._unspiderfy(),this._addLayer(e,this._maxZoom),this.fire("layeradd",{layer:e}),this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons();var t=e,i=this._zoom;if(e.__parent)for(;t.__parent._zoom>=i;)t=t.__parent;return this._currentShownBounds.contains(t.getLatLng())&&(this.options.animateAddingMarkers?this._animationAddLayer(e,t):this._animationAddLayerNonAnimated(e,t)),this},removeLayer:function(e){return e instanceof L.LayerGroup?this.removeLayers([e]):e.getLatLng?this._map?e.__parent?(this._unspiderfy&&(this._unspiderfy(),this._unspiderfyLayer(e)),this._removeLayer(e,!0),this.fire("layerremove",{layer:e}),this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons(),e.off(this._childMarkerEventHandlers,this),this._featureGroup.hasLayer(e)&&(this._featureGroup.removeLayer(e),e.clusterShow&&e.clusterShow()),this):this:(!this._arraySplice(this._needsClustering,e)&&this.hasLayer(e)&&this._needsRemoving.push({layer:e,latlng:e._latlng}),this.fire("layerremove",{layer:e}),this):(this._nonPointGroup.removeLayer(e),this.fire("layerremove",{layer:e}),this)},addLayers:function(e,t){if(!L.Util.isArray(e))return this.addLayer(e);var i,r=this._featureGroup,n=this._nonPointGroup,s=this.options.chunkedLoading,o=this.options.chunkInterval,a=this.options.chunkProgress,h=e.length,l=0,u=!0;if(this._map){var _=/* @__PURE__ */(new Date).getTime(),d=L.bind(function(){var p=/* @__PURE__ */(new Date).getTime();for(this._map&&this._unspiderfy&&this._unspiderfy();l<h&&!(s&&l%200==0&&/* @__PURE__ */(new Date).getTime()-p>o);l++)if((i=e[l])instanceof L.LayerGroup)u&&(e=e.slice(),u=!1),this._extractNonGroupLayers(i,e),h=e.length;else if(i.getLatLng){if(!this.hasLayer(i)&&(this._addLayer(i,this._maxZoom),t||this.fire("layeradd",{layer:i}),i.__parent&&2===i.__parent.getChildCount())){var c=i.__parent.getAllChildMarkers(),f=c[0]===i?c[1]:c[0];r.removeLayer(f)}}else n.addLayer(i),t||this.fire("layeradd",{layer:i});a&&a(l,h,/* @__PURE__ */(new Date).getTime()-_),l===h?(this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons(),this._topClusterLevel._recursivelyAddChildrenToMap(null,this._zoom,this._currentShownBounds)):setTimeout(d,this.options.chunkDelay)},this);d()}else for(var p=this._needsClustering;l<h;l++)(i=e[l])instanceof L.LayerGroup?(u&&(e=e.slice(),u=!1),this._extractNonGroupLayers(i,e),h=e.length):i.getLatLng?this.hasLayer(i)||p.push(i):n.addLayer(i);return this},removeLayers:function(e){var t,i,r=e.length,n=this._featureGroup,s=this._nonPointGroup,o=!0;if(!this._map){for(t=0;t<r;t++)(i=e[t])instanceof L.LayerGroup?(o&&(e=e.slice(),o=!1),this._extractNonGroupLayers(i,e),r=e.length):(this._arraySplice(this._needsClustering,i),s.removeLayer(i),this.hasLayer(i)&&this._needsRemoving.push({layer:i,latlng:i._latlng}),this.fire("layerremove",{layer:i}));return this}if(this._unspiderfy){this._unspiderfy();var a=e.slice(),h=r;for(t=0;t<h;t++)(i=a[t])instanceof L.LayerGroup?(this._extractNonGroupLayers(i,a),h=a.length):this._unspiderfyLayer(i)}for(t=0;t<r;t++)(i=e[t])instanceof L.LayerGroup?(o&&(e=e.slice(),o=!1),this._extractNonGroupLayers(i,e),r=e.length):i.__parent?(this._removeLayer(i,!0,!0),this.fire("layerremove",{layer:i}),n.hasLayer(i)&&(n.removeLayer(i),i.clusterShow&&i.clusterShow())):(s.removeLayer(i),this.fire("layerremove",{layer:i}));return this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons(),this._topClusterLevel._recursivelyAddChildrenToMap(null,this._zoom,this._currentShownBounds),this},clearLayers:function(){return this._map||(this._needsClustering=[],this._needsRemoving=[],delete this._gridClusters,delete this._gridUnclustered),this._noanimationUnspiderfy&&this._noanimationUnspiderfy(),this._featureGroup.clearLayers(),this._nonPointGroup.clearLayers(),this.eachLayer(function(e){e.off(this._childMarkerEventHandlers,this),delete e.__parent},this),this._map&&this._generateInitialClusters(),this},getBounds:function(){var e=new L.LatLngBounds;this._topClusterLevel&&e.extend(this._topClusterLevel._bounds);for(var t=this._needsClustering.length-1;t>=0;t--)e.extend(this._needsClustering[t].getLatLng());return e.extend(this._nonPointGroup.getBounds()),e},eachLayer:function(e,t){var i,r,n,s=this._needsClustering.slice(),o=this._needsRemoving;for(this._topClusterLevel&&this._topClusterLevel.getAllChildMarkers(s),r=s.length-1;r>=0;r--){for(i=!0,n=o.length-1;n>=0;n--)if(o[n].layer===s[r]){i=!1;break}i&&e.call(t,s[r])}this._nonPointGroup.eachLayer(e,t)},getLayers:function(){var e=[];return this.eachLayer(function(t){e.push(t)}),e},getLayer:function(e){var t=null;return e=parseInt(e,10),this.eachLayer(function(i){L.stamp(i)===e&&(t=i)}),t},hasLayer:function(e){if(!e)return!1;var t,i=this._needsClustering;for(t=i.length-1;t>=0;t--)if(i[t]===e)return!0;for(t=(i=this._needsRemoving).length-1;t>=0;t--)if(i[t].layer===e)return!1;return!(!e.__parent||e.__parent._group!==this)||this._nonPointGroup.hasLayer(e)},zoomToShowLayer:function(e,t){var i=this._map;"function"!=typeof t&&(t=function(){});var r=function(){!i.hasLayer(e)&&!i.hasLayer(e.__parent)||this._inZoomAnimation||(this._map.off("moveend",r,this),this.off("animationend",r,this),i.hasLayer(e)?t():e.__parent._icon&&(this.once("spiderfied",t,this),e.__parent.spiderfy()))};e._icon&&this._map.getBounds().contains(e.getLatLng())?t():e.__parent._zoom<Math.round(this._map._zoom)?(this._map.on("moveend",r,this),this._map.panTo(e.getLatLng())):(this._map.on("moveend",r,this),this.on("animationend",r,this),e.__parent.zoomToBounds())},onAdd:function(e){var t,i,r;if(this._map=e,!isFinite(this._map.getMaxZoom()))throw"Map has no maxZoom specified";for(this._featureGroup.addTo(e),this._nonPointGroup.addTo(e),this._gridClusters||this._generateInitialClusters(),this._maxLat=e.options.crs.projection.MAX_LATITUDE,t=0,i=this._needsRemoving.length;t<i;t++)(r=this._needsRemoving[t]).newlatlng=r.layer._latlng,r.layer._latlng=r.latlng;for(t=0,i=this._needsRemoving.length;t<i;t++)r=this._needsRemoving[t],this._removeLayer(r.layer,!0),r.layer._latlng=r.newlatlng;this._needsRemoving=[],this._zoom=Math.round(this._map._zoom),this._currentShownBounds=this._getExpandedVisibleBounds(),this._map.on("zoomend",this._zoomEnd,this),this._map.on("moveend",this._moveEnd,this),this._spiderfierOnAdd&&this._spiderfierOnAdd(),this._bindEvents(),i=this._needsClustering,this._needsClustering=[],this.addLayers(i,!0)},onRemove:function(e){e.off("zoomend",this._zoomEnd,this),e.off("moveend",this._moveEnd,this),this._unbindEvents(),this._map._mapPane.className=this._map._mapPane.className.replace(" leaflet-cluster-anim",""),this._spiderfierOnRemove&&this._spiderfierOnRemove(),delete this._maxLat,this._hideCoverage(),this._featureGroup.remove(),this._nonPointGroup.remove(),this._featureGroup.clearLayers(),this._map=null},getVisibleParent:function(e){for(var t=e;t&&!t._icon;)t=t.__parent;return t||null},_arraySplice:function(e,t){for(var i=e.length-1;i>=0;i--)if(e[i]===t)return e.splice(i,1),!0},_removeFromGridUnclustered:function(e,t){for(var i=this._map,r=this._gridUnclustered,n=Math.floor(this._map.getMinZoom());t>=n&&r[t].removeObject(e,i.project(e.getLatLng(),t));t--);},_childMarkerDragStart:function(e){e.target.__dragStart=e.target._latlng},_childMarkerMoved:function(e){if(!this._ignoreMove&&!e.target.__dragStart){var t=e.target._popup&&e.target._popup.isOpen();this._moveChild(e.target,e.oldLatLng,e.latlng),t&&e.target.openPopup()}},_moveChild:function(e,t,i){e._latlng=t,this.removeLayer(e),e._latlng=i,this.addLayer(e)},_childMarkerDragEnd:function(e){var t=e.target.__dragStart;delete e.target.__dragStart,t&&this._moveChild(e.target,t,e.target._latlng)},_removeLayer:function(e,t,i){var r=this._gridClusters,n=this._gridUnclustered,s=this._featureGroup,o=this._map,a=Math.floor(this._map.getMinZoom());t&&this._removeFromGridUnclustered(e,this._maxZoom);var h,l=e.__parent,u=l._markers;for(this._arraySplice(u,e);l&&(l._childCount--,l._boundsNeedUpdate=!0,!(l._zoom<a));)t&&l._childCount<=1?(h=l._markers[0]===e?l._markers[1]:l._markers[0],r[l._zoom].removeObject(l,o.project(l._cLatLng,l._zoom)),n[l._zoom].addObject(h,o.project(h.getLatLng(),l._zoom)),this._arraySplice(l.__parent._childClusters,l),l.__parent._markers.push(h),h.__parent=l.__parent,l._icon&&(s.removeLayer(l),i||s.addLayer(h))):l._iconNeedsUpdate=!0,l=l.__parent;delete e.__parent},_isOrIsParent:function(e,t){for(;t;){if(e===t)return!0;t=t.parentNode}return!1},fire:function(e,t,i){if(t&&t.layer instanceof L.MarkerCluster){if(t.originalEvent&&this._isOrIsParent(t.layer._icon,t.originalEvent.relatedTarget))return;e="cluster"+e}L.FeatureGroup.prototype.fire.call(this,e,t,i)},listens:function(e,t){return L.FeatureGroup.prototype.listens.call(this,e,t)||L.FeatureGroup.prototype.listens.call(this,"cluster"+e,t)},_defaultIconCreateFunction:function(e){var t=e.getChildCount(),i=" marker-cluster-";return i+=t<10?"small":t<100?"medium":"large",new L.DivIcon({html:"<div><span>"+t+"</span></div>",className:"marker-cluster"+i,iconSize:new L.Point(40,40)})},_bindEvents:function(){var e=this._map,t=this.options.spiderfyOnMaxZoom,i=this.options.showCoverageOnHover,r=this.options.zoomToBoundsOnClick,n=this.options.spiderfyOnEveryZoom;(t||r||n)&&this.on("clusterclick clusterkeypress",this._zoomOrSpiderfy,this),i&&(this.on("clustermouseover",this._showCoverage,this),this.on("clustermouseout",this._hideCoverage,this),e.on("zoomend",this._hideCoverage,this))},_zoomOrSpiderfy:function(e){var t=e.layer,i=t;if("clusterkeypress"!==e.type||!e.originalEvent||13===e.originalEvent.keyCode){for(;1===i._childClusters.length;)i=i._childClusters[0];i._zoom===this._maxZoom&&i._childCount===t._childCount&&this.options.spiderfyOnMaxZoom?t.spiderfy():this.options.zoomToBoundsOnClick&&t.zoomToBounds(),this.options.spiderfyOnEveryZoom&&t.spiderfy(),e.originalEvent&&13===e.originalEvent.keyCode&&this._map._container.focus()}},_showCoverage:function(e){var t=this._map;this._inZoomAnimation||(this._shownPolygon&&t.removeLayer(this._shownPolygon),e.layer.getChildCount()>2&&e.layer!==this._spiderfied&&(this._shownPolygon=new L.Polygon(e.layer.getConvexHull(),this.options.polygonOptions),t.addLayer(this._shownPolygon)))},_hideCoverage:function(){this._shownPolygon&&(this._map.removeLayer(this._shownPolygon),this._shownPolygon=null)},_unbindEvents:function(){var e=this.options.spiderfyOnMaxZoom,t=this.options.showCoverageOnHover,i=this.options.zoomToBoundsOnClick,r=this.options.spiderfyOnEveryZoom,n=this._map;(e||i||r)&&this.off("clusterclick clusterkeypress",this._zoomOrSpiderfy,this),t&&(this.off("clustermouseover",this._showCoverage,this),this.off("clustermouseout",this._hideCoverage,this),n.off("zoomend",this._hideCoverage,this))},_zoomEnd:function(){this._map&&(this._mergeSplitClusters(),this._zoom=Math.round(this._map._zoom),this._currentShownBounds=this._getExpandedVisibleBounds())},_moveEnd:function(){if(!this._inZoomAnimation){var e=this._getExpandedVisibleBounds();this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),this._zoom,e),this._topClusterLevel._recursivelyAddChildrenToMap(null,Math.round(this._map._zoom),e),this._currentShownBounds=e}},_generateInitialClusters:function(){var e=Math.ceil(this._map.getMaxZoom()),t=Math.floor(this._map.getMinZoom()),i=this.options.maxClusterRadius,r=i;"function"!=typeof i&&(r=function(){return i}),null!==this.options.disableClusteringAtZoom&&(e=this.options.disableClusteringAtZoom-1),this._maxZoom=e,this._gridClusters={},this._gridUnclustered={};for(var n=e;n>=t;n--)this._gridClusters[n]=new L.DistanceGrid(r(n)),this._gridUnclustered[n]=new L.DistanceGrid(r(n));this._topClusterLevel=new this._markerCluster(this,t-1)},_addLayer:function(e,t){var i,r,n=this._gridClusters,s=this._gridUnclustered,o=Math.floor(this._map.getMinZoom());for(this.options.singleMarkerMode&&this._overrideMarkerIcon(e),e.on(this._childMarkerEventHandlers,this);t>=o;t--){i=this._map.project(e.getLatLng(),t);var a=n[t].getNearObject(i);if(a)return a._addChild(e),void(e.__parent=a);if(a=s[t].getNearObject(i)){var h=a.__parent;h&&this._removeLayer(a,!1);var l=new this._markerCluster(this,t,a,e);n[t].addObject(l,this._map.project(l._cLatLng,t)),a.__parent=l,e.__parent=l;var u=l;for(r=t-1;r>h._zoom;r--)u=new this._markerCluster(this,r,u),n[r].addObject(u,this._map.project(a.getLatLng(),r));return h._addChild(u),void this._removeFromGridUnclustered(a,t)}s[t].addObject(e,i)}this._topClusterLevel._addChild(e),e.__parent=this._topClusterLevel},_refreshClustersIcons:function(){this._featureGroup.eachLayer(function(e){e instanceof L.MarkerCluster&&e._iconNeedsUpdate&&e._updateIcon()})},_enqueue:function(e){this._queue.push(e),this._queueTimeout||(this._queueTimeout=setTimeout(L.bind(this._processQueue,this),300))},_processQueue:function(){for(var e=0;e<this._queue.length;e++)this._queue[e].call(this);this._queue.length=0,clearTimeout(this._queueTimeout),this._queueTimeout=null},_mergeSplitClusters:function(){var e=Math.round(this._map._zoom);this._processQueue(),this._zoom<e&&this._currentShownBounds.intersects(this._getExpandedVisibleBounds())?(this._animationStart(),this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),this._zoom,this._getExpandedVisibleBounds()),this._animationZoomIn(this._zoom,e)):this._zoom>e?(this._animationStart(),this._animationZoomOut(this._zoom,e)):this._moveEnd()},_getExpandedVisibleBounds:function(){return this.options.removeOutsideVisibleBounds?L.Browser.mobile?this._checkBoundsMaxLat(this._map.getBounds()):this._checkBoundsMaxLat(this._map.getBounds().pad(1)):this._mapBoundsInfinite},_checkBoundsMaxLat:function(e){var t=this._maxLat;return void 0!==t&&(e.getNorth()>=t&&(e._northEast.lat=1/0),e.getSouth()<=-t&&(e._southWest.lat=-1/0)),e},_animationAddLayerNonAnimated:function(e,t){if(t===e)this._featureGroup.addLayer(e);else if(2===t._childCount){t._addToMap();var i=t.getAllChildMarkers();this._featureGroup.removeLayer(i[0]),this._featureGroup.removeLayer(i[1])}else t._updateIcon()},_extractNonGroupLayers:function(e,t){var i,r=e.getLayers(),n=0;for(t=t||[];n<r.length;n++)(i=r[n])instanceof L.LayerGroup?this._extractNonGroupLayers(i,t):t.push(i);return t},_overrideMarkerIcon:function(e){return e.options.icon=this.options.iconCreateFunction({getChildCount:function(){return 1},getAllChildMarkers:function(){return[e]}})}});L.MarkerClusterGroup.include({_mapBoundsInfinite:new L.LatLngBounds(new L.LatLng(-1/0,-1/0),new L.LatLng(1/0,1/0))}),L.MarkerClusterGroup.include({_noAnimation:{_animationStart:function(){},_animationZoomIn:function(e,t){this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),e),this._topClusterLevel._recursivelyAddChildrenToMap(null,t,this._getExpandedVisibleBounds()),this.fire("animationend")},_animationZoomOut:function(e,t){this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),e),this._topClusterLevel._recursivelyAddChildrenToMap(null,t,this._getExpandedVisibleBounds()),this.fire("animationend")},_animationAddLayer:function(e,t){this._animationAddLayerNonAnimated(e,t)}},_withAnimation:{_animationStart:function(){this._map._mapPane.className+=" leaflet-cluster-anim",this._inZoomAnimation++},_animationZoomIn:function(e,t){var i,r=this._getExpandedVisibleBounds(),n=this._featureGroup,s=Math.floor(this._map.getMinZoom());this._ignoreMove=!0,this._topClusterLevel._recursively(r,e,s,function(s){var o,a=s._latlng,h=s._markers;for(r.contains(a)||(a=null),s._isSingleParent()&&e+1===t?(n.removeLayer(s),s._recursivelyAddChildrenToMap(null,t,r)):(s.clusterHide(),s._recursivelyAddChildrenToMap(a,t,r)),i=h.length-1;i>=0;i--)o=h[i],r.contains(o._latlng)||n.removeLayer(o)}),this._forceLayout(),this._topClusterLevel._recursivelyBecomeVisible(r,t),n.eachLayer(function(e){e instanceof L.MarkerCluster||!e._icon||e.clusterShow()}),this._topClusterLevel._recursively(r,e,t,function(e){e._recursivelyRestoreChildPositions(t)}),this._ignoreMove=!1,this._enqueue(function(){this._topClusterLevel._recursively(r,e,s,function(e){n.removeLayer(e),e.clusterShow()}),this._animationEnd()})},_animationZoomOut:function(e,t){this._animationZoomOutSingle(this._topClusterLevel,e-1,t),this._topClusterLevel._recursivelyAddChildrenToMap(null,t,this._getExpandedVisibleBounds()),this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),e,this._getExpandedVisibleBounds())},_animationAddLayer:function(e,t){var i=this,r=this._featureGroup;r.addLayer(e),t!==e&&(t._childCount>2?(t._updateIcon(),this._forceLayout(),this._animationStart(),e._setPos(this._map.latLngToLayerPoint(t.getLatLng())),e.clusterHide(),this._enqueue(function(){r.removeLayer(e),e.clusterShow(),i._animationEnd()})):(this._forceLayout(),i._animationStart(),i._animationZoomOutSingle(t,this._map.getMaxZoom(),this._zoom)))}},_animationZoomOutSingle:function(e,t,i){var r=this._getExpandedVisibleBounds(),n=Math.floor(this._map.getMinZoom());e._recursivelyAnimateChildrenInAndAddSelfToMap(r,n,t+1,i);var s=this;this._forceLayout(),e._recursivelyBecomeVisible(r,i),this._enqueue(function(){if(1===e._childCount){var o=e._markers[0];this._ignoreMove=!0,o.setLatLng(o.getLatLng()),this._ignoreMove=!1,o.clusterShow&&o.clusterShow()}else e._recursively(r,i,n,function(e){e._recursivelyRemoveChildrenFromMap(r,n,t+1)});s._animationEnd()})},_animationEnd:function(){this._map&&(this._map._mapPane.className=this._map._mapPane.className.replace(" leaflet-cluster-anim","")),this._inZoomAnimation--,this.fire("animationend")},_forceLayout:function(){L.Util.falseFn(document.body.offsetWidth)}}),L.markerClusterGroup=function(e){return new L.MarkerClusterGroup(e)};var i=L.MarkerCluster=L.Marker.extend({options:L.Icon.prototype.options,initialize:function(e,t,i,r){L.Marker.prototype.initialize.call(this,i?i._cLatLng||i.getLatLng():new L.LatLng(0,0),{icon:this,pane:e.options.clusterPane}),this._group=e,this._zoom=t,this._markers=[],this._childClusters=[],this._childCount=0,this._iconNeedsUpdate=!0,this._boundsNeedUpdate=!0,this._bounds=new L.LatLngBounds,i&&this._addChild(i),r&&this._addChild(r)},getAllChildMarkers:function(e,t){e=e||[];for(var i=this._childClusters.length-1;i>=0;i--)this._childClusters[i].getAllChildMarkers(e,t);for(var r=this._markers.length-1;r>=0;r--)t&&this._markers[r].__dragStart||e.push(this._markers[r]);return e},getChildCount:function(){return this._childCount},zoomToBounds:function(e){for(var t,i=this._childClusters.slice(),r=this._group._map,n=r.getBoundsZoom(this._bounds),s=this._zoom+1,o=r.getZoom();i.length>0&&n>s;){s++;var a=[];for(t=0;t<i.length;t++)a=a.concat(i[t]._childClusters);i=a}n>s?this._group._map.setView(this._latlng,s):n<=o?this._group._map.setView(this._latlng,o+1):this._group._map.fitBounds(this._bounds,e)},getBounds:function(){var e=new L.LatLngBounds;return e.extend(this._bounds),e},_updateIcon:function(){this._iconNeedsUpdate=!0,this._icon&&this.setIcon(this)},createIcon:function(){return this._iconNeedsUpdate&&(this._iconObj=this._group.options.iconCreateFunction(this),this._iconNeedsUpdate=!1),this._iconObj.createIcon()},createShadow:function(){return this._iconObj.createShadow()},_addChild:function(e,t){this._iconNeedsUpdate=!0,this._boundsNeedUpdate=!0,this._setClusterCenter(e),e instanceof L.MarkerCluster?(t||(this._childClusters.push(e),e.__parent=this),this._childCount+=e._childCount):(t||this._markers.push(e),this._childCount++),this.__parent&&this.__parent._addChild(e,!0)},_setClusterCenter:function(e){this._cLatLng||(this._cLatLng=e._cLatLng||e._latlng)},_resetBounds:function(){var e=this._bounds;e._southWest&&(e._southWest.lat=1/0,e._southWest.lng=1/0),e._northEast&&(e._northEast.lat=-1/0,e._northEast.lng=-1/0)},_recalculateBounds:function(){var e,t,i,r,n=this._markers,s=this._childClusters,o=0,a=0,h=this._childCount;if(0!==h){for(this._resetBounds(),e=0;e<n.length;e++)i=n[e]._latlng,this._bounds.extend(i),o+=i.lat,a+=i.lng;for(e=0;e<s.length;e++)(t=s[e])._boundsNeedUpdate&&t._recalculateBounds(),this._bounds.extend(t._bounds),i=t._wLatLng,r=t._childCount,o+=i.lat*r,a+=i.lng*r;this._latlng=this._wLatLng=new L.LatLng(o/h,a/h),this._boundsNeedUpdate=!1}},_addToMap:function(e){e&&(this._backupLatlng=this._latlng,this.setLatLng(e)),this._group._featureGroup.addLayer(this)},_recursivelyAnimateChildrenIn:function(e,t,i){this._recursively(e,this._group._map.getMinZoom(),i-1,function(e){var i,r,n=e._markers;for(i=n.length-1;i>=0;i--)(r=n[i])._icon&&(r._setPos(t),r.clusterHide())},function(e){var i,r,n=e._childClusters;for(i=n.length-1;i>=0;i--)(r=n[i])._icon&&(r._setPos(t),r.clusterHide())})},_recursivelyAnimateChildrenInAndAddSelfToMap:function(e,t,i,r){this._recursively(e,r,t,function(n){n._recursivelyAnimateChildrenIn(e,n._group._map.latLngToLayerPoint(n.getLatLng()).round(),i),n._isSingleParent()&&i-1===r?(n.clusterShow(),n._recursivelyRemoveChildrenFromMap(e,t,i)):n.clusterHide(),n._addToMap()})},_recursivelyBecomeVisible:function(e,t){this._recursively(e,this._group._map.getMinZoom(),t,null,function(e){e.clusterShow()})},_recursivelyAddChildrenToMap:function(e,t,i){this._recursively(i,this._group._map.getMinZoom()-1,t,function(r){if(t!==r._zoom)for(var n=r._markers.length-1;n>=0;n--){var s=r._markers[n];i.contains(s._latlng)&&(e&&(s._backupLatlng=s.getLatLng(),s.setLatLng(e),s.clusterHide&&s.clusterHide()),r._group._featureGroup.addLayer(s))}},function(t){t._addToMap(e)})},_recursivelyRestoreChildPositions:function(e){for(var t=this._markers.length-1;t>=0;t--){var i=this._markers[t];i._backupLatlng&&(i.setLatLng(i._backupLatlng),delete i._backupLatlng)}if(e-1===this._zoom)for(var r=this._childClusters.length-1;r>=0;r--)this._childClusters[r]._restorePosition();else for(var n=this._childClusters.length-1;n>=0;n--)this._childClusters[n]._recursivelyRestoreChildPositions(e)},_restorePosition:function(){this._backupLatlng&&(this.setLatLng(this._backupLatlng),delete this._backupLatlng)},_recursivelyRemoveChildrenFromMap:function(e,t,i,r){var n,s;this._recursively(e,t-1,i-1,function(e){for(s=e._markers.length-1;s>=0;s--)n=e._markers[s],r&&r.contains(n._latlng)||(e._group._featureGroup.removeLayer(n),n.clusterShow&&n.clusterShow())},function(e){for(s=e._childClusters.length-1;s>=0;s--)n=e._childClusters[s],r&&r.contains(n._latlng)||(e._group._featureGroup.removeLayer(n),n.clusterShow&&n.clusterShow())})},_recursively:function(e,t,i,r,n){var s,o,a=this._childClusters,h=this._zoom;if(t<=h&&(r&&r(this),n&&h===i&&n(this)),h<t||h<i)for(s=a.length-1;s>=0;s--)(o=a[s])._boundsNeedUpdate&&o._recalculateBounds(),e.intersects(o._bounds)&&o._recursively(e,t,i,r,n)},_isSingleParent:function(){return this._childClusters.length>0&&this._childClusters[0]._childCount===this._childCount}});L.Marker.include({clusterHide:function(){var e=this.options.opacity;return this.setOpacity(0),this.options.opacity=e,this},clusterShow:function(){return this.setOpacity(this.options.opacity)}}),L.DistanceGrid=function(e){this._cellSize=e,this._sqCellSize=e*e,this._grid={},this._objectPoint={}},L.DistanceGrid.prototype={addObject:function(e,t){var i=this._getCoord(t.x),r=this._getCoord(t.y),n=this._grid,s=n[r]=n[r]||{},o=s[i]=s[i]||[],a=L.Util.stamp(e);this._objectPoint[a]=t,o.push(e)},updateObject:function(e,t){this.removeObject(e),this.addObject(e,t)},removeObject:function(e,t){var i,r,n=this._getCoord(t.x),s=this._getCoord(t.y),o=this._grid,a=o[s]=o[s]||{},h=a[n]=a[n]||[];for(delete this._objectPoint[L.Util.stamp(e)],i=0,r=h.length;i<r;i++)if(h[i]===e)return h.splice(i,1),1===r&&delete a[n],!0},eachObject:function(e,t){var i,r,n,s,o,a,h=this._grid;for(i in h)for(r in o=h[i])for(n=0,s=(a=o[r]).length;n<s;n++)e.call(t,a[n])&&(n--,s--)},getNearObject:function(e){var t,i,r,n,s,o,a,h,l=this._getCoord(e.x),u=this._getCoord(e.y),_=this._objectPoint,d=this._sqCellSize,p=null;for(t=u-1;t<=u+1;t++)if(n=this._grid[t])for(i=l-1;i<=l+1;i++)if(s=n[i])for(r=0,o=s.length;r<o;r++)a=s[r],((h=this._sqDist(_[L.Util.stamp(a)],e))<d||h<=d&&null===p)&&(d=h,p=a);return p},_getCoord:function(e){var t=Math.floor(e/this._cellSize);return isFinite(t)?t:e},_sqDist:function(e,t){var i=t.x-e.x,r=t.y-e.y;return i*i+r*r}},L.QuickHull={getDistant:function(e,t){var i=t[1].lat-t[0].lat;return(t[0].lng-t[1].lng)*(e.lat-t[0].lat)+i*(e.lng-t[0].lng)},findMostDistantPointFromBaseLine:function(e,t){var i,r,n,s=0,o=null,a=[];for(i=t.length-1;i>=0;i--)r=t[i],(n=this.getDistant(r,e))>0&&(a.push(r),n>s&&(s=n,o=r));return{maxPoint:o,newPoints:a}},buildConvexHull:function(e,t){var i=[],r=this.findMostDistantPointFromBaseLine(e,t);return r.maxPoint?i=(i=i.concat(this.buildConvexHull([e[0],r.maxPoint],r.newPoints))).concat(this.buildConvexHull([r.maxPoint,e[1]],r.newPoints)):[e[0]]},getConvexHull:function(e){var t,i=!1,r=!1,n=!1,s=!1,o=null,a=null,h=null,l=null,u=null,_=null;for(t=e.length-1;t>=0;t--){var d=e[t];(!1===i||d.lat>i)&&(o=d,i=d.lat),(!1===r||d.lat<r)&&(a=d,r=d.lat),(!1===n||d.lng>n)&&(h=d,n=d.lng),(!1===s||d.lng<s)&&(l=d,s=d.lng)}return r!==i?(_=a,u=o):(_=l,u=h),[].concat(this.buildConvexHull([_,u],e),this.buildConvexHull([u,_],e))}},L.MarkerCluster.include({getConvexHull:function(){var e,t,i=this.getAllChildMarkers(),r=[];for(t=i.length-1;t>=0;t--)e=i[t].getLatLng(),r.push(e);return L.QuickHull.getConvexHull(r)}}),L.MarkerCluster.include({_2PI:2*Math.PI,_circleFootSeparation:25,_circleStartAngle:0,_spiralFootSeparation:28,_spiralLengthStart:11,_spiralLengthFactor:5,_circleSpiralSwitchover:9,spiderfy:function(){if(this._group._spiderfied!==this&&!this._group._inZoomAnimation){var e,t=this.getAllChildMarkers(null,!0),i=this._group._map.latLngToLayerPoint(this._latlng);this._group._unspiderfy(),this._group._spiderfied=this,this._group.options.spiderfyShapePositions?e=this._group.options.spiderfyShapePositions(t.length,i):t.length>=this._circleSpiralSwitchover?e=this._generatePointsSpiral(t.length,i):(i.y+=10,e=this._generatePointsCircle(t.length,i)),this._animationSpiderfy(t,e)}},unspiderfy:function(e){this._group._inZoomAnimation||(this._animationUnspiderfy(e),this._group._spiderfied=null)},_generatePointsCircle:function(e,t){var i,r,n=this._group.options.spiderfyDistanceMultiplier*this._circleFootSeparation*(2+e)/this._2PI,s=this._2PI/e,o=[];for(n=Math.max(n,35),o.length=e,i=0;i<e;i++)r=this._circleStartAngle+i*s,o[i]=new L.Point(t.x+n*Math.cos(r),t.y+n*Math.sin(r))._round();return o},_generatePointsSpiral:function(e,t){var i,r=this._group.options.spiderfyDistanceMultiplier,n=r*this._spiralLengthStart,s=r*this._spiralFootSeparation,o=r*this._spiralLengthFactor*this._2PI,a=0,h=[];for(h.length=e,i=e;i>=0;i--)i<e&&(h[i]=new L.Point(t.x+n*Math.cos(a),t.y+n*Math.sin(a))._round()),n+=o/(a+=s/n+5e-4*i);return h},_noanimationUnspiderfy:function(){var e,t,i=this._group,r=i._map,n=i._featureGroup,s=this.getAllChildMarkers(null,!0);for(i._ignoreMove=!0,this.setOpacity(1),t=s.length-1;t>=0;t--)e=s[t],n.removeLayer(e),e._preSpiderfyLatlng&&(e.setLatLng(e._preSpiderfyLatlng),delete e._preSpiderfyLatlng),e.setZIndexOffset&&e.setZIndexOffset(0),e._spiderLeg&&(r.removeLayer(e._spiderLeg),delete e._spiderLeg);i.fire("unspiderfied",{cluster:this,markers:s}),i._ignoreMove=!1,i._spiderfied=null}}),L.MarkerClusterNonAnimated=L.MarkerCluster.extend({_animationSpiderfy:function(e,t){var i,r,n,s,o=this._group,a=o._map,h=o._featureGroup,l=this._group.options.spiderLegPolylineOptions;for(o._ignoreMove=!0,i=0;i<e.length;i++)s=a.layerPointToLatLng(t[i]),r=e[i],n=new L.Polyline([this._latlng,s],l),a.addLayer(n),r._spiderLeg=n,r._preSpiderfyLatlng=r._latlng,r.setLatLng(s),r.setZIndexOffset&&r.setZIndexOffset(1e6),h.addLayer(r);this.setOpacity(.3),o._ignoreMove=!1,o.fire("spiderfied",{cluster:this,markers:e})},_animationUnspiderfy:function(){this._noanimationUnspiderfy()}}),L.MarkerCluster.include({_animationSpiderfy:function(e,t){var i,r,n,s,o,a,h=this,l=this._group,u=l._map,_=l._featureGroup,d=this._latlng,p=u.latLngToLayerPoint(d),c=L.Path.SVG,f=L.extend({},this._group.options.spiderLegPolylineOptions),m=f.opacity;for(void 0===m&&(m=L.MarkerClusterGroup.prototype.options.spiderLegPolylineOptions.opacity),c?(f.opacity=0,f.className=(f.className||"")+" leaflet-cluster-spider-leg"):f.opacity=m,l._ignoreMove=!0,i=0;i<e.length;i++)r=e[i],a=u.layerPointToLatLng(t[i]),n=new L.Polyline([d,a],f),u.addLayer(n),r._spiderLeg=n,c&&(o=(s=n._path).getTotalLength()+.1,s.style.strokeDasharray=o,s.style.strokeDashoffset=o),r.setZIndexOffset&&r.setZIndexOffset(1e6),r.clusterHide&&r.clusterHide(),_.addLayer(r),r._setPos&&r._setPos(p);for(l._forceLayout(),l._animationStart(),i=e.length-1;i>=0;i--)a=u.layerPointToLatLng(t[i]),(r=e[i])._preSpiderfyLatlng=r._latlng,r.setLatLng(a),r.clusterShow&&r.clusterShow(),c&&((s=(n=r._spiderLeg)._path).style.strokeDashoffset=0,n.setStyle({opacity:m}));this.setOpacity(.3),l._ignoreMove=!1,setTimeout(function(){l._animationEnd(),l.fire("spiderfied",{cluster:h,markers:e})},200)},_animationUnspiderfy:function(e){var t,i,r,n,s,o,a=this,h=this._group,l=h._map,u=h._featureGroup,_=e?l._latLngToNewLayerPoint(this._latlng,e.zoom,e.center):l.latLngToLayerPoint(this._latlng),d=this.getAllChildMarkers(null,!0),p=L.Path.SVG;for(h._ignoreMove=!0,h._animationStart(),this.setOpacity(1),i=d.length-1;i>=0;i--)(t=d[i])._preSpiderfyLatlng&&(t.closePopup(),t.setLatLng(t._preSpiderfyLatlng),delete t._preSpiderfyLatlng,o=!0,t._setPos&&(t._setPos(_),o=!1),t.clusterHide&&(t.clusterHide(),o=!1),o&&u.removeLayer(t),p&&(s=(n=(r=t._spiderLeg)._path).getTotalLength()+.1,n.style.strokeDashoffset=s,r.setStyle({opacity:0})));h._ignoreMove=!1,setTimeout(function(){var e=0;for(i=d.length-1;i>=0;i--)(t=d[i])._spiderLeg&&e++;for(i=d.length-1;i>=0;i--)(t=d[i])._spiderLeg&&(t.clusterShow&&t.clusterShow(),t.setZIndexOffset&&t.setZIndexOffset(0),e>1&&u.removeLayer(t),l.removeLayer(t._spiderLeg),delete t._spiderLeg);h._animationEnd(),h.fire("unspiderfied",{cluster:a,markers:d})},200)}}),L.MarkerClusterGroup.include({_spiderfied:null,unspiderfy:function(){this._unspiderfy.apply(this,arguments)},_spiderfierOnAdd:function(){this._map.on("click",this._unspiderfyWrapper,this),this._map.options.zoomAnimation&&this._map.on("zoomstart",this._unspiderfyZoomStart,this),this._map.on("zoomend",this._noanimationUnspiderfy,this),L.Browser.touch||this._map.getRenderer(this)},_spiderfierOnRemove:function(){this._map.off("click",this._unspiderfyWrapper,this),this._map.off("zoomstart",this._unspiderfyZoomStart,this),this._map.off("zoomanim",this._unspiderfyZoomAnim,this),this._map.off("zoomend",this._noanimationUnspiderfy,this),this._noanimationUnspiderfy()},_unspiderfyZoomStart:function(){this._map&&this._map.on("zoomanim",this._unspiderfyZoomAnim,this)},_unspiderfyZoomAnim:function(e){L.DomUtil.hasClass(this._map._mapPane,"leaflet-touching")||(this._map.off("zoomanim",this._unspiderfyZoomAnim,this),this._unspiderfy(e))},_unspiderfyWrapper:function(){this._unspiderfy()},_unspiderfy:function(e){this._spiderfied&&this._spiderfied.unspiderfy(e)},_noanimationUnspiderfy:function(){this._spiderfied&&this._spiderfied._noanimationUnspiderfy()},_unspiderfyLayer:function(e){e._spiderLeg&&(this._featureGroup.removeLayer(e),e.clusterShow&&e.clusterShow(),e.setZIndexOffset&&e.setZIndexOffset(0),this._map.removeLayer(e._spiderLeg),delete e._spiderLeg)}}),L.MarkerClusterGroup.include({refreshClusters:function(e){return e?e instanceof L.MarkerClusterGroup?e=e._topClusterLevel.getAllChildMarkers():e instanceof L.LayerGroup?e=e._layers:e instanceof L.MarkerCluster?e=e.getAllChildMarkers():e instanceof L.Marker&&(e=[e]):e=this._topClusterLevel.getAllChildMarkers(),this._flagParentsIconsNeedUpdate(e),this._refreshClustersIcons(),this.options.singleMarkerMode&&this._refreshSingleMarkerModeMarkers(e),this},_flagParentsIconsNeedUpdate:function(e){var t,i;for(t in e)for(i=e[t].__parent;i;)i._iconNeedsUpdate=!0,i=i.__parent},_refreshSingleMarkerModeMarkers:function(e){var t,i;for(t in e)i=e[t],this.hasLayer(i)&&i.setIcon(this._overrideMarkerIcon(i))}}),L.Marker.include({refreshIconOptions:function(e,t){var i=this.options.icon;return L.setOptions(i,e),this.setIcon(i),t&&this.__parent&&this.__parent._group.refreshClusters(this),this}}),e.MarkerClusterGroup=t,e.MarkerCluster=i,Object.defineProperty(e,"__esModule",{value:!0})},"object"==typeof e&&void 0!==t?r(e):"function"==typeof define&&define.amd?define(["exports"],r):r(((i=i||self).Leaflet=i.Leaflet||{},i.Leaflet.markercluster={}))});export default t();
|
package/umd/Cko4QHwX.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var e=Object.create,t=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,n=Object.getPrototypeOf,l=Object.prototype.hasOwnProperty,p=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),a=(p,a,b)=>(b=null!=p?e(n(p)):{},((e,n,p,a)=>{if(n&&"object"==typeof n||"function"==typeof n)for(var b,c=o(n),u=0,O=c.length;u<O;u++)b=c[u],l.call(e,b)||void 0===b||t(e,b,{get:(e=>n[e]).bind(null,b),enumerable:!(a=r(n,b))||a.enumerable});return e})(!a&&p&&p.__esModule?b:t(b,"default",{value:p,enumerable:!0}),p));export{a as n,p as t};
|
package/umd/CnoPTYOO.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as t,h as e,r as s,v as n}from"./C3uDEVBt.js";import{G as o,L as i,Z as r,et as a,it as c,l,q as h,tt as p}from"./BItJQVdK.js";import{n as d}from"./4VTPoA38.js";var u=class extends c{#t;#e=void 0;#s;#n;constructor(t,e){super(),this.#t=t,this.setOptions(e),this.bindMethods(),this.#o()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){const e=this.options;this.options=this.#t.defaultMutationOptions(t),a(this.options,e)||this.#t.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#s,observer:this}),e?.mutationKey&&this.options.mutationKey&&h(e.mutationKey)!==h(this.options.mutationKey)?this.reset():"pending"===this.#s?.state.status&&this.#s.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#s?.removeObserver(this)}onMutationUpdate(t){this.#o(),this.#i(t)}getCurrentResult(){return this.#e}reset(){this.#s?.removeObserver(this),this.#s=void 0,this.#o(),this.#i()}mutate(t,e){return this.#n=e,this.#s?.removeObserver(this),this.#s=this.#t.getMutationCache().build(this.#t,this.options),this.#s.addObserver(this),this.#s.execute(t)}#o(){const t=this.#s?.state??d();this.#e={...t,isPending:"pending"===t.status,isSuccess:"success"===t.status,isError:"error"===t.status,isIdle:"idle"===t.status,mutate:this.mutate,reset:this.reset}}#i(t){o.batch(()=>{if(this.#n&&this.hasListeners()){const s=this.#e.variables,n=this.#e.context,o={client:this.#t,meta:this.options.meta,mutationKey:this.options.mutationKey};if("success"===t?.type){try{this.#n.onSuccess?.(t.data,s,n,o)}catch(e){Promise.reject(e)}try{this.#n.onSettled?.(t.data,null,s,n,o)}catch(e){Promise.reject(e)}}else if("error"===t?.type){try{this.#n.onError?.(t.error,s,n,o)}catch(e){Promise.reject(e)}try{this.#n.onSettled?.(void 0,t.error,s,n,o)}catch(e){Promise.reject(e)}}}this.listeners.forEach(t=>{t(this.#e)})})}};function m(a,c){const l=i(c),[h]=e(()=>new u(l,a));t(()=>{h.setOptions(a)},[h,a]);const d=s(n(t=>h.subscribe(o.batchCalls(t)),[h]),()=>h.getCurrentResult(),()=>h.getCurrentResult()),m=n((t,e)=>{h.mutate(t,e).catch(r)},[h]);if(d.error&&p(h.options.throwOnError,[d.error]))throw d.error;return{...d,mutate:m,mutateAsync:d.mutate}}function g(t){return t?String(t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'"):""}var v={[l.LINK]:'<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24"><path fill="currentColor" d="M5 21q-.825 0-1.412-.587T3 19V5q0-.825.588-1.412T5 3h6q.425 0 .713.288T12 4t-.288.713T11 5H5v14h14v-6q0-.425.288-.712T20 12t.713.288T21 13v6q0 .825-.587 1.413T19 21zM19 6.4L10.4 15q-.275.275-.7.275T9 15t-.275-.7t.275-.7L17.6 5H15q-.425 0-.712-.288T14 4t.288-.712T15 3h5q.425 0 .713.288T21 4v5q0 .425-.288.713T20 10t-.712-.288T19 9z"/></svg>',[l.EMAIL]:'<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24"><path fill="currentColor" d="M12 22q-2.075 0-3.9-.788t-3.175-2.137T2.788 15.9T2 12t.788-3.9t2.137-3.175T8.1 2.788T12 2t3.9.788t3.175 2.137T21.213 8.1T22 12v1.45q0 1.475-1.012 2.513T18.5 17q-.875 0-1.65-.375t-1.3-1.075q-.725.725-1.638 1.088T12 17q-2.075 0-3.537-1.463T7 12t1.463-3.537T12 7t3.538 1.463T17 12v1.45q0 .65.425 1.1T18.5 15t1.075-.45t.425-1.1V12q0-3.35-2.325-5.675T12 4T6.325 6.325T4 12t2.325 5.675T12 20h4q.425 0 .713.288T17 21t-.288.713T16 22zm0-7q1.25 0 2.125-.875T15 12t-.875-2.125T12 9t-2.125.875T9 12t.875 2.125T12 15"/></svg>',[l.PHONE]:'<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24"><path fill="currentColor" d="M19.95 21q-3.125 0-6.175-1.362t-5.55-3.863t-3.862-5.55T3 4.05q0-.45.3-.75t.75-.3H8.1q.35 0 .625.238t.325.562l.65 3.5q.05.4-.025.675T9.4 8.45L6.975 10.9q.5.925 1.187 1.787t1.513 1.663q.775.775 1.625 1.438T13.1 17l2.35-2.35q.225-.225.588-.337t.712-.063l3.45.7q.35.1.575.363T21 15.9v4.05q0 .45-.3.75t-.75.3M6.025 9l1.65-1.65L7.25 5H5.025q.125 1.025.35 2.025T6.025 9m8.95 8.95q.975.425 1.988.675T19 18.95v-2.2l-2.35-.475zm0 0"/></svg>',[l.SMS]:'<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24"><path fill="currentColor" d="m6 18l-2.3 2.3q-.475.475-1.088.213T2 19.575V4q0-.825.588-1.412T4 2h16q.825 0 1.413.588T22 4v12q0 .825-.587 1.413T20 18zm-.85-2H20V4H4v13.125zM4 16V4zm4-5q.425 0 .713-.288T9 10t-.288-.712T8 9t-.712.288T7 10t.288.713T8 11m4 0q.425 0 .713-.288T13 10t-.288-.712T12 9t-.712.288T11 10t.288.713T12 11m4 0q.425 0 .713-.288T17 10t-.288-.712T16 9t-.712.288T15 10t.288.713T16 11"/></svg>',[l.WHATSAPP]:'<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 258"><defs><linearGradient id="logosWhatsappIcon0" x1="50%" x2="50%" y1="100%" y2="0%"><stop offset="0%" stop-color="#1faf38"/><stop offset="100%" stop-color="#60d669"/></linearGradient><linearGradient id="logosWhatsappIcon1" x1="50%" x2="50%" y1="100%" y2="0%"><stop offset="0%" stop-color="#f9f9f9"/><stop offset="100%" stop-color="#fff"/></linearGradient></defs><path fill="url(#logosWhatsappIcon0)" d="M5.463 127.456c-.006 21.677 5.658 42.843 16.428 61.499L4.433 252.697l65.232-17.104a123 123 0 0 0 58.8 14.97h.054c67.815 0 123.018-55.183 123.047-123.01c.013-32.867-12.775-63.773-36.009-87.025c-23.23-23.25-54.125-36.061-87.043-36.076c-67.823 0-123.022 55.18-123.05 123.004"/><path fill="url(#logosWhatsappIcon1)" d="M1.07 127.416c-.007 22.457 5.86 44.38 17.014 63.704L0 257.147l67.571-17.717c18.618 10.151 39.58 15.503 60.91 15.511h.055c70.248 0 127.434-57.168 127.464-127.423c.012-34.048-13.236-66.065-37.3-90.15C194.633 13.286 162.633.014 128.536 0C58.276 0 1.099 57.16 1.071 127.416m40.24 60.376l-2.523-4.005c-10.606-16.864-16.204-36.352-16.196-56.363C22.614 69.029 70.138 21.52 128.576 21.52c28.3.012 54.896 11.044 74.9 31.06c20.003 20.018 31.01 46.628 31.003 74.93c-.026 58.395-47.551 105.91-105.943 105.91h-.042c-19.013-.01-37.66-5.116-53.922-14.765l-3.87-2.295l-40.098 10.513z"/><path fill="#fff" d="M96.678 74.148c-2.386-5.303-4.897-5.41-7.166-5.503c-1.858-.08-3.982-.074-6.104-.074c-2.124 0-5.575.799-8.492 3.984c-2.92 3.188-11.148 10.892-11.148 26.561s11.413 30.813 13.004 32.94c1.593 2.123 22.033 35.307 54.405 48.073c26.904 10.609 32.379 8.499 38.218 7.967c5.84-.53 18.844-7.702 21.497-15.139c2.655-7.436 2.655-13.81 1.859-15.142c-.796-1.327-2.92-2.124-6.105-3.716s-18.844-9.298-21.763-10.361c-2.92-1.062-5.043-1.592-7.167 1.597c-2.124 3.184-8.223 10.356-10.082 12.48c-1.857 2.129-3.716 2.394-6.9.801c-3.187-1.598-13.444-4.957-25.613-15.806c-9.468-8.442-15.86-18.867-17.718-22.056c-1.858-3.184-.199-4.91 1.398-6.497c1.431-1.427 3.186-3.719 4.78-5.578c1.588-1.86 2.118-3.187 3.18-5.311c1.063-2.126.531-3.986-.264-5.579c-.798-1.593-6.987-17.343-9.819-23.64"/></svg>',[l.MESSENGER]:'<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256"><defs><radialGradient id="logosMessenger0" cx="19.247%" cy="99.465%" r="108.96%" fx="19.247%" fy="99.465%"><stop offset="0%" stop-color="#09f"/><stop offset="60.975%" stop-color="#a033ff"/><stop offset="93.482%" stop-color="#ff5280"/><stop offset="100%" stop-color="#ff7061"/></radialGradient></defs><path fill="url(#logosMessenger0)" d="M128 0C55.894 0 0 52.818 0 124.16c0 37.317 15.293 69.562 40.2 91.835c2.09 1.871 3.352 4.493 3.438 7.298l.697 22.77c.223 7.262 7.724 11.988 14.37 9.054L84.111 243.9a10.22 10.22 0 0 1 6.837-.501c11.675 3.21 24.1 4.92 37.052 4.92c72.106 0 128-52.818 128-124.16S200.106 0 128 0"/><path fill="#fff" d="m51.137 160.47l37.6-59.653c5.98-9.49 18.788-11.853 27.762-5.123l29.905 22.43a7.68 7.68 0 0 0 9.252-.027l40.388-30.652c5.39-4.091 12.428 2.36 8.82 8.085l-37.6 59.654c-5.981 9.489-18.79 11.852-27.763 5.122l-29.906-22.43a7.68 7.68 0 0 0-9.25.027l-40.39 30.652c-5.39 4.09-12.427-2.36-8.818-8.085"/></svg>'},f=class{constructor(t,e,s){this.lightbox=t,this.captureAdImpression=e,this.captureAdClick=s,this.captionOn=!0,this.options={captionButtonOrder:8},t.on("init",()=>{this.initPswpEvents(t.pswp)})}getRootNode(){return this.lightbox?.pswp?.element?.getRootNode?.()||document}getElementById(t){const e=this.getRootNode();return"function"==typeof e.getElementById?e.getElementById(t):e.querySelector?.(`#${t}`)||document.getElementById(t)}querySelector(t){return this.getRootNode().querySelector?.(t)||document.querySelector(t)}initPswpEvents(t){t.on("uiRegister",()=>{t.ui.registerElement({name:"caption-toggle-button",title:"Toggle caption view",order:this.options.captionButtonOrder,isButton:!0,html:'<svg aria-hidden="true" class="pswp__icn p-0.5" viewBox="0 0 24 24"><use class="pswp__icn-shadow" xlink:href="#pswp__icn-show-caption"/><use class="pswp__icn-shadow" xlink:href="#pswp__icn-hide-caption"/><path id="pswp__icn-show-caption" d="M5 20q-.825 0-1.412-.587T3 18V6q0-.825.588-1.412T5 4h14q.825 0 1.413.588T21 6v12q0 .825-.587 1.413T19 20zm0-2h14V6H5zm2-3h3q.425 0 .713-.288T11 14v-.5q0-.225-.15-.375t-.375-.15h-.45q-.225 0-.375.15t-.15.375h-2v-3h2q0 .225.15.375t.375.15h.45q.225 0 .375-.15T11 10.5V10q0-.425-.288-.712T10 9H7q-.425 0-.712.288T6 10v4q0 .425.288.713T7 15m10-6h-3q-.425 0-.712.288T13 10v4q0 .425.288.713T14 15h3q.425 0 .713-.288T18 14v-.5q0-.225-.15-.375t-.375-.15h-.45q-.225 0-.375.15t-.15.375h-2v-3h2q0 .225.15.375t.375.15h.45q.225 0 .375-.15T18 10.5V10q0-.425-.288-.712T17 9M5 18V6z"/><path id="pswp__icn-hide-caption" style="display:none" d="m9.025 9l1.5 1.5H7.5v3h2q0-.225.15-.375t.375-.15h.45q.225 0 .375.15t.15.375v.5q0 .425-.288.713T10 15H7q-.425 0-.712-.288T6 14v-4q0-.425.288-.712T7 9zM21 6v10q0 .5-.325.763t-.7.262t-.675-.262T19 16V6H8.975q-.5 0-.75-.312T7.975 5t.25-.687t.75-.313H19q.825 0 1.413.588T21 6m-3 8q0 .225-.088.438t-.262.337L16.375 13.5h.125q0-.225.15-.375t.375-.15h.45q.225 0 .375.15t.15.375zm-1-5q.425 0 .713.288T18 10v.5q0 .225-.15.375t-.375.15h-.45q-.225 0-.375-.15t-.15-.375h-2v1.125l-1.5-1.5V10q0-.425.288-.712T14 9zM5 20q-.825 0-1.412-.587T3 18V6q0-.625.338-1.112t.862-.713L6.025 6H5v12h10.175L1.375 4.225q-.3-.3-.3-.712t.3-.713t.713-.3t.712.3l18.375 18.375q.3.3.3.713t-.3.712t-.712.3t-.713-.3L17.175 20z"/></svg>',onClick:()=>{this.toggleCaption(t)}}),t.ui.registerElement({name:"custom-caption",isButton:!1,appendTo:"root",html:'<div id="pswp-caption-container" class=" absolute bottom-0 w-full bg-transparent"></div>'})}),t.on("change",()=>{this.captionOn&&this.updateCaption(t)}),t.on("close",()=>{this.clearCaption()})}toggleCaption(t){this.captionOn?this.clearCaption():this.updateCaption(t),this.captionOn=!this.captionOn;const e=this.querySelector("#pswp__icn-show-caption"),s=this.querySelector("#pswp__icn-hide-caption");e&&(e.style.display=this.captionOn?"inline":"none"),s&&(s.style.display=this.captionOn?"none":"inline")}createCaptionHTML(t){const{id:e,type:s,caption:n,title:o,description:i,targetType:r,targetText:a,targetUrl:c}=t||{},h=Boolean(r)&&String(r)!==String(l.NONE),p=h?r:l.LINK;switch("ad"===s&&this.captureAdImpression&&this.captureAdImpression(e),s){case"image":case"video":return n?.length>0?`\n <div class=" w-full bg-black/50 p-4 text-gray-300">\n <h3 class=" text-center sm:text-lg">${g(n)}</h3>\n </div>\n `:"";case"ad":return`\n <div class=" w-full bg-black/85 p-4 text-white">\n <div class=" mx-auto w-full max-w-2xl space-y-2 text-center">\n <h3 class=" text-center sm:text-lg">${g(o)}</h3>\n <h4 class=" pb-2 text-center text-sm sm:text-base">${g(i)}</h4>\n ${h?`<button\n class=" flex w-full items-center justify-center gap-3 rounded-md bg-white py-1 text-lg text-black caption-action-button"\n data-id="${g(e)}"\n data-target-type="${g(p)}"\n data-target-url="${g(c)}">\n ${v[p]}\n ${g(a)}\n </button>`:""}\n </div>\n </div>\n `;default:return""}}updateCaption(t){try{const e=this.getElementById("pswp-caption-container");if(!e)return;const s=t.currSlide?.data;e.innerHTML=this.createCaptionHTML(s);const n=e.querySelector(".caption-action-button");n&&n.addEventListener("click",t=>{const e=t.currentTarget.dataset.id,s=t.currentTarget.dataset.targetType,n=t.currentTarget.dataset.targetUrl;this.captureAdClick&&e&&this.captureAdClick(e,s,n)})}catch(e){console.error("Error rendering caption:",e)}}clearCaption(){const t=this.getElementById("pswp-caption-container");t&&(t.innerHTML="")}},T={videoAttributes:{controls:"",playsinline:"",muted:"",preload:"auto"},autoplay:!0,preventDragOffset:40};function w(t){return t&&t.data&&"video"===t.data.type}var q=class{constructor(t,e){this.options=e,this.initLightboxEvents(t),t.on("init",()=>{this.initPswpEvents(t.pswp)})}initLightboxEvents(t){t.on("contentLoad",this.onContentLoad.bind(this)),t.on("contentDestroy",this.onContentDestroy.bind(this)),t.on("contentActivate",this.onContentActivate.bind(this)),t.on("contentDeactivate",this.onContentDeactivate.bind(this)),t.on("contentAppend",this.onContentAppend.bind(this)),t.on("contentResize",this.onContentResize.bind(this)),t.addFilter("isKeepingPlaceholder",this.isKeepingPlaceholder.bind(this)),t.addFilter("isContentZoomable",this.isContentZoomable.bind(this)),t.addFilter("useContentPlaceholder",this.useContentPlaceholder.bind(this)),t.addFilter("domItemData",(t,e,s)=>("video"===t.type&&s&&(s.dataset.pswpVideoSources?t.videoSources=JSON.parse(s.dataset.pswpVideoSources):s.dataset.pswpVideoSrc?t.videoSrc=s.dataset.pswpVideoSrc:t.videoSrc=s.href),t))}initPswpEvents(t){t.on("pointerDown",e=>{const s=t.currSlide;if(w(s)&&this.options.preventDragOffset){const n=e.originalEvent;if("pointerdown"===n.type){const o=Math.ceil(s.height*s.currZoomLevel)+s.bounds.center.y,i=n.pageY-t.offset.y;i>o-this.options.preventDragOffset&&i<o&&e.preventDefault()}}}),t.on("appendHeavy",t=>{w(t.slide)&&!t.slide.isActive&&t.preventDefault()}),t.on("close",()=>{w(t.currSlide.content)&&this.pauseVideo(t.currSlide.content)})}onContentDestroy({content:t}){w(t)&&t._videoPosterImg&&(t._videoPosterImg.onload=t._videoPosterImg.onerror=null,t._videoPosterImg=null)}onContentResize(t){if(w(t.content)){t.preventDefault();const e=t.width,s=t.height,n=t.content;if(n.element&&(n.element.style.width=`${e}px`,n.element.style.height=`${s}px`),n.slide&&n.slide.placeholder){const t=n.slide.placeholder.element.style;t.transform="none",t.width=`${e}px`,t.height=`${s}px`}}}isKeepingPlaceholder(t,e){return!w(e)&&t}isContentZoomable(t,e){return!w(e)&&t}onContentActivate({content:t}){w(t)&&this.options.autoplay&&this.playVideo(t)}onContentDeactivate({content:t}){w(t)&&this.pauseVideo(t)}onContentAppend(t){w(t.content)&&(t.preventDefault(),t.content.isAttached=!0,t.content.appendImage())}onContentLoad(t){const e=t.content;if(w(t.content)&&(t.preventDefault(),!e.element)){if(e.state="loading",e.type="video",e.element=document.createElement("video"),this.options.videoAttributes)for(let t in this.options.videoAttributes)e.element.setAttribute(t,this.options.videoAttributes[t]||"");e.element.setAttribute("poster",e.data.msrc),this.preloadVideoPoster(e,e.data.msrc),e.element.style.position="relative",e.element.style.left=0,e.element.style.top=0,e.data.videoSources?e.data.videoSources.forEach(t=>{let s=document.createElement("source");s.src=t.src,s.type=t.type,e.element.appendChild(s)}):e.data.videoSrc&&(e.element.src=e.data.videoSrc)}}preloadVideoPoster(t,e){!t._videoPosterImg&&e&&(t._videoPosterImg=new Image,t._videoPosterImg.src=e,t._videoPosterImg.complete?t.onLoaded():t._videoPosterImg.onload=t._videoPosterImg.onerror=()=>{t.onLoaded()})}playVideo(t){t.element&&t.element.play()}pauseVideo(t){t.element&&t.element.pause()}useContentPlaceholder(t,e){return!!w(e)||t}},y=class{constructor(t,e={}){new q(t,{...T,...e})}};export{f as n,m as r,y as t};
|
package/umd/D0VKfxwE.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import{E as e,S as t,T as r,b as a,f as n,h as o,p as s,t as l,v as i,w as d,y as c}from"./C3uDEVBt.js";import{a as p,i as m,n as u,s as f}from"./BItJQVdK.js";import{t as h}from"./b6CwQBFC.js";import{r as b}from"./Cb1JRT_1.js";import{t as v}from"./BkvtmX4K.js";var g=b("inline-flex h-fit flex-auto cursor-pointer items-center justify-center border transition-all duration-200 focus:outline-none active:scale-95",{variants:{size:{sm:"gap-1.5 p-1.5 text-xs",md:"gap-3 px-3 py-2 text-sm",lg:"gap-3 px-4 py-3 text-base"}},defaultVariants:{size:"md"}}),x=({size:e,buttons:t=[],onChange:r,selected:a,className:n})=>/* @__PURE__ */l("div",{className:m("button-group-overlap shadow-outer z-0 flex h-fit rounded",n),children:t.map((n,o)=>{const s=0===o,i=o===t.length-1,d=n.value===a;/* @__PURE__ */
|
|
2
|
-
return l("button",{type:"button",onClick:()=>r?.(n.value),className:m(g({size:e}),d?n.activeClassName?n.activeClassName:"bg-primary border-primary text-primary-foreground hover:bg-primary/90 border":"hover:bg-muted/50 active:bg-muted border-border border",s&&"rounded-l",i&&"rounded-r"),children:[!n.icon&&/* @__PURE__ */l("span",{className:"font-medium sm:py-0.5",children:n.text}),n.icon&&/* @__PURE__ */l("div",{className:"size-6",children:n.icon})]},n.value)})}),N=()=>{const{initializing:e,orgRole:t,user:r,loadingUser:a}=u();return{role:t??void 0,isSuper:Boolean(r?.isSuper),loading:Boolean(a||e),isOwner:t===f.OWNER,isAdmin:t===f.ADMIN,isModerator:t===f.MODERATOR}};function q({content:e,children:t,position:r="top",className:a,contentClassName:n}){const[s,i]=o(!1),{organization:d}=u();/* @__PURE__ */
|
|
3
|
-
return l("div",{className:m("relative inline-block",a),onMouseEnter:()=>i(!0),onMouseLeave:()=>i(!1),onClick:()=>i(!1),onBlur:()=>i(!1),children:[t,s&&/* @__PURE__ */l("div",{className:m("bg-popover text-popover-foreground border-border animate-in data-[side=bottom]:slide-in-from-top-2 data-[side=top]:slide-in-from-bottom-2 pointer-events-auto absolute z-50 rounded border px-3 py-2 text-sm whitespace-nowrap shadow-md",{top:"bottom-full left-1/2 -translate-x-1/2 mb-2",right:"left-full top-1/2 -translate-y-1/2 ml-2",bottom:"top-full left-1/2 -translate-x-1/2 mt-2",left:"right-full top-1/2 -translate-y-1/2 mr-2"}[r],n),"data-side":r,style:p(d),role:"tooltip",children:[e,/* @__PURE__ */l("div",{className:m("border-popover absolute h-0 w-0 border-4",{top:"top-full left-1/2 -translate-x-1/2 border-l-transparent border-r-transparent border-b-transparent",right:"right-full top-1/2 -translate-y-1/2 border-t-transparent border-b-transparent border-l-transparent",bottom:"bottom-full left-1/2 -translate-x-1/2 border-l-transparent border-r-transparent border-t-transparent",left:"left-full top-1/2 -translate-y-1/2 border-t-transparent border-b-transparent border-r-transparent"}[r])})]})]})}function w({className:e}){/* @__PURE__ */
|
|
4
|
-
return l("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:e,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */l("path",{fill:"currentColor",d:"M10.825 22q-.675 0-1.162-.45t-.588-1.1L8.85 18.8q-.325-.125-.612-.3t-.563-.375l-1.55.65q-.625.275-1.25.05t-.975-.8l-1.175-2.05q-.35-.575-.2-1.225t.675-1.075l1.325-1Q4.5 12.5 4.5 12.337v-.675q0-.162.025-.337l-1.325-1Q2.675 9.9 2.525 9.25t.2-1.225L3.9 5.975q.35-.575.975-.8t1.25.05l1.55.65q.275-.2.575-.375t.6-.3l.225-1.65q.1-.65.588-1.1T10.825 2h2.35q.675 0 1.163.45t.587 1.1l.225 1.65q.325.125.613.3t.562.375l1.55-.65q.625-.275 1.25-.05t.975.8l1.175 2.05q.35.575.2 1.225t-.675 1.075l-1.325 1q.025.175.025.338v.674q0 .163-.05.338l1.325 1q.525.425.675 1.075t-.2 1.225l-1.2 2.05q-.35.575-.975.8t-1.25-.05l-1.5-.65q-.275.2-.575.375t-.6.3l-.225 1.65q-.1.65-.587 1.1t-1.163.45zM11 20h1.975l.35-2.65q.775-.2 1.438-.587t1.212-.938l2.475 1.025l.975-1.7l-2.15-1.625q.125-.35.175-.737T17.5 12t-.05-.787t-.175-.738l2.15-1.625l-.975-1.7l-2.475 1.05q-.55-.575-1.212-.962t-1.438-.588L13 4h-1.975l-.35 2.65q-.775.2-1.437.588t-1.213.937L5.55 7.15l-.975 1.7l2.15 1.6q-.125.375-.175.75t-.05.8q0 .4.05.775t.175.75l-2.15 1.625l.975 1.7l2.475-1.05q.55.575 1.213.963t1.437.587zm1.05-4.5q1.45 0 2.475-1.025T15.55 12t-1.025-2.475T12.05 8.5q-1.475 0-2.487 1.025T8.55 12t1.013 2.475T12.05 15.5M12 12"})})}var y=e({open:!1,setOpen:()=>{}});function C({children:e,className:t,open:r,defaultOpen:a=!1,onOpenChange:n}){const[d,c]=o(a),p=void 0!==r?r:d,u=i(e=>{c(e),n?.(e)},[n]),f=s(()=>({open:p,setOpen:u}),[p,u]);/* @__PURE__ */
|
|
5
|
-
return l(y.Provider,{value:f,children:/* @__PURE__ */l("div",{className:m("relative",t),children:e})})}function T({children:e,className:a,asChild:n=!1}){const{open:o,setOpen:s}=c(y),d=i(e=>{e.stopPropagation(),s(!o)},[o,s]);if(n){const n=t(e)[0];return n?r(n,{onClick:e=>{d(e),n.props?.onClick?.(e)},className:m(n.props?.className,a,"cursor-pointer")}):null}/* @__PURE__ */
|
|
6
|
-
return l("span",{onClick:d,className:m("cursor-pointer",a),children:e})}function k({children:e,className:t,align:r="end",side:o="bottom",sideOffset:s=4}){const{open:i,setOpen:d}=c(y),f=n(null),{organization:h}=u();if(a(()=>{if(!i)return;const e=e=>{f.current&&!f.current.contains(e.target)&&d(!1)},t=e=>{"Escape"===e.key&&d(!1)};return document.addEventListener("click",e),document.addEventListener("keydown",t),()=>{document.removeEventListener("click",e),document.removeEventListener("keydown",t)}},[i,d]),!i)return null;const b="start"===r?"left-0":"end"===r?"right-0":"left-1/2 -translate-x-1/2",v="bottom"===o?{top:`calc(100% + ${s}px)`}:{bottom:`calc(100% + ${s}px)`};/* @__PURE__ */
|
|
7
|
-
return l("div",{ref:f,style:{...p(h),...v},className:m("bg-popover text-popover-foreground border-border absolute z-50 min-w-32 rounded border p-1 shadow-md","animate-in fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",b,t),"data-side":o,children:e})}function z({children:e,className:a,href:n,onClick:o,onSelect:s,disabled:p,icon:u,title:f,variant:b="default",isChecked:g,isBeta:x,suffix:N,asChild:q}){const{setOpen:w}=c(y),C=m("hover:bg-primary/20 relative flex w-full cursor-pointer items-center gap-3 rounded px-3 py-2 text-left text-sm transition-colors outline-none select-none",p&&"pointer-events-none opacity-50","destructive"===b&&"text-destructive hover:bg-destructive/10 focus:bg-destructive/10",a),T=e??/* @__PURE__ */l(d,{children:[u,
|
|
8
|
-
/* @__PURE__ */l("span",{className:"flex-1 truncate font-medium",children:f}),g&&/* @__PURE__ */l(v,{className:"text-primary size-5"}),x&&/* @__PURE__ */l("span",{className:"bg-primary text-primary-foreground rounded px-1.5 py-0.5 text-[10px]",children:"BETA"}),N&&/* @__PURE__ */l("span",{children:N})]}),k=i(e=>{p||(s?.(e),o?.(),w(!1))},[p,s,o,w]);if(q&&e){const a=t(e)[0];return a?r(a,{onClick:e=>{k(e),a.props?.onClick?.(e)},className:m(a.props?.className,C)}):null}return n?/* @__PURE__ */l(h,{to:n,onClick:k,className:C,children:T}):/* @__PURE__ */l("button",{onClick:k,className:C,disabled:p,type:"button",children:T})}function O({className:e}){/* @__PURE__ */
|
|
9
|
-
return l("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:e,"aria-hidden":"true",focusable:"false",children:/* @__PURE__ */l("path",{fill:"currentColor",d:"M9.5 16q-2.725 0-4.612-1.888T3 9.5t1.888-4.612T9.5 3t4.613 1.888T16 9.5q0 1.1-.35 2.075T14.7 13.3l5.6 5.6q.275.275.275.7t-.275.7t-.7.275t-.7-.275l-5.6-5.6q-.75.6-1.725.95T9.5 16m0-2q1.875 0 3.188-1.312T14 9.5t-1.312-3.187T9.5 5T6.313 6.313T5 9.5t1.313 3.188T9.5 14"})})}function M({className:e}){/* @__PURE__ */
|
|
10
|
-
return l("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",className:e,"aria-hidden":"true",focusable:"false",children:[/* @__PURE__ */l("path",{fill:"currentColor",d:"M12 2A10 10 0 1 0 22 12A10 10 0 0 0 12 2Zm0 18a8 8 0 1 1 8-8A8 8 0 0 1 12 20Z",opacity:".5"}),/* @__PURE__ */l("path",{fill:"currentColor",d:"M20 12h2A10 10 0 0 0 12 2V4A8 8 0 0 1 20 12Z",children:/* @__PURE__ */l("animateTransform",{attributeName:"transform",dur:"1s",from:"0 12 12",repeatCount:"indefinite",to:"360 12 12",type:"rotate"})})]})}export{z as a,q as c,k as i,N as l,O as n,T as o,C as r,w as s,M as t,x as u};
|