@mnaoumov/obsidian-lib 0.0.0 → 1.0.1
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 +15 -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 +1656 -0
- package/dist/lib/cjs/__merged.d.cts +205 -0
- package/dist/lib/cjs/active-file-provider.cjs +161 -0
- package/dist/lib/cjs/active-file-provider.d.cts +36 -0
- package/dist/lib/cjs/app.cjs +153 -0
- package/dist/lib/cjs/app.d.cts +17 -0
- package/dist/lib/cjs/async-with-notice.cjs +235 -0
- package/dist/lib/cjs/async-with-notice.d.cts +113 -0
- package/dist/lib/cjs/attachment-path.cjs +379 -0
- package/dist/lib/cjs/attachment-path.d.cts +341 -0
- package/dist/lib/cjs/attachment-unit-folder.cjs +168 -0
- package/dist/lib/cjs/attachment-unit-folder.d.cts +103 -0
- package/dist/lib/cjs/backlink-index.cjs +249 -0
- package/dist/lib/cjs/backlink-index.d.cts +51 -0
- package/dist/lib/cjs/backlink.cjs +217 -0
- package/dist/lib/cjs/backlink.d.cts +66 -0
- package/dist/lib/cjs/bases-view-registrar.cjs +162 -0
- package/dist/lib/cjs/bases-view-registrar.d.cts +52 -0
- package/dist/lib/cjs/callout.cjs +220 -0
- package/dist/lib/cjs/callout.d.cts +76 -0
- package/dist/lib/cjs/canvas.cjs +215 -0
- package/dist/lib/cjs/canvas.d.cts +28 -0
- package/dist/lib/cjs/case-insensitive-file-index.cjs +244 -0
- package/dist/lib/cjs/case-insensitive-file-index.d.cts +92 -0
- package/dist/lib/cjs/code-block-markdown-information.cjs +131 -0
- package/dist/lib/cjs/code-block-markdown-information.d.cts +48 -0
- package/dist/lib/cjs/code-block-reg-exp.cjs +145 -0
- package/dist/lib/cjs/code-block-reg-exp.d.cts +39 -0
- package/dist/lib/cjs/codemirror/index.cjs +153 -0
- package/dist/lib/cjs/codemirror/index.d.cts +2 -0
- package/dist/lib/cjs/codemirror/state-field-spec.cjs +131 -0
- package/dist/lib/cjs/codemirror/state-field-spec.d.cts +72 -0
- package/dist/lib/cjs/command-handlers/abstract-file-command-handler.cjs +416 -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 +278 -0
- package/dist/lib/cjs/command-handlers/command-handler-component.d.cts +146 -0
- package/dist/lib/cjs/command-handlers/command-handler.cjs +200 -0
- package/dist/lib/cjs/command-handlers/command-handler.d.cts +107 -0
- package/dist/lib/cjs/command-handlers/editor-command-handler.cjs +348 -0
- package/dist/lib/cjs/command-handlers/editor-command-handler.d.cts +208 -0
- package/dist/lib/cjs/command-handlers/file-command-handler.cjs +285 -0
- package/dist/lib/cjs/command-handlers/file-command-handler.d.cts +143 -0
- package/dist/lib/cjs/command-handlers/folder-command-handler.cjs +293 -0
- package/dist/lib/cjs/command-handlers/folder-command-handler.d.cts +149 -0
- package/dist/lib/cjs/command-handlers/global-command-handler.cjs +185 -0
- package/dist/lib/cjs/command-handlers/global-command-handler.d.cts +40 -0
- package/dist/lib/cjs/command-handlers/index.cjs +180 -0
- package/dist/lib/cjs/command-handlers/index.d.cts +11 -0
- package/dist/lib/cjs/command-handlers/open-demo-vault-command-handler.cjs +209 -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 +174 -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 +187 -0
- package/dist/lib/cjs/command-handlers/unlock-active-note-command-handler.d.cts +54 -0
- package/dist/lib/cjs/command-registrar.cjs +169 -0
- package/dist/lib/cjs/command-registrar.d.cts +48 -0
- package/dist/lib/cjs/community-plugins.cjs +322 -0
- package/dist/lib/cjs/community-plugins.d.cts +270 -0
- package/dist/lib/cjs/components/abort-signal-component.cjs +172 -0
- package/dist/lib/cjs/components/abort-signal-component.d.cts +30 -0
- package/dist/lib/cjs/components/all-windows-event-component.cjs +214 -0
- package/dist/lib/cjs/components/all-windows-event-component.d.cts +84 -0
- package/dist/lib/cjs/components/async-error-handler-component.cjs +176 -0
- package/dist/lib/cjs/components/async-error-handler-component.d.cts +30 -0
- package/dist/lib/cjs/components/async-events-component.cjs +148 -0
- package/dist/lib/cjs/components/async-events-component.d.cts +15 -0
- package/dist/lib/cjs/components/case-insensitive-file-index-component.cjs +186 -0
- package/dist/lib/cjs/components/case-insensitive-file-index-component.d.cts +36 -0
- package/dist/lib/cjs/components/component-ex.cjs +504 -0
- package/dist/lib/cjs/components/component-ex.d.cts +229 -0
- package/dist/lib/cjs/components/console-debug-component.cjs +170 -0
- package/dist/lib/cjs/components/console-debug-component.d.cts +30 -0
- package/dist/lib/cjs/components/core-plugin-toggle-component.cjs +202 -0
- package/dist/lib/cjs/components/core-plugin-toggle-component.d.cts +102 -0
- package/dist/lib/cjs/components/disposable-component.cjs +154 -0
- package/dist/lib/cjs/components/disposable-component.d.cts +24 -0
- package/dist/lib/cjs/components/embed-extensions-component.cjs +174 -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 +170 -0
- package/dist/lib/cjs/components/generate-markdown-link-default-params-component.d.cts +42 -0
- package/dist/lib/cjs/components/index.cjs +237 -0
- package/dist/lib/cjs/components/index.d.cts +30 -0
- package/dist/lib/cjs/components/layout-ready-component.cjs +211 -0
- package/dist/lib/cjs/components/layout-ready-component.d.cts +48 -0
- package/dist/lib/cjs/components/menu-event-registrar-component.cjs +196 -0
- package/dist/lib/cjs/components/menu-event-registrar-component.d.cts +52 -0
- package/dist/lib/cjs/components/monkey-around-component.cjs +245 -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 +321 -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 +180 -0
- package/dist/lib/cjs/components/plugin-context-component.d.cts +36 -0
- package/dist/lib/cjs/components/plugin-gate-component.cjs +548 -0
- package/dist/lib/cjs/components/plugin-gate-component.d.cts +332 -0
- package/dist/lib/cjs/components/plugin-notice-component.cjs +629 -0
- package/dist/lib/cjs/components/plugin-notice-component.d.cts +362 -0
- package/dist/lib/cjs/components/plugin-settings-component.cjs +644 -0
- package/dist/lib/cjs/components/plugin-settings-component.d.cts +362 -0
- package/dist/lib/cjs/components/plugin-settings-tab-component.cjs +170 -0
- package/dist/lib/cjs/components/plugin-settings-tab-component.d.cts +39 -0
- package/dist/lib/cjs/components/plugin-suggestion-component.cjs +278 -0
- package/dist/lib/cjs/components/plugin-suggestion-component.d.cts +162 -0
- package/dist/lib/cjs/components/pointer-position-component.cjs +166 -0
- package/dist/lib/cjs/components/pointer-position-component.d.cts +29 -0
- package/dist/lib/cjs/components/registry-component.cjs +187 -0
- package/dist/lib/cjs/components/registry-component.d.cts +37 -0
- package/dist/lib/cjs/components/release-notes-component.cjs +225 -0
- package/dist/lib/cjs/components/release-notes-component.d.cts +129 -0
- package/dist/lib/cjs/components/rename-delete-handler-component.cjs +1275 -0
- package/dist/lib/cjs/components/rename-delete-handler-component.d.cts +165 -0
- package/dist/lib/cjs/components/rmdir-guard-component.cjs +190 -0
- package/dist/lib/cjs/components/rmdir-guard-component.d.cts +76 -0
- package/dist/lib/cjs/components/settings-migration-component.cjs +222 -0
- package/dist/lib/cjs/components/settings-migration-component.d.cts +120 -0
- package/dist/lib/cjs/components/syntax-highlighting-component.cjs +248 -0
- package/dist/lib/cjs/components/syntax-highlighting-component.d.cts +149 -0
- package/dist/lib/cjs/components/templates-language-component.cjs +276 -0
- package/dist/lib/cjs/components/templates-language-component.d.cts +124 -0
- package/dist/lib/cjs/constructors/get-dom-events-handlers-constructor.cjs +246 -0
- package/dist/lib/cjs/constructors/get-dom-events-handlers-constructor.d.cts +22 -0
- package/dist/lib/cjs/constructors/index.cjs +153 -0
- package/dist/lib/cjs/constructors/index.d.cts +2 -0
- package/dist/lib/cjs/css-class.cjs +208 -0
- package/dist/lib/cjs/css-class.d.cts +278 -0
- package/dist/lib/cjs/data-handler.cjs +170 -0
- package/dist/lib/cjs/data-handler.d.cts +49 -0
- package/dist/lib/cjs/dataview-link.cjs +160 -0
- package/dist/lib/cjs/dataview-link.d.cts +42 -0
- package/dist/lib/cjs/dataview.cjs +379 -0
- package/dist/lib/cjs/dataview.d.cts +249 -0
- package/dist/lib/cjs/debug.cjs +148 -0
- package/dist/lib/cjs/debug.d.cts +19 -0
- package/dist/lib/cjs/demo-vault-helper-settings.cjs +131 -0
- package/dist/lib/cjs/demo-vault-helper-settings.d.cts +29 -0
- package/dist/lib/cjs/demo-vault-helper.cjs +232 -0
- package/dist/lib/cjs/demo-vault-helper.d.cts +61 -0
- package/dist/lib/cjs/demo-vault-naming.cjs +157 -0
- package/dist/lib/cjs/demo-vault-naming.d.cts +54 -0
- package/dist/lib/cjs/desktop-demo-vault-opener.cjs +348 -0
- package/dist/lib/cjs/desktop-demo-vault-opener.d.cts +76 -0
- package/dist/lib/cjs/desktop-trusted-input.cjs +301 -0
- package/dist/lib/cjs/desktop-trusted-input.d.cts +288 -0
- package/dist/lib/cjs/editor-extension-registrar.cjs +162 -0
- package/dist/lib/cjs/editor-extension-registrar.d.cts +37 -0
- package/dist/lib/cjs/editor-suggest-registrar.cjs +162 -0
- package/dist/lib/cjs/editor-suggest-registrar.d.cts +36 -0
- package/dist/lib/cjs/editor.cjs +200 -0
- package/dist/lib/cjs/editor.d.cts +45 -0
- package/dist/lib/cjs/events.cjs +172 -0
- package/dist/lib/cjs/events.d.cts +98 -0
- package/dist/lib/cjs/extensions-registrar.cjs +162 -0
- package/dist/lib/cjs/extensions-registrar.d.cts +51 -0
- package/dist/lib/cjs/file-change.cjs +558 -0
- package/dist/lib/cjs/file-change.d.cts +156 -0
- package/dist/lib/cjs/file-explorer.cjs +157 -0
- package/dist/lib/cjs/file-explorer.d.cts +34 -0
- package/dist/lib/cjs/file-manager.cjs +251 -0
- package/dist/lib/cjs/file-manager.d.cts +123 -0
- package/dist/lib/cjs/file-system.cjs +571 -0
- package/dist/lib/cjs/file-system.d.cts +554 -0
- package/dist/lib/cjs/folder-note.cjs +261 -0
- package/dist/lib/cjs/folder-note.d.cts +166 -0
- package/dist/lib/cjs/frontmatter-formatting.cjs +448 -0
- package/dist/lib/cjs/frontmatter-formatting.d.cts +44 -0
- package/dist/lib/cjs/frontmatter-link-cache-with-offsets.cjs +159 -0
- package/dist/lib/cjs/frontmatter-link-cache-with-offsets.d.cts +34 -0
- package/dist/lib/cjs/frontmatter.cjs +271 -0
- package/dist/lib/cjs/frontmatter.d.cts +145 -0
- package/dist/lib/cjs/generated-during-build.cjs +146 -0
- package/dist/lib/cjs/generated-during-build.d.cts +25 -0
- package/dist/lib/cjs/hover-link-source-registrar.cjs +162 -0
- package/dist/lib/cjs/hover-link-source-registrar.d.cts +52 -0
- package/dist/lib/cjs/html-element.cjs +183 -0
- package/dist/lib/cjs/html-element.d.cts +98 -0
- package/dist/lib/cjs/i18n/custom-type-options.cjs +132 -0
- package/dist/lib/cjs/i18n/custom-type-options.d.cts +38 -0
- package/dist/lib/cjs/i18n/default-translations.cjs +132 -0
- package/dist/lib/cjs/i18n/default-translations.d.cts +15 -0
- package/dist/lib/cjs/i18n/i18n.cjs +192 -0
- package/dist/lib/cjs/i18n/i18n.d.cts +38 -0
- package/dist/lib/cjs/i18n/index.cjs +162 -0
- package/dist/lib/cjs/i18n/index.d.cts +5 -0
- package/dist/lib/cjs/i18n/locales/en.cjs +224 -0
- package/dist/lib/cjs/i18n/locales/en.d.cts +91 -0
- package/dist/lib/cjs/i18n/locales/index.cjs +156 -0
- package/dist/lib/cjs/i18n/locales/index.d.cts +3 -0
- package/dist/lib/cjs/i18n/locales/translations-map.cjs +150 -0
- package/dist/lib/cjs/i18n/locales/translations-map.d.cts +100 -0
- package/dist/lib/cjs/index.cjs +435 -0
- package/dist/lib/cjs/index.d.cts +96 -0
- package/dist/lib/cjs/is-in-obsidian.cjs +154 -0
- package/dist/lib/cjs/is-in-obsidian.d.cts +12 -0
- package/dist/lib/cjs/library-styles.cjs +173 -0
- package/dist/lib/cjs/library-styles.d.cts +56 -0
- package/dist/lib/cjs/library.cjs +181 -0
- package/dist/lib/cjs/library.d.cts +57 -0
- package/dist/lib/cjs/link-name.cjs +145 -0
- package/dist/lib/cjs/link-name.d.cts +23 -0
- package/dist/lib/cjs/link-update-progress.cjs +131 -0
- package/dist/lib/cjs/link-update-progress.d.cts +32 -0
- package/dist/lib/cjs/link.cjs +1053 -0
- package/dist/lib/cjs/link.d.cts +1369 -0
- package/dist/lib/cjs/logger.cjs +212 -0
- package/dist/lib/cjs/logger.d.cts +37 -0
- package/dist/lib/cjs/loop.cjs +243 -0
- package/dist/lib/cjs/loop.d.cts +104 -0
- package/dist/lib/cjs/markdown-code-block-processor-registrar.cjs +166 -0
- package/dist/lib/cjs/markdown-code-block-processor-registrar.d.cts +62 -0
- package/dist/lib/cjs/markdown-code-block-processor.cjs +444 -0
- package/dist/lib/cjs/markdown-code-block-processor.d.cts +137 -0
- package/dist/lib/cjs/markdown-post-processor-registrar.cjs +163 -0
- package/dist/lib/cjs/markdown-post-processor-registrar.d.cts +59 -0
- package/dist/lib/cjs/markdown-view.cjs +151 -0
- package/dist/lib/cjs/markdown-view.d.cts +14 -0
- package/dist/lib/cjs/markdown.cjs +470 -0
- package/dist/lib/cjs/markdown.d.cts +226 -0
- package/dist/lib/cjs/menu-event-registrar.cjs +131 -0
- package/dist/lib/cjs/menu-event-registrar.d.cts +84 -0
- package/dist/lib/cjs/metadata-cache.cjs +544 -0
- package/dist/lib/cjs/metadata-cache.d.cts +359 -0
- package/dist/lib/cjs/mobile-trusted-input.cjs +185 -0
- package/dist/lib/cjs/mobile-trusted-input.d.cts +98 -0
- package/dist/lib/cjs/modals/alert.cjs +178 -0
- package/dist/lib/cjs/modals/alert.d.cts +35 -0
- package/dist/lib/cjs/modals/confirm.cjs +188 -0
- package/dist/lib/cjs/modals/confirm.d.cts +39 -0
- package/dist/lib/cjs/modals/index.cjs +177 -0
- package/dist/lib/cjs/modals/index.d.cts +10 -0
- package/dist/lib/cjs/modals/minimizable-modal.cjs +441 -0
- package/dist/lib/cjs/modals/minimizable-modal.d.cts +129 -0
- package/dist/lib/cjs/modals/modal-command-builder.cjs +458 -0
- package/dist/lib/cjs/modals/modal-command-builder.d.cts +285 -0
- package/dist/lib/cjs/modals/modal.cjs +176 -0
- package/dist/lib/cjs/modals/modal.d.cts +64 -0
- package/dist/lib/cjs/modals/prompt.cjs +256 -0
- package/dist/lib/cjs/modals/prompt.d.cts +83 -0
- package/dist/lib/cjs/modals/select-item.cjs +201 -0
- package/dist/lib/cjs/modals/select-item.d.cts +55 -0
- package/dist/lib/cjs/modals/select-option.cjs +189 -0
- package/dist/lib/cjs/modals/select-option.d.cts +65 -0
- package/dist/lib/cjs/modals/suggest-modal-command-builder.cjs +144 -0
- package/dist/lib/cjs/modals/suggest-modal-command-builder.d.cts +35 -0
- package/dist/lib/cjs/note-priority.cjs +234 -0
- package/dist/lib/cjs/note-priority.d.cts +154 -0
- package/dist/lib/cjs/notebook-navigator.cjs +163 -0
- package/dist/lib/cjs/notebook-navigator.d.cts +132 -0
- package/dist/lib/cjs/obsidian-dev-utils-state.cjs +175 -0
- package/dist/lib/cjs/obsidian-dev-utils-state.d.cts +42 -0
- package/dist/lib/cjs/obsidian-protocol-handler-registrar.cjs +165 -0
- package/dist/lib/cjs/obsidian-protocol-handler-registrar.d.cts +55 -0
- package/dist/lib/cjs/obsidian-settings.cjs +182 -0
- package/dist/lib/cjs/obsidian-settings.d.cts +62 -0
- package/dist/lib/cjs/parse-link.cjs +538 -0
- package/dist/lib/cjs/parse-link.d.cts +288 -0
- package/dist/lib/cjs/path-settings.cjs +269 -0
- package/dist/lib/cjs/path-settings.d.cts +56 -0
- package/dist/lib/cjs/pdf.cjs +173 -0
- package/dist/lib/cjs/pdf.d.cts +26 -0
- package/dist/lib/cjs/plugin/index.cjs +174 -0
- package/dist/lib/cjs/plugin/index.d.cts +9 -0
- package/dist/lib/cjs/plugin/plugin-api.cjs +519 -0
- package/dist/lib/cjs/plugin/plugin-api.d.cts +413 -0
- package/dist/lib/cjs/plugin/plugin-context.cjs +191 -0
- package/dist/lib/cjs/plugin/plugin-context.d.cts +27 -0
- package/dist/lib/cjs/plugin/plugin-event-source.cjs +226 -0
- package/dist/lib/cjs/plugin/plugin-event-source.d.cts +97 -0
- package/dist/lib/cjs/plugin/plugin-install-state.cjs +195 -0
- package/dist/lib/cjs/plugin/plugin-install-state.d.cts +113 -0
- package/dist/lib/cjs/plugin/plugin-lifecycle-events.cjs +151 -0
- package/dist/lib/cjs/plugin/plugin-lifecycle-events.d.cts +127 -0
- package/dist/lib/cjs/plugin/plugin-settings-tab.cjs +611 -0
- package/dist/lib/cjs/plugin/plugin-settings-tab.d.cts +368 -0
- package/dist/lib/cjs/plugin/plugin.cjs +706 -0
- package/dist/lib/cjs/plugin/plugin.d.cts +363 -0
- package/dist/lib/cjs/plugin/settings-migration-api.cjs +131 -0
- package/dist/lib/cjs/plugin/settings-migration-api.d.cts +91 -0
- package/dist/lib/cjs/plugin-cli-handler-registrar.cjs +163 -0
- package/dist/lib/cjs/plugin-cli-handler-registrar.d.cts +64 -0
- package/dist/lib/cjs/popovers/field-popover.cjs +182 -0
- package/dist/lib/cjs/popovers/field-popover.d.cts +75 -0
- package/dist/lib/cjs/popovers/index.cjs +159 -0
- package/dist/lib/cjs/popovers/index.d.cts +4 -0
- package/dist/lib/cjs/popovers/popover-anchor.cjs +182 -0
- package/dist/lib/cjs/popovers/popover-anchor.d.cts +67 -0
- package/dist/lib/cjs/popovers/popover.cjs +229 -0
- package/dist/lib/cjs/popovers/popover.d.cts +78 -0
- package/dist/lib/cjs/property-entry.cjs +172 -0
- package/dist/lib/cjs/property-entry.d.cts +43 -0
- package/dist/lib/cjs/queue.cjs +212 -0
- package/dist/lib/cjs/queue.d.cts +93 -0
- package/dist/lib/cjs/react/app-context.cjs +151 -0
- package/dist/lib/cjs/react/app-context.d.cts +24 -0
- package/dist/lib/cjs/react/index.cjs +153 -0
- package/dist/lib/cjs/react/index.d.cts +2 -0
- package/dist/lib/cjs/reference.cjs +186 -0
- package/dist/lib/cjs/reference.d.cts +116 -0
- package/dist/lib/cjs/resource-lock.cjs +1096 -0
- package/dist/lib/cjs/resource-lock.d.cts +318 -0
- package/dist/lib/cjs/resource-url.cjs +156 -0
- package/dist/lib/cjs/resource-url.d.cts +31 -0
- package/dist/lib/cjs/ribbon-icon-registrar.cjs +163 -0
- package/dist/lib/cjs/ribbon-icon-registrar.d.cts +60 -0
- package/dist/lib/cjs/setting-components/checkbox-component.cjs +216 -0
- package/dist/lib/cjs/setting-components/checkbox-component.d.cts +69 -0
- package/dist/lib/cjs/setting-components/code-highlighter-component.cjs +378 -0
- package/dist/lib/cjs/setting-components/code-highlighter-component.d.cts +132 -0
- package/dist/lib/cjs/setting-components/date-component.cjs +180 -0
- package/dist/lib/cjs/setting-components/date-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/date-time-component.cjs +180 -0
- package/dist/lib/cjs/setting-components/date-time-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/email-component.cjs +191 -0
- package/dist/lib/cjs/setting-components/email-component.d.cts +49 -0
- package/dist/lib/cjs/setting-components/file-component.cjs +183 -0
- package/dist/lib/cjs/setting-components/file-component.d.cts +43 -0
- package/dist/lib/cjs/setting-components/index.cjs +228 -0
- package/dist/lib/cjs/setting-components/index.d.cts +27 -0
- package/dist/lib/cjs/setting-components/month-component.cjs +188 -0
- package/dist/lib/cjs/setting-components/month-component.d.cts +51 -0
- package/dist/lib/cjs/setting-components/multiple-dropdown-component.cjs +253 -0
- package/dist/lib/cjs/setting-components/multiple-dropdown-component.d.cts +92 -0
- package/dist/lib/cjs/setting-components/multiple-email-component.cjs +177 -0
- package/dist/lib/cjs/setting-components/multiple-email-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/multiple-file-component.cjs +185 -0
- package/dist/lib/cjs/setting-components/multiple-file-component.d.cts +43 -0
- package/dist/lib/cjs/setting-components/multiple-text-component.cjs +272 -0
- package/dist/lib/cjs/setting-components/multiple-text-component.d.cts +109 -0
- package/dist/lib/cjs/setting-components/number-component.cjs +201 -0
- package/dist/lib/cjs/setting-components/number-component.d.cts +56 -0
- package/dist/lib/cjs/setting-components/password-component.cjs +177 -0
- package/dist/lib/cjs/setting-components/password-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/setting-component-wrapper.cjs +160 -0
- package/dist/lib/cjs/setting-components/setting-component-wrapper.d.cts +13 -0
- package/dist/lib/cjs/setting-components/telephone-component.cjs +191 -0
- package/dist/lib/cjs/setting-components/telephone-component.d.cts +51 -0
- package/dist/lib/cjs/setting-components/text-based-component.cjs +170 -0
- package/dist/lib/cjs/setting-components/text-based-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/time-component.cjs +185 -0
- package/dist/lib/cjs/setting-components/time-component.d.cts +38 -0
- package/dist/lib/cjs/setting-components/tri-state-checkbox-component.cjs +217 -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 +262 -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 +264 -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 +175 -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 +232 -0
- package/dist/lib/cjs/setting-components/typed-text-component.d.cts +100 -0
- package/dist/lib/cjs/setting-components/url-component.cjs +191 -0
- package/dist/lib/cjs/setting-components/url-component.d.cts +49 -0
- package/dist/lib/cjs/setting-components/validator-component.cjs +230 -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 +131 -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 +188 -0
- package/dist/lib/cjs/setting-components/week-component.d.cts +51 -0
- package/dist/lib/cjs/setting-ex.cjs +372 -0
- package/dist/lib/cjs/setting-ex.d.cts +198 -0
- package/dist/lib/cjs/setting-group-ex.cjs +165 -0
- package/dist/lib/cjs/setting-group-ex.d.cts +26 -0
- package/dist/lib/cjs/status-bar-item-registrar.cjs +162 -0
- package/dist/lib/cjs/status-bar-item-registrar.d.cts +36 -0
- package/dist/lib/cjs/templater.cjs +279 -0
- package/dist/lib/cjs/templater.d.cts +284 -0
- package/dist/lib/cjs/transformers/duration-transformer.cjs +182 -0
- package/dist/lib/cjs/transformers/duration-transformer.d.cts +39 -0
- package/dist/lib/cjs/transformers/index.cjs +153 -0
- package/dist/lib/cjs/transformers/index.d.cts +2 -0
- package/dist/lib/cjs/trusted-input.cjs +196 -0
- package/dist/lib/cjs/trusted-input.d.cts +131 -0
- package/dist/lib/cjs/validation.cjs +189 -0
- package/dist/lib/cjs/validation.d.cts +87 -0
- package/dist/lib/cjs/vault-delete.cjs +222 -0
- package/dist/lib/cjs/vault-delete.d.cts +82 -0
- package/dist/lib/cjs/vault-transaction.cjs +412 -0
- package/dist/lib/cjs/vault-transaction.d.cts +163 -0
- package/dist/lib/cjs/vault.cjs +701 -0
- package/dist/lib/cjs/vault.d.cts +506 -0
- package/dist/lib/cjs/view-registrar.cjs +162 -0
- package/dist/lib/cjs/view-registrar.d.cts +52 -0
- package/dist/lib/cjs/workspace.cjs +186 -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 +1524 -0
- package/dist/lib/esm/active-file-provider.d.mts +36 -0
- package/dist/lib/esm/active-file-provider.mjs +64 -0
- package/dist/lib/esm/app.d.mts +17 -0
- package/dist/lib/esm/app.mjs +56 -0
- package/dist/lib/esm/async-with-notice.d.mts +113 -0
- package/dist/lib/esm/async-with-notice.mjs +141 -0
- package/dist/lib/esm/attachment-path.d.mts +341 -0
- package/dist/lib/esm/attachment-path.mjs +294 -0
- package/dist/lib/esm/attachment-unit-folder.d.mts +103 -0
- package/dist/lib/esm/attachment-unit-folder.mjs +70 -0
- package/dist/lib/esm/backlink-index.d.mts +51 -0
- package/dist/lib/esm/backlink-index.mjs +152 -0
- package/dist/lib/esm/backlink.d.mts +66 -0
- package/dist/lib/esm/backlink.mjs +123 -0
- package/dist/lib/esm/bases-view-registrar.d.mts +52 -0
- package/dist/lib/esm/bases-view-registrar.mjs +65 -0
- package/dist/lib/esm/callout.d.mts +76 -0
- package/dist/lib/esm/callout.mjs +124 -0
- package/dist/lib/esm/canvas.d.mts +28 -0
- package/dist/lib/esm/canvas.mjs +121 -0
- package/dist/lib/esm/case-insensitive-file-index.d.mts +92 -0
- package/dist/lib/esm/case-insensitive-file-index.mjs +144 -0
- package/dist/lib/esm/code-block-markdown-information.d.mts +48 -0
- package/dist/lib/esm/code-block-markdown-information.mjs +42 -0
- package/dist/lib/esm/code-block-reg-exp.d.mts +39 -0
- package/dist/lib/esm/code-block-reg-exp.mjs +48 -0
- package/dist/lib/esm/codemirror/index.d.mts +2 -0
- package/dist/lib/esm/codemirror/index.mjs +46 -0
- package/dist/lib/esm/codemirror/state-field-spec.d.mts +72 -0
- package/dist/lib/esm/codemirror/state-field-spec.mjs +42 -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 +322 -0
- package/dist/lib/esm/command-handlers/command-handler-component.d.mts +146 -0
- package/dist/lib/esm/command-handlers/command-handler-component.mjs +185 -0
- package/dist/lib/esm/command-handlers/command-handler.d.mts +107 -0
- package/dist/lib/esm/command-handlers/command-handler.mjs +103 -0
- package/dist/lib/esm/command-handlers/editor-command-handler.d.mts +208 -0
- package/dist/lib/esm/command-handlers/editor-command-handler.mjs +254 -0
- package/dist/lib/esm/command-handlers/file-command-handler.d.mts +143 -0
- package/dist/lib/esm/command-handlers/file-command-handler.mjs +192 -0
- package/dist/lib/esm/command-handlers/folder-command-handler.d.mts +149 -0
- package/dist/lib/esm/command-handlers/folder-command-handler.mjs +200 -0
- package/dist/lib/esm/command-handlers/global-command-handler.d.mts +40 -0
- package/dist/lib/esm/command-handlers/global-command-handler.mjs +88 -0
- package/dist/lib/esm/command-handlers/index.d.mts +11 -0
- package/dist/lib/esm/command-handlers/index.mjs +64 -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 +102 -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 +77 -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 +90 -0
- package/dist/lib/esm/command-registrar.d.mts +48 -0
- package/dist/lib/esm/command-registrar.mjs +72 -0
- package/dist/lib/esm/community-plugins.d.mts +270 -0
- package/dist/lib/esm/community-plugins.mjs +214 -0
- package/dist/lib/esm/components/abort-signal-component.d.mts +30 -0
- package/dist/lib/esm/components/abort-signal-component.mjs +75 -0
- package/dist/lib/esm/components/all-windows-event-component.d.mts +84 -0
- package/dist/lib/esm/components/all-windows-event-component.mjs +117 -0
- package/dist/lib/esm/components/async-error-handler-component.d.mts +30 -0
- package/dist/lib/esm/components/async-error-handler-component.mjs +79 -0
- package/dist/lib/esm/components/async-events-component.d.mts +15 -0
- package/dist/lib/esm/components/async-events-component.mjs +51 -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 +93 -0
- package/dist/lib/esm/components/component-ex.d.mts +229 -0
- package/dist/lib/esm/components/component-ex.mjs +413 -0
- package/dist/lib/esm/components/console-debug-component.d.mts +30 -0
- package/dist/lib/esm/components/console-debug-component.mjs +73 -0
- package/dist/lib/esm/components/core-plugin-toggle-component.d.mts +102 -0
- package/dist/lib/esm/components/core-plugin-toggle-component.mjs +105 -0
- package/dist/lib/esm/components/disposable-component.d.mts +24 -0
- package/dist/lib/esm/components/disposable-component.mjs +57 -0
- package/dist/lib/esm/components/embed-extensions-component.d.mts +38 -0
- package/dist/lib/esm/components/embed-extensions-component.mjs +77 -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 +73 -0
- package/dist/lib/esm/components/index.d.mts +30 -0
- package/dist/lib/esm/components/index.mjs +102 -0
- package/dist/lib/esm/components/layout-ready-component.d.mts +48 -0
- package/dist/lib/esm/components/layout-ready-component.mjs +113 -0
- package/dist/lib/esm/components/menu-event-registrar-component.d.mts +52 -0
- package/dist/lib/esm/components/menu-event-registrar-component.mjs +99 -0
- package/dist/lib/esm/components/monkey-around-component.d.mts +241 -0
- package/dist/lib/esm/components/monkey-around-component.mjs +146 -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 +227 -0
- package/dist/lib/esm/components/plugin-context-component.d.mts +36 -0
- package/dist/lib/esm/components/plugin-context-component.mjs +86 -0
- package/dist/lib/esm/components/plugin-gate-component.d.mts +332 -0
- package/dist/lib/esm/components/plugin-gate-component.mjs +464 -0
- package/dist/lib/esm/components/plugin-notice-component.d.mts +362 -0
- package/dist/lib/esm/components/plugin-notice-component.mjs +535 -0
- package/dist/lib/esm/components/plugin-settings-component.d.mts +362 -0
- package/dist/lib/esm/components/plugin-settings-component.mjs +554 -0
- package/dist/lib/esm/components/plugin-settings-tab-component.d.mts +39 -0
- package/dist/lib/esm/components/plugin-settings-tab-component.mjs +73 -0
- package/dist/lib/esm/components/plugin-suggestion-component.d.mts +162 -0
- package/dist/lib/esm/components/plugin-suggestion-component.mjs +184 -0
- package/dist/lib/esm/components/pointer-position-component.d.mts +29 -0
- package/dist/lib/esm/components/pointer-position-component.mjs +69 -0
- package/dist/lib/esm/components/registry-component.d.mts +37 -0
- package/dist/lib/esm/components/registry-component.mjs +90 -0
- package/dist/lib/esm/components/release-notes-component.d.mts +129 -0
- package/dist/lib/esm/components/release-notes-component.mjs +128 -0
- package/dist/lib/esm/components/rename-delete-handler-component.d.mts +165 -0
- package/dist/lib/esm/components/rename-delete-handler-component.mjs +1230 -0
- package/dist/lib/esm/components/rmdir-guard-component.d.mts +76 -0
- package/dist/lib/esm/components/rmdir-guard-component.mjs +92 -0
- package/dist/lib/esm/components/settings-migration-component.d.mts +120 -0
- package/dist/lib/esm/components/settings-migration-component.mjs +125 -0
- package/dist/lib/esm/components/syntax-highlighting-component.d.mts +149 -0
- package/dist/lib/esm/components/syntax-highlighting-component.mjs +151 -0
- package/dist/lib/esm/components/templates-language-component.d.mts +124 -0
- package/dist/lib/esm/components/templates-language-component.mjs +179 -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 +149 -0
- package/dist/lib/esm/constructors/index.d.mts +2 -0
- package/dist/lib/esm/constructors/index.mjs +46 -0
- package/dist/lib/esm/css-class.d.mts +278 -0
- package/dist/lib/esm/css-class.mjs +111 -0
- package/dist/lib/esm/data-handler.d.mts +49 -0
- package/dist/lib/esm/data-handler.mjs +73 -0
- package/dist/lib/esm/dataview-link.d.mts +42 -0
- package/dist/lib/esm/dataview-link.mjs +66 -0
- package/dist/lib/esm/dataview.d.mts +249 -0
- package/dist/lib/esm/dataview.mjs +280 -0
- package/dist/lib/esm/debug.d.mts +19 -0
- package/dist/lib/esm/debug.mjs +51 -0
- package/dist/lib/esm/demo-vault-helper-settings.d.mts +29 -0
- package/dist/lib/esm/demo-vault-helper-settings.mjs +42 -0
- package/dist/lib/esm/demo-vault-helper.d.mts +61 -0
- package/dist/lib/esm/demo-vault-helper.mjs +142 -0
- package/dist/lib/esm/demo-vault-naming.d.mts +54 -0
- package/dist/lib/esm/demo-vault-naming.mjs +59 -0
- package/dist/lib/esm/desktop-demo-vault-opener.d.mts +76 -0
- package/dist/lib/esm/desktop-demo-vault-opener.mjs +266 -0
- package/dist/lib/esm/desktop-trusted-input.d.mts +288 -0
- package/dist/lib/esm/desktop-trusted-input.mjs +198 -0
- package/dist/lib/esm/editor-extension-registrar.d.mts +37 -0
- package/dist/lib/esm/editor-extension-registrar.mjs +65 -0
- package/dist/lib/esm/editor-suggest-registrar.d.mts +36 -0
- package/dist/lib/esm/editor-suggest-registrar.mjs +68 -0
- package/dist/lib/esm/editor.d.mts +45 -0
- package/dist/lib/esm/editor.mjs +107 -0
- package/dist/lib/esm/events.d.mts +98 -0
- package/dist/lib/esm/events.mjs +73 -0
- package/dist/lib/esm/extensions-registrar.d.mts +51 -0
- package/dist/lib/esm/extensions-registrar.mjs +65 -0
- package/dist/lib/esm/file-change.d.mts +156 -0
- package/dist/lib/esm/file-change.mjs +473 -0
- package/dist/lib/esm/file-explorer.d.mts +34 -0
- package/dist/lib/esm/file-explorer.mjs +60 -0
- package/dist/lib/esm/file-manager.d.mts +123 -0
- package/dist/lib/esm/file-manager.mjs +161 -0
- package/dist/lib/esm/file-system.d.mts +554 -0
- package/dist/lib/esm/file-system.mjs +458 -0
- package/dist/lib/esm/folder-note.d.mts +166 -0
- package/dist/lib/esm/folder-note.mjs +161 -0
- package/dist/lib/esm/frontmatter-formatting.d.mts +44 -0
- package/dist/lib/esm/frontmatter-formatting.mjs +368 -0
- package/dist/lib/esm/frontmatter-link-cache-with-offsets.d.mts +34 -0
- package/dist/lib/esm/frontmatter-link-cache-with-offsets.mjs +61 -0
- package/dist/lib/esm/frontmatter.d.mts +145 -0
- package/dist/lib/esm/frontmatter.mjs +174 -0
- package/dist/lib/esm/generated-during-build.d.mts +25 -0
- package/dist/lib/esm/generated-during-build.mjs +48 -0
- package/dist/lib/esm/hover-link-source-registrar.d.mts +52 -0
- package/dist/lib/esm/hover-link-source-registrar.mjs +65 -0
- package/dist/lib/esm/html-element.d.mts +98 -0
- package/dist/lib/esm/html-element.mjs +86 -0
- package/dist/lib/esm/i18n/custom-type-options.d.mts +38 -0
- package/dist/lib/esm/i18n/custom-type-options.mjs +43 -0
- package/dist/lib/esm/i18n/default-translations.d.mts +15 -0
- package/dist/lib/esm/i18n/default-translations.mjs +43 -0
- package/dist/lib/esm/i18n/i18n.d.mts +38 -0
- package/dist/lib/esm/i18n/i18n.mjs +89 -0
- package/dist/lib/esm/i18n/index.d.mts +5 -0
- package/dist/lib/esm/i18n/index.mjs +52 -0
- package/dist/lib/esm/i18n/locales/en.d.mts +91 -0
- package/dist/lib/esm/i18n/locales/en.mjs +127 -0
- package/dist/lib/esm/i18n/locales/index.d.mts +3 -0
- package/dist/lib/esm/i18n/locales/index.mjs +48 -0
- package/dist/lib/esm/i18n/locales/translations-map.d.mts +100 -0
- package/dist/lib/esm/i18n/locales/translations-map.mjs +52 -0
- package/dist/lib/esm/index.d.mts +96 -0
- package/dist/lib/esm/index.mjs +234 -0
- package/dist/lib/esm/is-in-obsidian.d.mts +12 -0
- package/dist/lib/esm/is-in-obsidian.mjs +59 -0
- package/dist/lib/esm/library-styles.d.mts +56 -0
- package/dist/lib/esm/library-styles.mjs +72 -0
- package/dist/lib/esm/library.d.mts +57 -0
- package/dist/lib/esm/library.mjs +83 -0
- package/dist/lib/esm/link-name.d.mts +23 -0
- package/dist/lib/esm/link-name.mjs +48 -0
- package/dist/lib/esm/link-update-progress.d.mts +32 -0
- package/dist/lib/esm/link-update-progress.mjs +42 -0
- package/dist/lib/esm/link.d.mts +1369 -0
- package/dist/lib/esm/link.mjs +988 -0
- package/dist/lib/esm/logger.d.mts +37 -0
- package/dist/lib/esm/logger.mjs +115 -0
- package/dist/lib/esm/loop.d.mts +104 -0
- package/dist/lib/esm/loop.mjs +151 -0
- package/dist/lib/esm/markdown-code-block-processor-registrar.d.mts +62 -0
- package/dist/lib/esm/markdown-code-block-processor-registrar.mjs +69 -0
- package/dist/lib/esm/markdown-code-block-processor.d.mts +137 -0
- package/dist/lib/esm/markdown-code-block-processor.mjs +356 -0
- package/dist/lib/esm/markdown-post-processor-registrar.d.mts +59 -0
- package/dist/lib/esm/markdown-post-processor-registrar.mjs +66 -0
- package/dist/lib/esm/markdown-view.d.mts +14 -0
- package/dist/lib/esm/markdown-view.mjs +54 -0
- package/dist/lib/esm/markdown.d.mts +226 -0
- package/dist/lib/esm/markdown.mjs +391 -0
- package/dist/lib/esm/menu-event-registrar.d.mts +84 -0
- package/dist/lib/esm/menu-event-registrar.mjs +42 -0
- package/dist/lib/esm/metadata-cache.d.mts +359 -0
- package/dist/lib/esm/metadata-cache.mjs +454 -0
- package/dist/lib/esm/mobile-trusted-input.d.mts +98 -0
- package/dist/lib/esm/mobile-trusted-input.mjs +82 -0
- package/dist/lib/esm/modals/alert.d.mts +35 -0
- package/dist/lib/esm/modals/alert.mjs +84 -0
- package/dist/lib/esm/modals/confirm.d.mts +39 -0
- package/dist/lib/esm/modals/confirm.mjs +94 -0
- package/dist/lib/esm/modals/index.d.mts +10 -0
- package/dist/lib/esm/modals/index.mjs +62 -0
- package/dist/lib/esm/modals/minimizable-modal.d.mts +129 -0
- package/dist/lib/esm/modals/minimizable-modal.mjs +348 -0
- package/dist/lib/esm/modals/modal-command-builder.d.mts +285 -0
- package/dist/lib/esm/modals/modal-command-builder.mjs +363 -0
- package/dist/lib/esm/modals/modal.d.mts +64 -0
- package/dist/lib/esm/modals/modal.mjs +78 -0
- package/dist/lib/esm/modals/prompt.d.mts +83 -0
- package/dist/lib/esm/modals/prompt.mjs +168 -0
- package/dist/lib/esm/modals/select-item.d.mts +55 -0
- package/dist/lib/esm/modals/select-item.mjs +104 -0
- package/dist/lib/esm/modals/select-option.d.mts +65 -0
- package/dist/lib/esm/modals/select-option.mjs +95 -0
- package/dist/lib/esm/modals/suggest-modal-command-builder.d.mts +35 -0
- package/dist/lib/esm/modals/suggest-modal-command-builder.mjs +47 -0
- package/dist/lib/esm/note-priority.d.mts +154 -0
- package/dist/lib/esm/note-priority.mjs +135 -0
- package/dist/lib/esm/notebook-navigator.d.mts +132 -0
- package/dist/lib/esm/notebook-navigator.mjs +64 -0
- package/dist/lib/esm/obsidian-dev-utils-state.d.mts +42 -0
- package/dist/lib/esm/obsidian-dev-utils-state.mjs +76 -0
- package/dist/lib/esm/obsidian-protocol-handler-registrar.d.mts +55 -0
- package/dist/lib/esm/obsidian-protocol-handler-registrar.mjs +68 -0
- package/dist/lib/esm/obsidian-settings.d.mts +62 -0
- package/dist/lib/esm/obsidian-settings.mjs +81 -0
- package/dist/lib/esm/parse-link.d.mts +288 -0
- package/dist/lib/esm/parse-link.mjs +428 -0
- package/dist/lib/esm/path-settings.d.mts +56 -0
- package/dist/lib/esm/path-settings.mjs +176 -0
- package/dist/lib/esm/pdf.d.mts +26 -0
- package/dist/lib/esm/pdf.mjs +76 -0
- package/dist/lib/esm/plugin/index.d.mts +9 -0
- package/dist/lib/esm/plugin/index.mjs +60 -0
- package/dist/lib/esm/plugin/plugin-api.d.mts +413 -0
- package/dist/lib/esm/plugin/plugin-api.mjs +422 -0
- package/dist/lib/esm/plugin/plugin-context.d.mts +27 -0
- package/dist/lib/esm/plugin/plugin-context.mjs +101 -0
- package/dist/lib/esm/plugin/plugin-event-source.d.mts +97 -0
- package/dist/lib/esm/plugin/plugin-event-source.mjs +129 -0
- package/dist/lib/esm/plugin/plugin-install-state.d.mts +113 -0
- package/dist/lib/esm/plugin/plugin-install-state.mjs +101 -0
- package/dist/lib/esm/plugin/plugin-lifecycle-events.d.mts +127 -0
- package/dist/lib/esm/plugin/plugin-lifecycle-events.mjs +52 -0
- package/dist/lib/esm/plugin/plugin-settings-tab.d.mts +368 -0
- package/dist/lib/esm/plugin/plugin-settings-tab.mjs +527 -0
- package/dist/lib/esm/plugin/plugin.d.mts +363 -0
- package/dist/lib/esm/plugin/plugin.mjs +611 -0
- package/dist/lib/esm/plugin/settings-migration-api.d.mts +91 -0
- package/dist/lib/esm/plugin/settings-migration-api.mjs +42 -0
- package/dist/lib/esm/plugin-cli-handler-registrar.d.mts +64 -0
- package/dist/lib/esm/plugin-cli-handler-registrar.mjs +66 -0
- package/dist/lib/esm/popovers/field-popover.d.mts +75 -0
- package/dist/lib/esm/popovers/field-popover.mjs +88 -0
- package/dist/lib/esm/popovers/index.d.mts +4 -0
- package/dist/lib/esm/popovers/index.mjs +50 -0
- package/dist/lib/esm/popovers/popover-anchor.d.mts +67 -0
- package/dist/lib/esm/popovers/popover-anchor.mjs +82 -0
- package/dist/lib/esm/popovers/popover.d.mts +78 -0
- package/dist/lib/esm/popovers/popover.mjs +132 -0
- package/dist/lib/esm/property-entry.d.mts +43 -0
- package/dist/lib/esm/property-entry.mjs +73 -0
- package/dist/lib/esm/queue.d.mts +93 -0
- package/dist/lib/esm/queue.mjs +122 -0
- package/dist/lib/esm/react/app-context.d.mts +24 -0
- package/dist/lib/esm/react/app-context.mjs +56 -0
- package/dist/lib/esm/react/index.d.mts +2 -0
- package/dist/lib/esm/react/index.mjs +46 -0
- package/dist/lib/esm/reference.d.mts +116 -0
- package/dist/lib/esm/reference.mjs +87 -0
- package/dist/lib/esm/resource-lock.d.mts +318 -0
- package/dist/lib/esm/resource-lock.mjs +1006 -0
- package/dist/lib/esm/resource-url.d.mts +31 -0
- package/dist/lib/esm/resource-url.mjs +59 -0
- package/dist/lib/esm/ribbon-icon-registrar.d.mts +60 -0
- package/dist/lib/esm/ribbon-icon-registrar.mjs +66 -0
- package/dist/lib/esm/setting-components/checkbox-component.d.mts +69 -0
- package/dist/lib/esm/setting-components/checkbox-component.mjs +119 -0
- package/dist/lib/esm/setting-components/code-highlighter-component.d.mts +132 -0
- package/dist/lib/esm/setting-components/code-highlighter-component.mjs +287 -0
- package/dist/lib/esm/setting-components/date-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/date-component.mjs +83 -0
- package/dist/lib/esm/setting-components/date-time-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/date-time-component.mjs +83 -0
- package/dist/lib/esm/setting-components/email-component.d.mts +49 -0
- package/dist/lib/esm/setting-components/email-component.mjs +94 -0
- package/dist/lib/esm/setting-components/file-component.d.mts +43 -0
- package/dist/lib/esm/setting-components/file-component.mjs +86 -0
- package/dist/lib/esm/setting-components/index.d.mts +27 -0
- package/dist/lib/esm/setting-components/index.mjs +96 -0
- package/dist/lib/esm/setting-components/month-component.d.mts +51 -0
- package/dist/lib/esm/setting-components/month-component.mjs +91 -0
- package/dist/lib/esm/setting-components/multiple-dropdown-component.d.mts +92 -0
- package/dist/lib/esm/setting-components/multiple-dropdown-component.mjs +159 -0
- package/dist/lib/esm/setting-components/multiple-email-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/multiple-email-component.mjs +80 -0
- package/dist/lib/esm/setting-components/multiple-file-component.d.mts +43 -0
- package/dist/lib/esm/setting-components/multiple-file-component.mjs +88 -0
- package/dist/lib/esm/setting-components/multiple-text-component.d.mts +109 -0
- package/dist/lib/esm/setting-components/multiple-text-component.mjs +178 -0
- package/dist/lib/esm/setting-components/number-component.d.mts +56 -0
- package/dist/lib/esm/setting-components/number-component.mjs +104 -0
- package/dist/lib/esm/setting-components/password-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/password-component.mjs +80 -0
- package/dist/lib/esm/setting-components/setting-component-wrapper.d.mts +13 -0
- package/dist/lib/esm/setting-components/setting-component-wrapper.mjs +63 -0
- package/dist/lib/esm/setting-components/telephone-component.d.mts +51 -0
- package/dist/lib/esm/setting-components/telephone-component.mjs +94 -0
- package/dist/lib/esm/setting-components/text-based-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/text-based-component.mjs +73 -0
- package/dist/lib/esm/setting-components/time-component.d.mts +38 -0
- package/dist/lib/esm/setting-components/time-component.mjs +88 -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 +120 -0
- package/dist/lib/esm/setting-components/typed-dropdown-component.d.mts +97 -0
- package/dist/lib/esm/setting-components/typed-dropdown-component.mjs +168 -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 +167 -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 +78 -0
- package/dist/lib/esm/setting-components/typed-text-component.d.mts +100 -0
- package/dist/lib/esm/setting-components/typed-text-component.mjs +138 -0
- package/dist/lib/esm/setting-components/url-component.d.mts +49 -0
- package/dist/lib/esm/setting-components/url-component.mjs +94 -0
- package/dist/lib/esm/setting-components/validator-component.d.mts +23 -0
- package/dist/lib/esm/setting-components/validator-component.mjs +142 -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 +42 -0
- package/dist/lib/esm/setting-components/week-component.d.mts +51 -0
- package/dist/lib/esm/setting-components/week-component.mjs +91 -0
- package/dist/lib/esm/setting-ex.d.mts +198 -0
- package/dist/lib/esm/setting-ex.mjs +274 -0
- package/dist/lib/esm/setting-group-ex.d.mts +26 -0
- package/dist/lib/esm/setting-group-ex.mjs +68 -0
- package/dist/lib/esm/status-bar-item-registrar.d.mts +36 -0
- package/dist/lib/esm/status-bar-item-registrar.mjs +65 -0
- package/dist/lib/esm/templater.d.mts +284 -0
- package/dist/lib/esm/templater.mjs +173 -0
- package/dist/lib/esm/transformers/duration-transformer.d.mts +39 -0
- package/dist/lib/esm/transformers/duration-transformer.mjs +85 -0
- package/dist/lib/esm/transformers/index.d.mts +2 -0
- package/dist/lib/esm/transformers/index.mjs +46 -0
- package/dist/lib/esm/trusted-input.d.mts +131 -0
- package/dist/lib/esm/trusted-input.mjs +83 -0
- package/dist/lib/esm/validation.d.mts +87 -0
- package/dist/lib/esm/validation.mjs +87 -0
- package/dist/lib/esm/vault-delete.d.mts +82 -0
- package/dist/lib/esm/vault-delete.mjs +132 -0
- package/dist/lib/esm/vault-transaction.d.mts +163 -0
- package/dist/lib/esm/vault-transaction.mjs +325 -0
- package/dist/lib/esm/vault.d.mts +506 -0
- package/dist/lib/esm/vault.mjs +604 -0
- package/dist/lib/esm/view-registrar.d.mts +52 -0
- package/dist/lib/esm/view-registrar.mjs +65 -0
- package/dist/lib/esm/workspace.d.mts +81 -0
- package/dist/lib/esm/workspace.mjs +84 -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 +533 -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,82 @@
|
|
|
1
|
+
/// <reference path="./library.d.cts" />
|
|
2
|
+
/**
|
|
3
|
+
* @file
|
|
4
|
+
*
|
|
5
|
+
* This module provides deletion utilities that require metadata cache access.
|
|
6
|
+
*/
|
|
7
|
+
import type { App, TAbstractFile, TFile } from 'obsidian' with { 'resolution-mode': 'import' };
|
|
8
|
+
import type { PluginNoticeComponent } from './components/plugin-notice-component.cjs';
|
|
9
|
+
import type { PathOrAbstractFile } from './file-system.cjs';
|
|
10
|
+
/**
|
|
11
|
+
* The result of {@link deleteIfNotUsed}.
|
|
12
|
+
*/
|
|
13
|
+
export declare enum DeleteIfNotUsedResult {
|
|
14
|
+
/**
|
|
15
|
+
* The file/folder was deleted.
|
|
16
|
+
*/
|
|
17
|
+
Deleted = "deleted",
|
|
18
|
+
/**
|
|
19
|
+
* The file/folder was not deleted.
|
|
20
|
+
*/
|
|
21
|
+
NotDeleted = "not-deleted",
|
|
22
|
+
/**
|
|
23
|
+
* The file was still used, and {@link DeleteIfNotUsedParams.rescueStillUsedFile} moved it out of the way
|
|
24
|
+
* instead of it being deleted or left where it was.
|
|
25
|
+
*/
|
|
26
|
+
Rescued = "rescued"
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Parameters passed to {@link DeleteIfNotUsedParams.rescueStillUsedFile}.
|
|
30
|
+
*/
|
|
31
|
+
export interface RescueStillUsedFileParams {
|
|
32
|
+
/**
|
|
33
|
+
* The file that is about to be kept because other notes still reference it.
|
|
34
|
+
*/
|
|
35
|
+
readonly file: TFile;
|
|
36
|
+
/**
|
|
37
|
+
* The paths of the notes that still reference the file once everything being deleted alongside it is
|
|
38
|
+
* gone. Never empty.
|
|
39
|
+
*/
|
|
40
|
+
readonly survivingNotePaths: readonly string[];
|
|
41
|
+
}
|
|
42
|
+
interface DeleteIfNotUsedParams {
|
|
43
|
+
readonly app: App;
|
|
44
|
+
readonly deleteAbstractFile?: (file: TAbstractFile) => Promise<void>;
|
|
45
|
+
readonly deletedNotePath?: string;
|
|
46
|
+
readonly deletedNotePaths?: readonly string[];
|
|
47
|
+
readonly pathOrFile: PathOrAbstractFile;
|
|
48
|
+
readonly pluginNoticeComponent?: PluginNoticeComponent;
|
|
49
|
+
readonly rescueStillUsedFile?: (params: RescueStillUsedFileParams) => Promise<boolean>;
|
|
50
|
+
readonly shouldDeleteEmptyFolders?: boolean;
|
|
51
|
+
readonly shouldProtectIfStillUsed?: (file: TFile) => boolean;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Deletes an abstract file safely from the vault, but only if it is not referenced by other notes.
|
|
55
|
+
*
|
|
56
|
+
* Backlinks originating from {@link DeleteIfNotUsedParams.deletedNotePath} and
|
|
57
|
+
* {@link DeleteIfNotUsedParams.deletedNotePaths} are discounted before deciding whether a file is still
|
|
58
|
+
* used — a note that is itself going away cannot keep an attachment alive. Deleting a single note needs
|
|
59
|
+
* only the former; deleting a folder needs the latter, because every note inside it disappears at once.
|
|
60
|
+
*
|
|
61
|
+
* {@link DeleteIfNotUsedParams.shouldProtectIfStillUsed} narrows which files that protection covers; a file
|
|
62
|
+
* it rejects is deleted no matter how many notes link to it. Deleting a whole folder of notes uses this to
|
|
63
|
+
* exempt the notes themselves — leaving a dangling link behind is what Obsidian normally does, so keeping
|
|
64
|
+
* every linked-to note would make folder deletion impossible. By default every still-used file is kept.
|
|
65
|
+
*
|
|
66
|
+
* A kept file is stranded: it survives in a folder whose owning note is gone, while the note still
|
|
67
|
+
* referencing it lives elsewhere. {@link DeleteIfNotUsedParams.rescueStillUsedFile} is the seam that lets
|
|
68
|
+
* the caller relocate it instead, since where it belongs is the caller's attachment-path policy, not this
|
|
69
|
+
* function's. Without that callback the file is simply kept, exactly as before.
|
|
70
|
+
*
|
|
71
|
+
* The actual removal goes through {@link DeleteIfNotUsedParams.deleteAbstractFile} when supplied,
|
|
72
|
+
* otherwise through {@link trashSafe}. A caller that intercepted a specific deletion primitive passes its
|
|
73
|
+
* unpatched original here, so the user's chosen semantics (permanent delete vs trash) survive the detour.
|
|
74
|
+
*
|
|
75
|
+
* @param params - The parameters for the function.
|
|
76
|
+
* @returns A {@link Promise} that resolves to {@link DeleteIfNotUsedResult.Deleted} if the abstract file
|
|
77
|
+
* was deleted, {@link DeleteIfNotUsedResult.Rescued} if it was moved away by
|
|
78
|
+
* {@link DeleteIfNotUsedParams.rescueStillUsedFile}, or {@link DeleteIfNotUsedResult.NotDeleted} if it was
|
|
79
|
+
* kept where it was.
|
|
80
|
+
*/
|
|
81
|
+
export declare function deleteIfNotUsed(params: DeleteIfNotUsedParams): Promise<DeleteIfNotUsedResult>;
|
|
82
|
+
export {};
|
|
@@ -0,0 +1,412 @@
|
|
|
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
|
+
const existingProcess = globalThis.process;
|
|
22
|
+
if (!existingProcess) {
|
|
23
|
+
globalThis.process = browserProcess;
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
if (existingProcess.versions?.node) {
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
const existingProcessRecord = existingProcess;
|
|
30
|
+
for (const [key, value] of Object.entries(browserProcess)) {
|
|
31
|
+
existingProcessRecord[key] ??= value;
|
|
32
|
+
}
|
|
33
|
+
existingProcessRecord["browser"] = true;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
function keepName($unknown) {
|
|
37
|
+
return $unknown;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
(function initCjs() {
|
|
41
|
+
const globalThisRecord = globalThis;
|
|
42
|
+
ensureDisposeSymbols();
|
|
43
|
+
globalThisRecord["__name"] ??= keepName;
|
|
44
|
+
globalThisRecord["__extractDefault"] ??= extractDefault;
|
|
45
|
+
ensureBrowserProcess();
|
|
46
|
+
function extractDefault(module) {
|
|
47
|
+
return module && module.__esModule && "default" in module ? module.default : module;
|
|
48
|
+
}
|
|
49
|
+
})();
|
|
50
|
+
})();
|
|
51
|
+
(function patchObsidianRequire() {
|
|
52
|
+
const originalRequire = require;
|
|
53
|
+
if (!originalRequire || originalRequire.__isPatched) {
|
|
54
|
+
return;
|
|
55
|
+
}
|
|
56
|
+
require = Object.assign(
|
|
57
|
+
(id) => requirePatched(id),
|
|
58
|
+
originalRequire,
|
|
59
|
+
{
|
|
60
|
+
__isPatched: true
|
|
61
|
+
}
|
|
62
|
+
);
|
|
63
|
+
function extractDefault(module) {
|
|
64
|
+
return module && module.__esModule && "default" in module ? module.default : module;
|
|
65
|
+
}
|
|
66
|
+
const OBSIDIAN_BUILT_IN_MODULE_NAMES = /* @__PURE__ */ new Set([
|
|
67
|
+
"@codemirror/autocomplete",
|
|
68
|
+
"@codemirror/collab",
|
|
69
|
+
"@codemirror/commands",
|
|
70
|
+
"@codemirror/language",
|
|
71
|
+
"@codemirror/lint",
|
|
72
|
+
"@codemirror/search",
|
|
73
|
+
"@codemirror/state",
|
|
74
|
+
"@codemirror/text",
|
|
75
|
+
"@codemirror/view",
|
|
76
|
+
"@lezer/common",
|
|
77
|
+
"@lezer/highlight",
|
|
78
|
+
"@lezer/lr",
|
|
79
|
+
"obsidian"
|
|
80
|
+
]);
|
|
81
|
+
const DEPRECATED_OBSIDIAN_BUILT_IN_MODULE_NAMES = /* @__PURE__ */ new Set([
|
|
82
|
+
"@codemirror/closebrackets",
|
|
83
|
+
"@codemirror/comment",
|
|
84
|
+
"@codemirror/fold",
|
|
85
|
+
"@codemirror/gutter",
|
|
86
|
+
"@codemirror/highlight",
|
|
87
|
+
"@codemirror/history",
|
|
88
|
+
"@codemirror/matchbrackets",
|
|
89
|
+
"@codemirror/panel",
|
|
90
|
+
"@codemirror/rangeset",
|
|
91
|
+
"@codemirror/rectangular-selection",
|
|
92
|
+
"@codemirror/stream-parser",
|
|
93
|
+
"@codemirror/tooltip"
|
|
94
|
+
]);
|
|
95
|
+
function requirePatched(id) {
|
|
96
|
+
if (OBSIDIAN_BUILT_IN_MODULE_NAMES.has(id) || DEPRECATED_OBSIDIAN_BUILT_IN_MODULE_NAMES.has(id)) {
|
|
97
|
+
return originalRequire?.(id);
|
|
98
|
+
}
|
|
99
|
+
if (globalThis.app.isMobile) {
|
|
100
|
+
if (id === "process" || id === "node:process") {
|
|
101
|
+
console.debug(`The most likely you can safely ignore this error. Module not found: ${id}. Fake process object is returned instead.`);
|
|
102
|
+
return process;
|
|
103
|
+
}
|
|
104
|
+
} else {
|
|
105
|
+
const module = originalRequire?.(id);
|
|
106
|
+
if (module) {
|
|
107
|
+
return extractDefault(module);
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
console.debug(`The most likely you can safely ignore this error. Module not found: ${id}. Empty object is returned instead.`);
|
|
111
|
+
return {};
|
|
112
|
+
}
|
|
113
|
+
})();
|
|
114
|
+
|
|
115
|
+
"use strict";
|
|
116
|
+
var __defProp = Object.defineProperty;
|
|
117
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
118
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
119
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
120
|
+
var __export = (target, all) => {
|
|
121
|
+
for (var name in all)
|
|
122
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
123
|
+
};
|
|
124
|
+
var __copyProps = (to, from, except, desc) => {
|
|
125
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
126
|
+
for (let key of __getOwnPropNames(from))
|
|
127
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
128
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
129
|
+
}
|
|
130
|
+
return to;
|
|
131
|
+
};
|
|
132
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
133
|
+
var vault_transaction_exports = {};
|
|
134
|
+
__export(vault_transaction_exports, {
|
|
135
|
+
VaultTransaction: () => VaultTransaction
|
|
136
|
+
});
|
|
137
|
+
module.exports = __toCommonJS(vault_transaction_exports);
|
|
138
|
+
var import_disposable = require('@mnaoumov/typescript-lib/disposable');
|
|
139
|
+
var import_type_guards = require('@mnaoumov/typescript-lib/type-guards');
|
|
140
|
+
var import_editor = require('./editor.cjs');
|
|
141
|
+
var import_file_system = require('./file-system.cjs');
|
|
142
|
+
var import_vault = require('./vault.cjs');
|
|
143
|
+
const DEFAULT_STAGING_FOLDER_PATH = ".obsidian-dev-utils-temp";
|
|
144
|
+
class VaultTransaction {
|
|
145
|
+
/**
|
|
146
|
+
* The Obsidian application instance the transaction mutates.
|
|
147
|
+
*/
|
|
148
|
+
app;
|
|
149
|
+
hasStagingFolder = false;
|
|
150
|
+
mutationBypass = null;
|
|
151
|
+
stagedTrashPaths = [];
|
|
152
|
+
stagingFolderPath;
|
|
153
|
+
state = "open";
|
|
154
|
+
undoSteps = [];
|
|
155
|
+
/**
|
|
156
|
+
* Creates a new vault transaction.
|
|
157
|
+
*
|
|
158
|
+
* @param params - The parameters.
|
|
159
|
+
*/
|
|
160
|
+
constructor(params) {
|
|
161
|
+
this.app = params.app;
|
|
162
|
+
this.stagingFolderPath = params.stagingFolderPath ?? DEFAULT_STAGING_FOLDER_PATH;
|
|
163
|
+
this.mutationBypass = params.openMutationBypass?.() ?? null;
|
|
164
|
+
}
|
|
165
|
+
/**
|
|
166
|
+
* Commits the transaction: finalizes soft-deletes by trashing the staged resources for real and
|
|
167
|
+
* removes the staging folder. After this the transaction can no longer be mutated or rolled back.
|
|
168
|
+
*
|
|
169
|
+
* @returns A {@link Promise} that resolves when the commit completes.
|
|
170
|
+
*/
|
|
171
|
+
async commit() {
|
|
172
|
+
this.assertOpen();
|
|
173
|
+
this.state = "committed";
|
|
174
|
+
const adapter = this.app.vault.adapter;
|
|
175
|
+
for (const stagedPath of this.stagedTrashPaths) {
|
|
176
|
+
const wasTrashedToSystem = await adapter.trashSystem(stagedPath);
|
|
177
|
+
if (!wasTrashedToSystem) {
|
|
178
|
+
await adapter.trashLocal(stagedPath);
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
await this.removeStagingFolder();
|
|
182
|
+
this.disposeMutationBypass();
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Copies a file or folder, recording the removal of the copy as the inverse. A folder is copied with
|
|
186
|
+
* its whole subtree, so the single recorded removal undoes the whole tree. Unlike
|
|
187
|
+
* {@link VaultTransaction.create}, the content is copied byte for byte, so a binary resource
|
|
188
|
+
* round-trips faithfully.
|
|
189
|
+
*
|
|
190
|
+
* Parent folders that had to be created for the destination are NOT undone individually, matching
|
|
191
|
+
* {@link VaultTransaction.create} and {@link VaultTransaction.rename}.
|
|
192
|
+
*
|
|
193
|
+
* @param oldPathOrFile - The path, file or folder to copy.
|
|
194
|
+
* @param newPath - The desired new path (an available path is chosen if it is taken).
|
|
195
|
+
* @returns A {@link Promise} resolving to the actual path of the copy.
|
|
196
|
+
*/
|
|
197
|
+
async copy(oldPathOrFile, newPath) {
|
|
198
|
+
this.assertOpen();
|
|
199
|
+
const oldPath = (0, import_file_system.getPath)(this.app, oldPathOrFile);
|
|
200
|
+
const actualNewPath = await (0, import_vault.copySafe)({ app: this.app, newPath, oldPathOrFile });
|
|
201
|
+
if (actualNewPath !== oldPath) {
|
|
202
|
+
this.pushUndo(async () => {
|
|
203
|
+
await this.hardDelete(actualNewPath);
|
|
204
|
+
});
|
|
205
|
+
}
|
|
206
|
+
return actualNewPath;
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Creates a file with the given content, recording its removal as the inverse.
|
|
210
|
+
*
|
|
211
|
+
* @param path - The path of the file to create.
|
|
212
|
+
* @param data - The content of the file.
|
|
213
|
+
* @returns A {@link Promise} resolving to the created {@link TFile}.
|
|
214
|
+
*/
|
|
215
|
+
async create(path, data) {
|
|
216
|
+
this.assertOpen();
|
|
217
|
+
const file = await this.app.vault.create(path, data);
|
|
218
|
+
const createdPath = file.path;
|
|
219
|
+
this.pushUndo(async () => {
|
|
220
|
+
await this.hardDelete(createdPath);
|
|
221
|
+
});
|
|
222
|
+
return file;
|
|
223
|
+
}
|
|
224
|
+
/**
|
|
225
|
+
* Creates a folder (including missing ancestors), recording its removal as the inverse. A no-op if
|
|
226
|
+
* the folder already exists.
|
|
227
|
+
*
|
|
228
|
+
* @param path - The path of the folder to create.
|
|
229
|
+
* @returns A {@link Promise} that resolves when the folder exists.
|
|
230
|
+
*/
|
|
231
|
+
async createFolder(path) {
|
|
232
|
+
this.assertOpen();
|
|
233
|
+
const result = await (0, import_vault.createFolderSafe)(this.app, path);
|
|
234
|
+
if (result === import_vault.CreateFolderSafeResult.Created) {
|
|
235
|
+
this.pushUndo(async () => {
|
|
236
|
+
await this.hardDelete(path);
|
|
237
|
+
});
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
/**
|
|
241
|
+
* Replaces the content of a file, capturing the old content so it can be restored on rollback.
|
|
242
|
+
*
|
|
243
|
+
* @param pathOrFile - The path or file to modify.
|
|
244
|
+
* @param newContent - The new content.
|
|
245
|
+
* @returns A {@link Promise} that resolves when the file is modified.
|
|
246
|
+
*/
|
|
247
|
+
async modify(pathOrFile, newContent) {
|
|
248
|
+
await this.process(pathOrFile, () => newContent);
|
|
249
|
+
}
|
|
250
|
+
/**
|
|
251
|
+
* Transforms the content of a file, capturing the old content so it can be restored on rollback.
|
|
252
|
+
*
|
|
253
|
+
* @param pathOrFile - The path or file to process.
|
|
254
|
+
* @param newContentProvider - Maps the current content to the new content.
|
|
255
|
+
* @returns A {@link Promise} that resolves when the file is processed.
|
|
256
|
+
*/
|
|
257
|
+
async process(pathOrFile, newContentProvider) {
|
|
258
|
+
this.assertOpen();
|
|
259
|
+
const path = (0, import_file_system.getPath)(this.app, pathOrFile);
|
|
260
|
+
const oldContent = await (0, import_vault.readSafe)(this.app, path);
|
|
261
|
+
await (0, import_vault.process)({
|
|
262
|
+
app: this.app,
|
|
263
|
+
newContentProvider: ({ content }) => newContentProvider(content),
|
|
264
|
+
pathOrFile: path,
|
|
265
|
+
pluginNoticeComponent: null,
|
|
266
|
+
resourceLockComponent: null
|
|
267
|
+
});
|
|
268
|
+
(0, import_type_guards.assertNonNullable)(oldContent);
|
|
269
|
+
this.pushUndo(async () => {
|
|
270
|
+
await (0, import_vault.process)({
|
|
271
|
+
app: this.app,
|
|
272
|
+
newContentProvider: oldContent,
|
|
273
|
+
pathOrFile: path,
|
|
274
|
+
pluginNoticeComponent: null,
|
|
275
|
+
resourceLockComponent: null
|
|
276
|
+
});
|
|
277
|
+
(0, import_editor.syncOpenEditorBuffersForPath)(this.app, path, oldContent);
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
/**
|
|
281
|
+
* Renames or moves a resource, recording the reverse rename as the inverse.
|
|
282
|
+
*
|
|
283
|
+
* @param oldPathOrFile - The resource to rename.
|
|
284
|
+
* @param newPath - The desired new path (an available path is chosen if it is taken).
|
|
285
|
+
* @returns A {@link Promise} resolving to the actual new path.
|
|
286
|
+
*/
|
|
287
|
+
async rename(oldPathOrFile, newPath) {
|
|
288
|
+
this.assertOpen();
|
|
289
|
+
const oldPath = (0, import_file_system.getPath)(this.app, oldPathOrFile);
|
|
290
|
+
const actualNewPath = await (0, import_vault.renameSafe)({ app: this.app, newPath, oldPathOrAbstractFile: oldPathOrFile });
|
|
291
|
+
this.pushUndo(async () => {
|
|
292
|
+
await (0, import_vault.renameSafe)({ app: this.app, newPath: oldPath, oldPathOrAbstractFile: actualNewPath });
|
|
293
|
+
});
|
|
294
|
+
return actualNewPath;
|
|
295
|
+
}
|
|
296
|
+
/**
|
|
297
|
+
* Rolls back the transaction: undoes the completed steps in reverse order and removes the staging
|
|
298
|
+
* folder. Idempotent.
|
|
299
|
+
*
|
|
300
|
+
* @returns A {@link Promise} that resolves when the rollback completes.
|
|
301
|
+
*/
|
|
302
|
+
async rollback() {
|
|
303
|
+
if (this.state === "rolledBack") {
|
|
304
|
+
return;
|
|
305
|
+
}
|
|
306
|
+
this.assertNotCommitted();
|
|
307
|
+
this.state = "rolledBack";
|
|
308
|
+
for (const step of [...this.undoSteps].reverse()) {
|
|
309
|
+
await step.undo();
|
|
310
|
+
}
|
|
311
|
+
await this.removeStagingFolder();
|
|
312
|
+
this.disposeMutationBypass();
|
|
313
|
+
}
|
|
314
|
+
/**
|
|
315
|
+
* Rolls back the transaction on disposal unless it was already committed or rolled back.
|
|
316
|
+
*/
|
|
317
|
+
async [Symbol.asyncDispose]() {
|
|
318
|
+
if (this.state === "open") {
|
|
319
|
+
await this.rollback();
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
/**
|
|
323
|
+
* Soft-deletes a resource by moving it into the staging folder, recording the move-back as the
|
|
324
|
+
* inverse. The real trash happens on {@link VaultTransaction.commit}. A no-op if the resource does
|
|
325
|
+
* not exist.
|
|
326
|
+
*
|
|
327
|
+
* @param pathOrFile - The path or resource to trash.
|
|
328
|
+
* @returns A {@link Promise} that resolves when the resource has been staged.
|
|
329
|
+
*/
|
|
330
|
+
async trash(pathOrFile) {
|
|
331
|
+
this.assertOpen();
|
|
332
|
+
const file = (0, import_file_system.getAbstractFileOrNull)({ app: this.app, pathOrFile });
|
|
333
|
+
if (!file) {
|
|
334
|
+
return;
|
|
335
|
+
}
|
|
336
|
+
const originalPath = file.path;
|
|
337
|
+
await this.ensureStagingFolder();
|
|
338
|
+
const stagedPath = await this.getAvailableStagedPath(file.name);
|
|
339
|
+
const adapter = this.app.vault.adapter;
|
|
340
|
+
await adapter.rename(originalPath, stagedPath);
|
|
341
|
+
this.stagedTrashPaths.push(stagedPath);
|
|
342
|
+
this.pushUndo(async () => {
|
|
343
|
+
if (await adapter.exists(stagedPath)) {
|
|
344
|
+
await adapter.rename(stagedPath, originalPath);
|
|
345
|
+
}
|
|
346
|
+
});
|
|
347
|
+
}
|
|
348
|
+
assertNotCommitted() {
|
|
349
|
+
if (this.state === "committed") {
|
|
350
|
+
throw new Error("Cannot roll back a committed transaction.");
|
|
351
|
+
}
|
|
352
|
+
}
|
|
353
|
+
assertOpen() {
|
|
354
|
+
if (this.state !== "open") {
|
|
355
|
+
throw new Error(`Cannot mutate a ${this.state} transaction.`);
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
disposeMutationBypass() {
|
|
359
|
+
if (this.mutationBypass) {
|
|
360
|
+
(0, import_disposable.dispose)(this.mutationBypass);
|
|
361
|
+
}
|
|
362
|
+
this.mutationBypass = null;
|
|
363
|
+
}
|
|
364
|
+
async ensureStagingFolder() {
|
|
365
|
+
if (this.hasStagingFolder) {
|
|
366
|
+
return;
|
|
367
|
+
}
|
|
368
|
+
const adapter = this.app.vault.adapter;
|
|
369
|
+
if (!await adapter.exists(this.stagingFolderPath)) {
|
|
370
|
+
await adapter.mkdir(this.stagingFolderPath);
|
|
371
|
+
}
|
|
372
|
+
this.hasStagingFolder = true;
|
|
373
|
+
}
|
|
374
|
+
async getAvailableStagedPath(name) {
|
|
375
|
+
const adapter = this.app.vault.adapter;
|
|
376
|
+
const dotIndex = name.lastIndexOf(".");
|
|
377
|
+
const hasExtension = dotIndex > 0;
|
|
378
|
+
const baseName = hasExtension ? name.slice(0, dotIndex) : name;
|
|
379
|
+
const extension = hasExtension ? name.slice(dotIndex) : "";
|
|
380
|
+
let candidate = `${this.stagingFolderPath}/${name}`;
|
|
381
|
+
let counter = 1;
|
|
382
|
+
while (await adapter.exists(candidate)) {
|
|
383
|
+
candidate = `${this.stagingFolderPath}/${baseName} ${counter.toString()}${extension}`;
|
|
384
|
+
counter++;
|
|
385
|
+
}
|
|
386
|
+
return candidate;
|
|
387
|
+
}
|
|
388
|
+
async hardDelete(path) {
|
|
389
|
+
const file = (0, import_file_system.getAbstractFileOrNull)({ app: this.app, pathOrFile: path });
|
|
390
|
+
if (file) {
|
|
391
|
+
await this.app.vault.delete(file, true);
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
pushUndo(undo) {
|
|
395
|
+
this.undoSteps.push({ undo });
|
|
396
|
+
}
|
|
397
|
+
async removeStagingFolder() {
|
|
398
|
+
if (!this.hasStagingFolder) {
|
|
399
|
+
return;
|
|
400
|
+
}
|
|
401
|
+
this.hasStagingFolder = false;
|
|
402
|
+
const adapter = this.app.vault.adapter;
|
|
403
|
+
if (await adapter.exists(this.stagingFolderPath)) {
|
|
404
|
+
await adapter.rmdir(this.stagingFolderPath, true);
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
409
|
+
0 && (module.exports = {
|
|
410
|
+
VaultTransaction
|
|
411
|
+
});
|
|
412
|
+
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vLi4vc3JjL3ZhdWx0LXRyYW5zYWN0aW9uLnRzIl0sCiAgInNvdXJjZXNDb250ZW50IjogWyIvKipcbiAqIEBmaWxlXG4gKlxuICogQSByZXZlcnNpYmxlLCB0cmFuc2FjdGlvbmFsIGxvZyBvZiB2YXVsdCBtdXRhdGlvbnMuIEVhY2ggbXV0YXRpb24gcmVjb3JkcyBob3cgdG8gdW5kbyBpdHNlbGY7XG4gKiB7QGxpbmsgVmF1bHRUcmFuc2FjdGlvbi5yb2xsYmFja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