allyhub 0.2.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli-version.js +2 -0
- package/dist/commands/add.js +5 -5
- package/dist/commands/auth.js +4 -4
- package/dist/commands/cloud-tools.js +9 -10
- package/dist/commands/dev.js +2 -2
- package/dist/commands/doctor.js +4 -4
- package/dist/commands/frames/piece.js +1 -1
- package/dist/commands/frames.js +6 -6
- package/dist/commands/index.js +1 -1
- package/dist/commands/inspect/contrast.js +1 -1
- package/dist/commands/inspect/layout.js +1 -1
- package/dist/commands/model.js +1 -1
- package/dist/commands/orgs.js +2 -2
- package/dist/commands/render.js +2 -2
- package/dist/commands/sheet.js +2 -2
- package/dist/commands/skills.js +3 -3
- package/dist/commands/slides.js +3 -0
- package/dist/main.js +7 -7
- package/dist/text/facts-text.js +5 -5
- package/dist/text/format.js +2 -2
- package/dist/works.js +1 -1
- package/editor-web/assets/browser-B31cR_c2.js +105 -0
- package/editor-web/assets/dist-6TNEuNMX.js +4 -0
- package/editor-web/assets/dist-Cm2TIjW5.js +2 -0
- package/editor-web/assets/dist-Cpt0p8bX.js +6 -0
- package/editor-web/assets/dist-D2GccKEJ.js +1 -0
- package/editor-web/assets/dist-Z0zvYXmu.js +233 -0
- package/editor-web/assets/dist-fs4ONrUV.js +32 -0
- package/editor-web/assets/index-CAcsAZ9u.js +70 -0
- package/editor-web/assets/index-DlcJckhO.css +2 -0
- package/editor-web/assets/list-D2v7U8K8.js +1 -0
- package/editor-web/assets/react-D0RmGe2w.js +101 -0
- package/editor-web/assets/rolldown-runtime-XKyaHtl9.js +1 -0
- package/editor-web/assets/text-align-start-B3k2cx5f.js +1 -0
- package/editor-web/assets/undo-2-Ecr7-Obc.js +1 -0
- package/editor-web/index.html +4 -4
- package/node_modules/@allyhub-next/audio/package.json +1 -1
- package/node_modules/@allyhub-next/browser/package.json +1 -1
- package/node_modules/@allyhub-next/build/dist/data.js +1 -1
- package/node_modules/@allyhub-next/build/dist/meta-worker.d.ts +10 -0
- package/node_modules/@allyhub-next/build/dist/meta-worker.js +2 -2
- package/node_modules/@allyhub-next/build/dist/model-info.js +2 -1
- package/node_modules/@allyhub-next/build/dist/plugin.d.ts +2 -0
- package/node_modules/@allyhub-next/build/dist/plugin.js +9 -8
- package/node_modules/@allyhub-next/build/dist/prepare.d.ts +13 -1
- package/node_modules/@allyhub-next/build/dist/prepare.js +2 -2
- package/node_modules/@allyhub-next/build/dist/scan.d.ts +1 -1
- package/node_modules/@allyhub-next/build/dist/scan.js +1 -1
- package/node_modules/@allyhub-next/build/dist/types.js +3 -3
- package/node_modules/@allyhub-next/build/package.json +1 -1
- package/node_modules/@allyhub-next/check/dist/check.js +3 -3
- package/node_modules/@allyhub-next/check/dist/generated.d.ts +1 -1
- package/node_modules/@allyhub-next/check/package.json +1 -1
- package/node_modules/@allyhub-next/cloud/dist/index.js +1 -1
- package/node_modules/@allyhub-next/cloud/dist/signin.js +2 -2
- package/node_modules/@allyhub-next/cloud/dist/token.js +1 -1
- package/node_modules/@allyhub-next/cloud/package.json +1 -1
- package/node_modules/@allyhub-next/components/package.json +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/card.d.ts +2 -11
- package/node_modules/@allyhub-next/dev-server/dist/card.js +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/exports.d.ts +2 -2
- package/node_modules/@allyhub-next/dev-server/dist/exports.js +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/index.d.ts +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/index.js +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/live.d.ts +3 -0
- package/node_modules/@allyhub-next/dev-server/dist/live.js +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/project.d.ts +3 -0
- package/node_modules/@allyhub-next/dev-server/dist/project.js +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/reveal.d.ts +6 -0
- package/node_modules/@allyhub-next/dev-server/dist/reveal.js +2 -0
- package/node_modules/@allyhub-next/dev-server/dist/server.js +1 -1
- package/node_modules/@allyhub-next/dev-server/dist/stage.d.ts +2 -0
- package/node_modules/@allyhub-next/dev-server/dist/stage.js +22 -2
- package/node_modules/@allyhub-next/dev-server/dist/tools.d.ts +2 -0
- package/node_modules/@allyhub-next/dev-server/dist/tools.js +1 -1
- package/node_modules/@allyhub-next/dev-server/package.json +1 -1
- package/node_modules/@allyhub-next/doc/dist/docx.d.ts +28 -0
- package/node_modules/@allyhub-next/doc/dist/docx.js +4 -0
- package/node_modules/@allyhub-next/doc/dist/html.d.ts +3 -0
- package/node_modules/@allyhub-next/doc/dist/html.js +1 -1
- package/node_modules/@allyhub-next/doc/package.json +5 -1
- package/node_modules/@allyhub-next/export/dist/deck-fonts.d.ts +24 -0
- package/node_modules/@allyhub-next/export/dist/deck-fonts.js +2 -0
- package/node_modules/@allyhub-next/export/dist/deck-pptx.d.ts +12 -0
- package/node_modules/@allyhub-next/export/dist/deck-pptx.js +2 -0
- package/node_modules/@allyhub-next/export/dist/export.d.ts +17 -5
- package/node_modules/@allyhub-next/export/dist/export.js +2 -2
- package/node_modules/@allyhub-next/export/dist/index.d.ts +1 -0
- package/node_modules/@allyhub-next/export/dist/index.js +1 -1
- package/node_modules/@allyhub-next/export/dist/names.d.ts +11 -6
- package/node_modules/@allyhub-next/export/dist/names.js +1 -1
- package/node_modules/@allyhub-next/export/package.json +1 -1
- package/node_modules/@allyhub-next/formats/dist/data/script.d.ts +22 -0
- package/node_modules/@allyhub-next/formats/dist/data/script.js +1 -1
- package/node_modules/@allyhub-next/formats/dist/data/slides.d.ts +1494 -0
- package/node_modules/@allyhub-next/formats/dist/data/slides.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/index.d.ts +2 -0
- package/node_modules/@allyhub-next/formats/dist/index.js +1 -1
- package/node_modules/@allyhub-next/formats/dist/items.d.ts +26 -0
- package/node_modules/@allyhub-next/formats/dist/items.js +1 -1
- package/node_modules/@allyhub-next/formats/dist/layout.d.ts +2 -0
- package/node_modules/@allyhub-next/formats/dist/layout.js +1 -1
- package/node_modules/@allyhub-next/formats/dist/note-shape.d.ts +39 -0
- package/node_modules/@allyhub-next/formats/dist/note-shape.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/schemas.d.ts +418 -0
- package/node_modules/@allyhub-next/formats/dist/schemas.js +1 -1
- package/node_modules/@allyhub-next/formats/package.json +1 -1
- package/node_modules/@allyhub-next/measure/dist/index.d.ts +1 -1
- package/node_modules/@allyhub-next/measure/dist/index.js +1 -1
- package/node_modules/@allyhub-next/measure/dist/overlay.d.ts +14 -1
- package/node_modules/@allyhub-next/measure/dist/overlay.js +1 -1
- package/node_modules/@allyhub-next/measure/package.json +1 -1
- package/node_modules/@allyhub-next/media/dist/asr/parakeet.d.ts +1 -4
- package/node_modules/@allyhub-next/media/dist/asr/parakeet.js +4 -4
- package/node_modules/@allyhub-next/media/dist/asr/transcribe.d.ts +1 -1
- package/node_modules/@allyhub-next/media/dist/asr/transcribe.js +1 -1
- package/node_modules/@allyhub-next/media/dist/grid.d.ts +3 -3
- package/node_modules/@allyhub-next/media/dist/grid.js +5 -5
- package/node_modules/@allyhub-next/media/dist/local.d.ts +3 -0
- package/node_modules/@allyhub-next/media/dist/local.js +1 -1
- package/node_modules/@allyhub-next/media/dist/ocr/tesseract.d.ts +8 -2
- package/node_modules/@allyhub-next/media/dist/ocr/tesseract.js +1 -1
- package/node_modules/@allyhub-next/media/dist/ocr/text.js +3 -3
- package/node_modules/@allyhub-next/media/dist/ocr/worker.js +1 -1
- package/node_modules/@allyhub-next/media/dist/sheet.js +3 -3
- package/node_modules/@allyhub-next/media/dist/tools.d.ts +11 -1
- package/node_modules/@allyhub-next/media/dist/tools.js +1 -1
- package/node_modules/@allyhub-next/media/dist/vision/faces.js +1 -1
- package/node_modules/@allyhub-next/media/dist/vision/matte.js +1 -1
- package/node_modules/@allyhub-next/media/dist/vision/runtime.d.ts +1 -1
- package/node_modules/@allyhub-next/media/dist/vision/runtime.js +2 -2
- package/node_modules/@allyhub-next/media/dist/worker-process.d.ts +1 -1
- package/node_modules/@allyhub-next/media/dist/worker-process.js +1 -1
- package/node_modules/@allyhub-next/media/package.json +1 -1
- package/node_modules/@allyhub-next/model/dist/build-job.d.ts +2 -0
- package/node_modules/@allyhub-next/model/dist/build-worker.js +1 -1
- package/node_modules/@allyhub-next/model/dist/build.d.ts +10 -0
- package/node_modules/@allyhub-next/model/dist/build.js +2 -1
- package/node_modules/@allyhub-next/model/dist/report.d.ts +1 -1
- package/node_modules/@allyhub-next/model/package.json +1 -1
- package/node_modules/@allyhub-next/project/dist/digest.d.ts +1 -3
- package/node_modules/@allyhub-next/project/dist/digest.js +1 -1
- package/node_modules/@allyhub-next/project/dist/page.d.ts +0 -5
- package/node_modules/@allyhub-next/project/dist/page.js +2 -2
- package/node_modules/@allyhub-next/project/dist/session.js +1 -1
- package/node_modules/@allyhub-next/project/package.json +1 -1
- package/node_modules/@allyhub-next/protocol/dist/app.d.ts +1 -62
- package/node_modules/@allyhub-next/protocol/dist/app.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/auth.d.ts +17 -17
- package/node_modules/@allyhub-next/protocol/dist/auth.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/cli.d.ts +1 -5
- package/node_modules/@allyhub-next/protocol/dist/cli.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/editor.d.ts +13 -26
- package/node_modules/@allyhub-next/protocol/dist/editor.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/index.d.ts +1 -0
- package/node_modules/@allyhub-next/protocol/dist/index.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/notes.d.ts +163 -0
- package/node_modules/@allyhub-next/protocol/dist/notes.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/registry.d.ts +4 -2
- package/node_modules/@allyhub-next/protocol/dist/registry.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/routes.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/runtimes.d.ts +3 -0
- package/node_modules/@allyhub-next/protocol/dist/runtimes.js +1 -1
- package/node_modules/@allyhub-next/protocol/dist/tools.d.ts +38 -0
- package/node_modules/@allyhub-next/protocol/dist/tools.js +1 -1
- package/node_modules/@allyhub-next/protocol/package.json +1 -1
- package/node_modules/@allyhub-next/registry/dist/registry.js +1 -1
- package/node_modules/@allyhub-next/registry/package.json +1 -1
- package/node_modules/@allyhub-next/render/dist/doc/index.d.ts +1 -1
- package/node_modules/@allyhub-next/render/dist/doc/index.js +1 -1
- package/node_modules/@allyhub-next/render/dist/doc/print.d.ts +11 -0
- package/node_modules/@allyhub-next/render/dist/doc/print.js +17 -1
- package/node_modules/@allyhub-next/render/dist/exports.d.ts +29 -4
- package/node_modules/@allyhub-next/render/dist/exports.js +2 -2
- package/node_modules/@allyhub-next/render/dist/page.d.ts +11 -1
- package/node_modules/@allyhub-next/render/dist/render.d.ts +2 -0
- package/node_modules/@allyhub-next/render/dist/render.js +2 -2
- package/node_modules/@allyhub-next/render/package.json +1 -1
- package/node_modules/@allyhub-next/runtime/LICENSE +241 -0
- package/node_modules/@allyhub-next/runtime/dist/bridge.d.ts +13 -3
- package/node_modules/@allyhub-next/runtime/dist/clock.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/env.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/facade.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/footage.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/frame.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/index.d.ts +2 -0
- package/node_modules/@allyhub-next/runtime/dist/index.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/locate.d.ts +11 -0
- package/node_modules/@allyhub-next/runtime/dist/locate.js +2 -0
- package/node_modules/@allyhub-next/runtime/dist/measure.d.ts +2 -1
- package/node_modules/@allyhub-next/runtime/dist/measure.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/music.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/output.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/piece.d.ts +5 -9
- package/node_modules/@allyhub-next/runtime/dist/piece.js +2 -2
- package/node_modules/@allyhub-next/runtime/dist/player/player.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/reads.d.ts +2 -0
- package/node_modules/@allyhub-next/runtime/dist/reads.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/sound.js +1 -1
- package/node_modules/@allyhub-next/runtime/dist/stage-kit.d.ts +12 -0
- package/node_modules/@allyhub-next/runtime/dist/stage-kit.js +2 -0
- package/node_modules/@allyhub-next/runtime/package.json +5 -6
- package/node_modules/@allyhub-next/runtimes/dist/errors.d.ts +5 -1
- package/node_modules/@allyhub-next/runtimes/dist/index.d.ts +1 -0
- package/node_modules/@allyhub-next/runtimes/dist/index.js +1 -1
- package/node_modules/@allyhub-next/runtimes/dist/node-program.d.ts +3 -0
- package/node_modules/@allyhub-next/runtimes/dist/node-program.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/packages.d.ts +65 -0
- package/node_modules/@allyhub-next/runtimes/dist/packages.js +4 -0
- package/node_modules/@allyhub-next/runtimes/dist/runtimes.js +2 -2
- package/node_modules/@allyhub-next/runtimes/dist/unpack.d.ts +7 -0
- package/node_modules/@allyhub-next/runtimes/dist/unpack.js +1 -1
- package/node_modules/@allyhub-next/runtimes/package.json +5 -1
- package/node_modules/@allyhub-next/runtimes/pins/docx/package-lock.json +67 -0
- package/node_modules/@allyhub-next/runtimes/pins/docx/package.json +9 -0
- package/node_modules/@allyhub-next/runtimes/pins/exceljs/package-lock.json +2533 -0
- package/node_modules/@allyhub-next/runtimes/pins/exceljs/package.json +8 -0
- package/node_modules/@allyhub-next/runtimes/pins/gltf-tools/package-lock.json +753 -0
- package/node_modules/@allyhub-next/runtimes/pins/gltf-tools/package.json +14 -0
- package/node_modules/@allyhub-next/runtimes/pins/manifold-3d/package-lock.json +950 -0
- package/node_modules/@allyhub-next/runtimes/pins/manifold-3d/package.json +8 -0
- package/node_modules/@allyhub-next/runtimes/pins/onnxruntime-node/package-lock.json +227 -0
- package/node_modules/@allyhub-next/runtimes/pins/onnxruntime-node/package.json +8 -0
- package/node_modules/@allyhub-next/runtimes/pins/sherpa-onnx-node/package-lock.json +105 -0
- package/node_modules/@allyhub-next/runtimes/pins/sherpa-onnx-node/package.json +8 -0
- package/node_modules/@allyhub-next/runtimes/pins/tesseract.js/package-lock.json +128 -0
- package/node_modules/@allyhub-next/runtimes/pins/tesseract.js/package.json +9 -0
- package/node_modules/@allyhub-next/runtimes/schemas/runtimes.schema.json +5 -24
- package/node_modules/@allyhub-next/scaffold/dist/index.js +5 -5
- package/node_modules/@allyhub-next/scaffold/package.json +1 -1
- package/node_modules/@allyhub-next/scenery/package.json +1 -1
- package/node_modules/@allyhub-next/scenery-host/dist/bundle.d.ts +3 -2
- package/node_modules/@allyhub-next/scenery-host/dist/bundle.js +3 -3
- package/node_modules/@allyhub-next/scenery-host/dist/model-stage.d.ts +32 -0
- package/node_modules/@allyhub-next/scenery-host/dist/model-stage.js +3 -0
- package/node_modules/@allyhub-next/scenery-host/dist/viewer.d.ts +11 -0
- package/node_modules/@allyhub-next/scenery-host/dist/viewer.js +1 -1
- package/node_modules/@allyhub-next/scenery-host/package.json +1 -1
- package/node_modules/@allyhub-next/sheet/package.json +1 -1
- package/node_modules/@allyhub-next/site/dist/media.js +2 -2
- package/node_modules/@allyhub-next/site/package.json +1 -1
- package/node_modules/@allyhub-next/slides-core/LICENSE +241 -0
- package/node_modules/@allyhub-next/slides-core/dist/animation.d.ts +129 -0
- package/node_modules/@allyhub-next/slides-core/dist/animation.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/api.d.ts +649 -0
- package/node_modules/@allyhub-next/slides-core/dist/api.js +4 -0
- package/node_modules/@allyhub-next/slides-core/dist/capabilities.d.ts +18 -0
- package/node_modules/@allyhub-next/slides-core/dist/capabilities.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/chart-api.d.ts +165 -0
- package/node_modules/@allyhub-next/slides-core/dist/chart-api.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/chart-file.d.ts +11 -0
- package/node_modules/@allyhub-next/slides-core/dist/chart-file.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/chart.d.ts +184 -0
- package/node_modules/@allyhub-next/slides-core/dist/chart.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/check.d.ts +7 -0
- package/node_modules/@allyhub-next/slides-core/dist/check.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/enums.d.ts +146 -0
- package/node_modules/@allyhub-next/slides-core/dist/enums.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/file.d.ts +109 -0
- package/node_modules/@allyhub-next/slides-core/dist/file.js +4 -0
- package/node_modules/@allyhub-next/slides-core/dist/index.d.ts +21 -0
- package/node_modules/@allyhub-next/slides-core/dist/index.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/measure.d.ts +34 -0
- package/node_modules/@allyhub-next/slides-core/dist/measure.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/model.d.ts +278 -0
- package/node_modules/@allyhub-next/slides-core/dist/model.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/office.d.ts +58 -0
- package/node_modules/@allyhub-next/slides-core/dist/office.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/path.d.ts +6 -0
- package/node_modules/@allyhub-next/slides-core/dist/path.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/placeholders.d.ts +7 -0
- package/node_modules/@allyhub-next/slides-core/dist/placeholders.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/resolve.d.ts +181 -0
- package/node_modules/@allyhub-next/slides-core/dist/resolve.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/script.d.ts +43 -0
- package/node_modules/@allyhub-next/slides-core/dist/script.js +3 -0
- package/node_modules/@allyhub-next/slides-core/dist/stage.d.ts +63 -0
- package/node_modules/@allyhub-next/slides-core/dist/stage.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/strict.d.ts +23 -0
- package/node_modules/@allyhub-next/slides-core/dist/strict.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/theme.d.ts +72 -0
- package/node_modules/@allyhub-next/slides-core/dist/theme.js +2 -0
- package/node_modules/@allyhub-next/slides-core/dist/units.d.ts +35 -0
- package/node_modules/@allyhub-next/slides-core/dist/units.js +2 -0
- package/node_modules/@allyhub-next/slides-core/package.json +14 -0
- package/node_modules/@allyhub-next/slides-pptx/LICENSE +241 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/charts.d.ts +6 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/charts.js +2 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/fonts.d.ts +45 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/fonts.js +2 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/import.d.ts +18 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/import.js +3 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/index.d.ts +5 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/index.js +2 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/read.d.ts +55 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/read.js +4 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/shapes.d.ts +67 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/shapes.js +2 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/text.d.ts +21 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/text.js +2 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/theme.d.ts +4 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/theme.js +2 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/timing.d.ts +32 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/timing.js +2 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/write.d.ts +32 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/write.js +3 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/xml.d.ts +26 -0
- package/node_modules/@allyhub-next/slides-pptx/dist/xml.js +3 -0
- package/node_modules/@allyhub-next/slides-pptx/package.json +14 -0
- package/node_modules/@allyhub-next/slides-runtime/LICENSE +241 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/draw.d.ts +40 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/draw.js +3 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/edit.d.ts +4 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/edit.js +2 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/index.d.ts +4 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/index.js +2 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/ink.d.ts +10 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/ink.js +2 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/load.d.ts +6 -0
- package/node_modules/@allyhub-next/slides-runtime/dist/load.js +6 -0
- package/node_modules/@allyhub-next/slides-runtime/package.json +14 -0
- package/node_modules/@allyhub-next/stage/dist/graphics.js +1 -1
- package/node_modules/@allyhub-next/stage/dist/identity.js +1 -1
- package/node_modules/@allyhub-next/stage/dist/page.d.ts +9 -0
- package/node_modules/@allyhub-next/stage/dist/page.js +12 -2
- package/node_modules/@allyhub-next/stage/dist/server.js +1 -1
- package/node_modules/@allyhub-next/stage/package.json +1 -1
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/400-italic.css +79 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/400.css +79 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/700-italic.css +79 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/700.css +79 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/LICENSE +93 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/arial.css +316 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-ext-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-ext-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-ext-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-cyrillic-ext-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-ext-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-ext-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-ext-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-greek-ext-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-hebrew-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-hebrew-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-hebrew-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-hebrew-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-ext-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-ext-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-ext-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-latin-ext-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-vietnamese-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-vietnamese-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-vietnamese-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/arimo/files/arimo-vietnamese-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/400-italic.css +69 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/400.css +69 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/700-italic.css +69 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/700.css +69 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/LICENSE +93 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/calibri.css +276 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-ext-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-ext-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-ext-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-cyrillic-ext-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-ext-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-ext-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-ext-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-greek-ext-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-ext-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-ext-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-ext-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-latin-ext-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-vietnamese-400-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-vietnamese-400-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-vietnamese-700-italic.woff2 +0 -0
- package/node_modules/@allyhub-next/stage-page/dist/fonts/carlito/files/carlito-vietnamese-700-normal.woff2 +0 -0
- package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/400.css +1 -1
- package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/700.css +1 -1
- package/node_modules/@allyhub-next/stage-page/dist/fonts/noto-sans-sc/microsoft-yahei.css +2018 -0
- package/node_modules/@allyhub-next/stage-page/dist/host.js +21 -0
- package/node_modules/@allyhub-next/stage-page/dist/page.js +79 -0
- package/node_modules/@allyhub-next/stage-page/package.json +14 -0
- package/node_modules/@allyhub-next/video-core/dist/export.d.ts +6 -5
- package/node_modules/@allyhub-next/video-core/dist/export.js +1 -1
- package/node_modules/@allyhub-next/video-core/dist/fact.d.ts +173 -4
- package/node_modules/@allyhub-next/video-core/dist/fact.js +1 -1
- package/node_modules/@allyhub-next/video-core/dist/formats.d.ts +6 -13
- package/node_modules/@allyhub-next/video-core/dist/formats.js +1 -1
- package/node_modules/@allyhub-next/video-core/dist/index.d.ts +0 -1
- package/node_modules/@allyhub-next/video-core/dist/index.js +1 -1
- package/node_modules/@allyhub-next/video-core/dist/measure.d.ts +83 -0
- package/node_modules/@allyhub-next/video-core/dist/piece.d.ts +8 -9
- package/node_modules/@allyhub-next/video-core/dist/piece.js +1 -1
- package/node_modules/@allyhub-next/video-core/dist/problem.d.ts +9 -1
- package/node_modules/@allyhub-next/video-core/dist/problem.js +1 -1
- package/node_modules/@allyhub-next/video-core/dist/schema.d.ts +0 -2
- package/node_modules/@allyhub-next/video-core/dist/script-edit.d.ts +4 -0
- package/node_modules/@allyhub-next/video-core/dist/script.d.ts +8 -0
- package/node_modules/@allyhub-next/video-core/dist/script.js +1 -1
- package/node_modules/@allyhub-next/video-core/dist/timeline.d.ts +34 -1
- package/node_modules/@allyhub-next/video-core/package.json +1 -1
- package/package.json +48 -41
- package/dist/commands/mcp-app.js +0 -3
- package/dist/commands/mcp-docs.js +0 -2
- package/dist/commands/mcp.js +0 -2
- package/editor-app/view.html +0 -128
- package/editor-web/assets/chevron-left-D1vfOP5S.js +0 -1
- package/editor-web/assets/chevron-up-BMNXDEBs.js +0 -1
- package/editor-web/assets/dist-B4VKfY-H.js +0 -136
- package/editor-web/assets/dist-BIEloJVS.js +0 -8
- package/editor-web/assets/dist-BcInw4os.js +0 -232
- package/editor-web/assets/dist-Coblfc3T.js +0 -1
- package/editor-web/assets/floating-ui.react-dom-DSyn5TRd.js +0 -1
- package/editor-web/assets/index-BSFR4plz.css +0 -2
- package/editor-web/assets/index-Dc8FX_sp.js +0 -56
- package/editor-web/assets/react-Bo429Bov.js +0 -61
- package/editor-web/assets/undo-2-CWgOKQ3L.js +0 -1
- package/node_modules/@allyhub-next/runtime/dist/host.js +0 -21
- package/node_modules/@allyhub-next/runtime/dist/page.js +0 -72
- package/node_modules/@allyhub-next/runtime/dist/paged.d.ts +0 -16
- package/node_modules/@allyhub-next/runtime/dist/paged.js +0 -2
- package/node_modules/@allyhub-next/video-core/dist/slides.d.ts +0 -37
- package/node_modules/@allyhub-next/video-core/dist/slides.js +0 -2
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-color-emoji/LICENSE +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-color-emoji/emoji.css +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-color-emoji/files/noto-color-emoji-emoji-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/LICENSE +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-100-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-100-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-101-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-101-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-102-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-102-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-103-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-103-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-104-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-104-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-105-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-105-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-106-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-106-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-107-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-107-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-108-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-108-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-109-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-109-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-110-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-110-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-111-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-111-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-112-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-112-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-113-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-113-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-114-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-114-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-115-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-115-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-116-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-116-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-117-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-117-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-118-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-118-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-119-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-119-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-21-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-21-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-22-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-22-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-23-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-23-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-24-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-24-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-25-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-25-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-26-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-26-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-27-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-27-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-28-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-28-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-29-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-29-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-30-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-30-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-31-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-31-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-32-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-32-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-33-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-33-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-34-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-34-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-35-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-35-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-36-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-36-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-37-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-37-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-38-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-38-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-39-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-39-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-4-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-4-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-40-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-40-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-41-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-41-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-42-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-42-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-43-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-43-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-44-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-44-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-45-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-45-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-46-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-46-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-47-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-47-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-48-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-48-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-49-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-49-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-5-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-5-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-50-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-50-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-51-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-51-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-52-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-52-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-53-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-53-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-54-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-54-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-55-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-55-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-56-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-56-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-57-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-57-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-58-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-58-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-59-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-59-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-6-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-6-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-60-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-60-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-61-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-61-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-62-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-62-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-63-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-63-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-64-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-64-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-65-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-65-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-66-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-66-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-67-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-67-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-68-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-68-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-69-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-69-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-70-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-70-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-71-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-71-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-72-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-72-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-73-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-73-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-74-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-74-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-75-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-75-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-76-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-76-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-77-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-77-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-78-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-78-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-79-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-79-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-80-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-80-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-81-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-81-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-82-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-82-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-83-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-83-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-84-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-84-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-85-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-85-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-86-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-86-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-87-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-87-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-88-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-88-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-89-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-89-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-90-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-90-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-91-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-91-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-97-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-97-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-98-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-98-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-99-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-99-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-cyrillic-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-cyrillic-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-latin-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-latin-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-latin-ext-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-latin-ext-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-vietnamese-400-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/fonts/noto-sans-sc/files/noto-sans-sc-vietnamese-700-normal.woff2 +0 -0
- /package/node_modules/@allyhub-next/{runtime → stage-page}/dist/host.d.ts +0 -0
|
@@ -1,136 +0,0 @@
|
|
|
1
|
-
import{C as e,O as t,S as n,_ as r,c as i,d as a,f as o,h as s,j as c,l,n as u,r as d,u as f,x as p}from"./react-Bo429Bov.js";import{P as m}from"./floating-ui.react-dom-DSyn5TRd.js";import{n as h,r as g,t as _}from"./chevron-up-BMNXDEBs.js";import{t as v}from"./chevron-left-D1vfOP5S.js";import{i as y,n as b,r as x,t as S}from"./undo-2-CWgOKQ3L.js";import{$ as C,A as w,B as T,F as E,G as ee,I as te,K as ne,M as D,N as O,O as re,P as ie,U as ae,V as oe,X as k,Y as se,_ as ce,a as le,b as ue,c as de,d as fe,f as pe,g as me,h as he,i as ge,it as _e,j as ve,k as ye,l as be,m as A,n as xe,nt as Se,o as j,ot as Ce,p as we,q as M,r as N,s as P,t as Te,u as Ee,y as De,z as Oe}from"./index-Dc8FX_sp.js";var ke=i(`arrow-down-wide-narrow`,[[`path`,{d:`m3 16 4 4 4-4`,key:`1co6wj`}],[`path`,{d:`M7 20V4`,key:`1yoxec`}],[`path`,{d:`M11 4h10`,key:`1w87gc`}],[`path`,{d:`M11 8h7`,key:`djye34`}],[`path`,{d:`M11 12h4`,key:`q8tih4`}]]),Ae=i(`arrow-down`,[[`path`,{d:`M12 5v14`,key:`s699le`}],[`path`,{d:`m19 12-7 7-7-7`,key:`1idqje`}]]),je=i(`arrow-left-to-line`,[[`path`,{d:`M3 19V5`,key:`rwsyhb`}],[`path`,{d:`m13 6-6 6 6 6`,key:`1yhaz7`}],[`path`,{d:`M7 12h14`,key:`uoisry`}]]),Me=i(`arrow-right-to-line`,[[`path`,{d:`M17 12H3`,key:`8awo09`}],[`path`,{d:`m11 18 6-6-6-6`,key:`8c2y43`}],[`path`,{d:`M21 5v14`,key:`nzette`}]]),Ne=i(`arrow-up-narrow-wide`,[[`path`,{d:`m3 8 4-4 4 4`,key:`11wl7u`}],[`path`,{d:`M7 4v16`,key:`1glfcx`}],[`path`,{d:`M11 12h4`,key:`q8tih4`}],[`path`,{d:`M11 16h7`,key:`uosisv`}],[`path`,{d:`M11 20h10`,key:`jvxblo`}]]),Pe=i(`arrow-up`,[[`path`,{d:`m5 12 7-7 7 7`,key:`hav0vg`}],[`path`,{d:`M12 19V5`,key:`x0mq9r`}]]),Fe=i(`at-sign`,[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M16 8v5a3 3 0 0 0 6 0v-1a10 10 0 1 0-4 8`,key:`7n84p3`}]]),Ie=i(`calendar`,[[`path`,{d:`M8 2v4`,key:`1cmpym`}],[`path`,{d:`M16 2v4`,key:`4m81vk`}],[`rect`,{width:`18`,height:`18`,x:`3`,y:`4`,rx:`2`,key:`1hopcy`}],[`path`,{d:`M3 10h18`,key:`8toen8`}]]),Le=i(`circle-chevron-down`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m16 10-4 4-4-4`,key:`894hmk`}]]),Re=i(`clipboard-paste`,[[`path`,{d:`M11 14h10`,key:`1w8e9d`}],[`path`,{d:`M16 4h2a2 2 0 0 1 2 2v1.344`,key:`1e62lh`}],[`path`,{d:`m17 18 4-4-4-4`,key:`z2g111`}],[`path`,{d:`M8 4H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 1.793-1.113`,key:`bjbb7m`}],[`rect`,{x:`8`,y:`2`,width:`8`,height:`4`,rx:`1`,key:`ublpy`}]]),ze=i(`clock`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6l4 2`,key:`mmk7yg`}]]),Be=i(`eraser`,[[`path`,{d:`M21 21H8a2 2 0 0 1-1.42-.587l-3.994-3.999a2 2 0 0 1 0-2.828l10-10a2 2 0 0 1 2.829 0l5.999 6a2 2 0 0 1 0 2.828L12.834 21`,key:`g5wo59`}],[`path`,{d:`m5.082 11.09 8.828 8.828`,key:`1wx5vj`}]]),Ve=i(`external-link`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]),F=i(`eye-off`,[[`path`,{d:`M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49`,key:`ct8e1f`}],[`path`,{d:`M14.084 14.158a3 3 0 0 1-4.242-4.242`,key:`151rxh`}],[`path`,{d:`M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143`,key:`13bj9a`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),He=i(`funnel`,[[`path`,{d:`M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z`,key:`sc7q7i`}]]),Ue=i(`grip-vertical`,[[`circle`,{cx:`9`,cy:`12`,r:`1`,key:`1vctgf`}],[`circle`,{cx:`9`,cy:`5`,r:`1`,key:`hp0tcf`}],[`circle`,{cx:`9`,cy:`19`,r:`1`,key:`fkjjf6`}],[`circle`,{cx:`15`,cy:`12`,r:`1`,key:`1tmaij`}],[`circle`,{cx:`15`,cy:`5`,r:`1`,key:`19l28e`}],[`circle`,{cx:`15`,cy:`19`,r:`1`,key:`f4zoj3`}]]),I=i(`hash`,[[`line`,{x1:`4`,x2:`20`,y1:`9`,y2:`9`,key:`4lhtct`}],[`line`,{x1:`4`,x2:`20`,y1:`15`,y2:`15`,key:`vyu0kd`}],[`line`,{x1:`10`,x2:`8`,y1:`3`,y2:`21`,key:`1ggp8o`}],[`line`,{x1:`16`,x2:`14`,y1:`3`,y2:`21`,key:`weycgp`}]]),We=i(`image-off`,[[`line`,{x1:`2`,x2:`22`,y1:`2`,y2:`22`,key:`a6p6uj`}],[`path`,{d:`M10.41 10.41a2 2 0 1 1-2.83-2.83`,key:`1bzlo9`}],[`line`,{x1:`13.5`,x2:`6`,y1:`13.5`,y2:`21`,key:`1q0aeu`}],[`line`,{x1:`18`,x2:`21`,y1:`12`,y2:`15`,key:`5mozeu`}],[`path`,{d:`M3.59 3.59A1.99 1.99 0 0 0 3 5v14a2 2 0 0 0 2 2h14c.55 0 1.052-.22 1.41-.59`,key:`mmje98`}],[`path`,{d:`M21 15V5a2 2 0 0 0-2-2H9`,key:`43el77`}]]),L=i(`key-round`,[[`path`,{d:`M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z`,key:`1s6t7t`}],[`circle`,{cx:`16.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`w0ekpg`}]]),Ge=i(`link`,[[`path`,{d:`M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71`,key:`1cjeqo`}],[`path`,{d:`M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71`,key:`19qd67`}]]),Ke=i(`maximize-2`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`m21 3-7 7`,key:`1l2asr`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M9 21H3v-6`,key:`wtvkvv`}]]),R=i(`paintbrush`,[[`path`,{d:`m14.622 17.897-10.68-2.913`,key:`vj2p1u`}],[`path`,{d:`M18.376 2.622a1 1 0 1 1 3.002 3.002L17.36 9.643a.5.5 0 0 0 0 .707l.944.944a2.41 2.41 0 0 1 0 3.408l-.944.944a.5.5 0 0 1-.707 0L8.354 7.348a.5.5 0 0 1 0-.707l.944-.944a2.41 2.41 0 0 1 3.408 0l.944.944a.5.5 0 0 0 .707 0z`,key:`18tc5c`}],[`path`,{d:`M9 8c-1.804 2.71-3.97 3.46-6.583 3.948a.507.507 0 0 0-.302.819l7.32 8.883a1 1 0 0 0 1.185.204C12.735 20.405 16 16.792 16 15`,key:`ytzfxy`}]]),qe=i(`paperclip`,[[`path`,{d:`m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551`,key:`1miecu`}]]),Je=i(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]),Ye=i(`phone`,[[`path`,{d:`M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384`,key:`9njp5v`}]]),Xe=i(`replace`,[[`path`,{d:`M14 4a1 1 0 0 1 1-1`,key:`dhj8ez`}],[`path`,{d:`M15 10a1 1 0 0 1-1-1`,key:`1mnyi5`}],[`path`,{d:`M21 4a1 1 0 0 0-1-1`,key:`sfs9ap`}],[`path`,{d:`M21 9a1 1 0 0 1-1 1`,key:`mp6qeo`}],[`path`,{d:`m3 7 3 3 3-3`,key:`x25e72`}],[`path`,{d:`M6 10V5a2 2 0 0 1 2-2h2`,key:`15xut4`}],[`rect`,{x:`3`,y:`14`,width:`7`,height:`7`,rx:`1`,key:`1bkyp8`}]]),Ze=i(`scissors`,[[`circle`,{cx:`6`,cy:`6`,r:`3`,key:`1lh9wr`}],[`path`,{d:`M8.12 8.12 12 12`,key:`1alkpv`}],[`path`,{d:`M20 4 8.12 15.88`,key:`xgtan2`}],[`circle`,{cx:`6`,cy:`18`,r:`3`,key:`fqmcym`}],[`path`,{d:`M14.8 14.8 20 20`,key:`ptml3r`}]]),Qe=i(`search`,[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]),z=i(`square-check`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),$e=i(`type`,[[`path`,{d:`M12 4v16`,key:`1654pz`}],[`path`,{d:`M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2`,key:`e0r10z`}],[`path`,{d:`M9 20h6`,key:`s66wpe`}]]),et=i(`upload`,[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]),B=c(t(),1),V=l(),H=Object.defineProperty,U=(e,t)=>H(e,`name`,{value:t,configurable:!0}),tt=`Popover`,[nt,rt]=ee(tt,[ue]),it=ue(),[at,ot]=nt(tt),st=U(e=>{let{__scopePopover:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!1}=e,s=it(t),c=B.useRef(null),[l,u]=B.useState(!1),[d,f]=B.useState(0),[p,m]=B.useState(0),[h,g]=oe({prop:r,defaultProp:i??!1,onChange:a,caller:tt});return(0,V.jsx)(me,{...s,children:(0,V.jsx)(at,{scope:t,contentId:Oe(),titleId:Oe(),descriptionId:Oe(),titlePresent:d>0,descriptionPresent:p>0,setTitleCount:f,setDescriptionCount:m,triggerRef:c,open:h,onOpenChange:g,onOpenToggle:B.useCallback(()=>g(e=>!e),[g]),hasCustomAnchor:l,onCustomAnchorAdd:B.useCallback(()=>u(!0),[]),onCustomAnchorRemove:B.useCallback(()=>u(!1),[]),modal:o,children:n})})},`Popover`),ct=`PopoverTrigger`,lt=B.forwardRef(U(function(e,t){let{__scopePopover:n,...r}=e,i=ot(ct,n),a=it(n),o=se(t,i.triggerRef),s=(0,V.jsx)(ne.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.open?i.contentId:void 0,"data-state":bt(i.open),...r,ref:o,onClick:ae(e.onClick,i.onOpenToggle)});return i.hasCustomAnchor?s:(0,V.jsx)(ce,{asChild:!0,...a,children:s})},`PopoverTrigger`)),ut=`PopoverPortal`,[dt,ft]=nt(ut,{forceMount:void 0}),pt=U(e=>{let{__scopePopover:t,forceMount:n,children:r,container:i}=e,a=ot(ut,t);return(0,V.jsx)(dt,{scope:t,forceMount:n,children:(0,V.jsx)(T,{present:n||a.open,children:(0,V.jsx)(ve,{asChild:!0,container:i,children:r})})})},`PopoverPortal`),mt=`PopoverContent`,ht=B.forwardRef(U(function(e,t){let n=ft(mt,e.__scopePopover),{forceMount:r=n.forceMount,...i}=e,a=ot(mt,e.__scopePopover);return(0,V.jsx)(T,{present:r||a.open,children:a.modal?(0,V.jsx)(_t,{...i,ref:t}):(0,V.jsx)(vt,{...i,ref:t})})},`PopoverContent`)),gt=M(`PopoverContent.RemoveScroll`),_t=B.forwardRef(U(function(e,t){let n=ot(mt,e.__scopePopover),r=B.useRef(null),i=se(t,r),a=B.useRef(!1),{nodes:o,registry:s}=E();return B.useEffect(()=>{let e=r.current;if(e)return re(e)},[]),(0,V.jsx)(ye,{as:gt,allowPinchZoom:!0,shards:B.useMemo(()=>[r,...o.map(e=>({current:e}))],[r,o]),children:(0,V.jsx)(yt,{...e,ref:i,branchNodes:o,branchRegistry:s,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ae(e.onCloseAutoFocus,e=>{e.preventDefault(),a.current||n.triggerRef.current?.focus()}),onPointerDownOutside:ae(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0,r=t.button===2||n;a.current=r},{checkForDefaultPrevented:!1}),onFocusOutside:ae(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1})})})},`PopoverContentModal`)),vt=B.forwardRef(U(function(e,t){let n=ot(mt,e.__scopePopover),r=B.useRef(!1),i=B.useRef(!1);return(0,V.jsx)(yt,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})},`PopoverContentNonModal`)),yt=B.forwardRef(U(function(e,t){let{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:o,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onInteractOutside:u,"aria-describedby":d,branchNodes:f,branchRegistry:p,...m}=e,h=ot(mt,n),g=it(n),[_,v]=B.useState(null),y=se(t,v);return ie(_),w(),(0,V.jsx)(O,{registry:p,children:(0,V.jsx)(D,{asChild:!0,loop:!0,trapped:r,branches:f,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,V.jsx)(te,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:u,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onDismiss:()=>h.onOpenChange(!1),deferPointerDownOutside:!0,children:(0,V.jsx)(De,{"data-state":bt(h.open),role:`dialog`,id:h.contentId,"aria-labelledby":h.titlePresent?h.titleId:void 0,"aria-describedby":h.descriptionPresent?xt(d,h.descriptionId):d,...g,...m,ref:y,style:{...m.style,"--radix-popover-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-popover-content-available-width":`var(--radix-popper-available-width)`,"--radix-popover-content-available-height":`var(--radix-popper-available-height)`,"--radix-popover-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-popover-trigger-height":`var(--radix-popper-anchor-height)`}})})})})},`PopoverContentImpl`));function bt(e){return e?`open`:`closed`}U(bt,`getState`);function xt(...e){let t=new Set;for(let n of e)if(typeof n==`string`)for(let e of String(n).trim().split(/\s+/))e&&t.add(e);return t.size>0?Array.from(t).join(` `):void 0}U(xt,`concatAriaDescribedby`);function St(e,t=`,`){let n=e.startsWith(``),r=[],i=[],a=0,o=0,s=+!!n,c=1,l=e.length;for(;s<l;){let n=s,u=c,d=[],f=``,p=!1,m=!1,h=!1;for(;s<l;){let i=e.charAt(s);if(p){if(i===`"`){if(e.charAt(s+1)===`"`){f+=`"`,s+=2;continue}p=!1,s+=1;continue}i===`
|
|
2
|
-
`&&(c+=1),f+=i,s+=1}else if(i===`"`&&f===``&&!m)p=!0,m=!0,s+=1;else if(i===t)d.push(f),f=``,m=!1,s+=1;else{if(i===`\r`||i===`
|
|
3
|
-
`){let t=s;i===`\r`&&e.charAt(s+1)===`
|
|
4
|
-
`?(a+=1,s+=2):(i===`
|
|
5
|
-
`&&(o+=1),s+=1),c+=1,d.push(f),r.push({fields:d,start:n,end:t,line:u}),h=!0;break}f+=i,s+=1}}h||(p&&i.push({line:u,message:`a quoted field is never closed: a " is missing`}),d.push(f),r.push({fields:d,start:n,end:l,line:u}))}let u=e.charAt(l-1);return{source:e,records:r,dialect:{delimiter:t,newline:a>o?`\r
|
|
6
|
-
`:`
|
|
7
|
-
`,bom:n,finalNewline:l>+!!n&&(u===`
|
|
8
|
-
`||u===`\r`)},problems:i}}function Ct(e,t=`,`){return e.includes(t)||e.includes(`"`)||e.includes(`
|
|
9
|
-
`)||e.includes(`\r`)?`"${e.replace(/"/g,`""`)}"`:e}function wt(e,t=`,`){return e.length===1&&e[0]===``?`""`:e.map(e=>Ct(e,t)).join(t)}function Tt(e){return e.map(e=>wt(e,` `)).join(`
|
|
10
|
-
`)}function Et(e){return St(e,` `).records.map(e=>e.fields)}var Dt={type:`text`};[...new Set(Object.values({text:[`is`,`is-not`,`contains`,`not-contains`,`starts-with`,`ends-with`,`empty`,`not-empty`],number:[`=`,`!=`,`<`,`<=`,`>`,`>=`,`between`,`empty`,`not-empty`],select:[`is`,`is-not`,`in`,`not-in`,`empty`,`not-empty`],"multi-select":[`has`,`has-any`,`has-all`,`has-none`,`empty`,`not-empty`],date:[`on`,`before`,`after`,`on-or-before`,`on-or-after`,`between`,`empty`,`not-empty`],checkbox:[`is`],url:[`is`,`is-not`,`contains`,`not-contains`,`starts-with`,`ends-with`,`empty`,`not-empty`],email:[`is`,`is-not`,`contains`,`not-contains`,`starts-with`,`ends-with`,`empty`,`not-empty`],phone:[`is`,`is-not`,`contains`,`not-contains`,`starts-with`,`ends-with`,`empty`,`not-empty`],file:[`empty`,`not-empty`,`contains`]}).flat())];var Ot=e=>`all`in e||`any`in e,W=(e,t)=>e.columns[t]??Dt;function kt(e){let t=e+1,n=``;for(;t>0;){let e=(t-1)%26;n=String.fromCharCode(65+e)+n,t=Math.floor((t-1)/26)}return n}function At(e,t=e){let n=`${kt(Math.min(e.column,t.column))}${String(Math.min(e.row,t.row)+1)}`,r=`${kt(Math.max(e.column,t.column))}${String(Math.max(e.row,t.row)+1)}`;return n===r?n:`${n}:${r}`}function jt(e){let t=St(e),n=[...t.problems],[r,...i]=t.records,a=r?r.fields.map(e=>e.trim()):[];if(r){let e=new Map;a.forEach((t,i)=>{if(t===``){n.push({line:r.line,message:`column ${String(i+1)} has no name in the header`});return}let a=e.get(t);a===void 0?e.set(t,i):n.push({line:r.line,message:`"${t}" names columns ${String(a+1)} and ${String(i+1)}: each column needs a name of its own`})})}let o=a.length,s=[],c=[];for(let e of i){let t=e.fields,r=t.length===1&&t[0]===``;!r&&t.length>o&&t.slice(o).some(e=>e!==``)&&n.push({line:e.line,message:`this row has ${String(t.length)} fields, more than the header's ${String(o)}`});let i=r?[]:t.slice(0,o);for(;i.length<o;)i.push(``);s.push(i),c.push(e.line)}return{data:{columns:a,rows:s},csv:t,problems:n,lines:c}}function Mt(e,t){if(e.columns.length!==t.columns.length||e.rows.length!==t.rows.length||e.columns.some((e,n)=>e!==t.columns[n]))return!1;for(let n=0;n<e.rows.length;n++){let r=e.rows[n]??[],i=t.rows[n]??[];for(let t=0;t<e.columns.length;t++)if((r[t]??``)!==(i[t]??``))return!1}return!0}var Nt=Symbol.for(`yaml.alias`),Pt=Symbol.for(`yaml.document`),Ft=Symbol.for(`yaml.map`),It=Symbol.for(`yaml.pair`),Lt=Symbol.for(`yaml.scalar`),Rt=Symbol.for(`yaml.seq`),zt=Symbol.for(`yaml.node.type`),Bt=e=>!!e&&typeof e==`object`&&e[zt]===Nt,Vt=e=>!!e&&typeof e==`object`&&e[zt]===Pt,G=e=>!!e&&typeof e==`object`&&e[zt]===Ft,K=e=>!!e&&typeof e==`object`&&e[zt]===It,q=e=>!!e&&typeof e==`object`&&e[zt]===Lt,Ht=e=>!!e&&typeof e==`object`&&e[zt]===Rt;function J(e){if(e&&typeof e==`object`)switch(e[zt]){case Ft:case Rt:return!0}return!1}function Y(e){if(e&&typeof e==`object`)switch(e[zt]){case Nt:case Ft:case Lt:case Rt:return!0}return!1}var Ut=e=>(q(e)||J(e))&&!!e.anchor,Wt=Symbol(`break visit`),Gt=Symbol(`skip children`),Kt=Symbol(`remove node`);function qt(e,t){let n=Yt(t);Vt(e)?Jt(null,e.contents,n,Object.freeze([e]))===Kt&&(e.contents=null):Jt(null,e,n,Object.freeze([]))}qt.BREAK=Wt,qt.SKIP=Gt,qt.REMOVE=Kt;function Jt(e,t,n,r){let i=Xt(e,t,n,r);if(Y(i)||K(i))return Zt(e,r,i),Jt(e,i,n,r);if(typeof i!=`symbol`){if(J(t)){r=Object.freeze(r.concat(t));for(let e=0;e<t.items.length;++e){let i=Jt(e,t.items[e],n,r);if(typeof i==`number`)e=i-1;else if(i===Wt)return Wt;else i===Kt&&(t.items.splice(e,1),--e)}}else if(K(t)){r=Object.freeze(r.concat(t));let e=Jt(`key`,t.key,n,r);if(e===Wt)return Wt;e===Kt&&(t.key=null);let i=Jt(`value`,t.value,n,r);if(i===Wt)return Wt;i===Kt&&(t.value=null)}}return i}function Yt(e){return typeof e==`object`&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function Xt(e,t,n,r){if(typeof n==`function`)return n(e,t,r);if(G(t))return n.Map?.(e,t,r);if(Ht(t))return n.Seq?.(e,t,r);if(K(t))return n.Pair?.(e,t,r);if(q(t))return n.Scalar?.(e,t,r);if(Bt(t))return n.Alias?.(e,t,r)}function Zt(e,t,n){let r=t[t.length-1];if(J(r))r.items[e]=n;else if(K(r))e===`key`?r.key=n:r.value=n;else if(Vt(r))r.contents=n;else{let e=Bt(r)?`alias`:`scalar`;throw Error(`Cannot replace node with ${e} parent`)}}var Qt={"!":`%21`,",":`%2C`,"[":`%5B`,"]":`%5D`,"{":`%7B`,"}":`%7D`},$t=e=>e.replace(/[!,[\]{}]/g,e=>Qt[e]),en=class e{constructor(t,n){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},e.defaultYaml,t),this.tags=Object.assign({},e.defaultTags,n)}clone(){let t=new e(this.yaml,this.tags);return t.docStart=this.docStart,t}atDocument(){let t=new e(this.yaml,this.tags);switch(this.yaml.version){case`1.1`:this.atNextDocument=!0;break;case`1.2`:this.atNextDocument=!1,this.yaml={explicit:e.defaultYaml.explicit,version:`1.2`},this.tags=Object.assign({},e.defaultTags)}return t}add(t,n){this.atNextDocument&&=(this.yaml={explicit:e.defaultYaml.explicit,version:`1.1`},this.tags=Object.assign({},e.defaultTags),!1);let r=t.trim().split(/[ \t]+/),i=r.shift();switch(i){case`%TAG`:{if(r.length!==2&&(n(0,`%TAG directive should contain exactly two parts`),r.length<2))return!1;let[e,t]=r;return this.tags[e]=t,!0}case`%YAML`:{if(this.yaml.explicit=!0,r.length!==1)return n(0,`%YAML directive should contain exactly one part`),!1;let[e]=r;if(e===`1.1`||e===`1.2`)return this.yaml.version=e,!0;{let t=/^\d+\.\d+$/.test(e);return n(6,`Unsupported YAML version ${e}`,t),!1}}default:return n(0,`Unknown directive ${i}`,!0),!1}}tagName(e,t){if(e===`!`)return`!`;if(e[0]!==`!`)return t(`Not a valid tag: ${e}`),null;if(e[1]===`<`){let n=e.slice(2,-1);return n===`!`||n===`!!`?(t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==`>`&&t(`Verbatim tags must end with a >`),n)}let[,n,r]=e.match(/^(.*!)([^!]*)$/s);r||t(`The ${e} tag has no suffix`);let i=this.tags[n];if(i)try{return i+decodeURIComponent(r)}catch(e){return t(String(e)),null}return n===`!`?e:(t(`Could not resolve tag: ${e}`),null)}tagString(e){for(let[t,n]of Object.entries(this.tags))if(e.startsWith(n))return t+$t(e.substring(n.length));return e[0]===`!`?e:`!<${e}>`}toString(e){let t=this.yaml.explicit?[`%YAML ${this.yaml.version||`1.2`}`]:[],n=Object.entries(this.tags),r;if(e&&n.length>0&&Y(e.contents)){let t={};qt(e.contents,(e,n)=>{Y(n)&&n.tag&&(t[n.tag]=!0)}),r=Object.keys(t)}else r=[];for(let[i,a]of n)i===`!!`&&a===`tag:yaml.org,2002:`||e&&!r.some(e=>e.startsWith(a))||t.push(`%TAG ${i} ${a}`);return t.join(`
|
|
11
|
-
`)}};en.defaultYaml={explicit:!1,version:`1.2`},en.defaultTags={"!!":`tag:yaml.org,2002:`};function tn(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let t=`Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`;throw Error(t)}return!0}function nn(e){let t=new Set;return qt(e,{Value(e,n){n.anchor&&t.add(n.anchor)}}),t}function rn(e,t){for(let n=1;;++n){let r=`${e}${n}`;if(!t.has(r))return r}}function an(e,t){let n=[],r=new Map,i=null;return{onAnchor:r=>{n.push(r),i??=nn(e);let a=rn(t,i);return i.add(a),a},setAnchors:()=>{for(let e of n){let t=r.get(e);if(typeof t==`object`&&t.anchor&&(q(t.node)||J(t.node)))t.node.anchor=t.anchor;else{let t=Error(`Failed to resolve repeated object (this should not happen)`);throw t.source=e,t}}},sourceObjects:r}}function on(e,t,n,r){if(r&&typeof r==`object`){if(Array.isArray(r))for(let t=0,n=r.length;t<n;++t){let n=r[t],i=on(e,r,String(t),n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}else if(r instanceof Map)for(let t of Array.from(r.keys())){let n=r.get(t),i=on(e,r,t,n);i===void 0?r.delete(t):i!==n&&r.set(t,i)}else if(r instanceof Set)for(let t of Array.from(r)){let n=on(e,r,t,t);n===void 0?r.delete(t):n!==t&&(r.delete(t),r.add(n))}else for(let[t,n]of Object.entries(r)){let i=on(e,r,t,n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}}return e.call(t,n,r)}function X(e,t,n){if(Array.isArray(e))return e.map((e,t)=>X(e,String(t),n));if(e&&typeof e.toJSON==`function`){if(!n||!Ut(e))return e.toJSON(t,n);let r={aliasCount:0,count:1,res:void 0};n.anchors.set(e,r),n.onCreate=e=>{r.res=e,delete n.onCreate};let i=e.toJSON(t,n);return n.onCreate&&n.onCreate(i),i}return typeof e==`bigint`&&!n?.keep?Number(e):e}var sn=class{constructor(e){Object.defineProperty(this,zt,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:t,maxAliasCount:n,onAnchor:r,reviver:i}={}){if(!Vt(e))throw TypeError(`A document argument is required`);let a={anchors:new Map,doc:e,keep:!0,mapAsMap:t===!0,mapKeyWarned:!1,maxAliasCount:typeof n==`number`?n:100},o=X(this,``,a);if(typeof r==`function`)for(let{count:e,res:t}of a.anchors.values())r(t,e);return typeof i==`function`?on(i,{"":o},``,o):o}},cn=class extends sn{constructor(e){super(Nt),this.source=e,Object.defineProperty(this,"tag",{set(){throw Error(`Alias nodes cannot have tags`)}})}resolve(e,t){if(t?.maxAliasCount===0)throw ReferenceError(`Alias resolution is disabled`);let n;t?.aliasResolveCache?n=t.aliasResolveCache:(n=[],qt(e,{Node:(e,t)=>{(Bt(t)||Ut(t))&&n.push(t)}}),t&&(t.aliasResolveCache=n));let r;for(let e of n){if(e===this)break;e.anchor===this.source&&(r=e)}if(r&&t){let{anchors:e,doc:n,maxAliasCount:i}=t,a=e.get(r);if(a||=(X(r,null,t),e.get(r)),a?.res===void 0)throw ReferenceError(`This should not happen: Alias anchor was not resolved?`);if(i>=0&&(a.count+=1,a.aliasCount===0&&(a.aliasCount=ln(n,r,e)),a.count*a.aliasCount>i))throw ReferenceError(`Excessive alias count indicates a resource exhaustion attack`)}return r}toJSON(e,t){if(!t)return{source:this.source};let n=this.resolve(t.doc,t);if(!n){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(e)}return t.anchors.get(n).res}toString(e,t,n){let r=`*${this.source}`;if(e){if(tn(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(e)}if(e.implicitKey)return`${r} `}return r}};function ln(e,t,n){if(Bt(t)){let r=t.resolve(e),i=n&&r&&n.get(r);return i?i.count*i.aliasCount:0}if(J(t)){let r=0;for(let i of t.items){let t=ln(e,i,n);t>r&&(r=t)}return r}if(K(t)){let r=ln(e,t.key,n),i=ln(e,t.value,n);return Math.max(r,i)}return 1}var un=e=>!e||typeof e!=`function`&&typeof e!=`object`,Z=class extends sn{constructor(e){super(Lt),this.value=e}toJSON(e,t){return t?.keep?this.value:X(this.value,e,t)}toString(){return String(this.value)}};Z.BLOCK_FOLDED=`BLOCK_FOLDED`,Z.BLOCK_LITERAL=`BLOCK_LITERAL`,Z.PLAIN=`PLAIN`,Z.QUOTE_DOUBLE=`QUOTE_DOUBLE`,Z.QUOTE_SINGLE=`QUOTE_SINGLE`;var dn=`tag:yaml.org,2002:`;function fn(e,t,n){if(t){let e=n.filter(e=>e.tag===t),r=e.find(e=>!e.format)??e[0];if(!r)throw Error(`Tag ${t} not found`);return r}return n.find(t=>t.identify?.(e)&&!t.format)}function pn(e,t,n){if(Vt(e)&&(e=e.contents),Y(e))return e;if(K(e)){let t=n.schema[Ft].createNode?.(n.schema,null,n);return t.items.push(e),t}(e instanceof String||e instanceof Number||e instanceof Boolean||typeof BigInt<`u`&&e instanceof BigInt)&&(e=e.valueOf());let{aliasDuplicateObjects:r,onAnchor:i,onTagObj:a,schema:o,sourceObjects:s}=n,c;if(r&&e&&typeof e==`object`){if(c=s.get(e),c)return c.anchor??(c.anchor=i(e)),new cn(c.anchor);c={anchor:null,node:null},s.set(e,c)}t?.startsWith(`!!`)&&(t=dn+t.slice(2));let l=fn(e,t,o.tags);if(!l){if(e&&typeof e.toJSON==`function`&&(e=e.toJSON()),!e||typeof e!=`object`){let t=new Z(e);return c&&(c.node=t),t}l=e instanceof Map?o[Ft]:Symbol.iterator in Object(e)?o[Rt]:o[Ft]}a&&(a(l),delete n.onTagObj);let u=l?.createNode?l.createNode(n.schema,e,n):typeof l?.nodeClass?.from==`function`?l.nodeClass.from(n.schema,e,n):new Z(e);return t?u.tag=t:l.default||(u.tag=l.tag),c&&(c.node=u),u}function mn(e,t,n){let r=n;for(let e=t.length-1;e>=0;--e){let n=t[e];if(typeof n==`number`&&Number.isInteger(n)&&n>=0){let e=[];e[n]=r,r=e}else r=new Map([[n,r]])}return pn(r,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error(`This should not happen, please report a bug.`)},schema:e,sourceObjects:new Map})}var hn=e=>e==null||typeof e==`object`&&!!e[Symbol.iterator]().next().done,gn=class extends sn{constructor(e,t){super(e),Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(t.schema=e),t.items=t.items.map(t=>Y(t)||K(t)?t.clone(e):t),this.range&&(t.range=this.range.slice()),t}addIn(e,t){if(hn(e))this.add(t);else{let[n,...r]=e,i=this.get(n,!0);if(J(i))i.addIn(r,t);else if(i===void 0&&this.schema)this.set(n,mn(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){let[t,...n]=e;if(n.length===0)return this.delete(t);let r=this.get(t,!0);if(J(r))return r.deleteIn(n);throw Error(`Expected YAML collection at ${t}. Remaining path: ${n}`)}getIn(e,t){let[n,...r]=e,i=this.get(n,!0);return r.length===0?!t&&q(i)?i.value:i:J(i)?i.getIn(r,t):void 0}hasAllNullValues(e){return this.items.every(t=>{if(!K(t))return!1;let n=t.value;return n==null||e&&q(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){let[t,...n]=e;if(n.length===0)return this.has(t);let r=this.get(t,!0);return J(r)?r.hasIn(n):!1}setIn(e,t){let[n,...r]=e;if(r.length===0)this.set(n,t);else{let e=this.get(n,!0);if(J(e))e.setIn(r,t);else if(e===void 0&&this.schema)this.set(n,mn(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}},_n=e=>e.replace(/^(?!$)(?: $)?/gm,`#`);function vn(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}var yn=(e,t,n)=>e.endsWith(`
|
|
12
|
-
`)?vn(n,t):n.includes(`
|
|
13
|
-
`)?`
|
|
14
|
-
`+vn(n,t):(e.endsWith(` `)?``:` `)+n,bn=`flow`,xn=`block`,Sn=`quoted`;function Cn(e,t,n=`flow`,{indentAtStart:r,lineWidth:i=80,minContentWidth:a=20,onFold:o,onOverflow:s}={}){if(!i||i<0)return e;i<a&&(a=0);let c=Math.max(1+a,1+i-t.length);if(e.length<=c)return e;let l=[],u={},d=i-t.length;typeof r==`number`&&(r>i-Math.max(2,a)?l.push(0):d=i-r);let f,p,m=!1,h=-1,g=-1,_=-1;n===`block`&&(h=wn(e,h,t.length),h!==-1&&(d=h+c));for(let r;r=e[h+=1];){if(n===`quoted`&&r===`\\`){switch(g=h,e[h+1]){case`x`:h+=3;break;case`u`:h+=5;break;case`U`:h+=9;break;default:h+=1}_=h}if(r===`
|
|
15
|
-
`)n===`block`&&(h=wn(e,h,t.length)),d=h+t.length+c,f=void 0;else{if(r===` `&&p&&p!==` `&&p!==`
|
|
16
|
-
`&&p!==` `){let t=e[h+1];t&&t!==` `&&t!==`
|
|
17
|
-
`&&t!==` `&&(f=h)}if(h>=d){if(f)l.push(f),d=f+c,f=void 0;else if(n===`quoted`){for(;p===` `||p===` `;)p=r,r=e[h+=1],m=!0;let t=h>_+1?h-2:g-1;if(u[t])return e;l.push(t),u[t]=!0,d=t+c,f=void 0}else m=!0}}p=r}if(m&&s&&s(),l.length===0)return e;o&&o();let v=e.slice(0,l[0]);for(let r=0;r<l.length;++r){let i=l[r],a=l[r+1]||e.length;i===0?v=`\n${t}${e.slice(0,a)}`:(n===`quoted`&&u[i]&&(v+=`${e[i]}\\`),v+=`\n${t}${e.slice(i+1,a)}`)}return v}function wn(e,t,n){let r=t,i=t+1,a=e[i];for(;a===` `||a===` `;)if(t<i+n)a=e[++t];else{do a=e[++t];while(a&&a!==`
|
|
18
|
-
`);r=t,i=t+1,a=e[i]}return r}var Tn=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),En=e=>/^(%|---|\.\.\.)/m.test(e);function Dn(e,t,n){if(!t||t<0)return!1;let r=t-n,i=e.length;if(i<=r)return!1;for(let t=0,n=0;t<i;++t)if(e[t]===`
|
|
19
|
-
`){if(t-n>r)return!0;if(n=t+1,i-n<=r)return!1}return!0}function On(e,t){let n=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return n;let{implicitKey:r}=t,i=t.options.doubleQuotedMinMultiLineLength,a=t.indent||(En(e)?` `:``),o=``,s=0;for(let e=0,t=n[e];t;t=n[++e])if(t===` `&&n[e+1]===`\\`&&n[e+2]===`n`&&(o+=n.slice(s,e)+`\\ `,e+=1,s=e,t=`\\`),t===`\\`)switch(n[e+1]){case`u`:{o+=n.slice(s,e);let t=n.substr(e+2,4);switch(t){case`0000`:o+=`\\0`;break;case`0007`:o+=`\\a`;break;case`000b`:o+=`\\v`;break;case`001b`:o+=`\\e`;break;case`0085`:o+=`\\N`;break;case`00a0`:o+=`\\_`;break;case`2028`:o+=`\\L`;break;case`2029`:o+=`\\P`;break;default:t.substr(0,2)===`00`?o+=`\\x`+t.substr(2):o+=n.substr(e,6)}e+=5,s=e+1}break;case`n`:if(r||n[e+2]===`"`||n.length<i)e+=1;else{for(o+=n.slice(s,e)+`
|
|
20
|
-
|
|
21
|
-
`;n[e+2]===`\\`&&n[e+3]===`n`&&n[e+4]!==`"`;)o+=`
|
|
22
|
-
`,e+=2;o+=a,n[e+2]===` `&&(o+=`\\`),e+=1,s=e+1}break;default:e+=1}return o=s?o+n.slice(s):n,r?o:Cn(o,a,Sn,Tn(t,!1))}function kn(e,t){if(t.options.singleQuote===!1||t.implicitKey&&e.includes(`
|
|
23
|
-
`)||/[ \t]\n|\n[ \t]/.test(e))return On(e,t);let n=t.indent||(En(e)?` `:``),r=`'`+e.replace(/'/g,`''`).replace(/\n+/g,`$&\n${n}`)+`'`;return t.implicitKey?r:Cn(r,n,bn,Tn(t,!1))}function An(e,t){let{singleQuote:n}=t.options,r;if(n===!1)r=On;else{let t=e.includes(`"`),i=e.includes(`'`);r=t&&!i?kn:i&&!t?On:n?kn:On}return r(e,t)}var jn;try{jn=RegExp(`(^|(?<!
|
|
24
|
-
))
|
|
25
|
-
+(?!
|
|
26
|
-
|$)`,`g`)}catch{jn=/\n+(?!\n|$)/g}function Mn({comment:e,type:t,value:n},r,i,a){let{blockQuote:o,commentString:s,lineWidth:c}=r.options;if(!o||/\n[\t ]+$/.test(n))return An(n,r);let l=r.indent||(r.forceBlockIndent||En(n)?` `:``),u=o===`literal`?!0:o===`folded`||t===Z.BLOCK_FOLDED?!1:t===Z.BLOCK_LITERAL||!Dn(n,c,l.length);if(!n)return u?`|
|
|
27
|
-
`:`>
|
|
28
|
-
`;let d,f;for(f=n.length;f>0;--f){let e=n[f-1];if(e!==`
|
|
29
|
-
`&&e!==` `&&e!==` `)break}let p=n.substring(f),m=p.indexOf(`
|
|
30
|
-
`);m===-1?d=`-`:n===p||m!==p.length-1?(d=`+`,a&&a()):d=``,p&&=(n=n.slice(0,-p.length),p[p.length-1]===`
|
|
31
|
-
`&&(p=p.slice(0,-1)),p.replace(jn,`$&${l}`));let h=!1,g,_=-1;for(g=0;g<n.length;++g){let e=n[g];if(e===` `)h=!0;else if(e===`
|
|
32
|
-
`)_=g;else break}let v=n.substring(0,_<g?_+1:g);v&&=(n=n.substring(v.length),v.replace(/\n+/g,`$&${l}`));let y=(h?l?`2`:`1`:``)+d;if(e&&(y+=` `+s(e.replace(/ ?[\r\n]+/g,` `)),i&&i()),!u){let e=n.replace(/\n+/g,`
|
|
33
|
-
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,`$1$2`).replace(/\n+/g,`$&${l}`),i=!1,a=Tn(r,!0);o!==`folded`&&t!==Z.BLOCK_FOLDED&&(a.onOverflow=()=>{i=!0});let s=Cn(`${v}${e}${p}`,l,xn,a);if(!i)return`>${y}\n${l}${s}`}return n=n.replace(/\n+/g,`$&${l}`),`|${y}\n${l}${v}${n}${p}`}function Nn(e,t,n,r){let{type:i,value:a}=e,{actualString:o,implicitKey:s,indent:c,indentStep:l,inFlow:u}=t;if(s&&a.includes(`
|
|
34
|
-
`)||u&&/[[\]{},]/.test(a))return An(a,t);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(a))return s||u||!a.includes(`
|
|
35
|
-
`)?An(a,t):Mn(e,t,n,r);if(!s&&!u&&i!==Z.PLAIN&&a.includes(`
|
|
36
|
-
`))return Mn(e,t,n,r);if(En(a)){if(c===``)return t.forceBlockIndent=!0,Mn(e,t,n,r);if(s&&c===l)return An(a,t)}let d=a.replace(/\n+/g,`$&\n${c}`);if(o){let e=e=>e.default&&e.tag!==`tag:yaml.org,2002:str`&&e.test?.test(d),{compat:n,tags:r}=t.doc.schema;if(r.some(e)||n?.some(e))return An(a,t)}return s?d:Cn(d,c,bn,Tn(t,!1))}function Pn(e,t,n,r){let{implicitKey:i,inFlow:a}=t,o=typeof e.value==`string`?e:Object.assign({},e,{value:String(e.value)}),{type:s}=e;s!==Z.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(s=Z.QUOTE_DOUBLE);let c=e=>{switch(e){case Z.BLOCK_FOLDED:case Z.BLOCK_LITERAL:return i||a?An(o.value,t):Mn(o,t,n,r);case Z.QUOTE_DOUBLE:return On(o.value,t);case Z.QUOTE_SINGLE:return kn(o.value,t);case Z.PLAIN:return Nn(o,t,n,r);default:return null}},l=c(s);if(l===null){let{defaultKeyType:e,defaultStringType:n}=t.options,r=i&&e||n;if(l=c(r),l===null)throw Error(`Unsupported default string type ${r}`)}return l}function Fn(e,t){let n=Object.assign({blockQuote:!0,commentString:_n,defaultKeyType:null,defaultStringType:`PLAIN`,directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:`false`,flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:`null`,simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:`true`,verifyAliasOrder:!0},e.schema.toStringOptions,t),r;switch(n.collectionStyle){case`block`:r=!1;break;case`flow`:r=!0;break;default:r=null}return{anchors:new Set,doc:e,flowCollectionPadding:n.flowCollectionPadding?` `:``,indent:``,indentStep:typeof n.indent==`number`?` `.repeat(n.indent):` `,inFlow:r,options:n}}function In(e,t){if(t.tag){let n=e.filter(e=>e.tag===t.tag);if(n.length>0)return n.find(e=>e.format===t.format)??n[0]}let n,r;if(q(t)){r=t.value;let i=e.filter(e=>e.identify?.(r));if(i.length>1){let e=i.filter(e=>e.test);e.length>0&&(i=e)}n=i.find(e=>e.format===t.format)??i.find(e=>!e.format)}else r=t,n=e.find(e=>e.nodeClass&&r instanceof e.nodeClass);if(!n){let e=r?.constructor?.name??(r===null?`null`:typeof r);throw Error(`Tag not resolved for ${e} value`)}return n}function Ln(e,t,{anchors:n,doc:r}){if(!r.directives)return``;let i=[],a=(q(e)||J(e))&&e.anchor;a&&tn(a)&&(n.add(a),i.push(`&${a}`));let o=e.tag??(t.default?null:t.tag);return o&&i.push(r.directives.tagString(o)),i.join(` `)}function Rn(e,t,n,r){if(K(e))return e.toString(t,n,r);if(Bt(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw TypeError(`Cannot stringify circular structure without alias nodes`);t.resolvedAliases?t.resolvedAliases.add(e):t.resolvedAliases=new Set([e]),e=e.resolve(t.doc)}let i,a=Y(e)?e:t.doc.createNode(e,{onTagObj:e=>i=e});i??=In(t.doc.schema.tags,a);let o=Ln(a,i,t);o.length>0&&(t.indentAtStart=(t.indentAtStart??0)+o.length+1);let s=typeof i.stringify==`function`?i.stringify(a,t,n,r):q(a)?Pn(a,t,n,r):a.toString(t,n,r);return o?q(a)||s[0]===`{`||s[0]===`[`?`${o} ${s}`:`${o}\n${t.indent}${s}`:s}function zn({key:e,value:t},n,r,i){let{allNullValues:a,doc:o,indent:s,indentStep:c,options:{commentString:l,indentSeq:u,simpleKeys:d}}=n,f=Y(e)&&e.comment||null;if(d){if(f)throw Error(`With simple keys, key nodes cannot have comments`);if(J(e)||!Y(e)&&typeof e==`object`)throw Error(`With simple keys, collection cannot be used as a key value`)}let p=!d&&(!e||f&&t==null&&!n.inFlow||J(e)||(q(e)?e.type===Z.BLOCK_FOLDED||e.type===Z.BLOCK_LITERAL:typeof e==`object`));n=Object.assign({},n,{allNullValues:!1,implicitKey:!p&&(d||!a),indent:s+c});let m=!1,h=!1,g=Rn(e,n,()=>m=!0,()=>h=!0);if(!p&&!n.inFlow&&g.length>1024){if(d)throw Error(`With simple keys, single line scalar must not span more than 1024 characters`);p=!0}if(n.inFlow){if(a||t==null)return m&&r&&r(),g===``?`?`:p?`? ${g}`:g}else if(a&&!d||t==null&&p)return g=`? ${g}`,f&&!m?g+=yn(g,n.indent,l(f)):h&&i&&i(),g;m&&(f=null),p?(f&&(g+=yn(g,n.indent,l(f))),g=`? ${g}\n${s}:`):(g=`${g}:`,f&&(g+=yn(g,n.indent,l(f))));let _,v,y;Y(t)?(_=!!t.spaceBefore,v=t.commentBefore,y=t.comment):(_=!1,v=null,y=null,t&&typeof t==`object`&&(t=o.createNode(t))),n.implicitKey=!1,!p&&!f&&q(t)&&(n.indentAtStart=g.length+1),h=!1,!u&&c.length>=2&&!n.inFlow&&!p&&Ht(t)&&!t.flow&&!t.tag&&!t.anchor&&(n.indent=n.indent.substring(2));let b=!1,x=Rn(t,n,()=>b=!0,()=>h=!0),S=` `;if(f||_||v){if(S=_?`
|
|
37
|
-
`:``,v){let e=l(v);S+=`\n${vn(e,n.indent)}`}x===``&&!n.inFlow?S===`
|
|
38
|
-
`&&y&&(S=`
|
|
39
|
-
|
|
40
|
-
`):S+=`\n${n.indent}`}else if(!p&&J(t)){let e=x[0],r=x.indexOf(`
|
|
41
|
-
`),i=r!==-1,a=n.inFlow??t.flow??t.items.length===0;if(i||!a){let t=!1;if(i&&(e===`&`||e===`!`)){let n=x.indexOf(` `);e===`&`&&n!==-1&&n<r&&x[n+1]===`!`&&(n=x.indexOf(` `,n+1)),(n===-1||r<n)&&(t=!0)}t||(S=`\n${n.indent}`)}}else(x===``||x[0]===`
|
|
42
|
-
`)&&(S=``);return g+=S+x,n.inFlow?b&&r&&r():y&&!b?g+=yn(g,n.indent,l(y)):h&&i&&i(),g}function Bn(e,t){(e===`debug`||e===`warn`)&&console.warn(t)}var Vn=`<<`,Hn={identify:e=>e===Vn||typeof e==`symbol`&&e.description===Vn,default:`key`,tag:`tag:yaml.org,2002:merge`,test:/^<<$/,resolve:()=>Object.assign(new Z(Symbol(Vn)),{addToJSMap:Wn}),stringify:()=>Vn},Un=(e,t)=>(Hn.identify(t)||q(t)&&(!t.type||t.type===Z.PLAIN)&&Hn.identify(t.value))&&e?.doc.schema.tags.some(e=>e.tag===Hn.tag&&e.default);function Wn(e,t,n){let r=Kn(e,n);if(Ht(r))for(let n of r.items)Gn(e,t,n);else if(Array.isArray(r))for(let n of r)Gn(e,t,n);else Gn(e,t,r)}function Gn(e,t,n){let r=Kn(e,n);if(!G(r))throw Error(`Merge sources must be maps or map aliases`);let i=r.toJSON(null,e,Map);for(let[e,n]of i)t instanceof Map?t.has(e)||t.set(e,n):t instanceof Set?t.add(e):Object.prototype.hasOwnProperty.call(t,e)||Object.defineProperty(t,e,{value:n,writable:!0,enumerable:!0,configurable:!0});return t}function Kn(e,t){return e&&Bt(t)?t.resolve(e.doc,e):t}function qn(e,t,{key:n,value:r}){if(Y(n)&&n.addToJSMap)n.addToJSMap(e,t,r);else if(Un(e,n))Wn(e,t,r);else{let i=X(n,``,e);if(t instanceof Map)t.set(i,X(r,i,e));else if(t instanceof Set)t.add(i);else{let a=Jn(n,i,e),o=X(r,a,e);a in t?Object.defineProperty(t,a,{value:o,writable:!0,enumerable:!0,configurable:!0}):t[a]=o}}return t}function Jn(e,t,n){if(t===null)return``;if(typeof t!=`object`)return String(t);if(Y(e)&&n?.doc){let t=Fn(n.doc,{});t.anchors=new Set;for(let e of n.anchors.keys())t.anchors.add(e.anchor);t.inFlow=!0,t.inStringifyKey=!0;let r=e.toString(t);if(!n.mapKeyWarned){let e=JSON.stringify(r);e.length>40&&(e=e.substring(0,36)+`..."`),Bn(n.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${e}. Set mapAsMap: true to use object keys.`),n.mapKeyWarned=!0}return r}return JSON.stringify(t)}function Yn(e,t,n){return new Xn(pn(e,void 0,n),pn(t,void 0,n))}var Xn=class e{constructor(e,t=null){Object.defineProperty(this,zt,{value:It}),this.key=e,this.value=t}clone(t){let{key:n,value:r}=this;return Y(n)&&(n=n.clone(t)),Y(r)&&(r=r.clone(t)),new e(n,r)}toJSON(e,t){return qn(t,t?.mapAsMap?new Map:{},this)}toString(e,t,n){return e?.doc?zn(this,e,t,n):JSON.stringify(this)}};function Zn(e,t,n){return(t.inFlow??e.flow?$n:Qn)(e,t,n)}function Qn({comment:e,items:t},n,{blockItemPrefix:r,flowChars:i,itemIndent:a,onChompKeep:o,onComment:s}){let{indent:c,options:{commentString:l}}=n,u=Object.assign({},n,{indent:a,type:null}),d=!1,f=[];for(let e=0;e<t.length;++e){let i=t[e],o=null;if(Y(i))!d&&i.spaceBefore&&f.push(``),er(n,f,i.commentBefore,d),i.comment&&(o=i.comment);else if(K(i)){let e=Y(i.key)?i.key:null;e&&(!d&&e.spaceBefore&&f.push(``),er(n,f,e.commentBefore,d))}d=!1;let s=Rn(i,u,()=>o=null,()=>d=!0);o&&(s+=yn(s,a,l(o))),d&&o&&(d=!1),f.push(r+s)}let p;if(f.length===0)p=i.start+i.end;else{p=f[0];for(let e=1;e<f.length;++e){let t=f[e];p+=t?`\n${c}${t}`:`
|
|
43
|
-
`}}return e?(p+=`
|
|
44
|
-
`+vn(l(e),c),s&&s()):d&&o&&o(),p}function $n({items:e},t,{flowChars:n,itemIndent:r}){let{indent:i,indentStep:a,flowCollectionPadding:o,options:{commentString:s}}=t;r+=a;let c=Object.assign({},t,{indent:r,inFlow:!0,type:null}),l=!1,u=0,d=[];for(let n=0;n<e.length;++n){let i=e[n],a=null;if(Y(i))i.spaceBefore&&d.push(``),er(t,d,i.commentBefore,!1),i.comment&&(a=i.comment);else if(K(i)){let e=Y(i.key)?i.key:null;e&&(e.spaceBefore&&d.push(``),er(t,d,e.commentBefore,!1),e.comment&&(l=!0));let n=Y(i.value)?i.value:null;n?(n.comment&&(a=n.comment),n.commentBefore&&(l=!0)):i.value==null&&e?.comment&&(a=e.comment)}a&&(l=!0);let o=Rn(i,c,()=>a=null);l||=d.length>u||o.includes(`
|
|
45
|
-
`),n<e.length-1?o+=`,`:t.options.trailingComma&&(t.options.lineWidth>0&&(l||=d.reduce((e,t)=>e+t.length+2,2)+(o.length+2)>t.options.lineWidth),l&&(o+=`,`)),a&&(o+=yn(o,r,s(a))),d.push(o),u=d.length}let{start:f,end:p}=n;if(d.length===0)return f+p;if(!l){let e=d.reduce((e,t)=>e+t.length+2,2);l=t.options.lineWidth>0&&e>t.options.lineWidth}if(l){let e=f;for(let t of d)e+=t?`\n${a}${i}${t}`:`
|
|
46
|
-
`;return`${e}\n${i}${p}`}return`${f}${o}${d.join(` `)}${o}${p}`}function er({indent:e,options:{commentString:t}},n,r,i){if(r&&i&&(r=r.replace(/^\n+/,``)),r){let i=vn(t(r),e);n.push(i.trimStart())}}function tr(e,t){let n=q(t)?t.value:t;for(let r of e)if(K(r)&&(r.key===t||r.key===n||q(r.key)&&r.key.value===n))return r}var nr=class extends gn{static get tagName(){return`tag:yaml.org,2002:map`}constructor(e){super(Ft,e),this.items=[]}static from(e,t,n){let{keepUndefined:r,replacer:i}=n,a=new this(e),o=(e,o)=>{if(typeof i==`function`)o=i.call(t,e,o);else if(Array.isArray(i)&&!i.includes(e))return;(o!==void 0||r)&&a.items.push(Yn(e,o,n))};if(t instanceof Map)for(let[e,n]of t)o(e,n);else if(t&&typeof t==`object`)for(let e of Object.keys(t))o(e,t[e]);return typeof e.sortMapEntries==`function`&&a.items.sort(e.sortMapEntries),a}add(e,t){let n;n=K(e)?e:!e||typeof e!=`object`||!(`key`in e)?new Xn(e,e?.value):new Xn(e.key,e.value);let r=tr(this.items,n.key),i=this.schema?.sortMapEntries;if(r){if(!t)throw Error(`Key ${n.key} already set`);q(r.value)&&un(n.value)?r.value.value=n.value:r.value=n.value}else if(i){let e=this.items.findIndex(e=>i(n,e)<0);e===-1?this.items.push(n):this.items.splice(e,0,n)}else this.items.push(n)}delete(e){let t=tr(this.items,e);return t?this.items.splice(this.items.indexOf(t),1).length>0:!1}get(e,t){let n=tr(this.items,e)?.value;return(!t&&q(n)?n.value:n)??void 0}has(e){return!!tr(this.items,e)}set(e,t){this.add(new Xn(e,t),!0)}toJSON(e,t,n){let r=n?new n:t?.mapAsMap?new Map:{};t?.onCreate&&t.onCreate(r);for(let e of this.items)qn(t,r,e);return r}toString(e,t,n){if(!e)return JSON.stringify(this);for(let e of this.items)if(!K(e))throw Error(`Map items must all be pairs; found ${JSON.stringify(e)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),Zn(this,e,{blockItemPrefix:``,flowChars:{start:`{`,end:`}`},itemIndent:e.indent||``,onChompKeep:n,onComment:t})}},rr={collection:`map`,default:!0,nodeClass:nr,tag:`tag:yaml.org,2002:map`,resolve(e,t){return G(e)||t(`Expected a mapping for this tag`),e},createNode:(e,t,n)=>nr.from(e,t,n)},ir=class extends gn{static get tagName(){return`tag:yaml.org,2002:seq`}constructor(e){super(Rt,e),this.items=[]}add(e){this.items.push(e)}delete(e){let t=ar(e);return typeof t==`number`&&this.items.splice(t,1).length>0}get(e,t){let n=ar(e);if(typeof n!=`number`)return;let r=this.items[n];return!t&&q(r)?r.value:r}has(e){let t=ar(e);return typeof t==`number`&&t<this.items.length}set(e,t){let n=ar(e);if(typeof n!=`number`)throw Error(`Expected a valid index, not ${e}.`);let r=this.items[n];q(r)&&un(t)?r.value=t:this.items[n]=t}toJSON(e,t){let n=[];t?.onCreate&&t.onCreate(n);let r=0;for(let e of this.items)n.push(X(e,String(r++),t));return n}toString(e,t,n){return e?Zn(this,e,{blockItemPrefix:`- `,flowChars:{start:`[`,end:`]`},itemIndent:(e.indent||``)+` `,onChompKeep:n,onComment:t}):JSON.stringify(this)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t)){let e=0;for(let a of t){if(typeof r==`function`){let n=t instanceof Set?a:String(e++);a=r.call(t,n,a)}i.items.push(pn(a,void 0,n))}}return i}};function ar(e){let t=q(e)?e.value:e;return t&&typeof t==`string`&&(t=Number(t)),typeof t==`number`&&Number.isInteger(t)&&t>=0?t:null}var or={collection:`seq`,default:!0,nodeClass:ir,tag:`tag:yaml.org,2002:seq`,resolve(e,t){return Ht(e)||t(`Expected a sequence for this tag`),e},createNode:(e,t,n)=>ir.from(e,t,n)},sr={identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify(e,t,n,r){return t=Object.assign({actualString:!0},t),Pn(e,t,n,r)}},cr={identify:e=>e==null,createNode:()=>new Z(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new Z(null),stringify:({source:e},t)=>typeof e==`string`&&cr.test.test(e)?e:t.options.nullStr},lr={identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:e=>new Z(e[0]===`t`||e[0]===`T`),stringify({source:e,value:t},n){return e&&lr.test.test(e)&&t===(e[0]===`t`||e[0]===`T`)?e:t?n.options.trueStr:n.options.falseStr}};function ur({format:e,minFractionDigits:t,tag:n,value:r}){if(typeof r==`bigint`)return String(r);let i=typeof r==`number`?r:Number(r);if(!isFinite(i))return isNaN(i)?`.nan`:i<0?`-.inf`:`.inf`;let a=Object.is(r,-0)?`-0`:JSON.stringify(r);if(!e&&t&&(!n||n===`tag:yaml.org,2002:float`)&&/^-?\d/.test(a)&&!a.includes(`e`)){let e=a.indexOf(`.`);e<0&&(e=a.length,a+=`.`);let n=t-(a.length-e-1);for(;n-->0;)a+=`0`}return a}var dr={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:ur},fr={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():ur(e)}},pr={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){let t=new Z(parseFloat(e)),n=e.indexOf(`.`);return n!==-1&&e[e.length-1]===`0`&&(t.minFractionDigits=e.length-n-1),t},stringify:ur},mr=e=>typeof e==`bigint`||Number.isInteger(e),hr=(e,t,n,{intAsBigInt:r})=>r?BigInt(e):parseInt(e.substring(t),n);function gr(e,t,n){let{value:r}=e;return mr(r)&&r>=0?n+r.toString(t):ur(e)}var _r={identify:e=>mr(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^0o[0-7]+$/,resolve:(e,t,n)=>hr(e,2,8,n),stringify:e=>gr(e,8,`0o`)},vr={identify:mr,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9]+$/,resolve:(e,t,n)=>hr(e,0,10,n),stringify:ur},yr={identify:e=>mr(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,n)=>hr(e,2,16,n),stringify:e=>gr(e,16,`0x`)},br=[rr,or,sr,cr,lr,_r,vr,yr,dr,fr,pr];function xr(e){return typeof e==`bigint`||Number.isInteger(e)}var Sr=({value:e})=>JSON.stringify(e),Cr=[{identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify:Sr},{identify:e=>e==null,createNode:()=>new Z(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^null$/,resolve:()=>null,stringify:Sr},{identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^true$|^false$/,resolve:e=>e===`true`,stringify:Sr},{identify:xr,default:!0,tag:`tag:yaml.org,2002:int`,test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:n})=>n?BigInt(e):parseInt(e,10),stringify:({value:e})=>xr(e)?e.toString():JSON.stringify(e)},{identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:e=>parseFloat(e),stringify:Sr}],wr=[rr,or].concat(Cr,{default:!0,tag:``,test:/^/,resolve(e,t){return t(`Unresolved plain scalar ${JSON.stringify(e)}`),e}}),Tr={identify:e=>e instanceof Uint8Array,default:!1,tag:`tag:yaml.org,2002:binary`,resolve(e,t){if(typeof atob==`function`){let t=atob(e.replace(/[\n\r]/g,``)),n=new Uint8Array(t.length);for(let e=0;e<t.length;++e)n[e]=t.charCodeAt(e);return n}return t(`This environment does not support reading binary tags; either Buffer or atob is required`),e},stringify({comment:e,type:t,value:n},r,i,a){if(!n)return``;let o=n,s;if(typeof btoa==`function`){let e=``;for(let t=0;t<o.length;++t)e+=String.fromCharCode(o[t]);s=btoa(e)}else throw Error(`This environment does not support writing binary tags; either Buffer or btoa is required`);if(t??=Z.BLOCK_LITERAL,t!==Z.QUOTE_DOUBLE){let e=Math.max(r.options.lineWidth-r.indent.length,r.options.minContentWidth),n=Math.ceil(s.length/e),i=Array(n);for(let t=0,r=0;t<n;++t,r+=e)i[t]=s.substr(r,e);s=i.join(t===Z.BLOCK_LITERAL?`
|
|
47
|
-
`:` `)}return Pn({comment:e,type:t,value:s},r,i,a)}};function Er(e,t){if(Ht(e))for(let n=0;n<e.items.length;++n){let r=e.items[n];if(!K(r)){if(G(r)){r.items.length>1&&t(`Each pair must have its own sequence indicator`);let e=r.items[0]||new Xn(new Z(null));if(r.commentBefore&&(e.key.commentBefore=e.key.commentBefore?`${r.commentBefore}\n${e.key.commentBefore}`:r.commentBefore),r.comment){let t=e.value??e.key;t.comment=t.comment?`${r.comment}\n${t.comment}`:r.comment}r=e}e.items[n]=K(r)?r:new Xn(r)}}else t(`Expected a sequence for this tag`);return e}function Dr(e,t,n){let{replacer:r}=n,i=new ir(e);i.tag=`tag:yaml.org,2002:pairs`;let a=0;if(t&&Symbol.iterator in Object(t))for(let e of t){typeof r==`function`&&(e=r.call(t,String(a++),e));let o,s;if(Array.isArray(e)){if(e.length===2)o=e[0],s=e[1];else throw TypeError(`Expected [key, value] tuple: ${e}`)}else if(e&&e instanceof Object){let t=Object.keys(e);if(t.length===1)o=t[0],s=e[o];else throw TypeError(`Expected tuple with one key, not ${t.length} keys`)}else o=e;i.items.push(Yn(o,s,n))}return i}var Or={collection:`seq`,default:!1,tag:`tag:yaml.org,2002:pairs`,resolve:Er,createNode:Dr},kr=class e extends ir{constructor(){super(),this.add=nr.prototype.add.bind(this),this.delete=nr.prototype.delete.bind(this),this.get=nr.prototype.get.bind(this),this.has=nr.prototype.has.bind(this),this.set=nr.prototype.set.bind(this),this.tag=e.tag}toJSON(e,t){if(!t)return super.toJSON(e);let n=new Map;t?.onCreate&&t.onCreate(n);for(let e of this.items){let r,i;if(K(e)?(r=X(e.key,``,t),i=X(e.value,r,t)):r=X(e,``,t),n.has(r))throw Error(`Ordered maps must not include duplicate keys`);n.set(r,i)}return n}static from(e,t,n){let r=Dr(e,t,n),i=new this;return i.items=r.items,i}};kr.tag=`tag:yaml.org,2002:omap`;var Ar={collection:`seq`,identify:e=>e instanceof Map,nodeClass:kr,default:!1,tag:`tag:yaml.org,2002:omap`,resolve(e,t){let n=Er(e,t),r=[];for(let{key:e}of n.items)q(e)&&(r.includes(e.value)?t(`Ordered maps must not include duplicate keys: ${e.value}`):r.push(e.value));return Object.assign(new kr,n)},createNode:(e,t,n)=>kr.from(e,t,n)};function jr({value:e,source:t},n){return t&&(e?Mr:Nr).test.test(t)?t:e?n.options.trueStr:n.options.falseStr}var Mr={identify:e=>e===!0,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new Z(!0),stringify:jr},Nr={identify:e=>e===!1,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new Z(!1),stringify:jr},Pr={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:ur},Fr={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e.replace(/_/g,``)),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():ur(e)}},Ir={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){let t=new Z(parseFloat(e.replace(/_/g,``))),n=e.indexOf(`.`);if(n!==-1){let r=e.substring(n+1).replace(/_/g,``);r[r.length-1]===`0`&&(t.minFractionDigits=r.length)}return t},stringify:ur},Lr=e=>typeof e==`bigint`||Number.isInteger(e);function Rr(e,t,n,{intAsBigInt:r}){let i=e[0];if((i===`-`||i===`+`)&&(t+=1),e=e.substring(t).replace(/_/g,``),r){switch(n){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`}let t=BigInt(e);return i===`-`?BigInt(-1)*t:t}let a=parseInt(e,n);return i===`-`?-1*a:a}function zr(e,t,n){let{value:r}=e;if(Lr(r)){let e=r.toString(t);return r<0?`-`+n+e.substr(1):n+e}return ur(e)}var Br={identify:Lr,default:!0,tag:`tag:yaml.org,2002:int`,format:`BIN`,test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,n)=>Rr(e,2,2,n),stringify:e=>zr(e,2,`0b`)},Vr={identify:Lr,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^[-+]?0[0-7_]+$/,resolve:(e,t,n)=>Rr(e,1,8,n),stringify:e=>zr(e,8,`0`)},Hr={identify:Lr,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,n)=>Rr(e,0,10,n),stringify:ur},Ur={identify:Lr,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,n)=>Rr(e,2,16,n),stringify:e=>zr(e,16,`0x`)},Wr=class e extends nr{constructor(t){super(t),this.tag=e.tag}add(e){let t;t=K(e)?e:e&&typeof e==`object`&&`key`in e&&`value`in e&&e.value===null?new Xn(e.key,null):new Xn(e,null),tr(this.items,t.key)||this.items.push(t)}get(e,t){let n=tr(this.items,e);return!t&&K(n)?q(n.key)?n.key.value:n.key:n}set(e,t){if(typeof t!=`boolean`)throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);let n=tr(this.items,e);n&&!t?this.items.splice(this.items.indexOf(n),1):!n&&t&&this.items.push(new Xn(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);throw Error(`Set items must all have null values`)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t))for(let e of t)typeof r==`function`&&(e=r.call(t,e,e)),i.items.push(Yn(e,null,n));return i}};Wr.tag=`tag:yaml.org,2002:set`;var Gr={collection:`map`,identify:e=>e instanceof Set,nodeClass:Wr,default:!1,tag:`tag:yaml.org,2002:set`,createNode:(e,t,n)=>Wr.from(e,t,n),resolve(e,t){if(G(e)){if(e.hasAllNullValues(!0))return Object.assign(new Wr,e);t(`Set items must all have null values`)}else t(`Expected a mapping for this tag`);return e}};function Kr(e,t){let n=e[0],r=n===`-`||n===`+`?e.substring(1):e,i=e=>t?BigInt(e):Number(e),a=r.replace(/_/g,``).split(`:`).reduce((e,t)=>e*i(60)+i(t),i(0));return n===`-`?i(-1)*a:a}function qr(e){let{value:t}=e,n=e=>e;if(typeof t==`bigint`)n=e=>BigInt(e);else if(isNaN(t)||!isFinite(t))return ur(e);let r=``;t<0&&(r=`-`,t*=n(-1));let i=n(60),a=[t%i];return t<60?a.unshift(0):(t=(t-a[0])/i,a.unshift(t%i),t>=60&&(t=(t-a[0])/i,a.unshift(t))),r+a.map(e=>String(e).padStart(2,`0`)).join(`:`).replace(/000000\d*$/,``)}var Jr={identify:e=>typeof e==`bigint`||Number.isInteger(e),default:!0,tag:`tag:yaml.org,2002:int`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:n})=>Kr(e,n),stringify:qr},Yr={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:e=>Kr(e,!1),stringify:qr},Xr={identify:e=>e instanceof Date,default:!0,tag:`tag:yaml.org,2002:timestamp`,test:RegExp(`^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$`),resolve(e){let t=e.match(Xr.test);if(!t)throw Error(`!!timestamp expects a date, starting with yyyy-mm-dd`);let[,n,r,i,a,o,s]=t.map(Number),c=t[7]?Number((t[7]+`00`).substr(1,3)):0,l=Date.UTC(n,r-1,i,a||0,o||0,s||0,c),u=t[8];if(u&&u!==`Z`){let e=Kr(u,!1);Math.abs(e)<30&&(e*=60),l-=6e4*e}return new Date(l)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,``)??``},Zr=[rr,or,sr,cr,Mr,Nr,Br,Vr,Hr,Ur,Pr,Fr,Ir,Tr,Hn,Ar,Or,Gr,Jr,Yr,Xr],Qr=new Map([[`core`,br],[`failsafe`,[rr,or,sr]],[`json`,wr],[`yaml11`,Zr],[`yaml-1.1`,Zr]]),$r={binary:Tr,bool:lr,float:pr,floatExp:fr,floatNaN:dr,floatTime:Yr,int:vr,intHex:yr,intOct:_r,intTime:Jr,map:rr,merge:Hn,null:cr,omap:Ar,pairs:Or,seq:or,set:Gr,timestamp:Xr},ei={"tag:yaml.org,2002:binary":Tr,"tag:yaml.org,2002:merge":Hn,"tag:yaml.org,2002:omap":Ar,"tag:yaml.org,2002:pairs":Or,"tag:yaml.org,2002:set":Gr,"tag:yaml.org,2002:timestamp":Xr};function ti(e,t,n){let r=Qr.get(t);if(r&&!e)return n&&!r.includes(Hn)?r.concat(Hn):r.slice();let i=r;if(!i){if(Array.isArray(e))i=[];else{let e=Array.from(Qr.keys()).filter(e=>e!==`yaml11`).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown schema "${t}"; use one of ${e} or define customTags array`)}}if(Array.isArray(e))for(let t of e)i=i.concat(t);else typeof e==`function`&&(i=e(i.slice()));return n&&(i=i.concat(Hn)),i.reduce((e,t)=>{let n=typeof t==`string`?$r[t]:t;if(!n){let e=JSON.stringify(t),n=Object.keys($r).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown custom tag ${e}; use one of ${n}`)}return e.includes(n)||e.push(n),e},[])}var ni=(e,t)=>e.key<t.key?-1:+(e.key>t.key),ri=class e{constructor({compat:e,customTags:t,merge:n,resolveKnownTags:r,schema:i,sortMapEntries:a,toStringDefaults:o}){this.compat=Array.isArray(e)?ti(e,`compat`):e?ti(null,e):null,this.name=typeof i==`string`&&i||`core`,this.knownTags=r?ei:{},this.tags=ti(t,this.name,n),this.toStringOptions=o??null,Object.defineProperty(this,Ft,{value:rr}),Object.defineProperty(this,Lt,{value:sr}),Object.defineProperty(this,Rt,{value:or}),this.sortMapEntries=typeof a==`function`?a:a===!0?ni:null}clone(){let t=Object.create(e.prototype,Object.getOwnPropertyDescriptors(this));return t.tags=this.tags.slice(),t}};function ii(e,t){let n=[],r=t.directives===!0;if(t.directives!==!1&&e.directives){let t=e.directives.toString(e);t?(n.push(t),r=!0):e.directives.docStart&&(r=!0)}r&&n.push(`---`);let i=Fn(e,t),{commentString:a}=i.options;if(e.commentBefore){n.length!==1&&n.unshift(``);let t=a(e.commentBefore);n.unshift(vn(t,``))}let o=!1,s=null;if(e.contents){if(Y(e.contents)){if(e.contents.spaceBefore&&r&&n.push(``),e.contents.commentBefore){let t=a(e.contents.commentBefore);n.push(vn(t,``))}i.forceBlockIndent=!!e.comment,s=e.contents.comment}let t=s?void 0:()=>o=!0,c=Rn(e.contents,i,()=>s=null,t);s&&(c+=yn(c,``,a(s))),(c[0]===`|`||c[0]===`>`)&&n[n.length-1]===`---`?n[n.length-1]=`--- ${c}`:n.push(c)}else n.push(Rn(e.contents,i));if(e.directives?.docEnd){if(e.comment){let t=a(e.comment);t.includes(`
|
|
48
|
-
`)?(n.push(`...`),n.push(vn(t,``))):n.push(`... ${t}`)}else n.push(`...`)}else{let t=e.comment;t&&o&&(t=t.replace(/^\n+/,``)),t&&((!o||s)&&n[n.length-1]!==``&&n.push(``),n.push(vn(a(t),``)))}return n.join(`
|
|
49
|
-
`)+`
|
|
50
|
-
`}var ai=class e{constructor(e,t,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,zt,{value:Pt});let r=null;typeof t==`function`||Array.isArray(t)?r=t:n===void 0&&t&&(n=t,t=void 0);let i=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:`warn`,prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:`1.2`},n);this.options=i;let{version:a}=i;n?._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(a=this.directives.yaml.version)):this.directives=new en({version:a}),this.setSchema(a,n),this.contents=e===void 0?null:this.createNode(e,r,n)}clone(){let t=Object.create(e.prototype,{[zt]:{value:Pt}});return t.commentBefore=this.commentBefore,t.comment=this.comment,t.errors=this.errors.slice(),t.warnings=this.warnings.slice(),t.options=Object.assign({},this.options),this.directives&&(t.directives=this.directives.clone()),t.schema=this.schema.clone(),t.contents=Y(this.contents)?this.contents.clone(t.schema):this.contents,this.range&&(t.range=this.range.slice()),t}add(e){oi(this.contents)&&this.contents.add(e)}addIn(e,t){oi(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){let n=nn(this);e.anchor=!t||n.has(t)?rn(t||`a`,n):t}return new cn(e.anchor)}createNode(e,t,n){let r;if(typeof t==`function`)e=t.call({"":e},``,e),r=t;else if(Array.isArray(t)){let e=t.filter(e=>typeof e==`number`||e instanceof String||e instanceof Number).map(String);e.length>0&&(t=t.concat(e)),r=t}else n===void 0&&t&&(n=t,t=void 0);let{aliasDuplicateObjects:i,anchorPrefix:a,flow:o,keepUndefined:s,onTagObj:c,tag:l}=n??{},{onAnchor:u,setAnchors:d,sourceObjects:f}=an(this,a||`a`),p={aliasDuplicateObjects:i??!0,keepUndefined:s??!1,onAnchor:u,onTagObj:c,replacer:r,schema:this.schema,sourceObjects:f},m=pn(e,l,p);return o&&J(m)&&(m.flow=!0),d(),m}createPair(e,t,n={}){return new Xn(this.createNode(e,null,n),this.createNode(t,null,n))}delete(e){return oi(this.contents)?this.contents.delete(e):!1}deleteIn(e){return hn(e)?this.contents!=null&&(this.contents=null,!0):oi(this.contents)?this.contents.deleteIn(e):!1}get(e,t){return J(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return hn(e)?!t&&q(this.contents)?this.contents.value:this.contents:J(this.contents)?this.contents.getIn(e,t):void 0}has(e){return J(this.contents)?this.contents.has(e):!1}hasIn(e){return hn(e)?this.contents!==void 0:J(this.contents)?this.contents.hasIn(e):!1}set(e,t){this.contents==null?this.contents=mn(this.schema,[e],t):oi(this.contents)&&this.contents.set(e,t)}setIn(e,t){hn(e)?this.contents=t:this.contents==null?this.contents=mn(this.schema,Array.from(e),t):oi(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){typeof e==`number`&&(e=String(e));let n;switch(e){case`1.1`:this.directives?this.directives.yaml.version=`1.1`:this.directives=new en({version:`1.1`}),n={resolveKnownTags:!1,schema:`yaml-1.1`};break;case`1.2`:case`next`:this.directives?this.directives.yaml.version=e:this.directives=new en({version:e}),n={resolveKnownTags:!0,schema:`core`};break;case null:this.directives&&delete this.directives,n=null;break;default:{let t=JSON.stringify(e);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${t}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new ri(Object.assign(n,t));else throw Error(`With a null YAML version, the { schema: Schema } option is required`)}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:r,onAnchor:i,reviver:a}={}){let o={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof r==`number`?r:100},s=X(this.contents,t??``,o);if(typeof i==`function`)for(let{count:e,res:t}of o.anchors.values())i(t,e);return typeof a==`function`?on(a,{"":s},``,s):s}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw Error(`Document with errors cannot be stringified`);if(`indent`in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let t=JSON.stringify(e.indent);throw Error(`"indent" option must be a positive integer, not ${t}`)}return ii(this,e)}};function oi(e){if(J(e))return!0;throw Error(`Expected a YAML collection as document contents`)}var si=class extends Error{constructor(e,t,n,r){super(),this.name=e,this.code=n,this.message=r,this.pos=t}},ci=class extends si{constructor(e,t,n){super(`YAMLParseError`,e,t,n)}},li=class extends si{constructor(e,t,n){super(`YAMLWarning`,e,t,n)}},ui=(e,t)=>n=>{if(n.pos[0]===-1)return;n.linePos=n.pos.map(e=>t.linePos(e));let{line:r,col:i}=n.linePos[0];n.message+=` at line ${r}, column ${i}`;let a=i-1,o=e.substring(t.lineStarts[r-1],t.lineStarts[r]).replace(/[\n\r]+$/,``);if(a>=60&&o.length>80){let e=Math.min(a-39,o.length-79);o=`…`+o.substring(e),a-=e-1}if(o.length>80&&(o=o.substring(0,79)+`…`),r>1&&/^ *$/.test(o.substring(0,a))){let n=e.substring(t.lineStarts[r-2],t.lineStarts[r-1]);n.length>80&&(n=n.substring(0,79)+`…
|
|
51
|
-
`),o=n+o}if(/[^ ]/.test(o)){let e=1,t=n.linePos[1];t?.line===r&&t.col>i&&(e=Math.max(1,Math.min(t.col-i,80-a)));let s=` `.repeat(a)+`^`.repeat(e);n.message+=`:\n\n${o}\n${s}\n`}};function di(e,{flow:t,indicator:n,next:r,offset:i,onError:a,parentIndent:o,startOnNewline:s}){let c=!1,l=s,u=s,d=``,f=``,p=!1,m=!1,h=null,g=null,_=null,v=null,y=null,b=null,x=null;for(let i of e)switch(m&&=(i.type!==`space`&&i.type!==`newline`&&i.type!==`comma`&&a(i.offset,`MISSING_CHAR`,`Tags and anchors must be separated from the next token by white space`),!1),h&&=(l&&i.type!==`comment`&&i.type!==`newline`&&a(h,`TAB_AS_INDENT`,`Tabs are not allowed as indentation`),null),i.type){case`space`:!t&&(n!==`doc-start`||r?.type!==`flow-collection`)&&i.source.includes(` `)&&(h=i),u=!0;break;case`comment`:{u||a(i,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`);let e=i.source.substring(1)||` `;d?d+=f+e:d=e,f=``,l=!1;break}case`newline`:l?d?d+=i.source:b&&n===`seq-item-ind`||(c=!0):f+=i.source,l=!0,p=!0,(g||_)&&(v=i),u=!0;break;case`anchor`:g&&a(i,`MULTIPLE_ANCHORS`,`A node can have at most one anchor`),i.source.endsWith(`:`)&&a(i.offset+i.source.length-1,`BAD_ALIAS`,`Anchor ending in : is ambiguous`,!0),g=i,x??=i.offset,l=!1,u=!1,m=!0;break;case`tag`:_&&a(i,`MULTIPLE_TAGS`,`A node can have at most one tag`),_=i,x??=i.offset,l=!1,u=!1,m=!0;break;case n:(g||_)&&a(i,`BAD_PROP_ORDER`,`Anchors and tags must be after the ${i.source} indicator`),b&&a(i,`UNEXPECTED_TOKEN`,`Unexpected ${i.source} in ${t??`collection`}`),b=i,l=n===`seq-item-ind`||n===`explicit-key-ind`,u=!1;break;case`comma`:if(t){y&&a(i,`UNEXPECTED_TOKEN`,`Unexpected , in ${t}`),y=i,l=!1,u=!1;break}default:a(i,`UNEXPECTED_TOKEN`,`Unexpected ${i.type} token`),l=!1,u=!1}let S=e[e.length-1],C=S?S.offset+S.source.length:i;return m&&r&&r.type!==`space`&&r.type!==`newline`&&r.type!==`comma`&&(r.type!==`scalar`||r.source!==``)&&a(r.offset,`MISSING_CHAR`,`Tags and anchors must be separated from the next token by white space`),h&&(l&&h.indent<=o||r?.type===`block-map`||r?.type===`block-seq`)&&a(h,`TAB_AS_INDENT`,`Tabs are not allowed as indentation`),{comma:y,found:b,spaceBefore:c,comment:d,hasNewline:p,anchor:g,tag:_,newlineAfterProp:v,end:C,start:x??C}}function fi(e){if(!e)return null;switch(e.type){case`alias`:case`scalar`:case`double-quoted-scalar`:case`single-quoted-scalar`:if(e.source.includes(`
|
|
52
|
-
`))return!0;if(e.end){for(let t of e.end)if(t.type===`newline`)return!0}return!1;case`flow-collection`:for(let t of e.items){for(let e of t.start)if(e.type===`newline`)return!0;if(t.sep){for(let e of t.sep)if(e.type===`newline`)return!0}if(fi(t.key)||fi(t.value))return!0}return!1;default:return!0}}function pi(e,t,n){if(t?.type===`flow-collection`){let r=t.end[0];r.indent===e&&(r.source===`]`||r.source===`}`)&&fi(t)&&n(r,`BAD_INDENT`,`Flow end indicator should be more indented than parent`,!0)}}function mi(e,t,n){let{uniqueKeys:r}=e.options;if(r===!1)return!1;let i=typeof r==`function`?r:(e,t)=>e===t||q(e)&&q(t)&&e.value===t.value;return t.some(e=>i(e.key,n))}var hi=`All mapping items must start at the same column`;function gi({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=new((a?.nodeClass)??nr)(n.schema);n.atRoot&&=!1;let s=r.offset,c=null;for(let a of r.items){let{start:l,key:u,sep:d,value:f}=a,p=di(l,{indicator:`explicit-key-ind`,next:u??d?.[0],offset:s,onError:i,parentIndent:r.indent,startOnNewline:!0}),m=!p.found;if(m){if(u&&(u.type===`block-seq`?i(s,`BLOCK_AS_IMPLICIT_KEY`,`A block sequence may not be used as an implicit map key`):`indent`in u&&u.indent!==r.indent&&i(s,`BAD_INDENT`,hi)),!p.anchor&&!p.tag&&!d){c=p.end,p.comment&&(o.comment?o.comment+=`
|
|
53
|
-
`+p.comment:o.comment=p.comment);continue}(p.newlineAfterProp||fi(u))&&i(u??l[l.length-1],`MULTILINE_IMPLICIT_KEY`,`Implicit keys need to be on a single line`)}else p.found?.indent!==r.indent&&i(s,`BAD_INDENT`,hi);n.atKey=!0;let h=p.end,g=u?e(n,u,p,i):t(n,h,l,null,p,i);n.schema.compat&&pi(r.indent,u,i),n.atKey=!1,mi(n,o.items,g)&&i(h,`DUPLICATE_KEY`,`Map keys must be unique`);let _=di(d??[],{indicator:`map-value-ind`,next:f,offset:g.range[2],onError:i,parentIndent:r.indent,startOnNewline:!u||u.type===`block-scalar`});if(s=_.end,_.found){m&&(f?.type===`block-map`&&!_.hasNewline&&i(s,`BLOCK_AS_IMPLICIT_KEY`,`Nested mappings are not allowed in compact mappings`),n.options.strict&&p.start<_.found.offset-1024&&i(g.range,`KEY_OVER_1024_CHARS`,`The : indicator must be at most 1024 chars after the start of an implicit block mapping key`));let c=f?e(n,f,_,i):t(n,s,d,null,_,i);n.schema.compat&&pi(r.indent,f,i),s=c.range[2];let l=new Xn(g,c);n.options.keepSourceTokens&&(l.srcToken=a),o.items.push(l)}else{m&&i(g.range,`MISSING_CHAR`,`Implicit map keys need to be followed by map values`),_.comment&&(g.comment?g.comment+=`
|
|
54
|
-
`+_.comment:g.comment=_.comment);let e=new Xn(g);n.options.keepSourceTokens&&(e.srcToken=a),o.items.push(e)}}return c&&c<s&&i(c,`IMPOSSIBLE`,`Map comment with trailing content`),o.range=[r.offset,s,c??s],o}function _i({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=new((a?.nodeClass)??ir)(n.schema);n.atRoot&&=!1,n.atKey&&=!1;let s=r.offset,c=null;for(let{start:a,value:l}of r.items){let u=di(a,{indicator:`seq-item-ind`,next:l,offset:s,onError:i,parentIndent:r.indent,startOnNewline:!0});if(!u.found){if(u.anchor||u.tag||l)l?.type===`block-seq`?i(u.end,`BAD_INDENT`,`All sequence items must start at the same column`):i(s,`MISSING_CHAR`,`Sequence item without - indicator`);else{c=u.end,u.comment&&(o.comment=u.comment);continue}}let d=l?e(n,l,u,i):t(n,u.end,a,null,u,i);n.schema.compat&&pi(r.indent,l,i),s=d.range[2],o.items.push(d)}return o.range=[r.offset,s,c??s],o}function vi(e,t,n,r){let i=``;if(e){let a=!1,o=``;for(let s of e){let{source:e,type:c}=s;switch(c){case`space`:a=!0;break;case`comment`:{n&&!a&&r(s,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`);let t=e.substring(1)||` `;i?i+=o+t:i=t,o=``;break}case`newline`:i&&(o+=e),a=!0;break;default:r(s,`UNEXPECTED_TOKEN`,`Unexpected ${c} at node end`)}t+=e.length}}return{comment:i,offset:t}}var yi=`Block collections are not allowed within flow collections`,bi=e=>e&&(e.type===`block-map`||e.type===`block-seq`);function xi({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=r.start.source===`{`,s=o?`flow map`:`flow sequence`,c=new((a?.nodeClass)??(o?nr:ir))(n.schema);c.flow=!0;let l=n.atRoot;l&&(n.atRoot=!1),n.atKey&&=!1;let u=r.offset+r.start.source.length;for(let a=0;a<r.items.length;++a){let l=r.items[a],{start:d,key:f,sep:p,value:m}=l,h=di(d,{flow:s,indicator:`explicit-key-ind`,next:f??p?.[0],offset:u,onError:i,parentIndent:r.indent,startOnNewline:!1});if(!h.found){if(!h.anchor&&!h.tag&&!p&&!m){a===0&&h.comma?i(h.comma,`UNEXPECTED_TOKEN`,`Unexpected , in ${s}`):a<r.items.length-1&&i(h.start,`UNEXPECTED_TOKEN`,`Unexpected empty item in ${s}`),h.comment&&(c.comment?c.comment+=`
|
|
55
|
-
`+h.comment:c.comment=h.comment),u=h.end;continue}!o&&n.options.strict&&fi(f)&&i(f,`MULTILINE_IMPLICIT_KEY`,`Implicit keys of flow sequence pairs need to be on a single line`)}if(a===0)h.comma&&i(h.comma,`UNEXPECTED_TOKEN`,`Unexpected , in ${s}`);else if(h.comma||i(h.start,`MISSING_CHAR`,`Missing , between ${s} items`),h.comment){let e=``;loop:for(let t of d)switch(t.type){case`comma`:case`space`:break;case`comment`:e=t.source.substring(1);break loop;default:break loop}if(e){let t=c.items[c.items.length-1];K(t)&&(t=t.value??t.key),t.comment?t.comment+=`
|
|
56
|
-
`+e:t.comment=e,h.comment=h.comment.substring(e.length+1)}}if(!o&&!p&&!h.found){let r=m?e(n,m,h,i):t(n,h.end,p,null,h,i);c.items.push(r),u=r.range[2],bi(m)&&i(r.range,`BLOCK_IN_FLOW`,yi)}else{n.atKey=!0;let a=h.end,g=f?e(n,f,h,i):t(n,a,d,null,h,i);bi(f)&&i(g.range,`BLOCK_IN_FLOW`,yi),n.atKey=!1;let _=di(p??[],{flow:s,indicator:`map-value-ind`,next:m,offset:g.range[2],onError:i,parentIndent:r.indent,startOnNewline:!1});if(_.found){if(!o&&!h.found&&n.options.strict){if(p)for(let e of p){if(e===_.found)break;if(e.type===`newline`){i(e,`MULTILINE_IMPLICIT_KEY`,`Implicit keys of flow sequence pairs need to be on a single line`);break}}h.start<_.found.offset-1024&&i(_.found,`KEY_OVER_1024_CHARS`,`The : indicator must be at most 1024 chars after the start of an implicit flow sequence key`)}}else m&&(`source`in m&&m.source?.[0]===`:`?i(m,`MISSING_CHAR`,`Missing space after : in ${s}`):i(_.start,`MISSING_CHAR`,`Missing , or : between ${s} items`));let v=m?e(n,m,_,i):_.found?t(n,_.end,p,null,_,i):null;v?bi(m)&&i(v.range,`BLOCK_IN_FLOW`,yi):_.comment&&(g.comment?g.comment+=`
|
|
57
|
-
`+_.comment:g.comment=_.comment);let y=new Xn(g,v);if(n.options.keepSourceTokens&&(y.srcToken=l),o){let e=c;mi(n,e.items,g)&&i(a,`DUPLICATE_KEY`,`Map keys must be unique`),e.items.push(y)}else{let e=new nr(n.schema);e.flow=!0,e.items.push(y);let t=(v??g).range;e.range=[g.range[0],t[1],t[2]],c.items.push(e)}u=v?v.range[2]:_.end}}let d=o?`}`:`]`,[f,...p]=r.end,m=u;if(f?.source===d)m=f.offset+f.source.length;else{let e=s[0].toUpperCase()+s.substring(1),t=l?`${e} must end with a ${d}`:`${e} in block collection must be sufficiently indented and end with a ${d}`;i(u,l?`MISSING_CHAR`:`BAD_INDENT`,t),f&&f.source.length!==1&&p.unshift(f)}if(p.length>0){let e=vi(p,m,n.options.strict,i);e.comment&&(c.comment?c.comment+=`
|
|
58
|
-
`+e.comment:c.comment=e.comment),c.range=[r.offset,m,e.offset]}else c.range=[r.offset,m,m];return c}function Si(e,t,n,r,i,a){let o=n.type===`block-map`?gi(e,t,n,r,a):n.type===`block-seq`?_i(e,t,n,r,a):xi(e,t,n,r,a),s=o.constructor;return i===`!`||i===s.tagName?(o.tag=s.tagName,o):(i&&(o.tag=i),o)}function Ci(e,t,n,r,i){let a=r.tag,o=a?t.directives.tagName(a.source,e=>i(a,`TAG_RESOLVE_FAILED`,e)):null;if(n.type===`block-seq`){let{anchor:e,newlineAfterProp:t}=r,n=e&&a?e.offset>a.offset?e:a:e??a;n&&(!t||t.offset<n.offset)&&i(n,`MISSING_CHAR`,`Missing newline after block sequence props`)}let s=n.type===`block-map`?`map`:n.type===`block-seq`?`seq`:n.start.source===`{`?`map`:`seq`;if(!a||!o||o===`!`||o===nr.tagName&&s===`map`||o===ir.tagName&&s===`seq`)return Si(e,t,n,i,o);let c=t.schema.tags.find(e=>e.tag===o&&e.collection===s);if(!c){let r=t.schema.knownTags[o];if(r?.collection===s)t.schema.tags.push(Object.assign({},r,{default:!1})),c=r;else return r?i(a,`BAD_COLLECTION_TYPE`,`${r.tag} used for ${s} collection, but expects ${r.collection??`scalar`}`,!0):i(a,`TAG_RESOLVE_FAILED`,`Unresolved tag: ${o}`,!0),Si(e,t,n,i,o)}let l=Si(e,t,n,i,o,c),u=c.resolve?.(l,e=>i(a,`TAG_RESOLVE_FAILED`,e),t.options)??l,d=Y(u)?u:new Z(u);return d.range=l.range,d.tag=o,c?.format&&(d.format=c.format),d}function wi(e,t,n){let r=t.offset,i=Ti(t,e.options.strict,n);if(!i)return{value:``,type:null,comment:``,range:[r,r,r]};let a=i.mode===`>`?Z.BLOCK_FOLDED:Z.BLOCK_LITERAL,o=t.source?Ei(t.source):[],s=o.length;for(let e=o.length-1;e>=0;--e){let t=o[e][1];if(t===``||t===`\r`)s=e;else break}if(s===0){let e=i.chomp===`+`&&o.length>0?`
|
|
59
|
-
`.repeat(Math.max(1,o.length-1)):``,n=r+i.length;return t.source&&(n+=t.source.length),{value:e,type:a,comment:i.comment,range:[r,n,n]}}let c=t.indent+i.indent,l=t.offset+i.length,u=0;for(let t=0;t<s;++t){let[r,a]=o[t];if(a===``||a===`\r`)i.indent===0&&r.length>c&&(c=r.length);else{r.length<c&&n(l+r.length,`MISSING_CHAR`,`Block scalars with more-indented leading empty lines must use an explicit indentation indicator`),i.indent===0&&(c=r.length),u=t,c===0&&!e.atRoot&&n(l,`BAD_INDENT`,`Block scalar values in collections must be indented`);break}l+=r.length+a.length+1}for(let e=o.length-1;e>=s;--e)o[e][0].length>c&&(s=e+1);let d=``,f=``,p=!1;for(let e=0;e<u;++e)d+=o[e][0].slice(c)+`
|
|
60
|
-
`;for(let e=u;e<s;++e){let[t,r]=o[e];l+=t.length+r.length+1;let s=r[r.length-1]===`\r`;if(s&&(r=r.slice(0,-1)),r&&t.length<c){let e=`Block scalar lines must not be less indented than their ${i.indent?`explicit indentation indicator`:`first line`}`;n(l-r.length-(s?2:1),`BAD_INDENT`,e),t=``}a===Z.BLOCK_LITERAL?(d+=f+t.slice(c)+r,f=`
|
|
61
|
-
`):t.length>c||r[0]===` `?(f===` `?f=`
|
|
62
|
-
`:!p&&f===`
|
|
63
|
-
`&&(f=`
|
|
64
|
-
|
|
65
|
-
`),d+=f+t.slice(c)+r,f=`
|
|
66
|
-
`,p=!0):r===``?f===`
|
|
67
|
-
`?d+=`
|
|
68
|
-
`:f=`
|
|
69
|
-
`:(d+=f+r,f=` `,p=!1)}switch(i.chomp){case`-`:break;case`+`:for(let e=s;e<o.length;++e)d+=`
|
|
70
|
-
`+o[e][0].slice(c);d[d.length-1]!==`
|
|
71
|
-
`&&(d+=`
|
|
72
|
-
`);break;default:d+=`
|
|
73
|
-
`}let m=r+i.length+t.source.length;return{value:d,type:a,comment:i.comment,range:[r,m,m]}}function Ti({offset:e,props:t},n,r){if(t[0].type!==`block-scalar-header`)return r(t[0],`IMPOSSIBLE`,`Block scalar header not found`),null;let{source:i}=t[0],a=i[0],o=0,s=``,c=-1;for(let t=1;t<i.length;++t){let n=i[t];if(!s&&(n===`-`||n===`+`))s=n;else{let r=Number(n);!o&&r?o=r:c===-1&&(c=e+t)}}c!==-1&&r(c,`UNEXPECTED_TOKEN`,`Block scalar header includes extra characters: ${i}`);let l=!1,u=``,d=i.length;for(let e=1;e<t.length;++e){let i=t[e];switch(i.type){case`space`:l=!0;case`newline`:d+=i.source.length;break;case`comment`:n&&!l&&r(i,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`),d+=i.source.length,u=i.source.substring(1);break;case`error`:r(i,`UNEXPECTED_TOKEN`,i.message),d+=i.source.length;break;default:{r(i,`UNEXPECTED_TOKEN`,`Unexpected token in block scalar header: ${i.type}`);let e=i.source;e&&typeof e==`string`&&(d+=e.length)}}}return{mode:a,indent:o,chomp:s,comment:u,length:d}}function Ei(e){let t=e.split(/\n( *)/),n=t[0],r=n.match(/^( *)/),i=[r?.[1]?[r[1],n.slice(r[1].length)]:[``,n]];for(let e=1;e<t.length;e+=2)i.push([t[e],t[e+1]]);return i}function Di(e,t,n){let{offset:r,type:i,source:a,end:o}=e,s,c,l=(e,t,i)=>n(r+e,t,i);switch(i){case`scalar`:s=Z.PLAIN,c=Oi(a,l);break;case`single-quoted-scalar`:s=Z.QUOTE_SINGLE,c=ki(a,l);break;case`double-quoted-scalar`:s=Z.QUOTE_DOUBLE,c=ji(a,l);break;default:return n(e,`UNEXPECTED_TOKEN`,`Expected a flow scalar value, but found: ${i}`),{value:``,type:null,comment:``,range:[r,r+a.length,r+a.length]}}let u=r+a.length,d=vi(o,u,t,n);return{value:c,type:s,comment:d.comment,range:[r,u,d.offset]}}function Oi(e,t){let n=``;switch(e[0]){case` `:n=`a tab character`;break;case`,`:n=`flow indicator character ,`;break;case`%`:n=`directive indicator character %`;break;case`|`:case`>`:n=`block scalar indicator ${e[0]}`;break;case`@`:case"`":n=`reserved character ${e[0]}`}return n&&t(0,`BAD_SCALAR_START`,`Plain value cannot start with ${n}`),Ai(e)}function ki(e,t){return(e[e.length-1]!==`'`||e.length===1)&&t(e.length,`MISSING_CHAR`,`Missing closing 'quote`),Ai(e.slice(1,-1)).replace(/''/g,`'`)}function Ai(e){let t=/(.*?)\r?\n/sy,n=t.exec(e);if(!n)return e;let r,i;try{r=RegExp(`(?<![ ])[ ]+$`),i=RegExp(`^[ ]+|(?<![ ])[ ]+$`,`g`)}catch{r=/[ \t]+$/,i=/^[ \t]+|[ \t]+$/g}let a=n[1].replace(r,``),o=` `,s=t.lastIndex;for(;n=t.exec(e);){let e=n[1].replace(i,``);e===``?o===`
|
|
74
|
-
`?a+=o:o=`
|
|
75
|
-
`:(a+=o+e,o=` `),s=t.lastIndex}let c=/[ \t]*(.*)/sy;return c.lastIndex=s,n=c.exec(e),a+o+(n?.[1]??``)}function ji(e,t){let n=``;for(let r=1;r<e.length-1;++r){let i=e[r];if(i!==`\r`||e[r+1]!==`
|
|
76
|
-
`){if(i===`
|
|
77
|
-
`){let{fold:t,offset:i}=Mi(e,r);n+=t,r=i}else if(i===`\\`){let i=e[++r],a=Ni[i];if(a)n+=a;else if(i===`
|
|
78
|
-
`)for(i=e[r+1];i===` `||i===` `;)i=e[++r+1];else if(i===`\r`&&e[r+1]===`
|
|
79
|
-
`)for(i=e[++r+1];i===` `||i===` `;)i=e[++r+1];else if(i===`x`||i===`u`||i===`U`){let a=i===`x`?2:i===`u`?4:8;n+=Pi(e,r+1,a,t),r+=a}else{let i=e.substr(r-1,2);t(r-1,`BAD_DQ_ESCAPE`,`Invalid escape sequence ${i}`),n+=i}}else if(i===` `||i===` `){let t=r,a=e[r+1];for(;a===` `||a===` `;)a=e[++r+1];a!==`
|
|
80
|
-
`&&(a!==`\r`||e[r+2]!==`
|
|
81
|
-
`)&&(n+=r>t?e.slice(t,r+1):i)}else n+=i}}return(e[e.length-1]!==`"`||e.length===1)&&t(e.length,`MISSING_CHAR`,`Missing closing "quote`),n}function Mi(e,t){let n=``,r=e[t+1];for(;(r===` `||r===` `||r===`
|
|
82
|
-
`||r===`\r`)&&(r!==`\r`||e[t+2]===`
|
|
83
|
-
`);)r===`
|
|
84
|
-
`&&(n+=`
|
|
85
|
-
`),t+=1,r=e[t+1];return n||=` `,{fold:n,offset:t}}var Ni={0:`\0`,a:`\x07`,b:`\b`,e:`\x1B`,f:`\f`,n:`
|
|
86
|
-
`,r:`\r`,t:` `,v:`\v`,N:`
`,_:`\xA0`,L:`\u2028`,P:`\u2029`," ":` `,'"':`"`,"/":`/`,"\\":`\\`," ":` `};function Pi(e,t,n,r){let i=e.substr(t,n),a=i.length===n&&/^[0-9a-fA-F]+$/.test(i)?parseInt(i,16):NaN;try{return String.fromCodePoint(a)}catch{let i=e.substr(t-2,n+2);return r(t-2,`BAD_DQ_ESCAPE`,`Invalid escape sequence ${i}`),i}}function Fi(e,t,n,r){let{value:i,type:a,comment:o,range:s}=t.type===`block-scalar`?wi(e,t,r):Di(t,e.options.strict,r),c=n?e.directives.tagName(n.source,e=>r(n,`TAG_RESOLVE_FAILED`,e)):null,l;l=e.options.stringKeys&&e.atKey?e.schema[Lt]:c?Ii(e.schema,i,c,n,r):t.type===`scalar`?Li(e,i,t,r):e.schema[Lt];let u;try{let a=l.resolve(i,e=>r(n??t,`TAG_RESOLVE_FAILED`,e),e.options);u=q(a)?a:new Z(a)}catch(e){let a=e instanceof Error?e.message:String(e);r(n??t,`TAG_RESOLVE_FAILED`,a),u=new Z(i)}return u.range=s,u.source=i,a&&(u.type=a),c&&(u.tag=c),l.format&&(u.format=l.format),o&&(u.comment=o),u}function Ii(e,t,n,r,i){if(n===`!`)return e[Lt];let a=[];for(let t of e.tags)if(!t.collection&&t.tag===n){if(t.default&&t.test)a.push(t);else return t}for(let e of a)if(e.test?.test(t))return e;let o=e.knownTags[n];return o&&!o.collection?(e.tags.push(Object.assign({},o,{default:!1,test:void 0})),o):(i(r,`TAG_RESOLVE_FAILED`,`Unresolved tag: ${n}`,n!==`tag:yaml.org,2002:str`),e[Lt])}function Li({atKey:e,directives:t,schema:n},r,i,a){let o=n.tags.find(t=>(t.default===!0||e&&t.default===`key`)&&t.test?.test(r))||n[Lt];if(n.compat){let e=n.compat.find(e=>e.default&&e.test?.test(r))??n[Lt];o.tag!==e.tag&&a(i,`TAG_RESOLVE_FAILED`,`Value may be parsed as either ${t.tagString(o.tag)} or ${t.tagString(e.tag)}`,!0)}return o}function Ri(e,t,n){if(t){n??=t.length;for(let r=n-1;r>=0;--r){let n=t[r];switch(n.type){case`space`:case`comment`:case`newline`:e-=n.source.length;continue}for(n=t[++r];n?.type===`space`;)e+=n.source.length,n=t[++r];break}}return e}var zi={composeNode:Bi,composeEmptyNode:Vi};function Bi(e,t,n,r){let i=e.atKey,{spaceBefore:a,comment:o,anchor:s,tag:c}=n,l,u=!0;switch(t.type){case`alias`:l=Hi(e,t,r),(s||c)&&r(t,`ALIAS_PROPS`,`An alias node must not specify any properties`);break;case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:case`block-scalar`:l=Fi(e,t,c,r),s&&(l.anchor=s.source.substring(1));break;case`block-map`:case`block-seq`:case`flow-collection`:try{l=Ci(zi,e,t,n,r),s&&(l.anchor=s.source.substring(1))}catch(e){r(t,`RESOURCE_EXHAUSTION`,e instanceof Error?e.message:String(e))}break;default:r(t,`UNEXPECTED_TOKEN`,t.type===`error`?t.message:`Unsupported token (type: ${t.type})`),u=!1}return l??=Vi(e,t.offset,void 0,null,n,r),s&&l.anchor===``&&r(s,`BAD_ALIAS`,`Anchor cannot be an empty string`),i&&e.options.stringKeys&&(!q(l)||typeof l.value!=`string`||l.tag&&l.tag!==`tag:yaml.org,2002:str`)&&r(c??t,`NON_STRING_KEY`,`With stringKeys, all keys must be strings`),a&&(l.spaceBefore=!0),o&&(t.type===`scalar`&&t.source===``?l.comment=o:l.commentBefore=o),e.options.keepSourceTokens&&u&&(l.srcToken=t),l}function Vi(e,t,n,r,{spaceBefore:i,comment:a,anchor:o,tag:s,end:c},l){let u=Fi(e,{type:`scalar`,offset:Ri(t,n,r),indent:-1,source:``},s,l);return o&&(u.anchor=o.source.substring(1),u.anchor===``&&l(o,`BAD_ALIAS`,`Anchor cannot be an empty string`)),i&&(u.spaceBefore=!0),a&&(u.comment=a,u.range[2]=c),u}function Hi({options:e},{offset:t,source:n,end:r},i){let a=new cn(n.substring(1));a.source===``&&i(t,`BAD_ALIAS`,`Alias cannot be an empty string`),a.source.endsWith(`:`)&&i(t+n.length-1,`BAD_ALIAS`,`Alias ending in : is ambiguous`,!0);let o=t+n.length,s=vi(r,o,e.strict,i);return a.range=[t,o,s.offset],s.comment&&(a.comment=s.comment),a}function Ui(e,t,{offset:n,start:r,value:i,end:a},o){let s=new ai(void 0,Object.assign({_directives:t},e)),c={atKey:!1,atRoot:!0,directives:s.directives,options:s.options,schema:s.schema},l=di(r,{indicator:`doc-start`,next:i??a?.[0],offset:n,onError:o,parentIndent:0,startOnNewline:!0});l.found&&(s.directives.docStart=!0,i&&(i.type===`block-map`||i.type===`block-seq`)&&!l.hasNewline&&o(l.end,`MISSING_CHAR`,`Block collection cannot start on same line with directives-end marker`)),s.contents=i?Bi(c,i,l,o):Vi(c,l.end,r,null,l,o);let u=s.contents.range[2],d=vi(a,u,!1,o);return d.comment&&(s.comment=d.comment),s.range=[n,u,d.offset],s}function Wi(e){if(typeof e==`number`)return[e,e+1];if(Array.isArray(e))return e.length===2?e:[e[0],e[1]];let{offset:t,source:n}=e;return[t,t+(typeof n==`string`?n.length:1)]}function Gi(e){let t=``,n=!1,r=!1;for(let i=0;i<e.length;++i){let a=e[i];switch(a[0]){case`#`:t+=(t===``?``:r?`
|
|
87
|
-
|
|
88
|
-
`:`
|
|
89
|
-
`)+(a.substring(1)||` `),n=!0,r=!1;break;case`%`:e[i+1]?.[0]!==`#`&&(i+=1),n=!1;break;default:n||(r=!0),n=!1}}return{comment:t,afterEmptyLine:r}}var Ki=class{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(e,t,n,r)=>{let i=Wi(e);r?this.warnings.push(new li(i,t,n)):this.errors.push(new ci(i,t,n))},this.directives=new en({version:e.version||`1.2`}),this.options=e}decorate(e,t){let{comment:n,afterEmptyLine:r}=Gi(this.prelude);if(n){let i=e.contents;if(t)e.comment=e.comment?`${e.comment}\n${n}`:n;else if(r||e.directives.docStart||!i)e.commentBefore=n;else if(J(i)&&!i.flow&&i.items.length>0){let e=i.items[0];K(e)&&(e=e.key);let t=e.commentBefore;e.commentBefore=t?`${n}\n${t}`:n}else{let e=i.commentBefore;i.commentBefore=e?`${n}\n${e}`:n}}if(t){for(let t=0;t<this.errors.length;++t)e.errors.push(this.errors[t]);for(let t=0;t<this.warnings.length;++t)e.warnings.push(this.warnings[t])}else e.errors=this.errors,e.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:Gi(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,t=!1,n=-1){for(let t of e)yield*this.next(t);yield*this.end(t,n)}*next(e){switch(e.type){case`directive`:this.directives.add(e.source,(t,n,r)=>{let i=Wi(e);i[0]+=t,this.onError(i,`BAD_DIRECTIVE`,n,r)}),this.prelude.push(e.source),this.atDirectives=!0;break;case`document`:{let t=Ui(this.options,this.directives,e,this.onError);this.atDirectives&&!t.directives.docStart&&this.onError(e,`MISSING_CHAR`,`Missing directives-end/doc-start indicator line`),this.decorate(t,!1),this.doc&&(yield this.doc),this.doc=t,this.atDirectives=!1;break}case`byte-order-mark`:case`space`:break;case`comment`:case`newline`:this.prelude.push(e.source);break;case`error`:{let t=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new ci(Wi(e),`UNEXPECTED_TOKEN`,t);this.atDirectives||!this.doc?this.errors.push(n):this.doc.errors.push(n);break}case`doc-end`:{if(!this.doc){this.errors.push(new ci(Wi(e),`UNEXPECTED_TOKEN`,`Unexpected doc-end without preceding document`));break}this.doc.directives.docEnd=!0;let t=vi(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),t.comment){let e=this.doc.comment;this.doc.comment=e?`${e}\n${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new ci(Wi(e),`UNEXPECTED_TOKEN`,`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let e=new ai(void 0,Object.assign({_directives:this.directives},this.options));this.atDirectives&&this.onError(t,`MISSING_CHAR`,`Missing directives-end indicator line`),e.range=[0,t,t],this.decorate(e,!1),yield e}}},qi=Symbol(`break visit`),Ji=Symbol(`skip children`),Yi=Symbol(`remove item`);function Xi(e,t){`type`in e&&e.type===`document`&&(e={start:e.start,value:e.value}),Zi(Object.freeze([]),e,t)}Xi.BREAK=qi,Xi.SKIP=Ji,Xi.REMOVE=Yi,Xi.itemAtPath=(e,t)=>{let n=e;for(let[e,r]of t){let t=n?.[e];if(t&&`items`in t)n=t.items[r];else return}return n},Xi.parentCollection=(e,t)=>{let n=Xi.itemAtPath(e,t.slice(0,-1)),r=t[t.length-1][0],i=n?.[r];if(i&&`items`in i)return i;throw Error(`Parent collection not found`)};function Zi(e,t,n){let r=n(t,e);if(typeof r==`symbol`)return r;for(let i of[`key`,`value`]){let a=t[i];if(a&&`items`in a){for(let t=0;t<a.items.length;++t){let r=Zi(Object.freeze(e.concat([[i,t]])),a.items[t],n);if(typeof r==`number`)t=r-1;else if(r===qi)return qi;else r===Yi&&(a.items.splice(t,1),--t)}typeof r==`function`&&i===`key`&&(r=r(t,e))}}return typeof r==`function`?r(t,e):r}function Qi(e){switch(e){case``:return`byte-order-mark`;case``:return`doc-mode`;case``:return`flow-error-end`;case``:return`scalar`;case`---`:return`doc-start`;case`...`:return`doc-end`;case``:case`
|
|
90
|
-
`:case`\r
|
|
91
|
-
`:return`newline`;case`-`:return`seq-item-ind`;case`?`:return`explicit-key-ind`;case`:`:return`map-value-ind`;case`{`:return`flow-map-start`;case`}`:return`flow-map-end`;case`[`:return`flow-seq-start`;case`]`:return`flow-seq-end`;case`,`:return`comma`}switch(e[0]){case` `:case` `:return`space`;case`#`:return`comment`;case`%`:return`directive-line`;case`*`:return`alias`;case`&`:return`anchor`;case`!`:return`tag`;case`'`:return`single-quoted-scalar`;case`"`:return`double-quoted-scalar`;case`|`:case`>`:return`block-scalar-header`}return null}function $i(e){switch(e){case void 0:case` `:case`
|
|
92
|
-
`:case`\r`:case` `:return!0;default:return!1}}var ea=new Set(`0123456789ABCDEFabcdef`),ta=new Set(`0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()`),na=new Set(`,[]{}`),ra=new Set(` ,[]{}
|
|
93
|
-
\r `),ia=e=>!e||ra.has(e),aa=class{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer=``,this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,t=!1){if(e){if(typeof e!=`string`)throw TypeError(`source is not a string`);this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!t;let n=this.next??`stream`;for(;n&&(t||this.hasChars(1));)n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,t=this.buffer[e];for(;t===` `||t===` `;)t=this.buffer[++e];return!t||t===`#`||t===`
|
|
94
|
-
`||t===`\r`&&this.buffer[e+1]===`
|
|
95
|
-
`}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let t=this.buffer[e];if(this.indentNext>0){let n=0;for(;t===` `;)t=this.buffer[++n+e];if(t===`\r`){let t=this.buffer[n+e+1];if(t===`
|
|
96
|
-
`||!t&&!this.atEnd)return e+n+1}return t===`
|
|
97
|
-
`||n>=this.indentNext||!t&&!this.atEnd?e+n:-1}if(t===`-`||t===`.`){let t=this.buffer.substr(e,3);if((t===`---`||t===`...`)&&$i(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return(typeof e!=`number`||e!==-1&&e<this.pos)&&(e=this.buffer.indexOf(`
|
|
98
|
-
`,this.pos),this.lineEndPos=e),e===-1?this.atEnd?this.buffer.substring(this.pos):null:(this.buffer[e-1]===`\r`&&--e,this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case`stream`:return yield*this.parseStream();case`line-start`:return yield*this.parseLineStart();case`block-start`:return yield*this.parseBlockStart();case`doc`:return yield*this.parseDocument();case`flow`:return yield*this.parseFlowCollection();case`quoted-scalar`:return yield*this.parseQuotedScalar();case`block-scalar`:return yield*this.parseBlockScalar();case`plain-scalar`:return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(e===null)return this.setNext(`stream`);if(e[0]===``&&(yield*this.pushCount(1),e=e.substring(1)),e[0]===`%`){let t=e.length,n=e.indexOf(`#`);for(;n!==-1;){let r=e[n-1];if(r===` `||r===` `){t=n-1;break}n=e.indexOf(`#`,n+1)}for(;;){let n=e[t-1];if(n===` `||n===` `)--t;else break}let r=(yield*this.pushCount(t))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-r),this.pushNewline(),`stream`}if(this.atLineEnd()){let t=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-t),yield*this.pushNewline(),`stream`}return yield``,yield*this.parseLineStart()}*parseLineStart(){let e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext(`line-start`);if(e===`-`||e===`.`){if(!this.atEnd&&!this.hasChars(4))return this.setNext(`line-start`);let e=this.peek(3);if((e===`---`||e===`...`)&&$i(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,e===`---`?`doc`:`stream`}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!$i(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){let[e,t]=this.peek(2);if(!t&&!this.atEnd)return this.setNext(`block-start`);if((e===`-`||e===`?`||e===`:`)&&$i(t)){let e=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=e,`block-start`}return`doc`}*parseDocument(){yield*this.pushSpaces(!0);let e=this.getLine();if(e===null)return this.setNext(`doc`);let t=yield*this.pushIndicators();switch(e[t]){case`#`:yield*this.pushCount(e.length-t);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case`{`:case`[`:return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,`flow`;case`}`:case`]`:return yield*this.pushCount(1),`doc`;case`*`:return yield*this.pushUntil(ia),`doc`;case`"`:case`'`:return yield*this.parseQuotedScalar();case`|`:case`>`:return t+=yield*this.parseBlockScalarHeader(),t+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-t),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,t,n=-1;do e=yield*this.pushNewline(),e>0?(t=yield*this.pushSpaces(!1),this.indentValue=n=t):t=0,t+=yield*this.pushSpaces(!0);while(e+t>0);let r=this.getLine();if(r===null)return this.setNext(`flow`);if((n!==-1&&n<this.indentNext&&r[0]!==`#`||n===0&&(r.startsWith(`---`)||r.startsWith(`...`))&&$i(r[3]))&&(n!==this.indentNext-1||this.flowLevel!==1||r[0]!==`]`&&r[0]!==`}`))return this.flowLevel=0,yield``,yield*this.parseLineStart();let i=0;for(;r[i]===`,`;)i+=yield*this.pushCount(1),i+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(i+=yield*this.pushIndicators(),r[i]){case void 0:return`flow`;case`#`:return yield*this.pushCount(r.length-i),`flow`;case`{`:case`[`:return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,`flow`;case`}`:case`]`:return yield*this.pushCount(1),this.flowKey=!0,--this.flowLevel,this.flowLevel?`flow`:`doc`;case`*`:return yield*this.pushUntil(ia),`flow`;case`"`:case`'`:return this.flowKey=!0,yield*this.parseQuotedScalar();case`:`:{let e=this.charAt(1);if(this.flowKey||$i(e)||e===`,`)return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),`flow`}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let e=this.charAt(0),t=this.buffer.indexOf(e,this.pos+1);if(e===`'`)for(;t!==-1&&this.buffer[t+1]===`'`;)t=this.buffer.indexOf(`'`,t+2);else for(;t!==-1;){let e=0;for(;this.buffer[t-1-e]===`\\`;)e+=1;if(e%2==0)break;t=this.buffer.indexOf(`"`,t+1)}let n=this.buffer.substring(0,t),r=n.indexOf(`
|
|
99
|
-
`,this.pos);if(r!==-1){for(;r!==-1;){let e=this.continueScalar(r+1);if(e===-1)break;r=n.indexOf(`
|
|
100
|
-
`,e)}r!==-1&&(t=r-(n[r-1]===`\r`?2:1))}if(t===-1){if(!this.atEnd)return this.setNext(`quoted-scalar`);t=this.buffer.length}return yield*this.pushToIndex(t+1,!1),this.flowLevel?`flow`:`doc`}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){let t=this.buffer[++e];if(t===`+`)this.blockScalarKeep=!0;else if(t>`0`&&t<=`9`)this.blockScalarIndent=Number(t)-1;else if(t!==`-`)break}return yield*this.pushUntil(e=>$i(e)||e===`#`)}*parseBlockScalar(){let e=this.pos-1,t=0,n;loop:for(let r=this.pos;n=this.buffer[r];++r)switch(n){case` `:t+=1;break;case`
|
|
101
|
-
`:e=r,t=0;break;case`\r`:{let e=this.buffer[r+1];if(!e&&!this.atEnd)return this.setNext(`block-scalar`);if(e===`
|
|
102
|
-
`)break}default:break loop}if(!n&&!this.atEnd)return this.setNext(`block-scalar`);if(t>=this.indentNext){this.indentNext=this.blockScalarIndent===-1?t:this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{let t=this.continueScalar(e+1);if(t===-1)break;e=this.buffer.indexOf(`
|
|
103
|
-
`,t)}while(e!==-1);if(e===-1){if(!this.atEnd)return this.setNext(`block-scalar`);e=this.buffer.length}}let r=e+1;for(n=this.buffer[r];n===` `;)n=this.buffer[++r];if(n===` `){for(;n===` `||n===` `||n===`\r`||n===`
|
|
104
|
-
`;)n=this.buffer[++r];e=r-1}else if(!this.blockScalarKeep)do{let n=e-1,r=this.buffer[n];r===`\r`&&(r=this.buffer[--n]);let i=n;for(;r===` `;)r=this.buffer[--n];if(r===`
|
|
105
|
-
`&&n>=this.pos&&n+1+t>i)e=n;else break}while(1);return yield``,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let e=this.flowLevel>0,t=this.pos-1,n=this.pos-1,r;for(;r=this.buffer[++n];)if(r===`:`){let r=this.buffer[n+1];if($i(r)||e&&na.has(r))break;t=n}else if($i(r)){let i=this.buffer[n+1];if(r===`\r`&&(i===`
|
|
106
|
-
`?(n+=1,r=`
|
|
107
|
-
`,i=this.buffer[n+1]):t=n),i===`#`||e&&na.has(i))break;if(r===`
|
|
108
|
-
`){let e=this.continueScalar(n+1);if(e===-1)break;n=Math.max(n,e-2)}}else{if(e&&na.has(r))break;t=n}return!r&&!this.atEnd?this.setNext(`plain-scalar`):(yield``,yield*this.pushToIndex(t+1,!0),e?`flow`:`doc`)}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,t){let n=this.buffer.slice(this.pos,e);return n?(yield n,this.pos+=n.length,n.length):(t&&(yield``),0)}*pushIndicators(){let e=0;loop:for(;;){switch(this.charAt(0)){case`!`:e+=yield*this.pushTag(),e+=yield*this.pushSpaces(!0);continue loop;case`&`:e+=yield*this.pushUntil(ia),e+=yield*this.pushSpaces(!0);continue loop;case`-`:case`?`:case`:`:{let t=this.flowLevel>0,n=this.charAt(1);if($i(n)||t&&na.has(n)){t?this.flowKey&&=!1:this.indentNext=this.indentValue+1,e+=yield*this.pushCount(1),e+=yield*this.pushSpaces(!0);continue loop}}}break loop}return e}*pushTag(){if(this.charAt(1)===`<`){let e=this.pos+2,t=this.buffer[e];for(;!$i(t)&&t!==`>`;)t=this.buffer[++e];return yield*this.pushToIndex(t===`>`?e+1:e,!1)}{let e=this.pos+1,t=this.buffer[e];for(;t;)if(ta.has(t))t=this.buffer[++e];else if(t===`%`&&ea.has(this.buffer[e+1])&&ea.has(this.buffer[e+2]))t=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];return e===`
|
|
109
|
-
`?yield*this.pushCount(1):e===`\r`&&this.charAt(1)===`
|
|
110
|
-
`?yield*this.pushCount(2):0}*pushSpaces(e){let t=this.pos-1,n;do n=this.buffer[++t];while(n===` `||e&&n===` `);let r=t-this.pos;return r>0&&(yield this.buffer.substr(this.pos,r),this.pos=t),r}*pushUntil(e){let t=this.pos,n=this.buffer[t];for(;!e(n);)n=this.buffer[++t];return yield*this.pushToIndex(t,!1)}},oa=class{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let t=0,n=this.lineStarts.length;for(;t<n;){let r=t+n>>1;this.lineStarts[r]<e?t=r+1:n=r}if(this.lineStarts[t]===e)return{line:t+1,col:1};if(t===0)return{line:0,col:e};let r=this.lineStarts[t-1];return{line:t,col:e-r+1}}}};function sa(e,t){for(let n=0;n<e.length;++n)if(e[n].type===t)return!0;return!1}function ca(e){for(let t=0;t<e.length;++t)switch(e[t].type){case`space`:case`comment`:case`newline`:break;default:return t}return-1}function la(e){switch(e?.type){case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:case`flow-collection`:return!0;default:return!1}}function ua(e){switch(e.type){case`document`:return e.start;case`block-map`:{let t=e.items[e.items.length-1];return t.sep??t.start}case`block-seq`:return e.items[e.items.length-1].start;default:return[]}}function da(e){if(e.length===0)return[];let t=e.length;loop:for(;--t>=0;)switch(e[t].type){case`doc-start`:case`explicit-key-ind`:case`map-value-ind`:case`seq-item-ind`:case`newline`:break loop}for(;e[++t]?.type===`space`;);return e.splice(t,e.length)}function fa(e,t){if(t.length<1e5)Array.prototype.push.apply(e,t);else for(let n=0;n<t.length;++n)e.push(t[n])}function pa(e){if(e.start.type===`flow-seq-start`)for(let t of e.items)t.sep&&!t.value&&!sa(t.start,`explicit-key-ind`)&&!sa(t.sep,`map-value-ind`)&&(t.key&&(t.value=t.key),delete t.key,la(t.value)?t.value.end?fa(t.value.end,t.sep):t.value.end=t.sep:fa(t.start,t.sep),delete t.sep)}var ma=class{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source=``,this.type=``,this.lexer=new aa,this.onNewLine=e}*parse(e,t=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(let n of this.lexer.lex(e,t))yield*this.next(n);t||(yield*this.end())}*next(e){if(this.source=e,this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}let t=Qi(e);if(!t){let t=`Not a YAML token: ${e}`;yield*this.pop({type:`error`,offset:this.offset,message:t,source:e}),this.offset+=e.length}else if(t===`scalar`)this.atNewLine=!1,this.atScalar=!0,this.type=`scalar`;else{switch(this.type=t,yield*this.step(),t){case`newline`:this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case`space`:this.atNewLine&&e[0]===` `&&(this.indent+=e.length);break;case`explicit-key-ind`:case`map-value-ind`:case`seq-item-ind`:this.atNewLine&&(this.indent+=e.length);break;case`doc-mode`:case`flow-error-end`:return;default:this.atNewLine=!1}this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if(this.type===`doc-end`&&e?.type!==`doc-end`){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:`doc-end`,offset:this.offset,source:this.source})}else{if(!e)return yield*this.stream();switch(e.type){case`document`:return yield*this.document(e);case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:return yield*this.scalar(e);case`block-scalar`:return yield*this.blockScalar(e);case`block-map`:return yield*this.blockMap(e);case`block-seq`:return yield*this.blockSequence(e);case`flow-collection`:return yield*this.flowCollection(e);case`doc-end`:return yield*this.documentEnd(e)}yield*this.pop()}}peek(e){return this.stack[this.stack.length-e]}*pop(e){let t=e??this.stack.pop();if(!t)yield{type:`error`,offset:this.offset,source:``,message:`Tried to pop an empty stack`};else if(this.stack.length===0)yield t;else{let e=this.peek(1);switch(t.type===`block-scalar`?t.indent=`indent`in e?e.indent:0:t.type===`flow-collection`&&e.type===`document`&&(t.indent=0),t.type===`flow-collection`&&pa(t),e.type){case`document`:e.value=t;break;case`block-scalar`:e.props.push(t);break;case`block-map`:{let n=e.items[e.items.length-1];if(n.value){e.items.push({start:[],key:t,sep:[]}),this.onKeyLine=!0;return}if(n.sep)n.value=t;else{Object.assign(n,{key:t,sep:[]}),this.onKeyLine=!n.explicitKey;return}break}case`block-seq`:{let n=e.items[e.items.length-1];n.value?e.items.push({start:[],value:t}):n.value=t;break}case`flow-collection`:{let n=e.items[e.items.length-1];!n||n.value?e.items.push({start:[],key:t,sep:[]}):n.sep?n.value=t:Object.assign(n,{key:t,sep:[]});return}default:yield*this.pop(),yield*this.pop(t)}if((e.type===`document`||e.type===`block-map`||e.type===`block-seq`)&&(t.type===`block-map`||t.type===`block-seq`)){let n=t.items[t.items.length-1];n&&!n.sep&&!n.value&&n.start.length>0&&ca(n.start)===-1&&(t.indent===0||n.start.every(e=>e.type!==`comment`||e.indent<t.indent))&&(e.type===`document`?e.end=n.start:e.items.push({start:n.start}),t.items.splice(-1,1))}}}*stream(){switch(this.type){case`directive-line`:yield{type:`directive`,offset:this.offset,source:this.source};return;case`byte-order-mark`:case`space`:case`comment`:case`newline`:yield this.sourceToken;return;case`doc-mode`:case`doc-start`:{let e={type:`document`,offset:this.offset,start:[]};this.type===`doc-start`&&e.start.push(this.sourceToken),this.stack.push(e);return}}yield{type:`error`,offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case`doc-start`:ca(e.start)===-1?e.start.push(this.sourceToken):(yield*this.pop(),yield*this.step());return;case`anchor`:case`tag`:case`space`:case`comment`:case`newline`:e.start.push(this.sourceToken);return}let t=this.startBlockValue(e);t?this.stack.push(t):yield{type:`error`,offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if(this.type===`map-value-ind`){let t=da(ua(this.peek(2))),n;e.end?(n=e.end,n.push(this.sourceToken),delete e.end):n=[this.sourceToken];let r={type:`block-map`,offset:e.offset,indent:e.indent,items:[{start:t,key:e,sep:n}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=r}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case`space`:case`comment`:case`newline`:e.props.push(this.sourceToken);return;case`scalar`:if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let e=this.source.indexOf(`
|
|
111
|
-
`)+1;for(;e!==0;)this.onNewLine(this.offset+e),e=this.source.indexOf(`
|
|
112
|
-
`,e)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let t=e.items[e.items.length-1];switch(this.type){case`newline`:if(this.onKeyLine=!1,t.value){let n=`end`in t.value?t.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type===`comment`?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`space`:case`comment`:if(t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2]?.value?.end;if(Array.isArray(n)){fa(n,t.start),n.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let n=!this.onKeyLine&&this.indent===e.indent,r=n&&(t.sep||t.explicitKey)&&this.type!==`seq-item-ind`,i=[];if(r&&t.sep&&!t.value){let n=[];for(let r=0;r<t.sep.length;++r){let i=t.sep[r];switch(i.type){case`newline`:n.push(r);break;case`space`:break;case`comment`:i.indent>e.indent&&(n.length=0);break;default:n.length=0}}n.length>=2&&(i=t.sep.splice(n[1]))}switch(this.type){case`anchor`:case`tag`:r||t.value?(i.push(this.sourceToken),e.items.push({start:i}),this.onKeyLine=!0):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`explicit-key-ind`:!t.sep&&!t.explicitKey?(t.start.push(this.sourceToken),t.explicitKey=!0):r||t.value?(i.push(this.sourceToken),e.items.push({start:i,explicitKey:!0})):this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case`map-value-ind`:if(t.explicitKey){if(!t.sep){if(sa(t.start,`newline`))Object.assign(t,{key:null,sep:[this.sourceToken]});else{let e=da(t.start);this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:e,key:null,sep:[this.sourceToken]}]})}}else if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(sa(t.sep,`map-value-ind`))this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:i,key:null,sep:[this.sourceToken]}]});else if(la(t.key)&&!sa(t.sep,`newline`)){let e=da(t.start),n=t.key,r=t.sep;r.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:e,key:n,sep:r}]})}else i.length>0?t.sep=t.sep.concat(i,this.sourceToken):t.sep.push(this.sourceToken)}else t.sep?t.value||r?e.items.push({start:i,key:null,sep:[this.sourceToken]}):sa(t.sep,`map-value-ind`)?this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:{let n=this.flowScalar(this.type);r||t.value?(e.items.push({start:i,key:n,sep:[]}),this.onKeyLine=!0):t.sep?this.stack.push(n):(Object.assign(t,{key:n,sep:[]}),this.onKeyLine=!0);return}default:{let r=this.startBlockValue(e);if(r){if(r.type===`block-seq`){if(!t.explicitKey&&t.sep&&!sa(t.sep,`newline`)){yield*this.pop({type:`error`,offset:this.offset,message:`Unexpected block-seq-ind on same line with key`,source:this.source});return}}else n&&e.items.push({start:i});this.stack.push(r);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let t=e.items[e.items.length-1];switch(this.type){case`newline`:if(t.value){let n=`end`in t.value?t.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type===`comment`?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case`space`:case`comment`:if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2]?.value?.end;if(Array.isArray(n)){fa(n,t.start),n.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return;case`anchor`:case`tag`:if(t.value||this.indent<=e.indent)break;t.start.push(this.sourceToken);return;case`seq-item-ind`:if(this.indent!==e.indent)break;t.value||sa(t.start,`seq-item-ind`)?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return}if(this.indent>e.indent){let t=this.startBlockValue(e);if(t){this.stack.push(t);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let t=e.items[e.items.length-1];if(this.type===`flow-error-end`){let e;do yield*this.pop(),e=this.peek(1);while(e?.type===`flow-collection`)}else if(e.end.length===0){switch(this.type){case`comma`:case`explicit-key-ind`:!t||t.sep?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return;case`map-value-ind`:!t||t.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});return;case`space`:case`comment`:case`newline`:case`anchor`:case`tag`:!t||t.value?e.items.push({start:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:{let n=this.flowScalar(this.type);!t||t.value?e.items.push({start:[],key:n,sep:[]}):t.sep?this.stack.push(n):Object.assign(t,{key:n,sep:[]});return}case`flow-map-end`:case`flow-seq-end`:e.end.push(this.sourceToken);return}let n=this.startBlockValue(e);n?this.stack.push(n):(yield*this.pop(),yield*this.step())}else{let t=this.peek(2);if(t.type===`block-map`&&(this.type===`map-value-ind`&&t.indent===e.indent||this.type===`newline`&&!t.items[t.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type===`map-value-ind`&&t.type!==`flow-collection`){let n=da(ua(t));pa(e);let r=e.end.splice(1,e.end.length);r.push(this.sourceToken);let i={type:`block-map`,offset:e.offset,indent:e.indent,items:[{start:n,key:e,sep:r}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=i}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let e=this.source.indexOf(`
|
|
113
|
-
`)+1;for(;e!==0;)this.onNewLine(this.offset+e),e=this.source.indexOf(`
|
|
114
|
-
`,e)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:return this.flowScalar(this.type);case`block-scalar-header`:return{type:`block-scalar`,offset:this.offset,indent:this.indent,props:[this.sourceToken],source:``};case`flow-map-start`:case`flow-seq-start`:return{type:`flow-collection`,offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case`seq-item-ind`:return{type:`block-seq`,offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case`explicit-key-ind`:{this.onKeyLine=!0;let t=da(ua(e));return t.push(this.sourceToken),{type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:t,explicitKey:!0}]}}case`map-value-ind`:{this.onKeyLine=!0;let t=da(ua(e));return{type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){return this.type!==`comment`||this.indent<=t?!1:e.every(e=>e.type===`newline`||e.type===`space`)}*documentEnd(e){this.type!==`doc-mode`&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type===`newline`&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case`comma`:case`doc-start`:case`doc-end`:case`flow-seq-end`:case`flow-map-end`:case`map-value-ind`:yield*this.pop(),yield*this.step();break;case`newline`:this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type===`newline`&&(yield*this.pop())}}};function ha(e){let t=e.prettyErrors!==!1;return{lineCounter:e.lineCounter||t&&new oa||null,prettyErrors:t}}function ga(e,t={}){let{lineCounter:n,prettyErrors:r}=ha(t),i=new ma(n?.addNewLine),a=new Ki(t),o=null;for(let t of a.compose(i.parse(e),!0,e.length))if(!o)o=t;else if(o.options.logLevel!==`silent`){o.errors.push(new ci(t.range.slice(0,2),`MULTIPLE_DOCS`,`Source contains multiple documents; please use YAML.parseAllDocuments()`));break}return r&&n&&(o.errors.forEach(ui(e,n)),o.warnings.forEach(ui(e,n))),o}function _a(e,t){let n=[];return{problems:n,at(r,i){let a=r.length===0?e.contents:e.getIn(r,!0),o=(typeof a==`object`&&a&&`range`in a&&Array.isArray(a.range)?a.range:void 0)?.[0];n.push({path:r.join(`.`),...o===void 0?{}:{line:t.linePos(o).line},message:i})}}}function va(e){let t=new oa,n=ga(e,{lineCounter:t,prettyErrors:!1}),r=n.errors.map(e=>({path:``,line:t.linePos(e.pos[0]).line,message:`not YAML: ${e.message.split(`
|
|
115
|
-
`)[0]??``}`}));if(r.length>0)return{value:{},doc:n,lines:t,problems:r};let i=n.toJS()??{};return!G(n.contents)&&n.contents!==null?(r.push({path:``,line:1,message:`should be a map of fields`}),{value:{},doc:n,lines:t,problems:r}):{value:i,doc:n,lines:t,problems:r}}var ya=e=>typeof e==`object`&&!!e&&!Array.isArray(e),ba=e=>Array.isArray(e)?`a list`:e===null?`nothing`:typeof e==`object`?`a map`:JSON.stringify(e);function xa(e,t,n,r){for(let i of Object.keys(t))n.includes(i)||e.at([...r,i],`${i} is not a field here (${n.join(`, `)})`)}var Sa=e=>typeof e==`number`&&Number.isFinite(e)&&e>0;function Ca(e,t,n){if(t===`plain`||t===`percent`||t===`currency`)return{style:t,thousands:!0};if(!ya(t)){e.at(n,`should be plain, percent, currency or a map, not ${ba(t)}`);return}xa(e,t,[`style`,`decimals`,`currency`,`thousands`],n);let r=t.style??(t.currency===void 0?`plain`:`currency`);if(r!==`plain`&&r!==`percent`&&r!==`currency`){e.at([...n,`style`],`should be plain, percent or currency`);return}let i={style:r,thousands:t.thousands!==!1},a=t.decimals;a!==void 0&&(typeof a==`number`&&Number.isInteger(a)&&a>=0&&a<=10?i.decimals=a:e.at([...n,`decimals`],`should be a whole number from 0 to 10`));let o=t.currency;return o!==void 0&&(typeof o==`string`&&/^[A-Za-z]{3}$/.test(o)?i.currency=o.toUpperCase():e.at([...n,`currency`],`should be a three-letter currency code: USD, EUR, CNY`)),t.thousands!==void 0&&typeof t.thousands!=`boolean`&&e.at([...n,`thousands`],`should be true or false`),i}function wa(e,t,n){if(t===`iso`||t===`short`||t===`long`)return{style:t,time:!0};if(!ya(t)){e.at(n,`should be iso, short, long or a map, not ${ba(t)}`);return}xa(e,t,[`style`,`time`],n);let r=t.style??`short`;if(r!==`iso`&&r!==`short`&&r!==`long`)e.at([...n,`style`],`should be iso, short or long`);else return t.time!==void 0&&typeof t.time!=`boolean`&&e.at([...n,`time`],`should be true or false`),{style:r,time:t.time!==!1}}function Ta(t,n,r,i){if(!Array.isArray(n))return t.at(r,`should be a list of options`),[];let a=[],o=new Set;return n.forEach((n,s)=>{let c=[...r,s],l;if(typeof n==`string`||typeof n==`number`||typeof n==`boolean`)l={name:String(n)};else if(ya(n)){xa(t,n,[`name`,`color`],c);let r=n.name;if(typeof r!=`string`&&typeof r!=`number`){t.at(c,`an option needs a name`);return}l={name:String(r)};let i=n.color;i!==void 0&&(e.includes(i)?l.color=i:t.at([...c,`color`],`should be one of ${e.join(`, `)}`))}else{t.at(c,`an option is a name, or a map with a name and a color`);return}l.name=l.name.trim(),l.name===``?t.at(c,`an option's name cannot be empty`):(l.name.includes(i)&&t.at(c,`"${l.name}" has the separator ${JSON.stringify(i)} in it`),o.has(l.name)?t.at(c,`"${l.name}" is an option twice`):(o.add(l.name),a.push(l)))}),a}function Ea(e,t,r){if(t==null)return{type:`text`};if(typeof t==`string`){if(n.includes(t)){let e=t;return e===`select`||e===`multi-select`?{type:e,options:[]}:{type:e}}return e.at(r,`${t} is not a type (${n.join(`, `)})`),{type:`text`}}if(!ya(t))return e.at(r,`should be a map of the column's fields, not ${ba(t)}`),{type:`text`};xa(e,t,[`type`,`options`,`separator`,`format`,`width`,`height`,`wrap`],r);let i=t.type??`text`,a=`text`;n.includes(i)?a=i:e.at([...r,`type`],`${ba(i)} is not a type (${n.join(`, `)})`);let o={type:a},s=t.separator;s!==void 0&&(a!==`multi-select`&&a!==`file`?e.at([...r,`separator`],`only a multi-select or a file column has a separator`):typeof s==`string`&&s.length>0&&s.trim()!==``&&!s.includes(`"`)?o.separator=s:e.at([...r,`separator`],`should be a character or a few, not empty, not a quote`)),t.options===void 0?(a===`select`||a===`multi-select`)&&(o.options=[]):a===`select`||a===`multi-select`?o.options=Ta(e,t.options,[...r,`options`],o.separator??`;`):e.at([...r,`options`],`only a select or a multi-select column has options`);let c=t.format;if(c!==void 0){if(a===`number`){let t=Ca(e,c,[...r,`format`]);t&&(o.number=t)}else if(a===`date`){let t=wa(e,c,[...r,`format`]);t&&(o.date=t)}else e.at([...r,`format`],`only a number or a date column has a format`)}let l=t.width;l!==void 0&&(Sa(l)?o.width=Math.round(l):e.at([...r,`width`],`should be a width in px`));let u=t.height;u!==void 0&&(a===`file`?Sa(u)?o.height=Math.round(u):e.at([...r,`height`],`should be a height in px`):e.at([...r,`height`],`only a file column has a height`));let d=t.wrap;return d!==void 0&&(typeof d==`boolean`?o.wrap=d:e.at([...r,`wrap`],`should be true or false`)),o}function Da(e){let{spec:t,value:n,r}=Oa(e);if(r.problems.length===0){let e=p(`sheet`,n);if(!e.ok)for(let t of e.problems)r.at(t.path===``?[]:t.path.split(`.`),t.message)}return{spec:t,problems:r.problems}}function Oa(e){let{value:t,doc:n,lines:r,problems:i}=va(e),a=_a(n,r);a.problems.push(...i);let o={columns:{}};if(!ya(t))return{spec:o,value:t,r:a};xa(a,t,[`title`,`key`,`primary`,`columns`],[]);let s=t.title;s!==void 0&&(typeof s==`string`||typeof s==`number`?o.title=String(s):a.at([`title`],`should be text`));let c=t.key;c!==void 0&&(typeof c==`string`&&c.trim()!==``?o.key=c:a.at([`key`],`should be a column's name`));let l=t.primary;l!==void 0&&(typeof l==`string`&&l.trim()!==``?o.primary=l:a.at([`primary`],`should be a column's name`));let u=t.columns;if(u!=null){if(!ya(u))a.at([`columns`],`should be a map from a column's name to what it is`);else for(let[e,t]of Object.entries(u))o.columns[e]=Ea(a,t,[`columns`,e])}return{spec:o,value:t,r:a}}var ka=/^-?(\d+\.?\d*|\.\d+)(e[+-]?\d+)?$/i,Aa=/^(\d{4})-(\d{2})-(\d{2})(?:[T ](\d{2}):(\d{2})(?::(\d{2})(?:\.(\d{1,3})\d*)?)?(Z|[+-]\d{2}:?\d{2})?)?$/,ja=/^[^\s@]+@[^\s@]+\.[^\s@]+$/,Ma=e=>e.trim()===``;function Na(e){let t=e.trim();if(!ka.test(t))return;let n=Number(t);return Number.isFinite(n)?n:void 0}function Pa(e){let t=Aa.exec(e.trim());if(!t)return;let[,n,r,i,a,o,s,c,l]=t,u=Number(n),d=Number(r),f=Number(i);if(d<1||d>12||f<1||f>new Date(Date.UTC(u,d,0)).getUTCDate())return;let p=a===void 0?0:Number(a),m=o===void 0?0:Number(o),h=s===void 0?0:Number(s);if(p>23||m>59||h>59)return;let g=Date.UTC(u,d-1,f,p,m,h,c===void 0?0:Number(c.padEnd(3,`0`)));if(l!==void 0&&l!==`Z`){let e=l.startsWith(`-`)?-1:1,t=l.slice(1).replace(`:`,``);g-=e*(Number(t.slice(0,2))*60+Number(t.slice(2)))*6e4}return{ms:g,time:a!==void 0}}function Fa(e){let t=e.trim().toLowerCase();return t===`true`||t!==`false`&&void 0}function Ia(e,t=`;`){return e.split(t).map(e=>e.trim()).filter(e=>e!==``)}var La=(e,t=`;`)=>e.join(t);function Ra(e,t){if(!Ma(t))switch(e.type){case`number`:return Na(t)===void 0?`is not a number (write digits with a point for decimals and no thousands separator: 1234.5)`:void 0;case`date`:return Pa(t)===void 0?`is not a date (write 2026-10-14, or 2026-10-14T09:30)`:void 0;case`checkbox`:return Fa(t)===void 0?`is not true or false`:void 0;case`select`:{let n=(e.options??[]).map(e=>e.name);return n.includes(t.trim())?void 0:`is not one of its options (${n.join(`, `)||`none`})`}case`multi-select`:{let n=new Set((e.options??[]).map(e=>e.name)),r=Ia(t,e.separator).filter(e=>!n.has(e));return r.length===0?void 0:`has ${r.map(e=>`"${e}"`).join(`, `)}, not among its options (${[...n].join(`, `)||`none`})`}case`email`:return ja.test(t.trim())?void 0:`is not an email address`;case`url`:return/\s/.test(t.trim())?`is not an address: it has a space in it`:void 0;case`text`:case`phone`:case`file`:return}}function za(e,t){let n=t.trim();if(n!==``){if(e.type===`email`)return`mailto:${n}`;if(e.type===`phone`)return`tel:${n.replace(/[^\d+]/g,``)}`;if(e.type===`url`)return/^[a-z][a-z0-9+.-]*:/i.test(n)?n:`https://${n}`}}var Ba=new Map;function Va(e,t,n){let r=JSON.stringify([e,t,n]),i=Ba.get(r);if(i)return i;let a=e?.style??`plain`,o={useGrouping:e?.thousands??!0,...n===void 0?{maximumFractionDigits:6}:{minimumFractionDigits:n,maximumFractionDigits:n}},s;try{s=a===`currency`?new Intl.NumberFormat(t,{...o,style:`currency`,currency:e?.currency??`USD`}):a===`percent`?new Intl.NumberFormat(t,{...o,style:`percent`}):new Intl.NumberFormat(t,o)}catch{s=new Intl.NumberFormat(`en`,o)}return Ba.set(r,s),s}function Ha(e,t,n=`en`){return Va(t,n,t?.decimals).format(e)}var Ua=new Map;function Wa(e,t,n=`en`){let r=t?.style??`short`,i=e.time&&(t?.time??!0);if(r===`iso`){let t=new Date(e.ms).toISOString();return i?`${t.slice(0,10)} ${t.slice(11,16)}`:t.slice(0,10)}let a=`${r}|${String(i)}|${n}`,o=Ua.get(a);if(!o){let e={timeZone:`UTC`,...r===`long`?{weekday:`long`,year:`numeric`,month:`long`,day:`numeric`}:{year:`numeric`,month:`short`,day:`numeric`},...i?{hour:`2-digit`,minute:`2-digit`,hourCycle:`h23`}:{}};try{o=new Intl.DateTimeFormat(n,e)}catch{o=new Intl.DateTimeFormat(`en`,e)}Ua.set(a,o)}return o.format(new Date(e.ms))}function Ga(e,t,n=`en`){if(Ma(t))return``;switch(e.type){case`number`:{let r=Na(t);return r===void 0?t:Ha(r,e.number,n)}case`date`:{let r=Pa(t);return r===void 0?t:Wa(r,e.date,n)}case`checkbox`:return Fa(t)===!0?`✓`:Fa(t)===!1?``:t;case`multi-select`:return Ia(t,e.separator).join(`, `);default:return t}}var Ka=new Intl.Collator(`en`,{numeric:!0,sensitivity:`base`});function qa(e,t=!1){let n=Ja(e),r=Ya(t);return(e,t)=>r(n(e),n(t))}function Ja(e){let t=new Map((e.options??[]).map((e,t)=>[e.name,t]));return n=>{if(Ma(n))return[3,0];switch(e.type){case`number`:{let e=Na(n);return e===void 0?[2,n]:[0,e]}case`date`:{let e=Pa(n);return e===void 0?[2,n]:[0,e.ms]}case`checkbox`:{let e=Fa(n);return e===void 0?[2,n]:[0,+!!e]}case`select`:{let e=t.get(n.trim());return e===void 0?[2,n]:[0,e]}case`multi-select`:{let r=t.get(Ia(n,e.separator)[0]??``);return r===void 0?[2,n]:[0,r]}default:return[0,n]}}}function Ya(e=!1){let t=e?-1:1;return([e,n],[r,i])=>e===r?e===3?0:typeof n==`number`&&typeof i==`number`?t*(n-i):t*Ka.compare(String(n),String(i)):e-r}function Xa(e,t){let n=t.trim().replace(/^\.\//,``);if(n===``||/^[a-z][a-z0-9+.-]*:/i.test(n)||n.startsWith(`/`))return[];let r=e=>{let t=[];for(let n of e.split(`/`))if(n!==``&&n!==`.`){if(n===`..`){if(t.length===0)return;t.pop()}else t.push(n)}return t.join(`/`)};return[r(`${e}/${n}`),r(n)].filter((e,t,n)=>e!==void 0&&n.indexOf(e)===t)}var Za=(e,t)=>{let n=e.length===1&&e[0]===``,r=[];for(let i=0;i<t;i++)r.push(n?``:e[i]??``);return r.join(`\0`)},Qa=(e,t,n)=>{if(!e)return!1;for(let r=0;r<n;r++)if((e[r]??``)!==(t[r]??``))return!1;return!0},$a=64;function eo(e,t,n){let r=n??jt(e.source).data,{dialect:i,records:a,source:o}=e;if(Mt(r,t))return e;let s=t.columns.length;if(s===0&&t.rows.length===0)return{source:i.bom?``:``,records:[],dialect:i,problems:[]};let c=e=>{let t=a[e+1];if(t&&!(t.fields.length>s&&t.fields.slice(s).some(e=>e!==``)))return o.slice(t.start,t.end)},l=new Uint8Array(r.rows.length),u=new Map;r.rows.forEach((e,t)=>u.set(e,t));let d,f=0,p=e=>{d||(d=new Map,r.rows.forEach((e,t)=>{if(l[t])return;let n=Za(e,s),r=d?.get(n);r?r.push(t):d?.set(n,[t])}));let t=d.get(Za(e,s));for(;t&&t.length>0;){let e=t.shift();if(e!==void 0&&!l[e])return e}},m=[],h=a[0],g=h?.fields.length===s&&h.fields.every((e,n)=>e.trim()===t.columns[n]);m.push(g?o.slice(h.start,h.end):wt(t.columns,i.delimiter)),t.rows.forEach((e,t)=>{let a=u.get(e);a!==void 0&&l[a]&&(a=void 0),a===void 0&&!l[t]&&Qa(r.rows[t],e,s)&&(a=t),a===void 0&&(f+=1,(n===void 0||f>$a)&&(a=p(e)));let o=a===void 0?void 0:c(a);if(a!==void 0&&o!==void 0){l[a]=1,m.push(o);return}let d=e.slice(0,s);for(;d.length<s;)d.push(``);m.push(wt(d,i.delimiter))});let _=m[m.length-1],v=i.finalNewline||_===``,y=i.bom?``:``,b=[],x=y.length,S=1;return m.forEach((e,n)=>{let r=n===0?t.columns:t.rows[n-1]??[];b.push({fields:r,start:x,end:x+e.length,line:S});for(let t=e.indexOf(`
|
|
116
|
-
`);t>=0;t=e.indexOf(`
|
|
117
|
-
`,t+1))S+=1;S+=1,x+=e.length+i.newline.length}),{source:`${y}${m.join(i.newline)}${v?i.newline:``}`,records:b,dialect:{...i,finalNewline:v},problems:[]}}var to=e=>q(e.key)?String(e.key.value):void 0,no=(e,t)=>{let n=(e,t)=>{if(Ht(e)){for(let r of e.items)n(r,t+1);e.flow=e.items.every(e=>q(e)||G(e)&&e.items.every(e=>q(e.value)))}else if(G(e)){for(let r of e.items)n(r.value,t+1);e.flow=t>0||e.items.length<=4&&e.items.every(e=>q(e.value)||(Ht(e.value)||G(e.value))&&e.value.flow===!0)}};n(e,0),(G(t)||Ht(t))&&(G(e)||Ht(e))&&(e.flow=t.flow??!1)};function ro(e){return new ai({[e]:0}).toString().replace(/: 0\n$/,``)}function io(e,t,n,r,i){let a=new ai({[e]:t}),o=a.contents.items[0];return o?.value&&r(o.value,i),a.toString({lineWidth:0,flowCollectionPadding:!0}).replace(/\n$/,``).replace(/\[ ([^[\]{}"'\n]*) \]/g,`[$1]`).replace(/\[ \{/g,`[{`).replace(/\} \]/g,`}]`).split(`
|
|
118
|
-
`).map((e,t)=>t===0||e===``?e:` `.repeat(n)+e).join(`
|
|
119
|
-
`)}var ao=(e,t)=>e.lastIndexOf(`
|
|
120
|
-
`,t-1)+1,oo=(e,t)=>{let n=e.indexOf(`
|
|
121
|
-
`,t);return n<0?e.length:n+1};function so(e,t,n,r){let i=ga(e??``),a=i.errors.length>0||!(G(i.contents)||i.contents===null)?new ai({}):i;if(n===void 0)a.deleteIn(t);else{let e=a.createNode(n);r(e,a.getIn(t,!0)),a.setIn(t,e)}let o=a.toString({lineWidth:0,flowCollectionPadding:!0});return o===`{}
|
|
122
|
-
`?``:o}var co=e=>JSON.stringify(ga(e).toJS()??{});function lo(e,t,n,r=no){let i=e??``,a=ga(i);if(a.errors.length>0||!(G(a.contents)||a.contents===null))return so(e,t,n,r);let o=a.contents;for(let[a,s]of t.slice(0,-1).entries()){if(o?.flow)return so(e,t,n,r);let c=o?.items.find(e=>to(e)===s);if(!c){if(n===void 0)return i;let o=n;for(let e of[...t.slice(a+1)].reverse())o={[e]:o};return lo(e,t.slice(0,a+1),o,e=>{let n=(e,i)=>{if(G(e)){e.flow=!1;for(let o of e.items)i+1<t.length-a-1?n(o.value,i+1):o.value&&r(o.value,void 0)}};n(e,0)})}if(!G(c.value))return so(e,t,n,r);o=c.value}if(o?.flow)return so(e,t,n,r);let s=t[t.length-1]??``,c=o?.items.find(e=>to(e)===s),l=c?.key,u=c?.value??void 0,d=(o?.items[0]?.key)?.range?.[0],f=d===void 0?2*(t.length-1):d-ao(i,d);if(G(u)&&!u.flow&&typeof n==`object`&&n&&!Array.isArray(n)){let e=n,a=u.toJSON()??{},o=i;for(let n of new Set([...Object.keys(a),...Object.keys(e)]))JSON.stringify(a[n])!==JSON.stringify(e[n])&&(o=lo(o,[...t,n],e[n],r));return o}let p;if(c&&l?.range){let e=l.range[0],t=u?.range?u.range[1]:l.range[1];if(n===void 0)p=i.slice(0,ao(i,e))+i.slice(oo(i,t-1));else{let a=i.charAt(t-1)===`
|
|
123
|
-
`?`
|
|
124
|
-
`:``;p=i.slice(0,e)+io(s,n,f,r,u)+a+i.slice(t)}}else{if(n===void 0)return i;let e=io(s,n,f,r,void 0),t=o?.items[o.items.length-1],a=(t?.value??t?.key)?.range?.[1];if(a===void 0)p=`${i}${i===``||i.endsWith(`
|
|
125
|
-
`)?``:`
|
|
126
|
-
`}${` `.repeat(f)}${e}\n`;else{let t=i.charAt(a-1)===`
|
|
127
|
-
`?a:oo(i,a),n=t>0&&i.charAt(t-1)!==`
|
|
128
|
-
`?`
|
|
129
|
-
`:``;p=`${i.slice(0,t)}${n}${` `.repeat(f)}${e}\n${i.slice(t)}`}}let m=so(e,t,n,r);return ga(p).errors.length>0||co(p)!==co(m)?m:p}function uo(e){return e.decimals===void 0&&e.currency===void 0&&e.thousands?e.style:{...e.style===`plain`?{}:{style:e.style},...e.currency===void 0?{}:{currency:e.currency},...e.decimals===void 0?{}:{decimals:e.decimals},...e.thousands?{}:{thousands:!1}}}function fo(e){let t={type:e.type,...e.options===void 0||e.type!==`select`&&e.type!==`multi-select`?{}:{options:e.options.map(e=>e.color===void 0?e.name:{name:e.name,color:e.color})},...e.separator===void 0||e.type!==`multi-select`&&e.type!==`file`?{}:{separator:e.separator},...e.type===`number`&&e.number?{format:uo(e.number)}:{},...e.type===`date`&&e.date?{format:e.date.time?e.date.style:{style:e.date.style,time:!1}}:{},...e.width===void 0?{}:{width:e.width},...e.height===void 0||e.type!==`file`?{}:{height:e.height},...e.wrap===void 0?{}:{wrap:e.wrap}};return Object.keys(t).length===1?e.type:t}function po(e,t,n){let r=lo(e,[`columns`,t],n===void 0?void 0:fo(n)),i=ga(r),a=i.errors.length===0?i.getIn([`columns`],!0):void 0;return n===void 0&&G(a)&&a.items.length===0&&(r=lo(r,[`columns`],void 0)),r}function mo(e,t,n){let r=e??``,i=ga(r),a=r,o=i.errors.length===0?i.getIn([`columns`],!0):void 0;if(G(o)){let e=o.items.find(e=>to(e)===t)?.key?.range;e&&(a=r.slice(0,e[0])+ro(n)+r.slice(e[1]))}return ga(a).get(`key`)===t&&(a=lo(a,[`key`],n)),ga(a).get(`primary`)===t&&(a=lo(a,[`primary`],n)),a}function ho(e,t,n){return lo(e,[t],n===void 0||n===``?void 0:n)}var go=e=>e.trim().toLocaleLowerCase(),_o=e=>typeof e==`string`?Pa(e)?.ms:void 0,vo=e=>Math.floor(e/864e5)*864e5;function yo(e,t,n){let{op:r}=t,i=t.value;if(r===`empty`)return Ma(n);if(r===`not-empty`)return!Ma(n);switch(e.type){case`number`:{let e=Na(n);if(e===void 0)return r===`!=`;if(r===`between`){if(!Array.isArray(i)||i.length!==2)return!1;let t=Number(i[0]),n=Number(i[1]);return e>=Math.min(t,n)&&e<=Math.max(t,n)}let t=Number(i);if(!Number.isFinite(t))return!1;switch(r){case`=`:return e===t;case`!=`:return e!==t;case`<`:return e<t;case`<=`:return e<=t;case`>`:return e>t;case`>=`:return e>=t;default:return!1}}case`date`:{let e=Pa(n);if(!e)return!1;let t=vo(e.ms);if(r===`between`){if(!Array.isArray(i)||i.length!==2)return!1;let e=_o(i[0]),n=_o(i[1]);return e===void 0||n===void 0?!1:t>=vo(Math.min(e,n))&&t<=vo(Math.max(e,n))}let a=_o(i);if(a===void 0)return!1;let o=vo(a);switch(r){case`on`:return t===o;case`before`:return t<o;case`after`:return t>o;case`on-or-before`:return t<=o;case`on-or-after`:return t>=o;default:return!1}}case`checkbox`:return(Fa(n)??!1)===(typeof i==`boolean`?i:Fa(String(i))??!0);case`select`:{let e=n.trim();return r===`in`||r===`not-in`?(Array.isArray(i)?i.map(String):[String(i)]).includes(e)===(r===`in`):r===`is`?e===String(i):r===`is-not`&&e!==String(i)}case`multi-select`:{let t=new Set(Ia(n,e.separator)),a=Array.isArray(i)?i.map(String):[String(i)];switch(r){case`has`:return a.every(e=>t.has(e));case`has-any`:return a.some(e=>t.has(e));case`has-all`:return a.every(e=>t.has(e));case`has-none`:return!a.some(e=>t.has(e));default:return!1}}default:{let e=go(n),t=go(String(i??``));switch(r){case`is`:return e===t;case`is-not`:return e!==t;case`contains`:return e.includes(t);case`not-contains`:return!e.includes(t);case`starts-with`:return e.startsWith(t);case`ends-with`:return e.endsWith(t);default:return!1}}}}function bo(e){if(e.op===`empty`||e.op===`not-empty`)return!1;let t=e.value;return t===void 0||t===``?!0:Array.isArray(t)?t.length===0||t.every(e=>e===``):!1}function xo(e,t,n,r){if(Ot(n))return`all`in n?n.all.every(n=>xo(e,t,n,r)):n.any.length===0||n.any.some(n=>xo(e,t,n,r));if(bo(n))return!0;let i=e.columns.indexOf(n.column);return i<0?!1:yo(W(t,n.column),n,r[i]??``)}function So(e,t,n){let r=n.filter;return Co(e,t,e.rows.map((e,t)=>t).filter(n=>r===void 0||xo(e,t,r,e.rows[n]??[])),n.sort??[])}function Co(e,t,n,r){let i=r.map(t=>({at:e.columns.indexOf(t.column),k:t})).filter(e=>e.at>=0).map(({at:r,k:i})=>{let a=Ja(W(t,i.column)),o=[];for(let t of n)o[t]=a(e.rows[t]?.[r]??``);return{values:o,cmp:Ya(i.desc===!0)}});if(i.length===0)return[...n];let a=[3,0];return[...n].sort((e,t)=>{for(let{values:n,cmp:r}of i){let i=r(n[e]??a,n[t]??a);if(i!==0)return i}return e-t})}function wo(e,t){return t.columns?t.columns.filter(t=>e.columns.includes(t)):[...e.columns]}function To(e,t){if(t.primary!==void 0&&e.includes(t.primary))return t.primary;let n=e.filter(e=>e!==t.key);return n.find(e=>W(t,e).type===`text`)??n[0]??e[0]}var Eo=e=>`sheet.look:${e}`;function Do(e){return typeof e==`object`&&e&&!Array.isArray(e)?e:void 0}function Oo(e){let t={};return e.columns&&(t.columns=e.columns),e.widths&&Object.keys(e.widths).length>0&&(t.widths=e.widths),e.freeze&&(t.freeze=e.freeze),e.wrap?.length&&(t.wrap=e.wrap),e.sort?.length&&(t.sort=e.sort),e.filter&&(t.filter=e.filter),t}var ko=(e,t)=>JSON.stringify(Oo(e))===JSON.stringify(Oo(t));function Ao(e,t,n){let r=e=>Ot(e)?Ao(e,t,n):e.column===t?{...e,column:n}:e;return`all`in e?{all:e.all.map(r)}:{any:e.any.map(r)}}function jo(e,t,n){if(!JSON.stringify(e).includes(JSON.stringify(t)))return e;let r=e=>e===t?n:e,i={...e};return e.columns&&(i.columns=e.columns.map(r)),e.widths&&(i.widths=Object.fromEntries(Object.entries(e.widths).map(([e,t])=>[r(e),t]))),e.wrap&&(i.wrap=e.wrap.map(r)),e.sort&&(i.sort=e.sort.map(e=>({...e,column:r(e.column)}))),e.filter&&(i.filter=Ao(e.filter,t,n)),i}function Mo(e){let t=(`all`in e?e.all:e.any).flatMap(e=>{if(Ot(e)){let t=Mo(e);return t?[t]:[]}return bo(e)?[]:[e]});if(t.length!==0)return`all`in e?{all:t}:{any:t}}function No(e){if(!e.filter)return e;let t=Mo(e.filter),n=Po(e);return t?{...n,filter:t}:n}function Po(e){let t={...e};return delete t.filter,t}var Fo=e=>new Date(Math.floor(e/864e5)*864e5).toISOString().slice(0,10);function Io(e,t,n,r){if(Ma(n))return[{key:`∅`,label:``,condition:{column:e,op:`empty`}}];let i=n.trim();switch(t.type){case`number`:{let n=Na(i);return n===void 0?[]:[{key:`n:${String(n)}`,label:Ga(t,i,r),condition:{column:e,op:`=`,value:n}}]}case`date`:{let n=Pa(i);if(!n)return[];let a=Fo(n.ms);return[{key:`d:${a}`,label:Ga({...t,date:{style:t.date?.style??`short`,time:!1}},a,r),condition:{column:e,op:`on`,value:a}}]}case`checkbox`:{let t=Fa(i)??!1;return[{key:`b:${String(t)}`,label:String(t),condition:{column:e,op:`is`,value:t}}]}case`multi-select`:return Ia(i,t.separator).map(t=>({key:`m:${t}`,label:t,condition:{column:e,op:`has-any`,value:[t]}}));case`select`:return[{key:`s:${i}`,label:i,condition:{column:e,op:`is`,value:i}}];case`file`:return[{key:`f:any`,label:``,condition:{column:e,op:`not-empty`}}];default:return[{key:`t:${i.toLocaleLowerCase()}`,label:i,condition:{column:e,op:`is`,value:i}}]}}function Lo(e,t){let n=t.value;if(t.op===`empty`)return`∅`;if(t.op===`not-empty`&&e.type===`file`)return`f:any`;switch(e.type){case`number`:return t.op===`=`&&typeof n==`number`?`n:${String(n)}`:void 0;case`date`:return t.op===`on`&&typeof n==`string`?`d:${n}`:void 0;case`checkbox`:return t.op===`is`&&typeof n==`boolean`?`b:${String(n)}`:void 0;case`multi-select`:return t.op===`has-any`&&Array.isArray(n)&&n.length===1?`m:${String(n[0])}`:void 0;case`select`:return t.op===`is`&&typeof n==`string`?`s:${n}`:void 0;case`file`:return;default:return t.op===`is`&&typeof n==`string`?`t:${n.trim().toLocaleLowerCase()}`:void 0}}function Ro(e,t,n,r){let i=new Map;for(let a of n)for(let n of Io(e,t,a,r)){let e=i.get(n.key);e?e.count++:i.set(n.key,{...n,count:1,raw:a.trim()})}let a=qa(t.type===`multi-select`?{type:`text`}:t);return[...i.values()].sort((e,n)=>e.key===`∅`?1:n.key===`∅`?-1:t.type===`multi-select`?e.label.localeCompare(n.label,r):a(e.raw,n.raw)).map(e=>{let t={...e};return delete t.raw,t})}var zo=e=>e===void 0?[]:`all`in e?e.all:[e];function Bo(e,t,n){if(!Ot(e)||!(`any`in e)||e.any.length===0)return;let r=new Set;for(let i of e.any){if(Ot(i)||i.column!==t)return;let e=Lo(n,i);if(e===void 0)return;r.add(e)}return r}function Vo(e,t,n){for(let r of zo(e.filter)){let e=Bo(r,t,n);if(e)return e}}function Ho(e,t,n,r){let i=zo(e.filter).filter(e=>Bo(e,t,n)===void 0),a=r===void 0?i:[...i,{any:r.map(e=>e.condition)}],o=Po(e);return a.length===0?o:{...o,filter:{all:a}}}function Uo(e){let t=new Set,n=e=>{Ot(e)?(`all`in e?e.all:e.any).forEach(n):t.add(e.column)};return zo(e.filter).forEach(n),t}var Wo=[`text`,`number`,`currency`,`percent`,`date`,`checkbox`,`list`,`file`];function Go(e){switch(e.type){case`text`:return`text`;case`number`:{let t=e.number?.style??`plain`;return t===`plain`?`number`:t}case`date`:return`date`;case`checkbox`:return`checkbox`;case`select`:return`list`;case`file`:return`file`;default:return}}function Ko(e,t,n){let r={type:t===`currency`||t===`percent`?`number`:t===`list`?`select`:t};if(t===`number`||t===`currency`||t===`percent`){let n=e.type===`number`?e.number:void 0,i=t===`number`?`plain`:t;(i!==`plain`||n!==void 0)&&(r.number={...n??{thousands:!0},style:i},i!==`currency`&&Reflect.deleteProperty(r.number,`currency`))}if(t===`date`&&e.date&&(r.date=e.date),t===`list`){let t=[...e.options??[]],i=new Set(t.map(e=>e.name));for(let r of n){let n=e.type===`multi-select`?Ia(r,e.separator):[r.trim()];for(let e of n)if(!(e===``||i.has(e))){if(t.length>=200)break;i.add(e),t.push({name:e})}}r.options=t}return t===`file`&&e.type===`file`&&(e.separator!==void 0&&(r.separator=e.separator),e.height!==void 0&&(r.height=e.height)),e.width!==void 0&&(r.width=e.width),e.wrap!==void 0&&(r.wrap=e.wrap),r}var qo=/\.(png|jpe?g|gif|webp|avif|svg)$/i;function Jo(e,t){return Ia(t,e.separator)}function Yo(e){return e.slice(e.lastIndexOf(`/`)+1)}function Xo(e,t,n){let r=n;for(let n of t){let t=W(e,n);t.type===`file`&&t.height!==void 0&&(r=Math.max(r,t.height+10))}return r}function Zo(e,t){let n=[];for(let r of t)Jo(e,r.value).forEach((e,t)=>{n.push({path:e,row:r.id,title:r.title,at:t})});return n}var Qo=400;function $o(e,t,n,r=`en`,i={}){let a=i.min??88,o=i.max??320,s={},c=e.rows.slice(0,Qo);return e.columns.forEach((e,i)=>{let l=W(t,e),u=n(e)+76+(t.key===e?18:0);for(let e of c){let t=e[i]??``;if(Ma(t))continue;let a;switch(l.type){case`checkbox`:a=40;break;case`select`:a=n(t.trim())+12+18;break;case`multi-select`:a=Ia(t,l.separator).reduce((e,t)=>e+n(t)+12+4,0)+18;break;case`url`:case`email`:case`phone`:a=n(t.trim())+18+18;break;case`file`:a=Ia(t,l.separator).reduce((e,t)=>e+4+(qo.test(t)?Math.round((l.height??24)*1.6):n(t.slice(t.lastIndexOf(`/`)+1))+29),0)+18;break;default:a=n(Ga(l,t,r))+18}if(a>u&&(u=a),u>=o)break}s[e]=Math.round(Math.min(o,Math.max(a,u)))}),s}function es({...e}){return(0,V.jsx)(st,{"data-slot":`popover`,...e})}function ts({...e}){return(0,V.jsx)(lt,{"data-slot":`popover-trigger`,...e})}function ns({className:e,align:t=`center`,sideOffset:n=4,...r}){return(0,V.jsx)(pt,{children:(0,V.jsx)(ht,{"data-slot":`popover-content`,align:t,sideOffset:n,className:k(`z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-hidden data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95`,e),...r})})}var rs=(e,t=2)=>String(e).padStart(t,`0`),is=(e,t,n)=>`${rs(e,4)}-${rs(t)}-${rs(n)}`;function as(e,t,n=0){let r=(new Date(Date.UTC(e,t-1,1)).getUTCDay()-n+7)%7,i=new Date(Date.UTC(e,t,0)).getUTCDate(),a=[],o=Math.ceil((r+i)/7)*7;for(let n=0;n<o;n++){let i=new Date(Date.UTC(e,t-1,1-r+n)),o={day:is(i.getUTCFullYear(),i.getUTCMonth()+1,i.getUTCDate()),inMonth:i.getUTCMonth()===t-1};n%7==0&&a.push([]),a[a.length-1]?.push(o)}return a}var os=new Set([`zh-cn`,`es`,`fr`,`de`,`it`,`ru`,`tr`,`vi`]);function ss(e){return+!!os.has(o(e))}function cs(e,t){let n=e.year*12+(e.month-1)+t;return{year:Math.floor(n/12),month:n%12+1}}function ls(e,t){let n=e.trim();return/^\d{4}-\d{2}-\d{2}/.test(n)&&Pa(n)!==void 0?`${t}${n.slice(10)}`:t}function us(e=new Date){return is(e.getFullYear(),e.getMonth()+1,e.getDate())}var ds=[`jan`,`feb`,`mar`,`apr`,`may`,`jun`,`jul`,`aug`,`sep`,`oct`,`nov`,`dec`],fs={today:0,tomorrow:1,yesterday:-1,今天:0,明天:1,昨天:-1};function ps(e,t){let n=new Date(Date.parse(`${e}T00:00:00Z`)+t*864e5);return is(n.getUTCFullYear(),n.getUTCMonth()+1,n.getUTCDate())}function ms(e){let t={...fs},n=new Set,r=new Intl.RelativeTimeFormat(e,{numeric:`auto`});for(let e of[-1,0,1]){let i=r.format(e,`day`).toLowerCase();i in t&&t[i]!==e?n.add(i):t[i]=e}for(let e of n)Reflect.deleteProperty(t,e);return t}function hs(e){let t=new Map;ds.forEach((e,n)=>t.set(e,n+1));for(let n of[`long`,`short`]){let r=new Intl.DateTimeFormat(e,{month:n,timeZone:`UTC`});for(let e=0;e<12;e++){let n=r.format(Date.UTC(2026,e,15)).toLowerCase().replace(/\.$/u,``);/^\d+$/u.test(n)||t.set(n,e+1)}}return t}function gs(e){let t=new Intl.DateTimeFormat(e,{timeZone:`UTC`}).formatToParts(Date.UTC(2026,9,14)).map(e=>e.type);return t.indexOf(`day`)<t.indexOf(`month`)}function _s(e,t,n=`en`){let r=e.trim();if(r===``)return;if(Pa(r)!==void 0)return r;let i=/\s+(\d{1,2}):(\d{2})$/.exec(r),a=i?r.slice(0,i.index):r,o=i?`T${(i[1]??``).padStart(2,`0`)}:${i[2]??``}`:``,s=(e,t,n)=>{let r=`${is(e,t,n)}${o}`;return Pa(r)===void 0?void 0:r},c=ms(n)[a.toLowerCase()];if(c!==void 0){let e=ps(t,c);return s(Number(e.slice(0,4)),Number(e.slice(5,7)),Number(e.slice(8,10)))}let l=/^(\d{4})[/.\-年](\d{1,2})[/.\-月](\d{1,2})日?$/.exec(a);if(l||(l=/^(\d{4})\s*년\s*(\d{1,2})\s*월\s*(\d{1,2})\s*일?$/u.exec(a),l))return s(Number(l[1]),Number(l[2]),Number(l[3]));if(l=/^(\d{1,2})[/.-](\d{1,2})[/.-](\d{4})$/.exec(a),l)return gs(n)?s(Number(l[3]),Number(l[2]),Number(l[1])):s(Number(l[3]),Number(l[1]),Number(l[2]));let u=hs(n),d=e=>{let t=(e??``).toLowerCase().replace(/\.$/u,``);return u.get(t)??u.get(t.slice(0,3))??0};if(l=/^(\p{L}+)\.?\s+(\d{1,2}),?\s+(\d{4})$/u.exec(a),l&&d(l[1])>0)return s(Number(l[3]),d(l[1]),Number(l[2]));if(l=/^(\d{1,2})\.?\s+(?:de\s+)?(\p{L}+)\.?,?\s+(?:de\s+)?(\d{4})$/u.exec(a),l&&d(l[2])>0)return s(Number(l[3]),d(l[2]),Number(l[1]))}var vs=8;function ys(e){let t=e.closest(`.sheet-grid`);if(!t)return new DOMRect(0,0,window.innerWidth,window.innerHeight);let n=t.getBoundingClientRect(),r=t.querySelector(`.sheet-footer`),i=r?r.getBoundingClientRect().top:n.bottom;return new DOMRect(n.left,n.top,n.width,i-n.top)}function bs(e,t,n=!0){(0,B.useLayoutEffect)(()=>{let t=e.current;if(!t||!n)return;t.style.transform=``;let r=t.getBoundingClientRect(),i=ys(t),a=0,o=0;if(r.right>i.right-vs&&(a=Math.max(i.left+vs-r.left,i.right-vs-r.right)),r.bottom>i.bottom-vs){let e=(t.closest(`.sheet-cell`)??t.parentElement)?.getBoundingClientRect(),n=e?r.height-e.height:r.height;o=r.top-n>=i.top+vs?-n:Math.max(i.top+vs-r.top,i.bottom-vs-r.bottom)}(a!==0||o!==0)&&(t.style.transform=`translate(${String(a)}px, ${String(o)}px)`)},[e,t,n])}function xs(){let e=t=>{window.removeEventListener(`pointerup`,e,!0),t.button===2&&(t.preventDefault(),t.stopPropagation())};window.addEventListener(`pointerup`,e,!0)}var Ss=e=>/^\d{4}-\d{2}-\d{2}[T ](\d{2}:\d{2})/.exec(e.trim())?.[1];function Cs(e,t){let n=e.trim(),r=n.slice(0,10),i=/(Z|[+-]\d{2}:?\d{2})$/.exec(n)?.[1]??``;return t===void 0?r:`${r}T${t}${i}`}function ws({value:e,initial:t,strings:n,onCommit:r,onCancel:i,inline:a,locale:o}){let s=us(),[c,l]=(0,B.useState)(t??e),[u,d]=(0,B.useState)(!1),f=_s(c,s,o),p=f?.slice(0,10),[m,h]=(0,B.useState)(()=>{let e=p??s;return{year:Number(e.slice(0,4)),month:Number(e.slice(5,7))}}),g=(0,B.useRef)(null),_=(0,B.useRef)(null);bs(g,u,!a),(0,B.useLayoutEffect)(()=>{let e=_.current;e&&(e.focus(),e.setSelectionRange(e.value.length,e.value.length))},[]);let y=ss(o),b=as(m.year,m.month,y),x=(0,B.useMemo)(()=>{let e=new Intl.DateTimeFormat(o??`en`,{weekday:`narrow`,timeZone:`UTC`});return(b[0]??[]).map(t=>e.format(Date.parse(`${t.day}T00:00:00Z`)))},[o,b]),S=new Intl.DateTimeFormat(o??`en`,{year:`numeric`,month:`long`,timeZone:`UTC`}).format(Date.UTC(m.year,m.month-1,1)),w=t=>ls(f??e,t),T=e=>{h({year:Number(e.slice(0,4)),month:Number(e.slice(5,7))})},E=e=>{c.trim()===``?r(``,e):f===void 0?(d(!0),_.current?.focus()):r(f,e)},ee=e=>{let t=w(ps(p??s,e));l(t),d(!1),T(t.slice(0,10))},te=e=>{e.nativeEvent.isComposing||(e.stopPropagation(),e.key===`Escape`?(e.preventDefault(),i()):e.key===`Enter`?(e.preventDefault(),E(e.shiftKey?`shift-enter`:`enter`)):e.key===`Tab`?(e.preventDefault(),E(e.shiftKey?`shift-tab`:`tab`)):e.key===`ArrowDown`||e.key===`ArrowUp`?(e.preventDefault(),ee((e.key===`ArrowDown`?1:-1)*(e.shiftKey?7:1))):(e.key===`PageDown`||e.key===`PageUp`)&&(e.preventDefault(),h(t=>cs(t,e.key===`PageDown`?1:-1))))},ne=f===void 0?void 0:Ss(f),D=e=>{e.preventDefault()};return(0,V.jsxs)(`div`,{ref:g,className:`sheet-editor sheet-date`,"data-inline":a?``:void 0,"data-wrong":u?``:void 0,"data-testid":`sheet-date-editor`,children:[(0,V.jsx)(`input`,{ref:_,className:`sheet-date-field`,value:c,placeholder:n.date.placeholder,"aria-label":n.types.date,"aria-invalid":u,spellCheck:!1,onChange:e=>{l(e.target.value),d(!1);let t=_s(e.target.value,s,o);t&&T(t.slice(0,10))},onKeyDown:te,onBlur:e=>{g.current?.contains(e.relatedTarget)||(c.trim()===``?r(``,`click`):f===void 0?i():r(f,`click`))}}),u&&(0,V.jsx)(`p`,{className:`sheet-editor-wrong`,role:`alert`,children:n.cell.notDate}),(0,V.jsxs)(`div`,{className:`sheet-date-month`,onMouseDown:D,children:[(0,V.jsx)(`span`,{className:`sheet-date-title`,children:S}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,tabIndex:-1,"aria-label":n.date.previousMonth,onClick:()=>{h(e=>cs(e,-1))},children:(0,V.jsx)(v,{size:14,"aria-hidden":!0})}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,tabIndex:-1,"aria-label":n.date.nextMonth,onClick:()=>{h(e=>cs(e,1))},children:(0,V.jsx)(Ce,{size:14,"aria-hidden":!0})})]}),(0,V.jsxs)(`div`,{className:`sheet-date-days`,role:`grid`,"aria-label":S,onMouseDown:D,children:[(0,V.jsx)(`div`,{className:`sheet-date-week`,role:`row`,children:x.map((e,t)=>(0,V.jsx)(`span`,{className:`sheet-date-weekday`,role:`columnheader`,children:e},t))}),b.map(e=>(0,V.jsx)(`div`,{className:`sheet-date-week`,role:`row`,children:e.map(e=>(0,V.jsx)(`button`,{type:`button`,role:`gridcell`,tabIndex:-1,className:`sheet-date-day`,"aria-selected":e.day===p,"data-out":e.inMonth?void 0:``,"data-today":e.day===s?``:void 0,"data-day":e.day,onClick:()=>{r(w(e.day),`click`)},children:Number(e.day.slice(8))},e.day))},e[0]?.day))]}),(0,V.jsxs)(`div`,{className:`sheet-date-foot`,onMouseDown:D,children:[(0,V.jsx)(`button`,{type:`button`,className:`sheet-date-action`,tabIndex:-1,onClick:()=>{r(w(s),`click`)},children:n.date.today}),f!==void 0&&(ne===void 0?(0,V.jsxs)(`button`,{type:`button`,className:`sheet-date-action`,tabIndex:-1,onClick:()=>{l(Cs(f,`09:00`))},children:[(0,V.jsx)(ze,{size:12,"aria-hidden":!0}),n.date.addTime]}):(0,V.jsxs)(`span`,{className:`sheet-date-time`,children:[(0,V.jsx)(ze,{size:12,"aria-hidden":!0}),(0,V.jsx)(`input`,{type:`time`,"aria-label":n.date.time,value:ne,onMouseDown:e=>{e.stopPropagation()},onChange:e=>{e.target.value!==``&&l(Cs(f,e.target.value))},onKeyDown:e=>{e.stopPropagation(),e.key===`Enter`?(e.preventDefault(),E(`enter`)):e.key===`Escape`&&(e.preventDefault(),i())}}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,tabIndex:-1,"aria-label":n.date.removeTime,onClick:()=>{l(Cs(f,void 0))},children:(0,V.jsx)(C,{size:12,"aria-hidden":!0})})]})),(0,V.jsx)(`button`,{type:`button`,className:`sheet-date-action`,"data-quiet":``,tabIndex:-1,onClick:()=>{r(``,`click`)},children:n.date.clear})]})]})}var Ts=c(m(),1),Es=350,Ds=320;function Os(e,t,n){return Xa(e,t).map(n)}function ks({path:e,height:t,dir:n,fileUrl:r,strings:i,onOpen:a}){let o=Os(n,e,r),[s,c]=(0,B.useState)(0),[l,u]=(0,B.useState)(),d=(0,B.useRef)(void 0),f=(0,B.useRef)(null),p=o[s];return(0,B.useEffect)(()=>()=>{window.clearTimeout(d.current)},[]),p===null?(0,V.jsx)(`span`,{className:`sheet-pic`,style:{height:t},"aria-hidden":!0}):p===void 0?(0,V.jsxs)(`span`,{className:`sheet-pic`,"data-missing":``,style:{height:t},title:`${e}: ${i.files.notFound}`,children:[(0,V.jsx)(We,{size:Math.min(14,t-6),"aria-hidden":!0}),t>=40&&(0,V.jsx)(`span`,{children:i.files.notFound})]}):(0,V.jsxs)(`button`,{ref:f,type:`button`,className:`sheet-pic`,style:{height:t},title:Yo(e),"aria-label":Yo(e),tabIndex:-1,onClick:e=>{e.stopPropagation(),window.clearTimeout(d.current),u(void 0),a?.()},onPointerEnter:()=>{t>=Ds/2||(window.clearTimeout(d.current),d.current=window.setTimeout(()=>{let e=f.current?.getBoundingClientRect();e&&u(e)},Es))},onPointerLeave:()=>{window.clearTimeout(d.current),u(void 0)},children:[(0,V.jsx)(`img`,{src:p,alt:``,loading:`lazy`,draggable:!1,onError:()=>{c(e=>e+1)}}),l&&(0,Ts.createPortal)((0,V.jsx)(`span`,{className:`sheet-pic-preview`,role:`presentation`,style:As(l),children:(0,V.jsx)(`img`,{src:p,alt:``})}),document.body)]})}function As(e){let t=Math.max(8,Math.min(e.left,window.innerWidth-344));return window.innerHeight-e.bottom>344?{left:t,top:e.bottom+6}:{left:t,bottom:window.innerHeight-e.top+6}}function js({column:e,value:t,strings:n,dir:r,fileUrl:i,height:a,onOpen:o}){let s=Jo(e,t),c=a??e.height??24,l=s.length===1,u=(0,B.useRef)(null),[d,f]=(0,B.useState)(0);return(0,B.useLayoutEffect)(()=>{let e=u.current;if(!e)return;let t=new ResizeObserver(()=>{let t=0;for(let n of e.children){let r=n;r.dataset.more===void 0&&r.offsetLeft+r.offsetWidth>e.clientWidth+1&&t++}f(t)});t.observe(e);for(let n of e.children)t.observe(n);return()=>{t.disconnect()}},[t,c]),(0,V.jsxs)(`span`,{ref:u,className:`sheet-files`,title:s.join(`
|
|
130
|
-
`),children:[s.map((e,t)=>qo.test(e)&&i?(0,V.jsx)(ks,{path:e,height:c,dir:r??``,fileUrl:i,strings:n,...o?{onOpen:()=>{o(t)}}:{}},`${e}-${String(t)}`):(0,V.jsxs)(`span`,{className:`sheet-file`,"data-only":l?``:void 0,children:[(0,V.jsx)(_e,{size:13,"aria-hidden":!0}),(0,V.jsx)(`span`,{className:`sheet-file-name`,children:Yo(e)})]},`${e}-${String(t)}`)),d>0&&(0,V.jsxs)(`span`,{className:`sheet-files-more`,"data-more":``,children:[`+`,d]})]})}function Ms({files:e,at:t,dir:n,fileUrl:r,strings:i,readOnly:a,onStep:o,onRemove:s,onClose:c}){let l=e[t],[u,d]=(0,B.useState)(0),[f,p]=(0,B.useState)(t);if(f!==t&&(p(t),d(0)),!l)return null;let m=Os(n,l.path,r)[u],h=qo.test(l.path),g=n=>{e.length>1&&o((t+n+e.length)%e.length)};return(0,V.jsx)(Ee,{open:!0,onOpenChange:e=>{e||c()},children:(0,V.jsxs)(fe,{className:`sheet-viewer`,showCloseButton:!1,"data-testid":`sheet-viewer`,tabIndex:-1,onOpenAutoFocus:e=>{e.preventDefault(),e.currentTarget?.focus()},onKeyDown:e=>{e.key===`ArrowLeft`?(e.preventDefault(),g(-1)):e.key===`ArrowRight`&&(e.preventDefault(),g(1))},children:[(0,V.jsxs)(`header`,{className:`sheet-viewer-bar`,children:[(0,V.jsxs)(`span`,{className:`sheet-viewer-names`,children:[(0,V.jsx)(A,{className:`sheet-viewer-name`,children:Yo(l.path)}),(0,V.jsxs)(`span`,{className:`sheet-viewer-row`,children:[l.title,e.length>1&&(0,V.jsx)(`span`,{className:`sheet-viewer-count`,children:i.files.of(t+1,e.length)})]})]}),typeof m==`string`&&(0,V.jsxs)(`a`,{className:`sheet-viewer-action`,href:m,target:`_blank`,rel:`noreferrer noopener`,children:[(0,V.jsx)(Ve,{size:14,"aria-hidden":!0}),i.files.open]}),!a&&(0,V.jsx)(`button`,{type:`button`,className:`sheet-viewer-action`,"data-testid":`sheet-viewer-remove`,onClick:()=>{s(l)},children:i.files.remove}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":i.files.close,title:i.files.close,onClick:c,children:(0,V.jsx)(C,{size:16,"aria-hidden":!0})})]}),(0,V.jsxs)(`div`,{className:`sheet-viewer-stage`,children:[e.length>1&&(0,V.jsx)(`button`,{type:`button`,className:`sheet-viewer-step`,"data-side":`left`,"aria-label":i.files.previous,title:i.files.previous,onClick:()=>{g(-1)},children:(0,V.jsx)(v,{size:20,"aria-hidden":!0})}),m===null?null:h&&m!==void 0?(0,V.jsx)(`img`,{className:`sheet-viewer-picture`,src:m,alt:Yo(l.path),onError:()=>{d(e=>e+1)}}):(0,V.jsxs)(`span`,{className:`sheet-viewer-file`,"data-missing":m===void 0?``:void 0,children:[m===void 0?(0,V.jsx)(We,{size:40,"aria-hidden":!0}):(0,V.jsx)(_e,{size:40,"aria-hidden":!0}),(0,V.jsx)(`span`,{children:m===void 0?i.files.notFound:l.path})]}),e.length>1&&(0,V.jsx)(`button`,{type:`button`,className:`sheet-viewer-step`,"data-side":`right`,"aria-label":i.files.next,title:i.files.next,onClick:()=>{g(1)},children:(0,V.jsx)(Ce,{size:20,"aria-hidden":!0})})]})]})})}function Ns({name:e,option:t}){return(0,V.jsx)(`span`,{className:`sheet-chip`,"data-color":t?.color??`gray`,"data-unknown":t?void 0:``,children:e})}function Ps({column:e,value:t,locale:n,strings:r,fileUrl:i,dir:a,height:o,onToggle:s,onOpen:c}){if(Ma(t))return e.type===`checkbox`?(0,V.jsx)(`button`,{type:`button`,className:`sheet-check`,"aria-checked":!1,role:`checkbox`,tabIndex:-1,onMouseDown:e=>{e.stopPropagation()},onClick:s}):null;let l=Ra(e,t);if(l!==void 0)return(0,V.jsx)(`span`,{className:`sheet-value`,"data-wrong":``,title:`“${t}” ${l}`,children:t});switch(e.type){case`checkbox`:{let e=Fa(t)===!0;return(0,V.jsx)(`button`,{type:`button`,className:`sheet-check`,role:`checkbox`,"aria-checked":e,tabIndex:-1,onMouseDown:e=>{e.stopPropagation()},onClick:s,children:e&&(0,V.jsx)(g,{size:12,strokeWidth:3,"aria-hidden":!0})})}case`select`:{let n=e.options?.find(e=>e.name===t.trim());return(0,V.jsx)(Ns,{name:t.trim(),...n?{option:n}:{}})}case`multi-select`:return(0,V.jsx)(`span`,{className:`sheet-chips`,children:Ia(t,e.separator).map((t,n)=>{let r=e.options?.find(e=>e.name===t);return(0,V.jsx)(Ns,{name:t,...r?{option:r}:{}},`${t}-${String(n)}`)})});case`url`:case`email`:case`phone`:{let n=za(e,t);return(0,V.jsxs)(`span`,{className:`sheet-link`,children:[(0,V.jsx)(`span`,{className:`sheet-link-text`,children:t}),n&&(0,V.jsx)(`a`,{className:`sheet-link-open`,href:n,target:`_blank`,rel:`noreferrer noopener`,title:r.cell.open,"aria-label":r.cell.open,onMouseDown:e=>{e.stopPropagation()},children:(0,V.jsx)(Ve,{size:12,"aria-hidden":!0})})]})}case`file`:return(0,V.jsx)(js,{column:e,value:t,strings:r,...a===void 0?{}:{dir:a},...i?{fileUrl:i}:{},...o===void 0?{}:{height:o},...c?{onOpen:c}:{}});default:return(0,V.jsx)(`span`,{className:`sheet-value`,children:Ga(e,t,n)})}}function Fs(e,t,n){if(!Ma(t))switch(e.type){case`number`:return Na(t)===void 0?n.cell.notNumber:void 0;case`date`:return Pa(t)===void 0?n.cell.notDate:void 0;case`email`:return Ra(e,t)===void 0?void 0:n.cell.notEmail;case`url`:return Ra(e,t)===void 0?void 0:n.cell.notUrl;default:return}}function Is(e){let{column:t}=e;return t.type===`select`||t.type===`multi-select`?(0,V.jsx)(Rs,{...e}):t.type===`date`?(0,V.jsx)(ws,{...e}):(0,V.jsx)(Ls,{...e})}function Ls({column:e,value:t,initial:n,strings:r,onCommit:i,onCancel:a,inline:o}){let[s,c]=(0,B.useState)(n??t),[l,u]=(0,B.useState)(),d=(0,B.useRef)(null),f=(0,B.useRef)(null),p=e.type===`text`;bs(f,l,!o),(0,B.useLayoutEffect)(()=>{let e=d.current;if(!e)return;e.focus();let t=e.value.length;e.setSelectionRange(t,t)},[]),(0,B.useLayoutEffect)(()=>{let e=d.current;e&&p&&(e.style.height=`auto`,e.style.height=`${String(e.scrollHeight)}px`)},[s,p]);let m=t=>{let n=e.type===`text`?s:s.trim(),a=Fs(e,n,r);a===void 0?i(n,t):(u(a),d.current?.focus())},h=e=>{e.nativeEvent.isComposing||(e.key===`Escape`?(e.preventDefault(),e.stopPropagation(),a()):e.key===`Enter`&&!(p&&(e.shiftKey||e.altKey))?(e.preventDefault(),e.stopPropagation(),m(e.shiftKey?`shift-enter`:`enter`)):e.key===`Tab`?(e.preventDefault(),e.stopPropagation(),m(e.shiftKey?`shift-tab`:`tab`)):e.stopPropagation())},g=e.type===`number`?`1234.5`:void 0;return(0,V.jsxs)(`div`,{ref:f,className:`sheet-editor`,"data-inline":o?``:void 0,"data-wrong":l?``:void 0,children:[(0,V.jsx)(`textarea`,{ref:d,className:`sheet-editor-input`,"data-type":e.type,rows:1,value:s,spellCheck:e.type===`text`,...g?{placeholder:g}:{},onChange:e=>{c(e.target.value),u(void 0)},onKeyDown:h,onBlur:t=>{if(o||f.current?.contains(t.relatedTarget))return;let n=e.type===`text`?s:s.trim();Fs(e,n,r)===void 0?i(n,`click`):a()},"aria-invalid":l!==void 0}),l&&(0,V.jsx)(`p`,{className:`sheet-editor-wrong`,role:`alert`,children:l})]})}function Rs({column:e,value:t,initial:n,strings:r,onCommit:i,onCancel:a,onAddOption:o,inline:s}){let c=e.type===`multi-select`,l=(0,B.useMemo)(()=>e.options??[],[e.options]),[u,d]=(0,B.useState)(()=>c?Ia(t,e.separator):t.trim()===``?[]:[t.trim()]),[f,p]=(0,B.useState)(n??``),[m,h]=(0,B.useState)(0),_=(0,B.useRef)(null),v=(0,B.useRef)(null);(0,B.useEffect)(()=>{_.current?.focus()},[]);let y=f.trim().toLowerCase(),b=l.filter(e=>e.name.toLowerCase().includes(y)),x=l.some(e=>e.name.toLowerCase()===y),S=y!==``&&!x&&o!==void 0&&!f.includes(e.separator??`;`),w=b.length+ +!!S;bs(v,w,!s);let T=(t,n)=>{i(c?La(t,e.separator):t[0]??``,n)},E=(e,t)=>{if(c){let t=u.includes(e)?u.filter(t=>t!==e):[...u,e];d(t),p(``),s&&T(t,`click`)}else T([e],t)},ee=e=>{let t=f.trim();o?.(t),E(t,e)};return(0,V.jsxs)(`div`,{ref:v,className:`sheet-editor sheet-options`,"data-inline":s?``:void 0,children:[(0,V.jsxs)(`div`,{className:`sheet-options-field`,children:[u.map(e=>{let t=l.find(t=>t.name===e);return(0,V.jsxs)(`span`,{className:`sheet-options-chosen`,children:[(0,V.jsx)(Ns,{name:e,...t?{option:t}:{}}),(0,V.jsx)(`button`,{type:`button`,tabIndex:-1,"aria-label":`${r.cell.clear} ${e}`,onMouseDown:e=>{e.preventDefault()},onClick:()=>{let t=u.filter(t=>t!==e);d(t),(!c||s)&&T(t,`click`)},children:(0,V.jsx)(C,{size:11,"aria-hidden":!0})})]},e)}),(0,V.jsx)(`input`,{ref:_,className:`sheet-options-input`,value:f,placeholder:u.length===0?r.column.addOption:``,onChange:e=>{p(e.target.value),h(0)},onKeyDown:n=>{if(!n.nativeEvent.isComposing){if(n.stopPropagation(),n.key===`Escape`)n.preventDefault(),c&&u.join(`\0`)!==Ia(t,e.separator).join(`\0`)?T(u,`click`):a();else if(n.key===`ArrowDown`)n.preventDefault(),h(e=>Math.min(w-1,e+1));else if(n.key===`ArrowUp`)n.preventDefault(),h(e=>Math.max(0,e-1));else if(n.key===`Enter`){if(n.preventDefault(),y===``&&c){T(u,n.shiftKey?`shift-enter`:`enter`);return}let e=b[m];e?E(e.name,n.shiftKey?`shift-enter`:`enter`):S?ee(n.shiftKey?`shift-enter`:`enter`):y===``&&!c&&T([],`enter`)}else n.key===`Tab`?(n.preventDefault(),T(u,n.shiftKey?`shift-tab`:`tab`)):n.key===`Backspace`&&f===``&&u.length>0&&(n.preventDefault(),d(u.slice(0,-1)))}},onBlur:()=>{!s&&c?T(u,`click`):s||a()}})]}),(0,V.jsxs)(`ul`,{className:`sheet-options-list`,role:`listbox`,"aria-multiselectable":c,children:[b.map((e,t)=>(0,V.jsxs)(`li`,{role:`option`,"aria-selected":u.includes(e.name),"data-active":t===m?``:void 0,onMouseDown:e=>{e.preventDefault()},onMouseEnter:()=>{h(t)},onClick:()=>{E(e.name,`click`)},children:[(0,V.jsx)(Ns,{name:e.name,option:e}),u.includes(e.name)&&(0,V.jsx)(g,{size:13,"aria-hidden":!0,className:`sheet-options-tick`})]},e.name)),S&&(0,V.jsxs)(`li`,{role:`option`,"aria-selected":!1,"data-active":m===b.length?``:void 0,onMouseDown:e=>{e.preventDefault()},onClick:()=>{ee(`click`)},children:[(0,V.jsx)(Se,{size:13,"aria-hidden":!0}),(0,V.jsx)(`span`,{children:r.column.newOption(f.trim())})]})]})]})}function zs({column:e,canHide:t,strings:n,actions:r,open:i,onOpenChange:a}){let o=n.column,s=Go(e);return(0,V.jsxs)(Te,{modal:!1,open:i,onOpenChange:a,children:[(0,V.jsx)(be,{asChild:!0,children:(0,V.jsx)(`span`,{className:`sheet-head-anchor`,"aria-hidden":!0})}),(0,V.jsxs)(xe,{align:`start`,className:`sheet-menu`,"data-testid":`sheet-column-menu`,onCloseAutoFocus:e=>{e.preventDefault()},children:[(0,V.jsxs)(N,{onSelect:r.rename,children:[(0,V.jsx)(Je,{"aria-hidden":!0}),o.rename]}),(0,V.jsxs)(j,{children:[(0,V.jsxs)(de,{"data-testid":`sheet-format`,children:[(0,V.jsx)(R,{"aria-hidden":!0}),o.format]}),(0,V.jsxs)(P,{className:`sheet-menu`,children:[s===void 0&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(N,{disabled:!0,className:`sheet-menu-note`,children:[(0,V.jsx)(g,{"aria-hidden":!0}),n.types[e.type]]}),(0,V.jsx)(ge,{})]}),Wo.map(e=>(0,V.jsxs)(N,{"data-testid":`sheet-format-${e}`,onSelect:()=>{e!==s&&r.format(e)},children:[e===s?(0,V.jsx)(g,{"aria-hidden":!0}):(0,V.jsx)(`span`,{className:`sheet-menu-blank`,"aria-hidden":!0}),o.formats[e]]},e))]})]}),(0,V.jsx)(ge,{}),(0,V.jsxs)(N,{onSelect:()=>{r.insert(`left`)},children:[(0,V.jsx)(je,{"aria-hidden":!0}),o.insertLeft]}),(0,V.jsxs)(N,{onSelect:()=>{r.insert(`right`)},children:[(0,V.jsx)(Me,{"aria-hidden":!0}),o.insertRight]}),t&&(0,V.jsxs)(N,{onSelect:r.hide,children:[(0,V.jsx)(F,{"aria-hidden":!0}),o.hide]}),(0,V.jsx)(ge,{}),(0,V.jsxs)(N,{variant:`destructive`,onSelect:r.remove,children:[(0,V.jsx)(b,{"aria-hidden":!0}),o.remove]})]})]})}function Bs(e,t){let n=t.auto;return e.key===`∅`?n.blanks:e.key===`b:true`?n.checked:e.key===`b:false`?n.unchecked:e.key===`f:any`?n.hasFile:e.label}function Vs(e,t){let n=e.options?.find(e=>e.name===t);return n?{option:n}:{}}var Hs=1e3;function Us({name:e,column:t,values:n,ticked:r,sort:i,strings:a,locale:o,trigger:s,onSort:c,onTicked:l}){let u=a.auto,[d,f]=(0,B.useState)(!1),[p,m]=(0,B.useState)([]),[h,g]=(0,B.useState)(new Set),[_,v]=(0,B.useState)(``),y=t.type===`number`?`number`:t.type===`date`?`date`:t.type===`select`||t.type===`multi-select`?`options`:`text`,b=y===`options`,x=(0,B.useMemo)(()=>{let e=_.trim().toLocaleLowerCase(o);return e===``?p:p.filter(t=>Bs(t,a).toLocaleLowerCase(o).includes(e))},[p,_,a,o]),S=x.length>0&&x.every(e=>h.has(e.key)),C=x.some(e=>h.has(e.key)),w=()=>{f(!1)};return(0,V.jsxs)(es,{open:d,onOpenChange:e=>{if(e){let e=n();m(e),g(new Set(r??e.map(e=>e.key))),v(``)}f(e)},children:[(0,V.jsx)(ts,{asChild:!0,children:s}),(0,V.jsxs)(ns,{align:`start`,className:`sheet-pop sheet-autofilter`,"data-testid":`sheet-autofilter`,"aria-label":u.button(e),onKeyDown:e=>{e.stopPropagation()},children:[(0,V.jsxs)(`button`,{type:`button`,className:`sheet-auto-sort`,"data-on":i===`asc`?``:void 0,"data-testid":`sheet-sort-asc`,onClick:()=>{c(!1),w()},children:[(0,V.jsx)(Ne,{size:14,"aria-hidden":!0}),u.sortAsc[y]]}),(0,V.jsxs)(`button`,{type:`button`,className:`sheet-auto-sort`,"data-on":i===`desc`?``:void 0,"data-testid":`sheet-sort-desc`,onClick:()=>{c(!0),w()},children:[(0,V.jsx)(ke,{size:14,"aria-hidden":!0}),u.sortDesc[y]]}),(0,V.jsx)(`div`,{className:`sheet-auto-rule`,role:`separator`}),(0,V.jsxs)(`label`,{className:`sheet-auto-search`,children:[(0,V.jsx)(Qe,{size:13,"aria-hidden":!0}),(0,V.jsx)(`input`,{value:_,placeholder:u.search,"aria-label":u.search,"data-testid":`sheet-autofilter-search`,onChange:e=>{v(e.target.value)}})]}),(0,V.jsxs)(`div`,{className:`sheet-auto-list`,role:`group`,"aria-label":e,children:[x.length>0&&(0,V.jsxs)(`label`,{className:`sheet-auto-row`,"data-all":``,children:[(0,V.jsx)(`input`,{type:`checkbox`,checked:S,ref:e=>{e&&(e.indeterminate=!S&&C)},onChange:()=>{g(e=>{let t=new Set(e);for(let e of x)S?t.delete(e.key):t.add(e.key);return t})}}),(0,V.jsx)(`span`,{className:`sheet-auto-label`,children:_.trim()===``?u.selectAll:u.selectFound})]}),x.slice(0,Hs).map(e=>(0,V.jsxs)(`label`,{className:`sheet-auto-row`,children:[(0,V.jsx)(`input`,{type:`checkbox`,checked:h.has(e.key),onChange:()=>{g(t=>{let n=new Set(t);return n.has(e.key)?n.delete(e.key):n.add(e.key),n})}}),(0,V.jsx)(`span`,{className:`sheet-auto-label`,"data-quiet":e.key===`∅`?``:void 0,children:b&&e.key!==`∅`?(0,V.jsx)(Ns,{name:e.label,...Vs(t,e.label)}):Bs(e,a)}),(0,V.jsx)(`span`,{className:`sheet-auto-count`,children:e.count})]},e.key)),x.length>Hs&&(0,V.jsx)(`p`,{className:`sheet-auto-more`,children:u.more(x.length-Hs)}),x.length===0&&(0,V.jsx)(`p`,{className:`sheet-auto-more`,children:u.none})]}),(0,V.jsxs)(`div`,{className:`sheet-auto-foot`,children:[r!==void 0&&(0,V.jsx)(he,{variant:`ghost`,size:`xs`,"data-testid":`sheet-autofilter-clear`,onClick:()=>{l(void 0),w()},children:u.clear}),(0,V.jsx)(`span`,{className:`sheet-auto-gap`}),(0,V.jsx)(he,{variant:`ghost`,size:`xs`,onClick:w,children:a.column.cancel}),(0,V.jsx)(he,{size:`xs`,"data-testid":`sheet-autofilter-ok`,disabled:h.size===0,onClick:()=>{let e=p.filter(e=>h.has(e.key));l(e.length===p.length?void 0:e),w()},children:u.ok})]})]})]})}function Ws(e,t,n){let r=n.initialDeps??[],i;function a(){var a;let o;n.key&&n.debug?.call(n)&&(o=Date.now());let s=e();if(!(s.length!==r.length||s.some((e,t)=>r[t]!==e)))return i;r=s;let c;if(n.key&&n.debug?.call(n)&&(c=Date.now()),i=t(...s),n.key&&n.debug?.call(n)){let e=Math.round((Date.now()-o)*100)/100,t=Math.round((Date.now()-c)*100)/100,r=t/16,i=(e,t)=>{for(e=String(e);e.length<t;)e=` `+e;return e};console.info(`%c⏱ ${i(t,5)} /${i(e,5)} ms`,`
|
|
131
|
-
font-size: .6rem;
|
|
132
|
-
font-weight: bold;
|
|
133
|
-
color: hsl(${Math.max(0,Math.min(120-120*r,120))}deg 100% 31%);`,n?.key)}return(a=n?.onChange)==null||a.call(n,i),i}return a.updateDeps=e=>{r=e},a}function Gs(e,t){if(e===void 0)throw Error(`Unexpected undefined${t?`: ${t}`:``}`);return e}var Ks=(e,t)=>Math.abs(e-t)<1.01,qs=(e,t,n)=>{let r;return function(...i){e.clearTimeout(r),r=e.setTimeout(()=>t.apply(this,i),n)}},Js=e=>{let{offsetWidth:t,offsetHeight:n}=e;return{width:t,height:n}},Ys=e=>e,Xs=e=>{let t=Math.max(e.startIndex-e.overscan,0),n=Math.min(e.endIndex+e.overscan,e.count-1),r=[];for(let e=t;e<=n;e++)r.push(e);return r},Zs=(e,t)=>{let n=e.scrollElement;if(!n)return;let r=e.targetWindow;if(!r)return;let i=e=>{let{width:n,height:r}=e;t({width:Math.round(n),height:Math.round(r)})};if(i(Js(n)),!r.ResizeObserver)return()=>{};let a=new r.ResizeObserver(t=>{let r=()=>{let e=t[0];if(e?.borderBoxSize){let t=e.borderBoxSize[0];if(t){i({width:t.inlineSize,height:t.blockSize});return}}i(Js(n))};e.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(r):r()});return a.observe(n,{box:`border-box`}),()=>{a.unobserve(n)}},Qs={passive:!0},$s=typeof window>`u`||`onscrollend`in window,ec=(e,t)=>{let n=e.scrollElement;if(!n)return;let r=e.targetWindow;if(!r)return;let i=0,a=e.options.useScrollendEvent&&$s?()=>void 0:qs(r,()=>{t(i,!1)},e.options.isScrollingResetDelay),o=r=>()=>{let{horizontal:o,isRtl:s}=e.options;i=o?n.scrollLeft*(s&&-1||1):n.scrollTop,a(),t(i,r)},s=o(!0),c=o(!1);c(),n.addEventListener(`scroll`,s,Qs);let l=e.options.useScrollendEvent&&$s;return l&&n.addEventListener(`scrollend`,c,Qs),()=>{n.removeEventListener(`scroll`,s),l&&n.removeEventListener(`scrollend`,c)}},tc=(e,t,n)=>{if(t?.borderBoxSize){let e=t.borderBoxSize[0];if(e)return Math.round(e[n.options.horizontal?`inlineSize`:`blockSize`])}return e[n.options.horizontal?`offsetWidth`:`offsetHeight`]},nc=(e,{adjustments:t=0,behavior:n},r)=>{var i,a;let o=e+t;(a=(i=r.scrollElement)?.scrollTo)==null||a.call(i,{[r.options.horizontal?`left`:`top`]:o,behavior:n})},rc=class{constructor(e){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let e=null,t=()=>e||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:e=new this.targetWindow.ResizeObserver(e=>{e.forEach(e=>{let t=()=>{this._measureElement(e.target,e)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(t):t()})}));return{disconnect:()=>{var n;(n=t())==null||n.disconnect(),e=null},observe:e=>t()?.observe(e,{box:`border-box`}),unobserve:e=>t()?.unobserve(e)}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach(([t,n])=>{n===void 0&&delete e[t]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:Ys,rangeExtractor:Xs,onChange:()=>{},measureElement:tc,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:`data-index`,initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...e}},this.notify=e=>{var t,n;(n=(t=this.options).onChange)==null||n.call(t,this,e)},this.maybeNotify=Ws(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),e=>{this.notify(e)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(e=>e()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{let e=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==e){if(this.cleanup(),!e){this.maybeNotify();return}this.scrollElement=e,this.targetWindow=this.scrollElement&&`ownerDocument`in this.scrollElement?this.scrollElement.ownerDocument.defaultView:this.scrollElement?.window??null,this.elementsCache.forEach(e=>{this.observer.observe(e)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,e=>{this.scrollRect=e,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(e,t)=>{this.scrollAdjustments=0,this.scrollDirection=t?this.getScrollOffset()<e?`forward`:`backward`:null,this.scrollOffset=e,this.isScrolling=t,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?`width`:`height`]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset==`function`?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(e,t)=>{let n=new Map,r=new Map;for(let i=t-1;i>=0;i--){let t=e[i];if(n.has(t.lane))continue;let a=r.get(t.lane);if(a==null||t.end>a.end?r.set(t.lane,t):t.end<a.end&&n.set(t.lane,!0),n.size===this.options.lanes)break}return r.size===this.options.lanes?Array.from(r.values()).sort((e,t)=>e.end===t.end?e.index-t.index:e.end-t.end)[0]:void 0},this.getMeasurementOptions=Ws(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(e,t,n,r,i)=>(this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:t,scrollMargin:n,getItemKey:r,enabled:i}),{key:!1}),this.getMeasurements=Ws(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:e,paddingStart:t,scrollMargin:n,getItemKey:r,enabled:i},a)=>{if(!i)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(e=>{this.itemSizeCache.set(e.key,e.size)}));let o=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];let s=this.measurementsCache.slice(0,o);for(let i=o;i<e;i++){let e=r(i),o=this.options.lanes===1?s[i-1]:this.getFurthestMeasurement(s,i),c=o?o.end+this.options.gap:t+n,l=a.get(e),u=typeof l==`number`?l:this.options.estimateSize(i),d=c+u,f=o?o.lane:i%this.options.lanes;s[i]={index:i,start:c,size:u,end:d,key:e,lane:f}}return this.measurementsCache=s,s},{key:!1,debug:()=>this.options.debug}),this.calculateRange=Ws(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(e,t,n,r)=>this.range=e.length>0&&t>0?ac({measurements:e,outerSize:t,scrollOffset:n,lanes:r}):null,{key:!1,debug:()=>this.options.debug}),this.getVirtualIndexes=Ws(()=>{let e=null,t=null,n=this.calculateRange();return n&&(e=n.startIndex,t=n.endIndex),this.maybeNotify.updateDeps([this.isScrolling,e,t]),[this.options.rangeExtractor,this.options.overscan,this.options.count,e,t]},(e,t,n,r,i)=>r===null||i===null?[]:e({startIndex:r,endIndex:i,overscan:t,count:n}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{let t=this.options.indexAttribute,n=e.getAttribute(t);return n?parseInt(n,10):(console.warn(`Missing attribute name '${t}={index}' on measured element.`),-1)},this._measureElement=(e,t)=>{let n=this.indexFromElement(e),r=this.measurementsCache[n];if(!r)return;let i=r.key,a=this.elementsCache.get(i);a!==e&&(a&&this.observer.unobserve(a),this.observer.observe(e),this.elementsCache.set(i,e)),e.isConnected&&this.resizeItem(n,this.options.measureElement(e,t,this))},this.resizeItem=(e,t)=>{let n=this.measurementsCache[e];if(!n)return;let r=t-(this.itemSizeCache.get(n.key)??n.size);r!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange===void 0?n.start<this.getScrollOffset()+this.scrollAdjustments:this.shouldAdjustScrollPositionOnItemSizeChange(n,r,this))&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=r,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(n.index),this.itemSizeCache=new Map(this.itemSizeCache.set(n.key,t)),this.notify(!1))},this.measureElement=e=>{e?this._measureElement(e,void 0):this.elementsCache.forEach((e,t)=>{e.isConnected||(this.observer.unobserve(e),this.elementsCache.delete(t))})},this.getVirtualItems=Ws(()=>[this.getVirtualIndexes(),this.getMeasurements()],(e,t)=>{let n=[];for(let r=0,i=e.length;r<i;r++){let i=t[e[r]];n.push(i)}return n},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=e=>{let t=this.getMeasurements();if(t.length!==0)return Gs(t[ic(0,t.length-1,e=>Gs(t[e]).start,e)])},this.getOffsetForAlignment=(e,t,n=0)=>{let r=this.getSize(),i=this.getScrollOffset();t===`auto`&&(t=e>=i+r?`end`:`start`),t===`center`?e+=(n-r)/2:t===`end`&&(e-=r);let a=this.getTotalSize()+this.options.scrollMargin-r;return Math.max(Math.min(a,e),0)},this.getOffsetForIndex=(e,t=`auto`)=>{e=Math.max(0,Math.min(e,this.options.count-1));let n=this.measurementsCache[e];if(!n)return;let r=this.getSize(),i=this.getScrollOffset();if(t===`auto`){if(n.end>=i+r-this.options.scrollPaddingEnd)t=`end`;else if(n.start<=i+this.options.scrollPaddingStart)t=`start`;else return[i,t]}let a=t===`end`?n.end+this.options.scrollPaddingEnd:n.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(a,t,n.size),t]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(e,{align:t=`start`,behavior:n}={})=>{n===`smooth`&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(e,t),{adjustments:void 0,behavior:n})},this.scrollToIndex=(e,{align:t=`auto`,behavior:n}={})=>{n===`smooth`&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),e=Math.max(0,Math.min(e,this.options.count-1));let r=0,i=t=>{if(!this.targetWindow)return;let r=this.getOffsetForIndex(e,t);if(!r){console.warn(`Failed to get offset for index:`,e);return}let[i,o]=r;this._scrollToOffset(i,{adjustments:void 0,behavior:n}),this.targetWindow.requestAnimationFrame(()=>{let t=this.getScrollOffset(),n=this.getOffsetForIndex(e,o);n?Ks(n[0],t)||a(o):console.warn(`Failed to get offset for index:`,e)})},a=t=>{this.targetWindow&&(r++,r<10?this.targetWindow.requestAnimationFrame(()=>i(t)):console.warn(`Failed to scroll to index ${e} after 10 attempts.`))};i(t)},this.scrollBy=(e,{behavior:t}={})=>{t===`smooth`&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+e,{adjustments:void 0,behavior:t})},this.getTotalSize=()=>{let e=this.getMeasurements(),t;if(e.length===0)t=this.options.paddingStart;else if(this.options.lanes===1)t=e[e.length-1]?.end??0;else{let n=Array(this.options.lanes).fill(null),r=e.length-1;for(;r>=0&&n.some(e=>e===null);){let t=e[r];n[t.lane]===null&&(n[t.lane]=t.end),r--}t=Math.max(...n.filter(e=>e!==null))}return Math.max(t-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(e,{adjustments:t,behavior:n})=>{this.options.scrollToFn(e,{behavior:n,adjustments:t},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(e)}},ic=(e,t,n,r)=>{for(;e<=t;){let i=(e+t)/2|0,a=n(i);if(a<r)e=i+1;else if(a>r)t=i-1;else return i}return e>0?e-1:0};function ac({measurements:e,outerSize:t,scrollOffset:n,lanes:r}){let i=e.length-1,a=t=>e[t].start;if(e.length<=r)return{startIndex:0,endIndex:i};let o=ic(0,i,a,n),s=o;if(r===1)for(;s<i&&e[s].end<n+t;)s++;else if(r>1){let a=Array(r).fill(0);for(;s<i&&a.some(e=>e<n+t);){let t=e[s];a[t.lane]=t.end,s++}let c=Array(r).fill(n+t);for(;o>=0&&c.some(e=>e>=n);){let t=e[o];c[t.lane]=t.start,o--}o=Math.max(0,o-o%r),s=Math.min(i,s+(r-1-s%r))}return{startIndex:o,endIndex:s}}var oc=typeof document<`u`?B.useLayoutEffect:B.useEffect;function sc(e){let t=B.useReducer(()=>({}),{})[1],n={...e,onChange:(n,r)=>{var i;r?(0,Ts.flushSync)(t):t(),(i=e.onChange)==null||i.call(e,n,r)}},[r]=B.useState(()=>new rc(n));return r.setOptions(n),oc(()=>r._didMount(),[]),oc(()=>r._willUpdate()),r}function cc(e){return sc({observeElementRect:Zs,observeElementOffset:ec,scrollToFn:nc,...e})}function lc(e,t){return typeof e==`function`?e(t):e}function uc(e,t){return n=>{t.setState(t=>({...t,[e]:lc(n,t[e])}))}}function dc(e){return e instanceof Function}function fc(e){return Array.isArray(e)&&e.every(e=>typeof e==`number`)}function pc(e,t){let n=[],r=e=>{e.forEach(e=>{n.push(e);let i=t(e);i!=null&&i.length&&r(i)})};return r(e),n}function Q(e,t,n){let r=[],i;return a=>{let o;n.key&&n.debug&&(o=Date.now());let s=e(a);if(!(s.length!==r.length||s.some((e,t)=>r[t]!==e)))return i;r=s;let c;if(n.key&&n.debug&&(c=Date.now()),i=t(...s),n==null||n.onChange==null||n.onChange(i),n.key&&n.debug&&n!=null&&n.debug()){let e=Math.round((Date.now()-o)*100)/100,t=Math.round((Date.now()-c)*100)/100,r=t/16,i=(e,t)=>{for(e=String(e);e.length<t;)e=` `+e;return e};console.info(`%c⏱ ${i(t,5)} /${i(e,5)} ms`,`
|
|
134
|
-
font-size: .6rem;
|
|
135
|
-
font-weight: bold;
|
|
136
|
-
color: hsl(${Math.max(0,Math.min(120-120*r,120))}deg 100% 31%);`,n?.key)}return i}}function $(e,t,n,r){return{debug:()=>e?.debugAll??e[t],key:!1,onChange:r}}function mc(e,t,n,r){let i={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(r),renderValue:()=>i.getValue()??e.options.renderFallbackValue,getContext:Q(()=>[e,n,t,i],(e,t,n,r)=>({table:e,column:t,row:n,cell:r,getValue:r.getValue,renderValue:r.renderValue}),$(e.options,`debugCells`,`cell.getContext`))};return e._features.forEach(r=>{r.createCell==null||r.createCell(i,n,t,e)},{}),i}function hc(e,t,n,r){let i={...e._getDefaultColumnDef(),...t},a=i.accessorKey,o=i.id??(a?typeof String.prototype.replaceAll==`function`?a.replaceAll(`.`,`_`):a.replace(/\./g,`_`):void 0)??(typeof i.header==`string`?i.header:void 0),s;if(i.accessorFn?s=i.accessorFn:a&&(s=a.includes(`.`)?e=>{let t=e;for(let e of a.split(`.`))t=t?.[e];return t}:e=>e[i.accessorKey]),!o)throw Error();let c={id:`${String(o)}`,accessorFn:s,parent:r,depth:n,columnDef:i,columns:[],getFlatColumns:Q(()=>[!0],()=>[c,...c.columns?.flatMap(e=>e.getFlatColumns())],$(e.options,`debugColumns`,`column.getFlatColumns`)),getLeafColumns:Q(()=>[e._getOrderColumnsFn()],e=>{var t;return(t=c.columns)!=null&&t.length?e(c.columns.flatMap(e=>e.getLeafColumns())):[c]},$(e.options,`debugColumns`,`column.getLeafColumns`))};for(let t of e._features)t.createColumn==null||t.createColumn(c,e);return c}var gc=`debugHeaders`;function _c(e,t,n){let r={id:n.id??t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{let e=[],t=n=>{n.subHeaders&&n.subHeaders.length&&n.subHeaders.map(t),e.push(n)};return t(r),e},getContext:()=>({table:e,header:r,column:t})};return e._features.forEach(t=>{t.createHeader==null||t.createHeader(r,e)}),r}var vc={createTable:e=>{e.getHeaderGroups=Q(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,i)=>{let a=r?.map(e=>n.find(t=>t.id===e)).filter(Boolean)??[],o=i?.map(e=>n.find(t=>t.id===e)).filter(Boolean)??[],s=n.filter(e=>!(r!=null&&r.includes(e.id))&&!(i!=null&&i.includes(e.id)));return yc(t,[...a,...s,...o],e)},$(e.options,gc,`getHeaderGroups`)),e.getCenterHeaderGroups=Q(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,i)=>(n=n.filter(e=>!(r!=null&&r.includes(e.id))&&!(i!=null&&i.includes(e.id))),yc(t,n,e,`center`)),$(e.options,gc,`getCenterHeaderGroups`)),e.getLeftHeaderGroups=Q(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,r)=>yc(t,r?.map(e=>n.find(t=>t.id===e)).filter(Boolean)??[],e,`left`),$(e.options,gc,`getLeftHeaderGroups`)),e.getRightHeaderGroups=Q(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,r)=>yc(t,r?.map(e=>n.find(t=>t.id===e)).filter(Boolean)??[],e,`right`),$(e.options,gc,`getRightHeaderGroups`)),e.getFooterGroups=Q(()=>[e.getHeaderGroups()],e=>[...e].reverse(),$(e.options,gc,`getFooterGroups`)),e.getLeftFooterGroups=Q(()=>[e.getLeftHeaderGroups()],e=>[...e].reverse(),$(e.options,gc,`getLeftFooterGroups`)),e.getCenterFooterGroups=Q(()=>[e.getCenterHeaderGroups()],e=>[...e].reverse(),$(e.options,gc,`getCenterFooterGroups`)),e.getRightFooterGroups=Q(()=>[e.getRightHeaderGroups()],e=>[...e].reverse(),$(e.options,gc,`getRightFooterGroups`)),e.getFlatHeaders=Q(()=>[e.getHeaderGroups()],e=>e.map(e=>e.headers).flat(),$(e.options,gc,`getFlatHeaders`)),e.getLeftFlatHeaders=Q(()=>[e.getLeftHeaderGroups()],e=>e.map(e=>e.headers).flat(),$(e.options,gc,`getLeftFlatHeaders`)),e.getCenterFlatHeaders=Q(()=>[e.getCenterHeaderGroups()],e=>e.map(e=>e.headers).flat(),$(e.options,gc,`getCenterFlatHeaders`)),e.getRightFlatHeaders=Q(()=>[e.getRightHeaderGroups()],e=>e.map(e=>e.headers).flat(),$(e.options,gc,`getRightFlatHeaders`)),e.getCenterLeafHeaders=Q(()=>[e.getCenterFlatHeaders()],e=>e.filter(e=>{var t;return!((t=e.subHeaders)!=null&&t.length)}),$(e.options,gc,`getCenterLeafHeaders`)),e.getLeftLeafHeaders=Q(()=>[e.getLeftFlatHeaders()],e=>e.filter(e=>{var t;return!((t=e.subHeaders)!=null&&t.length)}),$(e.options,gc,`getLeftLeafHeaders`)),e.getRightLeafHeaders=Q(()=>[e.getRightFlatHeaders()],e=>e.filter(e=>{var t;return!((t=e.subHeaders)!=null&&t.length)}),$(e.options,gc,`getRightLeafHeaders`)),e.getLeafHeaders=Q(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(e,t,n)=>[...e[0]?.headers??[],...t[0]?.headers??[],...n[0]?.headers??[]].map(e=>e.getLeafHeaders()).flat(),$(e.options,gc,`getLeafHeaders`))}};function yc(e,t,n,r){let i=0,a=function(e,t){t===void 0&&(t=1),i=Math.max(i,t),e.filter(e=>e.getIsVisible()).forEach(e=>{var n;(n=e.columns)!=null&&n.length&&a(e.columns,t+1)},0)};a(e);let o=[],s=(e,t)=>{let i={depth:t,id:[r,`${t}`].filter(Boolean).join(`_`),headers:[]},a=[];e.forEach(e=>{let o=[...a].reverse()[0],s=e.column.depth===i.depth,c,l=!1;if(s&&e.column.parent?c=e.column.parent:(c=e.column,l=!0),o&&o?.column===c)o.subHeaders.push(e);else{let i=_c(n,c,{id:[r,t,c.id,e?.id].filter(Boolean).join(`_`),isPlaceholder:l,placeholderId:l?`${a.filter(e=>e.column===c).length}`:void 0,depth:t,index:a.length});i.subHeaders.push(e),a.push(i)}i.headers.push(e),e.headerGroup=i}),o.push(i),t>0&&s(a,t-1)};s(t.map((e,t)=>_c(n,e,{depth:i,index:t})),i-1),o.reverse();let c=e=>e.filter(e=>e.column.getIsVisible()).map(e=>{let t=0,n=0,r=[0];e.subHeaders&&e.subHeaders.length?(r=[],c(e.subHeaders).forEach(e=>{let{colSpan:n,rowSpan:i}=e;t+=n,r.push(i)})):t=1;let i=Math.min(...r);return n+=i,e.colSpan=t,e.rowSpan=n,{colSpan:t,rowSpan:n}});return c(o[0]?.headers??[]),o}var bc=(e,t,n,r,i,a,o)=>{let s={id:t,index:r,original:n,depth:i,parentId:o,_valuesCache:{},_uniqueValuesCache:{},getValue:t=>{if(s._valuesCache.hasOwnProperty(t))return s._valuesCache[t];let n=e.getColumn(t);if(n!=null&&n.accessorFn)return s._valuesCache[t]=n.accessorFn(s.original,r),s._valuesCache[t]},getUniqueValues:t=>{if(s._uniqueValuesCache.hasOwnProperty(t))return s._uniqueValuesCache[t];let n=e.getColumn(t);if(n!=null&&n.accessorFn)return n.columnDef.getUniqueValues?(s._uniqueValuesCache[t]=n.columnDef.getUniqueValues(s.original,r),s._uniqueValuesCache[t]):(s._uniqueValuesCache[t]=[s.getValue(t)],s._uniqueValuesCache[t])},renderValue:t=>s.getValue(t)??e.options.renderFallbackValue,subRows:a??[],getLeafRows:()=>pc(s.subRows,e=>e.subRows),getParentRow:()=>s.parentId?e.getRow(s.parentId,!0):void 0,getParentRows:()=>{let e=[],t=s;for(;;){let n=t.getParentRow();if(!n)break;e.push(n),t=n}return e.reverse()},getAllCells:Q(()=>[e.getAllLeafColumns()],t=>t.map(t=>mc(e,s,t,t.id)),$(e.options,`debugRows`,`getAllCells`)),_getAllCellsByColumnId:Q(()=>[s.getAllCells()],e=>e.reduce((e,t)=>(e[t.column.id]=t,e),{}),$(e.options,`debugRows`,`getAllCellsByColumnId`))};for(let t=0;t<e._features.length;t++){let n=e._features[t];n==null||n.createRow==null||n.createRow(s,e)}return s},xc={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},Sc=(e,t,n)=>{var r,i;let a=n==null||(r=n.toString())==null?void 0:r.toLowerCase();return!!((i=e.getValue(t))!=null&&(i=i.toString())!=null&&(i=i.toLowerCase())!=null&&i.includes(a))};Sc.autoRemove=e=>Mc(e);var Cc=(e,t,n)=>{var r;return!!((r=e.getValue(t))!=null&&(r=r.toString())!=null&&r.includes(n))};Cc.autoRemove=e=>Mc(e);var wc=(e,t,n)=>{var r;return((r=e.getValue(t))==null||(r=r.toString())==null?void 0:r.toLowerCase())===n?.toLowerCase()};wc.autoRemove=e=>Mc(e);var Tc=(e,t,n)=>e.getValue(t)?.includes(n);Tc.autoRemove=e=>Mc(e);var Ec=(e,t,n)=>!n.some(n=>{var r;return!((r=e.getValue(t))!=null&&r.includes(n))});Ec.autoRemove=e=>Mc(e)||!(e!=null&&e.length);var Dc=(e,t,n)=>n.some(n=>e.getValue(t)?.includes(n));Dc.autoRemove=e=>Mc(e)||!(e!=null&&e.length);var Oc=(e,t,n)=>e.getValue(t)===n;Oc.autoRemove=e=>Mc(e);var kc=(e,t,n)=>e.getValue(t)==n;kc.autoRemove=e=>Mc(e);var Ac=(e,t,n)=>{let[r,i]=n,a=e.getValue(t);return a>=r&&a<=i};Ac.resolveFilterValue=e=>{let[t,n]=e,r=typeof t==`number`?t:parseFloat(t),i=typeof n==`number`?n:parseFloat(n),a=t===null||Number.isNaN(r)?-1/0:r,o=n===null||Number.isNaN(i)?1/0:i;if(a>o){let e=a;a=o,o=e}return[a,o]},Ac.autoRemove=e=>Mc(e)||Mc(e[0])&&Mc(e[1]);var jc={includesString:Sc,includesStringSensitive:Cc,equalsString:wc,arrIncludes:Tc,arrIncludesAll:Ec,arrIncludesSome:Dc,equals:Oc,weakEquals:kc,inNumberRange:Ac};function Mc(e){return e==null||e===``}var Nc={getDefaultColumnDef:()=>({filterFn:`auto`}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:uc(`columnFilters`,e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{let n=t.getCoreRowModel().flatRows[0]?.getValue(e.id);return typeof n==`string`?jc.includesString:typeof n==`number`?jc.inNumberRange:typeof n==`boolean`||typeof n==`object`&&n?jc.equals:Array.isArray(n)?jc.arrIncludes:jc.weakEquals},e.getFilterFn=()=>dc(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn===`auto`?e.getAutoFilterFn():t.options.filterFns?.[e.columnDef.filterFn]??jc[e.columnDef.filterFn],e.getCanFilter=()=>(e.columnDef.enableColumnFilter??!0)&&(t.options.enableColumnFilters??!0)&&(t.options.enableFilters??!0)&&!!e.accessorFn,e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(t=>t.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>t.getState().columnFilters?.findIndex(t=>t.id===e.id)??-1,e.setFilterValue=n=>{t.setColumnFilters(t=>{let r=e.getFilterFn(),i=t?.find(t=>t.id===e.id),a=lc(n,i?i.value:void 0);if(Pc(r,a,e))return t?.filter(t=>t.id!==e.id)??[];let o={id:e.id,value:a};return i?t?.map(t=>t.id===e.id?o:t)??[]:t!=null&&t.length?[...t,o]:[o]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{let n=e.getAllLeafColumns();e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(e=>lc(t,e)?.filter(e=>{let t=n.find(t=>t.id===e.id);return!(t&&Pc(t.getFilterFn(),e.value,t))}))},e.resetColumnFilters=t=>{e.setColumnFilters(t?[]:e.initialState?.columnFilters??[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function Pc(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||t===void 0||typeof t==`string`&&!t}var Fc={sum:(e,t,n)=>n.reduce((t,n)=>{let r=n.getValue(e);return t+(typeof r==`number`?r:0)},0),min:(e,t,n)=>{let r;return n.forEach(t=>{let n=t.getValue(e);n!=null&&(r>n||r===void 0&&n>=n)&&(r=n)}),r},max:(e,t,n)=>{let r;return n.forEach(t=>{let n=t.getValue(e);n!=null&&(r<n||r===void 0&&n>=n)&&(r=n)}),r},extent:(e,t,n)=>{let r,i;return n.forEach(t=>{let n=t.getValue(e);n!=null&&(r===void 0?n>=n&&(r=i=n):(r>n&&(r=n),i<n&&(i=n)))}),[r,i]},mean:(e,t)=>{let n=0,r=0;if(t.forEach(t=>{let i=t.getValue(e);i!=null&&(i=+i)>=i&&(++n,r+=i)}),n)return r/n},median:(e,t)=>{if(!t.length)return;let n=t.map(t=>t.getValue(e));if(!fc(n))return;if(n.length===1)return n[0];let r=Math.floor(n.length/2),i=n.sort((e,t)=>e-t);return n.length%2==0?(i[r-1]+i[r])/2:i[r]},unique:(e,t)=>Array.from(new Set(t.map(t=>t.getValue(e))).values()),uniqueCount:(e,t)=>new Set(t.map(t=>t.getValue(e))).size,count:(e,t)=>t.length},Ic={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t;return((t=e.getValue())==null||t.toString==null?void 0:t.toString())??null},aggregationFn:`auto`}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:uc(`grouping`,e),groupedColumnMode:`reorder`}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(t=>t!=null&&t.includes(e.id)?t.filter(t=>t!==e.id):[...t??[],e.id])},e.getCanGroup=()=>(e.columnDef.enableGrouping??!0)&&(t.options.enableGrouping??!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue),e.getIsGrouped=()=>t.getState().grouping?.includes(e.id),e.getGroupedIndex=()=>t.getState().grouping?.indexOf(e.id),e.getToggleGroupingHandler=()=>{let t=e.getCanGroup();return()=>{t&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{let n=t.getCoreRowModel().flatRows[0]?.getValue(e.id);if(typeof n==`number`)return Fc.sum;if(Object.prototype.toString.call(n)===`[object Date]`)return Fc.extent},e.getAggregationFn=()=>{if(!e)throw Error();return dc(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn===`auto`?e.getAutoAggregationFn():t.options.aggregationFns?.[e.columnDef.aggregationFn]??Fc[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{e.setGrouping(t?[]:e.initialState?.grouping??[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];let r=t.getColumn(n);return r!=null&&r.columnDef.getGroupingValue?(e._groupingValuesCache[n]=r.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,r)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var t;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((t=n.subRows)!=null&&t.length)}}};function Lc(e,t,n){if(!(t!=null&&t.length)||!n)return e;let r=e.filter(e=>!t.includes(e.id));return n===`remove`?r:[...t.map(t=>e.find(e=>e.id===t)).filter(Boolean),...r]}var Rc={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:uc(`columnOrder`,e)}),createColumn:(e,t)=>{e.getIndex=Q(e=>[Yc(t,e)],t=>t.findIndex(t=>t.id===e.id),$(t.options,`debugColumns`,`getIndex`)),e.getIsFirstColumn=n=>Yc(t,n)[0]?.id===e.id,e.getIsLastColumn=n=>{let r=Yc(t,n);return r[r.length-1]?.id===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{e.setColumnOrder(t?[]:e.initialState.columnOrder??[])},e._getOrderColumnsFn=Q(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(e,t,n)=>r=>{let i=[];if(!(e!=null&&e.length))i=r;else{let t=[...e],n=[...r];for(;n.length&&t.length;){let e=t.shift(),r=n.findIndex(t=>t.id===e);r>-1&&i.push(n.splice(r,1)[0])}i=[...i,...n]}return Lc(i,t,n)},$(e.options,`debugTable`,`_getOrderColumnsFn`))}},zc=()=>({left:[],right:[]}),Bc={getInitialState:e=>({columnPinning:zc(),...e}),getDefaultOptions:e=>({onColumnPinningChange:uc(`columnPinning`,e)}),createColumn:(e,t)=>{e.pin=n=>{let r=e.getLeafColumns().map(e=>e.id).filter(Boolean);t.setColumnPinning(e=>n===`right`?{left:(e?.left??[]).filter(e=>!(r!=null&&r.includes(e))),right:[...(e?.right??[]).filter(e=>!(r!=null&&r.includes(e))),...r]}:n===`left`?{left:[...(e?.left??[]).filter(e=>!(r!=null&&r.includes(e))),...r],right:(e?.right??[]).filter(e=>!(r!=null&&r.includes(e)))}:{left:(e?.left??[]).filter(e=>!(r!=null&&r.includes(e))),right:(e?.right??[]).filter(e=>!(r!=null&&r.includes(e)))})},e.getCanPin=()=>e.getLeafColumns().some(e=>(e.columnDef.enablePinning??!0)&&(t.options.enableColumnPinning??t.options.enablePinning??!0)),e.getIsPinned=()=>{let n=e.getLeafColumns().map(e=>e.id),{left:r,right:i}=t.getState().columnPinning,a=n.some(e=>r?.includes(e)),o=n.some(e=>i?.includes(e));return a?`left`:o?`right`:!1},e.getPinnedIndex=()=>{var n;let r=e.getIsPinned();return r?((n=t.getState().columnPinning)==null||(n=n[r])==null?void 0:n.indexOf(e.id))??-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=Q(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(e,t,n)=>{let r=[...t??[],...n??[]];return e.filter(e=>!r.includes(e.column.id))},$(t.options,`debugRows`,`getCenterVisibleCells`)),e.getLeftVisibleCells=Q(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(e,t)=>(t??[]).map(t=>e.find(e=>e.column.id===t)).filter(Boolean).map(e=>({...e,position:`left`})),$(t.options,`debugRows`,`getLeftVisibleCells`)),e.getRightVisibleCells=Q(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(e,t)=>(t??[]).map(t=>e.find(e=>e.column.id===t)).filter(Boolean).map(e=>({...e,position:`right`})),$(t.options,`debugRows`,`getRightVisibleCells`))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>e.setColumnPinning(t?zc():e.initialState?.columnPinning??zc()),e.getIsSomeColumnsPinned=t=>{let n=e.getState().columnPinning;return t?!!n[t]?.length:!!(n.left?.length||n.right?.length)},e.getLeftLeafColumns=Q(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(e,t)=>(t??[]).map(t=>e.find(e=>e.id===t)).filter(Boolean),$(e.options,`debugColumns`,`getLeftLeafColumns`)),e.getRightLeafColumns=Q(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(e,t)=>(t??[]).map(t=>e.find(e=>e.id===t)).filter(Boolean),$(e.options,`debugColumns`,`getRightLeafColumns`)),e.getCenterLeafColumns=Q(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(e,t,n)=>{let r=[...t??[],...n??[]];return e.filter(e=>!r.includes(e.id))},$(e.options,`debugColumns`,`getCenterLeafColumns`))}};function Vc(e){return e||(typeof document<`u`?document:null)}var Hc={size:150,minSize:20,maxSize:2**53-1},Uc=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),Wc={getDefaultColumnDef:()=>Hc,getInitialState:e=>({columnSizing:{},columnSizingInfo:Uc(),...e}),getDefaultOptions:e=>({columnResizeMode:`onEnd`,columnResizeDirection:`ltr`,onColumnSizingChange:uc(`columnSizing`,e),onColumnSizingInfoChange:uc(`columnSizingInfo`,e)}),createColumn:(e,t)=>{e.getSize=()=>{let n=t.getState().columnSizing[e.id];return Math.min(Math.max(e.columnDef.minSize??Hc.minSize,n??e.columnDef.size??Hc.size),e.columnDef.maxSize??Hc.maxSize)},e.getStart=Q(e=>[e,Yc(t,e),t.getState().columnSizing],(t,n)=>n.slice(0,e.getIndex(t)).reduce((e,t)=>e+t.getSize(),0),$(t.options,`debugColumns`,`getStart`)),e.getAfter=Q(e=>[e,Yc(t,e),t.getState().columnSizing],(t,n)=>n.slice(e.getIndex(t)+1).reduce((e,t)=>e+t.getSize(),0),$(t.options,`debugColumns`,`getAfter`)),e.resetSize=()=>{t.setColumnSizing(t=>{let{[e.id]:n,...r}=t;return r})},e.getCanResize=()=>(e.columnDef.enableResizing??!0)&&(t.options.enableColumnResizing??!0),e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let t=0,n=e=>{e.subHeaders.length?e.subHeaders.forEach(n):t+=e.column.getSize()??0};return n(e),t},e.getStart=()=>{if(e.index>0){let t=e.headerGroup.headers[e.index-1];return t.getStart()+t.getSize()}return 0},e.getResizeHandler=n=>{let r=t.getColumn(e.column.id),i=r?.getCanResize();return a=>{if(!r||!i||(a.persist==null||a.persist(),qc(a)&&a.touches&&a.touches.length>1))return;let o=e.getSize(),s=e?e.getLeafHeaders().map(e=>[e.column.id,e.column.getSize()]):[[r.id,r.getSize()]],c=qc(a)?Math.round(a.touches[0].clientX):a.clientX,l={},u=(e,n)=>{typeof n==`number`&&(t.setColumnSizingInfo(e=>{let r=t.options.columnResizeDirection===`rtl`?-1:1,i=(n-(e?.startOffset??0))*r,a=Math.max(i/(e?.startSize??0),-.999999);return e.columnSizingStart.forEach(e=>{let[t,n]=e;l[t]=Math.round(Math.max(n+n*a,0)*100)/100}),{...e,deltaOffset:i,deltaPercentage:a}}),(t.options.columnResizeMode===`onChange`||e===`end`)&&t.setColumnSizing(e=>({...e,...l})))},d=e=>u(`move`,e),f=e=>{u(`end`,e),t.setColumnSizingInfo(e=>({...e,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},p=Vc(n),m={moveHandler:e=>d(e.clientX),upHandler:e=>{p?.removeEventListener(`mousemove`,m.moveHandler),p?.removeEventListener(`mouseup`,m.upHandler),f(e.clientX)}},h={moveHandler:e=>(e.cancelable&&(e.preventDefault(),e.stopPropagation()),d(e.touches[0].clientX),!1),upHandler:e=>{p?.removeEventListener(`touchmove`,h.moveHandler),p?.removeEventListener(`touchend`,h.upHandler),e.cancelable&&(e.preventDefault(),e.stopPropagation()),f(e.touches[0]?.clientX)}},g=Kc()?{passive:!1}:!1;qc(a)?(p?.addEventListener(`touchmove`,h.moveHandler,g),p?.addEventListener(`touchend`,h.upHandler,g)):(p?.addEventListener(`mousemove`,m.moveHandler,g),p?.addEventListener(`mouseup`,m.upHandler,g)),t.setColumnSizingInfo(e=>({...e,startOffset:c,startSize:o,deltaOffset:0,deltaPercentage:0,columnSizingStart:s,isResizingColumn:r.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{e.setColumnSizing(t?{}:e.initialState.columnSizing??{})},e.resetHeaderSizeInfo=t=>{e.setColumnSizingInfo(t?Uc():e.initialState.columnSizingInfo??Uc())},e.getTotalSize=()=>e.getHeaderGroups()[0]?.headers.reduce((e,t)=>e+t.getSize(),0)??0,e.getLeftTotalSize=()=>e.getLeftHeaderGroups()[0]?.headers.reduce((e,t)=>e+t.getSize(),0)??0,e.getCenterTotalSize=()=>e.getCenterHeaderGroups()[0]?.headers.reduce((e,t)=>e+t.getSize(),0)??0,e.getRightTotalSize=()=>e.getRightHeaderGroups()[0]?.headers.reduce((e,t)=>e+t.getSize(),0)??0}},Gc=null;function Kc(){if(typeof Gc==`boolean`)return Gc;let e=!1;try{let t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener(`test`,n,t),window.removeEventListener(`test`,n)}catch{e=!1}return Gc=e,Gc}function qc(e){return e.type===`touchstart`}var Jc={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:uc(`columnVisibility`,e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(t=>({...t,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{let n=e.columns;return(n.length?n.some(e=>e.getIsVisible()):t.getState().columnVisibility?.[e.id])??!0},e.getCanHide=()=>(e.columnDef.enableHiding??!0)&&(t.options.enableHiding??!0),e.getToggleVisibilityHandler=()=>t=>{e.toggleVisibility==null||e.toggleVisibility(t.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=Q(()=>[e.getAllCells(),t.getState().columnVisibility],e=>e.filter(e=>e.column.getIsVisible()),$(t.options,`debugRows`,`_getAllVisibleCells`)),e.getVisibleCells=Q(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(e,t,n)=>[...e,...t,...n],$(t.options,`debugRows`,`getVisibleCells`))},createTable:e=>{let t=(t,n)=>Q(()=>[n(),n().filter(e=>e.getIsVisible()).map(e=>e.id).join(`_`)],e=>e.filter(e=>e.getIsVisible==null?void 0:e.getIsVisible()),$(e.options,`debugColumns`,t));e.getVisibleFlatColumns=t(`getVisibleFlatColumns`,()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t(`getVisibleLeafColumns`,()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t(`getLeftVisibleLeafColumns`,()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t(`getRightVisibleLeafColumns`,()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t(`getCenterVisibleLeafColumns`,()=>e.getCenterLeafColumns()),e.setColumnVisibility=t=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(t),e.resetColumnVisibility=t=>{e.setColumnVisibility(t?{}:e.initialState.columnVisibility??{})},e.toggleAllColumnsVisible=t=>{t??=!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((e,n)=>({...e,[n.id]:t||!(n.getCanHide!=null&&n.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(e=>!(e.getIsVisible!=null&&e.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(e=>e.getIsVisible==null?void 0:e.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>t=>{e.toggleAllColumnsVisible(t.target?.checked)}}};function Yc(e,t){return t?t===`center`?e.getCenterVisibleLeafColumns():t===`left`?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}var Xc={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,`__global__`),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,`__global__`),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,`__global__`),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},Zc={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:uc(`globalFilter`,e),globalFilterFn:`auto`,getColumnCanGlobalFilter:t=>{var n;let r=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof r==`string`||typeof r==`number`}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>(e.columnDef.enableGlobalFilter??!0)&&(t.options.enableGlobalFilter??!0)&&(t.options.enableFilters??!0)&&((t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))??!0)&&!!e.accessorFn},createTable:e=>{e.getGlobalAutoFilterFn=()=>jc.includesString,e.getGlobalFilterFn=()=>{let{globalFilterFn:t}=e.options;return dc(t)?t:t===`auto`?e.getGlobalAutoFilterFn():e.options.filterFns?.[t]??jc[t]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},Qc={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:uc(`expanded`,e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{if(!t)e._queue(()=>{t=!0});else if(e.options.autoResetAll??e.options.autoResetExpanded??!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=t=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(t),e.toggleAllRowsExpanded=t=>{t??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=t=>{e.setExpanded(t?{}:e.initialState?.expanded??{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(e=>e.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>t=>{t.persist==null||t.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{let t=e.getState().expanded;return t===!0||Object.values(t).some(Boolean)},e.getIsAllRowsExpanded=()=>{let t=e.getState().expanded;return typeof t==`boolean`?t===!0:!(!Object.keys(t).length||e.getRowModel().flatRows.some(e=>!e.getIsExpanded()))},e.getExpandedDepth=()=>{let t=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(e=>{let n=e.split(`.`);t=Math.max(t,n.length)}),t},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(r=>{let i=r===!0||!!(r!=null&&r[e.id]),a={};if(r===!0?Object.keys(t.getRowModel().rowsById).forEach(e=>{a[e]=!0}):a=r,n??=!i,!i&&n)return{...a,[e.id]:!0};if(i&&!n){let{[e.id]:t,...n}=a;return n}return r})},e.getIsExpanded=()=>{let n=t.getState().expanded;return!!((t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))??(n===!0||n?.[e.id]))},e.getCanExpand=()=>{var n;return(t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))??((t.options.enableExpanding??!0)&&!!((n=e.subRows)!=null&&n.length))},e.getIsAllParentsExpanded=()=>{let n=!0,r=e;for(;n&&r.parentId;)r=t.getRow(r.parentId,!0),n=r.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{let t=e.getCanExpand();return()=>{t&&e.toggleExpanded()}}}},$c=0,el=10,tl=()=>({pageIndex:$c,pageSize:el}),nl={getInitialState:e=>({...e,pagination:{...tl(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:uc(`pagination`,e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{if(!t)e._queue(()=>{t=!0});else if(e.options.autoResetAll??e.options.autoResetPageIndex??!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=t=>e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(e=>lc(t,e)),e.resetPagination=t=>{e.setPagination(t?tl():e.initialState.pagination??tl())},e.setPageIndex=t=>{e.setPagination(n=>{let r=lc(t,n.pageIndex),i=e.options.pageCount===void 0||e.options.pageCount===-1?2**53-1:e.options.pageCount-1;return r=Math.max(0,Math.min(r,i)),{...n,pageIndex:r}})},e.resetPageIndex=t=>{var n;e.setPageIndex(t?$c:((n=e.initialState)==null||(n=n.pagination)==null?void 0:n.pageIndex)??$c)},e.resetPageSize=t=>{var n;e.setPageSize(t?el:((n=e.initialState)==null||(n=n.pagination)==null?void 0:n.pageSize)??el)},e.setPageSize=t=>{e.setPagination(e=>{let n=Math.max(1,lc(t,e.pageSize)),r=e.pageSize*e.pageIndex,i=Math.floor(r/n);return{...e,pageIndex:i,pageSize:n}})},e.setPageCount=t=>e.setPagination(n=>{let r=lc(t,e.options.pageCount??-1);return typeof r==`number`&&(r=Math.max(-1,r)),{...n,pageCount:r}}),e.getPageOptions=Q(()=>[e.getPageCount()],e=>{let t=[];return e&&e>0&&(t=[...Array(e)].fill(null).map((e,t)=>t)),t},$(e.options,`debugTable`,`getPageOptions`)),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{let{pageIndex:t}=e.getState().pagination,n=e.getPageCount();return n===-1||n!==0&&t<n-1},e.previousPage=()=>e.setPageIndex(e=>e-1),e.nextPage=()=>e.setPageIndex(e=>e+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>e.options.pageCount??Math.ceil(e.getRowCount()/e.getState().pagination.pageSize),e.getRowCount=()=>e.options.rowCount??e.getPrePaginationRowModel().rows.length}},rl=()=>({top:[],bottom:[]}),il={getInitialState:e=>({rowPinning:rl(),...e}),getDefaultOptions:e=>({onRowPinningChange:uc(`rowPinning`,e)}),createRow:(e,t)=>{e.pin=(n,r,i)=>{let a=r?e.getLeafRows().map(e=>{let{id:t}=e;return t}):[],o=i?e.getParentRows().map(e=>{let{id:t}=e;return t}):[],s=new Set([...o,e.id,...a]);t.setRowPinning(e=>n===`bottom`?{top:(e?.top??[]).filter(e=>!(s!=null&&s.has(e))),bottom:[...(e?.bottom??[]).filter(e=>!(s!=null&&s.has(e))),...Array.from(s)]}:n===`top`?{top:[...(e?.top??[]).filter(e=>!(s!=null&&s.has(e))),...Array.from(s)],bottom:(e?.bottom??[]).filter(e=>!(s!=null&&s.has(e)))}:{top:(e?.top??[]).filter(e=>!(s!=null&&s.has(e))),bottom:(e?.bottom??[]).filter(e=>!(s!=null&&s.has(e)))})},e.getCanPin=()=>{let{enableRowPinning:n,enablePinning:r}=t.options;return typeof n==`function`?n(e):n??r??!0},e.getIsPinned=()=>{let n=[e.id],{top:r,bottom:i}=t.getState().rowPinning,a=n.some(e=>r?.includes(e)),o=n.some(e=>i?.includes(e));return a?`top`:o?`bottom`:!1},e.getPinnedIndex=()=>{let n=e.getIsPinned();return n?((n===`top`?t.getTopRows():t.getBottomRows())?.map(e=>{let{id:t}=e;return t}))?.indexOf(e.id)??-1:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>e.setRowPinning(t?rl():e.initialState?.rowPinning??rl()),e.getIsSomeRowsPinned=t=>{let n=e.getState().rowPinning;return t?!!n[t]?.length:!!(n.top?.length||n.bottom?.length)},e._getPinnedRows=(t,n,r)=>(e.options.keepPinnedRows??!0?(n??[]).map(t=>{let n=e.getRow(t,!0);return n.getIsAllParentsExpanded()?n:null}):(n??[]).map(e=>t.find(t=>t.id===e))).filter(Boolean).map(e=>({...e,position:r})),e.getTopRows=Q(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,`top`),$(e.options,`debugRows`,`getTopRows`)),e.getBottomRows=Q(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,`bottom`),$(e.options,`debugRows`,`getBottomRows`)),e.getCenterRows=Q(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(e,t,n)=>{let r=new Set([...t??[],...n??[]]);return e.filter(e=>!r.has(e.id))},$(e.options,`debugRows`,`getCenterRows`))}},al={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:uc(`rowSelection`,e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>e.setRowSelection(t?{}:e.initialState.rowSelection??{}),e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=t===void 0?!e.getIsAllRowsSelected():t;let r={...n},i=e.getPreGroupedRowModel().flatRows;return t?i.forEach(e=>{e.getCanSelect()&&(r[e.id]=!0)}):i.forEach(e=>{delete r[e.id]}),r})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{let r=t===void 0?!e.getIsAllPageRowsSelected():t,i={...n};return e.getRowModel().rows.forEach(t=>{ol(i,t.id,r,!0,e)}),i}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=Q(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?sl(e,n):{rows:[],flatRows:[],rowsById:{}},$(e.options,`debugTable`,`getSelectedRowModel`)),e.getFilteredSelectedRowModel=Q(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?sl(e,n):{rows:[],flatRows:[],rowsById:{}},$(e.options,`debugTable`,`getFilteredSelectedRowModel`)),e.getGroupedSelectedRowModel=Q(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?sl(e,n):{rows:[],flatRows:[],rowsById:{}},$(e.options,`debugTable`,`getGroupedSelectedRowModel`)),e.getIsAllRowsSelected=()=>{let t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState(),r=!!(t.length&&Object.keys(n).length);return r&&t.some(e=>e.getCanSelect()&&!n[e.id])&&(r=!1),r},e.getIsAllPageRowsSelected=()=>{let t=e.getPaginationRowModel().flatRows.filter(e=>e.getCanSelect()),{rowSelection:n}=e.getState(),r=!!t.length;return r&&t.some(e=>!n[e.id])&&(r=!1),r},e.getIsSomeRowsSelected=()=>{let t=Object.keys(e.getState().rowSelection??{}).length;return t>0&&t<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{let t=e.getPaginationRowModel().flatRows;return!e.getIsAllPageRowsSelected()&&t.filter(e=>e.getCanSelect()).some(e=>e.getIsSelected()||e.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,r)=>{let i=e.getIsSelected();t.setRowSelection(a=>{if(n=n===void 0?!i:n,e.getCanSelect()&&i===n)return a;let o={...a};return ol(o,e.id,n,r?.selectChildren??!0,t),o})},e.getIsSelected=()=>{let{rowSelection:n}=t.getState();return cl(e,n)},e.getIsSomeSelected=()=>{let{rowSelection:n}=t.getState();return ll(e,n)===`some`},e.getIsAllSubRowsSelected=()=>{let{rowSelection:n}=t.getState();return ll(e,n)===`all`},e.getCanSelect=()=>typeof t.options.enableRowSelection==`function`?t.options.enableRowSelection(e):t.options.enableRowSelection??!0,e.getCanSelectSubRows=()=>typeof t.options.enableSubRowSelection==`function`?t.options.enableSubRowSelection(e):t.options.enableSubRowSelection??!0,e.getCanMultiSelect=()=>typeof t.options.enableMultiRowSelection==`function`?t.options.enableMultiRowSelection(e):t.options.enableMultiRowSelection??!0,e.getToggleSelectedHandler=()=>{let t=e.getCanSelect();return n=>{t&&e.toggleSelected(n.target?.checked)}}}},ol=(e,t,n,r,i)=>{var a;let o=i.getRow(t,!0);n?(o.getCanMultiSelect()||Object.keys(e).forEach(t=>delete e[t]),o.getCanSelect()&&(e[t]=!0)):delete e[t],r&&(a=o.subRows)!=null&&a.length&&o.getCanSelectSubRows()&&o.subRows.forEach(t=>ol(e,t.id,n,r,i))};function sl(e,t){let n=e.getState().rowSelection,r=[],i={},a=function(e,t){return e.map(e=>{var t;let o=cl(e,n);if(o&&(r.push(e),i[e.id]=e),(t=e.subRows)!=null&&t.length&&(e={...e,subRows:a(e.subRows)}),o)return e}).filter(Boolean)};return{rows:a(t.rows),flatRows:r,rowsById:i}}function cl(e,t){return t[e.id]??!1}function ll(e,t,n){var r;if(!((r=e.subRows)!=null&&r.length))return!1;let i=!0,a=!1;return e.subRows.forEach(e=>{if((!a||i)&&(e.getCanSelect()&&(cl(e,t)?a=!0:i=!1),e.subRows&&e.subRows.length)){let n=ll(e,t);n===`all`?a=!0:(n===`some`&&(a=!0),i=!1)}}),i?`all`:a?`some`:!1}var ul=/([0-9]+)/gm,dl=(e,t,n)=>yl(vl(e.getValue(n)).toLowerCase(),vl(t.getValue(n)).toLowerCase()),fl=(e,t,n)=>yl(vl(e.getValue(n)),vl(t.getValue(n))),pl=(e,t,n)=>_l(vl(e.getValue(n)).toLowerCase(),vl(t.getValue(n)).toLowerCase()),ml=(e,t,n)=>_l(vl(e.getValue(n)),vl(t.getValue(n))),hl=(e,t,n)=>{let r=e.getValue(n),i=t.getValue(n);return r>i?1:r<i?-1:0},gl=(e,t,n)=>_l(e.getValue(n),t.getValue(n));function _l(e,t){return e===t?0:e>t?1:-1}function vl(e){return typeof e==`number`?isNaN(e)||e===1/0||e===-1/0?``:String(e):typeof e==`string`?e:``}function yl(e,t){let n=e.split(ul).filter(Boolean),r=t.split(ul).filter(Boolean);for(;n.length&&r.length;){let e=n.shift(),t=r.shift(),i=parseInt(e,10),a=parseInt(t,10),o=[i,a].sort();if(isNaN(o[0])){if(e>t)return 1;if(t>e)return-1}else{if(isNaN(o[1]))return isNaN(i)?-1:1;if(i>a)return 1;if(a>i)return-1}}return n.length-r.length}var bl={alphanumeric:dl,alphanumericCaseSensitive:fl,text:pl,textCaseSensitive:ml,datetime:hl,basic:gl},xl=[vc,Jc,Rc,Bc,xc,Nc,Xc,Zc,{getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:`auto`,sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:uc(`sorting`,e),isMultiSortEvent:e=>e.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{let n=t.getFilteredRowModel().flatRows.slice(10),r=!1;for(let t of n){let n=t?.getValue(e.id);if(Object.prototype.toString.call(n)===`[object Date]`)return bl.datetime;if(typeof n==`string`&&(r=!0,n.split(ul).length>1))return bl.alphanumeric}return r?bl.text:bl.basic},e.getAutoSortDir=()=>typeof t.getFilteredRowModel().flatRows[0]?.getValue(e.id)==`string`?`asc`:`desc`,e.getSortingFn=()=>{if(!e)throw Error();return dc(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn===`auto`?e.getAutoSortingFn():t.options.sortingFns?.[e.columnDef.sortingFn]??bl[e.columnDef.sortingFn]},e.toggleSorting=(n,r)=>{let i=e.getNextSortingOrder(),a=n!=null;t.setSorting(o=>{let s=o?.find(t=>t.id===e.id),c=o?.findIndex(t=>t.id===e.id),l=[],u,d=a?n:i===`desc`;return u=o!=null&&o.length&&e.getCanMultiSort()&&r?s?`toggle`:`add`:o!=null&&o.length&&c!==o.length-1?`replace`:s?`toggle`:`replace`,u===`toggle`&&(a||i||(u=`remove`)),u===`add`?(l=[...o,{id:e.id,desc:d}],l.splice(0,l.length-(t.options.maxMultiSortColCount??2**53-1))):l=u===`toggle`?o.map(t=>t.id===e.id?{...t,desc:d}:t):u===`remove`?o.filter(t=>t.id!==e.id):[{id:e.id,desc:d}],l})},e.getFirstSortDir=()=>e.columnDef.sortDescFirst??t.options.sortDescFirst??e.getAutoSortDir()===`desc`?`desc`:`asc`,e.getNextSortingOrder=n=>{let r=e.getFirstSortDir(),i=e.getIsSorted();return i?i!==r&&(t.options.enableSortingRemoval??!0)&&(!n||(t.options.enableMultiRemove??!0))?!1:i===`desc`?`asc`:`desc`:r},e.getCanSort=()=>(e.columnDef.enableSorting??!0)&&(t.options.enableSorting??!0)&&!!e.accessorFn,e.getCanMultiSort=()=>e.columnDef.enableMultiSort??t.options.enableMultiSort??!!e.accessorFn,e.getIsSorted=()=>{let n=t.getState().sorting?.find(t=>t.id===e.id);return n?n.desc?`desc`:`asc`:!1},e.getSortIndex=()=>t.getState().sorting?.findIndex(t=>t.id===e.id)??-1,e.clearSorting=()=>{t.setSorting(t=>t!=null&&t.length?t.filter(t=>t.id!==e.id):[])},e.getToggleSortingHandler=()=>{let n=e.getCanSort();return r=>{n&&(r.persist==null||r.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(r):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{e.setSorting(t?[]:e.initialState?.sorting??[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},Ic,Qc,nl,il,al,Wc];function Sl(e){let t=[...xl,...e._features??[]],n={_features:t},r=n._features.reduce((e,t)=>Object.assign(e,t.getDefaultOptions==null?void 0:t.getDefaultOptions(n)),{}),i=e=>n.options.mergeOptions?n.options.mergeOptions(r,e):{...r,...e},a={...e.initialState??{}};n._features.forEach(e=>{a=(e.getInitialState==null?void 0:e.getInitialState(a))??a});let o=[],s=!1,c={_features:t,options:{...r,...e},initialState:a,_queue:e=>{o.push(e),s||(s=!0,Promise.resolve().then(()=>{for(;o.length;)o.shift()();s=!1}).catch(e=>setTimeout(()=>{throw e})))},reset:()=>{n.setState(n.initialState)},setOptions:e=>{let t=lc(e,n.options);n.options=i(t)},getState:()=>n.options.state,setState:e=>{n.options.onStateChange==null||n.options.onStateChange(e)},_getRowId:(e,t,r)=>(n.options.getRowId==null?void 0:n.options.getRowId(e,t,r))??`${r?[r.id,t].join(`.`):t}`,getCoreRowModel:()=>(n._getCoreRowModel||=n.options.getCoreRowModel(n),n._getCoreRowModel()),getRowModel:()=>n.getPaginationRowModel(),getRow:(e,t)=>{let r=(t?n.getPrePaginationRowModel():n.getRowModel()).rowsById[e];if(!r&&(r=n.getCoreRowModel().rowsById[e],!r))throw Error();return r},_getDefaultColumnDef:Q(()=>[n.options.defaultColumn],e=>(e??={},{header:e=>{let t=e.header.column.columnDef;return t.accessorKey?t.accessorKey:t.accessorFn?t.id:null},cell:e=>{var t;return((t=e.renderValue())==null||t.toString==null?void 0:t.toString())??null},...n._features.reduce((e,t)=>Object.assign(e,t.getDefaultColumnDef==null?void 0:t.getDefaultColumnDef()),{}),...e}),$(e,`debugColumns`,`_getDefaultColumnDef`)),_getColumnDefs:()=>n.options.columns,getAllColumns:Q(()=>[n._getColumnDefs()],e=>{let t=function(e,r,i){return i===void 0&&(i=0),e.map(e=>{let a=hc(n,e,i,r),o=e;return a.columns=o.columns?t(o.columns,a,i+1):[],a})};return t(e)},$(e,`debugColumns`,`getAllColumns`)),getAllFlatColumns:Q(()=>[n.getAllColumns()],e=>e.flatMap(e=>e.getFlatColumns()),$(e,`debugColumns`,`getAllFlatColumns`)),_getAllFlatColumnsById:Q(()=>[n.getAllFlatColumns()],e=>e.reduce((e,t)=>(e[t.id]=t,e),{}),$(e,`debugColumns`,`getAllFlatColumnsById`)),getAllLeafColumns:Q(()=>[n.getAllColumns(),n._getOrderColumnsFn()],(e,t)=>t(e.flatMap(e=>e.getLeafColumns())),$(e,`debugColumns`,`getAllLeafColumns`)),getColumn:e=>n._getAllFlatColumnsById()[e]};Object.assign(n,c);for(let e=0;e<n._features.length;e++){let t=n._features[e];t==null||t.createTable==null||t.createTable(n)}return n}function Cl(){return e=>Q(()=>[e.options.data],t=>{let n={rows:[],flatRows:[],rowsById:{}},r=function(t,i,a){i===void 0&&(i=0);let o=[];for(let c=0;c<t.length;c++){let l=bc(e,e._getRowId(t[c],c,a),t[c],c,i,void 0,a?.id);if(n.flatRows.push(l),n.rowsById[l.id]=l,o.push(l),e.options.getSubRows){var s;l.originalSubRows=e.options.getSubRows(t[c],c),(s=l.originalSubRows)!=null&&s.length&&(l.subRows=r(l.originalSubRows,i+1,l))}}return o};return n.rows=r(t),n},$(e.options,`debugTable`,`getRowModel`,()=>e._autoResetPageIndex()))}function wl(e){let t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=B.useState(()=>({current:Sl(t)})),[r,i]=B.useState(()=>n.current.initialState);return n.current.setOptions(t=>({...t,...e,state:{...r,...e.state},onStateChange:t=>{i(t),e.onStateChange==null||e.onStateChange(t)}})),n.current}function Tl(e,t=14){let n={size:t,"aria-hidden":!0,className:`sheet-type-icon`};switch(e){case`number`:return(0,V.jsx)(I,{...n});case`select`:return(0,V.jsx)(Le,{...n});case`multi-select`:return(0,V.jsx)(x,{...n});case`date`:return(0,V.jsx)(Ie,{...n});case`checkbox`:return(0,V.jsx)(z,{...n});case`url`:return(0,V.jsx)(Ge,{...n});case`email`:return(0,V.jsx)(Fe,{...n});case`phone`:return(0,V.jsx)(Ye,{...n});case`file`:return(0,V.jsx)(qe,{...n});default:return(0,V.jsx)($e,{...n})}}var El=1,Dl=()=>El++,Ol=e=>({columns:[...e.columns],rows:e.rows.map(e=>({id:Dl(),cells:e}))}),kl=e=>({columns:e.columns,rows:e.rows.map(e=>e.cells)}),Al=e=>new Map(e.rows.map((e,t)=>[e.id,t]));function jl(e,t){let n=[...e];for(let{row:e,after:r}of t){let t=r===null?0:n.findIndex(e=>e.id===r)+1;n.splice(t<=0&&r!==null?n.length:t,0,{id:e.id,cells:e.cells})}return n}function Ml(e,t){let{table:n,texts:r}=e;switch(t.kind){case`cells`:{let e=Al(n),i=[...n.rows];for(let r of t.changes){let t=e.get(r.id),a=n.columns.indexOf(r.column);if(t===void 0||a<0)continue;let o=i[t];if(!o)continue;let s=[...o.cells];s[a]=r.after,i[t]={id:o.id,cells:s}}return{table:{columns:n.columns,rows:i},texts:r}}case`insert`:return{table:{columns:n.columns,rows:jl(n.rows,t.rows)},texts:r};case`remove`:{let e=new Set(t.rows.map(e=>e.row.id));return{table:{columns:n.columns,rows:n.rows.filter(t=>!e.has(t.id))},texts:r}}case`order`:{let e=new Map(n.rows.map(e=>[e.id,e])),i=[];for(let n of t.after){let t=e.get(n);t&&(i.push(t),e.delete(n))}return i.push(...e.values()),{table:{columns:n.columns,rows:i},texts:r}}case`insert-column`:{if(n.columns.includes(t.name))return e;let i=Math.max(0,Math.min(t.at,n.columns.length)),a=[...n.columns];return a.splice(i,0,t.name),{table:{columns:a,rows:n.rows.map(e=>{let n=[...e.cells];return n.splice(i,0,t.values.get(e.id)??``),{id:e.id,cells:n}})},texts:r}}case`remove-column`:{let i=n.columns.indexOf(t.name);return i<0?e:{table:{columns:n.columns.filter((e,t)=>t!==i),rows:n.rows.map(e=>({id:e.id,cells:e.cells.filter((e,t)=>t!==i)}))},texts:r}}case`rename-column`:{let i=n.columns.indexOf(t.from);if(i<0||n.columns.includes(t.to))return e;let a=[...n.columns];return a[i]=t.to,{table:{columns:a,rows:n.rows},texts:r}}case`move-column`:{let i=n.columns.indexOf(t.name);if(i<0)return e;let a=Math.max(0,Math.min(t.to,n.columns.length-1)),o=[...n.columns];return o.splice(i,1),o.splice(a,0,t.name),{table:{columns:o,rows:n.rows.map(e=>{let t=[...e.cells],[n]=t.splice(i,1);return t.splice(a,0,n??``),{id:e.id,cells:t}})},texts:r}}case`spec`:return{table:n,texts:{spec:t.after}};case`batch`:return t.edits.reduce(Ml,e)}}function Nl(e){switch(e.kind){case`cells`:return{kind:`cells`,changes:e.changes.map(e=>({...e,before:e.after,after:e.before}))};case`insert`:return{kind:`remove`,rows:e.rows};case`remove`:return{kind:`insert`,rows:e.rows};case`order`:return{kind:`order`,before:e.after,after:e.before};case`insert-column`:return{...e,kind:`remove-column`};case`remove-column`:return{...e,kind:`insert-column`};case`rename-column`:return{kind:`rename-column`,from:e.to,to:e.from};case`move-column`:return{kind:`move-column`,name:e.name,from:e.to,to:e.from};case`spec`:return{kind:`spec`,before:e.after,after:e.before};case`batch`:return{kind:`batch`,edits:[...e.edits].reverse().map(Nl)}}}function Pl(e){switch(e.kind){case`cells`:return e.changes.every(e=>e.before===e.after);case`insert`:case`remove`:return e.rows.length===0;case`order`:return e.before.length===e.after.length&&e.before.every((t,n)=>e.after[n]===t);case`rename-column`:return e.from===e.to;case`move-column`:return e.from===e.to;case`spec`:return e.before===e.after;case`batch`:return e.edits.every(Pl);default:return!1}}function Fl(e,t){let n=null,r=[];for(let i of e.rows)t.has(i.id)&&r.push({row:i,after:n}),n=i.id;return{kind:`remove`,rows:r}}function Il(e,t){let n=t.map(t=>e.columns.indexOf(t));return e.rows.map(e=>n.map(t=>e.cells[t]??``).join(`\0`))}function Ll(e,t){let n={columns:[...t.columns],rows:t.rows.map(e=>({id:0,cells:e}))},r=e.columns.filter(e=>n.columns.includes(e)),i=Il(e,r),a=Il(n,r),o=s(i,a),c=[],l=new Set,u=r.map(t=>[e.columns.indexOf(t),n.columns.indexOf(t)]),d=(t,r)=>{if(u.length<=1)return!0;let i=e.rows[t]?.cells??[],a=n.rows[r]?.cells??[],o=u.filter(([e,t])=>(i[e]??``)===(a[t]??``)).length;return o>0&&o*2>=u.length},f=[],p=-1,m=-1;for(let[e,t]of[...o,[i.length,a.length]]){let n=m+1;for(let r=p+1;r<e;r++)for(let e=n;e<t;e++)if(d(r,e)){f.push([r,e]),n=e+1;break}e<i.length&&f.push([e,t]),p=e,m=t}for(let[t,i]of f){let a=e.rows[t],o=n.rows[i];if(a&&o){o.id=a.id,l.add(t);for(let t of r){let r=a.cells[e.columns.indexOf(t)]??``,i=o.cells[n.columns.indexOf(t)]??``;r!==i&&c.push({kind:`cell`,id:o.id,column:t,before:r,after:i})}}}for(let e of n.rows)e.id===0&&(e.id=Dl(),c.push({kind:`row-added`,id:e.id}));let h=null;e.rows.forEach((t,n)=>{l.has(n)?h=t.id:c.push({kind:`row-removed`,row:t,after:h,columns:[...e.columns]})});for(let t of n.columns)e.columns.includes(t)||c.push({kind:`column-added`,name:t});return e.columns.forEach((t,r)=>{n.columns.includes(t)||c.push({kind:`column-removed`,name:t,at:r,values:new Map(e.rows.map(e=>[e.id,e.cells[r]??``]))})}),{table:n,changes:c}}function Rl(e,t){switch(e.kind){case`cell`:{let n=t.rows.find(t=>t.id===e.id),r=t.columns.indexOf(e.column);return!n||r<0?void 0:{kind:`cells`,changes:[{id:e.id,column:e.column,before:n.cells[r]??``,after:e.before}]}}case`row-added`:return t.rows.some(t=>t.id===e.id)?Fl(t,new Set([e.id])):void 0;case`row-removed`:{let n=t.columns.map(t=>e.row.cells[e.columns.indexOf(t)]??``);return{kind:`insert`,rows:[{row:{id:e.row.id,cells:n},after:e.after}]}}case`column-added`:{let n=t.columns.indexOf(e.name);return n<0?void 0:{kind:`remove-column`,at:n,name:e.name,values:new Map(t.rows.map(e=>[e.id,e.cells[n]??``]))}}case`column-removed`:return{kind:`insert-column`,at:e.at,name:e.name,values:e.values}}}function zl(e,t){switch(e.kind){case`cells`:return t.kind===`cell`&&e.changes.some(e=>e.id===t.id&&e.column===t.column);case`remove`:return(t.kind===`cell`||t.kind===`row-added`)&&e.rows.some(e=>e.row.id===t.id);case`remove-column`:case`rename-column`:return t.kind===`cell`&&t.column===(`name`in e?e.name:e.from)||t.kind===`column-added`&&t.name===(`name`in e?e.name:e.from);case`batch`:return e.edits.some(e=>zl(e,t));default:return!1}}var Bl=e=>({r0:Math.min(e.anchor.r,e.focus.r),r1:Math.max(e.anchor.r,e.focus.r),c0:Math.min(e.anchor.c,e.focus.c),c1:Math.max(e.anchor.c,e.focus.c)}),Vl=(e,t,n)=>t>=e.r0&&t<=e.r1&&n>=e.c0&&n<=e.c1,Hl=e=>({anchor:e,focus:e}),Ul=(e,t,n)=>({r:Math.max(0,Math.min(e.r,t-1)),c:Math.max(0,Math.min(e.c,n-1))});function Wl(e,t,n){let{rows:r,cols:i}=n;if(r===0||i===0)return e;let{r:a,c:o}=e.focus;switch(t){case`up`:a=n.jump?0:a-1;break;case`down`:a=n.jump?r-1:a+1;break;case`left`:o=n.jump?0:o-1;break;case`right`:o=n.jump?i-1:o+1;break;case`home`:o=0,n.jump&&(a=0);break;case`end`:o=i-1,n.jump&&(a=r-1);break;case`top`:a=0;break;case`bottom`:a=r-1;break;case`page-up`:a-=n.page;break;case`page-down`:a+=n.page}let s=Ul({r:a,c:o},r,i);return n.extend?{anchor:e.anchor,focus:s}:Hl(s)}function Gl(e,t,n,r){let i=Bl(e);if(i.r0===i.r1&&i.c0===i.c1)return Wl(e,t===`next`?`right`:t===`previous`?`left`:t,{extend:!1,jump:!1,rows:n,cols:r,page:1});let{r:a,c:o}=e.focus,s=t===`next`||t===`previous`,c=t===`next`||t===`down`;return s?(o+=c?1:-1,o>i.c1?(o=i.c0,a=a>=i.r1?i.r0:a+1):o<i.c0&&(o=i.c1,a=a<=i.r0?i.r1:a-1)):(a+=c?1:-1,a>i.r1?(a=i.r0,o=o>=i.c1?i.c0:o+1):a<i.r0&&(a=i.r1,o=o<=i.c0?i.c1:o-1)),{anchor:e.anchor,focus:{r:a,c:o}}}function Kl(e,t,n){let r=new Map(e.rows.map(e=>[e.id,e])),i=t.columns.map(t=>e.columns.indexOf(t)),a=[];for(let e=n.r0;e<=n.r1;e++){let o=r.get(t.rows[e]??-1),s=[];for(let e=n.c0;e<=n.c1;e++)s.push(o?.cells[i[e]??-1]??``);a.push(s)}return Tt(a)}function ql(e,t,n){let r=new Map(e.rows.map(e=>[e.id,e])),i=[];for(let a=n.r0;a<=n.r1;a++){let o=t.rows[a],s=o===void 0?void 0:r.get(o);if(s)for(let r=n.c0;r<=n.c1;r++){let n=t.columns[r];if(n===void 0)continue;let a=s.cells[e.columns.indexOf(n)]??``;a!==``&&i.push({id:s.id,column:n,before:a,after:``})}}return{kind:`cells`,changes:i}}function Jl(e,t){let n=e.type===`text`?t:t.trim();if(Ra(e,n)===void 0)return n;if(e.type===`checkbox`){let e=n.toLowerCase();if([`yes`,`y`,`1`,`✓`,`x`,`checked`,`on`].includes(e))return`true`;if([`no`,`n`,`0`,``,`unchecked`,`off`].includes(e))return`false`}if(e.type===`number`){let e=n.endsWith(`%`),t=Number(n.replace(/[,\s$€£¥%]/g,``));if(n!==``&&Number.isFinite(t))return String(e?t/100:t)}}function Yl(e,t,n,r,i){let a=Et(i.replace(/\r?\n$/,``)),o=new Map,s=0,c=a.length===1&&(a[0]?.length??0)===1,l=c?r.r1-r.r0+1:a.length,u=c?r.c1-r.c0+1:Math.max(0,...a.map(e=>e.length)),d=new Map(e.rows.map(e=>[e.id,e])),f=[],p=[],m=(e,n)=>{let r=W(t,e);if(r.type===`select`||r.type===`multi-select`){let t=r.type===`select`?[n.trim()].filter(e=>e!==``):Ia(n,r.separator),i=new Set((r.options??[]).map(e=>e.name));for(let n of t){if(i.has(n))continue;let t=o.get(e)??[];t.includes(n)||t.push(n),o.set(e,t)}return r.type===`select`?t[0]??``:La(t,r.separator)}return Jl(r,n)};for(let t=0;t<l;t++){let i=a[c?0:t]??[],o=n.rows[r.r0+t],l=o===void 0?void 0:d.get(o);l||(l={id:Dl(),cells:e.columns.map(()=>``)},p.push(l));for(let t=0;t<u;t++){let a=n.columns[r.c0+t];if(a===void 0)continue;let o=m(a,i[c?0:t]??``);if(o===void 0){s+=1;continue}let u=e.columns.indexOf(a);if(p.includes(l)){l.cells[u]=o;continue}let d=l.cells[u]??``;d!==o&&f.push({id:l.id,column:a,before:d,after:o})}}let h=e.rows[e.rows.length-1]?.id??null,g=[];if(f.length>0&&g.push({kind:`cells`,changes:f}),p.length>0){let e=h;g.push({kind:`insert`,rows:p.map(t=>{let n={row:t,after:e};return e=t.id,n})})}return{edit:g.length===1&&g[0]?g[0]:{kind:`batch`,edits:g},skipped:s,options:o}}function Xl(e,t,n,r=1){let i=new Map(e.rows.map(e=>[e.id,e])),a=[],o=Math.max(1,Math.min(r,n.r1-n.r0+1));for(let r=n.c0;r<=n.c1;r++){let s=t.columns[r];if(s===void 0)continue;let c=e.columns.indexOf(s),l=[];for(let e=0;e<o;e++)l.push(i.get(t.rows[n.r0+e]??-1)?.cells[c]??``);for(let e=n.r0+o;e<=n.r1;e++){let r=i.get(t.rows[e]??-1);if(!r)continue;let u=l[(e-n.r0)%o]??``,d=r.cells[c]??``;d!==u&&a.push({id:r.id,column:s,before:d,after:u})}}return{kind:`cells`,changes:a}}var Zl=34,Ql=44;function $l(e){switch(e.type){case`checkbox`:return 96;case`number`:return 132;case`date`:return 150;case`select`:return 160;default:return 200}}var eu=(e,t)=>`${String(e)}:${t}`;function tu(e,t,n,r){let i=[];return r?i.push(`inset 0 0 0 1px var(--sheet-focus)`):e&&Vl(e,t,n)&&(e.r0!==e.r1||e.c0!==e.c1)&&(t===e.r0&&i.push(`inset 0 1px 0 0 var(--sheet-focus)`),t===e.r1&&i.push(`inset 0 -1px 0 0 var(--sheet-focus)`),n===e.c0&&i.push(`inset 1px 0 0 0 var(--sheet-focus)`),n===e.c1&&i.push(`inset -1px 0 0 0 var(--sheet-focus)`)),i.length?i.join(`,`):void 0}var nu=(0,B.forwardRef)(function(e,t){let{spec:n,columns:r,widths:i,fit:a,freeze:o,wrap:s,items:c,rowItems:l,selection:u,editing:d,readOnly:f,found:p,current:m,agentCells:g,agentRows:_,away:v,sorted:y,strings:b,locale:x,on:S}=e,C=e.rowHeight??34,w=(0,B.useRef)(null),[T,E]=(0,B.useState)({}),ee=wl({data:[],columns:(0,B.useMemo)(()=>r.map(e=>({id:e,size:i[e]??W(n,e).width??a?.[e]??$l(W(n,e)),minSize:60,maxSize:1200})),[r,i,n,a]),getCoreRowModel:Cl(),columnResizeMode:`onChange`,state:{columnSizing:T},onColumnSizingChange:E}),te=ee.getState().columnSizingInfo.isResizingColumn,ne=(0,B.useRef)(!1);(0,B.useEffect)(()=>{let e=ne.current;if(ne.current=te,e&&!te){let t=T[e];t!==void 0&&S.resize(e,Math.round(t))}},[te,T,S]),(0,B.useEffect)(()=>{E({})},[i]);let D=r.map(e=>ee.getColumn(e)?.getSize()??i[e]??a?.[e]??$l(W(n,e))),O=Math.min(o,r.length),re=[],ie=72;for(let e=0;e<O;e++)re.push(ie),ie+=D[e]??0;let ae=ie-72,oe=r.slice(O),k=D.slice(O),se=72+D.reduce((e,t)=>e+t,0)+Ql,ce=s.size>0,le=cc({count:c.length,getScrollElement:()=>w.current,estimateSize:()=>C,overscan:12,scrollMargin:34,getItemKey:e=>{let t=c[e];return t===void 0?e:`r:${String(t.row.id)}`},...ce?{measureElement:e=>e.getBoundingClientRect().height}:{}}),ue=cc({horizontal:!0,count:oe.length,getScrollElement:()=>w.current,estimateSize:e=>k[e]??180,overscan:3,scrollMargin:72+ae}),de=k.join(`,`);(0,B.useEffect)(()=>{ue.measure()},[de,ue]),(0,B.useEffect)(()=>{le.measure()},[ce,C,le]);let fe=le.getVirtualItems(),pe=ue.getVirtualItems(),me=pe[0],he=pe[pe.length-1],ge=me?me.start-(72+ae):0,_e=pe.map(e=>e.index),ve=he?k.slice(he.index+1).reduce((e,t)=>e+t,0):0;(0,B.useImperativeHandle)(t,()=>({reveal:e=>{let t=l[e.r];t!==void 0&&le.scrollToIndex(t,{align:`auto`});let n=w.current;if(!n||e.c<O)return;let r=72+D.slice(0,e.c).reduce((e,t)=>e+t,0),i=D[e.c]??0,a=n.scrollLeft+72+ae,o=n.scrollLeft+n.clientWidth;r<a?n.scrollLeft=r-72-ae:r+i>o&&(n.scrollLeft=r+i-n.clientWidth)},page:()=>Math.max(1,Math.floor(((w.current?.clientHeight??400)-34)/C)-1),focus:()=>{w.current?.focus({preventScroll:!0})},element:()=>w.current}),[l,le,O,D,ae,C]);let[ye,be]=(0,B.useState)(!1);(0,B.useEffect)(()=>{let e=w.current;if(!e)return;let t=()=>{be(e.scrollLeft>0)};return t(),e.addEventListener(`scroll`,t,{passive:!0}),()=>{e.removeEventListener(`scroll`,t)}},[]);let A=u?Bl(u):void 0,xe=u?.focus,j=(0,B.useRef)(void 0),[Ce,we]=(0,B.useState)(),[M,N]=(0,B.useState)(),[P,Te]=(0,B.useState)(),[Ee,De]=(0,B.useState)(),Oe=(e,t)=>{let n=document.elementFromPoint(e,t)?.closest(`[data-cell]`);if(!n)return;let r=Number(n.dataset.r),i=Number(n.dataset.c);return Number.isFinite(r)&&Number.isFinite(i)?{r,c:i}:void 0},ke=(0,B.useRef)(void 0),je=(0,B.useRef)({x:0,y:0}),Me=(0,B.useCallback)(()=>{let e=w.current;if(!e||!j.current){ke.current=void 0;return}let t=e.getBoundingClientRect(),{x:n,y:r}=je.current,i=r<t.top+34+24?-12:r>t.bottom-24?12:0,a=n<t.left+72+ae+24?-12:n>t.right-24?12:0;if(a!==0||i!==0){e.scrollBy(a,i);let t=j.current;if(t.kind===`select`){let e=Oe(n-a*2,r-i*2);e&&S.select({anchor:t.anchor,focus:e})}}ke.current=window.requestAnimationFrame(Me)},[ae,S]);(0,B.useEffect)(()=>{let e=e=>{let t=j.current;if(t){if(je.current={x:e.clientX,y:e.clientY},ke.current??=window.requestAnimationFrame(Me),t.kind===`select`){let n=Oe(e.clientX,e.clientY);n&&S.select({anchor:t.anchor,focus:n})}else if(t.kind===`fill`){let n=Oe(e.clientX,e.clientY);n&&(t.to=Math.max(t.box.r1,n.r),Te(t.to))}else if(t.kind===`column`){if(!t.moved&&Math.abs(e.clientX-t.startX)<5)return;t.moved=!0;let n=w.current?.querySelectorAll(`[data-head]`)??[],i=r.length;for(let t of n){let n=t.getBoundingClientRect(),r=Number(t.dataset.c);e.clientX<n.left+n.width/2&&(i=Math.min(i,r))}t.to=i,we(i)}else{if(!t.moved&&Math.abs(e.clientY-t.startY)<5)return;t.moved=!0;let n=document.elementFromPoint(e.clientX,e.clientY)?.closest(`[data-row-id]`);if(!n)return;let r=Number(n.dataset.rowId),i=n.getBoundingClientRect(),a=e.clientY>i.top+i.height/2;if(N({id:r,after:a}),!a)t.before=r;else{let e=c.findIndex(e=>e.row.id===r);t.before=c[e+1]?.row.id??null}}}},t=()=>{let e=j.current;if(j.current=void 0,ke.current!==void 0&&window.cancelAnimationFrame(ke.current),ke.current=void 0,e){if(e.kind===`fill`&&e.to>e.box.r1&&S.fill(e.box,e.to),e.kind===`column`&&e.moved){let t=r.indexOf(e.name),n=e.to>t?e.to-1:e.to;n!==t&&S.moveColumn(e.name,n)}e.kind===`rows`&&e.moved&&!e.ids.includes(e.before??-1)&&S.moveRows(e.ids,e.before),Te(void 0),we(void 0),N(void 0)}};return window.addEventListener(`pointermove`,e),window.addEventListener(`pointerup`,t),window.addEventListener(`pointercancel`,t),()=>{window.removeEventListener(`pointermove`,e),window.removeEventListener(`pointerup`,t),window.removeEventListener(`pointercancel`,t)}},[Me,r,c,S]);let Ne=(e,t)=>{e.button===0&&(e.target.closest(`button, a, input, textarea, select, .sheet-editor`)||(e.preventDefault(),S.focusGrid(),e.shiftKey&&u?(S.select({anchor:u.anchor,focus:t}),j.current={kind:`select`,anchor:u.anchor}):(S.select({anchor:t,focus:t}),j.current={kind:`select`,anchor:t})))},Fe=e=>e<O?{width:D[e],left:re[e],position:`sticky`,zIndex:2}:{width:D[e]},Ie=(t,i)=>{let o=W(n,t),s=ee.getHeaderGroups()[0]?.headers.find(e=>e.column.id===t),c=S.columnActions(t),d=e.sortedBy?.column===t?e.sortedBy.desc?`desc`:`asc`:void 0,p=e.filtered?.has(t)===!0;return(0,V.jsxs)(`div`,{role:`columnheader`,className:`sheet-head`,"data-head":``,"data-c":i,"data-type":o.type,"data-frozen":i<O?``:void 0,"data-last-frozen":i===O-1?``:void 0,"data-drop":Ce===i?`before`:Ce===i+1&&i===r.length-1?`after`:void 0,"data-selected":A&&A.c0<=i&&i<=A.c1?``:void 0,style:Fe(i),onPointerDown:e=>{e.currentTarget.contains(e.target)&&(e.button!==0||f||e.target.closest(`button, [data-resizer]`)||(j.current={kind:`column`,name:t,startX:e.clientX,moved:!1,to:i}))},onClick:e=>{if(!e.currentTarget.contains(e.target)||e.target.closest(`button, [data-resizer]`))return;let t=Math.max(0,l.length-1);e.shiftKey&&u?S.select({anchor:{r:0,c:u.anchor.c},focus:{r:t,c:i}}):S.select({anchor:{r:0,c:i},focus:{r:t,c:i}}),S.focusGrid()},onDoubleClick:e=>{e.currentTarget.contains(e.target)&&(e.target.closest(`button, [data-resizer]`)||f||c.rename())},onContextMenu:e=>{e.currentTarget.contains(e.target)&&(e.preventDefault(),!f&&(xs(),De(t)))},children:[Tl(o.type,13),e.renaming===t?(0,V.jsx)(ru,{name:t,taken:e.allColumns,strings:b,onDone:e=>{S.rename(t,e)}}):(0,V.jsx)(`span`,{className:`sheet-head-name`,title:t,children:t}),e.keyColumn===t&&(0,V.jsx)(`span`,{className:`sheet-head-key`,title:b.column.key,"aria-label":b.column.key,children:(0,V.jsx)(L,{size:12,"aria-hidden":!0})}),e.headerTool&&!f?e.headerTool(t,(0,V.jsx)(`button`,{type:`button`,"data-menu":``,className:`sheet-head-menu`,"data-on":d||p?``:void 0,"data-testid":`sheet-head-filter-${String(i)}`,"aria-label":b.auto.button(t),title:b.auto.button(t),children:p?(0,V.jsx)(He,{size:12,"aria-hidden":!0}):d===`desc`?(0,V.jsx)(Ae,{size:13,"aria-hidden":!0}):d===`asc`?(0,V.jsx)(Pe,{size:13,"aria-hidden":!0}):(0,V.jsx)(h,{size:13,"aria-hidden":!0})})):null,(0,V.jsx)(zs,{open:Ee===t,onOpenChange:e=>{De(e?t:void 0)},column:o,canHide:r.length>1,strings:b,actions:c}),s&&(0,V.jsx)(`span`,{"data-resizer":``,className:`sheet-resizer`,"data-on":s.column.getIsResizing()?``:void 0,onPointerDown:e=>{e.stopPropagation(),s.getResizeHandler()(e.nativeEvent)},onMouseDown:e=>{e.stopPropagation()},onDoubleClick:()=>{S.resize(t,a?.[t]??$l(o))}})]},t)},Le=(t,r,i)=>{let a=W(n,r),o=e.allColumns.indexOf(r),c=t.row.cells[o]??``,l=eu(t.row.id,r),u=xe?.r===t.r&&xe.c===i,h=d?.cell.r===t.r&&d.cell.c===i&&!f,_=A!==void 0&&Vl(A,t.r,i),y=P!==void 0&&A?.c0!==void 0&&i>=A.c0&&i<=A.c1&&t.r>A.r1&&t.r<=P,C=!f&&!d&&t.r===A?.r1&&i===A.c1,w=g.get(l);return(0,V.jsxs)(`div`,{id:`cell-${At({row:t.index,column:o})}`,role:`gridcell`,className:`sheet-cell`,"data-cell":``,"data-r":t.r,"data-c":i,"data-type":a.type,"data-frozen":i<O?``:void 0,"data-last-frozen":i===O-1?``:void 0,"data-wrap":s.has(r)?``:void 0,"data-sel":_&&!u?``:void 0,"data-fill":y?``:void 0,"data-found":p.has(l)?m===l?`current`:``:void 0,"data-agent":w===void 0?void 0:v?.has(l)?`away`:``,"data-editing":h?``:void 0,"data-drop-file":e.dropping?.r===t.r&&e.dropping.c===i?``:void 0,"aria-selected":_,style:{...Fe(i),boxShadow:tu(A,t.r,i,u)},onPointerDown:e=>{Ne(e,{r:t.r,c:i})},onDoubleClick:()=>{!f&&a.type!==`checkbox`&&S.edit({r:t.r,c:i})},onContextMenu:e=>{S.contextMenu(e,{r:t.r,c:i})},children:[(0,V.jsx)(Ps,{column:a,value:c,locale:x,strings:b,...e.fileUrl?{fileUrl:e.fileUrl}:{},...e.dir?{dir:e.dir}:{},...f?{}:{onToggle:()=>{S.toggle({r:t.r,c:i})}},onOpen:e=>{S.openFile({r:t.r,c:i},e)}}),h&&(0,V.jsx)(`div`,{className:`sheet-cell-edit`,"data-type":a.type,children:(0,V.jsx)(Is,{column:a,value:c,...d.initial===void 0?{}:{initial:d.initial},strings:b,locale:x,onCommit:S.commit,onCancel:S.cancel,onAddOption:e=>{S.addOption(r,e)}})}),C&&(0,V.jsx)(`span`,{className:`sheet-fill-handle`,onPointerDown:e=>{e.stopPropagation(),e.preventDefault(),j.current={kind:`fill`,box:A,to:A.r1}}})]},r)},Re=e=>{let t=A!==void 0&&A.r0<=e.r&&e.r<=A.r1&&A.c0===0&&A.c1===r.length-1;return(0,V.jsxs)(`div`,{className:`sheet-gutter`,"data-agent":_.has(e.row.id)?v?.has(`row:${String(e.row.id)}`)?`away`:``:void 0,"data-selected":t?``:void 0,onPointerDown:t=>{if(t.button!==0||t.target.closest(`button`))return;t.preventDefault(),S.focusGrid();let n=Math.max(0,r.length-1);t.shiftKey&&u?S.select({anchor:{r:u.anchor.r,c:0},focus:{r:e.r,c:n}}):S.select({anchor:{r:e.r,c:0},focus:{r:e.r,c:n}})},onContextMenu:t=>{S.contextMenu(t,{r:e.r,c:0})},children:[f||y?(0,V.jsx)(`span`,{className:`sheet-grip`,"data-off":``,"aria-hidden":!0}):(0,V.jsx)(`span`,{className:`sheet-grip`,"aria-hidden":!0,onPointerDown:n=>{n.stopPropagation(),n.preventDefault();let r=t?c.flatMap(e=>e.r>=A.r0&&e.r<=A.r1?[e.row.id]:[]):[e.row.id];j.current={kind:`rows`,ids:r,startY:n.clientY,moved:!1,before:e.row.id}},children:(0,V.jsx)(Ue,{size:12})}),(0,V.jsx)(`span`,{className:`sheet-row-number`,title:e.index===e.r?void 0:b.row.inFile(e.index+1),children:e.r+1}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-expand`,"aria-label":b.row.expand,title:b.row.expand,onClick:()=>{S.expand(e.row.id)},children:(0,V.jsx)(Ke,{size:11,"aria-hidden":!0})})]})},ze=e=>e>0?(0,V.jsx)(`div`,{className:`sheet-spacer`,style:{width:e},"aria-hidden":!0}):null;return(0,V.jsxs)(V.Fragment,{children:[ye&&O>0&&(0,V.jsx)(`div`,{className:`sheet-frozen-edge`,"aria-hidden":!0,style:{left:72+ae,height:Math.min(34+c.length*C,w.current?.clientHeight??1/0)}}),(0,V.jsx)(`div`,{ref:w,className:`sheet-grid`,role:`grid`,"aria-rowcount":l.length,"aria-colcount":r.length,tabIndex:0,"data-testid":`sheet-grid`,onFocus:e=>{e.target===e.currentTarget&&S.focusGrid()},"data-dragging":j.current?``:void 0,children:(0,V.jsxs)(`div`,{className:`sheet-canvas`,style:{width:se},children:[(0,V.jsxs)(`div`,{className:`sheet-header`,role:`row`,style:{height:34},children:[(0,V.jsx)(`div`,{className:`sheet-corner`,"aria-hidden":!0}),r.slice(0,O).map((e,t)=>Ie(e,t)),ze(ge),_e.map(e=>Ie(oe[e]??``,e+O)),ze(ve),(0,V.jsx)(`button`,{type:`button`,className:`sheet-add-column`,"aria-label":b.column.add,title:b.column.add,disabled:f,onClick:S.addColumn,children:(0,V.jsx)(Se,{size:14,"aria-hidden":!0})})]}),(0,V.jsx)(`div`,{className:`sheet-body`,style:{height:le.getTotalSize()-0},children:fe.map(e=>{let t=c[e.index];if(!t)return null;let n=e.start-34;return(0,V.jsxs)(`div`,{role:`row`,"data-index":e.index,"data-row-id":t.row.id,"data-drop":M?.id===t.row.id?M.after?`after`:`before`:void 0,"data-editing":d?.cell.r===t.r?``:void 0,"data-added":_.has(t.row.id)?v?.has(`row:${String(t.row.id)}`)?`away`:``:void 0,ref:ce?le.measureElement:void 0,className:`sheet-row`,style:{transform:`translateY(${String(n)}px)`,...ce?{minHeight:C}:{height:C}},children:[Re(t),r.slice(0,O).map((e,n)=>Le(t,e,n)),ze(ge),_e.map(e=>Le(t,oe[e]??``,e+O)),ze(ve)]},e.key)})}),!f&&(0,V.jsxs)(`button`,{type:`button`,className:`sheet-new-row`,style:{height:Zl},"data-testid":`sheet-new-row`,onClick:S.addRow,children:[(0,V.jsx)(Se,{size:14,"aria-hidden":!0}),b.row.newRow]}),e.empty]})})]})});function ru({name:e,taken:t,strings:n,onDone:r}){let[i,a]=(0,B.useState)(e),o=(0,B.useRef)(!1),s=i.trim(),c=s===``?n.column.empty:s!==e&&t.includes(s)?n.column.taken:void 0,l=t=>{o.current||(o.current=!0,r(t===void 0||t===e?void 0:t))};return(0,V.jsx)(`input`,{className:`sheet-head-input`,value:i,"aria-label":n.column.name,"aria-invalid":c!==void 0,title:c,"data-testid":`sheet-head-input`,spellCheck:!1,ref:e=>{e&&document.activeElement!==e&&!o.current&&(e.focus(),e.select())},onPointerDown:e=>{e.stopPropagation()},onClick:e=>{e.stopPropagation()},onDoubleClick:e=>{e.stopPropagation()},onChange:e=>{a(e.target.value)},onKeyDown:e=>{e.stopPropagation(),!e.nativeEvent.isComposing&&(e.key===`Enter`?(e.preventDefault(),c===void 0&&l(s)):e.key===`Escape`&&(e.preventDefault(),l(void 0)))},onBlur:()=>{l(c===void 0?s:void 0)}})}var iu=120;function au({row:e,columns:t,allColumns:n,spec:r,number:i,total:a,title:o,readOnly:s,strings:c,locale:l,fileUrl:u,dir:d,onChange:f,onAddOption:p,onOpenFile:m,onAddFiles:g,onStep:v,onClose:y}){let[b,x]=(0,B.useState)(),S=[...t,...n.filter(e=>!t.includes(e))];return(0,V.jsxs)(`aside`,{className:`sheet-panel`,"aria-label":c.row.record,"data-testid":`sheet-record`,children:[(0,V.jsxs)(`header`,{className:`sheet-panel-head`,children:[(0,V.jsxs)(`span`,{className:`sheet-panel-titles`,children:[(0,V.jsx)(`span`,{className:`sheet-panel-title`,"data-empty":o.trim()===``?``:void 0,children:o.trim()===``?c.untitled:o}),(0,V.jsx)(`span`,{className:`sheet-panel-number`,children:c.row.of(i,a)})]}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":c.row.previous,onClick:()=>{v(-1)},children:(0,V.jsx)(_,{size:14,"aria-hidden":!0})}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":c.row.next,onClick:()=>{v(1)},children:(0,V.jsx)(h,{size:14,"aria-hidden":!0})}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":c.row.close,onClick:y,children:(0,V.jsx)(C,{size:14,"aria-hidden":!0})})]}),(0,V.jsx)(`dl`,{className:`sheet-record`,children:S.map((i,a)=>{let o=W(r,i),h=e.cells[n.indexOf(i)]??``,_=b===i&&!s;return(0,V.jsxs)(`div`,{className:`sheet-record-field`,"data-hidden":t.includes(i)?void 0:``,"data-first-hidden":a===t.length&&a>0?``:void 0,"data-label":a===t.length&&a>0?c.row.hiddenFields:void 0,children:[(0,V.jsxs)(`dt`,{children:[Tl(o.type,13),(0,V.jsx)(`span`,{children:i})]}),(0,V.jsxs)(`dd`,{"data-type":o.type,onClick:()=>{!s&&o.type!==`checkbox`&&x(i)},children:[_?(0,V.jsx)(Is,{column:o,value:h,strings:c,locale:l,inline:!0,onCommit:e=>{f(i,e),x(void 0)},onCancel:()=>{x(void 0)},onAddOption:e=>{p(i,e)}}):(0,V.jsx)(Ps,{column:o,value:h,locale:l,strings:c,...u?{fileUrl:u}:{},...d?{dir:d}:{},...o.type===`file`?{height:iu}:{},...m?{onOpen:e=>{m(i,e)}}:{},...s?{}:{onToggle:()=>{f(i,h.trim().toLowerCase()===`true`?`false`:`true`)}}}),!_&&h===``&&o.type!==`checkbox`&&!(o.type===`file`&&g)&&(0,V.jsx)(`span`,{className:`sheet-record-empty`,children:`—`}),!_&&o.type===`file`&&g&&(0,V.jsxs)(`button`,{type:`button`,className:`sheet-record-add`,onClick:e=>{e.stopPropagation(),g(i)},children:[(0,V.jsx)(qe,{size:13,"aria-hidden":!0}),c.files.add]})]})]},i)})})]})}function ou(e,t,n=4){if(e.type!==`number`||e.number?.decimals!==void 0)return;let r=e.number?.style??`plain`;if(r===`currency`)return;let i=r===`percent`?100:1,a=10**n,o=0;for(let e of t){let t=Na(e);if(t===void 0)continue;let r=String(Math.round(t*i*a)/a),s=r.indexOf(`.`);if(!(s<0||r.includes(`e`))&&(o=Math.max(o,r.length-s-1),o>=n))return n}return o}function su(e,t){let n;return t.columns.forEach((r,i)=>{let a=W(e,r),o=ou(a,t.rows.map(e=>e.cells[i]??``));o!==void 0&&(n??={...e.columns},n[r]={...a,number:{style:a.number?.style??`plain`,thousands:a.number?.thousands??!0,...a.number?.currency===void 0?{}:{currency:a.number.currency},decimals:o}})}),n?{...e,columns:n}:e}function cu(e,t,n,r,i){if((r.r1-r.r0+1)*(r.c1-r.c0+1)>2e6)return;let a=new Map(e.rows.map(e=>[e.id,e])),o=0,s=0,c=0,l;for(let i=r.c0;i<=r.c1;i++){let u=n.columns[i];if(u===void 0)continue;let d=e.columns.indexOf(u),f=W(t,u);for(let e=r.r0;e<=r.r1;e++){let t=n.rows[e],r=t===void 0?``:a.get(t)?.cells[d]??``;if(Ma(r)||(o++,f.type!==`number`))continue;let i=Na(r);i!==void 0&&(s++,c+=i,l=l===void 0||l===u?u:null)}}if(s===0||typeof l!=`string`)return{count:o,numbers:s};let u=W(t,l),d=e=>Ga(u,String(e),i),f=10**((u.number?.decimals??2)+(u.number?.style===`percent`?2:0));return{count:o,numbers:s,sum:d(c),average:d(Math.round(c/s*f)/f)}}function lu({change:e,at:t,agent:n,spec:r,locale:i,strings:a,onEnter:o,onLeave:s,onKeep:c,onUndo:l}){let u=e.away?a.review.away:e.kind===`row-added`?a.review.added(n):a.review.changed(n);return(0,V.jsxs)(`div`,{className:`sheet-review-card`,role:`dialog`,"aria-label":u,"data-away":e.away?``:void 0,"data-testid":`sheet-review-card`,style:{left:t.left,top:t.top},onPointerEnter:o,onPointerLeave:s,onPointerDown:e=>{e.stopPropagation()},children:[(0,V.jsxs)(`p`,{className:`sheet-review-card-who`,children:[(0,V.jsx)(`span`,{className:`sheet-review-card-dot`,"aria-hidden":!0}),u]}),e.kind===`cell`&&(0,V.jsxs)(`p`,{className:`sheet-review-card-was`,children:[(0,V.jsx)(`span`,{children:a.review.was}),(0,V.jsx)(`del`,{children:e.before===``?a.review.empty:Ga(W(r,e.column),e.before,i)})]}),(0,V.jsxs)(`div`,{className:`sheet-review-card-actions`,children:[(0,V.jsxs)(`button`,{type:`button`,onClick:l,children:[(0,V.jsx)(S,{size:13,"aria-hidden":!0}),a.review.undo]}),(0,V.jsxs)(`button`,{type:`button`,"data-keep":``,onClick:c,children:[(0,V.jsx)(g,{size:13,"aria-hidden":!0}),a.review.keep]})]})]})}var uu=(e,t,n)=>[e>0?`${String(e)} ${e===1?`Zelle`:`Zellen`}`:``,t>0?`${String(t)} ${t===1?`Zeile`:`Zeilen`}`:``,n>0?`${String(n)} ${n===1?`Spalte`:`Spalten`}`:``].filter(e=>e!==``).join(`, `),du={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Wird geöffnet …`,unreadable:`Diese Tabelle kann gerade nicht bearbeitet werden: ihre Datei ist kein CSV, das eine Tabelle lesen kann. Hier ist, was nicht stimmt.`,readOnlyLarge:e=>`Diese Tabelle ist ${e} MB groß und wird hier nur angezeigt, nicht bearbeitet.`,untitled:`Ohne Titel`,saved:`Gesichert`,saving:`Wird gesichert …`,unsaved:`Nicht gesichert`,failed:`Nicht gesichert`,rows:(e,t)=>e===t?`${t.toLocaleString(`de`)} ${t===1?`Zeile`:`Zeilen`}`:`${e.toLocaleString(`de`)} von ${t.toLocaleString(`de`)} Zeilen`,find:`Suchen`,findPlaceholder:`In der Tabelle suchen`,matches:e=>e===1?`1 Treffer`:`${String(e)} Treffer`,types:{text:`Text`,number:`Zahl`,select:`Dropdownliste`,"multi-select":`Mehrfachauswahl`,date:`Datum`,checkbox:`Kontrollkästchen`,url:`Link`,email:`E-Mail`,phone:`Telefon`,file:`Datei`},auto:{button:e=>`${e} sortieren und filtern`,sortAsc:{text:`Von A bis Z sortieren`,number:`Nach Größe sortieren (aufsteigend)`,date:`Vom ältesten zum neuesten sortieren`,options:`In Reihenfolge der Optionen sortieren`},sortDesc:{text:`Von Z bis A sortieren`,number:`Nach Größe sortieren (absteigend)`,date:`Vom neuesten zum ältesten sortieren`,options:`In umgekehrter Reihenfolge der Optionen sortieren`},search:`Suchen`,selectAll:`(Alles auswählen)`,selectFound:`(Alle Suchergebnisse auswählen)`,blanks:`(Leere)`,checked:`Aktiviert`,unchecked:`Nicht aktiviert`,hasFile:`Mit Datei`,more:e=>`${e.toLocaleString(`de`)} weitere. Such danach, um sie zu finden.`,none:`Keine passenden Werte.`,clear:`Filter löschen`,ok:`OK`},look:{sorted:e=>`Sortiert nach ${e}`,filtered:e=>e.length===1?`Gefiltert nach ${e[0]??``}`:`Gefiltert nach ${String(e.length)} Spalten`,hidden:e=>e===1?`1 Spalte ausgeblendet`:`${String(e)} Spalten ausgeblendet`,clear:`Löschen`,note:`Nur du siehst diese Sortierung und diesen Filter.`},replace:{label:`Ersetzen`,with:`Ersetzen durch`,one:`Ersetzen`,all:`Alle ersetzen`,done:e=>`In ${String(e)} ${e===1?`Zelle`:`Zellen`} ersetzt.`},stats:{average:`Mittelwert`,count:`Anzahl`,sum:`Summe`},column:{name:`Spaltenname`,key:`Schlüsselspalte: Jede Zeile hat einen eigenen Wert`,add:`Spalte hinzufügen`,rename:`Umbenennen`,format:`Format`,formats:{text:`Text`,number:`Zahl`,currency:`Währung`,percent:`Prozent`,date:`Datum`,checkbox:`Kontrollkästchen`,list:`Dropdownliste`,file:`Anhang`},addOption:`Option hinzufügen`,newOption:e=>`„${e}“ hinzufügen`,confirm:`Löschen`,cancel:`Abbrechen`,hide:`Spalte ausblenden`,insertLeft:`Spalte links einfügen`,insertRight:`Spalte rechts einfügen`,remove:`Spalte löschen`,removeAsk:(e,t)=>`„${e}“ und ${t===1?`ihren`:`ihre`} ${t.toLocaleString(`de`)} ${t===1?`Wert`:`Werte`} löschen? Du kannst es widerrufen.`,taken:`Eine andere Spalte hat diesen Namen.`,empty:`Eine Spalte braucht einen Namen.`,newName:e=>e===1?`Spalte`:`Spalte ${String(e)}`},row:{numbered:e=>`Zeile ${String(e)}`,inFile:e=>`Zeile ${String(e)} in der Datei`,of:(e,t)=>`Zeile ${String(e)} von ${String(t)}`,hiddenFields:`Ausgeblendete Spalten`,insertAbove:`Zeile oberhalb einfügen`,insertBelow:`Zeile unterhalb einfügen`,remove:e=>e===1?`Zeile löschen`:`${String(e)} Zeilen löschen`,expand:`Zeile öffnen`,newRow:`Neue Zeile`,record:`Zeile`,previous:`Vorherige Zeile`,next:`Nächste Zeile`,close:`Schließen`},cell:{copy:`Kopieren`,cut:`Ausschneiden`,paste:`Einfügen`,clear:`Löschen`,clearContents:`Inhalte löschen`,notNumber:`Keine Zahl. Schreib Ziffern, mit Punkt für Dezimalstellen: 1234.5`,notDate:`Kein Datum. Schreib 2026-10-14 oder 2026-10-14T09:30`,notEmail:`Keine E-Mail-Adresse`,notUrl:`Eine Adresse enthält keine Leerzeichen`,open:`Öffnen`,left:e=>e===1?`1 Wert passte nicht in seine Spalte und wurde ausgelassen.`:`${String(e)} Werte passten nicht in ihre Spalten und wurden ausgelassen.`,pasteHint:`Mit ⌘V einfügen.`},files:{notFound:`Nicht gefunden`,insert:`Datei einfügen …`,add:`Datei hinzufügen`,adding:e=>e===1?`1 Datei wird hinzugefügt …`:`${String(e)} Dateien werden hinzugefügt …`,tooLarge:(e,t)=>`${e} ist größer als ${String(t)} MB und wurde nicht hinzugefügt.`,failed:e=>`${e} konnte nicht hinzugefügt werden.`,notHere:`Nur eine Anhangspalte enthält Dateien. Stell das Format der Spalte zuerst auf Anhang.`,remove:`Aus Zelle entfernen`,of:(e,t)=>`${String(e)} von ${String(t)}`,previous:`Vorherige Datei`,next:`Nächste Datei`,open:`In neuem Tab öffnen`,close:`Schließen`},review:{count:(e,t,n,r)=>`${e} hat ${uu(t,n,r)} geändert`,keepAll:`Alle behalten`,undoAll:`Alle widerrufen`,keep:`Behalten`,undo:`Widerrufen`,was:`Vorher`,added:e=>`Hinzugefügt von ${e}`,changed:e=>`Geändert von ${e}`,away:`Geändert seit deinem letzten Blick`,countAway:(e,t,n)=>`Seit deinem letzten Blick: ${uu(e,t,n)} geändert`,empty:`leer`,next:`Weiter`,previous:`Zurück`,position:(e,t)=>`${String(e)} von ${String(t)}`,conflicts:e=>`${String(e)} ${e===1?`Zelle wurde`:`Zellen wurden`} von euch beiden geändert: Deine Werte wurden behalten.`},date:{placeholder:`z. B. 2026-10-14`,today:`Heute`,previousMonth:`Vorheriger Monat`,nextMonth:`Nächster Monat`,clear:`Löschen`,addTime:`Uhrzeit hinzufügen`,removeTime:`Uhrzeit entfernen`,time:`Uhrzeit`},empty:{title:`Noch keine Zeilen`,addRow:`Zeile hinzufügen`,paste:`Zeilen einfügen`,pasteHint:`Kopiere Zeilen in Excel oder Google Sheets und drück dann hier ⌘V.`,importFile:`Datei importieren`,noMatch:`Keine Zeilen anzuzeigen`,noMatchBody:`Der Filter blendet alle Zeilen aus.`,clearFilter:`Filter löschen`}},fu=(e,t,n)=>[e>0?`${String(e)} ${e===1?`cell`:`cells`}`:``,t>0?`${String(t)} ${t===1?`row`:`rows`}`:``,n>0?`${String(n)} ${n===1?`column`:`columns`}`:``].filter(e=>e!==``).join(`, `),pu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Opening…`,unreadable:`This sheet cannot be edited right now: its file is not CSV a sheet can read. Here is what is wrong.`,readOnlyLarge:e=>`This sheet is ${e} MB: it is shown, not edited, here.`,untitled:`Untitled`,saved:`Saved`,saving:`Saving…`,unsaved:`Unsaved`,failed:`Not saved`,rows:(e,t)=>e===t?`${t.toLocaleString(`en`)} ${t===1?`row`:`rows`}`:`${e.toLocaleString(`en`)} of ${t.toLocaleString(`en`)} rows`,find:`Find`,findPlaceholder:`Find in the sheet`,matches:e=>e===1?`1 match`:`${String(e)} matches`,types:{text:`Text`,number:`Number`,select:`Dropdown list`,"multi-select":`List of several`,date:`Date`,checkbox:`Checkbox`,url:`Link`,email:`Email`,phone:`Phone`,file:`File`},auto:{button:e=>`Sort and filter ${e}`,sortAsc:{text:`Sort A to Z`,number:`Sort smallest to largest`,date:`Sort oldest to newest`,options:`Sort in option order`},sortDesc:{text:`Sort Z to A`,number:`Sort largest to smallest`,date:`Sort newest to oldest`,options:`Sort in reverse option order`},search:`Search`,selectAll:`(Select all)`,selectFound:`(Select all search results)`,blanks:`(Blanks)`,checked:`Checked`,unchecked:`Unchecked`,hasFile:`Has a file`,more:e=>`${e.toLocaleString(`en`)} more. Search to find them.`,none:`No values match.`,clear:`Clear filter`,ok:`OK`},look:{sorted:e=>`Sorted by ${e}`,filtered:e=>e.length===1?`Filtered by ${e[0]??``}`:`Filtered by ${String(e.length)} columns`,hidden:e=>e===1?`1 column hidden`:`${String(e)} columns hidden`,clear:`Clear`,note:`Only you see this sort and filter.`},replace:{label:`Replace`,with:`Replace with`,one:`Replace`,all:`Replace all`,done:e=>`Replaced in ${String(e)} ${e===1?`cell`:`cells`}.`},stats:{average:`Average`,count:`Count`,sum:`Sum`},column:{name:`Column name`,key:`Key column: each row's value is its own`,add:`Add a column`,rename:`Rename`,format:`Format`,formats:{text:`Text`,number:`Number`,currency:`Currency`,percent:`Percent`,date:`Date`,checkbox:`Checkbox`,list:`Dropdown list`,file:`Attachment`},addOption:`Add an option`,newOption:e=>`Add “${e}”`,confirm:`Delete`,cancel:`Cancel`,hide:`Hide column`,insertLeft:`Insert column left`,insertRight:`Insert column right`,remove:`Delete column`,removeAsk:(e,t)=>`Delete “${e}” and its ${t.toLocaleString(`en`)} ${t===1?`value`:`values`}? You can undo it.`,taken:`Another column has this name.`,empty:`A column needs a name.`,newName:e=>e===1?`Column`:`Column ${String(e)}`},row:{numbered:e=>`Row ${String(e)}`,inFile:e=>`Row ${String(e)} in the file`,of:(e,t)=>`Row ${String(e)} of ${String(t)}`,hiddenFields:`Hidden columns`,insertAbove:`Insert row above`,insertBelow:`Insert row below`,remove:e=>e===1?`Delete row`:`Delete ${String(e)} rows`,expand:`Open row`,newRow:`New row`,record:`Row`,previous:`Previous row`,next:`Next row`,close:`Close`},cell:{copy:`Copy`,cut:`Cut`,paste:`Paste`,clear:`Clear`,clearContents:`Clear contents`,notNumber:`Not a number. Write digits, with a point for decimals: 1234.5`,notDate:`Not a date. Write 2026-10-14, or 2026-10-14T09:30`,notEmail:`Not an email address`,notUrl:`An address has no spaces`,open:`Open`,left:e=>e===1?`1 value did not fit its column and was left out.`:`${String(e)} values did not fit their columns and were left out.`,pasteHint:`Use ⌘V to paste.`},files:{notFound:`Not found`,insert:`Insert file…`,add:`Add file`,adding:e=>e===1?`Adding 1 file…`:`Adding ${String(e)} files…`,tooLarge:(e,t)=>`${e} is over ${String(t)} MB and was not added.`,failed:e=>`${e} could not be added.`,notHere:`Only an attachment column holds files. Set the column's format to Attachment first.`,remove:`Remove from cell`,of:(e,t)=>`${String(e)} of ${String(t)}`,previous:`Previous file`,next:`Next file`,open:`Open in a new tab`,close:`Close`},review:{count:(e,t,n,r)=>`${e} changed ${fu(t,n,r)}`,keepAll:`Keep all`,undoAll:`Undo all`,keep:`Keep`,undo:`Undo`,was:`Before`,added:e=>`Added by ${e}`,changed:e=>`Changed by ${e}`,away:`Changed since you last looked`,countAway:(e,t,n)=>`Since you last looked: ${fu(e,t,n)} changed`,empty:`empty`,next:`Next`,previous:`Previous`,position:(e,t)=>`${String(e)} of ${String(t)}`,conflicts:e=>`${String(e)} ${e===1?`cell was`:`cells were`} changed by both of you: yours were kept.`},date:{placeholder:`2026-10-14, today, Oct 14…`,today:`Today`,previousMonth:`Previous month`,nextMonth:`Next month`,clear:`Clear`,addTime:`Add a time`,removeTime:`Remove the time`,time:`Time`},empty:{title:`No rows yet`,addRow:`Add a row`,paste:`Paste rows`,pasteHint:`Copy rows in Excel or Google Sheets, then press ⌘V here.`,importFile:`Import a file`,noMatch:`No rows to show`,noMatchBody:`The filter leaves every row out.`,clearFilter:`Clear the filter`}},mu=(e,t,n)=>`${e.toLocaleString(`es`)} ${e===1?t:n}`,hu=(e,t,n)=>[e>0?mu(e,`celda`,`celdas`):``,t>0?mu(t,`fila`,`filas`):``,n>0?mu(n,`columna`,`columnas`):``].filter(e=>e!==``).join(`, `),gu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Abriendo…`,unreadable:`Esta hoja no se puede editar ahora: su archivo no es un CSV que una hoja pueda leer. Esto es lo que falla.`,readOnlyLarge:e=>`Esta hoja ocupa ${e} MB: aquí se muestra, pero no se edita.`,untitled:`Sin título`,saved:`Guardado`,saving:`Guardando…`,unsaved:`Sin guardar`,failed:`No guardado`,rows:(e,t)=>e===t?mu(t,`fila`,`filas`):`${e.toLocaleString(`es`)} de ${t.toLocaleString(`es`)} filas`,find:`Buscar`,findPlaceholder:`Buscar en la hoja`,matches:e=>mu(e,`coincidencia`,`coincidencias`),types:{text:`Texto`,number:`Número`,select:`Lista desplegable`,"multi-select":`Selección múltiple`,date:`Fecha`,checkbox:`Casilla`,url:`Vínculo`,email:`Correo electrónico`,phone:`Teléfono`,file:`Archivo`},auto:{button:e=>`Ordenar y filtrar ${e}`,sortAsc:{text:`Ordenar de A a Z`,number:`Ordenar de menor a mayor`,date:`Ordenar de más antiguos a más recientes`,options:`Ordenar según las opciones`},sortDesc:{text:`Ordenar de Z a A`,number:`Ordenar de mayor a menor`,date:`Ordenar de más recientes a más antiguos`,options:`Ordenar según las opciones, al revés`},search:`Buscar`,selectAll:`(Seleccionar todo)`,selectFound:`(Seleccionar todos los resultados de la búsqueda)`,blanks:`(Vacías)`,checked:`Activada`,unchecked:`Desactivada`,hasFile:`Tiene un archivo`,more:e=>`${e.toLocaleString(`es`)} más. Busca para encontrarlos.`,none:`Ningún valor coincide.`,clear:`Borrar filtro`,ok:`Aceptar`},look:{sorted:e=>`Ordenado por ${e}`,filtered:e=>e.length===1?`Filtrado por ${e[0]??``}`:`Filtrado por ${String(e.length)} columnas`,hidden:e=>e===1?`1 columna oculta`:`${String(e)} columnas ocultas`,clear:`Borrar`,note:`Solo tú ves esta ordenación y este filtro.`},replace:{label:`Reemplazar`,with:`Reemplazar con`,one:`Reemplazar`,all:`Reemplazar todos`,done:e=>`Reemplazado en ${mu(e,`celda`,`celdas`)}.`},stats:{average:`Promedio`,count:`Recuento`,sum:`Suma`},column:{name:`Nombre de la columna`,key:`Columna clave: el valor de cada fila es único`,add:`Añadir una columna`,rename:`Cambiar nombre`,format:`Formato`,formats:{text:`Texto`,number:`Número`,currency:`Moneda`,percent:`Porcentaje`,date:`Fecha`,checkbox:`Casilla`,list:`Lista desplegable`,file:`Archivo adjunto`},addOption:`Añadir una opción`,newOption:e=>`Añadir “${e}”`,confirm:`Eliminar`,cancel:`Cancelar`,hide:`Ocultar columna`,insertLeft:`Insertar columna a la izquierda`,insertRight:`Insertar columna a la derecha`,remove:`Eliminar columna`,removeAsk:(e,t)=>`¿Eliminar “${e}” y ${t===1?`su valor`:`sus ${t.toLocaleString(`es`)} valores`}? Puedes deshacerlo.`,taken:`Ya hay otra columna con este nombre.`,empty:`Una columna necesita un nombre.`,newName:e=>e===1?`Columna`:`Columna ${String(e)}`},row:{numbered:e=>`Fila ${String(e)}`,inFile:e=>`Fila ${String(e)} del archivo`,of:(e,t)=>`Fila ${String(e)} de ${String(t)}`,hiddenFields:`Columnas ocultas`,insertAbove:`Insertar fila arriba`,insertBelow:`Insertar fila debajo`,remove:e=>e===1?`Eliminar fila`:`Eliminar ${String(e)} filas`,expand:`Abrir fila`,newRow:`Nueva fila`,record:`Fila`,previous:`Fila anterior`,next:`Fila siguiente`,close:`Cerrar`},cell:{copy:`Copiar`,cut:`Cortar`,paste:`Pegar`,clear:`Borrar`,clearContents:`Borrar contenido`,notNumber:`No es un número. Escribe cifras, con un punto para los decimales: 1234.5`,notDate:`No es una fecha. Escribe 2026-10-14 o 2026-10-14T09:30`,notEmail:`No es una dirección de correo electrónico`,notUrl:`Una dirección no lleva espacios`,open:`Abrir`,left:e=>e===1?`1 valor no encajaba en su columna y se omitió.`:`${String(e)} valores no encajaban en sus columnas y se omitieron.`,pasteHint:`Usa ⌘V para pegar.`},files:{notFound:`No encontrado`,insert:`Insertar archivo…`,add:`Añadir archivo`,adding:e=>e===1?`Añadiendo 1 archivo…`:`Añadiendo ${String(e)} archivos…`,tooLarge:(e,t)=>`${e} supera los ${String(t)} MB y no se añadió.`,failed:e=>`No se pudo añadir ${e}.`,notHere:`Solo una columna de archivos adjuntos contiene archivos. Primero cambia el formato de la columna a Archivo adjunto.`,remove:`Quitar de la celda`,of:(e,t)=>`${String(e)} de ${String(t)}`,previous:`Archivo anterior`,next:`Archivo siguiente`,open:`Abrir en una pestaña nueva`,close:`Cerrar`},review:{count:(e,t,n,r)=>`${e} cambió ${hu(t,n,r)}`,keepAll:`Conservar todo`,undoAll:`Deshacer todo`,keep:`Conservar`,undo:`Deshacer`,was:`Antes`,added:e=>`Añadido por ${e}`,changed:e=>`Cambiado por ${e}`,away:`Cambiado desde la última vez que lo viste`,countAway:(e,t,n)=>`Desde la última vez que lo viste: cambios en ${hu(e,t,n)}`,empty:`vacío`,next:`Siguiente`,previous:`Anterior`,position:(e,t)=>`${String(e)} de ${String(t)}`,conflicts:e=>e===1?`1 celda tenía cambios de los dos: se conservó el tuyo.`:`${String(e)} celdas tenían cambios de los dos: se conservaron los tuyos.`},date:{placeholder:`2026-10-14, 2026/10/14…`,today:`Hoy`,previousMonth:`Mes anterior`,nextMonth:`Mes siguiente`,clear:`Borrar`,addTime:`Añadir una hora`,removeTime:`Quitar la hora`,time:`Hora`},empty:{title:`Aún no hay filas`,addRow:`Añadir una fila`,paste:`Pegar filas`,pasteHint:`Copia filas en Excel o Google Sheets y pulsa ⌘V aquí.`,importFile:`Importar un archivo`,noMatch:`No hay filas que mostrar`,noMatchBody:`El filtro deja fuera todas las filas.`,clearFilter:`Borrar el filtro`}},_u=(e,t,n)=>`${e.toLocaleString(`fr`)} ${e<2?t:n}`,vu=(e,t,n)=>[e>0?_u(e,`cellule`,`cellules`):``,t>0?_u(t,`ligne`,`lignes`):``,n>0?_u(n,`colonne`,`colonnes`):``].filter(e=>e!==``).join(`, `),yu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Ouverture…`,unreadable:`Cette feuille de calcul ne peut pas être modifiée pour l’instant\xA0: son fichier n’est pas un CSV lisible. Voici ce qui ne va pas.`,readOnlyLarge:e=>`Cette feuille de calcul fait ${e}\u00a0Mo\u00a0: elle est affichée ici, pas modifiée.`,untitled:`Sans titre`,saved:`Enregistré`,saving:`Enregistrement…`,unsaved:`Non enregistré`,failed:`Non enregistré`,rows:(e,t)=>e===t?_u(t,`ligne`,`lignes`):`${e.toLocaleString(`fr`)} sur ${_u(t,`ligne`,`lignes`)}`,find:`Rechercher`,findPlaceholder:`Rechercher dans la feuille`,matches:e=>_u(e,`résultat`,`résultats`),types:{text:`Texte`,number:`Nombre`,select:`Liste déroulante`,"multi-select":`Liste à choix multiples`,date:`Date`,checkbox:`Case à cocher`,url:`Lien`,email:`E-mail`,phone:`Téléphone`,file:`Fichier`},auto:{button:e=>`Trier et filtrer ${e}`,sortAsc:{text:`Trier de A à Z`,number:`Trier du plus petit au plus grand`,date:`Trier du plus ancien au plus récent`,options:`Trier dans l’ordre des options`},sortDesc:{text:`Trier de Z à A`,number:`Trier du plus grand au plus petit`,date:`Trier du plus récent au plus ancien`,options:`Trier dans l’ordre inverse des options`},search:`Rechercher`,selectAll:`(Sélectionner tout)`,selectFound:`(Sélectionner tous les résultats de la recherche)`,blanks:`(Vides)`,checked:`Coché`,unchecked:`Non coché`,hasFile:`Contient un fichier`,more:e=>`${e.toLocaleString(`fr`)} de plus. Recherchez pour les trouver.`,none:`Aucune valeur ne correspond.`,clear:`Effacer le filtre`,ok:`OK`},look:{sorted:e=>`Trié par ${e}`,filtered:e=>e.length===1?`Filtré par ${e[0]??``}`:`Filtré par ${String(e.length)} colonnes`,hidden:e=>e<2?`${String(e)} colonne masquée`:`${String(e)} colonnes masquées`,clear:`Effacer`,note:`Vous seul voyez ce tri et ce filtre.`},replace:{label:`Remplacer`,with:`Remplacer par`,one:`Remplacer`,all:`Remplacer tout`,done:e=>`Remplacé dans ${_u(e,`cellule`,`cellules`)}.`},stats:{average:`Moyenne`,count:`Nombre`,sum:`Somme`},column:{name:`Nom de la colonne`,key:`Colonne clé\xA0: chaque ligne y a sa propre valeur`,add:`Ajouter une colonne`,rename:`Renommer`,format:`Format`,formats:{text:`Texte`,number:`Nombre`,currency:`Monétaire`,percent:`Pourcentage`,date:`Date`,checkbox:`Case à cocher`,list:`Liste déroulante`,file:`Pièce jointe`},addOption:`Ajouter une option`,newOption:e=>`Ajouter «\u00a0${e}\u00a0»`,confirm:`Supprimer`,cancel:`Annuler`,hide:`Masquer la colonne`,insertLeft:`Insérer une colonne à gauche`,insertRight:`Insérer une colonne à droite`,remove:`Supprimer la colonne`,removeAsk:(e,t)=>`Supprimer «\u00a0${e}\u00a0» et ${t<2?`sa`:`ses`} ${_u(t,`valeur`,`valeurs`)}\u00a0? Vous pourrez annuler.`,taken:`Une autre colonne porte ce nom.`,empty:`Une colonne doit avoir un nom.`,newName:e=>e===1?`Colonne`:`Colonne ${String(e)}`},row:{numbered:e=>`Ligne ${String(e)}`,inFile:e=>`Ligne ${String(e)} du fichier`,of:(e,t)=>`Ligne ${String(e)} sur ${String(t)}`,hiddenFields:`Colonnes masquées`,insertAbove:`Insérer une ligne au-dessus`,insertBelow:`Insérer une ligne en dessous`,remove:e=>e===1?`Supprimer la ligne`:`Supprimer ${String(e)} lignes`,expand:`Ouvrir la ligne`,newRow:`Nouvelle ligne`,record:`Ligne`,previous:`Ligne précédente`,next:`Ligne suivante`,close:`Fermer`},cell:{copy:`Copier`,cut:`Couper`,paste:`Coller`,clear:`Effacer`,clearContents:`Effacer le contenu`,notNumber:`Ce n’est pas un nombre. Écrivez des chiffres, avec un point pour les décimales\xA0: 1234.5`,notDate:`Ce n’est pas une date. Écrivez 2026-10-14, ou 2026-10-14T09:30`,notEmail:`Ce n’est pas une adresse e-mail`,notUrl:`Une adresse ne contient pas d’espaces`,open:`Ouvrir`,left:e=>e===1?`1 valeur ne convenait pas à sa colonne et a été laissée de côté.`:`${String(e)} valeurs ne convenaient pas à leur colonne et ont été laissées de côté.`,pasteHint:`Utilisez ⌘V pour coller.`},files:{notFound:`Introuvable`,insert:`Insérer un fichier…`,add:`Ajouter un fichier`,adding:e=>e===1?`Ajout d’un fichier…`:`Ajout de ${String(e)} fichiers…`,tooLarge:(e,t)=>`${e} dépasse ${String(t)}\u00a0Mo et n’a pas été ajouté.`,failed:e=>`${e} n’a pas pu être ajouté.`,notHere:`Seule une colonne de pièces jointes contient des fichiers. Choisissez d’abord le format Pièce jointe pour la colonne.`,remove:`Retirer de la cellule`,of:(e,t)=>`${String(e)} sur ${String(t)}`,previous:`Fichier précédent`,next:`Fichier suivant`,open:`Ouvrir dans un nouvel onglet`,close:`Fermer`},review:{count:(e,t,n,r)=>`${e} a modifié ${vu(t,n,r)}`,keepAll:`Tout garder`,undoAll:`Tout annuler`,keep:`Garder`,undo:`Annuler`,was:`Avant`,added:e=>`Ajouté par ${e}`,changed:e=>`Modifié par ${e}`,away:`Modifié depuis votre dernière visite`,countAway:(e,t,n)=>`Depuis votre dernière visite\u00a0: ${vu(e,t,n)} ${e+t+n<2?`modifiée`:`modifiées`}`,empty:`vide`,next:`Suivant`,previous:`Précédent`,position:(e,t)=>`${String(e)} sur ${String(t)}`,conflicts:e=>e<2?`${String(e)} cellule a été modifiée par vous deux\u00a0: votre version a été gardée.`:`${String(e)} cellules ont été modifiées par vous deux\u00a0: vos versions ont été gardées.`},date:{placeholder:`2026-10-14, 2026-10-14 09:30…`,today:`Aujourd’hui`,previousMonth:`Mois précédent`,nextMonth:`Mois suivant`,clear:`Effacer`,addTime:`Ajouter une heure`,removeTime:`Retirer l’heure`,time:`Heure`},empty:{title:`Aucune ligne pour l’instant`,addRow:`Ajouter une ligne`,paste:`Coller des lignes`,pasteHint:`Copiez des lignes dans Excel ou Google Sheets, puis appuyez sur ⌘V ici.`,importFile:`Importer un fichier`,noMatch:`Aucune ligne à afficher`,noMatchBody:`Le filtre exclut toutes les lignes.`,clearFilter:`Effacer le filtre`}},bu=new Intl.PluralRules(`hi`),xu=e=>bu.select(e)===`one`,Su=e=>e.toLocaleString(`hi`),Cu=(e,t,n)=>[e>0?`${String(e)} सेल`:``,t>0?`${String(t)} ${xu(t)?`पंक्ति`:`पंक्तियाँ`}`:``,n>0?`${String(n)} कॉलम`:``].filter(e=>e!==``).join(`, `),wu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`खुल रहा है…`,unreadable:`यह शीट अभी एडिट नहीं की जा सकती: इसकी फ़ाइल ऐसी CSV नहीं है जिसे शीट पढ़ सके। गड़बड़ी यह है।`,readOnlyLarge:e=>`यह शीट ${e} MB की है: यहाँ यह सिर्फ़ दिखाई जाती है, एडिट नहीं होती।`,untitled:`बिना शीर्षक`,saved:`सेव हो गया`,saving:`सेव हो रहा है…`,unsaved:`सेव नहीं हुआ`,failed:`सेव नहीं हो सका`,rows:(e,t)=>e===t?`${Su(t)} ${xu(t)?`पंक्ति`:`पंक्तियाँ`}`:`${Su(t)} में से ${Su(e)} पंक्तियाँ`,find:`ढूँढें`,findPlaceholder:`शीट में ढूँढें`,matches:e=>`${String(e)} मिलान`,types:{text:`टेक्स्ट`,number:`संख्या`,select:`ड्रॉपडाउन सूची`,"multi-select":`कई विकल्पों की सूची`,date:`तारीख`,checkbox:`चेकबॉक्स`,url:`लिंक`,email:`ईमेल`,phone:`फ़ोन`,file:`फ़ाइल`},auto:{button:e=>`${e} को सॉर्ट और फ़िल्टर करें`,sortAsc:{text:`A से Z तक सॉर्ट करें`,number:`सबसे छोटे से सबसे बड़े तक सॉर्ट करें`,date:`सबसे पुराने से सबसे नए तक सॉर्ट करें`,options:`विकल्पों के क्रम में सॉर्ट करें`},sortDesc:{text:`Z से A तक सॉर्ट करें`,number:`सबसे बड़े से सबसे छोटे तक सॉर्ट करें`,date:`सबसे नए से सबसे पुराने तक सॉर्ट करें`,options:`विकल्पों के उल्टे क्रम में सॉर्ट करें`},search:`खोजें`,selectAll:`(सभी चुनें)`,selectFound:`(खोज के सभी नतीजे चुनें)`,blanks:`(रिक्त)`,checked:`चेक किया हुआ`,unchecked:`चेक नहीं किया हुआ`,hasFile:`फ़ाइल है`,more:e=>`${Su(e)} और। उन्हें पाने के लिए खोजें।`,none:`कोई मान मेल नहीं खाता।`,clear:`फ़िल्टर साफ़ करें`,ok:`ठीक है`},look:{sorted:e=>`${e} के हिसाब से सॉर्ट किया गया`,filtered:e=>e.length===1?`${e[0]??``} के हिसाब से फ़िल्टर किया गया`:`${String(e.length)} कॉलम के हिसाब से फ़िल्टर किया गया`,hidden:e=>`${String(e)} कॉलम छिपे हुए`,clear:`साफ़ करें`,note:`यह सॉर्ट और फ़िल्टर सिर्फ़ आपको दिखता है।`},replace:{label:`बदलें`,with:`इससे बदलें`,one:`बदलें`,all:`सभी बदलें`,done:e=>`${String(e)} सेल में बदला गया।`},stats:{average:`औसत`,count:`गिनती`,sum:`योग`},column:{name:`कॉलम का नाम`,key:`की कॉलम: हर पंक्ति का मान अलग होता है`,add:`कॉलम जोड़ें`,rename:`नाम बदलें`,format:`फ़ॉर्मेट`,formats:{text:`टेक्स्ट`,number:`संख्या`,currency:`मुद्रा`,percent:`प्रतिशत`,date:`तारीख`,checkbox:`चेकबॉक्स`,list:`ड्रॉपडाउन सूची`,file:`अटैचमेंट`},addOption:`विकल्प जोड़ें`,newOption:e=>`“${e}” जोड़ें`,confirm:`डिलीट करें`,cancel:`रद्द करें`,hide:`कॉलम छिपाएँ`,insertLeft:`बाईं ओर कॉलम डालें`,insertRight:`दाईं ओर कॉलम डालें`,remove:`कॉलम डिलीट करें`,removeAsk:(e,t)=>`“${e}” और उसके ${Su(t)} मान डिलीट करें? आप इसे पहले जैसा कर सकते हैं।`,taken:`किसी दूसरे कॉलम का यही नाम है।`,empty:`कॉलम का नाम होना ज़रूरी है।`,newName:e=>e===1?`कॉलम`:`कॉलम ${String(e)}`},row:{numbered:e=>`पंक्ति ${String(e)}`,inFile:e=>`फ़ाइल में पंक्ति ${String(e)}`,of:(e,t)=>`पंक्ति ${String(e)} / ${String(t)}`,hiddenFields:`छिपे हुए कॉलम`,insertAbove:`ऊपर पंक्ति डालें`,insertBelow:`नीचे पंक्ति डालें`,remove:e=>e===1?`पंक्ति डिलीट करें`:`${String(e)} पंक्तियाँ डिलीट करें`,expand:`पंक्ति खोलें`,newRow:`नई पंक्ति`,record:`पंक्ति`,previous:`पिछली पंक्ति`,next:`अगली पंक्ति`,close:`बंद करें`},cell:{copy:`कॉपी करें`,cut:`कट करें`,paste:`पेस्ट करें`,clear:`साफ़ करें`,clearContents:`सामग्री साफ़ करें`,notNumber:`यह संख्या नहीं है। अंक लिखें, दशमलव के लिए पॉइंट के साथ: 1234.5`,notDate:`यह तारीख नहीं है। 2026-10-14 या 2026-10-14T09:30 लिखें`,notEmail:`यह ईमेल पता नहीं है`,notUrl:`पते में स्पेस नहीं होते`,open:`खोलें`,left:e=>e===1?`1 मान अपने कॉलम में फ़िट नहीं हुआ और छोड़ दिया गया।`:`${String(e)} मान अपने कॉलम में फ़िट नहीं हुए और छोड़ दिए गए।`,pasteHint:`पेस्ट करने के लिए ⌘V इस्तेमाल करें।`},files:{notFound:`नहीं मिली`,insert:`फ़ाइल डालें…`,add:`फ़ाइल जोड़ें`,adding:e=>e===1?`1 फ़ाइल जोड़ी जा रही है…`:`${String(e)} फ़ाइलें जोड़ी जा रही हैं…`,tooLarge:(e,t)=>`${e} ${String(t)} MB से बड़ी है, इसलिए जोड़ी नहीं गई।`,failed:e=>`${e} जोड़ी नहीं जा सकी।`,notHere:`फ़ाइलें सिर्फ़ अटैचमेंट कॉलम में रहती हैं। पहले कॉलम का फ़ॉर्मेट अटैचमेंट पर सेट करें।`,remove:`सेल से हटाएँ`,of:(e,t)=>`${String(e)} / ${String(t)}`,previous:`पिछली फ़ाइल`,next:`अगली फ़ाइल`,open:`नए टैब में खोलें`,close:`बंद करें`},review:{count:(e,t,n,r)=>`${e} के बदलाव: ${Cu(t,n,r)}`,keepAll:`सभी रखें`,undoAll:`सभी पहले जैसे करें`,keep:`रखें`,undo:`पहले जैसा करें`,was:`पहले`,added:e=>`${e} ने जोड़ा`,changed:e=>`${e} ने बदला`,away:`आपके पिछली बार देखने के बाद बदला गया`,countAway:(e,t,n)=>`आपके पिछली बार देखने के बाद बदला गया: ${Cu(e,t,n)}`,empty:`खाली`,next:`अगला`,previous:`पिछला`,position:(e,t)=>`${String(e)} / ${String(t)}`,conflicts:e=>`${String(e)} सेल आप दोनों ने बदले: आपके बदलाव रखे गए।`},date:{placeholder:`2026-10-14, today, Oct 14…`,today:`आज`,previousMonth:`पिछला महीना`,nextMonth:`अगला महीना`,clear:`साफ़ करें`,addTime:`समय जोड़ें`,removeTime:`समय हटाएँ`,time:`समय`},empty:{title:`अभी कोई पंक्ति नहीं`,addRow:`पंक्ति जोड़ें`,paste:`पंक्तियाँ पेस्ट करें`,pasteHint:`Excel या Google Sheets में पंक्तियाँ कॉपी करें, फिर यहाँ ⌘V दबाएँ।`,importFile:`फ़ाइल इंपोर्ट करें`,noMatch:`दिखाने के लिए कोई पंक्ति नहीं`,noMatchBody:`फ़िल्टर हर पंक्ति को बाहर कर देता है।`,clearFilter:`फ़िल्टर साफ़ करें`}},Tu=(e,t,n)=>`${e.toLocaleString(`it`)} ${e===1?t:n}`,Eu=(e,t,n)=>[e>0?Tu(e,`cella`,`celle`):``,t>0?Tu(t,`riga`,`righe`):``,n>0?Tu(n,`colonna`,`colonne`):``].filter(e=>e!==``).join(`, `),Du={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Apertura…`,unreadable:`Al momento questo foglio non si può modificare: il suo file non è un CSV leggibile. Ecco cosa non va.`,readOnlyLarge:e=>`Questo foglio è di ${e} MB: qui si può vedere, ma non modificare.`,untitled:`Senza titolo`,saved:`Salvato`,saving:`Salvataggio…`,unsaved:`Non salvato`,failed:`Non salvato`,rows:(e,t)=>e===t?Tu(t,`riga`,`righe`):`${e.toLocaleString(`it`)} di ${t.toLocaleString(`it`)} righe`,find:`Trova`,findPlaceholder:`Trova nel foglio`,matches:e=>e===1?`1 risultato`:`${String(e)} risultati`,types:{text:`Testo`,number:`Numero`,select:`Elenco a discesa`,"multi-select":`Selezione multipla`,date:`Data`,checkbox:`Casella di controllo`,url:`Link`,email:`Email`,phone:`Telefono`,file:`File`},auto:{button:e=>`Ordina e filtra ${e}`,sortAsc:{text:`Ordina dalla A alla Z`,number:`Ordina dal più piccolo al più grande`,date:`Ordina dal meno recente al più recente`,options:`Ordina secondo le opzioni`},sortDesc:{text:`Ordina dalla Z alla A`,number:`Ordina dal più grande al più piccolo`,date:`Ordina dal più recente al meno recente`,options:`Ordina secondo le opzioni, al contrario`},search:`Cerca`,selectAll:`(Seleziona tutto)`,selectFound:`(Seleziona tutti i risultati della ricerca)`,blanks:`(Vuote)`,checked:`Selezionata`,unchecked:`Non selezionata`,hasFile:`Con un file`,more:e=>`Altri ${e.toLocaleString(`it`)}. Usa la ricerca per trovarli.`,none:`Nessun valore corrispondente.`,clear:`Cancella filtro`,ok:`OK`},look:{sorted:e=>`Ordinato per ${e}`,filtered:e=>e.length===1?`Filtrato per ${e[0]??``}`:`Filtrato per ${String(e.length)} colonne`,hidden:e=>e===1?`1 colonna nascosta`:`${String(e)} colonne nascoste`,clear:`Cancella`,note:`Solo tu vedi questo ordinamento e questo filtro.`},replace:{label:`Sostituisci`,with:`Sostituisci con`,one:`Sostituisci`,all:`Sostituisci tutto`,done:e=>`Sostituito in ${Tu(e,`cella`,`celle`)}.`},stats:{average:`Media`,count:`Conteggio`,sum:`Somma`},column:{name:`Nome della colonna`,key:`Colonna chiave: ogni riga ha un valore unico`,add:`Aggiungi una colonna`,rename:`Rinomina`,format:`Formato`,formats:{text:`Testo`,number:`Numero`,currency:`Valuta`,percent:`Percentuale`,date:`Data`,checkbox:`Casella di controllo`,list:`Elenco a discesa`,file:`Allegato`},addOption:`Aggiungi un'opzione`,newOption:e=>`Aggiungi “${e}”`,confirm:`Elimina`,cancel:`Annulla`,hide:`Nascondi colonna`,insertLeft:`Inserisci colonna a sinistra`,insertRight:`Inserisci colonna a destra`,remove:`Elimina colonna`,removeAsk:(e,t)=>`Eliminare “${e}” e ${t===1?`il suo valore`:`i suoi ${t.toLocaleString(`it`)} valori`}? Puoi annullare.`,taken:`Un'altra colonna ha già questo nome.`,empty:`Una colonna deve avere un nome.`,newName:e=>e===1?`Colonna`:`Colonna ${String(e)}`},row:{numbered:e=>`Riga ${String(e)}`,inFile:e=>`Riga ${String(e)} nel file`,of:(e,t)=>`Riga ${String(e)} di ${String(t)}`,hiddenFields:`Colonne nascoste`,insertAbove:`Inserisci riga sopra`,insertBelow:`Inserisci riga sotto`,remove:e=>e===1?`Elimina riga`:`Elimina ${String(e)} righe`,expand:`Apri riga`,newRow:`Nuova riga`,record:`Riga`,previous:`Riga precedente`,next:`Riga successiva`,close:`Chiudi`},cell:{copy:`Copia`,cut:`Taglia`,paste:`Incolla`,clear:`Cancella`,clearContents:`Cancella contenuto`,notNumber:`Non è un numero. Scrivi le cifre, con il punto per i decimali: 1234.5`,notDate:`Non è una data. Scrivi 2026-10-14 o 2026-10-14T09:30`,notEmail:`Non è un indirizzo email`,notUrl:`Un indirizzo non contiene spazi`,open:`Apri`,left:e=>e===1?`1 valore non era adatto alla sua colonna ed è stato escluso.`:`${String(e)} valori non erano adatti alle loro colonne e sono stati esclusi.`,pasteHint:`Usa ⌘V per incollare.`},files:{notFound:`Non trovato`,insert:`Inserisci file…`,add:`Aggiungi file`,adding:e=>e===1?`Aggiunta di 1 file…`:`Aggiunta di ${String(e)} file…`,tooLarge:(e,t)=>`${e} supera i ${String(t)} MB e non è stato aggiunto.`,failed:e=>`Impossibile aggiungere ${e}.`,notHere:`Solo una colonna di allegati contiene file. Imposta prima il formato della colonna su Allegato.`,remove:`Rimuovi dalla cella`,of:(e,t)=>`${String(e)} di ${String(t)}`,previous:`File precedente`,next:`File successivo`,open:`Apri in un nuovo pannello`,close:`Chiudi`},review:{count:(e,t,n,r)=>`${e} ha modificato ${Eu(t,n,r)}`,keepAll:`Mantieni tutto`,undoAll:`Annulla tutto`,keep:`Mantieni`,undo:`Annulla`,was:`Prima`,added:e=>`Aggiunto da ${e}`,changed:e=>`Modificato da ${e}`,away:`Modificato dall'ultima volta che l'hai visto`,countAway:(e,t,n)=>`Dall'ultima volta che l'hai visto: modificate ${Eu(e,t,n)}`,empty:`vuoto`,next:`Successivo`,previous:`Precedente`,position:(e,t)=>`${String(e)} di ${String(t)}`,conflicts:e=>e===1?`1 cella è stata modificata da entrambi: è stata mantenuta la tua versione.`:`${String(e)} celle sono state modificate da entrambi: è stata mantenuta la tua versione.`},date:{placeholder:`2026-10-14, 2026/10/14…`,today:`Oggi`,previousMonth:`Mese precedente`,nextMonth:`Mese successivo`,clear:`Cancella`,addTime:`Aggiungi un orario`,removeTime:`Rimuovi l'orario`,time:`Ora`},empty:{title:`Ancora nessuna riga`,addRow:`Aggiungi una riga`,paste:`Incolla righe`,pasteHint:`Copia le righe in Excel o Google Fogli, poi premi ⌘V qui.`,importFile:`Importa un file`,noMatch:`Nessuna riga da mostrare`,noMatchBody:`Il filtro esclude tutte le righe.`,clearFilter:`Cancella il filtro`}},Ou=/[\u3040-\u30ff\u3400-\u9fff\uf900-\ufaff]/u,ku=/[A-Za-z0-9]/;function Au(...e){let t=``;for(let n of e){if(n===``)continue;let e=t.at(-1)??``,r=n[0]??``,i=Ou.test(e)&&ku.test(r)||ku.test(e)&&Ou.test(r);t+=(i?` `:``)+n}return t}var ju=(e,t,n)=>[e>0?`セル ${String(e)} 個`:``,t>0?`${String(t)} 行`:``,n>0?`${String(n)} 列`:``].filter(e=>e!==``).join(`、`),Mu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`開いています…`,unreadable:`このシートは現在編集できません:ファイルが読み込める CSV になっていません。問題点は次のとおりです。`,readOnlyLarge:e=>`このシートは ${e} MB あるため、ここでは表示のみで編集はできません。`,untitled:`無題`,saved:`保存済み`,saving:`保存中…`,unsaved:`未保存`,failed:`保存できませんでした`,rows:(e,t)=>e===t?`${t.toLocaleString(`ja`)} 行`:`${e.toLocaleString(`ja`)} / ${t.toLocaleString(`ja`)} 行`,find:`検索`,findPlaceholder:`シート内を検索`,matches:e=>`${String(e)} 件`,types:{text:`文字列`,number:`数値`,select:`ドロップダウンリスト`,"multi-select":`複数選択リスト`,date:`日付`,checkbox:`チェックボックス`,url:`リンク`,email:`メール`,phone:`電話番号`,file:`ファイル`},auto:{button:e=>Au(e,`の並べ替えとフィルター`),sortAsc:{text:`昇順で並べ替え(A → Z)`,number:`小さい順に並べ替え`,date:`古い順に並べ替え`,options:`選択肢の順に並べ替え`},sortDesc:{text:`降順で並べ替え(Z → A)`,number:`大きい順に並べ替え`,date:`新しい順に並べ替え`,options:`選択肢の逆順に並べ替え`},search:`検索`,selectAll:`(すべて選択)`,selectFound:`(検索結果をすべて選択)`,blanks:`(空白セル)`,checked:`チェックあり`,unchecked:`チェックなし`,hasFile:`ファイルあり`,more:e=>`ほか ${e.toLocaleString(`ja`)} 件。検索すると見つかります。`,none:`一致する値はありません。`,clear:`フィルターをクリア`,ok:`OK`},look:{sorted:e=>`「${e}」で並べ替え中`,filtered:e=>e.length===1?`「${e[0]??``}」でフィルター中`:`${String(e.length)} 列でフィルター中`,hidden:e=>`${String(e)} 列を非表示`,clear:`クリア`,note:`この並べ替えとフィルターはあなたにだけ表示されます。`},replace:{label:`置換`,with:`置換後の文字列`,one:`置換`,all:`すべて置換`,done:e=>`${String(e)} 個のセルで置換しました。`},stats:{average:`平均`,count:`データの個数`,sum:`合計`},column:{name:`列名`,key:`キー列:行ごとに値が重複しません`,add:`列を追加`,rename:`名前を変更`,format:`表示形式`,formats:{text:`文字列`,number:`数値`,currency:`通貨`,percent:`パーセンテージ`,date:`日付`,checkbox:`チェックボックス`,list:`ドロップダウンリスト`,file:`添付ファイル`},addOption:`選択肢を追加`,newOption:e=>`「${e}」を追加`,confirm:`削除`,cancel:`キャンセル`,hide:`列を非表示`,insertLeft:`左に列を挿入`,insertRight:`右に列を挿入`,remove:`列を削除`,removeAsk:(e,t)=>`「${e}」とその ${t.toLocaleString(`ja`)} 個の値を削除しますか?元に戻せます。`,taken:`同じ名前の列がすでにあります。`,empty:`列には名前が必要です。`,newName:e=>e===1?`列`:`列 ${String(e)}`},row:{numbered:e=>`${String(e)} 行目`,inFile:e=>`ファイルの ${String(e)} 行目`,of:(e,t)=>`${String(e)} / ${String(t)} 行`,hiddenFields:`非表示の列`,insertAbove:`上に行を挿入`,insertBelow:`下に行を挿入`,remove:e=>e===1?`行を削除`:`${String(e)} 行を削除`,expand:`行を開く`,newRow:`新しい行`,record:`行`,previous:`前の行`,next:`次の行`,close:`閉じる`},cell:{copy:`コピー`,cut:`切り取り`,paste:`貼り付け`,clear:`クリア`,clearContents:`内容をクリア`,notNumber:`数値ではありません。数字で入力し、小数点にはピリオドを使ってください:1234.5`,notDate:`日付ではありません。2026-10-14 または 2026-10-14T09:30 の形式で入力してください`,notEmail:`メールアドレスではありません`,notUrl:`アドレスにスペースは使えません`,open:`開く`,left:e=>`${String(e)} 個の値が列の形式に合わないため、貼り付けませんでした。`,pasteHint:`⌘V で貼り付けてください。`},files:{notFound:`見つかりません`,insert:`ファイルを挿入…`,add:`ファイルを追加`,adding:e=>`${String(e)} 個のファイルを追加中…`,tooLarge:(e,t)=>`${e} は ${String(t)} MB を超えているため、追加しませんでした。`,failed:e=>`${e} を追加できませんでした。`,notHere:`ファイルを入れられるのは添付ファイルの列だけです。先に列の表示形式を「添付ファイル」にしてください。`,remove:`セルから削除`,of:(e,t)=>`${String(e)} / ${String(t)}`,previous:`前のファイル`,next:`次のファイル`,open:`新しいタブで開く`,close:`閉じる`},review:{count:(e,t,n,r)=>Au(e,`が${ju(t,n,r)}を変更しました`),keepAll:`すべて残す`,undoAll:`すべて元に戻す`,keep:`残す`,undo:`元に戻す`,was:`変更前`,added:e=>Au(e,`が追加`),changed:e=>Au(e,`が変更`),away:`前回の確認以降に変更`,countAway:(e,t,n)=>`前回の確認以降、${ju(e,t,n)}が変更されました`,empty:`空`,next:`次へ`,previous:`前へ`,position:(e,t)=>`${String(e)} / ${String(t)}`,conflicts:e=>`${String(e)} 個のセルが双方で変更されました。あなたの変更を残しています。`},date:{placeholder:`2026-10-14、2026年10月14日、today…`,today:`今日`,previousMonth:`前の月`,nextMonth:`次の月`,clear:`クリア`,addTime:`時刻を追加`,removeTime:`時刻を削除`,time:`時刻`},empty:{title:`まだ行がありません`,addRow:`行を追加`,paste:`行を貼り付け`,pasteHint:`Excel や Google スプレッドシートで行をコピーし、ここで ⌘V を押してください。`,importFile:`ファイルを読み込む`,noMatch:`表示する行がありません`,noMatchBody:`フィルターですべての行が除外されています。`,clearFilter:`フィルターをクリア`}},Nu=(e,t,n)=>[e>0?`셀 ${String(e)}개`:``,t>0?`행 ${String(t)}개`:``,n>0?`열 ${String(n)}개`:``].filter(e=>e!==``).join(`, `),Pu=e=>{let t=e.replace(/[^\p{L}\p{N}]+$/u,``),n=t.charCodeAt(t.length-1);return`${e}${(n>=44032&&n<=55203?(n-44032)%28!=0:/\d$/u.test(t)?/[013678]$/u.test(t):/(ng|[lmnkpt])$/iu.test(t))?`이`:`가`}`},Fu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`여는 중…`,unreadable:`지금은 이 시트를 편집할 수 없습니다. 파일이 시트에서 읽을 수 있는 CSV가 아닙니다. 문제는 다음과 같습니다.`,readOnlyLarge:e=>`이 시트는 ${e} MB라서 여기서는 보기만 할 수 있고 편집할 수 없습니다.`,untitled:`제목 없음`,saved:`저장됨`,saving:`저장 중…`,unsaved:`저장 안 됨`,failed:`저장하지 못함`,rows:(e,t)=>e===t?`${t.toLocaleString(`ko`)}행`:`${t.toLocaleString(`ko`)}행 중 ${e.toLocaleString(`ko`)}행`,find:`찾기`,findPlaceholder:`시트에서 찾기`,matches:e=>`${String(e)}개 일치`,types:{text:`텍스트`,number:`숫자`,select:`드롭다운 목록`,"multi-select":`다중 선택 목록`,date:`날짜`,checkbox:`확인란`,url:`링크`,email:`이메일`,phone:`전화번호`,file:`파일`},auto:{button:e=>`${e} 정렬 및 필터`,sortAsc:{text:`텍스트 오름차순 정렬`,number:`숫자 오름차순 정렬`,date:`오래된 날짜순 정렬`,options:`옵션 순서대로 정렬`},sortDesc:{text:`텍스트 내림차순 정렬`,number:`숫자 내림차순 정렬`,date:`최근 날짜순 정렬`,options:`옵션 역순으로 정렬`},search:`검색`,selectAll:`(모두 선택)`,selectFound:`(검색 결과 모두 선택)`,blanks:`(필드 값 없음)`,checked:`선택됨`,unchecked:`선택 안 됨`,hasFile:`파일 있음`,more:e=>`${e.toLocaleString(`ko`)}개 더 있습니다. 검색하여 찾으세요.`,none:`일치하는 값이 없습니다.`,clear:`필터 해제`,ok:`확인`},look:{sorted:e=>`${e} 기준 정렬됨`,filtered:e=>e.length===1?`${e[0]??``} 기준 필터링됨`:`열 ${String(e.length)}개 기준 필터링됨`,hidden:e=>`열 ${String(e)}개 숨김`,clear:`해제`,note:`이 정렬과 필터는 나에게만 보입니다.`},replace:{label:`바꾸기`,with:`바꿀 내용`,one:`바꾸기`,all:`모두 바꾸기`,done:e=>`셀 ${String(e)}개에서 바꿨습니다.`},stats:{average:`평균`,count:`개수`,sum:`합계`},column:{name:`열 이름`,key:`키 열: 행마다 고유한 값을 가집니다`,add:`열 추가`,rename:`이름 바꾸기`,format:`서식`,formats:{text:`텍스트`,number:`숫자`,currency:`통화`,percent:`백분율`,date:`날짜`,checkbox:`확인란`,list:`드롭다운 목록`,file:`첨부 파일`},addOption:`옵션 추가`,newOption:e=>`“${e}” 추가`,confirm:`삭제`,cancel:`취소`,hide:`열 숨기기`,insertLeft:`왼쪽에 열 삽입`,insertRight:`오른쪽에 열 삽입`,remove:`열 삭제`,removeAsk:(e,t)=>`“${e}” 열과 그 값 ${t.toLocaleString(`ko`)}개를 삭제할까요? 실행 취소할 수 있습니다.`,taken:`같은 이름의 열이 이미 있습니다.`,empty:`열 이름을 입력하세요.`,newName:e=>e===1?`열`:`열 ${String(e)}`},row:{numbered:e=>`${String(e)}행`,inFile:e=>`파일의 ${String(e)}행`,of:(e,t)=>`${String(t)}행 중 ${String(e)}행`,hiddenFields:`숨긴 열`,insertAbove:`위에 행 삽입`,insertBelow:`아래에 행 삽입`,remove:e=>e===1?`행 삭제`:`행 ${String(e)}개 삭제`,expand:`행 열기`,newRow:`새 행`,record:`행`,previous:`이전 행`,next:`다음 행`,close:`닫기`},cell:{copy:`복사`,cut:`잘라내기`,paste:`붙여넣기`,clear:`지우기`,clearContents:`내용 지우기`,notNumber:`숫자가 아닙니다. 숫자로 쓰고 소수는 점을 사용하세요: 1234.5`,notDate:`날짜가 아닙니다. 2026-10-14 또는 2026-10-14T09:30 형식으로 쓰세요`,notEmail:`이메일 주소가 아닙니다`,notUrl:`주소에는 공백을 쓸 수 없습니다`,open:`열기`,left:e=>`값 ${String(e)}개가 열에 맞지 않아 제외되었습니다.`,pasteHint:`붙여넣으려면 ⌘V를 사용하세요.`},files:{notFound:`찾을 수 없음`,insert:`파일 삽입…`,add:`파일 추가`,adding:e=>`파일 ${String(e)}개 추가 중…`,tooLarge:(e,t)=>`${e} 파일이 ${String(t)} MB를 넘어 추가하지 않았습니다.`,failed:e=>`${e} 파일을 추가하지 못했습니다.`,notHere:`첨부 파일 열에만 파일을 넣을 수 있습니다. 먼저 열 서식을 첨부 파일로 설정하세요.`,remove:`셀에서 제거`,of:(e,t)=>`${String(e)} / ${String(t)}`,previous:`이전 파일`,next:`다음 파일`,open:`새 탭에서 열기`,close:`닫기`},review:{count:(e,t,n,r)=>`${Pu(e)} 변경함: ${Nu(t,n,r)}`,keepAll:`모두 유지`,undoAll:`모두 실행 취소`,keep:`유지`,undo:`실행 취소`,was:`이전`,added:e=>`${Pu(e)} 추가함`,changed:e=>`${Pu(e)} 변경함`,away:`마지막으로 본 뒤 변경됨`,countAway:(e,t,n)=>`마지막으로 본 뒤 변경됨: ${Nu(e,t,n)}`,empty:`비어 있음`,next:`다음`,previous:`이전`,position:(e,t)=>`${String(e)} / ${String(t)}`,conflicts:e=>`셀 ${String(e)}개를 양쪽에서 모두 바꿨습니다. 내 변경 사항을 유지했습니다.`},date:{placeholder:`2026-10-14, 2026.10.14, today…`,today:`오늘`,previousMonth:`이전 달`,nextMonth:`다음 달`,clear:`지우기`,addTime:`시간 추가`,removeTime:`시간 제거`,time:`시간`},empty:{title:`아직 행이 없습니다`,addRow:`행 추가`,paste:`행 붙여넣기`,pasteHint:`Excel이나 Google Sheets에서 행을 복사한 뒤 여기서 ⌘V를 누르세요.`,importFile:`파일 가져오기`,noMatch:`표시할 행이 없습니다`,noMatchBody:`필터 때문에 모든 행이 제외되었습니다.`,clearFilter:`필터 해제`}},Iu=(e,t,n)=>[e>0?`${String(e)} ${e===1?`célula`:`células`}`:``,t>0?`${String(t)} ${t===1?`linha`:`linhas`}`:``,n>0?`${String(n)} ${n===1?`coluna`:`colunas`}`:``].filter(e=>e!==``).join(`, `),Lu=e=>e.toLocaleString(`pt-BR`),Ru={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Abrindo…`,unreadable:`Não é possível editar esta planilha agora: o arquivo dela não é um CSV que uma planilha consiga ler. Veja o que está errado.`,readOnlyLarge:e=>`Esta planilha tem ${e} MB: aqui ela é mostrada, não editada.`,untitled:`Sem título`,saved:`Salvo`,saving:`Salvando…`,unsaved:`Não salvo`,failed:`Não foi salvo`,rows:(e,t)=>e===t?`${Lu(t)} ${t===1?`linha`:`linhas`}`:`${Lu(e)} de ${Lu(t)} linhas`,find:`Localizar`,findPlaceholder:`Localizar na planilha`,matches:e=>e===1?`1 resultado`:`${String(e)} resultados`,types:{text:`Texto`,number:`Número`,select:`Lista suspensa`,"multi-select":`Seleção múltipla`,date:`Data`,checkbox:`Caixa de seleção`,url:`Link`,email:`Email`,phone:`Telefone`,file:`Arquivo`},auto:{button:e=>`Classificar e filtrar ${e}`,sortAsc:{text:`Classificar de A a Z`,number:`Classificar do menor para o maior`,date:`Classificar do mais antigo para o mais novo`,options:`Classificar na ordem das opções`},sortDesc:{text:`Classificar de Z a A`,number:`Classificar do maior para o menor`,date:`Classificar do mais novo para o mais antigo`,options:`Classificar na ordem inversa das opções`},search:`Pesquisar`,selectAll:`(Selecionar tudo)`,selectFound:`(Selecionar todos os resultados da pesquisa)`,blanks:`(Vazias)`,checked:`Marcada`,unchecked:`Desmarcada`,hasFile:`Tem arquivo`,more:e=>`Mais ${Lu(e)}. Pesquise para encontrá-los.`,none:`Nenhum valor corresponde.`,clear:`Limpar filtro`,ok:`OK`},look:{sorted:e=>`Classificado por ${e}`,filtered:e=>e.length===1?`Filtrado por ${e[0]??``}`:`Filtrado por ${String(e.length)} colunas`,hidden:e=>e===1?`1 coluna oculta`:`${String(e)} colunas ocultas`,clear:`Limpar`,note:`Só você vê esta classificação e este filtro.`},replace:{label:`Substituir`,with:`Substituir por`,one:`Substituir`,all:`Substituir tudo`,done:e=>`Substituído em ${String(e)} ${e===1?`célula`:`células`}.`},stats:{average:`Média`,count:`Contagem`,sum:`Soma`},column:{name:`Nome da coluna`,key:`Coluna-chave: o valor de cada linha é único`,add:`Adicionar uma coluna`,rename:`Renomear`,format:`Formato`,formats:{text:`Texto`,number:`Número`,currency:`Moeda`,percent:`Porcentagem`,date:`Data`,checkbox:`Caixa de seleção`,list:`Lista suspensa`,file:`Anexo`},addOption:`Adicionar uma opção`,newOption:e=>`Adicionar “${e}”`,confirm:`Excluir`,cancel:`Cancelar`,hide:`Ocultar coluna`,insertLeft:`Inserir coluna à esquerda`,insertRight:`Inserir coluna à direita`,remove:`Excluir coluna`,removeAsk:(e,t)=>`Excluir “${e}” e ${t===1?`seu valor`:`seus ${Lu(t)} valores`}? Você pode desfazer.`,taken:`Outra coluna já tem este nome.`,empty:`Uma coluna precisa de um nome.`,newName:e=>e===1?`Coluna`:`Coluna ${String(e)}`},row:{numbered:e=>`Linha ${String(e)}`,inFile:e=>`Linha ${String(e)} no arquivo`,of:(e,t)=>`Linha ${String(e)} de ${String(t)}`,hiddenFields:`Colunas ocultas`,insertAbove:`Inserir linha acima`,insertBelow:`Inserir linha abaixo`,remove:e=>e===1?`Excluir linha`:`Excluir ${String(e)} linhas`,expand:`Abrir linha`,newRow:`Nova linha`,record:`Linha`,previous:`Linha anterior`,next:`Próxima linha`,close:`Fechar`},cell:{copy:`Copiar`,cut:`Recortar`,paste:`Colar`,clear:`Limpar`,clearContents:`Limpar conteúdo`,notNumber:`Não é um número. Escreva algarismos, com ponto para decimais: 1234.5`,notDate:`Não é uma data. Escreva 2026-10-14 ou 2026-10-14T09:30`,notEmail:`Não é um endereço de email`,notUrl:`Um endereço não tem espaços`,open:`Abrir`,left:e=>e===1?`1 valor não cabia na coluna e ficou de fora.`:`${String(e)} valores não cabiam nas colunas e ficaram de fora.`,pasteHint:`Use ⌘V para colar.`},files:{notFound:`Não encontrado`,insert:`Inserir arquivo…`,add:`Adicionar arquivo`,adding:e=>e===1?`Adicionando 1 arquivo…`:`Adicionando ${String(e)} arquivos…`,tooLarge:(e,t)=>`${e} tem mais de ${String(t)} MB e não foi adicionado.`,failed:e=>`Não foi possível adicionar ${e}.`,notHere:`Só uma coluna de anexos guarda arquivos. Primeiro defina o formato da coluna como Anexo.`,remove:`Remover da célula`,of:(e,t)=>`${String(e)} de ${String(t)}`,previous:`Arquivo anterior`,next:`Próximo arquivo`,open:`Abrir em uma nova aba`,close:`Fechar`},review:{count:(e,t,n,r)=>`O ${e} alterou ${Iu(t,n,r)}`,keepAll:`Manter tudo`,undoAll:`Desfazer tudo`,keep:`Manter`,undo:`Desfazer`,was:`Antes`,added:e=>`Adicionado pelo ${e}`,changed:e=>`Alterado pelo ${e}`,away:`Alterado desde a última vez que você olhou`,countAway:(e,t,n)=>`Desde a última vez que você olhou: alterações em ${Iu(e,t,n)}`,empty:`vazio`,next:`Próxima`,previous:`Anterior`,position:(e,t)=>`${String(e)} de ${String(t)}`,conflicts:e=>e===1?`1 célula foi alterada por vocês dois: a sua versão foi mantida.`:`${String(e)} células foram alteradas por vocês dois: as suas versões foram mantidas.`},date:{placeholder:`2026-10-14, 2026/10/14…`,today:`Hoje`,previousMonth:`Mês anterior`,nextMonth:`Próximo mês`,clear:`Limpar`,addTime:`Adicionar um horário`,removeTime:`Remover o horário`,time:`Horário`},empty:{title:`Nenhuma linha ainda`,addRow:`Adicionar uma linha`,paste:`Colar linhas`,pasteHint:`Copie linhas no Excel ou no Planilhas Google e pressione ⌘V aqui.`,importFile:`Importar um arquivo`,noMatch:`Nenhuma linha para mostrar`,noMatchBody:`O filtro deixa todas as linhas de fora.`,clearFilter:`Limpar o filtro`}},zu=new Intl.PluralRules(`ru`),Bu=(e,t,n,r)=>{let i=zu.select(e);return i===`one`?t:i===`many`?r:n},Vu=(e,t,n,r)=>`${e.toLocaleString(`ru`)} ${Bu(e,t,n,r)}`,Hu=(e,t,n)=>[e>0?Vu(e,`ячейка`,`ячейки`,`ячеек`):``,t>0?Vu(t,`строка`,`строки`,`строк`):``,n>0?Vu(n,`столбец`,`столбца`,`столбцов`):``].filter(e=>e!==``).join(`, `),Uu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Открытие…`,unreadable:`Сейчас эту таблицу нельзя редактировать: её файл не является CSV, который может прочитать таблица. Вот что не так.`,readOnlyLarge:e=>`Размер таблицы — ${e} MB: здесь её можно только просматривать.`,untitled:`Без названия`,saved:`Сохранено`,saving:`Сохранение…`,unsaved:`Не сохранено`,failed:`Не сохранено`,rows:(e,t)=>e===t?Vu(t,`строка`,`строки`,`строк`):`${e.toLocaleString(`ru`)} из ${Vu(t,`строки`,`строк`,`строк`)}`,find:`Найти`,findPlaceholder:`Найти в таблице`,matches:e=>Vu(e,`совпадение`,`совпадения`,`совпадений`),types:{text:`Текст`,number:`Число`,select:`Раскрывающийся список`,"multi-select":`Список с несколькими значениями`,date:`Дата`,checkbox:`Флажок`,url:`Ссылка`,email:`Эл. почта`,phone:`Телефон`,file:`Файл`},auto:{button:e=>`Сортировка и фильтр: ${e}`,sortAsc:{text:`Сортировка от А до Я`,number:`Сортировка от минимального к максимальному`,date:`Сортировка от старых к новым`,options:`Сортировка в порядке вариантов`},sortDesc:{text:`Сортировка от Я до А`,number:`Сортировка от максимального к минимальному`,date:`Сортировка от новых к старым`,options:`Сортировка в обратном порядке вариантов`},search:`Поиск`,selectAll:`(Выделить все)`,selectFound:`(Выделить все результаты поиска)`,blanks:`(Пустые)`,checked:`Отмечено`,unchecked:`Не отмечено`,hasFile:`Есть файл`,more:e=>`Ещё ${e.toLocaleString(`ru`)}. Воспользуйтесь поиском.`,none:`Нет подходящих значений.`,clear:`Удалить фильтр`,ok:`ОК`},look:{sorted:e=>`Сортировка: ${e}`,filtered:e=>e.length===1?`Фильтр: ${e[0]??``}`:`Фильтр по ${Vu(e.length,`столбцу`,`столбцам`,`столбцам`)}`,hidden:e=>`Скрыто: ${Vu(e,`столбец`,`столбца`,`столбцов`)}`,clear:`Сбросить`,note:`Эту сортировку и фильтр видите только вы.`},replace:{label:`Заменить`,with:`Заменить на`,one:`Заменить`,all:`Заменить все`,done:e=>`Заменено в ${Vu(e,`ячейке`,`ячейках`,`ячейках`)}.`},stats:{average:`Среднее`,count:`Количество`,sum:`Сумма`},column:{name:`Имя столбца`,key:`Ключевой столбец: значение в каждой строке своё`,add:`Добавить столбец`,rename:`Переименовать`,format:`Формат`,formats:{text:`Текст`,number:`Число`,currency:`Валюта`,percent:`Процент`,date:`Дата`,checkbox:`Флажок`,list:`Раскрывающийся список`,file:`Вложение`},addOption:`Добавить вариант`,newOption:e=>`Добавить «${e}»`,confirm:`Удалить`,cancel:`Отменить`,hide:`Скрыть столбец`,insertLeft:`Вставить столбец слева`,insertRight:`Вставить столбец справа`,remove:`Удалить столбец`,removeAsk:(e,t)=>`Удалить «${e}» и ${t===1?`его значение`:`его ${Vu(t,`значение`,`значения`,`значений`)}`}? Это можно отменить.`,taken:`Столбец с таким именем уже есть.`,empty:`У столбца должно быть имя.`,newName:e=>e===1?`Столбец`:`Столбец ${String(e)}`},row:{numbered:e=>`Строка ${String(e)}`,inFile:e=>`Строка ${String(e)} в файле`,of:(e,t)=>`Строка ${String(e)} из ${String(t)}`,hiddenFields:`Скрытые столбцы`,insertAbove:`Вставить строку выше`,insertBelow:`Вставить строку ниже`,remove:e=>e===1?`Удалить строку`:`Удалить ${Vu(e,`строку`,`строки`,`строк`)}`,expand:`Открыть строку`,newRow:`Новая строка`,record:`Строка`,previous:`Предыдущая строка`,next:`Следующая строка`,close:`Закрыть`},cell:{copy:`Скопировать`,cut:`Вырезать`,paste:`Вставить`,clear:`Очистить`,clearContents:`Очистить содержимое`,notNumber:`Это не число. Пишите цифры, дробную часть — через точку: 1234.5`,notDate:`Это не дата. Пишите 2026-10-14 или 2026-10-14T09:30`,notEmail:`Это не адрес электронной почты`,notUrl:`В адресе не может быть пробелов`,open:`Открыть`,left:e=>e===1?`1 значение не подошло к своему столбцу и не вставлено.`:`${Vu(e,`значение`,`значения`,`значений`)} не подошли к своим столбцам и не вставлены.`,pasteHint:`Чтобы вставить, нажмите ⌘V.`},files:{notFound:`Не найден`,insert:`Вставить файл…`,add:`Добавить файл`,adding:e=>`Добавление: ${Vu(e,`файл`,`файла`,`файлов`)}…`,tooLarge:(e,t)=>`${e} больше ${String(t)} MB и не добавлен.`,failed:e=>`Не удалось добавить ${e}.`,notHere:`Файлы можно хранить только в столбце вложений. Сначала задайте столбцу формат «Вложение».`,remove:`Удалить из ячейки`,of:(e,t)=>`${String(e)} из ${String(t)}`,previous:`Предыдущий файл`,next:`Следующий файл`,open:`Открыть в новой вкладке`,close:`Закрыть`},review:{count:(e,t,n,r)=>`${e} изменил: ${Hu(t,n,r)}`,keepAll:`Оставить все`,undoAll:`Отменить все`,keep:`Оставить`,undo:`Отменить`,was:`Было`,added:e=>`Добавил ${e}`,changed:e=>`Изменил ${e}`,away:`Изменено с вашего последнего просмотра`,countAway:(e,t,n)=>`С вашего последнего просмотра изменено: ${Hu(e,t,n)}`,empty:`пусто`,next:`Следующее`,previous:`Предыдущее`,position:(e,t)=>`${String(e)} из ${String(t)}`,conflicts:e=>`${e===1?`1 ячейку`:Vu(e,`ячейку`,`ячейки`,`ячеек`)} изменили вы оба: оставлены ваши значения.`},date:{placeholder:`2026-10-14, 2026/10/14…`,today:`Сегодня`,previousMonth:`Предыдущий месяц`,nextMonth:`Следующий месяц`,clear:`Очистить`,addTime:`Добавить время`,removeTime:`Убрать время`,time:`Время`},empty:{title:`Строк пока нет`,addRow:`Добавить строку`,paste:`Вставить строки`,pasteHint:`Скопируйте строки в Excel или Google Таблицах и нажмите здесь ⌘V.`,importFile:`Импортировать файл`,noMatch:`Нет строк для показа`,noMatchBody:`Фильтр скрывает все строки.`,clearFilter:`Удалить фильтр`}},Wu=(e,t,n)=>[e>0?`${String(e)} เซลล์`:``,t>0?`${String(t)} แถว`:``,n>0?`${String(n)} คอลัมน์`:``].filter(e=>e!==``).join(`, `),Gu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`กำลังเปิด…`,unreadable:`ยังแก้ไขชีตนี้ไม่ได้ในตอนนี้ เพราะไฟล์ไม่ใช่ CSV ที่ชีตอ่านได้ ปัญหามีดังนี้`,readOnlyLarge:e=>`ชีตนี้มีขนาด ${e} MB จึงแสดงได้อย่างเดียว แก้ไขที่นี่ไม่ได้`,untitled:`ไม่มีชื่อ`,saved:`บันทึกแล้ว`,saving:`กำลังบันทึก…`,unsaved:`ยังไม่ได้บันทึก`,failed:`บันทึกไม่สำเร็จ`,rows:(e,t)=>e===t?`${t.toLocaleString(`th`)} แถว`:`${e.toLocaleString(`th`)} จาก ${t.toLocaleString(`th`)} แถว`,find:`ค้นหา`,findPlaceholder:`ค้นหาในชีต`,matches:e=>`ตรงกัน ${String(e)} รายการ`,types:{text:`ข้อความ`,number:`ตัวเลข`,select:`รายการดรอปดาวน์`,"multi-select":`รายการหลายค่า`,date:`วันที่`,checkbox:`กล่องกาเครื่องหมาย`,url:`ลิงก์`,email:`อีเมล`,phone:`โทรศัพท์`,file:`ไฟล์`},auto:{button:e=>`เรียงลำดับและกรอง ${e}`,sortAsc:{text:`เรียงลำดับจาก A ถึง Z`,number:`เรียงลำดับจากน้อยที่สุดไปหามากที่สุด`,date:`เรียงลำดับจากเก่าที่สุดไปหาใหม่ที่สุด`,options:`เรียงลำดับตามตัวเลือก`},sortDesc:{text:`เรียงลำดับจาก Z ถึง A`,number:`เรียงลำดับจากมากที่สุดไปหาน้อยที่สุด`,date:`เรียงลำดับจากใหม่ที่สุดไปหาเก่าที่สุด`,options:`เรียงลำดับย้อนกลับตามตัวเลือก`},search:`ค้นหา`,selectAll:`(เลือกทั้งหมด)`,selectFound:`(เลือกผลการค้นหาทั้งหมด)`,blanks:`(ช่องว่าง)`,checked:`เลือกแล้ว`,unchecked:`ไม่ได้เลือก`,hasFile:`มีไฟล์`,more:e=>`อีก ${e.toLocaleString(`th`)} รายการ ค้นหาเพื่อดู`,none:`ไม่มีค่าที่ตรงกัน`,clear:`ล้างตัวกรอง`,ok:`ตกลง`},look:{sorted:e=>`เรียงลำดับตาม ${e}`,filtered:e=>e.length===1?`กรองตาม ${e[0]??``}`:`กรองตาม ${String(e.length)} คอลัมน์`,hidden:e=>`ซ่อน ${String(e)} คอลัมน์`,clear:`ล้าง`,note:`การเรียงลำดับและการกรองนี้เห็นเฉพาะคุณ`},replace:{label:`แทนที่`,with:`แทนที่ด้วย`,one:`แทนที่`,all:`แทนที่ทั้งหมด`,done:e=>`แทนที่แล้วใน ${String(e)} เซลล์`},stats:{average:`ค่าเฉลี่ย`,count:`จำนวนนับ`,sum:`ผลรวม`},column:{name:`ชื่อคอลัมน์`,key:`คอลัมน์คีย์: ค่าในแต่ละแถวต้องไม่ซ้ำกัน`,add:`เพิ่มคอลัมน์`,rename:`เปลี่ยนชื่อ`,format:`รูปแบบ`,formats:{text:`ข้อความ`,number:`ตัวเลข`,currency:`สกุลเงิน`,percent:`เปอร์เซ็นต์`,date:`วันที่`,checkbox:`กล่องกาเครื่องหมาย`,list:`รายการดรอปดาวน์`,file:`ไฟล์แนบ`},addOption:`เพิ่มตัวเลือก`,newOption:e=>`เพิ่ม “${e}”`,confirm:`ลบ`,cancel:`ยกเลิก`,hide:`ซ่อนคอลัมน์`,insertLeft:`แทรกคอลัมน์ทางซ้าย`,insertRight:`แทรกคอลัมน์ทางขวา`,remove:`ลบคอลัมน์`,removeAsk:(e,t)=>`ลบ “${e}” และค่าทั้ง ${t.toLocaleString(`th`)} ค่าหรือไม่ คุณเลิกทำได้`,taken:`มีคอลัมน์อื่นใช้ชื่อนี้แล้ว`,empty:`คอลัมน์ต้องมีชื่อ`,newName:e=>e===1?`คอลัมน์`:`คอลัมน์ ${String(e)}`},row:{numbered:e=>`แถว ${String(e)}`,inFile:e=>`แถว ${String(e)} ในไฟล์`,of:(e,t)=>`แถว ${String(e)} จาก ${String(t)}`,hiddenFields:`คอลัมน์ที่ซ่อน`,insertAbove:`แทรกแถวด้านบน`,insertBelow:`แทรกแถวด้านล่าง`,remove:e=>e===1?`ลบแถว`:`ลบ ${String(e)} แถว`,expand:`เปิดแถว`,newRow:`แถวใหม่`,record:`แถว`,previous:`แถวก่อนหน้า`,next:`แถวถัดไป`,close:`ปิด`},cell:{copy:`คัดลอก`,cut:`ตัด`,paste:`วาง`,clear:`ล้าง`,clearContents:`ล้างเนื้อหา`,notNumber:`ไม่ใช่ตัวเลข ใช้ตัวเลขและจุดทศนิยม เช่น 1234.5`,notDate:`ไม่ใช่วันที่ ใช้รูปแบบ 2026-10-14 หรือ 2026-10-14T09:30`,notEmail:`ไม่ใช่ที่อยู่อีเมล`,notUrl:`ที่อยู่ต้องไม่มีช่องว่าง`,open:`เปิด`,left:e=>`${String(e)} ค่าไม่ตรงกับคอลัมน์ จึงไม่ได้ใส่`,pasteHint:`ใช้ ⌘V เพื่อวาง`},files:{notFound:`ไม่พบไฟล์`,insert:`แทรกไฟล์…`,add:`เพิ่มไฟล์`,adding:e=>`กำลังเพิ่ม ${String(e)} ไฟล์…`,tooLarge:(e,t)=>`${e} มีขนาดเกิน ${String(t)} MB จึงไม่ได้เพิ่ม`,failed:e=>`เพิ่ม ${e} ไม่สำเร็จ`,notHere:`เฉพาะคอลัมน์ไฟล์แนบเท่านั้นที่เก็บไฟล์ได้ ตั้งรูปแบบของคอลัมน์เป็นไฟล์แนบก่อน`,remove:`เอาออกจากเซลล์`,of:(e,t)=>`${String(e)} จาก ${String(t)}`,previous:`ไฟล์ก่อนหน้า`,next:`ไฟล์ถัดไป`,open:`เปิดในแท็บใหม่`,close:`ปิด`},review:{count:(e,t,n,r)=>`${e} เปลี่ยน ${Wu(t,n,r)}`,keepAll:`เก็บทั้งหมด`,undoAll:`เลิกทำทั้งหมด`,keep:`เก็บ`,undo:`เลิกทำ`,was:`ก่อนหน้า`,added:e=>`เพิ่มโดย ${e}`,changed:e=>`เปลี่ยนโดย ${e}`,away:`เปลี่ยนไปหลังจากที่คุณดูครั้งล่าสุด`,countAway:(e,t,n)=>`หลังจากที่คุณดูครั้งล่าสุด: เปลี่ยนไป ${Wu(e,t,n)}`,empty:`ว่าง`,next:`ถัดไป`,previous:`ก่อนหน้า`,position:(e,t)=>`${String(e)} จาก ${String(t)}`,conflicts:e=>`${String(e)} เซลล์ถูกเปลี่ยนโดยทั้งสองฝ่าย จึงเก็บของคุณไว้`},date:{placeholder:`2026-10-14, today, Oct 14…`,today:`วันนี้`,previousMonth:`เดือนก่อนหน้า`,nextMonth:`เดือนถัดไป`,clear:`ล้าง`,addTime:`เพิ่มเวลา`,removeTime:`เอาเวลาออก`,time:`เวลา`},empty:{title:`ยังไม่มีแถว`,addRow:`เพิ่มแถว`,paste:`วางแถว`,pasteHint:`คัดลอกแถวใน Excel หรือ Google Sheets แล้วกด ⌘V ที่นี่`,importFile:`นำเข้าไฟล์`,noMatch:`ไม่มีแถวให้แสดง`,noMatchBody:`ตัวกรองซ่อนทุกแถวไว้`,clearFilter:`ล้างตัวกรอง`}},Ku=(e,t,n)=>[e>0?`${String(e)} hücre`:``,t>0?`${String(t)} satır`:``,n>0?`${String(n)} sütun`:``].filter(e=>e!==``).join(`, `),qu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Açılıyor…`,unreadable:`Bu tablo şu anda düzenlenemiyor: dosyası, bir tablonun okuyabileceği CSV değil. Sorunlar aşağıda.`,readOnlyLarge:e=>`Bu tablo ${e} MB: burada yalnızca gösterilir, düzenlenmez.`,untitled:`Adsız`,saved:`Kaydedildi`,saving:`Kaydediliyor…`,unsaved:`Kaydedilmedi`,failed:`Kaydedilemedi`,rows:(e,t)=>e===t?`${t.toLocaleString(`tr`)} satır`:`${t.toLocaleString(`tr`)} satırdan ${e.toLocaleString(`tr`)}`,find:`Bul`,findPlaceholder:`Tabloda bul`,matches:e=>`${String(e)} eşleşme`,types:{text:`Metin`,number:`Sayı`,select:`Açılır liste`,"multi-select":`Çoklu seçim listesi`,date:`Tarih`,checkbox:`Onay kutusu`,url:`Bağlantı`,email:`E-posta`,phone:`Telefon`,file:`Dosya`},auto:{button:e=>`Sırala ve filtre uygula: ${e}`,sortAsc:{text:`A'dan Z'ye sırala`,number:`Küçükten büyüğe sırala`,date:`Eskiden yeniye sırala`,options:`Seçenek sırasına göre sırala`},sortDesc:{text:`Z'den A'ya sırala`,number:`Büyükten küçüğe sırala`,date:`Yeniden eskiye sırala`,options:`Ters seçenek sırasına göre sırala`},search:`Ara`,selectAll:`(Tümünü seç)`,selectFound:`(Tüm arama sonuçlarını seç)`,blanks:`(Boş)`,checked:`İşaretli`,unchecked:`İşaretsiz`,hasFile:`Dosyası var`,more:e=>`${e.toLocaleString(`tr`)} tane daha. Bulmak için arayın.`,none:`Eşleşen değer yok.`,clear:`Filtreyi temizle`,ok:`Tamam`},look:{sorted:e=>`Sıralama: ${e}`,filtered:e=>e.length===1?`Filtre: ${e[0]??``}`:`${String(e.length)} sütunda filtre`,hidden:e=>`${String(e)} sütun gizli`,clear:`Temizle`,note:`Bu sıralamayı ve filtreyi yalnızca siz görürsünüz.`},replace:{label:`Değiştir`,with:`Yeni değer`,one:`Değiştir`,all:`Tümünü değiştir`,done:e=>`${String(e)} hücrede değiştirildi.`},stats:{average:`Ortalama`,count:`Sayım`,sum:`Toplam`},column:{name:`Sütun adı`,key:`Anahtar sütun: her satırın değeri kendine özgüdür`,add:`Sütun ekle`,rename:`Yeniden adlandır`,format:`Biçim`,formats:{text:`Metin`,number:`Sayı`,currency:`Para birimi`,percent:`Yüzde`,date:`Tarih`,checkbox:`Onay kutusu`,list:`Açılır liste`,file:`Ek`},addOption:`Seçenek ekle`,newOption:e=>`“${e}” ekle`,confirm:`Sil`,cancel:`Vazgeç`,hide:`Sütunu gizle`,insertLeft:`Sola sütun ekle`,insertRight:`Sağa sütun ekle`,remove:`Sütunu sil`,removeAsk:(e,t)=>`“${e}” ve içindeki ${t.toLocaleString(`tr`)} değer silinsin mi? Geri alabilirsiniz.`,taken:`Bu ad başka bir sütunda kullanılıyor.`,empty:`Sütunun bir adı olmalı.`,newName:e=>e===1?`Sütun`:`Sütun ${String(e)}`},row:{numbered:e=>`Satır ${String(e)}`,inFile:e=>`Dosyada satır ${String(e)}`,of:(e,t)=>`Satır ${String(e)} / ${String(t)}`,hiddenFields:`Gizli sütunlar`,insertAbove:`Üste satır ekle`,insertBelow:`Alta satır ekle`,remove:e=>e===1?`Satırı sil`:`${String(e)} satırı sil`,expand:`Satırı aç`,newRow:`Yeni satır`,record:`Satır`,previous:`Önceki satır`,next:`Sonraki satır`,close:`Kapat`},cell:{copy:`Kopyala`,cut:`Kes`,paste:`Yapıştır`,clear:`Temizle`,clearContents:`İçeriği temizle`,notNumber:`Sayı değil. Rakamlarla, ondalık için nokta kullanarak yazın: 1234.5`,notDate:`Tarih değil. 2026-10-14 ya da 2026-10-14T09:30 yazın`,notEmail:`E-posta adresi değil`,notUrl:`Adreste boşluk olmaz`,open:`Aç`,left:e=>`${String(e)} değer sütununa uymadığı için dışarıda bırakıldı.`,pasteHint:`Yapıştırmak için ⌘V kullanın.`},files:{notFound:`Bulunamadı`,insert:`Dosya ekle…`,add:`Dosya ekle`,adding:e=>`${String(e)} dosya ekleniyor…`,tooLarge:(e,t)=>`${e} ${String(t)} MB'tan büyük olduğu için eklenmedi.`,failed:e=>`${e} eklenemedi.`,notHere:`Dosyaları yalnızca ek sütunu tutar. Önce sütunun biçimini Ek olarak ayarlayın.`,remove:`Hücreden kaldır`,of:(e,t)=>`${String(e)} / ${String(t)}`,previous:`Önceki dosya`,next:`Sonraki dosya`,open:`Yeni sekmede aç`,close:`Kapat`},review:{count:(e,t,n,r)=>`${e} değiştirdi: ${Ku(t,n,r)}`,keepAll:`Tümünü koru`,undoAll:`Tümünü geri al`,keep:`Koru`,undo:`Geri al`,was:`Önce`,added:e=>`${e} ekledi`,changed:e=>`${e} değiştirdi`,away:`Son baktığınızdan beri değişti`,countAway:(e,t,n)=>`Son baktığınızdan beri değişen: ${Ku(e,t,n)}`,empty:`boş`,next:`Sonraki`,previous:`Önceki`,position:(e,t)=>`${String(e)} / ${String(t)}`,conflicts:e=>`${String(e)} hücreyi ikiniz de değiştirdiniz: sizinkiler korundu.`},date:{placeholder:`2026-10-14, 2026.10.14…`,today:`Bugün`,previousMonth:`Önceki ay`,nextMonth:`Sonraki ay`,clear:`Temizle`,addTime:`Saat ekle`,removeTime:`Saati kaldır`,time:`Saat`},empty:{title:`Henüz satır yok`,addRow:`Satır ekle`,paste:`Satırları yapıştır`,pasteHint:`Satırları Excel'de ya da Google E-Tablolar'da kopyalayın, sonra burada ⌘V'ye basın.`,importFile:`Dosya içe aktar`,noMatch:`Gösterilecek satır yok`,noMatchBody:`Filtre tüm satırları dışarıda bırakıyor.`,clearFilter:`Filtreyi temizle`}},Ju=(e,t,n)=>[e>0?`${String(e)} ô`:``,t>0?`${String(t)} hàng`:``,n>0?`${String(n)} cột`:``].filter(e=>e!==``).join(`, `),Yu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`Đang mở…`,unreadable:`Hiện chưa thể sửa bảng tính này: tệp của nó không phải CSV mà bảng tính đọc được. Đây là chỗ sai.`,readOnlyLarge:e=>`Bảng tính này nặng ${e} MB: ở đây chỉ xem được, không sửa được.`,untitled:`Không có tiêu đề`,saved:`Đã lưu`,saving:`Đang lưu…`,unsaved:`Chưa lưu`,failed:`Không lưu được`,rows:(e,t)=>e===t?`${t.toLocaleString(`vi`)} hàng`:`${e.toLocaleString(`vi`)} / ${t.toLocaleString(`vi`)} hàng`,find:`Tìm`,findPlaceholder:`Tìm trong bảng tính`,matches:e=>`${String(e)} kết quả`,types:{text:`Văn bản`,number:`Số`,select:`Danh sách thả xuống`,"multi-select":`Danh sách chọn nhiều`,date:`Ngày`,checkbox:`Hộp kiểm`,url:`Liên kết`,email:`Email`,phone:`Điện thoại`,file:`Tệp`},auto:{button:e=>`Sắp xếp và lọc ${e}`,sortAsc:{text:`Sắp xếp từ A đến Z`,number:`Sắp xếp từ nhỏ nhất đến lớn nhất`,date:`Sắp xếp từ cũ nhất đến mới nhất`,options:`Sắp xếp theo thứ tự tùy chọn`},sortDesc:{text:`Sắp xếp từ Z đến A`,number:`Sắp xếp từ lớn nhất đến nhỏ nhất`,date:`Sắp xếp từ mới nhất đến cũ nhất`,options:`Sắp xếp theo thứ tự tùy chọn đảo ngược`},search:`Tìm kiếm`,selectAll:`(Chọn tất cả)`,selectFound:`(Chọn tất cả kết quả tìm kiếm)`,blanks:`(Trống)`,checked:`Đã chọn`,unchecked:`Chưa chọn`,hasFile:`Có tệp`,more:e=>`Còn ${e.toLocaleString(`vi`)} giá trị nữa. Hãy tìm kiếm để thấy.`,none:`Không có giá trị nào khớp.`,clear:`Xóa bộ lọc`,ok:`OK`},look:{sorted:e=>`Sắp xếp theo ${e}`,filtered:e=>e.length===1?`Lọc theo ${e[0]??``}`:`Lọc theo ${String(e.length)} cột`,hidden:e=>`Đã ẩn ${String(e)} cột`,clear:`Xóa`,note:`Chỉ bạn thấy cách sắp xếp và lọc này.`},replace:{label:`Thay thế`,with:`Thay thế bằng`,one:`Thay thế`,all:`Thay thế tất cả`,done:e=>`Đã thay thế trong ${String(e)} ô.`},stats:{average:`Trung bình`,count:`Số đếm`,sum:`Tổng`},column:{name:`Tên cột`,key:`Cột khóa: giá trị của mỗi hàng là duy nhất`,add:`Thêm cột`,rename:`Đổi tên`,format:`Định dạng`,formats:{text:`Văn bản`,number:`Số`,currency:`Tiền tệ`,percent:`Phần trăm`,date:`Ngày`,checkbox:`Hộp kiểm`,list:`Danh sách thả xuống`,file:`Tệp đính kèm`},addOption:`Thêm tùy chọn`,newOption:e=>`Thêm “${e}”`,confirm:`Xóa`,cancel:`Hủy`,hide:`Ẩn cột`,insertLeft:`Chèn cột bên trái`,insertRight:`Chèn cột bên phải`,remove:`Xóa cột`,removeAsk:(e,t)=>`Xóa “${e}” và ${t.toLocaleString(`vi`)} giá trị của nó? Bạn có thể hoàn tác.`,taken:`Đã có cột khác mang tên này.`,empty:`Cột cần có tên.`,newName:e=>e===1?`Cột`:`Cột ${String(e)}`},row:{numbered:e=>`Hàng ${String(e)}`,inFile:e=>`Hàng ${String(e)} trong tệp`,of:(e,t)=>`Hàng ${String(e)} / ${String(t)}`,hiddenFields:`Cột ẩn`,insertAbove:`Chèn hàng phía trên`,insertBelow:`Chèn hàng phía dưới`,remove:e=>e===1?`Xóa hàng`:`Xóa ${String(e)} hàng`,expand:`Mở hàng`,newRow:`Hàng mới`,record:`Hàng`,previous:`Hàng trước`,next:`Hàng sau`,close:`Đóng`},cell:{copy:`Sao chép`,cut:`Cắt`,paste:`Dán`,clear:`Xóa`,clearContents:`Xóa nội dung`,notNumber:`Không phải số. Hãy viết chữ số, dùng dấu chấm cho phần thập phân: 1234.5`,notDate:`Không phải ngày. Hãy viết 2026-10-14 hoặc 2026-10-14T09:30`,notEmail:`Không phải địa chỉ email`,notUrl:`Địa chỉ không được có dấu cách`,open:`Mở`,left:e=>`${String(e)} giá trị không hợp với cột của nó nên đã được bỏ qua.`,pasteHint:`Dùng ⌘V để dán.`},files:{notFound:`Không tìm thấy`,insert:`Chèn tệp…`,add:`Thêm tệp`,adding:e=>`Đang thêm ${String(e)} tệp…`,tooLarge:(e,t)=>`${e} lớn hơn ${String(t)} MB nên không được thêm.`,failed:e=>`Không thêm được ${e}.`,notHere:`Chỉ cột tệp đính kèm mới chứa được tệp. Hãy đặt định dạng của cột thành Tệp đính kèm trước.`,remove:`Xóa khỏi ô`,of:(e,t)=>`${String(e)} / ${String(t)}`,previous:`Tệp trước`,next:`Tệp sau`,open:`Mở trong tab mới`,close:`Đóng`},review:{count:(e,t,n,r)=>`${e} đã thay đổi ${Ju(t,n,r)}`,keepAll:`Giữ tất cả`,undoAll:`Hoàn tác tất cả`,keep:`Giữ`,undo:`Hoàn tác`,was:`Trước đó`,added:e=>`Do ${e} thêm`,changed:e=>`Do ${e} thay đổi`,away:`Đã thay đổi từ lần cuối bạn xem`,countAway:(e,t,n)=>`Từ lần cuối bạn xem: ${Ju(e,t,n)} đã thay đổi`,empty:`trống`,next:`Tiếp`,previous:`Trước`,position:(e,t)=>`${String(e)} / ${String(t)}`,conflicts:e=>`${String(e)} ô đã bị cả hai bên thay đổi: giữ lại bản của bạn.`},date:{placeholder:`2026-10-14, 2026/10/14…`,today:`Hôm nay`,previousMonth:`Tháng trước`,nextMonth:`Tháng sau`,clear:`Xóa`,addTime:`Thêm giờ`,removeTime:`Bỏ giờ`,time:`Giờ`},empty:{title:`Chưa có hàng nào`,addRow:`Thêm hàng`,paste:`Dán hàng`,pasteHint:`Sao chép các hàng trong Excel hoặc Google Trang tính, rồi nhấn ⌘V tại đây.`,importFile:`Nhập tệp`,noMatch:`Không có hàng nào để hiển thị`,noMatchBody:`Bộ lọc đã loại bỏ mọi hàng.`,clearFilter:`Xóa bộ lọc`}},Xu=(e,t,n)=>[e>0?`${String(e)} 个单元格`:``,t>0?`${String(t)} 行`:``,n>0?`${String(n)} 列`:``].filter(e=>e!==``).join(`、`),Zu={agent:`AllyHub`,agentInline:`AllyHub`,loading:`正在打开…`,unreadable:`这张表暂时无法编辑:它的文件不是可读的 CSV。问题如下。`,readOnlyLarge:e=>`这张表有 ${e} MB,在这里只能查看,不能编辑。`,untitled:`未命名`,saved:`已保存`,saving:`正在保存…`,unsaved:`未保存`,failed:`保存失败`,rows:(e,t)=>e===t?`${String(t)} 行`:`${String(e)} / ${String(t)} 行`,find:`查找`,findPlaceholder:`在表中查找`,matches:e=>`${String(e)} 处`,types:{text:`文本`,number:`数字`,select:`下拉列表`,"multi-select":`多选列表`,date:`日期`,checkbox:`复选框`,url:`链接`,email:`邮箱`,phone:`电话`,file:`文件`},auto:{button:e=>`排序和筛选:${e}`,sortAsc:{text:`从 A 到 Z 排序`,number:`从小到大排序`,date:`从早到晚排序`,options:`按选项顺序排序`},sortDesc:{text:`从 Z 到 A 排序`,number:`从大到小排序`,date:`从晚到早排序`,options:`按选项倒序排序`},search:`搜索`,selectAll:`(全选)`,selectFound:`(全选搜索结果)`,blanks:`(空白)`,checked:`已勾选`,unchecked:`未勾选`,hasFile:`有文件`,more:e=>`还有 ${String(e)} 个,搜索即可找到。`,none:`没有匹配的值。`,clear:`清除筛选`,ok:`确定`},look:{sorted:e=>`按“${e}”排序`,filtered:e=>e.length===1?`按“${e[0]??``}”筛选`:`按 ${String(e.length)} 列筛选`,hidden:e=>`隐藏了 ${String(e)} 列`,clear:`清除`,note:`这个排序和筛选只有你能看到。`},replace:{label:`替换`,with:`替换为`,one:`替换`,all:`全部替换`,done:e=>`替换了 ${String(e)} 个单元格。`},stats:{average:`平均值`,count:`计数`,sum:`求和`},column:{name:`列名`,key:`主键列:每一行的值都不重复`,add:`添加列`,rename:`重命名`,format:`格式`,formats:{text:`文本`,number:`数字`,currency:`货币`,percent:`百分比`,date:`日期`,checkbox:`复选框`,list:`下拉列表`,file:`附件`},addOption:`添加选项`,newOption:e=>`添加“${e}”`,confirm:`删除`,cancel:`取消`,hide:`隐藏列`,insertLeft:`在左侧插入列`,insertRight:`在右侧插入列`,remove:`删除列`,removeAsk:(e,t)=>`删除“${e}”及其 ${String(t)} 个值?可以撤销。`,taken:`已有同名的列。`,empty:`列需要一个名称。`,newName:e=>e===1?`列`:`列 ${String(e)}`},row:{numbered:e=>`第 ${String(e)} 行`,inFile:e=>`文件里的第 ${String(e)} 行`,of:(e,t)=>`第 ${String(e)} 行,共 ${String(t)} 行`,hiddenFields:`隐藏的列`,insertAbove:`在上方插入行`,insertBelow:`在下方插入行`,remove:e=>e===1?`删除行`:`删除 ${String(e)} 行`,expand:`展开行`,newRow:`新行`,record:`行`,previous:`上一行`,next:`下一行`,close:`关闭`},cell:{copy:`复制`,cut:`剪切`,paste:`粘贴`,clear:`清除`,clearContents:`清除内容`,notNumber:`不是数字。请写数字,小数用点:1234.5`,notDate:`不是日期。请写 2026-10-14 或 2026-10-14T09:30`,notEmail:`不是邮箱地址`,notUrl:`地址里不能有空格`,open:`打开`,left:e=>`有 ${String(e)} 个值不符合所在列,没有粘贴。`,pasteHint:`请用 ⌘V 粘贴。`},files:{notFound:`找不到文件`,insert:`插入文件…`,add:`添加文件`,adding:e=>`正在添加 ${String(e)} 个文件…`,tooLarge:(e,t)=>`${e} 超过 ${String(t)} MB,没有添加。`,failed:e=>`${e} 没能添加。`,notHere:`只有附件列能放文件。请先把这一列的格式设为附件。`,remove:`从单元格移除`,of:(e,t)=>`第 ${String(e)} 个,共 ${String(t)} 个`,previous:`上一个文件`,next:`下一个文件`,open:`在新标签页打开`,close:`关闭`},review:{count:(e,t,n,r)=>Au(e,`改动了 ${Xu(t,n,r)}`),keepAll:`全部保留`,undoAll:`全部撤销`,keep:`保留`,undo:`撤销`,was:`之前`,added:e=>Au(e,`新加的`),changed:e=>Au(e,`改的`),away:`你上次查看之后改的`,countAway:(e,t,n)=>`你上次查看之后,改动了 ${Xu(e,t,n)}`,empty:`空`,next:`下一处`,previous:`上一处`,position:(e,t)=>`${String(e)} / ${String(t)}`,conflicts:e=>`有 ${String(e)} 个单元格你们都改了:保留了你的。`},date:{placeholder:`2026-10-14、今天、明天…`,today:`今天`,previousMonth:`上个月`,nextMonth:`下个月`,clear:`清除`,addTime:`加上时间`,removeTime:`去掉时间`,time:`时间`},empty:{title:`还没有行`,addRow:`新建一行`,paste:`粘贴几行`,pasteHint:`在 Excel 或 Google 表格里复制几行,再在这里按 ⌘V。`,importFile:`导入文件`,noMatch:`没有可显示的行`,noMatchBody:`筛选把每一行都排除了。`,clearFilter:`清除筛选`}},Qu=(e,t,n)=>[e>0?`${String(e)} 個儲存格`:``,t>0?`${String(t)} 列`:``,n>0?`${String(n)} 欄`:``].filter(e=>e!==``).join(`、`),$u=a({en:pu,"zh-cn":Zu,"zh-tw":{agent:`AllyHub`,agentInline:`AllyHub`,loading:`正在打開…`,unreadable:`目前無法編輯這張工作表:它的檔案不是可讀取的 CSV。問題如下。`,readOnlyLarge:e=>`這張工作表有 ${e} MB,在這裡只能檢視,無法編輯。`,untitled:`未命名`,saved:`已儲存`,saving:`正在儲存…`,unsaved:`未儲存`,failed:`未能儲存`,rows:(e,t)=>e===t?`${t.toLocaleString(`zh-TW`)} 列`:`${e.toLocaleString(`zh-TW`)} / ${t.toLocaleString(`zh-TW`)} 列`,find:`尋找`,findPlaceholder:`在工作表中尋找`,matches:e=>`${String(e)} 個符合項目`,types:{text:`文字`,number:`數值`,select:`下拉式清單`,"multi-select":`多選清單`,date:`日期`,checkbox:`核取方塊`,url:`連結`,email:`電子郵件`,phone:`電話`,file:`檔案`},auto:{button:e=>`排序與篩選:${e}`,sortAsc:{text:`從 A 到 Z 排序`,number:`從最小到最大排序`,date:`從最舊到最新排序`,options:`依選項順序排序`},sortDesc:{text:`從 Z 到 A 排序`,number:`從最大到最小排序`,date:`從最新到最舊排序`,options:`依選項反向順序排序`},search:`搜尋`,selectAll:`(全選)`,selectFound:`(選取所有搜尋結果)`,blanks:`(空格)`,checked:`已勾選`,unchecked:`未勾選`,hasFile:`有檔案`,more:e=>`還有 ${e.toLocaleString(`zh-TW`)} 個,請用搜尋找到它們。`,none:`沒有符合的值。`,clear:`清除篩選`,ok:`確定`},look:{sorted:e=>`依「${e}」排序`,filtered:e=>e.length===1?`依「${e[0]??``}」篩選`:`依 ${String(e.length)} 欄篩選`,hidden:e=>`已隱藏 ${String(e)} 欄`,clear:`清除`,note:`這個排序和篩選只有你看得到。`},replace:{label:`取代`,with:`取代為`,one:`取代`,all:`全部取代`,done:e=>`已在 ${String(e)} 個儲存格中取代。`},stats:{average:`平均值`,count:`項目個數`,sum:`加總`},column:{name:`欄名稱`,key:`主鍵欄:每一列的值都不重複`,add:`新增欄`,rename:`重新命名`,format:`格式`,formats:{text:`文字`,number:`數值`,currency:`貨幣`,percent:`百分比`,date:`日期`,checkbox:`核取方塊`,list:`下拉式清單`,file:`附件`},addOption:`新增選項`,newOption:e=>`新增「${e}」`,confirm:`刪除`,cancel:`取消`,hide:`隱藏欄`,insertLeft:`在左側插入欄`,insertRight:`在右側插入欄`,remove:`刪除欄`,removeAsk:(e,t)=>`要刪除「${e}」及其中的 ${t.toLocaleString(`zh-TW`)} 個值嗎?之後可以還原。`,taken:`已有同名的欄。`,empty:`欄需要一個名稱。`,newName:e=>e===1?`欄`:`欄 ${String(e)}`},row:{numbered:e=>`第 ${String(e)} 列`,inFile:e=>`檔案中的第 ${String(e)} 列`,of:(e,t)=>`第 ${String(e)} 列,共 ${String(t)} 列`,hiddenFields:`隱藏的欄`,insertAbove:`在上方插入列`,insertBelow:`在下方插入列`,remove:e=>e===1?`刪除列`:`刪除 ${String(e)} 列`,expand:`展開列`,newRow:`新列`,record:`列`,previous:`上一列`,next:`下一列`,close:`關閉`},cell:{copy:`拷貝`,cut:`剪下`,paste:`貼上`,clear:`清除`,clearContents:`清除內容`,notNumber:`不是數值。請輸入數字,小數用小數點:1234.5`,notDate:`不是日期。請輸入 2026-10-14 或 2026-10-14T09:30`,notEmail:`不是電子郵件地址`,notUrl:`網址中不能有空格`,open:`打開`,left:e=>`有 ${String(e)} 個值不符合所在欄的格式,因此略過。`,pasteHint:`請按 ⌘V 貼上。`},files:{notFound:`找不到`,insert:`插入檔案…`,add:`新增檔案`,adding:e=>`正在新增 ${String(e)} 個檔案…`,tooLarge:(e,t)=>`${e} 超過 ${String(t)} MB,未新增。`,failed:e=>`無法新增 ${e}。`,notHere:`只有附件欄能放檔案。請先將這一欄的格式設為「附件」。`,remove:`從儲存格移除`,of:(e,t)=>`第 ${String(e)} 個,共 ${String(t)} 個`,previous:`上一個檔案`,next:`下一個檔案`,open:`在新分頁中打開`,close:`關閉`},review:{count:(e,t,n,r)=>Au(e,`修改了 ${Qu(t,n,r)}`),keepAll:`全部保留`,undoAll:`全部還原`,keep:`保留`,undo:`還原`,was:`修改前`,added:e=>Au(`由`,e,`新增`),changed:e=>Au(`由`,e,`修改`),away:`你上次查看後有修改`,countAway:(e,t,n)=>`你上次查看後,修改了 ${Qu(e,t,n)}`,empty:`空白`,next:`下一個`,previous:`上一個`,position:(e,t)=>`${String(e)} / ${String(t)}`,conflicts:e=>`有 ${String(e)} 個儲存格你們兩邊都修改了:已保留你的版本。`},date:{placeholder:`2026-10-14、今天、明天…`,today:`今天`,previousMonth:`上個月`,nextMonth:`下個月`,clear:`清除`,addTime:`加上時間`,removeTime:`移除時間`,time:`時間`},empty:{title:`還沒有任何列`,addRow:`新增一列`,paste:`貼上列`,pasteHint:`在 Excel 或 Google 試算表中拷貝幾列,再到這裡按 ⌘V。`,importFile:`匯入檔案`,noMatch:`沒有可顯示的列`,noMatchBody:`篩選條件排除了所有列。`,clearFilter:`清除篩選`}},ja:Mu,ko:Fu,es:gu,fr:yu,de:du,it:Du,pt:Ru,ru:Uu,tr:qu,vi:Yu,th:Gu,hi:wu});function ed(e,t,n){let r=new Set(e.columns),i=new Set(t.columns),a=n.columns.filter(e=>!(r.has(e)&&!i.has(e)));return t.columns.forEach((e,n)=>{if(a.includes(e)||r.has(e))return;let i=a.length;for(let e=n-1;e>=0;e--){let n=t.columns[e],r=n===void 0?-1:a.indexOf(n);if(r>=0){i=r+1;break}}n===0&&(i=0),a.splice(i,0,e)}),a}var td=(e,t)=>{let n=new Map,r=e.rows[t]??[];return e.columns.forEach((e,t)=>n.set(e,r[t]??``)),n};function nd(e,t,n,r){let i=[],a=e.out.length;for(let o of e.columns){let s=t?.get(o),c=n?.get(o),l=r?.get(o),u;c===void 0?u=l??``:l===void 0?u=c:c===s?u=l:l===s||l===c?u=c:(u=c,e.conflicts.push({kind:`cell`,row:a,column:o,mine:c,theirs:l})),i.push(u)}e.out.push(i)}var rd=(e,t)=>{if(!e||!t)return e!==t;for(let[n,r]of e)if(t.has(n)&&t.get(n)!==r)return!0;return!1};function id(e,t){let n=e.columns.indexOf(t);if(n<0)return;let r=e.rows.map(e=>(e[n]??``).trim());if(!r.some(e=>e===``))return new Set(r).size===r.length?r:void 0}function ad(e,t,n,r,i){let a=e=>new Map(e.map((e,t)=>[e,t])),o=a(i.base),s=a(i.mine),c=a(i.theirs),l=[];for(let e of i.theirs)l.push(e);i.mine.forEach((e,t)=>{if(c.has(e)||o.has(e))return;let n=0;for(let e=t-1;e>=0;e--){let t=i.mine[e],r=t===void 0?-1:l.indexOf(t);if(r>=0){n=r+1;break}}l.splice(n,0,e)});for(let i of l){let a=o.has(i)?td(t,o.get(i)??0):void 0,l=s.has(i)?td(n,s.get(i)??0):void 0,u=c.has(i)?td(r,c.get(i)??0):void 0;if(a&&!l){if(!rd(a,u))continue;e.conflicts.push({kind:`rows`,row:e.out.length})}nd(e,a,l,u)}for(let r of i.mine){if(c.has(r)||!o.has(r))continue;let i=td(t,o.get(r)??0),a=td(n,s.get(r)??0);rd(i,a)&&(e.conflicts.push({kind:`rows`,row:e.out.length}),nd(e,i,a,void 0))}}function od(e,t,n,r){let i=[],a=-1,o=-1;for(let[s,c]of[...t,[n,r]])(s-a>1||c-o>1)&&i.push({side:e,bStart:a+1,bEnd:s,sStart:o+1,sEnd:c}),a=s,o=c;return i}function sd(e,t,n,r){let i=t.columns.filter(e=>n.columns.includes(e)&&r.columns.includes(e)),a=e=>{let t=i.map(t=>e.columns.indexOf(t));return e.rows.map(e=>t.map(t=>e[t]??``).join(`\0`))},o=a(t),c=a(n),l=a(r),u=s(o,c),d=s(o,l),f=new Map(u),p=new Map(d),m=[...od(`mine`,u,o.length,c.length),...od(`theirs`,d,o.length,l.length)].sort((e,t)=>e.bStart-t.bStart||e.bEnd-t.bEnd),h=[];for(let e of m){let t=h[h.length-1];if(t){let n=Math.min(...t.map(e=>e.bStart)),r=Math.max(...t.map(e=>e.bEnd));if(e.bStart<r||e.bStart===r&&e.bStart===e.bEnd&&n===r){t.push(e);continue}}h.push([e])}let g=i=>{let a=f.get(i),o=p.get(i);nd(e,td(t,i),a===void 0?void 0:td(n,a),o===void 0?void 0:td(r,o))},_=0;for(let i of h){let a=Math.min(...i.map(e=>e.bStart)),o=Math.max(...i.map(e=>e.bEnd));for(;_<a;_++)g(_);_=o;let s=e=>{let t=i.filter(t=>t.side===e),n=t[0],r=t[t.length-1];if(n&&r)return cd(n.sStart-(n.bStart-a),r.sEnd+(o-r.bEnd))},u=cd(a,o),d=s(`mine`),m=s(`theirs`);if(d===void 0||m===void 0){let i=d??m??[],a=d===void 0?f:p,o=d===void 0?n:r,s=i.length===u.length;i.forEach((i,c)=>{let l=s?u[c]:void 0,f=l===void 0?void 0:a.get(l),p=l===void 0?void 0:td(t,l),m=f===void 0?void 0:td(o,f),h=td(d===void 0?r:n,i);d===void 0?nd(e,p,m,h):nd(e,p,h,m)})}else if(d.length===u.length&&m.length===u.length)u.forEach((i,a)=>{nd(e,td(t,i),td(n,d[a]??0),td(r,m[a]??0))});else if(ld(c,d,l,m))d.forEach((t,i)=>{nd(e,void 0,td(n,t),td(r,m[i]??0))});else{d.length+m.length>0&&e.conflicts.push({kind:`rows`,row:e.out.length});for(let t of d)nd(e,void 0,td(n,t),void 0);for(let t of m)nd(e,void 0,void 0,td(r,t))}}for(;_<o.length;_++)g(_)}var cd=(e,t)=>{let n=[];for(let r=e;r<t;r++)n.push(r);return n},ld=(e,t,n,r)=>t.length===r.length&&t.every((t,i)=>e[t]===n[r[i]??-1]);function ud(e,t,n,r){let i=ed(e,t,n),a={columns:i,conflicts:[],out:[]},o=r===void 0?void 0:(()=>{let i=id(e,r),a=id(t,r),o=id(n,r);return i&&a&&o?{base:i,mine:a,theirs:o}:void 0})();return o?ad(a,e,t,n,o):sd(a,e,t,n),{data:{columns:i,rows:a.out},conflicts:a.conflicts}}var dd=class{kept=new Map;of(e){let t=this.kept.get(e);if(t)return t;let n=jt(e);return this.keep(e,{csv:n.csv,data:n.data})}keep(e,t){for(this.kept.delete(e),this.kept.set(e,t);this.kept.size>3;){let e=this.kept.keys().next().value;if(e===void 0)break;this.kept.delete(e)}return t}save(e,t){let n=this.of(e),r=kl(t);if(Mt(n.data,r))return;let i=eo(n.csv,r,n.data);return this.keep(i.source,{csv:i,data:r}),i.source}incoming(e,t,n,r){let i=this.of(e).data,a=this.of(t).data,o=kl(n),s=Mt(i,o)?{data:a,conflicts:[]}:ud(i,o,a,r),c=Ll(n,s.data);return{table:c.table,changes:c.changes,conflicts:s.conflicts,dirty:!Mt(a,s.data)}}};function fd(e){return jt(e).problems.filter(e=>e.message.includes(`quoted field`)).map(e=>`line ${String(e.line)}: ${e.message}`)}var pd=e=>e===null?void 0:Da(e).spec.key;function md(e,t,n){if(t===e)return n;if(n===e||n===t)return t;let r=Da(e??``).spec,i=Da(t??``).spec,a=n??``;for(let e of[`title`,`key`])i[e]!==r[e]&&(a=ho(a,e,i[e]));let o=new Set([...Object.keys(r.columns),...Object.keys(i.columns)]);for(let e of o){let t=i.columns[e];JSON.stringify(t)!==JSON.stringify(r.columns[e])&&(a=po(a,e,t))}return a===``&&n===null?null:a}var hd=e=>e.cells.join(`\0`);function gd(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return`${String(e.length)}:${(t>>>0).toString(16)}`}function _d(e,t){let n=new Map(e.rows.map((e,t)=>[e.id,t])),r=t=>{let r=n.get(t),i=r===void 0?void 0:e.rows[r];return i?hd(i):void 0},i=[];for(let e of t){let t=i.length;switch(e.kind){case`cell`:{let t=r(e.id);t!==void 0&&i.push({kind:`cell`,row:t,column:e.column,before:e.before,after:e.after});break}case`row-added`:{let t=r(e.id);t!==void 0&&i.push({kind:`row-added`,row:t});break}case`row-removed`:i.push({kind:`row-removed`,cells:[...e.row.cells],columns:[...e.columns],after:e.after===null?null:r(e.after)??null});break;case`column-added`:i.push({kind:`column-added`,name:e.name});break;case`column-removed`:i.push({kind:`column-removed`,name:e.name,at:e.at,values:[...e.values].flatMap(([e,t])=>{let n=r(e);return n===void 0?[]:[[n,t]]})})}let n=i[t];e.away&&n&&(i[t]={...n,away:!0})}return i}function vd(e,t){let n=new Map;for(let t of e.rows){let e=n.get(hd(t));e?e.push(t.id):n.set(hd(t),[t.id])}let r=e=>n.get(e)?.[0],i=[],a=-1;for(let n of t){let t=i.length;switch(n.kind){case`cell`:{let t=r(n.row),a=e.columns.indexOf(n.column),o=e.rows.find(e=>e.id===t);t!==void 0&&a>=0&&o?.cells[a]===n.after&&i.push({...n,id:t,kind:`cell`});break}case`row-added`:{let e=r(n.row);e!==void 0&&i.push({kind:`row-added`,id:e});break}case`row-removed`:i.push({kind:`row-removed`,row:{id:a--,cells:[...n.cells]},columns:[...n.columns],after:n.after===null?null:r(n.after)??null});break;case`column-added`:e.columns.includes(n.name)&&i.push(n);break;case`column-removed`:if(!e.columns.includes(n.name)){let e=new Map;for(let[t,i]of n.values){let n=r(t);n!==void 0&&e.set(n,i)}i.push({kind:`column-removed`,name:n.name,at:n.at,values:e})}}let o=i[t];n.away&&o&&(i[t]={...o,away:!0})}return i}function yd(e,t,n){let r=jt(e);if(r.problems.length>0)return[];let{table:i,changes:a}=Ll(Ol(r.data),n),o=new Map(i.rows.map((e,n)=>[e.id,t.rows[n]?.id??e.id])),s=e=>o.get(e)??e;return a.map(e=>{switch(e.kind){case`cell`:return{...e,id:s(e.id)};case`row-added`:return{...e,id:s(e.id)};case`row-removed`:return{...e,after:e.after===null?null:s(e.after)};case`column-removed`:return{...e,values:new Map([...e.values].map(([e,t])=>[s(e),t]))};default:return e}}).map(e=>({...e,away:!0}))}function bd(e,t){let n=[...e];for(let e of t){if(e.kind===`cell`){let t=n.findIndex(t=>t.kind===`cell`&&t.id===e.id&&t.column===e.column),r=n[t];if(r?.kind===`cell`){n[t]={...e,before:r.before};continue}}e.kind===`row-added`&&n.some(t=>t.kind===`row-added`&&t.id===e.id)||n.push(e)}return n.filter(e=>e.kind!==`cell`||e.before!==e.after)}var xd=e=>`sheet.review:${e}`,Sd=e=>`sheet.seen:${e}`;function Cd(e,t){let n=typeof t==`object`&&t?t:void 0;return{changes:Array.isArray(e)?e:[],...typeof n?.seen==`string`?{seen:n.seen}:{},...typeof n?.pending==`string`?{pending:n.pending}:{}}}function wd(e){return e.length===0?null:[...e]}function Td(e,t){return{...e.length<=1e6?{seen:e}:{},...t===void 0?{}:{pending:t}}}function Ed({parts:e,strings:t,onClear:n}){return e.length===0?null:(0,V.jsxs)(`span`,{className:`sheet-look`,"data-testid":`sheet-look`,title:t.look.note,children:[(0,V.jsx)(`span`,{className:`sheet-look-text`,children:e.join(` · `)}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-look-clear`,"data-testid":`sheet-look-clear`,onClick:n,children:t.look.clear})]})}function Dd({find:e,onFind:t,count:n,at:r,onStep:i,replacing:a,onReplacing:o,onReplace:s,readOnly:c,strings:l}){let u=(0,B.useRef)(null),[d,f]=(0,B.useState)(``),p=e!==void 0;if((0,B.useEffect)(()=>{p&&u.current?.focus()},[p,a]),!p)return null;let m=(e,n)=>{e.stopPropagation(),!e.nativeEvent.isComposing&&(e.key===`Enter`?(e.preventDefault(),n()):e.key===`Escape`&&(e.preventDefault(),t(void 0)))};return(0,V.jsxs)(`span`,{className:`sheet-finding`,"data-testid":`sheet-find-bar`,children:[(0,V.jsxs)(`span`,{className:`sheet-find`,children:[(0,V.jsx)(Qe,{size:14,"aria-hidden":!0}),(0,V.jsx)(`input`,{ref:u,value:e,placeholder:l.findPlaceholder,"aria-label":l.find,"data-testid":`sheet-find-input`,onChange:e=>{t(e.target.value)},onKeyDown:e=>{m(e,()=>{i(e.shiftKey?-1:1)})}}),e!==``&&(0,V.jsx)(`span`,{className:`sheet-find-count`,children:n===0?l.matches(0):`${String(r+1)}/${String(n)}`}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":l.review.previous,title:l.review.previous,disabled:n===0,onClick:()=>{i(-1)},children:(0,V.jsx)(_,{size:13,"aria-hidden":!0})}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":l.review.next,title:l.review.next,disabled:n===0,onClick:()=>{i(1)},children:(0,V.jsx)(h,{size:13,"aria-hidden":!0})}),!c&&(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":l.replace.label,title:l.replace.label,"aria-pressed":a,"data-testid":`sheet-replace-toggle`,onClick:()=>{o(!a)},children:(0,V.jsx)(Xe,{size:13,"aria-hidden":!0})}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":l.row.close,title:l.row.close,onClick:()=>{t(void 0)},children:(0,V.jsx)(C,{size:13,"aria-hidden":!0})})]}),a&&!c&&(0,V.jsxs)(`span`,{className:`sheet-find`,"data-testid":`sheet-replace`,children:[(0,V.jsx)(`input`,{value:d,placeholder:l.replace.with,"aria-label":l.replace.with,"data-testid":`sheet-replace-input`,onChange:e=>{f(e.target.value)},onKeyDown:e=>{m(e,()=>{s(d,!1)})}}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-find-action`,disabled:n===0,"data-testid":`sheet-replace-one`,onClick:()=>{s(d,!1)},children:l.replace.one}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-find-action`,disabled:n===0,"data-testid":`sheet-replace-all`,onClick:()=>{s(d,!0)},children:l.replace.all})]})]})}function Od(e){return typeof navigator<`u`&&/Mac|iPhone|iPad/.test(navigator.userAgent)?`⌘${e}`:`Ctrl+${e}`}var kd=`sheet.csv`,Ad=`sheet.yaml`,jd=`files`,Md=20971520,Nd=28;async function Pd(e,t){try{return(await e[`storage/get`]({key:t})).value}catch{return null}}function Fd(e,t,n){e[`storage/set`]({key:t,value:n}).catch(()=>void 0)}async function Id(e){let t=new Uint8Array(await e.arrayBuffer()),n=``;for(let e=0;e<t.length;e+=32768)n+=String.fromCharCode(...t.subarray(e,e+32768));return btoa(n)}function Ld({bare:e,...t}){let n=d(),r={...t,className:`${e===!0?`sheet-bare `:``}${t.className??``}`},i=r.dir??n?.item.dir;return!n||i===void 0?(0,V.jsx)(Rd,{className:r.className,strings:$u.of(`en`)}):(0,V.jsx)(zd,{...r,dir:i,scope:`${n.project.name}|${i}/${kd}`,language:n.locale,...n.agent?{agent:n.agent.name}:{}},`${n.project.name}|${i}`)}function Rd(e){return(0,V.jsx)(`div`,{className:`sheet-page ${e.className??``}`,"data-testid":`sheet-editor`,"data-state":`loading`,children:(0,V.jsx)(`div`,{className:`sheet-sheet`,children:(0,V.jsx)(`p`,{className:`sheet-message`,children:e.strings.loading})})})}function zd(e){let t=u(),{dir:n,scope:i}=e,a=$u.of(e.language),[o,s]=(0,B.useState)(),[c,l]=(0,B.useState)(),[d,f]=(0,B.useState)(0),[p]=(0,B.useState)(()=>new dd),m=(0,B.useCallback)(()=>{f(e=>e+1)},[]),h=(0,B.useCallback)(e=>{s(t=>t&&{...t,look:e})},[]);if((0,B.useEffect)(()=>{let e={live:!0},a=[];return(async()=>{try{let[o,c,u,d,f]=await Promise.all([r.open(t,`${n}/${kd}`,{report:!1}),r.open(t,`${n}/${Ad}`,{report:!1}),Pd(t,Eo(i)),Pd(t,xd(i)),Pd(t,Sd(i))]);if(a.push(o,c),!e.live){for(let e of a)e.close();return}s({rows:o,spec:c,look:Do(u),review:Cd(d,f)}),l(void 0)}catch(t){e.live&&l(t instanceof Error?t.message:String(t))}})(),()=>{e.live=!1;for(let e of a)e.close()}},[t,n,i]),c!==void 0)return(0,V.jsx)(`div`,{className:`sheet-page ${e.className??``}`,"data-testid":`sheet-editor`,children:(0,V.jsx)(`div`,{className:`sheet-sheet`,children:(0,V.jsx)(`p`,{className:`sheet-message`,role:`alert`,children:c})})});if(!o)return(0,V.jsx)(Rd,{className:e.className,strings:a});let g=o.rows.text,_=e.readOnlyAbove??Md,v=fd(g),y=v.length>0?{text:a.unreadable,lines:v}:g.length>_?{text:a.readOnlyLarge((g.length/1024/1024).toFixed(1)),lines:[]}:void 0;return(0,V.jsx)(Vd,{...e,opened:o,cache:p,strings:a,readOnly:y!==void 0,limit:_,reload:m,onLook:h,...y?{notice:y}:{}},d)}function Bd(e,t){for(let n of[`error`,`saving`,`unsaved`])if(e===n||t===n)return n;return`saved`}function Vd({opened:e,cache:t,dir:n,scope:r,strings:i,readOnly:a,limit:s,reload:c,onLook:l,notice:d,language:p,agent:m,onImport:v,className:x}){let C=u(),{rows:w,spec:T}=e,E=f[o(p)],ee=m??i.agent,[te,ne]=(0,B.useState)(()=>({table:Ol(t.of(w.text).data),texts:{spec:T.version===null?null:T.text}})),D=(0,B.useRef)(te),O=(0,B.useCallback)(e=>{D.current=e,ne(e)},[]),[re,ie]=(0,B.useState)(`saved`),[ae,oe]=(0,B.useState)(),[k,se]=(0,B.useState)(()=>{if(a)return[];let t=e.review,n=w.text,r=vd(te.table,t.changes),i=t.pending!==void 0&&t.pending===gd(n)?n:t.seen;return bd(r,i!==void 0&&i!==n?yd(i,te.table,kl(te.table)):[])}),ce=(0,B.useCallback)(e=>{a||Fd(C,Sd(r),Td(w.text,e))},[C,r,a,w]);(0,B.useEffect)(()=>{ce()},[ce]);let ue=(0,B.useRef)(void 0);(0,B.useEffect)(()=>{if(a)return;let e=wd(_d(te.table,k)),t=JSON.stringify(e);t!==ue.current&&(ue.current=t,Fd(C,xd(r),e))},[C,r,a,te.table,k]);let[de,me]=(0,B.useState)(0);(0,B.useEffect)(()=>{if(ae===void 0)return;let e=window.setTimeout(()=>{oe(void 0)},4e3);return()=>{window.clearTimeout(e)}},[ae]);let _e=(0,B.useRef)([]),ve=(0,B.useRef)([]),ye=(0,B.useRef)(null),j=(0,B.useMemo)(()=>te.texts.spec===null?{columns:{}}:Da(te.texts.spec).spec,[te.texts.spec]),Ce=(0,B.useMemo)(()=>{let e={},t=[];for(let[n,r]of Object.entries(j.columns))r.width!==void 0&&(e[n]=r.width),r.wrap&&t.push(n);return{...Object.keys(e).length?{widths:e}:{},...t.length?{wrap:t}:{}}},[j]),M=e.look,P=M??Ce,De=M!==void 0&&!ko(No(M),No(Ce)),Oe=(0,B.useCallback)(e=>{let t=e!==void 0&&ko(e,Ce)?void 0:e;Fd(C,Eo(r),t??null),l(t)},[C,r,Ce,l]);(0,B.useLayoutEffect)(()=>{w.attach({save:e=>{if(a)return;let n=t.save(e,D.current.table);return n!==void 0&&ce(gd(n)),n},take:(e,n)=>{let r=fd(e).length>0||e.length>s;if(a||r){c();return}let i=D.current,o=t.incoming(n,e,i.table,pd(i.texts.spec));O({...i,table:o.table}),ce(),o.changes.length>0&&se(e=>{let t=new Set(o.changes.flatMap(e=>e.kind===`cell`?[`${String(e.id)}:${e.column}`]:[]));return[...e.filter(e=>!(e.kind===`cell`&&t.has(`${String(e.id)}:${e.column}`))),...o.changes].filter(e=>e.kind!==`cell`||e.before!==e.after)}),o.conflicts.length>0&&me(e=>e+o.conflicts.length),o.dirty&&w.edited()}}),T.attach({save:e=>{let t=D.current.texts.spec;if(!(a||t===null||t===e))return t},take:(e,t)=>{let n=D.current,r=T.version===null?null:e,i=md(t===``?null:t,n.texts.spec,r);O({...n,texts:{spec:i}}),i!==r&&i!==null&&T.edited()}})},[w,T,t,a,s,c,ce,O]),(0,B.useEffect)(()=>{let e=()=>{let e=Bd(w.state,T.state);ie(e);let t=w.error??T.error;e===`error`&&t!==void 0&&oe(t),e===`saved`&&ce(),a||C[`editor/state`]({state:e,...e===`error`&&t!==void 0?{message:t}:{}}).catch(()=>void 0)},t=[w.onState(e),T.onState(e)];return()=>{for(let e of t)e()}},[C,w,T,a,ce]),(0,B.useEffect)(()=>{let e=()=>{w.flush(),T.flush()};return window.addEventListener(`beforeunload`,e),()=>{window.removeEventListener(`beforeunload`,e)}},[w,T]);let ke=(0,B.useCallback)((e,t)=>{t.table!==e.table&&w.edited(),t.texts.spec!==e.texts.spec&&(T.edited(),T.flush())},[w,T]),[je,Me]=(0,B.useState)(()=>new Map),Ne=(0,B.useRef)(new Set),Fe=(0,B.useCallback)(e=>{let t=je.get(e);if(t!==void 0)return t;if(!Ne.current.has(e)){Ne.current.add(e);let t=t=>{Me(n=>new Map(n).set(e,t))};C[`files/url`]({path:e}).then(e=>{t(e.url)},()=>{t(`about:invalid`)})}return null},[C,je]),[Ie,Le]=(0,B.useState)(),[ze,Ve]=(0,B.useState)(),F=(0,B.useCallback)((e,t={})=>{if(a||Pl(e))return;let n=D.current,r=Ml(n,e);O(r),t.undoable!==!1&&(_e.current.push({edit:e,selection:Ie}),_e.current.length>500&&_e.current.shift(),ve.current=[]),se(t=>t.filter(t=>!zl(e,t))),ke(n,r)},[a,ke,Ie,O]),He=(0,B.useCallback)(()=>{let e=_e.current.pop();if(!e)return;let t=Nl(e.edit),n=D.current,r=Ml(n,t);O(r),ve.current.push(e),e.selection&&Le(e.selection),ke(n,r)},[ke,O]),Ue=(0,B.useCallback)(()=>{let e=ve.current.pop();if(!e)return;let t=D.current,n=Ml(t,e.edit);O(n),_e.current.push(e),ke(t,n)},[ke,O]),{table:I}=te,We=(0,B.useMemo)(()=>kl(I),[I]),L=I.columns,Ge=To(L,j),R=(0,B.useMemo)(()=>{let e=wo(We,P),t=e.length>0?e:L.slice(0,1);return Ge===void 0||!t.includes(Ge)?t:[Ge,...t.filter(e=>e!==Ge)]},[We,P,L,Ge]),Je=Ge!==void 0&&R[0]===Ge,Ye=(0,B.useMemo)(()=>So(We,j,P),[We,j,P]),{items:Xe,rowItems:Qe,shownIds:z}=(0,B.useMemo)(()=>{let e=[],t=[];for(let n of Ye){let r=I.rows[n];r&&(e.push({row:r,index:n,r:t.length}),t.push(r.id))}return{items:e,rowItems:e.map((e,t)=>t),shownIds:t}},[I.rows,Ye]),$e=(0,B.useMemo)(()=>({rows:z,columns:R}),[z,R]),H=(0,B.useMemo)(()=>{if(!Ie||z.length===0||R.length===0)return;let e=e=>{if(Ie.ids!==z){let t=Ie.ids[e.r],n=t===void 0?-1:z.indexOf(t);if(n>=0)return{r:n,c:Math.min(e.c,R.length-1)}}return Ul(e,z.length,R.length)};return{anchor:e(Ie.selection.anchor),focus:e(Ie.selection.focus)}},[Ie,z,R.length]),U=(0,B.useCallback)(e=>{Le(e===void 0?void 0:{selection:e,ids:z})},[z]),tt=(0,B.useRef)(z);(0,B.useEffect)(()=>{tt.current=z},[z]);let nt=(0,B.useMemo)(()=>new Map(I.rows.map((e,t)=>[e.id,t])),[I.rows]),rt=(0,B.useMemo)(()=>P.widths??{},[P.widths]),it=(0,B.useMemo)(()=>su(j,I),[j,I]),at=(0,B.useMemo)(()=>Xo(j,R,34),[j,R]),ot=L.join(`\0`),st=(0,B.useMemo)(()=>{let e=document.createElement(`canvas`).getContext(`2d`),t=getComputedStyle(document.documentElement).getPropertyValue(`--allyhub-font-ui`).trim();return e&&(e.font=`13px ${t||`system-ui`}`),$o(We,j,e?t=>e.measureText(t).width:e=>e.length*7,E)},[ot,j,E]),ct=(0,B.useMemo)(()=>new Set(P.wrap??[]),[P.wrap]),[lt,ut]=(0,B.useState)(),[dt,ft]=(0,B.useState)(!1),[pt,mt]=(0,B.useState)(0),ht=(0,B.useCallback)(e=>{let t=e?.trim().toLowerCase();if(!t)return[];let n=[],r=R.map(e=>L.indexOf(e));for(let e of z){let i=I.rows[nt.get(e)??-1];i&&R.forEach((a,o)=>{(i.cells[r[o]??-1]??``).toLowerCase().includes(t)&&n.push(`${String(e)}:${a}`)})}return n},[R,L,z,I.rows,nt]),gt=(0,B.useMemo)(()=>ht(lt),[ht,lt]),_t=(0,B.useMemo)(()=>new Set(gt),[gt]),vt=(0,B.useCallback)((e,t)=>{let n=e[t];if(n===void 0)return;let r=n.indexOf(`:`),i=Number(n.slice(0,r)),a=z.indexOf(i),o=R.indexOf(n.slice(r+1));if(a<0||o<0)return;let s={r:a,c:o};U(Hl(s)),ye.current?.reveal(s)},[z,R,U]),yt=(0,B.useCallback)(e=>{ut(e),mt(0),vt(ht(e),0)},[vt,ht]),bt=(0,B.useCallback)(e=>{if(gt.length===0)return;let t=(pt+e+gt.length)%gt.length;mt(t),vt(gt,t)},[gt,pt,vt]),{agentCells:xt,agentRows:St,away:Ct}=(0,B.useMemo)(()=>{let e=new Map,t=new Set,n=new Set;for(let r of k)if(r.kind===`cell`){let t=`${String(r.id)}:${r.column}`;e.set(t,r.before),r.away&&n.add(t)}else r.kind===`row-added`&&(t.add(r.id),r.away&&n.add(`row:${String(r.id)}`));return{agentCells:e,agentRows:t,away:n}},[k]),wt=(0,B.useCallback)(e=>{let t=e.map(e=>Rl(e,D.current.table)).filter(e=>e!==void 0);t.length>0&&F({kind:`batch`,edits:t}),se(t=>t.filter(t=>!e.includes(t)))},[F]),Tt=(0,B.useCallback)(e=>{let t=z[e.r],n=R[e.c],r=t===void 0?void 0:I.rows[nt.get(t)??-1];return r&&n!==void 0?{row:r,column:n}:void 0},[z,R,I.rows,nt]),Dt=(0,B.useCallback)((e,t,n)=>{let r=e.cells[D.current.table.columns.indexOf(t)]??``;F({kind:`cells`,changes:[{id:e.id,column:t,before:r,after:n}]})},[F]),Ot=(0,B.useCallback)(e=>{let t=D.current.texts.spec;return{kind:`spec`,before:t,after:e(t??void 0)}},[]),kt=(0,B.useCallback)((e,t)=>{let n=W(j,e);if(n.options?.some(e=>e.name===t))return;let r={...n,options:[...n.options??[],{name:t}]};F(Ot(t=>po(t,e,r)))},[j,F,Ot]),At=(0,B.useCallback)((e,t,n=1)=>{let r=D.current.table.rows,i;if(t===`end`||e===void 0)i=r[r.length-1]?.id??null;else{let n=z[e.r],a=n===void 0?r.length-1:nt.get(n)??r.length-1;i=t===`above`?r[a-1]?.id??null:r[a]?.id??null}let a=Array.from({length:n},()=>({id:Dl(),cells:L.map(()=>``)})),o=i;return F({kind:`insert`,rows:a.map(e=>{let t={row:e,after:o};return o=e.id,t})}),a.map(e=>e.id)},[z,nt,L,F]),jt=(0,B.useCallback)(e=>new Set(z.slice(e.r0,e.r1+1)),[z]),Mt=(0,B.useCallback)(()=>{for(let e=1;;e++){let t=i.column.newName(e);if(!L.includes(t))return t}},[L,i]),[Nt,Pt]=(0,B.useState)(),[Ft,It]=(0,B.useState)(),Lt=(0,B.useCallback)(e=>{let t=Mt();if(F({kind:`insert-column`,at:e,name:t,values:new Map}),P.columns){let n=Math.min(e,R.length),r=[...R];r.splice(n,0,t),Oe({...P,columns:r})}Pt(t)},[Mt,F,P,R,Oe]),Rt=(0,B.useCallback)((e,t)=>{let n=D.current.texts,r=[{kind:`rename-column`,from:e,to:t}],i=mo(n.spec??void 0,e,t);i!==(n.spec??void 0)&&r.push({kind:`spec`,before:n.spec,after:i||null}),F({kind:`batch`,edits:r}),M&&Oe(jo(M,e,t))},[F,M,Oe]),zt=(0,B.useCallback)((e,t)=>{let n=D.current.table.columns.indexOf(e),r=D.current.table.rows.map(e=>e.cells[n]??``),i=Ko(W(j,e),t,r);F(Ot(t=>po(t,e,i)))},[j,F,Ot]),[Bt,Vt]=(0,B.useState)(),G=H===void 0?void 0:z[H.focus.r],K=Bt===void 0?void 0:G??Bt,q=K===void 0?void 0:I.rows[nt.get(K)??-1],Ht=!a,J=(0,B.useCallback)(async e=>{let{path:t}=await C[`files/upload`]({dir:`${n}/${jd}`,name:e.name,data:await Id(e)});return t.startsWith(`${n}/`)?t.slice(n.length+1):t},[C,n]),Y=(0,B.useCallback)(async(e,t)=>{if(a||t.length===0)return;let n=Tt(e);if(!n)return;let r=W(j,n.column);if(r.type!==`file`){oe(i.files.notHere);return}U(Hl(e)),oe(i.files.adding(t.length));let o=[],s=[];for(let e of t)if(e.size>Nd*1024*1024)s.push(i.files.tooLarge(e.name,Nd));else try{o.push(await J(e))}catch{s.push(i.files.failed(e.name))}if(oe(s.length>0?s.join(` `):void 0),o.length===0)return;let c=D.current.table,l=c.rows.find(e=>e.id===n.row.id);if(!l)return;let u=l.cells[c.columns.indexOf(n.column)]??``;Dt(l,n.column,La([...Ia(u,r.separator),...o],r.separator))},[J,a,Tt,j,i,U,Dt]),Ut=(0,B.useRef)(void 0),Wt=(0,B.useRef)(null),Gt=(0,B.useCallback)(e=>{Ut.current=e,Wt.current?.click()},[]),[Kt,qt]=(0,B.useState)(),Jt=e=>{let t=e?.closest(`[data-cell]`);if(t)return{r:Number(t.dataset.r),c:Number(t.dataset.c)}},Yt=e=>e.dataTransfer.types.includes(`Files`),Xt=e=>{if(!Ht||!Yt(e))return;e.preventDefault();let t=Jt(e.target);e.dataTransfer.dropEffect=t?`copy`:`none`,(t?.r!==Kt?.r||t?.c!==Kt?.c)&&qt(t)},Zt=e=>{e.currentTarget.contains(e.relatedTarget)||qt(void 0)},Qt=e=>{if(!Ht||!Yt(e))return;e.preventDefault(),qt(void 0);let t=Jt(e.target);t&&Y(t,[...e.dataTransfer.files])},[$t,en]=(0,B.useState)(),tn=L.indexOf(Ge??``),nn=(0,B.useCallback)((e,t)=>{let n=Tt(e);if(!n)return;let r=W(j,n.column);if(r.type!==`file`)return;let a=L.indexOf(n.column),o=Zo(r,z.flatMap(e=>{let t=I.rows[nt.get(e)??-1];return t?[{id:e,value:t.cells[a]??``,title:(t.cells[tn]?.trim()??``)||i.row.numbered((nt.get(e)??0)+1)}]:[]})),s=o.findIndex(e=>e.row===n.row.id&&e.at===t);s<0||(U(Hl(e)),en({column:n.column,files:o,at:s}))},[Tt,j,L,z,I.rows,nt,tn,i,U]),rn=(0,B.useRef)(null),an=(0,B.useCallback)(()=>{rn.current?.focus({preventScroll:!0})},[]),on=e=>{let t=e;return!t||t===rn.current||!t.closest(`input, textarea, select, [role=dialog], [role=menu]`)};(0,B.useEffect)(()=>{let e=rn.current,t=e?.parentElement;if(!e||!t||!H)return;let n=t.querySelector(`[data-cell][data-r="${String(H.focus.r)}"][data-c="${String(H.focus.c)}"]`);if(!n)return;let r=n.getBoundingClientRect(),i=t.getBoundingClientRect();e.style.left=`${String(r.left-i.left+8)}px`,e.style.top=`${String(r.top-i.top+8)}px`},[H]);let X=z.length,sn=R.length,cn=(0,B.useCallback)(e=>{ye.current?.reveal(e)},[]),ln=(0,B.useCallback)(e=>{U(e),cn(e.focus)},[cn,U]),un=(0,B.useCallback)((e,t)=>{let n=ze?.cell;if(Ve(void 0),!n)return;let r=Tt(n);r&&(r.row.cells[L.indexOf(r.column)]??``)!==e&&Dt(r.row,r.column,e),H&&t!==`click`&&ln(Gl(H,t===`tab`?`next`:t===`shift-tab`?`previous`:t===`shift-enter`?`up`:`down`,X,sn)),an()},[ze,Tt,L,Dt,H,ln,X,sn,an]),Z=(0,B.useCallback)(e=>{let t=Tt(e);if(!t)return;let n=t.row.cells[L.indexOf(t.column)]??``;Dt(t.row,t.column,n.trim().toLowerCase()===`true`?`false`:`true`)},[Tt,L,Dt]),dn=(0,B.useCallback)(e=>{if(!H)return;let t=Bl(H),n=Kl(I,$e,t);return e&&!a&&F(ql(I,$e,t)),n},[H,I,$e,a,F]),fn=(0,B.useCallback)(e=>{if(a)return;let t=I.rows.length===0&&!H;if(!H&&!t)return;let n=H?Bl(H):{r0:0,r1:0,c0:0,c1:0},r=[],o=I,s=$e;if(t){let t=Math.max(0,...Et(e.replace(/\r?\n$/,``)).map(e=>e.length)),n=[];for(let e=1;I.columns.length+n.length<t;e++){let t=i.column.newName(e);I.columns.includes(t)||n.push(t)}n.forEach((e,t)=>{r.push({kind:`insert-column`,at:I.columns.length+t,name:e,values:new Map})}),o={...I,columns:[...I.columns,...n]},s={rows:[],columns:[...$e.columns,...n]}}let c=Yl(o,j,s,n,e);if(c.options.size>0){let e=D.current.texts.spec??void 0;for(let[t,n]of c.options){let r=W(Da(e??``).spec,t);e=po(e,t,{...r,options:[...r.options??[],...n.map(e=>({name:e}))]})}r.push({kind:`spec`,before:D.current.texts.spec,after:e??null})}r.push(c.edit),F({kind:`batch`,edits:r}),oe(c.skipped>0?i.cell.left(c.skipped):void 0);let l=e.replace(/\r?\n$/,``).split(/\r?\n/);if(l.length!==1||l[0]?.includes(` `)){let e=l.length,t=Math.max(...l.map(e=>e.split(` `).length));U({anchor:{r:n.r0,c:n.c0},focus:{r:n.r0+e-1,c:Math.min(s.columns.length-1,n.c0+t-1)}})}},[H,a,I,j,$e,F,i,U]),pn=e=>{if(ze||e.nativeEvent.isComposing||!on(e.target))return;let t=e.metaKey||e.ctrlKey;if(t&&e.key.toLowerCase()===`z`){e.preventDefault(),e.shiftKey?Ue():He();return}if(t&&e.key.toLowerCase()===`y`){e.preventDefault(),Ue();return}if(t&&e.key.toLowerCase()===`f`){e.preventDefault(),yt(lt??``);return}if(e.ctrlKey&&!e.metaKey&&e.key.toLowerCase()===`h`){e.preventDefault(),yt(lt??``),ft(!0);return}if(X===0||sn===0)return;if(t&&e.key.toLowerCase()===`a`){e.preventDefault(),U({anchor:{r:0,c:0},focus:{r:X-1,c:sn-1}});return}let n=H??Hl({r:0,c:0});if(e.key===` `&&e.shiftKey!==e.ctrlKey&&!e.metaKey){e.preventDefault();let t=Bl(n);U(e.shiftKey?{anchor:{r:t.r0,c:0},focus:{r:t.r1,c:sn-1}}:{anchor:{r:0,c:t.c0},focus:{r:X-1,c:t.c1}});return}let r={ArrowUp:`up`,ArrowDown:`down`,ArrowLeft:`left`,ArrowRight:`right`,Home:`home`,End:`end`,PageUp:`page-up`,PageDown:`page-down`}[e.key];if(r){e.preventDefault(),ln(Wl(n,r,{extend:e.shiftKey,jump:t,rows:X,cols:sn,page:ye.current?.page()??10}));return}if(e.key===`Tab`){e.preventDefault(),ln(Gl(n,e.shiftKey?`previous`:`next`,X,sn));return}if(e.key===`Escape`){let e=Bl(n);lt===void 0?e.r0!==e.r1||e.c0!==e.c1?U(Hl(n.focus)):Bt!==void 0&&Vt(void 0):yt(void 0);return}if(e.key===` `&&!t&&!e.shiftKey){let t=Tt(n.focus),r=t?W(j,t.column):void 0;if(t&&r?.type===`file`&&Jo(r,t.row.cells[L.indexOf(t.column)]??``).length>0){e.preventDefault(),nn(n.focus,0);return}}if(t&&e.key===`Enter`){e.preventDefault();let t=z[n.focus.r];t!==void 0&&Vt(t);return}if(a)return;let i=R[n.focus.c],o=i===void 0?`text`:W(j,i).type;if(e.key===`Enter`||e.key===`F2`){e.preventDefault();let t=Bl(n);if(e.key===`Enter`&&(t.r0!==t.r1||t.c0!==t.c1)){ln(Gl(n,e.shiftKey?`up`:`down`,X,sn));return}o===`checkbox`?Z(n.focus):Ve({cell:n.focus})}else if(e.key===`Backspace`||e.key===`Delete`)e.preventDefault(),F(ql(I,$e,Bl(n)));else if(t&&e.key.toLowerCase()===`d`)e.preventDefault(),F(Xl(I,$e,Bl(n)));else if(e.key===` `&&o===`checkbox`){e.preventDefault();let t=Bl(n);for(let e=t.r0;e<=t.r1;e++)Z({r:e,c:n.focus.c})}},mn=e=>{if(a||e===``||X===0||sn===0)return;let t=H??Hl({r:0,c:0}),n=R[t.focus.c];n!==void 0&&W(j,n).type!==`checkbox`&&(U(Hl(t.focus)),Ve({cell:t.focus,initial:e}))},hn=e=>{if(ze||!on(e.target))return;let t=dn(!1);t!==void 0&&(e.preventDefault(),e.clipboardData.setData(`text/plain`,t))},gn=e=>{if(ze||!on(e.target))return;let t=dn(!0);t!==void 0&&(e.preventDefault(),e.clipboardData.setData(`text/plain`,t))},_n=e=>{if(ze||!on(e.target))return;e.preventDefault();let t=[...e.clipboardData.files];t.length>0&&Ht&&H?Y(H.focus,t):fn(e.clipboardData.getData(`text/plain`))},vn=(0,B.useMemo)(()=>{let e=[];for(let t of k){let n=t.kind===`cell`||t.kind===`row-added`?t.id:void 0,r=n===void 0?-1:z.indexOf(n);if(r<0)continue;let i=t.kind===`cell`?Math.max(0,R.indexOf(t.column)):0;e.push({change:t,r,c:i})}return e.sort((e,t)=>e.r-t.r||e.c-t.c)},[k,z,R]),[yn,bn]=(0,B.useState)(-1),xn=(0,B.useCallback)(e=>{if(vn.length===0)return;let t=(yn+e+vn.length)%vn.length;bn(t);let n=vn[t];if(!n)return;let r={r:n.r,c:n.c};U(Hl(r)),ye.current?.reveal(r)},[vn,yn,U]),[Sn,Cn]=(0,B.useState)(),wn=(0,B.useRef)(void 0),Tn=(0,B.useRef)(!1),En=(0,B.useCallback)(()=>{window.clearTimeout(wn.current),wn.current=window.setTimeout(()=>{Tn.current||Cn(void 0)},160)},[]),Dn=e=>{if(ze||e.buttons!==0)return;let t=e.target;if(t.closest(`.sheet-review-card`))return;let n=t.closest(`[data-cell][data-agent], .sheet-gutter[data-agent]`);if(!n){En();return}let r;if(n.classList.contains(`sheet-gutter`)){let e=Number(n.closest(`[data-row-id]`)?.dataset.rowId);r=k.find(t=>t.kind===`row-added`&&t.id===e)}else{let e=Tt({r:Number(n.dataset.r),c:Number(n.dataset.c)});r=e?k.find(t=>t.kind===`cell`&&t.id===e.row.id&&t.column===e.column):void 0}if(!r){En();return}if(Sn?.change===r){window.clearTimeout(wn.current);return}let i=e.currentTarget.getBoundingClientRect(),a=n.getBoundingClientRect(),o=r;window.clearTimeout(wn.current),wn.current=window.setTimeout(()=>{Cn({change:o,left:Math.max(8,Math.min(a.left-i.left,i.width-268)),top:a.bottom-i.top+4})},Sn?0:280)};(0,B.useEffect)(()=>()=>{window.clearTimeout(wn.current)},[]);let On=Sn&&k.includes(Sn.change)?Sn:void 0,[kn,An]=(0,B.useState)(),jn=(0,B.useCallback)((e,t)=>{e.preventDefault(),H&&Bl(H).r0<=t.r&&t.r<=Bl(H).r1&&Bl(H).c0<=t.c&&t.c<=Bl(H).c1||U(Hl(t)),xs(),An({x:e.clientX,y:e.clientY,cell:t})},[H,U]),Mn=(0,B.useMemo)(()=>({select:e=>{U(e)},edit:(e,t)=>{U(Hl(e)),Ve({cell:e,...t===void 0?{}:{initial:t}})},commit:un,cancel:()=>{Ve(void 0),an()},toggle:Z,addOption:kt,resize:(e,t)=>{let n=W(j,e),r=D.current.texts,i=po(r.spec??void 0,e,{...n,width:t});F({kind:`spec`,before:r.spec,after:i},{undoable:!1}),M&&Oe({...M,widths:{...M.widths??{},[e]:t}})},moveColumn:(e,t)=>{if(Je&&e===Ge)return;let n=Je?Math.max(1,t):t;if(!M?.columns){F({kind:`move-column`,name:e,from:L.indexOf(e),to:L.indexOf(R[n]??e)});return}let r=R.filter(t=>t!==e);r.splice(n,0,e),Oe({...P,columns:r})},moveRows:(e,t)=>{let n=D.current.table.rows.map(e=>e.id),r=new Set(e),i=n.filter(e=>!r.has(e)),a=t===null?i.length:i.indexOf(t),o=[...i];o.splice(a<0?i.length:a,0,...n.filter(e=>r.has(e))),F({kind:`order`,before:n,after:o})},addRow:()=>{let[e]=At(void 0,`end`);window.requestAnimationFrame(()=>{let t=e===void 0?-1:tt.current.indexOf(e);t>=0&&(U(Hl({r:t,c:0})),Ve({cell:{r:t,c:0}}),ye.current?.reveal({r:t,c:0}))})},addColumn:()=>{Lt(L.length)},contextMenu:jn,rename:(e,t)=>{Pt(void 0),t!==void 0&&!L.includes(t)&&Rt(e,t),an()},expand:e=>{let t=z.indexOf(e);t>=0&&U(Hl({r:t,c:H?.focus.c??0})),Vt(e)},openFile:nn,fill:(e,t)=>{F(Xl(I,$e,{...e,r1:t},e.r1-e.r0+1)),U({anchor:{r:e.r0,c:e.c0},focus:{r:t,c:e.c1}})},columnActions:e=>({rename:()=>{Pt(e)},format:t=>{zt(e,t)},hide:()=>{Oe({...P,columns:R.filter(t=>t!==e)})},insert:t=>{let n=L.indexOf(e)+ +(t===`right`);Lt(n)},remove:()=>{let t=L.indexOf(e),n=new Map(D.current.table.rows.map(e=>[e.id,e.cells[t]??``])),r=[...n.values()].filter(e=>e!==``).length;It({title:i.column.removeAsk(e,r),run:()=>{let r=D.current.texts,i=r.spec??void 0;j.columns[e]!==void 0&&(i=po(i,e,void 0)),j.key===e&&(i=ho(i,`key`,void 0)),j.primary===e&&(i=ho(i,`primary`,void 0)),F({kind:`batch`,edits:[{kind:`remove-column`,at:t,name:e,values:n},...i===(r.spec??void 0)?[]:[{kind:`spec`,before:r.spec,after:i===void 0||i===``?null:i}]]})}})}}),focusGrid:()=>{an()}}),[un,Z,kt,j,F,M,Oe,L,R,P,At,Lt,jn,I,$e,i,an,U,Je,Ge,Rt,zt,z,H,nn]),Nn=a?void 0:I.rows.length===0?(0,V.jsxs)(`div`,{className:`sheet-empty`,"data-testid":`sheet-empty`,children:[(0,V.jsx)(`p`,{className:`sheet-empty-title`,children:i.empty.title}),(0,V.jsxs)(`div`,{className:`sheet-empty-actions`,children:[(0,V.jsxs)(he,{size:`sm`,"data-testid":`sheet-empty-add`,onClick:Mn.addRow,children:[(0,V.jsx)(Se,{"aria-hidden":!0}),i.empty.addRow]}),(0,V.jsxs)(he,{variant:`outline`,size:`sm`,onClick:()=>{an(),oe(i.empty.pasteHint)},children:[(0,V.jsx)(Re,{"aria-hidden":!0}),i.empty.paste]}),v&&(0,V.jsxs)(`label`,{className:`sheet-empty-file`,children:[(0,V.jsx)(et,{"aria-hidden":!0,size:14}),i.empty.importFile,(0,V.jsx)(`input`,{type:`file`,accept:`.csv,.tsv,.xlsx`,className:`sheet-empty-input`,onChange:e=>{let t=e.target.files?.[0];e.target.value=``,t&&v(t)}})]})]})]}):Ye.length===0&&P.filter?(0,V.jsxs)(`div`,{className:`sheet-empty`,"data-quiet":``,"data-testid":`sheet-no-match`,children:[(0,V.jsx)(`p`,{className:`sheet-empty-title`,children:i.empty.noMatch}),(0,V.jsx)(`p`,{className:`sheet-empty-body`,children:i.empty.noMatchBody}),(0,V.jsx)(`div`,{className:`sheet-empty-actions`,children:(0,V.jsx)(he,{variant:`outline`,size:`sm`,onClick:()=>{Oe(Po(P))},children:i.empty.clearFilter})})]}):void 0,Pn=(0,B.useMemo)(()=>{if(!De)return[];let e=[],t=M.sort?.[0];t&&JSON.stringify(M.sort)!==JSON.stringify(Ce.sort??[])&&e.push(i.look.sorted(t.column,t.desc===!0));let n=[...Uo(No(M))].filter(e=>{let t=W(j,e);return JSON.stringify([...Vo(M,e,t)??[]])!==JSON.stringify([...Vo(Ce,e,t)??[]])});n.length>0&&e.push(i.look.filtered(n));let r=wo(We,Ce).length-wo(We,M).length;return r>0&&e.push(i.look.hidden(r)),e},[De,M,Ce,j,We,i]),Fn=(0,B.useCallback)((e,t)=>{let n=W(j,e),r=P.sort?.[0];return(0,V.jsx)(Us,{name:e,column:n,ticked:Vo(P,e,n),sort:r?.column===e?r.desc?`desc`:`asc`:void 0,strings:i,locale:E,trigger:t,values:()=>{let t=No(Ho(P,e,n,void 0)),r=L.indexOf(e),i=So(We,j,t).map(e=>I.rows[e]?.cells[r]??``);return Ro(e,n,i,E)},onSort:t=>{Oe({...P,sort:[{column:e,...t?{desc:!0}:{}}]})},onTicked:t=>{Oe(Ho(P,e,n,t)),an()}})},[j,P,i,E,L,We,I.rows,Oe,an]),In=(0,B.useMemo)(()=>Uo(No(P)),[P]),Ln=P.sort?.[0],Rn=(0,B.useMemo)(()=>Ln===void 0?void 0:{column:Ln.column,desc:Ln.desc===!0},[Ln]),zn=(0,B.useCallback)((e,t)=>{let n=lt?.trim();if(!n||a)return;let r=new RegExp(n.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`),`gi`),o=t?gt:gt.slice(pt,pt+1),s=D.current.table,c=new Map(s.rows.map(e=>[e.id,e])),l=o.flatMap(t=>{let n=t.indexOf(`:`),i=Number(t.slice(0,n)),a=t.slice(n+1),o=c.get(i)?.cells[s.columns.indexOf(a)]??``,l=o.replace(r,()=>e);return l===o?[]:[{id:i,column:a,before:o,after:l}]});if(l.length===0||(F({kind:`cells`,changes:l}),oe(t?i.replace.done(l.length):void 0),t))return;let u=pt+1>=gt.length,d=u?gt[0]:gt[pt+1];if(d===void 0||d===o[0])return;let f=l[0]?.after.toLowerCase().includes(n.toLowerCase());mt(u?0:f===!0?pt+1:pt),vt([d],0)},[lt,a,gt,pt,F,i,vt]),Bn=(0,B.useMemo)(()=>{if(!H)return;let e=Bl(H);if(e.r0!==e.r1||e.c0!==e.c1)return cu(I,j,$e,e,E)},[H,I,j,$e,E]),Vn=H?Bl(H):void 0,Hn=kn?Tt(kn.cell):void 0,Un=Hn?k.find(e=>e.kind===`cell`&&e.id===Hn.row.id&&e.column===Hn.column):void 0,Wn={cells:k.filter(e=>e.kind===`cell`).length,rows:k.filter(e=>e.kind===`row-added`||e.kind===`row-removed`).length,columns:k.filter(e=>e.kind===`column-added`||e.kind===`column-removed`).length};return(0,V.jsxs)(`div`,{className:`sheet-page ${x??``}`,"data-testid":`sheet-editor`,"data-state":re,lang:E,children:[(0,V.jsxs)(`div`,{className:`sheet-sheet`,children:[d&&(0,V.jsxs)(`div`,{className:`sheet-notice`,role:`note`,"data-testid":`sheet-notice`,children:[(0,V.jsx)(`p`,{children:d.text}),d.lines.map(e=>(0,V.jsx)(`p`,{className:`sheet-notice-line`,children:e},e))]}),(0,V.jsxs)(`div`,{className:`sheet-main`,children:[(0,V.jsxs)(`div`,{className:`sheet-grid-wrap`,onPointerOver:Dn,onPointerLeave:En,onKeyDown:pn,onCopy:hn,onCut:gn,onPaste:_n,onDragOver:Xt,onDragLeave:Zt,onDrop:Qt,children:[Ht&&(0,V.jsx)(`input`,{ref:Wt,type:`file`,multiple:!0,hidden:!0,"data-testid":`sheet-file-input`,onChange:e=>{let t=[...e.target.files??[]];e.target.value=``;let n=Ut.current;n&&Y(n,t)}}),(0,V.jsx)(`textarea`,{ref:rn,className:`sheet-sink`,"aria-label":i.cell.open,tabIndex:-1,"data-testid":`sheet-sink`,onInput:e=>{if(e.nativeEvent.isComposing)return;let t=e.currentTarget.value;e.currentTarget.value=``,mn(t)},onCompositionEnd:e=>{let t=e.data;e.currentTarget.value=``,mn(t)}}),(0,V.jsx)(nu,{ref:ye,spec:it,rowHeight:at,...Kt?{dropping:Kt}:{},allColumns:L,columns:R,widths:rt,fit:st,freeze:P.freeze??+!!Je,wrap:ct,items:Xe,rowItems:Qe,selection:H,editing:ze,readOnly:a,found:_t,current:gt[pt],agentCells:xt,agentRows:St,away:Ct,headerTool:Fn,filtered:In,...Rn?{sortedBy:Rn}:{},...Nt===void 0?{}:{renaming:Nt},...Nn?{empty:Nn}:{},sorted:(P.sort?.length??0)>0,...j.key===void 0?{}:{keyColumn:j.key},strings:i,locale:E,fileUrl:Fe,dir:n,on:Mn}),lt!==void 0&&(0,V.jsx)(`div`,{className:`sheet-find-float`,children:(0,V.jsx)(Dd,{find:lt,onFind:yt,count:gt.length,at:pt,onStep:bt,replacing:dt,onReplacing:ft,onReplace:zn,readOnly:a,strings:i})}),On&&(0,V.jsx)(lu,{change:On.change,at:On,agent:m??i.agentInline,spec:it,locale:E,strings:i,onEnter:()=>{Tn.current=!0,window.clearTimeout(wn.current)},onLeave:()=>{Tn.current=!1,En()},onKeep:()=>{se(e=>e.filter(e=>e!==On.change)),Cn(void 0)},onUndo:()=>{wt([On.change]),Cn(void 0)}}),ae!==void 0&&(0,V.jsx)(`p`,{className:`sheet-toast`,role:`status`,children:ae}),(Wn.cells+Wn.rows+Wn.columns>0||de>0)&&(0,V.jsxs)(`div`,{className:`sheet-review-bar`,"data-testid":`sheet-review-bar`,"data-away":k.length>0&&k.every(e=>e.away)?``:void 0,children:[(0,V.jsxs)(`span`,{className:`sheet-review-text`,children:[Wn.cells+Wn.rows+Wn.columns>0&&(k.every(e=>e.away)?i.review.countAway(Wn.cells,Wn.rows,Wn.columns):i.review.count(ee,Wn.cells,Wn.rows,Wn.columns)),de>0&&(0,V.jsxs)(`span`,{className:`sheet-review-conflict`,children:[` `,i.review.conflicts(de)]})]}),vn.length>0&&(0,V.jsxs)(`span`,{className:`sheet-review-step`,children:[(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":i.review.previous,title:i.review.previous,"data-testid":`sheet-review-previous`,onClick:()=>{xn(-1)},children:(0,V.jsx)(_,{size:14,"aria-hidden":!0})}),(0,V.jsx)(`span`,{className:`sheet-review-position`,children:yn>=0&&yn<vn.length?i.review.position(yn+1,vn.length):String(vn.length)}),(0,V.jsx)(`button`,{type:`button`,className:`sheet-icon-button`,"aria-label":i.review.next,title:i.review.next,"data-testid":`sheet-review-next`,onClick:()=>{xn(1)},children:(0,V.jsx)(h,{size:14,"aria-hidden":!0})})]}),k.length>0&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(`button`,{type:`button`,onClick:()=>{wt(k)},children:[(0,V.jsx)(S,{size:13,"aria-hidden":!0}),i.review.undoAll]}),(0,V.jsxs)(`button`,{type:`button`,onClick:()=>{se([]),me(0)},children:[(0,V.jsx)(g,{size:13,"aria-hidden":!0}),i.review.keepAll]})]}),k.length===0&&de>0&&(0,V.jsx)(`button`,{type:`button`,onClick:()=>{me(0)},children:i.review.keep})]})]}),q&&(0,V.jsx)(au,{row:q,columns:R,allColumns:L,spec:j,number:z.includes(q.id)?z.indexOf(q.id)+1:(nt.get(q.id)??0)+1,total:z.includes(q.id)?z.length:I.rows.length,title:q.cells[L.indexOf(To(L,j)??``)]??``,readOnly:a,strings:i,locale:E,fileUrl:Fe,dir:n,onChange:(e,t)=>{Dt(q,e,t)},onAddOption:kt,onOpenFile:(e,t)=>{let n=z.indexOf(q.id),r=R.indexOf(e);n>=0&&r>=0&&nn({r:n,c:r},t)},...Ht?{onAddFiles:e=>{let t=z.indexOf(q.id),n=R.indexOf(e);t>=0&&n>=0&&Gt({r:t,c:n})}}:{},onStep:e=>{let t=z.indexOf(q.id),n=z[t+e];if(n===void 0)return;Vt(n);let r=z.indexOf(n);if(r<0)return;let i={r,c:H?.focus.c??0};U(Hl(i)),cn(i)},onClose:()=>{Vt(void 0),an()}},q.id)]}),(0,V.jsxs)(`footer`,{className:`sheet-status`,"data-testid":`sheet-status`,children:[(0,V.jsx)(`span`,{className:`sheet-count`,"data-testid":`sheet-count`,children:i.rows(z.length,I.rows.length)}),(0,V.jsx)(Ed,{parts:Pn,strings:i,onClear:()=>{Oe(void 0)}}),Bn&&Bn.count>0&&(0,V.jsxs)(`span`,{className:`sheet-stats`,"data-testid":`sheet-stats`,children:[Bn.average!==void 0&&(0,V.jsxs)(`span`,{children:[i.stats.average,` `,(0,V.jsx)(`b`,{children:Bn.average})]}),(0,V.jsxs)(`span`,{children:[i.stats.count,` `,(0,V.jsx)(`b`,{children:Bn.count})]}),Bn.sum!==void 0&&(0,V.jsxs)(`span`,{children:[i.stats.sum,` `,(0,V.jsx)(`b`,{children:Bn.sum})]})]})]})]}),kn&&(0,V.jsxs)(Te,{open:!0,modal:!1,onOpenChange:e=>{e||An(void 0)},children:[(0,V.jsx)(be,{asChild:!0,children:(0,V.jsx)(`span`,{className:`sheet-menu-anchor`,style:{left:kn.x,top:kn.y}})}),(0,V.jsxs)(xe,{align:`start`,className:`sheet-menu`,"data-testid":`sheet-context-menu`,onCloseAutoFocus:e=>{e.preventDefault()},children:[Un?.kind===`cell`&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(N,{disabled:!0,className:`sheet-menu-note`,children:[i.review.was,`:`,` `,Un.before===``?`—`:Ga(W(j,Un.column),Un.before,E)]}),(0,V.jsxs)(N,{onSelect:()=>{se(e=>e.filter(e=>e!==Un))},children:[(0,V.jsx)(g,{"aria-hidden":!0}),i.review.keep]}),(0,V.jsxs)(N,{onSelect:()=>{wt([Un])},children:[(0,V.jsx)(S,{"aria-hidden":!0}),i.review.undo]}),(0,V.jsx)(ge,{})]}),(0,V.jsxs)(N,{onSelect:()=>{let e=dn(!1);e!==void 0&&navigator.clipboard.writeText(e)},children:[(0,V.jsx)(y,{"aria-hidden":!0}),i.cell.copy,(0,V.jsx)(le,{children:Od(`C`)})]}),!a&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(N,{onSelect:()=>{let e=dn(!0);e!==void 0&&navigator.clipboard.writeText(e)},children:[(0,V.jsx)(Ze,{"aria-hidden":!0}),i.cell.cut,(0,V.jsx)(le,{children:Od(`X`)})]}),(0,V.jsxs)(N,{onSelect:()=>{navigator.clipboard.readText().then(fn,()=>{oe(i.cell.pasteHint)})},children:[(0,V.jsx)(Re,{"aria-hidden":!0}),i.cell.paste,(0,V.jsx)(le,{children:Od(`V`)})]}),(0,V.jsxs)(N,{onSelect:()=>{Vn&&F(ql(I,$e,Vn))},children:[(0,V.jsx)(Be,{"aria-hidden":!0}),i.cell.clearContents,(0,V.jsx)(le,{children:`⌫`})]}),Ht&&Hn&&W(j,Hn.column).type===`file`&&(0,V.jsxs)(N,{"data-testid":`sheet-insert-file`,onSelect:()=>{Gt(kn.cell)},children:[(0,V.jsx)(qe,{"aria-hidden":!0}),i.files.insert]}),(0,V.jsx)(ge,{}),(0,V.jsxs)(N,{onSelect:()=>{At(kn.cell,`above`)},children:[(0,V.jsx)(Pe,{"aria-hidden":!0}),i.row.insertAbove]}),(0,V.jsxs)(N,{onSelect:()=>{At(kn.cell,`below`)},children:[(0,V.jsx)(Ae,{"aria-hidden":!0}),i.row.insertBelow]}),(0,V.jsxs)(N,{variant:`destructive`,onSelect:()=>{Vn&&F(Fl(D.current.table,jt(Vn)))},children:[(0,V.jsx)(b,{"aria-hidden":!0}),i.row.remove(Vn?Vn.r1-Vn.r0+1:1)]})]}),(0,V.jsx)(ge,{}),(0,V.jsxs)(N,{onSelect:()=>{let e=z[kn.cell.r];e!==void 0&&Vt(e)},children:[(0,V.jsx)(Ke,{"aria-hidden":!0}),i.row.expand,(0,V.jsx)(le,{children:Od(`↵`)})]})]})]}),$t&&(0,V.jsx)(Ms,{files:$t.files,at:$t.at,dir:n,fileUrl:Fe,strings:i,readOnly:a,onStep:e=>{en({...$t,at:e});let t=z.indexOf($t.files[e]?.row??-1),n=R.indexOf($t.column);t>=0&&n>=0&&ln(Hl({r:t,c:n}))},onRemove:e=>{let t=D.current.table,n=t.rows.find(t=>t.id===e.row);if(!n)return;let r=W(j,$t.column),i=Ia(n.cells[t.columns.indexOf($t.column)]??``,r.separator);i.splice(e.at,1),Dt(n,$t.column,La(i,r.separator)),en(void 0),an()},onClose:()=>{en(void 0),an()}}),(0,V.jsx)(Ee,{open:Ft!==void 0,onOpenChange:e=>{e||It(void 0)},children:(0,V.jsxs)(fe,{className:`sheet-dialog`,showCloseButton:!1,children:[(0,V.jsx)(we,{children:(0,V.jsx)(A,{children:Ft?.title})}),(0,V.jsxs)(pe,{children:[(0,V.jsx)(he,{variant:`ghost`,onClick:()=>{It(void 0)},children:i.column.cancel}),(0,V.jsxs)(he,{variant:`destructive`,"data-testid":`sheet-confirm`,onClick:()=>{Ft?.run(),It(void 0)},children:[(0,V.jsx)(b,{"aria-hidden":!0}),i.column.confirm]})]})]})})]})}export{Ld as SheetEditor};
|