@whatsaaaa/design-system 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/assets/manifest.json +12 -0
- package/assets/whatsaaaa/ghost-on-dark.svg +1 -0
- package/assets/whatsaaaa/ghost-on-light.svg +1 -0
- package/dist/css/base.css +14 -0
- package/dist/css/code.css +18 -0
- package/dist/css/ghost.css +27 -0
- package/dist/css/icons.css +1 -0
- package/dist/css/pairs.css +57 -0
- package/dist/css/segmented.css +71 -0
- package/dist/ghost/bubble.d.ts +2 -2
- package/dist/ghost/bubble.js +18 -10
- package/dist/ghost/index.d.ts +8 -2
- package/dist/ghost/index.js +50 -10
- package/dist/ghost/svg.d.ts +4 -0
- package/dist/ghost/svg.js +9 -0
- package/dist/index.css +211 -0
- package/dist/shiki/index.d.ts +19 -0
- package/dist/shiki/index.js +25 -0
- package/dist/tokens.css +42 -0
- package/dist/tokens.d.ts +7 -0
- package/dist/tokens.js +14 -0
- package/docs/usage.md +106 -32
- package/package.json +2 -1
- package/src/vitepress/styles/vars.css +2 -2
- package/tokens/contrast.json +18 -0
- package/tokens/core.tokens.json +53 -0
- package/tokens/theme-dark.tokens.json +16 -0
- package/tokens/theme-light.tokens.json +16 -0
package/docs/usage.md
CHANGED
|
@@ -18,18 +18,20 @@ One import has everything: fonts, tokens, page defaults and every class.
|
|
|
18
18
|
|
|
19
19
|
Or take pieces. `tokens.css` and `fonts.css` first, then what you use:
|
|
20
20
|
|
|
21
|
-
| Import
|
|
22
|
-
|
|
|
23
|
-
| `@whatsaaaa/design-system/tokens.css`
|
|
24
|
-
| `@whatsaaaa/design-system/fonts.css`
|
|
25
|
-
| `@whatsaaaa/design-system/css/base.css`
|
|
26
|
-
| `@whatsaaaa/design-system/css/prose.css`
|
|
27
|
-
| `@whatsaaaa/design-system/css/code.css`
|
|
28
|
-
| `@whatsaaaa/design-system/css/callout.css`
|
|
29
|
-
| `@whatsaaaa/design-system/css/
|
|
30
|
-
| `@whatsaaaa/design-system/css/
|
|
31
|
-
| `@whatsaaaa/design-system/css/
|
|
32
|
-
| `@whatsaaaa/design-system/css/
|
|
21
|
+
| Import | What it has |
|
|
22
|
+
| -------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
23
|
+
| `@whatsaaaa/design-system/tokens.css` | Every token as a CSS variable, for both themes |
|
|
24
|
+
| `@whatsaaaa/design-system/fonts.css` | JetBrains Mono and Inter, self-hosted, with Serbian Latin |
|
|
25
|
+
| `@whatsaaaa/design-system/css/base.css` | Page defaults. It resets margins and list markers |
|
|
26
|
+
| `@whatsaaaa/design-system/css/prose.css` | Long-form text, in a `.ws-prose` container |
|
|
27
|
+
| `@whatsaaaa/design-system/css/code.css` | `.ws-code`, a code block with a caption |
|
|
28
|
+
| `@whatsaaaa/design-system/css/callout.css` | `.ws-callout` |
|
|
29
|
+
| `@whatsaaaa/design-system/css/segmented.css` | `.ws-segmented`, buttons in a row with one pressed |
|
|
30
|
+
| `@whatsaaaa/design-system/css/pairs.css` | `.ws-pairs`, terms and their values, such as an order summary |
|
|
31
|
+
| `@whatsaaaa/design-system/css/terminal.css` | Tab bar, prompts, status line, key caps, tags. It brings `theme.css` along |
|
|
32
|
+
| `@whatsaaaa/design-system/css/theme.css` | `ws-theme-dark` and `ws-theme-light`, for an element of one theme only |
|
|
33
|
+
| `@whatsaaaa/design-system/css/ghost.css` | Styles of `<ws-ghost>` |
|
|
34
|
+
| `@whatsaaaa/design-system/css/icons.css` | The icons the callouts and prompts draw, and `--ws-icon-check`, the tick of a form. Needed with `callout.css` and `terminal.css`, and for the tick |
|
|
33
35
|
|
|
34
36
|
Everything is prefixed: classes with `ws-`, variables with `--ws-`.
|
|
35
37
|
|
|
@@ -37,20 +39,21 @@ Everything is prefixed: classes with `ws-`, variables with `--ws-`.
|
|
|
37
39
|
|
|
38
40
|
Use the role tokens. Never write a hex value, and never use a `--ws-palette-*` color for interface: a role changes with the theme and carries the contrast rules, the palette does not.
|
|
39
41
|
|
|
40
|
-
| For
|
|
41
|
-
|
|
|
42
|
-
| Page background
|
|
43
|
-
| Panels and cards
|
|
44
|
-
| Inline code, hover, current item
|
|
45
|
-
| Dividers
|
|
46
|
-
| Outlines of inputs and buttons
|
|
47
|
-
| Text
|
|
48
|
-
| Secondary text
|
|
49
|
-
| Disabled text, idle marks
|
|
50
|
-
| Brand accent
|
|
51
|
-
| Links, focus ring, primary button
|
|
52
|
-
|
|
|
53
|
-
|
|
|
42
|
+
| For | Token |
|
|
43
|
+
| ---------------------------------- | ---------------------------------------------------------------------------------------------------------------- |
|
|
44
|
+
| Page background | `--ws-color-bg` |
|
|
45
|
+
| Panels and cards | `--ws-color-surface` |
|
|
46
|
+
| Inline code, hover, current item | `--ws-color-raised` |
|
|
47
|
+
| Dividers | `--ws-color-border` |
|
|
48
|
+
| Outlines of inputs and buttons | `--ws-color-field-border` |
|
|
49
|
+
| Text | `--ws-color-text` |
|
|
50
|
+
| Secondary text | `--ws-color-text-secondary` |
|
|
51
|
+
| Disabled text, idle marks | `--ws-color-text-faint` |
|
|
52
|
+
| Brand accent | `--ws-color-brand` |
|
|
53
|
+
| Links, focus ring, primary button | `--ws-color-interactive`, with `--ws-color-on-interactive` for text on it |
|
|
54
|
+
| Primary button, hovered or pressed | `--ws-color-interactive-hover`, `--ws-color-interactive-active` |
|
|
55
|
+
| Tags | `--ws-color-tag-text` on `--ws-color-tag-bg` |
|
|
56
|
+
| Status | `--ws-color-tip`, `-note`, `-warning`, `-danger`: each with `-text` for its label and `-tint` for its background |
|
|
54
57
|
|
|
55
58
|
Rules:
|
|
56
59
|
|
|
@@ -123,13 +126,14 @@ Use a text style, not a size. A style is two lines:
|
|
|
123
126
|
}
|
|
124
127
|
```
|
|
125
128
|
|
|
126
|
-
Styles: `display`, `h1`, `h2`, `h3`, `h4`, `lead`, `body`, `body-sm`, `label`, `label-sm`, `caption`, `overline` (set it in uppercase) and `code`. Below 64rem use `display-compact`, `h1-compact` and `
|
|
129
|
+
Styles: `display`, `h1`, `h2`, `h3`, `h4`, `tagline` (the line under the display name), `lead`, `body`, `body-sm`, `label`, `label-sm`, `caption`, `overline` (set it in uppercase) and `code`. Below 64rem use `display-compact`, `h1-compact`, `h2-compact` and `tagline-compact`.
|
|
127
130
|
|
|
128
131
|
Do not load other fonts, and do not load these from a CDN. Set `font-variant-ligatures: none` on anything that shows code.
|
|
129
132
|
|
|
130
133
|
## 5. Space, radius, motion
|
|
131
134
|
|
|
132
135
|
- Space: `--ws-space-2` to `--ws-space-64`, named by px, set in rem. Use them for padding, margin and gap.
|
|
136
|
+
- Sizes: `--ws-size-control` (40 px) is the height of a one-line field, a button and a segmented control. `--ws-size-check` (20 px) is a checkbox or a radio button and `--ws-size-step` (24 px) the circle of a step number. Use them for those, not a space token.
|
|
133
137
|
- Radius: `--ws-radius-xs` (key caps), `-sm` (inline code, tags), `-md` (inputs, buttons), `-lg` (blocks, cards), `-xl` (the window), `-full` (dots).
|
|
134
138
|
- Borders, not shadows: `--ws-border-width-thin`, `-medium`, `-thick`.
|
|
135
139
|
- Motion: `--ws-motion-duration-fast`, `-base`, `-slow` with `--ws-motion-easing-standard`. Wrap movement in `@media (prefers-reduced-motion: no-preference)`.
|
|
@@ -138,10 +142,11 @@ Do not load other fonts, and do not load these from a CDN. Set `font-variant-lig
|
|
|
138
142
|
## 6. Classes
|
|
139
143
|
|
|
140
144
|
- Long-form text: put rendered Markdown in `<article class="ws-prose">`. Wrap a table in `<div class="ws-table">` so it scrolls inside itself, and give a cell of running text `class="ws-table__text"` so a narrow frame scrolls instead of squeezing it. A first cell stays on one line unless it has that class. The docs theme does both.
|
|
141
|
-
- Code block with a caption: `<figure class="ws-code"><figcaption><span>file.ts</span><span>ts</span></figcaption><pre><code>...</code></pre></figure>`. For highlighting, use Shiki with `codeTheme` from `@whatsaaaa/design-system/shiki`.
|
|
145
|
+
- Code block with a caption: `<figure class="ws-code"><figcaption><span>file.ts</span><span>ts</span></figcaption><pre><code>...</code></pre></figure>`. For highlighting, use Shiki with `codeTheme` from `@whatsaaaa/design-system/shiki`. See [code blocks](#code-blocks).
|
|
142
146
|
- Callout: `<aside class="ws-callout ws-callout--warning"><p class="ws-callout__title">Warning</p><p>...</p></aside>`. Modifiers: `--tip`, `--warning`, `--danger`. None is a note.
|
|
143
147
|
- Terminal frame: `ws-term` (the window), `ws-tab-bar` with `ws-tab-bar__brand`, `ws-tabs` and `ws-tab-bar__end`, `ws-prompt` for headings, `ws-output`, `ws-status-line`. Mark the current tab with `aria-current="page"`.
|
|
144
148
|
- Small pieces: `ws-kbd`, `ws-tag`, `ws-tag--outline`, `ws-state` with `--active` or `--experimental`, `ws-arrow`, `ws-cursor`, and `ws-visually-hidden` for text that only assistive technology reads.
|
|
149
|
+
- Forms: `ws-segmented` and `ws-pairs`. See [forms](#forms).
|
|
145
150
|
|
|
146
151
|
The markup of each piece is in the comment at the top of its stylesheet, and in the style guide.
|
|
147
152
|
|
|
@@ -168,6 +173,71 @@ The markup of each piece is in the comment at the top of its stylesheet, and in
|
|
|
168
173
|
- An item for wide screens only takes `ws-status-line__item--wide`, and one with a border on its left `ws-status-line__item--edge`.
|
|
169
174
|
- A focus ring in the window's bars is drawn inside its control, so neither the bars nor the window's corners cut it off. A control of your own in a bar does the same: `outline-offset: calc(-1 * var(--ws-border-width-medium))`.
|
|
170
175
|
|
|
176
|
+
### Forms
|
|
177
|
+
|
|
178
|
+
The system draws no fields and no buttons: draw them from the roles, with these.
|
|
179
|
+
|
|
180
|
+
- **One height.** A one-line field, a button and a segmented control are `--ws-size-control` tall. A checkbox or a radio button is `--ws-size-check`, a step number's circle `--ws-size-step`.
|
|
181
|
+
- **The primary button** is filled with `--ws-color-interactive`, its label `--ws-color-on-interactive`. Under the pointer it takes `--ws-color-interactive-hover`, while pressed `--ws-color-interactive-active`. Do not mix a hover color of your own.
|
|
182
|
+
- **A tick** is `--ws-icon-check` from `css/icons.css`, a mask like the other icons: a ticked box, a done step, a sent form. Draw it at 1rem in `currentcolor`, or `--ws-color-on-interactive` on a checked box.
|
|
183
|
+
- **A number field has no spin buttons.** `base.css` hides the browser's own, and the arrow keys still step the value. Without `base.css`, hide them the same way: `appearance: textfield` on the field, and `appearance: none` on its `::-webkit-inner-spin-button` and `::-webkit-outer-spin-button`.
|
|
184
|
+
|
|
185
|
+
A **segmented control** is a few buttons with one pressed, such as a switch between the languages of a page:
|
|
186
|
+
|
|
187
|
+
```html
|
|
188
|
+
<div class="ws-segmented" role="group" aria-label="Language">
|
|
189
|
+
<button type="button" aria-pressed="true" lang="en">English</button>
|
|
190
|
+
<button type="button" aria-pressed="false" lang="sr">Srpski</button>
|
|
191
|
+
</div>
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
- Give the group a name with `aria-label`, and each button `aria-pressed`. Pressing a button presses it and releases the one that was pressed. Pressing the pressed one does nothing.
|
|
195
|
+
- Keys: each button is a stop of the Tab key, and Enter or Space presses it. No arrow keys: those belong to a radio group. A choice that is a value of a form, sent with it, is a group of radio buttons, not this.
|
|
196
|
+
- The pressed button is raised, in the text color, with an edge of the interactive color twice as thick, at least 3:1 on the page and on the raised fill. In forced colors it takes the system's selection colors. Do not fill it with the interactive color: next to a primary button it would be as loud.
|
|
197
|
+
|
|
198
|
+
**Terms and values**, a row each, are a `<dl class="ws-pairs">`: the answers of a form on its review step. The term is in the voice of a label, its value in the face of a field. The terms share a column as wide as the longest of them, at most two fifths of the row, so the values line up and have the rest of it. With `ws-pairs--amounts` the amounts take what the widest of them needs, and the terms the rest of the row. A long value wraps: give a long email or URL a `<wbr />` after its `@` or a `/`, so it breaks there. A value that still does not fit breaks anywhere, as a last resort.
|
|
199
|
+
|
|
200
|
+
```html
|
|
201
|
+
<dl class="ws-pairs ws-pairs--amounts">
|
|
202
|
+
<div>
|
|
203
|
+
<dt>2 × workshop ticket</dt>
|
|
204
|
+
<dd>€96.00</dd>
|
|
205
|
+
</div>
|
|
206
|
+
<div>
|
|
207
|
+
<dt>Lunch</dt>
|
|
208
|
+
<dd>€12.50</dd>
|
|
209
|
+
</div>
|
|
210
|
+
<div>
|
|
211
|
+
<dt>Booking fee</dt>
|
|
212
|
+
<dd>€1.00</dd>
|
|
213
|
+
</div>
|
|
214
|
+
<div class="ws-pairs__total">
|
|
215
|
+
<dt>Total</dt>
|
|
216
|
+
<dd>€109.50</dd>
|
|
217
|
+
</div>
|
|
218
|
+
</dl>
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
- `ws-pairs--amounts` is for money and other numbers: each value at the right edge, in figures of one width, so the digits of the rows line up. Write each amount whole, with its currency and the same number of decimals.
|
|
222
|
+
- `ws-pairs__total` is the last row: set off by a solid rule, and semibold.
|
|
223
|
+
|
|
224
|
+
### Code blocks
|
|
225
|
+
|
|
226
|
+
- **A block scrolls sideways.** One that shows what a person typed, which a phone would cut off, takes `ws-code--wrap` and wraps its lines instead.
|
|
227
|
+
- **Its lines hang.** When each line is a `<span class="line">` with `--ws-code-hang`, its indent in characters plus two, the rest of a wrapped line starts one level in from the line's own text. With Shiki, the `hangingIndent` transformer gives each line its own:
|
|
228
|
+
|
|
229
|
+
```ts
|
|
230
|
+
import { codeTheme, hangingIndent } from '@whatsaaaa/design-system/shiki'
|
|
231
|
+
|
|
232
|
+
const html = highlighter.codeToHtml(json, {
|
|
233
|
+
lang: 'json',
|
|
234
|
+
theme: codeTheme,
|
|
235
|
+
transformers: [hangingIndent()],
|
|
236
|
+
})
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
- **Shiki is large.** With one language and the JavaScript engine it is about 40 KB gzipped, enough to push a small app past a bundler's chunk warning. When code blocks are not on the first screen, load it when a block needs it, with a dynamic `import()` of `shiki/core`, its JavaScript engine and the languages you use, so it is a chunk of its own: show the code as plain text in `--ws-code-text` first, and the colors when they arrive. For one small language, such as the JSON a form sends, a tokenizer of your own that colors with the `--ws-syntax-*` tokens needs no Shiki at all.
|
|
240
|
+
|
|
171
241
|
## 7. Keys
|
|
172
242
|
|
|
173
243
|
A key hint in a status line has to work. Put `data-ws-key` on the control the key presses, give the status line the keys switch, and turn the shortcuts on:
|
|
@@ -209,14 +279,15 @@ The switch is not optional. The keys are single characters that act on the whole
|
|
|
209
279
|
## 8. The ghost
|
|
210
280
|
|
|
211
281
|
```ts
|
|
212
|
-
import { defineGhost, ghostMarkup, ghostSvg } from '@whatsaaaa/design-system/ghost'
|
|
282
|
+
import { defineGhost, ghostElement, ghostMarkup, ghostSvg } from '@whatsaaaa/design-system/ghost'
|
|
213
283
|
|
|
214
284
|
defineGhost() // registers <ws-ghost>, in the browser
|
|
215
285
|
```
|
|
216
286
|
|
|
217
|
-
- `<ws-ghost px="6"></ws-ghost>` is the ghost with the easter egg. Render `ghostMarkup({ px: 6 })` inside it on the server.
|
|
218
|
-
- `ghostSvg({ px: 2 })` is the ghost as a picture, for a link or a decoration.
|
|
219
|
-
- `
|
|
287
|
+
- `<ws-ghost px="6"></ws-ghost>` is the ghost with the easter egg. Render `ghostMarkup({ px: 6 })` inside it on the server. It fills itself in when it is empty, and draws its speech bubble, without setting `innerHTML`.
|
|
288
|
+
- `ghostSvg({ px: 2 })` is the ghost as a picture, for a link or a decoration. `ghostElement({ px: 2 })` is the same picture as an element, for a script that adds it with `append`.
|
|
289
|
+
- In a component, where markup would need `innerHTML`, `v-html` or `dangerouslySetInnerHTML`, take the files instead: `ghost-on-dark.svg` and `ghost-on-light.svg`, the ghost without the margin of its grid, 20 by 24. Put both in, with `ws-theme-dark` and `ws-theme-light`.
|
|
290
|
+
- `px` is the size of one sprite pixel. Use whole numbers. A large ghost, such as the one next to the display name, takes `compact-px="4"` too: its size below 64rem, from 1 to 5.
|
|
220
291
|
|
|
221
292
|
Do not recolor the ghost, do not draw on it, do not rotate or stretch it, and do not redraw it. Its tongue is always the brand color. On a project's site the ghost links to the handle's site, and the project's own sprite is the logo.
|
|
222
293
|
|
|
@@ -229,6 +300,7 @@ Generated files are in `assets/<name>/`, for `whatsaaaa` and for each project. `
|
|
|
229
300
|
| Favicon | `favicon.ico`, `favicon.svg`, `apple-touch-icon.png`. `icon-192.png` and `icon-512.png` for a manifest |
|
|
230
301
|
| Logo on any background | `mark.svg` |
|
|
231
302
|
| Logo in a header | `mark-on-dark.svg`, `mark-on-light.svg`, or `mark-mono.svg` to take the text color |
|
|
303
|
+
| The ghost in a link | `ghost-on-dark.svg`, `ghost-on-light.svg`, the handle's only |
|
|
232
304
|
| Name | `wordmark-dark.svg`, `wordmark-light.svg` |
|
|
233
305
|
| Logo with name | `lockup-dark.svg`, `lockup-light.svg` |
|
|
234
306
|
| Top of a README | `readme-header.svg` |
|
|
@@ -237,6 +309,8 @@ Generated files are in `assets/<name>/`, for `whatsaaaa` and for each project. `
|
|
|
237
309
|
|
|
238
310
|
Copy the files you need into the project. Show a mark at 16, 32, 48 or 64 px, where its pixels are sharp.
|
|
239
311
|
|
|
312
|
+
A mark's box is its whole 16 by 16 grid, with the empty pixels around the sprite. A project's sprite leaves two columns empty on each side, an eighth of the width, so at 32 px its pixels start 4 px inside the box. To put them on an edge, such as the edge the content of a page starts at, pull the image out by that much: `margin-inline: calc(-1 * var(--ws-space-4))` at 32 px. The ghost's files have no margin.
|
|
313
|
+
|
|
240
314
|
Never edit a file in `assets/`. To change artwork, change its source and run `pnpm assets` in this repository. For a project that has no kit yet, add a file like `identity/projects/form-builder.json` first.
|
|
241
315
|
|
|
242
316
|
## 10. Docs sites
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@whatsaaaa/design-system",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "Whatsaaaa's design system: brand identity, design tokens, typography, docs theme and asset kit",
|
|
5
5
|
"homepage": "https://github.com/whatsaaaa/design-system#readme",
|
|
6
6
|
"bugs": "https://github.com/whatsaaaa/design-system/issues",
|
|
@@ -103,6 +103,7 @@
|
|
|
103
103
|
"png-to-ico": "^3.0.2",
|
|
104
104
|
"postcss-html": "^2.0.0",
|
|
105
105
|
"publint": "^0.3.25",
|
|
106
|
+
"shiki": "^2.5.0",
|
|
106
107
|
"stylelint": "^18.0.0",
|
|
107
108
|
"stylelint-config-standard": "^41.0.0",
|
|
108
109
|
"stylelint-value-no-unknown-custom-properties": "^6.1.1",
|
|
@@ -118,10 +118,10 @@
|
|
|
118
118
|
--vp-button-brand-bg: var(--ws-color-interactive);
|
|
119
119
|
--vp-button-brand-hover-border: transparent;
|
|
120
120
|
--vp-button-brand-hover-text: var(--ws-color-on-interactive);
|
|
121
|
-
--vp-button-brand-hover-bg: var(--ws-color-interactive);
|
|
121
|
+
--vp-button-brand-hover-bg: var(--ws-color-interactive-hover);
|
|
122
122
|
--vp-button-brand-active-border: transparent;
|
|
123
123
|
--vp-button-brand-active-text: var(--ws-color-on-interactive);
|
|
124
|
-
--vp-button-brand-active-bg: var(--ws-color-interactive);
|
|
124
|
+
--vp-button-brand-active-bg: var(--ws-color-interactive-active);
|
|
125
125
|
--vp-button-alt-border: var(--ws-color-field-border);
|
|
126
126
|
--vp-button-alt-text: var(--ws-color-text);
|
|
127
127
|
--vp-button-alt-bg: transparent;
|
package/tokens/contrast.json
CHANGED
|
@@ -97,6 +97,24 @@
|
|
|
97
97
|
"min": 4.5,
|
|
98
98
|
"use": "The label of a primary button"
|
|
99
99
|
},
|
|
100
|
+
{
|
|
101
|
+
"foreground": "color.on-interactive",
|
|
102
|
+
"background": "color.interactive-hover",
|
|
103
|
+
"min": 4.5,
|
|
104
|
+
"use": "The label of a primary button under the pointer"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"foreground": "color.on-interactive",
|
|
108
|
+
"background": "color.interactive-active",
|
|
109
|
+
"min": 4.5,
|
|
110
|
+
"use": "The label of a primary button while it is pressed"
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
"foreground": "color.interactive",
|
|
114
|
+
"background": "color.raised",
|
|
115
|
+
"min": 3,
|
|
116
|
+
"use": "The edge of a pressed segment"
|
|
117
|
+
},
|
|
100
118
|
{ "foreground": "color.tag-text", "background": "color.tag-bg", "min": 4.5, "use": "Tags" },
|
|
101
119
|
{
|
|
102
120
|
"foreground": "color.tip",
|
package/tokens/core.tokens.json
CHANGED
|
@@ -271,6 +271,38 @@
|
|
|
271
271
|
}
|
|
272
272
|
}
|
|
273
273
|
},
|
|
274
|
+
"tagline": {
|
|
275
|
+
"$description": "The line under the display name on a home page.",
|
|
276
|
+
"$value": {
|
|
277
|
+
"fontFamily": "{font.family.sans}",
|
|
278
|
+
"fontSize": {
|
|
279
|
+
"value": 1.25,
|
|
280
|
+
"unit": "rem"
|
|
281
|
+
},
|
|
282
|
+
"fontWeight": 500,
|
|
283
|
+
"lineHeight": 1.5,
|
|
284
|
+
"letterSpacing": {
|
|
285
|
+
"value": 0,
|
|
286
|
+
"unit": "rem"
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
},
|
|
290
|
+
"tagline-compact": {
|
|
291
|
+
"$description": "The tagline on phones.",
|
|
292
|
+
"$value": {
|
|
293
|
+
"fontFamily": "{font.family.sans}",
|
|
294
|
+
"fontSize": {
|
|
295
|
+
"value": 1.125,
|
|
296
|
+
"unit": "rem"
|
|
297
|
+
},
|
|
298
|
+
"fontWeight": 500,
|
|
299
|
+
"lineHeight": 1.5,
|
|
300
|
+
"letterSpacing": {
|
|
301
|
+
"value": 0,
|
|
302
|
+
"unit": "rem"
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
},
|
|
274
306
|
"lead": {
|
|
275
307
|
"$description": "The first paragraph of a page.",
|
|
276
308
|
"$value": {
|
|
@@ -606,6 +638,27 @@
|
|
|
606
638
|
"unit": "rem"
|
|
607
639
|
},
|
|
608
640
|
"$description": "Height of the status line."
|
|
641
|
+
},
|
|
642
|
+
"control": {
|
|
643
|
+
"$value": {
|
|
644
|
+
"value": 2.5,
|
|
645
|
+
"unit": "rem"
|
|
646
|
+
},
|
|
647
|
+
"$description": "Height of a one-line field, a button and a segmented control."
|
|
648
|
+
},
|
|
649
|
+
"check": {
|
|
650
|
+
"$value": {
|
|
651
|
+
"value": 1.25,
|
|
652
|
+
"unit": "rem"
|
|
653
|
+
},
|
|
654
|
+
"$description": "A checkbox or a radio button."
|
|
655
|
+
},
|
|
656
|
+
"step": {
|
|
657
|
+
"$value": {
|
|
658
|
+
"value": 1.5,
|
|
659
|
+
"unit": "rem"
|
|
660
|
+
},
|
|
661
|
+
"$description": "The number of a step in its circle."
|
|
609
662
|
}
|
|
610
663
|
},
|
|
611
664
|
"motion": {
|
|
@@ -57,6 +57,22 @@
|
|
|
57
57
|
"$value": "{palette.main.foam}",
|
|
58
58
|
"$description": "Links, the focus ring, checked controls and the primary button fill."
|
|
59
59
|
},
|
|
60
|
+
"interactive-hover": {
|
|
61
|
+
"$value": {
|
|
62
|
+
"colorSpace": "srgb",
|
|
63
|
+
"components": [0.6745, 0.8745, 0.9098],
|
|
64
|
+
"hex": "#acdfe8"
|
|
65
|
+
},
|
|
66
|
+
"$description": "The interactive fill under the pointer, such as a hovered primary button: the interactive color 0.05 further from the page in OKLab lightness."
|
|
67
|
+
},
|
|
68
|
+
"interactive-active": {
|
|
69
|
+
"$value": {
|
|
70
|
+
"colorSpace": "srgb",
|
|
71
|
+
"components": [0.7373, 0.9412, 0.9765],
|
|
72
|
+
"hex": "#bcf0f9"
|
|
73
|
+
},
|
|
74
|
+
"$description": "The interactive fill while it is pressed: 0.1 further from the page in OKLab lightness."
|
|
75
|
+
},
|
|
60
76
|
"on-interactive": {
|
|
61
77
|
"$value": "{palette.main.base}",
|
|
62
78
|
"$description": "Text on the interactive fill."
|
|
@@ -57,6 +57,22 @@
|
|
|
57
57
|
"$value": "{palette.dawn.pine}",
|
|
58
58
|
"$description": "Links, the focus ring, checked controls and the primary button fill."
|
|
59
59
|
},
|
|
60
|
+
"interactive-hover": {
|
|
61
|
+
"$value": {
|
|
62
|
+
"colorSpace": "srgb",
|
|
63
|
+
"components": [0.0863, 0.3569, 0.4549],
|
|
64
|
+
"hex": "#165b74"
|
|
65
|
+
},
|
|
66
|
+
"$description": "The interactive fill under the pointer, such as a hovered primary button: the interactive color 0.05 further from the page in OKLab lightness."
|
|
67
|
+
},
|
|
68
|
+
"interactive-active": {
|
|
69
|
+
"$value": {
|
|
70
|
+
"colorSpace": "srgb",
|
|
71
|
+
"components": [0.0, 0.302, 0.3961],
|
|
72
|
+
"hex": "#004d65"
|
|
73
|
+
},
|
|
74
|
+
"$description": "The interactive fill while it is pressed: 0.1 further from the page in OKLab lightness."
|
|
75
|
+
},
|
|
60
76
|
"on-interactive": {
|
|
61
77
|
"$value": "{palette.dawn.base}",
|
|
62
78
|
"$description": "Text on the interactive fill."
|