@digicreon/mucss 1.0.0 → 1.4.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 +67 -17
- package/dist/mu.amber.css +2 -2
- package/dist/mu.azure.css +2 -2
- package/dist/mu.blue.css +2 -2
- package/dist/mu.css +2 -2
- package/dist/mu.cyan.css +2 -2
- package/dist/mu.fuchsia.css +2 -2
- package/dist/mu.green.css +2 -2
- package/dist/mu.grey.css +2 -2
- package/dist/mu.indigo.css +2 -2
- package/dist/mu.jade.css +2 -2
- package/dist/mu.lime.css +2 -2
- package/dist/mu.orange.css +2 -2
- package/dist/mu.pink.css +2 -2
- package/dist/mu.pumpkin.css +2 -2
- package/dist/mu.purple.css +2 -2
- package/dist/mu.red.css +2 -2
- package/dist/mu.sand.css +2 -2
- package/dist/mu.slate.css +2 -2
- package/dist/mu.violet.css +2 -2
- package/dist/mu.yellow.css +2 -2
- package/dist/mu.zinc.css +2 -2
- package/documentation/mu.accordion.md +4 -2
- package/documentation/mu.alert.md +22 -14
- package/documentation/mu.badge.md +35 -15
- package/documentation/mu.breadcrumb.md +8 -6
- package/documentation/mu.button.md +39 -28
- package/documentation/mu.card.md +35 -19
- package/documentation/mu.checkbox-radio.md +4 -2
- package/documentation/mu.code.md +85 -0
- package/documentation/mu.colors.md +307 -0
- package/documentation/mu.container.md +87 -0
- package/documentation/mu.dark-mode.md +96 -0
- package/documentation/mu.dropdown.md +32 -27
- package/documentation/mu.embedded.md +101 -0
- package/documentation/mu.figure.md +82 -0
- package/documentation/mu.forms-advanced.md +6 -4
- package/documentation/mu.forms.md +11 -9
- package/documentation/mu.grid.md +14 -8
- package/documentation/mu.group.md +29 -27
- package/documentation/mu.hero.md +200 -0
- package/documentation/mu.link.md +108 -0
- package/documentation/mu.loading.md +4 -2
- package/documentation/mu.modal.md +9 -7
- package/documentation/mu.nav.md +191 -0
- package/documentation/mu.pagination.md +3 -1
- package/documentation/mu.progress.md +31 -14
- package/documentation/mu.range.md +4 -2
- package/documentation/mu.skeleton.md +111 -0
- package/documentation/mu.spinner.md +20 -12
- package/documentation/mu.switch.md +4 -2
- package/documentation/mu.table.md +20 -6
- package/documentation/mu.tabs.md +5 -3
- package/documentation/mu.toast.md +134 -0
- package/documentation/mu.tooltip.md +30 -28
- package/documentation/mu.typography.md +44 -42
- package/documentation/mu.utilities.md +83 -0
- package/documentation/mu.variables.md +276 -0
- package/package.json +5 -3
package/README.md
CHANGED
|
@@ -1,20 +1,36 @@
|
|
|
1
1
|
# µCSS
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Full-featured themeable CSS framework built on [PicoCSS v2](https://picocss.com/).
|
|
4
4
|
|
|
5
5
|
## Features
|
|
6
6
|
|
|
7
7
|
- **20 color themes** — One CSS file per theme, ready to use
|
|
8
|
-
- **12-column responsive grid** —
|
|
9
|
-
- **
|
|
8
|
+
- **12-column responsive grid** — 6 breakpoints, offsets, ordering, display utilities
|
|
9
|
+
- **17 UI components** — Accordion, Alert, Badge, Breadcrumb, Button, Card, Forms, Hero, Modal, Nav, Pagination, Progress, Skeleton, Spinner, Table, Toast, Tabs
|
|
10
|
+
- **Utility classes** — Color (text, background, border), positioning (sticky, fixed)
|
|
10
11
|
- **Dark mode** — Automatic (prefers-color-scheme) or manual (`data-theme`)
|
|
11
12
|
- **Pure CSS** — No JavaScript dependency
|
|
12
13
|
- **PHP tooling** — Build and theming via PHP scripts, no Node.js/SASS required
|
|
13
|
-
- **PicoCSS compatible** — All variables use the `--pico-` prefix
|
|
14
14
|
|
|
15
15
|
## Installation
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
### CDN (jsDelivr)
|
|
18
|
+
|
|
19
|
+
```html
|
|
20
|
+
<!-- Default theme (azure) -->
|
|
21
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@digicreon/mucss/dist/mu.css">
|
|
22
|
+
|
|
23
|
+
<!-- Or pick a specific color theme -->
|
|
24
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@digicreon/mucss/dist/mu.violet.css">
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### npm
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
npm install @digicreon/mucss
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### Local
|
|
18
34
|
|
|
19
35
|
```html
|
|
20
36
|
<!-- Default theme (azure) -->
|
|
@@ -41,17 +57,21 @@ Each file is self-contained (PicoCSS base + colors + grid + all components).
|
|
|
41
57
|
| Component | Description | Example |
|
|
42
58
|
|-----------|-------------|---------|
|
|
43
59
|
| Accordion | Collapsible sections using `<details>` | [accordion.html](examples/accordion.html) |
|
|
44
|
-
| Alert | Notification banners,
|
|
60
|
+
| Alert | Notification banners, 11 colors, dismissible | [alert.html](examples/alert.html) |
|
|
45
61
|
| Badge | Inline labels, pills, outline, attached | [badge.html](examples/badge.html) |
|
|
46
62
|
| Breadcrumb | Navigation trail, 4 separator styles, boxed | [breadcrumb.html](examples/breadcrumb.html) |
|
|
47
|
-
| Button |
|
|
63
|
+
| Button | 11 colors, outline, link, 3 sizes | [button.html](examples/button.html) |
|
|
48
64
|
| Card | Colored `<article>` with header/footer | [card.html](examples/card.html) |
|
|
49
65
|
| Forms | Input sizes (sm/lg) and validation states | [forms.html](examples/forms.html) |
|
|
66
|
+
| Hero | Full-width hero sections, 11 colors, gradient | [hero.html](examples/hero.html) |
|
|
50
67
|
| Modal | Dialog sizes (sm/default/lg/fullscreen) | [modal.html](examples/modal.html) |
|
|
68
|
+
| Nav | Responsive navbar, burger menu, colored, sticky/fixed | [nav.html](examples/nav.html) |
|
|
51
69
|
| Pagination | Aligned, sized, borderless, responsive | [pagination.html](examples/pagination.html) |
|
|
52
70
|
| Progress | Colored progress bars | [progress.html](examples/progress.html) |
|
|
53
|
-
|
|
|
71
|
+
| Skeleton | Loading placeholders, text, title, avatar, image | [skeleton.html](examples/skeleton.html) |
|
|
72
|
+
| Spinner | Loading spinners, 11 colors, 3 sizes | [spinner.html](examples/spinner.html) |
|
|
54
73
|
| Table | Hover, striped, bordered, compact, fullwidth | [table.html](examples/table.html) |
|
|
74
|
+
| Toast | Fixed-position notifications, 6 positions, 11 colors | [toast.html](examples/toast.html) |
|
|
55
75
|
| Tabs | Standard, pills, aligned, fullwidth | [tabs.html](examples/tabs.html) |
|
|
56
76
|
|
|
57
77
|
## PicoCSS native
|
|
@@ -70,15 +90,16 @@ Each file is self-contained (PicoCSS base + colors + grid + all components).
|
|
|
70
90
|
|
|
71
91
|
## Grid
|
|
72
92
|
|
|
73
|
-
Flexbox 12-column grid with
|
|
93
|
+
Flexbox 12-column grid with 6 breakpoints:
|
|
74
94
|
|
|
75
95
|
| Breakpoint | Prefix | Min-width |
|
|
76
96
|
|------------|--------|-----------|
|
|
77
97
|
| Default | `col-` | 0 |
|
|
78
|
-
| Small | `col-sm-` |
|
|
79
|
-
| Medium | `col-md-` |
|
|
80
|
-
| Large | `col-lg-` |
|
|
81
|
-
| Extra-large | `col-xl-` |
|
|
98
|
+
| Small | `col-sm-` | 576px |
|
|
99
|
+
| Medium | `col-md-` | 768px |
|
|
100
|
+
| Large | `col-lg-` | 1024px |
|
|
101
|
+
| Extra-large | `col-xl-` | 1280px |
|
|
102
|
+
| Extra-extra-large | `col-xxl-` | 1536px |
|
|
82
103
|
|
|
83
104
|
```html
|
|
84
105
|
<div class="row">
|
|
@@ -91,6 +112,29 @@ Offsets (`offset-{n}`, `offset-md-{n}`...), ordering (`order-first`, `order-md-2
|
|
|
91
112
|
|
|
92
113
|
See [grid example](examples/grid.html).
|
|
93
114
|
|
|
115
|
+
## Utilities
|
|
116
|
+
|
|
117
|
+
### Color classes
|
|
118
|
+
|
|
119
|
+
33 utility classes for text, background, and border colors:
|
|
120
|
+
|
|
121
|
+
- `.c-{role}` — text color (`.c-primary`, `.c-success`, …)
|
|
122
|
+
- `.bg-{role}` — background color with automatic inverse text and link color
|
|
123
|
+
- `.border-{role}` — border color
|
|
124
|
+
- `.c-inverse` — white/black text for use on filled backgrounds
|
|
125
|
+
|
|
126
|
+
On `<nav>` or its parent (e.g. `<header>`), `.bg-*` classes also apply a gradient.
|
|
127
|
+
|
|
128
|
+
### Positioning
|
|
129
|
+
|
|
130
|
+
| Class | Effect |
|
|
131
|
+
|-------|--------|
|
|
132
|
+
| `.sticky-top` | Sticks to top on scroll (stays in flow) |
|
|
133
|
+
| `.fixed-top` | Fixed to viewport top (out of flow) |
|
|
134
|
+
| `.fixed-bottom` | Fixed to viewport bottom (out of flow) |
|
|
135
|
+
|
|
136
|
+
On `<nav>`, these classes automatically add `z-index` and `box-shadow`.
|
|
137
|
+
|
|
94
138
|
## Dark mode
|
|
95
139
|
|
|
96
140
|
µCSS supports three modes:
|
|
@@ -128,17 +172,23 @@ mucss/
|
|
|
128
172
|
pico.colors.css # PicoCSS palette (external)
|
|
129
173
|
css/
|
|
130
174
|
mu.grid.css # 12-column grid
|
|
131
|
-
mu.
|
|
175
|
+
mu.colors.css # Color utility classes
|
|
176
|
+
mu.utilities.css # Positioning utilities (sticky, fixed)
|
|
177
|
+
mu.component.*.css # UI components (17 files)
|
|
132
178
|
dist/ # Build output (21 CSS files)
|
|
179
|
+
documentation/ # Component and feature documentation
|
|
133
180
|
examples/ # HTML demos for each component
|
|
134
|
-
specification.md # Full specification
|
|
135
181
|
```
|
|
136
182
|
|
|
137
183
|
## Color roles
|
|
138
184
|
|
|
139
|
-
Each theme maps
|
|
185
|
+
Each theme maps 11 semantic roles to PicoCSS color families:
|
|
186
|
+
|
|
187
|
+
**primary** · **secondary** · **tertiary** · **contrast** · **accent** · **success** · **info** · **warning** · **error** · **pop** · **spark**
|
|
188
|
+
|
|
189
|
+
> `pop` and `spark` are derived roles — `pop` uses the same color family as `accent` with lighter shades, and `spark` uses the same color family as `contrast` with lighter shades. They do not appear in the theme JSON.
|
|
140
190
|
|
|
141
|
-
|
|
191
|
+
µCSS also provides utility classes for color and positioning — see [Utilities](#utilities).
|
|
142
192
|
|
|
143
193
|
## License
|
|
144
194
|
|