@mnaoumov/obsidian-lib 0.0.0 → 1.0.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/@types/dataview/api/data-array/package.json +4 -0
- package/@types/dataview/api/extensions/package.json +4 -0
- package/@types/dataview/api/inline-api/package.json +4 -0
- package/@types/dataview/api/plugin-api/package.json +4 -0
- package/@types/dataview/api/result/package.json +4 -0
- package/@types/dataview/data-import/common/package.json +4 -0
- package/@types/dataview/data-import/csv/package.json +4 -0
- package/@types/dataview/data-import/inline-field/package.json +4 -0
- package/@types/dataview/data-import/markdown-file/package.json +4 -0
- package/@types/dataview/data-import/persister/package.json +4 -0
- package/@types/dataview/data-import/web-worker/import-entry/package.json +4 -0
- package/@types/dataview/data-import/web-worker/import-impl/package.json +4 -0
- package/@types/dataview/data-import/web-worker/import-manager/package.json +4 -0
- package/@types/dataview/data-index/index/package.json +4 -0
- package/@types/dataview/data-index/package.json +4 -0
- package/@types/dataview/data-index/resolver/package.json +4 -0
- package/@types/dataview/data-index/source/package.json +4 -0
- package/@types/dataview/data-model/markdown/package.json +4 -0
- package/@types/dataview/data-model/serialized/markdown/package.json +4 -0
- package/@types/dataview/data-model/transferable/package.json +4 -0
- package/@types/dataview/data-model/value/package.json +4 -0
- package/@types/dataview/expression/binaryop/package.json +4 -0
- package/@types/dataview/expression/context/package.json +4 -0
- package/@types/dataview/expression/field/package.json +4 -0
- package/@types/dataview/expression/functions/package.json +4 -0
- package/@types/dataview/expression/parse/package.json +4 -0
- package/@types/dataview/index/package.json +4 -0
- package/@types/dataview/main/package.json +4 -0
- package/@types/dataview/package.json +4 -0
- package/@types/dataview/query/engine/package.json +4 -0
- package/@types/dataview/query/parse/package.json +4 -0
- package/@types/dataview/query/query/package.json +4 -0
- package/@types/dataview/settings/package.json +4 -0
- package/@types/dataview/typings/obsidian-ex/package.json +4 -0
- package/@types/dataview/typings/workers/package.json +4 -0
- package/@types/dataview/ui/export/markdown/package.json +4 -0
- package/@types/dataview/ui/lp-render/package.json +4 -0
- package/@types/dataview/ui/markdown/package.json +4 -0
- package/@types/dataview/ui/refreshable-view/package.json +4 -0
- package/@types/dataview/ui/render/package.json +4 -0
- package/@types/dataview/ui/views/calendar-view/package.json +4 -0
- package/@types/dataview/ui/views/inline-field-live-preview/package.json +4 -0
- package/@types/dataview/ui/views/inline-view/package.json +4 -0
- package/@types/dataview/ui/views/js-view/package.json +4 -0
- package/@types/dataview/ui/views/list-view/package.json +4 -0
- package/@types/dataview/ui/views/table-view/package.json +4 -0
- package/@types/dataview/ui/views/task-view/package.json +4 -0
- package/@types/dataview/util/hash/package.json +4 -0
- package/@types/dataview/util/locale/package.json +4 -0
- package/@types/dataview/util/media/package.json +4 -0
- package/@types/dataview/util/normalize/package.json +4 -0
- package/@types/i18next/package.json +4 -0
- package/@types/obsidian-integration-testing/package.json +4 -0
- package/@types/original-fs/package.json +4 -0
- package/LICENSE +21 -0
- package/README.md +7 -1
- package/codemirror/index/package.json +6 -0
- package/codemirror/package.json +6 -0
- package/codemirror/state-field-spec/package.json +6 -0
- package/command-handlers/abstract-file-command-handler/package.json +6 -0
- package/command-handlers/command-handler/package.json +6 -0
- package/command-handlers/command-handler-component/package.json +6 -0
- package/command-handlers/editor-command-handler/package.json +6 -0
- package/command-handlers/file-command-handler/package.json +6 -0
- package/command-handlers/folder-command-handler/package.json +6 -0
- package/command-handlers/global-command-handler/package.json +6 -0
- package/command-handlers/index/package.json +6 -0
- package/command-handlers/open-demo-vault-command-handler/package.json +6 -0
- package/command-handlers/open-settings-command-handler/package.json +6 -0
- package/command-handlers/package.json +6 -0
- package/command-handlers/unlock-active-note-command-handler/package.json +6 -0
- package/components/abort-signal-component/package.json +6 -0
- package/components/all-windows-event-component/package.json +6 -0
- package/components/async-error-handler-component/package.json +6 -0
- package/components/async-events-component/package.json +6 -0
- package/components/case-insensitive-file-index-component/package.json +6 -0
- package/components/component-ex/package.json +6 -0
- package/components/console-debug-component/package.json +6 -0
- package/components/core-plugin-toggle-component/package.json +6 -0
- package/components/disposable-component/package.json +6 -0
- package/components/embed-extensions-component/package.json +6 -0
- package/components/generate-markdown-link-default-params-component/package.json +6 -0
- package/components/index/package.json +6 -0
- package/components/layout-ready-component/package.json +6 -0
- package/components/menu-event-registrar-component/package.json +6 -0
- package/components/monkey-around-component/package.json +6 -0
- package/components/notebook-navigator-menu-event-registrar-component/package.json +6 -0
- package/components/package.json +6 -0
- package/components/plugin-context-component/package.json +6 -0
- package/components/plugin-gate-component/package.json +6 -0
- package/components/plugin-notice-component/package.json +6 -0
- package/components/plugin-settings-component/package.json +6 -0
- package/components/plugin-settings-tab-component/package.json +6 -0
- package/components/plugin-suggestion-component/package.json +6 -0
- package/components/pointer-position-component/package.json +6 -0
- package/components/registry-component/package.json +6 -0
- package/components/release-notes-component/package.json +6 -0
- package/components/rename-delete-handler-component/package.json +6 -0
- package/components/rmdir-guard-component/package.json +6 -0
- package/components/settings-migration-component/package.json +6 -0
- package/components/syntax-highlighting-component/package.json +6 -0
- package/components/templates-language-component/package.json +6 -0
- package/constructors/get-dom-events-handlers-constructor/package.json +6 -0
- package/constructors/index/package.json +6 -0
- package/constructors/package.json +6 -0
- package/dist/lib/cjs/@types/dataview/api/data-array.d.cts +137 -0
- package/dist/lib/cjs/@types/dataview/api/extensions.d.cts +16 -0
- package/dist/lib/cjs/@types/dataview/api/inline-api.d.cts +187 -0
- package/dist/lib/cjs/@types/dataview/api/plugin-api.d.cts +210 -0
- package/dist/lib/cjs/@types/dataview/api/result.d.cts +39 -0
- package/dist/lib/cjs/@types/dataview/data-import/common.d.cts +4 -0
- package/dist/lib/cjs/@types/dataview/data-import/csv.d.cts +4 -0
- package/dist/lib/cjs/@types/dataview/data-import/inline-field.d.cts +43 -0
- package/dist/lib/cjs/@types/dataview/data-import/markdown-file.d.cts +53 -0
- package/dist/lib/cjs/@types/dataview/data-import/persister.d.cts +33 -0
- package/dist/lib/cjs/@types/dataview/data-import/web-worker/import-entry.d.cts +2 -0
- package/dist/lib/cjs/@types/dataview/data-import/web-worker/import-impl.d.cts +7 -0
- package/dist/lib/cjs/@types/dataview/data-import/web-worker/import-manager.d.cts +38 -0
- package/dist/lib/cjs/@types/dataview/data-index/index.d.cts +187 -0
- package/dist/lib/cjs/@types/dataview/data-index/resolver.d.cts +24 -0
- package/dist/lib/cjs/@types/dataview/data-index/source.d.cts +72 -0
- package/dist/lib/cjs/@types/dataview/data-model/markdown.d.cts +116 -0
- package/dist/lib/cjs/@types/dataview/data-model/serialized/markdown.d.cts +107 -0
- package/dist/lib/cjs/@types/dataview/data-model/transferable.d.cts +8 -0
- package/dist/lib/cjs/@types/dataview/data-model/value.d.cts +176 -0
- package/dist/lib/cjs/@types/dataview/expression/binaryop.d.cts +44 -0
- package/dist/lib/cjs/@types/dataview/expression/context.d.cts +50 -0
- package/dist/lib/cjs/@types/dataview/expression/field.d.cts +83 -0
- package/dist/lib/cjs/@types/dataview/expression/functions.d.cts +150 -0
- package/dist/lib/cjs/@types/dataview/expression/parse.d.cts +164 -0
- package/dist/lib/cjs/@types/dataview/index.d.cts +56 -0
- package/dist/lib/cjs/@types/dataview/main.d.cts +53 -0
- package/dist/lib/cjs/@types/dataview/query/engine.d.cts +104 -0
- package/dist/lib/cjs/@types/dataview/query/parse.d.cts +45 -0
- package/dist/lib/cjs/@types/dataview/query/query.d.cts +96 -0
- package/dist/lib/cjs/@types/dataview/settings.d.cts +61 -0
- package/dist/lib/cjs/@types/dataview/typings/obsidian-ex.d.cts +29 -0
- package/dist/lib/cjs/@types/dataview/typings/workers.d.cts +5 -0
- package/dist/lib/cjs/@types/dataview/ui/export/markdown.d.cts +16 -0
- package/dist/lib/cjs/@types/dataview/ui/lp-render.d.cts +38 -0
- package/dist/lib/cjs/@types/dataview/ui/markdown.d.cts +87 -0
- package/dist/lib/cjs/@types/dataview/ui/refreshable-view.d.cts +19 -0
- package/dist/lib/cjs/@types/dataview/ui/render.d.cts +34 -0
- package/dist/lib/cjs/@types/dataview/ui/views/calendar-view.d.cts +18 -0
- package/dist/lib/cjs/@types/dataview/ui/views/inline-field-live-preview.d.cts +43 -0
- package/dist/lib/cjs/@types/dataview/ui/views/inline-view.d.cts +29 -0
- package/dist/lib/cjs/@types/dataview/ui/views/js-view.d.cts +24 -0
- package/dist/lib/cjs/@types/dataview/ui/views/list-view.d.cts +26 -0
- package/dist/lib/cjs/@types/dataview/ui/views/table-view.d.cts +29 -0
- package/dist/lib/cjs/@types/dataview/ui/views/task-view.d.cts +52 -0
- package/dist/lib/cjs/@types/dataview/util/hash.d.cts +2 -0
- package/dist/lib/cjs/@types/dataview/util/locale.d.cts +3 -0
- package/dist/lib/cjs/@types/dataview/util/media.d.cts +7 -0
- package/dist/lib/cjs/@types/dataview/util/normalize.d.cts +45 -0
- package/dist/lib/cjs/@types/i18next.d.cts +14 -0
- package/dist/lib/cjs/@types/obsidian-integration-testing.d.cts +29 -0
- package/dist/lib/cjs/@types/original-fs.d.cts +15 -0
- package/dist/lib/cjs/__merged.cjs +1680 -0
- package/dist/lib/cjs/__merged.d.cts +205 -0
- package/dist/lib/cjs/active-file-provider.cjs +185 -0
- package/dist/lib/cjs/active-file-provider.d.cts +36 -0
- package/dist/lib/cjs/app.cjs +177 -0
- package/dist/lib/cjs/app.d.cts +17 -0
- package/dist/lib/cjs/async-with-notice.cjs +259 -0
- package/dist/lib/cjs/async-with-notice.d.cts +113 -0
- package/dist/lib/cjs/attachment-path.cjs +403 -0
- package/dist/lib/cjs/attachment-path.d.cts +341 -0
- package/dist/lib/cjs/attachment-unit-folder.cjs +192 -0
- package/dist/lib/cjs/attachment-unit-folder.d.cts +103 -0
- package/dist/lib/cjs/backlink-index.cjs +273 -0
- package/dist/lib/cjs/backlink-index.d.cts +51 -0
- package/dist/lib/cjs/backlink.cjs +241 -0
- package/dist/lib/cjs/backlink.d.cts +66 -0
- package/dist/lib/cjs/bases-view-registrar.cjs +186 -0
- package/dist/lib/cjs/bases-view-registrar.d.cts +52 -0
- package/dist/lib/cjs/callout.cjs +244 -0
- package/dist/lib/cjs/callout.d.cts +76 -0
- package/dist/lib/cjs/canvas.cjs +239 -0
- package/dist/lib/cjs/canvas.d.cts +28 -0
- package/dist/lib/cjs/case-insensitive-file-index.cjs +268 -0
- package/dist/lib/cjs/case-insensitive-file-index.d.cts +92 -0
- package/dist/lib/cjs/code-block-markdown-information.cjs +155 -0
- package/dist/lib/cjs/code-block-markdown-information.d.cts +48 -0
- package/dist/lib/cjs/code-block-reg-exp.cjs +169 -0
- package/dist/lib/cjs/code-block-reg-exp.d.cts +39 -0
- package/dist/lib/cjs/codemirror/index.cjs +177 -0
- package/dist/lib/cjs/codemirror/index.d.cts +2 -0
- package/dist/lib/cjs/codemirror/state-field-spec.cjs +155 -0
- package/dist/lib/cjs/codemirror/state-field-spec.d.cts +72 -0
- package/dist/lib/cjs/command-handlers/abstract-file-command-handler.cjs +440 -0
- package/dist/lib/cjs/command-handlers/abstract-file-command-handler.d.cts +274 -0
- package/dist/lib/cjs/command-handlers/command-handler-component.cjs +302 -0
- package/dist/lib/cjs/command-handlers/command-handler-component.d.cts +146 -0
- package/dist/lib/cjs/command-handlers/command-handler.cjs +224 -0
- package/dist/lib/cjs/command-handlers/command-handler.d.cts +107 -0
- package/dist/lib/cjs/command-handlers/editor-command-handler.cjs +372 -0
- package/dist/lib/cjs/command-handlers/editor-command-handler.d.cts +208 -0
- package/dist/lib/cjs/command-handlers/file-command-handler.cjs +309 -0
- package/dist/lib/cjs/command-handlers/file-command-handler.d.cts +143 -0
- package/dist/lib/cjs/command-handlers/folder-command-handler.cjs +317 -0
- package/dist/lib/cjs/command-handlers/folder-command-handler.d.cts +149 -0
- package/dist/lib/cjs/command-handlers/global-command-handler.cjs +209 -0
- package/dist/lib/cjs/command-handlers/global-command-handler.d.cts +40 -0
- package/dist/lib/cjs/command-handlers/index.cjs +204 -0
- package/dist/lib/cjs/command-handlers/index.d.cts +11 -0
- package/dist/lib/cjs/command-handlers/open-demo-vault-command-handler.cjs +233 -0
- package/dist/lib/cjs/command-handlers/open-demo-vault-command-handler.d.cts +73 -0
- package/dist/lib/cjs/command-handlers/open-settings-command-handler.cjs +198 -0
- package/dist/lib/cjs/command-handlers/open-settings-command-handler.d.cts +44 -0
- package/dist/lib/cjs/command-handlers/unlock-active-note-command-handler.cjs +211 -0
- package/dist/lib/cjs/command-handlers/unlock-active-note-command-handler.d.cts +54 -0
- package/dist/lib/cjs/command-registrar.cjs +193 -0
- package/dist/lib/cjs/command-registrar.d.cts +48 -0
- package/dist/lib/cjs/community-plugins.cjs +346 -0
- package/dist/lib/cjs/community-plugins.d.cts +270 -0
- package/dist/lib/cjs/components/abort-signal-component.cjs +196 -0
- package/dist/lib/cjs/components/abort-signal-component.d.cts +30 -0
- package/dist/lib/cjs/components/all-windows-event-component.cjs +238 -0
- package/dist/lib/cjs/components/all-windows-event-component.d.cts +84 -0
- package/dist/lib/cjs/components/async-error-handler-component.cjs +200 -0
- package/dist/lib/cjs/components/async-error-handler-component.d.cts +30 -0
- package/dist/lib/cjs/components/async-events-component.cjs +172 -0
- package/dist/lib/cjs/components/async-events-component.d.cts +15 -0
- package/dist/lib/cjs/components/case-insensitive-file-index-component.cjs +210 -0
- package/dist/lib/cjs/components/case-insensitive-file-index-component.d.cts +36 -0
- package/dist/lib/cjs/components/component-ex.cjs +528 -0
- package/dist/lib/cjs/components/component-ex.d.cts +229 -0
- package/dist/lib/cjs/components/console-debug-component.cjs +194 -0
- package/dist/lib/cjs/components/console-debug-component.d.cts +30 -0
- package/dist/lib/cjs/components/core-plugin-toggle-component.cjs +226 -0
- package/dist/lib/cjs/components/core-plugin-toggle-component.d.cts +102 -0
- package/dist/lib/cjs/components/disposable-component.cjs +178 -0
- package/dist/lib/cjs/components/disposable-component.d.cts +24 -0
- package/dist/lib/cjs/components/embed-extensions-component.cjs +198 -0
- package/dist/lib/cjs/components/embed-extensions-component.d.cts +38 -0
- package/dist/lib/cjs/components/generate-markdown-link-default-params-component.cjs +194 -0
- package/dist/lib/cjs/components/generate-markdown-link-default-params-component.d.cts +42 -0
- package/dist/lib/cjs/components/index.cjs +261 -0
- package/dist/lib/cjs/components/index.d.cts +30 -0
- package/dist/lib/cjs/components/layout-ready-component.cjs +235 -0
- package/dist/lib/cjs/components/layout-ready-component.d.cts +48 -0
- package/dist/lib/cjs/components/menu-event-registrar-component.cjs +220 -0
- package/dist/lib/cjs/components/menu-event-registrar-component.d.cts +52 -0
- package/dist/lib/cjs/components/monkey-around-component.cjs +269 -0
- package/dist/lib/cjs/components/monkey-around-component.d.cts +241 -0
- package/dist/lib/cjs/components/notebook-navigator-menu-event-registrar-component.cjs +345 -0
- package/dist/lib/cjs/components/notebook-navigator-menu-event-registrar-component.d.cts +150 -0
- package/dist/lib/cjs/components/plugin-context-component.cjs +204 -0
- package/dist/lib/cjs/components/plugin-context-component.d.cts +36 -0
- package/dist/lib/cjs/components/plugin-gate-component.cjs +572 -0
- package/dist/lib/cjs/components/plugin-gate-component.d.cts +332 -0
- package/dist/lib/cjs/components/plugin-notice-component.cjs +653 -0
- package/dist/lib/cjs/components/plugin-notice-component.d.cts +362 -0
- package/dist/lib/cjs/components/plugin-settings-component.cjs +668 -0
- package/dist/lib/cjs/components/plugin-settings-component.d.cts +362 -0
- package/dist/lib/cjs/components/plugin-settings-tab-component.cjs +194 -0
- package/dist/lib/cjs/components/plugin-settings-tab-component.d.cts +39 -0
- package/dist/lib/cjs/components/plugin-suggestion-component.cjs +302 -0
- package/dist/lib/cjs/components/plugin-suggestion-component.d.cts +162 -0
- package/dist/lib/cjs/components/pointer-position-component.cjs +190 -0
- package/dist/lib/cjs/components/pointer-position-component.d.cts +29 -0
- package/dist/lib/cjs/components/registry-component.cjs +211 -0
- package/dist/lib/cjs/components/registry-component.d.cts +37 -0
- package/dist/lib/cjs/components/release-notes-component.cjs +249 -0
- package/dist/lib/cjs/components/release-notes-component.d.cts +129 -0
- package/dist/lib/cjs/components/rename-delete-handler-component.cjs +1299 -0
- package/dist/lib/cjs/components/rename-delete-handler-component.d.cts +165 -0
- package/dist/lib/cjs/components/rmdir-guard-component.cjs +214 -0
- package/dist/lib/cjs/components/rmdir-guard-component.d.cts +76 -0
- package/dist/lib/cjs/components/settings-migration-component.cjs +246 -0
- package/dist/lib/cjs/components/settings-migration-component.d.cts +120 -0
- package/dist/lib/cjs/components/syntax-highlighting-component.cjs +272 -0
- package/dist/lib/cjs/components/syntax-highlighting-component.d.cts +149 -0
- package/dist/lib/cjs/components/templates-language-component.cjs +300 -0
- package/dist/lib/cjs/components/templates-language-component.d.cts +124 -0
- package/dist/lib/cjs/constructors/get-dom-events-handlers-constructor.cjs +270 -0
- package/dist/lib/cjs/constructors/get-dom-events-handlers-constructor.d.cts +22 -0
- package/dist/lib/cjs/constructors/index.cjs +177 -0
- package/dist/lib/cjs/constructors/index.d.cts +2 -0
- package/dist/lib/cjs/css-class.cjs +232 -0
- package/dist/lib/cjs/css-class.d.cts +278 -0
- package/dist/lib/cjs/data-handler.cjs +194 -0
- package/dist/lib/cjs/data-handler.d.cts +49 -0
- package/dist/lib/cjs/dataview-link.cjs +184 -0
- package/dist/lib/cjs/dataview-link.d.cts +42 -0
- package/dist/lib/cjs/dataview.cjs +403 -0
- package/dist/lib/cjs/dataview.d.cts +249 -0
- package/dist/lib/cjs/debug.cjs +172 -0
- package/dist/lib/cjs/debug.d.cts +19 -0
- package/dist/lib/cjs/demo-vault-helper-settings.cjs +155 -0
- package/dist/lib/cjs/demo-vault-helper-settings.d.cts +29 -0
- package/dist/lib/cjs/demo-vault-helper.cjs +256 -0
- package/dist/lib/cjs/demo-vault-helper.d.cts +61 -0
- package/dist/lib/cjs/demo-vault-naming.cjs +181 -0
- package/dist/lib/cjs/demo-vault-naming.d.cts +54 -0
- package/dist/lib/cjs/desktop-demo-vault-opener.cjs +372 -0
- package/dist/lib/cjs/desktop-demo-vault-opener.d.cts +76 -0
- package/dist/lib/cjs/desktop-trusted-input.cjs +325 -0
- package/dist/lib/cjs/desktop-trusted-input.d.cts +288 -0
- package/dist/lib/cjs/editor-extension-registrar.cjs +186 -0
- package/dist/lib/cjs/editor-extension-registrar.d.cts +37 -0
- package/dist/lib/cjs/editor-suggest-registrar.cjs +186 -0
- package/dist/lib/cjs/editor-suggest-registrar.d.cts +36 -0
- package/dist/lib/cjs/editor.cjs +224 -0
- package/dist/lib/cjs/editor.d.cts +45 -0
- package/dist/lib/cjs/events.cjs +196 -0
- package/dist/lib/cjs/events.d.cts +98 -0
- package/dist/lib/cjs/extensions-registrar.cjs +186 -0
- package/dist/lib/cjs/extensions-registrar.d.cts +51 -0
- package/dist/lib/cjs/file-change.cjs +582 -0
- package/dist/lib/cjs/file-change.d.cts +156 -0
- package/dist/lib/cjs/file-explorer.cjs +181 -0
- package/dist/lib/cjs/file-explorer.d.cts +34 -0
- package/dist/lib/cjs/file-manager.cjs +275 -0
- package/dist/lib/cjs/file-manager.d.cts +123 -0
- package/dist/lib/cjs/file-system.cjs +595 -0
- package/dist/lib/cjs/file-system.d.cts +554 -0
- package/dist/lib/cjs/folder-note.cjs +285 -0
- package/dist/lib/cjs/folder-note.d.cts +166 -0
- package/dist/lib/cjs/frontmatter-formatting.cjs +472 -0
- package/dist/lib/cjs/frontmatter-formatting.d.cts +44 -0
- package/dist/lib/cjs/frontmatter-link-cache-with-offsets.cjs +183 -0
- package/dist/lib/cjs/frontmatter-link-cache-with-offsets.d.cts +34 -0
- package/dist/lib/cjs/frontmatter.cjs +295 -0
- package/dist/lib/cjs/frontmatter.d.cts +145 -0
- package/dist/lib/cjs/generated-during-build.cjs +170 -0
- package/dist/lib/cjs/generated-during-build.d.cts +19 -0
- package/dist/lib/cjs/hover-link-source-registrar.cjs +186 -0
- package/dist/lib/cjs/hover-link-source-registrar.d.cts +52 -0
- package/dist/lib/cjs/html-element.cjs +207 -0
- package/dist/lib/cjs/html-element.d.cts +98 -0
- package/dist/lib/cjs/i18n/custom-type-options.cjs +156 -0
- package/dist/lib/cjs/i18n/custom-type-options.d.cts +38 -0
- package/dist/lib/cjs/i18n/default-translations.cjs +156 -0
- package/dist/lib/cjs/i18n/default-translations.d.cts +15 -0
- package/dist/lib/cjs/i18n/i18n.cjs +216 -0
- package/dist/lib/cjs/i18n/i18n.d.cts +38 -0
- package/dist/lib/cjs/i18n/index.cjs +186 -0
- package/dist/lib/cjs/i18n/index.d.cts +5 -0
- package/dist/lib/cjs/i18n/locales/en.cjs +248 -0
- package/dist/lib/cjs/i18n/locales/en.d.cts +91 -0
- package/dist/lib/cjs/i18n/locales/index.cjs +180 -0
- package/dist/lib/cjs/i18n/locales/index.d.cts +3 -0
- package/dist/lib/cjs/i18n/locales/translations-map.cjs +174 -0
- package/dist/lib/cjs/i18n/locales/translations-map.d.cts +100 -0
- package/dist/lib/cjs/index.cjs +459 -0
- package/dist/lib/cjs/index.d.cts +96 -0
- package/dist/lib/cjs/is-in-obsidian.cjs +178 -0
- package/dist/lib/cjs/is-in-obsidian.d.cts +12 -0
- package/dist/lib/cjs/library-styles.cjs +197 -0
- package/dist/lib/cjs/library-styles.d.cts +56 -0
- package/dist/lib/cjs/library.cjs +205 -0
- package/dist/lib/cjs/library.d.cts +57 -0
- package/dist/lib/cjs/link-name.cjs +169 -0
- package/dist/lib/cjs/link-name.d.cts +23 -0
- package/dist/lib/cjs/link-update-progress.cjs +155 -0
- package/dist/lib/cjs/link-update-progress.d.cts +32 -0
- package/dist/lib/cjs/link.cjs +1077 -0
- package/dist/lib/cjs/link.d.cts +1369 -0
- package/dist/lib/cjs/logger.cjs +236 -0
- package/dist/lib/cjs/logger.d.cts +37 -0
- package/dist/lib/cjs/loop.cjs +267 -0
- package/dist/lib/cjs/loop.d.cts +104 -0
- package/dist/lib/cjs/markdown-code-block-processor-registrar.cjs +190 -0
- package/dist/lib/cjs/markdown-code-block-processor-registrar.d.cts +62 -0
- package/dist/lib/cjs/markdown-code-block-processor.cjs +468 -0
- package/dist/lib/cjs/markdown-code-block-processor.d.cts +137 -0
- package/dist/lib/cjs/markdown-post-processor-registrar.cjs +187 -0
- package/dist/lib/cjs/markdown-post-processor-registrar.d.cts +59 -0
- package/dist/lib/cjs/markdown-view.cjs +175 -0
- package/dist/lib/cjs/markdown-view.d.cts +14 -0
- package/dist/lib/cjs/markdown.cjs +494 -0
- package/dist/lib/cjs/markdown.d.cts +226 -0
- package/dist/lib/cjs/menu-event-registrar.cjs +155 -0
- package/dist/lib/cjs/menu-event-registrar.d.cts +84 -0
- package/dist/lib/cjs/metadata-cache.cjs +568 -0
- package/dist/lib/cjs/metadata-cache.d.cts +359 -0
- package/dist/lib/cjs/mobile-trusted-input.cjs +209 -0
- package/dist/lib/cjs/mobile-trusted-input.d.cts +98 -0
- package/dist/lib/cjs/modals/alert.cjs +202 -0
- package/dist/lib/cjs/modals/alert.d.cts +35 -0
- package/dist/lib/cjs/modals/confirm.cjs +212 -0
- package/dist/lib/cjs/modals/confirm.d.cts +39 -0
- package/dist/lib/cjs/modals/index.cjs +201 -0
- package/dist/lib/cjs/modals/index.d.cts +10 -0
- package/dist/lib/cjs/modals/minimizable-modal.cjs +465 -0
- package/dist/lib/cjs/modals/minimizable-modal.d.cts +129 -0
- package/dist/lib/cjs/modals/modal-command-builder.cjs +482 -0
- package/dist/lib/cjs/modals/modal-command-builder.d.cts +285 -0
- package/dist/lib/cjs/modals/modal.cjs +200 -0
- package/dist/lib/cjs/modals/modal.d.cts +64 -0
- package/dist/lib/cjs/modals/prompt.cjs +280 -0
- package/dist/lib/cjs/modals/prompt.d.cts +83 -0
- package/dist/lib/cjs/modals/select-item.cjs +225 -0
- package/dist/lib/cjs/modals/select-item.d.cts +55 -0
- package/dist/lib/cjs/modals/select-option.cjs +213 -0
- package/dist/lib/cjs/modals/select-option.d.cts +65 -0
- package/dist/lib/cjs/modals/suggest-modal-command-builder.cjs +168 -0
- package/dist/lib/cjs/modals/suggest-modal-command-builder.d.cts +35 -0
- package/dist/lib/cjs/note-priority.cjs +258 -0
- package/dist/lib/cjs/note-priority.d.cts +154 -0
- package/dist/lib/cjs/notebook-navigator.cjs +187 -0
- package/dist/lib/cjs/notebook-navigator.d.cts +132 -0
- package/dist/lib/cjs/obsidian-dev-utils-state.cjs +199 -0
- package/dist/lib/cjs/obsidian-dev-utils-state.d.cts +42 -0
- package/dist/lib/cjs/obsidian-protocol-handler-registrar.cjs +189 -0
- package/dist/lib/cjs/obsidian-protocol-handler-registrar.d.cts +55 -0
- package/dist/lib/cjs/obsidian-settings.cjs +206 -0
- package/dist/lib/cjs/obsidian-settings.d.cts +62 -0
- package/dist/lib/cjs/parse-link.cjs +562 -0
- package/dist/lib/cjs/parse-link.d.cts +288 -0
- package/dist/lib/cjs/path-settings.cjs +293 -0
- package/dist/lib/cjs/path-settings.d.cts +56 -0
- package/dist/lib/cjs/pdf.cjs +197 -0
- package/dist/lib/cjs/pdf.d.cts +26 -0
- package/dist/lib/cjs/plugin/index.cjs +198 -0
- package/dist/lib/cjs/plugin/index.d.cts +9 -0
- package/dist/lib/cjs/plugin/plugin-api.cjs +543 -0
- package/dist/lib/cjs/plugin/plugin-api.d.cts +413 -0
- package/dist/lib/cjs/plugin/plugin-context.cjs +215 -0
- package/dist/lib/cjs/plugin/plugin-context.d.cts +27 -0
- package/dist/lib/cjs/plugin/plugin-event-source.cjs +250 -0
- package/dist/lib/cjs/plugin/plugin-event-source.d.cts +97 -0
- package/dist/lib/cjs/plugin/plugin-install-state.cjs +219 -0
- package/dist/lib/cjs/plugin/plugin-install-state.d.cts +113 -0
- package/dist/lib/cjs/plugin/plugin-lifecycle-events.cjs +175 -0
- package/dist/lib/cjs/plugin/plugin-lifecycle-events.d.cts +127 -0
- package/dist/lib/cjs/plugin/plugin-settings-tab.cjs +635 -0
- package/dist/lib/cjs/plugin/plugin-settings-tab.d.cts +368 -0
- package/dist/lib/cjs/plugin/plugin.cjs +730 -0
- package/dist/lib/cjs/plugin/plugin.d.cts +363 -0
- package/dist/lib/cjs/plugin/settings-migration-api.cjs +155 -0
- package/dist/lib/cjs/plugin/settings-migration-api.d.cts +91 -0
- package/dist/lib/cjs/plugin-cli-handler-registrar.cjs +187 -0
- package/dist/lib/cjs/plugin-cli-handler-registrar.d.cts +64 -0
- package/dist/lib/cjs/popovers/field-popover.cjs +206 -0
- package/dist/lib/cjs/popovers/field-popover.d.cts +75 -0
- package/dist/lib/cjs/popovers/index.cjs +183 -0
- package/dist/lib/cjs/popovers/index.d.cts +4 -0
- package/dist/lib/cjs/popovers/popover-anchor.cjs +206 -0
- package/dist/lib/cjs/popovers/popover-anchor.d.cts +67 -0
- package/dist/lib/cjs/popovers/popover.cjs +253 -0
- package/dist/lib/cjs/popovers/popover.d.cts +78 -0
- package/dist/lib/cjs/property-entry.cjs +196 -0
- package/dist/lib/cjs/property-entry.d.cts +43 -0
- package/dist/lib/cjs/queue.cjs +236 -0
- package/dist/lib/cjs/queue.d.cts +93 -0
- package/dist/lib/cjs/react/app-context.cjs +175 -0
- package/dist/lib/cjs/react/app-context.d.cts +24 -0
- package/dist/lib/cjs/react/index.cjs +177 -0
- package/dist/lib/cjs/react/index.d.cts +2 -0
- package/dist/lib/cjs/reference.cjs +210 -0
- package/dist/lib/cjs/reference.d.cts +116 -0
- package/dist/lib/cjs/resource-lock.cjs +1120 -0
- package/dist/lib/cjs/resource-lock.d.cts +318 -0
- package/dist/lib/cjs/resource-url.cjs +180 -0
- package/dist/lib/cjs/resource-url.d.cts +31 -0
- package/dist/lib/cjs/ribbon-icon-registrar.cjs +187 -0
- package/dist/lib/cjs/ribbon-icon-registrar.d.cts +60 -0
- package/dist/lib/cjs/setting-components/checkbox-component.cjs +240 -0
- package/dist/lib/cjs/setting-components/checkbox-component.d.cts +69 -0
- package/dist/lib/cjs/setting-components/code-highlighter-component.cjs +402 -0
- package/dist/lib/cjs/setting-components/code-highlighter-component.d.cts +132 -0
- package/dist/lib/cjs/setting-components/date-component.cjs +204 -0
- package/dist/lib/cjs/setting-components/date-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/date-time-component.cjs +204 -0
- package/dist/lib/cjs/setting-components/date-time-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/email-component.cjs +215 -0
- package/dist/lib/cjs/setting-components/email-component.d.cts +49 -0
- package/dist/lib/cjs/setting-components/file-component.cjs +207 -0
- package/dist/lib/cjs/setting-components/file-component.d.cts +43 -0
- package/dist/lib/cjs/setting-components/index.cjs +252 -0
- package/dist/lib/cjs/setting-components/index.d.cts +27 -0
- package/dist/lib/cjs/setting-components/month-component.cjs +212 -0
- package/dist/lib/cjs/setting-components/month-component.d.cts +51 -0
- package/dist/lib/cjs/setting-components/multiple-dropdown-component.cjs +277 -0
- package/dist/lib/cjs/setting-components/multiple-dropdown-component.d.cts +92 -0
- package/dist/lib/cjs/setting-components/multiple-email-component.cjs +201 -0
- package/dist/lib/cjs/setting-components/multiple-email-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/multiple-file-component.cjs +209 -0
- package/dist/lib/cjs/setting-components/multiple-file-component.d.cts +43 -0
- package/dist/lib/cjs/setting-components/multiple-text-component.cjs +296 -0
- package/dist/lib/cjs/setting-components/multiple-text-component.d.cts +109 -0
- package/dist/lib/cjs/setting-components/number-component.cjs +225 -0
- package/dist/lib/cjs/setting-components/number-component.d.cts +56 -0
- package/dist/lib/cjs/setting-components/password-component.cjs +201 -0
- package/dist/lib/cjs/setting-components/password-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/setting-component-wrapper.cjs +184 -0
- package/dist/lib/cjs/setting-components/setting-component-wrapper.d.cts +13 -0
- package/dist/lib/cjs/setting-components/telephone-component.cjs +215 -0
- package/dist/lib/cjs/setting-components/telephone-component.d.cts +51 -0
- package/dist/lib/cjs/setting-components/text-based-component.cjs +194 -0
- package/dist/lib/cjs/setting-components/text-based-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/time-component.cjs +209 -0
- package/dist/lib/cjs/setting-components/time-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/tri-state-checkbox-component.cjs +241 -0
- package/dist/lib/cjs/setting-components/tri-state-checkbox-component.d.cts +69 -0
- package/dist/lib/cjs/setting-components/typed-dropdown-component.cjs +286 -0
- package/dist/lib/cjs/setting-components/typed-dropdown-component.d.cts +97 -0
- package/dist/lib/cjs/setting-components/typed-multiple-dropdown-component.cjs +288 -0
- package/dist/lib/cjs/setting-components/typed-multiple-dropdown-component.d.cts +99 -0
- package/dist/lib/cjs/setting-components/typed-range-text-component.cjs +199 -0
- package/dist/lib/cjs/setting-components/typed-range-text-component.d.cts +35 -0
- package/dist/lib/cjs/setting-components/typed-text-component.cjs +256 -0
- package/dist/lib/cjs/setting-components/typed-text-component.d.cts +100 -0
- package/dist/lib/cjs/setting-components/url-component.cjs +215 -0
- package/dist/lib/cjs/setting-components/url-component.d.cts +49 -0
- package/dist/lib/cjs/setting-components/validator-component.cjs +254 -0
- package/dist/lib/cjs/setting-components/validator-component.d.cts +23 -0
- package/dist/lib/cjs/setting-components/value-component-with-change-tracking.cjs +155 -0
- package/dist/lib/cjs/setting-components/value-component-with-change-tracking.d.cts +20 -0
- package/dist/lib/cjs/setting-components/week-component.cjs +212 -0
- package/dist/lib/cjs/setting-components/week-component.d.cts +51 -0
- package/dist/lib/cjs/setting-ex.cjs +396 -0
- package/dist/lib/cjs/setting-ex.d.cts +198 -0
- package/dist/lib/cjs/setting-group-ex.cjs +189 -0
- package/dist/lib/cjs/setting-group-ex.d.cts +26 -0
- package/dist/lib/cjs/status-bar-item-registrar.cjs +186 -0
- package/dist/lib/cjs/status-bar-item-registrar.d.cts +36 -0
- package/dist/lib/cjs/templater.cjs +303 -0
- package/dist/lib/cjs/templater.d.cts +284 -0
- package/dist/lib/cjs/transformers/duration-transformer.cjs +206 -0
- package/dist/lib/cjs/transformers/duration-transformer.d.cts +39 -0
- package/dist/lib/cjs/transformers/index.cjs +177 -0
- package/dist/lib/cjs/transformers/index.d.cts +2 -0
- package/dist/lib/cjs/trusted-input.cjs +220 -0
- package/dist/lib/cjs/trusted-input.d.cts +131 -0
- package/dist/lib/cjs/validation.cjs +213 -0
- package/dist/lib/cjs/validation.d.cts +87 -0
- package/dist/lib/cjs/vault-delete.cjs +246 -0
- package/dist/lib/cjs/vault-delete.d.cts +82 -0
- package/dist/lib/cjs/vault-transaction.cjs +436 -0
- package/dist/lib/cjs/vault-transaction.d.cts +163 -0
- package/dist/lib/cjs/vault.cjs +725 -0
- package/dist/lib/cjs/vault.d.cts +506 -0
- package/dist/lib/cjs/view-registrar.cjs +186 -0
- package/dist/lib/cjs/view-registrar.d.cts +52 -0
- package/dist/lib/cjs/workspace.cjs +210 -0
- package/dist/lib/cjs/workspace.d.cts +81 -0
- package/dist/lib/esm/@types/dataview/api/data-array.d.mts +137 -0
- package/dist/lib/esm/@types/dataview/api/extensions.d.mts +16 -0
- package/dist/lib/esm/@types/dataview/api/inline-api.d.mts +187 -0
- package/dist/lib/esm/@types/dataview/api/plugin-api.d.mts +210 -0
- package/dist/lib/esm/@types/dataview/api/result.d.mts +39 -0
- package/dist/lib/esm/@types/dataview/data-import/common.d.mts +4 -0
- package/dist/lib/esm/@types/dataview/data-import/csv.d.mts +4 -0
- package/dist/lib/esm/@types/dataview/data-import/inline-field.d.mts +43 -0
- package/dist/lib/esm/@types/dataview/data-import/markdown-file.d.mts +53 -0
- package/dist/lib/esm/@types/dataview/data-import/persister.d.mts +33 -0
- package/dist/lib/esm/@types/dataview/data-import/web-worker/import-entry.d.mts +2 -0
- package/dist/lib/esm/@types/dataview/data-import/web-worker/import-impl.d.mts +7 -0
- package/dist/lib/esm/@types/dataview/data-import/web-worker/import-manager.d.mts +38 -0
- package/dist/lib/esm/@types/dataview/data-index/index.d.mts +187 -0
- package/dist/lib/esm/@types/dataview/data-index/resolver.d.mts +24 -0
- package/dist/lib/esm/@types/dataview/data-index/source.d.mts +72 -0
- package/dist/lib/esm/@types/dataview/data-model/markdown.d.mts +116 -0
- package/dist/lib/esm/@types/dataview/data-model/serialized/markdown.d.mts +107 -0
- package/dist/lib/esm/@types/dataview/data-model/transferable.d.mts +8 -0
- package/dist/lib/esm/@types/dataview/data-model/value.d.mts +176 -0
- package/dist/lib/esm/@types/dataview/expression/binaryop.d.mts +44 -0
- package/dist/lib/esm/@types/dataview/expression/context.d.mts +50 -0
- package/dist/lib/esm/@types/dataview/expression/field.d.mts +83 -0
- package/dist/lib/esm/@types/dataview/expression/functions.d.mts +150 -0
- package/dist/lib/esm/@types/dataview/expression/parse.d.mts +164 -0
- package/dist/lib/esm/@types/dataview/index.d.mts +56 -0
- package/dist/lib/esm/@types/dataview/main.d.mts +53 -0
- package/dist/lib/esm/@types/dataview/query/engine.d.mts +104 -0
- package/dist/lib/esm/@types/dataview/query/parse.d.mts +45 -0
- package/dist/lib/esm/@types/dataview/query/query.d.mts +96 -0
- package/dist/lib/esm/@types/dataview/settings.d.mts +61 -0
- package/dist/lib/esm/@types/dataview/typings/obsidian-ex.d.mts +29 -0
- package/dist/lib/esm/@types/dataview/typings/workers.d.mts +5 -0
- package/dist/lib/esm/@types/dataview/ui/export/markdown.d.mts +16 -0
- package/dist/lib/esm/@types/dataview/ui/lp-render.d.mts +38 -0
- package/dist/lib/esm/@types/dataview/ui/markdown.d.mts +87 -0
- package/dist/lib/esm/@types/dataview/ui/refreshable-view.d.mts +19 -0
- package/dist/lib/esm/@types/dataview/ui/render.d.mts +34 -0
- package/dist/lib/esm/@types/dataview/ui/views/calendar-view.d.mts +18 -0
- package/dist/lib/esm/@types/dataview/ui/views/inline-field-live-preview.d.mts +43 -0
- package/dist/lib/esm/@types/dataview/ui/views/inline-view.d.mts +29 -0
- package/dist/lib/esm/@types/dataview/ui/views/js-view.d.mts +24 -0
- package/dist/lib/esm/@types/dataview/ui/views/list-view.d.mts +26 -0
- package/dist/lib/esm/@types/dataview/ui/views/table-view.d.mts +29 -0
- package/dist/lib/esm/@types/dataview/ui/views/task-view.d.mts +52 -0
- package/dist/lib/esm/@types/dataview/util/hash.d.mts +2 -0
- package/dist/lib/esm/@types/dataview/util/locale.d.mts +3 -0
- package/dist/lib/esm/@types/dataview/util/media.d.mts +7 -0
- package/dist/lib/esm/@types/dataview/util/normalize.d.mts +45 -0
- package/dist/lib/esm/@types/i18next.d.mts +14 -0
- package/dist/lib/esm/@types/obsidian-integration-testing.d.mts +29 -0
- package/dist/lib/esm/@types/original-fs.d.mts +15 -0
- package/dist/lib/esm/__merged.d.mts +205 -0
- package/dist/lib/esm/__merged.mjs +1532 -0
- package/dist/lib/esm/active-file-provider.d.mts +36 -0
- package/dist/lib/esm/active-file-provider.mjs +72 -0
- package/dist/lib/esm/app.d.mts +17 -0
- package/dist/lib/esm/app.mjs +64 -0
- package/dist/lib/esm/async-with-notice.d.mts +113 -0
- package/dist/lib/esm/async-with-notice.mjs +149 -0
- package/dist/lib/esm/attachment-path.d.mts +341 -0
- package/dist/lib/esm/attachment-path.mjs +302 -0
- package/dist/lib/esm/attachment-unit-folder.d.mts +103 -0
- package/dist/lib/esm/attachment-unit-folder.mjs +78 -0
- package/dist/lib/esm/backlink-index.d.mts +51 -0
- package/dist/lib/esm/backlink-index.mjs +160 -0
- package/dist/lib/esm/backlink.d.mts +66 -0
- package/dist/lib/esm/backlink.mjs +131 -0
- package/dist/lib/esm/bases-view-registrar.d.mts +52 -0
- package/dist/lib/esm/bases-view-registrar.mjs +73 -0
- package/dist/lib/esm/callout.d.mts +76 -0
- package/dist/lib/esm/callout.mjs +132 -0
- package/dist/lib/esm/canvas.d.mts +28 -0
- package/dist/lib/esm/canvas.mjs +129 -0
- package/dist/lib/esm/case-insensitive-file-index.d.mts +92 -0
- package/dist/lib/esm/case-insensitive-file-index.mjs +152 -0
- package/dist/lib/esm/code-block-markdown-information.d.mts +48 -0
- package/dist/lib/esm/code-block-markdown-information.mjs +50 -0
- package/dist/lib/esm/code-block-reg-exp.d.mts +39 -0
- package/dist/lib/esm/code-block-reg-exp.mjs +56 -0
- package/dist/lib/esm/codemirror/index.d.mts +2 -0
- package/dist/lib/esm/codemirror/index.mjs +54 -0
- package/dist/lib/esm/codemirror/state-field-spec.d.mts +72 -0
- package/dist/lib/esm/codemirror/state-field-spec.mjs +50 -0
- package/dist/lib/esm/command-handlers/abstract-file-command-handler.d.mts +274 -0
- package/dist/lib/esm/command-handlers/abstract-file-command-handler.mjs +330 -0
- package/dist/lib/esm/command-handlers/command-handler-component.d.mts +146 -0
- package/dist/lib/esm/command-handlers/command-handler-component.mjs +193 -0
- package/dist/lib/esm/command-handlers/command-handler.d.mts +107 -0
- package/dist/lib/esm/command-handlers/command-handler.mjs +111 -0
- package/dist/lib/esm/command-handlers/editor-command-handler.d.mts +208 -0
- package/dist/lib/esm/command-handlers/editor-command-handler.mjs +262 -0
- package/dist/lib/esm/command-handlers/file-command-handler.d.mts +143 -0
- package/dist/lib/esm/command-handlers/file-command-handler.mjs +200 -0
- package/dist/lib/esm/command-handlers/folder-command-handler.d.mts +149 -0
- package/dist/lib/esm/command-handlers/folder-command-handler.mjs +208 -0
- package/dist/lib/esm/command-handlers/global-command-handler.d.mts +40 -0
- package/dist/lib/esm/command-handlers/global-command-handler.mjs +96 -0
- package/dist/lib/esm/command-handlers/index.d.mts +11 -0
- package/dist/lib/esm/command-handlers/index.mjs +72 -0
- package/dist/lib/esm/command-handlers/open-demo-vault-command-handler.d.mts +73 -0
- package/dist/lib/esm/command-handlers/open-demo-vault-command-handler.mjs +110 -0
- package/dist/lib/esm/command-handlers/open-settings-command-handler.d.mts +44 -0
- package/dist/lib/esm/command-handlers/open-settings-command-handler.mjs +85 -0
- package/dist/lib/esm/command-handlers/unlock-active-note-command-handler.d.mts +54 -0
- package/dist/lib/esm/command-handlers/unlock-active-note-command-handler.mjs +98 -0
- package/dist/lib/esm/command-registrar.d.mts +48 -0
- package/dist/lib/esm/command-registrar.mjs +80 -0
- package/dist/lib/esm/community-plugins.d.mts +270 -0
- package/dist/lib/esm/community-plugins.mjs +222 -0
- package/dist/lib/esm/components/abort-signal-component.d.mts +30 -0
- package/dist/lib/esm/components/abort-signal-component.mjs +83 -0
- package/dist/lib/esm/components/all-windows-event-component.d.mts +84 -0
- package/dist/lib/esm/components/all-windows-event-component.mjs +125 -0
- package/dist/lib/esm/components/async-error-handler-component.d.mts +30 -0
- package/dist/lib/esm/components/async-error-handler-component.mjs +87 -0
- package/dist/lib/esm/components/async-events-component.d.mts +15 -0
- package/dist/lib/esm/components/async-events-component.mjs +59 -0
- package/dist/lib/esm/components/case-insensitive-file-index-component.d.mts +36 -0
- package/dist/lib/esm/components/case-insensitive-file-index-component.mjs +101 -0
- package/dist/lib/esm/components/component-ex.d.mts +229 -0
- package/dist/lib/esm/components/component-ex.mjs +421 -0
- package/dist/lib/esm/components/console-debug-component.d.mts +30 -0
- package/dist/lib/esm/components/console-debug-component.mjs +81 -0
- package/dist/lib/esm/components/core-plugin-toggle-component.d.mts +102 -0
- package/dist/lib/esm/components/core-plugin-toggle-component.mjs +113 -0
- package/dist/lib/esm/components/disposable-component.d.mts +24 -0
- package/dist/lib/esm/components/disposable-component.mjs +65 -0
- package/dist/lib/esm/components/embed-extensions-component.d.mts +38 -0
- package/dist/lib/esm/components/embed-extensions-component.mjs +85 -0
- package/dist/lib/esm/components/generate-markdown-link-default-params-component.d.mts +42 -0
- package/dist/lib/esm/components/generate-markdown-link-default-params-component.mjs +81 -0
- package/dist/lib/esm/components/index.d.mts +30 -0
- package/dist/lib/esm/components/index.mjs +110 -0
- package/dist/lib/esm/components/layout-ready-component.d.mts +48 -0
- package/dist/lib/esm/components/layout-ready-component.mjs +121 -0
- package/dist/lib/esm/components/menu-event-registrar-component.d.mts +52 -0
- package/dist/lib/esm/components/menu-event-registrar-component.mjs +107 -0
- package/dist/lib/esm/components/monkey-around-component.d.mts +241 -0
- package/dist/lib/esm/components/monkey-around-component.mjs +154 -0
- package/dist/lib/esm/components/notebook-navigator-menu-event-registrar-component.d.mts +150 -0
- package/dist/lib/esm/components/notebook-navigator-menu-event-registrar-component.mjs +235 -0
- package/dist/lib/esm/components/plugin-context-component.d.mts +36 -0
- package/dist/lib/esm/components/plugin-context-component.mjs +94 -0
- package/dist/lib/esm/components/plugin-gate-component.d.mts +332 -0
- package/dist/lib/esm/components/plugin-gate-component.mjs +472 -0
- package/dist/lib/esm/components/plugin-notice-component.d.mts +362 -0
- package/dist/lib/esm/components/plugin-notice-component.mjs +543 -0
- package/dist/lib/esm/components/plugin-settings-component.d.mts +362 -0
- package/dist/lib/esm/components/plugin-settings-component.mjs +562 -0
- package/dist/lib/esm/components/plugin-settings-tab-component.d.mts +39 -0
- package/dist/lib/esm/components/plugin-settings-tab-component.mjs +81 -0
- package/dist/lib/esm/components/plugin-suggestion-component.d.mts +162 -0
- package/dist/lib/esm/components/plugin-suggestion-component.mjs +192 -0
- package/dist/lib/esm/components/pointer-position-component.d.mts +29 -0
- package/dist/lib/esm/components/pointer-position-component.mjs +77 -0
- package/dist/lib/esm/components/registry-component.d.mts +37 -0
- package/dist/lib/esm/components/registry-component.mjs +98 -0
- package/dist/lib/esm/components/release-notes-component.d.mts +129 -0
- package/dist/lib/esm/components/release-notes-component.mjs +136 -0
- package/dist/lib/esm/components/rename-delete-handler-component.d.mts +165 -0
- package/dist/lib/esm/components/rename-delete-handler-component.mjs +1238 -0
- package/dist/lib/esm/components/rmdir-guard-component.d.mts +76 -0
- package/dist/lib/esm/components/rmdir-guard-component.mjs +100 -0
- package/dist/lib/esm/components/settings-migration-component.d.mts +120 -0
- package/dist/lib/esm/components/settings-migration-component.mjs +133 -0
- package/dist/lib/esm/components/syntax-highlighting-component.d.mts +149 -0
- package/dist/lib/esm/components/syntax-highlighting-component.mjs +159 -0
- package/dist/lib/esm/components/templates-language-component.d.mts +124 -0
- package/dist/lib/esm/components/templates-language-component.mjs +187 -0
- package/dist/lib/esm/constructors/get-dom-events-handlers-constructor.d.mts +22 -0
- package/dist/lib/esm/constructors/get-dom-events-handlers-constructor.mjs +157 -0
- package/dist/lib/esm/constructors/index.d.mts +2 -0
- package/dist/lib/esm/constructors/index.mjs +54 -0
- package/dist/lib/esm/css-class.d.mts +278 -0
- package/dist/lib/esm/css-class.mjs +119 -0
- package/dist/lib/esm/data-handler.d.mts +49 -0
- package/dist/lib/esm/data-handler.mjs +81 -0
- package/dist/lib/esm/dataview-link.d.mts +42 -0
- package/dist/lib/esm/dataview-link.mjs +74 -0
- package/dist/lib/esm/dataview.d.mts +249 -0
- package/dist/lib/esm/dataview.mjs +288 -0
- package/dist/lib/esm/debug.d.mts +19 -0
- package/dist/lib/esm/debug.mjs +59 -0
- package/dist/lib/esm/demo-vault-helper-settings.d.mts +29 -0
- package/dist/lib/esm/demo-vault-helper-settings.mjs +50 -0
- package/dist/lib/esm/demo-vault-helper.d.mts +61 -0
- package/dist/lib/esm/demo-vault-helper.mjs +150 -0
- package/dist/lib/esm/demo-vault-naming.d.mts +54 -0
- package/dist/lib/esm/demo-vault-naming.mjs +67 -0
- package/dist/lib/esm/desktop-demo-vault-opener.d.mts +76 -0
- package/dist/lib/esm/desktop-demo-vault-opener.mjs +274 -0
- package/dist/lib/esm/desktop-trusted-input.d.mts +288 -0
- package/dist/lib/esm/desktop-trusted-input.mjs +206 -0
- package/dist/lib/esm/editor-extension-registrar.d.mts +37 -0
- package/dist/lib/esm/editor-extension-registrar.mjs +73 -0
- package/dist/lib/esm/editor-suggest-registrar.d.mts +36 -0
- package/dist/lib/esm/editor-suggest-registrar.mjs +76 -0
- package/dist/lib/esm/editor.d.mts +45 -0
- package/dist/lib/esm/editor.mjs +115 -0
- package/dist/lib/esm/events.d.mts +98 -0
- package/dist/lib/esm/events.mjs +81 -0
- package/dist/lib/esm/extensions-registrar.d.mts +51 -0
- package/dist/lib/esm/extensions-registrar.mjs +73 -0
- package/dist/lib/esm/file-change.d.mts +156 -0
- package/dist/lib/esm/file-change.mjs +481 -0
- package/dist/lib/esm/file-explorer.d.mts +34 -0
- package/dist/lib/esm/file-explorer.mjs +68 -0
- package/dist/lib/esm/file-manager.d.mts +123 -0
- package/dist/lib/esm/file-manager.mjs +169 -0
- package/dist/lib/esm/file-system.d.mts +554 -0
- package/dist/lib/esm/file-system.mjs +466 -0
- package/dist/lib/esm/folder-note.d.mts +166 -0
- package/dist/lib/esm/folder-note.mjs +169 -0
- package/dist/lib/esm/frontmatter-formatting.d.mts +44 -0
- package/dist/lib/esm/frontmatter-formatting.mjs +376 -0
- package/dist/lib/esm/frontmatter-link-cache-with-offsets.d.mts +34 -0
- package/dist/lib/esm/frontmatter-link-cache-with-offsets.mjs +69 -0
- package/dist/lib/esm/frontmatter.d.mts +145 -0
- package/dist/lib/esm/frontmatter.mjs +182 -0
- package/dist/lib/esm/generated-during-build.d.mts +19 -0
- package/dist/lib/esm/generated-during-build.mjs +56 -0
- package/dist/lib/esm/hover-link-source-registrar.d.mts +52 -0
- package/dist/lib/esm/hover-link-source-registrar.mjs +73 -0
- package/dist/lib/esm/html-element.d.mts +98 -0
- package/dist/lib/esm/html-element.mjs +94 -0
- package/dist/lib/esm/i18n/custom-type-options.d.mts +38 -0
- package/dist/lib/esm/i18n/custom-type-options.mjs +51 -0
- package/dist/lib/esm/i18n/default-translations.d.mts +15 -0
- package/dist/lib/esm/i18n/default-translations.mjs +51 -0
- package/dist/lib/esm/i18n/i18n.d.mts +38 -0
- package/dist/lib/esm/i18n/i18n.mjs +97 -0
- package/dist/lib/esm/i18n/index.d.mts +5 -0
- package/dist/lib/esm/i18n/index.mjs +60 -0
- package/dist/lib/esm/i18n/locales/en.d.mts +91 -0
- package/dist/lib/esm/i18n/locales/en.mjs +135 -0
- package/dist/lib/esm/i18n/locales/index.d.mts +3 -0
- package/dist/lib/esm/i18n/locales/index.mjs +56 -0
- package/dist/lib/esm/i18n/locales/translations-map.d.mts +100 -0
- package/dist/lib/esm/i18n/locales/translations-map.mjs +60 -0
- package/dist/lib/esm/index.d.mts +96 -0
- package/dist/lib/esm/index.mjs +242 -0
- package/dist/lib/esm/is-in-obsidian.d.mts +12 -0
- package/dist/lib/esm/is-in-obsidian.mjs +67 -0
- package/dist/lib/esm/library-styles.d.mts +56 -0
- package/dist/lib/esm/library-styles.mjs +80 -0
- package/dist/lib/esm/library.d.mts +57 -0
- package/dist/lib/esm/library.mjs +91 -0
- package/dist/lib/esm/link-name.d.mts +23 -0
- package/dist/lib/esm/link-name.mjs +56 -0
- package/dist/lib/esm/link-update-progress.d.mts +32 -0
- package/dist/lib/esm/link-update-progress.mjs +50 -0
- package/dist/lib/esm/link.d.mts +1369 -0
- package/dist/lib/esm/link.mjs +996 -0
- package/dist/lib/esm/logger.d.mts +37 -0
- package/dist/lib/esm/logger.mjs +123 -0
- package/dist/lib/esm/loop.d.mts +104 -0
- package/dist/lib/esm/loop.mjs +159 -0
- package/dist/lib/esm/markdown-code-block-processor-registrar.d.mts +62 -0
- package/dist/lib/esm/markdown-code-block-processor-registrar.mjs +77 -0
- package/dist/lib/esm/markdown-code-block-processor.d.mts +137 -0
- package/dist/lib/esm/markdown-code-block-processor.mjs +364 -0
- package/dist/lib/esm/markdown-post-processor-registrar.d.mts +59 -0
- package/dist/lib/esm/markdown-post-processor-registrar.mjs +74 -0
- package/dist/lib/esm/markdown-view.d.mts +14 -0
- package/dist/lib/esm/markdown-view.mjs +62 -0
- package/dist/lib/esm/markdown.d.mts +226 -0
- package/dist/lib/esm/markdown.mjs +399 -0
- package/dist/lib/esm/menu-event-registrar.d.mts +84 -0
- package/dist/lib/esm/menu-event-registrar.mjs +50 -0
- package/dist/lib/esm/metadata-cache.d.mts +359 -0
- package/dist/lib/esm/metadata-cache.mjs +462 -0
- package/dist/lib/esm/mobile-trusted-input.d.mts +98 -0
- package/dist/lib/esm/mobile-trusted-input.mjs +90 -0
- package/dist/lib/esm/modals/alert.d.mts +35 -0
- package/dist/lib/esm/modals/alert.mjs +92 -0
- package/dist/lib/esm/modals/confirm.d.mts +39 -0
- package/dist/lib/esm/modals/confirm.mjs +102 -0
- package/dist/lib/esm/modals/index.d.mts +10 -0
- package/dist/lib/esm/modals/index.mjs +70 -0
- package/dist/lib/esm/modals/minimizable-modal.d.mts +129 -0
- package/dist/lib/esm/modals/minimizable-modal.mjs +356 -0
- package/dist/lib/esm/modals/modal-command-builder.d.mts +285 -0
- package/dist/lib/esm/modals/modal-command-builder.mjs +371 -0
- package/dist/lib/esm/modals/modal.d.mts +64 -0
- package/dist/lib/esm/modals/modal.mjs +86 -0
- package/dist/lib/esm/modals/prompt.d.mts +83 -0
- package/dist/lib/esm/modals/prompt.mjs +176 -0
- package/dist/lib/esm/modals/select-item.d.mts +55 -0
- package/dist/lib/esm/modals/select-item.mjs +112 -0
- package/dist/lib/esm/modals/select-option.d.mts +65 -0
- package/dist/lib/esm/modals/select-option.mjs +103 -0
- package/dist/lib/esm/modals/suggest-modal-command-builder.d.mts +35 -0
- package/dist/lib/esm/modals/suggest-modal-command-builder.mjs +55 -0
- package/dist/lib/esm/note-priority.d.mts +154 -0
- package/dist/lib/esm/note-priority.mjs +143 -0
- package/dist/lib/esm/notebook-navigator.d.mts +132 -0
- package/dist/lib/esm/notebook-navigator.mjs +72 -0
- package/dist/lib/esm/obsidian-dev-utils-state.d.mts +42 -0
- package/dist/lib/esm/obsidian-dev-utils-state.mjs +84 -0
- package/dist/lib/esm/obsidian-protocol-handler-registrar.d.mts +55 -0
- package/dist/lib/esm/obsidian-protocol-handler-registrar.mjs +76 -0
- package/dist/lib/esm/obsidian-settings.d.mts +62 -0
- package/dist/lib/esm/obsidian-settings.mjs +89 -0
- package/dist/lib/esm/parse-link.d.mts +288 -0
- package/dist/lib/esm/parse-link.mjs +436 -0
- package/dist/lib/esm/path-settings.d.mts +56 -0
- package/dist/lib/esm/path-settings.mjs +184 -0
- package/dist/lib/esm/pdf.d.mts +26 -0
- package/dist/lib/esm/pdf.mjs +84 -0
- package/dist/lib/esm/plugin/index.d.mts +9 -0
- package/dist/lib/esm/plugin/index.mjs +68 -0
- package/dist/lib/esm/plugin/plugin-api.d.mts +413 -0
- package/dist/lib/esm/plugin/plugin-api.mjs +430 -0
- package/dist/lib/esm/plugin/plugin-context.d.mts +27 -0
- package/dist/lib/esm/plugin/plugin-context.mjs +109 -0
- package/dist/lib/esm/plugin/plugin-event-source.d.mts +97 -0
- package/dist/lib/esm/plugin/plugin-event-source.mjs +137 -0
- package/dist/lib/esm/plugin/plugin-install-state.d.mts +113 -0
- package/dist/lib/esm/plugin/plugin-install-state.mjs +109 -0
- package/dist/lib/esm/plugin/plugin-lifecycle-events.d.mts +127 -0
- package/dist/lib/esm/plugin/plugin-lifecycle-events.mjs +60 -0
- package/dist/lib/esm/plugin/plugin-settings-tab.d.mts +368 -0
- package/dist/lib/esm/plugin/plugin-settings-tab.mjs +535 -0
- package/dist/lib/esm/plugin/plugin.d.mts +363 -0
- package/dist/lib/esm/plugin/plugin.mjs +619 -0
- package/dist/lib/esm/plugin/settings-migration-api.d.mts +91 -0
- package/dist/lib/esm/plugin/settings-migration-api.mjs +50 -0
- package/dist/lib/esm/plugin-cli-handler-registrar.d.mts +64 -0
- package/dist/lib/esm/plugin-cli-handler-registrar.mjs +74 -0
- package/dist/lib/esm/popovers/field-popover.d.mts +75 -0
- package/dist/lib/esm/popovers/field-popover.mjs +96 -0
- package/dist/lib/esm/popovers/index.d.mts +4 -0
- package/dist/lib/esm/popovers/index.mjs +58 -0
- package/dist/lib/esm/popovers/popover-anchor.d.mts +67 -0
- package/dist/lib/esm/popovers/popover-anchor.mjs +90 -0
- package/dist/lib/esm/popovers/popover.d.mts +78 -0
- package/dist/lib/esm/popovers/popover.mjs +140 -0
- package/dist/lib/esm/property-entry.d.mts +43 -0
- package/dist/lib/esm/property-entry.mjs +81 -0
- package/dist/lib/esm/queue.d.mts +93 -0
- package/dist/lib/esm/queue.mjs +130 -0
- package/dist/lib/esm/react/app-context.d.mts +24 -0
- package/dist/lib/esm/react/app-context.mjs +64 -0
- package/dist/lib/esm/react/index.d.mts +2 -0
- package/dist/lib/esm/react/index.mjs +54 -0
- package/dist/lib/esm/reference.d.mts +116 -0
- package/dist/lib/esm/reference.mjs +95 -0
- package/dist/lib/esm/resource-lock.d.mts +318 -0
- package/dist/lib/esm/resource-lock.mjs +1014 -0
- package/dist/lib/esm/resource-url.d.mts +31 -0
- package/dist/lib/esm/resource-url.mjs +67 -0
- package/dist/lib/esm/ribbon-icon-registrar.d.mts +60 -0
- package/dist/lib/esm/ribbon-icon-registrar.mjs +74 -0
- package/dist/lib/esm/setting-components/checkbox-component.d.mts +69 -0
- package/dist/lib/esm/setting-components/checkbox-component.mjs +127 -0
- package/dist/lib/esm/setting-components/code-highlighter-component.d.mts +132 -0
- package/dist/lib/esm/setting-components/code-highlighter-component.mjs +295 -0
- package/dist/lib/esm/setting-components/date-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/date-component.mjs +91 -0
- package/dist/lib/esm/setting-components/date-time-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/date-time-component.mjs +91 -0
- package/dist/lib/esm/setting-components/email-component.d.mts +49 -0
- package/dist/lib/esm/setting-components/email-component.mjs +102 -0
- package/dist/lib/esm/setting-components/file-component.d.mts +43 -0
- package/dist/lib/esm/setting-components/file-component.mjs +94 -0
- package/dist/lib/esm/setting-components/index.d.mts +27 -0
- package/dist/lib/esm/setting-components/index.mjs +104 -0
- package/dist/lib/esm/setting-components/month-component.d.mts +51 -0
- package/dist/lib/esm/setting-components/month-component.mjs +99 -0
- package/dist/lib/esm/setting-components/multiple-dropdown-component.d.mts +92 -0
- package/dist/lib/esm/setting-components/multiple-dropdown-component.mjs +167 -0
- package/dist/lib/esm/setting-components/multiple-email-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/multiple-email-component.mjs +88 -0
- package/dist/lib/esm/setting-components/multiple-file-component.d.mts +43 -0
- package/dist/lib/esm/setting-components/multiple-file-component.mjs +96 -0
- package/dist/lib/esm/setting-components/multiple-text-component.d.mts +109 -0
- package/dist/lib/esm/setting-components/multiple-text-component.mjs +186 -0
- package/dist/lib/esm/setting-components/number-component.d.mts +56 -0
- package/dist/lib/esm/setting-components/number-component.mjs +112 -0
- package/dist/lib/esm/setting-components/password-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/password-component.mjs +88 -0
- package/dist/lib/esm/setting-components/setting-component-wrapper.d.mts +13 -0
- package/dist/lib/esm/setting-components/setting-component-wrapper.mjs +71 -0
- package/dist/lib/esm/setting-components/telephone-component.d.mts +51 -0
- package/dist/lib/esm/setting-components/telephone-component.mjs +102 -0
- package/dist/lib/esm/setting-components/text-based-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/text-based-component.mjs +81 -0
- package/dist/lib/esm/setting-components/time-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/time-component.mjs +96 -0
- package/dist/lib/esm/setting-components/tri-state-checkbox-component.d.mts +69 -0
- package/dist/lib/esm/setting-components/tri-state-checkbox-component.mjs +128 -0
- package/dist/lib/esm/setting-components/typed-dropdown-component.d.mts +97 -0
- package/dist/lib/esm/setting-components/typed-dropdown-component.mjs +176 -0
- package/dist/lib/esm/setting-components/typed-multiple-dropdown-component.d.mts +99 -0
- package/dist/lib/esm/setting-components/typed-multiple-dropdown-component.mjs +175 -0
- package/dist/lib/esm/setting-components/typed-range-text-component.d.mts +35 -0
- package/dist/lib/esm/setting-components/typed-range-text-component.mjs +86 -0
- package/dist/lib/esm/setting-components/typed-text-component.d.mts +100 -0
- package/dist/lib/esm/setting-components/typed-text-component.mjs +146 -0
- package/dist/lib/esm/setting-components/url-component.d.mts +49 -0
- package/dist/lib/esm/setting-components/url-component.mjs +102 -0
- package/dist/lib/esm/setting-components/validator-component.d.mts +23 -0
- package/dist/lib/esm/setting-components/validator-component.mjs +150 -0
- package/dist/lib/esm/setting-components/value-component-with-change-tracking.d.mts +20 -0
- package/dist/lib/esm/setting-components/value-component-with-change-tracking.mjs +50 -0
- package/dist/lib/esm/setting-components/week-component.d.mts +51 -0
- package/dist/lib/esm/setting-components/week-component.mjs +99 -0
- package/dist/lib/esm/setting-ex.d.mts +198 -0
- package/dist/lib/esm/setting-ex.mjs +282 -0
- package/dist/lib/esm/setting-group-ex.d.mts +26 -0
- package/dist/lib/esm/setting-group-ex.mjs +76 -0
- package/dist/lib/esm/status-bar-item-registrar.d.mts +36 -0
- package/dist/lib/esm/status-bar-item-registrar.mjs +73 -0
- package/dist/lib/esm/templater.d.mts +284 -0
- package/dist/lib/esm/templater.mjs +181 -0
- package/dist/lib/esm/transformers/duration-transformer.d.mts +39 -0
- package/dist/lib/esm/transformers/duration-transformer.mjs +93 -0
- package/dist/lib/esm/transformers/index.d.mts +2 -0
- package/dist/lib/esm/transformers/index.mjs +54 -0
- package/dist/lib/esm/trusted-input.d.mts +131 -0
- package/dist/lib/esm/trusted-input.mjs +91 -0
- package/dist/lib/esm/validation.d.mts +87 -0
- package/dist/lib/esm/validation.mjs +95 -0
- package/dist/lib/esm/vault-delete.d.mts +82 -0
- package/dist/lib/esm/vault-delete.mjs +140 -0
- package/dist/lib/esm/vault-transaction.d.mts +163 -0
- package/dist/lib/esm/vault-transaction.mjs +333 -0
- package/dist/lib/esm/vault.d.mts +506 -0
- package/dist/lib/esm/vault.mjs +612 -0
- package/dist/lib/esm/view-registrar.d.mts +52 -0
- package/dist/lib/esm/view-registrar.mjs +73 -0
- package/dist/lib/esm/workspace.d.mts +81 -0
- package/dist/lib/esm/workspace.mjs +92 -0
- package/dist/styles.css +497 -0
- package/i18n/custom-type-options/package.json +6 -0
- package/i18n/default-translations/package.json +6 -0
- package/i18n/i18n/package.json +6 -0
- package/i18n/index/package.json +6 -0
- package/i18n/locales/en/package.json +6 -0
- package/i18n/locales/index/package.json +6 -0
- package/i18n/locales/package.json +6 -0
- package/i18n/locales/translations-map/package.json +6 -0
- package/i18n/package.json +6 -0
- package/modals/alert/package.json +6 -0
- package/modals/confirm/package.json +6 -0
- package/modals/index/package.json +6 -0
- package/modals/minimizable-modal/package.json +6 -0
- package/modals/modal/package.json +6 -0
- package/modals/modal-command-builder/package.json +6 -0
- package/modals/package.json +6 -0
- package/modals/prompt/package.json +6 -0
- package/modals/select-item/package.json +6 -0
- package/modals/select-option/package.json +6 -0
- package/modals/suggest-modal-command-builder/package.json +6 -0
- package/package.json +488 -13
- package/plugin/index/package.json +6 -0
- package/plugin/package.json +6 -0
- package/plugin/plugin/package.json +6 -0
- package/plugin/plugin-api/package.json +6 -0
- package/plugin/plugin-context/package.json +6 -0
- package/plugin/plugin-event-source/package.json +6 -0
- package/plugin/plugin-install-state/package.json +6 -0
- package/plugin/plugin-lifecycle-events/package.json +6 -0
- package/plugin/plugin-settings-tab/package.json +6 -0
- package/plugin/settings-migration-api/package.json +6 -0
- package/popovers/field-popover/package.json +6 -0
- package/popovers/index/package.json +6 -0
- package/popovers/package.json +6 -0
- package/popovers/popover/package.json +6 -0
- package/popovers/popover-anchor/package.json +6 -0
- package/react/app-context/package.json +6 -0
- package/react/index/package.json +6 -0
- package/react/package.json +6 -0
- package/setting-components/checkbox-component/package.json +6 -0
- package/setting-components/code-highlighter-component/package.json +6 -0
- package/setting-components/date-component/package.json +6 -0
- package/setting-components/date-time-component/package.json +6 -0
- package/setting-components/email-component/package.json +6 -0
- package/setting-components/file-component/package.json +6 -0
- package/setting-components/index/package.json +6 -0
- package/setting-components/month-component/package.json +6 -0
- package/setting-components/multiple-dropdown-component/package.json +6 -0
- package/setting-components/multiple-email-component/package.json +6 -0
- package/setting-components/multiple-file-component/package.json +6 -0
- package/setting-components/multiple-text-component/package.json +6 -0
- package/setting-components/number-component/package.json +6 -0
- package/setting-components/package.json +6 -0
- package/setting-components/password-component/package.json +6 -0
- package/setting-components/setting-component-wrapper/package.json +6 -0
- package/setting-components/telephone-component/package.json +6 -0
- package/setting-components/text-based-component/package.json +6 -0
- package/setting-components/time-component/package.json +6 -0
- package/setting-components/tri-state-checkbox-component/package.json +6 -0
- package/setting-components/typed-dropdown-component/package.json +6 -0
- package/setting-components/typed-multiple-dropdown-component/package.json +6 -0
- package/setting-components/typed-range-text-component/package.json +6 -0
- package/setting-components/typed-text-component/package.json +6 -0
- package/setting-components/url-component/package.json +6 -0
- package/setting-components/validator-component/package.json +6 -0
- package/setting-components/value-component-with-change-tracking/package.json +6 -0
- package/setting-components/week-component/package.json +6 -0
- package/transformers/duration-transformer/package.json +6 -0
- package/transformers/index/package.json +6 -0
- package/transformers/package.json +6 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/// <reference path="../library.d.mts" />
|
|
2
|
+
/**
|
|
3
|
+
* @file
|
|
4
|
+
*
|
|
5
|
+
* The former home of the `SuggestModal` instruction-bar builder.
|
|
6
|
+
*
|
|
7
|
+
* The builder is no longer tied to `SuggestModal` — it renders into a plain `Modal` and into a bare
|
|
8
|
+
* element + `Scope` too — so it moved to `modal-command-builder.ts` under the honest name
|
|
9
|
+
* {@link ModalCommandBuilder}. This module stays as a deprecated alias so existing importers keep working
|
|
10
|
+
* unchanged; it re-exports the very same class, not a copy.
|
|
11
|
+
*/
|
|
12
|
+
import type { ModalCommandBuilderBuildOptions } from './modal-command-builder.mjs';
|
|
13
|
+
import { ModalCommandBuilder } from './modal-command-builder.mjs';
|
|
14
|
+
export type { CheckboxCommand, DropDownCommand, KeyboardCommand } from './modal-command-builder.mjs';
|
|
15
|
+
/**
|
|
16
|
+
* Options for {@link SuggestModalCommandBuilder.build}.
|
|
17
|
+
*
|
|
18
|
+
* @deprecated Use {@link ModalCommandBuilderBuildOptions} from
|
|
19
|
+
* `obsidian-dev-utils/obsidian/modals/modal-command-builder` instead.
|
|
20
|
+
*/
|
|
21
|
+
export type SuggestModalCommandBuilderBuildOptions = ModalCommandBuilderBuildOptions;
|
|
22
|
+
/**
|
|
23
|
+
* Builds a `SuggestModal`'s instruction bar.
|
|
24
|
+
*
|
|
25
|
+
* @deprecated Use {@link ModalCommandBuilder} from
|
|
26
|
+
* `obsidian-dev-utils/obsidian/modals/modal-command-builder` instead.
|
|
27
|
+
*/
|
|
28
|
+
export declare const SuggestModalCommandBuilder: typeof ModalCommandBuilder;
|
|
29
|
+
/**
|
|
30
|
+
* Builds a `SuggestModal`'s instruction bar.
|
|
31
|
+
*
|
|
32
|
+
* @deprecated Use {@link ModalCommandBuilder} from
|
|
33
|
+
* `obsidian-dev-utils/obsidian/modals/modal-command-builder` instead.
|
|
34
|
+
*/
|
|
35
|
+
export type SuggestModalCommandBuilder = ModalCommandBuilder;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
/*
|
|
2
|
+
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
|
|
3
|
+
if you want to view the source, please visit the github repository of this plugin
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
(function () {
|
|
7
|
+
function ensureDisposeSymbols(symbolConstructor = Symbol) {
|
|
8
|
+
symbolConstructor.asyncDispose ??= symbolConstructor.for('Symbol.asyncDispose');
|
|
9
|
+
symbolConstructor.dispose ??= symbolConstructor.for('Symbol.dispose');
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
function ensureBrowserProcess() {
|
|
13
|
+
const browserProcess = {
|
|
14
|
+
browser: true,
|
|
15
|
+
cwd() {
|
|
16
|
+
return '/';
|
|
17
|
+
},
|
|
18
|
+
env: {},
|
|
19
|
+
platform: 'android'
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
// eslint-disable-next-line obsidianmd/no-global-this, unicorn/no-unnecessary-global-this -- Must stay `globalThis`-qualified: in the emitted banner a bare `process` is a free identifier, so reading it where the host has none throws a ReferenceError instead of yielding `undefined`. That is the very case this function exists to handle.
|
|
23
|
+
const existingProcess = globalThis.process;
|
|
24
|
+
|
|
25
|
+
if (!existingProcess) {
|
|
26
|
+
// eslint-disable-next-line obsidianmd/no-global-this -- Actively use globalThis.
|
|
27
|
+
globalThis.process = browserProcess;
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
if (existingProcess.versions?.node) {
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
const existingProcessRecord = existingProcess;
|
|
36
|
+
|
|
37
|
+
for (const [key, value] of Object.entries(browserProcess)) {
|
|
38
|
+
existingProcessRecord[key] ??= value;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
existingProcessRecord['browser'] = true;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
(function initEsm() {
|
|
45
|
+
ensureDisposeSymbols();
|
|
46
|
+
ensureBrowserProcess();
|
|
47
|
+
})();
|
|
48
|
+
})();
|
|
49
|
+
|
|
50
|
+
import { ModalCommandBuilder } from "./modal-command-builder.mjs";
|
|
51
|
+
const SuggestModalCommandBuilder = ModalCommandBuilder;
|
|
52
|
+
export {
|
|
53
|
+
SuggestModalCommandBuilder
|
|
54
|
+
};
|
|
55
|
+
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vLi4vLi4vc3JjL21vZGFscy9zdWdnZXN0LW1vZGFsLWNvbW1hbmQtYnVpbGRlci50cyJdLAogICJzb3VyY2VzQ29udGVudCI6IFsiLyoqXG4gKiBAZmlsZVxuICpcbiAqIFRoZSBmb3JtZXIgaG9tZSBvZiB0aGUgYFN1Z2dlc3RNb2RhbGAgaW5zdHJ1Y3Rpb24tYmFyIGJ1aWxkZXIuXG4gKlxuICogVGhlIGJ1aWxkZXIgaXMgbm8gbG9uZ2VyIHRpZWQgdG8gYFN1Z2dlc3RNb2RhbGAgXHUyMDE0IGl0IHJlbmRlcnMgaW50byBhIHBsYWluIGBNb2RhbGAgYW5kIGludG8gYSBiYXJlXG4gKiBlbGVtZW50ICsgYFNjb3BlYCB0b28gXHUyMDE0IHNvIGl0IG1vdmVkIHRvIGBtb2RhbC1jb21tYW5kLWJ1aWxkZXIudHNgIHVuZGVyIHRoZSBob25lc3QgbmFtZVxuICoge0BsaW5rIE1vZGFsQ29tbWFuZEJ1aWxkZXJ9LiBUaGlzIG1vZHVsZSBzdGF5cyBhcyBhIGRlcHJlY2F0ZWQgYWxpYXMgc28gZXhpc3RpbmcgaW1wb3J0ZXJzIGtlZXAgd29ya2luZ1xuICogdW5jaGFuZ2VkOyBpdCByZS1leHBvcnRzIHRoZSB2ZXJ5IHNhbWUgY2xhc3MsIG5vdCBhIGNvcHkuXG4gKi9cblxuaW1wb3J0IHR5cGUgeyBNb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cjtcblxuLyoqXG4gKiBCdWlsZHMgYSBgU3VnZ2VzdE1vZGFsYCdzIGluc3RydWN0aW9uIGJhci5cbiAqXG4gKiBAZGVwcmVjYXRlZCBVc2Uge0BsaW5rIE1vZGFsQ29tbWFuZEJ1aWxkZXJ9IGZyb21cbiAqIGBvYnNpZGlhbi1kZXYtdXRpbHMvb2JzaWRpYW4vbW9kYWxzL21vZGFsLWNvbW1hbmQtYnVpbGRlcmAgaW5zdGVhZC5cbiAqL1xuZXhwb3J0IHR5cGUgU3VnZ2VzdE1vZGFsQ29tbWFuZEJ1aWxkZXIgPSBNb2RhbENvbW1hbmRCdWlsZGVyO1xuIl0sCiAgIm1hcHBpbmdzIjogIjs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OztBQWFBLFNBQVMsMkJBQTJCO0FBc0I3QixNQUFNLDZCQUE2QjsiLAogICJuYW1lcyI6IFtdCn0K
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
/// <reference path="./library.d.mts" />
|
|
2
|
+
/**
|
|
3
|
+
* @file
|
|
4
|
+
*
|
|
5
|
+
* Decides which of several notes referencing the same attachment owns it.
|
|
6
|
+
*
|
|
7
|
+
* An attachment referenced from more than one note has no single correct home, so collecting it falls
|
|
8
|
+
* back to whatever `collectAttachmentUsedByMultipleNotesMode` says — skip, copy, cancel, or ask. A
|
|
9
|
+
* priority list lets the user answer the question once instead: put `.md` above `.excalidraw` and an
|
|
10
|
+
* image shared by both lands in the markdown note's folder.
|
|
11
|
+
*
|
|
12
|
+
* A tie is deliberately NOT resolved here. Two notes of equal priority is exactly the ambiguity the
|
|
13
|
+
* existing mode setting already exists to handle, and inventing a second, silent rule for it would
|
|
14
|
+
* move a file the user never named.
|
|
15
|
+
*
|
|
16
|
+
* The tie is also the whole of what gets REPORTED. A note the list ranked below the best rank cannot
|
|
17
|
+
* resolve the ambiguity, so listing it only adds noise — and worse in a picker, where offering it
|
|
18
|
+
* invites an answer the priority list itself would not have given. That is why
|
|
19
|
+
* {@link filterHighestPriorityNotePaths} exists alongside the two functions that decide.
|
|
20
|
+
*/
|
|
21
|
+
/**
|
|
22
|
+
* Why the priority list did not settle which note owns an attachment.
|
|
23
|
+
*
|
|
24
|
+
* The three values are exactly the three ways {@link pickHighestPriorityNotePath} (plus its empty-list
|
|
25
|
+
* guard) can fail to name a winner, so a caller can tell the user the real reason instead of only
|
|
26
|
+
* reporting that the attachment is referenced by several notes.
|
|
27
|
+
*/
|
|
28
|
+
export declare enum NoPriorityWinnerReason {
|
|
29
|
+
/**
|
|
30
|
+
* The priority list is empty — its default. Nothing was configured to decide between the notes.
|
|
31
|
+
*/
|
|
32
|
+
EmptyList = "EmptyList",
|
|
33
|
+
/**
|
|
34
|
+
* The list has entries, but none of the referencing notes matches any of them.
|
|
35
|
+
*/
|
|
36
|
+
NoMatch = "NoMatch",
|
|
37
|
+
/**
|
|
38
|
+
* Several referencing notes tie for the best rank, so the list names no single owner.
|
|
39
|
+
*/
|
|
40
|
+
Tie = "Tie"
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Parameters for {@link filterHighestPriorityNotePaths}.
|
|
44
|
+
*
|
|
45
|
+
* The same question as {@link pickHighestPriorityNotePath} asks, so deliberately the same parameters:
|
|
46
|
+
* the two must be answered from identical inputs or they could disagree.
|
|
47
|
+
*/
|
|
48
|
+
export type FilterHighestPriorityNotePathsParams = PickHighestPriorityNotePathParams;
|
|
49
|
+
/**
|
|
50
|
+
* Parameters for {@link findNoPriorityWinnerReason}.
|
|
51
|
+
*/
|
|
52
|
+
export interface FindNoPriorityWinnerReasonParams extends PickHighestPriorityNotePathParams {
|
|
53
|
+
/**
|
|
54
|
+
* The priority list, highest priority first.
|
|
55
|
+
*/
|
|
56
|
+
readonly entries: readonly string[];
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* Parameters for {@link findNotePriorityRank}.
|
|
60
|
+
*/
|
|
61
|
+
export interface FindNotePriorityRankParams {
|
|
62
|
+
/**
|
|
63
|
+
* The priority list, highest priority first.
|
|
64
|
+
*/
|
|
65
|
+
readonly entries: readonly string[];
|
|
66
|
+
/**
|
|
67
|
+
* The note's frontmatter, or `null` when it has none.
|
|
68
|
+
*/
|
|
69
|
+
readonly frontmatter: null | Readonly<Record<string, unknown>>;
|
|
70
|
+
/**
|
|
71
|
+
* The vault-relative path of the note.
|
|
72
|
+
*/
|
|
73
|
+
readonly notePath: string;
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* Parameters for {@link pickHighestPriorityNotePath}.
|
|
77
|
+
*/
|
|
78
|
+
export interface PickHighestPriorityNotePathParams {
|
|
79
|
+
/**
|
|
80
|
+
* The vault-relative paths of the notes referencing the attachment.
|
|
81
|
+
*/
|
|
82
|
+
readonly notePaths: readonly string[];
|
|
83
|
+
/**
|
|
84
|
+
* The priority rank of a note. Lower wins; {@link NO_PRIORITY_MATCH} means the note matched nothing.
|
|
85
|
+
*
|
|
86
|
+
* @param notePath - The vault-relative path of the note.
|
|
87
|
+
* @returns The rank.
|
|
88
|
+
*/
|
|
89
|
+
readonly rank: (notePath: string) => number;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* The rank of a note that matches no entry in the priority list. Higher than any real rank, so a note
|
|
93
|
+
* that matches nothing always loses to one that matches something.
|
|
94
|
+
*/
|
|
95
|
+
export declare const NO_PRIORITY_MATCH: number;
|
|
96
|
+
/**
|
|
97
|
+
* Narrows the referencing notes to the ones sharing the best rank.
|
|
98
|
+
*
|
|
99
|
+
* Those notes are the whole of the ambiguity: one the list ranked below them cannot resolve anything,
|
|
100
|
+
* so reporting it only adds noise. This mirrors {@link pickHighestPriorityNotePath}'s conditions
|
|
101
|
+
* rather than re-deciding anything, so the two can only ever agree — whenever that names a winner,
|
|
102
|
+
* this returns exactly that one note.
|
|
103
|
+
*
|
|
104
|
+
* A list that decides nothing at all — empty, or matching no note — ranks every note
|
|
105
|
+
* {@link NO_PRIORITY_MATCH}, so they all tie and every one of them is kept. That is the same list the
|
|
106
|
+
* user saw before, which is correct: nothing has ruled any of them out.
|
|
107
|
+
*
|
|
108
|
+
* @param params - The referencing notes and how to rank one.
|
|
109
|
+
* @returns The notes holding the best rank, in the order they were given.
|
|
110
|
+
*/
|
|
111
|
+
export declare function filterHighestPriorityNotePaths(params: FilterHighestPriorityNotePathsParams): string[];
|
|
112
|
+
/**
|
|
113
|
+
* Explains why the priority list named no owner for an attachment.
|
|
114
|
+
*
|
|
115
|
+
* Only meaningful once {@link pickHighestPriorityNotePath} has returned `null` (or the list was empty
|
|
116
|
+
* and was never consulted); it mirrors that function's own conditions rather than re-deciding
|
|
117
|
+
* anything, so the two can only ever agree.
|
|
118
|
+
*
|
|
119
|
+
* @param params - The priority list, the referencing notes, and how to rank one.
|
|
120
|
+
* @returns Which of the three ways the list failed to settle it.
|
|
121
|
+
*/
|
|
122
|
+
export declare function findNoPriorityWinnerReason(params: FindNoPriorityWinnerReasonParams): NoPriorityWinnerReason;
|
|
123
|
+
/**
|
|
124
|
+
* Finds how highly a note ranks in the priority list.
|
|
125
|
+
*
|
|
126
|
+
* An entry matches in one of four ways, picked by its shape so that one list can express all of them:
|
|
127
|
+
*
|
|
128
|
+
* - `property:name` — the note's frontmatter has `name`; `property:name=value` also compares the value.
|
|
129
|
+
* - `/regular expression/` — tested against the note's path.
|
|
130
|
+
* - `.ext` — the note's path ends with it, case-insensitively. This is the form the request asked for.
|
|
131
|
+
* - anything else — a path from the vault root, matching the vocabulary of the include / exclude
|
|
132
|
+
* path settings.
|
|
133
|
+
*
|
|
134
|
+
* When a note matches several entries the **longest** one decides its rank, so the most specific
|
|
135
|
+
* entry wins and the order of the list is left to express priority. Without this an Excalidraw note
|
|
136
|
+
* could never rank below a plain markdown one: `drawing.excalidraw.md` also ends with `.md`, so
|
|
137
|
+
* `.md` above `.excalidraw.md` — the very example the request is built on — would tie instead of
|
|
138
|
+
* resolving. Equal-length matches fall to the earlier entry.
|
|
139
|
+
*
|
|
140
|
+
* @param params - The parameters for finding the rank.
|
|
141
|
+
* @returns The index of the most specific matching entry, or {@link NO_PRIORITY_MATCH} when none match.
|
|
142
|
+
*/
|
|
143
|
+
export declare function findNotePriorityRank(params: FindNotePriorityRankParams): number;
|
|
144
|
+
/**
|
|
145
|
+
* Picks the single highest-priority note among those referencing an attachment.
|
|
146
|
+
*
|
|
147
|
+
* Returns `null` when the best rank is shared by more than one note, or when no note matches
|
|
148
|
+
* anything. Both are ties, and a tie is the caller's problem: it is what the multiple-notes mode
|
|
149
|
+
* setting is for.
|
|
150
|
+
*
|
|
151
|
+
* @param params - The parameters for picking the note.
|
|
152
|
+
* @returns The winning note's path, or `null` when there is no single winner.
|
|
153
|
+
*/
|
|
154
|
+
export declare function pickHighestPriorityNotePath(params: PickHighestPriorityNotePathParams): null | string;
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
/*
|
|
2
|
+
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
|
|
3
|
+
if you want to view the source, please visit the github repository of this plugin
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
(function () {
|
|
7
|
+
function ensureDisposeSymbols(symbolConstructor = Symbol) {
|
|
8
|
+
symbolConstructor.asyncDispose ??= symbolConstructor.for('Symbol.asyncDispose');
|
|
9
|
+
symbolConstructor.dispose ??= symbolConstructor.for('Symbol.dispose');
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
function ensureBrowserProcess() {
|
|
13
|
+
const browserProcess = {
|
|
14
|
+
browser: true,
|
|
15
|
+
cwd() {
|
|
16
|
+
return '/';
|
|
17
|
+
},
|
|
18
|
+
env: {},
|
|
19
|
+
platform: 'android'
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
// eslint-disable-next-line obsidianmd/no-global-this, unicorn/no-unnecessary-global-this -- Must stay `globalThis`-qualified: in the emitted banner a bare `process` is a free identifier, so reading it where the host has none throws a ReferenceError instead of yielding `undefined`. That is the very case this function exists to handle.
|
|
23
|
+
const existingProcess = globalThis.process;
|
|
24
|
+
|
|
25
|
+
if (!existingProcess) {
|
|
26
|
+
// eslint-disable-next-line obsidianmd/no-global-this -- Actively use globalThis.
|
|
27
|
+
globalThis.process = browserProcess;
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
if (existingProcess.versions?.node) {
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
const existingProcessRecord = existingProcess;
|
|
36
|
+
|
|
37
|
+
for (const [key, value] of Object.entries(browserProcess)) {
|
|
38
|
+
existingProcessRecord[key] ??= value;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
existingProcessRecord['browser'] = true;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
(function initEsm() {
|
|
45
|
+
ensureDisposeSymbols();
|
|
46
|
+
ensureBrowserProcess();
|
|
47
|
+
})();
|
|
48
|
+
})();
|
|
49
|
+
|
|
50
|
+
import { isValidRegExp } from "@mnaoumov/typescript-lib/reg-exp";
|
|
51
|
+
import {
|
|
52
|
+
checkPropertyEntryMatches,
|
|
53
|
+
isPropertyEntry
|
|
54
|
+
} from "./property-entry.mjs";
|
|
55
|
+
const REG_EXP_DELIMITER = "/";
|
|
56
|
+
const EXTENSION_PREFIX = ".";
|
|
57
|
+
var NoPriorityWinnerReason = /* @__PURE__ */ ((NoPriorityWinnerReason2) => {
|
|
58
|
+
NoPriorityWinnerReason2["EmptyList"] = "EmptyList";
|
|
59
|
+
NoPriorityWinnerReason2["NoMatch"] = "NoMatch";
|
|
60
|
+
NoPriorityWinnerReason2["Tie"] = "Tie";
|
|
61
|
+
return NoPriorityWinnerReason2;
|
|
62
|
+
})(NoPriorityWinnerReason || {});
|
|
63
|
+
const NO_PRIORITY_MATCH = Infinity;
|
|
64
|
+
function filterHighestPriorityNotePaths(params) {
|
|
65
|
+
const rankedNotePaths = params.notePaths.map((notePath) => ({
|
|
66
|
+
notePath,
|
|
67
|
+
rank: params.rank(notePath)
|
|
68
|
+
}));
|
|
69
|
+
let bestRank = NO_PRIORITY_MATCH;
|
|
70
|
+
for (const ranked of rankedNotePaths) {
|
|
71
|
+
if (ranked.rank < bestRank) {
|
|
72
|
+
bestRank = ranked.rank;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
return rankedNotePaths.filter((ranked) => ranked.rank === bestRank).map((ranked) => ranked.notePath);
|
|
76
|
+
}
|
|
77
|
+
function findNoPriorityWinnerReason(params) {
|
|
78
|
+
if (params.entries.length === 0) {
|
|
79
|
+
return "EmptyList" /* EmptyList */;
|
|
80
|
+
}
|
|
81
|
+
let bestRank = NO_PRIORITY_MATCH;
|
|
82
|
+
for (const notePath of params.notePaths) {
|
|
83
|
+
const currentRank = params.rank(notePath);
|
|
84
|
+
if (currentRank < bestRank) {
|
|
85
|
+
bestRank = currentRank;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
return bestRank === NO_PRIORITY_MATCH ? "NoMatch" /* NoMatch */ : "Tie" /* Tie */;
|
|
89
|
+
}
|
|
90
|
+
function findNotePriorityRank(params) {
|
|
91
|
+
let bestRank = NO_PRIORITY_MATCH;
|
|
92
|
+
let bestLength = -1;
|
|
93
|
+
for (const [index, entry] of params.entries.entries()) {
|
|
94
|
+
if (entry.length <= bestLength || !checkEntryMatches(entry, params)) {
|
|
95
|
+
continue;
|
|
96
|
+
}
|
|
97
|
+
bestRank = index;
|
|
98
|
+
bestLength = entry.length;
|
|
99
|
+
}
|
|
100
|
+
return bestRank;
|
|
101
|
+
}
|
|
102
|
+
function pickHighestPriorityNotePath(params) {
|
|
103
|
+
let bestRank = NO_PRIORITY_MATCH;
|
|
104
|
+
let bestNotePath = null;
|
|
105
|
+
let bestCount = 0;
|
|
106
|
+
for (const notePath of params.notePaths) {
|
|
107
|
+
const currentRank = params.rank(notePath);
|
|
108
|
+
if (currentRank < bestRank) {
|
|
109
|
+
bestRank = currentRank;
|
|
110
|
+
bestNotePath = notePath;
|
|
111
|
+
bestCount = 1;
|
|
112
|
+
} else if (currentRank === bestRank) {
|
|
113
|
+
bestCount++;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
return bestCount !== 1 || bestRank === NO_PRIORITY_MATCH ? null : bestNotePath;
|
|
117
|
+
}
|
|
118
|
+
function checkEntryMatches(entry, params) {
|
|
119
|
+
if (!entry) {
|
|
120
|
+
return false;
|
|
121
|
+
}
|
|
122
|
+
if (isPropertyEntry(entry)) {
|
|
123
|
+
return checkPropertyEntryMatches({ entry, frontmatter: params.frontmatter });
|
|
124
|
+
}
|
|
125
|
+
if (entry.length > 1 && entry.startsWith(REG_EXP_DELIMITER) && entry.endsWith(REG_EXP_DELIMITER)) {
|
|
126
|
+
const source = entry.slice(1, -1);
|
|
127
|
+
return isValidRegExp(source) && new RegExp(source).test(params.notePath);
|
|
128
|
+
}
|
|
129
|
+
if (entry.startsWith(EXTENSION_PREFIX)) {
|
|
130
|
+
return params.notePath.toLowerCase().endsWith(entry.toLowerCase());
|
|
131
|
+
}
|
|
132
|
+
const prefix = entry.endsWith("/") ? entry : `${entry}/`;
|
|
133
|
+
return params.notePath === entry || params.notePath.startsWith(prefix);
|
|
134
|
+
}
|
|
135
|
+
export {
|
|
136
|
+
NO_PRIORITY_MATCH,
|
|
137
|
+
NoPriorityWinnerReason,
|
|
138
|
+
filterHighestPriorityNotePaths,
|
|
139
|
+
findNoPriorityWinnerReason,
|
|
140
|
+
findNotePriorityRank,
|
|
141
|
+
pickHighestPriorityNotePath
|
|
142
|
+
};
|
|
143
|
+
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vLi4vc3JjL25vdGUtcHJpb3JpdHkudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbIi8qKlxuICogQGZpbGVcbiAqXG4gKiBEZWNpZGVzIHdoaWNoIG9mIHNldmVyYWwgbm90ZXMgcmVmZXJlbmNpbmcgdG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EsU0FBTyxjQUFjLEtBQUssYUFBYSxvQkFBb0IsT0FBTztBQUNwRTtBQUVBLFNBQVMsa0JBQWtCLE9BQWUsUUFBNkM7QUFDckYsTUFBSSxDQUFDLE9BQU87QUFDVixXQUFPO0FBQUEsRUFDVDtBQUVBLE1BQUksZ0JBQWdCLEtBQUssR0FBRztBQUMxQixXQUFPLDBCQUEwQixFQUFFLE9BQU8sYUFBYSxPQUFPLFlBQVksQ0FBQztBQUFBLEVBQzdFO0FBRUEsTUFBSSxNQUFNLFNBQVMsS0FBSyxNQUFNLFdBQVcsaUJBQWlCLEtBQUssTUFBTSxTQUFTLGlCQUFpQixHQUFHO0FBQ2hHLFVBQU0sU0FBUyxNQUFNLE1BQU0sR0FBRyxFQUFFO0FBRWhDLFdBQU8sY0FBYyxNQUFNLEtBQUssSUFBSSxPQUFPLE1BQU0sRUFBRSxLQUFLLE9BQU8sUUFBUTtBQUFBLEVBQ3pFO0FBRUEsTUFBSSxNQUFNLFdBQVcsZ0JBQWdCLEdBQUc7QUFDdEMsV0FBTyxPQUFPLFNBQVMsWUFBWSxFQUFFLFNBQVMsTUFBTSxZQUFZLENBQUM7QUFBQSxFQUNuRTtBQUVBLFFBQU0sU0FBUyxNQUFNLFNBQVMsR0FBRyxJQUFJLFFBQVEsR0FBRyxLQUFLO0FBQ3JELFNBQU8sT0FBTyxhQUFhLFNBQVMsT0FBTyxTQUFTLFdBQVcsTUFBTTtBQUN2RTsiLAogICJuYW1lcyI6IFsiTm9Qcmlvcml0eVdpbm5lclJlYXNvbiJdCn0K
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
/// <reference path="./library.d.mts" />
|
|
2
|
+
/**
|
|
3
|
+
* @file
|
|
4
|
+
*
|
|
5
|
+
* The slice of Notebook Navigator's public API this library talks to, and the runtime narrowing that
|
|
6
|
+
* gets hold of it.
|
|
7
|
+
*
|
|
8
|
+
* **Notebook Navigator draws its own file tree, so it never raises Obsidian's `file-menu` /
|
|
9
|
+
* `files-menu` workspace events** — which is why a plugin's context-menu items simply disappear for
|
|
10
|
+
* anyone browsing through it. What it offers instead is a documented extension API
|
|
11
|
+
* (`docs/api-reference.md` + `src/api/public/notebook-navigator.d.ts` in `johansan/notebook-navigator`,
|
|
12
|
+
* API 2.0.0), reachable at runtime as `app.plugins.getPlugin('notebook-navigator').api`.
|
|
13
|
+
*
|
|
14
|
+
* The types below are DECLARED HERE rather than imported: Notebook Navigator ships its `.d.ts` for
|
|
15
|
+
* download, not as an npm package, and depending on it would turn an optional integration into a
|
|
16
|
+
* build-time dependency. They are deliberately the narrowest shape this library uses — the API also
|
|
17
|
+
* carries `metadata`, `navigation`, `selection`, `tagCollections`, `propertyNodes` and an event bus,
|
|
18
|
+
* none of which apply to a file/folder command surface.
|
|
19
|
+
*/
|
|
20
|
+
import type { App, MenuItem, TFile, TFolder } from 'obsidian';
|
|
21
|
+
/**
|
|
22
|
+
* Notebook Navigator's public API object, narrowed to what this library uses.
|
|
23
|
+
*/
|
|
24
|
+
export interface NotebookNavigatorApi {
|
|
25
|
+
/**
|
|
26
|
+
* The menu-extension namespace.
|
|
27
|
+
*/
|
|
28
|
+
readonly menus: NotebookNavigatorMenus;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* What `menus.registerFileMenu` hands a subscriber when a FILE is right-clicked.
|
|
32
|
+
*
|
|
33
|
+
* There is no `Menu` here — an item is contributed through `addItem` alone, which is why the
|
|
34
|
+
* file/files menu handlers cannot simply be forwarded to it and have to be bridged (see
|
|
35
|
+
* `components/notebook-navigator-menu-event-registrar-component.ts`).
|
|
36
|
+
*/
|
|
37
|
+
export interface NotebookNavigatorFileMenuContext extends NotebookNavigatorMenuContext {
|
|
38
|
+
/**
|
|
39
|
+
* The file that was right-clicked.
|
|
40
|
+
*/
|
|
41
|
+
readonly file: TFile;
|
|
42
|
+
/**
|
|
43
|
+
* What the tree had selected when the menu was raised.
|
|
44
|
+
*/
|
|
45
|
+
readonly selection: NotebookNavigatorFileMenuSelection;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* The selection a file menu was raised on.
|
|
49
|
+
*/
|
|
50
|
+
export interface NotebookNavigatorFileMenuSelection {
|
|
51
|
+
/**
|
|
52
|
+
* Every selected file, which for `single` is just the right-clicked one.
|
|
53
|
+
*/
|
|
54
|
+
readonly files: readonly TFile[];
|
|
55
|
+
/**
|
|
56
|
+
* Whether one file or several are selected.
|
|
57
|
+
*/
|
|
58
|
+
readonly mode: NotebookNavigatorFileMenuSelectionMode;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Whether a file menu covers one file or a multi-selection.
|
|
62
|
+
*/
|
|
63
|
+
export type NotebookNavigatorFileMenuSelectionMode = 'multiple' | 'single';
|
|
64
|
+
/**
|
|
65
|
+
* What `menus.registerFolderMenu` hands a subscriber when a FOLDER is right-clicked.
|
|
66
|
+
*/
|
|
67
|
+
export interface NotebookNavigatorFolderMenuContext extends NotebookNavigatorMenuContext {
|
|
68
|
+
/**
|
|
69
|
+
* The folder that was right-clicked.
|
|
70
|
+
*/
|
|
71
|
+
readonly folder: TFolder;
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* What every Notebook Navigator menu context has in common: a way to add an item, and nothing else.
|
|
75
|
+
*
|
|
76
|
+
* The absence of a `Menu` is the whole shape of the integration problem — command handlers write into
|
|
77
|
+
* a `Menu`, so something has to sit between them and this.
|
|
78
|
+
*/
|
|
79
|
+
export interface NotebookNavigatorMenuContext {
|
|
80
|
+
/**
|
|
81
|
+
* Adds an item to the menu Notebook Navigator is building.
|
|
82
|
+
*
|
|
83
|
+
* @param callback - Receives the created item, to be configured in place.
|
|
84
|
+
*/
|
|
85
|
+
addItem: (callback: (item: MenuItem) => void) => void;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Unregisters a menu extension. Notebook Navigator returns a bare function rather than a disposable,
|
|
89
|
+
* so it is registered with the bridging component's `register`.
|
|
90
|
+
*/
|
|
91
|
+
export type NotebookNavigatorMenuDispose = () => void;
|
|
92
|
+
/**
|
|
93
|
+
* The `menus` namespace of Notebook Navigator's API.
|
|
94
|
+
*
|
|
95
|
+
* Only the file and folder registrars are declared: the tag and property registrars extend menus
|
|
96
|
+
* raised on things a file/folder command handler has no counterpart for.
|
|
97
|
+
*/
|
|
98
|
+
export interface NotebookNavigatorMenus {
|
|
99
|
+
/**
|
|
100
|
+
* Registers a contributor to the file context menu.
|
|
101
|
+
*
|
|
102
|
+
* @param callback - Invoked while the menu is being built.
|
|
103
|
+
* @returns A function that unregisters the contributor.
|
|
104
|
+
*/
|
|
105
|
+
registerFileMenu: (callback: (context: NotebookNavigatorFileMenuContext) => void) => NotebookNavigatorMenuDispose;
|
|
106
|
+
/**
|
|
107
|
+
* Registers a contributor to the folder context menu.
|
|
108
|
+
*
|
|
109
|
+
* @param callback - Invoked while the menu is being built.
|
|
110
|
+
* @returns A function that unregisters the contributor.
|
|
111
|
+
*/
|
|
112
|
+
registerFolderMenu: (callback: (context: NotebookNavigatorFolderMenuContext) => void) => NotebookNavigatorMenuDispose;
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* The `source` handed to the menu event handlers for a Notebook Navigator menu.
|
|
116
|
+
*
|
|
117
|
+
* Obsidian's own File Explorer sends `file-explorer-context-menu`; nothing in this library gates on
|
|
118
|
+
* the value, but the handlers are contracted to receive one, and a distinct string is what makes a
|
|
119
|
+
* handler able to tell the two surfaces apart.
|
|
120
|
+
*/
|
|
121
|
+
export declare const NOTEBOOK_NAVIGATOR_MENU_SOURCE = "notebook-navigator-context-menu";
|
|
122
|
+
/**
|
|
123
|
+
* Notebook Navigator's plugin id, as its manifest declares it.
|
|
124
|
+
*/
|
|
125
|
+
export declare const NOTEBOOK_NAVIGATOR_PLUGIN_ID = "notebook-navigator";
|
|
126
|
+
/**
|
|
127
|
+
* Gets Notebook Navigator's API, when it is installed, enabled and new enough.
|
|
128
|
+
*
|
|
129
|
+
* @param app - The application instance.
|
|
130
|
+
* @returns The API, or `null` when Notebook Navigator is not there to talk to.
|
|
131
|
+
*/
|
|
132
|
+
export declare function resolveNotebookNavigatorApi(app: App): NotebookNavigatorApi | null;
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/*
|
|
2
|
+
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
|
|
3
|
+
if you want to view the source, please visit the github repository of this plugin
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
(function () {
|
|
7
|
+
function ensureDisposeSymbols(symbolConstructor = Symbol) {
|
|
8
|
+
symbolConstructor.asyncDispose ??= symbolConstructor.for('Symbol.asyncDispose');
|
|
9
|
+
symbolConstructor.dispose ??= symbolConstructor.for('Symbol.dispose');
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
function ensureBrowserProcess() {
|
|
13
|
+
const browserProcess = {
|
|
14
|
+
browser: true,
|
|
15
|
+
cwd() {
|
|
16
|
+
return '/';
|
|
17
|
+
},
|
|
18
|
+
env: {},
|
|
19
|
+
platform: 'android'
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
// eslint-disable-next-line obsidianmd/no-global-this, unicorn/no-unnecessary-global-this -- Must stay `globalThis`-qualified: in the emitted banner a bare `process` is a free identifier, so reading it where the host has none throws a ReferenceError instead of yielding `undefined`. That is the very case this function exists to handle.
|
|
23
|
+
const existingProcess = globalThis.process;
|
|
24
|
+
|
|
25
|
+
if (!existingProcess) {
|
|
26
|
+
// eslint-disable-next-line obsidianmd/no-global-this -- Actively use globalThis.
|
|
27
|
+
globalThis.process = browserProcess;
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
if (existingProcess.versions?.node) {
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
const existingProcessRecord = existingProcess;
|
|
36
|
+
|
|
37
|
+
for (const [key, value] of Object.entries(browserProcess)) {
|
|
38
|
+
existingProcessRecord[key] ??= value;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
existingProcessRecord['browser'] = true;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
(function initEsm() {
|
|
45
|
+
ensureDisposeSymbols();
|
|
46
|
+
ensureBrowserProcess();
|
|
47
|
+
})();
|
|
48
|
+
})();
|
|
49
|
+
|
|
50
|
+
const NOTEBOOK_NAVIGATOR_MENU_SOURCE = "notebook-navigator-context-menu";
|
|
51
|
+
const NOTEBOOK_NAVIGATOR_PLUGIN_ID = "notebook-navigator";
|
|
52
|
+
function resolveNotebookNavigatorApi(app) {
|
|
53
|
+
const plugin = app.plugins.getPlugin(NOTEBOOK_NAVIGATOR_PLUGIN_ID);
|
|
54
|
+
if (!plugin || !("api" in plugin)) {
|
|
55
|
+
return null;
|
|
56
|
+
}
|
|
57
|
+
const api = plugin.api;
|
|
58
|
+
return isNotebookNavigatorApi(api) ? api : null;
|
|
59
|
+
}
|
|
60
|
+
function isNotebookNavigatorApi(value) {
|
|
61
|
+
if (typeof value !== "object" || value === null || !("menus" in value)) {
|
|
62
|
+
return false;
|
|
63
|
+
}
|
|
64
|
+
const menus = value.menus;
|
|
65
|
+
return typeof menus === "object" && menus !== null && "registerFileMenu" in menus && typeof menus.registerFileMenu === "function" && "registerFolderMenu" in menus && typeof menus.registerFolderMenu === "function";
|
|
66
|
+
}
|
|
67
|
+
export {
|
|
68
|
+
NOTEBOOK_NAVIGATOR_MENU_SOURCE,
|
|
69
|
+
NOTEBOOK_NAVIGATOR_PLUGIN_ID,
|
|
70
|
+
resolveNotebookNavigatorApi
|
|
71
|
+
};
|
|
72
|
+
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vLi4vc3JjL25vdGVib29rLW5hdmlnYXRvci50cyJdLAogICJzb3VyY2VzQ29udGVudCI6IFsiLyoqXG4gKiBAZmlsZVxuICpcbiAqIFRoZSBzbGljZSBvZiBOb3RlYm9vayBOYXZpZ2F0b3IncyBwdWJsaWMgQVBJIHRoa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