@mdfriday/foundry 26.4.20 → 26.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/obsidian/mobile.js +1 -1
- package/dist/cjs/worker/pool-manager.js +2 -2
- package/dist/cjs/worker/worker-node.js +2 -2
- package/dist/esm/index.js +1 -1
- package/dist/esm/obsidian/mobile.js +1 -1
- package/dist/types/internal/application/batch-task-queue.d.ts +17 -0
- package/dist/types/internal/application/container.d.ts +66 -0
- package/dist/types/internal/application/identity.d.ts +173 -0
- package/dist/types/internal/application/incremental-build-coordinator.d.ts +28 -0
- package/dist/types/internal/application/incremental-ssg.d.ts +4 -0
- package/dist/types/internal/application/index.d.ts +5 -4
- package/dist/types/internal/application/publish.d.ts +37 -0
- package/dist/types/internal/application/ssg-parallel.d.ts +6 -0
- package/dist/types/internal/application/ssg.d.ts +15 -0
- package/dist/types/internal/application/wiki-service-config.d.ts +65 -0
- package/dist/types/internal/application/wiki-service.d.ts +236 -0
- package/dist/types/internal/application/worker/pool-manager.d.ts +43 -0
- package/dist/types/internal/application/worker/worker-browser.d.ts +6 -0
- package/dist/types/internal/application/worker/worker-main.d.ts +12 -0
- package/dist/types/internal/application/worker/worker-state.d.ts +23 -0
- package/dist/types/internal/application/workspace.d.ts +98 -0
- package/dist/types/internal/domain/config/entity/config.d.ts +40 -0
- package/dist/types/internal/domain/config/entity/language.d.ts +51 -0
- package/dist/types/internal/domain/config/entity/markdown.d.ts +36 -0
- package/dist/types/internal/domain/config/entity/module.d.ts +36 -0
- package/dist/types/internal/domain/config/entity/root.d.ts +39 -0
- package/dist/types/internal/domain/config/entity/service.d.ts +36 -0
- package/dist/types/internal/domain/config/entity/social.d.ts +43 -0
- package/dist/types/internal/domain/config/entity/taxonomy.d.ts +39 -0
- package/dist/types/internal/domain/config/factory/config.d.ts +3 -0
- package/dist/types/internal/domain/config/factory/loader.d.ts +24 -0
- package/dist/types/internal/domain/config/factory/provider.d.ts +10 -0
- package/dist/types/internal/domain/config/factory/sourcedescriptor.d.ts +12 -0
- package/dist/types/internal/domain/config/type.d.ts +56 -0
- package/dist/types/internal/domain/config/vo/language.d.ts +6 -0
- package/dist/types/internal/domain/config/vo/markdown.d.ts +13 -0
- package/dist/types/internal/domain/config/vo/module.d.ts +9 -0
- package/dist/types/internal/domain/config/vo/root.d.ts +6 -0
- package/dist/types/internal/domain/config/vo/service.d.ts +6 -0
- package/dist/types/internal/domain/config/vo/social.d.ts +16 -0
- package/dist/types/internal/domain/config/vo/taxonomy.d.ts +12 -0
- package/dist/types/internal/domain/content/entity/content.d.ts +36 -0
- package/dist/types/internal/domain/content/entity/page.d.ts +23 -0
- package/dist/types/internal/domain/content/entity/pagebuilder.d.ts +83 -0
- package/dist/types/internal/domain/content/entity/pagecollector.d.ts +3 -0
- package/dist/types/internal/domain/content/entity/pagecontent.d.ts +14 -0
- package/dist/types/internal/domain/content/entity/pagemap.d.ts +69 -0
- package/dist/types/internal/domain/content/entity/pagesource.d.ts +52 -0
- package/dist/types/internal/domain/content/entity/pagetrees.d.ts +12 -0
- package/dist/types/internal/domain/content/entity/paginator.d.ts +19 -0
- package/dist/types/internal/domain/content/entity/section.d.ts +15 -0
- package/dist/types/internal/domain/content/entity/shortcode.d.ts +39 -0
- package/dist/types/internal/domain/content/entity/standalone.d.ts +9 -0
- package/dist/types/internal/domain/content/entity/taxonomy.d.ts +15 -0
- package/dist/types/internal/domain/content/entity/term.d.ts +6 -0
- package/dist/types/internal/domain/content/entity/translator.d.ts +22 -0
- package/dist/types/internal/domain/content/type.d.ts +6 -0
- package/dist/types/internal/domain/content/vo/classifier.d.ts +24 -0
- package/dist/types/internal/domain/content/vo/frontmatter.d.ts +65 -0
- package/dist/types/internal/domain/content/vo/kind.d.ts +10 -0
- package/dist/types/internal/domain/fs/entity/basefs.d.ts +23 -0
- package/dist/types/internal/domain/fs/entity/fs.d.ts +13 -0
- package/dist/types/internal/domain/fs/entity/originfs.d.ts +6 -0
- package/dist/types/internal/domain/fs/entity/overlaydir.d.ts +44 -0
- package/dist/types/internal/domain/fs/entity/overlayfs.d.ts +79 -0
- package/dist/types/internal/domain/fs/entity/service.d.ts +15 -0
- package/dist/types/internal/domain/fs/factory/fs.d.ts +4 -0
- package/dist/types/internal/domain/fs/type.d.ts +95 -0
- package/dist/types/internal/domain/fs/vo/dir.d.ts +41 -0
- package/dist/types/internal/domain/fs/vo/file.d.ts +28 -0
- package/dist/types/internal/domain/fs/vo/fileinfo.d.ts +23 -0
- package/dist/types/internal/domain/fs/vo/filemeta.d.ts +45 -0
- package/dist/types/internal/domain/fs/vo/filesystemscollector.d.ts +17 -0
- package/dist/types/internal/domain/fs/vo/filevitural.d.ts +8 -0
- package/dist/types/internal/domain/fs/vo/osfs.d.ts +12 -0
- package/dist/types/internal/domain/fs/vo/overlay-factory.d.ts +4 -0
- package/dist/types/internal/domain/fs/vo/overlayfs-factory.d.ts +42 -0
- package/dist/types/internal/domain/fs/vo/overlayoptions.d.ts +44 -0
- package/dist/types/internal/domain/fs/vo/static-copier.d.ts +22 -0
- package/dist/types/internal/domain/fs/vo/walkway.d.ts +22 -0
- package/dist/types/internal/domain/identity/entity/user.d.ts +100 -0
- package/dist/types/internal/domain/identity/factory/user-factory.d.ts +183 -0
- package/dist/types/internal/domain/identity/repository/index.d.ts +30 -0
- package/dist/types/internal/domain/identity/type.d.ts +17 -0
- package/dist/types/internal/domain/identity/value-object/device.d.ts +26 -0
- package/dist/types/internal/domain/identity/value-object/email.d.ts +29 -0
- package/dist/types/internal/domain/identity/value-object/license.d.ts +91 -0
- package/dist/types/internal/domain/identity/value-object/server-config.d.ts +37 -0
- package/dist/types/internal/domain/identity/value-object/sync-config.d.ts +47 -0
- package/dist/types/internal/domain/identity/value-object/token.d.ts +35 -0
- package/dist/types/internal/domain/markdown/entity/markdown.d.ts +41 -0
- package/dist/types/internal/domain/markdown/factory/it/config.d.ts +60 -0
- package/dist/types/internal/domain/markdown/factory/it/index.d.ts +21 -1
- package/dist/types/internal/domain/markdown/factory/it/parserresult.d.ts +3 -0
- package/dist/types/internal/domain/markdown/factory/it/plugins/callout-plugin.d.ts +40 -0
- package/dist/types/internal/domain/markdown/factory/it/plugins/latex-plugin.d.ts +23 -0
- package/dist/types/internal/domain/markdown/factory/it/plugins/mermaid-plugin.d.ts +24 -0
- package/dist/types/internal/domain/markdown/factory/it/plugins/tag-plugin.d.ts +71 -0
- package/dist/types/internal/domain/markdown/factory/it/plugins/wikilink-plugin.d.ts +28 -0
- package/dist/types/internal/domain/markdown/factory/it/plugins/wikilink.d.ts +31 -0
- package/dist/types/internal/domain/markdown/factory/it/tableofcontents.d.ts +21 -0
- package/dist/types/internal/domain/markdown/factory/it/util/path.d.ts +11 -0
- package/dist/types/internal/domain/markdown/factory/it/util/slugger-fallback.d.ts +6 -0
- package/dist/types/internal/domain/markdown/type.d.ts +159 -0
- package/dist/types/internal/domain/markdown/vo/config.d.ts +48 -0
- package/dist/types/internal/domain/markdown/vo/content.d.ts +92 -0
- package/dist/types/internal/domain/markdown/vo/context.d.ts +9 -0
- package/dist/types/internal/domain/markdown/vo/highlight.d.ts +15 -0
- package/dist/types/internal/domain/markdown/vo/pageparser.d.ts +9 -0
- package/dist/types/internal/domain/markdown/vo/parseinfo.d.ts +36 -0
- package/dist/types/internal/domain/markdown/vo/parserresult.d.ts +6 -0
- package/dist/types/internal/domain/markdown/vo/shortcode.d.ts +31 -1
- package/dist/types/internal/domain/markdown/vo/tableofcontents.d.ts +21 -0
- package/dist/types/internal/domain/module/entity/lang.d.ts +12 -0
- package/dist/types/internal/domain/module/entity/module.d.ts +73 -0
- package/dist/types/internal/domain/module/factory/module.d.ts +6 -0
- package/dist/types/internal/domain/module/type.d.ts +58 -0
- package/dist/types/internal/domain/module/vo/cache.d.ts +48 -0
- package/dist/types/internal/domain/module/vo/httpclient.d.ts +14 -0
- package/dist/types/internal/domain/module/vo/module.d.ts +76 -0
- package/dist/types/internal/domain/module/vo/mount.d.ts +39 -0
- package/dist/types/internal/domain/module/vo/themes.d.ts +38 -0
- package/dist/types/internal/domain/module/vo/zipextractor.d.ts +31 -0
- package/dist/types/internal/domain/paths/entity/path.d.ts +28 -0
- package/dist/types/internal/domain/paths/factory/pathfactory.d.ts +82 -0
- package/dist/types/internal/domain/paths/type.d.ts +132 -0
- package/dist/types/internal/domain/paths/vo/pathcomponents.d.ts +94 -0
- package/dist/types/internal/domain/paths/vo/pathparser.d.ts +77 -0
- package/dist/types/internal/domain/publish/entity/publisher.d.ts +26 -0
- package/dist/types/internal/domain/publish/factory/publisher-factory.d.ts +17 -0
- package/dist/types/internal/domain/publish/repository/http-client.d.ts +21 -0
- package/dist/types/internal/domain/publish/repository/manifest-repository.d.ts +27 -0
- package/dist/types/internal/domain/publish/type.d.ts +49 -0
- package/dist/types/internal/domain/publish/value-object/ftp-publisher.d.ts +30 -0
- package/dist/types/internal/domain/publish/value-object/mdfriday-publisher.d.ts +57 -0
- package/dist/types/internal/domain/publish/value-object/netlify-publisher.d.ts +55 -0
- package/dist/types/internal/domain/publish/value-object/publish-config.d.ts +38 -0
- package/dist/types/internal/domain/publish/value-object/publish-manifest.d.ts +50 -0
- package/dist/types/internal/domain/resources/entity/http.d.ts +11 -0
- package/dist/types/internal/domain/resources/entity/integrity.d.ts +4 -0
- package/dist/types/internal/domain/resources/entity/minifier.d.ts +4 -0
- package/dist/types/internal/domain/resources/entity/publisher.d.ts +24 -0
- package/dist/types/internal/domain/resources/entity/resource.d.ts +4 -0
- package/dist/types/internal/domain/resources/entity/resources.d.ts +40 -0
- package/dist/types/internal/domain/resources/entity/template.d.ts +4 -0
- package/dist/types/internal/domain/resources/factory/resource.d.ts +4 -0
- package/dist/types/internal/domain/site/entity/language.d.ts +55 -0
- package/dist/types/internal/domain/site/entity/menu-builder.d.ts +50 -0
- package/dist/types/internal/domain/site/entity/navigation.d.ts +8 -0
- package/dist/types/internal/domain/site/entity/page.d.ts +88 -0
- package/dist/types/internal/domain/site/entity/pagegraph.d.ts +85 -0
- package/dist/types/internal/domain/site/entity/pager.d.ts +6 -0
- package/dist/types/internal/domain/site/entity/publisher.d.ts +26 -0
- package/dist/types/internal/domain/site/entity/ref.d.ts +27 -0
- package/dist/types/internal/domain/site/entity/site.d.ts +178 -0
- package/dist/types/internal/domain/site/factory/navigation-factory.d.ts +6 -0
- package/dist/types/internal/domain/site/factory/site.d.ts +4 -0
- package/dist/types/internal/domain/site/service/html-link-processor.d.ts +44 -0
- package/dist/types/internal/domain/site/type.d.ts +100 -0
- package/dist/types/internal/domain/site/valueobject/author.d.ts +16 -0
- package/dist/types/internal/domain/site/valueobject/baseurl.d.ts +39 -0
- package/dist/types/internal/domain/site/valueobject/menu.d.ts +49 -0
- package/dist/types/internal/domain/site/valueobject/organization.d.ts +37 -0
- package/dist/types/internal/domain/site/valueobject/path.d.ts +50 -0
- package/dist/types/internal/domain/site/valueobject/version.d.ts +14 -0
- package/dist/types/internal/domain/template/entity/executor.d.ts +22 -0
- package/dist/types/internal/domain/template/entity/lookup.d.ts +55 -0
- package/dist/types/internal/domain/template/entity/parser.d.ts +40 -0
- package/dist/types/internal/domain/template/entity/template.d.ts +87 -0
- package/dist/types/internal/domain/template/factory/template.d.ts +61 -0
- package/dist/types/internal/domain/template/type.d.ts +109 -0
- package/dist/types/internal/domain/template/vo/baseof.d.ts +47 -0
- package/dist/types/internal/domain/template/vo/info.d.ts +28 -0
- package/dist/types/internal/domain/template/vo/namespace.d.ts +91 -0
- package/dist/types/internal/domain/template/vo/registry.d.ts +160 -0
- package/dist/types/internal/domain/wiki/entity/concept.d.ts +31 -0
- package/dist/types/internal/domain/wiki/entity/connection.d.ts +29 -0
- package/dist/types/internal/domain/wiki/entity/conversation.d.ts +65 -0
- package/dist/types/internal/domain/wiki/entity/embedding-index.d.ts +60 -0
- package/dist/types/internal/domain/wiki/entity/entity.d.ts +32 -0
- package/dist/types/internal/domain/wiki/entity/knowledge-base.d.ts +310 -0
- package/dist/types/internal/domain/wiki/entity/operation-log.d.ts +82 -0
- package/dist/types/internal/domain/wiki/factory/wiki-factory.d.ts +41 -0
- package/dist/types/internal/domain/wiki/index.d.ts +24 -0
- package/dist/types/internal/domain/wiki/repository/conversation-repository.interface.d.ts +29 -0
- package/dist/types/internal/domain/wiki/repository/crypto-service.d.ts +16 -0
- package/dist/types/internal/domain/wiki/repository/embedding-provider.d.ts +20 -0
- package/dist/types/internal/domain/wiki/repository/file-system.d.ts +43 -0
- package/dist/types/internal/domain/wiki/repository/index.d.ts +14 -0
- package/dist/types/internal/domain/wiki/repository/kb-repository.interface.d.ts +30 -0
- package/dist/types/internal/domain/wiki/repository/llm-http-client.d.ts +40 -0
- package/dist/types/internal/domain/wiki/repository/llm-provider.d.ts +40 -0
- package/dist/types/internal/domain/wiki/repository/path-service.d.ts +32 -0
- package/dist/types/internal/domain/wiki/repository/wiki-page-repository.interface.d.ts +49 -0
- package/dist/types/internal/domain/wiki/value-object/connection-type.d.ts +24 -0
- package/dist/types/internal/domain/wiki/value-object/content-annotator.d.ts +61 -0
- package/dist/types/internal/domain/wiki/value-object/entity-id.d.ts +17 -0
- package/dist/types/internal/domain/wiki/value-object/entity-type.d.ts +24 -0
- package/dist/types/internal/domain/wiki/value-object/extraction-parser.d.ts +27 -0
- package/dist/types/internal/domain/wiki/value-object/extraction-result.d.ts +32 -0
- package/dist/types/internal/domain/wiki/value-object/pricing.d.ts +64 -0
- package/dist/types/internal/domain/wiki/value-object/retrieval.d.ts +228 -0
- package/dist/types/internal/domain/wiki/value-object/source-record.d.ts +17 -0
- package/dist/types/internal/domain/wiki/value-object/token-usage.d.ts +26 -0
- package/dist/types/internal/domain/wiki/value-object/wiki-config.d.ts +40 -0
- package/dist/types/internal/domain/wiki/value-object/wiki-index-generator.d.ts +31 -0
- package/dist/types/internal/domain/wiki/value-object/wiki-page-renderer.d.ts +42 -0
- package/dist/types/internal/domain/workspace/entity/authentication.d.ts +29 -0
- package/dist/types/internal/domain/workspace/entity/project.d.ts +173 -0
- package/dist/types/internal/domain/workspace/entity/workspace.d.ts +85 -0
- package/dist/types/internal/domain/workspace/factory/workspace-factory.d.ts +107 -0
- package/dist/types/internal/domain/workspace/repository/file-system.d.ts +241 -0
- package/dist/types/internal/domain/workspace/repository/index.d.ts +6 -0
- package/dist/types/internal/domain/workspace/repository.d.ts +72 -0
- package/dist/types/internal/domain/workspace/type.d.ts +18 -0
- package/dist/types/internal/domain/workspace/value-object/folder-structure.d.ts +41 -0
- package/dist/types/internal/domain/workspace/value-object/project-metadata.d.ts +36 -0
- package/dist/types/internal/domain/workspace/value-object/workspace-metadata.d.ts +7 -0
- package/dist/types/internal/infrastructure/embedding/embedding-provider.interface.d.ts +33 -0
- package/dist/types/internal/infrastructure/embedding/index.d.ts +5 -0
- package/dist/types/internal/infrastructure/embedding/ollama-embedding-provider.d.ts +36 -0
- package/dist/types/internal/infrastructure/http/netlify-http-client.d.ts +20 -0
- package/dist/types/internal/infrastructure/http/node-http-client.d.ts +3 -0
- package/dist/types/internal/infrastructure/index.d.ts +8 -0
- package/dist/types/internal/infrastructure/llm/fetch-http-client.d.ts +24 -0
- package/dist/types/internal/infrastructure/llm/index.d.ts +6 -0
- package/dist/types/internal/infrastructure/llm/llm-config.d.ts +80 -0
- package/dist/types/internal/infrastructure/llm/lmstudio-provider.d.ts +71 -0
- package/dist/types/internal/infrastructure/llm/node-llm-http-client.d.ts +21 -0
- package/dist/types/internal/infrastructure/llm/ollama-provider.d.ts +22 -0
- package/dist/types/internal/infrastructure/llm/openai-compatible-provider.d.ts +75 -0
- package/dist/types/internal/infrastructure/llm/provider-factory.d.ts +36 -0
- package/dist/types/internal/infrastructure/llm/provider.d.ts +90 -0
- package/dist/types/internal/infrastructure/node/index.d.ts +11 -0
- package/dist/types/internal/infrastructure/node/node-conversation-repository.d.ts +21 -0
- package/dist/types/internal/infrastructure/node/node-crypto-service.d.ts +10 -0
- package/dist/types/internal/infrastructure/node/node-file-system.d.ts +29 -0
- package/dist/types/internal/infrastructure/node/node-kb-repository.d.ts +18 -0
- package/dist/types/internal/infrastructure/node/node-path-service.d.ts +14 -0
- package/dist/types/internal/infrastructure/node/node-wiki-page-repository.d.ts +25 -0
- package/dist/types/internal/infrastructure/persistence/node-file-system.d.ts +8 -0
- package/dist/types/internal/infrastructure/persistence/node-manifest-repository.d.ts +31 -0
- package/dist/types/internal/infrastructure/persistence/node-snapshot-repository.d.ts +28 -0
- package/dist/types/internal/infrastructure/persistence/node-workspace-repository.d.ts +9 -0
- package/dist/types/pkg/cahce/cache.d.ts +56 -0
- package/dist/types/pkg/lang/data.d.ts +21 -0
- package/dist/types/pkg/lang/index.d.ts +46 -0
- package/dist/types/pkg/lang/service.d.ts +49 -0
- package/dist/types/pkg/lang/types.d.ts +29 -0
- package/dist/types/pkg/log/http.d.ts +16 -0
- package/dist/types/pkg/log/manager.d.ts +57 -0
- package/dist/types/pkg/maps/scratch.d.ts +25 -0
- package/dist/types/pkg/md/parser/item.d.ts +3 -3
- package/dist/types/pkg/media/type.d.ts +19 -0
- package/dist/types/pkg/page-filter/index.d.ts +29 -0
- package/dist/types/pkg/paths/index.d.ts +9 -0
- package/dist/types/pkg/text/index.d.ts +4 -0
- package/dist/types/pkg/web/server/livereload-server.d.ts +7 -0
- package/dist/types/pkg/web/watcher/content-file-watcher.d.ts +3 -0
- package/package.json +21 -15
- package/dist/types/index.d.ts +0 -20
- package/dist/types/internal/interfaces/obsidian/adapters/identity-adapter.d.ts +0 -5
- package/dist/types/internal/interfaces/obsidian/adapters/index.d.ts +0 -2
- package/dist/types/internal/interfaces/obsidian/adapters/workspace-adapter.d.ts +0 -8
- package/dist/types/internal/interfaces/obsidian/desktop/adapters/identity-adapter.d.ts +0 -6
- package/dist/types/internal/interfaces/obsidian/desktop/adapters/index.d.ts +0 -2
- package/dist/types/internal/interfaces/obsidian/desktop/adapters/workspace-adapter.d.ts +0 -12
- package/dist/types/internal/interfaces/obsidian/desktop/container.d.ts +0 -7
- package/dist/types/internal/interfaces/obsidian/desktop/index.d.ts +0 -22
- package/dist/types/internal/interfaces/obsidian/index.d.ts +0 -7
- package/dist/types/internal/interfaces/obsidian/mobile/adapters/identity-adapter.d.ts +0 -9
- package/dist/types/internal/interfaces/obsidian/mobile/adapters/index.d.ts +0 -2
- package/dist/types/internal/interfaces/obsidian/mobile/adapters/workspace-adapter.d.ts +0 -13
- package/dist/types/internal/interfaces/obsidian/mobile/config-types.d.ts +0 -13
- package/dist/types/internal/interfaces/obsidian/mobile/container.d.ts +0 -6
- package/dist/types/internal/interfaces/obsidian/mobile/index.d.ts +0 -16
- package/dist/types/internal/interfaces/obsidian/mobile.d.ts +0 -2
- package/dist/types/internal/interfaces/obsidian/services/auth.service.d.ts +0 -11
- package/dist/types/internal/interfaces/obsidian/services/build.service.d.ts +0 -9
- package/dist/types/internal/interfaces/obsidian/services/config.service.d.ts +0 -31
- package/dist/types/internal/interfaces/obsidian/services/domain.service.d.ts +0 -15
- package/dist/types/internal/interfaces/obsidian/services/license.service.d.ts +0 -22
- package/dist/types/internal/interfaces/obsidian/services/project.service.d.ts +0 -17
- package/dist/types/internal/interfaces/obsidian/services/publish.service.d.ts +0 -11
- package/dist/types/internal/interfaces/obsidian/services/serve.service.d.ts +0 -18
- package/dist/types/internal/interfaces/obsidian/services/workspace.service.d.ts +0 -10
- package/dist/types/internal/interfaces/obsidian/types/auth.d.ts +0 -27
- package/dist/types/internal/interfaces/obsidian/types/build.d.ts +0 -23
- package/dist/types/internal/interfaces/obsidian/types/config.d.ts +0 -16
- package/dist/types/internal/interfaces/obsidian/types/domain.d.ts +0 -46
- package/dist/types/internal/interfaces/obsidian/types/index.d.ts +0 -9
- package/dist/types/internal/interfaces/obsidian/types/license.d.ts +0 -87
- package/dist/types/internal/interfaces/obsidian/types/project.d.ts +0 -56
- package/dist/types/internal/interfaces/obsidian/types/publish.d.ts +0 -33
- package/dist/types/internal/interfaces/obsidian/types/serve.d.ts +0 -46
- package/dist/types/internal/interfaces/obsidian/types/workspace.d.ts +0 -27
- package/dist/types/pkg/log/browser-manager.d.ts +0 -20
- package/dist/types/pkg/log/browser.d.ts +0 -25
- package/dist/types/pkg/media/buildin.d.ts +0 -3
|
@@ -15,16 +15,52 @@ export declare class Content {
|
|
|
15
15
|
collectPages(): Promise<void>;
|
|
16
16
|
private process;
|
|
17
17
|
private assemble;
|
|
18
|
+
/**
|
|
19
|
+
* GetPageSources - exact replica of Go's GetPageSources method
|
|
20
|
+
*/
|
|
18
21
|
getPageSources(page: Page): Promise<PageSource[]>;
|
|
22
|
+
/**
|
|
23
|
+
* GlobalPages - exact replica of Go's GlobalPages method
|
|
24
|
+
*/
|
|
19
25
|
globalPages(langIndex: number): Promise<Pages>;
|
|
20
26
|
globalRegularPages(): Promise<Pages>;
|
|
27
|
+
/**
|
|
28
|
+
* WalkPages - exact replica of Go's WalkPages method
|
|
29
|
+
* TypeScript equivalent of golang/internal/domain/contenthub/entity/walk.go:WalkPages
|
|
30
|
+
*/
|
|
21
31
|
walkPages(langIndex: number, walker: (page: Page) => Promise<void>): Promise<void>;
|
|
32
|
+
/**
|
|
33
|
+
* WalkTaxonomies - exact replica of Go's WalkTaxonomies method
|
|
34
|
+
* TypeScript equivalent of golang/internal/domain/contenthub/entity/walk.go:WalkTaxonomies
|
|
35
|
+
*/
|
|
22
36
|
walkTaxonomies(langIndex: number, walker: WalkTaxonomyFunc): Promise<void>;
|
|
37
|
+
/**
|
|
38
|
+
* GetPageFromPath - TypeScript equivalent of Go's PageFinder.GetPageFromPath
|
|
39
|
+
* This is the core content domain business logic for finding pages by path
|
|
40
|
+
*/
|
|
23
41
|
getPageFromPath(langIndex: number, path: string): Page | null;
|
|
24
42
|
getPageFromFile(langIndex: number, file: FileInfo): Page | null;
|
|
25
43
|
handleChangeFiles(fileMetaInfos: Map<string, FileMetaInfo>): Promise<string[]>;
|
|
44
|
+
/**
|
|
45
|
+
* 添加或更新文件到 PageMap,参考 collectDir 中的实现
|
|
46
|
+
*/
|
|
26
47
|
private addOrUpdateFile;
|
|
48
|
+
/**
|
|
49
|
+
* Translate a message for a specific language
|
|
50
|
+
* @param lang Language code
|
|
51
|
+
* @param translationID Translation identifier
|
|
52
|
+
* @returns Translated string
|
|
53
|
+
*/
|
|
27
54
|
translate(lang: string, translationID: string): string;
|
|
55
|
+
/**
|
|
56
|
+
* Get available translation languages
|
|
57
|
+
* @returns Array of language codes
|
|
58
|
+
*/
|
|
28
59
|
getAvailableLanguages(): string[];
|
|
60
|
+
/**
|
|
61
|
+
* Check if a language has translation support
|
|
62
|
+
* @param lang Language code
|
|
63
|
+
* @returns True if language is supported
|
|
64
|
+
*/
|
|
29
65
|
hasLanguageSupport(lang: string): boolean;
|
|
30
66
|
}
|
|
@@ -26,13 +26,36 @@ export declare class PageImpl implements Page {
|
|
|
26
26
|
section(): string;
|
|
27
27
|
paths(): Path;
|
|
28
28
|
path(): string;
|
|
29
|
+
/**
|
|
30
|
+
* Get page slug for PageGraph (Quartz-compatible format)
|
|
31
|
+
* Slug format: "posts/my-post" (no leading slash, no extension)
|
|
32
|
+
*
|
|
33
|
+
* Examples:
|
|
34
|
+
* - "/posts/my-post.md" → "posts/my-post"
|
|
35
|
+
* - "/posts/index.md" → "posts"
|
|
36
|
+
* - "/about.md" → "about"
|
|
37
|
+
* - "/index.md" → "index"
|
|
38
|
+
*/
|
|
29
39
|
slug(): string;
|
|
40
|
+
/**
|
|
41
|
+
* Convert path to slug (Quartz-compatible)
|
|
42
|
+
*
|
|
43
|
+
* Rules:
|
|
44
|
+
* 1. Remove leading slash
|
|
45
|
+
* 2. Remove file extension
|
|
46
|
+
* 3. Handle index files (index → parent folder)
|
|
47
|
+
* 4. Handle _index files (Hugo-style section index)
|
|
48
|
+
*/
|
|
30
49
|
private pathToSlug;
|
|
31
50
|
posOffset(offset: number): Promise<Position>;
|
|
32
51
|
description(): string;
|
|
33
52
|
get Description(): string;
|
|
34
53
|
StaticURL(src: string): string;
|
|
35
54
|
params(): Record<string, any>;
|
|
55
|
+
/**
|
|
56
|
+
* Template-friendly Params property getter
|
|
57
|
+
* Allows templates to access .Params instead of .params()
|
|
58
|
+
*/
|
|
36
59
|
get Params(): Record<string, any>;
|
|
37
60
|
store(): Scratch;
|
|
38
61
|
get Store(): Scratch;
|
|
@@ -28,35 +28,118 @@ export declare class PageBuilder {
|
|
|
28
28
|
private renderableDocument;
|
|
29
29
|
constructor(urlSvc: URLService, langSvc: LangService, taxonomySvc: TaxonomyService, templateSvc: Template | null, pageMapper: PageMap | null, taxonomy: Taxonomy, term: Term, section: Section, standalone: Standalone, converter: Converter, contentHub: ContentHub | null);
|
|
30
30
|
withSource(source: Source): PageBuilder;
|
|
31
|
+
/**
|
|
32
|
+
* WithLangIdx - exact replica of Go's WithLangIdx method
|
|
33
|
+
*/
|
|
31
34
|
withLangIdx(idx: number): PageBuilder;
|
|
35
|
+
/**
|
|
36
|
+
* Reset - exact replica of Go's reset method
|
|
37
|
+
*/
|
|
32
38
|
private reset;
|
|
39
|
+
/**
|
|
40
|
+
* Build - exact replica of Go's Build method
|
|
41
|
+
*/
|
|
33
42
|
build(): Promise<Page>;
|
|
43
|
+
/**
|
|
44
|
+
* KindBuild - exact replica of Go's KindBuild method
|
|
45
|
+
*/
|
|
34
46
|
kindBuild(): Promise<Page>;
|
|
47
|
+
/**
|
|
48
|
+
* Build internal - exact replica of Go's build method
|
|
49
|
+
*/
|
|
35
50
|
private buildInternal;
|
|
51
|
+
/**
|
|
52
|
+
* Build page - exact replica of Go's buildPage method
|
|
53
|
+
*/
|
|
36
54
|
private buildPage;
|
|
55
|
+
/**
|
|
56
|
+
* Build page with kind - exact replica of Go's buildPageWithKind method
|
|
57
|
+
*/
|
|
37
58
|
private buildPageWithKind;
|
|
59
|
+
/**
|
|
60
|
+
* Apply front matter - exact replica of Go's applyFrontMatter method
|
|
61
|
+
*/
|
|
38
62
|
private applyFrontMatter;
|
|
63
|
+
/**
|
|
64
|
+
* Build home - exact replica of Go's buildHome method
|
|
65
|
+
*/
|
|
39
66
|
private buildHome;
|
|
67
|
+
/**
|
|
68
|
+
* Build section - exact replica of Go's buildSection method
|
|
69
|
+
*/
|
|
40
70
|
private buildSection;
|
|
71
|
+
/**
|
|
72
|
+
* Build 404 - exact replica of Go's build404 method
|
|
73
|
+
*/
|
|
41
74
|
private build404;
|
|
75
|
+
/**
|
|
76
|
+
* Build sitemap - exact replica of Go's buildSitemap method
|
|
77
|
+
*/
|
|
42
78
|
private buildSitemap;
|
|
79
|
+
/**
|
|
80
|
+
* Build taxonomy - exact replica of Go's buildTaxonomy method
|
|
81
|
+
*/
|
|
43
82
|
private buildTaxonomy;
|
|
83
|
+
/**
|
|
84
|
+
* Build term - exact replica of Go's buildTerm method
|
|
85
|
+
*/
|
|
44
86
|
private buildTerm;
|
|
45
87
|
private render;
|
|
46
88
|
private parse;
|
|
89
|
+
/**
|
|
90
|
+
* Parse terms - exact replica of Go's parseTerms method
|
|
91
|
+
*/
|
|
47
92
|
private parseTerms;
|
|
93
|
+
/**
|
|
94
|
+
* Parse kind - exact replica of Go's parseKind method
|
|
95
|
+
*/
|
|
48
96
|
private parseKind;
|
|
97
|
+
/**
|
|
98
|
+
* Parse language by default - exact replica of Go's parseLanguageByDefault method
|
|
99
|
+
*/
|
|
49
100
|
private parseLanguageByDefault;
|
|
101
|
+
/**
|
|
102
|
+
* Parse language by index - exact replica of Go's parseLanguageByIdx method
|
|
103
|
+
*/
|
|
50
104
|
private parseLanguageByIdx;
|
|
105
|
+
/**
|
|
106
|
+
* Parse language - exact replica of Go's parseLanguage method
|
|
107
|
+
*/
|
|
51
108
|
private parseLanguage;
|
|
109
|
+
/**
|
|
110
|
+
* Parse front matter - exact replica of Go's parseFrontMatter method
|
|
111
|
+
*/
|
|
52
112
|
private parseFrontMatter;
|
|
113
|
+
/**
|
|
114
|
+
* Create shortcode renderer - returns a simple renderer for shortcodes
|
|
115
|
+
*/
|
|
53
116
|
private createShortcodeRenderer;
|
|
54
117
|
private doRenderShortcode;
|
|
55
118
|
private renderShortcodeMarkdown;
|
|
119
|
+
/**
|
|
120
|
+
* Build pagination - creates pagination for page
|
|
121
|
+
* TypeScript equivalent of Go's buildPagination method
|
|
122
|
+
*/
|
|
56
123
|
private buildPagination;
|
|
124
|
+
/**
|
|
125
|
+
* Adapt pagination - creates empty pagination for pages that don't support it
|
|
126
|
+
* TypeScript equivalent of Go's adaptPagination method
|
|
127
|
+
*/
|
|
57
128
|
private adaptPagination;
|
|
129
|
+
/**
|
|
130
|
+
* Build output - builds page output
|
|
131
|
+
*/
|
|
58
132
|
private buildOutput;
|
|
133
|
+
/**
|
|
134
|
+
* New page - creates a new page instance based on Go version
|
|
135
|
+
*/
|
|
59
136
|
private newPage;
|
|
137
|
+
/**
|
|
138
|
+
* New taxonomy - creates a new taxonomy page
|
|
139
|
+
*/
|
|
60
140
|
private newTaxonomy;
|
|
141
|
+
/**
|
|
142
|
+
* New term - creates a new term page
|
|
143
|
+
*/
|
|
61
144
|
private newTerm;
|
|
62
145
|
}
|
|
@@ -5,6 +5,9 @@ export declare class PagesCollector {
|
|
|
5
5
|
private processedPaths;
|
|
6
6
|
constructor(pageMap: PageMap, fs: FsService);
|
|
7
7
|
collect(): Promise<void>;
|
|
8
|
+
/**
|
|
9
|
+
* CollectDir - exact replica of Go's collectDir method
|
|
10
|
+
*/
|
|
8
11
|
private collectDir;
|
|
9
12
|
private handleBundleLeaf;
|
|
10
13
|
}
|
|
@@ -1,22 +1,36 @@
|
|
|
1
1
|
import { TocFragments } from "@internal/domain/markdown";
|
|
2
2
|
export declare class Content {
|
|
3
3
|
private rawSource;
|
|
4
|
+
/** Front matter data */
|
|
4
5
|
frontMatter?: Record<string, any>;
|
|
6
|
+
/** Final rendered HTML content */
|
|
5
7
|
renderedContent: string;
|
|
8
|
+
/** Content summary */
|
|
6
9
|
summary: string;
|
|
10
|
+
/** Word count */
|
|
7
11
|
wordCount: number;
|
|
12
|
+
/** Reading time in minutes */
|
|
8
13
|
readingTime: number;
|
|
9
14
|
toc?: TocFragments;
|
|
10
15
|
lazyRendered: boolean;
|
|
11
16
|
lazyRender: (() => Promise<void>) | undefined;
|
|
12
17
|
constructor(source: Uint8Array);
|
|
18
|
+
/**
|
|
19
|
+
* Update content with parsed and rendered data
|
|
20
|
+
*/
|
|
13
21
|
updateWithContentResult(result: any): void;
|
|
22
|
+
/**
|
|
23
|
+
* Get raw source content
|
|
24
|
+
*/
|
|
14
25
|
getRawSource(): Uint8Array;
|
|
15
26
|
RenderedContent(): Promise<string>;
|
|
16
27
|
Summary(): Promise<string>;
|
|
17
28
|
WordCount(): Promise<number>;
|
|
18
29
|
ReadingTime(): Promise<number>;
|
|
19
30
|
render(): Promise<void>;
|
|
31
|
+
/**
|
|
32
|
+
* Check if content is empty
|
|
33
|
+
*/
|
|
20
34
|
isEmpty(): boolean;
|
|
21
35
|
}
|
|
22
36
|
export declare function newContent(source: Uint8Array): Content;
|
|
@@ -3,7 +3,13 @@ import { PageTrees, PageTreesNode } from './pagetrees';
|
|
|
3
3
|
import { PageBuilder } from './pagebuilder';
|
|
4
4
|
import { FileInfo } from '../vo/fileinfo';
|
|
5
5
|
import { DynaCache } from '@pkg/cahce/cache';
|
|
6
|
+
/**
|
|
7
|
+
* Path utility functions - simplified implementations
|
|
8
|
+
*/
|
|
6
9
|
export declare function addTrailingSlash(path: string): string;
|
|
10
|
+
/**
|
|
11
|
+
* Page predicates - exact replica of Go's pagePredicates
|
|
12
|
+
*/
|
|
7
13
|
export declare const pagePredicates: {
|
|
8
14
|
kindPage: (p: Page) => boolean;
|
|
9
15
|
kindSection: (p: Page) => boolean;
|
|
@@ -14,18 +20,27 @@ export declare const pagePredicates: {
|
|
|
14
20
|
shouldListAny: (p: Page) => boolean;
|
|
15
21
|
shouldLink: (p: Page) => boolean;
|
|
16
22
|
};
|
|
23
|
+
/**
|
|
24
|
+
* PageMapQueryPagesBelowPath - query for pages below a path
|
|
25
|
+
*/
|
|
17
26
|
export interface PageMapQueryPagesBelowPath {
|
|
18
27
|
path: string;
|
|
19
28
|
keyPart: string;
|
|
20
29
|
include: (p: Page) => boolean;
|
|
21
30
|
key(): string;
|
|
22
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* PageMapQueryPagesInSection - query for pages in a section
|
|
34
|
+
*/
|
|
23
35
|
export interface PageMapQueryPagesInSection extends PageMapQueryPagesBelowPath {
|
|
24
36
|
recursive: boolean;
|
|
25
37
|
includeSelf: boolean;
|
|
26
38
|
index: number;
|
|
27
39
|
key(): string;
|
|
28
40
|
}
|
|
41
|
+
/**
|
|
42
|
+
* Implementation of PageMapQueryPagesBelowPath
|
|
43
|
+
*/
|
|
29
44
|
export declare class PageMapQueryPagesBelowPathImpl implements PageMapQueryPagesBelowPath {
|
|
30
45
|
path: string;
|
|
31
46
|
keyPart: string;
|
|
@@ -33,6 +48,9 @@ export declare class PageMapQueryPagesBelowPathImpl implements PageMapQueryPages
|
|
|
33
48
|
constructor(path: string, keyPart: string, include?: (p: Page) => boolean);
|
|
34
49
|
key(): string;
|
|
35
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* Implementation of PageMapQueryPagesInSection
|
|
53
|
+
*/
|
|
36
54
|
export declare class PageMapQueryPagesInSectionImpl extends PageMapQueryPagesBelowPathImpl implements PageMapQueryPagesInSection {
|
|
37
55
|
recursive: boolean;
|
|
38
56
|
includeSelf: boolean;
|
|
@@ -44,22 +62,73 @@ export declare class PageMap extends PageTrees {
|
|
|
44
62
|
private pageReverseIndex;
|
|
45
63
|
pageBuilder: PageBuilder;
|
|
46
64
|
constructor(pageBuilder: PageBuilder);
|
|
65
|
+
/**
|
|
66
|
+
* SetupReverseIndex - exact replica of Go's SetupReverseIndex method
|
|
67
|
+
*/
|
|
47
68
|
setupReverseIndex(): void;
|
|
69
|
+
/**
|
|
70
|
+
* InsertResourceNode - exact replica of Go's InsertResourceNode method
|
|
71
|
+
*/
|
|
48
72
|
insertResourceNode(key: string, node: PageTreesNode): void;
|
|
49
73
|
addFi(f: FileInfo): Promise<void>;
|
|
74
|
+
/**
|
|
75
|
+
* Assemble - exact replica of Go's Assemble method
|
|
76
|
+
*/
|
|
50
77
|
assemble(): Promise<void>;
|
|
78
|
+
/**
|
|
79
|
+
* AssembleTerms - exact replica of Go's assembleTerms method
|
|
80
|
+
*/
|
|
51
81
|
private assembleTerms;
|
|
82
|
+
/**
|
|
83
|
+
* CleanPages - exact replica of Go's cleanPages method
|
|
84
|
+
*/
|
|
52
85
|
private cleanPages;
|
|
86
|
+
/**
|
|
87
|
+
* ApplyAggregates - exact replica of Go's applyAggregates method
|
|
88
|
+
*/
|
|
53
89
|
private applyAggregates;
|
|
90
|
+
/**
|
|
91
|
+
* AssembleStructurePages - exact replica of Go's assembleStructurePages method
|
|
92
|
+
*/
|
|
54
93
|
private assembleStructurePages;
|
|
94
|
+
/**
|
|
95
|
+
* AddMissingTaxonomies - exact replica of Go's addMissingTaxonomies method
|
|
96
|
+
*/
|
|
55
97
|
private addMissingTaxonomies;
|
|
98
|
+
/**
|
|
99
|
+
* AddMissingStandalone - exact replica of Go's addMissingStandalone method
|
|
100
|
+
*/
|
|
56
101
|
private addMissingStandalone;
|
|
102
|
+
/**
|
|
103
|
+
* GetResourcesForPage - exact replica of Go's getResourcesForPage method
|
|
104
|
+
*/
|
|
57
105
|
getResourcesForPage(ps: Page): Promise<PageSource[]>;
|
|
106
|
+
/**
|
|
107
|
+
* ForEachResourceInPage - exact replica of Go's forEachResourceInPage method
|
|
108
|
+
*/
|
|
58
109
|
private forEachResourceInPage;
|
|
110
|
+
/**
|
|
111
|
+
* GetPagesInSection - exact replica of Go's getPagesInSection method
|
|
112
|
+
*/
|
|
59
113
|
getPagesInSection(langIndex: number, q: PageMapQueryPagesInSection): Promise<Pages>;
|
|
114
|
+
/**
|
|
115
|
+
* GetOrCreatePagesFromCache - simplified synchronous version
|
|
116
|
+
*/
|
|
60
117
|
getOrCreatePagesFromCacheSync(cache: DynaCache<string, Pages> | null, key: string, create: (key: string) => Promise<Pages>): Promise<Pages>;
|
|
118
|
+
/**
|
|
119
|
+
* GetPagesWithTerm - exact replica of Go's getPagesWithTerm method
|
|
120
|
+
*/
|
|
61
121
|
getPagesWithTerm(langIndex: number, q: PageMapQueryPagesBelowPath): Promise<Pages>;
|
|
122
|
+
/**
|
|
123
|
+
* GetTermsForPageInTaxonomy - exact replica of Go's getTermsForPageInTaxonomy method
|
|
124
|
+
*/
|
|
62
125
|
getTermsForPageInTaxonomy(langIndex: number, base: string, taxonomy: string): Promise<Pages>;
|
|
126
|
+
/**
|
|
127
|
+
* GetSections - exact replica of Go's getSections method
|
|
128
|
+
*/
|
|
63
129
|
getSections(langIndex: number, prefix: string): Promise<Pages>;
|
|
130
|
+
/**
|
|
131
|
+
* Helper method to get directory from path
|
|
132
|
+
*/
|
|
64
133
|
private pathDir;
|
|
65
134
|
}
|
|
@@ -9,18 +9,70 @@ export declare class Source implements PageSource {
|
|
|
9
9
|
constructor(file: FileInfo);
|
|
10
10
|
sourceKey(): string;
|
|
11
11
|
contentSource(): Promise<Uint8Array>;
|
|
12
|
+
/**
|
|
13
|
+
* Read source all - exact replica of Go's readSourceAll method
|
|
14
|
+
*/
|
|
12
15
|
private readSourceAll;
|
|
16
|
+
/**
|
|
17
|
+
* Position offset - exact replica of Go's PosOffset method
|
|
18
|
+
*/
|
|
13
19
|
posOffset(offset: number): Promise<Position>;
|
|
20
|
+
/**
|
|
21
|
+
* Get identity - for PageIdentity interface
|
|
22
|
+
*/
|
|
14
23
|
pageIdentity(): Identity;
|
|
24
|
+
/**
|
|
25
|
+
* Get file - for FileProvider interface
|
|
26
|
+
*/
|
|
15
27
|
pageFile(): FileInfo;
|
|
28
|
+
/**
|
|
29
|
+
* Get stale versions - for Staler interface
|
|
30
|
+
*/
|
|
16
31
|
staleVersions(): number[];
|
|
32
|
+
/**
|
|
33
|
+
* Get section - for PageSource interface
|
|
34
|
+
*/
|
|
17
35
|
section(): string;
|
|
36
|
+
/**
|
|
37
|
+
* Get paths - for PageSource interface
|
|
38
|
+
*/
|
|
18
39
|
paths(): any;
|
|
40
|
+
/**
|
|
41
|
+
* Get path - for PageSource interface
|
|
42
|
+
*/
|
|
19
43
|
path(): string;
|
|
44
|
+
/**
|
|
45
|
+
* Get page slug for PageGraph (Quartz-compatible format)
|
|
46
|
+
* Slug format: "posts/my-post" (no leading slash, no extension)
|
|
47
|
+
*
|
|
48
|
+
* This is the same logic as in PageImpl.slug()
|
|
49
|
+
*/
|
|
20
50
|
slug(): string;
|
|
51
|
+
/**
|
|
52
|
+
* Convert path to slug (Quartz-compatible)
|
|
53
|
+
*
|
|
54
|
+
* Rules:
|
|
55
|
+
* 1. Remove leading slash
|
|
56
|
+
* 2. Remove file extension
|
|
57
|
+
* 3. Handle index files (index → parent folder)
|
|
58
|
+
* 4. Handle _index files (Hugo-style section index)
|
|
59
|
+
*/
|
|
21
60
|
private pathToSlug;
|
|
61
|
+
/**
|
|
62
|
+
* Get opener - for PageSource interface
|
|
63
|
+
*/
|
|
22
64
|
opener(): () => Promise<any>;
|
|
65
|
+
/**
|
|
66
|
+
* Open reader - simple implementation
|
|
67
|
+
*/
|
|
23
68
|
openReader(): any;
|
|
69
|
+
/**
|
|
70
|
+
* Content - simple implementation
|
|
71
|
+
*/
|
|
24
72
|
content(): Promise<Uint8Array>;
|
|
25
73
|
}
|
|
74
|
+
/**
|
|
75
|
+
* Factory function to create new page source
|
|
76
|
+
* Exact replica of Go's newPageSource function
|
|
77
|
+
*/
|
|
26
78
|
export declare function newPageSource(file: FileInfo): Source;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { Page, PageIdentity, PageSource } from '../type';
|
|
2
2
|
import { NodeShiftTree, TreeShiftTree, WalkableTrees, MutableTrees } from '@pkg/doctree';
|
|
3
|
+
/**
|
|
4
|
+
* OrdinalWeightPage - page with ordinal and weight
|
|
5
|
+
*/
|
|
3
6
|
declare class OrdinalWeightPage {
|
|
4
7
|
private ordinal;
|
|
5
8
|
private weight;
|
|
@@ -11,6 +14,9 @@ declare class OrdinalWeightPage {
|
|
|
11
14
|
name(): string;
|
|
12
15
|
title(): string;
|
|
13
16
|
}
|
|
17
|
+
/**
|
|
18
|
+
* WeightedTermTreeNode - tree node for weighted terms
|
|
19
|
+
*/
|
|
14
20
|
export declare class WeightedTermTreeNode {
|
|
15
21
|
private pageTreesNodeInstance;
|
|
16
22
|
term: OrdinalWeightPage;
|
|
@@ -21,6 +27,9 @@ export declare class WeightedTermTreeNode {
|
|
|
21
27
|
isEmpty(): boolean;
|
|
22
28
|
shift(languageIndex: number, exact: boolean): [PageTreesNode | null, boolean];
|
|
23
29
|
}
|
|
30
|
+
/**
|
|
31
|
+
* PageTreesNode - represents a node in the page tree
|
|
32
|
+
*/
|
|
24
33
|
export interface IPageTreesNode {
|
|
25
34
|
getPage(): [Page, boolean];
|
|
26
35
|
}
|
|
@@ -53,5 +62,8 @@ export declare class PageTrees {
|
|
|
53
62
|
get TreeTaxonomyEntries(): TreeShiftTree<WeightedTermTreeNode>;
|
|
54
63
|
get ResourceTrees(): MutableTrees;
|
|
55
64
|
}
|
|
65
|
+
/**
|
|
66
|
+
* Factory function to create new PageTreesNode
|
|
67
|
+
*/
|
|
56
68
|
export declare function newPageTreesNode(ps: PageSource): PageTreesNode;
|
|
57
69
|
export {};
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { Page, PageGroups, Pager, PagerManager, Pages } from "@internal/domain/content";
|
|
2
|
+
/**
|
|
3
|
+
* TypeScript implementation of Go's Paginator
|
|
4
|
+
*/
|
|
2
5
|
export declare class PaginatorImpl {
|
|
3
6
|
private paginatedElements;
|
|
4
7
|
private _pagers;
|
|
@@ -11,8 +14,14 @@ export declare class PaginatorImpl {
|
|
|
11
14
|
getElement(pageNumber: number): any[];
|
|
12
15
|
getBase(): string;
|
|
13
16
|
getPagers(): PagerImpl[];
|
|
17
|
+
/**
|
|
18
|
+
* Get all pages across all pagers - flattens all paginated elements
|
|
19
|
+
*/
|
|
14
20
|
getAllPages(): Pages;
|
|
15
21
|
}
|
|
22
|
+
/**
|
|
23
|
+
* TypeScript implementation of Go's Pager - implements the existing Pager interface
|
|
24
|
+
*/
|
|
16
25
|
declare class PagerImpl implements Pager {
|
|
17
26
|
private number;
|
|
18
27
|
private paginator;
|
|
@@ -32,10 +41,16 @@ declare class PagerImpl implements Pager {
|
|
|
32
41
|
private element;
|
|
33
42
|
private pathJoin;
|
|
34
43
|
}
|
|
44
|
+
/**
|
|
45
|
+
* PagerManager service interface
|
|
46
|
+
*/
|
|
35
47
|
export interface PagerSvc {
|
|
36
48
|
pageSize(): number;
|
|
37
49
|
globalRegularPages(): Promise<any[]>;
|
|
38
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* TypeScript implementation of Go's Paginator entity - implements existing PagerManager interface
|
|
53
|
+
*/
|
|
39
54
|
export declare class PaginatorManagerImpl implements PagerManager {
|
|
40
55
|
private currentPager;
|
|
41
56
|
private initialized;
|
|
@@ -47,6 +62,10 @@ export declare class PaginatorManagerImpl implements PagerManager {
|
|
|
47
62
|
paginate(groups: PageGroups): Promise<Pager>;
|
|
48
63
|
paginate(pages: Pages): Promise<Pager>;
|
|
49
64
|
paginator(): Promise<Pager>;
|
|
65
|
+
/**
|
|
66
|
+
* Initialize paginator - TypeScript equivalent of golang's init.Do()
|
|
67
|
+
* This matches the exact logic from golang's Paginator.Paginator() method
|
|
68
|
+
*/
|
|
50
69
|
private initializePaginator;
|
|
51
70
|
private newPaginatorFromPages;
|
|
52
71
|
private newPaginatorFromPageGroups;
|
|
@@ -2,14 +2,29 @@ import { FsService, Page } from '../type';
|
|
|
2
2
|
import { PageTreesNode } from './pagetrees';
|
|
3
3
|
import { PageBuilder } from './pagebuilder';
|
|
4
4
|
import { NodeShiftTree } from '@pkg/doctree';
|
|
5
|
+
/**
|
|
6
|
+
* Constants - exact replica of Go's constants
|
|
7
|
+
*/
|
|
5
8
|
export declare const PAGE_HOME_BASE = "/";
|
|
9
|
+
/**
|
|
10
|
+
* Section class - exact replica of Go's Section struct
|
|
11
|
+
*/
|
|
6
12
|
export declare class Section {
|
|
7
13
|
home: Page | null;
|
|
8
14
|
seen: Record<string, boolean>;
|
|
9
15
|
fsSvc: FsService;
|
|
10
16
|
constructor(fsSvc: FsService);
|
|
17
|
+
/**
|
|
18
|
+
* IsHome - exact replica of Go's isHome method
|
|
19
|
+
*/
|
|
11
20
|
isHome(key: string): boolean;
|
|
21
|
+
/**
|
|
22
|
+
* IsSectionExist - exact replica of Go's isSectionExist method
|
|
23
|
+
*/
|
|
12
24
|
isSectionExist(section: string): boolean;
|
|
13
25
|
assemble(pages: NodeShiftTree<PageTreesNode>, pb: PageBuilder, langIdx: number): Promise<void>;
|
|
26
|
+
/**
|
|
27
|
+
* CreateHome - exact replica of Go's CreateHome method
|
|
28
|
+
*/
|
|
14
29
|
createHome(pb: PageBuilder): Promise<void>;
|
|
15
30
|
}
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { Page, Position } from '../type';
|
|
2
2
|
import { Scratch } from '@pkg/maps/scratch';
|
|
3
|
+
/**
|
|
4
|
+
* ShortcodeWithPage is the "." context in a shortcode template.
|
|
5
|
+
*/
|
|
3
6
|
export declare class ShortcodeWithPage {
|
|
4
7
|
private _params;
|
|
5
8
|
private _inner;
|
|
@@ -14,23 +17,59 @@ export declare class ShortcodeWithPage {
|
|
|
14
17
|
private _pos;
|
|
15
18
|
private _scratch;
|
|
16
19
|
constructor(params: any, inner: string, page: Page, parent: ShortcodeWithPage | null, name: string, isNamedParams: boolean, ordinal: number, indentation?: string, posOffset?: number);
|
|
20
|
+
/**
|
|
21
|
+
* Get shortcode parameters
|
|
22
|
+
*/
|
|
17
23
|
get params(): any;
|
|
18
24
|
get Params(): any;
|
|
19
25
|
get IsNamedParams(): boolean;
|
|
26
|
+
/**
|
|
27
|
+
* Get inner content
|
|
28
|
+
*/
|
|
20
29
|
get inner(): string;
|
|
21
30
|
get Inner(): string;
|
|
31
|
+
/**
|
|
32
|
+
* Get parent page
|
|
33
|
+
*/
|
|
22
34
|
get page(): Page;
|
|
23
35
|
get Page(): Page;
|
|
36
|
+
/**
|
|
37
|
+
* Get parent shortcode if any
|
|
38
|
+
*/
|
|
24
39
|
get parent(): ShortcodeWithPage | null;
|
|
25
40
|
get Parent(): ShortcodeWithPage | null;
|
|
41
|
+
/**
|
|
42
|
+
* Get shortcode name
|
|
43
|
+
*/
|
|
26
44
|
get name(): string;
|
|
45
|
+
/**
|
|
46
|
+
* Check if using named parameters
|
|
47
|
+
*/
|
|
27
48
|
get isNamedParams(): boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Get ordinal position
|
|
51
|
+
*/
|
|
28
52
|
get ordinal(): number;
|
|
29
53
|
get Ordinal(): number;
|
|
54
|
+
/**
|
|
55
|
+
* Returns the (potentially de-indented) inner content of the shortcode
|
|
56
|
+
*/
|
|
30
57
|
innerDeindent(): string;
|
|
31
58
|
get InnerDeindent(): string;
|
|
59
|
+
/**
|
|
60
|
+
* Position returns this shortcode's detailed position.
|
|
61
|
+
* Note that this information may be expensive to calculate,
|
|
62
|
+
* so only use this in error situations.
|
|
63
|
+
*/
|
|
32
64
|
position(): Promise<Position>;
|
|
65
|
+
/**
|
|
66
|
+
* Scratch returns a scratch-pad scoped for this shortcode.
|
|
67
|
+
* This can be used as a temporary storage for variables, counters etc.
|
|
68
|
+
*/
|
|
33
69
|
scratch(): Scratch;
|
|
70
|
+
/**
|
|
71
|
+
* Get is a convenience method to look up shortcode parameters by its key
|
|
72
|
+
*/
|
|
34
73
|
get(key: string | number): any;
|
|
35
74
|
Get(key: string | number): any;
|
|
36
75
|
}
|
|
@@ -2,11 +2,20 @@ import { FsService } from '../type';
|
|
|
2
2
|
import { PageTreesNode } from './pagetrees';
|
|
3
3
|
import { PageBuilder } from './pagebuilder';
|
|
4
4
|
import { NodeShiftTree } from '@pkg/doctree';
|
|
5
|
+
/**
|
|
6
|
+
* Constants - exact replica of Go's constants
|
|
7
|
+
*/
|
|
5
8
|
export declare const STANDALONE_PAGE_404_BASE = "404";
|
|
6
9
|
export declare const STANDALONE_PAGE_SITEMAP_BASE = "_sitemap";
|
|
10
|
+
/**
|
|
11
|
+
* Standalone class - exact replica of Go's Standalone struct
|
|
12
|
+
*/
|
|
7
13
|
export declare class Standalone {
|
|
8
14
|
fsSvc: FsService;
|
|
9
15
|
constructor(fsSvc: FsService);
|
|
16
|
+
/**
|
|
17
|
+
* Assemble - exact replica of Go's Assemble method
|
|
18
|
+
*/
|
|
10
19
|
assemble(pages: NodeShiftTree<PageTreesNode>, pb: PageBuilder): Promise<void>;
|
|
11
20
|
private addStandalone;
|
|
12
21
|
}
|
|
@@ -6,9 +6,24 @@ export declare class Taxonomy {
|
|
|
6
6
|
views: ITaxonomy[];
|
|
7
7
|
fsSvc: FsService;
|
|
8
8
|
constructor(views: ITaxonomy[], fsSvc: FsService);
|
|
9
|
+
/**
|
|
10
|
+
* Assemble - exact replica of Go's Assemble method
|
|
11
|
+
*/
|
|
9
12
|
assemble(pages: NodeShiftTree<PageTreesNode>, pb: PageBuilder, langIdx: number): Promise<void>;
|
|
13
|
+
/**
|
|
14
|
+
* IsTaxonomyPath - exact replica of Go's IsTaxonomyPath method
|
|
15
|
+
*/
|
|
10
16
|
isTaxonomyPath(p: string): boolean;
|
|
17
|
+
/**
|
|
18
|
+
* PluralTreeKey - exact replica of Go's PluralTreeKey method
|
|
19
|
+
*/
|
|
11
20
|
pluralTreeKey(plural: string): string;
|
|
21
|
+
/**
|
|
22
|
+
* GetTaxonomy - exact replica of Go's getTaxonomy method
|
|
23
|
+
*/
|
|
12
24
|
getTaxonomy(s: string): ITaxonomy | null;
|
|
25
|
+
/**
|
|
26
|
+
* IsZero - exact replica of Go's IsZero method
|
|
27
|
+
*/
|
|
13
28
|
isZero(v: ITaxonomy | null): boolean;
|
|
14
29
|
}
|