[ui] DomiUi: Rosea's buttons and town search on @domi/ui v1.0.4 (CPAL-1.0, vendored by its own tool into packages/domi-ui), the licence credit at the foot of every screen, the README's copy line and public-domain sources; before-and-after pictures by pnpm look:shots
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { Button, DOMI_ATTRIBUTION_TEXT, strike } from '@domi/ui';
|
||||
import { PRODUCT_NAME, type Gardener } from '@rosea/schema';
|
||||
import { tick } from 'svelte';
|
||||
import { en } from './copy/en.js';
|
||||
@@ -178,6 +179,7 @@
|
||||
<h1 bind:this={heading} tabindex="-1">{en.letter.title}</h1>
|
||||
<Letter {blocks} />
|
||||
<a href={GARDEN_HASH}>{en.letter.back}</a>
|
||||
{@render credit()}
|
||||
</main>
|
||||
{:else}
|
||||
<main class="shell">
|
||||
@@ -222,8 +224,11 @@
|
||||
{#if !kept}
|
||||
<p class="hint">{en.sunset.notKept}</p>
|
||||
{/if}
|
||||
<button type="button" class="quiet" onclick={() => (changing = true)}>{place ? en.sunset.change : en.sunset.choose}</button>
|
||||
<button type="button" class="quiet" bind:this={chairButton} onclick={() => (watching = true)}>{en.chair.move}</button>
|
||||
<Button variant="quiet" onclick={() => (changing = true)}>{place ? en.sunset.change : en.sunset.choose}</Button>
|
||||
<!-- @domi/ui's quiet button written as markup (INTEGRATE.md §3): focus comes back here after the sunset. -->
|
||||
<button type="button" class="domi-btn domi-btn--quiet" bind:this={chairButton} use:strike onclick={() => (watching = true)}>
|
||||
<span class="domi-btn__label">{en.chair.move}</span>
|
||||
</button>
|
||||
</div>
|
||||
{#if watching}
|
||||
<ChairSunset {place} guessed={choice?.kind === 'device-zone'} now={sunset.now} onclose={stopWatching} />
|
||||
@@ -233,13 +238,23 @@
|
||||
{#if blocks.length > 0}
|
||||
<a href={LETTER_HASH}>{en.letter.title}</a>
|
||||
{/if}
|
||||
{@render credit()}
|
||||
</main>
|
||||
{/if}
|
||||
|
||||
<!--
|
||||
The licence's credit (CPAL-1.0 Exhibit B, for Rosea and for @domi/ui): its exact words, at the foot of every screen
|
||||
from the first open on (domi-ui.md D9). Plain text, not @domi/ui's DomiCredit link: the garden is offline, and a
|
||||
tap must never carry the player out of it, least of all on Android, which has no internet at all.
|
||||
-->
|
||||
{#snippet credit()}
|
||||
<p class="credit">{DOMI_ATTRIBUTION_TEXT}</p>
|
||||
{/snippet}
|
||||
|
||||
{#if updateReady && onrefresh}
|
||||
<aside class="update" aria-label={en.update.ready}>
|
||||
<p role="status">{en.update.ready}</p>
|
||||
<button type="button" onclick={onrefresh}>{en.update.refresh}</button>
|
||||
<Button onclick={onrefresh}>{en.update.refresh}</Button>
|
||||
</aside>
|
||||
{/if}
|
||||
|
||||
@@ -296,14 +311,11 @@
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.quiet {
|
||||
font: inherit;
|
||||
background: none;
|
||||
border: none;
|
||||
padding: var(--space-1) 0;
|
||||
color: var(--rose);
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
.credit {
|
||||
margin: var(--space-4) 0 0;
|
||||
font-size: 0.8rem;
|
||||
color: var(--ink-soft);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.update {
|
||||
@@ -323,20 +335,4 @@
|
||||
margin: 0;
|
||||
color: var(--ink-soft);
|
||||
}
|
||||
|
||||
.update button {
|
||||
font: inherit;
|
||||
padding: var(--space-1) var(--space-3);
|
||||
border-radius: 999px;
|
||||
border: 1px solid var(--rose);
|
||||
background: var(--paper);
|
||||
color: var(--ink);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.update button:focus-visible,
|
||||
.quiet:focus-visible {
|
||||
outline: 2px solid var(--rose);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -101,6 +101,8 @@ export const en = {
|
||||
question: 'Where do you want your sunset?',
|
||||
why: 'The garden follows the real sun. Choose a town near you. It is kept on this device only.',
|
||||
searchLabel: 'Town or city',
|
||||
/** The search field's seal, read aloud (@domi/ui TextField, action search). The list follows the typing. */
|
||||
searchAction: 'Search towns',
|
||||
/** Said aloud as the list changes. Never "not found": a small town is not a mistake. */
|
||||
found: (n: number): string => (n === 0 ? 'No town by that name here. A larger one nearby will do.' : n === 1 ? 'One town' : `${n} towns`),
|
||||
skip: (guess: string): string => `Not now. Use ${guess}`,
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { Button } from '@domi/ui';
|
||||
import { en } from '../copy/en.js';
|
||||
import type { RoseWiring } from './types.js';
|
||||
|
||||
@@ -76,17 +77,18 @@
|
||||
<p>{refused ? en.rose.safe.refused : persisted === true ? en.rose.safe.kept : persisted === false ? en.rose.safe.mayClear : en.rose.safe.unknown}</p>
|
||||
{/if}
|
||||
{#if !inApp && persisted === false && !refused}
|
||||
<button type="button" class="quiet" onclick={ask}>{en.rose.safe.ask}</button>
|
||||
<Button variant="quiet" onclick={() => void ask()}>{en.rose.safe.ask}</Button>
|
||||
{/if}
|
||||
{#if !inApp && wiring.installHint}
|
||||
<p>{en.rose.safe.install}</p>
|
||||
{/if}
|
||||
|
||||
<button type="button" onclick={save}>{en.rose.safe.save}</button>
|
||||
<Button onclick={() => void save()}>{en.rose.safe.save}</Button>
|
||||
<p class="note">{en.rose.safe.fileNote}</p>
|
||||
|
||||
<label class="file">
|
||||
<span>{en.rose.safe.bringBack}</span>
|
||||
<!-- A label, so the file picker stays the browser's own; it wears @domi/ui's plate. -->
|
||||
<label class="file domi-btn">
|
||||
<span class="domi-btn__label">{en.rose.safe.bringBack}</span>
|
||||
<input type="file" accept="application/json,.json" onchange={bringBack} />
|
||||
</label>
|
||||
<p class="said" role="status">{said}</p>
|
||||
@@ -122,24 +124,6 @@
|
||||
display: none;
|
||||
}
|
||||
|
||||
button,
|
||||
.file {
|
||||
font: inherit;
|
||||
padding: var(--space-2) var(--space-3);
|
||||
border-radius: 999px;
|
||||
border: 1px solid var(--rose);
|
||||
background: var(--paper);
|
||||
color: var(--ink);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.quiet {
|
||||
border: none;
|
||||
padding: var(--space-1) 0;
|
||||
color: var(--rose);
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
.file {
|
||||
position: relative;
|
||||
}
|
||||
@@ -152,9 +136,9 @@
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.file:focus-within,
|
||||
button:focus-visible {
|
||||
outline: 2px solid var(--rose);
|
||||
outline-offset: 2px;
|
||||
/* The plate's own focus ring, on the label that holds the real input. */
|
||||
.file:focus-within {
|
||||
outline: 2px solid var(--domi-accent);
|
||||
outline-offset: 3px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { Button } from '@domi/ui';
|
||||
import type { PetalNow } from '@rosea/engine';
|
||||
import type { HopeSentence } from '@rosea/schema';
|
||||
import { tick } from 'svelte';
|
||||
@@ -34,11 +35,11 @@
|
||||
{#if petal.kind === 'folded'}
|
||||
<div class="petal">
|
||||
<img src={folded} alt={en.rose.petal.folded} width="56" height="56" />
|
||||
<button type="button" onclick={open}>{en.rose.petal.open}</button>
|
||||
<Button onclick={() => void open()}>{en.rose.petal.open}</Button>
|
||||
</div>
|
||||
{:else if petal.kind === 'open' && today}
|
||||
<div class="petal">
|
||||
<button type="button" class="quiet" aria-expanded={showing} aria-controls="{uid}-words" onclick={() => (showing = !showing)}>{en.rose.petal.today}</button>
|
||||
<Button variant="quiet" aria-expanded={showing} aria-controls="{uid}-words" onclick={() => (showing = !showing)}>{en.rose.petal.today}</Button>
|
||||
{#if showing}
|
||||
<div id="{uid}-words" class="words" tabindex="-1" bind:this={words}>
|
||||
<figure>
|
||||
@@ -103,26 +104,4 @@
|
||||
color: var(--ink-soft);
|
||||
}
|
||||
|
||||
button {
|
||||
font: inherit;
|
||||
padding: var(--space-2) var(--space-3);
|
||||
border-radius: 999px;
|
||||
border: 1px solid var(--rose);
|
||||
background: var(--paper);
|
||||
color: var(--ink);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.quiet {
|
||||
border: none;
|
||||
background: none;
|
||||
padding: var(--space-1) 0;
|
||||
color: var(--rose);
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
button:focus-visible {
|
||||
outline: 2px solid var(--rose);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { Button, strike } from '@domi/ui';
|
||||
import {
|
||||
careEvent, goodMoment, lightAt, localDay, newCare, newOpened, petalAt, petalsToday, pour, roseAt, ROSE, sentenceOpened, touch, TOUCH,
|
||||
UNTOUCHED, weedsToday, type Mood, type PetalNow, type Place, type RoseNow, type Stage, type TouchState
|
||||
@@ -265,11 +266,14 @@
|
||||
if (e.key === 'Escape') void closeRing();
|
||||
}}
|
||||
>
|
||||
<!-- Water and Touch her are @domi/ui's plate written as markup (INTEGRATE.md §3): Button sets its own
|
||||
onkeydown and onblur after the ones passed to it, and the pour needs both (domi-ui.md D3). -->
|
||||
<button
|
||||
type="button"
|
||||
class="water"
|
||||
class="domi-btn water"
|
||||
class:pouring
|
||||
aria-describedby="rose-water-hint"
|
||||
use:strike
|
||||
onpointerdown={(e) => {
|
||||
e.preventDefault();
|
||||
(e.currentTarget as HTMLElement).setPointerCapture?.(e.pointerId);
|
||||
@@ -286,18 +290,20 @@
|
||||
if (isPourKey(e)) stopPour();
|
||||
}}
|
||||
onblur={stopPour}
|
||||
>{en.rose.water}</button>
|
||||
><span class="domi-btn__label">{en.rose.water}</span></button>
|
||||
{#if rose.needs.wind}
|
||||
<button type="button" onclick={() => careBy('shade')}>{en.rose.shade}</button>
|
||||
<Button onclick={() => careBy('shade')}>{en.rose.shade}</Button>
|
||||
{/if}
|
||||
{#if rose.needs.weeds}
|
||||
<button type="button" onclick={() => careBy('weed')}>{en.rose.weed}</button>
|
||||
<Button onclick={() => careBy('weed')}>{en.rose.weed}</Button>
|
||||
{/if}
|
||||
{#if rose.needs.petals}
|
||||
<button type="button" onclick={() => careBy('petals')}>{en.rose.petals}</button>
|
||||
<Button onclick={() => careBy('petals')}>{en.rose.petals}</Button>
|
||||
{/if}
|
||||
<button
|
||||
type="button"
|
||||
class="domi-btn"
|
||||
use:strike
|
||||
onclick={() => {
|
||||
planet?.act('touch');
|
||||
touchHer();
|
||||
@@ -306,8 +312,8 @@
|
||||
// A held key is one touch, not a rush (thorns.md T2).
|
||||
if (e.repeat) e.preventDefault();
|
||||
}}
|
||||
>{en.rose.touch.label}</button>
|
||||
<button type="button" class="quiet" onclick={() => void closeRing()}>{en.scene.close}</button>
|
||||
><span class="domi-btn__label">{en.rose.touch.label}</span></button>
|
||||
<Button variant="quiet" onclick={() => void closeRing()}>{en.scene.close}</Button>
|
||||
</div>
|
||||
<p id="rose-water-hint" class="hint">{en.rose.waterHint}</p>
|
||||
{/if}
|
||||
@@ -326,10 +332,10 @@
|
||||
{/if}
|
||||
|
||||
<div class="more">
|
||||
<button type="button" class="quiet" aria-expanded={showNumbers} aria-controls="rose-numbers" onclick={() => (showNumbers = !showNumbers)}>{en.rose.numbers}</button>
|
||||
<button type="button" class="quiet" aria-expanded={showSafe} onclick={() => (showSafe = !showSafe)}>{en.rose.safe.title}</button>
|
||||
<Button variant="quiet" aria-expanded={showNumbers} aria-controls="rose-numbers" onclick={() => (showNumbers = !showNumbers)}>{en.rose.numbers}</Button>
|
||||
<Button variant="quiet" aria-expanded={showSafe} onclick={() => (showSafe = !showSafe)}>{en.rose.safe.title}</Button>
|
||||
{#if onchangegardener}
|
||||
<button type="button" class="quiet" onclick={onchangegardener}>{en.gardener.change}</button>
|
||||
<Button variant="quiet" onclick={onchangegardener}>{en.gardener.change}</Button>
|
||||
{/if}
|
||||
</div>
|
||||
{#if showNumbers}
|
||||
@@ -368,20 +374,16 @@
|
||||
gap: var(--space-2);
|
||||
}
|
||||
|
||||
.care button {
|
||||
font: inherit;
|
||||
padding: var(--space-2) var(--space-3);
|
||||
border-radius: 999px;
|
||||
border: 1px solid var(--rose);
|
||||
background: var(--paper);
|
||||
color: var(--ink);
|
||||
cursor: pointer;
|
||||
/* Water is held, not clicked: the page must not scroll or select under the finger (rose.md). */
|
||||
.care .water {
|
||||
touch-action: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.care button.pouring {
|
||||
background: color-mix(in srgb, var(--rose) 18%, var(--paper));
|
||||
/* While she is being watered the plate stays pressed in (@domi/ui's own press, held). */
|
||||
.care .water.pouring {
|
||||
background: var(--domi-plate-press);
|
||||
box-shadow: var(--domi-plate-shadow-press);
|
||||
}
|
||||
|
||||
.hint,
|
||||
@@ -399,18 +401,12 @@
|
||||
width: 12rem;
|
||||
}
|
||||
|
||||
.quiet {
|
||||
font: inherit;
|
||||
background: none;
|
||||
border: none;
|
||||
color: var(--rose);
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
/* The shared buttons keep their words on one line, so the row wraps instead (a phone is 360 px wide). */
|
||||
.more {
|
||||
display: flex;
|
||||
gap: var(--space-3);
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
gap: var(--space-1) var(--space-3);
|
||||
}
|
||||
|
||||
.numbers {
|
||||
@@ -427,9 +423,4 @@
|
||||
dd {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
button:focus-visible {
|
||||
outline: 2px solid var(--rose);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { Button } from '@domi/ui';
|
||||
import { GARDENER_FIELDS, GARDENER_OPTIONS, type Gardener as Look } from '@rosea/schema';
|
||||
import { untrack } from 'svelte';
|
||||
import { en } from '../copy/en.js';
|
||||
@@ -53,8 +54,8 @@
|
||||
</fieldset>
|
||||
{/each}
|
||||
<div class="actions">
|
||||
<button type="submit" class="primary">{en.gardener.done}</button>
|
||||
{#if oncancel}<button type="button" class="quiet" onclick={oncancel}>{en.scene.close}</button>{/if}
|
||||
<Button type="submit" variant="primary">{en.gardener.done}</Button>
|
||||
{#if oncancel}<Button variant="quiet" onclick={oncancel}>{en.scene.close}</Button>{/if}
|
||||
</div>
|
||||
</form>
|
||||
</section>
|
||||
@@ -145,33 +146,9 @@
|
||||
|
||||
.actions {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
gap: var(--space-3);
|
||||
}
|
||||
|
||||
button {
|
||||
font: inherit;
|
||||
padding: var(--space-2) var(--space-4);
|
||||
border-radius: 999px;
|
||||
border: 1px solid var(--rose);
|
||||
background: var(--paper);
|
||||
color: var(--ink);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.primary {
|
||||
background: var(--rose);
|
||||
color: var(--paper);
|
||||
}
|
||||
|
||||
.quiet {
|
||||
border: none;
|
||||
text-decoration: underline;
|
||||
color: var(--rose);
|
||||
}
|
||||
|
||||
button:focus-visible {
|
||||
outline: 2px solid var(--rose);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { Button } from '@domi/ui';
|
||||
import type { NamedPlace } from '@rosea/engine';
|
||||
import { en } from '../copy/en.js';
|
||||
import SunsetLine from './SunsetLine.svelte';
|
||||
@@ -87,8 +88,8 @@
|
||||
<p>{en.sunset.noTown}</p>
|
||||
{/if}
|
||||
<div class="choices">
|
||||
<button type="button" onclick={(e) => { e.stopPropagation(); showing += 1; }}>{en.chair.again}</button>
|
||||
<button type="button" class="quiet" onclick={(e) => { e.stopPropagation(); leave(); }}>{en.chair.back}</button>
|
||||
<Button onclick={(e) => { e.stopPropagation(); showing += 1; }}>{en.chair.again}</Button>
|
||||
<Button variant="quiet" onclick={(e) => { e.stopPropagation(); leave(); }}>{en.chair.back}</Button>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
@@ -186,27 +187,25 @@
|
||||
|
||||
.choices {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
gap: var(--space-3);
|
||||
}
|
||||
|
||||
button {
|
||||
font: inherit;
|
||||
padding: var(--space-2) var(--space-3);
|
||||
border-radius: 999px;
|
||||
border: 1px solid #f4d58d;
|
||||
background: transparent;
|
||||
color: #fbf6f1;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.quiet {
|
||||
border: none;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
button:focus-visible {
|
||||
outline: 2px solid #f4d58d;
|
||||
outline-offset: 2px;
|
||||
/* @domi/ui's buttons on dusk, whatever the page's theme: the plate is the evening's own glass with the
|
||||
sunset's gold edge, as Rosea's button was (domi-ui.md D5). */
|
||||
.choices {
|
||||
--domi-fg: var(--ink);
|
||||
--domi-fg-2: var(--ink-soft);
|
||||
--domi-edge: #f4d58d;
|
||||
--domi-accent: #f4d58d;
|
||||
--domi-plate: linear-gradient(180deg, #ffffff1f, #ffffff0a);
|
||||
--domi-plate-hover: linear-gradient(180deg, #ffffff2e, #ffffff12);
|
||||
--domi-plate-press: linear-gradient(180deg, #00000033, #ffffff0a);
|
||||
--domi-plate-shadow: inset 0 1px 0 #ffffff33, 0 8px 18px -12px #000000cc;
|
||||
--domi-plate-shadow-hover: inset 0 1px 0 #ffffff47, 0 10px 22px -12px #000000e6;
|
||||
--domi-tint: #f4d58d24;
|
||||
--domi-tint-strong: #f4d58d38;
|
||||
}
|
||||
|
||||
.sr-only {
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { Button, TextField } from '@domi/ui';
|
||||
import type { NamedPlace } from '@rosea/engine';
|
||||
import { en } from '../copy/en.js';
|
||||
import type { SunsetChoice } from './types.js';
|
||||
@@ -28,7 +29,7 @@
|
||||
let query = $state('');
|
||||
// Raw: the towns are handed on as they came, never wrapped in a state Proxy.
|
||||
let results = $state.raw<readonly NamedPlace[]>([]);
|
||||
let input = $state<HTMLInputElement>();
|
||||
let input = $state<HTMLInputElement | HTMLTextAreaElement | null>(null);
|
||||
|
||||
// Only the latest query's answer is shown, however the searches finish.
|
||||
let asked = 0;
|
||||
@@ -61,15 +62,20 @@
|
||||
<h2 id="{uid}-q">{en.sunset.question}</h2>
|
||||
<p class="why">{en.sunset.why}</p>
|
||||
|
||||
<label for="{uid}-search">{en.sunset.searchLabel}</label>
|
||||
<input
|
||||
<!-- The list already follows the typing; the seal and Enter only confirm it, so they say nothing of their own
|
||||
(sentText) and the status line below speaks (domi-ui.md D4). Nothing is sent anywhere: "search", never "send". -->
|
||||
<TextField
|
||||
id="{uid}-search"
|
||||
type="search"
|
||||
label={en.sunset.searchLabel}
|
||||
action="search"
|
||||
actionLabel={en.sunset.searchAction}
|
||||
sentText=""
|
||||
autocomplete="off"
|
||||
spellcheck="false"
|
||||
enterkeyhint="search"
|
||||
spellcheck={false}
|
||||
onsend={() => {}}
|
||||
bind:value={query}
|
||||
bind:this={input}
|
||||
bind:input
|
||||
/>
|
||||
<p class="found" role="status" aria-live="polite">{query.trim() === '' ? '' : en.sunset.found(results.length)}</p>
|
||||
|
||||
@@ -77,10 +83,10 @@
|
||||
<ul>
|
||||
{#each results as town (`${town.name}|${town.lat}|${town.lon}`)}
|
||||
<li>
|
||||
<button type="button" onclick={() => onchoose({ kind: 'town', town })}>
|
||||
<Button block onclick={() => onchoose({ kind: 'town', town })}>
|
||||
<span class="name">{town.name}</span>
|
||||
<span class="where">{where(town)}</span>
|
||||
</button>
|
||||
</Button>
|
||||
</li>
|
||||
{/each}
|
||||
</ul>
|
||||
@@ -88,11 +94,11 @@
|
||||
|
||||
<div class="other">
|
||||
{#if current && oncancel}
|
||||
<button type="button" class="quiet" onclick={oncancel}>{en.sunset.keep(current.name)}</button>
|
||||
<Button variant="quiet" onclick={oncancel}>{en.sunset.keep(current.name)}</Button>
|
||||
{/if}
|
||||
<button type="button" class="quiet" onclick={() => onchoose({ kind: 'device-zone' })}>
|
||||
<Button variant="quiet" onclick={() => onchoose({ kind: 'device-zone' })}>
|
||||
{guess ? en.sunset.skip(guess.name) : en.sunset.skipNoGuess}
|
||||
</button>
|
||||
</Button>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
@@ -123,19 +129,6 @@
|
||||
display: none;
|
||||
}
|
||||
|
||||
label {
|
||||
font-size: 0.95rem;
|
||||
}
|
||||
|
||||
input {
|
||||
font: inherit;
|
||||
padding: var(--space-2);
|
||||
border: 1px solid var(--ink-soft);
|
||||
border-radius: 0.5rem;
|
||||
background: var(--paper);
|
||||
color: var(--ink);
|
||||
}
|
||||
|
||||
ul {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
@@ -144,22 +137,11 @@
|
||||
gap: var(--space-1);
|
||||
}
|
||||
|
||||
button {
|
||||
font: inherit;
|
||||
cursor: pointer;
|
||||
border-radius: 0.5rem;
|
||||
color: var(--ink);
|
||||
}
|
||||
|
||||
li button {
|
||||
/* A town row: its name at the start, its region at the end, on @domi/ui's plate. */
|
||||
li :global(.domi-btn__label) {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
gap: var(--space-2);
|
||||
padding: var(--space-2);
|
||||
text-align: start;
|
||||
background: var(--paper);
|
||||
border: 1px solid color-mix(in srgb, var(--ink-soft) 40%, transparent);
|
||||
}
|
||||
|
||||
.where {
|
||||
@@ -172,18 +154,4 @@
|
||||
flex-wrap: wrap;
|
||||
gap: var(--space-2);
|
||||
}
|
||||
|
||||
.quiet {
|
||||
background: none;
|
||||
border: none;
|
||||
padding: var(--space-1) 0;
|
||||
color: var(--rose);
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
button:focus-visible,
|
||||
input:focus-visible {
|
||||
outline: 2px solid var(--rose);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/* @domi/ui, vendored in packages/domi-ui (CPAL-1.0, see its NOTICE): its tokens, base and components, before Rosea's
|
||||
own. Not its fonts: Rosea keeps her system faces (below). */
|
||||
@import '@domi/ui/tokens.css';
|
||||
@import '@domi/ui/base.css';
|
||||
@import '@domi/ui/components.css';
|
||||
|
||||
/*
|
||||
* Design tokens. Placeholders until docs/ART.md sets the palette: they exist so
|
||||
* components reference tokens from the first commit, never raw colours.
|
||||
@@ -13,6 +19,10 @@
|
||||
|
||||
--font-body: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
|
||||
--font-display: Georgia, 'Times New Roman', serif;
|
||||
/* Rosea keeps her system faces inside the shared controls too (@domi/ui INTEGRATE.md §0.4; the font is Mark's
|
||||
open question in its PALETTE.md). */
|
||||
--domi-font-hand: var(--font-body);
|
||||
--domi-font-book: var(--font-display);
|
||||
|
||||
--space-1: 0.25rem;
|
||||
--space-2: 0.5rem;
|
||||
|
||||
Reference in New Issue
Block a user