allyhub 0.19.0 → 0.20.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/commands/align.js +1 -1
- package/dist/commands/check.js +1 -1
- package/dist/commands/cloud-tools.js +1 -1
- package/dist/commands/cloud.js +1 -1
- package/dist/commands/dev.js +5 -5
- package/dist/commands/export.js +3 -0
- package/dist/commands/frames/doc.js +1 -1
- package/dist/commands/frames/piece.js +1 -1
- package/dist/commands/frames/sheet.js +1 -1
- package/dist/commands/frames.js +9 -9
- package/dist/commands/index.js +1 -1
- package/dist/commands/inspect/combos.js +1 -1
- package/dist/commands/inspect/common.js +2 -2
- package/dist/commands/inspect/facts.js +2 -2
- package/dist/commands/migrate.js +3 -0
- package/dist/commands/skills.js +3 -3
- package/dist/commands/upgrade.js +5 -0
- package/dist/commands.json +1 -1
- package/dist/help.js +3 -3
- package/dist/main.js +8 -7
- package/dist/node_modules/@allyhub/3d-extension/package.json +2 -2
- package/dist/node_modules/@allyhub/audio/package.json +1 -1
- package/dist/node_modules/@allyhub/blocks/LICENSE +241 -0
- package/dist/node_modules/@allyhub/blocks/dist/alt.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/elements.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/flow-resolve.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/flow-table.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/format.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/gantt.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/grids.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/html.js +75 -0
- package/dist/node_modules/@allyhub/blocks/dist/icons.generated.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/icons.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/index.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/layout.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/look.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/measure.js +3 -0
- package/dist/node_modules/@allyhub/blocks/dist/model.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/page.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/palette.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/path.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/resolve.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/samples.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/sankey.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/svg.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/tidy.js +2 -0
- package/dist/node_modules/@allyhub/blocks/dist/trees.js +2 -0
- package/dist/node_modules/@allyhub/blocks/package.json +19 -0
- package/dist/node_modules/@allyhub/browser/dist/html.js +1 -1
- package/dist/node_modules/@allyhub/browser/package.json +1 -1
- package/dist/node_modules/@allyhub/build/dist/fonts.js +9 -3
- package/dist/node_modules/@allyhub/build/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/build/dist/inspect-view.js +1 -1
- package/dist/node_modules/@allyhub/build/dist/migrate.js +2 -0
- package/dist/node_modules/@allyhub/build/dist/prepare.js +3 -3
- package/dist/node_modules/@allyhub/build/dist/work.js +3 -3
- package/dist/node_modules/@allyhub/build/package.json +5 -1
- package/dist/node_modules/@allyhub/canvas-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/canvas-model/package.json +1 -1
- package/dist/node_modules/@allyhub/chart/dist/chart-file.js +2 -1
- package/dist/node_modules/@allyhub/chart/dist/chart-xml.js +4 -3
- package/dist/node_modules/@allyhub/chart/dist/chart.js +4 -2
- package/dist/node_modules/@allyhub/chart/dist/chartex-xml.js +4 -0
- package/dist/node_modules/@allyhub/chart/dist/classic.js +2 -0
- package/dist/node_modules/@allyhub/chart/dist/embedded.js +2 -2
- package/dist/node_modules/@allyhub/chart/dist/extended.js +2 -0
- package/dist/node_modules/@allyhub/chart/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/chart/dist/svg.js +1 -1
- package/dist/node_modules/@allyhub/chart/dist/tree.js +2 -0
- package/dist/node_modules/@allyhub/chart/package.json +1 -1
- package/dist/node_modules/@allyhub/check/dist/check.js +1 -1
- package/dist/node_modules/@allyhub/check/package.json +1 -1
- package/dist/node_modules/@allyhub/cloud/dist/blobs.js +1 -1
- package/dist/node_modules/@allyhub/cloud/dist/call.js +4 -4
- package/dist/node_modules/@allyhub/cloud/dist/client.js +1 -1
- package/dist/node_modules/@allyhub/cloud/dist/storage.js +2 -0
- package/dist/node_modules/@allyhub/cloud/dist/uploads.js +2 -2
- package/dist/node_modules/@allyhub/cloud/package.json +1 -1
- package/dist/node_modules/@allyhub/components/package.json +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/background.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/item-process.js +2 -0
- package/dist/node_modules/@allyhub/dev-server/dist/item-worker.js +2 -0
- package/dist/node_modules/@allyhub/dev-server/dist/live.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/pages.js +20 -1
- package/dist/node_modules/@allyhub/dev-server/dist/project.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/record.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/server.js +2 -2
- package/dist/node_modules/@allyhub/dev-server/dist/tools.js +1 -1
- package/dist/node_modules/@allyhub/dev-server/dist/validate.js +2 -2
- package/dist/node_modules/@allyhub/dev-server/dist/writer.js +3 -3
- package/dist/node_modules/@allyhub/dev-server/package.json +1 -1
- package/dist/node_modules/@allyhub/diagnostics/dist/rules.js +1 -1
- package/dist/node_modules/@allyhub/diagnostics/package.json +1 -1
- package/dist/node_modules/@allyhub/doc/dist/blocks.js +2 -0
- package/dist/node_modules/@allyhub/doc/dist/chart.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/color.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/docx-read.js +12 -0
- package/dist/node_modules/@allyhub/doc/dist/docx.js +5 -4
- package/dist/node_modules/@allyhub/doc/dist/html.js +83 -48
- package/dist/node_modules/@allyhub/doc/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/markdown.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/merges.js +2 -0
- package/dist/node_modules/@allyhub/doc/dist/model.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/numbering.js +2 -0
- package/dist/node_modules/@allyhub/doc/dist/omml.js +3 -0
- package/dist/node_modules/@allyhub/doc/dist/page.js +2 -1
- package/dist/node_modules/@allyhub/doc/dist/paper.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/parse.js +5 -4
- package/dist/node_modules/@allyhub/doc/dist/redline.js +2 -0
- package/dist/node_modules/@allyhub/doc/dist/revisions.js +2 -0
- package/dist/node_modules/@allyhub/doc/dist/shapes.js +4 -0
- package/dist/node_modules/@allyhub/doc/dist/styles.js +2 -0
- package/dist/node_modules/@allyhub/doc/dist/table.js +1 -1
- package/dist/node_modules/@allyhub/doc/dist/write.js +65 -39
- package/dist/node_modules/@allyhub/doc/package.json +5 -1
- package/dist/node_modules/@allyhub/doc-extension/dist/build.js +2 -2
- package/dist/node_modules/@allyhub/doc-extension/dist/cli/find.js +1 -1
- package/dist/node_modules/@allyhub/doc-extension/dist/cli/import.js +3 -0
- package/dist/node_modules/@allyhub/doc-extension/dist/cli/index.js +1 -1
- package/dist/node_modules/@allyhub/doc-extension/dist/cli/styles.js +4 -0
- package/dist/node_modules/@allyhub/doc-extension/dist/export.js +1 -1
- package/dist/node_modules/@allyhub/doc-extension/dist/inspect.js +1 -1
- package/dist/node_modules/@allyhub/doc-extension/dist/project-tools.js +1 -1
- package/dist/node_modules/@allyhub/doc-extension/dist/tools.js +1 -1
- package/dist/node_modules/@allyhub/doc-extension/package.json +22 -2
- package/dist/node_modules/@allyhub/doc-print/dist/drawn.js +4 -4
- package/dist/node_modules/@allyhub/doc-print/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/doc-print/dist/layout.js +8 -7
- package/dist/node_modules/@allyhub/doc-print/dist/print.js +22 -16
- package/dist/node_modules/@allyhub/doc-print/package.json +1 -1
- package/dist/node_modules/@allyhub/export/dist/export.js +1 -1
- package/dist/node_modules/@allyhub/export/package.json +1 -1
- package/dist/node_modules/@allyhub/extension-api/package.json +1 -1
- package/dist/node_modules/@allyhub/extension-host/dist/points.js +1 -1
- package/dist/node_modules/@allyhub/extension-host/package.json +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/blocks-flow.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/blocks.d.ts +146 -0
- package/dist/node_modules/@allyhub/formats/dist/data/blocks.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/cell-styles.d.ts +9 -0
- package/dist/node_modules/@allyhub/formats/dist/data/cell-styles.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/deck-code.d.ts +47 -40
- package/dist/node_modules/@allyhub/formats/dist/data/deck-code.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/diagram-kinds.d.ts +6 -0
- package/dist/node_modules/@allyhub/formats/dist/data/diagram-kinds.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/diagrams.d.ts +29 -0
- package/dist/node_modules/@allyhub/formats/dist/data/diagrams.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/faces.d.ts +18 -0
- package/dist/node_modules/@allyhub/formats/dist/data/faces.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/page-data.d.ts +59 -0
- package/dist/node_modules/@allyhub/formats/dist/data/page-data.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/reference.d.ts +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/sheet.d.ts +698 -258
- package/dist/node_modules/@allyhub/formats/dist/data/sheet.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/slides.d.ts +14104 -2167
- package/dist/node_modules/@allyhub/formats/dist/data/slides.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/data/themes.d.ts +82 -0
- package/dist/node_modules/@allyhub/formats/dist/data/themes.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/tokens.d.ts +67 -0
- package/dist/node_modules/@allyhub/formats/dist/data/tokens.js +2 -0
- package/dist/node_modules/@allyhub/formats/dist/data/work.d.ts +42 -0
- package/dist/node_modules/@allyhub/formats/dist/data/work.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/index.d.ts +7 -0
- package/dist/node_modules/@allyhub/formats/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/items.d.ts +12 -3
- package/dist/node_modules/@allyhub/formats/dist/schemas.d.ts +3260 -290
- package/dist/node_modules/@allyhub/formats/dist/schemas.js +1 -1
- package/dist/node_modules/@allyhub/formats/dist/tolerant.d.ts +45 -0
- package/dist/node_modules/@allyhub/formats/dist/tolerant.js +2 -0
- package/dist/node_modules/@allyhub/formats/package.json +1 -1
- package/dist/node_modules/@allyhub/html-extension/dist/project-tools.js +21 -9
- package/dist/node_modules/@allyhub/html-extension/dist/tools.js +1 -1
- package/dist/node_modules/@allyhub/html-extension/markup/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/html-extension/markup/markup.json +14 -4
- package/dist/node_modules/@allyhub/html-extension/markup/pages/budget.html +22 -1
- package/dist/node_modules/@allyhub/html-extension/package.json +9 -1
- package/dist/node_modules/@allyhub/i18n/package.json +1 -1
- package/dist/node_modules/@allyhub/image-draw/dist/fonts.js +1 -1
- package/dist/node_modules/@allyhub/image-draw/dist/inspect.js +2 -2
- package/dist/node_modules/@allyhub/image-draw/package.json +1 -1
- package/dist/node_modules/@allyhub/image-extension/dist/build-plugins.js +1 -1
- package/dist/node_modules/@allyhub/image-extension/dist/cli.js +1 -1
- package/dist/node_modules/@allyhub/image-extension/package.json +2 -2
- package/dist/node_modules/@allyhub/image-extension/skills/allyhub/references/images.md +1 -1
- package/dist/node_modules/@allyhub/image-measure/dist/layout.js +2 -2
- package/dist/node_modules/@allyhub/image-measure/package.json +1 -1
- package/dist/node_modules/@allyhub/image-psd/package.json +1 -1
- package/dist/node_modules/@allyhub/image-render/package.json +1 -1
- package/dist/node_modules/@allyhub/image-runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/image-sdk/dist/block.js +2 -0
- package/dist/node_modules/@allyhub/image-sdk/dist/blocks.js +2 -0
- package/dist/node_modules/@allyhub/image-sdk/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/image-sdk/package.json +1 -1
- package/dist/node_modules/@allyhub/jobs/package.json +1 -1
- package/dist/node_modules/@allyhub/linkedin-extension/package.json +1 -3
- package/dist/node_modules/@allyhub/linkedin-extension/skills/allyhub/references/linkedin.md +3 -3
- package/dist/node_modules/@allyhub/linkedin-model/package.json +1 -1
- package/dist/node_modules/@allyhub/linkedin-view/package.json +1 -1
- package/dist/node_modules/@allyhub/measure/package.json +1 -1
- package/dist/node_modules/@allyhub/media/package.json +1 -1
- package/dist/node_modules/@allyhub/media-extension/dist/analyses/faces.js +1 -1
- package/dist/node_modules/@allyhub/media-extension/dist/asr/transcribe.js +1 -1
- package/dist/node_modules/@allyhub/media-extension/dist/ocr/text.js +1 -1
- package/dist/node_modules/@allyhub/media-extension/dist/vision/faces.js +1 -1
- package/dist/node_modules/@allyhub/media-extension/dist/vision/index-media.js +3 -2
- package/dist/node_modules/@allyhub/media-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/model/package.json +1 -1
- package/dist/node_modules/@allyhub/office-extension/markup/csv/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/csv/markup.json +1 -1
- package/dist/node_modules/@allyhub/office-extension/markup/document/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/presentation/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/workbook/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/office-extension/markup/workbook/markup.json +1 -1
- package/dist/node_modules/@allyhub/office-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/ooxml/dist/ext.js +1 -1
- package/dist/node_modules/@allyhub/ooxml/dist/mce.js +1 -1
- package/dist/node_modules/@allyhub/ooxml/dist/node.js +1 -1
- package/dist/node_modules/@allyhub/ooxml/dist/ns.js +1 -1
- package/dist/node_modules/@allyhub/ooxml/dist/opc.js +1 -1
- package/dist/node_modules/@allyhub/ooxml/package.json +1 -1
- package/dist/node_modules/@allyhub/piece/dist/export.d.ts +1 -1
- package/dist/node_modules/@allyhub/piece/dist/layout.d.ts +2 -0
- package/dist/node_modules/@allyhub/piece/dist/look.d.ts +10 -2
- package/dist/node_modules/@allyhub/piece/dist/look.js +1 -1
- package/dist/node_modules/@allyhub/piece/dist/media.d.ts +8 -2
- package/dist/node_modules/@allyhub/piece/dist/script.js +1 -1
- package/dist/node_modules/@allyhub/piece/dist/source.d.ts +3 -0
- package/dist/node_modules/@allyhub/piece/package.json +1 -1
- package/dist/node_modules/@allyhub/project/dist/media-index.js +1 -1
- package/dist/node_modules/@allyhub/project/package.json +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/cli.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/cloud.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/events.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/kinds.js +1 -1
- package/dist/node_modules/@allyhub/protocol/dist/page-frame.js +2 -0
- package/dist/node_modules/@allyhub/protocol/package.json +1 -1
- package/dist/node_modules/@allyhub/registry/package.json +1 -1
- package/dist/node_modules/@allyhub/render/package.json +1 -1
- package/dist/node_modules/@allyhub/runtime/dist/footage.js +1 -1
- package/dist/node_modules/@allyhub/runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/runtimes/dist/packages.js +2 -2
- package/dist/node_modules/@allyhub/runtimes/dist/runtimes.js +3 -3
- package/dist/node_modules/@allyhub/runtimes/package.json +1 -1
- package/dist/node_modules/@allyhub/scaffold/dist/index.js +12 -8
- package/dist/node_modules/@allyhub/scaffold/package.json +1 -1
- package/dist/node_modules/@allyhub/scenery/package.json +1 -1
- package/dist/node_modules/@allyhub/scenery-host/package.json +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/api/capabilities.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/api/charts.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/api/index.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/api/styles.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/api/workbook.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/engine.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/calc/server.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/cell-styles.js +2 -0
- package/dist/node_modules/@allyhub/sheet/dist/chart.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/check.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/file.js +2 -2
- package/dist/node_modules/@allyhub/sheet/dist/heatmap.js +2 -0
- package/dist/node_modules/@allyhub/sheet/dist/html.js +10 -10
- package/dist/node_modules/@allyhub/sheet/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/inspect.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/paginate.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/printed.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/sdk.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/sparklines.js +2 -0
- package/dist/node_modules/@allyhub/sheet/dist/table-style.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/table-styles.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/theme.js +2 -0
- package/dist/node_modules/@allyhub/sheet/dist/tiles.js +2 -0
- package/dist/node_modules/@allyhub/sheet/dist/units.js +2 -0
- package/dist/node_modules/@allyhub/sheet/dist/workbook.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/write.js +14 -14
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/charts.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/import.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/read.js +2 -2
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/styles.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/theme.js +1 -1
- package/dist/node_modules/@allyhub/sheet/dist/xlsx/write.js +1 -1
- package/dist/node_modules/@allyhub/sheet/package.json +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/dist/build.js +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/dist/cli/sheet.js +7 -7
- package/dist/node_modules/@allyhub/sheet-extension/dist/code.js +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/dist/evaluate.js +2 -2
- package/dist/node_modules/@allyhub/sheet-extension/dist/export.js +2 -2
- package/dist/node_modules/@allyhub/sheet-extension/dist/inspect.js +2 -2
- package/dist/node_modules/@allyhub/sheet-extension/dist/migrations.js +4 -0
- package/dist/node_modules/@allyhub/sheet-extension/dist/project-tools.js +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/dist/tools.js +1 -1
- package/dist/node_modules/@allyhub/sheet-extension/package.json +7 -3
- package/dist/node_modules/@allyhub/slides-core/dist/api.js +2 -2
- package/dist/node_modules/@allyhub/slides-core/dist/blocks.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/capabilities.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/chart-api.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/code.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/enums.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/file.js +3 -3
- package/dist/node_modules/@allyhub/slides-core/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/measure.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/model.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/office-layouts.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/office.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/resolve.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/script.js +2 -2
- package/dist/node_modules/@allyhub/slides-core/dist/styles/brief.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/styles/editorial.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/styles/index.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/styles/kit.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/styles/layouts.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/styles/pitch.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/styles/stage.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/styles/tiles.js +2 -0
- package/dist/node_modules/@allyhub/slides-core/dist/theme.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/dist/units.js +1 -1
- package/dist/node_modules/@allyhub/slides-core/package.json +1 -1
- package/dist/node_modules/@allyhub/slides-extension/dist/check.js +1 -1
- package/dist/node_modules/@allyhub/slides-extension/dist/cli/slides.js +2 -2
- package/dist/node_modules/@allyhub/slides-extension/dist/deck-fonts.js +1 -1
- package/dist/node_modules/@allyhub/slides-extension/dist/project-tools.js +1 -1
- package/dist/node_modules/@allyhub/slides-extension/package.json +24 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/charts.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/fonts.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/image-size.js +2 -0
- package/dist/node_modules/@allyhub/slides-pptx/dist/import/code.js +3 -3
- package/dist/node_modules/@allyhub/slides-pptx/dist/import/index.js +7 -2
- package/dist/node_modules/@allyhub/slides-pptx/dist/import/names.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/import/script.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/mtx.js +2 -0
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/chart.js +3 -2
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/chartex.js +3 -0
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/common.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/index.js +2 -2
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/shapes.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/table.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/text.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/read/timing.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/shapes.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/text.js +1 -1
- package/dist/node_modules/@allyhub/slides-pptx/dist/write.js +2 -2
- package/dist/node_modules/@allyhub/slides-pptx/dist/xml.js +3 -2
- package/dist/node_modules/@allyhub/slides-pptx/package.json +1 -1
- package/dist/node_modules/@allyhub/slides-runtime/dist/draw.js +2 -2
- package/dist/node_modules/@allyhub/slides-runtime/dist/load.js +1 -1
- package/dist/node_modules/@allyhub/slides-runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/stage/package.json +1 -1
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/LICENSE +93 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-ext-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-ext-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-ext-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/files/archivo-latin-ext-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-ext-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-ext-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-ext-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo/latin-ext-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo-black/LICENSE +93 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo-black/files/archivo-black-latin-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo-black/files/archivo-black-latin-ext-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo-black/latin-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/archivo-black/latin-ext-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/LICENSE +93 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-ext-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-ext-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-ext-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/files/ibm-plex-sans-latin-ext-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-ext-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-ext-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-ext-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/ibm-plex-sans/latin-ext-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/LICENSE +93 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-ext-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-ext-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-ext-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/files/inter-latin-ext-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-ext-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-ext-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-ext-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/inter-static/latin-ext-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/LICENSE +93 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-ext-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-ext-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-ext-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/files/newsreader-latin-ext-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-ext-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-ext-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-ext-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/newsreader/latin-ext-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/LICENSE +93 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-ext-400-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-ext-400-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-ext-700-italic.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/files/plus-jakarta-sans-latin-ext-700-normal.woff2 +0 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-ext-400-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-ext-400.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-ext-700-italic.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/fonts/plus-jakarta-sans/latin-ext-700.css +1 -0
- package/dist/node_modules/@allyhub/stage-page/dist/host.js +1 -1
- package/dist/node_modules/@allyhub/stage-page/dist/runtime/stage.html +42 -0
- package/dist/node_modules/@allyhub/stage-page/dist/style-faces.js +2 -0
- package/dist/node_modules/@allyhub/stage-page/package.json +1 -1
- package/dist/node_modules/@allyhub/stage-runtime/dist/runtime.js +96 -92
- package/dist/node_modules/@allyhub/stage-runtime/package.json +1 -1
- package/dist/node_modules/@allyhub/telemetry/dist/limit.js +2 -0
- package/dist/node_modules/@allyhub/telemetry/package.json +5 -1
- package/dist/node_modules/@allyhub/text-extension/markup/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/text-extension/markup-file/allyhub.yaml +2 -0
- package/dist/node_modules/@allyhub/text-extension/package.json +1 -1
- package/dist/node_modules/@allyhub/video-core/dist/footage-motion.js +1 -1
- package/dist/node_modules/@allyhub/video-core/dist/measure.js +1 -1
- package/dist/node_modules/@allyhub/video-core/dist/seams.js +1 -1
- package/dist/node_modules/@allyhub/video-core/package.json +1 -1
- package/dist/node_modules/@allyhub/video-extension/dist/cli/reference-text.js +1 -1
- package/dist/node_modules/@allyhub/video-extension/dist/inspect/index.js +1 -1
- package/dist/node_modules/@allyhub/video-extension/dist/inspect/joins.js +1 -1
- package/dist/node_modules/@allyhub/video-extension/dist/inspect/loop.js +3 -0
- package/dist/node_modules/@allyhub/video-extension/package.json +2 -25
- package/dist/node_modules/@allyhub/video-measure/dist/check.js +2 -2
- package/dist/node_modules/@allyhub/video-measure/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/video-measure/dist/seams.js +1 -1
- package/dist/node_modules/@allyhub/video-measure/dist/version.js +1 -1
- package/dist/node_modules/@allyhub/video-measure/package.json +1 -1
- package/dist/node_modules/@allyhub/video-sdk/dist/free.js +1 -1
- package/dist/node_modules/@allyhub/video-sdk/package.json +1 -1
- package/dist/node_modules/@allyhub/website/dist/index.js +1 -1
- package/dist/node_modules/@allyhub/website/dist/website.js +2 -2
- package/dist/node_modules/@allyhub/website/package.json +1 -1
- package/dist/node_modules/@allyhub/website-extension/package.json +3 -3
- package/dist/node_modules/@allyhub/x-extension/package.json +1 -3
- package/dist/node_modules/@allyhub/x-extension/skills/allyhub/references/x.md +3 -3
- package/dist/node_modules/@allyhub/x-model/package.json +1 -1
- package/dist/node_modules/@allyhub/x-view/package.json +1 -1
- package/dist/package.json +14 -14
- package/dist/self-upgrade.js +2 -0
- package/dist/text/batch-text.js +1 -1
- package/dist/text/facts-text.js +5 -5
- package/dist/text/format.js +2 -2
- package/dist/update-notice.js +3 -0
- package/dist/version.js +1 -1
- package/dist/works.js +1 -1
- package/editor-web/assets/{abnfDiagram-WEYOIA3C-DYaMS_BB.js → abnfDiagram-WEYOIA3C-BkVJMd53.js} +1 -1
- package/editor-web/assets/{architecture-WOLXFQ4H-g_Tjfl_y.js → architecture-WOLXFQ4H-C6rnaynZ.js} +1 -1
- package/editor-web/assets/{architectureDiagram-ZHVYKT53-CqdhofOL.js → architectureDiagram-ZHVYKT53-D3vrh8LK.js} +1 -1
- package/editor-web/assets/arrow-down-D-QZrqcz.js +1 -0
- package/editor-web/assets/arrow-up-B1zjKUHX.js +1 -0
- package/editor-web/assets/article-DHf6mOY_.js +7 -0
- package/editor-web/assets/article-Dns1-Xh-.js +3 -0
- package/editor-web/assets/{audio-lines-PZj77e7t.js → audio-lines-BFoW_IeO.js} +1 -1
- package/editor-web/assets/bar-button-CKPfx2AB.js +1 -0
- package/editor-web/assets/{blockDiagram-RJAE7QA3-Bc-28Bci.js → blockDiagram-RJAE7QA3-BKngt8H7.js} +1 -1
- package/editor-web/assets/{browser-C9NP0ZYz.js → browser-DEGNhKTV.js} +1 -1
- package/editor-web/assets/{c4Diagram-XDPPPE54-CTGJb8FB.js → c4Diagram-XDPPPE54-j7sUELqF.js} +1 -1
- package/editor-web/assets/calc-worker-Cr4a0xmt.js +168 -0
- package/editor-web/assets/channel-CVWSV3su.js +1 -0
- package/editor-web/assets/{chart-no-axes-column-Be0lFcGF.js → chart-no-axes-column-Dyy25XZ_.js} +1 -1
- package/editor-web/assets/chip-Bn_9JRRG.js +1 -0
- package/editor-web/assets/{chunk-2E7WHVMD-B2MPOVTU.js → chunk-2E7WHVMD-BXa-uRSi.js} +1 -1
- package/editor-web/assets/{chunk-4EMNKR2T-BUV1ZHP0.js → chunk-4EMNKR2T-B3ntcsZN.js} +1 -1
- package/editor-web/assets/{chunk-55XCU76K-BZlpspL5.js → chunk-55XCU76K-AMvnFwUg.js} +1 -1
- package/editor-web/assets/{chunk-7S6XSTFO-CpKeisWE.js → chunk-7S6XSTFO-BA6esfFu.js} +1 -1
- package/editor-web/assets/{chunk-AQDTSKZB-BJqwAPyo.js → chunk-AQDTSKZB-BT_vANXs.js} +1 -1
- package/editor-web/assets/{chunk-DSNLSHJZ-D6oPWl_W.js → chunk-DSNLSHJZ-DoUgmzGB.js} +1 -1
- package/editor-web/assets/{chunk-HAGFOTED-B5pk4MZF.js → chunk-HAGFOTED-DtnIrCZb.js} +1 -1
- package/editor-web/assets/{chunk-HNE4Q36P-DHbSPvxQ.js → chunk-HNE4Q36P-BlPwQx3_.js} +1 -1
- package/editor-web/assets/{chunk-NQOKRVIF-CcL_GcRA.js → chunk-NQOKRVIF-D2r7jp2r.js} +1 -1
- package/editor-web/assets/{chunk-UHW7PFBP-YgiOL6XE.js → chunk-UHW7PFBP-Cmc0_F5o.js} +1 -1
- package/editor-web/assets/{chunk-VQ5W62QI-p14b4UYc.js → chunk-VQ5W62QI-nJSMqAr0.js} +1 -1
- package/editor-web/assets/{chunk-WQQL4CDK-BWW0x-XH.js → chunk-WQQL4CDK-Btq2nbF6.js} +1 -1
- package/editor-web/assets/{chunk-YZO67HFG-oG3qd68C.js → chunk-YZO67HFG-DTbcCoGt.js} +1 -1
- package/editor-web/assets/{chunk-ZAUX2LTX-CpcheH0u.js → chunk-ZAUX2LTX-DVwkg-2N.js} +1 -1
- package/editor-web/assets/{chunk-ZCHMQSOR-cWQvLl1w.js → chunk-ZCHMQSOR-BV39jOOE.js} +1 -1
- package/editor-web/assets/{classDiagram-v2-4MYWR3UA-7PG7YcdU.js → classDiagram-v2-4MYWR3UA-Cj74-fhM.js} +1 -1
- package/editor-web/assets/code-Ch6AB5bZ.js +1 -0
- package/editor-web/assets/collaborator-XiHOxwGM.js +1 -0
- package/editor-web/assets/{copy-CuJSs0nI.js → copy-SoaMYqsN.js} +1 -1
- package/editor-web/assets/{createLucideIcon-lm_6n8YT.js → createLucideIcon-euu7Wcd9.js} +1 -1
- package/editor-web/assets/{cynefin-EF2NZ3EQ-CtcknEQ_.js → cynefin-EF2NZ3EQ-C0CkiipV.js} +1 -1
- package/editor-web/assets/{cynefinDiagram-WF24UDRP-Ca7VIsjN.js → cynefinDiagram-WF24UDRP-hdsnJ4cI.js} +1 -1
- package/editor-web/assets/{dagre-NK4GIZVX-BzcSLtsr.js → dagre-NK4GIZVX-CC7WSgaK.js} +1 -1
- package/editor-web/assets/deck-DQpNIS2p.js +1 -0
- package/editor-web/assets/{diagram-CBK3MWTC-DpRmTGlG.js → diagram-CBK3MWTC-DmaVm13J.js} +1 -1
- package/editor-web/assets/{diagram-I5XIIV2D-BTrs_AX8.js → diagram-I5XIIV2D-De8jqp7b.js} +1 -1
- package/editor-web/assets/{diagram-ODIL2UCW-CkIVjPqH.js → diagram-ODIL2UCW-B5pBTulX.js} +1 -1
- package/editor-web/assets/{diagram-PFBEJUXE-BlFMbAG1.js → diagram-PFBEJUXE-BYsXg5_w.js} +1 -1
- package/editor-web/assets/{diagram-RJA3I4VV-D3f8VJ-D.js → diagram-RJA3I4VV-DZ8f6bYe.js} +1 -1
- package/editor-web/assets/{diagram-TYUNFSNR-Bbpngj6F.js → diagram-TYUNFSNR-qXHUsauD.js} +1 -1
- package/editor-web/assets/dist--z0ZHp4T.js +16 -0
- package/editor-web/assets/dist-9kuRjUTN.js +41 -0
- package/editor-web/assets/dist-B3rd02Cg.js +6 -0
- package/editor-web/assets/dist-B5GOGGEe.js +1 -0
- package/editor-web/assets/dist-Bx6q9kCu.js +1 -0
- package/editor-web/assets/dist-C4hHtrJr.js +1 -0
- package/editor-web/assets/dist-CCXJewsi.js +19 -0
- package/editor-web/assets/dist-CfK2BLl8.js +4 -0
- package/editor-web/assets/dist-Cmux3oJ_.js +1 -0
- package/editor-web/assets/dist-Cspf85KV.js +6 -0
- package/editor-web/assets/dist-DA72-4WB.js +82 -0
- package/editor-web/assets/{dist-DruvDNQe.js → dist-DAhe-kFC.js} +5 -5
- package/editor-web/assets/dist-DIJnhQFK.js +9 -0
- package/editor-web/assets/dist-DOrGo1GD.js +19 -0
- package/editor-web/assets/{dist-Bd8IxQPP.js → dist-DQ6RpEJD.js} +2 -2
- package/editor-web/assets/dist-DjiCHlSu.js +35 -0
- package/editor-web/assets/dist-Do4a40Wn.js +19 -0
- package/editor-web/assets/dist-FKEWS3Co.js +547 -0
- package/editor-web/assets/dist-QKd2i6kG.js +5 -0
- package/editor-web/assets/dist-SGnOfLhx.js +24 -0
- package/editor-web/assets/dist-VmVB7tl4.js +3 -0
- package/editor-web/assets/{docx-draw-CoK1oqQD.js → docx-draw-L54blreB.js} +1 -1
- package/editor-web/assets/{ebnfDiagram-V4P3TTPT-BaKj-yL6.js → ebnfDiagram-V4P3TTPT-B7-IfVI-.js} +1 -1
- package/editor-web/assets/{elk-QONTBCTQ-Cn2qv1_U.js → elk-QONTBCTQ-Gj_WaeBn.js} +1 -1
- package/editor-web/assets/{erDiagram-KYQIGQAA-Bd7AEIDo.js → erDiagram-KYQIGQAA-BDF6Qoqx.js} +1 -1
- package/editor-web/assets/esm-PQD5Pn8a.js +21 -0
- package/editor-web/assets/{eventmodeling-K75KTNOO-Sfp7_461.js → eventmodeling-K75KTNOO-elxVXXEe.js} +1 -1
- package/editor-web/assets/{file-question-mark-DlIjUK37.js → file-question-mark-PeZgyqkK.js} +1 -1
- package/editor-web/assets/flowDiagram-IUGLLWBU-B-25n8zE.js +1 -0
- package/editor-web/assets/{ganttDiagram-R7GPNTJY-CBqcGdHI.js → ganttDiagram-R7GPNTJY-CEogW3jW.js} +1 -1
- package/editor-web/assets/{gitGraph-VSP46ZUC-WTokXKTW.js → gitGraph-VSP46ZUC-Bh9cRWFa.js} +1 -1
- package/editor-web/assets/{gitGraphDiagram-PDYL7XHY-BIWZHD9q.js → gitGraphDiagram-PDYL7XHY-BQAvdM_V.js} +1 -1
- package/editor-web/assets/{group-BdrTp7gi.js → group-DwM2yqU8.js} +1 -1
- package/editor-web/assets/hint-CbwoSBMw.js +1 -0
- package/editor-web/assets/index-CXisi0Cj.css +2 -0
- package/editor-web/assets/index-wMlfx8aT.js +28 -0
- package/editor-web/assets/{info-OHQRW6UA-COC6G-_J.js → info-OHQRW6UA-CdPrqere.js} +1 -1
- package/editor-web/assets/{infoDiagram-MVDRKAX5-DpaqdKBD.js → infoDiagram-MVDRKAX5-uwIMeP44.js} +1 -1
- package/editor-web/assets/{ishikawaDiagram-HPEHV2GE-Dyn2MAy1.js → ishikawaDiagram-HPEHV2GE-rtfvqK7E.js} +1 -1
- package/editor-web/assets/iso-UwGLGD3F.js +1 -0
- package/editor-web/assets/{italic-zw4_eUNF.js → italic-BV7iHxoP.js} +1 -1
- package/editor-web/assets/{journeyDiagram-BOSHW7O7-DeSVfmm7.js → journeyDiagram-BOSHW7O7-mmhfIyVG.js} +1 -1
- package/editor-web/assets/{kanban-definition-FNSA4HC5-Bfg0lj7B.js → kanban-definition-FNSA4HC5-Fe7jBsi-.js} +1 -1
- package/editor-web/assets/{link-DopSU3aa.js → link-CFOv3nz-.js} +1 -1
- package/editor-web/assets/{mermaid-parser.core-CyhovuYE.js → mermaid-parser.core-BxOSjBH9.js} +3 -3
- package/editor-web/assets/{mermaid.core-Dx1fBVUG.js → mermaid.core-BOln9YdH.js} +4 -4
- package/editor-web/assets/{mindmap-definition-6OY57UG3-QEU2HF_m.js → mindmap-definition-6OY57UG3-M3Q1LOtO.js} +1 -1
- package/editor-web/assets/minus-ngE8owxs.js +1 -0
- package/editor-web/assets/{packet-JDAUHWVQ-ReJTa_hw.js → packet-JDAUHWVQ-Dbb0TUG6.js} +1 -1
- package/editor-web/assets/{pegDiagram-ECIUJNBX-Bo1jFrvb.js → pegDiagram-ECIUJNBX-BZMRpSFC.js} +1 -1
- package/editor-web/assets/{pie-XZMESJXO-BrtYafNA.js → pie-XZMESJXO-Ctm9XdKp.js} +1 -1
- package/editor-web/assets/{pieDiagram-GNMPY74T-Cj0zQqs_.js → pieDiagram-GNMPY74T-cGbs5ZTl.js} +1 -1
- package/editor-web/assets/progress-DZQTiRLv.js +6 -0
- package/editor-web/assets/{quadrantDiagram-D57K4MC3-D5npDAVn.js → quadrantDiagram-D57K4MC3-BUe_zsxT.js} +1 -1
- package/editor-web/assets/{radar-ABXABTNO-C8RDrRqi.js → radar-ABXABTNO-CCmKtqLs.js} +1 -1
- package/editor-web/assets/{railroad-I3PHUGI6-ebDrmYTK.js → railroad-I3PHUGI6-k-yhjhjA.js} +1 -1
- package/editor-web/assets/{railroad-abnf-LNEFI6M7-BxKuqg6V.js → railroad-abnf-LNEFI6M7-B-PvntB3.js} +1 -1
- package/editor-web/assets/{railroad-ebnf-DWYD2UWJ-DOclnfpr.js → railroad-ebnf-DWYD2UWJ-Ds2rua1h.js} +1 -1
- package/editor-web/assets/{railroad-peg-JR7BVNR7-DN0A1fpq.js → railroad-peg-JR7BVNR7-jNZ2wEp2.js} +1 -1
- package/editor-web/assets/{railroadDiagram-Y72NRBL7-B3PjoVWw.js → railroadDiagram-Y72NRBL7-CTqSQ15w.js} +1 -1
- package/editor-web/assets/react-Byupo4pA.js +1 -0
- package/editor-web/assets/replace-CLLMtF4e.js +1 -0
- package/editor-web/assets/{requirementDiagram-EQYSW5RA-DLdzkQk5.js → requirementDiagram-EQYSW5RA-CUblhR5M.js} +1 -1
- package/editor-web/assets/ribbon-DajdQ_Ya.js +1 -0
- package/editor-web/assets/row-Bei9HNEe.js +1 -0
- package/editor-web/assets/{sankeyDiagram-SY24JHO5-Dip4Piv_.js → sankeyDiagram-SY24JHO5-nSz6zDX3.js} +1 -1
- package/editor-web/assets/schemas-C21MyseF.js +1 -0
- package/editor-web/assets/{iso-DoC-ZoBr.js → schemas-DlRAoVtq.js} +1 -1
- package/editor-web/assets/{scissors-B_xOiUhd.js → scissors-m6QcoEf2.js} +1 -1
- package/editor-web/assets/search-D75Bi2GU.js +1 -0
- package/editor-web/assets/{sequenceDiagram-BLEHNHQU-QnPcoybL.js → sequenceDiagram-BLEHNHQU-DxTpOYuo.js} +1 -1
- package/editor-web/assets/{session-DMlLCFWg.js → session-BhClkDyr.js} +1 -1
- package/editor-web/assets/{sigma-DSUsJhMn.js → sigma-B4AWtnVA.js} +1 -1
- package/editor-web/assets/snapshots-DwGHDN3t.js +1 -0
- package/editor-web/assets/sound-DkR3qxSt.js +1 -0
- package/editor-web/assets/split-DBAbwPZ5.js +3 -0
- package/editor-web/assets/{square-arrow-out-up-right-DF5dvsSp.js → square-arrow-out-up-right-1NqFsNDe.js} +1 -1
- package/editor-web/assets/{stateDiagram-v2-A6IESKWZ-D103CiMX.js → stateDiagram-v2-A6IESKWZ-C3e14iHY.js} +1 -1
- package/editor-web/assets/{sticky-note-BdkIu5_D.js → sticky-note-s4QfzaBB.js} +1 -1
- package/editor-web/assets/surface-CIF0Ae0z.js +1 -0
- package/editor-web/assets/swatch-BUzr_XmH.js +1 -0
- package/editor-web/assets/{swimlanes-B3ENRKFQ-y4gCqEoa.js → swimlanes-B3ENRKFQ-DPPdzNzu.js} +1 -1
- package/editor-web/assets/swimlanesDiagram-AYQRV4AK-B8n3zOw_.js +8 -0
- package/editor-web/assets/switch-DrZxoPQS.js +1 -0
- package/editor-web/assets/{syntax-CU_WPKxt.js → syntax-emXV4DnN.js} +1 -1
- package/editor-web/assets/table-BW43XXVd.js +1 -0
- package/editor-web/assets/tabs-BwU2E7bU.js +1 -0
- package/editor-web/assets/text-wrap-Baus6l-V.js +1 -0
- package/editor-web/assets/textarea-BX_ax3X8.js +1 -0
- package/editor-web/assets/{timeline-definition-JXYKGLGB-BMp76v4V.js → timeline-definition-JXYKGLGB-DRTJ1_Er.js} +1 -1
- package/editor-web/assets/tolerant-DM9s0Mt1.js +1 -0
- package/editor-web/assets/{treeView-D4JQ5SDB-Q_GYyk0b.js → treeView-D4JQ5SDB-BYJ_m-i5.js} +1 -1
- package/editor-web/assets/{treemap-SAJKECNS-B5lRWdQB.js → treemap-SAJKECNS-BcU6I6Rg.js} +1 -1
- package/editor-web/assets/type-CvZ0HZsV.js +41 -0
- package/editor-web/assets/{undo-2-C47jrRp5.js → undo-2-DCbMWoug.js} +1 -1
- package/editor-web/assets/{usecaseDiagram-WPOLBNNX--QRllA-U.js → usecaseDiagram-WPOLBNNX-YV92pS4o.js} +1 -1
- package/editor-web/assets/{vennDiagram-Q3Y3IDCW-CzkATPA3.js → vennDiagram-Q3Y3IDCW-oAvfHZtf.js} +1 -1
- package/editor-web/assets/video-SJvDRCJK.js +1 -0
- package/editor-web/assets/{wardley-7MLQ67FV-BXzwcdJa.js → wardley-7MLQ67FV-BLNiqxtt.js} +1 -1
- package/editor-web/assets/{wardleyDiagram-IVAIDKWA-BQvC8Agx.js → wardleyDiagram-IVAIDKWA-SppgC6xW.js} +1 -1
- package/editor-web/assets/{whole-word-D3ZAtnkw.js → whole-word-C9TkGBCY.js} +1 -1
- package/editor-web/assets/{words-CaUHhQHf.js → words-BUlNNuH2.js} +3 -3
- package/editor-web/assets/words-zMedmPWc.js +3 -0
- package/editor-web/assets/workbook-BZKYx4WB.js +41 -0
- package/editor-web/assets/{xychartDiagram-4URNHDU4-aY-lsD5o.js → xychartDiagram-4URNHDU4-BHMn_jwJ.js} +1 -1
- package/editor-web/assets/{zoom-in-PgsC94hP.js → zoom-in-yAGKspfC.js} +1 -1
- package/editor-web/index.html +9 -8
- package/package.json +3 -3
- package/CHANGELOG.md +0 -251
- package/dist/commands/render.js +0 -3
- package/dist/node_modules/@allyhub/video-extension/dist/inspect/motion.js +0 -4
- package/dist/node_modules/@allyhub/video-measure/dist/still.js +0 -2
- package/editor-web/assets/arrow-down-B8VUPCGi.js +0 -1
- package/editor-web/assets/arrow-up-Ds4juY8X.js +0 -1
- package/editor-web/assets/article-8evPh712.js +0 -3
- package/editor-web/assets/article-BhRtWYMd.js +0 -7
- package/editor-web/assets/bar-button-J9vbfzTx.js +0 -1
- package/editor-web/assets/calc-worker-oEIqrrTM.js +0 -45
- package/editor-web/assets/channel-wIj_OqDm.js +0 -1
- package/editor-web/assets/chart-amT4lgX3.js +0 -2
- package/editor-web/assets/chart-file-dGiRgFcH.js +0 -1
- package/editor-web/assets/code-CD-CbJG9.js +0 -1
- package/editor-web/assets/collaborator-BU4qU7O3.js +0 -1
- package/editor-web/assets/deck-C7fN0Qtn.js +0 -1
- package/editor-web/assets/dist-3iovns9K.js +0 -16
- package/editor-web/assets/dist-BkHnbOEj.js +0 -4
- package/editor-web/assets/dist-BvOrNcK-.js +0 -19
- package/editor-web/assets/dist-CEIszq39.js +0 -1
- package/editor-web/assets/dist-CU5RbLNH.js +0 -1
- package/editor-web/assets/dist-CWZj8IAm.js +0 -1
- package/editor-web/assets/dist-C_Mtrnif.js +0 -17
- package/editor-web/assets/dist-CdqpwdCV.js +0 -24
- package/editor-web/assets/dist-CjT76RAw.js +0 -43
- package/editor-web/assets/dist-CpzEn9T8.js +0 -6
- package/editor-web/assets/dist-CrFYWl5-.js +0 -3
- package/editor-web/assets/dist-D3C6FyrO.js +0 -82
- package/editor-web/assets/dist-D4eBFGVL.js +0 -1
- package/editor-web/assets/dist-DTcjb3cP.js +0 -18
- package/editor-web/assets/dist-D_WSM29I.js +0 -17
- package/editor-web/assets/dist-Dp_9ISjP.js +0 -531
- package/editor-web/assets/dist-J-tPYKGS.js +0 -5
- package/editor-web/assets/dist-YW8hS4IM.js +0 -9
- package/editor-web/assets/esm-Cjv8ogpP.js +0 -21
- package/editor-web/assets/file-exclamation-point-_L3ElCJ5.js +0 -1
- package/editor-web/assets/flowDiagram-IUGLLWBU-BlVUglzw.js +0 -1
- package/editor-web/assets/hint-rlht0uxG.js +0 -1
- package/editor-web/assets/index-BQWZnyAQ.js +0 -28
- package/editor-web/assets/index-Dvh1t1om.css +0 -2
- package/editor-web/assets/minus-CbPnUIOy.js +0 -1
- package/editor-web/assets/progress-CwKcXARv.js +0 -6
- package/editor-web/assets/props-form-BpSXbrSF.js +0 -1
- package/editor-web/assets/react-Edyoga_4.js +0 -1
- package/editor-web/assets/row-C_svyL8o.js +0 -1
- package/editor-web/assets/schemas-CQ_UU8-Z.js +0 -1
- package/editor-web/assets/search-Ba2BbT6T.js +0 -1
- package/editor-web/assets/slides-7xWhREpt.js +0 -1
- package/editor-web/assets/snapshots-BLX4NTQC.js +0 -1
- package/editor-web/assets/sound-bTlco_K3.js +0 -1
- package/editor-web/assets/split-tFGKk-x8.js +0 -3
- package/editor-web/assets/strikethrough-BwXWi4zg.js +0 -1
- package/editor-web/assets/surface-DtCjIlrq.js +0 -1
- package/editor-web/assets/svg-CWIBMIQ9.js +0 -1
- package/editor-web/assets/swatch-DhztHwPU.js +0 -1
- package/editor-web/assets/swimlanesDiagram-AYQRV4AK-DKzB_wSf.js +0 -8
- package/editor-web/assets/switch-8MU4Nfxe.js +0 -1
- package/editor-web/assets/table-DRbddzx0.js +0 -1
- package/editor-web/assets/tabs-CuEawka3.js +0 -1
- package/editor-web/assets/tag-CIfWT8B_.js +0 -1
- package/editor-web/assets/text-align-start-Cic2-TLh.js +0 -1
- package/editor-web/assets/textarea-D7TnPwv1.js +0 -1
- package/editor-web/assets/video-D0uTbHWx.js +0 -1
- package/editor-web/assets/words-XlXG79Ur.js +0 -3
- package/editor-web/assets/workbook-CiCXkjmN.js +0 -45
- package/editor-web/assets/x-DlhyIKuu.js +0 -41
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
-
import{chartColor as te,chartFrame as ne,docChartSvg as ie}from"./chart.js";import{emojiPicturesScript as oe}from"@allyhub/browser/emoji";export{EMOJI_PATTERN}from"@allyhub/browser/emoji";import{BACKGROUNDS as B,TEXT_COLORS as D}from"./color.js";import{columnWidths as ae,COLUMN_GAP as se}from"./columns.js";import{COMPONENT_WIDTH as U,componentName as re}from"./component.js";import{citationText as de,citedOf as le,sourceList as ce}from"./cite.js";import{blockId as pe,captionNumbers as fe,contentsTitle as he,numberedCaption as R,writtenInChinese as ge,withoutTitle as ue}from"./captions.js";import{DRAWN_CODE as K,mathHtml as me}from"./math.js";import{charsAcross as X,columnShares as $e,emptyHead as be,numberColumns as ke,withTableData as xe}from"./table.js";import{splitTitle as we}from"./title.js";import{PAPER as l,TONE_COLORS as Z,tagColors as ye}from"./paper.js";import{COVER_HEIGHT_MM as Se,everyBlock as q,innerBlocks as ve,noteNumbers as Ce,statTone as ze}from"./model.js";import{effectiveLook as H,lineMultiple as Ee,resolvePage as j,SINGLE_LINE as I}from"./page.js";export const PAGE_FACES={sans:'Carlito, Calibri, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif',serif:'Caladea, Cambria, "Noto Serif SC", "Songti SC", Georgia, serif',times:'Tinos, "Times New Roman", Times, "Noto Serif SC", serif',mono:'Cousine, "Courier New", "Noto Sans SC", monospace',song:'"Noto Serif SC", "Songti SC", SimSun, "宋体", serif',hei:'"Noto Sans SC", "PingFang SC", SimHei, "黑体", sans-serif',fangsong:'FangSong, STFangsong, "仿宋", "FangSong_GB2312", "Noto Serif SC", serif',kai:'"LXGW WenKai", KaiTi, STKaiti, "楷体", "Noto Serif SC", serif',xiaobiaosong:'"FZXiaoBiaoSong-B05S", "方正小标宋简体", "Noto Serif SC", "Songti SC", serif'};export function pageFaces(i={}){const n=H(i).font??"sans";return{text:PAGE_FACES[n],heading:PAGE_FACES[n],mono:PAGE_FACES.mono}}export const pageAccent=(i={})=>i.accent===void 0?void 0:te(i.accent);export{BACKGROUNDS,TEXT_COLORS}from"./color.js";export function blockNumbers(i){const n=new Map;for(const e of q(i))n.set(e,n.size);return n}const p=i=>i.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,"""),O=(i,n)=>n[i]??(/^(#[0-9a-f]{3,8}|[a-z]+|(rgb|hsl)a?\([\d\s.,%/]+\))$/i.test(i)?i:void 0),h=(i,n)=>{const e=n.ids?.get(i);return e===void 0?"":` data-b="${String(e)}"`};export function headingAnchors(i){const n=new Map,e=new Map;for(const a of q(i)){if(a.type!=="heading")continue;const s=a.content.map(r=>r.text).join("").trim().toLowerCase().replace(/[^\p{L}\p{N}\s-]/gu,"").replace(/\s/gu,"-"),t=s===""?"section":s,o=e.get(t)??0;e.set(t,o+1),n.set(a,o===0?t:`${t}-${String(o)}`)}return n}function x(i,n){return i.map(e=>{if(e.cite!==void 0){const{items:d,numbers:c,style:f}=n.sources,g=le(e.cite).keys[0],w=p(de(e.cite,d,c,f));return g!==void 0&&c.has(g)?`<a class="cite" href="#source-${p(g)}">${w}</a>`:`<span class="cite">${w}</span>`}if(e.note!==void 0){const d=n.notes.get(e.note.toLowerCase());return d===void 0?`<sup class="fn">[${p(e.note)}]</sup>`:`<sup class="fn"><a href="#note-${String(d)}">${String(d)}</a></sup>`}const a=e.text===""&&e.href?.startsWith("#")===!0?n.refs.get(decodeURIComponent(e.href.slice(1)))??"":e.text;let s=p(a).replace(/\n/g,"<br>");const t=e.styles;t.code&&(s=`<code>${s}</code>`),t.strike&&(s=`<s>${s}</s>`),t.italic&&(s=`<em>${s}</em>`),t.bold&&(s=`<strong>${s}</strong>`),t.underline&&(s=`<u>${s}</u>`);const o=t.color===void 0?void 0:O(t.color,D),r=t.background===void 0?void 0:O(t.background,B);if((o!==void 0||r!==void 0)&&(s=`<span style="${o===void 0?"":`color:${o};`}${r===void 0?"":`background:${r};`}">${s}</span>`),t.tag!==void 0){const d=ye(t.tag);s=`<span class="tag" style="background:${d.bg};color:${d.fg}">${s}</span>`}return e.href!==void 0&&/^(https?:|mailto:|#|\/|\.)/i.test(e.href)&&(s=`<a href="${p(e.href)}">${s}</a>`),s}).join("")}function z(i,n=!1){if(!i)return"";const e=i.color===void 0?void 0:O(i.color,D),a=i.background===void 0?void 0:O(i.background,B),s=[i.align===void 0?"":`text-align:${i.align};`,e===void 0?"":`color:${e};`,a===void 0?"":n?`background:${a};`:`background:${a};padding:0.15em 0.4em;border-radius:3px;`].join("");return s===""?"":` style="${s}"`}const Y=i=>i.type==="bullet"||i.type==="numbered"||i.type==="check";function S(i,n,e){const a=[];let s=0;for(;s<i.length;){const t=i[s];if(t===void 0)break;if(Y(t)){const o=t.type==="numbered";let r=s;const d=[];for(;r<i.length;){const f=i[r];if(!f||!Y(f)||f.type==="numbered"!==o)break;const g=f.type==="check"?`<span class="box${f.checked?" done":""}"></span>`:"";d.push(`<li${h(f,e)}${f.type==="check"?` class="task${f.checked?" done":""}"`:""}${z(f.look)}>${g}<span class="words">${x(f.content,e)}</span>${S(f.children??[],n,e)}</li>`),r++}const c=t.type==="numbered"&&t.start!==void 0?` start="${String(t.start)}"`:"";a.push(o?`<ol${c}>${d.join("")}</ol>`:`<ul>${d.join("")}</ul>`),s=r;continue}switch(s++,t.type){case"paragraph":a.push(`<p${h(t,e)}${z(t.look)}>${x(t.content,e)||" "}</p>${W(t.children,n,e)}`);break;case"heading":{const o=`h${String(t.level)}`;a.push(`<${o} id="${p(e.anchors.get(t)??"")}"${h(t,e)}${z(t.look)}>${x(t.content,e)}</${o}>${W(t.children,n,e)}`);break}case"toggle":a.push(`<p${h(t,e)}${z(t.look)}>${x(t.content,e)}</p>${W(t.children,n,e)}`);break;case"quote":a.push(`<blockquote${h(t,e)}${z(t.look)}><p>${x(t.content,e)}</p>${S(t.children??[],n,e)}</blockquote>`);break;case"callout":a.push(`<div class="callout"${h(t,e)}${z(t.look,!0)}>${t.icon===void 0?"":`<span class="callout-icon">${p(t.icon)}</span>`}<div><p>${x(t.content,e)}</p>${S(t.children??[],n,e)}</div></div>`);break;case"card":a.push(`<div class="card${cardKept(t,j(n.page))?" kept":""}"${h(t,e)}>${t.title===void 0&&t.subtitle===void 0?"":`<div class="card-head">${t.title===void 0?"":`<p class="card-title">${p(t.title)}</p>`}${t.subtitle===void 0?"":`<p class="card-subtitle">${p(t.subtitle)}</p>`}</div>`}${S(t.children??[],{...n,room:(n.room??U)-2*Ne},e)}</div>`);break;case"stats":a.push(`<div class="stats"${h(t,e)} style="grid-template-columns:repeat(${String(t.stats.length)},minmax(0,1fr))">${t.stats.map(o=>{const r=ze(o),d=o.delta===void 0&&o.note===void 0?"":`<p class="stat-foot">${o.delta===void 0?"":`<span class="stat-delta" style="color:${Z[r]}">${p(o.delta)}</span>`}${o.delta!==void 0&&o.note!==void 0?" ":""}${o.note===void 0?"":p(o.note)}</p>`,c=o.trend===void 0?"":trendSvg(o.trend,Z[r==="flat"?"flat":r]);return`<div class="stat"><p class="stat-label">${p(o.label)}</p><p class="stat-value">${p(o.value)}</p>${d}${c}</div>`}).join("")}</div>`);break;case"code":a.push(je(t,n,h(t,e)));break;case"columns":{const o=t.columns.map(d=>`${String(d.width??1)}fr`).join(" "),r=ae(t,n.room);a.push(`<div class="columns${columnsKept(t,j(n.page))?" kept":""}"${h(t,e)} style="grid-template-columns:${o}">${t.columns.map((d,c)=>`<div class="column">${S(d.blocks,{...n,room:r[c]??U},e)}</div>`).join("")}</div>`);break}case"chart":{const o=e.numbers.get(t),r=o===void 0?t:ue(t),{svg:d,problems:c}=ie(r,{...n,font:pageFaces(n.page).text}),{width:f}=ne(t,n.room),g=o===void 0||t.title===void 0?"":`<figcaption>${p(R(t.title,o))}</figcaption>`;a.push(d===void 0?`<div class="embed"${h(t,e)} data-chart>${p(t.title??"Chart")}<br><small>${p(c.join("; "))}</small></div>`:`<figure class="chart"${L(t.id)}${h(t,e)} style="max-width:${String(f)}px">${d}${g}</figure>`);break}case"image":{const o=n.image?.(t.src)??t.src;a.push(`<figure${L(t.id)}${h(t,e)}${t.align===void 0?"":` style="text-align:${t.align}"`}><img src="${p(o)}" alt="${p(t.alt??"")}"${t.width===void 0?"":` width="${String(t.width)}"`}>${t.caption===void 0?"":`<figcaption>${p(R(t.caption,e.numbers.get(t)))}</figcaption>`}</figure>`);break}case"table":{const o=t.head===void 0||t.head==="both",r=t.head==="column"||t.head==="both",d=ke(t),c=be(t),f=(m,$,y)=>`<tr${e.ids===void 0?"":` data-row="${String(y)}"`}>${m.map((_,F)=>{const G=$||r&&F===0?"th":"td",ee=d.has(F)?' class="num"':"";return`<${G}${ee}>${x(_,e)}</${G}>`}).join("")}</tr>`,g=j(n.page),w=(t.widths??[]).reduce((m,$)=>m+($??0),0),P=n.room??g.textWidth*96/25.4,E=$e(t,{across:X(Math.max(P-w,0),g.spacing.small),margins:X(2*g.spacing.cell.side*96/72,g.spacing.small)}),C=E.reduce((m,$,y)=>m+(t.widths?.[y]?0:$),0)||1,T=`<colgroup>${E.map((m,$)=>{const y=t.widths?.[$],_=b(m/C*100);return y?`<col style="width:${String(y)}px">`:w===0?`<col style="width:${_}%">`:`<col style="width:calc((100% - ${String(w)}px) * ${b(m/C)})">`}).join("")}</colgroup>`,[M,...N]=t.rows,A=o&&M!==void 0&&!c?`<thead>${f(M,!0,0)}</thead>`:"",u=(o?N:t.rows).map((m,$)=>f(m,!1,o?$+1:$)).join(""),v=t.caption===void 0?"":`<caption>${p(R(t.caption,e.numbers.get(t)))}</caption>`;a.push(`<table${L(t.id)}${h(t,e)}>${v}${T}${A}<tbody>${u}</tbody></table>`);break}case"divider":a.push(`<hr${h(t,e)}>`);break;case"pagebreak":a.push(`<div class="page-break"${h(t,e)}></div>`);break;case"toc":a.push(Te(t,e));break;case"bibliography":e.listed||(e.listed=!0,a.push(J(e,h(t,e))));break;case"note":break;case"component":{const o=n.component?.(t),r=t.align===void 0?"":` style="text-align:${t.align}"`;a.push(o===void 0?`<div class="embed"${h(t,e)} data-component>${p(re(t))}</div>`:`<figure${L(t.id)}${h(t,e)}${r}><img src="${p(o)}" alt="${p(t.alt??"")}"${t.width===void 0?"":` width="${String(t.width)}"`}>${t.caption===void 0?"":`<figcaption>${p(R(t.caption,e.numbers.get(t)))}</figcaption>`}</figure>`);break}case"embed":{const o=n.embed?.(t.source,e.embeds);e.embeds++;const r=/^<\s*([A-Za-z][\w.]*)/.exec(t.source.trim())?.[1];a.push(o===void 0?`<div class="embed"${h(t,e)} data-embed>${p(r??"")}</div>`:`<div${h(t,e)}>${o}</div>`);break}case"source":break}}return a.join(`
|
|
3
|
-
`)}function
|
|
4
|
-
`).map(n
|
|
2
|
+
import{colorsOfTheme as ne}from"@allyhub/formats";import{chartColor as be,chartFrame as xe,docChartSvg as ke,chartTheme as we}from"./chart.js";import{emojiPicturesScript as ve}from"@allyhub/browser/emoji";export{EMOJI_PATTERN}from"@allyhub/browser/emoji";import{BACKGROUNDS as R,TEXT_COLORS as D}from"./color.js";import{columnWidths as Se,COLUMN_GAP as ye}from"./columns.js";import{COMPONENT_WIDTH as O,componentName as Ce}from"./component.js";import{citationText as Te,citedOf as Ae,sourceList as Ee}from"./cite.js";import{blockId as ze,captionNumbers as Me,contentsTitle as je,numberedCaption as G,writtenInChinese as Fe,withoutTitle as Ne}from"./captions.js";import{calloutTone as Re,docStatsSvg as Oe,inlineIconSvg as ie,libraryBlockSvg as He,libraryBlockTable as Le}from"./blocks.js";import{DRAWN_CODE as oe,mathHtml as _e}from"./math.js";import{charsAcross as ae,columnShares as Ie,emptyHead as Be,numberColumns as We,withTableData as Pe}from"./table.js";import{splitTitle as qe}from"./title.js";import{PAPER as u,tagColors as re}from"./paper.js";import{COVER_HEIGHT_MM as De,everyBlock as U,innerBlocks as Ge,noteNumbers as Ue}from"./model.js";import{effectiveLook as H,lineMultiple as Ke,resolvePage as T,WATERMARK_COLOR as Xe,WATERMARK_OPACITY as Ye,WATERMARK_WASHOUT as se,SINGLE_LINE as L,sizePt as Ze}from"./page.js";import{LIST_BULLETS as Qe,headingNumbers as Je,listNumber as Ve}from"./numbering.js";import{alignAt as et,cellSpans as tt,columnLetters as nt}from"./merges.js";import{CAPTION_STYLE as it,LIST_PARAGRAPH as ot,NORMAL as at,QUOTE_STYLE as rt,TITLE_STYLE as st,headingStyle as dt,pickProps as lt,resolveStyle as ct,resolveTableStyle as de,styleId as _,TABLE_GRID as Y}from"./styles.js";export const PAGE_FACES={sans:'Carlito, Calibri, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif',serif:'Caladea, Cambria, "Noto Serif SC", "Songti SC", Georgia, serif',times:'Tinos, "Times New Roman", Times, "Noto Serif SC", serif',mono:'Cousine, "Courier New", "Noto Sans SC", monospace',song:'"Noto Serif SC", "Songti SC", SimSun, "宋体", serif',hei:'"Noto Sans SC", "PingFang SC", SimHei, "黑体", sans-serif',fangsong:'FangSong, STFangsong, "仿宋", "FangSong_GB2312", "Noto Serif SC", serif',kai:'"LXGW WenKai", KaiTi, STKaiti, "楷体", "Noto Serif SC", serif',xiaobiaosong:'"FZXiaoBiaoSong-B05S", "方正小标宋简体", "Noto Serif SC", "Songti SC", serif'};export function pageFaces(i={}){const n=H(i).font??"sans";return{text:PAGE_FACES[n],heading:PAGE_FACES[n],mono:PAGE_FACES.mono}}export const pageAccent=(i={})=>i.accent!==void 0?themeColorOf(i.accent,i)??be(i.accent):i.theme===void 0?void 0:ne(i.theme).accent1,themeColorOf=(i,n)=>ne(n.theme)[i.trim()];export{BACKGROUNDS,TEXT_COLORS}from"./color.js";export function blockNumbers(i){const n=new Map;for(const t of U(i))n.set(t,n.size);return n}export const TAB_STOP_PT=36;const f=i=>i.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,"""),A=(i,n)=>n[i]??(/^(#[0-9a-f]{3,8}|[a-z]+|(rgb|hsl)a?\([\d\s.,%/]+\))$/i.test(i)?i:void 0),g=(i,n)=>{const t=n.ids?.get(i);return t===void 0?"":` data-b="${String(t)}"`};export function headingAnchors(i){const n=new Map,t=new Map;for(const o of U(i)){if(o.type!=="heading")continue;const s=o.content.map(r=>r.text).join("").trim().toLowerCase().replace(/[^\p{L}\p{N}\s-]/gu,"").replace(/\s/gu,"-"),e=s===""?"section":s,a=t.get(e)??0;t.set(e,a+1),n.set(o,a===0?e:`${e}-${String(a)}`)}return n}function ft(i,n){const[t="",o=""]=(i.field??"").split(" ");switch(t.toUpperCase()){case"PAGEREF":{const s=n.headingPage?.(o);return s===void 0?i.text:String(s)}case"REF":return n.refs.get(o)??i.text;default:return i.text}}function E(i,n){return i.map(t=>{if(t.cite!==void 0){const{items:l,numbers:h,style:$}=n.sources,p=Ae(t.cite).keys[0],x=f(Te(t.cite,l,h,$));return p!==void 0&&h.has(p)?`<a class="cite" href="#source-${f(p)}">${x}</a>`:`<span class="cite">${x}</span>`}if(t.note!==void 0){const l=n.notes.get(t.note.toLowerCase());return l===void 0?`<sup class="fn">[${f(t.note)}]</sup>`:`<sup class="fn"><a href="#note-${String(l)}">${String(l)}</a></sup>`}const o=t.field!==void 0?ft(t,n):t.text===""&&t.href?.startsWith("#")===!0?n.refs.get(decodeURIComponent(t.href.slice(1)))??"":t.text;let s=f(o).replace(/\n/g,"<br>").replace(/\t/g,'<span class="tab"> </span>');const e=t.styles;e.code&&(s=`<code>${s}</code>`);const a=l=>f([l.author,l.date].filter(Boolean).join(", "));e.formatted&&(s=`<span class="rev-formatted" title="${a(e.formatted)}">${s}</span>`),e.deleted&&(s=`<del class="rev${e.deleted.move===void 0?"":" rev-moved"}" title="${a(e.deleted)}">${s}</del>`),e.inserted&&(s=`<ins class="rev${e.inserted.move===void 0?"":" rev-moved"}" title="${a(e.inserted)}">${s}</ins>`),e.superscript&&(s=`<sup>${s}</sup>`),e.subscript&&(s=`<sub>${s}</sub>`);const r=propsCss({...e.font===void 0?{}:{font:e.font},...e.size===void 0?{}:{size:e.size},...e.caps?{caps:!0}:{},...e.smallCaps?{smallCaps:!0}:{},...e.letterSpacing===void 0?{}:{letterSpacing:e.letterSpacing}});(r!==""||e.style!==void 0)&&(s=`<span${e.style===void 0?"":` class="cs-${_(e.style)}"`}${r===""?"":` style="${r}"`}>${s}</span>`),e.strike&&(s=`<s>${s}</s>`),e.italic&&(s=`<em>${s}</em>`),e.bold&&(s=`<strong>${s}</strong>`),e.underline&&(s=`<u>${s}</u>`);const d=e.color===void 0?void 0:A(e.color,D),c=e.background===void 0?void 0:A(e.background,R);if((d!==void 0||c!==void 0)&&(s=`<span style="${d===void 0?"":`color:${d};`}${c===void 0?"":`background:${c};`}">${s}</span>`),e.tag!==void 0){const l=re(e.tag);s=`<span class="tag" style="background:${l.bg};color:${l.fg}">${s}</span>`}return t.href!==void 0&&/^(https?:|mailto:|#|\/|\.)/i.test(t.href)&&(s=`<a href="${f(t.href)}">${s}</a>`),s}).join("")}export function propsCss(i){const n=i.font===void 0?void 0:Object.hasOwn(PAGE_FACES,i.font)?PAGE_FACES[i.font]:`"${i.font.replace(/["\\]/gu,"")}", ${PAGE_FACES.sans}`,t=i.lineHeight===void 0?void 0:typeof i.lineHeight=="number"?m(i.lineHeight*(L[i.font??"sans"]??1)):i.lineHeight;return[n===void 0?"":`font-family:${n};`,i.size===void 0?"":`font-size:${m(Ze(i.size))}pt;`,i.bold===void 0?"":`font-weight:${i.bold?"700":"400"};`,i.italic===void 0?"":`font-style:${i.italic?"italic":"normal"};`,i.underline===!0||i.strike===!0?`text-decoration:${[i.underline?"underline":"",i.strike?"line-through":""].join(" ").trim()};`:"",i.color===void 0?"":`color:${A(i.color,D)??i.color};`,i.background===void 0?"":`background:${A(i.background,R)??i.background};`,i.caps===!0?"text-transform:uppercase;":"",i.smallCaps===!0?"font-variant:small-caps;":"",i.letterSpacing===void 0?"":`letter-spacing:${m(i.letterSpacing)}pt;`,i.align===void 0?"":`text-align:${i.align};`,i.indent===void 0?"":`margin-left:${m(i.indent)}em;`,i.indentRight===void 0?"":`margin-right:${m(i.indentRight)}em;`,i.firstLine===void 0?"":`text-indent:${m(i.firstLine)}em;`,i.spaceBefore===void 0?"":`margin-top:${m(i.spaceBefore)}pt;`,i.spaceAfter===void 0?"":`margin-bottom:${m(i.spaceAfter)}pt;`,t===void 0?"":`line-height:${t};`,i.keepNext===!0?"break-after:avoid;":"",i.keepLines===!0?"break-inside:avoid;":"",i.pageBreakBefore===!0?"break-before:page;":""].join("")}function F(i,n=!1){if(!i)return"";const t=i.style,o=t===void 0?"":` class="ps-${_(t)}"`,s=propsCss(lt(i,"paragraph")),e=i.color===void 0?void 0:A(i.color,D),a=i.background===void 0?void 0:A(i.background,R),r=[e===void 0?"":`color:${e};`,a===void 0?"":n?`background:${a};`:`background:${a};padding:0.15em 0.4em;border-radius:3px;`,s].join("");return`${o}${r===""?"":` style="${r}"`}`}const le=i=>i.type==="bullet"||i.type==="numbered"||i.type==="check";function b(i,n,t){const o=[];let s=0;for(;s<i.length;){const e=i[s];if(e===void 0)break;if(e.revision!==void 0){const{kind:a,author:r,date:d,move:c}=e.revision,l=Object.fromEntries(Object.entries(e).filter(([h])=>h!=="revision"));o.push(`<div class="rev rev-${a}${c===void 0?"":" rev-moved"}" title="${f([r,d].filter(Boolean).join(", "))}">${b([l],n,t)}</div>`),s++;continue}if(e.formatted!==void 0){const{author:a,date:r}=e.formatted,d={...e};delete d.formatted,o.push(`<div class="rev-changed" title="${f([a,r].filter(Boolean).join(", "))}">${b([d],n,t)}</div>`),s++;continue}if(le(e)){const a=e.type==="numbered";let r=s;const d=[];for(;r<i.length;){const l=i[r];if(!l||!le(l)||l.type==="numbered"!==a)break;const h=l.type==="check"?`<span class="box${l.checked?" done":""}"></span>`:"",$=[...t.listCounts,(e.type==="numbered"?e.start??1:1)+d.length],p=n.page?.lists,x=l.type==="check"?"":` data-mark="${f(a?Ve(p?.numbered,$):p?.bullets?.[Math.min($.length,6)-1]??Qe[($.length-1)%3]??"•")}"`,v=t.listCounts;t.listCounts=a?$:[...v,1];const S=b(l.children??[],n,t);t.listCounts=v,d.push(`<li${g(l,t)}${l.type==="check"?` class="task${l.checked?" done":""}"`:""}${x}${F(l.look)}>${h}<span class="words">${E(l.content,t)}${Z(l)}</span>${S}</li>`),r++}const c=e.type==="numbered"&&e.start!==void 0?` start="${String(e.start)}"`:"";o.push(a?`<ol${c}>${d.join("")}</ol>`:`<ul>${d.join("")}</ul>`),s=r;continue}switch(s++,e.type){case"paragraph":o.push(`<p${g(e,t)}${F(e.look)}>${E(e.content,t)||(e.mark===void 0?" ":"")}${Z(e)}</p>${Q(e.children,n,t)}`);break;case"heading":{const a=`h${String(e.level)}`;o.push(`<${a} id="${f(t.anchors.get(e)??"")}"${g(e,t)}${F(e.look)}>${fe(e,t)}${E(e.content,t)}${Z(e)}</${a}>${Q(e.children,n,t)}`);break}case"toggle":o.push(`<p${g(e,t)}${F(e.look)}>${E(e.content,t)}</p>${Q(e.children,n,t)}`);break;case"quote":o.push(`<blockquote${g(e,t)}${F(e.look)}><p>${E(e.content,t)}</p>${b(e.children??[],n,t)}</blockquote>`);break;case"callout":{const a=Re(e.tone,n.page),r=e.icon??a?.icon,d=r===void 0?"":`<span class="callout-icon">${ie(r,a?.mark??u.lead)??f(r)}</span>`,c=a===void 0||e.look?.background!==void 0?"":` data-tone style="background:${a.bg};color:${a.fg}"`;o.push(`<div class="callout"${g(e,t)}${c===""?F(e.look,!0):c}>${d}<div><p>${E(e.content,t)}</p>${b(e.children??[],n,t)}</div></div>`);break}case"card":{const a=we(n.page).accent1,r=e.featured===!0,d=e.icon===void 0?"":`<p class="card-icon">${ie(e.icon,r?"#FFFFFF":a)??f(e.icon)}</p>`,c=e.tag===void 0?"":(()=>{const h=re("blue");return`<span class="tag card-tag" style="background:${h.bg};color:${h.fg}">${f(e.tag)}</span>`})(),l=e.title===void 0&&e.subtitle===void 0&&c===""?"":`<div class="card-head">${c}${e.title===void 0?"":`<p class="card-title">${f(e.title)}</p>`}${e.subtitle===void 0?"":`<p class="card-subtitle">${f(e.subtitle)}</p>`}</div>`;o.push(`<div class="card${cardKept(e,T(n.page))?" kept":""}${r?" featured":""}"${g(e,t)}${r?` style="background:${a};border-color:${a};color:#FFFFFF"`:""}>${d}${l}${b(e.children??[],{...n,room:(n.room??O)-2*mt},t)}</div>`);break}case"textbox":{const a=n.room??O,r=Math.min(e.width??(e.float===void 0&&e.wrap===void 0?a:ht),a);if(e.wrap!==void 0){o.push(`<figure class="over"${g(e,t)}><aside class="textbox" style="position:absolute;left:${String(e.x??0)}px;top:${String(e.y??0)}px;width:${String(r)}px;z-index:${e.wrap==="behind"?"-1":"2"}">${b(e.children??[],{...n,room:r-2*ue},t)}</aside></figure>`);break}const d=[...e.float===void 0?[]:[`float:${e.float}`,e.float==="left"?"margin:0.2em 1em 0.5em 0":"margin:0.2em 0 0.5em 1em"],...e.width===void 0&&e.float===void 0?[]:[`width:${String(r)}px`]].join(";");o.push(`<aside class="textbox"${g(e,t)}${d===""?"":` style="${d}"`}>${b(e.children??[],{...n,room:r-2*ue},t)}</aside>`);break}case"stats":{const a=Oe(e,n.room??O,{...n,id:`s${String(o.length)}`});o.push(`<div class="stats"${g(e,t)}>${a??""}</div>`);break}case"code":o.push(pt(e,n,g(e,t)));break;case"columns":{const a=e.columns.map(d=>`${String(d.width??1)}fr`).join(" "),r=Se(e,n.room);o.push(`<div class="columns${columnsKept(e,T(n.page))?" kept":""}"${g(e,t)} style="grid-template-columns:${a}">${e.columns.map((d,c)=>`<div class="column">${b(d.blocks,{...n,room:r[c]??O},t)}</div>`).join("")}</div>`);break}case"block":{const{svg:a,problems:r}=He(e,n.room??O,{...n,id:`b${String(t.numbers.size)}-${String(o.length)}`});o.push(a===void 0?`<div class="embed"${g(e,t)} data-block>${f(`<${e.tag}>`)}<br><small>${f(r.join("; "))}</small></div>`:`<figure class="block"${g(e,t)}>${a}</figure>`);const d=a===void 0?void 0:Le(e,n);d&&o.push(b([d],n,t));break}case"chart":{const a=t.numbers.get(e),r=a===void 0?e:Ne(e),{svg:d,problems:c}=ke(r,{...n,font:pageFaces(n.page).text}),{width:l}=xe(e,n.room),h=a===void 0||e.title===void 0?"":`<figcaption>${f(G(e.title,a))}</figcaption>`;o.push(d===void 0?`<div class="embed"${g(e,t)} data-chart>${f(e.title??"Chart")}<br><small>${f(c.join("; "))}</small></div>`:`<figure class="chart"${I(e.id)}${g(e,t)} style="max-width:${String(l)}px">${d}${h}</figure>`);break}case"image":{const a=n.image?.(e.src)??e.src;if(e.wrap!==void 0){o.push(`<figure class="over"${I(e.id)}${g(e,t)}><img src="${f(a)}" alt="${f(e.alt??"")}" style="left:${String(e.x??0)}px;top:${String(e.y??0)}px;z-index:${e.wrap==="behind"?"-1":"2"}"${e.width===void 0?"":` width="${String(e.width)}"`}></figure>`);break}const r=e.float!==void 0?` style="float:${e.float};margin:0.2em ${e.float==="left"?"1em 0.5em 0":"0 0.5em 1em"};max-width:50%"`:e.align===void 0?"":` style="text-align:${e.align}"`;o.push(`<figure${I(e.id)}${g(e,t)}${r}><img src="${f(a)}" alt="${f(e.alt??"")}"${e.width===void 0?"":` width="${String(e.width)}"`}>${e.caption===void 0?"":`<figcaption>${f(G(e.caption,t.numbers.get(e)))}</figcaption>`}</figure>`);break}case"table":{const a=e.head===void 0||e.head==="both",r=e.head==="column"||e.head==="both",d=We(e),c=Be(e),l=tt(e.merges),h=2*T(n.page).spacing.cell.top,$=(y,C,w)=>`<tr${t.ids===void 0?"":` data-row="${String(w)}"`}${e.heights?.[w]?` style="height:calc(${String(e.heights[w])}px + ${m(h)}pt)"`:""}>${y.map((X,N)=>{const j=l(w,N);if(j==="covered")return"";const V=C||r&&N===0?"th":"td",pe=d.has(N)?' class="num"':"",$e=j===void 0?"":`${j.cols>1?` colspan="${String(j.cols)}"`:""}${j.rows>1?` rowspan="${String(j.rows)}"`:""}`,ee=e.cells?.[`${nt(N)}${String(w+1)}`],te=et(e.valign,w,N);return`<${V}${pe}${$e}${te==="top"?"":` style="vertical-align:${te==="center"?"middle":"bottom"}"`}>${ee===void 0?E(X,t):`<div class="cell-blocks">${b(ee,n,t)}</div>`}</${V}>`}).join("")}</tr>`,p=T(n.page),x=(e.widths??[]).reduce((y,C)=>y+(C??0),0),v=n.room??p.textWidth*96/25.4,S=Ie(e,{across:ae(Math.max(v-x,0),p.spacing.small),margins:ae(2*p.spacing.cell.side*96/72,p.spacing.small)}),z=S.reduce((y,C,w)=>y+(e.widths?.[w]?0:C),0)||1,K=`<colgroup>${S.map((y,C)=>{const w=e.widths?.[C],X=m(y/z*100);return w?`<col style="width:${String(w)}px">`:x===0?`<col style="width:${X}%">`:`<col style="width:calc((100% - ${String(x)}px) * ${m(y/z)})">`}).join("")}</colgroup>`,[M,...B]=e.rows,W=a&&M!==void 0&&!c?`<thead>${$(M,!0,0)}</thead>`:"",P=(a?B:e.rows).map((y,C)=>$(y,!1,a?C+1:C)).join(""),q=e.caption===void 0?"":`<caption>${f(G(e.caption,t.numbers.get(e)))}</caption>`;o.push(`<table${I(e.id)}${e.style===void 0?"":` class="ts-${_(e.style)}"`}${g(e,t)}>${q}${K}${W}<tbody>${P}</tbody></table>`);break}case"divider":o.push(`<hr${g(e,t)}>`);break;case"pagebreak":o.push(`<div class="page-break"${g(e,t)}></div>`);break;case"toc":o.push(gt(e,t));break;case"bibliography":t.listed||(t.listed=!0,o.push(ce(t,g(e,t))));break;case"note":break;case"component":{const a=n.component?.(e),r=e.align===void 0?"":` style="text-align:${e.align}"`;o.push(a===void 0?`<div class="embed"${g(e,t)} data-component>${f(Ce(e))}</div>`:`<figure${I(e.id)}${g(e,t)}${r}><img src="${f(a)}" alt="${f(e.alt??"")}"${e.width===void 0?"":` width="${String(e.width)}"`}>${e.caption===void 0?"":`<figcaption>${f(G(e.caption,t.numbers.get(e)))}</figcaption>`}</figure>`);break}case"embed":{const a=n.embed?.(e.source,t.embeds);t.embeds++;const r=/^<\s*([A-Za-z][\w.]*)/.exec(e.source.trim())?.[1];o.push(a===void 0?`<div class="embed"${g(e,t)} data-embed>${f(r??"")}</div>`:`<div${g(e,t)}>${a}</div>`);break}case"source":case"comment":break}}return o.join(`
|
|
3
|
+
`)}function ce(i,n=""){const{list:t,style:o}=i.sources;return t.length===0?"":`<section class="sources" data-style="${o}"${n}><ol>${t.map(s=>`<li id="source-${f(s.item.id)}">${s.pieces.map(e=>e.italic?`<i>${f(e.text)}</i>`:f(e.text)).join("")}</li>`).join("")}</ol></section>`}const I=i=>i===void 0?"":` id="${f(i)}"`;function ut(i,n,t,o=1){if(o===1&&!i.some(d=>d.type==="pagebreak"&&(d.columns!==void 0||d.continuous===!0)))return b(i,n,t);const s=[];let e=[],a=o;const r=d=>{const c=b(e,n,t);s.push(a>1?`<div class="columns-section" style="column-count:${String(a)};column-gap:2em${d?"":";column-fill:auto"}">${c}</div>`:c),e=[]};for(const d of i){if(d.type==="pagebreak"&&(d.columns!==void 0||d.continuous===!0)){r(d.continuous===!0),d.continuous!==!0&&s.push(`<div class="page-break"${g(d,t)}></div>`),a=d.columns??1;continue}e.push(d)}return r(!1),s.join(`
|
|
4
|
+
`)}function fe(i,n){const t=n.headingNumbers.get(i);return t===void 0?"":`<span class="heading-number">${f(t)}</span> `}function gt(i,n){const t=i.levels??3,o=n.headings.filter(r=>r.block.level<=t),s=Math.min(...o.map(r=>r.block.level)),e=o.map(({block:r,anchor:d})=>{const c=n.headingPage?.(d);return`<li style="padding-left:${String(r.level-s)}em"><a href="#${f(d)}"><span class="toc-words">${fe(r,n)}${E(r.content,n)}</span>${c===void 0?"":`<span class="toc-fill"></span><span class="toc-page">${String(c)}</span>`}</a></li>`}),a=je(i,n.chinese);return`<nav class="toc"${g(i,n)}>${a===""?"":`<p class="toc-title">${f(a)}</p>`}<ol>${e.join("")}</ol></nav>`}export function keptWhole(i,n,t=0){const o=.35277777777777775,s="pt"in n.lineHeight?n.lineHeight.pt:n.lineHeight.multiple*(L[n.font]??1.22)*n.size,e=Math.max(20,(n.textWidth/o-30)/(n.size*.5)),a=r=>r.reduce((d,c)=>{if(c.type==="table")return d+c.rows.length*1.6+1;if(c.type==="chart"||c.type==="image"||c.type==="component")return d+18;if(c.type==="card")return d+2+a(c.children??[]);const l="content"in c?Math.max(1,Math.ceil(c.content.map(h=>h.text).join("").length/e))+.5:2;return d+l+a(Ge(c))},0);return(t+a(i))*s<n.textHeight/o*.6}export const cardKept=(i,n)=>keptWhole(i.children??[],n,2),columnsKept=(i,n)=>i.columns.every(t=>keptWhole(t.blocks,n));function Z(i){const n=i.mark;if(n===void 0)return"";const t=n.kind==="inserted"?"ins":"del",o=n.date===void 0?"":`, ${n.date}`;return`<${t} class="rev rev-mark" title="${f(`${n.author}${o}`)}">¶</${t}>`}const ht=240,ue=10,mt=15;export function trendSvg(i,n){const s=Math.min(...i),a=Math.max(...i)-s||1,d=i.map((c,l)=>[l/Math.max(1,i.length-1)*100,22-(c-s)/a*20]).map(([c,l],h)=>`${h===0?"M":"L"}${(c??0).toFixed(1)} ${(l??0).toFixed(1)}`).join(" ");return`<svg class="stat-trend" viewBox="0 0 ${String(100)} ${String(24)}" preserveAspectRatio="none" aria-hidden="true"><path d="${d}" fill="none" stroke="${n}" stroke-width="1.5" vector-effect="non-scaling-stroke" stroke-linejoin="round" stroke-linecap="round"/></svg>`}function pt(i,n,t=""){if(i.language===oe.math)return`<div class="math"${t}>${_e(i.code).html}</div>`;if(i.language===oe.mermaid){const o=n.diagram?.(i.code);if(o?.svg!==void 0)return`<figure class="diagram"${t}>${o.svg}</figure>`;if(o?.error!==void 0)return`<pre${t}><code>${f(i.code)}</code></pre><p class="drawn-error">Mermaid: ${f(o.error)}</p>`}return`<pre${t}><code>${$t(i.code)}</code></pre>`}const $t=i=>i.split(`
|
|
5
|
+
`).map(n=>`<span class="line">${f(n)}</span>`).join(""),Q=(i,n,t)=>i?.length?`<div class="under">${b(i,n,t)}</div>`:"";export const DOC_CSS=`
|
|
5
6
|
/* The page's side margins are the text column's own padding, so a cover
|
|
6
7
|
can reach the page's edges. The default page is Letter (PAGE_DEFAULTS). */
|
|
7
8
|
@page { size: 215.9mm 279.4mm; margin: 18mm 0; }
|
|
8
9
|
* { box-sizing: border-box; }
|
|
9
10
|
html { font-size: 11pt; }
|
|
10
|
-
body { margin: 0; color: ${
|
|
11
|
+
body { margin: 0; color: ${u.ink}; font-family: Carlito, Calibri, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif; line-height: 1.4; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
|
|
11
12
|
main { max-width: 215.9mm; margin: 0 auto; padding: 0 20mm; overflow-x: clip; }
|
|
13
|
+
main, article { isolation: isolate; }
|
|
14
|
+
figure.over { position: relative; height: 0; margin: 0; }
|
|
15
|
+
figure.over > img { position: absolute; max-width: none; }
|
|
12
16
|
/* Every block's space and step in is the page's (pageCss, from BlockSpacing). */
|
|
13
17
|
h1, h2, h3, h4, h5, h6 { line-height: inherit; margin: 0; break-after: avoid; }
|
|
14
18
|
h1, .toc-title { font-size: 1.75em; }
|
|
@@ -19,18 +23,24 @@ h2 { font-size: 1.45em; }
|
|
|
19
23
|
.toc-title { font-weight: bold; line-height: inherit; break-after: avoid; }
|
|
20
24
|
h3 { font-size: 1.15em; }
|
|
21
25
|
h4, h5, h6 { font-size: 1em; }
|
|
22
|
-
h5 { color: ${
|
|
23
|
-
h6 { color: ${
|
|
26
|
+
h5 { color: ${u.lead}; }
|
|
27
|
+
h6 { color: ${u.leadSoft}; font-weight: 500; }
|
|
24
28
|
p, ul, ol, li { margin: 0; }
|
|
25
29
|
ul, ol { padding-left: 0; }
|
|
26
30
|
/* A task as the editor draws it: a box, ticked and the words struck when done. */
|
|
27
31
|
li.task { list-style: none; }
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
/* A cell of blocks: its first block flush with its top, its last with its foot. */
|
|
33
|
+
.cell-blocks > :first-child { margin-top: 0; }
|
|
34
|
+
.cell-blocks > :last-child { margin-bottom: 0; }
|
|
35
|
+
/* A list item's mark as Word's multilevel list sets it (lists). */
|
|
36
|
+
li[data-mark]::marker { content: attr(data-mark) "\\a0\\a0"; }
|
|
37
|
+
li.task .box { display: inline-block; width: 0.95em; height: 0.95em; margin-right: 0.55em; border: 1.5px solid ${u.ruleStrong}; border-radius: 3px; vertical-align: -0.14em; }
|
|
38
|
+
li.task .box.done { border-color: ${u.ink}; background: ${u.ink} url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 6.2l2.3 2.3 4.7-4.9' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 85% no-repeat; }
|
|
39
|
+
li.task.done > .words { color: ${u.leadSoft}; text-decoration: line-through; text-decoration-color: ${u.ruleStrong}; }
|
|
40
|
+
blockquote { margin: 0; border-left: var(--quote-rule, 1px) solid ${u.ruleStrong}; color: ${u.lead}; }
|
|
41
|
+
code { font-family: Cousine, "Courier New", monospace; font-size: 0.88em; background: ${u.stone2}; border-radius: 3px; padding: 0.12em 0.34em; }
|
|
42
|
+
.tab { white-space: pre; tab-size: ${String(TAB_STOP_PT)}pt; }
|
|
43
|
+
pre { margin: 0; font-family: Cousine, "Courier New", monospace; background: ${u.stone}; border: 0.5pt solid ${u.stone}; border-radius: 6px; white-space: pre-wrap; overflow-wrap: anywhere; break-inside: avoid; }
|
|
34
44
|
pre code { background: none; padding: 0; }
|
|
35
45
|
pre .line { display: block; min-height: 1lh; padding-left: 2ch; text-indent: -2ch; }
|
|
36
46
|
/* Tables as the editor sets them, a report's three rules (booktabs): a
|
|
@@ -38,65 +48,88 @@ pre .line { display: block; min-height: 1lh; padding-left: 2ch; text-indent: -2c
|
|
|
38
48
|
by lines, no lines between columns; laid
|
|
39
49
|
out as Word lays them, each column as wide as it is set, the rest shared. */
|
|
40
50
|
table { border-collapse: collapse; width: 100%; table-layout: fixed; }
|
|
41
|
-
th, td { border: 0; border-bottom: 0.5pt solid ${
|
|
42
|
-
table > thead > tr:first-child > *, table:not(:has(> thead)) > tbody > tr:first-child > * { border-top: 1pt solid ${
|
|
43
|
-
table > tbody > tr:last-child > * { border-bottom: 1pt solid ${
|
|
51
|
+
th, td { border: 0; border-bottom: 0.5pt solid ${u.ruleMid}; text-align: left; vertical-align: top; }
|
|
52
|
+
table > thead > tr:first-child > *, table:not(:has(> thead)) > tbody > tr:first-child > * { border-top: 1pt solid ${u.ruleStrong}; }
|
|
53
|
+
table > tbody > tr:last-child > * { border-bottom: 1pt solid ${u.ruleStrong}; }
|
|
44
54
|
th { font-weight: 600; }
|
|
45
|
-
thead th { border-bottom: 0.75pt solid ${
|
|
55
|
+
thead th { border-bottom: 0.75pt solid ${u.ruleStrong}; background: ${u.stone3}; }
|
|
46
56
|
th.num, td.num { text-align: right; }
|
|
47
57
|
figure { break-inside: avoid; }
|
|
48
58
|
img { max-width: 100%; }
|
|
49
|
-
figcaption { color: ${
|
|
50
|
-
|
|
51
|
-
|
|
59
|
+
figcaption { color: ${u.leadSoft}; }
|
|
60
|
+
ins.rev, .rev-inserted { color: #1F5FA8; text-decoration: underline; }
|
|
61
|
+
del.rev, .rev-deleted { color: #B3362C; text-decoration: line-through; }
|
|
62
|
+
/* Moved words, as Word marks a move: green, struck twice where they were, underlined twice where they went. */
|
|
63
|
+
.rev.rev-moved { color: #2E7D32; text-decoration-style: double; }
|
|
64
|
+
/* A change of formatting: its words as they look now, a dotted line under them, as Word's markup marks one. */
|
|
65
|
+
.rev-formatted { text-decoration: underline dotted #1F5FA8; text-underline-offset: 0.2em; }
|
|
66
|
+
.rev-changed { position: relative; }
|
|
67
|
+
.rev-changed::before { content: ""; position: absolute; left: -3mm; top: 0; bottom: 0; border-left: 0.75pt solid #1F5FA8; }
|
|
68
|
+
.rev-inserted *, .rev-deleted * { color: inherit; }
|
|
69
|
+
hr { box-sizing: content-box; border: 0; border-bottom: 0.5pt solid ${u.rule}; }
|
|
70
|
+
/* Underlined spaces are a blank to fill in, as Word draws them: kept in the line, never hanging past its end. */
|
|
71
|
+
u { white-space: break-spaces; }
|
|
72
|
+
a { color: inherit; text-decoration: underline; text-decoration-color: ${u.ruleStrong}; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
|
|
52
73
|
/* A callout's sign in a column of its own, as wide as Word's cell for it. */
|
|
53
74
|
/* A card: blocks in a hairline border under a title and a quieter line. */
|
|
54
|
-
.card { border: 0.5pt solid ${
|
|
75
|
+
.card { border: 0.5pt solid ${u.rule}; border-radius: 8px; background: ${u.sheet}; }
|
|
55
76
|
.card.kept, .columns.kept { break-inside: avoid; }
|
|
56
77
|
.card-head p { margin: 0; }
|
|
57
78
|
.card-title { font-weight: 700; }
|
|
58
|
-
.card-subtitle { color: ${
|
|
79
|
+
.card-subtitle { color: ${u.lead}; }
|
|
59
80
|
/* Figures side by side: each a label over its value, how it moved under it. */
|
|
60
81
|
.stats { display: grid; break-inside: avoid; }
|
|
61
|
-
.stat { border: 0.5pt solid ${
|
|
82
|
+
.stat { border: 0.5pt solid ${u.rule}; border-radius: 8px; background: ${u.sheet}; }
|
|
62
83
|
.stat p { margin: 0; }
|
|
63
|
-
.stat-label, .stat-foot { color: ${
|
|
64
|
-
.stat-value { font-weight: 700; color: ${
|
|
84
|
+
.stat-label, .stat-foot { color: ${u.lead}; }
|
|
85
|
+
.stat-value { font-weight: 700; color: ${u.ink}; }
|
|
65
86
|
.stat-trend { display: block; width: 100%; height: 18pt; margin-top: 3pt; }
|
|
66
87
|
/* A tag: a word or two in a pill of its colour. */
|
|
67
88
|
.tag { border-radius: 999px; padding: 0 0.4em; font-size: 0.85em; }
|
|
68
|
-
.callout { display: flex; border-radius: 6px; background: ${
|
|
89
|
+
.callout { display: flex; border-radius: 6px; background: ${u.stone}; break-inside: avoid; }
|
|
69
90
|
.callout-icon { flex: none; width: 1.8em; }
|
|
70
91
|
.callout > div { flex: 1; min-width: 0; }
|
|
71
|
-
.embed { border: 1px dashed ${
|
|
92
|
+
.embed { border: 1px dashed ${u.ruleMid}; border-radius: 6px; padding: 1.5em; text-align: center; color: ${u.leadSoft}; break-inside: avoid; }
|
|
72
93
|
/* A cover: a band of a picture across the top of the first page, edge to
|
|
73
94
|
edge (Notion's). */
|
|
74
|
-
.cover { height: ${String(
|
|
95
|
+
.cover { height: ${String(De)}mm; margin: 0 -20mm 2.4em; overflow: hidden; break-inside: avoid; }
|
|
75
96
|
.cover img { display: block; width: 100%; height: 100%; max-width: none; object-fit: cover; }
|
|
76
97
|
/* A footnote's mark, and the notes at the end under a short rule. */
|
|
77
98
|
sup.fn { font-size: 0.72em; line-height: 0; margin-left: 0.02em; font-variant-numeric: tabular-nums; }
|
|
78
|
-
sup.fn a { text-decoration: none; color: ${
|
|
79
|
-
.notes { margin-top: 2.5em; padding-top: 0.8em; border-top: 1px solid ${
|
|
99
|
+
sup.fn a { text-decoration: none; color: ${u.lead}; }
|
|
100
|
+
.notes { margin-top: 2.5em; padding-top: 0.8em; border-top: 1px solid ${u.rule}; width: 100%; font-size: 0.85em; color: ${u.lead}; }
|
|
80
101
|
.notes ol { padding-left: 1.6em; margin: 0; }
|
|
81
102
|
.notes li { margin: 0.25em 0; }
|
|
82
103
|
.notes li p { margin: 0; }
|
|
83
104
|
.page-break { break-after: page; height: 0; }
|
|
84
105
|
/* A mark set half wide at a line's end, as Word squeezes it (GRID_SQUEEZE). */
|
|
85
106
|
.squeezed { letter-spacing: -0.5em; }
|
|
86
|
-
caption { caption-side: top; text-align: left; color: ${
|
|
107
|
+
caption { caption-side: top; text-align: left; color: ${u.leadSoft}; }
|
|
87
108
|
/* The contents: each heading a link, its page after a line of dots. */
|
|
88
109
|
.toc ol { list-style: none; padding: 0; }
|
|
89
110
|
.toc a { display: flex; align-items: baseline; gap: 0.4em; color: inherit; text-decoration: none; }
|
|
90
|
-
.toc-fill { flex: 1; min-width: 1em; border-bottom: 1px dotted ${
|
|
111
|
+
.toc-fill { flex: 1; min-width: 1em; border-bottom: 1px dotted ${u.ruleMid}; }
|
|
91
112
|
.toc-page { font-variant-numeric: tabular-nums; }
|
|
92
113
|
/* Citations and the list of sources: numbered with a hanging number (GB/T 7714), or by author with a hanging line (APA, MLA) as deep as a paragraph's first line is set in (--hang). */
|
|
93
114
|
a.cite { color: inherit; text-decoration: none; }
|
|
94
115
|
.sources ol { list-style: none; padding-left: 0; }
|
|
95
116
|
.sources li { text-align: left; text-indent: calc(-1 * var(--hang, 2em)); padding-left: var(--hang, 2em); }
|
|
96
117
|
.sources[data-style="gbt7714"] li { --hang: 2.2em; }
|
|
97
|
-
.columns { display: grid; gap: 0 ${String(
|
|
118
|
+
.columns { display: grid; gap: 0 ${String(ye)}px; }
|
|
98
119
|
.column { min-width: 0; }
|
|
99
120
|
.column > :first-child, .callout > div > :first-child { margin-top: 0; }
|
|
121
|
+
figure.block { margin: 0 0 var(--after, 0.7em); }
|
|
122
|
+
.stats > svg { display: block; width: 100%; height: auto; }
|
|
123
|
+
/* A library picture's outer rules sit on its edge, inside it; its edge is snapped to the device's pixels, so what it clips there would cut them. */
|
|
124
|
+
.stats > svg, figure.block > svg { overflow: visible; }
|
|
125
|
+
.callout-icon svg.icon, .card-icon svg.icon { vertical-align: -0.2em; }
|
|
126
|
+
.card-tag { float: right; margin-left: 0.6em; }
|
|
127
|
+
/* A text box, Word's: a hairline round its blocks, its inside Word's (3.6 pt, 7.2 pt). */
|
|
128
|
+
.textbox { border: 0.75pt solid ${u.rule}; padding: 3.6pt 7.2pt; box-sizing: border-box; break-inside: avoid; }
|
|
129
|
+
.textbox > :first-child { margin-top: 0; }
|
|
130
|
+
.textbox > :last-child { margin-bottom: 0; }
|
|
131
|
+
.card.featured .card-subtitle { color: inherit; opacity: 0.85; }
|
|
132
|
+
figure.block svg { display: block; width: 100%; height: auto; }
|
|
100
133
|
figure.chart { margin-left: auto; margin-right: auto; }
|
|
101
134
|
figure.chart, figure.diagram { text-align: center; }
|
|
102
135
|
/* A picture a line as high as it, as Word sets a line of a picture alone. */
|
|
@@ -110,10 +143,10 @@ figure.chart svg, figure.diagram svg { display: inline-block; max-width: 100%; h
|
|
|
110
143
|
a row never split, a table's head again on each page. */
|
|
111
144
|
p, li { orphans: 2; widows: 2; }
|
|
112
145
|
tr { break-inside: avoid; }
|
|
113
|
-
`;function
|
|
114
|
-
`)}export function
|
|
115
|
-
window.allyhubReady = ${
|
|
116
|
-
<\/script>`,
|
|
146
|
+
`;function bt(i,n,t){const o=[...U(i)].filter(a=>a.type==="note");return o.length===0?"":`<section class="notes"><ol>${o.map(a=>({note:a,n:t.notes.get(a.label.toLowerCase())})).sort((a,r)=>(a.n??1/0)-(r.n??1/0)).map(({note:a,n:r})=>`<li${g(a,t)}${r===void 0?"":` id="note-${String(r)}" value="${String(r)}"`}><p>${E(a.content,t)}</p>${b(a.children??[],n,t)}</li>`).join("")}</ol></section>`}const J="body > h1:first-child, main > h1:first-child, article > h1:first-child, main > .cover + h1",k=i=>`${String(Math.round(i*100)/100)}mm`,m=i=>String(Math.round(i*1e3)/1e3);function xt(i){const n=i.spacing,t=a=>`${m(a)}pt`,o=t(n.after),s=t(n.step),e="pt"in i.lineHeight?t(i.lineHeight.pt):m(i.lineHeight.multiple*(L.mono??1));return[`p, ul, ol, blockquote, pre, table, figure, .math, .callout, .card, .stats, .embed, .sources li { margin: 0 0 ${o}; }`,`h1, h2, h3, h4, h5, h6 { margin: ${t(n.heading.before)} 0 ${t(n.heading.after)}; }`,`.toc-title { margin: ${t(n.heading.before)} 0 ${t(n.heading.after)}; }`,`${J} { margin-top: 0; margin-bottom: ${t(n.title)}; }`,`ul, ol { padding-left: ${s}; } li ul, li ol { margin-bottom: 0; } li.task { margin-left: -${s}; } .under { margin-left: ${s}; }`,`:is(ul, ol) + :is(ul, ol) { margin-top: -${o}; }`,`blockquote { padding-left: calc(${t(n.quote)} - var(--quote-rule, 1px)); }`,`pre { padding: ${t(n.box.top)} ${t(n.box.side)}; font-size: ${t(n.small)}; line-height: ${e}; } pre code { font-size: inherit; }`,`.callout { padding: ${t(n.box.top)} ${t(n.box.side)} ${t(Math.max(n.box.top-n.after,0))}; }`,`.card { padding: ${t(n.card.top)} ${t(n.card.side)} ${t(Math.max(n.card.top-n.after,0))}; } .card-head { margin-bottom: ${o}; } .card-subtitle { font-size: ${t(n.small)}; }`,`.stats { gap: ${t(n.gap)}; } .stat { padding: ${t(n.card.top)} ${t(n.card.side)}; } .stat-label, .stat-foot { font-size: ${t(n.small)}; } .stat-value { font-size: ${t(n.figure)}; line-height: ${m(L[i.font]??L.sans??1.22)}; }`,`table { font-size: ${t(n.small)}; } th, td { padding: ${t(n.cell.top)} ${t(n.cell.side)}; }`,`caption { font-size: ${t(n.small)}; padding-bottom: ${t(n.caption)}; }`,`figcaption { font-size: ${t(n.small)}; margin-top: ${t(n.caption)}; }`,`hr { height: 1pt; margin: ${t(n.divider)} 0; }`,`.toc ol { margin: 0; } .toc li { margin: 0 0 ${t(n.contents)}; } .sources ol { margin: 0; }`]}function ge(i,n,t){if(n===void 0)return;const o=[n.font===void 0?"":`font-family: ${PAGE_FACES[t.font]};`,n.size===void 0?"":`font-size: ${m(t.size)}pt;`,t.font==="xiaobiaosong"?"font-weight: 700;":n.weight===void 0?"":`font-weight: ${t.weight==="bold"?"700":"400"};`,n.align===void 0?"":`text-align: ${t.align};`,n.italic===void 0?"":`font-style: ${t.italic?"italic":"normal"};`,t.rule?`border-bottom: 0.5pt solid ${u.rule}; padding-bottom: ${m(HEADING_RULE_SPACE)}pt;`:""].join(" ");return o.trim()===""?void 0:`${i} { ${o.trim()} }`}export function titleHeadingCss(i,n){const t=H(i),o=T(i);return[ge(n.title,t.title,o.title),...[1,2,3,4,5,6].map(s=>ge(n.heading(s),t.headings?.[s],o.headings[s]))].filter(s=>s!==void 0)}export const HEADING_RULE_SPACE=3;export function pageCss(i={}){const n=H(i),t=T(i),o=pageFaces(i),s=pageAccent(n),e=[];if(n.paper!==void 0||n.orientation!==void 0||n.margins!==void 0||n.header!==void 0||n.footer!==void 0){const{top:a,right:r,bottom:d,left:c}=t.margins;e.push(`@page { size: ${k(t.width)} ${k(t.height)}; margin: ${k(a)} 0 ${k(d)}; }`,`main { max-width: ${k(t.width)}; padding: 0 ${k(r)} 0 ${k(c)}; }`,`.cover { margin-left: -${k(c)}; margin-right: -${k(r)}; }`)}return n.font!==void 0&&n.font!=="sans"&&e.push(`body { font-family: ${o.text}; }`,`h1, h2, h3, h4, h5, h6 { font-family: ${o.heading}; }`,`.toc-title { font-family: ${o.heading}; }`),(n.size!==void 0||n.grid!==void 0)&&e.push(`html { font-size: ${m(t.size)}pt; }`),e.push(`body { line-height: ${"pt"in t.lineHeight?`${m(t.lineHeight.pt)}pt`:m(Ke(t)??1)}; }`),e.push(...xt(t)),t.letterSpacing!==0&&e.push(`body { letter-spacing: ${m(t.letterSpacing)}em; }`),n.textIndent!==void 0&&n.textIndent>0&&e.push(`.sources { --hang: ${m(n.textIndent)}em; }`,`p { text-indent: ${m(n.textIndent)}em; }`,"blockquote p, .callout p, .notes p, .toc p { text-indent: 0; }"),n.textAlign==="justify"&&e.push("p, li { text-align: justify; }"),e.push(...titleHeadingCss(i,{title:J,heading:a=>a===1?"h1, .toc-title":`h${String(a)}`})),s!==void 0&&e.push(`a { color: ${s}; text-decoration-color: color-mix(in oklab, ${s} 45%, transparent); }`,`blockquote { --quote-rule: 2px; border-left-color: ${s}; }`),e.push(...stylesCss(i.styles)),e.join(`
|
|
147
|
+
`)}const kt={[at]:"p, li",[ot]:"li",[rt]:"blockquote",[it]:"figcaption, .caption",[st]:J,...Object.fromEntries([1,2,3,4,5,6].map(i=>[dt(i),`h${String(i)}`]))};export function stylesCss(i){const n=Object.hasOwn(i??{},Y)?[]:he(Y,de(i,Y));return i===void 0?n:[...n,...Object.entries(i).flatMap(([t,o])=>{if(o.type==="table")return he(t,de(i,t));const s=propsCss(ct(i,t));return s===""?[]:[`${kt[t]??`.${o.type==="character"?"cs":"ps"}-${_(t)}`} { ${s} }`]})]}export function tableLookCss(i,n){const t=r=>A(r,D)??r,o=`0.5pt solid ${t(i.borderColor??u.ruleMid)}`,s=i.borders==="all"?`${n.cells} { border: ${o}; }`:i.borders==="rows"?`${n.cells} { border: 0; border-bottom: ${o}; } ${n.first} { border-top: ${o}; }`:i.borders==="outside"?`${n.cells} { border: 0; } ${n.table} { border: ${o}; }`:i.borders==="none"?`${n.cells} { border: 0; }`:"",e=`${n.head} { background: ${i.headBg===void 0?"none":A(i.headBg,R)??i.headBg};${i.headColor===void 0?"":` color: ${t(i.headColor)};`} font-weight: ${i.headBold===!0?"600":"400"}; }`,a=i.banded===void 0?"":`${n.band} { background: ${A(i.banded,R)??i.banded}; }`;return[s,e,a].filter(r=>r!=="")}function he(i,n){const t=_(i),o=`table.ts-${t}.ts-${t}`;return tableLookCss(n,{table:o,cells:`${o} > * > tr > *`,head:`${o} > thead > tr > th`,band:`${o} > tbody > tr:nth-child(odd) > *`,first:`${o} > :first-child > tr:first-child > *`})}export function partLook(i,n){return{...i,...n.margins===void 0?{}:{margins:n.margins},...n.header===void 0?{}:{header:n.header},...n.footer===void 0?{}:{footer:n.footer}}}export function docParts(i){const n=[];let t=[],o=!1,s,e,a,r=[],d;const c=()=>{n.push({blocks:t,landscape:o,...d===void 0?{}:{columns:d},...s===void 0?{}:{margins:s},...e===void 0?{}:{header:e},...a===void 0?{}:{footer:a},...r.length>0?{opens:r}:{}})};for(const l of i)l.type==="pagebreak"&&(l.orientation!==void 0||l.margins!==void 0||l.header!==void 0||l.footer!==void 0)?(c(),t=[],r=[],d=l.columns,l.orientation!==void 0&&(o=l.orientation==="landscape"),l.margins!==void 0&&(s=l.margins),l.header!==void 0&&(e=l.header,r.push("header")),l.footer!==void 0&&(a=l.footer,r.push("footer"))):t.push(l);return c(),n}const wt=`<script>
|
|
148
|
+
window.allyhubReady = ${ve({scope:"main",face:"Noto Color Emoji"})};
|
|
149
|
+
<\/script>`,vt=`<script>
|
|
117
150
|
window.allyhubReady = (async (before) => {
|
|
118
151
|
await before;
|
|
119
152
|
await document.fonts.ready;
|
|
@@ -129,7 +162,7 @@ window.allyhubReady = (async (before) => {
|
|
|
129
162
|
if (el.matches("p") || el.children.length === el.querySelectorAll(":scope > .words, :scope > .box").length)
|
|
130
163
|
if (lines(el) < 4) el.style.breakInside = "avoid";
|
|
131
164
|
})(window.allyhubReady);
|
|
132
|
-
<\/script>`,
|
|
165
|
+
<\/script>`,St=`<script>
|
|
133
166
|
window.allyhubReady = (async (before) => {
|
|
134
167
|
await before;
|
|
135
168
|
await document.fonts.ready;
|
|
@@ -214,24 +247,26 @@ window.allyhubReady = (async (before) => {
|
|
|
214
247
|
}
|
|
215
248
|
}
|
|
216
249
|
})(window.allyhubReady);
|
|
217
|
-
<\/script>`;
|
|
218
|
-
`}
|
|
250
|
+
<\/script>`;function me(i,n){const t=headingAnchors(i),o=Me(i,n.page),{title:s}=qe(i),e=new Map,a=[];for(const r of U(i)){const d=ze(r),c=o.get(r);if(d!==void 0&&c!==void 0&&e.set(d,c.label),r.type==="heading"){const l=t.get(r)??"";e.set(l,r.content.map(h=>h.text).join("")),r!==s&&a.push({block:r,anchor:l})}}return{embeds:0,notes:Ue(i),anchors:t,ids:n.ids?blockNumbers(i):void 0,numbers:o,refs:e,headings:a,headingNumbers:Je(i,n.page?.styles),headingPage:n.headingPage,chinese:Fe(i),sources:(()=>{const r=H(n.page??{}).citationStyle??"apa",d=n.sources??[],c=Ee(i,d,r);return{items:d,style:r,numbers:new Map(c.map(l=>[l.item.id,l.n])),list:c}})(),listed:!1,listCounts:[]}}export function blocksHtml(i,n={}){return b(i,n,me(i,n))}export function watermarkSvg(i,n,t){const o=i.watermark;if(o===void 0)return;const s=T(i),e=s.width,a=s.height,{top:r,left:d}=s.margins,c=s.textWidth,l=s.textHeight,h=d+c/2,$=r+l/2,p=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${String(e)} ${String(a)}" width="100%" height="100%" preserveAspectRatio="xMidYMid meet">`;if("picture"in o){if(n===void 0||t===void 0)return;const M=t.width/96*25.4,B=t.height/96*25.4,W=o.scale===void 0?Math.min(1,c/M,l/B):o.scale/100,P=M*W,q=B*W;return`${p}<image href="${f(n)}" x="${String(h-P/2)}" y="${String($-q/2)}" width="${String(P)}" height="${String(q)}"${o.washout===!0?` opacity="${String(se)}"`:""}/></svg>`}const x=o.layout!=="horizontal",v=x?Math.hypot(c,l)*.8:c*.9;let S=0;for(const M of o.text)S+=/[\u2E80-\u9FFF\uAC00-\uD7AF\uF900-\uFAFF\uFF00-\uFFEF]/u.test(M)?1:M===" "?.3:.62;const z=Math.min(v/Math.max(1,S),l/2),K=`font-family:${f(pageFaces({font:o.font??s.font}).text)};`;return`${p}<text x="${String(h)}" y="${String($)}" text-anchor="middle" dominant-baseline="central" font-size="${String(Math.round(z*10)/10)}" style="${K}" fill="${f(o.color??Xe)}" fill-opacity="${String(Ye)}"${x?` transform="rotate(-45 ${String(h)} ${String($)})"`:""}>${f(o.text)}</text></svg>`}function yt(i){const n=i.page??{},t=n.watermark;if(t===void 0)return"";const o=T(n),s=o.textWidth,e=o.textHeight,a="position:fixed;inset:0;z-index:-1;pointer-events:none;display:flex;align-items:center;justify-content:center";if("picture"in t){const r=i.image?.(t.picture)??t.picture,d=t.scale===void 0?`max-width:${String(s)}mm;max-height:${String(e)}mm`:`zoom:${String(t.scale/100)}`;return`<div class="watermark" aria-hidden="true" style="${a}"><img src="${f(r)}" alt="" style="${d};${t.washout===!0?`opacity:${String(se)}`:""}"></div>
|
|
251
|
+
`}return`<div class="watermark" aria-hidden="true" style="${a}">${watermarkSvg(n)??""}</div>
|
|
252
|
+
`}export function docHtml(i,n={}){const t=n.part===void 0?void 0:docParts(i)[n.part],o=t===void 0?n:{...n,page:partLook(n.page??{},t)},s=Pe(i,o),e=me(s,o),a=docParts(s),r=o.part,d=r===void 0?void 0:a[r],c=d===void 0?a.flatMap(z=>z.blocks):d.blocks,l=r===void 0||r===0,h=r===void 0||r===a.length-1,$=l?o.page?.cover:void 0,p=$===void 0?void 0:o.image?.($)??$,x=`${p===void 0?"":`<figure class="cover"><img src="${f(p)}" alt="" style="object-position:50% ${String(o.page?.coverY??50)}%"></figure>
|
|
253
|
+
`}${ut(c,o,e,d?.columns??1)}${h&&!e.listed?ce(e):""}${h?bt(s,o,e):""}`,v=T(o.page),S=[pageCss(o.page),...d?.landscape===!0?[`@page { size: ${k(v.height)} ${k(v.width)}; }`,`main { max-width: ${k(v.height)}; }`]:[],...p===void 0?[]:["@page :first { margin-top: 0; }"]].filter(z=>z!=="").join(`
|
|
219
254
|
`);return`<!doctype html>
|
|
220
255
|
<html>
|
|
221
256
|
<head>
|
|
222
257
|
<meta charset="utf-8">
|
|
223
|
-
<title>${
|
|
224
|
-
${
|
|
225
|
-
`}<style>${DOC_CSS}${
|
|
226
|
-
${
|
|
258
|
+
<title>${f(o.title??"")}</title>
|
|
259
|
+
${o.fonts===void 0?"":`<style>${o.fonts}</style>
|
|
260
|
+
`}<style>${DOC_CSS}${S===""?"":`
|
|
261
|
+
${S}`}</style>
|
|
227
262
|
</head>
|
|
228
263
|
<body>
|
|
229
|
-
<main>
|
|
230
|
-
${
|
|
264
|
+
${yt(o)}<main>
|
|
265
|
+
${x}
|
|
231
266
|
</main>
|
|
232
|
-
${
|
|
233
|
-
${H(
|
|
234
|
-
${
|
|
267
|
+
${wt}
|
|
268
|
+
${H(o.page??{}).grid===void 0?"":St}
|
|
269
|
+
${vt}
|
|
235
270
|
</body>
|
|
236
271
|
</html>
|
|
237
272
|
`}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
-
export{DOC_CSS,EMOJI_PATTERN,PAGE_FACES,blockNumbers,docHtml,docParts,headingAnchors,pageAccent,pageCss,pageFaces,trendSvg}from"./html.js";export{CHART_BARS,ROUND_FRAME,CHART_PALETTE,CHART_SECOND_TONE,CHART_TEXT,SMOOTHED,chartColor,chartFrame,chartTheme,chartWords,docChart,docChartSvg}from"./chart.js";export{COMPONENT_ASPECT,COMPONENT_WIDTH,componentAt,componentDrawing,componentDrawingKey,componentDraws,componentName}from"./component.js";export{COLUMN_GAP,columnWidths}from"./columns.js";export{numberColumns,tableRowsOf,withTableData}from"./table.js";export{CITATION_STYLES,citationText,citedKeys,citedOf,readSources,sourceList,sourceText,sourcePieces,withSources}from"./cite.js";export{blockId,captionNumbers,captionOf,captionWords,contentsTitle,numberedCaption,writtenInChinese}from"./captions.js";export{DRAWN_CODE,mathHtml}from"./math.js";export{DIAGRAM_TEXT_PX,PAPER,TONE_COLORS,diagramConfig,tagColors,tint}from"./paper.js";export{markdownOf,plainBlocks}from"./markdown.js";export*from"./model.js";export{CHINESE_SIZES,PAGE_DEFAULTS,PAGE_KEYS,PAGE_PRESETS,PAPERS,RUNNING_PLACES,effectiveLook,lineHeightPt,lineMultiple,SINGLE_LINE,marginBox,paperSize,presetLook,resolvePage,sizePt}from"./page.js";export{BLOCK_TAG,CALLOUT_TAG,CARD_TAG,STAT_ATTRIBUTES,STAT_TAG,STATS_TAG,TAG_TAG,CHART_ATTRIBUTES,CHART_TAG,COLUMN_TAG,COLUMNS_TAG,PAGE_BREAK_TAG,BIBLIOGRAPHY_TAG,TOC_TAG,COMPONENT_ATTRIBUTES,COMPONENT_TAG,ITEM_TAG,TABLE_TAG,parseDoc}from"./parse.js";export{patchDoc}from"./patch.js";export{isTitle,retitle,splitTitle,titleText,withTitle}from"./title.js";export{frontMatterOf,withPage,writeBlocks}from"./write.js";export{COVER_NAMES,COVER_WORDS,coverFileName,coverSvg}from"./covers.js";
|
|
2
|
+
export{DOC_CSS,EMOJI_PATTERN,PAGE_FACES,blockNumbers,blocksHtml,docHtml,watermarkSvg,docParts,partLook,headingAnchors,TAB_STOP_PT,pageAccent,pageCss,titleHeadingCss,pageFaces,propsCss,stylesCss,tableLookCss,trendSvg}from"./html.js";export{CHART_BARS,ROUND_FRAME,CHART_PALETTE,CHART_SECOND_TONE,CHART_TEXT,SMOOTHED,chartColor,chartFrame,chartTheme,chartWords,docChart,docChartSvg}from"./chart.js";export{COMPONENT_ASPECT,COMPONENT_WIDTH,componentAt,componentDrawing,componentDrawingKey,componentDraws,componentName}from"./component.js";export{COLUMN_GAP,columnWidths}from"./columns.js";export{numberColumns,tableRowsOf,withTableData}from"./table.js";export{CITATION_STYLES,citationText,citedKeys,citedOf,readSources,sourceList,sourceText,sourcePieces,withSources}from"./cite.js";export{blockId,captionNumbers,captionOf,captionWords,contentsTitle,numberedCaption,withoutTitle,writtenInChinese}from"./captions.js";export{DRAWN_CODE,mathHtml}from"./math.js";export{DIAGRAM_TEXT_PX,PAPER,TONE_COLORS,diagramConfig,tagColors,tint}from"./paper.js";export{markdownOf,plainBlocks}from"./markdown.js";export*from"./model.js";export{alignAt,alignsOf,cellSpans,CELL_VALIGNS,columnLetters,readAligns,readMerges,writeAligns,writeMerges}from"./merges.js";export{hasRevisions,settleBlocks,settleRuns}from"./revisions.js";export{LIST_BULLETS,LIST_NUMBERING,NUMBER_FORMATS,formatCount,headingNumbers,listNumber,listNumbering,readNumbering}from"./numbering.js";export{BUILT_IN_STYLES,CAPTION_STYLE,LIST_PARAGRAPH,NORMAL,PARAGRAPH_KEYS,QUOTE_STYLE,RUN_KEYS,TITLE_STYLE,headingStyle,isCharacterStyle,pickProps,propKeys,propsOf,readFontSize,readStyles,resolveStyle,resolveTableStyle,renameStyle,isTableStyle,TABLE_GRID,styleId,styleKnown,writtenStyle}from"./styles.js";export{REDLINE_ALIKE,likeness,redline,runsAgainst}from"./redline.js";export{CHINESE_SIZES,PAGE_DEFAULTS,PAGE_KEYS,PAGE_PRESETS,PAPERS,RUNNING_EDGE,RUNNING_PICTURE_HEIGHT,runningGap,runningTall,RUNNING_PLACES,runningPictures,effectiveLook,lineHeightPt,lineMultiple,SINGLE_LINE,marginBox,paperSize,presetLook,resolvePage,sizePt,withTheme,WATERMARK_COLOR,WATERMARK_OPACITY,WATERMARK_WASHOUT}from"./page.js";export{BLOCK_TAG,CALLOUT_TAG,CARD_TAG,TEXT_BOX_TAG,STAT_ATTRIBUTES,STAT_TAG,STATS_TAG,TAG_TAG,CHART_ATTRIBUTES,CHART_TAG,COLUMN_TAG,COLUMNS_TAG,PAGE_BREAK_TAG,BIBLIOGRAPHY_TAG,TOC_TAG,COMPONENT_ATTRIBUTES,COMPONENT_TAG,ITEM_TAG,TABLE_TAG,parseDoc}from"./parse.js";export{patchDoc}from"./patch.js";export{isTitle,retitle,splitTitle,titleText,withTitle}from"./title.js";export{frontMatterOf,withPage,writeBlocks}from"./write.js";export{COVER_NAMES,COVER_WORDS,coverFileName,coverSvg}from"./covers.js";export*from"./blocks.js";export{isExtended}from"@allyhub/chart";
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
-
import{withSources as f}from"./cite.js";import{docChart as
|
|
2
|
+
import{withSources as f}from"./cite.js";import{docChart as m}from"./chart.js";import{withTableData as y}from"./table.js";import{settleBlocks as h}from"./revisions.js";import{libraryBlockSvg as g,libraryBlockTable as x}from"./blocks.js";import{writeBlocks as w}from"./write.js";function l(e){const t={};return e.bold&&(t.bold=!0),e.italic&&(t.italic=!0),e.strike&&(t.strike=!0),e.code&&(t.code=!0),t}const o=e=>e.map(t=>t.note!==void 0?{text:t.text,styles:{},note:t.note}:t.href===void 0?{text:t.text,styles:l(t.styles)}:{text:t.text,href:t.href,styles:l(t.styles)});function v(e,t){switch(e.type){case"embed":case"source":case"comment":return[];case"component":{const n=t.component?.(e);return n===void 0?[]:[{type:"image",src:n,...e.alt===void 0?{}:{alt:e.alt},...e.caption===void 0?{}:{caption:e.caption}}]}case"block":{const{alt:n,problems:i}=g(e,600,t),c=n??i.join("; "),a=t.block?.(e),d=x(e,t);return[...a===void 0?[{type:"paragraph",content:[{text:c,styles:{}}]}]:[{type:"image",src:a,alt:c}],...d?plainBlocks([d],t):[]]}case"code":case"divider":return[e];case"pagebreak":case"toc":return[];case"bibliography":return[];case"columns":return e.columns.flatMap(n=>plainBlocks(n.blocks,t));case"card":{const n=[...e.title===void 0?[]:[{text:e.title,styles:{bold:!0}}],...e.subtitle===void 0?[]:[{text:`${e.title===void 0?"":" — "}${e.subtitle}`,styles:{}}]];return[...n.length>0?[{type:"paragraph",content:n}]:[],...plainBlocks(e.children??[],t)]}case"textbox":return plainBlocks(e.children??[],t);case"stats":return e.stats.map(n=>({type:"bullet",content:[{text:n.value,styles:{bold:!0}},{text:` ${n.label}`,styles:{}},...n.delta===void 0&&n.note===void 0?[]:[{text:` (${[n.delta,n.note].filter(i=>i!==void 0).join(" ")})`,styles:{}}]]}));case"chart":{const n=a=>a===""?[]:[{text:a,styles:{}}],i=e.table===void 0?m(e,t).chart:void 0,c=e.table??(i&&i.categories.length>0?[[e.categories??"",...i.series.map(a=>a.name)],...i.categories.map((a,d)=>[a,...i.series.map(p=>{const u=p.values[d];return u==null?"":String(u)})])]:void 0);return c===void 0?[]:[...e.title===void 0?[]:[{type:"paragraph",content:[{text:e.title,styles:{bold:!0}}]}],{type:"table",rows:c.map(a=>a.map(n))}]}case"image":return[{type:"image",src:e.src,...e.alt===void 0?{}:{alt:e.alt},...e.caption===void 0?{}:{caption:e.caption}}];case"table":return[...e.caption===void 0?[]:[{type:"paragraph",content:[{text:e.caption,styles:{bold:!0}}]}],{type:"table",rows:e.rows.map(n=>n.map(o))}];default:break}const r=o(e.content),s=plainBlocks(e.children??[],t);switch(e.type){case"bullet":case"numbered":case"check":case"note":case"quote":{const n={...e};return delete n.look,delete n.children,[{...n,content:r,...s.length?{children:s}:{}}]}case"callout":return[{type:"quote",content:[...e.icon===void 0?[]:[{text:`${e.icon} `,styles:{}}],...r],...s.length?{children:s}:{}}];case"heading":return[{type:"heading",level:e.level,content:r},...s];case"toggle":case"paragraph":return[{type:"paragraph",content:r},...s]}}export function plainBlocks(e,t={}){return e.flatMap(r=>v(r,t))}export function markdownOf(e,t={}){const r=t.page?.cover,s=r===void 0?[]:[{type:"image",src:r}],n=f(y(e,t),t.sources??[],t.page?.citationStyle??"apa");return`${w([...s,...plainBlocks(h(n,"accept"),t)])}
|
|
3
3
|
`}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
export function columnLetters(n){let o=n+1,r="";for(;o>0;){const e=(o-1)%26;r=String.fromCharCode(65+e)+r,o=Math.floor((o-1)/26)}return r}const g=/^([A-Z]{1,3})([1-9]\d{0,4})$/u;export function cellAt(n){const o=g.exec(n.trim().toUpperCase());if(!o)return;let r=0;for(const e of o[1]??"")r=r*26+(e.charCodeAt(0)-64);return{row:Number(o[2])-1,col:r-1}}export function readMerges(n,o,r){const e=[];for(const w of n.split(",")){const t=w.trim();if(t==="")continue;const[c,l]=t.split(":"),f=c===void 0?void 0:cellAt(c),s=l===void 0?void 0:cellAt(l);if(f===void 0||s===void 0){r(`a merge is a range of cells, A1:B2, not "${t}"`);continue}const i={row:Math.min(f.row,s.row),col:Math.min(f.col,s.col),rows:Math.abs(s.row-f.row)+1,cols:Math.abs(s.col-f.col)+1};if(i.rows*i.cols<2){r(`the merge ${t} is one cell`);continue}if(i.row+i.rows>o.rows||i.col+i.cols>o.cols){r(`the merge ${t} runs past the table`);continue}if(e.some(p=>$(p,i))){r(`the merge ${t} is over another`);continue}e.push(i)}return e}const $=(n,o)=>n.row<o.row+o.rows&&o.row<n.row+n.rows&&n.col<o.col+o.cols&&o.col<n.col+n.cols;export const writeMerges=n=>n.map(o=>`${columnLetters(o.col)}${String(o.row+1)}:${columnLetters(o.col+o.cols-1)}${String(o.row+o.rows)}`).join(", ");export function cellSpans(n){return n===void 0||n.length===0?()=>{}:(o,r)=>{for(const e of n){if(e.row===o&&e.col===r)return{rows:e.rows,cols:e.cols};if(o>=e.row&&o<e.row+e.rows&&r>=e.col&&r<e.col+e.cols)return"covered"}}}export const CELL_VALIGNS=["top","center","bottom"];export function readAligns(n,o,r){const e=[];for(const w of n.split(",")){const t=w.trim();if(t==="")continue;const c=t.split(/\s+/u),l=c.at(-1)?.toLowerCase(),f=CELL_VALIGNS.find(h=>h===l);if(f===void 0||c.length>2){r(`a cell's vertical alignment is top, center or bottom, after the cells it is for (A1:B2 center), not "${t}"`);continue}const s=c.length===2?c[0]:void 0;if(s===void 0){e.push({to:f});continue}const[i,p]=s.split(":"),u=i===void 0?void 0:cellAt(i),a=p===void 0?u:cellAt(p);if(u===void 0||a===void 0){r(`cells are named as Excel does, A1 or A1:B2, not "${s}"`);continue}const d={row:Math.min(u.row,a.row),col:Math.min(u.col,a.col),rows:Math.abs(a.row-u.row)+1,cols:Math.abs(a.col-u.col)+1};if(d.row+d.rows>o.rows||d.col+d.cols>o.cols){r(`${s} runs past the table`);continue}e.push({range:d,to:f})}return e}const m=n=>{const o=`${columnLetters(n.col)}${String(n.row+1)}`;return n.rows*n.cols===1?o:`${o}:${columnLetters(n.col+n.cols-1)}${String(n.row+n.rows)}`};export const writeAligns=n=>n.map(o=>o.range===void 0?o.to:`${m(o.range)} ${o.to}`).join(", ");export function alignAt(n,o,r){let e="top";for(const w of n??[]){const t=w.range;(t===void 0||o>=t.row&&o<t.row+t.rows&&r>=t.col&&r<t.col+t.cols)&&(e=w.to)}return e}export function alignsOf(n){const o=new Map;for(const t of n)for(const c of t)o.set(c,(o.get(c)??0)+1);if(o.size===0)return[];const r=[...o].reduce((t,c)=>c[1]>t[1]?c:t)[0],e=r==="top"?[]:[{to:r}],w=n.map(t=>t.map(()=>!1));return n.forEach((t,c)=>{let l=0;for(;l<t.length;){const f=t[l]??"top";if(f===r||w[c]?.[l]===!0){l++;continue}let s=l;for(;s+1<t.length&&t[s+1]===f&&w[c]?.[s+1]!==!0;)s++;let i=1;const p=u=>{const a=n[u];if(a===void 0)return!1;for(let d=l;d<=s;d++)if(a[d]!==f||w[u]?.[d]===!0)return!1;return!0};for(;p(c+i);)i++;for(let u=c;u<c+i;u++)for(let a=l;a<=s;a++){const d=w[u];d!==void 0&&(d[a]=!0)}e.push({range:{row:c,col:l,rows:i,cols:s-l+1},to:f}),l=s+1}}),e}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
-
export function statTone(e){const t=e.delta?.trim().charAt(0),
|
|
2
|
+
import{toneOf as h}from"@allyhub/formats";export const FORMAT_KEYS=["bold","italic","underline","strike","color","background","style","font","size","superscript","subscript","caps","smallCaps","letterSpacing"];export function statTone(e){if(e.status!==void 0){const o=h(e.status);if(o==="good"||o==="bad"||o==="warning"||o==="info")return o;if(o==="neutral")return"flat"}const t=e.delta?.trim().charAt(0),r=t==="+"||t==="↑";return!r&&!(t==="-"||t==="−"||t==="–"||t==="↓")?"flat":r!==(e.downIsGood===!0)?"good":"bad"}export const CHART_LABELS=["value","percentage","category","series"];export{PAGE_FONTS}from"./page.js";export const COVER_HEIGHT_MM=64,COVER_ASPECT=COVER_HEIGHT_MM/210,hasText=e=>"content"in e;const m=["bold","italic","underline","strike"],b=(e,t)=>e.note===void 0&&t.note===void 0&&e.field===void 0&&t.field===void 0&&e.cite===void 0&&t.cite===void 0&&e.href===t.href&&JSON.stringify(d(e.styles))===JSON.stringify(d(t.styles));export function plainEdges(e){const t=[],r=(n,o,s)=>{if(n==="")return;const i={text:n,styles:o,...s===void 0?{}:{href:s}},c=t.at(-1);c&&b(c,i)?c.text+=n:t.push(i)};return e.forEach((n,o)=>{if(n.note!==void 0||n.cite!==void 0||n.field!==void 0||n.text===""&&n.href!==void 0){t.push({...n});return}const{styles:s,href:i}=n,c=!s.code&&i===void 0&&m.some(g=>s[g])?/^(\s*)([\s\S]*?)(\s*)$/u.exec(n.text):null;if(!c){r(n.text,s,i);return}const[,p="",l="",a=""]=c,f={...s};delete f.bold,delete f.italic,delete f.underline,delete f.strike;const y=e[o-1]?.note!==void 0,x=e[o+1]?.note!==void 0;r(p,y?s:f,i),r(l,l===""?f:s,i),r(a,x?s:f,i)}),t}const w=e=>e.length>0&&e.every(t=>t!==null&&typeof t=="object"&&typeof t.text=="string"&&typeof t.styles=="object");function d(e){if(Array.isArray(e))return(w(e)?plainEdges(e):e).map(d);if(e!==null&&typeof e=="object"){const t={};for(const r of Object.keys(e).sort()){const n=e[r];n!==void 0&&(t[r]=d(n))}return t}return e}export const blockKey=e=>JSON.stringify(d(e)),sameBlocks=(e,t)=>e.length===t.length&&e.every((r,n)=>{const o=t[n];return o!==void 0&&blockKey(r)===blockKey(o)}),innerBlocks=e=>e.type==="columns"?e.columns.flatMap(t=>t.blocks):e.type==="table"?Object.values(e.cells??{}).flat():"children"in e?e.children??[]:[];export function*everyBlock(e){for(const t of e)yield t,yield*everyBlock(innerBlocks(t))}export function noteNumbers(e){return u(e).numbers}export function firstNoteMarks(e){return u(e).first}function u(e){const t=new Map,r=new Set,n=new Set([...everyBlock(e)].flatMap(s=>s.type==="note"?[s.label.toLowerCase()]:[])),o=s=>{for(const i of s){const c=i.note?.toLowerCase();c!==void 0&&n.has(c)&&!t.has(c)&&(t.set(c,t.size+1),r.add(i))}};for(const s of everyBlock(e))if(s.type!=="note"&&("content"in s&&o(s.content),s.type==="table"))for(const i of s.rows)for(const c of i)o(c);return{numbers:t,first:r}}export const isHiddenBlock=e=>e.type==="source"||e.type==="comment",shownBlocks=e=>e.filter(t=>!isHiddenBlock(t));export function fieldCodes(e){const t=[],r=n=>{if(Array.isArray(n))for(const o of n)r(o);else if(n!==null&&typeof n=="object"){const o=n;if(typeof o.field=="string"&&typeof o.text=="string")t.push(o.field);else for(const s of Object.values(n))r(s)}};return r(e),t}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
import{everyBlock as a}from"./model.js";import{headingStyle as u}from"./styles.js";import{splitTitle as f}from"./title.js";export const NUMBER_FORMATS={decimal:"decimal","lower-letter":"lowerLetter","upper-letter":"upperLetter","lower-roman":"lowerRoman","upper-roman":"upperRoman",chinese:"chineseCounting",circled:"decimalEnclosedCircle"};export function readNumbering(r,o,t=`a heading ${String(o)}'s numbering`){const e=[];let i=0;for(const n of r.matchAll(/\{(\d)(?::([a-z-]+))?\}/gu)){n.index>i&&e.push(r.slice(i,n.index));const l=Number(n[1]),s=n[2]??"decimal";if(l<1||l>o)return{parts:e,problem:`${t} counts levels 1 to ${String(o)}, not {${String(l)}}`};if(!Object.hasOwn(NUMBER_FORMATS,s))return{parts:e,problem:`a number's format is ${Object.keys(NUMBER_FORMATS).join(", ")}, not ${s}`};e.push({level:l,format:s}),i=n.index+n[0].length}return i<r.length&&e.push(r.slice(i)),e.some(n=>typeof n!="string")?{parts:e}:{parts:e,problem:`${t} counts its level with {${String(o)}}: "${r}" has no count`}}const m="abcdefghijklmnopqrstuvwxyz",p=[[1e3,"m"],[900,"cm"],[500,"d"],[400,"cd"],[100,"c"],[90,"xc"],[50,"l"],[40,"xl"],[10,"x"],[9,"ix"],[5,"v"],[4,"iv"],[1,"i"]],d="〇一二三四五六七八九";function g(r){if(r===0)return"〇";const o=["","十","百","千"],t=String(r).split("").map(Number);let e="",i=!1;return t.forEach((n,l)=>{const s=o[t.length-1-l]??"";if(n===0){i=e!=="";return}i&&(e+="〇"),i=!1,e+=n===1&&s==="十"&&e===""?s:`${d[n]??""}${s}`}),e.replace(/〇/gu,"零")}export function formatCount(r,o){switch(o){case"decimal":return String(r);case"lower-letter":case"upper-letter":{const e=(m[(r-1)%26]??"a").repeat(Math.floor((r-1)/26)+1);return o==="upper-letter"?e.toUpperCase():e}case"lower-roman":case"upper-roman":{let t=r,e="";for(const[i,n]of p)for(;t>=i;)e+=n,t-=i;return o==="upper-roman"?e.toUpperCase():e}case"chinese":return g(r);case"circled":return r>=1&&r<=20?String.fromCodePoint(9311+r):String(r)}}export function headingNumberings(r){const o=new Map;for(const t of[1,2,3,4,5,6]){const e=r?.[u(t)]?.numbering;if(e===void 0)continue;const i=readNumbering(e,t);i.problem===void 0&&o.set(t,i.parts)}return o}export function headingNumbers(r,o){const t=new Map,e=headingNumberings(o);if(e.size===0)return t;const{title:i}=f(r),n=[0,0,0,0,0,0];for(const l of a(r)){if(l.type!=="heading"||l===i||l.look?.style!==void 0)continue;const s=e.get(l.level);if(s!==void 0){n[l.level-1]=(n[l.level-1]??0)+1;for(let c=l.level;c<6;c++)n[c]=0;t.set(l,s.map(c=>typeof c=="string"?c:formatCount(Math.max(n[c.level-1]??1,1),c.format)).join(""))}}return t}export function wordLevelText(r,o,t){let e=!1;return{text:r.map(n=>typeof n=="string"?n.replace(/%/gu,"%%"):(n.level!==o&&n.format==="decimal"&&(t.get(n.level)??"decimal")!=="decimal"&&(e=!0),`%${String(n.level)}`)).join(""),legal:e}}export function ownFormat(r,o){return r.find(e=>typeof e!="string"&&e.level===o)?.format??"decimal"}export const LIST_NUMBERING=["{1}.","{2:lower-letter}.","{3:lower-roman}.","{4}.","{5:lower-letter}.","{6:lower-roman}."],LIST_BULLETS=["•","◦","▪","•","◦","▪"];export function listNumbering(r,o){const t=Math.min(Math.max(o,1),6),e=r?.[t-1]??LIST_NUMBERING[t-1]??"{1}.",i=readNumbering(e,t,`a list's level ${String(t)}`);return i.problem===void 0?i.parts:readNumbering(LIST_NUMBERING[t-1]??"{1}.",t).parts}export function listNumber(r,o){return listNumbering(r,o.length).map(t=>typeof t=="string"?t:formatCount(Math.max(o[t.level-1]??1,1),t.format)).join("")}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
import{attrOf as l}from"@allyhub/ooxml";const u=(e,r)=>e?.children.filter(t=>t.key===r)??[],n=(e,r)=>e?.children.find(t=>t.key===r),c=(e,r,t)=>{const a=n(n(e,r),t);return a===void 0?void 0:l(a,"m:val")},p=(e,r,t)=>{const a=n(n(e,r),t);if(a===void 0)return!1;const s=l(a,"m:val");return s===void 0||!["0","off","false"].includes(s)},b={α:"\\alpha",β:"\\beta",γ:"\\gamma",δ:"\\delta",ε:"\\varepsilon","ϵ":"\\epsilon",ζ:"\\zeta",η:"\\eta",θ:"\\theta",ϑ:"\\vartheta",ι:"\\iota",κ:"\\kappa",λ:"\\lambda",μ:"\\mu",ν:"\\nu",ξ:"\\xi",π:"\\pi",ϖ:"\\varpi",ρ:"\\rho",ϱ:"\\varrho",σ:"\\sigma",ς:"\\varsigma",τ:"\\tau",υ:"\\upsilon",φ:"\\varphi",ϕ:"\\phi",χ:"\\chi",ψ:"\\psi",ω:"\\omega",Γ:"\\Gamma",Δ:"\\Delta",Θ:"\\Theta",Λ:"\\Lambda",Ξ:"\\Xi",Π:"\\Pi",Σ:"\\Sigma",Υ:"\\Upsilon",Φ:"\\Phi",Ψ:"\\Psi",Ω:"\\Omega","±":"\\pm","∓":"\\mp","×":"\\times","÷":"\\div","·":"\\cdot","⋅":"\\cdot","∘":"\\circ","∙":"\\bullet","≤":"\\le","≥":"\\ge","≠":"\\ne","≈":"\\approx","≡":"\\equiv","∼":"\\sim","≃":"\\simeq","≅":"\\cong","∝":"\\propto","≪":"\\ll","≫":"\\gg","∞":"\\infty","∂":"\\partial","∇":"\\nabla","∈":"\\in","∉":"\\notin","∋":"\\ni","⊂":"\\subset","⊃":"\\supset","⊆":"\\subseteq","⊇":"\\supseteq","∪":"\\cup","∩":"\\cap","∅":"\\emptyset","∀":"\\forall","∃":"\\exists","¬":"\\neg","∧":"\\wedge","∨":"\\vee","→":"\\to","←":"\\leftarrow","↔":"\\leftrightarrow","⇒":"\\Rightarrow","⇐":"\\Leftarrow","⇔":"\\Leftrightarrow","↦":"\\mapsto","…":"\\ldots","⋯":"\\cdots","⋮":"\\vdots","⋱":"\\ddots","′":"'","″":"''","°":"^{\\circ}",ℏ:"\\hbar",ℓ:"\\ell",ℝ:"\\mathbb{R}",ℕ:"\\mathbb{N}",ℤ:"\\mathbb{Z}",ℚ:"\\mathbb{Q}",ℂ:"\\mathbb{C}","−":"-","∗":"*","∣":"\\mid","∥":"\\parallel","⊥":"\\perp","∠":"\\angle","△":"\\triangle","√":"\\surd"},P={"∑":"\\sum","∏":"\\prod","∐":"\\coprod","∫":"\\int","∬":"\\iint","∭":"\\iiint","∮":"\\oint","∯":"\\oiint","∰":"\\oiiint","⋃":"\\bigcup","⋂":"\\bigcap","⋁":"\\bigvee","⋀":"\\bigwedge","⨁":"\\bigoplus","⨂":"\\bigotimes"},v={"̂":"\\hat","̃":"\\tilde","̇":"\\dot","̈":"\\ddot","⃗":"\\vec","̄":"\\bar","̅":"\\bar","̆":"\\breve","̌":"\\check","́":"\\acute","̀":"\\grave"},f=e=>e===""?".":{"{":"\\{","}":"\\}","⟨":"\\langle","〈":"\\langle","⟩":"\\rangle","〉":"\\rangle","‖":"\\|","⌊":"\\lfloor","⌋":"\\rfloor","⌈":"\\lceil","⌉":"\\rceil"}[e]??e,h=new Set(["sin","cos","tan","cot","sec","csc","arcsin","arccos","arctan","sinh","cosh","tanh","coth","log","ln","lg","exp","lim","liminf","limsup","max","min","sup","inf","det","dim","ker","deg","gcd","arg","hom","Pr"]);function d(e,r){const t=e.trim();if(r&&h.has(t))return`\\${t}`;let a="";for(const s of e){const o=b[s];o!==void 0?a+=/[a-z]$/iu.test(o)?`${o} `:o:"#$%&_".includes(s)?a+=`\\${s}`:s==="{"||s==="}"?a+=`\\${s}`:s==="\\"?a+="\\backslash ":s==="~"?a+="\\sim ":s==="^"?a+="\\hat{}":a+=s}return r&&/^[A-Za-z]{2,}$/u.test(t)?`\\mathrm{${t}}`:a}function i(e){return e.map(x).join("").replace(/ +$/u,"").replace(/(\\[a-zA-Z]+) (?=[{}^_()[\]\\,.=+\-<>|]|$)/gu,"$1")}const m=e=>`{${i(e?.children??[])}}`,$=e=>{const r=i(e?.children??[]);return/^([A-Za-z0-9]|\\[a-zA-Z]+)$/u.test(r)?r:`{${r}}`};function x(e){switch(e.key){case"m:r":{const r=u(e,"m:t").map(a=>a.text).join(""),t=c(e,"m:rPr","m:sty")==="p"||n(n(e,"m:rPr"),"m:nor")!==void 0;return d(r,t)}case"w:r":return d(u(e,"w:t").map(r=>r.text).join(""),!0);case"m:f":{const r=m(n(e,"m:num")),t=m(n(e,"m:den")),a=c(e,"m:fPr","m:type");return a==="lin"||a==="skw"?`${r}/${t}`:a==="noBar"?`\\begin{matrix}${r.slice(1,-1)} \\\\ ${t.slice(1,-1)}\\end{matrix}`:`\\frac${r}${t}`}case"m:sSup":return`${$(n(e,"m:e"))}^${m(n(e,"m:sup"))}`;case"m:sSub":return`${$(n(e,"m:e"))}_${m(n(e,"m:sub"))}`;case"m:sSubSup":return`${$(n(e,"m:e"))}_${m(n(e,"m:sub"))}^${m(n(e,"m:sup"))}`;case"m:sPre":return`{}_${m(n(e,"m:sub"))}^${m(n(e,"m:sup"))}${m(n(e,"m:e"))}`;case"m:rad":{const r=n(e,"m:deg");return`\\sqrt${!p(e,"m:radPr","m:degHide")&&r!==void 0&&i(r.children)!==""?`[${i(r.children)}]`:""}${m(n(e,"m:e"))}`}case"m:nary":{const r=c(e,"m:naryPr","m:chr")??"∫",t=P[r]??`\\mathop{${d(r,!1)}}`,a=p(e,"m:naryPr","m:subHide")?"":i(n(e,"m:sub")?.children??[]),s=p(e,"m:naryPr","m:supHide")?"":i(n(e,"m:sup")?.children??[]);return`${t}${a===""?"":`_{${a}}`}${s===""?"":`^{${s}}`}${m(n(e,"m:e"))}`}case"m:d":{const r=c(e,"m:dPr","m:begChr")??"(",t=c(e,"m:dPr","m:endChr")??")",a=c(e,"m:dPr","m:sepChr")??"|",s=u(e,"m:e").map(g=>i(g.children)),o=u(e,"m:e")[0]?.children??[];return r==="("&&t===")"&&s.length===1&&o.length===1&&o[0]?.key==="m:f"&&c(o[0],"m:fPr","m:type")==="noBar"?`\\binom${m(n(o[0],"m:num"))}${m(n(o[0],"m:den"))}`:`\\left${f(r)}${s.join(a==="|"?"\\middle|":d(a,!1))}\\right${f(t)}`}case"m:func":{const r=i(n(e,"m:fName")?.children??[]),t=/^\\mathrm\{([A-Za-z]+)\}$/u.exec(r)?.[1];return`${t!==void 0&&h.has(t)?`\\${t}`:/^\\?[A-Za-z]+$/u.test(r)&&h.has(r.replace("\\",""))?`\\${r.replace("\\","")}`:r}${m(n(e,"m:e"))}`}case"m:limLow":{const r=i(n(e,"m:e")?.children??[]),t=m(n(e,"m:lim"));return/^\\(lim|max|min|sup|inf|liminf|limsup)$/u.test(r)?`${r}_${t}`:`\\underset${t}{${r}}`}case"m:limUpp":return`\\overset${m(n(e,"m:lim"))}${m(n(e,"m:e"))}`;case"m:acc":{const r=c(e,"m:accPr","m:chr")??"̂";return`${v[r]??"\\hat"}${m(n(e,"m:e"))}`}case"m:bar":return`${c(e,"m:barPr","m:pos")==="top"?"\\overline":"\\underline"}${m(n(e,"m:e"))}`;case"m:groupChr":{const r=c(e,"m:groupChrPr","m:chr")??"⏟";return`${(c(e,"m:groupChrPr","m:pos")??"bot")==="top"||r==="⏞"?"\\overbrace":"\\underbrace"}${m(n(e,"m:e"))}`}case"m:borderBox":return`\\boxed${m(n(e,"m:e"))}`;case"m:box":return i(n(e,"m:e")?.children??[]);case"m:phant":return`\\phantom${m(n(e,"m:e"))}`;case"m:m":return`\\begin{matrix}${u(e,"m:mr").map(r=>u(r,"m:e").map(t=>i(t.children)).join(" & ")).join(" \\\\ ")}\\end{matrix}`;case"m:eqArr":return`\\begin{aligned}${u(e,"m:e").map(r=>i(r.children).replaceAll("\\&","&")).join(" \\\\ ")}\\end{aligned}`;case"m:oMath":case"m:e":case"m:num":case"m:den":case"m:sub":case"m:sup":case"m:deg":case"m:lim":case"m:fName":case"w:ins":case"w:smartTag":return i(e.children);default:return""}}export const ommlToLatex=e=>i(e.children),ommlParaToLatex=e=>u(e,"m:oMath").map(ommlToLatex).join(` \\\\
|
|
3
|
+
`);
|