@apliteni/apliteni-ui 0.96.0 → 0.97.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/guidelines/button-labels.md +5 -5
- package/guidelines/iconography.md +12 -12
- package/package.json +1 -1
- package/react/README.md +4 -3
- package/src/styles/base.css +7 -0
- package/src/styles/table.css +6 -8
|
@@ -14,22 +14,22 @@
|
|
|
14
14
|
|
|
15
15
|
<!-- rule: glyph-repeats-the-verb -->
|
|
16
16
|
|
|
17
|
-
**Rule:** Add a glyph beside a label only when it depicts that label’s action, and treat
|
|
17
|
+
**Rule:** Add a glyph beside a label only when it depicts that label’s action, and treat a row’s buttons alike.
|
|
18
18
|
|
|
19
19
|
**Except:** A dismissing action beside a committing one is not a peer, and stays plain.
|
|
20
20
|
|
|
21
21
|
**Do:** The arrow downloads, the sheets copy.
|
|
22
22
|
|
|
23
|
-
**Don't:** A table is what is exported, not the export
|
|
23
|
+
**Don't:** A table is what is exported, not the export; the plain neighbour reads as lesser.
|
|
24
24
|
|
|
25
25
|
## Earn a wordless button
|
|
26
26
|
|
|
27
27
|
<!-- rule: wordless-earns-it -->
|
|
28
28
|
|
|
29
|
-
**Rule:** Drop a button’s words only when its glyph is learned everywhere, its action is on the closed list, and its name
|
|
29
|
+
**Rule:** Drop a button’s words only when its glyph is learned everywhere, its action is on the closed list, and its name reaches assistive technology and a hover title.
|
|
30
30
|
|
|
31
|
-
**Except:** [Icon-only controls](https://ui.apli.tech/storybook/?path=/story/guidelines-iconography--iconography) is the list
|
|
31
|
+
**Except:** [Icon-only controls](https://ui.apli.tech/storybook/?path=/story/guidelines-iconography--iconography) is the list. The folded rail shows its names beside the glyphs, so they carry no title.
|
|
32
32
|
|
|
33
33
|
**Do:** Overflow is on that list; the funnel is not.
|
|
34
34
|
|
|
35
|
-
**Don't:** A funnel could filter, sort or export
|
|
35
|
+
**Don't:** A funnel could filter, sort or export; the cog gave up the word that said which.
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
**Why:** Without a legend, readers need labels for unfamiliar glyphs.
|
|
10
10
|
|
|
11
|
-
**Except:**
|
|
11
|
+
**Except:** [Earn a wordless button](https://ui.apli.tech/storybook/?path=/story/guidelines-button-labels--button-labels) sets the three tests an entry passes, and the list grows by decision. Today: `x` to close or dismiss, `copy` to copy to clipboard, `moreHorizontal` and `moreVertical` for an overflow menu, `chevronDown` and `chevronUp` to expand or collapse. The shell’s chrome — theme toggle, sidebar toggle, collapsed-rail links — is wordless by a separate decision.
|
|
12
12
|
|
|
13
13
|
**Do:** Show an overflow menu without words; keep the Settings label.
|
|
14
14
|
|
|
@@ -18,15 +18,15 @@
|
|
|
18
18
|
|
|
19
19
|
<!-- rule: meaning -->
|
|
20
20
|
|
|
21
|
-
**Rule:** A circled glyph
|
|
21
|
+
**Rule:** A circled glyph is a state; a bare glyph is an action.
|
|
22
22
|
|
|
23
23
|
**Why:** Two meanings force readers to decide from context each time.
|
|
24
24
|
|
|
25
|
-
**Except:** Most glyphs show a thing, not a state or action, including `globe`, `database
|
|
25
|
+
**Except:** Most glyphs show a thing, not a state or action, including `globe`, `database` and `layers`. The split guides component choice, not the catalogue.
|
|
26
26
|
|
|
27
|
-
**Do:**
|
|
27
|
+
**Do:** `circleX` reports the failure; the bare `x` closes the toast.
|
|
28
28
|
|
|
29
|
-
**Don't:**
|
|
29
|
+
**Don't:** The same `x` carries both meanings.
|
|
30
30
|
|
|
31
31
|
## Preserve glyph paths
|
|
32
32
|
|
|
@@ -34,13 +34,13 @@
|
|
|
34
34
|
|
|
35
35
|
**Rule:** Use the Lucide path unchanged, and state when a glyph name differs.
|
|
36
36
|
|
|
37
|
-
**Why:**
|
|
37
|
+
**Why:** One source keeps the set consistent, and a recorded rename still traces back to it.
|
|
38
38
|
|
|
39
|
-
**Except:** A brand mark
|
|
39
|
+
**Except:** A brand mark with no Lucide original is allowed: `github` and `linkedin` are the vendor’s own marks and belong in BRAND.
|
|
40
40
|
|
|
41
|
-
**Do:**
|
|
41
|
+
**Do:** `circleCheck` is Lucide’s circle-check-big, path unchanged and name recorded.
|
|
42
42
|
|
|
43
|
-
**Don't:**
|
|
43
|
+
**Don't:** A redrawn path, or a rename nobody recorded.
|
|
44
44
|
|
|
45
45
|
## Status stroke width
|
|
46
46
|
|
|
@@ -48,10 +48,10 @@
|
|
|
48
48
|
|
|
49
49
|
**Rule:** Stroke a status glyph at 1.5 CSS px or wider, or require 4.5:1 text contrast instead of 3:1 graphic contrast.
|
|
50
50
|
|
|
51
|
-
**Why:** Visible width is `stroke-width × box ÷ 24`; below 1.5 CSS px
|
|
51
|
+
**Why:** Visible width is `stroke-width × box ÷ 24`; below 1.5 CSS px a stroke reads as a text stem and needs 4.5:1; above it, WCAG 1.4.11’s 3:1 graphic bar applies.
|
|
52
52
|
|
|
53
53
|
**Except:** Non-status glyphs, such as close buttons and chevrons, have no five-status pair to measure; their control owns their contrast.
|
|
54
54
|
|
|
55
|
-
**Do:**
|
|
55
|
+
**Do:** A 1.5 CSS px stroke, held to 3:1.
|
|
56
56
|
|
|
57
|
-
**Don't:**
|
|
57
|
+
**Don't:** A thinner stroke, still only 3:1.
|
package/package.json
CHANGED
package/react/README.md
CHANGED
|
@@ -658,9 +658,10 @@ size. Neither has a filled disc behind it.
|
|
|
658
658
|
there is no backdrop layer and no `backdrop` prop. Pass `title`, one short `body`
|
|
659
659
|
line, and React `actions`. There is no `eyebrow` prop: a confirmation carries one
|
|
660
660
|
title and at most one line under it, so put the outcome in the title rather than in a
|
|
661
|
-
label above it. A kit `Button` carries the focus ring already
|
|
662
|
-
a plain `<a
|
|
663
|
-
|
|
661
|
+
label above it. A kit `Button` carries the focus ring already, and so does
|
|
662
|
+
a router link or a plain `<a>`: the kit rings every anchor on `:focus-visible`. A
|
|
663
|
+
focusable that is neither — a `div` or `span` given `tabIndex` — still needs
|
|
664
|
+
`className="ui-focusable"`, or it falls back to the browser's own focus outline. An omitted or empty `actions`
|
|
664
665
|
leaves out the actions row. Hero and split default to h1; compact defaults to h2.
|
|
665
666
|
`level` overrides the heading rank, and a value outside 1–6 falls back to that layout
|
|
666
667
|
default. `confetti` enables the existing decorative animation. All three components
|
package/src/styles/base.css
CHANGED
|
@@ -141,6 +141,13 @@ svg:where(:not([width]):not([height])) {
|
|
|
141
141
|
.ui-focusable, in the vanilla topbar, React ThemeToggle and the React shell's bar
|
|
142
142
|
alike, so keyboard focus on it fell back to the browser's own outline in all three.
|
|
143
143
|
It has no class of its own to opt in with; it joins the list instead. Found on #385. */
|
|
144
|
+
/* `a` is here as an ELEMENT, not a class, because a link in running text is the one
|
|
145
|
+
control a consumer writes with no class on it at all — so it took the browser's
|
|
146
|
+
outline, which #457 refused. The net is over every anchor; a component that rings
|
|
147
|
+
its own anchor outranks this at two classes and keeps the shape it chose. The band
|
|
148
|
+
sits at whatever corner the link carries, which is the rule .ui-table's links
|
|
149
|
+
already take. Found on #586, decided on #587. */
|
|
150
|
+
a:focus-visible,
|
|
144
151
|
.ui-focusable:focus-visible,
|
|
145
152
|
.ui-snippet :focus-visible,
|
|
146
153
|
.ui-btn:focus-visible,
|
package/src/styles/table.css
CHANGED
|
@@ -145,14 +145,12 @@
|
|
|
145
145
|
top: 50%;
|
|
146
146
|
translate: 0 -50%;
|
|
147
147
|
}
|
|
148
|
-
/*
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
held by
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
outline-offset: var(--ring-offset);
|
|
155
|
-
}
|
|
148
|
+
/* No focus rule here any more. #510 gave a cell link the ring with a rule of this file's
|
|
149
|
+
own, because `base.css` reached no bare `a`; #587 put `a` on that shared list, so this
|
|
150
|
+
one painted the same two declarations a second time. The guarantee is unchanged and
|
|
151
|
+
still held by src/styles/table-focus.test.js — the corner the band follows is the
|
|
152
|
+
`border-radius` above, which is this file's and stays.
|
|
153
|
+
why: guidelines/state-set.md#focus-rings */
|
|
156
154
|
|
|
157
155
|
.ui-table__num { text-align: right; font-variant-numeric: tabular-nums; }
|
|
158
156
|
/* A numeric column is sized to its content while .ui-table__title claims the rest,
|