writer 1.25.0__py3-none-any.whl → 1.26.0rc3__py3-none-any.whl

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 (64) hide show
  1. writer/static/assets/BaseMarkdown-C7JpFNzG.js +1 -0
  2. writer/static/assets/{BlueprintToolbar-CSKyGsgb.js → BlueprintToolbar-Qq1M1yPa.js} +1 -1
  3. writer/static/assets/{BuilderApp-CXGhU9Dc.js → BuilderApp-CVdXjiyA.js} +3 -3
  4. writer/static/assets/{BuilderApplicationSelect-D4YCpoaq.js → BuilderApplicationSelect-BJ3WU4j8.js} +2 -2
  5. writer/static/assets/BuilderBlueprintLibraryPanel-BB2BzDiO.js +1 -0
  6. writer/static/assets/BuilderBlueprintLibraryPanel-qrkMQJpE.css +1 -0
  7. writer/static/assets/{BuilderEmbeddedCodeEditor-eTd4Hh29.js → BuilderEmbeddedCodeEditor-Bp4akO9H.js} +6 -6
  8. writer/static/assets/{BuilderGraphSelect-BSVTkG-Q.js → BuilderGraphSelect-DqqflOEF.js} +2 -2
  9. writer/static/assets/{BuilderInsertionLabel-BQTfooyn.js → BuilderInsertionLabel-DcnE9VFH.js} +1 -1
  10. writer/static/assets/{BuilderInsertionOverlay-CirmjKch.js → BuilderInsertionOverlay-CVXHfCDG.js} +1 -1
  11. writer/static/assets/{BuilderJournal-Do4CUC4U.js → BuilderJournal-BkdpDeUE.js} +2 -2
  12. writer/static/assets/{BuilderModelSelect-CDg6LxWs.js → BuilderModelSelect-B3mOzDst.js} +2 -2
  13. writer/static/assets/BuilderSettings-7A3iq6cl.js +16 -0
  14. writer/static/assets/{BuilderSettings-lZkOXEYw.css → BuilderSettings-BN0g4wlH.css} +1 -1
  15. writer/static/assets/{BuilderSettingsArtifactAPITriggerDetails-2hONOdPT.js → BuilderSettingsArtifactAPITriggerDetails-FkIt0kMq.js} +1 -1
  16. writer/static/assets/BuilderSettingsDeploySharedBlueprint-BdDSjNAL.css +1 -0
  17. writer/static/assets/BuilderSettingsDeploySharedBlueprint-BuSxeIj-.js +1 -0
  18. writer/static/assets/{BuilderSettingsHandlers-wr4bqW4s.js → BuilderSettingsHandlers-DbeF71aV.js} +1 -1
  19. writer/static/assets/{BuilderSidebarComponentTree-XfwZ-TqP.js → BuilderSidebarComponentTree-C14x1rVr.js} +1 -1
  20. writer/static/assets/{BuilderSidebarToolkit-BAq285RS.js → BuilderSidebarToolkit-jy_A1o9f.js} +2 -2
  21. writer/static/assets/{BuilderTemplateEditor-DOyCVTe3.js → BuilderTemplateEditor-BIgBS6qi.js} +1 -1
  22. writer/static/assets/{BuilderVault-7la3LjZT.js → BuilderVault-BgiAbw0w.js} +1 -1
  23. writer/static/assets/{ComponentRenderer-DRTUw3PP.js → ComponentRenderer-BJGX_6iU.js} +1 -1
  24. writer/static/assets/{SharedCopyClipboardButton-BAhxC5LU.js → SharedCopyClipboardButton-ed8bYNvB.js} +1 -1
  25. writer/static/assets/{WdsCheckbox-Bi_HXvVT.js → WdsCheckbox-BYGFbKQr.js} +1 -1
  26. writer/static/assets/{WdsDropdownMenu-BPKaOD8s.js → WdsDropdownMenu-C1nXnj7Y.js} +1 -1
  27. writer/static/assets/{WdsFieldWrapper-CwqGDrlP.js → WdsFieldWrapper-DUvtHQhU.js} +1 -1
  28. writer/static/assets/{WdsTabs-q0kVCXxi.js → WdsTabs-D3_pIGba.js} +1 -1
  29. writer/static/assets/{cssMode-BFJ2uFDF.js → cssMode-4RB2gbaz.js} +1 -1
  30. writer/static/assets/{freemarker2-DrweqdQ1.js → freemarker2-DTEq8jtt.js} +1 -1
  31. writer/static/assets/{handlebars-d2aT2S4T.js → handlebars-Bgenl5pg.js} +1 -1
  32. writer/static/assets/{html-DkR8jQS-.js → html-bSIJxImc.js} +1 -1
  33. writer/static/assets/{htmlMode-ChyeBcvP.js → htmlMode-DIJZeCM_.js} +1 -1
  34. writer/static/assets/{index-uhDDPaD2.js → index-BO2lDBxy.js} +1 -1
  35. writer/static/assets/{index-DHZHZi5W.js → index-CStxQ_Zn.js} +1 -1
  36. writer/static/assets/{index-Bj5EqtwJ.js → index-Tfvjt7wd.js} +47 -47
  37. writer/static/assets/{javascript-DtI3gL80.js → javascript-DEKuJ5Kr.js} +1 -1
  38. writer/static/assets/{jsonMode-B9CbMObz.js → jsonMode-P6mvp974.js} +1 -1
  39. writer/static/assets/{liquid-D620qh4W.js → liquid-CLV-Oo7T.js} +1 -1
  40. writer/static/assets/{mapbox-gl-IM8CBmd8.js → mapbox-gl-DBM-6gcD.js} +1 -1
  41. writer/static/assets/{mdx-CrO1Zrq5.js → mdx-D9lLpWK9.js} +1 -1
  42. writer/static/assets/{pdf-5wahDYbm.js → pdf-Car1WtOr.js} +1 -1
  43. writer/static/assets/{plotly.min-DmBAN9XQ.js → plotly.min-B_7RxSHC.js} +1 -1
  44. writer/static/assets/{python-BwZnPvHK.js → python-CKNDy5FF.js} +1 -1
  45. writer/static/assets/{razor-DIsRzgu4.js → razor-Hz0J-1ka.js} +1 -1
  46. writer/static/assets/{tsMode-CG0rBgC9.js → tsMode-CNnhj71T.js} +1 -1
  47. writer/static/assets/{typescript-BBvXo7TF.js → typescript-DBSqcEcy.js} +1 -1
  48. writer/static/assets/{useBlueprintRun-DQUAcK67.js → useBlueprintRun-BfljCQFl.js} +1 -1
  49. writer/static/assets/{useKeyValueEditor-vhhDzyE2.js → useKeyValueEditor-D9cp0yxU.js} +1 -1
  50. writer/static/assets/{useListResources-DGx8U65A.js → useListResources-Dz7zv-sv.js} +1 -1
  51. writer/static/assets/{xml-nERONKOk.js → xml-9fwRtLLU.js} +1 -1
  52. writer/static/assets/{yaml-B9E-sHku.js → yaml-COXu8O5A.js} +1 -1
  53. writer/static/index.html +1 -1
  54. {writer-1.25.0.dist-info → writer-1.26.0rc3.dist-info}/METADATA +1 -1
  55. {writer-1.25.0.dist-info → writer-1.26.0rc3.dist-info}/RECORD +58 -58
  56. writer/static/assets/BaseMarkdown-CsWzSrDd.js +0 -1
  57. writer/static/assets/BuilderBlueprintLibraryPanel-Bviy4WUX.js +0 -1
  58. writer/static/assets/BuilderBlueprintLibraryPanel-Ij-jmJNc.css +0 -1
  59. writer/static/assets/BuilderSettings-D96bVVVm.js +0 -16
  60. writer/static/assets/BuilderSettingsDeploySharedBlueprint-Ct5FVU3z.js +0 -1
  61. writer/static/assets/BuilderSettingsDeploySharedBlueprint-KJTl8gxP.css +0 -1
  62. {writer-1.25.0.dist-info → writer-1.26.0rc3.dist-info}/WHEEL +0 -0
  63. {writer-1.25.0.dist-info → writer-1.26.0rc3.dist-info}/entry_points.txt +0 -0
  64. {writer-1.25.0.dist-info → writer-1.26.0rc3.dist-info}/licenses/LICENSE.txt +0 -0
@@ -1,39 +1,39 @@
1
1
  function __vite__mapDeps(indexes) {
2
2
  if (!__vite__mapDeps.viteFileDeps) {
3
- __vite__mapDeps.viteFileDeps = ["./index-5u5REPT4.js","./serialization-DJC7NP0N.js","./Arrow.dom-GBJpMYQS.js","./SharedCopyClipboardButton-BAhxC5LU.js","./WdsDropdownMenu-BPKaOD8s.js","./WdsCheckbox-Bi_HXvVT.js","./WdsCheckbox-DKvpPA4D.css","./WdsDropdownMenu-CzzPN9Wg.css","./SharedCopyClipboardButton-BipJKGtz.css","./index-uhDDPaD2.js","./pdf-5wahDYbm.js","./BlueprintToolbar-CSKyGsgb.js","./useBlueprintRun-DQUAcK67.js","./BlueprintToolbar-wpfX0jo_.css","./BuilderSettingsDeploySharedBlueprint-Ct5FVU3z.js","./WdsFieldWrapper-CwqGDrlP.js","./WdsFieldWrapper-CsemOh8D.css","./BuilderSettingsDeploySharedBlueprint-KJTl8gxP.css","./ComponentRenderer-DRTUw3PP.js","./ComponentRenderer-72hqvEvI.css","./BuilderApp-CXGhU9Dc.js","./marked.esm-273vDTCT.js","./BuilderApp-WimUfNZr.css"]
3
+ __vite__mapDeps.viteFileDeps = ["./index-5u5REPT4.js","./serialization-DJC7NP0N.js","./Arrow.dom-GBJpMYQS.js","./SharedCopyClipboardButton-ed8bYNvB.js","./WdsDropdownMenu-C1nXnj7Y.js","./WdsCheckbox-BYGFbKQr.js","./WdsCheckbox-DKvpPA4D.css","./WdsDropdownMenu-CzzPN9Wg.css","./SharedCopyClipboardButton-BipJKGtz.css","./index-BO2lDBxy.js","./pdf-Car1WtOr.js","./BlueprintToolbar-Qq1M1yPa.js","./useBlueprintRun-BfljCQFl.js","./BlueprintToolbar-wpfX0jo_.css","./BuilderSettingsDeploySharedBlueprint-BuSxeIj-.js","./WdsFieldWrapper-DUvtHQhU.js","./WdsFieldWrapper-CsemOh8D.css","./BuilderSettingsDeploySharedBlueprint-BdDSjNAL.css","./ComponentRenderer-BJGX_6iU.js","./ComponentRenderer-72hqvEvI.css","./BuilderApp-CVdXjiyA.js","./marked.esm-273vDTCT.js","./BuilderApp-WimUfNZr.css"]
4
4
  }
5
5
  return indexes.map((i) => __vite__mapDeps.viteFileDeps[i])
6
6
  }
7
- var w2=(e,t,a)=>{if(!t.has(e))throw TypeError("Cannot "+a)};var xt=(e,t,a)=>(w2(e,t,"read from private field"),a?a.call(e):t.get(e)),Yo=(e,t,a)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,a)},s1=(e,t,a,n)=>(w2(e,t,"write to private field"),n?n.call(e,a):t.set(e,a),a);var fr=(e,t,a)=>(w2(e,t,"access private method"),a);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))n(r);new MutationObserver(r=>{for(const o of r)if(o.type==="childList")for(const s of o.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&n(s)}).observe(document,{childList:!0,subtree:!0});function a(r){const o={};return r.integrity&&(o.integrity=r.integrity),r.referrerPolicy&&(o.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?o.credentials="include":r.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(r){if(r.ep)return;r.ep=!0;const o=a(r);fetch(r.href,o)}})();const P9="modulepreload",L9=function(e,t){return new URL(e,t).href},zu={},zt=function(t,a,n){let r=Promise.resolve();if(a&&a.length>0){const o=document.getElementsByTagName("link"),s=document.querySelector("meta[property=csp-nonce]"),i=(s==null?void 0:s.nonce)||(s==null?void 0:s.getAttribute("nonce"));r=Promise.all(a.map(l=>{if(l=L9(l,n),l in zu)return;zu[l]=!0;const c=l.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(!!n)for(let f=o.length-1;f>=0;f--){const m=o[f];if(m.href===l&&(!c||m.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${l}"]${d}`))return;const h=document.createElement("link");if(h.rel=c?"stylesheet":P9,c||(h.as="script",h.crossOrigin=""),h.href=l,i&&h.setAttribute("nonce",i),document.head.appendChild(h),c)return new Promise((f,m)=>{h.addEventListener("load",f),h.addEventListener("error",()=>m(new Error(`Unable to preload CSS for ${l}`)))})}))}return r.then(()=>t()).catch(o=>{const s=new Event("vite:preloadError",{cancelable:!0});if(s.payload=o,window.dispatchEvent(s),!s.defaultPrevented)throw o})};/**
7
+ var w2=(e,t,a)=>{if(!t.has(e))throw TypeError("Cannot "+a)};var Mt=(e,t,a)=>(w2(e,t,"read from private field"),a?a.call(e):t.get(e)),Qo=(e,t,a)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,a)},s1=(e,t,a,n)=>(w2(e,t,"write to private field"),n?n.call(e,a):t.set(e,a),a);var Vn=(e,t,a)=>(w2(e,t,"access private method"),a);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))n(r);new MutationObserver(r=>{for(const o of r)if(o.type==="childList")for(const s of o.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&n(s)}).observe(document,{childList:!0,subtree:!0});function a(r){const o={};return r.integrity&&(o.integrity=r.integrity),r.referrerPolicy&&(o.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?o.credentials="include":r.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(r){if(r.ep)return;r.ep=!0;const o=a(r);fetch(r.href,o)}})();const P9="modulepreload",L9=function(e,t){return new URL(e,t).href},zu={},zt=function(t,a,n){let r=Promise.resolve();if(a&&a.length>0){const o=document.getElementsByTagName("link"),s=document.querySelector("meta[property=csp-nonce]"),i=(s==null?void 0:s.nonce)||(s==null?void 0:s.getAttribute("nonce"));r=Promise.all(a.map(l=>{if(l=L9(l,n),l in zu)return;zu[l]=!0;const c=l.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(!!n)for(let f=o.length-1;f>=0;f--){const m=o[f];if(m.href===l&&(!c||m.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${l}"]${d}`))return;const h=document.createElement("link");if(h.rel=c?"stylesheet":P9,c||(h.as="script",h.crossOrigin=""),h.href=l,i&&h.setAttribute("nonce",i),document.head.appendChild(h),c)return new Promise((f,m)=>{h.addEventListener("load",f),h.addEventListener("error",()=>m(new Error(`Unable to preload CSS for ${l}`)))})}))}return r.then(()=>t()).catch(o=>{const s=new Event("vite:preloadError",{cancelable:!0});if(s.payload=o,window.dispatchEvent(s),!s.defaultPrevented)throw o})};/**
8
8
  * @vue/shared v3.5.13
9
9
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
10
10
  * @license MIT
11
- **//*! #__NO_SIDE_EFFECTS__ */function gl(e){const t=Object.create(null);for(const a of e.split(","))t[a]=1;return a=>a in t}const Nt={},cs=[],Cn=()=>{},V9=()=>!1,Oi=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Wc=e=>e.startsWith("onUpdate:"),aa=Object.assign,Zc=(e,t)=>{const a=e.indexOf(t);a>-1&&e.splice(a,1)},O9=Object.prototype.hasOwnProperty,Kt=(e,t)=>O9.call(e,t),st=Array.isArray,ds=e=>Es(e)==="[object Map]",Vo=e=>Es(e)==="[object Set]",qu=e=>Es(e)==="[object Date]",H9=e=>Es(e)==="[object RegExp]",gt=e=>typeof e=="function",sa=e=>typeof e=="string",Bn=e=>typeof e=="symbol",ea=e=>e!==null&&typeof e=="object",Kc=e=>(ea(e)||gt(e))&&gt(e.then)&&gt(e.catch),Bm=Object.prototype.toString,Es=e=>Bm.call(e),R9=e=>Es(e).slice(8,-1),yl=e=>Es(e)==="[object Object]",Gc=e=>sa(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,us=gl(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Ml=e=>{const t=Object.create(null);return a=>t[a]||(t[a]=e(a))},N9=/-(\w)/g,Da=Ml(e=>e.replace(N9,(t,a)=>a?a.toUpperCase():"")),D9=/\B([A-Z])/g,rn=Ml(e=>e.replace(D9,"-$1").toLowerCase()),Hi=Ml(e=>e.charAt(0).toUpperCase()+e.slice(1)),li=Ml(e=>e?`on${Hi(e)}`:""),Ja=(e,t)=>!Object.is(e,t),hs=(e,...t)=>{for(let a=0;a<e.length;a++)e[a](...t)},Fm=(e,t,a,n=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:n,value:a})},z1=e=>{const t=parseFloat(e);return isNaN(t)?e:t},q1=e=>{const t=sa(e)?Number(e):NaN;return isNaN(t)?e:t};let Wu;const _l=()=>Wu||(Wu=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),B9="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol",F9=gl(B9);function bt(e){if(st(e)){const t={};for(let a=0;a<e.length;a++){const n=e[a],r=sa(n)?q9(n):bt(n);if(r)for(const o in r)t[o]=r[o]}return t}else if(sa(e)||ea(e))return e}const j9=/;(?![^(]*\))/g,U9=/:([^]+)/,z9=/\/\*[^]*?\*\//g;function q9(e){const t={};return e.replace(z9,"").split(j9).forEach(a=>{if(a){const n=a.split(U9);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function ft(e){let t="";if(sa(e))t=e;else if(st(e))for(let a=0;a<e.length;a++){const n=ft(e[a]);n&&(t+=n+" ")}else if(ea(e))for(const a in e)e[a]&&(t+=a+" ");return t.trim()}function W9(e){if(!e)return null;let{class:t,style:a}=e;return t&&!sa(t)&&(e.class=ft(t)),a&&(e.style=bt(a)),e}const Z9="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",K9=gl(Z9);function jm(e){return!!e||e===""}function G9(e,t){if(e.length!==t.length)return!1;let a=!0;for(let n=0;a&&n<e.length;n++)a=Qr(e[n],t[n]);return a}function Qr(e,t){if(e===t)return!0;let a=qu(e),n=qu(t);if(a||n)return a&&n?e.getTime()===t.getTime():!1;if(a=Bn(e),n=Bn(t),a||n)return e===t;if(a=st(e),n=st(t),a||n)return a&&n?G9(e,t):!1;if(a=ea(e),n=ea(t),a||n){if(!a||!n)return!1;const r=Object.keys(e).length,o=Object.keys(t).length;if(r!==o)return!1;for(const s in e){const i=e.hasOwnProperty(s),l=t.hasOwnProperty(s);if(i&&!l||!i&&l||!Qr(e[s],t[s]))return!1}}return String(e)===String(t)}function bl(e,t){return e.findIndex(a=>Qr(a,t))}const Um=e=>!!(e&&e.__v_isRef===!0),je=e=>sa(e)?e:e==null?"":st(e)||ea(e)&&(e.toString===Bm||!gt(e.toString))?Um(e)?je(e.value):JSON.stringify(e,zm,2):String(e),zm=(e,t)=>Um(t)?zm(e,t.value):ds(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((a,[n,r],o)=>(a[x2(n,o)+" =>"]=r,a),{})}:Vo(t)?{[`Set(${t.size})`]:[...t.values()].map(a=>x2(a))}:Bn(t)?x2(t):ea(t)&&!st(t)&&!yl(t)?String(t):t,x2=(e,t="")=>{var a;return Bn(e)?`Symbol(${(a=e.description)!=null?a:t})`:e};/**
11
+ **//*! #__NO_SIDE_EFFECTS__ */function gl(e){const t=Object.create(null);for(const a of e.split(","))t[a]=1;return a=>a in t}const Nt={},ds=[],Cn=()=>{},V9=()=>!1,Oi=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Wc=e=>e.startsWith("onUpdate:"),na=Object.assign,Zc=(e,t)=>{const a=e.indexOf(t);a>-1&&e.splice(a,1)},O9=Object.prototype.hasOwnProperty,Kt=(e,t)=>O9.call(e,t),st=Array.isArray,us=e=>Is(e)==="[object Map]",Oo=e=>Is(e)==="[object Set]",qu=e=>Is(e)==="[object Date]",H9=e=>Is(e)==="[object RegExp]",gt=e=>typeof e=="function",sa=e=>typeof e=="string",Fn=e=>typeof e=="symbol",ta=e=>e!==null&&typeof e=="object",Kc=e=>(ta(e)||gt(e))&&gt(e.then)&&gt(e.catch),Bm=Object.prototype.toString,Is=e=>Bm.call(e),R9=e=>Is(e).slice(8,-1),yl=e=>Is(e)==="[object Object]",Gc=e=>sa(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,hs=gl(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Ml=e=>{const t=Object.create(null);return a=>t[a]||(t[a]=e(a))},N9=/-(\w)/g,Da=Ml(e=>e.replace(N9,(t,a)=>a?a.toUpperCase():"")),D9=/\B([A-Z])/g,rn=Ml(e=>e.replace(D9,"-$1").toLowerCase()),Hi=Ml(e=>e.charAt(0).toUpperCase()+e.slice(1)),li=Ml(e=>e?`on${Hi(e)}`:""),Ja=(e,t)=>!Object.is(e,t),ps=(e,...t)=>{for(let a=0;a<e.length;a++)e[a](...t)},Fm=(e,t,a,n=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:n,value:a})},z1=e=>{const t=parseFloat(e);return isNaN(t)?e:t},q1=e=>{const t=sa(e)?Number(e):NaN;return isNaN(t)?e:t};let Wu;const _l=()=>Wu||(Wu=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),B9="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol",F9=gl(B9);function wt(e){if(st(e)){const t={};for(let a=0;a<e.length;a++){const n=e[a],r=sa(n)?q9(n):wt(n);if(r)for(const o in r)t[o]=r[o]}return t}else if(sa(e)||ta(e))return e}const j9=/;(?![^(]*\))/g,U9=/:([^]+)/,z9=/\/\*[^]*?\*\//g;function q9(e){const t={};return e.replace(z9,"").split(j9).forEach(a=>{if(a){const n=a.split(U9);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function ft(e){let t="";if(sa(e))t=e;else if(st(e))for(let a=0;a<e.length;a++){const n=ft(e[a]);n&&(t+=n+" ")}else if(ta(e))for(const a in e)e[a]&&(t+=a+" ");return t.trim()}function W9(e){if(!e)return null;let{class:t,style:a}=e;return t&&!sa(t)&&(e.class=ft(t)),a&&(e.style=wt(a)),e}const Z9="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",K9=gl(Z9);function jm(e){return!!e||e===""}function G9(e,t){if(e.length!==t.length)return!1;let a=!0;for(let n=0;a&&n<e.length;n++)a=eo(e[n],t[n]);return a}function eo(e,t){if(e===t)return!0;let a=qu(e),n=qu(t);if(a||n)return a&&n?e.getTime()===t.getTime():!1;if(a=Fn(e),n=Fn(t),a||n)return e===t;if(a=st(e),n=st(t),a||n)return a&&n?G9(e,t):!1;if(a=ta(e),n=ta(t),a||n){if(!a||!n)return!1;const r=Object.keys(e).length,o=Object.keys(t).length;if(r!==o)return!1;for(const s in e){const i=e.hasOwnProperty(s),l=t.hasOwnProperty(s);if(i&&!l||!i&&l||!eo(e[s],t[s]))return!1}}return String(e)===String(t)}function bl(e,t){return e.findIndex(a=>eo(a,t))}const Um=e=>!!(e&&e.__v_isRef===!0),je=e=>sa(e)?e:e==null?"":st(e)||ta(e)&&(e.toString===Bm||!gt(e.toString))?Um(e)?je(e.value):JSON.stringify(e,zm,2):String(e),zm=(e,t)=>Um(t)?zm(e,t.value):us(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((a,[n,r],o)=>(a[x2(n,o)+" =>"]=r,a),{})}:Oo(t)?{[`Set(${t.size})`]:[...t.values()].map(a=>x2(a))}:Fn(t)?x2(t):ta(t)&&!st(t)&&!yl(t)?String(t):t,x2=(e,t="")=>{var a;return Fn(e)?`Symbol(${(a=e.description)!=null?a:t})`:e};/**
12
12
  * @vue/reactivity v3.5.13
13
13
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
14
14
  * @license MIT
15
- **/let Ka;class Jc{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=Ka,!t&&Ka&&(this.index=(Ka.scopes||(Ka.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,a;if(this.scopes)for(t=0,a=this.scopes.length;t<a;t++)this.scopes[t].pause();for(t=0,a=this.effects.length;t<a;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,a;if(this.scopes)for(t=0,a=this.scopes.length;t<a;t++)this.scopes[t].resume();for(t=0,a=this.effects.length;t<a;t++)this.effects[t].resume()}}run(t){if(this._active){const a=Ka;try{return Ka=this,t()}finally{Ka=a}}}on(){Ka=this}off(){Ka=this.parent}stop(t){if(this._active){this._active=!1;let a,n;for(a=0,n=this.effects.length;a<n;a++)this.effects[a].stop();for(this.effects.length=0,a=0,n=this.cleanups.length;a<n;a++)this.cleanups[a]();if(this.cleanups.length=0,this.scopes){for(a=0,n=this.scopes.length;a<n;a++)this.scopes[a].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0}}}function J9(e){return new Jc(e)}function wl(){return Ka}function Xc(e,t=!1){Ka&&Ka.cleanups.push(e)}let oa;const C2=new WeakSet;class xi{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,Ka&&Ka.active&&Ka.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,C2.has(this)&&(C2.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Wm(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Zu(this),Zm(this);const t=oa,a=Dn;oa=this,Dn=!0;try{return this.fn()}finally{Km(this),oa=t,Dn=a,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)e0(t);this.deps=this.depsTail=void 0,Zu(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?C2.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){sc(this)&&this.run()}get dirty(){return sc(this)}}let qm=0,ci,di;function Wm(e,t=!1){if(e.flags|=8,t){e.next=di,di=e;return}e.next=ci,ci=e}function Yc(){qm++}function Qc(){if(--qm>0)return;if(di){let t=di;for(di=void 0;t;){const a=t.next;t.next=void 0,t.flags&=-9,t=a}}let e;for(;ci;){let t=ci;for(ci=void 0;t;){const a=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(n){e||(e=n)}t=a}}if(e)throw e}function Zm(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Km(e){let t,a=e.depsTail,n=a;for(;n;){const r=n.prevDep;n.version===-1?(n===a&&(a=r),e0(n),X9(n)):t=n,n.dep.activeLink=n.prevActiveLink,n.prevActiveLink=void 0,n=r}e.deps=t,e.depsTail=a}function sc(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Gm(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Gm(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Ci))return;e.globalVersion=Ci;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!sc(e)){e.flags&=-3;return}const a=oa,n=Dn;oa=e,Dn=!0;try{Zm(e);const r=e.fn(e._value);(t.version===0||Ja(r,e._value))&&(e._value=r,t.version++)}catch(r){throw t.version++,r}finally{oa=a,Dn=n,Km(e),e.flags&=-3}}function e0(e,t=!1){const{dep:a,prevSub:n,nextSub:r}=e;if(n&&(n.nextSub=r,e.prevSub=void 0),r&&(r.prevSub=n,e.nextSub=void 0),a.subs===e&&(a.subs=n,!n&&a.computed)){a.computed.flags&=-5;for(let o=a.computed.deps;o;o=o.nextDep)e0(o,!0)}!t&&!--a.sc&&a.map&&a.map.delete(a.key)}function X9(e){const{prevDep:t,nextDep:a}=e;t&&(t.nextDep=a,e.prevDep=void 0),a&&(a.prevDep=t,e.nextDep=void 0)}function Y9(e,t){e.effect instanceof xi&&(e=e.effect.fn);const a=new xi(e);t&&aa(a,t);try{a.run()}catch(r){throw a.stop(),r}const n=a.run.bind(a);return n.effect=a,n}function Q9(e){e.effect.stop()}let Dn=!0;const Jm=[];function ro(){Jm.push(Dn),Dn=!1}function oo(){const e=Jm.pop();Dn=e===void 0?!0:e}function Zu(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const a=oa;oa=void 0;try{t()}finally{oa=a}}}let Ci=0,eM=class{constructor(t,a){this.sub=t,this.dep=a,this.version=a.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}};class xl{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0}track(t){if(!oa||!Dn||oa===this.computed)return;let a=this.activeLink;if(a===void 0||a.sub!==oa)a=this.activeLink=new eM(oa,this),oa.deps?(a.prevDep=oa.depsTail,oa.depsTail.nextDep=a,oa.depsTail=a):oa.deps=oa.depsTail=a,Xm(a);else if(a.version===-1&&(a.version=this.version,a.nextDep)){const n=a.nextDep;n.prevDep=a.prevDep,a.prevDep&&(a.prevDep.nextDep=n),a.prevDep=oa.depsTail,a.nextDep=void 0,oa.depsTail.nextDep=a,oa.depsTail=a,oa.deps===a&&(oa.deps=n)}return a}trigger(t){this.version++,Ci++,this.notify(t)}notify(t){Yc();try{for(let a=this.subs;a;a=a.prevSub)a.sub.notify()&&a.sub.dep.notify()}finally{Qc()}}}function Xm(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let n=t.deps;n;n=n.nextDep)Xm(n)}const a=e.dep.subs;a!==e&&(e.prevSub=a,a&&(a.nextSub=e)),e.dep.subs=e}}const W1=new WeakMap,Ao=Symbol(""),ic=Symbol(""),Ai=Symbol("");function ja(e,t,a){if(Dn&&oa){let n=W1.get(e);n||W1.set(e,n=new Map);let r=n.get(a);r||(n.set(a,r=new xl),r.map=n,r.key=a),r.track()}}function Mr(e,t,a,n,r,o){const s=W1.get(e);if(!s){Ci++;return}const i=l=>{l&&l.trigger()};if(Yc(),t==="clear")s.forEach(i);else{const l=st(e),c=l&&Gc(a);if(l&&a==="length"){const d=Number(n);s.forEach((u,h)=>{(h==="length"||h===Ai||!Bn(h)&&h>=d)&&i(u)})}else switch((a!==void 0||s.has(void 0))&&i(s.get(a)),c&&i(s.get(Ai)),t){case"add":l?c&&i(s.get("length")):(i(s.get(Ao)),ds(e)&&i(s.get(ic)));break;case"delete":l||(i(s.get(Ao)),ds(e)&&i(s.get(ic)));break;case"set":ds(e)&&i(s.get(Ao));break}}Qc()}function tM(e,t){const a=W1.get(e);return a&&a.get(t)}function Qo(e){const t=St(e);return t===e?t:(ja(t,"iterate",Ai),hn(e)?t:t.map(Ua))}function Cl(e){return ja(e=St(e),"iterate",Ai),e}const aM={__proto__:null,[Symbol.iterator](){return A2(this,Symbol.iterator,Ua)},concat(...e){return Qo(this).concat(...e.map(t=>st(t)?Qo(t):t))},entries(){return A2(this,"entries",e=>(e[1]=Ua(e[1]),e))},every(e,t){return mr(this,"every",e,t,void 0,arguments)},filter(e,t){return mr(this,"filter",e,t,a=>a.map(Ua),arguments)},find(e,t){return mr(this,"find",e,t,Ua,arguments)},findIndex(e,t){return mr(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return mr(this,"findLast",e,t,Ua,arguments)},findLastIndex(e,t){return mr(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return mr(this,"forEach",e,t,void 0,arguments)},includes(...e){return S2(this,"includes",e)},indexOf(...e){return S2(this,"indexOf",e)},join(e){return Qo(this).join(e)},lastIndexOf(...e){return S2(this,"lastIndexOf",e)},map(e,t){return mr(this,"map",e,t,void 0,arguments)},pop(){return qs(this,"pop")},push(...e){return qs(this,"push",e)},reduce(e,...t){return Ku(this,"reduce",e,t)},reduceRight(e,...t){return Ku(this,"reduceRight",e,t)},shift(){return qs(this,"shift")},some(e,t){return mr(this,"some",e,t,void 0,arguments)},splice(...e){return qs(this,"splice",e)},toReversed(){return Qo(this).toReversed()},toSorted(e){return Qo(this).toSorted(e)},toSpliced(...e){return Qo(this).toSpliced(...e)},unshift(...e){return qs(this,"unshift",e)},values(){return A2(this,"values",Ua)}};function A2(e,t,a){const n=Cl(e),r=n[t]();return n!==e&&!hn(e)&&(r._next=r.next,r.next=()=>{const o=r._next();return o.value&&(o.value=a(o.value)),o}),r}const nM=Array.prototype;function mr(e,t,a,n,r,o){const s=Cl(e),i=s!==e&&!hn(e),l=s[t];if(l!==nM[t]){const u=l.apply(e,o);return i?Ua(u):u}let c=a;s!==e&&(i?c=function(u,h){return a.call(this,Ua(u),h,e)}:a.length>2&&(c=function(u,h){return a.call(this,u,h,e)}));const d=l.call(s,c,n);return i&&r?r(d):d}function Ku(e,t,a,n){const r=Cl(e);let o=a;return r!==e&&(hn(e)?a.length>3&&(o=function(s,i,l){return a.call(this,s,i,l,e)}):o=function(s,i,l){return a.call(this,s,Ua(i),l,e)}),r[t](o,...n)}function S2(e,t,a){const n=St(e);ja(n,"iterate",Ai);const r=n[t](...a);return(r===-1||r===!1)&&$l(a[0])?(a[0]=St(a[0]),n[t](...a)):r}function qs(e,t,a=[]){ro(),Yc();const n=St(e)[t].apply(e,a);return Qc(),oo(),n}const rM=gl("__proto__,__v_isRef,__isVue"),Ym=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Bn));function oM(e){Bn(e)||(e=String(e));const t=St(this);return ja(t,"has",e),t.hasOwnProperty(e)}class Qm{constructor(t=!1,a=!1){this._isReadonly=t,this._isShallow=a}get(t,a,n){if(a==="__v_skip")return t.__v_skip;const r=this._isReadonly,o=this._isShallow;if(a==="__v_isReactive")return!r;if(a==="__v_isReadonly")return r;if(a==="__v_isShallow")return o;if(a==="__v_raw")return n===(r?o?ov:rv:o?nv:av).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(n)?t:void 0;const s=st(t);if(!r){let l;if(s&&(l=aM[a]))return l;if(a==="hasOwnProperty")return oM}const i=Reflect.get(t,a,ba(t)?t:n);return(Bn(a)?Ym.has(a):rM(a))||(r||ja(t,"get",a),o)?i:ba(i)?s&&Gc(a)?i:i.value:ea(i)?r?jt(i):Ri(i):i}}class ev extends Qm{constructor(t=!1){super(!1,t)}set(t,a,n,r){let o=t[a];if(!this._isShallow){const l=eo(o);if(!hn(n)&&!eo(n)&&(o=St(o),n=St(n)),!st(t)&&ba(o)&&!ba(n))return l?!1:(o.value=n,!0)}const s=st(t)&&Gc(a)?Number(a)<t.length:Kt(t,a),i=Reflect.set(t,a,n,ba(t)?t:r);return t===St(r)&&(s?Ja(n,o)&&Mr(t,"set",a,n):Mr(t,"add",a,n)),i}deleteProperty(t,a){const n=Kt(t,a);t[a];const r=Reflect.deleteProperty(t,a);return r&&n&&Mr(t,"delete",a,void 0),r}has(t,a){const n=Reflect.has(t,a);return(!Bn(a)||!Ym.has(a))&&ja(t,"has",a),n}ownKeys(t){return ja(t,"iterate",st(t)?"length":Ao),Reflect.ownKeys(t)}}class tv extends Qm{constructor(t=!1){super(!0,t)}set(t,a){return!0}deleteProperty(t,a){return!0}}const sM=new ev,iM=new tv,lM=new ev(!0),cM=new tv(!0),lc=e=>e,i1=e=>Reflect.getPrototypeOf(e);function dM(e,t,a){return function(...n){const r=this.__v_raw,o=St(r),s=ds(o),i=e==="entries"||e===Symbol.iterator&&s,l=e==="keys"&&s,c=r[e](...n),d=a?lc:t?cc:Ua;return!t&&ja(o,"iterate",l?ic:Ao),{next(){const{value:u,done:h}=c.next();return h?{value:u,done:h}:{value:i?[d(u[0]),d(u[1])]:d(u),done:h}},[Symbol.iterator](){return this}}}}function l1(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function uM(e,t){const a={get(r){const o=this.__v_raw,s=St(o),i=St(r);e||(Ja(r,i)&&ja(s,"get",r),ja(s,"get",i));const{has:l}=i1(s),c=t?lc:e?cc:Ua;if(l.call(s,r))return c(o.get(r));if(l.call(s,i))return c(o.get(i));o!==s&&o.get(r)},get size(){const r=this.__v_raw;return!e&&ja(St(r),"iterate",Ao),Reflect.get(r,"size",r)},has(r){const o=this.__v_raw,s=St(o),i=St(r);return e||(Ja(r,i)&&ja(s,"has",r),ja(s,"has",i)),r===i?o.has(r):o.has(r)||o.has(i)},forEach(r,o){const s=this,i=s.__v_raw,l=St(i),c=t?lc:e?cc:Ua;return!e&&ja(l,"iterate",Ao),i.forEach((d,u)=>r.call(o,c(d),c(u),s))}};return aa(a,e?{add:l1("add"),set:l1("set"),delete:l1("delete"),clear:l1("clear")}:{add(r){!t&&!hn(r)&&!eo(r)&&(r=St(r));const o=St(this);return i1(o).has.call(o,r)||(o.add(r),Mr(o,"add",r,r)),this},set(r,o){!t&&!hn(o)&&!eo(o)&&(o=St(o));const s=St(this),{has:i,get:l}=i1(s);let c=i.call(s,r);c||(r=St(r),c=i.call(s,r));const d=l.call(s,r);return s.set(r,o),c?Ja(o,d)&&Mr(s,"set",r,o):Mr(s,"add",r,o),this},delete(r){const o=St(this),{has:s,get:i}=i1(o);let l=s.call(o,r);l||(r=St(r),l=s.call(o,r)),i&&i.call(o,r);const c=o.delete(r);return l&&Mr(o,"delete",r,void 0),c},clear(){const r=St(this),o=r.size!==0,s=r.clear();return o&&Mr(r,"clear",void 0,void 0),s}}),["keys","values","entries",Symbol.iterator].forEach(r=>{a[r]=dM(r,e,t)}),a}function Al(e,t){const a=uM(e,t);return(n,r,o)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?n:Reflect.get(Kt(a,r)&&r in n?a:n,r,o)}const hM={get:Al(!1,!1)},pM={get:Al(!1,!0)},fM={get:Al(!0,!1)},mM={get:Al(!0,!0)},av=new WeakMap,nv=new WeakMap,rv=new WeakMap,ov=new WeakMap;function vM(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function gM(e){return e.__v_skip||!Object.isExtensible(e)?0:vM(R9(e))}function Ri(e){return eo(e)?e:Sl(e,!1,sM,hM,av)}function sv(e){return Sl(e,!1,lM,pM,nv)}function jt(e){return Sl(e,!0,iM,fM,rv)}function Fr(e){return Sl(e,!0,cM,mM,ov)}function Sl(e,t,a,n,r){if(!ea(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=r.get(e);if(o)return o;const s=gM(e);if(s===0)return e;const i=new Proxy(e,s===2?n:a);return r.set(e,i),i}function Gr(e){return eo(e)?Gr(e.__v_raw):!!(e&&e.__v_isReactive)}function eo(e){return!!(e&&e.__v_isReadonly)}function hn(e){return!!(e&&e.__v_isShallow)}function $l(e){return e?!!e.__v_raw:!1}function St(e){const t=e&&e.__v_raw;return t?St(t):e}function iv(e){return!Kt(e,"__v_skip")&&Object.isExtensible(e)&&Fm(e,"__v_skip",!0),e}const Ua=e=>ea(e)?Ri(e):e,cc=e=>ea(e)?jt(e):e;function ba(e){return e?e.__v_isRef===!0:!1}function ye(e){return lv(e,!1)}function $t(e){return lv(e,!0)}function lv(e,t){return ba(e)?e:new yM(e,t)}class yM{constructor(t,a){this.dep=new xl,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=a?t:St(t),this._value=a?t:Ua(t),this.__v_isShallow=a}get value(){return this.dep.track(),this._value}set value(t){const a=this._rawValue,n=this.__v_isShallow||hn(t)||eo(t);t=n?t:St(t),Ja(t,a)&&(this._rawValue=t,this._value=n?t:Ua(t),this.dep.trigger())}}function MM(e){e.dep&&e.dep.trigger()}function E(e){return ba(e)?e.value:e}function Pa(e){return gt(e)?e():E(e)}const _M={get:(e,t,a)=>t==="__v_raw"?e:E(Reflect.get(e,t,a)),set:(e,t,a,n)=>{const r=e[t];return ba(r)&&!ba(a)?(r.value=a,!0):Reflect.set(e,t,a,n)}};function t0(e){return Gr(e)?e:new Proxy(e,_M)}class bM{constructor(t){this.__v_isRef=!0,this._value=void 0;const a=this.dep=new xl,{get:n,set:r}=t(a.track.bind(a),a.trigger.bind(a));this._get=n,this._set=r}get value(){return this._value=this._get()}set value(t){this._set(t)}}function cv(e){return new bM(e)}function a0(e){const t=st(e)?new Array(e.length):{};for(const a in e)t[a]=dv(e,a);return t}class wM{constructor(t,a,n){this._object=t,this._key=a,this._defaultValue=n,this.__v_isRef=!0,this._value=void 0}get value(){const t=this._object[this._key];return this._value=t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return tM(St(this._object),this._key)}}class xM{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function mn(e,t,a){return ba(e)?e:gt(e)?new xM(e):ea(e)&&arguments.length>1?dv(e,t,a):ye(e)}function dv(e,t,a){const n=e[t];return ba(n)?n:new wM(e,t,a)}class CM{constructor(t,a,n){this.fn=t,this.setter=a,this._value=void 0,this.dep=new xl(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Ci-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!a,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&oa!==this)return Wm(this,!0),!0}get value(){const t=this.dep.track();return Gm(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function AM(e,t,a=!1){let n,r;return gt(e)?n=e:(n=e.get,r=e.set),new CM(n,r,a)}const SM={GET:"get",HAS:"has",ITERATE:"iterate"},$M={SET:"set",ADD:"add",DELETE:"delete",CLEAR:"clear"},c1={},Z1=new WeakMap;let jr;function EM(){return jr}function uv(e,t=!1,a=jr){if(a){let n=Z1.get(a);n||Z1.set(a,n=[]),n.push(e)}}function IM(e,t,a=Nt){const{immediate:n,deep:r,once:o,scheduler:s,augmentJob:i,call:l}=a,c=M=>r?M:hn(M)||r===!1||r===0?_r(M,1):_r(M);let d,u,h,f,m=!1,g=!1;if(ba(e)?(u=()=>e.value,m=hn(e)):Gr(e)?(u=()=>c(e),m=!0):st(e)?(g=!0,m=e.some(M=>Gr(M)||hn(M)),u=()=>e.map(M=>{if(ba(M))return M.value;if(Gr(M))return c(M);if(gt(M))return l?l(M,2):M()})):gt(e)?t?u=l?()=>l(e,2):e:u=()=>{if(h){ro();try{h()}finally{oo()}}const M=jr;jr=d;try{return l?l(e,3,[f]):e(f)}finally{jr=M}}:u=Cn,t&&r){const M=u,x=r===!0?1/0:r;u=()=>_r(M(),x)}const _=wl(),b=()=>{d.stop(),_&&_.active&&Zc(_.effects,d)};if(o&&t){const M=t;t=(...x)=>{M(...x),b()}}let v=g?new Array(e.length).fill(c1):c1;const y=M=>{if(!(!(d.flags&1)||!d.dirty&&!M))if(t){const x=d.run();if(r||m||(g?x.some((S,L)=>Ja(S,v[L])):Ja(x,v))){h&&h();const S=jr;jr=d;try{const L=[x,v===c1?void 0:g&&v[0]===c1?[]:v,f];l?l(t,3,L):t(...L),v=x}finally{jr=S}}}else d.run()};return i&&i(y),d=new xi(u),d.scheduler=s?()=>s(y,!1):y,f=M=>uv(M,!1,d),h=d.onStop=()=>{const M=Z1.get(d);if(M){if(l)l(M,4);else for(const x of M)x();Z1.delete(d)}},t?n?y(!0):v=d.run():s?s(y.bind(null,!0),!0):d.run(),b.pause=d.pause.bind(d),b.resume=d.resume.bind(d),b.stop=b,b}function _r(e,t=1/0,a){if(t<=0||!ea(e)||e.__v_skip||(a=a||new Set,a.has(e)))return e;if(a.add(e),t--,ba(e))_r(e.value,t,a);else if(st(e))for(let n=0;n<e.length;n++)_r(e[n],t,a);else if(Vo(e)||ds(e))e.forEach(n=>{_r(n,t,a)});else if(yl(e)){for(const n in e)_r(e[n],t,a);for(const n of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,n)&&_r(e[n],t,a)}return e}/**
15
+ **/let Ka;class Jc{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=Ka,!t&&Ka&&(this.index=(Ka.scopes||(Ka.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,a;if(this.scopes)for(t=0,a=this.scopes.length;t<a;t++)this.scopes[t].pause();for(t=0,a=this.effects.length;t<a;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,a;if(this.scopes)for(t=0,a=this.scopes.length;t<a;t++)this.scopes[t].resume();for(t=0,a=this.effects.length;t<a;t++)this.effects[t].resume()}}run(t){if(this._active){const a=Ka;try{return Ka=this,t()}finally{Ka=a}}}on(){Ka=this}off(){Ka=this.parent}stop(t){if(this._active){this._active=!1;let a,n;for(a=0,n=this.effects.length;a<n;a++)this.effects[a].stop();for(this.effects.length=0,a=0,n=this.cleanups.length;a<n;a++)this.cleanups[a]();if(this.cleanups.length=0,this.scopes){for(a=0,n=this.scopes.length;a<n;a++)this.scopes[a].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0}}}function J9(e){return new Jc(e)}function wl(){return Ka}function Xc(e,t=!1){Ka&&Ka.cleanups.push(e)}let oa;const C2=new WeakSet;class xi{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,Ka&&Ka.active&&Ka.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,C2.has(this)&&(C2.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Wm(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Zu(this),Zm(this);const t=oa,a=Bn;oa=this,Bn=!0;try{return this.fn()}finally{Km(this),oa=t,Bn=a,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)e0(t);this.deps=this.depsTail=void 0,Zu(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?C2.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){sc(this)&&this.run()}get dirty(){return sc(this)}}let qm=0,ci,di;function Wm(e,t=!1){if(e.flags|=8,t){e.next=di,di=e;return}e.next=ci,ci=e}function Yc(){qm++}function Qc(){if(--qm>0)return;if(di){let t=di;for(di=void 0;t;){const a=t.next;t.next=void 0,t.flags&=-9,t=a}}let e;for(;ci;){let t=ci;for(ci=void 0;t;){const a=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(n){e||(e=n)}t=a}}if(e)throw e}function Zm(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Km(e){let t,a=e.depsTail,n=a;for(;n;){const r=n.prevDep;n.version===-1?(n===a&&(a=r),e0(n),X9(n)):t=n,n.dep.activeLink=n.prevActiveLink,n.prevActiveLink=void 0,n=r}e.deps=t,e.depsTail=a}function sc(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Gm(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Gm(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Ci))return;e.globalVersion=Ci;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!sc(e)){e.flags&=-3;return}const a=oa,n=Bn;oa=e,Bn=!0;try{Zm(e);const r=e.fn(e._value);(t.version===0||Ja(r,e._value))&&(e._value=r,t.version++)}catch(r){throw t.version++,r}finally{oa=a,Bn=n,Km(e),e.flags&=-3}}function e0(e,t=!1){const{dep:a,prevSub:n,nextSub:r}=e;if(n&&(n.nextSub=r,e.prevSub=void 0),r&&(r.prevSub=n,e.nextSub=void 0),a.subs===e&&(a.subs=n,!n&&a.computed)){a.computed.flags&=-5;for(let o=a.computed.deps;o;o=o.nextDep)e0(o,!0)}!t&&!--a.sc&&a.map&&a.map.delete(a.key)}function X9(e){const{prevDep:t,nextDep:a}=e;t&&(t.nextDep=a,e.prevDep=void 0),a&&(a.prevDep=t,e.nextDep=void 0)}function Y9(e,t){e.effect instanceof xi&&(e=e.effect.fn);const a=new xi(e);t&&na(a,t);try{a.run()}catch(r){throw a.stop(),r}const n=a.run.bind(a);return n.effect=a,n}function Q9(e){e.effect.stop()}let Bn=!0;const Jm=[];function oo(){Jm.push(Bn),Bn=!1}function so(){const e=Jm.pop();Bn=e===void 0?!0:e}function Zu(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const a=oa;oa=void 0;try{t()}finally{oa=a}}}let Ci=0,eM=class{constructor(t,a){this.sub=t,this.dep=a,this.version=a.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}};class xl{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0}track(t){if(!oa||!Bn||oa===this.computed)return;let a=this.activeLink;if(a===void 0||a.sub!==oa)a=this.activeLink=new eM(oa,this),oa.deps?(a.prevDep=oa.depsTail,oa.depsTail.nextDep=a,oa.depsTail=a):oa.deps=oa.depsTail=a,Xm(a);else if(a.version===-1&&(a.version=this.version,a.nextDep)){const n=a.nextDep;n.prevDep=a.prevDep,a.prevDep&&(a.prevDep.nextDep=n),a.prevDep=oa.depsTail,a.nextDep=void 0,oa.depsTail.nextDep=a,oa.depsTail=a,oa.deps===a&&(oa.deps=n)}return a}trigger(t){this.version++,Ci++,this.notify(t)}notify(t){Yc();try{for(let a=this.subs;a;a=a.prevSub)a.sub.notify()&&a.sub.dep.notify()}finally{Qc()}}}function Xm(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let n=t.deps;n;n=n.nextDep)Xm(n)}const a=e.dep.subs;a!==e&&(e.prevSub=a,a&&(a.nextSub=e)),e.dep.subs=e}}const W1=new WeakMap,So=Symbol(""),ic=Symbol(""),Ai=Symbol("");function ja(e,t,a){if(Bn&&oa){let n=W1.get(e);n||W1.set(e,n=new Map);let r=n.get(a);r||(n.set(a,r=new xl),r.map=n,r.key=a),r.track()}}function _r(e,t,a,n,r,o){const s=W1.get(e);if(!s){Ci++;return}const i=l=>{l&&l.trigger()};if(Yc(),t==="clear")s.forEach(i);else{const l=st(e),c=l&&Gc(a);if(l&&a==="length"){const d=Number(n);s.forEach((u,h)=>{(h==="length"||h===Ai||!Fn(h)&&h>=d)&&i(u)})}else switch((a!==void 0||s.has(void 0))&&i(s.get(a)),c&&i(s.get(Ai)),t){case"add":l?c&&i(s.get("length")):(i(s.get(So)),us(e)&&i(s.get(ic)));break;case"delete":l||(i(s.get(So)),us(e)&&i(s.get(ic)));break;case"set":us(e)&&i(s.get(So));break}}Qc()}function tM(e,t){const a=W1.get(e);return a&&a.get(t)}function es(e){const t=St(e);return t===e?t:(ja(t,"iterate",Ai),hn(e)?t:t.map(Ua))}function Cl(e){return ja(e=St(e),"iterate",Ai),e}const aM={__proto__:null,[Symbol.iterator](){return A2(this,Symbol.iterator,Ua)},concat(...e){return es(this).concat(...e.map(t=>st(t)?es(t):t))},entries(){return A2(this,"entries",e=>(e[1]=Ua(e[1]),e))},every(e,t){return mr(this,"every",e,t,void 0,arguments)},filter(e,t){return mr(this,"filter",e,t,a=>a.map(Ua),arguments)},find(e,t){return mr(this,"find",e,t,Ua,arguments)},findIndex(e,t){return mr(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return mr(this,"findLast",e,t,Ua,arguments)},findLastIndex(e,t){return mr(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return mr(this,"forEach",e,t,void 0,arguments)},includes(...e){return S2(this,"includes",e)},indexOf(...e){return S2(this,"indexOf",e)},join(e){return es(this).join(e)},lastIndexOf(...e){return S2(this,"lastIndexOf",e)},map(e,t){return mr(this,"map",e,t,void 0,arguments)},pop(){return Ws(this,"pop")},push(...e){return Ws(this,"push",e)},reduce(e,...t){return Ku(this,"reduce",e,t)},reduceRight(e,...t){return Ku(this,"reduceRight",e,t)},shift(){return Ws(this,"shift")},some(e,t){return mr(this,"some",e,t,void 0,arguments)},splice(...e){return Ws(this,"splice",e)},toReversed(){return es(this).toReversed()},toSorted(e){return es(this).toSorted(e)},toSpliced(...e){return es(this).toSpliced(...e)},unshift(...e){return Ws(this,"unshift",e)},values(){return A2(this,"values",Ua)}};function A2(e,t,a){const n=Cl(e),r=n[t]();return n!==e&&!hn(e)&&(r._next=r.next,r.next=()=>{const o=r._next();return o.value&&(o.value=a(o.value)),o}),r}const nM=Array.prototype;function mr(e,t,a,n,r,o){const s=Cl(e),i=s!==e&&!hn(e),l=s[t];if(l!==nM[t]){const u=l.apply(e,o);return i?Ua(u):u}let c=a;s!==e&&(i?c=function(u,h){return a.call(this,Ua(u),h,e)}:a.length>2&&(c=function(u,h){return a.call(this,u,h,e)}));const d=l.call(s,c,n);return i&&r?r(d):d}function Ku(e,t,a,n){const r=Cl(e);let o=a;return r!==e&&(hn(e)?a.length>3&&(o=function(s,i,l){return a.call(this,s,i,l,e)}):o=function(s,i,l){return a.call(this,s,Ua(i),l,e)}),r[t](o,...n)}function S2(e,t,a){const n=St(e);ja(n,"iterate",Ai);const r=n[t](...a);return(r===-1||r===!1)&&$l(a[0])?(a[0]=St(a[0]),n[t](...a)):r}function Ws(e,t,a=[]){oo(),Yc();const n=St(e)[t].apply(e,a);return Qc(),so(),n}const rM=gl("__proto__,__v_isRef,__isVue"),Ym=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Fn));function oM(e){Fn(e)||(e=String(e));const t=St(this);return ja(t,"has",e),t.hasOwnProperty(e)}class Qm{constructor(t=!1,a=!1){this._isReadonly=t,this._isShallow=a}get(t,a,n){if(a==="__v_skip")return t.__v_skip;const r=this._isReadonly,o=this._isShallow;if(a==="__v_isReactive")return!r;if(a==="__v_isReadonly")return r;if(a==="__v_isShallow")return o;if(a==="__v_raw")return n===(r?o?ov:rv:o?nv:av).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(n)?t:void 0;const s=st(t);if(!r){let l;if(s&&(l=aM[a]))return l;if(a==="hasOwnProperty")return oM}const i=Reflect.get(t,a,ba(t)?t:n);return(Fn(a)?Ym.has(a):rM(a))||(r||ja(t,"get",a),o)?i:ba(i)?s&&Gc(a)?i:i.value:ta(i)?r?jt(i):Ri(i):i}}class ev extends Qm{constructor(t=!1){super(!1,t)}set(t,a,n,r){let o=t[a];if(!this._isShallow){const l=to(o);if(!hn(n)&&!to(n)&&(o=St(o),n=St(n)),!st(t)&&ba(o)&&!ba(n))return l?!1:(o.value=n,!0)}const s=st(t)&&Gc(a)?Number(a)<t.length:Kt(t,a),i=Reflect.set(t,a,n,ba(t)?t:r);return t===St(r)&&(s?Ja(n,o)&&_r(t,"set",a,n):_r(t,"add",a,n)),i}deleteProperty(t,a){const n=Kt(t,a);t[a];const r=Reflect.deleteProperty(t,a);return r&&n&&_r(t,"delete",a,void 0),r}has(t,a){const n=Reflect.has(t,a);return(!Fn(a)||!Ym.has(a))&&ja(t,"has",a),n}ownKeys(t){return ja(t,"iterate",st(t)?"length":So),Reflect.ownKeys(t)}}class tv extends Qm{constructor(t=!1){super(!0,t)}set(t,a){return!0}deleteProperty(t,a){return!0}}const sM=new ev,iM=new tv,lM=new ev(!0),cM=new tv(!0),lc=e=>e,i1=e=>Reflect.getPrototypeOf(e);function dM(e,t,a){return function(...n){const r=this.__v_raw,o=St(r),s=us(o),i=e==="entries"||e===Symbol.iterator&&s,l=e==="keys"&&s,c=r[e](...n),d=a?lc:t?cc:Ua;return!t&&ja(o,"iterate",l?ic:So),{next(){const{value:u,done:h}=c.next();return h?{value:u,done:h}:{value:i?[d(u[0]),d(u[1])]:d(u),done:h}},[Symbol.iterator](){return this}}}}function l1(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function uM(e,t){const a={get(r){const o=this.__v_raw,s=St(o),i=St(r);e||(Ja(r,i)&&ja(s,"get",r),ja(s,"get",i));const{has:l}=i1(s),c=t?lc:e?cc:Ua;if(l.call(s,r))return c(o.get(r));if(l.call(s,i))return c(o.get(i));o!==s&&o.get(r)},get size(){const r=this.__v_raw;return!e&&ja(St(r),"iterate",So),Reflect.get(r,"size",r)},has(r){const o=this.__v_raw,s=St(o),i=St(r);return e||(Ja(r,i)&&ja(s,"has",r),ja(s,"has",i)),r===i?o.has(r):o.has(r)||o.has(i)},forEach(r,o){const s=this,i=s.__v_raw,l=St(i),c=t?lc:e?cc:Ua;return!e&&ja(l,"iterate",So),i.forEach((d,u)=>r.call(o,c(d),c(u),s))}};return na(a,e?{add:l1("add"),set:l1("set"),delete:l1("delete"),clear:l1("clear")}:{add(r){!t&&!hn(r)&&!to(r)&&(r=St(r));const o=St(this);return i1(o).has.call(o,r)||(o.add(r),_r(o,"add",r,r)),this},set(r,o){!t&&!hn(o)&&!to(o)&&(o=St(o));const s=St(this),{has:i,get:l}=i1(s);let c=i.call(s,r);c||(r=St(r),c=i.call(s,r));const d=l.call(s,r);return s.set(r,o),c?Ja(o,d)&&_r(s,"set",r,o):_r(s,"add",r,o),this},delete(r){const o=St(this),{has:s,get:i}=i1(o);let l=s.call(o,r);l||(r=St(r),l=s.call(o,r)),i&&i.call(o,r);const c=o.delete(r);return l&&_r(o,"delete",r,void 0),c},clear(){const r=St(this),o=r.size!==0,s=r.clear();return o&&_r(r,"clear",void 0,void 0),s}}),["keys","values","entries",Symbol.iterator].forEach(r=>{a[r]=dM(r,e,t)}),a}function Al(e,t){const a=uM(e,t);return(n,r,o)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?n:Reflect.get(Kt(a,r)&&r in n?a:n,r,o)}const hM={get:Al(!1,!1)},pM={get:Al(!1,!0)},fM={get:Al(!0,!1)},mM={get:Al(!0,!0)},av=new WeakMap,nv=new WeakMap,rv=new WeakMap,ov=new WeakMap;function vM(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function gM(e){return e.__v_skip||!Object.isExtensible(e)?0:vM(R9(e))}function Ri(e){return to(e)?e:Sl(e,!1,sM,hM,av)}function sv(e){return Sl(e,!1,lM,pM,nv)}function jt(e){return Sl(e,!0,iM,fM,rv)}function jr(e){return Sl(e,!0,cM,mM,ov)}function Sl(e,t,a,n,r){if(!ta(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=r.get(e);if(o)return o;const s=gM(e);if(s===0)return e;const i=new Proxy(e,s===2?n:a);return r.set(e,i),i}function Jr(e){return to(e)?Jr(e.__v_raw):!!(e&&e.__v_isReactive)}function to(e){return!!(e&&e.__v_isReadonly)}function hn(e){return!!(e&&e.__v_isShallow)}function $l(e){return e?!!e.__v_raw:!1}function St(e){const t=e&&e.__v_raw;return t?St(t):e}function iv(e){return!Kt(e,"__v_skip")&&Object.isExtensible(e)&&Fm(e,"__v_skip",!0),e}const Ua=e=>ta(e)?Ri(e):e,cc=e=>ta(e)?jt(e):e;function ba(e){return e?e.__v_isRef===!0:!1}function ye(e){return lv(e,!1)}function $t(e){return lv(e,!0)}function lv(e,t){return ba(e)?e:new yM(e,t)}class yM{constructor(t,a){this.dep=new xl,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=a?t:St(t),this._value=a?t:Ua(t),this.__v_isShallow=a}get value(){return this.dep.track(),this._value}set value(t){const a=this._rawValue,n=this.__v_isShallow||hn(t)||to(t);t=n?t:St(t),Ja(t,a)&&(this._rawValue=t,this._value=n?t:Ua(t),this.dep.trigger())}}function MM(e){e.dep&&e.dep.trigger()}function E(e){return ba(e)?e.value:e}function Pa(e){return gt(e)?e():E(e)}const _M={get:(e,t,a)=>t==="__v_raw"?e:E(Reflect.get(e,t,a)),set:(e,t,a,n)=>{const r=e[t];return ba(r)&&!ba(a)?(r.value=a,!0):Reflect.set(e,t,a,n)}};function t0(e){return Jr(e)?e:new Proxy(e,_M)}class bM{constructor(t){this.__v_isRef=!0,this._value=void 0;const a=this.dep=new xl,{get:n,set:r}=t(a.track.bind(a),a.trigger.bind(a));this._get=n,this._set=r}get value(){return this._value=this._get()}set value(t){this._set(t)}}function cv(e){return new bM(e)}function a0(e){const t=st(e)?new Array(e.length):{};for(const a in e)t[a]=dv(e,a);return t}class wM{constructor(t,a,n){this._object=t,this._key=a,this._defaultValue=n,this.__v_isRef=!0,this._value=void 0}get value(){const t=this._object[this._key];return this._value=t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return tM(St(this._object),this._key)}}class xM{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function mn(e,t,a){return ba(e)?e:gt(e)?new xM(e):ta(e)&&arguments.length>1?dv(e,t,a):ye(e)}function dv(e,t,a){const n=e[t];return ba(n)?n:new wM(e,t,a)}class CM{constructor(t,a,n){this.fn=t,this.setter=a,this._value=void 0,this.dep=new xl(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Ci-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!a,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&oa!==this)return Wm(this,!0),!0}get value(){const t=this.dep.track();return Gm(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function AM(e,t,a=!1){let n,r;return gt(e)?n=e:(n=e.get,r=e.set),new CM(n,r,a)}const SM={GET:"get",HAS:"has",ITERATE:"iterate"},$M={SET:"set",ADD:"add",DELETE:"delete",CLEAR:"clear"},c1={},Z1=new WeakMap;let Ur;function EM(){return Ur}function uv(e,t=!1,a=Ur){if(a){let n=Z1.get(a);n||Z1.set(a,n=[]),n.push(e)}}function IM(e,t,a=Nt){const{immediate:n,deep:r,once:o,scheduler:s,augmentJob:i,call:l}=a,c=M=>r?M:hn(M)||r===!1||r===0?br(M,1):br(M);let d,u,h,f,m=!1,g=!1;if(ba(e)?(u=()=>e.value,m=hn(e)):Jr(e)?(u=()=>c(e),m=!0):st(e)?(g=!0,m=e.some(M=>Jr(M)||hn(M)),u=()=>e.map(M=>{if(ba(M))return M.value;if(Jr(M))return c(M);if(gt(M))return l?l(M,2):M()})):gt(e)?t?u=l?()=>l(e,2):e:u=()=>{if(h){oo();try{h()}finally{so()}}const M=Ur;Ur=d;try{return l?l(e,3,[f]):e(f)}finally{Ur=M}}:u=Cn,t&&r){const M=u,x=r===!0?1/0:r;u=()=>br(M(),x)}const _=wl(),b=()=>{d.stop(),_&&_.active&&Zc(_.effects,d)};if(o&&t){const M=t;t=(...x)=>{M(...x),b()}}let v=g?new Array(e.length).fill(c1):c1;const y=M=>{if(!(!(d.flags&1)||!d.dirty&&!M))if(t){const x=d.run();if(r||m||(g?x.some((S,L)=>Ja(S,v[L])):Ja(x,v))){h&&h();const S=Ur;Ur=d;try{const L=[x,v===c1?void 0:g&&v[0]===c1?[]:v,f];l?l(t,3,L):t(...L),v=x}finally{Ur=S}}}else d.run()};return i&&i(y),d=new xi(u),d.scheduler=s?()=>s(y,!1):y,f=M=>uv(M,!1,d),h=d.onStop=()=>{const M=Z1.get(d);if(M){if(l)l(M,4);else for(const x of M)x();Z1.delete(d)}},t?n?y(!0):v=d.run():s?s(y.bind(null,!0),!0):d.run(),b.pause=d.pause.bind(d),b.resume=d.resume.bind(d),b.stop=b,b}function br(e,t=1/0,a){if(t<=0||!ta(e)||e.__v_skip||(a=a||new Set,a.has(e)))return e;if(a.add(e),t--,ba(e))br(e.value,t,a);else if(st(e))for(let n=0;n<e.length;n++)br(e[n],t,a);else if(Oo(e)||us(e))e.forEach(n=>{br(n,t,a)});else if(yl(e)){for(const n in e)br(e[n],t,a);for(const n of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,n)&&br(e[n],t,a)}return e}/**
16
16
  * @vue/runtime-core v3.5.13
17
17
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
18
18
  * @license MIT
19
- **/const hv=[];function kM(e){hv.push(e)}function TM(){hv.pop()}function PM(e,t){}const LM={SETUP_FUNCTION:0,0:"SETUP_FUNCTION",RENDER_FUNCTION:1,1:"RENDER_FUNCTION",NATIVE_EVENT_HANDLER:5,5:"NATIVE_EVENT_HANDLER",COMPONENT_EVENT_HANDLER:6,6:"COMPONENT_EVENT_HANDLER",VNODE_HOOK:7,7:"VNODE_HOOK",DIRECTIVE_HOOK:8,8:"DIRECTIVE_HOOK",TRANSITION_HOOK:9,9:"TRANSITION_HOOK",APP_ERROR_HANDLER:10,10:"APP_ERROR_HANDLER",APP_WARN_HANDLER:11,11:"APP_WARN_HANDLER",FUNCTION_REF:12,12:"FUNCTION_REF",ASYNC_COMPONENT_LOADER:13,13:"ASYNC_COMPONENT_LOADER",SCHEDULER:14,14:"SCHEDULER",COMPONENT_UPDATE:15,15:"COMPONENT_UPDATE",APP_UNMOUNT_CLEANUP:16,16:"APP_UNMOUNT_CLEANUP"},VM={sp:"serverPrefetch hook",bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush",15:"component update",16:"app unmount cleanup function"};function Is(e,t,a,n){try{return n?e(...n):e()}catch(r){Oo(r,t,a)}}function $n(e,t,a,n){if(gt(e)){const r=Is(e,t,a,n);return r&&Kc(r)&&r.catch(o=>{Oo(o,t,a)}),r}if(st(e)){const r=[];for(let o=0;o<e.length;o++)r.push($n(e[o],t,a,n));return r}}function Oo(e,t,a,n=!0){const r=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||Nt;if(t){let i=t.parent;const l=t.proxy,c=`https://vuejs.org/error-reference/#runtime-${a}`;for(;i;){const d=i.ec;if(d){for(let u=0;u<d.length;u++)if(d[u](e,l,c)===!1)return}i=i.parent}if(o){ro(),Is(o,null,10,[e,l,c]),oo();return}}OM(e,a,r,n,s)}function OM(e,t,a,n=!0,r=!1){if(r)throw e;console.error(e)}const Xa=[];let Jn=-1;const ps=[];let Ur=null,ns=0;const pv=Promise.resolve();let K1=null;function qa(e){const t=K1||pv;return e?t.then(this?e.bind(this):e):t}function HM(e){let t=Jn+1,a=Xa.length;for(;t<a;){const n=t+a>>>1,r=Xa[n],o=$i(r);o<e||o===e&&r.flags&2?t=n+1:a=n}return t}function n0(e){if(!(e.flags&1)){const t=$i(e),a=Xa[Xa.length-1];!a||!(e.flags&2)&&t>=$i(a)?Xa.push(e):Xa.splice(HM(t),0,e),e.flags|=1,fv()}}function fv(){K1||(K1=pv.then(mv))}function Si(e){st(e)?ps.push(...e):Ur&&e.id===-1?Ur.splice(ns+1,0,e):e.flags&1||(ps.push(e),e.flags|=1),fv()}function Gu(e,t,a=Jn+1){for(;a<Xa.length;a++){const n=Xa[a];if(n&&n.flags&2){if(e&&n.id!==e.uid)continue;Xa.splice(a,1),a--,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function G1(e){if(ps.length){const t=[...new Set(ps)].sort((a,n)=>$i(a)-$i(n));if(ps.length=0,Ur){Ur.push(...t);return}for(Ur=t,ns=0;ns<Ur.length;ns++){const a=Ur[ns];a.flags&4&&(a.flags&=-2),a.flags&8||a(),a.flags&=-2}Ur=null,ns=0}}const $i=e=>e.id==null?e.flags&2?-1:1/0:e.id;function mv(e){try{for(Jn=0;Jn<Xa.length;Jn++){const t=Xa[Jn];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),Is(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Jn<Xa.length;Jn++){const t=Xa[Jn];t&&(t.flags&=-2)}Jn=-1,Xa.length=0,G1(),K1=null,(Xa.length||ps.length)&&mv()}}let rs,d1=[];function vv(e,t){var a,n;rs=e,rs?(rs.enabled=!0,d1.forEach(({event:r,args:o})=>rs.emit(r,...o)),d1=[]):typeof window<"u"&&window.HTMLElement&&!((n=(a=window.navigator)==null?void 0:a.userAgent)!=null&&n.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(o=>{vv(o,t)}),setTimeout(()=>{rs||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,d1=[])},3e3)):d1=[]}let Ea=null,El=null;function Ei(e){const t=Ea;return Ea=e,El=e&&e.type.__scopeId||null,t}function RM(e){El=e}function NM(){El=null}const DM=e=>Xe;function Xe(e,t=Ea,a){if(!t||e._n)return e;const n=(...r)=>{n._d&&gc(-1);const o=Ei(t);let s;try{s=e(...r)}finally{Ei(o),n._d&&gc(1)}return s};return n._n=!0,n._c=!0,n._d=!0,n}function Ya(e,t){if(Ea===null)return e;const a=Fi(Ea),n=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[o,s,i,l=Nt]=t[r];o&&(gt(o)&&(o={mounted:o,updated:o}),o.deep&&_r(s),n.push({dir:o,instance:a,value:s,oldValue:void 0,arg:i,modifiers:l}))}return e}function Xn(e,t,a,n){const r=e.dirs,o=t&&t.dirs;for(let s=0;s<r.length;s++){const i=r[s];o&&(i.oldValue=o[s].value);let l=i.dir[n];l&&(ro(),$n(l,a,8,[e.el,i,e,t]),oo())}}const gv=Symbol("_vte"),yv=e=>e.__isTeleport,ui=e=>e&&(e.disabled||e.disabled===""),Ju=e=>e&&(e.defer||e.defer===""),Xu=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Yu=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,dc=(e,t)=>{const a=e&&e.to;return sa(a)?t?t(a):null:a},Mv={name:"Teleport",__isTeleport:!0,process(e,t,a,n,r,o,s,i,l,c){const{mc:d,pc:u,pbc:h,o:{insert:f,querySelector:m,createText:g,createComment:_}}=c,b=ui(t.props);let{shapeFlag:v,children:y,dynamicChildren:M}=t;if(e==null){const x=t.el=g(""),S=t.anchor=g("");f(x,a,n),f(S,a,n);const L=(te,J)=>{v&16&&(r&&r.isCE&&(r.ce._teleportTarget=te),d(y,te,J,r,o,s,i,l))},F=()=>{const te=t.target=dc(t.props,m),J=bv(te,t,g,f);te&&(s!=="svg"&&Xu(te)?s="svg":s!=="mathml"&&Yu(te)&&(s="mathml"),b||(L(te,J),V1(t,!1)))};b&&(L(a,S),V1(t,!0)),Ju(t.props)?Aa(()=>{F(),t.el.__isMounted=!0},o):F()}else{if(Ju(t.props)&&!e.el.__isMounted){Aa(()=>{Mv.process(e,t,a,n,r,o,s,i,l,c),delete e.el.__isMounted},o);return}t.el=e.el,t.targetStart=e.targetStart;const x=t.anchor=e.anchor,S=t.target=e.target,L=t.targetAnchor=e.targetAnchor,F=ui(e.props),te=F?a:S,J=F?x:L;if(s==="svg"||Xu(S)?s="svg":(s==="mathml"||Yu(S))&&(s="mathml"),M?(h(e.dynamicChildren,M,te,r,o,s,i),p0(e,t,!0)):l||u(e,t,te,J,r,o,s,i,!1),b)F?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):u1(t,a,x,c,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const be=t.target=dc(t.props,m);be&&u1(t,be,null,c,0)}else F&&u1(t,S,L,c,1);V1(t,b)}},remove(e,t,a,{um:n,o:{remove:r}},o){const{shapeFlag:s,children:i,anchor:l,targetStart:c,targetAnchor:d,target:u,props:h}=e;if(u&&(r(c),r(d)),o&&r(l),s&16){const f=o||!ui(h);for(let m=0;m<i.length;m++){const g=i[m];n(g,t,a,f,!!g.dynamicChildren)}}},move:u1,hydrate:BM};function u1(e,t,a,{o:{insert:n},m:r},o=2){o===0&&n(e.targetAnchor,t,a);const{el:s,anchor:i,shapeFlag:l,children:c,props:d}=e,u=o===2;if(u&&n(s,t,a),(!u||ui(d))&&l&16)for(let h=0;h<c.length;h++)r(c[h],t,a,2);u&&n(i,t,a)}function BM(e,t,a,n,r,o,{o:{nextSibling:s,parentNode:i,querySelector:l,insert:c,createText:d}},u){const h=t.target=dc(t.props,l);if(h){const f=ui(t.props),m=h._lpa||h.firstChild;if(t.shapeFlag&16)if(f)t.anchor=u(s(e),t,i(e),a,n,r,o),t.targetStart=m,t.targetAnchor=m&&s(m);else{t.anchor=s(e);let g=m;for(;g;){if(g&&g.nodeType===8){if(g.data==="teleport start anchor")t.targetStart=g;else if(g.data==="teleport anchor"){t.targetAnchor=g,h._lpa=t.targetAnchor&&s(t.targetAnchor);break}}g=s(g)}t.targetAnchor||bv(h,t,d,c),u(m&&s(m),t,h,a,n,r,o)}V1(t,f)}return t.anchor&&s(t.anchor)}const _v=Mv;function V1(e,t){const a=e.ctx;if(a&&a.ut){let n,r;for(t?(n=e.el,r=e.anchor):(n=e.targetStart,r=e.targetAnchor);n&&n!==r;)n.nodeType===1&&n.setAttribute("data-v-owner",a.uid),n=n.nextSibling;a.ut()}}function bv(e,t,a,n){const r=t.targetStart=a(""),o=t.targetAnchor=a("");return r[gv]=o,e&&(n(r,e),n(o,e)),o}const zr=Symbol("_leaveCb"),h1=Symbol("_enterCb");function r0(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return ia(()=>{e.isMounted=!0}),Ir(()=>{e.isUnmounting=!0}),e}const Mn=[Function,Array],o0={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Mn,onEnter:Mn,onAfterEnter:Mn,onEnterCancelled:Mn,onBeforeLeave:Mn,onLeave:Mn,onAfterLeave:Mn,onLeaveCancelled:Mn,onBeforeAppear:Mn,onAppear:Mn,onAfterAppear:Mn,onAppearCancelled:Mn},wv=e=>{const t=e.subTree;return t.component?wv(t.component):t},FM={name:"BaseTransition",props:o0,setup(e,{slots:t}){const a=gn(),n=r0();return()=>{const r=t.default&&Il(t.default(),!0);if(!r||!r.length)return;const o=xv(r),s=St(e),{mode:i}=s;if(n.isLeaving)return $2(o);const l=Qu(o);if(!l)return $2(o);let c=ys(l,s,n,a,u=>c=u);l.type!==_a&&Cr(l,c);let d=a.subTree&&Qu(a.subTree);if(d&&d.type!==_a&&!Rn(l,d)&&wv(a).type!==_a){let u=ys(d,s,n,a);if(Cr(d,u),i==="out-in"&&l.type!==_a)return n.isLeaving=!0,u.afterLeave=()=>{n.isLeaving=!1,a.job.flags&8||a.update(),delete u.afterLeave,d=void 0},$2(o);i==="in-out"&&l.type!==_a?u.delayLeave=(h,f,m)=>{const g=Av(n,d);g[String(d.key)]=d,h[zr]=()=>{f(),h[zr]=void 0,delete c.delayedLeave,d=void 0},c.delayedLeave=()=>{m(),delete c.delayedLeave,d=void 0}}:d=void 0}else d&&(d=void 0);return o}}};function xv(e){let t=e[0];if(e.length>1){for(const a of e)if(a.type!==_a){t=a;break}}return t}const Cv=FM;function Av(e,t){const{leavingVNodes:a}=e;let n=a.get(t.type);return n||(n=Object.create(null),a.set(t.type,n)),n}function ys(e,t,a,n,r){const{appear:o,mode:s,persisted:i=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:d,onEnterCancelled:u,onBeforeLeave:h,onLeave:f,onAfterLeave:m,onLeaveCancelled:g,onBeforeAppear:_,onAppear:b,onAfterAppear:v,onAppearCancelled:y}=t,M=String(e.key),x=Av(a,e),S=(te,J)=>{te&&$n(te,n,9,J)},L=(te,J)=>{const be=J[1];S(te,J),st(te)?te.every(oe=>oe.length<=1)&&be():te.length<=1&&be()},F={mode:s,persisted:i,beforeEnter(te){let J=l;if(!a.isMounted)if(o)J=_||l;else return;te[zr]&&te[zr](!0);const be=x[M];be&&Rn(e,be)&&be.el[zr]&&be.el[zr](),S(J,[te])},enter(te){let J=c,be=d,oe=u;if(!a.isMounted)if(o)J=b||c,be=v||d,oe=y||u;else return;let Te=!1;const Ue=te[h1]=Ze=>{Te||(Te=!0,Ze?S(oe,[te]):S(be,[te]),F.delayedLeave&&F.delayedLeave(),te[h1]=void 0)};J?L(J,[te,Ue]):Ue()},leave(te,J){const be=String(e.key);if(te[h1]&&te[h1](!0),a.isUnmounting)return J();S(h,[te]);let oe=!1;const Te=te[zr]=Ue=>{oe||(oe=!0,J(),Ue?S(g,[te]):S(m,[te]),te[zr]=void 0,x[be]===e&&delete x[be])};x[be]=e,f?L(f,[te,Te]):Te()},clone(te){const J=ys(te,t,a,n,r);return r&&r(J),J}};return F}function $2(e){if(Ni(e))return e=nr(e),e.children=null,e}function Qu(e){if(!Ni(e))return yv(e.type)&&e.children?xv(e.children):e;const{shapeFlag:t,children:a}=e;if(a){if(t&16)return a[0];if(t&32&&gt(a.default))return a.default()}}function Cr(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Cr(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Il(e,t=!1,a){let n=[],r=0;for(let o=0;o<e.length;o++){let s=e[o];const i=a==null?s.key:String(a)+String(s.key!=null?s.key:o);s.type===Je?(s.patchFlag&128&&r++,n=n.concat(Il(s.children,t,i))):(t||s.type!==_a)&&n.push(i!=null?nr(s,{key:i}):s)}if(r>1)for(let o=0;o<n.length;o++)n[o].patchFlag=-2;return n}/*! #__NO_SIDE_EFFECTS__ */function $e(e,t){return gt(e)?aa({name:e.name},t,{setup:e}):e}function Sv(){const e=gn();return e?(e.appContext.config.idPrefix||"v")+"-"+e.ids[0]+e.ids[1]++:""}function s0(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function pt(e){const t=gn(),a=$t(null);if(t){const r=t.refs===Nt?t.refs={}:t.refs;Object.defineProperty(r,e,{enumerable:!0,get:()=>a.value,set:o=>a.value=o})}return a}function Ii(e,t,a,n,r=!1){if(st(e)){e.forEach((m,g)=>Ii(m,t&&(st(t)?t[g]:t),a,n,r));return}if(Jr(n)&&!r){n.shapeFlag&512&&n.type.__asyncResolved&&n.component.subTree.component&&Ii(e,t,a,n.component.subTree);return}const o=n.shapeFlag&4?Fi(n.component):n.el,s=r?null:o,{i,r:l}=e,c=t&&t.r,d=i.refs===Nt?i.refs={}:i.refs,u=i.setupState,h=St(u),f=u===Nt?()=>!1:m=>Kt(h,m);if(c!=null&&c!==l&&(sa(c)?(d[c]=null,f(c)&&(u[c]=null)):ba(c)&&(c.value=null)),gt(l))Is(l,i,12,[s,d]);else{const m=sa(l),g=ba(l);if(m||g){const _=()=>{if(e.f){const b=m?f(l)?u[l]:d[l]:l.value;r?st(b)&&Zc(b,o):st(b)?b.includes(o)||b.push(o):m?(d[l]=[o],f(l)&&(u[l]=d[l])):(l.value=[o],e.k&&(d[e.k]=l.value))}else m?(d[l]=s,f(l)&&(u[l]=s)):g&&(l.value=s,e.k&&(d[e.k]=s))};s?(_.id=-1,Aa(_,a)):_()}}}let eh=!1;const es=()=>{eh||(console.error("Hydration completed but contains mismatches."),eh=!0)},jM=e=>e.namespaceURI.includes("svg")&&e.tagName!=="foreignObject",UM=e=>e.namespaceURI.includes("MathML"),p1=e=>{if(e.nodeType===1){if(jM(e))return"svg";if(UM(e))return"mathml"}},ss=e=>e.nodeType===8;function zM(e){const{mt:t,p:a,o:{patchProp:n,createText:r,nextSibling:o,parentNode:s,remove:i,insert:l,createComment:c}}=e,d=(y,M)=>{if(!M.hasChildNodes()){a(null,y,M),G1(),M._vnode=y;return}u(M.firstChild,y,null,null,null),G1(),M._vnode=y},u=(y,M,x,S,L,F=!1)=>{F=F||!!M.dynamicChildren;const te=ss(y)&&y.data==="[",J=()=>g(y,M,x,S,L,te),{type:be,ref:oe,shapeFlag:Te,patchFlag:Ue}=M;let Ze=y.nodeType;M.el=y,Ue===-2&&(F=!1,M.dynamicChildren=null);let Me=null;switch(be){case Xr:Ze!==3?M.children===""?(l(M.el=r(""),s(y),y),Me=y):Me=J():(y.data!==M.children&&(es(),y.data=M.children),Me=o(y));break;case _a:v(y)?(Me=o(y),b(M.el=y.content.firstChild,y,x)):Ze!==8||te?Me=J():Me=o(y);break;case $o:if(te&&(y=o(y),Ze=y.nodeType),Ze===1||Ze===3){Me=y;const ee=!M.children.length;for(let j=0;j<M.staticCount;j++)ee&&(M.children+=Me.nodeType===1?Me.outerHTML:Me.data),j===M.staticCount-1&&(M.anchor=Me),Me=o(Me);return te?o(Me):Me}else J();break;case Je:te?Me=m(y,M,x,S,L,F):Me=J();break;default:if(Te&1)(Ze!==1||M.type.toLowerCase()!==y.tagName.toLowerCase())&&!v(y)?Me=J():Me=h(y,M,x,S,L,F);else if(Te&6){M.slotScopeIds=L;const ee=s(y);if(te?Me=_(y):ss(y)&&y.data==="teleport start"?Me=_(y,y.data,"teleport end"):Me=o(y),t(M,ee,null,x,S,p1(ee),F),Jr(M)&&!M.type.__asyncResolved){let j;te?(j=Ce(Je),j.anchor=Me?Me.previousSibling:ee.lastChild):j=y.nodeType===3?pa(""):Ce("div"),j.el=y,M.component.subTree=j}}else Te&64?Ze!==8?Me=J():Me=M.type.hydrate(y,M,x,S,L,F,e,f):Te&128&&(Me=M.type.hydrate(y,M,x,S,p1(s(y)),L,F,e,u))}return oe!=null&&Ii(oe,null,S,M),Me},h=(y,M,x,S,L,F)=>{F=F||!!M.dynamicChildren;const{type:te,props:J,patchFlag:be,shapeFlag:oe,dirs:Te,transition:Ue}=M,Ze=te==="input"||te==="option";if(Ze||be!==-1){Te&&Xn(M,null,x,"created");let Me=!1;if(v(y)){Me=Qv(null,Ue)&&x&&x.vnode.props&&x.vnode.props.appear;const j=y.content.firstChild;Me&&Ue.beforeEnter(j),b(j,y,x),M.el=y=j}if(oe&16&&!(J&&(J.innerHTML||J.textContent))){let j=f(y.firstChild,M,y,x,S,L,F);for(;j;){f1(y,1)||es();const K=j;j=j.nextSibling,i(K)}}else if(oe&8){let j=M.children;j[0]===`
20
- `&&(y.tagName==="PRE"||y.tagName==="TEXTAREA")&&(j=j.slice(1)),y.textContent!==j&&(f1(y,0)||es(),y.textContent=M.children)}if(J){if(Ze||!F||be&48){const j=y.tagName.includes("-");for(const K in J)(Ze&&(K.endsWith("value")||K==="indeterminate")||Oi(K)&&!us(K)||K[0]==="."||j)&&n(y,K,null,J[K],void 0,x)}else if(J.onClick)n(y,"onClick",null,J.onClick,void 0,x);else if(be&4&&Gr(J.style))for(const j in J.style)J.style[j]}let ee;(ee=J&&J.onVnodeBeforeMount)&&tn(ee,x,M),Te&&Xn(M,null,x,"beforeMount"),((ee=J&&J.onVnodeMounted)||Te||Me)&&l3(()=>{ee&&tn(ee,x,M),Me&&Ue.enter(y),Te&&Xn(M,null,x,"mounted")},S)}return y.nextSibling},f=(y,M,x,S,L,F,te)=>{te=te||!!M.dynamicChildren;const J=M.children,be=J.length;for(let oe=0;oe<be;oe++){const Te=te?J[oe]:J[oe]=nn(J[oe]),Ue=Te.type===Xr;y?(Ue&&!te&&oe+1<be&&nn(J[oe+1]).type===Xr&&(l(r(y.data.slice(Te.children.length)),x,o(y)),y.data=Te.children),y=u(y,Te,S,L,F,te)):Ue&&!Te.children?l(Te.el=r(""),x):(f1(x,1)||es(),a(null,Te,x,null,S,L,p1(x),F))}return y},m=(y,M,x,S,L,F)=>{const{slotScopeIds:te}=M;te&&(L=L?L.concat(te):te);const J=s(y),be=f(o(y),M,J,x,S,L,F);return be&&ss(be)&&be.data==="]"?o(M.anchor=be):(es(),l(M.anchor=c("]"),J,be),be)},g=(y,M,x,S,L,F)=>{if(f1(y.parentElement,1)||es(),M.el=null,F){const be=_(y);for(;;){const oe=o(y);if(oe&&oe!==be)i(oe);else break}}const te=o(y),J=s(y);return i(y),a(null,M,J,te,x,S,p1(J),L),x&&(x.vnode.el=M.el,Ll(x,M.el)),te},_=(y,M="[",x="]")=>{let S=0;for(;y;)if(y=o(y),y&&ss(y)&&(y.data===M&&S++,y.data===x)){if(S===0)return o(y);S--}return y},b=(y,M,x)=>{const S=M.parentNode;S&&S.replaceChild(y,M);let L=x;for(;L;)L.vnode.el===M&&(L.vnode.el=L.subTree.el=y),L=L.parent},v=y=>y.nodeType===1&&y.tagName==="TEMPLATE";return[d,u]}const th="data-allow-mismatch",qM={0:"text",1:"children",2:"class",3:"style",4:"attribute"};function f1(e,t){if(t===0||t===1)for(;e&&!e.hasAttribute(th);)e=e.parentElement;const a=e&&e.getAttribute(th);if(a==null)return!1;if(a==="")return!0;{const n=a.split(",");return t===0&&n.includes("children")?!0:a.split(",").includes(qM[t])}}const WM=_l().requestIdleCallback||(e=>setTimeout(e,1)),ZM=_l().cancelIdleCallback||(e=>clearTimeout(e)),KM=(e=1e4)=>t=>{const a=WM(t,{timeout:e});return()=>ZM(a)};function GM(e){const{top:t,left:a,bottom:n,right:r}=e.getBoundingClientRect(),{innerHeight:o,innerWidth:s}=window;return(t>0&&t<o||n>0&&n<o)&&(a>0&&a<s||r>0&&r<s)}const JM=e=>(t,a)=>{const n=new IntersectionObserver(r=>{for(const o of r)if(o.isIntersecting){n.disconnect(),t();break}},e);return a(r=>{if(r instanceof Element){if(GM(r))return t(),n.disconnect(),!1;n.observe(r)}}),()=>n.disconnect()},XM=e=>t=>{if(e){const a=matchMedia(e);if(a.matches)t();else return a.addEventListener("change",t,{once:!0}),()=>a.removeEventListener("change",t)}},YM=(e=[])=>(t,a)=>{sa(e)&&(e=[e]);let n=!1;const r=s=>{n||(n=!0,o(),t(),s.target.dispatchEvent(new s.constructor(s.type,s)))},o=()=>{a(s=>{for(const i of e)s.removeEventListener(i,r)})};return a(s=>{for(const i of e)s.addEventListener(i,r,{once:!0})}),o};function QM(e,t){if(ss(e)&&e.data==="["){let a=1,n=e.nextSibling;for(;n;){if(n.nodeType===1){if(t(n)===!1)break}else if(ss(n))if(n.data==="]"){if(--a===0)break}else n.data==="["&&a++;n=n.nextSibling}}else t(e)}const Jr=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function $v(e){gt(e)&&(e={loader:e});const{loader:t,loadingComponent:a,errorComponent:n,delay:r=200,hydrate:o,timeout:s,suspensible:i=!0,onError:l}=e;let c=null,d,u=0;const h=()=>(u++,c=null,f()),f=()=>{let m;return c||(m=c=t().catch(g=>{if(g=g instanceof Error?g:new Error(String(g)),l)return new Promise((_,b)=>{l(g,()=>_(h()),()=>b(g),u+1)});throw g}).then(g=>m!==c&&c?c:(g&&(g.__esModule||g[Symbol.toStringTag]==="Module")&&(g=g.default),d=g,g)))};return $e({name:"AsyncComponentWrapper",__asyncLoader:f,__asyncHydrate(m,g,_){const b=o?()=>{const v=o(_,y=>QM(m,y));v&&(g.bum||(g.bum=[])).push(v)}:_;d?b():f().then(()=>!g.isUnmounted&&b())},get __asyncResolved(){return d},setup(){const m=$a;if(s0(m),d)return()=>E2(d,m);const g=y=>{c=null,Oo(y,m,13,!n)};if(i&&m.suspense||Ms)return f().then(y=>()=>E2(y,m)).catch(y=>(g(y),()=>n?Ce(n,{error:y}):null));const _=ye(!1),b=ye(),v=ye(!!r);return r&&setTimeout(()=>{v.value=!1},r),s!=null&&setTimeout(()=>{if(!_.value&&!b.value){const y=new Error(`Async component timed out after ${s}ms.`);g(y),b.value=y}},s),f().then(()=>{_.value=!0,m.parent&&Ni(m.parent.vnode)&&m.parent.update()}).catch(y=>{g(y),b.value=y}),()=>{if(_.value&&d)return E2(d,m);if(b.value&&n)return Ce(n,{error:b.value});if(a&&!v.value)return Ce(a)}}})}function E2(e,t){const{ref:a,props:n,children:r,ce:o}=t.vnode,s=Ce(e,n,r);return s.ref=a,s.ce=o,delete t.vnode.ce,s}const Ni=e=>e.type.__isKeepAlive,e_={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const a=gn(),n=a.ctx;if(!n.renderer)return()=>{const v=t.default&&t.default();return v&&v.length===1?v[0]:v};const r=new Map,o=new Set;let s=null;const i=a.suspense,{renderer:{p:l,m:c,um:d,o:{createElement:u}}}=n,h=u("div");n.activate=(v,y,M,x,S)=>{const L=v.component;c(v,y,M,0,i),l(L.vnode,v,y,M,L,i,x,v.slotScopeIds,S),Aa(()=>{L.isDeactivated=!1,L.a&&hs(L.a);const F=v.props&&v.props.onVnodeMounted;F&&tn(F,L.parent,v)},i)},n.deactivate=v=>{const y=v.component;X1(y.m),X1(y.a),c(v,h,null,1,i),Aa(()=>{y.da&&hs(y.da);const M=v.props&&v.props.onVnodeUnmounted;M&&tn(M,y.parent,v),y.isDeactivated=!0},i)};function f(v){I2(v),d(v,a,i,!0)}function m(v){r.forEach((y,M)=>{const x=wc(y.type);x&&!v(x)&&g(M)})}function g(v){const y=r.get(v);y&&(!s||!Rn(y,s))?f(y):s&&I2(s),r.delete(v),o.delete(v)}We(()=>[e.include,e.exclude],([v,y])=>{v&&m(M=>ai(v,M)),y&&m(M=>!ai(y,M))},{flush:"post",deep:!0});let _=null;const b=()=>{_!=null&&(Y1(a.subTree.type)?Aa(()=>{r.set(_,m1(a.subTree))},a.subTree.suspense):r.set(_,m1(a.subTree)))};return ia(b),Tl(b),Ir(()=>{r.forEach(v=>{const{subTree:y,suspense:M}=a,x=m1(y);if(v.type===x.type&&v.key===x.key){I2(x);const S=x.component.da;S&&Aa(S,M);return}f(v)})}),()=>{if(_=null,!t.default)return s=null;const v=t.default(),y=v[0];if(v.length>1)return s=null,v;if(!Ar(y)||!(y.shapeFlag&4)&&!(y.shapeFlag&128))return s=null,y;let M=m1(y);if(M.type===_a)return s=null,M;const x=M.type,S=wc(Jr(M)?M.type.__asyncResolved||{}:x),{include:L,exclude:F,max:te}=e;if(L&&(!S||!ai(L,S))||F&&S&&ai(F,S))return M.shapeFlag&=-257,s=M,y;const J=M.key==null?x:M.key,be=r.get(J);return M.el&&(M=nr(M),y.shapeFlag&128&&(y.ssContent=M)),_=J,be?(M.el=be.el,M.component=be.component,M.transition&&Cr(M,M.transition),M.shapeFlag|=512,o.delete(J),o.add(J)):(o.add(J),te&&o.size>parseInt(te,10)&&g(o.values().next().value)),M.shapeFlag|=256,s=M,Y1(y.type)?y:M}}},t_=e_;function ai(e,t){return st(e)?e.some(a=>ai(a,t)):sa(e)?e.split(",").includes(t):H9(e)?(e.lastIndex=0,e.test(t)):!1}function Ev(e,t){kv(e,"a",t)}function Iv(e,t){kv(e,"da",t)}function kv(e,t,a=$a){const n=e.__wdc||(e.__wdc=()=>{let r=a;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(kl(t,n,a),a){let r=a.parent;for(;r&&r.parent;)Ni(r.parent.vnode)&&a_(n,t,a,r),r=r.parent}}function a_(e,t,a,n){const r=kl(t,e,n,!0);Wn(()=>{Zc(n[t],r)},a)}function I2(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function m1(e){return e.shapeFlag&128?e.ssContent:e}function kl(e,t,a=$a,n=!1){if(a){const r=a[e]||(a[e]=[]),o=t.__weh||(t.__weh=(...s)=>{ro();const i=Io(a),l=$n(t,a,e,s);return i(),oo(),l});return n?r.unshift(o):r.push(o),o}}const Er=e=>(t,a=$a)=>{(!Ms||e==="sp")&&kl(e,(...n)=>t(...n),a)},ks=Er("bm"),ia=Er("m"),i0=Er("bu"),Tl=Er("u"),Ir=Er("bum"),Wn=Er("um"),Tv=Er("sp"),Pv=Er("rtg"),Lv=Er("rtc");function Vv(e,t=$a){kl("ec",e,t)}const l0="components",n_="directives";function r_(e,t){return c0(l0,e,!0,t)||e}const Ov=Symbol.for("v-ndc");function Ts(e){return sa(e)?c0(l0,e,!1)||e:e||Ov}function Hv(e){return c0(n_,e)}function c0(e,t,a=!0,n=!1){const r=Ea||$a;if(r){const o=r.type;if(e===l0){const i=wc(o,!1);if(i&&(i===t||i===Da(t)||i===Hi(Da(t))))return o}const s=ah(r[e]||o[e],t)||ah(r.appContext[e],t);return!s&&n?o:s}}function ah(e,t){return e&&(e[t]||e[Da(t)]||e[Hi(Da(t))])}function Ot(e,t,a,n){let r;const o=a&&a[n],s=st(e);if(s||sa(e)){const i=s&&Gr(e);let l=!1;i&&(l=!hn(e),e=Cl(e)),r=new Array(e.length);for(let c=0,d=e.length;c<d;c++)r[c]=t(l?Ua(e[c]):e[c],c,void 0,o&&o[c])}else if(typeof e=="number"){r=new Array(e);for(let i=0;i<e;i++)r[i]=t(i+1,i,void 0,o&&o[i])}else if(ea(e))if(e[Symbol.iterator])r=Array.from(e,(i,l)=>t(i,l,void 0,o&&o[l]));else{const i=Object.keys(e);r=new Array(i.length);for(let l=0,c=i.length;l<c;l++){const d=i[l];r[l]=t(e[d],d,l,o&&o[l])}}else r=[];return a&&(a[n]=r),r}function o_(e,t){for(let a=0;a<t.length;a++){const n=t[a];if(st(n))for(let r=0;r<n.length;r++)e[n[r].name]=n[r].fn;else n&&(e[n.name]=n.key?(...r)=>{const o=n.fn(...r);return o&&(o.key=n.key),o}:n.fn)}return e}function qt(e,t,a={},n,r){if(Ea.ce||Ea.parent&&Jr(Ea.parent)&&Ea.parent.ce)return t!=="default"&&(a.name=t),$(),Ie(Je,null,[Ce("slot",a,n&&n())],64);let o=e[t];o&&o._c&&(o._d=!1),$();const s=o&&d0(o(a)),i=a.key||s&&s.key,l=Ie(Je,{key:(i&&!Bn(i)?i:`_${t}`)+(!s&&n?"_fb":"")},s||(n?n():[]),s&&e._===1?64:-2);return!r&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),o&&o._c&&(o._d=!0),l}function d0(e){return e.some(t=>Ar(t)?!(t.type===_a||t.type===Je&&!d0(t.children)):!0)?e:null}function s_(e,t){const a={};for(const n in e)a[t&&/[A-Z]/.test(n)?`on:${n}`:li(n)]=e[n];return a}const uc=e=>e?f3(e)?Fi(e):uc(e.parent):null,hi=aa(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>uc(e.parent),$root:e=>uc(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>u0(e),$forceUpdate:e=>e.f||(e.f=()=>{n0(e.update)}),$nextTick:e=>e.n||(e.n=qa.bind(e.proxy)),$watch:e=>R_.bind(e)}),k2=(e,t)=>e!==Nt&&!e.__isScriptSetup&&Kt(e,t),hc={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:a,setupState:n,data:r,props:o,accessCache:s,type:i,appContext:l}=e;let c;if(t[0]!=="$"){const f=s[t];if(f!==void 0)switch(f){case 1:return n[t];case 2:return r[t];case 4:return a[t];case 3:return o[t]}else{if(k2(n,t))return s[t]=1,n[t];if(r!==Nt&&Kt(r,t))return s[t]=2,r[t];if((c=e.propsOptions[0])&&Kt(c,t))return s[t]=3,o[t];if(a!==Nt&&Kt(a,t))return s[t]=4,a[t];pc&&(s[t]=0)}}const d=hi[t];let u,h;if(d)return t==="$attrs"&&ja(e.attrs,"get",""),d(e);if((u=i.__cssModules)&&(u=u[t]))return u;if(a!==Nt&&Kt(a,t))return s[t]=4,a[t];if(h=l.config.globalProperties,Kt(h,t))return h[t]},set({_:e},t,a){const{data:n,setupState:r,ctx:o}=e;return k2(r,t)?(r[t]=a,!0):n!==Nt&&Kt(n,t)?(n[t]=a,!0):Kt(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=a,!0)},has({_:{data:e,setupState:t,accessCache:a,ctx:n,appContext:r,propsOptions:o}},s){let i;return!!a[s]||e!==Nt&&Kt(e,s)||k2(t,s)||(i=o[0])&&Kt(i,s)||Kt(n,s)||Kt(hi,s)||Kt(r.config.globalProperties,s)},defineProperty(e,t,a){return a.get!=null?e._.accessCache[t]=0:Kt(a,"value")&&this.set(e,t,a.value,null),Reflect.defineProperty(e,t,a)}},i_=aa({},hc,{get(e,t){if(t!==Symbol.unscopables)return hc.get(e,t,e)},has(e,t){return t[0]!=="_"&&!F9(t)}});function l_(){return null}function c_(){return null}function d_(e){}function u_(e){}function h_(){return null}function p_(){}function f_(e,t){return null}function m_(){return Rv().slots}function v_(){return Rv().attrs}function Rv(){const e=gn();return e.setupContext||(e.setupContext=g3(e))}function ki(e){return st(e)?e.reduce((t,a)=>(t[a]=null,t),{}):e}function g_(e,t){const a=ki(e);for(const n in t){if(n.startsWith("__skip"))continue;let r=a[n];r?st(r)||gt(r)?r=a[n]={type:r,default:t[n]}:r.default=t[n]:r===null&&(r=a[n]={default:t[n]}),r&&t[`__skip_${n}`]&&(r.skipFactory=!0)}return a}function Fn(e,t){return!e||!t?e||t:st(e)&&st(t)?e.concat(t):aa({},ki(e),ki(t))}function y_(e,t){const a={};for(const n in e)t.includes(n)||Object.defineProperty(a,n,{enumerable:!0,get:()=>e[n]});return a}function M_(e){const t=gn();let a=e();return Mc(),Kc(a)&&(a=a.catch(n=>{throw Io(t),n})),[a,()=>Io(t)]}let pc=!0;function __(e){const t=u0(e),a=e.proxy,n=e.ctx;pc=!1,t.beforeCreate&&nh(t.beforeCreate,e,"bc");const{data:r,computed:o,methods:s,watch:i,provide:l,inject:c,created:d,beforeMount:u,mounted:h,beforeUpdate:f,updated:m,activated:g,deactivated:_,beforeDestroy:b,beforeUnmount:v,destroyed:y,unmounted:M,render:x,renderTracked:S,renderTriggered:L,errorCaptured:F,serverPrefetch:te,expose:J,inheritAttrs:be,components:oe,directives:Te,filters:Ue}=t;if(c&&b_(c,n,null),s)for(const ee in s){const j=s[ee];gt(j)&&(n[ee]=j.bind(a))}if(r){const ee=r.call(a,a);ea(ee)&&(e.data=Ri(ee))}if(pc=!0,o)for(const ee in o){const j=o[ee],K=gt(j)?j.bind(a,a):gt(j.get)?j.get.bind(a,a):Cn,G=!gt(j)&&gt(j.set)?j.set.bind(a):Cn,T=H({get:K,set:G});Object.defineProperty(n,ee,{enumerable:!0,configurable:!0,get:()=>T.value,set:O=>T.value=O})}if(i)for(const ee in i)Nv(i[ee],n,a,ee);if(l){const ee=gt(l)?l.call(a):l;Reflect.ownKeys(ee).forEach(j=>{Bv(j,ee[j])})}d&&nh(d,e,"c");function Me(ee,j){st(j)?j.forEach(K=>ee(K.bind(a))):j&&ee(j.bind(a))}if(Me(ks,u),Me(ia,h),Me(i0,f),Me(Tl,m),Me(Ev,g),Me(Iv,_),Me(Vv,F),Me(Lv,S),Me(Pv,L),Me(Ir,v),Me(Wn,M),Me(Tv,te),st(J))if(J.length){const ee=e.exposed||(e.exposed={});J.forEach(j=>{Object.defineProperty(ee,j,{get:()=>a[j],set:K=>a[j]=K})})}else e.exposed||(e.exposed={});x&&e.render===Cn&&(e.render=x),be!=null&&(e.inheritAttrs=be),oe&&(e.components=oe),Te&&(e.directives=Te),te&&s0(e)}function b_(e,t,a=Cn){st(e)&&(e=fc(e));for(const n in e){const r=e[n];let o;ea(r)?"default"in r?o=re(r.from||n,r.default,!0):o=re(r.from||n):o=re(r),ba(o)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>o.value,set:s=>o.value=s}):t[n]=o}}function nh(e,t,a){$n(st(e)?e.map(n=>n.bind(t.proxy)):e.bind(t.proxy),t,a)}function Nv(e,t,a,n){let r=n.includes(".")?r3(a,n):()=>a[n];if(sa(e)){const o=t[e];gt(o)&&We(r,o)}else if(gt(e))We(r,e.bind(a));else if(ea(e))if(st(e))e.forEach(o=>Nv(o,t,a,n));else{const o=gt(e.handler)?e.handler.bind(a):t[e.handler];gt(o)&&We(r,o,e)}}function u0(e){const t=e.type,{mixins:a,extends:n}=t,{mixins:r,optionsCache:o,config:{optionMergeStrategies:s}}=e.appContext,i=o.get(t);let l;return i?l=i:!r.length&&!a&&!n?l=t:(l={},r.length&&r.forEach(c=>J1(l,c,s,!0)),J1(l,t,s)),ea(t)&&o.set(t,l),l}function J1(e,t,a,n=!1){const{mixins:r,extends:o}=t;o&&J1(e,o,a,!0),r&&r.forEach(s=>J1(e,s,a,!0));for(const s in t)if(!(n&&s==="expose")){const i=w_[s]||a&&a[s];e[s]=i?i(e[s],t[s]):t[s]}return e}const w_={data:rh,props:oh,emits:oh,methods:ni,computed:ni,beforeCreate:Za,created:Za,beforeMount:Za,mounted:Za,beforeUpdate:Za,updated:Za,beforeDestroy:Za,beforeUnmount:Za,destroyed:Za,unmounted:Za,activated:Za,deactivated:Za,errorCaptured:Za,serverPrefetch:Za,components:ni,directives:ni,watch:C_,provide:rh,inject:x_};function rh(e,t){return t?e?function(){return aa(gt(e)?e.call(this,this):e,gt(t)?t.call(this,this):t)}:t:e}function x_(e,t){return ni(fc(e),fc(t))}function fc(e){if(st(e)){const t={};for(let a=0;a<e.length;a++)t[e[a]]=e[a];return t}return e}function Za(e,t){return e?[...new Set([].concat(e,t))]:t}function ni(e,t){return e?aa(Object.create(null),e,t):t}function oh(e,t){return e?st(e)&&st(t)?[...new Set([...e,...t])]:aa(Object.create(null),ki(e),ki(t??{})):t}function C_(e,t){if(!e)return t;if(!t)return e;const a=aa(Object.create(null),e);for(const n in t)a[n]=Za(e[n],t[n]);return a}function Dv(){return{app:null,config:{isNativeTag:V9,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let A_=0;function S_(e,t){return function(n,r=null){gt(n)||(n=aa({},n)),r!=null&&!ea(r)&&(r=null);const o=Dv(),s=new WeakSet,i=[];let l=!1;const c=o.app={_uid:A_++,_component:n,_props:r,_container:null,_context:o,_instance:null,version:M3,get config(){return o.config},set config(d){},use(d,...u){return s.has(d)||(d&&gt(d.install)?(s.add(d),d.install(c,...u)):gt(d)&&(s.add(d),d(c,...u))),c},mixin(d){return o.mixins.includes(d)||o.mixins.push(d),c},component(d,u){return u?(o.components[d]=u,c):o.components[d]},directive(d,u){return u?(o.directives[d]=u,c):o.directives[d]},mount(d,u,h){if(!l){const f=c._ceVNode||Ce(n,r);return f.appContext=o,h===!0?h="svg":h===!1&&(h=void 0),u&&t?t(f,d):e(f,d,h),l=!0,c._container=d,d.__vue_app__=c,Fi(f.component)}},onUnmount(d){i.push(d)},unmount(){l&&($n(i,c._instance,16),e(null,c._container),delete c._container.__vue_app__)},provide(d,u){return o.provides[d]=u,c},runWithContext(d){const u=So;So=c;try{return d()}finally{So=u}}};return c}}let So=null;function Bv(e,t){if($a){let a=$a.provides;const n=$a.parent&&$a.parent.provides;n===a&&(a=$a.provides=Object.create(n)),a[e]=t}}function re(e,t,a=!1){const n=$a||Ea;if(n||So){const r=So?So._context.provides:n?n.parent==null?n.vnode.appContext&&n.vnode.appContext.provides:n.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return a&&gt(t)?t.call(n&&n.proxy):t}}function $_(){return!!($a||Ea||So)}const Fv={},jv=()=>Object.create(Fv),Uv=e=>Object.getPrototypeOf(e)===Fv;function E_(e,t,a,n=!1){const r={},o=jv();e.propsDefaults=Object.create(null),zv(e,t,r,o);for(const s in e.propsOptions[0])s in r||(r[s]=void 0);a?e.props=n?r:sv(r):e.type.props?e.props=r:e.props=o,e.attrs=o}function I_(e,t,a,n){const{props:r,attrs:o,vnode:{patchFlag:s}}=e,i=St(r),[l]=e.propsOptions;let c=!1;if((n||s>0)&&!(s&16)){if(s&8){const d=e.vnode.dynamicProps;for(let u=0;u<d.length;u++){let h=d[u];if(Pl(e.emitsOptions,h))continue;const f=t[h];if(l)if(Kt(o,h))f!==o[h]&&(o[h]=f,c=!0);else{const m=Da(h);r[m]=mc(l,i,m,f,e,!1)}else f!==o[h]&&(o[h]=f,c=!0)}}}else{zv(e,t,r,o)&&(c=!0);let d;for(const u in i)(!t||!Kt(t,u)&&((d=rn(u))===u||!Kt(t,d)))&&(l?a&&(a[u]!==void 0||a[d]!==void 0)&&(r[u]=mc(l,i,u,void 0,e,!0)):delete r[u]);if(o!==i)for(const u in o)(!t||!Kt(t,u))&&(delete o[u],c=!0)}c&&Mr(e.attrs,"set","")}function zv(e,t,a,n){const[r,o]=e.propsOptions;let s=!1,i;if(t)for(let l in t){if(us(l))continue;const c=t[l];let d;r&&Kt(r,d=Da(l))?!o||!o.includes(d)?a[d]=c:(i||(i={}))[d]=c:Pl(e.emitsOptions,l)||(!(l in n)||c!==n[l])&&(n[l]=c,s=!0)}if(o){const l=St(a),c=i||Nt;for(let d=0;d<o.length;d++){const u=o[d];a[u]=mc(r,l,u,c[u],e,!Kt(c,u))}}return s}function mc(e,t,a,n,r,o){const s=e[a];if(s!=null){const i=Kt(s,"default");if(i&&n===void 0){const l=s.default;if(s.type!==Function&&!s.skipFactory&&gt(l)){const{propsDefaults:c}=r;if(a in c)n=c[a];else{const d=Io(r);n=c[a]=l.call(null,t),d()}}else n=l;r.ce&&r.ce._setProp(a,n)}s[0]&&(o&&!i?n=!1:s[1]&&(n===""||n===rn(a))&&(n=!0))}return n}const k_=new WeakMap;function qv(e,t,a=!1){const n=a?k_:t.propsCache,r=n.get(e);if(r)return r;const o=e.props,s={},i=[];let l=!1;if(!gt(e)){const d=u=>{l=!0;const[h,f]=qv(u,t,!0);aa(s,h),f&&i.push(...f)};!a&&t.mixins.length&&t.mixins.forEach(d),e.extends&&d(e.extends),e.mixins&&e.mixins.forEach(d)}if(!o&&!l)return ea(e)&&n.set(e,cs),cs;if(st(o))for(let d=0;d<o.length;d++){const u=Da(o[d]);sh(u)&&(s[u]=Nt)}else if(o)for(const d in o){const u=Da(d);if(sh(u)){const h=o[d],f=s[u]=st(h)||gt(h)?{type:h}:aa({},h),m=f.type;let g=!1,_=!0;if(st(m))for(let b=0;b<m.length;++b){const v=m[b],y=gt(v)&&v.name;if(y==="Boolean"){g=!0;break}else y==="String"&&(_=!1)}else g=gt(m)&&m.name==="Boolean";f[0]=g,f[1]=_,(g||Kt(f,"default"))&&i.push(u)}}const c=[s,i];return ea(e)&&n.set(e,c),c}function sh(e){return e[0]!=="$"&&!us(e)}const Wv=e=>e[0]==="_"||e==="$stable",h0=e=>st(e)?e.map(nn):[nn(e)],T_=(e,t,a)=>{if(t._n)return t;const n=Xe((...r)=>h0(t(...r)),a);return n._c=!1,n},Zv=(e,t,a)=>{const n=e._ctx;for(const r in e){if(Wv(r))continue;const o=e[r];if(gt(o))t[r]=T_(r,o,n);else if(o!=null){const s=h0(o);t[r]=()=>s}}},Kv=(e,t)=>{const a=h0(t);e.slots.default=()=>a},Gv=(e,t,a)=>{for(const n in t)(a||n!=="_")&&(e[n]=t[n])},P_=(e,t,a)=>{const n=e.slots=jv();if(e.vnode.shapeFlag&32){const r=t._;r?(Gv(n,t,a),a&&Fm(n,"_",r,!0)):Zv(t,n)}else t&&Kv(e,t)},L_=(e,t,a)=>{const{vnode:n,slots:r}=e;let o=!0,s=Nt;if(n.shapeFlag&32){const i=t._;i?a&&i===1?o=!1:Gv(r,t,a):(o=!t.$stable,Zv(t,r)),s=t}else t&&(Kv(e,t),s={default:1});if(o)for(const i in r)!Wv(i)&&s[i]==null&&delete r[i]},Aa=l3;function Jv(e){return Yv(e)}function Xv(e){return Yv(e,zM)}function Yv(e,t){const a=_l();a.__VUE__=!0;const{insert:n,remove:r,patchProp:o,createElement:s,createText:i,createComment:l,setText:c,setElementText:d,parentNode:u,nextSibling:h,setScopeId:f=Cn,insertStaticContent:m}=e,g=(D,q,he,me=null,_e=null,Ae=null,pe=void 0,ce=null,ue=!!q.dynamicChildren)=>{if(D===q)return;D&&!Rn(D,q)&&(me=xe(D),O(D,_e,Ae,!0),D=null),q.patchFlag===-2&&(ue=!1,q.dynamicChildren=null);const{type:I,ref:B,shapeFlag:N}=q;switch(I){case Xr:_(D,q,he,me);break;case _a:b(D,q,he,me);break;case $o:D==null&&v(q,he,me,pe);break;case Je:oe(D,q,he,me,_e,Ae,pe,ce,ue);break;default:N&1?x(D,q,he,me,_e,Ae,pe,ce,ue):N&6?Te(D,q,he,me,_e,Ae,pe,ce,ue):(N&64||N&128)&&I.process(D,q,he,me,_e,Ae,pe,ce,ue,Ye)}B!=null&&_e&&Ii(B,D&&D.ref,Ae,q||D,!q)},_=(D,q,he,me)=>{if(D==null)n(q.el=i(q.children),he,me);else{const _e=q.el=D.el;q.children!==D.children&&c(_e,q.children)}},b=(D,q,he,me)=>{D==null?n(q.el=l(q.children||""),he,me):q.el=D.el},v=(D,q,he,me)=>{[D.el,D.anchor]=m(D.children,q,he,me,D.el,D.anchor)},y=({el:D,anchor:q},he,me)=>{let _e;for(;D&&D!==q;)_e=h(D),n(D,he,me),D=_e;n(q,he,me)},M=({el:D,anchor:q})=>{let he;for(;D&&D!==q;)he=h(D),r(D),D=he;r(q)},x=(D,q,he,me,_e,Ae,pe,ce,ue)=>{q.type==="svg"?pe="svg":q.type==="math"&&(pe="mathml"),D==null?S(q,he,me,_e,Ae,pe,ce,ue):te(D,q,_e,Ae,pe,ce,ue)},S=(D,q,he,me,_e,Ae,pe,ce)=>{let ue,I;const{props:B,shapeFlag:N,transition:U,dirs:se}=D;if(ue=D.el=s(D.type,Ae,B&&B.is,B),N&8?d(ue,D.children):N&16&&F(D.children,ue,null,me,_e,T2(D,Ae),pe,ce),se&&Xn(D,null,me,"created"),L(ue,D,D.scopeId,pe,me),B){for(const Ne in B)Ne!=="value"&&!us(Ne)&&o(ue,Ne,null,B[Ne],Ae,me);"value"in B&&o(ue,"value",null,B.value,Ae),(I=B.onVnodeBeforeMount)&&tn(I,me,D)}se&&Xn(D,null,me,"beforeMount");const Se=Qv(_e,U);Se&&U.beforeEnter(ue),n(ue,q,he),((I=B&&B.onVnodeMounted)||Se||se)&&Aa(()=>{I&&tn(I,me,D),Se&&U.enter(ue),se&&Xn(D,null,me,"mounted")},_e)},L=(D,q,he,me,_e)=>{if(he&&f(D,he),me)for(let Ae=0;Ae<me.length;Ae++)f(D,me[Ae]);if(_e){let Ae=_e.subTree;if(q===Ae||Y1(Ae.type)&&(Ae.ssContent===q||Ae.ssFallback===q)){const pe=_e.vnode;L(D,pe,pe.scopeId,pe.slotScopeIds,_e.parent)}}},F=(D,q,he,me,_e,Ae,pe,ce,ue=0)=>{for(let I=ue;I<D.length;I++){const B=D[I]=ce?qr(D[I]):nn(D[I]);g(null,B,q,he,me,_e,Ae,pe,ce)}},te=(D,q,he,me,_e,Ae,pe)=>{const ce=q.el=D.el;let{patchFlag:ue,dynamicChildren:I,dirs:B}=q;ue|=D.patchFlag&16;const N=D.props||Nt,U=q.props||Nt;let se;if(he&&fo(he,!1),(se=U.onVnodeBeforeUpdate)&&tn(se,he,q,D),B&&Xn(q,D,he,"beforeUpdate"),he&&fo(he,!0),(N.innerHTML&&U.innerHTML==null||N.textContent&&U.textContent==null)&&d(ce,""),I?J(D.dynamicChildren,I,ce,he,me,T2(q,_e),Ae):pe||j(D,q,ce,null,he,me,T2(q,_e),Ae,!1),ue>0){if(ue&16)be(ce,N,U,he,_e);else if(ue&2&&N.class!==U.class&&o(ce,"class",null,U.class,_e),ue&4&&o(ce,"style",N.style,U.style,_e),ue&8){const Se=q.dynamicProps;for(let Ne=0;Ne<Se.length;Ne++){const ut=Se[Ne],ie=N[ut],Ee=U[ut];(Ee!==ie||ut==="value")&&o(ce,ut,ie,Ee,_e,he)}}ue&1&&D.children!==q.children&&d(ce,q.children)}else!pe&&I==null&&be(ce,N,U,he,_e);((se=U.onVnodeUpdated)||B)&&Aa(()=>{se&&tn(se,he,q,D),B&&Xn(q,D,he,"updated")},me)},J=(D,q,he,me,_e,Ae,pe)=>{for(let ce=0;ce<q.length;ce++){const ue=D[ce],I=q[ce],B=ue.el&&(ue.type===Je||!Rn(ue,I)||ue.shapeFlag&70)?u(ue.el):he;g(ue,I,B,null,me,_e,Ae,pe,!0)}},be=(D,q,he,me,_e)=>{if(q!==he){if(q!==Nt)for(const Ae in q)!us(Ae)&&!(Ae in he)&&o(D,Ae,q[Ae],null,_e,me);for(const Ae in he){if(us(Ae))continue;const pe=he[Ae],ce=q[Ae];pe!==ce&&Ae!=="value"&&o(D,Ae,ce,pe,_e,me)}"value"in he&&o(D,"value",q.value,he.value,_e)}},oe=(D,q,he,me,_e,Ae,pe,ce,ue)=>{const I=q.el=D?D.el:i(""),B=q.anchor=D?D.anchor:i("");let{patchFlag:N,dynamicChildren:U,slotScopeIds:se}=q;se&&(ce=ce?ce.concat(se):se),D==null?(n(I,he,me),n(B,he,me),F(q.children||[],he,B,_e,Ae,pe,ce,ue)):N>0&&N&64&&U&&D.dynamicChildren?(J(D.dynamicChildren,U,he,_e,Ae,pe,ce),(q.key!=null||_e&&q===_e.subTree)&&p0(D,q,!0)):j(D,q,he,B,_e,Ae,pe,ce,ue)},Te=(D,q,he,me,_e,Ae,pe,ce,ue)=>{q.slotScopeIds=ce,D==null?q.shapeFlag&512?_e.ctx.activate(q,he,me,pe,ue):Ue(q,he,me,_e,Ae,pe,ue):Ze(D,q,ue)},Ue=(D,q,he,me,_e,Ae,pe)=>{const ce=D.component=p3(D,me,_e);if(Ni(D)&&(ce.ctx.renderer=Ye),m3(ce,!1,pe),ce.asyncDep){if(_e&&_e.registerDep(ce,Me,pe),!D.el){const ue=ce.subTree=Ce(_a);b(null,ue,q,he)}}else Me(ce,D,q,he,_e,Ae,pe)},Ze=(D,q,he)=>{const me=q.component=D.component;if(j_(D,q,he))if(me.asyncDep&&!me.asyncResolved){ee(me,q,he);return}else me.next=q,me.update();else q.el=D.el,me.vnode=q},Me=(D,q,he,me,_e,Ae,pe)=>{const ce=()=>{if(D.isMounted){let{next:N,bu:U,u:se,parent:Se,vnode:Ne}=D;{const Pe=e3(D);if(Pe){N&&(N.el=Ne.el,ee(D,N,pe)),Pe.asyncDep.then(()=>{D.isUnmounted||ce()});return}}let ut=N,ie;fo(D,!1),N?(N.el=Ne.el,ee(D,N,pe)):N=Ne,U&&hs(U),(ie=N.props&&N.props.onVnodeBeforeUpdate)&&tn(ie,Se,N,Ne),fo(D,!0);const Ee=O1(D),Oe=D.subTree;D.subTree=Ee,g(Oe,Ee,u(Oe.el),xe(Oe),D,_e,Ae),N.el=Ee.el,ut===null&&Ll(D,Ee.el),se&&Aa(se,_e),(ie=N.props&&N.props.onVnodeUpdated)&&Aa(()=>tn(ie,Se,N,Ne),_e)}else{let N;const{el:U,props:se}=q,{bm:Se,m:Ne,parent:ut,root:ie,type:Ee}=D,Oe=Jr(q);if(fo(D,!1),Se&&hs(Se),!Oe&&(N=se&&se.onVnodeBeforeMount)&&tn(N,ut,q),fo(D,!0),U&&wt){const Pe=()=>{D.subTree=O1(D),wt(U,D.subTree,D,_e,null)};Oe&&Ee.__asyncHydrate?Ee.__asyncHydrate(U,D,Pe):Pe()}else{ie.ce&&ie.ce._injectChildStyle(Ee);const Pe=D.subTree=O1(D);g(null,Pe,he,me,D,_e,Ae),q.el=Pe.el}if(Ne&&Aa(Ne,_e),!Oe&&(N=se&&se.onVnodeMounted)){const Pe=q;Aa(()=>tn(N,ut,Pe),_e)}(q.shapeFlag&256||ut&&Jr(ut.vnode)&&ut.vnode.shapeFlag&256)&&D.a&&Aa(D.a,_e),D.isMounted=!0,q=he=me=null}};D.scope.on();const ue=D.effect=new xi(ce);D.scope.off();const I=D.update=ue.run.bind(ue),B=D.job=ue.runIfDirty.bind(ue);B.i=D,B.id=D.uid,ue.scheduler=()=>n0(B),fo(D,!0),I()},ee=(D,q,he)=>{q.component=D;const me=D.vnode.props;D.vnode=q,D.next=null,I_(D,q.props,me,he),L_(D,q.children,he),ro(),Gu(D),oo()},j=(D,q,he,me,_e,Ae,pe,ce,ue=!1)=>{const I=D&&D.children,B=D?D.shapeFlag:0,N=q.children,{patchFlag:U,shapeFlag:se}=q;if(U>0){if(U&128){G(I,N,he,me,_e,Ae,pe,ce,ue);return}else if(U&256){K(I,N,he,me,_e,Ae,pe,ce,ue);return}}se&8?(B&16&&ae(I,_e,Ae),N!==I&&d(he,N)):B&16?se&16?G(I,N,he,me,_e,Ae,pe,ce,ue):ae(I,_e,Ae,!0):(B&8&&d(he,""),se&16&&F(N,he,me,_e,Ae,pe,ce,ue))},K=(D,q,he,me,_e,Ae,pe,ce,ue)=>{D=D||cs,q=q||cs;const I=D.length,B=q.length,N=Math.min(I,B);let U;for(U=0;U<N;U++){const se=q[U]=ue?qr(q[U]):nn(q[U]);g(D[U],se,he,null,_e,Ae,pe,ce,ue)}I>B?ae(D,_e,Ae,!0,!1,N):F(q,he,me,_e,Ae,pe,ce,ue,N)},G=(D,q,he,me,_e,Ae,pe,ce,ue)=>{let I=0;const B=q.length;let N=D.length-1,U=B-1;for(;I<=N&&I<=U;){const se=D[I],Se=q[I]=ue?qr(q[I]):nn(q[I]);if(Rn(se,Se))g(se,Se,he,null,_e,Ae,pe,ce,ue);else break;I++}for(;I<=N&&I<=U;){const se=D[N],Se=q[U]=ue?qr(q[U]):nn(q[U]);if(Rn(se,Se))g(se,Se,he,null,_e,Ae,pe,ce,ue);else break;N--,U--}if(I>N){if(I<=U){const se=U+1,Se=se<B?q[se].el:me;for(;I<=U;)g(null,q[I]=ue?qr(q[I]):nn(q[I]),he,Se,_e,Ae,pe,ce,ue),I++}}else if(I>U)for(;I<=N;)O(D[I],_e,Ae,!0),I++;else{const se=I,Se=I,Ne=new Map;for(I=Se;I<=U;I++){const ht=q[I]=ue?qr(q[I]):nn(q[I]);ht.key!=null&&Ne.set(ht.key,I)}let ut,ie=0;const Ee=U-Se+1;let Oe=!1,Pe=0;const Ke=new Array(Ee);for(I=0;I<Ee;I++)Ke[I]=0;for(I=se;I<=N;I++){const ht=D[I];if(ie>=Ee){O(ht,_e,Ae,!0);continue}let Ft;if(ht.key!=null)Ft=Ne.get(ht.key);else for(ut=Se;ut<=U;ut++)if(Ke[ut-Se]===0&&Rn(ht,q[ut])){Ft=ut;break}Ft===void 0?O(ht,_e,Ae,!0):(Ke[Ft-Se]=I+1,Ft>=Pe?Pe=Ft:Oe=!0,g(ht,q[Ft],he,null,_e,Ae,pe,ce,ue),ie++)}const it=Oe?V_(Ke):cs;for(ut=it.length-1,I=Ee-1;I>=0;I--){const ht=Se+I,Ft=q[ht],ma=ht+1<B?q[ht+1].el:me;Ke[I]===0?g(null,Ft,he,ma,_e,Ae,pe,ce,ue):Oe&&(ut<0||I!==it[ut]?T(Ft,he,ma,2):ut--)}}},T=(D,q,he,me,_e=null)=>{const{el:Ae,type:pe,transition:ce,children:ue,shapeFlag:I}=D;if(I&6){T(D.component.subTree,q,he,me);return}if(I&128){D.suspense.move(q,he,me);return}if(I&64){pe.move(D,q,he,Ye);return}if(pe===Je){n(Ae,q,he);for(let N=0;N<ue.length;N++)T(ue[N],q,he,me);n(D.anchor,q,he);return}if(pe===$o){y(D,q,he);return}if(me!==2&&I&1&&ce)if(me===0)ce.beforeEnter(Ae),n(Ae,q,he),Aa(()=>ce.enter(Ae),_e);else{const{leave:N,delayLeave:U,afterLeave:se}=ce,Se=()=>n(Ae,q,he),Ne=()=>{N(Ae,()=>{Se(),se&&se()})};U?U(Ae,Se,Ne):Ne()}else n(Ae,q,he)},O=(D,q,he,me=!1,_e=!1)=>{const{type:Ae,props:pe,ref:ce,children:ue,dynamicChildren:I,shapeFlag:B,patchFlag:N,dirs:U,cacheIndex:se}=D;if(N===-2&&(_e=!1),ce!=null&&Ii(ce,null,he,D,!0),se!=null&&(q.renderCache[se]=void 0),B&256){q.ctx.deactivate(D);return}const Se=B&1&&U,Ne=!Jr(D);let ut;if(Ne&&(ut=pe&&pe.onVnodeBeforeUnmount)&&tn(ut,q,D),B&6)P(D.component,he,me);else{if(B&128){D.suspense.unmount(he,me);return}Se&&Xn(D,null,q,"beforeUnmount"),B&64?D.type.remove(D,q,he,Ye,me):I&&!I.hasOnce&&(Ae!==Je||N>0&&N&64)?ae(I,q,he,!1,!0):(Ae===Je&&N&384||!_e&&B&16)&&ae(ue,q,he),me&&k(D)}(Ne&&(ut=pe&&pe.onVnodeUnmounted)||Se)&&Aa(()=>{ut&&tn(ut,q,D),Se&&Xn(D,null,q,"unmounted")},he)},k=D=>{const{type:q,el:he,anchor:me,transition:_e}=D;if(q===Je){C(he,me);return}if(q===$o){M(D);return}const Ae=()=>{r(he),_e&&!_e.persisted&&_e.afterLeave&&_e.afterLeave()};if(D.shapeFlag&1&&_e&&!_e.persisted){const{leave:pe,delayLeave:ce}=_e,ue=()=>pe(he,Ae);ce?ce(D.el,Ae,ue):ue()}else Ae()},C=(D,q)=>{let he;for(;D!==q;)he=h(D),r(D),D=he;r(q)},P=(D,q,he)=>{const{bum:me,scope:_e,job:Ae,subTree:pe,um:ce,m:ue,a:I}=D;X1(ue),X1(I),me&&hs(me),_e.stop(),Ae&&(Ae.flags|=8,O(pe,D,q,he)),ce&&Aa(ce,q),Aa(()=>{D.isUnmounted=!0},q),q&&q.pendingBranch&&!q.isUnmounted&&D.asyncDep&&!D.asyncResolved&&D.suspenseId===q.pendingId&&(q.deps--,q.deps===0&&q.resolve())},ae=(D,q,he,me=!1,_e=!1,Ae=0)=>{for(let pe=Ae;pe<D.length;pe++)O(D[pe],q,he,me,_e)},xe=D=>{if(D.shapeFlag&6)return xe(D.component.subTree);if(D.shapeFlag&128)return D.suspense.next();const q=h(D.anchor||D.el),he=q&&q[gv];return he?h(he):q};let ve=!1;const ze=(D,q,he)=>{D==null?q._vnode&&O(q._vnode,null,null,!0):g(q._vnode||null,D,q,null,null,null,he),q._vnode=D,ve||(ve=!0,Gu(),G1(),ve=!1)},Ye={p:g,um:O,m:T,r:k,mt:Ue,mc:F,pc:j,pbc:J,n:xe,o:e};let ct,wt;return t&&([ct,wt]=t(Ye)),{render:ze,hydrate:ct,createApp:S_(ze,ct)}}function T2({type:e,props:t},a){return a==="svg"&&e==="foreignObject"||a==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:a}function fo({effect:e,job:t},a){a?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Qv(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function p0(e,t,a=!1){const n=e.children,r=t.children;if(st(n)&&st(r))for(let o=0;o<n.length;o++){const s=n[o];let i=r[o];i.shapeFlag&1&&!i.dynamicChildren&&((i.patchFlag<=0||i.patchFlag===32)&&(i=r[o]=qr(r[o]),i.el=s.el),!a&&i.patchFlag!==-2&&p0(s,i)),i.type===Xr&&(i.el=s.el)}}function V_(e){const t=e.slice(),a=[0];let n,r,o,s,i;const l=e.length;for(n=0;n<l;n++){const c=e[n];if(c!==0){if(r=a[a.length-1],e[r]<c){t[n]=r,a.push(n);continue}for(o=0,s=a.length-1;o<s;)i=o+s>>1,e[a[i]]<c?o=i+1:s=i;c<e[a[o]]&&(o>0&&(t[n]=a[o-1]),a[o]=n)}}for(o=a.length,s=a[o-1];o-- >0;)a[o]=s,s=t[s];return a}function e3(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:e3(t)}function X1(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const t3=Symbol.for("v-scx"),a3=()=>re(t3);function O_(e,t){return Di(e,null,t)}function H_(e,t){return Di(e,null,{flush:"post"})}function n3(e,t){return Di(e,null,{flush:"sync"})}function We(e,t,a){return Di(e,t,a)}function Di(e,t,a=Nt){const{immediate:n,deep:r,flush:o,once:s}=a,i=aa({},a),l=t&&n||!t&&o!=="post";let c;if(Ms){if(o==="sync"){const f=a3();c=f.__watcherHandles||(f.__watcherHandles=[])}else if(!l){const f=()=>{};return f.stop=Cn,f.resume=Cn,f.pause=Cn,f}}const d=$a;i.call=(f,m,g)=>$n(f,d,m,g);let u=!1;o==="post"?i.scheduler=f=>{Aa(f,d&&d.suspense)}:o!=="sync"&&(u=!0,i.scheduler=(f,m)=>{m?f():n0(f)}),i.augmentJob=f=>{t&&(f.flags|=4),u&&(f.flags|=2,d&&(f.id=d.uid,f.i=d))};const h=IM(e,t,i);return Ms&&(c?c.push(h):l&&h()),h}function R_(e,t,a){const n=this.proxy,r=sa(e)?e.includes(".")?r3(n,e):()=>n[e]:e.bind(n,n);let o;gt(t)?o=t:(o=t.handler,a=t);const s=Io(this),i=Di(r,o.bind(n),a);return s(),i}function r3(e,t){const a=t.split(".");return()=>{let n=e;for(let r=0;r<a.length&&n;r++)n=n[a[r]];return n}}function ir(e,t,a=Nt){const n=gn(),r=Da(t),o=rn(t),s=o3(e,r),i=cv((l,c)=>{let d,u=Nt,h;return n3(()=>{const f=e[r];Ja(d,f)&&(d=f,c())}),{get(){return l(),a.get?a.get(d):d},set(f){const m=a.set?a.set(f):f;if(!Ja(m,d)&&!(u!==Nt&&Ja(f,u)))return;const g=n.vnode.props;g&&(t in g||r in g||o in g)&&(`onUpdate:${t}`in g||`onUpdate:${r}`in g||`onUpdate:${o}`in g)||(d=f,c()),n.emit(`update:${t}`,m),Ja(f,m)&&Ja(f,u)&&!Ja(m,h)&&c(),u=f,h=m}}});return i[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?s||Nt:i,done:!1}:{done:!0}}}},i}const o3=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Da(t)}Modifiers`]||e[`${rn(t)}Modifiers`];function N_(e,t,...a){if(e.isUnmounted)return;const n=e.vnode.props||Nt;let r=a;const o=t.startsWith("update:"),s=o&&o3(n,t.slice(7));s&&(s.trim&&(r=a.map(d=>sa(d)?d.trim():d)),s.number&&(r=a.map(z1)));let i,l=n[i=li(t)]||n[i=li(Da(t))];!l&&o&&(l=n[i=li(rn(t))]),l&&$n(l,e,6,r);const c=n[i+"Once"];if(c){if(!e.emitted)e.emitted={};else if(e.emitted[i])return;e.emitted[i]=!0,$n(c,e,6,r)}}function s3(e,t,a=!1){const n=t.emitsCache,r=n.get(e);if(r!==void 0)return r;const o=e.emits;let s={},i=!1;if(!gt(e)){const l=c=>{const d=s3(c,t,!0);d&&(i=!0,aa(s,d))};!a&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!o&&!i?(ea(e)&&n.set(e,null),null):(st(o)?o.forEach(l=>s[l]=null):aa(s,o),ea(e)&&n.set(e,s),s)}function Pl(e,t){return!e||!Oi(t)?!1:(t=t.slice(2).replace(/Once$/,""),Kt(e,t[0].toLowerCase()+t.slice(1))||Kt(e,rn(t))||Kt(e,t))}function O1(e){const{type:t,vnode:a,proxy:n,withProxy:r,propsOptions:[o],slots:s,attrs:i,emit:l,render:c,renderCache:d,props:u,data:h,setupState:f,ctx:m,inheritAttrs:g}=e,_=Ei(e);let b,v;try{if(a.shapeFlag&4){const M=r||n,x=M;b=nn(c.call(x,M,d,u,f,h,m)),v=i}else{const M=t;b=nn(M.length>1?M(u,{attrs:i,slots:s,emit:l}):M(u,null)),v=t.props?i:B_(i)}}catch(M){pi.length=0,Oo(M,e,1),b=Ce(_a)}let y=b;if(v&&g!==!1){const M=Object.keys(v),{shapeFlag:x}=y;M.length&&x&7&&(o&&M.some(Wc)&&(v=F_(v,o)),y=nr(y,v,!1,!0))}return a.dirs&&(y=nr(y,null,!1,!0),y.dirs=y.dirs?y.dirs.concat(a.dirs):a.dirs),a.transition&&Cr(y,a.transition),b=y,Ei(_),b}function D_(e,t=!0){let a;for(let n=0;n<e.length;n++){const r=e[n];if(Ar(r)){if(r.type!==_a||r.children==="v-if"){if(a)return;a=r}}else return}return a}const B_=e=>{let t;for(const a in e)(a==="class"||a==="style"||Oi(a))&&((t||(t={}))[a]=e[a]);return t},F_=(e,t)=>{const a={};for(const n in e)(!Wc(n)||!(n.slice(9)in t))&&(a[n]=e[n]);return a};function j_(e,t,a){const{props:n,children:r,component:o}=e,{props:s,children:i,patchFlag:l}=t,c=o.emitsOptions;if(t.dirs||t.transition)return!0;if(a&&l>=0){if(l&1024)return!0;if(l&16)return n?ih(n,s,c):!!s;if(l&8){const d=t.dynamicProps;for(let u=0;u<d.length;u++){const h=d[u];if(s[h]!==n[h]&&!Pl(c,h))return!0}}}else return(r||i)&&(!i||!i.$stable)?!0:n===s?!1:n?s?ih(n,s,c):!0:!!s;return!1}function ih(e,t,a){const n=Object.keys(t);if(n.length!==Object.keys(e).length)return!0;for(let r=0;r<n.length;r++){const o=n[r];if(t[o]!==e[o]&&!Pl(a,o))return!0}return!1}function Ll({vnode:e,parent:t},a){for(;t;){const n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.el=e.el),n===e)(e=t.vnode).el=a,t=t.parent;else break}}const Y1=e=>e.__isSuspense;let vc=0;const U_={name:"Suspense",__isSuspense:!0,process(e,t,a,n,r,o,s,i,l,c){if(e==null)q_(t,a,n,r,o,s,i,l,c);else{if(o&&o.deps>0&&!e.suspense.isInFallback){t.suspense=e.suspense,t.suspense.vnode=t,t.el=e.el;return}W_(e,t,a,n,r,s,i,l,c)}},hydrate:Z_,normalize:K_},z_=U_;function Ti(e,t){const a=e.props&&e.props[t];gt(a)&&a()}function q_(e,t,a,n,r,o,s,i,l){const{p:c,o:{createElement:d}}=l,u=d("div"),h=e.suspense=i3(e,r,n,t,u,a,o,s,i,l);c(null,h.pendingBranch=e.ssContent,u,null,n,h,o,s),h.deps>0?(Ti(e,"onPending"),Ti(e,"onFallback"),c(null,e.ssFallback,t,a,n,null,o,s),fs(h,e.ssFallback)):h.resolve(!1,!0)}function W_(e,t,a,n,r,o,s,i,{p:l,um:c,o:{createElement:d}}){const u=t.suspense=e.suspense;u.vnode=t,t.el=e.el;const h=t.ssContent,f=t.ssFallback,{activeBranch:m,pendingBranch:g,isInFallback:_,isHydrating:b}=u;if(g)u.pendingBranch=h,Rn(h,g)?(l(g,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0?u.resolve():_&&(b||(l(m,f,a,n,r,null,o,s,i),fs(u,f)))):(u.pendingId=vc++,b?(u.isHydrating=!1,u.activeBranch=g):c(g,r,u),u.deps=0,u.effects.length=0,u.hiddenContainer=d("div"),_?(l(null,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0?u.resolve():(l(m,f,a,n,r,null,o,s,i),fs(u,f))):m&&Rn(h,m)?(l(m,h,a,n,r,u,o,s,i),u.resolve(!0)):(l(null,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0&&u.resolve()));else if(m&&Rn(h,m))l(m,h,a,n,r,u,o,s,i),fs(u,h);else if(Ti(t,"onPending"),u.pendingBranch=h,h.shapeFlag&512?u.pendingId=h.component.suspenseId:u.pendingId=vc++,l(null,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0)u.resolve();else{const{timeout:v,pendingId:y}=u;v>0?setTimeout(()=>{u.pendingId===y&&u.fallback(f)},v):v===0&&u.fallback(f)}}function i3(e,t,a,n,r,o,s,i,l,c,d=!1){const{p:u,m:h,um:f,n:m,o:{parentNode:g,remove:_}}=c;let b;const v=G_(e);v&&t&&t.pendingBranch&&(b=t.pendingId,t.deps++);const y=e.props?q1(e.props.timeout):void 0,M=o,x={vnode:e,parent:t,parentComponent:a,namespace:s,container:n,hiddenContainer:r,deps:0,pendingId:vc++,timeout:typeof y=="number"?y:-1,activeBranch:null,pendingBranch:null,isInFallback:!d,isHydrating:d,isUnmounted:!1,effects:[],resolve(S=!1,L=!1){const{vnode:F,activeBranch:te,pendingBranch:J,pendingId:be,effects:oe,parentComponent:Te,container:Ue}=x;let Ze=!1;x.isHydrating?x.isHydrating=!1:S||(Ze=te&&J.transition&&J.transition.mode==="out-in",Ze&&(te.transition.afterLeave=()=>{be===x.pendingId&&(h(J,Ue,o===M?m(te):o,0),Si(oe))}),te&&(g(te.el)===Ue&&(o=m(te)),f(te,Te,x,!0)),Ze||h(J,Ue,o,0)),fs(x,J),x.pendingBranch=null,x.isInFallback=!1;let Me=x.parent,ee=!1;for(;Me;){if(Me.pendingBranch){Me.effects.push(...oe),ee=!0;break}Me=Me.parent}!ee&&!Ze&&Si(oe),x.effects=[],v&&t&&t.pendingBranch&&b===t.pendingId&&(t.deps--,t.deps===0&&!L&&t.resolve()),Ti(F,"onResolve")},fallback(S){if(!x.pendingBranch)return;const{vnode:L,activeBranch:F,parentComponent:te,container:J,namespace:be}=x;Ti(L,"onFallback");const oe=m(F),Te=()=>{x.isInFallback&&(u(null,S,J,oe,te,null,be,i,l),fs(x,S))},Ue=S.transition&&S.transition.mode==="out-in";Ue&&(F.transition.afterLeave=Te),x.isInFallback=!0,f(F,te,null,!0),Ue||Te()},move(S,L,F){x.activeBranch&&h(x.activeBranch,S,L,F),x.container=S},next(){return x.activeBranch&&m(x.activeBranch)},registerDep(S,L,F){const te=!!x.pendingBranch;te&&x.deps++;const J=S.vnode.el;S.asyncDep.catch(be=>{Oo(be,S,0)}).then(be=>{if(S.isUnmounted||x.isUnmounted||x.pendingId!==S.suspenseId)return;S.asyncResolved=!0;const{vnode:oe}=S;_c(S,be,!1),J&&(oe.el=J);const Te=!J&&S.subTree.el;L(S,oe,g(J||S.subTree.el),J?null:m(S.subTree),x,s,F),Te&&_(Te),Ll(S,oe.el),te&&--x.deps===0&&x.resolve()})},unmount(S,L){x.isUnmounted=!0,x.activeBranch&&f(x.activeBranch,a,S,L),x.pendingBranch&&f(x.pendingBranch,a,S,L)}};return x}function Z_(e,t,a,n,r,o,s,i,l){const c=t.suspense=i3(t,n,a,e.parentNode,document.createElement("div"),null,r,o,s,i,!0),d=l(e,c.pendingBranch=t.ssContent,a,c,o,s);return c.deps===0&&c.resolve(!1,!0),d}function K_(e){const{shapeFlag:t,children:a}=e,n=t&32;e.ssContent=lh(n?a.default:a),e.ssFallback=n?lh(a.fallback):Ce(_a)}function lh(e){let t;if(gt(e)){const a=Eo&&e._c;a&&(e._d=!1,$()),e=e(),a&&(e._d=!0,t=za,c3())}return st(e)&&(e=D_(e)),e=nn(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(a=>a!==e)),e}function l3(e,t){t&&t.pendingBranch?st(e)?t.effects.push(...e):t.effects.push(e):Si(e)}function fs(e,t){e.activeBranch=t;const{vnode:a,parentComponent:n}=e;let r=t.el;for(;!r&&t.component;)t=t.component.subTree,r=t.el;a.el=r,n&&n.subTree===a&&(n.vnode.el=r,Ll(n,r))}function G_(e){const t=e.props&&e.props.suspensible;return t!=null&&t!==!1}const Je=Symbol.for("v-fgt"),Xr=Symbol.for("v-txt"),_a=Symbol.for("v-cmt"),$o=Symbol.for("v-stc"),pi=[];let za=null;function $(e=!1){pi.push(za=e?null:[])}function c3(){pi.pop(),za=pi[pi.length-1]||null}let Eo=1;function gc(e,t=!1){Eo+=e,e<0&&za&&t&&(za.hasOnce=!0)}function d3(e){return e.dynamicChildren=Eo>0?za||cs:null,c3(),Eo>0&&za&&za.push(e),e}function R(e,t,a,n,r,o){return d3(Z(e,t,a,n,r,o,!0))}function Ie(e,t,a,n,r){return d3(Ce(e,t,a,n,r,!0))}function Ar(e){return e?e.__v_isVNode===!0:!1}function Rn(e,t){return e.type===t.type&&e.key===t.key}function J_(e){}const u3=({key:e})=>e??null,H1=({ref:e,ref_key:t,ref_for:a})=>(typeof e=="number"&&(e=""+e),e!=null?sa(e)||ba(e)||gt(e)?{i:Ea,r:e,k:t,f:!!a}:e:null);function Z(e,t=null,a=null,n=0,r=null,o=e===Je?0:1,s=!1,i=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&u3(t),ref:t&&H1(t),scopeId:El,slotScopeIds:null,children:a,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:n,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:Ea};return i?(f0(l,a),o&128&&e.normalize(l)):a&&(l.shapeFlag|=sa(a)?8:16),Eo>0&&!s&&za&&(l.patchFlag>0||o&6)&&l.patchFlag!==32&&za.push(l),l}const Ce=X_;function X_(e,t=null,a=null,n=0,r=null,o=!1){if((!e||e===Ov)&&(e=_a),Ar(e)){const i=nr(e,t,!0);return a&&f0(i,a),Eo>0&&!o&&za&&(i.shapeFlag&6?za[za.indexOf(e)]=i:za.push(i)),i.patchFlag=-2,i}if(ob(e)&&(e=e.__vccOpts),t){t=h3(t);let{class:i,style:l}=t;i&&!sa(i)&&(t.class=ft(i)),ea(l)&&($l(l)&&!st(l)&&(l=aa({},l)),t.style=bt(l))}const s=sa(e)?1:Y1(e)?128:yv(e)?64:ea(e)?4:gt(e)?2:0;return Z(e,t,a,n,r,s,o,!0)}function h3(e){return e?$l(e)||Uv(e)?aa({},e):e:null}function nr(e,t,a=!1,n=!1){const{props:r,ref:o,patchFlag:s,children:i,transition:l}=e,c=t?Bi(r||{},t):r,d={__v_isVNode:!0,__v_skip:!0,type:e.type,props:c,key:c&&u3(c),ref:t&&t.ref?a&&o?st(o)?o.concat(H1(t)):[o,H1(t)]:H1(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Je?s===-1?16:s|16:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&nr(e.ssContent),ssFallback:e.ssFallback&&nr(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&n&&Cr(d,l.clone(d)),d}function pa(e=" ",t=0){return Ce(Xr,null,e,t)}function Y_(e,t){const a=Ce($o,null,e);return a.staticCount=t,a}function ge(e="",t=!1){return t?($(),Ie(_a,null,e)):Ce(_a,null,e)}function nn(e){return e==null||typeof e=="boolean"?Ce(_a):st(e)?Ce(Je,null,e.slice()):Ar(e)?qr(e):Ce(Xr,null,String(e))}function qr(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:nr(e)}function f0(e,t){let a=0;const{shapeFlag:n}=e;if(t==null)t=null;else if(st(t))a=16;else if(typeof t=="object")if(n&65){const r=t.default;r&&(r._c&&(r._d=!1),f0(e,r()),r._c&&(r._d=!0));return}else{a=32;const r=t._;!r&&!Uv(t)?t._ctx=Ea:r===3&&Ea&&(Ea.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else gt(t)?(t={default:t,_ctx:Ea},a=32):(t=String(t),n&64?(a=16,t=[pa(t)]):a=8);e.children=t,e.shapeFlag|=a}function Bi(...e){const t={};for(let a=0;a<e.length;a++){const n=e[a];for(const r in n)if(r==="class")t.class!==n.class&&(t.class=ft([t.class,n.class]));else if(r==="style")t.style=bt([t.style,n.style]);else if(Oi(r)){const o=t[r],s=n[r];s&&o!==s&&!(st(o)&&o.includes(s))&&(t[r]=o?[].concat(o,s):s)}else r!==""&&(t[r]=n[r])}return t}function tn(e,t,a,n=null){$n(e,t,7,[a,n])}const Q_=Dv();let eb=0;function p3(e,t,a){const n=e.type,r=(t?t.appContext:e.appContext)||Q_,o={uid:eb++,vnode:e,type:n,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Jc(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:qv(n,r),emitsOptions:s3(n,r),emit:null,emitted:null,propsDefaults:Nt,inheritAttrs:n.inheritAttrs,ctx:Nt,data:Nt,props:Nt,attrs:Nt,slots:Nt,refs:Nt,setupState:Nt,setupContext:null,suspense:a,suspenseId:a?a.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=N_.bind(null,o),e.ce&&e.ce(o),o}let $a=null;const gn=()=>$a||Ea;let Q1,yc;{const e=_l(),t=(a,n)=>{let r;return(r=e[a])||(r=e[a]=[]),r.push(n),o=>{r.length>1?r.forEach(s=>s(o)):r[0](o)}};Q1=t("__VUE_INSTANCE_SETTERS__",a=>$a=a),yc=t("__VUE_SSR_SETTERS__",a=>Ms=a)}const Io=e=>{const t=$a;return Q1(e),e.scope.on(),()=>{e.scope.off(),Q1(t)}},Mc=()=>{$a&&$a.scope.off(),Q1(null)};function f3(e){return e.vnode.shapeFlag&4}let Ms=!1;function m3(e,t=!1,a=!1){t&&yc(t);const{props:n,children:r}=e.vnode,o=f3(e);E_(e,n,o,t),P_(e,r,a);const s=o?tb(e,t):void 0;return t&&yc(!1),s}function tb(e,t){const a=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,hc);const{setup:n}=a;if(n){ro();const r=e.setupContext=n.length>1?g3(e):null,o=Io(e),s=Is(n,e,0,[e.props,r]),i=Kc(s);if(oo(),o(),(i||e.sp)&&!Jr(e)&&s0(e),i){if(s.then(Mc,Mc),t)return s.then(l=>{_c(e,l,t)}).catch(l=>{Oo(l,e,0)});e.asyncDep=s}else _c(e,s,t)}else v3(e,t)}function _c(e,t,a){gt(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ea(t)&&(e.setupState=t0(t)),v3(e,a)}let el,bc;function ab(e){el=e,bc=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,i_))}}const nb=()=>!el;function v3(e,t,a){const n=e.type;if(!e.render){if(!t&&el&&!n.render){const r=n.template||u0(e).template;if(r){const{isCustomElement:o,compilerOptions:s}=e.appContext.config,{delimiters:i,compilerOptions:l}=n,c=aa(aa({isCustomElement:o,delimiters:i},s),l);n.render=el(r,c)}}e.render=n.render||Cn,bc&&bc(e)}{const r=Io(e);ro();try{__(e)}finally{oo(),r()}}}const rb={get(e,t){return ja(e,"get",""),e[t]}};function g3(e){const t=a=>{e.exposed=a||{}};return{attrs:new Proxy(e.attrs,rb),slots:e.slots,emit:e.emit,expose:t}}function Fi(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(t0(iv(e.exposed)),{get(t,a){if(a in t)return t[a];if(a in hi)return hi[a](e)},has(t,a){return a in t||a in hi}})):e.proxy}function wc(e,t=!0){return gt(e)?e.displayName||e.name:e.name||t&&e.__name}function ob(e){return gt(e)&&"__vccOpts"in e}const H=(e,t)=>AM(e,t,Ms);function En(e,t,a){const n=arguments.length;return n===2?ea(t)&&!st(t)?Ar(t)?Ce(e,null,[t]):Ce(e,t):Ce(e,null,t):(n>3?a=Array.prototype.slice.call(arguments,2):n===3&&Ar(a)&&(a=[a]),Ce(e,t,a))}function sb(){}function ib(e,t,a,n){const r=a[n];if(r&&y3(r,e))return r;const o=t();return o.memo=e.slice(),o.cacheIndex=n,a[n]=o}function y3(e,t){const a=e.memo;if(a.length!=t.length)return!1;for(let n=0;n<a.length;n++)if(Ja(a[n],t[n]))return!1;return Eo>0&&za&&za.push(e),!0}const M3="3.5.13",lb=Cn,cb=VM,db=rs,ub=vv,hb={createComponentInstance:p3,setupComponent:m3,renderComponentRoot:O1,setCurrentRenderingInstance:Ei,isVNode:Ar,normalizeVNode:nn,getComponentPublicInstance:Fi,ensureValidVNode:d0,pushWarningContext:kM,popWarningContext:TM},pb=hb,fb=null,mb=null,vb=null;/**
19
+ **/const hv=[];function kM(e){hv.push(e)}function TM(){hv.pop()}function PM(e,t){}const LM={SETUP_FUNCTION:0,0:"SETUP_FUNCTION",RENDER_FUNCTION:1,1:"RENDER_FUNCTION",NATIVE_EVENT_HANDLER:5,5:"NATIVE_EVENT_HANDLER",COMPONENT_EVENT_HANDLER:6,6:"COMPONENT_EVENT_HANDLER",VNODE_HOOK:7,7:"VNODE_HOOK",DIRECTIVE_HOOK:8,8:"DIRECTIVE_HOOK",TRANSITION_HOOK:9,9:"TRANSITION_HOOK",APP_ERROR_HANDLER:10,10:"APP_ERROR_HANDLER",APP_WARN_HANDLER:11,11:"APP_WARN_HANDLER",FUNCTION_REF:12,12:"FUNCTION_REF",ASYNC_COMPONENT_LOADER:13,13:"ASYNC_COMPONENT_LOADER",SCHEDULER:14,14:"SCHEDULER",COMPONENT_UPDATE:15,15:"COMPONENT_UPDATE",APP_UNMOUNT_CLEANUP:16,16:"APP_UNMOUNT_CLEANUP"},VM={sp:"serverPrefetch hook",bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush",15:"component update",16:"app unmount cleanup function"};function ks(e,t,a,n){try{return n?e(...n):e()}catch(r){Ho(r,t,a)}}function $n(e,t,a,n){if(gt(e)){const r=ks(e,t,a,n);return r&&Kc(r)&&r.catch(o=>{Ho(o,t,a)}),r}if(st(e)){const r=[];for(let o=0;o<e.length;o++)r.push($n(e[o],t,a,n));return r}}function Ho(e,t,a,n=!0){const r=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||Nt;if(t){let i=t.parent;const l=t.proxy,c=`https://vuejs.org/error-reference/#runtime-${a}`;for(;i;){const d=i.ec;if(d){for(let u=0;u<d.length;u++)if(d[u](e,l,c)===!1)return}i=i.parent}if(o){oo(),ks(o,null,10,[e,l,c]),so();return}}OM(e,a,r,n,s)}function OM(e,t,a,n=!0,r=!1){if(r)throw e;console.error(e)}const Xa=[];let Xn=-1;const fs=[];let zr=null,rs=0;const pv=Promise.resolve();let K1=null;function qa(e){const t=K1||pv;return e?t.then(this?e.bind(this):e):t}function HM(e){let t=Xn+1,a=Xa.length;for(;t<a;){const n=t+a>>>1,r=Xa[n],o=$i(r);o<e||o===e&&r.flags&2?t=n+1:a=n}return t}function n0(e){if(!(e.flags&1)){const t=$i(e),a=Xa[Xa.length-1];!a||!(e.flags&2)&&t>=$i(a)?Xa.push(e):Xa.splice(HM(t),0,e),e.flags|=1,fv()}}function fv(){K1||(K1=pv.then(mv))}function Si(e){st(e)?fs.push(...e):zr&&e.id===-1?zr.splice(rs+1,0,e):e.flags&1||(fs.push(e),e.flags|=1),fv()}function Gu(e,t,a=Xn+1){for(;a<Xa.length;a++){const n=Xa[a];if(n&&n.flags&2){if(e&&n.id!==e.uid)continue;Xa.splice(a,1),a--,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function G1(e){if(fs.length){const t=[...new Set(fs)].sort((a,n)=>$i(a)-$i(n));if(fs.length=0,zr){zr.push(...t);return}for(zr=t,rs=0;rs<zr.length;rs++){const a=zr[rs];a.flags&4&&(a.flags&=-2),a.flags&8||a(),a.flags&=-2}zr=null,rs=0}}const $i=e=>e.id==null?e.flags&2?-1:1/0:e.id;function mv(e){try{for(Xn=0;Xn<Xa.length;Xn++){const t=Xa[Xn];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),ks(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Xn<Xa.length;Xn++){const t=Xa[Xn];t&&(t.flags&=-2)}Xn=-1,Xa.length=0,G1(),K1=null,(Xa.length||fs.length)&&mv()}}let os,d1=[];function vv(e,t){var a,n;os=e,os?(os.enabled=!0,d1.forEach(({event:r,args:o})=>os.emit(r,...o)),d1=[]):typeof window<"u"&&window.HTMLElement&&!((n=(a=window.navigator)==null?void 0:a.userAgent)!=null&&n.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(o=>{vv(o,t)}),setTimeout(()=>{os||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,d1=[])},3e3)):d1=[]}let Ea=null,El=null;function Ei(e){const t=Ea;return Ea=e,El=e&&e.type.__scopeId||null,t}function RM(e){El=e}function NM(){El=null}const DM=e=>Xe;function Xe(e,t=Ea,a){if(!t||e._n)return e;const n=(...r)=>{n._d&&gc(-1);const o=Ei(t);let s;try{s=e(...r)}finally{Ei(o),n._d&&gc(1)}return s};return n._n=!0,n._c=!0,n._d=!0,n}function Ya(e,t){if(Ea===null)return e;const a=Fi(Ea),n=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[o,s,i,l=Nt]=t[r];o&&(gt(o)&&(o={mounted:o,updated:o}),o.deep&&br(s),n.push({dir:o,instance:a,value:s,oldValue:void 0,arg:i,modifiers:l}))}return e}function Yn(e,t,a,n){const r=e.dirs,o=t&&t.dirs;for(let s=0;s<r.length;s++){const i=r[s];o&&(i.oldValue=o[s].value);let l=i.dir[n];l&&(oo(),$n(l,a,8,[e.el,i,e,t]),so())}}const gv=Symbol("_vte"),yv=e=>e.__isTeleport,ui=e=>e&&(e.disabled||e.disabled===""),Ju=e=>e&&(e.defer||e.defer===""),Xu=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Yu=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,dc=(e,t)=>{const a=e&&e.to;return sa(a)?t?t(a):null:a},Mv={name:"Teleport",__isTeleport:!0,process(e,t,a,n,r,o,s,i,l,c){const{mc:d,pc:u,pbc:h,o:{insert:f,querySelector:m,createText:g,createComment:_}}=c,b=ui(t.props);let{shapeFlag:v,children:y,dynamicChildren:M}=t;if(e==null){const x=t.el=g(""),S=t.anchor=g("");f(x,a,n),f(S,a,n);const L=(te,J)=>{v&16&&(r&&r.isCE&&(r.ce._teleportTarget=te),d(y,te,J,r,o,s,i,l))},F=()=>{const te=t.target=dc(t.props,m),J=bv(te,t,g,f);te&&(s!=="svg"&&Xu(te)?s="svg":s!=="mathml"&&Yu(te)&&(s="mathml"),b||(L(te,J),V1(t,!1)))};b&&(L(a,S),V1(t,!0)),Ju(t.props)?Aa(()=>{F(),t.el.__isMounted=!0},o):F()}else{if(Ju(t.props)&&!e.el.__isMounted){Aa(()=>{Mv.process(e,t,a,n,r,o,s,i,l,c),delete e.el.__isMounted},o);return}t.el=e.el,t.targetStart=e.targetStart;const x=t.anchor=e.anchor,S=t.target=e.target,L=t.targetAnchor=e.targetAnchor,F=ui(e.props),te=F?a:S,J=F?x:L;if(s==="svg"||Xu(S)?s="svg":(s==="mathml"||Yu(S))&&(s="mathml"),M?(h(e.dynamicChildren,M,te,r,o,s,i),p0(e,t,!0)):l||u(e,t,te,J,r,o,s,i,!1),b)F?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):u1(t,a,x,c,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const be=t.target=dc(t.props,m);be&&u1(t,be,null,c,0)}else F&&u1(t,S,L,c,1);V1(t,b)}},remove(e,t,a,{um:n,o:{remove:r}},o){const{shapeFlag:s,children:i,anchor:l,targetStart:c,targetAnchor:d,target:u,props:h}=e;if(u&&(r(c),r(d)),o&&r(l),s&16){const f=o||!ui(h);for(let m=0;m<i.length;m++){const g=i[m];n(g,t,a,f,!!g.dynamicChildren)}}},move:u1,hydrate:BM};function u1(e,t,a,{o:{insert:n},m:r},o=2){o===0&&n(e.targetAnchor,t,a);const{el:s,anchor:i,shapeFlag:l,children:c,props:d}=e,u=o===2;if(u&&n(s,t,a),(!u||ui(d))&&l&16)for(let h=0;h<c.length;h++)r(c[h],t,a,2);u&&n(i,t,a)}function BM(e,t,a,n,r,o,{o:{nextSibling:s,parentNode:i,querySelector:l,insert:c,createText:d}},u){const h=t.target=dc(t.props,l);if(h){const f=ui(t.props),m=h._lpa||h.firstChild;if(t.shapeFlag&16)if(f)t.anchor=u(s(e),t,i(e),a,n,r,o),t.targetStart=m,t.targetAnchor=m&&s(m);else{t.anchor=s(e);let g=m;for(;g;){if(g&&g.nodeType===8){if(g.data==="teleport start anchor")t.targetStart=g;else if(g.data==="teleport anchor"){t.targetAnchor=g,h._lpa=t.targetAnchor&&s(t.targetAnchor);break}}g=s(g)}t.targetAnchor||bv(h,t,d,c),u(m&&s(m),t,h,a,n,r,o)}V1(t,f)}return t.anchor&&s(t.anchor)}const _v=Mv;function V1(e,t){const a=e.ctx;if(a&&a.ut){let n,r;for(t?(n=e.el,r=e.anchor):(n=e.targetStart,r=e.targetAnchor);n&&n!==r;)n.nodeType===1&&n.setAttribute("data-v-owner",a.uid),n=n.nextSibling;a.ut()}}function bv(e,t,a,n){const r=t.targetStart=a(""),o=t.targetAnchor=a("");return r[gv]=o,e&&(n(r,e),n(o,e)),o}const qr=Symbol("_leaveCb"),h1=Symbol("_enterCb");function r0(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return ia(()=>{e.isMounted=!0}),kr(()=>{e.isUnmounting=!0}),e}const Mn=[Function,Array],o0={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Mn,onEnter:Mn,onAfterEnter:Mn,onEnterCancelled:Mn,onBeforeLeave:Mn,onLeave:Mn,onAfterLeave:Mn,onLeaveCancelled:Mn,onBeforeAppear:Mn,onAppear:Mn,onAfterAppear:Mn,onAppearCancelled:Mn},wv=e=>{const t=e.subTree;return t.component?wv(t.component):t},FM={name:"BaseTransition",props:o0,setup(e,{slots:t}){const a=gn(),n=r0();return()=>{const r=t.default&&Il(t.default(),!0);if(!r||!r.length)return;const o=xv(r),s=St(e),{mode:i}=s;if(n.isLeaving)return $2(o);const l=Qu(o);if(!l)return $2(o);let c=Ms(l,s,n,a,u=>c=u);l.type!==_a&&Ar(l,c);let d=a.subTree&&Qu(a.subTree);if(d&&d.type!==_a&&!Nn(l,d)&&wv(a).type!==_a){let u=Ms(d,s,n,a);if(Ar(d,u),i==="out-in"&&l.type!==_a)return n.isLeaving=!0,u.afterLeave=()=>{n.isLeaving=!1,a.job.flags&8||a.update(),delete u.afterLeave,d=void 0},$2(o);i==="in-out"&&l.type!==_a?u.delayLeave=(h,f,m)=>{const g=Av(n,d);g[String(d.key)]=d,h[qr]=()=>{f(),h[qr]=void 0,delete c.delayedLeave,d=void 0},c.delayedLeave=()=>{m(),delete c.delayedLeave,d=void 0}}:d=void 0}else d&&(d=void 0);return o}}};function xv(e){let t=e[0];if(e.length>1){for(const a of e)if(a.type!==_a){t=a;break}}return t}const Cv=FM;function Av(e,t){const{leavingVNodes:a}=e;let n=a.get(t.type);return n||(n=Object.create(null),a.set(t.type,n)),n}function Ms(e,t,a,n,r){const{appear:o,mode:s,persisted:i=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:d,onEnterCancelled:u,onBeforeLeave:h,onLeave:f,onAfterLeave:m,onLeaveCancelled:g,onBeforeAppear:_,onAppear:b,onAfterAppear:v,onAppearCancelled:y}=t,M=String(e.key),x=Av(a,e),S=(te,J)=>{te&&$n(te,n,9,J)},L=(te,J)=>{const be=J[1];S(te,J),st(te)?te.every(oe=>oe.length<=1)&&be():te.length<=1&&be()},F={mode:s,persisted:i,beforeEnter(te){let J=l;if(!a.isMounted)if(o)J=_||l;else return;te[qr]&&te[qr](!0);const be=x[M];be&&Nn(e,be)&&be.el[qr]&&be.el[qr](),S(J,[te])},enter(te){let J=c,be=d,oe=u;if(!a.isMounted)if(o)J=b||c,be=v||d,oe=y||u;else return;let Te=!1;const Ue=te[h1]=Ze=>{Te||(Te=!0,Ze?S(oe,[te]):S(be,[te]),F.delayedLeave&&F.delayedLeave(),te[h1]=void 0)};J?L(J,[te,Ue]):Ue()},leave(te,J){const be=String(e.key);if(te[h1]&&te[h1](!0),a.isUnmounting)return J();S(h,[te]);let oe=!1;const Te=te[qr]=Ue=>{oe||(oe=!0,J(),Ue?S(g,[te]):S(m,[te]),te[qr]=void 0,x[be]===e&&delete x[be])};x[be]=e,f?L(f,[te,Te]):Te()},clone(te){const J=Ms(te,t,a,n,r);return r&&r(J),J}};return F}function $2(e){if(Ni(e))return e=rr(e),e.children=null,e}function Qu(e){if(!Ni(e))return yv(e.type)&&e.children?xv(e.children):e;const{shapeFlag:t,children:a}=e;if(a){if(t&16)return a[0];if(t&32&&gt(a.default))return a.default()}}function Ar(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Ar(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Il(e,t=!1,a){let n=[],r=0;for(let o=0;o<e.length;o++){let s=e[o];const i=a==null?s.key:String(a)+String(s.key!=null?s.key:o);s.type===Je?(s.patchFlag&128&&r++,n=n.concat(Il(s.children,t,i))):(t||s.type!==_a)&&n.push(i!=null?rr(s,{key:i}):s)}if(r>1)for(let o=0;o<n.length;o++)n[o].patchFlag=-2;return n}/*! #__NO_SIDE_EFFECTS__ */function $e(e,t){return gt(e)?na({name:e.name},t,{setup:e}):e}function Sv(){const e=gn();return e?(e.appContext.config.idPrefix||"v")+"-"+e.ids[0]+e.ids[1]++:""}function s0(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function pt(e){const t=gn(),a=$t(null);if(t){const r=t.refs===Nt?t.refs={}:t.refs;Object.defineProperty(r,e,{enumerable:!0,get:()=>a.value,set:o=>a.value=o})}return a}function Ii(e,t,a,n,r=!1){if(st(e)){e.forEach((m,g)=>Ii(m,t&&(st(t)?t[g]:t),a,n,r));return}if(Xr(n)&&!r){n.shapeFlag&512&&n.type.__asyncResolved&&n.component.subTree.component&&Ii(e,t,a,n.component.subTree);return}const o=n.shapeFlag&4?Fi(n.component):n.el,s=r?null:o,{i,r:l}=e,c=t&&t.r,d=i.refs===Nt?i.refs={}:i.refs,u=i.setupState,h=St(u),f=u===Nt?()=>!1:m=>Kt(h,m);if(c!=null&&c!==l&&(sa(c)?(d[c]=null,f(c)&&(u[c]=null)):ba(c)&&(c.value=null)),gt(l))ks(l,i,12,[s,d]);else{const m=sa(l),g=ba(l);if(m||g){const _=()=>{if(e.f){const b=m?f(l)?u[l]:d[l]:l.value;r?st(b)&&Zc(b,o):st(b)?b.includes(o)||b.push(o):m?(d[l]=[o],f(l)&&(u[l]=d[l])):(l.value=[o],e.k&&(d[e.k]=l.value))}else m?(d[l]=s,f(l)&&(u[l]=s)):g&&(l.value=s,e.k&&(d[e.k]=s))};s?(_.id=-1,Aa(_,a)):_()}}}let eh=!1;const ts=()=>{eh||(console.error("Hydration completed but contains mismatches."),eh=!0)},jM=e=>e.namespaceURI.includes("svg")&&e.tagName!=="foreignObject",UM=e=>e.namespaceURI.includes("MathML"),p1=e=>{if(e.nodeType===1){if(jM(e))return"svg";if(UM(e))return"mathml"}},is=e=>e.nodeType===8;function zM(e){const{mt:t,p:a,o:{patchProp:n,createText:r,nextSibling:o,parentNode:s,remove:i,insert:l,createComment:c}}=e,d=(y,M)=>{if(!M.hasChildNodes()){a(null,y,M),G1(),M._vnode=y;return}u(M.firstChild,y,null,null,null),G1(),M._vnode=y},u=(y,M,x,S,L,F=!1)=>{F=F||!!M.dynamicChildren;const te=is(y)&&y.data==="[",J=()=>g(y,M,x,S,L,te),{type:be,ref:oe,shapeFlag:Te,patchFlag:Ue}=M;let Ze=y.nodeType;M.el=y,Ue===-2&&(F=!1,M.dynamicChildren=null);let Me=null;switch(be){case Yr:Ze!==3?M.children===""?(l(M.el=r(""),s(y),y),Me=y):Me=J():(y.data!==M.children&&(ts(),y.data=M.children),Me=o(y));break;case _a:v(y)?(Me=o(y),b(M.el=y.content.firstChild,y,x)):Ze!==8||te?Me=J():Me=o(y);break;case Eo:if(te&&(y=o(y),Ze=y.nodeType),Ze===1||Ze===3){Me=y;const ee=!M.children.length;for(let j=0;j<M.staticCount;j++)ee&&(M.children+=Me.nodeType===1?Me.outerHTML:Me.data),j===M.staticCount-1&&(M.anchor=Me),Me=o(Me);return te?o(Me):Me}else J();break;case Je:te?Me=m(y,M,x,S,L,F):Me=J();break;default:if(Te&1)(Ze!==1||M.type.toLowerCase()!==y.tagName.toLowerCase())&&!v(y)?Me=J():Me=h(y,M,x,S,L,F);else if(Te&6){M.slotScopeIds=L;const ee=s(y);if(te?Me=_(y):is(y)&&y.data==="teleport start"?Me=_(y,y.data,"teleport end"):Me=o(y),t(M,ee,null,x,S,p1(ee),F),Xr(M)&&!M.type.__asyncResolved){let j;te?(j=Ce(Je),j.anchor=Me?Me.previousSibling:ee.lastChild):j=y.nodeType===3?pa(""):Ce("div"),j.el=y,M.component.subTree=j}}else Te&64?Ze!==8?Me=J():Me=M.type.hydrate(y,M,x,S,L,F,e,f):Te&128&&(Me=M.type.hydrate(y,M,x,S,p1(s(y)),L,F,e,u))}return oe!=null&&Ii(oe,null,S,M),Me},h=(y,M,x,S,L,F)=>{F=F||!!M.dynamicChildren;const{type:te,props:J,patchFlag:be,shapeFlag:oe,dirs:Te,transition:Ue}=M,Ze=te==="input"||te==="option";if(Ze||be!==-1){Te&&Yn(M,null,x,"created");let Me=!1;if(v(y)){Me=Qv(null,Ue)&&x&&x.vnode.props&&x.vnode.props.appear;const j=y.content.firstChild;Me&&Ue.beforeEnter(j),b(j,y,x),M.el=y=j}if(oe&16&&!(J&&(J.innerHTML||J.textContent))){let j=f(y.firstChild,M,y,x,S,L,F);for(;j;){f1(y,1)||ts();const K=j;j=j.nextSibling,i(K)}}else if(oe&8){let j=M.children;j[0]===`
20
+ `&&(y.tagName==="PRE"||y.tagName==="TEXTAREA")&&(j=j.slice(1)),y.textContent!==j&&(f1(y,0)||ts(),y.textContent=M.children)}if(J){if(Ze||!F||be&48){const j=y.tagName.includes("-");for(const K in J)(Ze&&(K.endsWith("value")||K==="indeterminate")||Oi(K)&&!hs(K)||K[0]==="."||j)&&n(y,K,null,J[K],void 0,x)}else if(J.onClick)n(y,"onClick",null,J.onClick,void 0,x);else if(be&4&&Jr(J.style))for(const j in J.style)J.style[j]}let ee;(ee=J&&J.onVnodeBeforeMount)&&tn(ee,x,M),Te&&Yn(M,null,x,"beforeMount"),((ee=J&&J.onVnodeMounted)||Te||Me)&&l3(()=>{ee&&tn(ee,x,M),Me&&Ue.enter(y),Te&&Yn(M,null,x,"mounted")},S)}return y.nextSibling},f=(y,M,x,S,L,F,te)=>{te=te||!!M.dynamicChildren;const J=M.children,be=J.length;for(let oe=0;oe<be;oe++){const Te=te?J[oe]:J[oe]=nn(J[oe]),Ue=Te.type===Yr;y?(Ue&&!te&&oe+1<be&&nn(J[oe+1]).type===Yr&&(l(r(y.data.slice(Te.children.length)),x,o(y)),y.data=Te.children),y=u(y,Te,S,L,F,te)):Ue&&!Te.children?l(Te.el=r(""),x):(f1(x,1)||ts(),a(null,Te,x,null,S,L,p1(x),F))}return y},m=(y,M,x,S,L,F)=>{const{slotScopeIds:te}=M;te&&(L=L?L.concat(te):te);const J=s(y),be=f(o(y),M,J,x,S,L,F);return be&&is(be)&&be.data==="]"?o(M.anchor=be):(ts(),l(M.anchor=c("]"),J,be),be)},g=(y,M,x,S,L,F)=>{if(f1(y.parentElement,1)||ts(),M.el=null,F){const be=_(y);for(;;){const oe=o(y);if(oe&&oe!==be)i(oe);else break}}const te=o(y),J=s(y);return i(y),a(null,M,J,te,x,S,p1(J),L),x&&(x.vnode.el=M.el,Ll(x,M.el)),te},_=(y,M="[",x="]")=>{let S=0;for(;y;)if(y=o(y),y&&is(y)&&(y.data===M&&S++,y.data===x)){if(S===0)return o(y);S--}return y},b=(y,M,x)=>{const S=M.parentNode;S&&S.replaceChild(y,M);let L=x;for(;L;)L.vnode.el===M&&(L.vnode.el=L.subTree.el=y),L=L.parent},v=y=>y.nodeType===1&&y.tagName==="TEMPLATE";return[d,u]}const th="data-allow-mismatch",qM={0:"text",1:"children",2:"class",3:"style",4:"attribute"};function f1(e,t){if(t===0||t===1)for(;e&&!e.hasAttribute(th);)e=e.parentElement;const a=e&&e.getAttribute(th);if(a==null)return!1;if(a==="")return!0;{const n=a.split(",");return t===0&&n.includes("children")?!0:a.split(",").includes(qM[t])}}const WM=_l().requestIdleCallback||(e=>setTimeout(e,1)),ZM=_l().cancelIdleCallback||(e=>clearTimeout(e)),KM=(e=1e4)=>t=>{const a=WM(t,{timeout:e});return()=>ZM(a)};function GM(e){const{top:t,left:a,bottom:n,right:r}=e.getBoundingClientRect(),{innerHeight:o,innerWidth:s}=window;return(t>0&&t<o||n>0&&n<o)&&(a>0&&a<s||r>0&&r<s)}const JM=e=>(t,a)=>{const n=new IntersectionObserver(r=>{for(const o of r)if(o.isIntersecting){n.disconnect(),t();break}},e);return a(r=>{if(r instanceof Element){if(GM(r))return t(),n.disconnect(),!1;n.observe(r)}}),()=>n.disconnect()},XM=e=>t=>{if(e){const a=matchMedia(e);if(a.matches)t();else return a.addEventListener("change",t,{once:!0}),()=>a.removeEventListener("change",t)}},YM=(e=[])=>(t,a)=>{sa(e)&&(e=[e]);let n=!1;const r=s=>{n||(n=!0,o(),t(),s.target.dispatchEvent(new s.constructor(s.type,s)))},o=()=>{a(s=>{for(const i of e)s.removeEventListener(i,r)})};return a(s=>{for(const i of e)s.addEventListener(i,r,{once:!0})}),o};function QM(e,t){if(is(e)&&e.data==="["){let a=1,n=e.nextSibling;for(;n;){if(n.nodeType===1){if(t(n)===!1)break}else if(is(n))if(n.data==="]"){if(--a===0)break}else n.data==="["&&a++;n=n.nextSibling}}else t(e)}const Xr=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function $v(e){gt(e)&&(e={loader:e});const{loader:t,loadingComponent:a,errorComponent:n,delay:r=200,hydrate:o,timeout:s,suspensible:i=!0,onError:l}=e;let c=null,d,u=0;const h=()=>(u++,c=null,f()),f=()=>{let m;return c||(m=c=t().catch(g=>{if(g=g instanceof Error?g:new Error(String(g)),l)return new Promise((_,b)=>{l(g,()=>_(h()),()=>b(g),u+1)});throw g}).then(g=>m!==c&&c?c:(g&&(g.__esModule||g[Symbol.toStringTag]==="Module")&&(g=g.default),d=g,g)))};return $e({name:"AsyncComponentWrapper",__asyncLoader:f,__asyncHydrate(m,g,_){const b=o?()=>{const v=o(_,y=>QM(m,y));v&&(g.bum||(g.bum=[])).push(v)}:_;d?b():f().then(()=>!g.isUnmounted&&b())},get __asyncResolved(){return d},setup(){const m=$a;if(s0(m),d)return()=>E2(d,m);const g=y=>{c=null,Ho(y,m,13,!n)};if(i&&m.suspense||_s)return f().then(y=>()=>E2(y,m)).catch(y=>(g(y),()=>n?Ce(n,{error:y}):null));const _=ye(!1),b=ye(),v=ye(!!r);return r&&setTimeout(()=>{v.value=!1},r),s!=null&&setTimeout(()=>{if(!_.value&&!b.value){const y=new Error(`Async component timed out after ${s}ms.`);g(y),b.value=y}},s),f().then(()=>{_.value=!0,m.parent&&Ni(m.parent.vnode)&&m.parent.update()}).catch(y=>{g(y),b.value=y}),()=>{if(_.value&&d)return E2(d,m);if(b.value&&n)return Ce(n,{error:b.value});if(a&&!v.value)return Ce(a)}}})}function E2(e,t){const{ref:a,props:n,children:r,ce:o}=t.vnode,s=Ce(e,n,r);return s.ref=a,s.ce=o,delete t.vnode.ce,s}const Ni=e=>e.type.__isKeepAlive,e_={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const a=gn(),n=a.ctx;if(!n.renderer)return()=>{const v=t.default&&t.default();return v&&v.length===1?v[0]:v};const r=new Map,o=new Set;let s=null;const i=a.suspense,{renderer:{p:l,m:c,um:d,o:{createElement:u}}}=n,h=u("div");n.activate=(v,y,M,x,S)=>{const L=v.component;c(v,y,M,0,i),l(L.vnode,v,y,M,L,i,x,v.slotScopeIds,S),Aa(()=>{L.isDeactivated=!1,L.a&&ps(L.a);const F=v.props&&v.props.onVnodeMounted;F&&tn(F,L.parent,v)},i)},n.deactivate=v=>{const y=v.component;X1(y.m),X1(y.a),c(v,h,null,1,i),Aa(()=>{y.da&&ps(y.da);const M=v.props&&v.props.onVnodeUnmounted;M&&tn(M,y.parent,v),y.isDeactivated=!0},i)};function f(v){I2(v),d(v,a,i,!0)}function m(v){r.forEach((y,M)=>{const x=wc(y.type);x&&!v(x)&&g(M)})}function g(v){const y=r.get(v);y&&(!s||!Nn(y,s))?f(y):s&&I2(s),r.delete(v),o.delete(v)}We(()=>[e.include,e.exclude],([v,y])=>{v&&m(M=>ni(v,M)),y&&m(M=>!ni(y,M))},{flush:"post",deep:!0});let _=null;const b=()=>{_!=null&&(Y1(a.subTree.type)?Aa(()=>{r.set(_,m1(a.subTree))},a.subTree.suspense):r.set(_,m1(a.subTree)))};return ia(b),Tl(b),kr(()=>{r.forEach(v=>{const{subTree:y,suspense:M}=a,x=m1(y);if(v.type===x.type&&v.key===x.key){I2(x);const S=x.component.da;S&&Aa(S,M);return}f(v)})}),()=>{if(_=null,!t.default)return s=null;const v=t.default(),y=v[0];if(v.length>1)return s=null,v;if(!Sr(y)||!(y.shapeFlag&4)&&!(y.shapeFlag&128))return s=null,y;let M=m1(y);if(M.type===_a)return s=null,M;const x=M.type,S=wc(Xr(M)?M.type.__asyncResolved||{}:x),{include:L,exclude:F,max:te}=e;if(L&&(!S||!ni(L,S))||F&&S&&ni(F,S))return M.shapeFlag&=-257,s=M,y;const J=M.key==null?x:M.key,be=r.get(J);return M.el&&(M=rr(M),y.shapeFlag&128&&(y.ssContent=M)),_=J,be?(M.el=be.el,M.component=be.component,M.transition&&Ar(M,M.transition),M.shapeFlag|=512,o.delete(J),o.add(J)):(o.add(J),te&&o.size>parseInt(te,10)&&g(o.values().next().value)),M.shapeFlag|=256,s=M,Y1(y.type)?y:M}}},t_=e_;function ni(e,t){return st(e)?e.some(a=>ni(a,t)):sa(e)?e.split(",").includes(t):H9(e)?(e.lastIndex=0,e.test(t)):!1}function Ev(e,t){kv(e,"a",t)}function Iv(e,t){kv(e,"da",t)}function kv(e,t,a=$a){const n=e.__wdc||(e.__wdc=()=>{let r=a;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(kl(t,n,a),a){let r=a.parent;for(;r&&r.parent;)Ni(r.parent.vnode)&&a_(n,t,a,r),r=r.parent}}function a_(e,t,a,n){const r=kl(t,e,n,!0);Zn(()=>{Zc(n[t],r)},a)}function I2(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function m1(e){return e.shapeFlag&128?e.ssContent:e}function kl(e,t,a=$a,n=!1){if(a){const r=a[e]||(a[e]=[]),o=t.__weh||(t.__weh=(...s)=>{oo();const i=ko(a),l=$n(t,a,e,s);return i(),so(),l});return n?r.unshift(o):r.push(o),o}}const Ir=e=>(t,a=$a)=>{(!_s||e==="sp")&&kl(e,(...n)=>t(...n),a)},Ts=Ir("bm"),ia=Ir("m"),i0=Ir("bu"),Tl=Ir("u"),kr=Ir("bum"),Zn=Ir("um"),Tv=Ir("sp"),Pv=Ir("rtg"),Lv=Ir("rtc");function Vv(e,t=$a){kl("ec",e,t)}const l0="components",n_="directives";function r_(e,t){return c0(l0,e,!0,t)||e}const Ov=Symbol.for("v-ndc");function Ps(e){return sa(e)?c0(l0,e,!1)||e:e||Ov}function Hv(e){return c0(n_,e)}function c0(e,t,a=!0,n=!1){const r=Ea||$a;if(r){const o=r.type;if(e===l0){const i=wc(o,!1);if(i&&(i===t||i===Da(t)||i===Hi(Da(t))))return o}const s=ah(r[e]||o[e],t)||ah(r.appContext[e],t);return!s&&n?o:s}}function ah(e,t){return e&&(e[t]||e[Da(t)]||e[Hi(Da(t))])}function Ot(e,t,a,n){let r;const o=a&&a[n],s=st(e);if(s||sa(e)){const i=s&&Jr(e);let l=!1;i&&(l=!hn(e),e=Cl(e)),r=new Array(e.length);for(let c=0,d=e.length;c<d;c++)r[c]=t(l?Ua(e[c]):e[c],c,void 0,o&&o[c])}else if(typeof e=="number"){r=new Array(e);for(let i=0;i<e;i++)r[i]=t(i+1,i,void 0,o&&o[i])}else if(ta(e))if(e[Symbol.iterator])r=Array.from(e,(i,l)=>t(i,l,void 0,o&&o[l]));else{const i=Object.keys(e);r=new Array(i.length);for(let l=0,c=i.length;l<c;l++){const d=i[l];r[l]=t(e[d],d,l,o&&o[l])}}else r=[];return a&&(a[n]=r),r}function o_(e,t){for(let a=0;a<t.length;a++){const n=t[a];if(st(n))for(let r=0;r<n.length;r++)e[n[r].name]=n[r].fn;else n&&(e[n.name]=n.key?(...r)=>{const o=n.fn(...r);return o&&(o.key=n.key),o}:n.fn)}return e}function qt(e,t,a={},n,r){if(Ea.ce||Ea.parent&&Xr(Ea.parent)&&Ea.parent.ce)return t!=="default"&&(a.name=t),$(),Ie(Je,null,[Ce("slot",a,n&&n())],64);let o=e[t];o&&o._c&&(o._d=!1),$();const s=o&&d0(o(a)),i=a.key||s&&s.key,l=Ie(Je,{key:(i&&!Fn(i)?i:`_${t}`)+(!s&&n?"_fb":"")},s||(n?n():[]),s&&e._===1?64:-2);return!r&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),o&&o._c&&(o._d=!0),l}function d0(e){return e.some(t=>Sr(t)?!(t.type===_a||t.type===Je&&!d0(t.children)):!0)?e:null}function s_(e,t){const a={};for(const n in e)a[t&&/[A-Z]/.test(n)?`on:${n}`:li(n)]=e[n];return a}const uc=e=>e?f3(e)?Fi(e):uc(e.parent):null,hi=na(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>uc(e.parent),$root:e=>uc(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>u0(e),$forceUpdate:e=>e.f||(e.f=()=>{n0(e.update)}),$nextTick:e=>e.n||(e.n=qa.bind(e.proxy)),$watch:e=>R_.bind(e)}),k2=(e,t)=>e!==Nt&&!e.__isScriptSetup&&Kt(e,t),hc={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:a,setupState:n,data:r,props:o,accessCache:s,type:i,appContext:l}=e;let c;if(t[0]!=="$"){const f=s[t];if(f!==void 0)switch(f){case 1:return n[t];case 2:return r[t];case 4:return a[t];case 3:return o[t]}else{if(k2(n,t))return s[t]=1,n[t];if(r!==Nt&&Kt(r,t))return s[t]=2,r[t];if((c=e.propsOptions[0])&&Kt(c,t))return s[t]=3,o[t];if(a!==Nt&&Kt(a,t))return s[t]=4,a[t];pc&&(s[t]=0)}}const d=hi[t];let u,h;if(d)return t==="$attrs"&&ja(e.attrs,"get",""),d(e);if((u=i.__cssModules)&&(u=u[t]))return u;if(a!==Nt&&Kt(a,t))return s[t]=4,a[t];if(h=l.config.globalProperties,Kt(h,t))return h[t]},set({_:e},t,a){const{data:n,setupState:r,ctx:o}=e;return k2(r,t)?(r[t]=a,!0):n!==Nt&&Kt(n,t)?(n[t]=a,!0):Kt(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=a,!0)},has({_:{data:e,setupState:t,accessCache:a,ctx:n,appContext:r,propsOptions:o}},s){let i;return!!a[s]||e!==Nt&&Kt(e,s)||k2(t,s)||(i=o[0])&&Kt(i,s)||Kt(n,s)||Kt(hi,s)||Kt(r.config.globalProperties,s)},defineProperty(e,t,a){return a.get!=null?e._.accessCache[t]=0:Kt(a,"value")&&this.set(e,t,a.value,null),Reflect.defineProperty(e,t,a)}},i_=na({},hc,{get(e,t){if(t!==Symbol.unscopables)return hc.get(e,t,e)},has(e,t){return t[0]!=="_"&&!F9(t)}});function l_(){return null}function c_(){return null}function d_(e){}function u_(e){}function h_(){return null}function p_(){}function f_(e,t){return null}function m_(){return Rv().slots}function v_(){return Rv().attrs}function Rv(){const e=gn();return e.setupContext||(e.setupContext=g3(e))}function ki(e){return st(e)?e.reduce((t,a)=>(t[a]=null,t),{}):e}function g_(e,t){const a=ki(e);for(const n in t){if(n.startsWith("__skip"))continue;let r=a[n];r?st(r)||gt(r)?r=a[n]={type:r,default:t[n]}:r.default=t[n]:r===null&&(r=a[n]={default:t[n]}),r&&t[`__skip_${n}`]&&(r.skipFactory=!0)}return a}function jn(e,t){return!e||!t?e||t:st(e)&&st(t)?e.concat(t):na({},ki(e),ki(t))}function y_(e,t){const a={};for(const n in e)t.includes(n)||Object.defineProperty(a,n,{enumerable:!0,get:()=>e[n]});return a}function M_(e){const t=gn();let a=e();return Mc(),Kc(a)&&(a=a.catch(n=>{throw ko(t),n})),[a,()=>ko(t)]}let pc=!0;function __(e){const t=u0(e),a=e.proxy,n=e.ctx;pc=!1,t.beforeCreate&&nh(t.beforeCreate,e,"bc");const{data:r,computed:o,methods:s,watch:i,provide:l,inject:c,created:d,beforeMount:u,mounted:h,beforeUpdate:f,updated:m,activated:g,deactivated:_,beforeDestroy:b,beforeUnmount:v,destroyed:y,unmounted:M,render:x,renderTracked:S,renderTriggered:L,errorCaptured:F,serverPrefetch:te,expose:J,inheritAttrs:be,components:oe,directives:Te,filters:Ue}=t;if(c&&b_(c,n,null),s)for(const ee in s){const j=s[ee];gt(j)&&(n[ee]=j.bind(a))}if(r){const ee=r.call(a,a);ta(ee)&&(e.data=Ri(ee))}if(pc=!0,o)for(const ee in o){const j=o[ee],K=gt(j)?j.bind(a,a):gt(j.get)?j.get.bind(a,a):Cn,G=!gt(j)&&gt(j.set)?j.set.bind(a):Cn,T=H({get:K,set:G});Object.defineProperty(n,ee,{enumerable:!0,configurable:!0,get:()=>T.value,set:O=>T.value=O})}if(i)for(const ee in i)Nv(i[ee],n,a,ee);if(l){const ee=gt(l)?l.call(a):l;Reflect.ownKeys(ee).forEach(j=>{Bv(j,ee[j])})}d&&nh(d,e,"c");function Me(ee,j){st(j)?j.forEach(K=>ee(K.bind(a))):j&&ee(j.bind(a))}if(Me(Ts,u),Me(ia,h),Me(i0,f),Me(Tl,m),Me(Ev,g),Me(Iv,_),Me(Vv,F),Me(Lv,S),Me(Pv,L),Me(kr,v),Me(Zn,M),Me(Tv,te),st(J))if(J.length){const ee=e.exposed||(e.exposed={});J.forEach(j=>{Object.defineProperty(ee,j,{get:()=>a[j],set:K=>a[j]=K})})}else e.exposed||(e.exposed={});x&&e.render===Cn&&(e.render=x),be!=null&&(e.inheritAttrs=be),oe&&(e.components=oe),Te&&(e.directives=Te),te&&s0(e)}function b_(e,t,a=Cn){st(e)&&(e=fc(e));for(const n in e){const r=e[n];let o;ta(r)?"default"in r?o=re(r.from||n,r.default,!0):o=re(r.from||n):o=re(r),ba(o)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>o.value,set:s=>o.value=s}):t[n]=o}}function nh(e,t,a){$n(st(e)?e.map(n=>n.bind(t.proxy)):e.bind(t.proxy),t,a)}function Nv(e,t,a,n){let r=n.includes(".")?r3(a,n):()=>a[n];if(sa(e)){const o=t[e];gt(o)&&We(r,o)}else if(gt(e))We(r,e.bind(a));else if(ta(e))if(st(e))e.forEach(o=>Nv(o,t,a,n));else{const o=gt(e.handler)?e.handler.bind(a):t[e.handler];gt(o)&&We(r,o,e)}}function u0(e){const t=e.type,{mixins:a,extends:n}=t,{mixins:r,optionsCache:o,config:{optionMergeStrategies:s}}=e.appContext,i=o.get(t);let l;return i?l=i:!r.length&&!a&&!n?l=t:(l={},r.length&&r.forEach(c=>J1(l,c,s,!0)),J1(l,t,s)),ta(t)&&o.set(t,l),l}function J1(e,t,a,n=!1){const{mixins:r,extends:o}=t;o&&J1(e,o,a,!0),r&&r.forEach(s=>J1(e,s,a,!0));for(const s in t)if(!(n&&s==="expose")){const i=w_[s]||a&&a[s];e[s]=i?i(e[s],t[s]):t[s]}return e}const w_={data:rh,props:oh,emits:oh,methods:ri,computed:ri,beforeCreate:Za,created:Za,beforeMount:Za,mounted:Za,beforeUpdate:Za,updated:Za,beforeDestroy:Za,beforeUnmount:Za,destroyed:Za,unmounted:Za,activated:Za,deactivated:Za,errorCaptured:Za,serverPrefetch:Za,components:ri,directives:ri,watch:C_,provide:rh,inject:x_};function rh(e,t){return t?e?function(){return na(gt(e)?e.call(this,this):e,gt(t)?t.call(this,this):t)}:t:e}function x_(e,t){return ri(fc(e),fc(t))}function fc(e){if(st(e)){const t={};for(let a=0;a<e.length;a++)t[e[a]]=e[a];return t}return e}function Za(e,t){return e?[...new Set([].concat(e,t))]:t}function ri(e,t){return e?na(Object.create(null),e,t):t}function oh(e,t){return e?st(e)&&st(t)?[...new Set([...e,...t])]:na(Object.create(null),ki(e),ki(t??{})):t}function C_(e,t){if(!e)return t;if(!t)return e;const a=na(Object.create(null),e);for(const n in t)a[n]=Za(e[n],t[n]);return a}function Dv(){return{app:null,config:{isNativeTag:V9,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let A_=0;function S_(e,t){return function(n,r=null){gt(n)||(n=na({},n)),r!=null&&!ta(r)&&(r=null);const o=Dv(),s=new WeakSet,i=[];let l=!1;const c=o.app={_uid:A_++,_component:n,_props:r,_container:null,_context:o,_instance:null,version:M3,get config(){return o.config},set config(d){},use(d,...u){return s.has(d)||(d&&gt(d.install)?(s.add(d),d.install(c,...u)):gt(d)&&(s.add(d),d(c,...u))),c},mixin(d){return o.mixins.includes(d)||o.mixins.push(d),c},component(d,u){return u?(o.components[d]=u,c):o.components[d]},directive(d,u){return u?(o.directives[d]=u,c):o.directives[d]},mount(d,u,h){if(!l){const f=c._ceVNode||Ce(n,r);return f.appContext=o,h===!0?h="svg":h===!1&&(h=void 0),u&&t?t(f,d):e(f,d,h),l=!0,c._container=d,d.__vue_app__=c,Fi(f.component)}},onUnmount(d){i.push(d)},unmount(){l&&($n(i,c._instance,16),e(null,c._container),delete c._container.__vue_app__)},provide(d,u){return o.provides[d]=u,c},runWithContext(d){const u=$o;$o=c;try{return d()}finally{$o=u}}};return c}}let $o=null;function Bv(e,t){if($a){let a=$a.provides;const n=$a.parent&&$a.parent.provides;n===a&&(a=$a.provides=Object.create(n)),a[e]=t}}function re(e,t,a=!1){const n=$a||Ea;if(n||$o){const r=$o?$o._context.provides:n?n.parent==null?n.vnode.appContext&&n.vnode.appContext.provides:n.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return a&&gt(t)?t.call(n&&n.proxy):t}}function $_(){return!!($a||Ea||$o)}const Fv={},jv=()=>Object.create(Fv),Uv=e=>Object.getPrototypeOf(e)===Fv;function E_(e,t,a,n=!1){const r={},o=jv();e.propsDefaults=Object.create(null),zv(e,t,r,o);for(const s in e.propsOptions[0])s in r||(r[s]=void 0);a?e.props=n?r:sv(r):e.type.props?e.props=r:e.props=o,e.attrs=o}function I_(e,t,a,n){const{props:r,attrs:o,vnode:{patchFlag:s}}=e,i=St(r),[l]=e.propsOptions;let c=!1;if((n||s>0)&&!(s&16)){if(s&8){const d=e.vnode.dynamicProps;for(let u=0;u<d.length;u++){let h=d[u];if(Pl(e.emitsOptions,h))continue;const f=t[h];if(l)if(Kt(o,h))f!==o[h]&&(o[h]=f,c=!0);else{const m=Da(h);r[m]=mc(l,i,m,f,e,!1)}else f!==o[h]&&(o[h]=f,c=!0)}}}else{zv(e,t,r,o)&&(c=!0);let d;for(const u in i)(!t||!Kt(t,u)&&((d=rn(u))===u||!Kt(t,d)))&&(l?a&&(a[u]!==void 0||a[d]!==void 0)&&(r[u]=mc(l,i,u,void 0,e,!0)):delete r[u]);if(o!==i)for(const u in o)(!t||!Kt(t,u))&&(delete o[u],c=!0)}c&&_r(e.attrs,"set","")}function zv(e,t,a,n){const[r,o]=e.propsOptions;let s=!1,i;if(t)for(let l in t){if(hs(l))continue;const c=t[l];let d;r&&Kt(r,d=Da(l))?!o||!o.includes(d)?a[d]=c:(i||(i={}))[d]=c:Pl(e.emitsOptions,l)||(!(l in n)||c!==n[l])&&(n[l]=c,s=!0)}if(o){const l=St(a),c=i||Nt;for(let d=0;d<o.length;d++){const u=o[d];a[u]=mc(r,l,u,c[u],e,!Kt(c,u))}}return s}function mc(e,t,a,n,r,o){const s=e[a];if(s!=null){const i=Kt(s,"default");if(i&&n===void 0){const l=s.default;if(s.type!==Function&&!s.skipFactory&&gt(l)){const{propsDefaults:c}=r;if(a in c)n=c[a];else{const d=ko(r);n=c[a]=l.call(null,t),d()}}else n=l;r.ce&&r.ce._setProp(a,n)}s[0]&&(o&&!i?n=!1:s[1]&&(n===""||n===rn(a))&&(n=!0))}return n}const k_=new WeakMap;function qv(e,t,a=!1){const n=a?k_:t.propsCache,r=n.get(e);if(r)return r;const o=e.props,s={},i=[];let l=!1;if(!gt(e)){const d=u=>{l=!0;const[h,f]=qv(u,t,!0);na(s,h),f&&i.push(...f)};!a&&t.mixins.length&&t.mixins.forEach(d),e.extends&&d(e.extends),e.mixins&&e.mixins.forEach(d)}if(!o&&!l)return ta(e)&&n.set(e,ds),ds;if(st(o))for(let d=0;d<o.length;d++){const u=Da(o[d]);sh(u)&&(s[u]=Nt)}else if(o)for(const d in o){const u=Da(d);if(sh(u)){const h=o[d],f=s[u]=st(h)||gt(h)?{type:h}:na({},h),m=f.type;let g=!1,_=!0;if(st(m))for(let b=0;b<m.length;++b){const v=m[b],y=gt(v)&&v.name;if(y==="Boolean"){g=!0;break}else y==="String"&&(_=!1)}else g=gt(m)&&m.name==="Boolean";f[0]=g,f[1]=_,(g||Kt(f,"default"))&&i.push(u)}}const c=[s,i];return ta(e)&&n.set(e,c),c}function sh(e){return e[0]!=="$"&&!hs(e)}const Wv=e=>e[0]==="_"||e==="$stable",h0=e=>st(e)?e.map(nn):[nn(e)],T_=(e,t,a)=>{if(t._n)return t;const n=Xe((...r)=>h0(t(...r)),a);return n._c=!1,n},Zv=(e,t,a)=>{const n=e._ctx;for(const r in e){if(Wv(r))continue;const o=e[r];if(gt(o))t[r]=T_(r,o,n);else if(o!=null){const s=h0(o);t[r]=()=>s}}},Kv=(e,t)=>{const a=h0(t);e.slots.default=()=>a},Gv=(e,t,a)=>{for(const n in t)(a||n!=="_")&&(e[n]=t[n])},P_=(e,t,a)=>{const n=e.slots=jv();if(e.vnode.shapeFlag&32){const r=t._;r?(Gv(n,t,a),a&&Fm(n,"_",r,!0)):Zv(t,n)}else t&&Kv(e,t)},L_=(e,t,a)=>{const{vnode:n,slots:r}=e;let o=!0,s=Nt;if(n.shapeFlag&32){const i=t._;i?a&&i===1?o=!1:Gv(r,t,a):(o=!t.$stable,Zv(t,r)),s=t}else t&&(Kv(e,t),s={default:1});if(o)for(const i in r)!Wv(i)&&s[i]==null&&delete r[i]},Aa=l3;function Jv(e){return Yv(e)}function Xv(e){return Yv(e,zM)}function Yv(e,t){const a=_l();a.__VUE__=!0;const{insert:n,remove:r,patchProp:o,createElement:s,createText:i,createComment:l,setText:c,setElementText:d,parentNode:u,nextSibling:h,setScopeId:f=Cn,insertStaticContent:m}=e,g=(D,q,he,me=null,_e=null,Ae=null,pe=void 0,ce=null,ue=!!q.dynamicChildren)=>{if(D===q)return;D&&!Nn(D,q)&&(me=xe(D),O(D,_e,Ae,!0),D=null),q.patchFlag===-2&&(ue=!1,q.dynamicChildren=null);const{type:I,ref:B,shapeFlag:N}=q;switch(I){case Yr:_(D,q,he,me);break;case _a:b(D,q,he,me);break;case Eo:D==null&&v(q,he,me,pe);break;case Je:oe(D,q,he,me,_e,Ae,pe,ce,ue);break;default:N&1?x(D,q,he,me,_e,Ae,pe,ce,ue):N&6?Te(D,q,he,me,_e,Ae,pe,ce,ue):(N&64||N&128)&&I.process(D,q,he,me,_e,Ae,pe,ce,ue,Ye)}B!=null&&_e&&Ii(B,D&&D.ref,Ae,q||D,!q)},_=(D,q,he,me)=>{if(D==null)n(q.el=i(q.children),he,me);else{const _e=q.el=D.el;q.children!==D.children&&c(_e,q.children)}},b=(D,q,he,me)=>{D==null?n(q.el=l(q.children||""),he,me):q.el=D.el},v=(D,q,he,me)=>{[D.el,D.anchor]=m(D.children,q,he,me,D.el,D.anchor)},y=({el:D,anchor:q},he,me)=>{let _e;for(;D&&D!==q;)_e=h(D),n(D,he,me),D=_e;n(q,he,me)},M=({el:D,anchor:q})=>{let he;for(;D&&D!==q;)he=h(D),r(D),D=he;r(q)},x=(D,q,he,me,_e,Ae,pe,ce,ue)=>{q.type==="svg"?pe="svg":q.type==="math"&&(pe="mathml"),D==null?S(q,he,me,_e,Ae,pe,ce,ue):te(D,q,_e,Ae,pe,ce,ue)},S=(D,q,he,me,_e,Ae,pe,ce)=>{let ue,I;const{props:B,shapeFlag:N,transition:U,dirs:se}=D;if(ue=D.el=s(D.type,Ae,B&&B.is,B),N&8?d(ue,D.children):N&16&&F(D.children,ue,null,me,_e,T2(D,Ae),pe,ce),se&&Yn(D,null,me,"created"),L(ue,D,D.scopeId,pe,me),B){for(const Ne in B)Ne!=="value"&&!hs(Ne)&&o(ue,Ne,null,B[Ne],Ae,me);"value"in B&&o(ue,"value",null,B.value,Ae),(I=B.onVnodeBeforeMount)&&tn(I,me,D)}se&&Yn(D,null,me,"beforeMount");const Se=Qv(_e,U);Se&&U.beforeEnter(ue),n(ue,q,he),((I=B&&B.onVnodeMounted)||Se||se)&&Aa(()=>{I&&tn(I,me,D),Se&&U.enter(ue),se&&Yn(D,null,me,"mounted")},_e)},L=(D,q,he,me,_e)=>{if(he&&f(D,he),me)for(let Ae=0;Ae<me.length;Ae++)f(D,me[Ae]);if(_e){let Ae=_e.subTree;if(q===Ae||Y1(Ae.type)&&(Ae.ssContent===q||Ae.ssFallback===q)){const pe=_e.vnode;L(D,pe,pe.scopeId,pe.slotScopeIds,_e.parent)}}},F=(D,q,he,me,_e,Ae,pe,ce,ue=0)=>{for(let I=ue;I<D.length;I++){const B=D[I]=ce?Wr(D[I]):nn(D[I]);g(null,B,q,he,me,_e,Ae,pe,ce)}},te=(D,q,he,me,_e,Ae,pe)=>{const ce=q.el=D.el;let{patchFlag:ue,dynamicChildren:I,dirs:B}=q;ue|=D.patchFlag&16;const N=D.props||Nt,U=q.props||Nt;let se;if(he&&mo(he,!1),(se=U.onVnodeBeforeUpdate)&&tn(se,he,q,D),B&&Yn(q,D,he,"beforeUpdate"),he&&mo(he,!0),(N.innerHTML&&U.innerHTML==null||N.textContent&&U.textContent==null)&&d(ce,""),I?J(D.dynamicChildren,I,ce,he,me,T2(q,_e),Ae):pe||j(D,q,ce,null,he,me,T2(q,_e),Ae,!1),ue>0){if(ue&16)be(ce,N,U,he,_e);else if(ue&2&&N.class!==U.class&&o(ce,"class",null,U.class,_e),ue&4&&o(ce,"style",N.style,U.style,_e),ue&8){const Se=q.dynamicProps;for(let Ne=0;Ne<Se.length;Ne++){const ut=Se[Ne],ie=N[ut],Ee=U[ut];(Ee!==ie||ut==="value")&&o(ce,ut,ie,Ee,_e,he)}}ue&1&&D.children!==q.children&&d(ce,q.children)}else!pe&&I==null&&be(ce,N,U,he,_e);((se=U.onVnodeUpdated)||B)&&Aa(()=>{se&&tn(se,he,q,D),B&&Yn(q,D,he,"updated")},me)},J=(D,q,he,me,_e,Ae,pe)=>{for(let ce=0;ce<q.length;ce++){const ue=D[ce],I=q[ce],B=ue.el&&(ue.type===Je||!Nn(ue,I)||ue.shapeFlag&70)?u(ue.el):he;g(ue,I,B,null,me,_e,Ae,pe,!0)}},be=(D,q,he,me,_e)=>{if(q!==he){if(q!==Nt)for(const Ae in q)!hs(Ae)&&!(Ae in he)&&o(D,Ae,q[Ae],null,_e,me);for(const Ae in he){if(hs(Ae))continue;const pe=he[Ae],ce=q[Ae];pe!==ce&&Ae!=="value"&&o(D,Ae,ce,pe,_e,me)}"value"in he&&o(D,"value",q.value,he.value,_e)}},oe=(D,q,he,me,_e,Ae,pe,ce,ue)=>{const I=q.el=D?D.el:i(""),B=q.anchor=D?D.anchor:i("");let{patchFlag:N,dynamicChildren:U,slotScopeIds:se}=q;se&&(ce=ce?ce.concat(se):se),D==null?(n(I,he,me),n(B,he,me),F(q.children||[],he,B,_e,Ae,pe,ce,ue)):N>0&&N&64&&U&&D.dynamicChildren?(J(D.dynamicChildren,U,he,_e,Ae,pe,ce),(q.key!=null||_e&&q===_e.subTree)&&p0(D,q,!0)):j(D,q,he,B,_e,Ae,pe,ce,ue)},Te=(D,q,he,me,_e,Ae,pe,ce,ue)=>{q.slotScopeIds=ce,D==null?q.shapeFlag&512?_e.ctx.activate(q,he,me,pe,ue):Ue(q,he,me,_e,Ae,pe,ue):Ze(D,q,ue)},Ue=(D,q,he,me,_e,Ae,pe)=>{const ce=D.component=p3(D,me,_e);if(Ni(D)&&(ce.ctx.renderer=Ye),m3(ce,!1,pe),ce.asyncDep){if(_e&&_e.registerDep(ce,Me,pe),!D.el){const ue=ce.subTree=Ce(_a);b(null,ue,q,he)}}else Me(ce,D,q,he,_e,Ae,pe)},Ze=(D,q,he)=>{const me=q.component=D.component;if(j_(D,q,he))if(me.asyncDep&&!me.asyncResolved){ee(me,q,he);return}else me.next=q,me.update();else q.el=D.el,me.vnode=q},Me=(D,q,he,me,_e,Ae,pe)=>{const ce=()=>{if(D.isMounted){let{next:N,bu:U,u:se,parent:Se,vnode:Ne}=D;{const Pe=e3(D);if(Pe){N&&(N.el=Ne.el,ee(D,N,pe)),Pe.asyncDep.then(()=>{D.isUnmounted||ce()});return}}let ut=N,ie;mo(D,!1),N?(N.el=Ne.el,ee(D,N,pe)):N=Ne,U&&ps(U),(ie=N.props&&N.props.onVnodeBeforeUpdate)&&tn(ie,Se,N,Ne),mo(D,!0);const Ee=O1(D),Oe=D.subTree;D.subTree=Ee,g(Oe,Ee,u(Oe.el),xe(Oe),D,_e,Ae),N.el=Ee.el,ut===null&&Ll(D,Ee.el),se&&Aa(se,_e),(ie=N.props&&N.props.onVnodeUpdated)&&Aa(()=>tn(ie,Se,N,Ne),_e)}else{let N;const{el:U,props:se}=q,{bm:Se,m:Ne,parent:ut,root:ie,type:Ee}=D,Oe=Xr(q);if(mo(D,!1),Se&&ps(Se),!Oe&&(N=se&&se.onVnodeBeforeMount)&&tn(N,ut,q),mo(D,!0),U&&xt){const Pe=()=>{D.subTree=O1(D),xt(U,D.subTree,D,_e,null)};Oe&&Ee.__asyncHydrate?Ee.__asyncHydrate(U,D,Pe):Pe()}else{ie.ce&&ie.ce._injectChildStyle(Ee);const Pe=D.subTree=O1(D);g(null,Pe,he,me,D,_e,Ae),q.el=Pe.el}if(Ne&&Aa(Ne,_e),!Oe&&(N=se&&se.onVnodeMounted)){const Pe=q;Aa(()=>tn(N,ut,Pe),_e)}(q.shapeFlag&256||ut&&Xr(ut.vnode)&&ut.vnode.shapeFlag&256)&&D.a&&Aa(D.a,_e),D.isMounted=!0,q=he=me=null}};D.scope.on();const ue=D.effect=new xi(ce);D.scope.off();const I=D.update=ue.run.bind(ue),B=D.job=ue.runIfDirty.bind(ue);B.i=D,B.id=D.uid,ue.scheduler=()=>n0(B),mo(D,!0),I()},ee=(D,q,he)=>{q.component=D;const me=D.vnode.props;D.vnode=q,D.next=null,I_(D,q.props,me,he),L_(D,q.children,he),oo(),Gu(D),so()},j=(D,q,he,me,_e,Ae,pe,ce,ue=!1)=>{const I=D&&D.children,B=D?D.shapeFlag:0,N=q.children,{patchFlag:U,shapeFlag:se}=q;if(U>0){if(U&128){G(I,N,he,me,_e,Ae,pe,ce,ue);return}else if(U&256){K(I,N,he,me,_e,Ae,pe,ce,ue);return}}se&8?(B&16&&ae(I,_e,Ae),N!==I&&d(he,N)):B&16?se&16?G(I,N,he,me,_e,Ae,pe,ce,ue):ae(I,_e,Ae,!0):(B&8&&d(he,""),se&16&&F(N,he,me,_e,Ae,pe,ce,ue))},K=(D,q,he,me,_e,Ae,pe,ce,ue)=>{D=D||ds,q=q||ds;const I=D.length,B=q.length,N=Math.min(I,B);let U;for(U=0;U<N;U++){const se=q[U]=ue?Wr(q[U]):nn(q[U]);g(D[U],se,he,null,_e,Ae,pe,ce,ue)}I>B?ae(D,_e,Ae,!0,!1,N):F(q,he,me,_e,Ae,pe,ce,ue,N)},G=(D,q,he,me,_e,Ae,pe,ce,ue)=>{let I=0;const B=q.length;let N=D.length-1,U=B-1;for(;I<=N&&I<=U;){const se=D[I],Se=q[I]=ue?Wr(q[I]):nn(q[I]);if(Nn(se,Se))g(se,Se,he,null,_e,Ae,pe,ce,ue);else break;I++}for(;I<=N&&I<=U;){const se=D[N],Se=q[U]=ue?Wr(q[U]):nn(q[U]);if(Nn(se,Se))g(se,Se,he,null,_e,Ae,pe,ce,ue);else break;N--,U--}if(I>N){if(I<=U){const se=U+1,Se=se<B?q[se].el:me;for(;I<=U;)g(null,q[I]=ue?Wr(q[I]):nn(q[I]),he,Se,_e,Ae,pe,ce,ue),I++}}else if(I>U)for(;I<=N;)O(D[I],_e,Ae,!0),I++;else{const se=I,Se=I,Ne=new Map;for(I=Se;I<=U;I++){const ht=q[I]=ue?Wr(q[I]):nn(q[I]);ht.key!=null&&Ne.set(ht.key,I)}let ut,ie=0;const Ee=U-Se+1;let Oe=!1,Pe=0;const Ke=new Array(Ee);for(I=0;I<Ee;I++)Ke[I]=0;for(I=se;I<=N;I++){const ht=D[I];if(ie>=Ee){O(ht,_e,Ae,!0);continue}let Ft;if(ht.key!=null)Ft=Ne.get(ht.key);else for(ut=Se;ut<=U;ut++)if(Ke[ut-Se]===0&&Nn(ht,q[ut])){Ft=ut;break}Ft===void 0?O(ht,_e,Ae,!0):(Ke[Ft-Se]=I+1,Ft>=Pe?Pe=Ft:Oe=!0,g(ht,q[Ft],he,null,_e,Ae,pe,ce,ue),ie++)}const it=Oe?V_(Ke):ds;for(ut=it.length-1,I=Ee-1;I>=0;I--){const ht=Se+I,Ft=q[ht],ma=ht+1<B?q[ht+1].el:me;Ke[I]===0?g(null,Ft,he,ma,_e,Ae,pe,ce,ue):Oe&&(ut<0||I!==it[ut]?T(Ft,he,ma,2):ut--)}}},T=(D,q,he,me,_e=null)=>{const{el:Ae,type:pe,transition:ce,children:ue,shapeFlag:I}=D;if(I&6){T(D.component.subTree,q,he,me);return}if(I&128){D.suspense.move(q,he,me);return}if(I&64){pe.move(D,q,he,Ye);return}if(pe===Je){n(Ae,q,he);for(let N=0;N<ue.length;N++)T(ue[N],q,he,me);n(D.anchor,q,he);return}if(pe===Eo){y(D,q,he);return}if(me!==2&&I&1&&ce)if(me===0)ce.beforeEnter(Ae),n(Ae,q,he),Aa(()=>ce.enter(Ae),_e);else{const{leave:N,delayLeave:U,afterLeave:se}=ce,Se=()=>n(Ae,q,he),Ne=()=>{N(Ae,()=>{Se(),se&&se()})};U?U(Ae,Se,Ne):Ne()}else n(Ae,q,he)},O=(D,q,he,me=!1,_e=!1)=>{const{type:Ae,props:pe,ref:ce,children:ue,dynamicChildren:I,shapeFlag:B,patchFlag:N,dirs:U,cacheIndex:se}=D;if(N===-2&&(_e=!1),ce!=null&&Ii(ce,null,he,D,!0),se!=null&&(q.renderCache[se]=void 0),B&256){q.ctx.deactivate(D);return}const Se=B&1&&U,Ne=!Xr(D);let ut;if(Ne&&(ut=pe&&pe.onVnodeBeforeUnmount)&&tn(ut,q,D),B&6)P(D.component,he,me);else{if(B&128){D.suspense.unmount(he,me);return}Se&&Yn(D,null,q,"beforeUnmount"),B&64?D.type.remove(D,q,he,Ye,me):I&&!I.hasOnce&&(Ae!==Je||N>0&&N&64)?ae(I,q,he,!1,!0):(Ae===Je&&N&384||!_e&&B&16)&&ae(ue,q,he),me&&k(D)}(Ne&&(ut=pe&&pe.onVnodeUnmounted)||Se)&&Aa(()=>{ut&&tn(ut,q,D),Se&&Yn(D,null,q,"unmounted")},he)},k=D=>{const{type:q,el:he,anchor:me,transition:_e}=D;if(q===Je){C(he,me);return}if(q===Eo){M(D);return}const Ae=()=>{r(he),_e&&!_e.persisted&&_e.afterLeave&&_e.afterLeave()};if(D.shapeFlag&1&&_e&&!_e.persisted){const{leave:pe,delayLeave:ce}=_e,ue=()=>pe(he,Ae);ce?ce(D.el,Ae,ue):ue()}else Ae()},C=(D,q)=>{let he;for(;D!==q;)he=h(D),r(D),D=he;r(q)},P=(D,q,he)=>{const{bum:me,scope:_e,job:Ae,subTree:pe,um:ce,m:ue,a:I}=D;X1(ue),X1(I),me&&ps(me),_e.stop(),Ae&&(Ae.flags|=8,O(pe,D,q,he)),ce&&Aa(ce,q),Aa(()=>{D.isUnmounted=!0},q),q&&q.pendingBranch&&!q.isUnmounted&&D.asyncDep&&!D.asyncResolved&&D.suspenseId===q.pendingId&&(q.deps--,q.deps===0&&q.resolve())},ae=(D,q,he,me=!1,_e=!1,Ae=0)=>{for(let pe=Ae;pe<D.length;pe++)O(D[pe],q,he,me,_e)},xe=D=>{if(D.shapeFlag&6)return xe(D.component.subTree);if(D.shapeFlag&128)return D.suspense.next();const q=h(D.anchor||D.el),he=q&&q[gv];return he?h(he):q};let ve=!1;const ze=(D,q,he)=>{D==null?q._vnode&&O(q._vnode,null,null,!0):g(q._vnode||null,D,q,null,null,null,he),q._vnode=D,ve||(ve=!0,Gu(),G1(),ve=!1)},Ye={p:g,um:O,m:T,r:k,mt:Ue,mc:F,pc:j,pbc:J,n:xe,o:e};let ct,xt;return t&&([ct,xt]=t(Ye)),{render:ze,hydrate:ct,createApp:S_(ze,ct)}}function T2({type:e,props:t},a){return a==="svg"&&e==="foreignObject"||a==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:a}function mo({effect:e,job:t},a){a?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Qv(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function p0(e,t,a=!1){const n=e.children,r=t.children;if(st(n)&&st(r))for(let o=0;o<n.length;o++){const s=n[o];let i=r[o];i.shapeFlag&1&&!i.dynamicChildren&&((i.patchFlag<=0||i.patchFlag===32)&&(i=r[o]=Wr(r[o]),i.el=s.el),!a&&i.patchFlag!==-2&&p0(s,i)),i.type===Yr&&(i.el=s.el)}}function V_(e){const t=e.slice(),a=[0];let n,r,o,s,i;const l=e.length;for(n=0;n<l;n++){const c=e[n];if(c!==0){if(r=a[a.length-1],e[r]<c){t[n]=r,a.push(n);continue}for(o=0,s=a.length-1;o<s;)i=o+s>>1,e[a[i]]<c?o=i+1:s=i;c<e[a[o]]&&(o>0&&(t[n]=a[o-1]),a[o]=n)}}for(o=a.length,s=a[o-1];o-- >0;)a[o]=s,s=t[s];return a}function e3(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:e3(t)}function X1(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const t3=Symbol.for("v-scx"),a3=()=>re(t3);function O_(e,t){return Di(e,null,t)}function H_(e,t){return Di(e,null,{flush:"post"})}function n3(e,t){return Di(e,null,{flush:"sync"})}function We(e,t,a){return Di(e,t,a)}function Di(e,t,a=Nt){const{immediate:n,deep:r,flush:o,once:s}=a,i=na({},a),l=t&&n||!t&&o!=="post";let c;if(_s){if(o==="sync"){const f=a3();c=f.__watcherHandles||(f.__watcherHandles=[])}else if(!l){const f=()=>{};return f.stop=Cn,f.resume=Cn,f.pause=Cn,f}}const d=$a;i.call=(f,m,g)=>$n(f,d,m,g);let u=!1;o==="post"?i.scheduler=f=>{Aa(f,d&&d.suspense)}:o!=="sync"&&(u=!0,i.scheduler=(f,m)=>{m?f():n0(f)}),i.augmentJob=f=>{t&&(f.flags|=4),u&&(f.flags|=2,d&&(f.id=d.uid,f.i=d))};const h=IM(e,t,i);return _s&&(c?c.push(h):l&&h()),h}function R_(e,t,a){const n=this.proxy,r=sa(e)?e.includes(".")?r3(n,e):()=>n[e]:e.bind(n,n);let o;gt(t)?o=t:(o=t.handler,a=t);const s=ko(this),i=Di(r,o.bind(n),a);return s(),i}function r3(e,t){const a=t.split(".");return()=>{let n=e;for(let r=0;r<a.length&&n;r++)n=n[a[r]];return n}}function lr(e,t,a=Nt){const n=gn(),r=Da(t),o=rn(t),s=o3(e,r),i=cv((l,c)=>{let d,u=Nt,h;return n3(()=>{const f=e[r];Ja(d,f)&&(d=f,c())}),{get(){return l(),a.get?a.get(d):d},set(f){const m=a.set?a.set(f):f;if(!Ja(m,d)&&!(u!==Nt&&Ja(f,u)))return;const g=n.vnode.props;g&&(t in g||r in g||o in g)&&(`onUpdate:${t}`in g||`onUpdate:${r}`in g||`onUpdate:${o}`in g)||(d=f,c()),n.emit(`update:${t}`,m),Ja(f,m)&&Ja(f,u)&&!Ja(m,h)&&c(),u=f,h=m}}});return i[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?s||Nt:i,done:!1}:{done:!0}}}},i}const o3=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Da(t)}Modifiers`]||e[`${rn(t)}Modifiers`];function N_(e,t,...a){if(e.isUnmounted)return;const n=e.vnode.props||Nt;let r=a;const o=t.startsWith("update:"),s=o&&o3(n,t.slice(7));s&&(s.trim&&(r=a.map(d=>sa(d)?d.trim():d)),s.number&&(r=a.map(z1)));let i,l=n[i=li(t)]||n[i=li(Da(t))];!l&&o&&(l=n[i=li(rn(t))]),l&&$n(l,e,6,r);const c=n[i+"Once"];if(c){if(!e.emitted)e.emitted={};else if(e.emitted[i])return;e.emitted[i]=!0,$n(c,e,6,r)}}function s3(e,t,a=!1){const n=t.emitsCache,r=n.get(e);if(r!==void 0)return r;const o=e.emits;let s={},i=!1;if(!gt(e)){const l=c=>{const d=s3(c,t,!0);d&&(i=!0,na(s,d))};!a&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!o&&!i?(ta(e)&&n.set(e,null),null):(st(o)?o.forEach(l=>s[l]=null):na(s,o),ta(e)&&n.set(e,s),s)}function Pl(e,t){return!e||!Oi(t)?!1:(t=t.slice(2).replace(/Once$/,""),Kt(e,t[0].toLowerCase()+t.slice(1))||Kt(e,rn(t))||Kt(e,t))}function O1(e){const{type:t,vnode:a,proxy:n,withProxy:r,propsOptions:[o],slots:s,attrs:i,emit:l,render:c,renderCache:d,props:u,data:h,setupState:f,ctx:m,inheritAttrs:g}=e,_=Ei(e);let b,v;try{if(a.shapeFlag&4){const M=r||n,x=M;b=nn(c.call(x,M,d,u,f,h,m)),v=i}else{const M=t;b=nn(M.length>1?M(u,{attrs:i,slots:s,emit:l}):M(u,null)),v=t.props?i:B_(i)}}catch(M){pi.length=0,Ho(M,e,1),b=Ce(_a)}let y=b;if(v&&g!==!1){const M=Object.keys(v),{shapeFlag:x}=y;M.length&&x&7&&(o&&M.some(Wc)&&(v=F_(v,o)),y=rr(y,v,!1,!0))}return a.dirs&&(y=rr(y,null,!1,!0),y.dirs=y.dirs?y.dirs.concat(a.dirs):a.dirs),a.transition&&Ar(y,a.transition),b=y,Ei(_),b}function D_(e,t=!0){let a;for(let n=0;n<e.length;n++){const r=e[n];if(Sr(r)){if(r.type!==_a||r.children==="v-if"){if(a)return;a=r}}else return}return a}const B_=e=>{let t;for(const a in e)(a==="class"||a==="style"||Oi(a))&&((t||(t={}))[a]=e[a]);return t},F_=(e,t)=>{const a={};for(const n in e)(!Wc(n)||!(n.slice(9)in t))&&(a[n]=e[n]);return a};function j_(e,t,a){const{props:n,children:r,component:o}=e,{props:s,children:i,patchFlag:l}=t,c=o.emitsOptions;if(t.dirs||t.transition)return!0;if(a&&l>=0){if(l&1024)return!0;if(l&16)return n?ih(n,s,c):!!s;if(l&8){const d=t.dynamicProps;for(let u=0;u<d.length;u++){const h=d[u];if(s[h]!==n[h]&&!Pl(c,h))return!0}}}else return(r||i)&&(!i||!i.$stable)?!0:n===s?!1:n?s?ih(n,s,c):!0:!!s;return!1}function ih(e,t,a){const n=Object.keys(t);if(n.length!==Object.keys(e).length)return!0;for(let r=0;r<n.length;r++){const o=n[r];if(t[o]!==e[o]&&!Pl(a,o))return!0}return!1}function Ll({vnode:e,parent:t},a){for(;t;){const n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.el=e.el),n===e)(e=t.vnode).el=a,t=t.parent;else break}}const Y1=e=>e.__isSuspense;let vc=0;const U_={name:"Suspense",__isSuspense:!0,process(e,t,a,n,r,o,s,i,l,c){if(e==null)q_(t,a,n,r,o,s,i,l,c);else{if(o&&o.deps>0&&!e.suspense.isInFallback){t.suspense=e.suspense,t.suspense.vnode=t,t.el=e.el;return}W_(e,t,a,n,r,s,i,l,c)}},hydrate:Z_,normalize:K_},z_=U_;function Ti(e,t){const a=e.props&&e.props[t];gt(a)&&a()}function q_(e,t,a,n,r,o,s,i,l){const{p:c,o:{createElement:d}}=l,u=d("div"),h=e.suspense=i3(e,r,n,t,u,a,o,s,i,l);c(null,h.pendingBranch=e.ssContent,u,null,n,h,o,s),h.deps>0?(Ti(e,"onPending"),Ti(e,"onFallback"),c(null,e.ssFallback,t,a,n,null,o,s),ms(h,e.ssFallback)):h.resolve(!1,!0)}function W_(e,t,a,n,r,o,s,i,{p:l,um:c,o:{createElement:d}}){const u=t.suspense=e.suspense;u.vnode=t,t.el=e.el;const h=t.ssContent,f=t.ssFallback,{activeBranch:m,pendingBranch:g,isInFallback:_,isHydrating:b}=u;if(g)u.pendingBranch=h,Nn(h,g)?(l(g,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0?u.resolve():_&&(b||(l(m,f,a,n,r,null,o,s,i),ms(u,f)))):(u.pendingId=vc++,b?(u.isHydrating=!1,u.activeBranch=g):c(g,r,u),u.deps=0,u.effects.length=0,u.hiddenContainer=d("div"),_?(l(null,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0?u.resolve():(l(m,f,a,n,r,null,o,s,i),ms(u,f))):m&&Nn(h,m)?(l(m,h,a,n,r,u,o,s,i),u.resolve(!0)):(l(null,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0&&u.resolve()));else if(m&&Nn(h,m))l(m,h,a,n,r,u,o,s,i),ms(u,h);else if(Ti(t,"onPending"),u.pendingBranch=h,h.shapeFlag&512?u.pendingId=h.component.suspenseId:u.pendingId=vc++,l(null,h,u.hiddenContainer,null,r,u,o,s,i),u.deps<=0)u.resolve();else{const{timeout:v,pendingId:y}=u;v>0?setTimeout(()=>{u.pendingId===y&&u.fallback(f)},v):v===0&&u.fallback(f)}}function i3(e,t,a,n,r,o,s,i,l,c,d=!1){const{p:u,m:h,um:f,n:m,o:{parentNode:g,remove:_}}=c;let b;const v=G_(e);v&&t&&t.pendingBranch&&(b=t.pendingId,t.deps++);const y=e.props?q1(e.props.timeout):void 0,M=o,x={vnode:e,parent:t,parentComponent:a,namespace:s,container:n,hiddenContainer:r,deps:0,pendingId:vc++,timeout:typeof y=="number"?y:-1,activeBranch:null,pendingBranch:null,isInFallback:!d,isHydrating:d,isUnmounted:!1,effects:[],resolve(S=!1,L=!1){const{vnode:F,activeBranch:te,pendingBranch:J,pendingId:be,effects:oe,parentComponent:Te,container:Ue}=x;let Ze=!1;x.isHydrating?x.isHydrating=!1:S||(Ze=te&&J.transition&&J.transition.mode==="out-in",Ze&&(te.transition.afterLeave=()=>{be===x.pendingId&&(h(J,Ue,o===M?m(te):o,0),Si(oe))}),te&&(g(te.el)===Ue&&(o=m(te)),f(te,Te,x,!0)),Ze||h(J,Ue,o,0)),ms(x,J),x.pendingBranch=null,x.isInFallback=!1;let Me=x.parent,ee=!1;for(;Me;){if(Me.pendingBranch){Me.effects.push(...oe),ee=!0;break}Me=Me.parent}!ee&&!Ze&&Si(oe),x.effects=[],v&&t&&t.pendingBranch&&b===t.pendingId&&(t.deps--,t.deps===0&&!L&&t.resolve()),Ti(F,"onResolve")},fallback(S){if(!x.pendingBranch)return;const{vnode:L,activeBranch:F,parentComponent:te,container:J,namespace:be}=x;Ti(L,"onFallback");const oe=m(F),Te=()=>{x.isInFallback&&(u(null,S,J,oe,te,null,be,i,l),ms(x,S))},Ue=S.transition&&S.transition.mode==="out-in";Ue&&(F.transition.afterLeave=Te),x.isInFallback=!0,f(F,te,null,!0),Ue||Te()},move(S,L,F){x.activeBranch&&h(x.activeBranch,S,L,F),x.container=S},next(){return x.activeBranch&&m(x.activeBranch)},registerDep(S,L,F){const te=!!x.pendingBranch;te&&x.deps++;const J=S.vnode.el;S.asyncDep.catch(be=>{Ho(be,S,0)}).then(be=>{if(S.isUnmounted||x.isUnmounted||x.pendingId!==S.suspenseId)return;S.asyncResolved=!0;const{vnode:oe}=S;_c(S,be,!1),J&&(oe.el=J);const Te=!J&&S.subTree.el;L(S,oe,g(J||S.subTree.el),J?null:m(S.subTree),x,s,F),Te&&_(Te),Ll(S,oe.el),te&&--x.deps===0&&x.resolve()})},unmount(S,L){x.isUnmounted=!0,x.activeBranch&&f(x.activeBranch,a,S,L),x.pendingBranch&&f(x.pendingBranch,a,S,L)}};return x}function Z_(e,t,a,n,r,o,s,i,l){const c=t.suspense=i3(t,n,a,e.parentNode,document.createElement("div"),null,r,o,s,i,!0),d=l(e,c.pendingBranch=t.ssContent,a,c,o,s);return c.deps===0&&c.resolve(!1,!0),d}function K_(e){const{shapeFlag:t,children:a}=e,n=t&32;e.ssContent=lh(n?a.default:a),e.ssFallback=n?lh(a.fallback):Ce(_a)}function lh(e){let t;if(gt(e)){const a=Io&&e._c;a&&(e._d=!1,$()),e=e(),a&&(e._d=!0,t=za,c3())}return st(e)&&(e=D_(e)),e=nn(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(a=>a!==e)),e}function l3(e,t){t&&t.pendingBranch?st(e)?t.effects.push(...e):t.effects.push(e):Si(e)}function ms(e,t){e.activeBranch=t;const{vnode:a,parentComponent:n}=e;let r=t.el;for(;!r&&t.component;)t=t.component.subTree,r=t.el;a.el=r,n&&n.subTree===a&&(n.vnode.el=r,Ll(n,r))}function G_(e){const t=e.props&&e.props.suspensible;return t!=null&&t!==!1}const Je=Symbol.for("v-fgt"),Yr=Symbol.for("v-txt"),_a=Symbol.for("v-cmt"),Eo=Symbol.for("v-stc"),pi=[];let za=null;function $(e=!1){pi.push(za=e?null:[])}function c3(){pi.pop(),za=pi[pi.length-1]||null}let Io=1;function gc(e,t=!1){Io+=e,e<0&&za&&t&&(za.hasOnce=!0)}function d3(e){return e.dynamicChildren=Io>0?za||ds:null,c3(),Io>0&&za&&za.push(e),e}function R(e,t,a,n,r,o){return d3(Z(e,t,a,n,r,o,!0))}function Ie(e,t,a,n,r){return d3(Ce(e,t,a,n,r,!0))}function Sr(e){return e?e.__v_isVNode===!0:!1}function Nn(e,t){return e.type===t.type&&e.key===t.key}function J_(e){}const u3=({key:e})=>e??null,H1=({ref:e,ref_key:t,ref_for:a})=>(typeof e=="number"&&(e=""+e),e!=null?sa(e)||ba(e)||gt(e)?{i:Ea,r:e,k:t,f:!!a}:e:null);function Z(e,t=null,a=null,n=0,r=null,o=e===Je?0:1,s=!1,i=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&u3(t),ref:t&&H1(t),scopeId:El,slotScopeIds:null,children:a,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:n,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:Ea};return i?(f0(l,a),o&128&&e.normalize(l)):a&&(l.shapeFlag|=sa(a)?8:16),Io>0&&!s&&za&&(l.patchFlag>0||o&6)&&l.patchFlag!==32&&za.push(l),l}const Ce=X_;function X_(e,t=null,a=null,n=0,r=null,o=!1){if((!e||e===Ov)&&(e=_a),Sr(e)){const i=rr(e,t,!0);return a&&f0(i,a),Io>0&&!o&&za&&(i.shapeFlag&6?za[za.indexOf(e)]=i:za.push(i)),i.patchFlag=-2,i}if(ob(e)&&(e=e.__vccOpts),t){t=h3(t);let{class:i,style:l}=t;i&&!sa(i)&&(t.class=ft(i)),ta(l)&&($l(l)&&!st(l)&&(l=na({},l)),t.style=wt(l))}const s=sa(e)?1:Y1(e)?128:yv(e)?64:ta(e)?4:gt(e)?2:0;return Z(e,t,a,n,r,s,o,!0)}function h3(e){return e?$l(e)||Uv(e)?na({},e):e:null}function rr(e,t,a=!1,n=!1){const{props:r,ref:o,patchFlag:s,children:i,transition:l}=e,c=t?Bi(r||{},t):r,d={__v_isVNode:!0,__v_skip:!0,type:e.type,props:c,key:c&&u3(c),ref:t&&t.ref?a&&o?st(o)?o.concat(H1(t)):[o,H1(t)]:H1(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Je?s===-1?16:s|16:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&rr(e.ssContent),ssFallback:e.ssFallback&&rr(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&n&&Ar(d,l.clone(d)),d}function pa(e=" ",t=0){return Ce(Yr,null,e,t)}function Y_(e,t){const a=Ce(Eo,null,e);return a.staticCount=t,a}function ge(e="",t=!1){return t?($(),Ie(_a,null,e)):Ce(_a,null,e)}function nn(e){return e==null||typeof e=="boolean"?Ce(_a):st(e)?Ce(Je,null,e.slice()):Sr(e)?Wr(e):Ce(Yr,null,String(e))}function Wr(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:rr(e)}function f0(e,t){let a=0;const{shapeFlag:n}=e;if(t==null)t=null;else if(st(t))a=16;else if(typeof t=="object")if(n&65){const r=t.default;r&&(r._c&&(r._d=!1),f0(e,r()),r._c&&(r._d=!0));return}else{a=32;const r=t._;!r&&!Uv(t)?t._ctx=Ea:r===3&&Ea&&(Ea.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else gt(t)?(t={default:t,_ctx:Ea},a=32):(t=String(t),n&64?(a=16,t=[pa(t)]):a=8);e.children=t,e.shapeFlag|=a}function Bi(...e){const t={};for(let a=0;a<e.length;a++){const n=e[a];for(const r in n)if(r==="class")t.class!==n.class&&(t.class=ft([t.class,n.class]));else if(r==="style")t.style=wt([t.style,n.style]);else if(Oi(r)){const o=t[r],s=n[r];s&&o!==s&&!(st(o)&&o.includes(s))&&(t[r]=o?[].concat(o,s):s)}else r!==""&&(t[r]=n[r])}return t}function tn(e,t,a,n=null){$n(e,t,7,[a,n])}const Q_=Dv();let eb=0;function p3(e,t,a){const n=e.type,r=(t?t.appContext:e.appContext)||Q_,o={uid:eb++,vnode:e,type:n,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Jc(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:qv(n,r),emitsOptions:s3(n,r),emit:null,emitted:null,propsDefaults:Nt,inheritAttrs:n.inheritAttrs,ctx:Nt,data:Nt,props:Nt,attrs:Nt,slots:Nt,refs:Nt,setupState:Nt,setupContext:null,suspense:a,suspenseId:a?a.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=N_.bind(null,o),e.ce&&e.ce(o),o}let $a=null;const gn=()=>$a||Ea;let Q1,yc;{const e=_l(),t=(a,n)=>{let r;return(r=e[a])||(r=e[a]=[]),r.push(n),o=>{r.length>1?r.forEach(s=>s(o)):r[0](o)}};Q1=t("__VUE_INSTANCE_SETTERS__",a=>$a=a),yc=t("__VUE_SSR_SETTERS__",a=>_s=a)}const ko=e=>{const t=$a;return Q1(e),e.scope.on(),()=>{e.scope.off(),Q1(t)}},Mc=()=>{$a&&$a.scope.off(),Q1(null)};function f3(e){return e.vnode.shapeFlag&4}let _s=!1;function m3(e,t=!1,a=!1){t&&yc(t);const{props:n,children:r}=e.vnode,o=f3(e);E_(e,n,o,t),P_(e,r,a);const s=o?tb(e,t):void 0;return t&&yc(!1),s}function tb(e,t){const a=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,hc);const{setup:n}=a;if(n){oo();const r=e.setupContext=n.length>1?g3(e):null,o=ko(e),s=ks(n,e,0,[e.props,r]),i=Kc(s);if(so(),o(),(i||e.sp)&&!Xr(e)&&s0(e),i){if(s.then(Mc,Mc),t)return s.then(l=>{_c(e,l,t)}).catch(l=>{Ho(l,e,0)});e.asyncDep=s}else _c(e,s,t)}else v3(e,t)}function _c(e,t,a){gt(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ta(t)&&(e.setupState=t0(t)),v3(e,a)}let el,bc;function ab(e){el=e,bc=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,i_))}}const nb=()=>!el;function v3(e,t,a){const n=e.type;if(!e.render){if(!t&&el&&!n.render){const r=n.template||u0(e).template;if(r){const{isCustomElement:o,compilerOptions:s}=e.appContext.config,{delimiters:i,compilerOptions:l}=n,c=na(na({isCustomElement:o,delimiters:i},s),l);n.render=el(r,c)}}e.render=n.render||Cn,bc&&bc(e)}{const r=ko(e);oo();try{__(e)}finally{so(),r()}}}const rb={get(e,t){return ja(e,"get",""),e[t]}};function g3(e){const t=a=>{e.exposed=a||{}};return{attrs:new Proxy(e.attrs,rb),slots:e.slots,emit:e.emit,expose:t}}function Fi(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(t0(iv(e.exposed)),{get(t,a){if(a in t)return t[a];if(a in hi)return hi[a](e)},has(t,a){return a in t||a in hi}})):e.proxy}function wc(e,t=!0){return gt(e)?e.displayName||e.name:e.name||t&&e.__name}function ob(e){return gt(e)&&"__vccOpts"in e}const H=(e,t)=>AM(e,t,_s);function En(e,t,a){const n=arguments.length;return n===2?ta(t)&&!st(t)?Sr(t)?Ce(e,null,[t]):Ce(e,t):Ce(e,null,t):(n>3?a=Array.prototype.slice.call(arguments,2):n===3&&Sr(a)&&(a=[a]),Ce(e,t,a))}function sb(){}function ib(e,t,a,n){const r=a[n];if(r&&y3(r,e))return r;const o=t();return o.memo=e.slice(),o.cacheIndex=n,a[n]=o}function y3(e,t){const a=e.memo;if(a.length!=t.length)return!1;for(let n=0;n<a.length;n++)if(Ja(a[n],t[n]))return!1;return Io>0&&za&&za.push(e),!0}const M3="3.5.13",lb=Cn,cb=VM,db=os,ub=vv,hb={createComponentInstance:p3,setupComponent:m3,renderComponentRoot:O1,setCurrentRenderingInstance:Ei,isVNode:Sr,normalizeVNode:nn,getComponentPublicInstance:Fi,ensureValidVNode:d0,pushWarningContext:kM,popWarningContext:TM},pb=hb,fb=null,mb=null,vb=null;/**
21
21
  * @vue/runtime-dom v3.5.13
22
22
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
23
23
  * @license MIT
24
- **/let xc;const ch=typeof window<"u"&&window.trustedTypes;if(ch)try{xc=ch.createPolicy("vue",{createHTML:e=>e})}catch{}const _3=xc?e=>xc.createHTML(e):e=>e,gb="http://www.w3.org/2000/svg",yb="http://www.w3.org/1998/Math/MathML",yr=typeof document<"u"?document:null,dh=yr&&yr.createElement("template"),Mb={insert:(e,t,a)=>{t.insertBefore(e,a||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,a,n)=>{const r=t==="svg"?yr.createElementNS(gb,e):t==="mathml"?yr.createElementNS(yb,e):a?yr.createElement(e,{is:a}):yr.createElement(e);return e==="select"&&n&&n.multiple!=null&&r.setAttribute("multiple",n.multiple),r},createText:e=>yr.createTextNode(e),createComment:e=>yr.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>yr.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,a,n,r,o){const s=a?a.previousSibling:t.lastChild;if(r&&(r===o||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),a),!(r===o||!(r=r.nextSibling)););else{dh.innerHTML=_3(n==="svg"?`<svg>${e}</svg>`:n==="mathml"?`<math>${e}</math>`:e);const i=dh.content;if(n==="svg"||n==="mathml"){const l=i.firstChild;for(;l.firstChild;)i.appendChild(l.firstChild);i.removeChild(l)}t.insertBefore(i,a)}return[s?s.nextSibling:t.firstChild,a?a.previousSibling:t.lastChild]}},Rr="transition",Ws="animation",_s=Symbol("_vtc"),b3={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},w3=aa({},o0,b3),_b=e=>(e.displayName="Transition",e.props=w3,e),m0=_b((e,{slots:t})=>En(Cv,x3(e),t)),mo=(e,t=[])=>{st(e)?e.forEach(a=>a(...t)):e&&e(...t)},uh=e=>e?st(e)?e.some(t=>t.length>1):e.length>1:!1;function x3(e){const t={};for(const oe in e)oe in b3||(t[oe]=e[oe]);if(e.css===!1)return t;const{name:a="v",type:n,duration:r,enterFromClass:o=`${a}-enter-from`,enterActiveClass:s=`${a}-enter-active`,enterToClass:i=`${a}-enter-to`,appearFromClass:l=o,appearActiveClass:c=s,appearToClass:d=i,leaveFromClass:u=`${a}-leave-from`,leaveActiveClass:h=`${a}-leave-active`,leaveToClass:f=`${a}-leave-to`}=e,m=bb(r),g=m&&m[0],_=m&&m[1],{onBeforeEnter:b,onEnter:v,onEnterCancelled:y,onLeave:M,onLeaveCancelled:x,onBeforeAppear:S=b,onAppear:L=v,onAppearCancelled:F=y}=t,te=(oe,Te,Ue,Ze)=>{oe._enterCancelled=Ze,Br(oe,Te?d:i),Br(oe,Te?c:s),Ue&&Ue()},J=(oe,Te)=>{oe._isLeaving=!1,Br(oe,u),Br(oe,f),Br(oe,h),Te&&Te()},be=oe=>(Te,Ue)=>{const Ze=oe?L:v,Me=()=>te(Te,oe,Ue);mo(Ze,[Te,Me]),hh(()=>{Br(Te,oe?l:o),Gn(Te,oe?d:i),uh(Ze)||ph(Te,n,g,Me)})};return aa(t,{onBeforeEnter(oe){mo(b,[oe]),Gn(oe,o),Gn(oe,s)},onBeforeAppear(oe){mo(S,[oe]),Gn(oe,l),Gn(oe,c)},onEnter:be(!1),onAppear:be(!0),onLeave(oe,Te){oe._isLeaving=!0;const Ue=()=>J(oe,Te);Gn(oe,u),oe._enterCancelled?(Gn(oe,h),Cc()):(Cc(),Gn(oe,h)),hh(()=>{oe._isLeaving&&(Br(oe,u),Gn(oe,f),uh(M)||ph(oe,n,_,Ue))}),mo(M,[oe,Ue])},onEnterCancelled(oe){te(oe,!1,void 0,!0),mo(y,[oe])},onAppearCancelled(oe){te(oe,!0,void 0,!0),mo(F,[oe])},onLeaveCancelled(oe){J(oe),mo(x,[oe])}})}function bb(e){if(e==null)return null;if(ea(e))return[P2(e.enter),P2(e.leave)];{const t=P2(e);return[t,t]}}function P2(e){return q1(e)}function Gn(e,t){t.split(/\s+/).forEach(a=>a&&e.classList.add(a)),(e[_s]||(e[_s]=new Set)).add(t)}function Br(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.remove(n));const a=e[_s];a&&(a.delete(t),a.size||(e[_s]=void 0))}function hh(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let wb=0;function ph(e,t,a,n){const r=e._endId=++wb,o=()=>{r===e._endId&&n()};if(a!=null)return setTimeout(o,a);const{type:s,timeout:i,propCount:l}=C3(e,t);if(!s)return n();const c=s+"end";let d=0;const u=()=>{e.removeEventListener(c,h),o()},h=f=>{f.target===e&&++d>=l&&u()};setTimeout(()=>{d<l&&u()},i+1),e.addEventListener(c,h)}function C3(e,t){const a=window.getComputedStyle(e),n=m=>(a[m]||"").split(", "),r=n(`${Rr}Delay`),o=n(`${Rr}Duration`),s=fh(r,o),i=n(`${Ws}Delay`),l=n(`${Ws}Duration`),c=fh(i,l);let d=null,u=0,h=0;t===Rr?s>0&&(d=Rr,u=s,h=o.length):t===Ws?c>0&&(d=Ws,u=c,h=l.length):(u=Math.max(s,c),d=u>0?s>c?Rr:Ws:null,h=d?d===Rr?o.length:l.length:0);const f=d===Rr&&/\b(transform|all)(,|$)/.test(n(`${Rr}Property`).toString());return{type:d,timeout:u,propCount:h,hasTransform:f}}function fh(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((a,n)=>mh(a)+mh(e[n])))}function mh(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function Cc(){return document.body.offsetHeight}function xb(e,t,a){const n=e[_s];n&&(t=(t?[t,...n]:[...n]).join(" ")),t==null?e.removeAttribute("class"):a?e.setAttribute("class",t):e.className=t}const tl=Symbol("_vod"),A3=Symbol("_vsh"),jn={beforeMount(e,{value:t},{transition:a}){e[tl]=e.style.display==="none"?"":e.style.display,a&&t?a.beforeEnter(e):Zs(e,t)},mounted(e,{value:t},{transition:a}){a&&t&&a.enter(e)},updated(e,{value:t,oldValue:a},{transition:n}){!t!=!a&&(n?t?(n.beforeEnter(e),Zs(e,!0),n.enter(e)):n.leave(e,()=>{Zs(e,!1)}):Zs(e,t))},beforeUnmount(e,{value:t}){Zs(e,t)}};function Zs(e,t){e.style.display=t?e[tl]:"none",e[A3]=!t}function Cb(){jn.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}const S3=Symbol("");function ji(e){const t=gn();if(!t)return;const a=t.ut=(r=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(o=>al(o,r))},n=()=>{const r=e(t.proxy);t.ce?al(t.ce,r):Ac(t.subTree,r),a(r)};i0(()=>{Si(n)}),ia(()=>{We(n,Cn,{flush:"post"});const r=new MutationObserver(n);r.observe(t.subTree.el.parentNode,{childList:!0}),Wn(()=>r.disconnect())})}function Ac(e,t){if(e.shapeFlag&128){const a=e.suspense;e=a.activeBranch,a.pendingBranch&&!a.isHydrating&&a.effects.push(()=>{Ac(a.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)al(e.el,t);else if(e.type===Je)e.children.forEach(a=>Ac(a,t));else if(e.type===$o){let{el:a,anchor:n}=e;for(;a&&(al(a,t),a!==n);)a=a.nextSibling}}function al(e,t){if(e.nodeType===1){const a=e.style;let n="";for(const r in t)a.setProperty(`--${r}`,t[r]),n+=`--${r}: ${t[r]};`;a[S3]=n}}const Ab=/(^|;)\s*display\s*:/;function Sb(e,t,a){const n=e.style,r=sa(a);let o=!1;if(a&&!r){if(t)if(sa(t))for(const s of t.split(";")){const i=s.slice(0,s.indexOf(":")).trim();a[i]==null&&R1(n,i,"")}else for(const s in t)a[s]==null&&R1(n,s,"");for(const s in a)s==="display"&&(o=!0),R1(n,s,a[s])}else if(r){if(t!==a){const s=n[S3];s&&(a+=";"+s),n.cssText=a,o=Ab.test(a)}}else t&&e.removeAttribute("style");tl in e&&(e[tl]=o?n.display:"",e[A3]&&(n.display="none"))}const vh=/\s*!important$/;function R1(e,t,a){if(st(a))a.forEach(n=>R1(e,t,n));else if(a==null&&(a=""),t.startsWith("--"))e.setProperty(t,a);else{const n=$b(e,t);vh.test(a)?e.setProperty(rn(n),a.replace(vh,""),"important"):e[n]=a}}const gh=["Webkit","Moz","ms"],L2={};function $b(e,t){const a=L2[t];if(a)return a;let n=Da(t);if(n!=="filter"&&n in e)return L2[t]=n;n=Hi(n);for(let r=0;r<gh.length;r++){const o=gh[r]+n;if(o in e)return L2[t]=o}return t}const yh="http://www.w3.org/1999/xlink";function Mh(e,t,a,n,r,o=K9(t)){n&&t.startsWith("xlink:")?a==null?e.removeAttributeNS(yh,t.slice(6,t.length)):e.setAttributeNS(yh,t,a):a==null||o&&!jm(a)?e.removeAttribute(t):e.setAttribute(t,o?"":Bn(a)?String(a):a)}function _h(e,t,a,n,r){if(t==="innerHTML"||t==="textContent"){a!=null&&(e[t]=t==="innerHTML"?_3(a):a);return}const o=e.tagName;if(t==="value"&&o!=="PROGRESS"&&!o.includes("-")){const i=o==="OPTION"?e.getAttribute("value")||"":e.value,l=a==null?e.type==="checkbox"?"on":"":String(a);(i!==l||!("_value"in e))&&(e.value=l),a==null&&e.removeAttribute(t),e._value=a;return}let s=!1;if(a===""||a==null){const i=typeof e[t];i==="boolean"?a=jm(a):a==null&&i==="string"?(a="",s=!0):i==="number"&&(a=0,s=!0)}try{e[t]=a}catch{}s&&e.removeAttribute(r||t)}function br(e,t,a,n){e.addEventListener(t,a,n)}function Eb(e,t,a,n){e.removeEventListener(t,a,n)}const bh=Symbol("_vei");function Ib(e,t,a,n,r=null){const o=e[bh]||(e[bh]={}),s=o[t];if(n&&s)s.value=n;else{const[i,l]=kb(t);if(n){const c=o[t]=Lb(n,r);br(e,i,c,l)}else s&&(Eb(e,i,s,l),o[t]=void 0)}}const wh=/(?:Once|Passive|Capture)$/;function kb(e){let t;if(wh.test(e)){t={};let n;for(;n=e.match(wh);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):rn(e.slice(2)),t]}let V2=0;const Tb=Promise.resolve(),Pb=()=>V2||(Tb.then(()=>V2=0),V2=Date.now());function Lb(e,t){const a=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=a.attached)return;$n(Vb(n,a.value),t,5,[n])};return a.value=e,a.attached=Pb(),a}function Vb(e,t){if(st(t)){const a=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{a.call(e),e._stopped=!0},t.map(n=>r=>!r._stopped&&n&&n(r))}else return t}const xh=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Ob=(e,t,a,n,r,o)=>{const s=r==="svg";t==="class"?xb(e,n,s):t==="style"?Sb(e,a,n):Oi(t)?Wc(t)||Ib(e,t,a,n,o):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Hb(e,t,n,s))?(_h(e,t,n),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Mh(e,t,n,s,o,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!sa(n))?_h(e,Da(t),n,o,t):(t==="true-value"?e._trueValue=n:t==="false-value"&&(e._falseValue=n),Mh(e,t,n,s))};function Hb(e,t,a,n){if(n)return!!(t==="innerHTML"||t==="textContent"||t in e&&xh(t)&&gt(a));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return xh(t)&&sa(a)?!1:t in e}const Ch={};/*! #__NO_SIDE_EFFECTS__ */function $3(e,t,a){const n=$e(e,t);yl(n)&&aa(n,t);class r extends Vl{constructor(s){super(n,s,a)}}return r.def=n,r}/*! #__NO_SIDE_EFFECTS__ */const Rb=(e,t)=>$3(e,t,R3),Nb=typeof HTMLElement<"u"?HTMLElement:class{};class Vl extends Nb{constructor(t,a={},n=rl){super(),this._def=t,this._props=a,this._createApp=n,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&n!==rl?this._root=this.shadowRoot:t.shadowRoot!==!1?(this.attachShadow({mode:"open"}),this._root=this.shadowRoot):this._root=this,this._def.__asyncLoader||this._resolveProps(this._def)}connectedCallback(){if(!this.isConnected)return;this.shadowRoot||this._parseSlots(),this._connected=!0;let t=this;for(;t=t&&(t.parentNode||t.host);)if(t instanceof Vl){this._parent=t;break}this._instance||(this._resolved?(this._setParent(),this._update()):t&&t._pendingResolve?this._pendingResolve=t._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(t=this._parent){t&&(this._instance.parent=t._instance,this._instance.provides=t._instance.provides)}disconnectedCallback(){this._connected=!1,qa(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null)})}_resolveDef(){if(this._pendingResolve)return;for(let n=0;n<this.attributes.length;n++)this._setAttr(this.attributes[n].name);this._ob=new MutationObserver(n=>{for(const r of n)this._setAttr(r.attributeName)}),this._ob.observe(this,{attributes:!0});const t=(n,r=!1)=>{this._resolved=!0,this._pendingResolve=void 0;const{props:o,styles:s}=n;let i;if(o&&!st(o))for(const l in o){const c=o[l];(c===Number||c&&c.type===Number)&&(l in this._props&&(this._props[l]=q1(this._props[l])),(i||(i=Object.create(null)))[Da(l)]=!0)}this._numberProps=i,r&&this._resolveProps(n),this.shadowRoot&&this._applyStyles(s),this._mount(n)},a=this._def.__asyncLoader;a?this._pendingResolve=a().then(n=>t(this._def=n,!0)):t(this._def)}_mount(t){this._app=this._createApp(t),t.configureApp&&t.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);const a=this._instance&&this._instance.exposed;if(a)for(const n in a)Kt(this,n)||Object.defineProperty(this,n,{get:()=>E(a[n])})}_resolveProps(t){const{props:a}=t,n=st(a)?a:Object.keys(a||{});for(const r of Object.keys(this))r[0]!=="_"&&n.includes(r)&&this._setProp(r,this[r]);for(const r of n.map(Da))Object.defineProperty(this,r,{get(){return this._getProp(r)},set(o){this._setProp(r,o,!0,!0)}})}_setAttr(t){if(t.startsWith("data-v-"))return;const a=this.hasAttribute(t);let n=a?this.getAttribute(t):Ch;const r=Da(t);a&&this._numberProps&&this._numberProps[r]&&(n=q1(n)),this._setProp(r,n,!1,!0)}_getProp(t){return this._props[t]}_setProp(t,a,n=!0,r=!1){if(a!==this._props[t]&&(a===Ch?delete this._props[t]:(this._props[t]=a,t==="key"&&this._app&&(this._app._ceVNode.key=a)),r&&this._instance&&this._update(),n)){const o=this._ob;o&&o.disconnect(),a===!0?this.setAttribute(rn(t),""):typeof a=="string"||typeof a=="number"?this.setAttribute(rn(t),a+""):a||this.removeAttribute(rn(t)),o&&o.observe(this,{attributes:!0})}}_update(){H3(this._createVNode(),this._root)}_createVNode(){const t={};this.shadowRoot||(t.onVnodeMounted=t.onVnodeUpdated=this._renderSlots.bind(this));const a=Ce(this._def,aa(t,this._props));return this._instance||(a.ce=n=>{this._instance=n,n.ce=this,n.isCE=!0;const r=(o,s)=>{this.dispatchEvent(new CustomEvent(o,yl(s[0])?aa({detail:s},s[0]):{detail:s}))};n.emit=(o,...s)=>{r(o,s),rn(o)!==o&&r(rn(o),s)},this._setParent()}),a}_applyStyles(t,a){if(!t)return;if(a){if(a===this._def||this._styleChildren.has(a))return;this._styleChildren.add(a)}const n=this._nonce;for(let r=t.length-1;r>=0;r--){const o=document.createElement("style");n&&o.setAttribute("nonce",n),o.textContent=t[r],this.shadowRoot.prepend(o)}}_parseSlots(){const t=this._slots={};let a;for(;a=this.firstChild;){const n=a.nodeType===1&&a.getAttribute("slot")||"default";(t[n]||(t[n]=[])).push(a),this.removeChild(a)}}_renderSlots(){const t=(this._teleportTarget||this).querySelectorAll("slot"),a=this._instance.type.__scopeId;for(let n=0;n<t.length;n++){const r=t[n],o=r.getAttribute("name")||"default",s=this._slots[o],i=r.parentNode;if(s)for(const l of s){if(a&&l.nodeType===1){const c=a+"-s",d=document.createTreeWalker(l,1);l.setAttribute(c,"");let u;for(;u=d.nextNode();)u.setAttribute(c,"")}i.insertBefore(l,r)}else for(;r.firstChild;)i.insertBefore(r.firstChild,r);i.removeChild(r)}}_injectChildStyle(t){this._applyStyles(t.styles,t)}_removeChildStyle(t){}}function E3(e){const t=gn(),a=t&&t.ce;return a||null}function Db(){const e=E3();return e&&e.shadowRoot}function Bb(e="$style"){{const t=gn();if(!t)return Nt;const a=t.type.__cssModules;if(!a)return Nt;const n=a[e];return n||Nt}}const I3=new WeakMap,k3=new WeakMap,nl=Symbol("_moveCb"),Ah=Symbol("_enterCb"),Fb=e=>(delete e.props.mode,e),jb=Fb({name:"TransitionGroup",props:aa({},w3,{tag:String,moveClass:String}),setup(e,{slots:t}){const a=gn(),n=r0();let r,o;return Tl(()=>{if(!r.length)return;const s=e.moveClass||`${e.name||"v"}-move`;if(!Zb(r[0].el,a.vnode.el,s))return;r.forEach(zb),r.forEach(qb);const i=r.filter(Wb);Cc(),i.forEach(l=>{const c=l.el,d=c.style;Gn(c,s),d.transform=d.webkitTransform=d.transitionDuration="";const u=c[nl]=h=>{h&&h.target!==c||(!h||/transform$/.test(h.propertyName))&&(c.removeEventListener("transitionend",u),c[nl]=null,Br(c,s))};c.addEventListener("transitionend",u)})}),()=>{const s=St(e),i=x3(s);let l=s.tag||Je;if(r=[],o)for(let c=0;c<o.length;c++){const d=o[c];d.el&&d.el instanceof Element&&(r.push(d),Cr(d,ys(d,i,n,a)),I3.set(d,d.el.getBoundingClientRect()))}o=t.default?Il(t.default()):[];for(let c=0;c<o.length;c++){const d=o[c];d.key!=null&&Cr(d,ys(d,i,n,a))}return Ce(l,null,o)}}}),Ub=jb;function zb(e){const t=e.el;t[nl]&&t[nl](),t[Ah]&&t[Ah]()}function qb(e){k3.set(e,e.el.getBoundingClientRect())}function Wb(e){const t=I3.get(e),a=k3.get(e),n=t.left-a.left,r=t.top-a.top;if(n||r){const o=e.el.style;return o.transform=o.webkitTransform=`translate(${n}px,${r}px)`,o.transitionDuration="0s",e}}function Zb(e,t,a){const n=e.cloneNode(),r=e[_s];r&&r.forEach(i=>{i.split(/\s+/).forEach(l=>l&&n.classList.remove(l))}),a.split(/\s+/).forEach(i=>i&&n.classList.add(i)),n.style.display="none";const o=t.nodeType===1?t:t.parentNode;o.appendChild(n);const{hasTransform:s}=C3(n);return o.removeChild(n),s}const to=e=>{const t=e.props["onUpdate:modelValue"]||!1;return st(t)?a=>hs(t,a):t};function Kb(e){e.target.composing=!0}function Sh(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const An=Symbol("_assign"),bs={created(e,{modifiers:{lazy:t,trim:a,number:n}},r){e[An]=to(r);const o=n||r.props&&r.props.type==="number";br(e,t?"change":"input",s=>{if(s.target.composing)return;let i=e.value;a&&(i=i.trim()),o&&(i=z1(i)),e[An](i)}),a&&br(e,"change",()=>{e.value=e.value.trim()}),t||(br(e,"compositionstart",Kb),br(e,"compositionend",Sh),br(e,"change",Sh))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:a,modifiers:{lazy:n,trim:r,number:o}},s){if(e[An]=to(s),e.composing)return;const i=(o||e.type==="number")&&!/^0\d/.test(e.value)?z1(e.value):e.value,l=t??"";i!==l&&(document.activeElement===e&&e.type!=="range"&&(n&&t===a||r&&e.value.trim()===l)||(e.value=l))}},v0={deep:!0,created(e,t,a){e[An]=to(a),br(e,"change",()=>{const n=e._modelValue,r=ws(e),o=e.checked,s=e[An];if(st(n)){const i=bl(n,r),l=i!==-1;if(o&&!l)s(n.concat(r));else if(!o&&l){const c=[...n];c.splice(i,1),s(c)}}else if(Vo(n)){const i=new Set(n);o?i.add(r):i.delete(r),s(i)}else s(T3(e,o))})},mounted:$h,beforeUpdate(e,t,a){e[An]=to(a),$h(e,t,a)}};function $h(e,{value:t,oldValue:a},n){e._modelValue=t;let r;if(st(t))r=bl(t,n.props.value)>-1;else if(Vo(t))r=t.has(n.props.value);else{if(t===a)return;r=Qr(t,T3(e,!0))}e.checked!==r&&(e.checked=r)}const g0={created(e,{value:t},a){e.checked=Qr(t,a.props.value),e[An]=to(a),br(e,"change",()=>{e[An](ws(e))})},beforeUpdate(e,{value:t,oldValue:a},n){e[An]=to(n),t!==a&&(e.checked=Qr(t,n.props.value))}},y0={deep:!0,created(e,{value:t,modifiers:{number:a}},n){const r=Vo(t);br(e,"change",()=>{const o=Array.prototype.filter.call(e.options,s=>s.selected).map(s=>a?z1(ws(s)):ws(s));e[An](e.multiple?r?new Set(o):o:o[0]),e._assigning=!0,qa(()=>{e._assigning=!1})}),e[An]=to(n)},mounted(e,{value:t}){Eh(e,t)},beforeUpdate(e,t,a){e[An]=to(a)},updated(e,{value:t}){e._assigning||Eh(e,t)}};function Eh(e,t){const a=e.multiple,n=st(t);if(!(a&&!n&&!Vo(t))){for(let r=0,o=e.options.length;r<o;r++){const s=e.options[r],i=ws(s);if(a)if(n){const l=typeof i;l==="string"||l==="number"?s.selected=t.some(c=>String(c)===String(i)):s.selected=bl(t,i)>-1}else s.selected=t.has(i);else if(Qr(ws(s),t)){e.selectedIndex!==r&&(e.selectedIndex=r);return}}!a&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function ws(e){return"_value"in e?e._value:e.value}function T3(e,t){const a=t?"_trueValue":"_falseValue";return a in e?e[a]:t}const M0={created(e,t,a){v1(e,t,a,null,"created")},mounted(e,t,a){v1(e,t,a,null,"mounted")},beforeUpdate(e,t,a,n){v1(e,t,a,n,"beforeUpdate")},updated(e,t,a,n){v1(e,t,a,n,"updated")}};function P3(e,t){switch(e){case"SELECT":return y0;case"TEXTAREA":return bs;default:switch(t){case"checkbox":return v0;case"radio":return g0;default:return bs}}}function v1(e,t,a,n,r){const s=P3(e.tagName,a.props&&a.props.type)[r];s&&s(e,t,a,n)}function Gb(){bs.getSSRProps=({value:e})=>({value:e}),g0.getSSRProps=({value:e},t)=>{if(t.props&&Qr(t.props.value,e))return{checked:!0}},v0.getSSRProps=({value:e},t)=>{if(st(e)){if(t.props&&bl(e,t.props.value)>-1)return{checked:!0}}else if(Vo(e)){if(t.props&&e.has(t.props.value))return{checked:!0}}else if(e)return{checked:!0}},M0.getSSRProps=(e,t)=>{if(typeof t.type!="string")return;const a=P3(t.type.toUpperCase(),t.props&&t.props.type);if(a.getSSRProps)return a.getSSRProps(e,t)}}const Jb=["ctrl","shift","alt","meta"],Xb={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>Jb.some(a=>e[`${a}Key`]&&!t.includes(a))},sn=(e,t)=>{const a=e._withMods||(e._withMods={}),n=t.join(".");return a[n]||(a[n]=(r,...o)=>{for(let s=0;s<t.length;s++){const i=Xb[t[s]];if(i&&i(r,t))return}return e(r,...o)})},Yb={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Sr=(e,t)=>{const a=e._withKeys||(e._withKeys={}),n=t.join(".");return a[n]||(a[n]=r=>{if(!("key"in r))return;const o=rn(r.key);if(t.some(s=>s===o||Yb[s]===o))return e(r)})},L3=aa({patchProp:Ob},Mb);let fi,Ih=!1;function V3(){return fi||(fi=Jv(L3))}function O3(){return fi=Ih?fi:Xv(L3),Ih=!0,fi}const H3=(...e)=>{V3().render(...e)},Qb=(...e)=>{O3().hydrate(...e)},rl=(...e)=>{const t=V3().createApp(...e),{mount:a}=t;return t.mount=n=>{const r=D3(n);if(!r)return;const o=t._component;!gt(o)&&!o.render&&!o.template&&(o.template=r.innerHTML),r.nodeType===1&&(r.textContent="");const s=a(r,!1,N3(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),s},t},R3=(...e)=>{const t=O3().createApp(...e),{mount:a}=t;return t.mount=n=>{const r=D3(n);if(r)return a(r,!0,N3(r))},t};function N3(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function D3(e){return sa(e)?document.querySelector(e):e}let kh=!1;const ew=()=>{kh||(kh=!0,Gb(),Cb())};/**
24
+ **/let xc;const ch=typeof window<"u"&&window.trustedTypes;if(ch)try{xc=ch.createPolicy("vue",{createHTML:e=>e})}catch{}const _3=xc?e=>xc.createHTML(e):e=>e,gb="http://www.w3.org/2000/svg",yb="http://www.w3.org/1998/Math/MathML",yr=typeof document<"u"?document:null,dh=yr&&yr.createElement("template"),Mb={insert:(e,t,a)=>{t.insertBefore(e,a||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,a,n)=>{const r=t==="svg"?yr.createElementNS(gb,e):t==="mathml"?yr.createElementNS(yb,e):a?yr.createElement(e,{is:a}):yr.createElement(e);return e==="select"&&n&&n.multiple!=null&&r.setAttribute("multiple",n.multiple),r},createText:e=>yr.createTextNode(e),createComment:e=>yr.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>yr.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,a,n,r,o){const s=a?a.previousSibling:t.lastChild;if(r&&(r===o||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),a),!(r===o||!(r=r.nextSibling)););else{dh.innerHTML=_3(n==="svg"?`<svg>${e}</svg>`:n==="mathml"?`<math>${e}</math>`:e);const i=dh.content;if(n==="svg"||n==="mathml"){const l=i.firstChild;for(;l.firstChild;)i.appendChild(l.firstChild);i.removeChild(l)}t.insertBefore(i,a)}return[s?s.nextSibling:t.firstChild,a?a.previousSibling:t.lastChild]}},Nr="transition",Zs="animation",bs=Symbol("_vtc"),b3={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},w3=na({},o0,b3),_b=e=>(e.displayName="Transition",e.props=w3,e),m0=_b((e,{slots:t})=>En(Cv,x3(e),t)),vo=(e,t=[])=>{st(e)?e.forEach(a=>a(...t)):e&&e(...t)},uh=e=>e?st(e)?e.some(t=>t.length>1):e.length>1:!1;function x3(e){const t={};for(const oe in e)oe in b3||(t[oe]=e[oe]);if(e.css===!1)return t;const{name:a="v",type:n,duration:r,enterFromClass:o=`${a}-enter-from`,enterActiveClass:s=`${a}-enter-active`,enterToClass:i=`${a}-enter-to`,appearFromClass:l=o,appearActiveClass:c=s,appearToClass:d=i,leaveFromClass:u=`${a}-leave-from`,leaveActiveClass:h=`${a}-leave-active`,leaveToClass:f=`${a}-leave-to`}=e,m=bb(r),g=m&&m[0],_=m&&m[1],{onBeforeEnter:b,onEnter:v,onEnterCancelled:y,onLeave:M,onLeaveCancelled:x,onBeforeAppear:S=b,onAppear:L=v,onAppearCancelled:F=y}=t,te=(oe,Te,Ue,Ze)=>{oe._enterCancelled=Ze,Fr(oe,Te?d:i),Fr(oe,Te?c:s),Ue&&Ue()},J=(oe,Te)=>{oe._isLeaving=!1,Fr(oe,u),Fr(oe,f),Fr(oe,h),Te&&Te()},be=oe=>(Te,Ue)=>{const Ze=oe?L:v,Me=()=>te(Te,oe,Ue);vo(Ze,[Te,Me]),hh(()=>{Fr(Te,oe?l:o),Jn(Te,oe?d:i),uh(Ze)||ph(Te,n,g,Me)})};return na(t,{onBeforeEnter(oe){vo(b,[oe]),Jn(oe,o),Jn(oe,s)},onBeforeAppear(oe){vo(S,[oe]),Jn(oe,l),Jn(oe,c)},onEnter:be(!1),onAppear:be(!0),onLeave(oe,Te){oe._isLeaving=!0;const Ue=()=>J(oe,Te);Jn(oe,u),oe._enterCancelled?(Jn(oe,h),Cc()):(Cc(),Jn(oe,h)),hh(()=>{oe._isLeaving&&(Fr(oe,u),Jn(oe,f),uh(M)||ph(oe,n,_,Ue))}),vo(M,[oe,Ue])},onEnterCancelled(oe){te(oe,!1,void 0,!0),vo(y,[oe])},onAppearCancelled(oe){te(oe,!0,void 0,!0),vo(F,[oe])},onLeaveCancelled(oe){J(oe),vo(x,[oe])}})}function bb(e){if(e==null)return null;if(ta(e))return[P2(e.enter),P2(e.leave)];{const t=P2(e);return[t,t]}}function P2(e){return q1(e)}function Jn(e,t){t.split(/\s+/).forEach(a=>a&&e.classList.add(a)),(e[bs]||(e[bs]=new Set)).add(t)}function Fr(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.remove(n));const a=e[bs];a&&(a.delete(t),a.size||(e[bs]=void 0))}function hh(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let wb=0;function ph(e,t,a,n){const r=e._endId=++wb,o=()=>{r===e._endId&&n()};if(a!=null)return setTimeout(o,a);const{type:s,timeout:i,propCount:l}=C3(e,t);if(!s)return n();const c=s+"end";let d=0;const u=()=>{e.removeEventListener(c,h),o()},h=f=>{f.target===e&&++d>=l&&u()};setTimeout(()=>{d<l&&u()},i+1),e.addEventListener(c,h)}function C3(e,t){const a=window.getComputedStyle(e),n=m=>(a[m]||"").split(", "),r=n(`${Nr}Delay`),o=n(`${Nr}Duration`),s=fh(r,o),i=n(`${Zs}Delay`),l=n(`${Zs}Duration`),c=fh(i,l);let d=null,u=0,h=0;t===Nr?s>0&&(d=Nr,u=s,h=o.length):t===Zs?c>0&&(d=Zs,u=c,h=l.length):(u=Math.max(s,c),d=u>0?s>c?Nr:Zs:null,h=d?d===Nr?o.length:l.length:0);const f=d===Nr&&/\b(transform|all)(,|$)/.test(n(`${Nr}Property`).toString());return{type:d,timeout:u,propCount:h,hasTransform:f}}function fh(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((a,n)=>mh(a)+mh(e[n])))}function mh(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function Cc(){return document.body.offsetHeight}function xb(e,t,a){const n=e[bs];n&&(t=(t?[t,...n]:[...n]).join(" ")),t==null?e.removeAttribute("class"):a?e.setAttribute("class",t):e.className=t}const tl=Symbol("_vod"),A3=Symbol("_vsh"),Un={beforeMount(e,{value:t},{transition:a}){e[tl]=e.style.display==="none"?"":e.style.display,a&&t?a.beforeEnter(e):Ks(e,t)},mounted(e,{value:t},{transition:a}){a&&t&&a.enter(e)},updated(e,{value:t,oldValue:a},{transition:n}){!t!=!a&&(n?t?(n.beforeEnter(e),Ks(e,!0),n.enter(e)):n.leave(e,()=>{Ks(e,!1)}):Ks(e,t))},beforeUnmount(e,{value:t}){Ks(e,t)}};function Ks(e,t){e.style.display=t?e[tl]:"none",e[A3]=!t}function Cb(){Un.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}const S3=Symbol("");function ji(e){const t=gn();if(!t)return;const a=t.ut=(r=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(o=>al(o,r))},n=()=>{const r=e(t.proxy);t.ce?al(t.ce,r):Ac(t.subTree,r),a(r)};i0(()=>{Si(n)}),ia(()=>{We(n,Cn,{flush:"post"});const r=new MutationObserver(n);r.observe(t.subTree.el.parentNode,{childList:!0}),Zn(()=>r.disconnect())})}function Ac(e,t){if(e.shapeFlag&128){const a=e.suspense;e=a.activeBranch,a.pendingBranch&&!a.isHydrating&&a.effects.push(()=>{Ac(a.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)al(e.el,t);else if(e.type===Je)e.children.forEach(a=>Ac(a,t));else if(e.type===Eo){let{el:a,anchor:n}=e;for(;a&&(al(a,t),a!==n);)a=a.nextSibling}}function al(e,t){if(e.nodeType===1){const a=e.style;let n="";for(const r in t)a.setProperty(`--${r}`,t[r]),n+=`--${r}: ${t[r]};`;a[S3]=n}}const Ab=/(^|;)\s*display\s*:/;function Sb(e,t,a){const n=e.style,r=sa(a);let o=!1;if(a&&!r){if(t)if(sa(t))for(const s of t.split(";")){const i=s.slice(0,s.indexOf(":")).trim();a[i]==null&&R1(n,i,"")}else for(const s in t)a[s]==null&&R1(n,s,"");for(const s in a)s==="display"&&(o=!0),R1(n,s,a[s])}else if(r){if(t!==a){const s=n[S3];s&&(a+=";"+s),n.cssText=a,o=Ab.test(a)}}else t&&e.removeAttribute("style");tl in e&&(e[tl]=o?n.display:"",e[A3]&&(n.display="none"))}const vh=/\s*!important$/;function R1(e,t,a){if(st(a))a.forEach(n=>R1(e,t,n));else if(a==null&&(a=""),t.startsWith("--"))e.setProperty(t,a);else{const n=$b(e,t);vh.test(a)?e.setProperty(rn(n),a.replace(vh,""),"important"):e[n]=a}}const gh=["Webkit","Moz","ms"],L2={};function $b(e,t){const a=L2[t];if(a)return a;let n=Da(t);if(n!=="filter"&&n in e)return L2[t]=n;n=Hi(n);for(let r=0;r<gh.length;r++){const o=gh[r]+n;if(o in e)return L2[t]=o}return t}const yh="http://www.w3.org/1999/xlink";function Mh(e,t,a,n,r,o=K9(t)){n&&t.startsWith("xlink:")?a==null?e.removeAttributeNS(yh,t.slice(6,t.length)):e.setAttributeNS(yh,t,a):a==null||o&&!jm(a)?e.removeAttribute(t):e.setAttribute(t,o?"":Fn(a)?String(a):a)}function _h(e,t,a,n,r){if(t==="innerHTML"||t==="textContent"){a!=null&&(e[t]=t==="innerHTML"?_3(a):a);return}const o=e.tagName;if(t==="value"&&o!=="PROGRESS"&&!o.includes("-")){const i=o==="OPTION"?e.getAttribute("value")||"":e.value,l=a==null?e.type==="checkbox"?"on":"":String(a);(i!==l||!("_value"in e))&&(e.value=l),a==null&&e.removeAttribute(t),e._value=a;return}let s=!1;if(a===""||a==null){const i=typeof e[t];i==="boolean"?a=jm(a):a==null&&i==="string"?(a="",s=!0):i==="number"&&(a=0,s=!0)}try{e[t]=a}catch{}s&&e.removeAttribute(r||t)}function wr(e,t,a,n){e.addEventListener(t,a,n)}function Eb(e,t,a,n){e.removeEventListener(t,a,n)}const bh=Symbol("_vei");function Ib(e,t,a,n,r=null){const o=e[bh]||(e[bh]={}),s=o[t];if(n&&s)s.value=n;else{const[i,l]=kb(t);if(n){const c=o[t]=Lb(n,r);wr(e,i,c,l)}else s&&(Eb(e,i,s,l),o[t]=void 0)}}const wh=/(?:Once|Passive|Capture)$/;function kb(e){let t;if(wh.test(e)){t={};let n;for(;n=e.match(wh);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):rn(e.slice(2)),t]}let V2=0;const Tb=Promise.resolve(),Pb=()=>V2||(Tb.then(()=>V2=0),V2=Date.now());function Lb(e,t){const a=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=a.attached)return;$n(Vb(n,a.value),t,5,[n])};return a.value=e,a.attached=Pb(),a}function Vb(e,t){if(st(t)){const a=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{a.call(e),e._stopped=!0},t.map(n=>r=>!r._stopped&&n&&n(r))}else return t}const xh=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Ob=(e,t,a,n,r,o)=>{const s=r==="svg";t==="class"?xb(e,n,s):t==="style"?Sb(e,a,n):Oi(t)?Wc(t)||Ib(e,t,a,n,o):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Hb(e,t,n,s))?(_h(e,t,n),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Mh(e,t,n,s,o,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!sa(n))?_h(e,Da(t),n,o,t):(t==="true-value"?e._trueValue=n:t==="false-value"&&(e._falseValue=n),Mh(e,t,n,s))};function Hb(e,t,a,n){if(n)return!!(t==="innerHTML"||t==="textContent"||t in e&&xh(t)&&gt(a));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return xh(t)&&sa(a)?!1:t in e}const Ch={};/*! #__NO_SIDE_EFFECTS__ */function $3(e,t,a){const n=$e(e,t);yl(n)&&na(n,t);class r extends Vl{constructor(s){super(n,s,a)}}return r.def=n,r}/*! #__NO_SIDE_EFFECTS__ */const Rb=(e,t)=>$3(e,t,R3),Nb=typeof HTMLElement<"u"?HTMLElement:class{};class Vl extends Nb{constructor(t,a={},n=rl){super(),this._def=t,this._props=a,this._createApp=n,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&n!==rl?this._root=this.shadowRoot:t.shadowRoot!==!1?(this.attachShadow({mode:"open"}),this._root=this.shadowRoot):this._root=this,this._def.__asyncLoader||this._resolveProps(this._def)}connectedCallback(){if(!this.isConnected)return;this.shadowRoot||this._parseSlots(),this._connected=!0;let t=this;for(;t=t&&(t.parentNode||t.host);)if(t instanceof Vl){this._parent=t;break}this._instance||(this._resolved?(this._setParent(),this._update()):t&&t._pendingResolve?this._pendingResolve=t._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(t=this._parent){t&&(this._instance.parent=t._instance,this._instance.provides=t._instance.provides)}disconnectedCallback(){this._connected=!1,qa(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null)})}_resolveDef(){if(this._pendingResolve)return;for(let n=0;n<this.attributes.length;n++)this._setAttr(this.attributes[n].name);this._ob=new MutationObserver(n=>{for(const r of n)this._setAttr(r.attributeName)}),this._ob.observe(this,{attributes:!0});const t=(n,r=!1)=>{this._resolved=!0,this._pendingResolve=void 0;const{props:o,styles:s}=n;let i;if(o&&!st(o))for(const l in o){const c=o[l];(c===Number||c&&c.type===Number)&&(l in this._props&&(this._props[l]=q1(this._props[l])),(i||(i=Object.create(null)))[Da(l)]=!0)}this._numberProps=i,r&&this._resolveProps(n),this.shadowRoot&&this._applyStyles(s),this._mount(n)},a=this._def.__asyncLoader;a?this._pendingResolve=a().then(n=>t(this._def=n,!0)):t(this._def)}_mount(t){this._app=this._createApp(t),t.configureApp&&t.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);const a=this._instance&&this._instance.exposed;if(a)for(const n in a)Kt(this,n)||Object.defineProperty(this,n,{get:()=>E(a[n])})}_resolveProps(t){const{props:a}=t,n=st(a)?a:Object.keys(a||{});for(const r of Object.keys(this))r[0]!=="_"&&n.includes(r)&&this._setProp(r,this[r]);for(const r of n.map(Da))Object.defineProperty(this,r,{get(){return this._getProp(r)},set(o){this._setProp(r,o,!0,!0)}})}_setAttr(t){if(t.startsWith("data-v-"))return;const a=this.hasAttribute(t);let n=a?this.getAttribute(t):Ch;const r=Da(t);a&&this._numberProps&&this._numberProps[r]&&(n=q1(n)),this._setProp(r,n,!1,!0)}_getProp(t){return this._props[t]}_setProp(t,a,n=!0,r=!1){if(a!==this._props[t]&&(a===Ch?delete this._props[t]:(this._props[t]=a,t==="key"&&this._app&&(this._app._ceVNode.key=a)),r&&this._instance&&this._update(),n)){const o=this._ob;o&&o.disconnect(),a===!0?this.setAttribute(rn(t),""):typeof a=="string"||typeof a=="number"?this.setAttribute(rn(t),a+""):a||this.removeAttribute(rn(t)),o&&o.observe(this,{attributes:!0})}}_update(){H3(this._createVNode(),this._root)}_createVNode(){const t={};this.shadowRoot||(t.onVnodeMounted=t.onVnodeUpdated=this._renderSlots.bind(this));const a=Ce(this._def,na(t,this._props));return this._instance||(a.ce=n=>{this._instance=n,n.ce=this,n.isCE=!0;const r=(o,s)=>{this.dispatchEvent(new CustomEvent(o,yl(s[0])?na({detail:s},s[0]):{detail:s}))};n.emit=(o,...s)=>{r(o,s),rn(o)!==o&&r(rn(o),s)},this._setParent()}),a}_applyStyles(t,a){if(!t)return;if(a){if(a===this._def||this._styleChildren.has(a))return;this._styleChildren.add(a)}const n=this._nonce;for(let r=t.length-1;r>=0;r--){const o=document.createElement("style");n&&o.setAttribute("nonce",n),o.textContent=t[r],this.shadowRoot.prepend(o)}}_parseSlots(){const t=this._slots={};let a;for(;a=this.firstChild;){const n=a.nodeType===1&&a.getAttribute("slot")||"default";(t[n]||(t[n]=[])).push(a),this.removeChild(a)}}_renderSlots(){const t=(this._teleportTarget||this).querySelectorAll("slot"),a=this._instance.type.__scopeId;for(let n=0;n<t.length;n++){const r=t[n],o=r.getAttribute("name")||"default",s=this._slots[o],i=r.parentNode;if(s)for(const l of s){if(a&&l.nodeType===1){const c=a+"-s",d=document.createTreeWalker(l,1);l.setAttribute(c,"");let u;for(;u=d.nextNode();)u.setAttribute(c,"")}i.insertBefore(l,r)}else for(;r.firstChild;)i.insertBefore(r.firstChild,r);i.removeChild(r)}}_injectChildStyle(t){this._applyStyles(t.styles,t)}_removeChildStyle(t){}}function E3(e){const t=gn(),a=t&&t.ce;return a||null}function Db(){const e=E3();return e&&e.shadowRoot}function Bb(e="$style"){{const t=gn();if(!t)return Nt;const a=t.type.__cssModules;if(!a)return Nt;const n=a[e];return n||Nt}}const I3=new WeakMap,k3=new WeakMap,nl=Symbol("_moveCb"),Ah=Symbol("_enterCb"),Fb=e=>(delete e.props.mode,e),jb=Fb({name:"TransitionGroup",props:na({},w3,{tag:String,moveClass:String}),setup(e,{slots:t}){const a=gn(),n=r0();let r,o;return Tl(()=>{if(!r.length)return;const s=e.moveClass||`${e.name||"v"}-move`;if(!Zb(r[0].el,a.vnode.el,s))return;r.forEach(zb),r.forEach(qb);const i=r.filter(Wb);Cc(),i.forEach(l=>{const c=l.el,d=c.style;Jn(c,s),d.transform=d.webkitTransform=d.transitionDuration="";const u=c[nl]=h=>{h&&h.target!==c||(!h||/transform$/.test(h.propertyName))&&(c.removeEventListener("transitionend",u),c[nl]=null,Fr(c,s))};c.addEventListener("transitionend",u)})}),()=>{const s=St(e),i=x3(s);let l=s.tag||Je;if(r=[],o)for(let c=0;c<o.length;c++){const d=o[c];d.el&&d.el instanceof Element&&(r.push(d),Ar(d,Ms(d,i,n,a)),I3.set(d,d.el.getBoundingClientRect()))}o=t.default?Il(t.default()):[];for(let c=0;c<o.length;c++){const d=o[c];d.key!=null&&Ar(d,Ms(d,i,n,a))}return Ce(l,null,o)}}}),Ub=jb;function zb(e){const t=e.el;t[nl]&&t[nl](),t[Ah]&&t[Ah]()}function qb(e){k3.set(e,e.el.getBoundingClientRect())}function Wb(e){const t=I3.get(e),a=k3.get(e),n=t.left-a.left,r=t.top-a.top;if(n||r){const o=e.el.style;return o.transform=o.webkitTransform=`translate(${n}px,${r}px)`,o.transitionDuration="0s",e}}function Zb(e,t,a){const n=e.cloneNode(),r=e[bs];r&&r.forEach(i=>{i.split(/\s+/).forEach(l=>l&&n.classList.remove(l))}),a.split(/\s+/).forEach(i=>i&&n.classList.add(i)),n.style.display="none";const o=t.nodeType===1?t:t.parentNode;o.appendChild(n);const{hasTransform:s}=C3(n);return o.removeChild(n),s}const ao=e=>{const t=e.props["onUpdate:modelValue"]||!1;return st(t)?a=>ps(t,a):t};function Kb(e){e.target.composing=!0}function Sh(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const An=Symbol("_assign"),ws={created(e,{modifiers:{lazy:t,trim:a,number:n}},r){e[An]=ao(r);const o=n||r.props&&r.props.type==="number";wr(e,t?"change":"input",s=>{if(s.target.composing)return;let i=e.value;a&&(i=i.trim()),o&&(i=z1(i)),e[An](i)}),a&&wr(e,"change",()=>{e.value=e.value.trim()}),t||(wr(e,"compositionstart",Kb),wr(e,"compositionend",Sh),wr(e,"change",Sh))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:a,modifiers:{lazy:n,trim:r,number:o}},s){if(e[An]=ao(s),e.composing)return;const i=(o||e.type==="number")&&!/^0\d/.test(e.value)?z1(e.value):e.value,l=t??"";i!==l&&(document.activeElement===e&&e.type!=="range"&&(n&&t===a||r&&e.value.trim()===l)||(e.value=l))}},v0={deep:!0,created(e,t,a){e[An]=ao(a),wr(e,"change",()=>{const n=e._modelValue,r=xs(e),o=e.checked,s=e[An];if(st(n)){const i=bl(n,r),l=i!==-1;if(o&&!l)s(n.concat(r));else if(!o&&l){const c=[...n];c.splice(i,1),s(c)}}else if(Oo(n)){const i=new Set(n);o?i.add(r):i.delete(r),s(i)}else s(T3(e,o))})},mounted:$h,beforeUpdate(e,t,a){e[An]=ao(a),$h(e,t,a)}};function $h(e,{value:t,oldValue:a},n){e._modelValue=t;let r;if(st(t))r=bl(t,n.props.value)>-1;else if(Oo(t))r=t.has(n.props.value);else{if(t===a)return;r=eo(t,T3(e,!0))}e.checked!==r&&(e.checked=r)}const g0={created(e,{value:t},a){e.checked=eo(t,a.props.value),e[An]=ao(a),wr(e,"change",()=>{e[An](xs(e))})},beforeUpdate(e,{value:t,oldValue:a},n){e[An]=ao(n),t!==a&&(e.checked=eo(t,n.props.value))}},y0={deep:!0,created(e,{value:t,modifiers:{number:a}},n){const r=Oo(t);wr(e,"change",()=>{const o=Array.prototype.filter.call(e.options,s=>s.selected).map(s=>a?z1(xs(s)):xs(s));e[An](e.multiple?r?new Set(o):o:o[0]),e._assigning=!0,qa(()=>{e._assigning=!1})}),e[An]=ao(n)},mounted(e,{value:t}){Eh(e,t)},beforeUpdate(e,t,a){e[An]=ao(a)},updated(e,{value:t}){e._assigning||Eh(e,t)}};function Eh(e,t){const a=e.multiple,n=st(t);if(!(a&&!n&&!Oo(t))){for(let r=0,o=e.options.length;r<o;r++){const s=e.options[r],i=xs(s);if(a)if(n){const l=typeof i;l==="string"||l==="number"?s.selected=t.some(c=>String(c)===String(i)):s.selected=bl(t,i)>-1}else s.selected=t.has(i);else if(eo(xs(s),t)){e.selectedIndex!==r&&(e.selectedIndex=r);return}}!a&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function xs(e){return"_value"in e?e._value:e.value}function T3(e,t){const a=t?"_trueValue":"_falseValue";return a in e?e[a]:t}const M0={created(e,t,a){v1(e,t,a,null,"created")},mounted(e,t,a){v1(e,t,a,null,"mounted")},beforeUpdate(e,t,a,n){v1(e,t,a,n,"beforeUpdate")},updated(e,t,a,n){v1(e,t,a,n,"updated")}};function P3(e,t){switch(e){case"SELECT":return y0;case"TEXTAREA":return ws;default:switch(t){case"checkbox":return v0;case"radio":return g0;default:return ws}}}function v1(e,t,a,n,r){const s=P3(e.tagName,a.props&&a.props.type)[r];s&&s(e,t,a,n)}function Gb(){ws.getSSRProps=({value:e})=>({value:e}),g0.getSSRProps=({value:e},t)=>{if(t.props&&eo(t.props.value,e))return{checked:!0}},v0.getSSRProps=({value:e},t)=>{if(st(e)){if(t.props&&bl(e,t.props.value)>-1)return{checked:!0}}else if(Oo(e)){if(t.props&&e.has(t.props.value))return{checked:!0}}else if(e)return{checked:!0}},M0.getSSRProps=(e,t)=>{if(typeof t.type!="string")return;const a=P3(t.type.toUpperCase(),t.props&&t.props.type);if(a.getSSRProps)return a.getSSRProps(e,t)}}const Jb=["ctrl","shift","alt","meta"],Xb={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>Jb.some(a=>e[`${a}Key`]&&!t.includes(a))},sn=(e,t)=>{const a=e._withMods||(e._withMods={}),n=t.join(".");return a[n]||(a[n]=(r,...o)=>{for(let s=0;s<t.length;s++){const i=Xb[t[s]];if(i&&i(r,t))return}return e(r,...o)})},Yb={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},$r=(e,t)=>{const a=e._withKeys||(e._withKeys={}),n=t.join(".");return a[n]||(a[n]=r=>{if(!("key"in r))return;const o=rn(r.key);if(t.some(s=>s===o||Yb[s]===o))return e(r)})},L3=na({patchProp:Ob},Mb);let fi,Ih=!1;function V3(){return fi||(fi=Jv(L3))}function O3(){return fi=Ih?fi:Xv(L3),Ih=!0,fi}const H3=(...e)=>{V3().render(...e)},Qb=(...e)=>{O3().hydrate(...e)},rl=(...e)=>{const t=V3().createApp(...e),{mount:a}=t;return t.mount=n=>{const r=D3(n);if(!r)return;const o=t._component;!gt(o)&&!o.render&&!o.template&&(o.template=r.innerHTML),r.nodeType===1&&(r.textContent="");const s=a(r,!1,N3(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),s},t},R3=(...e)=>{const t=O3().createApp(...e),{mount:a}=t;return t.mount=n=>{const r=D3(n);if(r)return a(r,!0,N3(r))},t};function N3(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function D3(e){return sa(e)?document.querySelector(e):e}let kh=!1;const ew=()=>{kh||(kh=!0,Gb(),Cb())};/**
25
25
  * vue v3.5.13
26
26
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
27
27
  * @license MIT
28
- **/const tw=()=>{},aw=Object.freeze(Object.defineProperty({__proto__:null,BaseTransition:Cv,BaseTransitionPropsValidators:o0,Comment:_a,DeprecationTypes:vb,EffectScope:Jc,ErrorCodes:LM,ErrorTypeStrings:cb,Fragment:Je,KeepAlive:t_,ReactiveEffect:xi,Static:$o,Suspense:z_,Teleport:_v,Text:Xr,TrackOpTypes:SM,Transition:m0,TransitionGroup:Ub,TriggerOpTypes:$M,VueElement:Vl,assertNumber:PM,callWithAsyncErrorHandling:$n,callWithErrorHandling:Is,camelize:Da,capitalize:Hi,cloneVNode:nr,compatUtils:mb,compile:tw,computed:H,createApp:rl,createBlock:Ie,createCommentVNode:ge,createElementBlock:R,createElementVNode:Z,createHydrationRenderer:Xv,createPropsRestProxy:y_,createRenderer:Jv,createSSRApp:R3,createSlots:o_,createStaticVNode:Y_,createTextVNode:pa,createVNode:Ce,customRef:cv,defineAsyncComponent:$v,defineComponent:$e,defineCustomElement:$3,defineEmits:c_,defineExpose:d_,defineModel:p_,defineOptions:u_,defineProps:l_,defineSSRCustomElement:Rb,defineSlots:h_,devtools:db,effect:Y9,effectScope:J9,getCurrentInstance:gn,getCurrentScope:wl,getCurrentWatcher:EM,getTransitionRawChildren:Il,guardReactiveProps:h3,h:En,handleError:Oo,hasInjectionContext:$_,hydrate:Qb,hydrateOnIdle:KM,hydrateOnInteraction:YM,hydrateOnMediaQuery:XM,hydrateOnVisible:JM,initCustomFormatter:sb,initDirectivesForSSR:ew,inject:re,isMemoSame:y3,isProxy:$l,isReactive:Gr,isReadonly:eo,isRef:ba,isRuntimeOnly:nb,isShallow:hn,isVNode:Ar,markRaw:iv,mergeDefaults:g_,mergeModels:Fn,mergeProps:Bi,nextTick:qa,normalizeClass:ft,normalizeProps:W9,normalizeStyle:bt,onActivated:Ev,onBeforeMount:ks,onBeforeUnmount:Ir,onBeforeUpdate:i0,onDeactivated:Iv,onErrorCaptured:Vv,onMounted:ia,onRenderTracked:Lv,onRenderTriggered:Pv,onScopeDispose:Xc,onServerPrefetch:Tv,onUnmounted:Wn,onUpdated:Tl,onWatcherCleanup:uv,openBlock:$,popScopeId:NM,provide:Bv,proxyRefs:t0,pushScopeId:RM,queuePostFlushCb:Si,reactive:Ri,readonly:jt,ref:ye,registerRuntimeCompiler:ab,render:H3,renderList:Ot,renderSlot:qt,resolveComponent:r_,resolveDirective:Hv,resolveDynamicComponent:Ts,resolveFilter:fb,resolveTransitionHooks:ys,setBlockTracking:gc,setDevtoolsHook:ub,setTransitionHooks:Cr,shallowReactive:sv,shallowReadonly:Fr,shallowRef:$t,ssrContextKey:t3,ssrUtils:pb,stop:Q9,toDisplayString:je,toHandlerKey:li,toHandlers:s_,toRaw:St,toRef:mn,toRefs:a0,toValue:Pa,transformVNodeArgs:J_,triggerRef:MM,unref:E,useAttrs:v_,useCssModule:Bb,useCssVars:ji,useHost:E3,useId:Sv,useModel:ir,useSSRContext:a3,useShadowRoot:Db,useSlots:m_,useTemplateRef:pt,useTransitionState:r0,vModelCheckbox:v0,vModelDynamic:M0,vModelRadio:g0,vModelSelect:y0,vModelText:bs,vShow:jn,version:M3,warn:lb,watch:We,watchEffect:O_,watchPostEffect:H_,watchSyncEffect:n3,withAsyncContext:M_,withCtx:Xe,withDefaults:f_,withDirectives:Ya,withKeys:Sr,withMemo:ib,withModifiers:sn,withScopeId:DM},Symbol.toStringTag,{value:"Module"}));/*! @license DOMPurify 3.0.9 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.9/LICENSE */const{entries:B3,setPrototypeOf:Th,isFrozen:nw,getPrototypeOf:rw,getOwnPropertyDescriptor:ow}=Object;let{freeze:Qa,seal:Un,create:F3}=Object,{apply:Sc,construct:$c}=typeof Reflect<"u"&&Reflect;Qa||(Qa=function(t){return t});Un||(Un=function(t){return t});Sc||(Sc=function(t,a,n){return t.apply(a,n)});$c||($c=function(t,a){return new t(...a)});const g1=vn(Array.prototype.forEach),Ph=vn(Array.prototype.pop),Ks=vn(Array.prototype.push),N1=vn(String.prototype.toLowerCase),O2=vn(String.prototype.toString),sw=vn(String.prototype.match),Gs=vn(String.prototype.replace),iw=vn(String.prototype.indexOf),lw=vn(String.prototype.trim),Hn=vn(Object.prototype.hasOwnProperty),dn=vn(RegExp.prototype.test),Js=cw(TypeError);function vn(e){return function(t){for(var a=arguments.length,n=new Array(a>1?a-1:0),r=1;r<a;r++)n[r-1]=arguments[r];return Sc(e,t,n)}}function cw(e){return function(){for(var t=arguments.length,a=new Array(t),n=0;n<t;n++)a[n]=arguments[n];return $c(e,a)}}function Vt(e,t){let a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:N1;Th&&Th(e,null);let n=t.length;for(;n--;){let r=t[n];if(typeof r=="string"){const o=a(r);o!==r&&(nw(t)||(t[n]=o),r=o)}e[r]=!0}return e}function dw(e){for(let t=0;t<e.length;t++)Hn(e,t)||(e[t]=null);return e}function go(e){const t=F3(null);for(const[a,n]of B3(e))Hn(e,a)&&(Array.isArray(n)?t[a]=dw(n):n&&typeof n=="object"&&n.constructor===Object?t[a]=go(n):t[a]=n);return t}function y1(e,t){for(;e!==null;){const n=ow(e,t);if(n){if(n.get)return vn(n.get);if(typeof n.value=="function")return vn(n.value)}e=rw(e)}function a(){return null}return a}const Lh=Qa(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),H2=Qa(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),R2=Qa(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),uw=Qa(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),N2=Qa(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),hw=Qa(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Vh=Qa(["#text"]),Oh=Qa(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),D2=Qa(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Hh=Qa(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),M1=Qa(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),pw=Un(/\{\{[\w\W]*|[\w\W]*\}\}/gm),fw=Un(/<%[\w\W]*|[\w\W]*%>/gm),mw=Un(/\${[\w\W]*}/gm),vw=Un(/^data-[\-\w.\u00B7-\uFFFF]/),gw=Un(/^aria-[\-\w]+$/),j3=Un(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),yw=Un(/^(?:\w+script|data):/i),Mw=Un(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),U3=Un(/^html$/i);var Rh=Object.freeze({__proto__:null,MUSTACHE_EXPR:pw,ERB_EXPR:fw,TMPLIT_EXPR:mw,DATA_ATTR:vw,ARIA_ATTR:gw,IS_ALLOWED_URI:j3,IS_SCRIPT_OR_DATA:yw,ATTR_WHITESPACE:Mw,DOCTYPE_NAME:U3});const _w=function(){return typeof window>"u"?null:window},bw=function(t,a){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const r="data-tt-policy-suffix";a&&a.hasAttribute(r)&&(n=a.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return t.createPolicy(o,{createHTML(s){return s},createScriptURL(s){return s}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}};function z3(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:_w();const t=qe=>z3(qe);if(t.version="3.0.9",t.removed=[],!e||!e.document||e.document.nodeType!==9)return t.isSupported=!1,t;let{document:a}=e;const n=a,r=n.currentScript,{DocumentFragment:o,HTMLTemplateElement:s,Node:i,Element:l,NodeFilter:c,NamedNodeMap:d=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:u,DOMParser:h,trustedTypes:f}=e,m=l.prototype,g=y1(m,"cloneNode"),_=y1(m,"nextSibling"),b=y1(m,"childNodes"),v=y1(m,"parentNode");if(typeof s=="function"){const qe=a.createElement("template");qe.content&&qe.content.ownerDocument&&(a=qe.content.ownerDocument)}let y,M="";const{implementation:x,createNodeIterator:S,createDocumentFragment:L,getElementsByTagName:F}=a,{importNode:te}=n;let J={};t.isSupported=typeof B3=="function"&&typeof v=="function"&&x&&x.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:be,ERB_EXPR:oe,TMPLIT_EXPR:Te,DATA_ATTR:Ue,ARIA_ATTR:Ze,IS_SCRIPT_OR_DATA:Me,ATTR_WHITESPACE:ee}=Rh;let{IS_ALLOWED_URI:j}=Rh,K=null;const G=Vt({},[...Lh,...H2,...R2,...N2,...Vh]);let T=null;const O=Vt({},[...Oh,...D2,...Hh,...M1]);let k=Object.seal(F3(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),C=null,P=null,ae=!0,xe=!0,ve=!1,ze=!0,Ye=!1,ct=!1,wt=!1,D=!1,q=!1,he=!1,me=!1,_e=!0,Ae=!1;const pe="user-content-";let ce=!0,ue=!1,I={},B=null;const N=Vt({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let U=null;const se=Vt({},["audio","video","img","source","image","track"]);let Se=null;const Ne=Vt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),ut="http://www.w3.org/1998/Math/MathML",ie="http://www.w3.org/2000/svg",Ee="http://www.w3.org/1999/xhtml";let Oe=Ee,Pe=!1,Ke=null;const it=Vt({},[ut,ie,Ee],O2);let ht=null;const Ft=["application/xhtml+xml","text/html"],ma="text/html";let Wt=null,ln=null;const Pr=a.createElement("form"),kn=function(Y){return Y instanceof RegExp||Y instanceof Function},lo=function(){let Y=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(ln&&ln===Y)){if((!Y||typeof Y!="object")&&(Y={}),Y=go(Y),ht=Ft.indexOf(Y.PARSER_MEDIA_TYPE)===-1?ma:Y.PARSER_MEDIA_TYPE,Wt=ht==="application/xhtml+xml"?O2:N1,K=Hn(Y,"ALLOWED_TAGS")?Vt({},Y.ALLOWED_TAGS,Wt):G,T=Hn(Y,"ALLOWED_ATTR")?Vt({},Y.ALLOWED_ATTR,Wt):O,Ke=Hn(Y,"ALLOWED_NAMESPACES")?Vt({},Y.ALLOWED_NAMESPACES,O2):it,Se=Hn(Y,"ADD_URI_SAFE_ATTR")?Vt(go(Ne),Y.ADD_URI_SAFE_ATTR,Wt):Ne,U=Hn(Y,"ADD_DATA_URI_TAGS")?Vt(go(se),Y.ADD_DATA_URI_TAGS,Wt):se,B=Hn(Y,"FORBID_CONTENTS")?Vt({},Y.FORBID_CONTENTS,Wt):N,C=Hn(Y,"FORBID_TAGS")?Vt({},Y.FORBID_TAGS,Wt):{},P=Hn(Y,"FORBID_ATTR")?Vt({},Y.FORBID_ATTR,Wt):{},I=Hn(Y,"USE_PROFILES")?Y.USE_PROFILES:!1,ae=Y.ALLOW_ARIA_ATTR!==!1,xe=Y.ALLOW_DATA_ATTR!==!1,ve=Y.ALLOW_UNKNOWN_PROTOCOLS||!1,ze=Y.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Ye=Y.SAFE_FOR_TEMPLATES||!1,ct=Y.WHOLE_DOCUMENT||!1,q=Y.RETURN_DOM||!1,he=Y.RETURN_DOM_FRAGMENT||!1,me=Y.RETURN_TRUSTED_TYPE||!1,D=Y.FORCE_BODY||!1,_e=Y.SANITIZE_DOM!==!1,Ae=Y.SANITIZE_NAMED_PROPS||!1,ce=Y.KEEP_CONTENT!==!1,ue=Y.IN_PLACE||!1,j=Y.ALLOWED_URI_REGEXP||j3,Oe=Y.NAMESPACE||Ee,k=Y.CUSTOM_ELEMENT_HANDLING||{},Y.CUSTOM_ELEMENT_HANDLING&&kn(Y.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(k.tagNameCheck=Y.CUSTOM_ELEMENT_HANDLING.tagNameCheck),Y.CUSTOM_ELEMENT_HANDLING&&kn(Y.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(k.attributeNameCheck=Y.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),Y.CUSTOM_ELEMENT_HANDLING&&typeof Y.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(k.allowCustomizedBuiltInElements=Y.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Ye&&(xe=!1),he&&(q=!0),I&&(K=Vt({},Vh),T=[],I.html===!0&&(Vt(K,Lh),Vt(T,Oh)),I.svg===!0&&(Vt(K,H2),Vt(T,D2),Vt(T,M1)),I.svgFilters===!0&&(Vt(K,R2),Vt(T,D2),Vt(T,M1)),I.mathMl===!0&&(Vt(K,N2),Vt(T,Hh),Vt(T,M1))),Y.ADD_TAGS&&(K===G&&(K=go(K)),Vt(K,Y.ADD_TAGS,Wt)),Y.ADD_ATTR&&(T===O&&(T=go(T)),Vt(T,Y.ADD_ATTR,Wt)),Y.ADD_URI_SAFE_ATTR&&Vt(Se,Y.ADD_URI_SAFE_ATTR,Wt),Y.FORBID_CONTENTS&&(B===N&&(B=go(B)),Vt(B,Y.FORBID_CONTENTS,Wt)),ce&&(K["#text"]=!0),ct&&Vt(K,["html","head","body"]),K.table&&(Vt(K,["tbody"]),delete C.tbody),Y.TRUSTED_TYPES_POLICY){if(typeof Y.TRUSTED_TYPES_POLICY.createHTML!="function")throw Js('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof Y.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Js('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');y=Y.TRUSTED_TYPES_POLICY,M=y.createHTML("")}else y===void 0&&(y=bw(f,r)),y!==null&&typeof M=="string"&&(M=y.createHTML(""));Qa&&Qa(Y),ln=Y}},Ro=Vt({},["mi","mo","mn","ms","mtext"]),No=Vt({},["foreignobject","desc","title","annotation-xml"]),Do=Vt({},["title","style","font","a","script"]),Bo=Vt({},[...H2,...R2,...uw]),Fo=Vt({},[...N2,...hw]),ur=function(Y){let Fe=v(Y);(!Fe||!Fe.tagName)&&(Fe={namespaceURI:Oe,tagName:"template"});const at=N1(Y.tagName),Gt=N1(Fe.tagName);return Ke[Y.namespaceURI]?Y.namespaceURI===ie?Fe.namespaceURI===Ee?at==="svg":Fe.namespaceURI===ut?at==="svg"&&(Gt==="annotation-xml"||Ro[Gt]):!!Bo[at]:Y.namespaceURI===ut?Fe.namespaceURI===Ee?at==="math":Fe.namespaceURI===ie?at==="math"&&No[Gt]:!!Fo[at]:Y.namespaceURI===Ee?Fe.namespaceURI===ie&&!No[Gt]||Fe.namespaceURI===ut&&!Ro[Gt]?!1:!Fo[at]&&(Do[at]||!Bo[at]):!!(ht==="application/xhtml+xml"&&Ke[Y.namespaceURI]):!1},fe=function(Y){Ks(t.removed,{element:Y});try{Y.parentNode.removeChild(Y)}catch{Y.remove()}},Le=function(Y,Fe){try{Ks(t.removed,{attribute:Fe.getAttributeNode(Y),from:Fe})}catch{Ks(t.removed,{attribute:null,from:Fe})}if(Fe.removeAttribute(Y),Y==="is"&&!T[Y])if(q||he)try{fe(Fe)}catch{}else try{Fe.setAttribute(Y,"")}catch{}},Re=function(Y){let Fe=null,at=null;if(D)Y="<remove></remove>"+Y;else{const va=sw(Y,/^[\r\n\t ]+/);at=va&&va[0]}ht==="application/xhtml+xml"&&Oe===Ee&&(Y='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+Y+"</body></html>");const Gt=y?y.createHTML(Y):Y;if(Oe===Ee)try{Fe=new h().parseFromString(Gt,ht)}catch{}if(!Fe||!Fe.documentElement){Fe=x.createDocument(Oe,"template",null);try{Fe.documentElement.innerHTML=Pe?M:Gt}catch{}}const ha=Fe.body||Fe.documentElement;return Y&&at&&ha.insertBefore(a.createTextNode(at),ha.childNodes[0]||null),Oe===Ee?F.call(Fe,ct?"html":"body")[0]:ct?Fe.documentElement:ha},Ve=function(Y){return S.call(Y.ownerDocument||Y,Y,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT,null)},Ge=function(Y){return Y instanceof u&&(typeof Y.nodeName!="string"||typeof Y.textContent!="string"||typeof Y.removeChild!="function"||!(Y.attributes instanceof d)||typeof Y.removeAttribute!="function"||typeof Y.setAttribute!="function"||typeof Y.namespaceURI!="string"||typeof Y.insertBefore!="function"||typeof Y.hasChildNodes!="function")},dt=function(Y){return typeof i=="function"&&Y instanceof i},rt=function(Y,Fe,at){J[Y]&&g1(J[Y],Gt=>{Gt.call(t,Fe,at,ln)})},Mt=function(Y){let Fe=null;if(rt("beforeSanitizeElements",Y,null),Ge(Y))return fe(Y),!0;const at=Wt(Y.nodeName);if(rt("uponSanitizeElement",Y,{tagName:at,allowedTags:K}),Y.hasChildNodes()&&!dt(Y.firstElementChild)&&dn(/<[/\w]/g,Y.innerHTML)&&dn(/<[/\w]/g,Y.textContent))return fe(Y),!0;if(!K[at]||C[at]){if(!C[at]&&Yt(at)&&(k.tagNameCheck instanceof RegExp&&dn(k.tagNameCheck,at)||k.tagNameCheck instanceof Function&&k.tagNameCheck(at)))return!1;if(ce&&!B[at]){const Gt=v(Y)||Y.parentNode,ha=b(Y)||Y.childNodes;if(ha&&Gt){const va=ha.length;for(let ya=va-1;ya>=0;--ya)Gt.insertBefore(g(ha[ya],!0),_(Y))}}return fe(Y),!0}return Y instanceof l&&!ur(Y)||(at==="noscript"||at==="noembed"||at==="noframes")&&dn(/<\/no(script|embed|frames)/i,Y.innerHTML)?(fe(Y),!0):(Ye&&Y.nodeType===3&&(Fe=Y.textContent,g1([be,oe,Te],Gt=>{Fe=Gs(Fe,Gt," ")}),Y.textContent!==Fe&&(Ks(t.removed,{element:Y.cloneNode()}),Y.textContent=Fe)),rt("afterSanitizeElements",Y,null),!1)},At=function(Y,Fe,at){if(_e&&(Fe==="id"||Fe==="name")&&(at in a||at in Pr))return!1;if(!(xe&&!P[Fe]&&dn(Ue,Fe))){if(!(ae&&dn(Ze,Fe))){if(!T[Fe]||P[Fe]){if(!(Yt(Y)&&(k.tagNameCheck instanceof RegExp&&dn(k.tagNameCheck,Y)||k.tagNameCheck instanceof Function&&k.tagNameCheck(Y))&&(k.attributeNameCheck instanceof RegExp&&dn(k.attributeNameCheck,Fe)||k.attributeNameCheck instanceof Function&&k.attributeNameCheck(Fe))||Fe==="is"&&k.allowCustomizedBuiltInElements&&(k.tagNameCheck instanceof RegExp&&dn(k.tagNameCheck,at)||k.tagNameCheck instanceof Function&&k.tagNameCheck(at))))return!1}else if(!Se[Fe]){if(!dn(j,Gs(at,ee,""))){if(!((Fe==="src"||Fe==="xlink:href"||Fe==="href")&&Y!=="script"&&iw(at,"data:")===0&&U[Y])){if(!(ve&&!dn(Me,Gs(at,ee,"")))){if(at)return!1}}}}}}return!0},Yt=function(Y){return Y!=="annotation-xml"&&Y.indexOf("-")>0},la=function(Y){rt("beforeSanitizeAttributes",Y,null);const{attributes:Fe}=Y;if(!Fe)return;const at={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:T};let Gt=Fe.length;for(;Gt--;){const ha=Fe[Gt],{name:va,namespaceURI:ya,value:Kn}=ha,co=Wt(va);let Ba=va==="value"?Kn:lw(Kn);if(at.attrName=co,at.attrValue=Ba,at.keepAttr=!0,at.forceKeepAttr=void 0,rt("uponSanitizeAttribute",Y,at),Ba=at.attrValue,at.forceKeepAttr||(Le(va,Y),!at.keepAttr))continue;if(!ze&&dn(/\/>/i,Ba)){Le(va,Y);continue}Ye&&g1([be,oe,Te],Xi=>{Ba=Gs(Ba,Xi," ")});const Ji=Wt(Y.nodeName);if(At(Ji,co,Ba)){if(Ae&&(co==="id"||co==="name")&&(Le(va,Y),Ba=pe+Ba),y&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!ya)switch(f.getAttributeType(Ji,co)){case"TrustedHTML":{Ba=y.createHTML(Ba);break}case"TrustedScriptURL":{Ba=y.createScriptURL(Ba);break}}try{ya?Y.setAttributeNS(ya,va,Ba):Y.setAttribute(va,Ba),Ph(t.removed)}catch{}}}rt("afterSanitizeAttributes",Y,null)},ca=function qe(Y){let Fe=null;const at=Ve(Y);for(rt("beforeSanitizeShadowDOM",Y,null);Fe=at.nextNode();)rt("uponSanitizeShadowNode",Fe,null),!Mt(Fe)&&(Fe.content instanceof o&&qe(Fe.content),la(Fe));rt("afterSanitizeShadowDOM",Y,null)};return t.sanitize=function(qe){let Y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Fe=null,at=null,Gt=null,ha=null;if(Pe=!qe,Pe&&(qe="<!-->"),typeof qe!="string"&&!dt(qe))if(typeof qe.toString=="function"){if(qe=qe.toString(),typeof qe!="string")throw Js("dirty is not a string, aborting")}else throw Js("toString is not a function");if(!t.isSupported)return qe;if(wt||lo(Y),t.removed=[],typeof qe=="string"&&(ue=!1),ue){if(qe.nodeName){const Kn=Wt(qe.nodeName);if(!K[Kn]||C[Kn])throw Js("root node is forbidden and cannot be sanitized in-place")}}else if(qe instanceof i)Fe=Re("<!---->"),at=Fe.ownerDocument.importNode(qe,!0),at.nodeType===1&&at.nodeName==="BODY"||at.nodeName==="HTML"?Fe=at:Fe.appendChild(at);else{if(!q&&!Ye&&!ct&&qe.indexOf("<")===-1)return y&&me?y.createHTML(qe):qe;if(Fe=Re(qe),!Fe)return q?null:me?M:""}Fe&&D&&fe(Fe.firstChild);const va=Ve(ue?qe:Fe);for(;Gt=va.nextNode();)Mt(Gt)||(Gt.content instanceof o&&ca(Gt.content),la(Gt));if(ue)return qe;if(q){if(he)for(ha=L.call(Fe.ownerDocument);Fe.firstChild;)ha.appendChild(Fe.firstChild);else ha=Fe;return(T.shadowroot||T.shadowrootmode)&&(ha=te.call(n,ha,!0)),ha}let ya=ct?Fe.outerHTML:Fe.innerHTML;return ct&&K["!doctype"]&&Fe.ownerDocument&&Fe.ownerDocument.doctype&&Fe.ownerDocument.doctype.name&&dn(U3,Fe.ownerDocument.doctype.name)&&(ya="<!DOCTYPE "+Fe.ownerDocument.doctype.name+`>
29
- `+ya),Ye&&g1([be,oe,Te],Kn=>{ya=Gs(ya,Kn," ")}),y&&me?y.createHTML(ya):ya},t.setConfig=function(){let qe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};lo(qe),wt=!0},t.clearConfig=function(){ln=null,wt=!1},t.isValidAttribute=function(qe,Y,Fe){ln||lo({});const at=Wt(qe),Gt=Wt(Y);return At(at,Gt,Fe)},t.addHook=function(qe,Y){typeof Y=="function"&&(J[qe]=J[qe]||[],Ks(J[qe],Y))},t.removeHook=function(qe){if(J[qe])return Ph(J[qe])},t.removeHooks=function(qe){J[qe]&&(J[qe]=[])},t.removeAllHooks=function(){J={}},t}var ww=z3();function xw(e,t){const a=e.hooks??{};let n;for(n in a){const r=a[n];r!==void 0&&t.addHook(n,r)}}function q3(){return ww()}function Cw(e={},t=q3){const a=t();xw(e,a);const n=function(r,o){const s=o.value;if(o.oldValue===s)return;const i=`${s}`,l=o.arg,c=e.namedConfigurations,d=e.default??{};if(c&&l!==void 0){r.innerHTML=a.sanitize(i,c[l]??d);return}r.innerHTML=a.sanitize(i,d)};return{mounted:n,updated:n}}const Aw={install(e,t={},a=q3){e.directive("dompurify-html",Cw(t,a))}};function Sw(e,t){return $w(window.sessionStorage,e,t)}function $w(e,t,a){const n=$t(r());function r(){if(!e)return;const o=e.getItem(t);if(o)try{const s=JSON.parse(o);if((a==null?void 0:a(s))===!1){e.removeItem(t);return}return s}catch{e.removeItem(t);return}}return H({get(){return n.value},set(o){n.value=o,e&&(o===void 0?e.removeItem(t):e.setItem(t,JSON.stringify(o)))}})}function fa(){return{log:console.log,warn:console.warn,info:console.info,error:console.error}}const Ew=1500,Iw=1e3,kw=100,Tw=fa();var Pw=(e=>(e[e.None=0]="None",e[e.Single=1]="Single",e[e.Multiple=2]="Multiple",e))(Pw||{});const Lw=new Set(["ui","blueprints","preview","vault","journal"]);function Vw(e){return typeof e=="string"&&Lw.has(e)}function Ow(){const e=Sw("generateBuilderManager__mode",Vw),t={mode:e.value??"preview",selection:[],mutationTransactionsSnapshot:{undo:null,redo:null},logEntries:[]},a=ye(t);let n=null,r=0;const o=[],s=j=>{l.value=j},i=()=>a.value.mode,l=H({get:()=>a.value.mode,set(j){a.value.mode=j,e.value=j}}),c=H(()=>l.value=="blueprints"?"blueprints_root":"root"),d=(j,K,G)=>{if(j===null){a.value.selection=[];return}a.value.selection.length!==0&&(a.value.selection=[]),u(j,K,G)},u=(j,K,G)=>{let T=K;if(typeof T>"u"){const O=document.querySelector(`.ComponentRenderer [data-writer-id="${j}"]`);T=O==null?void 0:O.dataset.writerInstancePath}a.value.selection=[...a.value.selection,{componentId:j,instancePath:T,source:G}]},h=(j,K,G,T)=>{if(!j.shiftKey&&!j.ctrlKey&&!j.metaKey)return d(K,G,T);f(K)?m(K):u(K,G,T)},f=j=>a.value.selection.some(K=>K.componentId===j),m=j=>{const K=a.value.selection.filter(G=>G.componentId!==j);K.length!==a.value.selection.length&&(a.value.selection=K)},g=H(()=>a.value.selection.length===0?0:a.value.selection.length===1?1:2),_=H(()=>g.value===1),b=H(()=>a.value.selection[0]),v=H(()=>{var j;return(j=a.value.selection[0])==null?void 0:j.componentId}),y=(j,K,G=!1)=>{if(n!==null)return;r<0&&(o.splice(r),r=0);const T=o[o.length-1],O=Date.now()-(T==null?void 0:T.timestamp);if(T!=null&&T.enableDebounce&&(T==null?void 0:T.id)==j&&O<Iw){n=o.pop();return}n={id:j,desc:K,timestamp:null,enableDebounce:G,mutations:{}}},M=j=>{n.mutations[j.id]||(n.mutations[j.id]={jsonPre:j?JSON.stringify(j):void 0})},x=j=>{n.mutations[j.id]||(n.mutations[j.id]={}),n.mutations[j.id].jsonPost=j?JSON.stringify(j):void 0},S=j=>{if(n.id!==j){Tw.warn("Mutation transaction mismatch.",j,n.id);return}n.timestamp=Date.now(),o.push(n),n=null,te()},L=()=>{const j=o.length-1+r,K=o[j];return K&&r--,te(),K},F=()=>{const j=o.length+r,K=o[j];return K&&r++,te(),K},te=()=>{const j=o.length-1+r,K=o[j],G=o.length+r,T=o[G];a.value.mutationTransactionsSnapshot={undo:K,redo:T}},J=()=>a.value.mutationTransactionsSnapshot;async function be(j){const K=JSON.stringify(j);let G=5981;for(let O=0;O<K.length;O++)G=(G<<5)+G+K.charCodeAt(O);return G.toString(16).padStart(2,"0")}const oe=async j=>{const{type:K,title:G,message:T,code:O,blueprintExecution:k,id:C}=j,P=await be(j);if(C){const ae=a.value.logEntries.findIndex(xe=>xe.id===C);ae!==-1&&a.value.logEntries.splice(ae,1)}else{const ae=a.value.logEntries.find(xe=>xe.fingerprint===P);if(ae){ae.repeated++,ae.timestampReceived=new Date,a.value.logEntries.sort((xe,ve)=>xe.timestampReceived<ve.timestampReceived?1:-1);return}}a.value.logEntries.unshift({id:C,type:K,title:G,message:T,code:O,blueprintExecution:k,timestampReceived:new Date,fingerprint:P,repeated:0}),a.value.logEntries.splice(kw)},Te=()=>a.value.logEntries.length,Ue=()=>{a.value.logEntries=[]},Ze=()=>a.value.logEntries,Me=H(()=>{var T,O,k;const j=Ze(),K=(O=(T=j.find(C=>!!C.blueprintExecution))==null?void 0:T.blueprintExecution)==null?void 0:O.runId;return K&&!!((k=j.filter(C=>{var P,ae;return((P=C==null?void 0:C.blueprintExecution)==null?void 0:P.runId)===K&&!((ae=C==null?void 0:C.blueprintExecution)!=null&&ae.exit)}))!=null&&k[0])?K:null});return{setMode:s,getMode:i,mode:l,activeRootId:c,openPanels:ye(new Set),isSettingsBarCollapsed:ye(!1),isComponentIdSelected:f,selectionStatus:g,isSingleSelectionActive:_,firstSelectedId:v,firstSelectedItem:b,removeSelectedComponentId:m,setSelection:d,appendSelection:u,handleSelectionFromEvent:h,selection:H(()=>a.value.selection),mutationTransactions:jt(o),openMutationTransaction:y,registerPreMutation:M,registerPostMutation:x,closeMutationTransaction:S,consumeUndoTransaction:L,consumeRedoTransaction:F,getMutationTransactionsSnapshot:J,handleLogEntry:oe,getLogEntryCount:Te,clearLogEntries:Ue,getLogEntries:Ze,activeBlueprintRunId:Me}}const ne={core:Symbol(),builderManager:Symbol(),notesManager:Symbol(),collaborationManager:Symbol(),secretsManager:Symbol(),evaluatedFields:Symbol(),componentId:Symbol(),isBeingEdited:Symbol(),isDisabled:Symbol(),getChildrenVNodes:Symbol(),renderProxiedComponent:Symbol(),instancePath:Symbol(),flattenedInstancePath:Symbol(),instanceData:Symbol(),isAutogenModalShown:Symbol(),socketTimeout:Symbol()};function W3(e){var a;const t=(a=e.split(","))==null?void 0:a[1];if(!t)throw Error(`Could not extract base64 from data url: ${e}`);return t}function Hw(e){const t=window.atob(e),a=t.length,n=new Uint8Array(a);for(let r=0;r<a;r++)n[r]=t.charCodeAt(r);return n.buffer}function Rw(e){const t=W3(e),a=atob(t),n=new ArrayBuffer(a.length),r=new Uint8Array(n);for(let o=0;o<a.length;o++)r[o]=a.charCodeAt(o);return n}var Q=(e=>(e.Text="Text",e.Binding="Binding",e.Boolean="Boolean",e.KeyValue="Key-Value",e.Color="Color",e.Shadow="Shadow",e.Number="Number",e.Object="Object",e.JSONInput="JSON",e.IdKey="Identifying Key",e.Width="Width",e.HAlign="Align (H)",e.VAlign="Align (V)",e.Padding="Padding",e.Tools="Tools",e.ComponentPicker="Component",e.Code="Code",e.Eval="Eval",e.BlueprintKey="Blueprint Key",e.BlueprintId="Blueprint Id",e.Handler="Handler",e.WriterGraphId="Graph Id",e.WriterGraphIds="Graph Ids",e.WriterAppId="App Id",e.WriterModelId="Model Id",e.ComponentId="Component Id",e.ComponentEventType="Component Event Type",e))(Q||{}),ot=(e=>(e.General="General",e.Style="Style",e.Tools="Tools",e))(ot||{}),Ui=(e=>(e.Text="Text",e.Textarea="Textarea",e))(Ui||{});const Nw={class:"WdsNumberInput__right"},Dw=$e({inheritAttrs:!1,__name:"WdsNumberInput",props:Fn({step:{type:Number,default:1},class:{type:String,default:void 0}},{modelValue:{type:Number,required:!1,default:void 0},modelModifiers:{}}),emits:Fn({focusout:e=>typeof e=="number"},["update:modelValue"]),setup(e,{expose:t}){const a=ir(e,"modelValue"),n=e;t({focus:s});const r=ye();function o(i){a.value=(a.value??0)+i,s()}function s(){var i;(i=r.value)==null||i.focus()}return(i,l)=>($(),R("div",{class:ft(["WdsNumberInput colorTransformer",n.class])},[Ya(Z("input",Bi({ref_key:"input",ref:r,"onUpdate:modelValue":l[0]||(l[0]=c=>a.value=c),class:"WdsNumberInput__input"},i.$attrs,{type:"number",onFocusout:l[1]||(l[1]=c=>i.$emit("focusout",a.value))}),null,16),[[bs,a.value]]),Z("div",Nw,[Z("button",{class:"WdsNumberInput__right__arrow",type:"button",onClick:l[2]||(l[2]=sn(c=>o(e.step),["prevent"])),onPointerdown:l[3]||(l[3]=sn(()=>{},["prevent"]))},l[6]||(l[6]=[Z("span",{class:"WdsNumberInput__right__arrow__up"},null,-1)]),32),Z("button",{class:"WdsNumberInput__right__arrow",type:"button",onClick:l[4]||(l[4]=sn(c=>o(-e.step),["prevent"])),onPointerdown:l[5]||(l[5]=sn(()=>{},["prevent"]))},l[7]||(l[7]=[Z("span",{class:"WdsNumberInput__right__arrow__down"},null,-1)]),32)])],2))}}),ke=(e,t)=>{const a=e.__vccOpts||e;for(const[n,r]of t)a[n]=r;return a},Bw=ke(Dw,[["__scopeId","data-v-e225ba84"]]),Fw={key:0},jw={key:1,class:"CoreDataframeCellNumber--text"},Uw=$e({__name:"CoreDataframeCellNumber",props:{value:{validator:e=>typeof e=="number"||typeof e=="bigint",required:!0},editable:{type:Boolean,required:!1}},emits:{change:e=>typeof e=="number"},setup(e,{emit:t}){const a=e,n=t;function r(o){o!==a.value&&n("change",o)}return(o,s)=>e.editable?($(),R("div",Fw,[Ce(Bw,{class:"CoreDataframeCellNumber--input","model-value":Number(e.value),onFocusout:s[0]||(s[0]=i=>r(i))},null,8,["model-value"])])):($(),R("div",jw,je(e.value),1))}}),zw=ke(Uw,[["__scopeId","data-v-0707fd0c"]]),qw={class:"markdown"},Ww=$e({__name:"BaseMarkdownRaw",props:{rawMarkdown:{type:String,required:!0}},setup(e){return(t,a)=>{const n=Hv("dompurify-html");return Ya(($(),R("div",qw,null,512)),[[n,e.rawMarkdown]])}}}),Z3=ke(Ww,[["__scopeId","data-v-2220bc7a"]]),K3=$e({__name:"BaseMarkdown",props:{rawText:{}},setup(e){let t;const a=ye(!1),n=e;return ks(async()=>{t=await zt(()=>import("./marked.esm-273vDTCT.js"),[],import.meta.url),a.value=!0}),(r,o)=>a.value?($(),Ie(Z3,{key:0,"raw-markdown":String(E(t).parse(n.rawText)).trim(),class:"BaseMarkdown"},null,8,["raw-markdown"])):ge("",!0)}}),Zw=["aria-invalid","autofocus"],Kw=$e({__name:"WdsTextareaInput",props:Fn({invalid:{type:Boolean,required:!1},autofocus:{type:Boolean}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(e,{expose:t}){const a=ir(e,"modelValue"),n=e,r=pt("input");t({focus:l,getSelection:i,value:a,ref:r,setSelectionEnd:s,setSelectionStart:o}),ia(()=>{n.autofocus&&l()});function o(c){r.value&&(r.value.selectionStart=c)}function s(c){r.value&&(r.value.selectionEnd=c)}function i(){var c,d;return{selectionStart:(c=r.value)==null?void 0:c.selectionStart,selectionEnd:(d=r.value)==null?void 0:d.selectionEnd}}function l(){var c;(c=r.value)==null||c.focus()}return(c,d)=>Ya(($(),R("textarea",{ref_key:"input",ref:r,"onUpdate:modelValue":d[0]||(d[0]=u=>a.value=u),"aria-invalid":e.invalid,autofocus:e.autofocus},null,8,Zw)),[[bs,a.value]])}}),_0=ke(Kw,[["__scopeId","data-v-2d90ab73"]]),Gw={key:2,class:"CoreDataframeCellText--text"},Jw=$e({__name:"CoreDataframeCellText",props:{value:{validator:()=>!0,required:!0},useMarkdown:{type:Boolean,required:!1},editable:{type:Boolean,required:!1},wrapText:{type:Boolean,required:!1}},emits:{change:e=>typeof e=="string"},setup(e,{emit:t}){const a=e,n=t,r=pt("textarea");function o(){r.value.value!==a.value&&n("change",r.value.value)}function s(){var h;if(!((h=r.value)!=null&&h.ref))return;const i=r.value.ref,l=getComputedStyle(i);if(!l)return;const c=parseInt(l.borderTopWidth)||0,d=parseInt(l.borderBottomWidth)||0,u=c+d;i.style.height=`${i.scrollHeight+u}px`}return We(()=>a.editable&&a.value,i=>{a.wrapText&&i&&qa(()=>s())},{immediate:!0}),(i,l)=>e.editable?($(),Ie(_0,{key:0,ref_key:"textarea",ref:r,class:"CoreDataframeCellText--textarea",rows:"1","model-value":String(e.value),onFocusout:o},null,8,["model-value"])):e.useMarkdown?($(),Ie(K3,{key:1,"raw-text":String(e.value)},null,8,["raw-text"])):($(),R("div",Gw,[Z("p",{class:ft({"CoreDataframeCellText__content--noWrap":!e.wrapText})},je(e.value),3)]))}}),Xw=ke(Jw,[["__scopeId","data-v-a47ac113"]]),Yw=["checked","readonly","tabindex"],Qw=$e({__name:"CoreDataframeCellBoolean",props:{value:{type:Boolean,required:!0},editable:{type:Boolean,required:!1}},emits:{change:e=>typeof e=="boolean"},setup(e,{emit:t}){const a=e,n=t;function r(o){if(!a.editable){o.preventDefault(),o.stopPropagation();return}n("change",o.target.checked)}return(o,s)=>($(),R("div",{class:ft(["CoreDataframeCellBoolean",{"CoreDataframeCellBoolean--disabled":!e.editable}])},[Z("input",{type:"checkbox",checked:e.value,readonly:!e.editable,tabindex:e.editable?0:-1,onChange:r},null,40,Yw)],2))}}),ex=ke(Qw,[["__scopeId","data-v-2d30bc74"]]);function G3(e,t){return typeof t=="bigint"?t.toString()+"n":t}const tx={class:"CoreDataframeCellUnknown"},ax=$e({__name:"CoreDataframeCellUnknown",props:{value:{validator:()=>!0,required:!0},wrapText:{type:Boolean,required:!1}},setup(e){const t=e,a=H(()=>JSON.stringify(t.value,G3));return(n,r)=>($(),R("div",tx,[Z("p",{class:ft({"CoreDataframeCellUnknown__content--noWrap":!e.wrapText})},je(a.value),3)]))}}),nx=ke(ax,[["__scopeId","data-v-06d2511b"]]),rx=$e({__name:"CoreDataframeCell",props:{value:{validator:()=>!0,required:!0},useMarkdown:{type:Boolean,required:!1},editable:{type:Boolean,required:!1},wrapText:{type:Boolean,required:!1}},emits:{change:e=>e!==void 0},setup(e){const t=e,a=H(()=>{switch(typeof t.value){case"number":case"bigint":return zw;case"boolean":return ex;case"string":return Xw;default:return nx}});return(n,r)=>($(),Ie(Ts(a.value),{value:e.value,"use-markdown":e.useMarkdown,editable:e.editable,"wrap-text":e.wrapText,onChange:r[0]||(r[0]=o=>n.$emit("change",o))},null,40,["value","use-markdown","editable","wrap-text"]))}}),xn="__internal_arquero_id",ox="data:application/vnd.apache.arrow.file;base64,QVJST1cxAAD/////iAMAABAAAAAAAAoADgAGAAUACAAKAAAAAAEEABAAAAAAAAoADAAAAAQACAAKAAAAlAIAAAQAAAABAAAADAAAAAgADAAEAAgACAAAAGwCAAAEAAAAXwIAAHsiaW5kZXhfY29sdW1ucyI6IFsiX19pbmRleF9sZXZlbF8wX18iXSwgImNvbHVtbl9pbmRleGVzIjogW3sibmFtZSI6IG51bGwsICJmaWVsZF9uYW1lIjogbnVsbCwgInBhbmRhc190eXBlIjogInVuaWNvZGUiLCAibnVtcHlfdHlwZSI6ICJvYmplY3QiLCAibWV0YWRhdGEiOiB7ImVuY29kaW5nIjogIlVURi04In19XSwgImNvbHVtbnMiOiBbeyJuYW1lIjogImNvbF9hIiwgImZpZWxkX25hbWUiOiAiY29sX2EiLCAicGFuZGFzX3R5cGUiOiAiaW50NjQiLCAibnVtcHlfdHlwZSI6ICJpbnQ2NCIsICJtZXRhZGF0YSI6IG51bGx9LCB7Im5hbWUiOiAiY29sX2IiLCAiZmllbGRfbmFtZSI6ICJjb2xfYiIsICJwYW5kYXNfdHlwZSI6ICJpbnQ2NCIsICJudW1weV90eXBlIjogImludDY0IiwgIm1ldGFkYXRhIjogbnVsbH0sIHsibmFtZSI6IG51bGwsICJmaWVsZF9uYW1lIjogIl9faW5kZXhfbGV2ZWxfMF9fIiwgInBhbmRhc190eXBlIjogImludDY0IiwgIm51bXB5X3R5cGUiOiAiaW50NjQiLCAibWV0YWRhdGEiOiBudWxsfV0sICJjcmVhdG9yIjogeyJsaWJyYXJ5IjogInB5YXJyb3ciLCAidmVyc2lvbiI6ICIxMi4wLjAifSwgInBhbmRhc192ZXJzaW9uIjogIjEuNS4zIn0ABgAAAHBhbmRhcwAAAwAAAIgAAABEAAAABAAAAJT///8AAAECEAAAACQAAAAEAAAAAAAAABEAAABfX2luZGV4X2xldmVsXzBfXwAAAJD///8AAAABQAAAAND///8AAAECEAAAABgAAAAEAAAAAAAAAAUAAABjb2xfYgAAAMD///8AAAABQAAAABAAFAAIAAYABwAMAAAAEAAQAAAAAAABAhAAAAAgAAAABAAAAAAAAAAFAAAAY29sX2EAAAAIAAwACAAHAAgAAAAAAAABQAAAAAAAAAD/////6AAAABQAAAAAAAAADAAWAAYABQAIAAwADAAAAAADBAAYAAAAMAAAAAAAAAAAAAoAGAAMAAQACAAKAAAAfAAAABAAAAACAAAAAAAAAAAAAAAGAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAACAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAABAAAAAAAAAAAAAAAAMAAAACAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAIAAAAAAAAAAwAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAD/////AAAAABAAAAAMABQABgAIAAwAEAAMAAAAAAAEADwAAAAoAAAABAAAAAEAAACYAwAAAAAAAPAAAAAAAAAAMAAAAAAAAAAAAAAAAAAAAAAACgAMAAAABAAIAAoAAACUAgAABAAAAAEAAAAMAAAACAAMAAQACAAIAAAAbAIAAAQAAABfAgAAeyJpbmRleF9jb2x1bW5zIjogWyJfX2luZGV4X2xldmVsXzBfXyJdLCAiY29sdW1uX2luZGV4ZXMiOiBbeyJuYW1lIjogbnVsbCwgImZpZWxkX25hbWUiOiBudWxsLCAicGFuZGFzX3R5cGUiOiAidW5pY29kZSIsICJudW1weV90eXBlIjogIm9iamVjdCIsICJtZXRhZGF0YSI6IHsiZW5jb2RpbmciOiAiVVRGLTgifX1dLCAiY29sdW1ucyI6IFt7Im5hbWUiOiAiY29sX2EiLCAiZmllbGRfbmFtZSI6ICJjb2xfYSIsICJwYW5kYXNfdHlwZSI6ICJpbnQ2NCIsICJudW1weV90eXBlIjogImludDY0IiwgIm1ldGFkYXRhIjogbnVsbH0sIHsibmFtZSI6ICJjb2xfYiIsICJmaWVsZF9uYW1lIjogImNvbF9iIiwgInBhbmRhc190eXBlIjogImludDY0IiwgIm51bXB5X3R5cGUiOiAiaW50NjQiLCAibWV0YWRhdGEiOiBudWxsfSwgeyJuYW1lIjogbnVsbCwgImZpZWxkX25hbWUiOiAiX19pbmRleF9sZXZlbF8wX18iLCAicGFuZGFzX3R5cGUiOiAiaW50NjQiLCAibnVtcHlfdHlwZSI6ICJpbnQ2NCIsICJtZXRhZGF0YSI6IG51bGx9XSwgImNyZWF0b3IiOiB7ImxpYnJhcnkiOiAicHlhcnJvdyIsICJ2ZXJzaW9uIjogIjEyLjAuMCJ9LCAicGFuZGFzX3ZlcnNpb24iOiAiMS41LjMifQAGAAAAcGFuZGFzAAADAAAAiAAAAEQAAAAEAAAAlP///wAAAQIQAAAAJAAAAAQAAAAAAAAAEQAAAF9faW5kZXhfbGV2ZWxfMF9fAAAAkP///wAAAAFAAAAA0P///wAAAQIQAAAAGAAAAAQAAAAAAAAABQAAAGNvbF9iAAAAwP///wAAAAFAAAAAEAAUAAgABgAHAAwAAAAQABAAAAAAAAECEAAAACAAAAAEAAAAAAAAAAUAAABjb2xfYQAAAAgADAAIAAcACAAAAAAAAAFAAAAAsAMAAEFSUk9XMQ==",J3=/^__index_level_[0-9]+__$/;function b0(e){const t=ye(!1),a=new AbortController;function n(){t.value=!0}function r(o){const s=o.currentTarget;document.hasFocus()?s.contains(o.relatedTarget)||(t.value=!1):window.addEventListener("focus",function i(){window.removeEventListener("focus",i),s.isConnected&&!s.contains(document.activeElement)&&(t.value=!1)},{signal:a.signal})}return We(e,(o,s)=>{s&&(s.removeEventListener("focusin",n),s.removeEventListener("focusout",r)),e!=null&&e.value&&(e.value.addEventListener("focusin",n,{signal:a.signal}),e.value.addEventListener("focusout",r,{signal:a.signal}))}),Ir(()=>{a.abort()}),jt(t)}const sx=["top","right","bottom","left"],Nh=["start","end"],Dh=sx.reduce((e,t)=>e.concat(t,t+"-"+Nh[0],t+"-"+Nh[1]),[]),xs=Math.min,un=Math.max,ol=Math.round,_1=Math.floor,tr=e=>({x:e,y:e}),ix={left:"right",right:"left",bottom:"top",top:"bottom"},lx={start:"end",end:"start"};function Bh(e,t,a){return un(e,xs(t,a))}function Ps(e,t){return typeof e=="function"?e(t):e}function rr(e){return e.split("-")[0]}function ar(e){return e.split("-")[1]}function X3(e){return e==="x"?"y":"x"}function Y3(e){return e==="y"?"height":"width"}function ko(e){return["top","bottom"].includes(rr(e))?"y":"x"}function Q3(e){return X3(ko(e))}function e6(e,t,a){a===void 0&&(a=!1);const n=ar(e),r=Q3(e),o=Y3(r);let s=r==="x"?n===(a?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=il(s)),[s,il(s)]}function cx(e){const t=il(e);return[sl(e),t,sl(t)]}function sl(e){return e.replace(/start|end/g,t=>lx[t])}function dx(e,t,a){const n=["left","right"],r=["right","left"],o=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return a?t?r:n:t?n:r;case"left":case"right":return t?o:s;default:return[]}}function ux(e,t,a,n){const r=ar(e);let o=dx(rr(e),a==="start",n);return r&&(o=o.map(s=>s+"-"+r),t&&(o=o.concat(o.map(sl)))),o}function il(e){return e.replace(/left|right|bottom|top/g,t=>ix[t])}function hx(e){return{top:0,right:0,bottom:0,left:0,...e}}function px(e){return typeof e!="number"?hx(e):{top:e,right:e,bottom:e,left:e}}function ll(e){const{x:t,y:a,width:n,height:r}=e;return{width:n,height:r,top:a,left:t,right:t+n,bottom:a+r,x:t,y:a}}function Fh(e,t,a){let{reference:n,floating:r}=e;const o=ko(t),s=Q3(t),i=Y3(s),l=rr(t),c=o==="y",d=n.x+n.width/2-r.width/2,u=n.y+n.height/2-r.height/2,h=n[i]/2-r[i]/2;let f;switch(l){case"top":f={x:d,y:n.y-r.height};break;case"bottom":f={x:d,y:n.y+n.height};break;case"right":f={x:n.x+n.width,y:u};break;case"left":f={x:n.x-r.width,y:u};break;default:f={x:n.x,y:n.y}}switch(ar(t)){case"start":f[s]-=h*(a&&c?-1:1);break;case"end":f[s]+=h*(a&&c?-1:1);break}return f}const fx=async(e,t,a)=>{const{placement:n="bottom",strategy:r="absolute",middleware:o=[],platform:s}=a,i=o.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t));let c=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:d,y:u}=Fh(c,n,l),h=n,f={},m=0;for(let g=0;g<i.length;g++){const{name:_,fn:b}=i[g],{x:v,y,data:M,reset:x}=await b({x:d,y:u,initialPlacement:n,placement:h,strategy:r,middlewareData:f,rects:c,platform:s,elements:{reference:e,floating:t}});d=v??d,u=y??u,f={...f,[_]:{...f[_],...M}},x&&m<=50&&(m++,typeof x=="object"&&(x.placement&&(h=x.placement),x.rects&&(c=x.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:r}):x.rects),{x:d,y:u}=Fh(c,h,l)),g=-1)}return{x:d,y:u,placement:h,strategy:r,middlewareData:f}};async function Ol(e,t){var a;t===void 0&&(t={});const{x:n,y:r,platform:o,rects:s,elements:i,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:h=!1,padding:f=0}=Ps(t,e),m=px(f),_=i[h?u==="floating"?"reference":"floating":u],b=ll(await o.getClippingRect({element:(a=await(o.isElement==null?void 0:o.isElement(_)))==null||a?_:_.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(i.floating)),boundary:c,rootBoundary:d,strategy:l})),v=u==="floating"?{x:n,y:r,width:s.floating.width,height:s.floating.height}:s.reference,y=await(o.getOffsetParent==null?void 0:o.getOffsetParent(i.floating)),M=await(o.isElement==null?void 0:o.isElement(y))?await(o.getScale==null?void 0:o.getScale(y))||{x:1,y:1}:{x:1,y:1},x=ll(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:v,offsetParent:y,strategy:l}):v);return{top:(b.top-x.top+m.top)/M.y,bottom:(x.bottom-b.bottom+m.bottom)/M.y,left:(b.left-x.left+m.left)/M.x,right:(x.right-b.right+m.right)/M.x}}function mx(e,t,a){return(e?[...a.filter(r=>ar(r)===e),...a.filter(r=>ar(r)!==e)]:a.filter(r=>rr(r)===r)).filter(r=>e?ar(r)===e||(t?sl(r)!==r:!1):!0)}const vx=function(e){return e===void 0&&(e={}),{name:"autoPlacement",options:e,async fn(t){var a,n,r;const{rects:o,middlewareData:s,placement:i,platform:l,elements:c}=t,{crossAxis:d=!1,alignment:u,allowedPlacements:h=Dh,autoAlignment:f=!0,...m}=Ps(e,t),g=u!==void 0||h===Dh?mx(u||null,f,h):h,_=await Ol(t,m),b=((a=s.autoPlacement)==null?void 0:a.index)||0,v=g[b];if(v==null)return{};const y=e6(v,o,await(l.isRTL==null?void 0:l.isRTL(c.floating)));if(i!==v)return{reset:{placement:g[0]}};const M=[_[rr(v)],_[y[0]],_[y[1]]],x=[...((n=s.autoPlacement)==null?void 0:n.overflows)||[],{placement:v,overflows:M}],S=g[b+1];if(S)return{data:{index:b+1,overflows:x},reset:{placement:S}};const L=x.map(J=>{const be=ar(J.placement);return[J.placement,be&&d?J.overflows.slice(0,2).reduce((oe,Te)=>oe+Te,0):J.overflows[0],J.overflows]}).sort((J,be)=>J[1]-be[1]),te=((r=L.filter(J=>J[2].slice(0,ar(J[0])?2:3).every(be=>be<=0))[0])==null?void 0:r[0])||L[0][0];return te!==i?{data:{index:b+1,overflows:x},reset:{placement:te}}:{}}}},gx=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var a,n;const{placement:r,middlewareData:o,rects:s,initialPlacement:i,platform:l,elements:c}=t,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:h,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:g=!0,..._}=Ps(e,t);if((a=o.arrow)!=null&&a.alignmentOffset)return{};const b=rr(r),v=ko(i),y=rr(i)===i,M=await(l.isRTL==null?void 0:l.isRTL(c.floating)),x=h||(y||!g?[il(i)]:cx(i)),S=m!=="none";!h&&S&&x.push(...ux(i,g,m,M));const L=[i,...x],F=await Ol(t,_),te=[];let J=((n=o.flip)==null?void 0:n.overflows)||[];if(d&&te.push(F[b]),u){const Ue=e6(r,s,M);te.push(F[Ue[0]],F[Ue[1]])}if(J=[...J,{placement:r,overflows:te}],!te.every(Ue=>Ue<=0)){var be,oe;const Ue=(((be=o.flip)==null?void 0:be.index)||0)+1,Ze=L[Ue];if(Ze)return{data:{index:Ue,overflows:J},reset:{placement:Ze}};let Me=(oe=J.filter(ee=>ee.overflows[0]<=0).sort((ee,j)=>ee.overflows[1]-j.overflows[1])[0])==null?void 0:oe.placement;if(!Me)switch(f){case"bestFit":{var Te;const ee=(Te=J.filter(j=>{if(S){const K=ko(j.placement);return K===v||K==="y"}return!0}).map(j=>[j.placement,j.overflows.filter(K=>K>0).reduce((K,G)=>K+G,0)]).sort((j,K)=>j[1]-K[1])[0])==null?void 0:Te[0];ee&&(Me=ee);break}case"initialPlacement":Me=i;break}if(r!==Me)return{reset:{placement:Me}}}return{}}}};async function yx(e,t){const{placement:a,platform:n,elements:r}=e,o=await(n.isRTL==null?void 0:n.isRTL(r.floating)),s=rr(a),i=ar(a),l=ko(a)==="y",c=["left","top"].includes(s)?-1:1,d=o&&l?-1:1,u=Ps(t,e);let{mainAxis:h,crossAxis:f,alignmentAxis:m}=typeof u=="number"?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return i&&typeof m=="number"&&(f=i==="end"?m*-1:m),l?{x:f*d,y:h*c}:{x:h*c,y:f*d}}const Mx=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var a,n;const{x:r,y:o,placement:s,middlewareData:i}=t,l=await yx(t,e);return s===((a=i.offset)==null?void 0:a.placement)&&(n=i.arrow)!=null&&n.alignmentOffset?{}:{x:r+l.x,y:o+l.y,data:{...l,placement:s}}}}},_x=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:a,y:n,placement:r}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:i={fn:_=>{let{x:b,y:v}=_;return{x:b,y:v}}},...l}=Ps(e,t),c={x:a,y:n},d=await Ol(t,l),u=ko(rr(r)),h=X3(u);let f=c[h],m=c[u];if(o){const _=h==="y"?"top":"left",b=h==="y"?"bottom":"right",v=f+d[_],y=f-d[b];f=Bh(v,f,y)}if(s){const _=u==="y"?"top":"left",b=u==="y"?"bottom":"right",v=m+d[_],y=m-d[b];m=Bh(v,m,y)}const g=i.fn({...t,[h]:f,[u]:m});return{...g,data:{x:g.x-a,y:g.y-n,enabled:{[h]:o,[u]:s}}}}}},bx=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var a,n;const{placement:r,rects:o,platform:s,elements:i}=t,{apply:l=()=>{},...c}=Ps(e,t),d=await Ol(t,c),u=rr(r),h=ar(r),f=ko(r)==="y",{width:m,height:g}=o.floating;let _,b;u==="top"||u==="bottom"?(_=u,b=h===(await(s.isRTL==null?void 0:s.isRTL(i.floating))?"start":"end")?"left":"right"):(b=u,_=h==="end"?"top":"bottom");const v=g-d.top-d.bottom,y=m-d.left-d.right,M=xs(g-d[_],v),x=xs(m-d[b],y),S=!t.middlewareData.shift;let L=M,F=x;if((a=t.middlewareData.shift)!=null&&a.enabled.x&&(F=y),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(L=v),S&&!h){const J=un(d.left,0),be=un(d.right,0),oe=un(d.top,0),Te=un(d.bottom,0);f?F=m-2*(J!==0||be!==0?J+be:un(d.left,d.right)):L=g-2*(oe!==0||Te!==0?oe+Te:un(d.top,d.bottom))}await l({...t,availableWidth:F,availableHeight:L});const te=await s.getDimensions(i.floating);return m!==te.width||g!==te.height?{reset:{rects:!0}}:{}}}};function Hl(){return typeof window<"u"}function Ho(e){return w0(e)?(e.nodeName||"").toLowerCase():"#document"}function pn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function lr(e){var t;return(t=(w0(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function w0(e){return Hl()?e instanceof Node||e instanceof pn(e).Node:!1}function zn(e){return Hl()?e instanceof Element||e instanceof pn(e).Element:!1}function or(e){return Hl()?e instanceof HTMLElement||e instanceof pn(e).HTMLElement:!1}function jh(e){return!Hl()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof pn(e).ShadowRoot}function zi(e){const{overflow:t,overflowX:a,overflowY:n,display:r}=qn(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+a)&&!["inline","contents"].includes(r)}function wx(e){return["table","td","th"].includes(Ho(e))}function Rl(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function x0(e){const t=C0(),a=zn(e)?qn(e):e;return a.transform!=="none"||a.perspective!=="none"||(a.containerType?a.containerType!=="normal":!1)||!t&&(a.backdropFilter?a.backdropFilter!=="none":!1)||!t&&(a.filter?a.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(a.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(a.contain||"").includes(n))}function xx(e){let t=ao(e);for(;or(t)&&!Cs(t);){if(x0(t))return t;if(Rl(t))return null;t=ao(t)}return null}function C0(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Cs(e){return["html","body","#document"].includes(Ho(e))}function qn(e){return pn(e).getComputedStyle(e)}function Nl(e){return zn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ao(e){if(Ho(e)==="html")return e;const t=e.assignedSlot||e.parentNode||jh(e)&&e.host||lr(e);return jh(t)?t.host:t}function t6(e){const t=ao(e);return Cs(t)?e.ownerDocument?e.ownerDocument.body:e.body:or(t)&&zi(t)?t:t6(t)}function Pi(e,t,a){var n;t===void 0&&(t=[]),a===void 0&&(a=!0);const r=t6(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=pn(r);if(o){const i=Ec(s);return t.concat(s,s.visualViewport||[],zi(r)?r:[],i&&a?Pi(i):[])}return t.concat(r,Pi(r,[],a))}function Ec(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function a6(e){const t=qn(e);let a=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const r=or(e),o=r?e.offsetWidth:a,s=r?e.offsetHeight:n,i=ol(a)!==o||ol(n)!==s;return i&&(a=o,n=s),{width:a,height:n,$:i}}function A0(e){return zn(e)?e:e.contextElement}function ms(e){const t=A0(e);if(!or(t))return tr(1);const a=t.getBoundingClientRect(),{width:n,height:r,$:o}=a6(t);let s=(o?ol(a.width):a.width)/n,i=(o?ol(a.height):a.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!i||!Number.isFinite(i))&&(i=1),{x:s,y:i}}const Cx=tr(0);function n6(e){const t=pn(e);return!C0()||!t.visualViewport?Cx:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Ax(e,t,a){return t===void 0&&(t=!1),!a||t&&a!==pn(e)?!1:t}function To(e,t,a,n){t===void 0&&(t=!1),a===void 0&&(a=!1);const r=e.getBoundingClientRect(),o=A0(e);let s=tr(1);t&&(n?zn(n)&&(s=ms(n)):s=ms(e));const i=Ax(o,a,n)?n6(o):tr(0);let l=(r.left+i.x)/s.x,c=(r.top+i.y)/s.y,d=r.width/s.x,u=r.height/s.y;if(o){const h=pn(o),f=n&&zn(n)?pn(n):n;let m=h,g=Ec(m);for(;g&&n&&f!==m;){const _=ms(g),b=g.getBoundingClientRect(),v=qn(g),y=b.left+(g.clientLeft+parseFloat(v.paddingLeft))*_.x,M=b.top+(g.clientTop+parseFloat(v.paddingTop))*_.y;l*=_.x,c*=_.y,d*=_.x,u*=_.y,l+=y,c+=M,m=pn(g),g=Ec(m)}}return ll({width:d,height:u,x:l,y:c})}function S0(e,t){const a=Nl(e).scrollLeft;return t?t.left+a:To(lr(e)).left+a}function r6(e,t,a){a===void 0&&(a=!1);const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-(a?0:S0(e,n)),o=n.top+t.scrollTop;return{x:r,y:o}}function Sx(e){let{elements:t,rect:a,offsetParent:n,strategy:r}=e;const o=r==="fixed",s=lr(n),i=t?Rl(t.floating):!1;if(n===s||i&&o)return a;let l={scrollLeft:0,scrollTop:0},c=tr(1);const d=tr(0),u=or(n);if((u||!u&&!o)&&((Ho(n)!=="body"||zi(s))&&(l=Nl(n)),or(n))){const f=To(n);c=ms(n),d.x=f.x+n.clientLeft,d.y=f.y+n.clientTop}const h=s&&!u&&!o?r6(s,l,!0):tr(0);return{width:a.width*c.x,height:a.height*c.y,x:a.x*c.x-l.scrollLeft*c.x+d.x+h.x,y:a.y*c.y-l.scrollTop*c.y+d.y+h.y}}function $x(e){return Array.from(e.getClientRects())}function Ex(e){const t=lr(e),a=Nl(e),n=e.ownerDocument.body,r=un(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),o=un(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let s=-a.scrollLeft+S0(e);const i=-a.scrollTop;return qn(n).direction==="rtl"&&(s+=un(t.clientWidth,n.clientWidth)-r),{width:r,height:o,x:s,y:i}}function Ix(e,t){const a=pn(e),n=lr(e),r=a.visualViewport;let o=n.clientWidth,s=n.clientHeight,i=0,l=0;if(r){o=r.width,s=r.height;const c=C0();(!c||c&&t==="fixed")&&(i=r.offsetLeft,l=r.offsetTop)}return{width:o,height:s,x:i,y:l}}function kx(e,t){const a=To(e,!0,t==="fixed"),n=a.top+e.clientTop,r=a.left+e.clientLeft,o=or(e)?ms(e):tr(1),s=e.clientWidth*o.x,i=e.clientHeight*o.y,l=r*o.x,c=n*o.y;return{width:s,height:i,x:l,y:c}}function Uh(e,t,a){let n;if(t==="viewport")n=Ix(e,a);else if(t==="document")n=Ex(lr(e));else if(zn(t))n=kx(t,a);else{const r=n6(e);n={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return ll(n)}function o6(e,t){const a=ao(e);return a===t||!zn(a)||Cs(a)?!1:qn(a).position==="fixed"||o6(a,t)}function Tx(e,t){const a=t.get(e);if(a)return a;let n=Pi(e,[],!1).filter(i=>zn(i)&&Ho(i)!=="body"),r=null;const o=qn(e).position==="fixed";let s=o?ao(e):e;for(;zn(s)&&!Cs(s);){const i=qn(s),l=x0(s);!l&&i.position==="fixed"&&(r=null),(o?!l&&!r:!l&&i.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||zi(s)&&!l&&o6(e,s))?n=n.filter(d=>d!==s):r=i,s=ao(s)}return t.set(e,n),n}function Px(e){let{element:t,boundary:a,rootBoundary:n,strategy:r}=e;const s=[...a==="clippingAncestors"?Rl(t)?[]:Tx(t,this._c):[].concat(a),n],i=s[0],l=s.reduce((c,d)=>{const u=Uh(t,d,r);return c.top=un(u.top,c.top),c.right=xs(u.right,c.right),c.bottom=xs(u.bottom,c.bottom),c.left=un(u.left,c.left),c},Uh(t,i,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Lx(e){const{width:t,height:a}=a6(e);return{width:t,height:a}}function Vx(e,t,a){const n=or(t),r=lr(t),o=a==="fixed",s=To(e,!0,o,t);let i={scrollLeft:0,scrollTop:0};const l=tr(0);if(n||!n&&!o)if((Ho(t)!=="body"||zi(r))&&(i=Nl(t)),n){const h=To(t,!0,o,t);l.x=h.x+t.clientLeft,l.y=h.y+t.clientTop}else r&&(l.x=S0(r));const c=r&&!n&&!o?r6(r,i):tr(0),d=s.left+i.scrollLeft-l.x-c.x,u=s.top+i.scrollTop-l.y-c.y;return{x:d,y:u,width:s.width,height:s.height}}function B2(e){return qn(e).position==="static"}function zh(e,t){if(!or(e)||qn(e).position==="fixed")return null;if(t)return t(e);let a=e.offsetParent;return lr(e)===a&&(a=a.ownerDocument.body),a}function s6(e,t){const a=pn(e);if(Rl(e))return a;if(!or(e)){let r=ao(e);for(;r&&!Cs(r);){if(zn(r)&&!B2(r))return r;r=ao(r)}return a}let n=zh(e,t);for(;n&&wx(n)&&B2(n);)n=zh(n,t);return n&&Cs(n)&&B2(n)&&!x0(n)?a:n||xx(e)||a}const Ox=async function(e){const t=this.getOffsetParent||s6,a=this.getDimensions,n=await a(e.floating);return{reference:Vx(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Hx(e){return qn(e).direction==="rtl"}const Rx={convertOffsetParentRelativeRectToViewportRelativeRect:Sx,getDocumentElement:lr,getClippingRect:Px,getOffsetParent:s6,getElementRects:Ox,getClientRects:$x,getDimensions:Lx,getScale:ms,isElement:zn,isRTL:Hx};function Nx(e,t){let a=null,n;const r=lr(e);function o(){var i;clearTimeout(n),(i=a)==null||i.disconnect(),a=null}function s(i,l){i===void 0&&(i=!1),l===void 0&&(l=1),o();const{left:c,top:d,width:u,height:h}=e.getBoundingClientRect();if(i||t(),!u||!h)return;const f=_1(d),m=_1(r.clientWidth-(c+u)),g=_1(r.clientHeight-(d+h)),_=_1(c),v={rootMargin:-f+"px "+-m+"px "+-g+"px "+-_+"px",threshold:un(0,xs(1,l))||1};let y=!0;function M(x){const S=x[0].intersectionRatio;if(S!==l){if(!y)return s();S?s(!1,S):n=setTimeout(()=>{s(!1,1e-7)},1e3)}y=!1}try{a=new IntersectionObserver(M,{...v,root:r.ownerDocument})}catch{a=new IntersectionObserver(M,v)}a.observe(e)}return s(!0),o}function kde(e,t,a,n){n===void 0&&(n={});const{ancestorScroll:r=!0,ancestorResize:o=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=A0(e),d=r||o?[...c?Pi(c):[],...Pi(t)]:[];d.forEach(b=>{r&&b.addEventListener("scroll",a,{passive:!0}),o&&b.addEventListener("resize",a)});const u=c&&i?Nx(c,a):null;let h=-1,f=null;s&&(f=new ResizeObserver(b=>{let[v]=b;v&&v.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var y;(y=f)==null||y.observe(t)})),a()}),c&&!l&&f.observe(c),f.observe(t));let m,g=l?To(e):null;l&&_();function _(){const b=To(e);g&&(b.x!==g.x||b.y!==g.y||b.width!==g.width||b.height!==g.height)&&a(),g=b,m=requestAnimationFrame(_)}return a(),()=>{var b;d.forEach(v=>{r&&v.removeEventListener("scroll",a),o&&v.removeEventListener("resize",a)}),u==null||u(),(b=f)==null||b.disconnect(),f=null,l&&cancelAnimationFrame(m)}}const Dx=Mx,i6=vx,Bx=_x,Tde=gx,Pde=bx,Fx=(e,t,a)=>{const n=new Map,r={platform:Rx,...a},o={...r.platform,_c:n};return fx(e,t,{...r,platform:o})};function jx(e){return e!=null&&typeof e=="object"&&"$el"in e}function qh(e){if(jx(e)){const t=e.$el;return w0(t)&&Ho(t)==="#comment"?null:t}return e}function Xs(e){return typeof e=="function"?e():E(e)}function l6(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Wh(e,t){const a=l6(e);return Math.round(t*a)/a}function c6(e,t,a){a===void 0&&(a={});const n=a.whileElementsMounted,r=H(()=>{var L;return(L=Xs(a.open))!=null?L:!0}),o=H(()=>Xs(a.middleware)),s=H(()=>{var L;return(L=Xs(a.placement))!=null?L:"bottom"}),i=H(()=>{var L;return(L=Xs(a.strategy))!=null?L:"absolute"}),l=H(()=>{var L;return(L=Xs(a.transform))!=null?L:!0}),c=H(()=>qh(e.value)),d=H(()=>qh(t.value)),u=ye(0),h=ye(0),f=ye(i.value),m=ye(s.value),g=$t({}),_=ye(!1),b=H(()=>{const L={position:f.value,left:"0",top:"0"};if(!d.value)return L;const F=Wh(d.value,u.value),te=Wh(d.value,h.value);return l.value?{...L,transform:"translate("+F+"px, "+te+"px)",...l6(d.value)>=1.5&&{willChange:"transform"}}:{position:f.value,left:F+"px",top:te+"px"}});let v;function y(){if(c.value==null||d.value==null)return;const L=r.value;Fx(c.value,d.value,{middleware:o.value,placement:s.value,strategy:i.value}).then(F=>{u.value=F.x,h.value=F.y,f.value=F.strategy,m.value=F.placement,g.value=F.middlewareData,_.value=L!==!1})}function M(){typeof v=="function"&&(v(),v=void 0)}function x(){if(M(),n===void 0){y();return}if(c.value!=null&&d.value!=null){v=n(c.value,d.value,y);return}}function S(){r.value||(_.value=!1)}return We([o,s,i,r],y,{flush:"sync"}),We([c,d],x,{flush:"sync"}),We(r,S,{flush:"sync"}),wl()&&Xc(M),{x:Fr(u),y:Fr(h),strategy:Fr(f),placement:Fr(m),middlewareData:Fr(g),isPositioned:Fr(_),floatingStyles:b,update:y}}const Ux={},zx={class:"WdsSkeletonLoader","aria-busy":"true"};function qx(e,t){return $(),R("div",zx)}const $0=ke(Ux,[["render",qx],["__scopeId","data-v-16706a43"]]);function Wx(){return En("div",{style:{display:"flex",alignItems:"center",justifyContent:"center"}},En("p",{style:{background:"var(--wdsColorOrange2)",padding:"8px",borderRadius:"4px"}},"Could not load the component"))}function Zx(e){return En("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",height:e.height??"100%",width:e.width??"100%",padding:"8px"}},En($0))}const F2=5;function sr(e){return $v({loadingComponent:()=>Zx(e.loadingComponentProps??{}),errorComponent:Wx,delay:300,onError(t,a,n,r){const o=fa();if(r<=F2){const s=`Failed to load async component (retry ${r}/${F2})`;o.warn(s,t),setTimeout(a,1e3)}else{const s=`Failed to load async component after ${F2} attempts`;o.error(s,t),n()}},...e})}const Kx={key:0,class:"CoreDataframeRow__cell CoreDataframeRow__cell--index"},Gx=$e({__name:"CoreDataframeRow",props:{showIndex:{type:Boolean,required:!1},wrapText:{type:Boolean,required:!1},indexText:{type:[Number,String],required:!0},columns:{type:Array,required:!0},row:{type:Object,required:!0},useMarkdown:{type:Boolean,required:!1},editable:{type:Boolean,required:!1},actions:{type:Object,required:!0},displayShadowOnSticky:{type:Boolean}},emits:{change:(e,t,a)=>typeof e=="string"&&typeof t=="number"&&a!==void 0,action:(e,t)=>typeof t=="number"&&typeof e=="string"},setup(e){const t=sr({loader:()=>zt(()=>Promise.resolve().then(()=>i0e),void 0,import.meta.url)}),a=[Dx(16),Bx()],n=e,r=ye(),o=b0(r),s=ye(!1),i=H(()=>Object.keys(n.actions||{}).length>0),l=H(()=>Object.entries(n.actions||{}).map(([c,d])=>({value:c,label:d})));return(c,d)=>($(),R("div",{ref_key:"root",ref:r,class:"CoreDataframeRow",tabindex:"0",onMouseover:d[1]||(d[1]=u=>s.value=!0),onMouseleave:d[2]||(d[2]=u=>s.value=!1),onFocusin:d[3]||(d[3]=u=>s.value=!0)},[d[4]||(d[4]=Z("div",{class:"CoreDataframeRow__spacer"},null,-1)),e.showIndex?($(),R("div",Kx,je(e.indexText),1)):ge("",!0),($(!0),R(Je,null,Ot(e.columns,u=>($(),R("div",{key:`${e.row[E(xn)]}_${u}`,class:"CoreDataframeRow__cell"},[Ce(rx,{value:e.row[u],"use-markdown":e.useMarkdown,editable:e.editable&&(s.value||E(o)),"wrap-text":e.wrapText,class:"CoreDataframeRow__cell__content",onChange:h=>c.$emit("change",u,e.row[E(xn)],h)},null,8,["value","use-markdown","editable","wrap-text","onChange"])]))),128)),i.value?($(),R("div",{key:1,class:ft(["CoreDataframeRow__options",{"CoreDataframeRow__options--shadow":e.displayShadowOnSticky}])},[Ce(E(t),{options:l.value,"hide-icons":"","dropdown-placement":"left","floating-middleware":a,onSelect:d[0]||(d[0]=u=>c.$emit("action",u,e.row[E(xn)]))},null,8,["options"])],2)):ge("",!0)],544))}}),Jx=ke(Gx,[["__scopeId","data-v-2c661540"]]);var Xx=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function E0(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ic={exports:{}},d6={},Sn={},As={},Ls={},kt={},Ss={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.regexpCode=e.getEsmExportName=e.getProperty=e.safeStringify=e.stringify=e.strConcat=e.addCodeArg=e.str=e._=e.nil=e._Code=e.Name=e.IDENTIFIER=e._CodeOrName=void 0;class t{}e._CodeOrName=t,e.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class a extends t{constructor(v){if(super(),!e.IDENTIFIER.test(v))throw new Error("CodeGen: name must be a valid identifier");this.str=v}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}e.Name=a;class n extends t{constructor(v){super(),this._items=typeof v=="string"?[v]:v}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const v=this._items[0];return v===""||v==='""'}get str(){var v;return(v=this._str)!==null&&v!==void 0?v:this._str=this._items.reduce((y,M)=>`${y}${M}`,"")}get names(){var v;return(v=this._names)!==null&&v!==void 0?v:this._names=this._items.reduce((y,M)=>(M instanceof a&&(y[M.str]=(y[M.str]||0)+1),y),{})}}e._Code=n,e.nil=new n("");function r(b,...v){const y=[b[0]];let M=0;for(;M<v.length;)i(y,v[M]),y.push(b[++M]);return new n(y)}e._=r;const o=new n("+");function s(b,...v){const y=[f(b[0])];let M=0;for(;M<v.length;)y.push(o),i(y,v[M]),y.push(o,f(b[++M]));return l(y),new n(y)}e.str=s;function i(b,v){v instanceof n?b.push(...v._items):v instanceof a?b.push(v):b.push(u(v))}e.addCodeArg=i;function l(b){let v=1;for(;v<b.length-1;){if(b[v]===o){const y=c(b[v-1],b[v+1]);if(y!==void 0){b.splice(v-1,3,y);continue}b[v++]="+"}v++}}function c(b,v){if(v==='""')return b;if(b==='""')return v;if(typeof b=="string")return v instanceof a||b[b.length-1]!=='"'?void 0:typeof v!="string"?`${b.slice(0,-1)}${v}"`:v[0]==='"'?b.slice(0,-1)+v.slice(1):void 0;if(typeof v=="string"&&v[0]==='"'&&!(b instanceof a))return`"${b}${v.slice(1)}`}function d(b,v){return v.emptyStr()?b:b.emptyStr()?v:s`${b}${v}`}e.strConcat=d;function u(b){return typeof b=="number"||typeof b=="boolean"||b===null?b:f(Array.isArray(b)?b.join(","):b)}function h(b){return new n(f(b))}e.stringify=h;function f(b){return JSON.stringify(b).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}e.safeStringify=f;function m(b){return typeof b=="string"&&e.IDENTIFIER.test(b)?new n(`.${b}`):r`[${b}]`}e.getProperty=m;function g(b){if(typeof b=="string"&&e.IDENTIFIER.test(b))return new n(`${b}`);throw new Error(`CodeGen: invalid export name: ${b}, use explicit $id name mapping`)}e.getEsmExportName=g;function _(b){return new n(b.toString())}e.regexpCode=_})(Ss);var kc={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ValueScope=e.ValueScopeName=e.Scope=e.varKinds=e.UsedValueState=void 0;const t=Ss;class a extends Error{constructor(c){super(`CodeGen: "code" for ${c} not defined`),this.value=c.value}}var n;(function(l){l[l.Started=0]="Started",l[l.Completed=1]="Completed"})(n||(e.UsedValueState=n={})),e.varKinds={const:new t.Name("const"),let:new t.Name("let"),var:new t.Name("var")};class r{constructor({prefixes:c,parent:d}={}){this._names={},this._prefixes=c,this._parent=d}toName(c){return c instanceof t.Name?c:this.name(c)}name(c){return new t.Name(this._newName(c))}_newName(c){const d=this._names[c]||this._nameGroup(c);return`${c}${d.index++}`}_nameGroup(c){var d,u;if(!((u=(d=this._parent)===null||d===void 0?void 0:d._prefixes)===null||u===void 0)&&u.has(c)||this._prefixes&&!this._prefixes.has(c))throw new Error(`CodeGen: prefix "${c}" is not allowed in this scope`);return this._names[c]={prefix:c,index:0}}}e.Scope=r;class o extends t.Name{constructor(c,d){super(d),this.prefix=c}setValue(c,{property:d,itemIndex:u}){this.value=c,this.scopePath=(0,t._)`.${new t.Name(d)}[${u}]`}}e.ValueScopeName=o;const s=(0,t._)`\n`;class i extends r{constructor(c){super(c),this._values={},this._scope=c.scope,this.opts={...c,_n:c.lines?s:t.nil}}get(){return this._scope}name(c){return new o(c,this._newName(c))}value(c,d){var u;if(d.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const h=this.toName(c),{prefix:f}=h,m=(u=d.key)!==null&&u!==void 0?u:d.ref;let g=this._values[f];if(g){const v=g.get(m);if(v)return v}else g=this._values[f]=new Map;g.set(m,h);const _=this._scope[f]||(this._scope[f]=[]),b=_.length;return _[b]=d.ref,h.setValue(d,{property:f,itemIndex:b}),h}getValue(c,d){const u=this._values[c];if(u)return u.get(d)}scopeRefs(c,d=this._values){return this._reduceValues(d,u=>{if(u.scopePath===void 0)throw new Error(`CodeGen: name "${u}" has no value`);return(0,t._)`${c}${u.scopePath}`})}scopeCode(c=this._values,d,u){return this._reduceValues(c,h=>{if(h.value===void 0)throw new Error(`CodeGen: name "${h}" has no value`);return h.value.code},d,u)}_reduceValues(c,d,u={},h){let f=t.nil;for(const m in c){const g=c[m];if(!g)continue;const _=u[m]=u[m]||new Map;g.forEach(b=>{if(_.has(b))return;_.set(b,n.Started);let v=d(b);if(v){const y=this.opts.es5?e.varKinds.var:e.varKinds.const;f=(0,t._)`${f}${y} ${b} = ${v};${this.opts._n}`}else if(v=h==null?void 0:h(b))f=(0,t._)`${f}${v}${this.opts._n}`;else throw new a(b);_.set(b,n.Completed)})}return f}}e.ValueScope=i})(kc);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.or=e.and=e.not=e.CodeGen=e.operators=e.varKinds=e.ValueScopeName=e.ValueScope=e.Scope=e.Name=e.regexpCode=e.stringify=e.getProperty=e.nil=e.strConcat=e.str=e._=void 0;const t=Ss,a=kc;var n=Ss;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return n._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return n.str}}),Object.defineProperty(e,"strConcat",{enumerable:!0,get:function(){return n.strConcat}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return n.nil}}),Object.defineProperty(e,"getProperty",{enumerable:!0,get:function(){return n.getProperty}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return n.stringify}}),Object.defineProperty(e,"regexpCode",{enumerable:!0,get:function(){return n.regexpCode}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return n.Name}});var r=kc;Object.defineProperty(e,"Scope",{enumerable:!0,get:function(){return r.Scope}}),Object.defineProperty(e,"ValueScope",{enumerable:!0,get:function(){return r.ValueScope}}),Object.defineProperty(e,"ValueScopeName",{enumerable:!0,get:function(){return r.ValueScopeName}}),Object.defineProperty(e,"varKinds",{enumerable:!0,get:function(){return r.varKinds}}),e.operators={GT:new t._Code(">"),GTE:new t._Code(">="),LT:new t._Code("<"),LTE:new t._Code("<="),EQ:new t._Code("==="),NEQ:new t._Code("!=="),NOT:new t._Code("!"),OR:new t._Code("||"),AND:new t._Code("&&"),ADD:new t._Code("+")};class o{optimizeNodes(){return this}optimizeNames(C,P){return this}}class s extends o{constructor(C,P,ae){super(),this.varKind=C,this.name=P,this.rhs=ae}render({es5:C,_n:P}){const ae=C?a.varKinds.var:this.varKind,xe=this.rhs===void 0?"":` = ${this.rhs}`;return`${ae} ${this.name}${xe};`+P}optimizeNames(C,P){if(C[this.name.str])return this.rhs&&(this.rhs=Ue(this.rhs,C,P)),this}get names(){return this.rhs instanceof t._CodeOrName?this.rhs.names:{}}}class i extends o{constructor(C,P,ae){super(),this.lhs=C,this.rhs=P,this.sideEffects=ae}render({_n:C}){return`${this.lhs} = ${this.rhs};`+C}optimizeNames(C,P){if(!(this.lhs instanceof t.Name&&!C[this.lhs.str]&&!this.sideEffects))return this.rhs=Ue(this.rhs,C,P),this}get names(){const C=this.lhs instanceof t.Name?{}:{...this.lhs.names};return Te(C,this.rhs)}}class l extends i{constructor(C,P,ae,xe){super(C,ae,xe),this.op=P}render({_n:C}){return`${this.lhs} ${this.op}= ${this.rhs};`+C}}class c extends o{constructor(C){super(),this.label=C,this.names={}}render({_n:C}){return`${this.label}:`+C}}class d extends o{constructor(C){super(),this.label=C,this.names={}}render({_n:C}){return`break${this.label?` ${this.label}`:""};`+C}}class u extends o{constructor(C){super(),this.error=C}render({_n:C}){return`throw ${this.error};`+C}get names(){return this.error.names}}class h extends o{constructor(C){super(),this.code=C}render({_n:C}){return`${this.code};`+C}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(C,P){return this.code=Ue(this.code,C,P),this}get names(){return this.code instanceof t._CodeOrName?this.code.names:{}}}class f extends o{constructor(C=[]){super(),this.nodes=C}render(C){return this.nodes.reduce((P,ae)=>P+ae.render(C),"")}optimizeNodes(){const{nodes:C}=this;let P=C.length;for(;P--;){const ae=C[P].optimizeNodes();Array.isArray(ae)?C.splice(P,1,...ae):ae?C[P]=ae:C.splice(P,1)}return C.length>0?this:void 0}optimizeNames(C,P){const{nodes:ae}=this;let xe=ae.length;for(;xe--;){const ve=ae[xe];ve.optimizeNames(C,P)||(Ze(C,ve.names),ae.splice(xe,1))}return ae.length>0?this:void 0}get names(){return this.nodes.reduce((C,P)=>oe(C,P.names),{})}}class m extends f{render(C){return"{"+C._n+super.render(C)+"}"+C._n}}class g extends f{}class _ extends m{}_.kind="else";class b extends m{constructor(C,P){super(P),this.condition=C}render(C){let P=`if(${this.condition})`+super.render(C);return this.else&&(P+="else "+this.else.render(C)),P}optimizeNodes(){super.optimizeNodes();const C=this.condition;if(C===!0)return this.nodes;let P=this.else;if(P){const ae=P.optimizeNodes();P=this.else=Array.isArray(ae)?new _(ae):ae}if(P)return C===!1?P instanceof b?P:P.nodes:this.nodes.length?this:new b(Me(C),P instanceof b?[P]:P.nodes);if(!(C===!1||!this.nodes.length))return this}optimizeNames(C,P){var ae;if(this.else=(ae=this.else)===null||ae===void 0?void 0:ae.optimizeNames(C,P),!!(super.optimizeNames(C,P)||this.else))return this.condition=Ue(this.condition,C,P),this}get names(){const C=super.names;return Te(C,this.condition),this.else&&oe(C,this.else.names),C}}b.kind="if";class v extends m{}v.kind="for";class y extends v{constructor(C){super(),this.iteration=C}render(C){return`for(${this.iteration})`+super.render(C)}optimizeNames(C,P){if(super.optimizeNames(C,P))return this.iteration=Ue(this.iteration,C,P),this}get names(){return oe(super.names,this.iteration.names)}}class M extends v{constructor(C,P,ae,xe){super(),this.varKind=C,this.name=P,this.from=ae,this.to=xe}render(C){const P=C.es5?a.varKinds.var:this.varKind,{name:ae,from:xe,to:ve}=this;return`for(${P} ${ae}=${xe}; ${ae}<${ve}; ${ae}++)`+super.render(C)}get names(){const C=Te(super.names,this.from);return Te(C,this.to)}}class x extends v{constructor(C,P,ae,xe){super(),this.loop=C,this.varKind=P,this.name=ae,this.iterable=xe}render(C){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(C)}optimizeNames(C,P){if(super.optimizeNames(C,P))return this.iterable=Ue(this.iterable,C,P),this}get names(){return oe(super.names,this.iterable.names)}}class S extends m{constructor(C,P,ae){super(),this.name=C,this.args=P,this.async=ae}render(C){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(C)}}S.kind="func";class L extends f{render(C){return"return "+super.render(C)}}L.kind="return";class F extends m{render(C){let P="try"+super.render(C);return this.catch&&(P+=this.catch.render(C)),this.finally&&(P+=this.finally.render(C)),P}optimizeNodes(){var C,P;return super.optimizeNodes(),(C=this.catch)===null||C===void 0||C.optimizeNodes(),(P=this.finally)===null||P===void 0||P.optimizeNodes(),this}optimizeNames(C,P){var ae,xe;return super.optimizeNames(C,P),(ae=this.catch)===null||ae===void 0||ae.optimizeNames(C,P),(xe=this.finally)===null||xe===void 0||xe.optimizeNames(C,P),this}get names(){const C=super.names;return this.catch&&oe(C,this.catch.names),this.finally&&oe(C,this.finally.names),C}}class te extends m{constructor(C){super(),this.error=C}render(C){return`catch(${this.error})`+super.render(C)}}te.kind="catch";class J extends m{render(C){return"finally"+super.render(C)}}J.kind="finally";class be{constructor(C,P={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...P,_n:P.lines?`
30
- `:""},this._extScope=C,this._scope=new a.Scope({parent:C}),this._nodes=[new g]}toString(){return this._root.render(this.opts)}name(C){return this._scope.name(C)}scopeName(C){return this._extScope.name(C)}scopeValue(C,P){const ae=this._extScope.value(C,P);return(this._values[ae.prefix]||(this._values[ae.prefix]=new Set)).add(ae),ae}getScopeValue(C,P){return this._extScope.getValue(C,P)}scopeRefs(C){return this._extScope.scopeRefs(C,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(C,P,ae,xe){const ve=this._scope.toName(P);return ae!==void 0&&xe&&(this._constants[ve.str]=ae),this._leafNode(new s(C,ve,ae)),ve}const(C,P,ae){return this._def(a.varKinds.const,C,P,ae)}let(C,P,ae){return this._def(a.varKinds.let,C,P,ae)}var(C,P,ae){return this._def(a.varKinds.var,C,P,ae)}assign(C,P,ae){return this._leafNode(new i(C,P,ae))}add(C,P){return this._leafNode(new l(C,e.operators.ADD,P))}code(C){return typeof C=="function"?C():C!==t.nil&&this._leafNode(new h(C)),this}object(...C){const P=["{"];for(const[ae,xe]of C)P.length>1&&P.push(","),P.push(ae),(ae!==xe||this.opts.es5)&&(P.push(":"),(0,t.addCodeArg)(P,xe));return P.push("}"),new t._Code(P)}if(C,P,ae){if(this._blockNode(new b(C)),P&&ae)this.code(P).else().code(ae).endIf();else if(P)this.code(P).endIf();else if(ae)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(C){return this._elseNode(new b(C))}else(){return this._elseNode(new _)}endIf(){return this._endBlockNode(b,_)}_for(C,P){return this._blockNode(C),P&&this.code(P).endFor(),this}for(C,P){return this._for(new y(C),P)}forRange(C,P,ae,xe,ve=this.opts.es5?a.varKinds.var:a.varKinds.let){const ze=this._scope.toName(C);return this._for(new M(ve,ze,P,ae),()=>xe(ze))}forOf(C,P,ae,xe=a.varKinds.const){const ve=this._scope.toName(C);if(this.opts.es5){const ze=P instanceof t.Name?P:this.var("_arr",P);return this.forRange("_i",0,(0,t._)`${ze}.length`,Ye=>{this.var(ve,(0,t._)`${ze}[${Ye}]`),ae(ve)})}return this._for(new x("of",xe,ve,P),()=>ae(ve))}forIn(C,P,ae,xe=this.opts.es5?a.varKinds.var:a.varKinds.const){if(this.opts.ownProperties)return this.forOf(C,(0,t._)`Object.keys(${P})`,ae);const ve=this._scope.toName(C);return this._for(new x("in",xe,ve,P),()=>ae(ve))}endFor(){return this._endBlockNode(v)}label(C){return this._leafNode(new c(C))}break(C){return this._leafNode(new d(C))}return(C){const P=new L;if(this._blockNode(P),this.code(C),P.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(L)}try(C,P,ae){if(!P&&!ae)throw new Error('CodeGen: "try" without "catch" and "finally"');const xe=new F;if(this._blockNode(xe),this.code(C),P){const ve=this.name("e");this._currNode=xe.catch=new te(ve),P(ve)}return ae&&(this._currNode=xe.finally=new J,this.code(ae)),this._endBlockNode(te,J)}throw(C){return this._leafNode(new u(C))}block(C,P){return this._blockStarts.push(this._nodes.length),C&&this.code(C).endBlock(P),this}endBlock(C){const P=this._blockStarts.pop();if(P===void 0)throw new Error("CodeGen: not in self-balancing block");const ae=this._nodes.length-P;if(ae<0||C!==void 0&&ae!==C)throw new Error(`CodeGen: wrong number of nodes: ${ae} vs ${C} expected`);return this._nodes.length=P,this}func(C,P=t.nil,ae,xe){return this._blockNode(new S(C,P,ae)),xe&&this.code(xe).endFunc(),this}endFunc(){return this._endBlockNode(S)}optimize(C=1){for(;C-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(C){return this._currNode.nodes.push(C),this}_blockNode(C){this._currNode.nodes.push(C),this._nodes.push(C)}_endBlockNode(C,P){const ae=this._currNode;if(ae instanceof C||P&&ae instanceof P)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${P?`${C.kind}/${P.kind}`:C.kind}"`)}_elseNode(C){const P=this._currNode;if(!(P instanceof b))throw new Error('CodeGen: "else" without "if"');return this._currNode=P.else=C,this}get _root(){return this._nodes[0]}get _currNode(){const C=this._nodes;return C[C.length-1]}set _currNode(C){const P=this._nodes;P[P.length-1]=C}}e.CodeGen=be;function oe(k,C){for(const P in C)k[P]=(k[P]||0)+(C[P]||0);return k}function Te(k,C){return C instanceof t._CodeOrName?oe(k,C.names):k}function Ue(k,C,P){if(k instanceof t.Name)return ae(k);if(!xe(k))return k;return new t._Code(k._items.reduce((ve,ze)=>(ze instanceof t.Name&&(ze=ae(ze)),ze instanceof t._Code?ve.push(...ze._items):ve.push(ze),ve),[]));function ae(ve){const ze=P[ve.str];return ze===void 0||C[ve.str]!==1?ve:(delete C[ve.str],ze)}function xe(ve){return ve instanceof t._Code&&ve._items.some(ze=>ze instanceof t.Name&&C[ze.str]===1&&P[ze.str]!==void 0)}}function Ze(k,C){for(const P in C)k[P]=(k[P]||0)-(C[P]||0)}function Me(k){return typeof k=="boolean"||typeof k=="number"||k===null?!k:(0,t._)`!${O(k)}`}e.not=Me;const ee=T(e.operators.AND);function j(...k){return k.reduce(ee)}e.and=j;const K=T(e.operators.OR);function G(...k){return k.reduce(K)}e.or=G;function T(k){return(C,P)=>C===t.nil?P:P===t.nil?C:(0,t._)`${O(C)} ${k} ${O(P)}`}function O(k){return k instanceof t.Name?k:(0,t._)`(${k})`}})(kt);var et={};Object.defineProperty(et,"__esModule",{value:!0});et.checkStrictMode=et.getErrorPath=et.Type=et.useFunc=et.setEvaluated=et.evaluatedPropsToName=et.mergeEvaluated=et.eachItem=et.unescapeJsonPointer=et.escapeJsonPointer=et.escapeFragment=et.unescapeFragment=et.schemaRefOrVal=et.schemaHasRulesButRef=et.schemaHasRules=et.checkUnknownRules=et.alwaysValidSchema=et.toHash=void 0;const ta=kt,Yx=Ss;function Qx(e){const t={};for(const a of e)t[a]=!0;return t}et.toHash=Qx;function eC(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(u6(e,t),!h6(t,e.self.RULES.all))}et.alwaysValidSchema=eC;function u6(e,t=e.schema){const{opts:a,self:n}=e;if(!a.strictSchema||typeof t=="boolean")return;const r=n.RULES.keywords;for(const o in t)r[o]||m6(e,`unknown keyword: "${o}"`)}et.checkUnknownRules=u6;function h6(e,t){if(typeof e=="boolean")return!e;for(const a in e)if(t[a])return!0;return!1}et.schemaHasRules=h6;function tC(e,t){if(typeof e=="boolean")return!e;for(const a in e)if(a!=="$ref"&&t.all[a])return!0;return!1}et.schemaHasRulesButRef=tC;function aC({topSchemaRef:e,schemaPath:t},a,n,r){if(!r){if(typeof a=="number"||typeof a=="boolean")return a;if(typeof a=="string")return(0,ta._)`${a}`}return(0,ta._)`${e}${t}${(0,ta.getProperty)(n)}`}et.schemaRefOrVal=aC;function nC(e){return p6(decodeURIComponent(e))}et.unescapeFragment=nC;function rC(e){return encodeURIComponent(I0(e))}et.escapeFragment=rC;function I0(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}et.escapeJsonPointer=I0;function p6(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}et.unescapeJsonPointer=p6;function oC(e,t){if(Array.isArray(e))for(const a of e)t(a);else t(e)}et.eachItem=oC;function Zh({mergeNames:e,mergeToName:t,mergeValues:a,resultToName:n}){return(r,o,s,i)=>{const l=s===void 0?o:s instanceof ta.Name?(o instanceof ta.Name?e(r,o,s):t(r,o,s),s):o instanceof ta.Name?(t(r,s,o),o):a(o,s);return i===ta.Name&&!(l instanceof ta.Name)?n(r,l):l}}et.mergeEvaluated={props:Zh({mergeNames:(e,t,a)=>e.if((0,ta._)`${a} !== true && ${t} !== undefined`,()=>{e.if((0,ta._)`${t} === true`,()=>e.assign(a,!0),()=>e.assign(a,(0,ta._)`${a} || {}`).code((0,ta._)`Object.assign(${a}, ${t})`))}),mergeToName:(e,t,a)=>e.if((0,ta._)`${a} !== true`,()=>{t===!0?e.assign(a,!0):(e.assign(a,(0,ta._)`${a} || {}`),k0(e,a,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:f6}),items:Zh({mergeNames:(e,t,a)=>e.if((0,ta._)`${a} !== true && ${t} !== undefined`,()=>e.assign(a,(0,ta._)`${t} === true ? true : ${a} > ${t} ? ${a} : ${t}`)),mergeToName:(e,t,a)=>e.if((0,ta._)`${a} !== true`,()=>e.assign(a,t===!0?!0:(0,ta._)`${a} > ${t} ? ${a} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function f6(e,t){if(t===!0)return e.var("props",!0);const a=e.var("props",(0,ta._)`{}`);return t!==void 0&&k0(e,a,t),a}et.evaluatedPropsToName=f6;function k0(e,t,a){Object.keys(a).forEach(n=>e.assign((0,ta._)`${t}${(0,ta.getProperty)(n)}`,!0))}et.setEvaluated=k0;const Kh={};function sC(e,t){return e.scopeValue("func",{ref:t,code:Kh[t.code]||(Kh[t.code]=new Yx._Code(t.code))})}et.useFunc=sC;var Tc;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(Tc||(et.Type=Tc={}));function iC(e,t,a){if(e instanceof ta.Name){const n=t===Tc.Num;return a?n?(0,ta._)`"[" + ${e} + "]"`:(0,ta._)`"['" + ${e} + "']"`:n?(0,ta._)`"/" + ${e}`:(0,ta._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return a?(0,ta.getProperty)(e).toString():"/"+I0(e)}et.getErrorPath=iC;function m6(e,t,a=e.opts.strictSchema){if(a){if(t=`strict mode: ${t}`,a===!0)throw new Error(t);e.self.logger.warn(t)}}et.checkStrictMode=m6;var Zn={};Object.defineProperty(Zn,"__esModule",{value:!0});const Fa=kt,lC={data:new Fa.Name("data"),valCxt:new Fa.Name("valCxt"),instancePath:new Fa.Name("instancePath"),parentData:new Fa.Name("parentData"),parentDataProperty:new Fa.Name("parentDataProperty"),rootData:new Fa.Name("rootData"),dynamicAnchors:new Fa.Name("dynamicAnchors"),vErrors:new Fa.Name("vErrors"),errors:new Fa.Name("errors"),this:new Fa.Name("this"),self:new Fa.Name("self"),scope:new Fa.Name("scope"),json:new Fa.Name("json"),jsonPos:new Fa.Name("jsonPos"),jsonLen:new Fa.Name("jsonLen"),jsonPart:new Fa.Name("jsonPart")};Zn.default=lC;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.extendErrors=e.resetErrorsCount=e.reportExtraError=e.reportError=e.keyword$DataError=e.keywordError=void 0;const t=kt,a=et,n=Zn;e.keywordError={message:({keyword:_})=>(0,t.str)`must pass "${_}" keyword validation`},e.keyword$DataError={message:({keyword:_,schemaType:b})=>b?(0,t.str)`"${_}" keyword must be ${b} ($data)`:(0,t.str)`"${_}" keyword is invalid ($data)`};function r(_,b=e.keywordError,v,y){const{it:M}=_,{gen:x,compositeRule:S,allErrors:L}=M,F=u(_,b,v);y??(S||L)?l(x,F):c(M,(0,t._)`[${F}]`)}e.reportError=r;function o(_,b=e.keywordError,v){const{it:y}=_,{gen:M,compositeRule:x,allErrors:S}=y,L=u(_,b,v);l(M,L),x||S||c(y,n.default.vErrors)}e.reportExtraError=o;function s(_,b){_.assign(n.default.errors,b),_.if((0,t._)`${n.default.vErrors} !== null`,()=>_.if(b,()=>_.assign((0,t._)`${n.default.vErrors}.length`,b),()=>_.assign(n.default.vErrors,null)))}e.resetErrorsCount=s;function i({gen:_,keyword:b,schemaValue:v,data:y,errsCount:M,it:x}){if(M===void 0)throw new Error("ajv implementation error");const S=_.name("err");_.forRange("i",M,n.default.errors,L=>{_.const(S,(0,t._)`${n.default.vErrors}[${L}]`),_.if((0,t._)`${S}.instancePath === undefined`,()=>_.assign((0,t._)`${S}.instancePath`,(0,t.strConcat)(n.default.instancePath,x.errorPath))),_.assign((0,t._)`${S}.schemaPath`,(0,t.str)`${x.errSchemaPath}/${b}`),x.opts.verbose&&(_.assign((0,t._)`${S}.schema`,v),_.assign((0,t._)`${S}.data`,y))})}e.extendErrors=i;function l(_,b){const v=_.const("err",b);_.if((0,t._)`${n.default.vErrors} === null`,()=>_.assign(n.default.vErrors,(0,t._)`[${v}]`),(0,t._)`${n.default.vErrors}.push(${v})`),_.code((0,t._)`${n.default.errors}++`)}function c(_,b){const{gen:v,validateName:y,schemaEnv:M}=_;M.$async?v.throw((0,t._)`new ${_.ValidationError}(${b})`):(v.assign((0,t._)`${y}.errors`,b),v.return(!1))}const d={keyword:new t.Name("keyword"),schemaPath:new t.Name("schemaPath"),params:new t.Name("params"),propertyName:new t.Name("propertyName"),message:new t.Name("message"),schema:new t.Name("schema"),parentSchema:new t.Name("parentSchema")};function u(_,b,v){const{createErrors:y}=_.it;return y===!1?(0,t._)`{}`:h(_,b,v)}function h(_,b,v={}){const{gen:y,it:M}=_,x=[f(M,v),m(_,v)];return g(_,b,x),y.object(...x)}function f({errorPath:_},{instancePath:b}){const v=b?(0,t.str)`${_}${(0,a.getErrorPath)(b,a.Type.Str)}`:_;return[n.default.instancePath,(0,t.strConcat)(n.default.instancePath,v)]}function m({keyword:_,it:{errSchemaPath:b}},{schemaPath:v,parentSchema:y}){let M=y?b:(0,t.str)`${b}/${_}`;return v&&(M=(0,t.str)`${M}${(0,a.getErrorPath)(v,a.Type.Str)}`),[d.schemaPath,M]}function g(_,{params:b,message:v},y){const{keyword:M,data:x,schemaValue:S,it:L}=_,{opts:F,propertyName:te,topSchemaRef:J,schemaPath:be}=L;y.push([d.keyword,M],[d.params,typeof b=="function"?b(_):b||(0,t._)`{}`]),F.messages&&y.push([d.message,typeof v=="function"?v(_):v]),F.verbose&&y.push([d.schema,S],[d.parentSchema,(0,t._)`${J}${be}`],[n.default.data,x]),te&&y.push([d.propertyName,te])}})(Ls);Object.defineProperty(As,"__esModule",{value:!0});As.boolOrEmptySchema=As.topBoolOrEmptySchema=void 0;const cC=Ls,dC=kt,uC=Zn,hC={message:"boolean schema is false"};function pC(e){const{gen:t,schema:a,validateName:n}=e;a===!1?v6(e,!1):typeof a=="object"&&a.$async===!0?t.return(uC.default.data):(t.assign((0,dC._)`${n}.errors`,null),t.return(!0))}As.topBoolOrEmptySchema=pC;function fC(e,t){const{gen:a,schema:n}=e;n===!1?(a.var(t,!1),v6(e)):a.var(t,!0)}As.boolOrEmptySchema=fC;function v6(e,t){const{gen:a,data:n}=e,r={gen:a,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,cC.reportError)(r,hC,void 0,t)}var Sa={},Po={};Object.defineProperty(Po,"__esModule",{value:!0});Po.getRules=Po.isJSONType=void 0;const mC=["string","number","integer","boolean","null","object","array"],vC=new Set(mC);function gC(e){return typeof e=="string"&&vC.has(e)}Po.isJSONType=gC;function yC(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}Po.getRules=yC;var wr={};Object.defineProperty(wr,"__esModule",{value:!0});wr.shouldUseRule=wr.shouldUseGroup=wr.schemaHasRulesForType=void 0;function MC({schema:e,self:t},a){const n=t.RULES.types[a];return n&&n!==!0&&g6(e,n)}wr.schemaHasRulesForType=MC;function g6(e,t){return t.rules.some(a=>y6(e,a))}wr.shouldUseGroup=g6;function y6(e,t){var a;return e[t.keyword]!==void 0||((a=t.definition.implements)===null||a===void 0?void 0:a.some(n=>e[n]!==void 0))}wr.shouldUseRule=y6;Object.defineProperty(Sa,"__esModule",{value:!0});Sa.reportTypeError=Sa.checkDataTypes=Sa.checkDataType=Sa.coerceAndCheckDataType=Sa.getJSONTypes=Sa.getSchemaTypes=Sa.DataType=void 0;const _C=Po,bC=wr,wC=Ls,Ct=kt,M6=et;var vs;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(vs||(Sa.DataType=vs={}));function xC(e){const t=_6(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}Sa.getSchemaTypes=xC;function _6(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(_C.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}Sa.getJSONTypes=_6;function CC(e,t){const{gen:a,data:n,opts:r}=e,o=AC(t,r.coerceTypes),s=t.length>0&&!(o.length===0&&t.length===1&&(0,bC.schemaHasRulesForType)(e,t[0]));if(s){const i=T0(t,n,r.strictNumbers,vs.Wrong);a.if(i,()=>{o.length?SC(e,t,o):P0(e)})}return s}Sa.coerceAndCheckDataType=CC;const b6=new Set(["string","number","integer","boolean","null"]);function AC(e,t){return t?e.filter(a=>b6.has(a)||t==="array"&&a==="array"):[]}function SC(e,t,a){const{gen:n,data:r,opts:o}=e,s=n.let("dataType",(0,Ct._)`typeof ${r}`),i=n.let("coerced",(0,Ct._)`undefined`);o.coerceTypes==="array"&&n.if((0,Ct._)`${s} == 'object' && Array.isArray(${r}) && ${r}.length == 1`,()=>n.assign(r,(0,Ct._)`${r}[0]`).assign(s,(0,Ct._)`typeof ${r}`).if(T0(t,r,o.strictNumbers),()=>n.assign(i,r))),n.if((0,Ct._)`${i} !== undefined`);for(const c of a)(b6.has(c)||c==="array"&&o.coerceTypes==="array")&&l(c);n.else(),P0(e),n.endIf(),n.if((0,Ct._)`${i} !== undefined`,()=>{n.assign(r,i),$C(e,i)});function l(c){switch(c){case"string":n.elseIf((0,Ct._)`${s} == "number" || ${s} == "boolean"`).assign(i,(0,Ct._)`"" + ${r}`).elseIf((0,Ct._)`${r} === null`).assign(i,(0,Ct._)`""`);return;case"number":n.elseIf((0,Ct._)`${s} == "boolean" || ${r} === null
28
+ **/const tw=()=>{},aw=Object.freeze(Object.defineProperty({__proto__:null,BaseTransition:Cv,BaseTransitionPropsValidators:o0,Comment:_a,DeprecationTypes:vb,EffectScope:Jc,ErrorCodes:LM,ErrorTypeStrings:cb,Fragment:Je,KeepAlive:t_,ReactiveEffect:xi,Static:Eo,Suspense:z_,Teleport:_v,Text:Yr,TrackOpTypes:SM,Transition:m0,TransitionGroup:Ub,TriggerOpTypes:$M,VueElement:Vl,assertNumber:PM,callWithAsyncErrorHandling:$n,callWithErrorHandling:ks,camelize:Da,capitalize:Hi,cloneVNode:rr,compatUtils:mb,compile:tw,computed:H,createApp:rl,createBlock:Ie,createCommentVNode:ge,createElementBlock:R,createElementVNode:Z,createHydrationRenderer:Xv,createPropsRestProxy:y_,createRenderer:Jv,createSSRApp:R3,createSlots:o_,createStaticVNode:Y_,createTextVNode:pa,createVNode:Ce,customRef:cv,defineAsyncComponent:$v,defineComponent:$e,defineCustomElement:$3,defineEmits:c_,defineExpose:d_,defineModel:p_,defineOptions:u_,defineProps:l_,defineSSRCustomElement:Rb,defineSlots:h_,devtools:db,effect:Y9,effectScope:J9,getCurrentInstance:gn,getCurrentScope:wl,getCurrentWatcher:EM,getTransitionRawChildren:Il,guardReactiveProps:h3,h:En,handleError:Ho,hasInjectionContext:$_,hydrate:Qb,hydrateOnIdle:KM,hydrateOnInteraction:YM,hydrateOnMediaQuery:XM,hydrateOnVisible:JM,initCustomFormatter:sb,initDirectivesForSSR:ew,inject:re,isMemoSame:y3,isProxy:$l,isReactive:Jr,isReadonly:to,isRef:ba,isRuntimeOnly:nb,isShallow:hn,isVNode:Sr,markRaw:iv,mergeDefaults:g_,mergeModels:jn,mergeProps:Bi,nextTick:qa,normalizeClass:ft,normalizeProps:W9,normalizeStyle:wt,onActivated:Ev,onBeforeMount:Ts,onBeforeUnmount:kr,onBeforeUpdate:i0,onDeactivated:Iv,onErrorCaptured:Vv,onMounted:ia,onRenderTracked:Lv,onRenderTriggered:Pv,onScopeDispose:Xc,onServerPrefetch:Tv,onUnmounted:Zn,onUpdated:Tl,onWatcherCleanup:uv,openBlock:$,popScopeId:NM,provide:Bv,proxyRefs:t0,pushScopeId:RM,queuePostFlushCb:Si,reactive:Ri,readonly:jt,ref:ye,registerRuntimeCompiler:ab,render:H3,renderList:Ot,renderSlot:qt,resolveComponent:r_,resolveDirective:Hv,resolveDynamicComponent:Ps,resolveFilter:fb,resolveTransitionHooks:Ms,setBlockTracking:gc,setDevtoolsHook:ub,setTransitionHooks:Ar,shallowReactive:sv,shallowReadonly:jr,shallowRef:$t,ssrContextKey:t3,ssrUtils:pb,stop:Q9,toDisplayString:je,toHandlerKey:li,toHandlers:s_,toRaw:St,toRef:mn,toRefs:a0,toValue:Pa,transformVNodeArgs:J_,triggerRef:MM,unref:E,useAttrs:v_,useCssModule:Bb,useCssVars:ji,useHost:E3,useId:Sv,useModel:lr,useSSRContext:a3,useShadowRoot:Db,useSlots:m_,useTemplateRef:pt,useTransitionState:r0,vModelCheckbox:v0,vModelDynamic:M0,vModelRadio:g0,vModelSelect:y0,vModelText:ws,vShow:Un,version:M3,warn:lb,watch:We,watchEffect:O_,watchPostEffect:H_,watchSyncEffect:n3,withAsyncContext:M_,withCtx:Xe,withDefaults:f_,withDirectives:Ya,withKeys:$r,withMemo:ib,withModifiers:sn,withScopeId:DM},Symbol.toStringTag,{value:"Module"}));/*! @license DOMPurify 3.0.9 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.9/LICENSE */const{entries:B3,setPrototypeOf:Th,isFrozen:nw,getPrototypeOf:rw,getOwnPropertyDescriptor:ow}=Object;let{freeze:Qa,seal:zn,create:F3}=Object,{apply:Sc,construct:$c}=typeof Reflect<"u"&&Reflect;Qa||(Qa=function(t){return t});zn||(zn=function(t){return t});Sc||(Sc=function(t,a,n){return t.apply(a,n)});$c||($c=function(t,a){return new t(...a)});const g1=vn(Array.prototype.forEach),Ph=vn(Array.prototype.pop),Gs=vn(Array.prototype.push),N1=vn(String.prototype.toLowerCase),O2=vn(String.prototype.toString),sw=vn(String.prototype.match),Js=vn(String.prototype.replace),iw=vn(String.prototype.indexOf),lw=vn(String.prototype.trim),Rn=vn(Object.prototype.hasOwnProperty),dn=vn(RegExp.prototype.test),Xs=cw(TypeError);function vn(e){return function(t){for(var a=arguments.length,n=new Array(a>1?a-1:0),r=1;r<a;r++)n[r-1]=arguments[r];return Sc(e,t,n)}}function cw(e){return function(){for(var t=arguments.length,a=new Array(t),n=0;n<t;n++)a[n]=arguments[n];return $c(e,a)}}function Vt(e,t){let a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:N1;Th&&Th(e,null);let n=t.length;for(;n--;){let r=t[n];if(typeof r=="string"){const o=a(r);o!==r&&(nw(t)||(t[n]=o),r=o)}e[r]=!0}return e}function dw(e){for(let t=0;t<e.length;t++)Rn(e,t)||(e[t]=null);return e}function yo(e){const t=F3(null);for(const[a,n]of B3(e))Rn(e,a)&&(Array.isArray(n)?t[a]=dw(n):n&&typeof n=="object"&&n.constructor===Object?t[a]=yo(n):t[a]=n);return t}function y1(e,t){for(;e!==null;){const n=ow(e,t);if(n){if(n.get)return vn(n.get);if(typeof n.value=="function")return vn(n.value)}e=rw(e)}function a(){return null}return a}const Lh=Qa(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),H2=Qa(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),R2=Qa(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),uw=Qa(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),N2=Qa(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),hw=Qa(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Vh=Qa(["#text"]),Oh=Qa(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),D2=Qa(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Hh=Qa(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),M1=Qa(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),pw=zn(/\{\{[\w\W]*|[\w\W]*\}\}/gm),fw=zn(/<%[\w\W]*|[\w\W]*%>/gm),mw=zn(/\${[\w\W]*}/gm),vw=zn(/^data-[\-\w.\u00B7-\uFFFF]/),gw=zn(/^aria-[\-\w]+$/),j3=zn(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),yw=zn(/^(?:\w+script|data):/i),Mw=zn(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),U3=zn(/^html$/i);var Rh=Object.freeze({__proto__:null,MUSTACHE_EXPR:pw,ERB_EXPR:fw,TMPLIT_EXPR:mw,DATA_ATTR:vw,ARIA_ATTR:gw,IS_ALLOWED_URI:j3,IS_SCRIPT_OR_DATA:yw,ATTR_WHITESPACE:Mw,DOCTYPE_NAME:U3});const _w=function(){return typeof window>"u"?null:window},bw=function(t,a){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const r="data-tt-policy-suffix";a&&a.hasAttribute(r)&&(n=a.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return t.createPolicy(o,{createHTML(s){return s},createScriptURL(s){return s}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}};function z3(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:_w();const t=qe=>z3(qe);if(t.version="3.0.9",t.removed=[],!e||!e.document||e.document.nodeType!==9)return t.isSupported=!1,t;let{document:a}=e;const n=a,r=n.currentScript,{DocumentFragment:o,HTMLTemplateElement:s,Node:i,Element:l,NodeFilter:c,NamedNodeMap:d=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:u,DOMParser:h,trustedTypes:f}=e,m=l.prototype,g=y1(m,"cloneNode"),_=y1(m,"nextSibling"),b=y1(m,"childNodes"),v=y1(m,"parentNode");if(typeof s=="function"){const qe=a.createElement("template");qe.content&&qe.content.ownerDocument&&(a=qe.content.ownerDocument)}let y,M="";const{implementation:x,createNodeIterator:S,createDocumentFragment:L,getElementsByTagName:F}=a,{importNode:te}=n;let J={};t.isSupported=typeof B3=="function"&&typeof v=="function"&&x&&x.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:be,ERB_EXPR:oe,TMPLIT_EXPR:Te,DATA_ATTR:Ue,ARIA_ATTR:Ze,IS_SCRIPT_OR_DATA:Me,ATTR_WHITESPACE:ee}=Rh;let{IS_ALLOWED_URI:j}=Rh,K=null;const G=Vt({},[...Lh,...H2,...R2,...N2,...Vh]);let T=null;const O=Vt({},[...Oh,...D2,...Hh,...M1]);let k=Object.seal(F3(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),C=null,P=null,ae=!0,xe=!0,ve=!1,ze=!0,Ye=!1,ct=!1,xt=!1,D=!1,q=!1,he=!1,me=!1,_e=!0,Ae=!1;const pe="user-content-";let ce=!0,ue=!1,I={},B=null;const N=Vt({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let U=null;const se=Vt({},["audio","video","img","source","image","track"]);let Se=null;const Ne=Vt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),ut="http://www.w3.org/1998/Math/MathML",ie="http://www.w3.org/2000/svg",Ee="http://www.w3.org/1999/xhtml";let Oe=Ee,Pe=!1,Ke=null;const it=Vt({},[ut,ie,Ee],O2);let ht=null;const Ft=["application/xhtml+xml","text/html"],ma="text/html";let Wt=null,ln=null;const Lr=a.createElement("form"),kn=function(Y){return Y instanceof RegExp||Y instanceof Function},co=function(){let Y=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(ln&&ln===Y)){if((!Y||typeof Y!="object")&&(Y={}),Y=yo(Y),ht=Ft.indexOf(Y.PARSER_MEDIA_TYPE)===-1?ma:Y.PARSER_MEDIA_TYPE,Wt=ht==="application/xhtml+xml"?O2:N1,K=Rn(Y,"ALLOWED_TAGS")?Vt({},Y.ALLOWED_TAGS,Wt):G,T=Rn(Y,"ALLOWED_ATTR")?Vt({},Y.ALLOWED_ATTR,Wt):O,Ke=Rn(Y,"ALLOWED_NAMESPACES")?Vt({},Y.ALLOWED_NAMESPACES,O2):it,Se=Rn(Y,"ADD_URI_SAFE_ATTR")?Vt(yo(Ne),Y.ADD_URI_SAFE_ATTR,Wt):Ne,U=Rn(Y,"ADD_DATA_URI_TAGS")?Vt(yo(se),Y.ADD_DATA_URI_TAGS,Wt):se,B=Rn(Y,"FORBID_CONTENTS")?Vt({},Y.FORBID_CONTENTS,Wt):N,C=Rn(Y,"FORBID_TAGS")?Vt({},Y.FORBID_TAGS,Wt):{},P=Rn(Y,"FORBID_ATTR")?Vt({},Y.FORBID_ATTR,Wt):{},I=Rn(Y,"USE_PROFILES")?Y.USE_PROFILES:!1,ae=Y.ALLOW_ARIA_ATTR!==!1,xe=Y.ALLOW_DATA_ATTR!==!1,ve=Y.ALLOW_UNKNOWN_PROTOCOLS||!1,ze=Y.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Ye=Y.SAFE_FOR_TEMPLATES||!1,ct=Y.WHOLE_DOCUMENT||!1,q=Y.RETURN_DOM||!1,he=Y.RETURN_DOM_FRAGMENT||!1,me=Y.RETURN_TRUSTED_TYPE||!1,D=Y.FORCE_BODY||!1,_e=Y.SANITIZE_DOM!==!1,Ae=Y.SANITIZE_NAMED_PROPS||!1,ce=Y.KEEP_CONTENT!==!1,ue=Y.IN_PLACE||!1,j=Y.ALLOWED_URI_REGEXP||j3,Oe=Y.NAMESPACE||Ee,k=Y.CUSTOM_ELEMENT_HANDLING||{},Y.CUSTOM_ELEMENT_HANDLING&&kn(Y.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(k.tagNameCheck=Y.CUSTOM_ELEMENT_HANDLING.tagNameCheck),Y.CUSTOM_ELEMENT_HANDLING&&kn(Y.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(k.attributeNameCheck=Y.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),Y.CUSTOM_ELEMENT_HANDLING&&typeof Y.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(k.allowCustomizedBuiltInElements=Y.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Ye&&(xe=!1),he&&(q=!0),I&&(K=Vt({},Vh),T=[],I.html===!0&&(Vt(K,Lh),Vt(T,Oh)),I.svg===!0&&(Vt(K,H2),Vt(T,D2),Vt(T,M1)),I.svgFilters===!0&&(Vt(K,R2),Vt(T,D2),Vt(T,M1)),I.mathMl===!0&&(Vt(K,N2),Vt(T,Hh),Vt(T,M1))),Y.ADD_TAGS&&(K===G&&(K=yo(K)),Vt(K,Y.ADD_TAGS,Wt)),Y.ADD_ATTR&&(T===O&&(T=yo(T)),Vt(T,Y.ADD_ATTR,Wt)),Y.ADD_URI_SAFE_ATTR&&Vt(Se,Y.ADD_URI_SAFE_ATTR,Wt),Y.FORBID_CONTENTS&&(B===N&&(B=yo(B)),Vt(B,Y.FORBID_CONTENTS,Wt)),ce&&(K["#text"]=!0),ct&&Vt(K,["html","head","body"]),K.table&&(Vt(K,["tbody"]),delete C.tbody),Y.TRUSTED_TYPES_POLICY){if(typeof Y.TRUSTED_TYPES_POLICY.createHTML!="function")throw Xs('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof Y.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Xs('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');y=Y.TRUSTED_TYPES_POLICY,M=y.createHTML("")}else y===void 0&&(y=bw(f,r)),y!==null&&typeof M=="string"&&(M=y.createHTML(""));Qa&&Qa(Y),ln=Y}},No=Vt({},["mi","mo","mn","ms","mtext"]),Do=Vt({},["foreignobject","desc","title","annotation-xml"]),Bo=Vt({},["title","style","font","a","script"]),Fo=Vt({},[...H2,...R2,...uw]),jo=Vt({},[...N2,...hw]),hr=function(Y){let Fe=v(Y);(!Fe||!Fe.tagName)&&(Fe={namespaceURI:Oe,tagName:"template"});const at=N1(Y.tagName),Gt=N1(Fe.tagName);return Ke[Y.namespaceURI]?Y.namespaceURI===ie?Fe.namespaceURI===Ee?at==="svg":Fe.namespaceURI===ut?at==="svg"&&(Gt==="annotation-xml"||No[Gt]):!!Fo[at]:Y.namespaceURI===ut?Fe.namespaceURI===Ee?at==="math":Fe.namespaceURI===ie?at==="math"&&Do[Gt]:!!jo[at]:Y.namespaceURI===Ee?Fe.namespaceURI===ie&&!Do[Gt]||Fe.namespaceURI===ut&&!No[Gt]?!1:!jo[at]&&(Bo[at]||!Fo[at]):!!(ht==="application/xhtml+xml"&&Ke[Y.namespaceURI]):!1},fe=function(Y){Gs(t.removed,{element:Y});try{Y.parentNode.removeChild(Y)}catch{Y.remove()}},Le=function(Y,Fe){try{Gs(t.removed,{attribute:Fe.getAttributeNode(Y),from:Fe})}catch{Gs(t.removed,{attribute:null,from:Fe})}if(Fe.removeAttribute(Y),Y==="is"&&!T[Y])if(q||he)try{fe(Fe)}catch{}else try{Fe.setAttribute(Y,"")}catch{}},Re=function(Y){let Fe=null,at=null;if(D)Y="<remove></remove>"+Y;else{const va=sw(Y,/^[\r\n\t ]+/);at=va&&va[0]}ht==="application/xhtml+xml"&&Oe===Ee&&(Y='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+Y+"</body></html>");const Gt=y?y.createHTML(Y):Y;if(Oe===Ee)try{Fe=new h().parseFromString(Gt,ht)}catch{}if(!Fe||!Fe.documentElement){Fe=x.createDocument(Oe,"template",null);try{Fe.documentElement.innerHTML=Pe?M:Gt}catch{}}const ha=Fe.body||Fe.documentElement;return Y&&at&&ha.insertBefore(a.createTextNode(at),ha.childNodes[0]||null),Oe===Ee?F.call(Fe,ct?"html":"body")[0]:ct?Fe.documentElement:ha},Ve=function(Y){return S.call(Y.ownerDocument||Y,Y,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT,null)},Ge=function(Y){return Y instanceof u&&(typeof Y.nodeName!="string"||typeof Y.textContent!="string"||typeof Y.removeChild!="function"||!(Y.attributes instanceof d)||typeof Y.removeAttribute!="function"||typeof Y.setAttribute!="function"||typeof Y.namespaceURI!="string"||typeof Y.insertBefore!="function"||typeof Y.hasChildNodes!="function")},dt=function(Y){return typeof i=="function"&&Y instanceof i},rt=function(Y,Fe,at){J[Y]&&g1(J[Y],Gt=>{Gt.call(t,Fe,at,ln)})},_t=function(Y){let Fe=null;if(rt("beforeSanitizeElements",Y,null),Ge(Y))return fe(Y),!0;const at=Wt(Y.nodeName);if(rt("uponSanitizeElement",Y,{tagName:at,allowedTags:K}),Y.hasChildNodes()&&!dt(Y.firstElementChild)&&dn(/<[/\w]/g,Y.innerHTML)&&dn(/<[/\w]/g,Y.textContent))return fe(Y),!0;if(!K[at]||C[at]){if(!C[at]&&Yt(at)&&(k.tagNameCheck instanceof RegExp&&dn(k.tagNameCheck,at)||k.tagNameCheck instanceof Function&&k.tagNameCheck(at)))return!1;if(ce&&!B[at]){const Gt=v(Y)||Y.parentNode,ha=b(Y)||Y.childNodes;if(ha&&Gt){const va=ha.length;for(let ya=va-1;ya>=0;--ya)Gt.insertBefore(g(ha[ya],!0),_(Y))}}return fe(Y),!0}return Y instanceof l&&!hr(Y)||(at==="noscript"||at==="noembed"||at==="noframes")&&dn(/<\/no(script|embed|frames)/i,Y.innerHTML)?(fe(Y),!0):(Ye&&Y.nodeType===3&&(Fe=Y.textContent,g1([be,oe,Te],Gt=>{Fe=Js(Fe,Gt," ")}),Y.textContent!==Fe&&(Gs(t.removed,{element:Y.cloneNode()}),Y.textContent=Fe)),rt("afterSanitizeElements",Y,null),!1)},At=function(Y,Fe,at){if(_e&&(Fe==="id"||Fe==="name")&&(at in a||at in Lr))return!1;if(!(xe&&!P[Fe]&&dn(Ue,Fe))){if(!(ae&&dn(Ze,Fe))){if(!T[Fe]||P[Fe]){if(!(Yt(Y)&&(k.tagNameCheck instanceof RegExp&&dn(k.tagNameCheck,Y)||k.tagNameCheck instanceof Function&&k.tagNameCheck(Y))&&(k.attributeNameCheck instanceof RegExp&&dn(k.attributeNameCheck,Fe)||k.attributeNameCheck instanceof Function&&k.attributeNameCheck(Fe))||Fe==="is"&&k.allowCustomizedBuiltInElements&&(k.tagNameCheck instanceof RegExp&&dn(k.tagNameCheck,at)||k.tagNameCheck instanceof Function&&k.tagNameCheck(at))))return!1}else if(!Se[Fe]){if(!dn(j,Js(at,ee,""))){if(!((Fe==="src"||Fe==="xlink:href"||Fe==="href")&&Y!=="script"&&iw(at,"data:")===0&&U[Y])){if(!(ve&&!dn(Me,Js(at,ee,"")))){if(at)return!1}}}}}}return!0},Yt=function(Y){return Y!=="annotation-xml"&&Y.indexOf("-")>0},la=function(Y){rt("beforeSanitizeAttributes",Y,null);const{attributes:Fe}=Y;if(!Fe)return;const at={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:T};let Gt=Fe.length;for(;Gt--;){const ha=Fe[Gt],{name:va,namespaceURI:ya,value:Gn}=ha,uo=Wt(va);let Ba=va==="value"?Gn:lw(Gn);if(at.attrName=uo,at.attrValue=Ba,at.keepAttr=!0,at.forceKeepAttr=void 0,rt("uponSanitizeAttribute",Y,at),Ba=at.attrValue,at.forceKeepAttr||(Le(va,Y),!at.keepAttr))continue;if(!ze&&dn(/\/>/i,Ba)){Le(va,Y);continue}Ye&&g1([be,oe,Te],Xi=>{Ba=Js(Ba,Xi," ")});const Ji=Wt(Y.nodeName);if(At(Ji,uo,Ba)){if(Ae&&(uo==="id"||uo==="name")&&(Le(va,Y),Ba=pe+Ba),y&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!ya)switch(f.getAttributeType(Ji,uo)){case"TrustedHTML":{Ba=y.createHTML(Ba);break}case"TrustedScriptURL":{Ba=y.createScriptURL(Ba);break}}try{ya?Y.setAttributeNS(ya,va,Ba):Y.setAttribute(va,Ba),Ph(t.removed)}catch{}}}rt("afterSanitizeAttributes",Y,null)},ca=function qe(Y){let Fe=null;const at=Ve(Y);for(rt("beforeSanitizeShadowDOM",Y,null);Fe=at.nextNode();)rt("uponSanitizeShadowNode",Fe,null),!_t(Fe)&&(Fe.content instanceof o&&qe(Fe.content),la(Fe));rt("afterSanitizeShadowDOM",Y,null)};return t.sanitize=function(qe){let Y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Fe=null,at=null,Gt=null,ha=null;if(Pe=!qe,Pe&&(qe="<!-->"),typeof qe!="string"&&!dt(qe))if(typeof qe.toString=="function"){if(qe=qe.toString(),typeof qe!="string")throw Xs("dirty is not a string, aborting")}else throw Xs("toString is not a function");if(!t.isSupported)return qe;if(xt||co(Y),t.removed=[],typeof qe=="string"&&(ue=!1),ue){if(qe.nodeName){const Gn=Wt(qe.nodeName);if(!K[Gn]||C[Gn])throw Xs("root node is forbidden and cannot be sanitized in-place")}}else if(qe instanceof i)Fe=Re("<!---->"),at=Fe.ownerDocument.importNode(qe,!0),at.nodeType===1&&at.nodeName==="BODY"||at.nodeName==="HTML"?Fe=at:Fe.appendChild(at);else{if(!q&&!Ye&&!ct&&qe.indexOf("<")===-1)return y&&me?y.createHTML(qe):qe;if(Fe=Re(qe),!Fe)return q?null:me?M:""}Fe&&D&&fe(Fe.firstChild);const va=Ve(ue?qe:Fe);for(;Gt=va.nextNode();)_t(Gt)||(Gt.content instanceof o&&ca(Gt.content),la(Gt));if(ue)return qe;if(q){if(he)for(ha=L.call(Fe.ownerDocument);Fe.firstChild;)ha.appendChild(Fe.firstChild);else ha=Fe;return(T.shadowroot||T.shadowrootmode)&&(ha=te.call(n,ha,!0)),ha}let ya=ct?Fe.outerHTML:Fe.innerHTML;return ct&&K["!doctype"]&&Fe.ownerDocument&&Fe.ownerDocument.doctype&&Fe.ownerDocument.doctype.name&&dn(U3,Fe.ownerDocument.doctype.name)&&(ya="<!DOCTYPE "+Fe.ownerDocument.doctype.name+`>
29
+ `+ya),Ye&&g1([be,oe,Te],Gn=>{ya=Js(ya,Gn," ")}),y&&me?y.createHTML(ya):ya},t.setConfig=function(){let qe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};co(qe),xt=!0},t.clearConfig=function(){ln=null,xt=!1},t.isValidAttribute=function(qe,Y,Fe){ln||co({});const at=Wt(qe),Gt=Wt(Y);return At(at,Gt,Fe)},t.addHook=function(qe,Y){typeof Y=="function"&&(J[qe]=J[qe]||[],Gs(J[qe],Y))},t.removeHook=function(qe){if(J[qe])return Ph(J[qe])},t.removeHooks=function(qe){J[qe]&&(J[qe]=[])},t.removeAllHooks=function(){J={}},t}var ww=z3();function xw(e,t){const a=e.hooks??{};let n;for(n in a){const r=a[n];r!==void 0&&t.addHook(n,r)}}function q3(){return ww()}function Cw(e={},t=q3){const a=t();xw(e,a);const n=function(r,o){const s=o.value;if(o.oldValue===s)return;const i=`${s}`,l=o.arg,c=e.namedConfigurations,d=e.default??{};if(c&&l!==void 0){r.innerHTML=a.sanitize(i,c[l]??d);return}r.innerHTML=a.sanitize(i,d)};return{mounted:n,updated:n}}const Aw={install(e,t={},a=q3){e.directive("dompurify-html",Cw(t,a))}};function Sw(e,t){return $w(window.sessionStorage,e,t)}function $w(e,t,a){const n=$t(r());function r(){if(!e)return;const o=e.getItem(t);if(o)try{const s=JSON.parse(o);if((a==null?void 0:a(s))===!1){e.removeItem(t);return}return s}catch{e.removeItem(t);return}}return H({get(){return n.value},set(o){n.value=o,e&&(o===void 0?e.removeItem(t):e.setItem(t,JSON.stringify(o)))}})}function fa(){return{log:console.log,warn:console.warn,info:console.info,error:console.error}}const Ew=1500,Iw=1e3,kw=100,Tw=fa();var Pw=(e=>(e[e.None=0]="None",e[e.Single=1]="Single",e[e.Multiple=2]="Multiple",e))(Pw||{});const Lw=new Set(["ui","blueprints","preview","vault","journal"]);function Vw(e){return typeof e=="string"&&Lw.has(e)}function Ow(){const e=Sw("generateBuilderManager__mode",Vw),t={mode:e.value??"preview",selection:[],mutationTransactionsSnapshot:{undo:null,redo:null},logEntries:[]},a=ye(t);let n=null,r=0;const o=[],s=j=>{l.value=j},i=()=>a.value.mode,l=H({get:()=>a.value.mode,set(j){a.value.mode=j,e.value=j}}),c=H(()=>l.value=="blueprints"?"blueprints_root":"root"),d=(j,K,G)=>{if(j===null){a.value.selection=[];return}a.value.selection.length!==0&&(a.value.selection=[]),u(j,K,G)},u=(j,K,G)=>{let T=K;if(typeof T>"u"){const O=document.querySelector(`.ComponentRenderer [data-writer-id="${j}"]`);T=O==null?void 0:O.dataset.writerInstancePath}a.value.selection=[...a.value.selection,{componentId:j,instancePath:T,source:G}]},h=(j,K,G,T)=>{if(!j.shiftKey&&!j.ctrlKey&&!j.metaKey)return d(K,G,T);f(K)?m(K):u(K,G,T)},f=j=>a.value.selection.some(K=>K.componentId===j),m=j=>{const K=a.value.selection.filter(G=>G.componentId!==j);K.length!==a.value.selection.length&&(a.value.selection=K)},g=H(()=>a.value.selection.length===0?0:a.value.selection.length===1?1:2),_=H(()=>g.value===1),b=H(()=>a.value.selection[0]),v=H(()=>{var j;return(j=a.value.selection[0])==null?void 0:j.componentId}),y=(j,K,G=!1)=>{if(n!==null)return;r<0&&(o.splice(r),r=0);const T=o[o.length-1],O=Date.now()-(T==null?void 0:T.timestamp);if(T!=null&&T.enableDebounce&&(T==null?void 0:T.id)==j&&O<Iw){n=o.pop();return}n={id:j,desc:K,timestamp:null,enableDebounce:G,mutations:{}}},M=j=>{n.mutations[j.id]||(n.mutations[j.id]={jsonPre:j?JSON.stringify(j):void 0})},x=j=>{n.mutations[j.id]||(n.mutations[j.id]={}),n.mutations[j.id].jsonPost=j?JSON.stringify(j):void 0},S=j=>{if(n.id!==j){Tw.warn("Mutation transaction mismatch.",j,n.id);return}n.timestamp=Date.now(),o.push(n),n=null,te()},L=()=>{const j=o.length-1+r,K=o[j];return K&&r--,te(),K},F=()=>{const j=o.length+r,K=o[j];return K&&r++,te(),K},te=()=>{const j=o.length-1+r,K=o[j],G=o.length+r,T=o[G];a.value.mutationTransactionsSnapshot={undo:K,redo:T}},J=()=>a.value.mutationTransactionsSnapshot;async function be(j){const K=JSON.stringify(j);let G=5981;for(let O=0;O<K.length;O++)G=(G<<5)+G+K.charCodeAt(O);return G.toString(16).padStart(2,"0")}const oe=async j=>{const{type:K,title:G,message:T,code:O,blueprintExecution:k,id:C}=j,P=await be(j);if(C){const ae=a.value.logEntries.findIndex(xe=>xe.id===C);ae!==-1&&a.value.logEntries.splice(ae,1)}else{const ae=a.value.logEntries.find(xe=>xe.fingerprint===P);if(ae){ae.repeated++,ae.timestampReceived=new Date,a.value.logEntries.sort((xe,ve)=>xe.timestampReceived<ve.timestampReceived?1:-1);return}}a.value.logEntries.unshift({id:C,type:K,title:G,message:T,code:O,blueprintExecution:k,timestampReceived:new Date,fingerprint:P,repeated:0}),a.value.logEntries.splice(kw)},Te=()=>a.value.logEntries.length,Ue=()=>{a.value.logEntries=[]},Ze=()=>a.value.logEntries,Me=H(()=>{var T,O,k;const j=Ze(),K=(O=(T=j.find(C=>!!C.blueprintExecution))==null?void 0:T.blueprintExecution)==null?void 0:O.runId;return K&&!!((k=j.filter(C=>{var P,ae;return((P=C==null?void 0:C.blueprintExecution)==null?void 0:P.runId)===K&&!((ae=C==null?void 0:C.blueprintExecution)!=null&&ae.exit)}))!=null&&k[0])?K:null});return{setMode:s,getMode:i,mode:l,activeRootId:c,openPanels:ye(new Set),isSettingsBarCollapsed:ye(!1),isComponentIdSelected:f,selectionStatus:g,isSingleSelectionActive:_,firstSelectedId:v,firstSelectedItem:b,removeSelectedComponentId:m,setSelection:d,appendSelection:u,handleSelectionFromEvent:h,selection:H(()=>a.value.selection),mutationTransactions:jt(o),openMutationTransaction:y,registerPreMutation:M,registerPostMutation:x,closeMutationTransaction:S,consumeUndoTransaction:L,consumeRedoTransaction:F,getMutationTransactionsSnapshot:J,handleLogEntry:oe,getLogEntryCount:Te,clearLogEntries:Ue,getLogEntries:Ze,activeBlueprintRunId:Me}}const ne={core:Symbol(),builderManager:Symbol(),notesManager:Symbol(),collaborationManager:Symbol(),secretsManager:Symbol(),evaluatedFields:Symbol(),componentId:Symbol(),isBeingEdited:Symbol(),isDisabled:Symbol(),getChildrenVNodes:Symbol(),renderProxiedComponent:Symbol(),instancePath:Symbol(),flattenedInstancePath:Symbol(),instanceData:Symbol(),isAutogenModalShown:Symbol(),socketTimeout:Symbol()};function W3(e){var a;const t=(a=e.split(","))==null?void 0:a[1];if(!t)throw Error(`Could not extract base64 from data url: ${e}`);return t}function Hw(e){const t=window.atob(e),a=t.length,n=new Uint8Array(a);for(let r=0;r<a;r++)n[r]=t.charCodeAt(r);return n.buffer}function Rw(e){const t=W3(e),a=atob(t),n=new ArrayBuffer(a.length),r=new Uint8Array(n);for(let o=0;o<a.length;o++)r[o]=a.charCodeAt(o);return n}var Q=(e=>(e.Text="Text",e.Binding="Binding",e.Boolean="Boolean",e.KeyValue="Key-Value",e.Color="Color",e.Shadow="Shadow",e.Number="Number",e.Object="Object",e.JSONInput="JSON",e.IdKey="Identifying Key",e.Width="Width",e.HAlign="Align (H)",e.VAlign="Align (V)",e.Padding="Padding",e.Tools="Tools",e.ComponentPicker="Component",e.Code="Code",e.Eval="Eval",e.BlueprintKey="Blueprint Key",e.BlueprintId="Blueprint Id",e.Handler="Handler",e.WriterGraphId="Graph Id",e.WriterGraphIds="Graph Ids",e.WriterAppId="App Id",e.WriterModelId="Model Id",e.ComponentId="Component Id",e.ComponentEventType="Component Event Type",e))(Q||{}),ot=(e=>(e.General="General",e.Style="Style",e.Tools="Tools",e))(ot||{}),Ui=(e=>(e.Text="Text",e.Textarea="Textarea",e))(Ui||{});const Nw={class:"WdsNumberInput__right"},Dw=$e({inheritAttrs:!1,__name:"WdsNumberInput",props:jn({step:{type:Number,default:1},class:{type:String,default:void 0}},{modelValue:{type:Number,required:!1,default:void 0},modelModifiers:{}}),emits:jn({focusout:e=>typeof e=="number"},["update:modelValue"]),setup(e,{expose:t}){const a=lr(e,"modelValue"),n=e;t({focus:s});const r=ye();function o(i){a.value=(a.value??0)+i,s()}function s(){var i;(i=r.value)==null||i.focus()}return(i,l)=>($(),R("div",{class:ft(["WdsNumberInput colorTransformer",n.class])},[Ya(Z("input",Bi({ref_key:"input",ref:r,"onUpdate:modelValue":l[0]||(l[0]=c=>a.value=c),class:"WdsNumberInput__input"},i.$attrs,{type:"number",onFocusout:l[1]||(l[1]=c=>i.$emit("focusout",a.value))}),null,16),[[ws,a.value]]),Z("div",Nw,[Z("button",{class:"WdsNumberInput__right__arrow",type:"button",onClick:l[2]||(l[2]=sn(c=>o(e.step),["prevent"])),onPointerdown:l[3]||(l[3]=sn(()=>{},["prevent"]))},l[6]||(l[6]=[Z("span",{class:"WdsNumberInput__right__arrow__up"},null,-1)]),32),Z("button",{class:"WdsNumberInput__right__arrow",type:"button",onClick:l[4]||(l[4]=sn(c=>o(-e.step),["prevent"])),onPointerdown:l[5]||(l[5]=sn(()=>{},["prevent"]))},l[7]||(l[7]=[Z("span",{class:"WdsNumberInput__right__arrow__down"},null,-1)]),32)])],2))}}),ke=(e,t)=>{const a=e.__vccOpts||e;for(const[n,r]of t)a[n]=r;return a},Bw=ke(Dw,[["__scopeId","data-v-e225ba84"]]),Fw={key:0},jw={key:1,class:"CoreDataframeCellNumber--text"},Uw=$e({__name:"CoreDataframeCellNumber",props:{value:{validator:e=>typeof e=="number"||typeof e=="bigint",required:!0},editable:{type:Boolean,required:!1}},emits:{change:e=>typeof e=="number"},setup(e,{emit:t}){const a=e,n=t;function r(o){o!==a.value&&n("change",o)}return(o,s)=>e.editable?($(),R("div",Fw,[Ce(Bw,{class:"CoreDataframeCellNumber--input","model-value":Number(e.value),onFocusout:s[0]||(s[0]=i=>r(i))},null,8,["model-value"])])):($(),R("div",jw,je(e.value),1))}}),zw=ke(Uw,[["__scopeId","data-v-0707fd0c"]]),qw={class:"markdown"},Ww=$e({__name:"BaseMarkdownRaw",props:{rawMarkdown:{type:String,required:!0}},setup(e){return(t,a)=>{const n=Hv("dompurify-html");return Ya(($(),R("div",qw,null,512)),[[n,e.rawMarkdown]])}}}),Z3=ke(Ww,[["__scopeId","data-v-2220bc7a"]]),K3=$e({__name:"BaseMarkdown",props:{rawText:{}},setup(e){let t;const a=ye(!1),n=e;return Ts(async()=>{t=await zt(()=>import("./marked.esm-273vDTCT.js"),[],import.meta.url),a.value=!0}),(r,o)=>a.value?($(),Ie(Z3,{key:0,"raw-markdown":String(E(t).parse(n.rawText)).trim(),class:"BaseMarkdown"},null,8,["raw-markdown"])):ge("",!0)}}),Zw=["aria-invalid","autofocus"],Kw=$e({__name:"WdsTextareaInput",props:jn({invalid:{type:Boolean,required:!1},autofocus:{type:Boolean}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(e,{expose:t}){const a=lr(e,"modelValue"),n=e,r=pt("input");t({focus:l,getSelection:i,value:a,ref:r,setSelectionEnd:s,setSelectionStart:o}),ia(()=>{n.autofocus&&l()});function o(c){r.value&&(r.value.selectionStart=c)}function s(c){r.value&&(r.value.selectionEnd=c)}function i(){var c,d;return{selectionStart:(c=r.value)==null?void 0:c.selectionStart,selectionEnd:(d=r.value)==null?void 0:d.selectionEnd}}function l(){var c;(c=r.value)==null||c.focus()}return(c,d)=>Ya(($(),R("textarea",{ref_key:"input",ref:r,"onUpdate:modelValue":d[0]||(d[0]=u=>a.value=u),"aria-invalid":e.invalid,autofocus:e.autofocus},null,8,Zw)),[[ws,a.value]])}}),_0=ke(Kw,[["__scopeId","data-v-2d90ab73"]]),Gw={key:2,class:"CoreDataframeCellText--text"},Jw=$e({__name:"CoreDataframeCellText",props:{value:{validator:()=>!0,required:!0},useMarkdown:{type:Boolean,required:!1},editable:{type:Boolean,required:!1},wrapText:{type:Boolean,required:!1}},emits:{change:e=>typeof e=="string"},setup(e,{emit:t}){const a=e,n=t,r=pt("textarea");function o(){r.value.value!==a.value&&n("change",r.value.value)}function s(){var h;if(!((h=r.value)!=null&&h.ref))return;const i=r.value.ref,l=getComputedStyle(i);if(!l)return;const c=parseInt(l.borderTopWidth)||0,d=parseInt(l.borderBottomWidth)||0,u=c+d;i.style.height=`${i.scrollHeight+u}px`}return We(()=>a.editable&&a.value,i=>{a.wrapText&&i&&qa(()=>s())},{immediate:!0}),(i,l)=>e.editable?($(),Ie(_0,{key:0,ref_key:"textarea",ref:r,class:"CoreDataframeCellText--textarea",rows:"1","model-value":String(e.value),onFocusout:o},null,8,["model-value"])):e.useMarkdown?($(),Ie(K3,{key:1,"raw-text":String(e.value)},null,8,["raw-text"])):($(),R("div",Gw,[Z("p",{class:ft({"CoreDataframeCellText__content--noWrap":!e.wrapText})},je(e.value),3)]))}}),Xw=ke(Jw,[["__scopeId","data-v-a47ac113"]]),Yw=["checked","readonly","tabindex"],Qw=$e({__name:"CoreDataframeCellBoolean",props:{value:{type:Boolean,required:!0},editable:{type:Boolean,required:!1}},emits:{change:e=>typeof e=="boolean"},setup(e,{emit:t}){const a=e,n=t;function r(o){if(!a.editable){o.preventDefault(),o.stopPropagation();return}n("change",o.target.checked)}return(o,s)=>($(),R("div",{class:ft(["CoreDataframeCellBoolean",{"CoreDataframeCellBoolean--disabled":!e.editable}])},[Z("input",{type:"checkbox",checked:e.value,readonly:!e.editable,tabindex:e.editable?0:-1,onChange:r},null,40,Yw)],2))}}),ex=ke(Qw,[["__scopeId","data-v-2d30bc74"]]);function G3(e,t){return typeof t=="bigint"?t.toString()+"n":t}const tx={class:"CoreDataframeCellUnknown"},ax=$e({__name:"CoreDataframeCellUnknown",props:{value:{validator:()=>!0,required:!0},wrapText:{type:Boolean,required:!1}},setup(e){const t=e,a=H(()=>JSON.stringify(t.value,G3));return(n,r)=>($(),R("div",tx,[Z("p",{class:ft({"CoreDataframeCellUnknown__content--noWrap":!e.wrapText})},je(a.value),3)]))}}),nx=ke(ax,[["__scopeId","data-v-06d2511b"]]),rx=$e({__name:"CoreDataframeCell",props:{value:{validator:()=>!0,required:!0},useMarkdown:{type:Boolean,required:!1},editable:{type:Boolean,required:!1},wrapText:{type:Boolean,required:!1}},emits:{change:e=>e!==void 0},setup(e){const t=e,a=H(()=>{switch(typeof t.value){case"number":case"bigint":return zw;case"boolean":return ex;case"string":return Xw;default:return nx}});return(n,r)=>($(),Ie(Ps(a.value),{value:e.value,"use-markdown":e.useMarkdown,editable:e.editable,"wrap-text":e.wrapText,onChange:r[0]||(r[0]=o=>n.$emit("change",o))},null,40,["value","use-markdown","editable","wrap-text"]))}}),xn="__internal_arquero_id",ox="data:application/vnd.apache.arrow.file;base64,QVJST1cxAAD/////iAMAABAAAAAAAAoADgAGAAUACAAKAAAAAAEEABAAAAAAAAoADAAAAAQACAAKAAAAlAIAAAQAAAABAAAADAAAAAgADAAEAAgACAAAAGwCAAAEAAAAXwIAAHsiaW5kZXhfY29sdW1ucyI6IFsiX19pbmRleF9sZXZlbF8wX18iXSwgImNvbHVtbl9pbmRleGVzIjogW3sibmFtZSI6IG51bGwsICJmaWVsZF9uYW1lIjogbnVsbCwgInBhbmRhc190eXBlIjogInVuaWNvZGUiLCAibnVtcHlfdHlwZSI6ICJvYmplY3QiLCAibWV0YWRhdGEiOiB7ImVuY29kaW5nIjogIlVURi04In19XSwgImNvbHVtbnMiOiBbeyJuYW1lIjogImNvbF9hIiwgImZpZWxkX25hbWUiOiAiY29sX2EiLCAicGFuZGFzX3R5cGUiOiAiaW50NjQiLCAibnVtcHlfdHlwZSI6ICJpbnQ2NCIsICJtZXRhZGF0YSI6IG51bGx9LCB7Im5hbWUiOiAiY29sX2IiLCAiZmllbGRfbmFtZSI6ICJjb2xfYiIsICJwYW5kYXNfdHlwZSI6ICJpbnQ2NCIsICJudW1weV90eXBlIjogImludDY0IiwgIm1ldGFkYXRhIjogbnVsbH0sIHsibmFtZSI6IG51bGwsICJmaWVsZF9uYW1lIjogIl9faW5kZXhfbGV2ZWxfMF9fIiwgInBhbmRhc190eXBlIjogImludDY0IiwgIm51bXB5X3R5cGUiOiAiaW50NjQiLCAibWV0YWRhdGEiOiBudWxsfV0sICJjcmVhdG9yIjogeyJsaWJyYXJ5IjogInB5YXJyb3ciLCAidmVyc2lvbiI6ICIxMi4wLjAifSwgInBhbmRhc192ZXJzaW9uIjogIjEuNS4zIn0ABgAAAHBhbmRhcwAAAwAAAIgAAABEAAAABAAAAJT///8AAAECEAAAACQAAAAEAAAAAAAAABEAAABfX2luZGV4X2xldmVsXzBfXwAAAJD///8AAAABQAAAAND///8AAAECEAAAABgAAAAEAAAAAAAAAAUAAABjb2xfYgAAAMD///8AAAABQAAAABAAFAAIAAYABwAMAAAAEAAQAAAAAAABAhAAAAAgAAAABAAAAAAAAAAFAAAAY29sX2EAAAAIAAwACAAHAAgAAAAAAAABQAAAAAAAAAD/////6AAAABQAAAAAAAAADAAWAAYABQAIAAwADAAAAAADBAAYAAAAMAAAAAAAAAAAAAoAGAAMAAQACAAKAAAAfAAAABAAAAACAAAAAAAAAAAAAAAGAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAACAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAABAAAAAAAAAAAAAAAAMAAAACAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAIAAAAAAAAAAwAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAD/////AAAAABAAAAAMABQABgAIAAwAEAAMAAAAAAAEADwAAAAoAAAABAAAAAEAAACYAwAAAAAAAPAAAAAAAAAAMAAAAAAAAAAAAAAAAAAAAAAACgAMAAAABAAIAAoAAACUAgAABAAAAAEAAAAMAAAACAAMAAQACAAIAAAAbAIAAAQAAABfAgAAeyJpbmRleF9jb2x1bW5zIjogWyJfX2luZGV4X2xldmVsXzBfXyJdLCAiY29sdW1uX2luZGV4ZXMiOiBbeyJuYW1lIjogbnVsbCwgImZpZWxkX25hbWUiOiBudWxsLCAicGFuZGFzX3R5cGUiOiAidW5pY29kZSIsICJudW1weV90eXBlIjogIm9iamVjdCIsICJtZXRhZGF0YSI6IHsiZW5jb2RpbmciOiAiVVRGLTgifX1dLCAiY29sdW1ucyI6IFt7Im5hbWUiOiAiY29sX2EiLCAiZmllbGRfbmFtZSI6ICJjb2xfYSIsICJwYW5kYXNfdHlwZSI6ICJpbnQ2NCIsICJudW1weV90eXBlIjogImludDY0IiwgIm1ldGFkYXRhIjogbnVsbH0sIHsibmFtZSI6ICJjb2xfYiIsICJmaWVsZF9uYW1lIjogImNvbF9iIiwgInBhbmRhc190eXBlIjogImludDY0IiwgIm51bXB5X3R5cGUiOiAiaW50NjQiLCAibWV0YWRhdGEiOiBudWxsfSwgeyJuYW1lIjogbnVsbCwgImZpZWxkX25hbWUiOiAiX19pbmRleF9sZXZlbF8wX18iLCAicGFuZGFzX3R5cGUiOiAiaW50NjQiLCAibnVtcHlfdHlwZSI6ICJpbnQ2NCIsICJtZXRhZGF0YSI6IG51bGx9XSwgImNyZWF0b3IiOiB7ImxpYnJhcnkiOiAicHlhcnJvdyIsICJ2ZXJzaW9uIjogIjEyLjAuMCJ9LCAicGFuZGFzX3ZlcnNpb24iOiAiMS41LjMifQAGAAAAcGFuZGFzAAADAAAAiAAAAEQAAAAEAAAAlP///wAAAQIQAAAAJAAAAAQAAAAAAAAAEQAAAF9faW5kZXhfbGV2ZWxfMF9fAAAAkP///wAAAAFAAAAA0P///wAAAQIQAAAAGAAAAAQAAAAAAAAABQAAAGNvbF9iAAAAwP///wAAAAFAAAAAEAAUAAgABgAHAAwAAAAQABAAAAAAAAECEAAAACAAAAAEAAAAAAAAAAUAAABjb2xfYQAAAAgADAAIAAcACAAAAAAAAAFAAAAAsAMAAEFSUk9XMQ==",J3=/^__index_level_[0-9]+__$/;function b0(e){const t=ye(!1),a=new AbortController;function n(){t.value=!0}function r(o){const s=o.currentTarget;document.hasFocus()?s.contains(o.relatedTarget)||(t.value=!1):window.addEventListener("focus",function i(){window.removeEventListener("focus",i),s.isConnected&&!s.contains(document.activeElement)&&(t.value=!1)},{signal:a.signal})}return We(e,(o,s)=>{s&&(s.removeEventListener("focusin",n),s.removeEventListener("focusout",r)),e!=null&&e.value&&(e.value.addEventListener("focusin",n,{signal:a.signal}),e.value.addEventListener("focusout",r,{signal:a.signal}))}),kr(()=>{a.abort()}),jt(t)}const sx=["top","right","bottom","left"],Nh=["start","end"],Dh=sx.reduce((e,t)=>e.concat(t,t+"-"+Nh[0],t+"-"+Nh[1]),[]),Cs=Math.min,un=Math.max,ol=Math.round,_1=Math.floor,ar=e=>({x:e,y:e}),ix={left:"right",right:"left",bottom:"top",top:"bottom"},lx={start:"end",end:"start"};function Bh(e,t,a){return un(e,Cs(t,a))}function Ls(e,t){return typeof e=="function"?e(t):e}function or(e){return e.split("-")[0]}function nr(e){return e.split("-")[1]}function X3(e){return e==="x"?"y":"x"}function Y3(e){return e==="y"?"height":"width"}function To(e){return["top","bottom"].includes(or(e))?"y":"x"}function Q3(e){return X3(To(e))}function e6(e,t,a){a===void 0&&(a=!1);const n=nr(e),r=Q3(e),o=Y3(r);let s=r==="x"?n===(a?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=il(s)),[s,il(s)]}function cx(e){const t=il(e);return[sl(e),t,sl(t)]}function sl(e){return e.replace(/start|end/g,t=>lx[t])}function dx(e,t,a){const n=["left","right"],r=["right","left"],o=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return a?t?r:n:t?n:r;case"left":case"right":return t?o:s;default:return[]}}function ux(e,t,a,n){const r=nr(e);let o=dx(or(e),a==="start",n);return r&&(o=o.map(s=>s+"-"+r),t&&(o=o.concat(o.map(sl)))),o}function il(e){return e.replace(/left|right|bottom|top/g,t=>ix[t])}function hx(e){return{top:0,right:0,bottom:0,left:0,...e}}function px(e){return typeof e!="number"?hx(e):{top:e,right:e,bottom:e,left:e}}function ll(e){const{x:t,y:a,width:n,height:r}=e;return{width:n,height:r,top:a,left:t,right:t+n,bottom:a+r,x:t,y:a}}function Fh(e,t,a){let{reference:n,floating:r}=e;const o=To(t),s=Q3(t),i=Y3(s),l=or(t),c=o==="y",d=n.x+n.width/2-r.width/2,u=n.y+n.height/2-r.height/2,h=n[i]/2-r[i]/2;let f;switch(l){case"top":f={x:d,y:n.y-r.height};break;case"bottom":f={x:d,y:n.y+n.height};break;case"right":f={x:n.x+n.width,y:u};break;case"left":f={x:n.x-r.width,y:u};break;default:f={x:n.x,y:n.y}}switch(nr(t)){case"start":f[s]-=h*(a&&c?-1:1);break;case"end":f[s]+=h*(a&&c?-1:1);break}return f}const fx=async(e,t,a)=>{const{placement:n="bottom",strategy:r="absolute",middleware:o=[],platform:s}=a,i=o.filter(Boolean),l=await(s.isRTL==null?void 0:s.isRTL(t));let c=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:d,y:u}=Fh(c,n,l),h=n,f={},m=0;for(let g=0;g<i.length;g++){const{name:_,fn:b}=i[g],{x:v,y,data:M,reset:x}=await b({x:d,y:u,initialPlacement:n,placement:h,strategy:r,middlewareData:f,rects:c,platform:s,elements:{reference:e,floating:t}});d=v??d,u=y??u,f={...f,[_]:{...f[_],...M}},x&&m<=50&&(m++,typeof x=="object"&&(x.placement&&(h=x.placement),x.rects&&(c=x.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:r}):x.rects),{x:d,y:u}=Fh(c,h,l)),g=-1)}return{x:d,y:u,placement:h,strategy:r,middlewareData:f}};async function Ol(e,t){var a;t===void 0&&(t={});const{x:n,y:r,platform:o,rects:s,elements:i,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:h=!1,padding:f=0}=Ls(t,e),m=px(f),_=i[h?u==="floating"?"reference":"floating":u],b=ll(await o.getClippingRect({element:(a=await(o.isElement==null?void 0:o.isElement(_)))==null||a?_:_.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(i.floating)),boundary:c,rootBoundary:d,strategy:l})),v=u==="floating"?{x:n,y:r,width:s.floating.width,height:s.floating.height}:s.reference,y=await(o.getOffsetParent==null?void 0:o.getOffsetParent(i.floating)),M=await(o.isElement==null?void 0:o.isElement(y))?await(o.getScale==null?void 0:o.getScale(y))||{x:1,y:1}:{x:1,y:1},x=ll(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:v,offsetParent:y,strategy:l}):v);return{top:(b.top-x.top+m.top)/M.y,bottom:(x.bottom-b.bottom+m.bottom)/M.y,left:(b.left-x.left+m.left)/M.x,right:(x.right-b.right+m.right)/M.x}}function mx(e,t,a){return(e?[...a.filter(r=>nr(r)===e),...a.filter(r=>nr(r)!==e)]:a.filter(r=>or(r)===r)).filter(r=>e?nr(r)===e||(t?sl(r)!==r:!1):!0)}const vx=function(e){return e===void 0&&(e={}),{name:"autoPlacement",options:e,async fn(t){var a,n,r;const{rects:o,middlewareData:s,placement:i,platform:l,elements:c}=t,{crossAxis:d=!1,alignment:u,allowedPlacements:h=Dh,autoAlignment:f=!0,...m}=Ls(e,t),g=u!==void 0||h===Dh?mx(u||null,f,h):h,_=await Ol(t,m),b=((a=s.autoPlacement)==null?void 0:a.index)||0,v=g[b];if(v==null)return{};const y=e6(v,o,await(l.isRTL==null?void 0:l.isRTL(c.floating)));if(i!==v)return{reset:{placement:g[0]}};const M=[_[or(v)],_[y[0]],_[y[1]]],x=[...((n=s.autoPlacement)==null?void 0:n.overflows)||[],{placement:v,overflows:M}],S=g[b+1];if(S)return{data:{index:b+1,overflows:x},reset:{placement:S}};const L=x.map(J=>{const be=nr(J.placement);return[J.placement,be&&d?J.overflows.slice(0,2).reduce((oe,Te)=>oe+Te,0):J.overflows[0],J.overflows]}).sort((J,be)=>J[1]-be[1]),te=((r=L.filter(J=>J[2].slice(0,nr(J[0])?2:3).every(be=>be<=0))[0])==null?void 0:r[0])||L[0][0];return te!==i?{data:{index:b+1,overflows:x},reset:{placement:te}}:{}}}},gx=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var a,n;const{placement:r,middlewareData:o,rects:s,initialPlacement:i,platform:l,elements:c}=t,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:h,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:g=!0,..._}=Ls(e,t);if((a=o.arrow)!=null&&a.alignmentOffset)return{};const b=or(r),v=To(i),y=or(i)===i,M=await(l.isRTL==null?void 0:l.isRTL(c.floating)),x=h||(y||!g?[il(i)]:cx(i)),S=m!=="none";!h&&S&&x.push(...ux(i,g,m,M));const L=[i,...x],F=await Ol(t,_),te=[];let J=((n=o.flip)==null?void 0:n.overflows)||[];if(d&&te.push(F[b]),u){const Ue=e6(r,s,M);te.push(F[Ue[0]],F[Ue[1]])}if(J=[...J,{placement:r,overflows:te}],!te.every(Ue=>Ue<=0)){var be,oe;const Ue=(((be=o.flip)==null?void 0:be.index)||0)+1,Ze=L[Ue];if(Ze)return{data:{index:Ue,overflows:J},reset:{placement:Ze}};let Me=(oe=J.filter(ee=>ee.overflows[0]<=0).sort((ee,j)=>ee.overflows[1]-j.overflows[1])[0])==null?void 0:oe.placement;if(!Me)switch(f){case"bestFit":{var Te;const ee=(Te=J.filter(j=>{if(S){const K=To(j.placement);return K===v||K==="y"}return!0}).map(j=>[j.placement,j.overflows.filter(K=>K>0).reduce((K,G)=>K+G,0)]).sort((j,K)=>j[1]-K[1])[0])==null?void 0:Te[0];ee&&(Me=ee);break}case"initialPlacement":Me=i;break}if(r!==Me)return{reset:{placement:Me}}}return{}}}};async function yx(e,t){const{placement:a,platform:n,elements:r}=e,o=await(n.isRTL==null?void 0:n.isRTL(r.floating)),s=or(a),i=nr(a),l=To(a)==="y",c=["left","top"].includes(s)?-1:1,d=o&&l?-1:1,u=Ls(t,e);let{mainAxis:h,crossAxis:f,alignmentAxis:m}=typeof u=="number"?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return i&&typeof m=="number"&&(f=i==="end"?m*-1:m),l?{x:f*d,y:h*c}:{x:h*c,y:f*d}}const Mx=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var a,n;const{x:r,y:o,placement:s,middlewareData:i}=t,l=await yx(t,e);return s===((a=i.offset)==null?void 0:a.placement)&&(n=i.arrow)!=null&&n.alignmentOffset?{}:{x:r+l.x,y:o+l.y,data:{...l,placement:s}}}}},_x=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:a,y:n,placement:r}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:i={fn:_=>{let{x:b,y:v}=_;return{x:b,y:v}}},...l}=Ls(e,t),c={x:a,y:n},d=await Ol(t,l),u=To(or(r)),h=X3(u);let f=c[h],m=c[u];if(o){const _=h==="y"?"top":"left",b=h==="y"?"bottom":"right",v=f+d[_],y=f-d[b];f=Bh(v,f,y)}if(s){const _=u==="y"?"top":"left",b=u==="y"?"bottom":"right",v=m+d[_],y=m-d[b];m=Bh(v,m,y)}const g=i.fn({...t,[h]:f,[u]:m});return{...g,data:{x:g.x-a,y:g.y-n,enabled:{[h]:o,[u]:s}}}}}},bx=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var a,n;const{placement:r,rects:o,platform:s,elements:i}=t,{apply:l=()=>{},...c}=Ls(e,t),d=await Ol(t,c),u=or(r),h=nr(r),f=To(r)==="y",{width:m,height:g}=o.floating;let _,b;u==="top"||u==="bottom"?(_=u,b=h===(await(s.isRTL==null?void 0:s.isRTL(i.floating))?"start":"end")?"left":"right"):(b=u,_=h==="end"?"top":"bottom");const v=g-d.top-d.bottom,y=m-d.left-d.right,M=Cs(g-d[_],v),x=Cs(m-d[b],y),S=!t.middlewareData.shift;let L=M,F=x;if((a=t.middlewareData.shift)!=null&&a.enabled.x&&(F=y),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(L=v),S&&!h){const J=un(d.left,0),be=un(d.right,0),oe=un(d.top,0),Te=un(d.bottom,0);f?F=m-2*(J!==0||be!==0?J+be:un(d.left,d.right)):L=g-2*(oe!==0||Te!==0?oe+Te:un(d.top,d.bottom))}await l({...t,availableWidth:F,availableHeight:L});const te=await s.getDimensions(i.floating);return m!==te.width||g!==te.height?{reset:{rects:!0}}:{}}}};function Hl(){return typeof window<"u"}function Ro(e){return w0(e)?(e.nodeName||"").toLowerCase():"#document"}function pn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function cr(e){var t;return(t=(w0(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function w0(e){return Hl()?e instanceof Node||e instanceof pn(e).Node:!1}function qn(e){return Hl()?e instanceof Element||e instanceof pn(e).Element:!1}function sr(e){return Hl()?e instanceof HTMLElement||e instanceof pn(e).HTMLElement:!1}function jh(e){return!Hl()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof pn(e).ShadowRoot}function zi(e){const{overflow:t,overflowX:a,overflowY:n,display:r}=Wn(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+a)&&!["inline","contents"].includes(r)}function wx(e){return["table","td","th"].includes(Ro(e))}function Rl(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function x0(e){const t=C0(),a=qn(e)?Wn(e):e;return a.transform!=="none"||a.perspective!=="none"||(a.containerType?a.containerType!=="normal":!1)||!t&&(a.backdropFilter?a.backdropFilter!=="none":!1)||!t&&(a.filter?a.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(a.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(a.contain||"").includes(n))}function xx(e){let t=no(e);for(;sr(t)&&!As(t);){if(x0(t))return t;if(Rl(t))return null;t=no(t)}return null}function C0(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function As(e){return["html","body","#document"].includes(Ro(e))}function Wn(e){return pn(e).getComputedStyle(e)}function Nl(e){return qn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function no(e){if(Ro(e)==="html")return e;const t=e.assignedSlot||e.parentNode||jh(e)&&e.host||cr(e);return jh(t)?t.host:t}function t6(e){const t=no(e);return As(t)?e.ownerDocument?e.ownerDocument.body:e.body:sr(t)&&zi(t)?t:t6(t)}function Pi(e,t,a){var n;t===void 0&&(t=[]),a===void 0&&(a=!0);const r=t6(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=pn(r);if(o){const i=Ec(s);return t.concat(s,s.visualViewport||[],zi(r)?r:[],i&&a?Pi(i):[])}return t.concat(r,Pi(r,[],a))}function Ec(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function a6(e){const t=Wn(e);let a=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const r=sr(e),o=r?e.offsetWidth:a,s=r?e.offsetHeight:n,i=ol(a)!==o||ol(n)!==s;return i&&(a=o,n=s),{width:a,height:n,$:i}}function A0(e){return qn(e)?e:e.contextElement}function vs(e){const t=A0(e);if(!sr(t))return ar(1);const a=t.getBoundingClientRect(),{width:n,height:r,$:o}=a6(t);let s=(o?ol(a.width):a.width)/n,i=(o?ol(a.height):a.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!i||!Number.isFinite(i))&&(i=1),{x:s,y:i}}const Cx=ar(0);function n6(e){const t=pn(e);return!C0()||!t.visualViewport?Cx:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Ax(e,t,a){return t===void 0&&(t=!1),!a||t&&a!==pn(e)?!1:t}function Po(e,t,a,n){t===void 0&&(t=!1),a===void 0&&(a=!1);const r=e.getBoundingClientRect(),o=A0(e);let s=ar(1);t&&(n?qn(n)&&(s=vs(n)):s=vs(e));const i=Ax(o,a,n)?n6(o):ar(0);let l=(r.left+i.x)/s.x,c=(r.top+i.y)/s.y,d=r.width/s.x,u=r.height/s.y;if(o){const h=pn(o),f=n&&qn(n)?pn(n):n;let m=h,g=Ec(m);for(;g&&n&&f!==m;){const _=vs(g),b=g.getBoundingClientRect(),v=Wn(g),y=b.left+(g.clientLeft+parseFloat(v.paddingLeft))*_.x,M=b.top+(g.clientTop+parseFloat(v.paddingTop))*_.y;l*=_.x,c*=_.y,d*=_.x,u*=_.y,l+=y,c+=M,m=pn(g),g=Ec(m)}}return ll({width:d,height:u,x:l,y:c})}function S0(e,t){const a=Nl(e).scrollLeft;return t?t.left+a:Po(cr(e)).left+a}function r6(e,t,a){a===void 0&&(a=!1);const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-(a?0:S0(e,n)),o=n.top+t.scrollTop;return{x:r,y:o}}function Sx(e){let{elements:t,rect:a,offsetParent:n,strategy:r}=e;const o=r==="fixed",s=cr(n),i=t?Rl(t.floating):!1;if(n===s||i&&o)return a;let l={scrollLeft:0,scrollTop:0},c=ar(1);const d=ar(0),u=sr(n);if((u||!u&&!o)&&((Ro(n)!=="body"||zi(s))&&(l=Nl(n)),sr(n))){const f=Po(n);c=vs(n),d.x=f.x+n.clientLeft,d.y=f.y+n.clientTop}const h=s&&!u&&!o?r6(s,l,!0):ar(0);return{width:a.width*c.x,height:a.height*c.y,x:a.x*c.x-l.scrollLeft*c.x+d.x+h.x,y:a.y*c.y-l.scrollTop*c.y+d.y+h.y}}function $x(e){return Array.from(e.getClientRects())}function Ex(e){const t=cr(e),a=Nl(e),n=e.ownerDocument.body,r=un(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),o=un(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let s=-a.scrollLeft+S0(e);const i=-a.scrollTop;return Wn(n).direction==="rtl"&&(s+=un(t.clientWidth,n.clientWidth)-r),{width:r,height:o,x:s,y:i}}function Ix(e,t){const a=pn(e),n=cr(e),r=a.visualViewport;let o=n.clientWidth,s=n.clientHeight,i=0,l=0;if(r){o=r.width,s=r.height;const c=C0();(!c||c&&t==="fixed")&&(i=r.offsetLeft,l=r.offsetTop)}return{width:o,height:s,x:i,y:l}}function kx(e,t){const a=Po(e,!0,t==="fixed"),n=a.top+e.clientTop,r=a.left+e.clientLeft,o=sr(e)?vs(e):ar(1),s=e.clientWidth*o.x,i=e.clientHeight*o.y,l=r*o.x,c=n*o.y;return{width:s,height:i,x:l,y:c}}function Uh(e,t,a){let n;if(t==="viewport")n=Ix(e,a);else if(t==="document")n=Ex(cr(e));else if(qn(t))n=kx(t,a);else{const r=n6(e);n={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return ll(n)}function o6(e,t){const a=no(e);return a===t||!qn(a)||As(a)?!1:Wn(a).position==="fixed"||o6(a,t)}function Tx(e,t){const a=t.get(e);if(a)return a;let n=Pi(e,[],!1).filter(i=>qn(i)&&Ro(i)!=="body"),r=null;const o=Wn(e).position==="fixed";let s=o?no(e):e;for(;qn(s)&&!As(s);){const i=Wn(s),l=x0(s);!l&&i.position==="fixed"&&(r=null),(o?!l&&!r:!l&&i.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||zi(s)&&!l&&o6(e,s))?n=n.filter(d=>d!==s):r=i,s=no(s)}return t.set(e,n),n}function Px(e){let{element:t,boundary:a,rootBoundary:n,strategy:r}=e;const s=[...a==="clippingAncestors"?Rl(t)?[]:Tx(t,this._c):[].concat(a),n],i=s[0],l=s.reduce((c,d)=>{const u=Uh(t,d,r);return c.top=un(u.top,c.top),c.right=Cs(u.right,c.right),c.bottom=Cs(u.bottom,c.bottom),c.left=un(u.left,c.left),c},Uh(t,i,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Lx(e){const{width:t,height:a}=a6(e);return{width:t,height:a}}function Vx(e,t,a){const n=sr(t),r=cr(t),o=a==="fixed",s=Po(e,!0,o,t);let i={scrollLeft:0,scrollTop:0};const l=ar(0);if(n||!n&&!o)if((Ro(t)!=="body"||zi(r))&&(i=Nl(t)),n){const h=Po(t,!0,o,t);l.x=h.x+t.clientLeft,l.y=h.y+t.clientTop}else r&&(l.x=S0(r));const c=r&&!n&&!o?r6(r,i):ar(0),d=s.left+i.scrollLeft-l.x-c.x,u=s.top+i.scrollTop-l.y-c.y;return{x:d,y:u,width:s.width,height:s.height}}function B2(e){return Wn(e).position==="static"}function zh(e,t){if(!sr(e)||Wn(e).position==="fixed")return null;if(t)return t(e);let a=e.offsetParent;return cr(e)===a&&(a=a.ownerDocument.body),a}function s6(e,t){const a=pn(e);if(Rl(e))return a;if(!sr(e)){let r=no(e);for(;r&&!As(r);){if(qn(r)&&!B2(r))return r;r=no(r)}return a}let n=zh(e,t);for(;n&&wx(n)&&B2(n);)n=zh(n,t);return n&&As(n)&&B2(n)&&!x0(n)?a:n||xx(e)||a}const Ox=async function(e){const t=this.getOffsetParent||s6,a=this.getDimensions,n=await a(e.floating);return{reference:Vx(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Hx(e){return Wn(e).direction==="rtl"}const Rx={convertOffsetParentRelativeRectToViewportRelativeRect:Sx,getDocumentElement:cr,getClippingRect:Px,getOffsetParent:s6,getElementRects:Ox,getClientRects:$x,getDimensions:Lx,getScale:vs,isElement:qn,isRTL:Hx};function Nx(e,t){let a=null,n;const r=cr(e);function o(){var i;clearTimeout(n),(i=a)==null||i.disconnect(),a=null}function s(i,l){i===void 0&&(i=!1),l===void 0&&(l=1),o();const{left:c,top:d,width:u,height:h}=e.getBoundingClientRect();if(i||t(),!u||!h)return;const f=_1(d),m=_1(r.clientWidth-(c+u)),g=_1(r.clientHeight-(d+h)),_=_1(c),v={rootMargin:-f+"px "+-m+"px "+-g+"px "+-_+"px",threshold:un(0,Cs(1,l))||1};let y=!0;function M(x){const S=x[0].intersectionRatio;if(S!==l){if(!y)return s();S?s(!1,S):n=setTimeout(()=>{s(!1,1e-7)},1e3)}y=!1}try{a=new IntersectionObserver(M,{...v,root:r.ownerDocument})}catch{a=new IntersectionObserver(M,v)}a.observe(e)}return s(!0),o}function kde(e,t,a,n){n===void 0&&(n={});const{ancestorScroll:r=!0,ancestorResize:o=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=A0(e),d=r||o?[...c?Pi(c):[],...Pi(t)]:[];d.forEach(b=>{r&&b.addEventListener("scroll",a,{passive:!0}),o&&b.addEventListener("resize",a)});const u=c&&i?Nx(c,a):null;let h=-1,f=null;s&&(f=new ResizeObserver(b=>{let[v]=b;v&&v.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var y;(y=f)==null||y.observe(t)})),a()}),c&&!l&&f.observe(c),f.observe(t));let m,g=l?Po(e):null;l&&_();function _(){const b=Po(e);g&&(b.x!==g.x||b.y!==g.y||b.width!==g.width||b.height!==g.height)&&a(),g=b,m=requestAnimationFrame(_)}return a(),()=>{var b;d.forEach(v=>{r&&v.removeEventListener("scroll",a),o&&v.removeEventListener("resize",a)}),u==null||u(),(b=f)==null||b.disconnect(),f=null,l&&cancelAnimationFrame(m)}}const Dx=Mx,i6=vx,Bx=_x,Tde=gx,Pde=bx,Fx=(e,t,a)=>{const n=new Map,r={platform:Rx,...a},o={...r.platform,_c:n};return fx(e,t,{...r,platform:o})};function jx(e){return e!=null&&typeof e=="object"&&"$el"in e}function qh(e){if(jx(e)){const t=e.$el;return w0(t)&&Ro(t)==="#comment"?null:t}return e}function Ys(e){return typeof e=="function"?e():E(e)}function l6(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Wh(e,t){const a=l6(e);return Math.round(t*a)/a}function c6(e,t,a){a===void 0&&(a={});const n=a.whileElementsMounted,r=H(()=>{var L;return(L=Ys(a.open))!=null?L:!0}),o=H(()=>Ys(a.middleware)),s=H(()=>{var L;return(L=Ys(a.placement))!=null?L:"bottom"}),i=H(()=>{var L;return(L=Ys(a.strategy))!=null?L:"absolute"}),l=H(()=>{var L;return(L=Ys(a.transform))!=null?L:!0}),c=H(()=>qh(e.value)),d=H(()=>qh(t.value)),u=ye(0),h=ye(0),f=ye(i.value),m=ye(s.value),g=$t({}),_=ye(!1),b=H(()=>{const L={position:f.value,left:"0",top:"0"};if(!d.value)return L;const F=Wh(d.value,u.value),te=Wh(d.value,h.value);return l.value?{...L,transform:"translate("+F+"px, "+te+"px)",...l6(d.value)>=1.5&&{willChange:"transform"}}:{position:f.value,left:F+"px",top:te+"px"}});let v;function y(){if(c.value==null||d.value==null)return;const L=r.value;Fx(c.value,d.value,{middleware:o.value,placement:s.value,strategy:i.value}).then(F=>{u.value=F.x,h.value=F.y,f.value=F.strategy,m.value=F.placement,g.value=F.middlewareData,_.value=L!==!1})}function M(){typeof v=="function"&&(v(),v=void 0)}function x(){if(M(),n===void 0){y();return}if(c.value!=null&&d.value!=null){v=n(c.value,d.value,y);return}}function S(){r.value||(_.value=!1)}return We([o,s,i,r],y,{flush:"sync"}),We([c,d],x,{flush:"sync"}),We(r,S,{flush:"sync"}),wl()&&Xc(M),{x:jr(u),y:jr(h),strategy:jr(f),placement:jr(m),middlewareData:jr(g),isPositioned:jr(_),floatingStyles:b,update:y}}const Ux={},zx={class:"WdsSkeletonLoader","aria-busy":"true"};function qx(e,t){return $(),R("div",zx)}const $0=ke(Ux,[["render",qx],["__scopeId","data-v-16706a43"]]);function Wx(){return En("div",{style:{display:"flex",alignItems:"center",justifyContent:"center"}},En("p",{style:{background:"var(--wdsColorOrange2)",padding:"8px",borderRadius:"4px"}},"Could not load the component"))}function Zx(e){return En("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",height:e.height??"100%",width:e.width??"100%",padding:"8px"}},En($0))}const F2=5;function ir(e){return $v({loadingComponent:()=>Zx(e.loadingComponentProps??{}),errorComponent:Wx,delay:300,onError(t,a,n,r){const o=fa();if(r<=F2){const s=`Failed to load async component (retry ${r}/${F2})`;o.warn(s,t),setTimeout(a,1e3)}else{const s=`Failed to load async component after ${F2} attempts`;o.error(s,t),n()}},...e})}const Kx={key:0,class:"CoreDataframeRow__cell CoreDataframeRow__cell--index"},Gx=$e({__name:"CoreDataframeRow",props:{showIndex:{type:Boolean,required:!1},wrapText:{type:Boolean,required:!1},indexText:{type:[Number,String],required:!0},columns:{type:Array,required:!0},row:{type:Object,required:!0},useMarkdown:{type:Boolean,required:!1},editable:{type:Boolean,required:!1},actions:{type:Object,required:!0},displayShadowOnSticky:{type:Boolean}},emits:{change:(e,t,a)=>typeof e=="string"&&typeof t=="number"&&a!==void 0,action:(e,t)=>typeof t=="number"&&typeof e=="string"},setup(e){const t=ir({loader:()=>zt(()=>Promise.resolve().then(()=>i0e),void 0,import.meta.url)}),a=[Dx(16),Bx()],n=e,r=ye(),o=b0(r),s=ye(!1),i=H(()=>Object.keys(n.actions||{}).length>0),l=H(()=>Object.entries(n.actions||{}).map(([c,d])=>({value:c,label:d})));return(c,d)=>($(),R("div",{ref_key:"root",ref:r,class:"CoreDataframeRow",tabindex:"0",onMouseover:d[1]||(d[1]=u=>s.value=!0),onMouseleave:d[2]||(d[2]=u=>s.value=!1),onFocusin:d[3]||(d[3]=u=>s.value=!0)},[d[4]||(d[4]=Z("div",{class:"CoreDataframeRow__spacer"},null,-1)),e.showIndex?($(),R("div",Kx,je(e.indexText),1)):ge("",!0),($(!0),R(Je,null,Ot(e.columns,u=>($(),R("div",{key:`${e.row[E(xn)]}_${u}`,class:"CoreDataframeRow__cell"},[Ce(rx,{value:e.row[u],"use-markdown":e.useMarkdown,editable:e.editable&&(s.value||E(o)),"wrap-text":e.wrapText,class:"CoreDataframeRow__cell__content",onChange:h=>c.$emit("change",u,e.row[E(xn)],h)},null,8,["value","use-markdown","editable","wrap-text","onChange"])]))),128)),i.value?($(),R("div",{key:1,class:ft(["CoreDataframeRow__options",{"CoreDataframeRow__options--shadow":e.displayShadowOnSticky}])},[Ce(E(t),{options:l.value,"hide-icons":"","dropdown-placement":"left","floating-middleware":a,onSelect:d[0]||(d[0]=u=>c.$emit("action",u,e.row[E(xn)]))},null,8,["options"])],2)):ge("",!0)],544))}}),Jx=ke(Gx,[["__scopeId","data-v-2c661540"]]);var Xx=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function E0(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ic={exports:{}},d6={},Sn={},Ss={},Vs={},kt={},$s={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.regexpCode=e.getEsmExportName=e.getProperty=e.safeStringify=e.stringify=e.strConcat=e.addCodeArg=e.str=e._=e.nil=e._Code=e.Name=e.IDENTIFIER=e._CodeOrName=void 0;class t{}e._CodeOrName=t,e.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class a extends t{constructor(v){if(super(),!e.IDENTIFIER.test(v))throw new Error("CodeGen: name must be a valid identifier");this.str=v}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}e.Name=a;class n extends t{constructor(v){super(),this._items=typeof v=="string"?[v]:v}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const v=this._items[0];return v===""||v==='""'}get str(){var v;return(v=this._str)!==null&&v!==void 0?v:this._str=this._items.reduce((y,M)=>`${y}${M}`,"")}get names(){var v;return(v=this._names)!==null&&v!==void 0?v:this._names=this._items.reduce((y,M)=>(M instanceof a&&(y[M.str]=(y[M.str]||0)+1),y),{})}}e._Code=n,e.nil=new n("");function r(b,...v){const y=[b[0]];let M=0;for(;M<v.length;)i(y,v[M]),y.push(b[++M]);return new n(y)}e._=r;const o=new n("+");function s(b,...v){const y=[f(b[0])];let M=0;for(;M<v.length;)y.push(o),i(y,v[M]),y.push(o,f(b[++M]));return l(y),new n(y)}e.str=s;function i(b,v){v instanceof n?b.push(...v._items):v instanceof a?b.push(v):b.push(u(v))}e.addCodeArg=i;function l(b){let v=1;for(;v<b.length-1;){if(b[v]===o){const y=c(b[v-1],b[v+1]);if(y!==void 0){b.splice(v-1,3,y);continue}b[v++]="+"}v++}}function c(b,v){if(v==='""')return b;if(b==='""')return v;if(typeof b=="string")return v instanceof a||b[b.length-1]!=='"'?void 0:typeof v!="string"?`${b.slice(0,-1)}${v}"`:v[0]==='"'?b.slice(0,-1)+v.slice(1):void 0;if(typeof v=="string"&&v[0]==='"'&&!(b instanceof a))return`"${b}${v.slice(1)}`}function d(b,v){return v.emptyStr()?b:b.emptyStr()?v:s`${b}${v}`}e.strConcat=d;function u(b){return typeof b=="number"||typeof b=="boolean"||b===null?b:f(Array.isArray(b)?b.join(","):b)}function h(b){return new n(f(b))}e.stringify=h;function f(b){return JSON.stringify(b).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}e.safeStringify=f;function m(b){return typeof b=="string"&&e.IDENTIFIER.test(b)?new n(`.${b}`):r`[${b}]`}e.getProperty=m;function g(b){if(typeof b=="string"&&e.IDENTIFIER.test(b))return new n(`${b}`);throw new Error(`CodeGen: invalid export name: ${b}, use explicit $id name mapping`)}e.getEsmExportName=g;function _(b){return new n(b.toString())}e.regexpCode=_})($s);var kc={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ValueScope=e.ValueScopeName=e.Scope=e.varKinds=e.UsedValueState=void 0;const t=$s;class a extends Error{constructor(c){super(`CodeGen: "code" for ${c} not defined`),this.value=c.value}}var n;(function(l){l[l.Started=0]="Started",l[l.Completed=1]="Completed"})(n||(e.UsedValueState=n={})),e.varKinds={const:new t.Name("const"),let:new t.Name("let"),var:new t.Name("var")};class r{constructor({prefixes:c,parent:d}={}){this._names={},this._prefixes=c,this._parent=d}toName(c){return c instanceof t.Name?c:this.name(c)}name(c){return new t.Name(this._newName(c))}_newName(c){const d=this._names[c]||this._nameGroup(c);return`${c}${d.index++}`}_nameGroup(c){var d,u;if(!((u=(d=this._parent)===null||d===void 0?void 0:d._prefixes)===null||u===void 0)&&u.has(c)||this._prefixes&&!this._prefixes.has(c))throw new Error(`CodeGen: prefix "${c}" is not allowed in this scope`);return this._names[c]={prefix:c,index:0}}}e.Scope=r;class o extends t.Name{constructor(c,d){super(d),this.prefix=c}setValue(c,{property:d,itemIndex:u}){this.value=c,this.scopePath=(0,t._)`.${new t.Name(d)}[${u}]`}}e.ValueScopeName=o;const s=(0,t._)`\n`;class i extends r{constructor(c){super(c),this._values={},this._scope=c.scope,this.opts={...c,_n:c.lines?s:t.nil}}get(){return this._scope}name(c){return new o(c,this._newName(c))}value(c,d){var u;if(d.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const h=this.toName(c),{prefix:f}=h,m=(u=d.key)!==null&&u!==void 0?u:d.ref;let g=this._values[f];if(g){const v=g.get(m);if(v)return v}else g=this._values[f]=new Map;g.set(m,h);const _=this._scope[f]||(this._scope[f]=[]),b=_.length;return _[b]=d.ref,h.setValue(d,{property:f,itemIndex:b}),h}getValue(c,d){const u=this._values[c];if(u)return u.get(d)}scopeRefs(c,d=this._values){return this._reduceValues(d,u=>{if(u.scopePath===void 0)throw new Error(`CodeGen: name "${u}" has no value`);return(0,t._)`${c}${u.scopePath}`})}scopeCode(c=this._values,d,u){return this._reduceValues(c,h=>{if(h.value===void 0)throw new Error(`CodeGen: name "${h}" has no value`);return h.value.code},d,u)}_reduceValues(c,d,u={},h){let f=t.nil;for(const m in c){const g=c[m];if(!g)continue;const _=u[m]=u[m]||new Map;g.forEach(b=>{if(_.has(b))return;_.set(b,n.Started);let v=d(b);if(v){const y=this.opts.es5?e.varKinds.var:e.varKinds.const;f=(0,t._)`${f}${y} ${b} = ${v};${this.opts._n}`}else if(v=h==null?void 0:h(b))f=(0,t._)`${f}${v}${this.opts._n}`;else throw new a(b);_.set(b,n.Completed)})}return f}}e.ValueScope=i})(kc);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.or=e.and=e.not=e.CodeGen=e.operators=e.varKinds=e.ValueScopeName=e.ValueScope=e.Scope=e.Name=e.regexpCode=e.stringify=e.getProperty=e.nil=e.strConcat=e.str=e._=void 0;const t=$s,a=kc;var n=$s;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return n._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return n.str}}),Object.defineProperty(e,"strConcat",{enumerable:!0,get:function(){return n.strConcat}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return n.nil}}),Object.defineProperty(e,"getProperty",{enumerable:!0,get:function(){return n.getProperty}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return n.stringify}}),Object.defineProperty(e,"regexpCode",{enumerable:!0,get:function(){return n.regexpCode}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return n.Name}});var r=kc;Object.defineProperty(e,"Scope",{enumerable:!0,get:function(){return r.Scope}}),Object.defineProperty(e,"ValueScope",{enumerable:!0,get:function(){return r.ValueScope}}),Object.defineProperty(e,"ValueScopeName",{enumerable:!0,get:function(){return r.ValueScopeName}}),Object.defineProperty(e,"varKinds",{enumerable:!0,get:function(){return r.varKinds}}),e.operators={GT:new t._Code(">"),GTE:new t._Code(">="),LT:new t._Code("<"),LTE:new t._Code("<="),EQ:new t._Code("==="),NEQ:new t._Code("!=="),NOT:new t._Code("!"),OR:new t._Code("||"),AND:new t._Code("&&"),ADD:new t._Code("+")};class o{optimizeNodes(){return this}optimizeNames(C,P){return this}}class s extends o{constructor(C,P,ae){super(),this.varKind=C,this.name=P,this.rhs=ae}render({es5:C,_n:P}){const ae=C?a.varKinds.var:this.varKind,xe=this.rhs===void 0?"":` = ${this.rhs}`;return`${ae} ${this.name}${xe};`+P}optimizeNames(C,P){if(C[this.name.str])return this.rhs&&(this.rhs=Ue(this.rhs,C,P)),this}get names(){return this.rhs instanceof t._CodeOrName?this.rhs.names:{}}}class i extends o{constructor(C,P,ae){super(),this.lhs=C,this.rhs=P,this.sideEffects=ae}render({_n:C}){return`${this.lhs} = ${this.rhs};`+C}optimizeNames(C,P){if(!(this.lhs instanceof t.Name&&!C[this.lhs.str]&&!this.sideEffects))return this.rhs=Ue(this.rhs,C,P),this}get names(){const C=this.lhs instanceof t.Name?{}:{...this.lhs.names};return Te(C,this.rhs)}}class l extends i{constructor(C,P,ae,xe){super(C,ae,xe),this.op=P}render({_n:C}){return`${this.lhs} ${this.op}= ${this.rhs};`+C}}class c extends o{constructor(C){super(),this.label=C,this.names={}}render({_n:C}){return`${this.label}:`+C}}class d extends o{constructor(C){super(),this.label=C,this.names={}}render({_n:C}){return`break${this.label?` ${this.label}`:""};`+C}}class u extends o{constructor(C){super(),this.error=C}render({_n:C}){return`throw ${this.error};`+C}get names(){return this.error.names}}class h extends o{constructor(C){super(),this.code=C}render({_n:C}){return`${this.code};`+C}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(C,P){return this.code=Ue(this.code,C,P),this}get names(){return this.code instanceof t._CodeOrName?this.code.names:{}}}class f extends o{constructor(C=[]){super(),this.nodes=C}render(C){return this.nodes.reduce((P,ae)=>P+ae.render(C),"")}optimizeNodes(){const{nodes:C}=this;let P=C.length;for(;P--;){const ae=C[P].optimizeNodes();Array.isArray(ae)?C.splice(P,1,...ae):ae?C[P]=ae:C.splice(P,1)}return C.length>0?this:void 0}optimizeNames(C,P){const{nodes:ae}=this;let xe=ae.length;for(;xe--;){const ve=ae[xe];ve.optimizeNames(C,P)||(Ze(C,ve.names),ae.splice(xe,1))}return ae.length>0?this:void 0}get names(){return this.nodes.reduce((C,P)=>oe(C,P.names),{})}}class m extends f{render(C){return"{"+C._n+super.render(C)+"}"+C._n}}class g extends f{}class _ extends m{}_.kind="else";class b extends m{constructor(C,P){super(P),this.condition=C}render(C){let P=`if(${this.condition})`+super.render(C);return this.else&&(P+="else "+this.else.render(C)),P}optimizeNodes(){super.optimizeNodes();const C=this.condition;if(C===!0)return this.nodes;let P=this.else;if(P){const ae=P.optimizeNodes();P=this.else=Array.isArray(ae)?new _(ae):ae}if(P)return C===!1?P instanceof b?P:P.nodes:this.nodes.length?this:new b(Me(C),P instanceof b?[P]:P.nodes);if(!(C===!1||!this.nodes.length))return this}optimizeNames(C,P){var ae;if(this.else=(ae=this.else)===null||ae===void 0?void 0:ae.optimizeNames(C,P),!!(super.optimizeNames(C,P)||this.else))return this.condition=Ue(this.condition,C,P),this}get names(){const C=super.names;return Te(C,this.condition),this.else&&oe(C,this.else.names),C}}b.kind="if";class v extends m{}v.kind="for";class y extends v{constructor(C){super(),this.iteration=C}render(C){return`for(${this.iteration})`+super.render(C)}optimizeNames(C,P){if(super.optimizeNames(C,P))return this.iteration=Ue(this.iteration,C,P),this}get names(){return oe(super.names,this.iteration.names)}}class M extends v{constructor(C,P,ae,xe){super(),this.varKind=C,this.name=P,this.from=ae,this.to=xe}render(C){const P=C.es5?a.varKinds.var:this.varKind,{name:ae,from:xe,to:ve}=this;return`for(${P} ${ae}=${xe}; ${ae}<${ve}; ${ae}++)`+super.render(C)}get names(){const C=Te(super.names,this.from);return Te(C,this.to)}}class x extends v{constructor(C,P,ae,xe){super(),this.loop=C,this.varKind=P,this.name=ae,this.iterable=xe}render(C){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(C)}optimizeNames(C,P){if(super.optimizeNames(C,P))return this.iterable=Ue(this.iterable,C,P),this}get names(){return oe(super.names,this.iterable.names)}}class S extends m{constructor(C,P,ae){super(),this.name=C,this.args=P,this.async=ae}render(C){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(C)}}S.kind="func";class L extends f{render(C){return"return "+super.render(C)}}L.kind="return";class F extends m{render(C){let P="try"+super.render(C);return this.catch&&(P+=this.catch.render(C)),this.finally&&(P+=this.finally.render(C)),P}optimizeNodes(){var C,P;return super.optimizeNodes(),(C=this.catch)===null||C===void 0||C.optimizeNodes(),(P=this.finally)===null||P===void 0||P.optimizeNodes(),this}optimizeNames(C,P){var ae,xe;return super.optimizeNames(C,P),(ae=this.catch)===null||ae===void 0||ae.optimizeNames(C,P),(xe=this.finally)===null||xe===void 0||xe.optimizeNames(C,P),this}get names(){const C=super.names;return this.catch&&oe(C,this.catch.names),this.finally&&oe(C,this.finally.names),C}}class te extends m{constructor(C){super(),this.error=C}render(C){return`catch(${this.error})`+super.render(C)}}te.kind="catch";class J extends m{render(C){return"finally"+super.render(C)}}J.kind="finally";class be{constructor(C,P={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...P,_n:P.lines?`
30
+ `:""},this._extScope=C,this._scope=new a.Scope({parent:C}),this._nodes=[new g]}toString(){return this._root.render(this.opts)}name(C){return this._scope.name(C)}scopeName(C){return this._extScope.name(C)}scopeValue(C,P){const ae=this._extScope.value(C,P);return(this._values[ae.prefix]||(this._values[ae.prefix]=new Set)).add(ae),ae}getScopeValue(C,P){return this._extScope.getValue(C,P)}scopeRefs(C){return this._extScope.scopeRefs(C,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(C,P,ae,xe){const ve=this._scope.toName(P);return ae!==void 0&&xe&&(this._constants[ve.str]=ae),this._leafNode(new s(C,ve,ae)),ve}const(C,P,ae){return this._def(a.varKinds.const,C,P,ae)}let(C,P,ae){return this._def(a.varKinds.let,C,P,ae)}var(C,P,ae){return this._def(a.varKinds.var,C,P,ae)}assign(C,P,ae){return this._leafNode(new i(C,P,ae))}add(C,P){return this._leafNode(new l(C,e.operators.ADD,P))}code(C){return typeof C=="function"?C():C!==t.nil&&this._leafNode(new h(C)),this}object(...C){const P=["{"];for(const[ae,xe]of C)P.length>1&&P.push(","),P.push(ae),(ae!==xe||this.opts.es5)&&(P.push(":"),(0,t.addCodeArg)(P,xe));return P.push("}"),new t._Code(P)}if(C,P,ae){if(this._blockNode(new b(C)),P&&ae)this.code(P).else().code(ae).endIf();else if(P)this.code(P).endIf();else if(ae)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(C){return this._elseNode(new b(C))}else(){return this._elseNode(new _)}endIf(){return this._endBlockNode(b,_)}_for(C,P){return this._blockNode(C),P&&this.code(P).endFor(),this}for(C,P){return this._for(new y(C),P)}forRange(C,P,ae,xe,ve=this.opts.es5?a.varKinds.var:a.varKinds.let){const ze=this._scope.toName(C);return this._for(new M(ve,ze,P,ae),()=>xe(ze))}forOf(C,P,ae,xe=a.varKinds.const){const ve=this._scope.toName(C);if(this.opts.es5){const ze=P instanceof t.Name?P:this.var("_arr",P);return this.forRange("_i",0,(0,t._)`${ze}.length`,Ye=>{this.var(ve,(0,t._)`${ze}[${Ye}]`),ae(ve)})}return this._for(new x("of",xe,ve,P),()=>ae(ve))}forIn(C,P,ae,xe=this.opts.es5?a.varKinds.var:a.varKinds.const){if(this.opts.ownProperties)return this.forOf(C,(0,t._)`Object.keys(${P})`,ae);const ve=this._scope.toName(C);return this._for(new x("in",xe,ve,P),()=>ae(ve))}endFor(){return this._endBlockNode(v)}label(C){return this._leafNode(new c(C))}break(C){return this._leafNode(new d(C))}return(C){const P=new L;if(this._blockNode(P),this.code(C),P.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(L)}try(C,P,ae){if(!P&&!ae)throw new Error('CodeGen: "try" without "catch" and "finally"');const xe=new F;if(this._blockNode(xe),this.code(C),P){const ve=this.name("e");this._currNode=xe.catch=new te(ve),P(ve)}return ae&&(this._currNode=xe.finally=new J,this.code(ae)),this._endBlockNode(te,J)}throw(C){return this._leafNode(new u(C))}block(C,P){return this._blockStarts.push(this._nodes.length),C&&this.code(C).endBlock(P),this}endBlock(C){const P=this._blockStarts.pop();if(P===void 0)throw new Error("CodeGen: not in self-balancing block");const ae=this._nodes.length-P;if(ae<0||C!==void 0&&ae!==C)throw new Error(`CodeGen: wrong number of nodes: ${ae} vs ${C} expected`);return this._nodes.length=P,this}func(C,P=t.nil,ae,xe){return this._blockNode(new S(C,P,ae)),xe&&this.code(xe).endFunc(),this}endFunc(){return this._endBlockNode(S)}optimize(C=1){for(;C-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(C){return this._currNode.nodes.push(C),this}_blockNode(C){this._currNode.nodes.push(C),this._nodes.push(C)}_endBlockNode(C,P){const ae=this._currNode;if(ae instanceof C||P&&ae instanceof P)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${P?`${C.kind}/${P.kind}`:C.kind}"`)}_elseNode(C){const P=this._currNode;if(!(P instanceof b))throw new Error('CodeGen: "else" without "if"');return this._currNode=P.else=C,this}get _root(){return this._nodes[0]}get _currNode(){const C=this._nodes;return C[C.length-1]}set _currNode(C){const P=this._nodes;P[P.length-1]=C}}e.CodeGen=be;function oe(k,C){for(const P in C)k[P]=(k[P]||0)+(C[P]||0);return k}function Te(k,C){return C instanceof t._CodeOrName?oe(k,C.names):k}function Ue(k,C,P){if(k instanceof t.Name)return ae(k);if(!xe(k))return k;return new t._Code(k._items.reduce((ve,ze)=>(ze instanceof t.Name&&(ze=ae(ze)),ze instanceof t._Code?ve.push(...ze._items):ve.push(ze),ve),[]));function ae(ve){const ze=P[ve.str];return ze===void 0||C[ve.str]!==1?ve:(delete C[ve.str],ze)}function xe(ve){return ve instanceof t._Code&&ve._items.some(ze=>ze instanceof t.Name&&C[ze.str]===1&&P[ze.str]!==void 0)}}function Ze(k,C){for(const P in C)k[P]=(k[P]||0)-(C[P]||0)}function Me(k){return typeof k=="boolean"||typeof k=="number"||k===null?!k:(0,t._)`!${O(k)}`}e.not=Me;const ee=T(e.operators.AND);function j(...k){return k.reduce(ee)}e.and=j;const K=T(e.operators.OR);function G(...k){return k.reduce(K)}e.or=G;function T(k){return(C,P)=>C===t.nil?P:P===t.nil?C:(0,t._)`${O(C)} ${k} ${O(P)}`}function O(k){return k instanceof t.Name?k:(0,t._)`(${k})`}})(kt);var et={};Object.defineProperty(et,"__esModule",{value:!0});et.checkStrictMode=et.getErrorPath=et.Type=et.useFunc=et.setEvaluated=et.evaluatedPropsToName=et.mergeEvaluated=et.eachItem=et.unescapeJsonPointer=et.escapeJsonPointer=et.escapeFragment=et.unescapeFragment=et.schemaRefOrVal=et.schemaHasRulesButRef=et.schemaHasRules=et.checkUnknownRules=et.alwaysValidSchema=et.toHash=void 0;const aa=kt,Yx=$s;function Qx(e){const t={};for(const a of e)t[a]=!0;return t}et.toHash=Qx;function eC(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(u6(e,t),!h6(t,e.self.RULES.all))}et.alwaysValidSchema=eC;function u6(e,t=e.schema){const{opts:a,self:n}=e;if(!a.strictSchema||typeof t=="boolean")return;const r=n.RULES.keywords;for(const o in t)r[o]||m6(e,`unknown keyword: "${o}"`)}et.checkUnknownRules=u6;function h6(e,t){if(typeof e=="boolean")return!e;for(const a in e)if(t[a])return!0;return!1}et.schemaHasRules=h6;function tC(e,t){if(typeof e=="boolean")return!e;for(const a in e)if(a!=="$ref"&&t.all[a])return!0;return!1}et.schemaHasRulesButRef=tC;function aC({topSchemaRef:e,schemaPath:t},a,n,r){if(!r){if(typeof a=="number"||typeof a=="boolean")return a;if(typeof a=="string")return(0,aa._)`${a}`}return(0,aa._)`${e}${t}${(0,aa.getProperty)(n)}`}et.schemaRefOrVal=aC;function nC(e){return p6(decodeURIComponent(e))}et.unescapeFragment=nC;function rC(e){return encodeURIComponent(I0(e))}et.escapeFragment=rC;function I0(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}et.escapeJsonPointer=I0;function p6(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}et.unescapeJsonPointer=p6;function oC(e,t){if(Array.isArray(e))for(const a of e)t(a);else t(e)}et.eachItem=oC;function Zh({mergeNames:e,mergeToName:t,mergeValues:a,resultToName:n}){return(r,o,s,i)=>{const l=s===void 0?o:s instanceof aa.Name?(o instanceof aa.Name?e(r,o,s):t(r,o,s),s):o instanceof aa.Name?(t(r,s,o),o):a(o,s);return i===aa.Name&&!(l instanceof aa.Name)?n(r,l):l}}et.mergeEvaluated={props:Zh({mergeNames:(e,t,a)=>e.if((0,aa._)`${a} !== true && ${t} !== undefined`,()=>{e.if((0,aa._)`${t} === true`,()=>e.assign(a,!0),()=>e.assign(a,(0,aa._)`${a} || {}`).code((0,aa._)`Object.assign(${a}, ${t})`))}),mergeToName:(e,t,a)=>e.if((0,aa._)`${a} !== true`,()=>{t===!0?e.assign(a,!0):(e.assign(a,(0,aa._)`${a} || {}`),k0(e,a,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:f6}),items:Zh({mergeNames:(e,t,a)=>e.if((0,aa._)`${a} !== true && ${t} !== undefined`,()=>e.assign(a,(0,aa._)`${t} === true ? true : ${a} > ${t} ? ${a} : ${t}`)),mergeToName:(e,t,a)=>e.if((0,aa._)`${a} !== true`,()=>e.assign(a,t===!0?!0:(0,aa._)`${a} > ${t} ? ${a} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function f6(e,t){if(t===!0)return e.var("props",!0);const a=e.var("props",(0,aa._)`{}`);return t!==void 0&&k0(e,a,t),a}et.evaluatedPropsToName=f6;function k0(e,t,a){Object.keys(a).forEach(n=>e.assign((0,aa._)`${t}${(0,aa.getProperty)(n)}`,!0))}et.setEvaluated=k0;const Kh={};function sC(e,t){return e.scopeValue("func",{ref:t,code:Kh[t.code]||(Kh[t.code]=new Yx._Code(t.code))})}et.useFunc=sC;var Tc;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(Tc||(et.Type=Tc={}));function iC(e,t,a){if(e instanceof aa.Name){const n=t===Tc.Num;return a?n?(0,aa._)`"[" + ${e} + "]"`:(0,aa._)`"['" + ${e} + "']"`:n?(0,aa._)`"/" + ${e}`:(0,aa._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return a?(0,aa.getProperty)(e).toString():"/"+I0(e)}et.getErrorPath=iC;function m6(e,t,a=e.opts.strictSchema){if(a){if(t=`strict mode: ${t}`,a===!0)throw new Error(t);e.self.logger.warn(t)}}et.checkStrictMode=m6;var Kn={};Object.defineProperty(Kn,"__esModule",{value:!0});const Fa=kt,lC={data:new Fa.Name("data"),valCxt:new Fa.Name("valCxt"),instancePath:new Fa.Name("instancePath"),parentData:new Fa.Name("parentData"),parentDataProperty:new Fa.Name("parentDataProperty"),rootData:new Fa.Name("rootData"),dynamicAnchors:new Fa.Name("dynamicAnchors"),vErrors:new Fa.Name("vErrors"),errors:new Fa.Name("errors"),this:new Fa.Name("this"),self:new Fa.Name("self"),scope:new Fa.Name("scope"),json:new Fa.Name("json"),jsonPos:new Fa.Name("jsonPos"),jsonLen:new Fa.Name("jsonLen"),jsonPart:new Fa.Name("jsonPart")};Kn.default=lC;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.extendErrors=e.resetErrorsCount=e.reportExtraError=e.reportError=e.keyword$DataError=e.keywordError=void 0;const t=kt,a=et,n=Kn;e.keywordError={message:({keyword:_})=>(0,t.str)`must pass "${_}" keyword validation`},e.keyword$DataError={message:({keyword:_,schemaType:b})=>b?(0,t.str)`"${_}" keyword must be ${b} ($data)`:(0,t.str)`"${_}" keyword is invalid ($data)`};function r(_,b=e.keywordError,v,y){const{it:M}=_,{gen:x,compositeRule:S,allErrors:L}=M,F=u(_,b,v);y??(S||L)?l(x,F):c(M,(0,t._)`[${F}]`)}e.reportError=r;function o(_,b=e.keywordError,v){const{it:y}=_,{gen:M,compositeRule:x,allErrors:S}=y,L=u(_,b,v);l(M,L),x||S||c(y,n.default.vErrors)}e.reportExtraError=o;function s(_,b){_.assign(n.default.errors,b),_.if((0,t._)`${n.default.vErrors} !== null`,()=>_.if(b,()=>_.assign((0,t._)`${n.default.vErrors}.length`,b),()=>_.assign(n.default.vErrors,null)))}e.resetErrorsCount=s;function i({gen:_,keyword:b,schemaValue:v,data:y,errsCount:M,it:x}){if(M===void 0)throw new Error("ajv implementation error");const S=_.name("err");_.forRange("i",M,n.default.errors,L=>{_.const(S,(0,t._)`${n.default.vErrors}[${L}]`),_.if((0,t._)`${S}.instancePath === undefined`,()=>_.assign((0,t._)`${S}.instancePath`,(0,t.strConcat)(n.default.instancePath,x.errorPath))),_.assign((0,t._)`${S}.schemaPath`,(0,t.str)`${x.errSchemaPath}/${b}`),x.opts.verbose&&(_.assign((0,t._)`${S}.schema`,v),_.assign((0,t._)`${S}.data`,y))})}e.extendErrors=i;function l(_,b){const v=_.const("err",b);_.if((0,t._)`${n.default.vErrors} === null`,()=>_.assign(n.default.vErrors,(0,t._)`[${v}]`),(0,t._)`${n.default.vErrors}.push(${v})`),_.code((0,t._)`${n.default.errors}++`)}function c(_,b){const{gen:v,validateName:y,schemaEnv:M}=_;M.$async?v.throw((0,t._)`new ${_.ValidationError}(${b})`):(v.assign((0,t._)`${y}.errors`,b),v.return(!1))}const d={keyword:new t.Name("keyword"),schemaPath:new t.Name("schemaPath"),params:new t.Name("params"),propertyName:new t.Name("propertyName"),message:new t.Name("message"),schema:new t.Name("schema"),parentSchema:new t.Name("parentSchema")};function u(_,b,v){const{createErrors:y}=_.it;return y===!1?(0,t._)`{}`:h(_,b,v)}function h(_,b,v={}){const{gen:y,it:M}=_,x=[f(M,v),m(_,v)];return g(_,b,x),y.object(...x)}function f({errorPath:_},{instancePath:b}){const v=b?(0,t.str)`${_}${(0,a.getErrorPath)(b,a.Type.Str)}`:_;return[n.default.instancePath,(0,t.strConcat)(n.default.instancePath,v)]}function m({keyword:_,it:{errSchemaPath:b}},{schemaPath:v,parentSchema:y}){let M=y?b:(0,t.str)`${b}/${_}`;return v&&(M=(0,t.str)`${M}${(0,a.getErrorPath)(v,a.Type.Str)}`),[d.schemaPath,M]}function g(_,{params:b,message:v},y){const{keyword:M,data:x,schemaValue:S,it:L}=_,{opts:F,propertyName:te,topSchemaRef:J,schemaPath:be}=L;y.push([d.keyword,M],[d.params,typeof b=="function"?b(_):b||(0,t._)`{}`]),F.messages&&y.push([d.message,typeof v=="function"?v(_):v]),F.verbose&&y.push([d.schema,S],[d.parentSchema,(0,t._)`${J}${be}`],[n.default.data,x]),te&&y.push([d.propertyName,te])}})(Vs);Object.defineProperty(Ss,"__esModule",{value:!0});Ss.boolOrEmptySchema=Ss.topBoolOrEmptySchema=void 0;const cC=Vs,dC=kt,uC=Kn,hC={message:"boolean schema is false"};function pC(e){const{gen:t,schema:a,validateName:n}=e;a===!1?v6(e,!1):typeof a=="object"&&a.$async===!0?t.return(uC.default.data):(t.assign((0,dC._)`${n}.errors`,null),t.return(!0))}Ss.topBoolOrEmptySchema=pC;function fC(e,t){const{gen:a,schema:n}=e;n===!1?(a.var(t,!1),v6(e)):a.var(t,!0)}Ss.boolOrEmptySchema=fC;function v6(e,t){const{gen:a,data:n}=e,r={gen:a,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,cC.reportError)(r,hC,void 0,t)}var Sa={},Lo={};Object.defineProperty(Lo,"__esModule",{value:!0});Lo.getRules=Lo.isJSONType=void 0;const mC=["string","number","integer","boolean","null","object","array"],vC=new Set(mC);function gC(e){return typeof e=="string"&&vC.has(e)}Lo.isJSONType=gC;function yC(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}Lo.getRules=yC;var xr={};Object.defineProperty(xr,"__esModule",{value:!0});xr.shouldUseRule=xr.shouldUseGroup=xr.schemaHasRulesForType=void 0;function MC({schema:e,self:t},a){const n=t.RULES.types[a];return n&&n!==!0&&g6(e,n)}xr.schemaHasRulesForType=MC;function g6(e,t){return t.rules.some(a=>y6(e,a))}xr.shouldUseGroup=g6;function y6(e,t){var a;return e[t.keyword]!==void 0||((a=t.definition.implements)===null||a===void 0?void 0:a.some(n=>e[n]!==void 0))}xr.shouldUseRule=y6;Object.defineProperty(Sa,"__esModule",{value:!0});Sa.reportTypeError=Sa.checkDataTypes=Sa.checkDataType=Sa.coerceAndCheckDataType=Sa.getJSONTypes=Sa.getSchemaTypes=Sa.DataType=void 0;const _C=Lo,bC=xr,wC=Vs,Ct=kt,M6=et;var gs;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(gs||(Sa.DataType=gs={}));function xC(e){const t=_6(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}Sa.getSchemaTypes=xC;function _6(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(_C.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}Sa.getJSONTypes=_6;function CC(e,t){const{gen:a,data:n,opts:r}=e,o=AC(t,r.coerceTypes),s=t.length>0&&!(o.length===0&&t.length===1&&(0,bC.schemaHasRulesForType)(e,t[0]));if(s){const i=T0(t,n,r.strictNumbers,gs.Wrong);a.if(i,()=>{o.length?SC(e,t,o):P0(e)})}return s}Sa.coerceAndCheckDataType=CC;const b6=new Set(["string","number","integer","boolean","null"]);function AC(e,t){return t?e.filter(a=>b6.has(a)||t==="array"&&a==="array"):[]}function SC(e,t,a){const{gen:n,data:r,opts:o}=e,s=n.let("dataType",(0,Ct._)`typeof ${r}`),i=n.let("coerced",(0,Ct._)`undefined`);o.coerceTypes==="array"&&n.if((0,Ct._)`${s} == 'object' && Array.isArray(${r}) && ${r}.length == 1`,()=>n.assign(r,(0,Ct._)`${r}[0]`).assign(s,(0,Ct._)`typeof ${r}`).if(T0(t,r,o.strictNumbers),()=>n.assign(i,r))),n.if((0,Ct._)`${i} !== undefined`);for(const c of a)(b6.has(c)||c==="array"&&o.coerceTypes==="array")&&l(c);n.else(),P0(e),n.endIf(),n.if((0,Ct._)`${i} !== undefined`,()=>{n.assign(r,i),$C(e,i)});function l(c){switch(c){case"string":n.elseIf((0,Ct._)`${s} == "number" || ${s} == "boolean"`).assign(i,(0,Ct._)`"" + ${r}`).elseIf((0,Ct._)`${r} === null`).assign(i,(0,Ct._)`""`);return;case"number":n.elseIf((0,Ct._)`${s} == "boolean" || ${r} === null
31
31
  || (${s} == "string" && ${r} && ${r} == +${r})`).assign(i,(0,Ct._)`+${r}`);return;case"integer":n.elseIf((0,Ct._)`${s} === "boolean" || ${r} === null
32
32
  || (${s} === "string" && ${r} && ${r} == +${r} && !(${r} % 1))`).assign(i,(0,Ct._)`+${r}`);return;case"boolean":n.elseIf((0,Ct._)`${r} === "false" || ${r} === 0 || ${r} === null`).assign(i,!1).elseIf((0,Ct._)`${r} === "true" || ${r} === 1`).assign(i,!0);return;case"null":n.elseIf((0,Ct._)`${r} === "" || ${r} === 0 || ${r} === false`),n.assign(i,null);return;case"array":n.elseIf((0,Ct._)`${s} === "string" || ${s} === "number"
33
- || ${s} === "boolean" || ${r} === null`).assign(i,(0,Ct._)`[${r}]`)}}}function $C({gen:e,parentData:t,parentDataProperty:a},n){e.if((0,Ct._)`${t} !== undefined`,()=>e.assign((0,Ct._)`${t}[${a}]`,n))}function Pc(e,t,a,n=vs.Correct){const r=n===vs.Correct?Ct.operators.EQ:Ct.operators.NEQ;let o;switch(e){case"null":return(0,Ct._)`${t} ${r} null`;case"array":o=(0,Ct._)`Array.isArray(${t})`;break;case"object":o=(0,Ct._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":o=s((0,Ct._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":o=s();break;default:return(0,Ct._)`typeof ${t} ${r} ${e}`}return n===vs.Correct?o:(0,Ct.not)(o);function s(i=Ct.nil){return(0,Ct.and)((0,Ct._)`typeof ${t} == "number"`,i,a?(0,Ct._)`isFinite(${t})`:Ct.nil)}}Sa.checkDataType=Pc;function T0(e,t,a,n){if(e.length===1)return Pc(e[0],t,a,n);let r;const o=(0,M6.toHash)(e);if(o.array&&o.object){const s=(0,Ct._)`typeof ${t} != "object"`;r=o.null?s:(0,Ct._)`!${t} || ${s}`,delete o.null,delete o.array,delete o.object}else r=Ct.nil;o.number&&delete o.integer;for(const s in o)r=(0,Ct.and)(r,Pc(s,t,a,n));return r}Sa.checkDataTypes=T0;const EC={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,Ct._)`{type: ${e}}`:(0,Ct._)`{type: ${t}}`};function P0(e){const t=IC(e);(0,wC.reportError)(t,EC)}Sa.reportTypeError=P0;function IC(e){const{gen:t,data:a,schema:n}=e,r=(0,M6.schemaRefOrVal)(e,n,"type");return{gen:t,keyword:"type",data:a,schema:n.type,schemaCode:r,schemaValue:r,parentSchema:n,params:{},it:e}}var Dl={};Object.defineProperty(Dl,"__esModule",{value:!0});Dl.assignDefaults=void 0;const ts=kt,kC=et;function TC(e,t){const{properties:a,items:n}=e.schema;if(t==="object"&&a)for(const r in a)Gh(e,r,a[r].default);else t==="array"&&Array.isArray(n)&&n.forEach((r,o)=>Gh(e,o,r.default))}Dl.assignDefaults=TC;function Gh(e,t,a){const{gen:n,compositeRule:r,data:o,opts:s}=e;if(a===void 0)return;const i=(0,ts._)`${o}${(0,ts.getProperty)(t)}`;if(r){(0,kC.checkStrictMode)(e,`default is ignored for: ${i}`);return}let l=(0,ts._)`${i} === undefined`;s.useDefaults==="empty"&&(l=(0,ts._)`${l} || ${i} === null || ${i} === ""`),n.if(l,(0,ts._)`${i} = ${(0,ts.stringify)(a)}`)}var Qn={},Pt={};Object.defineProperty(Pt,"__esModule",{value:!0});Pt.validateUnion=Pt.validateArray=Pt.usePattern=Pt.callValidateCode=Pt.schemaProperties=Pt.allSchemaProperties=Pt.noPropertyInData=Pt.propertyInData=Pt.isOwnProperty=Pt.hasPropFunc=Pt.reportMissingProp=Pt.checkMissingProp=Pt.checkReportMissingProp=void 0;const da=kt,L0=et,Nr=Zn,PC=et;function LC(e,t){const{gen:a,data:n,it:r}=e;a.if(O0(a,n,t,r.opts.ownProperties),()=>{e.setParams({missingProperty:(0,da._)`${t}`},!0),e.error()})}Pt.checkReportMissingProp=LC;function VC({gen:e,data:t,it:{opts:a}},n,r){return(0,da.or)(...n.map(o=>(0,da.and)(O0(e,t,o,a.ownProperties),(0,da._)`${r} = ${o}`)))}Pt.checkMissingProp=VC;function OC(e,t){e.setParams({missingProperty:t},!0),e.error()}Pt.reportMissingProp=OC;function w6(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,da._)`Object.prototype.hasOwnProperty`})}Pt.hasPropFunc=w6;function V0(e,t,a){return(0,da._)`${w6(e)}.call(${t}, ${a})`}Pt.isOwnProperty=V0;function HC(e,t,a,n){const r=(0,da._)`${t}${(0,da.getProperty)(a)} !== undefined`;return n?(0,da._)`${r} && ${V0(e,t,a)}`:r}Pt.propertyInData=HC;function O0(e,t,a,n){const r=(0,da._)`${t}${(0,da.getProperty)(a)} === undefined`;return n?(0,da.or)(r,(0,da.not)(V0(e,t,a))):r}Pt.noPropertyInData=O0;function x6(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}Pt.allSchemaProperties=x6;function RC(e,t){return x6(t).filter(a=>!(0,L0.alwaysValidSchema)(e,t[a]))}Pt.schemaProperties=RC;function NC({schemaCode:e,data:t,it:{gen:a,topSchemaRef:n,schemaPath:r,errorPath:o},it:s},i,l,c){const d=c?(0,da._)`${e}, ${t}, ${n}${r}`:t,u=[[Nr.default.instancePath,(0,da.strConcat)(Nr.default.instancePath,o)],[Nr.default.parentData,s.parentData],[Nr.default.parentDataProperty,s.parentDataProperty],[Nr.default.rootData,Nr.default.rootData]];s.opts.dynamicRef&&u.push([Nr.default.dynamicAnchors,Nr.default.dynamicAnchors]);const h=(0,da._)`${d}, ${a.object(...u)}`;return l!==da.nil?(0,da._)`${i}.call(${l}, ${h})`:(0,da._)`${i}(${h})`}Pt.callValidateCode=NC;const DC=(0,da._)`new RegExp`;function BC({gen:e,it:{opts:t}},a){const n=t.unicodeRegExp?"u":"",{regExp:r}=t.code,o=r(a,n);return e.scopeValue("pattern",{key:o.toString(),ref:o,code:(0,da._)`${r.code==="new RegExp"?DC:(0,PC.useFunc)(e,r)}(${a}, ${n})`})}Pt.usePattern=BC;function FC(e){const{gen:t,data:a,keyword:n,it:r}=e,o=t.name("valid");if(r.allErrors){const i=t.let("valid",!0);return s(()=>t.assign(i,!1)),i}return t.var(o,!0),s(()=>t.break()),o;function s(i){const l=t.const("len",(0,da._)`${a}.length`);t.forRange("i",0,l,c=>{e.subschema({keyword:n,dataProp:c,dataPropType:L0.Type.Num},o),t.if((0,da.not)(o),i)})}}Pt.validateArray=FC;function jC(e){const{gen:t,schema:a,keyword:n,it:r}=e;if(!Array.isArray(a))throw new Error("ajv implementation error");if(a.some(l=>(0,L0.alwaysValidSchema)(r,l))&&!r.opts.unevaluated)return;const s=t.let("valid",!1),i=t.name("_valid");t.block(()=>a.forEach((l,c)=>{const d=e.subschema({keyword:n,schemaProp:c,compositeRule:!0},i);t.assign(s,(0,da._)`${s} || ${i}`),e.mergeValidEvaluated(d,i)||t.if((0,da.not)(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}Pt.validateUnion=jC;Object.defineProperty(Qn,"__esModule",{value:!0});Qn.validateKeywordUsage=Qn.validSchemaType=Qn.funcKeywordCode=Qn.macroKeywordCode=void 0;const Ga=kt,yo=Zn,UC=Pt,zC=Ls;function qC(e,t){const{gen:a,keyword:n,schema:r,parentSchema:o,it:s}=e,i=t.macro.call(s.self,r,o,s),l=C6(a,n,i);s.opts.validateSchema!==!1&&s.self.validateSchema(i,!0);const c=a.name("valid");e.subschema({schema:i,schemaPath:Ga.nil,errSchemaPath:`${s.errSchemaPath}/${n}`,topSchemaRef:l,compositeRule:!0},c),e.pass(c,()=>e.error(!0))}Qn.macroKeywordCode=qC;function WC(e,t){var a;const{gen:n,keyword:r,schema:o,parentSchema:s,$data:i,it:l}=e;KC(l,t);const c=!i&&t.compile?t.compile.call(l.self,o,s,l):t.validate,d=C6(n,r,c),u=n.let("valid");e.block$data(u,h),e.ok((a=t.valid)!==null&&a!==void 0?a:u);function h(){if(t.errors===!1)g(),t.modifying&&Jh(e),_(()=>e.error());else{const b=t.async?f():m();t.modifying&&Jh(e),_(()=>ZC(e,b))}}function f(){const b=n.let("ruleErrs",null);return n.try(()=>g((0,Ga._)`await `),v=>n.assign(u,!1).if((0,Ga._)`${v} instanceof ${l.ValidationError}`,()=>n.assign(b,(0,Ga._)`${v}.errors`),()=>n.throw(v))),b}function m(){const b=(0,Ga._)`${d}.errors`;return n.assign(b,null),g(Ga.nil),b}function g(b=t.async?(0,Ga._)`await `:Ga.nil){const v=l.opts.passContext?yo.default.this:yo.default.self,y=!("compile"in t&&!i||t.schema===!1);n.assign(u,(0,Ga._)`${b}${(0,UC.callValidateCode)(e,d,v,y)}`,t.modifying)}function _(b){var v;n.if((0,Ga.not)((v=t.valid)!==null&&v!==void 0?v:u),b)}}Qn.funcKeywordCode=WC;function Jh(e){const{gen:t,data:a,it:n}=e;t.if(n.parentData,()=>t.assign(a,(0,Ga._)`${n.parentData}[${n.parentDataProperty}]`))}function ZC(e,t){const{gen:a}=e;a.if((0,Ga._)`Array.isArray(${t})`,()=>{a.assign(yo.default.vErrors,(0,Ga._)`${yo.default.vErrors} === null ? ${t} : ${yo.default.vErrors}.concat(${t})`).assign(yo.default.errors,(0,Ga._)`${yo.default.vErrors}.length`),(0,zC.extendErrors)(e)},()=>e.error())}function KC({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function C6(e,t,a){if(a===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof a=="function"?{ref:a}:{ref:a,code:(0,Ga.stringify)(a)})}function GC(e,t,a=!1){return!t.length||t.some(n=>n==="array"?Array.isArray(e):n==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==n||a&&typeof e>"u")}Qn.validSchemaType=GC;function JC({schema:e,opts:t,self:a,errSchemaPath:n},r,o){if(Array.isArray(r.keyword)?!r.keyword.includes(o):r.keyword!==o)throw new Error("ajv implementation error");const s=r.dependencies;if(s!=null&&s.some(i=>!Object.prototype.hasOwnProperty.call(e,i)))throw new Error(`parent schema must have dependencies of ${o}: ${s.join(",")}`);if(r.validateSchema&&!r.validateSchema(e[o])){const l=`keyword "${o}" value is invalid at path "${n}": `+a.errorsText(r.validateSchema.errors);if(t.validateSchema==="log")a.logger.error(l);else throw new Error(l)}}Qn.validateKeywordUsage=JC;var Yr={};Object.defineProperty(Yr,"__esModule",{value:!0});Yr.extendSubschemaMode=Yr.extendSubschemaData=Yr.getSubschema=void 0;const Yn=kt,A6=et;function XC(e,{keyword:t,schemaProp:a,schema:n,schemaPath:r,errSchemaPath:o,topSchemaRef:s}){if(t!==void 0&&n!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){const i=e.schema[t];return a===void 0?{schema:i,schemaPath:(0,Yn._)`${e.schemaPath}${(0,Yn.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:i[a],schemaPath:(0,Yn._)`${e.schemaPath}${(0,Yn.getProperty)(t)}${(0,Yn.getProperty)(a)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,A6.escapeFragment)(a)}`}}if(n!==void 0){if(r===void 0||o===void 0||s===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:r,topSchemaRef:s,errSchemaPath:o}}throw new Error('either "keyword" or "schema" must be passed')}Yr.getSubschema=XC;function YC(e,t,{dataProp:a,dataPropType:n,data:r,dataTypes:o,propertyName:s}){if(r!==void 0&&a!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:i}=t;if(a!==void 0){const{errorPath:c,dataPathArr:d,opts:u}=t,h=i.let("data",(0,Yn._)`${t.data}${(0,Yn.getProperty)(a)}`,!0);l(h),e.errorPath=(0,Yn.str)`${c}${(0,A6.getErrorPath)(a,n,u.jsPropertySyntax)}`,e.parentDataProperty=(0,Yn._)`${a}`,e.dataPathArr=[...d,e.parentDataProperty]}if(r!==void 0){const c=r instanceof Yn.Name?r:i.let("data",r,!0);l(c),s!==void 0&&(e.propertyName=s)}o&&(e.dataTypes=o);function l(c){e.data=c,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,c]}}Yr.extendSubschemaData=YC;function QC(e,{jtdDiscriminator:t,jtdMetadata:a,compositeRule:n,createErrors:r,allErrors:o}){n!==void 0&&(e.compositeRule=n),r!==void 0&&(e.createErrors=r),o!==void 0&&(e.allErrors=o),e.jtdDiscriminator=t,e.jtdMetadata=a}Yr.extendSubschemaMode=QC;var Na={},S6=function e(t,a){if(t===a)return!0;if(t&&a&&typeof t=="object"&&typeof a=="object"){if(t.constructor!==a.constructor)return!1;var n,r,o;if(Array.isArray(t)){if(n=t.length,n!=a.length)return!1;for(r=n;r--!==0;)if(!e(t[r],a[r]))return!1;return!0}if(t.constructor===RegExp)return t.source===a.source&&t.flags===a.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===a.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===a.toString();if(o=Object.keys(t),n=o.length,n!==Object.keys(a).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(a,o[r]))return!1;for(r=n;r--!==0;){var s=o[r];if(!e(t[s],a[s]))return!1}return!0}return t!==t&&a!==a},$6={exports:{}},Zr=$6.exports=function(e,t,a){typeof t=="function"&&(a=t,t={}),a=t.cb||a;var n=typeof a=="function"?a:a.pre||function(){},r=a.post||function(){};D1(t,n,r,e,"",e)};Zr.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Zr.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Zr.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Zr.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function D1(e,t,a,n,r,o,s,i,l,c){if(n&&typeof n=="object"&&!Array.isArray(n)){t(n,r,o,s,i,l,c);for(var d in n){var u=n[d];if(Array.isArray(u)){if(d in Zr.arrayKeywords)for(var h=0;h<u.length;h++)D1(e,t,a,u[h],r+"/"+d+"/"+h,o,r,d,n,h)}else if(d in Zr.propsKeywords){if(u&&typeof u=="object")for(var f in u)D1(e,t,a,u[f],r+"/"+d+"/"+eA(f),o,r,d,n,f)}else(d in Zr.keywords||e.allKeys&&!(d in Zr.skipKeywords))&&D1(e,t,a,u,r+"/"+d,o,r,d,n)}a(n,r,o,s,i,l,c)}}function eA(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}var tA=$6.exports;Object.defineProperty(Na,"__esModule",{value:!0});Na.getSchemaRefs=Na.resolveUrl=Na.normalizeId=Na._getFullPath=Na.getFullPath=Na.inlineRef=void 0;const aA=et,nA=S6,rA=tA,oA=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function sA(e,t=!0){return typeof e=="boolean"?!0:t===!0?!Lc(e):t?E6(e)<=t:!1}Na.inlineRef=sA;const iA=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Lc(e){for(const t in e){if(iA.has(t))return!0;const a=e[t];if(Array.isArray(a)&&a.some(Lc)||typeof a=="object"&&Lc(a))return!0}return!1}function E6(e){let t=0;for(const a in e){if(a==="$ref")return 1/0;if(t++,!oA.has(a)&&(typeof e[a]=="object"&&(0,aA.eachItem)(e[a],n=>t+=E6(n)),t===1/0))return 1/0}return t}function I6(e,t="",a){a!==!1&&(t=gs(t));const n=e.parse(t);return k6(e,n)}Na.getFullPath=I6;function k6(e,t){return e.serialize(t).split("#")[0]+"#"}Na._getFullPath=k6;const lA=/#\/?$/;function gs(e){return e?e.replace(lA,""):""}Na.normalizeId=gs;function cA(e,t,a){return a=gs(a),e.resolve(t,a)}Na.resolveUrl=cA;const dA=/^[a-z_][-a-z0-9._]*$/i;function uA(e,t){if(typeof e=="boolean")return{};const{schemaId:a,uriResolver:n}=this.opts,r=gs(e[a]||t),o={"":r},s=I6(n,r,!1),i={},l=new Set;return rA(e,{allKeys:!0},(u,h,f,m)=>{if(m===void 0)return;const g=s+h;let _=o[m];typeof u[a]=="string"&&(_=b.call(this,u[a])),v.call(this,u.$anchor),v.call(this,u.$dynamicAnchor),o[h]=_;function b(y){const M=this.opts.uriResolver.resolve;if(y=gs(_?M(_,y):y),l.has(y))throw d(y);l.add(y);let x=this.refs[y];return typeof x=="string"&&(x=this.refs[x]),typeof x=="object"?c(u,x.schema,y):y!==gs(g)&&(y[0]==="#"?(c(u,i[y],y),i[y]=u):this.refs[y]=g),y}function v(y){if(typeof y=="string"){if(!dA.test(y))throw new Error(`invalid anchor "${y}"`);b.call(this,`#${y}`)}}}),i;function c(u,h,f){if(h!==void 0&&!nA(u,h))throw d(f)}function d(u){return new Error(`reference "${u}" resolves to more than one schema`)}}Na.getSchemaRefs=uA;Object.defineProperty(Sn,"__esModule",{value:!0});Sn.getData=Sn.KeywordCxt=Sn.validateFunctionCode=void 0;const T6=As,Xh=Sa,H0=wr,cl=Sa,hA=Dl,mi=Qn,j2=Yr,lt=kt,yt=Zn,pA=Na,xr=et,Ys=Ls;function fA(e){if(V6(e)&&(O6(e),L6(e))){gA(e);return}P6(e,()=>(0,T6.topBoolOrEmptySchema)(e))}Sn.validateFunctionCode=fA;function P6({gen:e,validateName:t,schema:a,schemaEnv:n,opts:r},o){r.code.es5?e.func(t,(0,lt._)`${yt.default.data}, ${yt.default.valCxt}`,n.$async,()=>{e.code((0,lt._)`"use strict"; ${Yh(a,r)}`),vA(e,r),e.code(o)}):e.func(t,(0,lt._)`${yt.default.data}, ${mA(r)}`,n.$async,()=>e.code(Yh(a,r)).code(o))}function mA(e){return(0,lt._)`{${yt.default.instancePath}="", ${yt.default.parentData}, ${yt.default.parentDataProperty}, ${yt.default.rootData}=${yt.default.data}${e.dynamicRef?(0,lt._)`, ${yt.default.dynamicAnchors}={}`:lt.nil}}={}`}function vA(e,t){e.if(yt.default.valCxt,()=>{e.var(yt.default.instancePath,(0,lt._)`${yt.default.valCxt}.${yt.default.instancePath}`),e.var(yt.default.parentData,(0,lt._)`${yt.default.valCxt}.${yt.default.parentData}`),e.var(yt.default.parentDataProperty,(0,lt._)`${yt.default.valCxt}.${yt.default.parentDataProperty}`),e.var(yt.default.rootData,(0,lt._)`${yt.default.valCxt}.${yt.default.rootData}`),t.dynamicRef&&e.var(yt.default.dynamicAnchors,(0,lt._)`${yt.default.valCxt}.${yt.default.dynamicAnchors}`)},()=>{e.var(yt.default.instancePath,(0,lt._)`""`),e.var(yt.default.parentData,(0,lt._)`undefined`),e.var(yt.default.parentDataProperty,(0,lt._)`undefined`),e.var(yt.default.rootData,yt.default.data),t.dynamicRef&&e.var(yt.default.dynamicAnchors,(0,lt._)`{}`)})}function gA(e){const{schema:t,opts:a,gen:n}=e;P6(e,()=>{a.$comment&&t.$comment&&R6(e),wA(e),n.let(yt.default.vErrors,null),n.let(yt.default.errors,0),a.unevaluated&&yA(e),H6(e),AA(e)})}function yA(e){const{gen:t,validateName:a}=e;e.evaluated=t.const("evaluated",(0,lt._)`${a}.evaluated`),t.if((0,lt._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,lt._)`${e.evaluated}.props`,(0,lt._)`undefined`)),t.if((0,lt._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,lt._)`${e.evaluated}.items`,(0,lt._)`undefined`))}function Yh(e,t){const a=typeof e=="object"&&e[t.schemaId];return a&&(t.code.source||t.code.process)?(0,lt._)`/*# sourceURL=${a} */`:lt.nil}function MA(e,t){if(V6(e)&&(O6(e),L6(e))){_A(e,t);return}(0,T6.boolOrEmptySchema)(e,t)}function L6({schema:e,self:t}){if(typeof e=="boolean")return!e;for(const a in e)if(t.RULES.all[a])return!0;return!1}function V6(e){return typeof e.schema!="boolean"}function _A(e,t){const{schema:a,gen:n,opts:r}=e;r.$comment&&a.$comment&&R6(e),xA(e),CA(e);const o=n.const("_errs",yt.default.errors);H6(e,o),n.var(t,(0,lt._)`${o} === ${yt.default.errors}`)}function O6(e){(0,xr.checkUnknownRules)(e),bA(e)}function H6(e,t){if(e.opts.jtd)return Qh(e,[],!1,t);const a=(0,Xh.getSchemaTypes)(e.schema),n=(0,Xh.coerceAndCheckDataType)(e,a);Qh(e,a,!n,t)}function bA(e){const{schema:t,errSchemaPath:a,opts:n,self:r}=e;t.$ref&&n.ignoreKeywordsWithRef&&(0,xr.schemaHasRulesButRef)(t,r.RULES)&&r.logger.warn(`$ref: keywords ignored in schema at path "${a}"`)}function wA(e){const{schema:t,opts:a}=e;t.default!==void 0&&a.useDefaults&&a.strictSchema&&(0,xr.checkStrictMode)(e,"default is ignored in the schema root")}function xA(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,pA.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function CA(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function R6({gen:e,schemaEnv:t,schema:a,errSchemaPath:n,opts:r}){const o=a.$comment;if(r.$comment===!0)e.code((0,lt._)`${yt.default.self}.logger.log(${o})`);else if(typeof r.$comment=="function"){const s=(0,lt.str)`${n}/$comment`,i=e.scopeValue("root",{ref:t.root});e.code((0,lt._)`${yt.default.self}.opts.$comment(${o}, ${s}, ${i}.schema)`)}}function AA(e){const{gen:t,schemaEnv:a,validateName:n,ValidationError:r,opts:o}=e;a.$async?t.if((0,lt._)`${yt.default.errors} === 0`,()=>t.return(yt.default.data),()=>t.throw((0,lt._)`new ${r}(${yt.default.vErrors})`)):(t.assign((0,lt._)`${n}.errors`,yt.default.vErrors),o.unevaluated&&SA(e),t.return((0,lt._)`${yt.default.errors} === 0`))}function SA({gen:e,evaluated:t,props:a,items:n}){a instanceof lt.Name&&e.assign((0,lt._)`${t}.props`,a),n instanceof lt.Name&&e.assign((0,lt._)`${t}.items`,n)}function Qh(e,t,a,n){const{gen:r,schema:o,data:s,allErrors:i,opts:l,self:c}=e,{RULES:d}=c;if(o.$ref&&(l.ignoreKeywordsWithRef||!(0,xr.schemaHasRulesButRef)(o,d))){r.block(()=>B6(e,"$ref",d.all.$ref.definition));return}l.jtd||$A(e,t),r.block(()=>{for(const h of d.rules)u(h);u(d.post)});function u(h){(0,H0.shouldUseGroup)(o,h)&&(h.type?(r.if((0,cl.checkDataType)(h.type,s,l.strictNumbers)),ep(e,h),t.length===1&&t[0]===h.type&&a&&(r.else(),(0,cl.reportTypeError)(e)),r.endIf()):ep(e,h),i||r.if((0,lt._)`${yt.default.errors} === ${n||0}`))}}function ep(e,t){const{gen:a,schema:n,opts:{useDefaults:r}}=e;r&&(0,hA.assignDefaults)(e,t.type),a.block(()=>{for(const o of t.rules)(0,H0.shouldUseRule)(n,o)&&B6(e,o.keyword,o.definition,t.type)})}function $A(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(EA(e,t),e.opts.allowUnionTypes||IA(e,t),kA(e,e.dataTypes))}function EA(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(a=>{N6(e.dataTypes,a)||R0(e,`type "${a}" not allowed by context "${e.dataTypes.join(",")}"`)}),PA(e,t)}}function IA(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&R0(e,"use allowUnionTypes to allow union type keyword")}function kA(e,t){const a=e.self.RULES.all;for(const n in a){const r=a[n];if(typeof r=="object"&&(0,H0.shouldUseRule)(e.schema,r)){const{type:o}=r.definition;o.length&&!o.some(s=>TA(t,s))&&R0(e,`missing type "${o.join(",")}" for keyword "${n}"`)}}}function TA(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function N6(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function PA(e,t){const a=[];for(const n of e.dataTypes)N6(t,n)?a.push(n):t.includes("integer")&&n==="number"&&a.push("integer");e.dataTypes=a}function R0(e,t){const a=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${a}" (strictTypes)`,(0,xr.checkStrictMode)(e,t,e.opts.strictTypes)}class D6{constructor(t,a,n){if((0,mi.validateKeywordUsage)(t,a,n),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=n,this.data=t.data,this.schema=t.schema[n],this.$data=a.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,xr.schemaRefOrVal)(t,this.schema,n,this.$data),this.schemaType=a.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=a,this.$data)this.schemaCode=t.gen.const("vSchema",F6(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,mi.validSchemaType)(this.schema,a.schemaType,a.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(a.schemaType)}`);("code"in a?a.trackErrors:a.errors!==!1)&&(this.errsCount=t.gen.const("_errs",yt.default.errors))}result(t,a,n){this.failResult((0,lt.not)(t),a,n)}failResult(t,a,n){this.gen.if(t),n?n():this.error(),a?(this.gen.else(),a(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,a){this.failResult((0,lt.not)(t),void 0,a)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);const{schemaCode:a}=this;this.fail((0,lt._)`${a} !== undefined && (${(0,lt.or)(this.invalid$data(),t)})`)}error(t,a,n){if(a){this.setParams(a),this._error(t,n),this.setParams({});return}this._error(t,n)}_error(t,a){(t?Ys.reportExtraError:Ys.reportError)(this,this.def.error,a)}$dataError(){(0,Ys.reportError)(this,this.def.$dataError||Ys.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,Ys.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,a){a?Object.assign(this.params,t):this.params=t}block$data(t,a,n=lt.nil){this.gen.block(()=>{this.check$data(t,n),a()})}check$data(t=lt.nil,a=lt.nil){if(!this.$data)return;const{gen:n,schemaCode:r,schemaType:o,def:s}=this;n.if((0,lt.or)((0,lt._)`${r} === undefined`,a)),t!==lt.nil&&n.assign(t,!0),(o.length||s.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),t!==lt.nil&&n.assign(t,!1)),n.else()}invalid$data(){const{gen:t,schemaCode:a,schemaType:n,def:r,it:o}=this;return(0,lt.or)(s(),i());function s(){if(n.length){if(!(a instanceof lt.Name))throw new Error("ajv implementation error");const l=Array.isArray(n)?n:[n];return(0,lt._)`${(0,cl.checkDataTypes)(l,a,o.opts.strictNumbers,cl.DataType.Wrong)}`}return lt.nil}function i(){if(r.validateSchema){const l=t.scopeValue("validate$data",{ref:r.validateSchema});return(0,lt._)`!${l}(${a})`}return lt.nil}}subschema(t,a){const n=(0,j2.getSubschema)(this.it,t);(0,j2.extendSubschemaData)(n,this.it,t),(0,j2.extendSubschemaMode)(n,t);const r={...this.it,...n,items:void 0,props:void 0};return MA(r,a),r}mergeEvaluated(t,a){const{it:n,gen:r}=this;n.opts.unevaluated&&(n.props!==!0&&t.props!==void 0&&(n.props=xr.mergeEvaluated.props(r,t.props,n.props,a)),n.items!==!0&&t.items!==void 0&&(n.items=xr.mergeEvaluated.items(r,t.items,n.items,a)))}mergeValidEvaluated(t,a){const{it:n,gen:r}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return r.if(a,()=>this.mergeEvaluated(t,lt.Name)),!0}}Sn.KeywordCxt=D6;function B6(e,t,a,n){const r=new D6(e,a,t);"code"in a?a.code(r,n):r.$data&&a.validate?(0,mi.funcKeywordCode)(r,a):"macro"in a?(0,mi.macroKeywordCode)(r,a):(a.compile||a.validate)&&(0,mi.funcKeywordCode)(r,a)}const LA=/^\/(?:[^~]|~0|~1)*$/,VA=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function F6(e,{dataLevel:t,dataNames:a,dataPathArr:n}){let r,o;if(e==="")return yt.default.rootData;if(e[0]==="/"){if(!LA.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);r=e,o=yt.default.rootData}else{const c=VA.exec(e);if(!c)throw new Error(`Invalid JSON-pointer: ${e}`);const d=+c[1];if(r=c[2],r==="#"){if(d>=t)throw new Error(l("property/index",d));return n[t-d]}if(d>t)throw new Error(l("data",d));if(o=a[t-d],!r)return o}let s=o;const i=r.split("/");for(const c of i)c&&(o=(0,lt._)`${o}${(0,lt.getProperty)((0,xr.unescapeJsonPointer)(c))}`,s=(0,lt._)`${s} && ${o}`);return s;function l(c,d){return`Cannot access ${c} ${d} levels up, current level is ${t}`}}Sn.getData=F6;var qi={};Object.defineProperty(qi,"__esModule",{value:!0});class OA extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}}qi.default=OA;var Vs={};Object.defineProperty(Vs,"__esModule",{value:!0});const U2=Na;class HA extends Error{constructor(t,a,n,r){super(r||`can't resolve reference ${n} from id ${a}`),this.missingRef=(0,U2.resolveUrl)(t,a,n),this.missingSchema=(0,U2.normalizeId)((0,U2.getFullPath)(t,this.missingRef))}}Vs.default=HA;var on={};Object.defineProperty(on,"__esModule",{value:!0});on.resolveSchema=on.getCompilingSchema=on.resolveRef=on.compileSchema=on.SchemaEnv=void 0;const Vn=kt,RA=qi,vo=Zn,Nn=Na,tp=et,NA=Sn;class Bl{constructor(t){var a;this.refs={},this.dynamicAnchors={};let n;typeof t.schema=="object"&&(n=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(a=t.baseId)!==null&&a!==void 0?a:(0,Nn.normalizeId)(n==null?void 0:n[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=n==null?void 0:n.$async,this.refs={}}}on.SchemaEnv=Bl;function N0(e){const t=j6.call(this,e);if(t)return t;const a=(0,Nn.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:n,lines:r}=this.opts.code,{ownProperties:o}=this.opts,s=new Vn.CodeGen(this.scope,{es5:n,lines:r,ownProperties:o});let i;e.$async&&(i=s.scopeValue("Error",{ref:RA.default,code:(0,Vn._)`require("ajv/dist/runtime/validation_error").default`}));const l=s.scopeName("validate");e.validateName=l;const c={gen:s,allErrors:this.opts.allErrors,data:vo.default.data,parentData:vo.default.parentData,parentDataProperty:vo.default.parentDataProperty,dataNames:[vo.default.data],dataPathArr:[Vn.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,Vn.stringify)(e.schema)}:{ref:e.schema}),validateName:l,ValidationError:i,schema:e.schema,schemaEnv:e,rootId:a,baseId:e.baseId||a,schemaPath:Vn.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Vn._)`""`,opts:this.opts,self:this};let d;try{this._compilations.add(e),(0,NA.validateFunctionCode)(c),s.optimize(this.opts.code.optimize);const u=s.toString();d=`${s.scopeRefs(vo.default.scope)}return ${u}`,this.opts.code.process&&(d=this.opts.code.process(d,e));const f=new Function(`${vo.default.self}`,`${vo.default.scope}`,d)(this,this.scope.get());if(this.scope.value(l,{ref:f}),f.errors=null,f.schema=e.schema,f.schemaEnv=e,e.$async&&(f.$async=!0),this.opts.code.source===!0&&(f.source={validateName:l,validateCode:u,scopeValues:s._values}),this.opts.unevaluated){const{props:m,items:g}=c;f.evaluated={props:m instanceof Vn.Name?void 0:m,items:g instanceof Vn.Name?void 0:g,dynamicProps:m instanceof Vn.Name,dynamicItems:g instanceof Vn.Name},f.source&&(f.source.evaluated=(0,Vn.stringify)(f.evaluated))}return e.validate=f,e}catch(u){throw delete e.validate,delete e.validateName,d&&this.logger.error("Error compiling schema, function code:",d),u}finally{this._compilations.delete(e)}}on.compileSchema=N0;function DA(e,t,a){var n;a=(0,Nn.resolveUrl)(this.opts.uriResolver,t,a);const r=e.refs[a];if(r)return r;let o=jA.call(this,e,a);if(o===void 0){const s=(n=e.localRefs)===null||n===void 0?void 0:n[a],{schemaId:i}=this.opts;s&&(o=new Bl({schema:s,schemaId:i,root:e,baseId:t}))}if(o!==void 0)return e.refs[a]=BA.call(this,o)}on.resolveRef=DA;function BA(e){return(0,Nn.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:N0.call(this,e)}function j6(e){for(const t of this._compilations)if(FA(t,e))return t}on.getCompilingSchema=j6;function FA(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function jA(e,t){let a;for(;typeof(a=this.refs[t])=="string";)t=a;return a||this.schemas[t]||Fl.call(this,e,t)}function Fl(e,t){const a=this.opts.uriResolver.parse(t),n=(0,Nn._getFullPath)(this.opts.uriResolver,a);let r=(0,Nn.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&n===r)return z2.call(this,a,e);const o=(0,Nn.normalizeId)(n),s=this.refs[o]||this.schemas[o];if(typeof s=="string"){const i=Fl.call(this,e,s);return typeof(i==null?void 0:i.schema)!="object"?void 0:z2.call(this,a,i)}if(typeof(s==null?void 0:s.schema)=="object"){if(s.validate||N0.call(this,s),o===(0,Nn.normalizeId)(t)){const{schema:i}=s,{schemaId:l}=this.opts,c=i[l];return c&&(r=(0,Nn.resolveUrl)(this.opts.uriResolver,r,c)),new Bl({schema:i,schemaId:l,root:e,baseId:r})}return z2.call(this,a,s)}}on.resolveSchema=Fl;const UA=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function z2(e,{baseId:t,schema:a,root:n}){var r;if(((r=e.fragment)===null||r===void 0?void 0:r[0])!=="/")return;for(const i of e.fragment.slice(1).split("/")){if(typeof a=="boolean")return;const l=a[(0,tp.unescapeFragment)(i)];if(l===void 0)return;a=l;const c=typeof a=="object"&&a[this.opts.schemaId];!UA.has(i)&&c&&(t=(0,Nn.resolveUrl)(this.opts.uriResolver,t,c))}let o;if(typeof a!="boolean"&&a.$ref&&!(0,tp.schemaHasRulesButRef)(a,this.RULES)){const i=(0,Nn.resolveUrl)(this.opts.uriResolver,t,a.$ref);o=Fl.call(this,n,i)}const{schemaId:s}=this.opts;if(o=o||new Bl({schema:a,schemaId:s,root:n,baseId:t}),o.schema!==o.root.schema)return o}const zA="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",qA="Meta-schema for $data reference (JSON AnySchema extension proposal)",WA="object",ZA=["$data"],KA={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},GA=!1,JA={$id:zA,description:qA,type:WA,required:ZA,properties:KA,additionalProperties:GA};var D0={},jl={exports:{}};const XA={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};var YA={HEX:XA};const{HEX:QA}=YA;function U6(e){if(q6(e,".")<3)return{host:e,isIPV4:!1};const t=e.match(/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/u)||[],[a]=t;return a?{host:tS(a,"."),isIPV4:!0}:{host:e,isIPV4:!1}}function Vc(e,t=!1){let a="",n=!0;for(const r of e){if(QA[r]===void 0)return;r!=="0"&&n===!0&&(n=!1),n||(a+=r)}return t&&a.length===0&&(a="0"),a}function eS(e){let t=0;const a={error:!1,address:"",zone:""},n=[],r=[];let o=!1,s=!1,i=!1;function l(){if(r.length){if(o===!1){const c=Vc(r);if(c!==void 0)n.push(c);else return a.error=!0,!1}r.length=0}return!0}for(let c=0;c<e.length;c++){const d=e[c];if(!(d==="["||d==="]"))if(d===":"){if(s===!0&&(i=!0),!l())break;if(t++,n.push(":"),t>7){a.error=!0;break}c-1>=0&&e[c-1]===":"&&(s=!0);continue}else if(d==="%"){if(!l())break;o=!0}else{r.push(d);continue}}return r.length&&(o?a.zone=r.join(""):i?n.push(r.join("")):n.push(Vc(r))),a.address=n.join(""),a}function z6(e,t={}){if(q6(e,":")<2)return{host:e,isIPV6:!1};const a=eS(e);if(a.error)return{host:e,isIPV6:!1};{let n=a.address,r=a.address;return a.zone&&(n+="%"+a.zone,r+="%25"+a.zone),{host:n,escapedHost:r,isIPV6:!0}}}function tS(e,t){let a="",n=!0;const r=e.length;for(let o=0;o<r;o++){const s=e[o];s==="0"&&n?(o+1<=r&&e[o+1]===t||o+1===r)&&(a+=s,n=!1):(s===t?n=!0:n=!1,a+=s)}return a}function q6(e,t){let a=0;for(let n=0;n<e.length;n++)e[n]===t&&a++;return a}const ap=/^\.\.?\//u,np=/^\/\.(?:\/|$)/u,rp=/^\/\.\.(?:\/|$)/u,aS=/^\/?(?:.|\n)*?(?=\/|$)/u;function nS(e){const t=[];for(;e.length;)if(e.match(ap))e=e.replace(ap,"");else if(e.match(np))e=e.replace(np,"/");else if(e.match(rp))e=e.replace(rp,"/"),t.pop();else if(e==="."||e==="..")e="";else{const a=e.match(aS);if(a){const n=a[0];e=e.slice(n.length),t.push(n)}else throw new Error("Unexpected dot segment condition")}return t.join("")}function rS(e,t){const a=t!==!0?escape:unescape;return e.scheme!==void 0&&(e.scheme=a(e.scheme)),e.userinfo!==void 0&&(e.userinfo=a(e.userinfo)),e.host!==void 0&&(e.host=a(e.host)),e.path!==void 0&&(e.path=a(e.path)),e.query!==void 0&&(e.query=a(e.query)),e.fragment!==void 0&&(e.fragment=a(e.fragment)),e}function oS(e,t){const a=[];if(e.userinfo!==void 0&&(a.push(e.userinfo),a.push("@")),e.host!==void 0){let n=unescape(e.host);const r=U6(n);if(r.isIPV4)n=r.host;else{const o=z6(r.host,{isIPV4:!1});o.isIPV6===!0?n=`[${o.escapedHost}]`:n=e.host}a.push(n)}return(typeof e.port=="number"||typeof e.port=="string")&&(a.push(":"),a.push(String(e.port))),a.length?a.join(""):void 0}var sS={recomposeAuthority:oS,normalizeComponentEncoding:rS,removeDotSegments:nS,normalizeIPv4:U6,normalizeIPv6:z6,stringArrayToHexStripped:Vc};const iS=/^[\da-f]{8}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{12}$/iu,lS=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;function W6(e){return typeof e.secure=="boolean"?e.secure:String(e.scheme).toLowerCase()==="wss"}function Z6(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function K6(e){const t=String(e.scheme).toLowerCase()==="https";return(e.port===(t?443:80)||e.port==="")&&(e.port=void 0),e.path||(e.path="/"),e}function cS(e){return e.secure=W6(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function dS(e){if((e.port===(W6(e)?443:80)||e.port==="")&&(e.port=void 0),typeof e.secure=="boolean"&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){const[t,a]=e.resourceName.split("?");e.path=t&&t!=="/"?t:void 0,e.query=a,e.resourceName=void 0}return e.fragment=void 0,e}function uS(e,t){if(!e.path)return e.error="URN can not be parsed",e;const a=e.path.match(lS);if(a){const n=t.scheme||e.scheme||"urn";e.nid=a[1].toLowerCase(),e.nss=a[2];const r=`${n}:${t.nid||e.nid}`,o=B0[r];e.path=void 0,o&&(e=o.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e}function hS(e,t){const a=t.scheme||e.scheme||"urn",n=e.nid.toLowerCase(),r=`${a}:${t.nid||n}`,o=B0[r];o&&(e=o.serialize(e,t));const s=e,i=e.nss;return s.path=`${n||t.nid}:${i}`,t.skipEscape=!0,s}function pS(e,t){const a=e;return a.uuid=a.nss,a.nss=void 0,!t.tolerant&&(!a.uuid||!iS.test(a.uuid))&&(a.error=a.error||"UUID is not valid."),a}function fS(e){const t=e;return t.nss=(e.uuid||"").toLowerCase(),t}const G6={scheme:"http",domainHost:!0,parse:Z6,serialize:K6},mS={scheme:"https",domainHost:G6.domainHost,parse:Z6,serialize:K6},B1={scheme:"ws",domainHost:!0,parse:cS,serialize:dS},vS={scheme:"wss",domainHost:B1.domainHost,parse:B1.parse,serialize:B1.serialize},gS={scheme:"urn",parse:uS,serialize:hS,skipNormalize:!0},yS={scheme:"urn:uuid",parse:pS,serialize:fS,skipNormalize:!0},B0={http:G6,https:mS,ws:B1,wss:vS,urn:gS,"urn:uuid":yS};var MS=B0;const{normalizeIPv6:_S,normalizeIPv4:bS,removeDotSegments:ri,recomposeAuthority:wS,normalizeComponentEncoding:b1}=sS,F0=MS;function xS(e,t){return typeof e=="string"?e=er($r(e,t),t):typeof e=="object"&&(e=$r(er(e,t),t)),e}function CS(e,t,a){const n=Object.assign({scheme:"null"},a),r=J6($r(e,n),$r(t,n),n,!0);return er(r,{...n,skipEscape:!0})}function J6(e,t,a,n){const r={};return n||(e=$r(er(e,a),a),t=$r(er(t,a),a)),a=a||{},!a.tolerant&&t.scheme?(r.scheme=t.scheme,r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=ri(t.path||""),r.query=t.query):(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0?(r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=ri(t.path||""),r.query=t.query):(t.path?(t.path.charAt(0)==="/"?r.path=ri(t.path):((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path?r.path="/"+t.path:e.path?r.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:r.path=t.path,r.path=ri(r.path)),r.query=t.query):(r.path=e.path,t.query!==void 0?r.query=t.query:r.query=e.query),r.userinfo=e.userinfo,r.host=e.host,r.port=e.port),r.scheme=e.scheme),r.fragment=t.fragment,r}function AS(e,t,a){return typeof e=="string"?(e=unescape(e),e=er(b1($r(e,a),!0),{...a,skipEscape:!0})):typeof e=="object"&&(e=er(b1(e,!0),{...a,skipEscape:!0})),typeof t=="string"?(t=unescape(t),t=er(b1($r(t,a),!0),{...a,skipEscape:!0})):typeof t=="object"&&(t=er(b1(t,!0),{...a,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()}function er(e,t){const a={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},n=Object.assign({},t),r=[],o=F0[(n.scheme||a.scheme||"").toLowerCase()];o&&o.serialize&&o.serialize(a,n),a.path!==void 0&&(n.skipEscape?a.path=unescape(a.path):(a.path=escape(a.path),a.scheme!==void 0&&(a.path=a.path.split("%3A").join(":")))),n.reference!=="suffix"&&a.scheme&&r.push(a.scheme,":");const s=wS(a,n);if(s!==void 0&&(n.reference!=="suffix"&&r.push("//"),r.push(s),a.path&&a.path.charAt(0)!=="/"&&r.push("/")),a.path!==void 0){let i=a.path;!n.absolutePath&&(!o||!o.absolutePath)&&(i=ri(i)),s===void 0&&(i=i.replace(/^\/\//u,"/%2F")),r.push(i)}return a.query!==void 0&&r.push("?",a.query),a.fragment!==void 0&&r.push("#",a.fragment),r.join("")}const SS=Array.from({length:127},(e,t)=>/[^!"$&'()*+,\-.;=_`a-z{}~]/u.test(String.fromCharCode(t)));function $S(e){let t=0;for(let a=0,n=e.length;a<n;++a)if(t=e.charCodeAt(a),t>126||SS[t])return!0;return!1}const ES=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function $r(e,t){const a=Object.assign({},t),n={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},r=e.indexOf("%")!==-1;let o=!1;a.reference==="suffix"&&(e=(a.scheme?a.scheme+":":"")+"//"+e);const s=e.match(ES);if(s){if(n.scheme=s[1],n.userinfo=s[3],n.host=s[4],n.port=parseInt(s[5],10),n.path=s[6]||"",n.query=s[7],n.fragment=s[8],isNaN(n.port)&&(n.port=s[5]),n.host){const l=bS(n.host);if(l.isIPV4===!1){const c=_S(l.host,{isIPV4:!1});n.host=c.host.toLowerCase(),o=c.isIPV6}else n.host=l.host,o=!0}n.scheme===void 0&&n.userinfo===void 0&&n.host===void 0&&n.port===void 0&&!n.path&&n.query===void 0?n.reference="same-document":n.scheme===void 0?n.reference="relative":n.fragment===void 0?n.reference="absolute":n.reference="uri",a.reference&&a.reference!=="suffix"&&a.reference!==n.reference&&(n.error=n.error||"URI is not a "+a.reference+" reference.");const i=F0[(a.scheme||n.scheme||"").toLowerCase()];if(!a.unicodeSupport&&(!i||!i.unicodeSupport)&&n.host&&(a.domainHost||i&&i.domainHost)&&o===!1&&$S(n.host))try{n.host=URL.domainToASCII(n.host.toLowerCase())}catch(l){n.error=n.error||"Host's domain name can not be converted to ASCII: "+l}(!i||i&&!i.skipNormalize)&&(r&&n.scheme!==void 0&&(n.scheme=unescape(n.scheme)),r&&n.host!==void 0&&(n.host=unescape(n.host)),n.path!==void 0&&n.path.length&&(n.path=escape(unescape(n.path))),n.fragment!==void 0&&n.fragment.length&&(n.fragment=encodeURI(decodeURIComponent(n.fragment)))),i&&i.parse&&i.parse(n,a)}else n.error=n.error||"URI can not be parsed.";return n}const j0={SCHEMES:F0,normalize:xS,resolve:CS,resolveComponents:J6,equal:AS,serialize:er,parse:$r};jl.exports=j0;jl.exports.default=j0;jl.exports.fastUri=j0;var IS=jl.exports;Object.defineProperty(D0,"__esModule",{value:!0});const X6=IS;X6.code='require("ajv/dist/runtime/uri").default';D0.default=X6;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=void 0;var t=Sn;Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return t.KeywordCxt}});var a=kt;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return a._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return a.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return a.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return a.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return a.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return a.CodeGen}});const n=qi,r=Vs,o=Po,s=on,i=kt,l=Na,c=Sa,d=et,u=JA,h=D0,f=(G,T)=>new RegExp(G,T);f.code="new RegExp";const m=["removeAdditional","useDefaults","coerceTypes"],g=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),_={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},b={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},v=200;function y(G){var T,O,k,C,P,ae,xe,ve,ze,Ye,ct,wt,D,q,he,me,_e,Ae,pe,ce,ue,I,B,N,U;const se=G.strict,Se=(T=G.code)===null||T===void 0?void 0:T.optimize,Ne=Se===!0||Se===void 0?1:Se||0,ut=(k=(O=G.code)===null||O===void 0?void 0:O.regExp)!==null&&k!==void 0?k:f,ie=(C=G.uriResolver)!==null&&C!==void 0?C:h.default;return{strictSchema:(ae=(P=G.strictSchema)!==null&&P!==void 0?P:se)!==null&&ae!==void 0?ae:!0,strictNumbers:(ve=(xe=G.strictNumbers)!==null&&xe!==void 0?xe:se)!==null&&ve!==void 0?ve:!0,strictTypes:(Ye=(ze=G.strictTypes)!==null&&ze!==void 0?ze:se)!==null&&Ye!==void 0?Ye:"log",strictTuples:(wt=(ct=G.strictTuples)!==null&&ct!==void 0?ct:se)!==null&&wt!==void 0?wt:"log",strictRequired:(q=(D=G.strictRequired)!==null&&D!==void 0?D:se)!==null&&q!==void 0?q:!1,code:G.code?{...G.code,optimize:Ne,regExp:ut}:{optimize:Ne,regExp:ut},loopRequired:(he=G.loopRequired)!==null&&he!==void 0?he:v,loopEnum:(me=G.loopEnum)!==null&&me!==void 0?me:v,meta:(_e=G.meta)!==null&&_e!==void 0?_e:!0,messages:(Ae=G.messages)!==null&&Ae!==void 0?Ae:!0,inlineRefs:(pe=G.inlineRefs)!==null&&pe!==void 0?pe:!0,schemaId:(ce=G.schemaId)!==null&&ce!==void 0?ce:"$id",addUsedSchema:(ue=G.addUsedSchema)!==null&&ue!==void 0?ue:!0,validateSchema:(I=G.validateSchema)!==null&&I!==void 0?I:!0,validateFormats:(B=G.validateFormats)!==null&&B!==void 0?B:!0,unicodeRegExp:(N=G.unicodeRegExp)!==null&&N!==void 0?N:!0,int32range:(U=G.int32range)!==null&&U!==void 0?U:!0,uriResolver:ie}}class M{constructor(T={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,T=this.opts={...T,...y(T)};const{es5:O,lines:k}=this.opts.code;this.scope=new i.ValueScope({scope:{},prefixes:g,es5:O,lines:k}),this.logger=oe(T.logger);const C=T.validateFormats;T.validateFormats=!1,this.RULES=(0,o.getRules)(),x.call(this,_,T,"NOT SUPPORTED"),x.call(this,b,T,"DEPRECATED","warn"),this._metaOpts=J.call(this),T.formats&&F.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),T.keywords&&te.call(this,T.keywords),typeof T.meta=="object"&&this.addMetaSchema(T.meta),L.call(this),T.validateFormats=C}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:T,meta:O,schemaId:k}=this.opts;let C=u;k==="id"&&(C={...u},C.id=C.$id,delete C.$id),O&&T&&this.addMetaSchema(C,C[k],!1)}defaultMeta(){const{meta:T,schemaId:O}=this.opts;return this.opts.defaultMeta=typeof T=="object"?T[O]||T:void 0}validate(T,O){let k;if(typeof T=="string"){if(k=this.getSchema(T),!k)throw new Error(`no schema with key or ref "${T}"`)}else k=this.compile(T);const C=k(O);return"$async"in k||(this.errors=k.errors),C}compile(T,O){const k=this._addSchema(T,O);return k.validate||this._compileSchemaEnv(k)}compileAsync(T,O){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:k}=this.opts;return C.call(this,T,O);async function C(Ye,ct){await P.call(this,Ye.$schema);const wt=this._addSchema(Ye,ct);return wt.validate||ae.call(this,wt)}async function P(Ye){Ye&&!this.getSchema(Ye)&&await C.call(this,{$ref:Ye},!0)}async function ae(Ye){try{return this._compileSchemaEnv(Ye)}catch(ct){if(!(ct instanceof r.default))throw ct;return xe.call(this,ct),await ve.call(this,ct.missingSchema),ae.call(this,Ye)}}function xe({missingSchema:Ye,missingRef:ct}){if(this.refs[Ye])throw new Error(`AnySchema ${Ye} is loaded but ${ct} cannot be resolved`)}async function ve(Ye){const ct=await ze.call(this,Ye);this.refs[Ye]||await P.call(this,ct.$schema),this.refs[Ye]||this.addSchema(ct,Ye,O)}async function ze(Ye){const ct=this._loading[Ye];if(ct)return ct;try{return await(this._loading[Ye]=k(Ye))}finally{delete this._loading[Ye]}}}addSchema(T,O,k,C=this.opts.validateSchema){if(Array.isArray(T)){for(const ae of T)this.addSchema(ae,void 0,k,C);return this}let P;if(typeof T=="object"){const{schemaId:ae}=this.opts;if(P=T[ae],P!==void 0&&typeof P!="string")throw new Error(`schema ${ae} must be string`)}return O=(0,l.normalizeId)(O||P),this._checkUnique(O),this.schemas[O]=this._addSchema(T,k,O,C,!0),this}addMetaSchema(T,O,k=this.opts.validateSchema){return this.addSchema(T,O,!0,k),this}validateSchema(T,O){if(typeof T=="boolean")return!0;let k;if(k=T.$schema,k!==void 0&&typeof k!="string")throw new Error("$schema must be a string");if(k=k||this.opts.defaultMeta||this.defaultMeta(),!k)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const C=this.validate(k,T);if(!C&&O){const P="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(P);else throw new Error(P)}return C}getSchema(T){let O;for(;typeof(O=S.call(this,T))=="string";)T=O;if(O===void 0){const{schemaId:k}=this.opts,C=new s.SchemaEnv({schema:{},schemaId:k});if(O=s.resolveSchema.call(this,C,T),!O)return;this.refs[T]=O}return O.validate||this._compileSchemaEnv(O)}removeSchema(T){if(T instanceof RegExp)return this._removeAllSchemas(this.schemas,T),this._removeAllSchemas(this.refs,T),this;switch(typeof T){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const O=S.call(this,T);return typeof O=="object"&&this._cache.delete(O.schema),delete this.schemas[T],delete this.refs[T],this}case"object":{const O=T;this._cache.delete(O);let k=T[this.opts.schemaId];return k&&(k=(0,l.normalizeId)(k),delete this.schemas[k],delete this.refs[k]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(T){for(const O of T)this.addKeyword(O);return this}addKeyword(T,O){let k;if(typeof T=="string")k=T,typeof O=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),O.keyword=k);else if(typeof T=="object"&&O===void 0){if(O=T,k=O.keyword,Array.isArray(k)&&!k.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(Ue.call(this,k,O),!O)return(0,d.eachItem)(k,P=>Ze.call(this,P)),this;ee.call(this,O);const C={...O,type:(0,c.getJSONTypes)(O.type),schemaType:(0,c.getJSONTypes)(O.schemaType)};return(0,d.eachItem)(k,C.type.length===0?P=>Ze.call(this,P,C):P=>C.type.forEach(ae=>Ze.call(this,P,C,ae))),this}getKeyword(T){const O=this.RULES.all[T];return typeof O=="object"?O.definition:!!O}removeKeyword(T){const{RULES:O}=this;delete O.keywords[T],delete O.all[T];for(const k of O.rules){const C=k.rules.findIndex(P=>P.keyword===T);C>=0&&k.rules.splice(C,1)}return this}addFormat(T,O){return typeof O=="string"&&(O=new RegExp(O)),this.formats[T]=O,this}errorsText(T=this.errors,{separator:O=", ",dataVar:k="data"}={}){return!T||T.length===0?"No errors":T.map(C=>`${k}${C.instancePath} ${C.message}`).reduce((C,P)=>C+O+P)}$dataMetaSchema(T,O){const k=this.RULES.all;T=JSON.parse(JSON.stringify(T));for(const C of O){const P=C.split("/").slice(1);let ae=T;for(const xe of P)ae=ae[xe];for(const xe in k){const ve=k[xe];if(typeof ve!="object")continue;const{$data:ze}=ve.definition,Ye=ae[xe];ze&&Ye&&(ae[xe]=K(Ye))}}return T}_removeAllSchemas(T,O){for(const k in T){const C=T[k];(!O||O.test(k))&&(typeof C=="string"?delete T[k]:C&&!C.meta&&(this._cache.delete(C.schema),delete T[k]))}}_addSchema(T,O,k,C=this.opts.validateSchema,P=this.opts.addUsedSchema){let ae;const{schemaId:xe}=this.opts;if(typeof T=="object")ae=T[xe];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof T!="boolean")throw new Error("schema must be object or boolean")}let ve=this._cache.get(T);if(ve!==void 0)return ve;k=(0,l.normalizeId)(ae||k);const ze=l.getSchemaRefs.call(this,T,k);return ve=new s.SchemaEnv({schema:T,schemaId:xe,meta:O,baseId:k,localRefs:ze}),this._cache.set(ve.schema,ve),P&&!k.startsWith("#")&&(k&&this._checkUnique(k),this.refs[k]=ve),C&&this.validateSchema(T,!0),ve}_checkUnique(T){if(this.schemas[T]||this.refs[T])throw new Error(`schema with key or id "${T}" already exists`)}_compileSchemaEnv(T){if(T.meta?this._compileMetaSchema(T):s.compileSchema.call(this,T),!T.validate)throw new Error("ajv implementation error");return T.validate}_compileMetaSchema(T){const O=this.opts;this.opts=this._metaOpts;try{s.compileSchema.call(this,T)}finally{this.opts=O}}}M.ValidationError=n.default,M.MissingRefError=r.default,e.default=M;function x(G,T,O,k="error"){for(const C in G){const P=C;P in T&&this.logger[k](`${O}: option ${C}. ${G[P]}`)}}function S(G){return G=(0,l.normalizeId)(G),this.schemas[G]||this.refs[G]}function L(){const G=this.opts.schemas;if(G)if(Array.isArray(G))this.addSchema(G);else for(const T in G)this.addSchema(G[T],T)}function F(){for(const G in this.opts.formats){const T=this.opts.formats[G];T&&this.addFormat(G,T)}}function te(G){if(Array.isArray(G)){this.addVocabulary(G);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const T in G){const O=G[T];O.keyword||(O.keyword=T),this.addKeyword(O)}}function J(){const G={...this.opts};for(const T of m)delete G[T];return G}const be={log(){},warn(){},error(){}};function oe(G){if(G===!1)return be;if(G===void 0)return console;if(G.log&&G.warn&&G.error)return G;throw new Error("logger must implement log, warn and error methods")}const Te=/^[a-z_$][a-z0-9_$:-]*$/i;function Ue(G,T){const{RULES:O}=this;if((0,d.eachItem)(G,k=>{if(O.keywords[k])throw new Error(`Keyword ${k} is already defined`);if(!Te.test(k))throw new Error(`Keyword ${k} has invalid name`)}),!!T&&T.$data&&!("code"in T||"validate"in T))throw new Error('$data keyword must have "code" or "validate" function')}function Ze(G,T,O){var k;const C=T==null?void 0:T.post;if(O&&C)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:P}=this;let ae=C?P.post:P.rules.find(({type:ve})=>ve===O);if(ae||(ae={type:O,rules:[]},P.rules.push(ae)),P.keywords[G]=!0,!T)return;const xe={keyword:G,definition:{...T,type:(0,c.getJSONTypes)(T.type),schemaType:(0,c.getJSONTypes)(T.schemaType)}};T.before?Me.call(this,ae,xe,T.before):ae.rules.push(xe),P.all[G]=xe,(k=T.implements)===null||k===void 0||k.forEach(ve=>this.addKeyword(ve))}function Me(G,T,O){const k=G.rules.findIndex(C=>C.keyword===O);k>=0?G.rules.splice(k,0,T):(G.rules.push(T),this.logger.warn(`rule ${O} is not defined`))}function ee(G){let{metaSchema:T}=G;T!==void 0&&(G.$data&&this.opts.$data&&(T=K(T)),G.validateSchema=this.compile(T,!0))}const j={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function K(G){return{anyOf:[G,j]}}})(d6);var U0={},z0={},q0={};Object.defineProperty(q0,"__esModule",{value:!0});const kS={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};q0.default=kS;var Lo={};Object.defineProperty(Lo,"__esModule",{value:!0});Lo.callRef=Lo.getValidate=void 0;const TS=Vs,op=Pt,an=kt,as=Zn,sp=on,w1=et,PS={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:a,it:n}=e,{baseId:r,schemaEnv:o,validateName:s,opts:i,self:l}=n,{root:c}=o;if((a==="#"||a==="#/")&&r===c.baseId)return u();const d=sp.resolveRef.call(l,c,r,a);if(d===void 0)throw new TS.default(n.opts.uriResolver,r,a);if(d instanceof sp.SchemaEnv)return h(d);return f(d);function u(){if(o===c)return F1(e,s,o,o.$async);const m=t.scopeValue("root",{ref:c});return F1(e,(0,an._)`${m}.validate`,c,c.$async)}function h(m){const g=Y6(e,m);F1(e,g,m,m.$async)}function f(m){const g=t.scopeValue("schema",i.code.source===!0?{ref:m,code:(0,an.stringify)(m)}:{ref:m}),_=t.name("valid"),b=e.subschema({schema:m,dataTypes:[],schemaPath:an.nil,topSchemaRef:g,errSchemaPath:a},_);e.mergeEvaluated(b),e.ok(_)}}};function Y6(e,t){const{gen:a}=e;return t.validate?a.scopeValue("validate",{ref:t.validate}):(0,an._)`${a.scopeValue("wrapper",{ref:t})}.validate`}Lo.getValidate=Y6;function F1(e,t,a,n){const{gen:r,it:o}=e,{allErrors:s,schemaEnv:i,opts:l}=o,c=l.passContext?as.default.this:an.nil;n?d():u();function d(){if(!i.$async)throw new Error("async schema referenced by sync schema");const m=r.let("valid");r.try(()=>{r.code((0,an._)`await ${(0,op.callValidateCode)(e,t,c)}`),f(t),s||r.assign(m,!0)},g=>{r.if((0,an._)`!(${g} instanceof ${o.ValidationError})`,()=>r.throw(g)),h(g),s||r.assign(m,!1)}),e.ok(m)}function u(){e.result((0,op.callValidateCode)(e,t,c),()=>f(t),()=>h(t))}function h(m){const g=(0,an._)`${m}.errors`;r.assign(as.default.vErrors,(0,an._)`${as.default.vErrors} === null ? ${g} : ${as.default.vErrors}.concat(${g})`),r.assign(as.default.errors,(0,an._)`${as.default.vErrors}.length`)}function f(m){var g;if(!o.opts.unevaluated)return;const _=(g=a==null?void 0:a.validate)===null||g===void 0?void 0:g.evaluated;if(o.props!==!0)if(_&&!_.dynamicProps)_.props!==void 0&&(o.props=w1.mergeEvaluated.props(r,_.props,o.props));else{const b=r.var("props",(0,an._)`${m}.evaluated.props`);o.props=w1.mergeEvaluated.props(r,b,o.props,an.Name)}if(o.items!==!0)if(_&&!_.dynamicItems)_.items!==void 0&&(o.items=w1.mergeEvaluated.items(r,_.items,o.items));else{const b=r.var("items",(0,an._)`${m}.evaluated.items`);o.items=w1.mergeEvaluated.items(r,b,o.items,an.Name)}}}Lo.callRef=F1;Lo.default=PS;Object.defineProperty(z0,"__esModule",{value:!0});const LS=q0,VS=Lo,OS=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",LS.default,VS.default];z0.default=OS;var W0={},Z0={};Object.defineProperty(Z0,"__esModule",{value:!0});const dl=kt,Dr=dl.operators,ul={maximum:{okStr:"<=",ok:Dr.LTE,fail:Dr.GT},minimum:{okStr:">=",ok:Dr.GTE,fail:Dr.LT},exclusiveMaximum:{okStr:"<",ok:Dr.LT,fail:Dr.GTE},exclusiveMinimum:{okStr:">",ok:Dr.GT,fail:Dr.LTE}},HS={message:({keyword:e,schemaCode:t})=>(0,dl.str)`must be ${ul[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,dl._)`{comparison: ${ul[e].okStr}, limit: ${t}}`},RS={keyword:Object.keys(ul),type:"number",schemaType:"number",$data:!0,error:HS,code(e){const{keyword:t,data:a,schemaCode:n}=e;e.fail$data((0,dl._)`${a} ${ul[t].fail} ${n} || isNaN(${a})`)}};Z0.default=RS;var K0={};Object.defineProperty(K0,"__esModule",{value:!0});const vi=kt,NS={message:({schemaCode:e})=>(0,vi.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,vi._)`{multipleOf: ${e}}`},DS={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:NS,code(e){const{gen:t,data:a,schemaCode:n,it:r}=e,o=r.opts.multipleOfPrecision,s=t.let("res"),i=o?(0,vi._)`Math.abs(Math.round(${s}) - ${s}) > 1e-${o}`:(0,vi._)`${s} !== parseInt(${s})`;e.fail$data((0,vi._)`(${n} === 0 || (${s} = ${a}/${n}, ${i}))`)}};K0.default=DS;var G0={},J0={};Object.defineProperty(J0,"__esModule",{value:!0});function Q6(e){const t=e.length;let a=0,n=0,r;for(;n<t;)a++,r=e.charCodeAt(n++),r>=55296&&r<=56319&&n<t&&(r=e.charCodeAt(n),(r&64512)===56320&&n++);return a}J0.default=Q6;Q6.code='require("ajv/dist/runtime/ucs2length").default';Object.defineProperty(G0,"__esModule",{value:!0});const Mo=kt,BS=et,FS=J0,jS={message({keyword:e,schemaCode:t}){const a=e==="maxLength"?"more":"fewer";return(0,Mo.str)`must NOT have ${a} than ${t} characters`},params:({schemaCode:e})=>(0,Mo._)`{limit: ${e}}`},US={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:jS,code(e){const{keyword:t,data:a,schemaCode:n,it:r}=e,o=t==="maxLength"?Mo.operators.GT:Mo.operators.LT,s=r.opts.unicode===!1?(0,Mo._)`${a}.length`:(0,Mo._)`${(0,BS.useFunc)(e.gen,FS.default)}(${a})`;e.fail$data((0,Mo._)`${s} ${o} ${n}`)}};G0.default=US;var X0={};Object.defineProperty(X0,"__esModule",{value:!0});const zS=Pt,hl=kt,qS={message:({schemaCode:e})=>(0,hl.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,hl._)`{pattern: ${e}}`},WS={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:qS,code(e){const{data:t,$data:a,schema:n,schemaCode:r,it:o}=e,s=o.opts.unicodeRegExp?"u":"",i=a?(0,hl._)`(new RegExp(${r}, ${s}))`:(0,zS.usePattern)(e,n);e.fail$data((0,hl._)`!${i}.test(${t})`)}};X0.default=WS;var Y0={};Object.defineProperty(Y0,"__esModule",{value:!0});const gi=kt,ZS={message({keyword:e,schemaCode:t}){const a=e==="maxProperties"?"more":"fewer";return(0,gi.str)`must NOT have ${a} than ${t} properties`},params:({schemaCode:e})=>(0,gi._)`{limit: ${e}}`},KS={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:ZS,code(e){const{keyword:t,data:a,schemaCode:n}=e,r=t==="maxProperties"?gi.operators.GT:gi.operators.LT;e.fail$data((0,gi._)`Object.keys(${a}).length ${r} ${n}`)}};Y0.default=KS;var Q0={};Object.defineProperty(Q0,"__esModule",{value:!0});const Qs=Pt,yi=kt,GS=et,JS={message:({params:{missingProperty:e}})=>(0,yi.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,yi._)`{missingProperty: ${e}}`},XS={keyword:"required",type:"object",schemaType:"array",$data:!0,error:JS,code(e){const{gen:t,schema:a,schemaCode:n,data:r,$data:o,it:s}=e,{opts:i}=s;if(!o&&a.length===0)return;const l=a.length>=i.loopRequired;if(s.allErrors?c():d(),i.strictRequired){const f=e.parentSchema.properties,{definedProperties:m}=e.it;for(const g of a)if((f==null?void 0:f[g])===void 0&&!m.has(g)){const _=s.schemaEnv.baseId+s.errSchemaPath,b=`required property "${g}" is not defined at "${_}" (strictRequired)`;(0,GS.checkStrictMode)(s,b,s.opts.strictRequired)}}function c(){if(l||o)e.block$data(yi.nil,u);else for(const f of a)(0,Qs.checkReportMissingProp)(e,f)}function d(){const f=t.let("missing");if(l||o){const m=t.let("valid",!0);e.block$data(m,()=>h(f,m)),e.ok(m)}else t.if((0,Qs.checkMissingProp)(e,a,f)),(0,Qs.reportMissingProp)(e,f),t.else()}function u(){t.forOf("prop",n,f=>{e.setParams({missingProperty:f}),t.if((0,Qs.noPropertyInData)(t,r,f,i.ownProperties),()=>e.error())})}function h(f,m){e.setParams({missingProperty:f}),t.forOf(f,n,()=>{t.assign(m,(0,Qs.propertyInData)(t,r,f,i.ownProperties)),t.if((0,yi.not)(m),()=>{e.error(),t.break()})},yi.nil)}}};Q0.default=XS;var ed={};Object.defineProperty(ed,"__esModule",{value:!0});const Mi=kt,YS={message({keyword:e,schemaCode:t}){const a=e==="maxItems"?"more":"fewer";return(0,Mi.str)`must NOT have ${a} than ${t} items`},params:({schemaCode:e})=>(0,Mi._)`{limit: ${e}}`},QS={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:YS,code(e){const{keyword:t,data:a,schemaCode:n}=e,r=t==="maxItems"?Mi.operators.GT:Mi.operators.LT;e.fail$data((0,Mi._)`${a}.length ${r} ${n}`)}};ed.default=QS;var td={},Wi={};Object.defineProperty(Wi,"__esModule",{value:!0});const eg=S6;eg.code='require("ajv/dist/runtime/equal").default';Wi.default=eg;Object.defineProperty(td,"__esModule",{value:!0});const q2=Sa,Ra=kt,e$=et,t$=Wi,a$={message:({params:{i:e,j:t}})=>(0,Ra.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Ra._)`{i: ${e}, j: ${t}}`},n$={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:a$,code(e){const{gen:t,data:a,$data:n,schema:r,parentSchema:o,schemaCode:s,it:i}=e;if(!n&&!r)return;const l=t.let("valid"),c=o.items?(0,q2.getSchemaTypes)(o.items):[];e.block$data(l,d,(0,Ra._)`${s} === false`),e.ok(l);function d(){const m=t.let("i",(0,Ra._)`${a}.length`),g=t.let("j");e.setParams({i:m,j:g}),t.assign(l,!0),t.if((0,Ra._)`${m} > 1`,()=>(u()?h:f)(m,g))}function u(){return c.length>0&&!c.some(m=>m==="object"||m==="array")}function h(m,g){const _=t.name("item"),b=(0,q2.checkDataTypes)(c,_,i.opts.strictNumbers,q2.DataType.Wrong),v=t.const("indices",(0,Ra._)`{}`);t.for((0,Ra._)`;${m}--;`,()=>{t.let(_,(0,Ra._)`${a}[${m}]`),t.if(b,(0,Ra._)`continue`),c.length>1&&t.if((0,Ra._)`typeof ${_} == "string"`,(0,Ra._)`${_} += "_"`),t.if((0,Ra._)`typeof ${v}[${_}] == "number"`,()=>{t.assign(g,(0,Ra._)`${v}[${_}]`),e.error(),t.assign(l,!1).break()}).code((0,Ra._)`${v}[${_}] = ${m}`)})}function f(m,g){const _=(0,e$.useFunc)(t,t$.default),b=t.name("outer");t.label(b).for((0,Ra._)`;${m}--;`,()=>t.for((0,Ra._)`${g} = ${m}; ${g}--;`,()=>t.if((0,Ra._)`${_}(${a}[${m}], ${a}[${g}])`,()=>{e.error(),t.assign(l,!1).break(b)})))}}};td.default=n$;var ad={};Object.defineProperty(ad,"__esModule",{value:!0});const Oc=kt,r$=et,o$=Wi,s$={message:"must be equal to constant",params:({schemaCode:e})=>(0,Oc._)`{allowedValue: ${e}}`},i$={keyword:"const",$data:!0,error:s$,code(e){const{gen:t,data:a,$data:n,schemaCode:r,schema:o}=e;n||o&&typeof o=="object"?e.fail$data((0,Oc._)`!${(0,r$.useFunc)(t,o$.default)}(${a}, ${r})`):e.fail((0,Oc._)`${o} !== ${a}`)}};ad.default=i$;var nd={};Object.defineProperty(nd,"__esModule",{value:!0});const oi=kt,l$=et,c$=Wi,d$={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,oi._)`{allowedValues: ${e}}`},u$={keyword:"enum",schemaType:"array",$data:!0,error:d$,code(e){const{gen:t,data:a,$data:n,schema:r,schemaCode:o,it:s}=e;if(!n&&r.length===0)throw new Error("enum must have non-empty array");const i=r.length>=s.opts.loopEnum;let l;const c=()=>l??(l=(0,l$.useFunc)(t,c$.default));let d;if(i||n)d=t.let("valid"),e.block$data(d,u);else{if(!Array.isArray(r))throw new Error("ajv implementation error");const f=t.const("vSchema",o);d=(0,oi.or)(...r.map((m,g)=>h(f,g)))}e.pass(d);function u(){t.assign(d,!1),t.forOf("v",o,f=>t.if((0,oi._)`${c()}(${a}, ${f})`,()=>t.assign(d,!0).break()))}function h(f,m){const g=r[m];return typeof g=="object"&&g!==null?(0,oi._)`${c()}(${a}, ${f}[${m}])`:(0,oi._)`${a} === ${g}`}}};nd.default=u$;Object.defineProperty(W0,"__esModule",{value:!0});const h$=Z0,p$=K0,f$=G0,m$=X0,v$=Y0,g$=Q0,y$=ed,M$=td,_$=ad,b$=nd,w$=[h$.default,p$.default,f$.default,m$.default,v$.default,g$.default,y$.default,M$.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},_$.default,b$.default];W0.default=w$;var rd={},Os={};Object.defineProperty(Os,"__esModule",{value:!0});Os.validateAdditionalItems=void 0;const _o=kt,Hc=et,x$={message:({params:{len:e}})=>(0,_o.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,_o._)`{limit: ${e}}`},C$={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:x$,code(e){const{parentSchema:t,it:a}=e,{items:n}=t;if(!Array.isArray(n)){(0,Hc.checkStrictMode)(a,'"additionalItems" is ignored when "items" is not an array of schemas');return}tg(e,n)}};function tg(e,t){const{gen:a,schema:n,data:r,keyword:o,it:s}=e;s.items=!0;const i=a.const("len",(0,_o._)`${r}.length`);if(n===!1)e.setParams({len:t.length}),e.pass((0,_o._)`${i} <= ${t.length}`);else if(typeof n=="object"&&!(0,Hc.alwaysValidSchema)(s,n)){const c=a.var("valid",(0,_o._)`${i} <= ${t.length}`);a.if((0,_o.not)(c),()=>l(c)),e.ok(c)}function l(c){a.forRange("i",t.length,i,d=>{e.subschema({keyword:o,dataProp:d,dataPropType:Hc.Type.Num},c),s.allErrors||a.if((0,_o.not)(c),()=>a.break())})}}Os.validateAdditionalItems=tg;Os.default=C$;var od={},Hs={};Object.defineProperty(Hs,"__esModule",{value:!0});Hs.validateTuple=void 0;const ip=kt,j1=et,A$=Pt,S$={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:a}=e;if(Array.isArray(t))return ag(e,"additionalItems",t);a.items=!0,!(0,j1.alwaysValidSchema)(a,t)&&e.ok((0,A$.validateArray)(e))}};function ag(e,t,a=e.schema){const{gen:n,parentSchema:r,data:o,keyword:s,it:i}=e;d(r),i.opts.unevaluated&&a.length&&i.items!==!0&&(i.items=j1.mergeEvaluated.items(n,a.length,i.items));const l=n.name("valid"),c=n.const("len",(0,ip._)`${o}.length`);a.forEach((u,h)=>{(0,j1.alwaysValidSchema)(i,u)||(n.if((0,ip._)`${c} > ${h}`,()=>e.subschema({keyword:s,schemaProp:h,dataProp:h},l)),e.ok(l))});function d(u){const{opts:h,errSchemaPath:f}=i,m=a.length,g=m===u.minItems&&(m===u.maxItems||u[t]===!1);if(h.strictTuples&&!g){const _=`"${s}" is ${m}-tuple, but minItems or maxItems/${t} are not specified or different at path "${f}"`;(0,j1.checkStrictMode)(i,_,h.strictTuples)}}}Hs.validateTuple=ag;Hs.default=S$;Object.defineProperty(od,"__esModule",{value:!0});const $$=Hs,E$={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,$$.validateTuple)(e,"items")};od.default=E$;var sd={};Object.defineProperty(sd,"__esModule",{value:!0});const lp=kt,I$=et,k$=Pt,T$=Os,P$={message:({params:{len:e}})=>(0,lp.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,lp._)`{limit: ${e}}`},L$={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:P$,code(e){const{schema:t,parentSchema:a,it:n}=e,{prefixItems:r}=a;n.items=!0,!(0,I$.alwaysValidSchema)(n,t)&&(r?(0,T$.validateAdditionalItems)(e,r):e.ok((0,k$.validateArray)(e)))}};sd.default=L$;var id={};Object.defineProperty(id,"__esModule",{value:!0});const bn=kt,x1=et,V$={message:({params:{min:e,max:t}})=>t===void 0?(0,bn.str)`must contain at least ${e} valid item(s)`:(0,bn.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,bn._)`{minContains: ${e}}`:(0,bn._)`{minContains: ${e}, maxContains: ${t}}`},O$={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:V$,code(e){const{gen:t,schema:a,parentSchema:n,data:r,it:o}=e;let s,i;const{minContains:l,maxContains:c}=n;o.opts.next?(s=l===void 0?1:l,i=c):s=1;const d=t.const("len",(0,bn._)`${r}.length`);if(e.setParams({min:s,max:i}),i===void 0&&s===0){(0,x1.checkStrictMode)(o,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(i!==void 0&&s>i){(0,x1.checkStrictMode)(o,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,x1.alwaysValidSchema)(o,a)){let g=(0,bn._)`${d} >= ${s}`;i!==void 0&&(g=(0,bn._)`${g} && ${d} <= ${i}`),e.pass(g);return}o.items=!0;const u=t.name("valid");i===void 0&&s===1?f(u,()=>t.if(u,()=>t.break())):s===0?(t.let(u,!0),i!==void 0&&t.if((0,bn._)`${r}.length > 0`,h)):(t.let(u,!1),h()),e.result(u,()=>e.reset());function h(){const g=t.name("_valid"),_=t.let("count",0);f(g,()=>t.if(g,()=>m(_)))}function f(g,_){t.forRange("i",0,d,b=>{e.subschema({keyword:"contains",dataProp:b,dataPropType:x1.Type.Num,compositeRule:!0},g),_()})}function m(g){t.code((0,bn._)`${g}++`),i===void 0?t.if((0,bn._)`${g} >= ${s}`,()=>t.assign(u,!0).break()):(t.if((0,bn._)`${g} > ${i}`,()=>t.assign(u,!1).break()),s===1?t.assign(u,!0):t.if((0,bn._)`${g} >= ${s}`,()=>t.assign(u,!0)))}}};id.default=O$;var ng={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=kt,a=et,n=Pt;e.error={message:({params:{property:l,depsCount:c,deps:d}})=>{const u=c===1?"property":"properties";return(0,t.str)`must have ${u} ${d} when property ${l} is present`},params:({params:{property:l,depsCount:c,deps:d,missingProperty:u}})=>(0,t._)`{property: ${l},
33
+ || ${s} === "boolean" || ${r} === null`).assign(i,(0,Ct._)`[${r}]`)}}}function $C({gen:e,parentData:t,parentDataProperty:a},n){e.if((0,Ct._)`${t} !== undefined`,()=>e.assign((0,Ct._)`${t}[${a}]`,n))}function Pc(e,t,a,n=gs.Correct){const r=n===gs.Correct?Ct.operators.EQ:Ct.operators.NEQ;let o;switch(e){case"null":return(0,Ct._)`${t} ${r} null`;case"array":o=(0,Ct._)`Array.isArray(${t})`;break;case"object":o=(0,Ct._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":o=s((0,Ct._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":o=s();break;default:return(0,Ct._)`typeof ${t} ${r} ${e}`}return n===gs.Correct?o:(0,Ct.not)(o);function s(i=Ct.nil){return(0,Ct.and)((0,Ct._)`typeof ${t} == "number"`,i,a?(0,Ct._)`isFinite(${t})`:Ct.nil)}}Sa.checkDataType=Pc;function T0(e,t,a,n){if(e.length===1)return Pc(e[0],t,a,n);let r;const o=(0,M6.toHash)(e);if(o.array&&o.object){const s=(0,Ct._)`typeof ${t} != "object"`;r=o.null?s:(0,Ct._)`!${t} || ${s}`,delete o.null,delete o.array,delete o.object}else r=Ct.nil;o.number&&delete o.integer;for(const s in o)r=(0,Ct.and)(r,Pc(s,t,a,n));return r}Sa.checkDataTypes=T0;const EC={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,Ct._)`{type: ${e}}`:(0,Ct._)`{type: ${t}}`};function P0(e){const t=IC(e);(0,wC.reportError)(t,EC)}Sa.reportTypeError=P0;function IC(e){const{gen:t,data:a,schema:n}=e,r=(0,M6.schemaRefOrVal)(e,n,"type");return{gen:t,keyword:"type",data:a,schema:n.type,schemaCode:r,schemaValue:r,parentSchema:n,params:{},it:e}}var Dl={};Object.defineProperty(Dl,"__esModule",{value:!0});Dl.assignDefaults=void 0;const as=kt,kC=et;function TC(e,t){const{properties:a,items:n}=e.schema;if(t==="object"&&a)for(const r in a)Gh(e,r,a[r].default);else t==="array"&&Array.isArray(n)&&n.forEach((r,o)=>Gh(e,o,r.default))}Dl.assignDefaults=TC;function Gh(e,t,a){const{gen:n,compositeRule:r,data:o,opts:s}=e;if(a===void 0)return;const i=(0,as._)`${o}${(0,as.getProperty)(t)}`;if(r){(0,kC.checkStrictMode)(e,`default is ignored for: ${i}`);return}let l=(0,as._)`${i} === undefined`;s.useDefaults==="empty"&&(l=(0,as._)`${l} || ${i} === null || ${i} === ""`),n.if(l,(0,as._)`${i} = ${(0,as.stringify)(a)}`)}var er={},Pt={};Object.defineProperty(Pt,"__esModule",{value:!0});Pt.validateUnion=Pt.validateArray=Pt.usePattern=Pt.callValidateCode=Pt.schemaProperties=Pt.allSchemaProperties=Pt.noPropertyInData=Pt.propertyInData=Pt.isOwnProperty=Pt.hasPropFunc=Pt.reportMissingProp=Pt.checkMissingProp=Pt.checkReportMissingProp=void 0;const da=kt,L0=et,Dr=Kn,PC=et;function LC(e,t){const{gen:a,data:n,it:r}=e;a.if(O0(a,n,t,r.opts.ownProperties),()=>{e.setParams({missingProperty:(0,da._)`${t}`},!0),e.error()})}Pt.checkReportMissingProp=LC;function VC({gen:e,data:t,it:{opts:a}},n,r){return(0,da.or)(...n.map(o=>(0,da.and)(O0(e,t,o,a.ownProperties),(0,da._)`${r} = ${o}`)))}Pt.checkMissingProp=VC;function OC(e,t){e.setParams({missingProperty:t},!0),e.error()}Pt.reportMissingProp=OC;function w6(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,da._)`Object.prototype.hasOwnProperty`})}Pt.hasPropFunc=w6;function V0(e,t,a){return(0,da._)`${w6(e)}.call(${t}, ${a})`}Pt.isOwnProperty=V0;function HC(e,t,a,n){const r=(0,da._)`${t}${(0,da.getProperty)(a)} !== undefined`;return n?(0,da._)`${r} && ${V0(e,t,a)}`:r}Pt.propertyInData=HC;function O0(e,t,a,n){const r=(0,da._)`${t}${(0,da.getProperty)(a)} === undefined`;return n?(0,da.or)(r,(0,da.not)(V0(e,t,a))):r}Pt.noPropertyInData=O0;function x6(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}Pt.allSchemaProperties=x6;function RC(e,t){return x6(t).filter(a=>!(0,L0.alwaysValidSchema)(e,t[a]))}Pt.schemaProperties=RC;function NC({schemaCode:e,data:t,it:{gen:a,topSchemaRef:n,schemaPath:r,errorPath:o},it:s},i,l,c){const d=c?(0,da._)`${e}, ${t}, ${n}${r}`:t,u=[[Dr.default.instancePath,(0,da.strConcat)(Dr.default.instancePath,o)],[Dr.default.parentData,s.parentData],[Dr.default.parentDataProperty,s.parentDataProperty],[Dr.default.rootData,Dr.default.rootData]];s.opts.dynamicRef&&u.push([Dr.default.dynamicAnchors,Dr.default.dynamicAnchors]);const h=(0,da._)`${d}, ${a.object(...u)}`;return l!==da.nil?(0,da._)`${i}.call(${l}, ${h})`:(0,da._)`${i}(${h})`}Pt.callValidateCode=NC;const DC=(0,da._)`new RegExp`;function BC({gen:e,it:{opts:t}},a){const n=t.unicodeRegExp?"u":"",{regExp:r}=t.code,o=r(a,n);return e.scopeValue("pattern",{key:o.toString(),ref:o,code:(0,da._)`${r.code==="new RegExp"?DC:(0,PC.useFunc)(e,r)}(${a}, ${n})`})}Pt.usePattern=BC;function FC(e){const{gen:t,data:a,keyword:n,it:r}=e,o=t.name("valid");if(r.allErrors){const i=t.let("valid",!0);return s(()=>t.assign(i,!1)),i}return t.var(o,!0),s(()=>t.break()),o;function s(i){const l=t.const("len",(0,da._)`${a}.length`);t.forRange("i",0,l,c=>{e.subschema({keyword:n,dataProp:c,dataPropType:L0.Type.Num},o),t.if((0,da.not)(o),i)})}}Pt.validateArray=FC;function jC(e){const{gen:t,schema:a,keyword:n,it:r}=e;if(!Array.isArray(a))throw new Error("ajv implementation error");if(a.some(l=>(0,L0.alwaysValidSchema)(r,l))&&!r.opts.unevaluated)return;const s=t.let("valid",!1),i=t.name("_valid");t.block(()=>a.forEach((l,c)=>{const d=e.subschema({keyword:n,schemaProp:c,compositeRule:!0},i);t.assign(s,(0,da._)`${s} || ${i}`),e.mergeValidEvaluated(d,i)||t.if((0,da.not)(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}Pt.validateUnion=jC;Object.defineProperty(er,"__esModule",{value:!0});er.validateKeywordUsage=er.validSchemaType=er.funcKeywordCode=er.macroKeywordCode=void 0;const Ga=kt,_o=Kn,UC=Pt,zC=Vs;function qC(e,t){const{gen:a,keyword:n,schema:r,parentSchema:o,it:s}=e,i=t.macro.call(s.self,r,o,s),l=C6(a,n,i);s.opts.validateSchema!==!1&&s.self.validateSchema(i,!0);const c=a.name("valid");e.subschema({schema:i,schemaPath:Ga.nil,errSchemaPath:`${s.errSchemaPath}/${n}`,topSchemaRef:l,compositeRule:!0},c),e.pass(c,()=>e.error(!0))}er.macroKeywordCode=qC;function WC(e,t){var a;const{gen:n,keyword:r,schema:o,parentSchema:s,$data:i,it:l}=e;KC(l,t);const c=!i&&t.compile?t.compile.call(l.self,o,s,l):t.validate,d=C6(n,r,c),u=n.let("valid");e.block$data(u,h),e.ok((a=t.valid)!==null&&a!==void 0?a:u);function h(){if(t.errors===!1)g(),t.modifying&&Jh(e),_(()=>e.error());else{const b=t.async?f():m();t.modifying&&Jh(e),_(()=>ZC(e,b))}}function f(){const b=n.let("ruleErrs",null);return n.try(()=>g((0,Ga._)`await `),v=>n.assign(u,!1).if((0,Ga._)`${v} instanceof ${l.ValidationError}`,()=>n.assign(b,(0,Ga._)`${v}.errors`),()=>n.throw(v))),b}function m(){const b=(0,Ga._)`${d}.errors`;return n.assign(b,null),g(Ga.nil),b}function g(b=t.async?(0,Ga._)`await `:Ga.nil){const v=l.opts.passContext?_o.default.this:_o.default.self,y=!("compile"in t&&!i||t.schema===!1);n.assign(u,(0,Ga._)`${b}${(0,UC.callValidateCode)(e,d,v,y)}`,t.modifying)}function _(b){var v;n.if((0,Ga.not)((v=t.valid)!==null&&v!==void 0?v:u),b)}}er.funcKeywordCode=WC;function Jh(e){const{gen:t,data:a,it:n}=e;t.if(n.parentData,()=>t.assign(a,(0,Ga._)`${n.parentData}[${n.parentDataProperty}]`))}function ZC(e,t){const{gen:a}=e;a.if((0,Ga._)`Array.isArray(${t})`,()=>{a.assign(_o.default.vErrors,(0,Ga._)`${_o.default.vErrors} === null ? ${t} : ${_o.default.vErrors}.concat(${t})`).assign(_o.default.errors,(0,Ga._)`${_o.default.vErrors}.length`),(0,zC.extendErrors)(e)},()=>e.error())}function KC({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function C6(e,t,a){if(a===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof a=="function"?{ref:a}:{ref:a,code:(0,Ga.stringify)(a)})}function GC(e,t,a=!1){return!t.length||t.some(n=>n==="array"?Array.isArray(e):n==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==n||a&&typeof e>"u")}er.validSchemaType=GC;function JC({schema:e,opts:t,self:a,errSchemaPath:n},r,o){if(Array.isArray(r.keyword)?!r.keyword.includes(o):r.keyword!==o)throw new Error("ajv implementation error");const s=r.dependencies;if(s!=null&&s.some(i=>!Object.prototype.hasOwnProperty.call(e,i)))throw new Error(`parent schema must have dependencies of ${o}: ${s.join(",")}`);if(r.validateSchema&&!r.validateSchema(e[o])){const l=`keyword "${o}" value is invalid at path "${n}": `+a.errorsText(r.validateSchema.errors);if(t.validateSchema==="log")a.logger.error(l);else throw new Error(l)}}er.validateKeywordUsage=JC;var Qr={};Object.defineProperty(Qr,"__esModule",{value:!0});Qr.extendSubschemaMode=Qr.extendSubschemaData=Qr.getSubschema=void 0;const Qn=kt,A6=et;function XC(e,{keyword:t,schemaProp:a,schema:n,schemaPath:r,errSchemaPath:o,topSchemaRef:s}){if(t!==void 0&&n!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){const i=e.schema[t];return a===void 0?{schema:i,schemaPath:(0,Qn._)`${e.schemaPath}${(0,Qn.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:i[a],schemaPath:(0,Qn._)`${e.schemaPath}${(0,Qn.getProperty)(t)}${(0,Qn.getProperty)(a)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,A6.escapeFragment)(a)}`}}if(n!==void 0){if(r===void 0||o===void 0||s===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:r,topSchemaRef:s,errSchemaPath:o}}throw new Error('either "keyword" or "schema" must be passed')}Qr.getSubschema=XC;function YC(e,t,{dataProp:a,dataPropType:n,data:r,dataTypes:o,propertyName:s}){if(r!==void 0&&a!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:i}=t;if(a!==void 0){const{errorPath:c,dataPathArr:d,opts:u}=t,h=i.let("data",(0,Qn._)`${t.data}${(0,Qn.getProperty)(a)}`,!0);l(h),e.errorPath=(0,Qn.str)`${c}${(0,A6.getErrorPath)(a,n,u.jsPropertySyntax)}`,e.parentDataProperty=(0,Qn._)`${a}`,e.dataPathArr=[...d,e.parentDataProperty]}if(r!==void 0){const c=r instanceof Qn.Name?r:i.let("data",r,!0);l(c),s!==void 0&&(e.propertyName=s)}o&&(e.dataTypes=o);function l(c){e.data=c,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,c]}}Qr.extendSubschemaData=YC;function QC(e,{jtdDiscriminator:t,jtdMetadata:a,compositeRule:n,createErrors:r,allErrors:o}){n!==void 0&&(e.compositeRule=n),r!==void 0&&(e.createErrors=r),o!==void 0&&(e.allErrors=o),e.jtdDiscriminator=t,e.jtdMetadata=a}Qr.extendSubschemaMode=QC;var Na={},S6=function e(t,a){if(t===a)return!0;if(t&&a&&typeof t=="object"&&typeof a=="object"){if(t.constructor!==a.constructor)return!1;var n,r,o;if(Array.isArray(t)){if(n=t.length,n!=a.length)return!1;for(r=n;r--!==0;)if(!e(t[r],a[r]))return!1;return!0}if(t.constructor===RegExp)return t.source===a.source&&t.flags===a.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===a.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===a.toString();if(o=Object.keys(t),n=o.length,n!==Object.keys(a).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(a,o[r]))return!1;for(r=n;r--!==0;){var s=o[r];if(!e(t[s],a[s]))return!1}return!0}return t!==t&&a!==a},$6={exports:{}},Kr=$6.exports=function(e,t,a){typeof t=="function"&&(a=t,t={}),a=t.cb||a;var n=typeof a=="function"?a:a.pre||function(){},r=a.post||function(){};D1(t,n,r,e,"",e)};Kr.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Kr.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Kr.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Kr.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function D1(e,t,a,n,r,o,s,i,l,c){if(n&&typeof n=="object"&&!Array.isArray(n)){t(n,r,o,s,i,l,c);for(var d in n){var u=n[d];if(Array.isArray(u)){if(d in Kr.arrayKeywords)for(var h=0;h<u.length;h++)D1(e,t,a,u[h],r+"/"+d+"/"+h,o,r,d,n,h)}else if(d in Kr.propsKeywords){if(u&&typeof u=="object")for(var f in u)D1(e,t,a,u[f],r+"/"+d+"/"+eA(f),o,r,d,n,f)}else(d in Kr.keywords||e.allKeys&&!(d in Kr.skipKeywords))&&D1(e,t,a,u,r+"/"+d,o,r,d,n)}a(n,r,o,s,i,l,c)}}function eA(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}var tA=$6.exports;Object.defineProperty(Na,"__esModule",{value:!0});Na.getSchemaRefs=Na.resolveUrl=Na.normalizeId=Na._getFullPath=Na.getFullPath=Na.inlineRef=void 0;const aA=et,nA=S6,rA=tA,oA=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function sA(e,t=!0){return typeof e=="boolean"?!0:t===!0?!Lc(e):t?E6(e)<=t:!1}Na.inlineRef=sA;const iA=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Lc(e){for(const t in e){if(iA.has(t))return!0;const a=e[t];if(Array.isArray(a)&&a.some(Lc)||typeof a=="object"&&Lc(a))return!0}return!1}function E6(e){let t=0;for(const a in e){if(a==="$ref")return 1/0;if(t++,!oA.has(a)&&(typeof e[a]=="object"&&(0,aA.eachItem)(e[a],n=>t+=E6(n)),t===1/0))return 1/0}return t}function I6(e,t="",a){a!==!1&&(t=ys(t));const n=e.parse(t);return k6(e,n)}Na.getFullPath=I6;function k6(e,t){return e.serialize(t).split("#")[0]+"#"}Na._getFullPath=k6;const lA=/#\/?$/;function ys(e){return e?e.replace(lA,""):""}Na.normalizeId=ys;function cA(e,t,a){return a=ys(a),e.resolve(t,a)}Na.resolveUrl=cA;const dA=/^[a-z_][-a-z0-9._]*$/i;function uA(e,t){if(typeof e=="boolean")return{};const{schemaId:a,uriResolver:n}=this.opts,r=ys(e[a]||t),o={"":r},s=I6(n,r,!1),i={},l=new Set;return rA(e,{allKeys:!0},(u,h,f,m)=>{if(m===void 0)return;const g=s+h;let _=o[m];typeof u[a]=="string"&&(_=b.call(this,u[a])),v.call(this,u.$anchor),v.call(this,u.$dynamicAnchor),o[h]=_;function b(y){const M=this.opts.uriResolver.resolve;if(y=ys(_?M(_,y):y),l.has(y))throw d(y);l.add(y);let x=this.refs[y];return typeof x=="string"&&(x=this.refs[x]),typeof x=="object"?c(u,x.schema,y):y!==ys(g)&&(y[0]==="#"?(c(u,i[y],y),i[y]=u):this.refs[y]=g),y}function v(y){if(typeof y=="string"){if(!dA.test(y))throw new Error(`invalid anchor "${y}"`);b.call(this,`#${y}`)}}}),i;function c(u,h,f){if(h!==void 0&&!nA(u,h))throw d(f)}function d(u){return new Error(`reference "${u}" resolves to more than one schema`)}}Na.getSchemaRefs=uA;Object.defineProperty(Sn,"__esModule",{value:!0});Sn.getData=Sn.KeywordCxt=Sn.validateFunctionCode=void 0;const T6=Ss,Xh=Sa,H0=xr,cl=Sa,hA=Dl,mi=er,j2=Qr,lt=kt,yt=Kn,pA=Na,Cr=et,Qs=Vs;function fA(e){if(V6(e)&&(O6(e),L6(e))){gA(e);return}P6(e,()=>(0,T6.topBoolOrEmptySchema)(e))}Sn.validateFunctionCode=fA;function P6({gen:e,validateName:t,schema:a,schemaEnv:n,opts:r},o){r.code.es5?e.func(t,(0,lt._)`${yt.default.data}, ${yt.default.valCxt}`,n.$async,()=>{e.code((0,lt._)`"use strict"; ${Yh(a,r)}`),vA(e,r),e.code(o)}):e.func(t,(0,lt._)`${yt.default.data}, ${mA(r)}`,n.$async,()=>e.code(Yh(a,r)).code(o))}function mA(e){return(0,lt._)`{${yt.default.instancePath}="", ${yt.default.parentData}, ${yt.default.parentDataProperty}, ${yt.default.rootData}=${yt.default.data}${e.dynamicRef?(0,lt._)`, ${yt.default.dynamicAnchors}={}`:lt.nil}}={}`}function vA(e,t){e.if(yt.default.valCxt,()=>{e.var(yt.default.instancePath,(0,lt._)`${yt.default.valCxt}.${yt.default.instancePath}`),e.var(yt.default.parentData,(0,lt._)`${yt.default.valCxt}.${yt.default.parentData}`),e.var(yt.default.parentDataProperty,(0,lt._)`${yt.default.valCxt}.${yt.default.parentDataProperty}`),e.var(yt.default.rootData,(0,lt._)`${yt.default.valCxt}.${yt.default.rootData}`),t.dynamicRef&&e.var(yt.default.dynamicAnchors,(0,lt._)`${yt.default.valCxt}.${yt.default.dynamicAnchors}`)},()=>{e.var(yt.default.instancePath,(0,lt._)`""`),e.var(yt.default.parentData,(0,lt._)`undefined`),e.var(yt.default.parentDataProperty,(0,lt._)`undefined`),e.var(yt.default.rootData,yt.default.data),t.dynamicRef&&e.var(yt.default.dynamicAnchors,(0,lt._)`{}`)})}function gA(e){const{schema:t,opts:a,gen:n}=e;P6(e,()=>{a.$comment&&t.$comment&&R6(e),wA(e),n.let(yt.default.vErrors,null),n.let(yt.default.errors,0),a.unevaluated&&yA(e),H6(e),AA(e)})}function yA(e){const{gen:t,validateName:a}=e;e.evaluated=t.const("evaluated",(0,lt._)`${a}.evaluated`),t.if((0,lt._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,lt._)`${e.evaluated}.props`,(0,lt._)`undefined`)),t.if((0,lt._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,lt._)`${e.evaluated}.items`,(0,lt._)`undefined`))}function Yh(e,t){const a=typeof e=="object"&&e[t.schemaId];return a&&(t.code.source||t.code.process)?(0,lt._)`/*# sourceURL=${a} */`:lt.nil}function MA(e,t){if(V6(e)&&(O6(e),L6(e))){_A(e,t);return}(0,T6.boolOrEmptySchema)(e,t)}function L6({schema:e,self:t}){if(typeof e=="boolean")return!e;for(const a in e)if(t.RULES.all[a])return!0;return!1}function V6(e){return typeof e.schema!="boolean"}function _A(e,t){const{schema:a,gen:n,opts:r}=e;r.$comment&&a.$comment&&R6(e),xA(e),CA(e);const o=n.const("_errs",yt.default.errors);H6(e,o),n.var(t,(0,lt._)`${o} === ${yt.default.errors}`)}function O6(e){(0,Cr.checkUnknownRules)(e),bA(e)}function H6(e,t){if(e.opts.jtd)return Qh(e,[],!1,t);const a=(0,Xh.getSchemaTypes)(e.schema),n=(0,Xh.coerceAndCheckDataType)(e,a);Qh(e,a,!n,t)}function bA(e){const{schema:t,errSchemaPath:a,opts:n,self:r}=e;t.$ref&&n.ignoreKeywordsWithRef&&(0,Cr.schemaHasRulesButRef)(t,r.RULES)&&r.logger.warn(`$ref: keywords ignored in schema at path "${a}"`)}function wA(e){const{schema:t,opts:a}=e;t.default!==void 0&&a.useDefaults&&a.strictSchema&&(0,Cr.checkStrictMode)(e,"default is ignored in the schema root")}function xA(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,pA.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function CA(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function R6({gen:e,schemaEnv:t,schema:a,errSchemaPath:n,opts:r}){const o=a.$comment;if(r.$comment===!0)e.code((0,lt._)`${yt.default.self}.logger.log(${o})`);else if(typeof r.$comment=="function"){const s=(0,lt.str)`${n}/$comment`,i=e.scopeValue("root",{ref:t.root});e.code((0,lt._)`${yt.default.self}.opts.$comment(${o}, ${s}, ${i}.schema)`)}}function AA(e){const{gen:t,schemaEnv:a,validateName:n,ValidationError:r,opts:o}=e;a.$async?t.if((0,lt._)`${yt.default.errors} === 0`,()=>t.return(yt.default.data),()=>t.throw((0,lt._)`new ${r}(${yt.default.vErrors})`)):(t.assign((0,lt._)`${n}.errors`,yt.default.vErrors),o.unevaluated&&SA(e),t.return((0,lt._)`${yt.default.errors} === 0`))}function SA({gen:e,evaluated:t,props:a,items:n}){a instanceof lt.Name&&e.assign((0,lt._)`${t}.props`,a),n instanceof lt.Name&&e.assign((0,lt._)`${t}.items`,n)}function Qh(e,t,a,n){const{gen:r,schema:o,data:s,allErrors:i,opts:l,self:c}=e,{RULES:d}=c;if(o.$ref&&(l.ignoreKeywordsWithRef||!(0,Cr.schemaHasRulesButRef)(o,d))){r.block(()=>B6(e,"$ref",d.all.$ref.definition));return}l.jtd||$A(e,t),r.block(()=>{for(const h of d.rules)u(h);u(d.post)});function u(h){(0,H0.shouldUseGroup)(o,h)&&(h.type?(r.if((0,cl.checkDataType)(h.type,s,l.strictNumbers)),ep(e,h),t.length===1&&t[0]===h.type&&a&&(r.else(),(0,cl.reportTypeError)(e)),r.endIf()):ep(e,h),i||r.if((0,lt._)`${yt.default.errors} === ${n||0}`))}}function ep(e,t){const{gen:a,schema:n,opts:{useDefaults:r}}=e;r&&(0,hA.assignDefaults)(e,t.type),a.block(()=>{for(const o of t.rules)(0,H0.shouldUseRule)(n,o)&&B6(e,o.keyword,o.definition,t.type)})}function $A(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(EA(e,t),e.opts.allowUnionTypes||IA(e,t),kA(e,e.dataTypes))}function EA(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(a=>{N6(e.dataTypes,a)||R0(e,`type "${a}" not allowed by context "${e.dataTypes.join(",")}"`)}),PA(e,t)}}function IA(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&R0(e,"use allowUnionTypes to allow union type keyword")}function kA(e,t){const a=e.self.RULES.all;for(const n in a){const r=a[n];if(typeof r=="object"&&(0,H0.shouldUseRule)(e.schema,r)){const{type:o}=r.definition;o.length&&!o.some(s=>TA(t,s))&&R0(e,`missing type "${o.join(",")}" for keyword "${n}"`)}}}function TA(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function N6(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function PA(e,t){const a=[];for(const n of e.dataTypes)N6(t,n)?a.push(n):t.includes("integer")&&n==="number"&&a.push("integer");e.dataTypes=a}function R0(e,t){const a=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${a}" (strictTypes)`,(0,Cr.checkStrictMode)(e,t,e.opts.strictTypes)}class D6{constructor(t,a,n){if((0,mi.validateKeywordUsage)(t,a,n),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=n,this.data=t.data,this.schema=t.schema[n],this.$data=a.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Cr.schemaRefOrVal)(t,this.schema,n,this.$data),this.schemaType=a.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=a,this.$data)this.schemaCode=t.gen.const("vSchema",F6(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,mi.validSchemaType)(this.schema,a.schemaType,a.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(a.schemaType)}`);("code"in a?a.trackErrors:a.errors!==!1)&&(this.errsCount=t.gen.const("_errs",yt.default.errors))}result(t,a,n){this.failResult((0,lt.not)(t),a,n)}failResult(t,a,n){this.gen.if(t),n?n():this.error(),a?(this.gen.else(),a(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,a){this.failResult((0,lt.not)(t),void 0,a)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);const{schemaCode:a}=this;this.fail((0,lt._)`${a} !== undefined && (${(0,lt.or)(this.invalid$data(),t)})`)}error(t,a,n){if(a){this.setParams(a),this._error(t,n),this.setParams({});return}this._error(t,n)}_error(t,a){(t?Qs.reportExtraError:Qs.reportError)(this,this.def.error,a)}$dataError(){(0,Qs.reportError)(this,this.def.$dataError||Qs.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,Qs.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,a){a?Object.assign(this.params,t):this.params=t}block$data(t,a,n=lt.nil){this.gen.block(()=>{this.check$data(t,n),a()})}check$data(t=lt.nil,a=lt.nil){if(!this.$data)return;const{gen:n,schemaCode:r,schemaType:o,def:s}=this;n.if((0,lt.or)((0,lt._)`${r} === undefined`,a)),t!==lt.nil&&n.assign(t,!0),(o.length||s.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),t!==lt.nil&&n.assign(t,!1)),n.else()}invalid$data(){const{gen:t,schemaCode:a,schemaType:n,def:r,it:o}=this;return(0,lt.or)(s(),i());function s(){if(n.length){if(!(a instanceof lt.Name))throw new Error("ajv implementation error");const l=Array.isArray(n)?n:[n];return(0,lt._)`${(0,cl.checkDataTypes)(l,a,o.opts.strictNumbers,cl.DataType.Wrong)}`}return lt.nil}function i(){if(r.validateSchema){const l=t.scopeValue("validate$data",{ref:r.validateSchema});return(0,lt._)`!${l}(${a})`}return lt.nil}}subschema(t,a){const n=(0,j2.getSubschema)(this.it,t);(0,j2.extendSubschemaData)(n,this.it,t),(0,j2.extendSubschemaMode)(n,t);const r={...this.it,...n,items:void 0,props:void 0};return MA(r,a),r}mergeEvaluated(t,a){const{it:n,gen:r}=this;n.opts.unevaluated&&(n.props!==!0&&t.props!==void 0&&(n.props=Cr.mergeEvaluated.props(r,t.props,n.props,a)),n.items!==!0&&t.items!==void 0&&(n.items=Cr.mergeEvaluated.items(r,t.items,n.items,a)))}mergeValidEvaluated(t,a){const{it:n,gen:r}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return r.if(a,()=>this.mergeEvaluated(t,lt.Name)),!0}}Sn.KeywordCxt=D6;function B6(e,t,a,n){const r=new D6(e,a,t);"code"in a?a.code(r,n):r.$data&&a.validate?(0,mi.funcKeywordCode)(r,a):"macro"in a?(0,mi.macroKeywordCode)(r,a):(a.compile||a.validate)&&(0,mi.funcKeywordCode)(r,a)}const LA=/^\/(?:[^~]|~0|~1)*$/,VA=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function F6(e,{dataLevel:t,dataNames:a,dataPathArr:n}){let r,o;if(e==="")return yt.default.rootData;if(e[0]==="/"){if(!LA.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);r=e,o=yt.default.rootData}else{const c=VA.exec(e);if(!c)throw new Error(`Invalid JSON-pointer: ${e}`);const d=+c[1];if(r=c[2],r==="#"){if(d>=t)throw new Error(l("property/index",d));return n[t-d]}if(d>t)throw new Error(l("data",d));if(o=a[t-d],!r)return o}let s=o;const i=r.split("/");for(const c of i)c&&(o=(0,lt._)`${o}${(0,lt.getProperty)((0,Cr.unescapeJsonPointer)(c))}`,s=(0,lt._)`${s} && ${o}`);return s;function l(c,d){return`Cannot access ${c} ${d} levels up, current level is ${t}`}}Sn.getData=F6;var qi={};Object.defineProperty(qi,"__esModule",{value:!0});class OA extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}}qi.default=OA;var Os={};Object.defineProperty(Os,"__esModule",{value:!0});const U2=Na;class HA extends Error{constructor(t,a,n,r){super(r||`can't resolve reference ${n} from id ${a}`),this.missingRef=(0,U2.resolveUrl)(t,a,n),this.missingSchema=(0,U2.normalizeId)((0,U2.getFullPath)(t,this.missingRef))}}Os.default=HA;var on={};Object.defineProperty(on,"__esModule",{value:!0});on.resolveSchema=on.getCompilingSchema=on.resolveRef=on.compileSchema=on.SchemaEnv=void 0;const On=kt,RA=qi,go=Kn,Dn=Na,tp=et,NA=Sn;class Bl{constructor(t){var a;this.refs={},this.dynamicAnchors={};let n;typeof t.schema=="object"&&(n=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(a=t.baseId)!==null&&a!==void 0?a:(0,Dn.normalizeId)(n==null?void 0:n[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=n==null?void 0:n.$async,this.refs={}}}on.SchemaEnv=Bl;function N0(e){const t=j6.call(this,e);if(t)return t;const a=(0,Dn.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:n,lines:r}=this.opts.code,{ownProperties:o}=this.opts,s=new On.CodeGen(this.scope,{es5:n,lines:r,ownProperties:o});let i;e.$async&&(i=s.scopeValue("Error",{ref:RA.default,code:(0,On._)`require("ajv/dist/runtime/validation_error").default`}));const l=s.scopeName("validate");e.validateName=l;const c={gen:s,allErrors:this.opts.allErrors,data:go.default.data,parentData:go.default.parentData,parentDataProperty:go.default.parentDataProperty,dataNames:[go.default.data],dataPathArr:[On.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,On.stringify)(e.schema)}:{ref:e.schema}),validateName:l,ValidationError:i,schema:e.schema,schemaEnv:e,rootId:a,baseId:e.baseId||a,schemaPath:On.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,On._)`""`,opts:this.opts,self:this};let d;try{this._compilations.add(e),(0,NA.validateFunctionCode)(c),s.optimize(this.opts.code.optimize);const u=s.toString();d=`${s.scopeRefs(go.default.scope)}return ${u}`,this.opts.code.process&&(d=this.opts.code.process(d,e));const f=new Function(`${go.default.self}`,`${go.default.scope}`,d)(this,this.scope.get());if(this.scope.value(l,{ref:f}),f.errors=null,f.schema=e.schema,f.schemaEnv=e,e.$async&&(f.$async=!0),this.opts.code.source===!0&&(f.source={validateName:l,validateCode:u,scopeValues:s._values}),this.opts.unevaluated){const{props:m,items:g}=c;f.evaluated={props:m instanceof On.Name?void 0:m,items:g instanceof On.Name?void 0:g,dynamicProps:m instanceof On.Name,dynamicItems:g instanceof On.Name},f.source&&(f.source.evaluated=(0,On.stringify)(f.evaluated))}return e.validate=f,e}catch(u){throw delete e.validate,delete e.validateName,d&&this.logger.error("Error compiling schema, function code:",d),u}finally{this._compilations.delete(e)}}on.compileSchema=N0;function DA(e,t,a){var n;a=(0,Dn.resolveUrl)(this.opts.uriResolver,t,a);const r=e.refs[a];if(r)return r;let o=jA.call(this,e,a);if(o===void 0){const s=(n=e.localRefs)===null||n===void 0?void 0:n[a],{schemaId:i}=this.opts;s&&(o=new Bl({schema:s,schemaId:i,root:e,baseId:t}))}if(o!==void 0)return e.refs[a]=BA.call(this,o)}on.resolveRef=DA;function BA(e){return(0,Dn.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:N0.call(this,e)}function j6(e){for(const t of this._compilations)if(FA(t,e))return t}on.getCompilingSchema=j6;function FA(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function jA(e,t){let a;for(;typeof(a=this.refs[t])=="string";)t=a;return a||this.schemas[t]||Fl.call(this,e,t)}function Fl(e,t){const a=this.opts.uriResolver.parse(t),n=(0,Dn._getFullPath)(this.opts.uriResolver,a);let r=(0,Dn.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&n===r)return z2.call(this,a,e);const o=(0,Dn.normalizeId)(n),s=this.refs[o]||this.schemas[o];if(typeof s=="string"){const i=Fl.call(this,e,s);return typeof(i==null?void 0:i.schema)!="object"?void 0:z2.call(this,a,i)}if(typeof(s==null?void 0:s.schema)=="object"){if(s.validate||N0.call(this,s),o===(0,Dn.normalizeId)(t)){const{schema:i}=s,{schemaId:l}=this.opts,c=i[l];return c&&(r=(0,Dn.resolveUrl)(this.opts.uriResolver,r,c)),new Bl({schema:i,schemaId:l,root:e,baseId:r})}return z2.call(this,a,s)}}on.resolveSchema=Fl;const UA=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function z2(e,{baseId:t,schema:a,root:n}){var r;if(((r=e.fragment)===null||r===void 0?void 0:r[0])!=="/")return;for(const i of e.fragment.slice(1).split("/")){if(typeof a=="boolean")return;const l=a[(0,tp.unescapeFragment)(i)];if(l===void 0)return;a=l;const c=typeof a=="object"&&a[this.opts.schemaId];!UA.has(i)&&c&&(t=(0,Dn.resolveUrl)(this.opts.uriResolver,t,c))}let o;if(typeof a!="boolean"&&a.$ref&&!(0,tp.schemaHasRulesButRef)(a,this.RULES)){const i=(0,Dn.resolveUrl)(this.opts.uriResolver,t,a.$ref);o=Fl.call(this,n,i)}const{schemaId:s}=this.opts;if(o=o||new Bl({schema:a,schemaId:s,root:n,baseId:t}),o.schema!==o.root.schema)return o}const zA="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",qA="Meta-schema for $data reference (JSON AnySchema extension proposal)",WA="object",ZA=["$data"],KA={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},GA=!1,JA={$id:zA,description:qA,type:WA,required:ZA,properties:KA,additionalProperties:GA};var D0={},jl={exports:{}};const XA={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};var YA={HEX:XA};const{HEX:QA}=YA;function U6(e){if(q6(e,".")<3)return{host:e,isIPV4:!1};const t=e.match(/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/u)||[],[a]=t;return a?{host:tS(a,"."),isIPV4:!0}:{host:e,isIPV4:!1}}function Vc(e,t=!1){let a="",n=!0;for(const r of e){if(QA[r]===void 0)return;r!=="0"&&n===!0&&(n=!1),n||(a+=r)}return t&&a.length===0&&(a="0"),a}function eS(e){let t=0;const a={error:!1,address:"",zone:""},n=[],r=[];let o=!1,s=!1,i=!1;function l(){if(r.length){if(o===!1){const c=Vc(r);if(c!==void 0)n.push(c);else return a.error=!0,!1}r.length=0}return!0}for(let c=0;c<e.length;c++){const d=e[c];if(!(d==="["||d==="]"))if(d===":"){if(s===!0&&(i=!0),!l())break;if(t++,n.push(":"),t>7){a.error=!0;break}c-1>=0&&e[c-1]===":"&&(s=!0);continue}else if(d==="%"){if(!l())break;o=!0}else{r.push(d);continue}}return r.length&&(o?a.zone=r.join(""):i?n.push(r.join("")):n.push(Vc(r))),a.address=n.join(""),a}function z6(e,t={}){if(q6(e,":")<2)return{host:e,isIPV6:!1};const a=eS(e);if(a.error)return{host:e,isIPV6:!1};{let n=a.address,r=a.address;return a.zone&&(n+="%"+a.zone,r+="%25"+a.zone),{host:n,escapedHost:r,isIPV6:!0}}}function tS(e,t){let a="",n=!0;const r=e.length;for(let o=0;o<r;o++){const s=e[o];s==="0"&&n?(o+1<=r&&e[o+1]===t||o+1===r)&&(a+=s,n=!1):(s===t?n=!0:n=!1,a+=s)}return a}function q6(e,t){let a=0;for(let n=0;n<e.length;n++)e[n]===t&&a++;return a}const ap=/^\.\.?\//u,np=/^\/\.(?:\/|$)/u,rp=/^\/\.\.(?:\/|$)/u,aS=/^\/?(?:.|\n)*?(?=\/|$)/u;function nS(e){const t=[];for(;e.length;)if(e.match(ap))e=e.replace(ap,"");else if(e.match(np))e=e.replace(np,"/");else if(e.match(rp))e=e.replace(rp,"/"),t.pop();else if(e==="."||e==="..")e="";else{const a=e.match(aS);if(a){const n=a[0];e=e.slice(n.length),t.push(n)}else throw new Error("Unexpected dot segment condition")}return t.join("")}function rS(e,t){const a=t!==!0?escape:unescape;return e.scheme!==void 0&&(e.scheme=a(e.scheme)),e.userinfo!==void 0&&(e.userinfo=a(e.userinfo)),e.host!==void 0&&(e.host=a(e.host)),e.path!==void 0&&(e.path=a(e.path)),e.query!==void 0&&(e.query=a(e.query)),e.fragment!==void 0&&(e.fragment=a(e.fragment)),e}function oS(e,t){const a=[];if(e.userinfo!==void 0&&(a.push(e.userinfo),a.push("@")),e.host!==void 0){let n=unescape(e.host);const r=U6(n);if(r.isIPV4)n=r.host;else{const o=z6(r.host,{isIPV4:!1});o.isIPV6===!0?n=`[${o.escapedHost}]`:n=e.host}a.push(n)}return(typeof e.port=="number"||typeof e.port=="string")&&(a.push(":"),a.push(String(e.port))),a.length?a.join(""):void 0}var sS={recomposeAuthority:oS,normalizeComponentEncoding:rS,removeDotSegments:nS,normalizeIPv4:U6,normalizeIPv6:z6,stringArrayToHexStripped:Vc};const iS=/^[\da-f]{8}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{12}$/iu,lS=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;function W6(e){return typeof e.secure=="boolean"?e.secure:String(e.scheme).toLowerCase()==="wss"}function Z6(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function K6(e){const t=String(e.scheme).toLowerCase()==="https";return(e.port===(t?443:80)||e.port==="")&&(e.port=void 0),e.path||(e.path="/"),e}function cS(e){return e.secure=W6(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function dS(e){if((e.port===(W6(e)?443:80)||e.port==="")&&(e.port=void 0),typeof e.secure=="boolean"&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){const[t,a]=e.resourceName.split("?");e.path=t&&t!=="/"?t:void 0,e.query=a,e.resourceName=void 0}return e.fragment=void 0,e}function uS(e,t){if(!e.path)return e.error="URN can not be parsed",e;const a=e.path.match(lS);if(a){const n=t.scheme||e.scheme||"urn";e.nid=a[1].toLowerCase(),e.nss=a[2];const r=`${n}:${t.nid||e.nid}`,o=B0[r];e.path=void 0,o&&(e=o.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e}function hS(e,t){const a=t.scheme||e.scheme||"urn",n=e.nid.toLowerCase(),r=`${a}:${t.nid||n}`,o=B0[r];o&&(e=o.serialize(e,t));const s=e,i=e.nss;return s.path=`${n||t.nid}:${i}`,t.skipEscape=!0,s}function pS(e,t){const a=e;return a.uuid=a.nss,a.nss=void 0,!t.tolerant&&(!a.uuid||!iS.test(a.uuid))&&(a.error=a.error||"UUID is not valid."),a}function fS(e){const t=e;return t.nss=(e.uuid||"").toLowerCase(),t}const G6={scheme:"http",domainHost:!0,parse:Z6,serialize:K6},mS={scheme:"https",domainHost:G6.domainHost,parse:Z6,serialize:K6},B1={scheme:"ws",domainHost:!0,parse:cS,serialize:dS},vS={scheme:"wss",domainHost:B1.domainHost,parse:B1.parse,serialize:B1.serialize},gS={scheme:"urn",parse:uS,serialize:hS,skipNormalize:!0},yS={scheme:"urn:uuid",parse:pS,serialize:fS,skipNormalize:!0},B0={http:G6,https:mS,ws:B1,wss:vS,urn:gS,"urn:uuid":yS};var MS=B0;const{normalizeIPv6:_S,normalizeIPv4:bS,removeDotSegments:oi,recomposeAuthority:wS,normalizeComponentEncoding:b1}=sS,F0=MS;function xS(e,t){return typeof e=="string"?e=tr(Er(e,t),t):typeof e=="object"&&(e=Er(tr(e,t),t)),e}function CS(e,t,a){const n=Object.assign({scheme:"null"},a),r=J6(Er(e,n),Er(t,n),n,!0);return tr(r,{...n,skipEscape:!0})}function J6(e,t,a,n){const r={};return n||(e=Er(tr(e,a),a),t=Er(tr(t,a),a)),a=a||{},!a.tolerant&&t.scheme?(r.scheme=t.scheme,r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=oi(t.path||""),r.query=t.query):(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0?(r.userinfo=t.userinfo,r.host=t.host,r.port=t.port,r.path=oi(t.path||""),r.query=t.query):(t.path?(t.path.charAt(0)==="/"?r.path=oi(t.path):((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path?r.path="/"+t.path:e.path?r.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:r.path=t.path,r.path=oi(r.path)),r.query=t.query):(r.path=e.path,t.query!==void 0?r.query=t.query:r.query=e.query),r.userinfo=e.userinfo,r.host=e.host,r.port=e.port),r.scheme=e.scheme),r.fragment=t.fragment,r}function AS(e,t,a){return typeof e=="string"?(e=unescape(e),e=tr(b1(Er(e,a),!0),{...a,skipEscape:!0})):typeof e=="object"&&(e=tr(b1(e,!0),{...a,skipEscape:!0})),typeof t=="string"?(t=unescape(t),t=tr(b1(Er(t,a),!0),{...a,skipEscape:!0})):typeof t=="object"&&(t=tr(b1(t,!0),{...a,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()}function tr(e,t){const a={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},n=Object.assign({},t),r=[],o=F0[(n.scheme||a.scheme||"").toLowerCase()];o&&o.serialize&&o.serialize(a,n),a.path!==void 0&&(n.skipEscape?a.path=unescape(a.path):(a.path=escape(a.path),a.scheme!==void 0&&(a.path=a.path.split("%3A").join(":")))),n.reference!=="suffix"&&a.scheme&&r.push(a.scheme,":");const s=wS(a,n);if(s!==void 0&&(n.reference!=="suffix"&&r.push("//"),r.push(s),a.path&&a.path.charAt(0)!=="/"&&r.push("/")),a.path!==void 0){let i=a.path;!n.absolutePath&&(!o||!o.absolutePath)&&(i=oi(i)),s===void 0&&(i=i.replace(/^\/\//u,"/%2F")),r.push(i)}return a.query!==void 0&&r.push("?",a.query),a.fragment!==void 0&&r.push("#",a.fragment),r.join("")}const SS=Array.from({length:127},(e,t)=>/[^!"$&'()*+,\-.;=_`a-z{}~]/u.test(String.fromCharCode(t)));function $S(e){let t=0;for(let a=0,n=e.length;a<n;++a)if(t=e.charCodeAt(a),t>126||SS[t])return!0;return!1}const ES=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function Er(e,t){const a=Object.assign({},t),n={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},r=e.indexOf("%")!==-1;let o=!1;a.reference==="suffix"&&(e=(a.scheme?a.scheme+":":"")+"//"+e);const s=e.match(ES);if(s){if(n.scheme=s[1],n.userinfo=s[3],n.host=s[4],n.port=parseInt(s[5],10),n.path=s[6]||"",n.query=s[7],n.fragment=s[8],isNaN(n.port)&&(n.port=s[5]),n.host){const l=bS(n.host);if(l.isIPV4===!1){const c=_S(l.host,{isIPV4:!1});n.host=c.host.toLowerCase(),o=c.isIPV6}else n.host=l.host,o=!0}n.scheme===void 0&&n.userinfo===void 0&&n.host===void 0&&n.port===void 0&&!n.path&&n.query===void 0?n.reference="same-document":n.scheme===void 0?n.reference="relative":n.fragment===void 0?n.reference="absolute":n.reference="uri",a.reference&&a.reference!=="suffix"&&a.reference!==n.reference&&(n.error=n.error||"URI is not a "+a.reference+" reference.");const i=F0[(a.scheme||n.scheme||"").toLowerCase()];if(!a.unicodeSupport&&(!i||!i.unicodeSupport)&&n.host&&(a.domainHost||i&&i.domainHost)&&o===!1&&$S(n.host))try{n.host=URL.domainToASCII(n.host.toLowerCase())}catch(l){n.error=n.error||"Host's domain name can not be converted to ASCII: "+l}(!i||i&&!i.skipNormalize)&&(r&&n.scheme!==void 0&&(n.scheme=unescape(n.scheme)),r&&n.host!==void 0&&(n.host=unescape(n.host)),n.path!==void 0&&n.path.length&&(n.path=escape(unescape(n.path))),n.fragment!==void 0&&n.fragment.length&&(n.fragment=encodeURI(decodeURIComponent(n.fragment)))),i&&i.parse&&i.parse(n,a)}else n.error=n.error||"URI can not be parsed.";return n}const j0={SCHEMES:F0,normalize:xS,resolve:CS,resolveComponents:J6,equal:AS,serialize:tr,parse:Er};jl.exports=j0;jl.exports.default=j0;jl.exports.fastUri=j0;var IS=jl.exports;Object.defineProperty(D0,"__esModule",{value:!0});const X6=IS;X6.code='require("ajv/dist/runtime/uri").default';D0.default=X6;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=void 0;var t=Sn;Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return t.KeywordCxt}});var a=kt;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return a._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return a.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return a.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return a.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return a.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return a.CodeGen}});const n=qi,r=Os,o=Lo,s=on,i=kt,l=Na,c=Sa,d=et,u=JA,h=D0,f=(G,T)=>new RegExp(G,T);f.code="new RegExp";const m=["removeAdditional","useDefaults","coerceTypes"],g=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),_={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},b={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},v=200;function y(G){var T,O,k,C,P,ae,xe,ve,ze,Ye,ct,xt,D,q,he,me,_e,Ae,pe,ce,ue,I,B,N,U;const se=G.strict,Se=(T=G.code)===null||T===void 0?void 0:T.optimize,Ne=Se===!0||Se===void 0?1:Se||0,ut=(k=(O=G.code)===null||O===void 0?void 0:O.regExp)!==null&&k!==void 0?k:f,ie=(C=G.uriResolver)!==null&&C!==void 0?C:h.default;return{strictSchema:(ae=(P=G.strictSchema)!==null&&P!==void 0?P:se)!==null&&ae!==void 0?ae:!0,strictNumbers:(ve=(xe=G.strictNumbers)!==null&&xe!==void 0?xe:se)!==null&&ve!==void 0?ve:!0,strictTypes:(Ye=(ze=G.strictTypes)!==null&&ze!==void 0?ze:se)!==null&&Ye!==void 0?Ye:"log",strictTuples:(xt=(ct=G.strictTuples)!==null&&ct!==void 0?ct:se)!==null&&xt!==void 0?xt:"log",strictRequired:(q=(D=G.strictRequired)!==null&&D!==void 0?D:se)!==null&&q!==void 0?q:!1,code:G.code?{...G.code,optimize:Ne,regExp:ut}:{optimize:Ne,regExp:ut},loopRequired:(he=G.loopRequired)!==null&&he!==void 0?he:v,loopEnum:(me=G.loopEnum)!==null&&me!==void 0?me:v,meta:(_e=G.meta)!==null&&_e!==void 0?_e:!0,messages:(Ae=G.messages)!==null&&Ae!==void 0?Ae:!0,inlineRefs:(pe=G.inlineRefs)!==null&&pe!==void 0?pe:!0,schemaId:(ce=G.schemaId)!==null&&ce!==void 0?ce:"$id",addUsedSchema:(ue=G.addUsedSchema)!==null&&ue!==void 0?ue:!0,validateSchema:(I=G.validateSchema)!==null&&I!==void 0?I:!0,validateFormats:(B=G.validateFormats)!==null&&B!==void 0?B:!0,unicodeRegExp:(N=G.unicodeRegExp)!==null&&N!==void 0?N:!0,int32range:(U=G.int32range)!==null&&U!==void 0?U:!0,uriResolver:ie}}class M{constructor(T={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,T=this.opts={...T,...y(T)};const{es5:O,lines:k}=this.opts.code;this.scope=new i.ValueScope({scope:{},prefixes:g,es5:O,lines:k}),this.logger=oe(T.logger);const C=T.validateFormats;T.validateFormats=!1,this.RULES=(0,o.getRules)(),x.call(this,_,T,"NOT SUPPORTED"),x.call(this,b,T,"DEPRECATED","warn"),this._metaOpts=J.call(this),T.formats&&F.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),T.keywords&&te.call(this,T.keywords),typeof T.meta=="object"&&this.addMetaSchema(T.meta),L.call(this),T.validateFormats=C}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:T,meta:O,schemaId:k}=this.opts;let C=u;k==="id"&&(C={...u},C.id=C.$id,delete C.$id),O&&T&&this.addMetaSchema(C,C[k],!1)}defaultMeta(){const{meta:T,schemaId:O}=this.opts;return this.opts.defaultMeta=typeof T=="object"?T[O]||T:void 0}validate(T,O){let k;if(typeof T=="string"){if(k=this.getSchema(T),!k)throw new Error(`no schema with key or ref "${T}"`)}else k=this.compile(T);const C=k(O);return"$async"in k||(this.errors=k.errors),C}compile(T,O){const k=this._addSchema(T,O);return k.validate||this._compileSchemaEnv(k)}compileAsync(T,O){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:k}=this.opts;return C.call(this,T,O);async function C(Ye,ct){await P.call(this,Ye.$schema);const xt=this._addSchema(Ye,ct);return xt.validate||ae.call(this,xt)}async function P(Ye){Ye&&!this.getSchema(Ye)&&await C.call(this,{$ref:Ye},!0)}async function ae(Ye){try{return this._compileSchemaEnv(Ye)}catch(ct){if(!(ct instanceof r.default))throw ct;return xe.call(this,ct),await ve.call(this,ct.missingSchema),ae.call(this,Ye)}}function xe({missingSchema:Ye,missingRef:ct}){if(this.refs[Ye])throw new Error(`AnySchema ${Ye} is loaded but ${ct} cannot be resolved`)}async function ve(Ye){const ct=await ze.call(this,Ye);this.refs[Ye]||await P.call(this,ct.$schema),this.refs[Ye]||this.addSchema(ct,Ye,O)}async function ze(Ye){const ct=this._loading[Ye];if(ct)return ct;try{return await(this._loading[Ye]=k(Ye))}finally{delete this._loading[Ye]}}}addSchema(T,O,k,C=this.opts.validateSchema){if(Array.isArray(T)){for(const ae of T)this.addSchema(ae,void 0,k,C);return this}let P;if(typeof T=="object"){const{schemaId:ae}=this.opts;if(P=T[ae],P!==void 0&&typeof P!="string")throw new Error(`schema ${ae} must be string`)}return O=(0,l.normalizeId)(O||P),this._checkUnique(O),this.schemas[O]=this._addSchema(T,k,O,C,!0),this}addMetaSchema(T,O,k=this.opts.validateSchema){return this.addSchema(T,O,!0,k),this}validateSchema(T,O){if(typeof T=="boolean")return!0;let k;if(k=T.$schema,k!==void 0&&typeof k!="string")throw new Error("$schema must be a string");if(k=k||this.opts.defaultMeta||this.defaultMeta(),!k)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const C=this.validate(k,T);if(!C&&O){const P="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(P);else throw new Error(P)}return C}getSchema(T){let O;for(;typeof(O=S.call(this,T))=="string";)T=O;if(O===void 0){const{schemaId:k}=this.opts,C=new s.SchemaEnv({schema:{},schemaId:k});if(O=s.resolveSchema.call(this,C,T),!O)return;this.refs[T]=O}return O.validate||this._compileSchemaEnv(O)}removeSchema(T){if(T instanceof RegExp)return this._removeAllSchemas(this.schemas,T),this._removeAllSchemas(this.refs,T),this;switch(typeof T){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const O=S.call(this,T);return typeof O=="object"&&this._cache.delete(O.schema),delete this.schemas[T],delete this.refs[T],this}case"object":{const O=T;this._cache.delete(O);let k=T[this.opts.schemaId];return k&&(k=(0,l.normalizeId)(k),delete this.schemas[k],delete this.refs[k]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(T){for(const O of T)this.addKeyword(O);return this}addKeyword(T,O){let k;if(typeof T=="string")k=T,typeof O=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),O.keyword=k);else if(typeof T=="object"&&O===void 0){if(O=T,k=O.keyword,Array.isArray(k)&&!k.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(Ue.call(this,k,O),!O)return(0,d.eachItem)(k,P=>Ze.call(this,P)),this;ee.call(this,O);const C={...O,type:(0,c.getJSONTypes)(O.type),schemaType:(0,c.getJSONTypes)(O.schemaType)};return(0,d.eachItem)(k,C.type.length===0?P=>Ze.call(this,P,C):P=>C.type.forEach(ae=>Ze.call(this,P,C,ae))),this}getKeyword(T){const O=this.RULES.all[T];return typeof O=="object"?O.definition:!!O}removeKeyword(T){const{RULES:O}=this;delete O.keywords[T],delete O.all[T];for(const k of O.rules){const C=k.rules.findIndex(P=>P.keyword===T);C>=0&&k.rules.splice(C,1)}return this}addFormat(T,O){return typeof O=="string"&&(O=new RegExp(O)),this.formats[T]=O,this}errorsText(T=this.errors,{separator:O=", ",dataVar:k="data"}={}){return!T||T.length===0?"No errors":T.map(C=>`${k}${C.instancePath} ${C.message}`).reduce((C,P)=>C+O+P)}$dataMetaSchema(T,O){const k=this.RULES.all;T=JSON.parse(JSON.stringify(T));for(const C of O){const P=C.split("/").slice(1);let ae=T;for(const xe of P)ae=ae[xe];for(const xe in k){const ve=k[xe];if(typeof ve!="object")continue;const{$data:ze}=ve.definition,Ye=ae[xe];ze&&Ye&&(ae[xe]=K(Ye))}}return T}_removeAllSchemas(T,O){for(const k in T){const C=T[k];(!O||O.test(k))&&(typeof C=="string"?delete T[k]:C&&!C.meta&&(this._cache.delete(C.schema),delete T[k]))}}_addSchema(T,O,k,C=this.opts.validateSchema,P=this.opts.addUsedSchema){let ae;const{schemaId:xe}=this.opts;if(typeof T=="object")ae=T[xe];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof T!="boolean")throw new Error("schema must be object or boolean")}let ve=this._cache.get(T);if(ve!==void 0)return ve;k=(0,l.normalizeId)(ae||k);const ze=l.getSchemaRefs.call(this,T,k);return ve=new s.SchemaEnv({schema:T,schemaId:xe,meta:O,baseId:k,localRefs:ze}),this._cache.set(ve.schema,ve),P&&!k.startsWith("#")&&(k&&this._checkUnique(k),this.refs[k]=ve),C&&this.validateSchema(T,!0),ve}_checkUnique(T){if(this.schemas[T]||this.refs[T])throw new Error(`schema with key or id "${T}" already exists`)}_compileSchemaEnv(T){if(T.meta?this._compileMetaSchema(T):s.compileSchema.call(this,T),!T.validate)throw new Error("ajv implementation error");return T.validate}_compileMetaSchema(T){const O=this.opts;this.opts=this._metaOpts;try{s.compileSchema.call(this,T)}finally{this.opts=O}}}M.ValidationError=n.default,M.MissingRefError=r.default,e.default=M;function x(G,T,O,k="error"){for(const C in G){const P=C;P in T&&this.logger[k](`${O}: option ${C}. ${G[P]}`)}}function S(G){return G=(0,l.normalizeId)(G),this.schemas[G]||this.refs[G]}function L(){const G=this.opts.schemas;if(G)if(Array.isArray(G))this.addSchema(G);else for(const T in G)this.addSchema(G[T],T)}function F(){for(const G in this.opts.formats){const T=this.opts.formats[G];T&&this.addFormat(G,T)}}function te(G){if(Array.isArray(G)){this.addVocabulary(G);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const T in G){const O=G[T];O.keyword||(O.keyword=T),this.addKeyword(O)}}function J(){const G={...this.opts};for(const T of m)delete G[T];return G}const be={log(){},warn(){},error(){}};function oe(G){if(G===!1)return be;if(G===void 0)return console;if(G.log&&G.warn&&G.error)return G;throw new Error("logger must implement log, warn and error methods")}const Te=/^[a-z_$][a-z0-9_$:-]*$/i;function Ue(G,T){const{RULES:O}=this;if((0,d.eachItem)(G,k=>{if(O.keywords[k])throw new Error(`Keyword ${k} is already defined`);if(!Te.test(k))throw new Error(`Keyword ${k} has invalid name`)}),!!T&&T.$data&&!("code"in T||"validate"in T))throw new Error('$data keyword must have "code" or "validate" function')}function Ze(G,T,O){var k;const C=T==null?void 0:T.post;if(O&&C)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:P}=this;let ae=C?P.post:P.rules.find(({type:ve})=>ve===O);if(ae||(ae={type:O,rules:[]},P.rules.push(ae)),P.keywords[G]=!0,!T)return;const xe={keyword:G,definition:{...T,type:(0,c.getJSONTypes)(T.type),schemaType:(0,c.getJSONTypes)(T.schemaType)}};T.before?Me.call(this,ae,xe,T.before):ae.rules.push(xe),P.all[G]=xe,(k=T.implements)===null||k===void 0||k.forEach(ve=>this.addKeyword(ve))}function Me(G,T,O){const k=G.rules.findIndex(C=>C.keyword===O);k>=0?G.rules.splice(k,0,T):(G.rules.push(T),this.logger.warn(`rule ${O} is not defined`))}function ee(G){let{metaSchema:T}=G;T!==void 0&&(G.$data&&this.opts.$data&&(T=K(T)),G.validateSchema=this.compile(T,!0))}const j={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function K(G){return{anyOf:[G,j]}}})(d6);var U0={},z0={},q0={};Object.defineProperty(q0,"__esModule",{value:!0});const kS={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};q0.default=kS;var Vo={};Object.defineProperty(Vo,"__esModule",{value:!0});Vo.callRef=Vo.getValidate=void 0;const TS=Os,op=Pt,an=kt,ns=Kn,sp=on,w1=et,PS={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:a,it:n}=e,{baseId:r,schemaEnv:o,validateName:s,opts:i,self:l}=n,{root:c}=o;if((a==="#"||a==="#/")&&r===c.baseId)return u();const d=sp.resolveRef.call(l,c,r,a);if(d===void 0)throw new TS.default(n.opts.uriResolver,r,a);if(d instanceof sp.SchemaEnv)return h(d);return f(d);function u(){if(o===c)return F1(e,s,o,o.$async);const m=t.scopeValue("root",{ref:c});return F1(e,(0,an._)`${m}.validate`,c,c.$async)}function h(m){const g=Y6(e,m);F1(e,g,m,m.$async)}function f(m){const g=t.scopeValue("schema",i.code.source===!0?{ref:m,code:(0,an.stringify)(m)}:{ref:m}),_=t.name("valid"),b=e.subschema({schema:m,dataTypes:[],schemaPath:an.nil,topSchemaRef:g,errSchemaPath:a},_);e.mergeEvaluated(b),e.ok(_)}}};function Y6(e,t){const{gen:a}=e;return t.validate?a.scopeValue("validate",{ref:t.validate}):(0,an._)`${a.scopeValue("wrapper",{ref:t})}.validate`}Vo.getValidate=Y6;function F1(e,t,a,n){const{gen:r,it:o}=e,{allErrors:s,schemaEnv:i,opts:l}=o,c=l.passContext?ns.default.this:an.nil;n?d():u();function d(){if(!i.$async)throw new Error("async schema referenced by sync schema");const m=r.let("valid");r.try(()=>{r.code((0,an._)`await ${(0,op.callValidateCode)(e,t,c)}`),f(t),s||r.assign(m,!0)},g=>{r.if((0,an._)`!(${g} instanceof ${o.ValidationError})`,()=>r.throw(g)),h(g),s||r.assign(m,!1)}),e.ok(m)}function u(){e.result((0,op.callValidateCode)(e,t,c),()=>f(t),()=>h(t))}function h(m){const g=(0,an._)`${m}.errors`;r.assign(ns.default.vErrors,(0,an._)`${ns.default.vErrors} === null ? ${g} : ${ns.default.vErrors}.concat(${g})`),r.assign(ns.default.errors,(0,an._)`${ns.default.vErrors}.length`)}function f(m){var g;if(!o.opts.unevaluated)return;const _=(g=a==null?void 0:a.validate)===null||g===void 0?void 0:g.evaluated;if(o.props!==!0)if(_&&!_.dynamicProps)_.props!==void 0&&(o.props=w1.mergeEvaluated.props(r,_.props,o.props));else{const b=r.var("props",(0,an._)`${m}.evaluated.props`);o.props=w1.mergeEvaluated.props(r,b,o.props,an.Name)}if(o.items!==!0)if(_&&!_.dynamicItems)_.items!==void 0&&(o.items=w1.mergeEvaluated.items(r,_.items,o.items));else{const b=r.var("items",(0,an._)`${m}.evaluated.items`);o.items=w1.mergeEvaluated.items(r,b,o.items,an.Name)}}}Vo.callRef=F1;Vo.default=PS;Object.defineProperty(z0,"__esModule",{value:!0});const LS=q0,VS=Vo,OS=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",LS.default,VS.default];z0.default=OS;var W0={},Z0={};Object.defineProperty(Z0,"__esModule",{value:!0});const dl=kt,Br=dl.operators,ul={maximum:{okStr:"<=",ok:Br.LTE,fail:Br.GT},minimum:{okStr:">=",ok:Br.GTE,fail:Br.LT},exclusiveMaximum:{okStr:"<",ok:Br.LT,fail:Br.GTE},exclusiveMinimum:{okStr:">",ok:Br.GT,fail:Br.LTE}},HS={message:({keyword:e,schemaCode:t})=>(0,dl.str)`must be ${ul[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,dl._)`{comparison: ${ul[e].okStr}, limit: ${t}}`},RS={keyword:Object.keys(ul),type:"number",schemaType:"number",$data:!0,error:HS,code(e){const{keyword:t,data:a,schemaCode:n}=e;e.fail$data((0,dl._)`${a} ${ul[t].fail} ${n} || isNaN(${a})`)}};Z0.default=RS;var K0={};Object.defineProperty(K0,"__esModule",{value:!0});const vi=kt,NS={message:({schemaCode:e})=>(0,vi.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,vi._)`{multipleOf: ${e}}`},DS={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:NS,code(e){const{gen:t,data:a,schemaCode:n,it:r}=e,o=r.opts.multipleOfPrecision,s=t.let("res"),i=o?(0,vi._)`Math.abs(Math.round(${s}) - ${s}) > 1e-${o}`:(0,vi._)`${s} !== parseInt(${s})`;e.fail$data((0,vi._)`(${n} === 0 || (${s} = ${a}/${n}, ${i}))`)}};K0.default=DS;var G0={},J0={};Object.defineProperty(J0,"__esModule",{value:!0});function Q6(e){const t=e.length;let a=0,n=0,r;for(;n<t;)a++,r=e.charCodeAt(n++),r>=55296&&r<=56319&&n<t&&(r=e.charCodeAt(n),(r&64512)===56320&&n++);return a}J0.default=Q6;Q6.code='require("ajv/dist/runtime/ucs2length").default';Object.defineProperty(G0,"__esModule",{value:!0});const bo=kt,BS=et,FS=J0,jS={message({keyword:e,schemaCode:t}){const a=e==="maxLength"?"more":"fewer";return(0,bo.str)`must NOT have ${a} than ${t} characters`},params:({schemaCode:e})=>(0,bo._)`{limit: ${e}}`},US={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:jS,code(e){const{keyword:t,data:a,schemaCode:n,it:r}=e,o=t==="maxLength"?bo.operators.GT:bo.operators.LT,s=r.opts.unicode===!1?(0,bo._)`${a}.length`:(0,bo._)`${(0,BS.useFunc)(e.gen,FS.default)}(${a})`;e.fail$data((0,bo._)`${s} ${o} ${n}`)}};G0.default=US;var X0={};Object.defineProperty(X0,"__esModule",{value:!0});const zS=Pt,hl=kt,qS={message:({schemaCode:e})=>(0,hl.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,hl._)`{pattern: ${e}}`},WS={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:qS,code(e){const{data:t,$data:a,schema:n,schemaCode:r,it:o}=e,s=o.opts.unicodeRegExp?"u":"",i=a?(0,hl._)`(new RegExp(${r}, ${s}))`:(0,zS.usePattern)(e,n);e.fail$data((0,hl._)`!${i}.test(${t})`)}};X0.default=WS;var Y0={};Object.defineProperty(Y0,"__esModule",{value:!0});const gi=kt,ZS={message({keyword:e,schemaCode:t}){const a=e==="maxProperties"?"more":"fewer";return(0,gi.str)`must NOT have ${a} than ${t} properties`},params:({schemaCode:e})=>(0,gi._)`{limit: ${e}}`},KS={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:ZS,code(e){const{keyword:t,data:a,schemaCode:n}=e,r=t==="maxProperties"?gi.operators.GT:gi.operators.LT;e.fail$data((0,gi._)`Object.keys(${a}).length ${r} ${n}`)}};Y0.default=KS;var Q0={};Object.defineProperty(Q0,"__esModule",{value:!0});const ei=Pt,yi=kt,GS=et,JS={message:({params:{missingProperty:e}})=>(0,yi.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,yi._)`{missingProperty: ${e}}`},XS={keyword:"required",type:"object",schemaType:"array",$data:!0,error:JS,code(e){const{gen:t,schema:a,schemaCode:n,data:r,$data:o,it:s}=e,{opts:i}=s;if(!o&&a.length===0)return;const l=a.length>=i.loopRequired;if(s.allErrors?c():d(),i.strictRequired){const f=e.parentSchema.properties,{definedProperties:m}=e.it;for(const g of a)if((f==null?void 0:f[g])===void 0&&!m.has(g)){const _=s.schemaEnv.baseId+s.errSchemaPath,b=`required property "${g}" is not defined at "${_}" (strictRequired)`;(0,GS.checkStrictMode)(s,b,s.opts.strictRequired)}}function c(){if(l||o)e.block$data(yi.nil,u);else for(const f of a)(0,ei.checkReportMissingProp)(e,f)}function d(){const f=t.let("missing");if(l||o){const m=t.let("valid",!0);e.block$data(m,()=>h(f,m)),e.ok(m)}else t.if((0,ei.checkMissingProp)(e,a,f)),(0,ei.reportMissingProp)(e,f),t.else()}function u(){t.forOf("prop",n,f=>{e.setParams({missingProperty:f}),t.if((0,ei.noPropertyInData)(t,r,f,i.ownProperties),()=>e.error())})}function h(f,m){e.setParams({missingProperty:f}),t.forOf(f,n,()=>{t.assign(m,(0,ei.propertyInData)(t,r,f,i.ownProperties)),t.if((0,yi.not)(m),()=>{e.error(),t.break()})},yi.nil)}}};Q0.default=XS;var ed={};Object.defineProperty(ed,"__esModule",{value:!0});const Mi=kt,YS={message({keyword:e,schemaCode:t}){const a=e==="maxItems"?"more":"fewer";return(0,Mi.str)`must NOT have ${a} than ${t} items`},params:({schemaCode:e})=>(0,Mi._)`{limit: ${e}}`},QS={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:YS,code(e){const{keyword:t,data:a,schemaCode:n}=e,r=t==="maxItems"?Mi.operators.GT:Mi.operators.LT;e.fail$data((0,Mi._)`${a}.length ${r} ${n}`)}};ed.default=QS;var td={},Wi={};Object.defineProperty(Wi,"__esModule",{value:!0});const eg=S6;eg.code='require("ajv/dist/runtime/equal").default';Wi.default=eg;Object.defineProperty(td,"__esModule",{value:!0});const q2=Sa,Ra=kt,e$=et,t$=Wi,a$={message:({params:{i:e,j:t}})=>(0,Ra.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Ra._)`{i: ${e}, j: ${t}}`},n$={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:a$,code(e){const{gen:t,data:a,$data:n,schema:r,parentSchema:o,schemaCode:s,it:i}=e;if(!n&&!r)return;const l=t.let("valid"),c=o.items?(0,q2.getSchemaTypes)(o.items):[];e.block$data(l,d,(0,Ra._)`${s} === false`),e.ok(l);function d(){const m=t.let("i",(0,Ra._)`${a}.length`),g=t.let("j");e.setParams({i:m,j:g}),t.assign(l,!0),t.if((0,Ra._)`${m} > 1`,()=>(u()?h:f)(m,g))}function u(){return c.length>0&&!c.some(m=>m==="object"||m==="array")}function h(m,g){const _=t.name("item"),b=(0,q2.checkDataTypes)(c,_,i.opts.strictNumbers,q2.DataType.Wrong),v=t.const("indices",(0,Ra._)`{}`);t.for((0,Ra._)`;${m}--;`,()=>{t.let(_,(0,Ra._)`${a}[${m}]`),t.if(b,(0,Ra._)`continue`),c.length>1&&t.if((0,Ra._)`typeof ${_} == "string"`,(0,Ra._)`${_} += "_"`),t.if((0,Ra._)`typeof ${v}[${_}] == "number"`,()=>{t.assign(g,(0,Ra._)`${v}[${_}]`),e.error(),t.assign(l,!1).break()}).code((0,Ra._)`${v}[${_}] = ${m}`)})}function f(m,g){const _=(0,e$.useFunc)(t,t$.default),b=t.name("outer");t.label(b).for((0,Ra._)`;${m}--;`,()=>t.for((0,Ra._)`${g} = ${m}; ${g}--;`,()=>t.if((0,Ra._)`${_}(${a}[${m}], ${a}[${g}])`,()=>{e.error(),t.assign(l,!1).break(b)})))}}};td.default=n$;var ad={};Object.defineProperty(ad,"__esModule",{value:!0});const Oc=kt,r$=et,o$=Wi,s$={message:"must be equal to constant",params:({schemaCode:e})=>(0,Oc._)`{allowedValue: ${e}}`},i$={keyword:"const",$data:!0,error:s$,code(e){const{gen:t,data:a,$data:n,schemaCode:r,schema:o}=e;n||o&&typeof o=="object"?e.fail$data((0,Oc._)`!${(0,r$.useFunc)(t,o$.default)}(${a}, ${r})`):e.fail((0,Oc._)`${o} !== ${a}`)}};ad.default=i$;var nd={};Object.defineProperty(nd,"__esModule",{value:!0});const si=kt,l$=et,c$=Wi,d$={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,si._)`{allowedValues: ${e}}`},u$={keyword:"enum",schemaType:"array",$data:!0,error:d$,code(e){const{gen:t,data:a,$data:n,schema:r,schemaCode:o,it:s}=e;if(!n&&r.length===0)throw new Error("enum must have non-empty array");const i=r.length>=s.opts.loopEnum;let l;const c=()=>l??(l=(0,l$.useFunc)(t,c$.default));let d;if(i||n)d=t.let("valid"),e.block$data(d,u);else{if(!Array.isArray(r))throw new Error("ajv implementation error");const f=t.const("vSchema",o);d=(0,si.or)(...r.map((m,g)=>h(f,g)))}e.pass(d);function u(){t.assign(d,!1),t.forOf("v",o,f=>t.if((0,si._)`${c()}(${a}, ${f})`,()=>t.assign(d,!0).break()))}function h(f,m){const g=r[m];return typeof g=="object"&&g!==null?(0,si._)`${c()}(${a}, ${f}[${m}])`:(0,si._)`${a} === ${g}`}}};nd.default=u$;Object.defineProperty(W0,"__esModule",{value:!0});const h$=Z0,p$=K0,f$=G0,m$=X0,v$=Y0,g$=Q0,y$=ed,M$=td,_$=ad,b$=nd,w$=[h$.default,p$.default,f$.default,m$.default,v$.default,g$.default,y$.default,M$.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},_$.default,b$.default];W0.default=w$;var rd={},Hs={};Object.defineProperty(Hs,"__esModule",{value:!0});Hs.validateAdditionalItems=void 0;const wo=kt,Hc=et,x$={message:({params:{len:e}})=>(0,wo.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,wo._)`{limit: ${e}}`},C$={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:x$,code(e){const{parentSchema:t,it:a}=e,{items:n}=t;if(!Array.isArray(n)){(0,Hc.checkStrictMode)(a,'"additionalItems" is ignored when "items" is not an array of schemas');return}tg(e,n)}};function tg(e,t){const{gen:a,schema:n,data:r,keyword:o,it:s}=e;s.items=!0;const i=a.const("len",(0,wo._)`${r}.length`);if(n===!1)e.setParams({len:t.length}),e.pass((0,wo._)`${i} <= ${t.length}`);else if(typeof n=="object"&&!(0,Hc.alwaysValidSchema)(s,n)){const c=a.var("valid",(0,wo._)`${i} <= ${t.length}`);a.if((0,wo.not)(c),()=>l(c)),e.ok(c)}function l(c){a.forRange("i",t.length,i,d=>{e.subschema({keyword:o,dataProp:d,dataPropType:Hc.Type.Num},c),s.allErrors||a.if((0,wo.not)(c),()=>a.break())})}}Hs.validateAdditionalItems=tg;Hs.default=C$;var od={},Rs={};Object.defineProperty(Rs,"__esModule",{value:!0});Rs.validateTuple=void 0;const ip=kt,j1=et,A$=Pt,S$={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:a}=e;if(Array.isArray(t))return ag(e,"additionalItems",t);a.items=!0,!(0,j1.alwaysValidSchema)(a,t)&&e.ok((0,A$.validateArray)(e))}};function ag(e,t,a=e.schema){const{gen:n,parentSchema:r,data:o,keyword:s,it:i}=e;d(r),i.opts.unevaluated&&a.length&&i.items!==!0&&(i.items=j1.mergeEvaluated.items(n,a.length,i.items));const l=n.name("valid"),c=n.const("len",(0,ip._)`${o}.length`);a.forEach((u,h)=>{(0,j1.alwaysValidSchema)(i,u)||(n.if((0,ip._)`${c} > ${h}`,()=>e.subschema({keyword:s,schemaProp:h,dataProp:h},l)),e.ok(l))});function d(u){const{opts:h,errSchemaPath:f}=i,m=a.length,g=m===u.minItems&&(m===u.maxItems||u[t]===!1);if(h.strictTuples&&!g){const _=`"${s}" is ${m}-tuple, but minItems or maxItems/${t} are not specified or different at path "${f}"`;(0,j1.checkStrictMode)(i,_,h.strictTuples)}}}Rs.validateTuple=ag;Rs.default=S$;Object.defineProperty(od,"__esModule",{value:!0});const $$=Rs,E$={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,$$.validateTuple)(e,"items")};od.default=E$;var sd={};Object.defineProperty(sd,"__esModule",{value:!0});const lp=kt,I$=et,k$=Pt,T$=Hs,P$={message:({params:{len:e}})=>(0,lp.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,lp._)`{limit: ${e}}`},L$={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:P$,code(e){const{schema:t,parentSchema:a,it:n}=e,{prefixItems:r}=a;n.items=!0,!(0,I$.alwaysValidSchema)(n,t)&&(r?(0,T$.validateAdditionalItems)(e,r):e.ok((0,k$.validateArray)(e)))}};sd.default=L$;var id={};Object.defineProperty(id,"__esModule",{value:!0});const bn=kt,x1=et,V$={message:({params:{min:e,max:t}})=>t===void 0?(0,bn.str)`must contain at least ${e} valid item(s)`:(0,bn.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,bn._)`{minContains: ${e}}`:(0,bn._)`{minContains: ${e}, maxContains: ${t}}`},O$={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:V$,code(e){const{gen:t,schema:a,parentSchema:n,data:r,it:o}=e;let s,i;const{minContains:l,maxContains:c}=n;o.opts.next?(s=l===void 0?1:l,i=c):s=1;const d=t.const("len",(0,bn._)`${r}.length`);if(e.setParams({min:s,max:i}),i===void 0&&s===0){(0,x1.checkStrictMode)(o,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(i!==void 0&&s>i){(0,x1.checkStrictMode)(o,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,x1.alwaysValidSchema)(o,a)){let g=(0,bn._)`${d} >= ${s}`;i!==void 0&&(g=(0,bn._)`${g} && ${d} <= ${i}`),e.pass(g);return}o.items=!0;const u=t.name("valid");i===void 0&&s===1?f(u,()=>t.if(u,()=>t.break())):s===0?(t.let(u,!0),i!==void 0&&t.if((0,bn._)`${r}.length > 0`,h)):(t.let(u,!1),h()),e.result(u,()=>e.reset());function h(){const g=t.name("_valid"),_=t.let("count",0);f(g,()=>t.if(g,()=>m(_)))}function f(g,_){t.forRange("i",0,d,b=>{e.subschema({keyword:"contains",dataProp:b,dataPropType:x1.Type.Num,compositeRule:!0},g),_()})}function m(g){t.code((0,bn._)`${g}++`),i===void 0?t.if((0,bn._)`${g} >= ${s}`,()=>t.assign(u,!0).break()):(t.if((0,bn._)`${g} > ${i}`,()=>t.assign(u,!1).break()),s===1?t.assign(u,!0):t.if((0,bn._)`${g} >= ${s}`,()=>t.assign(u,!0)))}}};id.default=O$;var ng={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=kt,a=et,n=Pt;e.error={message:({params:{property:l,depsCount:c,deps:d}})=>{const u=c===1?"property":"properties";return(0,t.str)`must have ${u} ${d} when property ${l} is present`},params:({params:{property:l,depsCount:c,deps:d,missingProperty:u}})=>(0,t._)`{property: ${l},
34
34
  missingProperty: ${u},
35
35
  depsCount: ${c},
36
- deps: ${d}}`};const r={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(l){const[c,d]=o(l);s(l,c),i(l,d)}};function o({schema:l}){const c={},d={};for(const u in l){if(u==="__proto__")continue;const h=Array.isArray(l[u])?c:d;h[u]=l[u]}return[c,d]}function s(l,c=l.schema){const{gen:d,data:u,it:h}=l;if(Object.keys(c).length===0)return;const f=d.let("missing");for(const m in c){const g=c[m];if(g.length===0)continue;const _=(0,n.propertyInData)(d,u,m,h.opts.ownProperties);l.setParams({property:m,depsCount:g.length,deps:g.join(", ")}),h.allErrors?d.if(_,()=>{for(const b of g)(0,n.checkReportMissingProp)(l,b)}):(d.if((0,t._)`${_} && (${(0,n.checkMissingProp)(l,g,f)})`),(0,n.reportMissingProp)(l,f),d.else())}}e.validatePropertyDeps=s;function i(l,c=l.schema){const{gen:d,data:u,keyword:h,it:f}=l,m=d.name("valid");for(const g in c)(0,a.alwaysValidSchema)(f,c[g])||(d.if((0,n.propertyInData)(d,u,g,f.opts.ownProperties),()=>{const _=l.subschema({keyword:h,schemaProp:g},m);l.mergeValidEvaluated(_,m)},()=>d.var(m,!0)),l.ok(m))}e.validateSchemaDeps=i,e.default=r})(ng);var ld={};Object.defineProperty(ld,"__esModule",{value:!0});const rg=kt,H$=et,R$={message:"property name must be valid",params:({params:e})=>(0,rg._)`{propertyName: ${e.propertyName}}`},N$={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:R$,code(e){const{gen:t,schema:a,data:n,it:r}=e;if((0,H$.alwaysValidSchema)(r,a))return;const o=t.name("valid");t.forIn("key",n,s=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},o),t.if((0,rg.not)(o),()=>{e.error(!0),r.allErrors||t.break()})}),e.ok(o)}};ld.default=N$;var Ul={};Object.defineProperty(Ul,"__esModule",{value:!0});const C1=Pt,On=kt,D$=Zn,A1=et,B$={message:"must NOT have additional properties",params:({params:e})=>(0,On._)`{additionalProperty: ${e.additionalProperty}}`},F$={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:B$,code(e){const{gen:t,schema:a,parentSchema:n,data:r,errsCount:o,it:s}=e;if(!o)throw new Error("ajv implementation error");const{allErrors:i,opts:l}=s;if(s.props=!0,l.removeAdditional!=="all"&&(0,A1.alwaysValidSchema)(s,a))return;const c=(0,C1.allSchemaProperties)(n.properties),d=(0,C1.allSchemaProperties)(n.patternProperties);u(),e.ok((0,On._)`${o} === ${D$.default.errors}`);function u(){t.forIn("key",r,_=>{!c.length&&!d.length?m(_):t.if(h(_),()=>m(_))})}function h(_){let b;if(c.length>8){const v=(0,A1.schemaRefOrVal)(s,n.properties,"properties");b=(0,C1.isOwnProperty)(t,v,_)}else c.length?b=(0,On.or)(...c.map(v=>(0,On._)`${_} === ${v}`)):b=On.nil;return d.length&&(b=(0,On.or)(b,...d.map(v=>(0,On._)`${(0,C1.usePattern)(e,v)}.test(${_})`))),(0,On.not)(b)}function f(_){t.code((0,On._)`delete ${r}[${_}]`)}function m(_){if(l.removeAdditional==="all"||l.removeAdditional&&a===!1){f(_);return}if(a===!1){e.setParams({additionalProperty:_}),e.error(),i||t.break();return}if(typeof a=="object"&&!(0,A1.alwaysValidSchema)(s,a)){const b=t.name("valid");l.removeAdditional==="failing"?(g(_,b,!1),t.if((0,On.not)(b),()=>{e.reset(),f(_)})):(g(_,b),i||t.if((0,On.not)(b),()=>t.break()))}}function g(_,b,v){const y={keyword:"additionalProperties",dataProp:_,dataPropType:A1.Type.Str};v===!1&&Object.assign(y,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(y,b)}}};Ul.default=F$;var cd={};Object.defineProperty(cd,"__esModule",{value:!0});const j$=Sn,cp=Pt,W2=et,dp=Ul,U$={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:a,parentSchema:n,data:r,it:o}=e;o.opts.removeAdditional==="all"&&n.additionalProperties===void 0&&dp.default.code(new j$.KeywordCxt(o,dp.default,"additionalProperties"));const s=(0,cp.allSchemaProperties)(a);for(const u of s)o.definedProperties.add(u);o.opts.unevaluated&&s.length&&o.props!==!0&&(o.props=W2.mergeEvaluated.props(t,(0,W2.toHash)(s),o.props));const i=s.filter(u=>!(0,W2.alwaysValidSchema)(o,a[u]));if(i.length===0)return;const l=t.name("valid");for(const u of i)c(u)?d(u):(t.if((0,cp.propertyInData)(t,r,u,o.opts.ownProperties)),d(u),o.allErrors||t.else().var(l,!0),t.endIf()),e.it.definedProperties.add(u),e.ok(l);function c(u){return o.opts.useDefaults&&!o.compositeRule&&a[u].default!==void 0}function d(u){e.subschema({keyword:"properties",schemaProp:u,dataProp:u},l)}}};cd.default=U$;var dd={};Object.defineProperty(dd,"__esModule",{value:!0});const up=Pt,S1=kt,hp=et,pp=et,z$={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:a,data:n,parentSchema:r,it:o}=e,{opts:s}=o,i=(0,up.allSchemaProperties)(a),l=i.filter(g=>(0,hp.alwaysValidSchema)(o,a[g]));if(i.length===0||l.length===i.length&&(!o.opts.unevaluated||o.props===!0))return;const c=s.strictSchema&&!s.allowMatchingProperties&&r.properties,d=t.name("valid");o.props!==!0&&!(o.props instanceof S1.Name)&&(o.props=(0,pp.evaluatedPropsToName)(t,o.props));const{props:u}=o;h();function h(){for(const g of i)c&&f(g),o.allErrors?m(g):(t.var(d,!0),m(g),t.if(d))}function f(g){for(const _ in c)new RegExp(g).test(_)&&(0,hp.checkStrictMode)(o,`property ${_} matches pattern ${g} (use allowMatchingProperties)`)}function m(g){t.forIn("key",n,_=>{t.if((0,S1._)`${(0,up.usePattern)(e,g)}.test(${_})`,()=>{const b=l.includes(g);b||e.subschema({keyword:"patternProperties",schemaProp:g,dataProp:_,dataPropType:pp.Type.Str},d),o.opts.unevaluated&&u!==!0?t.assign((0,S1._)`${u}[${_}]`,!0):!b&&!o.allErrors&&t.if((0,S1.not)(d),()=>t.break())})})}}};dd.default=z$;var ud={};Object.defineProperty(ud,"__esModule",{value:!0});const q$=et,W$={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:a,it:n}=e;if((0,q$.alwaysValidSchema)(n,a)){e.fail();return}const r=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},r),e.failResult(r,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};ud.default=W$;var hd={};Object.defineProperty(hd,"__esModule",{value:!0});const Z$=Pt,K$={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:Z$.validateUnion,error:{message:"must match a schema in anyOf"}};hd.default=K$;var pd={};Object.defineProperty(pd,"__esModule",{value:!0});const U1=kt,G$=et,J$={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,U1._)`{passingSchemas: ${e.passing}}`},X$={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:J$,code(e){const{gen:t,schema:a,parentSchema:n,it:r}=e;if(!Array.isArray(a))throw new Error("ajv implementation error");if(r.opts.discriminator&&n.discriminator)return;const o=a,s=t.let("valid",!1),i=t.let("passing",null),l=t.name("_valid");e.setParams({passing:i}),t.block(c),e.result(s,()=>e.reset(),()=>e.error(!0));function c(){o.forEach((d,u)=>{let h;(0,G$.alwaysValidSchema)(r,d)?t.var(l,!0):h=e.subschema({keyword:"oneOf",schemaProp:u,compositeRule:!0},l),u>0&&t.if((0,U1._)`${l} && ${s}`).assign(s,!1).assign(i,(0,U1._)`[${i}, ${u}]`).else(),t.if(l,()=>{t.assign(s,!0),t.assign(i,u),h&&e.mergeEvaluated(h,U1.Name)})})}}};pd.default=X$;var fd={};Object.defineProperty(fd,"__esModule",{value:!0});const Y$=et,Q$={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:a,it:n}=e;if(!Array.isArray(a))throw new Error("ajv implementation error");const r=t.name("valid");a.forEach((o,s)=>{if((0,Y$.alwaysValidSchema)(n,o))return;const i=e.subschema({keyword:"allOf",schemaProp:s},r);e.ok(r),e.mergeEvaluated(i)})}};fd.default=Q$;var md={};Object.defineProperty(md,"__esModule",{value:!0});const pl=kt,og=et,eE={message:({params:e})=>(0,pl.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,pl._)`{failingKeyword: ${e.ifClause}}`},tE={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:eE,code(e){const{gen:t,parentSchema:a,it:n}=e;a.then===void 0&&a.else===void 0&&(0,og.checkStrictMode)(n,'"if" without "then" and "else" is ignored');const r=fp(n,"then"),o=fp(n,"else");if(!r&&!o)return;const s=t.let("valid",!0),i=t.name("_valid");if(l(),e.reset(),r&&o){const d=t.let("ifClause");e.setParams({ifClause:d}),t.if(i,c("then",d),c("else",d))}else r?t.if(i,c("then")):t.if((0,pl.not)(i),c("else"));e.pass(s,()=>e.error(!0));function l(){const d=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},i);e.mergeEvaluated(d)}function c(d,u){return()=>{const h=e.subschema({keyword:d},i);t.assign(s,i),e.mergeValidEvaluated(h,s),u?t.assign(u,(0,pl._)`${d}`):e.setParams({ifClause:d})}}}};function fp(e,t){const a=e.schema[t];return a!==void 0&&!(0,og.alwaysValidSchema)(e,a)}md.default=tE;var vd={};Object.defineProperty(vd,"__esModule",{value:!0});const aE=et,nE={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:a}){t.if===void 0&&(0,aE.checkStrictMode)(a,`"${e}" without "if" is ignored`)}};vd.default=nE;Object.defineProperty(rd,"__esModule",{value:!0});const rE=Os,oE=od,sE=Hs,iE=sd,lE=id,cE=ng,dE=ld,uE=Ul,hE=cd,pE=dd,fE=ud,mE=hd,vE=pd,gE=fd,yE=md,ME=vd;function _E(e=!1){const t=[fE.default,mE.default,vE.default,gE.default,yE.default,ME.default,dE.default,uE.default,cE.default,hE.default,pE.default];return e?t.push(oE.default,iE.default):t.push(rE.default,sE.default),t.push(lE.default),t}rd.default=_E;var gd={},yd={};Object.defineProperty(yd,"__esModule",{value:!0});const ga=kt,bE={message:({schemaCode:e})=>(0,ga.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,ga._)`{format: ${e}}`},wE={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:bE,code(e,t){const{gen:a,data:n,$data:r,schema:o,schemaCode:s,it:i}=e,{opts:l,errSchemaPath:c,schemaEnv:d,self:u}=i;if(!l.validateFormats)return;r?h():f();function h(){const m=a.scopeValue("formats",{ref:u.formats,code:l.code.formats}),g=a.const("fDef",(0,ga._)`${m}[${s}]`),_=a.let("fType"),b=a.let("format");a.if((0,ga._)`typeof ${g} == "object" && !(${g} instanceof RegExp)`,()=>a.assign(_,(0,ga._)`${g}.type || "string"`).assign(b,(0,ga._)`${g}.validate`),()=>a.assign(_,(0,ga._)`"string"`).assign(b,g)),e.fail$data((0,ga.or)(v(),y()));function v(){return l.strictSchema===!1?ga.nil:(0,ga._)`${s} && !${b}`}function y(){const M=d.$async?(0,ga._)`(${g}.async ? await ${b}(${n}) : ${b}(${n}))`:(0,ga._)`${b}(${n})`,x=(0,ga._)`(typeof ${b} == "function" ? ${M} : ${b}.test(${n}))`;return(0,ga._)`${b} && ${b} !== true && ${_} === ${t} && !${x}`}}function f(){const m=u.formats[o];if(!m){v();return}if(m===!0)return;const[g,_,b]=y(m);g===t&&e.pass(M());function v(){if(l.strictSchema===!1){u.logger.warn(x());return}throw new Error(x());function x(){return`unknown format "${o}" ignored in schema at path "${c}"`}}function y(x){const S=x instanceof RegExp?(0,ga.regexpCode)(x):l.code.formats?(0,ga._)`${l.code.formats}${(0,ga.getProperty)(o)}`:void 0,L=a.scopeValue("formats",{key:o,ref:x,code:S});return typeof x=="object"&&!(x instanceof RegExp)?[x.type||"string",x.validate,(0,ga._)`${L}.validate`]:["string",x,L]}function M(){if(typeof m=="object"&&!(m instanceof RegExp)&&m.async){if(!d.$async)throw new Error("async format in sync schema");return(0,ga._)`await ${b}(${n})`}return typeof _=="function"?(0,ga._)`${b}(${n})`:(0,ga._)`${b}.test(${n})`}}}};yd.default=wE;Object.defineProperty(gd,"__esModule",{value:!0});const xE=yd,CE=[xE.default];gd.default=CE;var $s={};Object.defineProperty($s,"__esModule",{value:!0});$s.contentVocabulary=$s.metadataVocabulary=void 0;$s.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];$s.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"];Object.defineProperty(U0,"__esModule",{value:!0});const AE=z0,SE=W0,$E=rd,EE=gd,mp=$s,IE=[AE.default,SE.default,(0,$E.default)(),EE.default,mp.metadataVocabulary,mp.contentVocabulary];U0.default=IE;var Md={},zl={};Object.defineProperty(zl,"__esModule",{value:!0});zl.DiscrError=void 0;var vp;(function(e){e.Tag="tag",e.Mapping="mapping"})(vp||(zl.DiscrError=vp={}));Object.defineProperty(Md,"__esModule",{value:!0});const os=kt,Rc=zl,gp=on,kE=Vs,TE=et,PE={message:({params:{discrError:e,tagName:t}})=>e===Rc.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:a}})=>(0,os._)`{error: ${e}, tag: ${a}, tagValue: ${t}}`},LE={keyword:"discriminator",type:"object",schemaType:"object",error:PE,code(e){const{gen:t,data:a,schema:n,parentSchema:r,it:o}=e,{oneOf:s}=r;if(!o.opts.discriminator)throw new Error("discriminator: requires discriminator option");const i=n.propertyName;if(typeof i!="string")throw new Error("discriminator: requires propertyName");if(n.mapping)throw new Error("discriminator: mapping is not supported");if(!s)throw new Error("discriminator: requires oneOf keyword");const l=t.let("valid",!1),c=t.const("tag",(0,os._)`${a}${(0,os.getProperty)(i)}`);t.if((0,os._)`typeof ${c} == "string"`,()=>d(),()=>e.error(!1,{discrError:Rc.DiscrError.Tag,tag:c,tagName:i})),e.ok(l);function d(){const f=h();t.if(!1);for(const m in f)t.elseIf((0,os._)`${c} === ${m}`),t.assign(l,u(f[m]));t.else(),e.error(!1,{discrError:Rc.DiscrError.Mapping,tag:c,tagName:i}),t.endIf()}function u(f){const m=t.name("valid"),g=e.subschema({keyword:"oneOf",schemaProp:f},m);return e.mergeEvaluated(g,os.Name),m}function h(){var f;const m={},g=b(r);let _=!0;for(let M=0;M<s.length;M++){let x=s[M];if(x!=null&&x.$ref&&!(0,TE.schemaHasRulesButRef)(x,o.self.RULES)){const L=x.$ref;if(x=gp.resolveRef.call(o.self,o.schemaEnv.root,o.baseId,L),x instanceof gp.SchemaEnv&&(x=x.schema),x===void 0)throw new kE.default(o.opts.uriResolver,o.baseId,L)}const S=(f=x==null?void 0:x.properties)===null||f===void 0?void 0:f[i];if(typeof S!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${i}"`);_=_&&(g||b(x)),v(S,M)}if(!_)throw new Error(`discriminator: "${i}" must be required`);return m;function b({required:M}){return Array.isArray(M)&&M.includes(i)}function v(M,x){if(M.const)y(M.const,x);else if(M.enum)for(const S of M.enum)y(S,x);else throw new Error(`discriminator: "properties/${i}" must have "const" or "enum"`)}function y(M,x){if(typeof M!="string"||M in m)throw new Error(`discriminator: "${i}" values must be unique strings`);m[M]=x}}}};Md.default=LE;const VE="http://json-schema.org/draft-07/schema#",OE="http://json-schema.org/draft-07/schema#",HE="Core schema meta-schema",RE={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},NE=["object","boolean"],DE={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},BE={$schema:VE,$id:OE,title:HE,definitions:RE,type:NE,properties:DE,default:!0};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const a=d6,n=U0,r=Md,o=BE,s=["/properties"],i="http://json-schema.org/draft-07/schema";class l extends a.default{_addVocabularies(){super._addVocabularies(),n.default.forEach(m=>this.addVocabulary(m)),this.opts.discriminator&&this.addKeyword(r.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const m=this.opts.$data?this.$dataMetaSchema(o,s):o;this.addMetaSchema(m,i,!1),this.refs["http://json-schema.org/schema"]=i}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(i)?i:void 0)}}t.Ajv=l,e.exports=t=l,e.exports.Ajv=l,Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var c=Sn;Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return c.KeywordCxt}});var d=kt;Object.defineProperty(t,"_",{enumerable:!0,get:function(){return d._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return d.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return d.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return d.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return d.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return d.CodeGen}});var u=qi;Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return u.default}});var h=Vs;Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return h.default}})})(Ic,Ic.exports);var sg=Ic.exports;const FE=E0(sg);var Nc={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const a=sg,n=kt,r=Ss,o=Sn,s=Ls,i=Zn,l="errorMessage",c=new a.Name("emUsed"),d={required:"missingProperty",dependencies:"property",dependentRequired:"property"},u=/\$\{[^}]+\}/,h=/\$\{([^}]+)\}/g,f=/^""\s*\+\s*|\s*\+\s*""$/g;function m(_){return{keyword:l,schemaType:["string","object"],post:!0,code(b){const{gen:v,data:y,schema:M,schemaValue:x,it:S}=b;if(S.createErrors===!1)return;const L=M,F=n.strConcat(i.default.instancePath,S.errorPath);v.if(a._`${i.default.errors} > 0`,()=>{if(typeof L=="object"){const[k,C]=J(L);C&&be(C),k&&oe(k),Te(te(L))}const O=typeof L=="string"?L:L._;O&&Ue(O),_.keepErrors||Ze()});function te({properties:O,items:k}){const C={};if(O){C.props={};for(const P in O)C.props[P]=[]}if(k){C.items={};for(let P=0;P<k.length;P++)C.items[P]=[]}return C}function J(O){let k,C;for(const P in O){if(P==="properties"||P==="items")continue;const ae=O[P];if(typeof ae=="object"){k||(k={});const xe=k[P]={};for(const ve in ae)xe[ve]=[]}else C||(C={}),C[P]=[]}return[k,C]}function be(O){const k=v.const("emErrors",a.stringify(O)),C=v.const("templates",K(O,M));v.forOf("err",i.default.vErrors,ve=>v.if(Me(ve,k),()=>v.code(a._`${k}[${ve}.keyword].push(${ve})`).assign(a._`${ve}.${c}`,!0)));const{singleError:P}=_;if(P){const ve=v.let("message",a._`""`),ze=v.let("paramsErrors",a._`[]`);ae(Ye=>{v.if(ve,()=>v.code(a._`${ve} += ${typeof P=="string"?P:";"}`)),v.code(a._`${ve} += ${xe(Ye)}`),v.assign(ze,a._`${ze}.concat(${k}[${Ye}])`)}),s.reportError(b,{message:ve,params:a._`{errors: ${ze}}`})}else ae(ve=>s.reportError(b,{message:xe(ve),params:a._`{errors: ${k}[${ve}]}`}));function ae(ve){v.forIn("key",k,ze=>v.if(a._`${k}[${ze}].length`,()=>ve(ze)))}function xe(ve){return a._`${ve} in ${C} ? ${C}[${ve}]() : ${x}[${ve}]`}}function oe(O){const k=v.const("emErrors",a.stringify(O)),C=[];for(const ze in O)C.push([ze,K(O[ze],M[ze])]);const P=v.const("templates",v.object(...C)),ae=v.scopeValue("obj",{ref:d,code:a.stringify(d)}),xe=v.let("emPropParams"),ve=v.let("emParamsErrors");v.forOf("err",i.default.vErrors,ze=>v.if(Me(ze,k),()=>{v.assign(xe,a._`${ae}[${ze}.keyword]`),v.assign(ve,a._`${k}[${ze}.keyword][${ze}.params[${xe}]]`),v.if(ve,()=>v.code(a._`${ve}.push(${ze})`).assign(a._`${ze}.${c}`,!0))})),v.forIn("key",k,ze=>v.forIn("keyProp",a._`${k}[${ze}]`,Ye=>{v.assign(ve,a._`${k}[${ze}][${Ye}]`),v.if(a._`${ve}.length`,()=>{const ct=v.const("tmpl",a._`${P}[${ze}] && ${P}[${ze}][${Ye}]`);s.reportError(b,{message:a._`${ct} ? ${ct}() : ${x}[${ze}][${Ye}]`,params:a._`{errors: ${ve}}`})})}))}function Te(O){const{props:k,items:C}=O;if(!k&&!C)return;const P=a._`typeof ${y} == "object"`,ae=a._`Array.isArray(${y})`,xe=v.let("emErrors");let ve,ze;const Ye=v.let("templates");k&&C?(ve=v.let("emChildKwd"),v.if(P),v.if(ae,()=>{ct(C,M.items),v.assign(ve,a.str`items`)},()=>{ct(k,M.properties),v.assign(ve,a.str`properties`)}),ze=a._`[${ve}]`):C?(v.if(ae),ct(C,M.items),ze=a._`.items`):k&&(v.if(n.and(P,n.not(ae))),ct(k,M.properties),ze=a._`.properties`),v.forOf("err",i.default.vErrors,wt=>ee(wt,xe,D=>v.code(a._`${xe}[${D}].push(${wt})`).assign(a._`${wt}.${c}`,!0))),v.forIn("key",xe,wt=>v.if(a._`${xe}[${wt}].length`,()=>{s.reportError(b,{message:a._`${wt} in ${Ye} ? ${Ye}[${wt}]() : ${x}${ze}[${wt}]`,params:a._`{errors: ${xe}[${wt}]}`}),v.assign(a._`${i.default.vErrors}[${i.default.errors}-1].instancePath`,a._`${F} + "/" + ${wt}.replace(/~/g, "~0").replace(/\\//g, "~1")`)})),v.endIf();function ct(wt,D){v.assign(xe,a.stringify(wt)),v.assign(Ye,K(wt,D))}}function Ue(O){const k=v.const("emErrs",a._`[]`);v.forOf("err",i.default.vErrors,C=>v.if(j(C),()=>v.code(a._`${k}.push(${C})`).assign(a._`${C}.${c}`,!0))),v.if(a._`${k}.length`,()=>s.reportError(b,{message:G(O),params:a._`{errors: ${k}}`}))}function Ze(){const O=v.const("emErrs",a._`[]`);v.forOf("err",i.default.vErrors,k=>v.if(a._`!${k}.${c}`,()=>v.code(a._`${O}.push(${k})`))),v.assign(i.default.vErrors,O).assign(i.default.errors,a._`${O}.length`)}function Me(O,k){return n.and(a._`${O}.keyword !== ${l}`,a._`!${O}.${c}`,a._`${O}.instancePath === ${F}`,a._`${O}.keyword in ${k}`,a._`${O}.schemaPath.indexOf(${S.errSchemaPath}) === 0`,a._`/^\\/[^\\/]*$/.test(${O}.schemaPath.slice(${S.errSchemaPath.length}))`)}function ee(O,k,C){v.if(n.and(a._`${O}.keyword !== ${l}`,a._`!${O}.${c}`,a._`${O}.instancePath.indexOf(${F}) === 0`),()=>{const P=v.scopeValue("pattern",{ref:/^\/([^/]*)(?:\/|$)/,code:a._`new RegExp("^\\\/([^/]*)(?:\\\/|$)")`}),ae=v.const("emMatches",a._`${P}.exec(${O}.instancePath.slice(${F}.length))`),xe=v.const("emChild",a._`${ae} && ${ae}[1].replace(/~1/g, "/").replace(/~0/g, "~")`);v.if(a._`${xe} !== undefined && ${xe} in ${k}`,()=>C(xe))})}function j(O){return n.and(a._`${O}.keyword !== ${l}`,a._`!${O}.${c}`,n.or(a._`${O}.instancePath === ${F}`,n.and(a._`${O}.instancePath.indexOf(${F}) === 0`,a._`${O}.instancePath[${F}.length] === "/"`)),a._`${O}.schemaPath.indexOf(${S.errSchemaPath}) === 0`,a._`${O}.schemaPath[${S.errSchemaPath}.length] === "/"`)}function K(O,k){const C=[];for(const P in O){const ae=k[P];u.test(ae)&&C.push([P,T(ae)])}return v.object(...C)}function G(O){return u.test(O)?new r._Code(r.safeStringify(O).replace(h,(k,C)=>`" + JSON.stringify(${o.getData(C,S)}) + "`).replace(f,"")):a.stringify(O)}function T(O){return a._`function(){return ${G(O)}}`}},metaSchema:{anyOf:[{type:"string"},{type:"object",properties:{properties:{$ref:"#/$defs/stringMap"},items:{$ref:"#/$defs/stringList"},required:{$ref:"#/$defs/stringOrMap"},dependencies:{$ref:"#/$defs/stringOrMap"}},additionalProperties:{type:"string"}}],$defs:{stringMap:{type:"object",additionalProperties:{type:"string"}},stringOrMap:{anyOf:[{type:"string"},{$ref:"#/$defs/stringMap"}]},stringList:{type:"array",items:{type:"string"}}}}}}const g=(_,b={})=>{if(!_.opts.allErrors)throw new Error("ajv-errors: Ajv option allErrors must be true");if(_.opts.jsPropertySyntax)throw new Error("ajv-errors: ajv option jsPropertySyntax is not supported");return _.addKeyword(m(b))};t.default=g,e.exports=g,e.exports.default=g})(Nc,Nc.exports);var jE=Nc.exports;const UE=E0(jE);var zE=(e=>(e.WriterBlueprintKey="writer#blueprintKey",e.CssClassnames="cssClassnames",e.CssSize="cssSize",e.Uri="uri",e.Uuid="uuid",e))(zE||{});function yn(e){return`https://dev.writer.com/framework/${encodeURIComponent(e)}.json`}function Lde(e){return{$id:yn(e.join(",")),type:"string",enum:e}}function _i(e,t){return{$id:yn(`between-${e}-${t}`),type:"number",minimum:e,maximum:t}}const qE={$id:yn("cssClassname"),type:"string",format:"cssClassnames"},ig={$id:yn("cssSize"),type:"string",format:"cssSize"};function WE(e,t){const a=e.getComponents().filter(n=>{var r;return n.type==="blueprints_blueprint"&&n.id!==t&&((r=n.content)==null?void 0:r.key)}).map(n=>n.content.key);if(a.length!==0)return{type:"string",not:{enum:[...new Set(a)]},errorMessage:"Must be unique"}}const lg={$id:yn("arrayOfString"),type:"array",items:{type:"string"}},_d=_i(-90,90),bd=_i(-180,180),ZE={$id:yn("gpsMarker"),type:"object",properties:{name:{type:"string"},lat:_d,lng:bd},required:["lat","lng","name"],additionalProperties:!1},cg={$id:yn("gpsMarkers"),type:"array",items:ZE},no={$id:yn("objectRecordNotNested"),type:"object",patternProperties:{"^.*$":{type:["string","number","boolean"]}},additionalProperties:!0},KE={$id:yn("anotatedText"),type:"array",items:{oneOf:[{type:"string"},{type:"array",items:{type:"string"}}]}},GE={$id:yn("repeaterObject"),oneOf:[{type:"object",patternProperties:{"^.*$":{type:"object"}},additionalProperties:!0},{type:"array",items:{type:"object"}}]},JE={$id:yn("chatBotMessage"),type:"object",properties:{role:{type:"string"},content:{oneOf:[{type:"string"},{type:"array",minItems:1,items:{type:"object",oneOf:[{type:"object",properties:{type:{type:"string",enum:["text"]},text:{type:"string"}},required:["type","text"],additionalProperties:!1},{type:"object",properties:{type:{type:"string",enum:["image_url"]},image_url:{type:"object",properties:{url:{type:"string",format:"uri",pattern:"^(https?:\\/\\/|data:image\\/)"}},required:["url"],additionalProperties:!1}},required:["type","image_url"],additionalProperties:!1}]}}]},tools:{type:"array",items:{type:"object",properties:{type:{type:"string"}},required:["type"],additionalProperties:!0}}},required:["role"],additionalProperties:!0},XE={$id:yn("chatBotMessages"),type:"array",items:JE},fn={$id:yn("positiveNumber"),type:"number",minimum:0},bi=new FE({strict:!0,allowUnionTypes:!0,allErrors:!0});UE(bi);function Vde(e){return(e==null?void 0:e.$id)===void 0?bi.compile(e):bi.getSchema(e.$id)||bi.compile(e)}const YE={uri:{format:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,errorMessage:"must be a valid URL"},uuid:{format:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,errorMessage:"must be a valid UUID"},cssClassnames:{format:/(^\s*[a-zA-Z_][-\w]*(\s+[a-zA-Z_][-\w]*)*\s*$)|(^$)/,errorMessage:"must be a valid list of CSS classes separated by spaces"},cssSize:{format:/(^([+-]?\d*\.?\d+)(px|em|%|vh|vw|rem|pt|pc|in|cm|mm|ex|ch|vmin|vmax|fr)$)|(^$)/,errorMessage:"must be a valid CSS size"},"writer#blueprintKey":{format:{type:"string",validate:e=>{const t=re(ne.core);return t?t.getComponents().filter(n=>n.type==="blueprints_blueprint").map(n=>n.content.key).includes(e):!0}},errorMessage:"must correspond to an existing blueprint key"}};Object.entries(YE).map(([e,t])=>bi.addFormat(e,t.format));const Ia={name:"Accent",type:Q.Color,category:ot.Style,applyStyleVariable:!0},ua={name:"Primary text",type:Q.Color,category:ot.Style,applyStyleVariable:!0},In={name:"Secondary text",type:Q.Color,category:ot.Style,applyStyleVariable:!0},dg={name:"Emptiness",desc:"Page background color",type:Q.Color,category:ot.Style,applyStyleVariable:!0},kr={name:"Container background",type:Q.Color,category:ot.Style,applyStyleVariable:!0},Rs={name:"Container shadow",type:Q.Shadow,category:ot.Style,applyStyleVariable:!0},wa={name:"Separator",type:Q.Color,category:ot.Style,applyStyleVariable:!0},cr={name:"Button",type:Q.Color,category:ot.Style,applyStyleVariable:!0},dr={name:"Button text",type:Q.Color,category:ot.Style,applyStyleVariable:!0},so={name:"Button shadow",type:Q.Shadow,category:ot.Style,applyStyleVariable:!0},mt={name:"Custom CSS classes",type:Q.Text,category:ot.Style,desc:"CSS classes, separated by spaces. You can define classes in custom stylesheets.",validator:qE},QE={name:"Content width",type:Q.Width,default:"100%",category:ot.Style,desc:"Configure content width using CSS units, e.g. 100px, 50%, 10vw, etc.",validator:ig},Ns={name:"Content alignment (H)",type:Q.HAlign,default:"unset",category:ot.Style},wd={name:"Content alignment (V)",type:Q.VAlign,default:"unset",category:ot.Style},Ds={name:"Padding",type:Q.Padding,default:"0",category:ot.Style};function Ut(e){return{...e,type:Q.Boolean,validator:{type:"boolean"}}}function xd(e){return Ut({name:"Enable copy button",desc:"Enable a copy button that lets users to copy the contents in this field to their clipboard",default:e.default,category:ot.Style,order:1})}const ug=Ut({name:"Collapsible",default:"no",category:ot.Style}),Cd=Ut({name:"Start collapsed",category:ot.Style,default:"no",desc:"Only applied when the component is collapsible."}),eI=new Set(["wds-blocks","wds-function","wds-blueprints","wds-send","wds-at-sign-slash"]);function tI(e){return eI.has(e)}const aI=$e({__name:"CustomIcon",props:{name:{type:String,required:!0}},setup(e){const t="1em";return(a,n)=>e.name==="wds-blocks"?($(),R("svg",{key:0,height:t,width:t,viewBox:"1 2 15 15",xmlns:"http://www.w3.org/2000/svg",fill:"none",stroke:"currentColor"},n[0]||(n[0]=[Z("line",{x1:"13.5",y1:"2",x2:"13.5",y2:"7"},null,-1),Z("line",{x1:"16",y1:"4.5",x2:"11",y2:"4.5"},null,-1),Z("path",{d:"M7.5 15.75V6C7.5 5.80109 7.42098 5.61032 7.28033 5.46967C7.13968 5.32902 6.94891 5.25 6.75 5.25H3C2.80109 5.25 2.61032 5.32902 2.46967 5.46967C2.32902 5.61032 2.25 5.80109 2.25 6V15C2.25 15.1989 2.32902 15.3897 2.46967 15.5303C2.61032 15.671 2.80109 15.75 3 15.75H12C12.1989 15.75 12.3897 15.671 12.5303 15.5303C12.671 15.3897 12.75 15.1989 12.75 15V11.25C12.75 11.0511 12.671 10.8603 12.5303 10.7197C12.3897 10.579 12.1989 10.5 12 10.5H2.25"},null,-1)]))):e.name==="wds-blueprints"?($(),R("svg",{key:1,width:t,height:t,viewBox:"2 2 15 15",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[1]||(n[1]=[Z("path",{d:"M14 2.5C15.3807 2.5 16.5 3.61929 16.5 5C16.5 6.38071 15.3807 7.5 14 7.5C12.7905 7.5 11.7814 6.64114 11.5498 5.5H7.4502C7.25138 6.47953 6.47951 7.25033 5.5 7.44922V11.5498C6.64114 11.7814 7.5 12.7905 7.5 14C7.5 15.3807 6.38071 16.5 5 16.5C3.61929 16.5 2.5 15.3807 2.5 14C2.5 12.7905 3.35886 11.7814 4.5 11.5498V7.44922C3.35895 7.21753 2.5 6.20943 2.5 5C2.5 3.61929 3.61929 2.5 5 2.5C6.20949 2.5 7.21858 3.35886 7.4502 4.5H11.5498C11.7814 3.35886 12.7905 2.5 14 2.5ZM14 11.5C15.3807 11.5 16.5 12.6193 16.5 14C16.5 15.3807 15.3807 16.5 14 16.5C12.6193 16.5 11.5 15.3807 11.5 14C11.5 12.6193 12.6193 11.5 14 11.5ZM5 12.5C4.17157 12.5 3.5 13.1716 3.5 14C3.5 14.8284 4.17157 15.5 5 15.5C5.82843 15.5 6.5 14.8284 6.5 14C6.5 13.1716 5.82843 12.5 5 12.5ZM14 12.5C13.1716 12.5 12.5 13.1716 12.5 14C12.5 14.8284 13.1716 15.5 14 15.5C14.8284 15.5 15.5 14.8284 15.5 14C15.5 13.1716 14.8284 12.5 14 12.5ZM5 3.5C4.17157 3.5 3.5 4.17157 3.5 5C3.5 5.82843 4.17157 6.5 5 6.5C5.82843 6.5 6.5 5.82843 6.5 5C6.5 4.17157 5.82843 3.5 5 3.5ZM14 3.5C13.1716 3.5 12.5 4.17157 12.5 5C12.5 5.82843 13.1716 6.5 14 6.5C14.8284 6.5 15.5 5.82843 15.5 5C15.5 4.17157 14.8284 3.5 14 3.5Z"},null,-1)]))):e.name==="wds-function"?($(),R("svg",{key:2,width:t,height:t,viewBox:"1 1 10 10",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[2]||(n[2]=[Z("path",{d:"M5.62515 8.875V8.125H6.3329L7.75115 6.5L6.3329 4.875H5.44052L4.64052 9.074C4.56111 9.50033 4.41098 9.82375 4.19015 10.0442C3.96932 10.2647 3.68419 10.375 3.33477 10.375C3.00144 10.375 2.72936 10.2846 2.51852 10.1039C2.30761 9.92304 2.20215 9.68363 2.20215 9.38562C2.20215 9.16062 2.26094 8.97967 2.37852 8.84275C2.49619 8.70592 2.64573 8.6375 2.82715 8.6375C3.00023 8.6375 3.14765 8.69713 3.2694 8.81638C3.39123 8.93563 3.45215 9.07921 3.45215 9.24713C3.45215 9.31446 3.43723 9.37358 3.4074 9.4245C3.37757 9.4755 3.34086 9.51542 3.29727 9.54425C3.31327 9.56025 3.33573 9.57387 3.36465 9.58512C3.39348 9.59629 3.42552 9.60188 3.46077 9.60188C3.56977 9.59679 3.6589 9.54667 3.72815 9.4515C3.79732 9.35625 3.85307 9.20958 3.8954 9.0115L4.67527 4.875H3.2214V4.125H4.81465L5.06752 2.75775C5.13227 2.40583 5.27732 2.12904 5.50265 1.92738C5.72798 1.72579 6.0044 1.625 6.3319 1.625C6.66015 1.625 6.92969 1.72133 7.14052 1.914C7.35144 2.10658 7.4569 2.34933 7.4569 2.64225C7.4569 2.857 7.39811 3.03283 7.28052 3.16975C7.16286 3.30658 7.01332 3.375 6.8319 3.375C6.65882 3.375 6.5114 3.31617 6.38965 3.1985C6.26782 3.08092 6.2069 2.93558 6.2069 2.7625C6.2069 2.69517 6.22182 2.63604 6.25165 2.58512C6.28148 2.53412 6.31977 2.49421 6.36652 2.46537C6.35052 2.44612 6.32569 2.43008 6.29202 2.41725C6.25836 2.4045 6.2239 2.39812 6.18865 2.39812C6.08415 2.40837 6.00098 2.45421 5.93915 2.53562C5.87732 2.61704 5.83002 2.73754 5.79727 2.89713L5.58477 4.125H7.87515V4.875H7.32615L8.25015 5.92988L9.17427 4.875H8.62515V4.125H10.8751V4.875H10.1675L8.74927 6.5L10.1723 8.125H10.8751V8.875H8.62515V8.125H9.17427L8.25015 7.0625L7.32615 8.125H7.87515V8.875H5.62515Z"},null,-1)]))):e.name==="wds-send"?($(),R("svg",{key:3,width:t,height:t,viewBox:"0 0 14 12",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[3]||(n[3]=[Z("path",{d:"M14.0712 4.50295C14.2882 4.72002 14.2882 5.07197 14.0712 5.28905L10.5337 8.8265C10.3166 9.04357 9.96468 9.04357 9.7476 8.8265C9.53052 8.60942 9.53052 8.25747 9.7476 8.0404L12.892 4.896L9.7476 1.7516C9.53052 1.53452 9.53052 1.18257 9.7476 0.965495C9.96467 0.74842 10.3166 0.74842 10.5337 0.965495L14.0712 4.50295ZM13.6781 5.45185L3.67268 5.45185L3.67268 4.34014L13.6781 4.34014L13.6781 5.45185ZM2.00511 7.11942L2.00511 8.23114L0.893394 8.23114L0.893394 7.11942L2.00511 7.11942ZM3.67268 9.89871L5.52553 9.89871L5.52553 11.0104L3.67268 11.0104L3.67268 9.89871ZM2.00511 8.23114C2.00511 9.15211 2.7517 9.89871 3.67268 9.89871L3.67268 11.0104C2.13772 11.0104 0.893394 9.76609 0.893394 8.23114L2.00511 8.23114ZM3.67268 5.45185C2.7517 5.45185 2.00511 6.19845 2.00511 7.11942L0.893394 7.11942C0.893394 5.58447 2.13772 4.34014 3.67268 4.34014L3.67268 5.45185Z"},null,-1)]))):e.name==="wds-at-sign-slash"?($(),R("svg",{key:4,width:t,height:t,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[4]||(n[4]=[Z("path",{d:"M10.5616 2.24813C10.708 2.10174 10.9454 2.10177 11.0919 2.24813C11.2379 2.39461 11.2381 2.6321 11.0919 2.77841L10.4229 3.44638C11.0404 4.34151 11.375 5.40523 11.3751 6.49813V6.99813C11.375 7.49528 11.1778 7.97275 10.8262 8.32431C10.4747 8.67585 9.99722 8.87303 9.50008 8.87313C9.00296 8.87305 8.52545 8.67579 8.1739 8.32431C8.05906 8.20944 7.96236 8.07944 7.88191 7.94149C7.44779 8.50645 6.76761 8.87306 6.00008 8.87313C5.70185 8.87311 5.41736 8.81529 5.15437 8.71493L3.48836 10.3809C4.1994 10.8408 5.02632 11.099 5.87996 11.1212C6.92135 11.1482 7.94108 10.8224 8.77449 10.1974C8.94014 10.0732 9.17563 10.108 9.29988 10.2735C9.42391 10.4392 9.39028 10.6737 9.22469 10.7979L9.04012 10.9298C8.10738 11.5697 6.99503 11.9006 5.86043 11.8712C4.81461 11.844 3.80372 11.5111 2.94832 10.921L2.07625 11.794C1.92994 11.9403 1.69246 11.9401 1.54597 11.794C1.3996 11.6476 1.39955 11.4102 1.54597 11.2638L2.35847 10.4503L9.95222 2.85653L10.5616 2.24813ZM3.72176 1.62997C4.81841 1.11684 6.05705 0.988532 7.23543 1.26669C8.0363 1.45583 8.77676 1.82644 9.40535 2.34188L8.87117 2.87606C8.34295 2.45697 7.7272 2.15412 7.06258 1.99716C6.0487 1.75791 4.98268 1.86717 4.03914 2.30868C3.0957 2.75025 2.32924 3.4981 1.86336 4.42978C1.39751 5.36152 1.2599 6.42372 1.47273 7.44345C1.62065 8.1516 1.9319 8.81087 2.37605 9.37118L1.84383 9.90341C1.29843 9.23815 0.916239 8.44848 0.738357 7.59677C0.490995 6.41173 0.65116 5.17763 1.19246 4.09481C1.7339 3.01195 2.62522 2.14316 3.72176 1.62997ZM5.7657 8.1036C5.84232 8.11469 5.92039 8.12313 6.00008 8.12313C6.84122 8.12301 7.53292 7.48333 7.61629 6.66415L7.62508 6.49813L7.61629 6.33212C7.61395 6.30911 7.60883 6.28647 7.60555 6.26376L5.7657 8.1036ZM8.37508 5.4952V6.99813C8.37516 7.29617 8.49356 7.5822 8.70418 7.79306C8.91508 8.00396 9.20182 8.12305 9.50008 8.12313C9.7983 8.12303 10.0841 8.00394 10.295 7.79306C10.5059 7.58216 10.625 7.29637 10.6251 6.99813V6.49813C10.625 5.60398 10.3641 4.73302 9.88191 3.98739L8.37508 5.4952ZM6.00008 4.12313C6.4633 4.12318 6.8947 4.25756 7.25984 4.48739L6.71004 5.0372C6.49561 4.93249 6.25486 4.87317 6.00008 4.87313C5.10278 4.87322 4.37522 5.60085 4.37508 6.49813C4.37511 6.75285 4.43527 6.99299 4.54012 7.20712L3.98836 7.75888C3.75876 7.39349 3.62512 6.96154 3.62508 6.49813C3.62522 5.18664 4.68856 4.12322 6.00008 4.12313Z"},null,-1)]))):ge("",!0)}});/**
36
+ deps: ${d}}`};const r={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(l){const[c,d]=o(l);s(l,c),i(l,d)}};function o({schema:l}){const c={},d={};for(const u in l){if(u==="__proto__")continue;const h=Array.isArray(l[u])?c:d;h[u]=l[u]}return[c,d]}function s(l,c=l.schema){const{gen:d,data:u,it:h}=l;if(Object.keys(c).length===0)return;const f=d.let("missing");for(const m in c){const g=c[m];if(g.length===0)continue;const _=(0,n.propertyInData)(d,u,m,h.opts.ownProperties);l.setParams({property:m,depsCount:g.length,deps:g.join(", ")}),h.allErrors?d.if(_,()=>{for(const b of g)(0,n.checkReportMissingProp)(l,b)}):(d.if((0,t._)`${_} && (${(0,n.checkMissingProp)(l,g,f)})`),(0,n.reportMissingProp)(l,f),d.else())}}e.validatePropertyDeps=s;function i(l,c=l.schema){const{gen:d,data:u,keyword:h,it:f}=l,m=d.name("valid");for(const g in c)(0,a.alwaysValidSchema)(f,c[g])||(d.if((0,n.propertyInData)(d,u,g,f.opts.ownProperties),()=>{const _=l.subschema({keyword:h,schemaProp:g},m);l.mergeValidEvaluated(_,m)},()=>d.var(m,!0)),l.ok(m))}e.validateSchemaDeps=i,e.default=r})(ng);var ld={};Object.defineProperty(ld,"__esModule",{value:!0});const rg=kt,H$=et,R$={message:"property name must be valid",params:({params:e})=>(0,rg._)`{propertyName: ${e.propertyName}}`},N$={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:R$,code(e){const{gen:t,schema:a,data:n,it:r}=e;if((0,H$.alwaysValidSchema)(r,a))return;const o=t.name("valid");t.forIn("key",n,s=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},o),t.if((0,rg.not)(o),()=>{e.error(!0),r.allErrors||t.break()})}),e.ok(o)}};ld.default=N$;var Ul={};Object.defineProperty(Ul,"__esModule",{value:!0});const C1=Pt,Hn=kt,D$=Kn,A1=et,B$={message:"must NOT have additional properties",params:({params:e})=>(0,Hn._)`{additionalProperty: ${e.additionalProperty}}`},F$={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:B$,code(e){const{gen:t,schema:a,parentSchema:n,data:r,errsCount:o,it:s}=e;if(!o)throw new Error("ajv implementation error");const{allErrors:i,opts:l}=s;if(s.props=!0,l.removeAdditional!=="all"&&(0,A1.alwaysValidSchema)(s,a))return;const c=(0,C1.allSchemaProperties)(n.properties),d=(0,C1.allSchemaProperties)(n.patternProperties);u(),e.ok((0,Hn._)`${o} === ${D$.default.errors}`);function u(){t.forIn("key",r,_=>{!c.length&&!d.length?m(_):t.if(h(_),()=>m(_))})}function h(_){let b;if(c.length>8){const v=(0,A1.schemaRefOrVal)(s,n.properties,"properties");b=(0,C1.isOwnProperty)(t,v,_)}else c.length?b=(0,Hn.or)(...c.map(v=>(0,Hn._)`${_} === ${v}`)):b=Hn.nil;return d.length&&(b=(0,Hn.or)(b,...d.map(v=>(0,Hn._)`${(0,C1.usePattern)(e,v)}.test(${_})`))),(0,Hn.not)(b)}function f(_){t.code((0,Hn._)`delete ${r}[${_}]`)}function m(_){if(l.removeAdditional==="all"||l.removeAdditional&&a===!1){f(_);return}if(a===!1){e.setParams({additionalProperty:_}),e.error(),i||t.break();return}if(typeof a=="object"&&!(0,A1.alwaysValidSchema)(s,a)){const b=t.name("valid");l.removeAdditional==="failing"?(g(_,b,!1),t.if((0,Hn.not)(b),()=>{e.reset(),f(_)})):(g(_,b),i||t.if((0,Hn.not)(b),()=>t.break()))}}function g(_,b,v){const y={keyword:"additionalProperties",dataProp:_,dataPropType:A1.Type.Str};v===!1&&Object.assign(y,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(y,b)}}};Ul.default=F$;var cd={};Object.defineProperty(cd,"__esModule",{value:!0});const j$=Sn,cp=Pt,W2=et,dp=Ul,U$={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:a,parentSchema:n,data:r,it:o}=e;o.opts.removeAdditional==="all"&&n.additionalProperties===void 0&&dp.default.code(new j$.KeywordCxt(o,dp.default,"additionalProperties"));const s=(0,cp.allSchemaProperties)(a);for(const u of s)o.definedProperties.add(u);o.opts.unevaluated&&s.length&&o.props!==!0&&(o.props=W2.mergeEvaluated.props(t,(0,W2.toHash)(s),o.props));const i=s.filter(u=>!(0,W2.alwaysValidSchema)(o,a[u]));if(i.length===0)return;const l=t.name("valid");for(const u of i)c(u)?d(u):(t.if((0,cp.propertyInData)(t,r,u,o.opts.ownProperties)),d(u),o.allErrors||t.else().var(l,!0),t.endIf()),e.it.definedProperties.add(u),e.ok(l);function c(u){return o.opts.useDefaults&&!o.compositeRule&&a[u].default!==void 0}function d(u){e.subschema({keyword:"properties",schemaProp:u,dataProp:u},l)}}};cd.default=U$;var dd={};Object.defineProperty(dd,"__esModule",{value:!0});const up=Pt,S1=kt,hp=et,pp=et,z$={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:a,data:n,parentSchema:r,it:o}=e,{opts:s}=o,i=(0,up.allSchemaProperties)(a),l=i.filter(g=>(0,hp.alwaysValidSchema)(o,a[g]));if(i.length===0||l.length===i.length&&(!o.opts.unevaluated||o.props===!0))return;const c=s.strictSchema&&!s.allowMatchingProperties&&r.properties,d=t.name("valid");o.props!==!0&&!(o.props instanceof S1.Name)&&(o.props=(0,pp.evaluatedPropsToName)(t,o.props));const{props:u}=o;h();function h(){for(const g of i)c&&f(g),o.allErrors?m(g):(t.var(d,!0),m(g),t.if(d))}function f(g){for(const _ in c)new RegExp(g).test(_)&&(0,hp.checkStrictMode)(o,`property ${_} matches pattern ${g} (use allowMatchingProperties)`)}function m(g){t.forIn("key",n,_=>{t.if((0,S1._)`${(0,up.usePattern)(e,g)}.test(${_})`,()=>{const b=l.includes(g);b||e.subschema({keyword:"patternProperties",schemaProp:g,dataProp:_,dataPropType:pp.Type.Str},d),o.opts.unevaluated&&u!==!0?t.assign((0,S1._)`${u}[${_}]`,!0):!b&&!o.allErrors&&t.if((0,S1.not)(d),()=>t.break())})})}}};dd.default=z$;var ud={};Object.defineProperty(ud,"__esModule",{value:!0});const q$=et,W$={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:a,it:n}=e;if((0,q$.alwaysValidSchema)(n,a)){e.fail();return}const r=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},r),e.failResult(r,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};ud.default=W$;var hd={};Object.defineProperty(hd,"__esModule",{value:!0});const Z$=Pt,K$={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:Z$.validateUnion,error:{message:"must match a schema in anyOf"}};hd.default=K$;var pd={};Object.defineProperty(pd,"__esModule",{value:!0});const U1=kt,G$=et,J$={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,U1._)`{passingSchemas: ${e.passing}}`},X$={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:J$,code(e){const{gen:t,schema:a,parentSchema:n,it:r}=e;if(!Array.isArray(a))throw new Error("ajv implementation error");if(r.opts.discriminator&&n.discriminator)return;const o=a,s=t.let("valid",!1),i=t.let("passing",null),l=t.name("_valid");e.setParams({passing:i}),t.block(c),e.result(s,()=>e.reset(),()=>e.error(!0));function c(){o.forEach((d,u)=>{let h;(0,G$.alwaysValidSchema)(r,d)?t.var(l,!0):h=e.subschema({keyword:"oneOf",schemaProp:u,compositeRule:!0},l),u>0&&t.if((0,U1._)`${l} && ${s}`).assign(s,!1).assign(i,(0,U1._)`[${i}, ${u}]`).else(),t.if(l,()=>{t.assign(s,!0),t.assign(i,u),h&&e.mergeEvaluated(h,U1.Name)})})}}};pd.default=X$;var fd={};Object.defineProperty(fd,"__esModule",{value:!0});const Y$=et,Q$={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:a,it:n}=e;if(!Array.isArray(a))throw new Error("ajv implementation error");const r=t.name("valid");a.forEach((o,s)=>{if((0,Y$.alwaysValidSchema)(n,o))return;const i=e.subschema({keyword:"allOf",schemaProp:s},r);e.ok(r),e.mergeEvaluated(i)})}};fd.default=Q$;var md={};Object.defineProperty(md,"__esModule",{value:!0});const pl=kt,og=et,eE={message:({params:e})=>(0,pl.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,pl._)`{failingKeyword: ${e.ifClause}}`},tE={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:eE,code(e){const{gen:t,parentSchema:a,it:n}=e;a.then===void 0&&a.else===void 0&&(0,og.checkStrictMode)(n,'"if" without "then" and "else" is ignored');const r=fp(n,"then"),o=fp(n,"else");if(!r&&!o)return;const s=t.let("valid",!0),i=t.name("_valid");if(l(),e.reset(),r&&o){const d=t.let("ifClause");e.setParams({ifClause:d}),t.if(i,c("then",d),c("else",d))}else r?t.if(i,c("then")):t.if((0,pl.not)(i),c("else"));e.pass(s,()=>e.error(!0));function l(){const d=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},i);e.mergeEvaluated(d)}function c(d,u){return()=>{const h=e.subschema({keyword:d},i);t.assign(s,i),e.mergeValidEvaluated(h,s),u?t.assign(u,(0,pl._)`${d}`):e.setParams({ifClause:d})}}}};function fp(e,t){const a=e.schema[t];return a!==void 0&&!(0,og.alwaysValidSchema)(e,a)}md.default=tE;var vd={};Object.defineProperty(vd,"__esModule",{value:!0});const aE=et,nE={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:a}){t.if===void 0&&(0,aE.checkStrictMode)(a,`"${e}" without "if" is ignored`)}};vd.default=nE;Object.defineProperty(rd,"__esModule",{value:!0});const rE=Hs,oE=od,sE=Rs,iE=sd,lE=id,cE=ng,dE=ld,uE=Ul,hE=cd,pE=dd,fE=ud,mE=hd,vE=pd,gE=fd,yE=md,ME=vd;function _E(e=!1){const t=[fE.default,mE.default,vE.default,gE.default,yE.default,ME.default,dE.default,uE.default,cE.default,hE.default,pE.default];return e?t.push(oE.default,iE.default):t.push(rE.default,sE.default),t.push(lE.default),t}rd.default=_E;var gd={},yd={};Object.defineProperty(yd,"__esModule",{value:!0});const ga=kt,bE={message:({schemaCode:e})=>(0,ga.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,ga._)`{format: ${e}}`},wE={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:bE,code(e,t){const{gen:a,data:n,$data:r,schema:o,schemaCode:s,it:i}=e,{opts:l,errSchemaPath:c,schemaEnv:d,self:u}=i;if(!l.validateFormats)return;r?h():f();function h(){const m=a.scopeValue("formats",{ref:u.formats,code:l.code.formats}),g=a.const("fDef",(0,ga._)`${m}[${s}]`),_=a.let("fType"),b=a.let("format");a.if((0,ga._)`typeof ${g} == "object" && !(${g} instanceof RegExp)`,()=>a.assign(_,(0,ga._)`${g}.type || "string"`).assign(b,(0,ga._)`${g}.validate`),()=>a.assign(_,(0,ga._)`"string"`).assign(b,g)),e.fail$data((0,ga.or)(v(),y()));function v(){return l.strictSchema===!1?ga.nil:(0,ga._)`${s} && !${b}`}function y(){const M=d.$async?(0,ga._)`(${g}.async ? await ${b}(${n}) : ${b}(${n}))`:(0,ga._)`${b}(${n})`,x=(0,ga._)`(typeof ${b} == "function" ? ${M} : ${b}.test(${n}))`;return(0,ga._)`${b} && ${b} !== true && ${_} === ${t} && !${x}`}}function f(){const m=u.formats[o];if(!m){v();return}if(m===!0)return;const[g,_,b]=y(m);g===t&&e.pass(M());function v(){if(l.strictSchema===!1){u.logger.warn(x());return}throw new Error(x());function x(){return`unknown format "${o}" ignored in schema at path "${c}"`}}function y(x){const S=x instanceof RegExp?(0,ga.regexpCode)(x):l.code.formats?(0,ga._)`${l.code.formats}${(0,ga.getProperty)(o)}`:void 0,L=a.scopeValue("formats",{key:o,ref:x,code:S});return typeof x=="object"&&!(x instanceof RegExp)?[x.type||"string",x.validate,(0,ga._)`${L}.validate`]:["string",x,L]}function M(){if(typeof m=="object"&&!(m instanceof RegExp)&&m.async){if(!d.$async)throw new Error("async format in sync schema");return(0,ga._)`await ${b}(${n})`}return typeof _=="function"?(0,ga._)`${b}(${n})`:(0,ga._)`${b}.test(${n})`}}}};yd.default=wE;Object.defineProperty(gd,"__esModule",{value:!0});const xE=yd,CE=[xE.default];gd.default=CE;var Es={};Object.defineProperty(Es,"__esModule",{value:!0});Es.contentVocabulary=Es.metadataVocabulary=void 0;Es.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Es.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"];Object.defineProperty(U0,"__esModule",{value:!0});const AE=z0,SE=W0,$E=rd,EE=gd,mp=Es,IE=[AE.default,SE.default,(0,$E.default)(),EE.default,mp.metadataVocabulary,mp.contentVocabulary];U0.default=IE;var Md={},zl={};Object.defineProperty(zl,"__esModule",{value:!0});zl.DiscrError=void 0;var vp;(function(e){e.Tag="tag",e.Mapping="mapping"})(vp||(zl.DiscrError=vp={}));Object.defineProperty(Md,"__esModule",{value:!0});const ss=kt,Rc=zl,gp=on,kE=Os,TE=et,PE={message:({params:{discrError:e,tagName:t}})=>e===Rc.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:a}})=>(0,ss._)`{error: ${e}, tag: ${a}, tagValue: ${t}}`},LE={keyword:"discriminator",type:"object",schemaType:"object",error:PE,code(e){const{gen:t,data:a,schema:n,parentSchema:r,it:o}=e,{oneOf:s}=r;if(!o.opts.discriminator)throw new Error("discriminator: requires discriminator option");const i=n.propertyName;if(typeof i!="string")throw new Error("discriminator: requires propertyName");if(n.mapping)throw new Error("discriminator: mapping is not supported");if(!s)throw new Error("discriminator: requires oneOf keyword");const l=t.let("valid",!1),c=t.const("tag",(0,ss._)`${a}${(0,ss.getProperty)(i)}`);t.if((0,ss._)`typeof ${c} == "string"`,()=>d(),()=>e.error(!1,{discrError:Rc.DiscrError.Tag,tag:c,tagName:i})),e.ok(l);function d(){const f=h();t.if(!1);for(const m in f)t.elseIf((0,ss._)`${c} === ${m}`),t.assign(l,u(f[m]));t.else(),e.error(!1,{discrError:Rc.DiscrError.Mapping,tag:c,tagName:i}),t.endIf()}function u(f){const m=t.name("valid"),g=e.subschema({keyword:"oneOf",schemaProp:f},m);return e.mergeEvaluated(g,ss.Name),m}function h(){var f;const m={},g=b(r);let _=!0;for(let M=0;M<s.length;M++){let x=s[M];if(x!=null&&x.$ref&&!(0,TE.schemaHasRulesButRef)(x,o.self.RULES)){const L=x.$ref;if(x=gp.resolveRef.call(o.self,o.schemaEnv.root,o.baseId,L),x instanceof gp.SchemaEnv&&(x=x.schema),x===void 0)throw new kE.default(o.opts.uriResolver,o.baseId,L)}const S=(f=x==null?void 0:x.properties)===null||f===void 0?void 0:f[i];if(typeof S!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${i}"`);_=_&&(g||b(x)),v(S,M)}if(!_)throw new Error(`discriminator: "${i}" must be required`);return m;function b({required:M}){return Array.isArray(M)&&M.includes(i)}function v(M,x){if(M.const)y(M.const,x);else if(M.enum)for(const S of M.enum)y(S,x);else throw new Error(`discriminator: "properties/${i}" must have "const" or "enum"`)}function y(M,x){if(typeof M!="string"||M in m)throw new Error(`discriminator: "${i}" values must be unique strings`);m[M]=x}}}};Md.default=LE;const VE="http://json-schema.org/draft-07/schema#",OE="http://json-schema.org/draft-07/schema#",HE="Core schema meta-schema",RE={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},NE=["object","boolean"],DE={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},BE={$schema:VE,$id:OE,title:HE,definitions:RE,type:NE,properties:DE,default:!0};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const a=d6,n=U0,r=Md,o=BE,s=["/properties"],i="http://json-schema.org/draft-07/schema";class l extends a.default{_addVocabularies(){super._addVocabularies(),n.default.forEach(m=>this.addVocabulary(m)),this.opts.discriminator&&this.addKeyword(r.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const m=this.opts.$data?this.$dataMetaSchema(o,s):o;this.addMetaSchema(m,i,!1),this.refs["http://json-schema.org/schema"]=i}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(i)?i:void 0)}}t.Ajv=l,e.exports=t=l,e.exports.Ajv=l,Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var c=Sn;Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return c.KeywordCxt}});var d=kt;Object.defineProperty(t,"_",{enumerable:!0,get:function(){return d._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return d.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return d.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return d.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return d.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return d.CodeGen}});var u=qi;Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return u.default}});var h=Os;Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return h.default}})})(Ic,Ic.exports);var sg=Ic.exports;const FE=E0(sg);var Nc={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const a=sg,n=kt,r=$s,o=Sn,s=Vs,i=Kn,l="errorMessage",c=new a.Name("emUsed"),d={required:"missingProperty",dependencies:"property",dependentRequired:"property"},u=/\$\{[^}]+\}/,h=/\$\{([^}]+)\}/g,f=/^""\s*\+\s*|\s*\+\s*""$/g;function m(_){return{keyword:l,schemaType:["string","object"],post:!0,code(b){const{gen:v,data:y,schema:M,schemaValue:x,it:S}=b;if(S.createErrors===!1)return;const L=M,F=n.strConcat(i.default.instancePath,S.errorPath);v.if(a._`${i.default.errors} > 0`,()=>{if(typeof L=="object"){const[k,C]=J(L);C&&be(C),k&&oe(k),Te(te(L))}const O=typeof L=="string"?L:L._;O&&Ue(O),_.keepErrors||Ze()});function te({properties:O,items:k}){const C={};if(O){C.props={};for(const P in O)C.props[P]=[]}if(k){C.items={};for(let P=0;P<k.length;P++)C.items[P]=[]}return C}function J(O){let k,C;for(const P in O){if(P==="properties"||P==="items")continue;const ae=O[P];if(typeof ae=="object"){k||(k={});const xe=k[P]={};for(const ve in ae)xe[ve]=[]}else C||(C={}),C[P]=[]}return[k,C]}function be(O){const k=v.const("emErrors",a.stringify(O)),C=v.const("templates",K(O,M));v.forOf("err",i.default.vErrors,ve=>v.if(Me(ve,k),()=>v.code(a._`${k}[${ve}.keyword].push(${ve})`).assign(a._`${ve}.${c}`,!0)));const{singleError:P}=_;if(P){const ve=v.let("message",a._`""`),ze=v.let("paramsErrors",a._`[]`);ae(Ye=>{v.if(ve,()=>v.code(a._`${ve} += ${typeof P=="string"?P:";"}`)),v.code(a._`${ve} += ${xe(Ye)}`),v.assign(ze,a._`${ze}.concat(${k}[${Ye}])`)}),s.reportError(b,{message:ve,params:a._`{errors: ${ze}}`})}else ae(ve=>s.reportError(b,{message:xe(ve),params:a._`{errors: ${k}[${ve}]}`}));function ae(ve){v.forIn("key",k,ze=>v.if(a._`${k}[${ze}].length`,()=>ve(ze)))}function xe(ve){return a._`${ve} in ${C} ? ${C}[${ve}]() : ${x}[${ve}]`}}function oe(O){const k=v.const("emErrors",a.stringify(O)),C=[];for(const ze in O)C.push([ze,K(O[ze],M[ze])]);const P=v.const("templates",v.object(...C)),ae=v.scopeValue("obj",{ref:d,code:a.stringify(d)}),xe=v.let("emPropParams"),ve=v.let("emParamsErrors");v.forOf("err",i.default.vErrors,ze=>v.if(Me(ze,k),()=>{v.assign(xe,a._`${ae}[${ze}.keyword]`),v.assign(ve,a._`${k}[${ze}.keyword][${ze}.params[${xe}]]`),v.if(ve,()=>v.code(a._`${ve}.push(${ze})`).assign(a._`${ze}.${c}`,!0))})),v.forIn("key",k,ze=>v.forIn("keyProp",a._`${k}[${ze}]`,Ye=>{v.assign(ve,a._`${k}[${ze}][${Ye}]`),v.if(a._`${ve}.length`,()=>{const ct=v.const("tmpl",a._`${P}[${ze}] && ${P}[${ze}][${Ye}]`);s.reportError(b,{message:a._`${ct} ? ${ct}() : ${x}[${ze}][${Ye}]`,params:a._`{errors: ${ve}}`})})}))}function Te(O){const{props:k,items:C}=O;if(!k&&!C)return;const P=a._`typeof ${y} == "object"`,ae=a._`Array.isArray(${y})`,xe=v.let("emErrors");let ve,ze;const Ye=v.let("templates");k&&C?(ve=v.let("emChildKwd"),v.if(P),v.if(ae,()=>{ct(C,M.items),v.assign(ve,a.str`items`)},()=>{ct(k,M.properties),v.assign(ve,a.str`properties`)}),ze=a._`[${ve}]`):C?(v.if(ae),ct(C,M.items),ze=a._`.items`):k&&(v.if(n.and(P,n.not(ae))),ct(k,M.properties),ze=a._`.properties`),v.forOf("err",i.default.vErrors,xt=>ee(xt,xe,D=>v.code(a._`${xe}[${D}].push(${xt})`).assign(a._`${xt}.${c}`,!0))),v.forIn("key",xe,xt=>v.if(a._`${xe}[${xt}].length`,()=>{s.reportError(b,{message:a._`${xt} in ${Ye} ? ${Ye}[${xt}]() : ${x}${ze}[${xt}]`,params:a._`{errors: ${xe}[${xt}]}`}),v.assign(a._`${i.default.vErrors}[${i.default.errors}-1].instancePath`,a._`${F} + "/" + ${xt}.replace(/~/g, "~0").replace(/\\//g, "~1")`)})),v.endIf();function ct(xt,D){v.assign(xe,a.stringify(xt)),v.assign(Ye,K(xt,D))}}function Ue(O){const k=v.const("emErrs",a._`[]`);v.forOf("err",i.default.vErrors,C=>v.if(j(C),()=>v.code(a._`${k}.push(${C})`).assign(a._`${C}.${c}`,!0))),v.if(a._`${k}.length`,()=>s.reportError(b,{message:G(O),params:a._`{errors: ${k}}`}))}function Ze(){const O=v.const("emErrs",a._`[]`);v.forOf("err",i.default.vErrors,k=>v.if(a._`!${k}.${c}`,()=>v.code(a._`${O}.push(${k})`))),v.assign(i.default.vErrors,O).assign(i.default.errors,a._`${O}.length`)}function Me(O,k){return n.and(a._`${O}.keyword !== ${l}`,a._`!${O}.${c}`,a._`${O}.instancePath === ${F}`,a._`${O}.keyword in ${k}`,a._`${O}.schemaPath.indexOf(${S.errSchemaPath}) === 0`,a._`/^\\/[^\\/]*$/.test(${O}.schemaPath.slice(${S.errSchemaPath.length}))`)}function ee(O,k,C){v.if(n.and(a._`${O}.keyword !== ${l}`,a._`!${O}.${c}`,a._`${O}.instancePath.indexOf(${F}) === 0`),()=>{const P=v.scopeValue("pattern",{ref:/^\/([^/]*)(?:\/|$)/,code:a._`new RegExp("^\\\/([^/]*)(?:\\\/|$)")`}),ae=v.const("emMatches",a._`${P}.exec(${O}.instancePath.slice(${F}.length))`),xe=v.const("emChild",a._`${ae} && ${ae}[1].replace(/~1/g, "/").replace(/~0/g, "~")`);v.if(a._`${xe} !== undefined && ${xe} in ${k}`,()=>C(xe))})}function j(O){return n.and(a._`${O}.keyword !== ${l}`,a._`!${O}.${c}`,n.or(a._`${O}.instancePath === ${F}`,n.and(a._`${O}.instancePath.indexOf(${F}) === 0`,a._`${O}.instancePath[${F}.length] === "/"`)),a._`${O}.schemaPath.indexOf(${S.errSchemaPath}) === 0`,a._`${O}.schemaPath[${S.errSchemaPath}.length] === "/"`)}function K(O,k){const C=[];for(const P in O){const ae=k[P];u.test(ae)&&C.push([P,T(ae)])}return v.object(...C)}function G(O){return u.test(O)?new r._Code(r.safeStringify(O).replace(h,(k,C)=>`" + JSON.stringify(${o.getData(C,S)}) + "`).replace(f,"")):a.stringify(O)}function T(O){return a._`function(){return ${G(O)}}`}},metaSchema:{anyOf:[{type:"string"},{type:"object",properties:{properties:{$ref:"#/$defs/stringMap"},items:{$ref:"#/$defs/stringList"},required:{$ref:"#/$defs/stringOrMap"},dependencies:{$ref:"#/$defs/stringOrMap"}},additionalProperties:{type:"string"}}],$defs:{stringMap:{type:"object",additionalProperties:{type:"string"}},stringOrMap:{anyOf:[{type:"string"},{$ref:"#/$defs/stringMap"}]},stringList:{type:"array",items:{type:"string"}}}}}}const g=(_,b={})=>{if(!_.opts.allErrors)throw new Error("ajv-errors: Ajv option allErrors must be true");if(_.opts.jsPropertySyntax)throw new Error("ajv-errors: ajv option jsPropertySyntax is not supported");return _.addKeyword(m(b))};t.default=g,e.exports=g,e.exports.default=g})(Nc,Nc.exports);var jE=Nc.exports;const UE=E0(jE);var zE=(e=>(e.WriterBlueprintKey="writer#blueprintKey",e.CssClassnames="cssClassnames",e.CssSize="cssSize",e.Uri="uri",e.Uuid="uuid",e))(zE||{});function yn(e){return`https://dev.writer.com/framework/${encodeURIComponent(e)}.json`}function Lde(e){return{$id:yn(e.join(",")),type:"string",enum:e}}function _i(e,t){return{$id:yn(`between-${e}-${t}`),type:"number",minimum:e,maximum:t}}const qE={$id:yn("cssClassname"),type:"string",format:"cssClassnames"},ig={$id:yn("cssSize"),type:"string",format:"cssSize"};function WE(e,t){const a=e.getComponents().filter(n=>{var r;return n.type==="blueprints_blueprint"&&n.id!==t&&((r=n.content)==null?void 0:r.key)}).map(n=>n.content.key);if(a.length!==0)return{type:"string",not:{enum:[...new Set(a)]},errorMessage:"Must be unique"}}const lg={$id:yn("arrayOfString"),type:"array",items:{type:"string"}},_d=_i(-90,90),bd=_i(-180,180),ZE={$id:yn("gpsMarker"),type:"object",properties:{name:{type:"string"},lat:_d,lng:bd},required:["lat","lng","name"],additionalProperties:!1},cg={$id:yn("gpsMarkers"),type:"array",items:ZE},ro={$id:yn("objectRecordNotNested"),type:"object",patternProperties:{"^.*$":{type:["string","number","boolean"]}},additionalProperties:!0},KE={$id:yn("anotatedText"),type:"array",items:{oneOf:[{type:"string"},{type:"array",items:{type:"string"}}]}},GE={$id:yn("repeaterObject"),oneOf:[{type:"object",patternProperties:{"^.*$":{type:"object"}},additionalProperties:!0},{type:"array",items:{type:"object"}}]},JE={$id:yn("chatBotMessage"),type:"object",properties:{role:{type:"string"},content:{oneOf:[{type:"string"},{type:"array",minItems:1,items:{type:"object",oneOf:[{type:"object",properties:{type:{type:"string",enum:["text"]},text:{type:"string"}},required:["type","text"],additionalProperties:!1},{type:"object",properties:{type:{type:"string",enum:["image_url"]},image_url:{type:"object",properties:{url:{type:"string",format:"uri",pattern:"^(https?:\\/\\/|data:image\\/)"}},required:["url"],additionalProperties:!1}},required:["type","image_url"],additionalProperties:!1}]}}]},tools:{type:"array",items:{type:"object",properties:{type:{type:"string"}},required:["type"],additionalProperties:!0}}},required:["role"],additionalProperties:!0},XE={$id:yn("chatBotMessages"),type:"array",items:JE},fn={$id:yn("positiveNumber"),type:"number",minimum:0},bi=new FE({strict:!0,allowUnionTypes:!0,allErrors:!0});UE(bi);function Vde(e){return(e==null?void 0:e.$id)===void 0?bi.compile(e):bi.getSchema(e.$id)||bi.compile(e)}const YE={uri:{format:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,errorMessage:"must be a valid URL"},uuid:{format:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,errorMessage:"must be a valid UUID"},cssClassnames:{format:/(^\s*[a-zA-Z_][-\w]*(\s+[a-zA-Z_][-\w]*)*\s*$)|(^$)/,errorMessage:"must be a valid list of CSS classes separated by spaces"},cssSize:{format:/(^([+-]?\d*\.?\d+)(px|em|%|vh|vw|rem|pt|pc|in|cm|mm|ex|ch|vmin|vmax|fr)$)|(^$)/,errorMessage:"must be a valid CSS size"},"writer#blueprintKey":{format:{type:"string",validate:e=>{const t=re(ne.core);return t?t.getComponents().filter(n=>n.type==="blueprints_blueprint").map(n=>n.content.key).includes(e):!0}},errorMessage:"must correspond to an existing blueprint key"}};Object.entries(YE).map(([e,t])=>bi.addFormat(e,t.format));const Ia={name:"Accent",type:Q.Color,category:ot.Style,applyStyleVariable:!0},ua={name:"Primary text",type:Q.Color,category:ot.Style,applyStyleVariable:!0},In={name:"Secondary text",type:Q.Color,category:ot.Style,applyStyleVariable:!0},dg={name:"Emptiness",desc:"Page background color",type:Q.Color,category:ot.Style,applyStyleVariable:!0},Tr={name:"Container background",type:Q.Color,category:ot.Style,applyStyleVariable:!0},Ns={name:"Container shadow",type:Q.Shadow,category:ot.Style,applyStyleVariable:!0},wa={name:"Separator",type:Q.Color,category:ot.Style,applyStyleVariable:!0},dr={name:"Button",type:Q.Color,category:ot.Style,applyStyleVariable:!0},ur={name:"Button text",type:Q.Color,category:ot.Style,applyStyleVariable:!0},io={name:"Button shadow",type:Q.Shadow,category:ot.Style,applyStyleVariable:!0},mt={name:"Custom CSS classes",type:Q.Text,category:ot.Style,desc:"CSS classes, separated by spaces. You can define classes in custom stylesheets.",validator:qE},QE={name:"Content width",type:Q.Width,default:"100%",category:ot.Style,desc:"Configure content width using CSS units, e.g. 100px, 50%, 10vw, etc.",validator:ig},Ds={name:"Content alignment (H)",type:Q.HAlign,default:"unset",category:ot.Style},wd={name:"Content alignment (V)",type:Q.VAlign,default:"unset",category:ot.Style},Bs={name:"Padding",type:Q.Padding,default:"0",category:ot.Style};function Ut(e){return{...e,type:Q.Boolean,validator:{type:"boolean"}}}function xd(e){return Ut({name:"Enable copy button",desc:"Enable a copy button that lets users to copy the contents in this field to their clipboard",default:e.default,category:ot.Style,order:1})}const ug=Ut({name:"Collapsible",default:"no",category:ot.Style}),Cd=Ut({name:"Start collapsed",category:ot.Style,default:"no",desc:"Only applied when the component is collapsible."}),eI=new Set(["wds-blocks","wds-function","wds-blueprints","wds-send","wds-at-sign-slash"]);function tI(e){return eI.has(e)}const aI=$e({__name:"CustomIcon",props:{name:{type:String,required:!0}},setup(e){const t="1em";return(a,n)=>e.name==="wds-blocks"?($(),R("svg",{key:0,height:t,width:t,viewBox:"1 2 15 15",xmlns:"http://www.w3.org/2000/svg",fill:"none",stroke:"currentColor"},n[0]||(n[0]=[Z("line",{x1:"13.5",y1:"2",x2:"13.5",y2:"7"},null,-1),Z("line",{x1:"16",y1:"4.5",x2:"11",y2:"4.5"},null,-1),Z("path",{d:"M7.5 15.75V6C7.5 5.80109 7.42098 5.61032 7.28033 5.46967C7.13968 5.32902 6.94891 5.25 6.75 5.25H3C2.80109 5.25 2.61032 5.32902 2.46967 5.46967C2.32902 5.61032 2.25 5.80109 2.25 6V15C2.25 15.1989 2.32902 15.3897 2.46967 15.5303C2.61032 15.671 2.80109 15.75 3 15.75H12C12.1989 15.75 12.3897 15.671 12.5303 15.5303C12.671 15.3897 12.75 15.1989 12.75 15V11.25C12.75 11.0511 12.671 10.8603 12.5303 10.7197C12.3897 10.579 12.1989 10.5 12 10.5H2.25"},null,-1)]))):e.name==="wds-blueprints"?($(),R("svg",{key:1,width:t,height:t,viewBox:"2 2 15 15",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[1]||(n[1]=[Z("path",{d:"M14 2.5C15.3807 2.5 16.5 3.61929 16.5 5C16.5 6.38071 15.3807 7.5 14 7.5C12.7905 7.5 11.7814 6.64114 11.5498 5.5H7.4502C7.25138 6.47953 6.47951 7.25033 5.5 7.44922V11.5498C6.64114 11.7814 7.5 12.7905 7.5 14C7.5 15.3807 6.38071 16.5 5 16.5C3.61929 16.5 2.5 15.3807 2.5 14C2.5 12.7905 3.35886 11.7814 4.5 11.5498V7.44922C3.35895 7.21753 2.5 6.20943 2.5 5C2.5 3.61929 3.61929 2.5 5 2.5C6.20949 2.5 7.21858 3.35886 7.4502 4.5H11.5498C11.7814 3.35886 12.7905 2.5 14 2.5ZM14 11.5C15.3807 11.5 16.5 12.6193 16.5 14C16.5 15.3807 15.3807 16.5 14 16.5C12.6193 16.5 11.5 15.3807 11.5 14C11.5 12.6193 12.6193 11.5 14 11.5ZM5 12.5C4.17157 12.5 3.5 13.1716 3.5 14C3.5 14.8284 4.17157 15.5 5 15.5C5.82843 15.5 6.5 14.8284 6.5 14C6.5 13.1716 5.82843 12.5 5 12.5ZM14 12.5C13.1716 12.5 12.5 13.1716 12.5 14C12.5 14.8284 13.1716 15.5 14 15.5C14.8284 15.5 15.5 14.8284 15.5 14C15.5 13.1716 14.8284 12.5 14 12.5ZM5 3.5C4.17157 3.5 3.5 4.17157 3.5 5C3.5 5.82843 4.17157 6.5 5 6.5C5.82843 6.5 6.5 5.82843 6.5 5C6.5 4.17157 5.82843 3.5 5 3.5ZM14 3.5C13.1716 3.5 12.5 4.17157 12.5 5C12.5 5.82843 13.1716 6.5 14 6.5C14.8284 6.5 15.5 5.82843 15.5 5C15.5 4.17157 14.8284 3.5 14 3.5Z"},null,-1)]))):e.name==="wds-function"?($(),R("svg",{key:2,width:t,height:t,viewBox:"1 1 10 10",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[2]||(n[2]=[Z("path",{d:"M5.62515 8.875V8.125H6.3329L7.75115 6.5L6.3329 4.875H5.44052L4.64052 9.074C4.56111 9.50033 4.41098 9.82375 4.19015 10.0442C3.96932 10.2647 3.68419 10.375 3.33477 10.375C3.00144 10.375 2.72936 10.2846 2.51852 10.1039C2.30761 9.92304 2.20215 9.68363 2.20215 9.38562C2.20215 9.16062 2.26094 8.97967 2.37852 8.84275C2.49619 8.70592 2.64573 8.6375 2.82715 8.6375C3.00023 8.6375 3.14765 8.69713 3.2694 8.81638C3.39123 8.93563 3.45215 9.07921 3.45215 9.24713C3.45215 9.31446 3.43723 9.37358 3.4074 9.4245C3.37757 9.4755 3.34086 9.51542 3.29727 9.54425C3.31327 9.56025 3.33573 9.57387 3.36465 9.58512C3.39348 9.59629 3.42552 9.60188 3.46077 9.60188C3.56977 9.59679 3.6589 9.54667 3.72815 9.4515C3.79732 9.35625 3.85307 9.20958 3.8954 9.0115L4.67527 4.875H3.2214V4.125H4.81465L5.06752 2.75775C5.13227 2.40583 5.27732 2.12904 5.50265 1.92738C5.72798 1.72579 6.0044 1.625 6.3319 1.625C6.66015 1.625 6.92969 1.72133 7.14052 1.914C7.35144 2.10658 7.4569 2.34933 7.4569 2.64225C7.4569 2.857 7.39811 3.03283 7.28052 3.16975C7.16286 3.30658 7.01332 3.375 6.8319 3.375C6.65882 3.375 6.5114 3.31617 6.38965 3.1985C6.26782 3.08092 6.2069 2.93558 6.2069 2.7625C6.2069 2.69517 6.22182 2.63604 6.25165 2.58512C6.28148 2.53412 6.31977 2.49421 6.36652 2.46537C6.35052 2.44612 6.32569 2.43008 6.29202 2.41725C6.25836 2.4045 6.2239 2.39812 6.18865 2.39812C6.08415 2.40837 6.00098 2.45421 5.93915 2.53562C5.87732 2.61704 5.83002 2.73754 5.79727 2.89713L5.58477 4.125H7.87515V4.875H7.32615L8.25015 5.92988L9.17427 4.875H8.62515V4.125H10.8751V4.875H10.1675L8.74927 6.5L10.1723 8.125H10.8751V8.875H8.62515V8.125H9.17427L8.25015 7.0625L7.32615 8.125H7.87515V8.875H5.62515Z"},null,-1)]))):e.name==="wds-send"?($(),R("svg",{key:3,width:t,height:t,viewBox:"0 0 14 12",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[3]||(n[3]=[Z("path",{d:"M14.0712 4.50295C14.2882 4.72002 14.2882 5.07197 14.0712 5.28905L10.5337 8.8265C10.3166 9.04357 9.96468 9.04357 9.7476 8.8265C9.53052 8.60942 9.53052 8.25747 9.7476 8.0404L12.892 4.896L9.7476 1.7516C9.53052 1.53452 9.53052 1.18257 9.7476 0.965495C9.96467 0.74842 10.3166 0.74842 10.5337 0.965495L14.0712 4.50295ZM13.6781 5.45185L3.67268 5.45185L3.67268 4.34014L13.6781 4.34014L13.6781 5.45185ZM2.00511 7.11942L2.00511 8.23114L0.893394 8.23114L0.893394 7.11942L2.00511 7.11942ZM3.67268 9.89871L5.52553 9.89871L5.52553 11.0104L3.67268 11.0104L3.67268 9.89871ZM2.00511 8.23114C2.00511 9.15211 2.7517 9.89871 3.67268 9.89871L3.67268 11.0104C2.13772 11.0104 0.893394 9.76609 0.893394 8.23114L2.00511 8.23114ZM3.67268 5.45185C2.7517 5.45185 2.00511 6.19845 2.00511 7.11942L0.893394 7.11942C0.893394 5.58447 2.13772 4.34014 3.67268 4.34014L3.67268 5.45185Z"},null,-1)]))):e.name==="wds-at-sign-slash"?($(),R("svg",{key:4,width:t,height:t,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor"},n[4]||(n[4]=[Z("path",{d:"M10.5616 2.24813C10.708 2.10174 10.9454 2.10177 11.0919 2.24813C11.2379 2.39461 11.2381 2.6321 11.0919 2.77841L10.4229 3.44638C11.0404 4.34151 11.375 5.40523 11.3751 6.49813V6.99813C11.375 7.49528 11.1778 7.97275 10.8262 8.32431C10.4747 8.67585 9.99722 8.87303 9.50008 8.87313C9.00296 8.87305 8.52545 8.67579 8.1739 8.32431C8.05906 8.20944 7.96236 8.07944 7.88191 7.94149C7.44779 8.50645 6.76761 8.87306 6.00008 8.87313C5.70185 8.87311 5.41736 8.81529 5.15437 8.71493L3.48836 10.3809C4.1994 10.8408 5.02632 11.099 5.87996 11.1212C6.92135 11.1482 7.94108 10.8224 8.77449 10.1974C8.94014 10.0732 9.17563 10.108 9.29988 10.2735C9.42391 10.4392 9.39028 10.6737 9.22469 10.7979L9.04012 10.9298C8.10738 11.5697 6.99503 11.9006 5.86043 11.8712C4.81461 11.844 3.80372 11.5111 2.94832 10.921L2.07625 11.794C1.92994 11.9403 1.69246 11.9401 1.54597 11.794C1.3996 11.6476 1.39955 11.4102 1.54597 11.2638L2.35847 10.4503L9.95222 2.85653L10.5616 2.24813ZM3.72176 1.62997C4.81841 1.11684 6.05705 0.988532 7.23543 1.26669C8.0363 1.45583 8.77676 1.82644 9.40535 2.34188L8.87117 2.87606C8.34295 2.45697 7.7272 2.15412 7.06258 1.99716C6.0487 1.75791 4.98268 1.86717 4.03914 2.30868C3.0957 2.75025 2.32924 3.4981 1.86336 4.42978C1.39751 5.36152 1.2599 6.42372 1.47273 7.44345C1.62065 8.1516 1.9319 8.81087 2.37605 9.37118L1.84383 9.90341C1.29843 9.23815 0.916239 8.44848 0.738357 7.59677C0.490995 6.41173 0.65116 5.17763 1.19246 4.09481C1.7339 3.01195 2.62522 2.14316 3.72176 1.62997ZM5.7657 8.1036C5.84232 8.11469 5.92039 8.12313 6.00008 8.12313C6.84122 8.12301 7.53292 7.48333 7.61629 6.66415L7.62508 6.49813L7.61629 6.33212C7.61395 6.30911 7.60883 6.28647 7.60555 6.26376L5.7657 8.1036ZM8.37508 5.4952V6.99813C8.37516 7.29617 8.49356 7.5822 8.70418 7.79306C8.91508 8.00396 9.20182 8.12305 9.50008 8.12313C9.7983 8.12303 10.0841 8.00394 10.295 7.79306C10.5059 7.58216 10.625 7.29637 10.6251 6.99813V6.49813C10.625 5.60398 10.3641 4.73302 9.88191 3.98739L8.37508 5.4952ZM6.00008 4.12313C6.4633 4.12318 6.8947 4.25756 7.25984 4.48739L6.71004 5.0372C6.49561 4.93249 6.25486 4.87317 6.00008 4.87313C5.10278 4.87322 4.37522 5.60085 4.37508 6.49813C4.37511 6.75285 4.43527 6.99299 4.54012 7.20712L3.98836 7.75888C3.75876 7.39349 3.62512 6.96154 3.62508 6.49813C3.62522 5.18664 4.68856 4.12322 6.00008 4.12313Z"},null,-1)]))):ge("",!0)}});/**
37
37
  * @license lucide v0.525.0 - ISC
38
38
  *
39
39
  * This source code is licensed under the ISC license.
@@ -8116,7 +8116,7 @@ var w2=(e,t,a)=>{if(!t.has(e))throw TypeError("Cannot "+a)};var xt=(e,t,a)=>(w2(
8116
8116
  */const ute=({icons:e={},nameAttr:t="data-lucide",attrs:a={}}={})=>{if(!Object.values(e).length)throw new Error(`Please provide an icons object.
8117
8117
  If you want to use all the icons you can import it like:
8118
8118
  \`import { createIcons, icons } from 'lucide';
8119
- lucide.createIcons({icons});\``);if(typeof document>"u")throw new Error("`createIcons()` only works in a browser environment.");const n=document.querySelectorAll(`[${t}]`);if(Array.from(n).forEach(r=>yp(r,{nameAttr:t,icons:e,attrs:a})),t==="data-lucide"){const r=document.querySelectorAll("[icon-name]");r.length>0&&(console.warn("[Lucide] Some icons were found with the now deprecated icon-name attribute. These will still be replaced for backwards compatibility, but will no longer be supported in v1.0 and you should switch to data-lucide"),Array.from(r).forEach(o=>yp(o,{nameAttr:"icon-name",icons:e,attrs:a})))}},hte=["innerHTML"],pte=$e({inheritAttrs:!1,__name:"LucideIcon",props:{name:{type:String,required:!0}},setup(e){const t=e,a=ye("");function n(r){a.value=`<i data-lucide="${r}"></i>`,qa(()=>{ute({icons:dte,attrs:{width:"1em",height:"1em"}})})}return We(mn(t,"name"),r=>{n(r)},{immediate:!0,flush:"post"}),(r,o)=>($(),R("span",{style:{display:"contents"},innerHTML:a.value},null,8,hte))}}),_t=$e({inheritAttrs:!1,__name:"WdsIcon",props:{name:{type:String,required:!0}},setup(e){return(t,a)=>E(tI)(e.name)?($(),Ie(aI,{key:0,name:e.name},null,8,["name"])):($(),Ie(pte,{key:1,name:e.name},null,8,["name"]))}}),fte=["aria-invalid"],mte={key:1,class:"WdsTextInputLayout__rightText"},vte=$e({__name:"WdsTextInputLayout",props:{leftIcon:{type:String,required:!1,default:void 0},rightIcon:{type:String,required:!1,default:void 0},invalid:{type:Boolean,required:!1},variant:{type:String,default:void 0},rightText:{type:String,required:!1,default:""}},emits:{rightIconClick:()=>!0},setup(e){const t=e,a=H(()=>[t.leftIcon?"auto":void 0,"minmax(0, 1fr)",t.rightText?"auto":void 0,t.rightIcon?"auto":void 0].filter(Boolean).join(" "));return(n,r)=>($(),R("div",Bi({class:["WdsTextInputLayout",{"WdsTextInputLayout--ghost":e.variant==="ghost"}]},n.$attrs,{"aria-invalid":e.invalid,style:{gridTemplateColumns:a.value}}),[e.leftIcon?($(),Ie(_t,{key:0,name:e.leftIcon},null,8,["name"])):ge("",!0),qt(n.$slots,"default",{},void 0,!0),e.rightText?($(),R("p",mte,je(e.rightText),1)):ge("",!0),e.rightIcon?($(),R("button",{key:2,class:"WdsTextInputLayout__rightIcon",type:"button",onClick:r[0]||(r[0]=o=>n.$emit("rightIconClick"))},[Ce(_t,{name:e.rightIcon},null,8,["name"])])):ge("",!0)],16,fte))}}),gte=ke(vte,[["__scopeId","data-v-2e9a2df9"]]),yte=["autofocus"],Mte=$e({inheritAttrs:!1,__name:"WdsTextInput",props:Fn({leftIcon:{type:String,required:!1,default:void 0},rightIcon:{type:String,required:!1,default:void 0},invalid:{type:Boolean,required:!1},variant:{type:String,default:void 0},enableClearButton:{type:Boolean,required:!1},rightText:{type:String,required:!1,default:""},autofocus:{type:Boolean}},{modelValue:{type:String},modelModifiers:{}}),emits:Fn({rightIconClick:()=>!0},["update:modelValue"]),setup(e,{expose:t}){const a=ir(e,"modelValue"),n=e;t({focus:l,getSelection:i,value:a,setSelectionEnd:s,setSelectionStart:o});const r=pt("input");ia(()=>{n.autofocus&&l()});function o(c){r.value&&(r.value.selectionStart=c)}function s(c){r.value&&(r.value.selectionEnd=c)}function i(){var c,d;return{selectionStart:(c=r.value)==null?void 0:c.selectionStart,selectionEnd:(d=r.value)==null?void 0:d.selectionEnd}}function l(){var c;(c=r.value)==null||c.focus()}return(c,d)=>($(),Ie(gte,{"left-icon":e.leftIcon,"right-icon":e.rightIcon,invalid:e.invalid,variant:e.variant,"right-text":e.rightText,class:"WdsTextInput",onRightIconClick:d[1]||(d[1]=u=>c.$emit("rightIconClick")),onClick:l},{default:Xe(()=>[Ya(Z("input",Bi({ref_key:"input",ref:r,"onUpdate:modelValue":d[0]||(d[0]=u=>a.value=u),class:"WdsTextInput__input",autofocus:e.autofocus},c.$attrs),null,16,yte),[[M0,a.value]])]),_:1},8,["left-icon","right-icon","invalid","variant","right-text"]))}}),fg=ke(Mte,[["__scopeId","data-v-f987e149"]]),_te={};function bte(e,t){return $(),R("button",null,[qt(e.$slots,"default",{},void 0,!0)])}const wn=ke(_te,[["render",bte],["__scopeId","data-v-75345289"]]);function wte(e){const t=$t([]),a=ye(!1),n=fa();async function r(){if(!a.value){for(a.value=!0;t.value.length;){const[s,...i]=t.value;try{await e(s)}catch(l){n.error("Error during handling job",s,l)}finally{t.value=i}}a.value=!1}}function o(s){if(t.value=[...t.value,s],!a.value)return r()}return{push:o,isBusy:jt(a)}}function mg(e,t,a){function n(i){return i.type==="blueprints_uieventtrigger"&&i.content.refComponentId===E(t)&&i.content.refEventType===E(a)}const r=H(()=>[...new Set(o.value.map(l=>l.parentId))].map(l=>e.getComponentById(l)).filter(Boolean)),o=H(()=>e.getComponents("blueprints_root").flatMap(i=>e.getComponents(i.id).filter(n))),s=H(()=>o.value.length>0);return{blueprints:r,triggers:o,isLinked:s}}function xte(e,t,a,n){const r=t.at(-1).componentId,o=H(()=>e.getComponentById(r)),{push:s,isBusy:i}=wte(l);async function l(m){switch(m.eventType){case"wf-dataframe-add":await c(...m.payload);break;case"wf-dataframe-update":await u(...m.payload);break;case"wf-dataframe-action":await d(...m.payload);break}}async function c(){const m="wf-dataframe-add",g=n.value.numRows(),_=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),b=_.escape(x=>x[xn]===g),v=n.value.filter(b).object();if(!v)throw Error("Could not find record");const y=Ste(v),M=_.from([y]);if(n.value=n.value.concat(M).derive({[xn]:()=>_.op.row_number()}),!!h(m))return new Promise(x=>{const S=new CustomEvent(m,{detail:{payload:{record:y,record_index:g},callback:x}});f(S)})}async function d(m,g){const _="wf-dataframe-action";if(!n.value)throw Error("Table is not ready");if(!h(_))return;const b=g-1;return new Promise(v=>{const y=new CustomEvent(_,{detail:{payload:{action:m,record_index:b},callback:v}});f(y)})}async function u(m,g,_){if(!n.value)throw Error("Table is not ready");if(g===void 0)throw Error("Must specify the index to update a row");const b="wf-dataframe-update",v=g-1,y=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),M=y.escape(J=>J[xn]===g),x=n.value.filter(M).object();if(!x)throw Error("Could not find record");const S=x[m],L=Cte(S,_),F=y.escape(J=>J[xn]===g?L:J[m]);if(n.value=n.value.derive({[m]:F}),!h(b))return;const te=Ate(n.value.filter(M).object());return new Promise(J=>{const be=new CustomEvent(b,{detail:{payload:{record:te,record_index:v},callback:J}});f(be)})}function h(m){var v,y;const g=(v=o.value.handlers)==null?void 0:v[m],_=((y=o.value.binding)==null?void 0:y.eventType)==m,b=mg(e,r,m).isLinked.value;return!!(g||_||b)}function f(m){a.value instanceof HTMLElement?a.value.dispatchEvent(m):a.value.$el.dispatchEvent(m)}return{isBusy:i,handleUpdateCell:(...m)=>s({eventType:"wf-dataframe-update",payload:m}),handleAddRow:(...m)=>s({eventType:"wf-dataframe-add",payload:m}),handleActionRow:(...m)=>s({eventType:"wf-dataframe-action",payload:m})}}function Cte(e,t){switch(typeof e){case"number":return Number(t);case"string":return String(t);case"boolean":return!!t;case"bigint":return BigInt(String(t));default:throw Error(`Could not update a field of type ${typeof e}`)}}function vg(e){return e===xn||J3.test(e)}function Ate(e){return Object.entries(e).filter(([t])=>!vg(t)).reduce((t,[a,n])=>(t[a]=n,t),{})}function Ste(e){return Object.entries(e).filter(([t])=>!vg(t)).reduce((t,[a,n])=>(t[a]=$te(n),t),{})}function $te(e){switch(typeof e){case"number":return 0;case"string":return"";case"boolean":return!1;case"bigint":return BigInt(0);case"object":return{};default:throw Error(`Could not get default value a field of type ${typeof e}`)}}var Ht=(e=>(e.White="#ffffff",e.Black="#000000",e.Blue1="#f3f5ff",e.Blue2="#e4e9ff",e.Blue3="#bfcbff",e.Blue4="#6985ff",e.Blue5="#5551ff",e.Blue6="#4a46da",e.Gray0="#fbfbfd",e.Gray1="#f5f5f9",e.Gray2="#e4e7ed",e.Gray3="#d2d4d7",e.Gray4="#828282",e.Gray5="#4f4f4f",e.Gray6="#333333",e.Purple1="#f6effd",e.Purple2="#ede2ff",e.Purple3="#d4b2f7",e.Purple4="#a95ef8",e.Purple5="#721cc9",e.Orange1="#fff4f1",e.Orange2="#ffcfc2",e.Orange4="#ff8866",e.Orange5="#ff643c",e.Green1="#f2fffb",e.Green2="#d4fff2",e.Green3="#a9f9e1",e.Green5="#3bdcab",e.Green6="#078660",e.Yellow2="#FFE999",e))(Ht||{}),gg=(e=>(e.Box="0px 2px 0px 0px #f3f3f3",e.Menu="0px 1px 8px 0px #bfcbff40",e.Large="0px 3px 40px 0px #acb9dc66",e))(gg||{});const Ode=Object.freeze(Object.fromEntries([...Object.entries(Ht).map(([e,t])=>[`--wdsColor${e}`,t]),...Object.entries(gg).map(([e,t])=>[`--wdsShadow${e}`,t])])),Ete=$e({__name:"WdsLoaderDots",props:{color:{type:String,required:!1,default:Ht.Blue5},size:{type:Number,required:!1,default:16}},setup(e){return(t,a)=>($(),R("div",{class:"WdsLoaderDots",style:bt({color:e.color,"--dot-size":`${e.size/4}px`})},a[0]||(a[0]=[Z("span",{class:"WdsLoaderDots__dot"},null,-1),Z("span",{class:"WdsLoaderDots__dot WdsLoaderDots__dot--delay-1"},null,-1),Z("span",{class:"WdsLoaderDots__dot WdsLoaderDots__dot--delay-2"},null,-1)]),4))}}),Ad=ke(Ete,[["__scopeId","data-v-030c34ee"]]),Ite=Object.freeze(Object.defineProperty({__proto__:null,default:Ad},Symbol.toStringTag,{value:"Module"})),kte=["disabled"],Tte={key:0,class:"WdsButton__loader"},Pte=$e({__name:"WdsButton",props:{variant:{type:String,default:"primary"},size:{type:String,default:"big"},customSize:{type:String,required:!1,default:void 0},loading:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1}},setup(e){const t=e,a=H(()=>{if(t.customSize)return{width:t.customSize,height:t.customSize}}),n=H(()=>["WdsButton",`WdsButton--${t.variant}`,t.customSize?void 0:`WdsButton--${t.size}`]);return(r,o)=>($(),R("button",{class:ft(["WdsButton colorTransformer",n.value]),type:"button",style:bt(a.value),disabled:e.disabled||e.loading},[e.loading?($(),R("div",Tte,[Ce(Ad,{color:"white",size:24})])):ge("",!0),qt(r.$slots,"default",{},void 0,!0)],14,kte))}}),La=ke(Pte,[["__scopeId","data-v-000063f2"]]),Lte=["aria-busy"],Vte={key:0},Ote={class:"CoreDataframe__table__row CoreDataframe__table__row--head"},Hte={key:0,"data-writer-grid-col":"0",class:"CoreDataframe__table__th CoreDataframe__table__th--index"},Rte={class:"widthAdjuster"},Nte=["data-writer-grid-col"],Dte=["onClick"],Bte={key:0,class:"CoreDataframe__table__th__icon"},Fte={class:"widthAdjuster"},jte={key:1,class:"CoreDataframe__table__th CoreDataframe__table__th--stickyRight"},Ute={key:0,class:"CoreDataframe__newRow"},zte="A component to display Pandas DataFrames.",qte=`
8119
+ lucide.createIcons({icons});\``);if(typeof document>"u")throw new Error("`createIcons()` only works in a browser environment.");const n=document.querySelectorAll(`[${t}]`);if(Array.from(n).forEach(r=>yp(r,{nameAttr:t,icons:e,attrs:a})),t==="data-lucide"){const r=document.querySelectorAll("[icon-name]");r.length>0&&(console.warn("[Lucide] Some icons were found with the now deprecated icon-name attribute. These will still be replaced for backwards compatibility, but will no longer be supported in v1.0 and you should switch to data-lucide"),Array.from(r).forEach(o=>yp(o,{nameAttr:"icon-name",icons:e,attrs:a})))}},hte=["innerHTML"],pte=$e({inheritAttrs:!1,__name:"LucideIcon",props:{name:{type:String,required:!0}},setup(e){const t=e,a=ye("");function n(r){a.value=`<i data-lucide="${r}"></i>`,qa(()=>{ute({icons:dte,attrs:{width:"1em",height:"1em"}})})}return We(mn(t,"name"),r=>{n(r)},{immediate:!0,flush:"post"}),(r,o)=>($(),R("span",{style:{display:"contents"},innerHTML:a.value},null,8,hte))}}),bt=$e({inheritAttrs:!1,__name:"WdsIcon",props:{name:{type:String,required:!0}},setup(e){return(t,a)=>E(tI)(e.name)?($(),Ie(aI,{key:0,name:e.name},null,8,["name"])):($(),Ie(pte,{key:1,name:e.name},null,8,["name"]))}}),fte=["aria-invalid"],mte={key:1,class:"WdsTextInputLayout__rightText"},vte=$e({__name:"WdsTextInputLayout",props:{leftIcon:{type:String,required:!1,default:void 0},rightIcon:{type:String,required:!1,default:void 0},invalid:{type:Boolean,required:!1},variant:{type:String,default:void 0},rightText:{type:String,required:!1,default:""}},emits:{rightIconClick:()=>!0},setup(e){const t=e,a=H(()=>[t.leftIcon?"auto":void 0,"minmax(0, 1fr)",t.rightText?"auto":void 0,t.rightIcon?"auto":void 0].filter(Boolean).join(" "));return(n,r)=>($(),R("div",Bi({class:["WdsTextInputLayout",{"WdsTextInputLayout--ghost":e.variant==="ghost"}]},n.$attrs,{"aria-invalid":e.invalid,style:{gridTemplateColumns:a.value}}),[e.leftIcon?($(),Ie(bt,{key:0,name:e.leftIcon},null,8,["name"])):ge("",!0),qt(n.$slots,"default",{},void 0,!0),e.rightText?($(),R("p",mte,je(e.rightText),1)):ge("",!0),e.rightIcon?($(),R("button",{key:2,class:"WdsTextInputLayout__rightIcon",type:"button",onClick:r[0]||(r[0]=o=>n.$emit("rightIconClick"))},[Ce(bt,{name:e.rightIcon},null,8,["name"])])):ge("",!0)],16,fte))}}),gte=ke(vte,[["__scopeId","data-v-2e9a2df9"]]),yte=["autofocus"],Mte=$e({inheritAttrs:!1,__name:"WdsTextInput",props:jn({leftIcon:{type:String,required:!1,default:void 0},rightIcon:{type:String,required:!1,default:void 0},invalid:{type:Boolean,required:!1},variant:{type:String,default:void 0},enableClearButton:{type:Boolean,required:!1},rightText:{type:String,required:!1,default:""},autofocus:{type:Boolean}},{modelValue:{type:String},modelModifiers:{}}),emits:jn({rightIconClick:()=>!0},["update:modelValue"]),setup(e,{expose:t}){const a=lr(e,"modelValue"),n=e;t({focus:l,getSelection:i,value:a,setSelectionEnd:s,setSelectionStart:o});const r=pt("input");ia(()=>{n.autofocus&&l()});function o(c){r.value&&(r.value.selectionStart=c)}function s(c){r.value&&(r.value.selectionEnd=c)}function i(){var c,d;return{selectionStart:(c=r.value)==null?void 0:c.selectionStart,selectionEnd:(d=r.value)==null?void 0:d.selectionEnd}}function l(){var c;(c=r.value)==null||c.focus()}return(c,d)=>($(),Ie(gte,{"left-icon":e.leftIcon,"right-icon":e.rightIcon,invalid:e.invalid,variant:e.variant,"right-text":e.rightText,class:"WdsTextInput",onRightIconClick:d[1]||(d[1]=u=>c.$emit("rightIconClick")),onClick:l},{default:Xe(()=>[Ya(Z("input",Bi({ref_key:"input",ref:r,"onUpdate:modelValue":d[0]||(d[0]=u=>a.value=u),class:"WdsTextInput__input",autofocus:e.autofocus},c.$attrs),null,16,yte),[[M0,a.value]])]),_:1},8,["left-icon","right-icon","invalid","variant","right-text"]))}}),fg=ke(Mte,[["__scopeId","data-v-f987e149"]]),_te={};function bte(e,t){return $(),R("button",null,[qt(e.$slots,"default",{},void 0,!0)])}const wn=ke(_te,[["render",bte],["__scopeId","data-v-75345289"]]);function wte(e){const t=$t([]),a=ye(!1),n=fa();async function r(){if(!a.value){for(a.value=!0;t.value.length;){const[s,...i]=t.value;try{await e(s)}catch(l){n.error("Error during handling job",s,l)}finally{t.value=i}}a.value=!1}}function o(s){if(t.value=[...t.value,s],!a.value)return r()}return{push:o,isBusy:jt(a)}}function mg(e,t,a){function n(i){return i.type==="blueprints_uieventtrigger"&&i.content.refComponentId===E(t)&&i.content.refEventType===E(a)}const r=H(()=>[...new Set(o.value.map(l=>l.parentId))].map(l=>e.getComponentById(l)).filter(Boolean)),o=H(()=>e.getComponents("blueprints_root").flatMap(i=>e.getComponents(i.id).filter(n))),s=H(()=>o.value.length>0);return{blueprints:r,triggers:o,isLinked:s}}function xte(e,t,a,n){const r=t.at(-1).componentId,o=H(()=>e.getComponentById(r)),{push:s,isBusy:i}=wte(l);async function l(m){switch(m.eventType){case"wf-dataframe-add":await c(...m.payload);break;case"wf-dataframe-update":await u(...m.payload);break;case"wf-dataframe-action":await d(...m.payload);break}}async function c(){const m="wf-dataframe-add",g=n.value.numRows(),_=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),b=_.escape(x=>x[xn]===g),v=n.value.filter(b).object();if(!v)throw Error("Could not find record");const y=Ste(v),M=_.from([y]);if(n.value=n.value.concat(M).derive({[xn]:()=>_.op.row_number()}),!!h(m))return new Promise(x=>{const S=new CustomEvent(m,{detail:{payload:{record:y,record_index:g},callback:x}});f(S)})}async function d(m,g){const _="wf-dataframe-action";if(!n.value)throw Error("Table is not ready");if(!h(_))return;const b=g-1;return new Promise(v=>{const y=new CustomEvent(_,{detail:{payload:{action:m,record_index:b},callback:v}});f(y)})}async function u(m,g,_){if(!n.value)throw Error("Table is not ready");if(g===void 0)throw Error("Must specify the index to update a row");const b="wf-dataframe-update",v=g-1,y=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),M=y.escape(J=>J[xn]===g),x=n.value.filter(M).object();if(!x)throw Error("Could not find record");const S=x[m],L=Cte(S,_),F=y.escape(J=>J[xn]===g?L:J[m]);if(n.value=n.value.derive({[m]:F}),!h(b))return;const te=Ate(n.value.filter(M).object());return new Promise(J=>{const be=new CustomEvent(b,{detail:{payload:{record:te,record_index:v},callback:J}});f(be)})}function h(m){var v,y;const g=(v=o.value.handlers)==null?void 0:v[m],_=((y=o.value.binding)==null?void 0:y.eventType)==m,b=mg(e,r,m).isLinked.value;return!!(g||_||b)}function f(m){a.value instanceof HTMLElement?a.value.dispatchEvent(m):a.value.$el.dispatchEvent(m)}return{isBusy:i,handleUpdateCell:(...m)=>s({eventType:"wf-dataframe-update",payload:m}),handleAddRow:(...m)=>s({eventType:"wf-dataframe-add",payload:m}),handleActionRow:(...m)=>s({eventType:"wf-dataframe-action",payload:m})}}function Cte(e,t){switch(typeof e){case"number":return Number(t);case"string":return String(t);case"boolean":return!!t;case"bigint":return BigInt(String(t));default:throw Error(`Could not update a field of type ${typeof e}`)}}function vg(e){return e===xn||J3.test(e)}function Ate(e){return Object.entries(e).filter(([t])=>!vg(t)).reduce((t,[a,n])=>(t[a]=n,t),{})}function Ste(e){return Object.entries(e).filter(([t])=>!vg(t)).reduce((t,[a,n])=>(t[a]=$te(n),t),{})}function $te(e){switch(typeof e){case"number":return 0;case"string":return"";case"boolean":return!1;case"bigint":return BigInt(0);case"object":return{};default:throw Error(`Could not get default value a field of type ${typeof e}`)}}var Ht=(e=>(e.White="#ffffff",e.Black="#000000",e.Blue1="#f3f5ff",e.Blue2="#e4e9ff",e.Blue3="#bfcbff",e.Blue4="#6985ff",e.Blue5="#5551ff",e.Blue6="#4a46da",e.Gray0="#fbfbfd",e.Gray1="#f5f5f9",e.Gray2="#e4e7ed",e.Gray3="#d2d4d7",e.Gray4="#828282",e.Gray5="#4f4f4f",e.Gray6="#333333",e.Purple1="#f6effd",e.Purple2="#ede2ff",e.Purple3="#d4b2f7",e.Purple4="#a95ef8",e.Purple5="#721cc9",e.Orange1="#fff4f1",e.Orange2="#ffcfc2",e.Orange4="#ff8866",e.Orange5="#ff643c",e.Green1="#f2fffb",e.Green2="#d4fff2",e.Green3="#a9f9e1",e.Green5="#3bdcab",e.Green6="#078660",e.Yellow2="#FFE999",e))(Ht||{}),gg=(e=>(e.Box="0px 2px 0px 0px #f3f3f3",e.Menu="0px 1px 8px 0px #bfcbff40",e.Large="0px 3px 40px 0px #acb9dc66",e))(gg||{});const Ode=Object.freeze(Object.fromEntries([...Object.entries(Ht).map(([e,t])=>[`--wdsColor${e}`,t]),...Object.entries(gg).map(([e,t])=>[`--wdsShadow${e}`,t])])),Ete=$e({__name:"WdsLoaderDots",props:{color:{type:String,required:!1,default:Ht.Blue5},size:{type:Number,required:!1,default:16}},setup(e){return(t,a)=>($(),R("div",{class:"WdsLoaderDots",style:wt({color:e.color,"--dot-size":`${e.size/4}px`})},a[0]||(a[0]=[Z("span",{class:"WdsLoaderDots__dot"},null,-1),Z("span",{class:"WdsLoaderDots__dot WdsLoaderDots__dot--delay-1"},null,-1),Z("span",{class:"WdsLoaderDots__dot WdsLoaderDots__dot--delay-2"},null,-1)]),4))}}),Ad=ke(Ete,[["__scopeId","data-v-030c34ee"]]),Ite=Object.freeze(Object.defineProperty({__proto__:null,default:Ad},Symbol.toStringTag,{value:"Module"})),kte=["disabled"],Tte={key:0,class:"WdsButton__loader"},Pte=$e({__name:"WdsButton",props:{variant:{type:String,default:"primary"},size:{type:String,default:"big"},customSize:{type:String,required:!1,default:void 0},loading:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1}},setup(e){const t=e,a=H(()=>{if(t.customSize)return{width:t.customSize,height:t.customSize}}),n=H(()=>["WdsButton",`WdsButton--${t.variant}`,t.customSize?void 0:`WdsButton--${t.size}`]);return(r,o)=>($(),R("button",{class:ft(["WdsButton colorTransformer",n.value]),type:"button",style:wt(a.value),disabled:e.disabled||e.loading},[e.loading?($(),R("div",Tte,[Ce(Ad,{color:"white",size:24})])):ge("",!0),qt(r.$slots,"default",{},void 0,!0)],14,kte))}}),La=ke(Pte,[["__scopeId","data-v-000063f2"]]),Lte=["aria-busy"],Vte={key:0},Ote={class:"CoreDataframe__table__row CoreDataframe__table__row--head"},Hte={key:0,"data-writer-grid-col":"0",class:"CoreDataframe__table__th CoreDataframe__table__th--index"},Rte={class:"widthAdjuster"},Nte=["data-writer-grid-col"],Dte=["onClick"],Bte={key:0,class:"CoreDataframe__table__th__icon"},Fte={class:"widthAdjuster"},jte={key:1,class:"CoreDataframe__table__th CoreDataframe__table__th--stickyRight"},Ute={key:0,class:"CoreDataframe__newRow"},zte="A component to display Pandas DataFrames.",qte=`
8120
8120
  # Subscribe this event handler to the \`wf-dataframe-update\` event
8121
8121
  #
8122
8122
  # more on : https://dev.writer.com/framework/dataframe
@@ -8137,12 +8137,12 @@ def on_record_action(state, payload):
8137
8137
  if payload['action'] == 'remove':
8138
8138
  state['mydf'].record_remove(payload) # should contain an EditableDataFrame instance
8139
8139
  if payload['action'] == 'open':
8140
- state['record'] = state['mydf'].record(record_index) # dict representation of record`,Kte={writer:{name:"DataFrame",description:zte,category:"Content",events:{"wf-dataframe-add":{desc:"Capture adding a row.",stub:Wte.trim(),eventPayloadExample:{record:{col_a:"0n",col_b:"0n"},record_index:2}},"wf-dataframe-update":{desc:"Capture a cell change.",stub:qte.trim(),eventPayloadExample:{record:{col_a:"1n",col_b:"2n"},record_index:0}},"wf-dataframe-action":{desc:"Remove or open a row.",stub:Zte.trim(),eventPayloadExample:{action:"open",record_index:0}}},fields:{dataframe:{name:"Data",desc:"Must be a state reference to a Pandas dataframe or PyArrow table. Alternatively, a URL for an Arrow IPC file.",type:Q.Text,default:ox},showIndex:Ut({name:"Show index",desc:"Shows the dataframe's index. If an Arrow table is used, shows the zero-based integer index.",default:"yes"}),enableSearch:Ut({name:"Enable search",default:"no"}),enableRecordAdd:Ut({name:"Enable adding a record",default:"no"}),enableRecordUpdate:Ut({name:"Enable updating a record",default:"no"}),enableDownload:Ut({name:"Enable download",desc:"Allows the user to download the data as CSV.",default:"no"}),actions:{name:"Actions",desc:"Define rows actions",type:Q.KeyValue,default:JSON.stringify({remove:"Remove",open:"Open"}),validator:no},useMarkdown:Ut({name:"Enable markdown",desc:"If active, the output will be sanitized; unsafe elements will be removed.",default:"no"}),displayRowCount:{name:"Display row count",desc:"Specifies how many rows to show simultaneously.",type:Q.Number,category:ot.Style,default:"10",validator:fn},wrapText:Ut({name:"Wrap text",category:ot.Style,desc:"Not wrapping text allows for an uniform grid, but may be inconvenient if your data contains longer text fields.",default:"no"}),primaryTextColor:ua,secondaryTextColor:In,accentColor:Ia,separatorColor:wa,dataframeBackgroundColor:{name:"Background",type:Q.Color,category:ot.Style,default:Ht.White,applyStyleVariable:!0},fontStyle:{name:"Font style",type:Q.Text,category:ot.Style,options:{normal:"normal",monospace:"monospace"},default:"normal"},cssClasses:mt}}},Gte=$e({...Kte,__name:"CoreDataframe",setup(e){const o=re(ne.evaluatedFields),s=pt("rootEl"),i=pt("toolsEl"),l=pt("gridContainerEl");let c=null;const d=$t(null),u=$t([]),h=H(()=>o.showIndex.value=="yes"),f=H(()=>o.actions.value),m=$t(null),g=ye(0),_=ye([]);let b=null;const v=re(ne.core),y=re(ne.instancePath),{handleUpdateCell:M,handleAddRow:x,handleActionRow:S,isBusy:L}=xte(v,y,s,d);async function F(){await x(),l.value.scrollTo({behavior:"smooth",top:48*Ue.value})}const te=H(()=>q.value||L.value),J=H(()=>{var ce;return d.value?(ce=d.value)==null?void 0:ce.columnNames():[]}),be=H(()=>J.value.filter(ce=>u.value.includes(ce))),oe=H(()=>J.value.filter(ue=>{if(ue===xn)return!1;const I=u.value.includes(ue),B=J3.test(ue);return!(I&&B)})),Te=H(()=>(h.value?1:0)+oe.value.length),Ue=H(()=>{var ce;return((ce=d.value)==null?void 0:ce.numRows())??0}),Ze=H(()=>Ue.value>1e3),Me=H(()=>Math.min(o.displayRowCount.value,Ue.value)),ee=H(()=>Object.keys(o.actions.value||{}).length>0),j=H(()=>!!o.useMarkdown.value),K=H(()=>!!o.enableRecordUpdate.value),G=H(()=>!!o.enableRecordAdd.value),T=H(()=>!!o.wrapText.value),O=H(()=>{let ce;return T.value?ce=Ue.value-1:ce=Ue.value-Me.value,Math.min(Math.ceil(g.value*ce),ce)}),k=H(()=>{if(!d.value)return null;const ce=Ze.value?O.value:0,ue=Ze.value?Me.value:1e3,I=d.value.objects({offset:ce,limit:ue}),B=d.value.indices().slice(ce,O.value+Me.value);return{data:I,indices:B}}),C=H(()=>{let ce="16px ";return _.value.length==0?(h.value&&(ce+="75px "),ce+=`repeat(${oe.value.length}, minmax(min-content, 1fr)) `):ce+=_.value.map(ue=>`${Math.max(ue,80)}px `).join(" "),ee.value&&(ce+="40px "),ce}),P=H(()=>{const ce=o.fontStyle.value,ue=`${(1+o.displayRowCount.value)*48}px`;return{position:Ze.value?"sticky":"unset","min-height":"48px","max-height":ue,"font-family":ce=="monospace"?"monospace":void 0,"grid-template-rows":`48px repeat(${Me.value}, min-content)`,"grid-template-columns":C.value}}),ae=H(()=>({top:`${48*Ue.value}px`})),xe=ye(!1);function ve(){if(!(l.value.scrollWidth>l.value.clientWidth)){xe.value=!1;return}const ue=l.value.scrollLeft+l.value.clientWidth>=l.value.scrollWidth;xe.value=!ue}We(_,ve);function ze(){const ce=l.value.scrollTop;g.value=ce/(l.value.scrollHeight-l.value.clientHeight),ve()}function Ye(){l.value.scrollTop=0}async function ct(){var I;_.value=[],await qa();const ce=(I=l.value)==null?void 0:I.querySelectorAll("[data-writer-grid-col]"),ue=[];ce==null||ce.forEach(B=>{const N=B,U=N.dataset.writerGridCol,{width:se}=N.getBoundingClientRect(),Se=Math.min(se,300);ue[U]=Se}),_.value=ue}function wt(ce,ue){var U,se;if(ce.target.classList.contains("widthAdjuster"))return;if(((U=m.value)==null?void 0:U.columnName)!==ue){m.value={columnName:ue,descending:!1};return}if((se=m.value)==null?void 0:se.descending){m.value=null;return}m.value={columnName:ue,descending:!m.value.descending}}function D(ce){const ue=ce.schema.metadata.get("pandas");return ue?JSON.parse(ue).index_columns:[]}const q=ye(!1);async function he(){q.value=!0;const ce=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),{tableFromIPC:ue}=await zt(()=>import("./Arrow.dom-GBJpMYQS.js"),__vite__mapDeps([2,1]),import.meta.url);try{const I=W3(o.dataframe.value),B=Hw(I),N=ue(B);u.value=D(N),c=ce.fromArrow(N),d.value=c.derive({[xn]:()=>ce.op.row_number()})}catch(I){fa().error("Couldn't load dataframe from Arrow URL.",I)}finally{q.value=!1}}async function me(){const ce=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),ue=d.value.select(ce.not(xn)).toCSV(),I=document.createElement("a"),B=new Blob([ue],{type:"text/csv"}),N=URL.createObjectURL(B);I.href=N,I.download="data.csv",I.click(),URL.revokeObjectURL(N)}async function _e(){const ce=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url);if(m.value===null){d.value=d.value.unorder();return}let ue;m.value.descending?ue=ce.desc(m.value.columnName):ue=m.value.columnName,d.value=d.value.orderby(ue)}async function Ae(ce){const ue=ce.target.value;if(!ue)d.value=c;else{const I=new RegExp(ue,"i"),N="(d, $) => "+c.columnNames().map(se=>`aq.op.match(d.${se}, $.pattern) !== null`).join(" || "),U=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url);d.value=c.params({pattern:I,filterS:N}).filter(N).derive({[xn]:()=>U.op.row_number()})}await qa(),Ye()}async function pe(ce){if(ce.buttons!==1){b=null;return}const ue=ce.target;if(!s.value.contains(ue))return;if(b===null&&ue.classList.contains("widthAdjuster")){const se=ue.closest(".CoreDataframe__table__th");b=parseInt(se.dataset.writerGridCol)}else if(b===null)return;const I=l.value.querySelector(`[data-writer-grid-col="${b}"]`),{left:B}=I.getBoundingClientRect(),U=ce.clientX-B;_.value[b]=U}return We(o.dataframe,()=>{he()}),We(m,async()=>{await _e()}),We(Te,()=>{ct()}),We(T,()=>{ct()}),ia(async()=>{await he(),document.addEventListener("mousemove",pe),i.value&&new ResizeObserver(ct).observe(i.value,{box:"border-box"})}),Wn(()=>{document.removeEventListener("mousemove",pe)}),(ce,ue)=>{var I;return $(),R("div",{ref_key:"rootEl",ref:s,class:"CoreDataframe","aria-busy":te.value},[Z("div",{ref_key:"toolsEl",ref:i,class:"tools"},[E(o).enableSearch.value==="yes"?($(),R("div",Vte,[Ce(fg,{class:"search",placeholder:"Search","left-icon":"search",onChange:Ae})])):ge("",!0),E(o).enableDownload.value?($(),Ie(wn,{key:1,title:"Download",class:"download",onClick:me},{default:Xe(()=>[Ce(_t,{name:"download"})]),_:1})):ge("",!0)],512),Z("div",{ref_key:"gridContainerEl",ref:l,class:"CoreDataframe__tableWrapper",onScroll:ze},[Z("div",{class:ft(["CoreDataframe__table",{scrolled:O.value>0,wrapText:T.value}]),style:bt(P.value)},[Z("div",Ote,[ue[0]||(ue[0]=Z("div",{class:"CoreDataframe__table__th CoreDataframeRow__spacer"},null,-1)),h.value?($(),R("div",Hte,[Z("div",Rte,[Ce(_t,{name:"grip-vertical"})])])):ge("",!0),($(!0),R(Je,null,Ot(oe.value,(B,N)=>{var U,se;return $(),R("div",{key:B,"data-writer-grid-col":N+(h.value?1:0),class:"CoreDataframe__table__th"},[Z("button",{type:"button",class:"CoreDataframe__table__th__name",onClick:Se=>wt(Se,B)},je(B),9,Dte),((U=m.value)==null?void 0:U.columnName)==B?($(),R("div",Bte,[Ce(_t,{name:(se=m.value)!=null&&se.descending?"arrow-up":"arrow-down"},null,8,["name"])])):ge("",!0),Z("div",Fte,[Ce(_t,{name:"grip-vertical"})])],8,Nte)}),128)),ee.value?($(),R("div",jte)):ge("",!0)]),($(!0),R(Je,null,Ot((I=k.value)==null?void 0:I.data,(B,N)=>($(),Ie(Jx,{key:N,class:"CoreDataframe__table__row",row:B,actions:f.value,"use-markdown":j.value,editable:K.value&&!te.value,columns:oe.value,"show-index":h.value,"index-text":k.value.indices[N]??be.value.map(U=>B[U]).join(", "),"display-shadow-on-sticky":xe.value,"wrap-text":T.value,onAction:E(S),onChange:E(M)},null,8,["row","actions","use-markdown","editable","columns","show-index","index-text","display-shadow-on-sticky","wrap-text","onAction","onChange"]))),128))],6),Ze.value?($(),R("div",{key:0,class:"endpoint",style:bt(ae.value)},null,4)):ge("",!0)],544),G.value?($(),R("div",Ute,[Ce(La,{"aria-label":"Create a new row at the end",size:"small",variant:"tertiary",onClick:F},{default:Xe(()=>[Ce(_t,{name:"plus"}),ue[1]||(ue[1]=pa(" Add a row "))]),_:1})])):ge("",!0)],8,Lte)}}}),Jte=ke(Gte,[["__scopeId","data-v-4c4e67d3"]]),Xte={key:0},Yte={key:1},Qte={key:2},eae={key:3},tae="A text component used to display headings or titles in different sizes and styles.",aae={writer:{name:"Heading",description:tae,category:"Content",fields:{text:{name:"Text",default:"(No text)",init:"Heading Text",desc:"Add text directly, or reference state elements with @{my_text}.",type:Q.Text},headingType:{name:"Heading type",default:"h3",options:{h1:"h1 (Big)",h2:"h2 (Normal)",h3:"h3 (Small)",h4:"h4 (Smallest)"},type:Q.Text,category:ot.Style},alignment:{name:"Alignment",default:"left",type:Q.Text,category:ot.Style,options:{left:"Left",center:"Center",right:"Right"}},primaryTextColor:ua,cssClasses:mt},previewField:"text"}},nae=$e({...aae,__name:"CoreHeading",setup(e){const t=re(ne.evaluatedFields);return(a,n)=>($(),R("div",{class:"CoreHeading",style:bt({"text-align":E(t).alignment.value})},[E(t).headingType.value=="h1"?($(),R("h1",Xte,je(E(t).text.value),1)):E(t).headingType.value=="h3"?($(),R("h3",Yte,je(E(t).text.value),1)):E(t).headingType.value=="h4"?($(),R("h4",Qte,je(E(t).text.value),1)):($(),R("h2",eae,je(E(t).text.value),1))],4))}}),rae=ke(nae,[["__scopeId","data-v-a24181bd"]]);function Zi(e){const t={ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,metaKey:e.metaKey};return new CustomEvent("wf-click",{detail:{payload:t}})}function oae(e){const t={key:e.key,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,metaKey:e.metaKey};return new CustomEvent("wf-keydown",{detail:{payload:t}})}const sae=["src","alt"],iae={key:0,class:"captionContainer"},lae="A component to display images.",cae=`
8140
+ state['record'] = state['mydf'].record(record_index) # dict representation of record`,Kte={writer:{name:"DataFrame",description:zte,category:"Content",events:{"wf-dataframe-add":{desc:"Capture adding a row.",stub:Wte.trim(),eventPayloadExample:{record:{col_a:"0n",col_b:"0n"},record_index:2}},"wf-dataframe-update":{desc:"Capture a cell change.",stub:qte.trim(),eventPayloadExample:{record:{col_a:"1n",col_b:"2n"},record_index:0}},"wf-dataframe-action":{desc:"Remove or open a row.",stub:Zte.trim(),eventPayloadExample:{action:"open",record_index:0}}},fields:{dataframe:{name:"Data",desc:"Must be a state reference to a Pandas dataframe or PyArrow table. Alternatively, a URL for an Arrow IPC file.",type:Q.Text,default:ox},showIndex:Ut({name:"Show index",desc:"Shows the dataframe's index. If an Arrow table is used, shows the zero-based integer index.",default:"yes"}),enableSearch:Ut({name:"Enable search",default:"no"}),enableRecordAdd:Ut({name:"Enable adding a record",default:"no"}),enableRecordUpdate:Ut({name:"Enable updating a record",default:"no"}),enableDownload:Ut({name:"Enable download",desc:"Allows the user to download the data as CSV.",default:"no"}),actions:{name:"Actions",desc:"Define rows actions",type:Q.KeyValue,default:JSON.stringify({remove:"Remove",open:"Open"}),validator:ro},useMarkdown:Ut({name:"Enable markdown",desc:"If active, the output will be sanitized; unsafe elements will be removed.",default:"no"}),displayRowCount:{name:"Display row count",desc:"Specifies how many rows to show simultaneously.",type:Q.Number,category:ot.Style,default:"10",validator:fn},wrapText:Ut({name:"Wrap text",category:ot.Style,desc:"Not wrapping text allows for an uniform grid, but may be inconvenient if your data contains longer text fields.",default:"no"}),primaryTextColor:ua,secondaryTextColor:In,accentColor:Ia,separatorColor:wa,dataframeBackgroundColor:{name:"Background",type:Q.Color,category:ot.Style,default:Ht.White,applyStyleVariable:!0},fontStyle:{name:"Font style",type:Q.Text,category:ot.Style,options:{normal:"normal",monospace:"monospace"},default:"normal"},cssClasses:mt}}},Gte=$e({...Kte,__name:"CoreDataframe",setup(e){const o=re(ne.evaluatedFields),s=pt("rootEl"),i=pt("toolsEl"),l=pt("gridContainerEl");let c=null;const d=$t(null),u=$t([]),h=H(()=>o.showIndex.value=="yes"),f=H(()=>o.actions.value),m=$t(null),g=ye(0),_=ye([]);let b=null;const v=re(ne.core),y=re(ne.instancePath),{handleUpdateCell:M,handleAddRow:x,handleActionRow:S,isBusy:L}=xte(v,y,s,d);async function F(){await x(),l.value.scrollTo({behavior:"smooth",top:48*Ue.value})}const te=H(()=>q.value||L.value),J=H(()=>{var ce;return d.value?(ce=d.value)==null?void 0:ce.columnNames():[]}),be=H(()=>J.value.filter(ce=>u.value.includes(ce))),oe=H(()=>J.value.filter(ue=>{if(ue===xn)return!1;const I=u.value.includes(ue),B=J3.test(ue);return!(I&&B)})),Te=H(()=>(h.value?1:0)+oe.value.length),Ue=H(()=>{var ce;return((ce=d.value)==null?void 0:ce.numRows())??0}),Ze=H(()=>Ue.value>1e3),Me=H(()=>Math.min(o.displayRowCount.value,Ue.value)),ee=H(()=>Object.keys(o.actions.value||{}).length>0),j=H(()=>!!o.useMarkdown.value),K=H(()=>!!o.enableRecordUpdate.value),G=H(()=>!!o.enableRecordAdd.value),T=H(()=>!!o.wrapText.value),O=H(()=>{let ce;return T.value?ce=Ue.value-1:ce=Ue.value-Me.value,Math.min(Math.ceil(g.value*ce),ce)}),k=H(()=>{if(!d.value)return null;const ce=Ze.value?O.value:0,ue=Ze.value?Me.value:1e3,I=d.value.objects({offset:ce,limit:ue}),B=d.value.indices().slice(ce,O.value+Me.value);return{data:I,indices:B}}),C=H(()=>{let ce="16px ";return _.value.length==0?(h.value&&(ce+="75px "),ce+=`repeat(${oe.value.length}, minmax(min-content, 1fr)) `):ce+=_.value.map(ue=>`${Math.max(ue,80)}px `).join(" "),ee.value&&(ce+="40px "),ce}),P=H(()=>{const ce=o.fontStyle.value,ue=`${(1+o.displayRowCount.value)*48}px`;return{position:Ze.value?"sticky":"unset","min-height":"48px","max-height":ue,"font-family":ce=="monospace"?"monospace":void 0,"grid-template-rows":`48px repeat(${Me.value}, min-content)`,"grid-template-columns":C.value}}),ae=H(()=>({top:`${48*Ue.value}px`})),xe=ye(!1);function ve(){if(!(l.value.scrollWidth>l.value.clientWidth)){xe.value=!1;return}const ue=l.value.scrollLeft+l.value.clientWidth>=l.value.scrollWidth;xe.value=!ue}We(_,ve);function ze(){const ce=l.value.scrollTop;g.value=ce/(l.value.scrollHeight-l.value.clientHeight),ve()}function Ye(){l.value.scrollTop=0}async function ct(){var I;_.value=[],await qa();const ce=(I=l.value)==null?void 0:I.querySelectorAll("[data-writer-grid-col]"),ue=[];ce==null||ce.forEach(B=>{const N=B,U=N.dataset.writerGridCol,{width:se}=N.getBoundingClientRect(),Se=Math.min(se,300);ue[U]=Se}),_.value=ue}function xt(ce,ue){var U,se;if(ce.target.classList.contains("widthAdjuster"))return;if(((U=m.value)==null?void 0:U.columnName)!==ue){m.value={columnName:ue,descending:!1};return}if((se=m.value)==null?void 0:se.descending){m.value=null;return}m.value={columnName:ue,descending:!m.value.descending}}function D(ce){const ue=ce.schema.metadata.get("pandas");return ue?JSON.parse(ue).index_columns:[]}const q=ye(!1);async function he(){q.value=!0;const ce=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),{tableFromIPC:ue}=await zt(()=>import("./Arrow.dom-GBJpMYQS.js"),__vite__mapDeps([2,1]),import.meta.url);try{const I=W3(o.dataframe.value),B=Hw(I),N=ue(B);u.value=D(N),c=ce.fromArrow(N),d.value=c.derive({[xn]:()=>ce.op.row_number()})}catch(I){fa().error("Couldn't load dataframe from Arrow URL.",I)}finally{q.value=!1}}async function me(){const ce=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url),ue=d.value.select(ce.not(xn)).toCSV(),I=document.createElement("a"),B=new Blob([ue],{type:"text/csv"}),N=URL.createObjectURL(B);I.href=N,I.download="data.csv",I.click(),URL.revokeObjectURL(N)}async function _e(){const ce=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url);if(m.value===null){d.value=d.value.unorder();return}let ue;m.value.descending?ue=ce.desc(m.value.columnName):ue=m.value.columnName,d.value=d.value.orderby(ue)}async function Ae(ce){const ue=ce.target.value;if(!ue)d.value=c;else{const I=new RegExp(ue,"i"),N="(d, $) => "+c.columnNames().map(se=>`aq.op.match(d.${se}, $.pattern) !== null`).join(" || "),U=await zt(()=>import("./index-5u5REPT4.js"),__vite__mapDeps([0,1]),import.meta.url);d.value=c.params({pattern:I,filterS:N}).filter(N).derive({[xn]:()=>U.op.row_number()})}await qa(),Ye()}async function pe(ce){if(ce.buttons!==1){b=null;return}const ue=ce.target;if(!s.value.contains(ue))return;if(b===null&&ue.classList.contains("widthAdjuster")){const se=ue.closest(".CoreDataframe__table__th");b=parseInt(se.dataset.writerGridCol)}else if(b===null)return;const I=l.value.querySelector(`[data-writer-grid-col="${b}"]`),{left:B}=I.getBoundingClientRect(),U=ce.clientX-B;_.value[b]=U}return We(o.dataframe,()=>{he()}),We(m,async()=>{await _e()}),We(Te,()=>{ct()}),We(T,()=>{ct()}),ia(async()=>{await he(),document.addEventListener("mousemove",pe),i.value&&new ResizeObserver(ct).observe(i.value,{box:"border-box"})}),Zn(()=>{document.removeEventListener("mousemove",pe)}),(ce,ue)=>{var I;return $(),R("div",{ref_key:"rootEl",ref:s,class:"CoreDataframe","aria-busy":te.value},[Z("div",{ref_key:"toolsEl",ref:i,class:"tools"},[E(o).enableSearch.value==="yes"?($(),R("div",Vte,[Ce(fg,{class:"search",placeholder:"Search","left-icon":"search",onChange:Ae})])):ge("",!0),E(o).enableDownload.value?($(),Ie(wn,{key:1,title:"Download",class:"download",onClick:me},{default:Xe(()=>[Ce(bt,{name:"download"})]),_:1})):ge("",!0)],512),Z("div",{ref_key:"gridContainerEl",ref:l,class:"CoreDataframe__tableWrapper",onScroll:ze},[Z("div",{class:ft(["CoreDataframe__table",{scrolled:O.value>0,wrapText:T.value}]),style:wt(P.value)},[Z("div",Ote,[ue[0]||(ue[0]=Z("div",{class:"CoreDataframe__table__th CoreDataframeRow__spacer"},null,-1)),h.value?($(),R("div",Hte,[Z("div",Rte,[Ce(bt,{name:"grip-vertical"})])])):ge("",!0),($(!0),R(Je,null,Ot(oe.value,(B,N)=>{var U,se;return $(),R("div",{key:B,"data-writer-grid-col":N+(h.value?1:0),class:"CoreDataframe__table__th"},[Z("button",{type:"button",class:"CoreDataframe__table__th__name",onClick:Se=>xt(Se,B)},je(B),9,Dte),((U=m.value)==null?void 0:U.columnName)==B?($(),R("div",Bte,[Ce(bt,{name:(se=m.value)!=null&&se.descending?"arrow-up":"arrow-down"},null,8,["name"])])):ge("",!0),Z("div",Fte,[Ce(bt,{name:"grip-vertical"})])],8,Nte)}),128)),ee.value?($(),R("div",jte)):ge("",!0)]),($(!0),R(Je,null,Ot((I=k.value)==null?void 0:I.data,(B,N)=>($(),Ie(Jx,{key:N,class:"CoreDataframe__table__row",row:B,actions:f.value,"use-markdown":j.value,editable:K.value&&!te.value,columns:oe.value,"show-index":h.value,"index-text":k.value.indices[N]??be.value.map(U=>B[U]).join(", "),"display-shadow-on-sticky":xe.value,"wrap-text":T.value,onAction:E(S),onChange:E(M)},null,8,["row","actions","use-markdown","editable","columns","show-index","index-text","display-shadow-on-sticky","wrap-text","onAction","onChange"]))),128))],6),Ze.value?($(),R("div",{key:0,class:"endpoint",style:wt(ae.value)},null,4)):ge("",!0)],544),G.value?($(),R("div",Ute,[Ce(La,{"aria-label":"Create a new row at the end",size:"small",variant:"tertiary",onClick:F},{default:Xe(()=>[Ce(bt,{name:"plus"}),ue[1]||(ue[1]=pa(" Add a row "))]),_:1})])):ge("",!0)],8,Lte)}}}),Jte=ke(Gte,[["__scopeId","data-v-4c4e67d3"]]),Xte={key:0},Yte={key:1},Qte={key:2},eae={key:3},tae="A text component used to display headings or titles in different sizes and styles.",aae={writer:{name:"Heading",description:tae,category:"Content",fields:{text:{name:"Text",default:"(No text)",init:"Heading Text",desc:"Add text directly, or reference state elements with @{my_text}.",type:Q.Text},headingType:{name:"Heading type",default:"h3",options:{h1:"h1 (Big)",h2:"h2 (Normal)",h3:"h3 (Small)",h4:"h4 (Smallest)"},type:Q.Text,category:ot.Style},alignment:{name:"Alignment",default:"left",type:Q.Text,category:ot.Style,options:{left:"Left",center:"Center",right:"Right"}},primaryTextColor:ua,cssClasses:mt},previewField:"text"}},nae=$e({...aae,__name:"CoreHeading",setup(e){const t=re(ne.evaluatedFields);return(a,n)=>($(),R("div",{class:"CoreHeading",style:wt({"text-align":E(t).alignment.value})},[E(t).headingType.value=="h1"?($(),R("h1",Xte,je(E(t).text.value),1)):E(t).headingType.value=="h3"?($(),R("h3",Yte,je(E(t).text.value),1)):E(t).headingType.value=="h4"?($(),R("h4",Qte,je(E(t).text.value),1)):($(),R("h2",eae,je(E(t).text.value),1))],4))}}),rae=ke(nae,[["__scopeId","data-v-a24181bd"]]);function Zi(e){const t={ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,metaKey:e.metaKey};return new CustomEvent("wf-click",{detail:{payload:t}})}function oae(e){const t={key:e.key,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,metaKey:e.metaKey};return new CustomEvent("wf-keydown",{detail:{payload:t}})}const sae=["src","alt"],iae={key:0,class:"captionContainer"},lae="A component to display images.",cae=`
8141
8141
  def click_handler(state):
8142
8142
 
8143
8143
  # Increment counter when the image is clicked
8144
8144
 
8145
- state["counter"] += 1`,dae={writer:{name:"Image",description:lae,category:"Content",fields:{src:{name:"Source",default:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQoAAAEKCAYAAADqyxvJAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAemSURBVHgB7d3baltHGIZhJd5DW3pS2vu/tkKgEFragiXLjuvVkpOS5PMa6Z8ZWc8DPXPBJNGrpX82evfrh4/PG4BveL8BCIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiC43HN3PP/24ubyoafCnT8+bD7/9vur/+f67u80PL/9V+fjHX5vtdv/qn794+bP55eXPaJbfh8wTRYGHh7p/pO/fv/v3hbZG5e+zuLm+WvXzT0+fNo8v/1XZ7582HJdQFKj+h3p7c73q5/ePTy9PInUvzOuVoVhUxWsJ0FNhhM6VUBS43z1sKl1fXaz6+eXjyv6xMBSXF5t3L086a+weHjcVqp+ezpVQFFje0Srfwdc+USz2jzUvzM+WWKyxK3pB74SihFAU2e7mmlNst7VPObe36+JVFdOqJ5VzJxRFqucUaweIy5yi0tXl+gW0Y8fUfKKOUBTZla80rHth/jenqIvFVcOc4tgx3e89TVQRiiLVKw03DSsNu+Jl29Fzim3xEPmcCUWhh8LPy8uMYu07+EPx5/frho9Dx4yp/RN1hKJQ9WDtbuXqx26yjVeLY8Wr+qPVuROKQtVLklcN+ykqd0RerfzosThWTC2L1hKKQsuLoHJOcdewn6Lyc/wyp1g7ZD3WC9yyaC2hKFa5I7JlTlH9Of5y5TLpseYUdmTWEopi1Rud1r6DV68MrP19FofG1HyinlAUq55TrB0gVs8pWgaah8ZUJOoJRbFzOrm5WOYUa4eah8b0fmv/RDWhKHZOJzc/672f4vHRILOaUHRwLic3P2vbXt4eCise9YSigxlPbs42p2iNl0j0IRQdzHhy861c12ejVR9C0cHyaF35zrc86s+2n6Llur4W9k/0IRSdzDanmPG6vpaY+ujRh1B0MtvJzerr+lrmFGtjKhL9CEUnb/nk5pcsM4r1c4p1v8/esmg3QtFJjxum1qp+R14br7Ux3dpo1Y1QdFR9w9Sok5tfU31d34Ot290IRUdv9eTm11Tup1gi8fwSFvoQio6qT27e3bZ838dcx+BfO6ewLNqXUHQ04w1T1Z/zq67rs9GqL6Ho7K2d3EyqruuzNNqXUHQ228nN6uv6Wo7Bp49o5hP9CUVns600LGY7Bp+Gvo++6Kc7oejsLZ3cfK1jL9ve+6Kf7oRigLdycvO1bhq2l38rpr7opz+hGGDGk5uVc4pjHoP3RcRjCMUAM57crJxTtByD/9rQ1/6JMYRigOqTm7c3LRuvTuO6PvsnxhCKQba7ueYUM17X96WY2j8xhlAMUj2nuGm4CbtSy5zi/zE1nxhHKAY59ZOba10dYT/F3v6JYYRikFM+udli+Th06Jxia//EMEIxUPUNU1UnN1sd+sVA9k+MIxQDVQ/mqk5utjrkuj5fRDyWUAx0qic3Wx1yXZ9l0bGEYqDqk5t3DfspKucAh1zXZ1l0LKEYbLYbpma9rs+OzLGEYrDZlkmrVxZajsEvcwrzibGEYrDZTm5WzylaBpp//n2/YSyhGKx6P8V100rDbNf1eZoYTSgGqz652XLD1GzX9TGeUEzgVE5uHsvaY/CMJxQTmPHkZuWcouUYPGMJxQRmPLk523V9jOVvawLLnKJyLtByw9Rs1/UxllBMYrY5xWzX9TGWUExitpOb1df13Vj5OClCMYmZT25WWGYU5hSnw9/UJHrcMLVW9X4KTxWnQygmUn3D1LG/setQLec+GEMoJjLryc0qnihOh1BMpPrk5t1ty/d9zHUMnjGEYiIz3jBVvWv0zn6KkyAUk5nv5OZc1/UxhlBMZraTm9XX9TlJehqEYjIzrjTMdgye/oRiMtUnN2f7YqCFZdL5CcWEZju5Odt1ffT37tcPH583AN/giQKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKI/gE7SXVdY25ypwAAAABJRU5ErkJggg==",desc:"A valid URL. Alternatively, you can provide a state reference to a Matplotlib figure or a packed file.",type:Q.Text},caption:{name:"Caption",init:"Image Caption",desc:"Leave blank to hide.",type:Q.Text},maxWidth:{name:"Max width (px)",type:Q.Number,default:"-1",category:ot.Style},maxHeight:{name:"Max height (px)",type:Q.Number,default:"-1",category:ot.Style},secondaryTextColor:In,cssClasses:mt},events:{"wf-click":{desc:"Capture single clicks.",stub:cae.trim()}},previewField:"caption"}},yg=$e({...dae,__name:"CoreImage",setup(e){const t=pt("rootEl"),a=re(ne.core),n=re(ne.evaluatedFields),r=re(ne.componentId),o=H(()=>{var d;return{cursor:typeof((d=a.getComponentById(r).handlers)==null?void 0:d["wf-click"])<"u"?"pointer":"unset"}}),s=H(()=>{const l=n.maxWidth.value,c=n.maxHeight.value;return{maxWidth:l!==-1?`${l}px`:void 0,maxHeight:c!==-1?`${c}px`:void 0}});function i(l){const c=Zi(l);t.value.dispatchEvent(c)}return(l,c)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreImage",style:bt(o.value),onClick:i},[Z("img",{src:E(n).src.value,alt:E(n).caption.value,draggable:"false",style:bt(s.value)},null,12,sae),E(n).caption.value||E(n).caption.value===0?($(),R("div",iae,je(E(n).caption.value),1)):ge("",!0)],4))}}),rm=e=>{e.writer&&(e.writer.docs=`Use your app's static folder to serve images directly. For example, \`static/my_image.png\`.
8145
+ state["counter"] += 1`,dae={writer:{name:"Image",description:lae,category:"Content",fields:{src:{name:"Source",default:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQoAAAEKCAYAAADqyxvJAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAemSURBVHgB7d3baltHGIZhJd5DW3pS2vu/tkKgEFragiXLjuvVkpOS5PMa6Z8ZWc8DPXPBJNGrpX82evfrh4/PG4BveL8BCIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiIQCiC43HN3PP/24ubyoafCnT8+bD7/9vur/+f67u80PL/9V+fjHX5vtdv/qn794+bP55eXPaJbfh8wTRYGHh7p/pO/fv/v3hbZG5e+zuLm+WvXzT0+fNo8v/1XZ7582HJdQFKj+h3p7c73q5/ePTy9PInUvzOuVoVhUxWsJ0FNhhM6VUBS43z1sKl1fXaz6+eXjyv6xMBSXF5t3L086a+weHjcVqp+ezpVQFFje0Srfwdc+USz2jzUvzM+WWKyxK3pB74SihFAU2e7mmlNst7VPObe36+JVFdOqJ5VzJxRFqucUaweIy5yi0tXl+gW0Y8fUfKKOUBTZla80rHth/jenqIvFVcOc4tgx3e89TVQRiiLVKw03DSsNu+Jl29Fzim3xEPmcCUWhh8LPy8uMYu07+EPx5/frho9Dx4yp/RN1hKJQ9WDtbuXqx26yjVeLY8Wr+qPVuROKQtVLklcN+ykqd0RerfzosThWTC2L1hKKQsuLoHJOcdewn6Lyc/wyp1g7ZD3WC9yyaC2hKFa5I7JlTlH9Of5y5TLpseYUdmTWEopi1Rud1r6DV68MrP19FofG1HyinlAUq55TrB0gVs8pWgaah8ZUJOoJRbFzOrm5WOYUa4eah8b0fmv/RDWhKHZOJzc/672f4vHRILOaUHRwLic3P2vbXt4eCise9YSigxlPbs42p2iNl0j0IRQdzHhy861c12ejVR9C0cHyaF35zrc86s+2n6Llur4W9k/0IRSdzDanmPG6vpaY+ujRh1B0MtvJzerr+lrmFGtjKhL9CEUnb/nk5pcsM4r1c4p1v8/esmg3QtFJjxum1qp+R14br7Ux3dpo1Y1QdFR9w9Sok5tfU31d34Ot290IRUdv9eTm11Tup1gi8fwSFvoQio6qT27e3bZ838dcx+BfO6ewLNqXUHQ04w1T1Z/zq67rs9GqL6Ho7K2d3EyqruuzNNqXUHQ228nN6uv6Wo7Bp49o5hP9CUVns600LGY7Bp+Gvo++6Kc7oejsLZ3cfK1jL9ve+6Kf7oRigLdycvO1bhq2l38rpr7opz+hGGDGk5uVc4pjHoP3RcRjCMUAM57crJxTtByD/9rQ1/6JMYRigOqTm7c3LRuvTuO6PvsnxhCKQba7ueYUM17X96WY2j8xhlAMUj2nuGm4CbtSy5zi/zE1nxhHKAY59ZOba10dYT/F3v6JYYRikFM+udli+Th06Jxia//EMEIxUPUNU1UnN1sd+sVA9k+MIxQDVQ/mqk5utjrkuj5fRDyWUAx0qic3Wx1yXZ9l0bGEYqDqk5t3DfspKucAh1zXZ1l0LKEYbLYbpma9rs+OzLGEYrDZlkmrVxZajsEvcwrzibGEYrDZTm5WzylaBpp//n2/YSyhGKx6P8V100rDbNf1eZoYTSgGqz652XLD1GzX9TGeUEzgVE5uHsvaY/CMJxQTmPHkZuWcouUYPGMJxQRmPLk523V9jOVvawLLnKJyLtByw9Rs1/UxllBMYrY5xWzX9TGWUExitpOb1df13Vj5OClCMYmZT25WWGYU5hSnw9/UJHrcMLVW9X4KTxWnQygmUn3D1LG/setQLec+GEMoJjLryc0qnihOh1BMpPrk5t1ty/d9zHUMnjGEYiIz3jBVvWv0zn6KkyAUk5nv5OZc1/UxhlBMZraTm9XX9TlJehqEYjIzrjTMdgye/oRiMtUnN2f7YqCFZdL5CcWEZju5Odt1ffT37tcPH583AN/giQKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKIhAKI/gE7SXVdY25ypwAAAABJRU5ErkJggg==",desc:"A valid URL. Alternatively, you can provide a state reference to a Matplotlib figure or a packed file.",type:Q.Text},caption:{name:"Caption",init:"Image Caption",desc:"Leave blank to hide.",type:Q.Text},maxWidth:{name:"Max width (px)",type:Q.Number,default:"-1",category:ot.Style},maxHeight:{name:"Max height (px)",type:Q.Number,default:"-1",category:ot.Style},secondaryTextColor:In,cssClasses:mt},events:{"wf-click":{desc:"Capture single clicks.",stub:cae.trim()}},previewField:"caption"}},yg=$e({...dae,__name:"CoreImage",setup(e){const t=pt("rootEl"),a=re(ne.core),n=re(ne.evaluatedFields),r=re(ne.componentId),o=H(()=>{var d;return{cursor:typeof((d=a.getComponentById(r).handlers)==null?void 0:d["wf-click"])<"u"?"pointer":"unset"}}),s=H(()=>{const l=n.maxWidth.value,c=n.maxHeight.value;return{maxWidth:l!==-1?`${l}px`:void 0,maxHeight:c!==-1?`${c}px`:void 0}});function i(l){const c=Zi(l);t.value.dispatchEvent(c)}return(l,c)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreImage",style:wt(o.value),onClick:i},[Z("img",{src:E(n).src.value,alt:E(n).caption.value,draggable:"false",style:wt(s.value)},null,12,sae),E(n).caption.value||E(n).caption.value===0?($(),R("div",iae,je(E(n).caption.value),1)):ge("",!0)],4))}}),rm=e=>{e.writer&&(e.writer.docs=`Use your app's static folder to serve images directly. For example, \`static/my_image.png\`.
8146
8146
 
8147
8147
  Alternatively, pass a Matplotlib figure via state.
8148
8148
 
@@ -8152,7 +8152,7 @@ You can also use packed files or bytes:
8152
8152
 
8153
8153
  \`state["img_b"] = wf.pack_bytes(img_bytes, "image/png")\`
8154
8154
 
8155
- \`state["img_f"] = wf.pack_file(img_file, "image/png")\``)};typeof rm=="function"&&rm(yg);const uae=ke(yg,[["__scopeId","data-v-72ccb130"]]),hae={},pae={class:"LoadingSymbol"};function fae(e,t){return $(),R("div",pae,t[0]||(t[0]=[Z("div",null,null,-1)]))}const Mg=ke(hae,[["render",fae],["__scopeId","data-v-5a38f374"]]),mae={class:"BaseEmptiness"},vae={class:"content"},gae={class:"title"},yae={key:0,class:"message"},Mae=$e({__name:"BaseEmptiness",props:{componentId:{type:String,required:!0},message:{type:String,required:!1,default:void 0}},setup(e){const t=e,a=re(ne.core),n=H(()=>a.getComponentById(t.componentId)),r=H(()=>a.getComponentDefinition(n.value.type));return(o,s)=>($(),R("div",mae,[Z("div",vae,[Z("div",gae,[Z("h3",null,"Empty "+je(r.value.name),1)]),e.message?($(),R("div",yae,je(e.message),1)):ge("",!0)])]))}}),Sd=ke(Mae,[["__scopeId","data-v-8c972dbe"]]),_ae={key:0,class:"message"},bae="A component that displays a message in various styles, including success, error, warning, and informational.",wae={writer:{name:"Message",description:bae,category:"Content",fields:{message:{name:"Message",type:Q.Text,desc:"Prefix with '+' for a success message, with '-' for error, '!' for warning, '%' for loading. No prefix for info. Leave empty to hide."},successColor:{name:"Success",default:Ht.Green3,type:Q.Color,category:ot.Style},errorColor:{name:"Error",default:Ht.Orange2,type:Q.Color,category:ot.Style},warningColor:{name:"Warning",default:"#FFE999",type:Q.Color,category:ot.Style},infoColor:{name:"Info",default:Ht.Blue2,type:Q.Color,category:ot.Style},loadingColor:{name:"Loading",default:Ht.Blue2,type:Q.Color,category:ot.Style},primaryTextColor:ua,cssClasses:mt},previewField:"name"}},_g=$e({...wae,__name:"CoreMessage",setup(e){const t=re(ne.componentId),a=re(ne.evaluatedFields),n=re(ne.isBeingEdited),r=H(()=>{const i=a.message.value;if(!i)return"neutral";const l=i.charAt(0);return l=="+"?"success":l=="-"?"error":l=="!"?"warning":l=="%"?"loading":"info"}),o=H(()=>{const i=a.message.value;if(!i)return;const l=i.charAt(0);return l=="+"||l=="-"||l=="!"||l=="%"?i.substring(1).trim():i}),s=H(()=>({"--messageActiveSeverityColor":{error:a.errorColor.value,success:a.successColor.value,warning:a.warningColor.value,info:a.infoColor.value,loading:a.loadingColor.value}[r.value]}));return(i,l)=>o.value||E(n)?($(),R("div",{key:0,class:ft(["CoreMessage",r.value]),style:bt(s.value)},[o.value?($(),R("p",_ae,[r.value=="loading"?($(),Ie(Mg,{key:0,class:"loadingSymbol"})):ge("",!0),Z("span",null,je(o.value),1)])):($(),Ie(Sd,{key:1,"component-id":E(t)},null,8,["component-id"]))],6)):ge("",!0)}}),om=e=>{e.writer&&(e.writer.docs=`When working with operations that can succeed or fail, _Message_ can be useful. You can reserve a state element to be used for the outcome of the operation; empty messages aren't shown, so you can initialise it empty.
8155
+ \`state["img_f"] = wf.pack_file(img_file, "image/png")\``)};typeof rm=="function"&&rm(yg);const uae=ke(yg,[["__scopeId","data-v-72ccb130"]]),hae={},pae={class:"LoadingSymbol"};function fae(e,t){return $(),R("div",pae,t[0]||(t[0]=[Z("div",null,null,-1)]))}const Mg=ke(hae,[["render",fae],["__scopeId","data-v-5a38f374"]]),mae={class:"BaseEmptiness"},vae={class:"content"},gae={class:"title"},yae={key:0,class:"message"},Mae=$e({__name:"BaseEmptiness",props:{componentId:{type:String,required:!0},message:{type:String,required:!1,default:void 0}},setup(e){const t=e,a=re(ne.core),n=H(()=>a.getComponentById(t.componentId)),r=H(()=>a.getComponentDefinition(n.value.type));return(o,s)=>($(),R("div",mae,[Z("div",vae,[Z("div",gae,[Z("h3",null,"Empty "+je(r.value.name),1)]),e.message?($(),R("div",yae,je(e.message),1)):ge("",!0)])]))}}),Sd=ke(Mae,[["__scopeId","data-v-8c972dbe"]]),_ae={key:0,class:"message"},bae="A component that displays a message in various styles, including success, error, warning, and informational.",wae={writer:{name:"Message",description:bae,category:"Content",fields:{message:{name:"Message",type:Q.Text,desc:"Prefix with '+' for a success message, with '-' for error, '!' for warning, '%' for loading. No prefix for info. Leave empty to hide."},successColor:{name:"Success",default:Ht.Green3,type:Q.Color,category:ot.Style},errorColor:{name:"Error",default:Ht.Orange2,type:Q.Color,category:ot.Style},warningColor:{name:"Warning",default:"#FFE999",type:Q.Color,category:ot.Style},infoColor:{name:"Info",default:Ht.Blue2,type:Q.Color,category:ot.Style},loadingColor:{name:"Loading",default:Ht.Blue2,type:Q.Color,category:ot.Style},primaryTextColor:ua,cssClasses:mt},previewField:"name"}},_g=$e({...wae,__name:"CoreMessage",setup(e){const t=re(ne.componentId),a=re(ne.evaluatedFields),n=re(ne.isBeingEdited),r=H(()=>{const i=a.message.value;if(!i)return"neutral";const l=i.charAt(0);return l=="+"?"success":l=="-"?"error":l=="!"?"warning":l=="%"?"loading":"info"}),o=H(()=>{const i=a.message.value;if(!i)return;const l=i.charAt(0);return l=="+"||l=="-"||l=="!"||l=="%"?i.substring(1).trim():i}),s=H(()=>({"--messageActiveSeverityColor":{error:a.errorColor.value,success:a.successColor.value,warning:a.warningColor.value,info:a.infoColor.value,loading:a.loadingColor.value}[r.value]}));return(i,l)=>o.value||E(n)?($(),R("div",{key:0,class:ft(["CoreMessage",r.value]),style:wt(s.value)},[o.value?($(),R("p",_ae,[r.value=="loading"?($(),Ie(Mg,{key:0,class:"loadingSymbol"})):ge("",!0),Z("span",null,je(o.value),1)])):($(),Ie(Sd,{key:1,"component-id":E(t)},null,8,["component-id"]))],6)):ge("",!0)}}),om=e=>{e.writer&&(e.writer.docs=`When working with operations that can succeed or fail, _Message_ can be useful. You can reserve a state element to be used for the outcome of the operation; empty messages aren't shown, so you can initialise it empty.
8156
8156
  Then, assign a message when the operation is completed.
8157
8157
 
8158
8158
  \`\`\`python
@@ -8162,13 +8162,13 @@ if is_ok:
8162
8162
  state["msg"] = "+It worked!"
8163
8163
  else:
8164
8164
  state["msg"] = "-It failed"
8165
- \`\`\``)};typeof om=="function"&&om(_g);const xae=ke(_g,[["__scopeId","data-v-5eb22d34"]]),Cae={key:0,class:"name"},Aae={key:1,class:"description"},Sae={class:"value"},$ae={key:2,class:"note"},Eae="A component that prominently displays a metric value and associated information.",Iae={writer:{name:"Metric",description:Eae,category:"Content",fields:{name:{name:"Name",init:"Metric",type:Q.Text},metricValue:{name:"Value",default:"-",type:Q.Text,desc:"The main value to be displayed. It's not limited to numbers."},description:{name:"Description",type:Q.Text},note:{name:"Note",init:"+Pass",type:Q.Text,desc:"Prefix with '+' for a positive message, with '-' for a negative message."},primaryTextColor:ua,secondaryTextColor:In,positiveColor:{name:"Positive",default:Ht.Green3,type:Q.Color,category:ot.Style},neutralColor:{name:"Neutral",default:"var(--separatorColor)",type:Q.Color,category:ot.Style},negativeColor:{name:"Negative",default:Ht.Orange2,type:Q.Color,category:ot.Style},cssClasses:mt},previewField:"name"}},kae=$e({...Iae,__name:"CoreMetric",setup(e){const t=re(ne.evaluatedFields),a=H(()=>{const o=t.note.value;if(!o)return"neutral";const s=o.charAt(0);return s=="+"?"positive":s=="-"?"negative":"neutral"}),n=H(()=>{const o=t.note.value;if(!o)return;const s=o.charAt(0);return s=="+"||s=="-"?o.substring(1):o}),r=H(()=>({"--messageActiveSentimentColor":{positive:t.positiveColor.value,neutral:t.neutralColor.value,negative:t.negativeColor.value}[a.value]}));return(o,s)=>($(),R("div",{class:"CoreMetric",style:bt(r.value)},[E(t).name.value?($(),R("div",Cae,je(E(t).name.value),1)):ge("",!0),E(t).description.value?($(),R("div",Aae,je(E(t).description.value),1)):ge("",!0),Z("h2",Sae,je(E(t).metricValue.value),1),n.value?($(),R("div",$ae,je(n.value),1)):ge("",!0)],4))}}),Tae=ke(kae,[["__scopeId","data-v-7b11fe28"]]),Pae="A component that displays Plotly graphs.",Lae={data:[{x:["a","b","c"],y:[22,25,29],type:"bar"}]},Vae={writer:{name:"Plotly graph",description:Pae,category:"Content",fields:{spec:{name:"Graph specification",default:JSON.stringify(Lae,null,2),desc:"Plotly graph specification. Pass it using state, e.g. @{fig}, or paste a JSON specification.",type:Q.Object},cssClasses:mt},events:{"plotly-click":{desc:"Sends a list with the clicked points.",eventPayloadExample:{curveNumber:0,pointNumber:2,x:"c",y:29,label:"c",xaxis:{anchor:"y"},yaxis:{anchor:"x"}}},"plotly-selected":{desc:"Sends a list with the selected points."},"plotly-deselect":{desc:"Triggered when points are deselected."}}}},bg=$e({...Vae,__name:"CorePlotlyGraph",setup(e){const t=pt("rootEl"),a=pt("chartTargetEl"),n=re(ne.evaluatedFields),r=H(()=>n.spec.value),o={paper_bgcolor:Ht.White,plot_bgcolor:Ht.Gray1,colorway:[Ht.Blue4,Ht.Blue4,Ht.Orange4,Ht.Green5],font:{family:"Poppins, sans-serif",size:12,color:Ht.Black},hoverlabel:{color:Ht.White,bgcolor:Ht.Black}},s=async()=>{var f,m,g;if(!r.value||!a.value)return;const u=await zt(()=>import("./plotly.min-DmBAN9XQ.js").then(_=>_.p),[],import.meta.url);if(!t.value||t.value.clientHeight==0)return;const h={...r.value,layout:{...o,...(f=r.value)==null?void 0:f.layout}};u.newPlot(a.value,h),l(),(g=(m=r.value)==null?void 0:m.layout)!=null&&g.autosize&&i()};function i(){const u=t.value.parentElement;u!=null&&u.clientHeight&&(t.value.style.height="100%",a.value.style.height="100%")}function l(){a.value.on("plotly_click",d("plotly-click")),a.value.on("plotly_selected",d("plotly-selected")),a.value.on("plotly_deselect",d("plotly-deselect"))}function c(u){var h,f;return{curveNumber:u.curveNumber,pointNumber:u.pointNumber,pointNumbers:u.pointNumbers,x:u.x,y:u.y,z:u.z,label:u.label,lat:u.lat,lon:u.lon,xaxis:{anchor:(h=u.xaxis)==null?void 0:h.anchor},yaxis:{anchor:(f=u.yaxis)==null?void 0:f.anchor}}}function d(u){return h=>{var m;const f=new CustomEvent(u,{detail:{payload:(m=h==null?void 0:h.points)==null?void 0:m.map(g=>c(g))}});t.value.dispatchEvent(f)}}return We(r,u=>{u&&s()}),ia(async()=>{await s(),t.value&&new ResizeObserver(s).observe(t.value,{box:"border-box"})}),(u,h)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CorePlotlyGraph"},[Z("div",{ref_key:"chartTargetEl",ref:a,class:"target"},null,512),h[0]||(h[0]=Z("div",{class:"mask"},null,-1))],512))}}),sm=e=>{e.writer&&(e.writer.docs=`You can listen to events triggered by Plotly.js and add interactivity to your charts.
8165
+ \`\`\``)};typeof om=="function"&&om(_g);const xae=ke(_g,[["__scopeId","data-v-5eb22d34"]]),Cae={key:0,class:"name"},Aae={key:1,class:"description"},Sae={class:"value"},$ae={key:2,class:"note"},Eae="A component that prominently displays a metric value and associated information.",Iae={writer:{name:"Metric",description:Eae,category:"Content",fields:{name:{name:"Name",init:"Metric",type:Q.Text},metricValue:{name:"Value",default:"-",type:Q.Text,desc:"The main value to be displayed. It's not limited to numbers."},description:{name:"Description",type:Q.Text},note:{name:"Note",init:"+Pass",type:Q.Text,desc:"Prefix with '+' for a positive message, with '-' for a negative message."},primaryTextColor:ua,secondaryTextColor:In,positiveColor:{name:"Positive",default:Ht.Green3,type:Q.Color,category:ot.Style},neutralColor:{name:"Neutral",default:"var(--separatorColor)",type:Q.Color,category:ot.Style},negativeColor:{name:"Negative",default:Ht.Orange2,type:Q.Color,category:ot.Style},cssClasses:mt},previewField:"name"}},kae=$e({...Iae,__name:"CoreMetric",setup(e){const t=re(ne.evaluatedFields),a=H(()=>{const o=t.note.value;if(!o)return"neutral";const s=o.charAt(0);return s=="+"?"positive":s=="-"?"negative":"neutral"}),n=H(()=>{const o=t.note.value;if(!o)return;const s=o.charAt(0);return s=="+"||s=="-"?o.substring(1):o}),r=H(()=>({"--messageActiveSentimentColor":{positive:t.positiveColor.value,neutral:t.neutralColor.value,negative:t.negativeColor.value}[a.value]}));return(o,s)=>($(),R("div",{class:"CoreMetric",style:wt(r.value)},[E(t).name.value?($(),R("div",Cae,je(E(t).name.value),1)):ge("",!0),E(t).description.value?($(),R("div",Aae,je(E(t).description.value),1)):ge("",!0),Z("h2",Sae,je(E(t).metricValue.value),1),n.value?($(),R("div",$ae,je(n.value),1)):ge("",!0)],4))}}),Tae=ke(kae,[["__scopeId","data-v-7b11fe28"]]),Pae="A component that displays Plotly graphs.",Lae={data:[{x:["a","b","c"],y:[22,25,29],type:"bar"}]},Vae={writer:{name:"Plotly graph",description:Pae,category:"Content",fields:{spec:{name:"Graph specification",default:JSON.stringify(Lae,null,2),desc:"Plotly graph specification. Pass it using state, e.g. @{fig}, or paste a JSON specification.",type:Q.Object},cssClasses:mt},events:{"plotly-click":{desc:"Sends a list with the clicked points.",eventPayloadExample:{curveNumber:0,pointNumber:2,x:"c",y:29,label:"c",xaxis:{anchor:"y"},yaxis:{anchor:"x"}}},"plotly-selected":{desc:"Sends a list with the selected points."},"plotly-deselect":{desc:"Triggered when points are deselected."}}}},bg=$e({...Vae,__name:"CorePlotlyGraph",setup(e){const t=pt("rootEl"),a=pt("chartTargetEl"),n=re(ne.evaluatedFields),r=H(()=>n.spec.value),o={paper_bgcolor:Ht.White,plot_bgcolor:Ht.Gray1,colorway:[Ht.Blue4,Ht.Blue4,Ht.Orange4,Ht.Green5],font:{family:"Poppins, sans-serif",size:12,color:Ht.Black},hoverlabel:{color:Ht.White,bgcolor:Ht.Black}},s=async()=>{var f,m,g;if(!r.value||!a.value)return;const u=await zt(()=>import("./plotly.min-B_7RxSHC.js").then(_=>_.p),[],import.meta.url);if(!t.value||t.value.clientHeight==0)return;const h={...r.value,layout:{...o,...(f=r.value)==null?void 0:f.layout}};u.newPlot(a.value,h),l(),(g=(m=r.value)==null?void 0:m.layout)!=null&&g.autosize&&i()};function i(){const u=t.value.parentElement;u!=null&&u.clientHeight&&(t.value.style.height="100%",a.value.style.height="100%")}function l(){a.value.on("plotly_click",d("plotly-click")),a.value.on("plotly_selected",d("plotly-selected")),a.value.on("plotly_deselect",d("plotly-deselect"))}function c(u){var h,f;return{curveNumber:u.curveNumber,pointNumber:u.pointNumber,pointNumbers:u.pointNumbers,x:u.x,y:u.y,z:u.z,label:u.label,lat:u.lat,lon:u.lon,xaxis:{anchor:(h=u.xaxis)==null?void 0:h.anchor},yaxis:{anchor:(f=u.yaxis)==null?void 0:f.anchor}}}function d(u){return h=>{var m;const f=new CustomEvent(u,{detail:{payload:(m=h==null?void 0:h.points)==null?void 0:m.map(g=>c(g))}});t.value.dispatchEvent(f)}}return We(r,u=>{u&&s()}),ia(async()=>{await s(),t.value&&new ResizeObserver(s).observe(t.value,{box:"border-box"})}),(u,h)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CorePlotlyGraph"},[Z("div",{ref_key:"chartTargetEl",ref:a,class:"target"},null,512),h[0]||(h[0]=Z("div",{class:"mask"},null,-1))],512))}}),sm=e=>{e.writer&&(e.writer.docs=`You can listen to events triggered by Plotly.js and add interactivity to your charts.
8166
8166
  For example, implement cross-filtering.`)};typeof sm=="function"&&sm(bg);const Oae=ke(bg,[["__scopeId","data-v-44c39dcb"]]),Hae={},Rae={class:"SharedControlBar"},Nae={class:"SharedControlBar__content"},Dae={key:0,class:"SharedControlBar__actions"};function Bae(e,t){return $(),R("div",Rae,[Z("div",Nae,[qt(e.$slots,"default",{},void 0,!0)]),e.$slots.actions?($(),R("div",Dae,[qt(e.$slots,"actions",{},void 0,!0)])):ge("",!0)])}const $d=ke(Hae,[["render",Bae],["__scopeId","data-v-1256a7fb"]]),Fae=`
8167
8167
  def click_handler(state):
8168
8168
 
8169
8169
  # Increment counter when the text is clicked
8170
8170
 
8171
- state["counter"] += 1`,jae="A component to display plain text or formatted text using Markdown syntax.",Uae={writer:{name:"Text",description:jae,category:"Content",fields:{text:{name:"Text",init:"Text",desc:"Add text directly, or reference state elements with @{my_text}.",type:Q.Text,control:Ui.Textarea},useMarkdown:Ut({name:"Enable markdown",desc:"The Markdown output will be sanitised; unsafe elements will be removed.",default:"no"}),alignment:{name:"Alignment",default:"left",type:Q.Text,options:{left:"Left",center:"Center",right:"Right"},category:ot.Style},quickCopy:xd({default:"no"}),primaryTextColor:ua,cssClasses:mt},events:{"wf-click":{desc:"Capture single clicks.",stub:Fae.trim()}},previewField:"text"}},zae=$e({...Uae,__name:"CoreText",setup(e){const t=sr({loader:()=>zt(()=>import("./SharedCopyClipboardButton-BAhxC5LU.js"),__vite__mapDeps([3,4,5,6,7,8]),import.meta.url)}),a=pt("rootEl"),n=re(ne.evaluatedFields),r=re(ne.componentId),o=re(ne.core),s=re(ne.isBeingEdited),i=H(()=>!n.text.value),l=H(()=>!i.value||s.value),c=H(()=>{var m;return{cursor:typeof((m=o.getComponentById(r).handlers)==null?void 0:m["wf-click"])<"u"?"pointer":"unset"}}),d=H(()=>({"text-align":n.alignment.value}));function u(h){const f=Zi(h);a.value.dispatchEvent(f)}return(h,f)=>l.value?($(),R("div",{key:0,ref_key:"rootEl",ref:a,class:"CoreText",style:bt(c.value),onClick:u},[i.value?($(),Ie(Sd,{key:0,"component-id":E(r)},null,8,["component-id"])):($(),Ie($d,{key:1},{actions:Xe(()=>[E(n).quickCopy.value?($(),Ie(E(t),{key:0,label:"Copy text",value:E(n).text.value},null,8,["value"])):ge("",!0)]),default:Xe(()=>[E(n).useMarkdown.value?($(),Ie(K3,{key:0,"raw-text":E(n).text.value,style:bt(d.value)},null,8,["raw-text","style"])):($(),R("p",{key:1,class:"plainText",style:bt(d.value)},je(E(n).text.value),5))]),_:1}))],4)):ge("",!0)}}),qae=ke(zae,[["__scopeId","data-v-26fe47d1"]]),wg="A component that displays Vega-Lite/Altair charts.",Wae={$schema:"https://vega.github.io/schema/vega-lite/v5.json",description:wg,data:{values:[{a:"A",b:100},{a:"B",b:200},{a:"C",b:150},{a:"D",b:300}]},mark:"bar",encoding:{x:{field:"a",type:"nominal"},y:{field:"b",type:"quantitative"}}},Zae={writer:{deprecated:!0,name:"Vega Lite chart",description:wg,category:"Content",fields:{spec:{name:"Chart specification",default:JSON.stringify(Wae,null,2),desc:"Vega-Lite chart specification. Pass a Vega Altair chart using state or paste a JSON specification.",type:Q.Object},cssClasses:mt}}},xg=$e({...Zae,__name:"CoreVegaLiteChart",setup(e){const t=pt("rootEl"),a=pt("chartTargetEl"),n=re(ne.evaluatedFields),r=async()=>{if(!n.spec.value||!a.value)return;const{default:o}=await zt(()=>import("./vega-embed.module-SNP5iNdJ.js"),[],import.meta.url);await o(a.value,n.spec.value)};return We(()=>n.spec.value,o=>{o&&r()}),ia(()=>{r(),new ResizeObserver(r).observe(t.value,{box:"border-box"})}),(o,s)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreVegaLiteChart"},[Z("div",{ref_key:"chartTargetEl",ref:a,class:"target"},null,512)],512))}}),im=e=>{e.writer&&(e.writer.docs=`Generate a chart using Altair and pass it via state; it'll be converted to Vega-Lite specification.
8171
+ state["counter"] += 1`,jae="A component to display plain text or formatted text using Markdown syntax.",Uae={writer:{name:"Text",description:jae,category:"Content",fields:{text:{name:"Text",init:"Text",desc:"Add text directly, or reference state elements with @{my_text}.",type:Q.Text,control:Ui.Textarea},useMarkdown:Ut({name:"Enable markdown",desc:"The Markdown output will be sanitised; unsafe elements will be removed.",default:"no"}),alignment:{name:"Alignment",default:"left",type:Q.Text,options:{left:"Left",center:"Center",right:"Right"},category:ot.Style},quickCopy:xd({default:"no"}),primaryTextColor:ua,cssClasses:mt},events:{"wf-click":{desc:"Capture single clicks.",stub:Fae.trim()}},previewField:"text"}},zae=$e({...Uae,__name:"CoreText",setup(e){const t=ir({loader:()=>zt(()=>import("./SharedCopyClipboardButton-ed8bYNvB.js"),__vite__mapDeps([3,4,5,6,7,8]),import.meta.url)}),a=pt("rootEl"),n=re(ne.evaluatedFields),r=re(ne.componentId),o=re(ne.core),s=re(ne.isBeingEdited),i=H(()=>!n.text.value),l=H(()=>!i.value||s.value),c=H(()=>{var m;return{cursor:typeof((m=o.getComponentById(r).handlers)==null?void 0:m["wf-click"])<"u"?"pointer":"unset"}}),d=H(()=>({"text-align":n.alignment.value}));function u(h){const f=Zi(h);a.value.dispatchEvent(f)}return(h,f)=>l.value?($(),R("div",{key:0,ref_key:"rootEl",ref:a,class:"CoreText",style:wt(c.value),onClick:u},[i.value?($(),Ie(Sd,{key:0,"component-id":E(r)},null,8,["component-id"])):($(),Ie($d,{key:1},{actions:Xe(()=>[E(n).quickCopy.value?($(),Ie(E(t),{key:0,label:"Copy text",value:E(n).text.value},null,8,["value"])):ge("",!0)]),default:Xe(()=>[E(n).useMarkdown.value?($(),Ie(K3,{key:0,"raw-text":E(n).text.value,style:wt(d.value)},null,8,["raw-text","style"])):($(),R("p",{key:1,class:"plainText",style:wt(d.value)},je(E(n).text.value),5))]),_:1}))],4)):ge("",!0)}}),qae=ke(zae,[["__scopeId","data-v-26fe47d1"]]),wg="A component that displays Vega-Lite/Altair charts.",Wae={$schema:"https://vega.github.io/schema/vega-lite/v5.json",description:wg,data:{values:[{a:"A",b:100},{a:"B",b:200},{a:"C",b:150},{a:"D",b:300}]},mark:"bar",encoding:{x:{field:"a",type:"nominal"},y:{field:"b",type:"quantitative"}}},Zae={writer:{deprecated:!0,name:"Vega Lite chart",description:wg,category:"Content",fields:{spec:{name:"Chart specification",default:JSON.stringify(Wae,null,2),desc:"Vega-Lite chart specification. Pass a Vega Altair chart using state or paste a JSON specification.",type:Q.Object},cssClasses:mt}}},xg=$e({...Zae,__name:"CoreVegaLiteChart",setup(e){const t=pt("rootEl"),a=pt("chartTargetEl"),n=re(ne.evaluatedFields),r=async()=>{if(!n.spec.value||!a.value)return;const{default:o}=await zt(()=>import("./vega-embed.module-SNP5iNdJ.js"),[],import.meta.url);await o(a.value,n.spec.value)};return We(()=>n.spec.value,o=>{o&&r()}),ia(()=>{r(),new ResizeObserver(r).observe(t.value,{box:"border-box"})}),(o,s)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreVegaLiteChart"},[Z("div",{ref_key:"chartTargetEl",ref:a,class:"target"},null,512)],512))}}),im=e=>{e.writer&&(e.writer.docs=`Generate a chart using Altair and pass it via state; it'll be converted to Vega-Lite specification.
8172
8172
 
8173
8173
  \`state["my_chart"] = chart\`
8174
8174
 
@@ -8182,7 +8182,7 @@ Alternatively, you can pack bytes or files in state:
8182
8182
 
8183
8183
  \`state["vid_f"] = wf.pack_file(vid_file, "video/mp4")\`
8184
8184
 
8185
- Afterwards, you can reference the video using the syntax \`@{vid_f}\`.`)};typeof lm=="function"&&lm(Cg);const Qae=ke(Cg,[["__scopeId","data-v-23bc2e6c"]]),ene={class:"CoreLink"},tne=["href","target","rel"],ane={writer:{name:"Link",description:"A component to create a hyperlink.",category:"Content",fields:{url:{name:"URL",type:Q.Text,default:"https://writer.com",desc:"Specify a URL or choose a page. Keep in mind that you can only link to pages for which a key has been specified.",options:e=>Object.fromEntries(e.getComponents("root",{sortedByPosition:!0}).map(t=>t.content.key).filter(t=>!!t).map(t=>[`#${t}`,`Page with key: ${t}`]))},target:{name:"Target",type:Q.Text,options:{_self:"Self",_blank:"Blank",_parent:"Parent",_top:"Top"},desc:"Specifies where to open the linked document.",default:"_blank"},rel:{name:"Rel",type:Q.Text,desc:"Specifies the relationship between the current document and the linked document."},text:{name:"Text",default:"",type:Q.Text,desc:"The text to display in the link."},primaryTextColor:ua,cssClasses:mt}}},nne=$e({...ane,__name:"CoreLink",setup(e){const t=re(ne.evaluatedFields),a=H(()=>t.text.value||t.url.value);return(n,r)=>($(),R("div",ene,[Z("a",{href:E(t).url.value,target:E(t).target.value,rel:E(t).rel.value},je(a.value),9,tne)]))}}),rne=ke(nne,[["__scopeId","data-v-db333917"]]);function Tr(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function*one(e,t="",a=new WeakSet){if(Tr(e)&&!a.has(e)){a.add(e);for(const n in e){const r=t?`${t}.${n}`:n;yield r,typeof e[n]=="object"&&e[n]!==null&&!Array.isArray(e[n])&&(yield*one(e[n],r,a))}}}function Ki(){const e=new AbortController;return Ir(()=>{e.abort()}),e}class ql extends Error{constructor(t="Operation aborted"){super(t),this.name=ql.name}}function sne(e,{onProgress:t,signal:a}={}){const n=new FileReader;return new Promise((r,o)=>{if(n.onload=()=>{r(String(n.result)||"")},n.onerror=()=>{o(n.error??new Error("Failed to read file"))},n.onprogress=({lengthComputable:s,loaded:i,total:l})=>{if(typeof t=="function"&&s){const c=Math.round(i/l*100);t(c,i,l)}},n.onabort=()=>{o(new ql)},a instanceof AbortSignal){if(a.aborted){n.abort();return}a.addEventListener("abort",()=>n.abort(),{once:!0})}n.readAsDataURL(e)})}let ine=0;function cm(e){var a;return{id:((a=window.crypto)==null?void 0:a.randomUUID())??`file-${ine++}`,file:e,name:e.name,size:e.size}}function lne(e){return Tr(e)&&"name"in e&&"type"in e&&"data"in e&&typeof e.data=="string"&&e.data.startsWith("data:")}function Ag({multiple:e}){const t=Ki(),a=$t([]);function n(d){return d.reduce((u,h)=>u+h.size,0)}function r(d){const u=d.map(h=>cm(h));a.value=Pa(e)?a.value.concat(u):u.slice(0,1)}function o(d){a.value=a.value.filter(u=>u.id!==d)}function s(d){const u=d.map(h=>cm(h));a.value=Pa(e)?u:u.slice(0,1)}function i(){a.value=[]}async function l(){const d=[],u=[];return t.signal.aborted?{encodedFiles:d,rejectedFiles:u}:((await Promise.allSettled(a.value.map(async({file:f})=>{const m=await sne(f,{signal:t.signal});return{name:f.name,type:f.type,data:m}}))).forEach(f=>{if(f.status==="fulfilled")d.push(f.value);else if(f.reason instanceof Error){if(f.reason instanceof ql)return;u.push(f.reason)}}),{encodedFiles:d,rejectedFiles:u})}async function c(d){const u=[];return t.signal.aborted?{decodedFiles:u}:((await Promise.allSettled(d.filter(f=>lne(f)).map(async f=>{const m=await fetch(f.data,{signal:t.signal}),g=await m.blob(),_=g.type||m.headers.get("Content-Type")||f.type||"";return new File([g],f.name,{type:_})}))).forEach(f=>{f.status==="fulfilled"&&u.push(f.value)}),{decodedFiles:u})}return{files:jt(a),calcTotalSize:n,addFiles:r,removeFile:o,replaceFiles:s,clearFiles:i,encodeFiles:l,decodeFiles:c}}const cne=async(e,t)=>e.size<=2*1024*1024?e:new Promise(a=>{const n=document.createElement("canvas"),r=n.getContext("2d");if(!r){t.warn(`Canvas 2D context not available for image optimization: ${e.name}, using original`),a(e);return}const o=new Image,s=URL.createObjectURL(e);o.onload=()=>{let{width:c,height:d}=o;if(c>1920||d>1080){const u=Math.min(1920/c,1080/d);c=Math.floor(c*u),d=Math.floor(d*u)}n.width=c,n.height=d,r.drawImage(o,0,0,c,d),URL.revokeObjectURL(s),n.toBlob(u=>{u?a(new File([u],e.name,{type:"image/jpeg"})):(t.warn(`Failed to compress image: ${e.name}, using original`),a(e))},"image/jpeg",.85)},o.onerror=()=>{URL.revokeObjectURL(s),t.warn(`Failed to optimize image: ${e.name}, using original`),a(e)},o.src=s}),dne={class:"CoreChatbotAvatar"},une=$e({__name:"CoreChatbotAvatar",props:{initials:{type:String,required:!0}},setup(e){return(t,a)=>($(),R("div",dne,je(e.initials),1))}}),hne=ke(une,[["__scopeId","data-v-ce5bb453"]]),pne={class:"WdsModal__main"},fne={key:1,class:"WdsModal__main__title"},mne={class:"WdsModal__main__title__header"},vne={key:0},gne={class:"WdsModal__main__content"},yne={key:2,class:"WdsModal__main__footer"},Mne={key:0,class:"WdsModal__main__footer__hint"},_ne={key:1,class:"WdsModal__main__footer__actions"},bne=$e({__name:"WdsModal",props:{title:{type:String,required:!1,default:null},size:{type:String,required:!1,default:"normal"},description:{type:String,required:!1,default:null},actions:{type:Array,required:!1,default:()=>[]},allowOverflow:{type:Boolean,required:!1},displayCloseButton:{type:Boolean,required:!1},hint:{type:String,required:!1,default:void 0}},emits:{close:()=>!0},setup(e){const t=e,{title:a,actions:n}=a0(t);return(r,o)=>{var s,i;return $(),Ie(_v,{to:"#modal"},[Z("div",{class:ft(["WdsModal colorTransformer",{"WdsModal--overflow":e.allowOverflow,"WdsModal--wide":e.size=="wide"}]),tabindex:"-1"},[Z("div",pne,[e.displayCloseButton?($(),Ie(La,{key:0,variant:"neutral",size:"smallIcon",class:"WdsModal__main__closeBtn",onClick:o[0]||(o[0]=l=>r.$emit("close"))},{default:Xe(()=>[Ce(_t,{name:"x"})]),_:1})):ge("",!0),E(a)||e.description?($(),R("div",fne,[Z("div",mne,[Z("h2",null,je(E(a)),1),qt(r.$slots,"titleActions",{},void 0,!0)]),e.description?($(),R("summary",vne,je(e.description),1)):ge("",!0)])):ge("",!0),Z("div",gne,[qt(r.$slots,"default",{},void 0,!0)]),((s=E(n))==null?void 0:s.length)>0||e.hint?($(),R("div",yne,[e.hint?($(),R("p",Mne,je(e.hint),1)):ge("",!0),((i=E(n))==null?void 0:i.length)>0?($(),R("div",_ne,[($(!0),R(Je,null,Ot(E(n),(l,c)=>($(),Ie(La,{key:c,variant:c==E(n).length-1?"primary":"tertiary",disabled:l.disabled,loading:l.loading,onClick:l.fn},{default:Xe(()=>[l.icon?($(),Ie(_t,{key:0,name:l.icon},null,8,["name"])):ge("",!0),pa(" "+je(l.desc),1)]),_:2},1032,["variant","disabled","loading","onClick"]))),128))])):ge("",!0)])):ge("",!0)])],2)])}}}),Sg=ke(bne,[["__scopeId","data-v-dcb8fed3"]]),wne=["aria-busy"],xne={key:1,class:"CoreChatbotMessage__content__text"},Cne={key:0,class:"content-fragment"},Ane={key:1},Sne={key:0,class:"message-images-wrapper"},$ne={class:"message-images-container"},Ene=["src","aria-label","onClick","onKeydown"],Ine={key:2,class:"CoreChatbotMessage__content__actions"},kne=["onClick"],Tne={key:0,class:"subheading"},Pne={class:"name"},Lne={key:1,class:"desc"},Vne=["src"],One=$e({__name:"CoreChatbotMessage",props:{initials:{type:String,required:!0},useMarkdown:{type:Boolean,required:!1},message:{type:Object,required:!1,default:void 0},assistantRoleColor:{type:String,required:!1,default:""},isLoading:{type:Boolean,required:!1}},emits:{actionClick:e=>typeof e=="object"&&e!==null},setup(e){const t=sr({loader:()=>zt(()=>import("./BaseMarkdown-CsWzSrDd.js"),[],import.meta.url)}),a=sr({loader:()=>zt(()=>Promise.resolve().then(()=>Ite),void 0,import.meta.url)}),n=e,r=H(()=>{var f;return((f=n.message)==null?void 0:f.actions)??[]}),o=H(()=>n.isLoading&&!i.value),s=H(()=>{var f;return n.isLoading?"assistant":((f=n.message)==null?void 0:f.role)??""}),i=H(()=>{var m;const f=(m=n.message)==null?void 0:m.content;return Array.isArray(f)?f:(f==null?void 0:f.trim())??""}),l=H(()=>{switch(s.value){case"user":return"var(--userRoleColor)";case"assistant":return n.assistantRoleColor||"linear-gradient(264deg, #f5ebff 0.71%, #eef1ff 100%)";default:return""}}),c=f=>{const m=f.target;m.style.display="none"},d=ye(),u=f=>f.some(m=>{var g;return m.type==="image_url"&&((g=m.image_url)==null?void 0:g.url)}),h=(f,m)=>{(f.key==="Enter"||f.key===" ")&&(f.preventDefault(),d.value=m)};return(f,m)=>($(),R(Je,null,[Z("div",{class:"CoreChatbotMessage","aria-busy":e.isLoading},[Ce(hne,{initials:e.initials},null,8,["initials"]),Z("div",{class:"CoreChatbotMessage__content",style:bt({background:l.value})},[o.value?($(),Ie(E(a),{key:0})):($(),R("div",xne,[Array.isArray(i.value)?($(),R(Je,{key:0},[($(!0),R(Je,null,Ot(i.value,(g,_)=>($(),R(Je,{key:`text-${_}`},[g.type==="text"?($(),R("div",Cne,[e.useMarkdown?($(),Ie(E(t),{key:0,"raw-text":g.text||""},null,8,["raw-text"])):($(),R("span",Ane,je(g.text),1))])):ge("",!0)],64))),128)),u(i.value)?($(),R("div",Sne,[Z("div",$ne,[($(!0),R(Je,null,Ot(i.value,(g,_)=>{var b,v,y;return $(),R(Je,{key:`image-${_}`},[g.type==="image_url"&&((b=g.image_url)!=null&&b.url)?($(),R("img",{key:0,src:(v=g.image_url)==null?void 0:v.url,alt:"Image from conversation",class:"message-image-preview",loading:"lazy",role:"button",tabindex:"0","aria-label":`Open image in modal - ${(y=g.image_url)==null?void 0:y.url}`,onError:c,onClick:M=>d.value=g.image_url.url,onKeydown:M=>h(M,g.image_url.url)},null,40,Ene)):ge("",!0)],64)}),128))])])):ge("",!0)],64)):($(),R(Je,{key:1},[e.useMarkdown?($(),Ie(E(t),{key:0,"raw-text":i.value},null,8,["raw-text"])):($(),R(Je,{key:1},[pa(je(i.value),1)],64))],64))])),r.value.length?($(),R("div",Ine,[($(!0),R(Je,null,Ot(r.value,(g,_)=>($(),R("button",{key:_,class:"action",onClick:b=>f.$emit("actionClick",g)},[g.subheading?($(),R("div",Tne,je(g.subheading),1)):ge("",!0),Z("h3",Pne,je(g.name),1),g.desc?($(),R("div",Lne,je(g.desc),1)):ge("",!0)],8,kne))),128))])):ge("",!0)],4)],8,wne),d.value?($(),Ie(Sg,{key:0,"display-close-button":!0,onClose:m[0]||(m[0]=g=>d.value=void 0)},{default:Xe(()=>[Z("img",{src:d.value,alt:"Full size image",class:"image-modal-img"},null,8,Vne)]),_:1})):ge("",!0)],64))}}),dm=ke(One,[["__scopeId","data-v-5d4e07d9"]]),Hne=["B","kB","MB","GB","TB","PB","EB","ZB","YB"],Rne=["B","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],Nne=["b","kbit","Mbit","Gbit","Tbit","Pbit","Ebit","Zbit","Ybit"],Dne=["b","kibit","Mibit","Gibit","Tibit","Pibit","Eibit","Zibit","Yibit"],um=(e,t,a)=>{let n=e;return typeof t=="string"||Array.isArray(t)?n=e.toLocaleString(t,a):(t===!0||a!==void 0)&&(n=e.toLocaleString(void 0,a)),n};function fl(e,t){if(!Number.isFinite(e))throw new TypeError(`Expected a finite number, got ${typeof e}: ${e}`);t={bits:!1,binary:!1,space:!0,...t};const a=t.bits?t.binary?Dne:Nne:t.binary?Rne:Hne,n=t.space?" ":"";if(t.signed&&e===0)return` 0${n}${a[0]}`;const r=e<0,o=r?"-":t.signed?"+":"";r&&(e=-e);let s;if(t.minimumFractionDigits!==void 0&&(s={minimumFractionDigits:t.minimumFractionDigits}),t.maximumFractionDigits!==void 0&&(s={maximumFractionDigits:t.maximumFractionDigits,...s}),e<1){const d=um(e,t.locale,s);return o+d+n+a[0]}const i=Math.min(Math.floor(t.binary?Math.log(e)/Math.log(1024):Math.log10(e)/3),a.length-1);e/=(t.binary?1024:1e3)**i,s||(e=e.toPrecision(3));const l=um(Number(e),t.locale,s),c=a[i];return o+l+n+c}const Bne={class:"filesArea"},Fne={key:1,class:"list"},jne=["title"],Une={class:"size"},zne={class:"filesButtons"},qne={key:0,class:"sizeExceededMessage"},Wne={key:1,class:"pastedImagesArea"},Zne={class:"pastedImagesList"},Kne=["src"],Gne={class:"inputArea"},Jne={class:"inputButtons"},Xne="A chatbot component to build human-to-AI interactions.",Yne=`
8185
+ Afterwards, you can reference the video using the syntax \`@{vid_f}\`.`)};typeof lm=="function"&&lm(Cg);const Qae=ke(Cg,[["__scopeId","data-v-23bc2e6c"]]),ene={class:"CoreLink"},tne=["href","target","rel"],ane={writer:{name:"Link",description:"A component to create a hyperlink.",category:"Content",fields:{url:{name:"URL",type:Q.Text,default:"https://writer.com",desc:"Specify a URL or choose a page. Keep in mind that you can only link to pages for which a key has been specified.",options:e=>Object.fromEntries(e.getComponents("root",{sortedByPosition:!0}).map(t=>t.content.key).filter(t=>!!t).map(t=>[`#${t}`,`Page with key: ${t}`]))},target:{name:"Target",type:Q.Text,options:{_self:"Self",_blank:"Blank",_parent:"Parent",_top:"Top"},desc:"Specifies where to open the linked document.",default:"_blank"},rel:{name:"Rel",type:Q.Text,desc:"Specifies the relationship between the current document and the linked document."},text:{name:"Text",default:"",type:Q.Text,desc:"The text to display in the link."},primaryTextColor:ua,cssClasses:mt}}},nne=$e({...ane,__name:"CoreLink",setup(e){const t=re(ne.evaluatedFields),a=H(()=>t.text.value||t.url.value);return(n,r)=>($(),R("div",ene,[Z("a",{href:E(t).url.value,target:E(t).target.value,rel:E(t).rel.value},je(a.value),9,tne)]))}}),rne=ke(nne,[["__scopeId","data-v-db333917"]]);function Pr(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function*one(e,t="",a=new WeakSet){if(Pr(e)&&!a.has(e)){a.add(e);for(const n in e){const r=t?`${t}.${n}`:n;yield r,typeof e[n]=="object"&&e[n]!==null&&!Array.isArray(e[n])&&(yield*one(e[n],r,a))}}}function Ki(){const e=new AbortController;return kr(()=>{e.abort()}),e}class ql extends Error{constructor(t="Operation aborted"){super(t),this.name=ql.name}}function sne(e,{onProgress:t,signal:a}={}){const n=new FileReader;return new Promise((r,o)=>{if(n.onload=()=>{r(String(n.result)||"")},n.onerror=()=>{o(n.error??new Error("Failed to read file"))},n.onprogress=({lengthComputable:s,loaded:i,total:l})=>{if(typeof t=="function"&&s){const c=Math.round(i/l*100);t(c,i,l)}},n.onabort=()=>{o(new ql)},a instanceof AbortSignal){if(a.aborted){n.abort();return}a.addEventListener("abort",()=>n.abort(),{once:!0})}n.readAsDataURL(e)})}let ine=0;function cm(e){var a;return{id:((a=window.crypto)==null?void 0:a.randomUUID())??`file-${ine++}`,file:e,name:e.name,size:e.size}}function lne(e){return Pr(e)&&"name"in e&&"type"in e&&"data"in e&&typeof e.data=="string"&&e.data.startsWith("data:")}function Ag({multiple:e}){const t=Ki(),a=$t([]);function n(d){return d.reduce((u,h)=>u+h.size,0)}function r(d){const u=d.map(h=>cm(h));a.value=Pa(e)?a.value.concat(u):u.slice(0,1)}function o(d){a.value=a.value.filter(u=>u.id!==d)}function s(d){const u=d.map(h=>cm(h));a.value=Pa(e)?u:u.slice(0,1)}function i(){a.value=[]}async function l(){const d=[],u=[];return t.signal.aborted?{encodedFiles:d,rejectedFiles:u}:((await Promise.allSettled(a.value.map(async({file:f})=>{const m=await sne(f,{signal:t.signal});return{name:f.name,type:f.type,data:m}}))).forEach(f=>{if(f.status==="fulfilled")d.push(f.value);else if(f.reason instanceof Error){if(f.reason instanceof ql)return;u.push(f.reason)}}),{encodedFiles:d,rejectedFiles:u})}async function c(d){const u=[];return t.signal.aborted?{decodedFiles:u}:((await Promise.allSettled(d.filter(f=>lne(f)).map(async f=>{const m=await fetch(f.data,{signal:t.signal}),g=await m.blob(),_=g.type||m.headers.get("Content-Type")||f.type||"";return new File([g],f.name,{type:_})}))).forEach(f=>{f.status==="fulfilled"&&u.push(f.value)}),{decodedFiles:u})}return{files:jt(a),calcTotalSize:n,addFiles:r,removeFile:o,replaceFiles:s,clearFiles:i,encodeFiles:l,decodeFiles:c}}const cne=async(e,t)=>e.size<=2*1024*1024?e:new Promise(a=>{const n=document.createElement("canvas"),r=n.getContext("2d");if(!r){t.warn(`Canvas 2D context not available for image optimization: ${e.name}, using original`),a(e);return}const o=new Image,s=URL.createObjectURL(e);o.onload=()=>{let{width:c,height:d}=o;if(c>1920||d>1080){const u=Math.min(1920/c,1080/d);c=Math.floor(c*u),d=Math.floor(d*u)}n.width=c,n.height=d,r.drawImage(o,0,0,c,d),URL.revokeObjectURL(s),n.toBlob(u=>{u?a(new File([u],e.name,{type:"image/jpeg"})):(t.warn(`Failed to compress image: ${e.name}, using original`),a(e))},"image/jpeg",.85)},o.onerror=()=>{URL.revokeObjectURL(s),t.warn(`Failed to optimize image: ${e.name}, using original`),a(e)},o.src=s}),dne={class:"CoreChatbotAvatar"},une=$e({__name:"CoreChatbotAvatar",props:{initials:{type:String,required:!0}},setup(e){return(t,a)=>($(),R("div",dne,je(e.initials),1))}}),hne=ke(une,[["__scopeId","data-v-ce5bb453"]]),pne={class:"WdsModal__main"},fne={key:1,class:"WdsModal__main__title"},mne={class:"WdsModal__main__title__header"},vne={key:0},gne={class:"WdsModal__main__content"},yne={key:2,class:"WdsModal__main__footer"},Mne={key:0,class:"WdsModal__main__footer__hint"},_ne={key:1,class:"WdsModal__main__footer__actions"},bne=$e({__name:"WdsModal",props:{title:{type:String,required:!1,default:null},size:{type:String,required:!1,default:"normal"},description:{type:String,required:!1,default:null},actions:{type:Array,required:!1,default:()=>[]},allowOverflow:{type:Boolean,required:!1},displayCloseButton:{type:Boolean,required:!1},hint:{type:String,required:!1,default:void 0}},emits:{close:()=>!0},setup(e){const t=e,{title:a,actions:n}=a0(t);return(r,o)=>{var s,i;return $(),Ie(_v,{to:"#modal"},[Z("div",{class:ft(["WdsModal colorTransformer",{"WdsModal--overflow":e.allowOverflow,"WdsModal--wide":e.size=="wide"}]),tabindex:"-1"},[Z("div",pne,[e.displayCloseButton?($(),Ie(La,{key:0,variant:"neutral",size:"smallIcon",class:"WdsModal__main__closeBtn",onClick:o[0]||(o[0]=l=>r.$emit("close"))},{default:Xe(()=>[Ce(bt,{name:"x"})]),_:1})):ge("",!0),E(a)||e.description?($(),R("div",fne,[Z("div",mne,[Z("h2",null,je(E(a)),1),qt(r.$slots,"titleActions",{},void 0,!0)]),e.description?($(),R("summary",vne,je(e.description),1)):ge("",!0)])):ge("",!0),Z("div",gne,[qt(r.$slots,"default",{},void 0,!0)]),((s=E(n))==null?void 0:s.length)>0||e.hint?($(),R("div",yne,[e.hint?($(),R("p",Mne,je(e.hint),1)):ge("",!0),((i=E(n))==null?void 0:i.length)>0?($(),R("div",_ne,[($(!0),R(Je,null,Ot(E(n),(l,c)=>($(),Ie(La,{key:c,variant:c==E(n).length-1?"primary":"tertiary",disabled:l.disabled,loading:l.loading,onClick:l.fn},{default:Xe(()=>[l.icon?($(),Ie(bt,{key:0,name:l.icon},null,8,["name"])):ge("",!0),pa(" "+je(l.desc),1)]),_:2},1032,["variant","disabled","loading","onClick"]))),128))])):ge("",!0)])):ge("",!0)])],2)])}}}),Sg=ke(bne,[["__scopeId","data-v-dcb8fed3"]]),wne=["aria-busy"],xne={key:1,class:"CoreChatbotMessage__content__text"},Cne={key:0,class:"content-fragment"},Ane={key:1},Sne={key:0,class:"message-images-wrapper"},$ne={class:"message-images-container"},Ene=["src","aria-label","onClick","onKeydown"],Ine={key:2,class:"CoreChatbotMessage__content__actions"},kne=["onClick"],Tne={key:0,class:"subheading"},Pne={class:"name"},Lne={key:1,class:"desc"},Vne=["src"],One=$e({__name:"CoreChatbotMessage",props:{initials:{type:String,required:!0},useMarkdown:{type:Boolean,required:!1},message:{type:Object,required:!1,default:void 0},assistantRoleColor:{type:String,required:!1,default:""},isLoading:{type:Boolean,required:!1}},emits:{actionClick:e=>typeof e=="object"&&e!==null},setup(e){const t=ir({loader:()=>zt(()=>import("./BaseMarkdown-C7JpFNzG.js"),[],import.meta.url)}),a=ir({loader:()=>zt(()=>Promise.resolve().then(()=>Ite),void 0,import.meta.url)}),n=e,r=H(()=>{var f;return((f=n.message)==null?void 0:f.actions)??[]}),o=H(()=>n.isLoading&&!i.value),s=H(()=>{var f;return n.isLoading?"assistant":((f=n.message)==null?void 0:f.role)??""}),i=H(()=>{var m;const f=(m=n.message)==null?void 0:m.content;return Array.isArray(f)?f:(f==null?void 0:f.trim())??""}),l=H(()=>{switch(s.value){case"user":return"var(--userRoleColor)";case"assistant":return n.assistantRoleColor||"linear-gradient(264deg, #f5ebff 0.71%, #eef1ff 100%)";default:return""}}),c=f=>{const m=f.target;m.style.display="none"},d=ye(),u=f=>f.some(m=>{var g;return m.type==="image_url"&&((g=m.image_url)==null?void 0:g.url)}),h=(f,m)=>{(f.key==="Enter"||f.key===" ")&&(f.preventDefault(),d.value=m)};return(f,m)=>($(),R(Je,null,[Z("div",{class:"CoreChatbotMessage","aria-busy":e.isLoading},[Ce(hne,{initials:e.initials},null,8,["initials"]),Z("div",{class:"CoreChatbotMessage__content",style:wt({background:l.value})},[o.value?($(),Ie(E(a),{key:0})):($(),R("div",xne,[Array.isArray(i.value)?($(),R(Je,{key:0},[($(!0),R(Je,null,Ot(i.value,(g,_)=>($(),R(Je,{key:`text-${_}`},[g.type==="text"?($(),R("div",Cne,[e.useMarkdown?($(),Ie(E(t),{key:0,"raw-text":g.text||""},null,8,["raw-text"])):($(),R("span",Ane,je(g.text),1))])):ge("",!0)],64))),128)),u(i.value)?($(),R("div",Sne,[Z("div",$ne,[($(!0),R(Je,null,Ot(i.value,(g,_)=>{var b,v,y;return $(),R(Je,{key:`image-${_}`},[g.type==="image_url"&&((b=g.image_url)!=null&&b.url)?($(),R("img",{key:0,src:(v=g.image_url)==null?void 0:v.url,alt:"Image from conversation",class:"message-image-preview",loading:"lazy",role:"button",tabindex:"0","aria-label":`Open image in modal - ${(y=g.image_url)==null?void 0:y.url}`,onError:c,onClick:M=>d.value=g.image_url.url,onKeydown:M=>h(M,g.image_url.url)},null,40,Ene)):ge("",!0)],64)}),128))])])):ge("",!0)],64)):($(),R(Je,{key:1},[e.useMarkdown?($(),Ie(E(t),{key:0,"raw-text":i.value},null,8,["raw-text"])):($(),R(Je,{key:1},[pa(je(i.value),1)],64))],64))])),r.value.length?($(),R("div",Ine,[($(!0),R(Je,null,Ot(r.value,(g,_)=>($(),R("button",{key:_,class:"action",onClick:b=>f.$emit("actionClick",g)},[g.subheading?($(),R("div",Tne,je(g.subheading),1)):ge("",!0),Z("h3",Pne,je(g.name),1),g.desc?($(),R("div",Lne,je(g.desc),1)):ge("",!0)],8,kne))),128))])):ge("",!0)],4)],8,wne),d.value?($(),Ie(Sg,{key:0,"display-close-button":!0,onClose:m[0]||(m[0]=g=>d.value=void 0)},{default:Xe(()=>[Z("img",{src:d.value,alt:"Full size image",class:"image-modal-img"},null,8,Vne)]),_:1})):ge("",!0)],64))}}),dm=ke(One,[["__scopeId","data-v-5d4e07d9"]]),Hne=["B","kB","MB","GB","TB","PB","EB","ZB","YB"],Rne=["B","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],Nne=["b","kbit","Mbit","Gbit","Tbit","Pbit","Ebit","Zbit","Ybit"],Dne=["b","kibit","Mibit","Gibit","Tibit","Pibit","Eibit","Zibit","Yibit"],um=(e,t,a)=>{let n=e;return typeof t=="string"||Array.isArray(t)?n=e.toLocaleString(t,a):(t===!0||a!==void 0)&&(n=e.toLocaleString(void 0,a)),n};function fl(e,t){if(!Number.isFinite(e))throw new TypeError(`Expected a finite number, got ${typeof e}: ${e}`);t={bits:!1,binary:!1,space:!0,...t};const a=t.bits?t.binary?Dne:Nne:t.binary?Rne:Hne,n=t.space?" ":"";if(t.signed&&e===0)return` 0${n}${a[0]}`;const r=e<0,o=r?"-":t.signed?"+":"";r&&(e=-e);let s;if(t.minimumFractionDigits!==void 0&&(s={minimumFractionDigits:t.minimumFractionDigits}),t.maximumFractionDigits!==void 0&&(s={maximumFractionDigits:t.maximumFractionDigits,...s}),e<1){const d=um(e,t.locale,s);return o+d+n+a[0]}const i=Math.min(Math.floor(t.binary?Math.log(e)/Math.log(1024):Math.log10(e)/3),a.length-1);e/=(t.binary?1024:1e3)**i,s||(e=e.toPrecision(3));const l=um(Number(e),t.locale,s),c=a[i];return o+l+n+c}const Bne={class:"filesArea"},Fne={key:1,class:"list"},jne=["title"],Une={class:"size"},zne={class:"filesButtons"},qne={key:0,class:"sizeExceededMessage"},Wne={key:1,class:"pastedImagesArea"},Zne={class:"pastedImagesList"},Kne=["src"],Gne={class:"inputArea"},Jne={class:"inputButtons"},Xne="A chatbot component to build human-to-AI interactions.",Yne=`
8186
8186
  def handle_message_simple(payload, state):
8187
8187
 
8188
8188
  # payload contains a dict in the form { "role": "user", "message": "hello"}
@@ -8236,7 +8236,7 @@ def handle_file_upload(state, payload):
8236
8236
  file_data = uploaded_file.get("data")
8237
8237
  with open(f"{name}-{i}.jpeg", "wb") as file_handle:
8238
8238
  file_handle.write(file_data)
8239
- `.trim(),tre={writer:{name:"Chatbot",description:Xne,category:"Content",fields:{conversation:{name:"Conversation",init:"@{chat}",desc:"An array with messages or a variable that contains your conversation as an object.",type:Q.Object,validator:XE},assistantInitials:{name:"Assistant initials",default:"AI",type:Q.Text},userInitials:{name:"User initials",default:"YOU",type:Q.Text},useMarkdown:Ut({name:"Enable markdown",desc:"If active, the output will be sanitized; unsafe elements will be removed.",default:"no"}),enableFileUpload:{name:"Enable file upload",default:"no",type:Q.Text,options:{single:"Single file",multiple:"Multiple files",no:"No"}},enableImagePaste:Ut({name:"Enable image paste",desc:"Allow users to paste images directly into the chat input using Ctrl/Cmd+V.",default:"yes"}),placeholder:{name:"Placeholder",default:"What do you need?",type:Q.Text},assistantRoleColor:{name:"Assistant role",type:Q.Color,category:ot.Style,applyStyleVariable:!0},userRoleColor:{name:"User role",default:Ht.Gray1,type:Q.Color,category:ot.Style,applyStyleVariable:!0},avatarBackgroundColor:{name:"Avatar",default:Ht.Gray6,type:Q.Color,category:ot.Style,applyStyleVariable:!0},avatarTextColor:{name:"Avatar text",default:Ht.White,type:Q.Color,category:ot.Style,applyStyleVariable:!0},accentColor:Ia,containerBackgroundColor:kr,primaryTextColor:ua,secondaryTextColor:In,separatorColor:wa,buttonColor:{...cr,default:Ht.Black},buttonTextColor:{...dr,default:Ht.White},cssClasses:mt},events:{"wf-chatbot-message":{desc:"Triggered when the user sends a message.",stub:Yne,eventPayloadExample:{role:"user",content:"I'm building a Chatbot"}},"wf-chatbot-action-click":{desc:"Handle clicks on actions.",stub:Qne},"wf-file-change":{desc:"Triggered when files are uploaded",stub:ere}}}},$g=$e({...tre,__name:"CoreChatbot",setup(e){const t=pt("rootEl"),a=pt("messageAreaEl"),n=pt("messagesEl"),r=ye(void 0),o=re(ne.evaluatedFields),s=fa(),i=$t([]),l=$t([]),c=$t([]);let d=0;const u=ye(!1),h=ye(null),f=ye(!1),m=ye(!1);let g,_;const b=H(()=>{var O;return((O=o.conversation)==null?void 0:O.value)??[]}),v=ye(""),y=H(()=>o.enableFileUpload.value==="multiple"),{files:M,calcTotalSize:x,addFiles:S,removeFile:L,clearFiles:F,encodeFiles:te}=Ag({multiple:y}),J=200*1024*1024,be=H(()=>x(M.value)>J),oe=H(()=>r.value===void 0?!1:r.value>=b.value.length);function Te(O){var ae;if(O&&"isComposing"in O&&O.isComposing||r.value)return;if(u.value){j("Images are still processing. Please wait a moment…");return}const k=(ae=v.value)==null?void 0:ae.trim();if(!k&&i.value.length===0)return;r.value=b.value.length+1;let C;if(i.value.length>0){const xe=[];v.value.trim()&&xe.push({type:"text",text:v.value}),i.value.filter(ve=>ve!==null).forEach(ve=>{xe.push({type:"image_url",image_url:{url:ve}})}),C={role:"user",content:xe}}else C={role:"user",content:k};const P=new CustomEvent("wf-chatbot-message",{detail:{payload:C,callback:()=>{r.value=void 0}}});t.value.dispatchEvent(P),v.value="",i.value=[],l.value=[],c.value=[]}function Ue(O){const{data:k}=O,C=new CustomEvent("wf-chatbot-action-click",{detail:{payload:k}});t.value.dispatchEvent(C)}function Ze(){const O=document.createElement("input");O.type="file",y.value&&(O.multiple=!0),O.addEventListener("change",()=>{S(Array.from(O.files||[]))}),O.click()}async function Me(O){var Ae;if(o.enableImagePaste.value!==!0)return;const k=(Ae=O.clipboardData)==null?void 0:Ae.items;if(!k)return;const C=10,P=50*1024*1024,ae=10*1024*1024,xe=["image/jpeg","image/jpg","image/png","image/webp"],ve=[];let ze=0,Ye=0,ct=0;for(let pe=0;pe<k.length;pe++){const ce=k[pe];if(ce.type.startsWith("image/")){if(!xe.includes(ce.type.toLowerCase())){ct++;continue}const ue=ce.getAsFile();if(ue){if(ue.size>ae){Ye++;continue}ze+=ue.size,ve.push(ue)}}}if(ve.length===0){ct>0&&Ye>0?j(`Images not added: ${ct} unsupported format(s) (only JPG, JPEG, PNG supported), ${Ye} too large (max ${ae/1024/1024}MB each).`):ct>0?j("Unsupported image format(s). Only JPG, JPEG, and PNG images are supported."):Ye>0&&j(`Image too large. Maximum size is ${ae/1024/1024}MB per image.`);return}if(i.value.length+ve.length>C){const pe=C-i.value.length;if(pe<=0){j(`Maximum ${C} images allowed. Please remove some images first.`);return}ve.splice(pe),j(`Only ${pe} image(s) added. Maximum ${C} images allowed.`)}if(ze>P){j(`Total size too large (${(ze/1024/1024).toFixed(1)}MB). Maximum ${P/1024/1024}MB total.`);return}const D=[];Ye>0&&D.push(`${Ye} image(s) too large (max ${ae/1024/1024}MB each)`),ct>0&&D.push(`${ct} unsupported format(s) (only JPG, JPEG, PNG supported)`),D.length>0&&j(`${D.join(", ")} - these images were skipped.`),O.preventDefault();const q=ve.map(()=>null),he=ve.map(()=>!0),me=ve.map(()=>`img-${d++}`);i.value=[...i.value,...q],l.value=[...l.value,...he],c.value=[...c.value,...me],u.value=!0;const _e=[];try{await Promise.all(ve.map(async(pe,ce)=>{try{const ue=await cne(pe,s);ue===pe&&pe.size>2*1024*1024?s.log(`Using original file for ${pe.name} (optimization failed)`):ue!==pe&&s.log(`Successfully optimized ${pe.name} from ${(pe.size/1024/1024).toFixed(2)}MB to ${(ue.size/1024/1024).toFixed(2)}MB`);const I=await G(ue),B=me[ce],N=c.value.findIndex(U=>U===B);if(N!==-1&&N<i.value.length){const U=[...i.value],se=[...l.value];U[N]=I,se[N]=!1,i.value=U,l.value=se}return I}catch(ue){return s.error("Failed to process pasted image:",ue),_e.push(ce),null}})),_e.map(pe=>({failureIndex:pe,imageId:me[pe]})).map(({imageId:pe})=>c.value.findIndex(ce=>ce===pe)).filter(pe=>pe!==-1).sort((pe,ce)=>ce-pe).forEach(pe=>{if(pe<i.value.length){const ce=[...i.value],ue=[...l.value],I=[...c.value];ce.splice(pe,1),ue.splice(pe,1),I.splice(pe,1),i.value=ce,l.value=ue,c.value=I}})}catch(pe){s.error("Error processing pasted images:",pe)}finally{u.value=!1}}function ee(O){const k=[...i.value],C=[...l.value],P=[...c.value];k.splice(O,1),C.splice(O,1),P.splice(O,1),i.value=k,l.value=C,c.value=P}function j(O){h.value=O,f.value=!1,_&&clearTimeout(_),_=setTimeout(()=>{f.value=!0,setTimeout(()=>{h.value=null,f.value=!1},300)},5e3)}function K(){a.value.scrollTo({top:a.value.scrollHeight,left:0})}const G=async O=>{const k=new FileReader;return k.readAsDataURL(O),new Promise((C,P)=>{k.onload=()=>C(k.result),k.onerror=()=>P(k.error)})};async function T(){if(M.value.length==0||m.value||be.value)return;m.value=!0;const{encodedFiles:O}=await te();if(O.length===0){m.value=!1;return}t.value.dispatchEvent(new CustomEvent("wf-file-change",{detail:{payload:O,callback:()=>{m.value=!1,F()}}}))}return ia(()=>{g=new ResizeObserver(()=>{K()}),g.observe(n.value)}),Ir(()=>{g.unobserve(n.value),_&&(clearTimeout(_),_=void 0)}),(O,k)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreChatbot"},[Z("div",{ref_key:"messageAreaEl",ref:a,class:"messageArea"},[Z("div",{ref_key:"messagesEl",ref:n,class:"messages"},[($(!0),R(Je,null,Ot(b.value,(C,P)=>($(),Ie(dm,{key:P,message:C,"use-markdown":E(o).useMarkdown.value,"assistant-role-color":E(o).assistantRoleColor.value,initials:C.role==="assistant"?E(o).assistantInitials.value:E(o).userInitials.value,onActionClick:k[0]||(k[0]=ae=>Ue(ae))},null,8,["message","use-markdown","assistant-role-color","initials"]))),128)),oe.value?($(),Ie(dm,{key:0,"is-loading":"",initials:E(o).assistantInitials.value},null,8,["initials"])):ge("",!0)],512)],512),E(M).length>0?($(),R(Je,{key:0},[Z("div",Bne,[m.value?($(),R(Je,{key:0},[pa(" Uploading... ")],64)):($(),R("div",Fne,[($(!0),R(Je,null,Ot(E(M),C=>($(),R("div",{key:C.id,class:"file"},[Z("div",null,[Z("div",{class:"name",title:C.name},je(C.name),9,jne),Z("div",Une,je(E(fl)(C.size)),1)]),Ce(wn,{onClick:P=>E(L)(C.id)},{default:Xe(()=>[Ce(_t,{name:"trash-2"})]),_:2},1032,["onClick"])]))),128))]))]),Z("div",zne,[be.value?($(),R("div",qne,[Ce(_t,{name:"triangle-alert"}),Z("span",null," Size limit of "+je(E(fl)(J))+" exceeded. ",1)])):m.value?ge("",!0):($(),Ie(wn,{key:1,title:"Upload",onClick:T},{default:Xe(()=>[Ce(_t,{name:"upload"})]),_:1}))])],64)):ge("",!0),i.value.length>0&&E(o).enableImagePaste.value===!0?($(),R("div",Wne,[Z("div",Zne,[($(!0),R(Je,null,Ot(i.value,(C,P)=>($(),R("div",{key:c.value[P],class:"pastedImage"},[l.value[P]?($(),Ie($0,{key:0,class:"imageSkeletonLoader"})):ge("",!0),!l.value[P]&&C?($(),R("img",{key:1,src:C,alt:"Pasted image"},null,8,Kne)):ge("",!0),Ce(wn,{class:"removeImage","aria-label":`Remove pasted image ${P+1}`,onClick:ae=>ee(P)},{default:Xe(()=>[Ce(_t,{name:"x"})]),_:2},1032,["aria-label","onClick"])]))),128))])])):ge("",!0),h.value?($(),R("div",{key:2,class:ft(["errorMessage",{"fade-out":f.value}])},[Ce(_t,{name:"alert-circle"}),Z("span",null,je(h.value),1)],2)):ge("",!0),Z("div",Gne,[Ce(_0,{modelValue:v.value,"onUpdate:modelValue":k[1]||(k[1]=C=>v.value=C),placeholder:E(o).placeholder.value,onKeydown:Sr(sn(Te,["exact","prevent"]),["enter"]),onPaste:Me},null,8,["modelValue","placeholder","onKeydown"])]),Z("div",Jne,[Ce(wn,{class:"send action",title:"Send message",onClick:Te},{default:Xe(()=>[Ce(_t,{name:"wds-send"})]),_:1}),E(o).enableFileUpload.value!="no"?($(),Ie(wn,{key:0,class:"action",title:"Attach files",onClick:Ze},{default:Xe(()=>[Ce(_t,{name:"paperclip"})]),_:1})):ge("",!0)])],512))}}),hm=e=>{e.writer&&(e.writer.docs="Connect it to an LLM by handling the `wf-chatbot-message` event, which is triggered every time the user sends a message.\n\nYou can add `actions` to messages, which are buttons that trigger the `wf-chatbot-action-click`.\n\nSee the stubs for more details.")};typeof hm=="function"&&hm($g);const are=ke($g,[["__scopeId","data-v-173a70b5"]]);var Eg={exports:{}};/**
8239
+ `.trim(),tre={writer:{name:"Chatbot",description:Xne,category:"Content",fields:{conversation:{name:"Conversation",init:"@{chat}",desc:"An array with messages or a variable that contains your conversation as an object.",type:Q.Object,validator:XE},assistantInitials:{name:"Assistant initials",default:"AI",type:Q.Text},userInitials:{name:"User initials",default:"YOU",type:Q.Text},useMarkdown:Ut({name:"Enable markdown",desc:"If active, the output will be sanitized; unsafe elements will be removed.",default:"no"}),enableFileUpload:{name:"Enable file upload",default:"no",type:Q.Text,options:{single:"Single file",multiple:"Multiple files",no:"No"}},enableImagePaste:Ut({name:"Enable image paste",desc:"Allow users to paste images directly into the chat input using Ctrl/Cmd+V.",default:"yes"}),placeholder:{name:"Placeholder",default:"What do you need?",type:Q.Text},assistantRoleColor:{name:"Assistant role",type:Q.Color,category:ot.Style,applyStyleVariable:!0},userRoleColor:{name:"User role",default:Ht.Gray1,type:Q.Color,category:ot.Style,applyStyleVariable:!0},avatarBackgroundColor:{name:"Avatar",default:Ht.Gray6,type:Q.Color,category:ot.Style,applyStyleVariable:!0},avatarTextColor:{name:"Avatar text",default:Ht.White,type:Q.Color,category:ot.Style,applyStyleVariable:!0},accentColor:Ia,containerBackgroundColor:Tr,primaryTextColor:ua,secondaryTextColor:In,separatorColor:wa,buttonColor:{...dr,default:Ht.Black},buttonTextColor:{...ur,default:Ht.White},cssClasses:mt},events:{"wf-chatbot-message":{desc:"Triggered when the user sends a message.",stub:Yne,eventPayloadExample:{role:"user",content:"I'm building a Chatbot"}},"wf-chatbot-action-click":{desc:"Handle clicks on actions.",stub:Qne},"wf-file-change":{desc:"Triggered when files are uploaded",stub:ere}}}},$g=$e({...tre,__name:"CoreChatbot",setup(e){const t=pt("rootEl"),a=pt("messageAreaEl"),n=pt("messagesEl"),r=ye(void 0),o=re(ne.evaluatedFields),s=fa(),i=$t([]),l=$t([]),c=$t([]);let d=0;const u=ye(!1),h=ye(null),f=ye(!1),m=ye(!1);let g,_;const b=H(()=>{var O;return((O=o.conversation)==null?void 0:O.value)??[]}),v=ye(""),y=H(()=>o.enableFileUpload.value==="multiple"),{files:M,calcTotalSize:x,addFiles:S,removeFile:L,clearFiles:F,encodeFiles:te}=Ag({multiple:y}),J=200*1024*1024,be=H(()=>x(M.value)>J),oe=H(()=>r.value===void 0?!1:r.value>=b.value.length);function Te(O){var ae;if(O&&"isComposing"in O&&O.isComposing||r.value)return;if(u.value){j("Images are still processing. Please wait a moment…");return}const k=(ae=v.value)==null?void 0:ae.trim();if(!k&&i.value.length===0)return;r.value=b.value.length+1;let C;if(i.value.length>0){const xe=[];v.value.trim()&&xe.push({type:"text",text:v.value}),i.value.filter(ve=>ve!==null).forEach(ve=>{xe.push({type:"image_url",image_url:{url:ve}})}),C={role:"user",content:xe}}else C={role:"user",content:k};const P=new CustomEvent("wf-chatbot-message",{detail:{payload:C,callback:()=>{r.value=void 0}}});t.value.dispatchEvent(P),v.value="",i.value=[],l.value=[],c.value=[]}function Ue(O){const{data:k}=O,C=new CustomEvent("wf-chatbot-action-click",{detail:{payload:k}});t.value.dispatchEvent(C)}function Ze(){const O=document.createElement("input");O.type="file",y.value&&(O.multiple=!0),O.addEventListener("change",()=>{S(Array.from(O.files||[]))}),O.click()}async function Me(O){var Ae;if(o.enableImagePaste.value!==!0)return;const k=(Ae=O.clipboardData)==null?void 0:Ae.items;if(!k)return;const C=10,P=50*1024*1024,ae=10*1024*1024,xe=["image/jpeg","image/jpg","image/png","image/webp"],ve=[];let ze=0,Ye=0,ct=0;for(let pe=0;pe<k.length;pe++){const ce=k[pe];if(ce.type.startsWith("image/")){if(!xe.includes(ce.type.toLowerCase())){ct++;continue}const ue=ce.getAsFile();if(ue){if(ue.size>ae){Ye++;continue}ze+=ue.size,ve.push(ue)}}}if(ve.length===0){ct>0&&Ye>0?j(`Images not added: ${ct} unsupported format(s) (only JPG, JPEG, PNG supported), ${Ye} too large (max ${ae/1024/1024}MB each).`):ct>0?j("Unsupported image format(s). Only JPG, JPEG, and PNG images are supported."):Ye>0&&j(`Image too large. Maximum size is ${ae/1024/1024}MB per image.`);return}if(i.value.length+ve.length>C){const pe=C-i.value.length;if(pe<=0){j(`Maximum ${C} images allowed. Please remove some images first.`);return}ve.splice(pe),j(`Only ${pe} image(s) added. Maximum ${C} images allowed.`)}if(ze>P){j(`Total size too large (${(ze/1024/1024).toFixed(1)}MB). Maximum ${P/1024/1024}MB total.`);return}const D=[];Ye>0&&D.push(`${Ye} image(s) too large (max ${ae/1024/1024}MB each)`),ct>0&&D.push(`${ct} unsupported format(s) (only JPG, JPEG, PNG supported)`),D.length>0&&j(`${D.join(", ")} - these images were skipped.`),O.preventDefault();const q=ve.map(()=>null),he=ve.map(()=>!0),me=ve.map(()=>`img-${d++}`);i.value=[...i.value,...q],l.value=[...l.value,...he],c.value=[...c.value,...me],u.value=!0;const _e=[];try{await Promise.all(ve.map(async(pe,ce)=>{try{const ue=await cne(pe,s);ue===pe&&pe.size>2*1024*1024?s.log(`Using original file for ${pe.name} (optimization failed)`):ue!==pe&&s.log(`Successfully optimized ${pe.name} from ${(pe.size/1024/1024).toFixed(2)}MB to ${(ue.size/1024/1024).toFixed(2)}MB`);const I=await G(ue),B=me[ce],N=c.value.findIndex(U=>U===B);if(N!==-1&&N<i.value.length){const U=[...i.value],se=[...l.value];U[N]=I,se[N]=!1,i.value=U,l.value=se}return I}catch(ue){return s.error("Failed to process pasted image:",ue),_e.push(ce),null}})),_e.map(pe=>({failureIndex:pe,imageId:me[pe]})).map(({imageId:pe})=>c.value.findIndex(ce=>ce===pe)).filter(pe=>pe!==-1).sort((pe,ce)=>ce-pe).forEach(pe=>{if(pe<i.value.length){const ce=[...i.value],ue=[...l.value],I=[...c.value];ce.splice(pe,1),ue.splice(pe,1),I.splice(pe,1),i.value=ce,l.value=ue,c.value=I}})}catch(pe){s.error("Error processing pasted images:",pe)}finally{u.value=!1}}function ee(O){const k=[...i.value],C=[...l.value],P=[...c.value];k.splice(O,1),C.splice(O,1),P.splice(O,1),i.value=k,l.value=C,c.value=P}function j(O){h.value=O,f.value=!1,_&&clearTimeout(_),_=setTimeout(()=>{f.value=!0,setTimeout(()=>{h.value=null,f.value=!1},300)},5e3)}function K(){a.value.scrollTo({top:a.value.scrollHeight,left:0})}const G=async O=>{const k=new FileReader;return k.readAsDataURL(O),new Promise((C,P)=>{k.onload=()=>C(k.result),k.onerror=()=>P(k.error)})};async function T(){if(M.value.length==0||m.value||be.value)return;m.value=!0;const{encodedFiles:O}=await te();if(O.length===0){m.value=!1;return}t.value.dispatchEvent(new CustomEvent("wf-file-change",{detail:{payload:O,callback:()=>{m.value=!1,F()}}}))}return ia(()=>{g=new ResizeObserver(()=>{K()}),g.observe(n.value)}),kr(()=>{g.unobserve(n.value),_&&(clearTimeout(_),_=void 0)}),(O,k)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreChatbot"},[Z("div",{ref_key:"messageAreaEl",ref:a,class:"messageArea"},[Z("div",{ref_key:"messagesEl",ref:n,class:"messages"},[($(!0),R(Je,null,Ot(b.value,(C,P)=>($(),Ie(dm,{key:P,message:C,"use-markdown":E(o).useMarkdown.value,"assistant-role-color":E(o).assistantRoleColor.value,initials:C.role==="assistant"?E(o).assistantInitials.value:E(o).userInitials.value,onActionClick:k[0]||(k[0]=ae=>Ue(ae))},null,8,["message","use-markdown","assistant-role-color","initials"]))),128)),oe.value?($(),Ie(dm,{key:0,"is-loading":"",initials:E(o).assistantInitials.value},null,8,["initials"])):ge("",!0)],512)],512),E(M).length>0?($(),R(Je,{key:0},[Z("div",Bne,[m.value?($(),R(Je,{key:0},[pa(" Uploading... ")],64)):($(),R("div",Fne,[($(!0),R(Je,null,Ot(E(M),C=>($(),R("div",{key:C.id,class:"file"},[Z("div",null,[Z("div",{class:"name",title:C.name},je(C.name),9,jne),Z("div",Une,je(E(fl)(C.size)),1)]),Ce(wn,{onClick:P=>E(L)(C.id)},{default:Xe(()=>[Ce(bt,{name:"trash-2"})]),_:2},1032,["onClick"])]))),128))]))]),Z("div",zne,[be.value?($(),R("div",qne,[Ce(bt,{name:"triangle-alert"}),Z("span",null," Size limit of "+je(E(fl)(J))+" exceeded. ",1)])):m.value?ge("",!0):($(),Ie(wn,{key:1,title:"Upload",onClick:T},{default:Xe(()=>[Ce(bt,{name:"upload"})]),_:1}))])],64)):ge("",!0),i.value.length>0&&E(o).enableImagePaste.value===!0?($(),R("div",Wne,[Z("div",Zne,[($(!0),R(Je,null,Ot(i.value,(C,P)=>($(),R("div",{key:c.value[P],class:"pastedImage"},[l.value[P]?($(),Ie($0,{key:0,class:"imageSkeletonLoader"})):ge("",!0),!l.value[P]&&C?($(),R("img",{key:1,src:C,alt:"Pasted image"},null,8,Kne)):ge("",!0),Ce(wn,{class:"removeImage","aria-label":`Remove pasted image ${P+1}`,onClick:ae=>ee(P)},{default:Xe(()=>[Ce(bt,{name:"x"})]),_:2},1032,["aria-label","onClick"])]))),128))])])):ge("",!0),h.value?($(),R("div",{key:2,class:ft(["errorMessage",{"fade-out":f.value}])},[Ce(bt,{name:"alert-circle"}),Z("span",null,je(h.value),1)],2)):ge("",!0),Z("div",Gne,[Ce(_0,{modelValue:v.value,"onUpdate:modelValue":k[1]||(k[1]=C=>v.value=C),placeholder:E(o).placeholder.value,onKeydown:$r(sn(Te,["exact","prevent"]),["enter"]),onPaste:Me},null,8,["modelValue","placeholder","onKeydown"])]),Z("div",Jne,[Ce(wn,{class:"send action",title:"Send message",onClick:Te},{default:Xe(()=>[Ce(bt,{name:"wds-send"})]),_:1}),E(o).enableFileUpload.value!="no"?($(),Ie(wn,{key:0,class:"action",title:"Attach files",onClick:Ze},{default:Xe(()=>[Ce(bt,{name:"paperclip"})]),_:1})):ge("",!0)])],512))}}),hm=e=>{e.writer&&(e.writer.docs="Connect it to an LLM by handling the `wf-chatbot-message` event, which is triggered every time the user sends a message.\n\nYou can add `actions` to messages, which are buttons that trigger the `wf-chatbot-action-click`.\n\nSee the stubs for more details.")};typeof hm=="function"&&hm($g);const are=ke($g,[["__scopeId","data-v-173a70b5"]]);var Eg={exports:{}};/**
8240
8240
  * chroma.js - JavaScript library for color conversions
8241
8241
  *
8242
8242
  * Copyright (c) 2011-2019, Gregor Aisch
@@ -8291,20 +8291,20 @@ def handle_file_upload(state, payload):
8291
8291
  * http://www.w3.org/TR/css3-color/#svg-color
8292
8292
  *
8293
8293
  * @preserve
8294
- */(function(e,t){(function(a,n){e.exports=n()})(Xx,function(){for(var a=function(p,w,A){return w===void 0&&(w=0),A===void 0&&(A=1),p<w?w:p>A?A:p},n=a,r=function(p){p._clipped=!1,p._unclipped=p.slice(0);for(var w=0;w<=3;w++)w<3?((p[w]<0||p[w]>255)&&(p._clipped=!0),p[w]=n(p[w],0,255)):w===3&&(p[w]=n(p[w],0,1));return p},o={},s=0,i=["Boolean","Number","String","Function","Array","Date","RegExp","Undefined","Null"];s<i.length;s+=1){var l=i[s];o["[object "+l+"]"]=l.toLowerCase()}var c=function(p){return o[Object.prototype.toString.call(p)]||"object"},d=c,u=function(p,w){return w===void 0&&(w=null),p.length>=3?Array.prototype.slice.call(p):d(p[0])=="object"&&w?w.split("").filter(function(A){return p[0][A]!==void 0}).map(function(A){return p[0][A]}):p[0]},h=c,f=function(p){if(p.length<2)return null;var w=p.length-1;return h(p[w])=="string"?p[w].toLowerCase():null},m=Math.PI,g={clip_rgb:r,limit:a,type:c,unpack:u,last:f,PI:m,TWOPI:m*2,PITHIRD:m/3,DEG2RAD:m/180,RAD2DEG:180/m},_={format:{},autodetect:[]},b=g.last,v=g.clip_rgb,y=g.type,M=_,x=function(){for(var w=[],A=arguments.length;A--;)w[A]=arguments[A];var V=this;if(y(w[0])==="object"&&w[0].constructor&&w[0].constructor===this.constructor)return w[0];var W=b(w),X=!1;if(!W){X=!0,M.sorted||(M.autodetect=M.autodetect.sort(function(He,Qe){return Qe.p-He.p}),M.sorted=!0);for(var z=0,le=M.autodetect;z<le.length;z+=1){var de=le[z];if(W=de.test.apply(de,w),W)break}}if(M.format[W]){var we=M.format[W].apply(null,X?w:w.slice(0,-1));V._rgb=v(we)}else throw new Error("unknown format: "+w);V._rgb.length===3&&V._rgb.push(1)};x.prototype.toString=function(){return y(this.hex)=="function"?this.hex():"["+this._rgb.join(",")+"]"};var S=x,L=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(L.Color,[null].concat(p)))};L.Color=S,L.version="2.4.2";var F=L,te=g.unpack,J=Math.max,be=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=te(p,"rgb"),V=A[0],W=A[1],X=A[2];V=V/255,W=W/255,X=X/255;var z=1-J(V,J(W,X)),le=z<1?1/(1-z):0,de=(1-V-z)*le,we=(1-W-z)*le,He=(1-X-z)*le;return[de,we,He,z]},oe=be,Te=g.unpack,Ue=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=Te(p,"cmyk");var A=p[0],V=p[1],W=p[2],X=p[3],z=p.length>4?p[4]:1;return X===1?[0,0,0,z]:[A>=1?0:255*(1-A)*(1-X),V>=1?0:255*(1-V)*(1-X),W>=1?0:255*(1-W)*(1-X),z]},Ze=Ue,Me=F,ee=S,j=_,K=g.unpack,G=g.type,T=oe;ee.prototype.cmyk=function(){return T(this._rgb)},Me.cmyk=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(ee,[null].concat(p,["cmyk"])))},j.format.cmyk=Ze,j.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=K(p,"cmyk"),G(p)==="array"&&p.length===4)return"cmyk"}});var O=g.unpack,k=g.last,C=function(p){return Math.round(p*100)/100},P=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=O(p,"hsla"),V=k(p)||"lsa";return A[0]=C(A[0]||0),A[1]=C(A[1]*100)+"%",A[2]=C(A[2]*100)+"%",V==="hsla"||A.length>3&&A[3]<1?(A[3]=A.length>3?A[3]:1,V="hsla"):A.length=3,V+"("+A.join(",")+")"},ae=P,xe=g.unpack,ve=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=xe(p,"rgba");var A=p[0],V=p[1],W=p[2];A/=255,V/=255,W/=255;var X=Math.min(A,V,W),z=Math.max(A,V,W),le=(z+X)/2,de,we;return z===X?(de=0,we=Number.NaN):de=le<.5?(z-X)/(z+X):(z-X)/(2-z-X),A==z?we=(V-W)/(z-X):V==z?we=2+(W-A)/(z-X):W==z&&(we=4+(A-V)/(z-X)),we*=60,we<0&&(we+=360),p.length>3&&p[3]!==void 0?[we,de,le,p[3]]:[we,de,le]},ze=ve,Ye=g.unpack,ct=g.last,wt=ae,D=ze,q=Math.round,he=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Ye(p,"rgba"),V=ct(p)||"rgb";return V.substr(0,3)=="hsl"?wt(D(A),V):(A[0]=q(A[0]),A[1]=q(A[1]),A[2]=q(A[2]),(V==="rgba"||A.length>3&&A[3]<1)&&(A[3]=A.length>3?A[3]:1,V="rgba"),V+"("+A.slice(0,V==="rgb"?3:4).join(",")+")")},me=he,_e=g.unpack,Ae=Math.round,pe=function(){for(var p,w=[],A=arguments.length;A--;)w[A]=arguments[A];w=_e(w,"hsl");var V=w[0],W=w[1],X=w[2],z,le,de;if(W===0)z=le=de=X*255;else{var we=[0,0,0],He=[0,0,0],Qe=X<.5?X*(1+W):X+W-X*W,De=2*X-Qe,nt=V/360;we[0]=nt+1/3,we[1]=nt,we[2]=nt-1/3;for(var tt=0;tt<3;tt++)we[tt]<0&&(we[tt]+=1),we[tt]>1&&(we[tt]-=1),6*we[tt]<1?He[tt]=De+(Qe-De)*6*we[tt]:2*we[tt]<1?He[tt]=Qe:3*we[tt]<2?He[tt]=De+(Qe-De)*(2/3-we[tt])*6:He[tt]=De;p=[Ae(He[0]*255),Ae(He[1]*255),Ae(He[2]*255)],z=p[0],le=p[1],de=p[2]}return w.length>3?[z,le,de,w[3]]:[z,le,de,1]},ce=pe,ue=ce,I=_,B=/^rgb\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*\)$/,N=/^rgba\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*,\s*([01]|[01]?\.\d+)\)$/,U=/^rgb\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,se=/^rgba\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,Se=/^hsl\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,Ne=/^hsla\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,ut=Math.round,ie=function(p){p=p.toLowerCase().trim();var w;if(I.format.named)try{return I.format.named(p)}catch{}if(w=p.match(B)){for(var A=w.slice(1,4),V=0;V<3;V++)A[V]=+A[V];return A[3]=1,A}if(w=p.match(N)){for(var W=w.slice(1,5),X=0;X<4;X++)W[X]=+W[X];return W}if(w=p.match(U)){for(var z=w.slice(1,4),le=0;le<3;le++)z[le]=ut(z[le]*2.55);return z[3]=1,z}if(w=p.match(se)){for(var de=w.slice(1,5),we=0;we<3;we++)de[we]=ut(de[we]*2.55);return de[3]=+de[3],de}if(w=p.match(Se)){var He=w.slice(1,4);He[1]*=.01,He[2]*=.01;var Qe=ue(He);return Qe[3]=1,Qe}if(w=p.match(Ne)){var De=w.slice(1,4);De[1]*=.01,De[2]*=.01;var nt=ue(De);return nt[3]=+w[4],nt}};ie.test=function(p){return B.test(p)||N.test(p)||U.test(p)||se.test(p)||Se.test(p)||Ne.test(p)};var Ee=ie,Oe=F,Pe=S,Ke=_,it=g.type,ht=me,Ft=Ee;Pe.prototype.css=function(p){return ht(this._rgb,p)},Oe.css=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Pe,[null].concat(p,["css"])))},Ke.format.css=Ft,Ke.autodetect.push({p:5,test:function(p){for(var w=[],A=arguments.length-1;A-- >0;)w[A]=arguments[A+1];if(!w.length&&it(p)==="string"&&Ft.test(p))return"css"}});var ma=S,Wt=F,ln=_,Pr=g.unpack;ln.format.gl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Pr(p,"rgba");return A[0]*=255,A[1]*=255,A[2]*=255,A},Wt.gl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(ma,[null].concat(p,["gl"])))},ma.prototype.gl=function(){var p=this._rgb;return[p[0]/255,p[1]/255,p[2]/255,p[3]]};var kn=g.unpack,lo=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=kn(p,"rgb"),V=A[0],W=A[1],X=A[2],z=Math.min(V,W,X),le=Math.max(V,W,X),de=le-z,we=de*100/255,He=z/(255-de)*100,Qe;return de===0?Qe=Number.NaN:(V===le&&(Qe=(W-X)/de),W===le&&(Qe=2+(X-V)/de),X===le&&(Qe=4+(V-W)/de),Qe*=60,Qe<0&&(Qe+=360)),[Qe,we,He]},Ro=lo,No=g.unpack,Do=Math.floor,Bo=function(){for(var p,w,A,V,W,X,z=[],le=arguments.length;le--;)z[le]=arguments[le];z=No(z,"hcg");var de=z[0],we=z[1],He=z[2],Qe,De,nt;He=He*255;var tt=we*255;if(we===0)Qe=De=nt=He;else{de===360&&(de=0),de>360&&(de-=360),de<0&&(de+=360),de/=60;var Et=Do(de),Lt=de-Et,Dt=He*(1-we),Zt=Dt+tt*(1-Lt),Oa=Dt+tt*Lt,Ta=Dt+tt;switch(Et){case 0:p=[Ta,Oa,Dt],Qe=p[0],De=p[1],nt=p[2];break;case 1:w=[Zt,Ta,Dt],Qe=w[0],De=w[1],nt=w[2];break;case 2:A=[Dt,Ta,Oa],Qe=A[0],De=A[1],nt=A[2];break;case 3:V=[Dt,Zt,Ta],Qe=V[0],De=V[1],nt=V[2];break;case 4:W=[Oa,Dt,Ta],Qe=W[0],De=W[1],nt=W[2];break;case 5:X=[Ta,Dt,Zt],Qe=X[0],De=X[1],nt=X[2];break}}return[Qe,De,nt,z.length>3?z[3]:1]},Fo=Bo,ur=g.unpack,fe=g.type,Le=F,Re=S,Ve=_,Ge=Ro;Re.prototype.hcg=function(){return Ge(this._rgb)},Le.hcg=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Re,[null].concat(p,["hcg"])))},Ve.format.hcg=Fo,Ve.autodetect.push({p:1,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=ur(p,"hcg"),fe(p)==="array"&&p.length===3)return"hcg"}});var dt=g.unpack,rt=g.last,Mt=Math.round,At=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=dt(p,"rgba"),V=A[0],W=A[1],X=A[2],z=A[3],le=rt(p)||"auto";z===void 0&&(z=1),le==="auto"&&(le=z<1?"rgba":"rgb"),V=Mt(V),W=Mt(W),X=Mt(X);var de=V<<16|W<<8|X,we="000000"+de.toString(16);we=we.substr(we.length-6);var He="0"+Mt(z*255).toString(16);switch(He=He.substr(He.length-2),le.toLowerCase()){case"rgba":return"#"+we+He;case"argb":return"#"+He+we;default:return"#"+we}},Yt=At,la=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,ca=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,qe=function(p){if(p.match(la)){(p.length===4||p.length===7)&&(p=p.substr(1)),p.length===3&&(p=p.split(""),p=p[0]+p[0]+p[1]+p[1]+p[2]+p[2]);var w=parseInt(p,16),A=w>>16,V=w>>8&255,W=w&255;return[A,V,W,1]}if(p.match(ca)){(p.length===5||p.length===9)&&(p=p.substr(1)),p.length===4&&(p=p.split(""),p=p[0]+p[0]+p[1]+p[1]+p[2]+p[2]+p[3]+p[3]);var X=parseInt(p,16),z=X>>24&255,le=X>>16&255,de=X>>8&255,we=Math.round((X&255)/255*100)/100;return[z,le,de,we]}throw new Error("unknown hex color: "+p)},Y=qe,Fe=F,at=S,Gt=g.type,ha=_,va=Yt;at.prototype.hex=function(p){return va(this._rgb,p)},Fe.hex=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(at,[null].concat(p,["hex"])))},ha.format.hex=Y,ha.autodetect.push({p:4,test:function(p){for(var w=[],A=arguments.length-1;A-- >0;)w[A]=arguments[A+1];if(!w.length&&Gt(p)==="string"&&[3,4,5,6,7,8,9].indexOf(p.length)>=0)return"hex"}});var ya=g.unpack,Kn=g.TWOPI,co=Math.min,Ba=Math.sqrt,Ji=Math.acos,Xi=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=ya(p,"rgb"),V=A[0],W=A[1],X=A[2];V/=255,W/=255,X/=255;var z,le=co(V,W,X),de=(V+W+X)/3,we=de>0?1-le/de:0;return we===0?z=NaN:(z=(V-W+(V-X))/2,z/=Ba((V-W)*(V-W)+(V-X)*(W-X)),z=Ji(z),X>W&&(z=Kn-z),z/=Kn),[z*360,we,de]},d8=Xi,u8=g.unpack,Gl=g.limit,jo=g.TWOPI,Jl=g.PITHIRD,Uo=Math.cos,h8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=u8(p,"hsi");var A=p[0],V=p[1],W=p[2],X,z,le;return isNaN(A)&&(A=0),isNaN(V)&&(V=0),A>360&&(A-=360),A<0&&(A+=360),A/=360,A<1/3?(le=(1-V)/3,X=(1+V*Uo(jo*A)/Uo(Jl-jo*A))/3,z=1-(le+X)):A<2/3?(A-=1/3,X=(1-V)/3,z=(1+V*Uo(jo*A)/Uo(Jl-jo*A))/3,le=1-(X+z)):(A-=2/3,z=(1-V)/3,le=(1+V*Uo(jo*A)/Uo(Jl-jo*A))/3,X=1-(z+le)),X=Gl(W*X*3),z=Gl(W*z*3),le=Gl(W*le*3),[X*255,z*255,le*255,p.length>3?p[3]:1]},p8=h8,f8=g.unpack,m8=g.type,v8=F,Dd=S,Bd=_,g8=d8;Dd.prototype.hsi=function(){return g8(this._rgb)},v8.hsi=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Dd,[null].concat(p,["hsi"])))},Bd.format.hsi=p8,Bd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=f8(p,"hsi"),m8(p)==="array"&&p.length===3)return"hsi"}});var y8=g.unpack,M8=g.type,_8=F,Fd=S,jd=_,b8=ze;Fd.prototype.hsl=function(){return b8(this._rgb)},_8.hsl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Fd,[null].concat(p,["hsl"])))},jd.format.hsl=ce,jd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=y8(p,"hsl"),M8(p)==="array"&&p.length===3)return"hsl"}});var w8=g.unpack,x8=Math.min,C8=Math.max,A8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=w8(p,"rgb");var A=p[0],V=p[1],W=p[2],X=x8(A,V,W),z=C8(A,V,W),le=z-X,de,we,He;return He=z/255,z===0?(de=Number.NaN,we=0):(we=le/z,A===z&&(de=(V-W)/le),V===z&&(de=2+(W-A)/le),W===z&&(de=4+(A-V)/le),de*=60,de<0&&(de+=360)),[de,we,He]},S8=A8,$8=g.unpack,E8=Math.floor,I8=function(){for(var p,w,A,V,W,X,z=[],le=arguments.length;le--;)z[le]=arguments[le];z=$8(z,"hsv");var de=z[0],we=z[1],He=z[2],Qe,De,nt;if(He*=255,we===0)Qe=De=nt=He;else{de===360&&(de=0),de>360&&(de-=360),de<0&&(de+=360),de/=60;var tt=E8(de),Et=de-tt,Lt=He*(1-we),Dt=He*(1-we*Et),Zt=He*(1-we*(1-Et));switch(tt){case 0:p=[He,Zt,Lt],Qe=p[0],De=p[1],nt=p[2];break;case 1:w=[Dt,He,Lt],Qe=w[0],De=w[1],nt=w[2];break;case 2:A=[Lt,He,Zt],Qe=A[0],De=A[1],nt=A[2];break;case 3:V=[Lt,Dt,He],Qe=V[0],De=V[1],nt=V[2];break;case 4:W=[Zt,Lt,He],Qe=W[0],De=W[1],nt=W[2];break;case 5:X=[He,Lt,Dt],Qe=X[0],De=X[1],nt=X[2];break}}return[Qe,De,nt,z.length>3?z[3]:1]},k8=I8,T8=g.unpack,P8=g.type,L8=F,Ud=S,zd=_,V8=S8;Ud.prototype.hsv=function(){return V8(this._rgb)},L8.hsv=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Ud,[null].concat(p,["hsv"])))},zd.format.hsv=k8,zd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=T8(p,"hsv"),P8(p)==="array"&&p.length===3)return"hsv"}});var Yi={Kn:18,Xn:.95047,Yn:1,Zn:1.08883,t0:.137931034,t1:.206896552,t2:.12841855,t3:.008856452},zo=Yi,O8=g.unpack,qd=Math.pow,H8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=O8(p,"rgb"),V=A[0],W=A[1],X=A[2],z=R8(V,W,X),le=z[0],de=z[1],we=z[2],He=116*de-16;return[He<0?0:He,500*(le-de),200*(de-we)]},Xl=function(p){return(p/=255)<=.04045?p/12.92:qd((p+.055)/1.055,2.4)},Yl=function(p){return p>zo.t3?qd(p,1/3):p/zo.t2+zo.t0},R8=function(p,w,A){p=Xl(p),w=Xl(w),A=Xl(A);var V=Yl((.4124564*p+.3575761*w+.1804375*A)/zo.Xn),W=Yl((.2126729*p+.7151522*w+.072175*A)/zo.Yn),X=Yl((.0193339*p+.119192*w+.9503041*A)/zo.Zn);return[V,W,X]},Wd=H8,qo=Yi,N8=g.unpack,D8=Math.pow,B8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=N8(p,"lab");var A=p[0],V=p[1],W=p[2],X,z,le,de,we,He;return z=(A+16)/116,X=isNaN(V)?z:z+V/500,le=isNaN(W)?z:z-W/200,z=qo.Yn*e2(z),X=qo.Xn*e2(X),le=qo.Zn*e2(le),de=Ql(3.2404542*X-1.5371385*z-.4985314*le),we=Ql(-.969266*X+1.8760108*z+.041556*le),He=Ql(.0556434*X-.2040259*z+1.0572252*le),[de,we,He,p.length>3?p[3]:1]},Ql=function(p){return 255*(p<=.00304?12.92*p:1.055*D8(p,1/2.4)-.055)},e2=function(p){return p>qo.t1?p*p*p:qo.t2*(p-qo.t0)},Zd=B8,F8=g.unpack,j8=g.type,U8=F,Kd=S,Gd=_,z8=Wd;Kd.prototype.lab=function(){return z8(this._rgb)},U8.lab=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Kd,[null].concat(p,["lab"])))},Gd.format.lab=Zd,Gd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=F8(p,"lab"),j8(p)==="array"&&p.length===3)return"lab"}});var q8=g.unpack,W8=g.RAD2DEG,Z8=Math.sqrt,K8=Math.atan2,G8=Math.round,J8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=q8(p,"lab"),V=A[0],W=A[1],X=A[2],z=Z8(W*W+X*X),le=(K8(X,W)*W8+360)%360;return G8(z*1e4)===0&&(le=Number.NaN),[V,z,le]},Jd=J8,X8=g.unpack,Y8=Wd,Q8=Jd,ey=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=X8(p,"rgb"),V=A[0],W=A[1],X=A[2],z=Y8(V,W,X),le=z[0],de=z[1],we=z[2];return Q8(le,de,we)},ty=ey,ay=g.unpack,ny=g.DEG2RAD,ry=Math.sin,oy=Math.cos,sy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=ay(p,"lch"),V=A[0],W=A[1],X=A[2];return isNaN(X)&&(X=0),X=X*ny,[V,oy(X)*W,ry(X)*W]},Xd=sy,iy=g.unpack,ly=Xd,cy=Zd,dy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=iy(p,"lch");var A=p[0],V=p[1],W=p[2],X=ly(A,V,W),z=X[0],le=X[1],de=X[2],we=cy(z,le,de),He=we[0],Qe=we[1],De=we[2];return[He,Qe,De,p.length>3?p[3]:1]},Yd=dy,uy=g.unpack,hy=Yd,py=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=uy(p,"hcl").reverse();return hy.apply(void 0,A)},fy=py,my=g.unpack,vy=g.type,Qd=F,Qi=S,t2=_,eu=ty;Qi.prototype.lch=function(){return eu(this._rgb)},Qi.prototype.hcl=function(){return eu(this._rgb).reverse()},Qd.lch=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Qi,[null].concat(p,["lch"])))},Qd.hcl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Qi,[null].concat(p,["hcl"])))},t2.format.lch=Yd,t2.format.hcl=fy,["lch","hcl"].forEach(function(p){return t2.autodetect.push({p:2,test:function(){for(var w=[],A=arguments.length;A--;)w[A]=arguments[A];if(w=my(w,p),vy(w)==="array"&&w.length===3)return p}})});var gy={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflower:"#6495ed",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",laserlemon:"#ffff54",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrod:"#fafad2",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",maroon2:"#7f0000",maroon3:"#b03060",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",purple2:"#7f007f",purple3:"#a020f0",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},tu=gy,yy=S,au=_,My=g.type,js=tu,_y=Y,by=Yt;yy.prototype.name=function(){for(var p=by(this._rgb,"rgb"),w=0,A=Object.keys(js);w<A.length;w+=1){var V=A[w];if(js[V]===p)return V.toLowerCase()}return p},au.format.named=function(p){if(p=p.toLowerCase(),js[p])return _y(js[p]);throw new Error("unknown color name: "+p)},au.autodetect.push({p:5,test:function(p){for(var w=[],A=arguments.length-1;A-- >0;)w[A]=arguments[A+1];if(!w.length&&My(p)==="string"&&js[p.toLowerCase()])return"named"}});var wy=g.unpack,xy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=wy(p,"rgb"),V=A[0],W=A[1],X=A[2];return(V<<16)+(W<<8)+X},Cy=xy,Ay=g.type,Sy=function(p){if(Ay(p)=="number"&&p>=0&&p<=16777215){var w=p>>16,A=p>>8&255,V=p&255;return[w,A,V,1]}throw new Error("unknown num color: "+p)},$y=Sy,Ey=F,nu=S,ru=_,Iy=g.type,ky=Cy;nu.prototype.num=function(){return ky(this._rgb)},Ey.num=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(nu,[null].concat(p,["num"])))},ru.format.num=$y,ru.autodetect.push({p:5,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p.length===1&&Iy(p[0])==="number"&&p[0]>=0&&p[0]<=16777215)return"num"}});var Ty=F,a2=S,ou=_,su=g.unpack,iu=g.type,lu=Math.round;a2.prototype.rgb=function(p){return p===void 0&&(p=!0),p===!1?this._rgb.slice(0,3):this._rgb.slice(0,3).map(lu)},a2.prototype.rgba=function(p){return p===void 0&&(p=!0),this._rgb.slice(0,4).map(function(w,A){return A<3?p===!1?w:lu(w):w})},Ty.rgb=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(a2,[null].concat(p,["rgb"])))},ou.format.rgb=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=su(p,"rgba");return A[3]===void 0&&(A[3]=1),A},ou.autodetect.push({p:3,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=su(p,"rgba"),iu(p)==="array"&&(p.length===3||p.length===4&&iu(p[3])=="number"&&p[3]>=0&&p[3]<=1))return"rgb"}});var e1=Math.log,Py=function(p){var w=p/100,A,V,W;return w<66?(A=255,V=w<6?0:-155.25485562709179-.44596950469579133*(V=w-2)+104.49216199393888*e1(V),W=w<20?0:-254.76935184120902+.8274096064007395*(W=w-10)+115.67994401066147*e1(W)):(A=351.97690566805693+.114206453784165*(A=w-55)-40.25366309332127*e1(A),V=325.4494125711974+.07943456536662342*(V=w-50)-28.0852963507957*e1(V),W=255),[A,V,W,1]},cu=Py,Ly=cu,Vy=g.unpack,Oy=Math.round,Hy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];for(var A=Vy(p,"rgb"),V=A[0],W=A[2],X=1e3,z=4e4,le=.4,de;z-X>le;){de=(z+X)*.5;var we=Ly(de);we[2]/we[0]>=W/V?z=de:X=de}return Oy(de)},Ry=Hy,n2=F,t1=S,r2=_,Ny=Ry;t1.prototype.temp=t1.prototype.kelvin=t1.prototype.temperature=function(){return Ny(this._rgb)},n2.temp=n2.kelvin=n2.temperature=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(t1,[null].concat(p,["temp"])))},r2.format.temp=r2.format.kelvin=r2.format.temperature=cu;var Dy=g.unpack,o2=Math.cbrt,By=Math.pow,Fy=Math.sign,jy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Dy(p,"rgb"),V=A[0],W=A[1],X=A[2],z=[s2(V/255),s2(W/255),s2(X/255)],le=z[0],de=z[1],we=z[2],He=o2(.4122214708*le+.5363325363*de+.0514459929*we),Qe=o2(.2119034982*le+.6806995451*de+.1073969566*we),De=o2(.0883024619*le+.2817188376*de+.6299787005*we);return[.2104542553*He+.793617785*Qe-.0040720468*De,1.9779984951*He-2.428592205*Qe+.4505937099*De,.0259040371*He+.7827717662*Qe-.808675766*De]},du=jy;function s2(p){var w=Math.abs(p);return w<.04045?p/12.92:(Fy(p)||1)*By((w+.055)/1.055,2.4)}var Uy=g.unpack,a1=Math.pow,zy=Math.sign,qy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=Uy(p,"lab");var A=p[0],V=p[1],W=p[2],X=a1(A+.3963377774*V+.2158037573*W,3),z=a1(A-.1055613458*V-.0638541728*W,3),le=a1(A-.0894841775*V-1.291485548*W,3);return[255*i2(4.0767416621*X-3.3077115913*z+.2309699292*le),255*i2(-1.2684380046*X+2.6097574011*z-.3413193965*le),255*i2(-.0041960863*X-.7034186147*z+1.707614701*le),p.length>3?p[3]:1]},uu=qy;function i2(p){var w=Math.abs(p);return w>.0031308?(zy(p)||1)*(1.055*a1(w,1/2.4)-.055):p*12.92}var Wy=g.unpack,Zy=g.type,Ky=F,hu=S,pu=_,Gy=du;hu.prototype.oklab=function(){return Gy(this._rgb)},Ky.oklab=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(hu,[null].concat(p,["oklab"])))},pu.format.oklab=uu,pu.autodetect.push({p:3,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=Wy(p,"oklab"),Zy(p)==="array"&&p.length===3)return"oklab"}});var Jy=g.unpack,Xy=du,Yy=Jd,Qy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Jy(p,"rgb"),V=A[0],W=A[1],X=A[2],z=Xy(V,W,X),le=z[0],de=z[1],we=z[2];return Yy(le,de,we)},e7=Qy,t7=g.unpack,a7=Xd,n7=uu,r7=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=t7(p,"lch");var A=p[0],V=p[1],W=p[2],X=a7(A,V,W),z=X[0],le=X[1],de=X[2],we=n7(z,le,de),He=we[0],Qe=we[1],De=we[2];return[He,Qe,De,p.length>3?p[3]:1]},o7=r7,s7=g.unpack,i7=g.type,l7=F,fu=S,mu=_,c7=e7;fu.prototype.oklch=function(){return c7(this._rgb)},l7.oklch=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(fu,[null].concat(p,["oklch"])))},mu.format.oklch=o7,mu.autodetect.push({p:3,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=s7(p,"oklch"),i7(p)==="array"&&p.length===3)return"oklch"}});var vu=S,d7=g.type;vu.prototype.alpha=function(p,w){return w===void 0&&(w=!1),p!==void 0&&d7(p)==="number"?w?(this._rgb[3]=p,this):new vu([this._rgb[0],this._rgb[1],this._rgb[2],p],"rgb"):this._rgb[3]};var u7=S;u7.prototype.clipped=function(){return this._rgb._clipped||!1};var uo=S,h7=Yi;uo.prototype.darken=function(p){p===void 0&&(p=1);var w=this,A=w.lab();return A[0]-=h7.Kn*p,new uo(A,"lab").alpha(w.alpha(),!0)},uo.prototype.brighten=function(p){return p===void 0&&(p=1),this.darken(-p)},uo.prototype.darker=uo.prototype.darken,uo.prototype.brighter=uo.prototype.brighten;var p7=S;p7.prototype.get=function(p){var w=p.split("."),A=w[0],V=w[1],W=this[A]();if(V){var X=A.indexOf(V)-(A.substr(0,2)==="ok"?2:0);if(X>-1)return W[X];throw new Error("unknown channel "+V+" in mode "+A)}else return W};var Wo=S,f7=g.type,m7=Math.pow,v7=1e-7,g7=20;Wo.prototype.luminance=function(p){if(p!==void 0&&f7(p)==="number"){if(p===0)return new Wo([0,0,0,this._rgb[3]],"rgb");if(p===1)return new Wo([255,255,255,this._rgb[3]],"rgb");var w=this.luminance(),A="rgb",V=g7,W=function(z,le){var de=z.interpolate(le,.5,A),we=de.luminance();return Math.abs(p-we)<v7||!V--?de:we>p?W(z,de):W(de,le)},X=(w>p?W(new Wo([0,0,0]),this):W(this,new Wo([255,255,255]))).rgb();return new Wo(X.concat([this._rgb[3]]))}return y7.apply(void 0,this._rgb.slice(0,3))};var y7=function(p,w,A){return p=l2(p),w=l2(w),A=l2(A),.2126*p+.7152*w+.0722*A},l2=function(p){return p/=255,p<=.03928?p/12.92:m7((p+.055)/1.055,2.4)},cn={},gu=S,yu=g.type,n1=cn,Mu=function(p,w,A){A===void 0&&(A=.5);for(var V=[],W=arguments.length-3;W-- >0;)V[W]=arguments[W+3];var X=V[0]||"lrgb";if(!n1[X]&&!V.length&&(X=Object.keys(n1)[0]),!n1[X])throw new Error("interpolation mode "+X+" is not defined");return yu(p)!=="object"&&(p=new gu(p)),yu(w)!=="object"&&(w=new gu(w)),n1[X](p,w,A).alpha(p.alpha()+A*(w.alpha()-p.alpha()))},_u=S,M7=Mu;_u.prototype.mix=_u.prototype.interpolate=function(p,w){w===void 0&&(w=.5);for(var A=[],V=arguments.length-2;V-- >0;)A[V]=arguments[V+2];return M7.apply(void 0,[this,p,w].concat(A))};var bu=S;bu.prototype.premultiply=function(p){p===void 0&&(p=!1);var w=this._rgb,A=w[3];return p?(this._rgb=[w[0]*A,w[1]*A,w[2]*A,A],this):new bu([w[0]*A,w[1]*A,w[2]*A,A],"rgb")};var c2=S,_7=Yi;c2.prototype.saturate=function(p){p===void 0&&(p=1);var w=this,A=w.lch();return A[1]+=_7.Kn*p,A[1]<0&&(A[1]=0),new c2(A,"lch").alpha(w.alpha(),!0)},c2.prototype.desaturate=function(p){return p===void 0&&(p=1),this.saturate(-p)};var wu=S,xu=g.type;wu.prototype.set=function(p,w,A){A===void 0&&(A=!1);var V=p.split("."),W=V[0],X=V[1],z=this[W]();if(X){var le=W.indexOf(X)-(W.substr(0,2)==="ok"?2:0);if(le>-1){if(xu(w)=="string")switch(w.charAt(0)){case"+":z[le]+=+w;break;case"-":z[le]+=+w;break;case"*":z[le]*=+w.substr(1);break;case"/":z[le]/=+w.substr(1);break;default:z[le]=+w}else if(xu(w)==="number")z[le]=w;else throw new Error("unsupported value for Color.set");var de=new wu(z,W);return A?(this._rgb=de._rgb,this):de}throw new Error("unknown channel "+X+" in mode "+W)}else return z};var b7=S,w7=function(p,w,A){var V=p._rgb,W=w._rgb;return new b7(V[0]+A*(W[0]-V[0]),V[1]+A*(W[1]-V[1]),V[2]+A*(W[2]-V[2]),"rgb")};cn.rgb=w7;var x7=S,d2=Math.sqrt,Zo=Math.pow,C7=function(p,w,A){var V=p._rgb,W=V[0],X=V[1],z=V[2],le=w._rgb,de=le[0],we=le[1],He=le[2];return new x7(d2(Zo(W,2)*(1-A)+Zo(de,2)*A),d2(Zo(X,2)*(1-A)+Zo(we,2)*A),d2(Zo(z,2)*(1-A)+Zo(He,2)*A),"rgb")};cn.lrgb=C7;var A7=S,S7=function(p,w,A){var V=p.lab(),W=w.lab();return new A7(V[0]+A*(W[0]-V[0]),V[1]+A*(W[1]-V[1]),V[2]+A*(W[2]-V[2]),"lab")};cn.lab=S7;var Cu=S,Ko=function(p,w,A,V){var W,X,z,le;V==="hsl"?(z=p.hsl(),le=w.hsl()):V==="hsv"?(z=p.hsv(),le=w.hsv()):V==="hcg"?(z=p.hcg(),le=w.hcg()):V==="hsi"?(z=p.hsi(),le=w.hsi()):V==="lch"||V==="hcl"?(V="hcl",z=p.hcl(),le=w.hcl()):V==="oklch"&&(z=p.oklch().reverse(),le=w.oklch().reverse());var de,we,He,Qe,De,nt;(V.substr(0,1)==="h"||V==="oklch")&&(W=z,de=W[0],He=W[1],De=W[2],X=le,we=X[0],Qe=X[1],nt=X[2]);var tt,Et,Lt,Dt;return!isNaN(de)&&!isNaN(we)?(we>de&&we-de>180?Dt=we-(de+360):we<de&&de-we>180?Dt=we+360-de:Dt=we-de,Et=de+A*Dt):isNaN(de)?isNaN(we)?Et=Number.NaN:(Et=we,(De==1||De==0)&&V!="hsv"&&(tt=Qe)):(Et=de,(nt==1||nt==0)&&V!="hsv"&&(tt=He)),tt===void 0&&(tt=He+A*(Qe-He)),Lt=De+A*(nt-De),V==="oklch"?new Cu([Lt,tt,Et],V):new Cu([Et,tt,Lt],V)},$7=Ko,Au=function(p,w,A){return $7(p,w,A,"lch")};cn.lch=Au,cn.hcl=Au;var E7=S,I7=function(p,w,A){var V=p.num(),W=w.num();return new E7(V+A*(W-V),"num")};cn.num=I7;var k7=Ko,T7=function(p,w,A){return k7(p,w,A,"hcg")};cn.hcg=T7;var P7=Ko,L7=function(p,w,A){return P7(p,w,A,"hsi")};cn.hsi=L7;var V7=Ko,O7=function(p,w,A){return V7(p,w,A,"hsl")};cn.hsl=O7;var H7=Ko,R7=function(p,w,A){return H7(p,w,A,"hsv")};cn.hsv=R7;var N7=S,D7=function(p,w,A){var V=p.oklab(),W=w.oklab();return new N7(V[0]+A*(W[0]-V[0]),V[1]+A*(W[1]-V[1]),V[2]+A*(W[2]-V[2]),"oklab")};cn.oklab=D7;var B7=Ko,F7=function(p,w,A){return B7(p,w,A,"oklch")};cn.oklch=F7;var u2=S,j7=g.clip_rgb,h2=Math.pow,p2=Math.sqrt,f2=Math.PI,Su=Math.cos,$u=Math.sin,U7=Math.atan2,z7=function(p,w,A){w===void 0&&(w="lrgb"),A===void 0&&(A=null);var V=p.length;A||(A=Array.from(new Array(V)).map(function(){return 1}));var W=V/A.reduce(function(Et,Lt){return Et+Lt});if(A.forEach(function(Et,Lt){A[Lt]*=W}),p=p.map(function(Et){return new u2(Et)}),w==="lrgb")return q7(p,A);for(var X=p.shift(),z=X.get(w),le=[],de=0,we=0,He=0;He<z.length;He++)if(z[He]=(z[He]||0)*A[0],le.push(isNaN(z[He])?0:A[0]),w.charAt(He)==="h"&&!isNaN(z[He])){var Qe=z[He]/180*f2;de+=Su(Qe)*A[0],we+=$u(Qe)*A[0]}var De=X.alpha()*A[0];p.forEach(function(Et,Lt){var Dt=Et.get(w);De+=Et.alpha()*A[Lt+1];for(var Zt=0;Zt<z.length;Zt++)if(!isNaN(Dt[Zt]))if(le[Zt]+=A[Lt+1],w.charAt(Zt)==="h"){var Oa=Dt[Zt]/180*f2;de+=Su(Oa)*A[Lt+1],we+=$u(Oa)*A[Lt+1]}else z[Zt]+=Dt[Zt]*A[Lt+1]});for(var nt=0;nt<z.length;nt++)if(w.charAt(nt)==="h"){for(var tt=U7(we/le[nt],de/le[nt])/f2*180;tt<0;)tt+=360;for(;tt>=360;)tt-=360;z[nt]=tt}else z[nt]=z[nt]/le[nt];return De/=V,new u2(z,w).alpha(De>.99999?1:De,!0)},q7=function(p,w){for(var A=p.length,V=[0,0,0,0],W=0;W<p.length;W++){var X=p[W],z=w[W]/A,le=X._rgb;V[0]+=h2(le[0],2)*z,V[1]+=h2(le[1],2)*z,V[2]+=h2(le[2],2)*z,V[3]+=le[3]*z}return V[0]=p2(V[0]),V[1]=p2(V[1]),V[2]=p2(V[2]),V[3]>.9999999&&(V[3]=1),new u2(j7(V))},Tn=F,Go=g.type,W7=Math.pow,m2=function(p){var w="rgb",A=Tn("#ccc"),V=0,W=[0,1],X=[],z=[0,0],le=!1,de=[],we=!1,He=0,Qe=1,De=!1,nt={},tt=!0,Et=1,Lt=function(Be){if(Be=Be||["#fff","#000"],Be&&Go(Be)==="string"&&Tn.brewer&&Tn.brewer[Be.toLowerCase()]&&(Be=Tn.brewer[Be.toLowerCase()]),Go(Be)==="array"){Be.length===1&&(Be=[Be[0],Be[0]]),Be=Be.slice(0);for(var vt=0;vt<Be.length;vt++)Be[vt]=Tn(Be[vt]);X.length=0;for(var Tt=0;Tt<Be.length;Tt++)X.push(Tt/(Be.length-1))}return en(),de=Be},Dt=function(Be){if(le!=null){for(var vt=le.length-1,Tt=0;Tt<vt&&Be>=le[Tt];)Tt++;return Tt-1}return 0},Zt=function(Be){return Be},Oa=function(Be){return Be},Ta=function(Be,vt){var Tt,It;if(vt==null&&(vt=!1),isNaN(Be)||Be===null)return A;if(vt)It=Be;else if(le&&le.length>2){var Ha=Dt(Be);It=Ha/(le.length-2)}else Qe!==He?It=(Be-He)/(Qe-He):It=1;It=Oa(It),vt||(It=Zt(It)),Et!==1&&(It=W7(It,Et)),It=z[0]+It*(1-z[0]-z[1]),It=Math.min(1,Math.max(0,It));var na=Math.floor(It*1e4);if(tt&&nt[na])Tt=nt[na];else{if(Go(de)==="array")for(var Bt=0;Bt<X.length;Bt++){var Jt=X[Bt];if(It<=Jt){Tt=de[Bt];break}if(It>=Jt&&Bt===X.length-1){Tt=de[Bt];break}if(It>Jt&&It<X[Bt+1]){It=(It-Jt)/(X[Bt+1]-Jt),Tt=Tn.interpolate(de[Bt],de[Bt+1],It,w);break}}else Go(de)==="function"&&(Tt=de(It));tt&&(nt[na]=Tt)}return Tt},en=function(){return nt={}};Lt(p);var Rt=function(Be){var vt=Tn(Ta(Be));return we&&vt[we]?vt[we]():vt};return Rt.classes=function(Be){if(Be!=null){if(Go(Be)==="array")le=Be,W=[Be[0],Be[Be.length-1]];else{var vt=Tn.analyze(W);Be===0?le=[vt.min,vt.max]:le=Tn.limits(vt,"e",Be)}return Rt}return le},Rt.domain=function(Be){if(!arguments.length)return W;He=Be[0],Qe=Be[Be.length-1],X=[];var vt=de.length;if(Be.length===vt&&He!==Qe)for(var Tt=0,It=Array.from(Be);Tt<It.length;Tt+=1){var Ha=It[Tt];X.push((Ha-He)/(Qe-He))}else{for(var na=0;na<vt;na++)X.push(na/(vt-1));if(Be.length>2){var Bt=Be.map(function(Xt,Qt){return Qt/(Be.length-1)}),Jt=Be.map(function(Xt){return(Xt-He)/(Qe-He)});Jt.every(function(Xt,Qt){return Bt[Qt]===Xt})||(Oa=function(Xt){if(Xt<=0||Xt>=1)return Xt;for(var Qt=0;Xt>=Jt[Qt+1];)Qt++;var Ln=(Xt-Jt[Qt])/(Jt[Qt+1]-Jt[Qt]),Or=Bt[Qt]+Ln*(Bt[Qt+1]-Bt[Qt]);return Or})}}return W=[He,Qe],Rt},Rt.mode=function(Be){return arguments.length?(w=Be,en(),Rt):w},Rt.range=function(Be,vt){return Lt(Be),Rt},Rt.out=function(Be){return we=Be,Rt},Rt.spread=function(Be){return arguments.length?(V=Be,Rt):V},Rt.correctLightness=function(Be){return Be==null&&(Be=!0),De=Be,en(),De?Zt=function(vt){for(var Tt=Ta(0,!0).lab()[0],It=Ta(1,!0).lab()[0],Ha=Tt>It,na=Ta(vt,!0).lab()[0],Bt=Tt+(It-Tt)*vt,Jt=na-Bt,Xt=0,Qt=1,Ln=20;Math.abs(Jt)>.01&&Ln-- >0;)(function(){return Ha&&(Jt*=-1),Jt<0?(Xt=vt,vt+=(Qt-vt)*.5):(Qt=vt,vt+=(Xt-vt)*.5),na=Ta(vt,!0).lab()[0],Jt=na-Bt})();return vt}:Zt=function(vt){return vt},Rt},Rt.padding=function(Be){return Be!=null?(Go(Be)==="number"&&(Be=[Be,Be]),z=Be,Rt):z},Rt.colors=function(Be,vt){arguments.length<2&&(vt="hex");var Tt=[];if(arguments.length===0)Tt=de.slice(0);else if(Be===1)Tt=[Rt(.5)];else if(Be>1){var It=W[0],Ha=W[1]-It;Tt=Z7(0,Be,!1).map(function(Qt){return Rt(It+Qt/(Be-1)*Ha)})}else{p=[];var na=[];if(le&&le.length>2)for(var Bt=1,Jt=le.length,Xt=1<=Jt;Xt?Bt<Jt:Bt>Jt;Xt?Bt++:Bt--)na.push((le[Bt-1]+le[Bt])*.5);else na=W;Tt=na.map(function(Qt){return Rt(Qt)})}return Tn[vt]&&(Tt=Tt.map(function(Qt){return Qt[vt]()})),Tt},Rt.cache=function(Be){return Be!=null?(tt=Be,Rt):tt},Rt.gamma=function(Be){return Be!=null?(Et=Be,Rt):Et},Rt.nodata=function(Be){return Be!=null?(A=Tn(Be),Rt):A},Rt};function Z7(p,w,A){for(var V=[],W=p<w,X=A?W?w+1:w-1:w,z=p;W?z<X:z>X;W?z++:z--)V.push(z);return V}var Us=S,K7=m2,G7=function(p){for(var w=[1,1],A=1;A<p;A++){for(var V=[1],W=1;W<=w.length;W++)V[W]=(w[W]||0)+w[W-1];w=V}return w},J7=function(p){var w,A,V,W,X,z,le;if(p=p.map(function(De){return new Us(De)}),p.length===2)w=p.map(function(De){return De.lab()}),X=w[0],z=w[1],W=function(De){var nt=[0,1,2].map(function(tt){return X[tt]+De*(z[tt]-X[tt])});return new Us(nt,"lab")};else if(p.length===3)A=p.map(function(De){return De.lab()}),X=A[0],z=A[1],le=A[2],W=function(De){var nt=[0,1,2].map(function(tt){return(1-De)*(1-De)*X[tt]+2*(1-De)*De*z[tt]+De*De*le[tt]});return new Us(nt,"lab")};else if(p.length===4){var de;V=p.map(function(De){return De.lab()}),X=V[0],z=V[1],le=V[2],de=V[3],W=function(De){var nt=[0,1,2].map(function(tt){return(1-De)*(1-De)*(1-De)*X[tt]+3*(1-De)*(1-De)*De*z[tt]+3*(1-De)*De*De*le[tt]+De*De*De*de[tt]});return new Us(nt,"lab")}}else if(p.length>=5){var we,He,Qe;we=p.map(function(De){return De.lab()}),Qe=p.length-1,He=G7(Qe),W=function(De){var nt=1-De,tt=[0,1,2].map(function(Et){return we.reduce(function(Lt,Dt,Zt){return Lt+He[Zt]*Math.pow(nt,Qe-Zt)*Math.pow(De,Zt)*Dt[Et]},0)});return new Us(tt,"lab")}}else throw new RangeError("No point in running bezier with only one color.");return W},X7=function(p){var w=J7(p);return w.scale=function(){return K7(w)},w},v2=F,Pn=function(p,w,A){if(!Pn[A])throw new Error("unknown blend mode "+A);return Pn[A](p,w)},Lr=function(p){return function(w,A){var V=v2(A).rgb(),W=v2(w).rgb();return v2.rgb(p(V,W))}},Vr=function(p){return function(w,A){var V=[];return V[0]=p(w[0],A[0]),V[1]=p(w[1],A[1]),V[2]=p(w[2],A[2]),V}},Y7=function(p){return p},Q7=function(p,w){return p*w/255},e9=function(p,w){return p>w?w:p},t9=function(p,w){return p>w?p:w},a9=function(p,w){return 255*(1-(1-p/255)*(1-w/255))},n9=function(p,w){return w<128?2*p*w/255:255*(1-2*(1-p/255)*(1-w/255))},r9=function(p,w){return 255*(1-(1-w/255)/(p/255))},o9=function(p,w){return p===255?255:(p=255*(w/255)/(1-p/255),p>255?255:p)};Pn.normal=Lr(Vr(Y7)),Pn.multiply=Lr(Vr(Q7)),Pn.screen=Lr(Vr(a9)),Pn.overlay=Lr(Vr(n9)),Pn.darken=Lr(Vr(e9)),Pn.lighten=Lr(Vr(t9)),Pn.dodge=Lr(Vr(o9)),Pn.burn=Lr(Vr(r9));for(var s9=Pn,g2=g.type,i9=g.clip_rgb,l9=g.TWOPI,c9=Math.pow,d9=Math.sin,u9=Math.cos,Eu=F,h9=function(p,w,A,V,W){p===void 0&&(p=300),w===void 0&&(w=-1.5),A===void 0&&(A=1),V===void 0&&(V=1),W===void 0&&(W=[0,1]);var X=0,z;g2(W)==="array"?z=W[1]-W[0]:(z=0,W=[W,W]);var le=function(de){var we=l9*((p+120)/360+w*de),He=c9(W[0]+z*de,V),Qe=X!==0?A[0]+de*X:A,De=Qe*He*(1-He)/2,nt=u9(we),tt=d9(we),Et=He+De*(-.14861*nt+1.78277*tt),Lt=He+De*(-.29227*nt-.90649*tt),Dt=He+De*(1.97294*nt);return Eu(i9([Et*255,Lt*255,Dt*255,1]))};return le.start=function(de){return de==null?p:(p=de,le)},le.rotations=function(de){return de==null?w:(w=de,le)},le.gamma=function(de){return de==null?V:(V=de,le)},le.hue=function(de){return de==null?A:(A=de,g2(A)==="array"?(X=A[1]-A[0],X===0&&(A=A[1])):X=0,le)},le.lightness=function(de){return de==null?W:(g2(de)==="array"?(W=de,z=de[1]-de[0]):(W=[de,de],z=0),le)},le.scale=function(){return Eu.scale(le)},le.hue(A),le},p9=S,f9="0123456789abcdef",m9=Math.floor,v9=Math.random,g9=function(){for(var p="#",w=0;w<6;w++)p+=f9.charAt(m9(v9()*16));return new p9(p,"hex")},y2=c,Iu=Math.log,y9=Math.pow,M9=Math.floor,_9=Math.abs,ku=function(p,w){w===void 0&&(w=null);var A={min:Number.MAX_VALUE,max:Number.MAX_VALUE*-1,sum:0,values:[],count:0};return y2(p)==="object"&&(p=Object.values(p)),p.forEach(function(V){w&&y2(V)==="object"&&(V=V[w]),V!=null&&!isNaN(V)&&(A.values.push(V),A.sum+=V,V<A.min&&(A.min=V),V>A.max&&(A.max=V),A.count+=1)}),A.domain=[A.min,A.max],A.limits=function(V,W){return Tu(A,V,W)},A},Tu=function(p,w,A){w===void 0&&(w="equal"),A===void 0&&(A=7),y2(p)=="array"&&(p=ku(p));var V=p.min,W=p.max,X=p.values.sort(function(_2,b2){return _2-b2});if(A===1)return[V,W];var z=[];if(w.substr(0,1)==="c"&&(z.push(V),z.push(W)),w.substr(0,1)==="e"){z.push(V);for(var le=1;le<A;le++)z.push(V+le/A*(W-V));z.push(W)}else if(w.substr(0,1)==="l"){if(V<=0)throw new Error("Logarithmic scales are only possible for values > 0");var de=Math.LOG10E*Iu(V),we=Math.LOG10E*Iu(W);z.push(V);for(var He=1;He<A;He++)z.push(y9(10,de+He/A*(we-de)));z.push(W)}else if(w.substr(0,1)==="q"){z.push(V);for(var Qe=1;Qe<A;Qe++){var De=(X.length-1)*Qe/A,nt=M9(De);if(nt===De)z.push(X[nt]);else{var tt=De-nt;z.push(X[nt]*(1-tt)+X[nt+1]*tt)}}z.push(W)}else if(w.substr(0,1)==="k"){var Et,Lt=X.length,Dt=new Array(Lt),Zt=new Array(A),Oa=!0,Ta=0,en=null;en=[],en.push(V);for(var Rt=1;Rt<A;Rt++)en.push(V+Rt/A*(W-V));for(en.push(W);Oa;){for(var Be=0;Be<A;Be++)Zt[Be]=0;for(var vt=0;vt<Lt;vt++)for(var Tt=X[vt],It=Number.MAX_VALUE,Ha=void 0,na=0;na<A;na++){var Bt=_9(en[na]-Tt);Bt<It&&(It=Bt,Ha=na),Zt[Ha]++,Dt[vt]=Ha}for(var Jt=new Array(A),Xt=0;Xt<A;Xt++)Jt[Xt]=null;for(var Qt=0;Qt<Lt;Qt++)Et=Dt[Qt],Jt[Et]===null?Jt[Et]=X[Qt]:Jt[Et]+=X[Qt];for(var Ln=0;Ln<A;Ln++)Jt[Ln]*=1/Zt[Ln];Oa=!1;for(var Or=0;Or<A;Or++)if(Jt[Or]!==en[Or]){Oa=!0;break}en=Jt,Ta++,Ta>200&&(Oa=!1)}for(var Hr={},Jo=0;Jo<A;Jo++)Hr[Jo]=[];for(var Xo=0;Xo<Lt;Xo++)Et=Dt[Xo],Hr[Et].push(X[Xo]);for(var pr=[],ho=0;ho<A;ho++)pr.push(Hr[ho][0]),pr.push(Hr[ho][Hr[ho].length-1]);pr=pr.sort(function(_2,b2){return _2-b2}),z.push(pr[0]);for(var zs=1;zs<pr.length;zs+=2){var po=pr[zs];!isNaN(po)&&z.indexOf(po)===-1&&z.push(po)}}return z},Pu={analyze:ku,limits:Tu},Lu=S,b9=function(p,w){p=new Lu(p),w=new Lu(w);var A=p.luminance(),V=w.luminance();return A>V?(A+.05)/(V+.05):(V+.05)/(A+.05)},Vu=S,hr=Math.sqrt,Ma=Math.pow,w9=Math.min,x9=Math.max,Ou=Math.atan2,Hu=Math.abs,r1=Math.cos,Ru=Math.sin,C9=Math.exp,Nu=Math.PI,A9=function(p,w,A,V,W){A===void 0&&(A=1),V===void 0&&(V=1),W===void 0&&(W=1);var X=function(po){return 360*po/(2*Nu)},z=function(po){return 2*Nu*po/360};p=new Vu(p),w=new Vu(w);var le=Array.from(p.lab()),de=le[0],we=le[1],He=le[2],Qe=Array.from(w.lab()),De=Qe[0],nt=Qe[1],tt=Qe[2],Et=(de+De)/2,Lt=hr(Ma(we,2)+Ma(He,2)),Dt=hr(Ma(nt,2)+Ma(tt,2)),Zt=(Lt+Dt)/2,Oa=.5*(1-hr(Ma(Zt,7)/(Ma(Zt,7)+Ma(25,7)))),Ta=we*(1+Oa),en=nt*(1+Oa),Rt=hr(Ma(Ta,2)+Ma(He,2)),Be=hr(Ma(en,2)+Ma(tt,2)),vt=(Rt+Be)/2,Tt=X(Ou(He,Ta)),It=X(Ou(tt,en)),Ha=Tt>=0?Tt:Tt+360,na=It>=0?It:It+360,Bt=Hu(Ha-na)>180?(Ha+na+360)/2:(Ha+na)/2,Jt=1-.17*r1(z(Bt-30))+.24*r1(z(2*Bt))+.32*r1(z(3*Bt+6))-.2*r1(z(4*Bt-63)),Xt=na-Ha;Xt=Hu(Xt)<=180?Xt:na<=Ha?Xt+360:Xt-360,Xt=2*hr(Rt*Be)*Ru(z(Xt)/2);var Qt=De-de,Ln=Be-Rt,Or=1+.015*Ma(Et-50,2)/hr(20+Ma(Et-50,2)),Hr=1+.045*vt,Jo=1+.015*vt*Jt,Xo=30*C9(-Ma((Bt-275)/25,2)),pr=2*hr(Ma(vt,7)/(Ma(vt,7)+Ma(25,7))),ho=-pr*Ru(2*z(Xo)),zs=hr(Ma(Qt/(A*Or),2)+Ma(Ln/(V*Hr),2)+Ma(Xt/(W*Jo),2)+ho*(Ln/(V*Hr))*(Xt/(W*Jo)));return x9(0,w9(100,zs))},Du=S,S9=function(p,w,A){A===void 0&&(A="lab"),p=new Du(p),w=new Du(w);var V=p.get(A),W=w.get(A),X=0;for(var z in V){var le=(V[z]||0)-(W[z]||0);X+=le*le}return Math.sqrt(X)},$9=S,E9=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];try{return new(Function.prototype.bind.apply($9,[null].concat(p))),!0}catch{return!1}},Bu=F,Fu=m2,I9={cool:function(){return Fu([Bu.hsl(180,1,.9),Bu.hsl(250,.7,.4)])},hot:function(){return Fu(["#000","#f00","#ff0","#fff"]).mode("rgb")}},o1={OrRd:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#b30000","#7f0000"],PuBu:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#045a8d","#023858"],BuPu:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#810f7c","#4d004b"],Oranges:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#a63603","#7f2704"],BuGn:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#006d2c","#00441b"],YlOrBr:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#993404","#662506"],YlGn:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#006837","#004529"],Reds:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#a50f15","#67000d"],RdPu:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177","#49006a"],Greens:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#006d2c","#00441b"],YlGnBu:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#253494","#081d58"],Purples:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#54278f","#3f007d"],GnBu:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#0868ac","#084081"],Greys:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525","#000000"],YlOrRd:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"],PuRd:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#980043","#67001f"],Blues:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#08519c","#08306b"],PuBuGn:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016c59","#014636"],Viridis:["#440154","#482777","#3f4a8a","#31678e","#26838f","#1f9d8a","#6cce5a","#b6de2b","#fee825"],Spectral:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],RdYlGn:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"],RdBu:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"],PiYG:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"],PRGn:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"],RdYlBu:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"],BrBG:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"],RdGy:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"],PuOr:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"],Set2:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494","#b3b3b3"],Accent:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17","#666666"],Set1:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf","#999999"],Set3:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5","#ffed6f"],Dark2:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d","#666666"],Paired:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99","#b15928"],Pastel2:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc","#cccccc"],Pastel1:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec","#f2f2f2"]},M2=0,ju=Object.keys(o1);M2<ju.length;M2+=1){var Uu=ju[M2];o1[Uu.toLowerCase()]=o1[Uu]}var k9=o1,ka=F;ka.average=z7,ka.bezier=X7,ka.blend=s9,ka.cubehelix=h9,ka.mix=ka.interpolate=Mu,ka.random=g9,ka.scale=m2,ka.analyze=Pu.analyze,ka.contrast=b9,ka.deltaE=A9,ka.distance=S9,ka.limits=Pu.limits,ka.valid=E9,ka.scales=I9,ka.colors=tu,ka.brewer=k9;var T9=ka;return T9})})(Eg);var nre=Eg.exports;const Ig=E0(nre),rre=["onClick"],ore=["data-writer-tooltip"],sre={key:1,class:"CoreTags__tag CoreTags__tag--empty"},ire=`
8294
+ */(function(e,t){(function(a,n){e.exports=n()})(Xx,function(){for(var a=function(p,w,A){return w===void 0&&(w=0),A===void 0&&(A=1),p<w?w:p>A?A:p},n=a,r=function(p){p._clipped=!1,p._unclipped=p.slice(0);for(var w=0;w<=3;w++)w<3?((p[w]<0||p[w]>255)&&(p._clipped=!0),p[w]=n(p[w],0,255)):w===3&&(p[w]=n(p[w],0,1));return p},o={},s=0,i=["Boolean","Number","String","Function","Array","Date","RegExp","Undefined","Null"];s<i.length;s+=1){var l=i[s];o["[object "+l+"]"]=l.toLowerCase()}var c=function(p){return o[Object.prototype.toString.call(p)]||"object"},d=c,u=function(p,w){return w===void 0&&(w=null),p.length>=3?Array.prototype.slice.call(p):d(p[0])=="object"&&w?w.split("").filter(function(A){return p[0][A]!==void 0}).map(function(A){return p[0][A]}):p[0]},h=c,f=function(p){if(p.length<2)return null;var w=p.length-1;return h(p[w])=="string"?p[w].toLowerCase():null},m=Math.PI,g={clip_rgb:r,limit:a,type:c,unpack:u,last:f,PI:m,TWOPI:m*2,PITHIRD:m/3,DEG2RAD:m/180,RAD2DEG:180/m},_={format:{},autodetect:[]},b=g.last,v=g.clip_rgb,y=g.type,M=_,x=function(){for(var w=[],A=arguments.length;A--;)w[A]=arguments[A];var V=this;if(y(w[0])==="object"&&w[0].constructor&&w[0].constructor===this.constructor)return w[0];var W=b(w),X=!1;if(!W){X=!0,M.sorted||(M.autodetect=M.autodetect.sort(function(He,Qe){return Qe.p-He.p}),M.sorted=!0);for(var z=0,le=M.autodetect;z<le.length;z+=1){var de=le[z];if(W=de.test.apply(de,w),W)break}}if(M.format[W]){var we=M.format[W].apply(null,X?w:w.slice(0,-1));V._rgb=v(we)}else throw new Error("unknown format: "+w);V._rgb.length===3&&V._rgb.push(1)};x.prototype.toString=function(){return y(this.hex)=="function"?this.hex():"["+this._rgb.join(",")+"]"};var S=x,L=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(L.Color,[null].concat(p)))};L.Color=S,L.version="2.4.2";var F=L,te=g.unpack,J=Math.max,be=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=te(p,"rgb"),V=A[0],W=A[1],X=A[2];V=V/255,W=W/255,X=X/255;var z=1-J(V,J(W,X)),le=z<1?1/(1-z):0,de=(1-V-z)*le,we=(1-W-z)*le,He=(1-X-z)*le;return[de,we,He,z]},oe=be,Te=g.unpack,Ue=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=Te(p,"cmyk");var A=p[0],V=p[1],W=p[2],X=p[3],z=p.length>4?p[4]:1;return X===1?[0,0,0,z]:[A>=1?0:255*(1-A)*(1-X),V>=1?0:255*(1-V)*(1-X),W>=1?0:255*(1-W)*(1-X),z]},Ze=Ue,Me=F,ee=S,j=_,K=g.unpack,G=g.type,T=oe;ee.prototype.cmyk=function(){return T(this._rgb)},Me.cmyk=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(ee,[null].concat(p,["cmyk"])))},j.format.cmyk=Ze,j.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=K(p,"cmyk"),G(p)==="array"&&p.length===4)return"cmyk"}});var O=g.unpack,k=g.last,C=function(p){return Math.round(p*100)/100},P=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=O(p,"hsla"),V=k(p)||"lsa";return A[0]=C(A[0]||0),A[1]=C(A[1]*100)+"%",A[2]=C(A[2]*100)+"%",V==="hsla"||A.length>3&&A[3]<1?(A[3]=A.length>3?A[3]:1,V="hsla"):A.length=3,V+"("+A.join(",")+")"},ae=P,xe=g.unpack,ve=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=xe(p,"rgba");var A=p[0],V=p[1],W=p[2];A/=255,V/=255,W/=255;var X=Math.min(A,V,W),z=Math.max(A,V,W),le=(z+X)/2,de,we;return z===X?(de=0,we=Number.NaN):de=le<.5?(z-X)/(z+X):(z-X)/(2-z-X),A==z?we=(V-W)/(z-X):V==z?we=2+(W-A)/(z-X):W==z&&(we=4+(A-V)/(z-X)),we*=60,we<0&&(we+=360),p.length>3&&p[3]!==void 0?[we,de,le,p[3]]:[we,de,le]},ze=ve,Ye=g.unpack,ct=g.last,xt=ae,D=ze,q=Math.round,he=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Ye(p,"rgba"),V=ct(p)||"rgb";return V.substr(0,3)=="hsl"?xt(D(A),V):(A[0]=q(A[0]),A[1]=q(A[1]),A[2]=q(A[2]),(V==="rgba"||A.length>3&&A[3]<1)&&(A[3]=A.length>3?A[3]:1,V="rgba"),V+"("+A.slice(0,V==="rgb"?3:4).join(",")+")")},me=he,_e=g.unpack,Ae=Math.round,pe=function(){for(var p,w=[],A=arguments.length;A--;)w[A]=arguments[A];w=_e(w,"hsl");var V=w[0],W=w[1],X=w[2],z,le,de;if(W===0)z=le=de=X*255;else{var we=[0,0,0],He=[0,0,0],Qe=X<.5?X*(1+W):X+W-X*W,De=2*X-Qe,nt=V/360;we[0]=nt+1/3,we[1]=nt,we[2]=nt-1/3;for(var tt=0;tt<3;tt++)we[tt]<0&&(we[tt]+=1),we[tt]>1&&(we[tt]-=1),6*we[tt]<1?He[tt]=De+(Qe-De)*6*we[tt]:2*we[tt]<1?He[tt]=Qe:3*we[tt]<2?He[tt]=De+(Qe-De)*(2/3-we[tt])*6:He[tt]=De;p=[Ae(He[0]*255),Ae(He[1]*255),Ae(He[2]*255)],z=p[0],le=p[1],de=p[2]}return w.length>3?[z,le,de,w[3]]:[z,le,de,1]},ce=pe,ue=ce,I=_,B=/^rgb\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*\)$/,N=/^rgba\(\s*(-?\d+),\s*(-?\d+)\s*,\s*(-?\d+)\s*,\s*([01]|[01]?\.\d+)\)$/,U=/^rgb\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,se=/^rgba\(\s*(-?\d+(?:\.\d+)?)%,\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,Se=/^hsl\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*\)$/,Ne=/^hsla\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,ut=Math.round,ie=function(p){p=p.toLowerCase().trim();var w;if(I.format.named)try{return I.format.named(p)}catch{}if(w=p.match(B)){for(var A=w.slice(1,4),V=0;V<3;V++)A[V]=+A[V];return A[3]=1,A}if(w=p.match(N)){for(var W=w.slice(1,5),X=0;X<4;X++)W[X]=+W[X];return W}if(w=p.match(U)){for(var z=w.slice(1,4),le=0;le<3;le++)z[le]=ut(z[le]*2.55);return z[3]=1,z}if(w=p.match(se)){for(var de=w.slice(1,5),we=0;we<3;we++)de[we]=ut(de[we]*2.55);return de[3]=+de[3],de}if(w=p.match(Se)){var He=w.slice(1,4);He[1]*=.01,He[2]*=.01;var Qe=ue(He);return Qe[3]=1,Qe}if(w=p.match(Ne)){var De=w.slice(1,4);De[1]*=.01,De[2]*=.01;var nt=ue(De);return nt[3]=+w[4],nt}};ie.test=function(p){return B.test(p)||N.test(p)||U.test(p)||se.test(p)||Se.test(p)||Ne.test(p)};var Ee=ie,Oe=F,Pe=S,Ke=_,it=g.type,ht=me,Ft=Ee;Pe.prototype.css=function(p){return ht(this._rgb,p)},Oe.css=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Pe,[null].concat(p,["css"])))},Ke.format.css=Ft,Ke.autodetect.push({p:5,test:function(p){for(var w=[],A=arguments.length-1;A-- >0;)w[A]=arguments[A+1];if(!w.length&&it(p)==="string"&&Ft.test(p))return"css"}});var ma=S,Wt=F,ln=_,Lr=g.unpack;ln.format.gl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Lr(p,"rgba");return A[0]*=255,A[1]*=255,A[2]*=255,A},Wt.gl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(ma,[null].concat(p,["gl"])))},ma.prototype.gl=function(){var p=this._rgb;return[p[0]/255,p[1]/255,p[2]/255,p[3]]};var kn=g.unpack,co=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=kn(p,"rgb"),V=A[0],W=A[1],X=A[2],z=Math.min(V,W,X),le=Math.max(V,W,X),de=le-z,we=de*100/255,He=z/(255-de)*100,Qe;return de===0?Qe=Number.NaN:(V===le&&(Qe=(W-X)/de),W===le&&(Qe=2+(X-V)/de),X===le&&(Qe=4+(V-W)/de),Qe*=60,Qe<0&&(Qe+=360)),[Qe,we,He]},No=co,Do=g.unpack,Bo=Math.floor,Fo=function(){for(var p,w,A,V,W,X,z=[],le=arguments.length;le--;)z[le]=arguments[le];z=Do(z,"hcg");var de=z[0],we=z[1],He=z[2],Qe,De,nt;He=He*255;var tt=we*255;if(we===0)Qe=De=nt=He;else{de===360&&(de=0),de>360&&(de-=360),de<0&&(de+=360),de/=60;var Et=Bo(de),Lt=de-Et,Dt=He*(1-we),Zt=Dt+tt*(1-Lt),Oa=Dt+tt*Lt,Ta=Dt+tt;switch(Et){case 0:p=[Ta,Oa,Dt],Qe=p[0],De=p[1],nt=p[2];break;case 1:w=[Zt,Ta,Dt],Qe=w[0],De=w[1],nt=w[2];break;case 2:A=[Dt,Ta,Oa],Qe=A[0],De=A[1],nt=A[2];break;case 3:V=[Dt,Zt,Ta],Qe=V[0],De=V[1],nt=V[2];break;case 4:W=[Oa,Dt,Ta],Qe=W[0],De=W[1],nt=W[2];break;case 5:X=[Ta,Dt,Zt],Qe=X[0],De=X[1],nt=X[2];break}}return[Qe,De,nt,z.length>3?z[3]:1]},jo=Fo,hr=g.unpack,fe=g.type,Le=F,Re=S,Ve=_,Ge=No;Re.prototype.hcg=function(){return Ge(this._rgb)},Le.hcg=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Re,[null].concat(p,["hcg"])))},Ve.format.hcg=jo,Ve.autodetect.push({p:1,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=hr(p,"hcg"),fe(p)==="array"&&p.length===3)return"hcg"}});var dt=g.unpack,rt=g.last,_t=Math.round,At=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=dt(p,"rgba"),V=A[0],W=A[1],X=A[2],z=A[3],le=rt(p)||"auto";z===void 0&&(z=1),le==="auto"&&(le=z<1?"rgba":"rgb"),V=_t(V),W=_t(W),X=_t(X);var de=V<<16|W<<8|X,we="000000"+de.toString(16);we=we.substr(we.length-6);var He="0"+_t(z*255).toString(16);switch(He=He.substr(He.length-2),le.toLowerCase()){case"rgba":return"#"+we+He;case"argb":return"#"+He+we;default:return"#"+we}},Yt=At,la=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,ca=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,qe=function(p){if(p.match(la)){(p.length===4||p.length===7)&&(p=p.substr(1)),p.length===3&&(p=p.split(""),p=p[0]+p[0]+p[1]+p[1]+p[2]+p[2]);var w=parseInt(p,16),A=w>>16,V=w>>8&255,W=w&255;return[A,V,W,1]}if(p.match(ca)){(p.length===5||p.length===9)&&(p=p.substr(1)),p.length===4&&(p=p.split(""),p=p[0]+p[0]+p[1]+p[1]+p[2]+p[2]+p[3]+p[3]);var X=parseInt(p,16),z=X>>24&255,le=X>>16&255,de=X>>8&255,we=Math.round((X&255)/255*100)/100;return[z,le,de,we]}throw new Error("unknown hex color: "+p)},Y=qe,Fe=F,at=S,Gt=g.type,ha=_,va=Yt;at.prototype.hex=function(p){return va(this._rgb,p)},Fe.hex=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(at,[null].concat(p,["hex"])))},ha.format.hex=Y,ha.autodetect.push({p:4,test:function(p){for(var w=[],A=arguments.length-1;A-- >0;)w[A]=arguments[A+1];if(!w.length&&Gt(p)==="string"&&[3,4,5,6,7,8,9].indexOf(p.length)>=0)return"hex"}});var ya=g.unpack,Gn=g.TWOPI,uo=Math.min,Ba=Math.sqrt,Ji=Math.acos,Xi=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=ya(p,"rgb"),V=A[0],W=A[1],X=A[2];V/=255,W/=255,X/=255;var z,le=uo(V,W,X),de=(V+W+X)/3,we=de>0?1-le/de:0;return we===0?z=NaN:(z=(V-W+(V-X))/2,z/=Ba((V-W)*(V-W)+(V-X)*(W-X)),z=Ji(z),X>W&&(z=Gn-z),z/=Gn),[z*360,we,de]},d8=Xi,u8=g.unpack,Gl=g.limit,Uo=g.TWOPI,Jl=g.PITHIRD,zo=Math.cos,h8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=u8(p,"hsi");var A=p[0],V=p[1],W=p[2],X,z,le;return isNaN(A)&&(A=0),isNaN(V)&&(V=0),A>360&&(A-=360),A<0&&(A+=360),A/=360,A<1/3?(le=(1-V)/3,X=(1+V*zo(Uo*A)/zo(Jl-Uo*A))/3,z=1-(le+X)):A<2/3?(A-=1/3,X=(1-V)/3,z=(1+V*zo(Uo*A)/zo(Jl-Uo*A))/3,le=1-(X+z)):(A-=2/3,z=(1-V)/3,le=(1+V*zo(Uo*A)/zo(Jl-Uo*A))/3,X=1-(z+le)),X=Gl(W*X*3),z=Gl(W*z*3),le=Gl(W*le*3),[X*255,z*255,le*255,p.length>3?p[3]:1]},p8=h8,f8=g.unpack,m8=g.type,v8=F,Dd=S,Bd=_,g8=d8;Dd.prototype.hsi=function(){return g8(this._rgb)},v8.hsi=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Dd,[null].concat(p,["hsi"])))},Bd.format.hsi=p8,Bd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=f8(p,"hsi"),m8(p)==="array"&&p.length===3)return"hsi"}});var y8=g.unpack,M8=g.type,_8=F,Fd=S,jd=_,b8=ze;Fd.prototype.hsl=function(){return b8(this._rgb)},_8.hsl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Fd,[null].concat(p,["hsl"])))},jd.format.hsl=ce,jd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=y8(p,"hsl"),M8(p)==="array"&&p.length===3)return"hsl"}});var w8=g.unpack,x8=Math.min,C8=Math.max,A8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=w8(p,"rgb");var A=p[0],V=p[1],W=p[2],X=x8(A,V,W),z=C8(A,V,W),le=z-X,de,we,He;return He=z/255,z===0?(de=Number.NaN,we=0):(we=le/z,A===z&&(de=(V-W)/le),V===z&&(de=2+(W-A)/le),W===z&&(de=4+(A-V)/le),de*=60,de<0&&(de+=360)),[de,we,He]},S8=A8,$8=g.unpack,E8=Math.floor,I8=function(){for(var p,w,A,V,W,X,z=[],le=arguments.length;le--;)z[le]=arguments[le];z=$8(z,"hsv");var de=z[0],we=z[1],He=z[2],Qe,De,nt;if(He*=255,we===0)Qe=De=nt=He;else{de===360&&(de=0),de>360&&(de-=360),de<0&&(de+=360),de/=60;var tt=E8(de),Et=de-tt,Lt=He*(1-we),Dt=He*(1-we*Et),Zt=He*(1-we*(1-Et));switch(tt){case 0:p=[He,Zt,Lt],Qe=p[0],De=p[1],nt=p[2];break;case 1:w=[Dt,He,Lt],Qe=w[0],De=w[1],nt=w[2];break;case 2:A=[Lt,He,Zt],Qe=A[0],De=A[1],nt=A[2];break;case 3:V=[Lt,Dt,He],Qe=V[0],De=V[1],nt=V[2];break;case 4:W=[Zt,Lt,He],Qe=W[0],De=W[1],nt=W[2];break;case 5:X=[He,Lt,Dt],Qe=X[0],De=X[1],nt=X[2];break}}return[Qe,De,nt,z.length>3?z[3]:1]},k8=I8,T8=g.unpack,P8=g.type,L8=F,Ud=S,zd=_,V8=S8;Ud.prototype.hsv=function(){return V8(this._rgb)},L8.hsv=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Ud,[null].concat(p,["hsv"])))},zd.format.hsv=k8,zd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=T8(p,"hsv"),P8(p)==="array"&&p.length===3)return"hsv"}});var Yi={Kn:18,Xn:.95047,Yn:1,Zn:1.08883,t0:.137931034,t1:.206896552,t2:.12841855,t3:.008856452},qo=Yi,O8=g.unpack,qd=Math.pow,H8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=O8(p,"rgb"),V=A[0],W=A[1],X=A[2],z=R8(V,W,X),le=z[0],de=z[1],we=z[2],He=116*de-16;return[He<0?0:He,500*(le-de),200*(de-we)]},Xl=function(p){return(p/=255)<=.04045?p/12.92:qd((p+.055)/1.055,2.4)},Yl=function(p){return p>qo.t3?qd(p,1/3):p/qo.t2+qo.t0},R8=function(p,w,A){p=Xl(p),w=Xl(w),A=Xl(A);var V=Yl((.4124564*p+.3575761*w+.1804375*A)/qo.Xn),W=Yl((.2126729*p+.7151522*w+.072175*A)/qo.Yn),X=Yl((.0193339*p+.119192*w+.9503041*A)/qo.Zn);return[V,W,X]},Wd=H8,Wo=Yi,N8=g.unpack,D8=Math.pow,B8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=N8(p,"lab");var A=p[0],V=p[1],W=p[2],X,z,le,de,we,He;return z=(A+16)/116,X=isNaN(V)?z:z+V/500,le=isNaN(W)?z:z-W/200,z=Wo.Yn*e2(z),X=Wo.Xn*e2(X),le=Wo.Zn*e2(le),de=Ql(3.2404542*X-1.5371385*z-.4985314*le),we=Ql(-.969266*X+1.8760108*z+.041556*le),He=Ql(.0556434*X-.2040259*z+1.0572252*le),[de,we,He,p.length>3?p[3]:1]},Ql=function(p){return 255*(p<=.00304?12.92*p:1.055*D8(p,1/2.4)-.055)},e2=function(p){return p>Wo.t1?p*p*p:Wo.t2*(p-Wo.t0)},Zd=B8,F8=g.unpack,j8=g.type,U8=F,Kd=S,Gd=_,z8=Wd;Kd.prototype.lab=function(){return z8(this._rgb)},U8.lab=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Kd,[null].concat(p,["lab"])))},Gd.format.lab=Zd,Gd.autodetect.push({p:2,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=F8(p,"lab"),j8(p)==="array"&&p.length===3)return"lab"}});var q8=g.unpack,W8=g.RAD2DEG,Z8=Math.sqrt,K8=Math.atan2,G8=Math.round,J8=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=q8(p,"lab"),V=A[0],W=A[1],X=A[2],z=Z8(W*W+X*X),le=(K8(X,W)*W8+360)%360;return G8(z*1e4)===0&&(le=Number.NaN),[V,z,le]},Jd=J8,X8=g.unpack,Y8=Wd,Q8=Jd,ey=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=X8(p,"rgb"),V=A[0],W=A[1],X=A[2],z=Y8(V,W,X),le=z[0],de=z[1],we=z[2];return Q8(le,de,we)},ty=ey,ay=g.unpack,ny=g.DEG2RAD,ry=Math.sin,oy=Math.cos,sy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=ay(p,"lch"),V=A[0],W=A[1],X=A[2];return isNaN(X)&&(X=0),X=X*ny,[V,oy(X)*W,ry(X)*W]},Xd=sy,iy=g.unpack,ly=Xd,cy=Zd,dy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=iy(p,"lch");var A=p[0],V=p[1],W=p[2],X=ly(A,V,W),z=X[0],le=X[1],de=X[2],we=cy(z,le,de),He=we[0],Qe=we[1],De=we[2];return[He,Qe,De,p.length>3?p[3]:1]},Yd=dy,uy=g.unpack,hy=Yd,py=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=uy(p,"hcl").reverse();return hy.apply(void 0,A)},fy=py,my=g.unpack,vy=g.type,Qd=F,Qi=S,t2=_,eu=ty;Qi.prototype.lch=function(){return eu(this._rgb)},Qi.prototype.hcl=function(){return eu(this._rgb).reverse()},Qd.lch=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Qi,[null].concat(p,["lch"])))},Qd.hcl=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(Qi,[null].concat(p,["hcl"])))},t2.format.lch=Yd,t2.format.hcl=fy,["lch","hcl"].forEach(function(p){return t2.autodetect.push({p:2,test:function(){for(var w=[],A=arguments.length;A--;)w[A]=arguments[A];if(w=my(w,p),vy(w)==="array"&&w.length===3)return p}})});var gy={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflower:"#6495ed",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",laserlemon:"#ffff54",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrod:"#fafad2",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",maroon2:"#7f0000",maroon3:"#b03060",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",purple2:"#7f007f",purple3:"#a020f0",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},tu=gy,yy=S,au=_,My=g.type,Us=tu,_y=Y,by=Yt;yy.prototype.name=function(){for(var p=by(this._rgb,"rgb"),w=0,A=Object.keys(Us);w<A.length;w+=1){var V=A[w];if(Us[V]===p)return V.toLowerCase()}return p},au.format.named=function(p){if(p=p.toLowerCase(),Us[p])return _y(Us[p]);throw new Error("unknown color name: "+p)},au.autodetect.push({p:5,test:function(p){for(var w=[],A=arguments.length-1;A-- >0;)w[A]=arguments[A+1];if(!w.length&&My(p)==="string"&&Us[p.toLowerCase()])return"named"}});var wy=g.unpack,xy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=wy(p,"rgb"),V=A[0],W=A[1],X=A[2];return(V<<16)+(W<<8)+X},Cy=xy,Ay=g.type,Sy=function(p){if(Ay(p)=="number"&&p>=0&&p<=16777215){var w=p>>16,A=p>>8&255,V=p&255;return[w,A,V,1]}throw new Error("unknown num color: "+p)},$y=Sy,Ey=F,nu=S,ru=_,Iy=g.type,ky=Cy;nu.prototype.num=function(){return ky(this._rgb)},Ey.num=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(nu,[null].concat(p,["num"])))},ru.format.num=$y,ru.autodetect.push({p:5,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p.length===1&&Iy(p[0])==="number"&&p[0]>=0&&p[0]<=16777215)return"num"}});var Ty=F,a2=S,ou=_,su=g.unpack,iu=g.type,lu=Math.round;a2.prototype.rgb=function(p){return p===void 0&&(p=!0),p===!1?this._rgb.slice(0,3):this._rgb.slice(0,3).map(lu)},a2.prototype.rgba=function(p){return p===void 0&&(p=!0),this._rgb.slice(0,4).map(function(w,A){return A<3?p===!1?w:lu(w):w})},Ty.rgb=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(a2,[null].concat(p,["rgb"])))},ou.format.rgb=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=su(p,"rgba");return A[3]===void 0&&(A[3]=1),A},ou.autodetect.push({p:3,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=su(p,"rgba"),iu(p)==="array"&&(p.length===3||p.length===4&&iu(p[3])=="number"&&p[3]>=0&&p[3]<=1))return"rgb"}});var e1=Math.log,Py=function(p){var w=p/100,A,V,W;return w<66?(A=255,V=w<6?0:-155.25485562709179-.44596950469579133*(V=w-2)+104.49216199393888*e1(V),W=w<20?0:-254.76935184120902+.8274096064007395*(W=w-10)+115.67994401066147*e1(W)):(A=351.97690566805693+.114206453784165*(A=w-55)-40.25366309332127*e1(A),V=325.4494125711974+.07943456536662342*(V=w-50)-28.0852963507957*e1(V),W=255),[A,V,W,1]},cu=Py,Ly=cu,Vy=g.unpack,Oy=Math.round,Hy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];for(var A=Vy(p,"rgb"),V=A[0],W=A[2],X=1e3,z=4e4,le=.4,de;z-X>le;){de=(z+X)*.5;var we=Ly(de);we[2]/we[0]>=W/V?z=de:X=de}return Oy(de)},Ry=Hy,n2=F,t1=S,r2=_,Ny=Ry;t1.prototype.temp=t1.prototype.kelvin=t1.prototype.temperature=function(){return Ny(this._rgb)},n2.temp=n2.kelvin=n2.temperature=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(t1,[null].concat(p,["temp"])))},r2.format.temp=r2.format.kelvin=r2.format.temperature=cu;var Dy=g.unpack,o2=Math.cbrt,By=Math.pow,Fy=Math.sign,jy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Dy(p,"rgb"),V=A[0],W=A[1],X=A[2],z=[s2(V/255),s2(W/255),s2(X/255)],le=z[0],de=z[1],we=z[2],He=o2(.4122214708*le+.5363325363*de+.0514459929*we),Qe=o2(.2119034982*le+.6806995451*de+.1073969566*we),De=o2(.0883024619*le+.2817188376*de+.6299787005*we);return[.2104542553*He+.793617785*Qe-.0040720468*De,1.9779984951*He-2.428592205*Qe+.4505937099*De,.0259040371*He+.7827717662*Qe-.808675766*De]},du=jy;function s2(p){var w=Math.abs(p);return w<.04045?p/12.92:(Fy(p)||1)*By((w+.055)/1.055,2.4)}var Uy=g.unpack,a1=Math.pow,zy=Math.sign,qy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=Uy(p,"lab");var A=p[0],V=p[1],W=p[2],X=a1(A+.3963377774*V+.2158037573*W,3),z=a1(A-.1055613458*V-.0638541728*W,3),le=a1(A-.0894841775*V-1.291485548*W,3);return[255*i2(4.0767416621*X-3.3077115913*z+.2309699292*le),255*i2(-1.2684380046*X+2.6097574011*z-.3413193965*le),255*i2(-.0041960863*X-.7034186147*z+1.707614701*le),p.length>3?p[3]:1]},uu=qy;function i2(p){var w=Math.abs(p);return w>.0031308?(zy(p)||1)*(1.055*a1(w,1/2.4)-.055):p*12.92}var Wy=g.unpack,Zy=g.type,Ky=F,hu=S,pu=_,Gy=du;hu.prototype.oklab=function(){return Gy(this._rgb)},Ky.oklab=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(hu,[null].concat(p,["oklab"])))},pu.format.oklab=uu,pu.autodetect.push({p:3,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=Wy(p,"oklab"),Zy(p)==="array"&&p.length===3)return"oklab"}});var Jy=g.unpack,Xy=du,Yy=Jd,Qy=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];var A=Jy(p,"rgb"),V=A[0],W=A[1],X=A[2],z=Xy(V,W,X),le=z[0],de=z[1],we=z[2];return Yy(le,de,we)},e7=Qy,t7=g.unpack,a7=Xd,n7=uu,r7=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];p=t7(p,"lch");var A=p[0],V=p[1],W=p[2],X=a7(A,V,W),z=X[0],le=X[1],de=X[2],we=n7(z,le,de),He=we[0],Qe=we[1],De=we[2];return[He,Qe,De,p.length>3?p[3]:1]},o7=r7,s7=g.unpack,i7=g.type,l7=F,fu=S,mu=_,c7=e7;fu.prototype.oklch=function(){return c7(this._rgb)},l7.oklch=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];return new(Function.prototype.bind.apply(fu,[null].concat(p,["oklch"])))},mu.format.oklch=o7,mu.autodetect.push({p:3,test:function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];if(p=s7(p,"oklch"),i7(p)==="array"&&p.length===3)return"oklch"}});var vu=S,d7=g.type;vu.prototype.alpha=function(p,w){return w===void 0&&(w=!1),p!==void 0&&d7(p)==="number"?w?(this._rgb[3]=p,this):new vu([this._rgb[0],this._rgb[1],this._rgb[2],p],"rgb"):this._rgb[3]};var u7=S;u7.prototype.clipped=function(){return this._rgb._clipped||!1};var ho=S,h7=Yi;ho.prototype.darken=function(p){p===void 0&&(p=1);var w=this,A=w.lab();return A[0]-=h7.Kn*p,new ho(A,"lab").alpha(w.alpha(),!0)},ho.prototype.brighten=function(p){return p===void 0&&(p=1),this.darken(-p)},ho.prototype.darker=ho.prototype.darken,ho.prototype.brighter=ho.prototype.brighten;var p7=S;p7.prototype.get=function(p){var w=p.split("."),A=w[0],V=w[1],W=this[A]();if(V){var X=A.indexOf(V)-(A.substr(0,2)==="ok"?2:0);if(X>-1)return W[X];throw new Error("unknown channel "+V+" in mode "+A)}else return W};var Zo=S,f7=g.type,m7=Math.pow,v7=1e-7,g7=20;Zo.prototype.luminance=function(p){if(p!==void 0&&f7(p)==="number"){if(p===0)return new Zo([0,0,0,this._rgb[3]],"rgb");if(p===1)return new Zo([255,255,255,this._rgb[3]],"rgb");var w=this.luminance(),A="rgb",V=g7,W=function(z,le){var de=z.interpolate(le,.5,A),we=de.luminance();return Math.abs(p-we)<v7||!V--?de:we>p?W(z,de):W(de,le)},X=(w>p?W(new Zo([0,0,0]),this):W(this,new Zo([255,255,255]))).rgb();return new Zo(X.concat([this._rgb[3]]))}return y7.apply(void 0,this._rgb.slice(0,3))};var y7=function(p,w,A){return p=l2(p),w=l2(w),A=l2(A),.2126*p+.7152*w+.0722*A},l2=function(p){return p/=255,p<=.03928?p/12.92:m7((p+.055)/1.055,2.4)},cn={},gu=S,yu=g.type,n1=cn,Mu=function(p,w,A){A===void 0&&(A=.5);for(var V=[],W=arguments.length-3;W-- >0;)V[W]=arguments[W+3];var X=V[0]||"lrgb";if(!n1[X]&&!V.length&&(X=Object.keys(n1)[0]),!n1[X])throw new Error("interpolation mode "+X+" is not defined");return yu(p)!=="object"&&(p=new gu(p)),yu(w)!=="object"&&(w=new gu(w)),n1[X](p,w,A).alpha(p.alpha()+A*(w.alpha()-p.alpha()))},_u=S,M7=Mu;_u.prototype.mix=_u.prototype.interpolate=function(p,w){w===void 0&&(w=.5);for(var A=[],V=arguments.length-2;V-- >0;)A[V]=arguments[V+2];return M7.apply(void 0,[this,p,w].concat(A))};var bu=S;bu.prototype.premultiply=function(p){p===void 0&&(p=!1);var w=this._rgb,A=w[3];return p?(this._rgb=[w[0]*A,w[1]*A,w[2]*A,A],this):new bu([w[0]*A,w[1]*A,w[2]*A,A],"rgb")};var c2=S,_7=Yi;c2.prototype.saturate=function(p){p===void 0&&(p=1);var w=this,A=w.lch();return A[1]+=_7.Kn*p,A[1]<0&&(A[1]=0),new c2(A,"lch").alpha(w.alpha(),!0)},c2.prototype.desaturate=function(p){return p===void 0&&(p=1),this.saturate(-p)};var wu=S,xu=g.type;wu.prototype.set=function(p,w,A){A===void 0&&(A=!1);var V=p.split("."),W=V[0],X=V[1],z=this[W]();if(X){var le=W.indexOf(X)-(W.substr(0,2)==="ok"?2:0);if(le>-1){if(xu(w)=="string")switch(w.charAt(0)){case"+":z[le]+=+w;break;case"-":z[le]+=+w;break;case"*":z[le]*=+w.substr(1);break;case"/":z[le]/=+w.substr(1);break;default:z[le]=+w}else if(xu(w)==="number")z[le]=w;else throw new Error("unsupported value for Color.set");var de=new wu(z,W);return A?(this._rgb=de._rgb,this):de}throw new Error("unknown channel "+X+" in mode "+W)}else return z};var b7=S,w7=function(p,w,A){var V=p._rgb,W=w._rgb;return new b7(V[0]+A*(W[0]-V[0]),V[1]+A*(W[1]-V[1]),V[2]+A*(W[2]-V[2]),"rgb")};cn.rgb=w7;var x7=S,d2=Math.sqrt,Ko=Math.pow,C7=function(p,w,A){var V=p._rgb,W=V[0],X=V[1],z=V[2],le=w._rgb,de=le[0],we=le[1],He=le[2];return new x7(d2(Ko(W,2)*(1-A)+Ko(de,2)*A),d2(Ko(X,2)*(1-A)+Ko(we,2)*A),d2(Ko(z,2)*(1-A)+Ko(He,2)*A),"rgb")};cn.lrgb=C7;var A7=S,S7=function(p,w,A){var V=p.lab(),W=w.lab();return new A7(V[0]+A*(W[0]-V[0]),V[1]+A*(W[1]-V[1]),V[2]+A*(W[2]-V[2]),"lab")};cn.lab=S7;var Cu=S,Go=function(p,w,A,V){var W,X,z,le;V==="hsl"?(z=p.hsl(),le=w.hsl()):V==="hsv"?(z=p.hsv(),le=w.hsv()):V==="hcg"?(z=p.hcg(),le=w.hcg()):V==="hsi"?(z=p.hsi(),le=w.hsi()):V==="lch"||V==="hcl"?(V="hcl",z=p.hcl(),le=w.hcl()):V==="oklch"&&(z=p.oklch().reverse(),le=w.oklch().reverse());var de,we,He,Qe,De,nt;(V.substr(0,1)==="h"||V==="oklch")&&(W=z,de=W[0],He=W[1],De=W[2],X=le,we=X[0],Qe=X[1],nt=X[2]);var tt,Et,Lt,Dt;return!isNaN(de)&&!isNaN(we)?(we>de&&we-de>180?Dt=we-(de+360):we<de&&de-we>180?Dt=we+360-de:Dt=we-de,Et=de+A*Dt):isNaN(de)?isNaN(we)?Et=Number.NaN:(Et=we,(De==1||De==0)&&V!="hsv"&&(tt=Qe)):(Et=de,(nt==1||nt==0)&&V!="hsv"&&(tt=He)),tt===void 0&&(tt=He+A*(Qe-He)),Lt=De+A*(nt-De),V==="oklch"?new Cu([Lt,tt,Et],V):new Cu([Et,tt,Lt],V)},$7=Go,Au=function(p,w,A){return $7(p,w,A,"lch")};cn.lch=Au,cn.hcl=Au;var E7=S,I7=function(p,w,A){var V=p.num(),W=w.num();return new E7(V+A*(W-V),"num")};cn.num=I7;var k7=Go,T7=function(p,w,A){return k7(p,w,A,"hcg")};cn.hcg=T7;var P7=Go,L7=function(p,w,A){return P7(p,w,A,"hsi")};cn.hsi=L7;var V7=Go,O7=function(p,w,A){return V7(p,w,A,"hsl")};cn.hsl=O7;var H7=Go,R7=function(p,w,A){return H7(p,w,A,"hsv")};cn.hsv=R7;var N7=S,D7=function(p,w,A){var V=p.oklab(),W=w.oklab();return new N7(V[0]+A*(W[0]-V[0]),V[1]+A*(W[1]-V[1]),V[2]+A*(W[2]-V[2]),"oklab")};cn.oklab=D7;var B7=Go,F7=function(p,w,A){return B7(p,w,A,"oklch")};cn.oklch=F7;var u2=S,j7=g.clip_rgb,h2=Math.pow,p2=Math.sqrt,f2=Math.PI,Su=Math.cos,$u=Math.sin,U7=Math.atan2,z7=function(p,w,A){w===void 0&&(w="lrgb"),A===void 0&&(A=null);var V=p.length;A||(A=Array.from(new Array(V)).map(function(){return 1}));var W=V/A.reduce(function(Et,Lt){return Et+Lt});if(A.forEach(function(Et,Lt){A[Lt]*=W}),p=p.map(function(Et){return new u2(Et)}),w==="lrgb")return q7(p,A);for(var X=p.shift(),z=X.get(w),le=[],de=0,we=0,He=0;He<z.length;He++)if(z[He]=(z[He]||0)*A[0],le.push(isNaN(z[He])?0:A[0]),w.charAt(He)==="h"&&!isNaN(z[He])){var Qe=z[He]/180*f2;de+=Su(Qe)*A[0],we+=$u(Qe)*A[0]}var De=X.alpha()*A[0];p.forEach(function(Et,Lt){var Dt=Et.get(w);De+=Et.alpha()*A[Lt+1];for(var Zt=0;Zt<z.length;Zt++)if(!isNaN(Dt[Zt]))if(le[Zt]+=A[Lt+1],w.charAt(Zt)==="h"){var Oa=Dt[Zt]/180*f2;de+=Su(Oa)*A[Lt+1],we+=$u(Oa)*A[Lt+1]}else z[Zt]+=Dt[Zt]*A[Lt+1]});for(var nt=0;nt<z.length;nt++)if(w.charAt(nt)==="h"){for(var tt=U7(we/le[nt],de/le[nt])/f2*180;tt<0;)tt+=360;for(;tt>=360;)tt-=360;z[nt]=tt}else z[nt]=z[nt]/le[nt];return De/=V,new u2(z,w).alpha(De>.99999?1:De,!0)},q7=function(p,w){for(var A=p.length,V=[0,0,0,0],W=0;W<p.length;W++){var X=p[W],z=w[W]/A,le=X._rgb;V[0]+=h2(le[0],2)*z,V[1]+=h2(le[1],2)*z,V[2]+=h2(le[2],2)*z,V[3]+=le[3]*z}return V[0]=p2(V[0]),V[1]=p2(V[1]),V[2]=p2(V[2]),V[3]>.9999999&&(V[3]=1),new u2(j7(V))},Tn=F,Jo=g.type,W7=Math.pow,m2=function(p){var w="rgb",A=Tn("#ccc"),V=0,W=[0,1],X=[],z=[0,0],le=!1,de=[],we=!1,He=0,Qe=1,De=!1,nt={},tt=!0,Et=1,Lt=function(Be){if(Be=Be||["#fff","#000"],Be&&Jo(Be)==="string"&&Tn.brewer&&Tn.brewer[Be.toLowerCase()]&&(Be=Tn.brewer[Be.toLowerCase()]),Jo(Be)==="array"){Be.length===1&&(Be=[Be[0],Be[0]]),Be=Be.slice(0);for(var vt=0;vt<Be.length;vt++)Be[vt]=Tn(Be[vt]);X.length=0;for(var Tt=0;Tt<Be.length;Tt++)X.push(Tt/(Be.length-1))}return en(),de=Be},Dt=function(Be){if(le!=null){for(var vt=le.length-1,Tt=0;Tt<vt&&Be>=le[Tt];)Tt++;return Tt-1}return 0},Zt=function(Be){return Be},Oa=function(Be){return Be},Ta=function(Be,vt){var Tt,It;if(vt==null&&(vt=!1),isNaN(Be)||Be===null)return A;if(vt)It=Be;else if(le&&le.length>2){var Ha=Dt(Be);It=Ha/(le.length-2)}else Qe!==He?It=(Be-He)/(Qe-He):It=1;It=Oa(It),vt||(It=Zt(It)),Et!==1&&(It=W7(It,Et)),It=z[0]+It*(1-z[0]-z[1]),It=Math.min(1,Math.max(0,It));var ra=Math.floor(It*1e4);if(tt&&nt[ra])Tt=nt[ra];else{if(Jo(de)==="array")for(var Bt=0;Bt<X.length;Bt++){var Jt=X[Bt];if(It<=Jt){Tt=de[Bt];break}if(It>=Jt&&Bt===X.length-1){Tt=de[Bt];break}if(It>Jt&&It<X[Bt+1]){It=(It-Jt)/(X[Bt+1]-Jt),Tt=Tn.interpolate(de[Bt],de[Bt+1],It,w);break}}else Jo(de)==="function"&&(Tt=de(It));tt&&(nt[ra]=Tt)}return Tt},en=function(){return nt={}};Lt(p);var Rt=function(Be){var vt=Tn(Ta(Be));return we&&vt[we]?vt[we]():vt};return Rt.classes=function(Be){if(Be!=null){if(Jo(Be)==="array")le=Be,W=[Be[0],Be[Be.length-1]];else{var vt=Tn.analyze(W);Be===0?le=[vt.min,vt.max]:le=Tn.limits(vt,"e",Be)}return Rt}return le},Rt.domain=function(Be){if(!arguments.length)return W;He=Be[0],Qe=Be[Be.length-1],X=[];var vt=de.length;if(Be.length===vt&&He!==Qe)for(var Tt=0,It=Array.from(Be);Tt<It.length;Tt+=1){var Ha=It[Tt];X.push((Ha-He)/(Qe-He))}else{for(var ra=0;ra<vt;ra++)X.push(ra/(vt-1));if(Be.length>2){var Bt=Be.map(function(Xt,Qt){return Qt/(Be.length-1)}),Jt=Be.map(function(Xt){return(Xt-He)/(Qe-He)});Jt.every(function(Xt,Qt){return Bt[Qt]===Xt})||(Oa=function(Xt){if(Xt<=0||Xt>=1)return Xt;for(var Qt=0;Xt>=Jt[Qt+1];)Qt++;var Ln=(Xt-Jt[Qt])/(Jt[Qt+1]-Jt[Qt]),Hr=Bt[Qt]+Ln*(Bt[Qt+1]-Bt[Qt]);return Hr})}}return W=[He,Qe],Rt},Rt.mode=function(Be){return arguments.length?(w=Be,en(),Rt):w},Rt.range=function(Be,vt){return Lt(Be),Rt},Rt.out=function(Be){return we=Be,Rt},Rt.spread=function(Be){return arguments.length?(V=Be,Rt):V},Rt.correctLightness=function(Be){return Be==null&&(Be=!0),De=Be,en(),De?Zt=function(vt){for(var Tt=Ta(0,!0).lab()[0],It=Ta(1,!0).lab()[0],Ha=Tt>It,ra=Ta(vt,!0).lab()[0],Bt=Tt+(It-Tt)*vt,Jt=ra-Bt,Xt=0,Qt=1,Ln=20;Math.abs(Jt)>.01&&Ln-- >0;)(function(){return Ha&&(Jt*=-1),Jt<0?(Xt=vt,vt+=(Qt-vt)*.5):(Qt=vt,vt+=(Xt-vt)*.5),ra=Ta(vt,!0).lab()[0],Jt=ra-Bt})();return vt}:Zt=function(vt){return vt},Rt},Rt.padding=function(Be){return Be!=null?(Jo(Be)==="number"&&(Be=[Be,Be]),z=Be,Rt):z},Rt.colors=function(Be,vt){arguments.length<2&&(vt="hex");var Tt=[];if(arguments.length===0)Tt=de.slice(0);else if(Be===1)Tt=[Rt(.5)];else if(Be>1){var It=W[0],Ha=W[1]-It;Tt=Z7(0,Be,!1).map(function(Qt){return Rt(It+Qt/(Be-1)*Ha)})}else{p=[];var ra=[];if(le&&le.length>2)for(var Bt=1,Jt=le.length,Xt=1<=Jt;Xt?Bt<Jt:Bt>Jt;Xt?Bt++:Bt--)ra.push((le[Bt-1]+le[Bt])*.5);else ra=W;Tt=ra.map(function(Qt){return Rt(Qt)})}return Tn[vt]&&(Tt=Tt.map(function(Qt){return Qt[vt]()})),Tt},Rt.cache=function(Be){return Be!=null?(tt=Be,Rt):tt},Rt.gamma=function(Be){return Be!=null?(Et=Be,Rt):Et},Rt.nodata=function(Be){return Be!=null?(A=Tn(Be),Rt):A},Rt};function Z7(p,w,A){for(var V=[],W=p<w,X=A?W?w+1:w-1:w,z=p;W?z<X:z>X;W?z++:z--)V.push(z);return V}var zs=S,K7=m2,G7=function(p){for(var w=[1,1],A=1;A<p;A++){for(var V=[1],W=1;W<=w.length;W++)V[W]=(w[W]||0)+w[W-1];w=V}return w},J7=function(p){var w,A,V,W,X,z,le;if(p=p.map(function(De){return new zs(De)}),p.length===2)w=p.map(function(De){return De.lab()}),X=w[0],z=w[1],W=function(De){var nt=[0,1,2].map(function(tt){return X[tt]+De*(z[tt]-X[tt])});return new zs(nt,"lab")};else if(p.length===3)A=p.map(function(De){return De.lab()}),X=A[0],z=A[1],le=A[2],W=function(De){var nt=[0,1,2].map(function(tt){return(1-De)*(1-De)*X[tt]+2*(1-De)*De*z[tt]+De*De*le[tt]});return new zs(nt,"lab")};else if(p.length===4){var de;V=p.map(function(De){return De.lab()}),X=V[0],z=V[1],le=V[2],de=V[3],W=function(De){var nt=[0,1,2].map(function(tt){return(1-De)*(1-De)*(1-De)*X[tt]+3*(1-De)*(1-De)*De*z[tt]+3*(1-De)*De*De*le[tt]+De*De*De*de[tt]});return new zs(nt,"lab")}}else if(p.length>=5){var we,He,Qe;we=p.map(function(De){return De.lab()}),Qe=p.length-1,He=G7(Qe),W=function(De){var nt=1-De,tt=[0,1,2].map(function(Et){return we.reduce(function(Lt,Dt,Zt){return Lt+He[Zt]*Math.pow(nt,Qe-Zt)*Math.pow(De,Zt)*Dt[Et]},0)});return new zs(tt,"lab")}}else throw new RangeError("No point in running bezier with only one color.");return W},X7=function(p){var w=J7(p);return w.scale=function(){return K7(w)},w},v2=F,Pn=function(p,w,A){if(!Pn[A])throw new Error("unknown blend mode "+A);return Pn[A](p,w)},Vr=function(p){return function(w,A){var V=v2(A).rgb(),W=v2(w).rgb();return v2.rgb(p(V,W))}},Or=function(p){return function(w,A){var V=[];return V[0]=p(w[0],A[0]),V[1]=p(w[1],A[1]),V[2]=p(w[2],A[2]),V}},Y7=function(p){return p},Q7=function(p,w){return p*w/255},e9=function(p,w){return p>w?w:p},t9=function(p,w){return p>w?p:w},a9=function(p,w){return 255*(1-(1-p/255)*(1-w/255))},n9=function(p,w){return w<128?2*p*w/255:255*(1-2*(1-p/255)*(1-w/255))},r9=function(p,w){return 255*(1-(1-w/255)/(p/255))},o9=function(p,w){return p===255?255:(p=255*(w/255)/(1-p/255),p>255?255:p)};Pn.normal=Vr(Or(Y7)),Pn.multiply=Vr(Or(Q7)),Pn.screen=Vr(Or(a9)),Pn.overlay=Vr(Or(n9)),Pn.darken=Vr(Or(e9)),Pn.lighten=Vr(Or(t9)),Pn.dodge=Vr(Or(o9)),Pn.burn=Vr(Or(r9));for(var s9=Pn,g2=g.type,i9=g.clip_rgb,l9=g.TWOPI,c9=Math.pow,d9=Math.sin,u9=Math.cos,Eu=F,h9=function(p,w,A,V,W){p===void 0&&(p=300),w===void 0&&(w=-1.5),A===void 0&&(A=1),V===void 0&&(V=1),W===void 0&&(W=[0,1]);var X=0,z;g2(W)==="array"?z=W[1]-W[0]:(z=0,W=[W,W]);var le=function(de){var we=l9*((p+120)/360+w*de),He=c9(W[0]+z*de,V),Qe=X!==0?A[0]+de*X:A,De=Qe*He*(1-He)/2,nt=u9(we),tt=d9(we),Et=He+De*(-.14861*nt+1.78277*tt),Lt=He+De*(-.29227*nt-.90649*tt),Dt=He+De*(1.97294*nt);return Eu(i9([Et*255,Lt*255,Dt*255,1]))};return le.start=function(de){return de==null?p:(p=de,le)},le.rotations=function(de){return de==null?w:(w=de,le)},le.gamma=function(de){return de==null?V:(V=de,le)},le.hue=function(de){return de==null?A:(A=de,g2(A)==="array"?(X=A[1]-A[0],X===0&&(A=A[1])):X=0,le)},le.lightness=function(de){return de==null?W:(g2(de)==="array"?(W=de,z=de[1]-de[0]):(W=[de,de],z=0),le)},le.scale=function(){return Eu.scale(le)},le.hue(A),le},p9=S,f9="0123456789abcdef",m9=Math.floor,v9=Math.random,g9=function(){for(var p="#",w=0;w<6;w++)p+=f9.charAt(m9(v9()*16));return new p9(p,"hex")},y2=c,Iu=Math.log,y9=Math.pow,M9=Math.floor,_9=Math.abs,ku=function(p,w){w===void 0&&(w=null);var A={min:Number.MAX_VALUE,max:Number.MAX_VALUE*-1,sum:0,values:[],count:0};return y2(p)==="object"&&(p=Object.values(p)),p.forEach(function(V){w&&y2(V)==="object"&&(V=V[w]),V!=null&&!isNaN(V)&&(A.values.push(V),A.sum+=V,V<A.min&&(A.min=V),V>A.max&&(A.max=V),A.count+=1)}),A.domain=[A.min,A.max],A.limits=function(V,W){return Tu(A,V,W)},A},Tu=function(p,w,A){w===void 0&&(w="equal"),A===void 0&&(A=7),y2(p)=="array"&&(p=ku(p));var V=p.min,W=p.max,X=p.values.sort(function(_2,b2){return _2-b2});if(A===1)return[V,W];var z=[];if(w.substr(0,1)==="c"&&(z.push(V),z.push(W)),w.substr(0,1)==="e"){z.push(V);for(var le=1;le<A;le++)z.push(V+le/A*(W-V));z.push(W)}else if(w.substr(0,1)==="l"){if(V<=0)throw new Error("Logarithmic scales are only possible for values > 0");var de=Math.LOG10E*Iu(V),we=Math.LOG10E*Iu(W);z.push(V);for(var He=1;He<A;He++)z.push(y9(10,de+He/A*(we-de)));z.push(W)}else if(w.substr(0,1)==="q"){z.push(V);for(var Qe=1;Qe<A;Qe++){var De=(X.length-1)*Qe/A,nt=M9(De);if(nt===De)z.push(X[nt]);else{var tt=De-nt;z.push(X[nt]*(1-tt)+X[nt+1]*tt)}}z.push(W)}else if(w.substr(0,1)==="k"){var Et,Lt=X.length,Dt=new Array(Lt),Zt=new Array(A),Oa=!0,Ta=0,en=null;en=[],en.push(V);for(var Rt=1;Rt<A;Rt++)en.push(V+Rt/A*(W-V));for(en.push(W);Oa;){for(var Be=0;Be<A;Be++)Zt[Be]=0;for(var vt=0;vt<Lt;vt++)for(var Tt=X[vt],It=Number.MAX_VALUE,Ha=void 0,ra=0;ra<A;ra++){var Bt=_9(en[ra]-Tt);Bt<It&&(It=Bt,Ha=ra),Zt[Ha]++,Dt[vt]=Ha}for(var Jt=new Array(A),Xt=0;Xt<A;Xt++)Jt[Xt]=null;for(var Qt=0;Qt<Lt;Qt++)Et=Dt[Qt],Jt[Et]===null?Jt[Et]=X[Qt]:Jt[Et]+=X[Qt];for(var Ln=0;Ln<A;Ln++)Jt[Ln]*=1/Zt[Ln];Oa=!1;for(var Hr=0;Hr<A;Hr++)if(Jt[Hr]!==en[Hr]){Oa=!0;break}en=Jt,Ta++,Ta>200&&(Oa=!1)}for(var Rr={},Xo=0;Xo<A;Xo++)Rr[Xo]=[];for(var Yo=0;Yo<Lt;Yo++)Et=Dt[Yo],Rr[Et].push(X[Yo]);for(var fr=[],po=0;po<A;po++)fr.push(Rr[po][0]),fr.push(Rr[po][Rr[po].length-1]);fr=fr.sort(function(_2,b2){return _2-b2}),z.push(fr[0]);for(var qs=1;qs<fr.length;qs+=2){var fo=fr[qs];!isNaN(fo)&&z.indexOf(fo)===-1&&z.push(fo)}}return z},Pu={analyze:ku,limits:Tu},Lu=S,b9=function(p,w){p=new Lu(p),w=new Lu(w);var A=p.luminance(),V=w.luminance();return A>V?(A+.05)/(V+.05):(V+.05)/(A+.05)},Vu=S,pr=Math.sqrt,Ma=Math.pow,w9=Math.min,x9=Math.max,Ou=Math.atan2,Hu=Math.abs,r1=Math.cos,Ru=Math.sin,C9=Math.exp,Nu=Math.PI,A9=function(p,w,A,V,W){A===void 0&&(A=1),V===void 0&&(V=1),W===void 0&&(W=1);var X=function(fo){return 360*fo/(2*Nu)},z=function(fo){return 2*Nu*fo/360};p=new Vu(p),w=new Vu(w);var le=Array.from(p.lab()),de=le[0],we=le[1],He=le[2],Qe=Array.from(w.lab()),De=Qe[0],nt=Qe[1],tt=Qe[2],Et=(de+De)/2,Lt=pr(Ma(we,2)+Ma(He,2)),Dt=pr(Ma(nt,2)+Ma(tt,2)),Zt=(Lt+Dt)/2,Oa=.5*(1-pr(Ma(Zt,7)/(Ma(Zt,7)+Ma(25,7)))),Ta=we*(1+Oa),en=nt*(1+Oa),Rt=pr(Ma(Ta,2)+Ma(He,2)),Be=pr(Ma(en,2)+Ma(tt,2)),vt=(Rt+Be)/2,Tt=X(Ou(He,Ta)),It=X(Ou(tt,en)),Ha=Tt>=0?Tt:Tt+360,ra=It>=0?It:It+360,Bt=Hu(Ha-ra)>180?(Ha+ra+360)/2:(Ha+ra)/2,Jt=1-.17*r1(z(Bt-30))+.24*r1(z(2*Bt))+.32*r1(z(3*Bt+6))-.2*r1(z(4*Bt-63)),Xt=ra-Ha;Xt=Hu(Xt)<=180?Xt:ra<=Ha?Xt+360:Xt-360,Xt=2*pr(Rt*Be)*Ru(z(Xt)/2);var Qt=De-de,Ln=Be-Rt,Hr=1+.015*Ma(Et-50,2)/pr(20+Ma(Et-50,2)),Rr=1+.045*vt,Xo=1+.015*vt*Jt,Yo=30*C9(-Ma((Bt-275)/25,2)),fr=2*pr(Ma(vt,7)/(Ma(vt,7)+Ma(25,7))),po=-fr*Ru(2*z(Yo)),qs=pr(Ma(Qt/(A*Hr),2)+Ma(Ln/(V*Rr),2)+Ma(Xt/(W*Xo),2)+po*(Ln/(V*Rr))*(Xt/(W*Xo)));return x9(0,w9(100,qs))},Du=S,S9=function(p,w,A){A===void 0&&(A="lab"),p=new Du(p),w=new Du(w);var V=p.get(A),W=w.get(A),X=0;for(var z in V){var le=(V[z]||0)-(W[z]||0);X+=le*le}return Math.sqrt(X)},$9=S,E9=function(){for(var p=[],w=arguments.length;w--;)p[w]=arguments[w];try{return new(Function.prototype.bind.apply($9,[null].concat(p))),!0}catch{return!1}},Bu=F,Fu=m2,I9={cool:function(){return Fu([Bu.hsl(180,1,.9),Bu.hsl(250,.7,.4)])},hot:function(){return Fu(["#000","#f00","#ff0","#fff"]).mode("rgb")}},o1={OrRd:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#b30000","#7f0000"],PuBu:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#045a8d","#023858"],BuPu:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#810f7c","#4d004b"],Oranges:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#a63603","#7f2704"],BuGn:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#006d2c","#00441b"],YlOrBr:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#993404","#662506"],YlGn:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#006837","#004529"],Reds:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#a50f15","#67000d"],RdPu:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177","#49006a"],Greens:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#006d2c","#00441b"],YlGnBu:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#253494","#081d58"],Purples:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#54278f","#3f007d"],GnBu:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#0868ac","#084081"],Greys:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525","#000000"],YlOrRd:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"],PuRd:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#980043","#67001f"],Blues:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#08519c","#08306b"],PuBuGn:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016c59","#014636"],Viridis:["#440154","#482777","#3f4a8a","#31678e","#26838f","#1f9d8a","#6cce5a","#b6de2b","#fee825"],Spectral:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],RdYlGn:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"],RdBu:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"],PiYG:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"],PRGn:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"],RdYlBu:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"],BrBG:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"],RdGy:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"],PuOr:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"],Set2:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494","#b3b3b3"],Accent:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17","#666666"],Set1:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf","#999999"],Set3:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5","#ffed6f"],Dark2:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d","#666666"],Paired:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99","#b15928"],Pastel2:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc","#cccccc"],Pastel1:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec","#f2f2f2"]},M2=0,ju=Object.keys(o1);M2<ju.length;M2+=1){var Uu=ju[M2];o1[Uu.toLowerCase()]=o1[Uu]}var k9=o1,ka=F;ka.average=z7,ka.bezier=X7,ka.blend=s9,ka.cubehelix=h9,ka.mix=ka.interpolate=Mu,ka.random=g9,ka.scale=m2,ka.analyze=Pu.analyze,ka.contrast=b9,ka.deltaE=A9,ka.distance=S9,ka.limits=Pu.limits,ka.valid=E9,ka.scales=I9,ka.colors=tu,ka.brewer=k9;var T9=ka;return T9})})(Eg);var nre=Eg.exports;const Ig=E0(nre),rre=["onClick"],ore=["data-writer-tooltip"],sre={key:1,class:"CoreTags__tag CoreTags__tag--empty"},ire=`
8295
8295
  def handle_tag_click(state, payload):
8296
- state["selected_tag_id"] = payload`,lre="A component to display coloured tag pills.",cre={writer:{name:"Tags",description:lre,category:"Content",fields:{tags:{name:"Tags",desc:"Key-value object with tags. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:"{}"},referenceColor:{name:"Reference",desc:"The colour to be used as reference for chroma and luminance, and as the starting point for hue rotation.",type:Q.Color,default:Ht.Blue5,category:ot.Style},seed:{name:"Seed value",desc:"Choose a different value to reshuffle colours.",type:Q.Number,default:"1",category:ot.Style},rotateHue:Ut({name:"Rotate hue",desc:"If active, rotates the hue depending on the content of the string. If turned off, the reference colour is always used.",default:"yes",category:ot.Style}),primaryTextColor:ua,cssClasses:mt},events:{"wf-tag-click":{desc:"Triggered when a tag is clicked.",stub:ire.trim(),eventPayloadExample:"tagKey"}},previewField:"text"}},dre=$e({...cre,__name:"CoreTags",setup(e){ji(h=>({"89f17936":l.value?"pointer":"auto"}));const t=[{h:-78,s:-34,l:16},{h:-61,s:-37,l:16},{h:-2,s:0,l:24},{h:-12,s:0,l:29},{h:28,s:-20,l:24},{h:-61,s:-95,l:25},{h:-173,s:0,l:16},{h:-228,s:0,l:22},{h:69,s:0,l:25},{h:70,s:0,l:29}],a=pt("rootEl"),n=re(ne.evaluatedFields),r=re(ne.componentId),o=re(ne.core),s=re(ne.isBeingEdited),{isLinked:i}=mg(o,r,"wf-tag-click"),l=H(()=>{var f;return i.value?!0:typeof((f=o.getComponentById(r).handlers)==null?void 0:f["wf-tag-click"])<"u"});function c(h){if(!n.rotateHue.value)return n.referenceColor.value;const f=Ig(n.referenceColor.value),m=t[d(h)];return f.set("hsl.h",`${Math.sign(m.h)==-1?"-":"+"}${Math.abs(m.h)}`).set("hsl.s",`${Math.sign(m.s)==-1?"-":"+"}${Math.abs(m.s/100)}`).set("hsl.l",`${Math.sign(m.l)==-1?"-":"+"}${Math.abs(m.l/100)}`).css()}function d(h){let f=n.seed.value*52673&4294967295;for(let g=0;g<h.length;g++)f=(g+1)*h.charCodeAt(g)^f&4294967295;return Math.abs(f)%t.length}function u(h){const f=new CustomEvent("wf-tag-click",{detail:{payload:h}});a.value.dispatchEvent(f)}return(h,f)=>E(s)||Object.entries(E(n).tags.value??[]).length>0?($(),R("div",{key:0,ref_key:"rootEl",ref:a,class:"CoreTags"},[Object.entries(E(n).tags.value??[]).length>0?($(!0),R(Je,{key:0},Ot(E(n).tags.value,(m,g)=>($(),R("p",{key:g,class:"CoreTags__tag",style:bt({background:c(g)}),onClick:_=>u(g)},[Z("span",{"data-writer-tooltip":m,"data-writer-tooltip-strategy":"overflow"},je(m),9,ore)],12,rre))),128)):($(),R("p",sre,f[0]||(f[0]=[Z("span",null,"Empty Tags",-1)])))],512)):ge("",!0)}}),ure=ke(dre,[["__scopeId","data-v-b71b9399"]]),hre={class:"info"},pre={key:1,class:"caption"},fre={class:"container","data-writer-container":""},mre=`
8296
+ state["selected_tag_id"] = payload`,lre="A component to display coloured tag pills.",cre={writer:{name:"Tags",description:lre,category:"Content",fields:{tags:{name:"Tags",desc:"Key-value object with tags. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:"{}"},referenceColor:{name:"Reference",desc:"The colour to be used as reference for chroma and luminance, and as the starting point for hue rotation.",type:Q.Color,default:Ht.Blue5,category:ot.Style},seed:{name:"Seed value",desc:"Choose a different value to reshuffle colours.",type:Q.Number,default:"1",category:ot.Style},rotateHue:Ut({name:"Rotate hue",desc:"If active, rotates the hue depending on the content of the string. If turned off, the reference colour is always used.",default:"yes",category:ot.Style}),primaryTextColor:ua,cssClasses:mt},events:{"wf-tag-click":{desc:"Triggered when a tag is clicked.",stub:ire.trim(),eventPayloadExample:"tagKey"}},previewField:"text"}},dre=$e({...cre,__name:"CoreTags",setup(e){ji(h=>({"89f17936":l.value?"pointer":"auto"}));const t=[{h:-78,s:-34,l:16},{h:-61,s:-37,l:16},{h:-2,s:0,l:24},{h:-12,s:0,l:29},{h:28,s:-20,l:24},{h:-61,s:-95,l:25},{h:-173,s:0,l:16},{h:-228,s:0,l:22},{h:69,s:0,l:25},{h:70,s:0,l:29}],a=pt("rootEl"),n=re(ne.evaluatedFields),r=re(ne.componentId),o=re(ne.core),s=re(ne.isBeingEdited),{isLinked:i}=mg(o,r,"wf-tag-click"),l=H(()=>{var f;return i.value?!0:typeof((f=o.getComponentById(r).handlers)==null?void 0:f["wf-tag-click"])<"u"});function c(h){if(!n.rotateHue.value)return n.referenceColor.value;const f=Ig(n.referenceColor.value),m=t[d(h)];return f.set("hsl.h",`${Math.sign(m.h)==-1?"-":"+"}${Math.abs(m.h)}`).set("hsl.s",`${Math.sign(m.s)==-1?"-":"+"}${Math.abs(m.s/100)}`).set("hsl.l",`${Math.sign(m.l)==-1?"-":"+"}${Math.abs(m.l/100)}`).css()}function d(h){let f=n.seed.value*52673&4294967295;for(let g=0;g<h.length;g++)f=(g+1)*h.charCodeAt(g)^f&4294967295;return Math.abs(f)%t.length}function u(h){const f=new CustomEvent("wf-tag-click",{detail:{payload:h}});a.value.dispatchEvent(f)}return(h,f)=>E(s)||Object.entries(E(n).tags.value??[]).length>0?($(),R("div",{key:0,ref_key:"rootEl",ref:a,class:"CoreTags"},[Object.entries(E(n).tags.value??[]).length>0?($(!0),R(Je,{key:0},Ot(E(n).tags.value,(m,g)=>($(),R("p",{key:g,class:"CoreTags__tag",style:wt({background:c(g)}),onClick:_=>u(g)},[Z("span",{"data-writer-tooltip":m,"data-writer-tooltip-strategy":"overflow"},je(m),9,ore)],12,rre))),128)):($(),R("p",sre,f[0]||(f[0]=[Z("span",null,"Empty Tags",-1)])))],512)):ge("",!0)}}),ure=ke(dre,[["__scopeId","data-v-b71b9399"]]),hre={class:"info"},pre={key:1,class:"caption"},fre={class:"container","data-writer-container":""},mre=`
8297
8297
  def handle_avatar_click():
8298
- print("The avatar was clicked")`,vre="A component to display user avatars.",gre={writer:{deprecated:!0,name:"Avatar",description:vre,category:"Content",allowedChildrenTypes:["*"],fields:{name:{name:"Name",type:Q.Text},imageSrc:{name:"Image source",desc:"A valid URL. Alternatively, you can provide a state reference to a packed file.",type:Q.Text},caption:{name:"Caption",desc:"Add an optional caption under the name, such as the person's job title.",type:Q.Text},size:{name:"Size",type:Q.Text,options:{small:"Small",medium:"Medium",large:"Large"},default:"medium",category:ot.Style},orientation:{name:"Orientation",type:Q.Text,options:{horizontal:"Horizontal",vertical:"Vertical"},default:"horizontal",category:ot.Style},primaryTextColor:ua,secondaryTextColor:In,separatorColor:wa,cssClasses:mt},events:{"wf-click":{desc:"Triggered when the avatar is clicked.",stub:mre.trim()}},previewField:"text"}},yre=$e({...gre,__name:"CoreAvatar",setup(e){ji(l=>({"220148ac":o.value?"pointer":"auto"}));const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.componentId),r=re(ne.core),o=H(()=>{var c;return typeof((c=r.getComponentById(n).handlers)==null?void 0:c["wf-click"])<"u"}),s=H(()=>({backgroundImage:a.imageSrc.value?`url(${a.imageSrc.value})`:"none",cursor:o.value?"pointer":"auto"}));function i(l){const c=Zi(l);t.value.dispatchEvent(c)}return(l,c)=>($(),R("div",{ref_key:"rootEl",ref:t,class:ft(["CoreAvatar",[E(a).size.value,E(a).orientation.value]])},[Z("div",{class:"image",style:bt(s.value),onClick:i},[E(a).imageSrc.value?ge("",!0):($(),Ie(_t,{key:0,name:"circle-user-round"}))],4),Z("div",hre,[E(a).name.value?($(),R("div",{key:0,class:"name",onClick:i},je(E(a).name.value),1)):ge("",!0),E(a).caption.value?($(),R("div",pre,je(E(a).caption.value),1)):ge("",!0),Z("div",fre,[qt(l.$slots,"default",{},void 0,!0)])])],2))}}),Mre=ke(yre,[["__scopeId","data-v-1a2cbd13"]]),_re={key:0,class:"CoreAnnotatedText__annotation__subject"},bre={writer:{name:"Annotated text",description:"Shows text with annotations",category:"Content",fields:{text:{name:"Annotated text",type:Q.Object,desc:"Value array with text/annotations. Must be a JSON string or a state reference to an array.",init:`["This ",["is", "Verb"]," some ",["annotated", "Adjective"], ["text", "Noun"]," for those of ",["you", "Pronoun"]," who ",["like", "Verb"]," this sort of ",["thing", "Noun"],". ","And here's a ",["word", "", "#faf"]," with a fancy background but no label."]`,validator:KE},referenceColor:{name:"Reference",desc:"The colour to be used as reference for chroma and luminance, and as the starting point for hue rotation.",type:Q.Color,default:Ht.Blue5,category:ot.Style},seed:{name:"Seed value",desc:"Choose a different value to reshuffle colours.",type:Q.Number,default:"1",category:ot.Style},rotateHue:Ut({name:"Rotate hue",desc:"If active, rotates the hue depending on the content of the string. If turned off, the reference colour is always used.",default:"yes",category:ot.Style}),useMarkdown:Ut({name:"Enable markdown",desc:"If active, the output will be sanitized; unsafe elements will be removed.",default:"no"}),copyButtons:xd({default:"no"}),buttonColor:cr,buttonTextColor:dr,primaryTextColor:ua,cssClasses:mt},previewField:"data"}},wre=$e({...bre,__name:"CoreAnnotatedText",setup(e){const t=sr({loader:()=>zt(()=>import("./SharedCopyClipboardButton-BAhxC5LU.js"),__vite__mapDeps([3,4,5,6,7,8]),import.meta.url)}),a=re(ne.evaluatedFields),n=H(()=>a.text.value??[]),r=re(ne.isBeingEdited),o=re(ne.componentId),s=H(()=>!a.text.value),i=H(()=>!s.value||r.value),l=H(()=>!!a.useMarkdown.value),c=[{h:-78,s:-34,l:16},{h:-61,s:-37,l:16},{h:-2,s:0,l:24},{h:-12,s:0,l:29},{h:28,s:-20,l:24},{h:-61,s:-95,l:25},{h:-173,s:0,l:16},{h:-228,s:0,l:22},{h:69,s:0,l:25},{h:70,s:0,l:29}];let d=[...c],u={},h=a.seed.value;function f(){const S=ye("");We([l,n],async()=>{if(!l.value)return S.value="";S.value=await F()},{immediate:!0});function L(te){const[J,be]=te,oe=be?`<span class="CoreAnnotatedText__annotation__subject">${be}</span>`:"";return`<span class="CoreAnnotatedText__annotation" style="background: ${b(te)}">${J}${oe}</span>`}async function F(){const te=n.value.reduce((be,oe)=>typeof oe=="string"?`${be} ${oe}`:Array.isArray(oe)?`${be} ${L(oe)}`:be,"");return await(await zt(()=>import("./marked.esm-273vDTCT.js"),[],import.meta.url)).parse(te)}return jt(S)}const m=f();function g(S,L){return S.set("hsl.h",`${Math.sign(L.h)==-1?"-":"+"}${Math.abs(L.h)}`).set("hsl.s",`${Math.sign(L.s)==-1?"-":"+"}${Math.abs(L.s/100)}`).set("hsl.l",`${Math.sign(L.l)==-1?"-":"+"}${Math.abs(L.l/100)}`).css()}function _(S,L=c.length){let F=a.seed.value*52673&4294967295;for(let J=0;J<S.length;J++)F=(J+1)*S.charCodeAt(J)^F&4294967295;return Math.abs(F)%L}function b(S){return S[2]||v(S[1])}function v(S){if(!a.rotateHue.value)return a.referenceColor.value;const L=Ig(a.referenceColor.value);if(h!==a.seed.value&&(d=[...c],u={},h=a.seed.value),u[S])return g(L,u[S]);d.length===0&&(d=[...c]);const F=_(S,d.length),te=d[F];return u[S]=te,d.splice(F,1),g(L,te)}const y=H(()=>n.value.reduce((S,L)=>typeof L=="string"?S+L:S+L[0],"")),M=H(()=>{try{return JSON.stringify(n.value)}catch{return n.value.join("")}}),x=H(()=>[{label:"Copy text",value:y.value},{label:"Copy JSON",value:M.value}]);return(S,L)=>i.value?($(),Ie($d,{key:0,class:"CoreAnnotatedText"},{actions:Xe(()=>[E(a).copyButtons.value?($(),Ie(E(t),{key:0,options:x.value},null,8,["options"])):ge("",!0)]),default:Xe(()=>[l.value?($(),Ie(Z3,{key:0,"raw-markdown":E(m),class:"CoreAnnotatedText__markdown"},null,8,["raw-markdown"])):($(),R(Je,{key:1},[s.value?($(),Ie(Sd,{key:0,"component-id":E(o)},null,8,["component-id"])):ge("",!0),($(!0),R(Je,null,Ot(n.value,(F,te)=>($(),R("span",{key:String(F)+te},[typeof F=="string"?($(),R(Je,{key:0},[pa(je(F),1)],64)):ge("",!0),Array.isArray(F)?($(),R("span",{key:1,class:"CoreAnnotatedText__annotation",style:bt({backgroundColor:b(F)})},[pa(je(F[0])+" ",1),F[1]?($(),R("span",_re,je(F[1]),1)):ge("",!0)],4)):ge("",!0)]))),128))],64))]),_:1})):ge("",!0)}}),xre=ke(wre,[["__scopeId","data-v-a540a40b"]]);function kg(e){return wl()?(Xc(e),!0):!1}const Wl=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Cre=Object.prototype.toString,Are=e=>Cre.call(e)==="[object Object]";function Sre(e){let t;function a(){return t||(t=e()),t}return a.reset=async()=>{const n=t;t=void 0,n&&await n},a}function X2(e){return Array.isArray(e)?e:[e]}function $re(e,t,a={}){const{immediate:n=!0,immediateCallback:r=!1}=a,o=$t(!1);let s;function i(){s&&(clearTimeout(s),s=void 0)}function l(){o.value=!1,i()}function c(...d){r&&e(),i(),o.value=!0,s=setTimeout(()=>{o.value=!1,s=void 0,e(...d)},Pa(t))}return n&&(o.value=!0,Wl&&c()),kg(l),{isPending:Fr(o),start:c,stop:l}}function Ere(e,t,a){return We(e,t,{...a,immediate:!0})}const Ire=Wl?window:void 0,Tg=Wl?window.navigator:void 0;function kre(e){var t;const a=Pa(e);return(t=a==null?void 0:a.$el)!=null?t:a}function is(...e){const t=[],a=()=>{t.forEach(i=>i()),t.length=0},n=(i,l,c,d)=>(i.addEventListener(l,c,d),()=>i.removeEventListener(l,c,d)),r=H(()=>{const i=X2(Pa(e[0])).filter(l=>l!=null);return i.every(l=>typeof l!="string")?i:void 0}),o=Ere(()=>{var i,l;return[(l=(i=r.value)==null?void 0:i.map(c=>kre(c)))!=null?l:[Ire].filter(c=>c!=null),X2(Pa(r.value?e[1]:e[0])),X2(E(r.value?e[2]:e[1])),Pa(r.value?e[3]:e[2])]},([i,l,c,d])=>{if(a(),!(i!=null&&i.length)||!(l!=null&&l.length)||!(c!=null&&c.length))return;const u=Are(d)?{...d}:d;t.push(...i.flatMap(h=>l.flatMap(f=>c.map(m=>n(h,f,m,u)))))},{flush:"post"}),s=()=>{o(),a()};return kg(a),s}function Tre(){const e=$t(!1),t=gn();return t&&ia(()=>{e.value=!0},t),e}function Pg(e){const t=Tre();return H(()=>(t.value,!!e()))}function pm(e,t={}){const{controls:a=!1,navigator:n=Tg}=t,r=Pg(()=>n&&"permissions"in n),o=$t(),s=typeof e=="string"?{name:e}:e,i=$t(),l=()=>{var d,u;i.value=(u=(d=o.value)==null?void 0:d.state)!=null?u:"prompt"};is(o,"change",l,{passive:!0});const c=Sre(async()=>{if(r.value){if(!o.value)try{o.value=await n.permissions.query(s)}catch{o.value=void 0}finally{l()}if(a)return St(o.value)}});return c(),a?{state:i,isSupported:r,query:c}:i}function Lg(e={}){const{navigator:t=Tg,read:a=!1,source:n,copiedDuring:r=1500,legacy:o=!1}=e,s=Pg(()=>t&&"clipboard"in t),i=pm("clipboard-read"),l=pm("clipboard-write"),c=H(()=>s.value||o),d=$t(""),u=$t(!1),h=$re(()=>u.value=!1,r,{immediate:!1});async function f(){let v=!(s.value&&b(i.value));if(!v)try{d.value=await t.clipboard.readText()}catch{v=!0}v&&(d.value=_())}c.value&&a&&is(["copy","cut"],f,{passive:!0});async function m(v=Pa(n)){if(c.value&&v!=null){let y=!(s.value&&b(l.value));if(!y)try{await t.clipboard.writeText(v)}catch{y=!0}y&&g(v),d.value=v,u.value=!0,h.start()}}function g(v){const y=document.createElement("textarea");y.value=v??"",y.style.position="absolute",y.style.opacity="0",document.body.appendChild(y),y.select(),document.execCommand("copy"),y.remove()}function _(){var v,y,M;return(M=(y=(v=document==null?void 0:document.getSelection)==null?void 0:v.call(document))==null?void 0:y.toString())!=null?M:""}function b(v){return v==="granted"||v==="prompt"}return{isSupported:c,text:d,copied:u,copy:m}}function Pre(e,t={}){var a,n;const r=$t(!1),o=$t(null);let s=0,i=!0;if(Wl){const l=typeof t=="function"?{onDrop:t}:t,c=(a=l.multiple)!=null?a:!0,d=(n=l.preventDefaultForUnhandled)!=null?n:!1,u=_=>{var b,v;const y=Array.from((v=(b=_.dataTransfer)==null?void 0:b.files)!=null?v:[]);return y.length===0?null:c?y:[y[0]]},h=_=>{const b=E(l.dataTypes);return typeof b=="function"?b(_):b!=null&&b.length?_.length===0?!1:_.every(v=>b.some(y=>v.includes(y))):!0},f=_=>{const b=Array.from(_??[]).map(M=>M.type),v=h(b),y=c||_.length<=1;return v&&y},m=()=>/^(?:(?!chrome|android).)*safari/i.test(navigator.userAgent)&&!("chrome"in window),g=(_,b)=>{var v,y,M,x,S,L;const F=(v=_.dataTransfer)==null?void 0:v.items;if(i=(y=F&&f(F))!=null?y:!1,d&&_.preventDefault(),!m()&&!i){_.dataTransfer&&(_.dataTransfer.dropEffect="none");return}_.preventDefault(),_.dataTransfer&&(_.dataTransfer.dropEffect="copy");const te=u(_);switch(b){case"enter":s+=1,r.value=!0,(M=l.onEnter)==null||M.call(l,null,_);break;case"over":(x=l.onOver)==null||x.call(l,null,_);break;case"leave":s-=1,s===0&&(r.value=!1),(S=l.onLeave)==null||S.call(l,null,_);break;case"drop":s=0,r.value=!1,i&&(o.value=te,(L=l.onDrop)==null||L.call(l,te,_));break}};is(e,"dragenter",_=>g(_,"enter")),is(e,"dragover",_=>g(_,"over")),is(e,"dragleave",_=>g(_,"leave")),is(e,"drop",_=>g(_,"drop"))}return{files:o,isOverDropZone:r}}function Zl(e){return!!(["string","number","boolean"].includes(typeof e)||e===null)}function Vg(e){return Zl(e)?!1:Array.isArray(e)}function Og(e){return Tr(e)}function Hg(e){return Zl(e)?1:Object.keys(e).length}function Rg(e){return typeof e.open=="boolean"&&Array.isArray(e.path)}const Lre=["open","disabled"],Vre={class:"SharedCollapsible__summary"},Ore={class:"content"},Hre=$e({__name:"SharedCollapsible",props:{open:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},icons:{type:Object,required:!1,default:void 0}},emits:{toggle:e=>typeof e=="boolean"},setup(e,{emit:t}){const a=e,n=t,r=ye(a.open);We(mn(a,"open"),i=>r.value=i);const o=H(()=>{if(a.icons!==void 0)return r.value?a.icons.open:a.icons.close});function s(i){const l=i.newState==="open";r.value=l,n("toggle",l)}return(i,l)=>($(),R("details",{class:ft(["SharedCollapsible",{"SharedCollapsible--customMarker":e.icons}]),open:r.value,disabled:e.disabled,onToggle:s},[Z("summary",Vre,[e.icons?($(),Ie(_t,{key:0,name:o.value},null,8,["name"])):ge("",!0),qt(i.$slots,"title",{},void 0,!0)]),Z("div",Ore,[qt(i.$slots,"content",{},void 0,!0)])],42,Lre))}}),Rre=ke(Hre,[["__scopeId","data-v-e02188e5"]]),Nre=$e({__name:"SharedJsonViewerChildrenCounter",props:{data:{type:[String,Number,Boolean,Object,Array,null],required:!0}},setup(e){const t=e,a=o=>`Object{${o}}`,n=o=>`Array[${o}]`,r=H(()=>{const o=Hg(t.data);return o===0?a(0):Vg(t.data)?n(o):Og(t.data)?a(o):a(0)});return(o,s)=>($(),R("span",null,je(r.value),1))}}),Ng=ke(Nre,[["__scopeId","data-v-2641ae29"]]),Dre={class:"SharedJsonViewerCollapsible__title"},Bre={key:0},Fre={class:"SharedJsonViewerCollapsible__content"},jre=$e({__name:"SharedJsonViewerCollapsible",props:{open:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},title:{type:String,required:!1,default:void 0},data:{type:[String,Number,Boolean,Object,Array,null],required:!1,default:void 0}},emits:{toggle:e=>typeof e=="boolean"},setup(e){return(t,a)=>($(),Ie(Rre,{open:e.open,disabled:e.disabled,icons:{close:"chevron-right",open:"chevron-down"},onToggle:a[0]||(a[0]=n=>t.$emit("toggle",n))},{title:Xe(()=>[Z("div",Dre,[e.title?($(),R("span",Bre,je(e.title),1)):ge("",!0),e.data?($(),Ie(Ng,{key:1,data:e.data},null,8,["data"])):ge("",!0)])]),content:Xe(()=>[Z("div",Fre,[qt(t.$slots,"default",{},void 0,!0)])]),_:3},8,["open","disabled"]))}}),Dg=ke(jre,[["__scopeId","data-v-f7561f2f"]]),Ure={class:"SharedJsonViewerValue"},zre=$e({__name:"SharedJsonViewerValue",props:{data:{type:[String,Number,Boolean,Object,Array,null],required:!0},maxValueLength:{type:Number,default:1e3}},setup(e){const t=e,a=H(()=>{const n=JSON.stringify(t.data);return n.length<=t.maxValueLength?n:`${n.slice(0,t.maxValueLength)}..."`});return(n,r)=>($(),R("span",Ure,je(a.value),1))}}),Bg=ke(zre,[["__scopeId","data-v-6842c28f"]]),qre={class:"SharedJsonViewerObject"},Wre={key:0,class:"SharedJsonViewerObject__value"},Zre=$e({__name:"SharedJsonViewerObject",props:{data:{type:[Object,Array],required:!0},path:{type:Array,default:()=>[]},initialDepth:{type:Number,default:0}},emits:{toggle:Rg},setup(e,{emit:t}){const a=e,n=mn(a,"initialDepth"),r=t,o=ye([]),s=H(()=>a.path.length+1);We(n,()=>{if(n.value===0){o.value=[];return}if(!(n.value===-1||n.value>s.value))return;const d=new Set([...o.value,...Object.keys(a.data)]);o.value=Array.from(d)},{immediate:!0});function i(c,d){d?o.value=[...o.value,c]:o.value=o.value.filter(u=>u!==c),r("toggle",{open:d,path:[...a.path,c]})}function l(c){return o.value.includes(String(c))}return(c,d)=>($(),R("div",qre,[($(!0),R(Je,null,Ot(Object.entries(e.data),([u,h],f)=>($(),R(Je,{key:f},[E(Zl)(h)||E(Hg)(h)===0?($(),R("div",Wre,[Z("span",null,je(u),1),d[1]||(d[1]=pa(": ")),Ce(Bg,{data:h},null,8,["data"])])):($(),Ie(Dg,{key:1,open:l(u),title:u,data:h,onToggle:m=>i(u,m)},{default:Xe(()=>[l(u)?($(),Ie(jg,{key:0,data:h,path:[...e.path,u],"initial-depth":n.value,onToggle:d[0]||(d[0]=m=>c.$emit("toggle",m))},null,8,["data","path","initial-depth"])):ge("",!0)]),_:2},1032,["open","title","data","onToggle"]))],64))),128))]))}}),fm=ke(Zre,[["__scopeId","data-v-72c975d1"]]);function Fg(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Kre(e,t){return t.search(new RegExp(`(^|\\n)\\s*"?${Fg(e)}"?\\s*:\\s*`))}function Gre(e,t){return t.search(new RegExp(`(^|\\n)\\s*"?${Fg(e)}"?\\s*(\\n\\s*)?(Object\\{\\d+\\}|Array\\[\\d+\\])`))}function Jre(e,t){const a=[];return Object.keys(e).forEach(n=>{const r=Kre(n,t);r!==-1&&a.push({type:"key-value",key:n,index:r});const o=Gre(n,t);o!==-1&&a.push({type:"collapsed",key:n,index:o})}),a.sort((n,r)=>n.index-r.index),a}function Xre(e,t,a){const n=new Map;Object.entries(e).forEach(([o,s])=>{n.set(o,Tr(s)?new Set(Object.keys(s)):new Set)});const r=[];return a.forEach((o,s)=>{if(o.type!=="collapsed")return;const i=n.get(o.key)??new Set;let l=t.length;for(let c=s+1;c<a.length;c++){const d=a[c];if(!(d.index<=o.index)){if(d.type==="collapsed"){l=d.index;break}if(d.type==="key-value"&&!i.has(d.key)){l=d.index;break}}}r.push({key:o.key,startIndex:o.index,endIndex:l})}),r}function Yre(e,t){const a=new Set;return e.forEach(n=>{if(n.type!=="key-value")return;t.some(o=>n.index>=o.startIndex&&n.index<o.endIndex)||a.add(n.key)}),a}function Qre(e,t){return t.find(n=>n.key===e.key&&n.startIndex===e.index)??t.find(n=>n.key===e.key)??null}function Dc(e,t){const a=Jre(e,t),n=Xre(e,t,a),r=Yre(a,n),o={array:[],object:{}};function s(l,c){o.array.push(c),o.object[l]=c}a.forEach(l=>{if(l.key in o.object)return;const c=e[l.key];switch(l.type){case"key-value":{r.has(l.key)&&s(l.key,c);break}case"collapsed":{const d=Qre(l,n),u=d?t.slice(d.startIndex,d.endIndex):t;if(!Tr(c)){s(l.key,c);break}const h=Dc(c,u),f=h.array.length>0||Object.keys(h.object).length>0;s(l.key,f?h.object:c);break}}});const i=o.array.length===0||Object.keys(o.object).length===0;return a.length>0&&i&&Object.entries(e).forEach(([l,c])=>{s(l,c)}),{array:o.array,object:o.object,tokenCount:a.length}}function eoe(e,t){const a=t.replace(/\r\n/g,`
8299
- `);if(Tr(e)){const{object:n}=Dc(e,a);return n}if(Array.isArray(e)){const n={};e.forEach((i,l)=>{n[String(l)]=i});const{array:r,tokenCount:o}=Dc(n,a);if(r.length>0)return r;const s=/(^|\n)\s*Array\[\d+\]/;return o>0||s.test(a)?e.slice():[]}return{}}const jg=$e({__name:"SharedJsonViewer",props:{data:{type:[String,Number,Boolean,Object,Array,null],required:!0},path:{type:Array,default:()=>[]},hideRoot:{type:Boolean,required:!1},initialDepth:{type:Number,default:0},enableCopyToJson:{type:Boolean,required:!1}},emits:{toggle:Rg},setup(e){const t=sr({loader:()=>zt(()=>import("./SharedCopyClipboardButton-BAhxC5LU.js"),__vite__mapDeps([3,4,5,6,7,8]),import.meta.url)}),a=e,n=H(()=>a.path.length===0&&!a.hideRoot),r=H(()=>a.initialDepth===-1||a.initialDepth>0);function o(d){if(d===void 0)return JSON.stringify(null);try{return JSON.stringify(d,null,2)}catch{return JSON.stringify(null)}}const s=H(()=>o(a.data)),{copy:i}=Lg();function l(d){return Array.isArray(d)?d.length===0:Tr(d)?Object.keys(d).length===0:!1}function c(d,u){var m;d.stopPropagation();const h=(((m=window.getSelection())==null?void 0:m.toString())??"").trim();if(!h)return;const f=eoe(u,h);l(f)||(d.preventDefault(),i(o(f)))}return(d,u)=>($(),Ie($d,null,{actions:Xe(()=>[e.enableCopyToJson?($(),Ie(E(t),{key:0,label:"Copy JSON",value:s.value},null,8,["value"])):ge("",!0)]),default:Xe(()=>[E(Og)(e.data)||E(Vg)(e.data)?($(),R(Je,{key:0},[n.value?($(),Ie(Dg,{key:0,open:r.value,data:e.data,onToggle:u[1]||(u[1]=h=>d.$emit("toggle",{path:[],open:h})),onCopy:u[2]||(u[2]=h=>c(h,e.data))},{default:Xe(()=>[Ce(fm,{data:e.data,path:e.path,"initial-depth":e.initialDepth,onToggle:u[0]||(u[0]=h=>d.$emit("toggle",h))},null,8,["data","path","initial-depth"])]),_:1},8,["open","data"])):($(),Ie(fm,{key:1,data:e.data,path:e.path,"initial-depth":e.initialDepth,onToggle:u[3]||(u[3]=h=>d.$emit("toggle",h)),onCopy:u[4]||(u[4]=h=>c(h,e.data))},null,8,["data","path","initial-depth"]))],64)):E(Zl)(e.data)?($(),Ie(Bg,{key:1,data:e.data},null,8,["data"])):($(),Ie(Ng,{key:2,data:{}}))]),_:1}))}}),toe={class:"CoreJsonViewer"},aoe="A component to explore JSON data as a hierarchy.",noe={name:"JSON Viewer",description:"A JSON tree viewer where you can expand the keys.",sample:{description:"This sample is opened by default",bool:!0,null:null,list:[1,"two",{key:3}]},sampleClosed:{description:"This sample is not opened by default"},createdAt:new Date},roe={name:"JSON viewer",description:aoe,category:"Content",fields:{data:{name:"Data",init:JSON.stringify(noe),type:Q.Object},initialDepth:{name:"Initial depth",desc:"Sets the initial viewing depth of the JSON tree hierarchy. Use -1 to display the full hierarchy.",type:Q.Number,init:"0",validator:fn},hideRoot:Ut({name:"Hide root",desc:"Don't show the type of the root node when it's an Object or an Array.",default:"no",category:ot.Style}),copy:xd({default:"no"}),jsonViewerIndentationSpacing:{name:"JSON indentation",type:Q.Width,category:ot.Style,applyStyleVariable:!0,validator:ig},secondaryTextColor:In,separatorColor:wa,cssClasses:mt},previewField:"data"},ooe={writer:roe},soe=$e({...ooe,__name:"CoreJsonViewer",setup(e){const t=re(ne.evaluatedFields),a=H(()=>t.data.value),n=H(()=>Number(t.initialDepth.value)||0);return(r,o)=>($(),R("div",toe,[Ce(jg,{data:a.value??{},"initial-depth":n.value,"enable-copy-to-json":E(t).copy.value,"hide-root":E(t).hideRoot.value},null,8,["data","initial-depth","enable-copy-to-json","hide-root"])]))}});function ioe(e,t={minimumFractionDigits:0,maximumFractionDigits:1}){const a=new Intl.NumberFormat(void 0,{style:"percent",...t});return H(()=>a.format(e.value))}const loe=["aria-valuetext","aria-valuemin","aria-valuemax","aria-valuenow","aria-busy","tabindex"],coe={key:0,class:"CoreProgressBar__title"},doe={key:0,class:"CoreProgressBar__title__label"},uoe={key:1,class:"CoreProgressBar__title__progress"},hoe={class:"CoreProgressBar__bar"},poe=`
8298
+ print("The avatar was clicked")`,vre="A component to display user avatars.",gre={writer:{deprecated:!0,name:"Avatar",description:vre,category:"Content",allowedChildrenTypes:["*"],fields:{name:{name:"Name",type:Q.Text},imageSrc:{name:"Image source",desc:"A valid URL. Alternatively, you can provide a state reference to a packed file.",type:Q.Text},caption:{name:"Caption",desc:"Add an optional caption under the name, such as the person's job title.",type:Q.Text},size:{name:"Size",type:Q.Text,options:{small:"Small",medium:"Medium",large:"Large"},default:"medium",category:ot.Style},orientation:{name:"Orientation",type:Q.Text,options:{horizontal:"Horizontal",vertical:"Vertical"},default:"horizontal",category:ot.Style},primaryTextColor:ua,secondaryTextColor:In,separatorColor:wa,cssClasses:mt},events:{"wf-click":{desc:"Triggered when the avatar is clicked.",stub:mre.trim()}},previewField:"text"}},yre=$e({...gre,__name:"CoreAvatar",setup(e){ji(l=>({"220148ac":o.value?"pointer":"auto"}));const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.componentId),r=re(ne.core),o=H(()=>{var c;return typeof((c=r.getComponentById(n).handlers)==null?void 0:c["wf-click"])<"u"}),s=H(()=>({backgroundImage:a.imageSrc.value?`url(${a.imageSrc.value})`:"none",cursor:o.value?"pointer":"auto"}));function i(l){const c=Zi(l);t.value.dispatchEvent(c)}return(l,c)=>($(),R("div",{ref_key:"rootEl",ref:t,class:ft(["CoreAvatar",[E(a).size.value,E(a).orientation.value]])},[Z("div",{class:"image",style:wt(s.value),onClick:i},[E(a).imageSrc.value?ge("",!0):($(),Ie(bt,{key:0,name:"circle-user-round"}))],4),Z("div",hre,[E(a).name.value?($(),R("div",{key:0,class:"name",onClick:i},je(E(a).name.value),1)):ge("",!0),E(a).caption.value?($(),R("div",pre,je(E(a).caption.value),1)):ge("",!0),Z("div",fre,[qt(l.$slots,"default",{},void 0,!0)])])],2))}}),Mre=ke(yre,[["__scopeId","data-v-1a2cbd13"]]),_re={key:0,class:"CoreAnnotatedText__annotation__subject"},bre={writer:{name:"Annotated text",description:"Shows text with annotations",category:"Content",fields:{text:{name:"Annotated text",type:Q.Object,desc:"Value array with text/annotations. Must be a JSON string or a state reference to an array.",init:`["This ",["is", "Verb"]," some ",["annotated", "Adjective"], ["text", "Noun"]," for those of ",["you", "Pronoun"]," who ",["like", "Verb"]," this sort of ",["thing", "Noun"],". ","And here's a ",["word", "", "#faf"]," with a fancy background but no label."]`,validator:KE},referenceColor:{name:"Reference",desc:"The colour to be used as reference for chroma and luminance, and as the starting point for hue rotation.",type:Q.Color,default:Ht.Blue5,category:ot.Style},seed:{name:"Seed value",desc:"Choose a different value to reshuffle colours.",type:Q.Number,default:"1",category:ot.Style},rotateHue:Ut({name:"Rotate hue",desc:"If active, rotates the hue depending on the content of the string. If turned off, the reference colour is always used.",default:"yes",category:ot.Style}),useMarkdown:Ut({name:"Enable markdown",desc:"If active, the output will be sanitized; unsafe elements will be removed.",default:"no"}),copyButtons:xd({default:"no"}),buttonColor:dr,buttonTextColor:ur,primaryTextColor:ua,cssClasses:mt},previewField:"data"}},wre=$e({...bre,__name:"CoreAnnotatedText",setup(e){const t=ir({loader:()=>zt(()=>import("./SharedCopyClipboardButton-ed8bYNvB.js"),__vite__mapDeps([3,4,5,6,7,8]),import.meta.url)}),a=re(ne.evaluatedFields),n=H(()=>a.text.value??[]),r=re(ne.isBeingEdited),o=re(ne.componentId),s=H(()=>!a.text.value),i=H(()=>!s.value||r.value),l=H(()=>!!a.useMarkdown.value),c=[{h:-78,s:-34,l:16},{h:-61,s:-37,l:16},{h:-2,s:0,l:24},{h:-12,s:0,l:29},{h:28,s:-20,l:24},{h:-61,s:-95,l:25},{h:-173,s:0,l:16},{h:-228,s:0,l:22},{h:69,s:0,l:25},{h:70,s:0,l:29}];let d=[...c],u={},h=a.seed.value;function f(){const S=ye("");We([l,n],async()=>{if(!l.value)return S.value="";S.value=await F()},{immediate:!0});function L(te){const[J,be]=te,oe=be?`<span class="CoreAnnotatedText__annotation__subject">${be}</span>`:"";return`<span class="CoreAnnotatedText__annotation" style="background: ${b(te)}">${J}${oe}</span>`}async function F(){const te=n.value.reduce((be,oe)=>typeof oe=="string"?`${be} ${oe}`:Array.isArray(oe)?`${be} ${L(oe)}`:be,"");return await(await zt(()=>import("./marked.esm-273vDTCT.js"),[],import.meta.url)).parse(te)}return jt(S)}const m=f();function g(S,L){return S.set("hsl.h",`${Math.sign(L.h)==-1?"-":"+"}${Math.abs(L.h)}`).set("hsl.s",`${Math.sign(L.s)==-1?"-":"+"}${Math.abs(L.s/100)}`).set("hsl.l",`${Math.sign(L.l)==-1?"-":"+"}${Math.abs(L.l/100)}`).css()}function _(S,L=c.length){let F=a.seed.value*52673&4294967295;for(let J=0;J<S.length;J++)F=(J+1)*S.charCodeAt(J)^F&4294967295;return Math.abs(F)%L}function b(S){return S[2]||v(S[1])}function v(S){if(!a.rotateHue.value)return a.referenceColor.value;const L=Ig(a.referenceColor.value);if(h!==a.seed.value&&(d=[...c],u={},h=a.seed.value),u[S])return g(L,u[S]);d.length===0&&(d=[...c]);const F=_(S,d.length),te=d[F];return u[S]=te,d.splice(F,1),g(L,te)}const y=H(()=>n.value.reduce((S,L)=>typeof L=="string"?S+L:S+L[0],"")),M=H(()=>{try{return JSON.stringify(n.value)}catch{return n.value.join("")}}),x=H(()=>[{label:"Copy text",value:y.value},{label:"Copy JSON",value:M.value}]);return(S,L)=>i.value?($(),Ie($d,{key:0,class:"CoreAnnotatedText"},{actions:Xe(()=>[E(a).copyButtons.value?($(),Ie(E(t),{key:0,options:x.value},null,8,["options"])):ge("",!0)]),default:Xe(()=>[l.value?($(),Ie(Z3,{key:0,"raw-markdown":E(m),class:"CoreAnnotatedText__markdown"},null,8,["raw-markdown"])):($(),R(Je,{key:1},[s.value?($(),Ie(Sd,{key:0,"component-id":E(o)},null,8,["component-id"])):ge("",!0),($(!0),R(Je,null,Ot(n.value,(F,te)=>($(),R("span",{key:String(F)+te},[typeof F=="string"?($(),R(Je,{key:0},[pa(je(F),1)],64)):ge("",!0),Array.isArray(F)?($(),R("span",{key:1,class:"CoreAnnotatedText__annotation",style:wt({backgroundColor:b(F)})},[pa(je(F[0])+" ",1),F[1]?($(),R("span",_re,je(F[1]),1)):ge("",!0)],4)):ge("",!0)]))),128))],64))]),_:1})):ge("",!0)}}),xre=ke(wre,[["__scopeId","data-v-a540a40b"]]);function kg(e){return wl()?(Xc(e),!0):!1}const Wl=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Cre=Object.prototype.toString,Are=e=>Cre.call(e)==="[object Object]";function Sre(e){let t;function a(){return t||(t=e()),t}return a.reset=async()=>{const n=t;t=void 0,n&&await n},a}function X2(e){return Array.isArray(e)?e:[e]}function $re(e,t,a={}){const{immediate:n=!0,immediateCallback:r=!1}=a,o=$t(!1);let s;function i(){s&&(clearTimeout(s),s=void 0)}function l(){o.value=!1,i()}function c(...d){r&&e(),i(),o.value=!0,s=setTimeout(()=>{o.value=!1,s=void 0,e(...d)},Pa(t))}return n&&(o.value=!0,Wl&&c()),kg(l),{isPending:jr(o),start:c,stop:l}}function Ere(e,t,a){return We(e,t,{...a,immediate:!0})}const Ire=Wl?window:void 0,Tg=Wl?window.navigator:void 0;function kre(e){var t;const a=Pa(e);return(t=a==null?void 0:a.$el)!=null?t:a}function ls(...e){const t=[],a=()=>{t.forEach(i=>i()),t.length=0},n=(i,l,c,d)=>(i.addEventListener(l,c,d),()=>i.removeEventListener(l,c,d)),r=H(()=>{const i=X2(Pa(e[0])).filter(l=>l!=null);return i.every(l=>typeof l!="string")?i:void 0}),o=Ere(()=>{var i,l;return[(l=(i=r.value)==null?void 0:i.map(c=>kre(c)))!=null?l:[Ire].filter(c=>c!=null),X2(Pa(r.value?e[1]:e[0])),X2(E(r.value?e[2]:e[1])),Pa(r.value?e[3]:e[2])]},([i,l,c,d])=>{if(a(),!(i!=null&&i.length)||!(l!=null&&l.length)||!(c!=null&&c.length))return;const u=Are(d)?{...d}:d;t.push(...i.flatMap(h=>l.flatMap(f=>c.map(m=>n(h,f,m,u)))))},{flush:"post"}),s=()=>{o(),a()};return kg(a),s}function Tre(){const e=$t(!1),t=gn();return t&&ia(()=>{e.value=!0},t),e}function Pg(e){const t=Tre();return H(()=>(t.value,!!e()))}function pm(e,t={}){const{controls:a=!1,navigator:n=Tg}=t,r=Pg(()=>n&&"permissions"in n),o=$t(),s=typeof e=="string"?{name:e}:e,i=$t(),l=()=>{var d,u;i.value=(u=(d=o.value)==null?void 0:d.state)!=null?u:"prompt"};ls(o,"change",l,{passive:!0});const c=Sre(async()=>{if(r.value){if(!o.value)try{o.value=await n.permissions.query(s)}catch{o.value=void 0}finally{l()}if(a)return St(o.value)}});return c(),a?{state:i,isSupported:r,query:c}:i}function Lg(e={}){const{navigator:t=Tg,read:a=!1,source:n,copiedDuring:r=1500,legacy:o=!1}=e,s=Pg(()=>t&&"clipboard"in t),i=pm("clipboard-read"),l=pm("clipboard-write"),c=H(()=>s.value||o),d=$t(""),u=$t(!1),h=$re(()=>u.value=!1,r,{immediate:!1});async function f(){let v=!(s.value&&b(i.value));if(!v)try{d.value=await t.clipboard.readText()}catch{v=!0}v&&(d.value=_())}c.value&&a&&ls(["copy","cut"],f,{passive:!0});async function m(v=Pa(n)){if(c.value&&v!=null){let y=!(s.value&&b(l.value));if(!y)try{await t.clipboard.writeText(v)}catch{y=!0}y&&g(v),d.value=v,u.value=!0,h.start()}}function g(v){const y=document.createElement("textarea");y.value=v??"",y.style.position="absolute",y.style.opacity="0",document.body.appendChild(y),y.select(),document.execCommand("copy"),y.remove()}function _(){var v,y,M;return(M=(y=(v=document==null?void 0:document.getSelection)==null?void 0:v.call(document))==null?void 0:y.toString())!=null?M:""}function b(v){return v==="granted"||v==="prompt"}return{isSupported:c,text:d,copied:u,copy:m}}function Pre(e,t={}){var a,n;const r=$t(!1),o=$t(null);let s=0,i=!0;if(Wl){const l=typeof t=="function"?{onDrop:t}:t,c=(a=l.multiple)!=null?a:!0,d=(n=l.preventDefaultForUnhandled)!=null?n:!1,u=_=>{var b,v;const y=Array.from((v=(b=_.dataTransfer)==null?void 0:b.files)!=null?v:[]);return y.length===0?null:c?y:[y[0]]},h=_=>{const b=E(l.dataTypes);return typeof b=="function"?b(_):b!=null&&b.length?_.length===0?!1:_.every(v=>b.some(y=>v.includes(y))):!0},f=_=>{const b=Array.from(_??[]).map(M=>M.type),v=h(b),y=c||_.length<=1;return v&&y},m=()=>/^(?:(?!chrome|android).)*safari/i.test(navigator.userAgent)&&!("chrome"in window),g=(_,b)=>{var v,y,M,x,S,L;const F=(v=_.dataTransfer)==null?void 0:v.items;if(i=(y=F&&f(F))!=null?y:!1,d&&_.preventDefault(),!m()&&!i){_.dataTransfer&&(_.dataTransfer.dropEffect="none");return}_.preventDefault(),_.dataTransfer&&(_.dataTransfer.dropEffect="copy");const te=u(_);switch(b){case"enter":s+=1,r.value=!0,(M=l.onEnter)==null||M.call(l,null,_);break;case"over":(x=l.onOver)==null||x.call(l,null,_);break;case"leave":s-=1,s===0&&(r.value=!1),(S=l.onLeave)==null||S.call(l,null,_);break;case"drop":s=0,r.value=!1,i&&(o.value=te,(L=l.onDrop)==null||L.call(l,te,_));break}};ls(e,"dragenter",_=>g(_,"enter")),ls(e,"dragover",_=>g(_,"over")),ls(e,"dragleave",_=>g(_,"leave")),ls(e,"drop",_=>g(_,"drop"))}return{files:o,isOverDropZone:r}}function Zl(e){return!!(["string","number","boolean"].includes(typeof e)||e===null)}function Vg(e){return Zl(e)?!1:Array.isArray(e)}function Og(e){return Pr(e)}function Hg(e){return Zl(e)?1:Object.keys(e).length}function Rg(e){return typeof e.open=="boolean"&&Array.isArray(e.path)}const Lre=["open","disabled"],Vre={class:"SharedCollapsible__summary"},Ore={class:"content"},Hre=$e({__name:"SharedCollapsible",props:{open:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},icons:{type:Object,required:!1,default:void 0}},emits:{toggle:e=>typeof e=="boolean"},setup(e,{emit:t}){const a=e,n=t,r=ye(a.open);We(mn(a,"open"),i=>r.value=i);const o=H(()=>{if(a.icons!==void 0)return r.value?a.icons.open:a.icons.close});function s(i){const l=i.newState==="open";r.value=l,n("toggle",l)}return(i,l)=>($(),R("details",{class:ft(["SharedCollapsible",{"SharedCollapsible--customMarker":e.icons}]),open:r.value,disabled:e.disabled,onToggle:s},[Z("summary",Vre,[e.icons?($(),Ie(bt,{key:0,name:o.value},null,8,["name"])):ge("",!0),qt(i.$slots,"title",{},void 0,!0)]),Z("div",Ore,[qt(i.$slots,"content",{},void 0,!0)])],42,Lre))}}),Rre=ke(Hre,[["__scopeId","data-v-e02188e5"]]),Nre=$e({__name:"SharedJsonViewerChildrenCounter",props:{data:{type:[String,Number,Boolean,Object,Array,null],required:!0}},setup(e){const t=e,a=o=>`Object{${o}}`,n=o=>`Array[${o}]`,r=H(()=>{const o=Hg(t.data);return o===0?a(0):Vg(t.data)?n(o):Og(t.data)?a(o):a(0)});return(o,s)=>($(),R("span",null,je(r.value),1))}}),Ng=ke(Nre,[["__scopeId","data-v-2641ae29"]]),Dre={class:"SharedJsonViewerCollapsible__title"},Bre={key:0},Fre={class:"SharedJsonViewerCollapsible__content"},jre=$e({__name:"SharedJsonViewerCollapsible",props:{open:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},title:{type:String,required:!1,default:void 0},data:{type:[String,Number,Boolean,Object,Array,null],required:!1,default:void 0}},emits:{toggle:e=>typeof e=="boolean"},setup(e){return(t,a)=>($(),Ie(Rre,{open:e.open,disabled:e.disabled,icons:{close:"chevron-right",open:"chevron-down"},onToggle:a[0]||(a[0]=n=>t.$emit("toggle",n))},{title:Xe(()=>[Z("div",Dre,[e.title?($(),R("span",Bre,je(e.title),1)):ge("",!0),e.data?($(),Ie(Ng,{key:1,data:e.data},null,8,["data"])):ge("",!0)])]),content:Xe(()=>[Z("div",Fre,[qt(t.$slots,"default",{},void 0,!0)])]),_:3},8,["open","disabled"]))}}),Dg=ke(jre,[["__scopeId","data-v-f7561f2f"]]),Ure={class:"SharedJsonViewerValue"},zre=$e({__name:"SharedJsonViewerValue",props:{data:{type:[String,Number,Boolean,Object,Array,null],required:!0},maxValueLength:{type:Number,default:1e3}},setup(e){const t=e,a=H(()=>{const n=JSON.stringify(t.data);return n.length<=t.maxValueLength?n:`${n.slice(0,t.maxValueLength)}..."`});return(n,r)=>($(),R("span",Ure,je(a.value),1))}}),Bg=ke(zre,[["__scopeId","data-v-6842c28f"]]),qre={class:"SharedJsonViewerObject"},Wre={key:0,class:"SharedJsonViewerObject__value"},Zre=$e({__name:"SharedJsonViewerObject",props:{data:{type:[Object,Array],required:!0},path:{type:Array,default:()=>[]},initialDepth:{type:Number,default:0}},emits:{toggle:Rg},setup(e,{emit:t}){const a=e,n=mn(a,"initialDepth"),r=t,o=ye([]),s=H(()=>a.path.length+1);We(n,()=>{if(n.value===0){o.value=[];return}if(!(n.value===-1||n.value>s.value))return;const d=new Set([...o.value,...Object.keys(a.data)]);o.value=Array.from(d)},{immediate:!0});function i(c,d){d?o.value=[...o.value,c]:o.value=o.value.filter(u=>u!==c),r("toggle",{open:d,path:[...a.path,c]})}function l(c){return o.value.includes(String(c))}return(c,d)=>($(),R("div",qre,[($(!0),R(Je,null,Ot(Object.entries(e.data),([u,h],f)=>($(),R(Je,{key:f},[E(Zl)(h)||E(Hg)(h)===0?($(),R("div",Wre,[Z("span",null,je(u),1),d[1]||(d[1]=pa(": ")),Ce(Bg,{data:h},null,8,["data"])])):($(),Ie(Dg,{key:1,open:l(u),title:u,data:h,onToggle:m=>i(u,m)},{default:Xe(()=>[l(u)?($(),Ie(jg,{key:0,data:h,path:[...e.path,u],"initial-depth":n.value,onToggle:d[0]||(d[0]=m=>c.$emit("toggle",m))},null,8,["data","path","initial-depth"])):ge("",!0)]),_:2},1032,["open","title","data","onToggle"]))],64))),128))]))}}),fm=ke(Zre,[["__scopeId","data-v-72c975d1"]]);function Fg(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Kre(e,t){return t.search(new RegExp(`(^|\\n)\\s*"?${Fg(e)}"?\\s*:\\s*`))}function Gre(e,t){return t.search(new RegExp(`(^|\\n)\\s*"?${Fg(e)}"?\\s*(\\n\\s*)?(Object\\{\\d+\\}|Array\\[\\d+\\])`))}function Jre(e,t){const a=[];return Object.keys(e).forEach(n=>{const r=Kre(n,t);r!==-1&&a.push({type:"key-value",key:n,index:r});const o=Gre(n,t);o!==-1&&a.push({type:"collapsed",key:n,index:o})}),a.sort((n,r)=>n.index-r.index),a}function Xre(e,t,a){const n=new Map;Object.entries(e).forEach(([o,s])=>{n.set(o,Pr(s)?new Set(Object.keys(s)):new Set)});const r=[];return a.forEach((o,s)=>{if(o.type!=="collapsed")return;const i=n.get(o.key)??new Set;let l=t.length;for(let c=s+1;c<a.length;c++){const d=a[c];if(!(d.index<=o.index)){if(d.type==="collapsed"){l=d.index;break}if(d.type==="key-value"&&!i.has(d.key)){l=d.index;break}}}r.push({key:o.key,startIndex:o.index,endIndex:l})}),r}function Yre(e,t){const a=new Set;return e.forEach(n=>{if(n.type!=="key-value")return;t.some(o=>n.index>=o.startIndex&&n.index<o.endIndex)||a.add(n.key)}),a}function Qre(e,t){return t.find(n=>n.key===e.key&&n.startIndex===e.index)??t.find(n=>n.key===e.key)??null}function Dc(e,t){const a=Jre(e,t),n=Xre(e,t,a),r=Yre(a,n),o={array:[],object:{}};function s(l,c){o.array.push(c),o.object[l]=c}a.forEach(l=>{if(l.key in o.object)return;const c=e[l.key];switch(l.type){case"key-value":{r.has(l.key)&&s(l.key,c);break}case"collapsed":{const d=Qre(l,n),u=d?t.slice(d.startIndex,d.endIndex):t;if(!Pr(c)){s(l.key,c);break}const h=Dc(c,u),f=h.array.length>0||Object.keys(h.object).length>0;s(l.key,f?h.object:c);break}}});const i=o.array.length===0||Object.keys(o.object).length===0;return a.length>0&&i&&Object.entries(e).forEach(([l,c])=>{s(l,c)}),{array:o.array,object:o.object,tokenCount:a.length}}function eoe(e,t){const a=t.replace(/\r\n/g,`
8299
+ `);if(Pr(e)){const{object:n}=Dc(e,a);return n}if(Array.isArray(e)){const n={};e.forEach((i,l)=>{n[String(l)]=i});const{array:r,tokenCount:o}=Dc(n,a);if(r.length>0)return r;const s=/(^|\n)\s*Array\[\d+\]/;return o>0||s.test(a)?e.slice():[]}return{}}const jg=$e({__name:"SharedJsonViewer",props:{data:{type:[String,Number,Boolean,Object,Array,null],required:!0},path:{type:Array,default:()=>[]},hideRoot:{type:Boolean,required:!1},initialDepth:{type:Number,default:0},enableCopyToJson:{type:Boolean,required:!1}},emits:{toggle:Rg},setup(e){const t=ir({loader:()=>zt(()=>import("./SharedCopyClipboardButton-ed8bYNvB.js"),__vite__mapDeps([3,4,5,6,7,8]),import.meta.url)}),a=e,n=H(()=>a.path.length===0&&!a.hideRoot),r=H(()=>a.initialDepth===-1||a.initialDepth>0);function o(d){if(d===void 0)return JSON.stringify(null);try{return JSON.stringify(d,null,2)}catch{return JSON.stringify(null)}}const s=H(()=>o(a.data)),{copy:i}=Lg();function l(d){return Array.isArray(d)?d.length===0:Pr(d)?Object.keys(d).length===0:!1}function c(d,u){var m;d.stopPropagation();const h=(((m=window.getSelection())==null?void 0:m.toString())??"").trim();if(!h)return;const f=eoe(u,h);l(f)||(d.preventDefault(),i(o(f)))}return(d,u)=>($(),Ie($d,null,{actions:Xe(()=>[e.enableCopyToJson?($(),Ie(E(t),{key:0,label:"Copy JSON",value:s.value},null,8,["value"])):ge("",!0)]),default:Xe(()=>[E(Og)(e.data)||E(Vg)(e.data)?($(),R(Je,{key:0},[n.value?($(),Ie(Dg,{key:0,open:r.value,data:e.data,onToggle:u[1]||(u[1]=h=>d.$emit("toggle",{path:[],open:h})),onCopy:u[2]||(u[2]=h=>c(h,e.data))},{default:Xe(()=>[Ce(fm,{data:e.data,path:e.path,"initial-depth":e.initialDepth,onToggle:u[0]||(u[0]=h=>d.$emit("toggle",h))},null,8,["data","path","initial-depth"])]),_:1},8,["open","data"])):($(),Ie(fm,{key:1,data:e.data,path:e.path,"initial-depth":e.initialDepth,onToggle:u[3]||(u[3]=h=>d.$emit("toggle",h)),onCopy:u[4]||(u[4]=h=>c(h,e.data))},null,8,["data","path","initial-depth"]))],64)):E(Zl)(e.data)?($(),Ie(Bg,{key:1,data:e.data},null,8,["data"])):($(),Ie(Ng,{key:2,data:{}}))]),_:1}))}}),toe={class:"CoreJsonViewer"},aoe="A component to explore JSON data as a hierarchy.",noe={name:"JSON Viewer",description:"A JSON tree viewer where you can expand the keys.",sample:{description:"This sample is opened by default",bool:!0,null:null,list:[1,"two",{key:3}]},sampleClosed:{description:"This sample is not opened by default"},createdAt:new Date},roe={name:"JSON viewer",description:aoe,category:"Content",fields:{data:{name:"Data",init:JSON.stringify(noe),type:Q.Object},initialDepth:{name:"Initial depth",desc:"Sets the initial viewing depth of the JSON tree hierarchy. Use -1 to display the full hierarchy.",type:Q.Number,init:"0",validator:fn},hideRoot:Ut({name:"Hide root",desc:"Don't show the type of the root node when it's an Object or an Array.",default:"no",category:ot.Style}),copy:xd({default:"no"}),jsonViewerIndentationSpacing:{name:"JSON indentation",type:Q.Width,category:ot.Style,applyStyleVariable:!0,validator:ig},secondaryTextColor:In,separatorColor:wa,cssClasses:mt},previewField:"data"},ooe={writer:roe},soe=$e({...ooe,__name:"CoreJsonViewer",setup(e){const t=re(ne.evaluatedFields),a=H(()=>t.data.value),n=H(()=>Number(t.initialDepth.value)||0);return(r,o)=>($(),R("div",toe,[Ce(jg,{data:a.value??{},"initial-depth":n.value,"enable-copy-to-json":E(t).copy.value,"hide-root":E(t).hideRoot.value},null,8,["data","initial-depth","enable-copy-to-json","hide-root"])]))}});function ioe(e,t={minimumFractionDigits:0,maximumFractionDigits:1}){const a=new Intl.NumberFormat(void 0,{style:"percent",...t});return H(()=>a.format(e.value))}const loe=["aria-valuetext","aria-valuemin","aria-valuemax","aria-valuenow","aria-busy","tabindex"],coe={key:0,class:"CoreProgressBar__title"},doe={key:0,class:"CoreProgressBar__title__label"},uoe={key:1,class:"CoreProgressBar__title__progress"},hoe={class:"CoreProgressBar__bar"},poe=`
8300
8300
  def handle_progress_bar_click():
8301
- print("The Progress bar was clicked")`,foe="A component to display a progression.",moe={name:"Progress bar",description:foe,category:"Content",allowedChildrenTypes:["*"],fields:{label:{name:"Label",type:Q.Text,default:""},value:{name:"Value",type:Q.Number},min:{name:"Minimum value",type:Q.Number,default:"0"},max:{name:"Maximum value",type:Q.Number,default:"1"},displayPercentage:Ut({name:"Display percentage",default:"no",category:ot.Style}),accentColor:Ia,primaryTextColor:ua,separatorColor:wa,cssClasses:mt},events:{"wf-click":{desc:"Triggered when the Progress bar is clicked.",stub:poe.trim()}}},voe={writer:moe},goe=$e({...voe,__name:"CoreProgressBar",setup(e){const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.componentId),r=re(ne.core),o=H(()=>{var g;return String((g=a.label)==null?void 0:g.value)}),s=H(()=>Number(a.value.value)),i=H(()=>Number(a.min.value)),l=H(()=>Number(a.max.value)),c=H(()=>!!a.displayPercentage.value),d=H(()=>{if(!(s.value===void 0||Number.isNaN(s.value)))return(s.value-i.value)/(l.value-i.value)}),u=ioe(d),h=H(()=>({width:d.value===void 0?void 0:`${d.value*100}%`})),f=H(()=>{var _;return typeof((_=r.getComponentById(n).handlers)==null?void 0:_["wf-click"])<"u"});function m(g){if(!f.value)return;const _=Zi(g);t.value.dispatchEvent(_)}return(g,_)=>($(),R("div",{ref_key:"rootEl",ref:t,class:ft(["CoreProgressBar",{"CoreProgressBar--clickable":f.value}]),role:"progressbar","aria-valuetext":d.value===void 0?null:E(u),"aria-valuemin":i.value,"aria-valuemax":l.value,"aria-valuenow":d.value===void 0?null:s.value,"aria-busy":d.value<1||d.value===void 0,tabindex:f.value?"0":null,onKeydown:Sr(m,["enter"]),onClick:m},[o.value||c.value?($(),R("div",coe,[o.value?($(),R("label",doe,je(o.value),1)):ge("",!0),c.value&&d.value!==void 0?($(),R("span",uoe,je(E(u)),1)):ge("",!0)])):ge("",!0),Z("div",hoe,[Z("div",{class:ft(["CoreProgressBar__bar__value",{"CoreProgressBar__bar__value--indeterminate":d.value===void 0}]),style:bt(h.value)},null,6)])],42,loe))}}),yoe=ke(goe,[["__scopeId","data-v-f479ce87"]]),Moe=/[\\]?@{([^}]*)}/;function Kl(e,t){const a=new RegExp(Moe.source,"g");function n(d,u){var _;const h=[];let f="",m=0,g=0;for(;g<d.length;){const b=d.charAt(g);b=="\\"?g+1<d.length&&(f+=d.charAt(g+1),g++):b=="."?m==0?(h.push(f),f=""):f+=b:b=="["?(m==0?(h.push(f),f=""):f+=b,m++):b=="]"?(m--,m==0?f=(_=r(f,u))==null?void 0:_.toString():f+=b):f+=b,g++}return f&&h.push(f),h}function r(d,u){let f=u?o(u):void 0;const m=(t==null?void 0:t.secrets.value)??{};let g={...e.userState.value,...m?{vault:m}:{}};const _=n(d,u);if(_[0]==="vault")return"********";for(let v=0;v<_.length;v++)f=f==null?void 0:f[_[v]],g=g==null?void 0:g[_[v]];return f??g}function o(d){var h,f;const u={};for(let m=0;m<d.length-1;m++){const g=d[m],{componentId:_}=g,{type:b}=e.getComponentById(_);if(b!=="repeater"||m+1>=d.length)continue;const v=d.slice(0,m+1),y=d.slice(0,m+2),{instanceNumber:M}=y.at(-1),x=l(v,"repeaterObject");if(!x)continue;const S=Object.entries(x),L=l(v,"keyVariable"),F=l(v,"valueVariable");u[L]=(h=S[M])==null?void 0:h[0],u[F]=(f=S[M])==null?void 0:f[1]}return u}function s(d,u){return d==null?"":d.replace(a,(f,m)=>{if(f.charAt(0)=="\\")return f.substring(1);const g=m.trim();if(!g)return"";const _=r(g,u);return typeof _>"u"?"":typeof _=="object"?JSON.stringify(_):_.toString()})}function i(d){var g;const u=(g=d.at(-1))==null?void 0:g.componentId,h=e.getComponentById(u);if(!h)return;const f={},{fields:m}=e.getComponentDefinition(h.type);if(m)return Object.keys(m).forEach(_=>{f[_]=H(()=>l(d,_))}),f}function l(d,u){var M;const{componentId:h}=d.at(-1),f=e.getComponentById(h);if(!f)return;const{fields:m}=e.getComponentDefinition(f.type),g=(M=f.content)==null?void 0:M[u],_=m[u].default,b=s(g,d),v=m[u].type,y=typeof b>"u"||b===null||b==="";if(v==Q.Object||v==Q.KeyValue||v==Q.Tools){if(!b)return JSON.parse(_||null);if(typeof b!="string")return b;try{return JSON.parse(b)}catch{return JSON.parse(_||null)}}else if(v==Q.Number){const x=_===null?null:parseFloat(_);if(y)return x??null;const S=parseFloat(b);return typeof S>"u"||Number.isNaN(S)?x??null:S}else if(v==Q.Boolean){const x=y?_:b;return x==="yes"||x==="true"}else return v==Q.IdKey?g:y?_||"":b}function c(d,u){const h=e.getComponentById(d);if(!h)return;if(typeof h.visible>"u"||h.visible.expression===!0)return!0;if(h.visible.expression===!1)return!1;const f=r(h.visible.binding,u);return h.visible.reversed===!0?!f:!!f}return{getEvaluatedFields:i,isComponentVisible:c,evaluateExpression:r}}function Va(e,t,a,n="",r){const o=ye(),s=ye(!1),i=ye(null),l=t.at(-1).componentId;H(()=>e.getComponentById(l));const{evaluateExpression:c}=Kl(e,r);function d(){var f;const h=e.getComponentById(l);if((f=h==null?void 0:h.binding)!=null&&f.stateRef)return c(h.binding.stateRef,t)}function u(h,f,m){if(o.value=h,s.value){i.value={eventValue:h,emitEventType:f};return}s.value=!0;const g=()=>{s.value=!1,i.value&&(u(i.value.eventValue,i.value.emitEventType),i.value=null),m==null||m()},_=new CustomEvent(f,{detail:{payload:h,callback:g}});a.value instanceof HTMLElement?a.value.dispatchEvent(_):a.value.$el.dispatchEvent(_)}return We(()=>d(),h=>{s.value||(o.value=h)},{immediate:!0}),We(o,h=>{typeof h>"u"&&(o.value=n)},{immediate:!0}),{formValue:o,handleInput:u}}const _oe={key:0},boe=$e({__name:"BaseInputWrapper",props:{label:{type:String,required:!1,default:void 0},isHorizontal:{type:Boolean,required:!1}},setup(e){return(t,a)=>($(),R("div",{ref:"rootEl",class:ft(["BaseInputWrapper",{horizontal:e.isHorizontal}])},[e.label?($(),R("label",_oe,je(e.label),1)):ge("",!0),qt(t.$slots,"default",{},void 0,!0)],2))}}),Wa=ke(boe,[["__scopeId","data-v-1cbc4730"]]),woe=["checked","value"],xoe=["for"],mm={a:"Option A",b:"Option B"},Coe="A user input component that allows users to choose multiple values from a list of options using checkboxes.",Aoe=`
8301
+ print("The Progress bar was clicked")`,foe="A component to display a progression.",moe={name:"Progress bar",description:foe,category:"Content",allowedChildrenTypes:["*"],fields:{label:{name:"Label",type:Q.Text,default:""},value:{name:"Value",type:Q.Number},min:{name:"Minimum value",type:Q.Number,default:"0"},max:{name:"Maximum value",type:Q.Number,default:"1"},displayPercentage:Ut({name:"Display percentage",default:"no",category:ot.Style}),accentColor:Ia,primaryTextColor:ua,separatorColor:wa,cssClasses:mt},events:{"wf-click":{desc:"Triggered when the Progress bar is clicked.",stub:poe.trim()}}},voe={writer:moe},goe=$e({...voe,__name:"CoreProgressBar",setup(e){const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.componentId),r=re(ne.core),o=H(()=>{var g;return String((g=a.label)==null?void 0:g.value)}),s=H(()=>Number(a.value.value)),i=H(()=>Number(a.min.value)),l=H(()=>Number(a.max.value)),c=H(()=>!!a.displayPercentage.value),d=H(()=>{if(!(s.value===void 0||Number.isNaN(s.value)))return(s.value-i.value)/(l.value-i.value)}),u=ioe(d),h=H(()=>({width:d.value===void 0?void 0:`${d.value*100}%`})),f=H(()=>{var _;return typeof((_=r.getComponentById(n).handlers)==null?void 0:_["wf-click"])<"u"});function m(g){if(!f.value)return;const _=Zi(g);t.value.dispatchEvent(_)}return(g,_)=>($(),R("div",{ref_key:"rootEl",ref:t,class:ft(["CoreProgressBar",{"CoreProgressBar--clickable":f.value}]),role:"progressbar","aria-valuetext":d.value===void 0?null:E(u),"aria-valuemin":i.value,"aria-valuemax":l.value,"aria-valuenow":d.value===void 0?null:s.value,"aria-busy":d.value<1||d.value===void 0,tabindex:f.value?"0":null,onKeydown:$r(m,["enter"]),onClick:m},[o.value||c.value?($(),R("div",coe,[o.value?($(),R("label",doe,je(o.value),1)):ge("",!0),c.value&&d.value!==void 0?($(),R("span",uoe,je(E(u)),1)):ge("",!0)])):ge("",!0),Z("div",hoe,[Z("div",{class:ft(["CoreProgressBar__bar__value",{"CoreProgressBar__bar__value--indeterminate":d.value===void 0}]),style:wt(h.value)},null,6)])],42,loe))}}),yoe=ke(goe,[["__scopeId","data-v-f479ce87"]]),Moe=/[\\]?@{([^}]*)}/;function Kl(e,t){const a=new RegExp(Moe.source,"g");function n(d,u){var _;const h=[];let f="",m=0,g=0;for(;g<d.length;){const b=d.charAt(g);b=="\\"?g+1<d.length&&(f+=d.charAt(g+1),g++):b=="."?m==0?(h.push(f),f=""):f+=b:b=="["?(m==0?(h.push(f),f=""):f+=b,m++):b=="]"?(m--,m==0?f=(_=r(f,u))==null?void 0:_.toString():f+=b):f+=b,g++}return f&&h.push(f),h}function r(d,u){let f=u?o(u):void 0;const m=(t==null?void 0:t.secrets.value)??{};let g={...e.userState.value,...m?{vault:m}:{}};const _=n(d,u);if(_[0]==="vault")return"********";for(let v=0;v<_.length;v++)f=f==null?void 0:f[_[v]],g=g==null?void 0:g[_[v]];return f??g}function o(d){var h,f;const u={};for(let m=0;m<d.length-1;m++){const g=d[m],{componentId:_}=g,{type:b}=e.getComponentById(_);if(b!=="repeater"||m+1>=d.length)continue;const v=d.slice(0,m+1),y=d.slice(0,m+2),{instanceNumber:M}=y.at(-1),x=l(v,"repeaterObject");if(!x)continue;const S=Object.entries(x),L=l(v,"keyVariable"),F=l(v,"valueVariable");u[L]=(h=S[M])==null?void 0:h[0],u[F]=(f=S[M])==null?void 0:f[1]}return u}function s(d,u){return d==null?"":d.replace(a,(f,m)=>{if(f.charAt(0)=="\\")return f.substring(1);const g=m.trim();if(!g)return"";const _=r(g,u);return typeof _>"u"?"":typeof _=="object"?JSON.stringify(_):_.toString()})}function i(d){var g;const u=(g=d.at(-1))==null?void 0:g.componentId,h=e.getComponentById(u);if(!h)return;const f={},{fields:m}=e.getComponentDefinition(h.type);if(m)return Object.keys(m).forEach(_=>{f[_]=H(()=>l(d,_))}),f}function l(d,u){var M;const{componentId:h}=d.at(-1),f=e.getComponentById(h);if(!f)return;const{fields:m}=e.getComponentDefinition(f.type),g=(M=f.content)==null?void 0:M[u],_=m[u].default,b=s(g,d),v=m[u].type,y=typeof b>"u"||b===null||b==="";if(v==Q.Object||v==Q.KeyValue||v==Q.Tools){if(!b)return JSON.parse(_||null);if(typeof b!="string")return b;try{return JSON.parse(b)}catch{return JSON.parse(_||null)}}else if(v==Q.Number){const x=_===null?null:parseFloat(_);if(y)return x??null;const S=parseFloat(b);return typeof S>"u"||Number.isNaN(S)?x??null:S}else if(v==Q.Boolean){const x=y?_:b;return x==="yes"||x==="true"}else return v==Q.IdKey?g:y?_||"":b}function c(d,u){const h=e.getComponentById(d);if(!h)return;if(typeof h.visible>"u"||h.visible.expression===!0)return!0;if(h.visible.expression===!1)return!1;const f=r(h.visible.binding,u);return h.visible.reversed===!0?!f:!!f}return{getEvaluatedFields:i,isComponentVisible:c,evaluateExpression:r}}function Va(e,t,a,n="",r){const o=ye(),s=ye(!1),i=ye(null),l=t.at(-1).componentId;H(()=>e.getComponentById(l));const{evaluateExpression:c}=Kl(e,r);function d(){var f;const h=e.getComponentById(l);if((f=h==null?void 0:h.binding)!=null&&f.stateRef)return c(h.binding.stateRef,t)}function u(h,f,m){if(o.value=h,s.value){i.value={eventValue:h,emitEventType:f};return}s.value=!0;const g=()=>{s.value=!1,i.value&&(u(i.value.eventValue,i.value.emitEventType),i.value=null),m==null||m()},_=new CustomEvent(f,{detail:{payload:h,callback:g}});a.value instanceof HTMLElement?a.value.dispatchEvent(_):a.value.$el.dispatchEvent(_)}return We(()=>d(),h=>{s.value||(o.value=h)},{immediate:!0}),We(o,h=>{typeof h>"u"&&(o.value=n)},{immediate:!0}),{formValue:o,handleInput:u}}const _oe={key:0},boe=$e({__name:"BaseInputWrapper",props:{label:{type:String,required:!1,default:void 0},isHorizontal:{type:Boolean,required:!1}},setup(e){return(t,a)=>($(),R("div",{ref:"rootEl",class:ft(["BaseInputWrapper",{horizontal:e.isHorizontal}])},[e.label?($(),R("label",_oe,je(e.label),1)):ge("",!0),qt(t.$slots,"default",{},void 0,!0)],2))}}),Wa=ke(boe,[["__scopeId","data-v-1cbc4730"]]),woe=["checked","value"],xoe=["for"],mm={a:"Option A",b:"Option B"},Coe="A user input component that allows users to choose multiple values from a list of options using checkboxes.",Aoe=`
8302
8302
  def onchange_handler(state, payload):
8303
8303
 
8304
8304
  # Set the state variable "selected" to the selected options.
8305
8305
  # The payload will be a list, as multiple options are allowed.
8306
8306
 
8307
- state["selected"] = payload`,Soe={writer:{name:"Checkbox input",description:Coe,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(mm,null,2),validator:no},orientation:{name:"Orientation",type:Q.Text,options:{vertical:"Vertical",horizontal:"Horizontal"},default:"vertical",category:ot.Style,desc:"Specify how to lay out the options."},primaryTextColor:ua,accentColor:Ia,cssClasses:mt},events:{"wf-options-change":{desc:"Sent when the selected options change.",stub:Aoe.trim(),bindable:!0,eventPayloadExample:Object.keys(mm)}}}},$oe=$e({...Soe,__name:"CoreCheckboxInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),o=re(ne.flattenedInstancePath),{formValue:s,handleInput:i}=Va(n,r,a);function l(){return a.value?Array.from(a.value.$el.querySelectorAll('input[type="checkbox"]')).map(u=>u.checked?u.value:void 0).filter(u=>typeof u<"u"):void 0}return(c,d)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreCheckboxInput"},{default:Xe(()=>[Z("div",{class:ft(["options",{horizontal:E(t).orientation.value=="horizontal"}])},[($(!0),R(Je,null,Ot(E(t).options.value,(u,h)=>($(),R("div",{key:h,class:"option"},[Z("input",{type:"checkbox",checked:Array.isArray(E(s))?E(s).includes(h):!1,value:h,onInput:d[0]||(d[0]=f=>E(i)(l(),"wf-options-change"))},null,40,woe),Z("label",{for:`${E(o)}-option-${h}`},je(u),9,xoe)]))),128))],2)]),_:1},8,["label"]))}}),Eoe=ke($oe,[["__scopeId","data-v-cdb01d0c"]]),Ioe=["value","list"],koe=["id"],Toe=$e({__name:"BaseInputColor",props:{value:{type:String,required:!1,default:void 0},customColors:{type:Array,default:()=>[]}},emits:{"update:value":e=>typeof e=="string",change:e=>typeof e=="string"},setup(e,{emit:t}){const a=e,n=t,r=pt("pickerEl"),o=re(ne.flattenedInstancePath),s=H(()=>{var c;return(c=a.customColors)!=null&&c.length?`${o}_datalist`:null});function i(c){n("update:value",c.target.value)}function l(c){n("change",c.target.value)}return(c,d)=>($(),R(Je,null,[Z("input",{ref_key:"pickerEl",ref:r,type:"color",class:"BaseInputColor",value:e.value,list:s.value,onInput:i,onChange:l},null,40,Ioe),s.value?($(),R("datalist",{key:0,id:s.value},[($(!0),R(Je,null,Ot(e.customColors,u=>($(),R("option",{key:u},je(u),1))),128))],8,koe)):ge("",!0)],64))}}),Poe=ke(Toe,[["__scopeId","data-v-ba449f16"]]),Loe="A user input component that allows users to select a color using a color picker interface.",vm=`
8307
+ state["selected"] = payload`,Soe={writer:{name:"Checkbox input",description:Coe,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(mm,null,2),validator:ro},orientation:{name:"Orientation",type:Q.Text,options:{vertical:"Vertical",horizontal:"Horizontal"},default:"vertical",category:ot.Style,desc:"Specify how to lay out the options."},primaryTextColor:ua,accentColor:Ia,cssClasses:mt},events:{"wf-options-change":{desc:"Sent when the selected options change.",stub:Aoe.trim(),bindable:!0,eventPayloadExample:Object.keys(mm)}}}},$oe=$e({...Soe,__name:"CoreCheckboxInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),o=re(ne.flattenedInstancePath),{formValue:s,handleInput:i}=Va(n,r,a);function l(){return a.value?Array.from(a.value.$el.querySelectorAll('input[type="checkbox"]')).map(u=>u.checked?u.value:void 0).filter(u=>typeof u<"u"):void 0}return(c,d)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreCheckboxInput"},{default:Xe(()=>[Z("div",{class:ft(["options",{horizontal:E(t).orientation.value=="horizontal"}])},[($(!0),R(Je,null,Ot(E(t).options.value,(u,h)=>($(),R("div",{key:h,class:"option"},[Z("input",{type:"checkbox",checked:Array.isArray(E(s))?E(s).includes(h):!1,value:h,onInput:d[0]||(d[0]=f=>E(i)(l(),"wf-options-change"))},null,40,woe),Z("label",{for:`${E(o)}-option-${h}`},je(u),9,xoe)]))),128))],2)]),_:1},8,["label"]))}}),Eoe=ke($oe,[["__scopeId","data-v-cdb01d0c"]]),Ioe=["value","list"],koe=["id"],Toe=$e({__name:"BaseInputColor",props:{value:{type:String,required:!1,default:void 0},customColors:{type:Array,default:()=>[]}},emits:{"update:value":e=>typeof e=="string",change:e=>typeof e=="string"},setup(e,{emit:t}){const a=e,n=t,r=pt("pickerEl"),o=re(ne.flattenedInstancePath),s=H(()=>{var c;return(c=a.customColors)!=null&&c.length?`${o}_datalist`:null});function i(c){n("update:value",c.target.value)}function l(c){n("change",c.target.value)}return(c,d)=>($(),R(Je,null,[Z("input",{ref_key:"pickerEl",ref:r,type:"color",class:"BaseInputColor",value:e.value,list:s.value,onInput:i,onChange:l},null,40,Ioe),s.value?($(),R("datalist",{key:0,id:s.value},[($(!0),R(Je,null,Ot(e.customColors,u=>($(),R("option",{key:u},je(u),1))),128))],8,koe)):ge("",!0)],64))}}),Poe=ke(Toe,[["__scopeId","data-v-ba449f16"]]),Loe="A user input component that allows users to select a color using a color picker interface.",vm=`
8308
8308
  def onchange_handler(state, payload):
8309
8309
 
8310
8310
  # Set the state variable "new_color" to the new value, provided as string.
@@ -8314,12 +8314,12 @@ def onchange_handler(state, payload):
8314
8314
 
8315
8315
  # Set the state variable "new_date" to the new value, provided as a YYYY-MM-DD string.
8316
8316
 
8317
- state["new_date"] = payload`,Foe={writer:{name:"Date input",description:Doe,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},cssClasses:mt},events:{"wf-date-change":{desc:"Capture changes to this control.",stub:Boe,bindable:!0,eventPayloadExample:new Date().toISOString().split("T")[0]}}}},joe=$e({...Foe,__name:"CoreDateInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a);return(i,l)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreDateInput"},{default:Xe(()=>[Z("input",{type:"date",value:E(o),onChange:l[0]||(l[0]=c=>E(s)(c.target.value,"wf-date-change"))},null,40,Noe)]),_:1},8,["label"]))}}),Uoe=ke(joe,[["__scopeId","data-v-66af2fd5"]]),zoe=$e({__name:"WdsDropdownInput",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=ir(e,"modelValue");return(a,n)=>Ya(($(),R("select",{"onUpdate:modelValue":n[0]||(n[0]=r=>t.value=r),class:"WdsDropdownInput colorTransformer"},[qt(a.$slots,"default",{},void 0,!0)],512)),[[y0,t.value]])}}),Ug=ke(zoe,[["__scopeId","data-v-a262dc28"]]),qoe=["value"],Woe="A user input component that allows users to select a single value from a list of options using a dropdown menu.",gm={a:"Option A",b:"Option B"},Zoe=`
8317
+ state["new_date"] = payload`,Foe={writer:{name:"Date input",description:Doe,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},cssClasses:mt},events:{"wf-date-change":{desc:"Capture changes to this control.",stub:Boe,bindable:!0,eventPayloadExample:new Date().toISOString().split("T")[0]}}}},joe=$e({...Foe,__name:"CoreDateInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a);return(i,l)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreDateInput"},{default:Xe(()=>[Z("input",{type:"date",value:E(o),onChange:l[0]||(l[0]=c=>E(s)(c.target.value,"wf-date-change"))},null,40,Noe)]),_:1},8,["label"]))}}),Uoe=ke(joe,[["__scopeId","data-v-66af2fd5"]]),zoe=$e({__name:"WdsDropdownInput",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=lr(e,"modelValue");return(a,n)=>Ya(($(),R("select",{"onUpdate:modelValue":n[0]||(n[0]=r=>t.value=r),class:"WdsDropdownInput colorTransformer"},[qt(a.$slots,"default",{},void 0,!0)],512)),[[y0,t.value]])}}),Ug=ke(zoe,[["__scopeId","data-v-a262dc28"]]),qoe=["value"],Woe="A user input component that allows users to select a single value from a list of options using a dropdown menu.",gm={a:"Option A",b:"Option B"},Zoe=`
8318
8318
  def onchange_handler(state, payload):
8319
8319
 
8320
8320
  # Set the state variable "selected" to the selected option
8321
8321
 
8322
- state["selected"] = payload`,Koe={writer:{deprecated:!0,name:"Dropdown input",description:Woe,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(gm,null,2),validator:no},cssClasses:mt},events:{"wf-option-change":{desc:"Sent when the selected option changes.",stub:Zoe.trim(),bindable:!0,eventPayloadExample:Object.keys(gm)[0]}}}},Goe=$e({...Koe,__name:"CoreDropdownInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a);return(i,l)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreDropdownInput"},{default:Xe(()=>[Ce(Ug,{modelValue:E(o),"onUpdate:modelValue":l[0]||(l[0]=c=>ba(o)?o.value=c:null),onInput:l[1]||(l[1]=c=>E(s)(c.target.value,"wf-option-change"))},{default:Xe(()=>[($(!0),R(Je,null,Ot(E(t).options.value,(c,d)=>($(),R("option",{key:d,value:d},je(c),9,qoe))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"]))}}),Joe=ke(Goe,[["__scopeId","data-v-567bbac8"]]),Xoe={class:"WdsTag__text"},Yoe=$e({__name:"WdsTag",props:{text:{type:String,required:!0},closable:{type:Boolean,required:!1},size:{type:String,default:"normal"},variant:{type:String,default:"normal"}},emits:{close:()=>!0},setup(e){const t=e,a=H(()=>[`WdsTag--size-${t.size}`,`WdsTag--variant-${t.variant}`]);return(n,r)=>($(),R("div",{class:ft(["WdsTag",a.value])},[Z("span",Xoe,je(e.text),1),e.closable?($(),R("button",{key:0,type:"button",class:"WdsTag__close",onClick:r[0]||(r[0]=sn(o=>n.$emit("close"),["stop"]))},[Ce(_t,{name:"x"})])):ge("",!0)],2))}}),zg=ke(Yoe,[["__scopeId","data-v-ade29829"]]),Qoe={class:"SharedFile"},ese={key:1,class:"SharedFile__icon"},tse=["title"],ase={key:2,class:"SharedFile__actions"},nse=$e({__name:"SharedFile",props:{status:{type:String,required:!0},name:{type:String,default:""},size:{type:Number,default:0}},emits:{download:()=>!0},setup(e){const t=e,a=H(()=>t.size>0),n=H(()=>t.status==="ready"),r=H(()=>a.value||n.value),o=H(()=>fl(t.size));return(s,i)=>($(),R("div",Qoe,[e.status==="uploading"?($(),Ie(Mg,{key:0})):($(),R("div",ese,[Ce(_t,{name:"file-check"})])),Z("span",{class:"SharedFile__name",title:e.name},je(e.name),9,tse),r.value?($(),R("div",ase,[a.value?($(),Ie(zg,{key:0,variant:"normal",text:o.value},null,8,["text"])):ge("",!0),n.value?($(),Ie(La,{key:1,variant:"tertiary",size:"smallIcon","data-writer-tooltip":"Download File","data-writer-tooltip-placement":"left","aria-label":`Download ${e.name||"File"}`,onClick:i[0]||(i[0]=l=>s.$emit("download"))},{default:Xe(()=>[Ce(_t,{name:"download"})]),_:1},8,["aria-label"])):ge("",!0)])):ge("",!0)]))}}),rse=ke(nse,[["__scopeId","data-v-82fa4fa8"]]);var ose=function(e,t){if(e&&t){var a=Array.isArray(t)?t:t.split(",");if(a.length===0)return!0;var n=e.name||"",r=(e.type||"").toLowerCase(),o=r.replace(/\/.*$/,"");return a.some(function(s){var i=s.trim().toLowerCase();return i.charAt(0)==="."?n.toLowerCase().endsWith(i):i.endsWith("/*")?o===i.replace(/\/.*$/,""):r===i})}return!0};function sse({acceptedFileTypes:e=[]}){const t=H(()=>{const r=Pa(e);if(!Array.isArray(r)||r.length===0)return[];const o=new Set;return r.forEach(s=>{if(typeof s!="string")return;const i=s.trim().toLowerCase();i&&o.add(i.startsWith("*.")?i.slice(1):i)}),[...o]}),a=H(()=>t.value.join(",")||void 0);function n(r){return ose(r,t.value)}return{acceptAttr:a,checkIsFileAccepted:n}}const ise=["for"],lse=["id","multiple","accept"],cse={class:"SharedDropZone__labelWrapper"},dse={class:"SharedDropZone__label"},use=$e({__name:"SharedDropZone",props:{multiple:{type:Boolean,default:!1},acceptedFileTypes:{type:Array,default:void 0},totalSizeLimit:{type:Number,default:void 0},label:{type:String,default:""},restrictions:{type:String,default:""}},emits:{drop:e=>Array.isArray(e)&&e.length>0},setup(e,{emit:t}){const a=e,n=t,r=Sv(),{acceptAttr:o,checkIsFileAccepted:s}=sse({acceptedFileTypes:mn(a,"acceptedFileTypes")});function i(u){const h=u.filter(f=>s(f));h.length>0&&n("drop",a.multiple?h:h.slice(0,1))}const l=pt("dropZoneElement"),{isOverDropZone:c}=Pre(l,{onDrop:u=>{Array.isArray(u)&&i(u)}});function d(u){u.target instanceof HTMLInputElement&&u.target.files instanceof FileList&&(i(Array.from(u.target.files)),u.target.value="")}return(u,h)=>($(),R("label",{ref_key:"dropZoneElement",ref:l,for:E(r),class:ft(["SharedDropZone",{SharedDropZone_active:E(c)}])},[Ya(Z("input",{id:E(r),type:"file",multiple:e.multiple,accept:E(o),onChange:d},null,40,lse),[[jn,!1]]),Z("div",cse,[h[2]||(h[2]=Z("svg",{xmlns:"http://www.w3.org/2000/svg",width:"60",height:"61",viewBox:"0 0 60 61",class:"SharedDropZone__svg"},[Z("circle",{class:"SharedDropZone__svgCircle",cx:"30",cy:"30.5",r:"30"}),Z("path",{d:"M17.6288 40.455C16.6907 39.2586 15.9316 37.9585 15.3513 36.5546C14.7713 35.1507 14.3873 33.6881 14.1992 32.1667H16.7505C16.9171 33.3611 17.2227 34.5069 17.6671 35.6042C18.1116 36.7014 18.6949 37.7222 19.4171 38.6667L17.6288 40.455ZM14.1992 28.8333C14.4001 27.3119 14.7874 25.8493 15.3613 24.4454C15.9349 23.0415 16.7014 21.7521 17.6609 20.5771L19.4171 22.3333C18.6949 23.2778 18.1116 24.2986 17.6671 25.3958C17.2227 26.4931 16.9171 27.6389 16.7505 28.8333H14.1992ZM28.2505 46.25C26.7291 46.0725 25.2734 45.6926 23.8834 45.1104C22.4934 44.5282 21.197 43.7713 19.9942 42.8396L21.7505 41C22.7227 41.7222 23.7505 42.3194 24.8338 42.7917C25.9171 43.2639 27.056 43.5833 28.2505 43.75V46.25ZM21.8338 19.9679L19.9942 18.1604C21.2248 17.2179 22.542 16.461 23.9459 15.8896C25.3498 15.3179 26.8124 14.9381 28.3338 14.75V17.25C27.1394 17.4167 25.9935 17.7281 24.8963 18.1842C23.7991 18.6406 22.7782 19.2351 21.8338 19.9679ZM31.5838 46.25V43.75C32.7955 43.5833 33.9552 43.2761 35.063 42.8283C36.1707 42.3808 37.2055 41.7821 38.1671 41.0321L40.0067 42.8396C38.7762 43.799 37.452 44.5603 36.0342 45.1233C34.6164 45.6864 33.133 46.0619 31.5838 46.25ZM38.2505 20C37.2782 19.2778 36.2366 18.6806 35.1255 18.2083C34.0144 17.7361 32.8616 17.4167 31.6671 17.25V14.75C33.1885 14.9275 34.6553 15.3047 36.0676 15.8817C37.4801 16.4583 38.7931 17.2179 40.0067 18.1604L38.2505 20ZM42.3401 40.4229L40.5838 38.6667C41.306 37.7222 41.8894 36.7014 42.3338 35.6042C42.7782 34.5069 43.0838 33.3611 43.2505 32.1667H45.8017C45.6009 33.6881 45.2135 35.1507 44.6396 36.5546C44.066 37.9585 43.2995 39.2479 42.3401 40.4229ZM43.2505 28.8333C43.0838 27.6389 42.7782 26.4931 42.3338 25.3958C41.8894 24.2986 41.306 23.2778 40.5838 22.3333L42.3721 20.545C43.3102 21.7414 44.0694 23.0415 44.6496 24.4454C45.2296 25.8493 45.6137 27.3119 45.8017 28.8333H43.2505ZM28.7763 38.2563V27.5321L24.0263 32.2821L22.2696 30.5L30.0263 22.7437L37.7826 30.5L36.0005 32.2563L31.2759 27.5321V38.2563H28.7763Z"})],-1)),Z("span",dse,[e.label?($(),R(Je,{key:0},[pa(je(e.label),1)],64)):($(),R(Je,{key:1},[h[0]||(h[0]=pa(" Drag & drop, or ")),h[1]||(h[1]=Z("span",null,"browse files",-1))],64))])])],10,ise))}}),hse=ke(use,[["__scopeId","data-v-2043a51b"]]),pse={class:"main"},fse={key:0,class:"file-list"},mse={key:1,class:"status"},vse="A user input component that allows users to upload files.",gse=`
8322
+ state["selected"] = payload`,Koe={writer:{deprecated:!0,name:"Dropdown input",description:Woe,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(gm,null,2),validator:ro},cssClasses:mt},events:{"wf-option-change":{desc:"Sent when the selected option changes.",stub:Zoe.trim(),bindable:!0,eventPayloadExample:Object.keys(gm)[0]}}}},Goe=$e({...Koe,__name:"CoreDropdownInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a);return(i,l)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreDropdownInput"},{default:Xe(()=>[Ce(Ug,{modelValue:E(o),"onUpdate:modelValue":l[0]||(l[0]=c=>ba(o)?o.value=c:null),onInput:l[1]||(l[1]=c=>E(s)(c.target.value,"wf-option-change"))},{default:Xe(()=>[($(!0),R(Je,null,Ot(E(t).options.value,(c,d)=>($(),R("option",{key:d,value:d},je(c),9,qoe))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"]))}}),Joe=ke(Goe,[["__scopeId","data-v-567bbac8"]]),Xoe={class:"WdsTag__text"},Yoe=$e({__name:"WdsTag",props:{text:{type:String,required:!0},closable:{type:Boolean,required:!1},size:{type:String,default:"normal"},variant:{type:String,default:"normal"}},emits:{close:()=>!0},setup(e){const t=e,a=H(()=>[`WdsTag--size-${t.size}`,`WdsTag--variant-${t.variant}`]);return(n,r)=>($(),R("div",{class:ft(["WdsTag",a.value])},[Z("span",Xoe,je(e.text),1),e.closable?($(),R("button",{key:0,type:"button",class:"WdsTag__close",onClick:r[0]||(r[0]=sn(o=>n.$emit("close"),["stop"]))},[Ce(bt,{name:"x"})])):ge("",!0)],2))}}),zg=ke(Yoe,[["__scopeId","data-v-ade29829"]]),Qoe={class:"SharedFile"},ese={key:1,class:"SharedFile__icon"},tse=["title"],ase={key:2,class:"SharedFile__actions"},nse=$e({__name:"SharedFile",props:{status:{type:String,required:!0},name:{type:String,default:""},size:{type:Number,default:0}},emits:{download:()=>!0},setup(e){const t=e,a=H(()=>t.size>0),n=H(()=>t.status==="ready"),r=H(()=>a.value||n.value),o=H(()=>fl(t.size));return(s,i)=>($(),R("div",Qoe,[e.status==="uploading"?($(),Ie(Mg,{key:0})):($(),R("div",ese,[Ce(bt,{name:"file-check"})])),Z("span",{class:"SharedFile__name",title:e.name},je(e.name),9,tse),r.value?($(),R("div",ase,[a.value?($(),Ie(zg,{key:0,variant:"normal",text:o.value},null,8,["text"])):ge("",!0),n.value?($(),Ie(La,{key:1,variant:"tertiary",size:"smallIcon","data-writer-tooltip":"Download File","data-writer-tooltip-placement":"left","aria-label":`Download ${e.name||"File"}`,onClick:i[0]||(i[0]=l=>s.$emit("download"))},{default:Xe(()=>[Ce(bt,{name:"download"})]),_:1},8,["aria-label"])):ge("",!0)])):ge("",!0)]))}}),rse=ke(nse,[["__scopeId","data-v-82fa4fa8"]]);var ose=function(e,t){if(e&&t){var a=Array.isArray(t)?t:t.split(",");if(a.length===0)return!0;var n=e.name||"",r=(e.type||"").toLowerCase(),o=r.replace(/\/.*$/,"");return a.some(function(s){var i=s.trim().toLowerCase();return i.charAt(0)==="."?n.toLowerCase().endsWith(i):i.endsWith("/*")?o===i.replace(/\/.*$/,""):r===i})}return!0};function sse({acceptedFileTypes:e=[]}){const t=H(()=>{const r=Pa(e);if(!Array.isArray(r)||r.length===0)return[];const o=new Set;return r.forEach(s=>{if(typeof s!="string")return;const i=s.trim().toLowerCase();i&&o.add(i.startsWith("*.")?i.slice(1):i)}),[...o]}),a=H(()=>t.value.join(",")||void 0);function n(r){return ose(r,t.value)}return{acceptAttr:a,checkIsFileAccepted:n}}const ise=["for"],lse=["id","multiple","accept"],cse={class:"SharedDropZone__labelWrapper"},dse={class:"SharedDropZone__label"},use=$e({__name:"SharedDropZone",props:{multiple:{type:Boolean,default:!1},acceptedFileTypes:{type:Array,default:void 0},totalSizeLimit:{type:Number,default:void 0},label:{type:String,default:""},restrictions:{type:String,default:""}},emits:{drop:e=>Array.isArray(e)&&e.length>0},setup(e,{emit:t}){const a=e,n=t,r=Sv(),{acceptAttr:o,checkIsFileAccepted:s}=sse({acceptedFileTypes:mn(a,"acceptedFileTypes")});function i(u){const h=u.filter(f=>s(f));h.length>0&&n("drop",a.multiple?h:h.slice(0,1))}const l=pt("dropZoneElement"),{isOverDropZone:c}=Pre(l,{onDrop:u=>{Array.isArray(u)&&i(u)}});function d(u){u.target instanceof HTMLInputElement&&u.target.files instanceof FileList&&(i(Array.from(u.target.files)),u.target.value="")}return(u,h)=>($(),R("label",{ref_key:"dropZoneElement",ref:l,for:E(r),class:ft(["SharedDropZone",{SharedDropZone_active:E(c)}])},[Ya(Z("input",{id:E(r),type:"file",multiple:e.multiple,accept:E(o),onChange:d},null,40,lse),[[Un,!1]]),Z("div",cse,[h[2]||(h[2]=Z("svg",{xmlns:"http://www.w3.org/2000/svg",width:"60",height:"61",viewBox:"0 0 60 61",class:"SharedDropZone__svg"},[Z("circle",{class:"SharedDropZone__svgCircle",cx:"30",cy:"30.5",r:"30"}),Z("path",{d:"M17.6288 40.455C16.6907 39.2586 15.9316 37.9585 15.3513 36.5546C14.7713 35.1507 14.3873 33.6881 14.1992 32.1667H16.7505C16.9171 33.3611 17.2227 34.5069 17.6671 35.6042C18.1116 36.7014 18.6949 37.7222 19.4171 38.6667L17.6288 40.455ZM14.1992 28.8333C14.4001 27.3119 14.7874 25.8493 15.3613 24.4454C15.9349 23.0415 16.7014 21.7521 17.6609 20.5771L19.4171 22.3333C18.6949 23.2778 18.1116 24.2986 17.6671 25.3958C17.2227 26.4931 16.9171 27.6389 16.7505 28.8333H14.1992ZM28.2505 46.25C26.7291 46.0725 25.2734 45.6926 23.8834 45.1104C22.4934 44.5282 21.197 43.7713 19.9942 42.8396L21.7505 41C22.7227 41.7222 23.7505 42.3194 24.8338 42.7917C25.9171 43.2639 27.056 43.5833 28.2505 43.75V46.25ZM21.8338 19.9679L19.9942 18.1604C21.2248 17.2179 22.542 16.461 23.9459 15.8896C25.3498 15.3179 26.8124 14.9381 28.3338 14.75V17.25C27.1394 17.4167 25.9935 17.7281 24.8963 18.1842C23.7991 18.6406 22.7782 19.2351 21.8338 19.9679ZM31.5838 46.25V43.75C32.7955 43.5833 33.9552 43.2761 35.063 42.8283C36.1707 42.3808 37.2055 41.7821 38.1671 41.0321L40.0067 42.8396C38.7762 43.799 37.452 44.5603 36.0342 45.1233C34.6164 45.6864 33.133 46.0619 31.5838 46.25ZM38.2505 20C37.2782 19.2778 36.2366 18.6806 35.1255 18.2083C34.0144 17.7361 32.8616 17.4167 31.6671 17.25V14.75C33.1885 14.9275 34.6553 15.3047 36.0676 15.8817C37.4801 16.4583 38.7931 17.2179 40.0067 18.1604L38.2505 20ZM42.3401 40.4229L40.5838 38.6667C41.306 37.7222 41.8894 36.7014 42.3338 35.6042C42.7782 34.5069 43.0838 33.3611 43.2505 32.1667H45.8017C45.6009 33.6881 45.2135 35.1507 44.6396 36.5546C44.066 37.9585 43.2995 39.2479 42.3401 40.4229ZM43.2505 28.8333C43.0838 27.6389 42.7782 26.4931 42.3338 25.3958C41.8894 24.2986 41.306 23.2778 40.5838 22.3333L42.3721 20.545C43.3102 21.7414 44.0694 23.0415 44.6496 24.4454C45.2296 25.8493 45.6137 27.3119 45.8017 28.8333H43.2505ZM28.7763 38.2563V27.5321L24.0263 32.2821L22.2696 30.5L30.0263 22.7437L37.7826 30.5L36.0005 32.2563L31.2759 27.5321V38.2563H28.7763Z"})],-1)),Z("span",dse,[e.label?($(),R(Je,{key:0},[pa(je(e.label),1)],64)):($(),R(Je,{key:1},[h[0]||(h[0]=pa(" Drag & drop, or ")),h[1]||(h[1]=Z("span",null,"browse files",-1))],64))])])],10,ise))}}),hse=ke(use,[["__scopeId","data-v-2043a51b"]]),pse={class:"main"},fse={key:0,class:"file-list"},mse={key:1,class:"status"},vse="A user input component that allows users to upload files.",gse=`
8323
8323
  def onchange_handler(state, payload):
8324
8324
 
8325
8325
  # An array of dictionaries is provided in the payload
@@ -8331,12 +8331,12 @@ def onchange_handler(state, payload):
8331
8331
  name = uploaded_file.get("name")
8332
8332
  file_data = uploaded_file.get("data")
8333
8333
  with open(f"{name}-{i}.jpeg", "wb") as file_handle:
8334
- file_handle.write(file_data)`.trim(),yse={writer:{name:"File input",description:vse,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},allowFileTypes:{name:"Allowed file types",type:Q.Text,init:[".pdf",".txt",".doc",".docx","image/*"].join(", "),desc:"Provides hints for browsers to select the correct file types. You can specify extensions and MIME types separated by comma, or leave empty to accept any file."},allowMultipleFiles:Ut({name:"Allow multiple files",default:"no"}),cssClasses:mt},events:{"wf-file-change":{desc:"Capture changes to this control.",stub:gse,bindable:!0,eventPayloadExample:[{name:"hello.txt",type:"text/plain",data:"data:text/plain;base64,SGVsbG8gd29ybGQK"}]}}}},Mse=$e({...yse,__name:"CoreFileInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a),i=H(()=>{var y;return(((y=t.allowFileTypes)==null?void 0:y.value)??"").split(",")}),l=H(()=>!!t.allowMultipleFiles.value),{files:c,calcTotalSize:d,replaceFiles:u,encodeFiles:h,decodeFiles:f}=Ag({multiple:l});ia(async()=>{if(Array.isArray(o.value)){const{decodedFiles:y}=await f(o.value);u(y)}});const m=200*1024*1024,g=ye(!1),_=ye(null);async function b(y){if(g.value)return;if(d(y)>m){_.value=`Files are too big. Total size limit is ${fl(m)}.`;return}g.value=!0,_.value=null,u(y);const{encodedFiles:M}=await h();if(M.length===0){g.value=!1;return}s(M,"wf-file-change"),g.value=!1}function v(y){const M=window.URL.createObjectURL(y),x=document.createElement("a");x.href=M,x.download=y.name,x.click(),x.remove(),setTimeout(()=>{window.URL.revokeObjectURL(M)},200)}return(y,M)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreFileInput"},{default:Xe(()=>[Z("div",pse,[Ce(hse,{multiple:l.value,"accepted-file-types":i.value,"total-size-limit":m,onDrop:b},null,8,["multiple","accepted-file-types"]),E(c).length>0?($(),R("ul",fse,[($(!0),R(Je,null,Ot(E(c),x=>($(),R("li",{key:x.id},[Ce(rse,{status:g.value?"uploading":"ready",name:x.name,size:x.size,onDownload:S=>v(x.file)},null,8,["status","name","size","onDownload"])]))),128))])):ge("",!0),_.value?($(),R("div",mse,[Z("span",null,je(_.value),1)])):ge("",!0)])]),_:1},8,["label"]))}}),_se=ke(Mse,[["__scopeId","data-v-bac48dfb"]]),Y2=new Map;function bse(){function e(a){const n=Y2.get(a);if(n!==void 0)return n;const r=fetch(a,{method:"HEAD"}).then(o=>{if(o.ok)return o.headers.get("Content-Type")||void 0}).catch(()=>{});return Y2.set(a,r),r}function t(){Y2.clear()}return{fetchAssetContentType:e,clearCache:t}}const wse=["src"],xse=$e({__name:"SharedImgWithFallback",props:{urls:{type:Array,required:!0},loaderMaxWidthPx:{type:Number,default:void 0},loaderMaxHeightPx:{type:Number,default:void 0}},setup(e){const t=e,a=H(()=>{const c={};return t.loaderMaxWidthPx!==void 0&&(c.maxWidth=`${t.loaderMaxWidthPx}px`,c.width=`${t.loaderMaxWidthPx}px`),t.loaderMaxHeightPx!==void 0&&(c.maxHeight=`${t.loaderMaxHeightPx}px`,c.height=`${t.loaderMaxHeightPx}px`),c}),n=ye(""),r=ye(!0),o=ye([]);let s=0;const{fetchAssetContentType:i}=bse();function l(c,d){return c.length!==d.length?!1:c.every((u,h)=>u===d[h])}return We(mn(t,"urls"),async c=>{if(l(c,o.value))return;o.value=[...c],r.value=!0,n.value="";const d=++s;for(const u of c){if(d!==s)return;const h=await i(u);if(d!==s)return;if(!(!h||h==="text/html")){n.value=u;break}}d===s&&(r.value=!1)},{immediate:!0}),(c,d)=>r.value?($(),Ie($0,{key:0,class:"skeleton",style:bt(a.value)},null,8,["style"])):($(),R("img",{key:1,src:n.value},null,8,wse))}}),qg=ke(xse,[["__scopeId","data-v-dd586442"]]),Cse={};function Ase(e,t){return $(),Ie(m0,{name:"slide-fade"},{default:Xe(()=>[qt(e.$slots,"default",{},void 0,!0)]),_:3})}const Sse=ke(Cse,[["render",Ase],["__scopeId","data-v-75fe1e40"]]),$se={key:1,class:"WdsSelect__trigger__multiSelectLabel"},Ese={key:0,class:"WdsSelect__trigger__multiSelectLabel__placeholder"},Ise=["data-writer-tooltip"],kse={class:"WdsSelect__trigger__arrow"},Tse=$e({__name:"WdsSelect",props:Fn({options:{type:Array,default:()=>[]},placeholder:{type:String,required:!1,default:void 0},defaultIcon:{type:String,required:!1,default:void 0},hideIcons:{type:Boolean,required:!1},enableSearch:{type:Boolean,required:!1},enableMultiSelection:{type:Boolean,required:!1},loading:{type:Boolean,required:!1}},{modelValue:{type:[String,Array],required:!0,default:void 0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=sr({loader:()=>zt(()=>import("./WdsDropdownMenu-BPKaOD8s.js").then(v=>v.b),__vite__mapDeps([4,5,6,7]),import.meta.url)}),a=e,n=ir(e,"modelValue"),r=ye(!1),o=pt("trigger"),s=pt("dropdown"),i=H(()=>a.enableSearch?[]:[i6({allowedPlacements:["bottom","top"]})]),{floatingStyles:l,update:c}=c6(o,s,{placement:"bottom",middleware:i}),d=H(()=>n.value?(Array.isArray(n.value)?n.value:[n.value]).filter(Boolean):[]),u=H(()=>d.value.map(v=>a.options.find(y=>y.value===v)??{value:v,label:v})),h=H(()=>n.value&&!a.options.some(v=>v.value===n.value)),f=H(()=>h.value?String(n.value):u.value.map(v=>v.label).sort().join(" / ")),m=H(()=>{var v;return h.value?"circle-question-mark":a.hideIcons?"":((v=u.value.at(0))==null?void 0:v.icon)??a.defaultIcon??"circle-question-mark"}),g=b0(o);We(g,()=>{g.value||setTimeout(()=>r.value=!1,300)},{immediate:!0});function _(v){a.enableMultiSelection||(r.value=!1),n.value=v}function b(v){Array.isArray(n.value)&&(n.value=n.value.filter(y=>y!==v))}return(v,y)=>($(),R("div",{ref_key:"trigger",ref:o,class:"WdsSelect"},[Z("div",{class:"WdsSelect__trigger",role:"button",tabindex:"0",onClick:y[0]||(y[0]=M=>r.value=!r.value),onKeydown:y[1]||(y[1]=Sr(M=>r.value=!r.value,["enter"]))},[(h.value||!e.hideIcons)&&!e.enableMultiSelection?($(),R(Je,{key:0},[Array.isArray(m.value)?($(),Ie(qg,{key:0,urls:m.value,"loader-max-width-px":18,"loader-max-height-px":18},null,8,["urls"])):($(),Ie(_t,{key:1,name:m.value},null,8,["name"]))],64)):ge("",!0),e.enableMultiSelection?($(),R("div",$se,[($(!0),R(Je,null,Ot(u.value,M=>($(),Ie(zg,{key:M.value,text:M.label,closable:"",onClose:x=>b(M.value)},null,8,["text","onClose"]))),128)),u.value.length===0&&e.placeholder?($(),R("p",Ese,je(e.placeholder),1)):ge("",!0)])):($(),R("div",{key:2,class:"WdsSelect__trigger__label","data-writer-tooltip-strategy":"overflow","data-writer-tooltip":f.value},je(f.value??e.placeholder),9,Ise)),Z("div",kse,[Ce(_t,{name:r.value?"chevron-up":"chevron-down"},null,8,["name"])])],32),Ce(Sse,null,{default:Xe(()=>[r.value?($(),Ie(E(t),{key:0,ref_key:"dropdown",ref:s,"enable-search":e.enableSearch,"enable-multi-selection":e.enableMultiSelection,"hide-icons":e.hideIcons,loading:e.loading,options:e.options,selected:n.value,style:bt(E(l)),onSelect:_,onSearch:E(c)},null,8,["enable-search","enable-multi-selection","hide-icons","loading","options","selected","style","onSearch"])):ge("",!0)]),_:1})],512))}}),Ed=ke(Tse,[["__scopeId","data-v-da33a38f"]]),Hde=Object.freeze(Object.defineProperty({__proto__:null,default:Ed},Symbol.toStringTag,{value:"Module"})),Pse="A user input component that allows users to select multiple values from a searchable list of options.",ym={a:"Option A",b:"Option B"},Lse=`
8334
+ file_handle.write(file_data)`.trim(),yse={writer:{name:"File input",description:vse,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},allowFileTypes:{name:"Allowed file types",type:Q.Text,init:[".pdf",".txt",".doc",".docx","image/*"].join(", "),desc:"Provides hints for browsers to select the correct file types. You can specify extensions and MIME types separated by comma, or leave empty to accept any file."},allowMultipleFiles:Ut({name:"Allow multiple files",default:"no"}),cssClasses:mt},events:{"wf-file-change":{desc:"Capture changes to this control.",stub:gse,bindable:!0,eventPayloadExample:[{name:"hello.txt",type:"text/plain",data:"data:text/plain;base64,SGVsbG8gd29ybGQK"}]}}}},Mse=$e({...yse,__name:"CoreFileInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a),i=H(()=>{var y;return(((y=t.allowFileTypes)==null?void 0:y.value)??"").split(",")}),l=H(()=>!!t.allowMultipleFiles.value),{files:c,calcTotalSize:d,replaceFiles:u,encodeFiles:h,decodeFiles:f}=Ag({multiple:l});ia(async()=>{if(Array.isArray(o.value)){const{decodedFiles:y}=await f(o.value);u(y)}});const m=200*1024*1024,g=ye(!1),_=ye(null);async function b(y){if(g.value)return;if(d(y)>m){_.value=`Files are too big. Total size limit is ${fl(m)}.`;return}g.value=!0,_.value=null,u(y);const{encodedFiles:M}=await h();if(M.length===0){g.value=!1;return}s(M,"wf-file-change"),g.value=!1}function v(y){const M=window.URL.createObjectURL(y),x=document.createElement("a");x.href=M,x.download=y.name,x.click(),x.remove(),setTimeout(()=>{window.URL.revokeObjectURL(M)},200)}return(y,M)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreFileInput"},{default:Xe(()=>[Z("div",pse,[Ce(hse,{multiple:l.value,"accepted-file-types":i.value,"total-size-limit":m,onDrop:b},null,8,["multiple","accepted-file-types"]),E(c).length>0?($(),R("ul",fse,[($(!0),R(Je,null,Ot(E(c),x=>($(),R("li",{key:x.id},[Ce(rse,{status:g.value?"uploading":"ready",name:x.name,size:x.size,onDownload:S=>v(x.file)},null,8,["status","name","size","onDownload"])]))),128))])):ge("",!0),_.value?($(),R("div",mse,[Z("span",null,je(_.value),1)])):ge("",!0)])]),_:1},8,["label"]))}}),_se=ke(Mse,[["__scopeId","data-v-bac48dfb"]]),Y2=new Map;function bse(){function e(a){const n=Y2.get(a);if(n!==void 0)return n;const r=fetch(a,{method:"HEAD"}).then(o=>{if(o.ok)return o.headers.get("Content-Type")||void 0}).catch(()=>{});return Y2.set(a,r),r}function t(){Y2.clear()}return{fetchAssetContentType:e,clearCache:t}}const wse=["src"],xse=$e({__name:"SharedImgWithFallback",props:{urls:{type:Array,required:!0},loaderMaxWidthPx:{type:Number,default:void 0},loaderMaxHeightPx:{type:Number,default:void 0}},setup(e){const t=e,a=H(()=>{const c={};return t.loaderMaxWidthPx!==void 0&&(c.maxWidth=`${t.loaderMaxWidthPx}px`,c.width=`${t.loaderMaxWidthPx}px`),t.loaderMaxHeightPx!==void 0&&(c.maxHeight=`${t.loaderMaxHeightPx}px`,c.height=`${t.loaderMaxHeightPx}px`),c}),n=ye(""),r=ye(!0),o=ye([]);let s=0;const{fetchAssetContentType:i}=bse();function l(c,d){return c.length!==d.length?!1:c.every((u,h)=>u===d[h])}return We(mn(t,"urls"),async c=>{if(l(c,o.value))return;o.value=[...c],r.value=!0,n.value="";const d=++s;for(const u of c){if(d!==s)return;const h=await i(u);if(d!==s)return;if(!(!h||h==="text/html")){n.value=u;break}}d===s&&(r.value=!1)},{immediate:!0}),(c,d)=>r.value?($(),Ie($0,{key:0,class:"skeleton",style:wt(a.value)},null,8,["style"])):($(),R("img",{key:1,src:n.value},null,8,wse))}}),qg=ke(xse,[["__scopeId","data-v-dd586442"]]),Cse={};function Ase(e,t){return $(),Ie(m0,{name:"slide-fade"},{default:Xe(()=>[qt(e.$slots,"default",{},void 0,!0)]),_:3})}const Sse=ke(Cse,[["render",Ase],["__scopeId","data-v-75fe1e40"]]),$se={key:1,class:"WdsSelect__trigger__multiSelectLabel"},Ese={key:0,class:"WdsSelect__trigger__multiSelectLabel__placeholder"},Ise=["data-writer-tooltip"],kse={class:"WdsSelect__trigger__arrow"},Tse=$e({__name:"WdsSelect",props:jn({options:{type:Array,default:()=>[]},placeholder:{type:String,required:!1,default:void 0},defaultIcon:{type:String,required:!1,default:void 0},hideIcons:{type:Boolean,required:!1},enableSearch:{type:Boolean,required:!1},enableMultiSelection:{type:Boolean,required:!1},loading:{type:Boolean,required:!1}},{modelValue:{type:[String,Array],required:!0,default:void 0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=ir({loader:()=>zt(()=>import("./WdsDropdownMenu-C1nXnj7Y.js").then(v=>v.b),__vite__mapDeps([4,5,6,7]),import.meta.url)}),a=e,n=lr(e,"modelValue"),r=ye(!1),o=pt("trigger"),s=pt("dropdown"),i=H(()=>a.enableSearch?[]:[i6({allowedPlacements:["bottom","top"]})]),{floatingStyles:l,update:c}=c6(o,s,{placement:"bottom",middleware:i}),d=H(()=>n.value?(Array.isArray(n.value)?n.value:[n.value]).filter(Boolean):[]),u=H(()=>d.value.map(v=>a.options.find(y=>y.value===v)??{value:v,label:v})),h=H(()=>n.value&&!a.options.some(v=>v.value===n.value)),f=H(()=>h.value?String(n.value):u.value.map(v=>v.label).sort().join(" / ")),m=H(()=>{var v;return h.value?"circle-question-mark":a.hideIcons?"":((v=u.value.at(0))==null?void 0:v.icon)??a.defaultIcon??"circle-question-mark"}),g=b0(o);We(g,()=>{g.value||setTimeout(()=>r.value=!1,300)},{immediate:!0});function _(v){a.enableMultiSelection||(r.value=!1),n.value=v}function b(v){Array.isArray(n.value)&&(n.value=n.value.filter(y=>y!==v))}return(v,y)=>($(),R("div",{ref_key:"trigger",ref:o,class:"WdsSelect"},[Z("div",{class:"WdsSelect__trigger",role:"button",tabindex:"0",onClick:y[0]||(y[0]=M=>r.value=!r.value),onKeydown:y[1]||(y[1]=$r(M=>r.value=!r.value,["enter"]))},[(h.value||!e.hideIcons)&&!e.enableMultiSelection?($(),R(Je,{key:0},[Array.isArray(m.value)?($(),Ie(qg,{key:0,urls:m.value,"loader-max-width-px":18,"loader-max-height-px":18},null,8,["urls"])):($(),Ie(bt,{key:1,name:m.value},null,8,["name"]))],64)):ge("",!0),e.enableMultiSelection?($(),R("div",$se,[($(!0),R(Je,null,Ot(u.value,M=>($(),Ie(zg,{key:M.value,text:M.label,closable:"",onClose:x=>b(M.value)},null,8,["text","onClose"]))),128)),u.value.length===0&&e.placeholder?($(),R("p",Ese,je(e.placeholder),1)):ge("",!0)])):($(),R("div",{key:2,class:"WdsSelect__trigger__label","data-writer-tooltip-strategy":"overflow","data-writer-tooltip":f.value},je(f.value??e.placeholder),9,Ise)),Z("div",kse,[Ce(bt,{name:r.value?"chevron-up":"chevron-down"},null,8,["name"])])],32),Ce(Sse,null,{default:Xe(()=>[r.value?($(),Ie(E(t),{key:0,ref_key:"dropdown",ref:s,"enable-search":e.enableSearch,"enable-multi-selection":e.enableMultiSelection,"hide-icons":e.hideIcons,loading:e.loading,options:e.options,selected:n.value,style:wt(E(l)),onSelect:_,onSearch:E(c)},null,8,["enable-search","enable-multi-selection","hide-icons","loading","options","selected","style","onSearch"])):ge("",!0)]),_:1})],512))}}),Ed=ke(Tse,[["__scopeId","data-v-da33a38f"]]),Hde=Object.freeze(Object.defineProperty({__proto__:null,default:Ed},Symbol.toStringTag,{value:"Module"})),Pse="A user input component that allows users to select multiple values from a searchable list of options.",ym={a:"Option A",b:"Option B"},Lse=`
8335
8335
  def onchange_handler(state, payload):
8336
8336
 
8337
8337
  # Set the state variable "selected" to the selected option
8338
8338
 
8339
- state["selected"] = payload`,Vse={writer:{deprecated:!0,name:"Multiselect input",description:Pse,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(ym,null,2),validator:no},placeholder:{name:"Placeholder",desc:"Text to show when no options are selected.",type:Q.Text},maximumCount:{name:"Maximum count",desc:"The maximum allowable number of selected options. Set to zero for unlimited.",type:Q.Number,default:"0",validator:fn},accentColor:{...Ia,desc:"The colour of the chips created for each selected option."},chipTextColor:{name:"Chip text",type:Q.Color,default:Ht.White,desc:"The colour of the text in the chips.",category:ot.Style,applyStyleVariable:!0},primaryTextColor:ua,containerBackgroundColor:kr,separatorColor:wa,cssClasses:mt},events:{"wf-options-change":{desc:"Sent when the selected options change.",stub:Lse.trim(),bindable:!0,eventPayloadExample:Object.keys(ym)}}}},Ose=$e({...Vse,__name:"CoreMultiselectInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a),i=H(()=>t.maximumCount.value?c.value.length>=t.maximumCount.value:!1),l=H(()=>Object.entries(t.options.value).map(([d,u])=>({value:d,label:String(u),disabled:i.value&&!c.value.includes(d)}))),c=H({get(){return o.value??[]},set(d){s(d,"wf-options-change")}});return(d,u)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreMultiselectInput"},{default:Xe(()=>[Ce(Ed,{modelValue:c.value,"onUpdate:modelValue":u[0]||(u[0]=h=>c.value=h),options:l.value,placeholder:E(t).placeholder.value,"enable-multi-selection":"","hide-icons":""},null,8,["modelValue","options","placeholder"])]),_:1},8,["label"]))}}),Hse=ke(Ose,[["__scopeId","data-v-6bf2991d"]]),Rse=["value","placeholder","min","max","step"],Nse="A user input component that allows users to enter numeric values.",Mm=`
8339
+ state["selected"] = payload`,Vse={writer:{deprecated:!0,name:"Multiselect input",description:Pse,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(ym,null,2),validator:ro},placeholder:{name:"Placeholder",desc:"Text to show when no options are selected.",type:Q.Text},maximumCount:{name:"Maximum count",desc:"The maximum allowable number of selected options. Set to zero for unlimited.",type:Q.Number,default:"0",validator:fn},accentColor:{...Ia,desc:"The colour of the chips created for each selected option."},chipTextColor:{name:"Chip text",type:Q.Color,default:Ht.White,desc:"The colour of the text in the chips.",category:ot.Style,applyStyleVariable:!0},primaryTextColor:ua,containerBackgroundColor:Tr,separatorColor:wa,cssClasses:mt},events:{"wf-options-change":{desc:"Sent when the selected options change.",stub:Lse.trim(),bindable:!0,eventPayloadExample:Object.keys(ym)}}}},Ose=$e({...Vse,__name:"CoreMultiselectInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a),i=H(()=>t.maximumCount.value?c.value.length>=t.maximumCount.value:!1),l=H(()=>Object.entries(t.options.value).map(([d,u])=>({value:d,label:String(u),disabled:i.value&&!c.value.includes(d)}))),c=H({get(){return o.value??[]},set(d){s(d,"wf-options-change")}});return(d,u)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreMultiselectInput"},{default:Xe(()=>[Ce(Ed,{modelValue:c.value,"onUpdate:modelValue":u[0]||(u[0]=h=>c.value=h),options:l.value,placeholder:E(t).placeholder.value,"enable-multi-selection":"","hide-icons":""},null,8,["modelValue","options","placeholder"])]),_:1},8,["label"]))}}),Hse=ke(Ose,[["__scopeId","data-v-6bf2991d"]]),Rse=["value","placeholder","min","max","step"],Nse="A user input component that allows users to enter numeric values.",Mm=`
8340
8340
  def onchange_handler(state, payload):
8341
8341
 
8342
8342
  # Set the state variable "new_val" to the new value
@@ -8346,17 +8346,17 @@ def onchange_handler(state, payload):
8346
8346
 
8347
8347
  # Set the state variable "selected" to the selected radio option
8348
8348
 
8349
- state["selected"] = payload`,Wse={writer:{name:"Radio input",description:zse,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(_m,null,2),validator:no},orientation:{name:"Orientation",type:Q.Text,options:{vertical:"Vertical",horizontal:"Horizontal"},default:"vertical",category:ot.Style,desc:"Specify how to lay out the options."},primaryTextColor:ua,accentColor:Ia,cssClasses:mt},events:{"wf-option-change":{desc:"Sent when the selected option changes.",stub:qse.trim(),bindable:!0,eventPayloadExample:Object.keys(_m)[0]}}}},Zse=$e({...Wse,__name:"CoreRadioInput",setup(e){const t=re(ne.evaluatedFields),a=re(ne.flattenedInstancePath),n=ye(null),r=re(ne.core),o=re(ne.instancePath),{formValue:s,handleInput:i}=Va(r,o,n);return(l,c)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:n,label:E(t).label.value,class:"CoreRadioInput"},{default:Xe(()=>[Z("div",{class:ft(["options",{horizontal:E(t).orientation.value=="horizontal"}])},[($(!0),R(Je,null,Ot(E(t).options.value,(d,u)=>($(),R("div",{key:u,class:"option"},[Z("input",{id:`${E(a)}-option-${u}`,type:"radio",checked:E(s)===u,value:u,name:`${E(a)}-options`,onInput:h=>E(i)(u,"wf-option-change")},null,40,jse),Z("label",{for:`${E(a)}-option-${u}`},je(d),9,Use)]))),128))],2)]),_:1},8,["label"]))}}),Kse=ke(Zse,[["__scopeId","data-v-3334f78f"]]),Gse="A user input component that allows users to select a single or multiples value(s) from a searchable list of options.",bm={a:"Option A",b:"Option B"},wm=`
8349
+ state["selected"] = payload`,Wse={writer:{name:"Radio input",description:zse,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(_m,null,2),validator:ro},orientation:{name:"Orientation",type:Q.Text,options:{vertical:"Vertical",horizontal:"Horizontal"},default:"vertical",category:ot.Style,desc:"Specify how to lay out the options."},primaryTextColor:ua,accentColor:Ia,cssClasses:mt},events:{"wf-option-change":{desc:"Sent when the selected option changes.",stub:qse.trim(),bindable:!0,eventPayloadExample:Object.keys(_m)[0]}}}},Zse=$e({...Wse,__name:"CoreRadioInput",setup(e){const t=re(ne.evaluatedFields),a=re(ne.flattenedInstancePath),n=ye(null),r=re(ne.core),o=re(ne.instancePath),{formValue:s,handleInput:i}=Va(r,o,n);return(l,c)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:n,label:E(t).label.value,class:"CoreRadioInput"},{default:Xe(()=>[Z("div",{class:ft(["options",{horizontal:E(t).orientation.value=="horizontal"}])},[($(!0),R(Je,null,Ot(E(t).options.value,(d,u)=>($(),R("div",{key:u,class:"option"},[Z("input",{id:`${E(a)}-option-${u}`,type:"radio",checked:E(s)===u,value:u,name:`${E(a)}-options`,onInput:h=>E(i)(u,"wf-option-change")},null,40,jse),Z("label",{for:`${E(a)}-option-${u}`},je(d),9,Use)]))),128))],2)]),_:1},8,["label"]))}}),Kse=ke(Zse,[["__scopeId","data-v-3334f78f"]]),Gse="A user input component that allows users to select a single or multiples value(s) from a searchable list of options.",bm={a:"Option A",b:"Option B"},wm=`
8350
8350
  def onchange_handler(state, payload):
8351
8351
 
8352
8352
  # Set the state variable "selected" to the selected option
8353
8353
 
8354
- state["selected"] = payload`,Jse={writer:{name:"Select input",description:Gse,docs:"This component provides a searchable dropdown for selecting one or multiple values. Usage: supply the Options field with a key-value object; open the dropdown and use the search box at the top to filter options by label (and detail, when provided). Configuration: Enable multi-selection via the 'Allow Multi-select' field; set a placeholder and limit selections with 'Maximum count' (applies only to multi-select). Limitations: search is client-side, case-insensitive, and matches label/detail text only (not the option key); no remote/async search; very large option lists are filtered in-memory.",category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},allowMultiSelect:{name:"Allow Multi-select",desc:"Select more than one option from the dropdown.",type:Q.Boolean},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(bm,null,2),validator:no},placeholder:{name:"Placeholder",desc:"Text to show when no options are selected.",type:Q.Text},maximumCount:{name:"Maximum count",desc:"The maximum allowable number of selected options. Set to zero for unlimited.",type:Q.Number,default:"0",validator:fn,enabled(e){return!!e.evaluatedFields.allowMultiSelect.value}},accentColor:Ia,primaryTextColor:ua,chipTextColor:{name:"Chip text",type:Q.Color,default:Ht.White,desc:"The colour of the text in the chips.",category:ot.Style,applyStyleVariable:!0,enabled(e){return!!e.evaluatedFields.allowMultiSelect.value}},containerBackgroundColor:kr,separatorColor:wa,cssClasses:mt},events:{"wf-option-change":{desc:"Sent when the selected option changes.",stub:wm.trim(),bindable:!0,enabled(e){return!e.evaluatedFields.allowMultiSelect.value}},"wf-options-change":{desc:"Sent when the selected options change.",stub:wm.trim(),bindable:!0,eventPayloadExample:Object.keys(bm),enabled(e){return!!e.evaluatedFields.allowMultiSelect.value}}}}},Xse=$e({...Jse,__name:"CoreSelectInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a),i=H(()=>Object.entries(t.options.value).map(([c,d])=>({value:c,label:String(d)}))),l=H({get(){return o.value},set(c){const d=t.allowMultiSelect.value?"wf-options-change":"wf-option-change";s(c,d)}});return(c,d)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreSelectInput"},{default:Xe(()=>[Ce(Ed,{modelValue:l.value,"onUpdate:modelValue":d[0]||(d[0]=u=>l.value=u),options:i.value,placeholder:E(t).placeholder.value,"enable-multi-selection":E(t).allowMultiSelect.value,"enable-search":"","hide-icons":""},null,8,["modelValue","options","placeholder","enable-multi-selection"])]),_:1},8,["label"]))}}),Yse=ke(Xse,[["__scopeId","data-v-5a8cb016"]]);function ml(e,t){const a=H(()=>{var n;return((n=String(t.value).split(".")[1])==null?void 0:n.length)??0});return H(()=>Number(e.value).toFixed(a.value))}const Qse={class:"BaseInputRange__popover__content"},eie=$e({__name:"BaseInputSliderThumb",props:Fn({min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},sliderBoundingRect:{type:Object,default:void 0},popoverDisplayMode:{type:String,default:"onChange"}},{value:{type:Number,default:50},valueModifiers:{}}),emits:["update:value"],setup(e,{expose:t}){const a=e;t({handleMouseDown:f,getOffsetLeft:m});const n=ir(e,"value"),r=pt("thumb"),o=ml(n,mn(a,"step")),s=H(()=>typeof n.value!="number"?50:(n.value-a.min)/(a.max-a.min)*100),i=ye(a.popoverDisplayMode==="always");let l=null;We(mn(a.popoverDisplayMode),()=>{a.popoverDisplayMode==="always"&&(i.value=!0)});function c(){a.popoverDisplayMode!=="always"&&(i.value=!0,l&&(clearTimeout(l),l=null),l=setTimeout(()=>{i.value=!1,l=null},1e3))}const d=H(()=>`${s.value}%`),u=H(()=>`${s.value}%`);function h(g){if(c(),a.min!==void 0&&g<a.min||a.max!==void 0&&g>a.max)return;const _=g-a.min,b=Math.round(_/a.step),v=a.min+b*a.step;n.value!==v&&(n.value=v)}function f(g){document.addEventListener("mousemove",b),document.addEventListener("mouseup",v);const _=a.sliderBoundingRect;b(g);function b(y){const M=(y.x-_.left)/(_.right-_.left);if(M>1||M<0)return;const x=(a.max-a.min)*M+a.min;h(x)}function v(){document.removeEventListener("mouseup",v),document.removeEventListener("mousemove",b)}}function m(){return r.value.offsetLeft}return(g,_)=>($(),R(Je,null,[Ce(m0,null,{default:Xe(()=>[Ya(Z("div",{class:"BaseInputRange__popover",style:bt({left:u.value})},[Z("span",Qse,je(E(o)),1)],4),[[jn,i.value]])]),_:1}),Z("button",{ref_key:"thumb",ref:r,type:"button",class:"BaseInputRange__thumb",style:bt({left:d.value}),"aria-label":"Use the arrow keys to increase or decrease the value.",onKeydown:[_[0]||(_[0]=Sr(b=>h(+n.value-e.step),["left"])),_[1]||(_[1]=Sr(b=>h(+n.value+e.step),["right"]))],onMousedown:f},null,36)],64))}}),Wg=ke(eie,[["__scopeId","data-v-f2261a8d"]]),tie=["aria-valuemin","aria-valuemax"],aie=$e({__name:"BaseInputSliderLayout",props:{min:{type:Number,default:0},max:{type:Number,default:100},popoverDisplayMode:{type:String,default:"onChange"}},setup(e){return(t,a)=>($(),R("div",{role:"slider","aria-valuemin":e.min,"aria-valuemax":e.max,class:ft(["BaseInputRange",{"BaseInputRange--popover-always-visible":e.popoverDisplayMode==="always"}])},[qt(t.$slots,"default",{},void 0,!0)],10,tie))}}),Zg=ke(aie,[["__scopeId","data-v-4583336d"]]);function Kg(e,t=500){const a=ye(),n=setInterval(()=>{var r;a.value=(r=e.value)==null?void 0:r.getBoundingClientRect()},t);return Wn(()=>{clearInterval(n)}),H(()=>a.value)}const nie=9,rie=$e({__name:"BaseInputSlider",props:Fn({min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},popoverDisplayMode:{type:String,default:"onChange"}},{value:{type:Number,default:50},valueModifiers:{}}),emits:["update:value"],setup(e){const t=e,a=ir(e,"value"),n=pt("slider"),r=pt("thumb"),o=ml(a,mn(t,"step")),s=H(()=>typeof a.value!="number"?50:(a.value-t.min)/(t.max-t.min)*100),i=Kg(n);return We(()=>t.min,()=>{typeof a.value=="number"&&a.value<t.min&&(a.value=t.min)},{immediate:!0}),We(()=>t.max,()=>{typeof a.value=="number"&&a.value>t.max&&(a.value=t.max)},{immediate:!0}),(l,c)=>($(),Ie(Zg,{min:e.min,max:e.max,"popover-display-mode":e.popoverDisplayMode,"aria-valuenow":e.value,"aria-valuetext":`${E(o)} (${Math.round(s.value)}%)`},{default:Xe(()=>[Z("div",{ref_key:"slider",ref:n,class:"BaseInputRange__slider",onMousedown:c[0]||(c[0]=(...d)=>E(r).handleMouseDown&&E(r).handleMouseDown(...d))},[Z("div",{class:"BaseInputRange__slider__progress",style:bt({width:`calc(${s.value}% + ${nie}px)`})},null,4)],544),Ce(Wg,{ref_key:"thumb",ref:r,value:e.value,min:e.min,max:e.max,step:e.step,"popover-display-mode":e.popoverDisplayMode,"slider-bounding-rect":E(i),"onUpdate:value":c[1]||(c[1]=d=>a.value=d)},null,8,["value","min","max","step","popover-display-mode","slider-bounding-rect"])]),_:1},8,["min","max","popover-display-mode","aria-valuenow","aria-valuetext"]))}}),oie="A user input component that allows users to select numeric values using a slider with optional constraints like min, max, and step.",sie=`
8354
+ state["selected"] = payload`,Jse={writer:{name:"Select input",description:Gse,docs:"This component provides a searchable dropdown for selecting one or multiple values. Usage: supply the Options field with a key-value object; open the dropdown and use the search box at the top to filter options by label (and detail, when provided). Configuration: Enable multi-selection via the 'Allow Multi-select' field; set a placeholder and limit selections with 'Maximum count' (applies only to multi-select). Limitations: search is client-side, case-insensitive, and matches label/detail text only (not the option key); no remote/async search; very large option lists are filtered in-memory.",category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},allowMultiSelect:{name:"Allow Multi-select",desc:"Select more than one option from the dropdown.",type:Q.Boolean},options:{name:"Options",desc:"Key-value object with options. Must be a JSON string or a state reference to a dictionary.",type:Q.KeyValue,default:JSON.stringify(bm,null,2),validator:ro},placeholder:{name:"Placeholder",desc:"Text to show when no options are selected.",type:Q.Text},maximumCount:{name:"Maximum count",desc:"The maximum allowable number of selected options. Set to zero for unlimited.",type:Q.Number,default:"0",validator:fn,enabled(e){return!!e.evaluatedFields.allowMultiSelect.value}},accentColor:Ia,primaryTextColor:ua,chipTextColor:{name:"Chip text",type:Q.Color,default:Ht.White,desc:"The colour of the text in the chips.",category:ot.Style,applyStyleVariable:!0,enabled(e){return!!e.evaluatedFields.allowMultiSelect.value}},containerBackgroundColor:Tr,separatorColor:wa,cssClasses:mt},events:{"wf-option-change":{desc:"Sent when the selected option changes.",stub:wm.trim(),bindable:!0,enabled(e){return!e.evaluatedFields.allowMultiSelect.value}},"wf-options-change":{desc:"Sent when the selected options change.",stub:wm.trim(),bindable:!0,eventPayloadExample:Object.keys(bm),enabled(e){return!!e.evaluatedFields.allowMultiSelect.value}}}}},Xse=$e({...Jse,__name:"CoreSelectInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a),i=H(()=>Object.entries(t.options.value).map(([c,d])=>({value:c,label:String(d)}))),l=H({get(){return o.value},set(c){const d=t.allowMultiSelect.value?"wf-options-change":"wf-option-change";s(c,d)}});return(c,d)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreSelectInput"},{default:Xe(()=>[Ce(Ed,{modelValue:l.value,"onUpdate:modelValue":d[0]||(d[0]=u=>l.value=u),options:i.value,placeholder:E(t).placeholder.value,"enable-multi-selection":E(t).allowMultiSelect.value,"enable-search":"","hide-icons":""},null,8,["modelValue","options","placeholder","enable-multi-selection"])]),_:1},8,["label"]))}}),Yse=ke(Xse,[["__scopeId","data-v-5a8cb016"]]);function ml(e,t){const a=H(()=>{var n;return((n=String(t.value).split(".")[1])==null?void 0:n.length)??0});return H(()=>Number(e.value).toFixed(a.value))}const Qse={class:"BaseInputRange__popover__content"},eie=$e({__name:"BaseInputSliderThumb",props:jn({min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},sliderBoundingRect:{type:Object,default:void 0},popoverDisplayMode:{type:String,default:"onChange"}},{value:{type:Number,default:50},valueModifiers:{}}),emits:["update:value"],setup(e,{expose:t}){const a=e;t({handleMouseDown:f,getOffsetLeft:m});const n=lr(e,"value"),r=pt("thumb"),o=ml(n,mn(a,"step")),s=H(()=>typeof n.value!="number"?50:(n.value-a.min)/(a.max-a.min)*100),i=ye(a.popoverDisplayMode==="always");let l=null;We(mn(a.popoverDisplayMode),()=>{a.popoverDisplayMode==="always"&&(i.value=!0)});function c(){a.popoverDisplayMode!=="always"&&(i.value=!0,l&&(clearTimeout(l),l=null),l=setTimeout(()=>{i.value=!1,l=null},1e3))}const d=H(()=>`${s.value}%`),u=H(()=>`${s.value}%`);function h(g){if(c(),a.min!==void 0&&g<a.min||a.max!==void 0&&g>a.max)return;const _=g-a.min,b=Math.round(_/a.step),v=a.min+b*a.step;n.value!==v&&(n.value=v)}function f(g){document.addEventListener("mousemove",b),document.addEventListener("mouseup",v);const _=a.sliderBoundingRect;b(g);function b(y){const M=(y.x-_.left)/(_.right-_.left);if(M>1||M<0)return;const x=(a.max-a.min)*M+a.min;h(x)}function v(){document.removeEventListener("mouseup",v),document.removeEventListener("mousemove",b)}}function m(){return r.value.offsetLeft}return(g,_)=>($(),R(Je,null,[Ce(m0,null,{default:Xe(()=>[Ya(Z("div",{class:"BaseInputRange__popover",style:wt({left:u.value})},[Z("span",Qse,je(E(o)),1)],4),[[Un,i.value]])]),_:1}),Z("button",{ref_key:"thumb",ref:r,type:"button",class:"BaseInputRange__thumb",style:wt({left:d.value}),"aria-label":"Use the arrow keys to increase or decrease the value.",onKeydown:[_[0]||(_[0]=$r(b=>h(+n.value-e.step),["left"])),_[1]||(_[1]=$r(b=>h(+n.value+e.step),["right"]))],onMousedown:f},null,36)],64))}}),Wg=ke(eie,[["__scopeId","data-v-f2261a8d"]]),tie=["aria-valuemin","aria-valuemax"],aie=$e({__name:"BaseInputSliderLayout",props:{min:{type:Number,default:0},max:{type:Number,default:100},popoverDisplayMode:{type:String,default:"onChange"}},setup(e){return(t,a)=>($(),R("div",{role:"slider","aria-valuemin":e.min,"aria-valuemax":e.max,class:ft(["BaseInputRange",{"BaseInputRange--popover-always-visible":e.popoverDisplayMode==="always"}])},[qt(t.$slots,"default",{},void 0,!0)],10,tie))}}),Zg=ke(aie,[["__scopeId","data-v-4583336d"]]);function Kg(e,t=500){const a=ye(),n=setInterval(()=>{var r;a.value=(r=e.value)==null?void 0:r.getBoundingClientRect()},t);return Zn(()=>{clearInterval(n)}),H(()=>a.value)}const nie=9,rie=$e({__name:"BaseInputSlider",props:jn({min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},popoverDisplayMode:{type:String,default:"onChange"}},{value:{type:Number,default:50},valueModifiers:{}}),emits:["update:value"],setup(e){const t=e,a=lr(e,"value"),n=pt("slider"),r=pt("thumb"),o=ml(a,mn(t,"step")),s=H(()=>typeof a.value!="number"?50:(a.value-t.min)/(t.max-t.min)*100),i=Kg(n);return We(()=>t.min,()=>{typeof a.value=="number"&&a.value<t.min&&(a.value=t.min)},{immediate:!0}),We(()=>t.max,()=>{typeof a.value=="number"&&a.value>t.max&&(a.value=t.max)},{immediate:!0}),(l,c)=>($(),Ie(Zg,{min:e.min,max:e.max,"popover-display-mode":e.popoverDisplayMode,"aria-valuenow":e.value,"aria-valuetext":`${E(o)} (${Math.round(s.value)}%)`},{default:Xe(()=>[Z("div",{ref_key:"slider",ref:n,class:"BaseInputRange__slider",onMousedown:c[0]||(c[0]=(...d)=>E(r).handleMouseDown&&E(r).handleMouseDown(...d))},[Z("div",{class:"BaseInputRange__slider__progress",style:wt({width:`calc(${s.value}% + ${nie}px)`})},null,4)],544),Ce(Wg,{ref_key:"thumb",ref:r,value:e.value,min:e.min,max:e.max,step:e.step,"popover-display-mode":e.popoverDisplayMode,"slider-bounding-rect":E(i),"onUpdate:value":c[1]||(c[1]=d=>a.value=d)},null,8,["value","min","max","step","popover-display-mode","slider-bounding-rect"])]),_:1},8,["min","max","popover-display-mode","aria-valuenow","aria-valuetext"]))}}),oie="A user input component that allows users to select numeric values using a slider with optional constraints like min, max, and step.",sie=`
8355
8355
  def onchange_handler(state, payload):
8356
8356
 
8357
8357
  # Set the state variable "new_val" to the new value
8358
8358
 
8359
- state["new_val"] = payload`,iie={writer:{name:"Slider input",description:oie,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},minValue:{name:"Minimum value",type:Q.Number,default:"0",init:"0"},maxValue:{name:"Maximum value",type:Q.Number,default:"100",init:"100"},stepSize:{name:"Step size",type:Q.Number,default:"1",init:"1",validator:fn},accentColor:Ia,popoverColor:{name:"Popover color",type:Q.Color,category:ot.Style,applyStyleVariable:!0,default:"white"},popoverBackgroundColor:{name:"Popover background",type:Q.Color,category:ot.Style,applyStyleVariable:!0,default:"rgba(0, 0, 0, 1)"},cssClasses:mt},events:{"wf-number-change":{desc:"Capture changes to this control.",stub:sie,bindable:!0}}}},lie=$e({...iie,__name:"CoreSliderInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a,50);return(i,l)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreSliderInput"},{default:Xe(()=>[Ce(rie,{"popover-display-mode":"always",value:E(o),min:E(t).minValue.value,max:E(t).maxValue.value,step:E(t).stepSize.value,"onUpdate:value":l[0]||(l[0]=c=>E(s)(c,"wf-number-change"))},null,8,["value","min","max","step"])]),_:1},8,["label"]))}}),cie=ke(lie,[["__scopeId","data-v-7ea51f87"]]),die=9,uie=$e({__name:"BaseInputSliderRange",props:Fn({min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},popoverDisplayMode:{type:String,default:"onChange"}},{value:{type:Array,default:()=>[20,60]},valueModifiers:{}}),emits:["update:value"],setup(e){const t=e,a=ir(e,"value");function n(_,b){const v=[...a.value];v[_]=b,a.value=v.sort((y,M)=>y-M)}const r=pt("slider"),o=pt("thumbs");function s(_){const b=o.value[0],v=o.value[1],y=Math.abs(_.x-b.getOffsetLeft()),M=Math.abs(_.x-v.getOffsetLeft());y>M?v.handleMouseDown(_):b.handleMouseDown(_)}const i=H(()=>Math.min(...a.value)),l=H(()=>Math.max(...a.value)),c=mn(t,"step"),d=ml(i,c),u=ml(l,c),h=H(()=>`from ${d} to ${u}`),f=H(()=>typeof i.value!="number"?50:(i.value-t.min)/(t.max-t.min)*100),m=H(()=>typeof l.value!="number"?50:(l.value-t.min)/(t.max-t.min)*100-f.value),g=Kg(r);return We(()=>t.min,()=>{a.value.some(_=>_<t.min)&&(a.value=a.value.map(_=>_<t.min?t.min:_))},{immediate:!0}),We(()=>t.max,()=>{a.value.some(_=>_>t.max)&&(a.value=a.value.map(_=>_>t.max?t.max:_))},{immediate:!0}),(_,b)=>($(),Ie(Zg,{class:"BaseInputRangeSlider",min:e.min,max:e.max,"popover-display-mode":e.popoverDisplayMode,"aria-valuetext":h.value},{default:Xe(()=>[Z("div",{ref_key:"slider",ref:r,class:"BaseInputRange__slider",onMousedown:s},[Z("div",{class:"BaseInputRange__slider__progress",style:bt({width:`calc(${m.value}% + ${die}px)`,marginLeft:`${f.value}%`})},null,4)],544),($(),R(Je,null,Ot([0,1],v=>Ce(Wg,{key:v,ref_for:!0,ref_key:"thumbs",ref:o,value:e.value[v],min:e.min,max:e.max,step:c.value,"popover-display-mode":e.popoverDisplayMode,"slider-bounding-rect":E(g),"onUpdate:value":y=>n(v?1:0,y)},null,8,["value","min","max","step","popover-display-mode","slider-bounding-rect","onUpdate:value"])),64))]),_:1},8,["min","max","popover-display-mode","aria-valuetext"]))}}),hie="A user input component that allows users to select numeric values range using a range slider with optional constraints like min, max, and step.",pie=`
8359
+ state["new_val"] = payload`,iie={writer:{name:"Slider input",description:oie,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},minValue:{name:"Minimum value",type:Q.Number,default:"0",init:"0"},maxValue:{name:"Maximum value",type:Q.Number,default:"100",init:"100"},stepSize:{name:"Step size",type:Q.Number,default:"1",init:"1",validator:fn},accentColor:Ia,popoverColor:{name:"Popover color",type:Q.Color,category:ot.Style,applyStyleVariable:!0,default:"white"},popoverBackgroundColor:{name:"Popover background",type:Q.Color,category:ot.Style,applyStyleVariable:!0,default:"rgba(0, 0, 0, 1)"},cssClasses:mt},events:{"wf-number-change":{desc:"Capture changes to this control.",stub:sie,bindable:!0}}}},lie=$e({...iie,__name:"CoreSliderInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a,50);return(i,l)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,class:"CoreSliderInput"},{default:Xe(()=>[Ce(rie,{"popover-display-mode":"always",value:E(o),min:E(t).minValue.value,max:E(t).maxValue.value,step:E(t).stepSize.value,"onUpdate:value":l[0]||(l[0]=c=>E(s)(c,"wf-number-change"))},null,8,["value","min","max","step"])]),_:1},8,["label"]))}}),cie=ke(lie,[["__scopeId","data-v-7ea51f87"]]),die=9,uie=$e({__name:"BaseInputSliderRange",props:jn({min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},popoverDisplayMode:{type:String,default:"onChange"}},{value:{type:Array,default:()=>[20,60]},valueModifiers:{}}),emits:["update:value"],setup(e){const t=e,a=lr(e,"value");function n(_,b){const v=[...a.value];v[_]=b,a.value=v.sort((y,M)=>y-M)}const r=pt("slider"),o=pt("thumbs");function s(_){const b=o.value[0],v=o.value[1],y=Math.abs(_.x-b.getOffsetLeft()),M=Math.abs(_.x-v.getOffsetLeft());y>M?v.handleMouseDown(_):b.handleMouseDown(_)}const i=H(()=>Math.min(...a.value)),l=H(()=>Math.max(...a.value)),c=mn(t,"step"),d=ml(i,c),u=ml(l,c),h=H(()=>`from ${d} to ${u}`),f=H(()=>typeof i.value!="number"?50:(i.value-t.min)/(t.max-t.min)*100),m=H(()=>typeof l.value!="number"?50:(l.value-t.min)/(t.max-t.min)*100-f.value),g=Kg(r);return We(()=>t.min,()=>{a.value.some(_=>_<t.min)&&(a.value=a.value.map(_=>_<t.min?t.min:_))},{immediate:!0}),We(()=>t.max,()=>{a.value.some(_=>_>t.max)&&(a.value=a.value.map(_=>_>t.max?t.max:_))},{immediate:!0}),(_,b)=>($(),Ie(Zg,{class:"BaseInputRangeSlider",min:e.min,max:e.max,"popover-display-mode":e.popoverDisplayMode,"aria-valuetext":h.value},{default:Xe(()=>[Z("div",{ref_key:"slider",ref:r,class:"BaseInputRange__slider",onMousedown:s},[Z("div",{class:"BaseInputRange__slider__progress",style:wt({width:`calc(${m.value}% + ${die}px)`,marginLeft:`${f.value}%`})},null,4)],544),($(),R(Je,null,Ot([0,1],v=>Ce(Wg,{key:v,ref_for:!0,ref_key:"thumbs",ref:o,value:e.value[v],min:e.min,max:e.max,step:c.value,"popover-display-mode":e.popoverDisplayMode,"slider-bounding-rect":E(g),"onUpdate:value":y=>n(v?1:0,y)},null,8,["value","min","max","step","popover-display-mode","slider-bounding-rect","onUpdate:value"])),64))]),_:1},8,["min","max","popover-display-mode","aria-valuetext"]))}}),hie="A user input component that allows users to select numeric values range using a range slider with optional constraints like min, max, and step.",pie=`
8360
8360
  def onchange_handler(state, payload):
8361
8361
 
8362
8362
  # Set the state variables "from" & "to" to the new range
@@ -8381,24 +8381,24 @@ def onchange_handler(state, payload):
8381
8381
 
8382
8382
  # Set the state variable "rating" to the new value
8383
8383
 
8384
- state["rating"] = payload`,Die={writer:{name:"Rating input",description:Rie,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},feedback:{name:"Feedback",default:"stars",type:Q.Text,options:{stars:"Stars",faces:"Faces",hearts:"Hearts"}},minValue:{name:"Minimum value",type:Q.Number,default:"1",desc:"Valid values are 0 and 1.",validator:_i(0,1)},maxValue:{name:"Max value",type:Q.Number,default:"5",desc:"Valid values are between 2 and 11.",validator:_i(2,11)},valueStep:{name:"Step",type:Q.Number,default:"1",desc:"Valid values are between 0.25 and 1.",validator:_i(.25,1)},accentColor:Ia,primaryTextColor:ua,cssClasses:mt},events:{"wf-number-change":{stub:Nie,bindable:!0}}}},Bie=$e({...Die,__name:"CoreRatingInput",setup(e){const t=re(ne.evaluatedFields),a=pt("rootInstance"),n=pt("unitsEl"),r=re(ne.core),o=re(ne.instancePath),s=ye(null),{formValue:i,handleInput:l}=Va(r,o,a);function c(M){const x=M.offsetX,S=n.value.querySelectorAll(".unit");let L=0;return S.forEach(F=>{const te=F;x>te.offsetLeft+te.offsetWidth?L++:x>te.offsetLeft&&(L+=(x-te.offsetLeft)/te.offsetWidth)}),L}function d(M){let x=Math.ceil(M/v.value)*v.value;return x=Math.max(Math.min(x,b.value),_.value),x}function u(M){const x=c(M);return d(x)}function h(M){const x=u(M);s.value=x}function f(){s.value=null}function m(M){const x=Math.max(Math.min(M,b.value),_.value),S=45,L=95,F=(x-_.value)/(b.value-_.value),te=F*-10,J=70+te,be=S+F*(L-S)+te;return`M30,${J} Q50,${be} 70,${J}`}function g(M){const x=u(M);l(x,"wf-number-change")}const _=H(()=>Math.max(Math.min(t.minValue.value,1),0)),b=H(()=>Math.max(Math.min(t.maxValue.value,11),2)),v=H(()=>Math.max(Math.min(t.valueStep.value,1),.25)),y=H(()=>{if(s.value!==null)return s.value;const M=parseFloat(i.value);return isNaN(M)?null:M});return(M,x)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,class:"CoreRatingInput",label:E(t).label.value},{default:Xe(()=>[Z("div",{ref_key:"unitsEl",ref:n,class:ft(["units",{valueSet:y.value!==null}]),onClick:g,onMousemove:h,onMouseout:f},[($(!0),R(Je,null,Ot([...Array(b.value).keys()],S=>($(),R("div",{key:S,class:ft(["unit",E(t).feedback.value])},[Z("div",{class:"filler",style:bt({width:`${y.value>S?Math.min(y.value-S,1)*100:0}%`})},null,4),y.value!==null?($(),R("div",Lie)):ge("",!0),E(t).feedback.value=="faces"?($(),R("div",Vie,[($(),R("svg",Oie,[x[0]||(x[0]=Z("circle",{class:"eye left",cx:"35",cy:"38",r:"6"},null,-1)),x[1]||(x[1]=Z("circle",{class:"eye right",cx:"65",cy:"38",r:"6"},null,-1)),Z("path",{class:"mouth",d:m(y.value??S+1)},null,8,Hie)]))])):ge("",!0)],2))),128))],34)]),_:1},8,["label"]))}}),Fie=ke(Bie,[["__scopeId","data-v-43de0eef"]]),jie=["aria-checked","onKeydown"],Uie="A user input component with a simple on/off status.",zie=`
8384
+ state["rating"] = payload`,Die={writer:{name:"Rating input",description:Rie,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},feedback:{name:"Feedback",default:"stars",type:Q.Text,options:{stars:"Stars",faces:"Faces",hearts:"Hearts"}},minValue:{name:"Minimum value",type:Q.Number,default:"1",desc:"Valid values are 0 and 1.",validator:_i(0,1)},maxValue:{name:"Max value",type:Q.Number,default:"5",desc:"Valid values are between 2 and 11.",validator:_i(2,11)},valueStep:{name:"Step",type:Q.Number,default:"1",desc:"Valid values are between 0.25 and 1.",validator:_i(.25,1)},accentColor:Ia,primaryTextColor:ua,cssClasses:mt},events:{"wf-number-change":{stub:Nie,bindable:!0}}}},Bie=$e({...Die,__name:"CoreRatingInput",setup(e){const t=re(ne.evaluatedFields),a=pt("rootInstance"),n=pt("unitsEl"),r=re(ne.core),o=re(ne.instancePath),s=ye(null),{formValue:i,handleInput:l}=Va(r,o,a);function c(M){const x=M.offsetX,S=n.value.querySelectorAll(".unit");let L=0;return S.forEach(F=>{const te=F;x>te.offsetLeft+te.offsetWidth?L++:x>te.offsetLeft&&(L+=(x-te.offsetLeft)/te.offsetWidth)}),L}function d(M){let x=Math.ceil(M/v.value)*v.value;return x=Math.max(Math.min(x,b.value),_.value),x}function u(M){const x=c(M);return d(x)}function h(M){const x=u(M);s.value=x}function f(){s.value=null}function m(M){const x=Math.max(Math.min(M,b.value),_.value),S=45,L=95,F=(x-_.value)/(b.value-_.value),te=F*-10,J=70+te,be=S+F*(L-S)+te;return`M30,${J} Q50,${be} 70,${J}`}function g(M){const x=u(M);l(x,"wf-number-change")}const _=H(()=>Math.max(Math.min(t.minValue.value,1),0)),b=H(()=>Math.max(Math.min(t.maxValue.value,11),2)),v=H(()=>Math.max(Math.min(t.valueStep.value,1),.25)),y=H(()=>{if(s.value!==null)return s.value;const M=parseFloat(i.value);return isNaN(M)?null:M});return(M,x)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,class:"CoreRatingInput",label:E(t).label.value},{default:Xe(()=>[Z("div",{ref_key:"unitsEl",ref:n,class:ft(["units",{valueSet:y.value!==null}]),onClick:g,onMousemove:h,onMouseout:f},[($(!0),R(Je,null,Ot([...Array(b.value).keys()],S=>($(),R("div",{key:S,class:ft(["unit",E(t).feedback.value])},[Z("div",{class:"filler",style:wt({width:`${y.value>S?Math.min(y.value-S,1)*100:0}%`})},null,4),y.value!==null?($(),R("div",Lie)):ge("",!0),E(t).feedback.value=="faces"?($(),R("div",Vie,[($(),R("svg",Oie,[x[0]||(x[0]=Z("circle",{class:"eye left",cx:"35",cy:"38",r:"6"},null,-1)),x[1]||(x[1]=Z("circle",{class:"eye right",cx:"65",cy:"38",r:"6"},null,-1)),Z("path",{class:"mouth",d:m(y.value??S+1)},null,8,Hie)]))])):ge("",!0)],2))),128))],34)]),_:1},8,["label"]))}}),Fie=ke(Bie,[["__scopeId","data-v-43de0eef"]]),jie=["aria-checked","onKeydown"],Uie="A user input component with a simple on/off status.",zie=`
8385
8385
  def handle_toggle(state, payload):
8386
8386
 
8387
8387
  # The payload will be a bool
8388
8388
 
8389
- state["its_on"] = payload`,qie={writer:{name:"Switch input",description:Uie,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},accentColor:Ia,primaryTextColor:ua,separatorColor:wa,cssClasses:mt},events:{"wf-toggle":{desc:"Sent when the switch is toggled.",stub:zie.trim(),bindable:!0}}}},Wie=$e({...qie,__name:"CoreSwitchInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a);function i(){s(!o.value,"wf-toggle")}return(l,c)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,"is-horizontal":!0,class:"CoreSwitchInput"},{default:Xe(()=>[Z("div",{class:ft(["switch",{on:!!E(o)}]),tabindex:"0",role:"switch","aria-checked":!!E(o),onClick:i,onKeydown:Sr(sn(i,["prevent"]),["enter","space"])},c[0]||(c[0]=[Z("div",{class:"toggle"},null,-1)]),42,jie)]),_:1},8,["label"]))}}),Zie=ke(Wie,[["__scopeId","data-v-b438aa37"]]),Kie=$e({__name:"BaseContainer",props:{contentHAlign:{},contentVAlign:{},contentPadding:{},isHorizontal:{type:Boolean}},setup(e){const t=e,a=H(()=>{const n={padding:t.contentPadding};return t.isHorizontal?{...n,justifyContent:t.contentHAlign,alignItems:t.contentVAlign}:{...n,alignItems:t.contentHAlign,justifyContent:t.contentVAlign}});return(n,r)=>($(),R("div",{class:ft(["BaseContainer",{horizontal:t.isHorizontal}]),style:bt(a.value),"data-writer-container":""},[qt(n.$slots,"default",{},void 0,!0)],6))}}),Gi=ke(Kie,[["__scopeId","data-v-4caa740e"]]),Gie=$e({__name:"BaseCollapseButton",props:Fn({direction:{type:String,required:!0}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,a=ir(e,"modelValue"),n=H(()=>{switch(t.direction){case"left-right":return"chevron-left";case"top-bottom":return"chevron-up";case"right-left":return"chevron-right";case"bottom-top":return"chevron-down";default:return"chevron-up"}});return(r,o)=>($(),Ie(La,{class:ft(["BaseCollapseIcon",{"BaseCollapseIcon--collapsed":a.value}]),variant:"tertiary",size:"icon",onClick:o[0]||(o[0]=s=>a.value=!a.value)},{default:Xe(()=>[Ce(_t,{name:n.value},null,8,["name"])]),_:1},8,["class"]))}}),Id=ke(Gie,[["__scopeId","data-v-9cca227f"]]),Jie={key:0,class:"header"},Xie={key:0,class:"titleContainer"},Yie={key:0},Qie={key:1,class:"collapsedTitle"},e1e={class:"transformed"},t1e={class:"content"},a1e="A layout component that organizes its child components in columns. Must be inside a Column container component.",n1e={writer:{name:"Column",description:a1e,allowedParentTypes:["columns","repeater"],allowedChildrenTypes:["*"],category:"Layout",fields:{title:{name:"Title",type:Q.Text},width:{name:"Width (factor)",default:"1",init:"1",type:Q.Number,desc:"Relative size when compared to other columns in the same container. A column of width 2 will be double the width of one with width 1.",category:ot.Style,validator:fn},isSticky:Ut({name:"Sticky",default:"no",category:ot.Style}),isCollapsible:ug,startCollapsed:{...Cd,desc:"Only applied when the column is collapsible."},separatorColor:wa,contentPadding:Ds,contentHAlign:Ns,contentVAlign:wd,cssClasses:mt}}},r1e=$e({...n1e,__name:"CoreColumn",setup(e){const t=re(ne.instancePath),a=re(ne.instanceData),n=re(ne.core),r=re(ne.componentId),o=re(ne.evaluatedFields),s=H(()=>!!o.isCollapsible.value),i=ye(o.isCollapsible.value&&o.startCollapsed.value),l=H(()=>{let f;return i.value?f="0 0 32px":f=`${o.width.value} 0 0`,{flex:f}}),c=H(()=>{var f,m;return h.value>=((m=(f=u.value)==null?void 0:f.value)==null?void 0:m.minimumNonCollapsiblePosition)}),d=H(()=>c.value?"right-left":"left-right"),u=H(()=>{var f;for(let m=-1;m>-1*t.length;m--){const g=t.at(m);if(((f=n.getComponentById(g.componentId))==null?void 0:f.type)!=="columns")continue;return a.at(m)}return null}),h=H(()=>{var f;return(f=n.getComponentById(r))==null?void 0:f.position});return We([()=>o.isCollapsible.value,h],()=>{const f=u.value;f&&(f.value={minimumNonCollapsiblePosition:void 0})}),We(u,f=>{!f||!f.value||s.value||typeof f.value.minimumNonCollapsiblePosition<"u"&&h.value>=f.value.minimumNonCollapsiblePosition||(f.value.minimumNonCollapsiblePosition=h.value)},{immediate:!0,deep:!0}),(f,m)=>($(),R("div",{class:ft(["CoreColumn",{sticky:E(o).isSticky.value,collapsible:s.value,collapsibleToRight:c.value,collapsed:i.value}]),style:bt(l.value)},[E(o).title.value||s.value?($(),R("div",Jie,[i.value?ge("",!0):($(),R("div",Xie,[E(o).title.value?($(),R("h3",Yie,je(E(o).title.value),1)):ge("",!0)])),s.value?($(),Ie(Id,{key:1,modelValue:i.value,"onUpdate:modelValue":m[0]||(m[0]=g=>i.value=g),class:"collapser",direction:d.value},null,8,["modelValue","direction"])):ge("",!0)])):ge("",!0),i.value&&E(o).title.value?($(),R("div",Qie,[Z("div",e1e,[Z("div",t1e,je(E(o).title.value),1)])])):ge("",!0),Ce(Gi,{class:"container","aria-expanded":s.value?i.value:null,"content-h-align":E(o).contentHAlign.value,"content-v-align":E(o).contentVAlign.value,"content-padding":E(o).contentPadding.value},{default:Xe(()=>[qt(f.$slots,"default",{},void 0,!0)]),_:3},8,["aria-expanded","content-h-align","content-v-align","content-padding"])],6))}}),o1e=ke(r1e,[["__scopeId","data-v-8fec53be"]]),s1e={class:"CoreColumns horizontal","data-writer-container":""},i1e={writer:{name:"Column container",description:"Serves as container for Column components",allowedChildrenTypes:["column","repeater","separator"],category:"Layout",fields:{cssClasses:mt}}},l1e=$e({...i1e,__name:"CoreColumns",setup(e){const t=re(ne.instanceData);return t.at(-1).value={minimumNonCollapsiblePosition:void 0},(a,n)=>($(),R("div",s1e,[qt(a.$slots,"default",{},void 0,!0)]))}}),c1e=ke(l1e,[["__scopeId","data-v-6df125f4"]]),d1e={class:"CoreHeader"},u1e={class:"container horizontal","data-writer-container":""},h1e="A container component that typically contains the main navigation elements.",p1e={writer:{deprecated:!0,name:"Header",description:h1e,category:"Layout",allowedChildrenTypes:["*"],fields:{text:{name:"Text",init:"Header Text",default:"(No text)",type:Q.Text},primaryTextColor:ua,cssClasses:mt},previewField:"text"}},f1e=$e({...p1e,__name:"CoreHeader",setup(e){const t=re(ne.evaluatedFields);return(a,n)=>($(),R("div",d1e,[Z("h1",null,je(E(t).text.value),1),Z("div",u1e,[qt(a.$slots,"default",{},void 0,!0)])]))}}),m1e=ke(f1e,[["__scopeId","data-v-7913ee71"]]),v1e="A layout component that stacks its child components horizontally, wrapping them to the next row if necessary.",g1e={writer:{name:"Horizontal stack",description:v1e,allowedChildrenTypes:["*"],category:"Layout",fields:{contentPadding:{...Ds,default:"0"},contentHAlign:Ns,contentVAlign:wd,cssClasses:mt}}},y1e=$e({...g1e,__name:"CoreHorizontalStack",setup(e){const t=re(ne.evaluatedFields);return(a,n)=>($(),Ie(Gi,{class:"CoreHorizontalStack","content-h-align":E(t).contentHAlign.value,"content-v-align":E(t).contentVAlign.value,"content-padding":E(t).contentPadding.value,"is-horizontal":!0},{default:Xe(()=>[qt(a.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-v-align","content-padding"]))}}),M1e=ke(y1e,[["__scopeId","data-v-39b6da8e"]]),_1e="A container component that divides the layout into sections, with an optional title.",b1e={writer:{name:"Section",description:_1e,category:"Layout",allowedChildrenTypes:["*"],fields:{title:{name:"Title",init:"Section Title",desc:"Leave blank to hide.",type:Q.Text},isCollapsible:ug,startCollapsed:Cd,accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:kr,containerShadow:Rs,separatorColor:wa,buttonColor:cr,buttonTextColor:dr,buttonShadow:so,contentPadding:{...Ds,default:"16px"},contentHAlign:Ns,cssClasses:mt},previewField:"title"}},w1e=$e({...b1e,__name:"CoreSection",setup(e){const t=re(ne.evaluatedFields),a=H(()=>t.isCollapsible.value),n=ye(a.value&&t.startCollapsed.value);return(r,o)=>($(),R("section",{class:ft(["CoreSection",{"CoreSection--collapsible":a.value}])},[E(t).title.value||a.value?($(),R("div",{key:0,class:ft(["CoreSection__title",{"CoreSection__title--collapsed":a.value&&n.value}])},[Z("h3",null,je(E(t).title.value),1),a.value?($(),Ie(Id,{key:0,modelValue:n.value,"onUpdate:modelValue":o[0]||(o[0]=s=>n.value=s),direction:"top-bottom"},null,8,["modelValue"])):ge("",!0)],2)):ge("",!0),n.value?ge("",!0):($(),Ie(Gi,{key:1,"content-h-align":E(t).contentHAlign.value,"content-padding":E(t).contentPadding.value,"aria-expanded":a.value?n.value:null},{default:Xe(()=>[qt(r.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-padding","aria-expanded"]))],2))}}),x1e=ke(w1e,[["__scopeId","data-v-8bef68a0"]]),C1e="A visual component to create a separation between adjacent elements.",Gg={writer:{name:"Separator",description:C1e,category:"Layout",fields:{separatorColor:wa,cssClasses:mt}}},Am=e=>{e.writer&&(e.writer.docs=`_Separator_ components are used to separate layout elements. They can be used in most containers, including _Column container_ to separate columns.
8389
+ state["its_on"] = payload`,qie={writer:{name:"Switch input",description:Uie,category:"Input",fields:{label:{name:"Label",init:"Input Label",type:Q.Text},accentColor:Ia,primaryTextColor:ua,separatorColor:wa,cssClasses:mt},events:{"wf-toggle":{desc:"Sent when the switch is toggled.",stub:zie.trim(),bindable:!0}}}},Wie=$e({...qie,__name:"CoreSwitchInput",setup(e){const t=re(ne.evaluatedFields),a=ye(null),n=re(ne.core),r=re(ne.instancePath),{formValue:o,handleInput:s}=Va(n,r,a);function i(){s(!o.value,"wf-toggle")}return(l,c)=>($(),Ie(Wa,{ref_key:"rootInstance",ref:a,label:E(t).label.value,"is-horizontal":!0,class:"CoreSwitchInput"},{default:Xe(()=>[Z("div",{class:ft(["switch",{on:!!E(o)}]),tabindex:"0",role:"switch","aria-checked":!!E(o),onClick:i,onKeydown:$r(sn(i,["prevent"]),["enter","space"])},c[0]||(c[0]=[Z("div",{class:"toggle"},null,-1)]),42,jie)]),_:1},8,["label"]))}}),Zie=ke(Wie,[["__scopeId","data-v-b438aa37"]]),Kie=$e({__name:"BaseContainer",props:{contentHAlign:{},contentVAlign:{},contentPadding:{},isHorizontal:{type:Boolean}},setup(e){const t=e,a=H(()=>{const n={padding:t.contentPadding};return t.isHorizontal?{...n,justifyContent:t.contentHAlign,alignItems:t.contentVAlign}:{...n,alignItems:t.contentHAlign,justifyContent:t.contentVAlign}});return(n,r)=>($(),R("div",{class:ft(["BaseContainer",{horizontal:t.isHorizontal}]),style:wt(a.value),"data-writer-container":""},[qt(n.$slots,"default",{},void 0,!0)],6))}}),Gi=ke(Kie,[["__scopeId","data-v-4caa740e"]]),Gie=$e({__name:"BaseCollapseButton",props:jn({direction:{type:String,required:!0}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,a=lr(e,"modelValue"),n=H(()=>{switch(t.direction){case"left-right":return"chevron-left";case"top-bottom":return"chevron-up";case"right-left":return"chevron-right";case"bottom-top":return"chevron-down";default:return"chevron-up"}});return(r,o)=>($(),Ie(La,{class:ft(["BaseCollapseIcon",{"BaseCollapseIcon--collapsed":a.value}]),variant:"tertiary",size:"icon",onClick:o[0]||(o[0]=s=>a.value=!a.value)},{default:Xe(()=>[Ce(bt,{name:n.value},null,8,["name"])]),_:1},8,["class"]))}}),Id=ke(Gie,[["__scopeId","data-v-9cca227f"]]),Jie={key:0,class:"header"},Xie={key:0,class:"titleContainer"},Yie={key:0},Qie={key:1,class:"collapsedTitle"},e1e={class:"transformed"},t1e={class:"content"},a1e="A layout component that organizes its child components in columns. Must be inside a Column container component.",n1e={writer:{name:"Column",description:a1e,allowedParentTypes:["columns","repeater"],allowedChildrenTypes:["*"],category:"Layout",fields:{title:{name:"Title",type:Q.Text},width:{name:"Width (factor)",default:"1",init:"1",type:Q.Number,desc:"Relative size when compared to other columns in the same container. A column of width 2 will be double the width of one with width 1.",category:ot.Style,validator:fn},isSticky:Ut({name:"Sticky",default:"no",category:ot.Style}),isCollapsible:ug,startCollapsed:{...Cd,desc:"Only applied when the column is collapsible."},separatorColor:wa,contentPadding:Bs,contentHAlign:Ds,contentVAlign:wd,cssClasses:mt}}},r1e=$e({...n1e,__name:"CoreColumn",setup(e){const t=re(ne.instancePath),a=re(ne.instanceData),n=re(ne.core),r=re(ne.componentId),o=re(ne.evaluatedFields),s=H(()=>!!o.isCollapsible.value),i=ye(o.isCollapsible.value&&o.startCollapsed.value),l=H(()=>{let f;return i.value?f="0 0 32px":f=`${o.width.value} 0 0`,{flex:f}}),c=H(()=>{var f,m;return h.value>=((m=(f=u.value)==null?void 0:f.value)==null?void 0:m.minimumNonCollapsiblePosition)}),d=H(()=>c.value?"right-left":"left-right"),u=H(()=>{var f;for(let m=-1;m>-1*t.length;m--){const g=t.at(m);if(((f=n.getComponentById(g.componentId))==null?void 0:f.type)!=="columns")continue;return a.at(m)}return null}),h=H(()=>{var f;return(f=n.getComponentById(r))==null?void 0:f.position});return We([()=>o.isCollapsible.value,h],()=>{const f=u.value;f&&(f.value={minimumNonCollapsiblePosition:void 0})}),We(u,f=>{!f||!f.value||s.value||typeof f.value.minimumNonCollapsiblePosition<"u"&&h.value>=f.value.minimumNonCollapsiblePosition||(f.value.minimumNonCollapsiblePosition=h.value)},{immediate:!0,deep:!0}),(f,m)=>($(),R("div",{class:ft(["CoreColumn",{sticky:E(o).isSticky.value,collapsible:s.value,collapsibleToRight:c.value,collapsed:i.value}]),style:wt(l.value)},[E(o).title.value||s.value?($(),R("div",Jie,[i.value?ge("",!0):($(),R("div",Xie,[E(o).title.value?($(),R("h3",Yie,je(E(o).title.value),1)):ge("",!0)])),s.value?($(),Ie(Id,{key:1,modelValue:i.value,"onUpdate:modelValue":m[0]||(m[0]=g=>i.value=g),class:"collapser",direction:d.value},null,8,["modelValue","direction"])):ge("",!0)])):ge("",!0),i.value&&E(o).title.value?($(),R("div",Qie,[Z("div",e1e,[Z("div",t1e,je(E(o).title.value),1)])])):ge("",!0),Ce(Gi,{class:"container","aria-expanded":s.value?i.value:null,"content-h-align":E(o).contentHAlign.value,"content-v-align":E(o).contentVAlign.value,"content-padding":E(o).contentPadding.value},{default:Xe(()=>[qt(f.$slots,"default",{},void 0,!0)]),_:3},8,["aria-expanded","content-h-align","content-v-align","content-padding"])],6))}}),o1e=ke(r1e,[["__scopeId","data-v-8fec53be"]]),s1e={class:"CoreColumns horizontal","data-writer-container":""},i1e={writer:{name:"Column container",description:"Serves as container for Column components",allowedChildrenTypes:["column","repeater","separator"],category:"Layout",fields:{cssClasses:mt}}},l1e=$e({...i1e,__name:"CoreColumns",setup(e){const t=re(ne.instanceData);return t.at(-1).value={minimumNonCollapsiblePosition:void 0},(a,n)=>($(),R("div",s1e,[qt(a.$slots,"default",{},void 0,!0)]))}}),c1e=ke(l1e,[["__scopeId","data-v-6df125f4"]]),d1e={class:"CoreHeader"},u1e={class:"container horizontal","data-writer-container":""},h1e="A container component that typically contains the main navigation elements.",p1e={writer:{deprecated:!0,name:"Header",description:h1e,category:"Layout",allowedChildrenTypes:["*"],fields:{text:{name:"Text",init:"Header Text",default:"(No text)",type:Q.Text},primaryTextColor:ua,cssClasses:mt},previewField:"text"}},f1e=$e({...p1e,__name:"CoreHeader",setup(e){const t=re(ne.evaluatedFields);return(a,n)=>($(),R("div",d1e,[Z("h1",null,je(E(t).text.value),1),Z("div",u1e,[qt(a.$slots,"default",{},void 0,!0)])]))}}),m1e=ke(f1e,[["__scopeId","data-v-7913ee71"]]),v1e="A layout component that stacks its child components horizontally, wrapping them to the next row if necessary.",g1e={writer:{name:"Horizontal stack",description:v1e,allowedChildrenTypes:["*"],category:"Layout",fields:{contentPadding:{...Bs,default:"0"},contentHAlign:Ds,contentVAlign:wd,cssClasses:mt}}},y1e=$e({...g1e,__name:"CoreHorizontalStack",setup(e){const t=re(ne.evaluatedFields);return(a,n)=>($(),Ie(Gi,{class:"CoreHorizontalStack","content-h-align":E(t).contentHAlign.value,"content-v-align":E(t).contentVAlign.value,"content-padding":E(t).contentPadding.value,"is-horizontal":!0},{default:Xe(()=>[qt(a.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-v-align","content-padding"]))}}),M1e=ke(y1e,[["__scopeId","data-v-39b6da8e"]]),_1e="A container component that divides the layout into sections, with an optional title.",b1e={writer:{name:"Section",description:_1e,category:"Layout",allowedChildrenTypes:["*"],fields:{title:{name:"Title",init:"Section Title",desc:"Leave blank to hide.",type:Q.Text},isCollapsible:ug,startCollapsed:Cd,accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:Tr,containerShadow:Ns,separatorColor:wa,buttonColor:dr,buttonTextColor:ur,buttonShadow:io,contentPadding:{...Bs,default:"16px"},contentHAlign:Ds,cssClasses:mt},previewField:"title"}},w1e=$e({...b1e,__name:"CoreSection",setup(e){const t=re(ne.evaluatedFields),a=H(()=>t.isCollapsible.value),n=ye(a.value&&t.startCollapsed.value);return(r,o)=>($(),R("section",{class:ft(["CoreSection",{"CoreSection--collapsible":a.value}])},[E(t).title.value||a.value?($(),R("div",{key:0,class:ft(["CoreSection__title",{"CoreSection__title--collapsed":a.value&&n.value}])},[Z("h3",null,je(E(t).title.value),1),a.value?($(),Ie(Id,{key:0,modelValue:n.value,"onUpdate:modelValue":o[0]||(o[0]=s=>n.value=s),direction:"top-bottom"},null,8,["modelValue"])):ge("",!0)],2)):ge("",!0),n.value?ge("",!0):($(),Ie(Gi,{key:1,"content-h-align":E(t).contentHAlign.value,"content-padding":E(t).contentPadding.value,"aria-expanded":a.value?n.value:null},{default:Xe(()=>[qt(r.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-padding","aria-expanded"]))],2))}}),x1e=ke(w1e,[["__scopeId","data-v-8bef68a0"]]),C1e="A visual component to create a separation between adjacent elements.",Gg={writer:{name:"Separator",description:C1e,category:"Layout",fields:{separatorColor:wa,cssClasses:mt}}},Am=e=>{e.writer&&(e.writer.docs=`_Separator_ components are used to separate layout elements. They can be used in most containers, including _Column container_ to separate columns.
8390
8390
 
8391
- If the container flows horizontally (like a _Horizontal Stack_ or a _Column container_) the _Separator_ will be a vertical line. Otherwise, it'll be a horizontal line.`)},A1e={class:"CoreSeparator separator"};function S1e(e,t,a,n,r,o){return $(),R("div",A1e,t[0]||(t[0]=[Z("div",{class:"line"},null,-1)]))}typeof Am=="function"&&Am(Gg);const $1e=ke(Gg,[["render",S1e],["__scopeId","data-v-0b867210"]]),E1e={class:"collapserContainer"},I1e={class:"container","data-writer-container":""},k1e="A container component that organizes its children in a sidebar. Its parent must be a Page component.",T1e={writer:{name:"Sidebar",description:k1e,positionless:!0,slot:"sidebar",allowedParentTypes:["page"],allowedChildrenTypes:["*"],category:"Layout",fields:{startCollapsed:{...Cd,desc:void 0},sidebarBackgroundColor:{name:"Background",type:Q.Color,category:ot.Style,applyStyleVariable:!0,default:"rgba(255, 255, 255, 0.3)"},accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:kr,containerShadow:Rs,separatorColor:wa,buttonColor:cr,buttonTextColor:dr,buttonShadow:so,cssClasses:mt}}},P1e=$e({...T1e,__name:"CoreSidebar",setup(e){const t=re(ne.evaluatedFields),a=ye(t.startCollapsed.value),n=re(ne.core),r=re(ne.builderManager),o=re(ne.componentId),s=H(()=>r==null?void 0:r.firstSelectedId.value),i=ye(0),l=H(()=>({"max-height":`calc(100vh - ${i.value}px)`}));We(s,d=>{d&&c(d)&&(a.value=!1)});const c=d=>{const u=n.getComponentById(d);return!u||u.type=="root"?!1:u.parentId==o?!0:c(u.parentId)};return ia(()=>{const d=document.querySelector(".ComponentRenderer");i.value=document.body.clientHeight-(d==null?void 0:d.parentElement.clientHeight)}),(d,u)=>($(),R("div",{class:ft(["CoreSidebar",{collapsed:a.value}]),style:bt(l.value)},[Z("div",E1e,[Ce(Id,{modelValue:a.value,"onUpdate:modelValue":u[0]||(u[0]=h=>a.value=h),direction:"left-right"},null,8,["modelValue"])]),Z("div",I1e,[qt(d.$slots,"default",{},void 0,!0)])],6))}}),L1e=ke(P1e,[["__scopeId","data-v-99b92063"]]),V1e=0,Sm=1,O1e="A container component that displays its child components as a tab inside a Tab container.",H1e={writer:{name:"Tab",description:O1e,allowedParentTypes:["tabs","repeater"],allowedChildrenTypes:["*"],category:"Layout",fields:{name:{name:"Name",default:"(No name)",init:"Tab Name",type:Q.Text},contentPadding:{...Ds,default:"16px"},contentHAlign:Ns,cssClasses:mt},previewField:"name"}},R1e=$e({...H1e,__name:"CoreTab",setup(e){const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.instancePath),r=re(ne.instanceData),o=re(ne.core),s=re(ne.builderManager),i=re(ne.componentId),{isComponentVisible:l}=Kl(o),c=H(()=>s==null?void 0:s.firstSelectedId.value),d=()=>{for(let x=-2;x>-1*n.length;x--){const S=n.at(x),{type:L}=o.getComponentById(S.componentId);if(L==="tabs")return x+1}},u=H(()=>{const x=d();return n.at(x)}),h=H(()=>u==null?void 0:u.value.instanceNumber),f=H(()=>h.value===V1e),m=H(()=>h.value===Sm),g=H(()=>l(i)?f.value||m.value&&M.value:!1),_=()=>{for(let x=-1;x>-1*n.length;x--){const S=n.at(x),{type:L}=o.getComponentById(S.componentId);if(L==="tabs")return r.at(x)}},b=()=>{const x=d(),S=n.slice(0,x),L=x+1<0?n.slice(x+1):[];return[...S,{componentId:n.at(x).componentId,instanceNumber:Sm},...L]},v=()=>{const x=_();if(x.value={activeTab:b()},t.value){const S=a.name.value,L=new CustomEvent("wf-tab-change",{detail:{payload:S},bubbles:!0});t.value.dispatchEvent(L)}},y=x=>{const S=o.getComponentById(x);return!S||S.type=="root"?!1:S.parentId==i?!0:y(S.parentId)};We(c,x=>{x&&y(x)&&v()});const M=H(()=>{var F;let x;f.value?x=b():x=n;const L=(F=_().value)==null?void 0:F.activeTab;return JSON.stringify(L)==JSON.stringify(x)});return ks(()=>{var L;if(f.value)return;const x=_();(L=x.value)!=null&&L.activeTab||l(i,n)&&(x.value={activeTab:n})}),(x,S)=>Ya(($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreTab"},[f.value?($(),R("button",{key:0,class:ft(["bit",{active:M.value}]),tabindex:"0",onClick:v},je(E(a).name.value),3)):ge("",!0),m.value?Ya(($(),Ie(Gi,{key:1,class:"container","content-h-align":E(a).contentHAlign.value,"content-padding":E(a).contentPadding.value},{default:Xe(()=>[qt(x.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-padding"])),[[jn,M.value]]):ge("",!0)],512)),[[jn,g.value]])}}),N1e=ke(R1e,[["__scopeId","data-v-0dc960a4"]]),D1e={class:"CoreTabs"},B1e={class:"tabSelector horizontal","data-writer-cage":"","data-writer-container":""},F1e={class:"container"},j1e=`
8391
+ If the container flows horizontally (like a _Horizontal Stack_ or a _Column container_) the _Separator_ will be a vertical line. Otherwise, it'll be a horizontal line.`)},A1e={class:"CoreSeparator separator"};function S1e(e,t,a,n,r,o){return $(),R("div",A1e,t[0]||(t[0]=[Z("div",{class:"line"},null,-1)]))}typeof Am=="function"&&Am(Gg);const $1e=ke(Gg,[["render",S1e],["__scopeId","data-v-0b867210"]]),E1e={class:"collapserContainer"},I1e={class:"container","data-writer-container":""},k1e="A container component that organizes its children in a sidebar. Its parent must be a Page component.",T1e={writer:{name:"Sidebar",description:k1e,positionless:!0,slot:"sidebar",allowedParentTypes:["page"],allowedChildrenTypes:["*"],category:"Layout",fields:{startCollapsed:{...Cd,desc:void 0},sidebarBackgroundColor:{name:"Background",type:Q.Color,category:ot.Style,applyStyleVariable:!0,default:"rgba(255, 255, 255, 0.3)"},accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:Tr,containerShadow:Ns,separatorColor:wa,buttonColor:dr,buttonTextColor:ur,buttonShadow:io,cssClasses:mt}}},P1e=$e({...T1e,__name:"CoreSidebar",setup(e){const t=re(ne.evaluatedFields),a=ye(t.startCollapsed.value),n=re(ne.core),r=re(ne.builderManager),o=re(ne.componentId),s=H(()=>r==null?void 0:r.firstSelectedId.value),i=ye(0),l=H(()=>({"max-height":`calc(100vh - ${i.value}px)`}));We(s,d=>{d&&c(d)&&(a.value=!1)});const c=d=>{const u=n.getComponentById(d);return!u||u.type=="root"?!1:u.parentId==o?!0:c(u.parentId)};return ia(()=>{const d=document.querySelector(".ComponentRenderer");i.value=document.body.clientHeight-(d==null?void 0:d.parentElement.clientHeight)}),(d,u)=>($(),R("div",{class:ft(["CoreSidebar",{collapsed:a.value}]),style:wt(l.value)},[Z("div",E1e,[Ce(Id,{modelValue:a.value,"onUpdate:modelValue":u[0]||(u[0]=h=>a.value=h),direction:"left-right"},null,8,["modelValue"])]),Z("div",I1e,[qt(d.$slots,"default",{},void 0,!0)])],6))}}),L1e=ke(P1e,[["__scopeId","data-v-99b92063"]]),V1e=0,Sm=1,O1e="A container component that displays its child components as a tab inside a Tab container.",H1e={writer:{name:"Tab",description:O1e,allowedParentTypes:["tabs","repeater"],allowedChildrenTypes:["*"],category:"Layout",fields:{name:{name:"Name",default:"(No name)",init:"Tab Name",type:Q.Text},contentPadding:{...Bs,default:"16px"},contentHAlign:Ds,cssClasses:mt},previewField:"name"}},R1e=$e({...H1e,__name:"CoreTab",setup(e){const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.instancePath),r=re(ne.instanceData),o=re(ne.core),s=re(ne.builderManager),i=re(ne.componentId),{isComponentVisible:l}=Kl(o),c=H(()=>s==null?void 0:s.firstSelectedId.value),d=()=>{for(let x=-2;x>-1*n.length;x--){const S=n.at(x),{type:L}=o.getComponentById(S.componentId);if(L==="tabs")return x+1}},u=H(()=>{const x=d();return n.at(x)}),h=H(()=>u==null?void 0:u.value.instanceNumber),f=H(()=>h.value===V1e),m=H(()=>h.value===Sm),g=H(()=>l(i)?f.value||m.value&&M.value:!1),_=()=>{for(let x=-1;x>-1*n.length;x--){const S=n.at(x),{type:L}=o.getComponentById(S.componentId);if(L==="tabs")return r.at(x)}},b=()=>{const x=d(),S=n.slice(0,x),L=x+1<0?n.slice(x+1):[];return[...S,{componentId:n.at(x).componentId,instanceNumber:Sm},...L]},v=()=>{const x=_();if(x.value={activeTab:b()},t.value){const S=a.name.value,L=new CustomEvent("wf-tab-change",{detail:{payload:S},bubbles:!0});t.value.dispatchEvent(L)}},y=x=>{const S=o.getComponentById(x);return!S||S.type=="root"?!1:S.parentId==i?!0:y(S.parentId)};We(c,x=>{x&&y(x)&&v()});const M=H(()=>{var F;let x;f.value?x=b():x=n;const L=(F=_().value)==null?void 0:F.activeTab;return JSON.stringify(L)==JSON.stringify(x)});return Ts(()=>{var L;if(f.value)return;const x=_();(L=x.value)!=null&&L.activeTab||l(i,n)&&(x.value={activeTab:n})}),(x,S)=>Ya(($(),R("div",{ref_key:"rootEl",ref:t,class:"CoreTab"},[f.value?($(),R("button",{key:0,class:ft(["bit",{active:M.value}]),tabindex:"0",onClick:v},je(E(a).name.value),3)):ge("",!0),m.value?Ya(($(),Ie(Gi,{key:1,class:"container","content-h-align":E(a).contentHAlign.value,"content-padding":E(a).contentPadding.value},{default:Xe(()=>[qt(x.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-padding"])),[[Un,M.value]]):ge("",!0)],512)),[[Un,g.value]])}}),N1e=ke(R1e,[["__scopeId","data-v-0dc960a4"]]),D1e={class:"CoreTabs"},B1e={class:"tabSelector horizontal","data-writer-cage":"","data-writer-container":""},F1e={class:"container"},j1e=`
8392
8392
  def tab_change_handler(state, payload):
8393
8393
 
8394
8394
  # The payload contains the name of the newly activated tab
8395
8395
 
8396
- state["active_tab"] = payload`,U1e="A container component for organising and displaying Tab components in a tabbed interface.",z1e={writer:{name:"Tab container",description:U1e,category:"Layout",allowedChildrenTypes:["tab","repeater"],events:{"wf-tab-change":{desc:"Sent when the active tab changes.",stub:j1e.trim(),eventPayloadExample:"Tab Name"}},fields:{accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:kr,containerShadow:Rs,separatorColor:wa,buttonColor:cr,buttonTextColor:dr,buttonShadow:so,cssClasses:mt}}},q1e=$e({...z1e,__name:"CoreTabs",setup(e){const t=re(ne.instanceData);return t.at(-1).value={activeTab:void 0},(a,n)=>($(),R("div",D1e,[Z("nav",B1e,[qt(a.$slots,"default",{instanceNumber:0},void 0,!0)]),Z("div",F1e,[qt(a.$slots,"default",{instanceNumber:1},void 0,!0)])]))}}),W1e=ke(q1e,[["__scopeId","data-v-cbe189a2"]]),Z1e={class:"CoreStep"},K1e=["disabled"],G1e={class:"indicator"},J1e={class:"label"},E1=0,Q2=1,X1e="A container component that displays its child components as a step inside a Step container.",Y1e={writer:{name:"Step",description:X1e,allowedParentTypes:["steps","repeater"],allowedChildrenTypes:["*"],category:"Layout",fields:{name:{name:"Name",default:"(No name)",init:"Step name",type:Q.Text},contentPadding:{...Ds,default:"16px"},isCompleted:Ut({name:"Completed",desc:"Use a state reference to dynamically mark this step as complete.",default:"no"}),contentHAlign:Ns,cssClasses:mt},previewField:"name"}},Q1e=$e({...Y1e,__name:"CoreStep",setup(e){const t=re(ne.evaluatedFields),a=re(ne.instancePath),n=re(ne.instanceData),r=re(ne.isBeingEdited),o=re(ne.core),s=re(ne.builderManager),i=re(ne.componentId),{isComponentVisible:l}=Kl(o),c=H(()=>s==null?void 0:s.firstSelectedId.value),d=h();function u(){for(let M=-1;M>-1*a.length;M--){const x=a.at(M),S=o.getComponentById(x.componentId);if(!S)return;if(S.type==="steps")return M}}function h(){const M=u();if(!(typeof M>"u"))return n.at(M)}function f(){const M=u()+1,x=a.slice(0,M),S=M+1<0?a.slice(M+1):[];return[...x,{componentId:a.at(M).componentId,instanceNumber:Q2},...S]}function m(){d.value={...d.value,activeStep:f()}}function g(){const M=d.value.steps.findIndex(L=>JSON.stringify(L.instancePath)==JSON.stringify(a));if(M==-1||M+1>d.value.steps.length)return;let S=d.value.steps.slice(M+1).find(L=>!L.isCompleted);S||(S=d.value.steps.at(-1)),d.value={...d.value,activeStep:S.instancePath}}function _(M){const x=o.getComponentById(M);return!x||x.type=="root"?!1:x.parentId==i?!0:_(x.parentId)}function b(){if(!t.isCompleted.value){m();return}g()}const v=H(()=>{const M=u()+1;return a.at(M)});We(c,M=>{M&&_(M)&&m()});const y=H(()=>{var S;let M;(v==null?void 0:v.value.instanceNumber)==E1?M=f():M=a;const x=(S=d.value)==null?void 0:S.activeStep;return JSON.stringify(x)==JSON.stringify(M)});return We([y,t.isCompleted],()=>{r.value||y.value&&t.isCompleted.value&&g()}),We(t.isCompleted,(M,x)=>{x&&(M||b())}),ks(()=>{var x;(v==null?void 0:v.value.instanceNumber)==E1||(typeof d.value.steps.find(S=>S.instancePath==a)>"u"&&d.value.steps.push({instancePath:a,isCompleted:t.isCompleted.value}),(x=d.value)==null?void 0:x.activeStep)||l(i,a)&&b()}),Ir(()=>{const M=d.value.steps.findIndex(x=>JSON.stringify(x.instancePath)==JSON.stringify(a));d.value.steps.splice(M,1)}),(M,x)=>{var S,L,F,te;return Ya(($(),R("div",Z1e,[((S=v.value)==null?void 0:S.instanceNumber)==E1?($(),R("button",{key:0,class:ft(["bit",{active:y.value,completed:E(t).isCompleted.value}]),disabled:!E(r),stepindex:"0",onClick:m},[Z("div",G1e,[x[0]||(x[0]=Z("div",{class:"linker left"},null,-1)),Z("div",{class:ft(["status",{completed:E(t).isCompleted.value}])},[E(t).isCompleted.value?($(),Ie(_t,{key:0,name:"check"})):ge("",!0)],2),x[1]||(x[1]=Z("div",{class:"linker right"},null,-1))]),Z("div",J1e,je(E(t).name.value),1)],10,K1e)):ge("",!0),((L=v.value)==null?void 0:L.instanceNumber)==Q2?Ya(($(),Ie(Gi,{key:1,class:"container","content-h-align":E(t).contentHAlign.value,"content-padding":E(t).contentPadding.value},{default:Xe(()=>[qt(M.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-padding"])),[[jn,y.value]]):ge("",!0)],512)),[[jn,((F=v.value)==null?void 0:F.instanceNumber)==E1||((te=v.value)==null?void 0:te.instanceNumber)==Q2&&y.value]])}}}),ele=ke(Q1e,[["__scopeId","data-v-e0ef95ce"]]),tle={class:"CoreSteps"},ale={class:"stepSelector horizontal","data-writer-cage":"","data-writer-container":""},nle={class:"container"},rle="A container component for displaying Step components, allowing you to implement a stepped blueprint.",ole={writer:{name:"Step container",description:rle,category:"Layout",allowedChildrenTypes:["step","repeater"],fields:{accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:kr,containerShadow:Rs,separatorColor:wa,buttonColor:cr,buttonTextColor:dr,buttonShadow:so,cssClasses:mt}}},sle=$e({...ole,__name:"CoreSteps",setup(e){const t=re(ne.instanceData),a={activeStep:void 0,steps:[]};return t.at(-1).value=a,(n,r)=>($(),R("div",tle,[Z("nav",ale,[qt(n.$slots,"default",{instanceNumber:0},void 0,!0)]),Z("div",nle,[qt(n.$slots,"default",{instanceNumber:1},void 0,!0)])]))}}),ile=ke(sle,[["__scopeId","data-v-c3cd761b"]]),lle={class:"CoreButton__text"},cle=`
8396
+ state["active_tab"] = payload`,U1e="A container component for organising and displaying Tab components in a tabbed interface.",z1e={writer:{name:"Tab container",description:U1e,category:"Layout",allowedChildrenTypes:["tab","repeater"],events:{"wf-tab-change":{desc:"Sent when the active tab changes.",stub:j1e.trim(),eventPayloadExample:"Tab Name"}},fields:{accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:Tr,containerShadow:Ns,separatorColor:wa,buttonColor:dr,buttonTextColor:ur,buttonShadow:io,cssClasses:mt}}},q1e=$e({...z1e,__name:"CoreTabs",setup(e){const t=re(ne.instanceData);return t.at(-1).value={activeTab:void 0},(a,n)=>($(),R("div",D1e,[Z("nav",B1e,[qt(a.$slots,"default",{instanceNumber:0},void 0,!0)]),Z("div",F1e,[qt(a.$slots,"default",{instanceNumber:1},void 0,!0)])]))}}),W1e=ke(q1e,[["__scopeId","data-v-cbe189a2"]]),Z1e={class:"CoreStep"},K1e=["disabled"],G1e={class:"indicator"},J1e={class:"label"},E1=0,Q2=1,X1e="A container component that displays its child components as a step inside a Step container.",Y1e={writer:{name:"Step",description:X1e,allowedParentTypes:["steps","repeater"],allowedChildrenTypes:["*"],category:"Layout",fields:{name:{name:"Name",default:"(No name)",init:"Step name",type:Q.Text},contentPadding:{...Bs,default:"16px"},isCompleted:Ut({name:"Completed",desc:"Use a state reference to dynamically mark this step as complete.",default:"no"}),contentHAlign:Ds,cssClasses:mt},previewField:"name"}},Q1e=$e({...Y1e,__name:"CoreStep",setup(e){const t=re(ne.evaluatedFields),a=re(ne.instancePath),n=re(ne.instanceData),r=re(ne.isBeingEdited),o=re(ne.core),s=re(ne.builderManager),i=re(ne.componentId),{isComponentVisible:l}=Kl(o),c=H(()=>s==null?void 0:s.firstSelectedId.value),d=h();function u(){for(let M=-1;M>-1*a.length;M--){const x=a.at(M),S=o.getComponentById(x.componentId);if(!S)return;if(S.type==="steps")return M}}function h(){const M=u();if(!(typeof M>"u"))return n.at(M)}function f(){const M=u()+1,x=a.slice(0,M),S=M+1<0?a.slice(M+1):[];return[...x,{componentId:a.at(M).componentId,instanceNumber:Q2},...S]}function m(){d.value={...d.value,activeStep:f()}}function g(){const M=d.value.steps.findIndex(L=>JSON.stringify(L.instancePath)==JSON.stringify(a));if(M==-1||M+1>d.value.steps.length)return;let S=d.value.steps.slice(M+1).find(L=>!L.isCompleted);S||(S=d.value.steps.at(-1)),d.value={...d.value,activeStep:S.instancePath}}function _(M){const x=o.getComponentById(M);return!x||x.type=="root"?!1:x.parentId==i?!0:_(x.parentId)}function b(){if(!t.isCompleted.value){m();return}g()}const v=H(()=>{const M=u()+1;return a.at(M)});We(c,M=>{M&&_(M)&&m()});const y=H(()=>{var S;let M;(v==null?void 0:v.value.instanceNumber)==E1?M=f():M=a;const x=(S=d.value)==null?void 0:S.activeStep;return JSON.stringify(x)==JSON.stringify(M)});return We([y,t.isCompleted],()=>{r.value||y.value&&t.isCompleted.value&&g()}),We(t.isCompleted,(M,x)=>{x&&(M||b())}),Ts(()=>{var x;(v==null?void 0:v.value.instanceNumber)==E1||(typeof d.value.steps.find(S=>S.instancePath==a)>"u"&&d.value.steps.push({instancePath:a,isCompleted:t.isCompleted.value}),(x=d.value)==null?void 0:x.activeStep)||l(i,a)&&b()}),kr(()=>{const M=d.value.steps.findIndex(x=>JSON.stringify(x.instancePath)==JSON.stringify(a));d.value.steps.splice(M,1)}),(M,x)=>{var S,L,F,te;return Ya(($(),R("div",Z1e,[((S=v.value)==null?void 0:S.instanceNumber)==E1?($(),R("button",{key:0,class:ft(["bit",{active:y.value,completed:E(t).isCompleted.value}]),disabled:!E(r),stepindex:"0",onClick:m},[Z("div",G1e,[x[0]||(x[0]=Z("div",{class:"linker left"},null,-1)),Z("div",{class:ft(["status",{completed:E(t).isCompleted.value}])},[E(t).isCompleted.value?($(),Ie(bt,{key:0,name:"check"})):ge("",!0)],2),x[1]||(x[1]=Z("div",{class:"linker right"},null,-1))]),Z("div",J1e,je(E(t).name.value),1)],10,K1e)):ge("",!0),((L=v.value)==null?void 0:L.instanceNumber)==Q2?Ya(($(),Ie(Gi,{key:1,class:"container","content-h-align":E(t).contentHAlign.value,"content-padding":E(t).contentPadding.value},{default:Xe(()=>[qt(M.$slots,"default",{},void 0,!0)]),_:3},8,["content-h-align","content-padding"])),[[Un,y.value]]):ge("",!0)],512)),[[Un,((F=v.value)==null?void 0:F.instanceNumber)==E1||((te=v.value)==null?void 0:te.instanceNumber)==Q2&&y.value]])}}}),ele=ke(Q1e,[["__scopeId","data-v-e0ef95ce"]]),tle={class:"CoreSteps"},ale={class:"stepSelector horizontal","data-writer-cage":"","data-writer-container":""},nle={class:"container"},rle="A container component for displaying Step components, allowing you to implement a stepped blueprint.",ole={writer:{name:"Step container",description:rle,category:"Layout",allowedChildrenTypes:["step","repeater"],fields:{accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,containerBackgroundColor:Tr,containerShadow:Ns,separatorColor:wa,buttonColor:dr,buttonTextColor:ur,buttonShadow:io,cssClasses:mt}}},sle=$e({...ole,__name:"CoreSteps",setup(e){const t=re(ne.instanceData),a={activeStep:void 0,steps:[]};return t.at(-1).value=a,(n,r)=>($(),R("div",tle,[Z("nav",ale,[qt(n.$slots,"default",{instanceNumber:0},void 0,!0)]),Z("div",nle,[qt(n.$slots,"default",{instanceNumber:1},void 0,!0)])]))}}),ile=ke(sle,[["__scopeId","data-v-c3cd761b"]]),lle={class:"CoreButton__text"},cle=`
8397
8397
  def handle_button_click(state):
8398
8398
 
8399
8399
  # Increment counter when the button is clicked
8400
8400
 
8401
- state["counter"] += 1`,dle="A standalone button component that can be linked to a click event handler.",ule={writer:{name:"Button",description:dle,category:"Other",events:{"wf-click":{desc:"Capture single clicks.",stub:cle.trim()}},fields:{text:{name:"Text",init:"Button Text",type:Q.Text},lucideIcon:{name:"Icon",type:Q.Text,desc:'Lucide icon name in kebab-case, e.g. "badge-check".'},isDisabled:Ut({name:"Disabled",default:"no",desc:"Disables all event handlers."}),buttonColor:cr,buttonTextColor:dr,buttonShadow:so,separatorColor:wa,cssClasses:mt},previewField:"text"}},hle=$e({...ule,__name:"CoreButton",setup(e){const t=ye(null),a=re(ne.evaluatedFields),n=re(ne.isDisabled),r=re(ne.isBeingEdited);We(a.isDisabled,s=>{n.value=s},{immediate:!0});function o(s){if(!t.value)return;const i=Zi(s);t.value.$el.dispatchEvent(i)}return(s,i)=>($(),Ie(La,{ref_key:"rootInstance",ref:t,class:"CoreButton","aria-disabled":E(n),disabled:!E(r)&&E(n),onClick:o},{default:Xe(()=>[E(a).lucideIcon.value?($(),Ie(_t,{key:0,name:E(a).lucideIcon.value},null,8,["name"])):ge("",!0),Z("span",lle,je(E(a).text.value),1)]),_:1},8,["aria-disabled","disabled"]))}}),ple=ke(hle,[["__scopeId","data-v-577b61ef"]]),fle={padding:"16px","min-height":"64px","min-width":"64px","border-radius":"8px",background:"linear-gradient(90deg, rgba(41,207,0,1) 0%, rgba(145,231,78,1) 100%)"},mle="A generic component that creates customisable HTML elements, which can serve as containers for other components.",Jg={writer:{name:"HTML element",description:mle,category:"Other",allowedChildrenTypes:["*"],fields:{element:{name:"Element",default:"div",type:Q.Text,desc:"Set the type of HTML element to create, e.g., 'div', 'section', 'span', etc."},styles:{name:"Styles",default:"{}",init:JSON.stringify(fle,null,2),type:Q.Object,desc:"Define the CSS styles to apply to the HTML element using a JSON object or a state reference to a dictionary.",validator:no},attrs:{name:"Attributes",default:"{}",type:Q.Object,desc:"Set additional HTML attributes for the element using a JSON object or a dictionary via a state reference.",validator:no},htmlInside:{name:"HTML inside",default:null,type:Q.Text,control:Ui.Textarea,desc:"Define custom HTML to be used inside the element. It will be wrapped in a div and rendered after children components."},cssClasses:mt}},setup(e,{slots:t}){const a=re(ne.evaluatedFields),n=/^[a-zA-Z][a-zA-Z0-9-_:.]*$/,r=H(()=>{if(typeof a.attrs.value!="object"||a.attrs.value===null)return{};const o=Object.entries(a.attrs.value).filter(([s])=>n.test(s));return Object.fromEntries(o)});return()=>{let o;return a.htmlInside.value&&(o=En("div",{innerHTML:a.htmlInside.value})),En(a.element.value,{...r.value,class:"CoreHTML","data-writer-container":"",style:a.styles.value},[t.default({}),o])}}},$m=e=>{e.writer&&(e.writer.docs=`You can configure the element type, styles, and attributes to fit your design requirements. You can link them to state for advanced use cases, such as custom animations.
8401
+ state["counter"] += 1`,dle="A standalone button component that can be linked to a click event handler.",ule={writer:{name:"Button",description:dle,category:"Other",events:{"wf-click":{desc:"Capture single clicks.",stub:cle.trim()}},fields:{text:{name:"Text",init:"Button Text",type:Q.Text},lucideIcon:{name:"Icon",type:Q.Text,desc:'Lucide icon name in kebab-case, e.g. "badge-check".'},isDisabled:Ut({name:"Disabled",default:"no",desc:"Disables all event handlers."}),buttonColor:dr,buttonTextColor:ur,buttonShadow:io,separatorColor:wa,cssClasses:mt},previewField:"text"}},hle=$e({...ule,__name:"CoreButton",setup(e){const t=ye(null),a=re(ne.evaluatedFields),n=re(ne.isDisabled),r=re(ne.isBeingEdited);We(a.isDisabled,s=>{n.value=s},{immediate:!0});function o(s){if(!t.value)return;const i=Zi(s);t.value.$el.dispatchEvent(i)}return(s,i)=>($(),Ie(La,{ref_key:"rootInstance",ref:t,class:"CoreButton","aria-disabled":E(n),disabled:!E(r)&&E(n),onClick:o},{default:Xe(()=>[E(a).lucideIcon.value?($(),Ie(bt,{key:0,name:E(a).lucideIcon.value},null,8,["name"])):ge("",!0),Z("span",lle,je(E(a).text.value),1)]),_:1},8,["aria-disabled","disabled"]))}}),ple=ke(hle,[["__scopeId","data-v-577b61ef"]]),fle={padding:"16px","min-height":"64px","min-width":"64px","border-radius":"8px",background:"linear-gradient(90deg, rgba(41,207,0,1) 0%, rgba(145,231,78,1) 100%)"},mle="A generic component that creates customisable HTML elements, which can serve as containers for other components.",Jg={writer:{name:"HTML element",description:mle,category:"Other",allowedChildrenTypes:["*"],fields:{element:{name:"Element",default:"div",type:Q.Text,desc:"Set the type of HTML element to create, e.g., 'div', 'section', 'span', etc."},styles:{name:"Styles",default:"{}",init:JSON.stringify(fle,null,2),type:Q.Object,desc:"Define the CSS styles to apply to the HTML element using a JSON object or a state reference to a dictionary.",validator:ro},attrs:{name:"Attributes",default:"{}",type:Q.Object,desc:"Set additional HTML attributes for the element using a JSON object or a dictionary via a state reference.",validator:ro},htmlInside:{name:"HTML inside",default:null,type:Q.Text,control:Ui.Textarea,desc:"Define custom HTML to be used inside the element. It will be wrapped in a div and rendered after children components."},cssClasses:mt}},setup(e,{slots:t}){const a=re(ne.evaluatedFields),n=/^[a-zA-Z][a-zA-Z0-9-_:.]*$/,r=H(()=>{if(typeof a.attrs.value!="object"||a.attrs.value===null)return{};const o=Object.entries(a.attrs.value).filter(([s])=>n.test(s));return Object.fromEntries(o)});return()=>{let o;return a.htmlInside.value&&(o=En("div",{innerHTML:a.htmlInside.value})),En(a.element.value,{...r.value,class:"CoreHTML","data-writer-container":"",style:a.styles.value},[t.default({}),o])}}},$m=e=>{e.writer&&(e.writer.docs=`You can configure the element type, styles, and attributes to fit your design requirements. You can link them to state for advanced use cases, such as custom animations.
8402
8402
 
8403
8403
  All valid HTML tags are supported, including tags such as \`iframe\`, allowing you to embed external sites.
8404
8404
 
@@ -8417,12 +8417,12 @@ def handle_page_size_change(state, payload):
8417
8417
  records = _load_records_from_db(start = state["page"] * state["pageSize"], limit = state["pageSize"])
8418
8418
  # update a repeater
8419
8419
  state["highlighted_members"] = {r.id: r for r in records}
8420
- `,Ple={writer:{name:"Pagination",category:"Other",description:"A component that can help you paginate records, for example from a Repeater or a DataFrame.",fields:{page:{name:"Page",init:"1",default:"1",type:Q.Number,desc:"The current page number.",validator:fn},pageSize:{name:"Page Size",default:"10",type:Q.Number,desc:"The number of items per page.",validator:fn},totalItems:{name:"Total Items",default:"10",type:Q.Number,desc:"The total number of items",validator:fn},pageSizeOptions:{name:"Page Size Options",init:"",default:"",type:Q.Text,desc:"A comma-separated list of page size options. If it's empty, the user can't change the page size. Set your default page size as the first option."},pageSizeShowAll:Ut({name:"Show All Option",default:"no",desc:"Show an option to show all records."}),jumpTo:Ut({name:"Jump To",default:"no",desc:"Show an option to jump to a specific page."})},events:{"wf-change-page":{desc:"Fires when the user pick a page",stub:kle.trim(),eventPayloadExample:2},"wf-change-page-size":{desc:"Fires when the user change the page size.",stub:Tle.trim(),eventPayloadExample:10}}}},Lle=$e({...Ple,__name:"CorePagination",setup(e){const t=re(ne.evaluatedFields),a=re(ne.core),n=pt("rootEl"),r=re(ne.instancePath),{handleInput:o}=Va(a,r,n),{handleInput:s}=Va(a,r,n),i=H(()=>t.pageSizeOptions.value!==""||t.pageSizeShowAll.value),l=H(()=>t.jumpTo.value),c=H(()=>t.totalItems.value==0?0:(t.page.value-1)*t.pageSize.value+1),d=H(()=>Math.min(t.page.value*t.pageSize.value,t.totalItems.value)),u=H(()=>t.totalItems.value),h=H(()=>Math.ceil(parseInt(t.totalItems.value)/parseInt(t.pageSize.value))),f=H(()=>{let M=[];const x=t.pageSizeOptions.value.split(",");for(const S in x){const L=parseInt(x[S],10);M.push({value:L,label:`${L} items`})}return t.pageSizeShowAll.value&&M.push({value:u.value,label:"All items"}),M}),m=H(()=>{const M=[],x=parseInt(t.page.value);if(h.value<=7)for(let S=0;S<h.value;S++)M.push(S+1);else x==1||x==2?(M.push(1),M.push(2),M.push(3),M.push("..."),M.push(h.value-2),M.push(h.value-1),M.push(h.value)):x==3?(M.push(1),M.push(2),M.push(3),M.push(4),M.push("..."),M.push(h.value-1),M.push(h.value)):x==4?(M.push(1),M.push(2),M.push(3),M.push(4),M.push(5),M.push("..."),M.push(h.value)):x==h.value||x==h.value-1?(M.push(1),M.push(2),M.push(3),M.push("..."),M.push(h.value-2),M.push(h.value-1),M.push(h.value)):x==h.value-2?(M.push(1),M.push(2),M.push("..."),M.push(h.value-3),M.push(h.value-2),M.push(h.value-1),M.push(h.value)):(M.push(1),M.push("..."),M.push(x-1),M.push(x),M.push(x+1),M.push("..."),M.push(h.value));return M}),g=H(()=>parseInt(t.page.value)-1<1),_=H(()=>parseInt(t.page.value)+1>h.value),b=M=>{if(M.target.value==="")return;let x=parseInt(M.target.value);x>h.value&&(x=h.value),o(x,"wf-change-page")},v=M=>{o(M,"wf-change-page")},y=M=>{let x=parseInt(M.target.value);s(x,"wf-change-page-size")};return(M,x)=>($(),R("div",{ref_key:"rootEl",ref:n,class:"CorePagination"},[Z("div",vle,[Ya(Z("div",gle,[Z("select",{class:"pagesize-select",onChange:y},[($(!0),R(Je,null,Ot(f.value,(S,L)=>($(),R("option",{key:L,value:S.value,selected:S.value==E(t).pageSize.value},je(S.label),9,yle))),128))],32)],512),[[jn,i.value]]),Z("div",Mle,[x[2]||(x[2]=pa(" Showing ")),Z("span",_le,je(c.value),1),x[3]||(x[3]=pa(" to ")),Z("span",ble,je(d.value),1),x[4]||(x[4]=pa(" of ")),Z("span",wle,je(u.value),1),x[5]||(x[5]=pa(" results "))])]),Z("div",xle,[Z("div",Cle,[Z("div",{class:ft(["paginationpicker-block",{"paginationpicker-disabled":g.value}]),onClick:x[0]||(x[0]=S=>v(E(t).page.value-1))},[Ce(_t,{name:"chevron-left"})],2),($(!0),R(Je,null,Ot(m.value,(S,L)=>($(),R(Je,{key:L},[S=="..."?($(),R("div",Ale,je(S),1)):ge("",!0),S!="..."&&S!=E(t).page.value?($(),R("div",{key:1,class:"paginationpicker-block",onClick:F=>v(S)},je(S),9,Sle)):ge("",!0),S==E(t).page.value?($(),R("div",$le,je(S),1)):ge("",!0)],64))),128)),Z("div",{class:ft(["paginationpicker-block",{"paginationpicker-disabled":_.value}]),onClick:x[1]||(x[1]=S=>v(E(t).page.value+1))},[Ce(_t,{name:"chevron-right"})],2)]),Ya(Z("div",Ele,[x[6]||(x[6]=Z("label",null,"Jump to",-1)),Z("input",{type:"text",value:E(t).page.value,onInput:b},null,40,Ile)],512),[[jn,l.value]])])],512))}}),Vle=ke(Lle,[["__scopeId","data-v-0424229a"]]),Ole="A container component that repeats its child components based on a dictionary.",Hle={a:{desc:"Option A"},b:{desc:"Option B"}},Rle={writer:{name:"Repeater",description:Ole,category:"Other",allowedChildrenTypes:["inherit"],fields:{repeaterObject:{name:"Repeater object",default:JSON.stringify(Hle,null,2),type:Q.Object,desc:"Include a state reference to the dictionary used for repeating the child components. Alternatively, specify a JSON object.",validator:GE},keyVariable:{name:"Key variable name",default:"itemId",init:"itemId",type:Q.Text,desc:"Set the name of the variable that will store the key of the current repeater object entry."},valueVariable:{name:"Value variable name",default:"item",init:"item",type:Q.Text,desc:"Set the name of the variable that will store the value of the current repeater object entry."}}},setup(e,{slots:t}){const a=re(ne.core),n=re(ne.componentId),r=re(ne.evaluatedFields),o=re(ne.isBeingEdited),s=re(ne.renderProxiedComponent),i=H(()=>a.getComponents(n,{sortedByPosition:!0})),l=()=>typeof r.repeaterObject.value!="object"?[]:Object.values(r.repeaterObject.value).map((d,u)=>i.value.map(h=>s(h.id,u)));return()=>{let c={};return i.value.length!=0&&r.repeaterObject.value!=null&&Object.keys(r.repeaterObject.value).length!=0?c=l():o.value===!0?c=t.default({}):c={},En("div",{class:"CoreRepeater","data-writer-container":""},c)}}},Nle=ke(Rle,[["__scopeId","data-v-0b783e59"]]),Dle="A component that emits an event repeatedly at specified time intervals, enabling time-based refresh.",Ble=`
8420
+ `,Ple={writer:{name:"Pagination",category:"Other",description:"A component that can help you paginate records, for example from a Repeater or a DataFrame.",fields:{page:{name:"Page",init:"1",default:"1",type:Q.Number,desc:"The current page number.",validator:fn},pageSize:{name:"Page Size",default:"10",type:Q.Number,desc:"The number of items per page.",validator:fn},totalItems:{name:"Total Items",default:"10",type:Q.Number,desc:"The total number of items",validator:fn},pageSizeOptions:{name:"Page Size Options",init:"",default:"",type:Q.Text,desc:"A comma-separated list of page size options. If it's empty, the user can't change the page size. Set your default page size as the first option."},pageSizeShowAll:Ut({name:"Show All Option",default:"no",desc:"Show an option to show all records."}),jumpTo:Ut({name:"Jump To",default:"no",desc:"Show an option to jump to a specific page."})},events:{"wf-change-page":{desc:"Fires when the user pick a page",stub:kle.trim(),eventPayloadExample:2},"wf-change-page-size":{desc:"Fires when the user change the page size.",stub:Tle.trim(),eventPayloadExample:10}}}},Lle=$e({...Ple,__name:"CorePagination",setup(e){const t=re(ne.evaluatedFields),a=re(ne.core),n=pt("rootEl"),r=re(ne.instancePath),{handleInput:o}=Va(a,r,n),{handleInput:s}=Va(a,r,n),i=H(()=>t.pageSizeOptions.value!==""||t.pageSizeShowAll.value),l=H(()=>t.jumpTo.value),c=H(()=>t.totalItems.value==0?0:(t.page.value-1)*t.pageSize.value+1),d=H(()=>Math.min(t.page.value*t.pageSize.value,t.totalItems.value)),u=H(()=>t.totalItems.value),h=H(()=>Math.ceil(parseInt(t.totalItems.value)/parseInt(t.pageSize.value))),f=H(()=>{let M=[];const x=t.pageSizeOptions.value.split(",");for(const S in x){const L=parseInt(x[S],10);M.push({value:L,label:`${L} items`})}return t.pageSizeShowAll.value&&M.push({value:u.value,label:"All items"}),M}),m=H(()=>{const M=[],x=parseInt(t.page.value);if(h.value<=7)for(let S=0;S<h.value;S++)M.push(S+1);else x==1||x==2?(M.push(1),M.push(2),M.push(3),M.push("..."),M.push(h.value-2),M.push(h.value-1),M.push(h.value)):x==3?(M.push(1),M.push(2),M.push(3),M.push(4),M.push("..."),M.push(h.value-1),M.push(h.value)):x==4?(M.push(1),M.push(2),M.push(3),M.push(4),M.push(5),M.push("..."),M.push(h.value)):x==h.value||x==h.value-1?(M.push(1),M.push(2),M.push(3),M.push("..."),M.push(h.value-2),M.push(h.value-1),M.push(h.value)):x==h.value-2?(M.push(1),M.push(2),M.push("..."),M.push(h.value-3),M.push(h.value-2),M.push(h.value-1),M.push(h.value)):(M.push(1),M.push("..."),M.push(x-1),M.push(x),M.push(x+1),M.push("..."),M.push(h.value));return M}),g=H(()=>parseInt(t.page.value)-1<1),_=H(()=>parseInt(t.page.value)+1>h.value),b=M=>{if(M.target.value==="")return;let x=parseInt(M.target.value);x>h.value&&(x=h.value),o(x,"wf-change-page")},v=M=>{o(M,"wf-change-page")},y=M=>{let x=parseInt(M.target.value);s(x,"wf-change-page-size")};return(M,x)=>($(),R("div",{ref_key:"rootEl",ref:n,class:"CorePagination"},[Z("div",vle,[Ya(Z("div",gle,[Z("select",{class:"pagesize-select",onChange:y},[($(!0),R(Je,null,Ot(f.value,(S,L)=>($(),R("option",{key:L,value:S.value,selected:S.value==E(t).pageSize.value},je(S.label),9,yle))),128))],32)],512),[[Un,i.value]]),Z("div",Mle,[x[2]||(x[2]=pa(" Showing ")),Z("span",_le,je(c.value),1),x[3]||(x[3]=pa(" to ")),Z("span",ble,je(d.value),1),x[4]||(x[4]=pa(" of ")),Z("span",wle,je(u.value),1),x[5]||(x[5]=pa(" results "))])]),Z("div",xle,[Z("div",Cle,[Z("div",{class:ft(["paginationpicker-block",{"paginationpicker-disabled":g.value}]),onClick:x[0]||(x[0]=S=>v(E(t).page.value-1))},[Ce(bt,{name:"chevron-left"})],2),($(!0),R(Je,null,Ot(m.value,(S,L)=>($(),R(Je,{key:L},[S=="..."?($(),R("div",Ale,je(S),1)):ge("",!0),S!="..."&&S!=E(t).page.value?($(),R("div",{key:1,class:"paginationpicker-block",onClick:F=>v(S)},je(S),9,Sle)):ge("",!0),S==E(t).page.value?($(),R("div",$le,je(S),1)):ge("",!0)],64))),128)),Z("div",{class:ft(["paginationpicker-block",{"paginationpicker-disabled":_.value}]),onClick:x[1]||(x[1]=S=>v(E(t).page.value+1))},[Ce(bt,{name:"chevron-right"})],2)]),Ya(Z("div",Ele,[x[6]||(x[6]=Z("label",null,"Jump to",-1)),Z("input",{type:"text",value:E(t).page.value,onInput:b},null,40,Ile)],512),[[Un,l.value]])])],512))}}),Vle=ke(Lle,[["__scopeId","data-v-0424229a"]]),Ole="A container component that repeats its child components based on a dictionary.",Hle={a:{desc:"Option A"},b:{desc:"Option B"}},Rle={writer:{name:"Repeater",description:Ole,category:"Other",allowedChildrenTypes:["inherit"],fields:{repeaterObject:{name:"Repeater object",default:JSON.stringify(Hle,null,2),type:Q.Object,desc:"Include a state reference to the dictionary used for repeating the child components. Alternatively, specify a JSON object.",validator:GE},keyVariable:{name:"Key variable name",default:"itemId",init:"itemId",type:Q.Text,desc:"Set the name of the variable that will store the key of the current repeater object entry."},valueVariable:{name:"Value variable name",default:"item",init:"item",type:Q.Text,desc:"Set the name of the variable that will store the value of the current repeater object entry."}}},setup(e,{slots:t}){const a=re(ne.core),n=re(ne.componentId),r=re(ne.evaluatedFields),o=re(ne.isBeingEdited),s=re(ne.renderProxiedComponent),i=H(()=>a.getComponents(n,{sortedByPosition:!0})),l=()=>typeof r.repeaterObject.value!="object"?[]:Object.values(r.repeaterObject.value).map((d,u)=>i.value.map(h=>s(h.id,u)));return()=>{let c={};return i.value.length!=0&&r.repeaterObject.value!=null&&Object.keys(r.repeaterObject.value).length!=0?c=l():o.value===!0?c=t.default({}):c={},En("div",{class:"CoreRepeater","data-writer-container":""},c)}}},Nle=ke(Rle,[["__scopeId","data-v-0b783e59"]]),Dle="A component that emits an event repeatedly at specified time intervals, enabling time-based refresh.",Ble=`
8421
8421
  def handle_timer_tick(state):
8422
8422
 
8423
8423
  # Increment counter when the timer ticks
8424
8424
 
8425
- state["counter"] += 1`.trim(),Fle={writer:{name:"Timer",description:Dle,category:"Other",fields:{intervalMs:{name:"Interval (ms)",desc:"How much time to wait between ticks. A tick is considered finished when its event is handled.",default:"200",type:Q.Number,validator:fn},isActive:Ut({name:"Active",default:"yes",desc:"Whether the timer should trigger tick events."}),accentColor:Ia,cssClasses:mt},events:{"wf-tick":{desc:"Emitted when the timer ticks.",stub:Ble.trim()}}}},jle=$e({...Fle,__name:"CoreTimer",setup(e){const n=re(ne.evaluatedFields),r=re(ne.core),o=pt("rootEl"),s=H(()=>n.intervalMs.value),i=H(()=>n.isActive.value),l=ye(!1),c=re(ne.componentId),d=H(()=>{var _,b;return!!((b=(_=r.getComponentById(c))==null?void 0:_.handlers)!=null&&b["wf-tick"])}),u=H(()=>({"animation-duration":`${Math.max(s.value,1e3)}ms`}));We([i,s],()=>{g()}),We(d,async _=>{_&&(await qa(),g())});let h=0,f=null;function m(){clearTimeout(f)}function g(){if(m(),!i.value||s.value<0||!o.value)return;Date.now()-h>=500&&(o.value.classList.remove("tick"),o.value.offsetWidth,h=Date.now(),o.value.classList.add("tick"));const _=({ok:v})=>{l.value=!v,f=setTimeout(()=>{g()},s.value)},b=new CustomEvent("wf-tick",{detail:{callback:_}});o.value.dispatchEvent(b)}return ia(()=>{g()}),(_,b)=>($(),R("div",{ref_key:"rootEl",ref:o,class:ft(["CoreTimer",{failing:l.value}]),style:bt(u.value)},null,6))}}),Ule=ke(jle,[["__scopeId","data-v-455cee49"]]),zle={class:"main"},qle={class:"actions"},Wle=["value"],Zle="A user input component that allows users to capture images using their webcam.",Kle=`
8425
+ state["counter"] += 1`.trim(),Fle={writer:{name:"Timer",description:Dle,category:"Other",fields:{intervalMs:{name:"Interval (ms)",desc:"How much time to wait between ticks. A tick is considered finished when its event is handled.",default:"200",type:Q.Number,validator:fn},isActive:Ut({name:"Active",default:"yes",desc:"Whether the timer should trigger tick events."}),accentColor:Ia,cssClasses:mt},events:{"wf-tick":{desc:"Emitted when the timer ticks.",stub:Ble.trim()}}}},jle=$e({...Fle,__name:"CoreTimer",setup(e){const n=re(ne.evaluatedFields),r=re(ne.core),o=pt("rootEl"),s=H(()=>n.intervalMs.value),i=H(()=>n.isActive.value),l=ye(!1),c=re(ne.componentId),d=H(()=>{var _,b;return!!((b=(_=r.getComponentById(c))==null?void 0:_.handlers)!=null&&b["wf-tick"])}),u=H(()=>({"animation-duration":`${Math.max(s.value,1e3)}ms`}));We([i,s],()=>{g()}),We(d,async _=>{_&&(await qa(),g())});let h=0,f=null;function m(){clearTimeout(f)}function g(){if(m(),!i.value||s.value<0||!o.value)return;Date.now()-h>=500&&(o.value.classList.remove("tick"),o.value.offsetWidth,h=Date.now(),o.value.classList.add("tick"));const _=({ok:v})=>{l.value=!v,f=setTimeout(()=>{g()},s.value)},b=new CustomEvent("wf-tick",{detail:{callback:_}});o.value.dispatchEvent(b)}return ia(()=>{g()}),(_,b)=>($(),R("div",{ref_key:"rootEl",ref:o,class:ft(["CoreTimer",{failing:l.value}]),style:wt(u.value)},null,6))}}),Ule=ke(jle,[["__scopeId","data-v-455cee49"]]),zle={class:"main"},qle={class:"actions"},Wle=["value"],Zle="A user input component that allows users to capture images using their webcam.",Kle=`
8426
8426
  def webcam_handler(payload):
8427
8427
 
8428
8428
  # This handler will save the captured images based on timestamp
@@ -8435,7 +8435,7 @@ def webcam_handler(payload):
8435
8435
 
8436
8436
  image_file = payload
8437
8437
  with open(f"capture-{timestamp}.png", "wb") as file_handle:
8438
- file_handle.write(image_file)`.trim(),Gle={writer:{deprecated:!0,name:"Webcam capture",description:Zle,category:"Other",fields:{refreshRate:{name:"Refresh rate (ms)",init:"200",default:"200",desc:"Set to 0 for manual capture.",type:Q.Number,validator:fn},buttonColor:cr,buttonTextColor:dr,buttonShadow:so,separatorColor:wa,cssClasses:mt},events:{"wf-webcam":{desc:"Sent when a frame is captured. Its payload contains the captured frame in PNG format.",stub:Kle.trim(),eventPayloadExample:"data:image/png;base64,azerty"}}}},Jle=$e({...Gle,__name:"CoreWebcamCapture",setup(e){const t=ye(!1),a=pt("rootEl"),n=document.createElement("canvas"),r=pt("videoEl"),o=re(ne.evaluatedFields),s=ye(null),i=ye(null),l=fa();ia(async()=>{var _,b;s.value=await c(),i.value=(b=(_=s.value)==null?void 0:_[0])==null?void 0:b.deviceId}),Ir(()=>{g()});const c=async()=>(await navigator.mediaDevices.enumerateDevices()).filter(v=>v.kind=="videoinput"),d=H(()=>o.refreshRate.value);We(d,(_,b)=>{_>0&&b<=0&&f()}),We(i,async()=>{t.value&&(g(),await m())});const u=async()=>{if(t.value=!t.value,!t.value){g();return}await m(),f()},h=()=>(n.getContext("2d").drawImage(r.value,0,0),n.toDataURL("image/png")),f=()=>{const _=new CustomEvent("wf-webcam",{detail:{payload:h(),callback:()=>{d.value<=0||!t.value||setTimeout(()=>{f()},d.value)}}});a.value.dispatchEvent(_)},m=async()=>(r.value.style.display="",new Promise((_,b)=>{navigator.mediaDevices.getUserMedia||(l.error("This browser doesn't support webcam connection."),b());const v={video:!0};s.value.length>1&&(v.video={deviceId:i.value}),navigator.mediaDevices.getUserMedia(v).then(y=>{r.value.srcObject=y;const M=y.getVideoTracks()[0].getSettings().width,x=y.getVideoTracks()[0].getSettings().height;n.setAttribute("width",M.toString()),n.setAttribute("height",x.toString()),_()}).catch(y=>{l.error("An error occurred when trying to use the webcam.",y),b()})})),g=()=>{const _=r.value.srcObject;_&&_.getTracks().map(v=>v.stop()),r.value.srcObject=null,r.value.style.display="none"};return(_,b)=>{var v;return $(),R("div",{ref_key:"rootEl",ref:a,class:"CoreWebcamCapture"},[Ya(Z("div",zle,[Z("video",{ref_key:"videoEl",ref:r,autoplay:"true"},null,512)],512),[[jn,t.value]]),Z("div",qle,[d.value==0?($(),Ie(La,{key:0,onClick:f},{default:Xe(()=>b[1]||(b[1]=[pa(" Capture image ")])),_:1})):ge("",!0),Ce(La,{onClick:u},{default:Xe(()=>[pa(je(t.value?"Stop capture":"Start webcam capture"),1)]),_:1}),((v=s.value)==null?void 0:v.length)>1?($(),Ie(Ug,{key:1,modelValue:i.value,"onUpdate:modelValue":b[0]||(b[0]=y=>i.value=y)},{default:Xe(()=>[($(!0),R(Je,null,Ot(s.value,(y,M)=>($(),R("option",{key:y.deviceId,value:y.deviceId},je(y.label||`Webcam ${M+1}`),9,Wle))),128))]),_:1},8,["modelValue"])):ge("",!0)])],512)}}}),Xle=ke(Jle,[["__scopeId","data-v-c89e0cac"]]),Yle={writer:{name:"Reuse component",slot:"*",description:"Those components are used to reuse other components. Reused components share the same state and are updated together.",category:"Other",allowedChildrenTypes:[],fields:{proxyId:{name:"Component id",type:Q.Text,desc:"The id of the component to reuse."}}}},Qle=$e({...Yle,__name:"CoreReuse",props:{contextSlot:{}},setup(e){const t=e,a=re(ne.evaluatedFields),r=re(ne.instancePath).at(-2).componentId,o=re(ne.core),s=re(ne.renderProxiedComponent),i=re(ne.isBeingEdited),l=re(ne.componentId),c=ye(En("div","")),d=ye(!0),u=H(()=>{var g;return(g=o.getComponentById(a.proxyId.value))==null?void 0:g.type}),h=H(()=>u.value?o.getComponentDefinition(u.value):null);function f(g,_){d.value=t.contextSlot==="default",c.value=En("div",{class:["CoreReuse",_],style:{color:"var(--primaryTextColor)"}},i.value?g:"")}function m(){if(!a.proxyId.value)return f("No component selected to reuse","empty");if(l===a.proxyId.value||!h.value)return f("The id specified for reuse doesn't match any component.","invalid-value");if(!o.getContainableTypes(r).includes(u.value))return f("The component cannot be reused here.","invalid-context");d.value=t.contextSlot===(h.value.slot??"default");const g=s(a.proxyId.value,0,{class:["CoreReuse"]});c.value=g}return We([a.proxyId,h],m,{immediate:!0}),(g,_)=>d.value?($(),Ie(Ts(c.value),{key:0})):ge("",!0)}}),e2e={key:0,class:"controls"},t2e={key:2},a2e=["page"],n2e="A component to embed PDF documents.",r2e={writer:{name:"PDF",description:n2e,category:"Embed",fields:{source:{name:"PDF source",type:Q.Text,desc:"A valid URL. Alternatively, you can provide a state reference to a packed PDF file."},highlights:{name:"Highlights",default:JSON.stringify([]),desc:"A list of highlights to be applied to the PDF as a JSON array of strings.",type:Q.Object,validator:lg},selectedMatch:{name:"Selected highlight match",default:null,desc:"The index of the selected highlight match.",type:Q.Number},page:{name:"Page",type:Q.Number,desc:"The page to be displayed."},controls:Ut({name:"Enable controls",desc:"Show controls to navigate the PDF.",default:"yes"}),containerBackgroundColor:kr,separatorColor:wa,primaryTextColor:ua,cssClasses:mt}}},o2e=$e({...r2e,__name:"CorePDF",setup(e){const t=re(ne.evaluatedFields,{});let a,n,r;const o=H(()=>t.highlights.value.filter(Boolean)),s=$t({completeWords:!1,ignoreCase:!0}),i=ye(1),l=ye(1),c=$t([]),d=ye(0),u=pt("rootEl"),h=pt("viewerEl"),f=ye(!1),m=ye(0),g=$t([]);function _(ee){return Tr(ee)&&"name"in ee&&"type"in ee&&"data"in ee&&typeof ee.data=="string"&&ee.data.startsWith("data:")}function b(ee){if(!(typeof ee!="string"||!ee.trim())){try{const j=JSON.parse(ee);if(Array.isArray(j)&&j.length>0){const K=j[0];if(_(K))return K.data}}catch{}return ee}}const v=H(()=>{var j;if(!((j=t.source)!=null&&j.value))return;const ee=b(t.source.value);if(ee)try{return Rw(ee)}catch{return}}),y=H(()=>v.value===void 0?{url:t.source.value,isEvalSupported:!1}:{data:v.value,isEvalSupported:!1});ia(async()=>{const ee=await zt(()=>import("./index-uhDDPaD2.js"),__vite__mapDeps([9,10]),import.meta.url),j=await zt(()=>import("./pdf-5wahDYbm.js"),[],import.meta.url);j.GlobalWorkerOptions.workerSrc=new URL(""+new URL("pdf.worker.min-CyUfim15.mjs",import.meta.url).href,import.meta.url).toString(),r=ee.VuePDF;const K=ee.usePDF;({pdf:a,pages:n}=K(y)),M()});function M(){f.value=!0,m.value=0,g.value=[],c.value=[]}function x(ee){g.value=[...g.value,{matches:ee.matches,page:ee.page}]}function S(ee){m.value++}function L(){c.value=g.value.reduce((ee,j)=>{const K=j.matches.map((G,T)=>({page:j.page,str:G.str,index:T}));return ee.push(...K),ee},[]).sort((ee,j)=>ee.page===j.page?ee.index-j.index:ee.page-j.page)}function F(){L(),d.value&&be(d.value),t.selectedMatch.value&&(d.value=t.selectedMatch.value)}function te(ee){const j=ee.target.getBoundingClientRect(),K=[...ee.target.children].filter(G=>G.className.includes("page")).find(G=>{const T=G.getBoundingClientRect(),O=T.y-j.y;return O<j.height/2&&O+T.height>j.height/2});K&&(l.value=Number(K.getAttribute("page")))}function J(ee,j){let K=0,G=ee;for(;G&&G!==j;)K+=G.offsetTop,G=G.offsetParent;return K}function be(ee){if(ee<1||ee>c.value.length)return;const j=c.value[ee-1];if(!j)return;const G=u.value.querySelectorAll(`div[page='${j.page}'] span.highlight`)[j.index];G instanceof HTMLElement&&(h.value.scrollTop=J(G,h.value))}const oe=ee=>{if(ee<1||ee>(n==null?void 0:n.value))return;const j=u.value.querySelector("div[page='"+ee+"']");j instanceof HTMLElement&&(h.value.scrollTop=J(j,h.value))};function Te(){d.value<c.value.length?d.value=d.value+1:d.value=1}function Ue(){d.value>1?d.value=d.value-1:d.value=c.value.length}function Ze(){i.value=i.value<2?i.value+.1:i.value}function Me(){i.value=i.value>.25?i.value-.1:i.value}return We(m,()=>{var ee;m.value===(n==null?void 0:n.value)&&(ee=t.page)!=null&&ee.value&&oe(t.page.value)}),We([g,m],()=>{(o.value.length==0||g.value.length===(n==null?void 0:n.value))&&m.value===(n==null?void 0:n.value)&&(F(),f.value=!1)}),We([i,t.source],M),We(o,()=>{g.value=[],c.value=[]}),We(d,()=>{be(d.value)}),We(t.selectedMatch,()=>{d.value=t.selectedMatch.value}),We(t.page,()=>{oe(t.page.value)}),(ee,j)=>($(),R("div",{ref_key:"rootEl",ref:u,class:"CorePDF"},[E(t).controls.value?($(),R("div",e2e,[Ce(wn,{onClick:j[0]||(j[0]=()=>oe(l.value-1))},{default:Xe(()=>[Ce(_t,{name:"arrow-up"})]),_:1}),Ce(wn,{onClick:j[1]||(j[1]=()=>oe(l.value+1))},{default:Xe(()=>[Ce(_t,{name:"arrow-down"})]),_:1}),($(),R("span",{key:l.value},je(l.value)+" / "+je(E(n)),1)),Ce(wn,{disabled:f.value,onClick:Ze},{default:Xe(()=>[Ce(_t,{name:"zoom-in"})]),_:1},8,["disabled"]),Ce(wn,{disabled:f.value,onClick:Me},{default:Xe(()=>[Ce(_t,{name:"zoom-out"})]),_:1},8,["disabled"]),Z("span",null,je(Math.round(i.value*100))+"%",1),j[2]||(j[2]=Z("span",{class:"separator"},null,-1)),c.value.length?($(),Ie(wn,{key:0,onClick:Ue},{default:Xe(()=>[Ce(_t,{name:"chevron-left"})]),_:1})):ge("",!0),c.value.length?($(),Ie(wn,{key:1,onClick:Te},{default:Xe(()=>[Ce(_t,{name:"chevron-right"})]),_:1})):ge("",!0),c.value.length?($(),R("span",t2e,"Matches "+je(d.value)+" / "+je(c.value.length),1)):ge("",!0)])):ge("",!0),Z("div",{ref_key:"viewerEl",ref:h,class:"viewer",onScroll:te},[($(!0),R(Je,null,Ot(E(n),K=>($(),R("div",{key:K,page:K,class:"page"},[Ce(E(r),{scale:i.value,pdf:E(a),page:K,"text-layer":"","highlight-text":o.value,"highlight-options":s.value,onHighlight:x,onLoaded:S},null,8,["scale","pdf","page","highlight-text","highlight-options"])],8,a2e))),128))],544),j[3]||(j[3]=Z("div",{class:"mask"},null,-1))],512))}}),s2e=ke(o2e,[["__scopeId","data-v-0e66d538"]]),i2e={key:0,class:"noURLProvided"},l2e=["src","referrerpolicy"],c2e="A component to embed an external resource in an iframe.",d2e=`
8438
+ file_handle.write(image_file)`.trim(),Gle={writer:{deprecated:!0,name:"Webcam capture",description:Zle,category:"Other",fields:{refreshRate:{name:"Refresh rate (ms)",init:"200",default:"200",desc:"Set to 0 for manual capture.",type:Q.Number,validator:fn},buttonColor:dr,buttonTextColor:ur,buttonShadow:io,separatorColor:wa,cssClasses:mt},events:{"wf-webcam":{desc:"Sent when a frame is captured. Its payload contains the captured frame in PNG format.",stub:Kle.trim(),eventPayloadExample:"data:image/png;base64,azerty"}}}},Jle=$e({...Gle,__name:"CoreWebcamCapture",setup(e){const t=ye(!1),a=pt("rootEl"),n=document.createElement("canvas"),r=pt("videoEl"),o=re(ne.evaluatedFields),s=ye(null),i=ye(null),l=fa();ia(async()=>{var _,b;s.value=await c(),i.value=(b=(_=s.value)==null?void 0:_[0])==null?void 0:b.deviceId}),kr(()=>{g()});const c=async()=>(await navigator.mediaDevices.enumerateDevices()).filter(v=>v.kind=="videoinput"),d=H(()=>o.refreshRate.value);We(d,(_,b)=>{_>0&&b<=0&&f()}),We(i,async()=>{t.value&&(g(),await m())});const u=async()=>{if(t.value=!t.value,!t.value){g();return}await m(),f()},h=()=>(n.getContext("2d").drawImage(r.value,0,0),n.toDataURL("image/png")),f=()=>{const _=new CustomEvent("wf-webcam",{detail:{payload:h(),callback:()=>{d.value<=0||!t.value||setTimeout(()=>{f()},d.value)}}});a.value.dispatchEvent(_)},m=async()=>(r.value.style.display="",new Promise((_,b)=>{navigator.mediaDevices.getUserMedia||(l.error("This browser doesn't support webcam connection."),b());const v={video:!0};s.value.length>1&&(v.video={deviceId:i.value}),navigator.mediaDevices.getUserMedia(v).then(y=>{r.value.srcObject=y;const M=y.getVideoTracks()[0].getSettings().width,x=y.getVideoTracks()[0].getSettings().height;n.setAttribute("width",M.toString()),n.setAttribute("height",x.toString()),_()}).catch(y=>{l.error("An error occurred when trying to use the webcam.",y),b()})})),g=()=>{const _=r.value.srcObject;_&&_.getTracks().map(v=>v.stop()),r.value.srcObject=null,r.value.style.display="none"};return(_,b)=>{var v;return $(),R("div",{ref_key:"rootEl",ref:a,class:"CoreWebcamCapture"},[Ya(Z("div",zle,[Z("video",{ref_key:"videoEl",ref:r,autoplay:"true"},null,512)],512),[[Un,t.value]]),Z("div",qle,[d.value==0?($(),Ie(La,{key:0,onClick:f},{default:Xe(()=>b[1]||(b[1]=[pa(" Capture image ")])),_:1})):ge("",!0),Ce(La,{onClick:u},{default:Xe(()=>[pa(je(t.value?"Stop capture":"Start webcam capture"),1)]),_:1}),((v=s.value)==null?void 0:v.length)>1?($(),Ie(Ug,{key:1,modelValue:i.value,"onUpdate:modelValue":b[0]||(b[0]=y=>i.value=y)},{default:Xe(()=>[($(!0),R(Je,null,Ot(s.value,(y,M)=>($(),R("option",{key:y.deviceId,value:y.deviceId},je(y.label||`Webcam ${M+1}`),9,Wle))),128))]),_:1},8,["modelValue"])):ge("",!0)])],512)}}}),Xle=ke(Jle,[["__scopeId","data-v-c89e0cac"]]),Yle={writer:{name:"Reuse component",slot:"*",description:"Those components are used to reuse other components. Reused components share the same state and are updated together.",category:"Other",allowedChildrenTypes:[],fields:{proxyId:{name:"Component id",type:Q.Text,desc:"The id of the component to reuse."}}}},Qle=$e({...Yle,__name:"CoreReuse",props:{contextSlot:{}},setup(e){const t=e,a=re(ne.evaluatedFields),r=re(ne.instancePath).at(-2).componentId,o=re(ne.core),s=re(ne.renderProxiedComponent),i=re(ne.isBeingEdited),l=re(ne.componentId),c=ye(En("div","")),d=ye(!0),u=H(()=>{var g;return(g=o.getComponentById(a.proxyId.value))==null?void 0:g.type}),h=H(()=>u.value?o.getComponentDefinition(u.value):null);function f(g,_){d.value=t.contextSlot==="default",c.value=En("div",{class:["CoreReuse",_],style:{color:"var(--primaryTextColor)"}},i.value?g:"")}function m(){if(!a.proxyId.value)return f("No component selected to reuse","empty");if(l===a.proxyId.value||!h.value)return f("The id specified for reuse doesn't match any component.","invalid-value");if(!o.getContainableTypes(r).includes(u.value))return f("The component cannot be reused here.","invalid-context");d.value=t.contextSlot===(h.value.slot??"default");const g=s(a.proxyId.value,0,{class:["CoreReuse"]});c.value=g}return We([a.proxyId,h],m,{immediate:!0}),(g,_)=>d.value?($(),Ie(Ps(c.value),{key:0})):ge("",!0)}}),e2e={key:0,class:"controls"},t2e={key:2},a2e=["page"],n2e="A component to embed PDF documents.",r2e={writer:{name:"PDF",description:n2e,category:"Embed",fields:{source:{name:"PDF source",type:Q.Text,desc:"A valid URL. Alternatively, you can provide a state reference to a packed PDF file."},highlights:{name:"Highlights",default:JSON.stringify([]),desc:"A list of highlights to be applied to the PDF as a JSON array of strings.",type:Q.Object,validator:lg},selectedMatch:{name:"Selected highlight match",default:null,desc:"The index of the selected highlight match.",type:Q.Number},page:{name:"Page",type:Q.Number,desc:"The page to be displayed."},controls:Ut({name:"Enable controls",desc:"Show controls to navigate the PDF.",default:"yes"}),containerBackgroundColor:Tr,separatorColor:wa,primaryTextColor:ua,cssClasses:mt}}},o2e=$e({...r2e,__name:"CorePDF",setup(e){const t=re(ne.evaluatedFields,{});let a,n,r;const o=H(()=>t.highlights.value.filter(Boolean)),s=$t({completeWords:!1,ignoreCase:!0}),i=ye(1),l=ye(1),c=$t([]),d=ye(0),u=pt("rootEl"),h=pt("viewerEl"),f=ye(!1),m=ye(0),g=$t([]);function _(ee){return Pr(ee)&&"name"in ee&&"type"in ee&&"data"in ee&&typeof ee.data=="string"&&ee.data.startsWith("data:")}function b(ee){if(!(typeof ee!="string"||!ee.trim())){try{const j=JSON.parse(ee);if(Array.isArray(j)&&j.length>0){const K=j[0];if(_(K))return K.data}}catch{}return ee}}const v=H(()=>{var j;if(!((j=t.source)!=null&&j.value))return;const ee=b(t.source.value);if(ee)try{return Rw(ee)}catch{return}}),y=H(()=>v.value===void 0?{url:t.source.value,isEvalSupported:!1}:{data:v.value,isEvalSupported:!1});ia(async()=>{const ee=await zt(()=>import("./index-BO2lDBxy.js"),__vite__mapDeps([9,10]),import.meta.url),j=await zt(()=>import("./pdf-Car1WtOr.js"),[],import.meta.url);j.GlobalWorkerOptions.workerSrc=new URL(""+new URL("pdf.worker.min-CyUfim15.mjs",import.meta.url).href,import.meta.url).toString(),r=ee.VuePDF;const K=ee.usePDF;({pdf:a,pages:n}=K(y)),M()});function M(){f.value=!0,m.value=0,g.value=[],c.value=[]}function x(ee){g.value=[...g.value,{matches:ee.matches,page:ee.page}]}function S(ee){m.value++}function L(){c.value=g.value.reduce((ee,j)=>{const K=j.matches.map((G,T)=>({page:j.page,str:G.str,index:T}));return ee.push(...K),ee},[]).sort((ee,j)=>ee.page===j.page?ee.index-j.index:ee.page-j.page)}function F(){L(),d.value&&be(d.value),t.selectedMatch.value&&(d.value=t.selectedMatch.value)}function te(ee){const j=ee.target.getBoundingClientRect(),K=[...ee.target.children].filter(G=>G.className.includes("page")).find(G=>{const T=G.getBoundingClientRect(),O=T.y-j.y;return O<j.height/2&&O+T.height>j.height/2});K&&(l.value=Number(K.getAttribute("page")))}function J(ee,j){let K=0,G=ee;for(;G&&G!==j;)K+=G.offsetTop,G=G.offsetParent;return K}function be(ee){if(ee<1||ee>c.value.length)return;const j=c.value[ee-1];if(!j)return;const G=u.value.querySelectorAll(`div[page='${j.page}'] span.highlight`)[j.index];G instanceof HTMLElement&&(h.value.scrollTop=J(G,h.value))}const oe=ee=>{if(ee<1||ee>(n==null?void 0:n.value))return;const j=u.value.querySelector("div[page='"+ee+"']");j instanceof HTMLElement&&(h.value.scrollTop=J(j,h.value))};function Te(){d.value<c.value.length?d.value=d.value+1:d.value=1}function Ue(){d.value>1?d.value=d.value-1:d.value=c.value.length}function Ze(){i.value=i.value<2?i.value+.1:i.value}function Me(){i.value=i.value>.25?i.value-.1:i.value}return We(m,()=>{var ee;m.value===(n==null?void 0:n.value)&&(ee=t.page)!=null&&ee.value&&oe(t.page.value)}),We([g,m],()=>{(o.value.length==0||g.value.length===(n==null?void 0:n.value))&&m.value===(n==null?void 0:n.value)&&(F(),f.value=!1)}),We([i,t.source],M),We(o,()=>{g.value=[],c.value=[]}),We(d,()=>{be(d.value)}),We(t.selectedMatch,()=>{d.value=t.selectedMatch.value}),We(t.page,()=>{oe(t.page.value)}),(ee,j)=>($(),R("div",{ref_key:"rootEl",ref:u,class:"CorePDF"},[E(t).controls.value?($(),R("div",e2e,[Ce(wn,{onClick:j[0]||(j[0]=()=>oe(l.value-1))},{default:Xe(()=>[Ce(bt,{name:"arrow-up"})]),_:1}),Ce(wn,{onClick:j[1]||(j[1]=()=>oe(l.value+1))},{default:Xe(()=>[Ce(bt,{name:"arrow-down"})]),_:1}),($(),R("span",{key:l.value},je(l.value)+" / "+je(E(n)),1)),Ce(wn,{disabled:f.value,onClick:Ze},{default:Xe(()=>[Ce(bt,{name:"zoom-in"})]),_:1},8,["disabled"]),Ce(wn,{disabled:f.value,onClick:Me},{default:Xe(()=>[Ce(bt,{name:"zoom-out"})]),_:1},8,["disabled"]),Z("span",null,je(Math.round(i.value*100))+"%",1),j[2]||(j[2]=Z("span",{class:"separator"},null,-1)),c.value.length?($(),Ie(wn,{key:0,onClick:Ue},{default:Xe(()=>[Ce(bt,{name:"chevron-left"})]),_:1})):ge("",!0),c.value.length?($(),Ie(wn,{key:1,onClick:Te},{default:Xe(()=>[Ce(bt,{name:"chevron-right"})]),_:1})):ge("",!0),c.value.length?($(),R("span",t2e,"Matches "+je(d.value)+" / "+je(c.value.length),1)):ge("",!0)])):ge("",!0),Z("div",{ref_key:"viewerEl",ref:h,class:"viewer",onScroll:te},[($(!0),R(Je,null,Ot(E(n),K=>($(),R("div",{key:K,page:K,class:"page"},[Ce(E(r),{scale:i.value,pdf:E(a),page:K,"text-layer":"","highlight-text":o.value,"highlight-options":s.value,onHighlight:x,onLoaded:S},null,8,["scale","pdf","page","highlight-text","highlight-options"])],8,a2e))),128))],544),j[3]||(j[3]=Z("div",{class:"mask"},null,-1))],512))}}),s2e=ke(o2e,[["__scopeId","data-v-0e66d538"]]),i2e={key:0,class:"noURLProvided"},l2e=["src","referrerpolicy"],c2e="A component to embed an external resource in an iframe.",d2e=`
8439
8439
  def load_handler(state):
8440
8440
 
8441
8441
  # Sets status message when resource is loaded
@@ -8467,7 +8467,7 @@ def handle_keydown(state, payload):
8467
8467
  def handle_page_open(state, payload):
8468
8468
  page_key = payload
8469
8469
  state["message"] = f"The page {page_key} has been opened."
8470
- `,C2e="A container component representing a single page within the application.",A2e={writer:{name:"Page",category:"Root",events:{"wf-keydown":{desc:"Captures all key activity while this page is open.",stub:w2e},"wf-page-open":{desc:"Emitted when the page is opened.",stub:x2e}},description:C2e,allowedChildrenTypes:["*"],allowedParentTypes:["root"],fields:{key:{name:"Page key",desc:"Unique identifier. It's needed to enable navigation to this Page.",type:Q.IdKey},pageMode:{name:"Page mode",default:"compact",type:Q.Text,options:{compact:"Compact",wide:"Wide"},category:ot.Style},accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,emptinessColor:dg,containerBackgroundColor:kr,containerShadow:Rs,separatorColor:wa,buttonColor:cr,buttonTextColor:dr,buttonShadow:so,cssClasses:mt},previewField:"key"}},S2e=$e({...A2e,__name:"CorePage",setup(e){const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.builderManager),r=re(ne.notesManager),o=Ki();function s(c){var m;const d=c.target;if(!(d instanceof Element)||d.closest("[data-writer-unselectable]"))return;const u=d.closest("[data-writer-id]"),h=u==null?void 0:u.dataset.writerId;if(!h)return;const f=(m=u.dataset)==null?void 0:m.writerInstancePath;r.isAnnotating.value&&n.mode.value!=="preview"&&(c.preventDefault(),r.createNote(h,{instancePath:f}))}function i(c){const d=oae(c),u=c.target;t.value.contains(u)&&t.value.dispatchEvent(d)}function l(){const c=a.key.value,d=new CustomEvent("wf-page-open",{detail:{payload:c}});t.value.dispatchEvent(d)}return We(t,()=>{t.value&&t.value.addEventListener("mousedown",s,{signal:o.signal})}),ia(async()=>{document.addEventListener("keydown",i,{signal:o.signal}),l()}),(c,d)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CorePage"},[Z("div",b2e,[qt(c.$slots,"default",{slotName:"sidebar",positionlessSlot:!0},void 0,!0)]),Z("div",{class:ft(["main",{compact:E(a).pageMode.value=="compact",wide:E(a).pageMode.value=="wide"}]),"data-writer-container":""},[qt(c.$slots,"default",{},void 0,!0)],2)],512))}}),$2e=ke(S2e,[["__scopeId","data-v-77f91eb1"]]),E2e=/^((?<pageKey>[^/]*))?(\/(?<routeVars>.*))?$/;function kd(e=document.location.hash){var o;const a=(o=e.substring(1).match(E2e))==null?void 0:o.groups,n=a!=null&&a.pageKey?decodeURIComponent(a.pageKey):void 0;if(!a)return{pageKey:n,routeVars:new Map};const r=new URLSearchParams(a.routeVars);return{pageKey:n,routeVars:new Map(r.entries())}}function I2e(){const e=kd(),t=Object.fromEntries(e.routeVars.entries());return{pageKey:e.pageKey,routeVars:t}}function k2e(e){const{pageKey:t,routeVars:a}=e;let n="";if(t&&(n+=`${encodeURIComponent(t)}`),a.size>0){const r=new URLSearchParams([...a.entries()]);n+=`/${r.toString()}`}return n}function Xg(e){document.location.hash=k2e(e)}function T2e(e){const t=kd();t.pageKey=e,Xg(t)}function Rde(e){const t=kd(),a=(t==null?void 0:t.routeVars)??{};t.routeVars=new Map(Object.entries({...a,...e})),Xg(t)}const P2e=`
8470
+ `,C2e="A container component representing a single page within the application.",A2e={writer:{name:"Page",category:"Root",events:{"wf-keydown":{desc:"Captures all key activity while this page is open.",stub:w2e},"wf-page-open":{desc:"Emitted when the page is opened.",stub:x2e}},description:C2e,allowedChildrenTypes:["*"],allowedParentTypes:["root"],fields:{key:{name:"Page key",desc:"Unique identifier. It's needed to enable navigation to this Page.",type:Q.IdKey},pageMode:{name:"Page mode",default:"compact",type:Q.Text,options:{compact:"Compact",wide:"Wide"},category:ot.Style},accentColor:Ia,primaryTextColor:ua,secondaryTextColor:In,emptinessColor:dg,containerBackgroundColor:Tr,containerShadow:Ns,separatorColor:wa,buttonColor:dr,buttonTextColor:ur,buttonShadow:io,cssClasses:mt},previewField:"key"}},S2e=$e({...A2e,__name:"CorePage",setup(e){const t=pt("rootEl"),a=re(ne.evaluatedFields),n=re(ne.builderManager),r=re(ne.notesManager),o=Ki();function s(c){var m;const d=c.target;if(!(d instanceof Element)||d.closest("[data-writer-unselectable]"))return;const u=d.closest("[data-writer-id]"),h=u==null?void 0:u.dataset.writerId;if(!h)return;const f=(m=u.dataset)==null?void 0:m.writerInstancePath;r.isAnnotating.value&&n.mode.value!=="preview"&&(c.preventDefault(),r.createNote(h,{instancePath:f}))}function i(c){const d=oae(c),u=c.target;t.value.contains(u)&&t.value.dispatchEvent(d)}function l(){const c=a.key.value,d=new CustomEvent("wf-page-open",{detail:{payload:c}});t.value.dispatchEvent(d)}return We(t,()=>{t.value&&t.value.addEventListener("mousedown",s,{signal:o.signal})}),ia(async()=>{document.addEventListener("keydown",i,{signal:o.signal}),l()}),(c,d)=>($(),R("div",{ref_key:"rootEl",ref:t,class:"CorePage"},[Z("div",b2e,[qt(c.$slots,"default",{slotName:"sidebar",positionlessSlot:!0},void 0,!0)]),Z("div",{class:ft(["main",{compact:E(a).pageMode.value=="compact",wide:E(a).pageMode.value=="wide"}]),"data-writer-container":""},[qt(c.$slots,"default",{},void 0,!0)],2)],512))}}),$2e=ke(S2e,[["__scopeId","data-v-77f91eb1"]]),E2e=/^((?<pageKey>[^/]*))?(\/(?<routeVars>.*))?$/;function kd(e=document.location.hash){var o;const a=(o=e.substring(1).match(E2e))==null?void 0:o.groups,n=a!=null&&a.pageKey?decodeURIComponent(a.pageKey):void 0;if(!a)return{pageKey:n,routeVars:new Map};const r=new URLSearchParams(a.routeVars);return{pageKey:n,routeVars:new Map(r.entries())}}function I2e(){const e=kd(),t=Object.fromEntries(e.routeVars.entries());return{pageKey:e.pageKey,routeVars:t}}function k2e(e){const{pageKey:t,routeVars:a}=e;let n="";if(t&&(n+=`${encodeURIComponent(t)}`),a.size>0){const r=new URLSearchParams([...a.entries()]);n+=`/${r.toString()}`}return n}function Xg(e){document.location.hash=k2e(e)}function T2e(e){const t=kd();t.pageKey=e,Xg(t)}function Rde(e){const t=kd(),a=(t==null?void 0:t.routeVars)??{};t.routeVars=new Map(Object.entries({...a,...e})),Xg(t)}const P2e=`
8471
8471
  def handle_hashchange(state, payload):
8472
8472
  # The payload is a dictionary with the page key and all the route variables in the URL hash.
8473
8473
  # For example, if the current URL is http://localhost:3000/#main/animal=duck&colour=yellow
@@ -8504,16 +8504,16 @@ def handle_app_open(state):
8504
8504
 
8505
8505
  page_key = payload.get("page_key")
8506
8506
  route_vars = payload.get("route_vars")
8507
- `.trim(),V2e="The root component of the application, which serves as the starting point of the component hierarchy.",O2e={writer:{name:"Root",category:"Root",description:V2e,allowedChildrenTypes:["page"],fields:{appName:{name:"App name",type:Q.Text,desc:"The app name will be shown in the browser's title bar."},cssClasses:mt,buttonColor:cr,buttonShadow:so,accentColor:Ia,contentPadding:Ds,primaryTextColor:ua,buttonTextColor:dr,emptinessColor:dg,containerShadow:Rs,secondaryTextColor:In,separatorColor:wa,contentVAlign:wd,contentHAlign:Ns,contentWidth:QE},events:{"wf-app-open":{desc:"Captures the first application load, including page key and route vars.",stub:L2e},"wf-hashchange":{desc:"Capture changes to the URL hash, including page key and route vars.",stub:P2e}}}},H2e=$e({...O2e,__name:"CoreRoot",setup(e){const t=re(ne.core),a=re(ne.builderManager),n=re(ne.getChildrenVNodes),r=pt("rootEl"),{isComponentVisible:o}=Kl(t),s=H(()=>{const c=t.activePageId.value;if(!!t.getComponentById(c)&&t.isChildOf("root",c))return c;const u=t.getComponents("root",{includeBMC:!0,includeCMC:!0,sortedByPosition:!0});if(u.length==0)return null;const h=u.filter(f=>o(f.id));return h.length==0?null:h[0].id});ia(()=>{s.value&&t.activePageId.value!==s.value&&t.setActivePageId(s.value)});function i(){var u;const c=I2e(),d=new CustomEvent("wf-hashchange",{detail:{payload:c}});(u=r.value)==null||u.dispatchEvent(d),c.pageKey&&t.setActivePageFromKey(c.pageKey)}We(s,c=>{var h;const u=(h=t.getComponentById(c).content)==null?void 0:h.key;a&&!a.isComponentIdSelected(c)&&a.setSelection(null),qa().then(()=>{var f,m;window.scrollTo(0,0),(m=(f=document.querySelector(".ComponentRenderer"))==null?void 0:f.parentElement)==null||m.scrollTo(0,0)}),T2e(u)});const l=Ki();return ks(()=>{window.addEventListener("hashchange",()=>i(),{signal:l.signal}),i()}),(c,d)=>($(),R("div",{ref_key:"rootEl",ref:r,class:"CoreRoot","data-writer-container":""},[($(!0),R(Je,null,Ot(E(n)(),u=>($(),R(Je,{key:u.key},[u.key===`${s.value}:0`?($(),Ie(Ts(u),{key:0})):ge("",!0)],64))),128))],512))}}),R2e=ke(H2e,[["__scopeId","data-v-391634de"]]),N2e={key:0,class:"noAccessTokenProvided"},D2e=[{lat:37.79322359164316,lng:-122.39999318828129,name:"Marker"}],B2e={writer:{deprecated:!0,name:"Mapbox",description:"A component to embed a Mapbox map. It can be used to display a map with markers.",docs:"For this component you need Mapbox access token: https://www.mapbox.com/api-documentation/#access-tokens-and-token-scopes",category:"Embed",fields:{accessToken:{name:"Access Token",default:"",desc:"Access token from Mapbox",type:Q.Text},mapStyle:{name:"Map style",default:"mapbox://styles/mapbox/standard",type:Q.Text,desc:"Map style URL"},zoom:{name:"Zoom",default:"8",type:Q.Number},lat:{name:"Latitude",default:"37.79322359164316",type:Q.Number,validator:_d},lng:{name:"Longitude",default:"-122.39999318828129",type:Q.Number,validator:bd},markers:{name:"Markers",init:JSON.stringify(D2e,null,2),desc:"",type:Q.Object,validator:cg},controls:Ut({name:"Enable controls",default:"yes",desc:"Show map controls"}),cssClasses:mt},events:{"mapbox-marker-click":{desc:"Capture single clicks on markers.",eventPayloadExample:[{lat:1,lng:1,name:"Marker"}]},"mapbox-click":{desc:"Capture single click on map.",eventPayloadExample:{lat:1,lng:1}}}}},F2e=$e({...B2e,__name:"CoreMapbox",setup(e){const t=re(ne.evaluatedFields),a=pt("rootEl"),n=pt("mapEl"),r=H(()=>[t.lng.value,t.lat.value]),o=ye(null);let s=[],i=null;const l=async()=>{if(!n.value||!t.accessToken.value)return;const d=await zt(()=>import("./mapbox-gl-IM8CBmd8.js").then(u=>u.m),[],import.meta.url);try{d.accessToken=t.accessToken.value,d.default&&(d.default.accessToken=t.accessToken.value),o.value=new d.Map({container:n.value,style:t.mapStyle.value,center:r.value,zoom:t.zoom.value}),o.value.on("click",u=>{const h=new CustomEvent("mapbox-click",{detail:{payload:{lat:u.lngLat.lat,lng:u.lngLat.lng}}});a.value.dispatchEvent(h)}),i=new d.NavigationControl,t.controls.value&&o.value.addControl(i),t.markers.value&&o.value.on("load",c)}catch(u){fa().error(u)}},c=async()=>{var u,h;if(!o.value)return;const d=await zt(()=>import("./mapbox-gl-IM8CBmd8.js").then(f=>f.m),[],import.meta.url);s.forEach(f=>f.remove()),s=[],(h=(u=t.markers)==null?void 0:u.value)==null||h.forEach(f=>{const m=new d.Marker().setLngLat([f.lng,f.lat]).addTo(o.value).setPopup(new d.Popup().setText(f.name));s.push(m),m.getElement().addEventListener("click",g=>{const _=new CustomEvent("mapbox-marker-click",{detail:{payload:f}});a.value.dispatchEvent(_),g.stopPropagation()})})};return We(t.controls,()=>{o.value&&(t.controls?o.value.addControl(i):o.value.removeControl(i))}),We(t.markers,async()=>{o.value&&await c()}),We(t.mapStyle,()=>{o.value&&o.value.setStyle(t.mapStyle.value)}),We(r,()=>{var d,u;o.value&&((d=r.value)!=null&&d.lat)&&((u=r.value)!=null&&u.lng)&&o.value.setCenter(r.value)}),We(t.zoom,()=>{o.value&&t.zoom.value&&o.value.setZoom(t.zoom.value)}),We([n,t.accessToken],()=>{l()}),(d,u)=>($(),R("div",{ref_key:"rootEl",ref:a,class:"CoreMapbox"},[E(t).accessToken.value?($(),R("div",{key:1,ref_key:"mapEl",ref:n,class:"map"},null,512)):($(),R("div",N2e,u[0]||(u[0]=[Z("h2",null,"MapBox cannot be initialised.",-1),Z("h3",null,"An access token hasn't been provided.",-1)]))),u[1]||(u[1]=Z("div",{class:"mask"},null,-1))],512))}}),j2e=ke(F2e,[["__scopeId","data-v-4859a323"]]),Td=new Set(["root","blueprints_root"]),Pd=new Set(["page","blueprints_blueprint"]),Nde=new Set([...Td,...Pd]);function U2e(e,t){const{type:a}=e[t],o=Rd().map(i=>({type:i,definition:Vi(i)})).filter(i=>i.definition.allowedParentTypes&&!i.definition.allowedParentTypes.includes(a));return new Set(o.map(i=>i.type))}function z2e(e,t){const{type:a,parentId:n}=e[t],r=Rd().filter(l=>!Td.has(l)),{allowedChildrenTypes:o,toolkit:s}=Vi(a);if(!o)return new Set([]);let i=new Set(o);if(o.includes("*")&&(i=new Set([...i,...r])),i.delete("inherit")){if(!n)return i;const l=Ld(e,n);i=new Set([...i,...l])}return s&&(i=new Set(Array.from(i).filter(l=>Vi(l).toolkit==s))),i}function Ld(e,t){const a=Array.from(z2e(e,t)),n=Array.from(U2e(e,t));return a.filter(o=>!n.includes(o))}function q2e(e){return Tr(e)&&"type"in e&&e.type==="writer/clipboard"&&"components"in e&&Array.isArray(e.components)}function W2e(){const e=fa();async function t(){try{const n=await navigator.clipboard.readText(),r=JSON.parse(n);return q2e(r)?r.components:void 0}catch(n){if(n instanceof Error&&n.name==="NotAllowedError")throw Error("Please allow clipboard access in your browser settings or try again");return}}function a(n){const r={type:"writer/clipboard",components:n};try{navigator.clipboard.writeText(JSON.stringify(r))}catch(o){e.warn("Failed to write components in the clipboard",o)}}return{get:t,set:a}}function Z2e(e,t){let a=E(t);const n=new Set;for(;a&&!n.has(a);){n.add(a);const r=e.getComponentById(a);if(!r)return;if(Pd.has(r.type))return r;a=r.parentId}}const Yg="true";function Dde(e){var a;const t=(a=e==null?void 0:e.content)==null?void 0:a.isSharedBlueprint;return String(t)===Yg}function Bs(e,t,a){const n=W2e();function r(){let B="";const N=new Uint16Array(16);return window.crypto.getRandomValues(N),N.forEach(U=>{B+=(U%36).toString(36)}),B}function o(I){const B=e.getComponentById(I);if(!B||B.position==0||!e.getComponentById(B.parentId))return;const se=Me(I,-1),Se=`move-up-${I}`;t.openMutationTransaction(Se,"Move up"),t.registerPreMutation(se),se.position++,t.registerPostMutation(se),t.registerPreMutation(B),B.position--,t.registerPostMutation(B),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function s(I){const B=e.getComponentById(I);if(!B||!e.getComponentById(B.parentId)||B.position==-2)return;const se=Me(I,1);if(!se)return;const Se=`move-down-${I}`;t.openMutationTransaction(Se,"Move down"),t.registerPreMutation(se),se.position--,t.registerPostMutation(se),t.registerPreMutation(B),B.position++,t.registerPostMutation(B),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function i(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=e.getComponentById(U.parentId);if(!se||I==B||se.id==B&&N===null)return;const Se=`move-${I}`;t.openMutationTransaction(Se,"Move"),t.registerPreMutation(U),m(I,-1),U.position=N??xe(B,U.type),U.parentId=B,m(I,1),t.registerPostMutation(U),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function l(I,B){const N=e.getComponentById(I);if(!N)return!1;const U=e.getContainableTypes(I);return!(N!=null&&N.isCodeManaged)&&!e.isChildOf(B.id,I)&&U.includes(B.type)}function c(I){const B=e.getComponentById(I),N=Me(I,1);if(N&&l(N.id,B))return i(I,N.id),N.id}function d(I){const B=e.getComponentById(I),N=e.getComponentById(B.parentId).parentId;if(N&&l(N,B))return i(I,N,0),N}function u(I,B,N,U){const se=r(),Se=e.getComponentDefinition(I),{fields:Ne}=Se,ut={...(U==null?void 0:U.content)??{}};return Object.entries(Ne??{}).forEach(([Ee,Oe])=>{Ee in ut||(ut[Ee]=Oe.init)}),{...U??{},id:se,type:I,parentId:B,content:ut,handlers:{},position:N??xe(B,I)}}function h(I,B,N,U){const se=u(I,B,N,U);se.id=(U==null?void 0:U.id)??se.id;const Se=`create-${se.id}`;return t.openMutationTransaction(Se,"Create"),e.addComponent(se),m(se.id,1),t.registerPostMutation(se),t.closeMutationTransaction(Se),e.sendComponentUpdate(),a==null||a.track(I.startsWith("blueprints_")?"blueprints_block_added":"ui_block_added",{componentId:se.id}),se.id}function f(I,B){if(B.length===0)return[];const N=B.reduce((Se,{type:Ne,position:ut,initProperties:ie},Ee)=>{const Oe=Ee===0?I:Se.at(-1).id??I,Pe=u(Ne,Oe,ut,ie);return Pe.id=(ie==null?void 0:ie.id)??Pe.id,Se.push(Pe),Se},[]),U=N.map(Se=>Se.id),se=`create-${U.join("-")}`;t.openMutationTransaction(se,"Create");for(const Se of N)e.addComponent(Se),m(Se.id,1),t.registerPostMutation(Se),a==null||a.track(Se.type.startsWith("blueprints_")?"blueprints_block_added":"ui_block_added",{componentId:Se.id});return t.closeMutationTransaction(se),e.sendComponentUpdate(),U}function m(I,B){const N=e.getComponentById(I);if(e.getComponentDefinition(N.type).positionless)return;e.getComponents(N.parentId,{includeBMC:!0,includeCMC:!1}).filter(Ne=>Ne.id!==I).filter(Ne=>Ne.position>=N.position).map(Ne=>{t.registerPreMutation(Ne),Ne.position+=B,t.registerPostMutation(Ne)})}function g(I){const B=e.getComponentById(I),N=[],U=se=>{const Se=e.getComponents(se.id);N.push(se),Se.map(Ne=>U(Ne))};return U(B),N}function _(I){return e.getComponents().filter(B=>{var N;return(N=B.outs)==null?void 0:N.find(U=>U.toNodeId==I)})}function b(...I){const B=I.map(U=>e.getComponentById(U)).filter(Boolean);if(B.length===0)return;const N=`delete-${B.map(U=>U.id).join(",")}`;t.openMutationTransaction(N,"Delete");for(const U of B){U.parentId&&m(U.id,-1);const se=_(U.id);for(const Ne of se)t.registerPreMutation(Ne),Ne.outs=[...Ne.outs.filter(ut=>ut.toNodeId!==U.id)];a==null||a.track(U.type.startsWith("blueprints_")?"blueprints_block_deleted":"ui_block_deleted",{componentId:U.id});const Se=g(U.id);for(const Ne of Se)t.registerPreMutation(Ne),e.deleteComponent(Ne.id),t.removeSelectedComponentId(Ne.id)}for(const{pageType:U,rootId:se}of[{rootId:"root",pageType:"page"},{rootId:"blueprints_root",pageType:"blueprints_blueprint"}]){if(e.getComponents(se,{includeBMC:!0,includeCMC:!0}).length>0)continue;const Ne=u(U,se);e.addComponent(Ne),t.registerPostMutation(Ne),e.setActivePageId(Ne.id)}t.closeMutationTransaction(N),e.sendComponentUpdate()}function v(I){return b(I)}function y(I){return Td.has(I)}function M(I){const B=e.getComponentById(I);return!y(I)&&!(B!=null&&B.isCodeManaged)}function x(I){const B=e.getComponentById(I);return!(B!=null&&B.isCodeManaged)&&e.getContainableTypes(I).length>0}function S(I){return!y(I)}function L(I){const B=e.getComponentById(I);return!y(I)&&!(B!=null&&B.isCodeManaged)}function F(I){const B=e.getComponentById(I);return!y(I)&&!(B!=null&&B.isCodeManaged)}function te(I){return!y(I)}function J(I){return e.getComponents(I).length>0}function be(I){return!!Me(I,1)}function oe(I){return!!Me(I,-1)}function Te(I,B){const N=e.getComponentById(I);if(!N)return;const U=N.parentId;if(!U)return;let se;B&&(se=B.split(",").slice(0,-1).join(",")),t.setSelection(U,se)}function Ue(I){const B=e.getComponents(I).sort((N,U)=>N.position-U.position).at(0);B&&t.setSelection(B.id)}function Ze(I){const B=e.getComponentById(I);return B?(t.setSelection(B.id),!0):!1}function Me(I,B){if(y(I))return;const N=e.getComponentById(I);if(!N)return;const{parentId:U,position:se}=N,Se=se+B;return e.getComponents(U,{includeBMC:!0,includeCMC:!1}).find(Ne=>Ne.position===Se&&Ne.parentId===U)}function ee(I){var se,Se;if(y(I))return;const B=(se=e.getComponentById(I))==null?void 0:se.parentId;if(!B)return;const N=e.getComponents(B).sort((Ne,ut)=>Ne.position-ut.position),U=N.findIndex(Ne=>Ne.id===I);U===-1&&U+1===N.length||t.setSelection((Se=N[U+1])==null?void 0:Se.id)}function j(I){const B=Me(I,-1);B&&t.setSelection(B.id)}function K(I){if(I.length==0)return!1;const B={};return[...e.getComponents(),...I].forEach(U=>{B[U.id]=U}),I.map(U=>Ld(B,U.parentId).includes(U.type)).every(U=>U)}function G(I){const B=e.getComponentById(I);return!(!B||B.isCodeManaged)}function T(I){const B=ut=>e.getComponents(ut,{includeBMC:!0,includeCMC:!1}).filter(Oe=>{var Ke;return!((Ke=e.getComponentDefinition(Oe.type))==null?void 0:Ke.positionless)}).length,N=e.getComponentById(I);if(!N||N.isCodeManaged)return{up:!1,down:!1};if(e.getComponentDefinition(N.type).positionless)return{up:!1,down:!1};const se=N.parentId?B(N.parentId):0,Se=se>0&&N.position>0,Ne=se>0&&N.position<se-1;return{up:Se,down:Ne}}function O(I){if(!e.getComponentById(I))return;const N=g(I);n.set(N),t.setSelection(null),v(I),e.sendComponentUpdate()}function k(I){const B=JSON.parse(JSON.stringify(I));return B.forEach(N=>{delete N.isCodeManaged;const U=r();B.filter(se=>se.id!==N.id).map(se=>{var Se;se.parentId==N.id&&(se.parentId=U),(Se=se.outs)==null||Se.forEach(Ne=>{Ne.toNodeId==N.id&&(Ne.toNodeId=U)})}),N.id=U,typeof N.x<"u"&&typeof N.y<"u"&&(N.x+=36,N.y+=36)}),B}function C(I){if(!e.getComponentById(I))return;const N=g(I),U=k(N);n.set(U)}async function P(I){if(!e.getComponentById(I))return;const N=await n.get();if(!N)throw Error("The clipboard doesn't contain Writer data");if(!N.length)throw Error("The clipboard doesn't contain components");const U=N[0];return typeof U.outs<"u"&&U.parentId!==I&&(U.outs=[]),ae(I,N)}function ae(I,B){var se;n.set(k(B));const N=B[0];if(N.parentId=I,N.position=xe(I,N.type),!K(B)){const Se=(se=e.getComponentById(I))==null?void 0:se.parentId;if(Se)return ae(Se,B);throw Error("Could not paste the components here")}const U=`paste-copy-${I}`;t.openMutationTransaction(U,"Paste from copy"),B.map(Se=>{e.addComponent(Se),t.registerPostMutation(Se)}),t.closeMutationTransaction(U),e.sendComponentUpdate()}function xe(I,B){if(e.getComponentDefinition(B).positionless)return-2;const U=e.getComponents(I,{includeBMC:!0,includeCMC:!1}).filter(se=>se.position!==-2);return U.length>0?Math.max(Math.max(...U.map(Se=>Se.position))+1,0):0}function ve(){var B,N;const I=t.getMutationTransactionsSnapshot();return{isUndoAvailable:!!I.undo,isRedoAvailable:!!I.redo,undoDesc:(B=I.undo)==null?void 0:B.desc,redoDesc:(N=I.redo)==null?void 0:N.desc}}function ze(){const I=t.consumeUndoTransaction();I&&(Object.entries(I.mutations).forEach(([B,N])=>{if(N.jsonPre&&N.jsonPost){e.addComponent(JSON.parse(N.jsonPre));return}if(!N.jsonPre&&N.jsonPost){e.deleteComponent(B);return}if(N.jsonPre&&!N.jsonPost){e.addComponent(JSON.parse(N.jsonPre));return}}),e.sendComponentUpdate())}function Ye(){const I=t.consumeRedoTransaction();I&&(Object.entries(I.mutations).forEach(([B,N])=>{if(N.jsonPre&&N.jsonPost){e.addComponent(JSON.parse(N.jsonPost));return}if(!N.jsonPre&&N.jsonPost){e.addComponent(JSON.parse(N.jsonPost));return}if(N.jsonPre&&!N.jsonPost){e.deleteComponent(B);return}}),e.sendComponentUpdate())}function ct(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=`edit-${I}-content-${B}`;t.openMutationTransaction(se,"Edit property",!0),t.registerPreMutation(U),U.content[B]=N,t.registerPostMutation(U),t.closeMutationTransaction(se),e.sendComponentUpdate()}function wt(I,B){const N=e.getComponentById(I);if(!N)return;const U=`add-${I}-out-${B.outId}-${B.toNodeId}`;t.openMutationTransaction(U,"Add out",!0),t.registerPreMutation(N),N.outs=[...N.outs??[],B],t.registerPostMutation(N),t.closeMutationTransaction(U),e.sendComponentUpdate(),a==null||a.track("ui_blueprint_connected",{componentIds:[I,B.toNodeId],outId:B.outId})}function D(I,B){const N=e.getComponentById(I);if(!N)return;const U=`edit-${I}-out-${B.outId}-${B.toNodeId}`;t.openMutationTransaction(U,"Edit out",!0),t.registerPreMutation(N),N.outs=N.outs.filter(se=>!(B.outId===se.outId&&B.toNodeId===se.toNodeId)),t.registerPostMutation(N),t.closeMutationTransaction(U),e.sendComponentUpdate()}function q(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=`change-${I}-coordinates`;t.openMutationTransaction(se,"Change coordinates",!1),t.registerPreMutation(U),U.x=Math.floor(B),U.y=Math.floor(N),t.registerPostMutation(U),t.closeMutationTransaction(se),e.sendComponentUpdate()}function he(I){const B=Object.entries(I);if(B.length==0)return;const N=`change-multiple-coordinates-${Object.keys(I).join(",")}`;t.openMutationTransaction(N,"Change coordinates",!1),B.forEach(([U,{x:se,y:Se}])=>{const Ne=e.getComponentById(U);Ne&&(t.registerPreMutation(Ne),Ne.x=Math.floor(se),Ne.y=Math.floor(Se),t.registerPostMutation(Ne))}),t.closeMutationTransaction(N),e.sendComponentUpdate()}function me(I,B,N="",U=!1){const se=e.getComponentById(I);if(!se)return;const Se=`change-visibility-${I}`;t.openMutationTransaction(Se,"Change visibility",!0),t.registerPreMutation(se),se.visible==null&&(se.visible={expression:!0,binding:"",reversed:!1}),typeof B=="boolean"?se.visible.expression=B:B=="custom"&&(se.visible={expression:"custom",binding:N,reversed:U}),t.registerPostMutation(se),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function _e(I,B,N){const U=e.getComponentById(I);if(!U)return;let se;if(N)se=N;else{const Ne=e.getComponentDefinition(U.type),ie=Object.entries(Ne.events).filter(([Ee,Oe])=>Oe.bindable).map(([Ee,Oe])=>Ee);se=ie==null?void 0:ie[0]}if(!se)return;const Se=`change-binding-${I}`;t.openMutationTransaction(Se,"Change binding",!0),t.registerPreMutation(U),B?U.binding={eventType:se,stateRef:B}:delete U.binding,t.registerPostMutation(U),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function Ae(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=`set-handler-${I}`;t.openMutationTransaction(se,"Set event handler",!0),t.registerPreMutation(U),N?(U.handlers||(U.handlers={}),U.handlers[B]=N):(delete U.handlers[B],Object.keys(U.handlers).length==0&&delete U.handlers),t.registerPostMutation(U),t.closeMutationTransaction(se),e.sendComponentUpdate()}async function pe(I){var se;const B=e.getComponentById(I);if(!B||!((se=e.getComponentDefinition(B.type))==null?void 0:se.name))return;const U=Z2e(e,I);if(U){switch(U==null?void 0:U.type){case"page":t.mode.value="ui";break;case"blueprints_blueprint":t.mode.value="blueprints";break}return e.setActivePageId(U.id),U.id}}function ce(I){return g(I).slice(1).filter(N=>{var U;return N.type!=="note"&&((U=e.getComponentDefinition(N.type))==null?void 0:U.category)!=="Internal"})}function ue(I){const B=r(),N=u("blueprints_blueprint","blueprints_root",void 0,{content:{key:I.title,isSharedBlueprint:Yg,sourceBlueprintId:I.id,deployedVersion:String(I.version),deployedDescription:I.description}});N.id=B;const U=k(I.components),se=new Set(U.map(Ne=>Ne.id));if(U.forEach(Ne=>{(!Ne.parentId||!se.has(Ne.parentId))&&(Ne.parentId=B)}),!K([N,...U]))throw Error("Cannot install blueprint: components are not compatible");const Se=`install-shared-blueprint-${B}`;return t.openMutationTransaction(Se,"Install shared blueprint"),e.addComponent(N),t.registerPostMutation(N),U.forEach(Ne=>{e.addComponent(Ne),t.registerPostMutation(Ne)}),t.closeMutationTransaction(Se),e.sendComponentUpdate(),a==null||a.track("blueprints_shared_installed",{blueprintId:I.id}),B}return{generateNewComponentId:r,moveComponent:i,moveComponentUp:o,moveComponentDown:s,cutComponent:O,copyComponent:C,pasteComponent:P,createAndInsertComponent:h,createAndInsertComponentsTree:f,removeComponentSubtree:v,removeComponentsSubtree:b,isPasteAllowed:G,undo:ze,redo:Ye,setContentValue:ct,addOut:wt,removeOut:D,changeCoordinates:q,changeCoordinatesMultiple:he,setVisibleValue:me,setBinding:_e,getUndoRedoSnapshot:ve,setHandlerValue:Ae,isAddAllowed:x,isCopyAllowed:S,isCutAllowed:L,isDeleteAllowed:F,isGoToParentAllowed:te,isGoToChildAllowed:J,isGoToNextSiblingAllowed:be,isGoToPrevSiblingAllowed:oe,repositionHigherSiblings:m,isDraggingAllowed:M,getEnabledMoves:T,goToParent:Te,goToChild:Ue,goToNextSibling:ee,goToPrevSibling:j,goToComponentParentPage:pe,moveComponentInsideNextSibling:c,moveComponentToParent:d,selectChild:Ze,extractBlueprintComponents:ce,installSharedBlueprint:ue}}const K2e=30,G2e=/^application\/json;writer=(?<componentType>\w+),(?<componentId>[\w\-]*)$/,ei=ye(null),vr=ye(null),I1=ye(!1);let ec=null,k1=null;function J2e(e){function t(_){const b=_.dataTransfer.types[0],v=b==null?void 0:b.match(G2e);if(!(v!=null&&v.groups))return;const{componentType:y,componentId:M}=v.groups;return{draggedType:y,draggedId:y==="blueprints_shared"?"":M,sourceBlueprintId:y==="blueprints_shared"?M:void 0}}function a(_){const y=(_.closest("[data-writer-cage]")??_).closest("[data-writer-id]");if(y)return y.dataset.writerId}function n(_){const b=t(_);if(!b)return;const{draggedType:v,draggedId:y}=b,M=a(_.target);if(!o(M,y,v))return;let S={};v==="blueprints_shared"&&b.sourceBlueprintId&&(S={sourceBlueprintId:b.sourceBlueprintId});const L={draggedType:v,draggedId:y,parentId:ei.value,position:k1,dragContent:S};return g(_),L}function r(_,b,v){const y=e.getComponentById(_);if(!y)return!1;const M=e.getContainableTypes(_);return!(y!=null&&y.isCodeManaged)&&!e.isChildOf(b,_)&&M.includes(v)}function o(_,b,v){const y=e.getComponentById(_);if(y)return r(_,b,v)?_:y.parentId?o(y.parentId,b,v):null}function s(_){if(I1.value){l(_);return}i(_)}function i(_){const b=t(_);if(!b)return;const{draggedType:v,draggedId:y}=b,M=_.target,x=a(M),S=o(x,y,v);if(!S||S==y)return;const F=M.closest(`[data-writer-id="${S}"]`).dataset.writerInstancePath;if(_.preventDefault(),vr.value!==F)ec=Date.now();else if(Date.now()-ec>=Ew){I1.value=!0,h(vr.value);return}ei.value=S,vr.value=F}function l(_){const b=t(_);if(!b)return;_.preventDefault();const v=document.querySelector(`[data-writer-instance-path="${vr.value}"]`);if(u(_.clientX,_.clientY,v)>K2e){g(_);return}const y=c(vr.value);if(y.length==0)return;const M=d(_.clientX,_.clientY,y);if(!M)return;const{el:x}=M,{draggedId:S}=b,L=parseInt(x.dataset.writerPosition),F=e.getComponentById(S);if(y.map(te=>{te.classList.contains("highlighted")&&te.classList.remove("highlighted")}),!x.classList.contains("highlighted")){if(x.classList.add("highlighted"),F&&F.parentId==ei.value&&L>F.position){k1=L-1;return}k1=L}}function c(_){const b=m(_);return Array.from(b.querySelectorAll("[data-writer-position]"))}function d(_,b,v){const y=v.map(M=>({el:M,distance:u(_,b,M)})).sort((M,x)=>M.distance>x.distance?1:-1);return y==null?void 0:y[0]}function u(_,b,v){const{top:y,left:M,right:x,bottom:S}=v.getBoundingClientRect(),L=Math.max(M-_,0,_-x),F=Math.max(y-b,0,b-S);return Math.sqrt(L*L+F*F)}function h(_){m(_).classList.add("crackedContainer")}function f(_){m(_).classList.remove("crackedContainer")}function m(_){const b=document.querySelector(`[data-writer-instance-path="${_}"]`);if(b.hasAttribute("data-writer-container"))return b;const v=b.querySelectorAll("[data-writer-container]");for(let y=0;y<v.length;y++){const M=v[y];if(M.closest("[data-writer-instance-path]")==b)return M}}function g(_){_.preventDefault(),vr.value&&(f(vr.value),vr.value=null),ei.value=null,ec=null,k1=null,I1.value=!1}return{candidateId:ei,candidateInstancePath:vr,isParentSuitable:r,isCandidacyConfirmed:I1,getComponentInfoFromDrag:t,dropComponent:n,assignInsertionCandidacy:s,removeInsertionCandidacy:g}}function tc(e,t){return Math.ceil(e/t)*t}function Em(e,t){return Math.round(e/t)*t}function Qg(e,t){return Math.hypot(t.x-e.x,t.y-e.y)}function Im({x:e,y:t},a){return{x:Em(e,a),y:Em(t,a)}}function Bc({x:e,y:t},{x:a,y:n}){return{x:e+a,y:t+n}}function km(e){return{x:e.x+e.width/2,y:e.y+e.height/2}}function T1(e,t,a){return e>=t&&e<=a}function Tm(e,t,a,n){return T1(e,a,n)||T1(t,a,n)||T1(a,e,t)||T1(n,e,t)}function X2e(e,t){const a=Tm(e.x,e.x+e.width,t.x,t.x+t.width),n=Tm(e.y,e.y+e.height,t.y,t.y+t.height);return a&&n}function Pm(e,t,a){const n=[{x:-a,y:-a},{x:-a,y:0},{x:-a,y:a},{x:0,y:-a},{x:0,y:a},{x:a,y:-a},{x:a,y:0},{x:a,y:a}],r=new Set,o=[],s=[];function i({x:f,y:m}){return{width:e.width,height:e.height,x:f,y:m}}function l(f){if(f.x<0||f.y<0)return!1;const m=i(f);return!t.some(g=>X2e(m,g))}function c(f){const m=`${f.x},${f.y}`;r.has(m)||(o.push(f),r.add(m))}for(c({x:e.x,y:e.y});o.length;){const f=o.shift();if(f===void 0)return;if(l(f)&&s.push(f),s.length===0)for(const m of n)c(Bc(f,m))}const d=km(e),u=f=>Qg(d,km(i(f))),h=s.sort((f,m)=>u(f)-u(m)).shift();return h?i(h):void 0}const Y2e="data:image/svg+xml,%3csvg%20width='29'%20height='33'%20viewBox='0%200%2029%2033'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109697)'%3e%3cpath%20d='M14.4995%200C22.2315%200%2028.4995%206.26801%2028.4995%2014C28.4995%2019.8214%2024.9459%2024.8114%2019.8901%2026.9229L14.4995%2032.3135L9.10791%2026.9229C4.05258%2024.8112%200.499512%2019.821%200.499512%2014C0.499512%206.26801%206.76753%200%2014.4995%200Z'%20fill='%23EDE2FF'/%3e%3cpath%20d='M15.1662%2011.3333H11.1662M17.8328%2014H11.1662M20.4995%2016C20.4995%2016.3536%2020.359%2016.6928%2020.109%2016.9428C19.8589%2017.1929%2019.5198%2017.3333%2019.1662%2017.3333H11.1662L8.49951%2020V9.33333C8.49951%208.97971%208.63999%208.64057%208.89004%208.39052C9.14008%208.14048%209.47922%208%209.83285%208H19.1662C19.5198%208%2019.8589%208.14048%2020.109%208.39052C20.359%208.64057%2020.4995%208.97971%2020.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_2417_109697'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(0.499512)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Q2e="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109696)'%20filter='url(%23filter0_d_2417_109696)'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='%23D4B2F7'/%3e%3cpath%20d='M16.1662%2011.3333H12.1662M18.8328%2014H12.1662M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109696'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109696'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109696'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109696'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",ece="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109695)'%20filter='url(%23filter0_d_2417_109695)'%3e%3cmask%20id='path-1-inside-1_2417_109695'%20fill='white'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'/%3e%3c/mask%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='%23D4B2F7'/%3e%3cpath%20d='M20.8901%2026.9229L20.5048%2026.0001L20.3226%2026.0762L20.183%2026.2157L20.8901%2026.9229ZM15.4995%2032.3135L14.7925%2033.0206L15.4996%2033.7276L16.2066%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.815%2026.2157L10.6754%2026.0762L10.4933%2026.0001L10.1079%2026.9229ZM15.4995%200V1C22.6792%201%2028.4995%206.8203%2028.4995%2014H29.4995H30.4995C30.4995%205.71573%2023.7838%20-1%2015.4995%20-1V0ZM29.4995%2014H28.4995C28.4995%2019.4038%2025.2015%2024.0386%2020.5048%2026.0001L20.8901%2026.9229L21.2755%2027.8456C26.6903%2025.5843%2030.4995%2020.2389%2030.4995%2014H29.4995ZM20.8901%2026.9229L20.183%2026.2157L14.7924%2031.6064L15.4995%2032.3135L16.2066%2033.0206L21.5972%2027.63L20.8901%2026.9229ZM15.4995%2032.3135L16.2066%2031.6063L10.815%2026.2157L10.1079%2026.9229L9.40087%2027.63L14.7925%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.4933%2026.0001C5.79702%2024.0385%202.49951%2019.4035%202.49951%2014H1.49951H0.499512C0.499512%2020.2385%204.30814%2025.584%209.72248%2027.8456L10.1079%2026.9229ZM1.49951%2014H2.49951C2.49951%206.8203%208.31981%201%2015.4995%201V0V-1C7.21524%20-1%200.499512%205.71573%200.499512%2014H1.49951Z'%20fill='white'%20mask='url(%23path-1-inside-1_2417_109695)'/%3e%3cpath%20d='M16.1662%2011.3333H12.1662M18.8328%2014H12.1662M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109695'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109695'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109695'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109695'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",tce="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109694)'%20filter='url(%23filter0_d_2417_109694)'%3e%3cmask%20id='path-1-inside-1_2417_109694'%20fill='white'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'/%3e%3c/mask%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='%23D4B2F7'/%3e%3cpath%20d='M20.8901%2026.9229L20.5048%2026.0001L20.3226%2026.0762L20.183%2026.2157L20.8901%2026.9229ZM15.4995%2032.3135L14.7925%2033.0206L15.4996%2033.7276L16.2066%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.815%2026.2157L10.6754%2026.0762L10.4933%2026.0001L10.1079%2026.9229ZM15.4995%200V1C22.6792%201%2028.4995%206.8203%2028.4995%2014H29.4995H30.4995C30.4995%205.71573%2023.7838%20-1%2015.4995%20-1V0ZM29.4995%2014H28.4995C28.4995%2019.4038%2025.2015%2024.0386%2020.5048%2026.0001L20.8901%2026.9229L21.2755%2027.8456C26.6903%2025.5843%2030.4995%2020.2389%2030.4995%2014H29.4995ZM20.8901%2026.9229L20.183%2026.2157L14.7924%2031.6064L15.4995%2032.3135L16.2066%2033.0206L21.5972%2027.63L20.8901%2026.9229ZM15.4995%2032.3135L16.2066%2031.6063L10.815%2026.2157L10.1079%2026.9229L9.40087%2027.63L14.7925%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.4933%2026.0001C5.79702%2024.0385%202.49951%2019.4035%202.49951%2014H1.49951H0.499512C0.499512%2020.2385%204.30814%2025.584%209.72248%2027.8456L10.1079%2026.9229ZM1.49951%2014H2.49951C2.49951%206.8203%208.31981%201%2015.4995%201V0V-1C7.21524%20-1%200.499512%205.71573%200.499512%2014H1.49951Z'%20fill='white'%20mask='url(%23path-1-inside-1_2417_109694)'/%3e%3cpath%20d='M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109694'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109694'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109694'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109694'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",ace="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109693)'%20filter='url(%23filter0_d_2417_109693)'%3e%3cmask%20id='path-1-inside-1_2417_109693'%20fill='white'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'/%3e%3c/mask%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='black'/%3e%3cpath%20d='M20.8901%2026.9229L20.5048%2026.0001L20.3226%2026.0762L20.183%2026.2157L20.8901%2026.9229ZM15.4995%2032.3135L14.7925%2033.0206L15.4996%2033.7276L16.2066%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.815%2026.2157L10.6754%2026.0762L10.4933%2026.0001L10.1079%2026.9229ZM15.4995%200V1C22.6792%201%2028.4995%206.8203%2028.4995%2014H29.4995H30.4995C30.4995%205.71573%2023.7838%20-1%2015.4995%20-1V0ZM29.4995%2014H28.4995C28.4995%2019.4038%2025.2015%2024.0386%2020.5048%2026.0001L20.8901%2026.9229L21.2755%2027.8456C26.6903%2025.5843%2030.4995%2020.2389%2030.4995%2014H29.4995ZM20.8901%2026.9229L20.183%2026.2157L14.7924%2031.6064L15.4995%2032.3135L16.2066%2033.0206L21.5972%2027.63L20.8901%2026.9229ZM15.4995%2032.3135L16.2066%2031.6063L10.815%2026.2157L10.1079%2026.9229L9.40087%2027.63L14.7925%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.4933%2026.0001C5.79702%2024.0385%202.49951%2019.4035%202.49951%2014H1.49951H0.499512C0.499512%2020.2385%204.30814%2025.584%209.72248%2027.8456L10.1079%2026.9229ZM1.49951%2014H2.49951C2.49951%206.8203%208.31981%201%2015.4995%201V0V-1C7.21524%20-1%200.499512%205.71573%200.499512%2014H1.49951Z'%20fill='white'%20mask='url(%23path-1-inside-1_2417_109693)'/%3e%3cpath%20d='M15.4995%2010.6667V14.6667M13.4995%2012.6667H17.4995M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='white'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109693'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109693'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109693'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109693'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",nce=["src"],rce=$e({__name:"BaseNote",props:{componentId:{type:String,required:!0}},setup(e){const t=e,a=re(ne.core),n=re(ne.notesManager),r=H(()=>a.getComponentById(t.componentId)),{state:o}=n.useNoteInformation(r),s=H(()=>{switch(o.value){case"hover":return Q2e;case"active":return ece;case"new":return tce;case"cursor":return ace;default:return Y2e}});function i(){n.selectNote(t.componentId,"show")}return(l,c)=>($(),R("button",{type:"button",class:"BaseNote","data-writer-unselectable":"true",onMouseenter:c[0]||(c[0]=d=>E(n).hoveredNoteId.value=e.componentId),onMouseleave:c[1]||(c[1]=d=>E(n).hoveredNoteId.value=void 0),onClick:i},[Z("img",{src:s.value,width:"32",height:"32"},null,8,nce)],32))}}),oce=ke(rce,[["__scopeId","data-v-1f4e58ab"]]),Lm=5;function sce(e){const{wrapperRef:t,builderManager:a,isAnnotating:n}=e,r=$t({isSelecting:!1,startX:0,startY:0,left:0,top:0,width:0,height:0}),o=Ki(),s=H(()=>r.value.isSelecting),i=ye(!1),l=ye(!1);let c=null,d=null,u=null,h=null,f=null,m=null;function g(ee){if(a.mode.value==="preview"){i.value=!1;return}if(n.value){i.value=!1;return}if(ee.shiftKey||ee.ctrlKey||ee.metaKey){i.value=!1;return}if(a.mode.value==="blueprints"&&!ee.altKey){i.value=!1;return}if(!(ee.target instanceof Element)){i.value=!1;return}const j=ee.target,K=t.value;if(!K||!K.contains(j)){i.value=!1;return}if(j.closest("[data-writer-id]"))if(a.mode.value==="blueprints"){if(!b(j)){i.value=!1;return}}else{i.value=!1;return}if(!y(j)){i.value=!1;return}if(a.mode.value==="blueprints"&&!v(j)){i.value=!1;return}i.value=!0}function _(ee){return a.mode.value==="preview"||n.value?!1:a.mode.value==="blueprints"?!(!ee.altKey||ee.shiftKey||ee.ctrlKey||ee.metaKey):!(ee.shiftKey||ee.ctrlKey||ee.metaKey||ee.altKey)}function b(ee){const j=ee.closest("[data-writer-id]");if(!j)return!0;const K=ee.closest(".BlueprintsBlueprint");return K?j===K:!1}function v(ee){const j=ee.closest(".BlueprintsBlueprint");if(!j)return!1;const K=j.querySelector(".nodeContainer");return K?K.contains(ee):!1}function y(ee){return!(ee.closest("[data-writer-unselectable]")||ee.classList.contains("selectionRectangle"))}function M(ee,j){const K=ee.querySelectorAll("[data-writer-id]"),G=[];for(const T of Array.from(K)){if(T.closest("[data-writer-unselectable]"))continue;const O=T.getBoundingClientRect();if(O.left>=j.left&&O.right<=j.right&&O.top>=j.top&&O.bottom<=j.bottom){const C=T.dataset.writerId,P=T.dataset.writerInstancePath;C&&G.push({componentId:C,instancePath:P&&P.trim()?P:void 0})}}return G}function x(){r.value.isSelecting&&(c&&(c.abort(),c=null),d!==null&&(cancelAnimationFrame(d),d=null),u=null,h!==null&&(cancelAnimationFrame(h),h=null),f=null,m!==null&&(clearTimeout(m),m=null),r.value={...r.value,isSelecting:!1},document.body.style.userSelect="",document.body.style.cursor="")}function S(ee){const K=window.getComputedStyle(ee).transform;let G=1,T=1;if(K&&K!=="none"){const O=K.match(/matrix\(([^)]+)\)/);if(O){const k=O[1].split(",").map(C=>parseFloat(C.trim()));k.length>=4&&(G=k[0],T=k[3])}}return{scaleX:G,scaleY:T}}function L(ee,j){const K=ee.getBoundingClientRect(),{scaleX:G,scaleY:T}=S(ee);return{left:K.left+j.left*G,top:K.top+j.top*T,right:K.left+(j.left+j.width)*G,bottom:K.top+(j.top+j.height)*T}}function F(ee){if(!r.value.isSelecting||a.mode.value==="preview")return;const j=t.value;if(j)try{const K=j.getBoundingClientRect(),{scaleX:G,scaleY:T}=S(j),O=(ee.clientX-K.left)/G,k=(ee.clientY-K.top)/T+j.scrollTop,{startX:C,startY:P}=r.value,ae=Math.min(C,O),xe=Math.min(P,k)-j.scrollTop,ve=Math.abs(O-C),ze=Math.abs(k-P);r.value={...r.value,left:ae,top:xe,width:ve,height:ze}}catch{x()}}function te(ee){r.value.isSelecting&&a.mode.value!=="preview"&&(f=ee,h===null&&(h=requestAnimationFrame(()=>{f&&(F(f),f=null),h=null})))}function J(ee){r.value.isSelecting&&(te(ee),ee.preventDefault())}function be(ee){if(!_(ee)||!(ee.target instanceof Element))return;const j=ee.target;if(j.closest("[data-writer-id]"))if(a.mode.value==="blueprints"){if(!b(j))return}else return;if(!y(j))return;const G=t.value;if(!G||!G.contains(j))return;ee.stopPropagation(),ee.preventDefault();const T=G.getBoundingClientRect(),{scaleX:O,scaleY:k}=S(G),C=(ee.clientX-T.left)/O,P=(ee.clientY-T.top)/k+G.scrollTop;r.value={isSelecting:!0,startX:C,startY:P,left:C,top:P-G.scrollTop,width:0,height:0},document.body.style.userSelect="none",document.body.style.cursor="crosshair",c=new AbortController,G.addEventListener("mousemove",J,{signal:c.signal})}function oe(ee){if(r.value.isSelecting){a.mode.value==="blueprints"&&ee.stopPropagation(),te(ee),ee.preventDefault();return}u=ee,d===null&&(d=requestAnimationFrame(()=>{u&&(g(u),u=null),d=null}))}function Te(ee){if(!r.value.isSelecting)return;if(a.mode.value==="preview"){x();return}const{left:j,top:K,width:G,height:T}=r.value;if(G<Lm||T<Lm){x();return}ee.stopPropagation(),ee.preventDefault(),ee.stopImmediatePropagation();const O=t.value;if(!O){x();return}const k=L(O,{left:j,top:K,width:G,height:T}),C=M(O,k);if(C.length>0){const[P,...ae]=C;a.setSelection(P.componentId,P.instancePath,"click"),ae.forEach(({componentId:xe,instancePath:ve})=>{a.appendSelection(xe,ve,"click")}),l.value=!0,m&&clearTimeout(m),qa().then(()=>{requestAnimationFrame(()=>{l.value=!1,m=null})})}else a.setSelection(null);x()}function Ue(ee){if(r.value.isSelecting){const j=t.value;if(j&&ee.target instanceof Node&&j.contains(ee.target))return;x()}}function Ze(ee){l.value&&(ee.preventDefault(),ee.stopPropagation(),ee.stopImmediatePropagation())}Wn(()=>{m&&clearTimeout(m),o.abort(),x()});function Me(ee){i.value=!1}return{selectionRect:r,isCursorSelecting:s,isHoveringSelectableArea:i,justCompletedDragSelection:l,handleMousedown:be,handleMousemove:oe,handleMouseup:Te,handleMouseleave:Me,handleDocumentMouseup:Ue,handleDocumentClick:Ze}}const ice=["d"],lce=["d"],cce=["cx","cy"],dce=["x1","y1","x2","y2","stroke"],uce=["x1","y1","x2","y2","stroke"],ti=30,hce=$e({__name:"BlueprintArrow",props:{arrow:{},isSelected:{type:Boolean},isEngaged:{type:Boolean}},emits:["delete"],setup(e,{emit:t}){const a=t,n=e,r=H(()=>{const i=n.arrow.x2-n.arrow.x1,l=n.arrow.y2-n.arrow.y1;return[{x:n.arrow.x1,y:n.arrow.y1},{x:n.arrow.x1+ti,y:n.arrow.y1},{x:n.arrow.x1+ti,y:n.arrow.y1+l*.25},{x:n.arrow.x1+i*.5,y:n.arrow.y1+l*.5},{x:n.arrow.x2-ti,y:n.arrow.y1+l*.75},{x:n.arrow.x2-ti,y:n.arrow.y2},{x:n.arrow.x2,y:n.arrow.y2}]}),o=H(()=>{const i=n.arrow.x2-n.arrow.x1,l=r.value;let c;return i>ti?(c=`M ${l[0].x} ${l[0].y}`,c+=`C ${l[3].x} ${l[0].y}, ${l[3].x} ${l[6].y}, ${l[6].x} ${l[6].y}`):(c=`M ${l[0].x} ${l[0].y}`,c+=`C ${l[1].x} ${l[1].y}, ${l[2].x} ${l[2].y}, ${l[3].x} ${l[3].y}`,c+=`C ${l[4].x} ${l[4].y}, ${l[5].x} ${l[5].y}, ${l[6].x} ${l[6].y}`),c});function s(){a("delete")}return(i,l)=>($(),R("g",{class:ft(["BlueprintArrow",{engaged:i.isEngaged}]),tabindex:"0","data-writer-unselectable":"true"},[Z("path",{d:o.value,style:bt({stroke:i.arrow.color})},null,12,ice),Z("path",{d:o.value,style:bt({stroke:i.arrow.color,strokeWidth:12,opacity:i.isSelected?"0.2":"0"})},null,12,lce),i.isSelected?($(),R("g",{key:0,class:"delete",tabindex:"0","aria-label":"Delete relation",onClick:s,onKeydown:Sr(s,["enter"])},[Z("circle",{cx:r.value[3].x,cy:r.value[3].y,r:"12"},null,8,cce),Z("line",{class:"cross",x1:r.value[3].x-4,y1:r.value[3].y-4,x2:r.value[3].x+4,y2:r.value[3].y+4,stroke:i.arrow.color,"stroke-width":"2"},null,8,dce),Z("line",{class:"cross",x1:r.value[3].x+4,y1:r.value[3].y-4,x2:r.value[3].x-4,y2:r.value[3].y+4,stroke:i.arrow.color,"stroke-width":"2"},null,8,uce)],32)):ge("",!0)],2))}}),Vm=ke(hce,[["__scopeId","data-v-343694d1"]]),pce=$e({__name:"BlueprintMiniMap",props:{nodeContainerEl:{},renderOffset:{},zoomLevel:{}},emits:["changeRenderOffset"],setup(e,{emit:t}){ji(v=>({"5436111d":`${l.value.width}px`,"2f2ee374":`${l.value.height}px`,"791851f1":c.value.isDisplayed?"":"none"}));const a=re(ne.builderManager),n=pt("rootEl"),r=t,o=new ResizeObserver(f),s=new MutationObserver(f),i=ye(.2),l=ye({width:166,height:100}),c=ye({width:260,height:1,top:0,left:0,isDisplayed:!1}),d=ye({width:1,height:1,top:0,left:0}),u=e,h=ye([]);function f(){if(!u.nodeContainerEl)return;const v=Array.from(u.nodeContainerEl.querySelectorAll("[data-writer-id]")),y=u.nodeContainerEl.getBoundingClientRect();let M=0,x=0;h.value=v.map(S=>{const L=S.getBoundingClientRect();return M=Math.max(M,L.right+u.renderOffset.x*u.zoomLevel-y.left),x=Math.max(x,L.bottom+u.renderOffset.y*u.zoomLevel-y.top),{id:S.dataset.writerId,width:L.width,height:L.height,top:L.top+u.renderOffset.y*u.zoomLevel-y.top,left:L.left+u.renderOffset.x*u.zoomLevel-y.left}}),l.value={width:260,height:y.height/y.width*y.width/7},i.value=Math.min(l.value.width/(y.width+300),l.value.height/(y.height+300),l.value.width/(M+300),l.value.height/(x+300),l.value.width/(u.renderOffset.x*u.zoomLevel+y.width),l.value.height/(u.renderOffset.y*u.zoomLevel+y.height)),d.value={top:u.renderOffset.y*u.zoomLevel,left:u.renderOffset.x*u.zoomLevel,width:y.width,height:y.height},c.value={...d.value,isDisplayed:c.value.isDisplayed}}function m(v){const y=u.nodeContainerEl.getBoundingClientRect(),M=n.value.getBoundingClientRect();c.value={...c.value,top:Math.min(Math.max(0,(v.pageY-M.top)*(1/i.value)-y.height/2),M.height*(1/i.value)-y.height),left:Math.min(Math.max(0,(v.pageX-M.left)*(1/i.value)-y.width/2),M.width*(1/i.value)-y.width)}}function g(){c.value.isDisplayed=!0}function _(){c.value.isDisplayed=!1}function b(v){v.stopPropagation(),a.setSelection(null),r("changeRenderOffset",{x:c.value.left*(1/u.zoomLevel),y:c.value.top*(1/u.zoomLevel)})}return ia(async()=>{o.observe(u.nodeContainerEl),s.observe(u.nodeContainerEl,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["style"]}),await qa(),f()}),Wn(()=>{o.disconnect(),s.disconnect()}),(v,y)=>($(),R("div",{ref_key:"rootEl",ref:n,class:"BlueprintMiniMap",onMouseenter:g,onMouseleave:_,onMousemove:m,onClick:b},[Z("div",{class:"selectedArea",style:bt({top:`${d.value.top*i.value}px`,left:`${d.value.left*i.value}px`,width:`${d.value.width*i.value}px`,height:`${d.value.height*i.value}px`})},null,4),Z("div",{class:"selector",style:bt({top:`${c.value.top*i.value}px`,left:`${c.value.left*i.value}px`,width:`${c.value.width*i.value}px`,height:`${c.value.height*i.value}px`})},null,4),($(!0),R(Je,null,Ot(h.value,M=>($(),R("div",{key:M.id,class:ft(["node",{selected:E(a).isComponentIdSelected(M.id)}]),style:bt({top:`${M.top*i.value}px`,left:`${M.left*i.value}px`,width:`${M.width*i.value}px`,height:`${M.height*i.value}px`})},null,6))),128))],544))}}),fce=ke(pce,[["__scopeId","data-v-05861f5c"]]);function mce(){var t;return((t=navigator==null?void 0:navigator.userAgentData)==null?void 0:t.platform)||(navigator==null?void 0:navigator.platform)}function Wr(){return Vd()?"⌘ ":"Ctrl+"}function Fc(e){return Vd()?e.metaKey:e.ctrlKey}function Vd(){return mce().toLowerCase().indexOf("mac")!=-1}const vce={class:"bar"},gce={class:"autoArranger"},yce={class:"zoomer"},Mce={class:"miniMapCollapser"},Om=.01,P1=.2,_ce=$e({__name:"BlueprintNavigator",props:{nodeContainerEl:{},renderOffset:{},zoomLevel:{}},emits:["changeRenderOffset","changeZoomLevel","resetZoom","autoArrange"],setup(e,{emit:t}){const a=e,{zoomLevel:n}=a0(a),r=pt("rootEl"),o=t,s=ye(!0),i=ye(l(n.value));function l(v){return`${Math.floor(v*100)}%`}function c(){s.value=!s.value}function d(){o("autoArrange")}function u(v){o("changeRenderOffset",v)}function h(){const v=n.value+P1;o("changeZoomLevel",v)}function f(){const v=n.value-P1;o("changeZoomLevel",v)}function m(v){const y=v.key;let M=n.value;if(y=="ArrowUp")M+=Om;else if(y=="ArrowDown")M-=Om;else return;o("changeZoomLevel",M)}function g(v){var x;const y=(x=v.target)==null?void 0:x.value;let M=parseInt(y)/100;isNaN(M)&&(M=1),i.value=l(M),o("changeZoomLevel",M)}function _(){o("resetZoom")}We(n,v=>{i.value=l(v)});function b(v){if(Fc(v)===!1)return;let y=n.value;if(v.key=="+"||v.key=="=")v.preventDefault(),y+=P1;else if(v.key=="-")v.preventDefault(),y-=P1;else return;o("changeZoomLevel",y)}return ia(()=>{document.addEventListener("keydown",b)}),Wn(()=>{document.removeEventListener("keydown",b)}),(v,y)=>($(),R("div",{ref_key:"rootEl",ref:r,"data-writer-unselectable":"true",class:"BlueprintNavigator",onKeydown:b},[v.nodeContainerEl&&s.value?($(),Ie(fce,{key:0,"node-container-el":v.nodeContainerEl,"render-offset":v.renderOffset,"zoom-level":E(n),class:"miniMap",onChangeRenderOffset:u},null,8,["node-container-el","render-offset","zoom-level"])):ge("",!0),Z("div",vce,[Z("div",gce,[Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":"Auto arrange blocks","data-writer-tooltip-placement":"left",onClick:d},{default:Xe(()=>[Ce(_t,{name:"grid-3x3"})]),_:1})]),Z("div",yce,[Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":E(n)>E(bo).minLevel?`Zoom out (${E(Wr)()}-)`:"Can't zoom further","data-writer-tooltip-placement":"left",onClick:f},{default:Xe(()=>[Ce(_t,{name:"minus"})]),_:1},8,["data-writer-tooltip"]),Ce(fg,{modelValue:i.value,"onUpdate:modelValue":y[0]||(y[0]=M=>i.value=M),class:"zoomLevelInput",onKeydown:m,onChange:g},null,8,["modelValue"]),Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":E(n)<E(bo).maxLevel?`Zoom in (${E(Wr)()}+)`:"Can't zoom further","data-writer-tooltip-placement":"right",onClick:h},{default:Xe(()=>[Ce(_t,{name:"plus"})]),_:1},8,["data-writer-tooltip"]),Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":"Reset zoom","data-writer-tooltip-placement":"right",onClick:_},{default:Xe(()=>[Ce(_t,{name:"undo-2"})]),_:1})]),Z("div",Mce,[Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":s.value?"Close minimap":"Open minimap","data-writer-tooltip-placement":"right",onClick:c},{default:Xe(()=>[Ce(_t,{name:s.value?"minimize-2":"maximize-2"},null,8,["name"])]),_:1},8,["data-writer-tooltip"])])])],544))}}),bce=ke(_ce,[["__scopeId","data-v-ee6553db"]]),wce={},xce={width:"592",height:"592",viewBox:"0 0 592 592",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Cce(e,t){return $(),R("svg",xce,t[0]||(t[0]=[Z("g",null,[Z("g",{"clip-path":"url(#paint0_angular_167_137448_clip_path)"},[Z("g",{transform:"matrix(0.208791 0.208791 -0.208791 0.208791 296.078 296.082)"},[Z("foreignObject",{x:"-1003.39",y:"-1003.39",width:"2006.77",height:"2006.77"},[Z("div",{xmlns:"http://www.w3.org/1999/xhtml",style:{background:`conic-gradient(
8507
+ `.trim(),V2e="The root component of the application, which serves as the starting point of the component hierarchy.",O2e={writer:{name:"Root",category:"Root",description:V2e,allowedChildrenTypes:["page"],fields:{appName:{name:"App name",type:Q.Text,desc:"The app name will be shown in the browser's title bar."},cssClasses:mt,buttonColor:dr,buttonShadow:io,accentColor:Ia,contentPadding:Bs,primaryTextColor:ua,buttonTextColor:ur,emptinessColor:dg,containerShadow:Ns,secondaryTextColor:In,separatorColor:wa,contentVAlign:wd,contentHAlign:Ds,contentWidth:QE},events:{"wf-app-open":{desc:"Captures the first application load, including page key and route vars.",stub:L2e},"wf-hashchange":{desc:"Capture changes to the URL hash, including page key and route vars.",stub:P2e}}}},H2e=$e({...O2e,__name:"CoreRoot",setup(e){const t=re(ne.core),a=re(ne.builderManager),n=re(ne.getChildrenVNodes),r=pt("rootEl"),{isComponentVisible:o}=Kl(t),s=H(()=>{const c=t.activePageId.value;if(!!t.getComponentById(c)&&t.isChildOf("root",c))return c;const u=t.getComponents("root",{includeBMC:!0,includeCMC:!0,sortedByPosition:!0});if(u.length==0)return null;const h=u.filter(f=>o(f.id));return h.length==0?null:h[0].id});ia(()=>{s.value&&t.activePageId.value!==s.value&&t.setActivePageId(s.value)});function i(){var u;const c=I2e(),d=new CustomEvent("wf-hashchange",{detail:{payload:c}});(u=r.value)==null||u.dispatchEvent(d),c.pageKey&&t.setActivePageFromKey(c.pageKey)}We(s,c=>{var h;const u=(h=t.getComponentById(c).content)==null?void 0:h.key;a&&!a.isComponentIdSelected(c)&&a.setSelection(null),qa().then(()=>{var f,m;window.scrollTo(0,0),(m=(f=document.querySelector(".ComponentRenderer"))==null?void 0:f.parentElement)==null||m.scrollTo(0,0)}),T2e(u)});const l=Ki();return Ts(()=>{window.addEventListener("hashchange",()=>i(),{signal:l.signal}),i()}),(c,d)=>($(),R("div",{ref_key:"rootEl",ref:r,class:"CoreRoot","data-writer-container":""},[($(!0),R(Je,null,Ot(E(n)(),u=>($(),R(Je,{key:u.key},[u.key===`${s.value}:0`?($(),Ie(Ps(u),{key:0})):ge("",!0)],64))),128))],512))}}),R2e=ke(H2e,[["__scopeId","data-v-391634de"]]),N2e={key:0,class:"noAccessTokenProvided"},D2e=[{lat:37.79322359164316,lng:-122.39999318828129,name:"Marker"}],B2e={writer:{deprecated:!0,name:"Mapbox",description:"A component to embed a Mapbox map. It can be used to display a map with markers.",docs:"For this component you need Mapbox access token: https://www.mapbox.com/api-documentation/#access-tokens-and-token-scopes",category:"Embed",fields:{accessToken:{name:"Access Token",default:"",desc:"Access token from Mapbox",type:Q.Text},mapStyle:{name:"Map style",default:"mapbox://styles/mapbox/standard",type:Q.Text,desc:"Map style URL"},zoom:{name:"Zoom",default:"8",type:Q.Number},lat:{name:"Latitude",default:"37.79322359164316",type:Q.Number,validator:_d},lng:{name:"Longitude",default:"-122.39999318828129",type:Q.Number,validator:bd},markers:{name:"Markers",init:JSON.stringify(D2e,null,2),desc:"",type:Q.Object,validator:cg},controls:Ut({name:"Enable controls",default:"yes",desc:"Show map controls"}),cssClasses:mt},events:{"mapbox-marker-click":{desc:"Capture single clicks on markers.",eventPayloadExample:[{lat:1,lng:1,name:"Marker"}]},"mapbox-click":{desc:"Capture single click on map.",eventPayloadExample:{lat:1,lng:1}}}}},F2e=$e({...B2e,__name:"CoreMapbox",setup(e){const t=re(ne.evaluatedFields),a=pt("rootEl"),n=pt("mapEl"),r=H(()=>[t.lng.value,t.lat.value]),o=ye(null);let s=[],i=null;const l=async()=>{if(!n.value||!t.accessToken.value)return;const d=await zt(()=>import("./mapbox-gl-DBM-6gcD.js").then(u=>u.m),[],import.meta.url);try{d.accessToken=t.accessToken.value,d.default&&(d.default.accessToken=t.accessToken.value),o.value=new d.Map({container:n.value,style:t.mapStyle.value,center:r.value,zoom:t.zoom.value}),o.value.on("click",u=>{const h=new CustomEvent("mapbox-click",{detail:{payload:{lat:u.lngLat.lat,lng:u.lngLat.lng}}});a.value.dispatchEvent(h)}),i=new d.NavigationControl,t.controls.value&&o.value.addControl(i),t.markers.value&&o.value.on("load",c)}catch(u){fa().error(u)}},c=async()=>{var u,h;if(!o.value)return;const d=await zt(()=>import("./mapbox-gl-DBM-6gcD.js").then(f=>f.m),[],import.meta.url);s.forEach(f=>f.remove()),s=[],(h=(u=t.markers)==null?void 0:u.value)==null||h.forEach(f=>{const m=new d.Marker().setLngLat([f.lng,f.lat]).addTo(o.value).setPopup(new d.Popup().setText(f.name));s.push(m),m.getElement().addEventListener("click",g=>{const _=new CustomEvent("mapbox-marker-click",{detail:{payload:f}});a.value.dispatchEvent(_),g.stopPropagation()})})};return We(t.controls,()=>{o.value&&(t.controls?o.value.addControl(i):o.value.removeControl(i))}),We(t.markers,async()=>{o.value&&await c()}),We(t.mapStyle,()=>{o.value&&o.value.setStyle(t.mapStyle.value)}),We(r,()=>{var d,u;o.value&&((d=r.value)!=null&&d.lat)&&((u=r.value)!=null&&u.lng)&&o.value.setCenter(r.value)}),We(t.zoom,()=>{o.value&&t.zoom.value&&o.value.setZoom(t.zoom.value)}),We([n,t.accessToken],()=>{l()}),(d,u)=>($(),R("div",{ref_key:"rootEl",ref:a,class:"CoreMapbox"},[E(t).accessToken.value?($(),R("div",{key:1,ref_key:"mapEl",ref:n,class:"map"},null,512)):($(),R("div",N2e,u[0]||(u[0]=[Z("h2",null,"MapBox cannot be initialised.",-1),Z("h3",null,"An access token hasn't been provided.",-1)]))),u[1]||(u[1]=Z("div",{class:"mask"},null,-1))],512))}}),j2e=ke(F2e,[["__scopeId","data-v-4859a323"]]),Td=new Set(["root","blueprints_root"]),Pd=new Set(["page","blueprints_blueprint"]),Nde=new Set([...Td,...Pd]);function U2e(e,t){const{type:a}=e[t],o=Rd().map(i=>({type:i,definition:Vi(i)})).filter(i=>i.definition.allowedParentTypes&&!i.definition.allowedParentTypes.includes(a));return new Set(o.map(i=>i.type))}function z2e(e,t){const{type:a,parentId:n}=e[t],r=Rd().filter(l=>!Td.has(l)),{allowedChildrenTypes:o,toolkit:s}=Vi(a);if(!o)return new Set([]);let i=new Set(o);if(o.includes("*")&&(i=new Set([...i,...r])),i.delete("inherit")){if(!n)return i;const l=Ld(e,n);i=new Set([...i,...l])}return s&&(i=new Set(Array.from(i).filter(l=>Vi(l).toolkit==s))),i}function Ld(e,t){const a=Array.from(z2e(e,t)),n=Array.from(U2e(e,t));return a.filter(o=>!n.includes(o))}function q2e(e){return Pr(e)&&"type"in e&&e.type==="writer/clipboard"&&"components"in e&&Array.isArray(e.components)}function W2e(){const e=fa();async function t(){try{const n=await navigator.clipboard.readText(),r=JSON.parse(n);return q2e(r)?r.components:void 0}catch(n){if(n instanceof Error&&n.name==="NotAllowedError")throw Error("Please allow clipboard access in your browser settings or try again");return}}function a(n){const r={type:"writer/clipboard",components:n};try{navigator.clipboard.writeText(JSON.stringify(r))}catch(o){e.warn("Failed to write components in the clipboard",o)}}return{get:t,set:a}}function Z2e(e,t){let a=E(t);const n=new Set;for(;a&&!n.has(a);){n.add(a);const r=e.getComponentById(a);if(!r)return;if(Pd.has(r.type))return r;a=r.parentId}}const Yg="true";function Dde(e){var a;const t=(a=e==null?void 0:e.content)==null?void 0:a.isSharedBlueprint;return String(t)===Yg}function Fs(e,t,a){const n=W2e();function r(){let B="";const N=new Uint16Array(16);return window.crypto.getRandomValues(N),N.forEach(U=>{B+=(U%36).toString(36)}),B}function o(I){const B=e.getComponentById(I);if(!B||B.position==0||!e.getComponentById(B.parentId))return;const se=Me(I,-1),Se=`move-up-${I}`;t.openMutationTransaction(Se,"Move up"),t.registerPreMutation(se),se.position++,t.registerPostMutation(se),t.registerPreMutation(B),B.position--,t.registerPostMutation(B),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function s(I){const B=e.getComponentById(I);if(!B||!e.getComponentById(B.parentId)||B.position==-2)return;const se=Me(I,1);if(!se)return;const Se=`move-down-${I}`;t.openMutationTransaction(Se,"Move down"),t.registerPreMutation(se),se.position--,t.registerPostMutation(se),t.registerPreMutation(B),B.position++,t.registerPostMutation(B),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function i(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=e.getComponentById(U.parentId);if(!se||I==B||se.id==B&&N===null)return;const Se=`move-${I}`;t.openMutationTransaction(Se,"Move"),t.registerPreMutation(U),m(I,-1),U.position=N??xe(B,U.type),U.parentId=B,m(I,1),t.registerPostMutation(U),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function l(I,B){const N=e.getComponentById(I);if(!N)return!1;const U=e.getContainableTypes(I);return!(N!=null&&N.isCodeManaged)&&!e.isChildOf(B.id,I)&&U.includes(B.type)}function c(I){const B=e.getComponentById(I),N=Me(I,1);if(N&&l(N.id,B))return i(I,N.id),N.id}function d(I){const B=e.getComponentById(I),N=e.getComponentById(B.parentId).parentId;if(N&&l(N,B))return i(I,N,0),N}function u(I,B,N,U){const se=r(),Se=e.getComponentDefinition(I),{fields:Ne}=Se,ut={...(U==null?void 0:U.content)??{}};return Object.entries(Ne??{}).forEach(([Ee,Oe])=>{Ee in ut||(ut[Ee]=Oe.init)}),{...U??{},id:se,type:I,parentId:B,content:ut,handlers:{},position:N??xe(B,I)}}function h(I,B,N,U){const se=u(I,B,N,U);se.id=(U==null?void 0:U.id)??se.id;const Se=`create-${se.id}`;return t.openMutationTransaction(Se,"Create"),e.addComponent(se),m(se.id,1),t.registerPostMutation(se),t.closeMutationTransaction(Se),e.sendComponentUpdate(),a==null||a.track(I.startsWith("blueprints_")?"blueprints_block_added":"ui_block_added",{componentId:se.id}),se.id}function f(I,B){if(B.length===0)return[];const N=B.reduce((Se,{type:Ne,position:ut,initProperties:ie},Ee)=>{const Oe=Ee===0?I:Se.at(-1).id??I,Pe=u(Ne,Oe,ut,ie);return Pe.id=(ie==null?void 0:ie.id)??Pe.id,Se.push(Pe),Se},[]),U=N.map(Se=>Se.id),se=`create-${U.join("-")}`;t.openMutationTransaction(se,"Create");for(const Se of N)e.addComponent(Se),m(Se.id,1),t.registerPostMutation(Se),a==null||a.track(Se.type.startsWith("blueprints_")?"blueprints_block_added":"ui_block_added",{componentId:Se.id});return t.closeMutationTransaction(se),e.sendComponentUpdate(),U}function m(I,B){const N=e.getComponentById(I);if(e.getComponentDefinition(N.type).positionless)return;e.getComponents(N.parentId,{includeBMC:!0,includeCMC:!1}).filter(Ne=>Ne.id!==I).filter(Ne=>Ne.position>=N.position).map(Ne=>{t.registerPreMutation(Ne),Ne.position+=B,t.registerPostMutation(Ne)})}function g(I){const B=e.getComponentById(I),N=[],U=se=>{const Se=e.getComponents(se.id);N.push(se),Se.map(Ne=>U(Ne))};return U(B),N}function _(I){return e.getComponents().filter(B=>{var N;return(N=B.outs)==null?void 0:N.find(U=>U.toNodeId==I)})}function b(...I){const B=I.map(U=>e.getComponentById(U)).filter(Boolean);if(B.length===0)return;const N=`delete-${B.map(U=>U.id).join(",")}`;t.openMutationTransaction(N,"Delete");for(const U of B){U.parentId&&m(U.id,-1);const se=_(U.id);for(const Ne of se)t.registerPreMutation(Ne),Ne.outs=[...Ne.outs.filter(ut=>ut.toNodeId!==U.id)];a==null||a.track(U.type.startsWith("blueprints_")?"blueprints_block_deleted":"ui_block_deleted",{componentId:U.id});const Se=g(U.id);for(const Ne of Se)t.registerPreMutation(Ne),e.deleteComponent(Ne.id),t.removeSelectedComponentId(Ne.id)}for(const{pageType:U,rootId:se}of[{rootId:"root",pageType:"page"},{rootId:"blueprints_root",pageType:"blueprints_blueprint"}]){if(e.getComponents(se,{includeBMC:!0,includeCMC:!0}).length>0)continue;const Ne=u(U,se);e.addComponent(Ne),t.registerPostMutation(Ne),e.setActivePageId(Ne.id)}t.closeMutationTransaction(N),e.sendComponentUpdate()}function v(I){return b(I)}function y(I){return Td.has(I)}function M(I){const B=e.getComponentById(I);return!y(I)&&!(B!=null&&B.isCodeManaged)}function x(I){const B=e.getComponentById(I);return!(B!=null&&B.isCodeManaged)&&e.getContainableTypes(I).length>0}function S(I){return!y(I)}function L(I){const B=e.getComponentById(I);return!y(I)&&!(B!=null&&B.isCodeManaged)}function F(I){const B=e.getComponentById(I);return!y(I)&&!(B!=null&&B.isCodeManaged)}function te(I){return!y(I)}function J(I){return e.getComponents(I).length>0}function be(I){return!!Me(I,1)}function oe(I){return!!Me(I,-1)}function Te(I,B){const N=e.getComponentById(I);if(!N)return;const U=N.parentId;if(!U)return;let se;B&&(se=B.split(",").slice(0,-1).join(",")),t.setSelection(U,se)}function Ue(I){const B=e.getComponents(I).sort((N,U)=>N.position-U.position).at(0);B&&t.setSelection(B.id)}function Ze(I){const B=e.getComponentById(I);return B?(t.setSelection(B.id),!0):!1}function Me(I,B){if(y(I))return;const N=e.getComponentById(I);if(!N)return;const{parentId:U,position:se}=N,Se=se+B;return e.getComponents(U,{includeBMC:!0,includeCMC:!1}).find(Ne=>Ne.position===Se&&Ne.parentId===U)}function ee(I){var se,Se;if(y(I))return;const B=(se=e.getComponentById(I))==null?void 0:se.parentId;if(!B)return;const N=e.getComponents(B).sort((Ne,ut)=>Ne.position-ut.position),U=N.findIndex(Ne=>Ne.id===I);U===-1&&U+1===N.length||t.setSelection((Se=N[U+1])==null?void 0:Se.id)}function j(I){const B=Me(I,-1);B&&t.setSelection(B.id)}function K(I){if(I.length==0)return!1;const B={};return[...e.getComponents(),...I].forEach(U=>{B[U.id]=U}),I.map(U=>Ld(B,U.parentId).includes(U.type)).every(U=>U)}function G(I){const B=e.getComponentById(I);return!(!B||B.isCodeManaged)}function T(I){const B=ut=>e.getComponents(ut,{includeBMC:!0,includeCMC:!1}).filter(Oe=>{var Ke;return!((Ke=e.getComponentDefinition(Oe.type))==null?void 0:Ke.positionless)}).length,N=e.getComponentById(I);if(!N||N.isCodeManaged)return{up:!1,down:!1};if(e.getComponentDefinition(N.type).positionless)return{up:!1,down:!1};const se=N.parentId?B(N.parentId):0,Se=se>0&&N.position>0,Ne=se>0&&N.position<se-1;return{up:Se,down:Ne}}function O(I){if(!e.getComponentById(I))return;const N=g(I);n.set(N),t.setSelection(null),v(I),e.sendComponentUpdate()}function k(I){const B=JSON.parse(JSON.stringify(I));return B.forEach(N=>{delete N.isCodeManaged;const U=r();B.filter(se=>se.id!==N.id).map(se=>{var Se;se.parentId==N.id&&(se.parentId=U),(Se=se.outs)==null||Se.forEach(Ne=>{Ne.toNodeId==N.id&&(Ne.toNodeId=U)})}),N.id=U,typeof N.x<"u"&&typeof N.y<"u"&&(N.x+=36,N.y+=36)}),B}function C(I){if(!e.getComponentById(I))return;const N=g(I),U=k(N);n.set(U)}async function P(I){if(!e.getComponentById(I))return;const N=await n.get();if(!N)throw Error("The clipboard doesn't contain Writer data");if(!N.length)throw Error("The clipboard doesn't contain components");const U=N[0];return typeof U.outs<"u"&&U.parentId!==I&&(U.outs=[]),ae(I,N)}function ae(I,B){var se;n.set(k(B));const N=B[0];if(N.parentId=I,N.position=xe(I,N.type),!K(B)){const Se=(se=e.getComponentById(I))==null?void 0:se.parentId;if(Se)return ae(Se,B);throw Error("Could not paste the components here")}const U=`paste-copy-${I}`;t.openMutationTransaction(U,"Paste from copy"),B.map(Se=>{e.addComponent(Se),t.registerPostMutation(Se)}),t.closeMutationTransaction(U),e.sendComponentUpdate()}function xe(I,B){if(e.getComponentDefinition(B).positionless)return-2;const U=e.getComponents(I,{includeBMC:!0,includeCMC:!1}).filter(se=>se.position!==-2);return U.length>0?Math.max(Math.max(...U.map(Se=>Se.position))+1,0):0}function ve(){var B,N;const I=t.getMutationTransactionsSnapshot();return{isUndoAvailable:!!I.undo,isRedoAvailable:!!I.redo,undoDesc:(B=I.undo)==null?void 0:B.desc,redoDesc:(N=I.redo)==null?void 0:N.desc}}function ze(){const I=t.consumeUndoTransaction();I&&(Object.entries(I.mutations).forEach(([B,N])=>{if(N.jsonPre&&N.jsonPost){e.addComponent(JSON.parse(N.jsonPre));return}if(!N.jsonPre&&N.jsonPost){e.deleteComponent(B);return}if(N.jsonPre&&!N.jsonPost){e.addComponent(JSON.parse(N.jsonPre));return}}),e.sendComponentUpdate())}function Ye(){const I=t.consumeRedoTransaction();I&&(Object.entries(I.mutations).forEach(([B,N])=>{if(N.jsonPre&&N.jsonPost){e.addComponent(JSON.parse(N.jsonPost));return}if(!N.jsonPre&&N.jsonPost){e.addComponent(JSON.parse(N.jsonPost));return}if(N.jsonPre&&!N.jsonPost){e.deleteComponent(B);return}}),e.sendComponentUpdate())}function ct(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=`edit-${I}-content-${B}`;t.openMutationTransaction(se,"Edit property",!0),t.registerPreMutation(U),U.content[B]=N,t.registerPostMutation(U),t.closeMutationTransaction(se),e.sendComponentUpdate()}function xt(I,B){const N=e.getComponentById(I);if(!N)return;const U=`add-${I}-out-${B.outId}-${B.toNodeId}`;t.openMutationTransaction(U,"Add out",!0),t.registerPreMutation(N),N.outs=[...N.outs??[],B],t.registerPostMutation(N),t.closeMutationTransaction(U),e.sendComponentUpdate(),a==null||a.track("ui_blueprint_connected",{componentIds:[I,B.toNodeId],outId:B.outId})}function D(I,B){const N=e.getComponentById(I);if(!N)return;const U=`edit-${I}-out-${B.outId}-${B.toNodeId}`;t.openMutationTransaction(U,"Edit out",!0),t.registerPreMutation(N),N.outs=N.outs.filter(se=>!(B.outId===se.outId&&B.toNodeId===se.toNodeId)),t.registerPostMutation(N),t.closeMutationTransaction(U),e.sendComponentUpdate()}function q(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=`change-${I}-coordinates`;t.openMutationTransaction(se,"Change coordinates",!1),t.registerPreMutation(U),U.x=Math.floor(B),U.y=Math.floor(N),t.registerPostMutation(U),t.closeMutationTransaction(se),e.sendComponentUpdate()}function he(I){const B=Object.entries(I);if(B.length==0)return;const N=`change-multiple-coordinates-${Object.keys(I).join(",")}`;t.openMutationTransaction(N,"Change coordinates",!1),B.forEach(([U,{x:se,y:Se}])=>{const Ne=e.getComponentById(U);Ne&&(t.registerPreMutation(Ne),Ne.x=Math.floor(se),Ne.y=Math.floor(Se),t.registerPostMutation(Ne))}),t.closeMutationTransaction(N),e.sendComponentUpdate()}function me(I,B,N="",U=!1){const se=e.getComponentById(I);if(!se)return;const Se=`change-visibility-${I}`;t.openMutationTransaction(Se,"Change visibility",!0),t.registerPreMutation(se),se.visible==null&&(se.visible={expression:!0,binding:"",reversed:!1}),typeof B=="boolean"?se.visible.expression=B:B=="custom"&&(se.visible={expression:"custom",binding:N,reversed:U}),t.registerPostMutation(se),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function _e(I,B,N){const U=e.getComponentById(I);if(!U)return;let se;if(N)se=N;else{const Ne=e.getComponentDefinition(U.type),ie=Object.entries(Ne.events).filter(([Ee,Oe])=>Oe.bindable).map(([Ee,Oe])=>Ee);se=ie==null?void 0:ie[0]}if(!se)return;const Se=`change-binding-${I}`;t.openMutationTransaction(Se,"Change binding",!0),t.registerPreMutation(U),B?U.binding={eventType:se,stateRef:B}:delete U.binding,t.registerPostMutation(U),t.closeMutationTransaction(Se),e.sendComponentUpdate()}function Ae(I,B,N){const U=e.getComponentById(I);if(!U)return;const se=`set-handler-${I}`;t.openMutationTransaction(se,"Set event handler",!0),t.registerPreMutation(U),N?(U.handlers||(U.handlers={}),U.handlers[B]=N):(delete U.handlers[B],Object.keys(U.handlers).length==0&&delete U.handlers),t.registerPostMutation(U),t.closeMutationTransaction(se),e.sendComponentUpdate()}async function pe(I){var se;const B=e.getComponentById(I);if(!B||!((se=e.getComponentDefinition(B.type))==null?void 0:se.name))return;const U=Z2e(e,I);if(U){switch(U==null?void 0:U.type){case"page":t.mode.value="ui";break;case"blueprints_blueprint":t.mode.value="blueprints";break}return e.setActivePageId(U.id),U.id}}function ce(I){return g(I).slice(1).filter(N=>{var U;return N.type!=="note"&&((U=e.getComponentDefinition(N.type))==null?void 0:U.category)!=="Internal"})}function ue(I){const B=r(),N=u("blueprints_blueprint","blueprints_root",void 0,{content:{key:I.title,isSharedBlueprint:Yg,sourceBlueprintId:I.id,deployedDescription:I.description}});N.id=B;const U=k(I.components),se=new Set(U.map(Ne=>Ne.id));if(U.forEach(Ne=>{(!Ne.parentId||!se.has(Ne.parentId))&&(Ne.parentId=B)}),!K([N,...U]))throw Error("Cannot install blueprint: components are not compatible");const Se=`install-shared-blueprint-${B}`;return t.openMutationTransaction(Se,"Install shared blueprint"),e.addComponent(N),t.registerPostMutation(N),U.forEach(Ne=>{e.addComponent(Ne),t.registerPostMutation(Ne)}),t.closeMutationTransaction(Se),e.sendComponentUpdate(),a==null||a.track("blueprints_shared_installed",{blueprintId:I.id}),B}return{generateNewComponentId:r,moveComponent:i,moveComponentUp:o,moveComponentDown:s,cutComponent:O,copyComponent:C,pasteComponent:P,createAndInsertComponent:h,createAndInsertComponentsTree:f,removeComponentSubtree:v,removeComponentsSubtree:b,isPasteAllowed:G,undo:ze,redo:Ye,setContentValue:ct,addOut:xt,removeOut:D,changeCoordinates:q,changeCoordinatesMultiple:he,setVisibleValue:me,setBinding:_e,getUndoRedoSnapshot:ve,setHandlerValue:Ae,isAddAllowed:x,isCopyAllowed:S,isCutAllowed:L,isDeleteAllowed:F,isGoToParentAllowed:te,isGoToChildAllowed:J,isGoToNextSiblingAllowed:be,isGoToPrevSiblingAllowed:oe,repositionHigherSiblings:m,isDraggingAllowed:M,getEnabledMoves:T,goToParent:Te,goToChild:Ue,goToNextSibling:ee,goToPrevSibling:j,goToComponentParentPage:pe,moveComponentInsideNextSibling:c,moveComponentToParent:d,selectChild:Ze,extractBlueprintComponents:ce,installSharedBlueprint:ue}}const K2e=30,G2e=/^application\/json;writer=(?<componentType>\w+),(?<componentId>[\w\-]*)$/,ti=ye(null),vr=ye(null),I1=ye(!1);let ec=null,k1=null;function J2e(e){function t(_){const b=_.dataTransfer.types[0],v=b==null?void 0:b.match(G2e);if(!(v!=null&&v.groups))return;const{componentType:y,componentId:M}=v.groups;return{draggedType:y,draggedId:y==="blueprints_shared"?"":M,sourceBlueprintId:y==="blueprints_shared"?M:void 0}}function a(_){const y=(_.closest("[data-writer-cage]")??_).closest("[data-writer-id]");if(y)return y.dataset.writerId}function n(_){const b=t(_);if(!b)return;const{draggedType:v,draggedId:y}=b,M=a(_.target);if(!o(M,y,v))return;let S={};v==="blueprints_shared"&&b.sourceBlueprintId&&(S={sourceBlueprintId:b.sourceBlueprintId});const L={draggedType:v,draggedId:y,parentId:ti.value,position:k1,dragContent:S};return g(_),L}function r(_,b,v){const y=e.getComponentById(_);if(!y)return!1;const M=e.getContainableTypes(_);return!(y!=null&&y.isCodeManaged)&&!e.isChildOf(b,_)&&M.includes(v)}function o(_,b,v){const y=e.getComponentById(_);if(y)return r(_,b,v)?_:y.parentId?o(y.parentId,b,v):null}function s(_){if(I1.value){l(_);return}i(_)}function i(_){const b=t(_);if(!b)return;const{draggedType:v,draggedId:y}=b,M=_.target,x=a(M),S=o(x,y,v);if(!S||S==y)return;const F=M.closest(`[data-writer-id="${S}"]`).dataset.writerInstancePath;if(_.preventDefault(),vr.value!==F)ec=Date.now();else if(Date.now()-ec>=Ew){I1.value=!0,h(vr.value);return}ti.value=S,vr.value=F}function l(_){const b=t(_);if(!b)return;_.preventDefault();const v=document.querySelector(`[data-writer-instance-path="${vr.value}"]`);if(u(_.clientX,_.clientY,v)>K2e){g(_);return}const y=c(vr.value);if(y.length==0)return;const M=d(_.clientX,_.clientY,y);if(!M)return;const{el:x}=M,{draggedId:S}=b,L=parseInt(x.dataset.writerPosition),F=e.getComponentById(S);if(y.map(te=>{te.classList.contains("highlighted")&&te.classList.remove("highlighted")}),!x.classList.contains("highlighted")){if(x.classList.add("highlighted"),F&&F.parentId==ti.value&&L>F.position){k1=L-1;return}k1=L}}function c(_){const b=m(_);return Array.from(b.querySelectorAll("[data-writer-position]"))}function d(_,b,v){const y=v.map(M=>({el:M,distance:u(_,b,M)})).sort((M,x)=>M.distance>x.distance?1:-1);return y==null?void 0:y[0]}function u(_,b,v){const{top:y,left:M,right:x,bottom:S}=v.getBoundingClientRect(),L=Math.max(M-_,0,_-x),F=Math.max(y-b,0,b-S);return Math.sqrt(L*L+F*F)}function h(_){m(_).classList.add("crackedContainer")}function f(_){m(_).classList.remove("crackedContainer")}function m(_){const b=document.querySelector(`[data-writer-instance-path="${_}"]`);if(b.hasAttribute("data-writer-container"))return b;const v=b.querySelectorAll("[data-writer-container]");for(let y=0;y<v.length;y++){const M=v[y];if(M.closest("[data-writer-instance-path]")==b)return M}}function g(_){_.preventDefault(),vr.value&&(f(vr.value),vr.value=null),ti.value=null,ec=null,k1=null,I1.value=!1}return{candidateId:ti,candidateInstancePath:vr,isParentSuitable:r,isCandidacyConfirmed:I1,getComponentInfoFromDrag:t,dropComponent:n,assignInsertionCandidacy:s,removeInsertionCandidacy:g}}function tc(e,t){return Math.ceil(e/t)*t}function Em(e,t){return Math.round(e/t)*t}function Qg(e,t){return Math.hypot(t.x-e.x,t.y-e.y)}function Im({x:e,y:t},a){return{x:Em(e,a),y:Em(t,a)}}function Bc({x:e,y:t},{x:a,y:n}){return{x:e+a,y:t+n}}function km(e){return{x:e.x+e.width/2,y:e.y+e.height/2}}function T1(e,t,a){return e>=t&&e<=a}function Tm(e,t,a,n){return T1(e,a,n)||T1(t,a,n)||T1(a,e,t)||T1(n,e,t)}function X2e(e,t){const a=Tm(e.x,e.x+e.width,t.x,t.x+t.width),n=Tm(e.y,e.y+e.height,t.y,t.y+t.height);return a&&n}function Pm(e,t,a){const n=[{x:-a,y:-a},{x:-a,y:0},{x:-a,y:a},{x:0,y:-a},{x:0,y:a},{x:a,y:-a},{x:a,y:0},{x:a,y:a}],r=new Set,o=[],s=[];function i({x:f,y:m}){return{width:e.width,height:e.height,x:f,y:m}}function l(f){if(f.x<0||f.y<0)return!1;const m=i(f);return!t.some(g=>X2e(m,g))}function c(f){const m=`${f.x},${f.y}`;r.has(m)||(o.push(f),r.add(m))}for(c({x:e.x,y:e.y});o.length;){const f=o.shift();if(f===void 0)return;if(l(f)&&s.push(f),s.length===0)for(const m of n)c(Bc(f,m))}const d=km(e),u=f=>Qg(d,km(i(f))),h=s.sort((f,m)=>u(f)-u(m)).shift();return h?i(h):void 0}const Y2e="data:image/svg+xml,%3csvg%20width='29'%20height='33'%20viewBox='0%200%2029%2033'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109697)'%3e%3cpath%20d='M14.4995%200C22.2315%200%2028.4995%206.26801%2028.4995%2014C28.4995%2019.8214%2024.9459%2024.8114%2019.8901%2026.9229L14.4995%2032.3135L9.10791%2026.9229C4.05258%2024.8112%200.499512%2019.821%200.499512%2014C0.499512%206.26801%206.76753%200%2014.4995%200Z'%20fill='%23EDE2FF'/%3e%3cpath%20d='M15.1662%2011.3333H11.1662M17.8328%2014H11.1662M20.4995%2016C20.4995%2016.3536%2020.359%2016.6928%2020.109%2016.9428C19.8589%2017.1929%2019.5198%2017.3333%2019.1662%2017.3333H11.1662L8.49951%2020V9.33333C8.49951%208.97971%208.63999%208.64057%208.89004%208.39052C9.14008%208.14048%209.47922%208%209.83285%208H19.1662C19.5198%208%2019.8589%208.14048%2020.109%208.39052C20.359%208.64057%2020.4995%208.97971%2020.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_2417_109697'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(0.499512)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",Q2e="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109696)'%20filter='url(%23filter0_d_2417_109696)'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='%23D4B2F7'/%3e%3cpath%20d='M16.1662%2011.3333H12.1662M18.8328%2014H12.1662M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109696'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109696'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109696'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109696'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",ece="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109695)'%20filter='url(%23filter0_d_2417_109695)'%3e%3cmask%20id='path-1-inside-1_2417_109695'%20fill='white'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'/%3e%3c/mask%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='%23D4B2F7'/%3e%3cpath%20d='M20.8901%2026.9229L20.5048%2026.0001L20.3226%2026.0762L20.183%2026.2157L20.8901%2026.9229ZM15.4995%2032.3135L14.7925%2033.0206L15.4996%2033.7276L16.2066%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.815%2026.2157L10.6754%2026.0762L10.4933%2026.0001L10.1079%2026.9229ZM15.4995%200V1C22.6792%201%2028.4995%206.8203%2028.4995%2014H29.4995H30.4995C30.4995%205.71573%2023.7838%20-1%2015.4995%20-1V0ZM29.4995%2014H28.4995C28.4995%2019.4038%2025.2015%2024.0386%2020.5048%2026.0001L20.8901%2026.9229L21.2755%2027.8456C26.6903%2025.5843%2030.4995%2020.2389%2030.4995%2014H29.4995ZM20.8901%2026.9229L20.183%2026.2157L14.7924%2031.6064L15.4995%2032.3135L16.2066%2033.0206L21.5972%2027.63L20.8901%2026.9229ZM15.4995%2032.3135L16.2066%2031.6063L10.815%2026.2157L10.1079%2026.9229L9.40087%2027.63L14.7925%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.4933%2026.0001C5.79702%2024.0385%202.49951%2019.4035%202.49951%2014H1.49951H0.499512C0.499512%2020.2385%204.30814%2025.584%209.72248%2027.8456L10.1079%2026.9229ZM1.49951%2014H2.49951C2.49951%206.8203%208.31981%201%2015.4995%201V0V-1C7.21524%20-1%200.499512%205.71573%200.499512%2014H1.49951Z'%20fill='white'%20mask='url(%23path-1-inside-1_2417_109695)'/%3e%3cpath%20d='M16.1662%2011.3333H12.1662M18.8328%2014H12.1662M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109695'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109695'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109695'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109695'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",tce="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109694)'%20filter='url(%23filter0_d_2417_109694)'%3e%3cmask%20id='path-1-inside-1_2417_109694'%20fill='white'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'/%3e%3c/mask%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='%23D4B2F7'/%3e%3cpath%20d='M20.8901%2026.9229L20.5048%2026.0001L20.3226%2026.0762L20.183%2026.2157L20.8901%2026.9229ZM15.4995%2032.3135L14.7925%2033.0206L15.4996%2033.7276L16.2066%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.815%2026.2157L10.6754%2026.0762L10.4933%2026.0001L10.1079%2026.9229ZM15.4995%200V1C22.6792%201%2028.4995%206.8203%2028.4995%2014H29.4995H30.4995C30.4995%205.71573%2023.7838%20-1%2015.4995%20-1V0ZM29.4995%2014H28.4995C28.4995%2019.4038%2025.2015%2024.0386%2020.5048%2026.0001L20.8901%2026.9229L21.2755%2027.8456C26.6903%2025.5843%2030.4995%2020.2389%2030.4995%2014H29.4995ZM20.8901%2026.9229L20.183%2026.2157L14.7924%2031.6064L15.4995%2032.3135L16.2066%2033.0206L21.5972%2027.63L20.8901%2026.9229ZM15.4995%2032.3135L16.2066%2031.6063L10.815%2026.2157L10.1079%2026.9229L9.40087%2027.63L14.7925%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.4933%2026.0001C5.79702%2024.0385%202.49951%2019.4035%202.49951%2014H1.49951H0.499512C0.499512%2020.2385%204.30814%2025.584%209.72248%2027.8456L10.1079%2026.9229ZM1.49951%2014H2.49951C2.49951%206.8203%208.31981%201%2015.4995%201V0V-1C7.21524%20-1%200.499512%205.71573%200.499512%2014H1.49951Z'%20fill='white'%20mask='url(%23path-1-inside-1_2417_109694)'/%3e%3cpath%20d='M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='black'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109694'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109694'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109694'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109694'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",ace="data:image/svg+xml,%3csvg%20width='31'%20height='35'%20viewBox='0%200%2031%2035'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_2417_109693)'%20filter='url(%23filter0_d_2417_109693)'%3e%3cmask%20id='path-1-inside-1_2417_109693'%20fill='white'%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'/%3e%3c/mask%3e%3cpath%20d='M15.4995%200C23.2315%200%2029.4995%206.26801%2029.4995%2014C29.4995%2019.8214%2025.9459%2024.8114%2020.8901%2026.9229L15.4995%2032.3135L10.1079%2026.9229C5.05258%2024.8112%201.49951%2019.821%201.49951%2014C1.49951%206.26801%207.76753%200%2015.4995%200Z'%20fill='black'/%3e%3cpath%20d='M20.8901%2026.9229L20.5048%2026.0001L20.3226%2026.0762L20.183%2026.2157L20.8901%2026.9229ZM15.4995%2032.3135L14.7925%2033.0206L15.4996%2033.7276L16.2066%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.815%2026.2157L10.6754%2026.0762L10.4933%2026.0001L10.1079%2026.9229ZM15.4995%200V1C22.6792%201%2028.4995%206.8203%2028.4995%2014H29.4995H30.4995C30.4995%205.71573%2023.7838%20-1%2015.4995%20-1V0ZM29.4995%2014H28.4995C28.4995%2019.4038%2025.2015%2024.0386%2020.5048%2026.0001L20.8901%2026.9229L21.2755%2027.8456C26.6903%2025.5843%2030.4995%2020.2389%2030.4995%2014H29.4995ZM20.8901%2026.9229L20.183%2026.2157L14.7924%2031.6064L15.4995%2032.3135L16.2066%2033.0206L21.5972%2027.63L20.8901%2026.9229ZM15.4995%2032.3135L16.2066%2031.6063L10.815%2026.2157L10.1079%2026.9229L9.40087%2027.63L14.7925%2033.0206L15.4995%2032.3135ZM10.1079%2026.9229L10.4933%2026.0001C5.79702%2024.0385%202.49951%2019.4035%202.49951%2014H1.49951H0.499512C0.499512%2020.2385%204.30814%2025.584%209.72248%2027.8456L10.1079%2026.9229ZM1.49951%2014H2.49951C2.49951%206.8203%208.31981%201%2015.4995%201V0V-1C7.21524%20-1%200.499512%205.71573%200.499512%2014H1.49951Z'%20fill='white'%20mask='url(%23path-1-inside-1_2417_109693)'/%3e%3cpath%20d='M15.4995%2010.6667V14.6667M13.4995%2012.6667H17.4995M21.4995%2016C21.4995%2016.3536%2021.359%2016.6928%2021.109%2016.9428C20.8589%2017.1929%2020.5198%2017.3333%2020.1662%2017.3333H12.1662L9.49951%2020V9.33333C9.49951%208.97971%209.63999%208.64057%209.89004%208.39052C10.1401%208.14048%2010.4792%208%2010.8328%208H20.1662C20.5198%208%2020.8589%208.14048%2021.109%208.39052C21.359%208.64057%2021.4995%208.97971%2021.4995%209.33333V16Z'%20stroke='white'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3c/g%3e%3cdefs%3e%3cfilter%20id='filter0_d_2417_109693'%20x='0.499512'%20y='0'%20width='30'%20height='35'%20filterUnits='userSpaceOnUse'%20color-interpolation-filters='sRGB'%3e%3cfeFlood%20flood-opacity='0'%20result='BackgroundImageFix'/%3e%3cfeColorMatrix%20in='SourceAlpha'%20type='matrix'%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%20127%200'%20result='hardAlpha'/%3e%3cfeOffset%20dy='1'/%3e%3cfeGaussianBlur%20stdDeviation='0.5'/%3e%3cfeColorMatrix%20type='matrix'%20values='0%200%200%200%200.74902%200%200%200%200%200.796078%200%200%200%200%201%200%200%200%201%200'/%3e%3cfeBlend%20mode='multiply'%20in2='BackgroundImageFix'%20result='effect1_dropShadow_2417_109693'/%3e%3cfeBlend%20mode='normal'%20in='SourceGraphic'%20in2='effect1_dropShadow_2417_109693'%20result='shape'/%3e%3c/filter%3e%3cclipPath%20id='clip0_2417_109693'%3e%3crect%20width='28'%20height='33'%20fill='white'%20transform='translate(1.49951)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",nce=["src"],rce=$e({__name:"BaseNote",props:{componentId:{type:String,required:!0}},setup(e){const t=e,a=re(ne.core),n=re(ne.notesManager),r=H(()=>a.getComponentById(t.componentId)),{state:o}=n.useNoteInformation(r),s=H(()=>{switch(o.value){case"hover":return Q2e;case"active":return ece;case"new":return tce;case"cursor":return ace;default:return Y2e}});function i(){n.selectNote(t.componentId,"show")}return(l,c)=>($(),R("button",{type:"button",class:"BaseNote","data-writer-unselectable":"true",onMouseenter:c[0]||(c[0]=d=>E(n).hoveredNoteId.value=e.componentId),onMouseleave:c[1]||(c[1]=d=>E(n).hoveredNoteId.value=void 0),onClick:i},[Z("img",{src:s.value,width:"32",height:"32"},null,8,nce)],32))}}),oce=ke(rce,[["__scopeId","data-v-1f4e58ab"]]),Lm=5;function sce(e){const{wrapperRef:t,builderManager:a,isAnnotating:n}=e,r=$t({isSelecting:!1,startX:0,startY:0,left:0,top:0,width:0,height:0}),o=Ki(),s=H(()=>r.value.isSelecting),i=ye(!1),l=ye(!1);let c=null,d=null,u=null,h=null,f=null,m=null;function g(ee){if(a.mode.value==="preview"){i.value=!1;return}if(n.value){i.value=!1;return}if(ee.shiftKey||ee.ctrlKey||ee.metaKey){i.value=!1;return}if(a.mode.value==="blueprints"&&!ee.altKey){i.value=!1;return}if(!(ee.target instanceof Element)){i.value=!1;return}const j=ee.target,K=t.value;if(!K||!K.contains(j)){i.value=!1;return}if(j.closest("[data-writer-id]"))if(a.mode.value==="blueprints"){if(!b(j)){i.value=!1;return}}else{i.value=!1;return}if(!y(j)){i.value=!1;return}if(a.mode.value==="blueprints"&&!v(j)){i.value=!1;return}i.value=!0}function _(ee){return a.mode.value==="preview"||n.value?!1:a.mode.value==="blueprints"?!(!ee.altKey||ee.shiftKey||ee.ctrlKey||ee.metaKey):!(ee.shiftKey||ee.ctrlKey||ee.metaKey||ee.altKey)}function b(ee){const j=ee.closest("[data-writer-id]");if(!j)return!0;const K=ee.closest(".BlueprintsBlueprint");return K?j===K:!1}function v(ee){const j=ee.closest(".BlueprintsBlueprint");if(!j)return!1;const K=j.querySelector(".nodeContainer");return K?K.contains(ee):!1}function y(ee){return!(ee.closest("[data-writer-unselectable]")||ee.classList.contains("selectionRectangle"))}function M(ee,j){const K=ee.querySelectorAll("[data-writer-id]"),G=[];for(const T of Array.from(K)){if(T.closest("[data-writer-unselectable]"))continue;const O=T.getBoundingClientRect();if(O.left>=j.left&&O.right<=j.right&&O.top>=j.top&&O.bottom<=j.bottom){const C=T.dataset.writerId,P=T.dataset.writerInstancePath;C&&G.push({componentId:C,instancePath:P&&P.trim()?P:void 0})}}return G}function x(){r.value.isSelecting&&(c&&(c.abort(),c=null),d!==null&&(cancelAnimationFrame(d),d=null),u=null,h!==null&&(cancelAnimationFrame(h),h=null),f=null,m!==null&&(clearTimeout(m),m=null),r.value={...r.value,isSelecting:!1},document.body.style.userSelect="",document.body.style.cursor="")}function S(ee){const K=window.getComputedStyle(ee).transform;let G=1,T=1;if(K&&K!=="none"){const O=K.match(/matrix\(([^)]+)\)/);if(O){const k=O[1].split(",").map(C=>parseFloat(C.trim()));k.length>=4&&(G=k[0],T=k[3])}}return{scaleX:G,scaleY:T}}function L(ee,j){const K=ee.getBoundingClientRect(),{scaleX:G,scaleY:T}=S(ee);return{left:K.left+j.left*G,top:K.top+j.top*T,right:K.left+(j.left+j.width)*G,bottom:K.top+(j.top+j.height)*T}}function F(ee){if(!r.value.isSelecting||a.mode.value==="preview")return;const j=t.value;if(j)try{const K=j.getBoundingClientRect(),{scaleX:G,scaleY:T}=S(j),O=(ee.clientX-K.left)/G,k=(ee.clientY-K.top)/T+j.scrollTop,{startX:C,startY:P}=r.value,ae=Math.min(C,O),xe=Math.min(P,k)-j.scrollTop,ve=Math.abs(O-C),ze=Math.abs(k-P);r.value={...r.value,left:ae,top:xe,width:ve,height:ze}}catch{x()}}function te(ee){r.value.isSelecting&&a.mode.value!=="preview"&&(f=ee,h===null&&(h=requestAnimationFrame(()=>{f&&(F(f),f=null),h=null})))}function J(ee){r.value.isSelecting&&(te(ee),ee.preventDefault())}function be(ee){if(!_(ee)||!(ee.target instanceof Element))return;const j=ee.target;if(j.closest("[data-writer-id]"))if(a.mode.value==="blueprints"){if(!b(j))return}else return;if(!y(j))return;const G=t.value;if(!G||!G.contains(j))return;ee.stopPropagation(),ee.preventDefault();const T=G.getBoundingClientRect(),{scaleX:O,scaleY:k}=S(G),C=(ee.clientX-T.left)/O,P=(ee.clientY-T.top)/k+G.scrollTop;r.value={isSelecting:!0,startX:C,startY:P,left:C,top:P-G.scrollTop,width:0,height:0},document.body.style.userSelect="none",document.body.style.cursor="crosshair",c=new AbortController,G.addEventListener("mousemove",J,{signal:c.signal})}function oe(ee){if(r.value.isSelecting){a.mode.value==="blueprints"&&ee.stopPropagation(),te(ee),ee.preventDefault();return}u=ee,d===null&&(d=requestAnimationFrame(()=>{u&&(g(u),u=null),d=null}))}function Te(ee){if(!r.value.isSelecting)return;if(a.mode.value==="preview"){x();return}const{left:j,top:K,width:G,height:T}=r.value;if(G<Lm||T<Lm){x();return}ee.stopPropagation(),ee.preventDefault(),ee.stopImmediatePropagation();const O=t.value;if(!O){x();return}const k=L(O,{left:j,top:K,width:G,height:T}),C=M(O,k);if(C.length>0){const[P,...ae]=C;a.setSelection(P.componentId,P.instancePath,"click"),ae.forEach(({componentId:xe,instancePath:ve})=>{a.appendSelection(xe,ve,"click")}),l.value=!0,m&&clearTimeout(m),qa().then(()=>{requestAnimationFrame(()=>{l.value=!1,m=null})})}else a.setSelection(null);x()}function Ue(ee){if(r.value.isSelecting){const j=t.value;if(j&&ee.target instanceof Node&&j.contains(ee.target))return;x()}}function Ze(ee){l.value&&(ee.preventDefault(),ee.stopPropagation(),ee.stopImmediatePropagation())}Zn(()=>{m&&clearTimeout(m),o.abort(),x()});function Me(ee){i.value=!1}return{selectionRect:r,isCursorSelecting:s,isHoveringSelectableArea:i,justCompletedDragSelection:l,handleMousedown:be,handleMousemove:oe,handleMouseup:Te,handleMouseleave:Me,handleDocumentMouseup:Ue,handleDocumentClick:Ze}}const ice=["d"],lce=["d"],cce=["cx","cy"],dce=["x1","y1","x2","y2","stroke"],uce=["x1","y1","x2","y2","stroke"],ai=30,hce=$e({__name:"BlueprintArrow",props:{arrow:{},isSelected:{type:Boolean},isEngaged:{type:Boolean}},emits:["delete"],setup(e,{emit:t}){const a=t,n=e,r=H(()=>{const i=n.arrow.x2-n.arrow.x1,l=n.arrow.y2-n.arrow.y1;return[{x:n.arrow.x1,y:n.arrow.y1},{x:n.arrow.x1+ai,y:n.arrow.y1},{x:n.arrow.x1+ai,y:n.arrow.y1+l*.25},{x:n.arrow.x1+i*.5,y:n.arrow.y1+l*.5},{x:n.arrow.x2-ai,y:n.arrow.y1+l*.75},{x:n.arrow.x2-ai,y:n.arrow.y2},{x:n.arrow.x2,y:n.arrow.y2}]}),o=H(()=>{const i=n.arrow.x2-n.arrow.x1,l=r.value;let c;return i>ai?(c=`M ${l[0].x} ${l[0].y}`,c+=`C ${l[3].x} ${l[0].y}, ${l[3].x} ${l[6].y}, ${l[6].x} ${l[6].y}`):(c=`M ${l[0].x} ${l[0].y}`,c+=`C ${l[1].x} ${l[1].y}, ${l[2].x} ${l[2].y}, ${l[3].x} ${l[3].y}`,c+=`C ${l[4].x} ${l[4].y}, ${l[5].x} ${l[5].y}, ${l[6].x} ${l[6].y}`),c});function s(){a("delete")}return(i,l)=>($(),R("g",{class:ft(["BlueprintArrow",{engaged:i.isEngaged}]),tabindex:"0","data-writer-unselectable":"true"},[Z("path",{d:o.value,style:wt({stroke:i.arrow.color})},null,12,ice),Z("path",{d:o.value,style:wt({stroke:i.arrow.color,strokeWidth:12,opacity:i.isSelected?"0.2":"0"})},null,12,lce),i.isSelected?($(),R("g",{key:0,class:"delete",tabindex:"0","aria-label":"Delete relation",onClick:s,onKeydown:$r(s,["enter"])},[Z("circle",{cx:r.value[3].x,cy:r.value[3].y,r:"12"},null,8,cce),Z("line",{class:"cross",x1:r.value[3].x-4,y1:r.value[3].y-4,x2:r.value[3].x+4,y2:r.value[3].y+4,stroke:i.arrow.color,"stroke-width":"2"},null,8,dce),Z("line",{class:"cross",x1:r.value[3].x+4,y1:r.value[3].y-4,x2:r.value[3].x-4,y2:r.value[3].y+4,stroke:i.arrow.color,"stroke-width":"2"},null,8,uce)],32)):ge("",!0)],2))}}),Vm=ke(hce,[["__scopeId","data-v-343694d1"]]),pce=$e({__name:"BlueprintMiniMap",props:{nodeContainerEl:{},renderOffset:{},zoomLevel:{}},emits:["changeRenderOffset"],setup(e,{emit:t}){ji(v=>({"5436111d":`${l.value.width}px`,"2f2ee374":`${l.value.height}px`,"791851f1":c.value.isDisplayed?"":"none"}));const a=re(ne.builderManager),n=pt("rootEl"),r=t,o=new ResizeObserver(f),s=new MutationObserver(f),i=ye(.2),l=ye({width:166,height:100}),c=ye({width:260,height:1,top:0,left:0,isDisplayed:!1}),d=ye({width:1,height:1,top:0,left:0}),u=e,h=ye([]);function f(){if(!u.nodeContainerEl)return;const v=Array.from(u.nodeContainerEl.querySelectorAll("[data-writer-id]")),y=u.nodeContainerEl.getBoundingClientRect();let M=0,x=0;h.value=v.map(S=>{const L=S.getBoundingClientRect();return M=Math.max(M,L.right+u.renderOffset.x*u.zoomLevel-y.left),x=Math.max(x,L.bottom+u.renderOffset.y*u.zoomLevel-y.top),{id:S.dataset.writerId,width:L.width,height:L.height,top:L.top+u.renderOffset.y*u.zoomLevel-y.top,left:L.left+u.renderOffset.x*u.zoomLevel-y.left}}),l.value={width:260,height:y.height/y.width*y.width/7},i.value=Math.min(l.value.width/(y.width+300),l.value.height/(y.height+300),l.value.width/(M+300),l.value.height/(x+300),l.value.width/(u.renderOffset.x*u.zoomLevel+y.width),l.value.height/(u.renderOffset.y*u.zoomLevel+y.height)),d.value={top:u.renderOffset.y*u.zoomLevel,left:u.renderOffset.x*u.zoomLevel,width:y.width,height:y.height},c.value={...d.value,isDisplayed:c.value.isDisplayed}}function m(v){const y=u.nodeContainerEl.getBoundingClientRect(),M=n.value.getBoundingClientRect();c.value={...c.value,top:Math.min(Math.max(0,(v.pageY-M.top)*(1/i.value)-y.height/2),M.height*(1/i.value)-y.height),left:Math.min(Math.max(0,(v.pageX-M.left)*(1/i.value)-y.width/2),M.width*(1/i.value)-y.width)}}function g(){c.value.isDisplayed=!0}function _(){c.value.isDisplayed=!1}function b(v){v.stopPropagation(),a.setSelection(null),r("changeRenderOffset",{x:c.value.left*(1/u.zoomLevel),y:c.value.top*(1/u.zoomLevel)})}return ia(async()=>{o.observe(u.nodeContainerEl),s.observe(u.nodeContainerEl,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["style"]}),await qa(),f()}),Zn(()=>{o.disconnect(),s.disconnect()}),(v,y)=>($(),R("div",{ref_key:"rootEl",ref:n,class:"BlueprintMiniMap",onMouseenter:g,onMouseleave:_,onMousemove:m,onClick:b},[Z("div",{class:"selectedArea",style:wt({top:`${d.value.top*i.value}px`,left:`${d.value.left*i.value}px`,width:`${d.value.width*i.value}px`,height:`${d.value.height*i.value}px`})},null,4),Z("div",{class:"selector",style:wt({top:`${c.value.top*i.value}px`,left:`${c.value.left*i.value}px`,width:`${c.value.width*i.value}px`,height:`${c.value.height*i.value}px`})},null,4),($(!0),R(Je,null,Ot(h.value,M=>($(),R("div",{key:M.id,class:ft(["node",{selected:E(a).isComponentIdSelected(M.id)}]),style:wt({top:`${M.top*i.value}px`,left:`${M.left*i.value}px`,width:`${M.width*i.value}px`,height:`${M.height*i.value}px`})},null,6))),128))],544))}}),fce=ke(pce,[["__scopeId","data-v-05861f5c"]]);function mce(){var t;return((t=navigator==null?void 0:navigator.userAgentData)==null?void 0:t.platform)||(navigator==null?void 0:navigator.platform)}function Zr(){return Vd()?"⌘ ":"Ctrl+"}function Fc(e){return Vd()?e.metaKey:e.ctrlKey}function Vd(){return mce().toLowerCase().indexOf("mac")!=-1}const vce={class:"bar"},gce={class:"autoArranger"},yce={class:"zoomer"},Mce={class:"miniMapCollapser"},Om=.01,P1=.2,_ce=$e({__name:"BlueprintNavigator",props:{nodeContainerEl:{},renderOffset:{},zoomLevel:{}},emits:["changeRenderOffset","changeZoomLevel","resetZoom","autoArrange"],setup(e,{emit:t}){const a=e,{zoomLevel:n}=a0(a),r=pt("rootEl"),o=t,s=ye(!0),i=ye(l(n.value));function l(v){return`${Math.floor(v*100)}%`}function c(){s.value=!s.value}function d(){o("autoArrange")}function u(v){o("changeRenderOffset",v)}function h(){const v=n.value+P1;o("changeZoomLevel",v)}function f(){const v=n.value-P1;o("changeZoomLevel",v)}function m(v){const y=v.key;let M=n.value;if(y=="ArrowUp")M+=Om;else if(y=="ArrowDown")M-=Om;else return;o("changeZoomLevel",M)}function g(v){var x;const y=(x=v.target)==null?void 0:x.value;let M=parseInt(y)/100;isNaN(M)&&(M=1),i.value=l(M),o("changeZoomLevel",M)}function _(){o("resetZoom")}We(n,v=>{i.value=l(v)});function b(v){if(Fc(v)===!1)return;let y=n.value;if(v.key=="+"||v.key=="=")v.preventDefault(),y+=P1;else if(v.key=="-")v.preventDefault(),y-=P1;else return;o("changeZoomLevel",y)}return ia(()=>{document.addEventListener("keydown",b)}),Zn(()=>{document.removeEventListener("keydown",b)}),(v,y)=>($(),R("div",{ref_key:"rootEl",ref:r,"data-writer-unselectable":"true",class:"BlueprintNavigator",onKeydown:b},[v.nodeContainerEl&&s.value?($(),Ie(fce,{key:0,"node-container-el":v.nodeContainerEl,"render-offset":v.renderOffset,"zoom-level":E(n),class:"miniMap",onChangeRenderOffset:u},null,8,["node-container-el","render-offset","zoom-level"])):ge("",!0),Z("div",vce,[Z("div",gce,[Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":"Auto arrange blocks","data-writer-tooltip-placement":"left",onClick:d},{default:Xe(()=>[Ce(bt,{name:"grid-3x3"})]),_:1})]),Z("div",yce,[Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":E(n)>E(xo).minLevel?`Zoom out (${E(Zr)()}-)`:"Can't zoom further","data-writer-tooltip-placement":"left",onClick:f},{default:Xe(()=>[Ce(bt,{name:"minus"})]),_:1},8,["data-writer-tooltip"]),Ce(fg,{modelValue:i.value,"onUpdate:modelValue":y[0]||(y[0]=M=>i.value=M),class:"zoomLevelInput",onKeydown:m,onChange:g},null,8,["modelValue"]),Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":E(n)<E(xo).maxLevel?`Zoom in (${E(Zr)()}+)`:"Can't zoom further","data-writer-tooltip-placement":"right",onClick:h},{default:Xe(()=>[Ce(bt,{name:"plus"})]),_:1},8,["data-writer-tooltip"]),Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":"Reset zoom","data-writer-tooltip-placement":"right",onClick:_},{default:Xe(()=>[Ce(bt,{name:"undo-2"})]),_:1})]),Z("div",Mce,[Ce(La,{variant:"neutral",size:"smallIcon","data-writer-tooltip":s.value?"Close minimap":"Open minimap","data-writer-tooltip-placement":"right",onClick:c},{default:Xe(()=>[Ce(bt,{name:s.value?"minimize-2":"maximize-2"},null,8,["name"])]),_:1},8,["data-writer-tooltip"])])])],544))}}),bce=ke(_ce,[["__scopeId","data-v-ee6553db"]]),wce={},xce={width:"592",height:"592",viewBox:"0 0 592 592",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function Cce(e,t){return $(),R("svg",xce,t[0]||(t[0]=[Z("g",null,[Z("g",{"clip-path":"url(#paint0_angular_167_137448_clip_path)"},[Z("g",{transform:"matrix(0.208791 0.208791 -0.208791 0.208791 296.078 296.082)"},[Z("foreignObject",{x:"-1003.39",y:"-1003.39",width:"2006.77",height:"2006.77"},[Z("div",{xmlns:"http://www.w3.org/1999/xhtml",style:{background:`conic-gradient(
8508
8508
  from 90deg,
8509
8509
  rgba(240, 207, 255, 1) 0deg,
8510
8510
  rgba(191, 203, 255, 1) 360deg
8511
- )`,height:"100%",width:"100%",opacity:"1"}})])])]),Z("ellipse",{cx:"296.078",cy:"296.082",rx:"295.275",ry:"295.275",transform:"rotate(-45 296.078 296.082)"})],-1),Z("defs",null,[Z("clipPath",{id:"paint0_angular_167_137448_clip_path"},[Z("ellipse",{cx:"296.078",cy:"296.082",rx:"295.275",ry:"295.275",transform:"rotate(-45 296.078 296.082)"})])],-1)]))}const ac=ke(wce,[["render",Cce]]),Ace={class:"BlueprintsAutogenContents"},Sce={class:"BlueprintsAutogenContents__contents"},$ce=$e({__name:"BlueprintsAutogenContents",props:{isBusy:{type:Boolean,required:!0}},setup(e){return(t,a)=>($(),R("div",Ace,[Z("div",Sce,[qt(t.$slots,"default",{},void 0,!0)]),Z("div",{class:ft(["BlueprintsAutogenContents__background",{busy:e.isBusy}])},[Ce(ac,{class:"rotating-circle left"}),Ce(ac,{class:"rotating-circle center"}),Ce(ac,{class:"rotating-circle right"})],2)]))}}),Ece=ke($ce,[["__scopeId","data-v-6ed2673c"]]),Ice="data:image/svg+xml,%3csvg%20width='48'%20height='48'%20viewBox='0%200%2048%2048'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20width='48'%20height='48'%20rx='24'%20fill='black'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M34.0187%2028.9434L37.2255%2015.7128H32.7659L30.812%2015.7128L34.0187%2028.9434Z'%20fill='white'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M25.4266%2015.7128H20.967L25.4266%2034.1126L27.4085%2034.1126H31.8681L27.4085%2015.7128H25.4266L25.4266%2015.7128Z'%20fill='white'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M17.5635%2015.7129H13.1038L13.1039%2015.7132H11.1219L15.5816%2034.113H20.0413L20.0412%2034.1126H22.0231L17.5635%2015.7129Z'%20fill='white'/%3e%3c/svg%3e",kce={class:"BlueprintsGenerationLoader"},Tce={class:"rotating-text"},Pce=4e3,Lce=$e({__name:"BlueprintsGenerationLoader",setup(e){const t=["Analyzing requirements","Shopping for blocks","Connecting the dots","Wiring the circuits","Flipping the switches"],a=ye(0),n=setInterval(()=>{a.value=(a.value+1)%t.length},Pce);return Wn(()=>clearInterval(n)),(r,o)=>($(),R("div",kce,[o[0]||(o[0]=Z("img",{src:Ice,alt:"Writer Framework logo",width:"72px",height:"72px"},null,-1)),Ce(Ad,{class:"dot-loader",color:"black"}),Z("p",Tce,[($(),R(Je,null,Ot(t,(s,i)=>Z("span",{key:i,class:ft({active:a.value===i})},je(s),3)),64))])]))}}),Vce=ke(Lce,[["__scopeId","data-v-78564a74"]]),gr=$t([]);function Od(){const e={};function t(r){const o=gr.value.findIndex(s=>s.id===r);o!==-1&&(gr.value=gr.value.filter((s,i)=>o!==i))}function a(r){e[r.id]&&(clearTimeout(e[r.id]),delete e[r.id]),!r.closable&&r.delayMs!==1/0&&(e[r.id]=setTimeout(()=>t(r.id),r.delayMs??3e3))}function n(r){if("id"in r&&gr.value.some(i=>i.id===r.id))return gr.value=gr.value.map(i=>i.id===r.id?r:i),a(r),r.id;const o="id"in r?r.id:new Date().getTime(),s={...r,id:o};return gr.value=[...gr.value,s],a(s),o}return{pushToast:n,removeToast:t,toasts:jt(gr)}}var Oce={BASE_URL:"./",MODE:"production",DEV:!1,PROD:!0,SSR:!1},wo,Ca,ra,xo,si,Co,ii;class Hce{constructor(t){Yo(this,xo);Yo(this,Co);Yo(this,wo,void 0);Yo(this,Ca,void 0);Yo(this,ra,void 0);s1(this,wo,t==null?void 0:t.signal),s1(this,Ca,(t==null?void 0:t.baseUrl)??window.location.origin),s1(this,ra,{signal:xt(this,wo),credentials:"include",headers:{"Content-Type":"application/json","X-Client":"Framework"}})}async fetchApplicationDeployment(t,a){const n=new URL(`/api/template/organization/${t}/application/${a}/deployment`,xt(this,Ca)),r=await fetch(n,xt(this,ra));if(!r.ok)throw Error(await r.text());return r.json()}async fetchOrganizationUsers(t,a={}){const n=new URL(`/api/user/v2/organization/${t}`,xt(this,Ca)),r=new URLSearchParams;for(const[s,i]of Object.entries(a))r.append(s,String(i));const o=await fetch(`${n}?${r.toString()}`,xt(this,ra));if(!o.ok)throw Error(await o.text());return o.json()}async publishApplication(t,a,n){const r=new URL(`/api/template/organization/${t}/application/${a}/publish`,xt(this,Ca)),o=await fetch(r,{...xt(this,ra),method:"PUT",body:JSON.stringify(n)});if(!o.ok)throw Error(await o.text());return o.json()}async updateApplicationMetadata(t,a,n){const r=new URL(`/api/template/organization/${t}/application/${a}/metadata`,xt(this,Ca)),o=await fetch(r,{...xt(this,ra),method:"PUT",body:JSON.stringify(n)});if(!o.ok)throw Error(await o.text());return o.json()}async fetchUserProfile(){const t=new URL("/api/user/v2/profile",xt(this,Ca)),a=await fetch(t,xt(this,ra));if(!a.ok)throw Error(await a.text());return a.json()}async fetchUserById(t){const a=new URL(`/api/user/v2/user/${t}`,xt(this,Ca)),n=await fetch(a,xt(this,ra));if(!n.ok)throw Error(await n.text());return n.json()}async analyticsIdentify(){const t=new URL("/api/analytics/identify",xt(this,Ca)),a=await fetch(t,{...xt(this,ra),method:"POST",body:JSON.stringify({traits:{}})});if(!a.ok)throw Error(await a.text())}async analyticsTrack(t,a){const n=new URL("/api/analytics/track",xt(this,Ca)),r=await fetch(n,{...xt(this,ra),method:"POST",body:JSON.stringify({eventName:t,properties:a})});if(!r.ok)throw Error(await r.text())}async analyticsPage(t,a,n){const r=new URL("/api/analytics/page",xt(this,Ca)),o=await fetch(r,{method:"POST",body:JSON.stringify({name:t,organizationId:a,properties:n}),signal:xt(this,wo),credentials:"include"});if(!o.ok)throw Error(await o.text())}async fetchThirdUserProfile(t){const a=new URL(`/api/user/v2/user/${t}`,xt(this,Ca)),n=await fetch(a,xt(this,ra));if(!n.ok)throw Error(await n.text());return n.json()}async createSecret(t,a,n,r){const o=await fetch(fr(this,xo,si).call(this,t,a),{...xt(this,ra),method:"POST",body:JSON.stringify({key:n,secret:r})});if(!o.ok)throw Error(await o.text());return o.json()}async fetchSecret(t,a,n){const r=await fetch(fr(this,xo,si).call(this,t,a,n),xt(this,ra));if(!r.ok)throw Error(await r.text());return r.json()}async deleteSecret(t,a,n){const r=await fetch(fr(this,xo,si).call(this,t,a,n),{...xt(this,ra),method:"DELETE"});if(!r.ok)throw Error(await r.text());return r.json()}async updateSecret(t,a,n,r){const o=await fetch(fr(this,xo,si).call(this,t,a,n),{...xt(this,ra),method:"PUT",body:JSON.stringify({key:n,secret:r})});if(!o.ok)throw Error(await o.text());return o.json()}async fetchMcpConnectedApps(t,a){const n=new URL(`/api/mcp-gateway/v2/organization/${t}/app-configurations`,xt(this,Ca)),r=new URLSearchParams({limit:"100"}),o={...xt(this,ra).headers};a&&(o["X-Agent-Id"]=a);const s=`${n}?${r.toString()}`,i=await fetch(s,{...xt(this,ra),headers:o});if(!i.ok){const c=await i.text();throw Error(c)}return(await i.json()).result||[]}async fetchMcpAppFunctions(t,a){const n=new URL(`/api/mcp-gateway/v1/functions/list/${t}`,xt(this,Ca)),r={...xt(this,ra).headers};a&&(r["X-Agent-Id"]=a);const o=await fetch(n,{...xt(this,ra),headers:r});if(!o.ok){const s=await o.text();throw Error(s)}return await o.json()}async fetchMcpTools(t,a){var o,s;const n=await this.fetchMcpConnectedApps(t,a),r=[];for(const i of n){const l=i.appId;if(l)try{const c=await this.fetchMcpAppFunctions(l,a),d=i.allFunctionsEnabled??!0,u=i.enabledFunctions||[];let h;d?h=c:u.length>0?h=c.filter(m=>m.name&&u.includes(m.name)):h=[];const f=((o=i.connector)==null?void 0:o.displayName)||((s=i.connector)==null?void 0:s.name)||i.name||"";for(const m of h)r.push({appId:l,appName:f,functionName:m.name||"",function:m,connector:i.connector?{logo:i.connector.logo}:void 0})}catch(c){fa().error("Error fetching MCP app functions:",c)}}return r}async fetchConfigJs(){const t=new URL("/env/config.js",xt(this,Ca)),a=await fetch(t,{signal:xt(this,wo),credentials:"include",headers:{"X-Client":"Framework"},...xt(this,ra)});if(!a.ok){const n=await a.text();throw Error(n)}return a.text()}async publishSharedBlueprint(t,a){const n=fr(this,Co,ii).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints`,n),o=await fetch(r,{...xt(this,ra),method:"POST",body:JSON.stringify({title:a.title,description:a.description,components:a.components,metadata:a.metadata,existing_snippet_id:a.existingSnippetId||null})});if(!o.ok)throw Error(await o.text());return o.json()}async listSharedBlueprints(t,a){const n=fr(this,Co,ii).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints`,n);a&&r.searchParams.append("search",a);const o=await fetch(r,xt(this,ra));if(!o.ok)throw Error(await o.text());return o.json()}async getSharedBlueprint(t,a){const n=fr(this,Co,ii).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints/${a}`,n),o=await fetch(r,xt(this,ra));if(!o.ok)throw Error(await o.text());return o.json()}async deleteSharedBlueprint(t,a){const n=fr(this,Co,ii).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints/${a}`,n),o=await fetch(r,{...xt(this,ra),method:"DELETE"});if(!o.ok)throw Error(await o.text())}}wo=new WeakMap,Ca=new WeakMap,ra=new WeakMap,xo=new WeakSet,si=function(t,a,n){const r=new URL(`/api/template/organization/${t}/agent/${a}/secret`,xt(this,Ca));return n?`${r}/${n}`:r},Co=new WeakSet,ii=function(){return Oce.VITE_AGENT_STORAGE_URL||xt(this,Ca)};var Rce={BASE_URL:"./",MODE:"production",DEV:!1,PROD:!0,SSR:!1};function io(e={}){const t=Rce.VITE_WRITER_BASE_URL??window.location.origin;return{writerApi:new Hce({...e,baseUrl:t}),apiBaseUrl:t}}let nc=!1;const Hm="[AgentEditor]";function Hd(e){const t=new AbortController,a=fa(),{writerApi:n}=io({signal:t.signal}),r=e.isWriterCloudApp;if(!nc){const f=We(r,async()=>{if(!(nc||!r.value)){nc=!0;try{const m=n.fetchUserProfile();await Promise.allSettled([n.analyticsIdentify(),o(m),s(m)])}catch(m){a.error("Failed to identify the current user for analytics",m)}finally{f()}}},{immediate:!0})}async function o(f=n.fetchUserProfile()){if(e.mode.value==="run")return;const m=await zt(()=>import("./index-DHZHZi5W.js").then(_=>_.i),[],import.meta.url);m.init("S6dr31v4MO4wuteztVhxysLkoA9HsZ6HnDaOTDLqNXHYZq-1P02ek-E3BR4Zgv4pMwdoYO",{fastUrl:"https://fast.chameleon.io/"});const g=await f;m.identify(`segment-prefix-${g.id}`,{email:g==null?void 0:g.email,name:(g==null?void 0:g.fullName)??`${g==null?void 0:g.firstName} ${g.lastName}`})}async function s(f=n.fetchUserProfile()){if(!r.value)return;const m=await zt(()=>import("./index.esm-B1ZQtduY.js"),[],import.meta.url);if(!m.isInitialized()){m.init({orgId:"o-2316W7-na1",devMode:!1});try{const g=await f;await m.FullStory("setIdentityAsync",{uid:`segment-prefix-${g.id}`,properties:g,consent:!0})}catch(g){a.error("Failed to set FullStory identity",g)}}}async function i(f,m){if(!r.value)return;const{FullStory:g}=await zt(()=>import("./index.esm-B1ZQtduY.js"),[],import.meta.url);return g("trackEventAsync",{name:f,properties:m})}function l(f,m){if(r.value)return n.analyticsTrack(f,m)}function c(f){const m=e.getComponentById(f);if(!m)return{};const g=e.getComponentDefinition(m.type);return g?{name:g.name,category:g.category}:{}}function d(f){const m=structuredClone(f);return typeof m.componentId=="string"&&(m.component=c(m.componentId),delete m.componentId),Array.isArray(m.componentIds)&&(m.components=m.componentIds.map(c),delete m.componentIds),{writerApplicationId:e.writerAppId.value,writerOrganizationId:String(e.writerOrgId.value),...m}}async function u(f,m={}){if(!r.value)return;const g=`${Hm} ${f}`,_=d(m);return a.log("[tracking]",g,_),await Promise.all([l(g,_),i(g,_)]).catch(a.error)}function h(f,m={}){if(r.value&&e.writerOrgId.value)return n.analyticsPage(`${Hm} ${f}`,e.writerOrgId.value,d(m))}return{track:u,page:h}}function Li(e,t=window.location.toString()){return new URL(`.${e}`,t).toString()}function Bde(e){return e.startsWith("/")?Li(e):e}const Nce={class:"BlueprintsAutogen"},Dce={class:"BlueprintsAutogen__panel"},Bce={class:"BlueprintsAutogen__error"},Fce={class:"BlueprintsAutogen__buttons"},jce=$e({__name:"BlueprintsAutogen",emits:["blockGeneration"],setup(e,{emit:t}){const a=re(ne.core),n=re(ne.builderManager),{generateNewComponentId:r}=Bs(a,n),o=Hd(a),{pushToast:s}=Od(),i=ye(!1),l=ye(""),c=ye(null);let d=null;const u=t;function h(){d&&d.abort(),u("blockGeneration",null)}ia(()=>{o.track("blueprints_auto_gen_opened")});function f(_){const b={};return _.forEach(v=>{const y=r();b[v.id]=y,v.id=y}),_.forEach(v=>{var y;(y=v.outs)==null||y.forEach(M=>{M.toNodeId=b[M.toNodeId]})}),_.forEach(v=>{Object.entries(b).forEach(([y,M])=>{const x=new RegExp(`(@{\\s*results\\.)aig${y}\\b`,"g");Object.entries(v.content).forEach(([S,L])=>{const F=L.replace(x,(te,J)=>te.replace(J,M));v.content[S]=F})})}),_}async function m(){var b;const _=l.value;if(!_){c.value="Please add instructions to create your blueprint.";return}i.value=!0,c.value=null,d&&d.abort(),d=new AbortController,o.track("blueprints_auto_gen_started",{prompt:l.value});try{const v=await fetch(Li("/api/autogen"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({description:_}),signal:d.signal});if(!v.ok){c.value="Agent failed to generate. Try again.";return}const y=await v.json(),M=f((b=y.blueprint)==null?void 0:b.components);u("blockGeneration",{components:M}),s({type:"success",message:"Blueprint generated"})}catch(v){v.name!=="AbortError"&&(c.value="Agent failed to generate. Try again.");return}finally{i.value=!1,d=null}o.track("blueprints_auto_gen_completed")}function g(){d&&d.abort(),i.value=!1}return(_,b)=>($(),R("div",Nce,[Z("h2",null,je(i.value?"Generating agent":"What would you like this agent to do?"),1),Ce(Ece,{"is-busy":i.value,class:ft({busy:i.value})},{default:Xe(()=>[i.value?($(),Ie(Vce,{key:1})):($(),R("div",{key:0,class:ft(["BlueprintsAutogen__main",{error:c.value}])},[Ce(_0,{modelValue:l.value,"onUpdate:modelValue":b[0]||(b[0]=v=>l.value=v),rows:"10",placeholder:`Describe a workflow
8511
+ )`,height:"100%",width:"100%",opacity:"1"}})])])]),Z("ellipse",{cx:"296.078",cy:"296.082",rx:"295.275",ry:"295.275",transform:"rotate(-45 296.078 296.082)"})],-1),Z("defs",null,[Z("clipPath",{id:"paint0_angular_167_137448_clip_path"},[Z("ellipse",{cx:"296.078",cy:"296.082",rx:"295.275",ry:"295.275",transform:"rotate(-45 296.078 296.082)"})])],-1)]))}const ac=ke(wce,[["render",Cce]]),Ace={class:"BlueprintsAutogenContents"},Sce={class:"BlueprintsAutogenContents__contents"},$ce=$e({__name:"BlueprintsAutogenContents",props:{isBusy:{type:Boolean,required:!0}},setup(e){return(t,a)=>($(),R("div",Ace,[Z("div",Sce,[qt(t.$slots,"default",{},void 0,!0)]),Z("div",{class:ft(["BlueprintsAutogenContents__background",{busy:e.isBusy}])},[Ce(ac,{class:"rotating-circle left"}),Ce(ac,{class:"rotating-circle center"}),Ce(ac,{class:"rotating-circle right"})],2)]))}}),Ece=ke($ce,[["__scopeId","data-v-6ed2673c"]]),Ice="data:image/svg+xml,%3csvg%20width='48'%20height='48'%20viewBox='0%200%2048%2048'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20width='48'%20height='48'%20rx='24'%20fill='black'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M34.0187%2028.9434L37.2255%2015.7128H32.7659L30.812%2015.7128L34.0187%2028.9434Z'%20fill='white'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M25.4266%2015.7128H20.967L25.4266%2034.1126L27.4085%2034.1126H31.8681L27.4085%2015.7128H25.4266L25.4266%2015.7128Z'%20fill='white'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M17.5635%2015.7129H13.1038L13.1039%2015.7132H11.1219L15.5816%2034.113H20.0413L20.0412%2034.1126H22.0231L17.5635%2015.7129Z'%20fill='white'/%3e%3c/svg%3e",kce={class:"BlueprintsGenerationLoader"},Tce={class:"rotating-text"},Pce=4e3,Lce=$e({__name:"BlueprintsGenerationLoader",setup(e){const t=["Analyzing requirements","Shopping for blocks","Connecting the dots","Wiring the circuits","Flipping the switches"],a=ye(0),n=setInterval(()=>{a.value=(a.value+1)%t.length},Pce);return Zn(()=>clearInterval(n)),(r,o)=>($(),R("div",kce,[o[0]||(o[0]=Z("img",{src:Ice,alt:"Writer Framework logo",width:"72px",height:"72px"},null,-1)),Ce(Ad,{class:"dot-loader",color:"black"}),Z("p",Tce,[($(),R(Je,null,Ot(t,(s,i)=>Z("span",{key:i,class:ft({active:a.value===i})},je(s),3)),64))])]))}}),Vce=ke(Lce,[["__scopeId","data-v-78564a74"]]),gr=$t([]);function Od(){const e={};function t(r){const o=gr.value.findIndex(s=>s.id===r);o!==-1&&(gr.value=gr.value.filter((s,i)=>o!==i))}function a(r){e[r.id]&&(clearTimeout(e[r.id]),delete e[r.id]),!r.closable&&r.delayMs!==1/0&&(e[r.id]=setTimeout(()=>t(r.id),r.delayMs??3e3))}function n(r){if("id"in r&&gr.value.some(i=>i.id===r.id))return gr.value=gr.value.map(i=>i.id===r.id?r:i),a(r),r.id;const o="id"in r?r.id:new Date().getTime(),s={...r,id:o};return gr.value=[...gr.value,s],a(s),o}return{pushToast:n,removeToast:t,toasts:jt(gr)}}var Oce={BASE_URL:"./",MODE:"production",DEV:!1,PROD:!0,SSR:!1},Co,Ca,ea,Ao,ii,Mr,Mo;class Hce{constructor(t){Qo(this,Ao);Qo(this,Mr);Qo(this,Co,void 0);Qo(this,Ca,void 0);Qo(this,ea,void 0);s1(this,Co,t==null?void 0:t.signal),s1(this,Ca,(t==null?void 0:t.baseUrl)??window.location.origin),s1(this,ea,{signal:Mt(this,Co),credentials:"include",headers:{"Content-Type":"application/json","X-Client":"Framework"}})}async fetchApplicationDeployment(t,a){const n=new URL(`/api/template/organization/${t}/application/${a}/deployment`,Mt(this,Ca)),r=await fetch(n,Mt(this,ea));if(!r.ok)throw Error(await r.text());return r.json()}async fetchOrganizationUsers(t,a={}){const n=new URL(`/api/user/v2/organization/${t}`,Mt(this,Ca)),r=new URLSearchParams;for(const[s,i]of Object.entries(a))r.append(s,String(i));const o=await fetch(`${n}?${r.toString()}`,Mt(this,ea));if(!o.ok)throw Error(await o.text());return o.json()}async publishApplication(t,a,n){const r=new URL(`/api/template/organization/${t}/application/${a}/publish`,Mt(this,Ca)),o=await fetch(r,{...Mt(this,ea),method:"PUT",body:JSON.stringify(n)});if(!o.ok)throw Error(await o.text());return o.json()}async updateApplicationMetadata(t,a,n){const r=new URL(`/api/template/organization/${t}/application/${a}/metadata`,Mt(this,Ca)),o=await fetch(r,{...Mt(this,ea),method:"PUT",body:JSON.stringify(n)});if(!o.ok)throw Error(await o.text());return o.json()}async fetchUserProfile(){const t=new URL("/api/user/v2/profile",Mt(this,Ca)),a=await fetch(t,Mt(this,ea));if(!a.ok)throw Error(await a.text());return a.json()}async fetchUserById(t){const a=new URL(`/api/user/v2/user/${t}`,Mt(this,Ca)),n=await fetch(a,Mt(this,ea));if(!n.ok)throw Error(await n.text());return n.json()}async analyticsIdentify(){const t=new URL("/api/analytics/identify",Mt(this,Ca)),a=await fetch(t,{...Mt(this,ea),method:"POST",body:JSON.stringify({traits:{}})});if(!a.ok)throw Error(await a.text())}async analyticsTrack(t,a){const n=new URL("/api/analytics/track",Mt(this,Ca)),r=await fetch(n,{...Mt(this,ea),method:"POST",body:JSON.stringify({eventName:t,properties:a})});if(!r.ok)throw Error(await r.text())}async analyticsPage(t,a,n){const r=new URL("/api/analytics/page",Mt(this,Ca)),o=await fetch(r,{method:"POST",body:JSON.stringify({name:t,organizationId:a,properties:n}),signal:Mt(this,Co),credentials:"include"});if(!o.ok)throw Error(await o.text())}async fetchThirdUserProfile(t){const a=new URL(`/api/user/v2/user/${t}`,Mt(this,Ca)),n=await fetch(a,Mt(this,ea));if(!n.ok)throw Error(await n.text());return n.json()}async createSecret(t,a,n,r){const o=await fetch(Vn(this,Ao,ii).call(this,t,a),{...Mt(this,ea),method:"POST",body:JSON.stringify({key:n,secret:r})});if(!o.ok)throw Error(await o.text());return o.json()}async fetchSecret(t,a,n){const r=await fetch(Vn(this,Ao,ii).call(this,t,a,n),Mt(this,ea));if(!r.ok)throw Error(await r.text());return r.json()}async deleteSecret(t,a,n){const r=await fetch(Vn(this,Ao,ii).call(this,t,a,n),{...Mt(this,ea),method:"DELETE"});if(!r.ok)throw Error(await r.text());return r.json()}async updateSecret(t,a,n,r){const o=await fetch(Vn(this,Ao,ii).call(this,t,a,n),{...Mt(this,ea),method:"PUT",body:JSON.stringify({key:n,secret:r})});if(!o.ok)throw Error(await o.text());return o.json()}async fetchMcpConnectedApps(t,a){const n=new URL(`/api/mcp-gateway/v2/organization/${t}/app-configurations`,Mt(this,Ca)),r=new URLSearchParams({limit:"100"}),o={...Mt(this,ea).headers};a&&(o["X-Agent-Id"]=a);const s=`${n}?${r.toString()}`,i=await fetch(s,{...Mt(this,ea),headers:o});if(!i.ok){const c=await i.text();throw Error(c)}return(await i.json()).result||[]}async fetchMcpAppFunctions(t,a){const n=new URL(`/api/mcp-gateway/v1/functions/list/${t}`,Mt(this,Ca)),r={...Mt(this,ea).headers};a&&(r["X-Agent-Id"]=a);const o=await fetch(n,{...Mt(this,ea),headers:r});if(!o.ok){const s=await o.text();throw Error(s)}return await o.json()}async fetchMcpTools(t,a){var o,s;const n=await this.fetchMcpConnectedApps(t,a),r=[];for(const i of n){const l=i.appId;if(l)try{const c=await this.fetchMcpAppFunctions(l,a),d=i.allFunctionsEnabled??!0,u=i.enabledFunctions||[];let h;d?h=c:u.length>0?h=c.filter(m=>m.name&&u.includes(m.name)):h=[];const f=((o=i.connector)==null?void 0:o.displayName)||((s=i.connector)==null?void 0:s.name)||i.name||"";for(const m of h)r.push({appId:l,appName:f,functionName:m.name||"",function:m,connector:i.connector?{logo:i.connector.logo}:void 0})}catch(c){fa().error("Error fetching MCP app functions:",c)}}return r}async fetchConfigJs(){const t=new URL("/env/config.js",Mt(this,Ca)),a=await fetch(t,{signal:Mt(this,Co),credentials:"include",headers:{"X-Client":"Framework"},...Mt(this,ea)});if(!a.ok){const n=await a.text();throw Error(n)}return a.text()}async publishSharedBlueprint(t,a){const n=Vn(this,Mr,Mo).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints`,n),o=await fetch(r,{...Mt(this,ea),method:"POST",body:JSON.stringify({title:a.title,description:a.description,components:a.components,metadata:a.metadata})});if(!o.ok)throw Error(await o.text());return o.json()}async listSharedBlueprints(t,a){const n=Vn(this,Mr,Mo).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints`,n);a&&r.searchParams.append("search",a);const o=await fetch(r,Mt(this,ea));if(!o.ok)throw Error(await o.text());return o.json()}async getSharedBlueprint(t,a){const n=Vn(this,Mr,Mo).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints/${a}`,n),o=await fetch(r,Mt(this,ea));if(!o.ok)throw Error(await o.text());return o.json()}async deleteSharedBlueprint(t,a){const n=Vn(this,Mr,Mo).call(this),r=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints/${a}`,n),o=await fetch(r,{...Mt(this,ea),method:"DELETE"});if(!o.ok)throw Error(await o.text())}async trackBlueprintInstallation(t,a,n){const r=Vn(this,Mr,Mo).call(this),o=new URL(`/api/agent-storage/v1/organization/${t}/shared-blueprints/installations`,r),s=await fetch(o,{...Mt(this,ea),method:"POST",body:JSON.stringify({blueprint_id:a,app_id:n})});if(!s.ok)throw Error(await s.text());return s.json()}async proposeSharedBlueprintGlobal(t){const a=Vn(this,Mr,Mo).call(this),n=new URL("/api/agent-storage/v1/shared-blueprints",a),r=await fetch(n,{...Mt(this,ea),method:"POST",body:JSON.stringify({title:t.title,description:t.description,components:t.components,metadata:t.metadata})});if(!r.ok)throw Error(await r.text());return r.json()}}Co=new WeakMap,Ca=new WeakMap,ea=new WeakMap,Ao=new WeakSet,ii=function(t,a,n){const r=new URL(`/api/template/organization/${t}/agent/${a}/secret`,Mt(this,Ca));return n?`${r}/${n}`:r},Mr=new WeakSet,Mo=function(){return Oce.VITE_AGENT_STORAGE_URL||Mt(this,Ca)};var Rce={BASE_URL:"./",MODE:"production",DEV:!1,PROD:!0,SSR:!1};function lo(e={}){const t=Rce.VITE_WRITER_BASE_URL??window.location.origin;return{writerApi:new Hce({...e,baseUrl:t}),apiBaseUrl:t}}let nc=!1;const Hm="[AgentEditor]";function Hd(e){const t=new AbortController,a=fa(),{writerApi:n}=lo({signal:t.signal}),r=e.isWriterCloudApp;if(!nc){const f=We(r,async()=>{if(!(nc||!r.value)){nc=!0;try{const m=n.fetchUserProfile();await Promise.allSettled([n.analyticsIdentify(),o(m),s(m)])}catch(m){a.error("Failed to identify the current user for analytics",m)}finally{f()}}},{immediate:!0})}async function o(f=n.fetchUserProfile()){if(e.mode.value==="run")return;const m=await zt(()=>import("./index-CStxQ_Zn.js").then(_=>_.i),[],import.meta.url);m.init("S6dr31v4MO4wuteztVhxysLkoA9HsZ6HnDaOTDLqNXHYZq-1P02ek-E3BR4Zgv4pMwdoYO",{fastUrl:"https://fast.chameleon.io/"});const g=await f;m.identify(`segment-prefix-${g.id}`,{email:g==null?void 0:g.email,name:(g==null?void 0:g.fullName)??`${g==null?void 0:g.firstName} ${g.lastName}`})}async function s(f=n.fetchUserProfile()){if(!r.value)return;const m=await zt(()=>import("./index.esm-B1ZQtduY.js"),[],import.meta.url);if(!m.isInitialized()){m.init({orgId:"o-2316W7-na1",devMode:!1});try{const g=await f;await m.FullStory("setIdentityAsync",{uid:`segment-prefix-${g.id}`,properties:g,consent:!0})}catch(g){a.error("Failed to set FullStory identity",g)}}}async function i(f,m){if(!r.value)return;const{FullStory:g}=await zt(()=>import("./index.esm-B1ZQtduY.js"),[],import.meta.url);return g("trackEventAsync",{name:f,properties:m})}function l(f,m){if(r.value)return n.analyticsTrack(f,m)}function c(f){const m=e.getComponentById(f);if(!m)return{};const g=e.getComponentDefinition(m.type);return g?{name:g.name,category:g.category}:{}}function d(f){const m=structuredClone(f);return typeof m.componentId=="string"&&(m.component=c(m.componentId),delete m.componentId),Array.isArray(m.componentIds)&&(m.components=m.componentIds.map(c),delete m.componentIds),{writerApplicationId:e.writerAppId.value,writerOrganizationId:String(e.writerOrgId.value),...m}}async function u(f,m={}){if(!r.value)return;const g=`${Hm} ${f}`,_=d(m);return a.log("[tracking]",g,_),await Promise.all([l(g,_),i(g,_)]).catch(a.error)}function h(f,m={}){if(r.value&&e.writerOrgId.value)return n.analyticsPage(`${Hm} ${f}`,e.writerOrgId.value,d(m))}return{track:u,page:h}}function Li(e,t=window.location.toString()){return new URL(`.${e}`,t).toString()}function Bde(e){return e.startsWith("/")?Li(e):e}const Nce={class:"BlueprintsAutogen"},Dce={class:"BlueprintsAutogen__panel"},Bce={class:"BlueprintsAutogen__error"},Fce={class:"BlueprintsAutogen__buttons"},jce=$e({__name:"BlueprintsAutogen",emits:["blockGeneration"],setup(e,{emit:t}){const a=re(ne.core),n=re(ne.builderManager),{generateNewComponentId:r}=Fs(a,n),o=Hd(a),{pushToast:s}=Od(),i=ye(!1),l=ye(""),c=ye(null);let d=null;const u=t;function h(){d&&d.abort(),u("blockGeneration",null)}ia(()=>{o.track("blueprints_auto_gen_opened")});function f(_){const b={};return _.forEach(v=>{const y=r();b[v.id]=y,v.id=y}),_.forEach(v=>{var y;(y=v.outs)==null||y.forEach(M=>{M.toNodeId=b[M.toNodeId]})}),_.forEach(v=>{Object.entries(b).forEach(([y,M])=>{const x=new RegExp(`(@{\\s*results\\.)aig${y}\\b`,"g");Object.entries(v.content).forEach(([S,L])=>{const F=L.replace(x,(te,J)=>te.replace(J,M));v.content[S]=F})})}),_}async function m(){var b;const _=l.value;if(!_){c.value="Please add instructions to create your blueprint.";return}i.value=!0,c.value=null,d&&d.abort(),d=new AbortController,o.track("blueprints_auto_gen_started",{prompt:l.value});try{const v=await fetch(Li("/api/autogen"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({description:_}),signal:d.signal});if(!v.ok){c.value="Agent failed to generate. Try again.";return}const y=await v.json(),M=f((b=y.blueprint)==null?void 0:b.components);u("blockGeneration",{components:M}),s({type:"success",message:"Blueprint generated"})}catch(v){v.name!=="AbortError"&&(c.value="Agent failed to generate. Try again.");return}finally{i.value=!1,d=null}o.track("blueprints_auto_gen_completed")}function g(){d&&d.abort(),i.value=!1}return(_,b)=>($(),R("div",Nce,[Z("h2",null,je(i.value?"Generating agent":"What would you like this agent to do?"),1),Ce(Ece,{"is-busy":i.value,class:ft({busy:i.value})},{default:Xe(()=>[i.value?($(),Ie(Vce,{key:1})):($(),R("div",{key:0,class:ft(["BlueprintsAutogen__main",{error:c.value}])},[Ce(_0,{modelValue:l.value,"onUpdate:modelValue":b[0]||(b[0]=v=>l.value=v),rows:"10",placeholder:`Describe a workflow
8512
8512
 
8513
8513
  example:
8514
8514
  - Connect to Google Keyword Planner and get the best keywords for my site www.writer.com
8515
8515
  - Get an article from Wordpress using the API
8516
- - Draft a new article with updates based on the target keywords`,style:{height:"100%"}},null,8,["modelValue"])],2))]),_:1},8,["is-busy","class"]),Z("div",Dce,[Z("p",Bce,je(c.value),1),Z("div",Fce,[i.value?($(),Ie(La,{key:0,variant:"tertiary",onClick:g},{default:Xe(()=>b[1]||(b[1]=[pa(" Back ")])),_:1})):ge("",!0),Ce(La,{variant:"tertiary",onClick:h},{default:Xe(()=>b[2]||(b[2]=[pa(" Skip ")])),_:1}),Ce(La,{variant:"secondary",disabled:i.value,onClick:m},{default:Xe(()=>[Ce(_t,{name:"sparkles"}),pa(" "+je(i.value?"Autogenerating...":"Autogenerate agent"),1)]),_:1},8,["disabled"])])])]))}}),Uce=ke(jce,[["__scopeId","data-v-50d9936c"]]),zce=["data-writer-unselectable"],qce={class:"BlueprintsBlueprint__svg"},Wce=["x","y"],Zce=["cx","cy","fill"],Kce={key:0,width:"100%",height:"100%",fill:"url(#grid)",fil:""},{log:Gce}=fa(),xa=24,Jce="A container component representing a single blueprint within the application.",Xce={writer:{name:"Blueprint",toolkit:"blueprints",category:"Root",description:Jce,allowedChildrenTypes:["*"],allowedParentTypes:["blueprints_root"],fields:{key:{name:"Blueprint key",desc:"Unique identifier. It's needed to enable navigation to this Blueprint.",type:Q.IdKey,validator:WE}}}},bo={minLevel:.2,maxLevel:1,step:.25,initialLevel:1},Yce=$e({...Xce,__name:"BlueprintsBlueprint",setup(e){ji(fe=>({"3cf15168":J.value}));const t=sr({loader:()=>zt(()=>import("./BlueprintToolbar-CSKyGsgb.js"),__vite__mapDeps([11,12,13]),import.meta.url),loadingComponentProps:{width:"250px",height:"40px"}}),a=sr({loader:()=>zt(()=>import("./BuilderSettingsDeploySharedBlueprint-Ct5FVU3z.js"),__vite__mapDeps([14,15,16,17]),import.meta.url)}),n=re(ne.core),r=re(ne.builderManager),o=re(ne.notesManager),s=re(ne.renderProxiedComponent),i=re(ne.componentId),l=re(ne.isAutogenModalShown,ye(!1));function c(){l.value=!0}const d=ye(!1),u=pt("rootEl"),h=pt("nodeContainerEl"),{selectionRect:f,isCursorSelecting:m,isHoveringSelectableArea:g,justCompletedDragSelection:_,handleMousedown:b,handleMousemove:v,handleMouseup:y,handleMouseleave:M,handleDocumentMouseup:x,handleDocumentClick:S}=sce({wrapperRef:h,builderManager:r,isAnnotating:o.isAnnotating}),L=$t([]),F=$t({x:0,y:0}),te=$t(null),J=ye(bo.initialLevel),be=new MutationObserver(ve),oe=$t({}),Te=xa*4,Ue=xa*6,Ze=H(()=>n.getComponents(i,{sortedByPosition:!0}).filter(fe=>fe.type!=="note")),Me=H(()=>Array.from(o.getNotes(i))),ee=Hd(n),{createAndInsertComponent:j,addOut:K,removeOut:G,changeCoordinatesMultiple:T}=Bs(n,r,ee),{getComponentInfoFromDrag:O}=J2e(n),k=$t(null),C=$t(null),P=$t(null),ae=xe();function xe(){const fe="blueprint__hideGrid",Le=ye(localStorage.getItem(fe)===null);return We(Le,Re=>Re?localStorage.removeItem(fe):localStorage.setItem(fe,"1")),Le}function ve(){L.value=Ze.value.reduce((fe,Le)=>{var Re;if(!((Re=Le.outs)!=null&&Re.length))return fe;for(const Ve of Le.outs){const Ge=N(Le.id,Ve.outId,void 0,Ve.toNodeId);Ge&&fe.push(Ge)}return fe},[])}const ze=H(()=>{var fe,Le;return k.value===null&&!((fe=C.value)!=null&&fe.isPerfected)&&!((Le=P.value)!=null&&Le.isPerfected)?null:!0});function Ye(fe){if(_.value){fe.preventDefault(),fe.stopPropagation();return}if(te.value=null,fe.target instanceof Element&&!fe.target.closest("[data-writer-unselectable]")&&o.isAnnotating.value){const{x:Le,y:Re}=ce(fe);o.createNote(i,{x:Le,y:Re})}}function ct(){const fe=new Map;function Le(Ve,Ge){var Mt;if(fe.values().find(At=>At.has(Ve)))return;fe.has(Ge)||fe.set(Ge,new Set),fe.get(Ge).add(Ve),(Mt=Ve.outs)==null||Mt.forEach(At=>{const Yt=n.getComponentById(At.toNodeId);Le(Yt,Ge+1)})}const Re=new Map;return Ze.value.forEach(Ve=>{var Ge;(Ge=Ve.outs)==null||Ge.forEach(dt=>{Re.has(dt.toNodeId)||Re.set(dt.toNodeId,new Set),Re.get(dt.toNodeId).add(Ve.id)})}),Ze.value.filter(Ve=>!Re.has(Ve.id)).forEach(Ve=>{Le(Ve,0)}),fe}function wt(fe){const Le=`[data-writer-id="${fe}"]`,Re=h.value.querySelector(Le);if(Re)return Re.getBoundingClientRect()}function D(fe){var Ge;const Le=wt(fe);if(!Le)return;const Re=(Ge=u.value)==null?void 0:Ge.getBoundingClientRect();if(!Re)return;const Ve=dt=>{const rt=tc(dt,xa);return rt===dt?rt+1:rt-1};return{x:F.value.x+(Le.x-Re.x)*pe.value,y:F.value.y+(Le.y-Re.y)*pe.value,width:Ve(Le.width*pe.value),height:Ve(Le.height*pe.value)}}function q(fe){const Le=new Map,Re=new Map;return fe.forEach((Ve,Ge)=>{let dt=0,rt=0;Ve.forEach(Mt=>{const At=wt(Mt.id);At&&(Re.set(Mt.id,{height:At.height*pe.value}),dt+=At.height*pe.value+Te,rt=Math.max(rt,At.width*pe.value))}),Le.set(Ge,{height:dt-Te,width:rt})}),{columnDimensions:Le,nodeDimensions:Re}}function he(){me("currentY")}function me(fe){const Le={currentY:(At,Yt)=>At.y>Yt.y?1:-1,socketPosition:(At,Yt)=>{const[la,ca]=[At,Yt].map(Gt=>Ze.value.map(ha=>{var va;return(va=ha.outs)==null?void 0:va.filter(ya=>ya.toNodeId===Gt.id).map(ya=>({fromNodeId:ha.id,fromOutId:ya.outId}))}).filter(Boolean).flat());if(!la||la.length===0||!ca||ca.length===0)return 0;const qe=document.querySelector(`[data-writer-id="${la[0].fromNodeId}"] [data-writer-socket-id="${la[0].fromOutId}"]`),Y=document.querySelector(`[data-writer-id="${ca[0].fromNodeId}"] [data-writer-socket-id="${ca[0].fromOutId}"]`);if(!qe||!Y)return 0;const Fe=qe.getBoundingClientRect(),at=Y.getBoundingClientRect();return Fe.y>at.y?-1:1}},Re=ct(),{columnDimensions:Ve,nodeDimensions:Ge}=q(Re),dt=Math.max(...Array.from(Ve.values()).map(At=>At.height)),rt={};let Mt=Ue/2;for(let At=0;At<Re.size;At++){const Yt=Array.from(Re.get(At)).sort(Le[fe]),{width:la,height:ca}=Ve.get(At);let qe=tc((dt-ca)/2+Te,xa);Yt.forEach(Y=>{const Fe=Im({x:Mt,y:qe},xa);rt[Y.id]=Fe,qe+=Ge.get(Y.id).height+Te}),Mt+=tc(la+Ue,xa)}T(rt)}function _e(fe,Le){Se();const Ve=document.querySelector(`[data-writer-id="${Le}"]`).getBoundingClientRect(),Ge=(fe.pageX-Ve.x)*pe.value,dt=(fe.pageY-Ve.y)*pe.value;C.value={nodeId:Le,offset:{x:Ge,y:dt},isPerfected:!1}}function Ae(fe,Le){k.value={fromNodeId:fe,fromOutId:Le}}const pe=H(()=>1/J.value);function ce(fe){const Le=u.value.getBoundingClientRect(),Re=F.value.x+(fe.pageX-Le.x)*(1/J.value),Ve=F.value.y+(fe.pageY-Le.y)*(1/J.value);return{x:Re,y:Ve}}function ue(fe){fe.preventDefault(),fe.stopPropagation();const Le=O(fe);if(!Le)return;const{draggedType:Re,draggedId:Ve,sourceBlueprintId:Ge}=Le;if(Ve)return;const{x:dt,y:rt}=ce(fe);if(dt<0||rt<0)return;ht(Re,{x:dt,y:rt},Ge?{sourceBlueprintId:Ge}:void 0)}function I(fe,Le){if(te.value==Le){te.value=null;return}fe.stopPropagation(),te.value=Le,r.setSelection(null)}async function B(fe){if(!fe.toNodeId)return;const Le={outId:fe.fromOutId,toNodeId:fe.toNodeId};G(fe.fromNodeId,Le)}function N(fe,Le,Re,Ve){var ca;let Ge,dt,rt,Mt;const At=(ca=u.value)==null?void 0:ca.getBoundingClientRect();if(!At)return;rt=((Re==null?void 0:Re.x)-At.x)*pe.value,Mt=((Re==null?void 0:Re.y)-At.y)*pe.value;const Yt=document.querySelector(`[data-writer-id="${fe}"] [data-writer-socket-id="${Le}"]`);if(!Yt)return;const la=Yt.getBoundingClientRect();if(Ge=(la.x-At.x+la.width/2)*pe.value,dt=(la.y-At.y+la.height/2)*pe.value,!!Yt){if(typeof Ve<"u"){const Y=document.querySelector(`[data-writer-id="${Ve}"]`).getBoundingClientRect();rt=(Y.x-At.x)*pe.value,Mt=(Y.y-At.y+Y.height/2)*pe.value}return{x1:Ge,y1:dt,x2:rt,y2:Mt,color:getComputedStyle(Yt).outlineColor,fromNodeId:fe,fromOutId:Le,toNodeId:Ve}}}function U(fe){const Re=fe.target.closest(".BlueprintsBlueprint [data-writer-id]");return Re==null?void 0:Re.dataset.writerId}function se(fe){let Le,Re;Re=U(fe),typeof Re>"u"&&(Le={x:fe.pageX,y:fe.pageY});const{fromNodeId:Ve,fromOutId:Ge}=k.value;Re!=Ve&&(k.value={...k.value,liveArrow:N(Ve,Ge,Le,Re)})}function Se(){P.value=null,k.value=null,C.value=null}function Ne(fe){const Le=Object.entries(fe).filter(([Re,Ve])=>{const Ge=n.getComponentById(Re);return(Ge==null?void 0:Ge.x)!==Ve.x||(Ge==null?void 0:Ge.y)!==Ve.y}).reduce((Re,[Ve,Ge])=>{const dt=Im(Ge,xa),rt=D(Ve),Mt={...rt,...dt},At=Ze.value.filter(ca=>ca.id!==Ve).map(ca=>D(ca.id)).filter(Boolean),{x:Yt,y:la}=Pm(Mt,At,xa);return(rt.x!==Yt||rt.y!==la)&&(Re[Ve]={x:Yt,y:la}),Re},{});Object.keys(Le).length!==0&&T(Le)}function ut(){Ne(oe.value),oe.value={}}function ie(fe){const{nodeId:Le,offset:Re}=C.value,{x:Ve,y:Ge}=ce(fe),dt=Math.max(Math.floor(Ve-Re.x),0),rt=Math.max(Math.floor(Ge-Re.y),0),Mt=n.getComponentById(Le);Qg({x:Mt.x,y:Mt.y},{x:dt,y:rt})>10&&(C.value={...C.value,isPerfected:!0});const Yt={x:dt-Mt.x,y:rt-Mt.y};if(!r.selection.value.some(qe=>qe.componentId===Le)){oe.value={...oe.value,[Le]:{x:dt,y:rt}};return}const ca=r.selection.value.map(qe=>n.getComponentById(qe.componentId)).filter(qe=>qe.id!==Le&&qe.x!==void 0&&qe.y!==void 0).reduce((qe,Y)=>(qe[Y.id]=Bc({x:Y.x,y:Y.y},Yt),qe),{});oe.value={...oe.value,...ca,[Le]:{x:dt,y:rt}}}function Ee(fe){const Le=u.value.getBoundingClientRect(),Re=fe.pageX-Le.x,Ve=fe.pageY-Le.y,{x:Ge,y:dt}=P.value.offset;P.value={isPerfected:!0,offset:{x:Re,y:Ve}},kn(F.value.x+(Ge-Re)*1*pe.value,F.value.y+(dt-Ve)*1*pe.value)}function Oe(){return f.value.isSelecting}function Pe(fe){if(v(fe),!Oe()&&fe.buttons==1){if(k.value){se(fe);return}if(C.value){ie(fe);return}if(P.value&&!Oe()){Ee(fe);return}}}function Ke(fe){if(Oe()||(Se(),fe.buttons!=1))return;const Le=u.value.getBoundingClientRect(),Re=fe.pageX-Le.x,Ve=fe.pageY-Le.y;P.value={offset:{x:Re,y:Ve},isPerfected:!1}}async function it(fe){C.value&&ut();const Le=k.value;if(Se(),Le===null)return;const Re=U(fe);if(!Re)return;const{fromNodeId:Ve,fromOutId:Ge}=Le;Ve!=Re&&K(Le.fromNodeId,{toNodeId:Re,outId:Ge})}function ht(fe,Le,Re){const Ve=Ze.value.map(Mt=>D(Mt.id)).filter(Boolean),{x:Ge,y:dt}=Pm({...Le,width:240,height:180},Ve,xa),rt=Object.keys(Re??{}).length>0?{x:Ge,y:dt,content:Re}:{x:Ge,y:dt};j(fe,i,void 0,rt)}function Ft(fe){var rt;const Le=wt(fe),Re=(rt=u.value)==null?void 0:rt.getBoundingClientRect();if(!Le||!Re)return;const{width:Ve,height:Ge}=Le,dt=n.getComponentById(fe);dt&&kn(dt.x-Re.width/2+Ve/2,dt.y-Re.height/2+Ge/2)}function ma(fe){kn(fe.x,fe.y)}function Wt(fe){const Le=Ze.value.map(Ge=>({id:Ge.id,type:Ge.type,content:Ge.content,outs:Ge.outs})),Re=JSON.stringify(Le),Ve=`
8516
+ - Draft a new article with updates based on the target keywords`,style:{height:"100%"}},null,8,["modelValue"])],2))]),_:1},8,["is-busy","class"]),Z("div",Dce,[Z("p",Bce,je(c.value),1),Z("div",Fce,[i.value?($(),Ie(La,{key:0,variant:"tertiary",onClick:g},{default:Xe(()=>b[1]||(b[1]=[pa(" Back ")])),_:1})):ge("",!0),Ce(La,{variant:"tertiary",onClick:h},{default:Xe(()=>b[2]||(b[2]=[pa(" Skip ")])),_:1}),Ce(La,{variant:"secondary",disabled:i.value,onClick:m},{default:Xe(()=>[Ce(bt,{name:"sparkles"}),pa(" "+je(i.value?"Autogenerating...":"Autogenerate agent"),1)]),_:1},8,["disabled"])])])]))}}),Uce=ke(jce,[["__scopeId","data-v-50d9936c"]]),zce=["data-writer-unselectable"],qce={class:"BlueprintsBlueprint__svg"},Wce=["x","y"],Zce=["cx","cy","fill"],Kce={key:0,width:"100%",height:"100%",fill:"url(#grid)",fil:""},{log:Gce}=fa(),xa=24,Jce="A container component representing a single blueprint within the application.",Xce={writer:{name:"Blueprint",toolkit:"blueprints",category:"Root",description:Jce,allowedChildrenTypes:["*"],allowedParentTypes:["blueprints_root"],fields:{key:{name:"Blueprint key",desc:"Unique identifier. It's needed to enable navigation to this Blueprint.",type:Q.IdKey,validator:WE}}}},xo={minLevel:.2,maxLevel:1,step:.25,initialLevel:1},Yce=$e({...Xce,__name:"BlueprintsBlueprint",setup(e){ji(fe=>({"3cf15168":J.value}));const t=ir({loader:()=>zt(()=>import("./BlueprintToolbar-Qq1M1yPa.js"),__vite__mapDeps([11,12,13]),import.meta.url),loadingComponentProps:{width:"250px",height:"40px"}}),a=ir({loader:()=>zt(()=>import("./BuilderSettingsDeploySharedBlueprint-BuSxeIj-.js"),__vite__mapDeps([14,15,16,17]),import.meta.url)}),n=re(ne.core),r=re(ne.builderManager),o=re(ne.notesManager),s=re(ne.renderProxiedComponent),i=re(ne.componentId),l=re(ne.isAutogenModalShown,ye(!1));function c(){l.value=!0}const d=ye(!1),u=pt("rootEl"),h=pt("nodeContainerEl"),{selectionRect:f,isCursorSelecting:m,isHoveringSelectableArea:g,justCompletedDragSelection:_,handleMousedown:b,handleMousemove:v,handleMouseup:y,handleMouseleave:M,handleDocumentMouseup:x,handleDocumentClick:S}=sce({wrapperRef:h,builderManager:r,isAnnotating:o.isAnnotating}),L=$t([]),F=$t({x:0,y:0}),te=$t(null),J=ye(xo.initialLevel),be=new MutationObserver(ve),oe=$t({}),Te=xa*4,Ue=xa*6,Ze=H(()=>n.getComponents(i,{sortedByPosition:!0}).filter(fe=>fe.type!=="note")),Me=H(()=>Array.from(o.getNotes(i))),ee=Hd(n),{createAndInsertComponent:j,addOut:K,removeOut:G,changeCoordinatesMultiple:T}=Fs(n,r,ee),{getComponentInfoFromDrag:O}=J2e(n),k=$t(null),C=$t(null),P=$t(null),ae=xe();function xe(){const fe="blueprint__hideGrid",Le=ye(localStorage.getItem(fe)===null);return We(Le,Re=>Re?localStorage.removeItem(fe):localStorage.setItem(fe,"1")),Le}function ve(){L.value=Ze.value.reduce((fe,Le)=>{var Re;if(!((Re=Le.outs)!=null&&Re.length))return fe;for(const Ve of Le.outs){const Ge=N(Le.id,Ve.outId,void 0,Ve.toNodeId);Ge&&fe.push(Ge)}return fe},[])}const ze=H(()=>{var fe,Le;return k.value===null&&!((fe=C.value)!=null&&fe.isPerfected)&&!((Le=P.value)!=null&&Le.isPerfected)?null:!0});function Ye(fe){if(_.value){fe.preventDefault(),fe.stopPropagation();return}if(te.value=null,fe.target instanceof Element&&!fe.target.closest("[data-writer-unselectable]")&&o.isAnnotating.value){const{x:Le,y:Re}=ce(fe);o.createNote(i,{x:Le,y:Re})}}function ct(){const fe=new Map;function Le(Ve,Ge){var _t;if(fe.values().find(At=>At.has(Ve)))return;fe.has(Ge)||fe.set(Ge,new Set),fe.get(Ge).add(Ve),(_t=Ve.outs)==null||_t.forEach(At=>{const Yt=n.getComponentById(At.toNodeId);Le(Yt,Ge+1)})}const Re=new Map;return Ze.value.forEach(Ve=>{var Ge;(Ge=Ve.outs)==null||Ge.forEach(dt=>{Re.has(dt.toNodeId)||Re.set(dt.toNodeId,new Set),Re.get(dt.toNodeId).add(Ve.id)})}),Ze.value.filter(Ve=>!Re.has(Ve.id)).forEach(Ve=>{Le(Ve,0)}),fe}function xt(fe){const Le=`[data-writer-id="${fe}"]`,Re=h.value.querySelector(Le);if(Re)return Re.getBoundingClientRect()}function D(fe){var Ge;const Le=xt(fe);if(!Le)return;const Re=(Ge=u.value)==null?void 0:Ge.getBoundingClientRect();if(!Re)return;const Ve=dt=>{const rt=tc(dt,xa);return rt===dt?rt+1:rt-1};return{x:F.value.x+(Le.x-Re.x)*pe.value,y:F.value.y+(Le.y-Re.y)*pe.value,width:Ve(Le.width*pe.value),height:Ve(Le.height*pe.value)}}function q(fe){const Le=new Map,Re=new Map;return fe.forEach((Ve,Ge)=>{let dt=0,rt=0;Ve.forEach(_t=>{const At=xt(_t.id);At&&(Re.set(_t.id,{height:At.height*pe.value}),dt+=At.height*pe.value+Te,rt=Math.max(rt,At.width*pe.value))}),Le.set(Ge,{height:dt-Te,width:rt})}),{columnDimensions:Le,nodeDimensions:Re}}function he(){me("currentY")}function me(fe){const Le={currentY:(At,Yt)=>At.y>Yt.y?1:-1,socketPosition:(At,Yt)=>{const[la,ca]=[At,Yt].map(Gt=>Ze.value.map(ha=>{var va;return(va=ha.outs)==null?void 0:va.filter(ya=>ya.toNodeId===Gt.id).map(ya=>({fromNodeId:ha.id,fromOutId:ya.outId}))}).filter(Boolean).flat());if(!la||la.length===0||!ca||ca.length===0)return 0;const qe=document.querySelector(`[data-writer-id="${la[0].fromNodeId}"] [data-writer-socket-id="${la[0].fromOutId}"]`),Y=document.querySelector(`[data-writer-id="${ca[0].fromNodeId}"] [data-writer-socket-id="${ca[0].fromOutId}"]`);if(!qe||!Y)return 0;const Fe=qe.getBoundingClientRect(),at=Y.getBoundingClientRect();return Fe.y>at.y?-1:1}},Re=ct(),{columnDimensions:Ve,nodeDimensions:Ge}=q(Re),dt=Math.max(...Array.from(Ve.values()).map(At=>At.height)),rt={};let _t=Ue/2;for(let At=0;At<Re.size;At++){const Yt=Array.from(Re.get(At)).sort(Le[fe]),{width:la,height:ca}=Ve.get(At);let qe=tc((dt-ca)/2+Te,xa);Yt.forEach(Y=>{const Fe=Im({x:_t,y:qe},xa);rt[Y.id]=Fe,qe+=Ge.get(Y.id).height+Te}),_t+=tc(la+Ue,xa)}T(rt)}function _e(fe,Le){Se();const Ve=document.querySelector(`[data-writer-id="${Le}"]`).getBoundingClientRect(),Ge=(fe.pageX-Ve.x)*pe.value,dt=(fe.pageY-Ve.y)*pe.value;C.value={nodeId:Le,offset:{x:Ge,y:dt},isPerfected:!1}}function Ae(fe,Le){k.value={fromNodeId:fe,fromOutId:Le}}const pe=H(()=>1/J.value);function ce(fe){const Le=u.value.getBoundingClientRect(),Re=F.value.x+(fe.pageX-Le.x)*(1/J.value),Ve=F.value.y+(fe.pageY-Le.y)*(1/J.value);return{x:Re,y:Ve}}function ue(fe){fe.preventDefault(),fe.stopPropagation();const Le=O(fe);if(!Le)return;const{draggedType:Re,draggedId:Ve,sourceBlueprintId:Ge}=Le;if(Ve)return;const{x:dt,y:rt}=ce(fe);if(dt<0||rt<0)return;ht(Re,{x:dt,y:rt},Ge?{sourceBlueprintId:Ge}:void 0)}function I(fe,Le){if(te.value==Le){te.value=null;return}fe.stopPropagation(),te.value=Le,r.setSelection(null)}async function B(fe){if(!fe.toNodeId)return;const Le={outId:fe.fromOutId,toNodeId:fe.toNodeId};G(fe.fromNodeId,Le)}function N(fe,Le,Re,Ve){var ca;let Ge,dt,rt,_t;const At=(ca=u.value)==null?void 0:ca.getBoundingClientRect();if(!At)return;rt=((Re==null?void 0:Re.x)-At.x)*pe.value,_t=((Re==null?void 0:Re.y)-At.y)*pe.value;const Yt=document.querySelector(`[data-writer-id="${fe}"] [data-writer-socket-id="${Le}"]`);if(!Yt)return;const la=Yt.getBoundingClientRect();if(Ge=(la.x-At.x+la.width/2)*pe.value,dt=(la.y-At.y+la.height/2)*pe.value,!!Yt){if(typeof Ve<"u"){const Y=document.querySelector(`[data-writer-id="${Ve}"]`).getBoundingClientRect();rt=(Y.x-At.x)*pe.value,_t=(Y.y-At.y+Y.height/2)*pe.value}return{x1:Ge,y1:dt,x2:rt,y2:_t,color:getComputedStyle(Yt).outlineColor,fromNodeId:fe,fromOutId:Le,toNodeId:Ve}}}function U(fe){const Re=fe.target.closest(".BlueprintsBlueprint [data-writer-id]");return Re==null?void 0:Re.dataset.writerId}function se(fe){let Le,Re;Re=U(fe),typeof Re>"u"&&(Le={x:fe.pageX,y:fe.pageY});const{fromNodeId:Ve,fromOutId:Ge}=k.value;Re!=Ve&&(k.value={...k.value,liveArrow:N(Ve,Ge,Le,Re)})}function Se(){P.value=null,k.value=null,C.value=null}function Ne(fe){const Le=Object.entries(fe).filter(([Re,Ve])=>{const Ge=n.getComponentById(Re);return(Ge==null?void 0:Ge.x)!==Ve.x||(Ge==null?void 0:Ge.y)!==Ve.y}).reduce((Re,[Ve,Ge])=>{const dt=Im(Ge,xa),rt=D(Ve),_t={...rt,...dt},At=Ze.value.filter(ca=>ca.id!==Ve).map(ca=>D(ca.id)).filter(Boolean),{x:Yt,y:la}=Pm(_t,At,xa);return(rt.x!==Yt||rt.y!==la)&&(Re[Ve]={x:Yt,y:la}),Re},{});Object.keys(Le).length!==0&&T(Le)}function ut(){Ne(oe.value),oe.value={}}function ie(fe){const{nodeId:Le,offset:Re}=C.value,{x:Ve,y:Ge}=ce(fe),dt=Math.max(Math.floor(Ve-Re.x),0),rt=Math.max(Math.floor(Ge-Re.y),0),_t=n.getComponentById(Le);Qg({x:_t.x,y:_t.y},{x:dt,y:rt})>10&&(C.value={...C.value,isPerfected:!0});const Yt={x:dt-_t.x,y:rt-_t.y};if(!r.selection.value.some(qe=>qe.componentId===Le)){oe.value={...oe.value,[Le]:{x:dt,y:rt}};return}const ca=r.selection.value.map(qe=>n.getComponentById(qe.componentId)).filter(qe=>qe.id!==Le&&qe.x!==void 0&&qe.y!==void 0).reduce((qe,Y)=>(qe[Y.id]=Bc({x:Y.x,y:Y.y},Yt),qe),{});oe.value={...oe.value,...ca,[Le]:{x:dt,y:rt}}}function Ee(fe){const Le=u.value.getBoundingClientRect(),Re=fe.pageX-Le.x,Ve=fe.pageY-Le.y,{x:Ge,y:dt}=P.value.offset;P.value={isPerfected:!0,offset:{x:Re,y:Ve}},kn(F.value.x+(Ge-Re)*1*pe.value,F.value.y+(dt-Ve)*1*pe.value)}function Oe(){return f.value.isSelecting}function Pe(fe){if(v(fe),!Oe()&&fe.buttons==1){if(k.value){se(fe);return}if(C.value){ie(fe);return}if(P.value&&!Oe()){Ee(fe);return}}}function Ke(fe){if(Oe()||(Se(),fe.buttons!=1))return;const Le=u.value.getBoundingClientRect(),Re=fe.pageX-Le.x,Ve=fe.pageY-Le.y;P.value={offset:{x:Re,y:Ve},isPerfected:!1}}async function it(fe){C.value&&ut();const Le=k.value;if(Se(),Le===null)return;const Re=U(fe);if(!Re)return;const{fromNodeId:Ve,fromOutId:Ge}=Le;Ve!=Re&&K(Le.fromNodeId,{toNodeId:Re,outId:Ge})}function ht(fe,Le,Re){const Ve=Ze.value.map(_t=>D(_t.id)).filter(Boolean),{x:Ge,y:dt}=Pm({...Le,width:240,height:180},Ve,xa),rt=Object.keys(Re??{}).length>0?{x:Ge,y:dt,content:Re}:{x:Ge,y:dt};j(fe,i,void 0,rt)}function Ft(fe){var rt;const Le=xt(fe),Re=(rt=u.value)==null?void 0:rt.getBoundingClientRect();if(!Le||!Re)return;const{width:Ve,height:Ge}=Le,dt=n.getComponentById(fe);dt&&kn(dt.x-Re.width/2+Ve/2,dt.y-Re.height/2+Ge/2)}function ma(fe){kn(fe.x,fe.y)}function Wt(fe){const Le=Ze.value.map(Ge=>({id:Ge.id,type:Ge.type,content:Ge.content,outs:Ge.outs})),Re=JSON.stringify(Le),Ve=`
8517
8517
  <example>
8518
8518
  <description>
8519
8519
  ${fe}
@@ -8521,5 +8521,5 @@ example:
8521
8521
  <blueprint>
8522
8522
  ${Re}
8523
8523
  </blueprint>
8524
- </example>`.trim();Gce(Ve)}function ln(fe){J.value=Math.max(Math.min(bo.maxLevel,fe),bo.minLevel)}function Pr(fe){ln(fe)}function kn(fe,Le){F.value={x:Math.max(0,fe),y:Math.max(0,Le)}}function lo(fe){kn(F.value.x+fe.deltaX*pe.value,F.value.y+fe.deltaY*pe.value)}function Ro(fe){const Le=.006666666666666667,Re=u.value.getBoundingClientRect(),Ve=J.value;J.value=Math.min(Math.max(J.value-fe.deltaY*Le,bo.minLevel),bo.maxLevel);const Ge={w:Re.width*(1/Ve)*pe.value*(J.value-Ve),h:Re.height*(1/Ve)*pe.value*(J.value-Ve)},dt={x:(fe.pageX-Re.x)/Re.width,y:(fe.pageY-Re.y)/Re.height};kn(F.value.x+Ge.w*dt.x,F.value.y+Ge.h*dt.y)}async function No(fe){if(fe.preventDefault(),!fe.ctrlKey&&!Fc(fe)){lo(fe);return}Ro(fe)}async function Do(){const{width:Le,height:Re,x:Ve,y:Ge}=u.value.getBoundingClientRect(),dt=h.value.querySelectorAll("[data-writer-id]"),{maxX:rt,maxY:Mt}=Array.from(dt).reduce((Yt,la)=>{const ca=la.getBoundingClientRect();return{maxY:Math.max(Yt.maxY,(ca.bottom-Ge)*pe.value+F.value.y),maxX:Math.max(Yt.maxX,(ca.right-Ve)*pe.value+F.value.x)}},{maxY:0,maxX:0}),At=Math.min((Le-48)/rt,(Re-48)/Mt);ln(At),kn(0,0)}async function Bo(fe){if(l.value=!1,!fe)return;const{components:Le}=fe;Le.forEach(Re=>{j(Re.type,i,void 0,Re)}),await qa(),me("socketPosition")}We(r.firstSelectedItem,fe=>{fe&&(te.value=null,n.isChildOf(i,fe.componentId)&&fe.source!=="click"&&Ft(fe.componentId))});function Fo(fe){if(Fc(fe)&&(fe.code==="Backquote"||fe.code==="Backslash")){ae.value=!ae.value;return}if(!r.selection.value.length)return;const Re=fe.target;if(Re.tagName==="INPUT"||Re.tagName==="TEXTAREA"||Re.getAttribute("contenteditable")==="true")return;function Ve(){switch(fe.key){case"ArrowDown":return{x:0,y:xa};case"ArrowUp":return{x:0,y:-xa};case"ArrowLeft":return{x:-xa,y:0};case"ArrowRight":return{x:xa,y:0}}}const Ge=Ve();if(Ge===void 0)return;fe.preventDefault();const dt=r.selection.value.map(rt=>n.getComponentById(rt.componentId)).filter(rt=>(rt==null?void 0:rt.x)!==void 0&&(rt==null?void 0:rt.y)!==void 0).reduce((rt,Mt)=>(rt[Mt.id]=Bc({x:Mt.x,y:Mt.y},Ge),rt),{});Ne(dt)}const ur=Ki();return ia(async()=>{var fe;await Do(),await qa(),ve(),(fe=u.value)==null||fe.addEventListener("wheel",No,{signal:ur.signal}),document.addEventListener("keydown",Fo,{signal:ur.signal}),document.addEventListener("mouseup",x,{signal:ur.signal}),document.addEventListener("click",S,{signal:ur.signal,capture:!0}),be.observe(h.value,{attributes:!0,attributeFilter:["style"],childList:!0,subtree:!0,characterData:!0}),window.createAutogenExample=Wt}),Wn(()=>{ur.abort(),be.disconnect()}),(fe,Le)=>{var Re;return $(),R("div",{ref_key:"rootEl",ref:u,class:ft(["BlueprintsBlueprint",{isSelecting:E(m),canSelect:E(g)&&!E(m)}]),"data-writer-unselectable":ze.value,onClick:Ye,onDragover:Le[6]||(Le[6]=sn(()=>{},["prevent","stop"])),onDrop:ue,onMousemove:Pe,onMousedown:Ke,onMouseup:it},[Z("div",{ref_key:"nodeContainerEl",ref:h,class:"nodeContainer",onMousedown:Le[0]||(Le[0]=(...Ve)=>E(b)&&E(b)(...Ve)),onMousemove:Le[1]||(Le[1]=(...Ve)=>E(v)&&E(v)(...Ve)),onMouseup:Le[2]||(Le[2]=(...Ve)=>E(y)&&E(y)(...Ve)),onMouseleave:Le[3]||(Le[3]=(...Ve)=>E(M)&&E(M)(...Ve))},[($(),R("svg",qce,[Z("defs",null,[Z("pattern",{id:"grid",width:xa,height:xa,patternUnits:"userSpaceOnUse",x:-F.value.x-xa/2,y:-F.value.y-xa/2},[Z("circle",{cx:xa/2,cy:xa/2,r:"1",fill:E(Ht).Gray3},null,8,Zce)],8,Wce)]),E(ae)?($(),R("rect",Kce)):ge("",!0),($(!0),R(Je,null,Ot(L.value,(Ve,Ge)=>($(),Ie(Vm,{key:Ge,arrow:Ve,"is-selected":te.value==Ge,"is-engaged":te.value==Ge||E(r).isComponentIdSelected(Ve.fromNodeId)||E(r).isComponentIdSelected(Ve.toNodeId),onClick:dt=>I(dt,Ge),onDelete:dt=>B(Ve)},null,8,["arrow","is-selected","is-engaged","onClick","onDelete"]))),128)),(Re=k.value)!=null&&Re.liveArrow?($(),Ie(Vm,{key:"liveArrow",arrow:k.value.liveArrow,"is-selected":!1,"is-engaged":!0},null,8,["arrow"])):ge("",!0)])),($(!0),R(Je,null,Ot(Ze.value,Ve=>{var Ge,dt,rt,Mt,At,Yt,la,ca;return $(),Ie(Ts(E(s)(Ve.id,0)),{key:Ve.id,style:bt({top:`${(((dt=(Ge=oe.value)==null?void 0:Ge[Ve.id])==null?void 0:dt.y)??Ve.y)-F.value.y}px`,left:`${(((Mt=(rt=oe.value)==null?void 0:rt[Ve.id])==null?void 0:Mt.x)??Ve.x)-F.value.x}px`,"border-color":((Yt=(At=k.value)==null?void 0:At.liveArrow)==null?void 0:Yt.toNodeId)==Ve.id?(ca=(la=k.value)==null?void 0:la.liveArrow)==null?void 0:ca.color:void 0}),onMousedown:sn(qe=>_e(qe,Ve.id),["stop"]),onOutMousedown:qe=>Ae(Ve.id,qe)},null,40,["style","onMousedown","onOutMousedown"])}),128)),($(!0),R(Je,null,Ot(Me.value,Ve=>{var Ge,dt,rt,Mt;return $(),Ie(oce,{key:Ve.id,"component-id":Ve.id,style:bt({top:`${(((dt=(Ge=oe.value)==null?void 0:Ge[Ve.id])==null?void 0:dt.y)??Ve.y)-F.value.y}px`,left:`${(((Mt=(rt=oe.value)==null?void 0:rt[Ve.id])==null?void 0:Mt.x)??Ve.x)-F.value.x}px`})},null,8,["component-id","style"])}),128)),E(f).isSelecting?($(),R("div",{key:0,class:"selectionRectangle",style:bt({left:`${E(f).left}px`,top:`${E(f).top}px`,width:`${E(f).width}px`,height:`${E(f).height}px`})},null,4)):ge("",!0)],544),Ce(E(t),{class:"blueprintsToolbar",onAutogenClick:c,onDeploy:Le[4]||(Le[4]=Ve=>d.value=!0)}),E(l)?($(),Ie(Sg,{key:0},{default:Xe(()=>[Ce(Uce,{onBlockGeneration:Bo})]),_:1})):ge("",!0),Ce(E(a),{modelValue:d.value,"onUpdate:modelValue":Le[5]||(Le[5]=Ve=>d.value=Ve),"blueprint-id":E(i)},null,8,["modelValue","blueprint-id"]),E(h)?($(),Ie(bce,{key:1,"node-container-el":E(h),"render-offset":F.value,"zoom-level":J.value,class:"navigator",onAutoArrange:he,onChangeRenderOffset:ma,onChangeZoomLevel:Pr,onResetZoom:Do},null,8,["node-container-el","render-offset","zoom-level"])):ge("",!0)],42,zce)}}}),Qce=ke(Yce,[["__scopeId","data-v-d8dd8762"]]);function e0e(e,t){const a=(t==null?void 0:t.wf)??re(ne.core),n=(t==null?void 0:t.ssbm)??re(ne.builderManager);if(!a)throw new Error("Missing core injection.");if(!n)throw new Error("Missing builderManager injection.");const r=fa(),o=H(()=>a.getComponentById(Pa(e.componentId)));We(o,h=>{h||r.error(`useComponentFieldViewModel: component with id "${Pa(e.componentId)}" not found`)},{immediate:!0});const s=H(()=>{var m,g,_;const h=Pa(e.defaultValue);if(typeof h=="string")return h;const f=a.getComponentDefinition((m=o.value)==null?void 0:m.type);return((_=(g=f==null?void 0:f.fields)==null?void 0:g[Pa(e.fieldKey)])==null?void 0:_.default)??""}),{setContentValue:i}=Bs(a,n);function l(h){o.value&&i(o.value.id,Pa(e.fieldKey),h)}const c=ye(!1);We([()=>Pa(e.componentId),()=>Pa(e.fieldKey)],()=>{c.value=!1});const d=H(()=>{var f,m;const h=(m=(f=o.value)==null?void 0:f.content)==null?void 0:m[Pa(e.fieldKey)];return c.value&&typeof h=="string"?h:h||s.value});return H({get:()=>d.value,set:h=>{c.value=!0,l(h)}})}const t0e={class:"alias"},a0e=["contenteditable"],n0e=$e({__name:"BlueprintsNodeNamer",props:{componentId:{},blockName:{}},setup(e){const a=e0e({componentId:mn(e,"componentId"),fieldKey:"alias"}),n=H(()=>!!a.value),r=pt("aliasEditorEl"),o=ye(!1);async function s(){if(o.value)return;o.value=!0,await qa();const c=r.value;c.focus();const d=document.createRange(),u=window.getSelection();d.setStart(c,c.childNodes.length),d.collapse(!0),u.removeAllRanges(),u.addRange(d)}function i(){const c=r.value.textContent;r.value.blur(),o.value=!1,a.value=c}function l(c){o.value&&c.stopPropagation()}return(c,d)=>($(),R("div",{class:ft(["BlueprintsNodeNamer",{beingEdited:o.value,hasEyebrow:n.value||o.value}]),"data-writer-unselectable":"true"},[Z("div",{class:"blockName",onClick:s},je(c.blockName),1),Z("div",t0e,[n.value||o.value?($(),R("div",{key:0,ref_key:"aliasEditorEl",ref:r,class:"aliasEditor",contenteditable:o.value,"data-writer-unselectable":"true",onClick:s,onMousemove:l,onBlur:i,onKeydown:Sr(i,["enter"])},je(E(a)),41,a0e)):ge("",!0)])],2))}}),r0e=ke(n0e,[["__scopeId","data-v-ac3126a4"]]);function e8(e,t){const a=H(()=>{const r=E(t);if(r)return e.getComponentById(r)}),n=H(()=>{var o;const r=(o=a.value)==null?void 0:o.type;if(r)return e.getComponentDefinition(r)});return{component:a,definition:n}}function o0e(e,t){return H(()=>{var s;const{type:a,id:n}=E(e)??{},r=(s=E(t))==null?void 0:s.outs;return a&&!Pd.has(a)&&a.startsWith("blueprints_")&&(r==null?void 0:r.success)!==void 0?`@{results.${n}}`:""})}const s0e=$e({__name:"SharedMoreDropdown",props:{options:{type:Array,default:()=>[]},triggerSize:{type:String,default:"smallIcon"},triggerVariant:{type:String,default:"neutral"},triggerCustomSize:{type:String,default:void 0},triggerIcon:{type:String,default:"ellipsis"},disabled:{type:Boolean},hideIcons:{type:Boolean,required:!1},dropdownPlacement:{type:String,required:!1,default:"bottom-end"},floatingMiddleware:{type:Array,required:!1,default:()=>[i6({allowedPlacements:["bottom-end","top-end"]})]}},emits:{select:e=>typeof e=="string"},setup(e,{emit:t}){const a=sr({loader:()=>zt(()=>import("./WdsDropdownMenu-BPKaOD8s.js").then(u=>u.b),__vite__mapDeps([4,5,6,7]),import.meta.url)}),n=e,r=t,o=ye(!1),s=pt("trigger"),i=pt("dropdown"),{floatingStyles:l}=c6(s,i,{placement:mn(n,"dropdownPlacement"),middleware:mn(n,"floatingMiddleware")}),c=b0(s);We(c,()=>{c.value||qa().then(()=>o.value=!1)},{immediate:!0});function d(u){o.value=!1,r("select",u)}return(u,h)=>($(),R("div",{ref_key:"trigger",ref:s,class:"SharedMoreDropdown"},[Ce(La,{variant:e.triggerVariant,size:e.triggerSize,disabled:e.disabled,"custom-size":e.triggerCustomSize,onClick:h[0]||(h[0]=sn(f=>o.value=!o.value,["stop"]))},{default:Xe(()=>[Ce(_t,{name:e.triggerIcon},null,8,["name"])]),_:1},8,["variant","size","disabled","custom-size"]),o.value?($(),Ie(E(a),{key:0,ref_key:"dropdown",ref:i,class:"SharedMoreDropdown__dropdown",options:e.options,style:bt(E(l)),"hide-icons":e.hideIcons,onSelect:d},null,8,["options","style","hide-icons"])):ge("",!0)],512))}}),t8=ke(s0e,[["__scopeId","data-v-df890e8f"]]),i0e=Object.freeze(Object.defineProperty({__proto__:null,default:t8},Symbol.toStringTag,{value:"Module"}));var ls=(e=>(e.Add="add",e.MoveUp="moveUp",e.MoveDown="moveDown",e.Cut="cut",e.Copy="copy",e.Paste="paste",e.GoToParent="goToParent",e.Delete="delete",e))(ls||{});function l0e(e){return typeof e=="string"&&Object.values(ls).includes(e)}function c0e(e,t,a,n={},r){const{moveComponentUp:o,moveComponentDown:s,cutComponent:i,pasteComponent:l,copyComponent:c,isAddAllowed:d,isCopyAllowed:u,isCutAllowed:h,isGoToParentAllowed:f,isPasteAllowed:m,isDeleteAllowed:g,getEnabledMoves:_,removeComponentsSubtree:b,goToParent:v}=Bs(e,t,a),y=Od(),M=H(()=>r?E(r).componentId:t.firstSelectedId.value),x=H(()=>r?E(r).instancePath:t.firstSelectedItem.value.instancePath),S=H(()=>{var Ze,Me;const oe=e.getComponentById(M.value);if(!oe)return{};const{up:Te,down:Ue}=_(M.value);return{isAddEnabled:d(M.value),componentTypeName:(Ze=e.getComponentDefinition(oe.type))==null?void 0:Ze.name,toolkit:(Me=e.getComponentDefinition(oe.type))==null?void 0:Me.toolkit,isMoveUpEnabled:Te,isMoveDownEnabled:Ue,isCopyEnabled:u(M.value),isCutEnabled:h(M.value),isGoToParentEnabled:f(M.value),isDeleteEnabled:g(M.value)}}),L=H(()=>t.firstSelectedId.value?m(t.firstSelectedId.value):!1);async function F(){try{await l(M.value)}catch(oe){y.pushToast({type:"error",message:String(oe)})}}function te(){if(!S.value.isDeleteEnabled)return;if(r){b(E(r).componentId);return}const oe=t.selection.value.map(Te=>Te.componentId);oe.length!==0&&b(...oe)}const J=H(()=>[{value:"add",label:"Add child",icon:"plus",disabled:!S.value.isAddEnabled},{value:"moveUp",label:"Move up",shortcut:`${Wr()}↑`,icon:"arrow-up",disabled:!S.value.isMoveUpEnabled},{value:"moveDown",label:"Move down",shortcut:`${Wr()}↓`,icon:"arrow-down",disabled:!S.value.isMoveDownEnabled},{value:"cut",label:"Cut",shortcut:`${Wr()}X`,icon:"scissors",disabled:!S.value.isCutEnabled},{value:"copy",label:"Copy",shortcut:`${Wr()}C`,icon:"clipboard",disabled:!S.value.isCopyEnabled},{value:"paste",label:"Paste",shortcut:`${Wr()}V`,icon:"clipboard-paste",disabled:!L.value},{value:"goToParent",label:"View parent",shortcut:`${Wr()}⇧↑`,icon:"list-tree",disabled:!S.value.isGoToParentEnabled},{value:"delete",label:"Delete",shortcut:Vd()?"⌫":"Del",icon:"trash-2",variant:"danger",disabled:!S.value.isDeleteEnabled}]);function be(oe){var Te;switch(oe){case"add":break;case"moveUp":o(M.value);break;case"moveDown":s(M.value);break;case"cut":i(M.value);break;case"copy":c(M.value);break;case"paste":F();break;case"goToParent":v(M.value,x.value);break;case"delete":te();break}(Te=n[oe])==null||Te.call(n)}return{dropdownOptions:J,handleDropdownSelect:be}}function a8(e){return e.map(t=>`${t.componentId}:${t.instanceNumber}`).join(",")}function Fde(e){return e?e.split(",").map(t=>{const[a,n]=t.split(":");return{componentId:a,instanceNumber:Number(n)}}):[]}const d0e={class:"BlueprintsNodeActions"},u0e=$e({__name:"BlueprintsNodeActions",props:{showDisplayErrorOption:{type:Boolean}},emits:{showError:()=>!0},setup(e,{emit:t}){const a=re(ne.core),n=re(ne.builderManager),r=re(ne.componentId),o=re(ne.instancePath),s=e,i=t,{component:l,definition:c}=e8(a,r),d=o0e(l,c),u=Hd(a),{copy:h,copied:f}=Lg();function m(){h(d.value)}const g=c0e(a,n,u,{},{instancePath:a8(o),componentId:r});function _(y){switch(l0e(y)&&g.handleDropdownSelect(y),y){case"showError":i("showError");break}}const b=new Set([ls.Add,ls.MoveUp,ls.MoveDown,ls.Paste]),v=H(()=>{const y=g.dropdownOptions.value.filter(M=>!b.has(M.value)).map(M=>(delete M.shortcut,M));return s.showDisplayErrorOption&&y.unshift({value:"showError",label:"Add error path",icon:"split"}),y});return(y,M)=>($(),R("div",d0e,[E(d)?($(),Ie(La,{key:0,size:"smallIcon",variant:"neutral","data-writer-tooltip-placement":"bottom","data-writer-unselectable":!0,"data-writer-tooltip":E(f)?"Copied!":"Copy result variable",onClick:sn(m,["prevent"])},{default:Xe(()=>[Ce(_t,{name:"at-sign"})]),_:1},8,["data-writer-tooltip"])):ge("",!0),Ce(t8,{"data-automation-action":"node-actions-dropdown",options:v.value,"data-writer-unselectable":!0,"trigger-custom-size":"32px","trigger-icon":"ellipsis-vertical",onSelect:_},null,8,["options"])]))}}),Rm=ke(u0e,[["__scopeId","data-v-ca70c7e7"]]),h0e={class:"BlueprintsNodeOutput"},p0e=["data-writer-socket-id"],f0e=$e({__name:"BlueprintsNodeOutput",props:{outId:{type:String,required:!0},out:{type:Object,required:!0},displayLabel:{type:Boolean}},emits:{click:()=>!0},setup(e){return(t,a)=>($(),R("div",h0e,[e.displayLabel?($(),R(Je,{key:0},[pa(je(e.out.name),1)],64)):ge("",!0),Z("div",{class:ft(["BlueprintsNodeOutput__ball",e.out.style]),"data-writer-socket-id":e.outId,"data-writer-unselectable":!0,onClickCapture:a[0]||(a[0]=sn(()=>{},["stop"])),onMousedownCapture:a[1]||(a[1]=sn(n=>t.$emit("click"),["stop"]))},null,42,p0e)]))}}),rc=ke(f0e,[["__scopeId","data-v-cbba3510"]]),m0e={class:"BlueprintsNodeLogs"},v0e=$e({__name:"BlueprintsNodeLogs",props:{count:{type:Number,required:!0},completionStyle:{type:String,required:!1,default:void 0}},emits:{click:()=>!0},setup(e){const t=e,a=H(()=>t.count===1?"1 output":`${t.count} outputs`);return(n,r)=>($(),R("div",m0e,[Z("button",{class:ft(["BlueprintsNodeLogs__btn",{"BlueprintsNodeLogs__btn--success":e.completionStyle=="success","BlueprintsNodeLogs__btn--skipped":e.completionStyle=="skipped","BlueprintsNodeLogs__btn--stopped":e.completionStyle=="stopped","BlueprintsNodeLogs__btn--error":e.completionStyle=="error"}]),"data-writer-unselectable":!0,type:"button",onClick:r[0]||(r[0]=o=>n.$emit("click"))},je(a.value),3)]))}}),g0e=ke(v0e,[["__scopeId","data-v-daf51f8d"]]);function jc(e){if(!e)return{};if(typeof e=="string")try{const t=JSON.parse(e);return typeof t=="object"&&t!==null?t:{}}catch{return{}}return typeof e=="object"?e:{}}function y0e(e,t){const a=H(()=>{var i;const r=Object.entries(((i=e.value)==null?void 0:i.fields)??{}).filter(([l,c])=>c.type===Q.Tools);if(r.length===0)return!1;const o=r.map(([l])=>{var c;return{fieldKey:l,tools:jc((c=t[l])==null?void 0:c.value)}});return o.some(({tools:l})=>Object.keys(l).length>0)?o.every(({tools:l})=>{const c=Object.keys(l);return c.length===0?!0:!c.some(d=>{var u;return((u=l[d])==null?void 0:u.type)==="function"})}):!1});function n(r){var i;const o=jc((i=t[r])==null?void 0:i.value),s=Object.keys(o);return s.length===0?!1:!s.some(l=>{var c;return((c=o[l])==null?void 0:c.type)==="function"})}return{hasOnlyNonFunctionTools:a,hasToolsButNoFunctionTools:n}}const M0e={key:0,class:"BlueprintsNode__main__outputs__output BlueprintsNode__main__outputs__empty"},_0e=$e({__name:"BlueprintsNodeTools",props:{fieldKey:{},fieldType:{},fieldValue:{},hasOutputs:{type:Boolean}},setup(e){const t=e,a=H(()=>t.fieldType!==Q.Tools?{}:jc(t.fieldValue)),n=H(()=>{if(t.fieldType!==Q.Tools)return!1;const l=Object.keys(a.value);return l.length===0?!1:!l.some(c=>{var d;return((d=a.value[c])==null?void 0:d.type)==="function"})});function r(l){return l!==null&&typeof l=="object"&&"type"in l&&l.type==="function"}const o=H(()=>Object.keys(a.value).filter(l=>!r(a.value[l]))),s=H(()=>o.value.length>0?o.value.join(", "):!t.hasOutputs&&n.value?"No outputs":"None configured."),i=H(()=>!t.hasOutputs||o.value.length>0);return(l,c)=>i.value?($(),R("div",M0e,je(s.value),1)):ge("",!0)}}),b0e=ke(_0e,[["__scopeId","data-v-09778394"]]);function n8(e,t){var r,o;if((t==null?void 0:t.type)!=="blueprints_shared")return null;const a=(r=t.content)==null?void 0:r.sourceBlueprintId;if(!a)return null;const n=e.getComponentById(a);return((o=n==null?void 0:n.content)==null?void 0:o.key)||null}function jde(e,t){const a=H(()=>e.getComponentDefinition(E(t).type)),n=H(()=>{var c;const s=E(t),{type:i,content:l}=s;return i=="html"&&(l!=null&&l.element)?l==null?void 0:l.element:i=="blueprints_blueprint"?(l==null?void 0:l.key)||"Blueprint":i=="blueprints_shared"?n8(e,s)||"Shared Blueprint":((c=a.value)==null?void 0:c.name)??`Unknown (${i})`}),r=H(()=>{var d,u;const s=(d=a.value)==null?void 0:d.previewField;if(!s)return;const i=(u=E(t).content)==null?void 0:u[s];let l;const c=70;return(i==null?void 0:i.length)>c?l=i.substring(0,c)+"...":l=i,l}),o=H(()=>{const s=E(t).type,i=a.value.category;return[`/components/${s}.svg`,`/components/category_${i}.svg`,s.startsWith("blueprints_")?`/components/blueprints_category_${i}.svg`:void 0].filter(Boolean).map(l=>Li(l))});return{name:n,previewText:r,possibleImageUrls:o}}const w0e={key:0,class:"BlueprintsNode__side"},x0e={class:"BlueprintsNode__extraBorder"},C0e={key:0,class:"runner"},A0e={class:"BlueprintsNode__main"},S0e={class:"BlueprintsNode__main__title"},$0e={key:0,class:"deprecationNotice"},E0e={key:0,class:"BlueprintsNode__main__outputs__title"},I0e={key:0,class:"BlueprintsNode__main__outputs__title"},k0e={key:1,class:"BlueprintsNode__main__footer"},T0e={writer:{name:"Node",description:"A Blueprints node.",toolkit:"blueprints",category:"Other",fields:{alias:{name:"Alias",type:Q.Text}},allowedParentTypes:["blueprints_blueprint"],previewField:"alias"}},P0e=$e({...T0e,__name:"BlueprintsNode",emits:["outMousedown","engaged"],setup(e,{emit:t}){const a=t,n=re(ne.core),r=re(ne.builderManager),{removeOut:o}=Bs(n,r),s=re(ne.componentId),i=re(ne.evaluatedFields),l=H(()=>{var K;return((K=h==null?void 0:h.value)==null?void 0:K.category)=="Triggers"}),c=H(()=>{var K;return((K=h==null?void 0:h.value)==null?void 0:K.category)=="Writer"}),d=H(()=>{var K;return(K=h==null?void 0:h.value)==null?void 0:K.deprecated}),{component:u,definition:h}=e8(n,s),f=H(()=>{var K;return u.value&&(n8(n,u.value)||((K=h.value)==null?void 0:K.name))||"Unknown"}),m=H(()=>{var K,G,T;return S.value==null?null:S.value=="skipped"?"skipped":S.value=="stopped"?"stopped":S.value=="in_progress"?"running":((T=(G=(K=h.value)==null?void 0:K.outs)==null?void 0:G[S.value])==null?void 0:T.style)??"success"}),{hasOnlyNonFunctionTools:g}=y0e(H(()=>h.value),i),_=H(()=>Object.entries(h.value.outs??{}).some(([G,T])=>{var k,C;return T.style!=="dynamic"||!T.field?!1:((C=(k=h.value.fields)==null?void 0:k[T.field])==null?void 0:C.type)!==Q.Tools})),b=H(()=>_.value?"OR":g.value?"No outputs":"THEN"),v=H(()=>g.value||!oe.value&&Object.keys(Me.value).length>0),y=H(()=>{var T,O;const K=r.getLogEntries(),G=((O=(T=K.find(k=>!!k.blueprintExecution))==null?void 0:T.blueprintExecution)==null?void 0:O.runId)??null;return K.filter(k=>{var C;return((C=k==null?void 0:k.blueprintExecution)==null?void 0:C.runId)===G})}),M={in_progress:5,error:4,success:3,stopped:2,skipped:1,none:0},x=H(()=>y.value.map(G=>G.blueprintExecution).filter(Boolean).flatMap(G=>G.summary.filter(T=>T.componentId===u.value.id).filter(T=>!!T.outcome))),S=H(()=>{let K="none";for(const G of x.value)(M[G.outcome]??M.success)>M[K]&&(K=G.outcome);return K==="none"?null:K}),L=H(()=>r.isComponentIdSelected(s)),F=ye(!1),te=H(()=>!J.value||be.value?!1:!F.value),J=H(()=>{var K,G;return((G=(K=h.value)==null?void 0:K.outs)==null?void 0:G.error)!==void 0}),be=H(()=>{var G;return J.value?((G=u.value.outs)==null?void 0:G.some(T=>T.outId==="error"))?!0:F.value:!1}),oe=H(()=>!(Object.keys(Me.value??{}).length>0||Object.keys(Ue.value??{}).length>0||Object.keys(Te.value??{}).length>1)),Te=H(()=>Object.entries(h.value.outs??{}).reduce((K,[G,T])=>(T.style=="dynamic"||G==="error"&&!be.value||(K[G]=T),K),{}),{}),Ue=H(()=>{var G;const K=new Set([...Object.keys(Te.value),...Object.values(Me.value).flatMap(Object.keys)]);return(((G=u.value)==null?void 0:G.outs)??[]).reduce((T,{outId:O})=>{if(!K.has(O))return T[O]={name:O,style:"dynamic",description:""},T},{})});function Ze(K){const T=h.value.fields[K].type==Q.Tools,O=Object.keys(i[K].value??{});return T?O.filter(C=>{var P;return((P=i[K].value[C])==null?void 0:P.type)=="function"}):O}const Me=H(()=>{const K={};return Object.entries(h.value.outs??{}).forEach(([G,T])=>{if(T.style!=="dynamic")return;if(!T.field){K.default??(K.default={}),K.default[G]={...T};return}K[T.field]={},Ze(T.field).forEach(k=>{K[T.field][`${G}_${k}`]={name:k,description:"Dynamically created",style:"dynamic"}})}),K});We(Me,()=>{var T,O;const K=Object.values(Me.value).flatMap(Object.keys);(((O=(T=u.value)==null?void 0:T.outs)==null?void 0:O.filter(k=>!K.includes(k.outId)&&!(k.outId in Te.value)))??[]).forEach(k=>{u.value&&o(u.value.id,k)})},{immediate:!0});const ee=H(()=>{if(["success","error","skipped","stopped"].includes(m.value)){const G=`/status/${m.value}.svg`;return[Li(G)]}const K=[`/components/${u.value.type}.svg`,`/components/blueprints_category_${h.value.category}.svg`];return n.featureFlags.value.includes("custom_block_icons")&&K.unshift(`/static/components/${u.value.id}.svg`),K.map(G=>Li(G))});function j(){x.value.at(-1)&&(r.openPanels.value.add("log"),r.setSelection(s,void 0,"click"))}return We(L,()=>{a("engaged")}),(K,G)=>($(),R("div",{class:ft(["BlueprintsNode",{"BlueprintsNode--trigger":l.value,"BlueprintsNode--intelligent":c.value,"BlueprintsNode--deprecated":d.value,"BlueprintsNode--running":m.value=="running","BlueprintsNode--success":m.value=="success","BlueprintsNode--skipped":m.value=="skipped","BlueprintsNode--stopped":m.value=="stopped","BlueprintsNode--error":m.value=="error"}])},[c.value&&m.value===null?($(),R("div",w0e)):ge("",!0),Z("div",x0e,[m.value=="running"?($(),R("div",C0e)):ge("",!0)]),Z("div",A0e,[Z("div",S0e,[Ce(qg,{urls:ee.value,class:"icon","loader-max-width-px":24,"loader-max-height-px":24},null,8,["urls"]),Ce(r0e,{"component-id":E(s),class:"nodeNamer","block-name":f.value},null,8,["component-id","block-name"]),d.value?($(),R("div",$0e," Deprecated ")):ge("",!0),l.value?($(),Ie(Rm,{key:1,"show-display-error-option":te.value,onShowError:G[0]||(G[0]=T=>F.value=!0)},null,8,["show-display-error-option"])):ge("",!0)]),($(!0),R(Je,null,Ot(Me.value,(T,O)=>{var k,C,P,ae;return $(),R("div",{key:O,class:"BlueprintsNode__main__outputs"},[(k=E(h).fields)!=null&&k[O]?($(),R("h4",E0e,je(E(h).fields[O].name),1)):ge("",!0),($(!0),R(Je,null,Ot(T,(xe,ve)=>($(),Ie(rc,{key:ve,class:"BlueprintsNode__main__outputs__output","out-id":ve,out:xe,"display-label":"",onClick:ze=>K.$emit("outMousedown",ve)},null,8,["out-id","out","onClick"]))),128)),Ce(b0e,{"field-key":O,"field-type":((P=(C=E(h).fields)==null?void 0:C[O])==null?void 0:P.type)??"","field-value":(ae=E(i)[O])==null?void 0:ae.value,"has-outputs":Object.keys(T).length>0},null,8,["field-key","field-type","field-value","has-outputs"])])}),128)),Object.keys(Te.value).length>0?($(),R("div",{key:0,class:ft(["BlueprintsNode__main__outputs",{"BlueprintsNode__main__outputs--float":oe.value&&!l.value}])},[v.value?($(),R("h4",I0e,je(b.value),1)):ge("",!0),($(!0),R(Je,null,Ot(Te.value,(T,O)=>($(),Ie(rc,{key:O,class:"BlueprintsNode__main__outputs__output","out-id":O,out:T,"display-label":!oe.value,onClick:k=>K.$emit("outMousedown",O)},null,8,["out-id","out","display-label","onClick"]))),128)),($(!0),R(Je,null,Ot(Ue.value,(T,O)=>($(),Ie(rc,{key:O,class:"BlueprintsNode__main__outputs__output","out-id":O,out:T,"display-label":"",onClick:k=>K.$emit("outMousedown",O)},null,8,["out-id","out","onClick"]))),128))],2)):ge("",!0),l.value?ge("",!0):($(),R("div",k0e,[x.value.length>0?($(),Ie(g0e,{key:0,"completion-style":m.value,count:x.value.length,onClick:j},null,8,["completion-style","count"])):ge("",!0),Ce(Rm,{"show-display-error-option":te.value,onShowError:G[1]||(G[1]=T=>F.value=!0)},null,8,["show-display-error-option"])]))])],2))}}),L0e=ke(P0e,[["__scopeId","data-v-810cc87f"]]),V0e={class:"BlueprintsRoot","data-writer-container":""},O0e="The root component of the application, which serves as the starting point of the component hierarchy.",H0e={writer:{name:"Blueprints Root",toolkit:"blueprints",category:"Root",description:O0e,allowedChildrenTypes:["blueprints_blueprint"],fields:{}}},R0e=$e({...H0e,__name:"BlueprintsRoot",setup(e){const t=re(ne.core),a=re(ne.getChildrenVNodes),n=H(()=>{const r=t.activePageId.value;if(!!t.getComponentById(r)&&t.isChildOf("blueprints_root",r))return r;const s=t.getComponents("blueprints_root",{includeBMC:!0,includeCMC:!1,sortedByPosition:!0});return s.length==0?null:s[0].id});return ia(()=>{n.value&&t.activePageId.value!==n.value&&t.setActivePageId(n.value)}),(r,o)=>($(),R("div",V0e,[($(!0),R(Je,null,Ot(E(a)(),s=>($(),R(Je,{key:s.key},[s.key===`${n.value}:0`?($(),Ie(Ts(s),{key:0})):ge("",!0)],64))),128))]))}}),N0e=ke(R0e,[["__scopeId","data-v-367e0c79"]]),D0e={name:"Note",description:"Internal note displayed only in edit mode",category:"Internal",fields:{parentInstancePath:{name:"Parent's instance path",type:Q.Text},content:{name:"Content",type:Q.Text,control:Ui.Textarea},createdAt:{name:"Created At",type:Q.Text},createdBy:{name:"Created By",type:Q.Number}}},B0e={writer:D0e};function F0e(e,t,a,n,r,o){return ge("",!0)}const j0e=ke(B0e,[["render",F0e]]);let r8=[];function U0e(e){r8=e??[]}function o8(e){return!e||e.length===0?!0:e.some(t=>r8.includes(t))}const vl={root:R2e,page:$2e,sidebar:L1e,button:ple,text:qae,section:x1e,header:m1e,heading:rae,dataframe:Jte,html:Jg,pagination:Vle,repeater:Nle,column:o1e,columns:c1e,tab:N1e,tabs:W1e,link:rne,horizontalstack:M1e,separator:$1e,image:uae,pdf:s2e,iframe:f2e,googlemaps:_2e,mapbox:j2e,timer:Ule,textinput:bie,textareainput:Sie,numberinput:Fse,sliderinput:cie,rangeinput:vie,colorinput:Roe,dateinput:Uoe,timeinput:Pie,radioinput:Kse,checkboxinput:Eoe,dropdowninput:Joe,selectinput:Yse,multiselectinput:Hse,fileinput:_se,webcamcapture:Xle,vegalitechart:Kae,plotlygraph:Oae,metric:Tae,message:xae,videoplayer:Qae,chatbot:are,step:ele,steps:ile,ratinginput:Fie,tags:ure,switchinput:Zie,reuse:Qle,avatar:Mre,annotatedtext:xre,jsonviewer:soe,blueprints_root:N0e,blueprints_blueprint:Qce,progressbar:yoe,note:j0e},wi=Ri({});function Nm(e){const t=`Component type "${e}" not supported. If it's a custom component, please ensure it's been loaded.`;return{writer:{name:"Fallback Component",allowedChildrenTypes:["*"],description:t,category:"Fallback"},setup(a,{slots:n}){return()=>En("div",{"data-writer-container":"",style:{color:"var(--primaryTextColor)"}},[t,n.default({})])}}}function z0e(e){var r,o;const t={blueprints_node:L0e},a=wi[e];if(!a)return;const n=a.baseType;return{...t[n],writer:{...t[n].writer,...wi[e].writer,fields:{...(r=t[n].writer)==null?void 0:r.fields,...(o=wi[e].writer)==null?void 0:o.fields}}}}function q0e(e){var n;const t=z0e(e)??vl[e]??Nm(e),a=(n=t==null?void 0:t.writer)==null?void 0:n.featureFlags;return o8(a)?t:Nm(e)}function Vi(e){var t;return(t=q0e(e))==null?void 0:t.writer}function Rd(){return[...Object.keys(vl),...Object.keys(wi)].filter(t=>{var n,r;const a=(r=(n=vl[t])==null?void 0:n.writer)==null?void 0:r.featureFlags;return o8(a)})}function W0e(e,t){vl[e]=t}function Z0e(e,t){wi[e]=t}function K0e(e){let t=!1;return J0e(e),Object.entries(e).forEach(([,a])=>{t=Q0e(a,e)||t,t=G0e(a)||t}),t}function G0e(e){const t=fa(),a=Vi(e.type);if(!a||a.category=="Fallback")return t.error(`Component ${e.id} (${e.type}). Invalid component type.`),!1;let n=!1;return n=ade(e),n=tde(e)||n,X0e(e,a),Y0e(e,a),n}function Uc(e,t,a={}){a[e]=!0,Object.entries(t).filter(([,n])=>n.parentId===e).forEach(([n])=>Uc(n,t,a))}function J0e(e){const t=fa(),a=Object.fromEntries(Object.entries(e).map(([n])=>[n,!1]));Uc("root",e,a),Uc("blueprints_root",e,a),Object.entries(a).forEach(([n,r])=>{r||t.warn(`Component ${n} (${e[n].type}). Orphan component.`)})}function X0e(e,t){const a=fa(),n=Object.keys(t.fields??{});e.content&&Object.keys(e.content).forEach(r=>{n.includes(r)||a.warn(`Component ${e.id} (${e.type}). Field key "${r}" is defined in the component but not in the template.`)})}function Y0e(e,t){const a=Object.keys(t.events??{});if(!e.binding)return;const n=e.binding.eventType;if(a.includes(n)&&t.events[n].bindable)return;fa().warn(`Component ${e.id} (${e.type}). The component is bound to event "${e.binding.eventType}" but the template doesn't define that event or it's not bindable.`)}function Q0e(e,t){const a=fa();let n=!1;e.id=="root"&&e.position!==0&&a.error("Root must be at position 0."),e.position==-1&&a.error(`Component ${e.id} (${e.type}). Invalid position.`);const r=Object.values(t).filter(i=>i.parentId===e.id&&i.position!==-2&&!i.isCodeManaged);let o=0;return r.forEach(i=>{o+=i.position}),(r.length-1)*r.length/2!==o&&(a.error(`Component ${e.id} (${e.type}). Invalid children positions. Automated fix will be applied.`),ede(r),n=!0),n}function ede(e){e.sort((t,a)=>t.position>a.position?1:-1),e.map((t,a)=>{t.position=a})}function tde(e){var a,n,r;let t=!1;if(Object.keys(e.handlers??{}).forEach(o=>{if(!o.startsWith("ss-"))return;const s=`wf-${o.substring(3)}`;e.handlers[s]=e.handlers[o],t=!0,delete e.handlers[o]}),(n=(a=e.binding)==null?void 0:a.eventType)!=null&&n.startsWith("ss-")){const s=`wf-${((r=e.binding)==null?void 0:r.eventType).substring(3)}`;e.binding.eventType=s,t=!0}return t}function ade(e,t){let a=!1;if(e.type=="column"){if("horizontalAlignment"in e.content){const n={left:"start",center:"center",right:"end"};e.content.contentHAlign=n[e.content.horizontalAlignment]||e.content.horizontalAlignment,delete e.content.horizontalAlignment,a=!0}if("verticalAlignment"in e.content){const n={normal:"unset",top:"start",center:"center",bottom:"end"};e.content.contentVAlign=n[e.content.verticalAlignment]||e.content.verticalAlignment,delete e.content.verticalAlignment,a=!0}}else if(e.type=="horizontalstack"){if("alignment"in e.content){const n={left:"start",center:"center",right:"end"};e.content.contentHAlign=n[e.content.alignment]||e.content.alignment,delete e.content.alignment,a=!0}}else e.type=="section"&&"snapMode"in e.content&&(delete e.content.snapMode,a=!0);return a}function nde(e){let t="";const a=[];let n=!1;for(let o=0;o<e.length;o++){const s=e[o];if(s==="."&&!n){a.push(t),t="";continue}t+=s,s==="\\"?n=!0:n=!1}return a.push(t),a.map(o=>o.replaceAll("\\.","."))}const rde="WriterCustomComponentTemplates";async function ode(e){await Promise.all(e.map(async t=>{const a=t.toLocaleLowerCase();a.endsWith(".js")?await sde(t):a.endsWith(".css")&&lde(t)}))}async function sde(e){var a;const t=fa();t.log(`Importing custom component templates at "${e}"...`),await zt(()=>import(s8()+e),[],import.meta.url),(a=Object.entries(window[rde]))==null||a.forEach(([n,r])=>{ide(n)?(W0e(`custom_${n}`,r),t.log(`Registering template for "${n}".`)):t.warn(`custom component '${n}' is ignored. A custom component should be declared using only alphanumeric lowercase and _.`)})}function ide(e){return/^[a-z0-9_]+$/.test(e)}function lde(e){const t=document.createElement("link");t.rel="stylesheet",t.href=s8()+e,document.head.appendChild(t)}function s8(){let e=window.location.pathname;return e.endsWith("/")||(e+="/"),`${e}extensions/`}function cde(e){return new Promise((t,a)=>{const n=new FileReader;n.onload=()=>{t(n.result)},n.onerror=r=>{a(r)},n.readAsArrayBuffer(e)})}async function dde(e){const t=await cde(e);if(!t)return;const a=new TextDecoder("utf-8");return JSON.parse(a.decode(t))}function ude(e,t){const a=URL.createObjectURL(e);try{const n=document.createElement("a");n.href=a,n.download=t,document.body.appendChild(n),n.click(),document.body.removeChild(n)}finally{URL.revokeObjectURL(a)}}function Ude(e,t){const a=JSON.stringify(e,null,2),n=new Blob([a],{type:"application/json"});ude(n,t)}const i8=5e3,oc=5;function hde(e){return typeof e!="object"||e===null?!1:e.type==="file"&&typeof e.content=="string"}function zde(e){return typeof e!="object"||e===null?!1:e.type==="binary"}function Fs(e){return typeof e!="object"||e===null?!1:e.type==="directory"&&typeof e.children=="object"}function*pde(e,t=[]){if(!Fs(e)){yield t;return}for(const[a,n]of Object.entries(e.children))yield*pde(n,[...t,a])}function*fde(e,t=[]){if(yield t,!!Fs(e))for(const[a,n]of Object.entries(e.children))yield*fde(n,[...t,a])}function Nd(e,t){if(e.length===0)return t;if(!Fs(t))return;const[a,...n]=e,r=t.children[a];return n.length===0?r:Nd(n,r)}function zc(e,t,a={type:"file",content:"",complete:!0}){var o;const n=structuredClone(t);let r=n;for(let s=0;s<e.length;s++){if(!Fs(r))return n;const i=e.at(s);if(s===e.length-1)return r.children[i]=a,n;(o=r.children)[i]??(o[i]={type:"directory",children:{}}),r=r.children[i]}return n}function mde(e,t,a){const n=Nd(e,a);if(Fs(n)||n===void 0)return a;const r=l8(e,a);return zc(t,r,structuredClone(n))}function l8(e,t){return c8(e,structuredClone(t))}function c8(e,t){if(!Fs(t)||!(e.at(0)in t.children))return t;if(e.length===1)return delete t.children[e.at(0)],t;const a=c8(e.slice(1),t.children[e.at(0)]);return a.type==="directory"&&Object.keys(a.children).length===0&&delete t.children[e.at(0)],t}const vde=6e4;function gde(){let e=null;const t=ye(null),a=ye(null),n=ye(),r=$t([]),o=ye(null),s=$t({type:"directory",children:{}}),i=ye({}),l=ye([]),c=ye({}),d=ye({});let u;const h=ye("idle");let f=0;const m=ye(new Map);let g=[],_=[];const b=[];let v=!1;const y=ye(),M=H(()=>{var ie;return Number((ie=n.value)==null?void 0:ie.organizationId)||void 0}),x=H(()=>{var ie;return(ie=n.value)==null?void 0:ie.id}),S=H(()=>{var ie;return(ie=n.value)==null?void 0:ie.apiKey}),L=H(()=>{var ie;return((ie=n.value)==null?void 0:ie.baseUrl)??"https://api.writer.com"}),F=H(()=>!!(x.value||M.value));async function te(){await J(),oe(),a.value=="edit"}async function J(){Ze();let ie=null,Ee=null;try{Ee=await fetch("./api/init",{method:"post",cache:"no-store",headers:{"Content-Type":"application/json"},body:JSON.stringify({proposedSessionId:e})});const Pe=await Ee.text();ie=JSON.parse(Pe)}catch{throw new Error(`Failed to acquire initialization data. Server responded with ${(Ee==null?void 0:Ee.status)??"no response"} status.`)}if(Ee.status>400)throw"Connection rejected.";ie.extensionPaths&&await ode(ie.extensionPaths),a.value=ie.mode,i.value=ie.components,d.value=ie.userState,c.value=structuredClone(ie.userState),j(ie.mail),e=ie.sessionId,t.value=new Date().getTime(),r.value=ie.featureFlags,U0e(r.value),n.value=ie.writerApplication,be(ie.abstractTemplates),l.value=ie.userFunctions,o.value=ie.runCode,s.value=ie.sourceFiles,await Me(),!(a.value!="edit"||!K0e(ie.components))&&await pe()}function be(ie){Object.entries(ie??{}).forEach(([Ee,Oe])=>{Z0e(Ee,Oe)})}function oe(){setTimeout(()=>{me("keepAlive",{},oe)},vde)}function Te(ie){ie&&Object.entries(ie).forEach(([Ee,Oe])=>{const Pe=Ee.charAt(0),Ke=nde(Ee.substring(1)),it=Ke.length-1;let ht=d.value;const Ft=Pe==="-";for(let ma=0;ma<it;ma++){const Wt=ht==null?void 0:ht[Ke[ma]];typeof Wt=="object"&&Wt!==null?ht=Wt:Ft||(ht[Ke[ma]]={},ht=ht[Ke[ma]])}Ft?delete ht[Ke.at(-1)]:ht[Ke.at(-1)]=Oe})}function Ue(ie){ie&&(i.value=ie)}function Ze(){m.value.forEach(({callback:ie})=>{ie==null||ie({ok:!1})}),m.value.clear()}async function Me(){if(u&&h.value==="connected")return;const ie=fa(),Ee=new URL("./api/stream",window.location.href);Ee.protocol=Ee.protocol.replace("https","wss"),Ee.protocol=Ee.protocol.replace("http","ws"),u=new WebSocket(Ee.href),u.onopen=()=>{h.value="connected",ie.log("WebSocket connected. Initialising stream..."),me("streamInit",{sessionId:e}),v&&(v=!1,pe().catch(Pe=>{ie.error("Failed to retry component update after reconnect:",Pe),v=!0}))};function Oe(Pe){var it,ht,Ft,ma;if(Pe.messageType=="announcement"&&Pe.payload.type=="codeUpdate"){u.close(),J();return}if(Pe.messageType=="announcement"&&Pe.payload.type=="collaborationUpdate"){b.forEach(Wt=>Wt.fn(Pe.payload.payload));return}if(Pe.messageType=="announcement"&&Pe.payload.type=="componentUpdate"){const Wt={};Object.entries(i.value).forEach(([ln,Pr])=>{Pr.isCodeManaged&&(Wt[ln]=Pr)}),i.value={...Wt,...Pe.payload.payload};return}if(Pe.messageType=="announcement"&&Pe.payload.type=="mail"){j(Pe.payload.payload);return}(Pe.messageType=="eventResponse"||Pe.messageType=="stateEnquiryResponse")&&(Te((it=Pe.payload)==null?void 0:it.mutations),j((ht=Pe.payload)==null?void 0:ht.mail),Ue((Ft=Pe.payload)==null?void 0:Ft.components));const Ke=m.value.get(Pe.trackingId);(ma=Ke==null?void 0:Ke.callback)==null||ma.call(Ke,{ok:!0,payload:Pe.payload}),m.value.delete(Pe.trackingId)}return u.onmessage=async Pe=>{let Ke;try{Pe.data instanceof Blob?Ke=await dde(Pe.data):Ke=JSON.parse(Pe.data)}catch(it){ie.error("Error parsing WebSocket message:",it);return}try{Oe(Ke)}catch(it){ie.error("Error processing WebSocket message:",it)}},u.onclose=async Pe=>{if(u=null,Pe.code==1008){h.value="offline",ie.error("Invalid session. Reinitialising..."),await J();return}Pe.code==4001?(h.value="suspended",ie.info("WebSocket closed due to code update. Attempting to reconnect...")):(h.value="offline",ie.error(`WebSocket closed with code ${Pe.code}. Attempting to reconnect...`)),setTimeout(async()=>{try{await Me(),ie.info("Reconnected.")}catch{ie.error("Couldn't reconnect.")}},i8)},new Promise((Pe,Ke)=>{u.addEventListener("open",()=>Pe(),{once:!0}),u.addEventListener("close",()=>{Ke(new Error("WebSocket connection closed before establishing."))},{once:!0})})}function ee(ie=1e3){u&&(u.onclose=()=>{},u.close(ie),h.value="offline")}function j(ie=[]){g.push(...ie),g=g.filter(Ee=>{const Oe=_.filter(Pe=>Pe.mailType==Ee.type);if(Oe.length==0)return Ee;Oe.forEach(Pe=>Pe.fn(Ee.payload))})}function K(ie){b.push({fn:ie})}function G(ie,Ee){_.push({mailType:ie,fn:Ee}),j()}function T(ie,Ee){_=_.filter(Oe=>!(Oe.mailType===ie&&Oe.fn===Ee))}function O(ie){var Oe;let Ee=null;if(ie instanceof CustomEvent)Ee=((Oe=ie.detail)==null?void 0:Oe.payload)??null;else{const Pe={};for(const Ke in ie){const it=ie[Ke];typeof it!="function"&&(it instanceof Object||(Pe[Ke]=it))}Ee=Pe}return Ee}async function k(ie,Ee,Oe){var Ft,ma;const Pe=Oe?O(ie):null;let Ke,it;ie instanceof CustomEvent&&(Ke=(Ft=ie.detail)==null?void 0:Ft.callback,it=(ma=ie.detail)==null?void 0:ma.handler),me("event",async()=>({type:ie.type,instancePath:Ee,handler:it,payload:await Pe}),Ke,!0)}async function C(ie){return new Promise(Ee=>{me("collaborationPing",ie,()=>{Ee()})})}async function P(ie){return new Promise((Ee,Oe)=>{me("hashRequest",{message:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");Ee((it=Ke.payload)==null?void 0:it.message)})})}function ae(ie,Ee){const Oe=structuredClone(St(s.value)),Pe=Nd(Ee,Oe);hde(Pe)&&(Pe.content=ie,Pe.complete=!0,s.value=Oe)}async function xe(ie){return new Promise((Ee,Oe)=>{me("createSourceFile",{path:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");if((it=Ke.payload)!=null&&it.error)return Oe("Couldn't create the file.");s.value=zc(ie,St(s.value)),Ee()})})}async function ve(ie,Ee){return new Promise((Oe,Pe)=>{me("uploadSourceFile",{path:ie,content:Ee},it=>{var ht,Ft;if(!it.ok)return Pe("Couldn't connect to the server.");if((ht=it.payload)!=null&&ht.error)return Pe("Couldn't upload the file.");s.value=((Ft=it.payload)==null?void 0:Ft.sourceFiles)??zc(ie,St(s.value)),Oe()})})}async function ze(ie,Ee){return new Promise((Oe,Pe)=>{me("renameSourceFile",{from:ie,to:Ee},it=>{var ht;if(!it.ok)return Pe("Couldn't connect to the server.");if((ht=it.payload)!=null&&ht.error)return Pe("Couldn't rename the file.");s.value=mde(ie,Ee,St(s.value)),Oe()})})}async function Ye(ie){return new Promise((Ee,Oe)=>{me("deleteSourceFile",{path:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");if((it=Ke.payload)!=null&&it.error)return Oe("Couldn't delete the file.");s.value=l8(ie,St(s.value)),Ee()})})}async function ct(ie,Ee=["main.py"]){return new Promise((Oe,Pe)=>{me("codeSaveRequest",{code:ie,path:Ee},it=>{if(!it.ok)return Pe("Couldn't connect to the server.");ae(ie,Ee),Oe()}),Ee.join("/")==="main.py"&&(h.value="suspended")})}function wt(ie){return new Promise((Ee,Oe)=>{me("loadSourceFile",{path:ie},Ke=>{if(!Ke.ok)return Oe("Couldn't connect to the server.");ae(Ke.payload.content,ie),Ee()})})}async function D(ie){return new Promise((Ee,Oe)=>{me("listResources",{resource_type:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");Ee(((it=Ke.payload)==null?void 0:it.data)??[])})})}async function q(ie){me("stateEnquiry",{},ie,!0)}function he(ie){const Pe=(Ke=0)=>{const it=m.value.get(ie);it!==void 0&&(Ke==0&&it.type=="stateEnquiry"||q(()=>setTimeout(()=>Pe(Ke+1),150)))};setTimeout(()=>Pe(0),150)}async function me(ie,Ee,Oe,Pe=!1){if(h.value=="offline"||h.value=="suspended"){Oe==null||Oe({ok:!1});return}const Ke=fa(),it=f++;try{(Oe||Pe)&&m.value.set(it,{type:ie,callback:Oe}),Pe&&he(it);let ht;typeof Ee=="function"?ht=await Ee():ht=Ee;const Ft={type:ie,trackingId:it,payload:ht};if(u.readyState!==WebSocket.OPEN)throw"Connection lost.";u.send(JSON.stringify(Ft,G3))}catch(ht){Ke.error("sendFrontendMessage error",ht),Oe==null||Oe({ok:!1})}}function _e(ie){delete i.value[ie]}function Ae(ie){i.value[ie.id]=ie}async function pe(){const ie={};Object.entries(i.value).forEach(([Oe,Pe])=>{Pe.isCodeManaged||(ie[Oe]=Pe)});const Ee={components:ie};return new Promise((Oe,Pe)=>{me("componentUpdate",Ee,it=>{if(!it.ok)return v=!0,Pe("Couldn't connect to the server.");Oe()})})}async function ce(){return new Promise((ie,Ee)=>{me("writerVaultUpdate",{},Pe=>{if(!Pe.ok)return Ee("Couldn't connect to the server.");ie()})})}function ue(ie){return i.value[ie]}function I(ie,Ee){let Oe=i.value[Ee];do{if(Oe.parentId==ie)return!0;Oe=i.value[Oe.parentId]}while(Oe);return!1}function B(ie,{includeBMC:Ee=!0,includeCMC:Oe=!0,sortedByPosition:Pe=!1}={}){let Ke=Object.values(i.value);return typeof ie<"u"&&(Ke=Ke.filter(it=>it.parentId==ie)),Ke=Ke.filter(it=>{const ht=it.isCodeManaged;return Ee&&!ht||Oe&&ht}),Pe&&(Ke=Ke.sort((it,ht)=>it.isCodeManaged&&!ht.isCodeManaged?1:!it.isCodeManaged&&ht.isCodeManaged?-1:it.position>ht.position?1:-1)),Ke}function*N(ie,Ee={}){for(const Oe of B(ie,Ee))yield Oe,yield*N(Oe.id,Ee)}function U(ie){const Oe=B("root").filter(Pe=>Pe.content.key==ie);Oe.length!=0&&se(Oe[0].id)}function se(ie){y.value=ie}function Se(ie){return Ld(i.value,ie)}function Ne(){return u}return{webSocket:u,syncHealth:h,frontendMessageMap:jt(m),mode:jt(a),userFunctions:jt(l),addMailSubscription:G,removeMailSubscription:T,addCollaborationPingSubscription:K,init:te,forwardEvent:k,hashMessage:P,runCode:jt(o),sourceFiles:jt(s),sendCodeSaveRequest:ct,sendCreateSourceFileRequest:xe,sendRenameSourceFileRequest:ze,sendDeleteSourceFileRequest:Ye,sendFileUploadRequest:ve,requestSourceFileLoading:wt,sendListResourcesRequest:D,sendComponentUpdate:pe,sendWriterVaultUpdate:ce,sendCollaborationPing:C,addComponent:Ae,deleteComponent:_e,getComponentById:ue,getComponents:B,getComponentsNested:N,setActivePageId:se,activePageId:jt(y),setActivePageFromKey:U,getComponentDefinition:Vi,getSupportedComponentTypes:Rd,getContainableTypes:Se,sessionTimestamp:jt(t),userState:jt(d),userStateInitial:jt(c),isChildOf:I,featureFlags:jt(r),getWebSocket:Ne,stopSync:ee,writerApplication:jt(n),isWriterCloudApp:F,writerOrgId:M,writerAppId:x,writerApiKey:S,writerBaseUrl:L}}const yde=2e3,Mde=1e3,_de=5e3;function bde(e){const t=ye({});let a=null,n=null;const r=ye({}),o=ye(null),s=ye({}),i=ye([]),{writerApi:l}=io(),c=H(()=>{const b={};return i.value.forEach(v=>{var x,S;const y=v.userId;(((S=(x=r.value[y])==null?void 0:x.selection)==null?void 0:S.map(L=>L.instancePath))??[]).forEach(L=>{b[L]=[...b[L]??[],y]})}),b});function d(b){const v=b.userId;if(v!=null){if(b.action=="leave"){delete r.value[v];return}r.value={...r.value,[v]:b}}}function u(b,v,y){return b||v?`${b} ${v}`:y||"Unknown"}async function h(b){const v=s.value[b];if(v)return v;const y=await l.fetchThirdUserProfile(b),M=u(y.firstName,y.lastName,y.email);return s.value[b]={userId:b,displayName:M,avatar:y.avatar,email:y.email},s.value[b]}async function f(){const v=Object.keys(r.value).map(y=>h(parseInt(y)));return Promise.all(v)}async function m(){clearTimeout(n);const b=[];Object.keys(r.value).forEach(v=>{var x;const y=(x=r.value[v])==null?void 0:x.time;if(!y)return;Date.now()-new Date(y).getTime()>_de&&b.push(v)}),b.forEach(v=>delete r.value[v]),i.value=await f(),n=setTimeout(m,Mde)}function g(b){t.value={...t.value,...b}}function _(){e.sendCollaborationPing({userId:o.value,action:"auto",time:new Date,...t.value}),t.value.action="auto",clearTimeout(a),a=setTimeout(_,yde)}return{groomSnapshot:m,updateOutgoingPing:g,sendCollaborationPing:_,handleIncomingCollaborationUpdate:d,connectedProfiles:i,connectedUsersByInstancePath:c}}let Dm;async function qc(e=io().writerApi){return Dm??(Dm=e.fetchUserProfile()),await Dm}function qde(e=io().writerApi){const t=$t(),a=$t(),n=ye(!1);async function r(){a.value=void 0,n.value=!0;try{t.value=await qc(e)}catch(o){a.value=o,t.value=void 0}finally{n.value=!1}}return ia(r),{user:jt(t),isLoading:jt(n),error:jt(a)}}const L1={};function Wde(e,t=io().writerApi){const a=$t(),n=$t(),r=ye(!1);async function o(s){n.value=void 0,r.value=!0;try{L1[s]??(L1[s]=t.fetchUserById(s)),a.value=await L1[s]}catch(i){n.value=i,a.value=void 0}finally{r.value=!1}}return We(e,o,{immediate:!0}),{user:jt(a),isLoading:jt(r),error:jt(n)}}function wde(e,t){const a=Od(),{removeComponentSubtree:n,generateNewComponentId:r}=Bs(e,t),o=ye(!1),s=ye(),i=ye("show"),l=ye(),c=$t(),d=H(()=>s.value?y(s.value):void 0);async function u(S){const L=x(S).createdBy.value,F=await qc();return L===F.id}async function h(S,L="show"){if(S===void 0){c.value=void 0,s.value=void 0,i.value="show";return}if(L==="edit"){const F=y(S);if(!await u(F))return a.pushToast({type:"error",message:"You cannot edit this note because it was created by another user"})}i.value=L,s.value=S,f(S)}function f(S){let L=e.getComponentById(S);for(;L;){switch(L.type){case"blueprints_root":t.mode.value="blueprints";break;case"root":t.mode.value="ui";break;case"blueprints_blueprint":case"page":e.setActivePageId(L.id);break}L=e.getComponentById(L.parentId)}}async function m(S,L){let F;"instancePath"in L&&(F=typeof L.instancePath=="string"?L.instancePath:a8(L.instancePath));const te=await qc(),J=r();return c.value={id:J,type:"note",parentId:S,content:{parentInstancePath:F,content:"",createdBy:String(te.id),createdAt:new Date().toISOString()},x:"x"in L?L.x:void 0,y:"y"in L?L.y:void 0},await h(J,"edit"),J}We(s,()=>{c.value&&c.value.id!==s.value&&(c.value=void 0)});async function g(S){const L=y(S);if(!await u(L))return a.pushToast({type:"error",message:"You cannot delete this note because it was created by another user"});h(void 0),n(S)}function*_(){yield*v("root"),yield*v("blueprints_root")}function*b(S){if(!S){yield*_();return}const L=S.toLocaleLowerCase();for(const F of _()){if(!F.content.content)continue;String(F.content.content).toLocaleLowerCase().includes(L)&&(yield F)}}function*v(S){var L;for(const F of e.getComponentsNested(S))F.type==="note"&&(yield F);if(c.value){let F=c.value.parentId;for(;F;){if(F===S){yield jt(c.value);return}F=(L=e.getComponentById(F))==null?void 0:L.parentId}}}function y(S){var F;const L=e.getComponentById(S);if((L==null?void 0:L.type)==="note")return L;if(((F=c.value)==null?void 0:F.id)===S)return jt(c.value)}const M=S=>{var L;return String(((L=S.content)==null?void 0:L.content)??"")};function x(S){const L=new Intl.DateTimeFormat(void 0,{dateStyle:"short",timeStyle:"short"}),F=H(()=>{var K,G,T;const Me=(K=E(S))==null?void 0:K.id,ee=(G=E(S))==null?void 0:G.content;return l.value===Me?"hover":((T=d.value)==null?void 0:T.id)===Me?ee.content?"active":"new":"default"}),te=H(()=>M(E(S))),J=H(()=>E(S).content.createdAt),be=H(()=>E(S).content.parentInstancePath),oe=H(()=>{var ee;const Me=(ee=E(S).content)==null?void 0:ee.createdBy;return Me?Number(Me):void 0}),Te=H(()=>{if(!J.value)return"";const Me=new Date(J.value);return L.format(Me)}),Ue=H(()=>Ze(E(S).id)==="blueprints_root"?"blueprints":"ui");function Ze(Me){const ee=e.getComponentById(Me);return ee?Ze(ee.parentId)??Me:Me}return{content:te,type:Ue,createdBy:oe,createdAt:J,createdAtFormatted:Te,state:F,parentInstancePath:be}}return{isAnnotating:o,createNote:m,getNotes:v,selectNote:h,searchNotes:b,getAllNotes:_,deleteNote:g,selectedNoteId:jt(s),selectedNoteMode:jt(i),selectedNote:d,hoveredNoteId:l,useNoteInformation:x,getNoteContent:M}}function xde(e){const t="vault",a=$t({}),n=ye(!1),r=ye(!1),o=ye(!1),{writerApi:s}=io();async function i(){try{return(await s.fetchSecret(e.writerOrgId.value,e.writerAppId.value,t)).secret}catch{return}}async function l(){if(e.isWriterCloudApp.value){n.value=!0,o.value=!1;try{const d=await i();a.value=d??{}}finally{n.value=!1}}}async function c(d){if(!e.isWriterCloudApp.value)return;r.value=!0,o.value=!1;const u=await i();try{u===void 0?await s.createSecret(e.writerOrgId.value,e.writerAppId.value,t,d):await s.updateSecret(e.writerOrgId.value,e.writerAppId.value,t,d),a.value=d}catch(h){o.value=h}finally{r.value=!1}}return{secrets:a,load:l,readonly:H(()=>n.value||r.value),isLoading:jt(n),isSaving:jt(r),update:c}}function Cde(e){const t=fa();async function a(){if(!e.isWriterCloudApp.value){t.log("Skipping config.js load - not a Writer Cloud App");return}if(!(typeof window<"u"&&window.__WRITER_APP_CONFIG__))try{const{writerApi:n}=io(),r=await n.fetchConfigJs(),o=document.createElement("script");o.textContent=r,document.head.appendChild(o)}catch(n){t.warn("Failed to load config.js via WriterApi ",n)}}return{loadConfigJs:a}}const _n=gde();globalThis.vue=aw;globalThis.injectionKeys=ne;globalThis.core=_n;const Kr=fa();async function Ade(){await _n.init();const e=_n.mode.value,t=e=="edit"?Ow():void 0,a=wde(_n,t),n=e=="edit"?xde(_n):void 0,r=e=="edit"?bde(_n):void 0;t&&(_n.addMailSubscription("logEntry",t.handleLogEntry),_n.addCollaborationPingSubscription(r.handleIncomingCollaborationUpdate),globalThis.wfbm=t),Kr.log(`Mounting app in mode ${e}...`);const{default:o}=e==="run"&&await zt(()=>import("./ComponentRenderer-DRTUw3PP.js"),__vite__mapDeps([18,19]),import.meta.url),{default:s}=e==="edit"&&await zt(()=>import("./BuilderApp-CXGhU9Dc.js").then(c=>c.c),__vite__mapDeps([20,5,6,21,22]),import.meta.url),i=rl(o||s);i.use(Aw),i.provide(ne.core,_n),i.provide(ne.builderManager,t),i.provide(ne.notesManager,a),i.provide(ne.collaborationManager,r),i.provide(ne.secretsManager,n),i.mount("#app");const{loadConfigJs:l}=Cde(_n);l().catch(Kr.error),_n.isWriterCloudApp.value&&r&&await Sde(r).catch(Kr.error),_n.isWriterCloudApp.value&&n&&n.load().catch(Kr.error)}async function Sde(e){const{writerApi:t}=io(),a=await t.fetchUserProfile();e.updateOutgoingPing({userId:a.id,action:"join"}),e.sendCollaborationPing(),e.groomSnapshot(),window.addEventListener("beforeunload",function(){e.updateOutgoingPing({action:"leave"}),e.sendCollaborationPing()})}async function $de(){var e;for(let t=0;t<oc;t++)try{await Ade();return}catch(a){if(t<oc-1){if(Kr.warn(`Core initialization failed (attempt ${t+1}/${oc}). Retrying...`,a),document.getElementById("loading_L1")&&!document.getElementById("loading_message")&&t>=2){const r=document.createElement("div");r.id="loading_message",r.textContent=`We're getting things ready.
8525
- Hang tight while we connect...`,r.style.cssText="position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);margin-top:120px;text-align:center;font-family: 'Poppins','Helvetica Neue','Lucida Grande',sans-serif;color:#666;font-size:14px;line-height:1.4;max-width:400px;padding:0 20px;z-index:1000;white-space:pre-line;opacity:0;transition:opacity 0.5s ease-in;",(e=document.getElementById("loading_L1"))==null||e.appendChild(r),setTimeout(()=>{r.style.opacity="1"},50)}await new Promise(r=>setTimeout(r,i8*(t+1)));continue}throw a}}Kr.log("Initialising core...");$de().then(async()=>{Kr.log("Core initialised.")}).catch(e=>{Kr.error("Core initialisation failed.",e);const t=document.createElement("div");t.className="error-message",t.setAttribute("role","alert"),t.style.cssText='padding: 20px; color: #d32f2f; background: #ffebee; border: 1px solid #e57373; border-radius: 4px; margin: 20px; font-family: "Poppins", "Helvetica Neue", "Lucida Grande", sans-serif;';const a=document.createElement("div");a.textContent="Failed to initialise application"+(e!=null&&e.message?`: ${e.message}`:"");const n=document.createElement("div");n.style.marginTop="12px",n.textContent="This might mean the Agent Builder is still being prepared. Try reloading the page in a few seconds.";const r=document.createElement("button");r.textContent="Reload page",r.className="WdsButton WdsButton--small WdsButton--tertiary",r.style.cssText="margin-top: 16px; font-size: .875rem; font-weight: 600; border-radius: 300px; padding: 4px 16px; height: 32px; background: var(--wdsColorWhite); color: var(--wdsColorBlack); border-color: var(--wdsColorGray2); border-width: 1px; border-style: solid; box-shadow: var(--buttonShadow); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; outline: none; position: relative; overflow: hidden; max-width: 100%; width: fit-content;",r.onclick=()=>window.location.reload(),t.appendChild(a),t.appendChild(n),t.appendChild(r);const o=document.getElementById("loading_L1");o==null||o.remove();const s=document.getElementById("loading_message");s&&s.remove(),document.body.appendChild(t)});export{fa as $,pa as A,Sd as B,Td as C,Je as D,Ot as E,ot as F,ft as G,Ode as H,ks as I,qt as J,bt as K,qa as L,T2e as M,Rde as N,I2e as O,Bde as P,zt as Q,E as R,ge as S,jg as T,Ki as U,Od as V,La as W,io as X,$t as Y,jt as Z,ke as _,ne as a,b0 as a$,Wde as a0,$0 as a1,t8 as a2,Sg as a3,Lg as a4,Ice as a5,bs as a6,ba as a7,Wn as a8,fl as a9,Y_ as aA,_0 as aB,e0e as aC,Sw as aD,Vd as aE,Ad as aF,Ub as aG,a0 as aH,Fde as aI,mn as aJ,t_ as aK,oce as aL,J2e as aM,Pw as aN,E0 as aO,Bi as aP,Xx as aQ,c6 as aR,Dx as aS,Dde as aT,K3 as aU,Sv as aV,one as aW,Pd as aX,jde as aY,gte as aZ,kde as a_,Wr as aa,hse as ab,_v as ac,Fc as ad,St as ae,pde as af,Nd as ag,Fs as ah,zde as ai,zc as aj,hde as ak,fde as al,l8 as am,Fn as an,sr as ao,ir as ap,sn as aq,Sr as ar,Sse as as,Ht as at,o_ as au,O_ as av,fg as aw,Bs as ax,Hv as ay,qde as az,Ie as b,Tde as b0,Pde as b1,Ir as b2,Ui as b3,Moe as b4,Ug as b5,Ts as b6,Q as b7,Lde as b8,Vde as b9,i0e as bA,zE as ba,YE as bb,c0e as bc,ls as bd,ji as be,e8 as bf,o0e as bg,n8 as bh,Ew as bi,Ed as bj,zg as bk,qg as bl,Li as bm,Ude as bn,m0 as bo,Ev as bp,Mg as bq,Rd as br,Vi as bs,Nde as bt,Yg as bu,mg as bv,gn as bw,iv as bx,cv as by,Hde as bz,H as c,$e as d,L0e as e,R as f,Z as g,q0e as h,re as i,a8 as j,En as k,Kl as l,pt as m,Ri as n,$ as o,Bv as p,ia as q,ye as r,Ya as s,je as t,Hd as u,jn as v,We as w,Ce as x,_t as y,Xe as z};
8524
+ </example>`.trim();Gce(Ve)}function ln(fe){J.value=Math.max(Math.min(xo.maxLevel,fe),xo.minLevel)}function Lr(fe){ln(fe)}function kn(fe,Le){F.value={x:Math.max(0,fe),y:Math.max(0,Le)}}function co(fe){kn(F.value.x+fe.deltaX*pe.value,F.value.y+fe.deltaY*pe.value)}function No(fe){const Le=.006666666666666667,Re=u.value.getBoundingClientRect(),Ve=J.value;J.value=Math.min(Math.max(J.value-fe.deltaY*Le,xo.minLevel),xo.maxLevel);const Ge={w:Re.width*(1/Ve)*pe.value*(J.value-Ve),h:Re.height*(1/Ve)*pe.value*(J.value-Ve)},dt={x:(fe.pageX-Re.x)/Re.width,y:(fe.pageY-Re.y)/Re.height};kn(F.value.x+Ge.w*dt.x,F.value.y+Ge.h*dt.y)}async function Do(fe){if(fe.preventDefault(),!fe.ctrlKey&&!Fc(fe)){co(fe);return}No(fe)}async function Bo(){const{width:Le,height:Re,x:Ve,y:Ge}=u.value.getBoundingClientRect(),dt=h.value.querySelectorAll("[data-writer-id]"),{maxX:rt,maxY:_t}=Array.from(dt).reduce((Yt,la)=>{const ca=la.getBoundingClientRect();return{maxY:Math.max(Yt.maxY,(ca.bottom-Ge)*pe.value+F.value.y),maxX:Math.max(Yt.maxX,(ca.right-Ve)*pe.value+F.value.x)}},{maxY:0,maxX:0}),At=Math.min((Le-48)/rt,(Re-48)/_t);ln(At),kn(0,0)}async function Fo(fe){if(l.value=!1,!fe)return;const{components:Le}=fe;Le.forEach(Re=>{j(Re.type,i,void 0,Re)}),await qa(),me("socketPosition")}We(r.firstSelectedItem,fe=>{fe&&(te.value=null,n.isChildOf(i,fe.componentId)&&fe.source!=="click"&&Ft(fe.componentId))});function jo(fe){if(Fc(fe)&&(fe.code==="Backquote"||fe.code==="Backslash")){ae.value=!ae.value;return}if(!r.selection.value.length)return;const Re=fe.target;if(Re.tagName==="INPUT"||Re.tagName==="TEXTAREA"||Re.getAttribute("contenteditable")==="true")return;function Ve(){switch(fe.key){case"ArrowDown":return{x:0,y:xa};case"ArrowUp":return{x:0,y:-xa};case"ArrowLeft":return{x:-xa,y:0};case"ArrowRight":return{x:xa,y:0}}}const Ge=Ve();if(Ge===void 0)return;fe.preventDefault();const dt=r.selection.value.map(rt=>n.getComponentById(rt.componentId)).filter(rt=>(rt==null?void 0:rt.x)!==void 0&&(rt==null?void 0:rt.y)!==void 0).reduce((rt,_t)=>(rt[_t.id]=Bc({x:_t.x,y:_t.y},Ge),rt),{});Ne(dt)}const hr=Ki();return ia(async()=>{var fe;await Bo(),await qa(),ve(),(fe=u.value)==null||fe.addEventListener("wheel",Do,{signal:hr.signal}),document.addEventListener("keydown",jo,{signal:hr.signal}),document.addEventListener("mouseup",x,{signal:hr.signal}),document.addEventListener("click",S,{signal:hr.signal,capture:!0}),be.observe(h.value,{attributes:!0,attributeFilter:["style"],childList:!0,subtree:!0,characterData:!0}),window.createAutogenExample=Wt}),Zn(()=>{hr.abort(),be.disconnect()}),(fe,Le)=>{var Re;return $(),R("div",{ref_key:"rootEl",ref:u,class:ft(["BlueprintsBlueprint",{isSelecting:E(m),canSelect:E(g)&&!E(m)}]),"data-writer-unselectable":ze.value,onClick:Ye,onDragover:Le[6]||(Le[6]=sn(()=>{},["prevent","stop"])),onDrop:ue,onMousemove:Pe,onMousedown:Ke,onMouseup:it},[Z("div",{ref_key:"nodeContainerEl",ref:h,class:"nodeContainer",onMousedown:Le[0]||(Le[0]=(...Ve)=>E(b)&&E(b)(...Ve)),onMousemove:Le[1]||(Le[1]=(...Ve)=>E(v)&&E(v)(...Ve)),onMouseup:Le[2]||(Le[2]=(...Ve)=>E(y)&&E(y)(...Ve)),onMouseleave:Le[3]||(Le[3]=(...Ve)=>E(M)&&E(M)(...Ve))},[($(),R("svg",qce,[Z("defs",null,[Z("pattern",{id:"grid",width:xa,height:xa,patternUnits:"userSpaceOnUse",x:-F.value.x-xa/2,y:-F.value.y-xa/2},[Z("circle",{cx:xa/2,cy:xa/2,r:"1",fill:E(Ht).Gray3},null,8,Zce)],8,Wce)]),E(ae)?($(),R("rect",Kce)):ge("",!0),($(!0),R(Je,null,Ot(L.value,(Ve,Ge)=>($(),Ie(Vm,{key:Ge,arrow:Ve,"is-selected":te.value==Ge,"is-engaged":te.value==Ge||E(r).isComponentIdSelected(Ve.fromNodeId)||E(r).isComponentIdSelected(Ve.toNodeId),onClick:dt=>I(dt,Ge),onDelete:dt=>B(Ve)},null,8,["arrow","is-selected","is-engaged","onClick","onDelete"]))),128)),(Re=k.value)!=null&&Re.liveArrow?($(),Ie(Vm,{key:"liveArrow",arrow:k.value.liveArrow,"is-selected":!1,"is-engaged":!0},null,8,["arrow"])):ge("",!0)])),($(!0),R(Je,null,Ot(Ze.value,Ve=>{var Ge,dt,rt,_t,At,Yt,la,ca;return $(),Ie(Ps(E(s)(Ve.id,0)),{key:Ve.id,style:wt({top:`${(((dt=(Ge=oe.value)==null?void 0:Ge[Ve.id])==null?void 0:dt.y)??Ve.y)-F.value.y}px`,left:`${(((_t=(rt=oe.value)==null?void 0:rt[Ve.id])==null?void 0:_t.x)??Ve.x)-F.value.x}px`,"border-color":((Yt=(At=k.value)==null?void 0:At.liveArrow)==null?void 0:Yt.toNodeId)==Ve.id?(ca=(la=k.value)==null?void 0:la.liveArrow)==null?void 0:ca.color:void 0}),onMousedown:sn(qe=>_e(qe,Ve.id),["stop"]),onOutMousedown:qe=>Ae(Ve.id,qe)},null,40,["style","onMousedown","onOutMousedown"])}),128)),($(!0),R(Je,null,Ot(Me.value,Ve=>{var Ge,dt,rt,_t;return $(),Ie(oce,{key:Ve.id,"component-id":Ve.id,style:wt({top:`${(((dt=(Ge=oe.value)==null?void 0:Ge[Ve.id])==null?void 0:dt.y)??Ve.y)-F.value.y}px`,left:`${(((_t=(rt=oe.value)==null?void 0:rt[Ve.id])==null?void 0:_t.x)??Ve.x)-F.value.x}px`})},null,8,["component-id","style"])}),128)),E(f).isSelecting?($(),R("div",{key:0,class:"selectionRectangle",style:wt({left:`${E(f).left}px`,top:`${E(f).top}px`,width:`${E(f).width}px`,height:`${E(f).height}px`})},null,4)):ge("",!0)],544),Ce(E(t),{class:"blueprintsToolbar",onAutogenClick:c,onDeploy:Le[4]||(Le[4]=Ve=>d.value=!0)}),E(l)?($(),Ie(Sg,{key:0},{default:Xe(()=>[Ce(Uce,{onBlockGeneration:Fo})]),_:1})):ge("",!0),Ce(E(a),{modelValue:d.value,"onUpdate:modelValue":Le[5]||(Le[5]=Ve=>d.value=Ve),"blueprint-id":E(i)},null,8,["modelValue","blueprint-id"]),E(h)?($(),Ie(bce,{key:1,"node-container-el":E(h),"render-offset":F.value,"zoom-level":J.value,class:"navigator",onAutoArrange:he,onChangeRenderOffset:ma,onChangeZoomLevel:Lr,onResetZoom:Bo},null,8,["node-container-el","render-offset","zoom-level"])):ge("",!0)],42,zce)}}}),Qce=ke(Yce,[["__scopeId","data-v-d8dd8762"]]);function e0e(e,t){const a=(t==null?void 0:t.wf)??re(ne.core),n=(t==null?void 0:t.ssbm)??re(ne.builderManager);if(!a)throw new Error("Missing core injection.");if(!n)throw new Error("Missing builderManager injection.");const r=fa(),o=H(()=>a.getComponentById(Pa(e.componentId)));We(o,h=>{h||r.error(`useComponentFieldViewModel: component with id "${Pa(e.componentId)}" not found`)},{immediate:!0});const s=H(()=>{var m,g,_;const h=Pa(e.defaultValue);if(typeof h=="string")return h;const f=a.getComponentDefinition((m=o.value)==null?void 0:m.type);return((_=(g=f==null?void 0:f.fields)==null?void 0:g[Pa(e.fieldKey)])==null?void 0:_.default)??""}),{setContentValue:i}=Fs(a,n);function l(h){o.value&&i(o.value.id,Pa(e.fieldKey),h)}const c=ye(!1);We([()=>Pa(e.componentId),()=>Pa(e.fieldKey)],()=>{c.value=!1});const d=H(()=>{var f,m;const h=(m=(f=o.value)==null?void 0:f.content)==null?void 0:m[Pa(e.fieldKey)];return c.value&&typeof h=="string"?h:h||s.value});return H({get:()=>d.value,set:h=>{c.value=!0,l(h)}})}const t0e={class:"alias"},a0e=["contenteditable"],n0e=$e({__name:"BlueprintsNodeNamer",props:{componentId:{},blockName:{}},setup(e){const a=e0e({componentId:mn(e,"componentId"),fieldKey:"alias"}),n=H(()=>!!a.value),r=pt("aliasEditorEl"),o=ye(!1);async function s(){if(o.value)return;o.value=!0,await qa();const c=r.value;c.focus();const d=document.createRange(),u=window.getSelection();d.setStart(c,c.childNodes.length),d.collapse(!0),u.removeAllRanges(),u.addRange(d)}function i(){const c=r.value.textContent;r.value.blur(),o.value=!1,a.value=c}function l(c){o.value&&c.stopPropagation()}return(c,d)=>($(),R("div",{class:ft(["BlueprintsNodeNamer",{beingEdited:o.value,hasEyebrow:n.value||o.value}]),"data-writer-unselectable":"true"},[Z("div",{class:"blockName",onClick:s},je(c.blockName),1),Z("div",t0e,[n.value||o.value?($(),R("div",{key:0,ref_key:"aliasEditorEl",ref:r,class:"aliasEditor",contenteditable:o.value,"data-writer-unselectable":"true",onClick:s,onMousemove:l,onBlur:i,onKeydown:$r(i,["enter"])},je(E(a)),41,a0e)):ge("",!0)])],2))}}),r0e=ke(n0e,[["__scopeId","data-v-ac3126a4"]]);function e8(e,t){const a=H(()=>{const r=E(t);if(r)return e.getComponentById(r)}),n=H(()=>{var o;const r=(o=a.value)==null?void 0:o.type;if(r)return e.getComponentDefinition(r)});return{component:a,definition:n}}function o0e(e,t){return H(()=>{var s;const{type:a,id:n}=E(e)??{},r=(s=E(t))==null?void 0:s.outs;return a&&!Pd.has(a)&&a.startsWith("blueprints_")&&(r==null?void 0:r.success)!==void 0?`@{results.${n}}`:""})}const s0e=$e({__name:"SharedMoreDropdown",props:{options:{type:Array,default:()=>[]},triggerSize:{type:String,default:"smallIcon"},triggerVariant:{type:String,default:"neutral"},triggerCustomSize:{type:String,default:void 0},triggerIcon:{type:String,default:"ellipsis"},disabled:{type:Boolean},hideIcons:{type:Boolean,required:!1},dropdownPlacement:{type:String,required:!1,default:"bottom-end"},floatingMiddleware:{type:Array,required:!1,default:()=>[i6({allowedPlacements:["bottom-end","top-end"]})]}},emits:{select:e=>typeof e=="string"},setup(e,{emit:t}){const a=ir({loader:()=>zt(()=>import("./WdsDropdownMenu-C1nXnj7Y.js").then(u=>u.b),__vite__mapDeps([4,5,6,7]),import.meta.url)}),n=e,r=t,o=ye(!1),s=pt("trigger"),i=pt("dropdown"),{floatingStyles:l}=c6(s,i,{placement:mn(n,"dropdownPlacement"),middleware:mn(n,"floatingMiddleware")}),c=b0(s);We(c,()=>{c.value||qa().then(()=>o.value=!1)},{immediate:!0});function d(u){o.value=!1,r("select",u)}return(u,h)=>($(),R("div",{ref_key:"trigger",ref:s,class:"SharedMoreDropdown"},[Ce(La,{variant:e.triggerVariant,size:e.triggerSize,disabled:e.disabled,"custom-size":e.triggerCustomSize,onClick:h[0]||(h[0]=sn(f=>o.value=!o.value,["stop"]))},{default:Xe(()=>[Ce(bt,{name:e.triggerIcon},null,8,["name"])]),_:1},8,["variant","size","disabled","custom-size"]),o.value?($(),Ie(E(a),{key:0,ref_key:"dropdown",ref:i,class:"SharedMoreDropdown__dropdown",options:e.options,style:wt(E(l)),"hide-icons":e.hideIcons,onSelect:d},null,8,["options","style","hide-icons"])):ge("",!0)],512))}}),t8=ke(s0e,[["__scopeId","data-v-df890e8f"]]),i0e=Object.freeze(Object.defineProperty({__proto__:null,default:t8},Symbol.toStringTag,{value:"Module"}));var cs=(e=>(e.Add="add",e.MoveUp="moveUp",e.MoveDown="moveDown",e.Cut="cut",e.Copy="copy",e.Paste="paste",e.GoToParent="goToParent",e.Delete="delete",e))(cs||{});function l0e(e){return typeof e=="string"&&Object.values(cs).includes(e)}function c0e(e,t,a,n={},r){const{moveComponentUp:o,moveComponentDown:s,cutComponent:i,pasteComponent:l,copyComponent:c,isAddAllowed:d,isCopyAllowed:u,isCutAllowed:h,isGoToParentAllowed:f,isPasteAllowed:m,isDeleteAllowed:g,getEnabledMoves:_,removeComponentsSubtree:b,goToParent:v}=Fs(e,t,a),y=Od(),M=H(()=>r?E(r).componentId:t.firstSelectedId.value),x=H(()=>r?E(r).instancePath:t.firstSelectedItem.value.instancePath),S=H(()=>{var Ze,Me;const oe=e.getComponentById(M.value);if(!oe)return{};const{up:Te,down:Ue}=_(M.value);return{isAddEnabled:d(M.value),componentTypeName:(Ze=e.getComponentDefinition(oe.type))==null?void 0:Ze.name,toolkit:(Me=e.getComponentDefinition(oe.type))==null?void 0:Me.toolkit,isMoveUpEnabled:Te,isMoveDownEnabled:Ue,isCopyEnabled:u(M.value),isCutEnabled:h(M.value),isGoToParentEnabled:f(M.value),isDeleteEnabled:g(M.value)}}),L=H(()=>t.firstSelectedId.value?m(t.firstSelectedId.value):!1);async function F(){try{await l(M.value)}catch(oe){y.pushToast({type:"error",message:String(oe)})}}function te(){if(!S.value.isDeleteEnabled)return;if(r){b(E(r).componentId);return}const oe=t.selection.value.map(Te=>Te.componentId);oe.length!==0&&b(...oe)}const J=H(()=>[{value:"add",label:"Add child",icon:"plus",disabled:!S.value.isAddEnabled},{value:"moveUp",label:"Move up",shortcut:`${Zr()}↑`,icon:"arrow-up",disabled:!S.value.isMoveUpEnabled},{value:"moveDown",label:"Move down",shortcut:`${Zr()}↓`,icon:"arrow-down",disabled:!S.value.isMoveDownEnabled},{value:"cut",label:"Cut",shortcut:`${Zr()}X`,icon:"scissors",disabled:!S.value.isCutEnabled},{value:"copy",label:"Copy",shortcut:`${Zr()}C`,icon:"clipboard",disabled:!S.value.isCopyEnabled},{value:"paste",label:"Paste",shortcut:`${Zr()}V`,icon:"clipboard-paste",disabled:!L.value},{value:"goToParent",label:"View parent",shortcut:`${Zr()}⇧↑`,icon:"list-tree",disabled:!S.value.isGoToParentEnabled},{value:"delete",label:"Delete",shortcut:Vd()?"⌫":"Del",icon:"trash-2",variant:"danger",disabled:!S.value.isDeleteEnabled}]);function be(oe){var Te;switch(oe){case"add":break;case"moveUp":o(M.value);break;case"moveDown":s(M.value);break;case"cut":i(M.value);break;case"copy":c(M.value);break;case"paste":F();break;case"goToParent":v(M.value,x.value);break;case"delete":te();break}(Te=n[oe])==null||Te.call(n)}return{dropdownOptions:J,handleDropdownSelect:be}}function a8(e){return e.map(t=>`${t.componentId}:${t.instanceNumber}`).join(",")}function Fde(e){return e?e.split(",").map(t=>{const[a,n]=t.split(":");return{componentId:a,instanceNumber:Number(n)}}):[]}const d0e={class:"BlueprintsNodeActions"},u0e=$e({__name:"BlueprintsNodeActions",props:{showDisplayErrorOption:{type:Boolean}},emits:{showError:()=>!0},setup(e,{emit:t}){const a=re(ne.core),n=re(ne.builderManager),r=re(ne.componentId),o=re(ne.instancePath),s=e,i=t,{component:l,definition:c}=e8(a,r),d=o0e(l,c),u=Hd(a),{copy:h,copied:f}=Lg();function m(){h(d.value)}const g=c0e(a,n,u,{},{instancePath:a8(o),componentId:r});function _(y){switch(l0e(y)&&g.handleDropdownSelect(y),y){case"showError":i("showError");break}}const b=new Set([cs.Add,cs.MoveUp,cs.MoveDown,cs.Paste]),v=H(()=>{const y=g.dropdownOptions.value.filter(M=>!b.has(M.value)).map(M=>(delete M.shortcut,M));return s.showDisplayErrorOption&&y.unshift({value:"showError",label:"Add error path",icon:"split"}),y});return(y,M)=>($(),R("div",d0e,[E(d)?($(),Ie(La,{key:0,size:"smallIcon",variant:"neutral","data-writer-tooltip-placement":"bottom","data-writer-unselectable":!0,"data-writer-tooltip":E(f)?"Copied!":"Copy result variable",onClick:sn(m,["prevent"])},{default:Xe(()=>[Ce(bt,{name:"at-sign"})]),_:1},8,["data-writer-tooltip"])):ge("",!0),Ce(t8,{"data-automation-action":"node-actions-dropdown",options:v.value,"data-writer-unselectable":!0,"trigger-custom-size":"32px","trigger-icon":"ellipsis-vertical",onSelect:_},null,8,["options"])]))}}),Rm=ke(u0e,[["__scopeId","data-v-ca70c7e7"]]),h0e={class:"BlueprintsNodeOutput"},p0e=["data-writer-socket-id"],f0e=$e({__name:"BlueprintsNodeOutput",props:{outId:{type:String,required:!0},out:{type:Object,required:!0},displayLabel:{type:Boolean}},emits:{click:()=>!0},setup(e){return(t,a)=>($(),R("div",h0e,[e.displayLabel?($(),R(Je,{key:0},[pa(je(e.out.name),1)],64)):ge("",!0),Z("div",{class:ft(["BlueprintsNodeOutput__ball",e.out.style]),"data-writer-socket-id":e.outId,"data-writer-unselectable":!0,onClickCapture:a[0]||(a[0]=sn(()=>{},["stop"])),onMousedownCapture:a[1]||(a[1]=sn(n=>t.$emit("click"),["stop"]))},null,42,p0e)]))}}),rc=ke(f0e,[["__scopeId","data-v-cbba3510"]]),m0e={class:"BlueprintsNodeLogs"},v0e=$e({__name:"BlueprintsNodeLogs",props:{count:{type:Number,required:!0},completionStyle:{type:String,required:!1,default:void 0}},emits:{click:()=>!0},setup(e){const t=e,a=H(()=>t.count===1?"1 output":`${t.count} outputs`);return(n,r)=>($(),R("div",m0e,[Z("button",{class:ft(["BlueprintsNodeLogs__btn",{"BlueprintsNodeLogs__btn--success":e.completionStyle=="success","BlueprintsNodeLogs__btn--skipped":e.completionStyle=="skipped","BlueprintsNodeLogs__btn--stopped":e.completionStyle=="stopped","BlueprintsNodeLogs__btn--error":e.completionStyle=="error"}]),"data-writer-unselectable":!0,type:"button",onClick:r[0]||(r[0]=o=>n.$emit("click"))},je(a.value),3)]))}}),g0e=ke(v0e,[["__scopeId","data-v-daf51f8d"]]);function jc(e){if(!e)return{};if(typeof e=="string")try{const t=JSON.parse(e);return typeof t=="object"&&t!==null?t:{}}catch{return{}}return typeof e=="object"?e:{}}function y0e(e,t){const a=H(()=>{var i;const r=Object.entries(((i=e.value)==null?void 0:i.fields)??{}).filter(([l,c])=>c.type===Q.Tools);if(r.length===0)return!1;const o=r.map(([l])=>{var c;return{fieldKey:l,tools:jc((c=t[l])==null?void 0:c.value)}});return o.some(({tools:l})=>Object.keys(l).length>0)?o.every(({tools:l})=>{const c=Object.keys(l);return c.length===0?!0:!c.some(d=>{var u;return((u=l[d])==null?void 0:u.type)==="function"})}):!1});function n(r){var i;const o=jc((i=t[r])==null?void 0:i.value),s=Object.keys(o);return s.length===0?!1:!s.some(l=>{var c;return((c=o[l])==null?void 0:c.type)==="function"})}return{hasOnlyNonFunctionTools:a,hasToolsButNoFunctionTools:n}}const M0e={key:0,class:"BlueprintsNode__main__outputs__output BlueprintsNode__main__outputs__empty"},_0e=$e({__name:"BlueprintsNodeTools",props:{fieldKey:{},fieldType:{},fieldValue:{},hasOutputs:{type:Boolean}},setup(e){const t=e,a=H(()=>t.fieldType!==Q.Tools?{}:jc(t.fieldValue)),n=H(()=>{if(t.fieldType!==Q.Tools)return!1;const l=Object.keys(a.value);return l.length===0?!1:!l.some(c=>{var d;return((d=a.value[c])==null?void 0:d.type)==="function"})});function r(l){return l!==null&&typeof l=="object"&&"type"in l&&l.type==="function"}const o=H(()=>Object.keys(a.value).filter(l=>!r(a.value[l]))),s=H(()=>o.value.length>0?o.value.join(", "):!t.hasOutputs&&n.value?"No outputs":"None configured."),i=H(()=>!t.hasOutputs||o.value.length>0);return(l,c)=>i.value?($(),R("div",M0e,je(s.value),1)):ge("",!0)}}),b0e=ke(_0e,[["__scopeId","data-v-09778394"]]);function n8(e,t){var r,o;if((t==null?void 0:t.type)!=="blueprints_shared")return;const a=(r=t.content)==null?void 0:r.sourceBlueprintId;if(!a)return;const n=e.getComponentById(a);return(o=n==null?void 0:n.content)==null?void 0:o.key}function jde(e,t){var r,o;if((t==null?void 0:t.type)!=="blueprints_shared")return;const a=(r=t.content)==null?void 0:r.sourceBlueprintId;if(!a)return;const n=e.getComponentById(a);return(o=n==null?void 0:n.content)==null?void 0:o.deployedDescription}function Ude(e,t){const a=H(()=>e.getComponentDefinition(E(t).type)),n=H(()=>{var c;const s=E(t),{type:i,content:l}=s;return i=="html"&&(l!=null&&l.element)?l==null?void 0:l.element:i=="blueprints_blueprint"?(l==null?void 0:l.key)||"Blueprint":i=="blueprints_shared"?n8(e,s)||"Shared Blueprint":((c=a.value)==null?void 0:c.name)??`Unknown (${i})`}),r=H(()=>{var d,u;const s=(d=a.value)==null?void 0:d.previewField;if(!s)return;const i=(u=E(t).content)==null?void 0:u[s];let l;const c=70;return(i==null?void 0:i.length)>c?l=i.substring(0,c)+"...":l=i,l}),o=H(()=>{const s=E(t).type,i=a.value.category;return[`/components/${s}.svg`,`/components/category_${i}.svg`,s.startsWith("blueprints_")?`/components/blueprints_category_${i}.svg`:void 0].filter(Boolean).map(l=>Li(l))});return{name:n,previewText:r,possibleImageUrls:o}}const w0e={key:0,class:"BlueprintsNode__side"},x0e={class:"BlueprintsNode__extraBorder"},C0e={key:0,class:"runner"},A0e={class:"BlueprintsNode__main"},S0e={class:"BlueprintsNode__main__title"},$0e={key:0,class:"deprecationNotice"},E0e={key:0,class:"BlueprintsNode__main__outputs__title"},I0e={key:0,class:"BlueprintsNode__main__outputs__title"},k0e={key:1,class:"BlueprintsNode__main__footer"},T0e={writer:{name:"Node",description:"A Blueprints node.",toolkit:"blueprints",category:"Other",fields:{alias:{name:"Alias",type:Q.Text}},allowedParentTypes:["blueprints_blueprint"],previewField:"alias"}},P0e=$e({...T0e,__name:"BlueprintsNode",emits:["outMousedown","engaged"],setup(e,{emit:t}){const a=t,n=re(ne.core),r=re(ne.builderManager),{removeOut:o}=Fs(n,r),s=re(ne.componentId),i=re(ne.evaluatedFields),l=H(()=>{var K;return((K=h==null?void 0:h.value)==null?void 0:K.category)=="Triggers"}),c=H(()=>{var K;return((K=h==null?void 0:h.value)==null?void 0:K.category)=="Writer"}),d=H(()=>{var K;return(K=h==null?void 0:h.value)==null?void 0:K.deprecated}),{component:u,definition:h}=e8(n,s),f=H(()=>{var K;return u.value&&(n8(n,u.value)||((K=h.value)==null?void 0:K.name))||"Unknown"}),m=H(()=>{var K,G,T;return S.value==null?null:S.value=="skipped"?"skipped":S.value=="stopped"?"stopped":S.value=="in_progress"?"running":((T=(G=(K=h.value)==null?void 0:K.outs)==null?void 0:G[S.value])==null?void 0:T.style)??"success"}),{hasOnlyNonFunctionTools:g}=y0e(H(()=>h.value),i),_=H(()=>Object.entries(h.value.outs??{}).some(([G,T])=>{var k,C;return T.style!=="dynamic"||!T.field?!1:((C=(k=h.value.fields)==null?void 0:k[T.field])==null?void 0:C.type)!==Q.Tools})),b=H(()=>_.value?"OR":g.value?"No outputs":"THEN"),v=H(()=>g.value||!oe.value&&Object.keys(Me.value).length>0),y=H(()=>{var T,O;const K=r.getLogEntries(),G=((O=(T=K.find(k=>!!k.blueprintExecution))==null?void 0:T.blueprintExecution)==null?void 0:O.runId)??null;return K.filter(k=>{var C;return((C=k==null?void 0:k.blueprintExecution)==null?void 0:C.runId)===G})}),M={in_progress:5,error:4,success:3,stopped:2,skipped:1,none:0},x=H(()=>y.value.map(G=>G.blueprintExecution).filter(Boolean).flatMap(G=>G.summary.filter(T=>T.componentId===u.value.id).filter(T=>!!T.outcome))),S=H(()=>{let K="none";for(const G of x.value)(M[G.outcome]??M.success)>M[K]&&(K=G.outcome);return K==="none"?null:K}),L=H(()=>r.isComponentIdSelected(s)),F=ye(!1),te=H(()=>!J.value||be.value?!1:!F.value),J=H(()=>{var K,G;return((G=(K=h.value)==null?void 0:K.outs)==null?void 0:G.error)!==void 0}),be=H(()=>{var G;return J.value?((G=u.value.outs)==null?void 0:G.some(T=>T.outId==="error"))?!0:F.value:!1}),oe=H(()=>!(Object.keys(Me.value??{}).length>0||Object.keys(Ue.value??{}).length>0||Object.keys(Te.value??{}).length>1)),Te=H(()=>Object.entries(h.value.outs??{}).reduce((K,[G,T])=>(T.style=="dynamic"||G==="error"&&!be.value||(K[G]=T),K),{}),{}),Ue=H(()=>{var G;const K=new Set([...Object.keys(Te.value),...Object.values(Me.value).flatMap(Object.keys)]);return(((G=u.value)==null?void 0:G.outs)??[]).reduce((T,{outId:O})=>{if(!K.has(O))return T[O]={name:O,style:"dynamic",description:""},T},{})});function Ze(K){const T=h.value.fields[K].type==Q.Tools,O=Object.keys(i[K].value??{});return T?O.filter(C=>{var P;return((P=i[K].value[C])==null?void 0:P.type)=="function"}):O}const Me=H(()=>{const K={};return Object.entries(h.value.outs??{}).forEach(([G,T])=>{if(T.style!=="dynamic")return;if(!T.field){K.default??(K.default={}),K.default[G]={...T};return}K[T.field]={},Ze(T.field).forEach(k=>{K[T.field][`${G}_${k}`]={name:k,description:"Dynamically created",style:"dynamic"}})}),K});We(Me,()=>{var T,O;const K=Object.values(Me.value).flatMap(Object.keys);(((O=(T=u.value)==null?void 0:T.outs)==null?void 0:O.filter(k=>!K.includes(k.outId)&&!(k.outId in Te.value)))??[]).forEach(k=>{u.value&&o(u.value.id,k)})},{immediate:!0});const ee=H(()=>{if(["success","error","skipped","stopped"].includes(m.value)){const G=`/status/${m.value}.svg`;return[Li(G)]}const K=[`/components/${u.value.type}.svg`,`/components/blueprints_category_${h.value.category}.svg`];return n.featureFlags.value.includes("custom_block_icons")&&K.unshift(`/static/components/${u.value.id}.svg`),K.map(G=>Li(G))});function j(){x.value.at(-1)&&(r.openPanels.value.add("log"),r.setSelection(s,void 0,"click"))}return We(L,()=>{a("engaged")}),(K,G)=>($(),R("div",{class:ft(["BlueprintsNode",{"BlueprintsNode--trigger":l.value,"BlueprintsNode--intelligent":c.value,"BlueprintsNode--deprecated":d.value,"BlueprintsNode--running":m.value=="running","BlueprintsNode--success":m.value=="success","BlueprintsNode--skipped":m.value=="skipped","BlueprintsNode--stopped":m.value=="stopped","BlueprintsNode--error":m.value=="error"}])},[c.value&&m.value===null?($(),R("div",w0e)):ge("",!0),Z("div",x0e,[m.value=="running"?($(),R("div",C0e)):ge("",!0)]),Z("div",A0e,[Z("div",S0e,[Ce(qg,{urls:ee.value,class:"icon","loader-max-width-px":24,"loader-max-height-px":24},null,8,["urls"]),Ce(r0e,{"component-id":E(s),class:"nodeNamer","block-name":f.value},null,8,["component-id","block-name"]),d.value?($(),R("div",$0e," Deprecated ")):ge("",!0),l.value?($(),Ie(Rm,{key:1,"show-display-error-option":te.value,onShowError:G[0]||(G[0]=T=>F.value=!0)},null,8,["show-display-error-option"])):ge("",!0)]),($(!0),R(Je,null,Ot(Me.value,(T,O)=>{var k,C,P,ae;return $(),R("div",{key:O,class:"BlueprintsNode__main__outputs"},[(k=E(h).fields)!=null&&k[O]?($(),R("h4",E0e,je(E(h).fields[O].name),1)):ge("",!0),($(!0),R(Je,null,Ot(T,(xe,ve)=>($(),Ie(rc,{key:ve,class:"BlueprintsNode__main__outputs__output","out-id":ve,out:xe,"display-label":"",onClick:ze=>K.$emit("outMousedown",ve)},null,8,["out-id","out","onClick"]))),128)),Ce(b0e,{"field-key":O,"field-type":((P=(C=E(h).fields)==null?void 0:C[O])==null?void 0:P.type)??"","field-value":(ae=E(i)[O])==null?void 0:ae.value,"has-outputs":Object.keys(T).length>0},null,8,["field-key","field-type","field-value","has-outputs"])])}),128)),Object.keys(Te.value).length>0?($(),R("div",{key:0,class:ft(["BlueprintsNode__main__outputs",{"BlueprintsNode__main__outputs--float":oe.value&&!l.value}])},[v.value?($(),R("h4",I0e,je(b.value),1)):ge("",!0),($(!0),R(Je,null,Ot(Te.value,(T,O)=>($(),Ie(rc,{key:O,class:"BlueprintsNode__main__outputs__output","out-id":O,out:T,"display-label":!oe.value,onClick:k=>K.$emit("outMousedown",O)},null,8,["out-id","out","display-label","onClick"]))),128)),($(!0),R(Je,null,Ot(Ue.value,(T,O)=>($(),Ie(rc,{key:O,class:"BlueprintsNode__main__outputs__output","out-id":O,out:T,"display-label":"",onClick:k=>K.$emit("outMousedown",O)},null,8,["out-id","out","onClick"]))),128))],2)):ge("",!0),l.value?ge("",!0):($(),R("div",k0e,[x.value.length>0?($(),Ie(g0e,{key:0,"completion-style":m.value,count:x.value.length,onClick:j},null,8,["completion-style","count"])):ge("",!0),Ce(Rm,{"show-display-error-option":te.value,onShowError:G[1]||(G[1]=T=>F.value=!0)},null,8,["show-display-error-option"])]))])],2))}}),L0e=ke(P0e,[["__scopeId","data-v-810cc87f"]]),V0e={class:"BlueprintsRoot","data-writer-container":""},O0e="The root component of the application, which serves as the starting point of the component hierarchy.",H0e={writer:{name:"Blueprints Root",toolkit:"blueprints",category:"Root",description:O0e,allowedChildrenTypes:["blueprints_blueprint"],fields:{}}},R0e=$e({...H0e,__name:"BlueprintsRoot",setup(e){const t=re(ne.core),a=re(ne.getChildrenVNodes),n=H(()=>{const r=t.activePageId.value;if(!!t.getComponentById(r)&&t.isChildOf("blueprints_root",r))return r;const s=t.getComponents("blueprints_root",{includeBMC:!0,includeCMC:!1,sortedByPosition:!0});return s.length==0?null:s[0].id});return ia(()=>{n.value&&t.activePageId.value!==n.value&&t.setActivePageId(n.value)}),(r,o)=>($(),R("div",V0e,[($(!0),R(Je,null,Ot(E(a)(),s=>($(),R(Je,{key:s.key},[s.key===`${n.value}:0`?($(),Ie(Ps(s),{key:0})):ge("",!0)],64))),128))]))}}),N0e=ke(R0e,[["__scopeId","data-v-367e0c79"]]),D0e={name:"Note",description:"Internal note displayed only in edit mode",category:"Internal",fields:{parentInstancePath:{name:"Parent's instance path",type:Q.Text},content:{name:"Content",type:Q.Text,control:Ui.Textarea},createdAt:{name:"Created At",type:Q.Text},createdBy:{name:"Created By",type:Q.Number}}},B0e={writer:D0e};function F0e(e,t,a,n,r,o){return ge("",!0)}const j0e=ke(B0e,[["render",F0e]]);let r8=[];function U0e(e){r8=e??[]}function o8(e){return!e||e.length===0?!0:e.some(t=>r8.includes(t))}const vl={root:R2e,page:$2e,sidebar:L1e,button:ple,text:qae,section:x1e,header:m1e,heading:rae,dataframe:Jte,html:Jg,pagination:Vle,repeater:Nle,column:o1e,columns:c1e,tab:N1e,tabs:W1e,link:rne,horizontalstack:M1e,separator:$1e,image:uae,pdf:s2e,iframe:f2e,googlemaps:_2e,mapbox:j2e,timer:Ule,textinput:bie,textareainput:Sie,numberinput:Fse,sliderinput:cie,rangeinput:vie,colorinput:Roe,dateinput:Uoe,timeinput:Pie,radioinput:Kse,checkboxinput:Eoe,dropdowninput:Joe,selectinput:Yse,multiselectinput:Hse,fileinput:_se,webcamcapture:Xle,vegalitechart:Kae,plotlygraph:Oae,metric:Tae,message:xae,videoplayer:Qae,chatbot:are,step:ele,steps:ile,ratinginput:Fie,tags:ure,switchinput:Zie,reuse:Qle,avatar:Mre,annotatedtext:xre,jsonviewer:soe,blueprints_root:N0e,blueprints_blueprint:Qce,progressbar:yoe,note:j0e},wi=Ri({});function Nm(e){const t=`Component type "${e}" not supported. If it's a custom component, please ensure it's been loaded.`;return{writer:{name:"Fallback Component",allowedChildrenTypes:["*"],description:t,category:"Fallback"},setup(a,{slots:n}){return()=>En("div",{"data-writer-container":"",style:{color:"var(--primaryTextColor)"}},[t,n.default({})])}}}function z0e(e){var r,o;const t={blueprints_node:L0e},a=wi[e];if(!a)return;const n=a.baseType;return{...t[n],writer:{...t[n].writer,...wi[e].writer,fields:{...(r=t[n].writer)==null?void 0:r.fields,...(o=wi[e].writer)==null?void 0:o.fields}}}}function q0e(e){var n;const t=z0e(e)??vl[e]??Nm(e),a=(n=t==null?void 0:t.writer)==null?void 0:n.featureFlags;return o8(a)?t:Nm(e)}function Vi(e){var t;return(t=q0e(e))==null?void 0:t.writer}function Rd(){return[...Object.keys(vl),...Object.keys(wi)].filter(t=>{var n,r;const a=(r=(n=vl[t])==null?void 0:n.writer)==null?void 0:r.featureFlags;return o8(a)})}function W0e(e,t){vl[e]=t}function Z0e(e,t){wi[e]=t}function K0e(e){let t=!1;return J0e(e),Object.entries(e).forEach(([,a])=>{t=Q0e(a,e)||t,t=G0e(a)||t}),t}function G0e(e){const t=fa(),a=Vi(e.type);if(!a||a.category=="Fallback")return t.error(`Component ${e.id} (${e.type}). Invalid component type.`),!1;let n=!1;return n=ade(e),n=tde(e)||n,X0e(e,a),Y0e(e,a),n}function Uc(e,t,a={}){a[e]=!0,Object.entries(t).filter(([,n])=>n.parentId===e).forEach(([n])=>Uc(n,t,a))}function J0e(e){const t=fa(),a=Object.fromEntries(Object.entries(e).map(([n])=>[n,!1]));Uc("root",e,a),Uc("blueprints_root",e,a),Object.entries(a).forEach(([n,r])=>{r||t.warn(`Component ${n} (${e[n].type}). Orphan component.`)})}function X0e(e,t){const a=fa(),n=Object.keys(t.fields??{});e.content&&Object.keys(e.content).forEach(r=>{n.includes(r)||a.warn(`Component ${e.id} (${e.type}). Field key "${r}" is defined in the component but not in the template.`)})}function Y0e(e,t){const a=Object.keys(t.events??{});if(!e.binding)return;const n=e.binding.eventType;if(a.includes(n)&&t.events[n].bindable)return;fa().warn(`Component ${e.id} (${e.type}). The component is bound to event "${e.binding.eventType}" but the template doesn't define that event or it's not bindable.`)}function Q0e(e,t){const a=fa();let n=!1;e.id=="root"&&e.position!==0&&a.error("Root must be at position 0."),e.position==-1&&a.error(`Component ${e.id} (${e.type}). Invalid position.`);const r=Object.values(t).filter(i=>i.parentId===e.id&&i.position!==-2&&!i.isCodeManaged);let o=0;return r.forEach(i=>{o+=i.position}),(r.length-1)*r.length/2!==o&&(a.error(`Component ${e.id} (${e.type}). Invalid children positions. Automated fix will be applied.`),ede(r),n=!0),n}function ede(e){e.sort((t,a)=>t.position>a.position?1:-1),e.map((t,a)=>{t.position=a})}function tde(e){var a,n,r;let t=!1;if(Object.keys(e.handlers??{}).forEach(o=>{if(!o.startsWith("ss-"))return;const s=`wf-${o.substring(3)}`;e.handlers[s]=e.handlers[o],t=!0,delete e.handlers[o]}),(n=(a=e.binding)==null?void 0:a.eventType)!=null&&n.startsWith("ss-")){const s=`wf-${((r=e.binding)==null?void 0:r.eventType).substring(3)}`;e.binding.eventType=s,t=!0}return t}function ade(e,t){let a=!1;if(e.type=="column"){if("horizontalAlignment"in e.content){const n={left:"start",center:"center",right:"end"};e.content.contentHAlign=n[e.content.horizontalAlignment]||e.content.horizontalAlignment,delete e.content.horizontalAlignment,a=!0}if("verticalAlignment"in e.content){const n={normal:"unset",top:"start",center:"center",bottom:"end"};e.content.contentVAlign=n[e.content.verticalAlignment]||e.content.verticalAlignment,delete e.content.verticalAlignment,a=!0}}else if(e.type=="horizontalstack"){if("alignment"in e.content){const n={left:"start",center:"center",right:"end"};e.content.contentHAlign=n[e.content.alignment]||e.content.alignment,delete e.content.alignment,a=!0}}else e.type=="section"&&"snapMode"in e.content&&(delete e.content.snapMode,a=!0);return a}function nde(e){let t="";const a=[];let n=!1;for(let o=0;o<e.length;o++){const s=e[o];if(s==="."&&!n){a.push(t),t="";continue}t+=s,s==="\\"?n=!0:n=!1}return a.push(t),a.map(o=>o.replaceAll("\\.","."))}const rde="WriterCustomComponentTemplates";async function ode(e){await Promise.all(e.map(async t=>{const a=t.toLocaleLowerCase();a.endsWith(".js")?await sde(t):a.endsWith(".css")&&lde(t)}))}async function sde(e){var a;const t=fa();t.log(`Importing custom component templates at "${e}"...`),await zt(()=>import(s8()+e),[],import.meta.url),(a=Object.entries(window[rde]))==null||a.forEach(([n,r])=>{ide(n)?(W0e(`custom_${n}`,r),t.log(`Registering template for "${n}".`)):t.warn(`custom component '${n}' is ignored. A custom component should be declared using only alphanumeric lowercase and _.`)})}function ide(e){return/^[a-z0-9_]+$/.test(e)}function lde(e){const t=document.createElement("link");t.rel="stylesheet",t.href=s8()+e,document.head.appendChild(t)}function s8(){let e=window.location.pathname;return e.endsWith("/")||(e+="/"),`${e}extensions/`}function cde(e){return new Promise((t,a)=>{const n=new FileReader;n.onload=()=>{t(n.result)},n.onerror=r=>{a(r)},n.readAsArrayBuffer(e)})}async function dde(e){const t=await cde(e);if(!t)return;const a=new TextDecoder("utf-8");return JSON.parse(a.decode(t))}function ude(e,t){const a=URL.createObjectURL(e);try{const n=document.createElement("a");n.href=a,n.download=t,document.body.appendChild(n),n.click(),document.body.removeChild(n)}finally{URL.revokeObjectURL(a)}}function zde(e,t){const a=JSON.stringify(e,null,2),n=new Blob([a],{type:"application/json"});ude(n,t)}const i8=5e3,oc=5;function hde(e){return typeof e!="object"||e===null?!1:e.type==="file"&&typeof e.content=="string"}function qde(e){return typeof e!="object"||e===null?!1:e.type==="binary"}function js(e){return typeof e!="object"||e===null?!1:e.type==="directory"&&typeof e.children=="object"}function*pde(e,t=[]){if(!js(e)){yield t;return}for(const[a,n]of Object.entries(e.children))yield*pde(n,[...t,a])}function*fde(e,t=[]){if(yield t,!!js(e))for(const[a,n]of Object.entries(e.children))yield*fde(n,[...t,a])}function Nd(e,t){if(e.length===0)return t;if(!js(t))return;const[a,...n]=e,r=t.children[a];return n.length===0?r:Nd(n,r)}function zc(e,t,a={type:"file",content:"",complete:!0}){var o;const n=structuredClone(t);let r=n;for(let s=0;s<e.length;s++){if(!js(r))return n;const i=e.at(s);if(s===e.length-1)return r.children[i]=a,n;(o=r.children)[i]??(o[i]={type:"directory",children:{}}),r=r.children[i]}return n}function mde(e,t,a){const n=Nd(e,a);if(js(n)||n===void 0)return a;const r=l8(e,a);return zc(t,r,structuredClone(n))}function l8(e,t){return c8(e,structuredClone(t))}function c8(e,t){if(!js(t)||!(e.at(0)in t.children))return t;if(e.length===1)return delete t.children[e.at(0)],t;const a=c8(e.slice(1),t.children[e.at(0)]);return a.type==="directory"&&Object.keys(a.children).length===0&&delete t.children[e.at(0)],t}const vde=6e4;function gde(){let e=null;const t=ye(null),a=ye(null),n=ye(),r=$t([]),o=ye(null),s=$t({type:"directory",children:{}}),i=ye({}),l=ye([]),c=ye({}),d=ye({});let u;const h=ye("idle");let f=0;const m=ye(new Map);let g=[],_=[];const b=[];let v=!1;const y=ye(),M=H(()=>{var ie;return Number((ie=n.value)==null?void 0:ie.organizationId)||void 0}),x=H(()=>{var ie;return(ie=n.value)==null?void 0:ie.id}),S=H(()=>{var ie;return(ie=n.value)==null?void 0:ie.apiKey}),L=H(()=>{var ie;return((ie=n.value)==null?void 0:ie.baseUrl)??"https://api.writer.com"}),F=H(()=>!!(x.value||M.value));async function te(){await J(),oe(),a.value=="edit"}async function J(){Ze();let ie=null,Ee=null;try{Ee=await fetch("./api/init",{method:"post",cache:"no-store",headers:{"Content-Type":"application/json"},body:JSON.stringify({proposedSessionId:e})});const Pe=await Ee.text();ie=JSON.parse(Pe)}catch{throw new Error(`Failed to acquire initialization data. Server responded with ${(Ee==null?void 0:Ee.status)??"no response"} status.`)}if(Ee.status>400)throw"Connection rejected.";ie.extensionPaths&&await ode(ie.extensionPaths),a.value=ie.mode,i.value=ie.components,d.value=ie.userState,c.value=structuredClone(ie.userState),j(ie.mail),e=ie.sessionId,t.value=new Date().getTime(),r.value=ie.featureFlags,U0e(r.value),n.value=ie.writerApplication,be(ie.abstractTemplates),l.value=ie.userFunctions,o.value=ie.runCode,s.value=ie.sourceFiles,await Me(),!(a.value!="edit"||!K0e(ie.components))&&await pe()}function be(ie){Object.entries(ie??{}).forEach(([Ee,Oe])=>{Z0e(Ee,Oe)})}function oe(){setTimeout(()=>{me("keepAlive",{},oe)},vde)}function Te(ie){ie&&Object.entries(ie).forEach(([Ee,Oe])=>{const Pe=Ee.charAt(0),Ke=nde(Ee.substring(1)),it=Ke.length-1;let ht=d.value;const Ft=Pe==="-";for(let ma=0;ma<it;ma++){const Wt=ht==null?void 0:ht[Ke[ma]];typeof Wt=="object"&&Wt!==null?ht=Wt:Ft||(ht[Ke[ma]]={},ht=ht[Ke[ma]])}Ft?delete ht[Ke.at(-1)]:ht[Ke.at(-1)]=Oe})}function Ue(ie){ie&&(i.value=ie)}function Ze(){m.value.forEach(({callback:ie})=>{ie==null||ie({ok:!1})}),m.value.clear()}async function Me(){if(u&&h.value==="connected")return;const ie=fa(),Ee=new URL("./api/stream",window.location.href);Ee.protocol=Ee.protocol.replace("https","wss"),Ee.protocol=Ee.protocol.replace("http","ws"),u=new WebSocket(Ee.href),u.onopen=()=>{h.value="connected",ie.log("WebSocket connected. Initialising stream..."),me("streamInit",{sessionId:e}),v&&(v=!1,pe().catch(Pe=>{ie.error("Failed to retry component update after reconnect:",Pe),v=!0}))};function Oe(Pe){var it,ht,Ft,ma;if(Pe.messageType=="announcement"&&Pe.payload.type=="codeUpdate"){u.close(),J();return}if(Pe.messageType=="announcement"&&Pe.payload.type=="collaborationUpdate"){b.forEach(Wt=>Wt.fn(Pe.payload.payload));return}if(Pe.messageType=="announcement"&&Pe.payload.type=="componentUpdate"){const Wt={};Object.entries(i.value).forEach(([ln,Lr])=>{Lr.isCodeManaged&&(Wt[ln]=Lr)}),i.value={...Wt,...Pe.payload.payload};return}if(Pe.messageType=="announcement"&&Pe.payload.type=="mail"){j(Pe.payload.payload);return}(Pe.messageType=="eventResponse"||Pe.messageType=="stateEnquiryResponse")&&(Te((it=Pe.payload)==null?void 0:it.mutations),j((ht=Pe.payload)==null?void 0:ht.mail),Ue((Ft=Pe.payload)==null?void 0:Ft.components));const Ke=m.value.get(Pe.trackingId);(ma=Ke==null?void 0:Ke.callback)==null||ma.call(Ke,{ok:!0,payload:Pe.payload}),m.value.delete(Pe.trackingId)}return u.onmessage=async Pe=>{let Ke;try{Pe.data instanceof Blob?Ke=await dde(Pe.data):Ke=JSON.parse(Pe.data)}catch(it){ie.error("Error parsing WebSocket message:",it);return}try{Oe(Ke)}catch(it){ie.error("Error processing WebSocket message:",it)}},u.onclose=async Pe=>{if(u=null,Pe.code==1008){h.value="offline",ie.error("Invalid session. Reinitialising..."),await J();return}Pe.code==4001?(h.value="suspended",ie.info("WebSocket closed due to code update. Attempting to reconnect...")):(h.value="offline",ie.error(`WebSocket closed with code ${Pe.code}. Attempting to reconnect...`)),setTimeout(async()=>{try{await Me(),ie.info("Reconnected.")}catch{ie.error("Couldn't reconnect.")}},i8)},new Promise((Pe,Ke)=>{u.addEventListener("open",()=>Pe(),{once:!0}),u.addEventListener("close",()=>{Ke(new Error("WebSocket connection closed before establishing."))},{once:!0})})}function ee(ie=1e3){u&&(u.onclose=()=>{},u.close(ie),h.value="offline")}function j(ie=[]){g.push(...ie),g=g.filter(Ee=>{const Oe=_.filter(Pe=>Pe.mailType==Ee.type);if(Oe.length==0)return Ee;Oe.forEach(Pe=>Pe.fn(Ee.payload))})}function K(ie){b.push({fn:ie})}function G(ie,Ee){_.push({mailType:ie,fn:Ee}),j()}function T(ie,Ee){_=_.filter(Oe=>!(Oe.mailType===ie&&Oe.fn===Ee))}function O(ie){var Oe;let Ee=null;if(ie instanceof CustomEvent)Ee=((Oe=ie.detail)==null?void 0:Oe.payload)??null;else{const Pe={};for(const Ke in ie){const it=ie[Ke];typeof it!="function"&&(it instanceof Object||(Pe[Ke]=it))}Ee=Pe}return Ee}async function k(ie,Ee,Oe){var Ft,ma;const Pe=Oe?O(ie):null;let Ke,it;ie instanceof CustomEvent&&(Ke=(Ft=ie.detail)==null?void 0:Ft.callback,it=(ma=ie.detail)==null?void 0:ma.handler),me("event",async()=>({type:ie.type,instancePath:Ee,handler:it,payload:await Pe}),Ke,!0)}async function C(ie){return new Promise(Ee=>{me("collaborationPing",ie,()=>{Ee()})})}async function P(ie){return new Promise((Ee,Oe)=>{me("hashRequest",{message:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");Ee((it=Ke.payload)==null?void 0:it.message)})})}function ae(ie,Ee){const Oe=structuredClone(St(s.value)),Pe=Nd(Ee,Oe);hde(Pe)&&(Pe.content=ie,Pe.complete=!0,s.value=Oe)}async function xe(ie){return new Promise((Ee,Oe)=>{me("createSourceFile",{path:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");if((it=Ke.payload)!=null&&it.error)return Oe("Couldn't create the file.");s.value=zc(ie,St(s.value)),Ee()})})}async function ve(ie,Ee){return new Promise((Oe,Pe)=>{me("uploadSourceFile",{path:ie,content:Ee},it=>{var ht,Ft;if(!it.ok)return Pe("Couldn't connect to the server.");if((ht=it.payload)!=null&&ht.error)return Pe("Couldn't upload the file.");s.value=((Ft=it.payload)==null?void 0:Ft.sourceFiles)??zc(ie,St(s.value)),Oe()})})}async function ze(ie,Ee){return new Promise((Oe,Pe)=>{me("renameSourceFile",{from:ie,to:Ee},it=>{var ht;if(!it.ok)return Pe("Couldn't connect to the server.");if((ht=it.payload)!=null&&ht.error)return Pe("Couldn't rename the file.");s.value=mde(ie,Ee,St(s.value)),Oe()})})}async function Ye(ie){return new Promise((Ee,Oe)=>{me("deleteSourceFile",{path:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");if((it=Ke.payload)!=null&&it.error)return Oe("Couldn't delete the file.");s.value=l8(ie,St(s.value)),Ee()})})}async function ct(ie,Ee=["main.py"]){return new Promise((Oe,Pe)=>{me("codeSaveRequest",{code:ie,path:Ee},it=>{if(!it.ok)return Pe("Couldn't connect to the server.");ae(ie,Ee),Oe()}),Ee.join("/")==="main.py"&&(h.value="suspended")})}function xt(ie){return new Promise((Ee,Oe)=>{me("loadSourceFile",{path:ie},Ke=>{if(!Ke.ok)return Oe("Couldn't connect to the server.");ae(Ke.payload.content,ie),Ee()})})}async function D(ie){return new Promise((Ee,Oe)=>{me("listResources",{resource_type:ie},Ke=>{var it;if(!Ke.ok)return Oe("Couldn't connect to the server.");Ee(((it=Ke.payload)==null?void 0:it.data)??[])})})}async function q(ie){me("stateEnquiry",{},ie,!0)}function he(ie){const Pe=(Ke=0)=>{const it=m.value.get(ie);it!==void 0&&(Ke==0&&it.type=="stateEnquiry"||q(()=>setTimeout(()=>Pe(Ke+1),150)))};setTimeout(()=>Pe(0),150)}async function me(ie,Ee,Oe,Pe=!1){if(h.value=="offline"||h.value=="suspended"){Oe==null||Oe({ok:!1});return}const Ke=fa(),it=f++;try{(Oe||Pe)&&m.value.set(it,{type:ie,callback:Oe}),Pe&&he(it);let ht;typeof Ee=="function"?ht=await Ee():ht=Ee;const Ft={type:ie,trackingId:it,payload:ht};if(u.readyState!==WebSocket.OPEN)throw"Connection lost.";u.send(JSON.stringify(Ft,G3))}catch(ht){Ke.error("sendFrontendMessage error",ht),Oe==null||Oe({ok:!1})}}function _e(ie){delete i.value[ie]}function Ae(ie){i.value[ie.id]=ie}async function pe(){const ie={};Object.entries(i.value).forEach(([Oe,Pe])=>{Pe.isCodeManaged||(ie[Oe]=Pe)});const Ee={components:ie};return new Promise((Oe,Pe)=>{me("componentUpdate",Ee,it=>{if(!it.ok)return v=!0,Pe("Couldn't connect to the server.");Oe()})})}async function ce(){return new Promise((ie,Ee)=>{me("writerVaultUpdate",{},Pe=>{if(!Pe.ok)return Ee("Couldn't connect to the server.");ie()})})}function ue(ie){return i.value[ie]}function I(ie,Ee){let Oe=i.value[Ee];do{if(Oe.parentId==ie)return!0;Oe=i.value[Oe.parentId]}while(Oe);return!1}function B(ie,{includeBMC:Ee=!0,includeCMC:Oe=!0,sortedByPosition:Pe=!1}={}){let Ke=Object.values(i.value);return typeof ie<"u"&&(Ke=Ke.filter(it=>it.parentId==ie)),Ke=Ke.filter(it=>{const ht=it.isCodeManaged;return Ee&&!ht||Oe&&ht}),Pe&&(Ke=Ke.sort((it,ht)=>it.isCodeManaged&&!ht.isCodeManaged?1:!it.isCodeManaged&&ht.isCodeManaged?-1:it.position>ht.position?1:-1)),Ke}function*N(ie,Ee={}){for(const Oe of B(ie,Ee))yield Oe,yield*N(Oe.id,Ee)}function U(ie){const Oe=B("root").filter(Pe=>Pe.content.key==ie);Oe.length!=0&&se(Oe[0].id)}function se(ie){y.value=ie}function Se(ie){return Ld(i.value,ie)}function Ne(){return u}return{webSocket:u,syncHealth:h,frontendMessageMap:jt(m),mode:jt(a),userFunctions:jt(l),addMailSubscription:G,removeMailSubscription:T,addCollaborationPingSubscription:K,init:te,forwardEvent:k,hashMessage:P,runCode:jt(o),sourceFiles:jt(s),sendCodeSaveRequest:ct,sendCreateSourceFileRequest:xe,sendRenameSourceFileRequest:ze,sendDeleteSourceFileRequest:Ye,sendFileUploadRequest:ve,requestSourceFileLoading:xt,sendListResourcesRequest:D,sendComponentUpdate:pe,sendWriterVaultUpdate:ce,sendCollaborationPing:C,addComponent:Ae,deleteComponent:_e,getComponentById:ue,getComponents:B,getComponentsNested:N,setActivePageId:se,activePageId:jt(y),setActivePageFromKey:U,getComponentDefinition:Vi,getSupportedComponentTypes:Rd,getContainableTypes:Se,sessionTimestamp:jt(t),userState:jt(d),userStateInitial:jt(c),isChildOf:I,featureFlags:jt(r),getWebSocket:Ne,stopSync:ee,writerApplication:jt(n),isWriterCloudApp:F,writerOrgId:M,writerAppId:x,writerApiKey:S,writerBaseUrl:L}}const yde=2e3,Mde=1e3,_de=5e3;function bde(e){const t=ye({});let a=null,n=null;const r=ye({}),o=ye(null),s=ye({}),i=ye([]),{writerApi:l}=lo(),c=H(()=>{const b={};return i.value.forEach(v=>{var x,S;const y=v.userId;(((S=(x=r.value[y])==null?void 0:x.selection)==null?void 0:S.map(L=>L.instancePath))??[]).forEach(L=>{b[L]=[...b[L]??[],y]})}),b});function d(b){const v=b.userId;if(v!=null){if(b.action=="leave"){delete r.value[v];return}r.value={...r.value,[v]:b}}}function u(b,v,y){return b||v?`${b} ${v}`:y||"Unknown"}async function h(b){const v=s.value[b];if(v)return v;const y=await l.fetchThirdUserProfile(b),M=u(y.firstName,y.lastName,y.email);return s.value[b]={userId:b,displayName:M,avatar:y.avatar,email:y.email},s.value[b]}async function f(){const v=Object.keys(r.value).map(y=>h(parseInt(y)));return Promise.all(v)}async function m(){clearTimeout(n);const b=[];Object.keys(r.value).forEach(v=>{var x;const y=(x=r.value[v])==null?void 0:x.time;if(!y)return;Date.now()-new Date(y).getTime()>_de&&b.push(v)}),b.forEach(v=>delete r.value[v]),i.value=await f(),n=setTimeout(m,Mde)}function g(b){t.value={...t.value,...b}}function _(){e.sendCollaborationPing({userId:o.value,action:"auto",time:new Date,...t.value}),t.value.action="auto",clearTimeout(a),a=setTimeout(_,yde)}return{groomSnapshot:m,updateOutgoingPing:g,sendCollaborationPing:_,handleIncomingCollaborationUpdate:d,connectedProfiles:i,connectedUsersByInstancePath:c}}let Dm;async function qc(e=lo().writerApi){return Dm??(Dm=e.fetchUserProfile()),await Dm}function Wde(e=lo().writerApi){const t=$t(),a=$t(),n=ye(!1);async function r(){a.value=void 0,n.value=!0;try{t.value=await qc(e)}catch(o){a.value=o,t.value=void 0}finally{n.value=!1}}return ia(r),{user:jt(t),isLoading:jt(n),error:jt(a)}}const L1={};function Zde(e,t=lo().writerApi){const a=$t(),n=$t(),r=ye(!1);async function o(s){n.value=void 0,r.value=!0;try{L1[s]??(L1[s]=t.fetchUserById(s)),a.value=await L1[s]}catch(i){n.value=i,a.value=void 0}finally{r.value=!1}}return We(e,o,{immediate:!0}),{user:jt(a),isLoading:jt(r),error:jt(n)}}function wde(e,t){const a=Od(),{removeComponentSubtree:n,generateNewComponentId:r}=Fs(e,t),o=ye(!1),s=ye(),i=ye("show"),l=ye(),c=$t(),d=H(()=>s.value?y(s.value):void 0);async function u(S){const L=x(S).createdBy.value,F=await qc();return L===F.id}async function h(S,L="show"){if(S===void 0){c.value=void 0,s.value=void 0,i.value="show";return}if(L==="edit"){const F=y(S);if(!await u(F))return a.pushToast({type:"error",message:"You cannot edit this note because it was created by another user"})}i.value=L,s.value=S,f(S)}function f(S){let L=e.getComponentById(S);for(;L;){switch(L.type){case"blueprints_root":t.mode.value="blueprints";break;case"root":t.mode.value="ui";break;case"blueprints_blueprint":case"page":e.setActivePageId(L.id);break}L=e.getComponentById(L.parentId)}}async function m(S,L){let F;"instancePath"in L&&(F=typeof L.instancePath=="string"?L.instancePath:a8(L.instancePath));const te=await qc(),J=r();return c.value={id:J,type:"note",parentId:S,content:{parentInstancePath:F,content:"",createdBy:String(te.id),createdAt:new Date().toISOString()},x:"x"in L?L.x:void 0,y:"y"in L?L.y:void 0},await h(J,"edit"),J}We(s,()=>{c.value&&c.value.id!==s.value&&(c.value=void 0)});async function g(S){const L=y(S);if(!await u(L))return a.pushToast({type:"error",message:"You cannot delete this note because it was created by another user"});h(void 0),n(S)}function*_(){yield*v("root"),yield*v("blueprints_root")}function*b(S){if(!S){yield*_();return}const L=S.toLocaleLowerCase();for(const F of _()){if(!F.content.content)continue;String(F.content.content).toLocaleLowerCase().includes(L)&&(yield F)}}function*v(S){var L;for(const F of e.getComponentsNested(S))F.type==="note"&&(yield F);if(c.value){let F=c.value.parentId;for(;F;){if(F===S){yield jt(c.value);return}F=(L=e.getComponentById(F))==null?void 0:L.parentId}}}function y(S){var F;const L=e.getComponentById(S);if((L==null?void 0:L.type)==="note")return L;if(((F=c.value)==null?void 0:F.id)===S)return jt(c.value)}const M=S=>{var L;return String(((L=S.content)==null?void 0:L.content)??"")};function x(S){const L=new Intl.DateTimeFormat(void 0,{dateStyle:"short",timeStyle:"short"}),F=H(()=>{var K,G,T;const Me=(K=E(S))==null?void 0:K.id,ee=(G=E(S))==null?void 0:G.content;return l.value===Me?"hover":((T=d.value)==null?void 0:T.id)===Me?ee.content?"active":"new":"default"}),te=H(()=>M(E(S))),J=H(()=>E(S).content.createdAt),be=H(()=>E(S).content.parentInstancePath),oe=H(()=>{var ee;const Me=(ee=E(S).content)==null?void 0:ee.createdBy;return Me?Number(Me):void 0}),Te=H(()=>{if(!J.value)return"";const Me=new Date(J.value);return L.format(Me)}),Ue=H(()=>Ze(E(S).id)==="blueprints_root"?"blueprints":"ui");function Ze(Me){const ee=e.getComponentById(Me);return ee?Ze(ee.parentId)??Me:Me}return{content:te,type:Ue,createdBy:oe,createdAt:J,createdAtFormatted:Te,state:F,parentInstancePath:be}}return{isAnnotating:o,createNote:m,getNotes:v,selectNote:h,searchNotes:b,getAllNotes:_,deleteNote:g,selectedNoteId:jt(s),selectedNoteMode:jt(i),selectedNote:d,hoveredNoteId:l,useNoteInformation:x,getNoteContent:M}}function xde(e){const t="vault",a=$t({}),n=ye(!1),r=ye(!1),o=ye(!1),{writerApi:s}=lo();async function i(){try{return(await s.fetchSecret(e.writerOrgId.value,e.writerAppId.value,t)).secret}catch{return}}async function l(){if(e.isWriterCloudApp.value){n.value=!0,o.value=!1;try{const d=await i();a.value=d??{}}finally{n.value=!1}}}async function c(d){if(!e.isWriterCloudApp.value)return;r.value=!0,o.value=!1;const u=await i();try{u===void 0?await s.createSecret(e.writerOrgId.value,e.writerAppId.value,t,d):await s.updateSecret(e.writerOrgId.value,e.writerAppId.value,t,d),a.value=d}catch(h){o.value=h}finally{r.value=!1}}return{secrets:a,load:l,readonly:H(()=>n.value||r.value),isLoading:jt(n),isSaving:jt(r),update:c}}function Cde(e){const t=fa();async function a(){if(!e.isWriterCloudApp.value){t.log("Skipping config.js load - not a Writer Cloud App");return}if(!(typeof window<"u"&&window.__WRITER_APP_CONFIG__))try{const{writerApi:n}=lo(),r=await n.fetchConfigJs(),o=document.createElement("script");o.textContent=r,document.head.appendChild(o)}catch(n){t.warn("Failed to load config.js via WriterApi ",n)}}return{loadConfigJs:a}}const _n=gde();globalThis.vue=aw;globalThis.injectionKeys=ne;globalThis.core=_n;const Gr=fa();async function Ade(){await _n.init();const e=_n.mode.value,t=e=="edit"?Ow():void 0,a=wde(_n,t),n=e=="edit"?xde(_n):void 0,r=e=="edit"?bde(_n):void 0;t&&(_n.addMailSubscription("logEntry",t.handleLogEntry),_n.addCollaborationPingSubscription(r.handleIncomingCollaborationUpdate),globalThis.wfbm=t),Gr.log(`Mounting app in mode ${e}...`);const{default:o}=e==="run"&&await zt(()=>import("./ComponentRenderer-BJGX_6iU.js"),__vite__mapDeps([18,19]),import.meta.url),{default:s}=e==="edit"&&await zt(()=>import("./BuilderApp-CVdXjiyA.js").then(c=>c.c),__vite__mapDeps([20,5,6,21,22]),import.meta.url),i=rl(o||s);i.use(Aw),i.provide(ne.core,_n),i.provide(ne.builderManager,t),i.provide(ne.notesManager,a),i.provide(ne.collaborationManager,r),i.provide(ne.secretsManager,n),i.mount("#app");const{loadConfigJs:l}=Cde(_n);l().catch(Gr.error),_n.isWriterCloudApp.value&&r&&await Sde(r).catch(Gr.error),_n.isWriterCloudApp.value&&n&&n.load().catch(Gr.error)}async function Sde(e){const{writerApi:t}=lo(),a=await t.fetchUserProfile();e.updateOutgoingPing({userId:a.id,action:"join"}),e.sendCollaborationPing(),e.groomSnapshot(),window.addEventListener("beforeunload",function(){e.updateOutgoingPing({action:"leave"}),e.sendCollaborationPing()})}async function $de(){var e;for(let t=0;t<oc;t++)try{await Ade();return}catch(a){if(t<oc-1){if(Gr.warn(`Core initialization failed (attempt ${t+1}/${oc}). Retrying...`,a),document.getElementById("loading_L1")&&!document.getElementById("loading_message")&&t>=2){const r=document.createElement("div");r.id="loading_message",r.textContent=`We're getting things ready.
8525
+ Hang tight while we connect...`,r.style.cssText="position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);margin-top:120px;text-align:center;font-family: 'Poppins','Helvetica Neue','Lucida Grande',sans-serif;color:#666;font-size:14px;line-height:1.4;max-width:400px;padding:0 20px;z-index:1000;white-space:pre-line;opacity:0;transition:opacity 0.5s ease-in;",(e=document.getElementById("loading_L1"))==null||e.appendChild(r),setTimeout(()=>{r.style.opacity="1"},50)}await new Promise(r=>setTimeout(r,i8*(t+1)));continue}throw a}}Gr.log("Initialising core...");$de().then(async()=>{Gr.log("Core initialised.")}).catch(e=>{Gr.error("Core initialisation failed.",e);const t=document.createElement("div");t.className="error-message",t.setAttribute("role","alert"),t.style.cssText='padding: 20px; color: #d32f2f; background: #ffebee; border: 1px solid #e57373; border-radius: 4px; margin: 20px; font-family: "Poppins", "Helvetica Neue", "Lucida Grande", sans-serif;';const a=document.createElement("div");a.textContent="Failed to initialise application"+(e!=null&&e.message?`: ${e.message}`:"");const n=document.createElement("div");n.style.marginTop="12px",n.textContent="This might mean the Agent Builder is still being prepared. Try reloading the page in a few seconds.";const r=document.createElement("button");r.textContent="Reload page",r.className="WdsButton WdsButton--small WdsButton--tertiary",r.style.cssText="margin-top: 16px; font-size: .875rem; font-weight: 600; border-radius: 300px; padding: 4px 16px; height: 32px; background: var(--wdsColorWhite); color: var(--wdsColorBlack); border-color: var(--wdsColorGray2); border-width: 1px; border-style: solid; box-shadow: var(--buttonShadow); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; outline: none; position: relative; overflow: hidden; max-width: 100%; width: fit-content;",r.onclick=()=>window.location.reload(),t.appendChild(a),t.appendChild(n),t.appendChild(r);const o=document.getElementById("loading_L1");o==null||o.remove();const s=document.getElementById("loading_message");s&&s.remove(),document.body.appendChild(t)});export{fa as $,pa as A,Sd as B,Td as C,Je as D,Ot as E,ot as F,ft as G,Ode as H,Ts as I,qt as J,wt as K,qa as L,T2e as M,Rde as N,I2e as O,Bde as P,zt as Q,E as R,ge as S,jg as T,Ki as U,Od as V,La as W,lo as X,$t as Y,jt as Z,ke as _,ne as a,kde as a$,Zde as a0,$0 as a1,t8 as a2,Sg as a3,Lg as a4,Ice as a5,ws as a6,ba as a7,Zn as a8,fl as a9,Y_ as aA,_0 as aB,e0e as aC,Sw as aD,Vd as aE,Ad as aF,Ub as aG,a0 as aH,Fde as aI,mn as aJ,t_ as aK,oce as aL,J2e as aM,Pw as aN,E0 as aO,Bi as aP,Xx as aQ,c6 as aR,Dx as aS,Dde as aT,v0 as aU,K3 as aV,Sv as aW,one as aX,Pd as aY,Ude as aZ,gte as a_,Zr as aa,hse as ab,_v as ac,Fc as ad,St as ae,pde as af,Nd as ag,js as ah,qde as ai,zc as aj,hde as ak,fde as al,l8 as am,jn as an,ir as ao,lr as ap,sn as aq,$r as ar,Sse as as,Ht as at,o_ as au,O_ as av,fg as aw,Fs as ax,Hv as ay,Wde as az,Ie as b,b0,Tde as b1,Pde as b2,kr as b3,Ui as b4,Moe as b5,Ug as b6,Ps as b7,Q as b8,Lde as b9,cv as bA,Hde as bB,i0e as bC,Vde as ba,zE as bb,YE as bc,jde as bd,c0e as be,cs as bf,ji as bg,e8 as bh,o0e as bi,n8 as bj,Ew as bk,Ed as bl,zg as bm,qg as bn,Li as bo,zde as bp,m0 as bq,Ev as br,Mg as bs,Rd as bt,Vi as bu,Nde as bv,Yg as bw,mg as bx,gn as by,iv as bz,H as c,$e as d,L0e as e,R as f,Z as g,q0e as h,re as i,a8 as j,En as k,Kl as l,pt as m,Ri as n,$ as o,Bv as p,ia as q,ye as r,Ya as s,je as t,Hd as u,Un as v,We as w,Ce as x,bt as y,Xe as z};