diff --git a/configurator/playwright.config.js b/configurator/playwright.config.js index f5303d4c..82cebe12 100644 --- a/configurator/playwright.config.js +++ b/configurator/playwright.config.js @@ -31,9 +31,10 @@ export default defineConfig({ viewport: { width: 1600, height: 1000 }, }, projects: [ - { name: 'chromium', use: { browserName: 'chromium' } }, + { name: 'chromium', use: { browserName: 'chromium' }, testIgnore: '**/screenshots.spec.js' }, { name: 'firefox', use: { browserName: 'firefox' }, testMatch: CROSS_ENGINE }, { name: 'webkit', use: { browserName: 'webkit' }, testMatch: CROSS_ENGINE }, + { name: 'screenshots', use: { browserName: 'chromium' }, testMatch: '**/screenshots.spec.js' }, ], webServer: { command: 'npm run preview -- --port 4173 --strictPort', diff --git a/configurator/src/components/ControlPreview.svelte b/configurator/src/components/ControlPreview.svelte index fdcdf56a..70cafc91 100644 --- a/configurator/src/components/ControlPreview.svelte +++ b/configurator/src/components/ControlPreview.svelte @@ -4,6 +4,13 @@ let { token, value = '', type = 'text', label = '' } = $props(); const active = $derived(value || overrides[token?.name] || token?.value || ''); const stageStyle = $derived(buildPreviewDeclarations(overrides, ui.previewTheme)); + const LABELS = { + color: 'colour', font: 'typeface', radius: 'corner', shadow: 'elevation', + motion: 'timing', 'line-height': 'leading', wrap: 'text wrap', + opacity: 'opacity', gradient: 'gradient', border: 'border style', + media: 'object fit', scale: 'scale', spacing: 'size', + }; + const caption = $derived(LABELS[type] ?? type);
@@ -37,6 +44,7 @@
{/if}
+

{caption}

diff --git a/configurator/src/components/ControlSection.svelte b/configurator/src/components/ControlSection.svelte index c3f18a19..7f778996 100644 --- a/configurator/src/components/ControlSection.svelte +++ b/configurator/src/components/ControlSection.svelte @@ -1,8 +1,9 @@ -
+
(open = e.currentTarget.open)}> {title} diff --git a/configurator/src/components/FriendlyControl.svelte b/configurator/src/components/FriendlyControl.svelte index 7d585877..20d90c93 100644 --- a/configurator/src/components/FriendlyControl.svelte +++ b/configurator/src/components/FriendlyControl.svelte @@ -1,6 +1,7 @@