@kanorio/elements 0.0.0-stage → 1.1.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.
Files changed (274) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +57 -2
  3. package/dist/MediaPlayer-7IBSXL7Q.js +2 -0
  4. package/dist/MediaPlayer-HTXF4T2V.js +2 -0
  5. package/dist/PDFViewerFull-FBLYNUDX.js +3 -0
  6. package/dist/PDFViewerFull-KMUVT2BL.js +13 -0
  7. package/dist/altcha-J22D7W3J.js +4 -0
  8. package/dist/altcha-NPBMCOEY.js +4 -0
  9. package/dist/ar-3VA7IUCO.js +2 -0
  10. package/dist/ar-AUQCHHZG.js +2 -0
  11. package/dist/ar-DCOOI5KT.js +2 -0
  12. package/dist/ar-HRZRFWUW.js +2 -0
  13. package/dist/bg-3IK4HFKG.js +2 -0
  14. package/dist/bg-IRGRVWOG.js +2 -0
  15. package/dist/bg-QWC2KG3G.js +2 -0
  16. package/dist/bg-TNDZDXHZ.js +2 -0
  17. package/dist/bn-BHRS66N3.js +2 -0
  18. package/dist/bn-DM5WNGJ5.js +2 -0
  19. package/dist/bn-L44L7SBD.js +2 -0
  20. package/dist/bn-RR3LC6EH.js +2 -0
  21. package/dist/chunk-2UVUNYL6.js +2 -0
  22. package/dist/chunk-37VDVTUT.js +2 -0
  23. package/dist/chunk-3OGF7I4H.js +2 -0
  24. package/dist/chunk-3ZTUZPSD.js +2 -0
  25. package/dist/chunk-5AWUTOK7.js +2 -0
  26. package/dist/chunk-5U2SZE3H.js +2 -0
  27. package/dist/chunk-6LGTFWQS.js +15 -0
  28. package/dist/chunk-A77JMBLF.js +2 -0
  29. package/dist/chunk-BZJ5YCGP.js +2 -0
  30. package/dist/chunk-CDG7S4P5.js +2 -0
  31. package/dist/chunk-CP347QFQ.js +2 -0
  32. package/dist/chunk-DTDUK36B.js +8 -0
  33. package/dist/chunk-DXTWCLOM.js +4 -0
  34. package/dist/chunk-EY4JAVE3.js +2 -0
  35. package/dist/chunk-F5NEDREL.js +2 -0
  36. package/dist/chunk-HBNSRIEP.js +2 -0
  37. package/dist/chunk-JZXJO62T.js +15 -0
  38. package/dist/chunk-LLHBSWTL.js +2 -0
  39. package/dist/chunk-M5GS2ENM.js +2 -0
  40. package/dist/chunk-MG2FK3GU.js +5 -0
  41. package/dist/chunk-N7SSXSF5.js +2 -0
  42. package/dist/chunk-NOCGHD2O.js +2 -0
  43. package/dist/chunk-S4ZA2INU.js +415 -0
  44. package/dist/chunk-TLBIYET7.js +404 -0
  45. package/dist/chunk-TLRFFLH4.js +94 -0
  46. package/dist/chunk-U3U5KVR6.js +2 -0
  47. package/dist/chunk-UBMXRFSK.js +4 -0
  48. package/dist/chunk-V4OWPVBD.js +2 -0
  49. package/dist/chunk-ZDU7A7WZ.js +2 -0
  50. package/dist/chunk-ZSRHO7CJ.js +2 -0
  51. package/dist/cs-3IX2ZQKJ.js +2 -0
  52. package/dist/cs-MFQPSNCV.js +2 -0
  53. package/dist/cs-NZW6FBFY.js +2 -0
  54. package/dist/cs-OMRFBZVP.js +2 -0
  55. package/dist/da-7SYMTSVT.js +2 -0
  56. package/dist/da-AFMLFM32.js +2 -0
  57. package/dist/da-MEA64IPM.js +2 -0
  58. package/dist/da-PZ32KKTE.js +2 -0
  59. package/dist/de-5JPEK4HF.js +2 -0
  60. package/dist/de-7GBTXFMH.js +2 -0
  61. package/dist/de-E4Z2FEBZ.js +2 -0
  62. package/dist/de-MVL4XGYR.js +2 -0
  63. package/dist/deliverables-FBCRGMTB.js +93 -0
  64. package/dist/deliverables-FMKPDHJH.js +92 -0
  65. package/dist/el-BCFO2NS3.js +2 -0
  66. package/dist/el-G2AWU43W.js +2 -0
  67. package/dist/el-O7W5IGS6.js +2 -0
  68. package/dist/el-SMBF7FG4.js +2 -0
  69. package/dist/elements.css +2 -0
  70. package/dist/en-AIAENVLI.js +2 -0
  71. package/dist/en-AU-LB5UVGIW.js +2 -0
  72. package/dist/en-AU-Q2O2HPJ2.js +2 -0
  73. package/dist/en-CA-AZDOY7PW.js +2 -0
  74. package/dist/en-CA-PVKXM3WS.js +2 -0
  75. package/dist/en-CMYO4GCN.js +2 -0
  76. package/dist/en-GB-2N4WB6SL.js +2 -0
  77. package/dist/en-GB-Y5QRPC7S.js +2 -0
  78. package/dist/en-LHV2B2XG.js +2 -0
  79. package/dist/en-SAXQF5YW.js +2 -0
  80. package/dist/en-US-74L4OI3J.js +2 -0
  81. package/dist/en-US-EKS52JBW.js +2 -0
  82. package/dist/errors-OILTIMI5.js +2 -0
  83. package/dist/errors-S4JOS2FB.js +2 -0
  84. package/dist/es-419-CN2GZEOV.js +2 -0
  85. package/dist/es-419-KBS42HIO.js +2 -0
  86. package/dist/es-419-Q5IH6W5F.js +2 -0
  87. package/dist/es-419-VSZWGONE.js +2 -0
  88. package/dist/es-ES-7L55KPLO.js +2 -0
  89. package/dist/es-ES-ETSYFLPQ.js +2 -0
  90. package/dist/es-es-GNKRK4H2.js +2 -0
  91. package/dist/es-es-ZHEJP4O2.js +2 -0
  92. package/dist/fa-FBR4MORA.js +2 -0
  93. package/dist/fa-OYP2Q5EV.js +2 -0
  94. package/dist/fa-QWGXRQ4X.js +2 -0
  95. package/dist/fa-WRJCKGS3.js +2 -0
  96. package/dist/fi-44ST6B6Q.js +2 -0
  97. package/dist/fi-BATN376F.js +2 -0
  98. package/dist/fi-J6NJBPNK.js +2 -0
  99. package/dist/fi-PSUMYQZD.js +2 -0
  100. package/dist/fr-CA-KXRNFZBP.js +2 -0
  101. package/dist/fr-CA-PWWAPLBH.js +2 -0
  102. package/dist/fr-FR-FMLQPLOD.js +2 -0
  103. package/dist/fr-FR-MQAFE7IX.js +2 -0
  104. package/dist/fr-ca-2B3TKJL6.js +2 -0
  105. package/dist/fr-ca-A4GWIOE7.js +2 -0
  106. package/dist/fr-fr-FEUFFV6I.js +2 -0
  107. package/dist/fr-fr-TONIMGOJ.js +2 -0
  108. package/dist/gu-BREQK3GJ.js +2 -0
  109. package/dist/gu-RNCZTEOA.js +2 -0
  110. package/dist/he-4AQSZCU4.js +2 -0
  111. package/dist/he-GNC45OCB.js +2 -0
  112. package/dist/he-RZE7SAH3.js +2 -0
  113. package/dist/he-VXZCGAHY.js +2 -0
  114. package/dist/hi-DKG5TPYX.js +2 -0
  115. package/dist/hi-F7Y62LAZ.js +2 -0
  116. package/dist/hi-G5IRZBZ5.js +2 -0
  117. package/dist/hi-LFKLYYDS.js +2 -0
  118. package/dist/hls-7WKCHYU6.js +45 -0
  119. package/dist/hls-KJIMXAWZ.js +30 -0
  120. package/dist/hu-3Y5YEIFL.js +2 -0
  121. package/dist/hu-BPCAJCJ3.js +2 -0
  122. package/dist/hu-L6W5O2G5.js +2 -0
  123. package/dist/hu-YRQRLSFJ.js +2 -0
  124. package/dist/id-64FYGYA6.js +2 -0
  125. package/dist/id-7DWHYYFC.js +2 -0
  126. package/dist/id-DCV57AQB.js +2 -0
  127. package/dist/id-E4ZYT3YK.js +2 -0
  128. package/dist/index.d.ts +3045 -0
  129. package/dist/index.js +2 -0
  130. package/dist/it-7RASZ4SK.js +2 -0
  131. package/dist/it-BGPYU5QL.js +2 -0
  132. package/dist/it-JICU5WVL.js +2 -0
  133. package/dist/it-YD6A6Q35.js +2 -0
  134. package/dist/ja-4V7QJLTM.js +2 -0
  135. package/dist/ja-52MBIM3T.js +2 -0
  136. package/dist/ja-EGKR5NHK.js +2 -0
  137. package/dist/ja-MA2A5SFZ.js +2 -0
  138. package/dist/kanorio-elements.js +98 -0
  139. package/dist/km-HPCMYWAG.js +2 -0
  140. package/dist/km-PHVYTPLT.js +2 -0
  141. package/dist/kn-5DYCOYAN.js +2 -0
  142. package/dist/kn-QAWBGLHG.js +2 -0
  143. package/dist/ko-55JV4VQK.js +2 -0
  144. package/dist/ko-7QD664NG.js +2 -0
  145. package/dist/ko-FZIJZG6K.js +2 -0
  146. package/dist/ko-G4I5K2UY.js +2 -0
  147. package/dist/lo-JNUKFIQV.js +2 -0
  148. package/dist/lo-YRHYLRZC.js +2 -0
  149. package/dist/ml-3LXSDTNF.js +2 -0
  150. package/dist/ml-QO64O4H6.js +2 -0
  151. package/dist/mr-5WLN37JQ.js +2 -0
  152. package/dist/mr-HGKBSCPM.js +2 -0
  153. package/dist/mr-PLM72664.js +2 -0
  154. package/dist/mr-Q2RUE6T6.js +2 -0
  155. package/dist/ms-N544Y63H.js +2 -0
  156. package/dist/ms-PIAATVMD.js +2 -0
  157. package/dist/my-3J665CWK.js +2 -0
  158. package/dist/my-6IKSM3XW.js +2 -0
  159. package/dist/nb-345ACUTX.js +2 -0
  160. package/dist/nb-F33WYJ6T.js +2 -0
  161. package/dist/nb-VXSPTUAK.js +2 -0
  162. package/dist/nb-ZOWEL6VQ.js +2 -0
  163. package/dist/ne-AAIECB2W.js +2 -0
  164. package/dist/ne-ASFNHMO3.js +2 -0
  165. package/dist/nl-4KAIKVKC.js +2 -0
  166. package/dist/nl-BE-SHZLAL5T.js +2 -0
  167. package/dist/nl-BE-WK4C6XRZ.js +2 -0
  168. package/dist/nl-NL-2YLHGJZL.js +2 -0
  169. package/dist/nl-NL-PHRY43UB.js +2 -0
  170. package/dist/nl-VXJ7CRDZ.js +2 -0
  171. package/dist/nn-I5A2LCBH.js +2 -0
  172. package/dist/nn-S3SNETRB.js +2 -0
  173. package/dist/pa-P2GAYL5A.js +2 -0
  174. package/dist/pa-VX5TUNDP.js +2 -0
  175. package/dist/pl-4Y4BWTLT.js +2 -0
  176. package/dist/pl-BRJ5H72A.js +2 -0
  177. package/dist/pl-OV5IAHMC.js +2 -0
  178. package/dist/pl-SGPLZAER.js +2 -0
  179. package/dist/prod-3BEPDL7S.js +2 -0
  180. package/dist/prod-4MTOPW55.js +2 -0
  181. package/dist/pt-BR-CW3MRSRP.js +2 -0
  182. package/dist/pt-BR-WKEKB5CG.js +2 -0
  183. package/dist/pt-PT-AJZQS2C6.js +2 -0
  184. package/dist/pt-PT-ZTPCI2K6.js +2 -0
  185. package/dist/pt-br-EXNYC3L5.js +2 -0
  186. package/dist/pt-br-IOF65TN2.js +2 -0
  187. package/dist/pt-pt-7BYW57KC.js +2 -0
  188. package/dist/pt-pt-DGEIQHKN.js +2 -0
  189. package/dist/ro-ANISGUFX.js +2 -0
  190. package/dist/ro-GDWJ3F3A.js +2 -0
  191. package/dist/ro-HRV64STT.js +2 -0
  192. package/dist/ro-SLAZ33BA.js +2 -0
  193. package/dist/ru-2GEOOKZX.js +2 -0
  194. package/dist/ru-7U566HR4.js +2 -0
  195. package/dist/ru-EJILX4Y7.js +2 -0
  196. package/dist/ru-PKSZKOLH.js +2 -0
  197. package/dist/si-5F7RWQIE.js +2 -0
  198. package/dist/si-5VUM5FGR.js +2 -0
  199. package/dist/srt-parser-7ZH4HLCL.js +3 -0
  200. package/dist/srt-parser-YWFHXAO4.js +2 -0
  201. package/dist/ssa-parser-2BHZLTC3.js +5 -0
  202. package/dist/ssa-parser-R6G7ZJLU.js +2 -0
  203. package/dist/sv-GFAENRIP.js +2 -0
  204. package/dist/sv-HZVCM7LG.js +2 -0
  205. package/dist/sv-UJ5LCXFA.js +2 -0
  206. package/dist/sv-UOGO55PW.js +2 -0
  207. package/dist/sw-5XU65KFC.js +2 -0
  208. package/dist/sw-EVYAYVM2.js +2 -0
  209. package/dist/sw-HPTUVWO6.js +2 -0
  210. package/dist/sw-KVAYRFED.js +2 -0
  211. package/dist/ta-L62HPFNH.js +2 -0
  212. package/dist/ta-MNWTH3F5.js +2 -0
  213. package/dist/ta-R73RBA23.js +2 -0
  214. package/dist/ta-TOIAFCN5.js +2 -0
  215. package/dist/te-5SBVH4OF.js +2 -0
  216. package/dist/te-GVW56XDM.js +2 -0
  217. package/dist/te-PWIXXRJP.js +2 -0
  218. package/dist/te-WKXYDHSM.js +2 -0
  219. package/dist/th-2GWK7DBB.js +2 -0
  220. package/dist/th-3VH5JHWP.js +2 -0
  221. package/dist/th-F7RKJACJ.js +2 -0
  222. package/dist/th-G6SY3D2Q.js +2 -0
  223. package/dist/tl-OCD2O6J3.js +2 -0
  224. package/dist/tl-PZNXANIM.js +2 -0
  225. package/dist/tr-2BDM6H5Q.js +2 -0
  226. package/dist/tr-RJO57G2Z.js +2 -0
  227. package/dist/tr-TCPMEXLQ.js +2 -0
  228. package/dist/tr-VFMHVRQX.js +2 -0
  229. package/dist/uk-6S7TMK7C.js +2 -0
  230. package/dist/uk-JZQ5M5JE.js +2 -0
  231. package/dist/uk-OQRACKKD.js +2 -0
  232. package/dist/uk-PGHXMWJR.js +2 -0
  233. package/dist/ur-4CR64XUI.js +2 -0
  234. package/dist/ur-CV7QI6IC.js +2 -0
  235. package/dist/ur-J5HV4NTW.js +2 -0
  236. package/dist/ur-PJPC3XAH.js +2 -0
  237. package/dist/vi-MQSOSIUY.js +2 -0
  238. package/dist/vi-THIT43PD.js +2 -0
  239. package/dist/vi-U7OT2LM7.js +2 -0
  240. package/dist/vi-XMAGDR5G.js +2 -0
  241. package/dist/vidstack-B9fTkxQO-EQ52NVZW.js +2 -0
  242. package/dist/vidstack-B9fTkxQO-GEVQP7HO.js +2 -0
  243. package/dist/vidstack-BmcqUMKx-JZPVW77Y.js +2 -0
  244. package/dist/vidstack-BmcqUMKx-XYI2YLUH.js +2 -0
  245. package/dist/vidstack-C0fPJIzs-MDJPXUYY.js +2 -0
  246. package/dist/vidstack-C0fPJIzs-S4BCJHHV.js +2 -0
  247. package/dist/vidstack-CHcsWfRV-UMLDE4ND.js +2 -0
  248. package/dist/vidstack-CHcsWfRV-VTC6J2M3.js +2 -0
  249. package/dist/vidstack-CvezEmSQ-GSHFFL5T.js +2 -0
  250. package/dist/vidstack-CvezEmSQ-X4CSXZAN.js +2 -0
  251. package/dist/vidstack-D2vrrUMs-LK4VWKXR.js +2 -0
  252. package/dist/vidstack-D2vrrUMs-MZTRJLT6.js +2 -0
  253. package/dist/vidstack-Di0HObvT-G6SYBHQL.js +2 -0
  254. package/dist/vidstack-Di0HObvT-P5UCUZVE.js +2 -0
  255. package/dist/vidstack-DiaLSJYx-4FNR72DU.js +2 -0
  256. package/dist/vidstack-DiaLSJYx-SXHLLWKT.js +2 -0
  257. package/dist/vidstack-Dy74GavT-BN73KZQD.js +2 -0
  258. package/dist/vidstack-Dy74GavT-R7RVPT3S.js +2 -0
  259. package/dist/vidstack-GkTzay8D-IY3RQGM5.js +2 -0
  260. package/dist/vidstack-GkTzay8D-PBE5ZIYA.js +2 -0
  261. package/dist/web-components.d.ts +12 -0
  262. package/dist/web-components.js +2 -0
  263. package/dist/worker.js +1 -0
  264. package/dist/zh-CN-CCYHPSVA.js +2 -0
  265. package/dist/zh-CN-RNW2BEY7.js +2 -0
  266. package/dist/zh-HK-HE2T63O2.js +2 -0
  267. package/dist/zh-HK-RKREDSAO.js +2 -0
  268. package/dist/zh-Hant-GBQLGJDF.js +2 -0
  269. package/dist/zh-Hant-T6KHSA5B.js +2 -0
  270. package/dist/zh-cn-NBHEPFJJ.js +2 -0
  271. package/dist/zh-cn-XPV5D6U6.js +2 -0
  272. package/dist/zh-tw-EGRDKAEG.js +2 -0
  273. package/dist/zh-tw-HNBFCMMO.js +2 -0
  274. package/package.json +83 -3
@@ -0,0 +1,2 @@
1
+ import{C as n}from"./chunk-V4OWPVBD.js";function i(){return"https://www.gstatic.com/cv/js/sender/v1/cast_sender.js?loadCastFramework=1"}function c(){return!!window.cast?.framework}function u(){return!!window.chrome?.cast?.isAvailable}function C(){return e().getCastState()===cast.framework.CastState.CONNECTED}function e(){return window.cast.framework.CastContext.getInstance()}function o(){return e().getCurrentSession()}function s(){return o()?.getSessionObj().media[0]}function d(t){return s()?.media.contentId===t?.src}function m(){return{language:"en-US",autoJoinPolicy:chrome.cast.AutoJoinPolicy.ORIGIN_SCOPED,receiverApplicationId:chrome.cast.media.DEFAULT_MEDIA_RECEIVER_APP_ID,resumeSavedSession:!0,androidReceiverCompatible:!0}}function f(t){return`Google Cast Error Code: ${t}`}function g(t,r){return n(e(),t,r)}export{i as a,c as b,u as c,C as d,e,o as f,s as g,d as h,m as i,f as j,g as k};
2
+ //# sourceMappingURL=chunk-37VDVTUT.js.map
@@ -0,0 +1,2 @@
1
+ import{m as B,o as W,p as U,z as Z}from"./chunk-5AWUTOK7.js";import{pg as Y}from"./chunk-S4ZA2INU.js";import{a as oe}from"./chunk-6LGTFWQS.js";import{c as te}from"./chunk-CDG7S4P5.js";var ne="/pdfjs",ge="https://js.kanorio.com/pdfjs",E=ne;function ue(e){E=e.replace(/\/+$/,"")}function re(e){return`${E}/${e}/pdf.worker.min.mjs`}function fe(e){return`${E}/${e}/cmaps/`}function me(e){return`${E}/${e}/standard_fonts/`}function he(e){let r=re(e.version);e.GlobalWorkerOptions.workerSrc!==r&&(e.GlobalWorkerOptions.workerSrc=r)}var I=0,m=null;function $(){if(typeof document>"u")return()=>{};let e=document.documentElement,r=document.body;if(I===0){let c=window.innerWidth-e.clientWidth;m={htmlOverflow:e.style.overflow,bodyOverflow:r.style.overflow,bodyPaddingRight:r.style.paddingRight},e.style.overflow="hidden",r.style.overflow="hidden",c>0&&(r.style.paddingRight=`${c}px`)}I+=1;let a=!1;return()=>{a||(a=!0,I-=1,!(I>0||!m)&&(e.style.overflow=m.htmlOverflow,r.style.overflow=m.bodyOverflow,r.style.paddingRight=m.bodyPaddingRight,m=null))}}var o=te(oe());var H=/\.(avif|gif|jpe?g|png|webp)$/i;function ie(e,r){let a=r?.trim()||B(e)||"image";return H.test(a)?a.replace(H,".jpg"):`${a}.jpg`}async function N(e,r){let a=W(e,{useCase:"lightbox-image",format:"jpeg"}),c=await fetch(a);if(!c.ok)throw new Error(`Failed to fetch image: ${c.status} ${c.statusText}`);let h=await c.blob(),f=document.createElement("a");f.href=URL.createObjectURL(h),f.download=ie(e,r),f.click(),URL.revokeObjectURL(f.href)}var se=1,ae=3,G=.2,ce=.95,le=.9,de="w-10 h-10 md:w-12 md:h-12 rounded-full bg-[color-mix(in_srgb,var(--media-fg)_10%,transparent)] hover:bg-[color-mix(in_srgb,var(--media-fg)_20%,transparent)] flex items-center justify-center transition-all",Ie=`${de} disabled:opacity-30 disabled:cursor-not-allowed`,ke="h-10 md:h-12 min-w-[50px] px-2 rounded-full text-[var(--media-fg)] text-xs md:text-sm font-medium tabular-nums text-center transition-colors enabled:hover:bg-[color-mix(in_srgb,var(--media-fg)_10%,transparent)] disabled:cursor-default";function F(e){return"touches"in e&&e.touches.length>0?{clientX:e.touches[0].clientX,clientY:e.touches[0].clientY}:"changedTouches"in e&&e.changedTouches.length>0?{clientX:e.changedTouches[0].clientX,clientY:e.changedTouches[0].clientY}:{clientX:e.clientX,clientY:e.clientY}}function De({images:e,filenames:r,enableKeyboard:a=!1,onDownload:c,onShare:h}){let{ui:f}=Y(),{imageDownloadUrl:R}=Z(),A=(0,o.useCallback)(()=>typeof window>"u"||typeof window.matchMedia!="function"?!1:window.matchMedia("(hover: hover) and (pointer: fine)").matches,[]),[x,X]=(0,o.useState)(!1),[u,w]=(0,o.useState)(0),[d,v]=(0,o.useState)(1),[y,L]=(0,o.useState)({x:0,y:0}),[k,j]=(0,o.useState)(!1),[D,z]=(0,o.useState)({x:0,y:0}),M=(0,o.useCallback)(()=>{v(t=>{let n=Math.min(t+G,ae);return Math.round(n*10)/10})},[]),_=(0,o.useCallback)(()=>{v(t=>{let n=Math.max(t-G,se),s=Math.round(n*10)/10;return s===1&&L({x:0,y:0}),s})},[]),g=(0,o.useCallback)(()=>{v(1),L({x:0,y:0})},[]),K=(0,o.useCallback)(t=>{w(t),X(!0),v(1),L({x:0,y:0})},[]),T=(0,o.useCallback)(()=>{X(!1),g()},[g]);(0,o.useEffect)(()=>{if(x)return $()},[x]);let S=(0,o.useCallback)(()=>{e.length<=1||(w(t=>t===0?t:t-1),g())},[e.length,g]),P=(0,o.useCallback)(()=>{e.length<=1||(w(t=>t===e.length-1?t:t+1),g())},[e.length,g]);(0,o.useEffect)(()=>{if(!x||!a)return;let t=n=>{let s=A(),l=n.metaKey||n.ctrlKey,i=n.key==="+"||n.key==="="||n.key==="NumpadAdd",p=n.key==="-"||n.key==="_"||n.key==="NumpadSubtract",O=n.key==="0"||n.key==="Numpad0";if(s&&(l&&(i||p||O)||i||p||O)){if(n.preventDefault(),i){M();return}if(p){_();return}g();return}switch(n.key){case"Escape":T();break;case"ArrowLeft":S();break;case"ArrowRight":P();break}};return window.addEventListener("keydown",t),()=>window.removeEventListener("keydown",t)},[x,a,T,S,P,M,_,g,A]);let b=(0,o.useMemo)(()=>{if(d<=1)return{maxOffsetX:0,maxOffsetY:0};let t=typeof window<"u"?window.innerWidth:1920,n=typeof window<"u"?window.innerHeight:1080,s=t*ce,l=n*le,i=s*d,p=l*d,O=Math.max(0,(i-s)/2),ee=Math.max(0,(p-l)/2);return{maxOffsetX:O,maxOffsetY:ee}},[d]),C=(0,o.useCallback)(t=>{if(d<=1)return;j(!0);let{clientX:n,clientY:s}=F(t);z({x:n-y.x,y:s-y.y})},[d,y]),J=(0,o.useCallback)(t=>{if(!k||d<=1)return;let{clientX:n,clientY:s}=F(t),l=n-D.x,i=s-D.y;l=Math.max(-b.maxOffsetX,Math.min(b.maxOffsetX,l)),i=Math.max(-b.maxOffsetY,Math.min(b.maxOffsetY,i)),L({x:l,y:i})},[k,d,D,b]),q=(0,o.useCallback)(()=>{j(!1)},[]),Q=(0,o.useCallback)(async()=>{let t=e[u];if(!t)return;if(c){let i=U(t);await c(i,u);return}let n=r?.[u],s=R(t,n);if(s){let i=document.createElement("a");i.href=s,i.rel="noopener",i.click();return}let l=U(t);await N(l,n)},[e,u,c,r,R]),V=(0,o.useCallback)(async()=>{let t=e[u];if(t){if(h){await h(t,u);return}if(navigator.share)try{await navigator.share({title:f.imageShareTitle,text:f.imageShareText,url:t})}catch{}else try{await navigator.clipboard.writeText(t)}catch{}}},[e,u,h]);return{lightboxOpen:x,lightboxIndex:u,zoomLevel:d,position:y,isDraggingLightbox:k,openLightbox:K,closeLightbox:T,setLightboxIndex:w,prevImage:S,nextImage:P,zoomIn:M,zoomOut:_,resetZoom:g,handleLightboxDragStart:C,handleLightboxDrag:J,handleLightboxDragEnd:q,handleDownload:Q,handleShare:V}}export{ge as a,ue as b,fe as c,me as d,he as e,$ as f,se as g,ae as h,de as i,Ie as j,ke as k,De as l};
2
+ //# sourceMappingURL=chunk-3OGF7I4H.js.map
@@ -0,0 +1,2 @@
1
+ var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf;var __hasOwnProp=Object.prototype.hasOwnProperty;var __commonJS=(cb,mod)=>function __require(){return mod||(0,cb[__getOwnPropNames(cb)[0]])((mod={exports:{}}).exports,mod),mod.exports};var __export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:true})};var __copyProps=(to,from,except,desc)=>{if(from&&typeof from==="object"||typeof from==="function"){for(let key of __getOwnPropNames(from))if(!__hasOwnProp.call(to,key)&&key!==except)__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable})}return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:true}):target,mod));export{__commonJS,__export,__toESM};
2
+ //# sourceMappingURL=chunk-3ZTUZPSD.js.map
@@ -0,0 +1,2 @@
1
+ import{a as q}from"./chunk-S4ZA2INU.js";import{a as xe}from"./chunk-6LGTFWQS.js";import{c as v}from"./chunk-CDG7S4P5.js";function Ze(e,t){return{locale:t,ui:e.ui,search:e.search,shop:e.shop,blog:e.blog,productInfo:e.productInfo,delivery:e.delivery,paymentMethods:e.orderStatus.methodTypes,cookieSettings:e.cookieConsent.settings,curriculum:{contentUnitsCount:e.account.contentUnitsCount,contentPreviewBadge:e.account.contentPreviewBadge,contentLocked:e.account.contentLocked,contentOptional:e.account.contentOptional,contentLoadError:e.account.contentLoadError,contentNoUnits:e.account.contentNoUnits}}}function Qe(e,t){let n=e;for(let[r,i]of Object.entries(t))n=n.replaceAll(`{${r}}`,i);return n}function K(e,t){if(e==null||e.length<=t)return e;let n=0;for(let r=0;n<e.length&&r<t;r++)n+=(e.codePointAt(n)??0)>65535?2:1;return e.slice(0,n)}var Re=["top-left","top","top-right","left","center","right","bottom-left","bottom","bottom-right"],we=["logo","text","image"],Z={min:5,max:50,default:20},Q={min:10,max:100,default:60},Ae=60,J={pages:!0,articles:!0,products:!1},E={enabled:!1,source:"logo",text:"",image:null,layout:"single",position:"bottom-right",size:Z.default,opacity:Q.default,apply:J,overlay:null,version:null,activatedAt:null,deactivatedAt:null},M={allowDownload:!0,keepCopyright:!0,deterrence:!1,watermark:E};function Y(e,t){return typeof e!="number"||!Number.isFinite(e)?t.default:Math.min(t.max,Math.max(t.min,Math.round(e)))}function X(e,t,n){return typeof e=="string"&&t.includes(e)?e:n}function Ie(e){let t=e&&typeof e=="object"?e:{},n=r=>typeof t[r]=="boolean"?t[r]:J[r];return{pages:n("pages"),articles:n("articles"),products:n("products")}}function Me(e){let t=e&&typeof e=="object"?e:{},n=t.overlay&&typeof t.overlay=="object"?t.overlay:null,r=n&&typeof n.url=="string"&&typeof n.width=="number"&&typeof n.height=="number"&&typeof n.key=="string"?{url:n.url,width:n.width,height:n.height,key:n.key}:null,i=Array.isArray(t.regenHistory)?t.regenHistory.filter(a=>typeof a=="string"&&!Number.isNaN(Date.parse(a))):void 0,o=$(t.scheduledAt);return{enabled:t.enabled===!0,source:X(t.source,we,E.source),text:typeof t.text=="string"?K(t.text,Ae):"",image:typeof t.image=="string"&&t.image?t.image:null,layout:t.layout==="tile"?"tile":"single",position:X(t.position,Re,E.position),size:Y(t.size,Z),opacity:Y(t.opacity,Q),apply:Ie(t.apply),overlay:r,version:typeof t.version=="string"&&t.version?t.version:null,activatedAt:$(t.activatedAt),deactivatedAt:$(t.deactivatedAt),...i&&i.length>0?{regenHistory:i}:{},...o?{scheduledAt:o}:{}}}function $(e){return typeof e=="string"&&!Number.isNaN(Date.parse(e))?e:null}function nt(e){let t=e&&typeof e=="object"?e:{},n=r=>typeof t[r]=="boolean"?t[r]:M[r];return{allowDownload:n("allowDownload"),keepCopyright:n("keepCopyright"),deterrence:n("deterrence"),watermark:Me(t.watermark)}}function rt(e){return e.allowDownload&&!e.deterrence}function it(e){return!e.deterrence}var y=v(xe());var ee=["24:9","21:9","16:9","4:3","1:1","4:5"],te=["16:9","4:3","1:1","3:4","4:5"],Se=["4:3","1:1","3:4"];function d(e){if(typeof e!="string")return null;let t=/^(\d+(?:\.\d+)?):(\d+(?:\.\d+)?)$/.exec(e.trim());if(!t)return null;let n=Number(t[1]),r=Number(t[2]);if(!Number.isFinite(n)||!Number.isFinite(r)||n<=0||r<=0)return null;let i=n/r;return i<.25-1e-6||i>5+1e-6?null:i}function at(e){return e.desktop===null||e.tablet===null||e.mobile===null}var T={mobile:{fill:"absolute inset-0 h-full w-full",flow:"relative h-auto w-full"},tablet:{fill:"md:absolute md:inset-0 md:h-full",flow:"md:relative md:inset-auto md:h-auto"},desktop:{fill:"lg:absolute lg:inset-0 lg:h-full",flow:"lg:relative lg:inset-auto lg:h-auto"}};function st(e){let t=a=>a&&d(a)?"fill":"flow",n=t(e.mobile),r=t(e.tablet),i=t(e.desktop),o=[T.mobile[n]];return r!==n&&o.push(T.tablet[r]),i!==r&&o.push(T.desktop[i]),o.join(" ")}function Fe(e){switch(e??"standard"){case"compact":return"24:9";case"tall":return"16:9";default:return"21:9"}}var D={"page-main-visual:banner-profile":{tabletInherits:"desktop",devices:["desktop","tablet","mobile"],presets:ee,allowCustomRatio:!0},"page-main-visual:split-hero":{tabletInherits:"mobile",devices:["desktop","tablet","mobile"],presets:te,allowCustomRatio:!0},"page-main-visual:overlay-hero":{tabletInherits:"desktop",devices:["desktop","mobile"],presets:["16:9","4:5"],allowCustomRatio:!1,fixedHeight:!0},"image-text-split":{tabletInherits:"mobile",devices:["desktop","tablet","mobile"],presets:te,allowCustomRatio:!0,allowNatural:!0},"full-width-image":{tabletInherits:"desktop",devices:["desktop","tablet","mobile"],presets:ee,allowCustomRatio:!0,allowNatural:!0},"card-grid":{tabletInherits:"desktop",devices:["desktop"],presets:Se,allowCustomRatio:!1},"multi-link":{tabletInherits:"desktop",devices:["desktop"],presets:["4:3"],allowCustomRatio:!1}};function ne(e,t,n="desktop"){if(e==null)return{desktop:t,tablet:t,mobile:t};if(typeof e!="object")return{desktop:e,tablet:e,mobile:e};let r=e,i=r.desktop??t,o=r.mobile??i,a=r.tablet??(n==="mobile"?o:i);return{desktop:i,tablet:a,mobile:o}}function ke(e){let t=e.layout??"banner-profile";if(t==="overlay-hero")return{policy:D["page-main-visual:overlay-hero"],ratios:{desktop:"16:9",tablet:"16:9",mobile:"4:5"},fixedHeight:!0};if(t==="split-hero"){let o=D["page-main-visual:split-hero"],a=ne(e.imageRatio,"4:3",o.tabletInherits);return{policy:o,ratios:{desktop:a.desktop==="natural"||!d(a.desktop)?"4:3":a.desktop,tablet:a.tablet==="natural"||!d(a.tablet)?"4:3":a.tablet,mobile:a.mobile==="natural"||!d(a.mobile)?"4:3":a.mobile},fixedHeight:!1}}let n=D["page-main-visual:banner-profile"],r=Fe(e.bannerHeight),i=ne(e.imageRatio,r,n.tabletInherits);return{policy:n,ratios:{desktop:i.desktop==="natural"||!d(i.desktop)?r:i.desktop,tablet:i.tablet==="natural"||!d(i.tablet)?r:i.tablet,mobile:i.mobile==="natural"||!d(i.mobile)?r:i.mobile},fixedHeight:!1}}function Ce(e){let t=e.desktop,n=e.tablet,r=e.mobile;if(!t&&!n&&!r)return null;if(t&&t===n&&t===r)return[{device:"all",ratio:t}];let i=[];return t&&i.push({device:"desktop",ratio:t}),n&&n!==t&&n!==r&&i.push({device:"tablet",ratio:n}),r&&r!==t&&i.push({device:"mobile",ratio:r}),i.length>0?i:null}function ve(e){let{ratios:t}=ke(e??{});return Ce(t)??[{device:"all",ratio:"21:9"}]}var ct=ve();var S=.05;function re(e){return Math.min(1,Math.max(0,e))}function P(e){if(!e||typeof e!="object")return null;let{x:t,y:n}=e;return typeof t!="number"||typeof n!="number"||!Number.isFinite(t)||!Number.isFinite(n)?null:{x:re(t),y:re(n)}}function ie(e){if(!e||typeof e!="object")return null;let{x:t,y:n,w:r,h:i}=e;if(typeof t!="number"||typeof n!="number"||typeof r!="number"||typeof i!="number"||!Number.isFinite(t)||!Number.isFinite(n)||!Number.isFinite(r)||!Number.isFinite(i))return null;let o=Math.min(1,Math.max(S,r)),a=Math.min(1,Math.max(S,i)),s=Math.min(1-o,Math.max(0,t)),u=Math.min(1-a,Math.max(0,n));return{x:s,y:u,w:o,h:a}}function oe(e){if(!e||typeof e!="object")return null;let t=e;if(typeof t.ratio!="string"||!d(t.ratio))return null;let n=ie(t.rect);return n?{ratio:t.ratio.trim(),rect:n}:null}function $e(e){if(typeof e!="string")return;let t=e.trim();return/^#[0-9a-fA-F]{6}$/.test(t)?t.toLowerCase():void 0}function Ee(e){return Math.abs(e.x-.5)<.005&&Math.abs(e.y-.5)<.005}function _(e){let t=P(e?.focus);return!t||Ee(t)?null:t}function O(e){if(!e?.screens||typeof e.screens!="object")return!1;for(let t of["desktop","tablet","mobile"])if(oe(e.screens[t]))return!0;return!1}function Te(e,t,n){let r=P(e)??{x:.5,y:.5};if(!Number.isFinite(t)||t<=0||!Number.isFinite(n)||n<=0)return{x:0,y:0,w:1,h:1};if(t>=n){let s=Math.min(1,Math.max(S,n/t));return{x:Math.min(1-s,Math.max(0,r.x-s/2)),y:0,w:s,h:1}}let i=1,o=Math.min(1,Math.max(S,t/n));return{x:0,y:Math.min(1-o,Math.max(0,r.y-o/2)),w:i,h:o}}function De(e,t,n){if(!e)return!1;let r=d(e.ratio),i=d(t);if(!r||!i||Math.abs(r-i)/i>.01)return!1;if(n&&n.width>0&&n.height>0&&e.rect.h>0){let o=e.rect.w*n.width/(e.rect.h*n.height);if(Math.abs(o-i)/i>.02)return!1}return!0}function U(e){let{framing:t,device:n,targetRatio:r,tabletInherits:i="desktop"}=e,o=e.source??t?.source??null,a=t?.screens,s=n==="desktop"?["desktop"]:n==="mobile"?["mobile","desktop"]:i==="mobile"?["tablet","mobile","desktop"]:["tablet","desktop"],u=null,c=!1;for(let h of s){let g=oe(a?.[h]);if(g){if(De(g,r,o)){u=g;break}h===n&&(c=!0)}}if(u)return{ratio:r,rect:u.rect,derived:!1,ratioMismatchFallback:!1};let m=d(r)??16/9,l=o&&o.width>0&&o.height>0?o.width/o.height:m;return{ratio:r,rect:Te(t?.focus,l,m),derived:!0,ratioMismatchFallback:c}}function L(e,t){if(!t||!Number.isFinite(t.width)||!Number.isFinite(t.height)||t.width<=0||t.height<=0)return null;let n=ie(e);if(!n)return null;let r=Math.max(0,Math.round(n.x*t.width)),i=Math.max(0,Math.round(n.y*t.height)),o=Math.max(1,Math.round(n.w*t.width)),a=Math.max(1,Math.round(n.h*t.height)),s=Math.max(0,t.width-r-o),u=Math.max(0,t.height-i-a);return i<=1&&s<=1&&u<=1&&r<=1?null:{top:i,right:s,bottom:u,left:r}}function dt(e){let t=n=>`${Math.round(n*1e3)/10}%`;return`${t(e.x)} ${t(e.y)}`}function ae(e){let t=n=>(Math.round(n*100)/100).toFixed(2);return`${t(e.x)}x${t(e.y)}`}var se="asset:",Pe=/^asset:[a-z0-9]+$/;function _e(e){return Pe.test(e)}var ce="xu6i8N5WjaI_9HFe-hZzmg",ht=`https://img.kanorio.com/cdn-cgi/imagedelivery/${ce}`;var bt=String.raw`[^\s"'()<>?#\\]+`,Oe=String.raw`[A-Za-z0-9_.-]+`;function Ue(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}var yt=String.raw`(?:[?#][^\s"'()<>\\]*)?`;var Le=new RegExp(String.raw`^https://(?:imagedelivery\.net|[a-z0-9-]+\.kanorio\.com/cdn-cgi/imagedelivery|img\.kanorio\.com/wm/[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+)/${Ue(ce)}/(${Oe})(?:[/?#]|$)`);function We(e){return e?Le.exec(e)?.[1]??null:null}var Ne="mixed";function ze(e){return e&&e!==Ne?e:null}function xt(e,t){let n=e??"";if(!t?.name)return n;if(!n||n===t.name||t.formerNames?.includes(n))return t.name;let r=t.name.lastIndexOf("."),i=n.lastIndexOf(".");return r<=0||i<=0?n:`${n.slice(0,i)}${t.name.slice(r)}`}function Rt(e,t){if(t.assetId){let i=e[`${se}${t.assetId}`];if(i)return i}if(!t.url)return;if(_e(t.url))return e[t.url];let n=We(t.url);if(n)return e[n];let r=t.url.split(/[?#]/,1)[0];for(let[i,o]of Object.entries(e))if(!i.startsWith(se)&&r.endsWith(`/${i}`))return o}var p=85;function le(e){if(e)try{let t=new URL(e),n=t.pathname.split("/").filter(Boolean);return t.hostname==="imagedelivery.net"&&n.length>=2?n[1]:t.hostname.endsWith(".kanorio.com")&&n[0]==="cdn-cgi"&&n[1]==="imagedelivery"&&n.length>=4?n[3]:void 0}catch{return}}function je(e){return(e.split(/[?#]/,1)[0]??"").toLowerCase().endsWith(".svg")}function R(e){if(!e)return!1;try{let t=new URL(e);return!!(t.hostname==="imagedelivery.net"||t.hostname.endsWith(".kanorio.com")&&t.pathname.startsWith("/cdn-cgi/imagedelivery/"))}catch{return!1}}function He(e){try{let t=new URL(e);return t.searchParams.has("width")||t.searchParams.has("height")||t.searchParams.has("quality")||t.searchParams.has("fit")}catch{return!1}}function ue(e){switch(e){case"page-main-visual-background":return{width:1920,quality:p,fit:"cover"};case"page-main-visual-logo":return{width:600,height:600,quality:p,fit:"scale-down"};case"header-logo":return{width:600,height:600,quality:p,fit:"scale-down"};case"card-grid-carousel-image":return{width:800,quality:p,fit:"crop"};case"image-text-split-image":return{width:1200,quality:p,fit:"crop"};case"multi-image-carousel-image":return{width:1600,quality:p,fit:"scale-down"};case"lightbox-image":return{width:4096,quality:p,fit:"scale-down"};case"full-width-image":return{width:1920,quality:p,fit:"contain"};default:return{width:1920,quality:p,fit:"crop"}}}function z(e){try{let t=new URL(e),n=t.pathname.split("/").filter(Boolean);return t.hostname==="imagedelivery.net"&&n.length>=3?{baseUrl:`${t.protocol}//${t.hostname}`,accountHash:n[0],imageId:n[1],variant:n[2]||"public"}:t.hostname.endsWith(".kanorio.com")&&n[0]==="cdn-cgi"&&n[1]==="imagedelivery"&&n.length>=5?{baseUrl:`${t.protocol}//${t.hostname}/cdn-cgi/imagedelivery`,accountHash:n[2],imageId:n[3],variant:n[4]||"public"}:null}catch{return null}}function Ve(e,t){let{baseUrl:n,accountHash:r,imageId:i}=e,o=ue(t.useCase),a=t.width??o.width,s=t.height??o.height,u=p,c=t.fit??o.fit,m=t.format,l=[];if(t.trim){let{top:h,right:g,bottom:f,left:F}=t.trim;l.push(`trim=${Math.max(0,Math.round(h))};${Math.max(0,Math.round(g))};${Math.max(0,Math.round(f))};${Math.max(0,Math.round(F))}`)}return a&&l.push(`w=${a}`),s&&l.push(`h=${s}`),c&&l.push(`fit=${c}`),!t.trim&&t.focus&&a&&s&&(c==="crop"||c==="cover")&&l.push(`gravity=${ae(t.focus)}`),t.background&&/^#[0-9a-fA-F]{6}$/.test(t.background)&&l.push(`background=${encodeURIComponent(t.background)}`),l.push(`q=${u}`),m&&l.push(`f=${m}`),l.length>0?`${n}/${r}/${i}/${l.join(",")}`:`${n}/${r}/${i}/public`}function Ge(e){return ue(e).width??1920}function W(e,t){if(!R(e)||He(e)&&!t.format)return e;let n=z(e);return n?Ve(n,t):e}function Ct(e){if(!R(e))return e;let t=z(e);return t?`${t.baseUrl}/${t.accountHash}/${t.imageId}/public`:e}var Be=[400,800,1200,1600],qe="(max-width: 768px) 100vw, 960px";function vt(e){if(!R(e))return null;let t=z(e);if(!t)return null;let{baseUrl:n,accountHash:r,imageId:i}=t,o=p,a="scale-down",s=Be.map(c=>`${n}/${r}/${i}/w=${c},fit=${a},q=${o} ${c}w`).join(", ");return{src:`${n}/${r}/${i}/w=800,fit=${a},q=${o}`,srcSet:s,sizes:qe}}var Ke={mobile:[640,1080],tablet:[1024,1536],desktop:[1440,1920]},x={mobile:"(max-width: 767px)",tablet:"(min-width: 768px) and (max-width: 1023px)",desktop:"(min-width: 1024px)"},de=["desktop","tablet","mobile"];function ge(e){let t={};for(let n of de){let r=e.ratios[n];if(!r){t[n]={ratio:null,rect:null};continue}let i=U({framing:e.framing,device:n,targetRatio:r,tabletInherits:e.tabletInherits,source:e.source});t[n]={ratio:r,rect:i.derived?null:i.rect}}return t}function N(e,t){return e.ratio!==t.ratio?!1:!e.rect||!t.rect?e.rect===t.rect:Math.abs(e.rect.x-t.rect.x)<5e-4&&Math.abs(e.rect.y-t.rect.y)<5e-4&&Math.abs(e.rect.w-t.rect.w)<5e-4&&Math.abs(e.rect.h-t.rect.h)<5e-4}function Ye(e,t){let n=Ke[e];return!t||t<=0||t>=n[n.length-1]?n:[...n.filter(r=>r<t),Math.round(t)]}function $t(e){let{src:t,framing:n,deviceRatios:r,tabletInherits:i="desktop"}=e;if(!t||!r)return"single";let o=r.mobile===r.desktop&&r.tablet===r.desktop,a=O(n);if(!a&&o)return"single";let s=R(t)&&!je(t);if(!a)return s?"picture":"single";let u=n?.source&&n.source.width>0&&n.source.height>0?n.source:null,c=ge({framing:n,ratios:r,tabletInherits:i,source:u});return de.some(l=>c[l].rect!==null)?!s||!u?"css-fallback":o&&N(c.desktop,c.tablet)&&N(c.desktop,c.mobile)?"single-trim":"picture":o||!s?"single":"picture"}function Et(e){let t=e.useCase??"general",n=e.width??Ge(t),r=d(e.ratio)??16/9,i=Math.max(1,Math.round(n/r)),o=e.framing?.source&&e.framing.source.width>0&&e.framing.source.height>0?e.framing.source:null,a=U({framing:e.framing,device:"desktop",targetRatio:e.ratio,tabletInherits:e.tabletInherits,source:o}),s=!a.derived&&o?L(a.rect,o):null;return{src:W(e.src,{useCase:t,width:n,height:i,fit:"crop",trim:s,focus:s?null:_(e.framing)}),width:n,height:i}}function Tt(e){let{src:t,useCase:n="general",ratios:r,framing:i,tabletInherits:o="desktop",maxWidth:a}=e;if(!R(t))return null;let s=i?.source&&i.source.width>0&&i.source.height>0?i.source:null,u=_(i),c=ge({framing:i,ratios:r,tabletInherits:o,source:s}),m=b=>{let{ratio:j,rect:H}=c[b],w=j?d(j)??16/9:null,V=H&&s?L(H,s):null,k=Ye(b,a),A=[],he=k.map(I=>{let B=w?W(t,{useCase:n,width:I,height:Math.max(1,Math.round(I/w)),fit:"crop",trim:V,focus:V?null:u}):W(t,{useCase:n,width:I,fit:"scale-down"});return A.push(B),`${B} ${I}w`}),C=k[k.length-1],G=s?s.width/s.height:null,be=w?Math.max(1,Math.round(C/w)):G?Math.max(1,Math.round(C/G)):null,ye=A[A.length-1];return{device:b,media:b==="desktop"?void 0:x[b],src:ye,srcSet:he.join(", "),sizes:e.sizes?.[b]??"100vw",width:C,height:be,urls:A}},l=m("mobile"),h=m("tablet"),g=m("desktop"),f=N(c.tablet,c.desktop)?null:h,F=f?[{media:x.mobile,href:l.src,imageSrcSet:l.srcSet,imageSizes:l.sizes},{media:x.tablet,href:f.src,imageSrcSet:f.srcSet,imageSizes:f.sizes},{media:x.desktop,href:g.src,imageSrcSet:g.srcSet,imageSizes:g.sizes}]:[{media:x.mobile,href:l.src,imageSrcSet:l.srcSet,imageSizes:l.sizes},{media:"(min-width: 768px)",href:g.src,imageSrcSet:g.srcSet,imageSizes:g.sizes}],fe=Array.from(new Set([...l.urls,...f?f.urls:[],...g.urls]));return{mobile:l,tablet:f,desktop:g,preloads:F,allVariantUrls:fe}}var pe=v(q()),Xe={protection:M,imageDownloadUrl:()=>null},me=(0,y.createContext)(Xe);function Ot({protection:e,websiteId:t,apiBase:n="",children:r}){let i=(0,y.useMemo)(()=>({protection:e??M,imageDownloadUrl:(o,a)=>{let s=le(o);if(!t||!s)return null;let u=`${n}/api/public/sites/${encodeURIComponent(t)}/images/${encodeURIComponent(s)}/download`,c=new URLSearchParams;a&&c.set("name",a);let m=c.toString();return m?`${u}?${m}`:u}}),[e,t,n]);return(0,pe.jsx)(me.Provider,{value:i,children:r})}function Ut(){return(0,y.useContext)(me)}export{Ze as a,Qe as b,at as c,st as d,ie as e,$e as f,_ as g,U as h,dt as i,ze as j,xt as k,Rt as l,le as m,je as n,W as o,Ct as p,vt as q,$t as r,Et as s,Tt as t,K as u,nt as v,rt as w,it as x,Ot as y,Ut as z};
2
+ //# sourceMappingURL=chunk-5AWUTOK7.js.map