@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.
Files changed (88) hide show
  1. package/README.md +16 -16
  2. package/bin/norna-cli.mjs +12 -7
  3. package/docs/README.md +11 -12
  4. package/docs/commands.md +9 -9
  5. package/docs/configuration.md +14 -145
  6. package/docs/content.md +17 -15
  7. package/docs/design/command-organization.md +58 -57
  8. package/docs/design/site-examples-structure.md +6 -5
  9. package/docs/engine-development.md +5 -5
  10. package/docs/getting-started.md +20 -26
  11. package/docs/images-and-metadata.md +1 -1
  12. package/docs/local-development.md +2 -2
  13. package/docs/publishing.md +1 -1
  14. package/docs/routes.md +2 -2
  15. package/docs/site-structure.md +8 -7
  16. package/docs/theme.md +133 -7
  17. package/docs/typography.md +78 -43
  18. package/examples/dog-gallery/node_modules/.vite/deps/_metadata.json +74 -0
  19. package/examples/dog-gallery/node_modules/.vite/deps/astro-D_GIpJIE.js +434 -0
  20. package/examples/dog-gallery/node_modules/.vite/deps/astro-D_GIpJIE.js.map +1 -0
  21. package/examples/dog-gallery/node_modules/.vite/deps/astro_n_aria-query.js +6390 -0
  22. package/examples/dog-gallery/node_modules/.vite/deps/astro_n_aria-query.js.map +1 -0
  23. package/examples/dog-gallery/node_modules/.vite/deps/astro_n_axobject-query.js +2702 -0
  24. package/examples/dog-gallery/node_modules/.vite/deps/astro_n_axobject-query.js.map +1 -0
  25. package/examples/dog-gallery/node_modules/.vite/deps/astro_n_html-escaper.js +65 -0
  26. package/examples/dog-gallery/node_modules/.vite/deps/astro_n_html-escaper.js.map +1 -0
  27. package/examples/dog-gallery/node_modules/.vite/deps/astro_runtime_client_dev-toolbar_entrypoint__js.js +455 -0
  28. package/examples/dog-gallery/node_modules/.vite/deps/astro_runtime_client_dev-toolbar_entrypoint__js.js.map +1 -0
  29. package/examples/dog-gallery/node_modules/.vite/deps/audit-DM9Hkl5B.js +1534 -0
  30. package/examples/dog-gallery/node_modules/.vite/deps/audit-DM9Hkl5B.js.map +1 -0
  31. package/examples/dog-gallery/node_modules/.vite/deps/highlight-DnZ1ULOL.js +48 -0
  32. package/examples/dog-gallery/node_modules/.vite/deps/highlight-DnZ1ULOL.js.map +1 -0
  33. package/examples/dog-gallery/node_modules/.vite/deps/icons-RyebKi45.js +42 -0
  34. package/examples/dog-gallery/node_modules/.vite/deps/icons-RyebKi45.js.map +1 -0
  35. package/examples/dog-gallery/node_modules/.vite/deps/package.json +3 -0
  36. package/examples/dog-gallery/node_modules/.vite/deps/rolldown-runtime-BvCyGRYZ.js +4 -0
  37. package/examples/dog-gallery/node_modules/.vite/deps/settings-DaU-gNnK.js +190 -0
  38. package/examples/dog-gallery/node_modules/.vite/deps/settings-DaU-gNnK.js.map +1 -0
  39. package/examples/dog-gallery/node_modules/.vite/deps/toolbar-63PA619H.js +458 -0
  40. package/examples/dog-gallery/node_modules/.vite/deps/toolbar-63PA619H.js.map +1 -0
  41. package/examples/dog-gallery/node_modules/.vite/deps/ui-library--bkcNSYz.js +1016 -0
  42. package/examples/dog-gallery/node_modules/.vite/deps/ui-library--bkcNSYz.js.map +1 -0
  43. package/examples/dog-gallery/node_modules/.vite/deps/window-jPkpKVcy.js +32 -0
  44. package/examples/dog-gallery/node_modules/.vite/deps/window-jPkpKVcy.js.map +1 -0
  45. package/examples/dog-gallery/node_modules/.vite/deps/xray-BXCHpEJP.js +111 -0
  46. package/examples/dog-gallery/node_modules/.vite/deps/xray-BXCHpEJP.js.map +1 -0
  47. package/examples/dog-gallery/site/config.mjs +12 -42
  48. package/examples/dog-gallery/site/content.md +28 -6
  49. package/examples/dog-gallery/site/routes/dog-care/route-content.md +17 -3
  50. package/examples/dog-gallery/site/theme.md +83 -26
  51. package/fixtures/basic/site/config.mjs +2 -22
  52. package/fixtures/basic/site/content.md +1 -1
  53. package/fixtures/basic/site/theme.md +7 -3
  54. package/package.json +3 -3
  55. package/scripts/check-config.mjs +4 -3
  56. package/scripts/deploy-site.mjs +3 -3
  57. package/scripts/init-site.mjs +10 -8
  58. package/scripts/lib/frontmatter-yaml.mjs +85 -0
  59. package/scripts/lib/presentation.mjs +10 -11
  60. package/scripts/lib/project-config.mjs +146 -45
  61. package/scripts/lib/site-content.mjs +21 -3
  62. package/scripts/lib/theme-config.mjs +34 -0
  63. package/scripts/lib/typography.mjs +155 -35
  64. package/scripts/show-typography.mjs +127 -159
  65. package/scripts/sync-content-sections.mjs +6 -6
  66. package/scripts/test-content-check.mjs +3 -4
  67. package/scripts/test-engine-commands.mjs +21 -3
  68. package/scripts/test-package-check.mjs +34 -17
  69. package/scripts/test-temporary-visibility.mjs +2 -3
  70. package/src/components/SitePage.astro +2 -3
  71. package/src/components/SiteSection.astro +115 -19
  72. package/src/content.config.ts +66 -6
  73. package/src/layouts/BaseLayout.astro +11 -0
  74. package/src/styles/global.css +83 -52
  75. package/starters/basic/README.md +11 -15
  76. package/starters/basic/package.json +2 -2
  77. package/starters/basic/site/config.mjs +3 -24
  78. package/starters/basic/site/content.md +40 -7
  79. package/starters/basic/site/theme.md +84 -18
  80. package/starters/project/.github/workflows/deploy.yml +65 -0
  81. package/starters/project/README.md +72 -0
  82. package/starters/project/package-lock.json +4296 -0
  83. package/starters/project/package.json +35 -0
  84. package/starters/project/site/config.mjs +43 -0
  85. package/starters/project/site/content.md +128 -0
  86. package/starters/project/site/public/robots.txt +2 -0
  87. package/starters/project/site/routes/guide/route-content.md +85 -0
  88. package/starters/project/site/theme.md +43 -0
@@ -0,0 +1,35 @@
1
+ {
2
+ "name": "project-site",
3
+ "private": true,
4
+ "type": "module",
5
+ "scripts": {
6
+ "dev": "npm run norna:dev --",
7
+ "norna:dev": "norna dev:local",
8
+ "norna:dev:lan": "norna dev:lan",
9
+ "norna:dev:restart": "norna dev:restart",
10
+ "norna:dev:status": "norna dev:status",
11
+ "norna:dev:logs": "norna dev:logs",
12
+ "norna:dev:stop": "norna dev:stop",
13
+ "norna:check": "npm run norna:config:check && npm run norna:content:check",
14
+ "norna:config:check": "norna config:check",
15
+ "norna:content:check": "norna content:check",
16
+ "norna:sync": "norna content:sync",
17
+ "norna:typography:presets": "norna typography presets",
18
+ "norna:typography:show": "norna typography show",
19
+ "norna:public": "norna site:public",
20
+ "norna:images": "norna images",
21
+ "norna:build": "norna build",
22
+ "norna:build:local": "norna build:local",
23
+ "norna:deploy": "norna deploy",
24
+ "norna:deploy:commit": "norna deploy:commit",
25
+ "norna:deploy:watch": "norna deploy:watch",
26
+ "norna:doctor": "norna doctor",
27
+ "norna:preview": "norna preview",
28
+ "norna:engine:update": "norna engine:update",
29
+ "norna:engine:version": "norna engine:version",
30
+ "build": "npm run norna:build"
31
+ },
32
+ "dependencies": {
33
+ "@janga/norna": "0.7.3"
34
+ }
35
+ }
@@ -0,0 +1,43 @@
1
+ export default {
2
+ site: {
3
+ url: 'https://example.com/',
4
+ basePath: '/',
5
+ },
6
+ navigation: {
7
+ smoothScroll: {
8
+ enabled: true,
9
+ minimumDurationMs: 500,
10
+ maximumDurationMs: 1_100,
11
+ durationPerPixelMs: 0.18,
12
+ },
13
+ },
14
+ locale: {
15
+ lang: 'en',
16
+ labels: {
17
+ skipToContent: 'Skip to content',
18
+ siteNavigation: 'Pages',
19
+ pageNavigation: 'On this page',
20
+ sectionNavigation: 'Sections',
21
+ menu: 'Menu',
22
+ gallery: 'Images',
23
+ },
24
+ },
25
+ footer: {
26
+ copyrightMessage: '(c) Project contributors.',
27
+ buildInfo: {
28
+ enabled: true,
29
+ text: 'Built',
30
+ dateTimeFormat: {
31
+ locale: 'en-GB',
32
+ timeZone: 'UTC',
33
+ dateStyle: 'short',
34
+ timeStyle: 'short',
35
+ },
36
+ },
37
+ },
38
+ github: {
39
+ repo: 'owner/project-name',
40
+ branch: 'main',
41
+ pagesWorkflow: 'Deploy to GitHub Pages',
42
+ },
43
+ };
@@ -0,0 +1,128 @@
1
+ ---
2
+ title: Your project
3
+ description: A compact project site starter for an open source developer tool.
4
+ navigation:
5
+ label: Home
6
+ order: 0
7
+ sections:
8
+ - id: intro
9
+ - id: links
10
+ - id: install
11
+ - id: example
12
+ - id: why
13
+ - id: good-fit
14
+ - id: next
15
+ - id: license
16
+ ---
17
+
18
+ ## `<Your project> - <short value proposition>` {#intro}
19
+
20
+ Describe the project in one short, concrete phrase. Focus on what it helps the
21
+ user accomplish rather than implementation details.
22
+
23
+ > Example: **Checkline - keep project checks simple.**
24
+
25
+ `<Your project>` is an open source `<tool / library / CLI>` for
26
+ `<main purpose>`.
27
+
28
+ Briefly explain what the project does and who it is for. Optionally mention one
29
+ or two qualities that distinguish it.
30
+
31
+ > Example: Checkline is a small open source developer tool for running project
32
+ > checks from the command line or automated workflows.
33
+
34
+ ## Project links {#links}
35
+
36
+ Link to the most useful project resources. Keep only the links that are
37
+ relevant.
38
+
39
+ - [GitHub repository](https://github.com/owner/project)
40
+ - [Guide / Documentation](/guide/)
41
+ - [Package](https://www.npmjs.com/package/project)
42
+ - [Issue tracker](https://github.com/owner/project/issues)
43
+
44
+ ## Install {#install}
45
+
46
+ Show the simplest normal way to install the project. Add requirements or other
47
+ explanation only when needed.
48
+
49
+ ```sh
50
+ <install command>
51
+ ```
52
+
53
+ > Example:
54
+ >
55
+ > ```sh
56
+ > npm install checkline
57
+ > ```
58
+
59
+ ## Example {#example}
60
+
61
+ Show the smallest realistic example that demonstrates the project's main value.
62
+ More advanced usage belongs in the guide.
63
+
64
+ ```sh
65
+ <main command or minimal usage example>
66
+ ```
67
+
68
+ > Example:
69
+ >
70
+ > ```sh
71
+ > npx checkline
72
+ > ```
73
+
74
+ If a programmatic API is central to the project, a similarly small API example
75
+ may also be shown.
76
+
77
+ ## Why `<Your project>`? {#why}
78
+
79
+ Give two or three concrete reasons someone might choose the project. Focus on
80
+ meaningful benefits rather than generic claims such as "fast", "powerful", or
81
+ "easy to use".
82
+
83
+ ### `<Primary benefit>`
84
+
85
+ Explain the benefit in one or two sentences.
86
+
87
+ > Example:
88
+ >
89
+ > ### Fits existing workflows
90
+ >
91
+ > Use Checkline from the command line, project scripts, or automated workflows
92
+ > without introducing a separate service.
93
+
94
+ ### `<Secondary benefit>`
95
+
96
+ Explain another important property or advantage.
97
+
98
+ > Example:
99
+ >
100
+ > ### Configuration stays with the project
101
+ >
102
+ > Keep configuration alongside the rest of the source files so changes remain
103
+ > visible and versioned.
104
+
105
+ Add a third benefit only when it adds useful information.
106
+
107
+ ## Good fit for {#good-fit}
108
+
109
+ Help visitors decide whether the project matches their needs. Describe a few
110
+ realistic situations or workflows rather than repeating the feature list.
111
+
112
+ > Example: Checkline is a good fit for projects that want lightweight checks
113
+ > that can run locally and in automated workflows without adding separate
114
+ > infrastructure.
115
+
116
+ ## Next steps {#next}
117
+
118
+ Give the visitor a clear path forward.
119
+
120
+ > Example: Read the [guide](/guide/) to get started, or visit the GitHub
121
+ > repository for source code, issues, and contribution information.
122
+
123
+ ## License {#license}
124
+
125
+ State the project's license and link to the license file when one exists.
126
+
127
+ > Example: Checkline is released under the MIT License. See
128
+ > [LICENSE](https://github.com/owner/checkline/blob/main/LICENSE) for details.
@@ -0,0 +1,2 @@
1
+ User-agent: *
2
+ Allow: /
@@ -0,0 +1,85 @@
1
+ ---
2
+ title: Guide
3
+ description: Adapt this compact guide for normal project use.
4
+ navigation:
5
+ label: Guide
6
+ order: 10
7
+ sections:
8
+ - id: quickstart
9
+ - id: configuration
10
+ - id: usage
11
+ - id: topic
12
+ ---
13
+
14
+ ## Quickstart {#quickstart}
15
+
16
+ Show the shortest path from installation to a useful result.
17
+
18
+ ```sh
19
+ <install command>
20
+ <first useful command>
21
+ ```
22
+
23
+ Briefly explain what happens and what the user should expect.
24
+
25
+ > Example:
26
+ >
27
+ > ```sh
28
+ > npm install checkline
29
+ > npx checkline
30
+ > ```
31
+ >
32
+ > The command runs the default project check and prints a short result in the
33
+ > terminal.
34
+
35
+ ## Configuration {#configuration}
36
+
37
+ Include this section only if configuration is relevant. Explain when
38
+ configuration is needed and show the smallest realistic example.
39
+
40
+ ```js
41
+ export default {
42
+ // project-specific options
43
+ };
44
+ ```
45
+
46
+ If the project works well without configuration, say so.
47
+
48
+ > Example: Checkline can run without configuration. Add a config file only when
49
+ > the default paths or command behavior need to change.
50
+
51
+ ## Using `<Your project>` {#usage}
52
+
53
+ Show one slightly more complete example of the normal workflow. The purpose is
54
+ to demonstrate typical use, not every available command or option.
55
+
56
+ > Example: A project might keep the command in `package.json`:
57
+
58
+ ```json
59
+ {
60
+ "scripts": {
61
+ "check": "checkline"
62
+ }
63
+ }
64
+ ```
65
+
66
+ ```sh
67
+ npm run check
68
+ ```
69
+
70
+ ## `<API / Commands / Integration / Deployment>` {#topic}
71
+
72
+ Choose the topic that best fits the project. For a library this may be `API`;
73
+ for a CLI it may be `Commands`; other projects may need `Integration`,
74
+ `Deployment`, or something else.
75
+
76
+ For example, if a JavaScript API is relevant:
77
+
78
+ ```js
79
+ import { check } from 'checkline';
80
+
81
+ const result = await check();
82
+ ```
83
+
84
+ Keep the example deliberately small. Detailed reference documentation can live
85
+ elsewhere as the project grows.
@@ -0,0 +1,43 @@
1
+ ---
2
+ # Site-wide visual defaults. Remove a value to use the engine default.
3
+ navigation:
4
+ brand: Project Name
5
+ layout:
6
+ density: compact
7
+ pageWidth: 1120px
8
+ gutter:
9
+ desktop: clamp(1.25rem, 4vw, 3rem)
10
+ mobile: 1rem
11
+ spacing:
12
+ firstSectionTop:
13
+ desktop: clamp(0.9rem, 1.6vw, 1.5rem)
14
+ mobile: 0.9rem
15
+ sectionGap:
16
+ desktop: clamp(0.8rem, 1.6vw, 1.5rem)
17
+ mobile: 1rem
18
+ finalSectionBottom:
19
+ desktop: clamp(1rem, 2vw, 1.75rem)
20
+ mobile: 1rem
21
+ gallery:
22
+ width: 840px
23
+ maxAvailableWidthPercent:
24
+ desktop: 100
25
+ mobile: 100
26
+ maxAvailableHeightPercent:
27
+ desktop: 70
28
+ mobile: 62
29
+ typography:
30
+ fontFamily: "Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif"
31
+ preset: text-forward
32
+ rhythm: compact
33
+ presentation:
34
+ backgroundColor: "#001314"
35
+ textColor: "#f6f1e8"
36
+ inlineStyles:
37
+ accent:
38
+ color: "#8fd3ff"
39
+ muted:
40
+ color: "#b8b1a6"
41
+ frame:
42
+ colors: presentation
43
+ ---