al-design-system 1.1.0 → 1.3.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 +5 -3
- package/README.pt-BR.md +5 -3
- package/dist/al.css +318 -2
- package/dist/components/pagination.css +196 -0
- package/dist/components/progress.css +115 -0
- package/dist/foundation.css +4 -1
- package/dist/tokens.json +5 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@ An open-source design system, from Figma to code. Plain CSS, a little vanilla Ja
|
|
|
10
10
|
|
|
11
11
|
## What it is
|
|
12
12
|
|
|
13
|
-
- **Foundation +
|
|
13
|
+
- **Foundation + 26 components**, designed in Figma and coded from the same tokens.
|
|
14
14
|
- **Light and dark themes** built in. It follows the operating system by default, and you can force one.
|
|
15
15
|
- **Accessibility is checked by the build.** Every rendered combination (variant × state × theme) is measured for contrast against the background it actually sits on, and each component's markup contract is verified. If something fails, the build stops.
|
|
16
16
|
- **Nothing is typed by hand.** Tokens, CSS variables, `tokens.json` and the documentation tables are all generated from one source.
|
|
@@ -40,9 +40,11 @@ An open-source design system, from Figma to code. Plain CSS, a little vanilla Ja
|
|
|
40
40
|
| | Drawer | ✓ | [guidelines](src/components/drawer/guidelines.md) |
|
|
41
41
|
| Navigation | Sidebar | ✓ | [guidelines](src/components/sidebar/guidelines.md) |
|
|
42
42
|
| | Breadcrumb | ✓ | [guidelines](src/components/breadcrumb/guidelines.md) |
|
|
43
|
+
| | Pagination | | [guidelines](src/components/pagination/guidelines.md) |
|
|
43
44
|
| Feedback | Tooltip | ✓ | [guidelines](src/components/tooltip/guidelines.md) |
|
|
44
45
|
| | Toast | ✓ | [guidelines](src/components/toast/guidelines.md) |
|
|
45
46
|
| | Alert | ✓ | [guidelines](src/components/alert/guidelines.md) |
|
|
47
|
+
| | Progress | | [guidelines](src/components/progress/guidelines.md) |
|
|
46
48
|
|
|
47
49
|
Each guidelines file holds the usage rules (when to use it, when not to, content, behavior and accessibility) and, when there are any, the contrast exceptions the component declares.
|
|
48
50
|
|
|
@@ -55,7 +57,7 @@ npm install al-design-system
|
|
|
55
57
|
Or straight from a CDN, pinned to a version:
|
|
56
58
|
|
|
57
59
|
```html
|
|
58
|
-
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/al-design-system@1.
|
|
60
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/al-design-system@1.3.0/dist/al.css">
|
|
59
61
|
```
|
|
60
62
|
|
|
61
63
|
Each [GitHub Release](https://github.com/guilhermedworakowski/al-design-system/releases) also carries the `dist/` folder as a zip.
|
|
@@ -64,7 +66,7 @@ Each [GitHub Release](https://github.com/guilhermedworakowski/al-design-system/r
|
|
|
64
66
|
|
|
65
67
|
| File | What it is |
|
|
66
68
|
|---|---|
|
|
67
|
-
| `al.css` | Foundation + all
|
|
69
|
+
| `al.css` | Foundation + all 26 components, in one file |
|
|
68
70
|
| `foundation.css` | Only the Foundation: color, typography, spacing, radius, icon size, elevation, focus ring and motion |
|
|
69
71
|
| `components/<name>.css` | One component (its tokens + its CSS) |
|
|
70
72
|
| `components/<name>.js` | The behavior, for the 9 components that have a script |
|
package/README.pt-BR.md
CHANGED
|
@@ -10,7 +10,7 @@ Design system open source, do Figma ao código. CSS puro, um pouco de JavaScript
|
|
|
10
10
|
|
|
11
11
|
## O que é
|
|
12
12
|
|
|
13
|
-
- **Foundation +
|
|
13
|
+
- **Foundation + 26 componentes**, desenhados no Figma e codados a partir dos mesmos tokens.
|
|
14
14
|
- **Temas claro e escuro** já incluídos. Por padrão segue o sistema operacional, e dá para forçar um.
|
|
15
15
|
- **A acessibilidade é conferida no build.** Cada combinação renderizada (variante × estado × tema) tem o contraste medido contra o fundo onde ela realmente aparece, e o contrato de marcação de cada componente é verificado. Se algo reprova, o build para.
|
|
16
16
|
- **Nada é digitado à mão.** Tokens, variáveis CSS, `tokens.json` e as tabelas da documentação saem todos de uma fonte só.
|
|
@@ -40,9 +40,11 @@ Design system open source, do Figma ao código. CSS puro, um pouco de JavaScript
|
|
|
40
40
|
| | Drawer | ✓ | [diretrizes](src/components/drawer/guidelines.md) |
|
|
41
41
|
| Navegação | Sidebar | ✓ | [diretrizes](src/components/sidebar/guidelines.md) |
|
|
42
42
|
| | Breadcrumb | ✓ | [diretrizes](src/components/breadcrumb/guidelines.md) |
|
|
43
|
+
| | Pagination | | [diretrizes](src/components/pagination/guidelines.md) |
|
|
43
44
|
| Feedback | Tooltip | ✓ | [diretrizes](src/components/tooltip/guidelines.md) |
|
|
44
45
|
| | Toast | ✓ | [diretrizes](src/components/toast/guidelines.md) |
|
|
45
46
|
| | Alert | ✓ | [diretrizes](src/components/alert/guidelines.md) |
|
|
47
|
+
| | Progress | | [diretrizes](src/components/progress/guidelines.md) |
|
|
46
48
|
|
|
47
49
|
Cada arquivo de diretrizes traz as regras de uso (quando usar, quando não usar, conteúdo, comportamento e acessibilidade) e, quando houver, as exceções de contraste que o componente declara. Por enquanto as diretrizes estão em inglês; a versão em português chega junto com o site novo.
|
|
48
50
|
|
|
@@ -55,7 +57,7 @@ npm install al-design-system
|
|
|
55
57
|
Ou direto de uma CDN, fixado numa versão:
|
|
56
58
|
|
|
57
59
|
```html
|
|
58
|
-
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/al-design-system@1.
|
|
60
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/al-design-system@1.3.0/dist/al.css">
|
|
59
61
|
```
|
|
60
62
|
|
|
61
63
|
Cada [Release no GitHub](https://github.com/guilhermedworakowski/al-design-system/releases) também traz a pasta `dist/` num zip.
|
|
@@ -64,7 +66,7 @@ Cada [Release no GitHub](https://github.com/guilhermedworakowski/al-design-syste
|
|
|
64
66
|
|
|
65
67
|
| Arquivo | O que é |
|
|
66
68
|
|---|---|
|
|
67
|
-
| `al.css` | Foundation + os
|
|
69
|
+
| `al.css` | Foundation + os 26 componentes, num arquivo só |
|
|
68
70
|
| `foundation.css` | Só a Foundation: cor, tipografia, espaçamento, radius, tamanho de ícone, elevação, anel de foco e motion |
|
|
69
71
|
| `components/<nome>.css` | Um componente (os tokens + o CSS dele) |
|
|
70
72
|
| `components/<nome>.js` | O comportamento, para os 9 componentes que têm script |
|
package/dist/al.css
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
/* AL Design System 1.
|
|
1
|
+
/* AL Design System 1.3.0 - Foundation + 26 components.
|
|
2
2
|
* MIT. https://github.com/guilhermedworakowski/al-design-system
|
|
3
3
|
*/
|
|
4
4
|
/* AL Design System - Foundation
|
|
5
|
-
* v1.
|
|
5
|
+
* v1.3.0 - MIT
|
|
6
6
|
* GENERATED by src/foundation/css.py. Do not edit by hand: run the script.
|
|
7
7
|
*/
|
|
8
8
|
|
|
@@ -90,6 +90,7 @@
|
|
|
90
90
|
--al-bg-active-raised: #E0E0E0;
|
|
91
91
|
--al-bg-thumb: #B3B3B3;
|
|
92
92
|
--al-bg-thumb-disabled: #CECECE;
|
|
93
|
+
--al-bg-track: #E0E0E0;
|
|
93
94
|
--al-bg-scrim: #1818188F;
|
|
94
95
|
--al-bg-brand: #FC5000;
|
|
95
96
|
--al-bg-brand-hover: #C53900;
|
|
@@ -247,6 +248,7 @@
|
|
|
247
248
|
--al-bg-active-raised: #717171;
|
|
248
249
|
--al-bg-thumb: #717171;
|
|
249
250
|
--al-bg-thumb-disabled: #565656;
|
|
251
|
+
--al-bg-track: #565656;
|
|
250
252
|
--al-bg-scrim: #000000A3;
|
|
251
253
|
--al-bg-brand: #FC5000;
|
|
252
254
|
--al-bg-brand-hover: #EA4900;
|
|
@@ -312,6 +314,7 @@
|
|
|
312
314
|
--al-bg-active-raised: #717171;
|
|
313
315
|
--al-bg-thumb: #717171;
|
|
314
316
|
--al-bg-thumb-disabled: #565656;
|
|
317
|
+
--al-bg-track: #565656;
|
|
315
318
|
--al-bg-scrim: #000000A3;
|
|
316
319
|
--al-bg-brand: #FC5000;
|
|
317
320
|
--al-bg-brand-hover: #EA4900;
|
|
@@ -6927,3 +6930,316 @@
|
|
|
6927
6930
|
@media (prefers-reduced-motion: reduce) {
|
|
6928
6931
|
.al-link { transition: none; }
|
|
6929
6932
|
}
|
|
6933
|
+
|
|
6934
|
+
/* AL Design System - Progress tokens
|
|
6935
|
+
* GENERATED by src/components/progress/tokens.py. Do not edit by hand.
|
|
6936
|
+
*
|
|
6937
|
+
* Every color is a semantic the theme switches on :root.
|
|
6938
|
+
*/
|
|
6939
|
+
|
|
6940
|
+
:root {
|
|
6941
|
+
/* color */
|
|
6942
|
+
--al-progress-track-bg: var(--al-bg-track);
|
|
6943
|
+
--al-progress-fill-bg: var(--al-bg-brand);
|
|
6944
|
+
--al-progress-label-text: var(--al-text-primary);
|
|
6945
|
+
--al-progress-meta-text: var(--al-text-secondary);
|
|
6946
|
+
|
|
6947
|
+
/* geometry */
|
|
6948
|
+
--al-progress-radius: var(--al-radius-full);
|
|
6949
|
+
--al-progress-height: var(--al-space-8);
|
|
6950
|
+
--al-progress-height-thin: var(--al-space-4);
|
|
6951
|
+
--al-progress-gap: var(--al-space-8);
|
|
6952
|
+
|
|
6953
|
+
/* type - label and meta share one style */
|
|
6954
|
+
--al-progress-font-size: var(--al-font-size-sm);
|
|
6955
|
+
--al-progress-line-height: var(--al-line-height-sm);
|
|
6956
|
+
--al-progress-font-weight: var(--al-font-weight-regular);
|
|
6957
|
+
}
|
|
6958
|
+
|
|
6959
|
+
/* AL Design System - Progress
|
|
6960
|
+
*
|
|
6961
|
+
* Determinate only. The bar is a native <progress value max>: the browser
|
|
6962
|
+
* exposes the value to assistive tech with no extra ARIA, and the name comes
|
|
6963
|
+
* from the visible label through aria-labelledby (Thin: aria-label).
|
|
6964
|
+
*
|
|
6965
|
+
* Three types, one block:
|
|
6966
|
+
* .al-progress Label - label + percentage over an 8px bar
|
|
6967
|
+
* .al-progress--steps Steps - "N of total" in the meta ink
|
|
6968
|
+
* .al-progress--thin Thin - a 4px bar alone, no header
|
|
6969
|
+
*
|
|
6970
|
+
* The bar is never the only carrier of progress (usage rule 22): that is what
|
|
6971
|
+
* pays the declared fill-on-track exception. No focus, no aria-live - the end
|
|
6972
|
+
* of the task is announced by a Toast or an Alert, not by the bar.
|
|
6973
|
+
*
|
|
6974
|
+
* <progress> needs vendor pseudo-elements: WebKit/Blink draw the track in
|
|
6975
|
+
* ::-webkit-progress-bar and the fill in ::-webkit-progress-value; Firefox
|
|
6976
|
+
* paints the track on the element and the fill in ::-moz-progress-bar.
|
|
6977
|
+
*/
|
|
6978
|
+
|
|
6979
|
+
.al-progress {
|
|
6980
|
+
display: flex;
|
|
6981
|
+
flex-direction: column;
|
|
6982
|
+
gap: var(--al-progress-gap);
|
|
6983
|
+
inline-size: 100%;
|
|
6984
|
+
font-family: var(--al-font-sans);
|
|
6985
|
+
font-size: var(--al-progress-font-size);
|
|
6986
|
+
line-height: var(--al-progress-line-height);
|
|
6987
|
+
font-weight: var(--al-progress-font-weight);
|
|
6988
|
+
}
|
|
6989
|
+
|
|
6990
|
+
.al-progress__header {
|
|
6991
|
+
display: flex;
|
|
6992
|
+
justify-content: space-between;
|
|
6993
|
+
gap: var(--al-progress-gap);
|
|
6994
|
+
}
|
|
6995
|
+
|
|
6996
|
+
.al-progress__label {
|
|
6997
|
+
color: var(--al-progress-label-text);
|
|
6998
|
+
}
|
|
6999
|
+
|
|
7000
|
+
/* percentage; tabular figures keep it from jittering as it counts up */
|
|
7001
|
+
.al-progress__value {
|
|
7002
|
+
flex: none;
|
|
7003
|
+
color: var(--al-progress-meta-text);
|
|
7004
|
+
font-variant-numeric: tabular-nums;
|
|
7005
|
+
}
|
|
7006
|
+
|
|
7007
|
+
.al-progress--steps .al-progress__label {
|
|
7008
|
+
color: var(--al-progress-meta-text);
|
|
7009
|
+
}
|
|
7010
|
+
|
|
7011
|
+
/* ----------------------------------------------------------------- bar */
|
|
7012
|
+
.al-progress__bar {
|
|
7013
|
+
-webkit-appearance: none;
|
|
7014
|
+
appearance: none;
|
|
7015
|
+
display: block;
|
|
7016
|
+
inline-size: 100%;
|
|
7017
|
+
block-size: var(--al-progress-height);
|
|
7018
|
+
border: none;
|
|
7019
|
+
border-radius: var(--al-progress-radius);
|
|
7020
|
+
overflow: hidden;
|
|
7021
|
+
background-color: var(--al-progress-track-bg);
|
|
7022
|
+
color: var(--al-progress-fill-bg);
|
|
7023
|
+
}
|
|
7024
|
+
|
|
7025
|
+
.al-progress--thin .al-progress__bar {
|
|
7026
|
+
block-size: var(--al-progress-height-thin);
|
|
7027
|
+
}
|
|
7028
|
+
|
|
7029
|
+
.al-progress__bar::-webkit-progress-bar {
|
|
7030
|
+
background-color: var(--al-progress-track-bg);
|
|
7031
|
+
border-radius: var(--al-progress-radius);
|
|
7032
|
+
}
|
|
7033
|
+
|
|
7034
|
+
/* the width change is the only motion: no shimmer, no loop (rule 23) */
|
|
7035
|
+
.al-progress__bar::-webkit-progress-value {
|
|
7036
|
+
background-color: var(--al-progress-fill-bg);
|
|
7037
|
+
border-radius: var(--al-progress-radius);
|
|
7038
|
+
transition: inline-size var(--al-motion-duration-feedback) var(--al-motion-easing-enter);
|
|
7039
|
+
}
|
|
7040
|
+
|
|
7041
|
+
.al-progress__bar::-moz-progress-bar {
|
|
7042
|
+
background-color: var(--al-progress-fill-bg);
|
|
7043
|
+
border-radius: var(--al-progress-radius);
|
|
7044
|
+
}
|
|
7045
|
+
|
|
7046
|
+
@media (prefers-reduced-motion: reduce) {
|
|
7047
|
+
.al-progress__bar::-webkit-progress-value { transition: none; }
|
|
7048
|
+
}
|
|
7049
|
+
|
|
7050
|
+
/* AL Design System - Progress tokens
|
|
7051
|
+
* GENERATED by src/components/pagination/tokens.py. Do not edit by hand.
|
|
7052
|
+
*
|
|
7053
|
+
* Every color is a semantic the theme switches on :root.
|
|
7054
|
+
*/
|
|
7055
|
+
|
|
7056
|
+
:root {
|
|
7057
|
+
/* color */
|
|
7058
|
+
--al-pagination-item-label: var(--al-text-primary);
|
|
7059
|
+
--al-pagination-item-bg-hover: var(--al-bg-hover);
|
|
7060
|
+
--al-pagination-item-bg-active: var(--al-bg-active);
|
|
7061
|
+
--al-pagination-ellipsis: var(--al-text-secondary);
|
|
7062
|
+
--al-pagination-current-bg: var(--al-bg-brand-subtle);
|
|
7063
|
+
--al-pagination-current-label: var(--al-text-brand);
|
|
7064
|
+
--al-pagination-current-bg-hover: var(--al-bg-brand-hover);
|
|
7065
|
+
--al-pagination-current-bg-active: var(--al-bg-brand-active);
|
|
7066
|
+
--al-pagination-current-label-hover: var(--al-text-on-brand);
|
|
7067
|
+
--al-pagination-range-text: var(--al-text-secondary);
|
|
7068
|
+
|
|
7069
|
+
/* geometry */
|
|
7070
|
+
--al-pagination-item-padding: var(--al-space-8);
|
|
7071
|
+
--al-pagination-item-radius: var(--al-radius-full);
|
|
7072
|
+
--al-pagination-gap: var(--al-space-4);
|
|
7073
|
+
--al-pagination-range-gap: var(--al-space-16);
|
|
7074
|
+
--al-pagination-rows-gap: var(--al-space-8);
|
|
7075
|
+
|
|
7076
|
+
/* type - page numbers like the Button sm, range like body-sm */
|
|
7077
|
+
--al-pagination-font-size: var(--al-font-size-sm);
|
|
7078
|
+
--al-pagination-line-height: var(--al-line-height-sm);
|
|
7079
|
+
--al-pagination-font-weight: var(--al-font-weight-medium);
|
|
7080
|
+
--al-pagination-range-font-weight: var(--al-font-weight-regular);
|
|
7081
|
+
}
|
|
7082
|
+
|
|
7083
|
+
/* AL Design System - Pagination
|
|
7084
|
+
*
|
|
7085
|
+
* Four types, one block. Previous, Next and Load more are Buttons (Ghost sm,
|
|
7086
|
+
* Secondary sm) and rows per page is the Select: this file only lays them out
|
|
7087
|
+
* and draws what is the Pagination's own - the page items and the range text.
|
|
7088
|
+
*
|
|
7089
|
+
* .al-pagination Numbered - previous, pages, next
|
|
7090
|
+
* .al-pagination--simple Simple - previous and next only
|
|
7091
|
+
* .al-pagination--load-more Load more - one Secondary Button
|
|
7092
|
+
* .al-pagination--range Range - "Showing 41-60 of 312" + rows
|
|
7093
|
+
*
|
|
7094
|
+
* Markup (usage rules 20-22): a <nav aria-label="Pagination"> with the pages
|
|
7095
|
+
* in a <ul>. A page is an <a> when it changes the URL and a <button> when it
|
|
7096
|
+
* swaps content in place. The current page carries aria-current="page" - that
|
|
7097
|
+
* is what styles it, so the look can never disagree with what is announced.
|
|
7098
|
+
* The ellipsis is aria-hidden: it is not a control (rule 10).
|
|
7099
|
+
*
|
|
7100
|
+
* Disabled previous/next is the Button's own disabled state (rule 16), not a
|
|
7101
|
+
* Pagination style.
|
|
7102
|
+
*
|
|
7103
|
+
* NEVER ON SURFACE-RAISED (rule 8): the hovers use bg-hover/bg-active, which
|
|
7104
|
+
* vanish on the raised surface.
|
|
7105
|
+
*
|
|
7106
|
+
* NO HEIGHT: 36 = padding 8 + line 20 + padding 8. min-inline-size uses the
|
|
7107
|
+
* same sum so a one-digit page stays a circle and "16" grows into a pill.
|
|
7108
|
+
*/
|
|
7109
|
+
|
|
7110
|
+
/* ONE LINE (decided with Gui on 2026-10-21): wrapping split Previous, the
|
|
7111
|
+
pages and Next into three rows. The row never wraps; when it does not fit,
|
|
7112
|
+
the CONTAINER scrolls sideways (overflow-x: auto, with room for the focus
|
|
7113
|
+
ring). Range is the exception: text and rows may wrap. */
|
|
7114
|
+
.al-pagination {
|
|
7115
|
+
display: flex;
|
|
7116
|
+
flex-wrap: nowrap;
|
|
7117
|
+
align-items: center;
|
|
7118
|
+
gap: var(--al-pagination-gap);
|
|
7119
|
+
inline-size: max-content;
|
|
7120
|
+
}
|
|
7121
|
+
|
|
7122
|
+
.al-pagination--range {
|
|
7123
|
+
flex-wrap: wrap;
|
|
7124
|
+
inline-size: auto;
|
|
7125
|
+
}
|
|
7126
|
+
|
|
7127
|
+
.al-pagination__pages {
|
|
7128
|
+
display: flex;
|
|
7129
|
+
align-items: center;
|
|
7130
|
+
gap: var(--al-pagination-gap);
|
|
7131
|
+
margin: 0;
|
|
7132
|
+
padding: 0;
|
|
7133
|
+
list-style: none;
|
|
7134
|
+
}
|
|
7135
|
+
|
|
7136
|
+
/* ------------------------------------------------------------- page item */
|
|
7137
|
+
.al-pagination__item {
|
|
7138
|
+
display: inline-flex;
|
|
7139
|
+
align-items: center;
|
|
7140
|
+
justify-content: center;
|
|
7141
|
+
box-sizing: border-box;
|
|
7142
|
+
min-inline-size: calc(var(--al-pagination-item-padding) * 2 + var(--al-pagination-line-height));
|
|
7143
|
+
margin: 0;
|
|
7144
|
+
padding: var(--al-pagination-item-padding);
|
|
7145
|
+
border: 0;
|
|
7146
|
+
border-radius: var(--al-pagination-item-radius);
|
|
7147
|
+
background-color: transparent;
|
|
7148
|
+
font-family: var(--al-font-sans);
|
|
7149
|
+
font-size: var(--al-pagination-font-size);
|
|
7150
|
+
line-height: var(--al-pagination-line-height);
|
|
7151
|
+
font-weight: var(--al-pagination-font-weight);
|
|
7152
|
+
font-variant-numeric: tabular-nums;
|
|
7153
|
+
color: var(--al-pagination-item-label);
|
|
7154
|
+
text-decoration: none;
|
|
7155
|
+
cursor: pointer;
|
|
7156
|
+
-webkit-tap-highlight-color: transparent;
|
|
7157
|
+
transition: background-color var(--al-motion-duration-feedback) var(--al-motion-easing-exit), color var(--al-motion-duration-feedback) var(--al-motion-easing-exit), box-shadow var(--al-motion-duration-feedback) var(--al-motion-easing-exit);
|
|
7158
|
+
}
|
|
7159
|
+
|
|
7160
|
+
.al-pagination__item:hover {
|
|
7161
|
+
background-color: var(--al-pagination-item-bg-hover);
|
|
7162
|
+
}
|
|
7163
|
+
|
|
7164
|
+
.al-pagination__item:active {
|
|
7165
|
+
background-color: var(--al-pagination-item-bg-active);
|
|
7166
|
+
}
|
|
7167
|
+
|
|
7168
|
+
/* focus is rest plus the ring, keyboard only */
|
|
7169
|
+
.al-pagination__item:focus-visible {
|
|
7170
|
+
outline: none;
|
|
7171
|
+
box-shadow: var(--al-focus-ring-default);
|
|
7172
|
+
}
|
|
7173
|
+
|
|
7174
|
+
/* current: tonal at rest and focus, brand on hover and pressed (rule 19) */
|
|
7175
|
+
.al-pagination__item[aria-current="page"] {
|
|
7176
|
+
background-color: var(--al-pagination-current-bg);
|
|
7177
|
+
color: var(--al-pagination-current-label);
|
|
7178
|
+
}
|
|
7179
|
+
|
|
7180
|
+
.al-pagination__item[aria-current="page"]:hover {
|
|
7181
|
+
background-color: var(--al-pagination-current-bg-hover);
|
|
7182
|
+
color: var(--al-pagination-current-label-hover);
|
|
7183
|
+
}
|
|
7184
|
+
|
|
7185
|
+
.al-pagination__item[aria-current="page"]:active {
|
|
7186
|
+
background-color: var(--al-pagination-current-bg-active);
|
|
7187
|
+
color: var(--al-pagination-current-label-hover);
|
|
7188
|
+
}
|
|
7189
|
+
|
|
7190
|
+
/* ENTER - destination states take the enter curve, as in the Tab */
|
|
7191
|
+
.al-pagination__item:hover,
|
|
7192
|
+
.al-pagination__item:active,
|
|
7193
|
+
.al-pagination__item:focus-visible {
|
|
7194
|
+
transition-timing-function: var(--al-motion-easing-enter);
|
|
7195
|
+
}
|
|
7196
|
+
|
|
7197
|
+
/* ------------------------------------------------------------- ellipsis */
|
|
7198
|
+
.al-pagination__ellipsis {
|
|
7199
|
+
display: inline-flex;
|
|
7200
|
+
align-items: center;
|
|
7201
|
+
justify-content: center;
|
|
7202
|
+
min-inline-size: calc(var(--al-pagination-item-padding) * 2 + var(--al-pagination-line-height));
|
|
7203
|
+
padding: var(--al-pagination-item-padding);
|
|
7204
|
+
box-sizing: border-box;
|
|
7205
|
+
color: var(--al-pagination-ellipsis);
|
|
7206
|
+
}
|
|
7207
|
+
|
|
7208
|
+
/* ---------------------------------------------------------------- range */
|
|
7209
|
+
.al-pagination--range {
|
|
7210
|
+
gap: var(--al-pagination-range-gap);
|
|
7211
|
+
}
|
|
7212
|
+
|
|
7213
|
+
.al-pagination__range,
|
|
7214
|
+
.al-pagination__rows-label {
|
|
7215
|
+
margin: 0;
|
|
7216
|
+
font-family: var(--al-font-sans);
|
|
7217
|
+
font-size: var(--al-pagination-font-size);
|
|
7218
|
+
line-height: var(--al-pagination-line-height);
|
|
7219
|
+
font-weight: var(--al-pagination-range-font-weight);
|
|
7220
|
+
font-variant-numeric: tabular-nums;
|
|
7221
|
+
color: var(--al-pagination-range-text);
|
|
7222
|
+
}
|
|
7223
|
+
|
|
7224
|
+
.al-pagination__rows {
|
|
7225
|
+
display: flex;
|
|
7226
|
+
align-items: center;
|
|
7227
|
+
gap: var(--al-pagination-rows-gap);
|
|
7228
|
+
}
|
|
7229
|
+
|
|
7230
|
+
@media (prefers-reduced-motion: reduce) {
|
|
7231
|
+
.al-pagination__item {
|
|
7232
|
+
transition: none;
|
|
7233
|
+
}
|
|
7234
|
+
}
|
|
7235
|
+
|
|
7236
|
+
@media (forced-colors: active) {
|
|
7237
|
+
.al-pagination__item[aria-current="page"] {
|
|
7238
|
+
outline: var(--al-border-width-1) solid CanvasText;
|
|
7239
|
+
}
|
|
7240
|
+
|
|
7241
|
+
.al-pagination__item:focus-visible {
|
|
7242
|
+
outline: var(--al-border-width-focus) solid Highlight;
|
|
7243
|
+
outline-offset: var(--al-border-focus-offset);
|
|
7244
|
+
}
|
|
7245
|
+
}
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
/* AL Design System - Progress tokens
|
|
2
|
+
* GENERATED by src/components/pagination/tokens.py. Do not edit by hand.
|
|
3
|
+
*
|
|
4
|
+
* Every color is a semantic the theme switches on :root.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
:root {
|
|
8
|
+
/* color */
|
|
9
|
+
--al-pagination-item-label: var(--al-text-primary);
|
|
10
|
+
--al-pagination-item-bg-hover: var(--al-bg-hover);
|
|
11
|
+
--al-pagination-item-bg-active: var(--al-bg-active);
|
|
12
|
+
--al-pagination-ellipsis: var(--al-text-secondary);
|
|
13
|
+
--al-pagination-current-bg: var(--al-bg-brand-subtle);
|
|
14
|
+
--al-pagination-current-label: var(--al-text-brand);
|
|
15
|
+
--al-pagination-current-bg-hover: var(--al-bg-brand-hover);
|
|
16
|
+
--al-pagination-current-bg-active: var(--al-bg-brand-active);
|
|
17
|
+
--al-pagination-current-label-hover: var(--al-text-on-brand);
|
|
18
|
+
--al-pagination-range-text: var(--al-text-secondary);
|
|
19
|
+
|
|
20
|
+
/* geometry */
|
|
21
|
+
--al-pagination-item-padding: var(--al-space-8);
|
|
22
|
+
--al-pagination-item-radius: var(--al-radius-full);
|
|
23
|
+
--al-pagination-gap: var(--al-space-4);
|
|
24
|
+
--al-pagination-range-gap: var(--al-space-16);
|
|
25
|
+
--al-pagination-rows-gap: var(--al-space-8);
|
|
26
|
+
|
|
27
|
+
/* type - page numbers like the Button sm, range like body-sm */
|
|
28
|
+
--al-pagination-font-size: var(--al-font-size-sm);
|
|
29
|
+
--al-pagination-line-height: var(--al-line-height-sm);
|
|
30
|
+
--al-pagination-font-weight: var(--al-font-weight-medium);
|
|
31
|
+
--al-pagination-range-font-weight: var(--al-font-weight-regular);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/* AL Design System - Pagination
|
|
35
|
+
*
|
|
36
|
+
* Four types, one block. Previous, Next and Load more are Buttons (Ghost sm,
|
|
37
|
+
* Secondary sm) and rows per page is the Select: this file only lays them out
|
|
38
|
+
* and draws what is the Pagination's own - the page items and the range text.
|
|
39
|
+
*
|
|
40
|
+
* .al-pagination Numbered - previous, pages, next
|
|
41
|
+
* .al-pagination--simple Simple - previous and next only
|
|
42
|
+
* .al-pagination--load-more Load more - one Secondary Button
|
|
43
|
+
* .al-pagination--range Range - "Showing 41-60 of 312" + rows
|
|
44
|
+
*
|
|
45
|
+
* Markup (usage rules 20-22): a <nav aria-label="Pagination"> with the pages
|
|
46
|
+
* in a <ul>. A page is an <a> when it changes the URL and a <button> when it
|
|
47
|
+
* swaps content in place. The current page carries aria-current="page" - that
|
|
48
|
+
* is what styles it, so the look can never disagree with what is announced.
|
|
49
|
+
* The ellipsis is aria-hidden: it is not a control (rule 10).
|
|
50
|
+
*
|
|
51
|
+
* Disabled previous/next is the Button's own disabled state (rule 16), not a
|
|
52
|
+
* Pagination style.
|
|
53
|
+
*
|
|
54
|
+
* NEVER ON SURFACE-RAISED (rule 8): the hovers use bg-hover/bg-active, which
|
|
55
|
+
* vanish on the raised surface.
|
|
56
|
+
*
|
|
57
|
+
* NO HEIGHT: 36 = padding 8 + line 20 + padding 8. min-inline-size uses the
|
|
58
|
+
* same sum so a one-digit page stays a circle and "16" grows into a pill.
|
|
59
|
+
*/
|
|
60
|
+
|
|
61
|
+
/* ONE LINE (decided with Gui on 2026-10-21): wrapping split Previous, the
|
|
62
|
+
pages and Next into three rows. The row never wraps; when it does not fit,
|
|
63
|
+
the CONTAINER scrolls sideways (overflow-x: auto, with room for the focus
|
|
64
|
+
ring). Range is the exception: text and rows may wrap. */
|
|
65
|
+
.al-pagination {
|
|
66
|
+
display: flex;
|
|
67
|
+
flex-wrap: nowrap;
|
|
68
|
+
align-items: center;
|
|
69
|
+
gap: var(--al-pagination-gap);
|
|
70
|
+
inline-size: max-content;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.al-pagination--range {
|
|
74
|
+
flex-wrap: wrap;
|
|
75
|
+
inline-size: auto;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.al-pagination__pages {
|
|
79
|
+
display: flex;
|
|
80
|
+
align-items: center;
|
|
81
|
+
gap: var(--al-pagination-gap);
|
|
82
|
+
margin: 0;
|
|
83
|
+
padding: 0;
|
|
84
|
+
list-style: none;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/* ------------------------------------------------------------- page item */
|
|
88
|
+
.al-pagination__item {
|
|
89
|
+
display: inline-flex;
|
|
90
|
+
align-items: center;
|
|
91
|
+
justify-content: center;
|
|
92
|
+
box-sizing: border-box;
|
|
93
|
+
min-inline-size: calc(var(--al-pagination-item-padding) * 2 + var(--al-pagination-line-height));
|
|
94
|
+
margin: 0;
|
|
95
|
+
padding: var(--al-pagination-item-padding);
|
|
96
|
+
border: 0;
|
|
97
|
+
border-radius: var(--al-pagination-item-radius);
|
|
98
|
+
background-color: transparent;
|
|
99
|
+
font-family: var(--al-font-sans);
|
|
100
|
+
font-size: var(--al-pagination-font-size);
|
|
101
|
+
line-height: var(--al-pagination-line-height);
|
|
102
|
+
font-weight: var(--al-pagination-font-weight);
|
|
103
|
+
font-variant-numeric: tabular-nums;
|
|
104
|
+
color: var(--al-pagination-item-label);
|
|
105
|
+
text-decoration: none;
|
|
106
|
+
cursor: pointer;
|
|
107
|
+
-webkit-tap-highlight-color: transparent;
|
|
108
|
+
transition: background-color var(--al-motion-duration-feedback) var(--al-motion-easing-exit), color var(--al-motion-duration-feedback) var(--al-motion-easing-exit), box-shadow var(--al-motion-duration-feedback) var(--al-motion-easing-exit);
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.al-pagination__item:hover {
|
|
112
|
+
background-color: var(--al-pagination-item-bg-hover);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.al-pagination__item:active {
|
|
116
|
+
background-color: var(--al-pagination-item-bg-active);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/* focus is rest plus the ring, keyboard only */
|
|
120
|
+
.al-pagination__item:focus-visible {
|
|
121
|
+
outline: none;
|
|
122
|
+
box-shadow: var(--al-focus-ring-default);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
/* current: tonal at rest and focus, brand on hover and pressed (rule 19) */
|
|
126
|
+
.al-pagination__item[aria-current="page"] {
|
|
127
|
+
background-color: var(--al-pagination-current-bg);
|
|
128
|
+
color: var(--al-pagination-current-label);
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.al-pagination__item[aria-current="page"]:hover {
|
|
132
|
+
background-color: var(--al-pagination-current-bg-hover);
|
|
133
|
+
color: var(--al-pagination-current-label-hover);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.al-pagination__item[aria-current="page"]:active {
|
|
137
|
+
background-color: var(--al-pagination-current-bg-active);
|
|
138
|
+
color: var(--al-pagination-current-label-hover);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
/* ENTER - destination states take the enter curve, as in the Tab */
|
|
142
|
+
.al-pagination__item:hover,
|
|
143
|
+
.al-pagination__item:active,
|
|
144
|
+
.al-pagination__item:focus-visible {
|
|
145
|
+
transition-timing-function: var(--al-motion-easing-enter);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
/* ------------------------------------------------------------- ellipsis */
|
|
149
|
+
.al-pagination__ellipsis {
|
|
150
|
+
display: inline-flex;
|
|
151
|
+
align-items: center;
|
|
152
|
+
justify-content: center;
|
|
153
|
+
min-inline-size: calc(var(--al-pagination-item-padding) * 2 + var(--al-pagination-line-height));
|
|
154
|
+
padding: var(--al-pagination-item-padding);
|
|
155
|
+
box-sizing: border-box;
|
|
156
|
+
color: var(--al-pagination-ellipsis);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
/* ---------------------------------------------------------------- range */
|
|
160
|
+
.al-pagination--range {
|
|
161
|
+
gap: var(--al-pagination-range-gap);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.al-pagination__range,
|
|
165
|
+
.al-pagination__rows-label {
|
|
166
|
+
margin: 0;
|
|
167
|
+
font-family: var(--al-font-sans);
|
|
168
|
+
font-size: var(--al-pagination-font-size);
|
|
169
|
+
line-height: var(--al-pagination-line-height);
|
|
170
|
+
font-weight: var(--al-pagination-range-font-weight);
|
|
171
|
+
font-variant-numeric: tabular-nums;
|
|
172
|
+
color: var(--al-pagination-range-text);
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.al-pagination__rows {
|
|
176
|
+
display: flex;
|
|
177
|
+
align-items: center;
|
|
178
|
+
gap: var(--al-pagination-rows-gap);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
@media (prefers-reduced-motion: reduce) {
|
|
182
|
+
.al-pagination__item {
|
|
183
|
+
transition: none;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
@media (forced-colors: active) {
|
|
188
|
+
.al-pagination__item[aria-current="page"] {
|
|
189
|
+
outline: var(--al-border-width-1) solid CanvasText;
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
.al-pagination__item:focus-visible {
|
|
193
|
+
outline: var(--al-border-width-focus) solid Highlight;
|
|
194
|
+
outline-offset: var(--al-border-focus-offset);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
/* AL Design System - Progress tokens
|
|
2
|
+
* GENERATED by src/components/progress/tokens.py. Do not edit by hand.
|
|
3
|
+
*
|
|
4
|
+
* Every color is a semantic the theme switches on :root.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
:root {
|
|
8
|
+
/* color */
|
|
9
|
+
--al-progress-track-bg: var(--al-bg-track);
|
|
10
|
+
--al-progress-fill-bg: var(--al-bg-brand);
|
|
11
|
+
--al-progress-label-text: var(--al-text-primary);
|
|
12
|
+
--al-progress-meta-text: var(--al-text-secondary);
|
|
13
|
+
|
|
14
|
+
/* geometry */
|
|
15
|
+
--al-progress-radius: var(--al-radius-full);
|
|
16
|
+
--al-progress-height: var(--al-space-8);
|
|
17
|
+
--al-progress-height-thin: var(--al-space-4);
|
|
18
|
+
--al-progress-gap: var(--al-space-8);
|
|
19
|
+
|
|
20
|
+
/* type - label and meta share one style */
|
|
21
|
+
--al-progress-font-size: var(--al-font-size-sm);
|
|
22
|
+
--al-progress-line-height: var(--al-line-height-sm);
|
|
23
|
+
--al-progress-font-weight: var(--al-font-weight-regular);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/* AL Design System - Progress
|
|
27
|
+
*
|
|
28
|
+
* Determinate only. The bar is a native <progress value max>: the browser
|
|
29
|
+
* exposes the value to assistive tech with no extra ARIA, and the name comes
|
|
30
|
+
* from the visible label through aria-labelledby (Thin: aria-label).
|
|
31
|
+
*
|
|
32
|
+
* Three types, one block:
|
|
33
|
+
* .al-progress Label - label + percentage over an 8px bar
|
|
34
|
+
* .al-progress--steps Steps - "N of total" in the meta ink
|
|
35
|
+
* .al-progress--thin Thin - a 4px bar alone, no header
|
|
36
|
+
*
|
|
37
|
+
* The bar is never the only carrier of progress (usage rule 22): that is what
|
|
38
|
+
* pays the declared fill-on-track exception. No focus, no aria-live - the end
|
|
39
|
+
* of the task is announced by a Toast or an Alert, not by the bar.
|
|
40
|
+
*
|
|
41
|
+
* <progress> needs vendor pseudo-elements: WebKit/Blink draw the track in
|
|
42
|
+
* ::-webkit-progress-bar and the fill in ::-webkit-progress-value; Firefox
|
|
43
|
+
* paints the track on the element and the fill in ::-moz-progress-bar.
|
|
44
|
+
*/
|
|
45
|
+
|
|
46
|
+
.al-progress {
|
|
47
|
+
display: flex;
|
|
48
|
+
flex-direction: column;
|
|
49
|
+
gap: var(--al-progress-gap);
|
|
50
|
+
inline-size: 100%;
|
|
51
|
+
font-family: var(--al-font-sans);
|
|
52
|
+
font-size: var(--al-progress-font-size);
|
|
53
|
+
line-height: var(--al-progress-line-height);
|
|
54
|
+
font-weight: var(--al-progress-font-weight);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.al-progress__header {
|
|
58
|
+
display: flex;
|
|
59
|
+
justify-content: space-between;
|
|
60
|
+
gap: var(--al-progress-gap);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.al-progress__label {
|
|
64
|
+
color: var(--al-progress-label-text);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/* percentage; tabular figures keep it from jittering as it counts up */
|
|
68
|
+
.al-progress__value {
|
|
69
|
+
flex: none;
|
|
70
|
+
color: var(--al-progress-meta-text);
|
|
71
|
+
font-variant-numeric: tabular-nums;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.al-progress--steps .al-progress__label {
|
|
75
|
+
color: var(--al-progress-meta-text);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
/* ----------------------------------------------------------------- bar */
|
|
79
|
+
.al-progress__bar {
|
|
80
|
+
-webkit-appearance: none;
|
|
81
|
+
appearance: none;
|
|
82
|
+
display: block;
|
|
83
|
+
inline-size: 100%;
|
|
84
|
+
block-size: var(--al-progress-height);
|
|
85
|
+
border: none;
|
|
86
|
+
border-radius: var(--al-progress-radius);
|
|
87
|
+
overflow: hidden;
|
|
88
|
+
background-color: var(--al-progress-track-bg);
|
|
89
|
+
color: var(--al-progress-fill-bg);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.al-progress--thin .al-progress__bar {
|
|
93
|
+
block-size: var(--al-progress-height-thin);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.al-progress__bar::-webkit-progress-bar {
|
|
97
|
+
background-color: var(--al-progress-track-bg);
|
|
98
|
+
border-radius: var(--al-progress-radius);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/* the width change is the only motion: no shimmer, no loop (rule 23) */
|
|
102
|
+
.al-progress__bar::-webkit-progress-value {
|
|
103
|
+
background-color: var(--al-progress-fill-bg);
|
|
104
|
+
border-radius: var(--al-progress-radius);
|
|
105
|
+
transition: inline-size var(--al-motion-duration-feedback) var(--al-motion-easing-enter);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.al-progress__bar::-moz-progress-bar {
|
|
109
|
+
background-color: var(--al-progress-fill-bg);
|
|
110
|
+
border-radius: var(--al-progress-radius);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
@media (prefers-reduced-motion: reduce) {
|
|
114
|
+
.al-progress__bar::-webkit-progress-value { transition: none; }
|
|
115
|
+
}
|
package/dist/foundation.css
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* AL Design System - Foundation
|
|
2
|
-
* v1.
|
|
2
|
+
* v1.3.0 - MIT
|
|
3
3
|
* GENERATED by src/foundation/css.py. Do not edit by hand: run the script.
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -87,6 +87,7 @@
|
|
|
87
87
|
--al-bg-active-raised: #E0E0E0;
|
|
88
88
|
--al-bg-thumb: #B3B3B3;
|
|
89
89
|
--al-bg-thumb-disabled: #CECECE;
|
|
90
|
+
--al-bg-track: #E0E0E0;
|
|
90
91
|
--al-bg-scrim: #1818188F;
|
|
91
92
|
--al-bg-brand: #FC5000;
|
|
92
93
|
--al-bg-brand-hover: #C53900;
|
|
@@ -244,6 +245,7 @@
|
|
|
244
245
|
--al-bg-active-raised: #717171;
|
|
245
246
|
--al-bg-thumb: #717171;
|
|
246
247
|
--al-bg-thumb-disabled: #565656;
|
|
248
|
+
--al-bg-track: #565656;
|
|
247
249
|
--al-bg-scrim: #000000A3;
|
|
248
250
|
--al-bg-brand: #FC5000;
|
|
249
251
|
--al-bg-brand-hover: #EA4900;
|
|
@@ -309,6 +311,7 @@
|
|
|
309
311
|
--al-bg-active-raised: #717171;
|
|
310
312
|
--al-bg-thumb: #717171;
|
|
311
313
|
--al-bg-thumb-disabled: #565656;
|
|
314
|
+
--al-bg-track: #565656;
|
|
312
315
|
--al-bg-scrim: #000000A3;
|
|
313
316
|
--al-bg-brand: #FC5000;
|
|
314
317
|
--al-bg-brand-hover: #EA4900;
|
package/dist/tokens.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"meta": {
|
|
3
3
|
"name": "AL Design System",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.3.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"brandAnchor": "#FC5000",
|
|
7
7
|
"colorSpace": "OKLCH",
|
|
@@ -151,6 +151,10 @@
|
|
|
151
151
|
"#CECECE",
|
|
152
152
|
"#565656"
|
|
153
153
|
],
|
|
154
|
+
"bg-track": [
|
|
155
|
+
"#E0E0E0",
|
|
156
|
+
"#565656"
|
|
157
|
+
],
|
|
154
158
|
"bg-scrim": [
|
|
155
159
|
"#1818188F",
|
|
156
160
|
"#000000A3"
|