@anyblades/blades 3.1.0-beta.6 → 3.1.0-rc.1
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 +140 -170
- package/css/blades.css +4 -4
- package/css/blades.min.css +4 -4
- package/css/blades.ninja.css +5 -5
- package/css/blades.ninja.min.css +5 -5
- package/css/float-label.css +1 -1
- package/css/float-label.min.css +1 -1
- package/css/layered/README.md +164 -0
- package/css/layered/_compact.css +30 -0
- package/css/layered/_utilities.css +23 -0
- package/css/layered/_variables-blades.css +8 -0
- package/css/layered/_variables.css +258 -0
- package/css/layered/blades.layered.css +4 -4
- package/css/layered/blades.layered.min.css +4 -4
- package/css/layered/components/_accordion.css +93 -0
- package/css/layered/components/_card.css +37 -0
- package/css/layered/components/_dropdown-popover.css +89 -0
- package/css/layered/components/_dropdown.css +188 -0
- package/css/layered/components/_group.css +89 -0
- package/css/layered/components/_index.css +950 -0
- package/css/layered/components/_loading.css +51 -0
- package/css/layered/components/_modal-modern.css +17 -0
- package/css/layered/components/_modal.css +144 -0
- package/css/layered/components/_nav.css +114 -0
- package/css/layered/components/_progress.css +68 -0
- package/css/layered/components/_timeline.css +7 -0
- package/css/layered/components/_tooltip.css +158 -0
- package/css/layered/content/_button.css +125 -0
- package/css/layered/content/_code-block.css +17 -0
- package/css/layered/content/_code.css +46 -0
- package/css/layered/content/_embedded-content.css +33 -0
- package/css/layered/content/_figure.css +10 -0
- package/css/layered/content/_icon.css +30 -0
- package/css/layered/content/_index.css +456 -0
- package/css/layered/content/_link.css +59 -0
- package/css/layered/content/_misc.css +15 -0
- package/css/layered/content/_table.css +24 -0
- package/css/layered/content/_typography.css +137 -0
- package/css/layered/forms/_basics.css +257 -0
- package/css/layered/forms/_checkbox-radio-switch.css +132 -0
- package/css/layered/forms/_index.css +617 -0
- package/css/layered/forms/_input-color.css +17 -0
- package/css/layered/forms/_input-datetime.css +37 -0
- package/css/layered/forms/_input-file.css +25 -0
- package/css/layered/forms/_input-range.css +111 -0
- package/css/layered/forms/_input-search.css +32 -0
- package/css/layered/forms/float-label/_core.css +28 -0
- package/css/layered/forms/float-label/_index.css +54 -0
- package/css/layered/forms/float-label/_theme.css +25 -0
- package/css/layered/forms/float-label/core.css +1 -1
- package/css/layered/forms/float-label.css +1 -1
- package/css/layered/layout/_columns.css +7 -0
- package/css/layered/layout/_container.css +39 -0
- package/css/layered/layout/_document.css +37 -0
- package/css/layered/layout/_grid.css +17 -0
- package/css/layered/layout/_index.css +103 -0
- package/css/layered/layout/_landmarks.css +3 -0
- package/css/layered/layout/_overflow-auto.css +3 -0
- package/css/layered/layout/_section.css +3 -0
- package/css/pico.canonical.css +2512 -0
- package/css/pico.canonical.min.css +1 -0
- package/css/pico.canonical.unmin.css +2512 -0
- package/css/pico.canonical.unmin.min.css +1 -0
- package/css/pico.conditional.css +1 -1
- package/css/pico.conditional.min.css +1 -1
- package/css/pico.css +1 -1
- package/css/pico.min.css +1 -1
- package/css/pico.unmin.css +2365 -0
- package/css/pico.unmin.min.css +7 -0
- package/package.json +47 -19
- package/src/blades/_index.css +1 -1
- package/src/blades/components/_dropdown-popover.css +2 -0
- package/src/blades/components/_modal-modern.css +2 -0
- package/src/blades/forms/float-label/_core.css +1 -1
- package/src/blades.css +1 -1
- package/src/ninja/_index.css +1 -1
- package/src/ninja/_table-helpers.css +4 -4
- package/src/ninja/_table-responsive.css +5 -5
- package/src/ninja/_utilities.css +1 -1
- package/src/pico/_index.css +1 -1
package/README.md
CHANGED
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
# blades<sup>✨</sup>
|
|
2
2
|
|
|
3
|
-
![][V] ![][NEXT_V] ![][LIC] [![][X]][X_URL] [![][B]][B_URL] [![][M]][M_URL]
|
|
3
|
+
![][V] ![][NEXT_V] ![][LIC] [![][X]][X_URL] [![][B]][B_URL] [![][M]][M_URL] [![][D]][D_URL]
|
|
4
4
|
|
|
5
5
|
[V]: https://img.shields.io/npm/v/@anyblades/blades?label=&color=brightgreen
|
|
6
|
-
[NEXT_V]: https://img.shields.io/github/v/release/anyblades/blades?include_prereleases&label=
|
|
7
|
-
[LIC]: https://img.shields.io/badge
|
|
8
|
-
[X]:
|
|
6
|
+
[NEXT_V]: https://img.shields.io/github/v/release/anyblades/blades?include_prereleases&label=^&labelColor=blue&color=blue
|
|
7
|
+
[LIC]: https://img.shields.io/badge/🄻_MIT-gray
|
|
8
|
+
[X]: https://img.shields.io/badge/83-white?logo=x&style=social
|
|
9
9
|
[X_URL]: https://x.com/BladesCSS
|
|
10
10
|
[B]: https://img.shields.io/bluesky/followers/blades.dev?label=
|
|
11
11
|
[B_URL]: https://bsky.app/profile/blades.dev
|
|
12
12
|
[M]: https://img.shields.io/mastodon/follow/117487235444867518?label=NEW
|
|
13
13
|
[M_URL]: https://mastodon.social/@BladesCSS
|
|
14
|
+
[D]: https://img.shields.io/badge/%23blades-white?logo=discord&style=social
|
|
15
|
+
[D_URL]: https://discord.gg/mg8f26C
|
|
16
|
+
|
|
17
|
+

|
|
14
18
|
|
|
15
19
|
<!--section:summary-->
|
|
16
20
|
|
|
@@ -18,7 +22,7 @@
|
|
|
18
22
|
|
|
19
23
|
<big>Blades CSS is a modern drop‑in successor to [Pico CSS](//picocss.com/docs/maintenance).</big>
|
|
20
24
|
|
|
21
|
-
Just switch `pico.css` to `blades.css
|
|
25
|
+
Just switch `pico.css` to `blades.css`— and voilà!
|
|
22
26
|
|
|
23
27
|
<nav>
|
|
24
28
|
<a href="//blades.dev/css/" role="button">Get started</a>
|
|
@@ -32,7 +36,7 @@ Just switch `pico.css` to `blades.css` — and voilà!
|
|
|
32
36
|
|
|
33
37
|
## Quick start
|
|
34
38
|
|
|
35
|
-
<!--section:install-all,install
|
|
39
|
+
<!--section:install-all,install-->
|
|
36
40
|
|
|
37
41
|
<big>There are 4 ways to get started:</big>
|
|
38
42
|
|
|
@@ -57,80 +61,32 @@ Live example: https://github.com/pallets/website/blob/main/src/pallets/templates
|
|
|
57
61
|
|
|
58
62
|
Full list of CSS files available on CDN: https://cdn.jsdelivr.net/npm/@anyblades/blades@3/css/
|
|
59
63
|
|
|
60
|
-
`blades.layered.min.css` is Blades wrapped in `@layer blades { }`, so any unlayered styles of yours win over it without specificity fights. Note that inside a layer Blades' own `!important` declarations (form validation, reduced motion) beat your unlayered `!important`, and your `@keyframes` of the same name as Blades' win regardless of load order. When you can use `@import`, `@import url("…/blades.min.css") layer(blades);` does the same without this file.
|
|
61
|
-
|
|
62
64
|
### <mark>C.</mark> Install with NPM
|
|
63
65
|
|
|
64
66
|
```sh
|
|
65
67
|
npm install @anyblades/blades
|
|
66
68
|
```
|
|
67
69
|
|
|
68
|
-
Then, `@import`
|
|
70
|
+
Then, `@import` Blades into your CSS file:
|
|
69
71
|
|
|
70
72
|
```css
|
|
71
73
|
@import "@anyblades/blades";
|
|
72
74
|
```
|
|
73
75
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
Alternatively, import [standalone](//blades.ninja/css/standalone/) Blades CSS sources only (without underlying [Pico CSS](//blades.ninja/css/pico/) base styles):
|
|
76
|
+
Alternatively, import only the parts you need, e.g. per page or per component. They come wrapped in `@layer blades`, so your unlayered styles win over them:
|
|
77
77
|
|
|
78
78
|
```css
|
|
79
|
-
@import "@anyblades/blades/
|
|
79
|
+
@import "@anyblades/blades/variables";
|
|
80
|
+
@import "@anyblades/blades/layout/document";
|
|
81
|
+
@import "@anyblades/blades/content/typography";
|
|
82
|
+
@import "@anyblades/blades/components/card";
|
|
83
|
+
@import "@anyblades/blades/components/modal";
|
|
80
84
|
```
|
|
81
85
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
<div><hr></div>
|
|
85
|
-
|
|
86
|
-
Or import only the [Pico CSS](//blades.ninja/css/pico/) parts you need, e.g. per page or per component:
|
|
87
|
-
|
|
88
|
-
```css
|
|
89
|
-
@import "@anyblades/blades/pico/variables";
|
|
90
|
-
@import "@anyblades/blades/pico/layout/document";
|
|
91
|
-
@import "@anyblades/blades/pico/content/typography";
|
|
92
|
-
@import "@anyblades/blades/pico/components/card";
|
|
93
|
-
@import "@anyblades/blades/pico/components/modal";
|
|
94
|
-
```
|
|
95
|
-
|
|
96
|
-
- `variables` and `layout/document` are the minimum; keep the same order as [`src/pico/_index.css`](https://github.com/anyblades/blades/blob/main/src/pico/_index.css) (variables → layout → content → forms → components → utilities).
|
|
97
|
-
- `layout` doesn't pad `body > header/main/footer`. Add `layout/landmarks` for Pico's behaviour.
|
|
86
|
+
- `variables` and `layout/document` are the minimum; keep the same order as [src/pico/_index.css](https://github.com/anyblades/blades/blob/main/src/pico/_index.css).
|
|
98
87
|
- Some parts build on others, e.g. `components/modal` expects `components/card`, and `components/group` and `components/dropdown` expect `forms/basics` and `content/button`.
|
|
99
|
-
-
|
|
100
|
-
|
|
101
|
-
#### With bundlers and component frameworks (SvelteKit, Next.js, Nuxt, Astro, …)
|
|
102
|
-
|
|
103
|
-
Import the parts from JavaScript, i.e. the root layout and the components that use them, rather than with `@import` inside a component's `<style>` block. Use the layered parts, `@anyblades/blades/layered/*`: they are the same parts wrapped in `@layer blades`, which a JS `import` can't add by itself.
|
|
104
|
-
|
|
105
|
-
```js
|
|
106
|
-
// root layout, once: the base and every part that others build on
|
|
107
|
-
import "@anyblades/blades/layered/variables";
|
|
108
|
-
import "@anyblades/blades/layered/layout/document";
|
|
109
|
-
import "@anyblades/blades/layered/content/typography";
|
|
110
|
-
import "@anyblades/blades/layered/content/button";
|
|
111
|
-
import "@anyblades/blades/layered/forms/basics";
|
|
112
|
-
|
|
113
|
-
// in the component that renders a <dialog>
|
|
114
|
-
import "@anyblades/blades/layered/components/card";
|
|
115
|
-
import "@anyblades/blades/layered/components/modal";
|
|
116
|
-
import "@anyblades/blades/layered/components/modal-modern"; // optional: open animation without JS
|
|
117
|
-
```
|
|
118
|
-
|
|
119
|
-
```html
|
|
120
|
-
<style>
|
|
121
|
-
/* unlayered, so it wins over Blades whatever the specificity (except Blades' !important) */
|
|
122
|
-
article {
|
|
123
|
-
max-width: 40rem;
|
|
124
|
-
}
|
|
125
|
-
</style>
|
|
126
|
-
```
|
|
127
|
-
|
|
128
|
-
- Bundlers dedupe JS-side CSS imports and split them per route, so each part is downloaded and cached once and only where it's used.
|
|
129
|
-
- Blades' own parts are layered too, mostly in the same folders as Pico's: e.g. `components/modal-modern` adds the CSS-only open animation for `showModal()` on top of `components/modal`, and `components/dropdown-popover` styles `<ul popover>` / `<menu popover>` menus opened by a button. The others are `variables-blades`, `layout/columns`, `content/code-block`, `content/icon`, `forms/float-label`, `components/timeline` and `compact` (import it last, see below).
|
|
130
|
-
- Override in your component's `<style>` or `app.css`, or set `--pico-*` variables on `:root` or on an element. Unlayered CSS always wins over `@layer blades`. The usual layer caveats apply: Blades' own `!important` declarations beat yours, and if you use other layered CSS, declare the order once, before anything else is loaded. For Tailwind v4 that is `@layer theme, base, blades, components, utilities;` at the top of the CSS file you import first (before `@import "tailwindcss"`), and that file has to be imported before any `layered/*` part, because the first `@layer` the browser sees fixes the order.
|
|
131
|
-
- Parts don't `@import` the parts they build on (e.g. `components/modal` expects `components/card`, `components/group` and `components/dropdown` expect `content/button` and `forms/basics`, `components/modal-modern` expects `components/modal`, `components/dropdown-popover` expects `components/dropdown`, and the `forms/*` extras expect `forms/basics`). If they did, every route chunk would carry its own copy. Import those shared parts once, at the root or next to the part that needs them; bundlers dedupe the imports.
|
|
132
|
-
- An `@import` inside a scoped `<style>` (Svelte, Astro, Vue `scoped`) is processed as that component's own styles. The rules get scoped to the component's markup (Svelte also prunes the unused ones) and are duplicated in every component that imports them.
|
|
133
|
-
- Landmark padding: `pico.css` and `blades.ninja.css` pad `body > header`, `body > main` and `body > footer` like Pico, which doesn't match when the framework wraps the page in an element (SvelteKit's `<div style="display: contents">`, Next.js pages router `#__next`, Nuxt `#__nuxt`, a SPA's `#root` / `#app`). `blades.css` doesn't pad them; with per-part imports, add `layout/landmarks` (or `layered/layout/landmarks`) for Pico's `body >` padding.
|
|
88
|
+
- See [Layered modules](//blades.dev/css/layered/) for the available parts, and for importing them from JavaScript in bundlers and component frameworks (SvelteKit, Next.js, Nuxt, Astro, …).
|
|
89
|
+
- See [package.json](https://github.com/anyblades/blades/blob/main/package.json) for a list of all exported parts.
|
|
134
90
|
|
|
135
91
|
### <mark>D.</mark> Official starters
|
|
136
92
|
|
|
@@ -161,17 +117,94 @@ import "@anyblades/blades/layered/components/modal-modern"; // optional: open an
|
|
|
161
117
|
</html>
|
|
162
118
|
```
|
|
163
119
|
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
[Available for Nunjucks, Liquid and Twig ↗](https://blades.ninja/tpl/)<!--{role=button .outline}-->
|
|
120
|
+
Using Nunjucks, Twig or Liquid? Check out the built-in [Base HTML templates](//blades.dev/tpl/html/) for each engine, ready to be used in your project.
|
|
167
121
|
|
|
168
122
|
<!--section:gh-only-->
|
|
169
123
|
|
|
170
124
|
---
|
|
171
125
|
|
|
172
|
-
##
|
|
126
|
+
## Documentation
|
|
127
|
+
|
|
128
|
+
If you know Pico — you already know Blades:
|
|
129
|
+
|
|
130
|
+
<!-- ToC as is from https://blades.dev/#docs -->
|
|
131
|
+
<ul class="columns">
|
|
132
|
+
|
|
133
|
+
<li>
|
|
134
|
+
<strong><a href="//blades.dev/css/">Get started</a></strong>
|
|
135
|
+
<ul><li><a href="//blades.dev/css/">Quick start</a></li>
|
|
136
|
+
<li><a href="//blades.dev/css/color-schemes/">Dark scheme</a></li>
|
|
137
|
+
<li><a href="//blades.dev/css/variables/">CSS variables</a></li>
|
|
138
|
+
<li><a href="//blades.dev/css/compact/">Compact version <mark>NEW</mark></a></li>
|
|
139
|
+
<li><a href="//blades.dev/css/layered/">Layered modules <mark>NEW</mark></a></li>
|
|
140
|
+
<li><a href="//blades.dev/css/pico/">Inspired by Pico ✨</a></li>
|
|
141
|
+
<li><a href="//blades.dev/css/conditional/">Conditional styling</a></li></ul>
|
|
142
|
+
</li>
|
|
143
|
+
|
|
144
|
+
<li>
|
|
145
|
+
<strong><a href="//blades.dev/css/layout/">Layout</a></strong>
|
|
146
|
+
<ul><li><a href="//blades.dev/css/landmarks-section/">Landmarks & section</a></li>
|
|
147
|
+
<li><a href="//blades.dev/css/container/">Container</a></li>
|
|
148
|
+
<li><a href="//blades.dev/css/grid/">Grid</a></li>
|
|
149
|
+
<li><a href="//blades.dev/css/columns/">Text columns <mark>NEW</mark></a></li>
|
|
150
|
+
<li><a href="//blades.dev/css/utils/#overflow-auto">Overflow auto</a></li></ul>
|
|
151
|
+
</li>
|
|
152
|
+
|
|
153
|
+
<li>
|
|
154
|
+
<strong><a href="//blades.dev/css/content/">Content</a></strong>
|
|
155
|
+
<ul><li><a href="//blades.dev/css/typography/">Typography</a></li>
|
|
156
|
+
<li><a href="//blades.dev/css/link/">Link</a></li>
|
|
157
|
+
<li><a href="//blades.dev/css/icon/">Icon <mark>NEW</mark></a></li>
|
|
158
|
+
<li><a href="//blades.dev/css/button/">Button</a></li>
|
|
159
|
+
<li><a href="//blades.dev/css/table/">Table</a></li>
|
|
160
|
+
<li><a href="//blades.dev/css/code/">Code blocks <mark>NEW</mark></a></li></ul>
|
|
161
|
+
</li>
|
|
162
|
+
|
|
163
|
+
<li>
|
|
164
|
+
<strong><a href="//blades.dev/css/forms/">Forms</a></strong>
|
|
165
|
+
<ul><li><a href="//blades.dev/css/forms/">Overview</a></li>
|
|
166
|
+
<li><a href="//blades.dev/css/input/">Input</a></li>
|
|
167
|
+
<li><a href="//blades.dev/css/textarea/">Textarea</a></li>
|
|
168
|
+
<li><a href="//blades.dev/css/select/">Select</a></li>
|
|
169
|
+
<li><a href="//blades.dev/css/checkboxes/">Checkboxes</a></li>
|
|
170
|
+
<li><a href="//blades.dev/css/radios/">Radios</a></li>
|
|
171
|
+
<li><a href="//blades.dev/css/switch/">Switch</a></li>
|
|
172
|
+
<li><a href="//blades.dev/css/range/">Range</a></li>
|
|
173
|
+
<li><a href="//blades.dev/css/float-label/">Float labels <mark>NEW</mark></a></li></ul>
|
|
174
|
+
</li>
|
|
175
|
+
|
|
176
|
+
<li>
|
|
177
|
+
<strong><a href="//blades.dev/css/components/">Components</a></strong>
|
|
178
|
+
<ul><li><a href="//blades.dev/css/accordion/">Accordion</a></li>
|
|
179
|
+
<li><a href="//blades.dev/css/card/">Card</a></li>
|
|
180
|
+
<li><a href="//blades.dev/css/dropdown/">Dropdown <mark>UPD</mark></a></li>
|
|
181
|
+
<li><a href="//blades.dev/css/group/">Group</a></li>
|
|
182
|
+
<li><a href="//blades.dev/css/loading/">Loading</a></li>
|
|
183
|
+
<li><a href="//blades.dev/css/modal/">Modal <mark>UPD</mark></a></li>
|
|
184
|
+
<li><a href="//blades.dev/css/nav/">Navigation</a></li>
|
|
185
|
+
<li><a href="//blades.dev/css/progress/">Progress</a></li>
|
|
186
|
+
<li><a href="//blades.dev/css/tooltip/">Tooltip</a></li>
|
|
187
|
+
<li><a href="//blades.dev/css/timeline/">Timeline <mark>NEW</mark></a></li>
|
|
188
|
+
<li><a href="//blades.dev/css/utils/">Utilities</a></li></ul>
|
|
189
|
+
</li>
|
|
190
|
+
|
|
191
|
+
<li>
|
|
192
|
+
<strong><a href="//blades.dev/more/">More</a></strong>
|
|
193
|
+
<ul><li><a href="//blades.dev/tpl/">Dynamic templates <mark>NEW</mark></a></li>
|
|
194
|
+
<li><a href="//blades.dev/tpl/html/">Base HTML <mark>NEW</mark></a></li>
|
|
195
|
+
<li><a href="//blades.dev/tpl/sitemap/">Sitemap XML <mark>NEW</mark></a></li>
|
|
196
|
+
<li><a href="//blades.dev/css/ninja/">Ninja CSS <mark>NEW</mark> <sub style="">(experimental add-ons)</sub></a></li>
|
|
197
|
+
<li><a href="//blades.dev/css/frameworks/">CSS frameworks <mark>2026–2040</mark></a></li>
|
|
198
|
+
<li><a href="//buildawesome.one/">11ty / Build Awesome kit ↗</a></li></ul>
|
|
199
|
+
</li>
|
|
200
|
+
|
|
201
|
+
</ul>
|
|
202
|
+
|
|
203
|
+
<!--section:dark-mode-->
|
|
204
|
+
|
|
205
|
+
### Dark mode without a flash
|
|
173
206
|
|
|
174
|
-
With the Pico-based builds, Blades follows the OS setting by default, with no JavaScript and no flash (see [Dark scheme](//blades.
|
|
207
|
+
With the Pico-based builds, Blades follows the OS setting by default, with no JavaScript and no flash (see [Dark scheme](//blades.dev/css/color-schemes/)). To force a theme, set `data-theme="light"` or `"dark"` on `<html>`. On a nested element it works when the element paints its own background, such as `<article>`; otherwise add `background-color: var(--pico-background-color); color: var(--pico-color);`.
|
|
175
208
|
|
|
176
209
|
If you persist the user's choice, e.g. under the `localStorage` key `theme`, set the attribute **before the first paint** with a small inline script in `<head>`, e.g. in SvelteKit's `src/app.html`:
|
|
177
210
|
|
|
@@ -187,17 +220,19 @@ If you persist the user's choice, e.g. under the `localStorage` key `theme`, set
|
|
|
187
220
|
- Setting it later, e.g. in `onMount` or `useEffect`, renders the OS theme first and then switches.
|
|
188
221
|
- In a Next.js App Router layout, pass the same code as a template literal, ``<script dangerouslySetInnerHTML={{ __html: `try { … } catch {}` }} />``, and add `suppressHydrationWarning` to `<html>`, because the attribute changes before hydration.
|
|
189
222
|
|
|
190
|
-
|
|
223
|
+
<!--section:gh-only-->
|
|
224
|
+
|
|
225
|
+
### Compact sizing (opt-in)
|
|
191
226
|
|
|
192
|
-
|
|
227
|
+
<!--section:compact-->
|
|
193
228
|
|
|
194
229
|
Add `<html data-compact>` for the whole page, or put the attribute on a single element, e.g. `<form data-compact>` for one form. Without the attribute nothing changes.
|
|
195
230
|
|
|
196
231
|
- **Where it ships:**
|
|
197
232
|
- included in `blades.css`
|
|
198
233
|
- also in `blades.layered.css`
|
|
199
|
-
- with per-part imports, add `@
|
|
200
|
-
- with `pico.conditional.css`, add `@anyblades/blades/compact` after it
|
|
234
|
+
- with per-part imports, add `@anyblades/blades/compact` after the other parts
|
|
235
|
+
- with `pico.conditional.css`, add `@anyblades/blades/src/compact` after it
|
|
201
236
|
- **What changes:**
|
|
202
237
|
- smaller control padding and 1.5rem block spacing
|
|
203
238
|
- a 0.5rem radius and a 3px focus ring
|
|
@@ -207,116 +242,51 @@ Add `<html data-compact>` for the whole page, or put the attribute on a single e
|
|
|
207
242
|
- **Root font size:** on `<html>`, it also keeps the root font size at 100% instead of growing with the viewport. At 1280px wide, controls are then 38px instead of 62px. On a single element they are about 48px, because everything is sized in `rem` and the root stays as it is.
|
|
208
243
|
- **Field text size:** form controls stay at 16px, because below that iOS Safari zooms in on focus.
|
|
209
244
|
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
## Documentation
|
|
213
|
-
|
|
214
|
-
<!-- ToC as is from https://blades.ninja/#docs -->
|
|
215
|
-
<ul class="columns">
|
|
216
|
-
|
|
217
|
-
<li>
|
|
218
|
-
<strong><a href="//blades.ninja/css/">Get started</a></strong>
|
|
219
|
-
<ul><li><a href="//blades.ninja/css/">Quick start</a></li>
|
|
220
|
-
<li><a href="//blades.ninja/css/color-schemes/">Dark scheme</a></li>
|
|
221
|
-
<li><a href="//blades.ninja/css/variables/">CSS variables</a></li>
|
|
222
|
-
<li><a href="//blades.ninja/css/conditional/">Conditional styling <mark>NEW</mark></a></li>
|
|
223
|
-
<li><a href="//blades.ninja/css/standalone/">Standalone version <mark>NEW</mark></a></li></ul>
|
|
224
|
-
</li>
|
|
225
|
-
|
|
226
|
-
<li>
|
|
227
|
-
<strong><a href="//blades.ninja/css/layout/">Layout</a></strong>
|
|
228
|
-
<ul><li><a href="//blades.ninja/css/landmarks-section/">Landmarks & section</a></li>
|
|
229
|
-
<li><a href="//blades.ninja/css/container/">Container</a></li>
|
|
230
|
-
<li><a href="//blades.ninja/css/breakout/">Breakout container <mark>NEW</mark></a></li>
|
|
231
|
-
<li><a href="//blades.ninja/css/grid/">Grid</a></li>
|
|
232
|
-
<li><a href="//blades.ninja/css/columns/">Text columns <mark>NEW</mark></a></li></ul>
|
|
233
|
-
</li>
|
|
234
|
-
|
|
235
|
-
<li>
|
|
236
|
-
<strong><a href="//blades.ninja/css/content/">Content</a></strong>
|
|
237
|
-
<ul><li><a href="//blades.ninja/css/typography/">Typography <mark>UPD</mark></a></li>
|
|
238
|
-
<li><a href="//blades.ninja/css/link/">Link</a></li>
|
|
239
|
-
<li><a href="//blades.ninja/css/button/">Button</a></li>
|
|
240
|
-
<li><a href="//blades.ninja/css/icon/"><code style="padding: 0">‹i›</code>con helper <mark>NEW</mark></a></li>
|
|
241
|
-
<li><a href="//blades.ninja/css/list/">List <mark>UPD</mark></a></li>
|
|
242
|
-
<li><a href="//blades.ninja/css/table/">Table <mark>UPD</mark></a></li>
|
|
243
|
-
<li><a href="//blades.ninja/css/responsive-table/">Responsive table <mark>NEW</mark></a></li>
|
|
244
|
-
<li><a href="//blades.ninja/css/code/">Code blocks <mark>NEW</mark></a></li></ul>
|
|
245
|
-
</li>
|
|
246
|
-
|
|
247
|
-
<li>
|
|
248
|
-
<strong><a href="//blades.ninja/css/forms/">Forms</a></strong>
|
|
249
|
-
<ul><li><a href="//blades.ninja/css/forms/">Overview</a></li>
|
|
250
|
-
<li><a href="//blades.ninja/css/input/">Input</a></li>
|
|
251
|
-
<li><a href="//blades.ninja/css/textarea/">Textarea</a></li>
|
|
252
|
-
<li><a href="//blades.ninja/css/select/">Select</a></li>
|
|
253
|
-
<li><a href="//blades.ninja/css/checkboxes/">Checkboxes</a></li>
|
|
254
|
-
<li><a href="//blades.ninja/css/radios/">Radios</a></li>
|
|
255
|
-
<li><a href="//blades.ninja/css/switch/">Switch</a></li>
|
|
256
|
-
<li><a href="//blades.ninja/css/range/">Range</a></li>
|
|
257
|
-
<li><a href="//blades.ninja/css/float-label/">Float labels <mark>NEW</mark></a></li></ul>
|
|
258
|
-
</li>
|
|
245
|
+
<!--section:info-->
|
|
259
246
|
|
|
260
|
-
<
|
|
261
|
-
<strong><a href="//blades.ninja/css/components/">Components</a></strong>
|
|
262
|
-
<ul><li><a href="//blades.ninja/css/accordion/">Accordion</a></li>
|
|
263
|
-
<li><a href="//blades.ninja/css/card/">Card</a></li>
|
|
264
|
-
<li><a href="//blades.ninja/css/dropdown/">Dropdown</a></li>
|
|
265
|
-
<li><a href="//blades.ninja/css/group/">Group</a></li>
|
|
266
|
-
<li><a href="//blades.ninja/css/loading/">Loading</a></li>
|
|
267
|
-
<li><a href="//blades.ninja/css/modal/">Modal</a></li>
|
|
268
|
-
<li><a href="//blades.ninja/css/nav/">Navigation</a></li>
|
|
269
|
-
<li><a href="//blades.ninja/css/progress/">Progress</a></li>
|
|
270
|
-
<li><a href="//blades.ninja/css/tooltip/">Tooltip</a></li>
|
|
271
|
-
<li><a href="//blades.ninja/css/timeline/">Timeline <mark>NEW</mark></a></li>
|
|
272
|
-
<li><a href="//blades.ninja/css/jump/">Jump to... <mark>NEW</mark></a></li>
|
|
273
|
-
<li><a href="//blades.ninja/css/utils/">Utilities <mark>NEW</mark></a></li></ul>
|
|
274
|
-
</li>
|
|
247
|
+
## <sup style>Trusted by</sup>
|
|
275
248
|
|
|
276
|
-
<
|
|
277
|
-
<strong><a href="//blades.ninja/more/">More</a></strong>
|
|
278
|
-
<ul><li><a href="//blades.ninja/css/pico/">Pico CSS <mark>NEW</mark> <sub style="">(underlying fork)</sub></a></li>
|
|
279
|
-
<li><a href="//blades.ninja/css/ninja/">Ninja CSS <mark>NEW</mark> <sub style="">(experimental add-ons)</sub></a></li>
|
|
280
|
-
<li><a href="//blades.ninja/html/">Dynamic templates <mark>NEW</mark></a></li>
|
|
281
|
-
<li><a href="//blades.ninja/html/base/">Base HTML <mark>NEW</mark></a></li>
|
|
282
|
-
<li><a href="//blades.ninja/html/links/">Links snippet <mark>NEW</mark></a></li>
|
|
283
|
-
<li><a href="//blades.ninja/html/sitemap/">Sitemap XML <mark>NEW</mark></a></li>
|
|
284
|
-
<li><a href="//blades.ninja/css/frameworks/">CSS frameworks <mark>2026–2040</mark></a></li></ul>
|
|
285
|
-
</li>
|
|
249
|
+
<big>
|
|
286
250
|
|
|
287
|
-
|
|
251
|
+
- [<i>🐍</i> Flask & Jinja](https://palletsprojects.com/) community website
|
|
252
|
+
- [Grav CMS v2](https://getgrav.org/migrate-to-2#:~:text=blades) default theme
|
|
253
|
+
- [FastHTML](https://www.fastht.ml/docs/api/pico.html) Pico components [↗](https://github.com/AnswerDotAI/fasthtml/blob/main/fasthtml/pico.py)
|
|
288
254
|
|
|
289
|
-
|
|
255
|
+
<!--{.markerless}-->
|
|
290
256
|
|
|
291
|
-
|
|
257
|
+
</big>
|
|
292
258
|
|
|
293
|
-
|
|
294
|
-
- 🪐 [Grav CMS v2](https://getgrav.org/migrate-to-2#:~:text=blades) default theme [↗](https://www.followthatcar.com/)
|
|
259
|
+
## <sup style>Showcase</sup> <!--A-Z-->
|
|
295
260
|
|
|
296
|
-
|
|
261
|
+
- [000000076.xyz](//000000076.xyz/)
|
|
262
|
+
- [1k.football](//1k.football/)
|
|
263
|
+
- [buildawesome.one](//buildawesome.one/)
|
|
264
|
+
- [doany.io](//doany.io/) [↗](https://b.doany.io/en/posts/svelte-bun-sqlite/#on-biome-and-css:~:text=anyblades)
|
|
265
|
+
- [followthatcar.com](//followthatcar.com/)
|
|
266
|
+
- [greenroom.pudiga.org](//greenroom.pudiga.org/)
|
|
267
|
+
- [knives.ajitpanigrahi.com](//knives.ajitpanigrahi.com/)
|
|
268
|
+
- [robotics.spprep.org](//robotics.spprep.org/)
|
|
269
|
+
- [usehadron.dev](//usehadron.dev/#:~:text=blades)
|
|
297
270
|
|
|
298
|
-
<!--
|
|
271
|
+
<!--{.columns}-->
|
|
299
272
|
|
|
300
|
-
## <sup style>Featured by</sup> <!--
|
|
273
|
+
## <sup style>Featured by</sup> <!--by host-->
|
|
301
274
|
|
|
302
|
-
- [getgrav.org](https://getgrav.org/migrate-to-2#:~:text=blades)
|
|
303
|
-
- https://usehadron.dev/
|
|
304
275
|
- [@11ty/buildawesome](https://bsky.app/profile/11ty.dev/post/3mp75r53ccv2b) [↗](https://mastodon.social/@11ty@neighborhood.11ty.dev/116816881367741413)
|
|
305
|
-
- [
|
|
306
|
-
- https://github.com/dbohdan/classless-css
|
|
307
|
-
- https://github.com/uhub/awesome-css
|
|
308
|
-
- [/gabrielizalo/awesome-css-frameworks](https://github.com/gabrielizalo/awesome-css-frameworks-and-ui-libraries/tree/master/Lightweight)
|
|
309
|
-
- https://github.com/eggplantpasta/greenroom
|
|
310
|
-
- [/adamdjbrett/11ty-wisp](https://github.com/adamdjbrett/11ty-wisp#features:~:text=blades) [↗](https://github.com/adamdjbrett/000000076#:~:text=blades)
|
|
311
|
-
- [doany.io](https://doany.io/en/posts/svelte-bun-sqlite/#on-biome-and-css:~:text=anyblades)
|
|
276
|
+
- [@matthewmorete](https://bsky.app/profile/matthewmorete.com/post/3mx5wvywixc2l)
|
|
312
277
|
- [@box464](https://mastodon.social/@box464/117442493473921346)
|
|
313
|
-
- [@draupnerdata](https://www.youtube.com/watch?v=yDjArj9HSjs&t=180s)
|
|
314
|
-
- [@cantdutchthis](https://news.ycombinator.com/item?id=48729467)
|
|
315
|
-
- [@daviding](https://www.reddit.com/r/Wordpress/comments/1vnfhkr/comment/p3k9z1c/#:~:text=blades)
|
|
316
|
-
- [@infotexture](https://mastodon.social/@infotexture@indieweb.social/117294194740314396)
|
|
317
278
|
- [@lazarus](https://fosstodon.org/@lazarus/117384358792615667)
|
|
318
|
-
- [@matthewmorete](https://bsky.app/profile/matthewmorete.com/post/3mx5wvywixc2l)
|
|
319
279
|
- [@pauleveritt](https://fosstodon.org/@pauleveritt/116387278969347700)
|
|
280
|
+
- [@cantdutchthis](https://news.ycombinator.com/item?id=48729467)
|
|
281
|
+
- [@daviding](https://www.reddit.com/r/Wordpress/comments/1vnfhkr/comment/p3k9z1c/#:~:text=blades)
|
|
282
|
+
- [@dbohdan/classless-css](https://github.com/dbohdan/classless-css)
|
|
283
|
+
- [@gabrielizalo/css-frameworks](https://github.com/gabrielizalo/awesome-css-frameworks-and-ui-libraries/tree/master/Lightweight)
|
|
284
|
+
- [@uhub/awesome-css](https://github.com/uhub/awesome-css)
|
|
285
|
+
- [@draupnerdata](https://www.youtube.com/watch?v=yDjArj9HSjs&t=180s)
|
|
320
286
|
|
|
321
287
|
<!--{.markerless .columns}-->
|
|
322
|
-
|
|
288
|
+
|
|
289
|
+
<!--
|
|
290
|
+
> [!IMPORTANT]
|
|
291
|
+
> **Work in progress** — information below is under review:
|
|
292
|
+
-->
|
package/css/blades.css
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Blades CSS v3 with Pico CSS 🥷✨
|
|
3
|
-
* Copyright 2026 (https://blades.
|
|
3
|
+
* Copyright 2026 (https://blades.dev/)
|
|
4
4
|
* Licensed under MIT
|
|
5
5
|
*/
|
|
6
6
|
/*!
|
|
7
7
|
* Blades CSS' Pico fork v2.5 🥷✨
|
|
8
8
|
* Copyright 2019-2025 (https://picocss.com)
|
|
9
|
-
* Copyright 2026 (https://blades.
|
|
9
|
+
* Copyright 2026 (https://blades.dev/css/pico/)
|
|
10
10
|
* Licensed under MIT
|
|
11
11
|
*/
|
|
12
12
|
/*!
|
|
13
13
|
* Blades CSS standalone kit v3 🥷
|
|
14
|
-
* Copyright 2026 (https://blades.
|
|
14
|
+
* Copyright 2026 (https://blades.dev/css/standalone/)
|
|
15
15
|
* Licensed under MIT
|
|
16
16
|
*/
|
|
17
17
|
/*!
|
|
18
18
|
* Float Label CSS v2 by Blades CSS 🥷🏷️
|
|
19
|
-
* Copyright 2016–2026 (https://blades.
|
|
19
|
+
* Copyright 2016–2026 (https://blades.dev/css/float-label/)
|
|
20
20
|
* Licensed under MIT
|
|
21
21
|
*/
|
|
22
22
|
:scope, :host {
|