From cc89255bf25576154527314b9e9407323a179273 Mon Sep 17 00:00:00 2001 From: KaiPUecker Date: Thu, 16 May 2024 09:13:07 +0200 Subject: [PATCH] feature/modal-playground: put playground in a modal dialog (#39) --- src/app.css | 13 ++++- src/lib/components/show-code.svelte | 75 +++++++++++++++++++++++------ src/routes/+page.svelte | 16 +++--- 3 files changed, 81 insertions(+), 23 deletions(-) diff --git a/src/app.css b/src/app.css index 319bb7c..6f7c1dd 100644 --- a/src/app.css +++ b/src/app.css @@ -17,12 +17,21 @@ font-style: normal; } + +:root { + --font-family-base: 'Camingo', Arial, Helvetica, sans-serif; + --font-family-title: 'Oswald', Arial, Helvetica, sans-serif; + --ally-rule-lineheight: 32px; + --color-primary-hsl: 0deg 100% 47.5%; + --color-primary: hsl(var(--color-primary-hsl)); +} + * { - font-family: 'Camingo', arial, helvetica, sans-serif; + font-family: var(--font-family-base); } a, button.link { - color: red; + color: var(--color-primary); text-decoration: underline; cursor: pointer; } diff --git a/src/lib/components/show-code.svelte b/src/lib/components/show-code.svelte index 153c5ba..62ae0d0 100644 --- a/src/lib/components/show-code.svelte +++ b/src/lib/components/show-code.svelte @@ -1,24 +1,71 @@ - -{#if showPlayground} - - - - - -{/if} + + +

A11y-Code Example{title ? ': ' + title : ''}

+ + + + + +
\ No newline at end of file diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte index b01f13d..c1e1f7a 100644 --- a/src/routes/+page.svelte +++ b/src/routes/+page.svelte @@ -1,14 +1,16 @@ @@ -56,7 +58,7 @@ Markup - {@html dedent` + {@html dedent` @@ -69,7 +71,7 @@ - {@html dedent` + {@html dedent` Ich bin ein Link
`}