feat(skills): epic-002 — deploy-time authoring skills (design-adoption + legal-extraction)#46
Merged
Merged
Conversation
First slice of epic-002 (authoring-skills). A deploy-time Claude-Code skill scans a shop URL, extracts its corporate identity, and feeds the deterministic `revoco:make-theme` command, which renders a validated `--wf-*` / data-theme brand overlay plus a placement report. - ThemeOverlayGenerator validates values against the withdrawal.css token contract, guards against CSS injection, and never overrides the a11y-locked focus-ring token. - MakeThemeCommand is a thin, parameter-driven wrapper (TTY prompt for --slug, clean --no-interaction failure); output goes to --output or stdout, never into this repo. - 10 Pest cases cover the overlay, contract, a11y guard, report and validation. Brand overlays remain operator-placed and are never committed here (theming.md split).
Add a "Branding the form" section covering the neutral-first theming model, the deploy-time `design-adoption` Claude-Code skill, and the underlying `revoco:make-theme` command (with an example invocation). Reiterates that brand overlays are operator-reviewed, operator-placed, and never committed here.
feat(skills): design-adoption — brand overlay generator + skill (slice-018)
Second slice of epic-002 (authoring-skills). A deploy-time Claude-Code skill scrapes the operator's existing Impressum and privacy-policy pages and feeds the deterministic `revoco:import-legal` command, which validates, sanitizes and persists the content into the Phase-10 LegalSettings for review in Filament. - LegalContentImporter validates the JSON payload against the LegalSettings schema (unknown key / bad e-mail abort — nothing written), scopes per-locale fields by --locale, leaves fallback_order and the *_link overrides untouched, and refuses to overwrite populated fields without --overwrite. - Rich text (privacy, addendum) is sanitized with Str::sanitizeHtml — the same tool the render path uses; plain-text fields are tag-stripped. - ImportLegalCommand is a thin, parameter-driven wrapper (--locale/--input/--overwrite, clean --no-interaction failure) with a mandatory controller-review reminder. - 11 Pest cases cover per-locale scoping, sanitisation, the overwrite guard and validation.
Add a "Legal pages (Impressum & privacy)" section covering the operator-editable legal settings and the deploy-time `legal-extraction` skill with its underlying `revoco:import-legal` command (validation, sanitisation, overwrite guard, operator review in Filament).
Replace the Lindinger-derived CI values in the design-adoption README example with neutral placeholders (indigo/slate/Inter), and drop the prototype brand names from design/theming.md. Keeps the public repo free of any brand-specific content — the Lindinger data was only ever a throwaway skill test (gitignored scratch + dev DB).
feat(skills): legal-extraction — Impressum/Datenschutz importer + skill (slice-019)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Epic 002 — Authoring Skills (AI). Two deploy-time Claude-Code skills that let a non-programmer operator (or their agency) reach Revoco's best use without writing code. Each pairs a deterministic, Pest-tested artisan command (the correctness-critical core) with an AI skill wrapper (the non-deterministic scrape/extraction, verified hands-on). Nothing ships in the running container — the skills run in a Claude-Code session at setup time, and all output is operator-reviewed, never auto-published.
Slices
slice-018 — design-adoption (PR #25)
.claude/skills/design-adoption/SKILL.md: prompts for the shop URL, scans the site, extracts its corporate identity (colours, typography, logo).revoco:make-theme(MakeThemeCommand+ThemeOverlayGenerator): generates a.wf-card[data-theme=\"<slug>\"]overlay against the existing--wf-*token contract + a placement report (APP_THEME=<slug>, logo wiring).--wf-*tokens (no invented ones), preserves the a11y invariants (never overrides focus-ring / reduced-motion), writes to an operator path or stdout — never into this repo's committed theme (rules.md Tabu: no brand assets in the public repo).slice-019 — legal-extraction (PR #26, depends on 018)
.claude/skills/legal-extraction/SKILL.md: prompts for the Impressum + privacy URLs and their locale, scrapes and extracts them into a structured JSON payload.revoco:import-legal(ImportLegalCommand+LegalContentImporter): validates the payload against the Phase-10LegalSettingsschema (known keys only), sanitizes incoming HTML (Str::sanitizeHtml, allow-list — stored-XSS defense), and persists § 5 DDG imprint fields (global) + per-localeprivacy_content/imprint_address/imprint_addendum.--overwriterequired to replace populated legal text (never silently clobbers reviewed content); leavesfallback_order+*_linkoverrides untouched; prints a mandatory controller-review reminder. FilamentManageLegalis the review gate.Key decisions
design/authoring-skills.md(Phase-9 follow-up).--wf-*/APP_THEMEoverlay mechanism; legal fills the existingspatie/laravel-settingsstore. No new stores, no runtime coupling.--no-interactionfailure.Verification
MakeThemeCommandTest,ImportLegalCommandTestcover the command seams end-to-end (valid overlay / contract-only tokens / a11y preserved / report contents; per-locale writes / HTML sanitized / unknown-key rejected-writes-nothing / overwrite guard both ways / clean --no-interaction fail).Str::sanitizeHtmlkept structure, Impressum rendered structured. Extraction quality on flat CMS markup is best-effort by design (that's why the Filament review gate exists).main(0.7.0 / PHP 8.5 / dependabot bumps) — conflict-free; CI runs on the merged state.Scope
12 files, +1375/−1. New skills + two artisan commands + services + tests + README docs; one line in
design/theming.md. No consumer-runtime change, no changes to the 0.6.0/0.7.0 surfaces.Post-merge follow-ups (not in this PR)
design/authoring-skills.md, run the decisions promotion dialog.APP_THEMEneeds a container--force-recreate, not just an.envedit →design/deployment.md.