@ecsplico/editor 3.6.0 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +73 -0
- package/dist/adapters/direct-ai.d.ts +4 -4
- package/dist/adapters/direct-ai.js +2 -2
- package/dist/adapters/direct-ai.js.map +1 -1
- package/dist/adapters/document-state.d.ts +1 -1
- package/dist/adapters/document-state.js.map +1 -1
- package/dist/adapters/forge.d.ts +2 -2
- package/dist/adapters/forge.js.map +1 -1
- package/dist/adapters/nitro.d.ts +11 -3
- package/dist/adapters/nitro.js +3 -1
- package/dist/adapters/nitro.js.map +1 -1
- package/dist/adapters/shared.d.ts +6 -6
- package/dist/adapters/shared.js.map +1 -1
- package/dist/code/CodeSurface.vue.d.ts +3 -3
- package/dist/config/index.d.ts +14 -14
- package/dist/config/index.js +8 -8
- package/dist/config/index.js.map +1 -1
- package/dist/core/backend-types.d.ts +3 -3
- package/dist/core/backend-types.js.map +1 -1
- package/dist/core/backend.d.ts +4 -4
- package/dist/core/backend.js.map +1 -1
- package/dist/core/block-convert.d.ts +1 -1
- package/dist/core/block-convert.js +5 -5
- package/dist/core/block-convert.js.map +1 -1
- package/dist/core/block-transfer.d.ts +8 -4
- package/dist/core/block-transfer.js +23 -14
- package/dist/core/block-transfer.js.map +1 -1
- package/dist/core/capabilities.d.ts +113 -0
- package/dist/core/capabilities.js +155 -0
- package/dist/core/capabilities.js.map +1 -0
- package/dist/core/command-types.d.ts +1 -1
- package/dist/core/context.js.map +1 -1
- package/dist/core/convert.d.ts +5 -5
- package/dist/core/convert.js +5 -5
- package/dist/core/convert.js.map +1 -1
- package/dist/core/core-feature.js +1 -1
- package/dist/core/define-editor.d.ts +2 -2
- package/dist/core/define-editor.js +34 -6
- package/dist/core/define-editor.js.map +1 -1
- package/dist/core/derivation.d.ts +119 -0
- package/dist/core/derivation.js +187 -0
- package/dist/core/derivation.js.map +1 -0
- package/dist/core/derive.d.ts +61 -0
- package/dist/core/derive.js +69 -0
- package/dist/core/derive.js.map +1 -0
- package/dist/core/extension-points.d.ts +16 -0
- package/dist/core/feature-context.d.ts +5 -1
- package/dist/core/feature-context.js +10 -3
- package/dist/core/feature-context.js.map +1 -1
- package/dist/core/feature.d.ts +41 -19
- package/dist/core/feature.js.map +1 -1
- package/dist/core/fences.js +1 -1
- package/dist/core/fences.js.map +1 -1
- package/dist/core/index.d.ts +6 -2
- package/dist/core/index.js +5 -1
- package/dist/core/pipeline.d.ts +14 -5
- package/dist/core/pipeline.js +19 -7
- package/dist/core/pipeline.js.map +1 -1
- package/dist/core/properties.d.ts +22 -0
- package/dist/core/properties.js +17 -0
- package/dist/core/properties.js.map +1 -0
- package/dist/core/schema/block-ids.js +5 -5
- package/dist/core/schema/block-ids.js.map +1 -1
- package/dist/core/schema/index.d.ts +2 -1
- package/dist/core/schema/index.js +2 -1
- package/dist/core/schema/index.js.map +1 -1
- package/dist/core/schema/opaque-fence.d.ts +4 -4
- package/dist/core/schema/opaque-fence.js +7 -7
- package/dist/core/schema/opaque-fence.js.map +1 -1
- package/dist/core/schema/persisted-names.d.ts +58 -0
- package/dist/core/schema/persisted-names.js +96 -0
- package/dist/core/schema/persisted-names.js.map +1 -0
- package/dist/core/toolbar-items.js +1 -1
- package/dist/core/toolbar-items.js.map +1 -1
- package/dist/core/util.js +5 -1
- package/dist/core/util.js.map +1 -1
- package/dist/document/DocumentSurface.vue.d.ts +3 -3
- package/dist/features/ai/agent-ops.js +1 -1
- package/dist/features/ai/ai-review.js +1 -1
- package/dist/features/ai/assistant.d.ts +4 -4
- package/dist/features/ai/assistant.js +1 -1
- package/dist/features/ai/assistant.js.map +1 -1
- package/dist/features/ai/components/AiSelectionMenu.js +1 -1
- package/dist/features/ai/components/AiSelectionMenu.js.map +1 -1
- package/dist/features/ai/components/ModelQuickSwitch.js +7 -7
- package/dist/features/ai/components/ModelQuickSwitch.js.map +1 -1
- package/dist/features/ai/components/ModelQuickSwitch.vue.d.ts +4 -4
- package/dist/features/ai/components/SettingsAiTab.js +8 -8
- package/dist/features/ai/components/SettingsAiTab.js.map +1 -1
- package/dist/features/ai/components/SettingsModelProfiles.js +1 -1
- package/dist/features/ai/components/SettingsModelProfiles.js.map +1 -1
- package/dist/features/ai/document-chat-model.d.ts +2 -2
- package/dist/features/ai/document-chat-model.js +5 -5
- package/dist/features/ai/document-chat-model.js.map +1 -1
- package/dist/features/ai/document-chat.js +2 -2
- package/dist/features/ai/document-chat.js.map +1 -1
- package/dist/features/ai/feature.d.ts +2 -2
- package/dist/features/ai/feature.js +2 -2
- package/dist/features/ai/feature.js.map +1 -1
- package/dist/features/ai/ghost-autocomplete.d.ts +4 -4
- package/dist/features/ai/ghost-autocomplete.js +1 -1
- package/dist/features/ai/ghost-autocomplete.js.map +1 -1
- package/dist/features/ai/index.d.ts +3 -3
- package/dist/features/ai/index.js +2 -2
- package/dist/features/ai/model-profiles.d.ts +9 -9
- package/dist/features/ai/model-profiles.js +13 -13
- package/dist/features/ai/model-profiles.js.map +1 -1
- package/dist/features/ai/protocol/agent-ops.d.ts +2 -2
- package/dist/features/ai/protocol/agent-ops.js +1 -1
- package/dist/features/ai/protocol/agent-ops.js.map +1 -1
- package/dist/features/ai/protocol/block-lines.d.ts +7 -7
- package/dist/features/ai/protocol/block-lines.js +10 -10
- package/dist/features/ai/protocol/block-lines.js.map +1 -1
- package/dist/features/ai/protocol/chat.d.ts +5 -5
- package/dist/features/ai/protocol/chat.js +12 -12
- package/dist/features/ai/protocol/chat.js.map +1 -1
- package/dist/features/ai/protocol/generate.d.ts +1 -1
- package/dist/features/ai/protocol/generate.js +1 -1
- package/dist/features/ai/protocol/generate.js.map +1 -1
- package/dist/features/ai/protocol/index.d.ts +3 -3
- package/dist/features/ai/protocol/index.js +2 -2
- package/dist/features/ai/protocol/models.d.ts +3 -3
- package/dist/features/ai/protocol/models.js +3 -3
- package/dist/features/ai/protocol/models.js.map +1 -1
- package/dist/features/ai/protocol/schemas.d.ts +1 -1
- package/dist/features/ai/protocol/schemas.js +1 -1
- package/dist/features/ai/protocol/schemas.js.map +1 -1
- package/dist/features/ai/protocol/tasks.d.ts +5 -5
- package/dist/features/ai/protocol/tasks.js +12 -12
- package/dist/features/ai/protocol/tasks.js.map +1 -1
- package/dist/features/ai/react/AiSelectionMenu.js.map +1 -1
- package/dist/features/ai/react/ModelQuickSwitch.d.ts +4 -4
- package/dist/features/ai/react/ModelQuickSwitch.js +6 -6
- package/dist/features/ai/react/ModelQuickSwitch.js.map +1 -1
- package/dist/features/ai/react/SettingsAiTab.d.ts +1 -1
- package/dist/features/ai/react/SettingsAiTab.js +8 -8
- package/dist/features/ai/react/SettingsAiTab.js.map +1 -1
- package/dist/features/ai/react/SettingsModelProfiles.d.ts +1 -1
- package/dist/features/ai/react/SettingsModelProfiles.js +1 -1
- package/dist/features/ai/react/SettingsModelProfiles.js.map +1 -1
- package/dist/features/ai/react/use-ai-assistant.d.ts +1 -1
- package/dist/features/ai/react/use-ai-assistant.js +1 -1
- package/dist/features/ai/react/use-ai-assistant.js.map +1 -1
- package/dist/features/ai/react/use-model-profiles.d.ts +5 -5
- package/dist/features/ai/react/use-model-profiles.js +2 -2
- package/dist/features/ai/react/use-model-profiles.js.map +1 -1
- package/dist/features/ai/use-ai-assistant.d.ts +1 -1
- package/dist/features/ai/use-ai-assistant.js +1 -1
- package/dist/features/ai/use-ai-assistant.js.map +1 -1
- package/dist/features/ai/use-model-profiles.d.ts +4 -4
- package/dist/features/ai/use-model-profiles.js +2 -2
- package/dist/features/ai/use-model-profiles.js.map +1 -1
- package/dist/features/block-ui/block-actions.d.ts +8 -4
- package/dist/features/block-ui/block-actions.js +38 -22
- package/dist/features/block-ui/block-actions.js.map +1 -1
- package/dist/features/block-ui/block-target.d.ts +29 -0
- package/dist/features/block-ui/block-target.js +63 -0
- package/dist/features/block-ui/block-target.js.map +1 -0
- package/dist/features/block-ui/components/BlockHandles.js +3 -3
- package/dist/features/block-ui/components/BlockHandles.js.map +1 -1
- package/dist/features/block-ui/components/BlockUi.js +11 -23
- package/dist/features/block-ui/components/BlockUi.js.map +1 -1
- package/dist/features/block-ui/feature.d.ts +3 -2
- package/dist/features/block-ui/feature.js +3 -2
- package/dist/features/block-ui/feature.js.map +1 -1
- package/dist/features/block-ui/handle-geometry.js +12 -23
- package/dist/features/block-ui/handle-geometry.js.map +1 -1
- package/dist/features/block-ui/index.d.ts +2 -1
- package/dist/features/block-ui/index.js +2 -1
- package/dist/features/block-ui/react/BlockHandles.d.ts +1 -1
- package/dist/features/block-ui/react/BlockHandles.js +4 -4
- package/dist/features/block-ui/react/BlockHandles.js.map +1 -1
- package/dist/features/block-ui/react/BlockUi.js +13 -25
- package/dist/features/block-ui/react/BlockUi.js.map +1 -1
- package/dist/features/comments/model.js +1 -1
- package/dist/features/composites/accepted-children.d.ts +5 -4
- package/dist/features/composites/accepted-children.js +26 -26
- package/dist/features/composites/accepted-children.js.map +1 -1
- package/dist/features/composites/ai-brief.d.ts +4 -4
- package/dist/features/composites/ai-brief.js +14 -12
- package/dist/features/composites/ai-brief.js.map +1 -1
- package/dist/features/composites/anchors.d.ts +1 -1
- package/dist/features/composites/anchors.js.map +1 -1
- package/dist/features/composites/baskets.d.ts +1 -1
- package/dist/features/composites/baskets.js.map +1 -1
- package/dist/features/composites/bibliography-command.d.ts +1 -1
- package/dist/features/composites/bibliography-form.js +1 -1
- package/dist/features/composites/bibliography-form.js.map +1 -1
- package/dist/features/composites/bibliography.js.map +1 -1
- package/dist/features/composites/block-types-json.d.ts +38 -0
- package/dist/features/composites/block-types-json.js +122 -0
- package/dist/features/composites/block-types-json.js.map +1 -0
- package/dist/features/composites/block-types.d.ts +119 -0
- package/dist/features/composites/block-types.js +343 -0
- package/dist/features/composites/block-types.js.map +1 -0
- package/dist/features/composites/capabilities.js +109 -0
- package/dist/features/composites/capabilities.js.map +1 -0
- package/dist/features/composites/components/BibliographyEditor.js +5 -5
- package/dist/features/composites/components/BibliographyEditor.js.map +1 -1
- package/dist/features/composites/components/CompositeBasketMenu.js +2 -2
- package/dist/features/composites/components/CompositeBasketMenu.js.map +1 -1
- package/dist/features/composites/components/CompositeChrome.js +18 -8
- package/dist/features/composites/components/CompositeChrome.js.map +1 -1
- package/dist/features/composites/components/CompositeChrome.vue.d.ts +1 -1
- package/dist/features/composites/components/CompositeDetails.js +11 -10
- package/dist/features/composites/components/CompositeDetails.js.map +1 -1
- package/dist/features/composites/components/CompositeDetails.vue.d.ts +1 -1
- package/dist/features/composites/components/CompositeFieldEditor.js +7 -7
- package/dist/features/composites/components/CompositeFieldEditor.js.map +1 -1
- package/dist/features/composites/components/CompositeFieldEditor.vue.d.ts +5 -5
- package/dist/features/composites/components/CompositeInspector.js +136 -113
- package/dist/features/composites/components/CompositeInspector.js.map +1 -1
- package/dist/features/composites/components/CompositeInspector.vue.d.ts +3 -3
- package/dist/features/composites/components/CompositeStatusMenu.js +2 -2
- package/dist/features/composites/components/CompositeStatusMenu.js.map +1 -1
- package/dist/features/composites/components/CompositeSummaryEditor.js +1 -1
- package/dist/features/composites/components/CompositeSummaryEditor.js.map +1 -1
- package/dist/features/composites/components/CompositeSummaryEditor.vue.d.ts +1 -1
- package/dist/features/composites/components/CompositeTable.js +2 -2
- package/dist/features/composites/components/CompositeTable.js.map +1 -1
- package/dist/features/composites/components/CompositeTagsEditor.js +1 -1
- package/dist/features/composites/components/CompositeTagsEditor.js.map +1 -1
- package/dist/features/composites/components/CompositeTagsEditor.vue.d.ts +1 -1
- package/dist/features/composites/components/CompositeView.js +19 -17
- package/dist/features/composites/components/CompositeView.js.map +1 -1
- package/dist/features/composites/components/DerivationBadge.js +15 -6
- package/dist/features/composites/components/DerivationBadge.js.map +1 -1
- package/dist/features/composites/components/FocusChip.js +1 -1
- package/dist/features/composites/components/FocusChip.js.map +1 -1
- package/dist/features/composites/components/FocusChip.vue.d.ts +1 -1
- package/dist/features/composites/components/ReferenceFieldSelect.js +3 -3
- package/dist/features/composites/components/ReferenceFieldSelect.js.map +1 -1
- package/dist/features/composites/components/ReferenceView.js +1 -1
- package/dist/features/composites/components/ReferenceView.js.map +1 -1
- package/dist/features/composites/components/SettingsEditingTab.js +18 -18
- package/dist/features/composites/components/SettingsEditingTab.js.map +1 -1
- package/dist/features/composites/components/SettingsEditingTab.vue.d.ts +3 -3
- package/dist/features/composites/convert.d.ts +4 -4
- package/dist/features/composites/convert.js +27 -28
- package/dist/features/composites/convert.js.map +1 -1
- package/dist/features/composites/derived-chrome.js +34 -28
- package/dist/features/composites/derived-chrome.js.map +1 -1
- package/dist/features/composites/editing-settings-keys.js +6 -6
- package/dist/features/composites/editing-settings-keys.js.map +1 -1
- package/dist/features/composites/feature.d.ts +10 -10
- package/dist/features/composites/feature.js +58 -46
- package/dist/features/composites/feature.js.map +1 -1
- package/dist/features/composites/fences.d.ts +3 -3
- package/dist/features/composites/fences.js +18 -13
- package/dist/features/composites/fences.js.map +1 -1
- package/dist/features/composites/focus.d.ts +10 -10
- package/dist/features/composites/focus.js +11 -11
- package/dist/features/composites/focus.js.map +1 -1
- package/dist/features/composites/heading-composites.d.ts +5 -5
- package/dist/features/composites/heading-composites.js +13 -16
- package/dist/features/composites/heading-composites.js.map +1 -1
- package/dist/features/composites/index.d.ts +20 -18
- package/dist/features/composites/index.js +9 -7
- package/dist/features/composites/inspector-model.d.ts +45 -22
- package/dist/features/composites/inspector-model.js +53 -14
- package/dist/features/composites/inspector-model.js.map +1 -1
- package/dist/features/composites/legacy.d.ts +5 -4
- package/dist/features/composites/legacy.js +16 -23
- package/dist/features/composites/legacy.js.map +1 -1
- package/dist/features/composites/markdown-export.js +3 -3
- package/dist/features/composites/markdown-export.js.map +1 -1
- package/dist/features/composites/merge.d.ts +8 -8
- package/dist/features/composites/merge.js +23 -22
- package/dist/features/composites/merge.js.map +1 -1
- package/dist/features/composites/meta-display.js +5 -5
- package/dist/features/composites/meta-display.js.map +1 -1
- package/dist/features/composites/meta-keys.d.ts +5 -5
- package/dist/features/composites/meta-keys.js +8 -8
- package/dist/features/composites/meta-keys.js.map +1 -1
- package/dist/features/composites/node-views.d.ts +3 -3
- package/dist/features/composites/node-views.js +2 -2
- package/dist/features/composites/node-views.js.map +1 -1
- package/dist/features/composites/nodes.d.ts +13 -13
- package/dist/features/composites/nodes.js +100 -77
- package/dist/features/composites/nodes.js.map +1 -1
- package/dist/features/composites/outline.d.ts +15 -12
- package/dist/features/composites/outline.js +24 -21
- package/dist/features/composites/outline.js.map +1 -1
- package/dist/features/composites/properties.d.ts +51 -0
- package/dist/features/composites/properties.js +89 -0
- package/dist/features/composites/properties.js.map +1 -0
- package/dist/features/composites/react/BibliographyEditor.js +5 -5
- package/dist/features/composites/react/BibliographyEditor.js.map +1 -1
- package/dist/features/composites/react/CompositeBasketMenu.js +2 -2
- package/dist/features/composites/react/CompositeBasketMenu.js.map +1 -1
- package/dist/features/composites/react/CompositeChrome.d.ts +1 -1
- package/dist/features/composites/react/CompositeChrome.js +15 -6
- package/dist/features/composites/react/CompositeChrome.js.map +1 -1
- package/dist/features/composites/react/CompositeDetails.d.ts +1 -1
- package/dist/features/composites/react/CompositeDetails.js +11 -10
- package/dist/features/composites/react/CompositeDetails.js.map +1 -1
- package/dist/features/composites/react/CompositeFieldEditor.d.ts +5 -5
- package/dist/features/composites/react/CompositeFieldEditor.js +6 -6
- package/dist/features/composites/react/CompositeFieldEditor.js.map +1 -1
- package/dist/features/composites/react/CompositeInspector.d.ts +3 -3
- package/dist/features/composites/react/CompositeInspector.js +142 -128
- package/dist/features/composites/react/CompositeInspector.js.map +1 -1
- package/dist/features/composites/react/CompositeStatusMenu.js +2 -2
- package/dist/features/composites/react/CompositeStatusMenu.js.map +1 -1
- package/dist/features/composites/react/CompositeSummaryEditor.d.ts +1 -1
- package/dist/features/composites/react/CompositeSummaryEditor.js +1 -1
- package/dist/features/composites/react/CompositeSummaryEditor.js.map +1 -1
- package/dist/features/composites/react/CompositeTable.d.ts +1 -1
- package/dist/features/composites/react/CompositeTable.js +3 -3
- package/dist/features/composites/react/CompositeTable.js.map +1 -1
- package/dist/features/composites/react/CompositeTagsEditor.d.ts +1 -1
- package/dist/features/composites/react/CompositeTagsEditor.js +1 -1
- package/dist/features/composites/react/CompositeTagsEditor.js.map +1 -1
- package/dist/features/composites/react/CompositeView.js +17 -15
- package/dist/features/composites/react/CompositeView.js.map +1 -1
- package/dist/features/composites/react/DerivationBadge.js +13 -4
- package/dist/features/composites/react/DerivationBadge.js.map +1 -1
- package/dist/features/composites/react/FocusChip.d.ts +1 -1
- package/dist/features/composites/react/FocusChip.js +1 -1
- package/dist/features/composites/react/FocusChip.js.map +1 -1
- package/dist/features/composites/react/ReferenceFieldSelect.js +3 -3
- package/dist/features/composites/react/ReferenceFieldSelect.js.map +1 -1
- package/dist/features/composites/react/ReferenceView.d.ts +1 -1
- package/dist/features/composites/react/ReferenceView.js +1 -1
- package/dist/features/composites/react/ReferenceView.js.map +1 -1
- package/dist/features/composites/react/SettingsEditingTab.d.ts +4 -4
- package/dist/features/composites/react/SettingsEditingTab.js +20 -20
- package/dist/features/composites/react/SettingsEditingTab.js.map +1 -1
- package/dist/features/composites/react.js +1 -1
- package/dist/features/composites/react.js.map +1 -1
- package/dist/features/composites/reference-ai.js +1 -1
- package/dist/features/composites/reference-ai.js.map +1 -1
- package/dist/features/composites/reference-label.d.ts +3 -3
- package/dist/features/composites/reference-label.js +6 -6
- package/dist/features/composites/reference-label.js.map +1 -1
- package/dist/features/composites/reference-suggestion.d.ts +1 -1
- package/dist/features/composites/reference-suggestion.js +3 -3
- package/dist/features/composites/reference-suggestion.js.map +1 -1
- package/dist/features/composites/reference-text.d.ts +2 -2
- package/dist/features/composites/reference-text.js +4 -4
- package/dist/features/composites/reference-text.js.map +1 -1
- package/dist/features/composites/reference.d.ts +3 -3
- package/dist/features/composites/reference.js +1 -1
- package/dist/features/composites/reference.js.map +1 -1
- package/dist/features/composites/reveal-source.d.ts +3 -3
- package/dist/features/composites/reveal-source.js +6 -6
- package/dist/features/composites/reveal-source.js.map +1 -1
- package/dist/features/composites/rows-model.d.ts +2 -2
- package/dist/features/composites/rows-model.js +4 -3
- package/dist/features/composites/rows-model.js.map +1 -1
- package/dist/features/composites/rows.d.ts +16 -28
- package/dist/features/composites/rows.js +20 -54
- package/dist/features/composites/rows.js.map +1 -1
- package/dist/features/composites/schema.d.ts +12 -11
- package/dist/features/composites/schema.js +10 -9
- package/dist/features/composites/schema.js.map +1 -1
- package/dist/features/composites/source.d.ts +20 -0
- package/dist/features/composites/source.js +40 -0
- package/dist/features/composites/source.js.map +1 -0
- package/dist/features/composites/split.d.ts +11 -11
- package/dist/features/composites/split.js +20 -20
- package/dist/features/composites/split.js.map +1 -1
- package/dist/features/composites/structure-mode.js +3 -3
- package/dist/features/composites/structure-mode.js.map +1 -1
- package/dist/features/composites/table-model.js +2 -2
- package/dist/features/composites/table-model.js.map +1 -1
- package/dist/features/composites/use-composite-inspector.js +3 -1
- package/dist/features/composites/use-composite-inspector.js.map +1 -1
- package/dist/features/composites/use-composite-rows.d.ts +2 -2
- package/dist/features/composites/use-composite-rows.js.map +1 -1
- package/dist/features/composites/vue.js +1 -1
- package/dist/features/composites/vue.js.map +1 -1
- package/dist/features/image-studio/components/ImageStudioDialog.js +150 -87
- package/dist/features/image-studio/components/ImageStudioDialog.js.map +1 -1
- package/dist/features/image-studio/components/ImageStudioDialog.vue.d.ts +5 -1
- package/dist/features/image-studio/components/ImageStudioLibraryPanel.js +186 -0
- package/dist/features/image-studio/components/ImageStudioLibraryPanel.js.map +1 -0
- package/dist/features/image-studio/components/ImageStudioLibraryTile.js +134 -0
- package/dist/features/image-studio/components/ImageStudioLibraryTile.js.map +1 -0
- package/dist/features/image-studio/components/ImageStudioView.js.map +1 -1
- package/dist/features/image-studio/feature.d.ts +1 -1
- package/dist/features/image-studio/feature.js +1 -1
- package/dist/features/image-studio/feature.js.map +1 -1
- package/dist/features/image-studio/index.d.ts +3 -2
- package/dist/features/image-studio/index.js +2 -2
- package/dist/features/image-studio/library.d.ts +35 -0
- package/dist/features/image-studio/node-core.d.ts +3 -3
- package/dist/features/image-studio/node-core.js +1 -1
- package/dist/features/image-studio/node-core.js.map +1 -1
- package/dist/features/image-studio/node-store.d.ts +1 -1
- package/dist/features/image-studio/node-store.js +1 -1
- package/dist/features/image-studio/node-store.js.map +1 -1
- package/dist/features/image-studio/react/ImageStudioDialog.d.ts +1 -1
- package/dist/features/image-studio/react/ImageStudioDialog.js +46 -5
- package/dist/features/image-studio/react/ImageStudioDialog.js.map +1 -1
- package/dist/features/image-studio/react/ImageStudioLibraryPanel.js +141 -0
- package/dist/features/image-studio/react/ImageStudioLibraryPanel.js.map +1 -0
- package/dist/features/image-studio/react/ImageStudioLibraryTile.js +105 -0
- package/dist/features/image-studio/react/ImageStudioLibraryTile.js.map +1 -0
- package/dist/features/image-studio/react/ImageStudioView.js +1 -1
- package/dist/features/image-studio/react/ImageStudioView.js.map +1 -1
- package/dist/features/image-studio/react/store.d.ts +8 -3
- package/dist/features/image-studio/react/store.js.map +1 -1
- package/dist/features/image-studio/react.d.ts +4 -3
- package/dist/features/image-studio/react.js +3 -3
- package/dist/features/image-studio/react.js.map +1 -1
- package/dist/features/image-studio/schema.d.ts +1 -1
- package/dist/features/image-studio/schema.js +1 -1
- package/dist/features/image-studio/schema.js.map +1 -1
- package/dist/features/image-studio/state.d.ts +8 -3
- package/dist/features/image-studio/state.js +11 -3
- package/dist/features/image-studio/state.js.map +1 -1
- package/dist/features/image-studio/store.d.ts +8 -3
- package/dist/features/image-studio/vue.d.ts +4 -3
- package/dist/features/image-studio/vue.js +3 -3
- package/dist/features/image-studio/vue.js.map +1 -1
- package/dist/features/mentions/tag.js +2 -1
- package/dist/features/mentions/tag.js.map +1 -1
- package/dist/features/themes/components/SettingsAppearanceTab.js +1 -1
- package/dist/features/themes/components/SettingsAppearanceTab.js.map +1 -1
- package/dist/features/themes/feature.d.ts +1 -1
- package/dist/features/themes/feature.js.map +1 -1
- package/dist/features/themes/react/SettingsAppearanceTab.d.ts +1 -1
- package/dist/features/themes/react/SettingsAppearanceTab.js +1 -1
- package/dist/features/themes/react/SettingsAppearanceTab.js.map +1 -1
- package/dist/features/themes/theme-runtime.js +1 -1
- package/dist/features/themes/theme-runtime.js.map +1 -1
- package/dist/features/transcript/TranscriptSegmentView.js +1 -1
- package/dist/features/transcript/TranscriptSegmentView.js.map +1 -1
- package/dist/features/transcript/react/TranscriptSegmentView.js +1 -1
- package/dist/features/transcript/react/TranscriptSegmentView.js.map +1 -1
- package/dist/features/transcript/segment-node.js.map +1 -1
- package/dist/features/transfer/feature.js +1 -1
- package/dist/features/transfer/feature.js.map +1 -1
- package/dist/features/transfer/transforms.d.ts +4 -4
- package/dist/features/transfer/transforms.js +12 -12
- package/dist/features/transfer/transforms.js.map +1 -1
- package/dist/i18n/de/ai.js +4 -4
- package/dist/i18n/de/ai.js.map +1 -1
- package/dist/i18n/de/authors.js +1 -1
- package/dist/i18n/de/authors.js.map +1 -1
- package/dist/i18n/de/comments.js +1 -1
- package/dist/i18n/de/comments.js.map +1 -1
- package/dist/i18n/de/composites.js +62 -59
- package/dist/i18n/de/composites.js.map +1 -1
- package/dist/i18n/de/image-studio.js +11 -2
- package/dist/i18n/de/image-studio.js.map +1 -1
- package/dist/i18n/de/integrations.js +20 -20
- package/dist/i18n/de/integrations.js.map +1 -1
- package/dist/i18n/de/markdown.js +1 -1
- package/dist/i18n/de/markdown.js.map +1 -1
- package/dist/i18n/de/palette.js +1 -1
- package/dist/i18n/de/palette.js.map +1 -1
- package/dist/i18n/de/themes.js +3 -3
- package/dist/i18n/de/themes.js.map +1 -1
- package/dist/i18n/de/transfer.js +2 -2
- package/dist/i18n/de/transfer.js.map +1 -1
- package/dist/i18n/de/tree.js +6 -6
- package/dist/i18n/de/tree.js.map +1 -1
- package/dist/i18n/de.d.ts +110 -98
- package/dist/i18n/en/ai.js +2 -2
- package/dist/i18n/en/ai.js.map +1 -1
- package/dist/i18n/en/composites.js +64 -61
- package/dist/i18n/en/composites.js.map +1 -1
- package/dist/i18n/en/image-studio.js +9 -0
- package/dist/i18n/en/image-studio.js.map +1 -1
- package/dist/i18n/en/integrations.js +9 -9
- package/dist/i18n/en/integrations.js.map +1 -1
- package/dist/i18n/en/markdown.js +1 -1
- package/dist/i18n/en/markdown.js.map +1 -1
- package/dist/i18n/en/palette.js +1 -1
- package/dist/i18n/en/palette.js.map +1 -1
- package/dist/i18n/en/themes.js +4 -4
- package/dist/i18n/en/themes.js.map +1 -1
- package/dist/i18n/en/tree.js +5 -5
- package/dist/i18n/en/tree.js.map +1 -1
- package/dist/index.d.ts +4 -1
- package/dist/integrations/composite-ai/bibliography-fetch.d.ts +6 -6
- package/dist/integrations/composite-ai/bibliography-fetch.js +19 -19
- package/dist/integrations/composite-ai/bibliography-fetch.js.map +1 -1
- package/dist/integrations/composite-ai/composite-fill.d.ts +4 -4
- package/dist/integrations/composite-ai/composite-fill.js +5 -5
- package/dist/integrations/composite-ai/composite-fill.js.map +1 -1
- package/dist/integrations/composite-ai/composite-summary.d.ts +2 -2
- package/dist/integrations/composite-ai/composite-summary.js +5 -5
- package/dist/integrations/composite-ai/composite-summary.js.map +1 -1
- package/dist/integrations/composite-ai/derive.d.ts +17 -17
- package/dist/integrations/composite-ai/derive.js +27 -26
- package/dist/integrations/composite-ai/derive.js.map +1 -1
- package/dist/integrations/composite-ai/index.d.ts +14 -15
- package/dist/integrations/composite-ai/index.js +98 -77
- package/dist/integrations/composite-ai/index.js.map +1 -1
- package/dist/integrations/composite-ai/outline-sanitize.d.ts +1 -1
- package/dist/integrations/composite-ai/outline-sanitize.js +1 -1
- package/dist/integrations/composite-ai/outline-sanitize.js.map +1 -1
- package/dist/integrations/composite-ai/rendition.d.ts +9 -9
- package/dist/integrations/composite-ai/rendition.js +27 -27
- package/dist/integrations/composite-ai/rendition.js.map +1 -1
- package/dist/integrations/composite-ai/split.d.ts +8 -8
- package/dist/integrations/composite-ai/split.js +12 -12
- package/dist/integrations/composite-ai/split.js.map +1 -1
- package/dist/integrations/composite-ai/transfer-transforms.d.ts +2 -2
- package/dist/integrations/composite-ai/transfer-transforms.js +11 -11
- package/dist/integrations/composite-ai/transfer-transforms.js.map +1 -1
- package/dist/integrations/composite-media/index.d.ts +4 -3
- package/dist/integrations/composite-media/index.js +20 -14
- package/dist/integrations/composite-media/index.js.map +1 -1
- package/dist/markdown/MarkdownSurface.vue.d.ts +7 -7
- package/dist/markdown/document.js +1 -1
- package/dist/markdown/document.js.map +1 -1
- package/dist/nuxt/module.d.ts +48 -24
- package/dist/nuxt/module.js.map +1 -1
- package/dist/nuxt/runtime/server/plugins/editor-server.js +3 -2
- package/dist/nuxt/runtime/server/plugins/editor-server.js.map +1 -1
- package/dist/presets/compose.d.ts +6 -6
- package/dist/presets/compose.js +7 -4
- package/dist/presets/compose.js.map +1 -1
- package/dist/react/AdvancedEditor.d.ts +2 -2
- package/dist/react/AdvancedEditor.js +1 -1
- package/dist/react/AdvancedEditor.js.map +1 -1
- package/dist/react/compose.d.ts +1 -1
- package/dist/react/compose.js +1 -1
- package/dist/react/compose.js.map +1 -1
- package/dist/react/composed-surface.d.ts +5 -5
- package/dist/react/composed-surface.js +2 -2
- package/dist/react/composed-surface.js.map +1 -1
- package/dist/server/ai.d.ts +7 -7
- package/dist/server/ai.js +1 -1
- package/dist/server/ai.js.map +1 -1
- package/dist/server/auth.d.ts +1 -1
- package/dist/server/collab-state.d.ts +1 -1
- package/dist/server/collab-state.js.map +1 -1
- package/dist/server/collab.d.ts +4 -4
- package/dist/server/collab.js +22 -17
- package/dist/server/collab.js.map +1 -1
- package/dist/server/handlers/ai.d.ts +9 -6
- package/dist/server/handlers/ai.js +13 -17
- package/dist/server/handlers/ai.js.map +1 -1
- package/dist/server/handlers/context.d.ts +4 -0
- package/dist/server/handlers/context.js.map +1 -1
- package/dist/server/handlers/editor.d.ts +33 -32
- package/dist/server/handlers/editor.js +13 -8
- package/dist/server/handlers/editor.js.map +1 -1
- package/dist/server/handlers/images.d.ts +1 -1
- package/dist/server/handlers/images.js +1 -1
- package/dist/server/handlers/images.js.map +1 -1
- package/dist/server/host.d.ts +4 -0
- package/dist/server/host.js +10 -2
- package/dist/server/host.js.map +1 -1
- package/dist/server/index.d.ts +3 -3
- package/dist/server/ports.d.ts +8 -8
- package/dist/server/ports.js.map +1 -1
- package/dist/settings/index.d.ts +20 -19
- package/dist/settings/index.js +25 -24
- package/dist/settings/index.js.map +1 -1
- package/dist/settings/migrate.d.ts +18 -0
- package/dist/settings/migrate.js +46 -0
- package/dist/settings/migrate.js.map +1 -0
- package/dist/settings/values.d.ts +12 -12
- package/dist/settings/values.js +11 -11
- package/dist/settings/values.js.map +1 -1
- package/dist/styles/composites.css +10 -10
- package/dist/tree/DocumentTree.js +12 -5
- package/dist/tree/DocumentTree.js.map +1 -1
- package/dist/tree/drop-rules.js +5 -5
- package/dist/tree/drop-rules.js.map +1 -1
- package/dist/tree/react/DocumentTree.js +14 -5
- package/dist/tree/react/DocumentTree.js.map +1 -1
- package/dist/tree/tree-host.js +5 -5
- package/dist/tree/tree-host.js.map +1 -1
- package/dist/tree/tree-items.js +34 -28
- package/dist/tree/tree-items.js.map +1 -1
- package/dist/tree/tree-model.js +16 -16
- package/dist/tree/tree-model.js.map +1 -1
- package/dist/tree/tree-rows.js +2 -2
- package/dist/tree/tree-rows.js.map +1 -1
- package/dist/tree/tree-view-model.d.ts +2 -2
- package/dist/tree/tree-view-model.js.map +1 -1
- package/dist/vue/AdvancedEditor.js +2 -2
- package/dist/vue/AdvancedEditor.js.map +1 -1
- package/dist/vue/AdvancedEditor.vue.d.ts +10 -10
- package/dist/vue/SimpleEditor.vue.d.ts +4 -4
- package/dist/vue/components/EditorSurface.vue.d.ts +4 -4
- package/dist/vue/compose.d.ts +1 -1
- package/dist/vue/compose.js +1 -1
- package/dist/vue/compose.js.map +1 -1
- package/package.json +1 -1
- package/dist/features/composites/derivation.d.ts +0 -62
- package/dist/features/composites/derivation.js +0 -102
- package/dist/features/composites/derivation.js.map +0 -1
- package/dist/features/composites/kinds.d.ts +0 -89
- package/dist/features/composites/kinds.js +0 -285
- package/dist/features/composites/kinds.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CompositeTable.js","names":["_openBlock","_createElementBlock","_unref","_createVNode","_createElementVNode","_toDisplayString","_Fragment","_createSlots","_withCtx","_renderList","_createBlock","_createCommentVNode","_normalizeStyle","_createTextVNode","_normalizeClass"],"sources":["../../../../src/features/composites/components/CompositeTable.vue"],"sourcesContent":["<script setup lang=\"ts\">\n// All Bausteine of an editor's document as a sortable, filterable table. Columns beyond the fixed ones derive from the\n// meta fields of the kinds present in the document, so a host kind with fields gets its columns without code changes.\nimport type { Editor } from '@tiptap/core'\nimport { computed, ref } from 'vue'\nimport type { TableColumn } from '../../../vue/kit/types'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { compositeKindsOf } from '../nodes'\nimport type { CompositeRow } from '../rows'\nimport { columnSpecsOf, type FieldContext, FILTER_ALL, fieldColumnsOf, fieldOf, fieldText, hasText, isLongText, sortRows, toggled } from '../table-model'\nimport { useCompositeRows } from '../use-composite-rows'\n\nconst props = defineProps<{ editor?: Editor }>()\nconst emit = defineEmits<{ select: [row: CompositeRow] }>()\n\nconst { Badge: UBadge, Button: UButton, Icon: UIcon, Input: UInput, Select: USelect, Table: UTable } = useUiKit()\nconst { t } = useEditorI18n()\n\nconst { rows, tags, kinds } = useCompositeRows(() => props.editor)\n\n// --- Columns ----------------------------------------------------------------------------------------------------\n\n// `reference` cells resolve their target in the document; re-read whenever the rows change.\nconst fieldContext = computed<FieldContext | undefined>(() => {\n void rows.value\n return props.editor ? { doc: props.editor.state.doc, kinds: compositeKindsOf(props.editor), t } : undefined\n})\nconst fieldColumns = computed(() => fieldColumnsOf(rows.value, kinds.value, fieldContext.value))\nconst specs = computed(() => columnSpecsOf(fieldColumns.value, t))\n\nconst columns = computed<TableColumn<CompositeRow>[]>(() => specs.value.map(spec => ({\n id: spec.id,\n header: spec.label,\n accessorFn: spec.sort,\n // The table reports `aria-sort` on the header cell only for columns that opt in.\n enableSorting: true,\n meta: { class: {\n th: [spec.id === 'title' ? 'min-w-56' : '', spec.align === 'end' ? 'text-right' : ''].join(' '),\n td: spec.align === 'end' ? 'text-right' : '',\n } },\n})))\n\n// --- Filter -----------------------------------------------------------------------------------------------------\n\nconst search = ref('')\nconst pickedKinds = ref<string[]>([])\nconst pickedTags = ref<string[]>([])\nconst pickedOptions = ref<Record<string, string>>({})\n\n/** One select per `select` field in use; its choices are the union of the options of all kinds that have the key. */\nconst selectFilters = computed(() => fieldColumns.value.flatMap((column) => {\n if (column.field.type !== 'select') return []\n const options = new Map<string, string>()\n for (const row of rows.value) {\n for (const option of fieldOf(row, column.field.key)?.options ?? []) if (!options.has(option.value)) options.set(option.value, option.label)\n }\n return [{\n key: column.field.key,\n label: column.field.label,\n items: [{ label: t('composites.table.filter.all'), value: FILTER_ALL }, ...[...options].map(([value, label]) => ({ label, value }))],\n }]\n}))\n\n// A kind, tag or option that vanished from the document can no longer be unpicked in the UI, so it must not filter either.\nconst activeKinds = computed(() => pickedKinds.value.filter(id => kinds.value.some(kind => kind.id === id)))\nconst activeTags = computed(() => pickedTags.value.filter(tag => tags.value.includes(tag)))\nconst activeOptions = computed(() => selectFilters.value.flatMap((filter) => {\n const value = pickedOptions.value[filter.key]\n return value && filter.items.some(item => item.value === value && value !== FILTER_ALL) ? [[filter.key, value] as const] : []\n}))\nconst needle = computed(() => search.value.trim().toLowerCase())\nconst filterActive = computed(() => activeKinds.value.length > 0 || activeTags.value.length > 0 || activeOptions.value.length > 0 || needle.value !== '')\n\nfunction resetFilters() {\n search.value = ''\n pickedKinds.value = []\n pickedTags.value = []\n pickedOptions.value = {}\n}\n\nconst filtered = computed(() => rows.value.filter((row) => {\n if (activeKinds.value.length && !activeKinds.value.includes(row.kind)) return false\n if (activeTags.value.length && !activeTags.value.every(tag => row.tags.includes(tag))) return false\n if (activeOptions.value.some(([key, value]) => row.meta[key] !== value)) return false\n if (needle.value) {\n const haystack = `${row.title}\\n${row.description}\\n${row.tags.map(tag => `#${tag}`).join(' ')}`.toLowerCase()\n if (!haystack.includes(needle.value)) return false\n }\n return true\n}))\n\n// --- Sorting (client side; the table only reports the state, so the data is ordered here) -------------------------\n\nconst sorting = ref<{ id: string, desc: boolean }[]>([])\nconst activeSort = computed(() => {\n const entry = sorting.value[0]\n const spec = entry && specs.value.find(item => item.id === entry.id)\n return entry && spec ? { id: entry.id, desc: entry.desc, sort: spec.sort } : null\n})\n\n/** Header click cycles ascending → descending → unsorted. */\nfunction cycleSort(id: string) {\n const current = sorting.value[0]\n if (current?.id !== id) sorting.value = [{ id, desc: false }]\n else sorting.value = current.desc ? [] : [{ id, desc: true }]\n}\nconst sortIcon = (id: string) => {\n const current = sorting.value[0]\n if (current?.id !== id) return 'i-lucide-chevrons-up-down'\n return current.desc ? 'i-lucide-arrow-down' : 'i-lucide-arrow-up'\n}\n\nconst sorted = computed(() => {\n const sort = activeSort.value\n return sort ? sortRows(filtered.value, sort.sort, sort.desc) : filtered.value\n})\n\nconst countLabel = computed(() => t(rows.value.length === 1 ? 'composites.table.count.one' : 'composites.table.count.other', { n: sorted.value.length, total: rows.value.length }))\n</script>\n\n<template>\n <section class=\"flex min-h-0 flex-col gap-3\" :aria-label=\"t('composites.table.label')\">\n <div v-if=\"!rows.length\" class=\"mx-auto flex max-w-sm flex-1 flex-col items-center justify-center gap-2 py-16 text-center\">\n <UIcon name=\"i-lucide-table-2\" class=\"size-8 text-[var(--sk-fg-dimmed)]\" />\n <p class=\"text-sm font-medium text-[var(--sk-fg-highlighted)]\">\n {{ t('composites.table.emptyTitle') }}\n </p>\n <p class=\"text-sm text-[var(--sk-muted)]\">\n {{ t('composites.table.emptyText') }}\n </p>\n </div>\n\n <template v-else>\n <div class=\"flex flex-col gap-2\">\n <div class=\"flex flex-wrap items-center gap-2\">\n <UInput\n v-model=\"search\"\n class=\"w-64\"\n size=\"sm\"\n icon=\"i-lucide-search\"\n :placeholder=\"t('composites.table.search.placeholder')\"\n :aria-label=\"t('composites.table.search.label')\"\n >\n <template v-if=\"search\" #trailing>\n <UButton\n color=\"neutral\"\n variant=\"link\"\n size=\"xs\"\n icon=\"i-lucide-x\"\n :aria-label=\"t('composites.table.search.clear')\"\n @click=\"search = ''\"\n />\n </template>\n </UInput>\n\n <div v-for=\"filter in selectFilters\" :key=\"filter.key\" class=\"flex items-center gap-1.5\">\n <span class=\"text-sm text-[var(--sk-muted)]\" aria-hidden=\"true\">{{ filter.label }}</span>\n <USelect\n :model-value=\"pickedOptions[filter.key] ?? FILTER_ALL\"\n class=\"w-36\"\n size=\"sm\"\n :items=\"filter.items\"\n :aria-label=\"filter.label\"\n @update:model-value=\"pickedOptions = { ...pickedOptions, [filter.key]: String($event) }\"\n />\n </div>\n\n <UButton\n v-if=\"filterActive\"\n size=\"sm\"\n color=\"neutral\"\n variant=\"ghost\"\n icon=\"i-lucide-filter-x\"\n :label=\"t('composites.table.filter.reset')\"\n @click=\"resetFilters\"\n />\n <span class=\"ml-auto text-xs tabular-nums text-[var(--sk-muted)]\" role=\"status\">{{ countLabel }}</span>\n </div>\n\n <div v-if=\"kinds.length > 1\" class=\"flex flex-wrap items-center gap-1\" role=\"group\" :aria-label=\"t('composites.table.filter.byKind')\">\n <UButton\n v-for=\"kind in kinds\"\n :key=\"kind.id\"\n size=\"xs\"\n color=\"neutral\"\n :variant=\"activeKinds.includes(kind.id) ? 'solid' : 'outline'\"\n :icon=\"kind.icon\"\n :label=\"kind.label\"\n :aria-pressed=\"activeKinds.includes(kind.id)\"\n @click=\"pickedKinds = toggled(pickedKinds, kind.id)\"\n />\n </div>\n\n <div v-if=\"tags.length\" class=\"flex flex-wrap items-center gap-1\" role=\"group\" :aria-label=\"t('composites.table.filter.byTag')\">\n <UButton\n v-for=\"tag in tags\"\n :key=\"tag\"\n size=\"xs\"\n color=\"neutral\"\n :variant=\"activeTags.includes(tag) ? 'solid' : 'outline'\"\n :label=\"`#${tag}`\"\n :aria-pressed=\"activeTags.includes(tag)\"\n @click=\"pickedTags = toggled(pickedTags, tag)\"\n />\n </div>\n </div>\n\n <UTable\n v-model:sorting=\"sorting\"\n :data=\"sorted\"\n :columns=\"columns\"\n :get-row-id=\"(row: CompositeRow) => row.key\"\n :ui=\"{ th: 'px-3 py-2 text-sm', td: 'px-3 py-2' }\"\n sticky\n class=\"min-h-0 flex-1 rounded-md border border-[var(--sk-border)]\"\n @select=\"(_event: Event, row: { original: CompositeRow }) => emit('select', row.original)\"\n >\n <template v-for=\"spec in specs\" :key=\"spec.id\" #[`${spec.id}-header`]>\n <button\n type=\"button\"\n class=\"-mx-1.5 inline-flex cursor-pointer items-center gap-1 rounded px-1.5 py-0.5 font-semibold hover:bg-[var(--sk-bg-elevated)] focus-visible:outline-2 focus-visible:outline-[var(--sk-primary)]\"\n @click=\"cycleSort(spec.id)\"\n >\n {{ spec.label }}\n <UIcon :name=\"sortIcon(spec.id)\" class=\"size-3.5\" :class=\"activeSort?.id === spec.id ? 'text-[var(--sk-fg-highlighted)]' : 'text-[var(--sk-fg-dimmed)]'\" />\n </button>\n </template>\n\n <template #title-cell=\"{ row }: { row: { original: CompositeRow } }\">\n <div class=\"flex min-w-0 items-center gap-1.5\" :style=\"{ paddingLeft: `${row.original.depth * 1.25}rem` }\">\n <UIcon :name=\"row.original.icon\" class=\"size-4 shrink-0 text-[var(--sk-muted)]\" />\n <span v-if=\"hasText(row.original.title)\" class=\"truncate font-medium text-[var(--sk-fg-highlighted)]\">{{ row.original.title }}</span>\n <span v-else class=\"truncate text-[var(--sk-muted)]\">{{ t('composites.untitled') }}</span>\n </div>\n </template>\n <template #kind-cell=\"{ row }: { row: { original: CompositeRow } }\">\n {{ row.original.kindLabel }}\n </template>\n <template v-for=\"column in fieldColumns\" :key=\"column.id\" #[`${column.id}-cell`]=\"{ row }: { row: { original: CompositeRow } }\">\n <span\n v-if=\"fieldText(row.original, column.field.key, fieldContext)\"\n class=\"block\"\n :class=\"[column.field.type === 'number' || column.field.type === 'date' ? 'tabular-nums' : '', isLongText(column.field) ? 'max-w-64 truncate' : '']\"\n :title=\"isLongText(column.field) ? fieldText(row.original, column.field.key, fieldContext) : undefined\"\n >{{ fieldText(row.original, column.field.key, fieldContext) }}</span>\n <template v-else>\n <span class=\"text-[var(--sk-fg-dimmed)]\" aria-hidden=\"true\">–</span>\n <span class=\"sr-only\">{{ t('composites.table.noValue') }}</span>\n </template>\n </template>\n <template #tags-cell=\"{ row }: { row: { original: CompositeRow } }\">\n <div v-if=\"row.original.tags.length\" class=\"flex flex-wrap gap-1\">\n <UBadge v-for=\"tag in row.original.tags\" :key=\"tag\" color=\"neutral\" variant=\"subtle\" size=\"sm\" :label=\"`#${tag}`\" />\n </div>\n <template v-else>\n <span class=\"text-[var(--sk-fg-dimmed)]\" aria-hidden=\"true\">–</span>\n <span class=\"sr-only\">{{ t('composites.table.noTags') }}</span>\n </template>\n </template>\n <template #summary-cell=\"{ row }: { row: { original: CompositeRow } }\">\n <template v-if=\"hasText(row.original.description)\">\n <span class=\"inline-block size-2 rounded-full bg-[var(--sk-primary)]\" aria-hidden=\"true\" :title=\"row.original.description\" />\n <span class=\"sr-only\">{{ t('composites.table.summaryPresent') }}</span>\n </template>\n <template v-else>\n <span class=\"text-[var(--sk-fg-dimmed)]\" aria-hidden=\"true\">–</span>\n <span class=\"sr-only\">{{ t('composites.summary.none') }}</span>\n </template>\n </template>\n\n <template #empty>\n <div class=\"flex flex-col items-center gap-2 py-6\">\n <p class=\"text-sm text-[var(--sk-muted)]\">\n {{ t('composites.table.filter.noMatch') }}\n </p>\n <UButton\n size=\"sm\"\n color=\"neutral\"\n variant=\"outline\"\n icon=\"i-lucide-filter-x\"\n :label=\"t('composites.table.filter.reset')\"\n @click=\"resetFilters\"\n />\n </div>\n </template>\n </UTable>\n </template>\n </section>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AC,IAAI,UAAU,OAAO,MAAM,KAAK,aAAA,KAAY,IAAI,KAAA;KAC3F,GAAAG,gBAAAH,MAAA,SAAA,CAAS,CAAC,IAAI,UAAU,OAAO,MAAM,KAAK,aAAA,KAAY,CAAA,GAAA,IAAA,WAAA,MAC1DF,UAAA,GAAAC,mBAGWK,UAAA,EAAA,KAAA,EAAA,GAAA,CAFT,OAAA,OAAA,OAAA,KAAAF,mBAAoE,QAAA;MAA9D,OAAM;MAA6B,eAAY;KAAO,GAAA,KAAC,EAAA,IAC7DA,mBAAgE,QAAhE,aAAgEC,gBAAvCH,MAAA,CAAA,CAAC,CAAA,0BAAA,CAAA,GAAA,CAAA,CAAA,GAAA,EAAA,EAAA,CAAA"}
|
|
1
|
+
{"version":3,"file":"CompositeTable.js","names":["_openBlock","_createElementBlock","_unref","_createVNode","_createElementVNode","_toDisplayString","_Fragment","_createSlots","_withCtx","_renderList","_createBlock","_createCommentVNode","_normalizeStyle","_createTextVNode","_normalizeClass"],"sources":["../../../../src/features/composites/components/CompositeTable.vue"],"sourcesContent":["<script setup lang=\"ts\">\n// All Typed blocks of an editor's document as a sortable, filterable table. Columns beyond the fixed ones derive from the\n// meta fields of the kinds present in the document, so a host kind with fields gets its columns without code changes.\nimport type { Editor } from '@tiptap/core'\nimport { computed, ref } from 'vue'\nimport type { TableColumn } from '../../../vue/kit/types'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { blockTypesOf } from '../nodes'\nimport type { CompositeRow } from '../rows'\nimport { columnSpecsOf, type FieldContext, FILTER_ALL, fieldColumnsOf, fieldOf, fieldText, hasText, isLongText, sortRows, toggled } from '../table-model'\nimport { useCompositeRows } from '../use-composite-rows'\n\nconst props = defineProps<{ editor?: Editor }>()\nconst emit = defineEmits<{ select: [row: CompositeRow] }>()\n\nconst { Badge: UBadge, Button: UButton, Icon: UIcon, Input: UInput, Select: USelect, Table: UTable } = useUiKit()\nconst { t } = useEditorI18n()\n\nconst { rows, tags, kinds } = useCompositeRows(() => props.editor)\n\n// --- Columns ----------------------------------------------------------------------------------------------------\n\n// `reference` cells resolve their target in the document; re-read whenever the rows change.\nconst fieldContext = computed<FieldContext | undefined>(() => {\n void rows.value\n return props.editor ? { doc: props.editor.state.doc, kinds: blockTypesOf(props.editor), t } : undefined\n})\nconst fieldColumns = computed(() => fieldColumnsOf(rows.value, kinds.value, fieldContext.value))\nconst specs = computed(() => columnSpecsOf(fieldColumns.value, t))\n\nconst columns = computed<TableColumn<CompositeRow>[]>(() => specs.value.map(spec => ({\n id: spec.id,\n header: spec.label,\n accessorFn: spec.sort,\n // The table reports `aria-sort` on the header cell only for columns that opt in.\n enableSorting: true,\n meta: { class: {\n th: [spec.id === 'title' ? 'min-w-56' : '', spec.align === 'end' ? 'text-right' : ''].join(' '),\n td: spec.align === 'end' ? 'text-right' : '',\n } },\n})))\n\n// --- Filter -----------------------------------------------------------------------------------------------------\n\nconst search = ref('')\nconst pickedKinds = ref<string[]>([])\nconst pickedTags = ref<string[]>([])\nconst pickedOptions = ref<Record<string, string>>({})\n\n/** One select per `select` field in use; its choices are the union of the options of all kinds that have the key. */\nconst selectFilters = computed(() => fieldColumns.value.flatMap((column) => {\n if (column.field.type !== 'select') return []\n const options = new Map<string, string>()\n for (const row of rows.value) {\n for (const option of fieldOf(row, column.field.key)?.options ?? []) if (!options.has(option.value)) options.set(option.value, option.label)\n }\n return [{\n key: column.field.key,\n label: column.field.label,\n items: [{ label: t('composites.table.filter.all'), value: FILTER_ALL }, ...[...options].map(([value, label]) => ({ label, value }))],\n }]\n}))\n\n// A kind, tag or option that vanished from the document can no longer be unpicked in the UI, so it must not filter either.\nconst activeKinds = computed(() => pickedKinds.value.filter(id => kinds.value.some(kind => kind.id === id)))\nconst activeTags = computed(() => pickedTags.value.filter(tag => tags.value.includes(tag)))\nconst activeOptions = computed(() => selectFilters.value.flatMap((filter) => {\n const value = pickedOptions.value[filter.key]\n return value && filter.items.some(item => item.value === value && value !== FILTER_ALL) ? [[filter.key, value] as const] : []\n}))\nconst needle = computed(() => search.value.trim().toLowerCase())\nconst filterActive = computed(() => activeKinds.value.length > 0 || activeTags.value.length > 0 || activeOptions.value.length > 0 || needle.value !== '')\n\nfunction resetFilters() {\n search.value = ''\n pickedKinds.value = []\n pickedTags.value = []\n pickedOptions.value = {}\n}\n\nconst filtered = computed(() => rows.value.filter((row) => {\n if (activeKinds.value.length && !activeKinds.value.includes(row.kind)) return false\n if (activeTags.value.length && !activeTags.value.every(tag => row.tags.includes(tag))) return false\n if (activeOptions.value.some(([key, value]) => row.meta[key] !== value)) return false\n if (needle.value) {\n const haystack = `${row.title}\\n${row.description}\\n${row.tags.map(tag => `#${tag}`).join(' ')}`.toLowerCase()\n if (!haystack.includes(needle.value)) return false\n }\n return true\n}))\n\n// --- Sorting (client side; the table only reports the state, so the data is ordered here) -------------------------\n\nconst sorting = ref<{ id: string, desc: boolean }[]>([])\nconst activeSort = computed(() => {\n const entry = sorting.value[0]\n const spec = entry && specs.value.find(item => item.id === entry.id)\n return entry && spec ? { id: entry.id, desc: entry.desc, sort: spec.sort } : null\n})\n\n/** Header click cycles ascending → descending → unsorted. */\nfunction cycleSort(id: string) {\n const current = sorting.value[0]\n if (current?.id !== id) sorting.value = [{ id, desc: false }]\n else sorting.value = current.desc ? [] : [{ id, desc: true }]\n}\nconst sortIcon = (id: string) => {\n const current = sorting.value[0]\n if (current?.id !== id) return 'i-lucide-chevrons-up-down'\n return current.desc ? 'i-lucide-arrow-down' : 'i-lucide-arrow-up'\n}\n\nconst sorted = computed(() => {\n const sort = activeSort.value\n return sort ? sortRows(filtered.value, sort.sort, sort.desc) : filtered.value\n})\n\nconst countLabel = computed(() => t(rows.value.length === 1 ? 'composites.table.count.one' : 'composites.table.count.other', { n: sorted.value.length, total: rows.value.length }))\n</script>\n\n<template>\n <section class=\"flex min-h-0 flex-col gap-3\" :aria-label=\"t('composites.table.label')\">\n <div v-if=\"!rows.length\" class=\"mx-auto flex max-w-sm flex-1 flex-col items-center justify-center gap-2 py-16 text-center\">\n <UIcon name=\"i-lucide-table-2\" class=\"size-8 text-[var(--sk-fg-dimmed)]\" />\n <p class=\"text-sm font-medium text-[var(--sk-fg-highlighted)]\">\n {{ t('composites.table.emptyTitle') }}\n </p>\n <p class=\"text-sm text-[var(--sk-muted)]\">\n {{ t('composites.table.emptyText') }}\n </p>\n </div>\n\n <template v-else>\n <div class=\"flex flex-col gap-2\">\n <div class=\"flex flex-wrap items-center gap-2\">\n <UInput\n v-model=\"search\"\n class=\"w-64\"\n size=\"sm\"\n icon=\"i-lucide-search\"\n :placeholder=\"t('composites.table.search.placeholder')\"\n :aria-label=\"t('composites.table.search.label')\"\n >\n <template v-if=\"search\" #trailing>\n <UButton\n color=\"neutral\"\n variant=\"link\"\n size=\"xs\"\n icon=\"i-lucide-x\"\n :aria-label=\"t('composites.table.search.clear')\"\n @click=\"search = ''\"\n />\n </template>\n </UInput>\n\n <div v-for=\"filter in selectFilters\" :key=\"filter.key\" class=\"flex items-center gap-1.5\">\n <span class=\"text-sm text-[var(--sk-muted)]\" aria-hidden=\"true\">{{ filter.label }}</span>\n <USelect\n :model-value=\"pickedOptions[filter.key] ?? FILTER_ALL\"\n class=\"w-36\"\n size=\"sm\"\n :items=\"filter.items\"\n :aria-label=\"filter.label\"\n @update:model-value=\"pickedOptions = { ...pickedOptions, [filter.key]: String($event) }\"\n />\n </div>\n\n <UButton\n v-if=\"filterActive\"\n size=\"sm\"\n color=\"neutral\"\n variant=\"ghost\"\n icon=\"i-lucide-filter-x\"\n :label=\"t('composites.table.filter.reset')\"\n @click=\"resetFilters\"\n />\n <span class=\"ml-auto text-xs tabular-nums text-[var(--sk-muted)]\" role=\"status\">{{ countLabel }}</span>\n </div>\n\n <div v-if=\"kinds.length > 1\" class=\"flex flex-wrap items-center gap-1\" role=\"group\" :aria-label=\"t('composites.table.filter.byKind')\">\n <UButton\n v-for=\"kind in kinds\"\n :key=\"kind.id\"\n size=\"xs\"\n color=\"neutral\"\n :variant=\"activeKinds.includes(kind.id) ? 'solid' : 'outline'\"\n :icon=\"kind.icon\"\n :label=\"kind.label\"\n :aria-pressed=\"activeKinds.includes(kind.id)\"\n @click=\"pickedKinds = toggled(pickedKinds, kind.id)\"\n />\n </div>\n\n <div v-if=\"tags.length\" class=\"flex flex-wrap items-center gap-1\" role=\"group\" :aria-label=\"t('composites.table.filter.byTag')\">\n <UButton\n v-for=\"tag in tags\"\n :key=\"tag\"\n size=\"xs\"\n color=\"neutral\"\n :variant=\"activeTags.includes(tag) ? 'solid' : 'outline'\"\n :label=\"`#${tag}`\"\n :aria-pressed=\"activeTags.includes(tag)\"\n @click=\"pickedTags = toggled(pickedTags, tag)\"\n />\n </div>\n </div>\n\n <UTable\n v-model:sorting=\"sorting\"\n :data=\"sorted\"\n :columns=\"columns\"\n :get-row-id=\"(row: CompositeRow) => row.key\"\n :ui=\"{ th: 'px-3 py-2 text-sm', td: 'px-3 py-2' }\"\n sticky\n class=\"min-h-0 flex-1 rounded-md border border-[var(--sk-border)]\"\n @select=\"(_event: Event, row: { original: CompositeRow }) => emit('select', row.original)\"\n >\n <template v-for=\"spec in specs\" :key=\"spec.id\" #[`${spec.id}-header`]>\n <button\n type=\"button\"\n class=\"-mx-1.5 inline-flex cursor-pointer items-center gap-1 rounded px-1.5 py-0.5 font-semibold hover:bg-[var(--sk-bg-elevated)] focus-visible:outline-2 focus-visible:outline-[var(--sk-primary)]\"\n @click=\"cycleSort(spec.id)\"\n >\n {{ spec.label }}\n <UIcon :name=\"sortIcon(spec.id)\" class=\"size-3.5\" :class=\"activeSort?.id === spec.id ? 'text-[var(--sk-fg-highlighted)]' : 'text-[var(--sk-fg-dimmed)]'\" />\n </button>\n </template>\n\n <template #title-cell=\"{ row }: { row: { original: CompositeRow } }\">\n <div class=\"flex min-w-0 items-center gap-1.5\" :style=\"{ paddingLeft: `${row.original.depth * 1.25}rem` }\">\n <UIcon :name=\"row.original.icon\" class=\"size-4 shrink-0 text-[var(--sk-muted)]\" />\n <span v-if=\"hasText(row.original.title)\" class=\"truncate font-medium text-[var(--sk-fg-highlighted)]\">{{ row.original.title }}</span>\n <span v-else class=\"truncate text-[var(--sk-muted)]\">{{ t('composites.untitled') }}</span>\n </div>\n </template>\n <template #kind-cell=\"{ row }: { row: { original: CompositeRow } }\">\n {{ row.original.kindLabel }}\n </template>\n <template v-for=\"column in fieldColumns\" :key=\"column.id\" #[`${column.id}-cell`]=\"{ row }: { row: { original: CompositeRow } }\">\n <span\n v-if=\"fieldText(row.original, column.field.key, fieldContext)\"\n class=\"block\"\n :class=\"[column.field.type === 'number' || column.field.type === 'date' ? 'tabular-nums' : '', isLongText(column.field) ? 'max-w-64 truncate' : '']\"\n :title=\"isLongText(column.field) ? fieldText(row.original, column.field.key, fieldContext) : undefined\"\n >{{ fieldText(row.original, column.field.key, fieldContext) }}</span>\n <template v-else>\n <span class=\"text-[var(--sk-fg-dimmed)]\" aria-hidden=\"true\">–</span>\n <span class=\"sr-only\">{{ t('composites.table.noValue') }}</span>\n </template>\n </template>\n <template #tags-cell=\"{ row }: { row: { original: CompositeRow } }\">\n <div v-if=\"row.original.tags.length\" class=\"flex flex-wrap gap-1\">\n <UBadge v-for=\"tag in row.original.tags\" :key=\"tag\" color=\"neutral\" variant=\"subtle\" size=\"sm\" :label=\"`#${tag}`\" />\n </div>\n <template v-else>\n <span class=\"text-[var(--sk-fg-dimmed)]\" aria-hidden=\"true\">–</span>\n <span class=\"sr-only\">{{ t('composites.table.noTags') }}</span>\n </template>\n </template>\n <template #summary-cell=\"{ row }: { row: { original: CompositeRow } }\">\n <template v-if=\"hasText(row.original.description)\">\n <span class=\"inline-block size-2 rounded-full bg-[var(--sk-primary)]\" aria-hidden=\"true\" :title=\"row.original.description\" />\n <span class=\"sr-only\">{{ t('composites.table.summaryPresent') }}</span>\n </template>\n <template v-else>\n <span class=\"text-[var(--sk-fg-dimmed)]\" aria-hidden=\"true\">–</span>\n <span class=\"sr-only\">{{ t('composites.summary.none') }}</span>\n </template>\n </template>\n\n <template #empty>\n <div class=\"flex flex-col items-center gap-2 py-6\">\n <p class=\"text-sm text-[var(--sk-muted)]\">\n {{ t('composites.table.filter.noMatch') }}\n </p>\n <UButton\n size=\"sm\"\n color=\"neutral\"\n variant=\"outline\"\n icon=\"i-lucide-filter-x\"\n :label=\"t('composites.table.filter.reset')\"\n @click=\"resetFilters\"\n />\n </div>\n </template>\n </UTable>\n </template>\n </section>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAaA,MAAM,QAAQ;EACd,MAAM,OAAO;EAEb,MAAM,EAAE,OAAO,QAAQ,QAAQ,SAAS,MAAM,OAAO,OAAO,QAAQ,QAAQ,SAAS,OAAO,WAAW,SAAS;EAChH,MAAM,EAAE,MAAM,cAAc;EAE5B,MAAM,EAAE,MAAM,MAAM,UAAU,uBAAuB,MAAM,MAAM;EAKjE,MAAM,eAAe,eAAyC;GAC5D,KAAU;GACV,OAAO,MAAM,SAAS;IAAE,KAAK,MAAM,OAAO,MAAM;IAAK,OAAO,aAAa,MAAM,MAAM;IAAG;GAAE,IAAI,KAAA;EAChG,CAAC;EACD,MAAM,eAAe,eAAe,eAAe,KAAK,OAAO,MAAM,OAAO,aAAa,KAAK,CAAC;EAC/F,MAAM,QAAQ,eAAe,cAAc,aAAa,OAAO,CAAC,CAAC;EAEjE,MAAM,UAAU,eAA4C,MAAM,MAAM,KAAI,UAAS;GACnF,IAAI,KAAK;GACT,QAAQ,KAAK;GACb,YAAY,KAAK;GAEjB,eAAe;GACf,MAAM,EAAE,OAAO;IACb,IAAI,CAAC,KAAK,OAAO,UAAU,aAAa,IAAI,KAAK,UAAU,QAAQ,eAAe,EAAE,CAAC,CAAC,KAAK,GAAG;IAC9F,IAAI,KAAK,UAAU,QAAQ,eAAe;GAC5C,EAAE;EACJ,EAAE,CAAC;EAIH,MAAM,SAAS,IAAI,EAAE;EACrB,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N,MAAA,SAAA,CAAS,CAAC,IAAI,UAAU,OAAO,MAAM,KAAK,aAAA,KAAY,KAD9DF,UAAA,GAAAC,mBAKqE,QAAA;;MAHnE,OAAKa,eAAA,CAAC,SAAO,CACJ,OAAO,MAAM,SAAI,YAAiB,OAAO,MAAM,SAAI,SAAA,iBAAA,IAAmCZ,MAAA,UAAA,CAAU,CAAC,OAAO,KAAK,IAAA,sBAAA,EAAA,CAAA,CAAA;MACrH,OAAOA,MAAA,UAAA,CAAU,CAAC,OAAO,KAAK,IAAIA,MAAA,SAAA,CAAS,CAAC,IAAI,UAAU,OAAO,MAAM,KAAK,aAAA,KAAY,IAAI,KAAA;KAC3F,GAAAG,gBAAAH,MAAA,SAAA,CAAS,CAAC,IAAI,UAAU,OAAO,MAAM,KAAK,aAAA,KAAY,CAAA,GAAA,IAAA,WAAA,MAC1DF,UAAA,GAAAC,mBAGWK,UAAA,EAAA,KAAA,EAAA,GAAA,CAFT,OAAA,OAAA,OAAA,KAAAF,mBAAoE,QAAA;MAA9D,OAAM;MAA6B,eAAY;KAAO,GAAA,KAAC,EAAA,IAC7DA,mBAAgE,QAAhE,aAAgEC,gBAAvCH,MAAA,CAAA,CAAC,CAAA,0BAAA,CAAA,GAAA,CAAA,CAAA,GAAA,EAAA,EAAA,CAAA"}
|
|
@@ -6,7 +6,7 @@ import { useEditorI18n } from "../../../vue/use-editor-i18n.js";
|
|
|
6
6
|
import { setCompositeTags } from "../rows.js";
|
|
7
7
|
import { Fragment, createCommentVNode, createElementBlock, createTextVNode, createVNode, defineComponent, onBeforeUnmount, openBlock, ref, toDisplayString, unref, watch, withCtx } from "vue";
|
|
8
8
|
//#region src/features/composites/components/CompositeTagsEditor.vue
|
|
9
|
-
/** Tags of one
|
|
9
|
+
/** Tags of one Typed block as an input menu with suggestions from the metadata registry, writing through `setCompositeTags`. */
|
|
10
10
|
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
11
11
|
__name: "CompositeTagsEditor",
|
|
12
12
|
props: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CompositeTagsEditor.js","names":["_openBlock","_createElementBlock","_Fragment","_createCommentVNode","_createVNode","_unref","_withCtx","_createTextVNode","_toDisplayString"],"sources":["../../../../src/features/composites/components/CompositeTagsEditor.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Editor } from '@tiptap/core'\nimport { onBeforeUnmount, ref, watch } from 'vue'\nimport { metadataOf } from '../../../core/metadata'\nimport { METADATA_LIST } from '../../../core/metadata-types'\nimport { normalizeTagName } from '../../../core/tag-name'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { type CompositeRow, setCompositeTags } from '../rows'\n\n/** Tags of one
|
|
1
|
+
{"version":3,"file":"CompositeTagsEditor.js","names":["_openBlock","_createElementBlock","_Fragment","_createCommentVNode","_createVNode","_unref","_withCtx","_createTextVNode","_toDisplayString"],"sources":["../../../../src/features/composites/components/CompositeTagsEditor.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Editor } from '@tiptap/core'\nimport { onBeforeUnmount, ref, watch } from 'vue'\nimport { metadataOf } from '../../../core/metadata'\nimport { METADATA_LIST } from '../../../core/metadata-types'\nimport { normalizeTagName } from '../../../core/tag-name'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { type CompositeRow, setCompositeTags } from '../rows'\n\n/** Tags of one Typed block as an input menu with suggestions from the metadata registry, writing through `setCompositeTags`. */\nconst props = defineProps<{ editor: Editor, row: CompositeRow }>()\n\nconst { InputMenu: UInputMenu } = useUiKit()\nconst { t } = useEditorI18n()\n\nconst term = ref('')\nconst items = ref<string[]>([])\n// Suggestions are loaded when the menu opens and 150 ms after typing pauses; a newer search aborts the older one.\nlet timer: ReturnType<typeof setTimeout> | undefined\nlet pending: AbortController | undefined\n\nfunction scheduleSearch() {\n clearTimeout(timer)\n timer = setTimeout(async () => {\n pending?.abort()\n const controller = pending = new AbortController()\n try {\n const found = await metadataOf(props.editor).search(METADATA_LIST.hashtags, { query: term.value, editor: props.editor, signal: controller.signal })\n if (!controller.signal.aborted) items.value = found.map(item => item.label)\n }\n catch (error) {\n if (!controller.signal.aborted) console.warn('Tag-Vorschläge konnten nicht geladen werden', error)\n }\n }, 150)\n}\nwatch(term, scheduleSearch)\nonBeforeUnmount(() => {\n clearTimeout(timer)\n pending?.abort()\n})\n\nfunction onTags(value: unknown) {\n setCompositeTags(props.editor, props.row, Array.isArray(value) ? value.filter((tag): tag is string => typeof tag === 'string') : [])\n}\n\n// „Neu Tag“ → `neu-tag`; a name that is already set is ignored.\nfunction onCreate(raw: string) {\n const name = normalizeTagName(raw)\n term.value = ''\n if (!name || props.row.tags.includes(name)) return\n setCompositeTags(props.editor, props.row, [...props.row.tags, name])\n if (!items.value.includes(name)) metadataOf(props.editor).create(METADATA_LIST.hashtags, { id: name, label: name })\n}\n</script>\n\n<template>\n <!-- `position` is required in the object form of `create-item`: InputMenu renders the create row only for 'top' or 'bottom'. -->\n <UInputMenu\n v-model:search-term=\"term\"\n multiple\n :create-item=\"{ position: 'bottom', when: 'always' }\"\n :model-value=\"row.tags\"\n :items=\"items\"\n ignore-filter\n :placeholder=\"t('composites.tags.placeholder')\"\n :aria-label=\"t('composites.tags.label')\"\n size=\"sm\"\n icon=\"i-lucide-hash\"\n class=\"w-full\"\n @update:model-value=\"onTags\"\n @update:open=\"(open: boolean) => open && scheduleSearch()\"\n @create=\"onCreate\"\n >\n <template #create-item-label=\"{ item }: { item: string }\">\n {{ t('composites.tags.create', { tag: normalizeTagName(item) || item }) }}\n </template>\n </UInputMenu>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;EAWA,MAAM,QAAQ;EAEd,MAAM,EAAE,WAAW,eAAe,SAAS;EAC3C,MAAM,EAAE,MAAM,cAAc;EAE5B,MAAM,OAAO,IAAI,EAAE;EACnB,MAAM,QAAQ,IAAc,CAAC,C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A,OAAA,OAAA,MAAA,WAAA,KAAI,QAAA;IACzB,UAAA;IACC,eAAa;KAAA,UAAA;KAAA,MAAA;IAAA;IACb,eAAa,QAAA,IAAI;IACjB,OAAO,MAAA;IACR,iBAAA;IACC,aAAaA,MAAA,CAAA,CAAC,CAAA,6BAAA;IACd,cAAYA,MAAA,CAAA,CAAC,CAAA,uBAAA;IACd,MAAK;IACL,MAAK;IACL,OAAM;IACL,uBAAoB;IACpB,iBAAW,OAAA,OAAA,OAAA,MAAG,SAAkB,QAAQ,eAAc;IAC9C;;IAEE,qBAAiBC,SACgD,EAD5C,WAAI,CAC/BC,gBAAAC,gBAAAH,MAAA,CAAA,CAAC,CAAA,0BAAA,EAAA,KAAkCA,MAAA,gBAAA,CAAgB,CAAC,IAAI,KAAK,KAAI,CAAA,CAAA,GAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CompositeRow } from "../rows.js";
|
|
2
2
|
import { Editor } from "@tiptap/core";
|
|
3
3
|
//#region src/features/composites/components/CompositeTagsEditor.vue.d.ts
|
|
4
|
-
/** Tags of one
|
|
4
|
+
/** Tags of one Typed block as an input menu with suggestions from the metadata registry, writing through `setCompositeTags`. */
|
|
5
5
|
type __VLS_Props = {
|
|
6
6
|
editor: Editor;
|
|
7
7
|
row: CompositeRow;
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { derivationOf } from "
|
|
4
|
-
import {
|
|
1
|
+
import { capabilityDataOf } from "../../../core/capabilities.js";
|
|
2
|
+
import { TYPED_BLOCK_CLASS } from "../../../core/schema/persisted-names.js";
|
|
3
|
+
import { derivationOf } from "../../../core/derivation.js";
|
|
4
|
+
import { blockTypeOf } from "../block-types.js";
|
|
5
|
+
import { titleHiddenOf } from "../baskets.js";
|
|
6
|
+
import { blockTypesOf, compositeBasketsOf } from "../nodes.js";
|
|
5
7
|
import { useStoreRef } from "../../../vue/store-ref.js";
|
|
6
8
|
import { computed, createBlock, createCommentVNode, createElementVNode, createVNode, defineComponent, normalizeClass, normalizeStyle, openBlock, unref, withCtx } from "vue";
|
|
7
9
|
import { NodeViewContent, NodeViewWrapper, nodeViewProps } from "@tiptap/vue-3";
|
|
@@ -11,16 +13,16 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
11
13
|
props: nodeViewProps,
|
|
12
14
|
setup(__props) {
|
|
13
15
|
const props = __props;
|
|
14
|
-
const kind = computed(() =>
|
|
15
|
-
const expanded = useStoreRef(() => props.editor.storage.
|
|
16
|
+
const kind = computed(() => blockTypeOf(blockTypesOf(props.editor), String(props.node.attrs.blockType)));
|
|
17
|
+
const expanded = useStoreRef(() => props.editor.storage.typedBlock.expanded);
|
|
16
18
|
const collapsed = computed(() => {
|
|
17
19
|
const id = props.node.attrs.id;
|
|
18
20
|
return typeof id === "string" && id !== "" && derivationOf(props.node) !== null && !expanded.value.has(id);
|
|
19
21
|
});
|
|
20
|
-
const basket = computed(() =>
|
|
22
|
+
const basket = computed(() => capabilityDataOf(props.editor, props.node, "basket"));
|
|
21
23
|
const basketColor = computed(() => compositeBasketsOf(props.editor).find((candidate) => candidate.id === basket.value)?.color);
|
|
22
|
-
const
|
|
23
|
-
const revealedTitles = useStoreRef(() => props.editor.storage.
|
|
24
|
+
const blockTypeTone = computed(() => kind.value.chrome?.tone || void 0);
|
|
25
|
+
const revealedTitles = useStoreRef(() => props.editor.storage.typedBlock.revealedTitles);
|
|
24
26
|
const titleHidden = computed(() => {
|
|
25
27
|
const id = props.node.attrs.id;
|
|
26
28
|
return titleHiddenOf(props.node) && !(typeof id === "string" && revealedTitles.value.has(id));
|
|
@@ -28,22 +30,22 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
28
30
|
/** `text` as a CSS string literal (for `content:`). */
|
|
29
31
|
const cssString = (text) => `"${text.replace(/["\\]/g, "\\$&").replace(/\n/g, "\\a ")}"`;
|
|
30
32
|
const placeholderVars = computed(() => ({
|
|
31
|
-
"--composite-title-placeholder": cssString(kind.value.titlePlaceholder),
|
|
33
|
+
"--composite-title-placeholder": cssString(kind.value.titlePlaceholder ?? ""),
|
|
32
34
|
...basketColor.value ? { "--sk-basket-color": basketColor.value } : {},
|
|
33
|
-
...
|
|
35
|
+
...blockTypeTone.value ? { "--sk-block-type-tone": blockTypeTone.value } : {}
|
|
34
36
|
}));
|
|
35
37
|
return (_ctx, _cache) => {
|
|
36
38
|
return openBlock(), createBlock(unref(NodeViewWrapper), {
|
|
37
39
|
as: "section",
|
|
38
|
-
class: normalizeClass([
|
|
40
|
+
class: normalizeClass([unref(TYPED_BLOCK_CLASS), {
|
|
39
41
|
"is-collapsed": collapsed.value,
|
|
40
42
|
"is-selected rounded-md ring-1 ring-[var(--sk-primary)]": _ctx.selected
|
|
41
43
|
}]),
|
|
42
|
-
"data-type": "
|
|
43
|
-
"data-
|
|
44
|
+
"data-type": "typedBlock",
|
|
45
|
+
"data-block-type": _ctx.node.attrs.blockType,
|
|
44
46
|
"data-id": _ctx.node.attrs.id || void 0,
|
|
45
47
|
"data-basket": basket.value || void 0,
|
|
46
|
-
"data-
|
|
48
|
+
"data-block-type-tone": blockTypeTone.value ? "" : void 0,
|
|
47
49
|
"data-title-hidden": titleHidden.value ? "" : void 0,
|
|
48
50
|
style: normalizeStyle(placeholderVars.value)
|
|
49
51
|
}, {
|
|
@@ -59,10 +61,10 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
59
61
|
_: 1
|
|
60
62
|
}, 8, [
|
|
61
63
|
"class",
|
|
62
|
-
"data-
|
|
64
|
+
"data-block-type",
|
|
63
65
|
"data-id",
|
|
64
66
|
"data-basket",
|
|
65
|
-
"data-
|
|
67
|
+
"data-block-type-tone",
|
|
66
68
|
"data-title-hidden",
|
|
67
69
|
"style"
|
|
68
70
|
]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CompositeView.js","names":["selected","node","_openBlock","_createBlock","_unref","_normalizeClass","_normalizeStyle","_withCtx","_createCommentVNode","_createElementVNode","_createVNode"],"sources":["../../../../src/features/composites/components/CompositeView.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { NodeViewContent, NodeViewWrapper, nodeViewProps } from '@tiptap/vue-3'\nimport { computed } from 'vue'\nimport {
|
|
1
|
+
{"version":3,"file":"CompositeView.js","names":["selected","node","_openBlock","_createBlock","_unref","_normalizeClass","_normalizeStyle","_withCtx","_createCommentVNode","_createElementVNode","_createVNode"],"sources":["../../../../src/features/composites/components/CompositeView.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { NodeViewContent, NodeViewWrapper, nodeViewProps } from '@tiptap/vue-3'\nimport { computed } from 'vue'\nimport { capabilityDataOf } from '../../../core/capabilities'\nimport { titleHiddenOf } from '../baskets'\nimport { blockTypeOf } from '../block-types'\nimport { compositeBasketsOf, blockTypesOf } from '../nodes'\nimport { useStoreRef } from '../../../vue/store-ref'\nimport { derivationOf } from '../../../core/derivation'\nimport { TYPED_BLOCK_CLASS } from '../../../core/schema/persisted-names'\n\nconst props = defineProps(nodeViewProps)\n\nconst kind = computed(() => blockTypeOf(blockTypesOf(props.editor), String(props.node.attrs.blockType)))\n\n// A derived Typed block (one with a `meta.derivation`) shows collapsed to a faded preview until it is opened; the content\n// stays laid out (CSS clips it), so editing positions are unaffected. The chrome's chevron and a caret inside open it.\nconst expanded = useStoreRef(() => props.editor.storage.typedBlock.expanded)\nconst collapsed = computed(() => {\n const id: unknown = props.node.attrs.id\n return typeof id === 'string' && id !== '' && derivationOf(props.node) !== null && !expanded.value.has(id)\n})\n\n// Colour basket (`meta.basket`): `data-basket` carries the id, the stripe takes the basket's colour from `--sk-basket-color`.\nconst basket = computed(() => capabilityDataOf<string>(props.editor, props.node, 'basket'))\nconst basketColor = computed(() => compositeBasketsOf(props.editor).find(candidate => candidate.id === basket.value)?.color)\n\n// Block type tone (`BlockType.chrome.tone`): `data-block-type-tone` marks the wrapper, the surface reads the colour from `--sk-block-type-tone`.\nconst blockTypeTone = computed(() => kind.value.chrome?.tone || undefined)\n\n// A hidden title (`meta.titleHidden`) stays hidden until a caret enters it (`revealedTitles`, see `CompositeNode`).\nconst revealedTitles = useStoreRef(() => props.editor.storage.typedBlock.revealedTitles)\nconst titleHidden = computed(() => {\n const id: unknown = props.node.attrs.id\n return titleHiddenOf(props.node) && !(typeof id === 'string' && revealedTitles.value.has(id))\n})\n\n/** `text` as a CSS string literal (for `content:`). */\nconst cssString = (text: string) => `\"${text.replace(/[\"\\\\]/g, '\\\\$&').replace(/\\n/g, '\\\\a ')}\"`\n// Placeholder of the empty title (composites.css `content: var(…)`); a nested composite sets its own.\nconst placeholderVars = computed(() => ({\n '--composite-title-placeholder': cssString(kind.value.titlePlaceholder ?? ''),\n ...(basketColor.value ? { '--sk-basket-color': basketColor.value } : {}),\n ...(blockTypeTone.value ? { '--sk-block-type-tone': blockTypeTone.value } : {}),\n}))\n</script>\n\n<template>\n <NodeViewWrapper\n as=\"section\"\n :class=\"[TYPED_BLOCK_CLASS, { 'is-collapsed': collapsed, 'is-selected rounded-md ring-1 ring-[var(--sk-primary)]': selected }]\"\n data-type=\"typedBlock\"\n :data-block-type=\"node.attrs.blockType\"\n :data-id=\"node.attrs.id || undefined\"\n :data-basket=\"basket || undefined\"\n :data-block-type-tone=\"blockTypeTone ? '' : undefined\"\n :data-title-hidden=\"titleHidden ? '' : undefined\"\n :style=\"placeholderVars\"\n >\n <!-- Anchor of the kind icon on the left border: it only takes the icon's place and size. The composite chrome overlay\n measures it and draws the icon as the button that opens the details popover and drags the composite. -->\n <span class=\"composite__toggle\" contenteditable=\"false\" aria-hidden=\"true\" />\n <NodeViewContent class=\"composite__content\" />\n </NodeViewWrapper>\n</template>\n"],"mappings":";;;;;;;;;;;;;;EAWA,MAAM,QAAQ;EAEd,MAAM,OAAO,eAAe,YAAY,aAAa,MAAM,MAAM,GAAG,OAAO,MAAM,KAAK,MAAM,SAAS,CAAC,CAAC;EAIvG,MAAM,WAAW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,WAASA,KAAAA,KAAK,MAAM,MAAM,KAAA;IAC1B,eAAa,OAAA,SAAU,KAAA;IACvB,wBAAsB,cAAA,QAAa,KAAQ,KAAA;IAC3C,qBAAmB,YAAA,QAAW,KAAQ,KAAA;IACtC,OAAKK,eAAE,gBAAA,KAAe;;IAEvB,SAAAC,cAC6G;KAD7GC,mBAAA,oOAAA;KAEA,OAAA,OAAA,OAAA,KAAAC,mBAA6E,QAAA;MAAvE,OAAM;MAAoB,iBAAgB;MAAQ,eAAY;;KACpEC,YAA8CN,MAAA,eAAA,GAAA,EAA7B,OAAM,qBAAoB,CAAA"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { derivationOf } from "
|
|
1
|
+
import { derivationOf } from "../../../core/derivation.js";
|
|
2
2
|
import { useUiKit } from "../../../vue/kit/use-ui-kit.js";
|
|
3
3
|
import { useEditorI18n } from "../../../vue/use-editor-i18n.js";
|
|
4
|
-
import { derivationDetailsOf, derivationIsForeign, derivationMethodLabel } from "../derived-chrome.js";
|
|
4
|
+
import { derivationDetailsOf, derivationIsForeign, derivationMethodLabel, isSourceMissing } from "../derived-chrome.js";
|
|
5
5
|
import { formatDate } from "../meta-display.js";
|
|
6
6
|
import { Fragment, computed, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, normalizeClass, openBlock, toDisplayString, unref } from "vue";
|
|
7
7
|
//#region src/features/composites/components/DerivationBadge.vue
|
|
@@ -24,10 +24,10 @@ const _hoisted_10 = { class: "text-[var(--sk-muted)]" };
|
|
|
24
24
|
const _hoisted_11 = { class: "text-[var(--sk-fg)]" };
|
|
25
25
|
const _hoisted_12 = ["href"];
|
|
26
26
|
/**
|
|
27
|
-
* Where a derived
|
|
27
|
+
* Where a derived Typed block comes from. Compact (the `derivation` field type): the „abgeleitet“ badge with method and
|
|
28
28
|
* date. `detailed` (the details card): also the model, whether the source changed („Quelle geändert“), whether the body
|
|
29
29
|
* was edited since it was generated („bearbeitet“) and a link to the stored raw output. The detailed variant hashes
|
|
30
|
-
* the body, so it belongs only where one
|
|
30
|
+
* the body, so it belongs only where one Typed block is shown.
|
|
31
31
|
*/
|
|
32
32
|
const chip = "inline-flex h-5 shrink-0 items-center gap-1 rounded-sm px-1.5 text-xs leading-none whitespace-nowrap";
|
|
33
33
|
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
@@ -45,6 +45,7 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
45
45
|
const details = computed(() => props.detailed ? derivationDetailsOf(props.editor, props.node) : null);
|
|
46
46
|
const method = computed(() => derivation.value ? derivationMethodLabel(t, derivation.value.method) : "");
|
|
47
47
|
const foreign = computed(() => derivation.value ? derivationIsForeign(props.editor, derivation.value) : false);
|
|
48
|
+
const sourceMissing = computed(() => derivation.value ? isSourceMissing(props.editor, props.node) : false);
|
|
48
49
|
const created = computed(() => derivation.value?.createdAt ? formatDate(derivation.value.createdAt) : "");
|
|
49
50
|
return (_ctx, _cache) => {
|
|
50
51
|
return derivation.value && !__props.detailed ? (openBlock(), createElementBlock("div", _hoisted_1, [createVNode(unref(UIcon), {
|
|
@@ -54,6 +55,7 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
54
55
|
unref(t)("composites.derivation.badge"),
|
|
55
56
|
method.value,
|
|
56
57
|
foreign.value ? unref(t)("composites.derivation.foreign") : "",
|
|
58
|
+
sourceMissing.value ? unref(t)("composites.derivation.sourceMissing") : "",
|
|
57
59
|
created.value
|
|
58
60
|
].filter(Boolean).join(" · ")), 1)])) : derivation.value && details.value ? (openBlock(), createElementBlock("div", _hoisted_3, [
|
|
59
61
|
createElementVNode("div", _hoisted_4, [
|
|
@@ -68,15 +70,22 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
68
70
|
name: "i-lucide-file-symlink",
|
|
69
71
|
class: "size-3.5"
|
|
70
72
|
}), createTextVNode(toDisplayString(unref(t)("composites.derivation.foreign")), 1)], 2)) : createCommentVNode("v-if", true),
|
|
71
|
-
details.value.
|
|
73
|
+
details.value.sourceMissing ? (openBlock(), createElementBlock("span", {
|
|
72
74
|
key: 1,
|
|
73
75
|
class: normalizeClass([chip, "text-[var(--sk-warning)]"])
|
|
76
|
+
}, [createVNode(unref(UIcon), {
|
|
77
|
+
name: "i-lucide-unlink",
|
|
78
|
+
class: "size-3.5"
|
|
79
|
+
}), createTextVNode(toDisplayString(unref(t)("composites.derivation.sourceMissing")), 1)], 2)) : createCommentVNode("v-if", true),
|
|
80
|
+
details.value.stale ? (openBlock(), createElementBlock("span", {
|
|
81
|
+
key: 2,
|
|
82
|
+
class: normalizeClass([chip, "text-[var(--sk-warning)]"])
|
|
74
83
|
}, [createVNode(unref(UIcon), {
|
|
75
84
|
name: "i-lucide-triangle-alert",
|
|
76
85
|
class: "size-3.5"
|
|
77
86
|
}), createTextVNode(toDisplayString(unref(t)("composites.derivation.stale")), 1)], 2)) : createCommentVNode("v-if", true),
|
|
78
87
|
details.value.edited ? (openBlock(), createElementBlock("span", {
|
|
79
|
-
key:
|
|
88
|
+
key: 3,
|
|
80
89
|
class: normalizeClass([chip, "text-[var(--sk-muted)]"])
|
|
81
90
|
}, [createVNode(unref(UIcon), {
|
|
82
91
|
name: "i-lucide-pencil",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DerivationBadge.js","names":["_openBlock","_createElementBlock","_createVNode","_unref","_createElementVNode","_toDisplayString","_normalizeClass","_createTextVNode","_createCommentVNode","_Fragment"],"sources":["../../../../src/features/composites/components/DerivationBadge.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Node as ProseMirrorNode } from '@tiptap/pm/model'\nimport type { Editor } from '@tiptap/core'\nimport { computed } from 'vue'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { derivationOf } from '
|
|
1
|
+
{"version":3,"file":"DerivationBadge.js","names":["_openBlock","_createElementBlock","_createVNode","_unref","_createElementVNode","_toDisplayString","_normalizeClass","_createTextVNode","_createCommentVNode","_Fragment"],"sources":["../../../../src/features/composites/components/DerivationBadge.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Node as ProseMirrorNode } from '@tiptap/pm/model'\nimport type { Editor } from '@tiptap/core'\nimport { computed } from 'vue'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { derivationOf } from '../../../core/derivation'\nimport { derivationDetailsOf, derivationIsForeign, derivationMethodLabel, isSourceMissing } from '../derived-chrome'\nimport { formatDate } from '../meta-display'\n\n/**\n * Where a derived Typed block comes from. Compact (the `derivation` field type): the „abgeleitet“ badge with method and\n * date. `detailed` (the details card): also the model, whether the source changed („Quelle geändert“), whether the body\n * was edited since it was generated („bearbeitet“) and a link to the stored raw output. The detailed variant hashes\n * the body, so it belongs only where one Typed block is shown.\n */\nconst props = defineProps<{ editor: Editor, node: ProseMirrorNode, detailed?: boolean }>()\n\nconst { Icon: UIcon } = useUiKit()\nconst { t } = useEditorI18n()\n\nconst derivation = computed(() => derivationOf(props.node))\nconst details = computed(() => props.detailed ? derivationDetailsOf(props.editor, props.node) : null)\nconst method = computed(() => derivation.value ? derivationMethodLabel(t, derivation.value.method) : '')\nconst foreign = computed(() => derivation.value ? derivationIsForeign(props.editor, derivation.value) : false)\nconst sourceMissing = computed(() => derivation.value ? isSourceMissing(props.editor, props.node) : false)\nconst created = computed(() => derivation.value?.createdAt ? formatDate(derivation.value.createdAt) : '')\n\nconst chip = 'inline-flex h-5 shrink-0 items-center gap-1 rounded-sm px-1.5 text-xs leading-none whitespace-nowrap'\n</script>\n\n<template>\n <div v-if=\"derivation && !detailed\" class=\"flex min-w-0 items-center gap-1.5 text-xs text-[var(--sk-muted)]\">\n <UIcon name=\"i-lucide-git-branch\" class=\"size-3.5 shrink-0\" />\n <span class=\"truncate\">{{ [t('composites.derivation.badge'), method, foreign ? t('composites.derivation.foreign') : '', sourceMissing ? t('composites.derivation.sourceMissing') : '', created].filter(Boolean).join(' · ') }}</span>\n </div>\n\n <div v-else-if=\"derivation && details\" class=\"flex flex-col gap-1.5 rounded-md p-2 text-xs ring ring-[var(--sk-border)]\">\n <div class=\"flex flex-wrap items-center gap-1\">\n <span :class=\"[chip, 'text-[var(--sk-muted)]']\">\n <UIcon name=\"i-lucide-git-branch\" class=\"size-3.5\" />{{ t('composites.derivation.badge') }}\n </span>\n <span v-if=\"details.foreign\" :class=\"[chip, 'text-[var(--sk-muted)]']\">\n <UIcon name=\"i-lucide-file-symlink\" class=\"size-3.5\" />{{ t('composites.derivation.foreign') }}\n </span>\n <span v-if=\"details.sourceMissing\" :class=\"[chip, 'text-[var(--sk-warning)]']\">\n <UIcon name=\"i-lucide-unlink\" class=\"size-3.5\" />{{ t('composites.derivation.sourceMissing') }}\n </span>\n <span v-if=\"details.stale\" :class=\"[chip, 'text-[var(--sk-warning)]']\">\n <UIcon name=\"i-lucide-triangle-alert\" class=\"size-3.5\" />{{ t('composites.derivation.stale') }}\n </span>\n <span v-if=\"details.edited\" :class=\"[chip, 'text-[var(--sk-muted)]']\">\n <UIcon name=\"i-lucide-pencil\" class=\"size-3.5\" />{{ t('composites.derivation.edited') }}\n </span>\n </div>\n <dl class=\"grid grid-cols-[auto_1fr] gap-x-2 gap-y-0.5\">\n <dt class=\"text-[var(--sk-muted)]\">{{ t('composites.derivation.method') }}</dt>\n <dd class=\"truncate text-[var(--sk-fg)]\">{{ method }}</dd>\n <template v-if=\"derivation.model\">\n <dt class=\"text-[var(--sk-muted)]\">{{ t('composites.derivation.model') }}</dt>\n <dd class=\"truncate text-[var(--sk-fg)]\" :title=\"derivation.model\">{{ derivation.model }}</dd>\n </template>\n <template v-if=\"created\">\n <dt class=\"text-[var(--sk-muted)]\">{{ t('composites.derivation.createdAt') }}</dt>\n <dd class=\"text-[var(--sk-fg)]\">{{ created }}</dd>\n </template>\n </dl>\n <a\n v-if=\"details.outputUrl\"\n :href=\"details.outputUrl\"\n target=\"_blank\"\n rel=\"noopener\"\n class=\"inline-flex w-fit items-center gap-1 text-[var(--sk-primary)] hover:underline\"\n >\n <UIcon name=\"i-lucide-external-link\" class=\"size-3.5\" />{{ t('composites.derivation.openOutput') }}\n </a>\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4BA,MAAM,OAAO;;;;;;;;;EAZb,MAAM,QAAQ;EAEd,MAAM,EAAE,MAAM,UAAU,SAAS;EACjC,MAAM,EAAE,MAAM,cAAc;EAE5B,MAAM,aAAa,eAAe,aAAa,MAAM,IAAI,CAAC;EAC1D,MAAM,UAAU,eAAe,MAAM,WAAW,oBAAoB,MAAM,QAAQ,MAAM,IAAI,IAAI,IAAI;EACpG,MAAM,SAAS,eAAe,WAAW,QAAQ,sBAAsB,GAAG,WAAW,MAAM,MAAM,IAAI,EAAE;EACvG,MAAM,UAAU,eAAe,WAAW,QAAQ,oBAAoB,MAAM,QAAQ,WAAW,KAAK,IAAI,KAAK;EAC7G,MAAM,gBAAgB,eAAe,WAAW,QAAQ,gBAAgB,MAAM,QAAQ,MAAM,IAAI,IAAI,KAAK;EACzG,MAAM,UAAU,eAAe,WAAW,OAAO,YAAY,WAAW,WAAW,MAAM,SAAS,IAAI,EAAE;;GAM3F,OAAA,WAAA,SAAU,CAAK,QAAA,YAA1BA,UAAA,GAAAC,mBAGM,OAHN,YAGM,CAFJC,YAA8DC,MAAA,KAAA,GAAA;IAAvD,MAAK;IAAsB,OAAM;GACxC,CAAA,GAAAC,mBAAqO,QAArO,YAAqOC,gBAAA;IAA1MF,MAAA,CAAA,CAAC,CAAA,6BAAA;IAAiC,OAAA;IAAQ,QAAA,QAAUA,MAAA,CAAA,CAAC,CAAA,+BAAA,IAAA;IAAwC,cAAA,QAAgBA,MAAA,CAAA,CAAC,CAAA,qCAAA,IAAA;IAA8C,QAAA;GAAO,CAAA,CAAE,OAAO,OAAO,CAAA,CAAE,KAAI,KAAA,CAAA,GAAA,CAAA,CAAA,CAAA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,GAAA,CAAAC,YAAwDC,MAAA,KAAA,GAAA;KAAjD,MAAK;KAAyB,OAAM;IAAgB,CAAA,GAAAI,gBAAAF,gBAAAF,MAAA,CAAA,CAAC,CAAA,kCAAA,CAAA,GAAA,CAAA,CAAA,GAAA,GAAA,WAAA,KAAAK,mBAAA,QAAA,IAAA"}
|
|
@@ -11,7 +11,7 @@ const _hoisted_1 = {
|
|
|
11
11
|
};
|
|
12
12
|
const _hoisted_2 = { class: "truncate text-sm" };
|
|
13
13
|
/**
|
|
14
|
-
* Focus mode indicator (mounted by the composites feature): while a
|
|
14
|
+
* Focus mode indicator (mounted by the composites feature): while a Typed block is focused (`focusComposite`) a small chip
|
|
15
15
|
* fixed at the bottom of the surface names it and leaves focus mode.
|
|
16
16
|
*/
|
|
17
17
|
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FocusChip.js","names":["_openBlock","_createElementBlock","_createVNode","_unref","_createElementVNode","_toDisplayString","_createCommentVNode"],"sources":["../../../../src/features/composites/components/FocusChip.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Editor } from '@tiptap/vue-3'\nimport { computed } from 'vue'\nimport { findBlockById } from '../../../core/schema'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { compositeFocusOf } from '../focus'\n\n/**\n * Focus mode indicator (mounted by the composites feature): while a
|
|
1
|
+
{"version":3,"file":"FocusChip.js","names":["_openBlock","_createElementBlock","_createVNode","_unref","_createElementVNode","_toDisplayString","_createCommentVNode"],"sources":["../../../../src/features/composites/components/FocusChip.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Editor } from '@tiptap/vue-3'\nimport { computed } from 'vue'\nimport { findBlockById } from '../../../core/schema'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { compositeFocusOf } from '../focus'\n\n/**\n * Focus mode indicator (mounted by the composites feature): while a Typed block is focused (`focusComposite`) a small chip\n * fixed at the bottom of the surface names it and leaves focus mode.\n */\nconst props = defineProps<{ editor: Editor }>()\n\nconst { Button: UButton, Icon: UIcon } = useUiKit()\nconst { t } = useEditorI18n()\n\n// The vue-3 Editor's `state` is reactive, so this follows every transaction.\nconst focused = computed(() => {\n if (props.editor.isDestroyed) return null\n const id = compositeFocusOf(props.editor.state)\n const found = id ? findBlockById(props.editor.state.doc, id) : null\n return found ? { title: found.node.child(0).textContent.trim() || t('composites.untitled') } : null\n})\n</script>\n\n<template>\n <div\n v-if=\"focused\"\n class=\"fixed bottom-4 left-1/2 z-20 flex max-w-[90vw] -translate-x-1/2 items-center gap-2 rounded-full border border-[var(--sk-border)] bg-[var(--sk-bg)] py-1 pl-3 pr-1 shadow-lg\"\n role=\"status\"\n >\n <UIcon name=\"i-lucide-focus\" class=\"size-4 shrink-0 text-[var(--sk-primary)]\" />\n <span class=\"truncate text-sm\">{{ t('composites.focus.chip', { title: focused.title }) }}</span>\n <UButton size=\"xs\" color=\"neutral\" variant=\"ghost\" icon=\"i-lucide-x\" :label=\"t('composites.focus.release')\" :aria-label=\"t('composites.focus.leave')\" @click=\"editor.commands.focusComposite(null)\" />\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;EAYA,MAAM,QAAQ;EAEd,MAAM,EAAE,QAAQ,SAAS,MAAM,UAAU,SAAS;EAClD,MAAM,EAAE,MAAM,cAAc;EAG5B,MAAM,UAAU,eAAe;GAC7B,IAAI,MAAM,OAAO,aAAa,OAAO;GACrC,MAAM,KAAK,iBAAiB,MAAM,OAAO,KAAK;GAC9C,MAAM,QAAQ,KAAK,cAAc,MAAM,OAAO,MAAM,KAAK,EAAE,IAAI;GAC/D,OAAO,QAAQ,EAAE,OAAO,MAAM,KAAK,MAAM,CAAC,CAAC,CAAC,YAAY,KAAK,KAAK,EAAE,qBAAqB,EAAE,IAAI;EACjG,CAAC;;GAKS,OAAA,QAAA,SADRA,UAAA,GAAAC,mBAQM,OARN,YAQM;IAHJC,YAAgFC,MAAA,KAAA,GAAA;KAAzE,MAAK;KAAiB,OAAM;;IACnCC,mBAAgG,QAAhG,YAAgGC,gBAA9DF,MAAA,CAAA,CAAC,CAAA,yBAAA,EAAA,OAAmC,QAAA,MAAQ,MAAK,CAAA,CAAA,GAAA,CAAA;IACnFD,YAAsMC,MAAA,OAAA,GAAA;KAA7L,MAAK;KAAK,OAAM;KAAU,SAAQ;KAAQ,MAAK;KAAc,OAAOA,MAAA,CAAA,CAAC,CAAA,0BAAA;KAA+B,cAAYA,MAAA,CAAA,CAAC,CAAA,wBAAA;KAA6B,SAAK,OAAA,OAAA,OAAA,MAAA,WAAE,QAAA,OAAO,SAAS,eAAc,IAAA"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Editor } from "@tiptap/vue-3";
|
|
2
2
|
//#region src/features/composites/components/FocusChip.vue.d.ts
|
|
3
3
|
/**
|
|
4
|
-
* Focus mode indicator (mounted by the composites feature): while a
|
|
4
|
+
* Focus mode indicator (mounted by the composites feature): while a Typed block is focused (`focusComposite`) a small chip
|
|
5
5
|
* fixed at the bottom of the surface names it and leaves focus mode.
|
|
6
6
|
*/
|
|
7
7
|
type __VLS_Props = {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
+
import { setBlockProperty } from "../properties.js";
|
|
1
2
|
import { useUiKit } from "../../../vue/kit/use-ui-kit.js";
|
|
2
3
|
import { useEditorI18n } from "../../../vue/use-editor-i18n.js";
|
|
3
|
-
import { setCompositeMetaField } from "../rows.js";
|
|
4
4
|
import { metaText } from "../meta-display.js";
|
|
5
5
|
import { useCompositeRows } from "../use-composite-rows.js";
|
|
6
6
|
import { computed, createBlock, defineComponent, openBlock, unref } from "vue";
|
|
7
7
|
//#region src/features/composites/components/ReferenceFieldSelect.vue
|
|
8
|
-
/** The select of a `reference` field: the other
|
|
8
|
+
/** The select of a `reference` field: the other Typed blocks of the document (with a block ID, of the field's target Block types) by title. */
|
|
9
9
|
const NONE = "__none__";
|
|
10
10
|
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
11
11
|
__name: "ReferenceFieldSelect",
|
|
@@ -31,7 +31,7 @@ const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
|
31
31
|
value: candidate.id
|
|
32
32
|
}))]);
|
|
33
33
|
function onChoice(value) {
|
|
34
|
-
|
|
34
|
+
setBlockProperty(props.editor, props.row, props.field.key, typeof value === "string" && value !== NONE ? value : "");
|
|
35
35
|
}
|
|
36
36
|
return (_ctx, _cache) => {
|
|
37
37
|
return openBlock(), createBlock(unref(USelect), {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ReferenceFieldSelect.js","names":["_openBlock","_createBlock","_unref"],"sources":["../../../../src/features/composites/components/ReferenceFieldSelect.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Editor } from '@tiptap/core'\nimport { computed } from 'vue'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport type {
|
|
1
|
+
{"version":3,"file":"ReferenceFieldSelect.js","names":["_openBlock","_createBlock","_unref"],"sources":["../../../../src/features/composites/components/ReferenceFieldSelect.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport type { Editor } from '@tiptap/core'\nimport { computed } from 'vue'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport type { PropertyDefinition } from '../../../core/properties'\nimport { metaText } from '../meta-display'\nimport { type BlockProperties, setBlockProperty } from '../properties'\nimport { useCompositeRows } from '../use-composite-rows'\n\n/** The select of a `reference` field: the other Typed blocks of the document (with a block ID, of the field's target Block types) by title. */\nconst props = defineProps<{\n editor: Editor\n row: BlockProperties\n field: PropertyDefinition\n disabled?: boolean\n size?: 'xs' | 'sm' | 'md'\n}>()\n\n/** Nuxt UI's select has no empty-string value: the \"no reference\" item travels as this sentinel. */\nconst NONE = '__none__'\n\nconst { Select: USelect } = useUiKit()\nconst { t } = useEditorI18n()\nconst { rows } = useCompositeRows(() => props.editor)\n\nconst stored = computed(() => metaText(props.row, props.field))\nconst items = computed(() => [\n { label: t('composites.field.none'), value: NONE },\n ...rows.value\n .filter(candidate => candidate.id !== null && candidate.id !== props.row.id && (!props.field.targets || props.field.targets.includes(candidate.kind)))\n .map(candidate => ({ label: `${candidate.title.trim() || t('composites.inspector.untitled')} · ${candidate.kindLabel}`, value: candidate.id as string })),\n])\n\nfunction onChoice(value: unknown) {\n setBlockProperty(props.editor, props.row, props.field.key, typeof value === 'string' && value !== NONE ? value : '')\n}\n</script>\n\n<template>\n <USelect\n :model-value=\"stored || undefined\"\n :items=\"items\"\n :placeholder=\"t('composites.field.choose', { field: field.label })\"\n :aria-label=\"field.label\"\n :disabled=\"disabled\"\n :size=\"size\"\n class=\"w-full\"\n @update:model-value=\"onChoice\"\n />\n</template>\n"],"mappings":";;;;;;;;AAoBA,MAAM,OAAO;;;;;;;;;;;EATb,MAAM,QAAQ;;EAWd,MAAM,EAAE,QAAQ,YAAY,SAAS;EACrC,MAAM,EAAE,MAAM,cAAc;EAC5B,MAAM,EAAE,SAAS,uBAAuB,MAAM,MAAM;EAEpD,MAAM,SAAS,eAAe,SAAS,MAAM,KAAK,MAAM,KAAK,CAAC;EAC9D,MAAM,QAAQ,eAAe,CAC3B;GAAE,OAAO,EAAE,uBAAuB;GAAG,OAAO;EAAK,GACjD,GAAG,KAAK,MACL,QAAO,cAAa,UAAU,OAAO,QAAQ,UAAU,OAAO,MAAM,IAAI,OAAO,CAAC,MAAM,MAAM,WAAW,MAAM,MAAM,QAAQ,SAAS,UAAU,IAAI,EAAE,CAAA,CACpJ,KAAI,eAAc;GAAE,OAAO,GAAG,UAAU,MAAM,KAAK,KAAK,EAAE,+BAA+B,EAAE,KAAK,UAAU;GAAa,OAAO,UAAU;EAAa,EAAE,CAC5J,CAAC;EAED,SAAS,SAAS,OAAgB;GAChC,iBAAiB,MAAM,QAAQ,MAAM,KAAK,MAAM,MAAM,KAAK,OAAO,UAAU,YAAY,UAAU,OAAO,QAAQ,EAAE;EACrH;;GAIE,OAAAA,UAAA,GAAAC,YASEC,MAAA,OAAA,GAAA;IARC,eAAa,OAAA,SAAU,KAAA;IACvB,OAAO,MAAA;IACP,aAAaA,MAAA,CAAA,CAAC,CAAA,2BAAA,EAAA,OAAqC,QAAA,MAAM,MAAK,CAAA;IAC9D,cAAY,QAAA,MAAM;IAClB,UAAU,QAAA;IACV,MAAM,QAAA;IACP,OAAM;IACL,uBAAoB"}
|
|
@@ -6,7 +6,7 @@ import { computed, createBlock, createTextVNode, createVNode, defineComponent, n
|
|
|
6
6
|
import { NodeViewWrapper, nodeViewProps } from "@tiptap/vue-3";
|
|
7
7
|
//#region src/features/composites/components/ReferenceView.vue
|
|
8
8
|
/**
|
|
9
|
-
* The `reference` chip: the live short citation (or title) of the
|
|
9
|
+
* The `reference` chip: the live short citation (or title) of the Typed block it points at, followed by its locator.
|
|
10
10
|
* A click reveals the target and, with a locator, opens its source there (page of a PDF, time of a recording); a
|
|
11
11
|
* target that no longer exists shows a greyed „gone“ label. Double click or right click opens a popover to set the
|
|
12
12
|
* locator („Stelle“) in an editable editor.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ReferenceView.js","names":["selected","node","_openBlock","_createBlock","_unref","_normalizeClass","_withModifiers","_withCtx","_createTextVNode","_toDisplayString","_createVNode","_withKeys"],"sources":["../../../../src/features/composites/components/ReferenceView.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { NodeViewWrapper, nodeViewProps } from '@tiptap/vue-3'\nimport { computed, onBeforeUnmount, onMounted, ref, shallowRef } from 'vue'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { referenceAttrsOf, resolveReference } from '../reference-label'\nimport { revealSource } from '../reveal-source'\n\n/**\n * The `reference` chip: the live short citation (or title) of the
|
|
1
|
+
{"version":3,"file":"ReferenceView.js","names":["selected","node","_openBlock","_createBlock","_unref","_normalizeClass","_withModifiers","_withCtx","_createTextVNode","_toDisplayString","_createVNode","_withKeys"],"sources":["../../../../src/features/composites/components/ReferenceView.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { NodeViewWrapper, nodeViewProps } from '@tiptap/vue-3'\nimport { computed, onBeforeUnmount, onMounted, ref, shallowRef } from 'vue'\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { useEditorI18n } from '../../../vue/use-editor-i18n'\nimport { referenceAttrsOf, resolveReference } from '../reference-label'\nimport { revealSource } from '../reveal-source'\n\n/**\n * The `reference` chip: the live short citation (or title) of the Typed block it points at, followed by its locator.\n * A click reveals the target and, with a locator, opens its source there (page of a PDF, time of a recording); a\n * target that no longer exists shows a greyed „gone“ label. Double click or right click opens a popover to set the\n * locator („Stelle“) in an editable editor.\n */\nconst props = defineProps(nodeViewProps)\n\nconst { Input: UInput, Popover: UPopover } = useUiKit()\nconst { t } = useEditorI18n()\n\nconst resolved = shallowRef(resolveReference(props.editor, referenceAttrsOf(props.node)))\n\n// The target's title and bibliography edits change the label: re-resolve after document changes, once per frame.\nlet frame = 0\nfunction sync() {\n cancelAnimationFrame(frame)\n frame = requestAnimationFrame(() => {\n if (props.editor.isDestroyed) return\n const next = resolveReference(props.editor, referenceAttrsOf(props.node))\n const current = resolved.value\n if (next.label !== current.label || next.title !== current.title || next.gone !== current.gone) resolved.value = next\n })\n}\nonMounted(() => props.editor.on('update', sync))\nonBeforeUnmount(() => {\n cancelAnimationFrame(frame)\n props.editor.off('update', sync)\n})\n\nconst text = computed(() => {\n const label = resolved.value.gone ? t('composites.reference.gone') : resolved.value.label\n const locator = props.node.attrs.locator\n return typeof locator === 'string' && locator && !resolved.value.gone ? `${label}, ${locator}` : label\n})\n\nfunction onClick() {\n const target = String(props.node.attrs.target)\n if (!props.editor.commands.revealBlock(target)) return\n const locator = props.node.attrs.locator\n if (typeof locator === 'string' && locator) revealSource(props.editor, target, locator)\n}\n\nconst root = ref<{ $el: HTMLElement } | null>(null)\nconst reference = { getBoundingClientRect: () => root.value?.$el.getBoundingClientRect() ?? new DOMRect() }\n\nconst open = ref(false)\nconst draft = ref('')\n\nfunction openLocator() {\n if (!props.editor.isEditable) return\n draft.value = typeof props.node.attrs.locator === 'string' ? props.node.attrs.locator : ''\n open.value = true\n}\n\nfunction commit() {\n open.value = false\n const pos = props.getPos()\n if (typeof pos !== 'number' || draft.value.trim() === (props.node.attrs.locator ?? '')) return\n props.editor.commands.setReferenceLocator(pos, draft.value)\n}\n</script>\n\n<template>\n <NodeViewWrapper\n ref=\"root\"\n as=\"span\"\n :class=\"['reference', { 'is-gone': resolved.gone, 'is-selected': selected }]\"\n data-type=\"reference\"\n :data-target=\"node.attrs.target\"\n :title=\"resolved.gone ? undefined : resolved.title\"\n role=\"link\"\n @click=\"onClick\"\n @dblclick.prevent=\"openLocator\"\n @contextmenu.prevent=\"openLocator\"\n >\n {{ text }}\n <UPopover\n :open=\"open\"\n :reference=\"reference\"\n :content=\"{ side: 'bottom', align: 'start', sideOffset: 4, onCloseAutoFocus: (event: Event) => event.preventDefault() }\"\n :ui=\"{ content: 'w-56 p-2' }\"\n @update:open=\"(value: boolean) => { if (!value) commit() }\"\n >\n <template #content>\n <UInput\n v-model=\"draft\"\n size=\"xs\"\n class=\"w-full\"\n :placeholder=\"t('composites.reference.locatorPlaceholder')\"\n :aria-label=\"t('composites.reference.locator')\"\n @keydown.enter.prevent=\"commit\"\n />\n </template>\n </UPopover>\n </NodeViewWrapper>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;EAcA,MAAM,QAAQ;EAEd,MAAM,EAAE,OAAO,QAAQ,SAAS,aAAa,SAAS;EACtD,MAAM,EAAE,MAAM,cAAc;EAE5B,MAAM,WAAW,WAAW,iBAAiB,MAAM,QAAQ,iBAAiB,MAAM,IAAI,CAAC,CAAC;EAGxF,IAAI,QAAQ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