@kommon-lab/tokens 0.1.5 → 0.1.7
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 +28 -0
- package/dist/css/beebs.css +7 -0
- package/dist/css/ekstract.css +22 -0
- package/dist/fonts/ekstract/LttRecoleta-Bold.woff2 +0 -0
- package/dist/fonts/ekstract/LttRecoleta-Medium.woff2 +0 -0
- package/dist/fonts/ekstract/LttRecoleta-SemiBold.woff2 +0 -0
- package/docs/tokens-guidelines.md +73 -0
- package/fonts/ekstract/LttRecoleta-Bold.woff2 +0 -0
- package/fonts/ekstract/LttRecoleta-Medium.woff2 +0 -0
- package/fonts/ekstract/LttRecoleta-SemiBold.woff2 +0 -0
- package/package.json +4 -2
package/README.md
CHANGED
|
@@ -116,6 +116,34 @@ var(--font-body-m-bold-font-weight)
|
|
|
116
116
|
> **Responsive:** `display` and `title` tokens are defined mobile-first and automatically
|
|
117
117
|
> override at `min-width: 768px`. No extra configuration needed.
|
|
118
118
|
|
|
119
|
+
## Custom fonts
|
|
120
|
+
|
|
121
|
+
Most brands use **Figtree** (Google Fonts) — no setup needed.
|
|
122
|
+
|
|
123
|
+
**Ekstract** uses a custom font (`Ltt Recoleta`) bundled directly in this package. The `@font-face` declarations are injected automatically into `dist/css/ekstract.css` — just import the CSS and it works.
|
|
124
|
+
|
|
125
|
+
**Beebs** uses `Really Sans Small` (font files not yet available). Figtree is used as a placeholder in the meantime.
|
|
126
|
+
|
|
127
|
+
See `docs/tokens-guidelines.md` for details.
|
|
128
|
+
|
|
129
|
+
## For AI tools & LLMs
|
|
130
|
+
|
|
131
|
+
This package is designed to work with AI coding assistants.
|
|
132
|
+
The file `docs/tokens-guidelines.md` included in this package describes token usage rules and semantic intent.
|
|
133
|
+
|
|
134
|
+
**Key rules:**
|
|
135
|
+
|
|
136
|
+
- `color.bg.*` → backgrounds (`base` = default, `alternate` = subtle, `brand` = brand color)
|
|
137
|
+
- `color.fg.*` → text and icons (`neutral` = default, `subtle` = secondary, `brand` = brand color, `inverse` = on dark backgrounds)
|
|
138
|
+
- `font.body.*` → all content text (paragraphs, descriptions, UI labels)
|
|
139
|
+
- `font.title.*` / `font.display.*` → headings only — automatically responsive at 768px, no extra setup needed
|
|
140
|
+
- `font.link.*` → clickable links — always match the size to the surrounding `font.body.*`
|
|
141
|
+
- `space.*` → paddings and gaps (rem)
|
|
142
|
+
- `size.*` → component dimensions (rem)
|
|
143
|
+
- `border.radius.*` → rounded corners (rem) — `border.width.*` → border thickness (px)
|
|
144
|
+
|
|
145
|
+
**Never use primitive tokens directly** (e.g. `--kiabi-900`). Always use the public tokens listed above.
|
|
146
|
+
|
|
119
147
|
## Versioning
|
|
120
148
|
|
|
121
149
|
This package follows [Semantic Versioning](https://semver.org):
|
package/dist/css/beebs.css
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
/* Really Sans Small — PLACEHOLDER using Figtree until font files are provided */
|
|
2
|
+
@font-face {
|
|
3
|
+
font-family: 'Really Sans Small';
|
|
4
|
+
src: local('Figtree'), local('system-ui');
|
|
5
|
+
font-weight: 100 900;
|
|
6
|
+
font-style: normal;
|
|
7
|
+
}
|
|
1
8
|
/**
|
|
2
9
|
* Do not edit directly, this file was auto-generated.
|
|
3
10
|
*/
|
package/dist/css/ekstract.css
CHANGED
|
@@ -1,3 +1,25 @@
|
|
|
1
|
+
/* Ltt Recoleta — custom brand font for Ekstract */
|
|
2
|
+
@font-face {
|
|
3
|
+
font-family: 'Ltt Recoleta';
|
|
4
|
+
src: url('../fonts/ekstract/LttRecoleta-Medium.woff2') format('woff2');
|
|
5
|
+
font-weight: 500;
|
|
6
|
+
font-style: normal;
|
|
7
|
+
font-display: swap;
|
|
8
|
+
}
|
|
9
|
+
@font-face {
|
|
10
|
+
font-family: 'Ltt Recoleta';
|
|
11
|
+
src: url('../fonts/ekstract/LttRecoleta-SemiBold.woff2') format('woff2');
|
|
12
|
+
font-weight: 600;
|
|
13
|
+
font-style: normal;
|
|
14
|
+
font-display: swap;
|
|
15
|
+
}
|
|
16
|
+
@font-face {
|
|
17
|
+
font-family: 'Ltt Recoleta';
|
|
18
|
+
src: url('../fonts/ekstract/LttRecoleta-Bold.woff2') format('woff2');
|
|
19
|
+
font-weight: 700;
|
|
20
|
+
font-style: normal;
|
|
21
|
+
font-display: swap;
|
|
22
|
+
}
|
|
1
23
|
/**
|
|
2
24
|
* Do not edit directly, this file was auto-generated.
|
|
3
25
|
*/
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Token Guidelines
|
|
2
|
+
|
|
3
|
+
Règles d'usage des tokens Kommon pour les développeurs et les outils IA.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Typographie
|
|
8
|
+
|
|
9
|
+
### Display
|
|
10
|
+
|
|
11
|
+
| Token | Description |
|
|
12
|
+
|---|---|
|
|
13
|
+
| `font.display.l` | **Titre d'accroche de grande taille**, pour les heroes, tops de page ou ruptures éditoriales |
|
|
14
|
+
| `font.display.m` | **Titre d'accroche de taille moyenne**, pour les heroes, tops de page ou ruptures éditoriales |
|
|
15
|
+
|
|
16
|
+
### Title
|
|
17
|
+
|
|
18
|
+
| Token | Description |
|
|
19
|
+
|---|---|
|
|
20
|
+
| `font.title.l` | **Titre de page ou de section**, à hiérarchie visuelle forte |
|
|
21
|
+
| `font.title.m` | **Titre de page ou de section**, à hiérarchie visuelle moyenne |
|
|
22
|
+
| `font.title.s` | **Titre de page ou de section**, à hiérarchie visuelle réduite |
|
|
23
|
+
| `font.title.xs` | **Titre de page ou de section**, à hiérarchie visuelle minimale |
|
|
24
|
+
|
|
25
|
+
### Body
|
|
26
|
+
|
|
27
|
+
| Token | Description |
|
|
28
|
+
|---|---|
|
|
29
|
+
| `font.body.m` | **Taille par défaut** pour le texte d'interface et le contenu éditorial (paragraphes, descriptions, labels, etc.) |
|
|
30
|
+
| `font.body.m.bold` | Variante de `font.body.m` pour **créer de l'emphase** sur un mot ou une information clé |
|
|
31
|
+
| `font.body.s` | **Texte de taille réduite** pour les informations de support non essentielles, ou les éléments d'interface compacts |
|
|
32
|
+
| `font.body.s.bold` | Variante de `font.body.s` pour **créer de l'emphase** sur un mot ou une information clé |
|
|
33
|
+
| `font.body.xs` | **Texte de très petite taille**, réservé uniquement aux mentions légales |
|
|
34
|
+
| `font.body.xs.bold` | Variante de `font.body.xs` pour **créer de l'emphase** sur un mot ou une information clé |
|
|
35
|
+
|
|
36
|
+
### Link
|
|
37
|
+
|
|
38
|
+
| Token | Description |
|
|
39
|
+
|---|---|
|
|
40
|
+
| `font.link.m` | **Lien cliquable** intégré dans un texte `font.body.m` |
|
|
41
|
+
| `font.link.m.bold` | Variante de `font.link.m` pour créer davantage d'**emphase** sur le lien |
|
|
42
|
+
| `font.link.s` | **Lien cliquable** intégré dans un texte `font.body.s` |
|
|
43
|
+
| `font.link.s.bold` | Variante de `font.link.s` pour créer davantage d'**emphase** sur le lien |
|
|
44
|
+
| `font.link.xs` | **Lien cliquable** intégré dans un texte `font.body.xs` |
|
|
45
|
+
| `font.link.xs.bold` | Variante de `font.link.xs` pour créer davantage d'**emphase** sur le lien |
|
|
46
|
+
|
|
47
|
+
---
|
|
48
|
+
|
|
49
|
+
## Fonts personnalisées par brand
|
|
50
|
+
|
|
51
|
+
Toutes les brands utilisent **Figtree** (Google Fonts) pour les textes body et link.
|
|
52
|
+
Les fonts de titres (`font.display.*`, `font.title.*`) varient par brand.
|
|
53
|
+
|
|
54
|
+
| Brand | Font | Source | Statut |
|
|
55
|
+
|---|---|---|---|
|
|
56
|
+
| kiabi | Figtree | Google Fonts | ✅ |
|
|
57
|
+
| kitchoun | Figtree | Google Fonts | ✅ |
|
|
58
|
+
| kiabi-home | Figtree | Google Fonts | ✅ |
|
|
59
|
+
| ekstract | **Ltt Recoleta** | Fichiers woff2 embarqués dans le paquet (`fonts/ekstract/`) | ✅ |
|
|
60
|
+
| beebs | Really Sans Small | Fichiers woff2 à venir | ⏳ Figtree utilisée en placeholder |
|
|
61
|
+
|
|
62
|
+
### Ekstract — Ltt Recoleta
|
|
63
|
+
|
|
64
|
+
La font `Ltt Recoleta` est embarquée directement dans le paquet npm. Les `@font-face` sont injectés automatiquement dans `dist/css/ekstract.css` — aucune configuration supplémentaire nécessaire.
|
|
65
|
+
|
|
66
|
+
Les fichiers sont disponibles dans `fonts/ekstract/` si un usage direct est nécessaire :
|
|
67
|
+
- `LttRecoleta-Medium.woff2` — font-weight: 500
|
|
68
|
+
- `LttRecoleta-SemiBold.woff2` — font-weight: 600
|
|
69
|
+
- `LttRecoleta-Bold.woff2` — font-weight: 700
|
|
70
|
+
|
|
71
|
+
### Beebs — Really Sans Small ⏳
|
|
72
|
+
|
|
73
|
+
La font `Really Sans Small` n'est pas encore disponible. En attendant, un `@font-face` placeholder redirige vers Figtree. Dès réception des fichiers woff2, remplacer le placeholder dans `scripts/build-tokens.js` → `FONT_FACES.beebs`.
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kommon-lab/tokens",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.7",
|
|
4
4
|
"description": "Design tokens for Kommon Lab multi-brand design system",
|
|
5
5
|
"exports": {
|
|
6
6
|
"./css/*": "./dist/css/*",
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
},
|
|
9
9
|
"files": [
|
|
10
10
|
"dist/",
|
|
11
|
-
"tokens/"
|
|
11
|
+
"tokens/",
|
|
12
|
+
"fonts/",
|
|
13
|
+
"docs/tokens-guidelines.md"
|
|
12
14
|
],
|
|
13
15
|
"scripts": {
|
|
14
16
|
"transform": "node scripts/transform-tokens.js",
|