@alis-build/design-system 0.29.0 → 0.30.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/components/AppButton.md +14 -3
- package/components/AppTitleBar.md +1 -1
- package/package.json +1 -1
- package/rules/buttons.md +66 -10
- package/rules/known-gaps.md +1 -0
- package/rules/loading.md +3 -1
package/components/AppButton.md
CHANGED
|
@@ -11,10 +11,11 @@ Emphasis is allocated, not chosen ([buttons.md](../rules/buttons.md)).
|
|
|
11
11
|
- Cyan text is a link, never a button.
|
|
12
12
|
- **Error** (`app-btn--error`) for destructive actions, at the same level. **Quiet** (`app-btn--quiet`, `on-surface-variant`) for a quiet action beside content.
|
|
13
13
|
- No tonal or elevated buttons. A filled button scales to 97% and rounds to 12px when pressed (the CSS does it).
|
|
14
|
-
-
|
|
14
|
+
- **A word or a glyph, never both, outside the lexicon** ([buttons.md](../rules/buttons.md) § The form): `add` (New, Add), `upload`, `download`, `content_copy` (Copy) and `edit` lead their verb wherever it appears; `edit_square` leads a new conversation; a trailing chevron opens a menu and a trailing `open_in_new` leaves the product; a third party's mark leads a hand-off to them. No glyph on a filled button or a dialog's affirmative.
|
|
15
15
|
- **A shortcut** never goes in the label. A button with one takes an [AppTooltip](AppTooltip.md) that says the label and its keys, and `aria-keyshortcuts` ([shortcuts.md](../rules/shortcuts.md)); a button without one has no tooltip.
|
|
16
16
|
- The visible box is `control-height` (36px, 48 on touch), padded 24, and the target is `touch-target` ([buttons.md](../rules/buttons.md)). Text and outlined buttons are 600, the filled button 700. `app-btn--small` (32px, padded 12) belongs only in a table row. Inside a toggle group or table row, add `app-target--none`.
|
|
17
17
|
- **Loading** shows the work on the control the user pressed: a 16px spinner replaces the icon and the label stays (or becomes the present participle, "Deploying"). The button is busy, not disabled: full colour, presses ignored until it settles.
|
|
18
|
+
- **Done**, after a result nothing else on screen shows (a copy, a save in the background): ✓ (`check`) takes the leading glyph's place and the label says what happened ("Copied") for about two seconds, in a polite live region, then the button is back at rest.
|
|
18
19
|
- Work with steps you can count (a deploy, an upload) moves its indicator into the content once it starts: an [AppProgress](AppProgress.md), and the button goes back to rest. One wait, one indicator ([loading.md](../rules/loading.md)).
|
|
19
20
|
- If it shows only a glyph, it is an [AppIconButton](AppIconButton.md).
|
|
20
21
|
|
|
@@ -24,11 +25,16 @@ Emphasis is allocated, not chosen ([buttons.md](../rules/buttons.md)).
|
|
|
24
25
|
<!-- Text (default) -->
|
|
25
26
|
<button type="button" class="app-btn app-state app-target">View logs</button>
|
|
26
27
|
|
|
27
|
-
<!-- With
|
|
28
|
+
<!-- With a glyph from the lexicon (never on filled) -->
|
|
28
29
|
<button type="button" class="app-btn app-state app-target">
|
|
29
|
-
<span class="app-icon" aria-hidden="true">download</span>
|
|
30
|
+
<span class="app-icon" aria-hidden="true">download</span>Download
|
|
30
31
|
</button>
|
|
31
32
|
|
|
33
|
+
<!-- Leaves the product: open_in_new trails, and the name says so -->
|
|
34
|
+
<a class="app-btn app-state app-target" href="…" target="_blank" rel="noopener noreferrer" aria-label="Logs, opens in a new tab">
|
|
35
|
+
Logs<span class="app-icon" aria-hidden="true">open_in_new</span>
|
|
36
|
+
</a>
|
|
37
|
+
|
|
32
38
|
<!-- Outlined: the lead of a title bar, pane or empty state, when it starts something.
|
|
33
39
|
New and Add lead with add, at any rung -->
|
|
34
40
|
<button type="button" class="app-btn app-state app-target app-btn--outlined">
|
|
@@ -48,6 +54,11 @@ Emphasis is allocated, not chosen ([buttons.md](../rules/buttons.md)).
|
|
|
48
54
|
<span class="app-btn__spinner" aria-hidden="true"></span>Deploying
|
|
49
55
|
</button>
|
|
50
56
|
|
|
57
|
+
<!-- Done: a result you can't see, for about two seconds -->
|
|
58
|
+
<button type="button" class="app-btn app-state app-target">
|
|
59
|
+
<span class="app-icon" aria-hidden="true">check</span><span aria-live="polite">Copied</span>
|
|
60
|
+
</button>
|
|
61
|
+
|
|
51
62
|
<!-- Disabled -->
|
|
52
63
|
<button type="button" class="app-btn app-state app-target" disabled>Deploy</button>
|
|
53
64
|
|
|
@@ -22,7 +22,7 @@ See [page.md](../rules/page.md).
|
|
|
22
22
|
|
|
23
23
|
1. **Leading**: the menu button (`menu`), which opens the navigation drawer ([AppShell](AppShell.md)); back (`arrow_back`) on a detail route. Nothing on a screen with no navigation (joining an interview, signing in).
|
|
24
24
|
2. **The name**, page-title at its compact step (22/28 at 500, Material 3's Title Large Emphasized), truncating.
|
|
25
|
-
3. **The lead as its glyph alone**, its label the accessible name. A lead whose glyph wouldn't read on its own ("Generate key", "Install block") leaves the bar and leads ⋯ instead; a lead
|
|
25
|
+
3. **The lead as its glyph alone**, its label the accessible name. A lead whose glyph wouldn't read on its own ("Generate key", "Install block") leaves the bar and leads ⋯ instead; a lead whose verb has a glyph ([buttons.md](../rules/buttons.md) § The form) carries it at every width (`edit` for "Edit session").
|
|
26
26
|
4. **⋯** (`more_vert`), an [AppMenu](AppMenu.md) holding every other verb in the order they had, anything destructive last behind a divider. Left out when there are none. Rename lives here: never a double tap on the name.
|
|
27
27
|
|
|
28
28
|
The tabs scroll under it; the filter row is unchanged. Mark the parts that exist on only one side `app-compact-only` or `app-wide-only`, so one markup serves both.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alis-build/design-system",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.30.0",
|
|
4
4
|
"description": "The AlisX design system for coding agents: tokens, product CSS, component markup, capability marks, words and rules.",
|
|
5
5
|
"keywords": ["alisx", "design-system", "design-tokens", "css"],
|
|
6
6
|
"homepage": "https://alisx.com",
|
package/rules/buttons.md
CHANGED
|
@@ -77,11 +77,26 @@ stops it**, filled in `error`, and the label still names the outcome:
|
|
|
77
77
|
*Recording* in the same bar carries the signal
|
|
78
78
|
([AppComposer](../components/AppComposer.md)).
|
|
79
79
|
|
|
80
|
-
## The form:
|
|
81
|
-
|
|
82
|
-
**
|
|
83
|
-
|
|
84
|
-
|
|
80
|
+
## The form: a word, a glyph, or both from the lexicon
|
|
81
|
+
|
|
82
|
+
**A button is a word or a glyph** (a glyph alone is an
|
|
83
|
+
[AppIconButton](../components/AppIconButton.md)). It carries both only when the
|
|
84
|
+
glyph is in the lexicon below, because a glyph pulls the eye and emphasis is
|
|
85
|
+
rationed. Beside a word a glyph earns its place one of two ways: it is a
|
|
86
|
+
**landmark** for an action people come looking for, or it **tells** something the
|
|
87
|
+
word can't. Never a glyph that restates its verb for nothing, and never a mood (a
|
|
88
|
+
rocket on Deploy, a play glyph on Run).
|
|
89
|
+
|
|
90
|
+
**Landmarks.** One glyph per verb, and the verb carries it everywhere it
|
|
91
|
+
appears: a text button, a lead, a menu row in a menu with glyphs, an icon button.
|
|
92
|
+
|
|
93
|
+
| Verb | Glyph |
|
|
94
|
+
|---|---|
|
|
95
|
+
| New, Add | `add` |
|
|
96
|
+
| Upload | `upload` |
|
|
97
|
+
| Download | `download` |
|
|
98
|
+
| Copy | `content_copy` |
|
|
99
|
+
| Edit | `edit` |
|
|
85
100
|
|
|
86
101
|
- **`add` on every New and Add.** The action that brings a thing into a screen
|
|
87
102
|
(§ Naming the action) leads with the plain `add` glyph wherever it appears: a
|
|
@@ -91,17 +106,58 @@ similar controls people scan repeatedly, and the glyph is conventional.
|
|
|
91
106
|
its glyph is `add`. "Add a follow-up round" works inside a thing and keeps none,
|
|
92
107
|
and so does a field's own action ("Add" beside an input, taking what you
|
|
93
108
|
typed): it is that field's affirmative.
|
|
109
|
+
- **A verb joins the lexicon only when all four hold.** People know the glyph
|
|
110
|
+
without its word, from the products they already use. People come to the screen
|
|
111
|
+
looking for the action, rather than being offered it at the moment it fits
|
|
112
|
+
(Retry on an error line is offered). The glyph means one thing in the product.
|
|
113
|
+
And the action can't be regretted, because a landmark pulls the eye, and the eye
|
|
114
|
+
shouldn't go first to what destroys. So Refresh, Retry and Update now keep no
|
|
115
|
+
glyph (one arrow would mean three verbs), nor Delete (its `error` ink already
|
|
116
|
+
marks it), nor Preview (the eye also means show and hide), nor Share (its glyph
|
|
117
|
+
differs by platform).
|
|
118
|
+
|
|
119
|
+
**Tells.** The glyph says what the word can't: what kind of action, or where the
|
|
120
|
+
click goes.
|
|
121
|
+
|
|
94
122
|
- **`edit_square` on a new conversation.** `add` brings something into what you
|
|
95
123
|
are looking at: a project into the list, a file into the message. A new chat
|
|
96
124
|
brings nothing in; it leaves this conversation for a blank one, so "New chat"
|
|
97
125
|
and "New conversation" lead with `edit_square`, as does a rail row's "new" for
|
|
98
126
|
them ([AppShell](../components/AppShell.md)). On a conversation, that keeps the
|
|
99
127
|
composer's `add` the only + on screen.
|
|
100
|
-
- **
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
128
|
+
- **A trailing chevron (`expand_more`)**: the button opens a menu.
|
|
129
|
+
- **A trailing `open_in_new`**: the button leaves the product, in a new tab or for
|
|
130
|
+
another site, and its accessible name says so ("Logs, opens in a new tab"), as
|
|
131
|
+
on an [AppAttachment](../components/AppAttachment.md) and an
|
|
132
|
+
[AppMenu](../components/AppMenu.md) row. Never `arrow_outward` or
|
|
133
|
+
`arrow_forward` for it.
|
|
134
|
+
- **A third party's mark on a hand-off**: "Sign in with Google", "Connect
|
|
135
|
+
GitHub", "Open in VS Code". The button takes you to that party, so it leads
|
|
136
|
+
with their mark, at the glyph's size and never recoloured. Only sign-in,
|
|
137
|
+
connect and open-in buttons, and only marks from the system's list
|
|
138
|
+
([known-gaps.md](known-gaps.md) § Assets).
|
|
139
|
+
- **`stop_circle` on a capture in flight**, with the red of § Colour.
|
|
140
|
+
|
|
141
|
+
**States** take the leading glyph's place, then go:
|
|
142
|
+
|
|
143
|
+
- **A spinner while it works** ([AppButton](../components/AppButton.md) §
|
|
144
|
+
Loading).
|
|
145
|
+
- **✓ (`check`) after a result nothing else on screen shows**: a copy to the
|
|
146
|
+
clipboard, a save in the background. For about two seconds the glyph is ✓ and
|
|
147
|
+
the label says what happened ("Copied"), announced politely; then the button is
|
|
148
|
+
back at rest. On an icon button the glyph itself swaps, and the tooltip says
|
|
149
|
+
"Copied".
|
|
150
|
+
|
|
151
|
+
The rest:
|
|
152
|
+
|
|
153
|
+
- **No glyph on a filled button or a dialog's affirmative**: "Create project"
|
|
154
|
+
finishes what New started. The capture in flight is the one filled button with
|
|
155
|
+
one. A lead takes its verb's landmark or none: "New environment" with `add`,
|
|
156
|
+
"Edit session" with `edit`.
|
|
157
|
+
- **One glyph.** It leads, except the two that say where the click goes (the
|
|
158
|
+
chevron, `open_in_new`), which trail.
|
|
159
|
+
- **Alis's actions say so in words** ("Draft with Alis"). ✦ (`auto_awesome`)
|
|
160
|
+
marks what Alis wrote ([AppChip](../components/AppChip.md)), never a button.
|
|
105
161
|
|
|
106
162
|
## Rules
|
|
107
163
|
|
package/rules/known-gaps.md
CHANGED
|
@@ -30,5 +30,6 @@ What the system doesn't decide yet, in one place. When you hit one, take the qui
|
|
|
30
30
|
|
|
31
31
|
- No font files are vendored. `fonts.css` loads Nunito Sans and Material Symbols from Google Fonts, for prototypes; in production, self-host them (Material Symbols as the subset you use).
|
|
32
32
|
- The coding-agent ("works with") marks are not in this package; alisx.com carries them.
|
|
33
|
+
- **Third-party marks for hand-offs** ("Sign in with Google", "Connect GitHub", "Open in VS Code"; [buttons.md](buttons.md) § The form) have no list yet. Until a mark is added here with its owner's usage terms, the button is its words alone.
|
|
33
34
|
- **The email wordmark PNGs** (`email/alisx-wordmark*.png`) need a public home: a mail app fetches the image from a URL, and alisx.com doesn't serve them yet. The shell reads it from its `assets_url` slot ([email.md](email.md)).
|
|
34
35
|
- **The email button in Outlook for Windows** draws square: rounding it needs VML, which the shell leaves out.
|
package/rules/loading.md
CHANGED
|
@@ -49,7 +49,9 @@ decides which screen comes next (an invitation link, account setup, a handoff).
|
|
|
49
49
|
- **No "Loading…".** A line under the mark names what is coming, and only when
|
|
50
50
|
the wait is long enough to need one: *Setting up your interview*.
|
|
51
51
|
- **Never inside a control.** A button, a field or a chip keeps its own small
|
|
52
|
-
progress indicator, and the spinner stays there.
|
|
52
|
+
progress indicator, and the spinner stays there. A result nothing else on
|
|
53
|
+
screen shows ends there too: ✓ for about two seconds, then rest
|
|
54
|
+
([buttons.md](buttons.md) § The form).
|
|
53
55
|
- **It is `signal`** ([colour.md](colour.md)) and holds still under reduced
|
|
54
56
|
motion. Both belong to the loader; a site never sets its colour.
|
|
55
57
|
|