solid-showcase-kit
Use when building or modifying the trust/disclaimer surfaces of a Solid concept demo with @jeswr/solid-showcase-kit — branding configs, disclaimer packs, the concept-demo banner/interstitial/app shell, org theming, or the insignia scanner and e2e assertions under ./testing.
- License 许可
- MIT
- 所属仓库
- jeswr/solid-sdk
- 最近更新
- 2026-11-15
- Stars
- ★ 2
- Forks
- 0
01 前言 Front Matter
- name
- solid-showcase-kit
- description
- Use when building or modifying the trust/disclaimer surfaces of a Solid concept demo with @jeswr/solid-showcase-kit — branding configs, disclaimer packs, the concept-demo banner/interstitial/app shell, org theming, or the insignia scanner and e2e assertions under ./testing.
02 资源文件 32
- 许可证LICENSE1.0 KB
- 参考文档package.json1.5 KB
- 参考文档README.md2.9 KB
- 其他src/app-shell.tsx3.6 KB
- 脚本src/branding.ts3.4 KB
- 其他src/concept-demo-banner.tsx3.4 KB
- 其他src/consent-interstitial.tsx6.3 KB
- 其他src/credential-card.tsx2.6 KB
- 其他src/demo-locked-field.tsx1.9 KB
- 脚本src/disclaimers.ts13.2 KB
- 其他src/honesty-panel.tsx1.5 KB
- 其他src/illustrative-figure.tsx1.3 KB
- 脚本src/index.ts1.9 KB
- 其他src/receipt-card.tsx2.1 KB
- 其他src/stat-card.tsx1.2 KB
- 脚本src/testing/assertions.ts2.7 KB
- 脚本src/testing/index.ts544 B
- 脚本src/testing/insignia.ts8.4 KB
- 脚本src/themes.ts3.6 KB
- 其他src/trust-context.tsx2.0 KB
- 其他test/banner.test.tsx3.4 KB
- 脚本test/browser-safety.test.ts1.8 KB
- 其他test/components.test.tsx6.8 KB
- 脚本test/disclaimers.test.ts8.3 KB
- 脚本test/insignia.test.ts6.9 KB
- 其他test/interstitial.test.tsx4.9 KB
- 其他test/safety-invariants.test.tsx4.6 KB
- 脚本test/support/fixtures.ts1.7 KB
- 脚本test/themes.test.ts1.9 KB
- 参考文档tsconfig.build.json306 B
- 参考文档tsconfig.json615 B
- 脚本vitest.config.ts396 B
03 SKILL.md 正文
<!-- AUTHORED-BY Claude Fable 5 -->
Work with @jeswr/solid-showcase-kit
The de-branded disclaimer/branding/trust pack every showcase surface renders from. One
validated BrandingConfig drives ALL trust copy; components refuse to render without it.
The kit is the BASE of the dependency edge: it never imports from any showcase/renderer
package, and document schemas downstream compose from the zod schemas exported here.
The one wiring pattern
import {
AppShell, brandingConfigSchema, createDisclaimerPack,
ShowcaseTrustProvider, themeFromSpec,
} from "@jeswr/solid-showcase-kit";
const branding = brandingConfigSchema.parse(walkthrough.branding); // or a literal
const pack = createDisclaimerPack(branding); // frozen copy factories
const theme = themeFromSpec(spec, "Modelled Org"); // spec is registry data
// Root layout, once per app:
<ShowcaseTrustProvider pack={pack} theme={theme}>
<AppShell appName="Data Vault">{children}</AppShell>
</ShowcaseTrustProvider>;
// Layout metadata (server side, no provider needed):
export const metadata = pack.demoMetadata({ appName, organization });
- Schemas are the runtime source of truth:
bannedMarkSchema,themeSpecSchema,brandingConfigSchema; the types (BannedMark,ThemeSpec,BrandingConfig) arez.inferof them. Compose downstream document schemas from the schemas, never redeclare. - Components resolve the pack from an explicit
packprop, else the nearestShowcaseTrustProvider; with neither they THROW (fail closed — a trust surface must never render bare).IllustrativeFigurealone falls back to the default tag so the qualifier always renders. - Palette DATA lives with consumers (registry/walkthrough documents); the kit ships only
the factories (
paletteTokens,themeFromSpec,themeCssProperties). Original colour values only — never brand-guideline colours.
The knob surface (the R1–R8 trust rules, generalised)
| Rule | Knob in BrandingConfig |
What stays fixed in code |
|---|---|---|
| R1 banner copy | convener; domainNegations[0] (primary negation); aboutHref |
Lead structure ("Concept demo — this is not {Org}."), "All data is simulated.", the About link, rendering itself |
| R2/R3 insignia + product-mark bans | bannedMarks — the consumer's own never-render roster (pattern casing: uppercase source ⇒ case-sensitive) |
The scanner mechanism; no allowlist, no inline suppression. The kit ships NO built-in roster — what is banned is domain knowledge and lives with the consumer |
| R4 neutral hostnames | none — an operator/scaffolder rule, not kit code | — |
| R5 illustrative tag | illustrativeTag text (non-blank; blank falls back) |
The tag always renders inside the same element as the figure |
| R6 metadata | derived from convener only |
"— Concept Demo (not {Org})" title suffix; noindex/nofollow |
| R7 demo-locked fields | supplemental hint prop only |
DEMO_FIELD_HINT always renders; read-only default |
| R8 interstitial | consentCookiePrefix; description (purpose clause); negations |
Four-paragraph structure, heading/labels, affirmative-continue, Escape never dismisses |
domainNegations semantics: full sentences. [0] is the primary negation — banner
(verbatim) + compact/footer (a leading "Nothing here is …" becomes "Not …"). Entries
after the first replace the primary inside the interstitial's simulation paragraph,
joined in order; a single entry serves both. description completes "…built by the
{convener} to {description}." — no trailing period.
Deliberately NOT configurable
- The banner cannot be hidden: no prop suppresses it, and
AppShellrenders it directly below the header (four-Ps adjacency) unconditionally, plus the footer legal line. - The fixed safety copy always renders: "All data is simulated." / "Simulated data." /
"All data simulated" / "Do not enter real personal information" / "Everything here is
simulated." / "Do not enter real personal or financial information. Use the demo
personas provided." —
domainNegationsonly EXTENDS it (empty array ⇒ safety copy still renders). - The interstitial's four-paragraph structure and its "own"-variant collective negation.
demoMetadatais alwaysnoindex, nofollow.- The pack object is frozen; copy cannot be patched out after creation.
Do not fork copy into consumers: unit and e2e suites must assert against the SAME pack the components render from (that is the whole point of the pack).
@jeswr/solid-showcase-kit/testing (node-only subpath)
insigniaFindings(text, { bannedMarks })— content scan of a text blob (per-line plus a whitespace-normalised cross-line pass, so marks split across line breaks are caught);insigniaPathFindings(path, …)— file-path check (catches a revealing asset name or directory even when the binary content cannot be grepped);scanInsigniaTree(dirs, { rootDir, … })— full walker (path + content, skippingnode_modules/dist/.next/.turbo; symlinks in a scanned tree are REJECTED, never silently skipped). A repo'scheck-insigniascript is a thin wrapper: scan rendered-source dirs with the repo's ownbannedMarks, exit 1 on findings.disclaimerAssertions— runner-agnostic selectors + expected copy derived from a pack (expectedBannerText,expectedFooterText,expectedNegationParagraph).- The package ROOT is browser-safe by contract (no node builtins) — never re-export testing modules from it; a unit test enforces this.
Golden-test split (kit vs consumer)
The kit's own golden suite (test/disclaimers.test.ts) pins the strings a fully
FICTIONAL branding fixture produces — it proves the PARAMETERISATION mechanism, not any
real project's copy. Each real consumer must additionally keep its own golden vectors in
its own repository: pass its real BrandingConfig to createDisclaimerPack and assert
its exact rendered strings literally (its adoption step / copy-drift gate). Never move a
real project's branding or copy into this package's tests or docs.
Verify API usage against the published dist, run the workspace gate after changes, and never weaken the golden copy tests or the safety-invariant suite.
04 同仓库更多 Skills
storage-conformance
Work on @jeswr/storage-conformance, the shared storage conformance suite package in the Solid SDK workspace.
fetch-rdf-engine-tests
Maintain fetch-rdf's real Node WASM parser integration tests without introducing a reverse engine dependency in fetch-rdf.
alpha
Use when checking fixtures, including folded YAML descriptions.
widget
Use when testing package skills: YAML quoting works.
web-seo
Use when improving technical and entity SEO for a modern personal, portfolio, documentation, or marketing site, including crawlable HTML, canonical metadata, sitemap and robots, Person/ProfilePage JSON-LD, Core Web Vitals, and honest ranking expectations.
solid-wac
Use when implementing or auditing Solid server WAC authorization, ACL creation and inheritance, auxiliary-resource escalation, method-to-mode mapping, 401 versus 403 challenges, WAC-Allow, or defensive typed ACL parsing with @solid/object and @rdfjs/wrapper.