uniweb 1.0.0 → 1.0.2
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/LICENSE +201 -0
- package/README.md +532 -3
- package/package.json +60 -11
- package/partials/adding-pages.hbs +77 -0
- package/partials/agents.md +3000 -0
- package/partials/ai-assistance.hbs +28 -0
- package/partials/components-docs.hbs +13 -0
- package/partials/config-reference.hbs +66 -0
- package/partials/deployment.hbs +13 -0
- package/partials/learn-more.hbs +6 -0
- package/partials/quick-start.hbs +8 -0
- package/partials/search-docs.hbs +110 -0
- package/src/backend/asset-download.js +222 -0
- package/src/backend/client.js +986 -0
- package/src/backend/foundation-bring-along.js +692 -0
- package/src/backend/payment-handoff.js +362 -0
- package/src/backend/service-request.js +210 -0
- package/src/backend/site-media.js +255 -0
- package/src/backend/site-preview.js +77 -0
- package/src/backend/site-sync.js +2515 -0
- package/src/backend/workspace.js +234 -0
- package/src/commands/add.js +1900 -0
- package/src/commands/build.js +1214 -0
- package/src/commands/clone.js +466 -0
- package/src/commands/content.js +202 -0
- package/src/commands/deploy.js +537 -0
- package/src/commands/dev.js +202 -0
- package/src/commands/docs.js +530 -0
- package/src/commands/doctor.js +1982 -0
- package/src/commands/export.js +116 -0
- package/src/commands/families.js +82 -0
- package/src/commands/forget.js +197 -0
- package/src/commands/handoff.js +21 -0
- package/src/commands/i18n.js +1707 -0
- package/src/commands/inspect.js +375 -0
- package/src/commands/invite.js +24 -0
- package/src/commands/org.js +96 -0
- package/src/commands/publish.js +1087 -0
- package/src/commands/pull.js +1257 -0
- package/src/commands/push.js +663 -0
- package/src/commands/refresh.js +212 -0
- package/src/commands/register.js +1092 -0
- package/src/commands/rename.js +647 -0
- package/src/commands/site.js +358 -0
- package/src/commands/snapshot.js +461 -0
- package/src/commands/starter.js +206 -0
- package/src/commands/status.js +302 -0
- package/src/commands/sync.js +93 -0
- package/src/commands/template.js +107 -0
- package/src/commands/update.js +887 -0
- package/src/commands/validate.js +376 -0
- package/src/framework-index.json +248 -0
- package/src/index.js +2241 -0
- package/src/templates/fetchers/github.js +113 -0
- package/src/templates/fetchers/npm.js +85 -0
- package/src/templates/fetchers/release.js +92 -0
- package/src/templates/index.js +190 -0
- package/src/templates/processor.js +333 -0
- package/src/templates/resolver.js +232 -0
- package/src/templates/validator.js +155 -0
- package/src/utils/agents-stamp.js +110 -0
- package/src/utils/args.js +126 -0
- package/src/utils/asset-upload.js +270 -0
- package/src/utils/bytes.js +30 -0
- package/src/utils/code-upload.js +394 -0
- package/src/utils/config.js +417 -0
- package/src/utils/conformance.js +274 -0
- package/src/utils/dep-survey.js +176 -0
- package/src/utils/destination-prompt.js +146 -0
- package/src/utils/discover.js +75 -0
- package/src/utils/env.js +22 -0
- package/src/utils/exit.js +30 -0
- package/src/utils/fetch-retry.js +109 -0
- package/src/utils/flag-guard.js +246 -0
- package/src/utils/foundation-name.js +179 -0
- package/src/utils/git.js +342 -0
- package/src/utils/host-prompt.js +51 -0
- package/src/utils/install-integrity.js +210 -0
- package/src/utils/interactive.js +118 -0
- package/src/utils/json-file.js +72 -0
- package/src/utils/names.js +91 -0
- package/src/utils/placement.js +151 -0
- package/src/utils/pm.js +165 -0
- package/src/utils/preview.js +20 -0
- package/src/utils/pull-written.js +132 -0
- package/src/utils/records-guard.js +88 -0
- package/src/utils/registry-auth.js +994 -0
- package/src/utils/registry-orgs.js +290 -0
- package/src/utils/scaffold.js +483 -0
- package/src/utils/schemaless-report.js +30 -0
- package/src/utils/semver-precedence.js +80 -0
- package/src/utils/session-file.js +95 -0
- package/src/utils/site-content-refs.js +23 -0
- package/src/utils/site-copies.js +123 -0
- package/src/utils/site-data-upload.js +302 -0
- package/src/utils/site-identity.js +137 -0
- package/src/utils/snapshot-settings.js +112 -0
- package/src/utils/update-check.js +302 -0
- package/src/utils/uwx-read.js +157 -0
- package/src/utils/workspace.js +223 -0
- package/src/versions.js +467 -0
- package/starter/foundation/main.js +50 -0
- package/starter/foundation/sections/Section/index.jsx +95 -0
- package/starter/foundation/sections/Section/meta.js +44 -0
- package/starter/site/pages/about/1-about.md.hbs +13 -0
- package/starter/site/pages/about/page.yml +3 -0
- package/starter/site/pages/home/1-welcome.md.hbs +14 -0
- package/starter/site/pages/home/page.yml +3 -0
- package/templates/foundation/_gitignore +5 -0
- package/templates/foundation/components/.gitkeep +0 -0
- package/templates/foundation/main.js.hbs +33 -0
- package/templates/foundation/package.json.hbs +51 -0
- package/templates/foundation/sections/.gitkeep +0 -0
- package/templates/foundation/styles.css +6 -0
- package/templates/foundation/vite.config.js +3 -0
- package/templates/site/_gitignore +12 -0
- package/templates/site/entry.js +7 -0
- package/templates/site/index.html.hbs +13 -0
- package/templates/site/package.json.hbs +27 -0
- package/templates/site/public/favicon.svg +7 -0
- package/templates/site/site.yml.hbs +91 -0
- package/templates/site/theme.yml +99 -0
- package/templates/site/vite.config.js +7 -0
- package/templates/workspace/AGENTS.md.hbs +2 -0
- package/templates/workspace/README.md.hbs +87 -0
- package/templates/workspace/_gitignore +29 -0
- package/templates/workspace/_vscode/settings.json +6 -0
- package/templates/workspace/package.json.hbs +20 -0
- package/templates/workspace/pnpm-workspace.yaml.hbs +26 -0
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
### Adding a New Page
|
|
2
|
+
|
|
3
|
+
1. Create a folder: `site/pages/my-page/`
|
|
4
|
+
2. Add `page.yml`:
|
|
5
|
+
```yaml
|
|
6
|
+
title: My Page
|
|
7
|
+
```
|
|
8
|
+
3. Add section files: `1-hero.md`, `2-content.md`, etc.
|
|
9
|
+
|
|
10
|
+
### Section Ordering
|
|
11
|
+
|
|
12
|
+
By default, sections are discovered from `.md` files and sorted by numeric prefix (`1-`, `2-`, `3-`).
|
|
13
|
+
|
|
14
|
+
**Decimal prefixes** allow inserting sections without renumbering: `2.5-` sorts between `2-` and `3-`.
|
|
15
|
+
|
|
16
|
+
For explicit control, use the `sections` property in `page.yml`:
|
|
17
|
+
|
|
18
|
+
```yaml
|
|
19
|
+
title: My Page
|
|
20
|
+
sections:
|
|
21
|
+
- hero
|
|
22
|
+
- features
|
|
23
|
+
- pricing
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
This makes reordering easy (move lines) and allows commenting out sections temporarily.
|
|
27
|
+
|
|
28
|
+
**Options:**
|
|
29
|
+
- `sections: *` or omit — auto-discover and sort `.md` files by prefix (default)
|
|
30
|
+
- `sections: [hero, features]` — explicit ordering, no prefixes needed
|
|
31
|
+
- `sections: []` — pure route with no content sections
|
|
32
|
+
|
|
33
|
+
### Section Hierarchy (Subsections)
|
|
34
|
+
|
|
35
|
+
For parent-child relationships, use the explicit array with nesting:
|
|
36
|
+
|
|
37
|
+
```yaml
|
|
38
|
+
sections:
|
|
39
|
+
- hero
|
|
40
|
+
- features:
|
|
41
|
+
- logocloud
|
|
42
|
+
- stats
|
|
43
|
+
- pricing
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
This is clearer than prefix notation and easier to restructure.
|
|
47
|
+
|
|
48
|
+
**Advanced:** Comma prefixes (`1,1-`, `1,2-`) also denote hierarchy, but explicit arrays are recommended for readability.
|
|
49
|
+
|
|
50
|
+
### Page Ordering and Index Pages
|
|
51
|
+
|
|
52
|
+
Parent controls which page is the "index" for its route. The index page gets the parent's route.
|
|
53
|
+
|
|
54
|
+
**In `site.yml`** (for top-level pages):
|
|
55
|
+
```yaml
|
|
56
|
+
name: My Site
|
|
57
|
+
pages: [home, about, features] # First (home) is homepage at /
|
|
58
|
+
# Or just name the homepage:
|
|
59
|
+
index: home
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
**In `page.yml`** (for child pages):
|
|
63
|
+
```yaml
|
|
64
|
+
title: Documentation
|
|
65
|
+
pages: [getting-started, installation, config] # First is index for /docs
|
|
66
|
+
# Or just name the index:
|
|
67
|
+
index: getting-started
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
**How it works:**
|
|
71
|
+
- `pages: [a, b, c]` — Explicit order, first item gets parent route
|
|
72
|
+
- `index: name` — Just set the index, auto-discover the rest
|
|
73
|
+
- Omit both — Sort by `order` prop, lowest becomes index
|
|
74
|
+
|
|
75
|
+
**Example:** If `getting-started` is the index for `/docs`:
|
|
76
|
+
- `pages/docs/getting-started/` → route `/docs`
|
|
77
|
+
- `pages/docs/installation/` → route `/docs/installation`
|