@alis-build/design-system 0.29.0 → 0.30.1

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.
@@ -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
- - An icon only when the button sits in a set people scan, or `add` on a New or Add action wherever it sits ([buttons.md](../rules/buttons.md) § The form). No other icon on a filled or outlined button, and none on a dialog action.
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 an icon (a set people scan; never on filled) -->
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>Export
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 with no glyph above 600 can carry one for the phone (`edit` for "Edit session", `app-compact-only` on the glyph).
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.29.0",
3
+ "version": "0.30.1",
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: text only, unless scanned
81
-
82
- **The default is no icon**, because an icon draws attention and emphasis is
83
- rationed. Add a leading icon only when **both** hold: the button sits in a set of
84
- similar controls people scan repeatedly, and the glyph is conventional.
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
- - **No other icon on a lead**, filled or outlined, and none on a dialog action:
101
- "Create project" finishes what New started.
102
- - One icon, leading. The only trailing icon is a chevron meaning "opens a menu".
103
- - An icon belongs to the action, not the instance: "Delete" is iconed everywhere
104
- or nowhere.
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
 
@@ -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
 
package/rules/page.md CHANGED
@@ -67,11 +67,34 @@ means another route.
67
67
  - **The verbs follow the route**: each route tab shows the verbs that act on what
68
68
  it shows, and none when nothing can be done.
69
69
 
70
+ ## Close or back
71
+
72
+ One test: **is what you were on still there behind it?**
73
+
74
+ - **Yes: close (`close`) leads.** It opened beside or over a screen that stays: a
75
+ detail pane, the file pane, the shortcut sheet, the navigation drawer, a file
76
+ shown full size, a task you can leave half done (an interview in progress).
77
+ - **No: back (`arrow_back`) leads.** It took the screen's place, and back goes up
78
+ to where you came from: every detail screen, since it has its own route.
79
+ - **On a phone**, whatever covers the window leads with back, and the phone's back
80
+ gesture does the same.
81
+ - **Either one leads the bar**, its glyph on the 24px edge. Never on the trailing
82
+ edge, and never both.
83
+ - **Never an icon to leave a dialog, a message or a step.** A dialog leaves by
84
+ Cancel ([AppDialog](../components/AppDialog.md)). A snackbar goes by itself and
85
+ an alert stays until you act ([AppAlert](../components/AppAlert.md)). A step in
86
+ a flow goes back by a Back text button at the row's start
87
+ ([AppStepper](../components/AppStepper.md)).
88
+ - **`close` in a row or a chip removes that one**, named "Remove …"
89
+ ([AppChip](../components/AppChip.md), [AppCombobox](../components/AppCombobox.md),
90
+ [AppAttachment](../components/AppAttachment.md)). Never to delete, deny or
91
+ reject: those take words.
92
+
70
93
  ## A detail screen
71
94
 
72
- The same bar: the close button leading in flow, the name left, and renaming it or
73
- switching to a sibling as small icon buttons beside the name. Never a centred
74
- title with the close button pinned absolutely, never the name inside a pill
95
+ The same bar: back leading in flow, the name left, and renaming it or switching
96
+ to a sibling as small icon buttons beside the name. Never a centred title with
97
+ the back button pinned absolutely, never the name inside a pill
75
98
  button, and never the name again as a title in the body. The bar keeps the
76
99
  screen's edges: when the body is text at the prose measure, only the text is the
77
100
  centred column.