sandcms 0.6.2 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -10
- package/dist/admin/Account.svelte +286 -83
- package/dist/admin/Admin.svelte +14 -1
- package/dist/admin/ApiKeys.svelte +146 -79
- package/dist/admin/AssetAttachment.svelte +10 -12
- package/dist/admin/AssetAttachment.svelte.d.ts +0 -1
- package/dist/admin/BlueprintFields.svelte +20 -5
- package/dist/admin/BlueprintFields.svelte.d.ts +2 -1
- package/dist/admin/Collection.svelte +111 -54
- package/dist/admin/Dashboard.svelte +3 -37
- package/dist/admin/DateField.svelte +75 -0
- package/dist/admin/DateField.svelte.d.ts +11 -0
- package/dist/admin/Editor.svelte +70 -65
- package/dist/admin/Fields.svelte +24 -23
- package/dist/admin/Fields.svelte.d.ts +0 -1
- package/dist/admin/FocusPicker.svelte +1 -2
- package/dist/admin/Gallery.svelte +2 -7
- package/dist/admin/Gallery.svelte.d.ts +0 -1
- package/dist/admin/GlobalSearch.svelte +54 -26
- package/dist/admin/HoverHint.svelte +37 -0
- package/dist/admin/HoverHint.svelte.d.ts +8 -0
- package/dist/admin/Inbox.svelte +6 -11
- package/dist/admin/LinkField.svelte +128 -66
- package/dist/admin/LinkField.svelte.d.ts +0 -1
- package/dist/admin/Login.svelte +0 -1
- package/dist/admin/MediaLibrary.svelte +70 -56
- package/dist/admin/MediaPicker.svelte +62 -55
- package/dist/admin/MediaPicker.svelte.d.ts +0 -1
- package/dist/admin/NotificationSettings.svelte +35 -27
- package/dist/admin/RichText.svelte +2 -2
- package/dist/admin/RowMenu.svelte +28 -0
- package/dist/admin/RowMenu.svelte.d.ts +10 -0
- package/dist/admin/SearchList.svelte +51 -14
- package/dist/admin/Shell.svelte +64 -29
- package/dist/admin/ThemePicker.svelte +72 -0
- package/dist/admin/ThemePicker.svelte.d.ts +18 -0
- package/dist/admin/UploadButton.svelte +2 -1
- package/dist/admin/UploadProgress.svelte +24 -0
- package/dist/admin/UploadProgress.svelte.d.ts +7 -0
- package/dist/admin/Users.svelte +106 -50
- package/dist/admin/client.d.ts +5 -670
- package/dist/admin/client.js +20 -1
- package/dist/admin/components/ui/alert/alert.svelte.d.ts +3 -13
- package/dist/admin/components/ui/attachment/attachment-media.svelte.d.ts +3 -13
- package/dist/admin/components/ui/attachment/attachment.svelte.d.ts +6 -26
- package/dist/admin/components/ui/badge/badge.svelte.d.ts +7 -25
- package/dist/admin/components/ui/button/button.svelte.d.ts +15 -53
- package/dist/admin/components/ui/calendar/calendar-caption.svelte +76 -0
- package/dist/admin/components/ui/calendar/calendar-caption.svelte.d.ts +19 -0
- package/dist/admin/components/ui/calendar/calendar-cell.svelte +19 -0
- package/dist/admin/components/ui/calendar/calendar-cell.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-day.svelte +33 -0
- package/dist/admin/components/ui/calendar/calendar-day.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-grid-body.svelte +12 -0
- package/dist/admin/components/ui/calendar/calendar-grid-body.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-grid-head.svelte +12 -0
- package/dist/admin/components/ui/calendar/calendar-grid-head.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-grid-row.svelte +12 -0
- package/dist/admin/components/ui/calendar/calendar-grid-row.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-grid.svelte +16 -0
- package/dist/admin/components/ui/calendar/calendar-grid.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-head-cell.svelte +19 -0
- package/dist/admin/components/ui/calendar/calendar-head-cell.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-header.svelte +19 -0
- package/dist/admin/components/ui/calendar/calendar-header.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-heading.svelte +16 -0
- package/dist/admin/components/ui/calendar/calendar-heading.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-month-select.svelte +48 -0
- package/dist/admin/components/ui/calendar/calendar-month-select.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar-month.svelte +15 -0
- package/dist/admin/components/ui/calendar/calendar-month.svelte.d.ts +5 -0
- package/dist/admin/components/ui/calendar/calendar-months.svelte +19 -0
- package/dist/admin/components/ui/calendar/calendar-months.svelte.d.ts +5 -0
- package/dist/admin/components/ui/calendar/calendar-nav.svelte +19 -0
- package/dist/admin/components/ui/calendar/calendar-nav.svelte.d.ts +5 -0
- package/dist/admin/components/ui/calendar/calendar-next-button.svelte +37 -0
- package/dist/admin/components/ui/calendar/calendar-next-button.svelte.d.ts +8 -0
- package/dist/admin/components/ui/calendar/calendar-prev-button.svelte +37 -0
- package/dist/admin/components/ui/calendar/calendar-prev-button.svelte.d.ts +8 -0
- package/dist/admin/components/ui/calendar/calendar-year-select.svelte +47 -0
- package/dist/admin/components/ui/calendar/calendar-year-select.svelte.d.ts +4 -0
- package/dist/admin/components/ui/calendar/calendar.svelte +115 -0
- package/dist/admin/components/ui/calendar/calendar.svelte.d.ts +21 -0
- package/dist/admin/components/ui/calendar/index.d.ts +19 -0
- package/dist/admin/components/ui/calendar/index.js +21 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-checkbox-group.svelte +16 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-checkbox-group.svelte.d.ts +4 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-checkbox-item.svelte +46 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-checkbox-item.svelte.d.ts +9 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-content.svelte +31 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-content.svelte.d.ts +10 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-group-heading.svelte +22 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-group-heading.svelte.d.ts +8 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-group.svelte +7 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-group.svelte.d.ts +4 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-item.svelte +27 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-item.svelte.d.ts +8 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-label.svelte +24 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-label.svelte.d.ts +8 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-portal.svelte +7 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-portal.svelte.d.ts +3 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-radio-group.svelte +16 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-radio-group.svelte.d.ts +4 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-radio-item.svelte +36 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-radio-item.svelte.d.ts +4 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-separator.svelte +17 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-separator.svelte.d.ts +4 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-shortcut.svelte +23 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-shortcut.svelte.d.ts +5 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-sub-content.svelte +31 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-sub-content.svelte.d.ts +10 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-sub-trigger.svelte +29 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-sub-trigger.svelte.d.ts +7 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-sub.svelte +7 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-sub.svelte.d.ts +3 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-trigger.svelte +7 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu-trigger.svelte.d.ts +4 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu.svelte +7 -0
- package/dist/admin/components/ui/dropdown-menu/dropdown-menu.svelte.d.ts +3 -0
- package/dist/admin/components/ui/dropdown-menu/index.d.ts +18 -0
- package/dist/admin/components/ui/dropdown-menu/index.js +18 -0
- package/dist/admin/components/ui/input-otp/index.d.ts +5 -0
- package/dist/admin/components/ui/input-otp/index.js +5 -0
- package/dist/admin/components/ui/input-otp/input-otp-group.svelte +23 -0
- package/dist/admin/components/ui/input-otp/input-otp-group.svelte.d.ts +5 -0
- package/dist/admin/components/ui/input-otp/input-otp-separator.svelte +27 -0
- package/dist/admin/components/ui/input-otp/input-otp-separator.svelte.d.ts +5 -0
- package/dist/admin/components/ui/input-otp/input-otp-slot.svelte +29 -0
- package/dist/admin/components/ui/input-otp/input-otp-slot.svelte.d.ts +4 -0
- package/dist/admin/components/ui/input-otp/input-otp.svelte +24 -0
- package/dist/admin/components/ui/input-otp/input-otp.svelte.d.ts +4 -0
- package/dist/admin/components/ui/popover/index.d.ts +9 -0
- package/dist/admin/components/ui/popover/index.js +11 -0
- package/dist/admin/components/ui/popover/popover-close.svelte +7 -0
- package/dist/admin/components/ui/popover/popover-close.svelte.d.ts +4 -0
- package/dist/admin/components/ui/popover/popover-content.svelte +31 -0
- package/dist/admin/components/ui/popover/popover-content.svelte.d.ts +10 -0
- package/dist/admin/components/ui/popover/popover-description.svelte +20 -0
- package/dist/admin/components/ui/popover/popover-description.svelte.d.ts +5 -0
- package/dist/admin/components/ui/popover/popover-header.svelte +20 -0
- package/dist/admin/components/ui/popover/popover-header.svelte.d.ts +5 -0
- package/dist/admin/components/ui/popover/popover-portal.svelte +7 -0
- package/dist/admin/components/ui/popover/popover-portal.svelte.d.ts +3 -0
- package/dist/admin/components/ui/popover/popover-title.svelte +20 -0
- package/dist/admin/components/ui/popover/popover-title.svelte.d.ts +5 -0
- package/dist/admin/components/ui/popover/popover-trigger.svelte +17 -0
- package/dist/admin/components/ui/popover/popover-trigger.svelte.d.ts +4 -0
- package/dist/admin/components/ui/popover/popover.svelte +7 -0
- package/dist/admin/components/ui/popover/popover.svelte.d.ts +3 -0
- package/dist/admin/components/ui/switch/switch.svelte +2 -2
- package/dist/admin/components/ui/toggle/toggle.svelte.d.ts +6 -26
- package/dist/admin/components/ui/tooltip/index.d.ts +6 -0
- package/dist/admin/components/ui/tooltip/index.js +8 -0
- package/dist/admin/components/ui/tooltip/tooltip-content.svelte +48 -0
- package/dist/admin/components/ui/tooltip/tooltip-content.svelte.d.ts +11 -0
- package/dist/admin/components/ui/tooltip/tooltip-portal.svelte +7 -0
- package/dist/admin/components/ui/tooltip/tooltip-portal.svelte.d.ts +4 -0
- package/dist/admin/components/ui/tooltip/tooltip-provider.svelte +7 -0
- package/dist/admin/components/ui/tooltip/tooltip-provider.svelte.d.ts +4 -0
- package/dist/admin/components/ui/tooltip/tooltip-trigger.svelte +7 -0
- package/dist/admin/components/ui/tooltip/tooltip-trigger.svelte.d.ts +25 -0
- package/dist/admin/components/ui/tooltip/tooltip.svelte +7 -0
- package/dist/admin/components/ui/tooltip/tooltip.svelte.d.ts +25 -0
- package/dist/admin/generated/admin.css +1298 -234
- package/dist/admin/slug.d.ts +1 -0
- package/dist/admin/slug.js +6 -0
- package/dist/admin/theme-context.d.ts +7 -0
- package/dist/admin/theme-context.js +3 -0
- package/dist/admin/theme.d.ts +7 -0
- package/dist/admin/theme.js +14 -0
- package/dist/admin/types.d.ts +2 -1
- package/dist/admin/uploads.d.ts +8 -1
- package/dist/admin/uploads.js +94 -16
- package/dist/blueprints/files.js +1 -0
- package/dist/blueprints/load.js +7 -2
- package/dist/blueprints/types.d.ts +4 -1
- package/dist/cli/doctor.d.ts +3 -1
- package/dist/cli/doctor.js +85 -30
- package/dist/cli/files.d.ts +2 -6
- package/dist/cli/files.js +11 -2
- package/dist/cli/index.js +99 -31
- package/dist/cli/scaffold.js +8 -8
- package/dist/cli/setup.js +16 -26
- package/dist/cli/upgrade.js +21 -2
- package/dist/env.d.ts +32 -0
- package/dist/env.js +53 -3
- package/dist/server/admin-load.d.ts +13 -5
- package/dist/server/admin-load.js +8 -3
- package/dist/server/api-access.d.ts +4 -0
- package/dist/server/api-access.js +15 -2
- package/dist/server/api-pagination.d.ts +3 -0
- package/dist/server/api.js +11 -3
- package/dist/server/auth.d.ts +11 -9
- package/dist/server/auth.js +23 -0
- package/dist/server/cms.d.ts +65 -18
- package/dist/server/cms.js +62 -6
- package/dist/server/db/migration-data.js +4 -0
- package/dist/server/db/migrations/0009_local_media.sql +9 -0
- package/dist/server/db/migrations/meta/0009_snapshot.json +1763 -0
- package/dist/server/db/migrations/meta/_journal.json +7 -0
- package/dist/server/db/schema.d.ts +119 -2
- package/dist/server/db/schema.js +15 -3
- package/dist/server/hooks.js +155 -81
- package/dist/server/media/contracts.d.ts +115 -0
- package/dist/server/media/contracts.js +12 -0
- package/dist/server/media/deletions.d.ts +2 -1
- package/dist/server/media/deletions.js +3 -3
- package/dist/server/media/delivery.js +7 -11
- package/dist/server/media/import-r2.d.ts +56 -0
- package/dist/server/media/import-r2.js +342 -0
- package/dist/server/media/processor-child.d.ts +2 -0
- package/dist/server/media/processor-child.js +236 -0
- package/dist/server/media/processor.d.ts +51 -0
- package/dist/server/media/processor.js +135 -0
- package/dist/server/media/render-math.d.ts +24 -0
- package/dist/server/media/render-math.js +50 -0
- package/dist/server/media/runner.d.ts +30 -1
- package/dist/server/media/runner.js +418 -165
- package/dist/server/media/service.d.ts +56 -10
- package/dist/server/media/service.js +309 -98
- package/dist/server/media/storage.d.ts +5 -0
- package/dist/server/media/storage.js +279 -0
- package/dist/server/media/svg.d.ts +5 -0
- package/dist/server/media/svg.js +142 -0
- package/dist/server/media/upload-ticket.d.ts +12 -0
- package/dist/server/media/upload-ticket.js +35 -0
- package/dist/server/media/verify.d.ts +36 -0
- package/dist/server/media/verify.js +109 -0
- package/dist/server/platform/http.d.ts +27 -0
- package/dist/server/platform/http.js +77 -0
- package/dist/server/platform/index.d.ts +52 -0
- package/dist/server/platform/index.js +98 -0
- package/dist/server/platform/snapshots.d.ts +18 -0
- package/dist/server/platform/snapshots.js +110 -0
- package/dist/server/platform/volume.d.ts +20 -0
- package/dist/server/platform/volume.js +60 -0
- package/dist/worker/svg.d.ts +1 -5
- package/dist/worker/svg.js +2 -142
- package/docs/acceptance.md +6 -4
- package/docs/api.md +42 -4
- package/docs/cloudflare.md +48 -142
- package/docs/content.md +2 -2
- package/docs/deployment.md +159 -57
- package/docs/forms.md +1 -1
- package/docs/media.md +85 -21
- package/docs/package.md +21 -18
- package/docs/plans/0.7-self-hosted.md +264 -0
- package/docs/releases.md +27 -1
- package/docs/upgrades.md +44 -6
- package/package.json +38 -37
- package/templates/Dockerfile +28 -0
- package/templates/integration.ts +18 -2
- package/templates/railpack.json +1 -1
- package/templates/sandcms/blueprints/files/image.yaml +1 -1
- package/templates/sandcms/config.yaml +0 -1
- package/dist/cli/cloudflare.d.ts +0 -8
- package/dist/cli/cloudflare.js +0 -135
- package/templates/sandcms/worker/index.ts +0 -1
- package/templates/sandcms/worker/local.ts +0 -1
- package/templates/sandcms/worker/wrangler.jsonc +0 -6
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# SandCMS
|
|
2
2
|
|
|
3
|
-
**0.
|
|
3
|
+
**0.7.0** makes a SandCMS site self-contained: one container and one persistent volume hold the database, image originals, variants and hourly database snapshots. Images are processed on the site with sharp, uploads are chunked and resumable, and Cloudflare is no longer required. Existing sites import their R2 media once with `sandcms media import-r2`. See the [0.7.0 release notes](docs/releases.md#070), [upgrade checklist](docs/upgrades.md#070-upgrade-checklist) and [agent instructions](AGENTS.md).
|
|
4
4
|
|
|
5
5
|
SandCMS embeds a content workspace into a SvelteKit website. Developers own YAML blueprints and public routes; editors manage drafts, publication, images, and form submissions at `/admin`.
|
|
6
6
|
|
|
@@ -8,7 +8,7 @@ This repository contains the `sandcms` package and a working example website. Th
|
|
|
8
8
|
|
|
9
9
|
## Run locally
|
|
10
10
|
|
|
11
|
-
Requires Bun **1.4.
|
|
11
|
+
Requires Bun **1.4.4**. Node is not needed: `bunfig.toml` runs every tool (Vite, SvelteKit, svelte-check, Playwright) on Bun.
|
|
12
12
|
|
|
13
13
|
```sh
|
|
14
14
|
bun install --frozen-lockfile
|
|
@@ -22,7 +22,7 @@ Open **http://localhost:5410/admin**. `dev:init` creates an ignored local enviro
|
|
|
22
22
|
bun run cli user reset-password --email admin@example.test
|
|
23
23
|
```
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
Uploads and image processing work locally with no extra service. Media is stored in `./data/media` next to the database; see [media](docs/media.md).
|
|
26
26
|
|
|
27
27
|
To open the preview from another device over ZeroTier, stop the ordinary dev/preview server and run:
|
|
28
28
|
|
|
@@ -31,7 +31,11 @@ bun run build
|
|
|
31
31
|
bun run preview:network 10.123.59.34 # Use this machine's assigned ZeroTier IPv4 address.
|
|
32
32
|
```
|
|
33
33
|
|
|
34
|
-
Open `https://10.123.59.34:5443/admin` and accept the local certificate prompt. HTTP port 5410 redirects to it. The helper keeps the configured origin, secure cookies, and media delivery on the same HTTPS address, with the website backend bound to loopback.
|
|
34
|
+
Open `https://10.123.59.34:5443/admin` and accept the local certificate prompt. HTTP port 5410 redirects to it. The helper keeps the configured origin, secure cookies, and media delivery on the same HTTPS address, with the website backend bound to loopback. Certificates are generated under ignored `data/preview-tls`; production uses the host's trusted HTTPS certificate. The ordinary localhost environment remains unchanged.
|
|
35
|
+
|
|
36
|
+
## Hosting
|
|
37
|
+
|
|
38
|
+
A site runs as one container built from its `Dockerfile`, with one persistent volume mounted at `/data`, behind any reverse proxy with default settings. Zero-downtime deploys that briefly overlap the old and new container work, and the volume should be backed up on a schedule. We recommend [Dokploy](https://dokploy.com) or [Openship](https://openship.io), which provide all of this; nothing in the package depends on either. See [deployment](docs/deployment.md) for the requirements, environment and backup workflow.
|
|
35
39
|
|
|
36
40
|
## Included
|
|
37
41
|
|
|
@@ -39,9 +43,9 @@ Open `https://10.123.59.34:5443/admin` and accept the local certificate prompt.
|
|
|
39
43
|
- Validated YAML pages, site settings, collections, and form metadata. All planned field types, nested groups, ordered repeatable groups, stable relations, and focused Tiptap rich text.
|
|
40
44
|
- Independent draft/published snapshots, conflict detection, authenticated draft preview, required-field validation, and media readiness gates.
|
|
41
45
|
- Better Auth password sign-in, optional TOTP and recovery codes, temporary-password changes, two roles, and operator recovery. No public registration or email services.
|
|
42
|
-
-
|
|
46
|
+
- Chunked, resumable uploads up to 500 MB (JPEG, PNG, WebP, AVIF, GIF, TIFF, SVG), local processing with sharp, private originals, named versioned variants, sanitized SVG, global media selection, credits, usage warnings, and rebuilds.
|
|
43
47
|
- Developer-owned form actions, honeypot/rate limiting, schema snapshots, read/unread inbox, deletion, and safe CSV exports.
|
|
44
|
-
- Safe setup/upgrade manifests, a frozen SQL baseline and incremental migration runner, doctor,
|
|
48
|
+
- Safe setup/upgrade manifests, a frozen SQL baseline and incremental migration runner, doctor, a starter `Dockerfile` with a health check, volume and site-id checks, hourly verified snapshots, verified live backups, and guarded offline restores.
|
|
45
49
|
|
|
46
50
|
## Package use
|
|
47
51
|
|
|
@@ -52,7 +56,7 @@ bun pm pack --ignore-scripts --filename /tmp/sandcms.tgz
|
|
|
52
56
|
bun dist/cli/index.js setup --cwd /path/to/site --package /tmp/sandcms.tgz
|
|
53
57
|
```
|
|
54
58
|
|
|
55
|
-
For a reproducible local archive installation, use the explicit commands in the [package guide](docs/package.md). Setup previews changes
|
|
59
|
+
For a reproducible local archive installation, use the explicit commands in the [package guide](docs/package.md). Setup previews changes and preserves existing hooks/configuration and customized generated files. Public project routes are written by the website developer.
|
|
56
60
|
|
|
57
61
|
## Verification
|
|
58
62
|
|
|
@@ -65,14 +69,14 @@ bun run test:e2e
|
|
|
65
69
|
bun run test:package
|
|
66
70
|
```
|
|
67
71
|
|
|
68
|
-
Stop the dev server before building. Browser tests use the production Bun server
|
|
72
|
+
Stop the dev server before building. Browser tests use the production Bun server with isolated SQLite and media directories. Package tests install the archive into both a blank directory and an existing site. Tests do not use production resources. See [acceptance evidence and remaining external checks](docs/acceptance.md).
|
|
69
73
|
|
|
70
74
|
## Guides
|
|
71
75
|
|
|
72
76
|
- [Installation and private packaging](docs/package.md)
|
|
73
77
|
- [Blueprints and runtime API](docs/content.md)
|
|
74
78
|
- [Media, publication, and images](docs/media.md)
|
|
75
|
-
- [Cloudflare
|
|
79
|
+
- [Cloudflare: legacy R2 import and optional CDN](docs/cloudflare.md)
|
|
76
80
|
- [Forms and submissions](docs/forms.md)
|
|
77
81
|
- [Deployment, backups, and recovery](docs/deployment.md)
|
|
78
82
|
- [Updates and file ownership](docs/upgrades.md)
|
|
@@ -81,6 +85,6 @@ Stop the dev server before building. Browser tests use the production Bun server
|
|
|
81
85
|
|
|
82
86
|
SandCMS is licensed under the [PolyForm Strict License 1.0.0](LICENSE). See the license for permitted uses and terms.
|
|
83
87
|
|
|
84
|
-
Source is organized into `src/lib/blueprints`, `server`, `admin`, `
|
|
88
|
+
Source is organized into `src/lib/blueprints`, `server`, `admin`, `cli`, and the deprecated `worker`. `src/routes/(site)` demonstrates developer-owned pages; `(sandcms)` is the thin integration layer. Never commit content databases, secrets, or bootstrap passwords.
|
|
85
89
|
|
|
86
90
|
Agents can discover blueprints and map existing site content through the [authenticated content API](docs/api.md), with expiring Better Auth API keys and idempotent content writes.
|
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import * as Card from './components/ui/card/index.js';
|
|
3
|
+
import * as Dialog from './components/ui/dialog/index.js';
|
|
3
4
|
import Notice from './Notice.svelte';
|
|
4
5
|
import ApiKeys from './ApiKeys.svelte';
|
|
6
|
+
import ThemePicker from './ThemePicker.svelte';
|
|
5
7
|
import { untrack } from 'svelte';
|
|
6
8
|
import type { AdminData } from './types.js';
|
|
7
|
-
import { authClient, message } from './client.js';
|
|
9
|
+
import { authClient, copyText, message } from './client.js';
|
|
8
10
|
import { Button } from './components/ui/button/index.js';
|
|
9
11
|
import { Input } from './components/ui/input/index.js';
|
|
10
12
|
import { Label } from './components/ui/label/index.js';
|
|
13
|
+
import { Badge } from './components/ui/badge/index.js';
|
|
14
|
+
import ShieldCheck from '@lucide/svelte/icons/shield-check';
|
|
15
|
+
import Copy from '@lucide/svelte/icons/copy';
|
|
16
|
+
import Check from '@lucide/svelte/icons/check';
|
|
17
|
+
import * as InputOTP from './components/ui/input-otp/index.js';
|
|
18
|
+
import QRCode from 'qrcode';
|
|
11
19
|
let { data }: { data: AdminData } = $props();
|
|
12
20
|
let current = $state(''),
|
|
13
21
|
password = $state(''),
|
|
@@ -17,9 +25,35 @@
|
|
|
17
25
|
uri = $state(''),
|
|
18
26
|
codes = $state<string[]>([]),
|
|
19
27
|
enabled = $state(untrack(() => !!data.user?.twoFactorEnabled)),
|
|
28
|
+
setupOpen = $state(false),
|
|
29
|
+
disableOpen = $state(false),
|
|
30
|
+
step = $state(1),
|
|
20
31
|
busy = $state(false),
|
|
21
32
|
error = $state(''),
|
|
22
|
-
notice = $state('')
|
|
33
|
+
notice = $state(''),
|
|
34
|
+
dialogError = $state('');
|
|
35
|
+
const secret = $derived(uri ? (new URL(uri).searchParams.get('secret') ?? '') : '');
|
|
36
|
+
let qrUrl = $state('');
|
|
37
|
+
$effect(() => {
|
|
38
|
+
const target = uri;
|
|
39
|
+
if (!target) {
|
|
40
|
+
qrUrl = '';
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
QRCode.toDataURL(target, { width: 176, margin: 1 }).then((url) => {
|
|
44
|
+
if (target === uri) qrUrl = url;
|
|
45
|
+
});
|
|
46
|
+
});
|
|
47
|
+
let copied = $state(false);
|
|
48
|
+
async function copySecret() {
|
|
49
|
+
try {
|
|
50
|
+
await copyText(secret);
|
|
51
|
+
copied = true;
|
|
52
|
+
setTimeout(() => (copied = false), 2000);
|
|
53
|
+
} catch (e) {
|
|
54
|
+
dialogError = message(e);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
23
57
|
async function change() {
|
|
24
58
|
busy = true;
|
|
25
59
|
error = '';
|
|
@@ -44,40 +78,62 @@
|
|
|
44
78
|
busy = false;
|
|
45
79
|
}
|
|
46
80
|
}
|
|
47
|
-
|
|
81
|
+
function resetSetup() {
|
|
82
|
+
setupOpen = false;
|
|
83
|
+
step = 1;
|
|
84
|
+
twoFactorPassword = '';
|
|
85
|
+
code = '';
|
|
86
|
+
uri = '';
|
|
87
|
+
codes = [];
|
|
88
|
+
dialogError = '';
|
|
89
|
+
}
|
|
90
|
+
async function startSetup() {
|
|
48
91
|
busy = true;
|
|
49
|
-
|
|
92
|
+
dialogError = '';
|
|
50
93
|
try {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
} else {
|
|
57
|
-
const r = await authClient.twoFactor.enable({ password: twoFactorPassword });
|
|
58
|
-
if (r.error) throw new Error(r.error.message);
|
|
59
|
-
if (!r.data || !('totpURI' in r.data)) throw new Error('TOTP setup unavailable');
|
|
60
|
-
uri = r.data.totpURI;
|
|
61
|
-
codes = r.data.backupCodes;
|
|
62
|
-
}
|
|
94
|
+
const r = await authClient.twoFactor.enable({ password: twoFactorPassword });
|
|
95
|
+
if (r.error) throw new Error(r.error.message);
|
|
96
|
+
if (!r.data || !('totpURI' in r.data)) throw new Error('TOTP setup unavailable');
|
|
97
|
+
uri = r.data.totpURI;
|
|
98
|
+
codes = r.data.backupCodes;
|
|
63
99
|
twoFactorPassword = '';
|
|
100
|
+
step = 2;
|
|
64
101
|
} catch (e) {
|
|
65
|
-
|
|
102
|
+
dialogError = message(e);
|
|
66
103
|
} finally {
|
|
67
104
|
busy = false;
|
|
68
105
|
}
|
|
69
106
|
}
|
|
70
107
|
async function verify() {
|
|
108
|
+
if (busy) return;
|
|
71
109
|
busy = true;
|
|
72
|
-
|
|
110
|
+
dialogError = '';
|
|
73
111
|
try {
|
|
74
112
|
const r = await authClient.twoFactor.verifyTotp({ code });
|
|
75
113
|
if (r.error) throw new Error(r.error.message);
|
|
76
114
|
enabled = true;
|
|
77
|
-
|
|
78
|
-
notice = 'Two-factor authentication enabled. Keep your recovery codes safe.';
|
|
115
|
+
step = 3;
|
|
79
116
|
} catch (e) {
|
|
80
|
-
|
|
117
|
+
dialogError = message(e);
|
|
118
|
+
} finally {
|
|
119
|
+
busy = false;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
function finishSetup() {
|
|
123
|
+
resetSetup();
|
|
124
|
+
}
|
|
125
|
+
async function disable() {
|
|
126
|
+
busy = true;
|
|
127
|
+
dialogError = '';
|
|
128
|
+
try {
|
|
129
|
+
const r = await authClient.twoFactor.disable({ password: twoFactorPassword });
|
|
130
|
+
if (r.error) throw new Error(r.error.message);
|
|
131
|
+
enabled = false;
|
|
132
|
+
twoFactorPassword = '';
|
|
133
|
+
disableOpen = false;
|
|
134
|
+
notice = 'Two-factor authentication disabled.';
|
|
135
|
+
} catch (e) {
|
|
136
|
+
dialogError = message(e);
|
|
81
137
|
} finally {
|
|
82
138
|
busy = false;
|
|
83
139
|
}
|
|
@@ -90,11 +146,18 @@
|
|
|
90
146
|
a.click();
|
|
91
147
|
URL.revokeObjectURL(url);
|
|
92
148
|
}
|
|
149
|
+
async function copyCodes() {
|
|
150
|
+
try {
|
|
151
|
+
await copyText(codes.join('\n'));
|
|
152
|
+
notice = 'Recovery codes copied.';
|
|
153
|
+
} catch (e) {
|
|
154
|
+
dialogError = message(e);
|
|
155
|
+
}
|
|
156
|
+
}
|
|
93
157
|
</script>
|
|
94
158
|
|
|
95
159
|
<div class="cms-page-heading">
|
|
96
160
|
<div>
|
|
97
|
-
<div class="cms-eyebrow">YOUR ACCOUNT</div>
|
|
98
161
|
<h1>{data.user?.mustChangePassword ? 'Set your own password' : 'Account & security'}</h1>
|
|
99
162
|
<p class="cms-muted">
|
|
100
163
|
{data.user?.mustChangePassword
|
|
@@ -104,9 +167,9 @@
|
|
|
104
167
|
</div>
|
|
105
168
|
</div>
|
|
106
169
|
{#if error}<Notice error>{error}</Notice>{/if}{#if notice}<Notice>{notice}</Notice>{/if}
|
|
107
|
-
<div class="cms-
|
|
108
|
-
<Card.Root class="cms-detail-card">
|
|
109
|
-
<h2>
|
|
170
|
+
<div class="cms-settings">
|
|
171
|
+
<Card.Root class="cms-detail-card cms-settings-card">
|
|
172
|
+
<div class="cms-settings-header"><h2>Password</h2></div>
|
|
110
173
|
<form
|
|
111
174
|
class="cms-stack"
|
|
112
175
|
onsubmit={(e) => {
|
|
@@ -123,71 +186,211 @@
|
|
|
123
186
|
required
|
|
124
187
|
/>
|
|
125
188
|
</div>
|
|
126
|
-
<div class="cms-
|
|
127
|
-
<
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
189
|
+
<div class="cms-settings-row">
|
|
190
|
+
<div class="cms-field">
|
|
191
|
+
<Label for="new-password">New password</Label><Input
|
|
192
|
+
id="new-password"
|
|
193
|
+
type="password"
|
|
194
|
+
autocomplete="new-password"
|
|
195
|
+
bind:value={password}
|
|
196
|
+
minlength={12}
|
|
197
|
+
maxlength={128}
|
|
198
|
+
required
|
|
199
|
+
/>
|
|
200
|
+
</div>
|
|
201
|
+
<div class="cms-field">
|
|
202
|
+
<Label for="confirm-password">Confirm new password</Label><Input
|
|
203
|
+
id="confirm-password"
|
|
204
|
+
type="password"
|
|
205
|
+
autocomplete="new-password"
|
|
206
|
+
bind:value={confirmation}
|
|
207
|
+
minlength={12}
|
|
208
|
+
required
|
|
209
|
+
/>
|
|
210
|
+
</div>
|
|
136
211
|
</div>
|
|
137
|
-
<div class="cms-
|
|
138
|
-
<
|
|
139
|
-
id="confirm-password"
|
|
140
|
-
type="password"
|
|
141
|
-
autocomplete="new-password"
|
|
142
|
-
bind:value={confirmation}
|
|
143
|
-
minlength={12}
|
|
144
|
-
required
|
|
145
|
-
/>
|
|
212
|
+
<div class="cms-settings-actions">
|
|
213
|
+
<Button type="submit" disabled={busy}>Change password</Button>
|
|
146
214
|
</div>
|
|
147
|
-
<Button type="submit" disabled={busy}>Change password</Button>
|
|
148
215
|
</form>
|
|
149
216
|
</Card.Root>
|
|
150
|
-
{#if !data.user?.mustChangePassword}<Card.Root class="cms-detail-card">
|
|
151
|
-
<
|
|
152
|
-
|
|
153
|
-
{enabled
|
|
154
|
-
|
|
155
|
-
:
|
|
156
|
-
</
|
|
157
|
-
{#if
|
|
158
|
-
|
|
159
|
-
<
|
|
160
|
-
<
|
|
161
|
-
<
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
217
|
+
{#if !data.user?.mustChangePassword}<Card.Root class="cms-detail-card cms-settings-card">
|
|
218
|
+
<div class="cms-settings-header">
|
|
219
|
+
<h2>Two-factor authentication</h2>
|
|
220
|
+
{#if enabled}<Button variant="outline" size="sm" onclick={() => (disableOpen = true)}
|
|
221
|
+
>Disable</Button
|
|
222
|
+
>{:else}<Badge variant="outline">Off</Badge>{/if}
|
|
223
|
+
</div>
|
|
224
|
+
{#if enabled}
|
|
225
|
+
<div class="cms-empty cms-empty-large cms-protected">
|
|
226
|
+
<ShieldCheck size={36} />
|
|
227
|
+
<h3>Account protected</h3>
|
|
228
|
+
<p>A code from your authenticator app is required at sign-in.</p>
|
|
229
|
+
</div>
|
|
230
|
+
{:else}
|
|
231
|
+
<div class="cms-empty cms-empty-large">
|
|
232
|
+
<ShieldCheck size={36} />
|
|
233
|
+
<h3>Protect your account</h3>
|
|
234
|
+
<p>Require a one-time code from an authenticator app each time you sign in.</p>
|
|
235
|
+
<Button onclick={() => (setupOpen = true)}>Set up two-factor</Button>
|
|
236
|
+
</div>
|
|
237
|
+
{/if}
|
|
238
|
+
</Card.Root>{/if}
|
|
239
|
+
{#if !data.user?.mustChangePassword}<ThemePicker />{/if}
|
|
240
|
+
{#if data.user?.role === 'admin' && !data.user.mustChangePassword}<ApiKeys />{/if}
|
|
241
|
+
</div>
|
|
242
|
+
|
|
243
|
+
<Dialog.Root
|
|
244
|
+
bind:open={setupOpen}
|
|
245
|
+
onOpenChange={(open) => {
|
|
246
|
+
if (!open) resetSetup();
|
|
247
|
+
}}
|
|
248
|
+
>
|
|
249
|
+
<Dialog.Content portalProps={{ disabled: true }}>
|
|
250
|
+
{#if step === 1}
|
|
251
|
+
<Dialog.Header>
|
|
252
|
+
<Dialog.Description>Step 1 of 3</Dialog.Description>
|
|
253
|
+
<Dialog.Title>Confirm your password</Dialog.Title>
|
|
254
|
+
</Dialog.Header>
|
|
255
|
+
<form
|
|
256
|
+
class="cms-setup"
|
|
257
|
+
onsubmit={(e) => {
|
|
258
|
+
e.preventDefault();
|
|
259
|
+
startSetup();
|
|
260
|
+
}}
|
|
261
|
+
>
|
|
262
|
+
<div class="cms-field">
|
|
263
|
+
<Label for="2fa-password">Password</Label>
|
|
264
|
+
<Input
|
|
175
265
|
id="2fa-password"
|
|
176
266
|
type="password"
|
|
177
267
|
autocomplete="current-password"
|
|
178
268
|
bind:value={twoFactorPassword}
|
|
179
269
|
required
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
<
|
|
185
|
-
<
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
</
|
|
270
|
+
/>
|
|
271
|
+
</div>
|
|
272
|
+
{#if dialogError}<Notice error>{dialogError}</Notice>{/if}
|
|
273
|
+
<Dialog.Footer>
|
|
274
|
+
<Button variant="outline" onclick={() => (setupOpen = false)}>Cancel</Button>
|
|
275
|
+
<Button type="submit" disabled={busy}>Continue</Button>
|
|
276
|
+
</Dialog.Footer>
|
|
277
|
+
</form>
|
|
278
|
+
{:else if step === 2}
|
|
279
|
+
<Dialog.Header>
|
|
280
|
+
<Dialog.Description>Step 2 of 3</Dialog.Description>
|
|
281
|
+
<Dialog.Title>Add to your authenticator</Dialog.Title>
|
|
282
|
+
</Dialog.Header>
|
|
283
|
+
<div class="cms-setup">
|
|
284
|
+
<div class="cms-qr">
|
|
285
|
+
{#if qrUrl}<img
|
|
286
|
+
src={qrUrl}
|
|
287
|
+
width="176"
|
|
288
|
+
height="176"
|
|
289
|
+
alt="Scan with your authenticator app"
|
|
290
|
+
/>{/if}
|
|
291
|
+
<p class="cms-muted">Scan this code with your authenticator app.</p>
|
|
292
|
+
</div>
|
|
293
|
+
<div class="cms-setup-key">
|
|
294
|
+
<span class="cms-muted">Setup code</span>
|
|
295
|
+
<div class="cms-secret-row">
|
|
296
|
+
<code class="cms-secret">{secret}</code>
|
|
297
|
+
<Button
|
|
298
|
+
class="cms-copy"
|
|
299
|
+
variant="ghost"
|
|
300
|
+
size="icon-sm"
|
|
301
|
+
aria-label={copied ? 'Setup code copied' : 'Copy setup code'}
|
|
302
|
+
onclick={copySecret}
|
|
303
|
+
>{#if copied}<Check />{:else}<Copy />{/if}</Button
|
|
304
|
+
>
|
|
305
|
+
</div>
|
|
306
|
+
</div>
|
|
307
|
+
<form
|
|
308
|
+
class="cms-setup"
|
|
309
|
+
onsubmit={(e) => {
|
|
310
|
+
e.preventDefault();
|
|
311
|
+
verify();
|
|
312
|
+
}}
|
|
313
|
+
>
|
|
314
|
+
<div class="cms-field">
|
|
315
|
+
<Label for="totp">Enter the 6-digit code</Label>
|
|
316
|
+
<InputOTP.Root
|
|
317
|
+
inputId="totp"
|
|
318
|
+
maxlength={6}
|
|
319
|
+
inputmode="numeric"
|
|
320
|
+
autocomplete="one-time-code"
|
|
321
|
+
bind:value={code}
|
|
322
|
+
onComplete={verify}
|
|
323
|
+
>
|
|
324
|
+
{#snippet children({ cells })}
|
|
325
|
+
<InputOTP.Group class="cms-otp">
|
|
326
|
+
{#each cells as cell (cell)}<InputOTP.Slot {cell} />{/each}
|
|
327
|
+
</InputOTP.Group>
|
|
328
|
+
{/snippet}
|
|
329
|
+
</InputOTP.Root>
|
|
330
|
+
</div>
|
|
331
|
+
{#if dialogError}<Notice error>{dialogError}</Notice>{/if}
|
|
332
|
+
<Dialog.Footer>
|
|
333
|
+
<Button variant="outline" onclick={() => (setupOpen = false)}>Cancel</Button>
|
|
334
|
+
<Button type="submit" disabled={busy}>Verify and continue</Button>
|
|
335
|
+
</Dialog.Footer>
|
|
336
|
+
</form>
|
|
337
|
+
</div>
|
|
338
|
+
{:else}
|
|
339
|
+
<Dialog.Header>
|
|
340
|
+
<Dialog.Description>Step 3 of 3</Dialog.Description>
|
|
341
|
+
<Dialog.Title>Save your recovery codes</Dialog.Title>
|
|
342
|
+
</Dialog.Header>
|
|
343
|
+
<div class="cms-recovery">
|
|
344
|
+
<p class="cms-muted">Store these privately. Each code can be used once.</p>
|
|
345
|
+
<ul class="cms-recovery-codes">
|
|
346
|
+
{#each codes as recoveryCode (recoveryCode)}<li><code>{recoveryCode}</code></li>{/each}
|
|
347
|
+
</ul>
|
|
348
|
+
<Dialog.Footer>
|
|
349
|
+
<Button variant="outline" onclick={copyCodes}>Copy</Button>
|
|
350
|
+
<Button variant="outline" onclick={download}>Download</Button>
|
|
351
|
+
<Button onclick={finishSetup}>Done</Button>
|
|
352
|
+
</Dialog.Footer>
|
|
353
|
+
</div>
|
|
354
|
+
{/if}
|
|
355
|
+
</Dialog.Content>
|
|
356
|
+
</Dialog.Root>
|
|
192
357
|
|
|
193
|
-
|
|
358
|
+
<Dialog.Root
|
|
359
|
+
bind:open={disableOpen}
|
|
360
|
+
onOpenChange={(open) => {
|
|
361
|
+
if (!open) {
|
|
362
|
+
twoFactorPassword = '';
|
|
363
|
+
dialogError = '';
|
|
364
|
+
}
|
|
365
|
+
}}
|
|
366
|
+
>
|
|
367
|
+
<Dialog.Content portalProps={{ disabled: true }}>
|
|
368
|
+
<Dialog.Header>
|
|
369
|
+
<Dialog.Title>Disable two-factor authentication</Dialog.Title>
|
|
370
|
+
<Dialog.Description>Confirm your password to turn off codes at sign-in.</Dialog.Description>
|
|
371
|
+
</Dialog.Header>
|
|
372
|
+
<form
|
|
373
|
+
class="cms-setup"
|
|
374
|
+
onsubmit={(e) => {
|
|
375
|
+
e.preventDefault();
|
|
376
|
+
disable();
|
|
377
|
+
}}
|
|
378
|
+
>
|
|
379
|
+
<div class="cms-field">
|
|
380
|
+
<Label for="disable-2fa-password">Password</Label>
|
|
381
|
+
<Input
|
|
382
|
+
id="disable-2fa-password"
|
|
383
|
+
type="password"
|
|
384
|
+
autocomplete="current-password"
|
|
385
|
+
bind:value={twoFactorPassword}
|
|
386
|
+
required
|
|
387
|
+
/>
|
|
388
|
+
</div>
|
|
389
|
+
{#if dialogError}<Notice error>{dialogError}</Notice>{/if}
|
|
390
|
+
<Dialog.Footer>
|
|
391
|
+
<Button variant="outline" onclick={() => (disableOpen = false)}>Cancel</Button>
|
|
392
|
+
<Button type="submit" variant="destructive" disabled={busy}>Disable</Button>
|
|
393
|
+
</Dialog.Footer>
|
|
394
|
+
</form>
|
|
395
|
+
</Dialog.Content>
|
|
396
|
+
</Dialog.Root>
|
package/dist/admin/Admin.svelte
CHANGED
|
@@ -11,7 +11,20 @@
|
|
|
11
11
|
import Inbox from './Inbox.svelte';
|
|
12
12
|
import Users from './Users.svelte';
|
|
13
13
|
import Account from './Account.svelte';
|
|
14
|
+
import { setContext, untrack } from 'svelte';
|
|
15
|
+
import { persistTheme, type Theme } from './theme.js';
|
|
16
|
+
import { themeContext, type ThemeState } from './theme-context.js';
|
|
14
17
|
let { data }: { data: AdminData } = $props();
|
|
18
|
+
let theme = $state<Theme>(untrack(() => data.theme ?? 'system'));
|
|
19
|
+
setContext<ThemeState>(themeContext, {
|
|
20
|
+
get current() {
|
|
21
|
+
return theme;
|
|
22
|
+
},
|
|
23
|
+
set(next) {
|
|
24
|
+
theme = next;
|
|
25
|
+
persistTheme(next);
|
|
26
|
+
}
|
|
27
|
+
});
|
|
15
28
|
</script>
|
|
16
29
|
|
|
17
30
|
<svelte:head
|
|
@@ -20,7 +33,7 @@
|
|
|
20
33
|
content="noindex,nofollow"
|
|
21
34
|
/></svelte:head
|
|
22
35
|
>
|
|
23
|
-
<div class="sandcms-admin">
|
|
36
|
+
<div class="sandcms-admin" data-theme={theme}>
|
|
24
37
|
<a class="cms-skip" href="#cms-main">Skip to content</a>{#if data.screen === 'login'}<Login
|
|
25
38
|
emailEnabled={data.emailEnabled}
|
|
26
39
|
next={data.next}
|