@janga/norna 0.7.2 → 0.7.4
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 -16
- package/bin/norna-cli.mjs +12 -7
- package/docs/README.md +11 -12
- package/docs/commands.md +9 -9
- package/docs/configuration.md +14 -145
- package/docs/content.md +17 -15
- package/docs/design/command-organization.md +58 -57
- package/docs/design/site-examples-structure.md +6 -5
- package/docs/engine-development.md +5 -5
- package/docs/getting-started.md +20 -26
- package/docs/images-and-metadata.md +1 -1
- package/docs/local-development.md +2 -2
- package/docs/publishing.md +1 -1
- package/docs/routes.md +2 -2
- package/docs/site-structure.md +8 -7
- package/docs/theme.md +133 -7
- package/docs/typography.md +78 -43
- package/examples/dog-gallery/node_modules/.vite/deps/_metadata.json +74 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro-D_GIpJIE.js +434 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro-D_GIpJIE.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_n_aria-query.js +6390 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_n_aria-query.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_n_axobject-query.js +2702 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_n_axobject-query.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_n_html-escaper.js +65 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_n_html-escaper.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_runtime_client_dev-toolbar_entrypoint__js.js +455 -0
- package/examples/dog-gallery/node_modules/.vite/deps/astro_runtime_client_dev-toolbar_entrypoint__js.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/audit-DM9Hkl5B.js +1534 -0
- package/examples/dog-gallery/node_modules/.vite/deps/audit-DM9Hkl5B.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/highlight-DnZ1ULOL.js +48 -0
- package/examples/dog-gallery/node_modules/.vite/deps/highlight-DnZ1ULOL.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/icons-RyebKi45.js +42 -0
- package/examples/dog-gallery/node_modules/.vite/deps/icons-RyebKi45.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/package.json +3 -0
- package/examples/dog-gallery/node_modules/.vite/deps/rolldown-runtime-BvCyGRYZ.js +4 -0
- package/examples/dog-gallery/node_modules/.vite/deps/settings-DaU-gNnK.js +190 -0
- package/examples/dog-gallery/node_modules/.vite/deps/settings-DaU-gNnK.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/toolbar-63PA619H.js +458 -0
- package/examples/dog-gallery/node_modules/.vite/deps/toolbar-63PA619H.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/ui-library--bkcNSYz.js +1016 -0
- package/examples/dog-gallery/node_modules/.vite/deps/ui-library--bkcNSYz.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/window-jPkpKVcy.js +32 -0
- package/examples/dog-gallery/node_modules/.vite/deps/window-jPkpKVcy.js.map +1 -0
- package/examples/dog-gallery/node_modules/.vite/deps/xray-BXCHpEJP.js +111 -0
- package/examples/dog-gallery/node_modules/.vite/deps/xray-BXCHpEJP.js.map +1 -0
- package/examples/dog-gallery/site/config.mjs +12 -42
- package/examples/dog-gallery/site/content.md +28 -6
- package/examples/dog-gallery/site/routes/dog-care/route-content.md +17 -3
- package/examples/dog-gallery/site/theme.md +83 -26
- package/fixtures/basic/site/config.mjs +2 -22
- package/fixtures/basic/site/content.md +1 -1
- package/fixtures/basic/site/theme.md +7 -3
- package/package.json +3 -3
- package/scripts/check-config.mjs +4 -3
- package/scripts/deploy-site.mjs +3 -3
- package/scripts/init-site.mjs +10 -8
- package/scripts/lib/frontmatter-yaml.mjs +85 -0
- package/scripts/lib/presentation.mjs +10 -11
- package/scripts/lib/project-config.mjs +146 -45
- package/scripts/lib/site-content.mjs +21 -3
- package/scripts/lib/theme-config.mjs +34 -0
- package/scripts/lib/typography.mjs +155 -35
- package/scripts/show-typography.mjs +127 -159
- package/scripts/sync-content-sections.mjs +6 -6
- package/scripts/test-content-check.mjs +3 -4
- package/scripts/test-engine-commands.mjs +21 -3
- package/scripts/test-package-check.mjs +34 -17
- package/scripts/test-temporary-visibility.mjs +2 -3
- package/src/components/SitePage.astro +2 -3
- package/src/components/SiteSection.astro +115 -19
- package/src/content.config.ts +66 -6
- package/src/layouts/BaseLayout.astro +11 -0
- package/src/styles/global.css +83 -52
- package/starters/basic/README.md +11 -15
- package/starters/basic/package.json +2 -2
- package/starters/basic/site/config.mjs +3 -24
- package/starters/basic/site/content.md +40 -7
- package/starters/basic/site/theme.md +84 -18
- package/starters/project/.github/workflows/deploy.yml +65 -0
- package/starters/project/README.md +72 -0
- package/starters/project/package-lock.json +4296 -0
- package/starters/project/package.json +35 -0
- package/starters/project/site/config.mjs +43 -0
- package/starters/project/site/content.md +128 -0
- package/starters/project/site/public/robots.txt +2 -0
- package/starters/project/site/routes/guide/route-content.md +85 -0
- package/starters/project/site/theme.md +43 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
# Command Organization
|
|
2
2
|
|
|
3
|
-
This document defines the naming principles for commands in `norna`,
|
|
4
|
-
|
|
3
|
+
This document defines the naming principles for commands in `norna`, site
|
|
4
|
+
repositories, and GitHub projects that embed a Norna site.
|
|
5
5
|
|
|
6
6
|
The goal is that command names reveal both the action and the scope they affect.
|
|
7
|
-
This matters because the same repository can contain a
|
|
7
|
+
This matters because the same repository can contain a Norna site, an app, tests,
|
|
8
8
|
and a publishing workflow that should not accidentally share ambiguous command
|
|
9
9
|
names.
|
|
10
10
|
|
|
@@ -12,10 +12,10 @@ names.
|
|
|
12
12
|
|
|
13
13
|
`norna` commands must be understandable in three situations:
|
|
14
14
|
|
|
15
|
-
-
|
|
15
|
+
- Standalone site project: the repository exists only to publish one
|
|
16
16
|
`norna` site.
|
|
17
|
-
- Mixed
|
|
18
|
-
|
|
17
|
+
- Mixed project: the repository contains another project, such as an app or
|
|
18
|
+
library, and includes a Norna site as one part of its
|
|
19
19
|
GitHub Pages output.
|
|
20
20
|
- Engine development: the repository is `norna` itself.
|
|
21
21
|
|
|
@@ -27,7 +27,7 @@ Use these namespaces consistently.
|
|
|
27
27
|
|
|
28
28
|
Use `norna:*` npm scripts in repositories that consume `norna`.
|
|
29
29
|
|
|
30
|
-
These scripts operate on a selected
|
|
30
|
+
These scripts operate on a selected site source directory. In a standalone site
|
|
31
31
|
project that directory is normally `site/`. In a mixed project it may be a more
|
|
32
32
|
specific directory such as `presentation/`, with the script setting
|
|
33
33
|
`NORNA_SITE_DIR` or passing `norna --site-dir`.
|
|
@@ -41,19 +41,19 @@ npm run norna:sync
|
|
|
41
41
|
npm run norna:build
|
|
42
42
|
```
|
|
43
43
|
|
|
44
|
-
Mixed projects must use `norna:*` for
|
|
44
|
+
Mixed projects must use `norna:*` for Norna work so names such as `build`,
|
|
45
45
|
`test`, and `deploy` can remain under the containing project's control.
|
|
46
46
|
|
|
47
|
-
|
|
47
|
+
Standalone site projects should also use `norna:*` as the primary documented
|
|
48
48
|
interface. They may provide unprefixed aliases when the alias means the same
|
|
49
49
|
thing for the whole repository, for example `npm run build` as an alias for
|
|
50
50
|
`npm run norna:build`.
|
|
51
51
|
|
|
52
|
-
### Project Commands That Call
|
|
52
|
+
### Project Commands That Call Norna Commands
|
|
53
53
|
|
|
54
54
|
`norna` does not define a consuming project's unprefixed commands. Names
|
|
55
55
|
such as `build`, `test`, and `deploy` belong to the project that consumes the
|
|
56
|
-
|
|
56
|
+
Norna engine.
|
|
57
57
|
|
|
58
58
|
Examples:
|
|
59
59
|
|
|
@@ -63,18 +63,18 @@ npm run test
|
|
|
63
63
|
npm run deploy
|
|
64
64
|
```
|
|
65
65
|
|
|
66
|
-
When those project commands need the
|
|
66
|
+
When those project commands need the Norna site, they should call `norna:*`
|
|
67
67
|
scripts instead of calling `norna` directly. That keeps the selected
|
|
68
|
-
|
|
68
|
+
site source directory and other project-specific wrapper behavior in one
|
|
69
69
|
place.
|
|
70
70
|
|
|
71
71
|
In a mixed project, if `npm run build` exists, it should build the project's
|
|
72
|
-
complete publishable artifact, not only the
|
|
73
|
-
GitHub Pages artifact containing both a
|
|
72
|
+
complete publishable artifact, not only the Norna site. If the project publishes a
|
|
73
|
+
GitHub Pages artifact containing both a Norna site and an app, `build` should
|
|
74
74
|
produce that full artifact and may call `npm run norna:build` internally.
|
|
75
75
|
|
|
76
|
-
In a
|
|
77
|
-
commands because the
|
|
76
|
+
In a standalone site project, project commands may be aliases to `norna:*`
|
|
77
|
+
commands because the Norna site is the whole project.
|
|
78
78
|
|
|
79
79
|
### `release:*`
|
|
80
80
|
|
|
@@ -114,19 +114,19 @@ can set the correct site directory for the repository.
|
|
|
114
114
|
|
|
115
115
|
## Functional Groups
|
|
116
116
|
|
|
117
|
-
### Install
|
|
117
|
+
### Install Norna Software
|
|
118
118
|
|
|
119
|
-
Creating a new
|
|
119
|
+
Creating a new standalone site project starts outside the target project because
|
|
120
120
|
the target does not have a `package.json` yet:
|
|
121
121
|
|
|
122
122
|
```sh
|
|
123
|
-
npx @janga/norna@latest init my-
|
|
124
|
-
cd my-
|
|
123
|
+
npx @janga/norna@latest init my-site
|
|
124
|
+
cd my-site
|
|
125
125
|
npm install
|
|
126
126
|
```
|
|
127
127
|
|
|
128
128
|
A mixed project already has its own repository and may have its own
|
|
129
|
-
`package.json`. In that situation the
|
|
129
|
+
`package.json`. In that situation the Norna dependency should be installed as
|
|
130
130
|
part of the existing project setup:
|
|
131
131
|
|
|
132
132
|
```sh
|
|
@@ -134,7 +134,7 @@ npm install --save-exact @janga/norna
|
|
|
134
134
|
```
|
|
135
135
|
|
|
136
136
|
The mixed project should then add `norna:*` scripts that point at the chosen
|
|
137
|
-
|
|
137
|
+
site source directory.
|
|
138
138
|
|
|
139
139
|
Engine development uses ordinary package installation in the engine repository:
|
|
140
140
|
|
|
@@ -142,9 +142,9 @@ Engine development uses ordinary package installation in the engine repository:
|
|
|
142
142
|
npm install
|
|
143
143
|
```
|
|
144
144
|
|
|
145
|
-
### Upgrade Or Inspect
|
|
145
|
+
### Upgrade Or Inspect Norna Software
|
|
146
146
|
|
|
147
|
-
In a consuming repository, upgrading or inspecting the installed
|
|
147
|
+
In a consuming repository, upgrading or inspecting the installed Norna engine
|
|
148
148
|
is norna maintenance, so the preferred namespace is `norna:*`:
|
|
149
149
|
|
|
150
150
|
```sh
|
|
@@ -162,13 +162,13 @@ In the engine repository, version changes belong to `release:*`:
|
|
|
162
162
|
npm run release:minor
|
|
163
163
|
```
|
|
164
164
|
|
|
165
|
-
### Initialize A
|
|
165
|
+
### Initialize A Site Project Directory
|
|
166
166
|
|
|
167
167
|
Initialization is a direct CLI operation because it usually happens before a
|
|
168
168
|
project has npm scripts:
|
|
169
169
|
|
|
170
170
|
```sh
|
|
171
|
-
npx @janga/norna@latest init my-
|
|
171
|
+
npx @janga/norna@latest init my-site
|
|
172
172
|
```
|
|
173
173
|
|
|
174
174
|
The initializer should support two setup modes that share the same `norna:*`
|
|
@@ -176,25 +176,25 @@ command vocabulary.
|
|
|
176
176
|
|
|
177
177
|
#### Pure Setup
|
|
178
178
|
|
|
179
|
-
Pure setup creates a new project where the
|
|
179
|
+
Pure setup creates a new project where the Norna site is the whole repository:
|
|
180
180
|
|
|
181
181
|
```sh
|
|
182
|
-
npx @janga/norna@latest init my-
|
|
182
|
+
npx @janga/norna@latest init my-site --type pure
|
|
183
183
|
```
|
|
184
184
|
|
|
185
185
|
This should be the default when the target is a new or empty directory.
|
|
186
186
|
|
|
187
187
|
Pure setup should create:
|
|
188
188
|
|
|
189
|
-
- a normal
|
|
189
|
+
- a normal site source directory, normally `site/`;
|
|
190
190
|
- a `package.json` with `norna:*` scripts;
|
|
191
191
|
- unprefixed convenience aliases only when they mean the same thing as the
|
|
192
192
|
whole project, for example `build` as an alias for `norna:build`;
|
|
193
|
-
- the standard GitHub Pages workflow for publishing the
|
|
193
|
+
- the standard GitHub Pages workflow for publishing the site.
|
|
194
194
|
|
|
195
195
|
#### Embedded Setup
|
|
196
196
|
|
|
197
|
-
Embedded setup adds a
|
|
197
|
+
Embedded setup adds a Norna site to an existing project without taking ownership
|
|
198
198
|
of that project's root commands:
|
|
199
199
|
|
|
200
200
|
```sh
|
|
@@ -204,9 +204,9 @@ npx @janga/norna@latest init . --type embedded --site-dir presentation
|
|
|
204
204
|
Embedded setup should be selected explicitly, or suggested when the target
|
|
205
205
|
already contains a `package.json`.
|
|
206
206
|
|
|
207
|
-
Embedded setup should create or update only the
|
|
207
|
+
Embedded setup should create or update only the Norna-owned parts:
|
|
208
208
|
|
|
209
|
-
- the chosen
|
|
209
|
+
- the chosen site source directory, for example `presentation/`;
|
|
210
210
|
- `@janga/norna` as a project dependency;
|
|
211
211
|
- `norna:*` scripts that set the selected site directory;
|
|
212
212
|
- no unprefixed aliases such as `build`, `test`, `dev`, or `deploy`;
|
|
@@ -263,11 +263,11 @@ npm run test
|
|
|
263
263
|
|
|
264
264
|
If a mixed project defines `test`, that command should cover the whole project.
|
|
265
265
|
It may call `norna:check`, but it should not be a hidden synonym for only
|
|
266
|
-
|
|
266
|
+
Norna validation.
|
|
267
267
|
|
|
268
|
-
### Inspect
|
|
268
|
+
### Inspect Site Presentation
|
|
269
269
|
|
|
270
|
-
Commands that inspect
|
|
270
|
+
Commands that inspect site presentation without changing source files use
|
|
271
271
|
`norna:*` in consuming repositories:
|
|
272
272
|
|
|
273
273
|
```sh
|
|
@@ -275,13 +275,14 @@ npm run norna:typography:presets
|
|
|
275
275
|
npm run norna:typography:show
|
|
276
276
|
```
|
|
277
277
|
|
|
278
|
-
`norna:typography:presets` shows the built-in typography presets
|
|
279
|
-
installed engine. `norna:typography:show` shows the effective
|
|
280
|
-
the selected
|
|
278
|
+
`norna:typography:presets` shows the built-in typography presets and rhythms
|
|
279
|
+
from the installed engine. `norna:typography:show` shows the effective
|
|
280
|
+
typography for the selected site after presets, rhythms, and overrides have
|
|
281
|
+
been applied.
|
|
281
282
|
|
|
282
283
|
### Correct Content And Configuration
|
|
283
284
|
|
|
284
|
-
Commands that modify
|
|
285
|
+
Commands that modify Norna-owned source files use `norna:*`:
|
|
285
286
|
|
|
286
287
|
```sh
|
|
287
288
|
npm run norna:sync
|
|
@@ -293,7 +294,7 @@ npm run norna:images
|
|
|
293
294
|
Messages emitted by the engine should mention the direct CLI command and the
|
|
294
295
|
starter-style npm wrapper when suggesting a fix.
|
|
295
296
|
|
|
296
|
-
Configuration edits are normally manual edits to the selected
|
|
297
|
+
Configuration edits are normally manual edits to the selected site
|
|
297
298
|
`config.mjs`, followed by:
|
|
298
299
|
|
|
299
300
|
```sh
|
|
@@ -302,7 +303,7 @@ npm run norna:config:check
|
|
|
302
303
|
|
|
303
304
|
### Build
|
|
304
305
|
|
|
305
|
-
In a
|
|
306
|
+
In a standalone site project:
|
|
306
307
|
|
|
307
308
|
```sh
|
|
308
309
|
npm run norna:build
|
|
@@ -311,7 +312,7 @@ npm run build
|
|
|
311
312
|
```
|
|
312
313
|
|
|
313
314
|
`norna:build:local` builds and restarts the local dev server. `build` may
|
|
314
|
-
alias `norna:build` because the
|
|
315
|
+
alias `norna:build` because the Norna site is the whole project.
|
|
315
316
|
|
|
316
317
|
In a mixed project:
|
|
317
318
|
|
|
@@ -321,10 +322,10 @@ npm run norna:build:local
|
|
|
321
322
|
npm run build
|
|
322
323
|
```
|
|
323
324
|
|
|
324
|
-
`norna:build` builds only the
|
|
325
|
-
|
|
325
|
+
`norna:build` builds only the Norna site. `norna:build:local` builds the
|
|
326
|
+
site and restarts the local Norna dev server. If the mixed project defines
|
|
326
327
|
`build`, that project command should build the complete publishable artifact,
|
|
327
|
-
such as a GitHub Pages output that combines the
|
|
328
|
+
such as a GitHub Pages output that combines the Norna site with an app. It may call
|
|
328
329
|
`norna:build` internally.
|
|
329
330
|
|
|
330
331
|
In the engine repository:
|
|
@@ -347,8 +348,8 @@ npm run norna:deploy
|
|
|
347
348
|
npm run norna:deploy:commit
|
|
348
349
|
```
|
|
349
350
|
|
|
350
|
-
Use these only when the
|
|
351
|
-
project deliberately delegates deployment to the
|
|
351
|
+
Use these only when the Norna site is the deployable site or when the containing
|
|
352
|
+
project deliberately delegates deployment to the Norna engine.
|
|
352
353
|
|
|
353
354
|
Mixed projects may instead have project-owned deploy commands:
|
|
354
355
|
|
|
@@ -357,7 +358,7 @@ npm run deploy
|
|
|
357
358
|
```
|
|
358
359
|
|
|
359
360
|
Those commands should publish the complete project artifact. If they need the
|
|
360
|
-
|
|
361
|
+
Norna site, they should call `norna:*` scripts internally.
|
|
361
362
|
|
|
362
363
|
Engine publishing uses `release:*`, not `norna:*`:
|
|
363
364
|
|
|
@@ -369,14 +370,14 @@ npm run release:major
|
|
|
369
370
|
|
|
370
371
|
### Monitor Publishing
|
|
371
372
|
|
|
372
|
-
|
|
373
|
+
GitHub Pages monitoring for a Norna site belongs under:
|
|
373
374
|
|
|
374
375
|
```sh
|
|
375
376
|
npm run norna:deploy:watch
|
|
376
377
|
```
|
|
377
378
|
|
|
378
379
|
Mixed projects may provide a project-owned monitoring command when monitoring
|
|
379
|
-
is not specific to the
|
|
380
|
+
is not specific to the Norna site:
|
|
380
381
|
|
|
381
382
|
```sh
|
|
382
383
|
npm run deploy:watch
|
|
@@ -388,19 +389,19 @@ norna-specific deploy settings, it should call `norna:deploy:watch`.
|
|
|
388
389
|
## Naming Rules
|
|
389
390
|
|
|
390
391
|
- Use `norna:*` for every npm script in a consuming repository whose direct
|
|
391
|
-
object is the
|
|
392
|
+
object is the Norna site, its source files, its generated images, its dev server,
|
|
392
393
|
or its engine dependency.
|
|
393
394
|
- `norna` does not define unprefixed project commands such as `build`,
|
|
394
395
|
`test`, and `deploy` in consuming repositories.
|
|
395
|
-
- If project commands need
|
|
396
|
+
- If project commands need Norna behavior, they should call `norna:*`
|
|
396
397
|
scripts.
|
|
397
|
-
- In
|
|
398
|
+
- In standalone site projects, unprefixed project commands may alias `norna:*`
|
|
398
399
|
commands.
|
|
399
400
|
- In mixed projects, unprefixed project commands must not be aliases for only
|
|
400
|
-
the
|
|
401
|
+
the Norna site unless the command name makes that scope explicit.
|
|
401
402
|
- Use `release:*` only for publishing the reusable engine package.
|
|
402
403
|
- Prefer direct `norna ...` commands in engine docs and diagnostics;
|
|
403
404
|
prefer npm scripts in site-repository docs.
|
|
404
405
|
- Do not create separate namespaces for every internal concept. If a command is
|
|
405
|
-
about maintaining the
|
|
406
|
+
about maintaining the Norna dependency in a consuming repository, keep it
|
|
406
407
|
under `norna:*`.
|
|
@@ -26,8 +26,8 @@ site repository. It should not be a showcase for every feature.
|
|
|
26
26
|
An example site is a runnable site that demonstrates one or more features.
|
|
27
27
|
|
|
28
28
|
Examples can be richer than the starter. They may show routes, navigation,
|
|
29
|
-
typography presets, galleries, image carousels, inline
|
|
30
|
-
configuration choices.
|
|
29
|
+
typography presets, typography rhythms, galleries, image carousels, inline
|
|
30
|
+
styles, and site-specific configuration choices.
|
|
31
31
|
|
|
32
32
|
### Documentation Site
|
|
33
33
|
|
|
@@ -70,9 +70,10 @@ they demonstrate a distinct feature or workflow.
|
|
|
70
70
|
|
|
71
71
|
- `dog-gallery/`: current local visual demo, manual inspection site, and
|
|
72
72
|
navigation diagnostic target.
|
|
73
|
-
- `routes-demo/`: focused route/navigation example if dog
|
|
74
|
-
broad.
|
|
75
|
-
- `typography-demo/`: focused typography preset and override example
|
|
73
|
+
- `routes-demo/`: focused route/navigation example if the dog example becomes
|
|
74
|
+
too broad.
|
|
75
|
+
- `typography-demo/`: focused typography preset, rhythm, and override example
|
|
76
|
+
if needed.
|
|
76
77
|
|
|
77
78
|
The repository-local `site/` directory is reserved for the documentation site.
|
|
78
79
|
`docs/` should remain for reference documentation. It should link to the
|
|
@@ -14,13 +14,13 @@ This document is for work on the reusable `norna` package itself.
|
|
|
14
14
|
- `scripts/deploy-site.mjs`: deploy and deploy:commit behavior.
|
|
15
15
|
- `scripts/watch-pages-deploy.mjs`: GitHub Pages workflow monitor.
|
|
16
16
|
- `src/content.config.ts`: Astro content schema.
|
|
17
|
-
- `src/components/` and `src/layouts/`: rendered page, navigation,
|
|
18
|
-
layout.
|
|
17
|
+
- `src/components/` and `src/layouts/`: rendered page, navigation, image rows,
|
|
18
|
+
and layout.
|
|
19
19
|
- `tests/`: Playwright navigation diagnostics.
|
|
20
20
|
- `fixtures/basic/site/`: minimal site used for engine checks.
|
|
21
21
|
- `starters/basic/`: copyable site starter.
|
|
22
|
-
- `examples/dog-gallery/site/`: visual dog
|
|
23
|
-
|
|
22
|
+
- `examples/dog-gallery/site/`: visual dog example used by demo builds and
|
|
23
|
+
navigation diagnostics.
|
|
24
24
|
|
|
25
25
|
The repository-local `site/` directory is reserved for a local documentation
|
|
26
26
|
site. It is useful for dogfooding `norna` documentation, but it is not the
|
|
@@ -48,7 +48,7 @@ npm run dev:local
|
|
|
48
48
|
npm run build
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
-
The dog
|
|
51
|
+
The dog example remains the visual demo and navigation diagnostic target:
|
|
52
52
|
|
|
53
53
|
```sh
|
|
54
54
|
cd examples/dog-gallery/site
|
package/docs/getting-started.md
CHANGED
|
@@ -23,10 +23,10 @@ new site directory:
|
|
|
23
23
|
|
|
24
24
|
```sh
|
|
25
25
|
cd path/to/your/projects
|
|
26
|
-
npx @janga/norna@latest init my-
|
|
27
|
-
cd my-
|
|
26
|
+
npx @janga/norna@latest init my-site
|
|
27
|
+
cd my-site
|
|
28
28
|
npm install
|
|
29
|
-
npm run
|
|
29
|
+
npm run dev
|
|
30
30
|
```
|
|
31
31
|
|
|
32
32
|
After `npm install`, the project's npm scripts use the project-local `norna`
|
|
@@ -45,7 +45,7 @@ engine repository. For example:
|
|
|
45
45
|
```text
|
|
46
46
|
Projects/
|
|
47
47
|
norna/
|
|
48
|
-
my-
|
|
48
|
+
my-site/
|
|
49
49
|
```
|
|
50
50
|
|
|
51
51
|
The starter contains:
|
|
@@ -62,12 +62,13 @@ Commit the generated `package-lock.json` after the first install.
|
|
|
62
62
|
|
|
63
63
|
## First Edits
|
|
64
64
|
|
|
65
|
-
1. Edit `site/config.mjs` for the site's URL,
|
|
66
|
-
|
|
67
|
-
2. Edit `site/theme.md` for site-wide
|
|
68
|
-
|
|
65
|
+
1. Edit `site/config.mjs` for the site's URL, language labels, GitHub
|
|
66
|
+
repository, footer, and deploy settings.
|
|
67
|
+
2. Edit `site/theme.md` for site-wide layout, layout density, typography
|
|
68
|
+
rhythm, image sizing, font, typography preset, colors, inline styles, and
|
|
69
|
+
frame colors, or omit it to use engine defaults.
|
|
69
70
|
3. Edit `site/content.md` for homepage title, description, sections, text,
|
|
70
|
-
|
|
71
|
+
image rows, page/section presentation overrides, alt text, and captions.
|
|
71
72
|
4. Put source images under `site/images/<section-id>/`.
|
|
72
73
|
5. Add optional route pages under
|
|
73
74
|
`site/routes/<route-folder>/route-content.md`.
|
|
@@ -113,20 +114,13 @@ Read [Site Structure](site-structure.md), [Content](content.md),
|
|
|
113
114
|
[Theme](theme.md), [Typography](typography.md), [Routes](routes.md), and
|
|
114
115
|
[Configuration](configuration.md) before publishing a real site.
|
|
115
116
|
|
|
116
|
-
To change the site's maximum page width,
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
To change the site-wide typography preset, edit `site/theme.md`. To change one
|
|
128
|
-
page or section, add a focused `presentation.typography` override in
|
|
129
|
-
`site/content.md`. See [Typography](typography.md). Use
|
|
130
|
-
`npm run norna:typography:presets` to inspect the installed preset values and
|
|
131
|
-
`npm run norna:typography:show` to inspect the resolved typography for the
|
|
132
|
-
selected site.
|
|
117
|
+
To change the site's maximum page width, side gutters, layout density,
|
|
118
|
+
typography rhythm, image width, image height limits, font, colors, or
|
|
119
|
+
site-wide typography preset, edit `site/theme.md`. See [Theme](theme.md) for
|
|
120
|
+
the accepted shape.
|
|
121
|
+
|
|
122
|
+
To change one page or section, add a focused `presentation.typography`
|
|
123
|
+
override in `site/content.md`. See [Typography](typography.md). Use
|
|
124
|
+
`norna typography presets` to inspect the installed preset and rhythm values and
|
|
125
|
+
`norna typography show` to inspect the resolved typography for the selected
|
|
126
|
+
site.
|
|
@@ -15,7 +15,7 @@ Supported source extensions:
|
|
|
15
15
|
- `.png`
|
|
16
16
|
|
|
17
17
|
Image filenames must be globally unique under `site/images/`. The content and
|
|
18
|
-
image scripts reject duplicate filenames because
|
|
18
|
+
image scripts reject duplicate filenames because image rows identify images by
|
|
19
19
|
filename only.
|
|
20
20
|
|
|
21
21
|
## Generated Variants
|
|
@@ -5,7 +5,7 @@ Use the local preview commands when editing a site or the engine demo.
|
|
|
5
5
|
## Start Preview
|
|
6
6
|
|
|
7
7
|
```sh
|
|
8
|
-
npm run
|
|
8
|
+
npm run dev
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
The wrapper:
|
|
@@ -28,7 +28,7 @@ To stop any process that is blocking the standard port before starting, pass
|
|
|
28
28
|
`--kill`:
|
|
29
29
|
|
|
30
30
|
```sh
|
|
31
|
-
npm run
|
|
31
|
+
npm run dev -- --kill
|
|
32
32
|
```
|
|
33
33
|
|
|
34
34
|
For the pure starter's `dev` alias, use:
|
package/docs/publishing.md
CHANGED
|
@@ -79,7 +79,7 @@ npm run norna:deploy:commit -- "Commit message"
|
|
|
79
79
|
|
|
80
80
|
It builds, stages only allowed site changes, commits, pushes, and checks Pages.
|
|
81
81
|
The allowlist is implemented in `scripts/deploy-site.mjs` and includes the
|
|
82
|
-
site content file, selected config/static files, expected
|
|
82
|
+
site content file, selected config/static files, expected generated images,
|
|
83
83
|
generated image manifest, package files, `tsconfig.json`, `astro.config.mjs`,
|
|
84
84
|
and `src/` changes.
|
|
85
85
|
|
package/docs/routes.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
under `site/routes/<route-folder>/route-content.md` and build to first-level
|
|
5
5
|
URLs.
|
|
6
6
|
|
|
7
|
-
Routes use the same page frontmatter, section frontmatter,
|
|
7
|
+
Routes use the same page frontmatter, section frontmatter, image rows, and
|
|
8
8
|
Markdown section model as the homepage. See [Content](content.md) for the page
|
|
9
9
|
and section model.
|
|
10
10
|
|
|
@@ -21,7 +21,7 @@ Minimal route page:
|
|
|
21
21
|
```md
|
|
22
22
|
---
|
|
23
23
|
title: About
|
|
24
|
-
description: About this
|
|
24
|
+
description: About this site.
|
|
25
25
|
navigation:
|
|
26
26
|
label: About
|
|
27
27
|
order: 20
|
package/docs/site-structure.md
CHANGED
|
@@ -30,18 +30,19 @@ site directory. Without an explicit site directory, commands first accept the
|
|
|
30
30
|
current directory when it contains both `config.mjs` and `content.md`.
|
|
31
31
|
Otherwise, commands started from a subdirectory walk upward until they find the
|
|
32
32
|
default `site/` directory containing those files.
|
|
33
|
-
`theme.md` is optional; omit it to use the engine's built-in
|
|
34
|
-
defaults.
|
|
33
|
+
`theme.md` is optional; omit it to use the engine's built-in visual defaults.
|
|
35
34
|
|
|
36
35
|
## Versioned Source Files
|
|
37
36
|
|
|
38
37
|
Version these files in a site repository:
|
|
39
38
|
|
|
40
39
|
- `site/config.mjs`: technical site configuration.
|
|
41
|
-
- `site/theme.md`: optional site-wide visual theme,
|
|
42
|
-
|
|
40
|
+
- `site/theme.md`: optional site-wide visual theme, including layout, spacing,
|
|
41
|
+
image sizing, font, typography defaults, colors, inline styles, and frame
|
|
42
|
+
colors.
|
|
43
|
+
See [Theme](theme.md).
|
|
43
44
|
- `site/content.md`: homepage page file with editable content, section
|
|
44
|
-
definitions,
|
|
45
|
+
definitions, image rows, alt text, and captions. See [Content](content.md).
|
|
45
46
|
- `site/images/<section-id>/`: original source images.
|
|
46
47
|
- `site/routes/<route-folder>/route-content.md`: optional route page files.
|
|
47
48
|
See [Routes](routes.md).
|
|
@@ -83,6 +84,6 @@ In this repository:
|
|
|
83
84
|
- `starters/basic/` is copied by `norna init <target-dir>` to create a
|
|
84
85
|
site repository.
|
|
85
86
|
- `fixtures/basic/site/` is used by engine regression tests.
|
|
86
|
-
- `examples/dog-gallery/site/` is the local visual dog
|
|
87
|
-
|
|
87
|
+
- `examples/dog-gallery/site/` is the local visual dog example used by demo
|
|
88
|
+
builds and navigation diagnostics.
|
|
88
89
|
- `site/` is reserved for the local documentation site.
|