From ea6bb6dee297de997b13b65999a23ce13dce7737 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 13 Nov 2026 12:01:48 +0000 Subject: [PATCH 1/2] chore(deps)(deps): bump zustand from 5.0.16 to 5.1.0 Bumps [zustand](https://github.com/pmndrs/zustand) from 5.0.16 to 5.1.0. - [Release notes](https://github.com/pmndrs/zustand/releases) - [Commits](https://github.com/pmndrs/zustand/compare/v5.0.16...v5.1.0) --- updated-dependencies: - dependency-name: zustand dependency-version: 5.1.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 9a157d7..12e5360 100644 --- a/package.json +++ b/package.json @@ -61,7 +61,7 @@ "tailwind-merge": "^3.7.0", "tailwindcss-react-aria-components": "^2.2.0", "tw-animate-css": "^1.4.0", - "zustand": ">=5.0.15 <5.1.0" + "zustand": ">=5.0.15 <5.2.0" }, "devDependencies": { "@axe-core/playwright": "^4.14.0", From 5bd185735192696a33467b2702e0cae19aa208bc Mon Sep 17 00:00:00 2001 From: Imani Manyara Date: Fri, 13 Nov 2026 07:23:39 -0500 Subject: [PATCH 2/2] Rebuild the bundle for zustand 5.1.0 The hold below 5.1.0 existed for check:public-api, which went with the library build in #146. Built from a fresh install, as the committed build check does. --- CHANGELOG.md | 1 + ...alog-CzqeENgh.js => inertia-app-AboutDialog-CJ767Axr.js} | 2 +- ...e-C8ILm7PF.js => inertia-app-CommandPalette-BwDUkr5s.js} | 2 +- ...el-BEVQr2SF.js => inertia-app-DevToolsPanel-DTR4iugF.js} | 2 +- ...-app-Glyph-Sqogbcp0.js => inertia-app-Glyph-BTh2WfGX.js} | 2 +- ...nAsset-BxTI0Avw.js => inertia-app-IconAsset-D5LQFvGu.js} | 2 +- ...conGrid-2j3fPN9L.js => inertia-app-IconGrid-DIF0F5og.js} | 2 +- ...ist-BQKHQU2m.js => inertia-app-IconGridList-BRf8QUxz.js} | 2 +- ...-app-Index-Di3125Ab.js => inertia-app-Index-CYLz-kHD.js} | 2 +- ...-app-Index-C6E0HER2.js => inertia-app-Index-CYNScblV.js} | 2 +- ...-app-Index-vPjXYLiI.js => inertia-app-Index-D7nWsZkH.js} | 2 +- ...odal-BfI9zYWz.js => inertia-app-InviteModal-EYnwy4h0.js} | 2 +- ...og-C_2XdV3y.js => inertia-app-LibraryDialog-pHsb2tRu.js} | 2 +- ...ZUtpt6e.js => inertia-app-ManageAccessModal-DuJYB8GN.js} | 2 +- ...dal-BSY7q1IL.js => inertia-app-ProfileModal-BxXzjpvD.js} | 2 +- ...g-tYqn9J0W.js => inertia-app-SettingsDialog-BLmc1j3H.js} | 2 +- ...aT.js => inertia-app-SharedCollectionsModal-Ck8JGjnp.js} | 2 +- ...ia-app-Show-FcYNImUG.js => inertia-app-Show-CLovBubG.js} | 2 +- ...ia-app-Show--ogMsOM7.js => inertia-app-Show-xBGkaDin.js} | 2 +- ...rModal-V2XRwjds.js => inertia-app-TourModal-CXEo7KSW.js} | 2 +- ...-DjfA1xMT.js => inertia-app-TreatmentEngine-CsS8gV3T.js} | 2 +- ...Path-3NAVLTeG.js => inertia-app-browserPath-Dw6nbcHt.js} | 2 +- public/assets/js/inertia-app-chromeIcons-B0Qjpt7t.js | 1 - public/assets/js/inertia-app-chromeIcons-CnRqTA89.js | 1 + ...-app-label-CvJL15l3.js => inertia-app-label-CsvFWRXC.js} | 2 +- ...nippets-BQgVKbqv.js => inertia-app-snippets-BfAcmzWh.js} | 2 +- ...CulqlIuG.js => inertia-app-useResolvedIcons-DgMtrRpx.js} | 2 +- public/assets/js/inertia-app.js | 6 +++--- 28 files changed, 29 insertions(+), 28 deletions(-) rename public/assets/js/{inertia-app-AboutDialog-CzqeENgh.js => inertia-app-AboutDialog-CJ767Axr.js} (98%) rename public/assets/js/{inertia-app-CommandPalette-C8ILm7PF.js => inertia-app-CommandPalette-BwDUkr5s.js} (97%) rename public/assets/js/{inertia-app-DevToolsPanel-BEVQr2SF.js => inertia-app-DevToolsPanel-DTR4iugF.js} (99%) rename public/assets/js/{inertia-app-Glyph-Sqogbcp0.js => inertia-app-Glyph-BTh2WfGX.js} (99%) rename public/assets/js/{inertia-app-IconAsset-BxTI0Avw.js => inertia-app-IconAsset-D5LQFvGu.js} (98%) rename public/assets/js/{inertia-app-IconGrid-2j3fPN9L.js => inertia-app-IconGrid-DIF0F5og.js} (91%) rename public/assets/js/{inertia-app-IconGridList-BQKHQU2m.js => inertia-app-IconGridList-BRf8QUxz.js} (98%) rename public/assets/js/{inertia-app-Index-Di3125Ab.js => inertia-app-Index-CYLz-kHD.js} (81%) rename public/assets/js/{inertia-app-Index-C6E0HER2.js => inertia-app-Index-CYNScblV.js} (92%) rename public/assets/js/{inertia-app-Index-vPjXYLiI.js => inertia-app-Index-D7nWsZkH.js} (98%) rename public/assets/js/{inertia-app-InviteModal-BfI9zYWz.js => inertia-app-InviteModal-EYnwy4h0.js} (97%) rename public/assets/js/{inertia-app-LibraryDialog-C_2XdV3y.js => inertia-app-LibraryDialog-pHsb2tRu.js} (96%) rename public/assets/js/{inertia-app-ManageAccessModal-BZUtpt6e.js => inertia-app-ManageAccessModal-DuJYB8GN.js} (97%) rename public/assets/js/{inertia-app-ProfileModal-BSY7q1IL.js => inertia-app-ProfileModal-BxXzjpvD.js} (94%) rename public/assets/js/{inertia-app-SettingsDialog-tYqn9J0W.js => inertia-app-SettingsDialog-BLmc1j3H.js} (98%) rename public/assets/js/{inertia-app-SharedCollectionsModal-D6mGVpaT.js => inertia-app-SharedCollectionsModal-Ck8JGjnp.js} (89%) rename public/assets/js/{inertia-app-Show-FcYNImUG.js => inertia-app-Show-CLovBubG.js} (85%) rename public/assets/js/{inertia-app-Show--ogMsOM7.js => inertia-app-Show-xBGkaDin.js} (95%) rename public/assets/js/{inertia-app-TourModal-V2XRwjds.js => inertia-app-TourModal-CXEo7KSW.js} (96%) rename public/assets/js/{inertia-app-TreatmentEngine-DjfA1xMT.js => inertia-app-TreatmentEngine-CsS8gV3T.js} (99%) rename public/assets/js/{inertia-app-browserPath-3NAVLTeG.js => inertia-app-browserPath-Dw6nbcHt.js} (85%) delete mode 100644 public/assets/js/inertia-app-chromeIcons-B0Qjpt7t.js create mode 100644 public/assets/js/inertia-app-chromeIcons-CnRqTA89.js rename public/assets/js/{inertia-app-label-CvJL15l3.js => inertia-app-label-CsvFWRXC.js} (95%) rename public/assets/js/{inertia-app-snippets-BQgVKbqv.js => inertia-app-snippets-BfAcmzWh.js} (98%) rename public/assets/js/{inertia-app-useResolvedIcons-CulqlIuG.js => inertia-app-useResolvedIcons-DgMtrRpx.js} (99%) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5f95fe1..9f3ad97 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ All notable changes to `ichava/icon-browser` follow [Keep a Changelog](https://k ### Changed +- **`zustand` may resolve to 5.1.x (`>=5.0.15 <5.2.0`, icon-browser#147).** It was held below 5.1.0 because 5.1.0 narrows `persist.rehydrate()`'s type, which changed the published type of the old library's `useStore` and failed `check:public-api`. That check went with the library build in icon-browser#146, so the hold had no reason left. Typecheck and the 993 Vitest tests pass on 5.1.0, and `inertia-app.*` is rebuilt from a fresh `npm install --no-package-lock`, as `committed-build.yml` does. - **The browser UI's source lives in this repository** (react consolidation 3d). `ichava/react-icon-browser`'s `main` at `3cdbd1b` is imported as a snapshot with no history: its `src/` into `resources/js/`, its tooling and fixture catalogue into `.dev/browser/`, its fonts into `resources/assets/fonts/`, and its other root files into `.dev/imported/react-icon-browser/`; the 20 Metronic baseline paths are not imported. `npm run build:prod` builds the committed bundle from that source: `theme.css` is compiled with Tailwind and scoped to `[data-ichava-theme]` as the library build did, and `ichava.scss` no longer scans the browser's files. The browser's 875 Vitest tests (and 3 skipped) run here, 994 passing in all. TypeScript 6 and Tailwind ^4.3 match the source, and `typecheck:inertia` uses its stricter `tsconfig.base.json`. - **The shared Untitled UI pieces come from `@ichava/js-ui-kernel/react`**, pinned to `bc5120c` as in ichava.com: `cx`, `is-react-component`, the avatar base components, radio buttons, toggle, featured icon and `uui-theme.css`. Tabs and dropdown stay local. - **The Untitled UI PRO components are included as part of the product** (owner, 2026-11-12): the 12 the browser uses, in five folders [LICENSE](LICENSE) lists, each keeping its PRO header. See [Architecture](docs/architecture.md#untitled-ui-pro-components). diff --git a/public/assets/js/inertia-app-AboutDialog-CzqeENgh.js b/public/assets/js/inertia-app-AboutDialog-CJ767Axr.js similarity index 98% rename from public/assets/js/inertia-app-AboutDialog-CzqeENgh.js rename to public/assets/js/inertia-app-AboutDialog-CJ767Axr.js index fa28fe5..72bdf46 100644 --- a/public/assets/js/inertia-app-AboutDialog-CzqeENgh.js +++ b/public/assets/js/inertia-app-AboutDialog-CJ767Axr.js @@ -1 +1 @@ -import{f as e,g as t}from"./inertia-app.js";import{i as n,n as r,t as i}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{t as a}from"./inertia-app-Glyph-Sqogbcp0.js";import{A as o,K as s,dt as c}from"./inertia-app-chromeIcons-B0Qjpt7t.js";var l=n(r(),1),u=i();function d({children:e,direction:t=`vertical`,durationSec:n=16,gap:r=0,style:i,fade:a=!0,fadeColor:o=`var(--muted2)`}){return t===`horizontal`?(0,u.jsx)(m,{durationSec:n,gap:r,style:i,fade:a,fadeColor:o,children:e}):(0,u.jsx)(p,{durationSec:n,gap:r,style:i,fade:a,fadeColor:o,children:e})}function f(e,t){return{position:`absolute`,inset:0,pointerEvents:`none`,background:e?`linear-gradient(${t}, transparent 16px, transparent calc(100% - 16px), ${t})`:`linear-gradient(90deg, ${t}, transparent 24px, transparent calc(100% - 24px), ${t})`}}function p({children:e,durationSec:t,gap:n,style:r,fade:i,fadeColor:a}){let o=(0,l.useRef)(null),s=(0,l.useRef)(!1);return(0,l.useEffect)(()=>{let e=o.current;if(!e)return;let n=0,r=performance.now(),i=e.scrollTop,a=o=>{let c=o-r;r=o;let l=document.documentElement.hasAttribute(`data-reduce-motion`),u=e.scrollHeight/2;s.current||l?(i=e.scrollTop,u>0&&i>=u&&(i-=u,e.scrollTop=i)):u>0&&(i+=u/(t*1e3)*c,i>=u&&(i-=u),e.scrollTop=i),n=requestAnimationFrame(a)};return n=requestAnimationFrame(a),()=>cancelAnimationFrame(n)},[t]),(0,u.jsxs)(`div`,{onMouseEnter:()=>s.current=!0,onMouseLeave:()=>s.current=!1,style:{position:`relative`,overflow:`hidden`,...r},children:[(0,u.jsxs)(`div`,{ref:o,className:`ich-marquee-scroll`,style:{height:`100%`,overflowY:`auto`,overscrollBehavior:`contain`},children:[(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:n},children:e}),(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:n},"aria-hidden":!0,children:e})]}),i&&(0,u.jsx)(`div`,{style:f(!0,a)})]})}function m({children:e,durationSec:t,gap:n,style:r,fade:i,fadeColor:a}){let[o,s]=(0,l.useState)(!1);return(0,u.jsxs)(`div`,{onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1),style:{position:`relative`,overflow:`hidden`,...r},children:[(0,u.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`,gap:n,animation:`ichMarqueeX ${t}s linear infinite`,animationPlayState:o?`paused`:`running`,willChange:`transform`},children:[(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`row`,gap:n},children:e}),(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`row`,gap:n},"aria-hidden":!0,children:e})]}),i&&(0,u.jsx)(`div`,{style:f(!1,a)})]})}function h(){let n=o(),r=s(e=>e.closeLayer),i=s(e=>e.config),l=s(e=>e.catalog),f=i?.about??c.about,p=f.credits,m=f.links,h=i?.crossLinks?.landing,_=typeof h==`string`&&/^https?:\/\//i.test(h)?h:null;return(0,u.jsxs)(e,{showClose:!1,onClose:r,width:400,panelStyle:{overflow:`hidden`},children:[(0,u.jsxs)(`div`,{className:`relative`,children:[(0,u.jsx)(`button`,{onClick:r,title:`${n(`common.close`)} — Esc`,className:`absolute top-2.5 end-2.5 z-2 w-[26px] h-[26px] border border-[var(--border)] bg-[var(--pop)] shadow-[var(--shadow)] rounded-[6px] cursor-pointer flex items-center justify-center text-[var(--muted-fg)]`,children:(0,u.jsx)(a,{name:`close`,size:12,color:`currentColor`})}),(0,u.jsxs)(`div`,{className:`flex flex-col items-center gap-2.5 pt-[26px] px-5 pb-[18px] bg-[var(--accent-soft)]`,children:[(0,u.jsx)(`div`,{className:`w-[46px] h-[46px] rounded-[12px] bg-[var(--accent)] flex items-center justify-center shadow-[var(--shadow-elevated)]`,children:(0,u.jsx)(a,{name:`layers`,size:25,color:`var(--accent-fg)`})}),(0,u.jsxs)(`div`,{className:`flex items-baseline gap-1.5`,children:[(0,u.jsx)(`span`,{className:`font-bold text-[16px] tracking-[-.02em]`,children:i?.brand.name??`Ichava`}),(0,u.jsx)(`span`,{className:`text-[var(--muted-fg)] text-[14px]`,children:i?.brand.suffix??n(`about.browser`)}),(0,u.jsxs)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[11px] text-[var(--accent-text)]`,children:[`v`,i?.meta.version??`0.1.0`]})]}),(0,u.jsx)(`div`,{className:`text-[12px] text-[var(--muted-fg)] text-center leading-[1.55] max-w-[40ch]`,children:f.description}),(0,u.jsxs)(`div`,{className:`text-[11px] text-[var(--faint-fg)]`,children:[n(`about.craftedBy`),` `,(0,u.jsx)(`b`,{className:`text-[var(--fg)] font-semibold`,children:i?.meta.author??`Simtabi LLC`})]})]})]}),(0,u.jsxs)(`div`,{className:`flex border-t border-t-[var(--border)] border-b border-b-[var(--border)]`,children:[(0,u.jsx)(g,{value:t(l?.meta.total_ecosystem??0),label:f.stats[0]?.label??n(`about.statIcons`),border:!0}),(0,u.jsx)(g,{value:String(i?.meta.sets??70),label:f.stats[1]?.label??n(`about.statSets`),border:!0}),(0,u.jsx)(g,{value:i?.meta.license??c.meta.license,label:f.stats[2]?.label??n(`about.statLicense`)})]}),(0,u.jsx)(`div`,{className:`text-[9.5px] font-bold tracking-[.08em] text-[var(--faint-fg)] text-center pt-2 px-0 pb-1.5 bg-[var(--muted2)] border-b border-b-[var(--border)]`,children:f.creditsTitle}),(0,u.jsx)(d,{durationSec:f.creditsMarqueeSec,style:{height:126,background:`var(--muted2)`},fadeColor:`var(--muted2)`,children:p.map(e=>(0,u.jsxs)(`div`,{className:`flex items-baseline justify-center gap-2 py-[5px] px-4`,children:[(0,u.jsx)(`span`,{className:`text-[11.5px] font-[600]`,children:e.name}),(0,u.jsx)(`span`,{className:`text-[10px] text-[var(--muted-fg)]`,children:e.author}),(0,u.jsx)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[9.5px] text-[var(--accent-text)] bg-[var(--accent-soft)] rounded-[3px] py-0 px-[5px]`,children:e.license})]},e.name))}),(0,u.jsxs)(`div`,{className:`flex items-center gap-3 py-3 px-4 flex-wrap`,children:[(0,u.jsx)(`span`,{className:`text-[11px] text-[var(--muted-fg)]`,children:f.copyright}),(0,u.jsx)(`span`,{className:`flex-1`}),(0,u.jsxs)(`div`,{className:`flex items-center gap-3`,children:[_&&(0,u.jsx)(`a`,{href:_,target:`_blank`,rel:`noopener noreferrer`,className:`text-[12px]`,"data-ichava-landing":``,children:n(`about.landing`)}),m.map(e=>(0,u.jsx)(`a`,{href:e.href,target:`_blank`,rel:`noreferrer`,className:`text-[12px]`,children:e.label},e.label))]})]})]})}function g({value:e,label:t,border:n}){return(0,u.jsxs)(`div`,{style:{flex:1,display:`flex`,flexDirection:`column`,alignItems:`center`,gap:2,padding:10,borderRight:n?`1px solid var(--border)`:void 0},children:[(0,u.jsx)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[14px] font-semibold`,children:e}),(0,u.jsx)(`span`,{className:`text-[10px] text-[var(--muted-fg)]`,children:t})]})}export{h as AboutDialog}; \ No newline at end of file +import{f as e,g as t}from"./inertia-app.js";import{i as n,n as r,t as i}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{t as a}from"./inertia-app-Glyph-BTh2WfGX.js";import{A as o,K as s,dt as c}from"./inertia-app-chromeIcons-CnRqTA89.js";var l=n(r(),1),u=i();function d({children:e,direction:t=`vertical`,durationSec:n=16,gap:r=0,style:i,fade:a=!0,fadeColor:o=`var(--muted2)`}){return t===`horizontal`?(0,u.jsx)(m,{durationSec:n,gap:r,style:i,fade:a,fadeColor:o,children:e}):(0,u.jsx)(p,{durationSec:n,gap:r,style:i,fade:a,fadeColor:o,children:e})}function f(e,t){return{position:`absolute`,inset:0,pointerEvents:`none`,background:e?`linear-gradient(${t}, transparent 16px, transparent calc(100% - 16px), ${t})`:`linear-gradient(90deg, ${t}, transparent 24px, transparent calc(100% - 24px), ${t})`}}function p({children:e,durationSec:t,gap:n,style:r,fade:i,fadeColor:a}){let o=(0,l.useRef)(null),s=(0,l.useRef)(!1);return(0,l.useEffect)(()=>{let e=o.current;if(!e)return;let n=0,r=performance.now(),i=e.scrollTop,a=o=>{let c=o-r;r=o;let l=document.documentElement.hasAttribute(`data-reduce-motion`),u=e.scrollHeight/2;s.current||l?(i=e.scrollTop,u>0&&i>=u&&(i-=u,e.scrollTop=i)):u>0&&(i+=u/(t*1e3)*c,i>=u&&(i-=u),e.scrollTop=i),n=requestAnimationFrame(a)};return n=requestAnimationFrame(a),()=>cancelAnimationFrame(n)},[t]),(0,u.jsxs)(`div`,{onMouseEnter:()=>s.current=!0,onMouseLeave:()=>s.current=!1,style:{position:`relative`,overflow:`hidden`,...r},children:[(0,u.jsxs)(`div`,{ref:o,className:`ich-marquee-scroll`,style:{height:`100%`,overflowY:`auto`,overscrollBehavior:`contain`},children:[(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:n},children:e}),(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:n},"aria-hidden":!0,children:e})]}),i&&(0,u.jsx)(`div`,{style:f(!0,a)})]})}function m({children:e,durationSec:t,gap:n,style:r,fade:i,fadeColor:a}){let[o,s]=(0,l.useState)(!1);return(0,u.jsxs)(`div`,{onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1),style:{position:`relative`,overflow:`hidden`,...r},children:[(0,u.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`,gap:n,animation:`ichMarqueeX ${t}s linear infinite`,animationPlayState:o?`paused`:`running`,willChange:`transform`},children:[(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`row`,gap:n},children:e}),(0,u.jsx)(`div`,{style:{display:`flex`,flexDirection:`row`,gap:n},"aria-hidden":!0,children:e})]}),i&&(0,u.jsx)(`div`,{style:f(!1,a)})]})}function h(){let n=o(),r=s(e=>e.closeLayer),i=s(e=>e.config),l=s(e=>e.catalog),f=i?.about??c.about,p=f.credits,m=f.links,h=i?.crossLinks?.landing,_=typeof h==`string`&&/^https?:\/\//i.test(h)?h:null;return(0,u.jsxs)(e,{showClose:!1,onClose:r,width:400,panelStyle:{overflow:`hidden`},children:[(0,u.jsxs)(`div`,{className:`relative`,children:[(0,u.jsx)(`button`,{onClick:r,title:`${n(`common.close`)} — Esc`,className:`absolute top-2.5 end-2.5 z-2 w-[26px] h-[26px] border border-[var(--border)] bg-[var(--pop)] shadow-[var(--shadow)] rounded-[6px] cursor-pointer flex items-center justify-center text-[var(--muted-fg)]`,children:(0,u.jsx)(a,{name:`close`,size:12,color:`currentColor`})}),(0,u.jsxs)(`div`,{className:`flex flex-col items-center gap-2.5 pt-[26px] px-5 pb-[18px] bg-[var(--accent-soft)]`,children:[(0,u.jsx)(`div`,{className:`w-[46px] h-[46px] rounded-[12px] bg-[var(--accent)] flex items-center justify-center shadow-[var(--shadow-elevated)]`,children:(0,u.jsx)(a,{name:`layers`,size:25,color:`var(--accent-fg)`})}),(0,u.jsxs)(`div`,{className:`flex items-baseline gap-1.5`,children:[(0,u.jsx)(`span`,{className:`font-bold text-[16px] tracking-[-.02em]`,children:i?.brand.name??`Ichava`}),(0,u.jsx)(`span`,{className:`text-[var(--muted-fg)] text-[14px]`,children:i?.brand.suffix??n(`about.browser`)}),(0,u.jsxs)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[11px] text-[var(--accent-text)]`,children:[`v`,i?.meta.version??`0.1.0`]})]}),(0,u.jsx)(`div`,{className:`text-[12px] text-[var(--muted-fg)] text-center leading-[1.55] max-w-[40ch]`,children:f.description}),(0,u.jsxs)(`div`,{className:`text-[11px] text-[var(--faint-fg)]`,children:[n(`about.craftedBy`),` `,(0,u.jsx)(`b`,{className:`text-[var(--fg)] font-semibold`,children:i?.meta.author??`Simtabi LLC`})]})]})]}),(0,u.jsxs)(`div`,{className:`flex border-t border-t-[var(--border)] border-b border-b-[var(--border)]`,children:[(0,u.jsx)(g,{value:t(l?.meta.total_ecosystem??0),label:f.stats[0]?.label??n(`about.statIcons`),border:!0}),(0,u.jsx)(g,{value:String(i?.meta.sets??70),label:f.stats[1]?.label??n(`about.statSets`),border:!0}),(0,u.jsx)(g,{value:i?.meta.license??c.meta.license,label:f.stats[2]?.label??n(`about.statLicense`)})]}),(0,u.jsx)(`div`,{className:`text-[9.5px] font-bold tracking-[.08em] text-[var(--faint-fg)] text-center pt-2 px-0 pb-1.5 bg-[var(--muted2)] border-b border-b-[var(--border)]`,children:f.creditsTitle}),(0,u.jsx)(d,{durationSec:f.creditsMarqueeSec,style:{height:126,background:`var(--muted2)`},fadeColor:`var(--muted2)`,children:p.map(e=>(0,u.jsxs)(`div`,{className:`flex items-baseline justify-center gap-2 py-[5px] px-4`,children:[(0,u.jsx)(`span`,{className:`text-[11.5px] font-[600]`,children:e.name}),(0,u.jsx)(`span`,{className:`text-[10px] text-[var(--muted-fg)]`,children:e.author}),(0,u.jsx)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[9.5px] text-[var(--accent-text)] bg-[var(--accent-soft)] rounded-[3px] py-0 px-[5px]`,children:e.license})]},e.name))}),(0,u.jsxs)(`div`,{className:`flex items-center gap-3 py-3 px-4 flex-wrap`,children:[(0,u.jsx)(`span`,{className:`text-[11px] text-[var(--muted-fg)]`,children:f.copyright}),(0,u.jsx)(`span`,{className:`flex-1`}),(0,u.jsxs)(`div`,{className:`flex items-center gap-3`,children:[_&&(0,u.jsx)(`a`,{href:_,target:`_blank`,rel:`noopener noreferrer`,className:`text-[12px]`,"data-ichava-landing":``,children:n(`about.landing`)}),m.map(e=>(0,u.jsx)(`a`,{href:e.href,target:`_blank`,rel:`noreferrer`,className:`text-[12px]`,children:e.label},e.label))]})]})]})}function g({value:e,label:t,border:n}){return(0,u.jsxs)(`div`,{style:{flex:1,display:`flex`,flexDirection:`column`,alignItems:`center`,gap:2,padding:10,borderRight:n?`1px solid var(--border)`:void 0},children:[(0,u.jsx)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[14px] font-semibold`,children:e}),(0,u.jsx)(`span`,{className:`text-[10px] text-[var(--muted-fg)]`,children:t})]})}export{h as AboutDialog}; \ No newline at end of file diff --git a/public/assets/js/inertia-app-CommandPalette-C8ILm7PF.js b/public/assets/js/inertia-app-CommandPalette-BwDUkr5s.js similarity index 97% rename from public/assets/js/inertia-app-CommandPalette-C8ILm7PF.js rename to public/assets/js/inertia-app-CommandPalette-BwDUkr5s.js index fe9b20f..0f87a24 100644 --- a/public/assets/js/inertia-app-CommandPalette-C8ILm7PF.js +++ b/public/assets/js/inertia-app-CommandPalette-BwDUkr5s.js @@ -1 +1 @@ -import{i as e,n as t,t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{a as r,n as i,r as a,t as o}from"./inertia-app-IconAsset-BxTI0Avw.js";import{t as s}from"./inertia-app-Glyph-Sqogbcp0.js";import{A as c,O as l,S as u,h as d,k as f,m as p,v as m,w as h}from"./inertia-app.js";import{B as g,Ut as _,a as v,i as y,j as b,k as x,o as S,r as C,t as w}from"./inertia-app-cx-DVGP9Hhm.js";import{a as T,i as E,t as D}from"./inertia-app-ListBox-_e7t_Gp2.js";import{t as O}from"./inertia-app-TextField-DOf2KRkE.js";import{A as k,C as A,K as j,T as M,dt as N,g as ee,i as te,l as ne,n as re,q as P,r as F,t as I}from"./inertia-app-chromeIcons-B0Qjpt7t.js";import{a as L,i as R,n as z,t as B}from"./inertia-app-tooltip-D9d_CMoW.js";import{t as V}from"./inertia-app-button-B_oNuxaV.js";import{i as H}from"./inertia-app-snippets-BQgVKbqv.js";var U=e(t(),1),W=n(),G=({keys:e,withThen:t,className:n,size:r=`md`})=>(0,W.jsx)(`div`,{className:w(`flex items-center gap-x-1`,n),children:e.map((e,n)=>(0,W.jsxs)(U.Fragment,{children:[n!==0&&(0,W.jsxs)(`div`,{className:`flex items-center gap-x-1 text-quaternary`,children:[t&&(0,W.jsx)(`span`,{className:`text-sm font-medium`,children:`then`}),(0,W.jsx)(F,{size:16,strokeWidth:2.2})]}),(0,W.jsx)(`kbd`,{className:w(`min-w-6 rounded-[4px] bg-secondary_alt px-1 py-0.5 text-center font-medium text-tertiary ring-1 ring-secondary ring-inset`,r===`sm`?`font-mono text-[10.5px]`:`text-sm`),children:e.toUpperCase()})]},n))}),K=({placeholder:e,shortcutKeys:t,tooltip:n,className:r,...i})=>(0,W.jsxs)(L,{className:({isFocusWithin:e})=>w(`flex items-center gap-x-2 rounded-xl bg-primary p-4`,e&&`outline-2 outline-focus-ring`,r),children:[(0,W.jsx)(`div`,{className:`pointer-events-none absolute`,children:(0,W.jsx)(A,{className:`size-5 text-fg-quaternary`})}),(0,W.jsx)(R,{placeholder:e,className:`m-0 w-full bg-transparent pl-7 text-md text-primary ring-0 outline-hidden placeholder:text-placeholder autofill:rounded-lg autofill:text-primary`,...i}),n&&(0,W.jsx)(B,{title:n,placement:`top`,children:(0,W.jsx)(z,{className:`cursor-pointer text-fg-quaternary transition duration-200 hover:text-fg-quaternary_hover focus:text-fg-quaternary_hover`,children:(0,W.jsx)(ee,{className:`size-4 stroke-[2.25px]`})})}),t&&(0,W.jsx)(G,{keys:t})]}),q=e=>(0,W.jsxs)(`div`,{className:`flex h-7 min-w-7 items-center justify-between rounded-lg bg-primary p-1.5 ring-1 ring-secondary ring-inset`,children:[e.type===`icon`&&(0,W.jsx)(e.icon,{strokeWidth:2.4,className:`size-4 text-fg-quaternary`}),e.type===`text`&&(0,W.jsx)(`span`,{className:`text-sm font-semibold text-fg-quaternary`,children:e.label})]}),J=({className:e})=>(0,W.jsxs)(`footer`,{className:w(`absolute inset-x-0 bottom-0 flex items-center justify-between gap-x-3 bg-alpha-white/80 p-2 pl-4.5 ring-1 ring-secondary_alt backdrop-blur-lg max-md:hidden`,e),children:[(0,W.jsxs)(`div`,{className:`flex gap-4`,children:[(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsxs)(`div`,{className:`flex gap-1.5`,children:[(0,W.jsx)(q,{type:`icon`,icon:te}),(0,W.jsx)(q,{type:`icon`,icon:I})]}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`to navigate`})]}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsx)(q,{type:`icon`,icon:ne}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`to select`})]}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsx)(q,{type:`text`,label:`esc`}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`to close`})]}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsx)(q,{type:`icon`,icon:re}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`return to parent`})]})]}),(0,W.jsx)(V,{size:`sm`,color:`tertiary`,iconLeading:M})]}),Y=({children:e,className:t})=>(0,W.jsx)(x,{className:w(`flex px-4.5 pt-2 text-xs font-semibold text-tertiary`,t),children:e});function ie(e,t){let n=new Set(t);return Object.fromEntries(Object.entries(e).filter(([e])=>!n.has(e)))}var ae=({label:e,children:t,description:n,stacked:r,shortcutKeys:i,className:a,size:o=`md`,...s})=>{let c=o===`sm`;return(0,W.jsx)(E,{...ie(s,[`type`,`icon`,`alt`,`src`]),textValue:e,className:e=>w(`group block cursor-pointer px-2 py-0.5 outline-hidden`,typeof a==`function`?a(e):a),children:a=>(0,W.jsxs)(`div`,{className:w(`relative flex min-h-10 items-center justify-between rounded-lg px-2.5 py-2 pl-2.5 outline-focus-ring transition duration-100 ease-linear hover:bg-primary_hover`,c&&`min-h-8 rounded-md px-2 py-1 pl-2`,a.isSelected&&`bg-primary_hover`,a.isFocusVisible&&`outline-2 outline-offset-2`,r&&`items-start p-2.5 pl-3.5`),children:[s.type===`icon`&&!r&&(0,W.jsx)(s.icon,{className:w(`mr-2 text-fg-quaternary`,c?`size-4`:`size-5`)}),s.type===`icon`&&r&&(0,W.jsx)(l,{color:`gray`,size:`md`,theme:`modern`,icon:s.icon,className:`mr-2`}),s.type===`avatar`&&(0,W.jsx)(h,{alt:s.alt,src:s.src,size:r?`md`:`xs`,className:`mr-2`}),s.type===`dot`&&(0,W.jsx)(`svg`,{width:`10`,height:`10`,viewBox:`0 0 10 10`,fill:`none`,className:w(`mr-2 shrink-0 text-fg-success-secondary`,r&&`mt-2 self-start`),children:(0,W.jsx)(`circle`,{cx:`5`,cy:`5`,r:`4`,fill:`currentColor`})}),(0,W.jsxs)(`div`,{className:w(`flex flex-1 gap-x-1.5`,r&&`flex-col`),children:[(0,W.jsxs)(b,{slot:`label`,className:w(`font-medium text-primary`,c?`text-[12.5px]`:`text-sm`,i&&`flex flex-1 items-center justify-between gap-2`),children:[(0,W.jsx)(`span`,{children:typeof t==`function`?t(a):t||e}),i&&` `,i&&(0,W.jsx)(G,{keys:i,size:o})]}),n&&(0,W.jsx)(b,{slot:`description`,className:w(`text-tertiary`,c?`font-mono text-[10.5px]`:`text-sm`),children:n})]})]})})},X=(0,U.createContext)({hasFooter:!1,flatItems:[],selectedKeys:new Set,setSelectedKeys:()=>{}}),oe=({items:e,children:t,dialogClassName:n,overlayClassName:r,filter:i,inputValue:a,defaultItems:o,onInputChange:s,onSelectionChange:l,sensitivity:u=`base`,placeholder:d=`Search`,defaultSelectedKeys:f,shortcut:p=`⌘/`,dialogLabel:m=`Command menu`,inputLabel:h=`Search`,listLabel:_=`Command menu results`,...v})=>{let y=(0,U.useRef)(null),{contains:b}=c({sensitivity:u}),[x,S]=(0,U.useState)(f??new Set),C=e??o,w=(C??[]).reduce((e,t)=>[...e,...t.items],[]),T=(0,U.useMemo)(()=>{let e=!1;return U.Children.forEach(t,t=>{t&&typeof t==`object`&&`type`in t&&t.type===J&&(e=!0)}),e},[t]);return(0,W.jsx)(X.Provider,{value:{hasFooter:T,flatItems:w,selectedKeys:x,setSelectedKeys:S,onSelectionChange:l,items:C,listLabel:_,...v},children:(0,W.jsx)(se,{"aria-label":m,isOpen:v.isOpen,onOpenChange:v.onOpenChange,className:r,dialogClassName:n,children:(0,W.jsxs)(g,{inputValue:a,onInputChange:s,filter:i===!1?void 0:i||b,children:[(0,W.jsx)(O,{"aria-label":h,children:(0,W.jsx)(K,{autoFocus:!0,role:`combobox`,"aria-expanded":!0,shortcutKeys:p?[p]:void 0,placeholder:d,ref:y,className:`relative outline-hidden! after:absolute after:bottom-0 after:left-0 after:h-px after:w-full after:bg-border-secondary`})}),t]})})})},se=({className:e,dialogClassName:t,children:n,"aria-label":r=`Command menu`,...i})=>(0,W.jsx)(y,{...i,isDismissable:!0,className:t=>w(`fixed inset-0 z-50 flex min-h-full items-start justify-center overflow-y-auto bg-overlay/70 p-4 text-center md:pt-16 xl:pt-[clamp(64px,10vh,243px)]`,t.isEntering&&`duration-300 ease-out animate-in fade-in`,t.isExiting&&`duration-200 ease-in animate-out fade-out`,typeof e==`function`?e(t):e),children:e=>(0,W.jsx)(C,{className:e=>w(`flex max-h-full w-160 flex-col overflow-hidden rounded-xl bg-primary text-left align-middle shadow-xl`,e.isEntering&&`duration-300 ease-out animate-in zoom-in-95`,e.isExiting&&`duration-200 ease-in animate-out zoom-out-95`,typeof t==`function`?t(e):t),children:(0,W.jsx)(S,{"aria-label":r,className:`relative flex min-h-0 flex-1 flex-col outline-hidden`,children:typeof n==`function`?n(e):n})})}),ce=({className:e,selectionMode:t=`single`,...n})=>{let{hasFooter:r,emptyState:i,listLabel:a,...o}=(0,U.useContext)(X);return(0,W.jsx)(D,{"aria-label":a,...n,...o,renderEmptyState:()=>i,selectionMode:t,onSelectionChange:e=>{o.onSelectionChange?.(e),o.setSelectedKeys(e)},className:t=>w(`flex max-h-106 flex-1 scroll-py-10 flex-col gap-2 overflow-auto focus:outline-hidden`,r&&`scroll-pb-22 pb-13`,!t.isEmpty&&`pt-2`,typeof e==`function`?e(t):e)})},le=({title:e,children:t,items:n,...r})=>(0,W.jsxs)(T,{...r,className:w(`border-b border-secondary pb-2 last:border-transparent`,r.className),children:[e&&(0,W.jsx)(Y,{className:`pb-1`,children:e},e),(0,W.jsx)(_,{items:n,children:t})]}),Z=({children:e,asChild:t,...n})=>{let{selectedKeys:r}=(0,U.useContext)(X),i=Array.from(r);if(!i.length)return null;let a=i.at(0);return t?(0,W.jsx)(U.Fragment,{children:typeof e==`function`?e({selectedId:a}):e}):(0,W.jsx)(`div`,{...n,children:typeof e==`function`?e({selectedId:a}):e})},ue=({className:e,...t})=>(0,W.jsx)(`div`,{...t,className:w(`min-h-0 flex-1`,e)}),Q=oe;Q.Item=ae,Q.List=ce,Q.Group=ue,Q.Footer=J,Q.Preview=Z,Q.Section=le,Q.Trigger=v,Q.Collection=_;function de(){let e=P(),t=r(),{catalog:n,page:i}=a(),o=j(e=>e.closeLayer),[s,c]=(0,U.useState)(``),l=j(e=>e.config?.features.commands===!1?fe:e.recentCommands),h=d(),g=k(),_=j(e=>e.config?.limits)??N.limits,v=e.getState(),y=(0,U.useMemo)(()=>[{id:`theme`,label:g(`palette.toggleTheme`),icon:`moon`,kbd:`${h}T`,run:()=>v.toggleTheme()},{id:`settings`,label:g(`palette.openSettings`),icon:`settings`,kbd:`${h},`,run:()=>v.openLayer(`settings`)},{id:`favorites`,label:g(`palette.openFavorites`),icon:`heart`,kbd:`${h}1`,run:()=>v.openLibrary(`favorites`)},{id:`history`,label:g(`palette.openHistory`),icon:`clock`,kbd:`${h}2`,run:()=>v.openLibrary(`history`)},{id:`collections`,label:g(`palette.openCollections`),icon:`folder`,kbd:`${h}3`,run:()=>v.openLibrary(`collections`)},{id:`view`,label:v.view===`grid`?g(`palette.switchListView`):g(`palette.switchGridView`),icon:v.view===`grid`?`list`:`grid`,kbd:``,run:()=>v.setView(v.view===`grid`?`list`:`grid`)},{id:`reset`,label:g(`palette.resetFilters`),icon:`refresh`,kbd:m(h),run:()=>v.openConfirm({title:g(`toolbar.resetTitle`),body:g(`toolbar.resetBody`),confirmLabel:g(`toolbar.resetConfirm`),danger:!0,onConfirm:()=>{v.resetFilters(),v.showToast(g(`toolbar.resetToast`),`refresh`)}})},{id:`selectAll`,label:g(`palette.selectAll`),icon:`check`,kbd:`${h}A`,run:()=>f(e,t)},...v.config?.features.devtools===!1?[]:[{id:`devtools`,label:g(`palette.openDevtools`),icon:`zap`,kbd:p(h),run:()=>v.toggleDevtools()}]].filter(e=>{let t=v.config?.features;return e.id===`theme`?t?.themeToggle!==!1:e.id===`favorites`||e.id===`history`||e.id===`collections`?t?.[e.id]!==!1:!0}),[h,v,g,e,t]),b=s.trim().toLowerCase(),x=b?y.filter(e=>e.label.toLowerCase().includes(b)):[...y].sort((e,t)=>$(l,e.id)-$(l,t.id)),S=(0,U.useMemo)(()=>b?(n?n.icons:i.items).filter(e=>`${e.name} ${e.id} ${(e.tags??[]).join(` `)}`.toLowerCase().includes(b)).slice(0,_.paletteIconResults):[],[b,n,i,_.paletteIconResults]),C=new Map(x.map(e=>[`a:${e.id}`,e])),T=new Map(S.map(e=>[`i:${e.id}`,e])),E=(0,U.useMemo)(()=>S.map(e=>{let t=({className:t})=>(0,W.jsx)(`span`,{className:w(`inline-flex items-center justify-center`,t),children:(0,W.jsx)(pe,{icon:e})}),n=(0,W.jsxs)(W.Fragment,{children:[e.name,` `,(0,W.jsx)(`span`,{className:`ms-1 font-mono text-[10.5px] font-normal text-tertiary`,children:H(e)})]});return{id:`i:${e.id}`,type:`icon`,icon:t,label:e.name,children:n,size:`sm`}}),[S]),D=[];return x.length&&D.push({id:`actions`,title:!b&&l.length?g(`palette.recent`):g(`palette.actions`),items:x.map(e=>({id:`a:${e.id}`,type:`icon`,icon:u(e.icon),label:e.label,shortcutKeys:e.kbd?[e.kbd]:void 0,size:`sm`}))}),E.length&&D.push({id:`icons`,title:g(`palette.icons`),items:E}),(0,W.jsxs)(Q,{isOpen:!0,onOpenChange:e=>!e&&o(),items:D,filter:!1,inputValue:s,onInputChange:c,onAction:t=>{let n=T.get(String(t));if(n){v.openDetail(n.id);return}let r=C.get(String(t));r&&(e.getState().config?.features.commands!==!1&&v.logCommand(r.id,`action`),r.run(),e.getState().layer===`palette`&&o())},shortcut:null,placeholder:g(`palette.placeholder`),inputLabel:g(`palette.placeholder`),dialogLabel:g(`header.commandPalette`),listLabel:g(`palette.results`),overlayClassName:`z-(--z-overlay)`,dialogClassName:`w-[560px] max-w-[94vw] bg-[var(--surface)] text-[length:var(--app-font,13.5px)]`,emptyState:(0,W.jsx)(`div`,{className:`p-6 text-center text-[12px] text-[var(--muted-fg)]`,children:g(`palette.noMatches`,{q:s})}),children:[(0,W.jsx)(Q.Group,{children:(0,W.jsx)(Q.List,{selectionMode:`none`,children:e=>(0,W.jsx)(Q.Section,{...e,children:e=>(0,W.jsx)(Q.Item,{...e},e.id)})})}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2.5 border-t border-secondary px-3.5 py-2 text-[10.5px] text-[var(--muted-fg)]`,children:[(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`b`,{children:`↑↓`}),` `,g(`palette.navigate`)]}),(0,W.jsx)(`span`,{"aria-hidden":!0,children:`·`}),(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`b`,{children:`↵`}),` `,g(`palette.select`)]}),(0,W.jsx)(`span`,{"aria-hidden":!0,children:`·`}),(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`b`,{children:`esc`}),` `,g(`palette.close`)]})]})]})}var fe=[];function $(e,t){let n=e.indexOf(t);return n<0?99:n}function pe({icon:e}){let t=!!(e.svgUrl||e.svgContent),n=i(e);return!t||n?.body===``?(0,W.jsx)(`span`,{"data-role":`preview-fallback`,className:`inline-flex`,children:(0,W.jsx)(s,{name:`cube`,size:16,color:`var(--muted-fg)`})}):(0,W.jsx)(o,{icon:e,size:16,inline:!0})}export{de as CommandPalette}; \ No newline at end of file +import{i as e,n as t,t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{a as r,n as i,r as a,t as o}from"./inertia-app-IconAsset-D5LQFvGu.js";import{t as s}from"./inertia-app-Glyph-BTh2WfGX.js";import{A as c,O as l,S as u,h as d,k as f,m as p,v as m,w as h}from"./inertia-app.js";import{B as g,Ut as _,a as v,i as y,j as b,k as x,o as S,r as C,t as w}from"./inertia-app-cx-DVGP9Hhm.js";import{a as T,i as E,t as D}from"./inertia-app-ListBox-_e7t_Gp2.js";import{t as O}from"./inertia-app-TextField-DOf2KRkE.js";import{A as k,C as A,K as j,T as M,dt as N,g as ee,i as te,l as ne,n as re,q as P,r as F,t as I}from"./inertia-app-chromeIcons-CnRqTA89.js";import{a as L,i as R,n as z,t as B}from"./inertia-app-tooltip-D9d_CMoW.js";import{t as V}from"./inertia-app-button-B_oNuxaV.js";import{i as H}from"./inertia-app-snippets-BfAcmzWh.js";var U=e(t(),1),W=n(),G=({keys:e,withThen:t,className:n,size:r=`md`})=>(0,W.jsx)(`div`,{className:w(`flex items-center gap-x-1`,n),children:e.map((e,n)=>(0,W.jsxs)(U.Fragment,{children:[n!==0&&(0,W.jsxs)(`div`,{className:`flex items-center gap-x-1 text-quaternary`,children:[t&&(0,W.jsx)(`span`,{className:`text-sm font-medium`,children:`then`}),(0,W.jsx)(F,{size:16,strokeWidth:2.2})]}),(0,W.jsx)(`kbd`,{className:w(`min-w-6 rounded-[4px] bg-secondary_alt px-1 py-0.5 text-center font-medium text-tertiary ring-1 ring-secondary ring-inset`,r===`sm`?`font-mono text-[10.5px]`:`text-sm`),children:e.toUpperCase()})]},n))}),K=({placeholder:e,shortcutKeys:t,tooltip:n,className:r,...i})=>(0,W.jsxs)(L,{className:({isFocusWithin:e})=>w(`flex items-center gap-x-2 rounded-xl bg-primary p-4`,e&&`outline-2 outline-focus-ring`,r),children:[(0,W.jsx)(`div`,{className:`pointer-events-none absolute`,children:(0,W.jsx)(A,{className:`size-5 text-fg-quaternary`})}),(0,W.jsx)(R,{placeholder:e,className:`m-0 w-full bg-transparent pl-7 text-md text-primary ring-0 outline-hidden placeholder:text-placeholder autofill:rounded-lg autofill:text-primary`,...i}),n&&(0,W.jsx)(B,{title:n,placement:`top`,children:(0,W.jsx)(z,{className:`cursor-pointer text-fg-quaternary transition duration-200 hover:text-fg-quaternary_hover focus:text-fg-quaternary_hover`,children:(0,W.jsx)(ee,{className:`size-4 stroke-[2.25px]`})})}),t&&(0,W.jsx)(G,{keys:t})]}),q=e=>(0,W.jsxs)(`div`,{className:`flex h-7 min-w-7 items-center justify-between rounded-lg bg-primary p-1.5 ring-1 ring-secondary ring-inset`,children:[e.type===`icon`&&(0,W.jsx)(e.icon,{strokeWidth:2.4,className:`size-4 text-fg-quaternary`}),e.type===`text`&&(0,W.jsx)(`span`,{className:`text-sm font-semibold text-fg-quaternary`,children:e.label})]}),J=({className:e})=>(0,W.jsxs)(`footer`,{className:w(`absolute inset-x-0 bottom-0 flex items-center justify-between gap-x-3 bg-alpha-white/80 p-2 pl-4.5 ring-1 ring-secondary_alt backdrop-blur-lg max-md:hidden`,e),children:[(0,W.jsxs)(`div`,{className:`flex gap-4`,children:[(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsxs)(`div`,{className:`flex gap-1.5`,children:[(0,W.jsx)(q,{type:`icon`,icon:te}),(0,W.jsx)(q,{type:`icon`,icon:I})]}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`to navigate`})]}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsx)(q,{type:`icon`,icon:ne}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`to select`})]}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsx)(q,{type:`text`,label:`esc`}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`to close`})]}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,W.jsx)(q,{type:`icon`,icon:re}),(0,W.jsx)(`span`,{className:`text-sm font-semibold text-quaternary`,children:`return to parent`})]})]}),(0,W.jsx)(V,{size:`sm`,color:`tertiary`,iconLeading:M})]}),Y=({children:e,className:t})=>(0,W.jsx)(x,{className:w(`flex px-4.5 pt-2 text-xs font-semibold text-tertiary`,t),children:e});function ie(e,t){let n=new Set(t);return Object.fromEntries(Object.entries(e).filter(([e])=>!n.has(e)))}var ae=({label:e,children:t,description:n,stacked:r,shortcutKeys:i,className:a,size:o=`md`,...s})=>{let c=o===`sm`;return(0,W.jsx)(E,{...ie(s,[`type`,`icon`,`alt`,`src`]),textValue:e,className:e=>w(`group block cursor-pointer px-2 py-0.5 outline-hidden`,typeof a==`function`?a(e):a),children:a=>(0,W.jsxs)(`div`,{className:w(`relative flex min-h-10 items-center justify-between rounded-lg px-2.5 py-2 pl-2.5 outline-focus-ring transition duration-100 ease-linear hover:bg-primary_hover`,c&&`min-h-8 rounded-md px-2 py-1 pl-2`,a.isSelected&&`bg-primary_hover`,a.isFocusVisible&&`outline-2 outline-offset-2`,r&&`items-start p-2.5 pl-3.5`),children:[s.type===`icon`&&!r&&(0,W.jsx)(s.icon,{className:w(`mr-2 text-fg-quaternary`,c?`size-4`:`size-5`)}),s.type===`icon`&&r&&(0,W.jsx)(l,{color:`gray`,size:`md`,theme:`modern`,icon:s.icon,className:`mr-2`}),s.type===`avatar`&&(0,W.jsx)(h,{alt:s.alt,src:s.src,size:r?`md`:`xs`,className:`mr-2`}),s.type===`dot`&&(0,W.jsx)(`svg`,{width:`10`,height:`10`,viewBox:`0 0 10 10`,fill:`none`,className:w(`mr-2 shrink-0 text-fg-success-secondary`,r&&`mt-2 self-start`),children:(0,W.jsx)(`circle`,{cx:`5`,cy:`5`,r:`4`,fill:`currentColor`})}),(0,W.jsxs)(`div`,{className:w(`flex flex-1 gap-x-1.5`,r&&`flex-col`),children:[(0,W.jsxs)(b,{slot:`label`,className:w(`font-medium text-primary`,c?`text-[12.5px]`:`text-sm`,i&&`flex flex-1 items-center justify-between gap-2`),children:[(0,W.jsx)(`span`,{children:typeof t==`function`?t(a):t||e}),i&&` `,i&&(0,W.jsx)(G,{keys:i,size:o})]}),n&&(0,W.jsx)(b,{slot:`description`,className:w(`text-tertiary`,c?`font-mono text-[10.5px]`:`text-sm`),children:n})]})]})})},X=(0,U.createContext)({hasFooter:!1,flatItems:[],selectedKeys:new Set,setSelectedKeys:()=>{}}),oe=({items:e,children:t,dialogClassName:n,overlayClassName:r,filter:i,inputValue:a,defaultItems:o,onInputChange:s,onSelectionChange:l,sensitivity:u=`base`,placeholder:d=`Search`,defaultSelectedKeys:f,shortcut:p=`⌘/`,dialogLabel:m=`Command menu`,inputLabel:h=`Search`,listLabel:_=`Command menu results`,...v})=>{let y=(0,U.useRef)(null),{contains:b}=c({sensitivity:u}),[x,S]=(0,U.useState)(f??new Set),C=e??o,w=(C??[]).reduce((e,t)=>[...e,...t.items],[]),T=(0,U.useMemo)(()=>{let e=!1;return U.Children.forEach(t,t=>{t&&typeof t==`object`&&`type`in t&&t.type===J&&(e=!0)}),e},[t]);return(0,W.jsx)(X.Provider,{value:{hasFooter:T,flatItems:w,selectedKeys:x,setSelectedKeys:S,onSelectionChange:l,items:C,listLabel:_,...v},children:(0,W.jsx)(se,{"aria-label":m,isOpen:v.isOpen,onOpenChange:v.onOpenChange,className:r,dialogClassName:n,children:(0,W.jsxs)(g,{inputValue:a,onInputChange:s,filter:i===!1?void 0:i||b,children:[(0,W.jsx)(O,{"aria-label":h,children:(0,W.jsx)(K,{autoFocus:!0,role:`combobox`,"aria-expanded":!0,shortcutKeys:p?[p]:void 0,placeholder:d,ref:y,className:`relative outline-hidden! after:absolute after:bottom-0 after:left-0 after:h-px after:w-full after:bg-border-secondary`})}),t]})})})},se=({className:e,dialogClassName:t,children:n,"aria-label":r=`Command menu`,...i})=>(0,W.jsx)(y,{...i,isDismissable:!0,className:t=>w(`fixed inset-0 z-50 flex min-h-full items-start justify-center overflow-y-auto bg-overlay/70 p-4 text-center md:pt-16 xl:pt-[clamp(64px,10vh,243px)]`,t.isEntering&&`duration-300 ease-out animate-in fade-in`,t.isExiting&&`duration-200 ease-in animate-out fade-out`,typeof e==`function`?e(t):e),children:e=>(0,W.jsx)(C,{className:e=>w(`flex max-h-full w-160 flex-col overflow-hidden rounded-xl bg-primary text-left align-middle shadow-xl`,e.isEntering&&`duration-300 ease-out animate-in zoom-in-95`,e.isExiting&&`duration-200 ease-in animate-out zoom-out-95`,typeof t==`function`?t(e):t),children:(0,W.jsx)(S,{"aria-label":r,className:`relative flex min-h-0 flex-1 flex-col outline-hidden`,children:typeof n==`function`?n(e):n})})}),ce=({className:e,selectionMode:t=`single`,...n})=>{let{hasFooter:r,emptyState:i,listLabel:a,...o}=(0,U.useContext)(X);return(0,W.jsx)(D,{"aria-label":a,...n,...o,renderEmptyState:()=>i,selectionMode:t,onSelectionChange:e=>{o.onSelectionChange?.(e),o.setSelectedKeys(e)},className:t=>w(`flex max-h-106 flex-1 scroll-py-10 flex-col gap-2 overflow-auto focus:outline-hidden`,r&&`scroll-pb-22 pb-13`,!t.isEmpty&&`pt-2`,typeof e==`function`?e(t):e)})},le=({title:e,children:t,items:n,...r})=>(0,W.jsxs)(T,{...r,className:w(`border-b border-secondary pb-2 last:border-transparent`,r.className),children:[e&&(0,W.jsx)(Y,{className:`pb-1`,children:e},e),(0,W.jsx)(_,{items:n,children:t})]}),Z=({children:e,asChild:t,...n})=>{let{selectedKeys:r}=(0,U.useContext)(X),i=Array.from(r);if(!i.length)return null;let a=i.at(0);return t?(0,W.jsx)(U.Fragment,{children:typeof e==`function`?e({selectedId:a}):e}):(0,W.jsx)(`div`,{...n,children:typeof e==`function`?e({selectedId:a}):e})},ue=({className:e,...t})=>(0,W.jsx)(`div`,{...t,className:w(`min-h-0 flex-1`,e)}),Q=oe;Q.Item=ae,Q.List=ce,Q.Group=ue,Q.Footer=J,Q.Preview=Z,Q.Section=le,Q.Trigger=v,Q.Collection=_;function de(){let e=P(),t=r(),{catalog:n,page:i}=a(),o=j(e=>e.closeLayer),[s,c]=(0,U.useState)(``),l=j(e=>e.config?.features.commands===!1?fe:e.recentCommands),h=d(),g=k(),_=j(e=>e.config?.limits)??N.limits,v=e.getState(),y=(0,U.useMemo)(()=>[{id:`theme`,label:g(`palette.toggleTheme`),icon:`moon`,kbd:`${h}T`,run:()=>v.toggleTheme()},{id:`settings`,label:g(`palette.openSettings`),icon:`settings`,kbd:`${h},`,run:()=>v.openLayer(`settings`)},{id:`favorites`,label:g(`palette.openFavorites`),icon:`heart`,kbd:`${h}1`,run:()=>v.openLibrary(`favorites`)},{id:`history`,label:g(`palette.openHistory`),icon:`clock`,kbd:`${h}2`,run:()=>v.openLibrary(`history`)},{id:`collections`,label:g(`palette.openCollections`),icon:`folder`,kbd:`${h}3`,run:()=>v.openLibrary(`collections`)},{id:`view`,label:v.view===`grid`?g(`palette.switchListView`):g(`palette.switchGridView`),icon:v.view===`grid`?`list`:`grid`,kbd:``,run:()=>v.setView(v.view===`grid`?`list`:`grid`)},{id:`reset`,label:g(`palette.resetFilters`),icon:`refresh`,kbd:m(h),run:()=>v.openConfirm({title:g(`toolbar.resetTitle`),body:g(`toolbar.resetBody`),confirmLabel:g(`toolbar.resetConfirm`),danger:!0,onConfirm:()=>{v.resetFilters(),v.showToast(g(`toolbar.resetToast`),`refresh`)}})},{id:`selectAll`,label:g(`palette.selectAll`),icon:`check`,kbd:`${h}A`,run:()=>f(e,t)},...v.config?.features.devtools===!1?[]:[{id:`devtools`,label:g(`palette.openDevtools`),icon:`zap`,kbd:p(h),run:()=>v.toggleDevtools()}]].filter(e=>{let t=v.config?.features;return e.id===`theme`?t?.themeToggle!==!1:e.id===`favorites`||e.id===`history`||e.id===`collections`?t?.[e.id]!==!1:!0}),[h,v,g,e,t]),b=s.trim().toLowerCase(),x=b?y.filter(e=>e.label.toLowerCase().includes(b)):[...y].sort((e,t)=>$(l,e.id)-$(l,t.id)),S=(0,U.useMemo)(()=>b?(n?n.icons:i.items).filter(e=>`${e.name} ${e.id} ${(e.tags??[]).join(` `)}`.toLowerCase().includes(b)).slice(0,_.paletteIconResults):[],[b,n,i,_.paletteIconResults]),C=new Map(x.map(e=>[`a:${e.id}`,e])),T=new Map(S.map(e=>[`i:${e.id}`,e])),E=(0,U.useMemo)(()=>S.map(e=>{let t=({className:t})=>(0,W.jsx)(`span`,{className:w(`inline-flex items-center justify-center`,t),children:(0,W.jsx)(pe,{icon:e})}),n=(0,W.jsxs)(W.Fragment,{children:[e.name,` `,(0,W.jsx)(`span`,{className:`ms-1 font-mono text-[10.5px] font-normal text-tertiary`,children:H(e)})]});return{id:`i:${e.id}`,type:`icon`,icon:t,label:e.name,children:n,size:`sm`}}),[S]),D=[];return x.length&&D.push({id:`actions`,title:!b&&l.length?g(`palette.recent`):g(`palette.actions`),items:x.map(e=>({id:`a:${e.id}`,type:`icon`,icon:u(e.icon),label:e.label,shortcutKeys:e.kbd?[e.kbd]:void 0,size:`sm`}))}),E.length&&D.push({id:`icons`,title:g(`palette.icons`),items:E}),(0,W.jsxs)(Q,{isOpen:!0,onOpenChange:e=>!e&&o(),items:D,filter:!1,inputValue:s,onInputChange:c,onAction:t=>{let n=T.get(String(t));if(n){v.openDetail(n.id);return}let r=C.get(String(t));r&&(e.getState().config?.features.commands!==!1&&v.logCommand(r.id,`action`),r.run(),e.getState().layer===`palette`&&o())},shortcut:null,placeholder:g(`palette.placeholder`),inputLabel:g(`palette.placeholder`),dialogLabel:g(`header.commandPalette`),listLabel:g(`palette.results`),overlayClassName:`z-(--z-overlay)`,dialogClassName:`w-[560px] max-w-[94vw] bg-[var(--surface)] text-[length:var(--app-font,13.5px)]`,emptyState:(0,W.jsx)(`div`,{className:`p-6 text-center text-[12px] text-[var(--muted-fg)]`,children:g(`palette.noMatches`,{q:s})}),children:[(0,W.jsx)(Q.Group,{children:(0,W.jsx)(Q.List,{selectionMode:`none`,children:e=>(0,W.jsx)(Q.Section,{...e,children:e=>(0,W.jsx)(Q.Item,{...e},e.id)})})}),(0,W.jsxs)(`div`,{className:`flex items-center gap-2.5 border-t border-secondary px-3.5 py-2 text-[10.5px] text-[var(--muted-fg)]`,children:[(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`b`,{children:`↑↓`}),` `,g(`palette.navigate`)]}),(0,W.jsx)(`span`,{"aria-hidden":!0,children:`·`}),(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`b`,{children:`↵`}),` `,g(`palette.select`)]}),(0,W.jsx)(`span`,{"aria-hidden":!0,children:`·`}),(0,W.jsxs)(`span`,{children:[(0,W.jsx)(`b`,{children:`esc`}),` `,g(`palette.close`)]})]})]})}var fe=[];function $(e,t){let n=e.indexOf(t);return n<0?99:n}function pe({icon:e}){let t=!!(e.svgUrl||e.svgContent),n=i(e);return!t||n?.body===``?(0,W.jsx)(`span`,{"data-role":`preview-fallback`,className:`inline-flex`,children:(0,W.jsx)(s,{name:`cube`,size:16,color:`var(--muted-fg)`})}):(0,W.jsx)(o,{icon:e,size:16,inline:!0})}export{de as CommandPalette}; \ No newline at end of file diff --git a/public/assets/js/inertia-app-DevToolsPanel-BEVQr2SF.js b/public/assets/js/inertia-app-DevToolsPanel-DTR4iugF.js similarity index 99% rename from public/assets/js/inertia-app-DevToolsPanel-BEVQr2SF.js rename to public/assets/js/inertia-app-DevToolsPanel-DTR4iugF.js index f682055..434b3e4 100644 --- a/public/assets/js/inertia-app-DevToolsPanel-BEVQr2SF.js +++ b/public/assets/js/inertia-app-DevToolsPanel-DTR4iugF.js @@ -1 +1 @@ -import{i as e,n as t,t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{K as r,St as i,Y as a,Z as o,b as s,ct as c,ht as l,lt as u,nt as d,q as f,rt as p,tt as m,ut as h,v as g,x as _,y as v}from"./inertia-app-chromeIcons-B0Qjpt7t.js";import{i as y,p as b,r as x}from"./inertia-app.js";import{t as S}from"./inertia-app-Glyph-Sqogbcp0.js";var C=e(t(),1);function w(){return a(f())??l}var T=n(),E=[{id:`events`,label:`Events`},{id:`state`,label:`State`},{id:`storage`,label:`Storage`},{id:`tests`,label:`Tests`},{id:`logs`,label:`Logs`},{id:`boot`,label:`Boot`},{id:`status`,label:`Status`}],D=[{id:`bottom`,label:`Dock to bottom`,Icon:g},{id:`right`,label:`Dock to right`,Icon:s},{id:`left`,label:`Dock to left`,Icon:v},{id:`top`,label:`Dock to top`,Icon:_}];function O(e){if(typeof window>`u`)return o.max;let t=e===`left`||e===`right`?window.innerWidth:window.innerHeight;return Math.max(o.min,Math.min(o.max,Math.floor(t*.85)))}var k={bottom:e=>({left:0,right:0,bottom:0,height:e,borderTop:`1px solid var(--border)`,boxShadow:`0 -8px 24px -12px rgba(0,0,0,.3)`}),top:e=>({left:0,right:0,top:0,height:e,borderBottom:`1px solid var(--border)`,boxShadow:`0 8px 24px -12px rgba(0,0,0,.3)`}),left:e=>({top:0,bottom:0,left:0,width:e,borderRight:`1px solid var(--border)`,boxShadow:`8px 0 24px -12px rgba(0,0,0,.3)`}),right:e=>({top:0,bottom:0,right:0,width:e,borderLeft:`1px solid var(--border)`,boxShadow:`-8px 0 24px -12px rgba(0,0,0,.3)`})};function A(){let e=f(),t=r(e=>e.devtools.tab),n=r(e=>e.setDevToolsTab),i=r(e=>{let t=e.config?.host;return!t||!p(t,`status`)?null:m(t,`status`)??d(t,`status`,`status`)}),a=r(e=>e.toggleDevtools),{dock:s,size:c}=r(e=>e.devtoolsLayout),l=r(e=>e.setDevtoolsDock),u=r(e=>e.setDevtoolsSize),h=w();(0,C.useEffect)(()=>h.on(t=>e.getState().pushDevEvent(t)),[h,e]);let[,g]=(0,C.useState)(0);(0,C.useEffect)(()=>{let e=()=>g(e=>e+1);return window.addEventListener(`resize`,e),()=>window.removeEventListener(`resize`,e)},[]);let _=O(s),v=Math.min(c,_),y=s===`top`||s===`bottom`,b=e=>{e.preventDefault();let t=e.currentTarget;t.setPointerCapture(e.pointerId);let n=e=>s===`bottom`?window.innerHeight-e.clientY:s===`top`?e.clientY:s===`left`?e.clientX:window.innerWidth-e.clientX,r=e=>u(Math.min(O(s),n(e))),i=e=>{t.releasePointerCapture(e.pointerId),t.removeEventListener(`pointermove`,r),t.removeEventListener(`pointerup`,i)};t.addEventListener(`pointermove`,r),t.addEventListener(`pointerup`,i)},x=e=>{let t={bottom:`ArrowUp`,top:`ArrowDown`,left:`ArrowRight`,right:`ArrowLeft`}[s],n={bottom:`ArrowDown`,top:`ArrowUp`,left:`ArrowLeft`,right:`ArrowRight`}[s],r=e.shiftKey?64:16,i=null;e.key===t?i=v+r:e.key===n?i=v-r:e.key===`Home`?i=o.min:e.key===`End`&&(i=_),i!==null&&(e.preventDefault(),u(Math.min(_,i)))},A=s===`bottom`?{top:-3,left:0,right:0,height:6,cursor:`ns-resize`}:s===`top`?{bottom:-3,left:0,right:0,height:6,cursor:`ns-resize`}:s===`left`?{right:-3,top:0,bottom:0,width:6,cursor:`ew-resize`}:{left:-3,top:0,bottom:0,width:6,cursor:`ew-resize`};return(0,T.jsxs)(`div`,{role:`region`,"aria-label":`Ichava DevTools`,"data-dock":s,className:`fixed z-55 bg-[var(--pop)] flex flex-col text-[12px]`,style:k[s](v),children:[(0,T.jsx)(`div`,{role:`separator`,"aria-orientation":y?`horizontal`:`vertical`,"aria-label":`Resize DevTools`,"aria-valuemin":o.min,"aria-valuemax":_,"aria-valuenow":v,tabIndex:0,onPointerDown:b,onKeyDown:x,className:`absolute z-1 touch-none outline-focus-ring hover:bg-[var(--accent-soft)] focus-visible:bg-[var(--accent-soft)]`,style:A}),(0,T.jsxs)(`div`,{className:`flex flex-wrap items-center gap-1 min-h-[34px] py-1 px-2.5 border-b border-b-[var(--border)] flex-none`,children:[(0,T.jsx)(S,{name:`zap`,size:13,color:`var(--accent-text)`}),(0,T.jsx)(`span`,{className:`text-[12px] font-[600] mr-1.5`,children:`Ichava DevTools`}),E.filter(e=>e.id!==`status`||i).map(e=>(0,T.jsx)(`button`,{onClick:()=>n(e.id),style:{height:24,padding:`0 9px`,border:`none`,backgroundColor:t===e.id?`var(--muted)`:`transparent`,color:t===e.id?`var(--fg)`:`var(--muted-fg)`,borderRadius:5,fontSize:11.5,fontWeight:t===e.id?600:500,cursor:`pointer`},children:e.label},e.id)),(0,T.jsx)(`span`,{className:`flex-1`}),y&&(0,T.jsx)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[10px] text-[var(--faint-fg)]`,children:`window.dispatchEvent → ichava:*`}),(0,T.jsx)(`div`,{role:`radiogroup`,"aria-label":`DevTools position`,className:`ml-2 flex items-center gap-0.5 rounded-[6px] border border-[var(--border)] p-0.5`,children:D.map(({id:e,label:t,Icon:n})=>(0,T.jsx)(`button`,{role:`radio`,"aria-checked":s===e,"aria-label":t,title:t,onClick:()=>l(e),className:`flex h-5 w-5 items-center justify-center rounded-[4px] border-0 cursor-pointer ${s===e?`bg-[var(--muted)] text-[var(--fg)]`:`bg-transparent text-[var(--muted-fg)]`}`,children:(0,T.jsx)(n,{"aria-hidden":`true`,className:`size-3.5`})},e))}),(0,T.jsx)(`button`,{onClick:a,title:`Close — ⇧⌘D / Esc`,className:`ml-2 w-6 h-6 border border-[var(--border)] bg-[var(--bg)] rounded-[5px] cursor-pointer flex items-center justify-center text-[var(--muted-fg)]`,children:(0,T.jsx)(S,{name:`close`,size:11,color:`currentColor`})})]}),(0,T.jsxs)(`div`,{className:`flex-1 overflow-auto p-3 font-[family-name:'Geist_Mono',monospace]`,children:[t===`events`&&(0,T.jsx)(M,{}),t===`state`&&(0,T.jsx)(N,{}),t===`storage`&&(0,T.jsx)(P,{}),t===`tests`&&(0,T.jsx)(F,{}),t===`logs`&&(0,T.jsx)(I,{}),t===`boot`&&(0,T.jsx)(L,{}),t===`status`&&i&&(0,T.jsx)(H,{url:i})]})]})}function j(e){try{return new Date(e).toLocaleTimeString()}catch{return String(e)}}function M(){let e=r(e=>e.devtools.events),t=r(e=>e.devtools.capturing),n=r(e=>e.setCapturing),i=r(e=>e.clearDevEvents);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsxs)(z,{onClick:()=>n(!t),children:[t?`Pause`:`Resume`,` capture`]}),(0,T.jsx)(z,{onClick:i,children:`Clear log`}),(0,T.jsxs)(`span`,{className:`text-[var(--faint-fg)]`,children:[e.length,` events`]})]}),e.length===0?(0,T.jsx)(V,{children:`No events yet — interact with the app (sign in, share, toggle theme…).`}):e.map((e,t)=>(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:j(e.ts)}),(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:e.source??`page`}),(0,T.jsx)(`span`,{className:`text-[var(--accent-text)] font-semibold`,children:e.label}),e.payload!=null&&(0,T.jsx)(`span`,{className:`text-[var(--muted-fg)]`,children:JSON.stringify(e.payload)})]},t))]})}function N(){let e=r(e=>e),t={theme:e.theme,view:e.view,accent:e.accent,size:e.size,sizeUnit:e.sizeUnit,gridStroke:e.gridStroke,color:e.color,treatment:e.treatment,filters:e.filters,auth:{status:e.auth.status,plan:e.auth.user?.plan??null},favorites:e.favorites.length,collections:e.collections.length,storageDriver:e.storageDriver,consent:e.consent};return(0,T.jsx)(`pre`,{className:`m-0 whitespace-pre-wrap text-[var(--fg)] text-[11.5px] leading-[1.55]`,children:JSON.stringify(t,null,2)})}function P(){let e=f(),t=b(),n=r(e=>e.storageDriver),i=r(e=>e.setStorageDriver),a=r(e=>e.factoryReset),o=r(e=>e.openConfirm);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`font-[600] mb-1.5`,children:`Frontend storage driver`}),(0,T.jsx)(`div`,{className:`inline-flex gap-0.5 border border-[var(--border)] rounded-[6px] p-0.5 mb-2.5`,children:[`local`,`session`].map(e=>(0,T.jsx)(`button`,{onClick:()=>i(e),style:{height:24,padding:`0 12px`,border:`none`,borderRadius:4,backgroundColor:n===e?`var(--accent-soft)`:`transparent`,color:n===e?`var(--color-text-brand-secondary)`:`var(--muted-fg)`,fontSize:11.5,fontWeight:600,cursor:`pointer`},children:e===`local`?`localStorage`:`sessionStorage`},e))}),(0,T.jsxs)(`div`,{className:`text-[11px] text-[var(--muted-fg)] leading-[1.5] mb-2.5 font-[family-name:'Geist',system-ui]`,children:[`State key `,(0,T.jsx)(`b`,{children:c}),` — appearance, filters, view, favorites, collections, auth, notifications, consent. Active driver: `,(0,T.jsx)(`b`,{children:h()}),`.`]}),(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:()=>t(JSON.stringify(e.getState(),(e,t)=>e===`catalog`||e===`filtersData`?void 0:t),`State JSON copied`),children:`Copy state JSON`}),(0,T.jsx)(z,{onClick:()=>o({title:`Reset stored state?`,body:`Clears the persisted snapshot from the active storage driver and restores factory defaults.`,confirmLabel:`Reset state`,danger:!0,onConfirm:()=>{u(),a()}}),children:`Reset stored state…`})]})]})}function F(){let e=f(),t=r(e=>e.catalog),n=r(e=>e.config),[i,a]=(0,C.useState)(null),o=i?.filter(e=>e.pass).length??0,s=i?.length??0;return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:()=>a(x(t,n,e)),primary:!0,children:`Run full regression`}),i&&(0,T.jsxs)(`span`,{style:{color:o===s?`var(--success)`:`var(--danger)`,fontWeight:600},children:[o,` passed · `,s-o,` failed`]}),(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)] font-[family-name:'Geist',system-ui]`,children:`Covers catalog, pagination, snippets, treatments, config, store invariants`})]}),i?.map((e,t)=>(0,T.jsxs)(B,{children:[(0,T.jsx)(S,{name:e.pass?`check`:`close`,size:12,color:e.pass?`var(--success)`:`var(--danger)`}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:e.name}),e.detail&&!e.pass&&(0,T.jsx)(`span`,{className:`text-[var(--danger)]`,children:e.detail})]},t))]})}function I(){let e=y(),[t,n]=(0,C.useState)(0),r=(0,C.useRef)(`all`);(0,C.useEffect)(()=>e.subscribe(()=>n(e=>e+1)),[e]);let i=(0,C.useMemo)(()=>e.buffer(),[e,t]),a=b();return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:()=>{e.clear(),n(e=>e+1)},children:`Clear`}),(0,T.jsx)(z,{onClick:()=>a(JSON.stringify(i,null,2),`Logs copied`),children:`Export JSON`}),(0,T.jsxs)(`span`,{className:`text-[var(--faint-fg)]`,children:[i.length,` entries · level `,e.getLevel()]})]}),i.length===0?(0,T.jsx)(V,{children:`No log entries.`}):i.slice().reverse().map((e,t)=>(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:j(e.ts)}),(0,T.jsx)(`span`,{style:{color:e.level===`error`?`var(--danger)`:e.level===`warn`?`var(--warning)`:`var(--muted-fg)`,fontWeight:600,minWidth:40},children:e.level}),(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:e.source??`page`}),(0,T.jsx)(`span`,{className:`text-[var(--accent-text)]`,children:e.channel}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:e.message})]},t)),(0,T.jsx)(`button`,{hidden:!0,onClick:()=>r.current=`all`})]})}function L(){let e=r(e=>e.boot),t=()=>{window.ichavaBoot?.retry()},n=e=>{window.ichavaBoot?.[e](!0)};return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:t,children:`Replay boot`}),(0,T.jsx)(z,{onClick:()=>n(`simSlow`),children:`Sim slow`}),(0,T.jsx)(z,{onClick:()=>n(`simOffline`),children:`Sim offline`})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`phase`}),(0,T.jsx)(`span`,{className:`text-[var(--accent-text)] font-semibold`,children:e.phase})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`progress`}),(0,T.jsxs)(`span`,{className:`text-[var(--fg)]`,children:[e.progress,`%`]})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`label`}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:e.label||`—`})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`done`}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:String(e.done)})]})]})}function R({children:e}){return(0,T.jsx)(`div`,{className:`flex items-center gap-2 mb-2.5`,children:e})}function z({children:e,onClick:t,primary:n}){return(0,T.jsx)(`button`,{onClick:t,style:{height:26,padding:`0 10px`,border:n?`none`:`1px solid var(--border)`,borderRadius:5,backgroundColor:n?`var(--accent)`:`var(--bg)`,color:n?`var(--accent-fg)`:`var(--fg)`,fontSize:11.5,fontWeight:600,cursor:`pointer`,fontFamily:`'Geist',system-ui`},children:e})}function B({children:e}){return(0,T.jsx)(`div`,{className:`flex items-center gap-2 py-0.5 px-0 text-[11.5px]`,children:e})}function V({children:e}){return(0,T.jsx)(`div`,{className:`text-[var(--faint-fg)] font-[family-name:'Geist',system-ui] py-2 px-0`,children:e})}function H({url:e}){let[t,n]=(0,C.useState)(null),[r,a]=(0,C.useState)(null),[o,s]=(0,C.useState)(0);if((0,C.useEffect)(()=>{let t=!0;return i().request(e,{baseUrl:``}).then(e=>{t&&(n(e.data),a(null))}).catch(e=>{t&&a(String(e))}),()=>{t=!1}},[e,o]),r)return(0,T.jsxs)(`div`,{className:`text-[var(--danger)] text-[11.5px]`,children:[`Status unavailable: `,r]});if(!t)return(0,T.jsx)(`div`,{className:`text-[var(--muted-fg)] text-[11.5px]`,children:`Loading status…`});let c=[[`Packs registered`,String(t.registry.packages)],[`Conflicts`,String(t.registry.conflicts.length)],[`Orphaned packs`,String(t.orphans.length)],[`Watcher last scan`,t.watcher.lastScan??`never`],[`Render optimisation`,t.render.optimizationLevel]];return(0,T.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,T.jsx)(`dl`,{className:`grid grid-cols-[max-content_1fr] gap-x-4 gap-y-1 m-0 text-[11.5px]`,children:c.map(([e,t])=>(0,T.jsxs)(`div`,{className:`contents`,children:[(0,T.jsx)(`dt`,{className:`text-[var(--muted-fg)]`,children:e}),(0,T.jsx)(`dd`,{className:`m-0 font-[family-name:'Geist_Mono',monospace]`,children:t})]},e))}),(0,T.jsx)(`div`,{children:(0,T.jsx)(z,{onClick:()=>s(e=>e+1),children:`Refresh`})}),(0,T.jsx)(`pre`,{className:`m-0 whitespace-pre-wrap text-[var(--fg)] text-[11px] leading-[1.5]`,children:JSON.stringify(t,null,2)})]})}export{A as DevToolsPanel}; \ No newline at end of file +import{i as e,n as t,t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{K as r,St as i,Y as a,Z as o,b as s,ct as c,ht as l,lt as u,nt as d,q as f,rt as p,tt as m,ut as h,v as g,x as _,y as v}from"./inertia-app-chromeIcons-CnRqTA89.js";import{i as y,p as b,r as x}from"./inertia-app.js";import{t as S}from"./inertia-app-Glyph-BTh2WfGX.js";var C=e(t(),1);function w(){return a(f())??l}var T=n(),E=[{id:`events`,label:`Events`},{id:`state`,label:`State`},{id:`storage`,label:`Storage`},{id:`tests`,label:`Tests`},{id:`logs`,label:`Logs`},{id:`boot`,label:`Boot`},{id:`status`,label:`Status`}],D=[{id:`bottom`,label:`Dock to bottom`,Icon:g},{id:`right`,label:`Dock to right`,Icon:s},{id:`left`,label:`Dock to left`,Icon:v},{id:`top`,label:`Dock to top`,Icon:_}];function O(e){if(typeof window>`u`)return o.max;let t=e===`left`||e===`right`?window.innerWidth:window.innerHeight;return Math.max(o.min,Math.min(o.max,Math.floor(t*.85)))}var k={bottom:e=>({left:0,right:0,bottom:0,height:e,borderTop:`1px solid var(--border)`,boxShadow:`0 -8px 24px -12px rgba(0,0,0,.3)`}),top:e=>({left:0,right:0,top:0,height:e,borderBottom:`1px solid var(--border)`,boxShadow:`0 8px 24px -12px rgba(0,0,0,.3)`}),left:e=>({top:0,bottom:0,left:0,width:e,borderRight:`1px solid var(--border)`,boxShadow:`8px 0 24px -12px rgba(0,0,0,.3)`}),right:e=>({top:0,bottom:0,right:0,width:e,borderLeft:`1px solid var(--border)`,boxShadow:`-8px 0 24px -12px rgba(0,0,0,.3)`})};function A(){let e=f(),t=r(e=>e.devtools.tab),n=r(e=>e.setDevToolsTab),i=r(e=>{let t=e.config?.host;return!t||!p(t,`status`)?null:m(t,`status`)??d(t,`status`,`status`)}),a=r(e=>e.toggleDevtools),{dock:s,size:c}=r(e=>e.devtoolsLayout),l=r(e=>e.setDevtoolsDock),u=r(e=>e.setDevtoolsSize),h=w();(0,C.useEffect)(()=>h.on(t=>e.getState().pushDevEvent(t)),[h,e]);let[,g]=(0,C.useState)(0);(0,C.useEffect)(()=>{let e=()=>g(e=>e+1);return window.addEventListener(`resize`,e),()=>window.removeEventListener(`resize`,e)},[]);let _=O(s),v=Math.min(c,_),y=s===`top`||s===`bottom`,b=e=>{e.preventDefault();let t=e.currentTarget;t.setPointerCapture(e.pointerId);let n=e=>s===`bottom`?window.innerHeight-e.clientY:s===`top`?e.clientY:s===`left`?e.clientX:window.innerWidth-e.clientX,r=e=>u(Math.min(O(s),n(e))),i=e=>{t.releasePointerCapture(e.pointerId),t.removeEventListener(`pointermove`,r),t.removeEventListener(`pointerup`,i)};t.addEventListener(`pointermove`,r),t.addEventListener(`pointerup`,i)},x=e=>{let t={bottom:`ArrowUp`,top:`ArrowDown`,left:`ArrowRight`,right:`ArrowLeft`}[s],n={bottom:`ArrowDown`,top:`ArrowUp`,left:`ArrowLeft`,right:`ArrowRight`}[s],r=e.shiftKey?64:16,i=null;e.key===t?i=v+r:e.key===n?i=v-r:e.key===`Home`?i=o.min:e.key===`End`&&(i=_),i!==null&&(e.preventDefault(),u(Math.min(_,i)))},A=s===`bottom`?{top:-3,left:0,right:0,height:6,cursor:`ns-resize`}:s===`top`?{bottom:-3,left:0,right:0,height:6,cursor:`ns-resize`}:s===`left`?{right:-3,top:0,bottom:0,width:6,cursor:`ew-resize`}:{left:-3,top:0,bottom:0,width:6,cursor:`ew-resize`};return(0,T.jsxs)(`div`,{role:`region`,"aria-label":`Ichava DevTools`,"data-dock":s,className:`fixed z-55 bg-[var(--pop)] flex flex-col text-[12px]`,style:k[s](v),children:[(0,T.jsx)(`div`,{role:`separator`,"aria-orientation":y?`horizontal`:`vertical`,"aria-label":`Resize DevTools`,"aria-valuemin":o.min,"aria-valuemax":_,"aria-valuenow":v,tabIndex:0,onPointerDown:b,onKeyDown:x,className:`absolute z-1 touch-none outline-focus-ring hover:bg-[var(--accent-soft)] focus-visible:bg-[var(--accent-soft)]`,style:A}),(0,T.jsxs)(`div`,{className:`flex flex-wrap items-center gap-1 min-h-[34px] py-1 px-2.5 border-b border-b-[var(--border)] flex-none`,children:[(0,T.jsx)(S,{name:`zap`,size:13,color:`var(--accent-text)`}),(0,T.jsx)(`span`,{className:`text-[12px] font-[600] mr-1.5`,children:`Ichava DevTools`}),E.filter(e=>e.id!==`status`||i).map(e=>(0,T.jsx)(`button`,{onClick:()=>n(e.id),style:{height:24,padding:`0 9px`,border:`none`,backgroundColor:t===e.id?`var(--muted)`:`transparent`,color:t===e.id?`var(--fg)`:`var(--muted-fg)`,borderRadius:5,fontSize:11.5,fontWeight:t===e.id?600:500,cursor:`pointer`},children:e.label},e.id)),(0,T.jsx)(`span`,{className:`flex-1`}),y&&(0,T.jsx)(`span`,{className:`font-[family-name:'Geist_Mono',monospace] text-[10px] text-[var(--faint-fg)]`,children:`window.dispatchEvent → ichava:*`}),(0,T.jsx)(`div`,{role:`radiogroup`,"aria-label":`DevTools position`,className:`ml-2 flex items-center gap-0.5 rounded-[6px] border border-[var(--border)] p-0.5`,children:D.map(({id:e,label:t,Icon:n})=>(0,T.jsx)(`button`,{role:`radio`,"aria-checked":s===e,"aria-label":t,title:t,onClick:()=>l(e),className:`flex h-5 w-5 items-center justify-center rounded-[4px] border-0 cursor-pointer ${s===e?`bg-[var(--muted)] text-[var(--fg)]`:`bg-transparent text-[var(--muted-fg)]`}`,children:(0,T.jsx)(n,{"aria-hidden":`true`,className:`size-3.5`})},e))}),(0,T.jsx)(`button`,{onClick:a,title:`Close — ⇧⌘D / Esc`,className:`ml-2 w-6 h-6 border border-[var(--border)] bg-[var(--bg)] rounded-[5px] cursor-pointer flex items-center justify-center text-[var(--muted-fg)]`,children:(0,T.jsx)(S,{name:`close`,size:11,color:`currentColor`})})]}),(0,T.jsxs)(`div`,{className:`flex-1 overflow-auto p-3 font-[family-name:'Geist_Mono',monospace]`,children:[t===`events`&&(0,T.jsx)(M,{}),t===`state`&&(0,T.jsx)(N,{}),t===`storage`&&(0,T.jsx)(P,{}),t===`tests`&&(0,T.jsx)(F,{}),t===`logs`&&(0,T.jsx)(I,{}),t===`boot`&&(0,T.jsx)(L,{}),t===`status`&&i&&(0,T.jsx)(H,{url:i})]})]})}function j(e){try{return new Date(e).toLocaleTimeString()}catch{return String(e)}}function M(){let e=r(e=>e.devtools.events),t=r(e=>e.devtools.capturing),n=r(e=>e.setCapturing),i=r(e=>e.clearDevEvents);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsxs)(z,{onClick:()=>n(!t),children:[t?`Pause`:`Resume`,` capture`]}),(0,T.jsx)(z,{onClick:i,children:`Clear log`}),(0,T.jsxs)(`span`,{className:`text-[var(--faint-fg)]`,children:[e.length,` events`]})]}),e.length===0?(0,T.jsx)(V,{children:`No events yet — interact with the app (sign in, share, toggle theme…).`}):e.map((e,t)=>(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:j(e.ts)}),(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:e.source??`page`}),(0,T.jsx)(`span`,{className:`text-[var(--accent-text)] font-semibold`,children:e.label}),e.payload!=null&&(0,T.jsx)(`span`,{className:`text-[var(--muted-fg)]`,children:JSON.stringify(e.payload)})]},t))]})}function N(){let e=r(e=>e),t={theme:e.theme,view:e.view,accent:e.accent,size:e.size,sizeUnit:e.sizeUnit,gridStroke:e.gridStroke,color:e.color,treatment:e.treatment,filters:e.filters,auth:{status:e.auth.status,plan:e.auth.user?.plan??null},favorites:e.favorites.length,collections:e.collections.length,storageDriver:e.storageDriver,consent:e.consent};return(0,T.jsx)(`pre`,{className:`m-0 whitespace-pre-wrap text-[var(--fg)] text-[11.5px] leading-[1.55]`,children:JSON.stringify(t,null,2)})}function P(){let e=f(),t=b(),n=r(e=>e.storageDriver),i=r(e=>e.setStorageDriver),a=r(e=>e.factoryReset),o=r(e=>e.openConfirm);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`font-[600] mb-1.5`,children:`Frontend storage driver`}),(0,T.jsx)(`div`,{className:`inline-flex gap-0.5 border border-[var(--border)] rounded-[6px] p-0.5 mb-2.5`,children:[`local`,`session`].map(e=>(0,T.jsx)(`button`,{onClick:()=>i(e),style:{height:24,padding:`0 12px`,border:`none`,borderRadius:4,backgroundColor:n===e?`var(--accent-soft)`:`transparent`,color:n===e?`var(--color-text-brand-secondary)`:`var(--muted-fg)`,fontSize:11.5,fontWeight:600,cursor:`pointer`},children:e===`local`?`localStorage`:`sessionStorage`},e))}),(0,T.jsxs)(`div`,{className:`text-[11px] text-[var(--muted-fg)] leading-[1.5] mb-2.5 font-[family-name:'Geist',system-ui]`,children:[`State key `,(0,T.jsx)(`b`,{children:c}),` — appearance, filters, view, favorites, collections, auth, notifications, consent. Active driver: `,(0,T.jsx)(`b`,{children:h()}),`.`]}),(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:()=>t(JSON.stringify(e.getState(),(e,t)=>e===`catalog`||e===`filtersData`?void 0:t),`State JSON copied`),children:`Copy state JSON`}),(0,T.jsx)(z,{onClick:()=>o({title:`Reset stored state?`,body:`Clears the persisted snapshot from the active storage driver and restores factory defaults.`,confirmLabel:`Reset state`,danger:!0,onConfirm:()=>{u(),a()}}),children:`Reset stored state…`})]})]})}function F(){let e=f(),t=r(e=>e.catalog),n=r(e=>e.config),[i,a]=(0,C.useState)(null),o=i?.filter(e=>e.pass).length??0,s=i?.length??0;return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:()=>a(x(t,n,e)),primary:!0,children:`Run full regression`}),i&&(0,T.jsxs)(`span`,{style:{color:o===s?`var(--success)`:`var(--danger)`,fontWeight:600},children:[o,` passed · `,s-o,` failed`]}),(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)] font-[family-name:'Geist',system-ui]`,children:`Covers catalog, pagination, snippets, treatments, config, store invariants`})]}),i?.map((e,t)=>(0,T.jsxs)(B,{children:[(0,T.jsx)(S,{name:e.pass?`check`:`close`,size:12,color:e.pass?`var(--success)`:`var(--danger)`}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:e.name}),e.detail&&!e.pass&&(0,T.jsx)(`span`,{className:`text-[var(--danger)]`,children:e.detail})]},t))]})}function I(){let e=y(),[t,n]=(0,C.useState)(0),r=(0,C.useRef)(`all`);(0,C.useEffect)(()=>e.subscribe(()=>n(e=>e+1)),[e]);let i=(0,C.useMemo)(()=>e.buffer(),[e,t]),a=b();return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:()=>{e.clear(),n(e=>e+1)},children:`Clear`}),(0,T.jsx)(z,{onClick:()=>a(JSON.stringify(i,null,2),`Logs copied`),children:`Export JSON`}),(0,T.jsxs)(`span`,{className:`text-[var(--faint-fg)]`,children:[i.length,` entries · level `,e.getLevel()]})]}),i.length===0?(0,T.jsx)(V,{children:`No log entries.`}):i.slice().reverse().map((e,t)=>(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:j(e.ts)}),(0,T.jsx)(`span`,{style:{color:e.level===`error`?`var(--danger)`:e.level===`warn`?`var(--warning)`:`var(--muted-fg)`,fontWeight:600,minWidth:40},children:e.level}),(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:e.source??`page`}),(0,T.jsx)(`span`,{className:`text-[var(--accent-text)]`,children:e.channel}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:e.message})]},t)),(0,T.jsx)(`button`,{hidden:!0,onClick:()=>r.current=`all`})]})}function L(){let e=r(e=>e.boot),t=()=>{window.ichavaBoot?.retry()},n=e=>{window.ichavaBoot?.[e](!0)};return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsxs)(R,{children:[(0,T.jsx)(z,{onClick:t,children:`Replay boot`}),(0,T.jsx)(z,{onClick:()=>n(`simSlow`),children:`Sim slow`}),(0,T.jsx)(z,{onClick:()=>n(`simOffline`),children:`Sim offline`})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`phase`}),(0,T.jsx)(`span`,{className:`text-[var(--accent-text)] font-semibold`,children:e.phase})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`progress`}),(0,T.jsxs)(`span`,{className:`text-[var(--fg)]`,children:[e.progress,`%`]})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`label`}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:e.label||`—`})]}),(0,T.jsxs)(B,{children:[(0,T.jsx)(`span`,{className:`text-[var(--faint-fg)]`,children:`done`}),(0,T.jsx)(`span`,{className:`text-[var(--fg)]`,children:String(e.done)})]})]})}function R({children:e}){return(0,T.jsx)(`div`,{className:`flex items-center gap-2 mb-2.5`,children:e})}function z({children:e,onClick:t,primary:n}){return(0,T.jsx)(`button`,{onClick:t,style:{height:26,padding:`0 10px`,border:n?`none`:`1px solid var(--border)`,borderRadius:5,backgroundColor:n?`var(--accent)`:`var(--bg)`,color:n?`var(--accent-fg)`:`var(--fg)`,fontSize:11.5,fontWeight:600,cursor:`pointer`,fontFamily:`'Geist',system-ui`},children:e})}function B({children:e}){return(0,T.jsx)(`div`,{className:`flex items-center gap-2 py-0.5 px-0 text-[11.5px]`,children:e})}function V({children:e}){return(0,T.jsx)(`div`,{className:`text-[var(--faint-fg)] font-[family-name:'Geist',system-ui] py-2 px-0`,children:e})}function H({url:e}){let[t,n]=(0,C.useState)(null),[r,a]=(0,C.useState)(null),[o,s]=(0,C.useState)(0);if((0,C.useEffect)(()=>{let t=!0;return i().request(e,{baseUrl:``}).then(e=>{t&&(n(e.data),a(null))}).catch(e=>{t&&a(String(e))}),()=>{t=!1}},[e,o]),r)return(0,T.jsxs)(`div`,{className:`text-[var(--danger)] text-[11.5px]`,children:[`Status unavailable: `,r]});if(!t)return(0,T.jsx)(`div`,{className:`text-[var(--muted-fg)] text-[11.5px]`,children:`Loading status…`});let c=[[`Packs registered`,String(t.registry.packages)],[`Conflicts`,String(t.registry.conflicts.length)],[`Orphaned packs`,String(t.orphans.length)],[`Watcher last scan`,t.watcher.lastScan??`never`],[`Render optimisation`,t.render.optimizationLevel]];return(0,T.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,T.jsx)(`dl`,{className:`grid grid-cols-[max-content_1fr] gap-x-4 gap-y-1 m-0 text-[11.5px]`,children:c.map(([e,t])=>(0,T.jsxs)(`div`,{className:`contents`,children:[(0,T.jsx)(`dt`,{className:`text-[var(--muted-fg)]`,children:e}),(0,T.jsx)(`dd`,{className:`m-0 font-[family-name:'Geist_Mono',monospace]`,children:t})]},e))}),(0,T.jsx)(`div`,{children:(0,T.jsx)(z,{onClick:()=>s(e=>e+1),children:`Refresh`})}),(0,T.jsx)(`pre`,{className:`m-0 whitespace-pre-wrap text-[var(--fg)] text-[11px] leading-[1.5]`,children:JSON.stringify(t,null,2)})]})}export{A as DevToolsPanel}; \ No newline at end of file diff --git a/public/assets/js/inertia-app-Glyph-Sqogbcp0.js b/public/assets/js/inertia-app-Glyph-BTh2WfGX.js similarity index 99% rename from public/assets/js/inertia-app-Glyph-Sqogbcp0.js rename to public/assets/js/inertia-app-Glyph-BTh2WfGX.js index c2d9463..034594b 100644 --- a/public/assets/js/inertia-app-Glyph-Sqogbcp0.js +++ b/public/assets/js/inertia-app-Glyph-BTh2WfGX.js @@ -1 +1 @@ -import{B as e,F as t,H as n,I as r,L as i,M as a,N as o,P as s,R as c,U as l,V as u,W as d,j as f,z as p}from"./inertia-app-chromeIcons-B0Qjpt7t.js";import{t as m}from"./inertia-app-jsx-runtime-DyZJNswf.js";function h(e){return e?/^(https?:)?\//.test(e)?e:`${`./`.replace(/\/$/,``)}/${e.replace(/^\//,``)}`:``}function g(e){return`data:image/svg+xml;charset=utf-8,${encodeURIComponent(e)}`}var _=new class{url(e){return e.svgUrl?h(e.svgUrl):e.svgContent?g(e.svgContent):``}resolve(e,t){let n=this.url(e);return e.ownColor?{kind:`image`,url:n}:{kind:`mask`,url:n,color:t??`currentColor`}}toStyle(e,t){let n={width:`${t}px`,height:`${t}px`};return e.kind===`image`?{...n,backgroundImage:`url("${e.url}")`,backgroundSize:`contain`,backgroundRepeat:`no-repeat`,backgroundPosition:`center`}:{...n,backgroundColor:e.color,maskImage:`url("${e.url}")`,maskSize:`contain`,maskRepeat:`no-repeat`,maskPosition:`center`,WebkitMaskImage:`url("${e.url}")`,WebkitMaskSize:`contain`,WebkitMaskRepeat:`no-repeat`,WebkitMaskPosition:`center`}}},v=d(`outline`,`adjustments-horizontal`,`AdjustmentsHorizontal`,[[`path`,{d:`M12 6a2 2 0 1 0 4 0a2 2 0 1 0 -4 0`,key:`svg-0`}],[`path`,{d:`M4 6l8 0`,key:`svg-1`}],[`path`,{d:`M16 6l4 0`,key:`svg-2`}],[`path`,{d:`M6 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0`,key:`svg-3`}],[`path`,{d:`M4 12l2 0`,key:`svg-4`}],[`path`,{d:`M10 12l10 0`,key:`svg-5`}],[`path`,{d:`M15 18a2 2 0 1 0 4 0a2 2 0 1 0 -4 0`,key:`svg-6`}],[`path`,{d:`M4 18l11 0`,key:`svg-7`}],[`path`,{d:`M19 18l1 0`,key:`svg-8`}]]),y=d(`outline`,`alert-circle`,`AlertCircle`,[[`path`,{d:`M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0`,key:`svg-0`}],[`path`,{d:`M12 8v4`,key:`svg-1`}],[`path`,{d:`M12 16h.01`,key:`svg-2`}]]),b=d(`outline`,`bolt`,`Bolt`,[[`path`,{d:`M13 3l0 7l6 0l-8 11l0 -7l-6 0l8 -11`,key:`svg-0`}]]),x=d(`outline`,`chart-bar`,`ChartBar`,[[`path`,{d:`M3 13a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -6`,key:`svg-0`}],[`path`,{d:`M15 9a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v10a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -10`,key:`svg-1`}],[`path`,{d:`M9 5a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v14a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -14`,key:`svg-2`}],[`path`,{d:`M4 20h14`,key:`svg-3`}]]),S=d(`outline`,`chevron-left`,`ChevronLeft`,[[`path`,{d:`M15 6l-6 6l6 6`,key:`svg-0`}]]),C=d(`outline`,`chevron-up`,`ChevronUp`,[[`path`,{d:`M6 15l6 -6l6 6`,key:`svg-0`}]]),w=d(`outline`,`clock`,`Clock`,[[`path`,{d:`M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0`,key:`svg-0`}],[`path`,{d:`M12 7v5l3 3`,key:`svg-1`}]]),T=d(`outline`,`command`,`Command`,[[`path`,{d:`M7 9a2 2 0 1 1 2 -2v10a2 2 0 1 1 -2 -2h10a2 2 0 1 1 -2 2v-10a2 2 0 1 1 2 2h-10`,key:`svg-0`}]]),E=d(`outline`,`copy`,`Copy`,[[`path`,{d:`M7 9.667a2.667 2.667 0 0 1 2.667 -2.667h8.666a2.667 2.667 0 0 1 2.667 2.667v8.666a2.667 2.667 0 0 1 -2.667 2.667h-8.666a2.667 2.667 0 0 1 -2.667 -2.667l0 -8.666`,key:`svg-0`}],[`path`,{d:`M4.012 16.737a2.005 2.005 0 0 1 -1.012 -1.737v-10c0 -1.1 .9 -2 2 -2h10c.75 0 1.158 .385 1.5 1`,key:`svg-1`}]]),D=d(`outline`,`cube`,`Cube`,[[`path`,{d:`M21 16.008v-8.018a1.98 1.98 0 0 0 -1 -1.717l-7 -4.008a2.016 2.016 0 0 0 -2 0l-7 4.008c-.619 .355 -1 1.01 -1 1.718v8.018c0 .709 .381 1.363 1 1.717l7 4.008a2.016 2.016 0 0 0 2 0l7 -4.008c.619 -.355 1 -1.01 1 -1.718`,key:`svg-0`}],[`path`,{d:`M12 22v-10`,key:`svg-1`}],[`path`,{d:`M12 12l8.73 -5.04`,key:`svg-2`}],[`path`,{d:`M3.27 6.96l8.73 5.04`,key:`svg-3`}]]),O=d(`outline`,`download`,`Download`,[[`path`,{d:`M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2`,key:`svg-0`}],[`path`,{d:`M7 11l5 5l5 -5`,key:`svg-1`}],[`path`,{d:`M12 4l0 12`,key:`svg-2`}]]),k=d(`outline`,`heart`,`Heart`,[[`path`,{d:`M19.5 12.572l-7.5 7.428l-7.5 -7.428a5 5 0 1 1 7.5 -6.566a5 5 0 1 1 7.5 6.572`,key:`svg-0`}]]),A=d(`outline`,`layout-grid`,`LayoutGrid`,[[`path`,{d:`M4 5a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-0`}],[`path`,{d:`M14 5a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-1`}],[`path`,{d:`M4 15a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-2`}],[`path`,{d:`M14 15a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-3`}]]),j=d(`outline`,`link`,`Link`,[[`path`,{d:`M9 15l6 -6`,key:`svg-0`}],[`path`,{d:`M11 6l.463 -.536a5 5 0 0 1 7.071 7.072l-.534 .464`,key:`svg-1`}],[`path`,{d:`M13 18l-.397 .534a5.068 5.068 0 0 1 -7.127 0a4.972 4.972 0 0 1 0 -7.071l.524 -.463`,key:`svg-2`}]]),M=d(`outline`,`list`,`List`,[[`path`,{d:`M9 6l11 0`,key:`svg-0`}],[`path`,{d:`M9 12l11 0`,key:`svg-1`}],[`path`,{d:`M9 18l11 0`,key:`svg-2`}],[`path`,{d:`M5 6l0 .01`,key:`svg-3`}],[`path`,{d:`M5 12l0 .01`,key:`svg-4`}],[`path`,{d:`M5 18l0 .01`,key:`svg-5`}]]),N=d(`outline`,`maximize`,`Maximize`,[[`path`,{d:`M4 8v-2a2 2 0 0 1 2 -2h2`,key:`svg-0`}],[`path`,{d:`M4 16v2a2 2 0 0 0 2 2h2`,key:`svg-1`}],[`path`,{d:`M16 4h2a2 2 0 0 1 2 2v2`,key:`svg-2`}],[`path`,{d:`M16 20h2a2 2 0 0 0 2 -2v-2`,key:`svg-3`}]]),P=d(`outline`,`minimize`,`Minimize`,[[`path`,{d:`M15 19v-2a2 2 0 0 1 2 -2h2`,key:`svg-0`}],[`path`,{d:`M15 5v2a2 2 0 0 0 2 2h2`,key:`svg-1`}],[`path`,{d:`M5 15h2a2 2 0 0 1 2 2v2`,key:`svg-2`}],[`path`,{d:`M5 9h2a2 2 0 0 0 2 -2v-2`,key:`svg-3`}]]),F=d(`outline`,`moon`,`Moon`,[[`path`,{d:`M12 3c.132 0 .263 0 .393 0a7.5 7.5 0 0 0 7.92 12.446a9 9 0 1 1 -8.313 -12.454l0 .008`,key:`svg-0`}]]),I=d(`outline`,`palette`,`Palette`,[[`path`,{d:`M12 21a9 9 0 0 1 0 -18c4.97 0 9 3.582 9 8c0 1.06 -.474 2.078 -1.318 2.828c-.844 .75 -1.989 1.172 -3.182 1.172h-2.5a2 2 0 0 0 -1 3.75a1.3 1.3 0 0 1 -1 2.25`,key:`svg-0`}],[`path`,{d:`M7.5 10.5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0`,key:`svg-1`}],[`path`,{d:`M11.5 7.5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0`,key:`svg-2`}],[`path`,{d:`M15.5 10.5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0`,key:`svg-3`}]]),L=d(`outline`,`player-pause`,`PlayerPause`,[[`path`,{d:`M6 6a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v12a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1l0 -12`,key:`svg-0`}],[`path`,{d:`M14 6a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v12a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1l0 -12`,key:`svg-1`}]]),R=d(`outline`,`player-play`,`PlayerPlay`,[[`path`,{d:`M7 4v16l13 -8l-13 -8`,key:`svg-0`}]]),z=d(`outline`,`plus`,`Plus`,[[`path`,{d:`M12 5l0 14`,key:`svg-0`}],[`path`,{d:`M5 12l14 0`,key:`svg-1`}]]),B=d(`outline`,`refresh`,`Refresh`,[[`path`,{d:`M20 11a8.1 8.1 0 0 0 -15.5 -2m-.5 -4v4h4`,key:`svg-0`}],[`path`,{d:`M4 13a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4`,key:`svg-1`}]]),V=d(`outline`,`stack-2`,`Stack2`,[[`path`,{d:`M12 4l-8 4l8 4l8 -4l-8 -4`,key:`svg-0`}],[`path`,{d:`M4 12l8 4l8 -4`,key:`svg-1`}],[`path`,{d:`M4 16l8 4l8 -4`,key:`svg-2`}]]),H=d(`outline`,`sun`,`Sun`,[[`path`,{d:`M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0`,key:`svg-0`}],[`path`,{d:`M3 12h1m8 -9v1m8 8h1m-9 8v1m-6.4 -15.4l.7 .7m12.1 -.7l-.7 .7m0 11.4l.7 .7m-12.1 -.7l-.7 .7`,key:`svg-1`}]]),U=d(`outline`,`trash`,`Trash`,[[`path`,{d:`M4 7l16 0`,key:`svg-0`}],[`path`,{d:`M10 11l0 6`,key:`svg-1`}],[`path`,{d:`M14 11l0 6`,key:`svg-2`}],[`path`,{d:`M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2 -2l1 -12`,key:`svg-3`}],[`path`,{d:`M9 7v-3a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v3`,key:`svg-4`}]]),W=d(`outline`,`typography`,`Typography`,[[`path`,{d:`M4 20l3 0`,key:`svg-0`}],[`path`,{d:`M14 20l7 0`,key:`svg-1`}],[`path`,{d:`M6.9 15l6.9 0`,key:`svg-2`}],[`path`,{d:`M10.2 6.3l5.8 13.7`,key:`svg-3`}],[`path`,{d:`M5 20l6 -16l2 0l7 16`,key:`svg-4`}]]),G=d(`outline`,`world`,`World`,[[`path`,{d:`M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0`,key:`svg-0`}],[`path`,{d:`M3.6 9h16.8`,key:`svg-1`}],[`path`,{d:`M3.6 15h16.8`,key:`svg-2`}],[`path`,{d:`M11.5 3a17 17 0 0 0 0 18`,key:`svg-3`}],[`path`,{d:`M12.5 3a17 17 0 0 1 0 18`,key:`svg-4`}]]),K=d(`filled`,`bell-filled`,`BellFilled`,[[`path`,{d:`M14.235 19c.865 0 1.322 1.024 .745 1.668a3.992 3.992 0 0 1 -2.98 1.332a3.992 3.992 0 0 1 -2.98 -1.332c-.552 -.616 -.158 -1.579 .634 -1.661l.11 -.006h4.471z`,key:`svg-0`}],[`path`,{d:`M12 2c1.358 0 2.506 .903 2.875 2.141l.046 .171l.008 .043a8.013 8.013 0 0 1 4.024 6.069l.028 .287l.019 .289v2.931l.021 .136a3 3 0 0 0 1.143 1.847l.167 .117l.162 .099c.86 .487 .56 1.766 -.377 1.864l-.116 .006h-16c-1.028 0 -1.387 -1.364 -.493 -1.87a3 3 0 0 0 1.472 -2.063l.021 -.143l.001 -2.97a8 8 0 0 1 3.821 -6.454l.248 -.146l.01 -.043a3.003 3.003 0 0 1 2.562 -2.29l.182 -.017l.176 -.004z`,key:`svg-1`}]]),q=d(`filled`,`heart-filled`,`HeartFilled`,[[`path`,{d:`M6.979 3.074a6 6 0 0 1 4.988 1.425l.037 .033l.034 -.03a6 6 0 0 1 4.733 -1.44l.246 .036a6 6 0 0 1 3.364 10.008l-.18 .185l-.048 .041l-7.45 7.379a1 1 0 0 1 -1.313 .082l-.094 -.082l-7.493 -7.422a6 6 0 0 1 3.176 -10.215z`,key:`svg-0`}]]),J={"alert-circle":y,"bell-filled":K,check:u,"chevron-down":e,"chevron-left":S,"chevron-right":p,"chevron-up":C,clock:w,close:f,command:T,copy:E,cube:D,download:O,eye:c,folder:i,globe:G,grid:A,heart:k,"heart-filled":q,info:r,layers:V,link:j,list:M,minimize:P,moon:F,package:t,palette:I,pause:L,play:R,plus:z,refresh:B,resize:N,search:s,settings:o,sliders:v,"sort-asc":n,"sort-desc":l,sparkles:a,stats:x,sun:H,text:W,trash:U,zap:b},Y=m(),X=new Set;function Z({name:e,size:t=14,color:n,style:r,className:i}){let a=J[e];return a?(0,Y.jsx)(a,{"aria-hidden":!0,size:t,stroke:1.75,color:n??`currentColor`,...X.has(e)?{fill:`currentColor`}:null,className:i,style:{flex:`none`,...r}}):(0,Y.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,width:t,height:t,flex:`none`,...r}})}export{h as n,_ as r,Z as t}; \ No newline at end of file +import{B as e,F as t,H as n,I as r,L as i,M as a,N as o,P as s,R as c,U as l,V as u,W as d,j as f,z as p}from"./inertia-app-chromeIcons-CnRqTA89.js";import{t as m}from"./inertia-app-jsx-runtime-DyZJNswf.js";function h(e){return e?/^(https?:)?\//.test(e)?e:`${`./`.replace(/\/$/,``)}/${e.replace(/^\//,``)}`:``}function g(e){return`data:image/svg+xml;charset=utf-8,${encodeURIComponent(e)}`}var _=new class{url(e){return e.svgUrl?h(e.svgUrl):e.svgContent?g(e.svgContent):``}resolve(e,t){let n=this.url(e);return e.ownColor?{kind:`image`,url:n}:{kind:`mask`,url:n,color:t??`currentColor`}}toStyle(e,t){let n={width:`${t}px`,height:`${t}px`};return e.kind===`image`?{...n,backgroundImage:`url("${e.url}")`,backgroundSize:`contain`,backgroundRepeat:`no-repeat`,backgroundPosition:`center`}:{...n,backgroundColor:e.color,maskImage:`url("${e.url}")`,maskSize:`contain`,maskRepeat:`no-repeat`,maskPosition:`center`,WebkitMaskImage:`url("${e.url}")`,WebkitMaskSize:`contain`,WebkitMaskRepeat:`no-repeat`,WebkitMaskPosition:`center`}}},v=d(`outline`,`adjustments-horizontal`,`AdjustmentsHorizontal`,[[`path`,{d:`M12 6a2 2 0 1 0 4 0a2 2 0 1 0 -4 0`,key:`svg-0`}],[`path`,{d:`M4 6l8 0`,key:`svg-1`}],[`path`,{d:`M16 6l4 0`,key:`svg-2`}],[`path`,{d:`M6 12a2 2 0 1 0 4 0a2 2 0 1 0 -4 0`,key:`svg-3`}],[`path`,{d:`M4 12l2 0`,key:`svg-4`}],[`path`,{d:`M10 12l10 0`,key:`svg-5`}],[`path`,{d:`M15 18a2 2 0 1 0 4 0a2 2 0 1 0 -4 0`,key:`svg-6`}],[`path`,{d:`M4 18l11 0`,key:`svg-7`}],[`path`,{d:`M19 18l1 0`,key:`svg-8`}]]),y=d(`outline`,`alert-circle`,`AlertCircle`,[[`path`,{d:`M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0`,key:`svg-0`}],[`path`,{d:`M12 8v4`,key:`svg-1`}],[`path`,{d:`M12 16h.01`,key:`svg-2`}]]),b=d(`outline`,`bolt`,`Bolt`,[[`path`,{d:`M13 3l0 7l6 0l-8 11l0 -7l-6 0l8 -11`,key:`svg-0`}]]),x=d(`outline`,`chart-bar`,`ChartBar`,[[`path`,{d:`M3 13a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v6a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -6`,key:`svg-0`}],[`path`,{d:`M15 9a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v10a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -10`,key:`svg-1`}],[`path`,{d:`M9 5a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v14a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -14`,key:`svg-2`}],[`path`,{d:`M4 20h14`,key:`svg-3`}]]),S=d(`outline`,`chevron-left`,`ChevronLeft`,[[`path`,{d:`M15 6l-6 6l6 6`,key:`svg-0`}]]),C=d(`outline`,`chevron-up`,`ChevronUp`,[[`path`,{d:`M6 15l6 -6l6 6`,key:`svg-0`}]]),w=d(`outline`,`clock`,`Clock`,[[`path`,{d:`M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0`,key:`svg-0`}],[`path`,{d:`M12 7v5l3 3`,key:`svg-1`}]]),T=d(`outline`,`command`,`Command`,[[`path`,{d:`M7 9a2 2 0 1 1 2 -2v10a2 2 0 1 1 -2 -2h10a2 2 0 1 1 -2 2v-10a2 2 0 1 1 2 2h-10`,key:`svg-0`}]]),E=d(`outline`,`copy`,`Copy`,[[`path`,{d:`M7 9.667a2.667 2.667 0 0 1 2.667 -2.667h8.666a2.667 2.667 0 0 1 2.667 2.667v8.666a2.667 2.667 0 0 1 -2.667 2.667h-8.666a2.667 2.667 0 0 1 -2.667 -2.667l0 -8.666`,key:`svg-0`}],[`path`,{d:`M4.012 16.737a2.005 2.005 0 0 1 -1.012 -1.737v-10c0 -1.1 .9 -2 2 -2h10c.75 0 1.158 .385 1.5 1`,key:`svg-1`}]]),D=d(`outline`,`cube`,`Cube`,[[`path`,{d:`M21 16.008v-8.018a1.98 1.98 0 0 0 -1 -1.717l-7 -4.008a2.016 2.016 0 0 0 -2 0l-7 4.008c-.619 .355 -1 1.01 -1 1.718v8.018c0 .709 .381 1.363 1 1.717l7 4.008a2.016 2.016 0 0 0 2 0l7 -4.008c.619 -.355 1 -1.01 1 -1.718`,key:`svg-0`}],[`path`,{d:`M12 22v-10`,key:`svg-1`}],[`path`,{d:`M12 12l8.73 -5.04`,key:`svg-2`}],[`path`,{d:`M3.27 6.96l8.73 5.04`,key:`svg-3`}]]),O=d(`outline`,`download`,`Download`,[[`path`,{d:`M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2 -2v-2`,key:`svg-0`}],[`path`,{d:`M7 11l5 5l5 -5`,key:`svg-1`}],[`path`,{d:`M12 4l0 12`,key:`svg-2`}]]),k=d(`outline`,`heart`,`Heart`,[[`path`,{d:`M19.5 12.572l-7.5 7.428l-7.5 -7.428a5 5 0 1 1 7.5 -6.566a5 5 0 1 1 7.5 6.572`,key:`svg-0`}]]),A=d(`outline`,`layout-grid`,`LayoutGrid`,[[`path`,{d:`M4 5a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-0`}],[`path`,{d:`M14 5a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-1`}],[`path`,{d:`M4 15a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-2`}],[`path`,{d:`M14 15a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v4a1 1 0 0 1 -1 1h-4a1 1 0 0 1 -1 -1l0 -4`,key:`svg-3`}]]),j=d(`outline`,`link`,`Link`,[[`path`,{d:`M9 15l6 -6`,key:`svg-0`}],[`path`,{d:`M11 6l.463 -.536a5 5 0 0 1 7.071 7.072l-.534 .464`,key:`svg-1`}],[`path`,{d:`M13 18l-.397 .534a5.068 5.068 0 0 1 -7.127 0a4.972 4.972 0 0 1 0 -7.071l.524 -.463`,key:`svg-2`}]]),M=d(`outline`,`list`,`List`,[[`path`,{d:`M9 6l11 0`,key:`svg-0`}],[`path`,{d:`M9 12l11 0`,key:`svg-1`}],[`path`,{d:`M9 18l11 0`,key:`svg-2`}],[`path`,{d:`M5 6l0 .01`,key:`svg-3`}],[`path`,{d:`M5 12l0 .01`,key:`svg-4`}],[`path`,{d:`M5 18l0 .01`,key:`svg-5`}]]),N=d(`outline`,`maximize`,`Maximize`,[[`path`,{d:`M4 8v-2a2 2 0 0 1 2 -2h2`,key:`svg-0`}],[`path`,{d:`M4 16v2a2 2 0 0 0 2 2h2`,key:`svg-1`}],[`path`,{d:`M16 4h2a2 2 0 0 1 2 2v2`,key:`svg-2`}],[`path`,{d:`M16 20h2a2 2 0 0 0 2 -2v-2`,key:`svg-3`}]]),P=d(`outline`,`minimize`,`Minimize`,[[`path`,{d:`M15 19v-2a2 2 0 0 1 2 -2h2`,key:`svg-0`}],[`path`,{d:`M15 5v2a2 2 0 0 0 2 2h2`,key:`svg-1`}],[`path`,{d:`M5 15h2a2 2 0 0 1 2 2v2`,key:`svg-2`}],[`path`,{d:`M5 9h2a2 2 0 0 0 2 -2v-2`,key:`svg-3`}]]),F=d(`outline`,`moon`,`Moon`,[[`path`,{d:`M12 3c.132 0 .263 0 .393 0a7.5 7.5 0 0 0 7.92 12.446a9 9 0 1 1 -8.313 -12.454l0 .008`,key:`svg-0`}]]),I=d(`outline`,`palette`,`Palette`,[[`path`,{d:`M12 21a9 9 0 0 1 0 -18c4.97 0 9 3.582 9 8c0 1.06 -.474 2.078 -1.318 2.828c-.844 .75 -1.989 1.172 -3.182 1.172h-2.5a2 2 0 0 0 -1 3.75a1.3 1.3 0 0 1 -1 2.25`,key:`svg-0`}],[`path`,{d:`M7.5 10.5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0`,key:`svg-1`}],[`path`,{d:`M11.5 7.5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0`,key:`svg-2`}],[`path`,{d:`M15.5 10.5a1 1 0 1 0 2 0a1 1 0 1 0 -2 0`,key:`svg-3`}]]),L=d(`outline`,`player-pause`,`PlayerPause`,[[`path`,{d:`M6 6a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v12a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1l0 -12`,key:`svg-0`}],[`path`,{d:`M14 6a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1v12a1 1 0 0 1 -1 1h-2a1 1 0 0 1 -1 -1l0 -12`,key:`svg-1`}]]),R=d(`outline`,`player-play`,`PlayerPlay`,[[`path`,{d:`M7 4v16l13 -8l-13 -8`,key:`svg-0`}]]),z=d(`outline`,`plus`,`Plus`,[[`path`,{d:`M12 5l0 14`,key:`svg-0`}],[`path`,{d:`M5 12l14 0`,key:`svg-1`}]]),B=d(`outline`,`refresh`,`Refresh`,[[`path`,{d:`M20 11a8.1 8.1 0 0 0 -15.5 -2m-.5 -4v4h4`,key:`svg-0`}],[`path`,{d:`M4 13a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4`,key:`svg-1`}]]),V=d(`outline`,`stack-2`,`Stack2`,[[`path`,{d:`M12 4l-8 4l8 4l8 -4l-8 -4`,key:`svg-0`}],[`path`,{d:`M4 12l8 4l8 -4`,key:`svg-1`}],[`path`,{d:`M4 16l8 4l8 -4`,key:`svg-2`}]]),H=d(`outline`,`sun`,`Sun`,[[`path`,{d:`M8 12a4 4 0 1 0 8 0a4 4 0 1 0 -8 0`,key:`svg-0`}],[`path`,{d:`M3 12h1m8 -9v1m8 8h1m-9 8v1m-6.4 -15.4l.7 .7m12.1 -.7l-.7 .7m0 11.4l.7 .7m-12.1 -.7l-.7 .7`,key:`svg-1`}]]),U=d(`outline`,`trash`,`Trash`,[[`path`,{d:`M4 7l16 0`,key:`svg-0`}],[`path`,{d:`M10 11l0 6`,key:`svg-1`}],[`path`,{d:`M14 11l0 6`,key:`svg-2`}],[`path`,{d:`M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2 -2l1 -12`,key:`svg-3`}],[`path`,{d:`M9 7v-3a1 1 0 0 1 1 -1h4a1 1 0 0 1 1 1v3`,key:`svg-4`}]]),W=d(`outline`,`typography`,`Typography`,[[`path`,{d:`M4 20l3 0`,key:`svg-0`}],[`path`,{d:`M14 20l7 0`,key:`svg-1`}],[`path`,{d:`M6.9 15l6.9 0`,key:`svg-2`}],[`path`,{d:`M10.2 6.3l5.8 13.7`,key:`svg-3`}],[`path`,{d:`M5 20l6 -16l2 0l7 16`,key:`svg-4`}]]),G=d(`outline`,`world`,`World`,[[`path`,{d:`M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0`,key:`svg-0`}],[`path`,{d:`M3.6 9h16.8`,key:`svg-1`}],[`path`,{d:`M3.6 15h16.8`,key:`svg-2`}],[`path`,{d:`M11.5 3a17 17 0 0 0 0 18`,key:`svg-3`}],[`path`,{d:`M12.5 3a17 17 0 0 1 0 18`,key:`svg-4`}]]),K=d(`filled`,`bell-filled`,`BellFilled`,[[`path`,{d:`M14.235 19c.865 0 1.322 1.024 .745 1.668a3.992 3.992 0 0 1 -2.98 1.332a3.992 3.992 0 0 1 -2.98 -1.332c-.552 -.616 -.158 -1.579 .634 -1.661l.11 -.006h4.471z`,key:`svg-0`}],[`path`,{d:`M12 2c1.358 0 2.506 .903 2.875 2.141l.046 .171l.008 .043a8.013 8.013 0 0 1 4.024 6.069l.028 .287l.019 .289v2.931l.021 .136a3 3 0 0 0 1.143 1.847l.167 .117l.162 .099c.86 .487 .56 1.766 -.377 1.864l-.116 .006h-16c-1.028 0 -1.387 -1.364 -.493 -1.87a3 3 0 0 0 1.472 -2.063l.021 -.143l.001 -2.97a8 8 0 0 1 3.821 -6.454l.248 -.146l.01 -.043a3.003 3.003 0 0 1 2.562 -2.29l.182 -.017l.176 -.004z`,key:`svg-1`}]]),q=d(`filled`,`heart-filled`,`HeartFilled`,[[`path`,{d:`M6.979 3.074a6 6 0 0 1 4.988 1.425l.037 .033l.034 -.03a6 6 0 0 1 4.733 -1.44l.246 .036a6 6 0 0 1 3.364 10.008l-.18 .185l-.048 .041l-7.45 7.379a1 1 0 0 1 -1.313 .082l-.094 -.082l-7.493 -7.422a6 6 0 0 1 3.176 -10.215z`,key:`svg-0`}]]),J={"alert-circle":y,"bell-filled":K,check:u,"chevron-down":e,"chevron-left":S,"chevron-right":p,"chevron-up":C,clock:w,close:f,command:T,copy:E,cube:D,download:O,eye:c,folder:i,globe:G,grid:A,heart:k,"heart-filled":q,info:r,layers:V,link:j,list:M,minimize:P,moon:F,package:t,palette:I,pause:L,play:R,plus:z,refresh:B,resize:N,search:s,settings:o,sliders:v,"sort-asc":n,"sort-desc":l,sparkles:a,stats:x,sun:H,text:W,trash:U,zap:b},Y=m(),X=new Set;function Z({name:e,size:t=14,color:n,style:r,className:i}){let a=J[e];return a?(0,Y.jsx)(a,{"aria-hidden":!0,size:t,stroke:1.75,color:n??`currentColor`,...X.has(e)?{fill:`currentColor`}:null,className:i,style:{flex:`none`,...r}}):(0,Y.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,width:t,height:t,flex:`none`,...r}})}export{h as n,_ as r,Z as t}; \ No newline at end of file diff --git a/public/assets/js/inertia-app-IconAsset-BxTI0Avw.js b/public/assets/js/inertia-app-IconAsset-D5LQFvGu.js similarity index 98% rename from public/assets/js/inertia-app-IconAsset-BxTI0Avw.js rename to public/assets/js/inertia-app-IconAsset-D5LQFvGu.js index 9c3dbff..80362c5 100644 --- a/public/assets/js/inertia-app-IconAsset-BxTI0Avw.js +++ b/public/assets/js/inertia-app-IconAsset-D5LQFvGu.js @@ -1 +1 @@ -import{i as e,n as t,t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{Ct as r,K as i,St as a,X as o,at as s,q as c,st as l}from"./inertia-app-chromeIcons-B0Qjpt7t.js";import{n as u,r as d,s as f,t as p}from"./inertia-app-TreatmentEngine-DjfA1xMT.js";import{r as m}from"./inertia-app-Glyph-Sqogbcp0.js";function h(e){return e?/(?:fill|stroke|stop-color)\s*=\s*"(?!(?:none|currentColor|transparent)\b)#?[0-9a-zA-Z(),.%\s]+"/.test(e):!1}function g(e){return{id:e.id,package:e.package,name:e.name,category:e.category,sub:e.sub,variant:e.variant??`outline`,kind:e.kind??`icon`,svgContent:e.svg_content??null,svgUrl:e.svg_url??null,viewBox:e.viewbox??`0 0 24 24`,bladeClean:e.blade_clean??``,bladeGeneric:e.blade_generic??``,helper:e.helper??``,...e.icon_path||e.path?{path:e.icon_path||e.path}:{},...e.snippets?{snippets:e.snippets}:{},tags:e.tags??[],keywords:e.keywords??[],ownColor:h(e.svg_content)}}var _=e(t(),1),v=Symbol(`ichava.themeVariants`),y=e=>typeof e==`string`&&e!==``?e:null;function b(e,t){let n=t.theme_variants;if(!n||typeof n!=`object`||Array.isArray(n))return e;let r={};for(let[e,t]of Object.entries(n)){if(!t||typeof t!=`object`)continue;let n=y(t.svg_url),i=y(t.svg_content);(n||i)&&(r[e]={svgUrl:n,svgContent:i})}return Object.keys(r).length?Object.assign({},e,{[v]:r}):e}function x(e){return e[v]}var S=new WeakMap;function C(e,t){let n=x(e)?.[t];if(!n)return e;let r=S.get(e);r||S.set(e,r=new Map);let i=r.get(t);return i||(i={...e,svgUrl:n.svgUrl,svgContent:n.svgContent},r.set(t,i)),i}function w(e,t,n){return e.total>0?null:n===0?`no_icons`:t.search?.trim()||t.categories?.length||t.subs?.length||t.variants?.length||t.tags?.length||t.keywords?.length||t.kind||t.packages?.length?`no_match`:`no_icons`}var T=class{#e;constructor(e){this.#e=e,this.repo=new f(e)}async listIcons(e){let t=this.repo.page(e);return{...t,emptyReason:w(t,e,this.#e.icons.length)}}async getIcon(e){return this.repo.byId(e)??null}async getSvg(e,t){return e.svgContent?e.svgContent:e.svgUrl?a().request(e.svgUrl,{raw:!0,baseUrl:``,signal:t}):``}async getFilters(){return this.repo.filters()}async getStatistics(){return this.#e.meta}async getTree(){return this.repo.categoryTree({search:``,packages:[],categories:[],variants:[],page:1,perPage:0,sortBy:`name`,sortDirection:`asc`})}async getRelated(e,t=6){return this.repo.related(e,t)}async getVariantCounts(e){return this.repo.variantCounts(e)}async getKindCounts(e){return this.repo.kindCounts(e)}},E=class e{#e;#t=null;#n=null;constructor(e=a().config.baseUrl){this.#e=e}static at(t){return new e(t).withTransport(a().with({baseUrl:t}))}get transport(){return this.#t??a()}static fromApi(t){let n=t.base??a().config.baseUrl;return e.at(n).withEndpoints(t.endpoints)}get endpoints(){return this.#n}withTransport(t){let n=new e(this.#e);return n.#t=t,n.#n=this.#n,n}withEndpoints(e){let t=this.withTransport(this.transport);return t.#t=this.#t,t.#n=Array.isArray(e)?{}:{...e},t}csrf(e){return this.withTransport(this.transport.with({csrf:{strategy:e}}))}timeout(e){return this.withTransport(this.transport.with({timeoutMs:e}))}credentials(e){return this.withTransport(this.transport.with({credentials:e}))}#r(e,t={}){return this.transport.request(e,{...t,baseUrl:this.#e})}#i(e,t,n,i={},a={}){let o=this.#n?.[e];return o?this.transport.request(`${r(o,a)}${n}`,{...i,baseUrl:``}):this.#r(`${t}${n}`,i)}async listIcons(e,t){return M(await this.#i(`icons.list`,`/icons`,F(P(e)),{signal:t}),e)}async getIcon(e,t){let n=await this.#i(`icons.show`,`/icons/${e}`,``,{signal:t},{iconId:e});return n?.data?b(g(n.data),n.data):null}async getSvg(e,t){return this.#i(`icons.svg`,`/icons/${e.id}/svg`,``,{raw:!0,signal:t},{iconId:e.id})}async getFilters(e){let t=await this.#i(`icons.filters`,`/icons/filters`,``,{signal:e}),n=t.data??t;return{packages:(n.packages??[]).map(D),categories:n.categories??[],variants:n.variants??[]}}async getStatistics(e){let t=await this.#i(`icons.statistics`,`/icons/statistics`,``,{signal:e});return t.data??t}async getTree(e){return this.#a(``,e)}async getTreeFor(e,t){return this.#a(F(P(k(e))),t)}async#a(e,t){let n=await this.#i(`icons.tree`,`/icons/tree`,e,{signal:t});return(Array.isArray(n)?n:n.data??[]).map(A)}async getCatalogMeta(e){let t=await this.#i(`icons.filters`,`/icons/filters`,``,{signal:e}),n=t.data??t;return{packages:(n.packages??[]).map(D),variantsByPackage:O(n.variants_by_package)}}async getRelated(e,t=6,n){let{items:r}=await this.listIcons({categories:[e.category],page:1,perPage:t+1},n);return r.filter(t=>t.id!==e.id).slice(0,t)}async getVariantCounts(e,t){let n=await this.getFilters(t);return new Map(n.variants.map(e=>[e.name,e.count]))}async getKindCounts(e,t){let{kind:n,page:r,perPage:i,sortBy:a,sortDirection:o,...s}=e,c=await this.#i(`icons.filters`,`/icons/filters`,F(P(s)),{signal:t}),l=c.data?.kinds??c.kinds??[],u={icon:0,illustration:0};for(let e of l)(e.name===`icon`||e.name===`illustration`)&&(u[e.name]=e.count);return u}};function D(e){let t=e,n=String(t.id??t.name??``);return{id:n,label:t.label??n,...t.description?{description:t.description}:{},count:typeof t.count==`number`?t.count:0,installed:t.installed??!0,loaded:t.loaded??!0,...t.kind===`icon`||t.kind===`illustration`?{kind:t.kind}:{},...t.default===!0?{default:!0}:{}}}function O(e){if(!e||typeof e!=`object`||Array.isArray(e))return{};let t={};for(let[n,r]of Object.entries(e))Array.isArray(r)&&(t[n]=r.filter(e=>!!e&&typeof e==`object`&&typeof e.slug==`string`).map(e=>({slug:String(e.slug),label:typeof e.label==`string`&&e.label?e.label:String(e.slug),description:typeof e.description==`string`?e.description:``,default:e.default===!0})));return t}function k(e){let{categories:t,subs:n,page:r,perPage:i,sortBy:a,sortDirection:o,...s}=e;return s}function A(e){let t=(e.children??[]).map(j);return{pack:e.id,label:e.title??e.name,count:t.length,cats:t}}function j(e){let t=(e.children??[]).map(e=>({slug:e.name,name:e.label??e.name,count:e.icon_count}));return{name:e.name,count:e.icon_count,sub:t.length?t:void 0}}function M(e,t){let n=e??{},r=n.data??n,i;i=Array.isArray(r)?r:r&&typeof r==`object`?Object.entries(r).filter(([e])=>e!==`grouped`&&/^\d+$/.test(e)).map(([,e])=>e):[];let a=n.meta??{},o=N(a.per_page,t.perPage??i.length),s=N(a.total,i.length),c=N(a.current_page,t.page??1),l=N(a.last_page,Math.max(1,Math.ceil(s/Math.max(1,o)))),u=N(a.from,s?(c-1)*o+1:0),d=N(a.to,Math.min(c*o,s)),f=a.empty_reason,p=f===`no_match`||f===`no_icons`?f:null;return{items:i.map(e=>b(g(e),e)),total:s,page:c,perPage:o,lastPage:l,rangeStart:u,rangeEnd:d,emptyReason:p}}function N(e,t){Array.isArray(e)&&(e=e[0]);let n=typeof e==`string`?parseInt(e,10):e;return Number.isFinite(n)?n:t}function P(e){return{search:e.search,packages:e.packages,categories:e.categories,subs:e.subs,variants:e.variants,kind:e.kind,tags:e.tags,keywords:e.keywords,language:e.language,page:e.page,per_page:e.perPage,sort_by:e.sortBy,sort_direction:e.sortDirection}}function F(e){let t=new URLSearchParams;for(let[n,r]of Object.entries(e))r==null||r===``||Array.isArray(r)&&r.length===0||(Array.isArray(r)?r.forEach(e=>t.append(`${n}[]`,String(e))):t.append(n,String(r)));let n=t.toString();return n?`?${n}`:``}var I=(0,_.createContext)(null),L=I.Provider;function R(){return(0,_.useContext)(I)}var z=300;function B(e){return{items:[],total:0,page:1,perPage:e,lastPage:1,rangeStart:0,rangeEnd:0}}var V={packages:[],variantsByPackage:{}},H=[],U=new Map;function W(e){let{categories:t,subs:n,page:r,perPage:i,sortBy:a,sortDirection:o,...s}=e;return JSON.stringify(s)}function G(e,t,n){let r=n.filter(e=>e.installed).map(e=>e.id);if(!r.length)return null;let i=new Set(n.map(e=>e.id)),a=(e,t)=>e.length===t.length&&e.every((e,n)=>e===t[n]),o=a(e,t),s=!e.some(e=>i.has(e));if(!o&&!s)return null;let c=t.filter(e=>i.has(e)),l=c.length?c:r;return a(e,l)?null:l}function K(e,t,n){let[r,i]=(0,_.useState)(()=>B(t.perPage??60)),[a,o]=(0,_.useState)(null),[s,c]=(0,_.useState)([]),[l,u]=(0,_.useState)(new Map),[d,f]=(0,_.useState)(V),[p,m]=(0,_.useState)(!1),[h,g]=(0,_.useState)(null),v=(0,_.useRef)(null),y=(0,_.useRef)(null);(0,_.useEffect)(()=>{if(!e)return;let n=setTimeout(()=>{v.current?.abort();let n=new AbortController;v.current=n,m(!0),e.listIcons(t,n.signal).then(e=>{n.signal.aborted||(i(e),g(null))}).then(()=>e.getKindCounts?e.getKindCounts(t,n.signal):null).then(e=>{n.signal.aborted||e===void 0||o(e)}).catch(e=>{n.signal.aborted||g(e)}).finally(()=>{n.signal.aborted||m(!1)})},z);return()=>{clearTimeout(n),v.current?.abort()}},[e,JSON.stringify(t)]),(0,_.useEffect)(()=>{if(!e)return;let n=new AbortController;return Promise.all([e.getVariantCounts(t,n.signal),e.getCatalogMeta?e.getCatalogMeta(n.signal):V]).then(([e,t])=>{n.signal.aborted||(u(e),f(t))}).catch(e=>{n.signal.aborted||g(e)}),()=>n.abort()},[e]);let b=!!e?.getTreeFor,x=b?W(t):``;(0,_.useEffect)(()=>{if(!e)return;let n=new AbortController,r=()=>(e.getTreeFor?e.getTreeFor(t,n.signal):e.getTree(n.signal)).then(e=>{n.signal.aborted||c(e)}).catch(e=>{n.signal.aborted||g(e)}),i=b&&y.current===e;y.current=e;let a=i?setTimeout(r,z):null;return i||r(),()=>{a&&clearTimeout(a),n.abort()}},[e,x]);let S=(0,_.useMemo)(()=>e?q(s,n):H,[e,s,n]),C=e?d:V;return{page:r,kindCounts:a,tree:S,variantCounts:e?l:U,packages:C.packages,variantsByPackage:C.variantsByPackage,loading:p,error:h}}function q(e,t){if(!t.trim())return e;let n=t.toLowerCase();return e.map(e=>({...e,cats:e.cats.map(e=>{let t=e.name.toLowerCase().includes(n),r=e.sub?.filter(e=>e.name.toLowerCase().includes(n));return t?e:r&&r.length?{...e,sub:r}:null}).filter(e=>e!==null)})).filter(e=>e.cats.length>0)}var J=new WeakSet,Y={};function X(){let e=i(e=>e.catalog),t=i(e=>e.filters),n=i(e=>e.catQ),r=i(e=>e.setPage),a=i(e=>e.config?.features.searchLanguage?s(e.locale):void 0),u=(0,_.useMemo)(()=>({...o(t),...a?{language:a}:{}}),[t,a]),d=(0,_.useMemo)(()=>e?new f(e):null,[e]),p=(0,_.useMemo)(()=>{if(!d||!e)return{items:[],total:0,page:1,perPage:t.perPage,lastPage:1,rangeStart:0,rangeEnd:0,emptyReason:null};let n=d.page(u);return{...n,emptyReason:w(n,u,e.icons.length)}},[d,e,u,t.perPage]),m=(0,_.useMemo)(()=>d?d.kindCounts(u):null,[d,u]),h=(0,_.useMemo)(()=>{if(!d)return[];let e=d.categoryTree(u);if(!n.trim())return e;let t=n.toLowerCase();return e.map(e=>({...e,cats:e.cats.map(e=>{let n=e.name.toLowerCase().includes(t),r=e.sub?.filter(e=>e.name.toLowerCase().includes(t));return n?e:r&&r.length?{...e,sub:r}:null}).filter(e=>e!==null)})).filter(e=>e.cats.length>0)},[d,u,n]),g=(0,_.useMemo)(()=>d?d.variantCounts(u):new Map,[d,u]),v=R(),y=K(e?null:v,u,n),b=e?p:y.page,x=e?h:y.tree,S=e?g:y.variantCounts,C=e?m:y.kindCounts,T=(0,_.useMemo)(()=>e?e.packages:y.packages,[e,y.packages]),E=e?Y:y.variantsByPackage,D=c(),O=i(e=>e.config?.defaults.packages);return(0,_.useEffect)(()=>{if(!T.length||J.has(D))return;J.add(D);let e=G(D.getState().filters.packages,O??l.packages,T);e&&D.getState().selectAllPacks(e)},[T,D,O]),(0,_.useEffect)(()=>{b.total>0&&t.page!==b.page&&r(b.page)},[t.page,b.page,b.total,r]),{repo:d,page:b,tree:x,variantCounts:S,kindCounts:C,packages:T,variantsByPackage:E,catalog:e,client:e?null:v,loading:!e&&y.loading,error:e?null:y.error}}function Z(e){let t=(0,_.useMemo)(()=>d(e),[e]),[n,r]=(0,_.useState)(null);return(0,_.useEffect)(()=>{if(!(t instanceof Promise))return;let n=!0;return t.then(t=>{n&&r({icon:e,parts:t})}),()=>{n=!1}},[t,e]),t instanceof Promise?n?.icon===e?n.parts:null:t}var Q=n(),$=1.5;function ee({icon:e,size:t,color:n,stroke:r,inline:a}){let o=C(e,i(e=>e.theme)),s=o!==e,c=i(e=>e.color),l=i(e=>e.treatment),d=i(e=>e.gridStroke),f=i(e=>e.theme===`dark`&&e.adaptMonochrome)&&!s,p=(n===void 0?c:n)??`currentColor`,h=r??d,g=o.variant===`outline`&&Math.abs(h-$)>.01;if(o.ownColor){let e=o.svgContent||a?(0,Q.jsx)(ne,{icon:o,size:t}):(0,Q.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,...m.toStyle(m.resolve(o,null),t)}});return f?(0,Q.jsx)(te,{icon:o,size:t,color:p,fallback:e}):e}if(a||g)return(0,Q.jsx)(re,{icon:o,size:t,color:p,stroke:h});let _=m.resolve(o,p).url;return(0,Q.jsx)(`span`,{"aria-hidden":!0,style:u(_,t,p,l)})}function te({icon:e,size:t,color:n,fallback:r}){let i=Z(e);return i?.monoBody?(0,Q.jsx)(`svg`,{"aria-hidden":!0,"data-ichava-mono":``,width:t,height:t,viewBox:i.viewBox,className:`inline-block`,style:{color:n},dangerouslySetInnerHTML:{__html:i.monoBody}}):(0,Q.jsx)(Q.Fragment,{children:r})}function ne({icon:e,size:t}){let n=Z(e);return n?(0,Q.jsx)(`svg`,{"aria-hidden":!0,"data-ichava-illustration":e.kind===`illustration`?``:void 0,width:t,height:t,viewBox:n.viewBox,className:`inline-block`,dangerouslySetInnerHTML:{__html:n.body}}):(0,Q.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,width:t,height:t}})}function re({icon:e,size:t,color:n,stroke:r}){let a=i(e=>e.treatment),o=Z(e);return o?(0,Q.jsx)(`svg`,{"aria-hidden":!0,width:t,height:t,viewBox:o.viewBox,fill:`none`,stroke:n,strokeWidth:r,strokeLinecap:`round`,strokeLinejoin:`round`,style:{display:`inline-block`,...p(a)},dangerouslySetInnerHTML:{__html:o.body}}):(0,Q.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,width:t,height:t}})}export{R as a,g as c,L as i,Z as n,E as o,X as r,T as s,ee as t}; \ No newline at end of file +import{i as e,n as t,t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{Ct as r,K as i,St as a,X as o,at as s,q as c,st as l}from"./inertia-app-chromeIcons-CnRqTA89.js";import{n as u,r as d,s as f,t as p}from"./inertia-app-TreatmentEngine-CsS8gV3T.js";import{r as m}from"./inertia-app-Glyph-BTh2WfGX.js";function h(e){return e?/(?:fill|stroke|stop-color)\s*=\s*"(?!(?:none|currentColor|transparent)\b)#?[0-9a-zA-Z(),.%\s]+"/.test(e):!1}function g(e){return{id:e.id,package:e.package,name:e.name,category:e.category,sub:e.sub,variant:e.variant??`outline`,kind:e.kind??`icon`,svgContent:e.svg_content??null,svgUrl:e.svg_url??null,viewBox:e.viewbox??`0 0 24 24`,bladeClean:e.blade_clean??``,bladeGeneric:e.blade_generic??``,helper:e.helper??``,...e.icon_path||e.path?{path:e.icon_path||e.path}:{},...e.snippets?{snippets:e.snippets}:{},tags:e.tags??[],keywords:e.keywords??[],ownColor:h(e.svg_content)}}var _=e(t(),1),v=Symbol(`ichava.themeVariants`),y=e=>typeof e==`string`&&e!==``?e:null;function b(e,t){let n=t.theme_variants;if(!n||typeof n!=`object`||Array.isArray(n))return e;let r={};for(let[e,t]of Object.entries(n)){if(!t||typeof t!=`object`)continue;let n=y(t.svg_url),i=y(t.svg_content);(n||i)&&(r[e]={svgUrl:n,svgContent:i})}return Object.keys(r).length?Object.assign({},e,{[v]:r}):e}function x(e){return e[v]}var S=new WeakMap;function C(e,t){let n=x(e)?.[t];if(!n)return e;let r=S.get(e);r||S.set(e,r=new Map);let i=r.get(t);return i||(i={...e,svgUrl:n.svgUrl,svgContent:n.svgContent},r.set(t,i)),i}function w(e,t,n){return e.total>0?null:n===0?`no_icons`:t.search?.trim()||t.categories?.length||t.subs?.length||t.variants?.length||t.tags?.length||t.keywords?.length||t.kind||t.packages?.length?`no_match`:`no_icons`}var T=class{#e;constructor(e){this.#e=e,this.repo=new f(e)}async listIcons(e){let t=this.repo.page(e);return{...t,emptyReason:w(t,e,this.#e.icons.length)}}async getIcon(e){return this.repo.byId(e)??null}async getSvg(e,t){return e.svgContent?e.svgContent:e.svgUrl?a().request(e.svgUrl,{raw:!0,baseUrl:``,signal:t}):``}async getFilters(){return this.repo.filters()}async getStatistics(){return this.#e.meta}async getTree(){return this.repo.categoryTree({search:``,packages:[],categories:[],variants:[],page:1,perPage:0,sortBy:`name`,sortDirection:`asc`})}async getRelated(e,t=6){return this.repo.related(e,t)}async getVariantCounts(e){return this.repo.variantCounts(e)}async getKindCounts(e){return this.repo.kindCounts(e)}},E=class e{#e;#t=null;#n=null;constructor(e=a().config.baseUrl){this.#e=e}static at(t){return new e(t).withTransport(a().with({baseUrl:t}))}get transport(){return this.#t??a()}static fromApi(t){let n=t.base??a().config.baseUrl;return e.at(n).withEndpoints(t.endpoints)}get endpoints(){return this.#n}withTransport(t){let n=new e(this.#e);return n.#t=t,n.#n=this.#n,n}withEndpoints(e){let t=this.withTransport(this.transport);return t.#t=this.#t,t.#n=Array.isArray(e)?{}:{...e},t}csrf(e){return this.withTransport(this.transport.with({csrf:{strategy:e}}))}timeout(e){return this.withTransport(this.transport.with({timeoutMs:e}))}credentials(e){return this.withTransport(this.transport.with({credentials:e}))}#r(e,t={}){return this.transport.request(e,{...t,baseUrl:this.#e})}#i(e,t,n,i={},a={}){let o=this.#n?.[e];return o?this.transport.request(`${r(o,a)}${n}`,{...i,baseUrl:``}):this.#r(`${t}${n}`,i)}async listIcons(e,t){return M(await this.#i(`icons.list`,`/icons`,F(P(e)),{signal:t}),e)}async getIcon(e,t){let n=await this.#i(`icons.show`,`/icons/${e}`,``,{signal:t},{iconId:e});return n?.data?b(g(n.data),n.data):null}async getSvg(e,t){return this.#i(`icons.svg`,`/icons/${e.id}/svg`,``,{raw:!0,signal:t},{iconId:e.id})}async getFilters(e){let t=await this.#i(`icons.filters`,`/icons/filters`,``,{signal:e}),n=t.data??t;return{packages:(n.packages??[]).map(D),categories:n.categories??[],variants:n.variants??[]}}async getStatistics(e){let t=await this.#i(`icons.statistics`,`/icons/statistics`,``,{signal:e});return t.data??t}async getTree(e){return this.#a(``,e)}async getTreeFor(e,t){return this.#a(F(P(k(e))),t)}async#a(e,t){let n=await this.#i(`icons.tree`,`/icons/tree`,e,{signal:t});return(Array.isArray(n)?n:n.data??[]).map(A)}async getCatalogMeta(e){let t=await this.#i(`icons.filters`,`/icons/filters`,``,{signal:e}),n=t.data??t;return{packages:(n.packages??[]).map(D),variantsByPackage:O(n.variants_by_package)}}async getRelated(e,t=6,n){let{items:r}=await this.listIcons({categories:[e.category],page:1,perPage:t+1},n);return r.filter(t=>t.id!==e.id).slice(0,t)}async getVariantCounts(e,t){let n=await this.getFilters(t);return new Map(n.variants.map(e=>[e.name,e.count]))}async getKindCounts(e,t){let{kind:n,page:r,perPage:i,sortBy:a,sortDirection:o,...s}=e,c=await this.#i(`icons.filters`,`/icons/filters`,F(P(s)),{signal:t}),l=c.data?.kinds??c.kinds??[],u={icon:0,illustration:0};for(let e of l)(e.name===`icon`||e.name===`illustration`)&&(u[e.name]=e.count);return u}};function D(e){let t=e,n=String(t.id??t.name??``);return{id:n,label:t.label??n,...t.description?{description:t.description}:{},count:typeof t.count==`number`?t.count:0,installed:t.installed??!0,loaded:t.loaded??!0,...t.kind===`icon`||t.kind===`illustration`?{kind:t.kind}:{},...t.default===!0?{default:!0}:{}}}function O(e){if(!e||typeof e!=`object`||Array.isArray(e))return{};let t={};for(let[n,r]of Object.entries(e))Array.isArray(r)&&(t[n]=r.filter(e=>!!e&&typeof e==`object`&&typeof e.slug==`string`).map(e=>({slug:String(e.slug),label:typeof e.label==`string`&&e.label?e.label:String(e.slug),description:typeof e.description==`string`?e.description:``,default:e.default===!0})));return t}function k(e){let{categories:t,subs:n,page:r,perPage:i,sortBy:a,sortDirection:o,...s}=e;return s}function A(e){let t=(e.children??[]).map(j);return{pack:e.id,label:e.title??e.name,count:t.length,cats:t}}function j(e){let t=(e.children??[]).map(e=>({slug:e.name,name:e.label??e.name,count:e.icon_count}));return{name:e.name,count:e.icon_count,sub:t.length?t:void 0}}function M(e,t){let n=e??{},r=n.data??n,i;i=Array.isArray(r)?r:r&&typeof r==`object`?Object.entries(r).filter(([e])=>e!==`grouped`&&/^\d+$/.test(e)).map(([,e])=>e):[];let a=n.meta??{},o=N(a.per_page,t.perPage??i.length),s=N(a.total,i.length),c=N(a.current_page,t.page??1),l=N(a.last_page,Math.max(1,Math.ceil(s/Math.max(1,o)))),u=N(a.from,s?(c-1)*o+1:0),d=N(a.to,Math.min(c*o,s)),f=a.empty_reason,p=f===`no_match`||f===`no_icons`?f:null;return{items:i.map(e=>b(g(e),e)),total:s,page:c,perPage:o,lastPage:l,rangeStart:u,rangeEnd:d,emptyReason:p}}function N(e,t){Array.isArray(e)&&(e=e[0]);let n=typeof e==`string`?parseInt(e,10):e;return Number.isFinite(n)?n:t}function P(e){return{search:e.search,packages:e.packages,categories:e.categories,subs:e.subs,variants:e.variants,kind:e.kind,tags:e.tags,keywords:e.keywords,language:e.language,page:e.page,per_page:e.perPage,sort_by:e.sortBy,sort_direction:e.sortDirection}}function F(e){let t=new URLSearchParams;for(let[n,r]of Object.entries(e))r==null||r===``||Array.isArray(r)&&r.length===0||(Array.isArray(r)?r.forEach(e=>t.append(`${n}[]`,String(e))):t.append(n,String(r)));let n=t.toString();return n?`?${n}`:``}var I=(0,_.createContext)(null),L=I.Provider;function R(){return(0,_.useContext)(I)}var z=300;function B(e){return{items:[],total:0,page:1,perPage:e,lastPage:1,rangeStart:0,rangeEnd:0}}var V={packages:[],variantsByPackage:{}},H=[],U=new Map;function W(e){let{categories:t,subs:n,page:r,perPage:i,sortBy:a,sortDirection:o,...s}=e;return JSON.stringify(s)}function G(e,t,n){let r=n.filter(e=>e.installed).map(e=>e.id);if(!r.length)return null;let i=new Set(n.map(e=>e.id)),a=(e,t)=>e.length===t.length&&e.every((e,n)=>e===t[n]),o=a(e,t),s=!e.some(e=>i.has(e));if(!o&&!s)return null;let c=t.filter(e=>i.has(e)),l=c.length?c:r;return a(e,l)?null:l}function K(e,t,n){let[r,i]=(0,_.useState)(()=>B(t.perPage??60)),[a,o]=(0,_.useState)(null),[s,c]=(0,_.useState)([]),[l,u]=(0,_.useState)(new Map),[d,f]=(0,_.useState)(V),[p,m]=(0,_.useState)(!1),[h,g]=(0,_.useState)(null),v=(0,_.useRef)(null),y=(0,_.useRef)(null);(0,_.useEffect)(()=>{if(!e)return;let n=setTimeout(()=>{v.current?.abort();let n=new AbortController;v.current=n,m(!0),e.listIcons(t,n.signal).then(e=>{n.signal.aborted||(i(e),g(null))}).then(()=>e.getKindCounts?e.getKindCounts(t,n.signal):null).then(e=>{n.signal.aborted||e===void 0||o(e)}).catch(e=>{n.signal.aborted||g(e)}).finally(()=>{n.signal.aborted||m(!1)})},z);return()=>{clearTimeout(n),v.current?.abort()}},[e,JSON.stringify(t)]),(0,_.useEffect)(()=>{if(!e)return;let n=new AbortController;return Promise.all([e.getVariantCounts(t,n.signal),e.getCatalogMeta?e.getCatalogMeta(n.signal):V]).then(([e,t])=>{n.signal.aborted||(u(e),f(t))}).catch(e=>{n.signal.aborted||g(e)}),()=>n.abort()},[e]);let b=!!e?.getTreeFor,x=b?W(t):``;(0,_.useEffect)(()=>{if(!e)return;let n=new AbortController,r=()=>(e.getTreeFor?e.getTreeFor(t,n.signal):e.getTree(n.signal)).then(e=>{n.signal.aborted||c(e)}).catch(e=>{n.signal.aborted||g(e)}),i=b&&y.current===e;y.current=e;let a=i?setTimeout(r,z):null;return i||r(),()=>{a&&clearTimeout(a),n.abort()}},[e,x]);let S=(0,_.useMemo)(()=>e?q(s,n):H,[e,s,n]),C=e?d:V;return{page:r,kindCounts:a,tree:S,variantCounts:e?l:U,packages:C.packages,variantsByPackage:C.variantsByPackage,loading:p,error:h}}function q(e,t){if(!t.trim())return e;let n=t.toLowerCase();return e.map(e=>({...e,cats:e.cats.map(e=>{let t=e.name.toLowerCase().includes(n),r=e.sub?.filter(e=>e.name.toLowerCase().includes(n));return t?e:r&&r.length?{...e,sub:r}:null}).filter(e=>e!==null)})).filter(e=>e.cats.length>0)}var J=new WeakSet,Y={};function X(){let e=i(e=>e.catalog),t=i(e=>e.filters),n=i(e=>e.catQ),r=i(e=>e.setPage),a=i(e=>e.config?.features.searchLanguage?s(e.locale):void 0),u=(0,_.useMemo)(()=>({...o(t),...a?{language:a}:{}}),[t,a]),d=(0,_.useMemo)(()=>e?new f(e):null,[e]),p=(0,_.useMemo)(()=>{if(!d||!e)return{items:[],total:0,page:1,perPage:t.perPage,lastPage:1,rangeStart:0,rangeEnd:0,emptyReason:null};let n=d.page(u);return{...n,emptyReason:w(n,u,e.icons.length)}},[d,e,u,t.perPage]),m=(0,_.useMemo)(()=>d?d.kindCounts(u):null,[d,u]),h=(0,_.useMemo)(()=>{if(!d)return[];let e=d.categoryTree(u);if(!n.trim())return e;let t=n.toLowerCase();return e.map(e=>({...e,cats:e.cats.map(e=>{let n=e.name.toLowerCase().includes(t),r=e.sub?.filter(e=>e.name.toLowerCase().includes(t));return n?e:r&&r.length?{...e,sub:r}:null}).filter(e=>e!==null)})).filter(e=>e.cats.length>0)},[d,u,n]),g=(0,_.useMemo)(()=>d?d.variantCounts(u):new Map,[d,u]),v=R(),y=K(e?null:v,u,n),b=e?p:y.page,x=e?h:y.tree,S=e?g:y.variantCounts,C=e?m:y.kindCounts,T=(0,_.useMemo)(()=>e?e.packages:y.packages,[e,y.packages]),E=e?Y:y.variantsByPackage,D=c(),O=i(e=>e.config?.defaults.packages);return(0,_.useEffect)(()=>{if(!T.length||J.has(D))return;J.add(D);let e=G(D.getState().filters.packages,O??l.packages,T);e&&D.getState().selectAllPacks(e)},[T,D,O]),(0,_.useEffect)(()=>{b.total>0&&t.page!==b.page&&r(b.page)},[t.page,b.page,b.total,r]),{repo:d,page:b,tree:x,variantCounts:S,kindCounts:C,packages:T,variantsByPackage:E,catalog:e,client:e?null:v,loading:!e&&y.loading,error:e?null:y.error}}function Z(e){let t=(0,_.useMemo)(()=>d(e),[e]),[n,r]=(0,_.useState)(null);return(0,_.useEffect)(()=>{if(!(t instanceof Promise))return;let n=!0;return t.then(t=>{n&&r({icon:e,parts:t})}),()=>{n=!1}},[t,e]),t instanceof Promise?n?.icon===e?n.parts:null:t}var Q=n(),$=1.5;function ee({icon:e,size:t,color:n,stroke:r,inline:a}){let o=C(e,i(e=>e.theme)),s=o!==e,c=i(e=>e.color),l=i(e=>e.treatment),d=i(e=>e.gridStroke),f=i(e=>e.theme===`dark`&&e.adaptMonochrome)&&!s,p=(n===void 0?c:n)??`currentColor`,h=r??d,g=o.variant===`outline`&&Math.abs(h-$)>.01;if(o.ownColor){let e=o.svgContent||a?(0,Q.jsx)(ne,{icon:o,size:t}):(0,Q.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,...m.toStyle(m.resolve(o,null),t)}});return f?(0,Q.jsx)(te,{icon:o,size:t,color:p,fallback:e}):e}if(a||g)return(0,Q.jsx)(re,{icon:o,size:t,color:p,stroke:h});let _=m.resolve(o,p).url;return(0,Q.jsx)(`span`,{"aria-hidden":!0,style:u(_,t,p,l)})}function te({icon:e,size:t,color:n,fallback:r}){let i=Z(e);return i?.monoBody?(0,Q.jsx)(`svg`,{"aria-hidden":!0,"data-ichava-mono":``,width:t,height:t,viewBox:i.viewBox,className:`inline-block`,style:{color:n},dangerouslySetInnerHTML:{__html:i.monoBody}}):(0,Q.jsx)(Q.Fragment,{children:r})}function ne({icon:e,size:t}){let n=Z(e);return n?(0,Q.jsx)(`svg`,{"aria-hidden":!0,"data-ichava-illustration":e.kind===`illustration`?``:void 0,width:t,height:t,viewBox:n.viewBox,className:`inline-block`,dangerouslySetInnerHTML:{__html:n.body}}):(0,Q.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,width:t,height:t}})}function re({icon:e,size:t,color:n,stroke:r}){let a=i(e=>e.treatment),o=Z(e);return o?(0,Q.jsx)(`svg`,{"aria-hidden":!0,width:t,height:t,viewBox:o.viewBox,fill:`none`,stroke:n,strokeWidth:r,strokeLinecap:`round`,strokeLinejoin:`round`,style:{display:`inline-block`,...p(a)},dangerouslySetInnerHTML:{__html:o.body}}):(0,Q.jsx)(`span`,{"aria-hidden":!0,style:{display:`inline-block`,width:t,height:t}})}export{R as a,g as c,L as i,Z as n,E as o,X as r,T as s,ee as t}; \ No newline at end of file diff --git a/public/assets/js/inertia-app-IconGrid-2j3fPN9L.js b/public/assets/js/inertia-app-IconGrid-DIF0F5og.js similarity index 91% rename from public/assets/js/inertia-app-IconGrid-2j3fPN9L.js rename to public/assets/js/inertia-app-IconGrid-DIF0F5og.js index e07505a..ce9f577 100644 --- a/public/assets/js/inertia-app-IconGrid-2j3fPN9L.js +++ b/public/assets/js/inertia-app-IconGrid-DIF0F5og.js @@ -1 +1 @@ -import{t as e}from"./inertia-app-dist-CZ5bRvM2.js";import{n as t}from"./inertia-app-browserPath-3NAVLTeG.js";import{t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";var r=n();function i({icons:n,showBase:i,emptyHint:a}){return n.length===0?(0,r.jsx)(`p`,{className:`theme-text-muted mt-8 text-sm`,children:a}):(0,r.jsx)(`div`,{className:`mt-6 grid grid-cols-4 gap-3 sm:grid-cols-6 md:grid-cols-8`,children:n.map(n=>(0,r.jsxs)(e,{href:`${i}/${n.id}`,className:`theme-bg-card theme-bg-card-hover rounded-lg border theme-border flex flex-col items-center gap-1 p-3 theme-transition`,children:[(0,r.jsx)(t,{icon:n,size:32}),(0,r.jsx)(`span`,{className:`theme-text-muted w-full truncate text-center text-[11px]`,children:n.name})]},n.id))})}export{i as t}; \ No newline at end of file +import{t as e}from"./inertia-app-dist-CZ5bRvM2.js";import{n as t}from"./inertia-app-browserPath-Dw6nbcHt.js";import{t as n}from"./inertia-app-jsx-runtime-DyZJNswf.js";var r=n();function i({icons:n,showBase:i,emptyHint:a}){return n.length===0?(0,r.jsx)(`p`,{className:`theme-text-muted mt-8 text-sm`,children:a}):(0,r.jsx)(`div`,{className:`mt-6 grid grid-cols-4 gap-3 sm:grid-cols-6 md:grid-cols-8`,children:n.map(n=>(0,r.jsxs)(e,{href:`${i}/${n.id}`,className:`theme-bg-card theme-bg-card-hover rounded-lg border theme-border flex flex-col items-center gap-1 p-3 theme-transition`,children:[(0,r.jsx)(t,{icon:n,size:32}),(0,r.jsx)(`span`,{className:`theme-text-muted w-full truncate text-center text-[11px]`,children:n.name})]},n.id))})}export{i as t}; \ No newline at end of file diff --git a/public/assets/js/inertia-app-IconGridList-BQKHQU2m.js b/public/assets/js/inertia-app-IconGridList-BRf8QUxz.js similarity index 98% rename from public/assets/js/inertia-app-IconGridList-BQKHQU2m.js rename to public/assets/js/inertia-app-IconGridList-BRf8QUxz.js index d8ef003..51ee33d 100644 --- a/public/assets/js/inertia-app-IconGridList-BQKHQU2m.js +++ b/public/assets/js/inertia-app-IconGridList-BRf8QUxz.js @@ -1 +1 @@ -import{An as e,Bt as t,D as n,F as r,G as i,H as a,I as o,J as s,Jt as c,M as l,Mn as u,Mt as d,O as f,P as p,Pt as m,R as h,U as g,Ut as _,V as v,Vt as y,W as b,Zt as ee,at as te,b as x,dt as ne,mt as S,nt as C,q as w,tt as T,w as E,wt as D}from"./inertia-app-cx-DVGP9Hhm.js";import{i as O,r as k}from"./inertia-app-Checkbox-1lRQwU49.js";import{d as A,f as re,n as j,o as M,p as N,s as P,u as F}from"./inertia-app-ListBox-_e7t_Gp2.js";import{i as I,n as L,r as R}from"./inertia-app-useResolvedIcons-CulqlIuG.js";import{i as z,n as B,t as V}from"./inertia-app-jsx-runtime-DyZJNswf.js";import{t as H}from"./inertia-app-Glyph-Sqogbcp0.js";var U=z(B(),1),W=(0,U.createContext)(null),G=(0,U.forwardRef)(function(e,t){return[e,t]=b(e,t,W),U.createElement(y,{content:U.createElement(_,e)},n=>U.createElement(K,{props:e,collection:n,gridListRef:t}))});function K({props:e,collection:t,gridListRef:n}){[e,n]=b(e,n,a);let{shouldUseVirtualFocus:r,filter:c,disallowTypeAhead:l,UNSTABLE_focusOnEntry:u,...p}=e,{dragAndDropHooks:h,keyboardNavigationBehavior:_=`arrow`,layout:v=`stack`,orientation:y=`vertical`}=e,{CollectionRoot:x,isVirtualized:S,layoutDelegate:w,dropTargetDelegate:T}=(0,U.useContext)(o),E=M({...p,collection:t,children:void 0,layoutDelegate:w}),O=P(E,c),k=te({usage:`search`,sensitivity:`base`}),{disabledBehavior:L,disabledKeys:R}=O.selectionManager,{direction:z}=m(),B=(0,U.useMemo)(()=>new ne({collection:O.collection,collator:k,ref:n,disabledKeys:R,disabledBehavior:L,layoutDelegate:w,layout:v,orientation:y,direction:z}),[O.collection,n,v,y,R,L,w,k,z]),{gridProps:V}=I({...p,keyboardDelegate:B,keyboardNavigationBehavior:v===`grid`?`tab`:_,isVirtualized:S,shouldSelectOnPressUp:e.shouldSelectOnPressUp,disallowTypeAhead:l,UNSTABLE_focusOnEntry:u},O,n),H=O.selectionManager,W=!!h?.useDraggableCollectionState,G=!!h?.useDroppableCollectionState;(0,U.useRef)(W),(0,U.useRef)(G),(0,U.useEffect)(()=>{},[W,G]);let K,q,Y,X=!1,Z=null,Q=(0,U.useRef)(null);if(W&&h){K=h.useDraggableCollectionState({collection:O.collection,selectionManager:H,preview:h.renderDragPreview?Q:void 0}),h.useDraggableCollection({},K,n);let e=h.DragPreview;Z=h.renderDragPreview?U.createElement(e,{ref:Q},h.renderDragPreview):null}if(G&&h){q=h.useDroppableCollectionState({collection:O.collection,selectionManager:H});let e=h.dropTargetDelegate||T||new h.ListDropTargetDelegate(t,n,{layout:v,direction:z,orientation:y});Y=h.useDroppableCollection({keyboardDelegate:B,dropTargetDelegate:e},q,n),X=q.isDropTarget({type:`root`})}let{focusProps:ae,isFocused:oe,isFocusVisible:se}=C(),$=O.collection.size===0,ce={isDropTarget:X,orientation:y,isEmpty:$,isFocused:oe,isFocusVisible:se,layout:v,state:O},le=i({...e,children:void 0,defaultClassName:`react-aria-GridList`,values:ce}),ue=null;if($&&e.renderEmptyState){let t=e.renderEmptyState(ce);ue=U.createElement(`div`,{role:`row`,"aria-rowindex":1,style:{display:`contents`}},U.createElement(`div`,{role:`gridcell`,style:{display:`contents`}},t))}let de=d(e,{global:!0});return U.createElement(D,null,U.createElement(s.div,{...ee(de,le,V,ae,Y?.collectionProps,null),ref:n,slot:e.slot||void 0,onScroll:e.onScroll,"data-drop-target":X||void 0,"data-empty":$||void 0,"data-focused":oe||void 0,"data-focus-visible":se||void 0,"data-layout":v,"data-orientation":y},U.createElement(g,{values:[[j,O],[A,{dragAndDropHooks:h,dragState:K,dropState:q}],[N,{render:J}]]},G&&U.createElement(ie,null),U.createElement(f,null,U.createElement(x,{collection:O.collection,scrollRef:n,persistedKeys:re(H,h,q),renderDropIndicator:F(h,q)}))),ue,Z))}var q=t(u,function(e,t,r){let u=(0,U.useContext)(j),{dragAndDropHooks:f,dragState:m,dropState:_}=(0,U.useContext)(A),y=c(t),{isVirtualized:b}=(0,U.useContext)(o),te=m&&!(m.isDisabled||m.selectionManager.isDisabled(r.key)),{rowProps:x,gridCellProps:ne,descriptionProps:E,...D}=R({node:r,shouldSelectOnPressUp:!!m,isVirtualized:b,focusMode:e.focusMode,allowsArrowNavigation:e.allowsArrowNavigation},u,y),{hoverProps:re,isHovered:M}=T({isDisabled:!D.allowsSelection&&!D.hasAction&&!te,onHoverStart:r.props.onHoverStart,onHoverChange:r.props.onHoverChange,onHoverEnd:r.props.onHoverEnd}),{isFocusVisible:N,focusProps:P}=C(),{isFocusVisible:F,focusProps:I}=C({within:!0}),{checkboxProps:z}=L({key:r.key},u),B=u.selectionManager.disabledBehavior===`all`&&D.isDisabled?{isDisabled:!0}:{},V=null;m&&f&&(V=f.useDraggableItem({key:r.key,hasDragButton:!0},m));let H=null,W=(0,U.useRef)(null),{visuallyHiddenProps:G}=S();_&&f&&(H=f.useDropIndicator({target:{type:`item`,key:r.key,dropPosition:`on`}},_,W));let K=m&&m.isDragging(r.key),q=i({...e,id:void 0,children:r.rendered,defaultClassName:`react-aria-GridListItem`,values:{...D,isHovered:M,isFocusVisible:N,isFocusVisibleWithin:F,selectionMode:u.selectionManager.selectionMode,selectionBehavior:u.selectionManager.selectionBehavior,allowsDragging:!!m,isDragging:K,isDropTarget:H?.isDropTarget,id:r.key,state:u}}),J=(0,U.useRef)(null);(0,U.useEffect)(()=>{m&&!J.current&&console.warn(`Draggable items in a GridList must contain a `;case`alpine`:return`
+import{l as e,o as t,r as n}from"./inertia-app-TreatmentEngine-CsS8gV3T.js";import{Ct as r,mt as i}from"./inertia-app-chromeIcons-CnRqTA89.js";async function a(e,t,n,r){if(!(r.snippets.needsSvg?r.snippets.needsSvg(t,n):t===`svg`))return r.snippets.build(t,e,n);let i=await Promise.resolve(r.svgParts(e)),a=r.snippets.svgFromParts(e,i,n);return t===`svg`?a:r.snippets.build(t,e,n,a)}var o=[`svg`,`motion`,`helper`,`blade`,`bladeGeneric`,`livewire`,`alpine`,`vue`,`react`,`svelte`,`webcomponent`,`reactNative`,`angular`,`solid`,`preact`,`astro`,`qwik`,`ember`,`elm`,`api`,`name`],s={svg:`SVG`,motion:`Motion`,helper:`Helper`,blade:`Blade`,bladeGeneric:`Blade (generic)`,livewire:`Livewire`,alpine:`Alpine`,vue:`Vue`,react:`React`,svelte:`Svelte`,webcomponent:`Web Component`,reactNative:`React Native`,angular:`Angular`,solid:`Solid`,preact:`Preact`,astro:`Astro`,qwik:`Qwik`,ember:`Ember`,elm:`Elm`,api:`API`,name:`Name`},c=i.filter(e=>e.copy&&l(e.id)).map(e=>({id:e.id,label:s[e.id]}));function l(e){return o.includes(e)}var u={reactNative:`react-native`,angular:`angular`,solid:`solid`,preact:`preact`,astro:`astro`,qwik:`qwik`,ember:`ember`,elm:`elm`},d={tabler:`outline`,flag:`4x3`,twemoji:`twemoji`,openmoji:`openmoji-color`};function f(e){return e.variant&&e.variant!=="default"?e.variant:e.category&&e.category!==`general`?e.category:``}function p(t){return[e(t),f(t)].filter(Boolean).join(` · `)}var m=new class{#e=new Map;register(e,t){return this.#e.set(e,t),this}supports(e,t){return o.includes(e)||!!t?.templates?.[e]||this.#e.has(e)}needsSvg(e,t){let n=t?.templates?.[e];return n?/\{\{\s*(svg|jsx)\s*\}\}/.test(n):e===`svg`||e===`vue`||e===`react`||e===`svelte`||e===`webcomponent`||this.#e.has(e)}build(e,t,n,r){let i=j(t,e);if(i)return i;let a=this.needsSvg(e,n.config)?this.svg(t,n,r):``,o=v(t,n,a),s=n.config?.templates?.[e];if(s)return y(s,o);let c=this.#e.get(e);if(c)return c({icon:t,options:n,tokens:o});let l=o;switch(e){case`name`:return l.path;case`helper`:return t.helper||(l.class?`{{ ichava('${l.path}')->class('${l.class}') }}`:`{{ ichava('${l.path}') }}`);case`blade`:return t.bladeClean||M(l);case`bladeGeneric`:return t.bladeGeneric||``;case`svg`:return a;case`motion`:return this.motion(t,n);case`livewire`:return`{{-- Needs a public $icon property on the component. --}}\n`;case`alpine`:return`
\n
`;case`vue`:return`\n`;case`react`:return`import type { SVGProps } from 'react';\n\nexport function ${l.componentName}(props: SVGProps) {\n return (\n${z(l.jsx,` `)}\n );\n}`;case`svelte`:return`\n