@jini-ai/devops 0.7.3-next.2 → 0.7.3-next.3
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/README.md +16 -0
- package/dist/backup/site/archive-extensions.d.ts +73 -0
- package/dist/backup/site/archive-extensions.js +129 -0
- package/dist/backup/site/archive-manifest.d.ts +85 -0
- package/dist/backup/site/archive-manifest.js +176 -0
- package/dist/backup/site/archive-media.d.ts +121 -0
- package/dist/backup/site/archive-media.js +93 -0
- package/dist/backup/site/backup-service.credentials.d.ts +31 -0
- package/dist/backup/site/backup-service.credentials.js +161 -0
- package/dist/backup/site/backup-service.d.ts +331 -0
- package/dist/backup/site/backup-service.js +125 -0
- package/dist/backup/site/backup-service.plan.d.ts +64 -0
- package/dist/backup/site/backup-service.plan.js +207 -0
- package/dist/backup/site/backup-service.push.d.ts +29 -0
- package/dist/backup/site/backup-service.push.js +82 -0
- package/dist/backup/site/backup-service.shared.d.ts +40 -0
- package/dist/backup/site/backup-service.shared.js +37 -0
- package/dist/backup/site/bundled-export-file-policy.d.ts +38 -0
- package/dist/backup/site/bundled-export-file-policy.js +40 -0
- package/dist/backup/site/credential-warnings.d.ts +41 -0
- package/dist/backup/site/credential-warnings.js +50 -0
- package/dist/backup/site/import-backend-steps.d.ts +167 -0
- package/dist/backup/site/import-backend-steps.js +170 -0
- package/dist/backup/site/import-backend.d.ts +167 -0
- package/dist/backup/site/import-backend.js +298 -0
- package/dist/backup/site/import-database.d.ts +118 -0
- package/dist/backup/site/import-database.js +167 -0
- package/dist/backup/site/import-index/admission.d.ts +54 -0
- package/dist/backup/site/import-index/admission.js +46 -0
- package/dist/backup/site/import-index/backfill.d.ts +106 -0
- package/dist/backup/site/import-index/backfill.js +137 -0
- package/dist/backup/site/import-index/errors.d.ts +28 -0
- package/dist/backup/site/import-index/errors.js +38 -0
- package/dist/backup/site/import-index/migrations/checksums.d.ts +4 -0
- package/dist/backup/site/import-index/migrations/checksums.js +4 -0
- package/dist/backup/site/import-index/migrations/site-imports-v1.d.ts +2 -0
- package/dist/backup/site/import-index/migrations/site-imports-v1.js +10 -0
- package/dist/backup/site/import-index/mode.d.ts +191 -0
- package/dist/backup/site/import-index/mode.js +272 -0
- package/dist/backup/site/import-index/open.d.ts +40 -0
- package/dist/backup/site/import-index/open.js +87 -0
- package/dist/backup/site/import-index/paging.d.ts +28 -0
- package/dist/backup/site/import-index/paging.js +66 -0
- package/dist/backup/site/import-index/payload-namespace.d.ts +80 -0
- package/dist/backup/site/import-index/payload-namespace.js +156 -0
- package/dist/backup/site/import-index/rows.d.ts +32 -0
- package/dist/backup/site/import-index/rows.js +61 -0
- package/dist/backup/site/import-index/schema.d.ts +8 -0
- package/dist/backup/site/import-index/schema.js +31 -0
- package/dist/backup/site/import-index/store.d.ts +27 -0
- package/dist/backup/site/import-index/store.js +33 -0
- package/dist/backup/site/import-index/sweep.d.ts +10 -0
- package/dist/backup/site/import-index/sweep.js +26 -0
- package/dist/backup/site/import-keep-off.d.ts +128 -0
- package/dist/backup/site/import-keep-off.js +204 -0
- package/dist/backup/site/import-plugin-state.d.ts +74 -0
- package/dist/backup/site/import-plugin-state.js +67 -0
- package/dist/backup/site/import-registry.d.ts +110 -0
- package/dist/backup/site/import-registry.js +205 -0
- package/dist/backup/site/import-restore-placement.d.ts +94 -0
- package/dist/backup/site/import-restore-placement.js +158 -0
- package/dist/backup/site/import-restore.d.ts +111 -0
- package/dist/backup/site/import-restore.js +120 -0
- package/dist/backup/site/import-verifier-inventory.d.ts +137 -0
- package/dist/backup/site/import-verifier-inventory.js +236 -0
- package/dist/backup/site/import-verifier-projection.d.ts +78 -0
- package/dist/backup/site/import-verifier-projection.js +100 -0
- package/dist/backup/site/import-verifier.d.ts +126 -0
- package/dist/backup/site/import-verifier.js +53 -0
- package/dist/backup/site/owned-temp-root.d.ts +12 -0
- package/dist/backup/site/owned-temp-root.js +2 -0
- package/dist/backup/site/package-file-inventory.d.ts +63 -0
- package/dist/backup/site/package-file-inventory.js +56 -0
- package/dist/backup/site/push-content.d.ts +70 -0
- package/dist/backup/site/push-content.js +56 -0
- package/dist/backup/site/react/ShowMoreImports.d.ts +21 -0
- package/dist/backup/site/react/ShowMoreImports.js +8 -0
- package/dist/backup/site/saved-keys-port.d.ts +47 -0
- package/dist/backup/site/saved-keys-port.js +3 -0
- package/dist/backup/site/saved-keys.d.ts +25 -0
- package/dist/backup/site/saved-keys.js +38 -0
- package/dist/backup/site/share-backend.d.ts +243 -0
- package/dist/backup/site/share-backend.js +284 -0
- package/dist/backup/site/share-database/projection.d.ts +195 -0
- package/dist/backup/site/share-database/projection.js +90 -0
- package/dist/backup/site/share-database/projection.media.d.ts +38 -0
- package/dist/backup/site/share-database/projection.media.js +179 -0
- package/dist/backup/site/share-database/projection.tables.d.ts +46 -0
- package/dist/backup/site/share-database/projection.tables.js +193 -0
- package/dist/backup/site/share-expiry.d.ts +75 -0
- package/dist/backup/site/share-expiry.js +49 -0
- package/dist/backup/site/share-export-failure.d.ts +17 -0
- package/dist/backup/site/share-export-failure.js +16 -0
- package/dist/backup/site/share-file-policy.d.ts +60 -0
- package/dist/backup/site/share-file-policy.js +146 -0
- package/dist/backup/site/share-hosting.d.ts +107 -0
- package/dist/backup/site/share-hosting.js +148 -0
- package/dist/backup/site/share-preparation-steps.d.ts +180 -0
- package/dist/backup/site/share-preparation-steps.js +109 -0
- package/dist/backup/site/share-preparation.d.ts +122 -0
- package/dist/backup/site/share-preparation.js +43 -0
- package/dist/backup/site/share-refusal.d.ts +21 -0
- package/dist/backup/site/share-refusal.js +20 -0
- package/dist/backup/site/share-registry.d.ts +124 -0
- package/dist/backup/site/share-registry.js +219 -0
- package/dist/backup/site/share-retention.d.ts +62 -0
- package/dist/backup/site/share-retention.js +126 -0
- package/dist/backup/site/share-service.d.ts +128 -0
- package/dist/backup/site/share-service.js +194 -0
- package/dist/backup/site/share-zip.d.ts +115 -0
- package/dist/backup/site/share-zip.js +144 -0
- package/dist/backup/site/sources.d.ts +344 -0
- package/dist/backup/site/sources.js +595 -0
- package/dist/backup/site/static-copy.d.ts +122 -0
- package/dist/backup/site/static-copy.js +165 -0
- package/dist/backup/site/static-download-html.d.ts +76 -0
- package/dist/backup/site/static-download-html.js +149 -0
- package/dist/backup/site/static-download-landing.d.ts +52 -0
- package/dist/backup/site/static-download-landing.js +95 -0
- package/dist/backup/site/static-download-layout.d.ts +96 -0
- package/dist/backup/site/static-download-layout.js +325 -0
- package/dist/backup/site/static-export-selection.d.ts +50 -0
- package/dist/backup/site/static-export-selection.js +76 -0
- package/dist/backup/site/static-site-packager.d.ts +42 -0
- package/dist/backup/site/static-site-packager.js +32 -0
- package/dist/backup/site/tool-registrations.d.ts +74 -0
- package/dist/backup/site/tool-registrations.js +201 -0
- package/dist/checks/complexity-debt.d.ts +100 -0
- package/dist/checks/complexity-debt.js +131 -0
- package/dist/checks/coverage/diff.js +5 -1
- package/dist/checks/env-access.d.ts +14 -1
- package/dist/checks/env-access.js +92 -6
- package/dist/checks/live-verify-checks.d.ts +29 -0
- package/dist/checks/live-verify-checks.js +30 -0
- package/dist/checks/quality-gates.d.ts +137 -0
- package/dist/checks/quality-gates.js +209 -0
- package/dist/core/deploy-types.d.ts +2 -0
- package/dist/deploy/admin-http/site-update-status.d.ts +8 -0
- package/dist/deploy/admin-http/site-update-status.js +15 -0
- package/dist/deploy/host-kit.d.ts +3 -0
- package/dist/deploy/index.d.ts +6 -0
- package/dist/deploy/index.js +6 -0
- package/dist/deploy/ops-runner.js +7 -0
- package/dist/deploy/ops-tool-contracts.d.ts +10 -1
- package/dist/deploy/react/Deployment.d.ts +37 -0
- package/dist/deploy/react/Deployment.js +94 -0
- package/dist/deploy/react/DockerfileTab.d.ts +72 -0
- package/dist/deploy/react/DockerfileTab.js +131 -0
- package/dist/deploy/react/HistoryTab.d.ts +43 -0
- package/dist/deploy/react/HistoryTab.js +12 -0
- package/dist/deploy/react/OverviewTab.d.ts +60 -0
- package/dist/deploy/react/OverviewTab.js +75 -0
- package/dist/deploy/react/PublishRunResult.d.ts +5 -1
- package/dist/deploy/react/PublishRunResult.js +4 -4
- package/dist/deploy/react/SiteUpdateNotice.d.ts +22 -0
- package/dist/deploy/react/SiteUpdateNotice.js +25 -0
- package/dist/deploy/react/StaticCredentialFields.d.ts +36 -0
- package/dist/deploy/react/StaticCredentialFields.js +63 -0
- package/dist/deploy/react/StaticCredentialSteps.d.ts +23 -0
- package/dist/deploy/react/StaticCredentialSteps.js +155 -0
- package/dist/deploy/react/StaticExportCard.d.ts +11 -0
- package/dist/deploy/react/StaticExportCard.js +97 -0
- package/dist/deploy/react/StaticPublishCredentials.d.ts +50 -0
- package/dist/deploy/react/StaticPublishCredentials.js +77 -0
- package/dist/deploy/react/StaticPublishForm.d.ts +12 -0
- package/dist/deploy/react/StaticPublishForm.js +91 -0
- package/dist/deploy/react/StaticSiteTab.d.ts +207 -0
- package/dist/deploy/react/StaticSiteTab.js +117 -0
- package/dist/deploy/react/deployment-visuals.d.ts +207 -0
- package/dist/deploy/react/deployment-visuals.js +101 -0
- package/dist/deploy/react/download-dockerfile.d.ts +14 -0
- package/dist/deploy/react/download-dockerfile.js +15 -0
- package/dist/deploy/react/hooks/publish-credential-draft.d.ts +33 -0
- package/dist/deploy/react/hooks/publish-credential-draft.js +54 -0
- package/dist/deploy/react/hooks/publish-credential-selection.d.ts +13 -0
- package/dist/deploy/react/hooks/publish-credential-selection.js +34 -0
- package/dist/deploy/react/hooks/publish-credential-writes.d.ts +20 -0
- package/dist/deploy/react/hooks/publish-credential-writes.js +99 -0
- package/dist/deploy/react/hooks/static-publish-actions.d.ts +10 -0
- package/dist/deploy/react/hooks/static-publish-actions.js +62 -0
- package/dist/deploy/react/hooks/static-publish-form.hooks.d.ts +38 -0
- package/dist/deploy/react/hooks/static-publish-form.hooks.js +103 -0
- package/dist/deploy/react/hooks/static-publish-run.hooks.d.ts +28 -0
- package/dist/deploy/react/hooks/static-publish-run.hooks.js +92 -0
- package/dist/deploy/react/hooks/use-dockerfile-source.hooks.d.ts +148 -0
- package/dist/deploy/react/hooks/use-dockerfile-source.hooks.js +155 -0
- package/dist/deploy/react/hooks/use-publish-credentials.hooks.d.ts +268 -0
- package/dist/deploy/react/hooks/use-publish-credentials.hooks.js +52 -0
- package/dist/deploy/react/hooks/use-static-export.hooks.d.ts +128 -0
- package/dist/deploy/react/hooks/use-static-export.hooks.js +159 -0
- package/dist/deploy/react/hooks/use-static-publish.hooks.d.ts +208 -0
- package/dist/deploy/react/hooks/use-static-publish.hooks.js +48 -0
- package/dist/deploy/react/index.d.ts +4 -0
- package/dist/deploy/react/index.js +2 -0
- package/dist/deploy/react/rules.d.ts +363 -0
- package/dist/deploy/react/rules.js +314 -0
- package/dist/deploy/react/use-deployment-overview.hooks.d.ts +41 -0
- package/dist/deploy/react/use-deployment-overview.hooks.js +11 -0
- package/dist/deploy/site/agent-tools.d.ts +42 -0
- package/dist/deploy/site/agent-tools.js +119 -0
- package/dist/deploy/site/deploy-config-registry.d.ts +155 -0
- package/dist/deploy/site/deploy-config-registry.js +124 -0
- package/dist/deploy/site/deploy-config.d.ts +97 -0
- package/dist/deploy/site/deploy-config.js +115 -0
- package/dist/deploy/site/deploy-ops/agent-tools.d.ts +22 -0
- package/dist/deploy/site/deploy-ops/agent-tools.js +76 -0
- package/dist/deploy/site/deploy-ops/registry.d.ts +134 -0
- package/dist/deploy/site/deploy-ops/registry.js +106 -0
- package/dist/deploy/site/deploy-ops/run-ops.d.ts +66 -0
- package/dist/deploy/site/deploy-ops/run-ops.js +34 -0
- package/dist/deploy/site/deploy-ops/secret-confirm.d.ts +36 -0
- package/dist/deploy/site/deploy-ops/secret-confirm.js +27 -0
- package/dist/deploy/site/deploy-targets/host-kit.d.ts +28 -0
- package/dist/deploy/site/deploy-targets/host-kit.js +120 -0
- package/dist/deploy/site/deploy-targets/registry.d.ts +157 -0
- package/dist/deploy/site/deploy-targets/registry.js +132 -0
- package/dist/deploy/site/deploy-targets/types.d.ts +27 -0
- package/dist/deploy/site/deploy-targets/types.js +2 -0
- package/dist/deploy/site/dockerfile.d.ts +137 -0
- package/dist/deploy/site/dockerfile.js +101 -0
- package/dist/deploy/site/export-run.d.ts +137 -0
- package/dist/deploy/site/export-run.js +152 -0
- package/dist/deploy/site/ports.d.ts +115 -0
- package/dist/deploy/site/ports.js +2 -0
- package/dist/deploy/site/publish-agent-tools.d.ts +18 -0
- package/dist/deploy/site/publish-agent-tools.js +120 -0
- package/dist/deploy/site/publish-candidate.d.ts +26 -0
- package/dist/deploy/site/publish-candidate.js +37 -0
- package/dist/deploy/site/publish-credentials/account-label-heal-scheduler.d.ts +78 -0
- package/dist/deploy/site/publish-credentials/account-label-heal-scheduler.js +88 -0
- package/dist/deploy/site/publish-credentials/compatibility-port.d.ts +38 -0
- package/dist/deploy/site/publish-credentials/compatibility-port.js +19 -0
- package/dist/deploy/site/publish-credentials/execution-mode.d.ts +43 -0
- package/dist/deploy/site/publish-credentials/execution-mode.js +19 -0
- package/dist/deploy/site/publish-credentials/store-owner.d.ts +11 -0
- package/dist/deploy/site/publish-credentials/store-owner.js +9 -0
- package/dist/deploy/site/publish-credentials/store-resolution.d.ts +55 -0
- package/dist/deploy/site/publish-credentials/store-resolution.js +100 -0
- package/dist/deploy/site/publish-credentials/store-validation.d.ts +68 -0
- package/dist/deploy/site/publish-credentials/store-validation.js +182 -0
- package/dist/deploy/site/publish-credentials/store.d.ts +322 -0
- package/dist/deploy/site/publish-credentials/store.js +372 -0
- package/dist/deploy/site/publish-credentials/types.d.ts +85 -0
- package/dist/deploy/site/publish-credentials/types.js +2 -0
- package/dist/deploy/site/publish-tool-capabilities.d.ts +123 -0
- package/dist/deploy/site/publish-tool-capabilities.js +175 -0
- package/dist/deploy/site/publish-tool-credential.d.ts +48 -0
- package/dist/deploy/site/publish-tool-credential.js +284 -0
- package/dist/deploy/site/publish-tool-deps.d.ts +205 -0
- package/dist/deploy/site/publish-tool-deps.js +15 -0
- package/dist/deploy/site/publish-tool-execution.d.ts +78 -0
- package/dist/deploy/site/publish-tool-execution.js +313 -0
- package/dist/deploy/site/publish-tool-schema.d.ts +29 -0
- package/dist/deploy/site/publish-tool-schema.js +38 -0
- package/dist/deploy/site/static-publish/adapter-export.d.ts +54 -0
- package/dist/deploy/site/static-publish/adapter-export.js +89 -0
- package/dist/deploy/site/static-publish/adapter-plan.d.ts +99 -0
- package/dist/deploy/site/static-publish/adapter-plan.js +112 -0
- package/dist/deploy/site/static-publish/adapter.d.ts +182 -0
- package/dist/deploy/site/static-publish/adapter.js +321 -0
- package/dist/deploy/site/static-publish/admin-publish-read.d.ts +209 -0
- package/dist/deploy/site/static-publish/admin-publish-read.js +116 -0
- package/dist/deploy/site/static-publish/credentials.d.ts +110 -0
- package/dist/deploy/site/static-publish/credentials.js +290 -0
- package/dist/deploy/site/static-publish/domain-publish-rows.d.ts +25 -0
- package/dist/deploy/site/static-publish/domain-publish-rows.js +43 -0
- package/dist/deploy/site/static-publish/domain-publish-tool.d.ts +19 -0
- package/dist/deploy/site/static-publish/domain-publish-tool.js +111 -0
- package/dist/deploy/site/static-publish/inspection.d.ts +24 -0
- package/dist/deploy/site/static-publish/inspection.js +69 -0
- package/dist/deploy/site/static-publish/publish-history.d.ts +197 -0
- package/dist/deploy/site/static-publish/publish-history.js +153 -0
- package/dist/deploy/site/static-publish/publish-run.d.ts +156 -0
- package/dist/deploy/site/static-publish/publish-run.js +186 -0
- package/dist/deploy/site/static-publish/types.d.ts +165 -0
- package/dist/deploy/site/static-publish/types.js +2 -0
- package/dist/deploy/site/static-publish/verify.d.ts +217 -0
- package/dist/deploy/site/static-publish/verify.js +248 -0
- package/dist/deploy/site/tool-registrations.d.ts +97 -0
- package/dist/deploy/site/tool-registrations.js +130 -0
- package/dist/deploy/site/types.d.ts +51 -0
- package/dist/deploy/site/types.js +2 -0
- package/dist/deploy/site-update/check-for-update.d.ts +19 -0
- package/dist/deploy/site-update/check-for-update.js +19 -0
- package/dist/deploy/site-update/contracts.d.ts +161 -0
- package/dist/deploy/site-update/contracts.js +94 -0
- package/dist/deploy/site-update/desktop-site-update.d.ts +66 -0
- package/dist/deploy/site-update/desktop-site-update.js +43 -0
- package/dist/deploy/site-update/fake-site-update.d.ts +39 -0
- package/dist/deploy/site-update/fake-site-update.js +52 -0
- package/dist/deploy/site-update/run-site-update.d.ts +121 -0
- package/dist/deploy/site-update/run-site-update.js +219 -0
- package/dist/deploy/site-update/self-hosted-site-update.d.ts +71 -0
- package/dist/deploy/site-update/self-hosted-site-update.js +79 -0
- package/dist/deploy/target-contracts.d.ts +3 -0
- package/dist/deploy/tool.d.ts +5 -8
- package/dist/deploy/tool.js +6 -9
- package/dist/dns/binding-sweeper.d.ts +72 -0
- package/dist/dns/binding-sweeper.js +53 -0
- package/dist/dns/index.d.ts +1 -0
- package/dist/dns/index.js +1 -0
- package/dist/dns/site/binding.repo.d.ts +71 -0
- package/dist/dns/site/binding.repo.js +45 -0
- package/dist/dns/site/dns-changes.d.ts +90 -0
- package/dist/dns/site/dns-changes.js +271 -0
- package/dist/dns/site/dns-tools.d.ts +46 -0
- package/dist/dns/site/dns-tools.js +204 -0
- package/dist/dns/site/mail-dns-status.d.ts +111 -0
- package/dist/dns/site/mail-dns-status.js +190 -0
- package/dist/dns/site/mail-dns-tools.d.ts +33 -0
- package/dist/dns/site/mail-dns-tools.js +62 -0
- package/dist/dns/site/mail-requirements.d.ts +30 -0
- package/dist/dns/site/mail-requirements.js +78 -0
- package/dist/dns/site/tool-deps.d.ts +21 -0
- package/dist/dns/site/tool-deps.js +2 -0
- package/dist/dns/site/tools.d.ts +74 -0
- package/dist/dns/site/tools.js +124 -0
- package/dist/local-dev/bind-host.d.ts +80 -0
- package/dist/local-dev/bind-host.js +90 -0
- package/dist/local-dev/dev-proxy-upstream.d.ts +69 -0
- package/dist/local-dev/dev-proxy-upstream.js +63 -0
- package/dist/local-dev/index.d.ts +28 -0
- package/dist/local-dev/index.js +25 -0
- package/dist/packaging/electron/archive.d.ts +2 -9
- package/dist/packaging/electron/asar-adapter.d.ts +2 -1
- package/dist/packaging/electron/entry.d.ts +2 -0
- package/dist/packaging/electron/move-to-applications.d.ts +165 -0
- package/dist/packaging/electron/move-to-applications.js +162 -0
- package/dist/packaging/electron/policies.d.ts +33 -4
- package/dist/packaging/electron/policies.js +29 -10
- package/dist/packaging/electron/ports.d.ts +1 -6
- package/dist/packaging/electron/staging.d.ts +11 -2
- package/dist/packaging/electron/staging.js +15 -5
- package/dist/react/site-share-expiry/ShareExpiryControls.d.ts +29 -0
- package/dist/react/site-share-expiry/ShareExpiryControls.js +7 -0
- package/dist/react/site-share-expiry/index.d.ts +2 -0
- package/dist/react/site-share-expiry/index.js +2 -0
- package/dist/source-control/react/ProvidersTab.d.ts +98 -0
- package/dist/source-control/react/ProvidersTab.js +195 -0
- package/dist/source-control/react/SourceControl.d.ts +51 -0
- package/dist/source-control/react/SourceControl.js +61 -0
- package/dist/source-control/react/hooks/use-source-control-credentials.hooks.d.ts +128 -0
- package/dist/source-control/react/hooks/use-source-control-credentials.hooks.js +102 -0
- package/dist/source-control/react/rules.d.ts +167 -0
- package/dist/source-control/react/rules.js +125 -0
- package/dist/source-control/react/source-control-visuals.d.ts +75 -0
- package/dist/source-control/react/source-control-visuals.js +48 -0
- package/dist/source-control/site/agent-tools.d.ts +5 -0
- package/dist/source-control/site/agent-tools.js +30 -0
- package/dist/source-control/site/bundled-provider-registry.d.ts +33 -0
- package/dist/source-control/site/bundled-provider-registry.js +37 -0
- package/dist/source-control/site/commit-schema.d.ts +40 -0
- package/dist/source-control/site/commit-schema.js +29 -0
- package/dist/source-control/site/commit-target.d.ts +26 -0
- package/dist/source-control/site/commit-target.js +58 -0
- package/dist/source-control/site/credential-form.d.ts +36 -0
- package/dist/source-control/site/credential-form.js +102 -0
- package/dist/source-control/site/credential-setup.d.ts +107 -0
- package/dist/source-control/site/credential-setup.js +216 -0
- package/dist/source-control/site/provider-kit.d.ts +37 -0
- package/dist/source-control/site/provider-kit.js +35 -0
- package/dist/source-control/site/provider-module.d.ts +251 -0
- package/dist/source-control/site/provider-module.js +2 -0
- package/dist/source-control/site/saved-key-bindings.d.ts +4 -0
- package/dist/source-control/site/saved-key-bindings.js +4 -0
- package/dist/source-control/site/static-site-packager-port.d.ts +37 -0
- package/dist/source-control/site/static-site-packager-port.js +2 -0
- package/dist/source-control/site/store.d.ts +209 -0
- package/dist/source-control/site/store.js +374 -0
- package/dist/source-control/site/store.validation.d.ts +72 -0
- package/dist/source-control/site/store.validation.js +168 -0
- package/dist/source-control/site/tool-registrations.d.ts +190 -0
- package/dist/source-control/site/tool-registrations.js +379 -0
- package/dist/static-export/site/export-preflight.d.ts +48 -0
- package/dist/static-export/site/export-preflight.js +82 -0
- package/dist/static-export/site/media-original-urls.d.ts +57 -0
- package/dist/static-export/site/media-original-urls.js +109 -0
- package/dist/static-export/site/ports.d.ts +82 -0
- package/dist/static-export/site/ports.js +29 -0
- package/dist/static-export/site/public-origin-policy.d.ts +32 -0
- package/dist/static-export/site/public-origin-policy.js +68 -0
- package/dist/static-export/site/route-manifest.d.ts +65 -0
- package/dist/static-export/site/route-manifest.js +139 -0
- package/dist/static-export/site/site-exporter.d.ts +158 -0
- package/dist/static-export/site/site-exporter.js +112 -0
- package/dist/static-export/site/static-security-headers.d.ts +39 -0
- package/dist/static-export/site/static-security-headers.js +43 -0
- package/dist/static-export/site/theme-preview-manifest.d.ts +35 -0
- package/dist/static-export/site/theme-preview-manifest.js +28 -0
- package/package.json +911 -7
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { escapeHtml } from "@jini-ai/core/text";
|
|
2
|
+
const TITLE_LIMIT = 120;
|
|
3
|
+
/** The page's own <title>, decoded to plain text; falls back to its path label. */
|
|
4
|
+
function pageTitle({ html, label, extractPlainText }, _options = {}) {
|
|
5
|
+
// Comments first: a theme template comment may mention a <title> tag (the privacy template does).
|
|
6
|
+
const raw = /<title\b[^>]*>([\s\S]*?)<\/title>/i.exec(html.replace(/<!--[\s\S]*?-->/g, ""))?.[1] ?? "";
|
|
7
|
+
const text = extractPlainText({ html: raw }).replace(/\s+/g, " ").trim();
|
|
8
|
+
if (!text)
|
|
9
|
+
return label;
|
|
10
|
+
return text.length > TITLE_LIMIT ? text.slice(0, TITLE_LIMIT - 1) + "…" : text;
|
|
11
|
+
}
|
|
12
|
+
/** "sites/x/about/index.html" → "/about/"; a theme's home is "/". */
|
|
13
|
+
function pageLabel({ file, folder }, _options = {}) {
|
|
14
|
+
const relative = file.slice(`sites/${folder}/`.length);
|
|
15
|
+
return "/" + relative.replace(/(?:^|\/)index\.html$/i, match => (match.startsWith("/") ? "/" : ""));
|
|
16
|
+
}
|
|
17
|
+
/** Relative hrefs survive spaces, `#` and `?` in delivered names; folders stay plain segments. */
|
|
18
|
+
function relativeHref({ file }, _options = {}) {
|
|
19
|
+
return file.split("/").map(segment => encodeURIComponent(segment)).join("/");
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The delivered pages of one theme, home first, then by path. Skips the error page and redirect stubs.
|
|
23
|
+
* @complexity O(pages log pages + page bytes scanned for <title>), no effects.
|
|
24
|
+
*/
|
|
25
|
+
export function landingPages({ files, folder, skip, extractPlainText }, _options = {}) {
|
|
26
|
+
const root = `sites/${folder}/`;
|
|
27
|
+
const pages = files.filter(file => file.path.startsWith(root) && /\.html$/i.test(file.path)
|
|
28
|
+
&& file.path !== root + "404.html" && !skip.has(file.path)).map(file => {
|
|
29
|
+
const label = pageLabel({ file: file.path, folder });
|
|
30
|
+
return { href: relativeHref({ file: file.path }), label, title: pageTitle({ html: file.content.toString(), label, extractPlainText }) };
|
|
31
|
+
});
|
|
32
|
+
return withoutSharedSuffix({ pages }).sort((a, b) => (a.label === "/" ? -1 : b.label === "/" ? 1 : a.label.localeCompare(b.label)));
|
|
33
|
+
}
|
|
34
|
+
/** "About | Studio", "Blog | Studio" → "About", "Blog": a suffix every page repeats is noise in a list. */
|
|
35
|
+
function withoutSharedSuffix({ pages }, _options = {}) {
|
|
36
|
+
const suffix = /\s[|–—-]\s[^|–—]+$/.exec(pages[0]?.title ?? "")?.[0];
|
|
37
|
+
if (!suffix || pages.length < 2 || pages.some(page => !page.title.endsWith(suffix) || page.title.length === suffix.length))
|
|
38
|
+
return pages;
|
|
39
|
+
return pages.map(page => ({ ...page, title: page.title.slice(0, -suffix.length) }));
|
|
40
|
+
}
|
|
41
|
+
/** Root entry file of every static download and repository commit (formerly "Open website.html"). */
|
|
42
|
+
export const LANDING_FILE = "index.html";
|
|
43
|
+
const STYLE = `
|
|
44
|
+
:root{color-scheme:light dark;--bg:#f6f5f2;--card:#fff;--ink:#1c1b19;--muted:#6b6760;--line:#e4e1da;--accent:#2d5bd7;--badge:#e7efff}
|
|
45
|
+
@media (prefers-color-scheme:dark){:root{--bg:#141413;--card:#1e1d1b;--ink:#f1efe9;--muted:#a19d95;--line:#33312d;--accent:#8fb0ff;--badge:#24314f}}
|
|
46
|
+
*{box-sizing:border-box}
|
|
47
|
+
body{margin:0;background:var(--bg);color:var(--ink);font:16px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif}
|
|
48
|
+
main{max-width:1080px;margin:0 auto;padding:48px 24px 64px}
|
|
49
|
+
header{margin-bottom:32px}
|
|
50
|
+
.eyebrow{margin:0 0 4px;color:var(--muted);font-size:13px;letter-spacing:.06em;text-transform:uppercase}
|
|
51
|
+
h1{margin:0;font-size:clamp(28px,5vw,40px);line-height:1.15;overflow-wrap:anywhere}
|
|
52
|
+
.meta{margin:8px 0 0;color:var(--muted)}
|
|
53
|
+
.note{margin:16px 0 0;padding:10px 14px;border:1px solid var(--line);border-radius:8px;background:var(--card);color:var(--muted);font-size:14px}
|
|
54
|
+
.themes{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:20px}
|
|
55
|
+
.card{display:flex;flex-direction:column;background:var(--card);border:1px solid var(--line);border-radius:12px;padding:20px;min-width:0}
|
|
56
|
+
.card.active{border-color:var(--accent)}
|
|
57
|
+
.card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
|
|
58
|
+
h2{margin:0;font-size:19px;line-height:1.3;overflow-wrap:anywhere}
|
|
59
|
+
.badge{flex:none;padding:2px 10px;border-radius:999px;background:var(--badge);color:var(--accent);font-size:12px;font-weight:600;white-space:nowrap}
|
|
60
|
+
.count{margin:4px 0 14px;color:var(--muted);font-size:14px;overflow-wrap:anywhere}
|
|
61
|
+
.open{display:inline-block;align-self:flex-start;margin-bottom:14px;padding:8px 14px;border-radius:8px;background:var(--accent);color:var(--card);font-weight:600;text-decoration:none}
|
|
62
|
+
ul{list-style:none;margin:0;padding:0;border-top:1px solid var(--line)}
|
|
63
|
+
li a{display:block;padding:9px 0;border-bottom:1px solid var(--line);color:var(--ink);text-decoration:none}
|
|
64
|
+
li:last-child a{border-bottom:0;padding-bottom:0}
|
|
65
|
+
li a:hover span{color:var(--accent);text-decoration:underline}
|
|
66
|
+
li span{display:block;overflow-wrap:anywhere}
|
|
67
|
+
li small{display:block;margin-top:1px;color:var(--muted);font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
|
|
68
|
+
@media (max-width:480px){main{padding:28px 16px 40px}.themes{grid-template-columns:1fr}}
|
|
69
|
+
`.trim();
|
|
70
|
+
/** One theme card: name, active badge, page count, open-home button and every page link. */
|
|
71
|
+
function themeCard({ theme }, _options = {}) {
|
|
72
|
+
const count = `${theme.pages.length} ${theme.pages.length === 1 ? "page" : "pages"}`;
|
|
73
|
+
const home = theme.pages[0];
|
|
74
|
+
return `<article class="card${theme.active ? " active" : ""}"><div class="card-head"><h2>${escapeHtml({ text: theme.title })}</h2>`
|
|
75
|
+
+ (theme.active ? `<span class="badge">Active theme</span>` : "") + `</div>`
|
|
76
|
+
+ `<p class="count">${count} · sites/${escapeHtml({ text: theme.folder })}/</p>`
|
|
77
|
+
+ (home ? `<a class="open" href="${escapeHtml({ text: home.href })}">Open ${escapeHtml({ text: home.label === "/" ? "home page" : home.title })}</a>` : "")
|
|
78
|
+
+ `<ul>${theme.pages.map(page => `<li><a href="${escapeHtml({ text: page.href })}"><span>${escapeHtml({ text: page.title })}</span><small>${escapeHtml({ text: page.label })}</small></a></li>`).join("")}</ul></article>`;
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Root index.html of a static download: works from file:// and in Quick Look with no script.
|
|
82
|
+
* Every name and title is escaped; hrefs are plain relative paths to delivered files.
|
|
83
|
+
* @complexity O(total listed pages), no effects.
|
|
84
|
+
* @example staticLandingPage({ siteName: "My Site", themes });
|
|
85
|
+
*/
|
|
86
|
+
export function staticLandingPage({ siteName, exportedWords, themes }, _optional = {}) {
|
|
87
|
+
const site = escapeHtml({ text: siteName });
|
|
88
|
+
const meta = [exportedWords ? `Exported ${exportedWords}` : "", `${themes.length} ${themes.length === 1 ? "theme" : "themes"}`].filter(Boolean).join(" · ");
|
|
89
|
+
return Buffer.from(`<!doctype html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">`
|
|
90
|
+
+ `<title>${site} — static copy</title><style>${STYLE}</style></head><body><main>`
|
|
91
|
+
+ `<header><p class="eyebrow">Static copy</p><h1>${site}</h1><p class="meta">${escapeHtml({ text: meta })}</p>`
|
|
92
|
+
+ `<p class="note">Quick Look can't follow links — open this file in your browser.</p></header>`
|
|
93
|
+
+ `<section class="themes">${themes.map(theme => themeCard({ theme })).join("")}</section></main></body></html>\n`);
|
|
94
|
+
}
|
|
95
|
+
//# sourceMappingURL=static-download-landing.js.map
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { type DownloadHtmlSourceEdits } from "./static-download-html.js";
|
|
2
|
+
import type { StaticExportTheme } from "./static-export-selection.js";
|
|
3
|
+
import { type StaticSiteMetadata } from "./static-copy.js";
|
|
4
|
+
import { type ExtractPlainText, type LandingRenderer } from "./static-download-landing.js";
|
|
5
|
+
/** One URL range found in a rendered body (start/end index the original spelling). */
|
|
6
|
+
export interface StaticUrlLocation {
|
|
7
|
+
start: number;
|
|
8
|
+
end: number;
|
|
9
|
+
kind: string;
|
|
10
|
+
identity?: boolean | undefined;
|
|
11
|
+
}
|
|
12
|
+
/** The static-export URL parsers the layout drives, injected so the backup domain never imports the
|
|
13
|
+
* static-export implementation (pass the `@jini-ai/devops/static-export` functions of the same names). */
|
|
14
|
+
export interface StaticUrlParsing {
|
|
15
|
+
/** Every URL range in a body of the given content type. */
|
|
16
|
+
exportUrlLocations: (required: {
|
|
17
|
+
body: string;
|
|
18
|
+
contentType: string;
|
|
19
|
+
}) => readonly StaticUrlLocation[];
|
|
20
|
+
/** Every URL candidate in an HTML fragment (srcset descriptors and data URLs included). */
|
|
21
|
+
extractHtmlReferences: (required: {
|
|
22
|
+
html: string;
|
|
23
|
+
}) => Iterable<{
|
|
24
|
+
url: string;
|
|
25
|
+
}>;
|
|
26
|
+
/** The output file a root-relative URL maps to; throws on a URL that resolves outside the output directory. */
|
|
27
|
+
outputFileForUrl: (required: {
|
|
28
|
+
url: string;
|
|
29
|
+
}, optional?: {
|
|
30
|
+
contentRoute?: boolean;
|
|
31
|
+
}) => string;
|
|
32
|
+
}
|
|
33
|
+
/** Host values the portable layout cannot own: the parse5 source edits, the share path policy, the share size limits,
|
|
34
|
+
* the theme-folder allocator, the HTML-to-text decoder used for landing titles, the landing-page renderer (the
|
|
35
|
+
* host's exported HTML) and the static-export URL parsers. */
|
|
36
|
+
export interface StaticDownloadHost extends StaticUrlParsing {
|
|
37
|
+
sourceEdits: DownloadHtmlSourceEdits;
|
|
38
|
+
validateSharePath: (required: {
|
|
39
|
+
path: string;
|
|
40
|
+
}) => void;
|
|
41
|
+
sharePathAlias: (required: {
|
|
42
|
+
path: string;
|
|
43
|
+
}) => string;
|
|
44
|
+
allocateThemes: (required: {
|
|
45
|
+
themeIds: readonly string[];
|
|
46
|
+
siteSlug: string;
|
|
47
|
+
}) => StaticExportTheme[];
|
|
48
|
+
checkShareLimits: (required: {
|
|
49
|
+
files: readonly {
|
|
50
|
+
path: string;
|
|
51
|
+
bytes: number;
|
|
52
|
+
}[];
|
|
53
|
+
totalBytes?: number | undefined;
|
|
54
|
+
}) => void;
|
|
55
|
+
extractPlainText: ExtractPlainText;
|
|
56
|
+
renderLanding: LandingRenderer;
|
|
57
|
+
}
|
|
58
|
+
/** Portable packaging consumes rendered files and real site/theme context, without backup metadata. */
|
|
59
|
+
export interface StaticDownloadCopy {
|
|
60
|
+
files: readonly {
|
|
61
|
+
path: string;
|
|
62
|
+
content: Buffer;
|
|
63
|
+
}[];
|
|
64
|
+
siteSlug?: string | undefined;
|
|
65
|
+
themeId?: string | undefined;
|
|
66
|
+
publicOrigin?: string | undefined;
|
|
67
|
+
/** Serving prefix the export was rendered under; stripped before ZIP file lookup. */
|
|
68
|
+
basePath?: string | undefined;
|
|
69
|
+
metadata?: (Omit<StaticSiteMetadata, "exportedAt"> & {
|
|
70
|
+
exportedAt?: string | undefined;
|
|
71
|
+
}) | undefined;
|
|
72
|
+
readme?: {
|
|
73
|
+
name: string;
|
|
74
|
+
words?: string | undefined;
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
type Copy = StaticDownloadCopy;
|
|
78
|
+
type File = Copy["files"][number];
|
|
79
|
+
/**
|
|
80
|
+
* Package an already-captured site for opening from disk. Pure: returns new paths/bytes,
|
|
81
|
+
* leaving the capture and the publish/CLI exporter layout untouched.
|
|
82
|
+
* @param required The captured site, including its original URL and theme context.
|
|
83
|
+
* @returns Download entries without the dated outer folder (the ZIP builder owns that folder).
|
|
84
|
+
* @throws SiteShareRefusal when an original path is unsafe; archive-wide collisions are checked by the ZIP owner.
|
|
85
|
+
* @complexity O(text bytes + references + files² + collision retries), O(export bytes) memory; no I/O.
|
|
86
|
+
* @example staticDownloadLayout({ copy });
|
|
87
|
+
*/
|
|
88
|
+
export declare function staticDownloadLayout({ copy, copies, activeThemeId, themes, host }: {
|
|
89
|
+
copy: Copy;
|
|
90
|
+
copies?: readonly Copy[] | undefined;
|
|
91
|
+
activeThemeId?: string | undefined;
|
|
92
|
+
themes?: readonly StaticExportTheme[] | undefined;
|
|
93
|
+
host: StaticDownloadHost;
|
|
94
|
+
}, _options?: {}): readonly File[];
|
|
95
|
+
export {};
|
|
96
|
+
//# sourceMappingURL=static-download-layout.d.ts.map
|
|
@@ -0,0 +1,325 @@
|
|
|
1
|
+
import path from "node:path";
|
|
2
|
+
import { downloadDocumentBase } from "./static-download-html.js";
|
|
3
|
+
import { readmeText } from "./static-copy.js";
|
|
4
|
+
import { LANDING_FILE, landingPages } from "./static-download-landing.js";
|
|
5
|
+
const LOCAL_ORIGIN = "https://static-copy.invalid";
|
|
6
|
+
/** Resolve local references against their original file; foreign URLs and fragments stay intact. */
|
|
7
|
+
function localUrl({ value, file, publicOrigin, basePath }, _options = {}) {
|
|
8
|
+
if (!value || value.startsWith("#") || value.startsWith("//"))
|
|
9
|
+
return undefined;
|
|
10
|
+
try {
|
|
11
|
+
const origin = publicOrigin ?? LOCAL_ORIGIN;
|
|
12
|
+
const url = new URL(value, `${origin}/${file}`);
|
|
13
|
+
return url.origin === origin ? withoutExportPrefix({ url, basePath }) : undefined;
|
|
14
|
+
}
|
|
15
|
+
catch {
|
|
16
|
+
return undefined;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
/** This freshly parsed URL names an exported file. Strip its serving prefix before file lookup;
|
|
20
|
+
* the ZIP's page map is rooted at the artifact, while canonical/feed URLs retain their public base.
|
|
21
|
+
*/
|
|
22
|
+
function withoutExportPrefix({ url, basePath }, _options = {}) {
|
|
23
|
+
const prefix = basePath?.replace(/\/$/, "");
|
|
24
|
+
if (prefix && (url.pathname === prefix || url.pathname.startsWith(prefix + "/")))
|
|
25
|
+
url.pathname = url.pathname.slice(prefix.length) || "/";
|
|
26
|
+
return url;
|
|
27
|
+
}
|
|
28
|
+
/** The index just past the comma that ends the candidate at `from`, or the end of the list. */
|
|
29
|
+
function dropCandidateTail({ value, from }, _options = {}) {
|
|
30
|
+
const comma = value.indexOf(",", from);
|
|
31
|
+
return comma < 0 ? value.length : comma + 1;
|
|
32
|
+
}
|
|
33
|
+
/** Reuse the exporter's candidate parser, including data URLs and descriptors. O(srcset bytes). */
|
|
34
|
+
function rewriteSrcset({ value, rewrite, parsing }, _options = {}) {
|
|
35
|
+
// Ranges contain the original HTML spelling; protect the wrapper quote without double-escaping &.
|
|
36
|
+
const refs = parsing.extractHtmlReferences({ html: `<img srcset="${value.replaceAll('"', """)}">` });
|
|
37
|
+
let cursor = 0;
|
|
38
|
+
let droppedLast = false;
|
|
39
|
+
const parts = [];
|
|
40
|
+
for (const { url } of refs) {
|
|
41
|
+
const start = value.indexOf(url, cursor);
|
|
42
|
+
if (start < 0)
|
|
43
|
+
continue;
|
|
44
|
+
const rewritten = rewrite({ value: url });
|
|
45
|
+
parts.push(value.slice(cursor, start), rewritten);
|
|
46
|
+
cursor = start + url.length;
|
|
47
|
+
// A dropped (missing) candidate takes its descriptor and separator with it.
|
|
48
|
+
droppedLast = rewritten === "";
|
|
49
|
+
if (droppedLast)
|
|
50
|
+
cursor = dropCandidateTail({ value, from: cursor });
|
|
51
|
+
}
|
|
52
|
+
const out = parts.join("") + value.slice(cursor);
|
|
53
|
+
// A dropped final candidate has no separator after it; the one before it is left dangling instead.
|
|
54
|
+
return droppedLast ? out.replace(/\s*,\s*$/u, "") : out;
|
|
55
|
+
}
|
|
56
|
+
/** Jini supplies linear CSS token ranges; only the URL inside each token changes. */
|
|
57
|
+
function rewriteCss({ body, rewrite, parsing }, _options = {}) {
|
|
58
|
+
const parts = [];
|
|
59
|
+
let cursor = 0;
|
|
60
|
+
for (const { start, end } of parsing.exportUrlLocations({ body, contentType: "text/css" })) {
|
|
61
|
+
const inner = body.slice(start + 4, end - 1).trim();
|
|
62
|
+
const quote = /^["']/.test(inner) ? inner[0] : "";
|
|
63
|
+
const value = quote ? inner.slice(1, -1) : inner;
|
|
64
|
+
parts.push(body.slice(cursor, start), `url(${quote}${rewrite({ value })}${quote})`);
|
|
65
|
+
cursor = end;
|
|
66
|
+
}
|
|
67
|
+
return parts.join("") + body.slice(cursor);
|
|
68
|
+
}
|
|
69
|
+
/** HTML edits use parser-backed source ranges, preserving theme scripts and surrounding bytes. */
|
|
70
|
+
function rewriteHtml({ body, rewrite, host }, _options = {}) {
|
|
71
|
+
body = downloadDocumentBase({ html: body, rewrite: value => rewrite({ value }), sourceEdits: host.sourceEdits });
|
|
72
|
+
const parts = [];
|
|
73
|
+
let cursor = 0;
|
|
74
|
+
for (const { start, end, kind, identity } of host.exportUrlLocations({ body, contentType: "text/html" })) {
|
|
75
|
+
if (kind === "action" || identity)
|
|
76
|
+
continue;
|
|
77
|
+
const value = body.slice(start, end);
|
|
78
|
+
const replacement = rewriteHtmlValue({ value, kind, rewrite, parsing: host });
|
|
79
|
+
parts.push(body.slice(cursor, start), replacement);
|
|
80
|
+
cursor = end;
|
|
81
|
+
}
|
|
82
|
+
return parts.join("") + body.slice(cursor);
|
|
83
|
+
}
|
|
84
|
+
/** Keep CSS and candidate-list grammar with their existing owners. */
|
|
85
|
+
function rewriteHtmlValue({ value, kind, rewrite, parsing }, _options = {}) {
|
|
86
|
+
if (kind === "css")
|
|
87
|
+
return rewriteCss({ body: value, rewrite, parsing });
|
|
88
|
+
if (kind === "srcset")
|
|
89
|
+
return rewriteSrcset({ value, rewrite, parsing });
|
|
90
|
+
return rewrite({ value });
|
|
91
|
+
}
|
|
92
|
+
/** Rewrite manifest link fields structurally; malformed manifests retain their original bytes. */
|
|
93
|
+
function rewriteManifest({ body, rewrite }, _options = {}) {
|
|
94
|
+
try {
|
|
95
|
+
return JSON.stringify(JSON.parse(body), (key, value) => typeof value === "string" && ["src", "href", "url", "start_url", "scope"].includes(key) ? rewrite({ value }) : value);
|
|
96
|
+
}
|
|
97
|
+
catch {
|
|
98
|
+
return body;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
/** The same transform visits references during discovery and rewrites them after paths are assigned. */
|
|
102
|
+
function rewriteFile({ file, rewrite, host }, _options = {}) {
|
|
103
|
+
if (/\.html$/i.test(file.path))
|
|
104
|
+
return Buffer.from(rewriteHtml({ body: file.content.toString(), rewrite, host }));
|
|
105
|
+
if (/\.css$/i.test(file.path))
|
|
106
|
+
return Buffer.from(rewriteCss({ body: file.content.toString(), rewrite, parsing: host }));
|
|
107
|
+
if (/\.(?:webmanifest|json)$/i.test(file.path))
|
|
108
|
+
return Buffer.from(rewriteManifest({ body: file.content.toString(), rewrite }));
|
|
109
|
+
if (file.path === "llms.txt")
|
|
110
|
+
return Buffer.from(rewriteMarkdown({ body: file.content.toString(), rewrite, parsing: host }));
|
|
111
|
+
return file.content;
|
|
112
|
+
}
|
|
113
|
+
/** Reuse Jini's generated Markdown ranges and the same relocation map as HTML assets.
|
|
114
|
+
* @complexity O(body bytes + references), no effects.
|
|
115
|
+
*/
|
|
116
|
+
function rewriteMarkdown({ body, rewrite, parsing }, _options = {}) {
|
|
117
|
+
const parts = [];
|
|
118
|
+
let cursor = 0;
|
|
119
|
+
for (const { start, end } of parsing.exportUrlLocations({ body, contentType: "text/markdown" })) {
|
|
120
|
+
parts.push(body.slice(cursor, start), rewrite({ value: body.slice(start, end) }));
|
|
121
|
+
cursor = end;
|
|
122
|
+
}
|
|
123
|
+
return parts.join("") + body.slice(cursor);
|
|
124
|
+
}
|
|
125
|
+
/** Static downloads alone supply permissive rules when the captured robots document is empty.
|
|
126
|
+
* The exporter already enforces public-origin/Sitemap policy; retain configured bytes verbatim.
|
|
127
|
+
*/
|
|
128
|
+
function downloadRobots({ file, content }, _options = {}) {
|
|
129
|
+
return file === "robots.txt" && !content.toString().trim() ? Buffer.from("User-agent: *\nAllow: /\n") : content;
|
|
130
|
+
}
|
|
131
|
+
/** Follow page references through stylesheets/manifests, retaining only reached public media.
|
|
132
|
+
* @complexity O(text bytes + references), each file visited at most once; no I/O.
|
|
133
|
+
*/
|
|
134
|
+
function referencedFiles({ copy, host }, _options = {}) {
|
|
135
|
+
const files = new Map(copy.files.map(file => [file.path, file]));
|
|
136
|
+
const reached = new Set(copy.files.filter(file => /\.html$/i.test(file.path)).map(file => file.path));
|
|
137
|
+
// Set iteration visits newly added entries: CSS imports and manifest icons share one bounded crawl.
|
|
138
|
+
for (const name of reached) {
|
|
139
|
+
const file = files.get(name);
|
|
140
|
+
if (!file)
|
|
141
|
+
continue;
|
|
142
|
+
rewriteFile({ file, rewrite: ({ value }, _optional = {}) => {
|
|
143
|
+
const url = localUrl({ value, file: name, publicOrigin: copy.publicOrigin, basePath: copy.basePath });
|
|
144
|
+
if (url && files.has(url.pathname.slice(1)))
|
|
145
|
+
reached.add(url.pathname.slice(1));
|
|
146
|
+
return value;
|
|
147
|
+
}, host });
|
|
148
|
+
}
|
|
149
|
+
return reached;
|
|
150
|
+
}
|
|
151
|
+
/** Allocate distinct portable filenames before rewriting; different source URLs retain their bytes. */
|
|
152
|
+
function allocateDownloadPath({ target, claimed, host }, _options = {}) {
|
|
153
|
+
const extension = path.posix.extname(target);
|
|
154
|
+
const stem = extension ? target.slice(0, -extension.length) : target;
|
|
155
|
+
let suffix = 1, candidate = target;
|
|
156
|
+
while (claimed.has(host.sharePathAlias({ path: candidate }))) {
|
|
157
|
+
suffix += 1;
|
|
158
|
+
candidate = `${stem}-${suffix}${extension}`;
|
|
159
|
+
}
|
|
160
|
+
claimed.add(host.sharePathAlias({ path: candidate }));
|
|
161
|
+
return candidate;
|
|
162
|
+
}
|
|
163
|
+
/** Flatten public media independently of theme images, using the same portable filename allocator. */
|
|
164
|
+
function mediaPath({ file, claimed, host }, _options = {}) {
|
|
165
|
+
const name = file.split("/")[1];
|
|
166
|
+
if (name === undefined)
|
|
167
|
+
throw new Error(`Static download media path has no filename: ${file}`);
|
|
168
|
+
return allocateDownloadPath({ target: `media/${name}${path.posix.extname(file)}`, claimed, host });
|
|
169
|
+
}
|
|
170
|
+
/** Repeated public URLs across themes use the first allocated media destination. */
|
|
171
|
+
function sharedMediaPath({ file, media, claimed, host }, _options = {}) {
|
|
172
|
+
const existing = media.get(file);
|
|
173
|
+
if (existing)
|
|
174
|
+
return existing;
|
|
175
|
+
const target = mediaPath({ file, claimed, host });
|
|
176
|
+
media.set(file, target);
|
|
177
|
+
return target;
|
|
178
|
+
}
|
|
179
|
+
/** Theme assets keep meaningful subtrees while media-library assets live beside sites/. */
|
|
180
|
+
function themeAssetPath({ file }, _options = {}) {
|
|
181
|
+
const relative = file.replace(/^theme-assets\/[^/]+\//, "");
|
|
182
|
+
if (/\.webmanifest$/i.test(relative))
|
|
183
|
+
return path.posix.basename(relative);
|
|
184
|
+
if (/\.css$/i.test(relative))
|
|
185
|
+
return "css/" + relative.replace(/^(?:css|styles)\//, "");
|
|
186
|
+
if (/\.(?:m?js|cjs)$/i.test(relative))
|
|
187
|
+
return "js/" + relative.replace(/^(?:js|scripts)\//, "");
|
|
188
|
+
if (/\.(?:woff2?|ttf|otf|eot)$/i.test(relative))
|
|
189
|
+
return "fonts/" + path.posix.basename(relative);
|
|
190
|
+
if (relative.startsWith("icons/"))
|
|
191
|
+
return relative;
|
|
192
|
+
if (/\.ico$/i.test(relative))
|
|
193
|
+
return "icons/" + path.posix.basename(relative);
|
|
194
|
+
if (/\.(?:avif|webp|png|jpe?g|gif|svg|ico)$/i.test(relative))
|
|
195
|
+
return "images/" + relative.replace(/^(?:assets|images)\//, "");
|
|
196
|
+
return relative;
|
|
197
|
+
}
|
|
198
|
+
/** Theme-owned files retain their own subtree; the single README stays at archive root. */
|
|
199
|
+
function themeDownloadPath({ file, theme }, _options = {}) {
|
|
200
|
+
if (file === "README.txt")
|
|
201
|
+
return file;
|
|
202
|
+
const relative = file.startsWith("theme-assets/") ? themeAssetPath({ file }) : file;
|
|
203
|
+
return `sites/${theme}/${relative}`;
|
|
204
|
+
}
|
|
205
|
+
/** Assign paths before rewriting, so references and files share one immutable mapping. */
|
|
206
|
+
function downloadPaths({ copy, theme, reached, media, claimed, host }, _options = {}) {
|
|
207
|
+
const paths = new Map();
|
|
208
|
+
for (const file of copy.files) {
|
|
209
|
+
host.validateSharePath({ path: file.path });
|
|
210
|
+
if (file.path.startsWith("m/")) {
|
|
211
|
+
const target = reached.has(file.path) ? sharedMediaPath({ file: file.path, media, claimed, host }) : undefined;
|
|
212
|
+
if (target)
|
|
213
|
+
paths.set(file.path, target);
|
|
214
|
+
continue;
|
|
215
|
+
}
|
|
216
|
+
// Removing theme/font directory prefixes can merge distinct URLs. Allocate before URL rewrites.
|
|
217
|
+
paths.set(file.path, allocateDownloadPath({ target: themeDownloadPath({ file: file.path, theme }), claimed, host }));
|
|
218
|
+
}
|
|
219
|
+
return paths;
|
|
220
|
+
}
|
|
221
|
+
/** Map a local page or asset from its old location to a file-relative download URL.
|
|
222
|
+
* Missing /m/ responses include private Library documents; never retain their URLs.
|
|
223
|
+
*/
|
|
224
|
+
function relocatedUrl({ value, file, target, paths, copy, theme, parsing }, _options = {}) {
|
|
225
|
+
const url = localUrl({ value, file, publicOrigin: copy.publicOrigin, basePath: copy.basePath });
|
|
226
|
+
if (!url)
|
|
227
|
+
return value;
|
|
228
|
+
const source = url.pathname.slice(1);
|
|
229
|
+
const page = source.replace(/\/$/, "");
|
|
230
|
+
const destination = paths.get(source) ?? paths.get(parsing.outputFileForUrl({ url: url.pathname }, { contentRoute: true }));
|
|
231
|
+
if (!destination && source.startsWith("m/"))
|
|
232
|
+
return "";
|
|
233
|
+
const themeRoot = `sites/${theme}`;
|
|
234
|
+
const fallback = `${themeRoot}/${page || "index.html"}`;
|
|
235
|
+
// Keep page paths explicit through the theme root, including links back to the current page.
|
|
236
|
+
if (destination?.endsWith(".html"))
|
|
237
|
+
return [path.posix.relative(path.posix.dirname(target), themeRoot),
|
|
238
|
+
path.posix.relative(themeRoot, destination)].filter(Boolean).join("/") + url.search + url.hash;
|
|
239
|
+
return path.posix.relative(path.posix.dirname(target), destination ?? fallback) + url.search + url.hash;
|
|
240
|
+
}
|
|
241
|
+
/**
|
|
242
|
+
* Package an already-captured site for opening from disk. Pure: returns new paths/bytes,
|
|
243
|
+
* leaving the capture and the publish/CLI exporter layout untouched.
|
|
244
|
+
* @param required The captured site, including its original URL and theme context.
|
|
245
|
+
* @returns Download entries without the dated outer folder (the ZIP builder owns that folder).
|
|
246
|
+
* @throws SiteShareRefusal when an original path is unsafe; archive-wide collisions are checked by the ZIP owner.
|
|
247
|
+
* @complexity O(text bytes + references + files² + collision retries), O(export bytes) memory; no I/O.
|
|
248
|
+
* @example staticDownloadLayout({ copy });
|
|
249
|
+
*/
|
|
250
|
+
export function staticDownloadLayout({ copy, copies = [copy], activeThemeId, themes, host }, _options = {}) {
|
|
251
|
+
const plans = downloadPlans({ copies, themes, siteSlug: copy.siteSlug ?? "", host });
|
|
252
|
+
const entries = [], deliveredMedia = new Set();
|
|
253
|
+
const sizes = [];
|
|
254
|
+
let totalBytes = 0;
|
|
255
|
+
// Track combined output incrementally after URL deduplication, before ZIP encoding.
|
|
256
|
+
const add = (file) => {
|
|
257
|
+
totalBytes += file.content.length;
|
|
258
|
+
sizes.push({ path: file.path, bytes: file.content.length });
|
|
259
|
+
host.checkShareLimits({ files: sizes, totalBytes });
|
|
260
|
+
entries.push(file);
|
|
261
|
+
};
|
|
262
|
+
const readmes = [], landing = [];
|
|
263
|
+
for (const plan of plans) {
|
|
264
|
+
const files = relocatedFiles({ ...plan, deliveredMedia, host });
|
|
265
|
+
for (const file of files)
|
|
266
|
+
add(file);
|
|
267
|
+
readmes.push(...downloadReadme({ plan }));
|
|
268
|
+
landing.push(landingTheme({ plan, files, activeThemeId: activeThemeId ?? copy.themeId, host }));
|
|
269
|
+
}
|
|
270
|
+
// A partial render may lose a home page; the landing page still lists every delivered page.
|
|
271
|
+
add(landingFile({ copy, landing, host }));
|
|
272
|
+
if (readmes.length)
|
|
273
|
+
add(readmeFile({ readmes }, { sharedMedia: copies.length > 1 ? deliveredMedia.size : undefined }));
|
|
274
|
+
return entries;
|
|
275
|
+
}
|
|
276
|
+
/** The download's landing page, named after the site and listing every theme card. */
|
|
277
|
+
function landingFile({ copy, landing, host }, _options = {}) {
|
|
278
|
+
return { path: LANDING_FILE, content: host.renderLanding({ siteName: copy.readme?.name ?? copy.siteSlug ?? "Website", exportedWords: copy.readme?.words, themes: landing }) };
|
|
279
|
+
}
|
|
280
|
+
/** The combined per-theme README; a multi-theme download also counts its shared media. */
|
|
281
|
+
function readmeFile({ readmes }, { sharedMedia } = {}) {
|
|
282
|
+
return { path: "README.txt", content: Buffer.from(readmes.join("\n") + (sharedMedia !== undefined ? `\nShared media: ${sharedMedia} files in media/.\n` : "")) };
|
|
283
|
+
}
|
|
284
|
+
/** One landing card: the theme's display title, its folder and its delivered pages (redirect stubs omitted). */
|
|
285
|
+
function landingTheme({ plan, files, activeThemeId, host }, _options = {}) {
|
|
286
|
+
const skip = new Set((plan.copy.metadata?.redirectFiles ?? []).flatMap(file => plan.paths.get(file) ?? []));
|
|
287
|
+
return { title: plan.copy.metadata?.theme ?? plan.theme, folder: plan.theme, active: plan.copy.themeId !== undefined && plan.copy.themeId === activeThemeId,
|
|
288
|
+
pages: landingPages({ files, folder: plan.theme, skip, extractPlainText: host.extractPlainText }) };
|
|
289
|
+
}
|
|
290
|
+
/** Dated downloads and deterministic commits share the same per-theme disclosures. */
|
|
291
|
+
function downloadReadme({ plan }, _options = {}) {
|
|
292
|
+
if (!plan.copy.readme || !plan.copy.metadata)
|
|
293
|
+
return [];
|
|
294
|
+
return [readmeText({ ...plan.copy.readme, metadata: plan.copy.metadata,
|
|
295
|
+
rendered: { files: [...plan.paths.values()].filter(name => name !== "README.txt").map(path => ({ path })), publicOrigin: plan.copy.publicOrigin } }, { downloadTheme: plan.theme }).toString()];
|
|
296
|
+
}
|
|
297
|
+
/** Assign every theme/media path before any rewrite; page maps remain capture-local. */
|
|
298
|
+
function downloadPlans({ copies, themes, siteSlug, host }, _options = {}) {
|
|
299
|
+
const folders = new Map((themes ?? host.allocateThemes({ themeIds: copies.map(item => item.themeId ?? item.metadata?.theme ?? "site"), siteSlug })).map(theme => [theme.themeId, theme.name]));
|
|
300
|
+
const media = new Map(), claimed = new Set();
|
|
301
|
+
return copies.map(item => {
|
|
302
|
+
const theme = folders.get(item.themeId ?? item.metadata?.theme ?? "site");
|
|
303
|
+
if (theme === undefined)
|
|
304
|
+
throw new Error("Static download has no allocated theme folder");
|
|
305
|
+
return { copy: item, theme, paths: downloadPaths({ copy: item, theme, reached: referencedFiles({ copy: item, host }), media, claimed, host }) };
|
|
306
|
+
});
|
|
307
|
+
}
|
|
308
|
+
/** Relocate one theme's URLs against its own page map, sharing only public media URL identities.
|
|
309
|
+
* @complexity O(capture bytes + references), no I/O; shared media membership is archive-wide.
|
|
310
|
+
*/
|
|
311
|
+
function relocatedFiles({ copy, theme, paths, deliveredMedia, host }, _options = {}) {
|
|
312
|
+
const entries = [];
|
|
313
|
+
for (const file of copy.files) {
|
|
314
|
+
const target = paths.get(file.path);
|
|
315
|
+
if (!target || file.path === "README.txt" || deliveredMedia.has(target))
|
|
316
|
+
continue;
|
|
317
|
+
if (target.startsWith("media/")) {
|
|
318
|
+
deliveredMedia.add(target);
|
|
319
|
+
}
|
|
320
|
+
const content = downloadRobots({ file: file.path, content: rewriteFile({ file, rewrite: ({ value }, _optional = {}) => relocatedUrl({ value, file: file.path, target, paths, copy, theme, parsing: host }), host }) });
|
|
321
|
+
entries.push({ path: target, content });
|
|
322
|
+
}
|
|
323
|
+
return entries;
|
|
324
|
+
}
|
|
325
|
+
//# sourceMappingURL=static-download-layout.js.map
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
export interface StaticExportInput {
|
|
2
|
+
jobId?: string;
|
|
3
|
+
themeIds?: readonly string[];
|
|
4
|
+
publicUrl?: string;
|
|
5
|
+
}
|
|
6
|
+
export interface StaticExportTheme {
|
|
7
|
+
themeId: string;
|
|
8
|
+
name: string;
|
|
9
|
+
}
|
|
10
|
+
export interface StaticExportOptions {
|
|
11
|
+
activeThemeId: string;
|
|
12
|
+
themes: readonly StaticExportTheme[];
|
|
13
|
+
}
|
|
14
|
+
/** The host's portable-path policy and refusal for malformed selection input. */
|
|
15
|
+
export interface StaticExportSelectionPolicy {
|
|
16
|
+
/** Throws when `path` may not be published in the archive. */
|
|
17
|
+
validateSharePath(required: {
|
|
18
|
+
path: string;
|
|
19
|
+
}): void;
|
|
20
|
+
/** Always throws the host's refusal for malformed input; this module never builds the message. */
|
|
21
|
+
invalidInput(): never;
|
|
22
|
+
}
|
|
23
|
+
/** The host's portable-path policy for allocating theme folder names. */
|
|
24
|
+
export interface StaticExportAllocationPolicy {
|
|
25
|
+
validateSharePath(required: {
|
|
26
|
+
path: string;
|
|
27
|
+
}): void;
|
|
28
|
+
/** Folds a name to its case/Unicode collision alias. */
|
|
29
|
+
sharePathAlias(required: {
|
|
30
|
+
path: string;
|
|
31
|
+
}): string;
|
|
32
|
+
}
|
|
33
|
+
/** One HTTP/tool start-or-resume contract. Never changes submitted selection order.
|
|
34
|
+
* @throws whatever `policy.invalidInput` throws, for malformed input, repeated IDs or selection on a resume.
|
|
35
|
+
* @complexity O(input bytes + IDs), no effects.
|
|
36
|
+
*/
|
|
37
|
+
export declare function parseStaticExportInput({ input, policy }: {
|
|
38
|
+
input: unknown;
|
|
39
|
+
policy: StaticExportSelectionPolicy;
|
|
40
|
+
}, _options?: {}): StaticExportInput;
|
|
41
|
+
/** Allocate portable names from the entire roster so options and selected subsets agree.
|
|
42
|
+
* Sorting makes case/Unicode collision suffixes independent of discovery and selection order.
|
|
43
|
+
* @complexity O(T log T + collision retries), O(T) memory; no I/O.
|
|
44
|
+
*/
|
|
45
|
+
export declare function allocateStaticExportThemes({ themeIds, siteSlug, policy }: {
|
|
46
|
+
themeIds: readonly string[];
|
|
47
|
+
siteSlug: string;
|
|
48
|
+
policy: StaticExportAllocationPolicy;
|
|
49
|
+
}, _options?: {}): StaticExportTheme[];
|
|
50
|
+
//# sourceMappingURL=static-export-selection.d.ts.map
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
/** One HTTP/tool start-or-resume contract. Never changes submitted selection order.
|
|
2
|
+
* @throws whatever `policy.invalidInput` throws, for malformed input, repeated IDs or selection on a resume.
|
|
3
|
+
* @complexity O(input bytes + IDs), no effects.
|
|
4
|
+
*/
|
|
5
|
+
export function parseStaticExportInput({ input, policy }, _options = {}) {
|
|
6
|
+
if (typeof input !== "object" || input === null || Array.isArray(input))
|
|
7
|
+
policy.invalidInput();
|
|
8
|
+
const raw = input;
|
|
9
|
+
if (Object.keys(raw).some(key => !["jobId", "themeIds", "publicUrl"].includes(key)))
|
|
10
|
+
policy.invalidInput();
|
|
11
|
+
if (raw.jobId !== undefined) {
|
|
12
|
+
return { jobId: readStaticJobId({ input: raw, policy }) };
|
|
13
|
+
}
|
|
14
|
+
const publicUrl = readPublicUrl({ value: raw.publicUrl, policy });
|
|
15
|
+
const themeIds = raw.themeIds === undefined ? undefined : readThemeIds({ value: raw.themeIds, policy });
|
|
16
|
+
return { ...(themeIds === undefined ? {} : { themeIds }), ...(publicUrl === undefined ? {} : { publicUrl }) };
|
|
17
|
+
}
|
|
18
|
+
/** Only parse the input shape here; the existing export-origin owner validates the destination. */
|
|
19
|
+
function readPublicUrl({ value, policy }, _options = {}) {
|
|
20
|
+
if (value === undefined)
|
|
21
|
+
return undefined;
|
|
22
|
+
if (typeof value !== "string" || !value.trim())
|
|
23
|
+
policy.invalidInput();
|
|
24
|
+
return value;
|
|
25
|
+
}
|
|
26
|
+
/** A resume cannot change the selection that the job already captured. */
|
|
27
|
+
function readStaticJobId({ input, policy }, _options = {}) {
|
|
28
|
+
if (typeof input.jobId !== "string" || !/^[0-9a-f-]{36}$/.test(input.jobId) || input.themeIds !== undefined || input.publicUrl !== undefined)
|
|
29
|
+
policy.invalidInput();
|
|
30
|
+
return input.jobId;
|
|
31
|
+
}
|
|
32
|
+
/** Theme IDs are canonical single path segments; installed membership is checked by the backend. */
|
|
33
|
+
function readThemeIds({ value, policy }, _options = {}) {
|
|
34
|
+
if (!Array.isArray(value) || !value.length)
|
|
35
|
+
policy.invalidInput();
|
|
36
|
+
const seen = new Set();
|
|
37
|
+
for (const id of value) {
|
|
38
|
+
if (typeof id !== "string" || !id || /[/\\%?#]/.test(id) || seen.has(id))
|
|
39
|
+
policy.invalidInput();
|
|
40
|
+
try {
|
|
41
|
+
policy.validateSharePath({ path: `sites/${id}/index.html` });
|
|
42
|
+
}
|
|
43
|
+
catch {
|
|
44
|
+
policy.invalidInput();
|
|
45
|
+
}
|
|
46
|
+
seen.add(id);
|
|
47
|
+
}
|
|
48
|
+
return [...seen];
|
|
49
|
+
}
|
|
50
|
+
/** Allocate portable names from the entire roster so options and selected subsets agree.
|
|
51
|
+
* Sorting makes case/Unicode collision suffixes independent of discovery and selection order.
|
|
52
|
+
* @complexity O(T log T + collision retries), O(T) memory; no I/O.
|
|
53
|
+
*/
|
|
54
|
+
export function allocateStaticExportThemes({ themeIds, siteSlug, policy }, _options = {}) {
|
|
55
|
+
// The site-slug prefix is branding, not part of the portable theme folder name.
|
|
56
|
+
const prefix = siteSlug.split("-")[0] + "-";
|
|
57
|
+
const names = new Map(), claimed = new Set();
|
|
58
|
+
for (const themeId of [...themeIds].sort()) {
|
|
59
|
+
const short = (themeId.startsWith(prefix) && themeId.length > prefix.length ? themeId.slice(prefix.length) : themeId).normalize("NFC");
|
|
60
|
+
let name = short, suffix = 1;
|
|
61
|
+
while (claimed.has(policy.sharePathAlias({ path: name }))) {
|
|
62
|
+
suffix += 1;
|
|
63
|
+
name = `${short}-${suffix}`;
|
|
64
|
+
}
|
|
65
|
+
policy.validateSharePath({ path: `sites/${name}/index.html` });
|
|
66
|
+
names.set(themeId, name);
|
|
67
|
+
claimed.add(policy.sharePathAlias({ path: name }));
|
|
68
|
+
}
|
|
69
|
+
return themeIds.map(themeId => {
|
|
70
|
+
const name = names.get(themeId);
|
|
71
|
+
if (name === undefined)
|
|
72
|
+
throw new Error(`Static export has no allocated folder for theme ${themeId}`);
|
|
73
|
+
return { themeId, name };
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
//# sourceMappingURL=static-export-selection.js.map
|