@janga/norna 0.7.9 → 0.7.10
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 +1 -1
- package/docs/README.md +14 -11
- package/docs/configuration.md +9 -54
- package/docs/content.md +6 -7
- package/docs/design/norna-diagram-design.md +2 -0
- package/docs/getting-started.md +18 -16
- package/docs/routes.md +7 -6
- package/docs/site-structure.md +4 -2
- package/docs/sitewide-content.md +74 -0
- package/docs/theme.md +61 -128
- package/docs/typography.md +45 -33
- package/examples/001-dog-shelter-single-page/README.md +9 -0
- package/examples/001-dog-shelter-single-page/site/config.mjs +27 -0
- package/examples/001-dog-shelter-single-page/site/content.md +38 -0
- package/examples/001-dog-shelter-single-page/site/images/what-we-do/dog-house.svg +25 -0
- package/examples/001-dog-shelter-single-page/site/images/you-can-help/heart.svg +13 -0
- package/examples/001-dog-shelter-single-page/site/public/favicon.svg +10 -0
- package/examples/001-dog-shelter-single-page/site/public/robots.txt +2 -0
- package/examples/001-dog-shelter-single-page/site/sitewide-content.md +6 -0
- package/examples/001-dog-shelter-single-page/site/theme.md +25 -0
- package/examples/002-dog-shelter-multi-page/README.md +9 -0
- package/examples/002-dog-shelter-multi-page/site/config.mjs +27 -0
- package/examples/002-dog-shelter-multi-page/site/content.md +12 -0
- package/examples/002-dog-shelter-multi-page/site/public/favicon.svg +10 -0
- package/examples/002-dog-shelter-multi-page/site/public/robots.txt +2 -0
- package/examples/002-dog-shelter-multi-page/site/routes/010-dogs/images/dogs/rex.svg +19 -0
- package/examples/002-dog-shelter-multi-page/site/routes/010-dogs/images/dogs/rover.svg +19 -0
- package/examples/002-dog-shelter-multi-page/site/routes/010-dogs/route-content.md +30 -0
- package/examples/002-dog-shelter-multi-page/site/routes/020-adopt/route-content.md +12 -0
- package/examples/002-dog-shelter-multi-page/site/sitewide-content.md +6 -0
- package/examples/002-dog-shelter-multi-page/site/theme.md +25 -0
- package/examples/dog-gallery/.astro/collections/site.schema.json +776 -0
- package/examples/dog-gallery/.astro/collections/theme.schema.json +672 -0
- package/examples/dog-gallery/.astro/content-assets.mjs +4 -0
- package/examples/dog-gallery/.astro/content-modules.mjs +1 -0
- package/examples/dog-gallery/.astro/content.d.ts +175 -0
- package/examples/dog-gallery/.astro/data-store.json +1 -0
- package/examples/dog-gallery/.astro/dev-local.json +8 -0
- package/examples/dog-gallery/.astro/dev.json +13 -0
- package/examples/dog-gallery/.astro/dev.log +95 -0
- package/examples/dog-gallery/.astro/settings.json +5 -0
- package/examples/dog-gallery/.astro/types.d.ts +2 -0
- package/examples/dog-gallery/dist/_astro/GalleryGrid.astro_astro_type_script_index_0_lang.B0kxDyGz.js +1 -0
- package/examples/dog-gallery/dist/_astro/SitePage.DicGh_5N.css +1 -0
- package/examples/dog-gallery/dist/dog-care/index.html +15 -0
- package/examples/dog-gallery/dist/dog-shelter-logo.svg +14 -0
- package/examples/dog-gallery/dist/favicon.svg +7 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/black-puppy-meadow-7255e3d9-1080.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/black-puppy-meadow-7255e3d9-1440.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/black-puppy-meadow-7255e3d9-1536.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/black-puppy-meadow-7255e3d9-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/black-puppy-meadow-7255e3d9-768.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/photo-of-a-black-dog-5cf614d2-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/photo-of-a-black-dog-5cf614d2-768.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/black-dogs/photo-of-a-black-dog-5cf614d2-960.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/brown-dog-50ef114e-1080.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/brown-dog-50ef114e-1440.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/brown-dog-50ef114e-1920.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/brown-dog-50ef114e-3939.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/brown-dog-50ef114e-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/brown-dog-50ef114e-768.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/dog-accompanies-master-7ef804d5-1080.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/dog-accompanies-master-7ef804d5-1440.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/dog-accompanies-master-7ef804d5-1920.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/dog-accompanies-master-7ef804d5-2400.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/dog-accompanies-master-7ef804d5-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/brown-dogs/dog-accompanies-master-7ef804d5-768.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/golden-retriever-f797fd88-1080.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/golden-retriever-f797fd88-1440.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/golden-retriever-f797fd88-1600.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/golden-retriever-f797fd88-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/golden-retriever-f797fd88-768.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/toller-puppy-a2a8fbc0-1080.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/toller-puppy-a2a8fbc0-1440.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/toller-puppy-a2a8fbc0-1920.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/toller-puppy-a2a8fbc0-2576.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/toller-puppy-a2a8fbc0-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/golden-dogs/toller-puppy-a2a8fbc0-768.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-cute-dog-077a0689-1080.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-cute-dog-077a0689-1277.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-cute-dog-077a0689-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-cute-dog-077a0689-768.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-puppy-garden-d3ab2ca0-1080.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-puppy-garden-d3ab2ca0-1440.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-puppy-garden-d3ab2ca0-1536.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-puppy-garden-d3ab2ca0-480.webp +0 -0
- package/examples/dog-gallery/dist/images/generated/white-dogs/white-puppy-garden-d3ab2ca0-768.webp +0 -0
- package/examples/dog-gallery/dist/index.html +45 -0
- package/examples/dog-gallery/dist/robots.txt +2 -0
- package/examples/dog-gallery/node_modules/.vite/deps/_metadata.json +7 -7
- package/examples/dog-gallery/site/.norna/generated-images.json +8 -8
- package/examples/dog-gallery/site/config.mjs +0 -20
- package/examples/dog-gallery/site/content.md +4 -5
- package/examples/dog-gallery/site/public/logo.svg +14 -0
- package/examples/dog-gallery/site/sitewide-content.md +16 -0
- package/examples/dog-gallery/site/theme.md +13 -24
- package/examples/presentation/README.md +15 -0
- package/examples/presentation/site/.norna/generated-images.json +66 -0
- package/examples/presentation/site/config.mjs +29 -0
- package/examples/presentation/site/content.md +67 -0
- package/examples/presentation/site/public/robots.txt +2 -0
- package/examples/presentation/site/routes/010-presets/route-content.md +63 -0
- package/examples/presentation/site/routes/010-presets/theme.md +4 -0
- package/examples/presentation/site/routes/020-media/images/cards/card-carousel.svg +11 -0
- package/examples/presentation/site/routes/020-media/images/cards/card-stack.svg +9 -0
- package/examples/presentation/site/routes/020-media/images/cards/card-surfaces.svg +8 -0
- package/examples/presentation/site/routes/020-media/images/carousel/carousel-one.svg +8 -0
- package/examples/presentation/site/routes/020-media/images/carousel/carousel-three.svg +13 -0
- package/examples/presentation/site/routes/020-media/images/carousel/carousel-two.svg +8 -0
- package/examples/presentation/site/routes/020-media/images/stack/stack-one.svg +8 -0
- package/examples/presentation/site/routes/020-media/images/stack/stack-two.svg +9 -0
- package/examples/presentation/site/routes/020-media/route-content.md +77 -0
- package/examples/presentation/site/routes/020-media/theme.md +4 -0
- package/examples/presentation/site/routes/030-surfaces/route-content.md +44 -0
- package/examples/presentation/site/routes/030-surfaces/theme.md +7 -0
- package/examples/presentation/site/sitewide-content.md +6 -0
- package/examples/presentation/site/theme.md +43 -0
- package/examples/typography-presets/.astro/collections/routeTheme.schema.json +746 -0
- package/examples/typography-presets/.astro/collections/site.schema.json +0 -717
- package/examples/typography-presets/.astro/collections/sitewide.schema.json +114 -0
- package/examples/typography-presets/.astro/collections/theme.schema.json +161 -59
- package/examples/typography-presets/.astro/content.d.ts +8 -0
- package/examples/typography-presets/.astro/data-store.json +1 -1
- package/examples/typography-presets/.astro/dev-local.json +2 -2
- package/examples/typography-presets/.astro/dev.json +2 -2
- package/examples/typography-presets/.astro/dev.log +37 -16
- package/examples/typography-presets/site/.norna/generated-images.json +76 -76
- package/examples/typography-presets/site/config.mjs +0 -13
- package/examples/typography-presets/site/content.md +8 -126
- package/examples/typography-presets/site/routes/010-quiet-gallery/route-content.md +34 -0
- package/examples/typography-presets/site/routes/010-quiet-gallery/theme.md +4 -0
- package/examples/typography-presets/site/routes/020-compact-gallery/route-content.md +33 -0
- package/examples/typography-presets/site/routes/020-compact-gallery/theme.md +4 -0
- package/examples/typography-presets/site/routes/030-text-forward/route-content.md +34 -0
- package/examples/typography-presets/site/routes/030-text-forward/theme.md +4 -0
- package/examples/typography-presets/site/routes/040-statement/route-content.md +34 -0
- package/examples/typography-presets/site/routes/040-statement/theme.md +4 -0
- package/examples/typography-presets/site/sitewide-content.md +14 -0
- package/examples/typography-presets/site/theme.md +9 -9
- package/fixtures/basic/site/config.mjs +0 -13
- package/fixtures/basic/site/sitewide-content.md +12 -0
- package/fixtures/basic/site/theme.md +2 -2
- package/fixtures/content-model-v2/site/content.md +2 -5
- package/fixtures/content-model-v2/site/theme.md +1 -3
- package/package.json +3 -2
- package/scripts/check-config.mjs +22 -1
- package/scripts/lib/frontmatter-yaml.mjs +28 -0
- package/scripts/lib/logo-assets.mjs +35 -0
- package/scripts/lib/norna-markdown-blocks.mjs +166 -0
- package/scripts/lib/presentation.mjs +104 -46
- package/scripts/lib/project-config.mjs +67 -105
- package/scripts/lib/site-content.mjs +26 -118
- package/scripts/lib/site-paths.mjs +2 -0
- package/scripts/lib/sitewide-config.mjs +34 -0
- package/scripts/lib/theme-config.mjs +72 -8
- package/scripts/lib/typography.mjs +20 -26
- package/scripts/show-typography.mjs +40 -147
- package/scripts/sync-content-sections.mjs +19 -17
- package/scripts/test-content-check.mjs +59 -27
- package/scripts/test-content-model-v2.mjs +154 -0
- package/scripts/test-engine-commands.mjs +3 -1
- package/scripts/test-package-check.mjs +66 -24
- package/scripts/test-temporary-visibility.mjs +19 -2
- package/src/components/CardList.astro +5 -2
- package/src/components/GalleryGrid.astro +37 -16
- package/src/components/SiteBanners.astro +100 -0
- package/src/components/SiteNavigation.astro +48 -31
- package/src/components/SitePage.astro +55 -13
- package/src/components/SiteSection.astro +193 -35
- package/src/content.config.ts +78 -48
- package/src/layouts/BaseLayout.astro +64 -14
- package/src/lib/routeThemes.ts +61 -0
- package/src/lib/sectionContent.ts +235 -51
- package/src/lib/sitePublicAssets.ts +1 -0
- package/src/styles/global.css +282 -93
- package/starters/basic/.github/workflows/deploy.yml +1 -1
- package/starters/basic/README.md +7 -6
- package/starters/basic/site/config.mjs +0 -13
- package/starters/basic/site/content.md +1 -1
- package/starters/basic/site/sitewide-content.md +14 -0
- package/starters/basic/site/theme.md +13 -24
- package/starters/project/.github/workflows/deploy.yml +1 -1
- package/starters/project/README.md +10 -8
- package/starters/project/site/config.mjs +0 -13
- package/starters/project/site/sitewide-content.md +14 -0
- package/starters/project/site/theme.md +3 -11
- /package/examples/typography-presets/site/{images → routes/010-quiet-gallery/images}/quiet-gallery/puppy-portrait.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/010-quiet-gallery/images}/quiet-gallery/shepherd-portrait.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/010-quiet-gallery/images}/quiet-gallery/white-puppy.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/020-compact-gallery/images}/compact-gallery/black-schnauzer.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/020-compact-gallery/images}/compact-gallery/retriever-portrait.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/020-compact-gallery/images}/compact-gallery/schnauzer-portrait.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/030-text-forward/images}/text-forward/boxer-portrait.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/030-text-forward/images}/text-forward/grass-puppy.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/030-text-forward/images}/text-forward/grey-street-dog.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/040-statement/images}/statement/black-pedigree.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/040-statement/images}/statement/sheepdog-grass.jpg +0 -0
- /package/examples/typography-presets/site/{images → routes/040-statement/images}/statement/sheepdog-wide.jpg +0 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Statement
|
|
3
|
+
description: A stronger typography preset for short declarative content.
|
|
4
|
+
navigation:
|
|
5
|
+
label: Statement
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## Statement {#statement}
|
|
9
|
+
|
|
10
|
+
This route uses the `statement` preset. Its purpose is to make short,
|
|
11
|
+
declarative sections feel more direct and programmatic. It is intentionally
|
|
12
|
+
stronger than the other presets and should usually be used sparingly.
|
|
13
|
+
|
|
14
|
+
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec id elit non mi
|
|
15
|
+
porta gravida at eget metus. Integer posuere erat a ante venenatis dapibus
|
|
16
|
+
posuere velit aliquet.
|
|
17
|
+
|
|
18
|
+
### Short emphasis
|
|
19
|
+
|
|
20
|
+
Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Aenean
|
|
21
|
+
lacinia bibendum nulla sed consectetur. Maecenas sed diam eget risus varius
|
|
22
|
+
blandit sit amet non magna.
|
|
23
|
+
|
|
24
|
+
```norna-image-stack
|
|
25
|
+
- image: sheepdog-grass.jpg
|
|
26
|
+
alt: A sheepdog puppy sitting in green grass.
|
|
27
|
+
caption: Sheepdog puppy in grass. Photo by Bicanski, CC0, via Pixnio.
|
|
28
|
+
- image: sheepdog-wide.jpg
|
|
29
|
+
alt: A sheepdog puppy lying outdoors.
|
|
30
|
+
caption: Sheepdog puppy outdoors. Photo by Bicanski, CC0, via Pixnio.
|
|
31
|
+
- image: black-pedigree.jpg
|
|
32
|
+
alt: A black dog standing in grass.
|
|
33
|
+
caption: Black pedigree dog portrait. Photo by Bicanski, CC0, via Pixnio.
|
|
34
|
+
```
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
---
|
|
2
|
+
navigation:
|
|
3
|
+
brand: Typography Presets
|
|
4
|
+
footer:
|
|
5
|
+
copyrightMessage: Dog photos by Bicanski, CC0, via Pixnio.
|
|
6
|
+
buildInfo:
|
|
7
|
+
enabled: true
|
|
8
|
+
text: Built
|
|
9
|
+
dateTimeFormat:
|
|
10
|
+
locale: en-GB
|
|
11
|
+
timeZone: UTC
|
|
12
|
+
dateStyle: short
|
|
13
|
+
timeStyle: short
|
|
14
|
+
---
|
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
---
|
|
2
|
-
navigation:
|
|
3
|
-
brand: Typography Presets
|
|
4
2
|
layout:
|
|
5
3
|
density: normal
|
|
6
4
|
pageWidth: 1320px
|
|
@@ -17,9 +15,12 @@ layout:
|
|
|
17
15
|
finalSectionBottom:
|
|
18
16
|
desktop: clamp(2rem, 4vw, 3.5rem)
|
|
19
17
|
mobile: 2rem
|
|
20
|
-
|
|
21
|
-
desktop:
|
|
22
|
-
mobile:
|
|
18
|
+
headingToBlock:
|
|
19
|
+
desktop: 0.75em
|
|
20
|
+
mobile: 0.7em
|
|
21
|
+
blockGap:
|
|
22
|
+
desktop: 1.5em
|
|
23
|
+
mobile: 1.25em
|
|
23
24
|
imageGap:
|
|
24
25
|
desktop: clamp(1.25rem, 3vw, 2.25rem)
|
|
25
26
|
mobile: 1.5rem
|
|
@@ -36,8 +37,7 @@ typography:
|
|
|
36
37
|
preset: quiet-gallery
|
|
37
38
|
rhythm: normal
|
|
38
39
|
presentation:
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
colors: presentation
|
|
40
|
+
palette: paper # Alternatives: dark, light
|
|
41
|
+
sectionSurfaces:
|
|
42
|
+
mode: cycle
|
|
43
43
|
---
|
|
@@ -19,19 +19,6 @@ export default {
|
|
|
19
19
|
gallery: 'Images',
|
|
20
20
|
},
|
|
21
21
|
},
|
|
22
|
-
footer: {
|
|
23
|
-
copyrightMessage: '(c) Fixture Artist.',
|
|
24
|
-
buildInfo: {
|
|
25
|
-
enabled: true,
|
|
26
|
-
text: 'Built',
|
|
27
|
-
dateTimeFormat: {
|
|
28
|
-
locale: 'en-GB',
|
|
29
|
-
timeZone: 'UTC',
|
|
30
|
-
dateStyle: 'short',
|
|
31
|
-
timeStyle: 'short',
|
|
32
|
-
},
|
|
33
|
-
},
|
|
34
|
-
},
|
|
35
22
|
github: {
|
|
36
23
|
repo: 'owner/fixture-site',
|
|
37
24
|
branch: 'main',
|
|
@@ -2,10 +2,7 @@
|
|
|
2
2
|
title: Content Model v2 Fixture
|
|
3
3
|
description: Internal fixture for Markdown-authoritative Norna content.
|
|
4
4
|
sections:
|
|
5
|
-
intro:
|
|
6
|
-
presentation:
|
|
7
|
-
typography:
|
|
8
|
-
preset: statement
|
|
5
|
+
intro: {}
|
|
9
6
|
timed:
|
|
10
7
|
visible:
|
|
11
8
|
from: "2026-01-01"
|
|
@@ -15,7 +12,7 @@ sections:
|
|
|
15
12
|
## Intro {#intro}
|
|
16
13
|
|
|
17
14
|
This fixture validates that Markdown defines sections and that section metadata
|
|
18
|
-
is optional. It also checks
|
|
15
|
+
is optional. It also checks **inline emphasis**.
|
|
19
16
|
|
|
20
17
|
```norna-image-stack
|
|
21
18
|
- image: hero.jpg
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@janga/norna",
|
|
3
3
|
"description": "A command-line publishing workflow for simple static sites.",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "0.7.
|
|
5
|
+
"version": "0.7.10",
|
|
6
6
|
"license": "GPL-3.0-only",
|
|
7
7
|
"repository": {
|
|
8
8
|
"type": "git",
|
|
@@ -85,7 +85,8 @@
|
|
|
85
85
|
},
|
|
86
86
|
"dependencies": {
|
|
87
87
|
"astro": "^7.1.3",
|
|
88
|
-
"embla-carousel": "^8.6.0"
|
|
88
|
+
"embla-carousel": "^8.6.0",
|
|
89
|
+
"satteri": "^0.9.1"
|
|
89
90
|
},
|
|
90
91
|
"devDependencies": {
|
|
91
92
|
"@playwright/test": "^1.61.1"
|
package/scripts/check-config.mjs
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
import { siteConfigLabel } from './lib/site-paths.mjs';
|
|
1
|
+
import { siteConfigLabel, sitePublicLabel } from './lib/site-paths.mjs';
|
|
2
|
+
import { getLogoAssets } from './lib/logo-assets.mjs';
|
|
3
|
+
import { readSitewideConfig } from './lib/sitewide-config.mjs';
|
|
4
|
+
import { readThemeConfig, validateRouteThemeFiles } from './lib/theme-config.mjs';
|
|
2
5
|
|
|
3
6
|
const formatErrorMessage = (error) => {
|
|
4
7
|
if (error instanceof SyntaxError) {
|
|
@@ -17,6 +20,24 @@ const formatErrorMessage = (error) => {
|
|
|
17
20
|
|
|
18
21
|
try {
|
|
19
22
|
const { projectConfig } = await import('./lib/project-config.mjs');
|
|
23
|
+
await readThemeConfig();
|
|
24
|
+
const sitewideConfig = await readSitewideConfig();
|
|
25
|
+
await validateRouteThemeFiles();
|
|
26
|
+
const logoAssets = getLogoAssets();
|
|
27
|
+
|
|
28
|
+
if (logoAssets.length > 1) {
|
|
29
|
+
throw new Error([
|
|
30
|
+
`Found multiple logo files in ${sitePublicLabel}. Keep exactly one of logo.svg, logo.png, logo.jpg, or logo.jpeg.`,
|
|
31
|
+
...logoAssets.map(({ filename }) => `- ${sitePublicLabel}/${filename}`),
|
|
32
|
+
].join('\n'));
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
if (logoAssets.length === 0) {
|
|
36
|
+
console.warn(`Warning: No logo file found in ${sitePublicLabel}. Norna will use sitewide navigation.brand or the homepage title as the navigation label.`);
|
|
37
|
+
console.warn(`Add exactly one of ${sitePublicLabel}/logo.svg, logo.png, logo.jpg, or logo.jpeg when the site should have a logo.`);
|
|
38
|
+
} else if (sitewideConfig.navigation?.brand) {
|
|
39
|
+
console.warn('Warning: Both sitewide navigation.brand and a logo file are configured. The logo is used; navigation.brand is only the text fallback.');
|
|
40
|
+
}
|
|
20
41
|
|
|
21
42
|
console.log('Config check passed.');
|
|
22
43
|
console.log(`Site URL: ${projectConfig.site.url}`);
|
|
@@ -20,9 +20,37 @@ const stripInlineComment = (value) => {
|
|
|
20
20
|
return value;
|
|
21
21
|
};
|
|
22
22
|
|
|
23
|
+
const splitInlineList = (value) => {
|
|
24
|
+
const entries = [];
|
|
25
|
+
let entryStart = 0;
|
|
26
|
+
let quote = null;
|
|
27
|
+
|
|
28
|
+
for (let index = 0; index < value.length; index += 1) {
|
|
29
|
+
const character = value[index];
|
|
30
|
+
const previous = value[index - 1];
|
|
31
|
+
|
|
32
|
+
if ((character === '"' || character === "'") && previous !== '\\') {
|
|
33
|
+
quote = quote === character ? null : quote ?? character;
|
|
34
|
+
continue;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
if (character === ',' && quote === null) {
|
|
38
|
+
entries.push(value.slice(entryStart, index).trim());
|
|
39
|
+
entryStart = index + 1;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
entries.push(value.slice(entryStart).trim());
|
|
44
|
+
return entries.filter(Boolean);
|
|
45
|
+
};
|
|
46
|
+
|
|
23
47
|
const parseScalar = (rawValue) => {
|
|
24
48
|
const value = stripInlineComment(rawValue.trim());
|
|
25
49
|
|
|
50
|
+
if (value.startsWith('[') && value.endsWith(']')) {
|
|
51
|
+
const listValue = value.slice(1, -1).trim();
|
|
52
|
+
return listValue ? splitInlineList(listValue).map(parseScalar) : [];
|
|
53
|
+
}
|
|
26
54
|
if (value === 'true') return true;
|
|
27
55
|
if (value === 'false') return false;
|
|
28
56
|
if (/^-?\d+(?:\.\d+)?$/.test(value)) return Number(value);
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { readdirSync } from 'node:fs';
|
|
2
|
+
import { sitePublicDir, sitePublicLabel } from './site-paths.mjs';
|
|
3
|
+
|
|
4
|
+
const logoFilePattern = /^logo\.(svg|png|jpe?g)$/i;
|
|
5
|
+
|
|
6
|
+
export const getLogoAssets = () => {
|
|
7
|
+
let entries;
|
|
8
|
+
|
|
9
|
+
try {
|
|
10
|
+
entries = readdirSync(sitePublicDir, { withFileTypes: true });
|
|
11
|
+
} catch (error) {
|
|
12
|
+
if (error?.code === 'ENOENT') return [];
|
|
13
|
+
throw error;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
return entries
|
|
17
|
+
.filter((entry) => entry.isFile() && logoFilePattern.test(entry.name))
|
|
18
|
+
.map((entry) => ({
|
|
19
|
+
filename: entry.name,
|
|
20
|
+
href: `/${entry.name}`,
|
|
21
|
+
}));
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export const getLogoAsset = () => {
|
|
25
|
+
const assets = getLogoAssets();
|
|
26
|
+
|
|
27
|
+
if (assets.length > 1) {
|
|
28
|
+
throw new Error([
|
|
29
|
+
`Found multiple logo files in ${sitePublicLabel}. Keep exactly one of logo.svg, logo.png, logo.jpg, or logo.jpeg.`,
|
|
30
|
+
...assets.map(({ filename }) => `- ${sitePublicLabel}/${filename}`),
|
|
31
|
+
].join('\n'));
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
return assets[0] ?? null;
|
|
35
|
+
};
|
|
@@ -588,6 +588,172 @@ export const splitNornaMarkdownBlockMarkers = (html, options = {}) => {
|
|
|
588
588
|
|
|
589
589
|
const normalizeBlockSource = (source) => source.replace(/\r\n?/g, '\n').trim();
|
|
590
590
|
|
|
591
|
+
const inlineNoteReferenceRegex = /\{note-ref\}/g;
|
|
592
|
+
const inlineNoteDeclarationRegex = /^\s*\{note:\s*(.*)\}\s*$/;
|
|
593
|
+
const inlineNoteDeclarationStartRegex = /\{note(?:\s*:|\s*\})/;
|
|
594
|
+
|
|
595
|
+
const maskInlineCodeAndComments = (source) => source.replace(
|
|
596
|
+
/<!--[\s\S]*?-->|(`+)([\s\S]*?)\1/g,
|
|
597
|
+
(match) => match.replace(/[^\r\n]/g, ' '),
|
|
598
|
+
);
|
|
599
|
+
|
|
600
|
+
const countInlineNoteReferences = (line) => Array.from(line.matchAll(inlineNoteReferenceRegex)).length;
|
|
601
|
+
|
|
602
|
+
const formatInlineNoteError = (message, options, line) => ({
|
|
603
|
+
blockType: 'inline-note',
|
|
604
|
+
line,
|
|
605
|
+
message: failMessage(message, { ...options, line }),
|
|
606
|
+
});
|
|
607
|
+
|
|
608
|
+
const getInlineNoteErrorMessage = () => 'Write the note on its own line as "{note: Your explanatory text.}".';
|
|
609
|
+
|
|
610
|
+
/**
|
|
611
|
+
* Finds the deliberately small inline-note syntax while ignoring fenced and
|
|
612
|
+
* inline code. Notes are paired by position, so no user-authored IDs are
|
|
613
|
+
* needed. The caller decides whether diagnostics should be fatal.
|
|
614
|
+
*/
|
|
615
|
+
export const extractInlineNoteDiagnostics = (markdown, options = {}) => {
|
|
616
|
+
const lines = normalizeLines(markdown);
|
|
617
|
+
const maskedLines = maskInlineCodeAndComments(maskFencedCodeBlocks(markdown)).split('\n');
|
|
618
|
+
const notes = [];
|
|
619
|
+
const errors = [];
|
|
620
|
+
let paragraph = null;
|
|
621
|
+
let pendingParagraph = null;
|
|
622
|
+
let noteJustSeen = false;
|
|
623
|
+
|
|
624
|
+
const addError = (message, line) => errors.push(formatInlineNoteError(message, options, line));
|
|
625
|
+
|
|
626
|
+
const finishParagraph = () => {
|
|
627
|
+
if (!paragraph) return;
|
|
628
|
+
if (paragraph.referenceCount > 0) {
|
|
629
|
+
pendingParagraph = paragraph;
|
|
630
|
+
}
|
|
631
|
+
paragraph = null;
|
|
632
|
+
};
|
|
633
|
+
|
|
634
|
+
const reportMissingNote = () => {
|
|
635
|
+
if (!pendingParagraph) return;
|
|
636
|
+
addError(
|
|
637
|
+
`Paragraph on line ${pendingParagraph.referenceLine} contains "{note-ref}" but has no following "{note: ...}".`,
|
|
638
|
+
pendingParagraph.referenceLine,
|
|
639
|
+
);
|
|
640
|
+
pendingParagraph = null;
|
|
641
|
+
};
|
|
642
|
+
|
|
643
|
+
const attachNote = (noteMatch, lineNumber) => {
|
|
644
|
+
const text = noteMatch[1].trim();
|
|
645
|
+
if (!text) {
|
|
646
|
+
addError(`The note on line ${lineNumber} is empty. ${getInlineNoteErrorMessage()}`, lineNumber);
|
|
647
|
+
pendingParagraph = null;
|
|
648
|
+
return;
|
|
649
|
+
}
|
|
650
|
+
|
|
651
|
+
if (/!\[[^\]]*\]\([^)]*\)|<img\b/i.test(text)) {
|
|
652
|
+
addError('Inline notes cannot contain images. Use a Norna image block with a caption instead.', lineNumber);
|
|
653
|
+
pendingParagraph = null;
|
|
654
|
+
return;
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
notes.push({
|
|
658
|
+
markdown: text,
|
|
659
|
+
referenceLine: pendingParagraph.referenceLine,
|
|
660
|
+
noteLine: lineNumber,
|
|
661
|
+
});
|
|
662
|
+
pendingParagraph = null;
|
|
663
|
+
noteJustSeen = true;
|
|
664
|
+
};
|
|
665
|
+
|
|
666
|
+
for (let index = 0; index < lines.length; index += 1) {
|
|
667
|
+
const line = lines[index] ?? '';
|
|
668
|
+
const maskedLine = maskedLines[index] ?? line;
|
|
669
|
+
const lineNumber = (options.lineOffset ?? 0) + index + 1;
|
|
670
|
+
const fence = getFenceInfo(line);
|
|
671
|
+
|
|
672
|
+
if (fence && fence.length >= 3) {
|
|
673
|
+
finishParagraph();
|
|
674
|
+
reportMissingNote();
|
|
675
|
+
let closingIndex = -1;
|
|
676
|
+
for (let candidateIndex = index + 1; candidateIndex < lines.length; candidateIndex += 1) {
|
|
677
|
+
if (getFenceCloseInfo(lines[candidateIndex], fence)) {
|
|
678
|
+
closingIndex = candidateIndex;
|
|
679
|
+
break;
|
|
680
|
+
}
|
|
681
|
+
}
|
|
682
|
+
index = closingIndex === -1 ? lines.length : closingIndex;
|
|
683
|
+
noteJustSeen = false;
|
|
684
|
+
continue;
|
|
685
|
+
}
|
|
686
|
+
|
|
687
|
+
const trimmed = line.trim();
|
|
688
|
+
const maskedTrimmed = maskedLine.trim();
|
|
689
|
+
const noteMatch = trimmed.match(inlineNoteDeclarationRegex);
|
|
690
|
+
const looksLikeNoteDeclaration = inlineNoteDeclarationStartRegex.test(maskedTrimmed);
|
|
691
|
+
const referenceCount = countInlineNoteReferences(maskedLine);
|
|
692
|
+
const isHeading = /^#{1,6}(?:\s|$)/.test(trimmed);
|
|
693
|
+
|
|
694
|
+
if (!trimmed) {
|
|
695
|
+
finishParagraph();
|
|
696
|
+
noteJustSeen = false;
|
|
697
|
+
continue;
|
|
698
|
+
}
|
|
699
|
+
|
|
700
|
+
if (pendingParagraph) {
|
|
701
|
+
if (noteMatch) {
|
|
702
|
+
attachNote(noteMatch, lineNumber);
|
|
703
|
+
continue;
|
|
704
|
+
}
|
|
705
|
+
|
|
706
|
+
if (looksLikeNoteDeclaration) {
|
|
707
|
+
addError(`Invalid note syntax on line ${lineNumber}. ${getInlineNoteErrorMessage()}`, lineNumber);
|
|
708
|
+
pendingParagraph = null;
|
|
709
|
+
} else {
|
|
710
|
+
reportMissingNote();
|
|
711
|
+
}
|
|
712
|
+
}
|
|
713
|
+
|
|
714
|
+
if (noteJustSeen) {
|
|
715
|
+
addError(`Add a blank line after the note on the previous line before starting more text.`, lineNumber);
|
|
716
|
+
noteJustSeen = false;
|
|
717
|
+
}
|
|
718
|
+
|
|
719
|
+
if (noteMatch || looksLikeNoteDeclaration) {
|
|
720
|
+
addError(
|
|
721
|
+
noteMatch
|
|
722
|
+
? `A "{note: ...}" requires a preceding paragraph containing "{note-ref}".`
|
|
723
|
+
: `Invalid note syntax on line ${lineNumber}. ${getInlineNoteErrorMessage()}`,
|
|
724
|
+
lineNumber,
|
|
725
|
+
);
|
|
726
|
+
continue;
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
if (isHeading) {
|
|
730
|
+
if (referenceCount > 0) {
|
|
731
|
+
addError('Place "{note-ref}" in a paragraph, not in a heading.', lineNumber);
|
|
732
|
+
}
|
|
733
|
+
finishParagraph();
|
|
734
|
+
reportMissingNote();
|
|
735
|
+
continue;
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
if (!paragraph) {
|
|
739
|
+
paragraph = {
|
|
740
|
+
referenceCount: 0,
|
|
741
|
+
referenceLine: lineNumber,
|
|
742
|
+
};
|
|
743
|
+
}
|
|
744
|
+
|
|
745
|
+
paragraph.referenceCount += referenceCount;
|
|
746
|
+
if (referenceCount > 0 && paragraph.referenceCount > 1) {
|
|
747
|
+
addError('A paragraph may contain only one "{note-ref}".', lineNumber);
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
|
|
751
|
+
finishParagraph();
|
|
752
|
+
reportMissingNote();
|
|
753
|
+
|
|
754
|
+
return { notes, errors };
|
|
755
|
+
};
|
|
756
|
+
|
|
591
757
|
export const splitNornaRenderedCodeBlocks = (html, rawBlocks, options = {}) => {
|
|
592
758
|
const blocks = [];
|
|
593
759
|
const renderedCodeRegex = /<pre\b[^>]*>\s*<code\b[^>]*>([\s\S]*?)<\/code>\s*<\/pre>/g;
|
|
@@ -1,71 +1,129 @@
|
|
|
1
1
|
import {
|
|
2
2
|
defaultTypography,
|
|
3
3
|
resolveTypographyConfig,
|
|
4
|
-
resolveTypographyOverride,
|
|
5
4
|
} from './typography.mjs';
|
|
6
5
|
|
|
7
|
-
export const
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
export const presentationPaletteNames = ['dark', 'light', 'paper'];
|
|
7
|
+
|
|
8
|
+
const presentationPalettes = Object.freeze({
|
|
9
|
+
dark: {
|
|
10
|
+
colorScheme: 'dark',
|
|
11
|
+
page: { backgroundColor: '#000000', textColor: '#f2eee6' },
|
|
12
|
+
surfaces: {
|
|
13
|
+
base: { backgroundColor: '#000000', textColor: '#f2eee6' },
|
|
14
|
+
soft: { backgroundColor: '#171717', textColor: '#f2eee6' },
|
|
15
|
+
emphasis: { backgroundColor: '#252525', textColor: '#f2eee6' },
|
|
16
|
+
},
|
|
17
|
+
frame: { backgroundColor: '#000000', textColor: '#f2eee6' },
|
|
18
|
+
css: {
|
|
19
|
+
surface: '#101010',
|
|
20
|
+
muted: '#aaa49a',
|
|
21
|
+
soft: '#302f2c',
|
|
22
|
+
accent: '#d8d2c8',
|
|
23
|
+
border: 'rgb(255 255 255 / 14%)',
|
|
24
|
+
navBackground: 'rgb(0 0 0 / 90%)',
|
|
25
|
+
navSeparator: 'rgb(255 255 255 / 28%)',
|
|
26
|
+
},
|
|
27
|
+
},
|
|
28
|
+
light: {
|
|
29
|
+
colorScheme: 'light',
|
|
30
|
+
page: { backgroundColor: '#ffffff', textColor: '#17201d' },
|
|
31
|
+
surfaces: {
|
|
32
|
+
base: { backgroundColor: '#ffffff', textColor: '#17201d' },
|
|
33
|
+
soft: { backgroundColor: '#f1f4f2', textColor: '#17201d' },
|
|
34
|
+
emphasis: { backgroundColor: '#dde7e1', textColor: '#17201d' },
|
|
35
|
+
},
|
|
36
|
+
frame: { backgroundColor: '#ffffff', textColor: '#17201d' },
|
|
37
|
+
css: {
|
|
38
|
+
surface: '#f7f8f7',
|
|
39
|
+
muted: '#5e655f',
|
|
40
|
+
soft: '#d9dfda',
|
|
41
|
+
accent: '#38645a',
|
|
42
|
+
border: 'rgb(0 0 0 / 14%)',
|
|
43
|
+
navBackground: 'rgb(255 255 255 / 92%)',
|
|
44
|
+
navSeparator: 'rgb(0 0 0 / 20%)',
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
paper: {
|
|
48
|
+
colorScheme: 'light',
|
|
49
|
+
page: { backgroundColor: '#f8f5ee', textColor: '#272522' },
|
|
50
|
+
surfaces: {
|
|
51
|
+
base: { backgroundColor: '#f8f5ee', textColor: '#272522' },
|
|
52
|
+
soft: { backgroundColor: '#ebe5d9', textColor: '#272522' },
|
|
53
|
+
emphasis: { backgroundColor: '#ded4c5', textColor: '#272522' },
|
|
54
|
+
},
|
|
55
|
+
frame: { backgroundColor: '#f8f5ee', textColor: '#272522' },
|
|
56
|
+
css: {
|
|
57
|
+
surface: '#f0ebe1',
|
|
58
|
+
muted: '#746e63',
|
|
59
|
+
soft: '#d8d0c4',
|
|
60
|
+
accent: '#685a43',
|
|
61
|
+
border: 'rgb(39 37 34 / 18%)',
|
|
62
|
+
navBackground: 'rgb(248 245 238 / 92%)',
|
|
63
|
+
navSeparator: 'rgb(39 37 34 / 24%)',
|
|
64
|
+
},
|
|
65
|
+
},
|
|
10
66
|
});
|
|
11
67
|
|
|
12
68
|
const normalizePresentation = (presentation) => presentation ?? {};
|
|
13
69
|
|
|
70
|
+
export const getPresentationPalette = (paletteName = 'dark') => {
|
|
71
|
+
const palette = presentationPalettes[paletteName];
|
|
72
|
+
if (!palette) {
|
|
73
|
+
throw new Error(`Unknown presentation palette: ${paletteName}. Use one of: ${presentationPaletteNames.join(', ')}`);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
return palette;
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
export const getPresentationCssVariables = (presentation) => {
|
|
80
|
+
const { palette } = presentation;
|
|
81
|
+
return {
|
|
82
|
+
'--color-page': palette.page.backgroundColor,
|
|
83
|
+
'--color-text': palette.page.textColor,
|
|
84
|
+
'--color-surface': palette.css.surface,
|
|
85
|
+
'--color-muted': palette.css.muted,
|
|
86
|
+
'--color-soft': palette.css.soft,
|
|
87
|
+
'--color-accent': palette.css.accent,
|
|
88
|
+
'--color-border': palette.css.border,
|
|
89
|
+
'--color-nav-background': palette.css.navBackground,
|
|
90
|
+
'--color-nav-separator': palette.css.navSeparator,
|
|
91
|
+
'--color-scheme': palette.colorScheme,
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
|
|
14
95
|
export const resolveThemePresentation = (theme) => {
|
|
15
96
|
const normalizedTheme = theme ?? {};
|
|
16
97
|
const normalizedThemePresentation = normalizePresentation(normalizedTheme.presentation);
|
|
98
|
+
const paletteName = normalizedThemePresentation.palette ?? 'dark';
|
|
99
|
+
const palette = getPresentationPalette(paletteName);
|
|
17
100
|
|
|
18
101
|
return {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
102
|
+
paletteName,
|
|
103
|
+
palette,
|
|
104
|
+
sectionSurfaces: {
|
|
105
|
+
mode: normalizedThemePresentation.sectionSurfaces?.mode ?? 'none',
|
|
106
|
+
sequence: normalizedThemePresentation.sectionSurfaces?.sequence ?? ['base', 'soft', 'emphasis'],
|
|
107
|
+
},
|
|
22
108
|
typography: resolveTypographyConfig(normalizedTheme.typography ?? defaultTypography),
|
|
23
109
|
};
|
|
24
110
|
};
|
|
25
111
|
|
|
26
|
-
export const resolvePagePresentation = (theme
|
|
112
|
+
export const resolvePagePresentation = (theme) => {
|
|
27
113
|
const resolvedThemePresentation = resolveThemePresentation(theme);
|
|
28
|
-
const normalizedPagePresentation = normalizePresentation(pagePresentation);
|
|
29
114
|
|
|
30
|
-
return
|
|
31
|
-
backgroundColor: normalizedPagePresentation.backgroundColor ?? resolvedThemePresentation.backgroundColor,
|
|
32
|
-
textColor: normalizedPagePresentation.textColor ?? resolvedThemePresentation.textColor,
|
|
33
|
-
inlineStyles: resolvedThemePresentation.inlineStyles,
|
|
34
|
-
typography: resolveTypographyOverride(
|
|
35
|
-
resolvedThemePresentation.typography,
|
|
36
|
-
normalizedPagePresentation.typography,
|
|
37
|
-
),
|
|
38
|
-
};
|
|
115
|
+
return resolvedThemePresentation;
|
|
39
116
|
};
|
|
40
117
|
|
|
41
|
-
const
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
const resolveColorSource = ({ colors, themeFrameColors, pagePresentation }) => {
|
|
47
|
-
if (!colors || colors === 'theme') {
|
|
48
|
-
return themeFrameColors;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
if (colors === 'presentation') {
|
|
52
|
-
return getColorsFromPresentation(pagePresentation);
|
|
53
|
-
}
|
|
118
|
+
export const resolveSectionSurface = (pagePresentation, sectionIndex) => {
|
|
119
|
+
const surfaceName = pagePresentation.sectionSurfaces.mode === 'cycle'
|
|
120
|
+
? pagePresentation.sectionSurfaces.sequence[sectionIndex % pagePresentation.sectionSurfaces.sequence.length]
|
|
121
|
+
: 'base';
|
|
54
122
|
|
|
55
|
-
return
|
|
123
|
+
return {
|
|
124
|
+
name: surfaceName,
|
|
125
|
+
...pagePresentation.palette.surfaces[surfaceName],
|
|
126
|
+
};
|
|
56
127
|
};
|
|
57
128
|
|
|
58
|
-
export const resolveFrameColors = ({ theme
|
|
59
|
-
const resolvedThemePresentation = resolveThemePresentation(theme);
|
|
60
|
-
const themeFrameColors = resolveColorSource({
|
|
61
|
-
colors: theme?.frame?.colors ?? 'presentation',
|
|
62
|
-
themeFrameColors: getColorsFromPresentation(resolvedThemePresentation),
|
|
63
|
-
pagePresentation: resolvedThemePresentation,
|
|
64
|
-
});
|
|
65
|
-
|
|
66
|
-
return resolveColorSource({
|
|
67
|
-
colors: pageFrame?.colors ?? 'theme',
|
|
68
|
-
themeFrameColors,
|
|
69
|
-
pagePresentation,
|
|
70
|
-
});
|
|
71
|
-
};
|
|
129
|
+
export const resolveFrameColors = ({ theme }) => resolveThemePresentation(theme).palette.frame;
|