@uniqbit/mate-core 1.0.0-canary.6 → 1.0.0-canary.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/claude-capability-plugins/companion-mentions/.claude-plugin/plugin.json +1 -1
- package/package.json +6 -3
- package/src/cli/commands/artifact/delivery/submit.ts +6 -4
- package/src/cli/commands/artifact/finish/command.ts +28 -11
- package/src/cli/commands/artifact/pending/command.ts +71 -7
- package/src/cli/commands/cap/tokensave.ts +2 -2
- package/src/cli/commands/companion/update.ts +2 -3
- package/src/cli/commands/doctor.ts +67 -4
- package/src/cli/commands/friction.ts +558 -0
- package/src/cli/commands/install.ts +8 -4
- package/src/cli/commands/plugin/install.ts +82 -35
- package/src/cli/commands/studio/connection.ts +53 -0
- package/src/cli/commands/studio/routes.ts +3 -0
- package/src/cli/commands/studio/selection.ts +10 -1
- package/src/cli/commands/studio/server.ts +31 -0
- package/src/cli/commands/studio/service-host.ts +3 -0
- package/src/cli/commands/studio/services.ts +25 -0
- package/src/cli/commands/triage.ts +172 -0
- package/src/cli/commands/vscode/release-vsix.json +2 -2
- package/src/cli/install-plan.tsx +3 -0
- package/src/cli/main.ts +85 -19
- package/src/cli/plugin-commands.ts +6 -1
- package/src/cli/usage.ts +12 -2
- package/src/create-mate.ts +11 -5
- package/src/distribution.ts +2 -0
- package/src/factory-host.ts +6 -0
- package/src/hooks/validate-artifact-path.ts +64 -14
- package/src/index.ts +1 -0
- package/src/lib/delivery/merge-git.ts +31 -7
- package/src/lib/delivery/overlap.ts +14 -1
- package/src/lib/delivery/repository-access.ts +11 -6
- package/src/lib/delivery/staging/apply-chain.ts +25 -7
- package/src/lib/delivery/staging/linked-merges.ts +175 -0
- package/src/lib/delivery/staging/naming.ts +3 -0
- package/src/lib/delivery/staging/openspec-type.ts +38 -7
- package/src/lib/delivery/staging/pending.ts +153 -11
- package/src/lib/delivery/staging/preflight.ts +239 -0
- package/src/lib/delivery/staging/project.ts +243 -104
- package/src/lib/delivery/staging/replay.ts +5 -3
- package/src/lib/delivery/staging/settle-linked.ts +5 -119
- package/src/lib/delivery/staging/submit.ts +139 -18
- package/src/lib/delivery/submit-change.ts +163 -37
- package/src/lib/friction/describe.ts +42 -0
- package/src/lib/friction/fields.ts +60 -0
- package/src/lib/friction/mark.ts +194 -0
- package/src/lib/friction/view/model.ts +67 -0
- package/src/lib/friction/view/read.ts +145 -0
- package/src/lib/friction/view/select.ts +54 -0
- package/src/lib/openspec-cli.ts +10 -5
- package/src/lib/orchestrator/adapters/claude.ts +5 -4
- package/src/lib/orchestrator/adapters/opencode.ts +2 -0
- package/src/lib/orchestrator/root-context.ts +23 -6
- package/src/lib/package-paths.ts +23 -15
- package/src/lib/session-attribution.ts +3 -7
- package/src/lib/skills-cli.ts +38 -0
- package/src/lib/tool-manifest.ts +73 -0
- package/src/lib/triage/context.ts +312 -0
- package/src/lib/triage/launch.ts +52 -0
- package/src/lib/triage/prepare.ts +112 -0
- package/src/lib/triage/session.ts +126 -0
- package/src/opencode/companion-hooks.ts +53 -5
- package/src/opencode/projected-guidance.ts +2 -0
- package/src/playbooks/companion-guidance.ts +2 -2
- package/src/plugin-api.ts +6 -0
- package/src/runtime/command-arg.ts +15 -0
- package/src/runtime/command-friction.ts +97 -0
- package/src/runtime/companion-guidance.ts +33 -16
- package/src/runtime/friction-fingerprint.ts +35 -0
- package/src/runtime/friction-log.ts +376 -0
- package/src/runtime/friction-recorder.ts +212 -0
- package/src/runtime/friction-retention.ts +1 -0
- package/src/runtime/friction-state.ts +110 -0
- package/src/runtime/friction-switch.ts +26 -0
- package/src/runtime/friction-vocabulary.ts +42 -0
- package/src/runtime/git-tracked.ts +13 -2
- package/src/runtime/projected-guidance.ts +2 -1
- package/src/runtime/secret-values.ts +16 -0
- package/src/runtime/session-id.ts +24 -0
- package/src/runtime/session-prepare-runner.ts +3 -0
- package/src/runtime/workflow/next-handoff-process.ts +2 -1
- package/src/studio.ts +47 -1
- package/src/templates/capabilities/openspec-cap/mate-minimal/schema.yaml +5 -1
- package/src/templates/capabilities/react-doctor/mate-react-doctor/SKILL.md +28 -0
- package/src/templates/mate-skills/agents/mate-apply-change/SKILL.md +42 -4
- package/src/templates/mate-skills/agents/mate-archive-change/SKILL.md +27 -2
- package/src/templates/mate-skills/agents/mate-backfill-spec/SKILL.md +23 -1
- package/src/templates/mate-skills/agents/mate-clarify-intent/SKILL.md +26 -1
- package/src/templates/mate-skills/agents/mate-domain-modeling/SKILL.md +28 -0
- package/src/templates/mate-skills/agents/mate-explore-change/SKILL.md +28 -3
- package/src/templates/mate-skills/agents/mate-grill-me/SKILL.md +28 -0
- package/src/templates/mate-skills/agents/mate-grill-with-docs/SKILL.md +28 -0
- package/src/templates/mate-skills/agents/mate-grilling/SKILL.md +25 -0
- package/src/templates/mate-skills/agents/mate-interview-me/SKILL.md +28 -0
- package/src/templates/mate-skills/agents/mate-propose-change/SKILL.md +28 -3
- package/src/templates/mate-skills/agents/mate-publish-artifact/SKILL.md +28 -6
- package/src/templates/mate-skills/agents/mate-show-me/SKILL.md +27 -2
- package/src/templates/mate-skills/agents/mate-simplify-code/SKILL.md +28 -0
- package/src/templates/mate-skills/agents/mate-submit-change/SKILL.md +24 -2
- package/src/templates/mate-skills/claude/mate-apply-change/SKILL.md +42 -4
- package/src/templates/mate-skills/claude/mate-archive-change/SKILL.md +27 -2
- package/src/templates/mate-skills/claude/mate-backfill-spec/SKILL.md +23 -1
- package/src/templates/mate-skills/claude/mate-clarify-intent/SKILL.md +26 -1
- package/src/templates/mate-skills/claude/mate-domain-modeling/SKILL.md +28 -0
- package/src/templates/mate-skills/claude/mate-explore-change/SKILL.md +28 -3
- package/src/templates/mate-skills/claude/mate-grill-me/SKILL.md +28 -0
- package/src/templates/mate-skills/claude/mate-grill-with-docs/SKILL.md +28 -0
- package/src/templates/mate-skills/claude/mate-grilling/SKILL.md +25 -0
- package/src/templates/mate-skills/claude/mate-interview-me/SKILL.md +28 -0
- package/src/templates/mate-skills/claude/mate-propose-change/SKILL.md +28 -3
- package/src/templates/mate-skills/claude/mate-publish-artifact/SKILL.md +28 -6
- package/src/templates/mate-skills/claude/mate-show-me/SKILL.md +27 -2
- package/src/templates/mate-skills/claude/mate-simplify-code/SKILL.md +28 -0
- package/src/templates/mate-skills/claude/mate-submit-change/SKILL.md +24 -2
- package/src/templates/triage/PLAYBOOK.md +120 -0
- package/src/tools/setup/__snapshots__/runtime-surface-golden.test.ts.snap +108 -108
- package/src/tools/setup/capabilities/graphify.ts +23 -1
- package/src/tools/setup/capabilities/rtk.ts +46 -94
- package/src/tools/setup/capabilities/tokensave.ts +76 -54
- package/src/tools/setup/dynamic-plugins/audiences.ts +28 -14
- package/src/tools/setup/dynamic-plugins/hydrate.ts +32 -14
- package/src/tools/setup/dynamic-plugins/install.ts +2 -0
- package/src/tools/setup/dynamic-plugins/installed.ts +73 -0
- package/src/tools/setup/dynamic-plugins/loader.ts +12 -10
- package/src/tools/setup/dynamic-plugins/local.ts +492 -0
- package/src/tools/setup/dynamic-plugins/paths.ts +34 -6
- package/src/tools/setup/dynamic-plugins/verify.ts +34 -14
- package/src/tools/setup/dynamic-plugins/workspaces.ts +17 -8
- package/src/tools/setup/mate.ts +26 -1
- package/src/tools/setup/plugin.ts +5 -0
- package/src/tools/setup/plugins/gitignore.ts +45 -12
- package/src/tools/setup/service.ts +12 -0
- package/src/tools/setup/utils.ts +10 -1
- package/src/tools/setup.ts +16 -2
- package/studio-dist/client/assets/app-ggXJ_QVh.css +2 -0
- package/studio-dist/client/assets/button-amJ3g5oD.js +1 -0
- package/studio-dist/client/assets/cn-BQPKiwI4.js +1 -0
- package/studio-dist/client/assets/combobox-CJ7aGFid.js +1 -0
- package/studio-dist/client/assets/{companion-view-BVaZNtiI.js → companion-view-C_N237bf.js} +1 -1
- package/studio-dist/client/assets/fields-BAiGkJ5N.js +1 -0
- package/studio-dist/client/assets/friction-DqOU59v7.js +1 -0
- package/studio-dist/client/assets/getting-started-djaQeWlu.js +1 -0
- package/studio-dist/client/assets/getting-started-yp42dj5S.js +1 -0
- package/studio-dist/client/assets/getting-started._topic-C9zVXz_m.js +1 -0
- package/studio-dist/client/assets/getting-started.index-DWbDKICP.js +1 -0
- package/studio-dist/client/assets/graph-BYaD_5Bq.js +2 -0
- package/studio-dist/client/assets/{graph-canvas-DDuzsNSx.js → graph-canvas-ySGKMhmk.js} +1 -1
- package/studio-dist/client/assets/guides-D6T6W_jV.js +1 -0
- package/studio-dist/client/assets/index-Qx7reRPD.js +40 -0
- package/studio-dist/client/assets/markdown-view-jMiaBTSO.js +1 -0
- package/studio-dist/client/assets/panel-C4bf_h2W.js +1 -0
- package/studio-dist/client/assets/plugins._service._view-y6f2FDAB.js +1 -0
- package/studio-dist/client/assets/prepaint-CKsXyJOR.js +27 -0
- package/studio-dist/client/assets/{queries-axYk2u9L.js → queries-Dfp5deWj.js} +1 -1
- package/studio-dist/client/assets/react-BYUSgtBs.js +1 -0
- package/studio-dist/client/assets/reports-JFSwSueq.js +1 -0
- package/studio-dist/client/assets/routes-BdOWSgzK.js +1 -0
- package/studio-dist/client/assets/search-CXosfvYh.js +1 -0
- package/studio-dist/client/assets/select-BHYYWPhK.js +1 -0
- package/studio-dist/client/assets/skills-Bo9FLsBd.js +1 -0
- package/studio-dist/client/assets/{specs-DU1kqcp5.js → specs-BrCOjOch.js} +1 -1
- package/studio-dist/client/assets/specs-view-CdE2rlli.js +1 -0
- package/studio-dist/client/assets/{steps-DhIFuAZy.js → steps-CKUno4lh.js} +1 -1
- package/studio-dist/client/assets/store-C3vJq8Wj.js +1 -0
- package/studio-dist/client/assets/{studio-BR9j15J0.js → studio-0ueISxwP.js} +8 -8
- package/studio-dist/client/assets/{studio-queries-CFP_yTpr.js → studio-queries-BflKt9va.js} +2 -2
- package/studio-dist/client/assets/{usage-CHmwtkoM.js → usage-BLsLy0nN.js} +16 -16
- package/studio-dist/client/assets/useAnchoredPopupScrollLock-DC7f8GOp.js +1 -0
- package/studio-dist/client/assets/useMutation-uJUrejsi.js +1 -0
- package/studio-dist/client/assets/vault-BB1B_OhR.js +1 -0
- package/studio-dist/client/assets/warnings-CqOOGlPD.js +1 -0
- package/studio-dist/client/assets/workflow-BFzmI-06.js +1 -0
- package/studio-dist/server/assets/{__23tanstack-start-server-fn-resolver-DAbZ6fzY.js → __23tanstack-start-server-fn-resolver-gVfW5vIV.js} +30 -14
- package/studio-dist/server/assets/_tanstack-start-manifest_v.js +66 -50
- package/studio-dist/server/assets/{button-BfoNadNR.js → button-D6bvrFmm.js} +226 -3478
- package/studio-dist/server/assets/cn-FXJAM0KO.js +5528 -0
- package/studio-dist/server/assets/combobox-D2MbYV1O.js +484 -0
- package/studio-dist/server/assets/{companion-view-DHUjPpA0.js → companion-view-Mf1ANbMb.js} +2 -2
- package/studio-dist/server/assets/{companions-kBrJZAd6.js → companions-Dr6IpNAb.js} +1 -1
- package/studio-dist/server/assets/{fields-BD_c65T1.js → fields-B4mAPETz.js} +2 -1
- package/studio-dist/server/assets/friction-9a5S1m7U.js +943 -0
- package/studio-dist/server/assets/friction-CWOTjpCV.js +62 -0
- package/studio-dist/server/assets/{getting-started-7P0oyWaM.js → getting-started-RU6tYU2Q.js} +2 -2
- package/studio-dist/server/assets/{getting-started._topic-B1mV0kGz.js → getting-started._topic-C02HGrC6.js} +2 -2
- package/studio-dist/server/assets/{getting-started.index-CeGtvUsm.js → getting-started.index-EzLRosbb.js} +2 -2
- package/studio-dist/server/assets/{graph-BWtmJOH2.js → graph-B11ITte0.js} +1 -1
- package/studio-dist/server/assets/{graph-DSDVEELZ.js → graph-CZ2H9Fzr.js} +8 -8
- package/studio-dist/server/assets/{graph-canvas-CID9Nksc.js → graph-canvas-rP5TT14Z.js} +2 -2
- package/studio-dist/server/assets/{guides-Bm3RbUB-.js → guides-B8HdeK_C.js} +1 -1
- package/studio-dist/server/assets/{guides-BLJenHwQ.js → guides-BGftp4wf.js} +1 -1
- package/studio-dist/server/assets/{guides.server-rHHqRuzV.js → guides.server-DqFQAStf.js} +1 -1
- package/studio-dist/server/assets/{markdown-view-D3v9x-cM.js → markdown-view-CArpV-CS.js} +1 -1
- package/studio-dist/server/assets/{panel-yqOl5GMU.js → panel-DR0iq46J.js} +4 -3
- package/studio-dist/server/assets/{plugins._service._view-DwqJX7s9.js → plugins._service._view-n7u2k5dF.js} +11 -6
- package/studio-dist/server/assets/prepaint-B28ClcPN.js +45 -0
- package/studio-dist/server/assets/{queries-DYmGrhNO.js → queries-D-yVP9i0.js} +1 -1
- package/studio-dist/server/assets/react-CiBZPDs8.js +45 -0
- package/studio-dist/server/assets/{reports-C4Y_Jd-x.js → reports-B9k98oE6.js} +1 -1
- package/studio-dist/server/assets/{reports-7yaPz7aP.js → reports-C2SmTgqh.js} +7 -7
- package/studio-dist/server/assets/{router-Dnoq5auE.js → router-CPt0TAk_.js} +654 -1565
- package/studio-dist/server/assets/{routes-Cok4p3mK.js → routes-CwH8LEy2.js} +8 -8
- package/studio-dist/server/assets/{search-DUK7Jl6f.js → search-b-yQesv3.js} +25 -2
- package/studio-dist/server/assets/{combobox-oxUI6r4V.js → select-C3i6TTX-.js} +35 -514
- package/studio-dist/server/assets/{shell-DNVXedgE.js → shell-CagqZZMZ.js} +4 -3
- package/studio-dist/server/assets/{skills-D8qdXSku.js → skills-C21Mg_8-.js} +8 -8
- package/studio-dist/server/assets/{skills-pKmuAs0F.js → skills-DGg0mWDM.js} +1 -1
- package/studio-dist/server/assets/{specs-DeHYUNFp.js → specs-DetoMiaB.js} +4 -4
- package/studio-dist/server/assets/{specs-view-BGn-5Ik_.js → specs-view-CmbfLDwN.js} +10 -9
- package/studio-dist/server/assets/{steps-CV7Yk7L7.js → steps-D1tYAyWZ.js} +1 -1
- package/studio-dist/server/assets/store-aC-I6f6o.js +93 -0
- package/studio-dist/server/assets/{studio-CB94np48.js → studio-qRvQjRpz.js} +47 -2
- package/studio-dist/server/assets/{studio-queries-BqZGBE70.js → studio-queries-Dqf-3nzj.js} +66 -8
- package/studio-dist/server/assets/{usage-M6Gi6Km7.js → usage-CS4CBK9D.js} +13 -44
- package/studio-dist/server/assets/{usage-j5jR9gX9.js → usage-Cwle9-xY.js} +1 -1
- package/studio-dist/server/assets/useAnchoredPopupScrollLock-BjMNgXv9.js +756 -0
- package/studio-dist/server/assets/useMutation-DpBIuWXt.js +690 -0
- package/studio-dist/server/assets/{vault-lBlvSyD4.js → vault-CEBBRLMb.js} +1 -1
- package/studio-dist/server/assets/{vault-PqVmssmW.js → vault-DVQidlId.js} +6 -6
- package/studio-dist/server/assets/{views-CsFp1i1G.js → views-UgO0Qz_g.js} +2 -2
- package/studio-dist/server/assets/{warnings-BDs34j_m.js → warnings-C7hgXpdk.js} +2 -2
- package/studio-dist/server/assets/{workflow-T0eEldsa.js → workflow-6dZZ1ofw.js} +9 -9
- package/studio-dist/server/server.js +2 -2
- package/tool-manifest.yaml +85 -0
- package/studio-dist/client/assets/app-BFVyWHGo.css +0 -2
- package/studio-dist/client/assets/button-D6LrRkOG.js +0 -1
- package/studio-dist/client/assets/combobox-Dk2MMZWE.js +0 -1
- package/studio-dist/client/assets/fields-D_FYhxQr.js +0 -1
- package/studio-dist/client/assets/getting-started-ByWRg7hC.js +0 -1
- package/studio-dist/client/assets/getting-started-DZSjYC-b.js +0 -1
- package/studio-dist/client/assets/getting-started._topic-C6OyQ4G6.js +0 -1
- package/studio-dist/client/assets/getting-started.index-BkmPHdEm.js +0 -1
- package/studio-dist/client/assets/graph-7jm2XzyL.js +0 -2
- package/studio-dist/client/assets/guides-D9VTjWXP.js +0 -1
- package/studio-dist/client/assets/index-BBmFpG4y.js +0 -40
- package/studio-dist/client/assets/markdown-view-RL5YvfZg.js +0 -1
- package/studio-dist/client/assets/panel-B8F8sOKQ.js +0 -1
- package/studio-dist/client/assets/plugins._service._view-CynxTbMx.js +0 -1
- package/studio-dist/client/assets/react-r45OnJCw.js +0 -27
- package/studio-dist/client/assets/reports-BCAyXh6p.js +0 -1
- package/studio-dist/client/assets/routes-BFPqq89E.js +0 -1
- package/studio-dist/client/assets/skills-DTks_uBx.js +0 -1
- package/studio-dist/client/assets/specs-view-omrd_5P3.js +0 -1
- package/studio-dist/client/assets/store-DJ5cncKA.js +0 -1
- package/studio-dist/client/assets/useBaseQuery-BlC-AZ35.js +0 -1
- package/studio-dist/client/assets/vault-DRg8MScm.js +0 -1
- package/studio-dist/client/assets/warnings-UHFy6HAp.js +0 -1
- package/studio-dist/client/assets/workflow-Bv9vSfVV.js +0 -1
- package/studio-dist/server/assets/react-BO0uMhpm.js +0 -89
- package/studio-dist/server/assets/store-CWDGIp6x.js +0 -280
- package/studio-dist/server/assets/useBaseQuery-Tv_QJt9r.js +0 -2051
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { t as CompanionView } from "./companion-view-
|
|
2
|
-
import {
|
|
1
|
+
import { t as CompanionView } from "./companion-view-Mf1ANbMb.js";
|
|
2
|
+
import { at as useNavigate, f as vaultChildrenQuery, it as Link, m as vaultQuery } from "./studio-queries-Dqf-3nzj.js";
|
|
3
3
|
import { n as require_react, o as __toESM, t as require_jsx_runtime } from "./jsx-runtime-Bt0s0YKS.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { n as PanelSection, r as SidePanel, t as PanelHead } from "./panel-
|
|
7
|
-
import { t as Warnings } from "./warnings-
|
|
8
|
-
import { t as MarkdownView } from "./markdown-view-
|
|
9
|
-
import {
|
|
4
|
+
import { $ as Age, Lr as useQuery, ct as ROW, et as CommandLine, it as PAGE_PAD, lt as StatusWord, nt as EmptyNote, ot as Pills, r as Icon, rt as ListCard, st as Progress, t as Button, tt as Count } from "./button-D6bvrFmm.js";
|
|
5
|
+
import { t as cn } from "./cn-FXJAM0KO.js";
|
|
6
|
+
import { n as PanelSection, r as SidePanel, t as PanelHead } from "./panel-DR0iq46J.js";
|
|
7
|
+
import { t as Warnings } from "./warnings-C7hgXpdk.js";
|
|
8
|
+
import { t as MarkdownView } from "./markdown-view-CArpV-CS.js";
|
|
9
|
+
import { A as changeStep, D as changeGroup, E as activeChanges, O as changePath, T as GROUP_TITLES, j as groupChanges, k as changeProgress, p as Route, w as CHANGE_GROUPS } from "./router-CPt0TAk_.js";
|
|
10
10
|
// src/views/overview/changed-specs.ts
|
|
11
11
|
var import_react = /* @__PURE__ */ __toESM(require_react(), 1);
|
|
12
12
|
/** Each capability once, at the newest shipped change that touched it. */
|
|
@@ -1,5 +1,18 @@
|
|
|
1
|
-
import { C as
|
|
1
|
+
import { C as COMPANION_PARAM, M as requestedMode, N as viewsFor, S as COMPANION_DIGEST_PATTERN, T as LEGACY_ROLE_PARAM, _ as REPORT_KINDS, k as STUDIO_MODE_PARAM, v as STATE_FILTERS, y as SUBJECT_TYPES } from "./studio-qRvQjRpz.js";
|
|
2
|
+
// ../mate-core/src/lib/friction/view/model.ts
|
|
3
|
+
var FRICTION_VIEW_DAYS = [
|
|
4
|
+
7,
|
|
5
|
+
30,
|
|
6
|
+
90
|
|
7
|
+
];
|
|
8
|
+
/** The period a value names, as a number or its text; `undefined` for any other. */
|
|
9
|
+
function frictionViewDays(value) {
|
|
10
|
+
return FRICTION_VIEW_DAYS.find((days) => String(days) === String(value));
|
|
11
|
+
}
|
|
2
12
|
// src/lib/search.ts
|
|
13
|
+
var FRICTION_SORTS = ["repeats", "recent"];
|
|
14
|
+
/** The option `value` names, or `undefined`. */
|
|
15
|
+
var oneOf = (options, value) => options.find((option) => option === value);
|
|
3
16
|
/**
|
|
4
17
|
* Forgiving like the server's own parsing: an unknown value selects nothing rather than failing.
|
|
5
18
|
* Reads the mode with core's precedence, so an unknown `studioMode` never revives a legacy `role`.
|
|
@@ -15,6 +28,16 @@ function validateStudioSearch(raw) {
|
|
|
15
28
|
const days = Number(raw.usageDays);
|
|
16
29
|
if (/^\d+$/.test(String(raw.usageDays)) && Number.isInteger(days) && days >= 1 && days <= 365) search.usageDays = days;
|
|
17
30
|
if (typeof raw.usageRepository === "string" && /^[a-zA-Z0-9_-]{1,64}$/.test(raw.usageRepository)) search.usageRepository = raw.usageRepository;
|
|
31
|
+
const frictionDays = frictionViewDays(raw.frictionDays);
|
|
32
|
+
if (frictionDays) search.frictionDays = frictionDays;
|
|
33
|
+
const frictionState = oneOf(STATE_FILTERS, raw.frictionState);
|
|
34
|
+
if (frictionState) search.frictionState = frictionState;
|
|
35
|
+
const frictionType = oneOf(SUBJECT_TYPES, raw.frictionType);
|
|
36
|
+
if (frictionType) search.frictionType = frictionType;
|
|
37
|
+
const frictionKind = oneOf(REPORT_KINDS, raw.frictionKind);
|
|
38
|
+
if (frictionKind) search.frictionKind = frictionKind;
|
|
39
|
+
const frictionSort = oneOf(FRICTION_SORTS, raw.frictionSort);
|
|
40
|
+
if (frictionSort) search.frictionSort = frictionSort;
|
|
18
41
|
return search;
|
|
19
42
|
}
|
|
20
43
|
/** The router JSON-parses search values, so `?q=2026` arrives as a number; read it as typed. */
|
|
@@ -52,4 +75,4 @@ function canonicalHref(pathname, searchStr, view, studioMode) {
|
|
|
52
75
|
params.set(STUDIO_MODE_PARAM, studioMode);
|
|
53
76
|
return `${pathname}?${params}`;
|
|
54
77
|
}
|
|
55
|
-
export {
|
|
78
|
+
export { FRICTION_VIEW_DAYS as a, validateStudioSearch as i, oneOf as n, frictionViewDays as o, validateSpecsSearch as r, canonicalHref as t };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { n as require_react, o as __toESM, t as require_jsx_runtime } from "./jsx-runtime-Bt0s0YKS.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
2
|
+
import { t as cn } from "./cn-FXJAM0KO.js";
|
|
3
|
+
import { $n as windowResize, Ar as NOOP, Bn as imperativeAction, Dn as jsdom, Dr as mergeProps, Dt as isElementVisible, Er as useRenderElement, Fn as cancelOpen, G as useValueAsRef, H as visuallyHiddenInput, Ir as useControlled, L as DROPDOWN_COLLISION_AVOIDANCE, M as FloatingPortal, Mr as useMergedRefs, Nn as isElementDisabled, Nr as useRefWithInit, Or as EMPTY_ARRAY, Pn as CompositeList, Qt as stopEvent, S as useOpenChangeComplete, T as useDismiss, Tn as contains, V as visuallyHidden, W as useAnimationFrame, Wn as itemPress, Xt as isVirtualClick, Y as useTimeout, a as ReactStore, ar as formatErrorMessage, cn as popupStateMapping, dn as triggerOpenStateMapping, er as createChangeEventDetails, f as attachPreventUnmountOnClose, gr as getWindow, ht as COMPOSITE_KEYS, ir as ownerDocument, kn as webkit, kr as EMPTY_OBJECT, kt as isListIndexDisabled, l as FOCUSABLE_POPUP_PROPS, mt as useDirection, nr as useCompositeListItem, or as useIsoLayoutEffect, pt as useToolbarRootContext, q as addEventListener, qn as none, qt as rectToClientRect, r as Icon, rr as useButton, sr as useStableCallback, tn as getFloatingFocusElement, un as pressableTriggerOpenStateMapping, vn as transitionStatusMapping, w as useTransitionStatus, x as useUnmountAfterClose } from "./button-D6bvrFmm.js";
|
|
4
|
+
import { _ as inertValue, a as InternalBackdrop, c as useLabelableId, d as useRegisterFieldControl, g as fieldValidityMapping, l as useLabelableContext, m as useFieldRootContext, o as useSetFieldFocused, s as useValueChanged, u as useFormContext, v as FloatingFocusManager } from "./fields-B4mAPETz.js";
|
|
5
|
+
import { S as useClick, _ as resolveSelectedIndex, a as hasNullItemLabel, b as useListNavigation, c as resolveSelectedLabel, d as compareItemEquality, f as defaultItemEquality, g as removeItem, h as isSelectedValueDirty, l as stringifyAsLabel, m as findSelectionIndex, n as useOpenInteractionType, p as findItemIndex, s as resolveMultipleLabels, t as useAnchoredPopupScrollLock, u as stringifyAsValue, x as useFloatingRootContext, y as useOnFirstRender } from "./useAnchoredPopupScrollLock-BjMNgXv9.js";
|
|
6
|
+
import { ct as useAnchorPositioning, lt as platform, ot as usePositioner, st as getDisabledMountTransitionStyles } from "./router-CPt0TAk_.js";
|
|
5
7
|
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/floating-ui-react/hooks/useTypeahead.mjs
|
|
6
8
|
var import_react = /* @__PURE__ */ __toESM(require_react(), 1);
|
|
7
9
|
/**
|
|
@@ -106,7 +108,6 @@ function useTypeahead(store, props) {
|
|
|
106
108
|
} : {}, [enabled, sharedProps]);
|
|
107
109
|
}
|
|
108
110
|
// ../../node_modules/.bun/@base-ui+utils@0.5.0+9e489665888c9e4a/node_modules/@base-ui/utils/usePreviousValue.mjs
|
|
109
|
-
var import_jsx_runtime = require_jsx_runtime();
|
|
110
111
|
/**
|
|
111
112
|
* Returns a previous value of its argument.
|
|
112
113
|
* @param value Current value.
|
|
@@ -124,6 +125,7 @@ function usePreviousValue(value) {
|
|
|
124
125
|
return state.previous;
|
|
125
126
|
}
|
|
126
127
|
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/utils/getPseudoElementBounds.mjs
|
|
128
|
+
var import_jsx_runtime = require_jsx_runtime();
|
|
127
129
|
var BOUNDARY_OFFSET = 5;
|
|
128
130
|
/**
|
|
129
131
|
* Determines if a mouse event occurred within the bounds of an element
|
|
@@ -159,457 +161,6 @@ function getPseudoElementBounds(element) {
|
|
|
159
161
|
function resolveAriaLabelledBy(fieldLabelId, localLabelId) {
|
|
160
162
|
return fieldLabelId ?? localLabelId;
|
|
161
163
|
}
|
|
162
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/trigger/ComboboxTrigger.mjs
|
|
163
|
-
/**
|
|
164
|
-
* A button that opens the popup.
|
|
165
|
-
* Renders a `<button>` element.
|
|
166
|
-
*
|
|
167
|
-
* Documentation: [Base UI Combobox](https://base-ui.com/react/components/combobox)
|
|
168
|
-
*/
|
|
169
|
-
var ComboboxTrigger = /*#__PURE__*/ import_react.forwardRef(function ComboboxTrigger(componentProps, forwardedRef) {
|
|
170
|
-
const { render, className, nativeButton = true, disabled: disabledProp = false, id: idProp, style, ...elementProps } = componentProps;
|
|
171
|
-
const { state: fieldState, disabled: fieldDisabled, setTouched, validationMode, validation } = useFieldRootContext();
|
|
172
|
-
const { labelId: fieldLabelId } = useLabelableContext();
|
|
173
|
-
const store = useComboboxRootContext();
|
|
174
|
-
const selectionMode = store.useState("selectionMode");
|
|
175
|
-
const comboboxDisabled = store.useState("disabled");
|
|
176
|
-
const readOnly = store.useState("readOnly");
|
|
177
|
-
const required = store.useState("required");
|
|
178
|
-
const positionerElement = store.useState("positionerElement");
|
|
179
|
-
const listElement = store.useState("listElement");
|
|
180
|
-
const storedPopupId = store.useState("popupId");
|
|
181
|
-
const triggerProps = store.useState("triggerProps");
|
|
182
|
-
const inputInsidePopup = store.useState("inputInsidePopup");
|
|
183
|
-
const rootId = store.useState("id");
|
|
184
|
-
const comboboxLabelId = store.useState("labelId");
|
|
185
|
-
const open = store.useState("open");
|
|
186
|
-
const selectedValue = store.useState("selectedValue");
|
|
187
|
-
const activeIndex = store.useState("activeIndex");
|
|
188
|
-
const selectedIndex = store.useState("selectedIndex");
|
|
189
|
-
const hasSelectedValue = store.useState("hasSelectedValue");
|
|
190
|
-
const floatingRootContext = useComboboxFloatingContext();
|
|
191
|
-
const inputValue = useComboboxInputValueContext();
|
|
192
|
-
const focusTimeout = useTimeout();
|
|
193
|
-
const disabled = fieldDisabled || comboboxDisabled || disabledProp;
|
|
194
|
-
const listEmpty = useListEmpty();
|
|
195
|
-
const popupSide = usePopupSide(store);
|
|
196
|
-
const triggerRef = import_react.useRef(null);
|
|
197
|
-
const setFocused = useSetFieldFocused(disabled, triggerRef);
|
|
198
|
-
useLabelableId({ id: inputInsidePopup ? idProp : void 0 });
|
|
199
|
-
const id = inputInsidePopup ? idProp ?? rootId : idProp;
|
|
200
|
-
const ariaLabelledBy = resolveAriaLabelledBy(fieldLabelId, comboboxLabelId);
|
|
201
|
-
let ariaControls;
|
|
202
|
-
if (open && inputInsidePopup) ariaControls = storedPopupId ?? getComboboxPopupId(rootId);
|
|
203
|
-
else if (open) ariaControls = listElement?.id;
|
|
204
|
-
const currentPointerTypeRef = import_react.useRef("");
|
|
205
|
-
function trackPointerType(event) {
|
|
206
|
-
currentPointerTypeRef.current = event.pointerType;
|
|
207
|
-
}
|
|
208
|
-
const { reference: triggerTypeaheadProps } = useTypeahead(floatingRootContext, {
|
|
209
|
-
enabled: !open && !readOnly && !comboboxDisabled && selectionMode === "single",
|
|
210
|
-
listRef: store.context.labelsRef,
|
|
211
|
-
activeIndex,
|
|
212
|
-
selectedIndex,
|
|
213
|
-
onMatch(index) {
|
|
214
|
-
const nextSelectedValue = store.context.valuesRef.current[index];
|
|
215
|
-
if (nextSelectedValue !== void 0) store.context.setSelectedValue(nextSelectedValue, createChangeEventDetails(none));
|
|
216
|
-
}
|
|
217
|
-
});
|
|
218
|
-
const { reference: triggerClickProps } = useClick(floatingRootContext, {
|
|
219
|
-
enabled: !comboboxDisabled,
|
|
220
|
-
event: "mousedown"
|
|
221
|
-
});
|
|
222
|
-
const { buttonRef, getButtonProps } = useButton({
|
|
223
|
-
native: nativeButton,
|
|
224
|
-
disabled
|
|
225
|
-
});
|
|
226
|
-
const state = {
|
|
227
|
-
...fieldState,
|
|
228
|
-
readOnly,
|
|
229
|
-
open,
|
|
230
|
-
disabled,
|
|
231
|
-
popupSide,
|
|
232
|
-
listEmpty,
|
|
233
|
-
placeholder: selectionMode === "none" ? false : !hasSelectedValue
|
|
234
|
-
};
|
|
235
|
-
const setTriggerElement = useStableCallback((element) => {
|
|
236
|
-
store.set("triggerElement", element);
|
|
237
|
-
});
|
|
238
|
-
return useRenderElement("button", componentProps, {
|
|
239
|
-
ref: [
|
|
240
|
-
forwardedRef,
|
|
241
|
-
buttonRef,
|
|
242
|
-
triggerRef,
|
|
243
|
-
setTriggerElement
|
|
244
|
-
],
|
|
245
|
-
state,
|
|
246
|
-
props: [
|
|
247
|
-
triggerProps,
|
|
248
|
-
triggerClickProps,
|
|
249
|
-
triggerTypeaheadProps,
|
|
250
|
-
{
|
|
251
|
-
id,
|
|
252
|
-
tabIndex: inputInsidePopup ? 0 : -1,
|
|
253
|
-
role: inputInsidePopup ? "combobox" : void 0,
|
|
254
|
-
"aria-expanded": open,
|
|
255
|
-
"aria-haspopup": inputInsidePopup ? "dialog" : "listbox",
|
|
256
|
-
"aria-controls": ariaControls,
|
|
257
|
-
"aria-required": inputInsidePopup ? required || void 0 : void 0,
|
|
258
|
-
"aria-readonly": inputInsidePopup ? readOnly || void 0 : void 0,
|
|
259
|
-
"aria-labelledby": ariaLabelledBy,
|
|
260
|
-
onPointerDown: trackPointerType,
|
|
261
|
-
onPointerEnter: trackPointerType,
|
|
262
|
-
onFocus() {
|
|
263
|
-
setFocused(true);
|
|
264
|
-
if (disabled) return;
|
|
265
|
-
focusTimeout.start(0, store.context.forceMount);
|
|
266
|
-
},
|
|
267
|
-
onBlur(event) {
|
|
268
|
-
if (contains(positionerElement, event.relatedTarget)) return;
|
|
269
|
-
setTouched(true);
|
|
270
|
-
setFocused(false);
|
|
271
|
-
if (validationMode === "onBlur") {
|
|
272
|
-
const valueToValidate = selectionMode === "none" ? inputValue : selectedValue;
|
|
273
|
-
validation.commit(valueToValidate);
|
|
274
|
-
}
|
|
275
|
-
},
|
|
276
|
-
onMouseDown(event) {
|
|
277
|
-
if (disabled) return;
|
|
278
|
-
if (!inputInsidePopup) floatingRootContext.set("domReferenceElement", event.currentTarget);
|
|
279
|
-
store.context.forceMount();
|
|
280
|
-
if (currentPointerTypeRef.current !== "touch") {
|
|
281
|
-
store.context.inputRef.current?.focus();
|
|
282
|
-
if (!inputInsidePopup) event.preventDefault();
|
|
283
|
-
}
|
|
284
|
-
if (open) return;
|
|
285
|
-
const doc = ownerDocument(event.currentTarget);
|
|
286
|
-
function handleMouseUp(mouseEvent) {
|
|
287
|
-
const currentTriggerElement = store.state.triggerElement;
|
|
288
|
-
if (!currentTriggerElement) return;
|
|
289
|
-
const mouseUpTarget = getTarget(mouseEvent);
|
|
290
|
-
const positioner = store.state.positionerElement;
|
|
291
|
-
const list = store.state.listElement;
|
|
292
|
-
if (contains(currentTriggerElement, mouseUpTarget) || contains(positioner, mouseUpTarget) || contains(list, mouseUpTarget)) return;
|
|
293
|
-
if (isMouseWithinBounds(mouseEvent, currentTriggerElement)) return;
|
|
294
|
-
store.context.setOpen(false, createChangeEventDetails(cancelOpen, mouseEvent));
|
|
295
|
-
}
|
|
296
|
-
if (inputInsidePopup) doc.addEventListener("mouseup", handleMouseUp, { once: true });
|
|
297
|
-
},
|
|
298
|
-
onKeyDown(event) {
|
|
299
|
-
if (event.key === "ArrowDown" || event.key === "ArrowUp") {
|
|
300
|
-
stopEvent(event);
|
|
301
|
-
store.context.setOpen(true, createChangeEventDetails(listNavigation, event.nativeEvent));
|
|
302
|
-
store.context.inputRef.current?.focus();
|
|
303
|
-
}
|
|
304
|
-
}
|
|
305
|
-
},
|
|
306
|
-
validation.getValidationProps(disabled, elementProps),
|
|
307
|
-
getButtonProps
|
|
308
|
-
],
|
|
309
|
-
stateAttributesMapping: triggerStateAttributesMapping
|
|
310
|
-
});
|
|
311
|
-
});
|
|
312
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/utils/handleInputPress.mjs
|
|
313
|
-
function handleInputPress(event, store, disabled, shouldIgnoreTarget) {
|
|
314
|
-
if (event.baseUIHandlerPrevented) return;
|
|
315
|
-
const target = getTarget(event.nativeEvent);
|
|
316
|
-
const targetElement = isElement(target) ? target : null;
|
|
317
|
-
if (targetElement !== event.currentTarget && (shouldIgnoreTarget?.(targetElement) || isInteractiveElement(targetElement))) return;
|
|
318
|
-
event.preventDefault();
|
|
319
|
-
if (disabled) return;
|
|
320
|
-
store.context.inputRef.current?.focus();
|
|
321
|
-
if (store.state.openOnInputClick) store.context.setOpen(true, createChangeEventDetails(inputPress, event.nativeEvent));
|
|
322
|
-
}
|
|
323
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/input-group/ComboboxInputGroup.mjs
|
|
324
|
-
/**
|
|
325
|
-
* A wrapper for the input and its associated controls.
|
|
326
|
-
* Renders a `<div>` element.
|
|
327
|
-
*
|
|
328
|
-
* Documentation: [Base UI Combobox](https://base-ui.com/react/components/combobox)
|
|
329
|
-
*/
|
|
330
|
-
var ComboboxInputGroup = /*#__PURE__*/ import_react.forwardRef(function ComboboxInputGroup(componentProps, forwardedRef) {
|
|
331
|
-
const { render, className, style, ...elementProps } = componentProps;
|
|
332
|
-
const { state: fieldState } = useFieldRootContext();
|
|
333
|
-
const store = useComboboxRootContext();
|
|
334
|
-
const open = store.useState("open");
|
|
335
|
-
const comboboxDisabled = store.useState("disabled");
|
|
336
|
-
const readOnly = store.useState("readOnly");
|
|
337
|
-
const hasSelectedValue = store.useState("hasSelectedValue");
|
|
338
|
-
const selectionMode = store.useState("selectionMode");
|
|
339
|
-
const popupSide = usePopupSide(store);
|
|
340
|
-
const disabled = comboboxDisabled;
|
|
341
|
-
const listEmpty = useListEmpty();
|
|
342
|
-
const placeholder = selectionMode === "none" ? false : !hasSelectedValue;
|
|
343
|
-
const state = {
|
|
344
|
-
...fieldState,
|
|
345
|
-
open,
|
|
346
|
-
disabled,
|
|
347
|
-
readOnly,
|
|
348
|
-
popupSide,
|
|
349
|
-
listEmpty,
|
|
350
|
-
placeholder
|
|
351
|
-
};
|
|
352
|
-
const setInputGroupElement = useStableCallback((element) => {
|
|
353
|
-
store.set("inputGroupElement", element);
|
|
354
|
-
});
|
|
355
|
-
return useRenderElement("div", componentProps, {
|
|
356
|
-
ref: [forwardedRef, setInputGroupElement],
|
|
357
|
-
props: [{
|
|
358
|
-
role: "group",
|
|
359
|
-
onMouseDown(event) {
|
|
360
|
-
handleInputPress(event, store, disabled, (target) => {
|
|
361
|
-
return contains(store.context.chipsContainerRef.current, target);
|
|
362
|
-
});
|
|
363
|
-
}
|
|
364
|
-
}, elementProps],
|
|
365
|
-
state,
|
|
366
|
-
stateAttributesMapping: triggerStateAttributesMapping
|
|
367
|
-
});
|
|
368
|
-
});
|
|
369
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/portal/ComboboxPortalContext.mjs
|
|
370
|
-
var ComboboxPortalContext = /*#__PURE__*/ import_react.createContext(void 0);
|
|
371
|
-
function useComboboxPortalContext() {
|
|
372
|
-
const context = import_react.useContext(ComboboxPortalContext);
|
|
373
|
-
if (context === void 0) throw new Error(formatErrorMessage(20));
|
|
374
|
-
return context;
|
|
375
|
-
}
|
|
376
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/portal/ComboboxPortal.mjs
|
|
377
|
-
/**
|
|
378
|
-
* A portal element that moves the popup to a different part of the DOM.
|
|
379
|
-
* By default, the portal element is appended to `<body>`.
|
|
380
|
-
* Renders a `<div>` element.
|
|
381
|
-
*
|
|
382
|
-
* Documentation: [Base UI Combobox](https://base-ui.com/react/components/combobox)
|
|
383
|
-
*/
|
|
384
|
-
var ComboboxPortal = /*#__PURE__*/ import_react.forwardRef(function ComboboxPortal(props, forwardedRef) {
|
|
385
|
-
const { keepMounted = false, ...portalProps } = props;
|
|
386
|
-
const store = useComboboxRootContext();
|
|
387
|
-
const mounted = store.useState("mounted");
|
|
388
|
-
const forceMounted = store.useState("forceMounted");
|
|
389
|
-
if (!(mounted || keepMounted || forceMounted)) return null;
|
|
390
|
-
return /*#__PURE__*/ (0, import_jsx_runtime.jsx)(ComboboxPortalContext.Provider, {
|
|
391
|
-
value: keepMounted,
|
|
392
|
-
children: /*#__PURE__*/ (0, import_jsx_runtime.jsx)(FloatingPortal, {
|
|
393
|
-
ref: forwardedRef,
|
|
394
|
-
...portalProps
|
|
395
|
-
})
|
|
396
|
-
});
|
|
397
|
-
});
|
|
398
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/positioner/ComboboxPositioner.mjs
|
|
399
|
-
/**
|
|
400
|
-
* Positions the popup against the trigger.
|
|
401
|
-
* Renders a `<div>` element.
|
|
402
|
-
*
|
|
403
|
-
* Documentation: [Base UI Combobox](https://base-ui.com/react/components/combobox)
|
|
404
|
-
*/
|
|
405
|
-
var ComboboxPositioner = /*#__PURE__*/ import_react.forwardRef(function ComboboxPositioner(componentProps, forwardedRef) {
|
|
406
|
-
const { render, className, anchor, positionMethod, side, align, sideOffset, alignOffset, collisionBoundary = "clipping-ancestors", collisionPadding, arrowPadding, sticky, disableAnchorTracking = false, collisionAvoidance = DROPDOWN_COLLISION_AVOIDANCE, style: styleProp, ...elementProps } = componentProps;
|
|
407
|
-
const store = useComboboxRootContext();
|
|
408
|
-
const floatingRootContext = useComboboxFloatingContext();
|
|
409
|
-
const keepMounted = useComboboxPortalContext();
|
|
410
|
-
const modal = store.useState("modal");
|
|
411
|
-
const open = store.useState("open");
|
|
412
|
-
const mounted = store.useState("mounted");
|
|
413
|
-
const openMethod = store.useState("openMethod");
|
|
414
|
-
const positionerElement = store.useState("positionerElement");
|
|
415
|
-
const triggerElement = store.useState("triggerElement");
|
|
416
|
-
const inputElement = store.useState("inputElement");
|
|
417
|
-
const inputGroupElement = store.useState("inputGroupElement");
|
|
418
|
-
const inputInsidePopup = store.useState("inputInsidePopup");
|
|
419
|
-
const transitionStatus = store.useState("transitionStatus");
|
|
420
|
-
const empty = useListEmpty();
|
|
421
|
-
const positioning = useAnchorPositioning({
|
|
422
|
-
anchor: anchor ?? (inputInsidePopup ? triggerElement : inputGroupElement ?? inputElement),
|
|
423
|
-
floatingRootContext,
|
|
424
|
-
positionMethod,
|
|
425
|
-
mounted,
|
|
426
|
-
side,
|
|
427
|
-
sideOffset,
|
|
428
|
-
align,
|
|
429
|
-
alignOffset,
|
|
430
|
-
arrowPadding,
|
|
431
|
-
collisionBoundary,
|
|
432
|
-
collisionPadding,
|
|
433
|
-
sticky,
|
|
434
|
-
disableAnchorTracking,
|
|
435
|
-
keepMounted,
|
|
436
|
-
collisionAvoidance,
|
|
437
|
-
lazyFlip: true
|
|
438
|
-
});
|
|
439
|
-
useAnchoredPopupScrollLock(open && modal, openMethod === "touch", positionerElement, triggerElement);
|
|
440
|
-
const state = {
|
|
441
|
-
open,
|
|
442
|
-
side: positioning.side,
|
|
443
|
-
align: positioning.align,
|
|
444
|
-
anchorHidden: positioning.anchorHidden,
|
|
445
|
-
empty
|
|
446
|
-
};
|
|
447
|
-
useIsoLayoutEffect(() => {
|
|
448
|
-
store.set("popupSide", positioning.side);
|
|
449
|
-
}, [store, positioning.side]);
|
|
450
|
-
const setPositionerElement = useStableCallback((element) => {
|
|
451
|
-
store.set("positionerElement", element);
|
|
452
|
-
});
|
|
453
|
-
const element = usePositioner(componentProps, state, {
|
|
454
|
-
styles: positioning.positionerStyles,
|
|
455
|
-
transitionStatus,
|
|
456
|
-
props: elementProps,
|
|
457
|
-
refs: [forwardedRef, setPositionerElement],
|
|
458
|
-
hidden: !mounted,
|
|
459
|
-
inert: !open
|
|
460
|
-
});
|
|
461
|
-
return /*#__PURE__*/ (0, import_jsx_runtime.jsxs)(ComboboxPositionerContext.Provider, {
|
|
462
|
-
value: positioning,
|
|
463
|
-
children: [mounted && modal && /*#__PURE__*/ (0, import_jsx_runtime.jsx)(InternalBackdrop, {
|
|
464
|
-
inert: inertValue(!open),
|
|
465
|
-
cutout: inputGroupElement ?? inputElement ?? triggerElement
|
|
466
|
-
}), element]
|
|
467
|
-
});
|
|
468
|
-
});
|
|
469
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/popup/ComboboxPopup.mjs
|
|
470
|
-
var stateAttributesMapping$3 = {
|
|
471
|
-
...popupStateMapping,
|
|
472
|
-
...transitionStatusMapping
|
|
473
|
-
};
|
|
474
|
-
/**
|
|
475
|
-
* A container for the list.
|
|
476
|
-
* Renders a `<div>` element.
|
|
477
|
-
*
|
|
478
|
-
* Documentation: [Base UI Combobox](https://base-ui.com/react/components/combobox)
|
|
479
|
-
*/
|
|
480
|
-
var ComboboxPopup = /*#__PURE__*/ import_react.forwardRef(function ComboboxPopup(componentProps, forwardedRef) {
|
|
481
|
-
const { render, className, style, initialFocus, finalFocus, ...elementProps } = componentProps;
|
|
482
|
-
const store = useComboboxRootContext();
|
|
483
|
-
const positioning = useComboboxPositionerContext();
|
|
484
|
-
const floatingRootContext = useComboboxFloatingContext();
|
|
485
|
-
const mounted = store.useState("mounted");
|
|
486
|
-
const open = store.useState("open");
|
|
487
|
-
const openMethod = store.useState("openMethod");
|
|
488
|
-
const popupProps = store.useState("popupProps");
|
|
489
|
-
const transitionStatus = store.useState("transitionStatus");
|
|
490
|
-
const inputInsidePopup = store.useState("inputInsidePopup");
|
|
491
|
-
const inputElement = store.useState("inputElement");
|
|
492
|
-
const modal = store.useState("modal");
|
|
493
|
-
const rootId = store.useState("id");
|
|
494
|
-
const empty = useListEmpty();
|
|
495
|
-
const popupId = elementProps.id ?? (inputInsidePopup ? getComboboxPopupId(rootId) : void 0);
|
|
496
|
-
useIsoLayoutEffect(() => {
|
|
497
|
-
store.set("popupId", store.context.popupRef.current?.id || popupId);
|
|
498
|
-
return () => {
|
|
499
|
-
store.set("popupId", void 0);
|
|
500
|
-
};
|
|
501
|
-
}, [store, popupId]);
|
|
502
|
-
useOpenChangeComplete({
|
|
503
|
-
open,
|
|
504
|
-
ref: store.context.popupRef,
|
|
505
|
-
onComplete() {
|
|
506
|
-
if (open) store.context.onOpenChangeComplete(true);
|
|
507
|
-
}
|
|
508
|
-
});
|
|
509
|
-
const state = {
|
|
510
|
-
open,
|
|
511
|
-
side: positioning.side,
|
|
512
|
-
align: positioning.align,
|
|
513
|
-
anchorHidden: positioning.anchorHidden,
|
|
514
|
-
transitionStatus,
|
|
515
|
-
empty
|
|
516
|
-
};
|
|
517
|
-
const element = useRenderElement("div", componentProps, {
|
|
518
|
-
state,
|
|
519
|
-
ref: [forwardedRef, store.context.popupRef],
|
|
520
|
-
props: [
|
|
521
|
-
popupProps,
|
|
522
|
-
{
|
|
523
|
-
id: popupId,
|
|
524
|
-
role: inputInsidePopup ? "dialog" : "presentation",
|
|
525
|
-
onFocus(event) {
|
|
526
|
-
const target = getTarget(event.nativeEvent);
|
|
527
|
-
if (openMethod !== "touch" && (contains(store.state.listElement, target) || target === event.currentTarget)) store.context.inputRef.current?.focus();
|
|
528
|
-
}
|
|
529
|
-
},
|
|
530
|
-
getDisabledMountTransitionStyles(transitionStatus),
|
|
531
|
-
elementProps
|
|
532
|
-
],
|
|
533
|
-
stateAttributesMapping: stateAttributesMapping$3
|
|
534
|
-
});
|
|
535
|
-
const resolvedInitialFocus = initialFocus === void 0 ? inputInsidePopup ? (interactionType) => interactionType === "touch" ? store.context.popupRef.current : inputElement : false : initialFocus;
|
|
536
|
-
let resolvedFinalFocus;
|
|
537
|
-
if (finalFocus != null) resolvedFinalFocus = finalFocus;
|
|
538
|
-
else resolvedFinalFocus = inputInsidePopup ? void 0 : false;
|
|
539
|
-
const focusManagerModal = !inputInsidePopup || modal;
|
|
540
|
-
return /*#__PURE__*/ (0, import_jsx_runtime.jsx)(FloatingFocusManager, {
|
|
541
|
-
context: floatingRootContext,
|
|
542
|
-
disabled: !mounted,
|
|
543
|
-
modal: focusManagerModal,
|
|
544
|
-
openInteractionType: openMethod,
|
|
545
|
-
initialFocus: resolvedInitialFocus,
|
|
546
|
-
returnFocus: resolvedFinalFocus,
|
|
547
|
-
getInsideElements: () => [store.context.startDismissRef.current, store.context.endDismissRef.current],
|
|
548
|
-
children: /*#__PURE__*/ (0, import_jsx_runtime.jsxs)(import_react.Fragment, { children: [element, focusManagerModal && /*#__PURE__*/ (0, import_jsx_runtime.jsx)(ComboboxInternalDismissButton, { ref: store.context.endDismissRef })] })
|
|
549
|
-
});
|
|
550
|
-
});
|
|
551
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/root/ComboboxRoot.mjs
|
|
552
|
-
/**
|
|
553
|
-
* Groups all parts of the combobox.
|
|
554
|
-
* Doesn't render its own HTML element.
|
|
555
|
-
*
|
|
556
|
-
* Documentation: [Base UI Combobox](https://base-ui.com/react/components/combobox)
|
|
557
|
-
*/
|
|
558
|
-
function ComboboxRoot(props) {
|
|
559
|
-
const { multiple = false, defaultValue, value, onValueChange, autoComplete, ...other } = props;
|
|
560
|
-
return /*#__PURE__*/ (0, import_jsx_runtime.jsx)(AriaCombobox, {
|
|
561
|
-
...other,
|
|
562
|
-
selectionMode: multiple ? "multiple" : "single",
|
|
563
|
-
selectedValue: value,
|
|
564
|
-
defaultSelectedValue: defaultValue,
|
|
565
|
-
onSelectedValueChange: onValueChange,
|
|
566
|
-
formAutoComplete: autoComplete
|
|
567
|
-
});
|
|
568
|
-
}
|
|
569
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/utils/ItemIndicator.mjs
|
|
570
|
-
var ItemIndicator = /*#__PURE__*/ import_react.memo(/*#__PURE__*/ import_react.forwardRef(function ItemIndicator(componentProps, forwardedRef) {
|
|
571
|
-
const { render, className, style, keepMounted, selected, ...elementProps } = componentProps;
|
|
572
|
-
const indicatorRef = import_react.useRef(null);
|
|
573
|
-
const { transitionStatus, setMounted } = useTransitionStatus(selected);
|
|
574
|
-
const element = useRenderElement("span", componentProps, {
|
|
575
|
-
ref: [forwardedRef, indicatorRef],
|
|
576
|
-
state: {
|
|
577
|
-
selected,
|
|
578
|
-
transitionStatus
|
|
579
|
-
},
|
|
580
|
-
props: [{
|
|
581
|
-
"aria-hidden": true,
|
|
582
|
-
children: "✔️"
|
|
583
|
-
}, elementProps],
|
|
584
|
-
stateAttributesMapping: transitionStatusMapping
|
|
585
|
-
});
|
|
586
|
-
useOpenChangeComplete({
|
|
587
|
-
batch: true,
|
|
588
|
-
enabled: !selected,
|
|
589
|
-
open: selected,
|
|
590
|
-
ref: indicatorRef,
|
|
591
|
-
onComplete() {
|
|
592
|
-
if (!selected) setMounted(false);
|
|
593
|
-
}
|
|
594
|
-
});
|
|
595
|
-
return element;
|
|
596
|
-
}));
|
|
597
|
-
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/combobox/item-indicator/ComboboxItemIndicator.mjs
|
|
598
|
-
/**
|
|
599
|
-
* Indicates whether the item is selected.
|
|
600
|
-
* Renders a `<span>` element.
|
|
601
|
-
*
|
|
602
|
-
* Documentation: [Base UI Combobox](https://base-ui.com/react/components/combobox)
|
|
603
|
-
*/
|
|
604
|
-
var ComboboxItemIndicator = /*#__PURE__*/ import_react.forwardRef(function ComboboxItemIndicator(componentProps, forwardedRef) {
|
|
605
|
-
const { selected } = useComboboxItemContext();
|
|
606
|
-
if (!(componentProps.keepMounted || selected)) return null;
|
|
607
|
-
return /*#__PURE__*/ (0, import_jsx_runtime.jsx)(ItemIndicator, {
|
|
608
|
-
...componentProps,
|
|
609
|
-
selected,
|
|
610
|
-
ref: forwardedRef
|
|
611
|
-
});
|
|
612
|
-
});
|
|
613
164
|
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/select/root/SelectRootContext.mjs
|
|
614
165
|
var SelectRootContext = /*#__PURE__*/ import_react.createContext(void 0);
|
|
615
166
|
var SelectFloatingContext = /*#__PURE__*/ import_react.createContext(void 0);
|
|
@@ -1919,6 +1470,34 @@ var SelectItem$1 = /*#__PURE__*/ import_react.memo(/*#__PURE__*/ import_react.fo
|
|
|
1919
1470
|
children: element
|
|
1920
1471
|
});
|
|
1921
1472
|
}));
|
|
1473
|
+
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/utils/ItemIndicator.mjs
|
|
1474
|
+
var ItemIndicator = /*#__PURE__*/ import_react.memo(/*#__PURE__*/ import_react.forwardRef(function ItemIndicator(componentProps, forwardedRef) {
|
|
1475
|
+
const { render, className, style, keepMounted, selected, ...elementProps } = componentProps;
|
|
1476
|
+
const indicatorRef = import_react.useRef(null);
|
|
1477
|
+
const { transitionStatus, setMounted } = useTransitionStatus(selected);
|
|
1478
|
+
const element = useRenderElement("span", componentProps, {
|
|
1479
|
+
ref: [forwardedRef, indicatorRef],
|
|
1480
|
+
state: {
|
|
1481
|
+
selected,
|
|
1482
|
+
transitionStatus
|
|
1483
|
+
},
|
|
1484
|
+
props: [{
|
|
1485
|
+
"aria-hidden": true,
|
|
1486
|
+
children: "✔️"
|
|
1487
|
+
}, elementProps],
|
|
1488
|
+
stateAttributesMapping: transitionStatusMapping
|
|
1489
|
+
});
|
|
1490
|
+
useOpenChangeComplete({
|
|
1491
|
+
batch: true,
|
|
1492
|
+
enabled: !selected,
|
|
1493
|
+
open: selected,
|
|
1494
|
+
ref: indicatorRef,
|
|
1495
|
+
onComplete() {
|
|
1496
|
+
if (!selected) setMounted(false);
|
|
1497
|
+
}
|
|
1498
|
+
});
|
|
1499
|
+
return element;
|
|
1500
|
+
}));
|
|
1922
1501
|
// ../../node_modules/.bun/@base-ui+react@1.9.0+9e489665888c9e4a/node_modules/@base-ui/react/select/item-indicator/SelectItemIndicator.mjs
|
|
1923
1502
|
/**
|
|
1924
1503
|
* Indicates whether the select item is selected.
|
|
@@ -2028,62 +1607,4 @@ function SelectItem({ className, children, ...props }) {
|
|
|
2028
1607
|
})]
|
|
2029
1608
|
});
|
|
2030
1609
|
}
|
|
2031
|
-
|
|
2032
|
-
var Combobox = ComboboxRoot;
|
|
2033
|
-
/** A typing field framed like the Select trigger, with the same inset chevron. */
|
|
2034
|
-
function ComboboxInput({ className, ...props }) {
|
|
2035
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(ComboboxInputGroup, {
|
|
2036
|
-
"data-slot": "combobox-input-group",
|
|
2037
|
-
className: cn("relative flex items-center", className),
|
|
2038
|
-
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ComboboxInput$1, {
|
|
2039
|
-
"data-slot": "combobox-input",
|
|
2040
|
-
className: cn(TRIGGER, "placeholder:text-muted focus:border-accent"),
|
|
2041
|
-
...props
|
|
2042
|
-
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ComboboxTrigger, {
|
|
2043
|
-
"data-slot": "combobox-trigger",
|
|
2044
|
-
"aria-label": "Show options",
|
|
2045
|
-
className: "absolute inset-y-0 right-0 flex w-9 items-center justify-center outline-none",
|
|
2046
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, {
|
|
2047
|
-
name: "chevron",
|
|
2048
|
-
className: CHEVRON
|
|
2049
|
-
})
|
|
2050
|
-
})]
|
|
2051
|
-
});
|
|
2052
|
-
}
|
|
2053
|
-
function ComboboxContent({ className, ...props }) {
|
|
2054
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ComboboxPortal, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ComboboxPositioner, {
|
|
2055
|
-
sideOffset: 6,
|
|
2056
|
-
className: "z-40",
|
|
2057
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ComboboxPopup, {
|
|
2058
|
-
"data-slot": "combobox-content",
|
|
2059
|
-
className: cn(POPUP, className),
|
|
2060
|
-
...props
|
|
2061
|
-
})
|
|
2062
|
-
}) });
|
|
2063
|
-
}
|
|
2064
|
-
var ComboboxList = ComboboxList$1;
|
|
2065
|
-
function ComboboxEmpty({ className, ...props }) {
|
|
2066
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ComboboxEmpty$1, {
|
|
2067
|
-
"data-slot": "combobox-empty",
|
|
2068
|
-
className: cn("px-2.5 py-1.5 text-sm text-muted empty:hidden", className),
|
|
2069
|
-
...props
|
|
2070
|
-
});
|
|
2071
|
-
}
|
|
2072
|
-
function ComboboxItem({ className, children, ...props }) {
|
|
2073
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(ComboboxItem$1, {
|
|
2074
|
-
"data-slot": "combobox-item",
|
|
2075
|
-
className: cn(ITEM, className),
|
|
2076
|
-
...props,
|
|
2077
|
-
children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
2078
|
-
className: "truncate",
|
|
2079
|
-
children
|
|
2080
|
-
}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ComboboxItemIndicator, {
|
|
2081
|
-
className: ITEM_CHECK,
|
|
2082
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, {
|
|
2083
|
-
name: "check",
|
|
2084
|
-
className: "size-4"
|
|
2085
|
-
})
|
|
2086
|
-
})]
|
|
2087
|
-
});
|
|
2088
|
-
}
|
|
2089
|
-
export { ComboboxItem as a, SelectContent as c, SelectValue as d, ComboboxInput as i, SelectItem as l, ComboboxContent as n, ComboboxList as o, ComboboxEmpty as r, Select as s, Combobox as t, SelectTrigger as u };
|
|
1610
|
+
export { Select as a, SelectTrigger as c, ItemIndicator as d, resolveAriaLabelledBy as f, POPUP as i, SelectValue as l, useTypeahead as m, ITEM as n, SelectContent as o, isMouseWithinBounds as p, ITEM_CHECK as r, SelectItem as s, CHEVRON as t, TRIGGER as u };
|