@africode/core 5.0.10 → 5.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +585 -585
- package/AGENT_INSTRUCTIONS.md +595 -595
- package/COMPONENT_SCHEMA.json +1826 -1800
- package/LICENSE +623 -623
- package/README.md +476 -476
- package/bin/africode.js +73 -73
- package/bin/cli.ts +82 -82
- package/bin/create-africode.js +220 -220
- package/bin/scaffold.ts +218 -218
- package/components/accordion.js +183 -183
- package/components/alert.js +131 -131
- package/components/auth-form.js +154 -154
- package/components/auth.js +172 -172
- package/components/avatar.js +117 -117
- package/components/badge.js +104 -104
- package/components/base.d.ts +139 -139
- package/components/base.js +234 -234
- package/components/breadcrumb.js +76 -72
- package/components/button.js +164 -164
- package/components/card.js +144 -137
- package/components/carousel.js +32 -32
- package/components/cart-drawer.js +28 -28
- package/components/code-block.js +20 -20
- package/components/contact-form.js +25 -25
- package/components/cookie-consent.js +23 -23
- package/components/cta-banner.js +38 -38
- package/components/cultural-card.js +243 -243
- package/components/dashboard-activity-list.js +103 -103
- package/components/dashboard-card.js +85 -85
- package/components/dashboard-metric.js +81 -81
- package/components/dashboard-shell.js +85 -85
- package/components/dashboard-topbar.js +84 -84
- package/components/divider.js +83 -83
- package/components/dropdown.js +171 -171
- package/components/error-boundary.js +155 -155
- package/components/faq-accordion.js +23 -23
- package/components/feature-grid.js +85 -85
- package/components/file-uploader.js +22 -22
- package/components/filter-bar.js +19 -19
- package/components/footer.js +113 -113
- package/components/form.js +131 -131
- package/components/gallery.js +22 -22
- package/components/hero.js +140 -138
- package/components/icon.js +36 -36
- package/components/index.js +128 -128
- package/components/input.js +252 -256
- package/components/kanga-card.js +185 -185
- package/components/kyc-upload.js +173 -173
- package/components/language-switcher.js +108 -108
- package/components/loader.js +80 -80
- package/components/modal.js +262 -262
- package/components/motion.js +84 -84
- package/components/nav-drawer.js +216 -216
- package/components/navbar.js +243 -236
- package/components/newsletter-signup.js +24 -24
- package/components/pagination.js +31 -31
- package/components/pattern-showcase.js +225 -225
- package/components/pricing-card.js +100 -100
- package/components/product-card.js +41 -41
- package/components/progress.js +132 -134
- package/components/react.js +111 -111
- package/components/search-box.js +24 -24
- package/components/section.js +54 -54
- package/components/select.js +321 -322
- package/components/sidebar.js +180 -180
- package/components/simple-chart.js +22 -22
- package/components/skeleton.js +85 -85
- package/components/stepper.js +28 -28
- package/components/table.js +181 -181
- package/components/tabs.js +202 -202
- package/components/team-grid.js +23 -23
- package/components/testimonial.js +94 -94
- package/components/theme-toggle.js +82 -82
- package/components/toast.js +139 -139
- package/components/tooltip.js +167 -167
- package/components/transaction-ledger.js +138 -138
- package/components/ui-avatar.js +79 -79
- package/components/ui-badge.js +61 -61
- package/components/ui-button.js +149 -149
- package/components/ui-card.js +74 -75
- package/components/ui-chip.js +87 -87
- package/components/ui-input.js +110 -110
- package/components/ui-popover.js +84 -84
- package/components/ui-progress-ring.js +60 -60
- package/components/ui-select.js +85 -85
- package/components/ui-stat.js +75 -75
- package/components/ui-switch.js +85 -85
- package/components/ui-table.js +69 -69
- package/components/ui-tabs.js +99 -99
- package/components/ui-tag.js +64 -64
- package/components/ui-textarea.js +84 -84
- package/components/ui-tooltip.js +66 -66
- package/components/video-player.js +22 -22
- package/components/wallet-balance.js +114 -114
- package/core/a2ui-schema-manager.js +351 -351
- package/core/a2ui.js +696 -696
- package/core/actions.js +27 -27
- package/core/bun-runtime.js +398 -397
- package/core/cli/commands/add.js +23 -23
- package/core/cli/commands/audit.js +58 -58
- package/core/cli/commands/build.js +193 -193
- package/core/cli/commands/create-plugin.js +241 -241
- package/core/cli/commands/dev.js +252 -285
- package/core/cli/commands/lint.js +23 -23
- package/core/cli/commands/test.js +33 -34
- package/core/cli/migrator.js +71 -71
- package/core/cli/ui.js +56 -56
- package/core/compliance.js +823 -823
- package/core/config.js +265 -265
- package/core/db-advanced.js +478 -481
- package/core/db.js +282 -284
- package/core/enhanced-hmr.js +406 -406
- package/core/errors.js +222 -222
- package/core/file-router.js +52 -50
- package/core/hmr-client.js +203 -204
- package/core/hmr.js +205 -197
- package/core/html.d.ts +30 -30
- package/core/html.js +84 -84
- package/core/hydration.js +52 -52
- package/core/lipa-namba-journey.js +548 -605
- package/core/logging.js +14 -14
- package/core/middleware.js +145 -145
- package/core/motion.js +106 -106
- package/core/nida-cig-middleware.js +417 -460
- package/core/patterns.d.ts +124 -124
- package/core/patterns.js +947 -1001
- package/core/plugins/index.js +345 -345
- package/core/request-analytics.js +253 -253
- package/core/request-identity.js +93 -93
- package/core/router.js +386 -386
- package/core/sdk-browser.js +140 -140
- package/core/sdk-client.js +61 -61
- package/core/sdk.d.ts +133 -133
- package/core/sdk.js +148 -148
- package/core/seo.js +76 -76
- package/core/server/auth-endpoints.js +339 -339
- package/core/server/auth.js +180 -180
- package/core/server/csrf.js +200 -206
- package/core/server/db.js +39 -39
- package/core/server/middleware.js +324 -324
- package/core/server/rate-limit.js +238 -238
- package/core/server/render.js +67 -69
- package/core/server/router.js +102 -120
- package/core/session-store.js +68 -68
- package/core/shim.js +28 -28
- package/core/state.d.ts +86 -86
- package/core/state.js +276 -276
- package/core/store.d.ts +122 -122
- package/core/store.js +61 -61
- package/core/validation.d.ts +232 -232
- package/core/validation.js +602 -602
- package/core/websocket.js +656 -641
- package/dist/africode.js +233 -230
- package/dist/africode.js.map +83 -83
- package/dist/build-info.json +3 -3
- package/dist/components.js +195 -192
- package/dist/components.js.map +73 -73
- package/dist/styles/africanity.css +321 -321
- package/dist/styles/typography.css +140 -140
- package/docs/IDE-Guide.md +50 -50
- package/package.json +113 -113
- package/scripts/generate-component-schema.js +82 -79
- package/styles/africanity.css +321 -321
- package/styles/typography.css +140 -140
- package/templates/starter/.env.example +15 -15
- package/templates/starter/africode.config.js +40 -40
- package/templates/starter/package.json +13 -13
- package/templates/starter/src/index.js +18 -18
- package/templates/starter/src/pages/index.html +55 -55
- package/templates/starter/src/pages/index.js +17 -17
- package/templates/starter/src/styles/main.css +3 -3
- package/templates/starter-3d/.env.example +7 -7
- package/templates/starter-3d/africode.config.js +29 -29
- package/templates/starter-3d/components/af-model-viewer.js +125 -125
- package/templates/starter-3d/package.json +14 -14
- package/templates/starter-3d/src/pages/index.html +55 -55
- package/templates/starter-3d/src/pages/index.js +50 -50
- package/templates/starter-3d/src/styles/main.css +3 -3
- package/templates/starter-dashboard/.env.example +21 -21
- package/templates/starter-dashboard/africode.config.js +20 -20
- package/templates/starter-dashboard/package.json +14 -14
- package/templates/starter-dashboard/src/index.js +17 -17
- package/templates/starter-dashboard/src/pages/api/analytics.js +24 -24
- package/templates/starter-dashboard/src/pages/index.html +118 -118
- package/templates/starter-dashboard/src/pages/index.js +110 -110
- package/templates/starter-dashboard/src/styles/main.css +172 -172
- package/templates/starter-fintech/.env.example +28 -28
- package/templates/starter-fintech/africode.config.js +20 -20
- package/templates/starter-fintech/package.json +15 -15
- package/templates/starter-fintech/src/index.js +17 -17
- package/templates/starter-fintech/src/pages/api/auth.js +45 -45
- package/templates/starter-fintech/src/pages/api/dashboard.js +19 -0
- package/templates/starter-fintech/src/pages/api/transfer.js +65 -65
- package/templates/starter-fintech/src/pages/api/wallet.js +39 -39
- package/templates/starter-fintech/src/pages/api/webhooks/payment.js +32 -32
- package/templates/starter-fintech/src/pages/index.html +169 -169
- package/templates/starter-fintech/src/pages/index.js +161 -161
- package/templates/starter-fintech/src/styles/main.css +246 -246
- package/templates/starter-react/.env.example +15 -15
- package/templates/starter-react/africode.config.js +40 -40
- package/templates/starter-react/package.json +15 -15
- package/templates/starter-react/src/pages/index.html +55 -55
- package/templates/starter-react/src/pages/index.js +68 -68
- package/templates/starter-react/src/styles/main.css +3 -3
- package/templates/starter-tailwind/.env.example +15 -15
- package/templates/starter-tailwind/africode.config.js +40 -40
- package/templates/starter-tailwind/package.json +19 -19
- package/templates/starter-tailwind/src/pages/index.html +55 -55
- package/templates/starter-tailwind/src/pages/index.js +67 -67
- package/templates/starter-tailwind/src/styles/main.css +3 -3
- package/templates/starter-tailwind/src/styles/tailwind.css +1 -1
- package/templates/starter-tailwind/src/tailwind-loader.js +30 -30
- package/templates/starter-tailwind/tailwind.config.cjs +18 -18
- package/templates/starter-website/.env.example +18 -18
- package/templates/starter-website/africode.config.js +20 -20
- package/templates/starter-website/package.json +14 -14
- package/templates/starter-website/src/index.js +17 -17
- package/templates/starter-website/src/pages/index.html +124 -124
- package/templates/starter-website/src/pages/index.js +116 -116
- package/templates/starter-website/src/styles/main.css +195 -195
- package/bin/africode.js.1758507140 +0 -343
- package/core/heartbeat.js +0 -64
package/dist/components.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var
|
|
1
|
+
var pe=Object.defineProperty;var ve=(t)=>t;function ue(t,n){this[t]=ve.bind(null,n)}var u=(t,n)=>{for(var r in n)pe(t,r,{get:n[r],enumerable:!0,configurable:!0,set:ue.bind(n,r)})};var m=(t,n)=>()=>(t&&(n=t(t=0)),n);class Nn{constructor(t){this.value=t,this.__type="RawHtml",Object.freeze(this)}toString(){return this.value}valueOf(){return this.value}}function $e(t){return String(t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function er(t){if(t instanceof Nn)return t.toString();if(Array.isArray(t))return t.map(er).join("");if(t===null||t===void 0||t===!1)return"";if(t===!0)return"true";return $e(t)}var g=(t,...n)=>{let r="";for(let o=0;o<t.length;o++)if(r+=t[o],o<n.length)r+=er(n[o]);return new Nn(r)};function f(t,n){if(typeof customElements>"u")return;if(!customElements.get(t))customElements.define(t,n)}var we,lr,i;var v=m(()=>{we=globalThis.HTMLElement??class{},lr=typeof CSSStyleSheet<"u";i=class i extends we{constructor(){super();this.attachShadow({mode:"open"});let t=this.render;if(t&&typeof t==="function")this.render=()=>{try{t.call(this),this.removeAttribute("has-error")}catch(n){console.error(`[AfriCode] Rendering error in <${this.localName}>:`,n),this.setAttribute("has-error","true"),this.shadowRoot.innerHTML=`
|
|
2
2
|
<style>
|
|
3
3
|
.af-local-error {
|
|
4
4
|
padding: 1rem;
|
|
@@ -17,7 +17,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
17
17
|
<span aria-hidden="true">⚠️</span>
|
|
18
18
|
<span>Failed to render</span>
|
|
19
19
|
</div>
|
|
20
|
-
`,this.emit("af-component-error",{component:this.localName,message:n.message,stack:n.stack})}}}connectedCallback(){}static styleCache=new Map;static globalSheets=[];static injectGlobalSheet(t){if(!
|
|
20
|
+
`,this.emit("af-component-error",{component:this.localName,message:n.message,stack:n.stack})}}}connectedCallback(){}static styleCache=new Map;static globalSheets=[];static injectGlobalSheet(t){if(!lr)return;if(!(t instanceof CSSStyleSheet))return;if(!i.globalSheets.includes(t))i.globalSheets.push(t)}async loadStyles(t=""){if(!this.shadowRoot)return;let r=lr&&"adoptedStyleSheets"in this.shadowRoot,o=typeof t==="string"&&t.length>0?t:"/styles/africanity.css",a=typeof t==="string"&&t.length>0?t:null;if(i.styleCache.has(o)){let e=i.styleCache.get(o);if(r)this.shadowRoot.adoptedStyleSheets=[e,...i.globalSheets];else this._applyFallbackStyle(e?.cssText||e?.text||e||"");return}try{let e=a;if(!e){let l=await fetch("/styles/africanity.css");if(!l.ok)throw Error(`Unable to load stylesheet: ${l.status}`);e=await l.text()}if(r){let l=new CSSStyleSheet;l.replaceSync(e),i.styleCache.set(o,l),this.shadowRoot.adoptedStyleSheets=[l,...i.globalSheets];return}this._applyFallbackStyle(e),i.styleCache.set(o,{text:e})}catch{this._applyFallbackStyle(a||"")}}_applyFallbackStyle(t){if(!this.shadowRoot)return;let n=this.shadowRoot.querySelector("style[data-africode-core-styles]");if(!n)n=document.createElement("style"),n.setAttribute("data-africode-core-styles",""),this.shadowRoot.prepend(n);n.textContent=t}spacing(t){return`var(--space-${t})`}createElement(t,{classes:n=[],attributes:r={},text:o=""}={}){let a=document.createElement(t);if(n.length)a.classList.add(...n);if(Object.entries(r).forEach(([e,l])=>a.setAttribute(e,l)),o)a.textContent=o;return a}emit(t,n){this.dispatchEvent(new CustomEvent(t,{detail:n,bubbles:!0,composed:!0}))}}});var br={};u(br,{default:()=>xe,AfriUIButton:()=>ut});var ut,xe;var Vn=m(()=>{v();ut=class ut extends i{static get observedAttributes(){return["variant","size","disabled","loading","full-width","aria-label"]}constructor(){super();this.render()}connectedCallback(){this.shadowRoot.querySelector("button")?.addEventListener("click",(n)=>{if(this.hasAttribute("disabled")||this.hasAttribute("loading")){n.preventDefault();return}this.emit("af-ui-button-click",{originalEvent:n})})}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("variant")||"primary",n=this.getAttribute("size")||"md",r=this.hasAttribute("disabled"),o=this.hasAttribute("loading"),a=this.getAttribute("aria-label")||"";this.shadowRoot.innerHTML=g`
|
|
21
21
|
<style>
|
|
22
22
|
:host { display: inline-block; }
|
|
23
23
|
|
|
@@ -117,7 +117,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
117
117
|
${o?g`<span class="spinner"></span>`:""}
|
|
118
118
|
<slot></slot>
|
|
119
119
|
</button>
|
|
120
|
-
`}};
|
|
120
|
+
`}};f("af-ui-button",ut);xe=ut});var ir={};u(ir,{default:()=>Ae,AfriUICard:()=>$t});var $t,Ae;var Kn=m(()=>{v();$t=class $t extends i{static get observedAttributes(){return["variant","bordered","clickable"]}constructor(){super();this.render()}connectedCallback(){if(this.loadStyles(),this.hasAttribute("clickable"))this.shadowRoot.querySelector(".card")?.addEventListener("click",()=>{this.emit("af-ui-card-click")})}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("variant")||"elevated";this.shadowRoot.innerHTML=g`
|
|
121
121
|
<style>
|
|
122
122
|
:host { display: block; }
|
|
123
123
|
|
|
@@ -147,7 +147,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
147
147
|
<article class="card ${t}">
|
|
148
148
|
<slot></slot>
|
|
149
149
|
</article>
|
|
150
|
-
`}};
|
|
150
|
+
`}};f("af-ui-card",$t);Ae=$t});var fr={};u(fr,{default:()=>_e,AfriUIInput:()=>wt});var wt,_e;var jn=m(()=>{v();wt=class wt extends i{static get observedAttributes(){return["label","placeholder","type","value","disabled","error"]}constructor(){super();this.render()}connectedCallback(){this._attachListeners(),this.loadStyles()}attributeChangedCallback(){this.render(),this._attachListeners()}_attachListeners(){let t=this.shadowRoot.querySelector("input");if(!t)return;t.addEventListener("input",()=>{this.emit("af-ui-input",{value:t.value})})}render(){let t=this.getAttribute("label")||"",n=this.getAttribute("placeholder")||"",r=this.getAttribute("type")||"text",o=this.getAttribute("value")||"",a=this.hasAttribute("disabled"),e=this.getAttribute("error")||"";this.shadowRoot.innerHTML=g`
|
|
151
151
|
<style>
|
|
152
152
|
:host { display: block; font-family: 'Inter', system-ui, sans-serif; }
|
|
153
153
|
|
|
@@ -205,7 +205,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
205
205
|
/>
|
|
206
206
|
<div class="error">${e}</div>
|
|
207
207
|
</div>
|
|
208
|
-
`}};
|
|
208
|
+
`}};f("af-ui-input",wt);_e=wt});var dr={};u(dr,{default:()=>ke,AfriUIBadge:()=>xt});var xt,ke;var Cn=m(()=>{v();xt=class xt extends i{static get observedAttributes(){return["variant","size","pill"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("variant")||"secondary",n=this.getAttribute("size")||"md",r=this.hasAttribute("pill");this.shadowRoot.innerHTML=g`
|
|
209
209
|
<style>
|
|
210
210
|
:host { display: inline-block; font-family: 'Inter', system-ui, sans-serif; }
|
|
211
211
|
|
|
@@ -232,7 +232,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
232
232
|
</style>
|
|
233
233
|
|
|
234
234
|
<span class="badge ${t}"><slot></slot></span>
|
|
235
|
-
`}};
|
|
235
|
+
`}};f("af-ui-badge",xt);ke=xt});var cr={};u(cr,{default:()=>qe,AfriUISwitch:()=>At});var At,qe;var In=m(()=>{v();At=class At extends i{static get observedAttributes(){return["checked","disabled","size"]}constructor(){super();this.render()}connectedCallback(){this.shadowRoot.querySelector("button")?.addEventListener("click",(t)=>{if(this.hasAttribute("disabled"))return;let n=!this.hasAttribute("checked");if(n)this.setAttribute("checked","");else this.removeAttribute("checked");this.emit("af-ui-switch-toggle",{checked:n,originalEvent:t})})}attributeChangedCallback(){this.render()}render(){let t=this.hasAttribute("checked"),n=this.hasAttribute("disabled"),r=this.getAttribute("size")||"md",o=r==="sm"?{width:36,height:20,knob:14}:r==="lg"?{width:56,height:32,knob:24}:{width:48,height:28,knob:20},a=t?"true":"false";this.shadowRoot.innerHTML=g`
|
|
236
236
|
<style>
|
|
237
237
|
:host { display: inline-block; }
|
|
238
238
|
|
|
@@ -267,7 +267,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
267
267
|
<button role="switch" aria-checked="${a}" ${n?"disabled":""}>
|
|
268
268
|
<span class="knob"></span>
|
|
269
269
|
</button>
|
|
270
|
-
`}};
|
|
270
|
+
`}};f("af-ui-switch",At);qe=At});var hr={};u(hr,{default:()=>Ee,AfriUISelect:()=>_t});var _t,Ee;var Pn=m(()=>{v();_t=class _t extends i{static get observedAttributes(){return["label","placeholder","disabled","error"]}constructor(){super();this.render()}connectedCallback(){this._attachListeners(),this.loadStyles()}attributeChangedCallback(){this.render(),this._attachListeners()}_attachListeners(){let t=this.shadowRoot.querySelector("select");if(!t)return;t.addEventListener("change",()=>{this.emit("af-ui-select",{value:t.value})})}render(){let t=this.getAttribute("label")||"",n=this.getAttribute("placeholder")||"Select an option",r=this.hasAttribute("disabled"),o=this.getAttribute("error")||"";this.shadowRoot.innerHTML=g`
|
|
271
271
|
<style>
|
|
272
272
|
:host { display: block; font-family: 'Inter', system-ui, sans-serif; }
|
|
273
273
|
|
|
@@ -303,7 +303,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
303
303
|
</select>
|
|
304
304
|
<div class="error">${o}</div>
|
|
305
305
|
</div>
|
|
306
|
-
`}};
|
|
306
|
+
`}};f("af-ui-select",_t);Ee=_t});var gr={};u(gr,{default:()=>Me,AfriUITextarea:()=>kt});var kt,Me;var Tn=m(()=>{v();kt=class kt extends i{static get observedAttributes(){return["label","placeholder","rows","disabled","error"]}constructor(){super();this.render()}connectedCallback(){this._attachListeners(),this.loadStyles()}attributeChangedCallback(){this.render(),this._attachListeners()}_attachListeners(){let t=this.shadowRoot.querySelector("textarea");if(!t)return;t.addEventListener("input",()=>{this.emit("af-ui-textarea",{value:t.value})})}render(){let t=this.getAttribute("label")||"",n=this.getAttribute("placeholder")||"",r=this.getAttribute("rows")||"4",o=this.hasAttribute("disabled"),a=this.getAttribute("error")||"";this.shadowRoot.innerHTML=g`
|
|
307
307
|
<style>
|
|
308
308
|
:host { display: block; font-family: 'Inter', system-ui, sans-serif; }
|
|
309
309
|
|
|
@@ -337,7 +337,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
337
337
|
<textarea rows="${r}" placeholder="${n}" ${o?"disabled":""}></textarea>
|
|
338
338
|
<div class="error">${a}</div>
|
|
339
339
|
</div>
|
|
340
|
-
`}};
|
|
340
|
+
`}};f("af-ui-textarea",kt);Me=kt});var mr={};u(mr,{default:()=>He,AfriUIChip:()=>qt});var qt,He;var Zn=m(()=>{v();qt=class qt extends i{static get observedAttributes(){return["variant","size","dismissible"]}constructor(){super();this.render()}connectedCallback(){this.render(),this._attachListeners()}attributeChangedCallback(){this.render(),this._attachListeners()}_attachListeners(){let t=this.shadowRoot.querySelector(".chip button");if(!t)return;t.addEventListener("click",(n)=>{n.stopPropagation(),this.emit("af-ui-chip-dismiss",{})})}render(){let t=this.getAttribute("variant")||"neutral",n=this.getAttribute("size")||"md",r=this.hasAttribute("dismissible");this.shadowRoot.innerHTML=g`
|
|
341
341
|
<style>
|
|
342
342
|
:host { display: inline-flex; }
|
|
343
343
|
|
|
@@ -375,7 +375,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
375
375
|
<slot></slot>
|
|
376
376
|
${r?g`<button aria-label="Remove">×</button>`:""}
|
|
377
377
|
</span>
|
|
378
|
-
`}};
|
|
378
|
+
`}};f("af-ui-chip",qt);He=qt});var sr={};u(sr,{default:()=>Le,AfriUITag:()=>Et});var Et,Le;var zn=m(()=>{v();Et=class Et extends i{static get observedAttributes(){return["variant","size"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("variant")||"secondary",n=this.getAttribute("size")||"md",r={sm:"0.25rem 0.6rem",md:"0.35rem 0.8rem",lg:"0.5rem 1rem"};this.shadowRoot.innerHTML=g`
|
|
379
379
|
<style>
|
|
380
380
|
:host { display: inline-block; font-family: 'Inter', sans-serif; }
|
|
381
381
|
|
|
@@ -401,7 +401,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
401
401
|
</style>
|
|
402
402
|
|
|
403
403
|
<span class="tag ${t}"><slot></slot></span>
|
|
404
|
-
`}};
|
|
404
|
+
`}};f("af-ui-tag",Et);Le=Et});var pr={};u(pr,{default:()=>Se,AfriUIAvatar:()=>Mt});var Mt,Se;var to=m(()=>{v();Mt=class Mt extends i{static get observedAttributes(){return["src","initials","size","badge"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("src"),n=this.getAttribute("initials")||"AC",r=this.getAttribute("size")||"md",o=r==="sm"?"32px":r==="lg"?"64px":"48px",a=this.getAttribute("badge");this.shadowRoot.innerHTML=g`
|
|
405
405
|
<style>
|
|
406
406
|
:host { display: inline-flex; }
|
|
407
407
|
|
|
@@ -444,7 +444,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
444
444
|
${t?g`<img src="${t}" alt="Avatar" />`:g`<span>${n}</span>`}
|
|
445
445
|
${a?g`<span class="badge">${a}</span>`:""}
|
|
446
446
|
</div>
|
|
447
|
-
`}};
|
|
447
|
+
`}};f("af-ui-avatar",Mt);Se=Mt});var vr={};u(vr,{default:()=>Re,AfriUIProgressRing:()=>Ht});var Ht,Re;var no=m(()=>{v();Ht=class Ht extends i{static get observedAttributes(){return["value","size","stroke","label"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=Number(this.getAttribute("value")||0),n=Number(this.getAttribute("size")||96),r=Number(this.getAttribute("stroke")||10),o=this.getAttribute("label")||"",a=(n-r)/2,e=2*Math.PI*a,l=e-t/100*e;this.shadowRoot.innerHTML=g`
|
|
448
448
|
<style>
|
|
449
449
|
:host { display: inline-flex; align-items: center; justify-content: center; }
|
|
450
450
|
.ring { position: relative; width: ${n}px; height: ${n}px; }
|
|
@@ -466,7 +466,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
466
466
|
${o?g`<div class="subtitle">${o}</div>`:""}
|
|
467
467
|
</div>
|
|
468
468
|
</div>
|
|
469
|
-
`}};
|
|
469
|
+
`}};f("af-ui-progress-ring",Ht);Re=Ht});var ur={};u(ur,{default:()=>Ye,AfriUITooltip:()=>Lt});var Lt,Ye;var oo=m(()=>{v();Lt=class Lt extends i{static get observedAttributes(){return["text","position"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("text")||"",n=this.getAttribute("position")||"top";this.shadowRoot.innerHTML=g`
|
|
470
470
|
<style>
|
|
471
471
|
:host { position: relative; display: inline-flex; }
|
|
472
472
|
|
|
@@ -499,7 +499,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
499
499
|
</style>
|
|
500
500
|
<slot></slot>
|
|
501
501
|
<div class="tooltip ${n}" role="tooltip">${t}</div>
|
|
502
|
-
`}};
|
|
502
|
+
`}};f("af-ui-tooltip",Lt);Ye=Lt});var $r={};u($r,{default:()=>Xe,AfriUIPopover:()=>St});var St,Xe;var ro=m(()=>{v();St=class St extends i{static get observedAttributes(){return["label","open"]}constructor(){super();this._open=this.hasAttribute("open"),this.render()}connectedCallback(){this._attachListeners()}attributeChangedCallback(){this._open=this.hasAttribute("open"),this.render(),this._attachListeners()}_attachListeners(){let t=this.shadowRoot.querySelector(".trigger");if(!t)return;t.addEventListener("click",()=>{if(this._open=!this._open,this._open)this.setAttribute("open","");else this.removeAttribute("open");this.render(),this._attachListeners()})}render(){let t=this.getAttribute("label")||"Open",n=this._open;this.shadowRoot.innerHTML=g`
|
|
503
503
|
<style>
|
|
504
504
|
:host { position: relative; display: inline-flex; }
|
|
505
505
|
.trigger {
|
|
@@ -531,7 +531,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
531
531
|
</style>
|
|
532
532
|
<button class="trigger" type="button">${t}</button>
|
|
533
533
|
<div class="panel"><slot></slot></div>
|
|
534
|
-
`}};
|
|
534
|
+
`}};f("af-ui-popover",St);Xe=St});var wr={};u(wr,{default:()=>Fe,AfriUITabs:()=>Rt,AfriUITabPanel:()=>ao});var Rt,ao,Fe;var eo=m(()=>{v();Rt=class Rt extends i{static get observedAttributes(){return["active"]}constructor(){super();this._active=this.getAttribute("active")||"0",this.render()}connectedCallback(){this._attachListeners()}attributeChangedCallback(){this._active=this.getAttribute("active")||"0",this.render(),this._attachListeners()}_attachListeners(){this.shadowRoot.querySelectorAll('[role="tab"]').forEach((n)=>{n.addEventListener("click",()=>{let r=n.getAttribute("data-index");this.setAttribute("active",r)})})}render(){let t=this._active,n=Array.from(this.children).filter((r)=>r.tagName.toLowerCase()==="ui-tab-panel");this.shadowRoot.innerHTML=g`
|
|
535
535
|
<style>
|
|
536
536
|
:host { display: block; font-family: 'Inter', system-ui, sans-serif; }
|
|
537
537
|
|
|
@@ -573,7 +573,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
573
573
|
${r.innerHTML}
|
|
574
574
|
</div>
|
|
575
575
|
`).join("")}
|
|
576
|
-
`}};
|
|
576
|
+
`}};ao=class ao extends i{render(){this.shadowRoot.innerHTML=g`<slot></slot>`}};f("af-ui-tabs",Rt);f("ui-tab-panel",ao);Fe=Rt});var xr={};u(xr,{default:()=>Je,AfriUITable:()=>Yt});var Yt,Je;var lo=m(()=>{v();Yt=class Yt extends i{static get observedAttributes(){return["striped","bordered","compact"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.hasAttribute("striped"),n=this.hasAttribute("bordered"),r=this.hasAttribute("compact");this.shadowRoot.innerHTML=g`
|
|
577
577
|
<style>
|
|
578
578
|
:host { display: block; overflow-x: auto; }
|
|
579
579
|
table {
|
|
@@ -608,7 +608,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
608
608
|
<table class="${n?"bordered":""}">
|
|
609
609
|
<slot></slot>
|
|
610
610
|
</table>
|
|
611
|
-
`}};
|
|
611
|
+
`}};f("af-ui-table",Yt);Je=Yt});var Ar={};u(Ar,{default:()=>Qe,AfriUIStat:()=>Xt});var Xt,Qe;var bo=m(()=>{v();Xt=class Xt extends i{static get observedAttributes(){return["label","value","delta","trend"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("label")||"Metric",n=this.getAttribute("value")||"0",r=this.getAttribute("delta")||"",o=this.getAttribute("trend")||"neutral",a=o==="positive"?"#16a34a":o==="negative"?"#dc2626":"#475569";this.shadowRoot.innerHTML=g`
|
|
612
612
|
<style>
|
|
613
613
|
:host { display: block; font-family: 'Inter', sans-serif; }
|
|
614
614
|
.stat {
|
|
@@ -646,7 +646,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
646
646
|
<div class="value">${n}</div>
|
|
647
647
|
${r?g`<div class="delta">${r}</div>`:""}
|
|
648
648
|
</div>
|
|
649
|
-
`}};
|
|
649
|
+
`}};f("af-ui-stat",Xt);Qe=Xt});var _r={};u(_r,{default:()=>Ge,AfriFooter:()=>Ft});var Ft,Ge;var io=m(()=>{v();Ft=class Ft extends i{static get observedAttributes(){return["company","year"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("company")||"AfriCode",n=this.getAttribute("year")||new Date().getFullYear();this.shadowRoot.innerHTML=g`
|
|
650
650
|
<style>
|
|
651
651
|
:host {
|
|
652
652
|
display: block;
|
|
@@ -726,7 +726,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
726
726
|
<slot name="legal"></slot>
|
|
727
727
|
</div>
|
|
728
728
|
</footer>
|
|
729
|
-
`}};
|
|
729
|
+
`}};f("af-footer",Ft);Ge=Ft});var kr={};u(kr,{default:()=>Be,AfriBreadcrumb:()=>Jt});var Jt,Be;var fo=m(()=>{v();Jt=class Jt extends i{static get observedAttributes(){return["separator"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("separator")||"/";this.shadowRoot.innerHTML=g`
|
|
730
730
|
<style>
|
|
731
731
|
:host {
|
|
732
732
|
display: block;
|
|
@@ -752,6 +752,10 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
752
752
|
color: #cbd5e1;
|
|
753
753
|
}
|
|
754
754
|
|
|
755
|
+
nav {
|
|
756
|
+
--af-breadcrumb-separator: '${t}';
|
|
757
|
+
}
|
|
758
|
+
|
|
755
759
|
::slotted(a) {
|
|
756
760
|
color: #0f172a;
|
|
757
761
|
text-decoration: none;
|
|
@@ -766,7 +770,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
766
770
|
<nav aria-label="Breadcrumb">
|
|
767
771
|
<slot></slot>
|
|
768
772
|
</nav>
|
|
769
|
-
`}};
|
|
773
|
+
`}};f("af-breadcrumb",Jt);Be=Jt});var qr={};u(qr,{default:()=>De,AfriFeatureGrid:()=>Qt});var Qt,De;var co=m(()=>{v();Qt=class Qt extends i{static get observedAttributes(){return["columns"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("columns")||"3";this.shadowRoot.innerHTML=g`
|
|
770
774
|
<style>
|
|
771
775
|
:host {
|
|
772
776
|
display: block;
|
|
@@ -819,7 +823,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
819
823
|
<div class="grid">
|
|
820
824
|
<slot></slot>
|
|
821
825
|
</div>
|
|
822
|
-
`}};
|
|
826
|
+
`}};f("af-feature-grid",Qt);De=Qt});var Er={};u(Er,{default:()=>Oe,AfriPricingCard:()=>Gt});var Gt,Oe;var ho=m(()=>{v();Gt=class Gt extends i{static get observedAttributes(){return["title","price","frequency","highlight"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("title")||"Standard",n=this.getAttribute("price")||"$49",r=this.getAttribute("frequency")||"per month",o=this.hasAttribute("highlight");this.shadowRoot.innerHTML=g`
|
|
823
827
|
<style>
|
|
824
828
|
:host {
|
|
825
829
|
display: block;
|
|
@@ -884,7 +888,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
884
888
|
</div>
|
|
885
889
|
<div class="footer"><slot name="action"></slot></div>
|
|
886
890
|
</div>
|
|
887
|
-
`}};
|
|
891
|
+
`}};f("af-pricing-card",Gt);Oe=Gt});var Mr={};u(Mr,{default:()=>We,AfriTestimonial:()=>Bt});var Bt,We;var go=m(()=>{v();Bt=class Bt extends i{static get observedAttributes(){return["author","role","company"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("author")||"Customer",n=this.getAttribute("role")||"Founder",r=this.getAttribute("company")||"";this.shadowRoot.innerHTML=g`
|
|
888
892
|
<style>
|
|
889
893
|
:host {
|
|
890
894
|
display: block;
|
|
@@ -944,7 +948,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
944
948
|
<span class="meta">${n}${r?` · ${r}`:""}</span>
|
|
945
949
|
</div>
|
|
946
950
|
</article>
|
|
947
|
-
`}};
|
|
951
|
+
`}};f("af-testimonial",Bt);We=Bt});var Hr={};u(Hr,{default:()=>Ue,AfriDashboardShell:()=>Dt});var Dt,Ue;var mo=m(()=>{v();Dt=class Dt extends i{static get observedAttributes(){return["sidebar-width","topbar-height"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("sidebar-width")||"280px",n=this.getAttribute("topbar-height")||"72px";this.shadowRoot.innerHTML=g`
|
|
948
952
|
<style>
|
|
949
953
|
:host {
|
|
950
954
|
display: block;
|
|
@@ -995,7 +999,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
995
999
|
<header class="topbar"><slot name="topbar"></slot></header>
|
|
996
1000
|
<main class="content"><slot></slot></main>
|
|
997
1001
|
</div>
|
|
998
|
-
`}};
|
|
1002
|
+
`}};f("af-dashboard-shell",Dt);Ue=Dt});var Lr={};u(Lr,{default:()=>Ne,AfriDashboardTopbar:()=>Ot});var Ot,Ne;var so=m(()=>{v();Ot=class Ot extends i{static get observedAttributes(){return["title","description"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("title")||"Dashboard",n=this.getAttribute("description")||"";this.shadowRoot.innerHTML=g`
|
|
999
1003
|
<style>
|
|
1000
1004
|
:host {
|
|
1001
1005
|
display: block;
|
|
@@ -1046,7 +1050,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1046
1050
|
</div>
|
|
1047
1051
|
<div class="actions"><slot name="actions"></slot></div>
|
|
1048
1052
|
</div>
|
|
1049
|
-
`}};
|
|
1053
|
+
`}};f("af-dashboard-topbar",Ot);Ne=Ot});var Sr={};u(Sr,{default:()=>ye,AfriDashboardCard:()=>Wt});var Wt,ye;var po=m(()=>{v();Wt=class Wt extends i{static get observedAttributes(){return["title","variant"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("title")||"",n=this.getAttribute("variant")||"surface",r={surface:{background:"#ffffff",border:"1px solid rgba(15, 23, 42, 0.08)",shadow:"0 18px 36px rgba(15, 23, 42, 0.04)"},elevated:{background:"linear-gradient(180deg, #ffffff 0%, #f8fafc 100%)",border:"1px solid rgba(15, 23, 42, 0.12)",shadow:"0 24px 48px rgba(15, 23, 42, 0.08)"}},o=r[n]||r.surface;this.shadowRoot.innerHTML=g`
|
|
1050
1054
|
<style>
|
|
1051
1055
|
:host {
|
|
1052
1056
|
display: block;
|
|
@@ -1083,7 +1087,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1083
1087
|
${t?g`<div class="header"><h3 class="title">${t}</h3><slot name="header"></slot></div>`:""}
|
|
1084
1088
|
<div class="body"><slot></slot></div>
|
|
1085
1089
|
</div>
|
|
1086
|
-
`}};
|
|
1090
|
+
`}};f("af-dashboard-card",Wt);ye=Wt});var Rr={};u(Rr,{default:()=>Ve,AfriDashboardMetric:()=>Ut});var Ut,Ve;var vo=m(()=>{v();Ut=class Ut extends i{static get observedAttributes(){return["label","value","delta","trend"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("label")||"Metric",n=this.getAttribute("value")||"0",r=this.getAttribute("delta")||"",o=this.getAttribute("trend")||"neutral",a=o==="positive"?"#16a34a":o==="negative"?"#dc2626":"#475569";this.shadowRoot.innerHTML=g`
|
|
1087
1091
|
<style>
|
|
1088
1092
|
:host {
|
|
1089
1093
|
display: block;
|
|
@@ -1128,7 +1132,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1128
1132
|
<div class="value">${n}</div>
|
|
1129
1133
|
${r?g`<div class="delta">${r}</div>`:""}
|
|
1130
1134
|
</div>
|
|
1131
|
-
`}};
|
|
1135
|
+
`}};f("af-dashboard-metric",Ut);Ve=Ut});var Yr={};u(Yr,{default:()=>Ke,AfriDashboardActivityList:()=>Nt});var Nt,Ke;var uo=m(()=>{v();Nt=class Nt extends i{static get observedAttributes(){return["title","empty-text"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("title")||"Recent Activity",n=this.getAttribute("empty-text")||"No recent activity available.";this.shadowRoot.innerHTML=g`
|
|
1132
1136
|
<style>
|
|
1133
1137
|
:host {
|
|
1134
1138
|
display: block;
|
|
@@ -1198,7 +1202,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1198
1202
|
</slot>
|
|
1199
1203
|
</div>
|
|
1200
1204
|
</div>
|
|
1201
|
-
`}};
|
|
1205
|
+
`}};f("af-dashboard-activity-list",Nt);Ke=Nt});var Xr={};u(Xr,{AfriAuthForm:()=>tn});function Ce(t){return typeof t==="string"&&/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)}var je=`
|
|
1202
1206
|
:host {
|
|
1203
1207
|
display: block;
|
|
1204
1208
|
color: var(--af-smart-text, var(--af-text, #172033));
|
|
@@ -1255,8 +1259,8 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1255
1259
|
.message.success {
|
|
1256
1260
|
color: var(--af-smart-success, var(--af-success, #087443));
|
|
1257
1261
|
}
|
|
1258
|
-
`,
|
|
1259
|
-
<style>${
|
|
1262
|
+
`,tn;var $o=m(()=>{v();tn=class tn extends i{static get observedAttributes(){return["endpoint","button-label"]}connectedCallback(){this.render()}attributeChangedCallback(){if(this.isConnected)this.render()}get endpoint(){return this.getAttribute("endpoint")||"/api/auth"}render(){this.shadowRoot.innerHTML=`
|
|
1263
|
+
<style>${je}</style>
|
|
1260
1264
|
<form novalidate>
|
|
1261
1265
|
<label>
|
|
1262
1266
|
Email
|
|
@@ -1269,7 +1273,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1269
1273
|
<button type="submit">${this.getAttribute("button-label")||"Continue"}</button>
|
|
1270
1274
|
<div class="message" role="status" aria-live="polite"></div>
|
|
1271
1275
|
</form>
|
|
1272
|
-
`,this.shadowRoot.querySelector("form").addEventListener("submit",(t)=>this.handleSubmit(t))}setMessage(t,n=""){let r=this.shadowRoot.querySelector(".message");r.className=n?`message ${n}`:"message",r.textContent=t}async handleSubmit(t){t.preventDefault();let n=t.currentTarget,r=n.querySelector("button"),o={email:n.elements.email.value.trim(),password:n.elements.password.value};if(!
|
|
1276
|
+
`,this.shadowRoot.querySelector("form").addEventListener("submit",(t)=>this.handleSubmit(t))}setMessage(t,n=""){let r=this.shadowRoot.querySelector(".message");r.className=n?`message ${n}`:"message",r.textContent=t}async handleSubmit(t){t.preventDefault();let n=t.currentTarget,r=n.querySelector("button"),o={email:n.elements.email.value.trim(),password:n.elements.password.value};if(!Ce(o.email)||o.password.length<8){this.setMessage("Enter a valid email and password.","error"),this.emit("af-auth-error",{code:"INVALID_INPUT"});return}r.disabled=!0,this.setMessage("Checking credentials...");try{let a=await fetch(this.endpoint,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(o)}),e=await a.json();if(!a.ok||e.ok===!1){this.setMessage(e.error||"Authentication failed.","error"),this.emit("af-auth-error",{response:e,status:a.status});return}this.setMessage("Authenticated.","success"),this.emit("af-auth-success",e)}catch(a){this.setMessage("Authentication service unavailable.","error"),this.emit("af-auth-error",{code:"NETWORK_ERROR",message:a.message})}finally{r.disabled=!1}}};f("af-auth-form",tn)});var Fr={};u(Fr,{AfriKycUpload:()=>nn});var Ie=`
|
|
1273
1277
|
:host {
|
|
1274
1278
|
display: block;
|
|
1275
1279
|
color: var(--af-smart-text, var(--af-text, #172033));
|
|
@@ -1330,8 +1334,8 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1330
1334
|
.message.success {
|
|
1331
1335
|
color: var(--af-smart-success, var(--af-success, #087443));
|
|
1332
1336
|
}
|
|
1333
|
-
`,
|
|
1334
|
-
<style>${
|
|
1337
|
+
`,Pe,nn;var wo=m(()=>{v();Pe=new Set(["application/pdf","image/jpeg","image/png"]);nn=class nn extends i{static get observedAttributes(){return["endpoint","max-size-mb"]}connectedCallback(){this.render()}attributeChangedCallback(){if(this.isConnected)this.render()}get endpoint(){return this.getAttribute("endpoint")||"/api/kyc"}get maxSizeMb(){return Number(this.getAttribute("max-size-mb")||5)}render(){this.shadowRoot.innerHTML=`
|
|
1338
|
+
<style>${Ie}</style>
|
|
1335
1339
|
<form novalidate>
|
|
1336
1340
|
<label>
|
|
1337
1341
|
Identity document
|
|
@@ -1341,7 +1345,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1341
1345
|
<button type="submit">Upload for review</button>
|
|
1342
1346
|
<div class="message" role="status" aria-live="polite"></div>
|
|
1343
1347
|
</form>
|
|
1344
|
-
`,this.shadowRoot.querySelector("form").addEventListener("submit",(t)=>this.handleSubmit(t))}setMessage(t,n=""){let r=this.shadowRoot.querySelector(".message");r.className=n?`message ${n}`:"message",r.textContent=t}validateFile(t){if(!t)return{ok:!1,code:"FILE_REQUIRED",error:"Choose an identity document."};if(!
|
|
1348
|
+
`,this.shadowRoot.querySelector("form").addEventListener("submit",(t)=>this.handleSubmit(t))}setMessage(t,n=""){let r=this.shadowRoot.querySelector(".message");r.className=n?`message ${n}`:"message",r.textContent=t}validateFile(t){if(!t)return{ok:!1,code:"FILE_REQUIRED",error:"Choose an identity document."};if(!Pe.has(t.type))return{ok:!1,code:"UNSUPPORTED_FILE_TYPE",error:"Use a PDF, JPG, or PNG document."};if(t.size>this.maxSizeMb*1024*1024)return{ok:!1,code:"FILE_TOO_LARGE",error:`File must be ${this.maxSizeMb} MB or smaller.`};return{ok:!0}}async handleSubmit(t){t.preventDefault();let n=t.currentTarget,r=n.querySelector("button"),o=n.elements.document.files?.[0],a=this.validateFile(o);if(!a.ok){this.setMessage(a.error,"error"),this.emit("af-kyc-error",a);return}let e=new FormData;e.set("document",o,o.name),r.disabled=!0,this.setMessage("Uploading document...");try{let l=await fetch(this.endpoint,{method:"POST",body:e}),b=await l.json().catch(()=>({}));if(!l.ok||b.ok===!1){this.setMessage(b.error||"Document upload failed.","error"),this.emit("af-kyc-error",{response:b,status:l.status});return}this.setMessage("Document received for review.","success"),this.emit("af-kyc-success",b)}catch(l){this.setMessage("KYC service unavailable.","error"),this.emit("af-kyc-error",{code:"NETWORK_ERROR",message:l.message})}finally{r.disabled=!1}}};f("af-kyc-upload",nn)});var Jr={};u(Jr,{AfriWalletBalance:()=>on});function Ao(t,n){return`${n||"TZS"} ${Number(t||0).toLocaleString("en-US")}`}var xo=`
|
|
1345
1349
|
:host {
|
|
1346
1350
|
display: block;
|
|
1347
1351
|
color: var(--af-smart-text, var(--af-text, #172033));
|
|
@@ -1371,28 +1375,28 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1371
1375
|
.error {
|
|
1372
1376
|
color: var(--af-smart-danger, var(--af-danger, #b42318));
|
|
1373
1377
|
}
|
|
1374
|
-
`,
|
|
1375
|
-
<style>${
|
|
1378
|
+
`,on;var _o=m(()=>{v();on=class on extends i{static get observedAttributes(){return["endpoint"]}connectedCallback(){this.renderLoading(),this.load()}attributeChangedCallback(){if(this.isConnected)this.load()}get endpoint(){return this.getAttribute("endpoint")||"/api/wallet"}renderLoading(){this.shadowRoot.innerHTML=`
|
|
1379
|
+
<style>${xo}</style>
|
|
1376
1380
|
<article class="wallet">
|
|
1377
1381
|
<span class="label">Available balance</span>
|
|
1378
1382
|
<strong class="amount">Loading</strong>
|
|
1379
1383
|
<span class="meta">Fetching wallet</span>
|
|
1380
1384
|
</article>
|
|
1381
1385
|
`}renderWallet(t){this.shadowRoot.innerHTML=`
|
|
1382
|
-
<style>${
|
|
1386
|
+
<style>${xo}</style>
|
|
1383
1387
|
<article class="wallet">
|
|
1384
1388
|
<span class="label">Available balance</span>
|
|
1385
1389
|
<strong class="amount"></strong>
|
|
1386
1390
|
<span class="meta"></span>
|
|
1387
1391
|
</article>
|
|
1388
|
-
`,this.shadowRoot.querySelector(".amount").textContent=
|
|
1389
|
-
<style>${
|
|
1392
|
+
`,this.shadowRoot.querySelector(".amount").textContent=Ao(t.availableBalance,t.currency),this.shadowRoot.querySelector(".meta").textContent=`Ledger ${Ao(t.ledgerBalance,t.currency)} · Daily limit ${Ao(t.dailyLimit,t.currency)}`}renderError(t){this.shadowRoot.innerHTML=`
|
|
1393
|
+
<style>${xo}</style>
|
|
1390
1394
|
<article class="wallet">
|
|
1391
1395
|
<span class="label">Available balance</span>
|
|
1392
1396
|
<strong class="amount error">Unavailable</strong>
|
|
1393
1397
|
<span class="meta error"></span>
|
|
1394
1398
|
</article>
|
|
1395
|
-
`,this.shadowRoot.querySelector(".meta").textContent=t}async load(){try{let t=await fetch(this.endpoint),n=await t.json();if(!t.ok||n.ok===!1||!n.wallet)throw Error(n.error||"Wallet data unavailable.");this.renderWallet(n.wallet),this.emit("af-wallet-load",n)}catch(t){this.renderError("Wallet API is unavailable."),this.emit("af-wallet-error",{message:t.message})}}};
|
|
1399
|
+
`,this.shadowRoot.querySelector(".meta").textContent=t}async load(){try{let t=await fetch(this.endpoint),n=await t.json();if(!t.ok||n.ok===!1||!n.wallet)throw Error(n.error||"Wallet data unavailable.");this.renderWallet(n.wallet),this.emit("af-wallet-load",n)}catch(t){this.renderError("Wallet API is unavailable."),this.emit("af-wallet-error",{message:t.message})}}};f("af-wallet-balance",on)});var Gr={};u(Gr,{AfriTransactionLedger:()=>rn});function Te(t,n){return`${n||"TZS"} ${Number(t||0).toLocaleString("en-US")}`}var Qr=`
|
|
1396
1400
|
:host {
|
|
1397
1401
|
display: block;
|
|
1398
1402
|
color: var(--af-smart-text, var(--af-text, #172033));
|
|
@@ -1427,13 +1431,13 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1427
1431
|
.error {
|
|
1428
1432
|
color: var(--af-smart-danger, var(--af-danger, #b42318));
|
|
1429
1433
|
}
|
|
1430
|
-
`,
|
|
1431
|
-
<style>${
|
|
1434
|
+
`,rn;var ko=m(()=>{v();rn=class rn extends i{static get observedAttributes(){return["endpoint"]}connectedCallback(){this.renderShell("Loading transactions"),this.load()}attributeChangedCallback(){if(this.isConnected)this.load()}get endpoint(){return this.getAttribute("endpoint")||"/api/wallet"}renderShell(t=""){if(this.shadowRoot.innerHTML=`
|
|
1435
|
+
<style>${Qr}</style>
|
|
1432
1436
|
<div class="ledger" role="list"></div>
|
|
1433
|
-
`,t){let n=document.createElement("div");n.className="empty",n.textContent=t,this.shadowRoot.querySelector(".ledger").append(n)}}renderTransactions(t){this.renderShell();let n=this.shadowRoot.querySelector(".ledger");if(!t.length){let r=document.createElement("div");r.className="empty",r.textContent="No transactions yet.",n.append(r);return}n.replaceChildren(...t.map((r)=>{let o=document.createElement("article"),a=document.createElement("div"),e=document.createElement("strong"),l=document.createElement("div"),
|
|
1434
|
-
<style>${
|
|
1437
|
+
`,t){let n=document.createElement("div");n.className="empty",n.textContent=t,this.shadowRoot.querySelector(".ledger").append(n)}}renderTransactions(t){this.renderShell();let n=this.shadowRoot.querySelector(".ledger");if(!t.length){let r=document.createElement("div");r.className="empty",r.textContent="No transactions yet.",n.append(r);return}n.replaceChildren(...t.map((r)=>{let o=document.createElement("article"),a=document.createElement("div"),e=document.createElement("strong"),l=document.createElement("div"),b=document.createElement("span");return o.className="row",o.setAttribute("role","listitem"),l.className="status",b.className="amount",e.textContent=r.counterparty||r.id||"Transaction",l.textContent=r.status||r.type||"pending",b.textContent=Te(r.amount,r.currency),a.append(e,l),o.append(a,b),o}))}renderError(t){this.shadowRoot.innerHTML=`
|
|
1438
|
+
<style>${Qr}</style>
|
|
1435
1439
|
<div class="empty error"></div>
|
|
1436
|
-
`,this.shadowRoot.querySelector(".empty").textContent=t}async load(){try{let t=await fetch(this.endpoint),n=await t.json(),r=Array.isArray(n.transactions)?n.transactions:[];if(!t.ok||n.ok===!1)throw Error(n.error||"Ledger data unavailable.");this.renderTransactions(r),this.emit("af-ledger-load",{transactions:r})}catch(t){this.renderError("Transaction ledger unavailable."),this.emit("af-ledger-error",{message:t.message})}}};
|
|
1440
|
+
`,this.shadowRoot.querySelector(".empty").textContent=t}async load(){try{let t=await fetch(this.endpoint),n=await t.json(),r=Array.isArray(n.transactions)?n.transactions:[];if(!t.ok||n.ok===!1)throw Error(n.error||"Ledger data unavailable.");this.renderTransactions(r),this.emit("af-ledger-load",{transactions:r})}catch(t){this.renderError("Transaction ledger unavailable."),this.emit("af-ledger-error",{message:t.message})}}};f("af-transaction-ledger",rn)});var Br={};u(Br,{default:()=>Ze,AfriNavDrawer:()=>yt});var yt,Ze;var qo=m(()=>{v();v();yt=class yt extends i{constructor(){super();this.isOpen=!1,this.position=this.getAttribute("position")||"left",this.width=this.getAttribute("width")||"280px",this.overlay=this.hasAttribute("overlay")}static get observedAttributes(){return["open","position","width","overlay"]}attributeChangedCallback(t,n,r){switch(t){case"open":this.isOpen=r!==null,this.render();break;case"position":this.position=r;break;case"width":this.width=r;break;case"overlay":this.overlay=r!==null;break}}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this.handleKeyDown),this.loadStyles()}disconnectedCallback(){this.removeEventListener("keydown",this.handleKeyDown)}handleKeyDown=(t)=>{if(t.key==="Escape"&&this.isOpen)this.close()};toggle(){this.isOpen?this.close():this.open()}open(){this.isOpen=!0,this.setAttribute("open",""),this.render(),this.emit("af-navdrawer-open",{drawer:this})}close(){this.isOpen=!1,this.removeAttribute("open"),this.render(),this.emit("af-navdrawer-close",{drawer:this})}render(){if(!this.shadowRoot)return;if(this.shadowRoot.innerHTML=`
|
|
1437
1441
|
<style>
|
|
1438
1442
|
:host {
|
|
1439
1443
|
display: block;
|
|
@@ -1539,7 +1543,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1539
1543
|
<slot name="content"></slot>
|
|
1540
1544
|
</div>
|
|
1541
1545
|
</aside>
|
|
1542
|
-
`,this.overlay){let t=this.shadowRoot.querySelector(".nav-drawer-overlay");if(t)t.addEventListener("click",()=>this.close())}}getItems(){return this.querySelectorAll('[slot="content"] .nav-item')}setActiveItem(t){this.getItems().forEach((o)=>o.classList.remove("active"));let r=this.querySelector(t);if(r)r.classList.add("active")}};
|
|
1546
|
+
`,this.overlay){let t=this.shadowRoot.querySelector(".nav-drawer-overlay");if(t)t.addEventListener("click",()=>this.close())}}getItems(){return this.querySelectorAll('[slot="content"] .nav-item')}setActiveItem(t){this.getItems().forEach((o)=>o.classList.remove("active"));let r=this.querySelector(t);if(r)r.classList.add("active")}};f("af-nav-drawer",yt);Ze=yt});var Dr={};u(Dr,{default:()=>ze,AfriButton:()=>an});var an,ze;var Or=m(()=>{v();an=class an extends i{static get observedAttributes(){return["variant","size","theme","disabled","loading","icon","aria-label"]}constructor(){super();this.render()}connectedCallback(){this.shadowRoot.querySelector("button")?.addEventListener("click",(n)=>{if(this.hasAttribute("disabled")||this.hasAttribute("loading")){n.preventDefault();return}this.emit("af-click",{originalEvent:n})})}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("variant")||"primary",n=this.getAttribute("size")||"md",r=this.getAttribute("theme")||"tanzania",o=this.hasAttribute("disabled"),a=this.hasAttribute("loading"),e=this.getAttribute("icon"),l=this.getAttribute("aria-label"),b={tanzania:{primary:"#1EB53A",accent:"#FCD116",text:"#FFFFFF"},maasai:{primary:"#FF0000",accent:"#8B0000",text:"#FFFFFF"},ndebele:{primary:"#4169E1",accent:"#FFD700",text:"#FFFFFF"},ocean:{primary:"#00A3DD",accent:"#0077BE",text:"#FFFFFF"}},d=b[r]||b.tanzania;this.shadowRoot.innerHTML=`
|
|
1543
1547
|
<style>
|
|
1544
1548
|
:host {
|
|
1545
1549
|
display: inline-block;
|
|
@@ -1567,8 +1571,8 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1567
1571
|
|
|
1568
1572
|
/* Variants */
|
|
1569
1573
|
.variant-primary {
|
|
1570
|
-
background: ${
|
|
1571
|
-
color: ${
|
|
1574
|
+
background: ${d.primary};
|
|
1575
|
+
color: ${d.text};
|
|
1572
1576
|
}
|
|
1573
1577
|
.variant-primary:hover:not(:disabled) {
|
|
1574
1578
|
filter: brightness(1.1);
|
|
@@ -1578,25 +1582,25 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1578
1582
|
|
|
1579
1583
|
.variant-secondary {
|
|
1580
1584
|
background: transparent;
|
|
1581
|
-
color: ${
|
|
1582
|
-
border: 2px solid ${
|
|
1585
|
+
color: ${d.primary};
|
|
1586
|
+
border: 2px solid ${d.primary};
|
|
1583
1587
|
}
|
|
1584
1588
|
.variant-secondary:hover:not(:disabled) {
|
|
1585
|
-
background: ${
|
|
1586
|
-
color: ${
|
|
1589
|
+
background: ${d.primary};
|
|
1590
|
+
color: ${d.text};
|
|
1587
1591
|
}
|
|
1588
1592
|
|
|
1589
1593
|
.variant-ghost {
|
|
1590
1594
|
background: transparent;
|
|
1591
|
-
color: ${
|
|
1595
|
+
color: ${d.primary};
|
|
1592
1596
|
}
|
|
1593
1597
|
.variant-ghost:hover:not(:disabled) {
|
|
1594
1598
|
background: rgba(0,0,0,0.05);
|
|
1595
1599
|
}
|
|
1596
1600
|
|
|
1597
1601
|
.variant-gradient {
|
|
1598
|
-
background: linear-gradient(135deg, ${
|
|
1599
|
-
color: ${
|
|
1602
|
+
background: linear-gradient(135deg, ${d.primary} 0%, ${d.accent} 100%);
|
|
1603
|
+
color: ${d.text};
|
|
1600
1604
|
}
|
|
1601
1605
|
.variant-gradient:hover:not(:disabled) {
|
|
1602
1606
|
transform: translateY(-2px);
|
|
@@ -1643,7 +1647,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1643
1647
|
${e&&!a?`<span class="icon">${e}</span>`:""}
|
|
1644
1648
|
<slot></slot>
|
|
1645
1649
|
</button>
|
|
1646
|
-
`}};
|
|
1650
|
+
`}};f("af-button",an);ze=an});var Wr={};u(Wr,{default:()=>tl,AfriCard:()=>en});var en,tl;var Ur=m(()=>{v();en=class en extends i{static get observedAttributes(){return["theme","variant","clickable","image"]}constructor(){super()}connectedCallback(){if(this.render(),this.hasAttribute("clickable"))this.shadowRoot.querySelector(".card").addEventListener("click",()=>{this.emit("af-click")})}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("theme")||"default",n=this.getAttribute("variant")||"elevated",r=this.hasAttribute("clickable"),o=this.getAttribute("image"),a={default:{accent:"#333",border:"#eee"},tanzania:{accent:"#1EB53A",border:"#1EB53A"},maasai:{accent:"#FF0000",border:"#8B0000"},ndebele:{accent:"#4169E1",border:"#4169E1"}},l={elevated:"box-shadow: 0 2px 12px rgba(0,0,0,0.1);",outlined:`border: 2px solid ${(a[t]||a.default).border};`,flat:"background: #f8f9fa;"},b=l[n]||l.elevated;this.shadowRoot.innerHTML=g`
|
|
1647
1651
|
<style>
|
|
1648
1652
|
:host {
|
|
1649
1653
|
display: block;
|
|
@@ -1651,6 +1655,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1651
1655
|
}
|
|
1652
1656
|
|
|
1653
1657
|
.card {
|
|
1658
|
+
${b}
|
|
1654
1659
|
background: var(--glass-bg, rgba(15, 23, 42, 0.7));
|
|
1655
1660
|
backdrop-filter: blur(var(--glass-blur, 12px));
|
|
1656
1661
|
border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.1));
|
|
@@ -1711,17 +1716,17 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1711
1716
|
</style>
|
|
1712
1717
|
|
|
1713
1718
|
<article class="card">
|
|
1714
|
-
${o
|
|
1719
|
+
${o?g`<img class="card-image" src="${o}" alt="" />`:""}
|
|
1715
1720
|
<div class="card-body">
|
|
1716
1721
|
<slot></slot>
|
|
1717
1722
|
</div>
|
|
1718
|
-
${this.querySelector('[slot="footer"]')
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
+
${this.querySelector('[slot="footer"]')?g`
|
|
1724
|
+
<div class="card-footer">
|
|
1725
|
+
<slot name="footer"></slot>
|
|
1726
|
+
</div>
|
|
1727
|
+
`:""}
|
|
1723
1728
|
</article>
|
|
1724
|
-
`}};
|
|
1729
|
+
`}};f("af-card",en);tl=en});var Nr={};u(Nr,{default:()=>nl,AfriNavbar:()=>ln});var ln,nl;var yr=m(()=>{v();ln=class ln extends i{static get observedAttributes(){return["theme","logo","sticky"]}constructor(){super();this._isOpen=!1,this._unsubscribe=null,this.render()}connectedCallback(){super.connectedCallback(),this.shadowRoot.querySelector(".menu-toggle")?.addEventListener("click",()=>{this._isOpen=!this._isOpen;let t=this.shadowRoot.querySelector(".nav-links"),n=this.shadowRoot.querySelector(".menu-toggle");if(t)t.classList.toggle("open",this._isOpen);if(n)n.classList.toggle("open",this._isOpen),n.setAttribute("aria-expanded",String(this._isOpen))})}disconnectedCallback(){if(this._unsubscribe)this._unsubscribe()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("theme")||"dark",n=this.getAttribute("logo")||"AfriCode",r=this.getAttribute("sticky")!=="false",o={dark:{start:"var(--afri-green, #1eb53a)",end:"var(--afri-gold, #fcd116)",accent:"var(--afri-gold, #fcd116)"},tanzania:{start:"#1EB53A",end:"#FCD116",accent:"#FCD116"},maasai:{start:"#FF0000",end:"#8B0000",accent:"#FF0000"},ndebele:{start:"#4169E1",end:"#FFFFFF",accent:"#4169E1"}},a=o[t]||o.dark;this.shadowRoot.innerHTML=`
|
|
1725
1730
|
<style>
|
|
1726
1731
|
:host {
|
|
1727
1732
|
display: block;
|
|
@@ -1738,7 +1743,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1738
1743
|
backdrop-filter: blur(12px);
|
|
1739
1744
|
-webkit-backdrop-filter: blur(12px);
|
|
1740
1745
|
border-bottom: 1px solid var(--glass-border);
|
|
1741
|
-
position: fixed;
|
|
1746
|
+
position: ${r?"fixed":"static"};
|
|
1742
1747
|
top: 0;
|
|
1743
1748
|
inset-inline: 0;
|
|
1744
1749
|
z-index: 1000;
|
|
@@ -1756,7 +1761,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1756
1761
|
.logo-mark {
|
|
1757
1762
|
width: 32px;
|
|
1758
1763
|
height: 32px;
|
|
1759
|
-
background: linear-gradient(135deg,
|
|
1764
|
+
background: linear-gradient(135deg, ${a.start}, ${a.end});
|
|
1760
1765
|
border-radius: 8px;
|
|
1761
1766
|
display: flex;
|
|
1762
1767
|
align-items: center;
|
|
@@ -1805,7 +1810,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1805
1810
|
left: 50%;
|
|
1806
1811
|
width: 0;
|
|
1807
1812
|
height: 2px;
|
|
1808
|
-
background:
|
|
1813
|
+
background: ${a.accent};
|
|
1809
1814
|
transition: all 0.3s ease;
|
|
1810
1815
|
transform: translateX(-50%);
|
|
1811
1816
|
}
|
|
@@ -1897,7 +1902,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1897
1902
|
<slot></slot>
|
|
1898
1903
|
</div>
|
|
1899
1904
|
</nav>
|
|
1900
|
-
`}};d("af-navbar",hn);nl=hn});var q,Ho,h,D=(t)=>{switch(typeof t){case"undefined":return h.undefined;case"string":return h.string;case"number":return Number.isNaN(t)?h.nan:h.number;case"boolean":return h.boolean;case"function":return h.function;case"bigint":return h.bigint;case"symbol":return h.symbol;case"object":if(Array.isArray(t))return h.array;if(t===null)return h.null;if(t.then&&typeof t.then==="function"&&t.catch&&typeof t.catch==="function")return h.promise;if(typeof Map<"u"&&t instanceof Map)return h.map;if(typeof Set<"u"&&t instanceof Set)return h.set;if(typeof Date<"u"&&t instanceof Date)return h.date;return h.object;default:return h.unknown}};var Kt=s(()=>{(function(t){t.assertEqual=(a)=>{};function n(a){}t.assertIs=n;function r(a){throw Error()}t.assertNever=r,t.arrayToEnum=(a)=>{let e={};for(let l of a)e[l]=l;return e},t.getValidEnumValues=(a)=>{let e=t.objectKeys(a).filter((i)=>typeof a[a[i]]!=="number"),l={};for(let i of e)l[i]=a[i];return t.objectValues(l)},t.objectValues=(a)=>{return t.objectKeys(a).map(function(e){return a[e]})},t.objectKeys=typeof Object.keys==="function"?(a)=>Object.keys(a):(a)=>{let e=[];for(let l in a)if(Object.prototype.hasOwnProperty.call(a,l))e.push(l);return e},t.find=(a,e)=>{for(let l of a)if(e(l))return l;return},t.isInteger=typeof Number.isInteger==="function"?(a)=>Number.isInteger(a):(a)=>typeof a==="number"&&Number.isFinite(a)&&Math.floor(a)===a;function o(a,e=" | "){return a.map((l)=>typeof l==="string"?`'${l}'`:l).join(e)}t.joinValues=o,t.jsonStringifyReplacer=(a,e)=>{if(typeof e==="bigint")return e.toString();return e}})(q||(q={}));(function(t){t.mergeShapes=(n,r)=>{return{...n,...r}}})(Ho||(Ho={}));h=q.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"])});var f,ol=(t)=>{return JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:")},Y;var gn=s(()=>{Kt();f=q.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);Y=class Y extends Error{get errors(){return this.issues}constructor(t){super();this.issues=[],this.addIssue=(r)=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};let n=new.target.prototype;if(Object.setPrototypeOf)Object.setPrototypeOf(this,n);else this.__proto__=n;this.name="ZodError",this.issues=t}format(t){let n=t||function(a){return a.message},r={_errors:[]},o=(a)=>{for(let e of a.issues)if(e.code==="invalid_union")e.unionErrors.map(o);else if(e.code==="invalid_return_type")o(e.returnTypeError);else if(e.code==="invalid_arguments")o(e.argumentsError);else if(e.path.length===0)r._errors.push(n(e));else{let l=r,i=0;while(i<e.path.length){let c=e.path[i];if(i!==e.path.length-1)l[c]=l[c]||{_errors:[]};else l[c]=l[c]||{_errors:[]},l[c]._errors.push(n(e));l=l[c],i++}}};return o(this),r}static assert(t){if(!(t instanceof Y))throw Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,q.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=(n)=>n.message){let n={},r=[];for(let o of this.issues)if(o.path.length>0){let a=o.path[0];n[a]=n[a]||[],n[a].push(t(o))}else r.push(t(o));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}};Y.create=(t)=>{return new Y(t)}});var rl=(t,n)=>{let r;switch(t.code){case f.invalid_type:if(t.received===h.undefined)r="Required";else r=`Expected ${t.expected}, received ${t.received}`;break;case f.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,q.jsonStringifyReplacer)}`;break;case f.unrecognized_keys:r=`Unrecognized key(s) in object: ${q.joinValues(t.keys,", ")}`;break;case f.invalid_union:r="Invalid input";break;case f.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${q.joinValues(t.options)}`;break;case f.invalid_enum_value:r=`Invalid enum value. Expected ${q.joinValues(t.options)}, received '${t.received}'`;break;case f.invalid_arguments:r="Invalid function arguments";break;case f.invalid_return_type:r="Invalid function return type";break;case f.invalid_date:r="Invalid date";break;case f.invalid_string:if(typeof t.validation==="object")if("includes"in t.validation){if(r=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position==="number")r=`${r} at one or more positions greater than or equal to ${t.validation.position}`}else if("startsWith"in t.validation)r=`Invalid input: must start with "${t.validation.startsWith}"`;else if("endsWith"in t.validation)r=`Invalid input: must end with "${t.validation.endsWith}"`;else q.assertNever(t.validation);else if(t.validation!=="regex")r=`Invalid ${t.validation}`;else r="Invalid";break;case f.too_small:if(t.type==="array")r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`;else if(t.type==="string")r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`;else if(t.type==="number")r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`;else if(t.type==="bigint")r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`;else if(t.type==="date")r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`;else r="Invalid input";break;case f.too_big:if(t.type==="array")r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`;else if(t.type==="string")r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`;else if(t.type==="number")r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`;else if(t.type==="bigint")r=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`;else if(t.type==="date")r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`;else r="Invalid input";break;case f.custom:r="Invalid input";break;case f.invalid_intersection_types:r="Intersection results could not be merged";break;case f.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case f.not_finite:r="Number must be finite";break;default:r=n.defaultError,q.assertNever(t)}return{message:r}},y;var So=s(()=>{gn();Kt();y=rl});function al(t){Ir=t}function ot(){return Ir}var Ir;var sn=s(()=>{So();Ir=y});function m(t,n){let r=ot(),o=jt({issueData:n,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,r,r===y?void 0:y].filter((a)=>!!a)});t.common.issues.push(o)}class S{constructor(){this.value="valid"}dirty(){if(this.value==="valid")this.value="dirty"}abort(){if(this.value!=="aborted")this.value="aborted"}static mergeArray(t,n){let r=[];for(let o of n){if(o.status==="aborted")return x;if(o.status==="dirty")t.dirty();r.push(o.value)}return{status:t.value,value:r}}static async mergeObjectAsync(t,n){let r=[];for(let o of n){let a=await o.key,e=await o.value;r.push({key:a,value:e})}return S.mergeObjectSync(t,r)}static mergeObjectSync(t,n){let r={};for(let o of n){let{key:a,value:e}=o;if(a.status==="aborted")return x;if(e.status==="aborted")return x;if(a.status==="dirty")t.dirty();if(e.status==="dirty")t.dirty();if(a.value!=="__proto__"&&(typeof e.value<"u"||o.alwaysSet))r[a.value]=e.value}return{status:t.value,value:r}}}var jt=(t)=>{let{data:n,path:r,errorMaps:o,issueData:a}=t,e=[...r,...a.path||[]],l={...a,path:e};if(a.message!==void 0)return{...a,path:e,message:a.message};let i="",c=o.filter(($)=>!!$).slice().reverse();for(let $ of c)i=$(l,{data:n,defaultError:i}).message;return{...a,path:e,message:i}},el,x,T=(t)=>({status:"dirty",value:t}),R=(t)=>({status:"valid",value:t}),mn=(t)=>t.status==="aborted",pn=(t)=>t.status==="dirty",K=(t)=>t.status==="valid",rt=(t)=>typeof Promise<"u"&&t instanceof Promise;var Ro=s(()=>{sn();So();el=[];x=Object.freeze({status:"aborted"})});var Pr=()=>{};var w;var Tr=s(()=>{(function(t){t.errToObj=(n)=>typeof n==="string"?{message:n}:n||{},t.toString=(n)=>typeof n==="string"?n:n?.message})(w||(w={}))});class Q{constructor(t,n,r,o){this._cachedPath=[],this.parent=t,this.data=n,this._path=r,this._key=o}get path(){if(!this._cachedPath.length)if(Array.isArray(this._key))this._cachedPath.push(...this._path,...this._key);else this._cachedPath.push(...this._path,this._key);return this._cachedPath}}function _(t){if(!t)return{};let{errorMap:n,invalid_type_error:r,required_error:o,description:a}=t;if(n&&(r||o))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);if(n)return{errorMap:n,description:a};return{errorMap:(l,i)=>{let{message:c}=t;if(l.code==="invalid_enum_value")return{message:c??i.defaultError};if(typeof i.data>"u")return{message:c??o??i.defaultError};if(l.code!=="invalid_type")return{message:i.defaultError};return{message:c??r??i.defaultError}},description:a}}class k{get description(){return this._def.description}_getType(t){return D(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:D(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new S,ctx:{common:t.parent.common,data:t.data,parsedType:D(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){let n=this._parse(t);if(rt(n))throw Error("Synchronous parse encountered promise.");return n}_parseAsync(t){let n=this._parse(t);return Promise.resolve(n)}parse(t,n){let r=this.safeParse(t,n);if(r.success)return r.data;throw r.error}safeParse(t,n){let r={common:{issues:[],async:n?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:D(t)},o=this._parseSync({data:t,path:r.path,parent:r});return Zr(r,o)}"~validate"(t){let n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:D(t)};if(!this["~standard"].async)try{let r=this._parseSync({data:t,path:[],parent:n});return K(r)?{value:r.value}:{issues:n.common.issues}}catch(r){if(r?.message?.toLowerCase()?.includes("encountered"))this["~standard"].async=!0;n.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:n}).then((r)=>K(r)?{value:r.value}:{issues:n.common.issues})}async parseAsync(t,n){let r=await this.safeParseAsync(t,n);if(r.success)return r.data;throw r.error}async safeParseAsync(t,n){let r={common:{issues:[],contextualErrorMap:n?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:D(t)},o=this._parse({data:t,path:r.path,parent:r}),a=await(rt(o)?o:Promise.resolve(o));return Zr(r,a)}refine(t,n){let r=(o)=>{if(typeof n==="string"||typeof n>"u")return{message:n};else if(typeof n==="function")return n(o);else return n};return this._refinement((o,a)=>{let e=t(o),l=()=>a.addIssue({code:f.custom,...r(o)});if(typeof Promise<"u"&&e instanceof Promise)return e.then((i)=>{if(!i)return l(),!1;else return!0});if(!e)return l(),!1;else return!0})}refinement(t,n){return this._refinement((r,o)=>{if(!t(r))return o.addIssue(typeof n==="function"?n(r,o):n),!1;else return!0})}_refinement(t){return new B({schema:this,typeName:A.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:(n)=>this["~validate"](n)}}optional(){return G.create(this,this._def)}nullable(){return N.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return J.create(this)}promise(){return nt.create(this,this._def)}or(t){return dt.create([this,t],this._def)}and(t){return ct.create(this,t,this._def)}transform(t){return new B({..._(this._def),schema:this,typeName:A.ZodEffects,effect:{type:"transform",transform:t}})}default(t){let n=typeof t==="function"?t:()=>t;return new st({..._(this._def),innerType:this,defaultValue:n,typeName:A.ZodDefault})}brand(){return new un({typeName:A.ZodBranded,type:this,..._(this._def)})}catch(t){let n=typeof t==="function"?t:()=>t;return new mt({..._(this._def),innerType:this,catchValue:n,typeName:A.ZodCatch})}describe(t){return new this.constructor({...this._def,description:t})}pipe(t){return zt.create(this,t)}readonly(){return pt.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}function na(t){let n="[0-5]\\d";if(t.precision)n=`${n}\\.\\d{${t.precision}}`;else if(t.precision==null)n=`${n}(\\.\\d+)?`;let r=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${n})${r}`}function Al(t){return new RegExp(`^${na(t)}$`)}function oa(t){let n=`${ta}T${na(t)}`,r=[];if(r.push(t.local?"Z?":"Z"),t.offset)r.push("([+-]\\d{2}:?\\d{2})");return n=`${n}(${r.join("|")})`,new RegExp(`^${n}$`)}function _l(t,n){if((n==="v4"||!n)&&ml.test(t))return!0;if((n==="v6"||!n)&&vl.test(t))return!0;return!1}function kl(t,n){if(!fl.test(t))return!1;try{let[r]=t.split(".");if(!r)return!1;let o=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),a=JSON.parse(atob(o));if(typeof a!=="object"||a===null)return!1;if("typ"in a&&a?.typ!=="JWT")return!1;if(!a.alg)return!1;if(n&&a.alg!==n)return!1;return!0}catch{return!1}}function ql(t,n){if((n==="v4"||!n)&&pl.test(t))return!0;if((n==="v6"||!n)&&ul.test(t))return!0;return!1}function Ll(t,n){let r=(t.toString().split(".")[1]||"").length,o=(n.toString().split(".")[1]||"").length,a=r>o?r:o,e=Number.parseInt(t.toFixed(a).replace(".","")),l=Number.parseInt(n.toFixed(a).replace(".",""));return e%l/10**a}function at(t){if(t instanceof E){let n={};for(let r in t.shape){let o=t.shape[r];n[r]=G.create(at(o))}return new E({...t._def,shape:()=>n})}else if(t instanceof J)return new J({...t._def,type:at(t.element)});else if(t instanceof G)return G.create(at(t.unwrap()));else if(t instanceof N)return N.create(at(t.unwrap()));else if(t instanceof W)return W.create(t.items.map((n)=>at(n)));else return t}function Xo(t,n){let r=D(t),o=D(n);if(t===n)return{valid:!0,data:t};else if(r===h.object&&o===h.object){let a=q.objectKeys(n),e=q.objectKeys(t).filter((i)=>a.indexOf(i)!==-1),l={...t,...n};for(let i of e){let c=Xo(t[i],n[i]);if(!c.valid)return{valid:!1};l[i]=c.data}return{valid:!0,data:l}}else if(r===h.array&&o===h.array){if(t.length!==n.length)return{valid:!1};let a=[];for(let e=0;e<t.length;e++){let l=t[e],i=n[e],c=Xo(l,i);if(!c.valid)return{valid:!1};a.push(c.data)}return{valid:!0,data:a}}else if(r===h.date&&o===h.date&&+t===+n)return{valid:!0,data:t};else return{valid:!1}}function ra(t,n){return new P({values:t,typeName:A.ZodEnum,..._(n)})}function zr(t,n){let r=typeof t==="function"?t(n):typeof t==="string"?{message:t}:t;return typeof r==="string"?{message:r}:r}function aa(t,n={},r){if(t)return z.create().superRefine((o,a)=>{let e=t(o);if(e instanceof Promise)return e.then((l)=>{if(!l){let i=zr(n,o),c=i.fatal??r??!0;a.addIssue({code:"custom",...i,fatal:c})}});if(!e){let l=zr(n,o),i=l.fatal??r??!0;a.addIssue({code:"custom",...l,fatal:i})}return});return z.create()}var Zr=(t,n)=>{if(K(n))return{success:!0,data:n.value};else{if(!t.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let r=new Y(t.common.issues);return this._error=r,this._error}}}},ll,il,bl,dl,cl,fl,hl,gl,sl="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",Yo,ml,pl,vl,ul,$l,wl,ta="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",xl,F,C,I,lt,Z,Ct,it,bt,z,j,O,It,J,E,dt,U=(t)=>{if(t instanceof ft)return U(t.schema);else if(t instanceof B)return U(t.innerType());else if(t instanceof ht)return[t.value];else if(t instanceof P)return t.options;else if(t instanceof gt)return q.objectValues(t.enum);else if(t instanceof st)return U(t._def.innerType);else if(t instanceof it)return[void 0];else if(t instanceof bt)return[null];else if(t instanceof G)return[void 0,...U(t.unwrap())];else if(t instanceof N)return[null,...U(t.unwrap())];else if(t instanceof un)return U(t.unwrap());else if(t instanceof pt)return U(t.unwrap());else if(t instanceof mt)return U(t._def.innerType);else return[]},vn,ct,W,Pt,Tt,tt,et,ft,ht,P,gt,nt,B,G,N,st,mt,Zt,El,un,zt,pt,Ml,A,Hl=(t,n={message:`Input not instance of ${t.name}`})=>aa((r)=>r instanceof t,n),ea,la,Sl,Rl,ia,Yl,Xl,Fl,Jl,Gl,Ql,Bl,Dl,Ol,Wl,yl,Ul,Nl,Vl,Kl,jl,Cl,Il,Pl,Tl,Zl,zl,ti,ni,oi,ri,ai,ei,li,ii=()=>ea().optional(),bi=()=>la().optional(),di=()=>ia().optional(),ci,fi;var ba=s(()=>{gn();sn();Tr();Ro();Kt();ll=/^c[^\s-]{8,}$/i,il=/^[0-9a-z]+$/,bl=/^[0-9A-HJKMNP-TV-Z]{26}$/i,dl=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,cl=/^[a-z0-9_-]{21}$/i,fl=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,hl=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,gl=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,ml=/^(?:(?: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])$/,pl=/^(?:(?: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])\/(3[0-2]|[12]?[0-9])$/,vl=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,ul=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,$l=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,wl=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,xl=new RegExp(`^${ta}$`);F=class F extends k{_parse(t){if(this._def.coerce)t.data=String(t.data);if(this._getType(t)!==h.string){let a=this._getOrReturnCtx(t);return m(a,{code:f.invalid_type,expected:h.string,received:a.parsedType}),x}let r=new S,o=void 0;for(let a of this._def.checks)if(a.kind==="min"){if(t.data.length<a.value)o=this._getOrReturnCtx(t,o),m(o,{code:f.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty()}else if(a.kind==="max"){if(t.data.length>a.value)o=this._getOrReturnCtx(t,o),m(o,{code:f.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty()}else if(a.kind==="length"){let e=t.data.length>a.value,l=t.data.length<a.value;if(e||l){if(o=this._getOrReturnCtx(t,o),e)m(o,{code:f.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message});else if(l)m(o,{code:f.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message});r.dirty()}}else if(a.kind==="email"){if(!gl.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"email",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="emoji"){if(!Yo)Yo=new RegExp(sl,"u");if(!Yo.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"emoji",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="uuid"){if(!dl.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"uuid",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="nanoid"){if(!cl.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"nanoid",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="cuid"){if(!ll.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"cuid",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="cuid2"){if(!il.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"cuid2",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="ulid"){if(!bl.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"ulid",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="url")try{new URL(t.data)}catch{o=this._getOrReturnCtx(t,o),m(o,{validation:"url",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="regex"){if(a.regex.lastIndex=0,!a.regex.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"regex",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="trim")t.data=t.data.trim();else if(a.kind==="includes"){if(!t.data.includes(a.value,a.position))o=this._getOrReturnCtx(t,o),m(o,{code:f.invalid_string,validation:{includes:a.value,position:a.position},message:a.message}),r.dirty()}else if(a.kind==="toLowerCase")t.data=t.data.toLowerCase();else if(a.kind==="toUpperCase")t.data=t.data.toUpperCase();else if(a.kind==="startsWith"){if(!t.data.startsWith(a.value))o=this._getOrReturnCtx(t,o),m(o,{code:f.invalid_string,validation:{startsWith:a.value},message:a.message}),r.dirty()}else if(a.kind==="endsWith"){if(!t.data.endsWith(a.value))o=this._getOrReturnCtx(t,o),m(o,{code:f.invalid_string,validation:{endsWith:a.value},message:a.message}),r.dirty()}else if(a.kind==="datetime"){if(!oa(a).test(t.data))o=this._getOrReturnCtx(t,o),m(o,{code:f.invalid_string,validation:"datetime",message:a.message}),r.dirty()}else if(a.kind==="date"){if(!xl.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{code:f.invalid_string,validation:"date",message:a.message}),r.dirty()}else if(a.kind==="time"){if(!Al(a).test(t.data))o=this._getOrReturnCtx(t,o),m(o,{code:f.invalid_string,validation:"time",message:a.message}),r.dirty()}else if(a.kind==="duration"){if(!hl.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"duration",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="ip"){if(!_l(t.data,a.version))o=this._getOrReturnCtx(t,o),m(o,{validation:"ip",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="jwt"){if(!kl(t.data,a.alg))o=this._getOrReturnCtx(t,o),m(o,{validation:"jwt",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="cidr"){if(!ql(t.data,a.version))o=this._getOrReturnCtx(t,o),m(o,{validation:"cidr",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="base64"){if(!$l.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"base64",code:f.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="base64url"){if(!wl.test(t.data))o=this._getOrReturnCtx(t,o),m(o,{validation:"base64url",code:f.invalid_string,message:a.message}),r.dirty()}else q.assertNever(a);return{status:r.value,value:t.data}}_regex(t,n,r){return this.refinement((o)=>t.test(o),{validation:n,code:f.invalid_string,...w.errToObj(r)})}_addCheck(t){return new F({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...w.errToObj(t)})}url(t){return this._addCheck({kind:"url",...w.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...w.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...w.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...w.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...w.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...w.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...w.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...w.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...w.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...w.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...w.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...w.errToObj(t)})}datetime(t){if(typeof t==="string")return this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t});return this._addCheck({kind:"datetime",precision:typeof t?.precision>"u"?null:t?.precision,offset:t?.offset??!1,local:t?.local??!1,...w.errToObj(t?.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){if(typeof t==="string")return this._addCheck({kind:"time",precision:null,message:t});return this._addCheck({kind:"time",precision:typeof t?.precision>"u"?null:t?.precision,...w.errToObj(t?.message)})}duration(t){return this._addCheck({kind:"duration",...w.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...w.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n?.position,...w.errToObj(n?.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...w.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...w.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...w.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...w.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...w.errToObj(n)})}nonempty(t){return this.min(1,w.errToObj(t))}trim(){return new F({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new F({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new F({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((t)=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find((t)=>t.kind==="date")}get isTime(){return!!this._def.checks.find((t)=>t.kind==="time")}get isDuration(){return!!this._def.checks.find((t)=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find((t)=>t.kind==="email")}get isURL(){return!!this._def.checks.find((t)=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find((t)=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find((t)=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find((t)=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find((t)=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find((t)=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find((t)=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find((t)=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find((t)=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find((t)=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find((t)=>t.kind==="base64url")}get minLength(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t}get maxLength(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t}};F.create=(t)=>{return new F({checks:[],typeName:A.ZodString,coerce:t?.coerce??!1,..._(t)})};C=class C extends k{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce)t.data=Number(t.data);if(this._getType(t)!==h.number){let a=this._getOrReturnCtx(t);return m(a,{code:f.invalid_type,expected:h.number,received:a.parsedType}),x}let r=void 0,o=new S;for(let a of this._def.checks)if(a.kind==="int"){if(!q.isInteger(t.data))r=this._getOrReturnCtx(t,r),m(r,{code:f.invalid_type,expected:"integer",received:"float",message:a.message}),o.dirty()}else if(a.kind==="min"){if(a.inclusive?t.data<a.value:t.data<=a.value)r=this._getOrReturnCtx(t,r),m(r,{code:f.too_small,minimum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),o.dirty()}else if(a.kind==="max"){if(a.inclusive?t.data>a.value:t.data>=a.value)r=this._getOrReturnCtx(t,r),m(r,{code:f.too_big,maximum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),o.dirty()}else if(a.kind==="multipleOf"){if(Ll(t.data,a.value)!==0)r=this._getOrReturnCtx(t,r),m(r,{code:f.not_multiple_of,multipleOf:a.value,message:a.message}),o.dirty()}else if(a.kind==="finite"){if(!Number.isFinite(t.data))r=this._getOrReturnCtx(t,r),m(r,{code:f.not_finite,message:a.message}),o.dirty()}else q.assertNever(a);return{status:o.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,w.toString(n))}gt(t,n){return this.setLimit("min",t,!1,w.toString(n))}lte(t,n){return this.setLimit("max",t,!0,w.toString(n))}lt(t,n){return this.setLimit("max",t,!1,w.toString(n))}setLimit(t,n,r,o){return new C({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:w.toString(o)}]})}_addCheck(t){return new C({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:w.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:w.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:w.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:w.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:w.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:w.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:w.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:w.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:w.toString(t)})}get minValue(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t}get maxValue(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t}get isInt(){return!!this._def.checks.find((t)=>t.kind==="int"||t.kind==="multipleOf"&&q.isInteger(t.value))}get isFinite(){let t=null,n=null;for(let r of this._def.checks)if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;else if(r.kind==="min"){if(n===null||r.value>n)n=r.value}else if(r.kind==="max"){if(t===null||r.value<t)t=r.value}return Number.isFinite(n)&&Number.isFinite(t)}};C.create=(t)=>{return new C({checks:[],typeName:A.ZodNumber,coerce:t?.coerce||!1,..._(t)})};I=class I extends k{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==h.bigint)return this._getInvalidInput(t);let r=void 0,o=new S;for(let a of this._def.checks)if(a.kind==="min"){if(a.inclusive?t.data<a.value:t.data<=a.value)r=this._getOrReturnCtx(t,r),m(r,{code:f.too_small,type:"bigint",minimum:a.value,inclusive:a.inclusive,message:a.message}),o.dirty()}else if(a.kind==="max"){if(a.inclusive?t.data>a.value:t.data>=a.value)r=this._getOrReturnCtx(t,r),m(r,{code:f.too_big,type:"bigint",maximum:a.value,inclusive:a.inclusive,message:a.message}),o.dirty()}else if(a.kind==="multipleOf"){if(t.data%a.value!==BigInt(0))r=this._getOrReturnCtx(t,r),m(r,{code:f.not_multiple_of,multipleOf:a.value,message:a.message}),o.dirty()}else q.assertNever(a);return{status:o.value,value:t.data}}_getInvalidInput(t){let n=this._getOrReturnCtx(t);return m(n,{code:f.invalid_type,expected:h.bigint,received:n.parsedType}),x}gte(t,n){return this.setLimit("min",t,!0,w.toString(n))}gt(t,n){return this.setLimit("min",t,!1,w.toString(n))}lte(t,n){return this.setLimit("max",t,!0,w.toString(n))}lt(t,n){return this.setLimit("max",t,!1,w.toString(n))}setLimit(t,n,r,o){return new I({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:w.toString(o)}]})}_addCheck(t){return new I({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:w.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:w.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:w.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:w.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:w.toString(n)})}get minValue(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t}get maxValue(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t}};I.create=(t)=>{return new I({checks:[],typeName:A.ZodBigInt,coerce:t?.coerce??!1,..._(t)})};lt=class lt extends k{_parse(t){if(this._def.coerce)t.data=Boolean(t.data);if(this._getType(t)!==h.boolean){let r=this._getOrReturnCtx(t);return m(r,{code:f.invalid_type,expected:h.boolean,received:r.parsedType}),x}return R(t.data)}};lt.create=(t)=>{return new lt({typeName:A.ZodBoolean,coerce:t?.coerce||!1,..._(t)})};Z=class Z extends k{_parse(t){if(this._def.coerce)t.data=new Date(t.data);if(this._getType(t)!==h.date){let a=this._getOrReturnCtx(t);return m(a,{code:f.invalid_type,expected:h.date,received:a.parsedType}),x}if(Number.isNaN(t.data.getTime())){let a=this._getOrReturnCtx(t);return m(a,{code:f.invalid_date}),x}let r=new S,o=void 0;for(let a of this._def.checks)if(a.kind==="min"){if(t.data.getTime()<a.value)o=this._getOrReturnCtx(t,o),m(o,{code:f.too_small,message:a.message,inclusive:!0,exact:!1,minimum:a.value,type:"date"}),r.dirty()}else if(a.kind==="max"){if(t.data.getTime()>a.value)o=this._getOrReturnCtx(t,o),m(o,{code:f.too_big,message:a.message,inclusive:!0,exact:!1,maximum:a.value,type:"date"}),r.dirty()}else q.assertNever(a);return{status:r.value,value:new Date(t.data.getTime())}}_addCheck(t){return new Z({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:w.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:w.toString(n)})}get minDate(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t!=null?new Date(t):null}get maxDate(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t!=null?new Date(t):null}};Z.create=(t)=>{return new Z({checks:[],coerce:t?.coerce||!1,typeName:A.ZodDate,..._(t)})};Ct=class Ct extends k{_parse(t){if(this._getType(t)!==h.symbol){let r=this._getOrReturnCtx(t);return m(r,{code:f.invalid_type,expected:h.symbol,received:r.parsedType}),x}return R(t.data)}};Ct.create=(t)=>{return new Ct({typeName:A.ZodSymbol,..._(t)})};it=class it extends k{_parse(t){if(this._getType(t)!==h.undefined){let r=this._getOrReturnCtx(t);return m(r,{code:f.invalid_type,expected:h.undefined,received:r.parsedType}),x}return R(t.data)}};it.create=(t)=>{return new it({typeName:A.ZodUndefined,..._(t)})};bt=class bt extends k{_parse(t){if(this._getType(t)!==h.null){let r=this._getOrReturnCtx(t);return m(r,{code:f.invalid_type,expected:h.null,received:r.parsedType}),x}return R(t.data)}};bt.create=(t)=>{return new bt({typeName:A.ZodNull,..._(t)})};z=class z extends k{constructor(){super(...arguments);this._any=!0}_parse(t){return R(t.data)}};z.create=(t)=>{return new z({typeName:A.ZodAny,..._(t)})};j=class j extends k{constructor(){super(...arguments);this._unknown=!0}_parse(t){return R(t.data)}};j.create=(t)=>{return new j({typeName:A.ZodUnknown,..._(t)})};O=class O extends k{_parse(t){let n=this._getOrReturnCtx(t);return m(n,{code:f.invalid_type,expected:h.never,received:n.parsedType}),x}};O.create=(t)=>{return new O({typeName:A.ZodNever,..._(t)})};It=class It extends k{_parse(t){if(this._getType(t)!==h.undefined){let r=this._getOrReturnCtx(t);return m(r,{code:f.invalid_type,expected:h.void,received:r.parsedType}),x}return R(t.data)}};It.create=(t)=>{return new It({typeName:A.ZodVoid,..._(t)})};J=class J extends k{_parse(t){let{ctx:n,status:r}=this._processInputParams(t),o=this._def;if(n.parsedType!==h.array)return m(n,{code:f.invalid_type,expected:h.array,received:n.parsedType}),x;if(o.exactLength!==null){let e=n.data.length>o.exactLength.value,l=n.data.length<o.exactLength.value;if(e||l)m(n,{code:e?f.too_big:f.too_small,minimum:l?o.exactLength.value:void 0,maximum:e?o.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:o.exactLength.message}),r.dirty()}if(o.minLength!==null){if(n.data.length<o.minLength.value)m(n,{code:f.too_small,minimum:o.minLength.value,type:"array",inclusive:!0,exact:!1,message:o.minLength.message}),r.dirty()}if(o.maxLength!==null){if(n.data.length>o.maxLength.value)m(n,{code:f.too_big,maximum:o.maxLength.value,type:"array",inclusive:!0,exact:!1,message:o.maxLength.message}),r.dirty()}if(n.common.async)return Promise.all([...n.data].map((e,l)=>{return o.type._parseAsync(new Q(n,e,n.path,l))})).then((e)=>{return S.mergeArray(r,e)});let a=[...n.data].map((e,l)=>{return o.type._parseSync(new Q(n,e,n.path,l))});return S.mergeArray(r,a)}get element(){return this._def.type}min(t,n){return new J({...this._def,minLength:{value:t,message:w.toString(n)}})}max(t,n){return new J({...this._def,maxLength:{value:t,message:w.toString(n)}})}length(t,n){return new J({...this._def,exactLength:{value:t,message:w.toString(n)}})}nonempty(t){return this.min(1,t)}};J.create=(t,n)=>{return new J({type:t,minLength:null,maxLength:null,exactLength:null,typeName:A.ZodArray,..._(n)})};E=class E extends k{constructor(){super(...arguments);this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let t=this._def.shape(),n=q.objectKeys(t);return this._cached={shape:t,keys:n},this._cached}_parse(t){if(this._getType(t)!==h.object){let c=this._getOrReturnCtx(t);return m(c,{code:f.invalid_type,expected:h.object,received:c.parsedType}),x}let{status:r,ctx:o}=this._processInputParams(t),{shape:a,keys:e}=this._getCached(),l=[];if(!(this._def.catchall instanceof O&&this._def.unknownKeys==="strip")){for(let c in o.data)if(!e.includes(c))l.push(c)}let i=[];for(let c of e){let $=a[c],L=o.data[c];i.push({key:{status:"valid",value:c},value:$._parse(new Q(o,L,o.path,c)),alwaysSet:c in o.data})}if(this._def.catchall instanceof O){let c=this._def.unknownKeys;if(c==="passthrough")for(let $ of l)i.push({key:{status:"valid",value:$},value:{status:"valid",value:o.data[$]}});else if(c==="strict"){if(l.length>0)m(o,{code:f.unrecognized_keys,keys:l}),r.dirty()}else if(c==="strip");else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let c=this._def.catchall;for(let $ of l){let L=o.data[$];i.push({key:{status:"valid",value:$},value:c._parse(new Q(o,L,o.path,$)),alwaysSet:$ in o.data})}}if(o.common.async)return Promise.resolve().then(async()=>{let c=[];for(let $ of i){let L=await $.key,H=await $.value;c.push({key:L,value:H,alwaysSet:$.alwaysSet})}return c}).then((c)=>{return S.mergeObjectSync(r,c)});else return S.mergeObjectSync(r,i)}get shape(){return this._def.shape()}strict(t){return w.errToObj,new E({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,r)=>{let o=this._def.errorMap?.(n,r).message??r.defaultError;if(n.code==="unrecognized_keys")return{message:w.errToObj(t).message??o};return{message:o}}}:{}})}strip(){return new E({...this._def,unknownKeys:"strip"})}passthrough(){return new E({...this._def,unknownKeys:"passthrough"})}extend(t){return new E({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new E({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:A.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new E({...this._def,catchall:t})}pick(t){let n={};for(let r of q.objectKeys(t))if(t[r]&&this.shape[r])n[r]=this.shape[r];return new E({...this._def,shape:()=>n})}omit(t){let n={};for(let r of q.objectKeys(this.shape))if(!t[r])n[r]=this.shape[r];return new E({...this._def,shape:()=>n})}deepPartial(){return at(this)}partial(t){let n={};for(let r of q.objectKeys(this.shape)){let o=this.shape[r];if(t&&!t[r])n[r]=o;else n[r]=o.optional()}return new E({...this._def,shape:()=>n})}required(t){let n={};for(let r of q.objectKeys(this.shape))if(t&&!t[r])n[r]=this.shape[r];else{let a=this.shape[r];while(a instanceof G)a=a._def.innerType;n[r]=a}return new E({...this._def,shape:()=>n})}keyof(){return ra(q.objectKeys(this.shape))}};E.create=(t,n)=>{return new E({shape:()=>t,unknownKeys:"strip",catchall:O.create(),typeName:A.ZodObject,..._(n)})};E.strictCreate=(t,n)=>{return new E({shape:()=>t,unknownKeys:"strict",catchall:O.create(),typeName:A.ZodObject,..._(n)})};E.lazycreate=(t,n)=>{return new E({shape:t,unknownKeys:"strip",catchall:O.create(),typeName:A.ZodObject,..._(n)})};dt=class dt extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r=this._def.options;function o(a){for(let l of a)if(l.result.status==="valid")return l.result;for(let l of a)if(l.result.status==="dirty")return n.common.issues.push(...l.ctx.common.issues),l.result;let e=a.map((l)=>new Y(l.ctx.common.issues));return m(n,{code:f.invalid_union,unionErrors:e}),x}if(n.common.async)return Promise.all(r.map(async(a)=>{let e={...n,common:{...n.common,issues:[]},parent:null};return{result:await a._parseAsync({data:n.data,path:n.path,parent:e}),ctx:e}})).then(o);else{let a=void 0,e=[];for(let i of r){let c={...n,common:{...n.common,issues:[]},parent:null},$=i._parseSync({data:n.data,path:n.path,parent:c});if($.status==="valid")return $;else if($.status==="dirty"&&!a)a={result:$,ctx:c};if(c.common.issues.length)e.push(c.common.issues)}if(a)return n.common.issues.push(...a.ctx.common.issues),a.result;let l=e.map((i)=>new Y(i));return m(n,{code:f.invalid_union,unionErrors:l}),x}}get options(){return this._def.options}};dt.create=(t,n)=>{return new dt({options:t,typeName:A.ZodUnion,..._(n)})};vn=class vn extends k{_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==h.object)return m(n,{code:f.invalid_type,expected:h.object,received:n.parsedType}),x;let r=this.discriminator,o=n.data[r],a=this.optionsMap.get(o);if(!a)return m(n,{code:f.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),x;if(n.common.async)return a._parseAsync({data:n.data,path:n.path,parent:n});else return a._parseSync({data:n.data,path:n.path,parent:n})}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,n,r){let o=new Map;for(let a of n){let e=U(a.shape[t]);if(!e.length)throw Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(let l of e){if(o.has(l))throw Error(`Discriminator property ${String(t)} has duplicate value ${String(l)}`);o.set(l,a)}}return new vn({typeName:A.ZodDiscriminatedUnion,discriminator:t,options:n,optionsMap:o,..._(r)})}};ct=class ct extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t),o=(a,e)=>{if(mn(a)||mn(e))return x;let l=Xo(a.value,e.value);if(!l.valid)return m(r,{code:f.invalid_intersection_types}),x;if(pn(a)||pn(e))n.dirty();return{status:n.value,value:l.data}};if(r.common.async)return Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([a,e])=>o(a,e));else return o(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}};ct.create=(t,n,r)=>{return new ct({left:t,right:n,typeName:A.ZodIntersection,..._(r)})};W=class W extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.array)return m(r,{code:f.invalid_type,expected:h.array,received:r.parsedType}),x;if(r.data.length<this._def.items.length)return m(r,{code:f.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),x;if(!this._def.rest&&r.data.length>this._def.items.length)m(r,{code:f.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty();let a=[...r.data].map((e,l)=>{let i=this._def.items[l]||this._def.rest;if(!i)return null;return i._parse(new Q(r,e,r.path,l))}).filter((e)=>!!e);if(r.common.async)return Promise.all(a).then((e)=>{return S.mergeArray(n,e)});else return S.mergeArray(n,a)}get items(){return this._def.items}rest(t){return new W({...this._def,rest:t})}};W.create=(t,n)=>{if(!Array.isArray(t))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new W({items:t,typeName:A.ZodTuple,rest:null,..._(n)})};Pt=class Pt extends k{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.object)return m(r,{code:f.invalid_type,expected:h.object,received:r.parsedType}),x;let o=[],a=this._def.keyType,e=this._def.valueType;for(let l in r.data)o.push({key:a._parse(new Q(r,l,r.path,l)),value:e._parse(new Q(r,r.data[l],r.path,l)),alwaysSet:l in r.data});if(r.common.async)return S.mergeObjectAsync(n,o);else return S.mergeObjectSync(n,o)}get element(){return this._def.valueType}static create(t,n,r){if(n instanceof k)return new Pt({keyType:t,valueType:n,typeName:A.ZodRecord,..._(r)});return new Pt({keyType:F.create(),valueType:t,typeName:A.ZodRecord,..._(n)})}};Tt=class Tt extends k{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.map)return m(r,{code:f.invalid_type,expected:h.map,received:r.parsedType}),x;let o=this._def.keyType,a=this._def.valueType,e=[...r.data.entries()].map(([l,i],c)=>{return{key:o._parse(new Q(r,l,r.path,[c,"key"])),value:a._parse(new Q(r,i,r.path,[c,"value"]))}});if(r.common.async){let l=new Map;return Promise.resolve().then(async()=>{for(let i of e){let c=await i.key,$=await i.value;if(c.status==="aborted"||$.status==="aborted")return x;if(c.status==="dirty"||$.status==="dirty")n.dirty();l.set(c.value,$.value)}return{status:n.value,value:l}})}else{let l=new Map;for(let i of e){let{key:c,value:$}=i;if(c.status==="aborted"||$.status==="aborted")return x;if(c.status==="dirty"||$.status==="dirty")n.dirty();l.set(c.value,$.value)}return{status:n.value,value:l}}}};Tt.create=(t,n,r)=>{return new Tt({valueType:n,keyType:t,typeName:A.ZodMap,..._(r)})};tt=class tt extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.set)return m(r,{code:f.invalid_type,expected:h.set,received:r.parsedType}),x;let o=this._def;if(o.minSize!==null){if(r.data.size<o.minSize.value)m(r,{code:f.too_small,minimum:o.minSize.value,type:"set",inclusive:!0,exact:!1,message:o.minSize.message}),n.dirty()}if(o.maxSize!==null){if(r.data.size>o.maxSize.value)m(r,{code:f.too_big,maximum:o.maxSize.value,type:"set",inclusive:!0,exact:!1,message:o.maxSize.message}),n.dirty()}let a=this._def.valueType;function e(i){let c=new Set;for(let $ of i){if($.status==="aborted")return x;if($.status==="dirty")n.dirty();c.add($.value)}return{status:n.value,value:c}}let l=[...r.data.values()].map((i,c)=>a._parse(new Q(r,i,r.path,c)));if(r.common.async)return Promise.all(l).then((i)=>e(i));else return e(l)}min(t,n){return new tt({...this._def,minSize:{value:t,message:w.toString(n)}})}max(t,n){return new tt({...this._def,maxSize:{value:t,message:w.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}};tt.create=(t,n)=>{return new tt({valueType:t,minSize:null,maxSize:null,typeName:A.ZodSet,..._(n)})};et=class et extends k{constructor(){super(...arguments);this.validate=this.implement}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==h.function)return m(n,{code:f.invalid_type,expected:h.function,received:n.parsedType}),x;function r(l,i){return jt({data:l,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,ot(),y].filter((c)=>!!c),issueData:{code:f.invalid_arguments,argumentsError:i}})}function o(l,i){return jt({data:l,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,ot(),y].filter((c)=>!!c),issueData:{code:f.invalid_return_type,returnTypeError:i}})}let a={errorMap:n.common.contextualErrorMap},e=n.data;if(this._def.returns instanceof nt){let l=this;return R(async function(...i){let c=new Y([]),$=await l._def.args.parseAsync(i,a).catch((M)=>{throw c.addIssue(r(i,M)),c}),L=await Reflect.apply(e,this,$);return await l._def.returns._def.type.parseAsync(L,a).catch((M)=>{throw c.addIssue(o(L,M)),c})})}else{let l=this;return R(function(...i){let c=l._def.args.safeParse(i,a);if(!c.success)throw new Y([r(i,c.error)]);let $=Reflect.apply(e,this,c.data),L=l._def.returns.safeParse($,a);if(!L.success)throw new Y([o($,L.error)]);return L.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new et({...this._def,args:W.create(t).rest(j.create())})}returns(t){return new et({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,n,r){return new et({args:t?t:W.create([]).rest(j.create()),returns:n||j.create(),typeName:A.ZodFunction,..._(r)})}};ft=class ft extends k{get schema(){return this._def.getter()}_parse(t){let{ctx:n}=this._processInputParams(t);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};ft.create=(t,n)=>{return new ft({getter:t,typeName:A.ZodLazy,..._(n)})};ht=class ht extends k{_parse(t){if(t.data!==this._def.value){let n=this._getOrReturnCtx(t);return m(n,{received:n.data,code:f.invalid_literal,expected:this._def.value}),x}return{status:"valid",value:t.data}}get value(){return this._def.value}};ht.create=(t,n)=>{return new ht({value:t,typeName:A.ZodLiteral,..._(n)})};P=class P extends k{_parse(t){if(typeof t.data!=="string"){let n=this._getOrReturnCtx(t),r=this._def.values;return m(n,{expected:q.joinValues(r),received:n.parsedType,code:f.invalid_type}),x}if(!this._cache)this._cache=new Set(this._def.values);if(!this._cache.has(t.data)){let n=this._getOrReturnCtx(t),r=this._def.values;return m(n,{received:n.data,code:f.invalid_enum_value,options:r}),x}return R(t.data)}get options(){return this._def.values}get enum(){let t={};for(let n of this._def.values)t[n]=n;return t}get Values(){let t={};for(let n of this._def.values)t[n]=n;return t}get Enum(){let t={};for(let n of this._def.values)t[n]=n;return t}extract(t,n=this._def){return P.create(t,{...this._def,...n})}exclude(t,n=this._def){return P.create(this.options.filter((r)=>!t.includes(r)),{...this._def,...n})}};P.create=ra;gt=class gt extends k{_parse(t){let n=q.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(t);if(r.parsedType!==h.string&&r.parsedType!==h.number){let o=q.objectValues(n);return m(r,{expected:q.joinValues(o),received:r.parsedType,code:f.invalid_type}),x}if(!this._cache)this._cache=new Set(q.getValidEnumValues(this._def.values));if(!this._cache.has(t.data)){let o=q.objectValues(n);return m(r,{received:r.data,code:f.invalid_enum_value,options:o}),x}return R(t.data)}get enum(){return this._def.values}};gt.create=(t,n)=>{return new gt({values:t,typeName:A.ZodNativeEnum,..._(n)})};nt=class nt extends k{unwrap(){return this._def.type}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==h.promise&&n.common.async===!1)return m(n,{code:f.invalid_type,expected:h.promise,received:n.parsedType}),x;let r=n.parsedType===h.promise?n.data:Promise.resolve(n.data);return R(r.then((o)=>{return this._def.type.parseAsync(o,{path:n.path,errorMap:n.common.contextualErrorMap})}))}};nt.create=(t,n)=>{return new nt({type:t,typeName:A.ZodPromise,..._(n)})};B=class B extends k{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===A.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){let{status:n,ctx:r}=this._processInputParams(t),o=this._def.effect||null,a={addIssue:(e)=>{if(m(r,e),e.fatal)n.abort();else n.dirty()},get path(){return r.path}};if(a.addIssue=a.addIssue.bind(a),o.type==="preprocess"){let e=o.transform(r.data,a);if(r.common.async)return Promise.resolve(e).then(async(l)=>{if(n.value==="aborted")return x;let i=await this._def.schema._parseAsync({data:l,path:r.path,parent:r});if(i.status==="aborted")return x;if(i.status==="dirty")return T(i.value);if(n.value==="dirty")return T(i.value);return i});else{if(n.value==="aborted")return x;let l=this._def.schema._parseSync({data:e,path:r.path,parent:r});if(l.status==="aborted")return x;if(l.status==="dirty")return T(l.value);if(n.value==="dirty")return T(l.value);return l}}if(o.type==="refinement"){let e=(l)=>{let i=o.refinement(l,a);if(r.common.async)return Promise.resolve(i);if(i instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return l};if(r.common.async===!1){let l=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(l.status==="aborted")return x;if(l.status==="dirty")n.dirty();return e(l.value),{status:n.value,value:l.value}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((l)=>{if(l.status==="aborted")return x;if(l.status==="dirty")n.dirty();return e(l.value).then(()=>{return{status:n.value,value:l.value}})})}if(o.type==="transform")if(r.common.async===!1){let e=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!K(e))return x;let l=o.transform(e.value,a);if(l instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:l}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((e)=>{if(!K(e))return x;return Promise.resolve(o.transform(e.value,a)).then((l)=>({status:n.value,value:l}))});q.assertNever(o)}};B.create=(t,n,r)=>{return new B({schema:t,typeName:A.ZodEffects,effect:n,..._(r)})};B.createWithPreprocess=(t,n,r)=>{return new B({schema:n,effect:{type:"preprocess",transform:t},typeName:A.ZodEffects,..._(r)})};G=class G extends k{_parse(t){if(this._getType(t)===h.undefined)return R(void 0);return this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};G.create=(t,n)=>{return new G({innerType:t,typeName:A.ZodOptional,..._(n)})};N=class N extends k{_parse(t){if(this._getType(t)===h.null)return R(null);return this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};N.create=(t,n)=>{return new N({innerType:t,typeName:A.ZodNullable,..._(n)})};st=class st extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r=n.data;if(n.parsedType===h.undefined)r=this._def.defaultValue();return this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};st.create=(t,n)=>{return new st({innerType:t,typeName:A.ZodDefault,defaultValue:typeof n.default==="function"?n.default:()=>n.default,..._(n)})};mt=class mt extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r={...n,common:{...n.common,issues:[]}},o=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});if(rt(o))return o.then((a)=>{return{status:"valid",value:a.status==="valid"?a.value:this._def.catchValue({get error(){return new Y(r.common.issues)},input:r.data})}});else return{status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new Y(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}};mt.create=(t,n)=>{return new mt({innerType:t,typeName:A.ZodCatch,catchValue:typeof n.catch==="function"?n.catch:()=>n.catch,..._(n)})};Zt=class Zt extends k{_parse(t){if(this._getType(t)!==h.nan){let r=this._getOrReturnCtx(t);return m(r,{code:f.invalid_type,expected:h.nan,received:r.parsedType}),x}return{status:"valid",value:t.data}}};Zt.create=(t)=>{return new Zt({typeName:A.ZodNaN,..._(t)})};El=Symbol("zod_brand");un=class un extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}};zt=class zt extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.common.async)return(async()=>{let a=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});if(a.status==="aborted")return x;if(a.status==="dirty")return n.dirty(),T(a.value);else return this._def.out._parseAsync({data:a.value,path:r.path,parent:r})})();else{let o=this._def.in._parseSync({data:r.data,path:r.path,parent:r});if(o.status==="aborted")return x;if(o.status==="dirty")return n.dirty(),{status:"dirty",value:o.value};else return this._def.out._parseSync({data:o.value,path:r.path,parent:r})}}static create(t,n){return new zt({in:t,out:n,typeName:A.ZodPipeline})}};pt=class pt extends k{_parse(t){let n=this._def.innerType._parse(t),r=(o)=>{if(K(o))o.value=Object.freeze(o.value);return o};return rt(n)?n.then((o)=>r(o)):r(n)}unwrap(){return this._def.innerType}};pt.create=(t,n)=>{return new pt({innerType:t,typeName:A.ZodReadonly,..._(n)})};Ml={object:E.lazycreate};(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(A||(A={}));ea=F.create,la=C.create,Sl=Zt.create,Rl=I.create,ia=lt.create,Yl=Z.create,Xl=Ct.create,Fl=it.create,Jl=bt.create,Gl=z.create,Ql=j.create,Bl=O.create,Dl=It.create,Ol=J.create,Wl=E.create,yl=E.strictCreate,Ul=dt.create,Nl=vn.create,Vl=ct.create,Kl=W.create,jl=Pt.create,Cl=Tt.create,Il=tt.create,Pl=et.create,Tl=ft.create,Zl=ht.create,zl=P.create,ti=gt.create,ni=nt.create,oi=B.create,ri=G.create,ai=N.create,ei=B.createWithPreprocess,li=zt.create,ci={string:(t)=>F.create({...t,coerce:!0}),number:(t)=>C.create({...t,coerce:!0}),boolean:(t)=>lt.create({...t,coerce:!0}),bigint:(t)=>I.create({...t,coerce:!0}),date:(t)=>Z.create({...t,coerce:!0})},fi=x});var p={};u(p,{void:()=>Dl,util:()=>q,unknown:()=>Ql,union:()=>Ul,undefined:()=>Fl,tuple:()=>Kl,transformer:()=>oi,symbol:()=>Xl,string:()=>ea,strictObject:()=>yl,setErrorMap:()=>al,set:()=>Il,record:()=>jl,quotelessJson:()=>ol,promise:()=>ni,preprocess:()=>ei,pipeline:()=>li,ostring:()=>ii,optional:()=>ri,onumber:()=>bi,oboolean:()=>di,objectUtil:()=>Ho,object:()=>Wl,number:()=>la,nullable:()=>ai,null:()=>Jl,never:()=>Bl,nativeEnum:()=>ti,nan:()=>Sl,map:()=>Cl,makeIssue:()=>jt,literal:()=>Zl,lazy:()=>Tl,late:()=>Ml,isValid:()=>K,isDirty:()=>pn,isAsync:()=>rt,isAborted:()=>mn,intersection:()=>Vl,instanceof:()=>Hl,getParsedType:()=>D,getErrorMap:()=>ot,function:()=>Pl,enum:()=>zl,effect:()=>oi,discriminatedUnion:()=>Nl,defaultErrorMap:()=>y,datetimeRegex:()=>oa,date:()=>Yl,custom:()=>aa,coerce:()=>ci,boolean:()=>ia,bigint:()=>Rl,array:()=>Ol,any:()=>Gl,addIssueToContext:()=>m,ZodVoid:()=>It,ZodUnknown:()=>j,ZodUnion:()=>dt,ZodUndefined:()=>it,ZodType:()=>k,ZodTuple:()=>W,ZodTransformer:()=>B,ZodSymbol:()=>Ct,ZodString:()=>F,ZodSet:()=>tt,ZodSchema:()=>k,ZodRecord:()=>Pt,ZodReadonly:()=>pt,ZodPromise:()=>nt,ZodPipeline:()=>zt,ZodParsedType:()=>h,ZodOptional:()=>G,ZodObject:()=>E,ZodNumber:()=>C,ZodNullable:()=>N,ZodNull:()=>bt,ZodNever:()=>O,ZodNativeEnum:()=>gt,ZodNaN:()=>Zt,ZodMap:()=>Tt,ZodLiteral:()=>ht,ZodLazy:()=>ft,ZodIssueCode:()=>f,ZodIntersection:()=>ct,ZodFunction:()=>et,ZodFirstPartyTypeKind:()=>A,ZodError:()=>Y,ZodEnum:()=>P,ZodEffects:()=>B,ZodDiscriminatedUnion:()=>vn,ZodDefault:()=>st,ZodDate:()=>Z,ZodCatch:()=>mt,ZodBranded:()=>un,ZodBoolean:()=>lt,ZodBigInt:()=>I,ZodArray:()=>J,ZodAny:()=>z,Schema:()=>k,ParseStatus:()=>S,OK:()=>R,NEVER:()=>fi,INVALID:()=>x,EMPTY_PATH:()=>el,DIRTY:()=>T,BRAND:()=>El});var Fo=s(()=>{sn();Ro();Pr();Kt();ba();gn()});var da=s(()=>{Fo();Fo()});function Jo(t){if(t===null||typeof t!=="object")return t;if(Array.isArray(t))return t.map(Jo);let n={};for(let r of Object.keys(t))n[r]=Jo(t[r]);return n}var hi,xd;var ca=s(()=>{hi={validation:{trimStrings:!1,emptyAsNullDefault:!1},security:{csrf:{enabled:!0,excludePaths:[],sameSite:"Strict",secure:!1},rateLimit:{enabled:!0,windowMs:60000,maxRequests:60,excludePaths:[]}},hooks:{onValidationError:null,onSecurityViolation:null,onRateLimit:null,onDatabaseError:null,onRequest:null}},xd=Jo(hi)});class tn{static validate(t,n){try{return{success:!0,data:t.parse(n)}}catch(r){if(r instanceof p.ZodError){let o={};return r.errors.forEach((a)=>{let e=a.path.join(".");o[e]=a.message}),{success:!1,errors:o}}return{success:!1,errors:{general:"Validation failed"}}}}static validateField(t,n){try{return t.parse(n),{success:!0}}catch(r){if(r instanceof p.ZodError)return{success:!1,error:r.errors[0]?.message||"Invalid value"};return{success:!1,error:"Validation failed"}}}static getFieldError(t,n){if(t.success)return null;return t.errors?.[n]||null}static hasFieldError(t,n){return!!this.getFieldError(t,n)}}var fa,V;var Go=s(()=>{da();ca();fa={login:p.object({email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters").regex(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)/,"Password must contain at least one uppercase letter, one lowercase letter, and one number")}),register:p.object({name:p.string().min(2,"Name must be at least 2 characters").max(50,"Name must be less than 50 characters").regex(/^[a-zA-Z\s'-]+$/,"Name can only contain letters, spaces, hyphens, and apostrophes"),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters").regex(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&])/,"Password must contain uppercase, lowercase, number, and special character"),confirmPassword:p.string()}).refine((t)=>t.password===t.confirmPassword,{message:"Passwords don't match",path:["confirmPassword"]}),auth:{register:p.object({action:p.literal("register"),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),username:p.string().min(3,"Username must be at least 3 characters").max(30,"Username must be less than 30 characters"),password:p.string().min(8,"Password must be at least 8 characters"),full_name:p.string().min(2,"Full name is required").max(100,"Full name is too long")}),login:p.object({action:p.literal("login"),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters")}),logout:p.object({action:p.literal("logout")}),action:p.discriminatedUnion("action",[p.object({action:p.literal("register")}).merge(p.object({email:p.string().min(1,"Email is required").email("Please enter a valid email address"),username:p.string().min(3,"Username must be at least 3 characters").max(30,"Username must be less than 30 characters"),password:p.string().min(8,"Password must be at least 8 characters"),full_name:p.string().min(2,"Full name is required").max(100,"Full name is too long")})),p.object({action:p.literal("login")}).merge(p.object({email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters")})),p.object({action:p.literal("logout")})])},contact:p.object({name:p.string().min(2,"Name must be at least 2 characters").max(100,"Name is too long"),email:p.string().email("Please enter a valid email address"),message:p.string().min(10,"Message must be at least 10 characters").max(1000,"Message is too long")}),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters").regex(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)/,"Password must contain uppercase, lowercase, and number"),phone:p.string().regex(/^[\+]?[1-9][\d]{0,15}$/,"Please enter a valid phone number"),url:p.string().min(1,"URL is required").url("Please enter a valid URL"),required:p.string().min(1,"This field is required"),positiveNumber:p.number().positive("Must be a positive number"),integer:p.number().int("Must be a whole number"),futureDate:p.date().min(new Date,"Date must be in the future"),imageFile:p.instanceof(File).refine((t)=>t.size<=5242880,"File size must be less than 5MB").refine((t)=>["image/jpeg","image/png","image/gif","image/webp"].includes(t.type),"File must be a JPEG, PNG, GIF, or WebP image"),userProfile:p.object({full_name:p.string().min(2,"Full name must be at least 2 characters").max(100,"Full name is too long").optional(),bio:p.string().max(500,"Bio must be less than 500 characters").nullable().optional(),avatar_url:p.string().url("Please enter a valid URL").nullable().optional(),theme:p.enum(["africanity","dark","light","system"]).optional(),language:p.string().min(2).max(10).optional()}),project:p.object({name:p.string().min(1,"Project name is required").max(100,"Project name is too long"),description:p.string().max(1000,"Description is too long").nullable().optional(),repository_url:p.string().url("Please enter a valid repository URL").nullable().optional(),demo_url:p.string().url("Please enter a valid demo URL").nullable().optional(),tags:p.array(p.string()).optional(),is_public:p.boolean().optional()})};V={required:(t="This field is required")=>p.string().min(1,t),email:(t="Please enter a valid email address")=>p.string().email(t),minLength:(t,n)=>p.string().min(t,n||`Must be at least ${t} characters`),maxLength:(t,n)=>p.string().max(t,n||`Must be less than ${t} characters`),pattern:(t,n)=>p.string().regex(t,n),numeric:(t="Must be a number")=>p.string().regex(/^\d+$/,t),phone:(t="Please enter a valid phone number")=>p.string().regex(/^[\+]?[1-9][\d]{0,15}$/,t),url:(t="Please enter a valid URL")=>p.string().min(1,"URL is required").url(t)}});var ha={};u(ha,{default:()=>gi,AfriInput:()=>$n});var $n,gi;var ga=s(()=>{v();Go();$n=class $n extends b{static get observedAttributes(){return["type","name","label","placeholder","error","helper","theme","icon","required","aria-label","aria-describedby","validation"]}constructor(){super();this._uniqueId=Math.random().toString(36).substr(2,9),this.render()}get value(){return this.shadowRoot.querySelector("input")?.value||""}set value(t){let n=this.shadowRoot.querySelector("input");if(n)n.value=t}connectedCallback(){this._attachInputListeners(),this.loadStyles()}attributeChangedCallback(){this.render(),this._attachInputListeners()}_attachInputListeners(){let t=this.shadowRoot.querySelector("input");if(!t)return;t.addEventListener("input",(n)=>{if(this.emit("af-input",{value:n.target.value}),this.hasAttribute("error"))this.removeAttribute("error")}),t.addEventListener("blur",()=>{this.emit("af-blur",{value:this.value}),this._validateInput()})}_setupValidation(){if(!this.getAttribute("validation"))return;let n=this.shadowRoot.querySelector("input");if(!n)return;n.addEventListener("input",()=>{if(this.hasAttribute("error"))this.removeAttribute("error")})}_validateInput(){let t=this.shadowRoot.querySelector("input");if(!t)return;let n=this.getAttribute("validation"),r=t.value;if(this.hasAttribute("required")&&!r.trim()){this.setAttribute("error","This field is required");return}if(n&&r.trim()){let a=this._getValidationSchema(n);if(a){let e=tn.validateField(a,r);if(!e.success)this.setAttribute("error",e.error);else this.removeAttribute("error")}}}_getValidationSchema(t){let n={email:V.email(),password:V.password(),phone:V.phone(),url:V.url(),required:V.required()};if(t.includes(":")){let[r,o]=t.split(":"),a=parseInt(o);switch(r){case"minLength":return V.minLength(a);case"maxLength":return V.maxLength(a);case"pattern":return V.pattern(new RegExp(o),"Invalid format")}}return n[t]||null}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("type")||"text",n=this.getAttribute("name")||"",r=this.getAttribute("label")||"",o=this.getAttribute("placeholder")||"",a=this.getAttribute("error")||"",e=this.getAttribute("helper")||"",l=this.getAttribute("theme")||"tanzania",i=this.getAttribute("icon")||"",c=this.hasAttribute("required"),$=this.getAttribute("aria-label"),L=this.getAttribute("aria-describedby"),H={tanzania:{focus:"#1EB53A",error:"#DC3545"},maasai:{focus:"#FF0000",error:"#8B0000"},ndebele:{focus:"#4169E1",error:"#DC143C"}},M=H[l]||H.tanzania,X=[];if(a)X.push(`error-${this._uniqueId}`);else if(e)X.push(`helper-${this._uniqueId}`);if(L)X.push(...L.split(" "));let Un=X.length>0?`aria-describedby="${X.join(" ")}"`:"";this.shadowRoot.innerHTML=`
|
|
1905
|
+
`}};f("af-navbar",ln);nl=ln});var q,Eo,h,D=(t)=>{switch(typeof t){case"undefined":return h.undefined;case"string":return h.string;case"number":return Number.isNaN(t)?h.nan:h.number;case"boolean":return h.boolean;case"function":return h.function;case"bigint":return h.bigint;case"symbol":return h.symbol;case"object":if(Array.isArray(t))return h.array;if(t===null)return h.null;if(t.then&&typeof t.then==="function"&&t.catch&&typeof t.catch==="function")return h.promise;if(typeof Map<"u"&&t instanceof Map)return h.map;if(typeof Set<"u"&&t instanceof Set)return h.set;if(typeof Date<"u"&&t instanceof Date)return h.date;return h.object;default:return h.unknown}};var Vt=m(()=>{(function(t){t.assertEqual=(a)=>{};function n(a){}t.assertIs=n;function r(a){throw Error()}t.assertNever=r,t.arrayToEnum=(a)=>{let e={};for(let l of a)e[l]=l;return e},t.getValidEnumValues=(a)=>{let e=t.objectKeys(a).filter((b)=>typeof a[a[b]]!=="number"),l={};for(let b of e)l[b]=a[b];return t.objectValues(l)},t.objectValues=(a)=>{return t.objectKeys(a).map(function(e){return a[e]})},t.objectKeys=typeof Object.keys==="function"?(a)=>Object.keys(a):(a)=>{let e=[];for(let l in a)if(Object.prototype.hasOwnProperty.call(a,l))e.push(l);return e},t.find=(a,e)=>{for(let l of a)if(e(l))return l;return},t.isInteger=typeof Number.isInteger==="function"?(a)=>Number.isInteger(a):(a)=>typeof a==="number"&&Number.isFinite(a)&&Math.floor(a)===a;function o(a,e=" | "){return a.map((l)=>typeof l==="string"?`'${l}'`:l).join(e)}t.joinValues=o,t.jsonStringifyReplacer=(a,e)=>{if(typeof e==="bigint")return e.toString();return e}})(q||(q={}));(function(t){t.mergeShapes=(n,r)=>{return{...n,...r}}})(Eo||(Eo={}));h=q.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"])});var c,ol=(t)=>{return JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:")},Y;var bn=m(()=>{Vt();c=q.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);Y=class Y extends Error{get errors(){return this.issues}constructor(t){super();this.issues=[],this.addIssue=(r)=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};let n=new.target.prototype;if(Object.setPrototypeOf)Object.setPrototypeOf(this,n);else this.__proto__=n;this.name="ZodError",this.issues=t}format(t){let n=t||function(a){return a.message},r={_errors:[]},o=(a)=>{for(let e of a.issues)if(e.code==="invalid_union")e.unionErrors.map(o);else if(e.code==="invalid_return_type")o(e.returnTypeError);else if(e.code==="invalid_arguments")o(e.argumentsError);else if(e.path.length===0)r._errors.push(n(e));else{let l=r,b=0;while(b<e.path.length){let d=e.path[b];if(b!==e.path.length-1)l[d]=l[d]||{_errors:[]};else l[d]=l[d]||{_errors:[]},l[d]._errors.push(n(e));l=l[d],b++}}};return o(this),r}static assert(t){if(!(t instanceof Y))throw Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,q.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=(n)=>n.message){let n={},r=[];for(let o of this.issues)if(o.path.length>0){let a=o.path[0];n[a]=n[a]||[],n[a].push(t(o))}else r.push(t(o));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}};Y.create=(t)=>{return new Y(t)}});var rl=(t,n)=>{let r;switch(t.code){case c.invalid_type:if(t.received===h.undefined)r="Required";else r=`Expected ${t.expected}, received ${t.received}`;break;case c.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,q.jsonStringifyReplacer)}`;break;case c.unrecognized_keys:r=`Unrecognized key(s) in object: ${q.joinValues(t.keys,", ")}`;break;case c.invalid_union:r="Invalid input";break;case c.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${q.joinValues(t.options)}`;break;case c.invalid_enum_value:r=`Invalid enum value. Expected ${q.joinValues(t.options)}, received '${t.received}'`;break;case c.invalid_arguments:r="Invalid function arguments";break;case c.invalid_return_type:r="Invalid function return type";break;case c.invalid_date:r="Invalid date";break;case c.invalid_string:if(typeof t.validation==="object")if("includes"in t.validation){if(r=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position==="number")r=`${r} at one or more positions greater than or equal to ${t.validation.position}`}else if("startsWith"in t.validation)r=`Invalid input: must start with "${t.validation.startsWith}"`;else if("endsWith"in t.validation)r=`Invalid input: must end with "${t.validation.endsWith}"`;else q.assertNever(t.validation);else if(t.validation!=="regex")r=`Invalid ${t.validation}`;else r="Invalid";break;case c.too_small:if(t.type==="array")r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`;else if(t.type==="string")r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`;else if(t.type==="number")r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`;else if(t.type==="bigint")r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`;else if(t.type==="date")r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`;else r="Invalid input";break;case c.too_big:if(t.type==="array")r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`;else if(t.type==="string")r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`;else if(t.type==="number")r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`;else if(t.type==="bigint")r=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`;else if(t.type==="date")r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`;else r="Invalid input";break;case c.custom:r="Invalid input";break;case c.invalid_intersection_types:r="Intersection results could not be merged";break;case c.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case c.not_finite:r="Number must be finite";break;default:r=n.defaultError,q.assertNever(t)}return{message:r}},N;var Mo=m(()=>{bn();Vt();N=rl});function al(t){Vr=t}function rt(){return Vr}var Vr;var fn=m(()=>{Mo();Vr=N});function s(t,n){let r=rt(),o=Kt({issueData:n,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,r,r===N?void 0:N].filter((a)=>!!a)});t.common.issues.push(o)}class S{constructor(){this.value="valid"}dirty(){if(this.value==="valid")this.value="dirty"}abort(){if(this.value!=="aborted")this.value="aborted"}static mergeArray(t,n){let r=[];for(let o of n){if(o.status==="aborted")return x;if(o.status==="dirty")t.dirty();r.push(o.value)}return{status:t.value,value:r}}static async mergeObjectAsync(t,n){let r=[];for(let o of n){let a=await o.key,e=await o.value;r.push({key:a,value:e})}return S.mergeObjectSync(t,r)}static mergeObjectSync(t,n){let r={};for(let o of n){let{key:a,value:e}=o;if(a.status==="aborted")return x;if(e.status==="aborted")return x;if(a.status==="dirty")t.dirty();if(e.status==="dirty")t.dirty();if(a.value!=="__proto__"&&(typeof e.value<"u"||o.alwaysSet))r[a.value]=e.value}return{status:t.value,value:r}}}var Kt=(t)=>{let{data:n,path:r,errorMaps:o,issueData:a}=t,e=[...r,...a.path||[]],l={...a,path:e};if(a.message!==void 0)return{...a,path:e,message:a.message};let b="",d=o.filter(($)=>!!$).slice().reverse();for(let $ of d)b=$(l,{data:n,defaultError:b}).message;return{...a,path:e,message:b}},el,x,Z=(t)=>({status:"dirty",value:t}),R=(t)=>({status:"valid",value:t}),dn=(t)=>t.status==="aborted",cn=(t)=>t.status==="dirty",j=(t)=>t.status==="valid",at=(t)=>typeof Promise<"u"&&t instanceof Promise;var Ho=m(()=>{fn();Mo();el=[];x=Object.freeze({status:"aborted"})});var Kr=()=>{};var w;var jr=m(()=>{(function(t){t.errToObj=(n)=>typeof n==="string"?{message:n}:n||{},t.toString=(n)=>typeof n==="string"?n:n?.message})(w||(w={}))});class G{constructor(t,n,r,o){this._cachedPath=[],this.parent=t,this.data=n,this._path=r,this._key=o}get path(){if(!this._cachedPath.length)if(Array.isArray(this._key))this._cachedPath.push(...this._path,...this._key);else this._cachedPath.push(...this._path,this._key);return this._cachedPath}}function _(t){if(!t)return{};let{errorMap:n,invalid_type_error:r,required_error:o,description:a}=t;if(n&&(r||o))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);if(n)return{errorMap:n,description:a};return{errorMap:(l,b)=>{let{message:d}=t;if(l.code==="invalid_enum_value")return{message:d??b.defaultError};if(typeof b.data>"u")return{message:d??o??b.defaultError};if(l.code!=="invalid_type")return{message:b.defaultError};return{message:d??r??b.defaultError}},description:a}}class k{get description(){return this._def.description}_getType(t){return D(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:D(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new S,ctx:{common:t.parent.common,data:t.data,parsedType:D(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){let n=this._parse(t);if(at(n))throw Error("Synchronous parse encountered promise.");return n}_parseAsync(t){let n=this._parse(t);return Promise.resolve(n)}parse(t,n){let r=this.safeParse(t,n);if(r.success)return r.data;throw r.error}safeParse(t,n){let r={common:{issues:[],async:n?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:D(t)},o=this._parseSync({data:t,path:r.path,parent:r});return Cr(r,o)}"~validate"(t){let n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:D(t)};if(!this["~standard"].async)try{let r=this._parseSync({data:t,path:[],parent:n});return j(r)?{value:r.value}:{issues:n.common.issues}}catch(r){if(r?.message?.toLowerCase()?.includes("encountered"))this["~standard"].async=!0;n.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:n}).then((r)=>j(r)?{value:r.value}:{issues:n.common.issues})}async parseAsync(t,n){let r=await this.safeParseAsync(t,n);if(r.success)return r.data;throw r.error}async safeParseAsync(t,n){let r={common:{issues:[],contextualErrorMap:n?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:D(t)},o=this._parse({data:t,path:r.path,parent:r}),a=await(at(o)?o:Promise.resolve(o));return Cr(r,a)}refine(t,n){let r=(o)=>{if(typeof n==="string"||typeof n>"u")return{message:n};else if(typeof n==="function")return n(o);else return n};return this._refinement((o,a)=>{let e=t(o),l=()=>a.addIssue({code:c.custom,...r(o)});if(typeof Promise<"u"&&e instanceof Promise)return e.then((b)=>{if(!b)return l(),!1;else return!0});if(!e)return l(),!1;else return!0})}refinement(t,n){return this._refinement((r,o)=>{if(!t(r))return o.addIssue(typeof n==="function"?n(r,o):n),!1;else return!0})}_refinement(t){return new B({schema:this,typeName:A.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:(n)=>this["~validate"](n)}}optional(){return Q.create(this,this._def)}nullable(){return V.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return J.create(this)}promise(){return ot.create(this,this._def)}or(t){return dt.create([this,t],this._def)}and(t){return ct.create(this,t,this._def)}transform(t){return new B({..._(this._def),schema:this,typeName:A.ZodEffects,effect:{type:"transform",transform:t}})}default(t){let n=typeof t==="function"?t:()=>t;return new st({..._(this._def),innerType:this,defaultValue:n,typeName:A.ZodDefault})}brand(){return new gn({typeName:A.ZodBranded,type:this,..._(this._def)})}catch(t){let n=typeof t==="function"?t:()=>t;return new pt({..._(this._def),innerType:this,catchValue:n,typeName:A.ZodCatch})}describe(t){return new this.constructor({...this._def,description:t})}pipe(t){return Zt.create(this,t)}readonly(){return vt.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}function Tr(t){let n="[0-5]\\d";if(t.precision)n=`${n}\\.\\d{${t.precision}}`;else if(t.precision==null)n=`${n}(\\.\\d+)?`;let r=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${n})${r}`}function Al(t){return new RegExp(`^${Tr(t)}$`)}function Zr(t){let n=`${Pr}T${Tr(t)}`,r=[];if(r.push(t.local?"Z?":"Z"),t.offset)r.push("([+-]\\d{2}:?\\d{2})");return n=`${n}(${r.join("|")})`,new RegExp(`^${n}$`)}function _l(t,n){if((n==="v4"||!n)&&sl.test(t))return!0;if((n==="v6"||!n)&&vl.test(t))return!0;return!1}function kl(t,n){if(!cl.test(t))return!1;try{let[r]=t.split(".");if(!r)return!1;let o=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),a=JSON.parse(atob(o));if(typeof a!=="object"||a===null)return!1;if("typ"in a&&a?.typ!=="JWT")return!1;if(!a.alg)return!1;if(n&&a.alg!==n)return!1;return!0}catch{return!1}}function ql(t,n){if((n==="v4"||!n)&&pl.test(t))return!0;if((n==="v6"||!n)&&ul.test(t))return!0;return!1}function El(t,n){let r=(t.toString().split(".")[1]||"").length,o=(n.toString().split(".")[1]||"").length,a=r>o?r:o,e=Number.parseInt(t.toFixed(a).replace(".","")),l=Number.parseInt(n.toFixed(a).replace(".",""));return e%l/10**a}function et(t){if(t instanceof M){let n={};for(let r in t.shape){let o=t.shape[r];n[r]=Q.create(et(o))}return new M({...t._def,shape:()=>n})}else if(t instanceof J)return new J({...t._def,type:et(t.element)});else if(t instanceof Q)return Q.create(et(t.unwrap()));else if(t instanceof V)return V.create(et(t.unwrap()));else if(t instanceof W)return W.create(t.items.map((n)=>et(n)));else return t}function So(t,n){let r=D(t),o=D(n);if(t===n)return{valid:!0,data:t};else if(r===h.object&&o===h.object){let a=q.objectKeys(n),e=q.objectKeys(t).filter((b)=>a.indexOf(b)!==-1),l={...t,...n};for(let b of e){let d=So(t[b],n[b]);if(!d.valid)return{valid:!1};l[b]=d.data}return{valid:!0,data:l}}else if(r===h.array&&o===h.array){if(t.length!==n.length)return{valid:!1};let a=[];for(let e=0;e<t.length;e++){let l=t[e],b=n[e],d=So(l,b);if(!d.valid)return{valid:!1};a.push(d.data)}return{valid:!0,data:a}}else if(r===h.date&&o===h.date&&+t===+n)return{valid:!0,data:t};else return{valid:!1}}function zr(t,n){return new T({values:t,typeName:A.ZodEnum,..._(n)})}function Ir(t,n){let r=typeof t==="function"?t(n):typeof t==="string"?{message:t}:t;return typeof r==="string"?{message:r}:r}function ta(t,n={},r){if(t)return tt.create().superRefine((o,a)=>{let e=t(o);if(e instanceof Promise)return e.then((l)=>{if(!l){let b=Ir(n,o),d=b.fatal??r??!0;a.addIssue({code:"custom",...b,fatal:d})}});if(!e){let l=Ir(n,o),b=l.fatal??r??!0;a.addIssue({code:"custom",...l,fatal:b})}return});return tt.create()}var Cr=(t,n)=>{if(j(n))return{success:!0,data:n.value};else{if(!t.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let r=new Y(t.common.issues);return this._error=r,this._error}}}},ll,bl,il,fl,dl,cl,hl,gl,ml="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",Lo,sl,pl,vl,ul,$l,wl,Pr="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",xl,F,I,P,bt,z,jt,it,ft,tt,C,O,Ct,J,M,dt,y=(t)=>{if(t instanceof ht)return y(t.schema);else if(t instanceof B)return y(t.innerType());else if(t instanceof gt)return[t.value];else if(t instanceof T)return t.options;else if(t instanceof mt)return q.objectValues(t.enum);else if(t instanceof st)return y(t._def.innerType);else if(t instanceof it)return[void 0];else if(t instanceof ft)return[null];else if(t instanceof Q)return[void 0,...y(t.unwrap())];else if(t instanceof V)return[null,...y(t.unwrap())];else if(t instanceof gn)return y(t.unwrap());else if(t instanceof vt)return y(t.unwrap());else if(t instanceof pt)return y(t._def.innerType);else return[]},hn,ct,W,It,Pt,nt,lt,ht,gt,T,mt,ot,B,Q,V,st,pt,Tt,Ml,gn,Zt,vt,Hl,A,Ll=(t,n={message:`Input not instance of ${t.name}`})=>ta((r)=>r instanceof t,n),na,oa,Sl,Rl,ra,Yl,Xl,Fl,Jl,Ql,Gl,Bl,Dl,Ol,Wl,Ul,Nl,yl,Vl,Kl,jl,Cl,Il,Pl,Tl,Zl,zl,tb,nb,ob,rb,ab,eb,lb,bb=()=>na().optional(),ib=()=>oa().optional(),fb=()=>ra().optional(),db,cb;var aa=m(()=>{bn();fn();jr();Ho();Vt();ll=/^c[^\s-]{8,}$/i,bl=/^[0-9a-z]+$/,il=/^[0-9A-HJKMNP-TV-Z]{26}$/i,fl=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,dl=/^[a-z0-9_-]{21}$/i,cl=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,hl=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,gl=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,sl=/^(?:(?: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])$/,pl=/^(?:(?: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])\/(3[0-2]|[12]?[0-9])$/,vl=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,ul=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,$l=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,wl=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,xl=new RegExp(`^${Pr}$`);F=class F extends k{_parse(t){if(this._def.coerce)t.data=String(t.data);if(this._getType(t)!==h.string){let a=this._getOrReturnCtx(t);return s(a,{code:c.invalid_type,expected:h.string,received:a.parsedType}),x}let r=new S,o=void 0;for(let a of this._def.checks)if(a.kind==="min"){if(t.data.length<a.value)o=this._getOrReturnCtx(t,o),s(o,{code:c.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty()}else if(a.kind==="max"){if(t.data.length>a.value)o=this._getOrReturnCtx(t,o),s(o,{code:c.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),r.dirty()}else if(a.kind==="length"){let e=t.data.length>a.value,l=t.data.length<a.value;if(e||l){if(o=this._getOrReturnCtx(t,o),e)s(o,{code:c.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message});else if(l)s(o,{code:c.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message});r.dirty()}}else if(a.kind==="email"){if(!gl.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"email",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="emoji"){if(!Lo)Lo=new RegExp(ml,"u");if(!Lo.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"emoji",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="uuid"){if(!fl.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"uuid",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="nanoid"){if(!dl.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"nanoid",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="cuid"){if(!ll.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"cuid",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="cuid2"){if(!bl.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"cuid2",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="ulid"){if(!il.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"ulid",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="url")try{new URL(t.data)}catch{o=this._getOrReturnCtx(t,o),s(o,{validation:"url",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="regex"){if(a.regex.lastIndex=0,!a.regex.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"regex",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="trim")t.data=t.data.trim();else if(a.kind==="includes"){if(!t.data.includes(a.value,a.position))o=this._getOrReturnCtx(t,o),s(o,{code:c.invalid_string,validation:{includes:a.value,position:a.position},message:a.message}),r.dirty()}else if(a.kind==="toLowerCase")t.data=t.data.toLowerCase();else if(a.kind==="toUpperCase")t.data=t.data.toUpperCase();else if(a.kind==="startsWith"){if(!t.data.startsWith(a.value))o=this._getOrReturnCtx(t,o),s(o,{code:c.invalid_string,validation:{startsWith:a.value},message:a.message}),r.dirty()}else if(a.kind==="endsWith"){if(!t.data.endsWith(a.value))o=this._getOrReturnCtx(t,o),s(o,{code:c.invalid_string,validation:{endsWith:a.value},message:a.message}),r.dirty()}else if(a.kind==="datetime"){if(!Zr(a).test(t.data))o=this._getOrReturnCtx(t,o),s(o,{code:c.invalid_string,validation:"datetime",message:a.message}),r.dirty()}else if(a.kind==="date"){if(!xl.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{code:c.invalid_string,validation:"date",message:a.message}),r.dirty()}else if(a.kind==="time"){if(!Al(a).test(t.data))o=this._getOrReturnCtx(t,o),s(o,{code:c.invalid_string,validation:"time",message:a.message}),r.dirty()}else if(a.kind==="duration"){if(!hl.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"duration",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="ip"){if(!_l(t.data,a.version))o=this._getOrReturnCtx(t,o),s(o,{validation:"ip",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="jwt"){if(!kl(t.data,a.alg))o=this._getOrReturnCtx(t,o),s(o,{validation:"jwt",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="cidr"){if(!ql(t.data,a.version))o=this._getOrReturnCtx(t,o),s(o,{validation:"cidr",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="base64"){if(!$l.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"base64",code:c.invalid_string,message:a.message}),r.dirty()}else if(a.kind==="base64url"){if(!wl.test(t.data))o=this._getOrReturnCtx(t,o),s(o,{validation:"base64url",code:c.invalid_string,message:a.message}),r.dirty()}else q.assertNever(a);return{status:r.value,value:t.data}}_regex(t,n,r){return this.refinement((o)=>t.test(o),{validation:n,code:c.invalid_string,...w.errToObj(r)})}_addCheck(t){return new F({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...w.errToObj(t)})}url(t){return this._addCheck({kind:"url",...w.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...w.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...w.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...w.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...w.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...w.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...w.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...w.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...w.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...w.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...w.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...w.errToObj(t)})}datetime(t){if(typeof t==="string")return this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t});return this._addCheck({kind:"datetime",precision:typeof t?.precision>"u"?null:t?.precision,offset:t?.offset??!1,local:t?.local??!1,...w.errToObj(t?.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){if(typeof t==="string")return this._addCheck({kind:"time",precision:null,message:t});return this._addCheck({kind:"time",precision:typeof t?.precision>"u"?null:t?.precision,...w.errToObj(t?.message)})}duration(t){return this._addCheck({kind:"duration",...w.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...w.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n?.position,...w.errToObj(n?.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...w.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...w.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...w.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...w.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...w.errToObj(n)})}nonempty(t){return this.min(1,w.errToObj(t))}trim(){return new F({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new F({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new F({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((t)=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find((t)=>t.kind==="date")}get isTime(){return!!this._def.checks.find((t)=>t.kind==="time")}get isDuration(){return!!this._def.checks.find((t)=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find((t)=>t.kind==="email")}get isURL(){return!!this._def.checks.find((t)=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find((t)=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find((t)=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find((t)=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find((t)=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find((t)=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find((t)=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find((t)=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find((t)=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find((t)=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find((t)=>t.kind==="base64url")}get minLength(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t}get maxLength(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t}};F.create=(t)=>{return new F({checks:[],typeName:A.ZodString,coerce:t?.coerce??!1,..._(t)})};I=class I extends k{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce)t.data=Number(t.data);if(this._getType(t)!==h.number){let a=this._getOrReturnCtx(t);return s(a,{code:c.invalid_type,expected:h.number,received:a.parsedType}),x}let r=void 0,o=new S;for(let a of this._def.checks)if(a.kind==="int"){if(!q.isInteger(t.data))r=this._getOrReturnCtx(t,r),s(r,{code:c.invalid_type,expected:"integer",received:"float",message:a.message}),o.dirty()}else if(a.kind==="min"){if(a.inclusive?t.data<a.value:t.data<=a.value)r=this._getOrReturnCtx(t,r),s(r,{code:c.too_small,minimum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),o.dirty()}else if(a.kind==="max"){if(a.inclusive?t.data>a.value:t.data>=a.value)r=this._getOrReturnCtx(t,r),s(r,{code:c.too_big,maximum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),o.dirty()}else if(a.kind==="multipleOf"){if(El(t.data,a.value)!==0)r=this._getOrReturnCtx(t,r),s(r,{code:c.not_multiple_of,multipleOf:a.value,message:a.message}),o.dirty()}else if(a.kind==="finite"){if(!Number.isFinite(t.data))r=this._getOrReturnCtx(t,r),s(r,{code:c.not_finite,message:a.message}),o.dirty()}else q.assertNever(a);return{status:o.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,w.toString(n))}gt(t,n){return this.setLimit("min",t,!1,w.toString(n))}lte(t,n){return this.setLimit("max",t,!0,w.toString(n))}lt(t,n){return this.setLimit("max",t,!1,w.toString(n))}setLimit(t,n,r,o){return new I({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:w.toString(o)}]})}_addCheck(t){return new I({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:w.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:w.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:w.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:w.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:w.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:w.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:w.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:w.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:w.toString(t)})}get minValue(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t}get maxValue(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t}get isInt(){return!!this._def.checks.find((t)=>t.kind==="int"||t.kind==="multipleOf"&&q.isInteger(t.value))}get isFinite(){let t=null,n=null;for(let r of this._def.checks)if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;else if(r.kind==="min"){if(n===null||r.value>n)n=r.value}else if(r.kind==="max"){if(t===null||r.value<t)t=r.value}return Number.isFinite(n)&&Number.isFinite(t)}};I.create=(t)=>{return new I({checks:[],typeName:A.ZodNumber,coerce:t?.coerce||!1,..._(t)})};P=class P extends k{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==h.bigint)return this._getInvalidInput(t);let r=void 0,o=new S;for(let a of this._def.checks)if(a.kind==="min"){if(a.inclusive?t.data<a.value:t.data<=a.value)r=this._getOrReturnCtx(t,r),s(r,{code:c.too_small,type:"bigint",minimum:a.value,inclusive:a.inclusive,message:a.message}),o.dirty()}else if(a.kind==="max"){if(a.inclusive?t.data>a.value:t.data>=a.value)r=this._getOrReturnCtx(t,r),s(r,{code:c.too_big,type:"bigint",maximum:a.value,inclusive:a.inclusive,message:a.message}),o.dirty()}else if(a.kind==="multipleOf"){if(t.data%a.value!==BigInt(0))r=this._getOrReturnCtx(t,r),s(r,{code:c.not_multiple_of,multipleOf:a.value,message:a.message}),o.dirty()}else q.assertNever(a);return{status:o.value,value:t.data}}_getInvalidInput(t){let n=this._getOrReturnCtx(t);return s(n,{code:c.invalid_type,expected:h.bigint,received:n.parsedType}),x}gte(t,n){return this.setLimit("min",t,!0,w.toString(n))}gt(t,n){return this.setLimit("min",t,!1,w.toString(n))}lte(t,n){return this.setLimit("max",t,!0,w.toString(n))}lt(t,n){return this.setLimit("max",t,!1,w.toString(n))}setLimit(t,n,r,o){return new P({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:w.toString(o)}]})}_addCheck(t){return new P({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:w.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:w.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:w.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:w.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:w.toString(n)})}get minValue(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t}get maxValue(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t}};P.create=(t)=>{return new P({checks:[],typeName:A.ZodBigInt,coerce:t?.coerce??!1,..._(t)})};bt=class bt extends k{_parse(t){if(this._def.coerce)t.data=Boolean(t.data);if(this._getType(t)!==h.boolean){let r=this._getOrReturnCtx(t);return s(r,{code:c.invalid_type,expected:h.boolean,received:r.parsedType}),x}return R(t.data)}};bt.create=(t)=>{return new bt({typeName:A.ZodBoolean,coerce:t?.coerce||!1,..._(t)})};z=class z extends k{_parse(t){if(this._def.coerce)t.data=new Date(t.data);if(this._getType(t)!==h.date){let a=this._getOrReturnCtx(t);return s(a,{code:c.invalid_type,expected:h.date,received:a.parsedType}),x}if(Number.isNaN(t.data.getTime())){let a=this._getOrReturnCtx(t);return s(a,{code:c.invalid_date}),x}let r=new S,o=void 0;for(let a of this._def.checks)if(a.kind==="min"){if(t.data.getTime()<a.value)o=this._getOrReturnCtx(t,o),s(o,{code:c.too_small,message:a.message,inclusive:!0,exact:!1,minimum:a.value,type:"date"}),r.dirty()}else if(a.kind==="max"){if(t.data.getTime()>a.value)o=this._getOrReturnCtx(t,o),s(o,{code:c.too_big,message:a.message,inclusive:!0,exact:!1,maximum:a.value,type:"date"}),r.dirty()}else q.assertNever(a);return{status:r.value,value:new Date(t.data.getTime())}}_addCheck(t){return new z({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:w.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:w.toString(n)})}get minDate(){let t=null;for(let n of this._def.checks)if(n.kind==="min"){if(t===null||n.value>t)t=n.value}return t!=null?new Date(t):null}get maxDate(){let t=null;for(let n of this._def.checks)if(n.kind==="max"){if(t===null||n.value<t)t=n.value}return t!=null?new Date(t):null}};z.create=(t)=>{return new z({checks:[],coerce:t?.coerce||!1,typeName:A.ZodDate,..._(t)})};jt=class jt extends k{_parse(t){if(this._getType(t)!==h.symbol){let r=this._getOrReturnCtx(t);return s(r,{code:c.invalid_type,expected:h.symbol,received:r.parsedType}),x}return R(t.data)}};jt.create=(t)=>{return new jt({typeName:A.ZodSymbol,..._(t)})};it=class it extends k{_parse(t){if(this._getType(t)!==h.undefined){let r=this._getOrReturnCtx(t);return s(r,{code:c.invalid_type,expected:h.undefined,received:r.parsedType}),x}return R(t.data)}};it.create=(t)=>{return new it({typeName:A.ZodUndefined,..._(t)})};ft=class ft extends k{_parse(t){if(this._getType(t)!==h.null){let r=this._getOrReturnCtx(t);return s(r,{code:c.invalid_type,expected:h.null,received:r.parsedType}),x}return R(t.data)}};ft.create=(t)=>{return new ft({typeName:A.ZodNull,..._(t)})};tt=class tt extends k{constructor(){super(...arguments);this._any=!0}_parse(t){return R(t.data)}};tt.create=(t)=>{return new tt({typeName:A.ZodAny,..._(t)})};C=class C extends k{constructor(){super(...arguments);this._unknown=!0}_parse(t){return R(t.data)}};C.create=(t)=>{return new C({typeName:A.ZodUnknown,..._(t)})};O=class O extends k{_parse(t){let n=this._getOrReturnCtx(t);return s(n,{code:c.invalid_type,expected:h.never,received:n.parsedType}),x}};O.create=(t)=>{return new O({typeName:A.ZodNever,..._(t)})};Ct=class Ct extends k{_parse(t){if(this._getType(t)!==h.undefined){let r=this._getOrReturnCtx(t);return s(r,{code:c.invalid_type,expected:h.void,received:r.parsedType}),x}return R(t.data)}};Ct.create=(t)=>{return new Ct({typeName:A.ZodVoid,..._(t)})};J=class J extends k{_parse(t){let{ctx:n,status:r}=this._processInputParams(t),o=this._def;if(n.parsedType!==h.array)return s(n,{code:c.invalid_type,expected:h.array,received:n.parsedType}),x;if(o.exactLength!==null){let e=n.data.length>o.exactLength.value,l=n.data.length<o.exactLength.value;if(e||l)s(n,{code:e?c.too_big:c.too_small,minimum:l?o.exactLength.value:void 0,maximum:e?o.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:o.exactLength.message}),r.dirty()}if(o.minLength!==null){if(n.data.length<o.minLength.value)s(n,{code:c.too_small,minimum:o.minLength.value,type:"array",inclusive:!0,exact:!1,message:o.minLength.message}),r.dirty()}if(o.maxLength!==null){if(n.data.length>o.maxLength.value)s(n,{code:c.too_big,maximum:o.maxLength.value,type:"array",inclusive:!0,exact:!1,message:o.maxLength.message}),r.dirty()}if(n.common.async)return Promise.all([...n.data].map((e,l)=>{return o.type._parseAsync(new G(n,e,n.path,l))})).then((e)=>{return S.mergeArray(r,e)});let a=[...n.data].map((e,l)=>{return o.type._parseSync(new G(n,e,n.path,l))});return S.mergeArray(r,a)}get element(){return this._def.type}min(t,n){return new J({...this._def,minLength:{value:t,message:w.toString(n)}})}max(t,n){return new J({...this._def,maxLength:{value:t,message:w.toString(n)}})}length(t,n){return new J({...this._def,exactLength:{value:t,message:w.toString(n)}})}nonempty(t){return this.min(1,t)}};J.create=(t,n)=>{return new J({type:t,minLength:null,maxLength:null,exactLength:null,typeName:A.ZodArray,..._(n)})};M=class M extends k{constructor(){super(...arguments);this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let t=this._def.shape(),n=q.objectKeys(t);return this._cached={shape:t,keys:n},this._cached}_parse(t){if(this._getType(t)!==h.object){let d=this._getOrReturnCtx(t);return s(d,{code:c.invalid_type,expected:h.object,received:d.parsedType}),x}let{status:r,ctx:o}=this._processInputParams(t),{shape:a,keys:e}=this._getCached(),l=[];if(!(this._def.catchall instanceof O&&this._def.unknownKeys==="strip")){for(let d in o.data)if(!e.includes(d))l.push(d)}let b=[];for(let d of e){let $=a[d],E=o.data[d];b.push({key:{status:"valid",value:d},value:$._parse(new G(o,E,o.path,d)),alwaysSet:d in o.data})}if(this._def.catchall instanceof O){let d=this._def.unknownKeys;if(d==="passthrough")for(let $ of l)b.push({key:{status:"valid",value:$},value:{status:"valid",value:o.data[$]}});else if(d==="strict"){if(l.length>0)s(o,{code:c.unrecognized_keys,keys:l}),r.dirty()}else if(d==="strip");else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let d=this._def.catchall;for(let $ of l){let E=o.data[$];b.push({key:{status:"valid",value:$},value:d._parse(new G(o,E,o.path,$)),alwaysSet:$ in o.data})}}if(o.common.async)return Promise.resolve().then(async()=>{let d=[];for(let $ of b){let E=await $.key,L=await $.value;d.push({key:E,value:L,alwaysSet:$.alwaysSet})}return d}).then((d)=>{return S.mergeObjectSync(r,d)});else return S.mergeObjectSync(r,b)}get shape(){return this._def.shape()}strict(t){return w.errToObj,new M({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,r)=>{let o=this._def.errorMap?.(n,r).message??r.defaultError;if(n.code==="unrecognized_keys")return{message:w.errToObj(t).message??o};return{message:o}}}:{}})}strip(){return new M({...this._def,unknownKeys:"strip"})}passthrough(){return new M({...this._def,unknownKeys:"passthrough"})}extend(t){return new M({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new M({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:A.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new M({...this._def,catchall:t})}pick(t){let n={};for(let r of q.objectKeys(t))if(t[r]&&this.shape[r])n[r]=this.shape[r];return new M({...this._def,shape:()=>n})}omit(t){let n={};for(let r of q.objectKeys(this.shape))if(!t[r])n[r]=this.shape[r];return new M({...this._def,shape:()=>n})}deepPartial(){return et(this)}partial(t){let n={};for(let r of q.objectKeys(this.shape)){let o=this.shape[r];if(t&&!t[r])n[r]=o;else n[r]=o.optional()}return new M({...this._def,shape:()=>n})}required(t){let n={};for(let r of q.objectKeys(this.shape))if(t&&!t[r])n[r]=this.shape[r];else{let a=this.shape[r];while(a instanceof Q)a=a._def.innerType;n[r]=a}return new M({...this._def,shape:()=>n})}keyof(){return zr(q.objectKeys(this.shape))}};M.create=(t,n)=>{return new M({shape:()=>t,unknownKeys:"strip",catchall:O.create(),typeName:A.ZodObject,..._(n)})};M.strictCreate=(t,n)=>{return new M({shape:()=>t,unknownKeys:"strict",catchall:O.create(),typeName:A.ZodObject,..._(n)})};M.lazycreate=(t,n)=>{return new M({shape:t,unknownKeys:"strip",catchall:O.create(),typeName:A.ZodObject,..._(n)})};dt=class dt extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r=this._def.options;function o(a){for(let l of a)if(l.result.status==="valid")return l.result;for(let l of a)if(l.result.status==="dirty")return n.common.issues.push(...l.ctx.common.issues),l.result;let e=a.map((l)=>new Y(l.ctx.common.issues));return s(n,{code:c.invalid_union,unionErrors:e}),x}if(n.common.async)return Promise.all(r.map(async(a)=>{let e={...n,common:{...n.common,issues:[]},parent:null};return{result:await a._parseAsync({data:n.data,path:n.path,parent:e}),ctx:e}})).then(o);else{let a=void 0,e=[];for(let b of r){let d={...n,common:{...n.common,issues:[]},parent:null},$=b._parseSync({data:n.data,path:n.path,parent:d});if($.status==="valid")return $;else if($.status==="dirty"&&!a)a={result:$,ctx:d};if(d.common.issues.length)e.push(d.common.issues)}if(a)return n.common.issues.push(...a.ctx.common.issues),a.result;let l=e.map((b)=>new Y(b));return s(n,{code:c.invalid_union,unionErrors:l}),x}}get options(){return this._def.options}};dt.create=(t,n)=>{return new dt({options:t,typeName:A.ZodUnion,..._(n)})};hn=class hn extends k{_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==h.object)return s(n,{code:c.invalid_type,expected:h.object,received:n.parsedType}),x;let r=this.discriminator,o=n.data[r],a=this.optionsMap.get(o);if(!a)return s(n,{code:c.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),x;if(n.common.async)return a._parseAsync({data:n.data,path:n.path,parent:n});else return a._parseSync({data:n.data,path:n.path,parent:n})}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,n,r){let o=new Map;for(let a of n){let e=y(a.shape[t]);if(!e.length)throw Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(let l of e){if(o.has(l))throw Error(`Discriminator property ${String(t)} has duplicate value ${String(l)}`);o.set(l,a)}}return new hn({typeName:A.ZodDiscriminatedUnion,discriminator:t,options:n,optionsMap:o,..._(r)})}};ct=class ct extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t),o=(a,e)=>{if(dn(a)||dn(e))return x;let l=So(a.value,e.value);if(!l.valid)return s(r,{code:c.invalid_intersection_types}),x;if(cn(a)||cn(e))n.dirty();return{status:n.value,value:l.data}};if(r.common.async)return Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([a,e])=>o(a,e));else return o(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}};ct.create=(t,n,r)=>{return new ct({left:t,right:n,typeName:A.ZodIntersection,..._(r)})};W=class W extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.array)return s(r,{code:c.invalid_type,expected:h.array,received:r.parsedType}),x;if(r.data.length<this._def.items.length)return s(r,{code:c.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),x;if(!this._def.rest&&r.data.length>this._def.items.length)s(r,{code:c.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty();let a=[...r.data].map((e,l)=>{let b=this._def.items[l]||this._def.rest;if(!b)return null;return b._parse(new G(r,e,r.path,l))}).filter((e)=>!!e);if(r.common.async)return Promise.all(a).then((e)=>{return S.mergeArray(n,e)});else return S.mergeArray(n,a)}get items(){return this._def.items}rest(t){return new W({...this._def,rest:t})}};W.create=(t,n)=>{if(!Array.isArray(t))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new W({items:t,typeName:A.ZodTuple,rest:null,..._(n)})};It=class It extends k{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.object)return s(r,{code:c.invalid_type,expected:h.object,received:r.parsedType}),x;let o=[],a=this._def.keyType,e=this._def.valueType;for(let l in r.data)o.push({key:a._parse(new G(r,l,r.path,l)),value:e._parse(new G(r,r.data[l],r.path,l)),alwaysSet:l in r.data});if(r.common.async)return S.mergeObjectAsync(n,o);else return S.mergeObjectSync(n,o)}get element(){return this._def.valueType}static create(t,n,r){if(n instanceof k)return new It({keyType:t,valueType:n,typeName:A.ZodRecord,..._(r)});return new It({keyType:F.create(),valueType:t,typeName:A.ZodRecord,..._(n)})}};Pt=class Pt extends k{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.map)return s(r,{code:c.invalid_type,expected:h.map,received:r.parsedType}),x;let o=this._def.keyType,a=this._def.valueType,e=[...r.data.entries()].map(([l,b],d)=>{return{key:o._parse(new G(r,l,r.path,[d,"key"])),value:a._parse(new G(r,b,r.path,[d,"value"]))}});if(r.common.async){let l=new Map;return Promise.resolve().then(async()=>{for(let b of e){let d=await b.key,$=await b.value;if(d.status==="aborted"||$.status==="aborted")return x;if(d.status==="dirty"||$.status==="dirty")n.dirty();l.set(d.value,$.value)}return{status:n.value,value:l}})}else{let l=new Map;for(let b of e){let{key:d,value:$}=b;if(d.status==="aborted"||$.status==="aborted")return x;if(d.status==="dirty"||$.status==="dirty")n.dirty();l.set(d.value,$.value)}return{status:n.value,value:l}}}};Pt.create=(t,n,r)=>{return new Pt({valueType:n,keyType:t,typeName:A.ZodMap,..._(r)})};nt=class nt extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==h.set)return s(r,{code:c.invalid_type,expected:h.set,received:r.parsedType}),x;let o=this._def;if(o.minSize!==null){if(r.data.size<o.minSize.value)s(r,{code:c.too_small,minimum:o.minSize.value,type:"set",inclusive:!0,exact:!1,message:o.minSize.message}),n.dirty()}if(o.maxSize!==null){if(r.data.size>o.maxSize.value)s(r,{code:c.too_big,maximum:o.maxSize.value,type:"set",inclusive:!0,exact:!1,message:o.maxSize.message}),n.dirty()}let a=this._def.valueType;function e(b){let d=new Set;for(let $ of b){if($.status==="aborted")return x;if($.status==="dirty")n.dirty();d.add($.value)}return{status:n.value,value:d}}let l=[...r.data.values()].map((b,d)=>a._parse(new G(r,b,r.path,d)));if(r.common.async)return Promise.all(l).then((b)=>e(b));else return e(l)}min(t,n){return new nt({...this._def,minSize:{value:t,message:w.toString(n)}})}max(t,n){return new nt({...this._def,maxSize:{value:t,message:w.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}};nt.create=(t,n)=>{return new nt({valueType:t,minSize:null,maxSize:null,typeName:A.ZodSet,..._(n)})};lt=class lt extends k{constructor(){super(...arguments);this.validate=this.implement}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==h.function)return s(n,{code:c.invalid_type,expected:h.function,received:n.parsedType}),x;function r(l,b){return Kt({data:l,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,rt(),N].filter((d)=>!!d),issueData:{code:c.invalid_arguments,argumentsError:b}})}function o(l,b){return Kt({data:l,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,rt(),N].filter((d)=>!!d),issueData:{code:c.invalid_return_type,returnTypeError:b}})}let a={errorMap:n.common.contextualErrorMap},e=n.data;if(this._def.returns instanceof ot){let l=this;return R(async function(...b){let d=new Y([]),$=await l._def.args.parseAsync(b,a).catch((H)=>{throw d.addIssue(r(b,H)),d}),E=await Reflect.apply(e,this,$);return await l._def.returns._def.type.parseAsync(E,a).catch((H)=>{throw d.addIssue(o(E,H)),d})})}else{let l=this;return R(function(...b){let d=l._def.args.safeParse(b,a);if(!d.success)throw new Y([r(b,d.error)]);let $=Reflect.apply(e,this,d.data),E=l._def.returns.safeParse($,a);if(!E.success)throw new Y([o($,E.error)]);return E.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new lt({...this._def,args:W.create(t).rest(C.create())})}returns(t){return new lt({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,n,r){return new lt({args:t?t:W.create([]).rest(C.create()),returns:n||C.create(),typeName:A.ZodFunction,..._(r)})}};ht=class ht extends k{get schema(){return this._def.getter()}_parse(t){let{ctx:n}=this._processInputParams(t);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};ht.create=(t,n)=>{return new ht({getter:t,typeName:A.ZodLazy,..._(n)})};gt=class gt extends k{_parse(t){if(t.data!==this._def.value){let n=this._getOrReturnCtx(t);return s(n,{received:n.data,code:c.invalid_literal,expected:this._def.value}),x}return{status:"valid",value:t.data}}get value(){return this._def.value}};gt.create=(t,n)=>{return new gt({value:t,typeName:A.ZodLiteral,..._(n)})};T=class T extends k{_parse(t){if(typeof t.data!=="string"){let n=this._getOrReturnCtx(t),r=this._def.values;return s(n,{expected:q.joinValues(r),received:n.parsedType,code:c.invalid_type}),x}if(!this._cache)this._cache=new Set(this._def.values);if(!this._cache.has(t.data)){let n=this._getOrReturnCtx(t),r=this._def.values;return s(n,{received:n.data,code:c.invalid_enum_value,options:r}),x}return R(t.data)}get options(){return this._def.values}get enum(){let t={};for(let n of this._def.values)t[n]=n;return t}get Values(){let t={};for(let n of this._def.values)t[n]=n;return t}get Enum(){let t={};for(let n of this._def.values)t[n]=n;return t}extract(t,n=this._def){return T.create(t,{...this._def,...n})}exclude(t,n=this._def){return T.create(this.options.filter((r)=>!t.includes(r)),{...this._def,...n})}};T.create=zr;mt=class mt extends k{_parse(t){let n=q.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(t);if(r.parsedType!==h.string&&r.parsedType!==h.number){let o=q.objectValues(n);return s(r,{expected:q.joinValues(o),received:r.parsedType,code:c.invalid_type}),x}if(!this._cache)this._cache=new Set(q.getValidEnumValues(this._def.values));if(!this._cache.has(t.data)){let o=q.objectValues(n);return s(r,{received:r.data,code:c.invalid_enum_value,options:o}),x}return R(t.data)}get enum(){return this._def.values}};mt.create=(t,n)=>{return new mt({values:t,typeName:A.ZodNativeEnum,..._(n)})};ot=class ot extends k{unwrap(){return this._def.type}_parse(t){let{ctx:n}=this._processInputParams(t);if(n.parsedType!==h.promise&&n.common.async===!1)return s(n,{code:c.invalid_type,expected:h.promise,received:n.parsedType}),x;let r=n.parsedType===h.promise?n.data:Promise.resolve(n.data);return R(r.then((o)=>{return this._def.type.parseAsync(o,{path:n.path,errorMap:n.common.contextualErrorMap})}))}};ot.create=(t,n)=>{return new ot({type:t,typeName:A.ZodPromise,..._(n)})};B=class B extends k{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===A.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){let{status:n,ctx:r}=this._processInputParams(t),o=this._def.effect||null,a={addIssue:(e)=>{if(s(r,e),e.fatal)n.abort();else n.dirty()},get path(){return r.path}};if(a.addIssue=a.addIssue.bind(a),o.type==="preprocess"){let e=o.transform(r.data,a);if(r.common.async)return Promise.resolve(e).then(async(l)=>{if(n.value==="aborted")return x;let b=await this._def.schema._parseAsync({data:l,path:r.path,parent:r});if(b.status==="aborted")return x;if(b.status==="dirty")return Z(b.value);if(n.value==="dirty")return Z(b.value);return b});else{if(n.value==="aborted")return x;let l=this._def.schema._parseSync({data:e,path:r.path,parent:r});if(l.status==="aborted")return x;if(l.status==="dirty")return Z(l.value);if(n.value==="dirty")return Z(l.value);return l}}if(o.type==="refinement"){let e=(l)=>{let b=o.refinement(l,a);if(r.common.async)return Promise.resolve(b);if(b instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return l};if(r.common.async===!1){let l=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(l.status==="aborted")return x;if(l.status==="dirty")n.dirty();return e(l.value),{status:n.value,value:l.value}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((l)=>{if(l.status==="aborted")return x;if(l.status==="dirty")n.dirty();return e(l.value).then(()=>{return{status:n.value,value:l.value}})})}if(o.type==="transform")if(r.common.async===!1){let e=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!j(e))return x;let l=o.transform(e.value,a);if(l instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:l}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((e)=>{if(!j(e))return x;return Promise.resolve(o.transform(e.value,a)).then((l)=>({status:n.value,value:l}))});q.assertNever(o)}};B.create=(t,n,r)=>{return new B({schema:t,typeName:A.ZodEffects,effect:n,..._(r)})};B.createWithPreprocess=(t,n,r)=>{return new B({schema:n,effect:{type:"preprocess",transform:t},typeName:A.ZodEffects,..._(r)})};Q=class Q extends k{_parse(t){if(this._getType(t)===h.undefined)return R(void 0);return this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};Q.create=(t,n)=>{return new Q({innerType:t,typeName:A.ZodOptional,..._(n)})};V=class V extends k{_parse(t){if(this._getType(t)===h.null)return R(null);return this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};V.create=(t,n)=>{return new V({innerType:t,typeName:A.ZodNullable,..._(n)})};st=class st extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r=n.data;if(n.parsedType===h.undefined)r=this._def.defaultValue();return this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};st.create=(t,n)=>{return new st({innerType:t,typeName:A.ZodDefault,defaultValue:typeof n.default==="function"?n.default:()=>n.default,..._(n)})};pt=class pt extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r={...n,common:{...n.common,issues:[]}},o=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});if(at(o))return o.then((a)=>{return{status:"valid",value:a.status==="valid"?a.value:this._def.catchValue({get error(){return new Y(r.common.issues)},input:r.data})}});else return{status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new Y(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}};pt.create=(t,n)=>{return new pt({innerType:t,typeName:A.ZodCatch,catchValue:typeof n.catch==="function"?n.catch:()=>n.catch,..._(n)})};Tt=class Tt extends k{_parse(t){if(this._getType(t)!==h.nan){let r=this._getOrReturnCtx(t);return s(r,{code:c.invalid_type,expected:h.nan,received:r.parsedType}),x}return{status:"valid",value:t.data}}};Tt.create=(t)=>{return new Tt({typeName:A.ZodNaN,..._(t)})};Ml=Symbol("zod_brand");gn=class gn extends k{_parse(t){let{ctx:n}=this._processInputParams(t),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}};Zt=class Zt extends k{_parse(t){let{status:n,ctx:r}=this._processInputParams(t);if(r.common.async)return(async()=>{let a=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});if(a.status==="aborted")return x;if(a.status==="dirty")return n.dirty(),Z(a.value);else return this._def.out._parseAsync({data:a.value,path:r.path,parent:r})})();else{let o=this._def.in._parseSync({data:r.data,path:r.path,parent:r});if(o.status==="aborted")return x;if(o.status==="dirty")return n.dirty(),{status:"dirty",value:o.value};else return this._def.out._parseSync({data:o.value,path:r.path,parent:r})}}static create(t,n){return new Zt({in:t,out:n,typeName:A.ZodPipeline})}};vt=class vt extends k{_parse(t){let n=this._def.innerType._parse(t),r=(o)=>{if(j(o))o.value=Object.freeze(o.value);return o};return at(n)?n.then((o)=>r(o)):r(n)}unwrap(){return this._def.innerType}};vt.create=(t,n)=>{return new vt({innerType:t,typeName:A.ZodReadonly,..._(n)})};Hl={object:M.lazycreate};(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(A||(A={}));na=F.create,oa=I.create,Sl=Tt.create,Rl=P.create,ra=bt.create,Yl=z.create,Xl=jt.create,Fl=it.create,Jl=ft.create,Ql=tt.create,Gl=C.create,Bl=O.create,Dl=Ct.create,Ol=J.create,Wl=M.create,Ul=M.strictCreate,Nl=dt.create,yl=hn.create,Vl=ct.create,Kl=W.create,jl=It.create,Cl=Pt.create,Il=nt.create,Pl=lt.create,Tl=ht.create,Zl=gt.create,zl=T.create,tb=mt.create,nb=ot.create,ob=B.create,rb=Q.create,ab=V.create,eb=B.createWithPreprocess,lb=Zt.create,db={string:(t)=>F.create({...t,coerce:!0}),number:(t)=>I.create({...t,coerce:!0}),boolean:(t)=>bt.create({...t,coerce:!0}),bigint:(t)=>P.create({...t,coerce:!0}),date:(t)=>z.create({...t,coerce:!0})},cb=x});var p={};u(p,{void:()=>Dl,util:()=>q,unknown:()=>Gl,union:()=>Nl,undefined:()=>Fl,tuple:()=>Kl,transformer:()=>ob,symbol:()=>Xl,string:()=>na,strictObject:()=>Ul,setErrorMap:()=>al,set:()=>Il,record:()=>jl,quotelessJson:()=>ol,promise:()=>nb,preprocess:()=>eb,pipeline:()=>lb,ostring:()=>bb,optional:()=>rb,onumber:()=>ib,oboolean:()=>fb,objectUtil:()=>Eo,object:()=>Wl,number:()=>oa,nullable:()=>ab,null:()=>Jl,never:()=>Bl,nativeEnum:()=>tb,nan:()=>Sl,map:()=>Cl,makeIssue:()=>Kt,literal:()=>Zl,lazy:()=>Tl,late:()=>Hl,isValid:()=>j,isDirty:()=>cn,isAsync:()=>at,isAborted:()=>dn,intersection:()=>Vl,instanceof:()=>Ll,getParsedType:()=>D,getErrorMap:()=>rt,function:()=>Pl,enum:()=>zl,effect:()=>ob,discriminatedUnion:()=>yl,defaultErrorMap:()=>N,datetimeRegex:()=>Zr,date:()=>Yl,custom:()=>ta,coerce:()=>db,boolean:()=>ra,bigint:()=>Rl,array:()=>Ol,any:()=>Ql,addIssueToContext:()=>s,ZodVoid:()=>Ct,ZodUnknown:()=>C,ZodUnion:()=>dt,ZodUndefined:()=>it,ZodType:()=>k,ZodTuple:()=>W,ZodTransformer:()=>B,ZodSymbol:()=>jt,ZodString:()=>F,ZodSet:()=>nt,ZodSchema:()=>k,ZodRecord:()=>It,ZodReadonly:()=>vt,ZodPromise:()=>ot,ZodPipeline:()=>Zt,ZodParsedType:()=>h,ZodOptional:()=>Q,ZodObject:()=>M,ZodNumber:()=>I,ZodNullable:()=>V,ZodNull:()=>ft,ZodNever:()=>O,ZodNativeEnum:()=>mt,ZodNaN:()=>Tt,ZodMap:()=>Pt,ZodLiteral:()=>gt,ZodLazy:()=>ht,ZodIssueCode:()=>c,ZodIntersection:()=>ct,ZodFunction:()=>lt,ZodFirstPartyTypeKind:()=>A,ZodError:()=>Y,ZodEnum:()=>T,ZodEffects:()=>B,ZodDiscriminatedUnion:()=>hn,ZodDefault:()=>st,ZodDate:()=>z,ZodCatch:()=>pt,ZodBranded:()=>gn,ZodBoolean:()=>bt,ZodBigInt:()=>P,ZodArray:()=>J,ZodAny:()=>tt,Schema:()=>k,ParseStatus:()=>S,OK:()=>R,NEVER:()=>cb,INVALID:()=>x,EMPTY_PATH:()=>el,DIRTY:()=>Z,BRAND:()=>Ml});var Ro=m(()=>{fn();Ho();Kr();Vt();aa();bn()});var ea=m(()=>{Ro();Ro()});function Yo(t){if(t===null||typeof t!=="object")return t;if(Array.isArray(t))return t.map(Yo);let n={};for(let r of Object.keys(t))n[r]=Yo(t[r]);return n}var hb,uf;var la=m(()=>{hb={validation:{trimStrings:!1,emptyAsNullDefault:!1},security:{csrf:{enabled:!0,excludePaths:[],sameSite:"Strict",secure:!1},rateLimit:{enabled:!0,windowMs:60000,maxRequests:60,excludePaths:[]}},hooks:{onValidationError:null,onSecurityViolation:null,onRateLimit:null,onDatabaseError:null,onRequest:null}},uf=Yo(hb)});class zt{static validate(t,n){try{return{success:!0,data:t.parse(n)}}catch(r){if(r instanceof p.ZodError){let o={};return r.errors.forEach((a)=>{let e=a.path.join(".");o[e]=a.message}),{success:!1,errors:o}}return{success:!1,errors:{general:"Validation failed"}}}}static validateField(t,n){try{return t.parse(n),{success:!0}}catch(r){if(r instanceof p.ZodError)return{success:!1,error:r.errors[0]?.message||"Invalid value"};return{success:!1,error:"Validation failed"}}}static getFieldError(t,n){if(t.success)return null;return t.errors?.[n]||null}static hasFieldError(t,n){return!!this.getFieldError(t,n)}}var ba,K;var Xo=m(()=>{ea();la();ba={login:p.object({email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters").regex(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)/,"Password must contain at least one uppercase letter, one lowercase letter, and one number")}),register:p.object({name:p.string().min(2,"Name must be at least 2 characters").max(50,"Name must be less than 50 characters").regex(/^[a-zA-Z\s'-]+$/,"Name can only contain letters, spaces, hyphens, and apostrophes"),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters").regex(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&])/,"Password must contain uppercase, lowercase, number, and special character"),confirmPassword:p.string()}).refine((t)=>t.password===t.confirmPassword,{message:"Passwords don't match",path:["confirmPassword"]}),auth:{register:p.object({action:p.literal("register"),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),username:p.string().min(3,"Username must be at least 3 characters").max(30,"Username must be less than 30 characters"),password:p.string().min(8,"Password must be at least 8 characters"),full_name:p.string().min(2,"Full name is required").max(100,"Full name is too long")}),login:p.object({action:p.literal("login"),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters")}),logout:p.object({action:p.literal("logout")}),action:p.discriminatedUnion("action",[p.object({action:p.literal("register")}).merge(p.object({email:p.string().min(1,"Email is required").email("Please enter a valid email address"),username:p.string().min(3,"Username must be at least 3 characters").max(30,"Username must be less than 30 characters"),password:p.string().min(8,"Password must be at least 8 characters"),full_name:p.string().min(2,"Full name is required").max(100,"Full name is too long")})),p.object({action:p.literal("login")}).merge(p.object({email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters")})),p.object({action:p.literal("logout")})])},contact:p.object({name:p.string().min(2,"Name must be at least 2 characters").max(100,"Name is too long"),email:p.string().email("Please enter a valid email address"),message:p.string().min(10,"Message must be at least 10 characters").max(1000,"Message is too long")}),email:p.string().min(1,"Email is required").email("Please enter a valid email address"),password:p.string().min(8,"Password must be at least 8 characters").regex(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)/,"Password must contain uppercase, lowercase, and number"),phone:p.string().regex(/^[+]?[1-9][\d]{0,15}$/,"Please enter a valid phone number"),url:p.string().min(1,"URL is required").url("Please enter a valid URL"),required:p.string().min(1,"This field is required"),positiveNumber:p.number().positive("Must be a positive number"),integer:p.number().int("Must be a whole number"),futureDate:p.date().min(new Date,"Date must be in the future"),imageFile:p.instanceof(File).refine((t)=>t.size<=5242880,"File size must be less than 5MB").refine((t)=>["image/jpeg","image/png","image/gif","image/webp"].includes(t.type),"File must be a JPEG, PNG, GIF, or WebP image"),userProfile:p.object({full_name:p.string().min(2,"Full name must be at least 2 characters").max(100,"Full name is too long").optional(),bio:p.string().max(500,"Bio must be less than 500 characters").nullable().optional(),avatar_url:p.string().url("Please enter a valid URL").nullable().optional(),theme:p.enum(["africanity","dark","light","system"]).optional(),language:p.string().min(2).max(10).optional()}),project:p.object({name:p.string().min(1,"Project name is required").max(100,"Project name is too long"),description:p.string().max(1000,"Description is too long").nullable().optional(),repository_url:p.string().url("Please enter a valid repository URL").nullable().optional(),demo_url:p.string().url("Please enter a valid demo URL").nullable().optional(),tags:p.array(p.string()).optional(),is_public:p.boolean().optional()})};K={required:(t="This field is required")=>p.string().min(1,t),email:(t="Please enter a valid email address")=>p.string().email(t),minLength:(t,n)=>p.string().min(t,n||`Must be at least ${t} characters`),maxLength:(t,n)=>p.string().max(t,n||`Must be less than ${t} characters`),pattern:(t,n)=>p.string().regex(t,n),numeric:(t="Must be a number")=>p.string().regex(/^\d+$/,t),phone:(t="Please enter a valid phone number")=>p.string().regex(/^[+]?[1-9][\d]{0,15}$/,t),url:(t="Please enter a valid URL")=>p.string().min(1,"URL is required").url(t)}});var ia={};u(ia,{default:()=>gb,AfriInput:()=>mn});var mn,gb;var fa=m(()=>{v();Xo();mn=class mn extends i{static get observedAttributes(){return["type","name","label","placeholder","error","helper","theme","icon","required","aria-label","aria-describedby","validation"]}constructor(){super();this._uniqueId=Math.random().toString(36).substr(2,9),this.render()}get value(){return this.shadowRoot.querySelector("input")?.value||""}set value(t){let n=this.shadowRoot.querySelector("input");if(n)n.value=t}connectedCallback(){this._attachInputListeners(),this.loadStyles()}attributeChangedCallback(){this.render(),this._attachInputListeners()}_attachInputListeners(){let t=this.shadowRoot.querySelector("input");if(!t)return;t.addEventListener("input",(n)=>{if(this.emit("af-input",{value:n.target.value}),this.hasAttribute("error"))this.removeAttribute("error")}),t.addEventListener("blur",()=>{this.emit("af-blur",{value:this.value}),this._validateInput()})}_setupValidation(){if(!this.getAttribute("validation"))return;let n=this.shadowRoot.querySelector("input");if(!n)return;n.addEventListener("input",()=>{if(this.hasAttribute("error"))this.removeAttribute("error")})}_validateInput(){let t=this.shadowRoot.querySelector("input");if(!t)return;let n=this.getAttribute("validation"),r=t.value;if(this.hasAttribute("required")&&!r.trim()){this.setAttribute("error","This field is required");return}if(n&&r.trim()){let a=this._getValidationSchema(n);if(a){let e=zt.validateField(a,r);if(!e.success)this.setAttribute("error",e.error);else this.removeAttribute("error")}}}_getValidationSchema(t){let n={email:K.email(),password:K.password(),phone:K.phone(),url:K.url(),required:K.required()};if(t.includes(":")){let[r,o]=t.split(":"),a=parseInt(o);switch(r){case"minLength":return K.minLength(a);case"maxLength":return K.maxLength(a);case"pattern":return K.pattern(new RegExp(o),"Invalid format")}}return n[t]||null}render(){let t=this.getAttribute("type")||"text",n=this.getAttribute("name")||"",r=this.getAttribute("label")||"",o=this.getAttribute("placeholder")||"",a=this.getAttribute("error")||"",e=this.getAttribute("helper")||"",l=this.getAttribute("theme")||"tanzania",b=this.getAttribute("icon")||"",d=this.hasAttribute("required"),$=this.getAttribute("aria-label"),E=this.getAttribute("aria-describedby"),L={tanzania:{focus:"#1EB53A",error:"#DC3545"},maasai:{focus:"#FF0000",error:"#8B0000"},ndebele:{focus:"#4169E1",error:"#DC143C"}},H=L[l]||L.tanzania,X=[];if(a)X.push(`error-${this._uniqueId}`);else if(e)X.push(`helper-${this._uniqueId}`);if(E)X.push(...E.split(" "));let Wn=X.length>0?`aria-describedby="${X.join(" ")}"`:"";this.shadowRoot.innerHTML=`
|
|
1901
1906
|
<style>
|
|
1902
1907
|
:host {
|
|
1903
1908
|
display: block;
|
|
@@ -1917,7 +1922,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1917
1922
|
}
|
|
1918
1923
|
|
|
1919
1924
|
.required-star {
|
|
1920
|
-
color: ${
|
|
1925
|
+
color: ${H.error};
|
|
1921
1926
|
margin-left: 2px;
|
|
1922
1927
|
}
|
|
1923
1928
|
|
|
@@ -1930,7 +1935,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1930
1935
|
input {
|
|
1931
1936
|
width: 100%;
|
|
1932
1937
|
padding: 10px 13px;
|
|
1933
|
-
${
|
|
1938
|
+
${b?"padding-left: 40px;":""}
|
|
1934
1939
|
font-size: 15px;
|
|
1935
1940
|
border: 2px solid #ddd;
|
|
1936
1941
|
border-radius: 5px;
|
|
@@ -1941,12 +1946,12 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1941
1946
|
|
|
1942
1947
|
input:focus {
|
|
1943
1948
|
outline: none;
|
|
1944
|
-
border-color: ${a?
|
|
1945
|
-
box-shadow: 0 0 0 3px ${a?
|
|
1949
|
+
border-color: ${a?H.error:H.focus};
|
|
1950
|
+
box-shadow: 0 0 0 3px ${a?H.error+"20":H.focus+"20"};
|
|
1946
1951
|
}
|
|
1947
1952
|
|
|
1948
1953
|
input.has-error {
|
|
1949
|
-
border-color: ${
|
|
1954
|
+
border-color: ${H.error};
|
|
1950
1955
|
}
|
|
1951
1956
|
|
|
1952
1957
|
.icon {
|
|
@@ -1966,30 +1971,30 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
1966
1971
|
.error-text {
|
|
1967
1972
|
font-size: 12px;
|
|
1968
1973
|
margin-top: 4px;
|
|
1969
|
-
color: ${
|
|
1974
|
+
color: ${H.error};
|
|
1970
1975
|
}
|
|
1971
1976
|
</style>
|
|
1972
1977
|
|
|
1973
1978
|
<div class="input-wrapper">
|
|
1974
|
-
${r?`<label for="input-${this._uniqueId}">${r}${
|
|
1979
|
+
${r?`<label for="input-${this._uniqueId}">${r}${d?'<span class="required-star">*</span>':""}</label>`:""}
|
|
1975
1980
|
<div class="input-container">
|
|
1976
|
-
${
|
|
1981
|
+
${b?`<span class="icon">${b}</span>`:""}
|
|
1977
1982
|
<input
|
|
1978
1983
|
id="input-${this._uniqueId}"
|
|
1979
1984
|
name="${n}"
|
|
1980
1985
|
type="${t}"
|
|
1981
1986
|
placeholder="${o}"
|
|
1982
1987
|
class="${a?"has-error":""}"
|
|
1983
|
-
${
|
|
1988
|
+
${d?"required":""}
|
|
1984
1989
|
${$?`aria-label="${$}"`:""}
|
|
1985
1990
|
${a?'aria-invalid="true"':""}
|
|
1986
|
-
${
|
|
1991
|
+
${Wn}
|
|
1987
1992
|
/>
|
|
1988
1993
|
</div>
|
|
1989
1994
|
${a?`<div id="error-${this._uniqueId}" class="error-text" role="alert">${a}</div>`:""}
|
|
1990
1995
|
${e&&!a?`<div id="helper-${this._uniqueId}" class="helper-text">${e}</div>`:""}
|
|
1991
1996
|
</div>
|
|
1992
|
-
`}};
|
|
1997
|
+
`}};f("af-input",mn);gb=mn});var da={};u(da,{default:()=>mb,AfriAlert:()=>sn});var sn,mb;var ca=m(()=>{v();sn=class sn extends i{static get observedAttributes(){return["type","title","dismissible"]}constructor(){super();this.render()}connectedCallback(){this.shadowRoot.querySelector(".close-btn")?.addEventListener("click",()=>{this.remove(),this.emit("af-dismiss")})}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("type")||"info",n=this.getAttribute("title")||"",r=this.hasAttribute("dismissible"),o={success:{bg:"#d4edda",border:"#1EB53A",text:"#155724",icon:"✓"},warning:{bg:"#fff3cd",border:"#FCD116",text:"#856404",icon:"⚠"},error:{bg:"#f8d7da",border:"#DC3545",text:"#721c24",icon:"✕"},info:{bg:"#d1ecf1",border:"#00A3DD",text:"#0c5460",icon:"ℹ"}},a=o[t]||o.info;this.shadowRoot.innerHTML=`
|
|
1993
1998
|
<style>
|
|
1994
1999
|
:host {
|
|
1995
2000
|
display: block;
|
|
@@ -2069,34 +2074,34 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2069
2074
|
</div>
|
|
2070
2075
|
${r?'<button class="close-btn" aria-label="Dismiss">×</button>':""}
|
|
2071
2076
|
</div>
|
|
2072
|
-
`}};
|
|
2073
|
-
align-items: ${
|
|
2077
|
+
`}};f("af-alert",sn);mb=sn});var ha={};u(ha,{AfriGrid:()=>Fo});function sb(t,n){let{sidebarSide:r="left",sidebarWidth:o="280px",minWidth:a="280px",gap:e="24px",columns:l,rows:b,align:d="stretch",justify:$="stretch",dense:E=!1}=n,L=E?"dense":"",H=`
|
|
2078
|
+
align-items: ${d};
|
|
2074
2079
|
justify-items: ${$};
|
|
2075
2080
|
gap: ${e};
|
|
2076
|
-
`;switch(t){case"sidebar":return r==="right"?`display: grid; grid-template-columns: 1fr ${o}; ${
|
|
2081
|
+
`;switch(t){case"sidebar":return r==="right"?`display: grid; grid-template-columns: 1fr ${o}; ${H}`:`display: grid; grid-template-columns: ${o} 1fr; ${H}`;case"holy-grail":return`
|
|
2077
2082
|
display: grid;
|
|
2078
2083
|
grid-template-columns: ${o} 1fr ${o};
|
|
2079
2084
|
grid-template-rows: auto 1fr auto;
|
|
2080
|
-
${
|
|
2085
|
+
${H}
|
|
2081
2086
|
`;case"bento":return`
|
|
2082
2087
|
display: grid;
|
|
2083
2088
|
grid-template-columns: repeat(12, 1fr);
|
|
2084
2089
|
grid-auto-rows: minmax(120px, auto);
|
|
2085
|
-
grid-auto-flow: row ${
|
|
2086
|
-
${
|
|
2090
|
+
grid-auto-flow: row ${L};
|
|
2091
|
+
${H}
|
|
2087
2092
|
`;case"masonry":return`
|
|
2088
2093
|
display: grid;
|
|
2089
2094
|
grid-template-columns: repeat(auto-fill, minmax(${a}, 1fr));
|
|
2090
2095
|
grid-template-rows: masonry;
|
|
2091
|
-
grid-auto-flow: row ${
|
|
2092
|
-
${
|
|
2093
|
-
`;case"auto":default:{let X=l?`repeat(${l}, 1fr)`:`repeat(auto-fit, minmax(${a}, 1fr))`,
|
|
2096
|
+
grid-auto-flow: row ${L};
|
|
2097
|
+
${H}
|
|
2098
|
+
`;case"auto":default:{let X=l?`repeat(${l}, 1fr)`:`repeat(auto-fit, minmax(${a}, 1fr))`,Wn=b?`repeat(${b}, 1fr)`:"auto";return`
|
|
2094
2099
|
display: grid;
|
|
2095
2100
|
grid-template-columns: ${X};
|
|
2096
|
-
${
|
|
2097
|
-
grid-auto-flow: row ${
|
|
2098
|
-
${
|
|
2099
|
-
`}}}var
|
|
2101
|
+
${b?`grid-template-rows: ${Wn};`:""}
|
|
2102
|
+
grid-auto-flow: row ${L};
|
|
2103
|
+
${H}
|
|
2104
|
+
`}}}var Fo;var ga=m(()=>{v();Fo=class Fo extends i{static get observedAttributes(){return["min-width","gap","columns","rows","layout","align","justify","dense","sidebar-side","sidebar-width"]}attributeChangedCallback(){if(this.isConnected)this.render()}_getAttrs(){return{minWidth:this.getAttribute("min-width")||"280px",gap:this.getAttribute("gap")||"24px",columns:this.getAttribute("columns")||null,rows:this.getAttribute("rows")||null,layout:this.getAttribute("layout")||"auto",align:this.getAttribute("align")||"stretch",justify:this.getAttribute("justify")||"stretch",dense:this.hasAttribute("dense"),sidebarSide:this.getAttribute("sidebar-side")||"left",sidebarWidth:this.getAttribute("sidebar-width")||"280px"}}_buildResponsiveBreakpoints(t){if(t.layout!=="auto"&&t.layout!=="masonry")return"";return`
|
|
2100
2105
|
@media (max-width: 768px) {
|
|
2101
2106
|
.grid {
|
|
2102
2107
|
grid-template-columns: repeat(auto-fit, minmax(min(${t.minWidth}, 100%), 1fr));
|
|
@@ -2113,7 +2118,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2113
2118
|
grid-template-columns: 1fr;
|
|
2114
2119
|
}
|
|
2115
2120
|
}
|
|
2116
|
-
`}render(){let t=this._getAttrs(),n=
|
|
2121
|
+
`}render(){let t=this._getAttrs(),n=sb(t.layout,t),r=this._buildResponsiveBreakpoints(t)+this._buildSidebarResponsive(t);this.shadowRoot.innerHTML=g`
|
|
2117
2122
|
<style>
|
|
2118
2123
|
:host {
|
|
2119
2124
|
display: block;
|
|
@@ -2143,7 +2148,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2143
2148
|
>
|
|
2144
2149
|
<slot></slot>
|
|
2145
2150
|
</div>
|
|
2146
|
-
`}connectedCallback(){this.render(),this._setupResizeObserver()}disconnectedCallback(){if(this._resizeObserver)this._resizeObserver.disconnect()}_setupResizeObserver(){if(typeof ResizeObserver>"u")return;let t=this.offsetWidth;this._resizeObserver=new ResizeObserver((n)=>{for(let r of n){let o=r.contentRect.width;if(Math.abs(o-t)>10)t=o,this.emit("af-grid-resize",{width:o,height:r.contentRect.height,layout:this.getAttribute("layout")||"auto"})}}),this._resizeObserver.observe(this)}setLayout(t){this.setAttribute("layout",t)}setColumns(t){this.setAttribute("columns",String(t))}setDense(t){if(t)this.setAttribute("dense","");else this.removeAttribute("dense")}};
|
|
2151
|
+
`}connectedCallback(){this.render(),this._setupResizeObserver()}disconnectedCallback(){if(this._resizeObserver)this._resizeObserver.disconnect()}_setupResizeObserver(){if(typeof ResizeObserver>"u")return;let t=this.offsetWidth;this._resizeObserver=new ResizeObserver((n)=>{for(let r of n){let o=r.contentRect.width;if(Math.abs(o-t)>10)t=o,this.emit("af-grid-resize",{width:o,height:r.contentRect.height,layout:this.getAttribute("layout")||"auto"})}}),this._resizeObserver.observe(this)}setLayout(t){this.setAttribute("layout",t)}setColumns(t){this.setAttribute("columns",String(t))}setDense(t){if(t)this.setAttribute("dense","");else this.removeAttribute("dense")}};f("af-grid",Fo)});var ma={};u(ma,{AfriSection:()=>Jo});var Jo;var sa=m(()=>{v();Jo=class Jo extends i{render(){let t=this.getAttribute("title");this.shadowRoot.innerHTML=g`
|
|
2147
2152
|
<style>
|
|
2148
2153
|
:host { display: block; width: 100%; }
|
|
2149
2154
|
.section {
|
|
@@ -2170,20 +2175,20 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2170
2175
|
}
|
|
2171
2176
|
</style>
|
|
2172
2177
|
<section class="section">
|
|
2173
|
-
${
|
|
2178
|
+
${t?g`
|
|
2174
2179
|
<div class="section-header">
|
|
2175
|
-
<h2>${
|
|
2180
|
+
<h2>${t}</h2>
|
|
2176
2181
|
</div>
|
|
2177
2182
|
`:""}
|
|
2178
2183
|
<slot></slot>
|
|
2179
2184
|
</section>
|
|
2180
|
-
`}connectedCallback(){this.render()}};
|
|
2185
|
+
`}connectedCallback(){this.render()}};f("af-section",Jo)});var pa={};u(pa,{default:()=>pb,AfriIcon:()=>pn});var pn,pb;var va=m(()=>{v();pn=class pn extends i{static get observedAttributes(){return["name","size"]}connectedCallback(){this.render()}render(){let t=this.getAttribute("name")||"circle",n=this.getAttribute("size")||"24",o={check:'<path d="M20 6L9 17l-5-5" />',x:'<path d="M18 6L6 18M6 6l12 12" />',"arrow-right":'<path d="M5 12h14M12 5l7 7-7 7" />',menu:'<path d="M3 12h18M3 6h18M3 18h18" />',search:'<circle cx="11" cy="11" r="8" /><path d="M21 21l-4.35-4.35" />'}[t]||"";this.shadowRoot.innerHTML=`
|
|
2181
2186
|
<style>
|
|
2182
2187
|
:host { display: inline-flex; vertical-align: middle; }
|
|
2183
2188
|
svg { width: ${n}px; height: ${n}px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
|
|
2184
2189
|
</style>
|
|
2185
2190
|
<svg viewBox="0 0 24 24">${o}</svg>
|
|
2186
|
-
`}};
|
|
2191
|
+
`}};f("af-icon",pn);pb=pn});var ua={};u(ua,{default:()=>vb,AfriAccordion:()=>vn});var vn,vb;var $a=m(()=>{v();vn=class vn extends i{static get observedAttributes(){return["theme","multiple"]}constructor(){super();this._openItems=new Set,this._uniqueId=Math.random().toString(36).substr(2,9),this.render()}connectedCallback(){this._setupAccordion()}_setupAccordion(){this.shadowRoot.querySelectorAll(".accordion-header").forEach((n,r)=>{n.addEventListener("click",()=>{this._toggleItem(r)})})}_toggleItem(t){let n=this.hasAttribute("multiple");if(this._openItems.has(t))this._openItems.delete(t);else{if(!n)this._openItems.clear();this._openItems.add(t)}this.render(),this._setupAccordion(),this.emit("af-toggle",{index:t,open:this._openItems.has(t)})}attributeChangedCallback(){this.render(),this._setupAccordion()}render(){let t=this.getAttribute("theme")||"tanzania",n=this.querySelector('[slot="items"]'),r=n?Array.from(n.children):[],o={tanzania:{accent:"#1EB53A"},maasai:{accent:"#FF0000"},ndebele:{accent:"#4169E1"}},a=o[t]||o.tanzania;this.shadowRoot.innerHTML=`
|
|
2187
2192
|
<style>
|
|
2188
2193
|
:host {
|
|
2189
2194
|
display: block;
|
|
@@ -2261,22 +2266,22 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2261
2266
|
</style>
|
|
2262
2267
|
|
|
2263
2268
|
<div class="accordion">
|
|
2264
|
-
${r.map((e,l)=>{let
|
|
2269
|
+
${r.map((e,l)=>{let b=this._openItems.has(l),d=`accordion-header-${this._uniqueId}-${l}`,$=`accordion-panel-${this._uniqueId}-${l}`;return`
|
|
2265
2270
|
<div class="accordion-item">
|
|
2266
2271
|
<button
|
|
2267
|
-
class="accordion-header ${
|
|
2268
|
-
aria-expanded="${
|
|
2272
|
+
class="accordion-header ${b?"active":""}"
|
|
2273
|
+
aria-expanded="${b}"
|
|
2269
2274
|
aria-controls="${$}"
|
|
2270
|
-
id="${
|
|
2275
|
+
id="${d}"
|
|
2271
2276
|
>
|
|
2272
2277
|
<span>${e.getAttribute("title")||`Item ${l+1}`}</span>
|
|
2273
2278
|
<span class="accordion-icon">▼</span>
|
|
2274
2279
|
</button>
|
|
2275
2280
|
<div
|
|
2276
|
-
class="accordion-content ${
|
|
2281
|
+
class="accordion-content ${b?"open":""}"
|
|
2277
2282
|
id="${$}"
|
|
2278
2283
|
role="region"
|
|
2279
|
-
aria-labelledby="${
|
|
2284
|
+
aria-labelledby="${d}"
|
|
2280
2285
|
>
|
|
2281
2286
|
<div class="accordion-body">
|
|
2282
2287
|
${e.innerHTML}
|
|
@@ -2286,7 +2291,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2286
2291
|
`}).join("")}
|
|
2287
2292
|
</div>
|
|
2288
2293
|
<slot name="items"></slot>
|
|
2289
|
-
`}};
|
|
2294
|
+
`}};f("af-accordion",vn);vb=vn});var wa={};u(wa,{default:()=>ub,AfriHero:()=>un});var un,ub;var xa=m(()=>{v();un=class un extends i{static get observedAttributes(){return["title","subtitle","pattern","overlay"]}connectedCallback(){super.connectedCallback(),this.render(),this.loadStyles()}render(){let t=this.getAttribute("title")||"AfriCode",n=this.getAttribute("subtitle")||"",r=this.getAttribute("pattern")||"";this.shadowRoot.innerHTML=`
|
|
2290
2295
|
<style>
|
|
2291
2296
|
:host {
|
|
2292
2297
|
display: flex;
|
|
@@ -2386,7 +2391,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2386
2391
|
</div>
|
|
2387
2392
|
<slot></slot>
|
|
2388
2393
|
</div>
|
|
2389
|
-
`}};
|
|
2394
|
+
`}};f("af-hero",un);ub=un});var Aa={};u(Aa,{default:()=>$b,AfriTable:()=>$n});var $n,$b;var _a=m(()=>{v();$n=class $n extends i{static get observedAttributes(){return["theme","striped","hoverable"]}constructor(){super();this._columns=[],this._data=[],this._sortColumn=null,this._sortDirection="asc",this.render()}set columns(t){this._columns=t,this.render()}set data(t){this._data=t,this.render()}attributeChangedCallback(){this.render()}_handleSort(t){if(this._sortColumn===t)this._sortDirection=this._sortDirection==="asc"?"desc":"asc";else this._sortColumn=t,this._sortDirection="asc";this.emit("af-sort",{column:t,direction:this._sortDirection}),this.render()}_getSortedData(){if(!this._sortColumn)return this._data;return[...this._data].sort((t,n)=>{let r=t[this._sortColumn],o=n[this._sortColumn],a=this._sortDirection==="asc"?1:-1;if(typeof r==="number")return(r-o)*a;return String(r).localeCompare(String(o))*a})}render(){let t=this.getAttribute("theme")||"tanzania",n=this.hasAttribute("striped"),r=this.hasAttribute("hoverable"),o={tanzania:{header:"#1EB53A",text:"#FFFFFF",accent:"#FCD116"},maasai:{header:"#8B0000",text:"#FFFFFF",accent:"#FF0000"},ndebele:{header:"#4169E1",text:"#FFFFFF",accent:"#FFD700"}},a=o[t]||o.tanzania,e=this._getSortedData();this.shadowRoot.innerHTML=`
|
|
2390
2395
|
<style>
|
|
2391
2396
|
:host {
|
|
2392
2397
|
display: block;
|
|
@@ -2466,7 +2471,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2466
2471
|
<tbody>
|
|
2467
2472
|
${e.length?e.map((l)=>`
|
|
2468
2473
|
<tr>
|
|
2469
|
-
${this._columns.map((
|
|
2474
|
+
${this._columns.map((b)=>`<td>${l[b.key]??""}</td>`).join("")}
|
|
2470
2475
|
</tr>
|
|
2471
2476
|
`).join(""):`
|
|
2472
2477
|
<tr>
|
|
@@ -2476,7 +2481,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2476
2481
|
</tbody>
|
|
2477
2482
|
</table>
|
|
2478
2483
|
</div>
|
|
2479
|
-
`,this.shadowRoot.querySelectorAll("th").forEach((l)=>{l.addEventListener("click",()=>{this._handleSort(l.dataset.column)})})}};
|
|
2484
|
+
`,this.shadowRoot.querySelectorAll("th").forEach((l)=>{l.addEventListener("click",()=>{this._handleSort(l.dataset.column)})})}};f("af-table",$n);$b=$n});var ka={};u(ka,{default:()=>wb,AfriModal:()=>wn});var wn,wb;var qa=m(()=>{v();wn=class wn extends i{static get observedAttributes(){return["open","theme","size","aria-label","aria-labelledby"]}constructor(){super();this.render()}connectedCallback(){this._setupListeners()}_setupListeners(){this.shadowRoot.querySelector(".backdrop")?.addEventListener("click",(t)=>{if(t.target.classList.contains("backdrop"))this.close()}),this.shadowRoot.querySelector(".close-btn")?.addEventListener("click",()=>{this.close()}),document.addEventListener("keydown",(t)=>{if(t.key==="Escape"&&this.hasAttribute("open"))this.close()}),this.shadowRoot.addEventListener("keydown",(t)=>{if(t.key==="Tab"&&this.hasAttribute("open"))this._handleTabKey(t)})}_getFocusableElements(){let t=this.shadowRoot.querySelector(".modal"),n='button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])',r=Array.from(t?.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])')||[]),o=Array.from(this.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'));return[...r,...o]}_focusFirstFocusableElement(){let t=this._getFocusableElements();if(t.length>0)t[0].focus();else this.shadowRoot.querySelector(".close-btn")?.focus()}_handleTabKey(t){let n=this._getFocusableElements();if(n.length===0){t.preventDefault();return}let r=n[0],o=n[n.length-1];if(t.shiftKey){if(document.activeElement===r)t.preventDefault(),o.focus()}else if(document.activeElement===o)t.preventDefault(),r.focus()}open(){this.setAttribute("open",""),document.body.style.overflow="hidden",this._previousFocus=document.activeElement,this._focusFirstFocusableElement(),this.emit("af-open")}close(){if(this.removeAttribute("open"),document.body.style.overflow="",this._previousFocus&&this._previousFocus.focus)this._previousFocus.focus();this.emit("af-close")}attributeChangedCallback(t,n,r){if(this.render(),t==="open")this._setupListeners()}render(){let t=this.hasAttribute("open"),n=this.getAttribute("theme")||"tanzania",r=this.getAttribute("size")||"md",o={tanzania:{accent:"#1EB53A"},maasai:{accent:"#FF0000"},ndebele:{accent:"#4169E1"}},a=o[n]||o.tanzania,e={sm:"400px",md:"560px",lg:"720px",full:"95vw"},l=this.getAttribute("aria-label"),b=this.getAttribute("aria-labelledby")||"modal-title";this.shadowRoot.innerHTML=`
|
|
2480
2485
|
<style>
|
|
2481
2486
|
:host {
|
|
2482
2487
|
font-family: 'Inter', system-ui, sans-serif;
|
|
@@ -2567,7 +2572,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2567
2572
|
</style>
|
|
2568
2573
|
|
|
2569
2574
|
<div class="backdrop">
|
|
2570
|
-
<div class="modal" role="dialog" aria-modal="true" ${l?`aria-label="${l}"`:`aria-labelledby="${
|
|
2575
|
+
<div class="modal" role="dialog" aria-modal="true" ${l?`aria-label="${l}"`:`aria-labelledby="${b}"`}>
|
|
2571
2576
|
<div class="modal-header">
|
|
2572
2577
|
<slot name="header" id="modal-title"></slot>
|
|
2573
2578
|
<button class="close-btn" aria-label="Close modal">×</button>
|
|
@@ -2580,7 +2585,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2580
2585
|
</div>
|
|
2581
2586
|
</div>
|
|
2582
2587
|
</div>
|
|
2583
|
-
`}};
|
|
2588
|
+
`}};f("af-modal",wn);wb=wn});var Ea={};u(Ea,{default:()=>xb,AfriTabs:()=>xn});var xn,xb;var Ma=m(()=>{v();xn=class xn extends i{static get observedAttributes(){return["theme"]}constructor(){super();this._activeTab=0,this.render()}connectedCallback(){this._setupTabs(),this.addEventListener("keydown",this._handleKeydown.bind(this))}_handleKeydown(t){let n=this.querySelector('[slot="tabs"]'),r=n?Array.from(n.children):[];if(r.length===0)return;switch(t.key){case"ArrowLeft":t.preventDefault(),this._activeTab=this._activeTab>0?this._activeTab-1:r.length-1,this.render(),this._setupTabs(),this._focusActiveTab();break;case"ArrowRight":t.preventDefault(),this._activeTab=this._activeTab<r.length-1?this._activeTab+1:0,this.render(),this._setupTabs(),this._focusActiveTab();break;case"Home":t.preventDefault(),this._activeTab=0,this.render(),this._setupTabs(),this._focusActiveTab();break;case"End":t.preventDefault(),this._activeTab=r.length-1,this.render(),this._setupTabs(),this._focusActiveTab();break}}_focusActiveTab(){let t=this.shadowRoot.querySelectorAll(".tab-button");if(t[this._activeTab])t[this._activeTab].focus()}_setupTabs(){this.shadowRoot.querySelectorAll(".tab-button").forEach((n,r)=>{n.addEventListener("click",()=>{this._activeTab=r,this.render(),this._setupTabs(),this.emit("af-tab-change",{index:r,tab:n.textContent})})})}attributeChangedCallback(){this.render(),this._setupTabs()}render(){let t=this.getAttribute("theme")||"tanzania",n=this.querySelector('[slot="tabs"]'),r=n?Array.from(n.children):[],o={tanzania:{active:"#1EB53A",text:"#FFFFFF"},maasai:{active:"#FF0000",text:"#FFFFFF"},ndebele:{active:"#4169E1",text:"#FFFFFF"}},a=o[t]||o.tanzania;this.shadowRoot.innerHTML=`
|
|
2584
2589
|
<style>
|
|
2585
2590
|
:host {
|
|
2586
2591
|
display: block;
|
|
@@ -2675,7 +2680,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2675
2680
|
</div>
|
|
2676
2681
|
</div>
|
|
2677
2682
|
<slot name="tabs"></slot>
|
|
2678
|
-
`}};
|
|
2683
|
+
`}};f("af-tabs",xn);xb=xn});function Qo(t){if(An.has(t))return An.get(t);let r=new Proxy(t,{get(o,a,e){let l=Reflect.get(o,a,e);if(l!==null&&typeof l==="object")return Qo(l);return l},set(o,a,e,l){let b=Reflect.get(o,a,l);if(b!==e){let d=Reflect.set(o,a,e,l);if(d)Ha(l,e,b,a);return d}return!0},deleteProperty(o,a){let e=Reflect.get(o,a),l=Reflect.deleteProperty(o,a);if(l){let b=An.get(o);Ha(b,void 0,e,a)}return l}});return An.set(t,r),r}function La(t,n){if(!_n.has(t))_n.set(t,new Set);let r=_n.get(t);return r.add(n),()=>{r.delete(n)}}function Ha(t,n,r,o){let a=_n.get(t);if(!a)return;a.forEach((e)=>{try{e(n,r,o)}catch(l){console.error("[AfriCode State] Subscriber error:",l)}})}class Sa{constructor(){this.store={}}get(t){return t.split("/").reduce((n,r)=>n?.[r],this.store)}set(t,n){let r=t.split("/"),o=this.store;while(r.length>1){let a=r.shift();if(!o[a]||typeof o[a]!=="object")o[a]={};o=o[a]}o[r[0]]=n}getAll(){return this.store}}var _n,An,Jf;var Go=m(()=>{_n=new WeakMap,An=new WeakMap;Jf=new Sa});var Ab,U,Ra;var Ya=m(()=>{Go();Ab={theme:"light",language:"en",ui:{sidebarCollapsed:!1,theme:"dark",activePage:"home"},user:{name:"Guest",permissions:[]},config:{animationsEnabled:!0,soundEnabled:!1}},U=Qo(Ab),Ra={setTheme(t){if(["dark","light","system"].includes(t))U.theme=t,U.ui.theme=t},setLanguage(t){U.language=t},toggleSidebar(t){if(typeof t==="boolean")U.ui.sidebarCollapsed=t;else U.ui.sidebarCollapsed=!U.ui.sidebarCollapsed},setActivePage(t){U.ui.activePage=t}}});var Xa={};u(Xa,{default:()=>_b,AfriSidebar:()=>kn});var kn,_b;var Fa=m(()=>{v();Ya();Go();kn=class kn extends i{static get observedAttributes(){return["position"]}constructor(){super();this._unsubscribe=null}connectedCallback(){super.connectedCallback(),this._unsubscribe=La(()=>{this.updateUI()}),this.render()}disconnectedCallback(){if(this._unsubscribe)this._unsubscribe()}updateUI(){let t=U.ui.sidebarCollapsed,n=this.shadowRoot.querySelector(".sidebar"),r=this.shadowRoot.querySelector(".sidebar-title"),o=this.shadowRoot.getElementById("toggle"),a=this.shadowRoot.querySelector(".sidebar-content");if(n)n.style.width=t?"60px":"260px";if(r)r.style.opacity=t?"0":"1";if(a)a.style.padding=t?"12px":"20px";if(o)o.innerHTML=t?"→":"← Collapse"}render(){let t=this.getAttribute("position")||"left",n=U.ui.sidebarCollapsed;this.shadowRoot.innerHTML=`
|
|
2679
2684
|
<style>
|
|
2680
2685
|
:host {
|
|
2681
2686
|
display: block;
|
|
@@ -2784,7 +2789,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2784
2789
|
</button>
|
|
2785
2790
|
</div>
|
|
2786
2791
|
</aside>
|
|
2787
|
-
`,this.shadowRoot.getElementById("toggle").addEventListener("click",()=>{
|
|
2792
|
+
`,this.shadowRoot.getElementById("toggle").addEventListener("click",()=>{Ra.toggleSidebar()})}};f("af-sidebar",kn);_b=kn});var Ja={};u(Ja,{default:()=>kb,AfriDropdown:()=>qn});var qn,kb;var Qa=m(()=>{v();qn=class qn extends i{static get observedAttributes(){return["label","open"]}constructor(){super();this._open=!1,this.render()}toggle(){if(this._open=!this._open,this._open)this.setAttribute("open","");else this.removeAttribute("open");this.render()}close(){this._open=!1,this.removeAttribute("open"),this.render()}connectedCallback(){document.addEventListener("click",(t)=>{if(!this.contains(t.target))this.close()}),this.addEventListener("keydown",this._handleKeydown.bind(this))}_handleKeydown(t){let n=this.shadowRoot.getElementById("trigger");switch(t.key){case"Enter":case" ":t.preventDefault(),this.toggle();break;case"Escape":if(this._open)t.preventDefault(),this.close(),n.focus();break;case"ArrowDown":if(!this._open)t.preventDefault(),this.toggle();break}}render(){let t=this.getAttribute("label")||"Menu",n=this.hasAttribute("open");this.shadowRoot.innerHTML=`
|
|
2788
2793
|
<style>
|
|
2789
2794
|
:host {
|
|
2790
2795
|
display: inline-block;
|
|
@@ -2866,7 +2871,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2866
2871
|
<div class="dropdown-menu" role="menu" ${n?"":'aria-hidden="true"'}>
|
|
2867
2872
|
<slot></slot>
|
|
2868
2873
|
</div>
|
|
2869
|
-
`,this.shadowRoot.getElementById("trigger").addEventListener("click",(r)=>{r.stopPropagation(),this.toggle()})}};
|
|
2874
|
+
`,this.shadowRoot.getElementById("trigger").addEventListener("click",(r)=>{r.stopPropagation(),this.toggle()})}};f("af-dropdown",qn);kb=qn});var Ga={};u(Ga,{default:()=>qb,AfriSelect:()=>En});var En,qb;var Ba=m(()=>{v();En=class En extends i{static get observedAttributes(){return["label","placeholder","theme","error","required","aria-label","aria-describedby"]}constructor(){super();this._uniqueId=Math.random().toString(36).substr(2,9),this._isOpen=!1,this._selectedIndex=-1,this._options=[],this.render()}get value(){return this._selectedIndex>=0?this._options[this._selectedIndex]?.value:""}connectedCallback(){this._options=Array.from(this.querySelectorAll("option")).map((t)=>({value:t.value,label:t.textContent})),this.render(),this._setupListeners()}_setupListeners(){let t=this.shadowRoot.querySelector(".select-trigger");t?.addEventListener("click",()=>{this._toggleDropdown()}),t?.addEventListener("keydown",(n)=>{this._handleKeydown(n)}),this.shadowRoot.querySelectorAll(".select-option").forEach((n,r)=>{n.addEventListener("click",()=>{this._selectOption(r)})}),document.addEventListener("click",(n)=>{if(!this.contains(n.target)&&this._isOpen)this._closeDropdown()})}_toggleDropdown(){this._isOpen=!this._isOpen;let t=this.shadowRoot.querySelector(".select-trigger"),n=this.shadowRoot.querySelector(".select-dropdown");if(n?.classList.toggle("open",this._isOpen),t?.classList.toggle("open",this._isOpen),this._isOpen)t?.setAttribute("aria-expanded","true"),n?.setAttribute("aria-hidden","false");else t?.setAttribute("aria-expanded","false"),n?.setAttribute("aria-hidden","true")}_closeDropdown(){this._isOpen=!1;let t=this.shadowRoot.querySelector(".select-trigger"),n=this.shadowRoot.querySelector(".select-dropdown");n?.classList.remove("open"),t?.classList.remove("open"),t?.setAttribute("aria-expanded","false"),n?.setAttribute("aria-hidden","true")}_selectOption(t){this._selectedIndex=t,this._closeDropdown(),this.render(),this._setupListeners(),this.emit("af-change",{value:this.value,label:this._options[t].label})}_handleKeydown(t){let n=this.shadowRoot.querySelector(".select-trigger");switch(t.key){case"Enter":case" ":t.preventDefault(),this._toggleDropdown();break;case"Escape":if(this._isOpen)t.preventDefault(),this._closeDropdown(),n.focus();break;case"ArrowDown":if(!this._isOpen)t.preventDefault(),this._toggleDropdown();else t.preventDefault(),this._navigateOptions(1);break;case"ArrowUp":if(this._isOpen)t.preventDefault(),this._navigateOptions(-1);break}}_navigateOptions(t){let n=this.shadowRoot.querySelectorAll(".select-option");if(n.length===0)return;let r=this._selectedIndex+t;if(r<0)r=n.length-1;if(r>=n.length)r=0;this._selectedIndex=r,this.render(),this._setupListeners(),this.shadowRoot.querySelector(".select-option.selected")?.scrollIntoView({block:"nearest"})}attributeChangedCallback(){this.render(),this._setupListeners()}render(){let t=this.getAttribute("label")||"",n=this.getAttribute("placeholder")||"Select an option",r=this.getAttribute("theme")||"tanzania",o=this.getAttribute("error")||"",a=this.hasAttribute("required"),e=this.getAttribute("aria-label"),l=this.getAttribute("aria-describedby"),b={tanzania:{focus:"#1EB53A",error:"#DC3545"},maasai:{focus:"#FF0000",error:"#8B0000"},ndebele:{focus:"#4169E1",error:"#DC143C"}},d=b[r]||b.tanzania,$=[];if(o)$.push(`error-${this._uniqueId}`);if(l)$.push(...l.split(" "));let E=$.length>0?`aria-describedby="${$.join(" ")}"`:"",L=this._selectedIndex>=0?this._options[this._selectedIndex]?.label:n;this.shadowRoot.innerHTML=`
|
|
2870
2875
|
<style>
|
|
2871
2876
|
:host {
|
|
2872
2877
|
display: block;
|
|
@@ -2883,7 +2888,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2883
2888
|
}
|
|
2884
2889
|
|
|
2885
2890
|
.required-star {
|
|
2886
|
-
color: ${
|
|
2891
|
+
color: ${d.error};
|
|
2887
2892
|
margin-left: 2px;
|
|
2888
2893
|
}
|
|
2889
2894
|
|
|
@@ -2895,7 +2900,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2895
2900
|
width: 100%;
|
|
2896
2901
|
padding: 10px 40px 10px 13px;
|
|
2897
2902
|
font-size: 15px;
|
|
2898
|
-
border: 2px solid ${o?
|
|
2903
|
+
border: 2px solid ${o?d.error:"#ddd"};
|
|
2899
2904
|
border-radius: 5px;
|
|
2900
2905
|
background: white;
|
|
2901
2906
|
cursor: pointer;
|
|
@@ -2908,8 +2913,8 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2908
2913
|
.select-trigger:focus,
|
|
2909
2914
|
.select-trigger.open {
|
|
2910
2915
|
outline: none;
|
|
2911
|
-
border-color: ${o?
|
|
2912
|
-
box-shadow: 0 0 0 3px ${o?
|
|
2916
|
+
border-color: ${o?d.error:d.focus};
|
|
2917
|
+
box-shadow: 0 0 0 3px ${o?d.error+"20":d.focus+"20"};
|
|
2913
2918
|
}
|
|
2914
2919
|
|
|
2915
2920
|
.select-arrow {
|
|
@@ -2955,18 +2960,18 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2955
2960
|
}
|
|
2956
2961
|
|
|
2957
2962
|
.select-option:hover {
|
|
2958
|
-
background: ${
|
|
2963
|
+
background: ${d.focus}15;
|
|
2959
2964
|
}
|
|
2960
2965
|
|
|
2961
2966
|
.select-option.selected {
|
|
2962
|
-
background: ${
|
|
2967
|
+
background: ${d.focus};
|
|
2963
2968
|
color: white;
|
|
2964
2969
|
}
|
|
2965
2970
|
|
|
2966
2971
|
.error-text {
|
|
2967
2972
|
font-size: 12px;
|
|
2968
2973
|
margin-top: 4px;
|
|
2969
|
-
color: ${
|
|
2974
|
+
color: ${d.error};
|
|
2970
2975
|
}
|
|
2971
2976
|
|
|
2972
2977
|
::slotted(option) {
|
|
@@ -2983,26 +2988,26 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
2983
2988
|
aria-haspopup="listbox"
|
|
2984
2989
|
${e?`aria-label="${e}"`:""}
|
|
2985
2990
|
${o?'aria-invalid="true"':""}
|
|
2986
|
-
${
|
|
2987
|
-
${
|
|
2991
|
+
${E}>
|
|
2992
|
+
${L}
|
|
2988
2993
|
</button>
|
|
2989
2994
|
<span class="select-arrow" aria-hidden="true">▼</span>
|
|
2990
2995
|
<div class="select-dropdown ${this._isOpen?"open":""}"
|
|
2991
2996
|
role="listbox"
|
|
2992
2997
|
aria-hidden="${!this._isOpen}">
|
|
2993
|
-
${this._options.map((
|
|
2998
|
+
${this._options.map((H,X)=>`
|
|
2994
2999
|
<div class="select-option ${X===this._selectedIndex?"selected":""}"
|
|
2995
3000
|
data-index="${X}"
|
|
2996
3001
|
role="option"
|
|
2997
3002
|
aria-selected="${X===this._selectedIndex}">
|
|
2998
|
-
${
|
|
3003
|
+
${H.label}
|
|
2999
3004
|
</div>
|
|
3000
3005
|
`).join("")}
|
|
3001
3006
|
</div>
|
|
3002
3007
|
</div>
|
|
3003
3008
|
${o?`<div id="error-${this._uniqueId}" class="error-text" role="alert">${o}</div>`:""}
|
|
3004
3009
|
<slot></slot>
|
|
3005
|
-
`}};
|
|
3010
|
+
`}};f("af-select",En);qb=En});var Da={};u(Da,{default:()=>Eb,AfriForm:()=>Mn});var Mn,Eb;var Oa=m(()=>{v();Xo();Mn=class Mn extends i{static get observedAttributes(){return["action","method","error","success","schema"]}constructor(){super();this.handleSubmit=this.handleSubmit.bind(this)}connectedCallback(){this.render(),this.shadowRoot.querySelector("form").addEventListener("submit",this.handleSubmit),this.loadStyles()}async handleSubmit(t){t.preventDefault();let n=t.target,r=this.querySelector('[type="submit"]')||this.shadowRoot.querySelector('button[type="submit"]'),o=this.getAttribute("schema"),a=o?this._getSchema(o):null,e=this.getAttribute("action"),l=this.getAttribute("method")||"GET",b=new FormData(n),d=Object.fromEntries(b.entries());if(Array.from(this.querySelectorAll("af-input")).forEach((E)=>{let L=E.getAttribute("name");if(L)d[L]=E.value}),a){let E=zt.validate(a,d);if(!E.success){this._showValidationErrors(E.errors),this.emit("af-validation-error",{errors:E.errors});return}}if(!e)return;if(r){var $=r.textContent;r.textContent="Wait...",r.disabled=!0}try{let E=await fetch(e,{method:l,headers:{"Content-Type":"application/json"},body:JSON.stringify(d)});if(E.ok)this.emit("success",await E.json()),this.setAttribute("success","Form submitted successfully!"),this.removeAttribute("error");else{let L=await E.text();this.emit("error",L),this.setAttribute("error",L),this.removeAttribute("success")}}catch(E){this.emit("error",E.message),this.setAttribute("error",E.message),this.removeAttribute("success")}finally{if(r)r.textContent=$,r.disabled=!1}}_getSchema(t){return ba[t]||null}_showValidationErrors(t){this.shadowRoot.querySelectorAll(".field-error").forEach((n)=>n.remove()),Object.entries(t).forEach(([n,r])=>{let o=this.querySelector(`[name="${n}"]`);if(o)if(o.tagName==="AF-INPUT")o.setAttribute("error",r);else{let a=document.createElement("div");a.className="field-error",a.textContent=r,a.style.color="red",a.style.fontSize="12px",a.style.marginTop="4px",o.parentNode.insertBefore(a,o.nextSibling)}})}};f("af-form",Mn);Eb=Mn});var Wa={};u(Wa,{default:()=>Mb,AfriTooltip:()=>Hn});var Hn,Mb;var Ua=m(()=>{v();Hn=class Hn extends i{static get observedAttributes(){return["text","position"]}constructor(){super();this._tooltipId=`af-tooltip-${Math.random().toString(36).substr(2,9)}`,this.render()}connectedCallback(){this._setupTooltipListeners()}attributeChangedCallback(){this.render(),this._setupTooltipListeners()}_setupTooltipListeners(){let t=this.shadowRoot.querySelector(".tooltip-trigger"),n=this.shadowRoot.querySelector(".tooltip-content");if(!t||!n)return;t.addEventListener("focus",()=>{n.style.opacity="1",n.style.visibility="visible",n.setAttribute("aria-hidden","false")}),t.addEventListener("blur",()=>{n.style.opacity="0",n.style.visibility="hidden",n.setAttribute("aria-hidden","true")}),t.addEventListener("mouseenter",()=>{n.style.opacity="1",n.style.visibility="visible",n.setAttribute("aria-hidden","false")}),t.addEventListener("mouseleave",()=>{n.style.opacity="0",n.style.visibility="hidden",n.setAttribute("aria-hidden","true")})}render(){let t=this.getAttribute("text")||"Tooltip",n=this.getAttribute("position")||"top",r={top:`
|
|
3006
3011
|
bottom: 100%;
|
|
3007
3012
|
left: 50%;
|
|
3008
3013
|
transform: translateX(-50%) translateY(-8px);
|
|
@@ -3091,7 +3096,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3091
3096
|
<slot></slot>
|
|
3092
3097
|
</span>
|
|
3093
3098
|
<div class="tooltip-content" id="${this._tooltipId}" role="tooltip" aria-hidden="true">${t}</div>
|
|
3094
|
-
`}};
|
|
3099
|
+
`}};f("af-tooltip",Hn);Mb=Hn});var Na={};u(Na,{default:()=>Hb,AfriToast:()=>Ln});var Ln,Hb;var ya=m(()=>{v();Ln=class Ln extends i{static get observedAttributes(){return["type","message","duration"]}constructor(){super();this.render()}show(t,n="info",r=4000){if(this.setAttribute("message",t),this.setAttribute("type",n),this.render(),this.shadowRoot.querySelector(".toast").classList.add("show"),r>0)setTimeout(()=>this.hide(),r)}hide(){this.shadowRoot.querySelector(".toast").classList.remove("show"),setTimeout(()=>this.emit("af-toast-close"),300)}render(){let t=this.getAttribute("type")||"info",n=this.getAttribute("message")||"",r={success:"✓",error:"✗",warning:"⚠",info:"ℹ"},o={success:"#1EB53A",error:"#EF3340",warning:"#FCD116",info:"#00A3DD"};this.shadowRoot.innerHTML=`
|
|
3095
3100
|
<style>
|
|
3096
3101
|
:host {
|
|
3097
3102
|
position: fixed;
|
|
@@ -3165,7 +3170,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3165
3170
|
</div>
|
|
3166
3171
|
<button class="toast-close" id="close">×</button>
|
|
3167
3172
|
</div>
|
|
3168
|
-
`,this.shadowRoot.getElementById("close")?.addEventListener("click",()=>this.hide())}};
|
|
3173
|
+
`,this.shadowRoot.getElementById("close")?.addEventListener("click",()=>this.hide())}};f("af-toast",Ln);Hb=Ln});var Va={};u(Va,{default:()=>Lb,AfriBadge:()=>Sn});var Sn,Lb;var Ka=m(()=>{v();Sn=class Sn extends i{static get observedAttributes(){return["variant","size","removable"]}constructor(){super();this.render()}connectedCallback(){this.shadowRoot.querySelector(".remove-btn")?.addEventListener("click",()=>{this.emit("af-remove"),this.remove()})}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("variant")||"default",n=this.getAttribute("size")||"md",r=this.hasAttribute("removable"),o={default:{bg:"#e9ecef",text:"#495057"},success:{bg:"#d4edda",text:"#155724"},warning:{bg:"#fff3cd",text:"#856404"},error:{bg:"#f8d7da",text:"#721c24"},info:{bg:"#d1ecf1",text:"#0c5460"},tanzania:{bg:"#1EB53A",text:"#FFFFFF"},maasai:{bg:"#FF0000",text:"#FFFFFF"},ndebele:{bg:"#4169E1",text:"#FFFFFF"},gold:{bg:"#FCD116",text:"#000000"}},a=o[t]||o.default,e={sm:{padding:"2px 6px",fontSize:"11px"},md:{padding:"4px 10px",fontSize:"13px"},lg:{padding:"6px 14px",fontSize:"15px"}},l=e[n]||e.md;this.shadowRoot.innerHTML=`
|
|
3169
3174
|
<style>
|
|
3170
3175
|
:host {
|
|
3171
3176
|
display: inline-block;
|
|
@@ -3206,7 +3211,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3206
3211
|
<slot></slot>
|
|
3207
3212
|
${r?'<button class="remove-btn" aria-label="Remove">×</button>':""}
|
|
3208
3213
|
</span>
|
|
3209
|
-
`}};
|
|
3214
|
+
`}};f("af-badge",Sn);Lb=Sn});var ja={};u(ja,{default:()=>Sb,AfriAvatar:()=>Rn});var Rn,Sb;var Ca=m(()=>{v();Rn=class Rn extends i{static get observedAttributes(){return["src","name","size","status","theme"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}_getInitials(t){if(!t)return"?";let n=t.trim().split(" ");if(n.length>=2)return(n[0][0]+n[n.length-1][0]).toUpperCase();return t.substring(0,2).toUpperCase()}render(){let t=this.getAttribute("src"),n=this.getAttribute("name")||"",r=this.getAttribute("size")||"md",o=this.getAttribute("status"),a=this.getAttribute("theme")||"tanzania",e={tanzania:"#1EB53A",maasai:"#FF0000",ndebele:"#4169E1",gold:"#FCD116"},l=e[a]||e.tanzania,b={sm:{size:"32px",font:"12px",status:"8px"},md:{size:"44px",font:"16px",status:"10px"},lg:{size:"64px",font:"22px",status:"14px"},xl:{size:"96px",font:"32px",status:"18px"}},d=b[r]||b.md,$={online:"#28a745",offline:"#6c757d",busy:"#dc3545",away:"#ffc107"};this.shadowRoot.innerHTML=`
|
|
3210
3215
|
<style>
|
|
3211
3216
|
:host {
|
|
3212
3217
|
display: inline-block;
|
|
@@ -3215,8 +3220,8 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3215
3220
|
|
|
3216
3221
|
.avatar {
|
|
3217
3222
|
position: relative;
|
|
3218
|
-
width: ${
|
|
3219
|
-
height: ${
|
|
3223
|
+
width: ${d.size};
|
|
3224
|
+
height: ${d.size};
|
|
3220
3225
|
border-radius: 50%;
|
|
3221
3226
|
display: flex;
|
|
3222
3227
|
align-items: center;
|
|
@@ -3224,7 +3229,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3224
3229
|
background: ${l};
|
|
3225
3230
|
color: white;
|
|
3226
3231
|
font-weight: 600;
|
|
3227
|
-
font-size: ${
|
|
3232
|
+
font-size: ${d.font};
|
|
3228
3233
|
overflow: hidden;
|
|
3229
3234
|
}
|
|
3230
3235
|
|
|
@@ -3238,8 +3243,8 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3238
3243
|
position: absolute;
|
|
3239
3244
|
bottom: 0;
|
|
3240
3245
|
right: 0;
|
|
3241
|
-
width: ${
|
|
3242
|
-
height: ${
|
|
3246
|
+
width: ${d.status};
|
|
3247
|
+
height: ${d.status};
|
|
3243
3248
|
border-radius: 50%;
|
|
3244
3249
|
border: 2px solid white;
|
|
3245
3250
|
background: ${o?$[o]||$.offline:"transparent"};
|
|
@@ -3250,7 +3255,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3250
3255
|
${t?`<img src="${t}" alt="${n}" />`:this._getInitials(n)}
|
|
3251
3256
|
${o?'<span class="status"></span>':""}
|
|
3252
3257
|
</div>
|
|
3253
|
-
`}};
|
|
3258
|
+
`}};f("af-avatar",Rn);Sb=Rn});var Ia={};u(Ia,{default:()=>Rb,AfriProgress:()=>Yn});var Yn,Rb;var Pa=m(()=>{v();Yn=class Yn extends i{static get observedAttributes(){return["value","max","theme","size","label","animated"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=parseFloat(this.getAttribute("value"))||0,n=parseFloat(this.getAttribute("max"))||100,r=this.getAttribute("theme")||"tanzania",o=this.getAttribute("size")||"md",a=this.getAttribute("label"),e=this.hasAttribute("animated"),l=Math.min(100,Math.max(0,t/n*100)),b={tanzania:{bar:"#1EB53A",track:"#e9ecef"},maasai:{bar:"#FF0000",track:"#e9ecef"},ndebele:{bar:"#4169E1",track:"#e9ecef"},gold:{bar:"#FCD116",track:"#e9ecef"},gradient:{bar:"linear-gradient(90deg, #1EB53A 0%, #FCD116 50%, #00A3DD 100%)",track:"#e9ecef"}},d=b[r]||b.tanzania,$={sm:"6px",md:"10px",lg:"16px"},E=$[o]||$.md;this.shadowRoot.innerHTML=`
|
|
3254
3259
|
<style>
|
|
3255
3260
|
:host {
|
|
3256
3261
|
display: block;
|
|
@@ -3279,8 +3284,8 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3279
3284
|
|
|
3280
3285
|
.progress-track {
|
|
3281
3286
|
width: 100%;
|
|
3282
|
-
height: ${
|
|
3283
|
-
background: ${
|
|
3287
|
+
height: ${E};
|
|
3288
|
+
background: ${d.track};
|
|
3284
3289
|
border-radius: 100px;
|
|
3285
3290
|
overflow: hidden;
|
|
3286
3291
|
}
|
|
@@ -3288,7 +3293,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3288
3293
|
.progress-bar {
|
|
3289
3294
|
height: 100%;
|
|
3290
3295
|
width: ${l}%;
|
|
3291
|
-
background: ${
|
|
3296
|
+
background: ${d.bar};
|
|
3292
3297
|
border-radius: 100px;
|
|
3293
3298
|
transition: width 500ms ease-out;
|
|
3294
3299
|
${e?`
|
|
@@ -3314,12 +3319,10 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3314
3319
|
</style>
|
|
3315
3320
|
|
|
3316
3321
|
<div class="progress-container">
|
|
3317
|
-
|
|
3318
|
-
<
|
|
3319
|
-
|
|
3320
|
-
|
|
3321
|
-
</div>
|
|
3322
|
-
`}
|
|
3322
|
+
<div class="progress-header">
|
|
3323
|
+
<span class="progress-label">${a||""}</span>
|
|
3324
|
+
<span class="progress-value">${l.toFixed(0)}%</span>
|
|
3325
|
+
</div>
|
|
3323
3326
|
<div class="progress-track">
|
|
3324
3327
|
<div class="progress-bar" role="progressbar"
|
|
3325
3328
|
aria-valuenow="${t}"
|
|
@@ -3327,7 +3330,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3327
3330
|
aria-valuemax="${n}"></div>
|
|
3328
3331
|
</div>
|
|
3329
3332
|
</div>
|
|
3330
|
-
`}};
|
|
3333
|
+
`}};f("af-progress",Yn);Rb=Yn});var Ta={};u(Ta,{default:()=>Yb,AfriLoader:()=>Xn});var Xn,Yb;var Za=m(()=>{v();Xn=class Xn extends i{static get observedAttributes(){return["size","color","type"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("size")||"40",n=this.getAttribute("color")||"currentColor",r=this.getAttribute("type")||"spiral",o={spiral:`M25,25 m0,-20 a20,20 0 1,1 0,40 a20,20 0 1,1 0,-40
|
|
3331
3334
|
M25,25 m0,-15 a15,15 0 1,0 0,30 a15,15 0 1,0 0,-30`,sun:"M25,5 L25,45 M5,25 L45,25 M11,11 L39,39 M39,11 L11,39",diamond:"M25,5 L45,25 L25,45 L5,25 Z"};this.shadowRoot.innerHTML=`
|
|
3332
3335
|
<style>
|
|
3333
3336
|
:host {
|
|
@@ -3358,7 +3361,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3358
3361
|
${r==="spiral"?`<path d="${o.spiral}" fill="none" stroke="currentColor" stroke-width="4" stroke-linecap="round" />`:r==="sun"?`<path d="${o.sun}" stroke="currentColor" stroke-width="4" stroke-linecap="round" />`:`<path d="${o.diamond}" fill="none" stroke="currentColor" stroke-width="4" />`}
|
|
3359
3362
|
</svg>
|
|
3360
3363
|
</div>
|
|
3361
|
-
`}};
|
|
3364
|
+
`}};f("af-loader",Xn);Yb=Xn});var za={};u(za,{default:()=>Xb,AfriSkeleton:()=>Fn});var Fn,Xb;var te=m(()=>{v();Fn=class Fn extends i{static get observedAttributes(){return["variant","width","height","lines"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("variant")||"text",n=this.getAttribute("width")||"100%",r=this.getAttribute("height")||"auto",o=parseInt(this.getAttribute("lines"))||1,a={text:{height:"16px",borderRadius:"4px"},title:{height:"28px",borderRadius:"4px"},avatar:{width:"48px",height:"48px",borderRadius:"50%"},card:{height:"200px",borderRadius:"12px"},button:{height:"40px",borderRadius:"6px",width:"120px"}},e=a[t]||a.text;this.shadowRoot.innerHTML=`
|
|
3362
3365
|
<style>
|
|
3363
3366
|
:host {
|
|
3364
3367
|
display: block;
|
|
@@ -3394,7 +3397,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3394
3397
|
</style>
|
|
3395
3398
|
|
|
3396
3399
|
${t==="text"||t==="title"?Array(o).fill(0).map(()=>'<div class="skeleton skeleton-line"></div>').join(""):`<div class="skeleton" style="width: ${e.width||n}; height: ${e.height||r};"></div>`}
|
|
3397
|
-
`}};
|
|
3400
|
+
`}};f("af-skeleton",Fn);Xb=Fn});var ne={};u(ne,{default:()=>Fb,AfriDivider:()=>Jn});var Jn,Fb;var oe=m(()=>{v();Jn=class Jn extends i{static get observedAttributes(){return["pattern","height","color","flip"]}constructor(){super();this.render()}attributeChangedCallback(){this.render()}_getPatternPath(t,n,r){switch(t||"zigzag"){case"zigzag":return`M0,${r} L${n/4},0 L${n/2},${r} L${n*0.75},0 L${n},${r} V${r+10} H0 Z`;case"waves":return`M0,${r/2} Q${n/4},0 ${n/2},${r/2} T${n},${r/2} V${r} H0 Z`;case"triangles":return`M0,${r} L${n/8},0 L${n/4},${r} L${n*0.375},0 L${n/2},${r}
|
|
3398
3401
|
L${n*0.625},0 L${n*0.75},${r} L${n*0.875},0 L${n},${r} V${r+10} H0 Z`;case"diamonds":return`M0,0 H${n} V${r/2}
|
|
3399
3402
|
L${n*0.9},${r} L${n*0.8},${r/2}
|
|
3400
3403
|
L${n*0.7},${r} L${n*0.6},${r/2}
|
|
@@ -3419,7 +3422,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3419
3422
|
<svg viewBox="0 0 100 ${n}" preserveAspectRatio="none">
|
|
3420
3423
|
<path d="${this._getPatternPath(t,100,parseInt(n))}" fill="currentColor" />
|
|
3421
3424
|
</svg>
|
|
3422
|
-
`}};
|
|
3425
|
+
`}};f("af-divider",Jn);Fb=Jn});function Jb(t,n,r=50,o=50){let a=[];for(let e=0;e<t;e++){let l=2*Math.PI*e/t-Math.PI/2,b=r+n*Math.cos(l),d=o+n*Math.sin(l);a.push(`${b.toFixed(2)},${d.toFixed(2)}`)}return a.join(" ")}function Bo({primaryColor:t="#FF0000",secondaryColor:n="#000000",backgroundColor:r="#8B0000",stripeWidth:o=4,size:a=40}={}){let e=`
|
|
3423
3426
|
<svg xmlns="http://www.w3.org/2000/svg" width="${a}" height="${a}" viewBox="0 0 ${a} ${a}">
|
|
3424
3427
|
<rect width="${a}" height="${a}" fill="${r}"/>
|
|
3425
3428
|
<rect x="0" y="0" width="${a}" height="${o}" fill="${t}" opacity="0.8"/>
|
|
@@ -3429,7 +3432,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3429
3432
|
<rect x="${a/2-o/2}" y="0" width="${o}" height="${a}" fill="${n}" opacity="0.4"/>
|
|
3430
3433
|
<rect x="${a-o}" y="0" width="${o}" height="${a}" fill="${t}" opacity="0.5"/>
|
|
3431
3434
|
</svg>
|
|
3432
|
-
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function
|
|
3435
|
+
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function Do({earthColor:t="#8B4513",ochreColor:n="#CD853F",charcoalColor:r="#2F2F2F",size:o=50}={}){let a=`
|
|
3433
3436
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3434
3437
|
<rect width="${o}" height="${o}" fill="${t}"/>
|
|
3435
3438
|
<!-- Cave art inspired figures -->
|
|
@@ -3444,7 +3447,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3444
3447
|
<circle cx="${o*0.15}" cy="${o*0.8}" r="3" fill="${n}"/>
|
|
3445
3448
|
<circle cx="${o*0.85}" cy="${o*0.2}" r="3" fill="${n}"/>
|
|
3446
3449
|
</svg>
|
|
3447
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3450
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Oo({primaryColor:t="#1EB53A",accentColor:n="#FCD116",size:r=30}={}){let o=`
|
|
3448
3451
|
<svg xmlns="http://www.w3.org/2000/svg" width="${r}" height="${r}" viewBox="0 0 ${r} ${r}">
|
|
3449
3452
|
<rect width="${r}" height="${r}" fill="${t}"/>
|
|
3450
3453
|
<!-- Pindo (Border) Motifs: Cashew/Triangle -->
|
|
@@ -3452,7 +3455,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3452
3455
|
<path d="M${r},0 L${r/2},${r/2} L${r},${r} Z" fill="${n}"/>
|
|
3453
3456
|
<circle cx="${r/2}" cy="${r/2}" r="${r*0.15}" fill="none" stroke="${n}" stroke-width="2"/>
|
|
3454
3457
|
</svg>
|
|
3455
|
-
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function
|
|
3458
|
+
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function Qb({primaryColor:t="#FF6B00",secondaryColor:n="#002B5C",backgroundColor:r="#FFFFFF",size:o=40}={}){let a=`
|
|
3456
3459
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3457
3460
|
<rect width="${o}" height="${o}" fill="${r}"/>
|
|
3458
3461
|
<!-- Border pattern -->
|
|
@@ -3464,7 +3467,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3464
3467
|
<circle cx="${o*0.5}" cy="${o*0.5}" r="${o*0.15}" fill="${n}"/>
|
|
3465
3468
|
<text x="${o*0.5}" y="${o*0.55}" text-anchor="middle" fill="${t}" font-size="${o*0.08}">KANGA</text>
|
|
3466
3469
|
</svg>
|
|
3467
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3470
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Gb({primaryColor:t="#8B4513",secondaryColor:n="#DAA520",backgroundColor:r="#F5F5DC",size:o=30}={}){let a=`
|
|
3468
3471
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3469
3472
|
<rect width="${o}" height="${o}" fill="${r}"/>
|
|
3470
3473
|
<!-- Kuba geometric border -->
|
|
@@ -3475,7 +3478,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3475
3478
|
<!-- Center diamond -->
|
|
3476
3479
|
<polygon points="${o*0.5},${o*0.3} ${o*0.7},${o*0.5} ${o*0.5},${o*0.7} ${o*0.3},${o*0.5}" fill="${n}"/>
|
|
3477
3480
|
</svg>
|
|
3478
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3481
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Bb({primaryColor:t="#FF0000",secondaryColor:n="#000000",accentColor:r="#FFFFFF",size:o=40}={}){let a=`
|
|
3479
3482
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3480
3483
|
<rect width="${o}" height="${o}" fill="${r}"/>
|
|
3481
3484
|
<!-- Bead pattern -->
|
|
@@ -3489,7 +3492,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3489
3492
|
<circle cx="${o*0.5}" cy="${o*0.8}" r="${o*0.08}" fill="${n}"/>
|
|
3490
3493
|
<circle cx="${o*0.8}" cy="${o*0.8}" r="${o*0.08}" fill="${t}"/>
|
|
3491
3494
|
</svg>
|
|
3492
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3495
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Db({primaryColor:t="#8B0000",secondaryColor:n="#FFD700",backgroundColor:r="#654321",size:o=50}={}){let a=`
|
|
3493
3496
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3494
3497
|
<ellipse cx="${o*0.5}" cy="${o*0.5}" rx="${o*0.4}" ry="${o*0.45}" fill="${r}"/>
|
|
3495
3498
|
<!-- Shield patterns -->
|
|
@@ -3499,7 +3502,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3499
3502
|
<line x1="${o*0.3}" y1="${o*0.2}" x2="${o*0.7}" y2="${o*0.2}" stroke="${t}" stroke-width="3"/>
|
|
3500
3503
|
<line x1="${o*0.3}" y1="${o*0.8}" x2="${o*0.7}" y2="${o*0.8}" stroke="${t}" stroke-width="3"/>
|
|
3501
3504
|
</svg>
|
|
3502
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3505
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Ob({primaryColor:t="#FF1493",secondaryColor:n="#00FF00",accentColor:r="#FFFF00",backgroundColor:o="#FFFFFF",size:a=50}={}){let e=`
|
|
3503
3506
|
<svg xmlns="http://www.w3.org/2000/svg" width="${a}" height="${a}" viewBox="0 0 ${a} ${a}">
|
|
3504
3507
|
<rect width="${a}" height="${a}" fill="${o}"/>
|
|
3505
3508
|
<!-- Ndebele geometric patterns -->
|
|
@@ -3511,7 +3514,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3511
3514
|
<circle cx="${a*0.5}" cy="${a*0.5}" r="${a*0.15}" fill="${n}"/>
|
|
3512
3515
|
<rect x="${a*0.45}" y="${a*0.45}" width="${a*0.1}" height="${a*0.1}" fill="${r}"/>
|
|
3513
3516
|
</svg>
|
|
3514
|
-
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function
|
|
3517
|
+
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function Wo({primaryColor:t="#00A3DD",secondaryColor:n="#FCD116",backgroundColor:r="#1EB53A",size:o=50}={}){let a=`
|
|
3515
3518
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3516
3519
|
<rect width="${o}" height="${o}" fill="${r}"/>
|
|
3517
3520
|
<circle cx="${o*0.25}" cy="${o*0.25}" r="${o*0.2}" fill="${t}" opacity="0.8"/>
|
|
@@ -3521,7 +3524,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3521
3524
|
<circle cx="${o*0.75}" cy="${o*0.25}" r="${o*0.08}" fill="${n}" opacity="0.6"/>
|
|
3522
3525
|
<circle cx="${o*0.25}" cy="${o*0.75}" r="${o*0.08}" fill="${n}" opacity="0.6"/>
|
|
3523
3526
|
</svg>
|
|
3524
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Uo({colors:t=["#FFD700","#228B22","#DC143C","#000000"],size:n=60}={}){let[r,o,a,e]=t,l=n/6,
|
|
3527
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Uo({colors:t=["#FFD700","#228B22","#DC143C","#000000"],size:n=60}={}){let[r,o,a,e]=t,l=n/6,b=`
|
|
3525
3528
|
<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}" viewBox="0 0 ${n} ${n}">
|
|
3526
3529
|
<rect width="${n}" height="${n}" fill="${e}"/>
|
|
3527
3530
|
<!-- Horizontal bands -->
|
|
@@ -3540,7 +3543,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3540
3543
|
<rect x="${n*0.1}" y="${n*0.1}" width="${n*0.15}" height="${n*0.15}" fill="${r}" stroke="${e}" stroke-width="1"/>
|
|
3541
3544
|
<rect x="${n*0.75}" y="${n*0.75}" width="${n*0.15}" height="${n*0.15}" fill="${a}" stroke="${e}" stroke-width="1"/>
|
|
3542
3545
|
</svg>
|
|
3543
|
-
`;return`data:image/svg+xml,${encodeURIComponent(
|
|
3546
|
+
`;return`data:image/svg+xml,${encodeURIComponent(b.trim())}`}function No({symbolColor:t="#000000",backgroundColor:n="#CD853F",size:r=50}={}){let o=`
|
|
3544
3547
|
<svg xmlns="http://www.w3.org/2000/svg" width="${r}" height="${r}" viewBox="0 0 ${r} ${r}">
|
|
3545
3548
|
<rect width="${r}" height="${r}" fill="${n}"/>
|
|
3546
3549
|
<!-- Sankofa-inspired heart shape (go back and get it) -->
|
|
@@ -3554,7 +3557,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3554
3557
|
<circle cx="${r*0.35}" cy="${r*0.45}" r="${r*0.08}" fill="none" stroke="${t}" stroke-width="2"/>
|
|
3555
3558
|
<circle cx="${r*0.65}" cy="${r*0.45}" r="${r*0.08}" fill="none" stroke="${t}" stroke-width="2"/>
|
|
3556
3559
|
</svg>
|
|
3557
|
-
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function
|
|
3560
|
+
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function yo({colors:t=["#4B0082","#FFD700","#FFFFFF"],size:n=50}={}){let[r,o,a]=t,e=n/10,l=`
|
|
3558
3561
|
<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}" viewBox="0 0 ${n} ${n}">
|
|
3559
3562
|
<rect width="${n}" height="${n}" fill="${r}"/>
|
|
3560
3563
|
<!-- Horizontal stripes -->
|
|
@@ -3571,7 +3574,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3571
3574
|
<polygon points="${n*0.75},${n*0.3} ${n*0.85},${n*0.5} ${n*0.75},${n*0.7} ${n*0.65},${n*0.5}"
|
|
3572
3575
|
fill="${o}" stroke="${a}" stroke-width="1"/>
|
|
3573
3576
|
</svg>
|
|
3574
|
-
`;return`data:image/svg+xml,${encodeURIComponent(l.trim())}`}function
|
|
3577
|
+
`;return`data:image/svg+xml,${encodeURIComponent(l.trim())}`}function Vo({primaryColor:t="#FF6B00",secondaryColor:n="#00A86B",accentColor:r="#FFD700",backgroundColor:o="#FFFFFF",size:a=60}={}){let e=`
|
|
3575
3578
|
<svg xmlns="http://www.w3.org/2000/svg" width="${a}" height="${a}" viewBox="0 0 ${a} ${a}">
|
|
3576
3579
|
<rect width="${a}" height="${a}" fill="${o}"/>
|
|
3577
3580
|
<!-- Bold circular motifs -->
|
|
@@ -3590,7 +3593,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3590
3593
|
<circle cx="${a*0.1}" cy="${a*0.8}" r="${a*0.05}" fill="${r}"/>
|
|
3591
3594
|
<circle cx="${a*0.9}" cy="${a*0.2}" r="${a*0.05}" fill="${r}"/>
|
|
3592
3595
|
</svg>
|
|
3593
|
-
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function
|
|
3596
|
+
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function Ko({primaryColor:t="#000000",secondaryColor:n="#FFFFFF",accentColor:r="#8B4513",size:o=60}={}){let a=`
|
|
3594
3597
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3595
3598
|
<rect width="${o}" height="${o}" fill="${t}"/>
|
|
3596
3599
|
<!-- Zigzags -->
|
|
@@ -3606,7 +3609,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3606
3609
|
<!-- Dots -->
|
|
3607
3610
|
<circle cx="${o*0.5}" cy="${o*0.5}" r="${o*0.08}" fill="${r}"/>
|
|
3608
3611
|
</svg>
|
|
3609
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3612
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function jo({primaryColor:t="#D2B48C",secondaryColor:n="#3E2723",size:r=60}={}){let o=`
|
|
3610
3613
|
<svg xmlns="http://www.w3.org/2000/svg" width="${r}" height="${r}" viewBox="0 0 ${r} ${r}">
|
|
3611
3614
|
<rect width="${r}" height="${r}" fill="${t}"/>
|
|
3612
3615
|
<!-- Interlocking diamonds/rectangles -->
|
|
@@ -3620,7 +3623,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3620
3623
|
<line x1="${r*0.4}" y1="${r*0.5}" x2="${r*0.6}" y2="${r*0.5}" stroke="${n}" stroke-width="2"/>
|
|
3621
3624
|
<line x1="${r*0.5}" y1="${r*0.4}" x2="${r*0.5}" y2="${r*0.6}" stroke="${n}" stroke-width="2"/>
|
|
3622
3625
|
</svg>
|
|
3623
|
-
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function
|
|
3626
|
+
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function Co({primaryColor:t="#000000",secondaryColor:n="#FFFFFF",accentColor:r="#B22222",size:o=60}={}){let a=`
|
|
3624
3627
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3625
3628
|
<rect width="${o}" height="${o}" fill="${n}"/>
|
|
3626
3629
|
<!-- Spiral/Diamond Motif -->
|
|
@@ -3636,7 +3639,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3636
3639
|
fill="${n}"/>
|
|
3637
3640
|
<circle cx="${o*0.5}" cy="${o*0.5}" r="${o*0.1}" fill="${r}"/>
|
|
3638
3641
|
</svg>
|
|
3639
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3642
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Io({colors:t=["#009E60","#FCDD09","#EF3340"],backgroundColor:n="#FFFFFF",size:r=40}={}){let[o,a,e]=t,l=`
|
|
3640
3643
|
<svg xmlns="http://www.w3.org/2000/svg" width="${r}" height="${r}" viewBox="0 0 ${r} ${r}">
|
|
3641
3644
|
<rect width="${r}" height="${r}" fill="${n}"/>
|
|
3642
3645
|
<!-- Diamond Chain -->
|
|
@@ -3649,7 +3652,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3649
3652
|
<line x1="0" y1="0" x2="0" y2="${r}" stroke="${o}" stroke-width="4"/>
|
|
3650
3653
|
<line x1="${r}" y1="0" x2="${r}" y2="${r}" stroke="${o}" stroke-width="4"/>
|
|
3651
3654
|
</svg>
|
|
3652
|
-
`;return`data:image/svg+xml,${encodeURIComponent(l.trim())}`}function
|
|
3655
|
+
`;return`data:image/svg+xml,${encodeURIComponent(l.trim())}`}function Po({colors:t=["#FFD700","#4169E1","#FF69B4","#228B22"],size:n=60,strokeWidth:r=2}={}){let[o,a,e,l]=t,b=`
|
|
3653
3656
|
<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}" viewBox="0 0 ${n} ${n}">
|
|
3654
3657
|
<rect width="${n}" height="${n}" fill="#FFFFFF"/>
|
|
3655
3658
|
<rect x="${r}" y="${r}"
|
|
@@ -3666,7 +3669,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3666
3669
|
<polygon points="${n/2},${n*0.3} ${n*0.7},${n/2} ${n/2},${n*0.7} ${n*0.3},${n/2}"
|
|
3667
3670
|
fill="#FFFFFF" stroke="#000000" stroke-width="${r}"/>
|
|
3668
3671
|
</svg>
|
|
3669
|
-
`;return`data:image/svg+xml,${encodeURIComponent(
|
|
3672
|
+
`;return`data:image/svg+xml,${encodeURIComponent(b.trim())}`}function To({colors:t=["#FFFFFF","#000000","#FF0000","#00A86B","#FFD700"],size:n=50}={}){let[r,o,a,e,l]=t,b=n/10,d=`
|
|
3670
3673
|
<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}" viewBox="0 0 ${n} ${n}">
|
|
3671
3674
|
<rect width="${n}" height="${n}" fill="${o}"/>
|
|
3672
3675
|
<!-- Triangle pattern (isivivane - sacred cairn) -->
|
|
@@ -3675,15 +3678,15 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3675
3678
|
<polygon points="${n*0.5},${n*0.25} ${n*0.75},${n*0.75} ${n*0.25},${n*0.75}"
|
|
3676
3679
|
fill="${a}"/>
|
|
3677
3680
|
<!-- Beadwork dots -->
|
|
3678
|
-
<circle cx="${n*0.5}" cy="${n*0.35}" r="${
|
|
3679
|
-
<circle cx="${n*0.35}" cy="${n*0.6}" r="${
|
|
3680
|
-
<circle cx="${n*0.65}" cy="${n*0.6}" r="${
|
|
3681
|
-
<circle cx="${n*0.5}" cy="${n*0.8}" r="${
|
|
3681
|
+
<circle cx="${n*0.5}" cy="${n*0.35}" r="${b}" fill="${r}"/>
|
|
3682
|
+
<circle cx="${n*0.35}" cy="${n*0.6}" r="${b}" fill="${e}"/>
|
|
3683
|
+
<circle cx="${n*0.65}" cy="${n*0.6}" r="${b}" fill="${l}"/>
|
|
3684
|
+
<circle cx="${n*0.5}" cy="${n*0.8}" r="${b}" fill="${r}"/>
|
|
3682
3685
|
<!-- Border dots -->
|
|
3683
|
-
<circle cx="${n*0.1}" cy="${n*0.1}" r="${
|
|
3684
|
-
<circle cx="${n*0.9}" cy="${n*0.1}" r="${
|
|
3686
|
+
<circle cx="${n*0.1}" cy="${n*0.1}" r="${b*0.7}" fill="${a}"/>
|
|
3687
|
+
<circle cx="${n*0.9}" cy="${n*0.1}" r="${b*0.7}" fill="${e}"/>
|
|
3685
3688
|
</svg>
|
|
3686
|
-
`;return`data:image/svg+xml,${encodeURIComponent(
|
|
3689
|
+
`;return`data:image/svg+xml,${encodeURIComponent(d.trim())}`}function Zo({colors:t=["#3E5EB9","#FECD00","#B10C0C","#FFFFFF"],size:n=50}={}){let[r,o,a,e]=t,l=`
|
|
3687
3690
|
<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}" viewBox="0 0 ${n} ${n}">
|
|
3688
3691
|
<rect width="${n}" height="${n}" fill="${r}"/>
|
|
3689
3692
|
<!-- Shield shape (central to Eswatini culture) -->
|
|
@@ -3703,7 +3706,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3703
3706
|
<polygon points="${n*0.1},${n*0.3} ${n*0.05},${n*0.5} ${n*0.15},${n*0.5}" fill="${e}"/>
|
|
3704
3707
|
<polygon points="${n*0.9},${n*0.3} ${n*0.85},${n*0.5} ${n*0.95},${n*0.5}" fill="${e}"/>
|
|
3705
3708
|
</svg>
|
|
3706
|
-
`;return`data:image/svg+xml,${encodeURIComponent(l.trim())}`}function
|
|
3709
|
+
`;return`data:image/svg+xml,${encodeURIComponent(l.trim())}`}function zo({primaryColor:t="#FFFFFF",accentColor:n="#00A86B",backgroundColor:r="#1a1a2e",size:o=50}={}){let a=`
|
|
3707
3710
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3708
3711
|
<rect width="${o}" height="${o}" fill="${r}"/>
|
|
3709
3712
|
<!-- Horizontal bands -->
|
|
@@ -3721,7 +3724,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3721
3724
|
<polygon points="0,${o} ${o*0.15},${o} 0,${o*0.85}" fill="${n}"/>
|
|
3722
3725
|
<polygon points="${o},${o} ${o*0.85},${o} ${o},${o*0.85}" fill="${n}"/>
|
|
3723
3726
|
</svg>
|
|
3724
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3727
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Wb(t,n){t.style.backgroundImage=`url("${n}")`,t.style.backgroundRepeat="repeat"}function tr({primaryColor:t="#8B0000",secondaryColor:n="#000000",accentColor:r="#FFD700",backgroundColor:o="#F5F5DC",size:a=60}={}){let e=`
|
|
3725
3728
|
<svg xmlns="http://www.w3.org/2000/svg" width="${a}" height="${a}" viewBox="0 0 ${a} ${a}">
|
|
3726
3729
|
<rect width="${a}" height="${a}" fill="${o}"/>
|
|
3727
3730
|
<!-- Lozenge (Diamond) - universal protective symbol -->
|
|
@@ -3734,7 +3737,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3734
3737
|
<line x1="${a*0.4}" y1="${a*0.4}" x2="${a*0.6}" y2="${a*0.6}" stroke="${n}" stroke-width="2"/>
|
|
3735
3738
|
<line x1="${a*0.6}" y1="${a*0.4}" x2="${a*0.4}" y2="${a*0.6}" stroke="${n}" stroke-width="2"/>
|
|
3736
3739
|
</svg>
|
|
3737
|
-
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function
|
|
3740
|
+
`;return`data:image/svg+xml,${encodeURIComponent(e.trim())}`}function nr({primaryColor:t="#4B0082",secondaryColor:n="#8A2BE2",accentColor:r="#FFFFFF",size:o=50}={}){let a=`
|
|
3738
3741
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3739
3742
|
<rect width="${o}" height="${o}" fill="${t}"/>
|
|
3740
3743
|
<!-- Resist circles (Oniko) -->
|
|
@@ -3745,7 +3748,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3745
3748
|
<path d="M0,0 Q${o*0.2},0 ${o*0.2},${o*0.2} Q0,${o*0.2} 0,0" fill="${n}"/>
|
|
3746
3749
|
<path d="M${o},${o} Q${o*0.8},${o} ${o*0.8},${o*0.8} Q${o},${o*0.8} ${o},${o}" fill="${n}"/>
|
|
3747
3750
|
</svg>
|
|
3748
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3751
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Ub({primaryColor:t="#2D3D6B",secondaryColor:n="#6B8CC7",accentColor:r="#FFFFFF",size:o=60}={}){let a=`
|
|
3749
3752
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3750
3753
|
<rect width="${o}" height="${o}" fill="${t}"/>
|
|
3751
3754
|
<!-- Southern Cross / Tuareg Star -->
|
|
@@ -3753,7 +3756,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3753
3756
|
fill="none" stroke="${r}" stroke-width="2"/>
|
|
3754
3757
|
<circle cx="${o*0.5}" cy="${o*0.5}" r="${o*0.1}" fill="${n}"/>
|
|
3755
3758
|
</svg>
|
|
3756
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3759
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Nb({inkColor:t="#3A2E2C",parchmentColor:n="#F4E4BC",size:r=50}={}){let o=`
|
|
3757
3760
|
<svg xmlns="http://www.w3.org/2000/svg" width="${r}" height="${r}" viewBox="0 0 ${r} ${r}">
|
|
3758
3761
|
<rect width="${r}" height="${r}" fill="${n}"/>
|
|
3759
3762
|
<path d="M${r*0.2} ${r*0.2} L${r*0.4} ${r*0.2} M${r*0.3} ${r*0.2} L${r*0.3} ${r*0.5} Q${r*0.4} ${r*0.6} ${r*0.2} ${r*0.7}"
|
|
@@ -3761,13 +3764,13 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3761
3764
|
<path d="M${r*0.6} ${r*0.3} C${r*0.8} ${r*0.3} ${r*0.8} ${r*0.6} ${r*0.6} ${r*0.6} L${r*0.8} ${r*0.8}"
|
|
3762
3765
|
fill="none" stroke="${t}" stroke-width="3" stroke-linecap="round"/>
|
|
3763
3766
|
</svg>
|
|
3764
|
-
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function
|
|
3767
|
+
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function yb({clayColor:t="#4E342E",earthColor:n="#3E2723",accentColor:r="#BCAAA4",size:o=60}={}){let a=`
|
|
3765
3768
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3766
3769
|
<rect width="${o}" height="${o}" fill="${n}"/>
|
|
3767
3770
|
<path d="M${o*0.2} ${o*0.5} Q${o*0.3} ${o*0.2} ${o*0.5} ${o*0.3} T${o*0.8} ${o*0.5} Q${o*0.7} ${o*0.8} ${o*0.5} ${o*0.7} T${o*0.2} ${o*0.5}"
|
|
3768
3771
|
fill="${t}" stroke="${r}" stroke-width="2"/>
|
|
3769
3772
|
</svg>
|
|
3770
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3773
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function re({primaryColor:t="#334155",secondaryColor:n="#1e293b",size:r=100}={}){let o=`
|
|
3771
3774
|
<svg xmlns="http://www.w3.org/2000/svg" width="${r}" height="${r}" viewBox="0 0 100 100">
|
|
3772
3775
|
<rect width="100" height="100" fill="${n}"/>
|
|
3773
3776
|
<path d="M10 10 H90 V90 H10 Z" fill="none" stroke="${t}" stroke-width="0.5" opacity="0.3"/>
|
|
@@ -3776,7 +3779,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3776
3779
|
<circle cx="80" cy="80" r="2" fill="${t}"/>
|
|
3777
3780
|
<circle cx="50" cy="50" r="1.5" fill="${t}"/>
|
|
3778
3781
|
</svg>
|
|
3779
|
-
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function
|
|
3782
|
+
`;return`data:image/svg+xml,${encodeURIComponent(o.trim())}`}function Vb({primaryColor:t="#000000",secondaryColor:n="#FCD116",backgroundColor:r="#FFFFFF",size:o=50}={}){let a=`
|
|
3780
3783
|
|
|
3781
3784
|
<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}">
|
|
3782
3785
|
|
|
@@ -3802,7 +3805,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3802
3805
|
|
|
3803
3806
|
</svg>
|
|
3804
3807
|
|
|
3805
|
-
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function
|
|
3808
|
+
`;return`data:image/svg+xml,${encodeURIComponent(a.trim())}`}function Kb({colors:t=["#000000","#FCD116","#E82127","#006B3F"],size:n=60}={}){let[r,o,a,e]=t,l=n/6,b=`
|
|
3806
3809
|
|
|
3807
3810
|
<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}" viewBox="0 0 ${n} ${n}">
|
|
3808
3811
|
|
|
@@ -3836,7 +3839,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3836
3839
|
|
|
3837
3840
|
</svg>
|
|
3838
3841
|
|
|
3839
|
-
`;return`data:image/svg+xml,${encodeURIComponent(
|
|
3842
|
+
`;return`data:image/svg+xml,${encodeURIComponent(b.trim())}`}var Qn;var Gn=m(()=>{Qn={generatePolygon:Jb,generateShuka:Bo,generateHadzabe:Do,generateKanga:Qb,generateKangaBorder:Oo,generateKitenge:Wo,generateMasaiShield:Db,generateTibeb:Io,generateImigongo:Co,generateKente:Uo,generateAdinkra:No,generateAsoOke:yo,generateAnkara:Vo,generateBogolan:Ko,generateAdire:nr,generateKuba:jo,generateKubaBorder:Gb,generateBerber:tr,generateNdebele:Po,generateNdebelePaint:Ob,generateZulu:To,generateZuluBeads:Bb,generateSwazi:Zo,generateXhosa:zo,generateYorubaAdire:Vb,generateAkanKente:Kb,applyPattern:Wb,generateTuareg:Ub,generateGeez:Nb,generateBoli:yb,generateCircuit:re,circuit:re}});var ae={};u(ae,{default:()=>Cb,KangaCard:()=>Bn});var Bn,Cb;var ee=m(()=>{v();Gn();Bn=class Bn extends i{static get observedAttributes(){return["theme","proverb","proverb-translation"]}constructor(){super();this.render()}connectedCallback(){this.loadStyles(),this.applyTheme()}attributeChangedCallback(t,n,r){if(n!==r)if(t==="theme")this.applyTheme();else this.render()}getThemeColors(){let t=this.getAttribute("theme")||"tanzania",n={tanzania:{primary:"#1EB53A",accent:"#FCD116",border:"#00A3DD",text:"#000000"},maasai:{primary:"#8B0000",accent:"#FF0000",border:"#000000",text:"#FFFFFF"},ndebele:{primary:"#4169E1",accent:"#FFD700",border:"#FF69B4",text:"#000000"}};return n[t]||n.tanzania}applyTheme(){let t=this.getThemeColors(),n=this.shadowRoot.querySelector(".pindo");if(n){let r=Qn.generateKangaBorder({primaryColor:t.primary,accentColor:t.accent});n.style.backgroundImage=`url("${r}")`,n.style.backgroundRepeat="repeat"}}render(){let t=this.getAttribute("proverb")||"",n=this.getAttribute("proverb-translation")||"",r=this.getThemeColors();this.shadowRoot.innerHTML=`
|
|
3840
3843
|
<style>
|
|
3841
3844
|
:host {
|
|
3842
3845
|
display: block;
|
|
@@ -3918,7 +3921,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
3918
3921
|
</div>
|
|
3919
3922
|
`:'<div class="jina"><slot name="proverb"></slot></div>'}
|
|
3920
3923
|
</article>
|
|
3921
|
-
`,this.applyTheme()}};
|
|
3924
|
+
`,this.applyTheme()}};f("af-kanga-card",Bn);Cb=Bn});var le={};u(le,{default:()=>Ib,CulturalCard:()=>Dn});var Dn,Ib;var be=m(()=>{v();Gn();Dn=class Dn extends i{static get observedAttributes(){return["culture","interactive"]}constructor(){super();this._cultures={maasai:{name:"Maasai",region:"Tanzania/Kenya",pattern:"generateShuka",colors:{primary:"#FF0000",accent:"#000000"}},hadzabe:{name:"Hadzabe",region:"Tanzania",pattern:"generateHadzabe",colors:{primary:"#8B4513",accent:"#CD853F"}},swahili:{name:"Swahili",region:"East Africa",pattern:"generateKangaBorder",colors:{primary:"#1EB53A",accent:"#FCD116"}},kitenge:{name:"Kitenge",region:"East Africa",pattern:"generateKitenge",colors:{primary:"#00A3DD",accent:"#1EB53A"}},tibeb:{name:"Tibeb",region:"Ethiopia",pattern:"generateTibeb",colors:{primary:"#009E60",accent:"#FCDD09"}},ashanti:{name:"Ashanti/Akan",region:"Ghana",pattern:"generateKente",colors:{primary:"#FFD700",accent:"#228B22"}},adinkra:{name:"Adinkra",region:"Ghana",pattern:"generateAdinkra",colors:{primary:"#000000",accent:"#CD853F"}},bogolan:{name:"Bogolan",region:"Mali",pattern:"generateBogolan",colors:{primary:"#3E2723",accent:"#D7CCC8"}},yoruba:{name:"Yoruba",region:"Nigeria",pattern:"generateAsoOke",colors:{primary:"#4B0082",accent:"#FFD700"}},ankara:{name:"Ankara",region:"West Africa",pattern:"generateAnkara",colors:{primary:"#FF6B00",accent:"#00A86B"}},kuba:{name:"Kuba Shoowa",region:"DRC",pattern:"generateKuba",colors:{primary:"#D2B48C",accent:"#3E2723"}},imigongo:{name:"Imigongo",region:"Rwanda",pattern:"generateImigongo",colors:{primary:"#000000",accent:"#B22222"}},ndebele:{name:"Ndebele",region:"South Africa",pattern:"generateNdebele",colors:{primary:"#4169E1",accent:"#FFD700"}},zulu:{name:"Zulu",region:"South Africa",pattern:"generateZulu",colors:{primary:"#FF0000",accent:"#000000"}},swazi:{name:"Swazi",region:"Eswatini",pattern:"generateSwazi",colors:{primary:"#3E5EB9",accent:"#FECD00"}},xhosa:{name:"Xhosa",region:"South Africa",pattern:"generateXhosa",colors:{primary:"#00A86B",accent:"#1a1a2e"}}},this.render()}connectedCallback(){this._setupInteraction()}_setupInteraction(){if(!this.hasAttribute("interactive"))return;this.shadowRoot.querySelector(".culture-selector")?.addEventListener("change",(n)=>{this.setAttribute("culture",n.target.value),this.emit("af-culture-change",{culture:n.target.value})})}attributeChangedCallback(){this.render(),this._setupInteraction()}render(){let t=this.getAttribute("culture")||"maasai",n=this.hasAttribute("interactive"),r=this._cultures[t]||this._cultures.maasai,o=Qn[r.pattern],a=o?o():"";this.shadowRoot.innerHTML=`
|
|
3922
3925
|
<style>
|
|
3923
3926
|
:host {
|
|
3924
3927
|
display: block;
|
|
@@ -4083,7 +4086,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
4083
4086
|
`:""}
|
|
4084
4087
|
</div>
|
|
4085
4088
|
</article>
|
|
4086
|
-
`}};
|
|
4089
|
+
`}};f("af-cultural-card",Dn);Ib=Dn});var ie={};u(ie,{default:()=>Pb,PatternShowcase:()=>On});var On,Pb;var fe=m(()=>{v();Gn();On=class On extends i{static get observedAttributes(){return["region","size"]}constructor(){super();this._allPatterns=[{key:"shuka",name:"Maasai Shuka",region:"east",country:"Tanzania/Kenya",fn:Bo,meaning:"Bravery, Unity, Identity"},{key:"hadzabe",name:"Hadzabe",region:"east",country:"Tanzania",fn:Do,meaning:"Ancient traditions, Hunter-gatherer heritage"},{key:"kanga",name:"Kanga",region:"east",country:"Tanzania/Kenya",fn:Oo,meaning:"Communication, Proverbs, Femininity"},{key:"kitenge",name:"Kitenge",region:"east",country:"East Africa",fn:Wo,meaning:"Celebration, African identity"},{key:"tibeb",name:"Tibeb",region:"east",country:"Ethiopia",fn:Io,meaning:"Faith, Tradition, Celebration"},{key:"kente",name:"Kente",region:"west",country:"Ghana",fn:Uo,meaning:"Royalty, Wisdom, Celebration"},{key:"adinkra",name:"Adinkra",region:"west",country:"Ghana",fn:No,meaning:"Philosophy, Proverbs, Wisdom"},{key:"bogolan",name:"Bogolan",region:"west",country:"Mali",fn:Ko,meaning:"Earth energy, Protection, Healing"},{key:"asooke",name:"Aso-Oke",region:"west",country:"Nigeria",fn:yo,meaning:"Prestige, Celebration, Heritage"},{key:"adire",name:"Adire (Indigo)",region:"west",country:"Nigeria",fn:nr,meaning:"Creativity, Uniqueness, Depth"},{key:"ankara",name:"Ankara",region:"west",country:"West Africa",fn:Vo,meaning:"Boldness, Pan-African pride"},{key:"kuba",name:"Kuba Shoowa",region:"central",country:"DRC",fn:jo,meaning:"Status, Mathematics, Eternity"},{key:"imigongo",name:"Imigongo",region:"central",country:"Rwanda",fn:Co,meaning:"Resilience, Strength, Artistry"},{key:"berber",name:"Berber",region:"north",country:"North Africa",fn:tr,meaning:"Protection, Nature, Identity"},{key:"ndebele",name:"Ndebele",region:"south",country:"South Africa",fn:Po,meaning:"Artistry, Marriage, Status"},{key:"zulu",name:"Zulu Beadwork",region:"south",country:"South Africa",fn:To,meaning:"Love letters, Community"},{key:"swazi",name:"Swazi",region:"south",country:"Eswatini",fn:Zo,meaning:"Monarchy, Warriors, Pride"},{key:"xhosa",name:"Xhosa",region:"south",country:"South Africa",fn:zo,meaning:"Dignity, Coming of age"}],this.render()}connectedCallback(){this._setupHovers()}_setupHovers(){this.shadowRoot.querySelectorAll(".pattern-item").forEach((t)=>{t.addEventListener("click",()=>{let n=t.dataset.key,r=this._allPatterns.find((o)=>o.key===n);if(r)this.emit("af-pattern-select",{pattern:r})})})}attributeChangedCallback(){this.render(),this._setupHovers()}render(){let t=this.getAttribute("region")||"all",n=this.getAttribute("size")||"md",r=t==="all"?this._allPatterns:this._allPatterns.filter((e)=>e.region===t),o={sm:80,md:120,lg:160},a=o[n]||o.md;this.shadowRoot.innerHTML=`
|
|
4087
4090
|
<style>
|
|
4088
4091
|
:host {
|
|
4089
4092
|
display: block;
|
|
@@ -4216,7 +4219,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
4216
4219
|
`).join("")}
|
|
4217
4220
|
</div>
|
|
4218
4221
|
</div>
|
|
4219
|
-
`,this.shadowRoot.querySelectorAll(".region-tab").forEach((e)=>{e.addEventListener("click",()=>{this.setAttribute("region",e.dataset.region)})})}};
|
|
4222
|
+
`,this.shadowRoot.querySelectorAll(".region-tab").forEach((e)=>{e.addEventListener("click",()=>{this.setAttribute("region",e.dataset.region)})})}};f("af-pattern-showcase",On);Pb=On});var de={};u(de,{AfriLanguageSwitcher:()=>or});var or;var ce=m(()=>{v();or=class or extends i{static get observedAttributes(){return["current"]}render(){let t=[{code:"en",name:"English"},{code:"sw",name:"Kiswahili"},{code:"fr",name:"Français"},{code:"ar",name:"العربية",dir:"rtl"},{code:"am",name:"አማርኛ"},{code:"yo",name:"Yorùbá"}],n=this.getAttribute("current")||"en",r=t.find((o)=>o.code===n)||t[0];this.shadowRoot.innerHTML=g`
|
|
4220
4223
|
<style>
|
|
4221
4224
|
:host { display: inline-block; position: relative; font-family: var(--font-body); }
|
|
4222
4225
|
.switcher-btn {
|
|
@@ -4267,7 +4270,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
4267
4270
|
</div>
|
|
4268
4271
|
`)}
|
|
4269
4272
|
</div>
|
|
4270
|
-
`,this.shadowRoot.querySelector(".switcher-btn").onclick=()=>{this.toggleAttribute("open")},this.shadowRoot.querySelectorAll(".lang-option").forEach((o)=>{o.onclick=()=>{let a=o.dataset.code;if(this.setAttribute("current",a),this.removeAttribute("open"),this.emit("lang-change",{code:a}),a==="ar")document.documentElement.dir="rtl";else document.documentElement.dir="ltr"}})}connectedCallback(){this.render()}attributeChangedCallback(){this.render()}};
|
|
4273
|
+
`,this.shadowRoot.querySelector(".switcher-btn").onclick=()=>{this.toggleAttribute("open")},this.shadowRoot.querySelectorAll(".lang-option").forEach((o)=>{o.onclick=()=>{let a=o.dataset.code;if(this.setAttribute("current",a),this.removeAttribute("open"),this.emit("lang-change",{code:a}),a==="ar")document.documentElement.dir="rtl";else document.documentElement.dir="ltr"}})}connectedCallback(){this.render()}attributeChangedCallback(){this.render()}};f("af-language-switcher",or)});var he={};u(he,{AfriAuth:()=>rr});var rr;var ge=m(()=>{v();rr=class rr extends i{constructor(){super();this.mode="login"}connectedCallback(){this.render(),this.setupEvents()}setupEvents(){let t=this.shadowRoot.querySelector("form"),n=this.shadowRoot.querySelector(".toggle-mode");if(n)n.addEventListener("click",(r)=>{r.preventDefault(),this.mode=this.mode==="login"?"register":"login",this.render(),this.setupEvents()});if(t)t.addEventListener("submit",async(r)=>{r.preventDefault();let o=this.shadowRoot.querySelector("#email").value,a=this.shadowRoot.querySelector("#password").value,e=this.shadowRoot.querySelector(".feedback");e.textContent="Processing...";try{let b=await(await fetch("/api/auth",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:this.mode,email:o,password:a})})).json();if(b.error)e.textContent=b.error,e.style.color="#ef4444";else e.textContent="Success! Redirecting...",e.style.color="#22c55e",setTimeout(()=>window.location.href="/",1000)}catch{e.textContent="Network Error"}})}render(){let t=this.mode==="login";this.shadowRoot.innerHTML=`
|
|
4271
4274
|
<style>
|
|
4272
4275
|
:host {
|
|
4273
4276
|
display: block;
|
|
@@ -4365,7 +4368,7 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
4365
4368
|
<span class="toggle-mode">${t?"Create an account":"Sign in"}</span>
|
|
4366
4369
|
</div>
|
|
4367
4370
|
</div>
|
|
4368
|
-
`}};
|
|
4371
|
+
`}};f("af-auth",rr)});var me={};u(me,{default:()=>Tb});var ar,Tb;var se=m(()=>{v();ar=class ar extends i{constructor(){super();this.currentTheme="dark"}connectedCallback(){this.loadStyles();let t=localStorage.getItem("africode-theme");if(t)this.currentTheme=t,document.documentElement.setAttribute("data-theme",t);else{let n=window.matchMedia("(prefers-color-scheme: light)").matches;this.currentTheme=n?"light":"dark",document.documentElement.setAttribute("data-theme",this.currentTheme)}this.render()}toggleTheme(){this.currentTheme=this.currentTheme==="dark"?"light":"dark",document.documentElement.setAttribute("data-theme",this.currentTheme),localStorage.setItem("africode-theme",this.currentTheme),window.dispatchEvent(new CustomEvent("theme-changed",{detail:{theme:this.currentTheme}})),this.render()}render(){let t=this.currentTheme==="dark";this.shadowRoot.innerHTML=g`
|
|
4369
4372
|
<style>
|
|
4370
4373
|
.toggle-btn {
|
|
4371
4374
|
background: var(--bg-surface-elevated, var(--afri-obsidian));
|
|
@@ -4390,11 +4393,11 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
4390
4393
|
}
|
|
4391
4394
|
</style>
|
|
4392
4395
|
|
|
4393
|
-
<button class="toggle-btn"
|
|
4394
|
-
<span class="icon"
|
|
4395
|
-
<span
|
|
4396
|
+
<button class="toggle-btn">
|
|
4397
|
+
<span class="icon">${t?"\uD83C\uDF19":"☀️"}</span>
|
|
4398
|
+
<span>${t?"Dark Mode":"Light Mode"}</span>
|
|
4396
4399
|
</button>
|
|
4397
|
-
`;let n=this.shadowRoot.querySelector(".toggle-btn");if(n)n.addEventListener("click",()=>this.toggleTheme())}};
|
|
4400
|
+
`;let n=this.shadowRoot.querySelector(".toggle-btn");if(n)n.addEventListener("click",()=>this.toggleTheme())}};f("af-theme-toggle",ar);Tb=ar});v();v();class yn extends i{static get observedAttributes(){return["theme","fallback-message"]}constructor(){super();this._hasError=!1,this._errorDetail=null,this.render()}connectedCallback(){this.addEventListener("af-component-error",this._handleError.bind(this))}disconnectedCallback(){this.removeEventListener("af-component-error",this._handleError.bind(this))}_handleError(t){t.stopPropagation(),this._hasError=!0,this._errorDetail=t.detail,console.warn("[AfriCode Boundary] Caught error:",this._errorDetail),this.render()}reset(){this._hasError=!1,this._errorDetail=null,this.render()}attributeChangedCallback(){this.render()}render(){let t=this.getAttribute("theme")||"tanzania",n=this.getAttribute("fallback-message")||"A part of this page failed to load.",r={tanzania:{bg:"#FFF9E6",border:"#FCD116",text:"#5A4A00"},maasai:{bg:"#FFEEEE",border:"#FF0000",text:"#8B0000"},ndebele:{bg:"#EBF0FF",border:"#4169E1",text:"#002B5C"},ocean:{bg:"#E6FAFF",border:"#00A3DD",text:"#004A66"}},o=r[t]||r.tanzania;if(this._hasError){this.shadowRoot.innerHTML=`
|
|
4398
4401
|
<style>
|
|
4399
4402
|
:host { display: block; width: 100%; font-family: 'Inter', system-ui, sans-serif; }
|
|
4400
4403
|
.boundary-error {
|
|
@@ -4465,6 +4468,6 @@ var me=Object.defineProperty;var pe=(t)=>t;function ve(t,n){this[t]=pe.bind(null
|
|
|
4465
4468
|
`,this.shadowRoot.getElementById("retry-btn").addEventListener("click",()=>{this.reset()});return}this.shadowRoot.innerHTML=`
|
|
4466
4469
|
<style>:host { display: block; }</style>
|
|
4467
4470
|
<slot></slot>
|
|
4468
|
-
`}}
|
|
4471
|
+
`}}f("af-error-boundary",yn);Vn();Kn();jn();Cn();In();Pn();Tn();Zn();zn();to();no();oo();ro();eo();lo();bo();io();fo();co();ho();go();mo();so();po();vo();uo();$o();wo();_o();ko();qo();var Zb={"af-button":()=>Promise.resolve().then(() => (Or(),Dr)),"af-card":()=>Promise.resolve().then(() => (Ur(),Wr)),"af-navbar":()=>Promise.resolve().then(() => (yr(),Nr)),"af-input":()=>Promise.resolve().then(() => (fa(),ia)),"af-alert":()=>Promise.resolve().then(() => (ca(),da)),"af-grid":()=>Promise.resolve().then(() => (ga(),ha)),"af-section":()=>Promise.resolve().then(() => (sa(),ma)),"af-icon":()=>Promise.resolve().then(() => (va(),pa)),"af-ui-button":()=>Promise.resolve().then(() => (Vn(),br)),"af-ui-card":()=>Promise.resolve().then(() => (Kn(),ir)),"af-ui-input":()=>Promise.resolve().then(() => (jn(),fr)),"af-ui-badge":()=>Promise.resolve().then(() => (Cn(),dr)),"af-ui-switch":()=>Promise.resolve().then(() => (In(),cr)),"af-ui-select":()=>Promise.resolve().then(() => (Pn(),hr)),"af-ui-textarea":()=>Promise.resolve().then(() => (Tn(),gr)),"af-ui-chip":()=>Promise.resolve().then(() => (Zn(),mr)),"af-ui-tag":()=>Promise.resolve().then(() => (zn(),sr)),"af-ui-avatar":()=>Promise.resolve().then(() => (to(),pr)),"af-ui-progress-ring":()=>Promise.resolve().then(() => (no(),vr)),"af-ui-tooltip":()=>Promise.resolve().then(() => (oo(),ur)),"af-ui-popover":()=>Promise.resolve().then(() => (ro(),$r)),"af-ui-tabs":()=>Promise.resolve().then(() => (eo(),wr)),"af-ui-table":()=>Promise.resolve().then(() => (lo(),xr)),"af-ui-stat":()=>Promise.resolve().then(() => (bo(),Ar)),"af-footer":()=>Promise.resolve().then(() => (io(),_r)),"af-breadcrumb":()=>Promise.resolve().then(() => (fo(),kr)),"af-feature-grid":()=>Promise.resolve().then(() => (co(),qr)),"af-pricing-card":()=>Promise.resolve().then(() => (ho(),Er)),"af-testimonial":()=>Promise.resolve().then(() => (go(),Mr)),"af-dashboard-shell":()=>Promise.resolve().then(() => (mo(),Hr)),"af-dashboard-topbar":()=>Promise.resolve().then(() => (so(),Lr)),"af-dashboard-card":()=>Promise.resolve().then(() => (po(),Sr)),"af-dashboard-metric":()=>Promise.resolve().then(() => (vo(),Rr)),"af-dashboard-activity-list":()=>Promise.resolve().then(() => (uo(),Yr)),"af-accordion":()=>Promise.resolve().then(() => ($a(),ua)),"af-hero":()=>Promise.resolve().then(() => (xa(),wa)),"af-table":()=>Promise.resolve().then(() => (_a(),Aa)),"af-modal":()=>Promise.resolve().then(() => (qa(),ka)),"af-tabs":()=>Promise.resolve().then(() => (Ma(),Ea)),"af-sidebar":()=>Promise.resolve().then(() => (Fa(),Xa)),"af-dropdown":()=>Promise.resolve().then(() => (Qa(),Ja)),"af-select":()=>Promise.resolve().then(() => (Ba(),Ga)),"af-form":()=>Promise.resolve().then(() => (Oa(),Da)),"af-tooltip":()=>Promise.resolve().then(() => (Ua(),Wa)),"af-toast":()=>Promise.resolve().then(() => (ya(),Na)),"af-badge":()=>Promise.resolve().then(() => (Ka(),Va)),"af-avatar":()=>Promise.resolve().then(() => (Ca(),ja)),"af-progress":()=>Promise.resolve().then(() => (Pa(),Ia)),"af-loader":()=>Promise.resolve().then(() => (Za(),Ta)),"af-skeleton":()=>Promise.resolve().then(() => (te(),za)),"af-divider":()=>Promise.resolve().then(() => (oe(),ne)),"af-kanga-card":()=>Promise.resolve().then(() => (ee(),ae)),"af-cultural-card":()=>Promise.resolve().then(() => (be(),le)),"af-pattern-showcase":()=>Promise.resolve().then(() => (fe(),ie)),"af-language-switcher":()=>Promise.resolve().then(() => (ce(),de)),"af-auth":()=>Promise.resolve().then(() => (ge(),he)),"af-auth-form":()=>Promise.resolve().then(() => ($o(),Xr)),"af-kyc-upload":()=>Promise.resolve().then(() => (wo(),Fr)),"af-wallet-balance":()=>Promise.resolve().then(() => (_o(),Jr)),"af-transaction-ledger":()=>Promise.resolve().then(() => (ko(),Gr)),"af-nav-drawer":()=>Promise.resolve().then(() => (qo(),Br)),"af-theme-toggle":()=>Promise.resolve().then(() => (se(),me))},Ud=Zb;export{Ud as default,Zb as componentMap,on as AfriWalletBalance,Lt as AfriUITooltip,kt as AfriUITextarea,Et as AfriUITag,Rt as AfriUITabs,Yt as AfriUITable,At as AfriUISwitch,Xt as AfriUIStat,_t as AfriUISelect,Ht as AfriUIProgressRing,St as AfriUIPopover,wt as AfriUIInput,qt as AfriUIChip,$t as AfriUICard,ut as AfriUIButton,xt as AfriUIBadge,Mt as AfriUIAvatar,rn as AfriTransactionLedger,Bt as AfriTestimonial,Gt as AfriPricingCard,yt as AfriNavDrawer,nn as AfriKycUpload,Ft as AfriFooter,Qt as AfriFeatureGrid,yn as AfriErrorBoundary,Ot as AfriDashboardTopbar,Dt as AfriDashboardShell,Ut as AfriDashboardMetric,Wt as AfriDashboardCard,Nt as AfriDashboardActivityList,i as AfriCodeComponent,Jt as AfriBreadcrumb,tn as AfriAuthForm};
|
|
4469
4472
|
|
|
4470
|
-
//# debugId=
|
|
4473
|
+
//# debugId=CB91343280EC8F3464756E2164756E21
|