allyhub 0.15.3 → 0.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +17 -0
- package/dist/commands/add.js +1 -1
- package/dist/commands/cloud-tools.js +1 -1
- package/dist/commands/dev.js +5 -5
- package/dist/commands/doctor.js +3 -3
- package/dist/commands/frames/doc.js +1 -1
- package/dist/commands/inspect/common.js +3 -3
- package/dist/commands/inspect/facts.js +2 -2
- package/dist/commands/inspect/index.js +1 -1
- package/dist/commands/inspect/layout.js +1 -1
- package/dist/commands/inspect/uses.js +3 -0
- package/dist/commands/mail.js +6 -6
- package/dist/commands/render.js +1 -1
- package/dist/main.js +8 -8
- package/dist/node_modules/@allyhub/3d-extension/dist/cli/scenery-text.js +2 -2
- package/dist/node_modules/@allyhub/3d-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/audio/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/audio/dist/place.js +2 -0
- package/dist/node_modules/@allyhub/audio/package.json +1 -1
- package/dist/node_modules/@allyhub/browser/package.json +1 -1
- package/dist/node_modules/@allyhub/build/dist/content.d.ts +7 -0
- package/dist/node_modules/@allyhub/build/dist/file-check.d.ts +2 -2
- package/dist/node_modules/@allyhub/build/dist/imports.d.ts +17 -0
- package/dist/node_modules/@allyhub/build/dist/imports.js +2 -0
- package/dist/node_modules/@allyhub/build/dist/index.d.ts +3 -2
- package/dist/node_modules/@allyhub/build/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/build/dist/inspect-view.d.ts +1 -1
- package/dist/node_modules/@allyhub/build/dist/inspect-view.js +1 -1
- package/dist/node_modules/@allyhub/build/dist/kind-build.d.ts +19 -3
- package/dist/node_modules/@allyhub/build/dist/prepare.js +3 -3
- package/dist/node_modules/@allyhub/build/dist/uses.d.ts +27 -6
- package/dist/node_modules/@allyhub/build/dist/uses.js +1 -1
- package/dist/node_modules/@allyhub/build/dist/work.d.ts +9 -1
- package/dist/node_modules/@allyhub/build/dist/work.js +3 -3
- package/dist/node_modules/@allyhub/build/package.json +1 -1
- package/dist/node_modules/@allyhub/canvas-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/canvas-extension/skills/allyhub/references/canvas.md +2 -2
- package/dist/node_modules/@allyhub/canvas-model/package.json +1 -1
- package/dist/node_modules/@allyhub/chart/package.json +1 -1
- package/dist/node_modules/@allyhub/check/package.json +1 -1
- package/dist/node_modules/@allyhub/cloud/dist/blobs.js +1 -1
- package/dist/node_modules/@allyhub/cloud/dist/client.d.ts +12 -3
- package/dist/node_modules/@allyhub/cloud/dist/client.js +1 -1
- package/dist/node_modules/@allyhub/cloud/dist/index.d.ts +1 -1
- package/dist/node_modules/@allyhub/cloud/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/cloud/package.json +1 -1
- package/dist/node_modules/@allyhub/components/package.json +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/deletion.js +2 -0
- package/dist/node_modules/@allyhub/dev-server/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/inputs.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/live.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/project.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/record.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/writer.js +3 -2
- package/dist/node_modules/@allyhub/dev-server/package.json +1 -1
- package/dist/node_modules/@allyhub/diagnostics/package.json +1 -1
- package/dist/node_modules/@allyhub/doc/dist/docx.js +4 -4
- package/dist/node_modules/@allyhub/doc/dist/html.js +40 -40
- package/dist/node_modules/@allyhub/doc/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/markdown.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/parse.js +4 -4
- package/dist/node_modules/@allyhub/doc/dist/table.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/write.js +26 -26
- package/dist/node_modules/@allyhub/doc/package.json +1 -1
- package/dist/node_modules/@allyhub/doc-extension/dist/build.js +2 -2
- package/dist/node_modules/@allyhub/doc-extension/dist/inspect.js +1 -1
- package/dist/node_modules/@allyhub/doc-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/doc-print/package.json +1 -1
- package/dist/node_modules/@allyhub/export/dist/export.js +1 -1
- package/dist/node_modules/@allyhub/export/package.json +1 -1
- package/dist/node_modules/@allyhub/extension-api/package.json +1 -1
- package/dist/node_modules/@allyhub/extension-host/dist/points.js +1 -1
- package/dist/node_modules/@allyhub/extension-host/package.json +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/slides.d.ts +15 -3
- package/dist/node_modules/@allyhub/formats/dist/data/slides.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/website.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/items.d.ts +70 -11
- package/dist/node_modules/@allyhub/formats/dist/items.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/layout.d.ts +15 -4
- package/dist/node_modules/@allyhub/formats/dist/layout.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/schemas.d.ts +4 -0
- package/dist/node_modules/@allyhub/formats/package.json +1 -1
- package/dist/node_modules/@allyhub/i18n/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/i18n/package.json +1 -1
- package/dist/node_modules/@allyhub/image-draw/dist/stage.js +1 -1
- package/dist/node_modules/@allyhub/image-draw/package.json +1 -1
- package/dist/node_modules/@allyhub/image-extension/dist/tools.js +1 -1
- package/dist/node_modules/@allyhub/image-extension/dist/workspace.js +1 -1
- package/dist/node_modules/@allyhub/image-extension/package.json +2 -2
- package/dist/node_modules/@allyhub/image-extension/skills/allyhub/references/images.md +3 -3
- package/dist/node_modules/@allyhub/image-measure/package.json +1 -1
- package/dist/node_modules/@allyhub/image-psd/package.json +1 -1
- package/dist/node_modules/@allyhub/image-render/package.json +1 -1
- package/dist/node_modules/@allyhub/image-runtime/dist/load.js +2 -2
- package/dist/node_modules/@allyhub/image-runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/image-sdk/package.json +1 -1
- package/dist/node_modules/@allyhub/jobs/package.json +1 -1
- package/dist/node_modules/@allyhub/linkedin-extension/package.json +3 -1
- package/dist/node_modules/@allyhub/linkedin-extension/skills/allyhub/references/linkedin.md +1 -1
- package/dist/node_modules/@allyhub/linkedin-model/package.json +1 -1
- package/dist/node_modules/@allyhub/linkedin-view/package.json +1 -1
- package/dist/node_modules/@allyhub/measure/package.json +1 -1
- package/dist/node_modules/@allyhub/media/package.json +1 -1
- package/dist/node_modules/@allyhub/media-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/model/package.json +1 -1
- package/dist/node_modules/@allyhub/office-extension/LICENSE +241 -0
- package/dist/node_modules/@allyhub/office-extension/markup/csv/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/csv/data/leads.csv +5 -0
- package/dist/node_modules/@allyhub/office-extension/markup/csv/markup.json +19 -0
- package/dist/node_modules/@allyhub/office-extension/markup/document/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/document/briefs/launch.docx +0 -0
- package/dist/node_modules/@allyhub/office-extension/markup/document/markup.json +11 -0
- package/dist/node_modules/@allyhub/office-extension/markup/presentation/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/presentation/decks/pitch.pptx +0 -0
- package/dist/node_modules/@allyhub/office-extension/markup/presentation/markup.json +11 -0
- package/dist/node_modules/@allyhub/office-extension/markup/workbook/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/workbook/data/plans.xlsx +0 -0
- package/dist/node_modules/@allyhub/office-extension/markup/workbook/markup.json +10 -0
- package/dist/node_modules/@allyhub/office-extension/package.json +124 -0
- package/dist/node_modules/@allyhub/ooxml/package.json +1 -1
- package/dist/node_modules/@allyhub/piece/dist/layer.d.ts +15 -0
- package/dist/node_modules/@allyhub/piece/dist/page/index.d.ts +1 -0
- package/dist/node_modules/@allyhub/piece/dist/page/index.js +1 -1
- package/dist/node_modules/@allyhub/piece/dist/page/runtimes.d.ts +9 -0
- package/dist/node_modules/@allyhub/piece/dist/page/runtimes.js +2 -0
- package/dist/node_modules/@allyhub/piece/dist/source.d.ts +53 -10
- package/dist/node_modules/@allyhub/piece/dist/source.js +1 -1
- package/dist/node_modules/@allyhub/piece/package.json +1 -1
- package/dist/node_modules/@allyhub/project/dist/digest.js +1 -1
- package/dist/node_modules/@allyhub/project/dist/part-keys.js +1 -1
- package/dist/node_modules/@allyhub/project/package.json +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/account.d.ts +10 -11
- package/dist/node_modules/@allyhub/protocol/dist/account.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/auth.d.ts +7 -0
- package/dist/node_modules/@allyhub/protocol/dist/auth.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/blobs.d.ts +9 -0
- package/dist/node_modules/@allyhub/protocol/dist/blobs.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/cli.d.ts +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/cli.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/cloud-computer.d.ts +77 -0
- package/dist/node_modules/@allyhub/protocol/dist/cloud-computer.js +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/cloud.d.ts +39 -9
- package/dist/node_modules/@allyhub/protocol/dist/cloud.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/editor.d.ts +15 -15
- package/dist/node_modules/@allyhub/protocol/dist/events.d.ts +441 -5
- package/dist/node_modules/@allyhub/protocol/dist/events.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/files.d.ts +2 -2
- package/dist/node_modules/@allyhub/protocol/dist/frame.d.ts +4 -1
- package/dist/node_modules/@allyhub/protocol/dist/frame.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/index.d.ts +8 -0
- package/dist/node_modules/@allyhub/protocol/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/jobs.d.ts +5 -5
- package/dist/node_modules/@allyhub/protocol/dist/kinds.d.ts +45 -0
- package/dist/node_modules/@allyhub/protocol/dist/kinds.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/paywall.d.ts +134 -0
- package/dist/node_modules/@allyhub/protocol/dist/paywall.js +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/place.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/presence.d.ts +3 -3
- package/dist/node_modules/@allyhub/protocol/dist/purposes.d.ts +47 -0
- package/dist/node_modules/@allyhub/protocol/dist/purposes.js +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/routes.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/shares.d.ts +52 -5
- package/dist/node_modules/@allyhub/protocol/dist/shares.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/sidebar-deletion.d.ts +34 -0
- package/dist/node_modules/@allyhub/protocol/dist/sidebar-deletion.js +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/sites.d.ts +1 -0
- package/dist/node_modules/@allyhub/protocol/dist/snapshots.d.ts +21 -52
- package/dist/node_modules/@allyhub/protocol/dist/snapshots.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/studio-server.d.ts +264 -0
- package/dist/node_modules/@allyhub/protocol/dist/studio-server.js +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/studio-tool-calls.d.ts +18 -0
- package/dist/node_modules/@allyhub/protocol/dist/studio-tool-calls.js +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/studio-window-requests.d.ts +97 -0
- package/dist/node_modules/@allyhub/protocol/dist/studio-window-requests.js +2 -0
- package/dist/node_modules/@allyhub/protocol/dist/teams.d.ts +3 -2
- package/dist/node_modules/@allyhub/protocol/dist/teams.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/tools.d.ts +26 -20
- package/dist/node_modules/@allyhub/protocol/dist/tools.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/turns.d.ts +71 -0
- package/dist/node_modules/@allyhub/protocol/dist/turns.js +2 -0
- package/dist/node_modules/@allyhub/protocol/package.json +1 -1
- package/dist/node_modules/@allyhub/registry/package.json +1 -1
- package/dist/node_modules/@allyhub/render/package.json +1 -1
- package/dist/node_modules/@allyhub/runtime/dist/compose.js +1 -1
- package/dist/node_modules/@allyhub/runtime/dist/embed.js +1 -1
- package/dist/node_modules/@allyhub/runtime/dist/film.js +1 -1
- package/dist/node_modules/@allyhub/runtime/dist/piece.js +2 -2
- package/dist/node_modules/@allyhub/runtime/dist/player/player.js +1 -1
- package/dist/node_modules/@allyhub/runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/runtimes/package.json +1 -1
- package/dist/node_modules/@allyhub/scaffold/dist/index.js +4 -4
- package/dist/node_modules/@allyhub/scaffold/package.json +1 -1
- package/dist/node_modules/@allyhub/scenery/package.json +1 -1
- package/dist/node_modules/@allyhub/scenery-host/package.json +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/coerce.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/engine.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/functions/criteria.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/functions/date.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/functions/dynamic.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/functions/info.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/functions/logical.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/functions/lookup.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/functions/text.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/formula/parse.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/charts.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/import.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/read.js +2 -2
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/write.js +1 -1
- package/dist/node_modules/@allyhub/sheet/package.json +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/dist/build.js +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/dist/cli/sheet.js +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/package.json +3 -3
- package/dist/node_modules/@allyhub/slides-core/dist/animation.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/api.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/components.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/resolve.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/package.json +1 -1
- package/dist/node_modules/@allyhub/slides-extension/dist/build.js +2 -1
- package/dist/node_modules/@allyhub/slides-extension/dist/cli/slides.js +2 -2
- package/dist/node_modules/@allyhub/slides-extension/dist/deck-pptx.js +1 -1
- package/dist/node_modules/@allyhub/slides-extension/dist/evaluate.js +2 -2
- package/dist/node_modules/@allyhub/slides-extension/dist/export.js +1 -1
- package/dist/node_modules/@allyhub/slides-extension/package.json +2 -2
- package/dist/node_modules/@allyhub/slides-pptx/dist/audio-icon.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/write.js +2 -2
- package/dist/node_modules/@allyhub/slides-pptx/package.json +5 -1
- package/dist/node_modules/@allyhub/slides-runtime/dist/component.js +1 -1
- package/dist/node_modules/@allyhub/slides-runtime/dist/draw.js +2 -2
- package/dist/node_modules/@allyhub/slides-runtime/dist/item.js +2 -0
- package/dist/node_modules/@allyhub/slides-runtime/dist/load.js +5 -5
- package/dist/node_modules/@allyhub/slides-runtime/dist/slide-css.js +20 -0
- package/dist/node_modules/@allyhub/slides-runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/stage/package.json +1 -1
- package/dist/node_modules/@allyhub/stage-page/dist/install.js +1 -1
- package/dist/node_modules/@allyhub/stage-page/dist/runtime/stage.html +1 -1
- package/dist/node_modules/@allyhub/stage-page/dist/runtime/stage.js +2 -2
- package/dist/node_modules/@allyhub/stage-page/package.json +1 -1
- package/dist/node_modules/@allyhub/stage-runtime/dist/runtime.js +20 -20
- package/dist/node_modules/@allyhub/stage-runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/telemetry/dist/doc.js +17 -2
- package/dist/node_modules/@allyhub/telemetry/dist/level.js +2 -2
- package/dist/node_modules/@allyhub/telemetry/dist/levels.js +2 -0
- package/dist/node_modules/@allyhub/telemetry/dist/scrub.js +1 -1
- package/dist/node_modules/@allyhub/telemetry/package.json +5 -1
- package/dist/node_modules/@allyhub/text-extension/markup/markup.json +1 -1
- package/dist/node_modules/@allyhub/text-extension/markup-file/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/text-extension/markup-file/archive/assets.zip +0 -0
- package/dist/node_modules/@allyhub/text-extension/markup-file/markup.json +10 -0
- package/dist/node_modules/@allyhub/text-extension/package.json +35 -1
- package/dist/node_modules/@allyhub/video-core/package.json +1 -1
- package/dist/node_modules/@allyhub/video-extension/dist/build.js +1 -1
- package/dist/node_modules/@allyhub/video-extension/dist/cli/reference-text.js +3 -3
- package/dist/node_modules/@allyhub/video-extension/package.json +2 -2
- package/dist/node_modules/@allyhub/video-measure/package.json +1 -1
- package/dist/node_modules/@allyhub/video-sdk/package.json +1 -1
- package/dist/node_modules/@allyhub/website/package.json +1 -1
- package/dist/node_modules/@allyhub/website-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/x-extension/package.json +3 -1
- package/dist/node_modules/@allyhub/x-extension/skills/allyhub/references/x.md +1 -1
- package/dist/node_modules/@allyhub/x-model/package.json +1 -1
- package/dist/node_modules/@allyhub/x-view/package.json +1 -1
- package/dist/package.json +13 -12
- package/dist/project.js +1 -1
- package/dist/telemetry.js +3 -3
- package/dist/text/console-text.js +2 -2
- package/dist/works.js +1 -1
- package/editor-web/assets/{abnfDiagram-WEYOIA3C-arPHIJYC.js → abnfDiagram-WEYOIA3C-CHNpVSPv.js} +1 -1
- package/editor-web/assets/{architecture-WOLXFQ4H-XPJlj9Iq.js → architecture-WOLXFQ4H-gPsJqQwV.js} +1 -1
- package/editor-web/assets/{architectureDiagram-ZHVYKT53-BZNJvOtd.js → architectureDiagram-ZHVYKT53-CEIDcC6r.js} +1 -1
- package/editor-web/assets/arrow-down-B8VUPCGi.js +1 -0
- package/editor-web/assets/arrow-up-Ds4juY8X.js +1 -0
- package/editor-web/assets/article-BHTjq0_Y.js +3 -0
- package/editor-web/assets/{article-Ck2ii-gZ.js → article-DfELjJ2o.js} +2 -2
- package/editor-web/assets/{audio-lines-1s1eRs4Q.js → audio-lines-PZj77e7t.js} +1 -1
- package/editor-web/assets/{bar-button-6Perrucg.js → bar-button-J9vbfzTx.js} +1 -1
- package/editor-web/assets/{blockDiagram-RJAE7QA3-B4L2P9Zz.js → blockDiagram-RJAE7QA3-CUzEGVet.js} +4 -4
- package/editor-web/assets/browser-C1XuTMlp.js +1 -0
- package/editor-web/assets/{c4Diagram-XDPPPE54-D5t2-Sm8.js → c4Diagram-XDPPPE54-CB94NR9s.js} +1 -1
- package/editor-web/assets/calc-worker-BdHh5LXM.js +45 -0
- package/editor-web/assets/channel-DCDCx5Es.js +1 -0
- package/editor-web/assets/chart-amT4lgX3.js +2 -0
- package/editor-web/assets/chart-file-CfbWK9l1.js +1 -0
- package/editor-web/assets/{chart-no-axes-column-CJmeYOSo.js → chart-no-axes-column-Be0lFcGF.js} +1 -1
- package/editor-web/assets/{chunk-2E7WHVMD-bWUHKM6h.js → chunk-2E7WHVMD-DFYo_Boi.js} +1 -1
- package/editor-web/assets/{chunk-4EMNKR2T-CGGaxE7r.js → chunk-4EMNKR2T-CLLjmweX.js} +1 -1
- package/editor-web/assets/{chunk-55XCU76K-BXCHI3wC.js → chunk-55XCU76K-CkwQ_3m1.js} +1 -1
- package/editor-web/assets/{chunk-7S6XSTFO-H4tWSKhS.js → chunk-7S6XSTFO-V-AvHpAB.js} +1 -1
- package/editor-web/assets/{chunk-AQDTSKZB-kyBZy8vG.js → chunk-AQDTSKZB-PjHyYpb8.js} +1 -1
- package/editor-web/assets/chunk-DSNLSHJZ-QaczBS3J.js +127 -0
- package/editor-web/assets/{chunk-HAGFOTED-P8dIUq9O.js → chunk-HAGFOTED-aLaQB5Xu.js} +1 -1
- package/editor-web/assets/{chunk-HNE4Q36P-B_BAZXMj.js → chunk-HNE4Q36P-De3ftDQR.js} +1 -1
- package/editor-web/assets/{chunk-NQOKRVIF-Bubl63jI.js → chunk-NQOKRVIF-CrhVQyvP.js} +17 -17
- package/editor-web/assets/{chunk-UHW7PFBP-DYGk0ZDz.js → chunk-UHW7PFBP-BFmZ5ZLn.js} +1 -1
- package/editor-web/assets/{chunk-VQ5W62QI-BLFRyEGi.js → chunk-VQ5W62QI-CzppUHLA.js} +1 -1
- package/editor-web/assets/{chunk-WQQL4CDK-kiwalF_c.js → chunk-WQQL4CDK-BrAU7V6v.js} +1 -1
- package/editor-web/assets/{chunk-YZO67HFG-D-bT0L2N.js → chunk-YZO67HFG-BSiF71qj.js} +1 -1
- package/editor-web/assets/{chunk-ZAUX2LTX-C_P5nPKV.js → chunk-ZAUX2LTX-BJc4r5b1.js} +1 -1
- package/editor-web/assets/{chunk-ZCHMQSOR-Deizt1PO.js → chunk-ZCHMQSOR-CkGTuehB.js} +1 -1
- package/editor-web/assets/{classDiagram-v2-4MYWR3UA-PUtBnliw.js → classDiagram-v2-4MYWR3UA-Byxc7J88.js} +7 -7
- package/editor-web/assets/code-CD-CbJG9.js +1 -0
- package/editor-web/assets/{collaborator--S95EupA.js → collaborator-BU4qU7O3.js} +1 -1
- package/editor-web/assets/{copy-DvOiv9Ra.js → copy-CuJSs0nI.js} +1 -1
- package/editor-web/assets/{createLucideIcon-REX213UO.js → createLucideIcon-lm_6n8YT.js} +1 -1
- package/editor-web/assets/csv-Bwre9FdI.js +11 -0
- package/editor-web/assets/{cynefin-EF2NZ3EQ-C09G_QFD.js → cynefin-EF2NZ3EQ-BSxkVbdf.js} +1 -1
- package/editor-web/assets/{cynefinDiagram-WF24UDRP-JxxJ5-Ov.js → cynefinDiagram-WF24UDRP-IkCgARNs.js} +1 -1
- package/editor-web/assets/{dagre-NK4GIZVX-6DkhWeGP.js → dagre-NK4GIZVX-9PgeH6nY.js} +1 -1
- package/editor-web/assets/deck-tTzKONci.js +1 -0
- package/editor-web/assets/{diagram-CBK3MWTC-kI_Q07du.js → diagram-CBK3MWTC-DRzeg3Ds.js} +1 -1
- package/editor-web/assets/{diagram-I5XIIV2D-FYaR41qP.js → diagram-I5XIIV2D-B_zeKMN6.js} +1 -1
- package/editor-web/assets/{diagram-ODIL2UCW-29WBGOdl.js → diagram-ODIL2UCW-FFm0O8SN.js} +1 -1
- package/editor-web/assets/{diagram-PFBEJUXE-BFZJ9s9P.js → diagram-PFBEJUXE-DrtCT8OA.js} +1 -1
- package/editor-web/assets/{diagram-RJA3I4VV-BSNFe4e-.js → diagram-RJA3I4VV-DtxJ3V0q.js} +1 -1
- package/editor-web/assets/{diagram-TYUNFSNR-Cb1wZgqj.js → diagram-TYUNFSNR-DmxF_8H_.js} +16 -16
- package/editor-web/assets/dist-BEpzsYn_.js +6 -0
- package/editor-web/assets/dist-BUD4ywMB.js +18 -0
- package/editor-web/assets/{dist-BrGYx10E.js → dist-Bd8IxQPP.js} +1 -1
- package/editor-web/assets/dist-C21CkR7Z.js +531 -0
- package/editor-web/assets/{dist-BuG-vxxb.js → dist-C56mWAec.js} +3 -3
- package/editor-web/assets/dist-CAb3W9_P.js +43 -0
- package/editor-web/assets/dist-CEknsRDd.js +24 -0
- package/editor-web/assets/dist-CbZAznNW.js +19 -0
- package/editor-web/assets/{dist-BaCVkpwc.js → dist-D3C6FyrO.js} +1 -1
- package/editor-web/assets/dist-DDzjbKIg.js +4 -0
- package/editor-web/assets/dist-DaEbElXI.js +3 -0
- package/editor-web/assets/{dist-CnbKC_fW.js → dist-Dr3o4vee.js} +1 -1
- package/editor-web/assets/{dist-BlqK1Oua.js → dist-DruvDNQe.js} +1 -1
- package/editor-web/assets/dist-JLyDtl9X.js +1 -0
- package/editor-web/assets/dist-PBbWAsrV.js +17 -0
- package/editor-web/assets/dist-ZZlQa66J.js +1 -0
- package/editor-web/assets/{dist-DXUMNYNX.js → dist-bQKpw3Zz.js} +5 -5
- package/editor-web/assets/dist-d4dayaWE.js +17 -0
- package/editor-web/assets/docx-draw-9Q_fArBC.js +4 -0
- package/editor-web/assets/docx-preview-pcg9ioe3.js +21 -0
- package/editor-web/assets/{ebnfDiagram-V4P3TTPT-t3vO5qHB.js → ebnfDiagram-V4P3TTPT-DSX1Aoty.js} +1 -1
- package/editor-web/assets/{elk-QONTBCTQ-DfIcGBDb.js → elk-QONTBCTQ-C7gy9q56.js} +1 -1
- package/editor-web/assets/{erDiagram-KYQIGQAA-Bgy1PYQf.js → erDiagram-KYQIGQAA-CKx_HoY4.js} +2 -2
- package/editor-web/assets/esm-BZb5QMQf.js +21 -0
- package/editor-web/assets/{eventmodeling-K75KTNOO-b8j935GM.js → eventmodeling-K75KTNOO-DL4HvSrd.js} +1 -1
- package/editor-web/assets/{file-exclamation-point-C_fX4fpI.js → file-exclamation-point-_L3ElCJ5.js} +1 -1
- package/editor-web/assets/file-question-mark-DlIjUK37.js +1 -0
- package/editor-web/assets/flowDiagram-IUGLLWBU-BUnRtJ8q.js +1 -0
- package/editor-web/assets/{ganttDiagram-R7GPNTJY-B6C_nkwn.js → ganttDiagram-R7GPNTJY-N-AP4slN.js} +1 -1
- package/editor-web/assets/{gitGraph-VSP46ZUC-CWtulOri.js → gitGraph-VSP46ZUC-BKRGJKWm.js} +1 -1
- package/editor-web/assets/{gitGraphDiagram-PDYL7XHY-BT80Z9gj.js → gitGraphDiagram-PDYL7XHY-ClwL7w2_.js} +1 -1
- package/editor-web/assets/{group-pebHQTdP.js → group-BdrTp7gi.js} +1 -1
- package/editor-web/assets/{hint-CKIaljPY.js → hint-rlht0uxG.js} +1 -1
- package/editor-web/assets/index-BedbINE5.css +2 -0
- package/editor-web/assets/index-DG2nHq4D.js +28 -0
- package/editor-web/assets/{info-OHQRW6UA-CyWiLOaB.js → info-OHQRW6UA-DpcY8t23.js} +1 -1
- package/editor-web/assets/{infoDiagram-MVDRKAX5-3TQgBeRh.js → infoDiagram-MVDRKAX5-ChtmtWni.js} +1 -1
- package/editor-web/assets/{ishikawaDiagram-HPEHV2GE-C3RAGFl7.js → ishikawaDiagram-HPEHV2GE-BZNTuG_F.js} +1 -1
- package/editor-web/assets/iso-ahTwmFwH.js +56 -0
- package/editor-web/assets/{italic-CtlNOXN9.js → italic-zw4_eUNF.js} +1 -1
- package/editor-web/assets/{journeyDiagram-BOSHW7O7-B3ZJp3pT.js → journeyDiagram-BOSHW7O7-C3uVmZbL.js} +1 -1
- package/editor-web/assets/{kanban-definition-FNSA4HC5-ChjUoDH7.js → kanban-definition-FNSA4HC5-puEhftGG.js} +4 -4
- package/editor-web/assets/{link-CW2KxKT_.js → link-DopSU3aa.js} +1 -1
- package/editor-web/assets/{mermaid-parser.core-CqJ7hTUI.js → mermaid-parser.core-Bw8re-WE.js} +3 -3
- package/editor-web/assets/mermaid.core-Cc2GIqBr.js +44 -0
- package/editor-web/assets/{mindmap-definition-6OY57UG3-Di0DNds3.js → mindmap-definition-6OY57UG3-C6MUl_S_.js} +3 -3
- package/editor-web/assets/minus-CbPnUIOy.js +1 -0
- package/editor-web/assets/{packet-JDAUHWVQ-CkCyk5LQ.js → packet-JDAUHWVQ-C75RnvC5.js} +1 -1
- package/editor-web/assets/{pegDiagram-ECIUJNBX-DGyUszOM.js → pegDiagram-ECIUJNBX-ChjmsdV4.js} +1 -1
- package/editor-web/assets/{pie-XZMESJXO-D56l6NOA.js → pie-XZMESJXO-BaKxJQpj.js} +1 -1
- package/editor-web/assets/{pieDiagram-GNMPY74T-C6Gy4c9c.js → pieDiagram-GNMPY74T-CT2ez8pr.js} +1 -1
- package/editor-web/assets/{progress-I2qmIfF4.js → progress-CwKcXARv.js} +1 -1
- package/editor-web/assets/props-form-D5oKHfpk.js +1 -0
- package/editor-web/assets/purify.es-B9ve_eFf.js +3 -0
- package/editor-web/assets/{quadrantDiagram-D57K4MC3-CWfkAwXQ.js → quadrantDiagram-D57K4MC3-BJItlTfk.js} +1 -1
- package/editor-web/assets/{radar-ABXABTNO-BhyQtVw_.js → radar-ABXABTNO-DnLzBlTo.js} +1 -1
- package/editor-web/assets/{railroad-I3PHUGI6-CyOyOgY6.js → railroad-I3PHUGI6-D5hj6Yv3.js} +1 -1
- package/editor-web/assets/{railroad-abnf-LNEFI6M7-ExhYWNk4.js → railroad-abnf-LNEFI6M7-DUZlZoPu.js} +1 -1
- package/editor-web/assets/{railroad-ebnf-DWYD2UWJ-B7vR6DFd.js → railroad-ebnf-DWYD2UWJ-CDyyDC6d.js} +1 -1
- package/editor-web/assets/{railroad-peg-JR7BVNR7-hqCnhLuG.js → railroad-peg-JR7BVNR7-CC3ImNnT.js} +1 -1
- package/editor-web/assets/{railroadDiagram-Y72NRBL7-D5X_R2ve.js → railroadDiagram-Y72NRBL7-Bjw-8Se5.js} +1 -1
- package/editor-web/assets/{react-Bk7NnOLX.js → react-Edyoga_4.js} +1 -1
- package/editor-web/assets/{requirementDiagram-EQYSW5RA-CIP8sDsk.js → requirementDiagram-EQYSW5RA-CDFnuEIO.js} +1 -1
- package/editor-web/assets/{row-k2eAfT-g.js → row-C_svyL8o.js} +1 -1
- package/editor-web/assets/{sankeyDiagram-SY24JHO5-BKDJlzrK.js → sankeyDiagram-SY24JHO5-CQPVLY1w.js} +1 -1
- package/editor-web/assets/schemas-moE_A7Nj.js +1 -0
- package/editor-web/assets/{scissors-BURkYWPv.js → scissors-B_xOiUhd.js} +1 -1
- package/editor-web/assets/{search-jKDvFIEU.js → search-Ba2BbT6T.js} +1 -1
- package/editor-web/assets/{sequenceDiagram-BLEHNHQU-CkRLYFZ7.js → sequenceDiagram-BLEHNHQU-BQzuLmBX.js} +1 -1
- package/editor-web/assets/{session-CUCSWPTE.js → session-s1I85rox.js} +1 -1
- package/editor-web/assets/{sigma-CY2Chbro.js → sigma-DSUsJhMn.js} +1 -1
- package/editor-web/assets/slides-oQ_C0SVJ.js +1 -0
- package/editor-web/assets/snapshots-BPJKywuN.js +1 -0
- package/editor-web/assets/{sound-DUCxe9eC.js → sound-bTlco_K3.js} +1 -1
- package/editor-web/assets/{split-Cjm6rVDC.js → split-7CVjIkSU.js} +2 -2
- package/editor-web/assets/square-arrow-out-up-right-DF5dvsSp.js +1 -0
- package/editor-web/assets/{stateDiagram-v2-A6IESKWZ-CCvwoTcz.js → stateDiagram-v2-A6IESKWZ-DOuageUf.js} +7 -7
- package/editor-web/assets/{sticky-note-C5qUDHhC.js → sticky-note-BdkIu5_D.js} +1 -1
- package/editor-web/assets/{strikethrough-DP-7tMz0.js → strikethrough-BwXWi4zg.js} +1 -1
- package/editor-web/assets/{surface-BocGwSox.js → surface-DtCjIlrq.js} +1 -1
- package/editor-web/assets/svg-CWIBMIQ9.js +1 -0
- package/editor-web/assets/{swatch-DGdJ5SeN.js → swatch-DhztHwPU.js} +1 -1
- package/editor-web/assets/{swimlanes-B3ENRKFQ-BXgW4pi4.js → swimlanes-B3ENRKFQ-CXKkok7X.js} +1 -1
- package/editor-web/assets/swimlanesDiagram-AYQRV4AK-C3Car2M0.js +8 -0
- package/editor-web/assets/{switch-Dwqxw1kp.js → switch-8MU4Nfxe.js} +1 -1
- package/editor-web/assets/{syntax-DSsHrzWF.js → syntax-CU_WPKxt.js} +1 -1
- package/editor-web/assets/{table-CTjNpE4W.js → table-DRbddzx0.js} +1 -1
- package/editor-web/assets/tabs-CiF1N-pL.js +1 -0
- package/editor-web/assets/tag-CIfWT8B_.js +1 -0
- package/editor-web/assets/text-align-start-Cic2-TLh.js +1 -0
- package/editor-web/assets/{textarea-BNH6Y1-o.js → textarea-D7TnPwv1.js} +1 -1
- package/editor-web/assets/{timeline-definition-JXYKGLGB-BwuUmgv1.js → timeline-definition-JXYKGLGB-DgAjAeZp.js} +3 -3
- package/editor-web/assets/{treeView-D4JQ5SDB-Da35tnkE.js → treeView-D4JQ5SDB-C0Xvnhck.js} +1 -1
- package/editor-web/assets/{treemap-SAJKECNS-4TcJReov.js → treemap-SAJKECNS-aXfKAeSX.js} +1 -1
- package/editor-web/assets/{undo-2-DUGGyBdX.js → undo-2-C47jrRp5.js} +1 -1
- package/editor-web/assets/{usecaseDiagram-WPOLBNNX-wj02og_C.js → usecaseDiagram-WPOLBNNX-CvUlBa-L.js} +1 -1
- package/editor-web/assets/{vennDiagram-Q3Y3IDCW-Cun6o3pg.js → vennDiagram-Q3Y3IDCW-qMJ1iCxs.js} +3 -3
- package/editor-web/assets/{video-DkuN7Uu7.js → video-DQrjo1TI.js} +1 -1
- package/editor-web/assets/{wardley-7MLQ67FV-DiL2aSXm.js → wardley-7MLQ67FV-DEdnH0by.js} +1 -1
- package/editor-web/assets/{wardleyDiagram-IVAIDKWA-Cll7rTnv.js → wardleyDiagram-IVAIDKWA-Bt-B2hQ5.js} +1 -1
- package/editor-web/assets/{whole-word-6DliXke2.js → whole-word-D3ZAtnkw.js} +1 -1
- package/editor-web/assets/{words-QKSIyC_P.js → words-0Ww2RyT4.js} +1 -1
- package/editor-web/assets/{words-B-7GbYO2.js → words-XlXG79Ur.js} +1 -1
- package/editor-web/assets/workbook-FSSUiIp9.js +45 -0
- package/editor-web/assets/x-DlhyIKuu.js +41 -0
- package/editor-web/assets/{xychartDiagram-4URNHDU4-s55eVncs.js → xychartDiagram-4URNHDU4-DV4bSzTb.js} +1 -1
- package/editor-web/assets/{zoom-in-C4lxmIDE.js → zoom-in-PgsC94hP.js} +1 -1
- package/editor-web/index.html +8 -7
- package/package.json +2 -2
- package/editor-web/assets/arrow-down-DzZjFrBL.js +0 -1
- package/editor-web/assets/arrow-up-hdmh9LVD.js +0 -1
- package/editor-web/assets/article-v30Q5cvX.js +0 -3
- package/editor-web/assets/calc-worker-jImBXoeb.js +0 -45
- package/editor-web/assets/channel-B8881pqR.js +0 -1
- package/editor-web/assets/chart-BC3kUUDD.js +0 -2
- package/editor-web/assets/chunk-DSNLSHJZ-BlB7YIMo.js +0 -129
- package/editor-web/assets/code-BID_OoRp.js +0 -1
- package/editor-web/assets/dist-B3RkByp0.js +0 -1
- package/editor-web/assets/dist-BAeqmRLA.js +0 -530
- package/editor-web/assets/dist-CGJv5-SE.js +0 -45
- package/editor-web/assets/dist-CUdvgRW5.js +0 -1
- package/editor-web/assets/dist-DhKxOqdu.js +0 -43
- package/editor-web/assets/dist-Dx2yV02v.js +0 -6
- package/editor-web/assets/dist-QuK0-suW.js +0 -24
- package/editor-web/assets/dist-Sl2_j-4w.js +0 -38
- package/editor-web/assets/dist-b5nFx4mV.js +0 -3
- package/editor-web/assets/dist-tteqAu5L.js +0 -4
- package/editor-web/assets/flowDiagram-IUGLLWBU-CnzC5OOy.js +0 -1
- package/editor-web/assets/index-C3A0pCmH.css +0 -2
- package/editor-web/assets/index-CFqSJBZ-.js +0 -28
- package/editor-web/assets/mermaid.core-DR2O-coV.js +0 -44
- package/editor-web/assets/minus-D1tgAHbU.js +0 -1
- package/editor-web/assets/props-form-gwp-8pGV.js +0 -1
- package/editor-web/assets/schemas-B89k2jEC.js +0 -1
- package/editor-web/assets/slides-BdaWgL_N.js +0 -1
- package/editor-web/assets/snapshots-CTS2iez5.js +0 -56
- package/editor-web/assets/svg-nJtFNJ-7.js +0 -1
- package/editor-web/assets/swimlanesDiagram-AYQRV4AK-AFpLq-Wf.js +0 -8
- package/editor-web/assets/tabs-B0bv2mMP.js +0 -1
- package/editor-web/assets/x-BsePFh6d.js +0 -41
|
@@ -1 +1 @@
|
|
|
1
|
-
import{M as e,
|
|
1
|
+
import{M as e,N as t}from"./snapshots-BPJKywuN.js";var n=8,r=3e4,i=n=>n instanceof t&&n.code===e.unavailable,a=n=>{if(!(n instanceof t)||n.code!==e.conflict)return;let r=n.data;return typeof r?.text==`string`&&(typeof r.version==`string`||r.version===null)?{text:r.text,version:r.version}:void 0},o=e=>`backup:${e}`,s=e=>typeof e==`object`&&!!e&&typeof e.text==`string`&&(typeof e.over==`string`||e.over===null),c=class e{path;text;version;state=`saved`;error;backup;host;delay;report;retryDelay;format;running;timer;dirty=!1;stale=!1;by;closed=!1;closing=!1;stops=[];stateListeners=new Set;undoListeners=new Set;undone=[];done=[];backupDelay;backupTimer;storage=!0;constructor(e,t,n,r){this.host=e,this.path=t,this.text=n.text,this.version=n.version,this.delay=r.delay??500,this.report=r.report??!0,this.backupDelay=r.backupDelay??1e3,this.retryDelay=r.retryDelay??1e3}static async open(t,n,r={}){let i=new e(t,n,await t[`files/read`]({path:n}),r);try{let e=await t[`storage/get`]?.({key:o(n)});e===void 0?i.storage=!1:s(e.value)&&e.value.over===i.version?i.backup=e.value:e.value!==null&&e.value!==void 0&&await t[`storage/set`]?.({key:o(n),value:null})}catch{i.storage=!1}let{watch:a}=await t[`files/watch`]({paths:[n]});return i.stops.push(t.on(`files/changed`,e=>{if(e.watch!==a)return;let t=e.changes.find(e=>e.path===n&&e.version!==i.version);t&&i.changed(t.by)}),()=>{t[`files/unwatch`]({watch:a}).catch(()=>void 0)}),i}attach(e){this.format=e}onState(e){return this.stateListeners.add(e),()=>this.stateListeners.delete(e)}edited(){this.closed||(this.dirty=!0,this.set(`unsaved`),clearTimeout(this.timer),this.timer=setTimeout(()=>{this.kick()},this.delay),this.storage&&(clearTimeout(this.backupTimer),this.backupTimer=setTimeout(()=>{this.backUp()},this.backupDelay)))}pushEdit(e){this.closed||(this.done.push(e),this.undone.length=0,this.edited(),this.undoChanged())}get canUndo(){return this.done.length>0}get canRedo(){return this.undone.length>0}get undoLabel(){return this.done.at(-1)?.label}get redoLabel(){return this.undone.at(-1)?.label}undo(){let e=this.done.pop();return e?(e.undo(),this.undone.push(e),this.edited(),this.undoChanged(),!0):!1}redo(){let e=this.undone.pop();return e?(e.redo(),this.done.push(e),this.edited(),this.undoChanged(),!0):!1}onUndo(e){return this.undoListeners.add(e),()=>this.undoListeners.delete(e)}undoChanged(){for(let e of this.undoListeners)e()}restoreBackup(){let e=this.backup;return!e||!this.format||e.over!==this.version?!1:(this.backup=void 0,this.format.take(e.text,this.text),this.edited(),!0)}async keepBackup(e){this.storage&&await this.host[`storage/set`]?.({key:o(this.path),value:e}).catch(()=>void 0)}async discardBackup(){this.backup=void 0,await this.keepBackup(null)}async backUp(){if(!this.format||this.closed)return;let e=this.format.save(this.text),t=e===void 0?null:{over:this.version,text:e};await this.keepBackup(t)}flush(){return clearTimeout(this.timer),this.kick()}changed(e){return this.stale=!0,this.by=e,this.kick()}async close(){this.closing=!0,await this.flush(),clearTimeout(this.backupTimer),this.state===`saved`&&await this.keepBackup(null),this.closed=!0;for(let e of this.stops.splice(0))e()}set(e,t){if(this.error=t,e!==this.state||t!==void 0){this.state=e;for(let t of this.stateListeners)t(e);this.report&&this.host[`editor/state`]&&this.host[`editor/state`]({state:e,...t===void 0?{}:{message:t}}).catch(()=>void 0)}}take(e,t,n){let r=this.text;this.text=e,this.version=t,e!==r&&this.format?.take(e,r,n)}waiting(){return this.dirty}kick(){return this.running??=this.loop(),this.running}async loop(){await Promise.resolve();let e=0,t=0;try{for(;this.dirty||this.stale;){if(this.stale){this.stale=!1;let e=this.by;this.by=void 0;let t=await this.host[`files/read`]({path:this.path});this.take(t.text,t.version,e)}if(!this.dirty||!this.format)continue;this.dirty=!1;let o=this.format.save(this.text);if(o===void 0)this.set(`saved`);else{this.set(`saving`);try{let{version:e}=await this.host[`files/write`]({path:this.path,text:o,over:this.version});if(this.text=o,this.version=e,!this.waiting()){let e=this.format.save(this.text)===void 0;this.set(e?`saved`:`unsaved`),e&&(clearTimeout(this.backupTimer),await this.keepBackup(null))}}catch(s){let c=a(s);if(!c){if(i(s)&&!this.closing){this.dirty=!0,this.set(`unsaved`);let e=Math.min(this.retryDelay*2**t++,r);await new Promise(t=>setTimeout(t,e));continue}this.set(`error`,s instanceof Error?s.message:String(s));continue}if(c.text===o){this.text=o,this.version=c.version,this.waiting()||this.set(this.format.save(this.text)===void 0?`saved`:`unsaved`);continue}if(this.take(c.text,c.version),++e>=n){this.set(`error`,`${this.path} keeps changing.`);continue}this.dirty=!0}}}}catch(e){this.dirty=!1,this.stale=!1,this.set(`error`,e instanceof Error?e.message:String(e))}finally{this.running=void 0}}};export{c as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./createLucideIcon-
|
|
1
|
+
import{t as e}from"./createLucideIcon-lm_6n8YT.js";var t=e(`sigma`,[[`path`,{d:`M18 7V5a1 1 0 0 0-1-1H6.5a.5.5 0 0 0-.4.8l4.5 6a2 2 0 0 1 0 2.4l-4.5 6a.5.5 0 0 0 .4.8H17a1 1 0 0 0 1-1v-2`,key:`wuwx1p`}]]);export{t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{C as e,S as t,T as n,_ as r,a as i,c as a,d as o,g as s,i as c,m as l,o as u,p as d,w as f,x as p,y as m}from"./iso-ahTwmFwH.js";var ee=/^[A-Za-z0-9_-]+(?:\.[A-Za-z0-9_-]+)*$/u,te=p({display:t(),speak:t()}),h=p({declarations:u(t()).default([]),selectors:u(t()).default([]),match:m(t(),t()).refine(e=>Object.keys(e).length>0,`A match needs at least one case.`)}),ne=f([t(),te,e([h])]),re=m(t(),n()).superRefine((e,t)=>{for(let[n,r]of Object.entries(e)){if(n===`$schema`){typeof r!=`string`&&t.addIssue({code:`custom`,path:[n],message:`$schema is a string.`});continue}ee.test(n)||t.addIssue({code:`custom`,path:[n],message:`"${n}" is not a message key: letters, digits, _ and -, in segments joined by dots.`});let e=ne.safeParse(r);e.success||t.addIssue({code:`custom`,path:[n],message:Array.isArray(r)?`A message with variants is [{ "declarations": […], "selectors": […], "match": {…} }]: ${e.error.issues.map(e=>e.message).join(`; `)}`:`A message is a string, { display, speak }, or [{ declarations, selectors, match }].`})}}).transform(e=>{let t={...e};return delete t.$schema,t}),g=/^[A-Za-z0-9_-]+$/u,_=t().regex(g,`A name is letters, digits, _ and -.`),v=d(()=>f([t(),te,h,u(v),m(_,v)])),ie=p({id:_,say:f([t(),h]).optional(),screen:m(_,v).optional()}),y=p({id:_,text:m(_,v).optional(),alt:m(_,t()).optional(),notes:f([t(),h]).optional()}),ae=p({id:_,text:m(_,v).optional()}),oe=p({title:t().optional(),text:m(_,v).optional(),parts:u(ie).default([]),slides:u(y).default([]),boards:u(ae).default([])}).superRefine((e,t)=>{let n=new Set;e.parts.forEach((e,r)=>{n.has(e.id)&&t.addIssue({code:`custom`,path:[`parts`,r,`id`],message:`Two parts are "${e.id}".`}),n.add(e.id)});let r=new Set;e.slides.forEach((e,n)=>{r.has(e.id)&&t.addIssue({code:`custom`,path:[`slides`,n,`id`],message:`Two slides are "${e.id}".`}),r.add(e.id)});let i=new Set;e.boards.forEach((e,n)=>{i.has(e.id)&&t.addIssue({code:`custom`,path:[`boards`,n,`id`],message:`Two boards are "${e.id}".`}),i.add(e.id)})}),b=t().regex(g,`A name is letters, digits, _ and -.`),x=[`dk1`,`lt1`,`dk2`,`lt2`,`accent1`,`accent2`,`accent3`,`accent4`,`accent5`,`accent6`,`hlink`,`folHlink`],se=[`l`,`ctr`,`r`,`just`],ce=`line.lineInv.triangle.rtTriangle.rect.diamond.parallelogram.trapezoid.nonIsoscelesTrapezoid.pentagon.hexagon.heptagon.octagon.decagon.dodecagon.star4.star5.star6.star7.star8.star10.star12.star16.star24.star32.roundRect.round1Rect.round2SameRect.round2DiagRect.snipRoundRect.snip1Rect.snip2SameRect.snip2DiagRect.plaque.ellipse.teardrop.homePlate.chevron.pieWedge.pie.blockArc.donut.noSmoking.rightArrow.leftArrow.upArrow.downArrow.stripedRightArrow.notchedRightArrow.bentUpArrow.leftRightArrow.upDownArrow.leftUpArrow.leftRightUpArrow.quadArrow.leftArrowCallout.rightArrowCallout.upArrowCallout.downArrowCallout.leftRightArrowCallout.upDownArrowCallout.quadArrowCallout.bentArrow.uturnArrow.circularArrow.leftCircularArrow.leftRightCircularArrow.curvedRightArrow.curvedLeftArrow.curvedUpArrow.curvedDownArrow.swooshArrow.cube.can.lightningBolt.heart.sun.moon.smileyFace.irregularSeal1.irregularSeal2.foldedCorner.bevel.frame.halfFrame.corner.diagStripe.chord.arc.leftBracket.rightBracket.leftBrace.rightBrace.bracketPair.bracePair.straightConnector1.bentConnector2.bentConnector3.bentConnector4.bentConnector5.curvedConnector2.curvedConnector3.curvedConnector4.curvedConnector5.callout1.callout2.callout3.accentCallout1.accentCallout2.accentCallout3.borderCallout1.borderCallout2.borderCallout3.accentBorderCallout1.accentBorderCallout2.accentBorderCallout3.wedgeRectCallout.wedgeRoundRectCallout.wedgeEllipseCallout.cloudCallout.cloud.ribbon.ribbon2.ellipseRibbon.ellipseRibbon2.leftRightRibbon.verticalScroll.horizontalScroll.wave.doubleWave.plus.flowChartProcess.flowChartDecision.flowChartInputOutput.flowChartPredefinedProcess.flowChartInternalStorage.flowChartDocument.flowChartMultidocument.flowChartTerminator.flowChartPreparation.flowChartManualInput.flowChartManualOperation.flowChartConnector.flowChartPunchedCard.flowChartPunchedTape.flowChartSummingJunction.flowChartOr.flowChartCollate.flowChartSort.flowChartExtract.flowChartMerge.flowChartOfflineStorage.flowChartOnlineStorage.flowChartMagneticTape.flowChartMagneticDisk.flowChartMagneticDrum.flowChartDisplay.flowChartDelay.flowChartAlternateProcess.flowChartOffpageConnector.actionButtonBlank.actionButtonHome.actionButtonHelp.actionButtonInformation.actionButtonForwardNext.actionButtonBackPrevious.actionButtonEnd.actionButtonBeginning.actionButtonReturn.actionButtonDocument.actionButtonSound.actionButtonMovie.gear6.gear9.funnel.mathPlus.mathMinus.mathMultiply.mathDivide.mathEqual.mathNotEqual.cornerTabs.squareTabs.plaqueTabs.chartX.chartStar.chartPlus`.split(`.`),S=[`appear`,`fade`,`fly-in`,`float-in`,`split`,`wipe`,`zoom`,`disappear`,`fade-out`,`fly-out`,`float-out`,`split-out`,`wipe-out`,`zoom-out`,`pulse`,`grow-shrink`,`spin`,`transparency`,`path`],le=[`word`,`letter`],ue=[`until-next-click`,`until-end-of-slide`],de=[`on-click`,`with-previous`,`after-previous`],C=[`from-bottom`,`from-top`,`from-left`,`from-right`,`from-top-right`,`from-bottom-right`,`from-top-left`,`from-bottom-left`,`vertical-out`,`vertical-in`,`horizontal-out`,`horizontal-in`,`in`,`out`,`rotate`,`up`,`down`,`clockwise`,`counterclockwise`,`both`,`horizontal`,`vertical`],w=[`solid`,`sysDot`,`sysDash`,`dash`,`dashDot`,`lgDash`,`lgDashDot`,`lgDashDotDot`,`dot`,`sysDashDot`,`sysDashDotDot`],T=[`flat`,`rnd`,`sq`],E=[`round`,`bevel`,`miter`],D=[`sng`,`dbl`,`thickThin`,`thinThick`,`tri`],O=[`none`,`triangle`,`arrow`,`stealth`,`diamond`,`oval`],k=[`sm`,`med`,`lg`],A=p({w:c(k).optional(),len:c(k).optional()}),fe=p({x:s(),y:s(),w:s().nonnegative(),h:s().nonnegative()}),j=[`tx1`,`bg1`,`tx2`,`bg2`],M=[...x,...j],N=[`tint`,`shade`,`lumMod`,`lumOff`,`lum`,`satMod`,`satOff`,`sat`,`hueMod`,`hueOff`,`hue`,`alpha`,`alphaMod`,`alphaOff`],P=`(?:${M.join(`|`)})`,pe=`(?:${N.join(`|`)}) -?\\d+(?:\\.\\d+)?(?:%|°)`,F=RegExp(`^(${P}) (lighter|darker) (100(?:\\.0{1,3})?|[1-9]?\\d(?:\\.\\d{1,3})?)%$`,`u`),I=RegExp(`^(${P}|#[0-9A-Fa-f]{6})((?: ${pe})+)$`,`u`),L=/^#[0-9A-Fa-f]{6}$/u,R=e=>M.includes(e),me=e=>N.includes(e),z=new Set([`hue`,`hueOff`]);function B(e){if(R(e))return e;if(L.test(e))return{rgb:e.toUpperCase()};let t=I.exec(e);if(t){let[,e=``,n=``]=t,r=[];for(let e of n.matchAll(/ (\w+) (-?[\d.]+)(%|°)/gu)){let[,t=``,n=``,i]=e;if(!me(t)||i===`°`!==z.has(t))return;let a=Number(n);r.push({name:t,value:i===`%`?Math.round(a*1e3)/1e5:a})}return R(e)?{theme_color:e,transforms:r}:{rgb:e.toUpperCase(),transforms:r}}let n=F.exec(e),[,r=``,i,a=``]=n??[],o=Math.round(Number(a)*1e3);if(!(!n||!R(r)||o<=0||o>1e5))return{theme_color:r,brightness:(i===`lighter`?o:-o)/1e5}}var V=e=>z.has(e.name)?`${e.name} ${String(Math.round(e.value*1e3)/1e3)}°`:`${e.name} ${String(Math.round(e.value*1e5)/1e3)}%`;function he(e){if(typeof e==`string`)return e;if(`rgb`in e)return e.transforms&&e.transforms.length>0?`${e.rgb} ${e.transforms.map(V).join(` `)}`:e.rgb;if(`transforms`in e)return e.transforms.length===0?e.theme_color:`${e.theme_color} ${e.transforms.map(V).join(` `)}`;let t=Math.round(Math.abs(e.brightness)*1e5)/1e3;return t===0?e.theme_color:`${e.theme_color} ${e.brightness>0?`lighter`:`darker`} ${String(t)}%`}var H=`A colour is one of the theme's (${x.join(`, `)}) or the colour map's (${j.join(`, `)}), one of them lighter or darker by a share over 0 up to 100% ("accent1 lighter 40%", "dk1 darker 25%"), #RRGGBB, or one of them with DrawingML's transforms in order ("accent1 lumMod 75% lumOff 25%", "#4472C4 alpha 50%", "accent2 hueOff 30°": ${N.join(`, `)}).`,U=f([c(M),t().regex(F,H),t().regex(L,H),t().regex(I,H)]).refine(e=>B(e)!==void 0,H),W=`alphaLcParenBoth.alphaUcParenBoth.alphaLcParenR.alphaUcParenR.alphaLcPeriod.alphaUcPeriod.arabicParenBoth.arabicParenR.arabicPeriod.arabicPlain.romanLcParenBoth.romanUcParenBoth.romanLcParenR.romanUcParenR.romanLcPeriod.romanUcPeriod.circleNumDbPlain.circleNumWdBlackPlain.circleNumWdWhitePlain.arabicDbPeriod.arabicDbPlain.ea1ChsPeriod.ea1ChsPlain.ea1ChtPeriod.ea1ChtPlain.ea1JpnChsDbPeriod.ea1JpnKorPlain.ea1JpnKorPeriod.arabic1Minus.arabic2Minus.hebrew2Minus.thaiAlphaPeriod.thaiAlphaParenR.thaiAlphaParenBoth.thaiNumPeriod.thaiNumParenR.thaiNumParenBoth.hindiAlphaPeriod.hindiNumPeriod.hindiNumParenR.hindiAlpha1Period`.split(`.`),ge=[`sng`,`dbl`,`heavy`,`dotted`,`dottedHeavy`,`dash`,`dashHeavy`,`dashLong`,`dashLongHeavy`,`dotDash`,`dotDashHeavy`,`dotDotDash`,`dotDotDashHeavy`,`wavy`,`wavyHeavy`,`wavyDbl`,`words`],_e=[`sngStrike`,`dblStrike`],G=[`all`,`small`,`none`],ve=[`horz`,`vert`,`vert270`,`eaVert`,`wordArtVert`,`wordArtVertRtl`,`mongolianVert`],ye=[`t`,`ctr`,`b`],K=f([s().min(0).max(1584),r({lines:s().min(0).max(100)})]),q=p({size:s().positive().max(4e3).optional(),bold:a().optional(),italic:a().optional(),underline:f([a(),c(ge)]).optional(),strike:f([a(),c(_e)]).optional(),caps:c(G).optional(),color:U.optional(),font:t().min(1).optional(),align:c(se).optional(),line_spacing:s().positive().max(10).optional(),space_before:K.optional(),space_after:K.optional(),anchor:c(ye).optional(),orientation:c(ve).optional(),bullet:f([l(!1),t().min(1).max(2)]).optional(),numbered:c(W).optional(),bullet_color:U.optional(),bullet_size:s().min(.25).max(4).optional(),start_at:o().min(1).max(32767).optional()}),be=p({left:s().lt(1).optional(),top:s().lt(1).optional(),right:s().lt(1).optional(),bottom:s().lt(1).optional()}).refine(e=>(e.left??0)+(e.right??0)<1,{message:`left and right together cut the whole picture away`}).refine(e=>(e.top??0)+(e.bottom??0)<1,{message:`top and bottom together cut the whole picture away`}),J=d(()=>f([t(),s(),a(),i(),u(J),m(t(),J)])),Y=[`column-clustered`,`column-stacked`,`column-stacked-100`,`bar-clustered`,`bar-stacked`,`bar-stacked-100`,`line`,`line-markers`,`area`,`area-stacked`,`area-stacked-100`,`pie`,`doughnut`,`scatter`,`scatter-lines`,`scatter-smooth`],X=[`bottom`,`top`,`left`,`right`],Z=[`column-clustered`,`column-stacked`,`column-stacked-100`,`line`,`line-markers`,`area`,`area-stacked`,`area-stacked-100`],Q=p({min:s().optional(),max:s().optional(),major:s().positive().optional(),gridlines:a().optional(),visible:a().optional(),format:t().min(1).optional(),reverse:a().optional(),gridline_color:U.optional(),line_color:U.optional()}),xe=p({type:c(Y),data:t().min(1).optional(),categories:f([t().min(1),u(t())]).optional(),series:u(f([t().min(1),p({name:t().min(1),values:u(s().nullable()).optional(),x:u(s().nullable()).optional(),color:U.optional(),format:t().min(1).optional(),smooth:a().optional(),line_width:s().positive().optional(),marker_size:s().int().min(2).max(72).optional(),type:c(Z).optional(),secondary:a().optional()})])).min(1),legend:c(X).optional(),labels:f([a(),p({value:a().optional(),percentage:a().optional(),category:a().optional(),series:a().optional(),format:t().min(1).optional(),position:c([`outEnd`,`inEnd`,`ctr`,`inBase`,`t`,`b`,`l`,`r`,`bestFit`]).optional(),size:s().positive().optional(),color:U.optional()})]).optional(),gap_width:s().min(0).max(500).optional(),overlap:s().min(-100).max(100).optional(),vary_by_categories:a().optional(),category_colors:u(U).min(1).optional(),hole_size:s().min(10).max(90).optional(),value_axis:Q.optional(),category_axis:Q.optional(),secondary_axis:Q.optional(),size:s().positive().optional(),title_size:s().positive().optional(),color:U.optional()}),$=s().min(0).max(1),Se=[`circle`,`rect`,`shape`],Ce=p({angle:s().min(0).max(360).optional(),path:c(Se).optional(),focus:p({left:s().optional(),top:s().optional(),right:s().optional(),bottom:s().optional()}).optional(),stops:u(p({at:$,color:U,transparency:$.optional()})).min(2).max(10)}),we=`pct5.pct10.pct20.pct25.pct30.pct40.pct50.pct60.pct70.pct75.pct80.pct90.horz.vert.ltHorz.ltVert.dkHorz.dkVert.narHorz.narVert.dashHorz.dashVert.cross.dnDiag.upDiag.ltDnDiag.ltUpDiag.dkDnDiag.dkUpDiag.wdDnDiag.wdUpDiag.dashDnDiag.dashUpDiag.diagCross.smCheck.lgCheck.smGrid.lgGrid.dotGrid.smConfetti.lgConfetti.horzBrick.diagBrick.solidDmnd.openDmnd.dotDmnd.plaid.sphere.weave.divot.shingle.wave.trellis.zigZag`.split(`.`),Te=p({preset:c(we),fg:U.optional(),bg:U.optional()}),Ee=[`tl`,`t`,`tr`,`l`,`ctr`,`r`,`bl`,`b`,`br`],De=p({path:t().min(1),tile:p({scale_x:s().positive().max(100).optional(),scale_y:s().positive().max(100).optional(),x:s().optional(),y:s().optional(),align:c(Ee).optional()}).optional(),transparency:$.optional()}),Oe=p({fill:U.optional(),gradient:Ce.optional(),picture:t().min(1).optional()}).refine(e=>[e.fill,e.gradient,e.picture].filter(e=>e!==void 0).length===1,{message:`A background is a fill, a gradient or a picture: one of them.`}),ke=p({color:U.optional(),blur:s().min(0).max(100).optional(),distance:s().min(0).max(200).optional(),angle:s().min(0).max(360).optional(),transparency:$.optional()}),Ae=p({color:U.optional(),blur:s().min(0).max(100).optional(),distance:s().min(0).max(200).optional(),angle:s().min(0).max(360).optional(),transparency:$.optional()}),je=p({color:U.optional(),size:s().min(0).max(150).optional(),transparency:$.optional()}),Me=p({transparency:$.optional(),size:$.optional(),distance:s().min(0).max(100).optional(),blur:s().min(0).max(100).optional()}),Ne=f([p({shape:t().min(1),site:o().min(0)}),l(`none`)]),Pe=r({row:o().min(0),column:o().min(0),rows:o().min(1).optional(),columns:o().min(1).optional()});function Fe(e,t,n,r){let i=e.rows??1,a=e.columns??1;if(i*a<2)return`A merge takes two cells or more.`;if(e.row+i>t||e.column+a>n)return`A merge from row ${String(e.row)}, column ${String(e.column)} goes past the table's ${String(t)} rows and ${String(n)} columns.`;for(let t=e.row;t<e.row+i;t++)for(let n=e.column;n<e.column+a;n++){let e=`${String(t)},${String(n)}`;if(r.has(e))return`Two merges take the cell at row ${String(t)}, column ${String(n)}.`;r.add(e)}}var Ie=[`auto`,`on-click`],Le=p({start:c(Ie).optional(),trim:p({start:s().min(0).optional(),end:s().positive().optional()}).refine(e=>e.start===void 0||e.end===void 0||e.end>e.start,{message:`A trim ends after it starts.`}).optional(),loop:a().optional(),volume:s().min(0).max(1).optional(),fullscreen:a().optional(),hide:a().optional()}),Re=p({frame:fe.optional(),rotation:s().min(0).lt(360).optional(),flip_h:l(!0).optional(),flip_v:l(!0).optional(),connect:p({begin:Ne.optional(),end:Ne.optional()}).optional(),z:o().optional(),fill:f([U,l(`none`)]).optional(),fill_transparency:$.optional(),gradient:Ce.optional(),pattern:Te.optional(),picture_fill:De.optional(),shadow:ke.optional(),inner_shadow:Ae.optional(),glow:je.optional(),soft_edges:s().positive().max(100).optional(),reflection:Me.optional(),line:f([U,l(`none`)]).optional(),line_width:s().positive().max(1584).optional(),line_dash:c(w).optional(),line_cap:c(T).optional(),line_join:c(E).optional(),line_compound:c(D).optional(),line_begin:c(O).optional(),line_end:c(O).optional(),line_begin_size:A.optional(),line_end_size:A.optional(),text:q.optional(),textbox:l(!0).optional(),picture:t().min(1).optional(),crop:be.optional(),movie:t().min(1).optional(),audio:t().min(1).optional(),item:t().min(1).optional(),poster:s().min(0).optional(),playback:Le.optional(),geometry:c(ce).optional(),adjustments:u(s()).max(8).optional(),path:p({w:s().positive(),h:s().positive(),d:t().min(1)}).optional(),table:p({columns:u(s().positive()).min(1),rows:u(p({height:s().positive(),fill:U.optional(),text:q.optional(),line:U.optional()})).min(1),merged:u(Pe).optional(),data:t().min(1).optional(),fields:u(t().min(1)).min(1).optional(),head:a().optional(),style:t().min(1).optional(),first_row:a().optional(),last_row:a().optional(),first_col:a().optional(),last_col:a().optional(),horz_banding:a().optional(),vert_banding:a().optional()}).superRefine((e,t)=>{let n=new Set;e.data===void 0&&(e.fields!==void 0||e.head!==void 0)&&t.addIssue({code:`custom`,path:[e.fields===void 0?`head`:`fields`],message:`fields and head say how a table shows its data: give it data.`}),(e.merged??[]).forEach((r,i)=>{let a=Fe(r,e.rows.length,e.columns.length,n);a!==void 0&&t.addIssue({code:`custom`,path:[`merged`,i],message:a})})}).optional(),chart:xe.optional(),link:t().trim().min(1).optional(),group:t().regex(/^[A-Za-z0-9_-]+(?:\/[A-Za-z0-9_-]+)*$/u,`A group is a name of letters, digits, _ and -; a group in a group is outer/inner.`).optional(),locked:l(!0).optional(),component:f([b,t().regex(/^[^#\s]+\.[cm]?[jt]sx?(?:#[A-Za-z_$][\w$]*)?$/u,`A component is a name the deck's module registers, or a module's path and export: ../ui.ts#Dialog.`)]).optional(),props:m(t(),J).optional(),dur:s().positive().optional()}),ze=e=>e.split(`/`).map((e,t,n)=>n.slice(0,t+1).join(`/`)),Be=(e,t)=>e!==void 0&&(e===t||e.startsWith(`${t}/`)),Ve=[`firstslide`,`lastslide`,`nextslide`,`previousslide`,`endshow`],He=e=>`ppaction://hlinkshowjump?jump=${e}`;function Ue(e){let t=/^ppaction:\/\/hlinkshowjump\?jump=([a-z]+)$/u.exec(e);return Ve.find(e=>e===t?.[1])}var We=e=>e.startsWith(`#`)&&e.length>1?e.slice(1):void 0,Ge=[`textbox`,`picture`,`movie`,`audio`,`geometry`,`path`,`table`,`chart`,`component`,`item`],Ke=[`fade`,`push`,`wipe`,`split`,`reveal`,`cut`,`cover`,`uncover`,`zoom`,`morph`],qe=p({type:c(Ke),direction:c(C).optional(),through_black:l(!0).optional(),duration:s().min(0).optional()}),Je=p({shape:t().min(1),paragraph:o().min(0).optional(),effect:c(S),direction:c(C).optional(),amount:s().positive().max(36e3).optional(),start:c(de).optional(),duration:s().min(0).optional(),delay:s().min(0).optional(),path:t().min(1).optional(),animate_text:c(le).optional(),text_delay:s().min(0).max(100).optional(),repeat:f([s().min(1).max(1e4),c(ue)]).optional(),rewind:l(!0).optional()}),Ye=p({id:b,layout:t().min(1).optional(),generate:b.optional(),hidden:f([l(!0),u(t())]).optional(),shapes:m(t().min(1),Re).optional(),animations:u(Je).optional(),transition:qe.optional(),advance_after:s().min(0).max(86400).optional(),background:Oe.optional(),section:t().trim().min(1).max(255).optional()}),Xe=p({slides:u(Ye).default([])}).superRefine((e,t)=>{let n=new Set;e.slides.forEach((e,r)=>{n.has(e.id)&&t.addIssue({code:`custom`,path:[`slides`,r,`id`],message:`Two slides are "${e.id}".`}),n.add(e.id),(e.layout===void 0?0:1)+(e.generate===void 0?0:1)!=1&&t.addIssue({code:`custom`,path:[`slides`,r],message:`Slide ${e.id} has a layout or a generator: one of them.`}),e.hidden!==void 0&&e.generate===void 0&&e.hidden!==!0&&t.addIssue({code:`custom`,path:[`slides`,r,`hidden`],message:`Slide ${e.id} is hidden (true); a list of ids is a generated block's.`});for(let[n,i]of Object.entries(e.shapes??{})){let a=Ge.filter(e=>i[e]!==void 0);a.length>1&&t.addIssue({code:`custom`,path:[`slides`,r,`shapes`,n],message:`Shape ${n} is one kind of shape, not ${a.join(` and `)}.`});let o=n.includes(`/`)?n.split(`/`):[n];(!(o.length<=2&&o.every(e=>g.test(e)))||o.length===2&&e.generate===void 0)&&t.addIssue({code:`custom`,path:[`slides`,r,`shapes`,n],message:`A shape's name is letters, digits, _ and -; <slide>/<shape> only in a generated block.`})}})});export{Ue as A,Ee as C,ze as D,B as E,oe as M,y as N,Be as O,re as P,x as S,he as T,Y as _,M as a,Ye as b,Se as c,w as d,O as f,we as g,W as h,X as i,We as j,He as k,T as l,Ie as m,G as n,N as o,E as p,Z as r,xe as s,S as t,D as u,Ve as v,ge as w,Xe as x,Ke as y};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{E as e,S as t,T as n,_ as r,a as i,c as a,d as o,g as s,h as c,i as l,it as ee,m as u,n as d,o as f,s as p,t as m,u as te,w as h,x as g,y as _}from"./iso-ahTwmFwH.js";g({jsonrpc:u(`2.0`),id:h([t(),o()]),method:t().min(1),params:n().optional()}),g({jsonrpc:u(`2.0`),method:t().min(1),params:n().optional()});var ne=g({code:o(),message:t(),data:n().optional()});h([g({jsonrpc:u(`2.0`),id:h([t(),o()]),result:n()}),g({jsonrpc:u(`2.0`),id:h([t(),o(),i()]),error:ne})]);var v={parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603,conflict:-32001,notFound:-32002,invalid:-32003,forbidden:-32004,unavailable:-32005},y=(e,t,n)=>({params:e,result:t,about:n}),b=(e,t)=>({params:e,about:t}),x=class extends Error{code;data;constructor(e,t,n){super(t),this.name=`RpcError`,this.code=e,this.data=n}};async function re(e,t,n){let{id:r}=n,i=Object.hasOwn(e,n.method)?e[n.method]:void 0;if(!i)return{jsonrpc:`2.0`,id:r,error:{code:v.methodNotFound,message:`There is no method "${n.method}".`}};let a=i.params.safeParse(n.params??{});if(!a.success)return{jsonrpc:`2.0`,id:r,error:{code:v.invalidParams,message:ee(a.error)}};try{let e=t[n.method],o=await e(a.data);return{jsonrpc:`2.0`,id:r,result:i.result.parse(o)}}catch(e){return e instanceof x?{jsonrpc:`2.0`,id:r,error:{code:e.code,message:e.message,...e.data===void 0?{}:{data:e.data}}}:{jsonrpc:`2.0`,id:r,error:{code:v.internal,message:e instanceof Error?e.message:String(e)}}}}var S=t().min(1).refine(e=>!e.startsWith(`/`)&&!e.split(`/`).includes(`..`),{message:`A path is inside the project.`}),C=h([u(``),S]),w=t().regex(/^[0-9a-f]{64}$/u).nullable(),ie=g({kind:l([`person`,`agent`,`tool`]),name:t().min(1)}),ae=g({path:S,size:o().nonnegative(),modified:s()}),oe={"files/read":y(g({path:S}),g({text:t(),version:w}),`A text file, with its version; a file that is not there reads as empty with version null.`),"files/write":y(g({path:S,text:t(),over:w}),g({version:w}),`Writes a text file over the version read. Errors: conflict (data: { text, version }) when it changed; invalid (data: { problems }) when its format refuses it.`),"files/upload":y(g({dir:S,name:t().min(1),data:p()}),g({path:S}),`Keeps a file the person added, under a free name in the folder.`),"files/url":y(g({path:S}),g({url:t()}),`An address a page can load the file from (a picture, a video).`),"files/list":y(g({dir:t()}),g({files:f(ae),dirs:f(S)}),`A folder's files and folders, as on disk.`),"files/move":y(g({from:S,to:S}),g({rewritten:f(S)}),`Moves a file or a folder, and rewrites the relative imports and links that pointed at it, as an editor does.`),"files/remove":y(g({path:S}),g({trash:t()}),`Moves a file or folder to the recycle bin (nothing is deleted).`),"files/trash":y(g({}),g({entries:f(g({id:t(),path:S,removed:s()}))}),`What the recycle bin holds.`),"files/restore":y(g({id:t()}),g({path:S}),`Puts a removed thing back where it was; refused while something is there.`),"files/watch":y(g({paths:f(S).min(1)}),g({watch:t()}),"Starts telling `files/changed` for these files or folders."),"files/unwatch":y(g({watch:t()}),g({}),`Stops a watch.`)},se={"files/changed":b(g({watch:t(),changes:f(g({path:S,version:w,by:ie.optional()}))}),`Files under a watch changed, other than by this client's own writes.`)},ce=r({name:t().min(1),only:f(t().min(1)),values:f(t().min(1)).optional()}),le=r({types:f(t().min(1)),extras:f(t().min(1)),options:f(ce),names:_(t(),_(t(),t())).optional()}),T={noun:t().min(1),icon:t().min(1).optional(),color:t().min(1).optional(),editor:t().min(1).optional(),exports:le.optional(),share:a().optional()},ue=r({name:t().min(1),...T}),E=r({name:_(t(),t().min(1)),plural:_(t(),t().min(1)).optional(),starter:r({files:_(t().min(1),t()),entry:t().min(1)}).optional(),order:s().optional(),turnInto:a().optional(),...T}),de=E.extend({id:t().min(1)}),D=(e,t)=>e.name[t]??e.name.en??e.noun,fe=/\.(ya?ml|json)$/u;function pe(e,t,n,r){let i=e=>e.replaceAll(`{{locale}}`,n).replaceAll(`{{name}}`,r);return{files:Object.entries(e.files).map(([e,a])=>{let o=i(e),s=fe.test(o)?JSON.stringify(t):t;return{path:o,text:a.replaceAll(`{{locale}}`,n).replaceAll(`{{name}}`,r).replaceAll(`{{title}}`,()=>s)}}),entry:i(e.entry)}}function me(e,t,n){return t===void 0?{name:e??`file`,noun:e??`file`}:{name:D(t,n),noun:t.noun,...t.icon===void 0?{}:{icon:t.icon},...t.color===void 0?{}:{color:t.color},...t.editor===void 0?{}:{editor:t.editor},...t.exports===void 0?{}:{exports:t.exports},...t.share===void 0?{}:{share:t.share}}}function he(e){return e.kindInfo?.exports===void 0?e.kind===void 0?`file as it is`:`nothing`:`formats`}var ge=[`script`,`style`,`font`,`img`,`media`,`connect`],_e=[`agent`,`project`,`piece`,`plugin`,`skill`,`website`,`studio`],ve=[`download`,`wake`,`export`,`update`,`install`,`start`,`publish`],ye=[`queued`,`running`,`paused`,`done`,`failed`,`cancelled`],be=[`bytes`,`files`,`share`],O=[`offline`,`no-space`,`no-credits`,`unavailable`,`other`],k=[`first-setup`],A=g({kind:l(_e),id:t()}),j=g({id:t(),about:A,what:l(ve),name:t().optional(),state:l(ye),completed:s().min(0),total:s().min(0).optional(),unit:l(be),left:s().min(0).optional(),stalled:a().optional(),step:l(k).optional(),cancellable:a(),pausable:a().optional(),quiet:a().optional(),retryable:a(),failure:g({reason:l(O),details:t()}).optional(),made:t().optional(),started:s(),ended:s().optional()}),M=g({mime:t().regex(/^image\//u),data:p()}),N=te(`type`,[g({type:u(`picture`),image:M,width:o().positive(),height:o().positive(),duration:s().nonnegative().optional()}),g({type:u(`text`),lines:f(t())}),g({type:u(`table`),columns:f(t()),rows:f(f(t())),count:o().nonnegative()})]);g({id:S,kind:t().min(1),dir:C,entry:S,title:t().optional()});var P={item:S,version:t().optional()},xe=c({code:t(),level:l([`error`,`warn`]),message:t(),piece:t().optional(),part:t().optional(),t:s().optional()}),Se=c({kind:t(),data:n()}),F=g({status:l([`off`,`waiting`,`running`,`done`,`failed`]),revision:o().nonnegative(),problems:f(xe),facts:f(Se),versions:g({total:o(),loaded:o(),reused:o()}).optional(),error:t().optional()}),Ce=[`queued`,`running`,`done`,`failed`,`cancelled`],I=_(t(),h([t(),a()])),L=g({id:t(),item:S,versions:f(t()),types:f(t()),options:I.optional(),state:l(Ce),progress:s().min(0).max(1),files:f(S),error:t().optional()}),we=g({file:S,status:l([`running`,`done`,`failed`]),message:t(),share:s().min(0).max(1).optional()}),R=g({url:t(),probe:t()}),Te={"project/items":y(g({}),g({items:f(g({id:S,kind:t().min(1).optional(),dir:C,entry:S,title:t().optional(),groups:f(t()),files:f(r({path:t().min(1),role:t().min(1).optional()})).optional(),kindInfo:E.optional()})),kinds:f(de).optional(),name:t(),scope:t(),revision:o().nonnegative()}),`The project's items, as its list (allyhub.yaml) names them, in its order: each a file of a kind, or a file an editor opens by its name.`),"project/file":y(g({path:S}),g({item:g({id:S,kind:t().min(1).optional(),dir:C,entry:S,title:t().optional(),groups:f(t()),kindInfo:E.optional()})}),"A file of the project as it opens in an editor, whether the list names it or not: the item it is, else the file in the editor that opens it by its name (an `editors` contribution's `files`); not found for a file that is not there or that no editor opens."),"items/preview":y(g({item:S}),g({preview:N.optional()}),`What an item looks like (named by its id or its file), as its kind's provider makes it from its files now (a video's still, an image's boards, a deck's slide, a doc's first paragraphs, a sheet's first rows); none where its kind gives none.`),"items/page":y(g({item:S,folder:C.optional(),file:S.optional()}),g({url:t()}),"The address of an item's page, for a frame (a report's page, a website built as files): `folder` served as the root of an origin of its own, the project's files alone (no other address loads), every file the page loads recorded as the item's input, so the item's editors hear `items/changed` when one changes."),"work/add":y(g({kind:t().min(1),file:S,title:t().min(1).optional()}),g({}),`Adds a piece to the end of the project's list (allyhub.yaml), the rest of it as it was; nothing when its file is listed already.`),"components/list":y(g({item:S}),g({components:f(g({of:t(),name:t(),label:h([t(),_(t(),t())]).optional()}))}),`The components an item may place: every one the project's files define, by the reference it would write.`),"components/stage":y(g(P),R,"The address of a page that draws an item's components one at a time, for a sandboxed frame (docs/design/components-everywhere.md): a deck's by the name its module gives it, a doc's by the reference its block writes. Its parent posts `{ type: \"component\", name, props, width, height, t }` and hears `component-ready`, or `error` with what went wrong."),"components/stills":y(g({...P,components:f(g({name:t(),props:_(t(),n()),width:s().positive(),height:s().positive(),t:s().nonnegative()})).min(1).max(64)}),g({stills:f(g({key:t(),url:e()}).nullable())}),`An item's components (a deck's, a doc's) drawn alone, transparent, as the render draws them: pictures kept by what they show, given as addresses.`),"check/results":y(g({}),F,`The check run after edits, as it stands.`),"check/run":y(g({}),g({}),`Runs the check again now.`),"export/start":y(g({item:S,versions:f(t()).optional(),types:f(t().min(1)).max(10).optional(),options:I.optional()}),g({job:L}),"Exports an item (its versions, as file types) into .allyhub/out/; `export/changed` says how it goes."),"export/cancel":y(g({job:t()}),g({}),`Stops an export.`),"export/list":y(g({}),g({jobs:f(L),reveal:a()}),`The exports asked for since the server started.`),"export/reveal":y(g({path:S}),g({}),"Shows an exported file in the person's file manager, where the server runs on their computer (`export/list`'s `reveal`).")},Ee={"project/items":`project`,"project/file":`asleep`,"items/preview":`asleep`,"items/page":`asleep`,"work/add":`machine`,"components/list":`asleep`,"components/stage":`asleep`,"components/stills":`project`,"check/results":`project`,"check/run":`machine`,"export/start":`machine`,"export/cancel":`machine`,"export/list":`asleep`,"export/reveal":`machine`};function De(e){return async(t,n,r)=>{let{result:i}=await t[`tools/call`]({name:n,arguments:r}),a=e[n]?.result.safeParse(i);if(!a?.success)throw new x(v.internal,`The answer to the tool ${n} is not what the protocol says.`);return a.data}}var Oe={"project/changed":b(g({revision:o().nonnegative()}),`The build saw a change: a stage or a timeline asked for now is the new one's.`),"items/changed":b(g({item:S,paths:f(t())}),`One of an item's inputs changed (docs/design/item-files.md, "An item's inputs"): a file its build lists, or one its pages loaded.`),"check/changed":b(F,`The check started, ended or failed.`),"export/changed":b(g({job:L}),`An export moved on.`),"index/changed":b(g({jobs:f(we)}),`Making what the media index lacks moved on.`),"jobs/changed":b(g({job:j,item:S}),`A job of the process the server runs in (docs/design/jobs.md: a website starting, an export) moved on, about a thing in this project: what the window lists, for the editor of that thing to show where the person waits on it.`)},z=e=>h([l(e),t().min(1).brand()]),B=e=>f(n()).transform(t=>t.flatMap(t=>{let n=e.safeParse(t);return n.success?[n.data]:[]})),ke=[`no_card`,`saving_card`,`not_a_card`,`declined`,`needs_authentication`,`not_charged`,`under_line`,`refunded`,`disputed`,`monthly_limit`],V=[`month`,`year`];r({credits:s(),held:s(),owed:s(),frozen:t().nullable().default(null),plan:r({id:t(),name:t(),interval:z(V),status:t(),renewsAt:d().nullable(),endsAt:d().nullable(),monthlyCredits:s().default(0),price:r({amountCents:s(),currency:t()}).nullable().default(null)}).nullable(),allowance:r({total:s(),used:s(),renewsAt:d()}).nullable().default(null),bought:s().default(0),expiring:f(r({credits:s(),expiresAt:d()})).default([]),customer:a().default(!1),autoTopUp:r({below:s(),amountCents:s(),monthlyLimitCents:s().nullable().default(null),chargedThisMonthCents:s().default(0),stopped:z(ke).nullable()}).nullable()}),r({plans:f(r({id:t(),name:t(),family:t().nullable().default(null),recommended:a().default(!1),monthlyCredits:s(),storageBytes:s().optional(),prices:f(r({interval:z(V),amountCents:s(),currency:t()}))})),topUp:r({currency:t(),creditsPerDollar:s(),minCents:s(),maxCents:s(),presetsCents:f(s()).default([])}),welcomeCredits:s().optional(),freeStorageBytes:s().optional()}),r({days:f(r({day:m(),credits:s(),byKind:_(t(),s()).default({})}))}),r({spends:f(r({at:t(),kind:z([`models`,`tools`,`studio`,`other`]),what:t().nullable(),seconds:s().nullable(),member:t().nullable(),credits:s()})),more:a()}),h([g({plan:t(),interval:l(V)}),g({topUpCents:s().int()})]),h([g({flow:l([`home`,`payment_method`,`cancel`])}),g({flow:u(`change_plan`),plan:t(),interval:l(V)})]).default({flow:`home`}),r({card:r({brand:t(),last4:t(),expMonth:s(),expYear:s()}).nullable(),email:t().nullable()}),r({invoices:f(r({id:t(),number:t().nullable(),createdAt:t(),kind:z([`plan`,`credits`]),totalCents:s(),currency:t(),status:t(),pdf:t().nullable(),url:t().nullable()}))}),g({topUpCents:s().int()}),g({below:s().nonnegative(),amountCents:s().int().positive(),monthlyLimitCents:s().int().positive().nullable().optional(),newCard:a().optional()});var H={tier:z([`premium`,`standard`,`efficient`]).optional(),maker:t().min(1).optional(),retired:a().optional()},Ae=r({type:z([`toggle`,`effort`,`budget_tokens`]),values:f(t().min(1)).optional(),min:s().int().nonnegative().optional(),max:s().int().positive().optional()});r({models:f(c({id:t().min(1),name:t().min(1),...H,reasoning:a().optional(),reasoningOptions:B(Ae).optional(),input:f(t()).optional(),contextWindow:s().int().positive().optional(),maxOutput:s().int().positive().optional()})).min(1),defaultModel:t().min(1),needPlan:f(c({id:t().min(1),name:t().min(1),...H})).default([])});var U=_(t(),n()),je=[`call`,`result`,`page`,`second`,`minute`,`thousand_characters`,`image`,`frame`,`megapixel`,`question`,`phrase`],Me=[`video`,`image`,`voice`,`music`],Ne=r({id:t().min(1),title:t().min(1),description:t().min(1),kind:z([`data`,`ai`]).default(`data`),line:t().optional()}),Pe=r({name:t().min(1),work:t().min(1),title:t().min(1),description:t().min(1),input:U,output:U,long:a(),example:_(t(),n()).optional(),price:r({credits:s().nonnegative(),per:z(je),varies:a()}).optional(),shown:r({name:t(),line:t(),section:z(Me)}).optional()});r({version:t().min(1),works:f(Ne),tools:f(Pe)}),r({off:r({works:f(t()),tools:f(t())})}),h([g({work:t().min(1),on:a()}),g({tool:t().min(1),on:a()})]),r({editors:f(r({id:t().min(1),name:_(t(),t()),plural:_(t(),t()).optional(),line:_(t(),t()),icon:t().optional(),color:t().optional()}))}),g({input:_(t(),n())}),r({id:t().min(1),tool:t().min(1),status:z([`working`,`completed`,`failed`]),output:n().optional(),error:r({kind:t().min(1),message:t().min(1)}).optional(),credits:s().nonnegative().optional(),pollAfterMs:s().int().nonnegative().optional(),createdAt:t(),endedAt:t().optional()});var W=1073741824;g({name:t().min(1).max(255),size:o().positive().max(W),sha256:t().regex(/^[0-9a-f]{64}$/u),contentType:t().min(1).max(255)}),r({id:t().min(1),upload:r({url:e(),headers:_(t(),t())}).nullable()}),r({id:t().min(1),name:t()}),r({url:e()});var G=t().regex(/^[0-9a-f]{64}$/u),K=t().min(1).max(1024).refine(e=>!e.startsWith(`/`)&&!e.includes(`\\`)&&e.split(`/`).every(e=>e!==``&&e!==`.`&&e!==`..`),`a relative path of forward slashes, without . or ..`),q=r({sha256:G,size:o().nonnegative().max(W)}),J=q.extend({type:t().min(1).max(255),immutable:u(!0).optional()});g({blobs:f(q.extend({contentType:t().min(1).max(255)})).min(1).max(1e3)}),r({uploads:f(r({sha256:G,url:e(),headers:_(t(),t())}))});var Fe=r({sessionId:t().min(1),agent:t().min(1),title:t().optional(),createdAt:d(),updatedAt:d(),transcript:G});r({sessionId:t().min(1),messages:f(r({method:t().min(1),params:n()}))});var Y=[`project`,`home`];t().regex(/^[a-z][a-z0-9-]*\/$/u,`one lower-case word and /`).refine(e=>!Object.values(X).includes(e)&&!Object.values($).includes(e),`a folder of the core's`),z(ge);var Ie=_(t(),f(t())),Le=t().refine(e=>e.endsWith(`/`)&&K.safeParse(e.slice(0,-1)).success,`a folder of the tree, ending in /`),Re=r({tree:f(K),files:f(K),own:_(K,J)}),ze=r({shared:f(Le),items:_(t(),Re)}),Be=r({format:u(1),kind:l(Y),project:r({name:t().min(1).max(255)}),host:r({version:t().min(1)}),madeAt:d(),files:_(K,q),tree:_(K,J),conversations:f(Fe),reach:ze.optional(),routes:Ie.optional()}),X={editor:`editor/`,runtime:`runtime/`,build:`build/`,media:`media/`,matte:`matte/`,stills:`stills/`,answers:`answers/`,previews:`previews/`};function Z(e){return Array.isArray(e)?e.map(Z):typeof e==`object`&&e?Object.fromEntries(Object.keys(e).sort().map(t=>[t,Z(e[t])])):e}var Ve=(e,t)=>`${X.answers}${e}/${encodeURIComponent(JSON.stringify(Z(t??{})))}.json`,He=r({result:n().optional(),error:r({code:s(),message:t(),data:n().optional()}).optional()}),Ue=e=>`${X.stills}${e}.webp`,We=(e,t)=>`${X.stills}index/${encodeURIComponent(e)}/${encodeURIComponent(t)}.json`,Ge=r({stills:_(t(),t().regex(/^[0-9a-f]{64}$/u))}),Q=e=>JSON.stringify(Z(e)),Ke=r({name:t(),props:_(t(),n()),width:s().positive(),height:s().positive(),t:s().nonnegative()});r({stills:f(r({version:t(),components:f(Ke)})).optional(),shows:r({media:f(t()),data:f(t())}).optional(),routes:_(t(),f(t().min(1))).optional(),page:r({folder:t().optional(),file:t().optional()}).optional()}),`${X.runtime}`,`${X.runtime}`,`${X.runtime}`;var qe=e=>e.split(`/`).map(encodeURIComponent).join(`/`),Je=r({kind:z([`cloud`,`computer`]),here:a()});g({project:g({id:t().min(1).optional(),idMadeByMachine:a().optional(),kind:l(Y),name:t().min(1).max(255)}),manifest:G}),r({id:t().min(1),projectId:t().min(1)}),r({missing:f(G)});var Ye=r({id:t().min(1),madeAt:d(),hostVersion:t()}),Xe=r({id:t().min(1),kind:l(Y),name:t(),latest:Ye.nullable(),executor:Je.optional()});r({projects:B(Xe)}),r({keptBytes:s(),capBytes:s().nullable(),clearingBytes:s().optional()}),g({page:o().min(1)});var Ze=r({id:t().min(1),kind:l(Y),name:t(),bytes:s(),versions:s(),madeAt:d().nullable()});r({items:B(Ze),total:s()});var Qe=r({id:t().min(1),name:t(),contentType:t(),size:s(),keptUntil:d()});r({items:B(Qe),total:s()}),r({origin:e(),expiresAt:d()});var $={manifest:`manifest.json`,files:`files/`,pages:`pages/`,conversations:`conversations/`},$e=-32010,et=e=>typeof e==`object`&&!!e&&e.code===-32010;export{C as A,ue as C,pe as D,D as E,y as F,b as I,v as M,x as N,oe as O,re as P,M as S,me as T,Te as _,Ge as a,P as b,Ue as c,qe as d,G as f,R as g,z as h,Be as i,S as j,se as k,Q as l,K as m,He as n,et as o,J as p,$ as r,Ve as s,$e as t,We as u,Ee as v,he as w,De as x,Oe as y};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-COiEfhsA.js";import{u as t,
|
|
1
|
+
import{i as e}from"./rolldown-runtime-COiEfhsA.js";import{u as t,y as n}from"./react-Edyoga_4.js";import{t as r}from"./jsx-runtime-DePvh3-m.js";import{t as i}from"./audio-lines-PZj77e7t.js";var a=r(),o=e(n(),1);function s(e){let n=(0,o.useRef)(null),r=(0,o.useRef)(!1);return t({element:()=>n.current,hold:()=>{let e=n.current;return r.current=e!==null&&!e.paused,e?.pause(),Promise.resolve()},release:()=>{r.current&&n.current?.play().catch(()=>void 0),r.current=!1}}),(0,a.jsxs)(`div`,{className:`flex size-full flex-col items-center justify-center gap-3 p-3`,"data-testid":`media-sound`,children:[(0,a.jsx)(i,{className:`text-lead size-8`,"aria-hidden":!0}),(0,a.jsx)(`audio`,{ref:n,src:e.url,controls:!0,preload:`metadata`,className:`w-full max-w-72`,onPointerDown:e=>{e.stopPropagation()}})]})}export{s as default};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-COiEfhsA.js";import{
|
|
1
|
+
import{i as e}from"./rolldown-runtime-COiEfhsA.js";import{o as t,s as n,u as r,v as i,y as a}from"./react-Edyoga_4.js";import{yt as o}from"./x-DlhyIKuu.js";import{t as s}from"./jsx-runtime-DePvh3-m.js";import{S as c,x as l,y as u}from"./dist-BEpzsYn_.js";import{t as d}from"./createLucideIcon-lm_6n8YT.js";import{A as f,o as p}from"./index-DG2nHq4D.js";import{t as m}from"./row-C_svyL8o.js";import{t as h}from"./textarea-D7TnPwv1.js";var g=d(`image-plus`,[[`path`,{d:`M16 5h6`,key:`1vod17`}],[`path`,{d:`M19 2v6`,key:`4bpg5p`}],[`path`,{d:`M21 11.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7.5`,key:`1ue2ih`}],[`path`,{d:`m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21`,key:`1xmnt7`}],[`circle`,{cx:`9`,cy:`9`,r:`2`,key:`af1f0g`}]]),_=e(a(),1),v=s(),y=o({en:{find:`Find`,items:`Items`,files:`Files`,nothing:`Nothing found`,altText:`Alt text`,altHint:`What the picture shows, for someone who cannot see it`,panes:`Resize the panes`},"zh-cn":{find:`查找`,items:`作品`,files:`文件`,nothing:`未找到`,altText:`替代文本`,altHint:`图片里有什么,写给看不见它的人`,panes:`调整两栏宽度`},"zh-tw":{find:`尋找`,items:`作品`,files:`檔案`,nothing:`找不到任何結果`,altText:`替代文字`,altHint:`圖片中有什麼,寫給看不見它的人`,panes:`調整兩欄寬度`},ja:{find:`検索`,items:`作品`,files:`ファイル`,nothing:`見つかりませんでした`,altText:`代替テキスト`,altHint:`画像に写っているもの。見ることができない人のために`,panes:`ペインの幅を変える`},ko:{find:`찾기`,items:`작업물`,files:`파일`,nothing:`찾은 항목 없음`,altText:`대체 텍스트`,altHint:`사진이 보여 주는 내용, 볼 수 없는 사람을 위해`,panes:`창 크기 조절`},es:{find:`Buscar`,items:`Elementos`,files:`Archivos`,nothing:`No se encontró nada`,altText:`Texto alternativo`,altHint:`Lo que muestra la imagen, para quien no puede verla`,panes:`Ajustar los paneles`},fr:{find:`Chercher`,items:`Éléments`,files:`Fichiers`,nothing:`Aucun résultat`,altText:`Texte alternatif`,altHint:`Ce que montre l’image, pour qui ne peut pas la voir`,panes:`Redimensionner les panneaux`},de:{find:`Suchen`,items:`Werke`,files:`Dateien`,nothing:`Nichts gefunden`,altText:`Alt-Text`,altHint:`Was das Bild zeigt, für jemanden, der es nicht sehen kann`,panes:`Bereiche anpassen`},pt:{find:`Procurar`,items:`Itens`,files:`Arquivos`,nothing:`Nada encontrado`,altText:`Texto alternativo`,altHint:`O que a imagem mostra, para quem não pode vê-la`,panes:`Redimensionar os painéis`}});function b(){return y.of(n()?.locale)}function x({alt:e,onAlt:t,trigger:n,most:r}){let i=b(),[a,o]=(0,_.useState)(!1),[s,d]=(0,_.useState)(e);return(0,v.jsxs)(u,{open:a,onOpenChange:n=>{o(n),n?d(e):s!==e&&t(s)},children:[(0,v.jsx)(c,{asChild:!0,children:n}),(0,v.jsx)(l,{className:`w-80`,align:`start`,children:(0,v.jsxs)(`label`,{className:`flex flex-col gap-1.5 text-sm`,children:[(0,v.jsx)(`span`,{className:`font-medium`,children:i.altText}),(0,v.jsx)(h,{autoFocus:!0,value:s,placeholder:i.altHint,maxLength:r,onFocus:e=>{let t=e.currentTarget.value.length;e.currentTarget.setSelectionRange(t,t)},onChange:e=>{d(e.target.value)},onBlur:()=>{s!==e&&t(s)}})]})})]})}function S({file:e,...t}){let n=(0,_.useRef)(null),a=(0,_.useRef)(!1);return r({element:()=>n.current,hold:()=>{let e=n.current;return a.current=e!==null&&!e.paused,e?.pause(),Promise.resolve()},release:()=>{a.current&&n.current?.play().catch(()=>void 0),a.current=!1},pictures:()=>{let e=n.current,t=e?i(e):void 0;return Promise.resolve(t?[t]:[])},locate:()=>{let t=e===void 0?`the video`:`the video ${e}`;return Promise.resolve({elements:[{name:t}],where:`on ${t} at ${(n.current?.currentTime??0).toFixed(2)} s`})}}),(0,v.jsx)(`video`,{ref:n,...t})}var C=(e,t)=>(0,v.jsx)(S,{...e,file:t});function w(e,t){let n=e===``?[]:e.split(`/`);for(let e of t.split(`#`)[0]?.split(`/`)??[])if(e!==``&&e!==`.`){if(e===`..`){if(n.length===0)return;n.pop()}else n.push(e)}return n.join(`/`)}function T(e,t){let n=e===``?[]:e.split(`/`),r=t.split(`/`),i=0;for(;i<n.length&&i<r.length-1&&n[i]===r[i];)i++;let a=[...n.slice(i).map(()=>`..`),...r.slice(i)].join(`/`);return a.startsWith(`../`)?a:`./${a}`}var E=e=>e.includes(`#`)||/\.(?:[cm]?[jt]s|tsx|jsx)$/iu.test(e);async function D(e,t,n){let r=w(t,n);if(r===void 0)return;if(!E(n))return(await e[`files/url`]({path:r}).catch(()=>void 0))?.url;let i=(await f(e,`items/preview`,{item:r}).catch(()=>void 0))?.preview;return i?.type===`picture`?`data:${i.image.mime};base64,${i.image.data}`:void 0}function O(e,n){let r=t(),[i,a]=(0,_.useState)(new Map),o=[...new Set(n)].sort().join(`
|
|
2
2
|
`);return(0,_.useEffect)(()=>{let t=!0,n=o===``?[]:o.split(`
|
|
3
|
-
`);return Promise.all(n.map(async t=>[t,await D(r,e,t)])).then(e=>{t&&a(new Map(e.flatMap(([e,t])=>t===void 0?[]:[[e,t]])))}),()=>{t=!1}},[r,e,o]),i}async function k(e,t,n,r=3){let i=await e(t).catch(()=>({files:[],dirs:[]})),a=i.files.map(e=>e.path).filter(n);if(r===0)return a;let o=await Promise.all(i.dirs.filter(e=>!e.split(`/`).some(e=>e.startsWith(`.`)||e===`node_modules`)).map(t=>k(e,t,n,r-1)));return[...a,...o.flat()]}var A=e=>e.split(`.`).pop()?.toLowerCase()??``;function j(e){let
|
|
3
|
+
`);return Promise.all(n.map(async t=>[t,await D(r,e,t)])).then(e=>{t&&a(new Map(e.flatMap(([e,t])=>t===void 0?[]:[[e,t]])))}),()=>{t=!1}},[r,e,o]),i}async function k(e,t,n,r=3){let i=await e(t).catch(()=>({files:[],dirs:[]})),a=i.files.map(e=>e.path).filter(n);if(r===0)return a;let o=await Promise.all(i.dirs.filter(e=>!e.split(`/`).some(e=>e.startsWith(`.`)||e===`node_modules`)).map(t=>k(e,t,n,r-1)));return[...a,...o.flat()]}var A=e=>e.split(`.`).pop()?.toLowerCase()??``;function j(e){let n=b(),r=t(),[i,a]=(0,_.useState)(``),[o,s]=(0,_.useState)([]),[c,l]=(0,_.useState)([]),u=e.types.join(`,`);(0,_.useEffect)(()=>{let e=!0,t=u.split(`,`);return k(e=>r[`files/list`]({dir:e}),``,e=>t.includes(A(e))).then(t=>{e&&s([...new Set(t)].sort())}),f(r,`project/items`,{}).then(t=>{e&&l(t.items)},()=>void 0),()=>{e=!1}},[r,u]);let d=i.trim().toLowerCase(),h=(0,_.useMemo)(()=>c.filter(t=>t.kind!==void 0&&t.entry!==e.self&&(t.kindInfo?.exports?.types??[]).some(t=>e.types.includes(t))&&(d===``||t.id.toLowerCase().includes(d)||(t.title??``).toLowerCase().includes(d))),[c,e.self,e.types,d]),g=o.filter(t=>e.types.includes(A(t))&&(d===``||t.toLowerCase().includes(d))),y=(t,n,r,i)=>(0,v.jsx)(m,{title:r,meta:(0,v.jsx)(`span`,{className:`text-lead max-w-32 truncate text-xs`,children:r}),onClick:()=>{e.onPick(i)},children:(0,v.jsx)(`span`,{className:`truncate`,children:n})},t);return(0,v.jsxs)(`div`,{className:`flex w-80 flex-col gap-2`,"data-testid":e.testId,children:[(0,v.jsx)(p,{autoFocus:!0,value:i,placeholder:n.find,"aria-label":n.find,onChange:e=>{a(e.target.value)}}),(0,v.jsxs)(`div`,{className:`flex h-72 flex-col overflow-y-auto`,children:[h.length>0&&(0,v.jsx)(`p`,{className:`text-lead px-2 pt-1 text-xs font-semibold`,children:n.items}),h.map(e=>y(`i:${e.id}`,e.title??e.id,e.entry,e.entry)),g.length>0&&(0,v.jsx)(`p`,{className:`text-lead px-2 pt-2 text-xs font-semibold`,children:n.files}),g.map(e=>y(`f:${e}`,e.split(`/`).pop()??e,e,e)),h.length===0&&g.length===0?(0,v.jsx)(`p`,{className:`text-lead px-2 py-6 text-center text-sm`,children:n.nothing}):null]})]})}var M=.3,N=.7;function P({edit:e,preview:t,width:n,background:r,testId:i}){let a=b(),[o,s]=(0,_.useState)(.5),[c,l]=(0,_.useState)(1),u=(0,_.useRef)(null),d=(0,_.useRef)(null);(0,_.useEffect)(()=>{let e=d.current;if(e===null)return;let t=()=>{l(Math.min(1,Math.max(.3,(e.clientWidth-32)/n)))};t();let r=new ResizeObserver(t);return r.observe(e),()=>{r.disconnect()}},[n]);let f=e=>Math.min(N,Math.max(M,e));return(0,v.jsxs)(`div`,{ref:u,className:`flex min-h-0 flex-1`,children:[(0,v.jsx)(`div`,{className:`min-w-0 overflow-y-auto`,style:{flexBasis:`${String(o*100)}%`},children:e}),(0,v.jsx)(`div`,{role:`separator`,"aria-orientation":`vertical`,"aria-label":a.panes,"aria-valuenow":Math.round(o*100),"aria-valuemin":M*100,"aria-valuemax":N*100,tabIndex:0,className:`ak-post-split-rule`,onPointerDown:e=>{let t=u.current?.getBoundingClientRect();if(t===void 0)return;e.currentTarget.setPointerCapture(e.pointerId);let n=e=>{s(f((e.clientX-t.left)/t.width))},r=()=>{window.removeEventListener(`pointermove`,n),window.removeEventListener(`pointerup`,r)};window.addEventListener(`pointermove`,n),window.addEventListener(`pointerup`,r)},onKeyDown:e=>{if(e.key===`ArrowLeft`)s(e=>f(e-.05));else if(e.key===`ArrowRight`)s(e=>f(e+.05));else return;e.preventDefault()}}),(0,v.jsx)(`div`,{ref:d,className:`min-w-0 flex-1 overflow-y-auto`,style:{background:r},"data-testid":i,children:(0,v.jsx)(`div`,{className:`mx-auto w-fit py-4`,style:{zoom:c},children:t})})]})}export{T as a,x as c,O as i,g as l,j as n,S as o,E as r,C as s,P as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"./createLucideIcon-lm_6n8YT.js";var t=e(`square-arrow-out-up-right`,[[`path`,{d:`M21 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h6`,key:`y09zxi`}],[`path`,{d:`m21 3-9 9`,key:`mpx6sq`}],[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}]]);export{t};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{t as e}from"./purify.es-B9ve_eFf.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{n,t as r}from"./d3-selection-COWvaQNI.js";import{C as i,H as a,U as o,_ as s,a as c,b as l,q as u,s as d,v as f}from"./chunk-DSNLSHJZ-QaczBS3J.js";import"./chunk-YZO67HFG-BSiF71qj.js";import{_ as p,s as m}from"./chunk-7S6XSTFO-V-AvHpAB.js";import"./chunk-AQDTSKZB-PjHyYpb8.js";import"./chunk-UHW7PFBP-BFmZ5ZLn.js";import{a as h,i as g,o as _,r as v}from"./chunk-J5ZVWO5B-oDCd-gWO.js";import"./chunk-HAGFOTED-aLaQB5Xu.js";import"./chunk-ZAUX2LTX-BJc4r5b1.js";import"./chunk-WQQL4CDK-BrAU7V6v.js";import{t as y}from"./chunk-55XCU76K-CkwQ_3m1.js";import{t as b}from"./chunk-XXDRQBXY-i7MKP1NY.js";import{t as x}from"./chunk-VQ5W62QI-CzppUHLA.js";import"./chunk-HNE4Q36P-De3ftDQR.js";import{i as S,r as C}from"./mermaid.core-Cc2GIqBr.js";var w=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,2],r=[1,3],i=[1,4],a=[2,4],o=[1,9],s=[1,11],c=[1,16],l=[1,17],u=[1,18],d=[1,19],f=[1,33],p=[1,20],m=[1,21],h=[1,22],g=[1,23],_=[1,24],v=[1,26],y=[1,27],b=[1,28],x=[1,29],S=[1,30],C=[1,31],w=[1,32],T=[1,35],E=[1,36],D=[1,37],O=[1,38],k=[1,34],A=[1,4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],j=[1,4,5,14,15,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,39,40,41,45,48,51,52,53,54,57],M=[4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],N={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,styleStatement:11,cssClassStatement:12,idStatement:13,DESCR:14,"-->":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,CLICK:38,STRING:39,HREF:40,classDef:41,CLASSDEF_ID:42,CLASSDEF_STYLEOPTS:43,DEFAULT:44,style:45,STYLE_IDS:46,STYLEDEF_STYLEOPTS:47,class:48,CLASSENTITY_IDS:49,STYLECLASS:50,direction_tb:51,direction_bt:52,direction_rl:53,direction_lr:54,eol:55,";":56,EDGE_STATE:57,STYLE_SEPARATOR:58,left_of:59,right_of:60,$accept:0,$end:1},terminals_:{2:`error`,4:`SPACE`,5:`NL`,6:`SD`,14:`DESCR`,15:`-->`,16:`HIDE_EMPTY`,17:`scale`,18:`WIDTH`,19:`COMPOSIT_STATE`,20:`STRUCT_START`,21:`STRUCT_STOP`,22:`STATE_DESCR`,23:`AS`,24:`ID`,25:`FORK`,26:`JOIN`,27:`CHOICE`,28:`CONCURRENT`,29:`note`,31:`NOTE_TEXT`,33:`acc_title`,34:`acc_title_value`,35:`acc_descr`,36:`acc_descr_value`,37:`acc_descr_multiline_value`,38:`CLICK`,39:`STRING`,40:`HREF`,41:`classDef`,42:`CLASSDEF_ID`,43:`CLASSDEF_STYLEOPTS`,44:`DEFAULT`,45:`style`,46:`STYLE_IDS`,47:`STYLEDEF_STYLEOPTS`,48:`class`,49:`CLASSENTITY_IDS`,50:`STYLECLASS`,51:`direction_tb`,52:`direction_bt`,53:`direction_rl`,54:`direction_lr`,56:`;`,57:`EDGE_STATE`,58:`STYLE_SEPARATOR`,59:`left_of`,60:`right_of`},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[9,5],[9,5],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[55,1],[55,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 3:return r.setRootDoc(a[s]),a[s];case 4:this.$=[];break;case 5:a[s]!=`nl`&&(a[s-1].push(a[s]),this.$=a[s-1]);break;case 6:case 7:this.$=a[s];break;case 8:this.$=`nl`;break;case 12:this.$=a[s];break;case 13:let e=a[s-1];e.description=r.trimColon(a[s]),this.$=e;break;case 14:this.$={stmt:`relation`,state1:a[s-2],state2:a[s]};break;case 15:let t=r.trimColon(a[s]);this.$={stmt:`relation`,state1:a[s-3],state2:a[s-1],description:t};break;case 19:this.$={stmt:`state`,id:a[s-3],type:`default`,description:``,doc:a[s-1]};break;case 20:var c=a[s],l=a[s-2].trim();if(a[s].match(`:`)){var u=a[s].split(`:`);c=u[0],l=[l,u[1]]}this.$={stmt:`state`,id:c,type:`default`,description:l};break;case 21:this.$={stmt:`state`,id:a[s-3],type:`default`,description:a[s-5],doc:a[s-1]};break;case 22:this.$={stmt:`state`,id:a[s],type:`fork`};break;case 23:this.$={stmt:`state`,id:a[s],type:`join`};break;case 24:this.$={stmt:`state`,id:a[s],type:`choice`};break;case 25:this.$={stmt:`state`,id:r.getDividerId(),type:`divider`};break;case 26:this.$={stmt:`state`,id:a[s-1].trim(),note:{position:a[s-2].trim(),text:a[s].trim()}};break;case 29:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 30:case 31:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 32:this.$={stmt:`click`,id:a[s-3],url:a[s-2],tooltip:a[s-1]};break;case 33:this.$={stmt:`click`,id:a[s-3],url:a[s-1],tooltip:``};break;case 34:case 35:this.$={stmt:`classDef`,id:a[s-1].trim(),classes:a[s].trim()};break;case 36:this.$={stmt:`style`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 37:this.$={stmt:`applyClass`,id:a[s-1].trim(),styleClass:a[s].trim()};break;case 38:r.setDirection(`TB`),this.$={stmt:`dir`,value:`TB`};break;case 39:r.setDirection(`BT`),this.$={stmt:`dir`,value:`BT`};break;case 40:r.setDirection(`RL`),this.$={stmt:`dir`,value:`RL`};break;case 41:r.setDirection(`LR`),this.$={stmt:`dir`,value:`LR`};break;case 44:case 45:this.$={stmt:`state`,id:a[s].trim(),type:`default`,description:``};break;case 46:this.$={stmt:`state`,id:a[s-2].trim(),classes:[a[s].trim()],type:`default`,description:``};break;case 47:this.$={stmt:`state`,id:a[s-2].trim(),classes:[a[s].trim()],type:`default`,description:``}}},`anonymous`),table:[{3:1,4:n,5:r,6:i},{1:[3]},{3:5,4:n,5:r,6:i},{3:6,4:n,5:r,6:i},e([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],a,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,5]),{9:39,10:12,11:13,12:14,13:15,16:c,17:l,19:u,22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,7]),e(A,[2,8]),e(A,[2,9]),e(A,[2,10]),e(A,[2,11]),e(A,[2,12],{14:[1,40],15:[1,41]}),e(A,[2,16]),{18:[1,42]},e(A,[2,18],{20:[1,43]}),{23:[1,44]},e(A,[2,22]),e(A,[2,23]),e(A,[2,24]),e(A,[2,25]),{30:45,31:[1,46],59:[1,47],60:[1,48]},e(A,[2,28]),{34:[1,49]},{36:[1,50]},e(A,[2,31]),{13:51,24:f,57:k},{42:[1,52],44:[1,53]},{46:[1,54]},{49:[1,55]},e(j,[2,44],{58:[1,56]}),e(j,[2,45],{58:[1,57]}),e(A,[2,38]),e(A,[2,39]),e(A,[2,40]),e(A,[2,41]),e(A,[2,6]),e(A,[2,13]),{13:58,24:f,57:k},e(A,[2,17]),e(M,a,{7:59}),{24:[1,60]},{24:[1,61]},{23:[1,62]},{24:[2,48]},{24:[2,49]},e(A,[2,29]),e(A,[2,30]),{39:[1,63],40:[1,64]},{43:[1,65]},{43:[1,66]},{47:[1,67]},{50:[1,68]},{24:[1,69]},{24:[1,70]},e(A,[2,14],{14:[1,71]}),{4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,21:[1,72],22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,20],{20:[1,73]}),{31:[1,74]},{24:[1,75]},{39:[1,76]},{39:[1,77]},e(A,[2,34]),e(A,[2,35]),e(A,[2,36]),e(A,[2,37]),e(j,[2,46]),e(j,[2,47]),e(A,[2,15]),e(A,[2,19]),e(M,a,{7:78}),e(A,[2,26]),e(A,[2,27]),{5:[1,79]},{5:[1,80]},{4:o,5:s,8:8,9:10,10:12,11:13,12:14,13:15,16:c,17:l,19:u,21:[1,81],22:d,24:f,25:p,26:m,27:h,28:g,29:_,32:25,33:v,35:y,37:b,38:x,41:S,45:C,48:w,51:T,52:E,53:D,54:O,57:k},e(A,[2,32]),e(A,[2,33]),e(A,[2,21])],defaultActions:{5:[2,1],6:[2,2],47:[2,48],48:[2,49]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
|
|
2
2
|
`+h.showPosition()+`
|
|
3
|
-
Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};N.lexer=(function(){return{EOF:1,parseError:
|
|
4
|
-
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:
|
|
5
|
-
`+t+`^`},`showPosition`),test_match:
|
|
6
|
-
`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(t,n,r,i){function a(){let e=n.yytext.indexOf(`%%`);if(e===0)return!1;if(e>0){let r=n.yytext.slice(0,e),i=n.yytext.slice(e);i&&t.lexer.unput(i),n.yytext=r}return!0}switch(e(a,`processId`),r){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:return 51;case 5:return 52;case 6:return 53;case 7:return 54;case 8:return 5;case 9:break;case 10:break;case 11:break;case 12:break;case 13:return this.pushState(`SCALE`),17;case 14:return 18;case 15:this.popState();break;case 16:return this.begin(`acc_title`),33;case 17:return this.popState(),`acc_title_value`;case 18:return this.begin(`acc_descr`),35;case 19:return this.popState(),`acc_descr_value`;case 20:this.begin(`acc_descr_multiline`);break;case 21:this.popState();break;case 22:return`acc_descr_multiline_value`;case 23:return this.pushState(`CLASSDEF`),41;case 24:return this.popState(),this.pushState(`CLASSDEFID`),`DEFAULT_CLASSDEF_ID`;case 25:return this.popState(),this.pushState(`CLASSDEFID`),42;case 26:return this.popState(),43;case 27:return this.pushState(`CLASS`),48;case 28:return this.popState(),this.pushState(`CLASS_STYLE`),49;case 29:return this.popState(),50;case 30:return this.pushState(`STYLE`),45;case 31:return this.popState(),this.pushState(`STYLEDEF_STYLES`),46;case 32:return this.popState(),47;case 33:return this.pushState(`SCALE`),17;case 34:return 18;case 35:this.popState();break;case 36:this.pushState(`STATE`);break;case 37:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),25;case 38:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),26;case 39:return this.popState(),n.yytext=n.yytext.slice(0,-10).trim(),27;case 40:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),25;case 41:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),26;case 42:return this.popState(),n.yytext=n.yytext.slice(0,-10).trim(),27;case 43:return 51;case 44:return 52;case 45:return 53;case 46:return 54;case 47:this.pushState(`STATE_STRING`);break;case 48:return this.pushState(`STATE_ID`),`AS`;case 49:return a()?(this.popState(),`ID`):void 0;case 50:this.popState();break;case 51:return`STATE_DESCR`;case 52:throw Error(`Error: State name must be a single word. Found: "`+n.yytext.trim()+`"`);case 53:return 19;case 54:this.popState();break;case 55:return this.popState(),this.pushState(`struct`),20;case 56:return this.popState(),21;case 57:break;case 58:return this.begin(`NOTE`),29;case 59:return this.popState(),this.pushState(`NOTE_ID`),59;case 60:return this.popState(),this.pushState(`NOTE_ID`),60;case 61:this.popState(),this.pushState(`FLOATING_NOTE`);break;case 62:return this.popState(),this.pushState(`FLOATING_NOTE_ID`),`AS`;case 63:break;case 64:return`NOTE_TEXT`;case 65:return a()?(this.popState(),`ID`):void 0;case 66:return a()?(this.popState(),this.pushState(`NOTE_TEXT`),24):void 0;case 67:return this.popState(),n.yytext=n.yytext.substr(2).trim(),31;case 68:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),31;case 69:return 6;case 70:return 6;case 71:return 16;case 72:return 57;case 73:return a()?24:void 0;case 74:return n.yytext=n.yytext.trim(),14;case 75:return 15;case 76:return 28;case 77:return 58;case 78:return 5;case 79:return`INVALID`}},`anonymous`),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<<fork>>)/i,/^(?:.*<<join>>)/i,/^(?:.*<<choice>>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\w+\s+\w+.*?\{)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,56,57,58,72,73,74,75,76,77],inclusive:!1},FLOATING_NOTE_ID:{rules:[65],inclusive:!1},FLOATING_NOTE:{rules:[62,63,64],inclusive:!1},NOTE_TEXT:{rules:[67,68],inclusive:!1},NOTE_ID:{rules:[66],inclusive:!1},NOTE:{rules:[59,60,61],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54,55],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,55,58,69,70,71,72,73,74,75,77,78,79],inclusive:!0}}}})();function P(){this.yy={}}return e(P,`Parser`),P.prototype=N,N.Parser=P,new P})();w.parser=w;var T=w,E=`TB`,D=`TB`,O=`dir`,k=`state`,A=`root`,j=`relation`,M=`classDef`,N=`style`,P=`applyClass`,F=`default`,ee=`divider`,te=`fill:none`,ne=`fill: #333`,re=`c`,ie=`markdown`,ae=`normal`,I=`rect`,L=`rectWithTitle`,oe=`stateStart`,se=`stateEnd`,R=`divider`,ce=`roundedWithTitle`,le=`note`,ue=`noteGroup`,z=`statediagram`,de=`${z}-state`,B=`transition`,fe=`note`,pe=`${B} note-edge`,me=`${z}-${fe}`,he=`${z}-cluster`,ge=`${z}-cluster-alt`,V=`parent`,H=`note`,_e=`state`,U=`----`,ve=`${U}${H}`,ye=`${U}${V}`,W=new Map,G=0,be=0,K=new Map,xe=e((e,t,n,r)=>{if(e===R&&n?.id!==void 0&&K.has(n.id)){let e=K.get(n.id);return K.set(t,e),e}let i=be++,a=r?void 0:i;return K.set(t,a),a},`colorSlotFor`);function q(e=``,t=0,n=``,r=U){return`${_e}-${e}${n!==null&&n.length>0?`${r}${n}`:``}-${t}`}e(q,`stateDomId`);var Se=e((e,n,r,i,a,o,s,l)=>{t.trace(`items`,n),n.forEach(t=>{switch(t.stmt){case k:X(e,t,r,i,a,o,s,l);break;case F:X(e,t,r,i,a,o,s,l);break;case j:{X(e,t.state1,r,i,a,o,s,l),X(e,t.state2,r,i,a,o,s,l);let n=s===`neo`,u={id:`edge`+G,start:t.state1.id,end:t.state2.id,arrowhead:`normal`,arrowTypeEnd:n?`arrow_barb_neo`:`arrow_barb`,style:te,labelStyle:``,label:d.sanitizeText(t.description??``,c()),arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,classes:B,look:s};a.push(u),G++}}})},`setupDoc`),Ce=e((e,t=D)=>{let n=t;if(e.doc)for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`);function J(e,t,n){if(!t.id||t.id===`</join></fork>`||t.id===`</choice>`)return;t.cssClasses&&(Array.isArray(t.cssCompiledStyles)||(t.cssCompiledStyles=[]),t.cssClasses.split(` `).forEach(e=>{let r=n.get(e);r&&(t.cssCompiledStyles=[...t.cssCompiledStyles??[],...r.styles])}));let r=e.find(e=>e.id===t.id);r?Object.assign(r,t):e.push(t)}e(J,`insertOrUpdateNode`);function we(e){return e?.classes?.join(` `)??``}e(we,`getClassesFromDbInfo`);function Y(e){return e?.styles??[]}e(Y,`getStylesFromDbInfo`);var X=e((e,n,r,i,a,o,s,l)=>{let u=n.id,f=r.get(u),p=we(f),m=Y(f),h=c(),g=p.trim()!==``||m.length>0;if(t.info(`dataFetcher parsedItem`,n,f,m),u!==`root`){let r=I;n.start===!0?r=oe:n.start===!1&&(r=se),n.type!==F&&(r=n.type),W.get(u)||W.set(u,{id:u,shape:r,description:d.sanitizeText(u,h),cssClasses:`${p} ${de}`,cssStyles:m});let c=W.get(u);n.description&&(Array.isArray(c.description)?(c.shape=L,c.description.push(n.description)):c.description?.length&&c.description.length>0?(c.shape=L,c.description=c.description===u?[n.description]:[c.description,n.description]):(c.shape=I,c.description=n.description),c.description=d.sanitizeTextOrArray(c.description,h)),c.description?.length===1&&c.shape===L&&(c.shape=c.type===`group`?ce:I),!c.type&&n.doc&&(t.info(`Setting cluster for XCX`,u,Ce(n)),c.type=`group`,c.isGroup=!0,c.dir=Ce(n),c.shape=n.type===ee?R:ce,c.colorIndex=xe(c.shape,u,e,g),c.cssClasses=`${c.cssClasses} ${he} ${o?ge:``}`);let f={labelStyle:``,shape:c.shape,label:c.description,cssClasses:c.cssClasses,cssCompiledStyles:[],cssStyles:c.cssStyles,id:u,dir:c.dir,domId:q(u,G),type:c.type,isGroup:c.type===`group`,colorIndex:c.colorIndex,padding:8,rx:10,ry:10,look:s,labelType:`markdown`};if(f.shape===R&&(f.label=``),e&&e.id!==`root`&&(t.trace(`Setting node `,u,` to be child of its parent `,e.id),f.parentId=e.id),f.centerLabel=!0,n.note){let e={labelStyle:``,shape:le,label:n.note.text,labelType:`markdown`,cssClasses:me,cssStyles:[],cssCompiledStyles:[],id:u+ve+`-`+G,domId:q(u,G,H),type:`node`,isGroup:!1,padding:h.flowchart?.padding,look:s,position:n.note.position},t=u+ye,r={labelStyle:``,shape:ue,label:n.note.text,cssClasses:c.cssClasses,cssStyles:[],id:u+ye,domId:q(u,G,V),type:`group`,isGroup:!0,padding:16,look:s,position:n.note.position};G++,r.id=t,e.parentId=t,J(i,r,l),J(i,e,l),J(i,f,l);let o=u,d=e.id;n.note.position===`left of`&&(o=e.id,d=u),a.push({id:o+`-`+d,start:o,end:d,arrowhead:`none`,arrowTypeEnd:``,style:te,labelStyle:``,classes:pe,pattern:`dashed`,arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,look:s})}else J(i,f,l)}n.doc&&(t.trace(`Adding nodes children `),Se(n,n.doc,r,i,a,!o,s,l))},`dataFetcher`),Te=e(()=>{W.clear(),G=0,be=0,K.clear()},`reset`),Ee=e((e,t=D)=>{if(!e.doc)return t;let n=t;for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`),De={getClasses:e(function(e,t){return t.db.getClasses()},`getClasses`),draw:e(async function(e,n,r,i){t.info(`REF0:`),t.info(`Drawing state diagram (v2)`,n);let{securityLevel:a,state:o,layout:s}=c();i.db.extract(i.db.getRootDocV2());let l=i.db.getData(),u=b(n,a);l.type=i.type,l.layoutAlgorithm=C(s),l.nodeSpacing=o?.nodeSpacing||50,l.rankSpacing=o?.rankSpacing||50,l.markers=c().look===`neo`?[`barbNeo`]:[`barb`],l.diagramId=n,await S(l,u);try{(typeof i.db.getLinks==`function`?i.db.getLinks():new Map).forEach((e,n)=>{let r=typeof n==`string`?n:typeof n?.id==`string`?n.id:``,i=l.nodes.find(e=>e.id===r);if(!r){t.warn(`⚠️ Invalid or missing stateId from key:`,JSON.stringify(n));return}let a=u.node()?.querySelectorAll(`g.node, g.rough-node`),o;if(a?.forEach(e=>{let t=e.textContent?.trim();(e.id===i?.domId||t===r)&&(o=e)}),!o){t.warn(`⚠️ Could not find node matching text:`,r);return}let s=o.parentNode;if(!s){t.warn(`⚠️ Node has no parent, cannot wrap:`,r);return}let c=document.createElementNS(`http://www.w3.org/2000/svg`,`a`),d=e.url.replace(/^"+|"+$/g,``);if(c.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,d),c.setAttribute(`target`,`_blank`),e.tooltip){let t=e.tooltip.replace(/^"+|"+$/g,``);c.setAttribute(`title`,t),o.setAttribute(`title`,t)}s.replaceChild(c,o),c.appendChild(o),t.info(`🔗 Wrapped node in <a> tag for:`,r,e.url)})}catch(e){t.error(`❌ Error injecting clickable links:`,e)}p.insertTitle(u,`statediagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),x(u,8,z,o?.useMaxWidth??!0)},`draw`),getDir:Ee},Z={START_NODE:`[*]`,START_TYPE:`start`,END_NODE:`[*]`,END_TYPE:`end`,COLOR_KEYWORD:`color`,FILL_KEYWORD:`fill`,BG_FILL:`bgFill`,STYLECLASS_SEP:`,`},Oe=e(()=>new Map,`newClassesList`),Q=e(()=>({relations:[],states:new Map,documents:{}}),`newDoc`),$=e(e=>JSON.parse(JSON.stringify(e)),`clone`),ke=class{constructor(e){this.version=e,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=Oe(),this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.funs=[],this.getAccTitle=f,this.setAccTitle=a,this.getAccDescription=o,this.setAccDescription=i,this.setDiagramTitle=u,this.getDiagramTitle=r,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this),this.bindFunctions=this.bindFunctions.bind(this)}static{e(this,`StateDB`)}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(e){this.clear(!0);for(let t of Array.isArray(e)?e:e.doc)switch(t.stmt){case k:this.addState(t.id.trim(),t.type,t.doc,t.description,t.note);break;case j:this.addRelation(t.state1,t.state2,t.description);break;case M:this.addStyleClass(t.id.trim(),t.classes);break;case N:this.handleStyleDef(t);break;case P:this.setCssClass(t.id.trim(),t.styleClass);break;case`click`:this.addLink(t.id,t.url,t.tooltip)}let t=this.getStates(),n=c();Te(),X(void 0,this.getRootDocV2(),t,this.nodes,this.edges,!0,n.look,this.classes);for(let e of this.nodes)if(Array.isArray(e.label)){if(e.description=e.label.slice(1),e.isGroup&&e.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${e.id}]`);e.label=e.label[0]}}handleStyleDef(e){let t=e.id.trim().split(`,`),n=e.styleClass.split(`,`);for(let e of t){let t=this.getState(e);if(!t){let n=e.trim();this.addState(n),t=this.getState(n)}t&&(t.styles=n.map(e=>e.replace(/;/g,``)?.trim()))}}setRootDoc(e){t.info(`Setting root doc`,e),this.rootDoc=e,this.version===1?this.extract(e):this.extract(this.getRootDocV2())}docTranslator(e,t,n){if(t.stmt===j){this.docTranslator(e,t.state1,!0),this.docTranslator(e,t.state2,!1);return}if(t.stmt===k&&(t.id===Z.START_NODE?(t.id=e.id+(n?`_start`:`_end`),t.start=n):t.id=t.id.trim()),t.stmt!==A&&t.stmt!==k||!t.doc)return;let r=[],i=[];for(let e of t.doc)if(e.type===ee){let t=$(e);t.doc=$(i),r.push(t),i=[]}else i.push(e);if(r.length>0&&i.length>0){let e={stmt:k,id:m(),type:`divider`,doc:$(i)};r.push($(e)),t.doc=r}t.doc.forEach(e=>this.docTranslator(t,e,!0))}getRootDocV2(){return this.docTranslator({id:A,stmt:A},{id:A,stmt:A,doc:this.rootDoc},!0),{id:A,doc:this.rootDoc}}addState(e,n=F,r=void 0,i=void 0,a=void 0,o=void 0,s=void 0,l=void 0){let u=e?.trim();if(!this.currentDocument.states.has(u))t.info(`Adding state `,u,i),this.currentDocument.states.set(u,{stmt:k,id:u,descriptions:[],type:n,doc:r,note:a,classes:[],styles:[],textStyles:[]});else{let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.doc||=r,e.type||=n}if(i&&(t.info(`Setting state description`,u,i),(Array.isArray(i)?i:[i]).forEach(e=>this.addDescription(u,e.trim()))),a){let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.note=a,e.note.text=d.sanitizeText(e.note.text,c())}o&&(t.info(`Setting state classes`,u,o),(Array.isArray(o)?o:[o]).forEach(e=>this.setCssClass(u,e.trim()))),s&&(t.info(`Setting state styles`,u,s),(Array.isArray(s)?s:[s]).forEach(e=>this.setStyle(u,e.trim()))),l&&(t.info(`Setting state styles`,u,s),(Array.isArray(l)?l:[l]).forEach(e=>this.setTextStyle(u,e.trim())))}clear(e){this.nodes=[],this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=Oe(),e||(this.links=new Map,s())}getState(e){return this.currentDocument.states.get(e)}getStates(){return this.currentDocument.states}logDocuments(){t.info(`Documents = `,this.documents)}getRelations(){return this.currentDocument.relations}addLink(e,n,r){this.links.set(e,{url:n,tooltip:r}),t.warn(`Adding link`,e,n,r)}getLinks(){return this.links}startIdIfNeeded(e=``){return e===Z.START_NODE?(this.startEndCount++,`${Z.START_TYPE}${this.startEndCount}`):e}startTypeIfNeeded(e=``,t=F){return e===Z.START_NODE?Z.START_TYPE:t}endIdIfNeeded(e=``){return e===Z.END_NODE?(this.startEndCount++,`${Z.END_TYPE}${this.startEndCount}`):e}endTypeIfNeeded(e=``,t=F){return e===Z.END_NODE?Z.END_TYPE:t}addRelationObjs(e,t,n=``){let r=this.startIdIfNeeded(e.id.trim()),i=this.startTypeIfNeeded(e.id.trim(),e.type),a=this.startIdIfNeeded(t.id.trim()),o=this.startTypeIfNeeded(t.id.trim(),t.type);this.addState(r,i,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.addState(a,o,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:d.sanitizeText(n,c())})}addRelation(e,t,n){if(typeof e==`object`&&typeof t==`object`)this.addRelationObjs(e,t,n);else if(typeof e==`string`&&typeof t==`string`){let r=this.startIdIfNeeded(e.trim()),i=this.startTypeIfNeeded(e),a=this.endIdIfNeeded(t.trim()),o=this.endTypeIfNeeded(t);this.addState(r,i),this.addState(a,o),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:n?d.sanitizeText(n,c()):void 0})}}addDescription(e,t){let n=this.currentDocument.states.get(e),r=t.startsWith(`:`)?t.replace(`:`,``).trim():t;n?.descriptions?.push(d.sanitizeText(r,c()))}cleanupLabel(e){return e.startsWith(`:`)?e.slice(2).trim():e.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(e,t=``){this.classes.has(e)||this.classes.set(e,{id:e,styles:[],textStyles:[]});let n=this.classes.get(e);t&&n&&t.split(Z.STYLECLASS_SEP).forEach(e=>{let t=e.replace(/([^;]*);/,`$1`).trim();if(RegExp(Z.COLOR_KEYWORD).exec(e)){let e=t.replace(Z.FILL_KEYWORD,Z.BG_FILL).replace(Z.COLOR_KEYWORD,Z.FILL_KEYWORD);n.textStyles.push(e)}n.styles.push(t)})}getClasses(){return this.classes}setupToolTips(e){let t=y();n(e).select(`svg`).selectAll(`g.node, g.rough-node`).on(`mouseover`,e=>{let r=n(e.currentTarget),i=r.attr(`title`);if(i===null)return;let a=e.currentTarget?.getBoundingClientRect();t.transition().duration(200).style(`opacity`,`.9`),t.style(`left`,window.scrollX+a.left+(a.right-a.left)/2+`px`).style(`top`,window.scrollY+a.bottom+`px`),t.html(l.sanitize(i)),r.classed(`hover`,!0)}).on(`mouseout`,e=>{t.transition().duration(500).style(`opacity`,0),n(e.currentTarget).classed(`hover`,!1)})}setCssClass(e,t){e.split(`,`).forEach(e=>{let n=this.getState(e);if(!n){let t=e.trim();this.addState(t),n=this.getState(t)}n?.classes?.push(t)})}setStyle(e,t){this.getState(e)?.styles?.push(t)}setTextStyle(e,t){this.getState(e)?.textStyles?.push(t)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirectionStatement(){return this.rootDoc.find(e=>e.stmt===O)}getDirection(){return this.getDirectionStatement()?.value??E}setDirection(e){let t=this.getDirectionStatement();t?t.value=e:this.rootDoc.unshift({stmt:O,value:e})}trimColon(e){return e.startsWith(`:`)?e.slice(1).trim():e.trim()}getData(){let e=c();for(let t of this.nodes)t.wrappingWidth??=e.state?.wrappingWidth,t.isGroup||(t.minWidth??=e.state?.minNodeWidth);return{nodes:this.nodes,edges:this.edges,other:{},config:e,direction:Ee(this.getRootDocV2())}}getConfig(){return c().state}},Ae=e(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!g(t,r))return``;let i=_(e.look),a=v(n),o=``;for(let e=0;e<h(r);e++){let t=r[e],s=a?`fill: ${n[e%n.length]};`:``,c=`[data-look="${i}"][data-color-id="color-${e}"]`;o+=`
|
|
3
|
+
Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};N.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
|
|
5
|
+
`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
+
`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,n,r,i){function a(){let t=n.yytext.indexOf(`%%`);if(t===0)return!1;if(t>0){let r=n.yytext.slice(0,t),i=n.yytext.slice(t);i&&e.lexer.unput(i),n.yytext=r}return!0}switch(t(a,`processId`),r){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:return 51;case 5:return 52;case 6:return 53;case 7:return 54;case 8:return 5;case 9:break;case 10:break;case 11:break;case 12:break;case 13:return this.pushState(`SCALE`),17;case 14:return 18;case 15:this.popState();break;case 16:return this.begin(`acc_title`),33;case 17:return this.popState(),`acc_title_value`;case 18:return this.begin(`acc_descr`),35;case 19:return this.popState(),`acc_descr_value`;case 20:this.begin(`acc_descr_multiline`);break;case 21:this.popState();break;case 22:return`acc_descr_multiline_value`;case 23:return this.pushState(`CLASSDEF`),41;case 24:return this.popState(),this.pushState(`CLASSDEFID`),`DEFAULT_CLASSDEF_ID`;case 25:return this.popState(),this.pushState(`CLASSDEFID`),42;case 26:return this.popState(),43;case 27:return this.pushState(`CLASS`),48;case 28:return this.popState(),this.pushState(`CLASS_STYLE`),49;case 29:return this.popState(),50;case 30:return this.pushState(`STYLE`),45;case 31:return this.popState(),this.pushState(`STYLEDEF_STYLES`),46;case 32:return this.popState(),47;case 33:return this.pushState(`SCALE`),17;case 34:return 18;case 35:this.popState();break;case 36:this.pushState(`STATE`);break;case 37:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),25;case 38:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),26;case 39:return this.popState(),n.yytext=n.yytext.slice(0,-10).trim(),27;case 40:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),25;case 41:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),26;case 42:return this.popState(),n.yytext=n.yytext.slice(0,-10).trim(),27;case 43:return 51;case 44:return 52;case 45:return 53;case 46:return 54;case 47:this.pushState(`STATE_STRING`);break;case 48:return this.pushState(`STATE_ID`),`AS`;case 49:return a()?(this.popState(),`ID`):void 0;case 50:this.popState();break;case 51:return`STATE_DESCR`;case 52:throw Error(`Error: State name must be a single word. Found: "`+n.yytext.trim()+`"`);case 53:return 19;case 54:this.popState();break;case 55:return this.popState(),this.pushState(`struct`),20;case 56:return this.popState(),21;case 57:break;case 58:return this.begin(`NOTE`),29;case 59:return this.popState(),this.pushState(`NOTE_ID`),59;case 60:return this.popState(),this.pushState(`NOTE_ID`),60;case 61:this.popState(),this.pushState(`FLOATING_NOTE`);break;case 62:return this.popState(),this.pushState(`FLOATING_NOTE_ID`),`AS`;case 63:break;case 64:return`NOTE_TEXT`;case 65:return a()?(this.popState(),`ID`):void 0;case 66:return a()?(this.popState(),this.pushState(`NOTE_TEXT`),24):void 0;case 67:return this.popState(),n.yytext=n.yytext.substr(2).trim(),31;case 68:return this.popState(),n.yytext=n.yytext.slice(0,-8).trim(),31;case 69:return 6;case 70:return 6;case 71:return 16;case 72:return 57;case 73:return a()?24:void 0;case 74:return n.yytext=n.yytext.trim(),14;case 75:return 15;case 76:return 28;case 77:return 58;case 78:return 5;case 79:return`INVALID`}},`anonymous`),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<<fork>>)/i,/^(?:.*<<join>>)/i,/^(?:.*<<choice>>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\w+\s+\w+.*?\{)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,56,57,58,72,73,74,75,76,77],inclusive:!1},FLOATING_NOTE_ID:{rules:[65],inclusive:!1},FLOATING_NOTE:{rules:[62,63,64],inclusive:!1},NOTE_TEXT:{rules:[67,68],inclusive:!1},NOTE_ID:{rules:[66],inclusive:!1},NOTE:{rules:[59,60,61],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54,55],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,55,58,69,70,71,72,73,74,75,77,78,79],inclusive:!0}}}})();function P(){this.yy={}}return t(P,`Parser`),P.prototype=N,N.Parser=P,new P})();w.parser=w;var T=w,E=`TB`,D=`TB`,O=`dir`,k=`state`,A=`root`,j=`relation`,M=`classDef`,N=`style`,P=`applyClass`,F=`default`,ee=`divider`,te=`fill:none`,ne=`fill: #333`,re=`c`,ie=`markdown`,ae=`normal`,I=`rect`,L=`rectWithTitle`,oe=`stateStart`,se=`stateEnd`,R=`divider`,ce=`roundedWithTitle`,le=`note`,ue=`noteGroup`,z=`statediagram`,de=`${z}-state`,B=`transition`,fe=`note`,pe=`${B} note-edge`,me=`${z}-${fe}`,he=`${z}-cluster`,ge=`${z}-cluster-alt`,V=`parent`,H=`note`,_e=`state`,U=`----`,ve=`${U}${H}`,ye=`${U}${V}`,W=new Map,G=0,be=0,K=new Map,xe=t((e,t,n,r)=>{if(e===R&&n?.id!==void 0&&K.has(n.id)){let e=K.get(n.id);return K.set(t,e),e}let i=be++,a=r?void 0:i;return K.set(t,a),a},`colorSlotFor`);function q(e=``,t=0,n=``,r=U){return`${_e}-${e}${n!==null&&n.length>0?`${r}${n}`:``}-${t}`}t(q,`stateDomId`);var Se=t((e,t,r,i,a,o,s,c)=>{n.trace(`items`,t),t.forEach(t=>{switch(t.stmt){case k:X(e,t,r,i,a,o,s,c);break;case F:X(e,t,r,i,a,o,s,c);break;case j:{X(e,t.state1,r,i,a,o,s,c),X(e,t.state2,r,i,a,o,s,c);let n=s===`neo`,u={id:`edge`+G,start:t.state1.id,end:t.state2.id,arrowhead:`normal`,arrowTypeEnd:n?`arrow_barb_neo`:`arrow_barb`,style:te,labelStyle:``,label:d.sanitizeText(t.description??``,l()),arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,classes:B,look:s};a.push(u),G++}}})},`setupDoc`),Ce=t((e,t=D)=>{let n=t;if(e.doc)for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`);function J(e,t,n){if(!t.id||t.id===`</join></fork>`||t.id===`</choice>`)return;t.cssClasses&&(Array.isArray(t.cssCompiledStyles)||(t.cssCompiledStyles=[]),t.cssClasses.split(` `).forEach(e=>{let r=n.get(e);r&&(t.cssCompiledStyles=[...t.cssCompiledStyles??[],...r.styles])}));let r=e.find(e=>e.id===t.id);r?Object.assign(r,t):e.push(t)}t(J,`insertOrUpdateNode`);function we(e){return e?.classes?.join(` `)??``}t(we,`getClassesFromDbInfo`);function Y(e){return e?.styles??[]}t(Y,`getStylesFromDbInfo`);var X=t((e,t,r,i,a,o,s,c)=>{let u=t.id,f=r.get(u),p=we(f),m=Y(f),h=l(),g=p.trim()!==``||m.length>0;if(n.info(`dataFetcher parsedItem`,t,f,m),u!==`root`){let r=I;t.start===!0?r=oe:t.start===!1&&(r=se),t.type!==F&&(r=t.type),W.get(u)||W.set(u,{id:u,shape:r,description:d.sanitizeText(u,h),cssClasses:`${p} ${de}`,cssStyles:m});let l=W.get(u);t.description&&(Array.isArray(l.description)?(l.shape=L,l.description.push(t.description)):l.description?.length&&l.description.length>0?(l.shape=L,l.description=l.description===u?[t.description]:[l.description,t.description]):(l.shape=I,l.description=t.description),l.description=d.sanitizeTextOrArray(l.description,h)),l.description?.length===1&&l.shape===L&&(l.shape=l.type===`group`?ce:I),!l.type&&t.doc&&(n.info(`Setting cluster for XCX`,u,Ce(t)),l.type=`group`,l.isGroup=!0,l.dir=Ce(t),l.shape=t.type===ee?R:ce,l.colorIndex=xe(l.shape,u,e,g),l.cssClasses=`${l.cssClasses} ${he} ${o?ge:``}`);let f={labelStyle:``,shape:l.shape,label:l.description,cssClasses:l.cssClasses,cssCompiledStyles:[],cssStyles:l.cssStyles,id:u,dir:l.dir,domId:q(u,G),type:l.type,isGroup:l.type===`group`,colorIndex:l.colorIndex,padding:8,rx:10,ry:10,look:s,labelType:`markdown`};if(f.shape===R&&(f.label=``),e&&e.id!==`root`&&(n.trace(`Setting node `,u,` to be child of its parent `,e.id),f.parentId=e.id),f.centerLabel=!0,t.note){let e={labelStyle:``,shape:le,label:t.note.text,labelType:`markdown`,cssClasses:me,cssStyles:[],cssCompiledStyles:[],id:u+ve+`-`+G,domId:q(u,G,H),type:`node`,isGroup:!1,padding:h.flowchart?.padding,look:s,position:t.note.position},n=u+ye,r={labelStyle:``,shape:ue,label:t.note.text,cssClasses:l.cssClasses,cssStyles:[],id:u+ye,domId:q(u,G,V),type:`group`,isGroup:!0,padding:16,look:s,position:t.note.position};G++,r.id=n,e.parentId=n,J(i,r,c),J(i,e,c),J(i,f,c);let o=u,d=e.id;t.note.position===`left of`&&(o=e.id,d=u),a.push({id:o+`-`+d,start:o,end:d,arrowhead:`none`,arrowTypeEnd:``,style:te,labelStyle:``,classes:pe,pattern:`dashed`,arrowheadStyle:ne,labelpos:re,labelType:ie,thickness:ae,look:s})}else J(i,f,c)}t.doc&&(n.trace(`Adding nodes children `),Se(t,t.doc,r,i,a,!o,s,c))},`dataFetcher`),Te=t(()=>{W.clear(),G=0,be=0,K.clear()},`reset`),Ee=t((e,t=D)=>{if(!e.doc)return t;let n=t;for(let t of e.doc)t.stmt===`dir`&&(n=t.value);return n},`getDir`),De={getClasses:t(function(e,t){return t.db.getClasses()},`getClasses`),draw:t(async function(e,t,r,i){n.info(`REF0:`),n.info(`Drawing state diagram (v2)`,t);let{securityLevel:a,state:o,layout:s}=l();i.db.extract(i.db.getRootDocV2());let c=i.db.getData(),u=b(t,a);c.type=i.type,c.layoutAlgorithm=C(s),c.nodeSpacing=o?.nodeSpacing||50,c.rankSpacing=o?.rankSpacing||50,c.markers=l().look===`neo`?[`barbNeo`]:[`barb`],c.diagramId=t,await S(c,u);try{(typeof i.db.getLinks==`function`?i.db.getLinks():new Map).forEach((e,t)=>{let r=typeof t==`string`?t:typeof t?.id==`string`?t.id:``,i=c.nodes.find(e=>e.id===r);if(!r){n.warn(`⚠️ Invalid or missing stateId from key:`,JSON.stringify(t));return}let a=u.node()?.querySelectorAll(`g.node, g.rough-node`),o;if(a?.forEach(e=>{let t=e.textContent?.trim();(e.id===i?.domId||t===r)&&(o=e)}),!o){n.warn(`⚠️ Could not find node matching text:`,r);return}let s=o.parentNode;if(!s){n.warn(`⚠️ Node has no parent, cannot wrap:`,r);return}let l=document.createElementNS(`http://www.w3.org/2000/svg`,`a`),d=e.url.replace(/^"+|"+$/g,``);if(l.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,d),l.setAttribute(`target`,`_blank`),e.tooltip){let t=e.tooltip.replace(/^"+|"+$/g,``);l.setAttribute(`title`,t),o.setAttribute(`title`,t)}s.replaceChild(l,o),l.appendChild(o),n.info(`🔗 Wrapped node in <a> tag for:`,r,e.url)})}catch(e){n.error(`❌ Error injecting clickable links:`,e)}p.insertTitle(u,`statediagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),x(u,8,z,o?.useMaxWidth??!0)},`draw`),getDir:Ee},Z={START_NODE:`[*]`,START_TYPE:`start`,END_NODE:`[*]`,END_TYPE:`end`,COLOR_KEYWORD:`color`,FILL_KEYWORD:`fill`,BG_FILL:`bgFill`,STYLECLASS_SEP:`,`},Oe=t(()=>new Map,`newClassesList`),Q=t(()=>({relations:[],states:new Map,documents:{}}),`newDoc`),$=t(e=>JSON.parse(JSON.stringify(e)),`clone`),ke=class{constructor(e){this.version=e,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=Oe(),this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.funs=[],this.getAccTitle=f,this.setAccTitle=o,this.getAccDescription=s,this.setAccDescription=a,this.setDiagramTitle=u,this.getDiagramTitle=i,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this),this.bindFunctions=this.bindFunctions.bind(this)}static{t(this,`StateDB`)}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(e){this.clear(!0);for(let t of Array.isArray(e)?e:e.doc)switch(t.stmt){case k:this.addState(t.id.trim(),t.type,t.doc,t.description,t.note);break;case j:this.addRelation(t.state1,t.state2,t.description);break;case M:this.addStyleClass(t.id.trim(),t.classes);break;case N:this.handleStyleDef(t);break;case P:this.setCssClass(t.id.trim(),t.styleClass);break;case`click`:this.addLink(t.id,t.url,t.tooltip)}let t=this.getStates(),n=l();Te(),X(void 0,this.getRootDocV2(),t,this.nodes,this.edges,!0,n.look,this.classes);for(let e of this.nodes)if(Array.isArray(e.label)){if(e.description=e.label.slice(1),e.isGroup&&e.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${e.id}]`);e.label=e.label[0]}}handleStyleDef(e){let t=e.id.trim().split(`,`),n=e.styleClass.split(`,`);for(let e of t){let t=this.getState(e);if(!t){let n=e.trim();this.addState(n),t=this.getState(n)}t&&(t.styles=n.map(e=>e.replace(/;/g,``)?.trim()))}}setRootDoc(e){n.info(`Setting root doc`,e),this.rootDoc=e,this.version===1?this.extract(e):this.extract(this.getRootDocV2())}docTranslator(e,t,n){if(t.stmt===j){this.docTranslator(e,t.state1,!0),this.docTranslator(e,t.state2,!1);return}if(t.stmt===k&&(t.id===Z.START_NODE?(t.id=e.id+(n?`_start`:`_end`),t.start=n):t.id=t.id.trim()),t.stmt!==A&&t.stmt!==k||!t.doc)return;let r=[],i=[];for(let e of t.doc)if(e.type===ee){let t=$(e);t.doc=$(i),r.push(t),i=[]}else i.push(e);if(r.length>0&&i.length>0){let e={stmt:k,id:m(),type:`divider`,doc:$(i)};r.push($(e)),t.doc=r}t.doc.forEach(e=>this.docTranslator(t,e,!0))}getRootDocV2(){return this.docTranslator({id:A,stmt:A},{id:A,stmt:A,doc:this.rootDoc},!0),{id:A,doc:this.rootDoc}}addState(e,t=F,r=void 0,i=void 0,a=void 0,o=void 0,s=void 0,c=void 0){let u=e?.trim();if(!this.currentDocument.states.has(u))n.info(`Adding state `,u,i),this.currentDocument.states.set(u,{stmt:k,id:u,descriptions:[],type:t,doc:r,note:a,classes:[],styles:[],textStyles:[]});else{let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.doc||=r,e.type||=t}if(i&&(n.info(`Setting state description`,u,i),(Array.isArray(i)?i:[i]).forEach(e=>this.addDescription(u,e.trim()))),a){let e=this.currentDocument.states.get(u);if(!e)throw Error(`State not found: ${u}`);e.note=a,e.note.text=d.sanitizeText(e.note.text,l())}o&&(n.info(`Setting state classes`,u,o),(Array.isArray(o)?o:[o]).forEach(e=>this.setCssClass(u,e.trim()))),s&&(n.info(`Setting state styles`,u,s),(Array.isArray(s)?s:[s]).forEach(e=>this.setStyle(u,e.trim()))),c&&(n.info(`Setting state styles`,u,s),(Array.isArray(c)?c:[c]).forEach(e=>this.setTextStyle(u,e.trim())))}clear(e){this.nodes=[],this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.documents={root:Q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=Oe(),e||(this.links=new Map,c())}getState(e){return this.currentDocument.states.get(e)}getStates(){return this.currentDocument.states}logDocuments(){n.info(`Documents = `,this.documents)}getRelations(){return this.currentDocument.relations}addLink(e,t,r){this.links.set(e,{url:t,tooltip:r}),n.warn(`Adding link`,e,t,r)}getLinks(){return this.links}startIdIfNeeded(e=``){return e===Z.START_NODE?(this.startEndCount++,`${Z.START_TYPE}${this.startEndCount}`):e}startTypeIfNeeded(e=``,t=F){return e===Z.START_NODE?Z.START_TYPE:t}endIdIfNeeded(e=``){return e===Z.END_NODE?(this.startEndCount++,`${Z.END_TYPE}${this.startEndCount}`):e}endTypeIfNeeded(e=``,t=F){return e===Z.END_NODE?Z.END_TYPE:t}addRelationObjs(e,t,n=``){let r=this.startIdIfNeeded(e.id.trim()),i=this.startTypeIfNeeded(e.id.trim(),e.type),a=this.startIdIfNeeded(t.id.trim()),o=this.startTypeIfNeeded(t.id.trim(),t.type);this.addState(r,i,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.addState(a,o,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:d.sanitizeText(n,l())})}addRelation(e,t,n){if(typeof e==`object`&&typeof t==`object`)this.addRelationObjs(e,t,n);else if(typeof e==`string`&&typeof t==`string`){let r=this.startIdIfNeeded(e.trim()),i=this.startTypeIfNeeded(e),a=this.endIdIfNeeded(t.trim()),o=this.endTypeIfNeeded(t);this.addState(r,i),this.addState(a,o),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:n?d.sanitizeText(n,l()):void 0})}}addDescription(e,t){let n=this.currentDocument.states.get(e),r=t.startsWith(`:`)?t.replace(`:`,``).trim():t;n?.descriptions?.push(d.sanitizeText(r,l()))}cleanupLabel(e){return e.startsWith(`:`)?e.slice(2).trim():e.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(e,t=``){this.classes.has(e)||this.classes.set(e,{id:e,styles:[],textStyles:[]});let n=this.classes.get(e);t&&n&&t.split(Z.STYLECLASS_SEP).forEach(e=>{let t=e.replace(/([^;]*);/,`$1`).trim();if(RegExp(Z.COLOR_KEYWORD).exec(e)){let e=t.replace(Z.FILL_KEYWORD,Z.BG_FILL).replace(Z.COLOR_KEYWORD,Z.FILL_KEYWORD);n.textStyles.push(e)}n.styles.push(t)})}getClasses(){return this.classes}setupToolTips(t){let n=y();r(t).select(`svg`).selectAll(`g.node, g.rough-node`).on(`mouseover`,t=>{let i=r(t.currentTarget),a=i.attr(`title`);if(a===null)return;let o=t.currentTarget?.getBoundingClientRect();n.transition().duration(200).style(`opacity`,`.9`),n.style(`left`,window.scrollX+o.left+(o.right-o.left)/2+`px`).style(`top`,window.scrollY+o.bottom+`px`),n.html(e.sanitize(a)),i.classed(`hover`,!0)}).on(`mouseout`,e=>{n.transition().duration(500).style(`opacity`,0),r(e.currentTarget).classed(`hover`,!1)})}setCssClass(e,t){e.split(`,`).forEach(e=>{let n=this.getState(e);if(!n){let t=e.trim();this.addState(t),n=this.getState(t)}n?.classes?.push(t)})}setStyle(e,t){this.getState(e)?.styles?.push(t)}setTextStyle(e,t){this.getState(e)?.textStyles?.push(t)}bindFunctions(e){this.funs.forEach(t=>{t(e)})}getDirectionStatement(){return this.rootDoc.find(e=>e.stmt===O)}getDirection(){return this.getDirectionStatement()?.value??E}setDirection(e){let t=this.getDirectionStatement();t?t.value=e:this.rootDoc.unshift({stmt:O,value:e})}trimColon(e){return e.startsWith(`:`)?e.slice(1).trim():e.trim()}getData(){let e=l();for(let t of this.nodes)t.wrappingWidth??=e.state?.wrappingWidth,t.isGroup||(t.minWidth??=e.state?.minNodeWidth);return{nodes:this.nodes,edges:this.edges,other:{},config:e,direction:Ee(this.getRootDocV2())}}getConfig(){return l().state}},Ae=t(e=>{let{theme:t,bkgColorArray:n,borderColorArray:r}=e;if(!g(t,r))return``;let i=_(e.look),a=v(n),o=``;for(let e=0;e<h(r);e++){let t=r[e],s=a?`fill: ${n[e%n.length]};`:``,c=`[data-look="${i}"][data-color-id="color-${e}"]`;o+=`
|
|
7
7
|
|
|
8
8
|
/* The title strip: \`rect.outer\` spans the whole composite and \`rect.inner\` covers
|
|
9
9
|
the body, so what stays visible of \`outer\` is the band behind the label. */
|
|
@@ -62,7 +62,7 @@ Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on l
|
|
|
62
62
|
${c}.statediagram-cluster .divider path[fill='none'] {
|
|
63
63
|
stroke: ${t};
|
|
64
64
|
}
|
|
65
|
-
`}return o},`genColor`),je={parser:T,get db(){return new ke(2)},renderer:De,styles:
|
|
65
|
+
`}return o},`genColor`),je={parser:T,get db(){return new ke(2)},renderer:De,styles:t(e=>`
|
|
66
66
|
${Ae(e)}
|
|
67
67
|
defs [id$="-barbEnd"] {
|
|
68
68
|
fill: ${e.transitionColor};
|
|
@@ -288,4 +288,4 @@ g.stateGroup line {
|
|
|
288
288
|
ry: ${e.radius}px;
|
|
289
289
|
filter: ${e.dropShadow?e.dropShadow.replace(`url(#drop-shadow)`,`url(${e.svgId}-drop-shadow)`):`none`}
|
|
290
290
|
}
|
|
291
|
-
`,`getStyles`),init:
|
|
291
|
+
`,`getStyles`),init:t(e=>{e.state||={},e.state.arrowMarkerAbsolute=e.arrowMarkerAbsolute},`init`)};export{je as diagram};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./createLucideIcon-
|
|
1
|
+
import{t as e}from"./createLucideIcon-lm_6n8YT.js";var t=e(`sticky-note`,[[`path`,{d:`M21 9a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 15 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2z`,key:`1dfntj`}],[`path`,{d:`M15 3v5a1 1 0 0 0 1 1h5`,key:`6s6qgf`}]]);export{t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./createLucideIcon-
|
|
1
|
+
import{t as e}from"./createLucideIcon-lm_6n8YT.js";var t=e(`strikethrough`,[[`path`,{d:`M16 4H9a3 3 0 0 0-2.83 4`,key:`43sutm`}],[`path`,{d:`M14 12a4 4 0 0 1 0 8H6`,key:`nlfj13`}],[`line`,{x1:`4`,x2:`20`,y1:`12`,y2:`12`,key:`1e0a9i`}]]);export{t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-COiEfhsA.js";import{
|
|
1
|
+
import"./rolldown-runtime-COiEfhsA.js";import{y as e}from"./react-Edyoga_4.js";import{gt as t,ht as n}from"./x-DlhyIKuu.js";import{t as r}from"./jsx-runtime-DePvh3-m.js";var i=r();e();var a=t(`overflow-hidden rounded-lg border border-rule`,{variants:{tone:{sheet:`bg-sheet`,paper:`bg-paper`,bare:`rounded-none border-0 bg-transparent`}},defaultVariants:{tone:`sheet`}});function o({className:e,tone:t,...r}){return(0,i.jsx)(`div`,{"data-slot":`surface`,className:n(a({tone:t,className:e})),...r})}export{o as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{_ as e,r as t}from"./chart-amT4lgX3.js";var n={dk1:`#000000`,lt1:`#FFFFFF`,dk2:`#44546A`,lt2:`#E7E6E6`,accent1:`#4472C4`,accent2:`#ED7D31`,accent3:`#A5A5A5`,accent4:`#FFC000`,accent5:`#5B9BD5`,accent6:`#70AD47`,hlink:`#0563C1`,folHlink:`#954F72`},r={"&":`&`,"<":`<`,">":`>`,'"':`"`},i=e=>e.replace(/[&<>"]/gu,e=>r[e]??e),a=e=>String(Number(e.toFixed(3)));function o(e,t){let n=e=>{let n=e.fill===void 0?`none`:t(e.fill),r=e.width>0?t(e.color):`none`;return`<path d="${i(e.d)}" fill="${n}" stroke="${r}" stroke-width="${a(e.width)}" stroke-linejoin="round"/>`},r=[];for(let t of[...e.grid,...e.shapes])r.push(n(t));for(let n of[...e.boxes,...e.keys])r.push(`<rect x="${a(n.x)}" y="${a(n.y)}" width="${a(n.width)}" height="${a(n.height)}" fill="${t(n.color)}"/>`);for(let t of[...e.axes,...e.lines])r.push(n(t));for(let n of e.dots)r.push(`<circle cx="${a(n.x)}" cy="${a(n.y)}" r="${a(n.r)}" fill="${t(n.color)}"/>`);for(let n of e.words){let e=n.rotate===void 0?``:` transform="rotate(${a(n.rotate)} ${a(n.x)} ${a(n.y)})"`;r.push(`<text x="${a(n.x)}" y="${a(n.y)}" font-size="${a(n.size)}" text-anchor="${n.anchor}" dominant-baseline="central" fill="${t(n.color)}"${e}>${i(n.text)}</text>`)}return r.join(``)}function s(r,s,c,l={}){let u=l.pointsPerPixel??.75,d=s*u,f=c*u,p=l.colors??n,m=t=>e(t,p),h=l.font??`Carlito, Calibri, Arial, sans-serif`,g=l.paper??`#FFFFFF`,_=l.edge??`#D9D9D9`,v=l.label===void 0?``:` role="img" aria-label="${i(l.label)}"`,y=g===`none`&&_===`none`?``:`<rect x="0.375" y="0.375" width="${a(d-.75)}" height="${a(f-.75)}" fill="${i(g)}" stroke="${i(_)}" stroke-width="${_===`none`?`0`:`0.75`}"/>`;return`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${a(d)} ${a(f)}" width="${a(s)}" height="${a(c)}" font-family="${i(h)}"${v}>${y}${o(t(r,d,f),m)}</svg>`}export{s as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-COiEfhsA.js";import{
|
|
1
|
+
import"./rolldown-runtime-COiEfhsA.js";import{y as e}from"./react-Edyoga_4.js";import{ht as t}from"./x-DlhyIKuu.js";import{t as n}from"./jsx-runtime-DePvh3-m.js";import{t as r}from"./createLucideIcon-lm_6n8YT.js";var i=r(`trash-2`,[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),a=n();e();function o({color:e,label:n,checked:r=!1,className:i,style:o,...s}){return(0,a.jsx)(`button`,{type:`button`,role:`radio`,"aria-checked":r,"aria-label":n,title:n,"data-slot":`swatch`,...s,className:t(`size-5 flex-none rounded-xs border border-rule outline-none ring-offset-1 ring-offset-sheet hover:ring-1 hover:ring-lead focus-visible:ring-1 focus-visible:ring-pencil`,r&&`ring-1 ring-ink`,i),style:{...o,background:e}})}export{i as n,o as t};
|