frontpage-host 0.1.3 → 0.1.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/AGENTS.md +22 -0
- package/dist/completions/generate.js +1 -1
- package/dist/registry.d.ts +1 -1
- package/dist/registry.js +58 -4
- package/llms.txt +2 -1
- package/package.json +1 -1
package/AGENTS.md
CHANGED
|
@@ -92,6 +92,27 @@ Rules:
|
|
|
92
92
|
7. Prefer reviewing the subdomain after push; only use `deploy wait` if you need to block until a build finishes.
|
|
93
93
|
8. The **UI / canvas agent does not use this CLI** — it edits the live tip in-process. Only CLI checkouts need `pull`.
|
|
94
94
|
|
|
95
|
+
## Site contract (Astro)
|
|
96
|
+
|
|
97
|
+
Sites are Astro 6 + Tailwind v4. More detail: `frontpage help site-building` or https://frontpage.host/developers/site-building
|
|
98
|
+
|
|
99
|
+
1. **Every page** wraps content in `<BaseLayout title="…" description="…">` (import from `src/layouts/BaseLayout.astro`).
|
|
100
|
+
2. **`src/config/site.ts`** — keep `pages` (path registry) and `nav` in sync when adding/renaming/deleting page files. Tab title comes from BaseLayout, not the `pages` map label.
|
|
101
|
+
3. **One file per URL** for similar page sets (services, guides, …). Do not default to `getStaticPaths()` over `src/data/*.ts`. Blog/news → `frontpage articles`, not a hand-rolled catalog.
|
|
102
|
+
4. **No backends / databases / fake forms or checkout.** Real forms use `<form data-fp-form="slug">` + `frontpage modules`. Refuse or use modules for payments.
|
|
103
|
+
5. **Tokens** in `src/config/tokens.ts` — keep required color/font/spacing/radii keys; style via CSS variables / token Tailwind. Setting a font token is not enough — apply `font-sans` / `font-serif` / `font-display`. No CLI font catalog yet; use existing tokens or `frontpage prompt`.
|
|
104
|
+
6. **Shared chrome** — prefer `src/components/Header.astro` + `Footer.astro` (or `chrome: { managed: true }` in `site.ts`).
|
|
105
|
+
7. **404** — customize `src/pages/404.astro` if needed; keep `frontpage:404` meta; never register `/404` in `nav`/`pages`.
|
|
106
|
+
8. **Platform-owned paths** stay off-limits (BaseLayout overlay, module/extension shells, `package.json`, …). Customer layouts like `DocsLayout` / `GuideLayout` are OK.
|
|
107
|
+
|
|
108
|
+
## Modules & articles
|
|
109
|
+
|
|
110
|
+
- Forms: `data-fp-form` markup in pages + `frontpage modules` for enable/config. No submit JS / honeypot / `action`.
|
|
111
|
+
- Articles: `frontpage articles …` for lifecycle; bodies via sync under `content/` or `articles content get|set`. Section landing is an owned `src/pages/<section>/index.astro`.
|
|
112
|
+
- Migrate a folder into Articles: prefer `frontpage prompt "migrate … into articles"` — do not invent a mass delete+write migration.
|
|
113
|
+
- Extensions: `frontpage extensions`; if LOCKED on plan, do not fake charts/etc.
|
|
114
|
+
- Media in markup: `/__media/uploads/<slug>/…` from `frontpage media` (not raw blob URLs).
|
|
115
|
+
|
|
95
116
|
## Agent prompt loop
|
|
96
117
|
|
|
97
118
|
```bash
|
|
@@ -194,6 +215,7 @@ Safe default after finishing work: summarize what changed and give the staging U
|
|
|
194
215
|
frontpage help
|
|
195
216
|
frontpage help --json
|
|
196
217
|
frontpage help sync
|
|
218
|
+
frontpage help site-building
|
|
197
219
|
frontpage help agent
|
|
198
220
|
frontpage doctor --json
|
|
199
221
|
```
|
|
@@ -14,7 +14,7 @@ _frontpage_completions() {
|
|
|
14
14
|
fi
|
|
15
15
|
local cmd="\${COMP_WORDS[1]}"
|
|
16
16
|
case "\${cmd}" in
|
|
17
|
-
help) COMPREPLY=( $(compgen -W "\${cmds} quickstart auth sync agent content history isolation exit-codes" -- "\${cur}") ) ;;
|
|
17
|
+
help) COMPREPLY=( $(compgen -W "\${cmds} quickstart auth sync site-building agent content history isolation exit-codes" -- "\${cur}") ) ;;
|
|
18
18
|
completion) COMPREPLY=( $(compgen -W "bash zsh fish" -- "\${cur}") ) ;;
|
|
19
19
|
runs) COMPREPLY=( $(compgen -W "list current wait cancel retry get" -- "\${cur}") ) ;;
|
|
20
20
|
deploy) COMPREPLY=( $(compgen -W "wait" -- "\${cur}") ) ;;
|
package/dist/registry.d.ts
CHANGED
|
@@ -14,6 +14,6 @@ export type CommandDef = {
|
|
|
14
14
|
seeAlso?: string[];
|
|
15
15
|
};
|
|
16
16
|
export declare const COMMANDS: readonly CommandDef[];
|
|
17
|
-
export declare const TOPIC_NAMES: readonly ["quickstart", "auth", "sync", "agent", "content", "history", "isolation", "exit-codes"];
|
|
17
|
+
export declare const TOPIC_NAMES: readonly ["quickstart", "auth", "sync", "site-building", "agent", "content", "history", "isolation", "exit-codes"];
|
|
18
18
|
export declare const TOPICS: Record<string, string>;
|
|
19
19
|
export declare function findCommand(name: string): CommandDef | undefined;
|
package/dist/registry.js
CHANGED
|
@@ -7,8 +7,24 @@ export const COMMANDS = [
|
|
|
7
7
|
name: "help",
|
|
8
8
|
summary: "Show available commands",
|
|
9
9
|
usage: "frontpage help [command|topic] [--json]",
|
|
10
|
-
topics: [
|
|
11
|
-
|
|
10
|
+
topics: [
|
|
11
|
+
"auth",
|
|
12
|
+
"sync",
|
|
13
|
+
"site-building",
|
|
14
|
+
"agent",
|
|
15
|
+
"content",
|
|
16
|
+
"history",
|
|
17
|
+
"isolation",
|
|
18
|
+
"exit-codes",
|
|
19
|
+
"quickstart",
|
|
20
|
+
],
|
|
21
|
+
examples: [
|
|
22
|
+
"frontpage help",
|
|
23
|
+
"frontpage help sync",
|
|
24
|
+
"frontpage help site-building",
|
|
25
|
+
"frontpage help push",
|
|
26
|
+
"frontpage help --json",
|
|
27
|
+
],
|
|
12
28
|
},
|
|
13
29
|
{
|
|
14
30
|
name: "login",
|
|
@@ -291,6 +307,7 @@ export const TOPIC_NAMES = [
|
|
|
291
307
|
"quickstart",
|
|
292
308
|
"auth",
|
|
293
309
|
"sync",
|
|
310
|
+
"site-building",
|
|
294
311
|
"agent",
|
|
295
312
|
"content",
|
|
296
313
|
"history",
|
|
@@ -315,8 +332,8 @@ export const TOPICS = {
|
|
|
315
332
|
|
|
316
333
|
Staging is the subdomain. There is no separate staging-deploy step for agents.
|
|
317
334
|
Never publish/unpublish unless the user explicitly asks.
|
|
318
|
-
Agents: read AGENTS.md
|
|
319
|
-
More: frontpage help auth | sync | agent | content | history | isolation | exit-codes`,
|
|
335
|
+
Agents: read AGENTS.md + frontpage help site-building; use --json for structured I/O.
|
|
336
|
+
More: frontpage help auth | sync | site-building | agent | content | history | isolation | exit-codes`,
|
|
320
337
|
auth: `Authentication
|
|
321
338
|
1. Create a key in the Frontpage editor: profile menu → Developers
|
|
322
339
|
2. frontpage login
|
|
@@ -353,6 +370,39 @@ export const TOPICS = {
|
|
|
353
370
|
- No separate "deploy to staging" step for agents — review the subdomain after the build.
|
|
354
371
|
- frontpage deploy wait only waits for an in-flight build; it is NOT go-live.
|
|
355
372
|
- frontpage publish promotes staging → production (custom domain). Never publish unless asked.`,
|
|
373
|
+
"site-building": `Site building (Astro contract)
|
|
374
|
+
Stack: Astro 6 + Tailwind v4. Pages in src/pages/. Every page wraps <BaseLayout title description>.
|
|
375
|
+
Control files: src/config/tokens.ts (design tokens), src/config/site.ts (title, nav, pages map, seo).
|
|
376
|
+
|
|
377
|
+
Pages map:
|
|
378
|
+
- Add/rename/delete a page file ⇒ update pages (+ nav if needed) in the SAME change set.
|
|
379
|
+
- Real title/description live on <BaseLayout>, not as authority in the pages map.
|
|
380
|
+
- One discrete .astro file per URL for similar sets (services, guides…). Do NOT default to
|
|
381
|
+
getStaticPaths() over src/data/*.ts. Blog/news → frontpage articles.
|
|
382
|
+
|
|
383
|
+
Hard fences:
|
|
384
|
+
- No API routes, serverless backends, or databases.
|
|
385
|
+
- No fake lead forms / checkout / card fields — use data-fp-* modules + frontpage modules, or refuse.
|
|
386
|
+
- Platform-owned paths are not syncable (BaseLayout overlay, module/extension shells, package.json…).
|
|
387
|
+
- Customer layouts (DocsLayout, GuideLayout, …) are fine when site-owned.
|
|
388
|
+
|
|
389
|
+
Tokens & fonts:
|
|
390
|
+
- Keep required colors/fonts/spacing/radii keys; style via CSS variables / token Tailwind.
|
|
391
|
+
- Setting fonts.sans is not enough — apply font-sans / font-serif / font-display on elements.
|
|
392
|
+
- No frontpage fonts catalog command yet; read tokens.ts or frontpage prompt.
|
|
393
|
+
|
|
394
|
+
Chrome / SEO / 404:
|
|
395
|
+
- Prefer src/components/Header.astro + Footer.astro (or chrome: { managed: true } in site.ts).
|
|
396
|
+
- seo block in site.ts + frontpage seo get|set; customize 404.astro but keep frontpage:404 meta;
|
|
397
|
+
never put /404 in nav or pages. robots/sitemap are platform-managed.
|
|
398
|
+
|
|
399
|
+
Modules & articles (short):
|
|
400
|
+
- Forms: <form data-fp-form="slug"> with named inputs; no action/onsubmit/honeypot.
|
|
401
|
+
- Articles: frontpage articles …; migrate folders via frontpage prompt (don't invent mass delete+write).
|
|
402
|
+
- Media in markup: /__media/uploads/<slug>/… from frontpage media (not raw blob URLs).
|
|
403
|
+
|
|
404
|
+
Full guide: https://frontpage.host/developers/site-building
|
|
405
|
+
See also: frontpage help sync | content | AGENTS.md`,
|
|
356
406
|
agent: `Agent + publish
|
|
357
407
|
frontpage prompt "make the hero shorter"
|
|
358
408
|
frontpage runs # latest + active
|
|
@@ -381,8 +431,12 @@ export const TOPICS = {
|
|
|
381
431
|
frontpage settings get|set
|
|
382
432
|
frontpage edit --path / --old "…" --new "…"
|
|
383
433
|
|
|
434
|
+
Real forms (file sync): <form data-fp-form="slug"> + named inputs — no action/onsubmit/honeypot.
|
|
435
|
+
Do not fake payments/checkout. LOCKED extensions → do not fake; say plan required.
|
|
436
|
+
Migrate pages → articles: prefer frontpage prompt "migrate …" over mass delete+write.
|
|
384
437
|
edit uses click-edit (exact single occurrence), not push / gated-write.
|
|
385
438
|
Module OAuth and secret values are not exposed via the CLI.
|
|
439
|
+
Site contract: frontpage help site-building · https://frontpage.host/developers/site-building
|
|
386
440
|
Domains, billing, members, and site delete are out of v1.`,
|
|
387
441
|
history: `History
|
|
388
442
|
frontpage history [--limit 20] [--page 1]
|
package/llms.txt
CHANGED
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
- Package: frontpage-host (npm). Binary: frontpage. Do NOT install npm package "frontpage".
|
|
4
4
|
- Docs in this package: README.md, AGENTS.md (agent operating manual).
|
|
5
5
|
- Introspect: frontpage help | frontpage help --json | frontpage help <topic|command>
|
|
6
|
-
- Topics: quickstart, auth, sync, agent, content, history, isolation, exit-codes
|
|
6
|
+
- Topics: quickstart, auth, sync, site-building, agent, content, history, isolation, exit-codes
|
|
7
|
+
- Site building: frontpage help site-building — Astro pages map, BaseLayout, tokens, no backends/fake forms
|
|
7
8
|
- Auth: mint fp_live_ key in Frontpage UI (Developers); frontpage login KEY or FRONTPAGE_API_KEY
|
|
8
9
|
- Site id: subdomain only (frontpage use <subdomain>). Not custom domains.
|
|
9
10
|
- Staging: https://<subdomain>.frontpage.host — push/prompt/edit update staging; no separate staging deploy step for agents
|