@awesomate/hosting-mcp 0.22.1 → 0.22.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@awesomate/hosting-mcp",
3
- "version": "0.22.1",
3
+ "version": "0.22.2",
4
4
  "description": "Awesomate MCP server — lets Claude manage your Awesomate WordPress hosting, plan, limits, n8n automations, and build Node/static apps + databases",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",
@@ -88,6 +88,9 @@ wrong account) · `references/connect-troubleshooting.md` (bootstrap, sandbox/
88
88
  proxy failures, resuming a connect, support report) ·
89
89
  `references/rest-fallback.md` (no `awesomate_*` tools — serve over REST) ·
90
90
  `references/voice.md` (how to talk to a non-technical owner).
91
+ `references/wordpress-launch-checks.md` (what to MEASURE in a real browser after any theme,
92
+ template or page deploy — boxed sections, missing logo/favicon, the post-domain re-key, http asset
93
+ URLs — every item a defect an owner reported before the agent noticed).
91
94
 
92
95
  ## After creating a site
93
96
 
@@ -310,6 +313,11 @@ scripts/deploy.sh --from ~/Studio/mysite --domain mysite.awesomate.site --with-d
310
313
  Never deploy without confirming with the user first, and always report the
311
314
  snapshot id and the verified live status.
312
315
 
316
+ **"Verified live status" means a real browser at 390px and 1440px, not a 200 from curl.**
317
+ Run the checklist in `references/wordpress-launch-checks.md` — full-bleed sections, gutters,
318
+ logo and favicon present, fonts loaded, no broken images, a real 404 — before saying done. Every
319
+ item on it was reported by a site owner after an agent had already said done.
320
+
313
321
  ## 5a. Staging on awesomate.dev (Support Plus+)
314
322
 
315
323
  The middle tier between "edit live" and "local Studio": a private full copy of
@@ -0,0 +1,108 @@
1
+ # WordPress launch checks — what to verify after deploying a theme or content
2
+
3
+ Every item here was a real defect that shipped to a live client site and was reported by the
4
+ owner, not caught by the agent. Each one looked fine in the generated code and was only visible
5
+ in a browser — so the rule is: **after any theme, template or page deploy, load the live site in a
6
+ real browser at 390px and 1440px and MEASURE, before telling the user it is done.**
7
+
8
+ ## 1. Sections boxed with white strips at the sides (the "margins are off" report)
9
+
10
+ **Symptom:** coloured section backgrounds stop short of the viewport edges, leaving white strips;
11
+ on a phone the text sits hard against the coloured band with no gutter. The home page often looks
12
+ fine while every inner page is wrong.
13
+
14
+ **Cause:** the inner-page template gives the **post-content block its own `layout`**:
15
+ `<!-- wp:post-content {"layout":{"type":"constrained"}} /-->`. That boxes every child group to
16
+ `contentSize` and strips its side padding. A front page written as `<!-- wp:post-content /-->`
17
+ (no layout) does not have the problem — which is why only some pages break.
18
+
19
+ **Fix:** post-content carries **no layout attribute** in templates whose content is built from
20
+ full-bleed section groups. Each section group is `{"layout":{"type":"constrained"}}` itself, so its
21
+ background runs edge to edge while its content is constrained. Keep a constrained post-content
22
+ only for deliberately narrow long-form templates (legal, single post), where every section is white
23
+ anyway.
24
+
25
+ **Measure it (Playwright, or DevTools console):**
26
+ ```js
27
+ const g = document.querySelector('main .wp-block-group.has-background');
28
+ const r = g.getBoundingClientRect();
29
+ const fullBleed = r.left <= 1 && r.width >= innerWidth - 1; // must be true
30
+ const inset = g.querySelector('h1,h2,p').getBoundingClientRect().left - r.left; // ≥16 on a phone
31
+ ```
32
+
33
+ Two related spacing faults usually travel with it:
34
+ - **Every `<section>` converted to a 96px-top-and-bottom group.** A page header flowing into its
35
+ content then stacks 192px of dead space. Padding must follow the design's section types (a full
36
+ section, a page header, a bare container), not one flat value.
37
+ - **WordPress's block gap opens a white line between two coloured bands.** Give section groups
38
+ `"margin":{"top":"0","bottom":"0"}`.
39
+ - **A fixed root gutter** (`styles.spacing.padding` = 40px) is far too wide on a phone. Use a
40
+ responsive value, e.g. `min(40px, 5vw)`.
41
+
42
+ ## 2. Logo missing, no favicon
43
+
44
+ **Symptom:** the header and footer show no logo at all; the browser tab has no icon.
45
+
46
+ **Cause:** `<!-- wp:site-logo /-->` renders **nothing** until a logo is set in Site Identity
47
+ (`custom_logo` theme mod), and no `<link rel="icon">` is emitted until `site_icon` is set. A fresh
48
+ install has neither, and the media library is empty. On these hosts **SVG uploads are disabled**
49
+ (`image/svg+xml` is not an allowed mime type), so the brand's SVGs cannot be uploaded as media.
50
+
51
+ **Fix, both halves:**
52
+ - Header/footer logos from the **theme's own files**, not media: make the header and footer
53
+ *patterns* (PHP) included from the parts —
54
+ `<!-- wp:pattern {"slug":"<theme>/header"} /-->` in `parts/header.html` — so the pattern can use
55
+ `get_theme_file_uri('assets/logos/logo.svg')`. This also lets the footer use the on-dark variant
56
+ while the header uses the primary, which a single Site Identity logo cannot do.
57
+ - Still set Site Identity, because WordPress uses it elsewhere:
58
+ `wp media import logo.png --porcelain` → `wp theme mod set custom_logo <id>`;
59
+ `wp media import icon-512.png --porcelain` → `wp option update site_icon <id>`.
60
+ The site icon must be a **PNG, square, ≥512px** — make one from the brand emblem with
61
+ transparent padding rather than uploading a rectangular PNG.
62
+
63
+ **Verify:** the live HTML contains an `<img alt="…">` in the header and `<link rel="icon"`, and both
64
+ URLs return 200 with an image content type.
65
+
66
+ ## 3. The hub re-keys a site when a custom domain becomes its primary
67
+
68
+ After a custom domain is attached and made primary, `GET /api/client-hosting/sites` reports the
69
+ site under **the new domain** (`domain: example.com`), and per-site endpoints keyed by the old
70
+ `siteN.<slug>.awesomate.site` name return **404** — including the snapshot call, which will abort a
71
+ snapshot-first deploy that worked yesterday. Read `/sites` and use the `domain` it reports.
72
+
73
+ ## 4. Content seeded over WP-CLI stores `http://` asset URLs
74
+
75
+ Pages created with `wp eval-file` / `wp post create` while the install is still on its
76
+ `*.awesomate.site` address store theme asset URLs as `http://<install host>/...`. A later
77
+ `wp search-replace https://<install host> https://example.com` misses every one of them because of
78
+ the scheme. Replace on the **bare host**: `wp search-replace <install-host> example.com --all-tables
79
+ --precise`, then recount with `LIKE '%<install-host>%'`.
80
+
81
+ ## 5. New pattern files render as nothing until the theme Version changes
82
+
83
+ **Symptom:** you add `patterns/header.php` (or any new pattern) to a live theme, deploy it, and
84
+ `<!-- wp:pattern {"slug":"theme/header"} /-->` renders an empty string — no error, no logo, nothing.
85
+ Patterns that already existed keep working, which makes the new one look broken rather than
86
+ unregistered.
87
+
88
+ **Cause:** WordPress caches the theme's `patterns/` directory listing in a transient keyed by the
89
+ theme's `Version:` header (`style.css`). A new file is not seen until that key changes.
90
+
91
+ **Fix:** bump `Version:` in `style.css` on every deploy that adds, removes or renames a pattern
92
+ file. Verified: the same deploy with `0.1.0 → 0.2.0` registered the patterns instantly. Treat the
93
+ version bump as part of the deploy, not a release ceremony.
94
+
95
+ ## The launch checklist
96
+
97
+ Run in a real browser against the LIVE domain, at 390 and 1440, before reporting done:
98
+
99
+ 1. Every coloured section is full-bleed (`getBoundingClientRect().left <= 1`) with text inset ≥16px.
100
+ 2. No horizontal overflow (`documentElement.scrollWidth <= clientWidth + 1`).
101
+ 3. Header shows the logo; `<link rel="icon">` is present; both URLs return 200.
102
+ 4. `document.fonts` reports the brand faces `loaded` (self-hosted fonts actually shipped).
103
+ 5. Zero broken images (`img.complete && naturalWidth > 0`), and zero assets still on the install host.
104
+ 6. A nonsense URL returns **404** with the theme's 404 template, not a 200 page.
105
+ 7. Section order matches the design (read the `h1,h2` sequence), and neither nav nor decorative
106
+ marks appear inside page content.
107
+ 8. If the deploy added pattern files, the theme `Version:` was bumped and every `wp:pattern`
108
+ in the parts actually rendered (an unregistered slug renders as empty, silently).