@xtrable-ltd/nanoesis 0.1.4 → 0.1.5
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/dist/editor-api.d.ts +19 -7
- package/dist/editor-api.js +8 -42
- package/editor/assets/{TemplatesPane-Cjwu8SOY.js → TemplatesPane-CEKbBX1Y.js} +172 -172
- package/editor/assets/{cssMode-CIqtqlOX.js → cssMode-q1Nw_pOI.js} +1 -1
- package/editor/assets/{freemarker2-03aLbgAQ.js → freemarker2-D4uWo9kP.js} +1 -1
- package/editor/assets/{handlebars-CsCT0Kz-.js → handlebars-DIXKS_PM.js} +1 -1
- package/editor/assets/{html-BMDaxhoV.js → html-WMfbPtFq.js} +1 -1
- package/editor/assets/{htmlMode-BmX-GJzB.js → htmlMode-D1MWdaop.js} +1 -1
- package/editor/assets/{index-DSooOnUR.css → index-BRPY7tEn.css} +1 -1
- package/editor/assets/{index-xCwd0bS3.js → index-erqFXslE.js} +63 -68
- package/editor/assets/{javascript-y8MJYJ58.js → javascript-C0daj-se.js} +1 -1
- package/editor/assets/{jsonMode-DPpxOVap.js → jsonMode-F4j8hmn2.js} +1 -1
- package/editor/assets/{liquid-CGoDffSW.js → liquid-BmXUpyt6.js} +1 -1
- package/editor/assets/{mdx-CMvr2LP2.js → mdx-wzY123NO.js} +1 -1
- package/editor/assets/{python-Dg93CFNM.js → python-WOKQ0Svl.js} +1 -1
- package/editor/assets/{razor-D8HipAex.js → razor-B9Yg1Ydt.js} +1 -1
- package/editor/assets/{tsMode-Drl3yYU0.js → tsMode-966q_lbW.js} +1 -1
- package/editor/assets/{typescript-Dcqumk7N.js → typescript-dxbYO44F.js} +1 -1
- package/editor/assets/{xml-zoMMlERG.js → xml-BHa7-pyl.js} +1 -1
- package/editor/assets/{yaml-BMaJnJHN.js → yaml-CcgAVYu7.js} +1 -1
- package/editor/index.html +2 -2
- package/package.json +1 -1
package/dist/editor-api.d.ts
CHANGED
|
@@ -216,16 +216,28 @@ declare function readMcpResource(uri: string): {
|
|
|
216
216
|
* §11d) and bundled here as **pure data**, so the engine's purity is untouched and the
|
|
217
217
|
* scaffold works identically for every host and the MCP server with no per-host wiring.
|
|
218
218
|
*
|
|
219
|
-
*
|
|
220
|
-
*
|
|
221
|
-
*
|
|
222
|
-
*
|
|
223
|
-
*
|
|
219
|
+
* Auto-fires on first sign-in to an empty store (revised 2026-05-28). The earlier behaviour
|
|
220
|
+
* — a confirm prompt that the user could dismiss — left a user who said no with no path
|
|
221
|
+
* forward (the empty Content workspace has no signposted route to the Dev workspace, and
|
|
222
|
+
* every alternative to scaffolding needs templates to already exist). Removing the choice
|
|
223
|
+
* removes a concept; the scaffold is idempotent and gate-clean, so doing it always is safe.
|
|
224
|
+
*
|
|
225
|
+
* Deliberately minimal (revised 2026-05-28, owner's call):
|
|
226
|
+
* - `templates/home.html` is a **full HTML document** (DESIGN §6.10: with no
|
|
227
|
+
* `templates/document.html`, a page template is the whole document) — no shared shell.
|
|
228
|
+
* The user can extract one later when they add a second page; for the bootstrap state,
|
|
229
|
+
* three files is simpler than four.
|
|
230
|
+
* - `public/styles.css` for baseline readability — a one-page site without any CSS reads
|
|
231
|
+
* poorly, and the styles.css path is the editor's canonical "your site's CSS" location.
|
|
232
|
+
* - `content/index.json` with `isPublished: true` (revised 2026-05-28). The earlier
|
|
233
|
+
* "draft, so going live is deliberate" framing turned out to be a footgun: a new user
|
|
234
|
+
* would hit Publish and get the "nothing went live" warning without obvious cause. A
|
|
235
|
+
* published placeholder is honest about what a publish will do; the user's first edit
|
|
236
|
+
* is to replace the placeholder copy, not to also remember to toggle a flag.
|
|
224
237
|
*/
|
|
225
238
|
/**
|
|
226
239
|
* The starter files, keyed by working-store path. Written through the store's `write`
|
|
227
|
-
* (so the index records each)
|
|
228
|
-
* that depends on them, though the store has no cross-file ordering requirement.
|
|
240
|
+
* (so the index records each). The store has no cross-file ordering requirement.
|
|
229
241
|
*/
|
|
230
242
|
declare const SCAFFOLD_FILES: Readonly<Record<string, string>>;
|
|
231
243
|
|
package/dist/editor-api.js
CHANGED
|
@@ -11,42 +11,29 @@ import {
|
|
|
11
11
|
} from "./chunk-S23S4ZAK.js";
|
|
12
12
|
|
|
13
13
|
// ../editor-api/src/scaffold.ts
|
|
14
|
-
var
|
|
14
|
+
var HOME_HTML = `<!doctype html>
|
|
15
15
|
<html lang="en">
|
|
16
16
|
<head>
|
|
17
17
|
<meta charset="utf-8" />
|
|
18
18
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
19
19
|
<title>{title}</title>
|
|
20
|
-
<meta name="description" content="{meta_description}" />
|
|
21
20
|
<link rel="stylesheet" href="/styles.css" />
|
|
22
21
|
</head>
|
|
23
22
|
<body>
|
|
24
|
-
<header class="site-header">
|
|
25
|
-
<a class="brand" href="/">Your site</a>
|
|
26
|
-
</header>
|
|
27
23
|
<main>
|
|
28
|
-
<
|
|
24
|
+
<h1>{title}</h1>
|
|
25
|
+
<div class="prose" data-type="richtext">{body}</div>
|
|
29
26
|
</main>
|
|
30
|
-
<footer class="site-footer">
|
|
31
|
-
<p>Built with nanoesis \u2014 static HTML, no runtime.</p>
|
|
32
|
-
</footer>
|
|
33
27
|
</body>
|
|
34
28
|
</html>
|
|
35
29
|
`;
|
|
36
|
-
var HOME_HTML = `<section class="hero">
|
|
37
|
-
<h1>{title}</h1>
|
|
38
|
-
<p class="lead">{lead}</p>
|
|
39
|
-
</section>
|
|
40
|
-
<div class="prose" data-type="richtext">{body}</div>
|
|
41
|
-
`;
|
|
42
30
|
var HOME_JSON = `${JSON.stringify(
|
|
43
31
|
{
|
|
44
32
|
template: "home",
|
|
45
33
|
title: "Welcome",
|
|
46
|
-
isPublished:
|
|
34
|
+
isPublished: true,
|
|
47
35
|
fields: {
|
|
48
|
-
|
|
49
|
-
body: "<p>This is your new site. It compiles to plain static HTML \u2014 there is no server and no client framework, and nothing of the editor survives into production.</p>"
|
|
36
|
+
body: "<p>This is your starter home page. Edit it in the nanoesis editor and click Publish to update your site.</p>"
|
|
50
37
|
}
|
|
51
38
|
},
|
|
52
39
|
null,
|
|
@@ -67,30 +54,16 @@ body {
|
|
|
67
54
|
margin: 0;
|
|
68
55
|
}
|
|
69
56
|
|
|
70
|
-
|
|
71
|
-
main,
|
|
72
|
-
.site-footer {
|
|
57
|
+
main {
|
|
73
58
|
max-width: var(--max);
|
|
74
59
|
margin-inline: auto;
|
|
75
60
|
padding: 1.5rem 1.25rem;
|
|
76
61
|
}
|
|
77
62
|
|
|
78
|
-
|
|
79
|
-
font-weight: 700;
|
|
80
|
-
text-decoration: none;
|
|
81
|
-
color: var(--ink);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
.hero h1 {
|
|
63
|
+
h1 {
|
|
85
64
|
font-size: 2.25rem;
|
|
86
65
|
letter-spacing: -0.01em;
|
|
87
|
-
margin: 0 0
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
.lead {
|
|
91
|
-
font-size: 1.2rem;
|
|
92
|
-
color: var(--muted);
|
|
93
|
-
margin: 0 0 2rem;
|
|
66
|
+
margin: 0 0 1rem;
|
|
94
67
|
}
|
|
95
68
|
|
|
96
69
|
.prose {
|
|
@@ -100,15 +73,8 @@ main,
|
|
|
100
73
|
a {
|
|
101
74
|
color: var(--accent);
|
|
102
75
|
}
|
|
103
|
-
|
|
104
|
-
.site-footer {
|
|
105
|
-
color: var(--muted);
|
|
106
|
-
font-size: 0.9rem;
|
|
107
|
-
border-top: 1px solid #eee;
|
|
108
|
-
}
|
|
109
76
|
`;
|
|
110
77
|
var SCAFFOLD_FILES = {
|
|
111
|
-
"templates/document.html": DOCUMENT_HTML,
|
|
112
78
|
"templates/home.html": HOME_HTML,
|
|
113
79
|
"public/styles.css": STYLES_CSS,
|
|
114
80
|
"content/index.json": HOME_JSON
|