@kitn.ai/ui 0.21.0 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/chat-thread.d.ts +9 -0
- package/dist/{create-tween-D3Y5qiij.js → create-tween-COnPwAQN.js} +1 -1
- package/dist/{create-tween-DGKY1FDY.js → create-tween-DmTUaXWE.js} +1 -1
- package/dist/{create-tween-paho5Rh-.js → create-tween-qs-jjvNA.js} +1 -1
- package/dist/custom-elements.json +43 -7
- package/dist/elements/agent-card.js +1 -1
- package/dist/elements/artifact.js +1 -1
- package/dist/elements/attachments.js +1 -1
- package/dist/elements/audio-visualizer.js +1 -1
- package/dist/elements/avatar.js +1 -1
- package/dist/elements/badge.js +1 -1
- package/dist/elements/button.js +1 -1
- package/dist/elements/card.js +1 -1
- package/dist/elements/cards.js +1 -1
- package/dist/elements/chain-of-thought.js +1 -1
- package/dist/elements/chat-scope-picker.js +1 -1
- package/dist/elements/chat-workspace.js +1 -1
- package/dist/elements/chat.js +1 -1
- package/dist/elements/checkpoint.js +1 -1
- package/dist/elements/choice.js +1 -1
- package/dist/elements/chunks/{Icon-C-2LvGDG.js → Icon-CHG5z5L7.js} +1 -1
- package/dist/elements/chunks/{action-icons-CaYoImEk.js → action-icons-BAtCEEgg.js} +1 -1
- package/dist/elements/chunks/arrow-left-CFPTeL1Y.js +1 -0
- package/dist/elements/chunks/{artifact-BBIscOxJ.js → artifact-fBZOE4SO.js} +1 -1
- package/dist/elements/chunks/{attachments-BB56zoji.js → attachments-DpYMe5VQ.js} +1 -1
- package/dist/elements/chunks/{audio-visualizer-BxOx4THz.js → audio-visualizer-DFwzAcuL.js} +1 -1
- package/dist/elements/chunks/{badge-SxLSZ19R.js → badge-D6zodm6E.js} +1 -1
- package/dist/elements/chunks/{button-CmkUkz6c.js → button-C42vrGvO.js} +1 -1
- package/dist/elements/chunks/{card-renderer-Db4ffkWv.js → card-renderer-DMZsSuvU.js} +1 -1
- package/dist/elements/chunks/{chat-thread-B3Ks-cKr.js → chat-thread-CNNEhol-.js} +1 -1
- package/dist/elements/chunks/check-7Q3K-iXE.js +1 -0
- package/dist/elements/chunks/chevron-down-CpNYLn7E.js +1 -0
- package/dist/elements/chunks/chevron-right-DrH85Fha.js +1 -0
- package/dist/elements/chunks/{choice-card-Q9cYYDyM.js → choice-card-YoWjpsFV.js} +1 -1
- package/dist/elements/chunks/circle-C9KRjKYv.js +1 -0
- package/dist/elements/chunks/circle-check-Dmi7Y4zw.js +1 -0
- package/dist/elements/chunks/{circle-x-D0MEfxOM.js → circle-x-QIxXda6k.js} +1 -1
- package/dist/elements/chunks/{code-block-C8VzAraE.js → code-block-CqeugReY.js} +1 -1
- package/dist/elements/chunks/{collapsible-Cvj61obE.js → collapsible-sTv-_5lF.js} +1 -1
- package/dist/elements/chunks/{composer-D86ztyL0.js → composer-ldQyeVEB.js} +1 -1
- package/dist/elements/chunks/{confirm-card-BdyDAGLw.js → confirm-card-C0RNOwfn.js} +1 -1
- package/dist/elements/chunks/context-5qgypNHC.js +1 -0
- package/dist/elements/chunks/conversation-list-DLzOacXz.js +1 -0
- package/dist/elements/chunks/{create-tween-C_A_B638.js → create-tween-V4TXZ93X.js} +1 -1
- package/dist/elements/chunks/default-input-DeeRSDHc.js +1 -0
- package/dist/elements/chunks/{define-BzPnNsXg.js → define-lE-QvQFn.js} +1 -1
- package/dist/elements/chunks/{disclosure-DVKsoc1F.js → disclosure-DZSa9jog.js} +1 -1
- package/dist/elements/chunks/{download-BjA54IMJ.js → download-B2ZmnGqW.js} +1 -1
- package/dist/elements/chunks/{dropdown-BjVVHWXH.js → dropdown-R3B7cSRE.js} +1 -1
- package/dist/elements/chunks/{ellipsis-BNedmqfi.js → ellipsis-BmxceY4l.js} +1 -1
- package/dist/elements/chunks/{embed-DQsl4XEq.js → embed-BVrtTZPo.js} +1 -1
- package/dist/elements/chunks/{external-link-Di-dw2CU.js → external-link-BbdR7YO7.js} +1 -1
- package/dist/elements/chunks/{file-text-B3sAODCV.js → file-text-D7dijo1A.js} +1 -1
- package/dist/elements/chunks/{file-tree-Dgto-bMn.js → file-tree-0upJ5jeb.js} +1 -1
- package/dist/elements/chunks/{folder-D6rMadFV.js → folder-D8z58t7B.js} +1 -1
- package/dist/elements/chunks/{form-CILxvhQ7.js → form-p5BKJNw5.js} +1 -1
- package/dist/elements/chunks/{hover-card-BtiF4XiU.js → hover-card-CN9s2md5.js} +1 -1
- package/dist/elements/chunks/{icon-DKkmze3y.js → icon-CNiKP37E.js} +1 -1
- package/dist/elements/chunks/{info-CWRjZkuy.js → info-BSnuJiHI.js} +1 -1
- package/dist/elements/chunks/{input--QJBK6BA.js → input-BauDmzxX.js} +1 -1
- package/dist/elements/chunks/{kbd-C3zuKh8R.js → kbd-BlHJaP9b.js} +1 -1
- package/dist/elements/chunks/{link-BL5JA7Q0.js → link-DEi5iUWC.js} +1 -1
- package/dist/elements/chunks/{link-preview-CU37bbXh.js → link-preview-BaHyM6W4.js} +1 -1
- package/dist/elements/chunks/{loader-XmpyxyRH.js → loader-CmJG_Fkq.js} +1 -1
- package/dist/elements/chunks/{markdown-3Gv5UZ_o.js → markdown-D2jaMpCN.js} +1 -1
- package/dist/elements/chunks/{message-X5NZbq-W.js → message-C5UfXZ2Z.js} +1 -1
- package/dist/elements/chunks/{message-CnBA2OUt.js → message-CXWLmmLn.js} +1 -1
- package/dist/elements/chunks/message-square-hXylwsy0.js +1 -0
- package/dist/elements/chunks/{minimize-2-DwyrUTcM.js → minimize-2-C9ytZFMU.js} +1 -1
- package/dist/elements/chunks/model-switcher-CivGfD7-.js +1 -0
- package/dist/elements/chunks/{overlay-Cepd-KcS.js → overlay-DJL_sbOm.js} +1 -1
- package/dist/elements/chunks/{paperclip-CdwKjrlu.js → paperclip-CFaB8naM.js} +1 -1
- package/dist/elements/chunks/{progress-bar-DMVXBD3b.js → progress-bar-Br5SksfR.js} +1 -1
- package/dist/elements/chunks/{prompt-suggestion-Di_WZE_5.js → prompt-suggestion-CMIvtAhU.js} +1 -1
- package/dist/elements/chunks/{reasoning-D0jMch5u.js → reasoning-DpZcNzLq.js} +1 -1
- package/dist/elements/chunks/{resizable-1znbL1Gv.js → resizable-Q8i3T9a_.js} +1 -1
- package/dist/elements/chunks/{rotate-cw-DVhhgx8n.js → rotate-cw-B5IHCBFV.js} +1 -1
- package/dist/elements/chunks/{scroll-area-Bs4bFS1P.js → scroll-area-eLeydBje.js} +1 -1
- package/dist/elements/chunks/{scroll-button-Bet5NLc4.js → scroll-button-DWbz0yA1.js} +1 -1
- package/dist/elements/chunks/{separator-C5Gh8qGC.js → separator-Xic78AD_.js} +1 -1
- package/dist/elements/chunks/{settings-5vmEFg0K.js → settings-B8H51pAx.js} +1 -1
- package/dist/elements/chunks/{settings-group-BWLB38kz.js → settings-group-CsG9eYLe.js} +1 -1
- package/dist/elements/chunks/{share-BZ3G_DaB.js → share-CNTx0z__.js} +1 -1
- package/dist/elements/chunks/{skeleton-DafPJQTp.js → skeleton-CLlHTcMI.js} +1 -1
- package/dist/elements/chunks/{source-D_qj_6uJ.js → source-BoVcU5ok.js} +1 -1
- package/dist/elements/chunks/{star-Cuv7j2IE.js → star-CxQVTVhI.js} +1 -1
- package/dist/elements/chunks/{store-C1StPHfW.js → store-CLtS5CUG.js} +1 -1
- package/dist/elements/chunks/{tasks-card-EyoBZfpA.js → tasks-card-CzlkLmUt.js} +1 -1
- package/dist/elements/chunks/{text-shimmer-D9gRSh34.js → text-shimmer-D5NhpIQ1.js} +1 -1
- package/dist/elements/chunks/{textarea-DuhtHfcm.js → textarea-x5Uxsmtm.js} +1 -1
- package/dist/elements/chunks/{thumbs-up-B9hwv43w.js → thumbs-up-UobcJnx9.js} +1 -1
- package/dist/elements/chunks/{toast-store-Bm3DUEDe.js → toast-store-BOfs9eXq.js} +1 -1
- package/dist/elements/chunks/{tool-CDtW7L0z.js → tool-Be6Dh_dt.js} +1 -1
- package/dist/elements/chunks/{tooltip-eB226mGK.js → tooltip-RxMxyCLF.js} +1 -1
- package/dist/elements/chunks/{triangle-alert-C1SNzTqK.js → triangle-alert-C4yxH2XN.js} +1 -1
- package/dist/elements/chunks/{use-card-resolution-YZh2MvI5.js → use-card-resolution-jva9ehH6.js} +1 -1
- package/dist/elements/chunks/{variant-aurora-Cj1F7D0l.js → variant-aurora-Dx4VRcjS.js} +1 -1
- package/dist/elements/chunks/{variant-custom-T9gpt7QE.js → variant-custom-Y1ZTWgEa.js} +1 -1
- package/dist/elements/chunks/{variant-wave-CxU9z-TE.js → variant-wave-B9gml9Cg.js} +1 -1
- package/dist/elements/chunks/{video-CK4R7Rus.js → video-CrPHsytT.js} +1 -1
- package/dist/elements/chunks/x-_-OPHept.js +1 -0
- package/dist/elements/coachmark.js +1 -1
- package/dist/elements/code-block.js +1 -1
- package/dist/elements/command.js +1 -1
- package/dist/elements/compare.js +1 -1
- package/dist/elements/composer.js +1 -1
- package/dist/elements/confirm-card.js +1 -1
- package/dist/elements/context-meter.js +1 -1
- package/dist/elements/conversation-list.js +1 -1
- package/dist/elements/default-input.d.ts +27 -0
- package/dist/elements/dialog.js +1 -1
- package/dist/elements/editable-label.js +1 -1
- package/dist/elements/embed.js +1 -1
- package/dist/elements/empty.js +1 -1
- package/dist/elements/feedback-bar.js +1 -1
- package/dist/elements/file-tree.js +1 -1
- package/dist/elements/file-upload.js +1 -1
- package/dist/elements/form.js +1 -1
- package/dist/elements/hover-card.js +1 -1
- package/dist/elements/icon.js +1 -1
- package/dist/elements/image.js +1 -1
- package/dist/elements/input.js +1 -1
- package/dist/elements/kbd.js +1 -1
- package/dist/elements/link-preview.js +1 -1
- package/dist/elements/loader.js +1 -1
- package/dist/elements/markdown.js +1 -1
- package/dist/elements/menu.js +1 -1
- package/dist/elements/message-skills.js +1 -1
- package/dist/elements/message.js +1 -1
- package/dist/elements/model-switcher.js +1 -1
- package/dist/elements/nav.js +1 -1
- package/dist/elements/notice.js +1 -1
- package/dist/elements/pane-group.js +1 -1
- package/dist/elements/pane.js +1 -1
- package/dist/elements/popover.js +1 -1
- package/dist/elements/progress-bar.js +1 -1
- package/dist/elements/prompt-dock.js +1 -1
- package/dist/elements/prompt-input.js +1 -1
- package/dist/elements/prompt-suggestions.js +1 -1
- package/dist/elements/reasoning.js +1 -1
- package/dist/elements/remote.js +1 -1
- package/dist/elements/resizable.js +1 -1
- package/dist/elements/response-stream.js +2 -2
- package/dist/elements/screen.js +1 -1
- package/dist/elements/scroll-area.js +1 -1
- package/dist/elements/scroll-button.js +1 -1
- package/dist/elements/search.js +1 -1
- package/dist/elements/segmented.js +1 -1
- package/dist/elements/separator.js +1 -1
- package/dist/elements/setting-item.js +1 -1
- package/dist/elements/settings-group.js +1 -1
- package/dist/elements/skeleton.js +1 -1
- package/dist/elements/slot-text.d.ts +51 -0
- package/dist/elements/slots.d.ts +5 -0
- package/dist/elements/source.js +1 -1
- package/dist/elements/status.js +1 -1
- package/dist/elements/switch.js +1 -1
- package/dist/elements/tabs.js +1 -1
- package/dist/elements/tasks.js +1 -1
- package/dist/elements/text-shimmer.js +1 -1
- package/dist/elements/thinking-bar.js +1 -1
- package/dist/elements/thread.js +1 -1
- package/dist/elements/toast.js +1 -1
- package/dist/elements/tool.js +1 -1
- package/dist/elements/tooltip.js +1 -1
- package/dist/elements/voice-input.js +1 -1
- package/dist/elements/voice-output.js +1 -1
- package/dist/elements.d.ts +12 -6
- package/dist/index.js +1535 -1487
- package/dist/index.server.js +2330 -2296
- package/dist/kai.es.js +1 -1
- package/dist/llms/llms-full.txt +12 -3
- package/dist/mcp.es.js +809 -75
- package/dist/react/index.d.ts +13 -3
- package/dist/react.js +14 -14
- package/dist/register-impl-AxIlqjo7.js +145 -0
- package/dist/{solid-BCJUQqwS.js → solid-BGYSJyHG.js} +4901 -4691
- package/dist/{solid-BdENBcEq.js → solid-Dt2nEwfl.js} +4406 -4320
- package/dist/solid.js +1 -1
- package/dist/solid.server.js +1 -1
- package/dist/{variant-aurora-DOb_o4pC.js → variant-aurora-B44X69AG.js} +1 -1
- package/dist/{variant-aurora-BKHHiOgL.js → variant-aurora-BRhV8Flk.js} +2 -2
- package/dist/{variant-aurora-1wMcXRUS.js → variant-aurora-Ds5ou9BH.js} +2 -2
- package/dist/{variant-custom-DWSSgmd2.js → variant-custom-B20FhtYj.js} +2 -2
- package/dist/{variant-custom-CJGB0Kbw.js → variant-custom-BvA1Schl.js} +1 -1
- package/dist/{variant-custom-Co0CkXJF.js → variant-custom-D6Rtvneb.js} +2 -2
- package/dist/{variant-wave-CEODq-9q.js → variant-wave-BUQtkryq.js} +1 -1
- package/dist/{variant-wave-C3-45cL6.js → variant-wave-BVYnqy9L.js} +2 -2
- package/dist/{variant-wave-jdXBnCUZ.js → variant-wave-DXC6_LcH.js} +2 -2
- package/dist/wire/encode.d.ts +79 -6
- package/dist/wire/files.d.ts +116 -0
- package/dist/wire/index.d.ts +3 -1
- package/dist/wire/media-types.d.ts +106 -0
- package/dist/wire.js +596 -368
- package/frameworks/react/index.tsx +9 -5
- package/llms-full.txt +12 -3
- package/package.json +2 -1
- package/src/agent-tooling/archetypes.ts +43 -12
- package/src/agent-tooling/integrations/anthropic.ts +29 -5
- package/src/agent-tooling/integrations/cloudflare.ts +5 -0
- package/src/agent-tooling/integrations/langgraph.ts +13 -0
- package/src/agent-tooling/integrations/mastra.ts +46 -5
- package/src/agent-tooling/integrations/mock.ts +4 -0
- package/src/agent-tooling/integrations/ollama.ts +7 -0
- package/src/agent-tooling/integrations/openai.ts +2 -0
- package/src/agent-tooling/integrations/openrouter.ts +2 -0
- package/src/agent-tooling/integrations/pi.ts +26 -1
- package/src/agent-tooling/integrations/pydantic-ai.ts +37 -3
- package/src/agent-tooling/integrations/vercel-ai-sdk.ts +42 -6
- package/src/agent-tooling/mcp/tools/scaffold.ts +853 -32
- package/src/agent-tooling/registry.ts +57 -0
- package/src/agent-tooling/types.ts +132 -0
- package/src/components/chat-thread.tsx +10 -1
- package/src/components/context.tsx +18 -12
- package/src/components/conversation-item.tsx +6 -0
- package/src/components/model-switcher.tsx +38 -8
- package/src/components/toast.tsx +6 -1
- package/src/elements/button.tsx +26 -3
- package/src/elements/chat.tsx +28 -2
- package/src/elements/default-input.tsx +128 -5
- package/src/elements/element-meta.json +30 -4
- package/src/elements/element-types.d.ts +12 -6
- package/src/elements/menu.tsx +30 -3
- package/src/elements/slot-text.ts +73 -0
- package/src/elements/slots.ts +10 -0
- package/src/index.ts +9 -5
- package/src/wire/encode.ts +229 -14
- package/src/wire/files.ts +342 -0
- package/src/wire/index.ts +21 -0
- package/src/wire/media-types.ts +344 -0
- package/dist/elements/chunks/arrow-left-Bb46H7w9.js +0 -1
- package/dist/elements/chunks/check-C8desc_h.js +0 -1
- package/dist/elements/chunks/chevron-down-DKtc2HNB.js +0 -1
- package/dist/elements/chunks/chevron-right-Dw4GPhwL.js +0 -1
- package/dist/elements/chunks/circle-BeokBsvB.js +0 -1
- package/dist/elements/chunks/circle-check-wJSqt859.js +0 -1
- package/dist/elements/chunks/context-WHDl-xSx.js +0 -1
- package/dist/elements/chunks/conversation-list-CdR14_Y4.js +0 -1
- package/dist/elements/chunks/default-input-CSZqUM81.js +0 -1
- package/dist/elements/chunks/message-square-CnpAm_P0.js +0 -1
- package/dist/elements/chunks/model-switcher-CclaJEHt.js +0 -1
- package/dist/elements/chunks/x-D1qx0aLd.js +0 -1
- package/dist/register-impl-bzrZ44ft.js +0 -145
package/dist/kai.es.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const Sn={bash:()=>import("./bash-InADTalH.js"),javascript:()=>import("./javascript-C25yR2R2.js"),typescript:()=>import("./typescript-RycA9KXf.js"),tsx:()=>import("./tsx-B8rCNbgL.js"),html:()=>import("./html-CPZ3oZQ7.js"),css:()=>import("./css-M7EaDHN_.js"),json:()=>import("./json-DxJze_jm.js"),vue:()=>import("./vue-BmIZj4XD.js"),svelte:()=>import("./svelte--5p79yCD.js")},On={"github-dark-dimmed":()=>import("./github-dark-dimmed-DUshB20C.js"),"github-light":()=>import("./github-light-JYsPkUQd.js")},xn={js:"javascript",ts:"typescript",jsx:"tsx",sh:"bash",shell:"bash"},Nt="github-dark-dimmed";let Ot=!0,xt={...Sn},At={...On},kt={...xn},jt=null;const zt=new Set,Ft=new Set;function An(){return jt||(jt=(async()=>{const[{createHighlighterCore:t},{createJavaScriptRegexEngine:n}]=await Promise.all([import("./core-C8fzo39E.js"),import("./engine-javascript-C1x7zo1_.js")]);return t({themes:[],langs:[],engine:n()})})()),jt}function Lt(t){return kt[t]??t}async function kn(t,n){const e=Lt(n);if(zt.has(e))return!0;const r=xt[e];return r?(await t.loadLanguage(r()),zt.add(e),!0):!1}async function Rt(t,n){if(Ft.has(n))return!0;const e=At[n];return e?(await t.loadTheme(e()),Ft.add(n),!0):!1}function jn(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">")}function lt(t){return`<pre><code>${jn(t)}</code></pre>`}async function Pn(t,n,e){if(!Ot||!t)return lt(t);try{const r=await An();if(!await kn(r,n))return lt(t);const o=await Rt(r,e)?e:await Rt(r,Nt)?Nt:null;return o?r.codeToHtml(t,{lang:Lt(n),theme:o}):lt(t)}catch{return lt(t)}}function _n(t){t.enabled!==void 0&&(Ot=t.enabled),t.languages&&(xt={...xt,...t.languages}),t.themes&&(At={...At,...t.themes}),t.aliases&&(kt={...kt,...t.aliases})}function qn(){return Ot}function Cn(t){const n=t.toLowerCase();return n?n.includes("bash")||n.includes("command")||n.includes("shell")||n.includes("terminal")||n.includes("exec")?"command":n.includes("edit")||n.includes("write")||n.includes("patch")||n.includes("replace")||n.includes("delete")?"file-change":n.includes("search")||n.includes("grep")||n.includes("glob")||n.includes("find")?"search":n.includes("fetch")||n.includes("http")||n.includes("browse")||n.includes("crawl")?"fetch":n.includes("mcp")?"mcp":n.includes("image")||n.includes("screenshot")||n.includes("vision")?"image":"generic":"generic"}const p={context:void 0,registry:void 0,effects:void 0,done:!1,getContextId(){return Kt(this.context.count)},getNextContextId(){return Kt(this.context.count++)}};function Kt(t){const n=String(t),e=n.length-1;return p.context.id+(e?String.fromCharCode(96+e):"")+n}function Pt(t){p.context=t}function Vn(){return{...p.context,id:p.getNextContextId(),count:0}}const Oe=!1,En=(t,n)=>t===n,E=Symbol("solid-proxy"),Jt=typeof Proxy=="function",X=Symbol("solid-track"),xe=Symbol("solid-dev-component"),at={equals:En};let Y=null,Ut=en;const P=1,Z=2,Wt={owned:null,cleanups:null,context:null,owner:null},_t={};var f=null;let c=null,J=null,U=null,g=null,b=null,O=null,ft=0;function F(t,n){const e=g,r=f,o=t.length===0,s=n===void 0?r:n,i=o?Wt:{owned:null,cleanups:null,context:s?s.context:null,owner:s},u=o?t:()=>t(()=>m(()=>z(i)));f=i,g=null;try{return k(u,!0)}finally{g=e,f=r}}function M(t,n){n=n?Object.assign({},at,n):at;const e={value:t,observers:null,observerSlots:null,comparator:n.equals||void 0},r=o=>(typeof o=="function"&&(c&&c.running&&c.sources.has(e)?o=o(e.tValue):o=o(e.value)),tn(e,o));return[Zt.bind(e),r]}function Bt(t,n,e){const r=et(t,n,!0,P);J&&c&&c.running?b.push(r):W(r)}function Gt(t,n,e){const r=et(t,n,!1,P);J&&c&&c.running?b.push(r):W(r)}function Qt(t,n,e){Ut=Kn;const r=et(t,n,!1,P),o=nt&&Ct(nt);o&&(r.suspense=o),(!e||!e.render)&&(r.user=!0),O?O.push(r):W(r)}function A(t,n,e){e=e?Object.assign({},at,e):at;const r=et(t,n,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=e.equals||void 0,J&&c&&c.running?(r.tState=P,b.push(r)):W(r),Zt.bind(r)}function Mn(t){return t&&typeof t=="object"&&"then"in t}function $n(t,n,e){let r,o,s;typeof n=="function"?(r=t,o=n,s=e||{}):(r=!0,o=t,s=n||{});let i=null,u=_t,l=null,d=!1,h=!1,a="initialValue"in s,w=typeof r=="function"&&A(r);const S=new Set,[_,D]=(s.storage||M)(s.initialValue),[N,K]=M(void 0),[q,C]=M(void 0,{equals:!1}),[V,T]=M(a?"ready":"unresolved");p.context&&(l=p.getNextContextId(),s.ssrLoadFrom==="initial"?u=s.initialValue:p.load&&p.has(l)&&(u=p.load(l)));function H(y,v,$,x){return i===y&&(i=null,x!==void 0&&(a=!0),(y===u||v===u)&&s.onHydrated&&queueMicrotask(()=>s.onHydrated(x,{value:v})),u=_t,c&&y&&d?(c.promises.delete(y),d=!1,k(()=>{c.running=!0,Tt(v,$)},!1)):Tt(v,$)),v}function Tt(y,v){k(()=>{v===void 0&&D(()=>y),T(v!==void 0?"errored":a?"ready":"unresolved"),K(v);for(const $ of S.keys())$.decrement();S.clear()},!1)}function mt(){const y=nt&&Ct(nt),v=_(),$=N();if($!==void 0&&!i)throw $;return g&&!g.user&&y&&Bt(()=>{q(),i&&(y.resolved&&c&&d?c.promises.add(i):S.has(y)||(y.increment(),S.add(y)))}),v}function St(y=!0){if(y!==!1&&h)return;h=!1;const v=w?w():r;if(d=c&&c.running,v==null||v===!1){H(i,m(_));return}c&&i&&c.promises.delete(i);let $;const x=u!==_t?u:m(()=>{try{return o(v,{value:_(),refetching:y})}catch(Q){$=Q}});if($!==void 0){H(i,void 0,ht($),v);return}else if(!Mn(x))return H(i,x,void 0,v),x;return i=x,"v"in x?(x.s===1?H(i,x.v,void 0,v):H(i,void 0,ht(x.v),v),x):(h=!0,queueMicrotask(()=>h=!1),k(()=>{T(a?"refreshing":"pending"),C()},!1),x.then(Q=>H(x,Q,void 0,v),Q=>H(x,void 0,ht(Q),v)))}Object.defineProperties(mt,{state:{get:()=>V()},error:{get:()=>N()},loading:{get(){const y=V();return y==="pending"||y==="refreshing"}},latest:{get(){if(!a)return mt();const y=N();if(y&&!i)throw y;return _()}}});let Ht=f;return w?Bt(()=>(Ht=f,St(!1))):St(!1),[mt,{refetch:y=>Xt(Ht,()=>St(y)),mutate:D}]}function Dn(t){return k(t,!1)}function m(t){if(!U&&g===null)return t();const n=g;g=null;try{return U?U.untrack(t):t()}finally{g=n}}function In(t,n,e){const r=Array.isArray(t);let o,s=e&&e.defer;return i=>{let u;if(r){u=Array(t.length);for(let d=0;d<t.length;d++)u[d]=t[d]()}else u=t();if(s)return s=!1,i;const l=m(()=>n(u,o,i));return o=u,l}}function Tn(t){Qt(()=>m(t))}function tt(t){return f===null||(f.cleanups===null?f.cleanups=[t]:f.cleanups.push(t)),t}function Hn(t,n){Y||(Y=Symbol("error")),f=et(void 0,void 0,!0),f.context={...f.context,[Y]:[n]},c&&c.running&&c.sources.add(f);try{return t()}catch(e){ot(e)}finally{f=f.owner}}function qt(){return g}function Nn(){return f}function Xt(t,n){const e=f,r=g;f=t,g=null;try{return k(n,!0)}catch(o){ot(o)}finally{f=e,g=r}}function zn(t){if(c&&c.running)return t(),c.done;const n=g,e=f;return Promise.resolve().then(()=>{g=n,f=e;let r;return(J||nt)&&(r=c||(c={sources:new Set,effects:[],promises:new Set,disposed:new Set,queue:new Set,running:!0}),r.done||(r.done=new Promise(o=>r.resolve=o)),r.running=!0),k(t,!1),g=f=null,r?r.done:void 0})}const[Ae,Yt]=M(!1);function Fn(t,n){const e=Symbol("context");return{id:e,Provider:Jn(e),defaultValue:t}}function Ct(t){let n;return f&&f.context&&(n=f.context[t.id])!==void 0?n:t.defaultValue}function Vt(t){const n=A(t),e=A(()=>Et(n()));return e.toArray=()=>{const r=e();return Array.isArray(r)?r:r!=null?[r]:[]},e}let nt;function Zt(){const t=c&&c.running;if(this.sources&&(t?this.tState:this.state))if((t?this.tState:this.state)===P)W(this);else{const n=b;b=null,k(()=>dt(this),!1),b=n}if(g){const n=this.observers;if(!n||n[n.length-1]!==g){const e=n?n.length:0;g.sources?(g.sources.push(this),g.sourceSlots.push(e)):(g.sources=[this],g.sourceSlots=[e]),n?(n.push(g),this.observerSlots.push(g.sources.length-1)):(this.observers=[g],this.observerSlots=[g.sources.length-1])}}return t&&c.sources.has(this)?this.tValue:this.value}function tn(t,n,e){let r=c&&c.running&&c.sources.has(t)?t.tValue:t.value;if(!t.comparator||!t.comparator(r,n)){if(c){const o=c.running;(o||!e&&c.sources.has(t))&&(c.sources.add(t),t.tValue=n),o||(t.value=n)}else t.value=n;t.observers&&t.observers.length&&k(()=>{for(let o=0;o<t.observers.length;o+=1){const s=t.observers[o],i=c&&c.running;i&&c.disposed.has(s)||((i?!s.tState:!s.state)&&(s.pure?b.push(s):O.push(s),s.observers&&rn(s)),i?s.tState=P:s.state=P)}if(b.length>1e6)throw b=[],new Error},!1)}return n}function W(t){if(!t.fn)return;z(t);const n=ft;nn(t,c&&c.running&&c.sources.has(t)?t.tValue:t.value,n),c&&!c.running&&c.sources.has(t)&&queueMicrotask(()=>{k(()=>{c&&(c.running=!0),g=f=t,nn(t,t.tValue,n),g=f=null},!1)})}function nn(t,n,e){let r;const o=f,s=g;g=f=t;try{r=t.fn(n)}catch(i){return t.pure&&(c&&c.running?(t.tState=P,t.tOwned&&t.tOwned.forEach(z),t.tOwned=void 0):(t.state=P,t.owned&&t.owned.forEach(z),t.owned=null)),t.updatedAt=e+1,ot(i)}finally{g=s,f=o}(!t.updatedAt||t.updatedAt<=e)&&(t.updatedAt!=null&&"observers"in t?tn(t,r,!0):c&&c.running&&t.pure?(c.sources.has(t)||(t.value=r),c.sources.add(t),t.tValue=r):t.value=r,t.updatedAt=e)}function et(t,n,e,r=P,o){const s={fn:t,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:n,owner:f,context:f?f.context:null,pure:e};if(c&&c.running&&(s.state=0,s.tState=r),f===null||f!==Wt&&(c&&c.running&&f.pure?f.tOwned?f.tOwned.push(s):f.tOwned=[s]:f.owned?f.owned.push(s):f.owned=[s]),U&&s.fn){const i=s.fn,[u,l]=M(void 0,{equals:!1}),d=U.factory(i,l);tt(()=>d.dispose());let h;const a=()=>zn(l).then(()=>{h&&(h.dispose(),h=void 0)});s.fn=w=>(u(),c&&c.running?(h||(h=U.factory(i,a)),h.track(w)):d.track(w))}return s}function rt(t){const n=c&&c.running;if((n?t.tState:t.state)===0)return;if((n?t.tState:t.state)===Z)return dt(t);if(t.suspense&&m(t.suspense.inFallback))return t.suspense.effects.push(t);const e=[t];for(;(t=t.owner)&&(!t.updatedAt||t.updatedAt<ft);){if(n&&c.disposed.has(t))return;(n?t.tState:t.state)&&e.push(t)}for(let r=e.length-1;r>=0;r--){if(t=e[r],n){let o=t,s=e[r+1];for(;(o=o.owner)&&o!==s;)if(c.disposed.has(o))return}if((n?t.tState:t.state)===P)W(t);else if((n?t.tState:t.state)===Z){const o=b;b=null,k(()=>dt(t,e[0]),!1),b=o}}}function k(t,n){if(b)return t();let e=!1;n||(b=[]),O?e=!0:O=[],ft++;try{const r=t();return Ln(e),r}catch(r){e||(O=null),b=null,ot(r)}}function Ln(t){if(b&&(J&&c&&c.running?Rn(b):en(b),b=null),t)return;let n;if(c){if(!c.promises.size&&!c.queue.size){const r=c.sources,o=c.disposed;O.push.apply(O,c.effects),n=c.resolve;for(const s of O)"tState"in s&&(s.state=s.tState),delete s.tState;c=null,k(()=>{for(const s of o)z(s);for(const s of r){if(s.value=s.tValue,s.owned)for(let i=0,u=s.owned.length;i<u;i++)z(s.owned[i]);s.tOwned&&(s.owned=s.tOwned),delete s.tValue,delete s.tOwned,s.tState=0}Yt(!1)},!1)}else if(c.running){c.running=!1,c.effects.push.apply(c.effects,O),O=null,Yt(!0);return}}const e=O;O=null,e.length&&k(()=>Ut(e),!1),n&&n()}function en(t){for(let n=0;n<t.length;n++)rt(t[n])}function Rn(t){for(let n=0;n<t.length;n++){const e=t[n],r=c.queue;r.has(e)||(r.add(e),J(()=>{r.delete(e),k(()=>{c.running=!0,rt(e)},!1),c&&(c.running=!1)}))}}function Kn(t){let n,e=0;for(n=0;n<t.length;n++){const r=t[n];r.user?t[e++]=r:rt(r)}if(p.context){if(p.count){p.effects||(p.effects=[]),p.effects.push(...t.slice(0,e));return}Pt()}for(p.effects&&(p.done||!p.count)&&(t=[...p.effects,...t],e+=p.effects.length,delete p.effects),n=0;n<e;n++)rt(t[n])}function dt(t,n){const e=c&&c.running;e?t.tState=0:t.state=0;for(let r=0;r<t.sources.length;r+=1){const o=t.sources[r];if(o.sources){const s=e?o.tState:o.state;s===P?o!==n&&(!o.updatedAt||o.updatedAt<ft)&&rt(o):s===Z&&dt(o,n)}}}function rn(t){const n=c&&c.running;for(let e=0;e<t.observers.length;e+=1){const r=t.observers[e];(n?!r.tState:!r.state)&&(n?r.tState=Z:r.state=Z,r.pure?b.push(r):O.push(r),r.observers&&rn(r))}}function z(t){let n;if(t.sources)for(;t.sources.length;){const e=t.sources.pop(),r=t.sourceSlots.pop(),o=e.observers;if(o&&o.length){const s=o.pop(),i=e.observerSlots.pop();r<o.length&&(s.sourceSlots[i]=r,o[r]=s,e.observerSlots[r]=i)}}if(t.tOwned){for(n=t.tOwned.length-1;n>=0;n--)z(t.tOwned[n]);delete t.tOwned}if(c&&c.running&&t.pure)on(t,!0);else if(t.owned){for(n=t.owned.length-1;n>=0;n--)z(t.owned[n]);t.owned=null}if(t.cleanups){for(n=t.cleanups.length-1;n>=0;n--)t.cleanups[n]();t.cleanups=null}c&&c.running?t.tState=0:t.state=0}function on(t,n){if(n||(t.tState=0,c.disposed.add(t)),t.owned)for(let e=0;e<t.owned.length;e++)on(t.owned[e])}function ht(t){return t instanceof Error?t:new Error(typeof t=="string"?t:"Unknown error",{cause:t})}function sn(t,n,e){try{for(const r of n)r(t)}catch(r){ot(r,e&&e.owner||null)}}function ot(t,n=f){const e=Y&&n&&n.context&&n.context[Y],r=ht(t);if(!e)throw r;O?O.push({fn(){sn(r,e,n)},state:P}):sn(r,e,n)}function Et(t){if(typeof t=="function"&&!t.length)return Et(t());if(Array.isArray(t)){const n=[];for(let e=0;e<t.length;e++){const r=Et(t[e]);if(Array.isArray(r))if(r.length<32768)n.push.apply(n,r);else for(let o=0;o<r.length;o++)n.push(r[o]);else n.push(r)}return n}return t}function Jn(t,n){return function(e){let r;return Gt(()=>r=m(()=>(f.context={...f.context,[t]:e.value},Vt(()=>e.children))),void 0),r}}const Mt=Symbol("fallback");function gt(t){for(let n=0;n<t.length;n++)t[n]()}function Un(t,n,e={}){let r=[],o=[],s=[],i=0,u=n.length>1?[]:null;return tt(()=>gt(s)),()=>{let l=t()||[],d=l.length,h,a;return l[X],m(()=>{let S,_,D,N,K,q,C,V,T;if(d===0)i!==0&&(gt(s),s=[],r=[],o=[],i=0,u&&(u=[])),e.fallback&&(r=[Mt],o[0]=F(H=>(s[0]=H,e.fallback())),i=1);else if(i===0){for(o=new Array(d),a=0;a<d;a++)r[a]=l[a],o[a]=F(w);i=d}else{for(D=new Array(d),N=new Array(d),u&&(K=new Array(d)),q=0,C=Math.min(i,d);q<C&&r[q]===l[q];q++);for(C=i-1,V=d-1;C>=q&&V>=q&&r[C]===l[V];C--,V--)D[V]=o[C],N[V]=s[C],u&&(K[V]=u[C]);for(S=new Map,_=new Array(V+1),a=V;a>=q;a--)T=l[a],h=S.get(T),_[a]=h===void 0?-1:h,S.set(T,a);for(h=q;h<=C;h++)T=r[h],a=S.get(T),a!==void 0&&a!==-1?(D[a]=o[h],N[a]=s[h],u&&(K[a]=u[h]),a=_[a],S.set(T,a)):s[h]();for(a=q;a<d;a++)a in D?(o[a]=D[a],s[a]=N[a],u&&(u[a]=K[a],u[a](a))):o[a]=F(w);o=o.slice(0,i=d),r=l.slice(0)}return o});function w(S){if(s[a]=S,u){const[_,D]=M(a);return u[a]=D,n(l[a],_)}return n(l[a])}}}function Wn(t,n,e={}){let r=[],o=[],s=[],i=[],u=0,l;return tt(()=>gt(s)),()=>{const d=t()||[],h=d.length;return d[X],m(()=>{if(h===0)return u!==0&&(gt(s),s=[],r=[],o=[],u=0,i=[]),e.fallback&&(r=[Mt],o[0]=F(w=>(s[0]=w,e.fallback())),u=1),o;for(r[0]===Mt&&(s[0](),s=[],r=[],o=[],u=0),l=0;l<h;l++)l<r.length&&r[l]!==d[l]?i[l](()=>d[l]):l>=r.length&&(o[l]=F(a));for(;l<r.length;l++)s[l]();return u=i.length=s.length=h,r=d.slice(0),o=o.slice(0,u)});function a(w){s[l]=w;const[S,_]=M(d[l]);return i[l]=_,n(S,l)}}}let un=!1;function Bn(){un=!0}function Gn(t,n){if(un&&p.context){const e=p.context;Pt(Vn());const r=m(()=>t(n||{}));return Pt(e),r}return m(()=>t(n||{}))}function pt(){return!0}const $t={get(t,n,e){return n===E?e:t.get(n)},has(t,n){return n===E?!0:t.has(n)},set:pt,deleteProperty:pt,getOwnPropertyDescriptor(t,n){return{configurable:!0,enumerable:!0,get(){return t.get(n)},set:pt,deleteProperty:pt}},ownKeys(t){return t.keys()}};function Dt(t){return(t=typeof t=="function"?t():t)?t:{}}function Qn(){for(let t=0,n=this.length;t<n;++t){const e=this[t]();if(e!==void 0)return e}}function Xn(...t){let n=!1;for(let i=0;i<t.length;i++){const u=t[i];n=n||!!u&&E in u,t[i]=typeof u=="function"?(n=!0,A(u)):u}if(Jt&&n)return new Proxy({get(i){for(let u=t.length-1;u>=0;u--){const l=Dt(t[u])[i];if(l!==void 0)return l}},has(i){for(let u=t.length-1;u>=0;u--)if(i in Dt(t[u]))return!0;return!1},keys(){const i=[];for(let u=0;u<t.length;u++)i.push(...Object.keys(Dt(t[u])));return[...new Set(i)]}},$t);const e={},r=Object.create(null);for(let i=t.length-1;i>=0;i--){const u=t[i];if(!u)continue;const l=Object.getOwnPropertyNames(u);for(let d=l.length-1;d>=0;d--){const h=l[d];if(h==="__proto__"||h==="constructor")continue;const a=Object.getOwnPropertyDescriptor(u,h);if(!r[h])r[h]=a.get?{enumerable:!0,configurable:!0,get:Qn.bind(e[h]=[a.get.bind(u)])}:a.value!==void 0?a:void 0;else{const w=e[h];w&&(a.get?w.push(a.get.bind(u)):a.value!==void 0&&w.push(()=>a.value))}}}const o={},s=Object.keys(r);for(let i=s.length-1;i>=0;i--){const u=s[i],l=r[u];l&&l.get?Object.defineProperty(o,u,l):o[u]=l?l.value:void 0}return o}function Yn(t,...n){const e=n.length;if(Jt&&E in t){const o=e>1?n.flat():n[0],s=n.map(i=>new Proxy({get(u){return i.includes(u)?t[u]:void 0},has(u){return i.includes(u)&&u in t},keys(){return i.filter(u=>u in t)}},$t));return s.push(new Proxy({get(i){return o.includes(i)?void 0:t[i]},has(i){return o.includes(i)?!1:i in t},keys(){return Object.keys(t).filter(i=>!o.includes(i))}},$t)),s}const r=[];for(let o=0;o<=e;o++)r[o]={};for(const o of Object.getOwnPropertyNames(t)){let s=e;for(let u=0;u<n.length;u++)if(n[u].includes(o)){s=u;break}const i=Object.getOwnPropertyDescriptor(t,o);!i.get&&!i.set&&i.enumerable&&i.writable&&i.configurable?r[s][o]=i.value:Object.defineProperty(r[s],o,i)}return r}let Zn=0;function te(){return p.context?p.getNextContextId():`cl-${Zn++}`}const cn=t=>`Stale read from <${t}>.`;function ne(t){const n="fallback"in t&&{fallback:()=>t.fallback};return A(Un(()=>t.each,t.children,n||void 0))}function ee(t){const n="fallback"in t&&{fallback:()=>t.fallback};return A(Wn(()=>t.each,t.children,n||void 0))}function re(t){const n=t.keyed,e=A(()=>t.when,void 0,void 0),r=n?e:A(e,void 0,{equals:(o,s)=>!o==!s});return A(()=>{const o=r();if(o){const s=t.children;return typeof s=="function"&&s.length>0?m(()=>s(n?o:()=>{if(!m(r))throw cn("Show");return e()})):s}return t.fallback},void 0,void 0)}function oe(t){const n=Vt(()=>t.children),e=A(()=>{const r=n(),o=Array.isArray(r)?r:[r];let s=()=>{};for(let i=0;i<o.length;i++){const u=i,l=o[i],d=s,h=A(()=>d()?void 0:l.when,void 0,void 0),a=l.keyed?h:A(h,void 0,{equals:(w,S)=>!w==!S});s=()=>d()||(a()?[u,h,l]:void 0)}return s});return A(()=>{const r=e()();if(!r)return t.fallback;const[o,s,i]=r,u=i.children;return typeof u=="function"&&u.length>0?m(()=>u(i.keyed?s():()=>{var l;if(((l=m(e)())==null?void 0:l[0])!==o)throw cn("Match");return s()})):u},void 0,void 0)}function se(t){return t}let yt;function ie(t){let n;p.context&&p.load&&(n=p.load(p.getContextId()));const[e,r]=M(n,void 0);return yt||(yt=new Set),yt.add(r),tt(()=>yt.delete(r)),A(()=>{let o;if(o=e()){const s=t.fallback;return typeof s=="function"&&s.length?m(()=>s(o,()=>r())):s}return Hn(()=>t.children,r)},void 0,void 0)}const vt=Symbol("store-raw"),L=Symbol("store-node"),I=Symbol("store-has"),ln=Symbol("store-self");function an(t){let n=t[E];if(!n&&(Object.defineProperty(t,E,{value:n=new Proxy(t,le)}),!Array.isArray(t))){const e=Object.keys(t),r=Object.getOwnPropertyDescriptors(t),o=Object.getPrototypeOf(t),s=o!==null&&t!==null&&typeof t=="object"&&!Array.isArray(t)&&o!==Object.prototype;if(s){const i=Object.getOwnPropertyDescriptors(o);e.push(...Object.keys(i)),Object.assign(r,i)}for(let i=0,u=e.length;i<u;i++){const l=e[i];s&&l==="constructor"||r[l].get&&Object.defineProperty(t,l,{configurable:!0,enumerable:r[l].enumerable,get:r[l].get.bind(n)})}}return n}function B(t){let n;return t!=null&&typeof t=="object"&&(t[E]||!(n=Object.getPrototypeOf(t))||n===Object.prototype||Array.isArray(t))}function R(t,n=new Set){let e,r,o,s;if(e=t!=null&&t[vt])return e;if(!B(t)||n.has(t))return t;if(Array.isArray(t)){Object.isFrozen(t)?t=t.slice(0):n.add(t);for(let i=0,u=t.length;i<u;i++)o=t[i],(r=R(o,n))!==o&&(t[i]=r)}else{Object.isFrozen(t)?t=Object.assign({},t):n.add(t);const i=Object.keys(t),u=Object.getOwnPropertyDescriptors(t);for(let l=0,d=i.length;l<d;l++)s=i[l],!u[s].get&&(o=t[s],(r=R(o,n))!==o&&(t[s]=r))}return t}function bt(t,n){let e=t[n];return e||Object.defineProperty(t,n,{value:e=Object.create(null)}),e}function st(t,n,e){if(t[n])return t[n];const[r,o]=M(e,{equals:!1,internal:!0});return r.$=o,t[n]=r}function ue(t,n){const e=Reflect.getOwnPropertyDescriptor(t,n);return!e||e.get||!e.configurable||n===E||n===L||(delete e.value,delete e.writable,e.get=()=>t[E][n]),e}function fn(t){qt()&&st(bt(t,L),ln)()}function ce(t){return fn(t),Reflect.ownKeys(t)}const le={get(t,n,e){if(n===vt)return t;if(n===E)return e;if(n===X)return fn(t),e;const r=bt(t,L),o=r[n];let s=o?o():t[n];if(n===L||n===I||n==="__proto__")return s;if(!o){const i=Object.getOwnPropertyDescriptor(t,n);qt()&&(typeof s!="function"||t.hasOwnProperty(n))&&!(i&&i.get)&&(s=st(r,n,s)())}return B(s)?an(s):s},has(t,n){return n===vt||n===E||n===X||n===L||n===I||n==="__proto__"?!0:(qt()&&st(bt(t,I),n)(),n in t)},set(){return!0},deleteProperty(){return!0},ownKeys:ce,getOwnPropertyDescriptor:ue};function G(t,n,e,r=!1){if(n==="__proto__"||!r&&t[n]===e)return;const o=t[n],s=t.length;e===void 0?(delete t[n],t[I]&&t[I][n]&&o!==void 0&&t[I][n].$()):(t[n]=e,t[I]&&t[I][n]&&o===void 0&&t[I][n].$());let i=bt(t,L),u;if((u=st(i,n,o))&&u.$(()=>e),Array.isArray(t)&&t.length!==s){for(let l=t.length;l<s;l++)(u=i[l])&&u.$();(u=st(i,"length",s))&&u.$(t.length)}(u=i[ln])&&u.$()}function dn(t,n){const e=Object.keys(n);for(let r=0;r<e.length;r+=1){const o=e[r];hn(o)||G(t,o,n[o])}}function hn(t){return t==="__proto__"||t==="constructor"||t==="prototype"}function ae(t,n){if(typeof n=="function"&&(n=n(t)),n=R(n),Array.isArray(n)){if(t===n)return;let e=0,r=n.length;for(;e<r;e++){const o=n[e];t[e]!==o&&G(t,e,o)}G(t,"length",r)}else dn(t,n)}function it(t,n,e=[]){let r,o=t;if(n.length>1){r=n.shift();const i=typeof r,u=Array.isArray(t);if(i==="string"&&(r==="__proto__"||n.length>1&&hn(r)))return;if(Array.isArray(r)){for(let l=0;l<r.length;l++)it(t,[r[l]].concat(n),e);return}else if(u&&i==="function"){for(let l=0;l<t.length;l++)r(t[l],l)&&it(t,[l].concat(n),e);return}else if(u&&i==="object"){const{from:l=0,to:d=t.length-1,by:h=1}=r;for(let a=l;a<=d;a+=h)it(t,[a].concat(n),e);return}else if(n.length>1){it(t[r],n,[r].concat(e));return}o=t[r],e=[r].concat(e)}let s=n[0];typeof s=="function"&&(s=s(o,e),s===o)||r===void 0&&s==null||(s=R(s),r===void 0||B(o)&&B(s)&&!Array.isArray(s)?dn(o,s):G(t,r,s))}function gn(...[t,n]){const e=R(t||{}),r=Array.isArray(e),o=an(e);function s(...i){Dn(()=>{r&&i.length===1?ae(e,i[0]):it(e,i)})}return[o,s]}const ke=Symbol("store-root"),wt=new WeakMap,pn={get(t,n){if(n===vt)return t;const e=t[n];if(n===E||n===X||n===L||n===I||n==="__proto__")return e;let r;return B(e)?wt.get(e)||(wt.set(e,r=new Proxy(e,pn)),r):e},set(t,n,e){return G(t,n,R(e)),!0},deleteProperty(t,n){return G(t,n,void 0,!0),!0}};function yn(t){return n=>{if(B(n)){let e;(e=wt.get(n))||wt.set(n,e=new Proxy(n,pn)),t(e)}return n}}let j={};function vn(t){j.stack&&t.setAttribute("stack",j.stack),j.position&&t.setAttribute("position",j.position),j.max!==void 0&&t.setAttribute("max",String(j.max)),j.appearance&&t.setAttribute("appearance",j.appearance),j.inverse!==void 0&&(j.inverse?t.setAttribute("inverse",""):t.removeAttribute("inverse"))}function fe(t){j={...j,...t},!(typeof document>"u")&&document.querySelectorAll("kai-toast-region").forEach(n=>vn(n))}const de=5e3,he=7e3,{toasts:It,setToasts:ut,mounted:je,setMounted:ge}=F(()=>{const[t,n]=gn([]),[e,r]=M(!1);return{toasts:t,setToasts:n,mounted:e,setMounted:r}});let bn=0;function pe(){return bn+=1,`toast-${bn}`}function ye(t){const n=t.duration??de;return n===0?0:t.action?Math.max(n,he):n}const wn=new Map;function ve(t=null){if(typeof document>"u")return;const n=wn.get(t);if(n&&n.isConnected)return n;const e=document.createElement("kai-toast-region");return document.body.appendChild(e),e.toasts=It,t&&(e.target=t),vn(e),wn.set(t,e),ge(!0),e}function be(t){const n=It.findIndex(e=>e.id===t.id);n>=0?ut(n,t):ut(yn(e=>{e.push(t)}))}function mn(t){ut(n=>n.filter(e=>e.id!==t))}function we(t){return{id:t,dismiss:()=>mn(t),update:n=>{const e=It.findIndex(r=>r.id===t);e>=0&&ut(e,r=>({...r,...n}))}}}function ct(t,n,e){ve(n?.target??null);const r=n?.id??pe(),o={id:r,message:t,variant:n?.variant??e,appearance:n?.appearance??j.appearance??"pill",inverse:n?.inverse??j.inverse??!1,description:n?.description,action:n?.action,duration:n?.duration,dismissible:n?.dismissible,target:n?.target};return be(o),we(r)}const me=Object.assign((t,n)=>ct(t,n,"neutral"),{success:(t,n)=>ct(t,n,"success"),warning:(t,n)=>ct(t,n,"warning"),error:(t,n)=>ct(t,n,"error"),info:(t,n)=>ct(t,n,"info"),dismiss:mn,clear:()=>ut([])}),Se=typeof window<"u"&&typeof customElements<"u"?import("./register-impl-bzrZ44ft.js").then(t=>t.r):Promise.resolve();export{ye as A,ie as E,ne as F,ee as I,se as M,re as S,F as a,Gt as b,A as c,Cn as classifyTool,_n as configureCodeHighlighting,fe as configureToasts,Qt as d,Bn as e,Se as elementsReady,M as f,Nn as g,Yn as h,Fn as i,qn as isCodeHighlightingEnabled,Gn as j,Ct as k,te as l,Xn as m,Tn as n,tt as o,In as p,$n as q,Xt as r,p as s,Pn as t,me as toast,m as u,oe as v,gn as w,yn as x,R as y,Vt as z};
|
|
1
|
+
const Sn={bash:()=>import("./bash-InADTalH.js"),javascript:()=>import("./javascript-C25yR2R2.js"),typescript:()=>import("./typescript-RycA9KXf.js"),tsx:()=>import("./tsx-B8rCNbgL.js"),html:()=>import("./html-CPZ3oZQ7.js"),css:()=>import("./css-M7EaDHN_.js"),json:()=>import("./json-DxJze_jm.js"),vue:()=>import("./vue-BmIZj4XD.js"),svelte:()=>import("./svelte--5p79yCD.js")},On={"github-dark-dimmed":()=>import("./github-dark-dimmed-DUshB20C.js"),"github-light":()=>import("./github-light-JYsPkUQd.js")},xn={js:"javascript",ts:"typescript",jsx:"tsx",sh:"bash",shell:"bash"},Nt="github-dark-dimmed";let Ot=!0,xt={...Sn},At={...On},kt={...xn},jt=null;const zt=new Set,Ft=new Set;function An(){return jt||(jt=(async()=>{const[{createHighlighterCore:t},{createJavaScriptRegexEngine:n}]=await Promise.all([import("./core-C8fzo39E.js"),import("./engine-javascript-C1x7zo1_.js")]);return t({themes:[],langs:[],engine:n()})})()),jt}function Lt(t){return kt[t]??t}async function kn(t,n){const e=Lt(n);if(zt.has(e))return!0;const r=xt[e];return r?(await t.loadLanguage(r()),zt.add(e),!0):!1}async function Rt(t,n){if(Ft.has(n))return!0;const e=At[n];return e?(await t.loadTheme(e()),Ft.add(n),!0):!1}function jn(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">")}function lt(t){return`<pre><code>${jn(t)}</code></pre>`}async function Pn(t,n,e){if(!Ot||!t)return lt(t);try{const r=await An();if(!await kn(r,n))return lt(t);const o=await Rt(r,e)?e:await Rt(r,Nt)?Nt:null;return o?r.codeToHtml(t,{lang:Lt(n),theme:o}):lt(t)}catch{return lt(t)}}function _n(t){t.enabled!==void 0&&(Ot=t.enabled),t.languages&&(xt={...xt,...t.languages}),t.themes&&(At={...At,...t.themes}),t.aliases&&(kt={...kt,...t.aliases})}function qn(){return Ot}function Cn(t){const n=t.toLowerCase();return n?n.includes("bash")||n.includes("command")||n.includes("shell")||n.includes("terminal")||n.includes("exec")?"command":n.includes("edit")||n.includes("write")||n.includes("patch")||n.includes("replace")||n.includes("delete")?"file-change":n.includes("search")||n.includes("grep")||n.includes("glob")||n.includes("find")?"search":n.includes("fetch")||n.includes("http")||n.includes("browse")||n.includes("crawl")?"fetch":n.includes("mcp")?"mcp":n.includes("image")||n.includes("screenshot")||n.includes("vision")?"image":"generic":"generic"}const p={context:void 0,registry:void 0,effects:void 0,done:!1,getContextId(){return Kt(this.context.count)},getNextContextId(){return Kt(this.context.count++)}};function Kt(t){const n=String(t),e=n.length-1;return p.context.id+(e?String.fromCharCode(96+e):"")+n}function Pt(t){p.context=t}function Vn(){return{...p.context,id:p.getNextContextId(),count:0}}const Oe=!1,En=(t,n)=>t===n,E=Symbol("solid-proxy"),Jt=typeof Proxy=="function",X=Symbol("solid-track"),xe=Symbol("solid-dev-component"),at={equals:En};let Y=null,Ut=en;const P=1,Z=2,Wt={owned:null,cleanups:null,context:null,owner:null},_t={};var f=null;let c=null,J=null,U=null,g=null,b=null,O=null,ft=0;function F(t,n){const e=g,r=f,o=t.length===0,s=n===void 0?r:n,i=o?Wt:{owned:null,cleanups:null,context:s?s.context:null,owner:s},u=o?t:()=>t(()=>m(()=>z(i)));f=i,g=null;try{return k(u,!0)}finally{g=e,f=r}}function M(t,n){n=n?Object.assign({},at,n):at;const e={value:t,observers:null,observerSlots:null,comparator:n.equals||void 0},r=o=>(typeof o=="function"&&(c&&c.running&&c.sources.has(e)?o=o(e.tValue):o=o(e.value)),tn(e,o));return[Zt.bind(e),r]}function Bt(t,n,e){const r=et(t,n,!0,P);J&&c&&c.running?b.push(r):W(r)}function Gt(t,n,e){const r=et(t,n,!1,P);J&&c&&c.running?b.push(r):W(r)}function Qt(t,n,e){Ut=Kn;const r=et(t,n,!1,P),o=nt&&Ct(nt);o&&(r.suspense=o),(!e||!e.render)&&(r.user=!0),O?O.push(r):W(r)}function A(t,n,e){e=e?Object.assign({},at,e):at;const r=et(t,n,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=e.equals||void 0,J&&c&&c.running?(r.tState=P,b.push(r)):W(r),Zt.bind(r)}function Mn(t){return t&&typeof t=="object"&&"then"in t}function $n(t,n,e){let r,o,s;typeof n=="function"?(r=t,o=n,s=e||{}):(r=!0,o=t,s=n||{});let i=null,u=_t,l=null,d=!1,h=!1,a="initialValue"in s,w=typeof r=="function"&&A(r);const S=new Set,[_,D]=(s.storage||M)(s.initialValue),[N,K]=M(void 0),[q,C]=M(void 0,{equals:!1}),[V,T]=M(a?"ready":"unresolved");p.context&&(l=p.getNextContextId(),s.ssrLoadFrom==="initial"?u=s.initialValue:p.load&&p.has(l)&&(u=p.load(l)));function H(y,v,$,x){return i===y&&(i=null,x!==void 0&&(a=!0),(y===u||v===u)&&s.onHydrated&&queueMicrotask(()=>s.onHydrated(x,{value:v})),u=_t,c&&y&&d?(c.promises.delete(y),d=!1,k(()=>{c.running=!0,Tt(v,$)},!1)):Tt(v,$)),v}function Tt(y,v){k(()=>{v===void 0&&D(()=>y),T(v!==void 0?"errored":a?"ready":"unresolved"),K(v);for(const $ of S.keys())$.decrement();S.clear()},!1)}function mt(){const y=nt&&Ct(nt),v=_(),$=N();if($!==void 0&&!i)throw $;return g&&!g.user&&y&&Bt(()=>{q(),i&&(y.resolved&&c&&d?c.promises.add(i):S.has(y)||(y.increment(),S.add(y)))}),v}function St(y=!0){if(y!==!1&&h)return;h=!1;const v=w?w():r;if(d=c&&c.running,v==null||v===!1){H(i,m(_));return}c&&i&&c.promises.delete(i);let $;const x=u!==_t?u:m(()=>{try{return o(v,{value:_(),refetching:y})}catch(Q){$=Q}});if($!==void 0){H(i,void 0,ht($),v);return}else if(!Mn(x))return H(i,x,void 0,v),x;return i=x,"v"in x?(x.s===1?H(i,x.v,void 0,v):H(i,void 0,ht(x.v),v),x):(h=!0,queueMicrotask(()=>h=!1),k(()=>{T(a?"refreshing":"pending"),C()},!1),x.then(Q=>H(x,Q,void 0,v),Q=>H(x,void 0,ht(Q),v)))}Object.defineProperties(mt,{state:{get:()=>V()},error:{get:()=>N()},loading:{get(){const y=V();return y==="pending"||y==="refreshing"}},latest:{get(){if(!a)return mt();const y=N();if(y&&!i)throw y;return _()}}});let Ht=f;return w?Bt(()=>(Ht=f,St(!1))):St(!1),[mt,{refetch:y=>Xt(Ht,()=>St(y)),mutate:D}]}function Dn(t){return k(t,!1)}function m(t){if(!U&&g===null)return t();const n=g;g=null;try{return U?U.untrack(t):t()}finally{g=n}}function In(t,n,e){const r=Array.isArray(t);let o,s=e&&e.defer;return i=>{let u;if(r){u=Array(t.length);for(let d=0;d<t.length;d++)u[d]=t[d]()}else u=t();if(s)return s=!1,i;const l=m(()=>n(u,o,i));return o=u,l}}function Tn(t){Qt(()=>m(t))}function tt(t){return f===null||(f.cleanups===null?f.cleanups=[t]:f.cleanups.push(t)),t}function Hn(t,n){Y||(Y=Symbol("error")),f=et(void 0,void 0,!0),f.context={...f.context,[Y]:[n]},c&&c.running&&c.sources.add(f);try{return t()}catch(e){ot(e)}finally{f=f.owner}}function qt(){return g}function Nn(){return f}function Xt(t,n){const e=f,r=g;f=t,g=null;try{return k(n,!0)}catch(o){ot(o)}finally{f=e,g=r}}function zn(t){if(c&&c.running)return t(),c.done;const n=g,e=f;return Promise.resolve().then(()=>{g=n,f=e;let r;return(J||nt)&&(r=c||(c={sources:new Set,effects:[],promises:new Set,disposed:new Set,queue:new Set,running:!0}),r.done||(r.done=new Promise(o=>r.resolve=o)),r.running=!0),k(t,!1),g=f=null,r?r.done:void 0})}const[Ae,Yt]=M(!1);function Fn(t,n){const e=Symbol("context");return{id:e,Provider:Jn(e),defaultValue:t}}function Ct(t){let n;return f&&f.context&&(n=f.context[t.id])!==void 0?n:t.defaultValue}function Vt(t){const n=A(t),e=A(()=>Et(n()));return e.toArray=()=>{const r=e();return Array.isArray(r)?r:r!=null?[r]:[]},e}let nt;function Zt(){const t=c&&c.running;if(this.sources&&(t?this.tState:this.state))if((t?this.tState:this.state)===P)W(this);else{const n=b;b=null,k(()=>dt(this),!1),b=n}if(g){const n=this.observers;if(!n||n[n.length-1]!==g){const e=n?n.length:0;g.sources?(g.sources.push(this),g.sourceSlots.push(e)):(g.sources=[this],g.sourceSlots=[e]),n?(n.push(g),this.observerSlots.push(g.sources.length-1)):(this.observers=[g],this.observerSlots=[g.sources.length-1])}}return t&&c.sources.has(this)?this.tValue:this.value}function tn(t,n,e){let r=c&&c.running&&c.sources.has(t)?t.tValue:t.value;if(!t.comparator||!t.comparator(r,n)){if(c){const o=c.running;(o||!e&&c.sources.has(t))&&(c.sources.add(t),t.tValue=n),o||(t.value=n)}else t.value=n;t.observers&&t.observers.length&&k(()=>{for(let o=0;o<t.observers.length;o+=1){const s=t.observers[o],i=c&&c.running;i&&c.disposed.has(s)||((i?!s.tState:!s.state)&&(s.pure?b.push(s):O.push(s),s.observers&&rn(s)),i?s.tState=P:s.state=P)}if(b.length>1e6)throw b=[],new Error},!1)}return n}function W(t){if(!t.fn)return;z(t);const n=ft;nn(t,c&&c.running&&c.sources.has(t)?t.tValue:t.value,n),c&&!c.running&&c.sources.has(t)&&queueMicrotask(()=>{k(()=>{c&&(c.running=!0),g=f=t,nn(t,t.tValue,n),g=f=null},!1)})}function nn(t,n,e){let r;const o=f,s=g;g=f=t;try{r=t.fn(n)}catch(i){return t.pure&&(c&&c.running?(t.tState=P,t.tOwned&&t.tOwned.forEach(z),t.tOwned=void 0):(t.state=P,t.owned&&t.owned.forEach(z),t.owned=null)),t.updatedAt=e+1,ot(i)}finally{g=s,f=o}(!t.updatedAt||t.updatedAt<=e)&&(t.updatedAt!=null&&"observers"in t?tn(t,r,!0):c&&c.running&&t.pure?(c.sources.has(t)||(t.value=r),c.sources.add(t),t.tValue=r):t.value=r,t.updatedAt=e)}function et(t,n,e,r=P,o){const s={fn:t,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:n,owner:f,context:f?f.context:null,pure:e};if(c&&c.running&&(s.state=0,s.tState=r),f===null||f!==Wt&&(c&&c.running&&f.pure?f.tOwned?f.tOwned.push(s):f.tOwned=[s]:f.owned?f.owned.push(s):f.owned=[s]),U&&s.fn){const i=s.fn,[u,l]=M(void 0,{equals:!1}),d=U.factory(i,l);tt(()=>d.dispose());let h;const a=()=>zn(l).then(()=>{h&&(h.dispose(),h=void 0)});s.fn=w=>(u(),c&&c.running?(h||(h=U.factory(i,a)),h.track(w)):d.track(w))}return s}function rt(t){const n=c&&c.running;if((n?t.tState:t.state)===0)return;if((n?t.tState:t.state)===Z)return dt(t);if(t.suspense&&m(t.suspense.inFallback))return t.suspense.effects.push(t);const e=[t];for(;(t=t.owner)&&(!t.updatedAt||t.updatedAt<ft);){if(n&&c.disposed.has(t))return;(n?t.tState:t.state)&&e.push(t)}for(let r=e.length-1;r>=0;r--){if(t=e[r],n){let o=t,s=e[r+1];for(;(o=o.owner)&&o!==s;)if(c.disposed.has(o))return}if((n?t.tState:t.state)===P)W(t);else if((n?t.tState:t.state)===Z){const o=b;b=null,k(()=>dt(t,e[0]),!1),b=o}}}function k(t,n){if(b)return t();let e=!1;n||(b=[]),O?e=!0:O=[],ft++;try{const r=t();return Ln(e),r}catch(r){e||(O=null),b=null,ot(r)}}function Ln(t){if(b&&(J&&c&&c.running?Rn(b):en(b),b=null),t)return;let n;if(c){if(!c.promises.size&&!c.queue.size){const r=c.sources,o=c.disposed;O.push.apply(O,c.effects),n=c.resolve;for(const s of O)"tState"in s&&(s.state=s.tState),delete s.tState;c=null,k(()=>{for(const s of o)z(s);for(const s of r){if(s.value=s.tValue,s.owned)for(let i=0,u=s.owned.length;i<u;i++)z(s.owned[i]);s.tOwned&&(s.owned=s.tOwned),delete s.tValue,delete s.tOwned,s.tState=0}Yt(!1)},!1)}else if(c.running){c.running=!1,c.effects.push.apply(c.effects,O),O=null,Yt(!0);return}}const e=O;O=null,e.length&&k(()=>Ut(e),!1),n&&n()}function en(t){for(let n=0;n<t.length;n++)rt(t[n])}function Rn(t){for(let n=0;n<t.length;n++){const e=t[n],r=c.queue;r.has(e)||(r.add(e),J(()=>{r.delete(e),k(()=>{c.running=!0,rt(e)},!1),c&&(c.running=!1)}))}}function Kn(t){let n,e=0;for(n=0;n<t.length;n++){const r=t[n];r.user?t[e++]=r:rt(r)}if(p.context){if(p.count){p.effects||(p.effects=[]),p.effects.push(...t.slice(0,e));return}Pt()}for(p.effects&&(p.done||!p.count)&&(t=[...p.effects,...t],e+=p.effects.length,delete p.effects),n=0;n<e;n++)rt(t[n])}function dt(t,n){const e=c&&c.running;e?t.tState=0:t.state=0;for(let r=0;r<t.sources.length;r+=1){const o=t.sources[r];if(o.sources){const s=e?o.tState:o.state;s===P?o!==n&&(!o.updatedAt||o.updatedAt<ft)&&rt(o):s===Z&&dt(o,n)}}}function rn(t){const n=c&&c.running;for(let e=0;e<t.observers.length;e+=1){const r=t.observers[e];(n?!r.tState:!r.state)&&(n?r.tState=Z:r.state=Z,r.pure?b.push(r):O.push(r),r.observers&&rn(r))}}function z(t){let n;if(t.sources)for(;t.sources.length;){const e=t.sources.pop(),r=t.sourceSlots.pop(),o=e.observers;if(o&&o.length){const s=o.pop(),i=e.observerSlots.pop();r<o.length&&(s.sourceSlots[i]=r,o[r]=s,e.observerSlots[r]=i)}}if(t.tOwned){for(n=t.tOwned.length-1;n>=0;n--)z(t.tOwned[n]);delete t.tOwned}if(c&&c.running&&t.pure)on(t,!0);else if(t.owned){for(n=t.owned.length-1;n>=0;n--)z(t.owned[n]);t.owned=null}if(t.cleanups){for(n=t.cleanups.length-1;n>=0;n--)t.cleanups[n]();t.cleanups=null}c&&c.running?t.tState=0:t.state=0}function on(t,n){if(n||(t.tState=0,c.disposed.add(t)),t.owned)for(let e=0;e<t.owned.length;e++)on(t.owned[e])}function ht(t){return t instanceof Error?t:new Error(typeof t=="string"?t:"Unknown error",{cause:t})}function sn(t,n,e){try{for(const r of n)r(t)}catch(r){ot(r,e&&e.owner||null)}}function ot(t,n=f){const e=Y&&n&&n.context&&n.context[Y],r=ht(t);if(!e)throw r;O?O.push({fn(){sn(r,e,n)},state:P}):sn(r,e,n)}function Et(t){if(typeof t=="function"&&!t.length)return Et(t());if(Array.isArray(t)){const n=[];for(let e=0;e<t.length;e++){const r=Et(t[e]);if(Array.isArray(r))if(r.length<32768)n.push.apply(n,r);else for(let o=0;o<r.length;o++)n.push(r[o]);else n.push(r)}return n}return t}function Jn(t,n){return function(e){let r;return Gt(()=>r=m(()=>(f.context={...f.context,[t]:e.value},Vt(()=>e.children))),void 0),r}}const Mt=Symbol("fallback");function gt(t){for(let n=0;n<t.length;n++)t[n]()}function Un(t,n,e={}){let r=[],o=[],s=[],i=0,u=n.length>1?[]:null;return tt(()=>gt(s)),()=>{let l=t()||[],d=l.length,h,a;return l[X],m(()=>{let S,_,D,N,K,q,C,V,T;if(d===0)i!==0&&(gt(s),s=[],r=[],o=[],i=0,u&&(u=[])),e.fallback&&(r=[Mt],o[0]=F(H=>(s[0]=H,e.fallback())),i=1);else if(i===0){for(o=new Array(d),a=0;a<d;a++)r[a]=l[a],o[a]=F(w);i=d}else{for(D=new Array(d),N=new Array(d),u&&(K=new Array(d)),q=0,C=Math.min(i,d);q<C&&r[q]===l[q];q++);for(C=i-1,V=d-1;C>=q&&V>=q&&r[C]===l[V];C--,V--)D[V]=o[C],N[V]=s[C],u&&(K[V]=u[C]);for(S=new Map,_=new Array(V+1),a=V;a>=q;a--)T=l[a],h=S.get(T),_[a]=h===void 0?-1:h,S.set(T,a);for(h=q;h<=C;h++)T=r[h],a=S.get(T),a!==void 0&&a!==-1?(D[a]=o[h],N[a]=s[h],u&&(K[a]=u[h]),a=_[a],S.set(T,a)):s[h]();for(a=q;a<d;a++)a in D?(o[a]=D[a],s[a]=N[a],u&&(u[a]=K[a],u[a](a))):o[a]=F(w);o=o.slice(0,i=d),r=l.slice(0)}return o});function w(S){if(s[a]=S,u){const[_,D]=M(a);return u[a]=D,n(l[a],_)}return n(l[a])}}}function Wn(t,n,e={}){let r=[],o=[],s=[],i=[],u=0,l;return tt(()=>gt(s)),()=>{const d=t()||[],h=d.length;return d[X],m(()=>{if(h===0)return u!==0&&(gt(s),s=[],r=[],o=[],u=0,i=[]),e.fallback&&(r=[Mt],o[0]=F(w=>(s[0]=w,e.fallback())),u=1),o;for(r[0]===Mt&&(s[0](),s=[],r=[],o=[],u=0),l=0;l<h;l++)l<r.length&&r[l]!==d[l]?i[l](()=>d[l]):l>=r.length&&(o[l]=F(a));for(;l<r.length;l++)s[l]();return u=i.length=s.length=h,r=d.slice(0),o=o.slice(0,u)});function a(w){s[l]=w;const[S,_]=M(d[l]);return i[l]=_,n(S,l)}}}let un=!1;function Bn(){un=!0}function Gn(t,n){if(un&&p.context){const e=p.context;Pt(Vn());const r=m(()=>t(n||{}));return Pt(e),r}return m(()=>t(n||{}))}function pt(){return!0}const $t={get(t,n,e){return n===E?e:t.get(n)},has(t,n){return n===E?!0:t.has(n)},set:pt,deleteProperty:pt,getOwnPropertyDescriptor(t,n){return{configurable:!0,enumerable:!0,get(){return t.get(n)},set:pt,deleteProperty:pt}},ownKeys(t){return t.keys()}};function Dt(t){return(t=typeof t=="function"?t():t)?t:{}}function Qn(){for(let t=0,n=this.length;t<n;++t){const e=this[t]();if(e!==void 0)return e}}function Xn(...t){let n=!1;for(let i=0;i<t.length;i++){const u=t[i];n=n||!!u&&E in u,t[i]=typeof u=="function"?(n=!0,A(u)):u}if(Jt&&n)return new Proxy({get(i){for(let u=t.length-1;u>=0;u--){const l=Dt(t[u])[i];if(l!==void 0)return l}},has(i){for(let u=t.length-1;u>=0;u--)if(i in Dt(t[u]))return!0;return!1},keys(){const i=[];for(let u=0;u<t.length;u++)i.push(...Object.keys(Dt(t[u])));return[...new Set(i)]}},$t);const e={},r=Object.create(null);for(let i=t.length-1;i>=0;i--){const u=t[i];if(!u)continue;const l=Object.getOwnPropertyNames(u);for(let d=l.length-1;d>=0;d--){const h=l[d];if(h==="__proto__"||h==="constructor")continue;const a=Object.getOwnPropertyDescriptor(u,h);if(!r[h])r[h]=a.get?{enumerable:!0,configurable:!0,get:Qn.bind(e[h]=[a.get.bind(u)])}:a.value!==void 0?a:void 0;else{const w=e[h];w&&(a.get?w.push(a.get.bind(u)):a.value!==void 0&&w.push(()=>a.value))}}}const o={},s=Object.keys(r);for(let i=s.length-1;i>=0;i--){const u=s[i],l=r[u];l&&l.get?Object.defineProperty(o,u,l):o[u]=l?l.value:void 0}return o}function Yn(t,...n){const e=n.length;if(Jt&&E in t){const o=e>1?n.flat():n[0],s=n.map(i=>new Proxy({get(u){return i.includes(u)?t[u]:void 0},has(u){return i.includes(u)&&u in t},keys(){return i.filter(u=>u in t)}},$t));return s.push(new Proxy({get(i){return o.includes(i)?void 0:t[i]},has(i){return o.includes(i)?!1:i in t},keys(){return Object.keys(t).filter(i=>!o.includes(i))}},$t)),s}const r=[];for(let o=0;o<=e;o++)r[o]={};for(const o of Object.getOwnPropertyNames(t)){let s=e;for(let u=0;u<n.length;u++)if(n[u].includes(o)){s=u;break}const i=Object.getOwnPropertyDescriptor(t,o);!i.get&&!i.set&&i.enumerable&&i.writable&&i.configurable?r[s][o]=i.value:Object.defineProperty(r[s],o,i)}return r}let Zn=0;function te(){return p.context?p.getNextContextId():`cl-${Zn++}`}const cn=t=>`Stale read from <${t}>.`;function ne(t){const n="fallback"in t&&{fallback:()=>t.fallback};return A(Un(()=>t.each,t.children,n||void 0))}function ee(t){const n="fallback"in t&&{fallback:()=>t.fallback};return A(Wn(()=>t.each,t.children,n||void 0))}function re(t){const n=t.keyed,e=A(()=>t.when,void 0,void 0),r=n?e:A(e,void 0,{equals:(o,s)=>!o==!s});return A(()=>{const o=r();if(o){const s=t.children;return typeof s=="function"&&s.length>0?m(()=>s(n?o:()=>{if(!m(r))throw cn("Show");return e()})):s}return t.fallback},void 0,void 0)}function oe(t){const n=Vt(()=>t.children),e=A(()=>{const r=n(),o=Array.isArray(r)?r:[r];let s=()=>{};for(let i=0;i<o.length;i++){const u=i,l=o[i],d=s,h=A(()=>d()?void 0:l.when,void 0,void 0),a=l.keyed?h:A(h,void 0,{equals:(w,S)=>!w==!S});s=()=>d()||(a()?[u,h,l]:void 0)}return s});return A(()=>{const r=e()();if(!r)return t.fallback;const[o,s,i]=r,u=i.children;return typeof u=="function"&&u.length>0?m(()=>u(i.keyed?s():()=>{var l;if(((l=m(e)())==null?void 0:l[0])!==o)throw cn("Match");return s()})):u},void 0,void 0)}function se(t){return t}let yt;function ie(t){let n;p.context&&p.load&&(n=p.load(p.getContextId()));const[e,r]=M(n,void 0);return yt||(yt=new Set),yt.add(r),tt(()=>yt.delete(r)),A(()=>{let o;if(o=e()){const s=t.fallback;return typeof s=="function"&&s.length?m(()=>s(o,()=>r())):s}return Hn(()=>t.children,r)},void 0,void 0)}const vt=Symbol("store-raw"),L=Symbol("store-node"),I=Symbol("store-has"),ln=Symbol("store-self");function an(t){let n=t[E];if(!n&&(Object.defineProperty(t,E,{value:n=new Proxy(t,le)}),!Array.isArray(t))){const e=Object.keys(t),r=Object.getOwnPropertyDescriptors(t),o=Object.getPrototypeOf(t),s=o!==null&&t!==null&&typeof t=="object"&&!Array.isArray(t)&&o!==Object.prototype;if(s){const i=Object.getOwnPropertyDescriptors(o);e.push(...Object.keys(i)),Object.assign(r,i)}for(let i=0,u=e.length;i<u;i++){const l=e[i];s&&l==="constructor"||r[l].get&&Object.defineProperty(t,l,{configurable:!0,enumerable:r[l].enumerable,get:r[l].get.bind(n)})}}return n}function B(t){let n;return t!=null&&typeof t=="object"&&(t[E]||!(n=Object.getPrototypeOf(t))||n===Object.prototype||Array.isArray(t))}function R(t,n=new Set){let e,r,o,s;if(e=t!=null&&t[vt])return e;if(!B(t)||n.has(t))return t;if(Array.isArray(t)){Object.isFrozen(t)?t=t.slice(0):n.add(t);for(let i=0,u=t.length;i<u;i++)o=t[i],(r=R(o,n))!==o&&(t[i]=r)}else{Object.isFrozen(t)?t=Object.assign({},t):n.add(t);const i=Object.keys(t),u=Object.getOwnPropertyDescriptors(t);for(let l=0,d=i.length;l<d;l++)s=i[l],!u[s].get&&(o=t[s],(r=R(o,n))!==o&&(t[s]=r))}return t}function bt(t,n){let e=t[n];return e||Object.defineProperty(t,n,{value:e=Object.create(null)}),e}function st(t,n,e){if(t[n])return t[n];const[r,o]=M(e,{equals:!1,internal:!0});return r.$=o,t[n]=r}function ue(t,n){const e=Reflect.getOwnPropertyDescriptor(t,n);return!e||e.get||!e.configurable||n===E||n===L||(delete e.value,delete e.writable,e.get=()=>t[E][n]),e}function fn(t){qt()&&st(bt(t,L),ln)()}function ce(t){return fn(t),Reflect.ownKeys(t)}const le={get(t,n,e){if(n===vt)return t;if(n===E)return e;if(n===X)return fn(t),e;const r=bt(t,L),o=r[n];let s=o?o():t[n];if(n===L||n===I||n==="__proto__")return s;if(!o){const i=Object.getOwnPropertyDescriptor(t,n);qt()&&(typeof s!="function"||t.hasOwnProperty(n))&&!(i&&i.get)&&(s=st(r,n,s)())}return B(s)?an(s):s},has(t,n){return n===vt||n===E||n===X||n===L||n===I||n==="__proto__"?!0:(qt()&&st(bt(t,I),n)(),n in t)},set(){return!0},deleteProperty(){return!0},ownKeys:ce,getOwnPropertyDescriptor:ue};function G(t,n,e,r=!1){if(n==="__proto__"||!r&&t[n]===e)return;const o=t[n],s=t.length;e===void 0?(delete t[n],t[I]&&t[I][n]&&o!==void 0&&t[I][n].$()):(t[n]=e,t[I]&&t[I][n]&&o===void 0&&t[I][n].$());let i=bt(t,L),u;if((u=st(i,n,o))&&u.$(()=>e),Array.isArray(t)&&t.length!==s){for(let l=t.length;l<s;l++)(u=i[l])&&u.$();(u=st(i,"length",s))&&u.$(t.length)}(u=i[ln])&&u.$()}function dn(t,n){const e=Object.keys(n);for(let r=0;r<e.length;r+=1){const o=e[r];hn(o)||G(t,o,n[o])}}function hn(t){return t==="__proto__"||t==="constructor"||t==="prototype"}function ae(t,n){if(typeof n=="function"&&(n=n(t)),n=R(n),Array.isArray(n)){if(t===n)return;let e=0,r=n.length;for(;e<r;e++){const o=n[e];t[e]!==o&&G(t,e,o)}G(t,"length",r)}else dn(t,n)}function it(t,n,e=[]){let r,o=t;if(n.length>1){r=n.shift();const i=typeof r,u=Array.isArray(t);if(i==="string"&&(r==="__proto__"||n.length>1&&hn(r)))return;if(Array.isArray(r)){for(let l=0;l<r.length;l++)it(t,[r[l]].concat(n),e);return}else if(u&&i==="function"){for(let l=0;l<t.length;l++)r(t[l],l)&&it(t,[l].concat(n),e);return}else if(u&&i==="object"){const{from:l=0,to:d=t.length-1,by:h=1}=r;for(let a=l;a<=d;a+=h)it(t,[a].concat(n),e);return}else if(n.length>1){it(t[r],n,[r].concat(e));return}o=t[r],e=[r].concat(e)}let s=n[0];typeof s=="function"&&(s=s(o,e),s===o)||r===void 0&&s==null||(s=R(s),r===void 0||B(o)&&B(s)&&!Array.isArray(s)?dn(o,s):G(t,r,s))}function gn(...[t,n]){const e=R(t||{}),r=Array.isArray(e),o=an(e);function s(...i){Dn(()=>{r&&i.length===1?ae(e,i[0]):it(e,i)})}return[o,s]}const ke=Symbol("store-root"),wt=new WeakMap,pn={get(t,n){if(n===vt)return t;const e=t[n];if(n===E||n===X||n===L||n===I||n==="__proto__")return e;let r;return B(e)?wt.get(e)||(wt.set(e,r=new Proxy(e,pn)),r):e},set(t,n,e){return G(t,n,R(e)),!0},deleteProperty(t,n){return G(t,n,void 0,!0),!0}};function yn(t){return n=>{if(B(n)){let e;(e=wt.get(n))||wt.set(n,e=new Proxy(n,pn)),t(e)}return n}}let j={};function vn(t){j.stack&&t.setAttribute("stack",j.stack),j.position&&t.setAttribute("position",j.position),j.max!==void 0&&t.setAttribute("max",String(j.max)),j.appearance&&t.setAttribute("appearance",j.appearance),j.inverse!==void 0&&(j.inverse?t.setAttribute("inverse",""):t.removeAttribute("inverse"))}function fe(t){j={...j,...t},!(typeof document>"u")&&document.querySelectorAll("kai-toast-region").forEach(n=>vn(n))}const de=5e3,he=7e3,{toasts:It,setToasts:ut,mounted:je,setMounted:ge}=F(()=>{const[t,n]=gn([]),[e,r]=M(!1);return{toasts:t,setToasts:n,mounted:e,setMounted:r}});let bn=0;function pe(){return bn+=1,`toast-${bn}`}function ye(t){const n=t.duration??de;return n===0?0:t.action?Math.max(n,he):n}const wn=new Map;function ve(t=null){if(typeof document>"u")return;const n=wn.get(t);if(n&&n.isConnected)return n;const e=document.createElement("kai-toast-region");return document.body.appendChild(e),e.toasts=It,t&&(e.target=t),vn(e),wn.set(t,e),ge(!0),e}function be(t){const n=It.findIndex(e=>e.id===t.id);n>=0?ut(n,t):ut(yn(e=>{e.push(t)}))}function mn(t){ut(n=>n.filter(e=>e.id!==t))}function we(t){return{id:t,dismiss:()=>mn(t),update:n=>{const e=It.findIndex(r=>r.id===t);e>=0&&ut(e,r=>({...r,...n}))}}}function ct(t,n,e){ve(n?.target??null);const r=n?.id??pe(),o={id:r,message:t,variant:n?.variant??e,appearance:n?.appearance??j.appearance??"pill",inverse:n?.inverse??j.inverse??!1,description:n?.description,action:n?.action,duration:n?.duration,dismissible:n?.dismissible,target:n?.target};return be(o),we(r)}const me=Object.assign((t,n)=>ct(t,n,"neutral"),{success:(t,n)=>ct(t,n,"success"),warning:(t,n)=>ct(t,n,"warning"),error:(t,n)=>ct(t,n,"error"),info:(t,n)=>ct(t,n,"info"),dismiss:mn,clear:()=>ut([])}),Se=typeof window<"u"&&typeof customElements<"u"?import("./register-impl-AxIlqjo7.js").then(t=>t.r):Promise.resolve();export{ye as A,ie as E,ne as F,ee as I,se as M,re as S,F as a,Gt as b,A as c,Cn as classifyTool,_n as configureCodeHighlighting,fe as configureToasts,Qt as d,Bn as e,Se as elementsReady,M as f,Nn as g,Yn as h,Fn as i,qn as isCodeHighlightingEnabled,Gn as j,Ct as k,te as l,Xn as m,Tn as n,tt as o,In as p,$n as q,Xt as r,p as s,Pn as t,me as toast,m as u,oe as v,gn as w,yn as x,R as y,Vt as z};
|
package/dist/llms/llms-full.txt
CHANGED
|
@@ -449,7 +449,7 @@ _No events._
|
|
|
449
449
|
| `size` | `size` | `undefined \| "sm" \| "md" \| "lg" \| "icon" \| "icon-sm"` | Size token. `icon` / `icon-sm` are square (for icon-only buttons); `sm` / `md` / `lg` size text buttons. Defaults to `md`. |
|
|
450
450
|
| `icon` | `icon` | `undefined \| string` | Leading icon: a named icon (e.g. `"mic"`, `"plus"`), an image URL/data-URI, or plain text. Renders before any slotted label. |
|
|
451
451
|
| `iconTrailing` | `icon-trailing` | `undefined \| string` | Trailing icon, after the label (e.g. `"chevron-down"` for a menu affordance). |
|
|
452
|
-
| `label` | `label` | `undefined \| string` | Accessible name. REQUIRED for icon-only buttons (no visible text); ignored when you slot visible text, which already names the button. |
|
|
452
|
+
| `label` | `label` | `undefined \| string` | Accessible name. REQUIRED for icon-only buttons (no visible text); ignored when you slot visible text, which already names the button. An `aria-label` on top of visible text REPLACES that name rather than adding to it, so a button reading "Save" that answers to "Submit" is unusable by speech input (WCAG 2.5.3, Label in Name). The visible text wins. An `icon` / `icon-sm` size hides the slot, which makes the button icon-only whatever you slotted, so `label` is what names it there. |
|
|
453
453
|
| `disabled` | `disabled` | `undefined \| false \| true` | Disable the button (non-interactive, dimmed). |
|
|
454
454
|
| `full` | `full` | `undefined \| false \| true` | Stretch the button to the full width of its container (a block button), e.g. a card CTA or a stacked action. Attribute: `full`. |
|
|
455
455
|
| `align` | `align` | `undefined \| "start" \| "center" \| "end"` | Justify the button's content: `start`, `center` (default), or `end`. Combine with `full` for a full-width, left-aligned button. |
|
|
@@ -629,6 +629,7 @@ _No events._
|
|
|
629
629
|
| `triggers` | — | `undefined \| { char: string; kind: string; items?: undefined \| { id: string; label: string; icon?: undefined \| string; description?: undefined \| string; group?: undefined \| string; kind?: undefined \| string; promptText?: undefined \| string; data?: undefined \| Record<string, unknown> }[] }[]` | Rich entity triggers. Each `{ char, kind, items }` opens a caret-anchored menu that inserts an atomic pill (`/` skills, `@` agents/plugins). Set as a JS property; forwarded to the input. |
|
|
630
630
|
| `kindIcons` | — | `undefined \| Record<string, string>` | Default icon per entity kind (kind → image src) for pills/menu items. |
|
|
631
631
|
| `actionsReveal` | `actions-reveal` | `undefined \| "always" \| "hover"` | Whether each message's action bar is always visible (`'always'`, default) or only revealed on hover of that message row (`'hover'`). |
|
|
632
|
+
| `accept` | `accept` | `undefined \| string` | Which attachment media types the user may stage, in HTML `accept` syntax: `<kai-chat accept="image/*,application/pdf">`. A plain string, so unlike `messages` it DOES work as an attribute. Omitted means no filter. MEDIA TYPES ONLY -- exact (`image/png`) or subtype wildcard (`text/*`). HTML allows a file extension here and this does not: `accept=".py"` THROWS with the entry named, rather than silently resolving to a picker that accepts nothing. It can only NARROW what the kit can already encode: `accept="image/*"` resolves to the four image formats both APIs take, not to every image type the OS offers. Pass the SAME string to `toOpenAIMessages(msgs, { accept })` and the picker and the wire cannot disagree -- both resolve it through `resolveMediaPolicy` against one declaration. That declaration is readable as `encodableMediaTypes()` from `@kitn.ai/ui/wire`, if you would rather build your own picker than use this prop. |
|
|
632
633
|
| `messages` | — | `undefined \| { id: string; role: "user" \| "assistant"; parts: ({ type: "text"; text: string; raw?: undefined \| { source: string; payload: unknown } } \| { type: "reasoning"; text: string; label?: undefined \| string; index?: undefined \| number; streamId?: undefined \| string; signature?: undefined \| string; raw?: undefined \| { source: string; payload: unknown } } \| { type: "tool"; tool: { type: string; kind?: undefined \| "command" \| "file-change" \| "search" \| "fetch" \| "mcp" \| "image" \| "generic"; state: "input-streaming" \| "input-available" \| "output-available" \| "output-error"; input?: undefined \| Record<string, unknown>; rawInput?: undefined \| string; output?: undefined \| Record<string, unknown>; toolCallId?: undefined \| string; errorText?: undefined \| string; raw?: undefined \| { source: string; payload: unknown } }; raw?: undefined \| { source: string; payload: unknown } } \| { type: "card"; envelope: { type: string; id: string; data: unknown; title?: undefined \| string; resolution?: undefined \| { kind: "action"; action: string; payload?: unknown; at?: undefined \| string } \| { kind: "submit"; data: unknown; at?: undefined \| string } \| { kind: "dismissed"; at?: undefined \| string } \| { kind: "expired"; reason?: undefined \| string; at?: undefined \| string } }; raw?: undefined \| { source: string; payload: unknown } } \| { type: "source"; source: { id?: undefined \| string; url?: undefined \| string; title?: undefined \| string; snippet?: undefined \| string; index?: undefined \| number }; raw?: undefined \| { source: string; payload: unknown } } \| { type: "file"; attachment: { id: string; type: "file" \| "source-document"; filename?: undefined \| string; mediaType?: undefined \| string; url?: undefined \| string; title?: undefined \| string }; raw?: undefined \| { source: string; payload: unknown } })[]; actions?: undefined \| ("copy" \| "like" \| "dislike" \| "regenerate" \| "edit" \| { id: string; label: string; icon?: undefined \| string; tooltip?: undefined \| string })[]; avatar?: undefined \| { src?: undefined \| string; fallback?: undefined \| string; alt?: undefined \| string }; feedback?: undefined \| "like" \| "dislike" }[]` | The full message thread to render, newest last. Each entry carries its role, ordered `parts`, and optional actions/avatar/feedback. Set as a JS property (`el.messages = [...]`); a NEW array reference per streaming chunk re-renders (mutating in place does not). Omit for an empty thread. Re-declared here (rather than inherited from `ChatThreadProps`) because the ELEMENT registers a `[]` default and renders the empty state without it, while the SolidJS `<ChatThread>` component still requires it. The facade hands it a validated array either way. Matches `<kai-thread>`. |
|
|
633
634
|
| `cardTypes` | — | `undefined \| Record<string, string>` | Optional card type -> custom-element tag overrides/additions for `card` parts (merged over the built-ins). Property: `el.cardTypes`. Typed as a plain string map (not the `CardTagMap` alias) so the generated React wrapper inlines it instead of emitting an unresolved named type. |
|
|
634
635
|
| `cardSchemas` | — | `undefined \| Record<string, object>` | JSON Schemas for the card types this app renders, keyed by envelope type. The companion of `cardTypes`, which says what DRAWS a card while this says what a VALID one looks like. An OBJECT, so it is a JS property only: `el.cardSchemas = { 'pricing-table': pricingSchema }`, never an attribute. `createCardRegistry(...).validationSchemas` is exactly this shape. Without it the kit validates its own seven built-ins and leaves your own card type, the one your app actually cares about, as the only unchecked thing on screen. A schema here WINS over a built-in of the same name. Typed `Record<string, object>` rather than `Record<string, JsonSchema>` deliberately: an imported `.json` schema widens `"type"` to `string`, and an authored one carries `$schema`/`title`/`description`/`additionalProperties`, so the tighter type would reject both of the normal ways to supply one. |
|
|
@@ -638,6 +639,7 @@ _No events._
|
|
|
638
639
|
| Event | `detail` type | Description |
|
|
639
640
|
|---|---|---|
|
|
640
641
|
| `kai-attachments-change` | `CustomEvent<{ attachments: { id: string; type: "file" \| "source-document"; filename?: undefined \| string; mediaType?: undefined \| string; url?: undefined \| string; title?: undefined \| string }[] }>` | The staged attachments changed (file added or removed). Carries the full current list so a consumer can react in real time. |
|
|
642
|
+
| `kai-attachments-rejected` | `CustomEvent<{ rejected: { filename: string; mediaType: string; reason: "filtered" \| "unsupported" }[] }>` | One or more picked files were refused because `accept` excluded them. The element renders NO message of its own: it reports the facts (name, media type, whether the kit could have sent it) and what the user should see is the application's call. Only ever fires when `accept` is set. |
|
|
641
643
|
| `kai-message-action` | `CustomEvent<{ messageId: string; action: string; state?: undefined \| "on" \| "off" }>` | An action button on a message was clicked. `action` is the built-in name or custom id. `state` is present only for the toggleable feedback votes: `'on'` when a like/dislike is set, `'off'` when re-tapped to clear. |
|
|
642
644
|
| `kai-model-change` | `CustomEvent<{ modelId: string }>` | The header model switcher changed. |
|
|
643
645
|
| `kai-search` | `CustomEvent<Record<string, never>>` | The Search button was clicked. |
|
|
@@ -951,6 +953,13 @@ _No events._
|
|
|
951
953
|
|---|---|---|
|
|
952
954
|
| `kai-threshold-change` | `CustomEvent<{ level: "ok" \| "warn" \| "danger" }>` | Fires when the computed severity level changes (ok → warn → danger or back). `detail.level` is `'ok'`, `'warn'`, or `'danger'`. |
|
|
953
955
|
|
|
956
|
+
**Styleable parts** (restyle from outside via `kai-context::part(name)`):
|
|
957
|
+
|
|
958
|
+
| Part | Description |
|
|
959
|
+
|---|---|
|
|
960
|
+
| `::part(track)` | The usage meter track inside the hover-card breakdown. Carries `role="progressbar"` and is in the DOM only while the card is open. Restyle its height, radius, or background from outside. — `kai-context::part(track) { height: 0.5rem }` |
|
|
961
|
+
| `::part(fill)` | The used-tokens portion of that meter. Its width follows `usedTokens / maxTokens`; its default color is the severity hue picked by `warnThreshold` / `dangerThreshold`, so recoloring it from outside replaces that signal. — `kai-context::part(fill) { background: var(--color-tool-blue) }` |
|
|
962
|
+
|
|
954
963
|
---
|
|
955
964
|
|
|
956
965
|
### `kai-conversations` / `Conversations`
|
|
@@ -1450,9 +1459,9 @@ _No events._
|
|
|
1450
1459
|
| `items` | — | `undefined \| { id?: undefined \| string; label?: undefined \| string; icon?: undefined \| string; shortcut?: undefined \| string; checked?: undefined \| false \| true; radioGroup?: undefined \| string; disabled?: undefined \| false \| true; separator?: undefined \| false \| true; heading?: undefined \| false \| true; items?: undefined \| Record<string, unknown>[] }[]` | Tree of menu items. Set as a JS property, not an HTML attribute. |
|
|
1451
1460
|
| `placement` | `placement` | `undefined \| string` | Optional placement hint (unused by the underlying Dropdown which always positions bottom-start, kept for future extension). |
|
|
1452
1461
|
| `triggerIcon` | `trigger-icon` | `undefined \| string` | Built-in trigger: leading icon (a named icon like `"plus"`, an image URL/data-URI, or text). Use this instead of slotting `slot="trigger"` for the common case; a slotted trigger overrides it. |
|
|
1453
|
-
| `triggerLabel` | `trigger-label` | `undefined \| string` | Built-in trigger: a text label (e.g. `"High"`). |
|
|
1462
|
+
| `triggerLabel` | `trigger-label` | `undefined \| string` | Built-in trigger: a text label (e.g. `"High"`). This is the trigger's VISIBLE text, so it is also its accessible name, and `label` does not override it: an accessible name that does not contain the visible text is unreachable by speech input, which is what WCAG 2.5.3 (Label in Name) exists for. A slotted `slot="trigger"` replaces this built-in trigger entirely and is named differently; see `label`. |
|
|
1454
1463
|
| `triggerIconTrailing` | `trigger-icon-trailing` | `undefined \| string` | Built-in trigger: a trailing icon (e.g. `"chevron-down"` for a select look). |
|
|
1455
|
-
| `label` | `label` | `undefined \| string` | Accessible name for
|
|
1464
|
+
| `label` | `label` | `undefined \| string` | Accessible name for a trigger with no visible label. Ignored when `triggerLabel` is set, which is already the visible name. It DOES name a slotted `slot="trigger"`, and that is a difference in what the two slots MEAN, not a limitation. `<kai-button>`'s slot IS the button's label, so text slotted there is the name and `label` steps aside. This slot is VISUAL content, a `+` or an `<svg>`, with the name supplied separately: decoration beside a name, never a second name competing with one. So `label` names the trigger here by design. Slotting a real WORD rather than a glyph makes that word a visible label, and an accessible name has to contain the visible text. Then either drop `label` or make it contain the word you slotted. |
|
|
1456
1465
|
| `open` | `open` | `undefined \| false \| true` | Drive/observe open state (Shoelace-style: settable + reflected to the `open` attribute, the menu still self-manages on click/keyboard). Set `el.open = true`, or `<kai-menu open>`; listen for `kai-open-change`. |
|
|
1457
1466
|
| `defaultOpen` | `default-open` | `undefined \| false \| true` | Initial open state on mount (uncontrolled seed). |
|
|
1458
1467
|
| `disabled` | `disabled` | `undefined \| false \| true` | Disable the trigger: click/keyboard and `show()` no longer open the menu. |
|