@digicreon/mucss 1.0.0 → 1.2.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.
Files changed (59) hide show
  1. package/README.md +60 -11
  2. package/dist/mu.amber.css +2 -2
  3. package/dist/mu.azure.css +2 -2
  4. package/dist/mu.blue.css +2 -2
  5. package/dist/mu.css +2 -2
  6. package/dist/mu.cyan.css +2 -2
  7. package/dist/mu.fuchsia.css +2 -2
  8. package/dist/mu.green.css +2 -2
  9. package/dist/mu.grey.css +2 -2
  10. package/dist/mu.indigo.css +2 -2
  11. package/dist/mu.jade.css +2 -2
  12. package/dist/mu.lime.css +2 -2
  13. package/dist/mu.orange.css +2 -2
  14. package/dist/mu.pink.css +2 -2
  15. package/dist/mu.pumpkin.css +2 -2
  16. package/dist/mu.purple.css +2 -2
  17. package/dist/mu.red.css +2 -2
  18. package/dist/mu.sand.css +2 -2
  19. package/dist/mu.slate.css +2 -2
  20. package/dist/mu.violet.css +2 -2
  21. package/dist/mu.yellow.css +2 -2
  22. package/dist/mu.zinc.css +2 -2
  23. package/documentation/mu.accordion.md +4 -2
  24. package/documentation/mu.alert.md +22 -14
  25. package/documentation/mu.badge.md +35 -15
  26. package/documentation/mu.breadcrumb.md +8 -6
  27. package/documentation/mu.button.md +39 -28
  28. package/documentation/mu.card.md +35 -19
  29. package/documentation/mu.checkbox-radio.md +4 -2
  30. package/documentation/mu.code.md +85 -0
  31. package/documentation/mu.colors.md +307 -0
  32. package/documentation/mu.container.md +87 -0
  33. package/documentation/mu.dark-mode.md +96 -0
  34. package/documentation/mu.dropdown.md +32 -27
  35. package/documentation/mu.embedded.md +101 -0
  36. package/documentation/mu.figure.md +82 -0
  37. package/documentation/mu.forms-advanced.md +6 -4
  38. package/documentation/mu.forms.md +11 -9
  39. package/documentation/mu.grid.md +7 -1
  40. package/documentation/mu.group.md +29 -27
  41. package/documentation/mu.hero.md +200 -0
  42. package/documentation/mu.link.md +108 -0
  43. package/documentation/mu.loading.md +4 -2
  44. package/documentation/mu.modal.md +9 -7
  45. package/documentation/mu.nav.md +191 -0
  46. package/documentation/mu.pagination.md +3 -1
  47. package/documentation/mu.progress.md +31 -14
  48. package/documentation/mu.range.md +4 -2
  49. package/documentation/mu.skeleton.md +111 -0
  50. package/documentation/mu.spinner.md +20 -12
  51. package/documentation/mu.switch.md +4 -2
  52. package/documentation/mu.table.md +20 -6
  53. package/documentation/mu.tabs.md +5 -3
  54. package/documentation/mu.toast.md +134 -0
  55. package/documentation/mu.tooltip.md +30 -28
  56. package/documentation/mu.typography.md +44 -42
  57. package/documentation/mu.utilities.md +83 -0
  58. package/documentation/mu.variables.md +276 -0
  59. package/package.json +5 -3
@@ -100,7 +100,7 @@ No additional CSS classes are needed on child elements. All styling targets the
100
100
 
101
101
  | Property | Value |
102
102
  |----------|-------|
103
- | Border | `1px solid var(--pico-secondary-background)` |
103
+ | Border | `1px solid var(--mu-secondary-background)` |
104
104
  | Border radius | `0.375rem` |
105
105
  | Summary padding | `0.75rem 1rem` |
106
106
  | Content padding | `0.75rem 1rem` |
@@ -116,4 +116,6 @@ No additional CSS classes are needed on child elements. All styling targets the
116
116
 
117
117
  ---
118
118
 
119
- [Voir l'exemple](../examples/accordion.html)
119
+ > See also : [µCard](mu.card.md) · [µTabs](mu.tabs.md)
120
+
121
+ → [See example](../examples/accordion.html)
@@ -1,6 +1,6 @@
1
1
  # µAlert
2
2
 
3
- **µAlert** is a notification banner component, part of the [µCSS](.) framework. It provides 8 color variants, an optional title, inline links, and a dismissible close button.
3
+ **µAlert** is a notification banner component, part of the [µCSS](.) framework. It provides 11 color variants, an optional title, inline links, and a dismissible close button.
4
4
 
5
5
  ---
6
6
 
@@ -18,7 +18,7 @@ Apply `.alert` along with a color variant class to a `<div>`:
18
18
 
19
19
  ## Color variants
20
20
 
21
- All 8 color roles are available:
21
+ All 11 color roles are available:
22
22
 
23
23
  ```html
24
24
  <div class="alert alert-primary"><p>This is a <strong>primary</strong> alert.</p></div>
@@ -29,18 +29,24 @@ All 8 color roles are available:
29
29
  <div class="alert alert-info"><p>This is an <strong>info</strong> alert.</p></div>
30
30
  <div class="alert alert-warning"><p>This is a <strong>warning</strong> alert.</p></div>
31
31
  <div class="alert alert-error"><p>This is an <strong>error</strong> alert.</p></div>
32
+ <div class="alert alert-accent"><p>This is an <strong>accent</strong> alert.</p></div>
33
+ <div class="alert alert-pop"><p>This is a <strong>pop</strong> alert.</p></div>
34
+ <div class="alert alert-spark"><p>This is a <strong>spark</strong> alert.</p></div>
32
35
  ```
33
36
 
34
- | Class | Text color | Background | Border |
35
- |-------|-----------|------------|--------|
36
- | `.alert-primary` | `--pico-primary` | `--pico-primary-background` | `--pico-primary` |
37
- | `.alert-secondary` | `--pico-secondary` | `--pico-secondary-background` | `--pico-secondary` |
38
- | `.alert-tertiary` | `--pico-tertiary` | `--pico-tertiary-background` | `--pico-tertiary` |
39
- | `.alert-contrast` | `--pico-contrast` | `--pico-contrast-background` | `--pico-contrast` |
40
- | `.alert-success` | `--pico-success` | `--pico-success-background` | `--pico-success` |
41
- | `.alert-info` | `--pico-info` | `--pico-info-background` | `--pico-info` |
42
- | `.alert-warning` | `--pico-warning` | `--pico-warning-background` | `--pico-warning` |
43
- | `.alert-error` | `--pico-error` | `--pico-error-background` | `--pico-error` |
37
+ | Class | Text color | Background |
38
+ |-------|-----------|------------|
39
+ | `.alert-primary` | `--mu-primary` | `--mu-primary-background` |
40
+ | `.alert-secondary` | `--mu-secondary` | `--mu-secondary-background` |
41
+ | `.alert-tertiary` | `--mu-tertiary` | `--mu-tertiary-background` |
42
+ | `.alert-contrast` | `--mu-contrast` | `--mu-contrast-background` |
43
+ | `.alert-success` | `--mu-success` | `--mu-success-background` |
44
+ | `.alert-info` | `--mu-info` | `--mu-info-background` |
45
+ | `.alert-warning` | `--mu-warning` | `--mu-warning-background` |
46
+ | `.alert-error` | `--mu-error` | `--mu-error-background` |
47
+ | `.alert-accent` | `--mu-accent` | `--mu-accent-background` |
48
+ | `.alert-pop` | `--mu-pop` | `--mu-pop-background` |
49
+ | `.alert-spark` | `--mu-spark` | `--mu-spark-background` |
44
50
 
45
51
  ---
46
52
 
@@ -104,7 +110,7 @@ Links inside alerts are styled with `font-weight: 600`, inherit the alert color,
104
110
  | Class | Description |
105
111
  |-------|-------------|
106
112
  | `.alert` | Base alert container (padding, border-radius, margin-bottom) |
107
- | `.alert-{color}` | Color variant (`primary`, `secondary`, `tertiary`, `contrast`, `success`, `info`, `warning`, `error`) |
113
+ | `.alert-{color}` | Color variant (`primary`, `secondary`, `tertiary`, `contrast`, `success`, `info`, `warning`, `error`, `accent`, `pop`, `spark`) |
108
114
  | `.alert-title` | Bold title block inside the alert |
109
115
  | `.alert-dismissible` | Adds right padding for the close button |
110
116
  | `.alert-close` | Close button, positioned absolutely at the right |
@@ -131,4 +137,6 @@ Links inside alerts are styled with `font-weight: 600`, inherit the alert color,
131
137
 
132
138
  ---
133
139
 
134
- [Voir l'exemple](../examples/alert.html)
140
+ > See also : [µToast](mu.toast.md) · [µBadge](mu.badge.md)
141
+
142
+ → [See example](../examples/alert.html)
@@ -1,6 +1,6 @@
1
1
  # µBadge
2
2
 
3
- **µBadge** is an inline label and counter component, part of the [µCSS](.) framework. It supports 8 color variants, outline style, pill shape, three sizes, and an attached positioning mode for notification counters.
3
+ **µBadge** is an inline label and counter component, part of the [µCSS](.) framework. It supports 11 color variants, outline style, pill shape, three sizes, and an attached positioning mode for notification counters.
4
4
 
5
5
  ---
6
6
 
@@ -12,13 +12,13 @@ Apply `.badge` along with a color variant class to a `<span>`:
12
12
  <span class="badge badge-primary">Primary</span>
13
13
  ```
14
14
 
15
- The default badge (without a color class) uses `--pico-contrast` as its background color.
15
+ The default badge (without a color class) uses `--mu-contrast` as its background color.
16
16
 
17
17
  ---
18
18
 
19
19
  ## Color variants (filled)
20
20
 
21
- All 8 color roles are available:
21
+ All 11 color roles are available:
22
22
 
23
23
  ```html
24
24
  <span class="badge badge-primary">Primary</span>
@@ -29,18 +29,24 @@ All 8 color roles are available:
29
29
  <span class="badge badge-info">Info</span>
30
30
  <span class="badge badge-warning">Warning</span>
31
31
  <span class="badge badge-error">Error</span>
32
+ <span class="badge badge-accent">Accent</span>
33
+ <span class="badge badge-pop">Pop</span>
34
+ <span class="badge badge-spark">Spark</span>
32
35
  ```
33
36
 
34
37
  | Class | Background | Text color | Border |
35
38
  |-------|-----------|------------|--------|
36
- | `.badge-primary` | `--pico-primary` | `--pico-primary-inverse` | `--pico-primary` |
37
- | `.badge-secondary` | `--pico-secondary` | `--pico-secondary-inverse` | `--pico-secondary` |
38
- | `.badge-tertiary` | `--pico-tertiary` | `--pico-tertiary-inverse` | `--pico-tertiary` |
39
- | `.badge-contrast` | `--pico-contrast` | `--pico-contrast-inverse` | `--pico-contrast` |
40
- | `.badge-success` | `--pico-success` | `--pico-success-inverse` | `--pico-success` |
41
- | `.badge-info` | `--pico-info` | `--pico-info-inverse` | `--pico-info` |
42
- | `.badge-warning` | `--pico-warning` | `--pico-warning-inverse` | `--pico-warning` |
43
- | `.badge-error` | `--pico-error` | `--pico-error-inverse` | `--pico-error` |
39
+ | `.badge-primary` | `--mu-primary` | `--mu-primary-inverse` | `--mu-primary` |
40
+ | `.badge-secondary` | `--mu-secondary` | `--mu-secondary-inverse` | `--mu-secondary` |
41
+ | `.badge-tertiary` | `--mu-tertiary` | `--mu-tertiary-inverse` | `--mu-tertiary` |
42
+ | `.badge-contrast` | `--mu-contrast` | `--mu-contrast-inverse` | `--mu-contrast` |
43
+ | `.badge-success` | `--mu-success` | `--mu-success-inverse` | `--mu-success` |
44
+ | `.badge-info` | `--mu-info` | `--mu-info-inverse` | `--mu-info` |
45
+ | `.badge-warning` | `--mu-warning` | `--mu-warning-inverse` | `--mu-warning` |
46
+ | `.badge-error` | `--mu-error` | `--mu-error-inverse` | `--mu-error` |
47
+ | `.badge-accent` | `--mu-accent` | `--mu-accent-inverse` | `--mu-accent` |
48
+ | `.badge-pop` | `--mu-pop` | `--mu-pop-inverse` | `--mu-pop` |
49
+ | `.badge-spark` | `--mu-spark` | `--mu-spark-inverse` | `--mu-spark` |
44
50
 
45
51
  ---
46
52
 
@@ -57,6 +63,9 @@ Add `.badge-outline` to remove the background and keep only the border and color
57
63
  <span class="badge badge-outline badge-info">Info</span>
58
64
  <span class="badge badge-outline badge-warning">Warning</span>
59
65
  <span class="badge badge-outline badge-error">Error</span>
66
+ <span class="badge badge-outline badge-accent">Accent</span>
67
+ <span class="badge badge-outline badge-pop">Pop</span>
68
+ <span class="badge badge-outline badge-spark">Spark</span>
60
69
  ```
61
70
 
62
71
  The `.badge-outline` class sets `background-color: transparent` and changes the text color to match the role color.
@@ -99,12 +108,12 @@ Three sizes are available:
99
108
  Use `.badge-attached` to position a badge as a notification counter on the corner of a parent element. The parent must have `position: relative`:
100
109
 
101
110
  ```html
102
- <span style="position: relative; display: inline-block; padding: 0.5rem 1rem; border: 1px solid var(--pico-secondary-background); border-radius: 0.375rem;">
111
+ <span style="position: relative; display: inline-block; padding: 0.5rem 1rem; border: 1px solid var(--mu-secondary-background); border-radius: 0.375rem;">
103
112
  Inbox
104
113
  <span class="badge badge-error badge-attached badge-pill">3</span>
105
114
  </span>
106
115
 
107
- <span style="position: relative; display: inline-block; padding: 0.5rem 1rem; border: 1px solid var(--pico-secondary-background); border-radius: 0.375rem;">
116
+ <span style="position: relative; display: inline-block; padding: 0.5rem 1rem; border: 1px solid var(--mu-secondary-background); border-radius: 0.375rem;">
108
117
  Notifications
109
118
  <span class="badge badge-warning badge-attached badge-pill">12</span>
110
119
  </span>
@@ -132,7 +141,7 @@ Link and button badges remove text-decoration, use a pointer cursor, and reduce
132
141
  | Class | Description |
133
142
  |-------|-------------|
134
143
  | `.badge` | Base badge (inline-flex, padding, font-size, border-radius) |
135
- | `.badge-{color}` | Color variant (`primary`, `secondary`, `tertiary`, `contrast`, `success`, `info`, `warning`, `error`) |
144
+ | `.badge-{color}` | Color variant (`primary`, `secondary`, `tertiary`, `contrast`, `success`, `info`, `warning`, `error`, `accent`, `pop`, `spark`) |
136
145
  | `.badge-outline` | Transparent background, colored text and border |
137
146
  | `.badge-pill` | Fully rounded corners (`border-radius: 50rem`) |
138
147
  | `.badge-sm` | Small size |
@@ -152,4 +161,15 @@ Link and button badges remove text-decoration, use a pointer cursor, and reduce
152
161
 
153
162
  ---
154
163
 
155
- [Voir l'exemple](../examples/badge.html)
164
+ ## Accessibility
165
+
166
+ - Badges used as links should have descriptive text or `aria-label` for screen readers.
167
+ - Ensure sufficient color contrast between badge text and background (WCAG AA minimum).
168
+ - Avoid using color alone to convey meaning — pair colored badges with text labels.
169
+ - For notification badges (counts), use `aria-label` to describe the count in context (e.g., `aria-label="3 unread messages"`).
170
+
171
+ ---
172
+
173
+ > See also : [µAlert](mu.alert.md) · [µButton](mu.button.md)
174
+
175
+ → [See example](../examples/badge.html)
@@ -119,12 +119,12 @@ The boxed variant can be combined with any separator style:
119
119
  |----------|-------|
120
120
  | Font size | `0.875rem` |
121
121
  | Separator margin | `0 0.5rem` |
122
- | Separator color | `var(--pico-secondary)` at 60% opacity |
123
- | Link color | `var(--pico-primary)` |
124
- | Link hover | `var(--pico-primary-hover)` with underline |
125
- | Current page color | `var(--pico-secondary)` |
122
+ | Separator color | `var(--mu-secondary)` at 60% opacity |
123
+ | Link color | `var(--mu-primary)` |
124
+ | Link hover | `var(--mu-primary-hover)` with underline |
125
+ | Current page color | `var(--mu-secondary)` |
126
126
  | Boxed padding | `0.5rem 1rem` |
127
- | Boxed background | `var(--pico-secondary-background)` |
127
+ | Boxed background | `var(--mu-secondary-background)` |
128
128
  | Boxed border radius | `0.375rem` |
129
129
 
130
130
  ---
@@ -137,4 +137,6 @@ The boxed variant can be combined with any separator style:
137
137
 
138
138
  ---
139
139
 
140
- [Voir l'exemple](../examples/breadcrumb.html)
140
+ > See also : [µNav](mu.nav.md) · [µPagination](mu.pagination.md)
141
+
142
+ → [See example](../examples/breadcrumb.html)
@@ -1,6 +1,6 @@
1
1
  # µButton
2
2
 
3
- **µButton** is a button component, part of the [µCSS](.) framework. It provides 8 color roles in filled and ghost variants, a link style, three sizes, and works on both `<button>` and `<a>` elements.
3
+ **µButton** is a button component, part of the [µCSS](.) framework. It provides 11 color roles in filled and outline variants, a link style, three sizes, and works on both `<button>` and `<a>` elements.
4
4
 
5
5
  ---
6
6
 
@@ -20,9 +20,9 @@ The `.btn` class can also be applied to `<a>` elements to render links as button
20
20
 
21
21
  ---
22
22
 
23
- ## Filled variants (8 colors)
23
+ ## Filled variants (11 colors)
24
24
 
25
- All 8 color roles are available as filled buttons:
25
+ All 11 color roles are available as filled buttons:
26
26
 
27
27
  ```html
28
28
  <button class="btn btn-primary">Primary</button>
@@ -33,39 +33,48 @@ All 8 color roles are available as filled buttons:
33
33
  <button class="btn btn-info">Info</button>
34
34
  <button class="btn btn-warning">Warning</button>
35
35
  <button class="btn btn-error">Error</button>
36
+ <button class="btn btn-accent">Accent</button>
37
+ <button class="btn btn-pop">Pop</button>
38
+ <button class="btn btn-spark">Spark</button>
36
39
  ```
37
40
 
38
41
  Each filled button has a solid background, matching border, and an inverse text color. On hover, the background and border shift to the `-hover` variant of the color.
39
42
 
40
43
  | Class | Background | Text color | Hover background |
41
44
  |-------|-----------|------------|-----------------|
42
- | `.btn-primary` | `--pico-primary` | `--pico-primary-inverse` | `--pico-primary-hover` |
43
- | `.btn-secondary` | `--pico-secondary` | `--pico-secondary-inverse` | `--pico-secondary-hover` |
44
- | `.btn-tertiary` | `--pico-tertiary` | `--pico-tertiary-inverse` | `--pico-tertiary-hover` |
45
- | `.btn-contrast` | `--pico-contrast` | `--pico-contrast-inverse` | `--pico-contrast-hover` |
46
- | `.btn-success` | `--pico-success` | `--pico-success-inverse` | `--pico-success-hover` |
47
- | `.btn-info` | `--pico-info` | `--pico-info-inverse` | `--pico-info-hover` |
48
- | `.btn-warning` | `--pico-warning` | `--pico-warning-inverse` | `--pico-warning-hover` |
49
- | `.btn-error` | `--pico-error` | `--pico-error-inverse` | `--pico-error-hover` |
45
+ | `.btn-primary` | `--mu-primary` | `--mu-primary-inverse` | `--mu-primary-hover` |
46
+ | `.btn-secondary` | `--mu-secondary` | `--mu-secondary-inverse` | `--mu-secondary-hover` |
47
+ | `.btn-tertiary` | `--mu-tertiary` | `--mu-tertiary-inverse` | `--mu-tertiary-hover` |
48
+ | `.btn-contrast` | `--mu-contrast` | `--mu-contrast-inverse` | `--mu-contrast-hover` |
49
+ | `.btn-success` | `--mu-success` | `--mu-success-inverse` | `--mu-success-hover` |
50
+ | `.btn-info` | `--mu-info` | `--mu-info-inverse` | `--mu-info-hover` |
51
+ | `.btn-warning` | `--mu-warning` | `--mu-warning-inverse` | `--mu-warning-hover` |
52
+ | `.btn-error` | `--mu-error` | `--mu-error-inverse` | `--mu-error-hover` |
53
+ | `.btn-accent` | `--mu-accent` | `--mu-accent-inverse` | `--mu-accent-hover` |
54
+ | `.btn-pop` | `--mu-pop` | `--mu-pop-inverse` | `--mu-pop-hover` |
55
+ | `.btn-spark` | `--mu-spark` | `--mu-spark-inverse` | `--mu-spark-hover` |
50
56
 
51
57
  ---
52
58
 
53
- ## Ghost variant
59
+ ## Outline variant
54
60
 
55
- Add `.btn-ghost` alongside a color class for a transparent background with visible border and colored text:
61
+ Add `.btn-outline` alongside a color class for a transparent background with visible border and colored text:
56
62
 
57
63
  ```html
58
- <button class="btn btn-ghost btn-primary">Primary</button>
59
- <button class="btn btn-ghost btn-secondary">Secondary</button>
60
- <button class="btn btn-ghost btn-tertiary">Tertiary</button>
61
- <button class="btn btn-ghost btn-contrast">Contrast</button>
62
- <button class="btn btn-ghost btn-success">Success</button>
63
- <button class="btn btn-ghost btn-info">Info</button>
64
- <button class="btn btn-ghost btn-warning">Warning</button>
65
- <button class="btn btn-ghost btn-error">Error</button>
64
+ <button class="btn btn-outline btn-primary">Primary</button>
65
+ <button class="btn btn-outline btn-secondary">Secondary</button>
66
+ <button class="btn btn-outline btn-tertiary">Tertiary</button>
67
+ <button class="btn btn-outline btn-contrast">Contrast</button>
68
+ <button class="btn btn-outline btn-success">Success</button>
69
+ <button class="btn btn-outline btn-info">Info</button>
70
+ <button class="btn btn-outline btn-warning">Warning</button>
71
+ <button class="btn btn-outline btn-error">Error</button>
72
+ <button class="btn btn-outline btn-accent">Accent</button>
73
+ <button class="btn btn-outline btn-pop">Pop</button>
74
+ <button class="btn btn-outline btn-spark">Spark</button>
66
75
  ```
67
76
 
68
- Ghost buttons have `background-color: transparent`, text color matching the role, and a matching border. On hover, opacity is reduced to `0.8`.
77
+ Outline buttons have `background-color: transparent`, text color matching the role, and a matching border. On hover, the background fills with the role color and the text switches to its inverse.
69
78
 
70
79
  ---
71
80
 
@@ -77,7 +86,7 @@ Use `.btn-link` for a button that looks like a text link (no background, no bord
77
86
  <button class="btn btn-link">Link button</button>
78
87
  ```
79
88
 
80
- The link style uses `--pico-primary` as its text color and `--pico-primary-hover` on hover.
89
+ The link style uses `--mu-primary` as its text color and `--mu-primary-hover` on hover.
81
90
 
82
91
  ---
83
92
 
@@ -105,7 +114,7 @@ Any `<a>` element can use `.btn` classes to look like a button:
105
114
 
106
115
  ```html
107
116
  <a class="btn btn-primary" href="#">Link as button</a>
108
- <a class="btn btn-ghost btn-success" href="#">Ghost link</a>
117
+ <a class="btn btn-outline btn-success" href="#">Outline link</a>
109
118
  <a class="btn btn-error btn-lg" href="#">Large link</a>
110
119
  ```
111
120
 
@@ -116,8 +125,8 @@ Any `<a>` element can use `.btn` classes to look like a button:
116
125
  | Class | Description |
117
126
  |-------|-------------|
118
127
  | `.btn` | Base button (inline-flex, padding, font-weight 600, border-radius, transitions) |
119
- | `.btn-{color}` | Filled color variant (`primary`, `secondary`, `tertiary`, `contrast`, `success`, `info`, `warning`, `error`) |
120
- | `.btn-ghost` | Transparent background, colored border and text |
128
+ | `.btn-{color}` | Filled color variant (`primary`, `secondary`, `tertiary`, `contrast`, `success`, `info`, `warning`, `error`, `accent`, `pop`, `spark`) |
129
+ | `.btn-outline` | Transparent background, colored border and text |
121
130
  | `.btn-link` | Looks like a text link (transparent, underlined, primary color) |
122
131
  | `.btn-sm` | Small size |
123
132
  | `.btn-lg` | Large size |
@@ -138,10 +147,12 @@ Any `<a>` element can use `.btn` classes to look like a button:
138
147
 
139
148
  ## Accessibility
140
149
 
141
- - Each color variant has a dedicated `:focus-visible` outline using the `--pico-{color}-focus` variable with a `2px` outline offset.
150
+ - Each color variant has a dedicated `:focus-visible` outline using the `--mu-{color}-focus` variable with a `2px` outline offset.
142
151
  - The `.btn-link` variant follows link color conventions for consistency with standard anchor styling.
143
152
  - Use `<button>` for actions and `<a>` for navigation to maintain proper semantics.
144
153
 
145
154
  ---
146
155
 
147
- [Voir l'exemple](../examples/button.html)
156
+ > See also : [µLink](mu.link.md) · [µForms](mu.forms.md)
157
+
158
+ → [See example](../examples/button.html)
@@ -1,12 +1,12 @@
1
1
  # µCard
2
2
 
3
- **µCard** provides colored card variants for the `<article>` element, part of the [µCSS](.) framework. It extends PicoCSS's default card styling with 8 color accents, automatic header/footer shading, and a left border indicator.
3
+ **µCard** provides colored card variants for the `<article>` element, part of the [µCSS](.) framework. It extends the default card styling with 11 color accents and automatic header/footer shading.
4
4
 
5
5
  ---
6
6
 
7
7
  ## Usage
8
8
 
9
- Cards use the standard HTML `<article>` element. Add a color class to apply a colored variant with a left border accent and tinted background.
9
+ Cards use the standard HTML `<article>` element. Add a color class to apply a colored variant with a tinted background.
10
10
 
11
11
  ```html
12
12
  <article class="card-primary">
@@ -28,7 +28,7 @@ A card can contain any combination of `<header>`, body content, and `<footer>`.
28
28
 
29
29
  ### Default card (no color)
30
30
 
31
- Without a color class, `<article>` renders with the standard PicoCSS card styling:
31
+ Without a color class, `<article>` renders with the standard card styling:
32
32
 
33
33
  ```html
34
34
  <article>
@@ -42,20 +42,23 @@ Without a color class, `<article>` renders with the standard PicoCSS card stylin
42
42
 
43
43
  ## Color variants
44
44
 
45
- 8 color classes are available, matching the µCSS color roles:
45
+ 11 color classes are available, matching the µCSS color roles:
46
46
 
47
- | Class | Color role | Left border | Background |
48
- |-------------------|------------|----------------------|----------------------------|
49
- | `.card-primary` | Primary | `--pico-primary` | `--pico-primary-background` |
50
- | `.card-secondary` | Secondary | `--pico-secondary` | `--pico-secondary-background` |
51
- | `.card-tertiary` | Tertiary | `--pico-tertiary` | `--pico-tertiary-background` |
52
- | `.card-contrast` | Contrast | `--pico-contrast` | `--pico-contrast-background` |
53
- | `.card-success` | Success | `--pico-success` | `--pico-success-background` |
54
- | `.card-info` | Info | `--pico-info` | `--pico-info-background` |
55
- | `.card-warning` | Warning | `--pico-warning` | `--pico-warning-background` |
56
- | `.card-error` | Error | `--pico-error` | `--pico-error-background` |
47
+ | Class | Color role | Background |
48
+ |-------------------|------------|----------------------------|
49
+ | `.card-primary` | Primary | `--mu-primary-background` |
50
+ | `.card-secondary` | Secondary | `--mu-secondary-background` |
51
+ | `.card-tertiary` | Tertiary | `--mu-tertiary-background` |
52
+ | `.card-contrast` | Contrast | `--mu-contrast-background` |
53
+ | `.card-accent` | Accent | `--mu-accent-background` |
54
+ | `.card-success` | Success | `--mu-success-background` |
55
+ | `.card-info` | Info | `--mu-info-background` |
56
+ | `.card-warning` | Warning | `--mu-warning-background` |
57
+ | `.card-error` | Error | `--mu-error-background` |
58
+ | `.card-pop` | Pop | `--mu-pop-background` |
59
+ | `.card-spark` | Spark | `--mu-spark-background` |
57
60
 
58
- ### All 8 variants example
61
+ ### All 11 variants example
59
62
 
60
63
  ```html
61
64
  <div class="row">
@@ -96,14 +99,13 @@ Without a color class, `<article>` renders with the standard PicoCSS card stylin
96
99
 
97
100
  Colored cards (`article[class*="card-"]`) apply the following styles:
98
101
 
99
- - **Left border**: 4px solid in the card's color role.
100
102
  - **Background**: the card's light background tint.
101
103
  - **Header/footer background**: a `color-mix()` blend of 12% card color into the card background, creating a subtle shading difference.
102
104
  - **Header border-bottom / footer border-top**: `color-mix()` blend of 20% card color, providing a gentle separator.
103
105
 
104
106
  ---
105
107
 
106
- ## PicoCSS override
108
+ ## Implementation note
107
109
 
108
110
  µCard includes one global fix:
109
111
 
@@ -113,7 +115,7 @@ article > *:last-child:not(header):not(footer) {
113
115
  }
114
116
  ```
115
117
 
116
- This removes the bottom margin on the last content element inside a card (e.g., a `<p>` tag), preventing unwanted spacing before the card's bottom edge or footer. This is necessary because PicoCSS applies default margins to `<p>` elements.
118
+ This removes the bottom margin on the last content element inside a card (e.g., a `<p>` tag), preventing unwanted spacing before the card's bottom edge or footer. This is necessary because the base styles apply default margins to `<p>` elements.
117
119
 
118
120
  ---
119
121
 
@@ -125,11 +127,25 @@ This removes the bottom margin on the last content element inside a card (e.g.,
125
127
  | `.card-secondary` | Secondary color variant |
126
128
  | `.card-tertiary` | Tertiary color variant |
127
129
  | `.card-contrast` | Contrast color variant |
130
+ | `.card-accent` | Accent color variant |
128
131
  | `.card-success` | Success color variant |
129
132
  | `.card-info` | Info color variant |
130
133
  | `.card-warning` | Warning color variant |
131
134
  | `.card-error` | Error color variant |
135
+ | `.card-pop` | Pop color variant (lighter accent) |
136
+ | `.card-spark` | Spark color variant (lighter contrast) |
132
137
 
133
138
  ---
134
139
 
135
- [Voir l'exemple](../examples/card.html)
140
+ ## Accessibility
141
+
142
+ - The `<article>` element is a semantic landmark — screen readers announce it as an article.
143
+ - Always include a heading (`<h2>`–`<h6>`) inside the card for screen reader navigation.
144
+ - Card `<header>` and `<footer>` are announced as part of the article structure.
145
+ - For clickable cards, make the heading link the primary interactive element rather than wrapping the entire card in `<a>`.
146
+
147
+ ---
148
+
149
+ > See also : [µGrid](mu.grid.md) · [µHero](mu.hero.md)
150
+
151
+ → [See example](../examples/card.html)
@@ -1,6 +1,6 @@
1
1
  # µCheckbox & Radio
2
2
 
3
- **µCheckbox & Radio** describes the native checkbox and radio button styling provided by [µCSS](.) via PicoCSS. These are standard HTML form controls (`<input type="checkbox">` and `<input type="radio">`) that PicoCSS styles automatically without any additional classes.
3
+ **µCheckbox & Radio** describes the native checkbox and radio button styling provided by [µCSS](.). These are standard HTML form controls (`<input type="checkbox">` and `<input type="radio">`) that µCSS styles automatically without any additional classes.
4
4
 
5
5
  ---
6
6
 
@@ -118,4 +118,6 @@ Checkboxes and radio buttons can be combined inside a card (`<article>`) for str
118
118
 
119
119
  ---
120
120
 
121
- [Voir l'exemple](../examples/checkbox-radio.html)
121
+ > See also : [µSwitch](mu.switch.md) · [µForms](mu.forms.md)
122
+
123
+ → [See example](../examples/checkbox-radio.html)
@@ -0,0 +1,85 @@
1
+ # µCode
2
+
3
+ **µCode** describes the styling of source code elements in [µCSS](.): inline code (`<code>`), code blocks (`<pre>`), keyboard shortcuts (`<kbd>`), and sample output (`<samp>`).
4
+
5
+ ---
6
+
7
+ ## Usage
8
+
9
+ An inline code fragment uses the `<code>` tag:
10
+
11
+ ```html
12
+ <p>Utilisez <code>var(--mu-primary)</code> pour la couleur primaire.</p>
13
+ ```
14
+
15
+ ---
16
+
17
+ ## Inline code
18
+
19
+ The `<code>`, `<kbd>`, and `<samp>` elements are displayed as `inline-block` with a colored background and border-radius:
20
+
21
+ ```html
22
+ <p>La commande <code>npm install</code> installe les dependances.</p>
23
+ <p>Appuyez sur <kbd>Ctrl</kbd> + <kbd>C</kbd> pour copier.</p>
24
+ <p>Le programme affiche <samp>Hello World</samp>.</p>
25
+ ```
26
+
27
+ | Element | Background | Text color |
28
+ |---------|------------|------------|
29
+ | `<code>` | `--mu-code-background-color` | `--mu-code-color` |
30
+ | `<samp>` | `--mu-code-background-color` | `--mu-code-color` |
31
+ | `<kbd>` | `--mu-code-kbd-background-color` | `--mu-code-kbd-color` |
32
+
33
+ The `<kbd>` element uses a dark background and light text to visually stand out as a keyboard shortcut.
34
+
35
+ ---
36
+
37
+ ## Code block
38
+
39
+ Wrap `<code>` inside `<pre>` for a code block with horizontal scrolling:
40
+
41
+ ```html
42
+ <pre><code>function hello() {
43
+ console.log("Hello, World!");
44
+ return true;
45
+ }</code></pre>
46
+ ```
47
+
48
+ The block receives a padding of `var(--mu-spacing)` and `overflow-x: auto` to handle long lines.
49
+
50
+ ---
51
+
52
+ ## Typographic properties
53
+
54
+ All code elements use the theme's monospace font:
55
+
56
+ | Property | Value |
57
+ |----------|-------|
58
+ | Font | `--mu-font-family` (monospace) |
59
+ | Size | `0.875em` (relative to parent) |
60
+ | Weight | `--mu-font-weight` |
61
+ | Border-radius | `--mu-border-radius` |
62
+ | Padding (inline) | `0.375rem` |
63
+ | Padding (block) | `var(--mu-spacing)` |
64
+
65
+ ---
66
+
67
+ ## Customization
68
+
69
+ ```css
70
+ :root {
71
+ /* Changer le fond du code inline */
72
+ --mu-code-background-color: #f0f0f0;
73
+
74
+ /* Changer la couleur du texte de code */
75
+ --mu-code-color: #333;
76
+
77
+ /* Personnaliser les touches clavier */
78
+ --mu-code-kbd-background-color: #333;
79
+ --mu-code-kbd-color: #fff;
80
+ }
81
+ ```
82
+
83
+ ---
84
+
85
+ > See also : [µTypography](mu.typography.md) · [µVariables](mu.variables.md)