actual-css 0.3.1 → 0.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/CHANGELOG.md +67 -3
- package/README.md +35 -30
- package/dist/actual.css +73 -4946
- package/dist/actual.full.css +7090 -0
- package/dist/actual.full.js +1 -0
- package/dist/actual.full.min.css +1 -0
- package/dist/actual.js +1 -1
- package/dist/actual.min.css +1 -1
- package/docs/design-notes/cascade-layer.md +34 -13
- package/docs/design-notes/column-layout.md +677 -0
- package/docs/design-notes/forced-colors.md +3 -0
- package/docs/design-notes/grid.md +612 -0
- package/docs/design-notes/naming.md +15 -0
- package/docs/design-notes/widget-primitives.md +1 -0
- package/docs/navigation.json +5 -1
- package/docs/pages/components/alert.md +16 -14
- package/docs/pages/components/aura.md +1 -1
- package/docs/pages/components/avatar.md +6 -6
- package/docs/pages/components/badge.md +7 -7
- package/docs/pages/components/button.md +16 -16
- package/docs/pages/components/card.md +13 -9
- package/docs/pages/components/chat.md +8 -8
- package/docs/pages/components/dialog.md +7 -7
- package/docs/pages/components/drawer.md +3 -3
- package/docs/pages/components/fab.md +7 -7
- package/docs/pages/components/navbar.md +9 -8
- package/docs/pages/components/pagination.md +4 -3
- package/docs/pages/components/skeleton.md +4 -4
- package/docs/pages/components/spinner.md +5 -5
- package/docs/pages/components/table.md +30 -5
- package/docs/pages/enhancements/flyout.md +13 -13
- package/docs/pages/enhancements/overview.md +1 -1
- package/docs/pages/enhancements/scrollspy.md +6 -6
- package/docs/pages/enhancements/status-bar.md +5 -1
- package/docs/pages/enhancements/tabs.md +6 -6
- package/docs/pages/enhancements/tooltip.md +1 -1
- package/docs/pages/examples/overview.md +39 -22
- package/docs/pages/forms/choice-cards.md +11 -6
- package/docs/pages/forms/controls.md +1 -1
- package/docs/pages/forms/detached-actions.md +1 -1
- package/docs/pages/forms/floating-field.md +10 -5
- package/docs/pages/forms/form-actions.md +1 -1
- package/docs/pages/forms/input-policy.md +1 -1
- package/docs/pages/forms/joined-controls.md +4 -4
- package/docs/pages/forms/labels.md +6 -6
- package/docs/pages/forms/otp.md +1 -1
- package/docs/pages/forms/overview.md +19 -19
- package/docs/pages/forms/password.md +1 -1
- package/docs/pages/forms/range.md +1 -1
- package/docs/pages/forms/states-and-sizes.md +41 -45
- package/docs/pages/forms/sticky-actions.md +3 -3
- package/docs/pages/forms/switch.md +110 -2
- package/docs/pages/forms/validation.md +9 -9
- package/docs/pages/foundations/philosophy.md +1 -1
- package/docs/pages/foundations/theming.md +17 -2
- package/docs/pages/foundations/tokens.md +22 -10
- package/docs/pages/foundations/typography.md +50 -20
- package/docs/pages/guides/bootstrap.md +11 -11
- package/docs/pages/guides/integrating-actual-css.md +186 -0
- package/docs/pages/guides/introduction.md +23 -26
- package/docs/pages/guides/modular-import.md +173 -0
- package/docs/pages/guides/progressive-enhancement.md +81 -78
- package/docs/pages/guides/tailwind.md +6 -8
- package/docs/pages/layout/app-shell.md +1 -1
- package/docs/pages/layout/center.md +1 -1
- package/docs/pages/layout/choosing.md +39 -0
- package/docs/pages/layout/column-layout.md +206 -0
- package/docs/pages/layout/frame.md +6 -1
- package/docs/pages/layout/grid.md +100 -102
- package/docs/pages/layout/list.md +1 -1
- package/docs/pages/layout/media.md +1 -1
- package/docs/pages/layout/overview.md +15 -2
- package/docs/pages/layout/scroll-snap.md +2 -2
- package/docs/pages/layout/scroll-target.md +45 -0
- package/docs/pages/layout/sidebar-layout.md +20 -19
- package/docs/pages/layout/stack.md +53 -1
- package/docs/pages/layout/switcher.md +10 -26
- package/docs/pages/layout/topbar.md +2 -2
- package/docs/pages/patterns/actions.md +1 -1
- package/docs/pages/patterns/code-block.md +1 -1
- package/docs/pages/patterns/exclusive-accordion.md +1 -1
- package/docs/pages/patterns/hierarchical-nav.md +1 -1
- package/docs/pages/patterns/icon-input.md +1 -1
- package/docs/pages/patterns/intent-nesting.md +1 -1
- package/docs/pages/patterns/navigation-list.md +1 -1
- package/docs/pages/patterns/overview.md +1 -1
- package/docs/pages/patterns/structured-lists.md +1 -1
- package/docs/pages/utilities/accessibility.md +3 -3
- package/docs/pages/utilities/flex.md +15 -15
- package/docs/pages/utilities/links.md +4 -4
- package/docs/pages/utilities/list.md +8 -8
- package/docs/pages/utilities/overflow.md +8 -8
- package/docs/pages/utilities/overview.md +1 -1
- package/docs/pages/utilities/shape.md +3 -3
- package/docs/pages/utilities/sizing-wrapping.md +23 -16
- package/docs/pages/utilities/spacing.md +20 -20
- package/docs/pages/utilities/text.md +10 -10
- package/llms.txt +46 -4
- package/package.json +42 -13
- package/scripts/reserved-classes.json +261 -0
- package/src/cli/actual-css.js +133 -0
- package/src/css/actual.css +1 -31
- package/src/css/actual.full.css +11 -2
- package/src/css/components/alert.css +17 -4
- package/src/css/components/badge.css +18 -6
- package/src/css/components/breadcrumb.css +1 -1
- package/src/css/components/button.css +19 -1
- package/src/css/components/card.css +27 -2
- package/src/css/components/drawer.css +27 -2
- package/src/css/components/flyout.css +5 -0
- package/src/css/components/index.css +32 -27
- package/src/css/components/join.css +8 -1
- package/src/css/components/key.css +2 -0
- package/src/css/components/menu.css +11 -1
- package/src/css/components/meter.css +4 -1
- package/src/css/components/modal.css +5 -0
- package/src/css/components/pagination.css +11 -0
- package/src/css/components/spinner.css +5 -0
- package/src/css/components/status-bar.css +5 -0
- package/src/css/components/surface.css +5 -0
- package/src/css/components/table.css +6 -0
- package/src/css/components/tooltip.css +5 -0
- package/src/css/core/index.css +9 -0
- package/src/css/core/print.css +18 -0
- package/src/css/{theme.css → core/theme.css} +20 -10
- package/src/css/{tokens.css → core/tokens.css} +15 -2
- package/src/css/{variants.css → core/variants.css} +3 -2
- package/src/css/effects/index.css +2 -0
- package/src/css/forms/base.css +8 -0
- package/src/css/forms/choice-card.css +5 -4
- package/src/css/forms/choice.css +49 -37
- package/src/css/forms/control.css +4 -1
- package/src/css/forms/custom-select.css +2 -0
- package/src/css/{optional → forms}/floating-field.css +25 -7
- package/src/css/forms/index.css +10 -13
- package/src/css/forms/native.css +15 -2
- package/src/css/{optional → forms}/otp.css +20 -16
- package/src/css/forms/switch.css +31 -29
- package/src/css/layout/app-shell.css +6 -0
- package/src/css/layout/center.css +13 -0
- package/src/css/layout/cluster.css +21 -0
- package/src/css/layout/column-layout.css +144 -0
- package/src/css/layout/container-query.css +13 -0
- package/src/css/layout/frame.css +19 -0
- package/src/css/layout/grid.css +141 -0
- package/src/css/layout/index.css +42 -0
- package/src/css/layout/measure.css +9 -0
- package/src/css/layout/media.css +10 -0
- package/src/css/layout/scroll-target.css +15 -0
- package/src/css/layout/scroller.css +41 -0
- package/src/css/layout/sidebar-layout.css +31 -0
- package/src/css/layout/stack.css +21 -0
- package/src/css/layout/switcher.css +23 -0
- package/src/css/{optional/layout-extra.css → layout/topbar.css} +0 -20
- package/src/css/typography/index.css +5 -0
- package/src/css/typography/lead.css +7 -0
- package/src/css/{components → typography}/overline.css +2 -2
- package/src/css/{prose.css → typography/prose.css} +53 -38
- package/src/css/{utilities.css → utilities/base.css} +2 -0
- package/src/css/utilities/index.css +3 -0
- package/src/js/escape.js +36 -0
- package/src/js/flyout.js +22 -12
- package/src/js/full.js +26 -0
- package/src/js/index.js +5 -21
- package/src/js/surface.js +1 -31
- package/src/js/tooltip.js +46 -18
- package/src/js/validation.js +1 -1
- package/src/tooling/css-bundle.js +308 -0
- package/dist/actual-themes.min.css +0 -1
- package/dist/optional.css +0 -1048
- package/dist/optional.min.css +0 -1
- package/docs/pages/guides/optional-components.md +0 -33
- package/src/css/grid.css +0 -109
- package/src/css/layout.css +0 -123
- package/src/css/optional/index.css +0 -10
- package/src/css/optional/scroller.css +0 -63
- package/src/css/print.css +0 -47
- package/src/css/themes/corporate.css +0 -60
- package/src/css/themes/cyberpunk.css +0 -60
- package/src/css/themes/dim.css +0 -33
- package/src/css/themes/edge.css +0 -117
- package/src/css/themes/forest.css +0 -65
- package/src/css/themes/gradient.css +0 -97
- package/src/css/themes/index.css +0 -47
- package/src/css/themes/indigo.css +0 -33
- package/src/css/themes/lavender.css +0 -66
- package/src/css/themes/mono.css +0 -60
- package/src/css/themes/neon.css +0 -66
- package/src/css/themes/ocean.css +0 -60
- package/src/css/themes/petrol.css +0 -64
- package/src/css/themes/spruce.css +0 -64
- package/src/css/themes/square.css +0 -65
- package/src/css/themes/sunset.css +0 -66
- /package/src/css/{optional → components}/chat.css +0 -0
- /package/src/css/{optional → components}/fab.css +0 -0
- /package/src/css/{base.css → core/base.css} +0 -0
- /package/src/css/{focus.css → core/focus.css} +0 -0
- /package/src/css/{intents.css → core/intents.css} +0 -0
- /package/src/css/{reset.css → core/reset.css} +0 -0
- /package/src/css/{optional → effects}/aura.css +0 -0
- /package/src/css/{optional → layout}/scroll-snap.css +0 -0
- /package/src/css/{optional/typography-fluid.css → typography/fluid.css} +0 -0
- /package/src/css/{optional/utilities-extra.css → utilities/extra.css} +0 -0
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "actual-css",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "Plain CSS component framework with semantic classes, universal variants, small tokens, theme hooks, and progressive enhancements.",
|
|
5
5
|
"type": "module",
|
|
6
|
-
"packageManager": "bun@1.
|
|
6
|
+
"packageManager": "bun@1.4.0",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"author": "Thomas <thomas@lekoala.be>",
|
|
9
9
|
"repository": {
|
|
@@ -27,19 +27,32 @@
|
|
|
27
27
|
],
|
|
28
28
|
"exports": {
|
|
29
29
|
".": "./dist/actual.min.css",
|
|
30
|
+
"./full": "./dist/actual.full.min.css",
|
|
30
31
|
"./css": "./src/css/actual.css",
|
|
31
|
-
"./css/layer": "./src/css/actual.layer.css",
|
|
32
32
|
"./css/components": "./src/css/components/index.css",
|
|
33
|
-
"./css/
|
|
34
|
-
"./css/
|
|
33
|
+
"./css/components/*": "./src/css/components/*.css",
|
|
34
|
+
"./css/effects": "./src/css/effects/index.css",
|
|
35
|
+
"./css/effects/*": "./src/css/effects/*.css",
|
|
36
|
+
"./css/forms": "./src/css/forms/base.css",
|
|
37
|
+
"./css/forms/all": "./src/css/forms/index.css",
|
|
38
|
+
"./css/forms/*": "./src/css/forms/*.css",
|
|
39
|
+
"./css/full": "./src/css/actual.full.css",
|
|
40
|
+
"./css/layer": "./src/css/actual.layer.css",
|
|
41
|
+
"./css/layout": "./src/css/layout/index.css",
|
|
42
|
+
"./css/layout/*": "./src/css/layout/*.css",
|
|
35
43
|
"./css/themes": null,
|
|
36
44
|
"./css/themes/*": null,
|
|
37
|
-
"./css
|
|
45
|
+
"./css/typography": "./src/css/typography/index.css",
|
|
46
|
+
"./css/typography/*": "./src/css/typography/*.css",
|
|
47
|
+
"./css/utilities": "./src/css/utilities/index.css",
|
|
48
|
+
"./css/utilities/*": "./src/css/utilities/*.css",
|
|
38
49
|
"./js": "./src/js/index.js",
|
|
50
|
+
"./js/full": "./src/js/full.js",
|
|
39
51
|
"./js/command": "./src/js/command.js",
|
|
40
52
|
"./js/context-menu": "./src/js/context-menu.js",
|
|
41
53
|
"./js/dialog": "./src/js/dialog.js",
|
|
42
54
|
"./js/dismiss": "./src/js/dismiss.js",
|
|
55
|
+
"./js/escape": "./src/js/escape.js",
|
|
43
56
|
"./js/enhance": "./src/js/enhance.js",
|
|
44
57
|
"./js/enhancement-loader": "./src/js/enhancement-loader.js",
|
|
45
58
|
"./js/parse-config": "./src/js/parse-config.js",
|
|
@@ -61,8 +74,12 @@
|
|
|
61
74
|
"./js/validation": "./src/js/validation.js",
|
|
62
75
|
"./js/status": "./src/js/status.js",
|
|
63
76
|
"./js/surface": "./src/js/surface.js",
|
|
77
|
+
"./reserved-classes.json": "./scripts/reserved-classes.json",
|
|
64
78
|
"./package.json": "./package.json"
|
|
65
79
|
},
|
|
80
|
+
"bin": {
|
|
81
|
+
"actual-css": "./src/cli/actual-css.js"
|
|
82
|
+
},
|
|
66
83
|
"main": "./dist/actual.js",
|
|
67
84
|
"style": "./dist/actual.min.css",
|
|
68
85
|
"unpkg": "./dist/actual.min.css",
|
|
@@ -71,11 +88,17 @@
|
|
|
71
88
|
"files": [
|
|
72
89
|
"dist",
|
|
73
90
|
"src/css/*.css",
|
|
74
|
-
"src/css/
|
|
91
|
+
"src/css/core",
|
|
92
|
+
"src/css/layout",
|
|
93
|
+
"src/css/typography",
|
|
75
94
|
"src/css/forms",
|
|
76
|
-
"src/css/
|
|
77
|
-
"src/css/
|
|
95
|
+
"src/css/components",
|
|
96
|
+
"src/css/effects",
|
|
97
|
+
"src/css/utilities",
|
|
98
|
+
"src/cli",
|
|
78
99
|
"src/js",
|
|
100
|
+
"src/tooling",
|
|
101
|
+
"scripts/reserved-classes.json",
|
|
79
102
|
"docs",
|
|
80
103
|
"CHANGELOG.md",
|
|
81
104
|
"llms.txt",
|
|
@@ -83,20 +106,25 @@
|
|
|
83
106
|
"README.md"
|
|
84
107
|
],
|
|
85
108
|
"engines": {
|
|
86
|
-
"bun": ">=1.
|
|
109
|
+
"bun": ">=1.4.0",
|
|
110
|
+
"node": ">=18"
|
|
87
111
|
},
|
|
88
112
|
"scripts": {
|
|
89
113
|
"lint": "biome check",
|
|
90
114
|
"lint:fix": "biome check --write",
|
|
91
|
-
"build:docs": "bun scripts/build-docs.js",
|
|
92
|
-
"watch:docs": "bun scripts/build-docs.js --watch",
|
|
115
|
+
"build:docs": "bun run build:themes && bun scripts/build-docs.js",
|
|
116
|
+
"watch:docs": "bun run build:themes && bun scripts/build-docs.js --watch",
|
|
93
117
|
"check:docs": "bun scripts/check-docs.js",
|
|
94
118
|
"check:compat": "bun scripts/check-compat.js",
|
|
95
119
|
"check:css-api": "bun scripts/check-css-api.js",
|
|
120
|
+
"check:color-space": "bun scripts/check-color-space.js",
|
|
121
|
+
"check:architecture": "bun scripts/check-css-architecture.js",
|
|
96
122
|
"build:dist": "bun scripts/build-dist.js",
|
|
97
123
|
"build:js": "bun scripts/build-js.js",
|
|
124
|
+
"build:themes": "bun scripts/build-themes.js",
|
|
98
125
|
"build:size": "bun scripts/build-size.js",
|
|
99
126
|
"check:enhance": "bun run scripts/check-enhance.js",
|
|
127
|
+
"generate:reserved": "bun scripts/generate-reserved-classes.js",
|
|
100
128
|
"check:reserved": "bun scripts/check-reserved.js",
|
|
101
129
|
"check:links": "bun scripts/check-doc-links.js",
|
|
102
130
|
"check:templates": "bun scripts/check-templates.js",
|
|
@@ -106,7 +134,8 @@
|
|
|
106
134
|
"probe": "bun scripts/probe.js",
|
|
107
135
|
"check:sync": "bun scripts/check-sync.js",
|
|
108
136
|
"test": "bun test",
|
|
109
|
-
"
|
|
137
|
+
"test:changed": "bun test --changed=master",
|
|
138
|
+
"build:all": "bun run lint && bun run build:dist && bun run build:js && bun run build:docs && bun run check:docs && bun run check:compat && bun run check:css-api && bun run check:color-space && bun run check:architecture && bun run check:enhance && bun run generate:reserved && bun run check:reserved && bun run check:sync && bun run check:links && bun run check:templates && bun run test && bun run build:size",
|
|
110
139
|
"prepublishOnly": "bun run build:all"
|
|
111
140
|
},
|
|
112
141
|
"devDependencies": {
|
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
[
|
|
2
|
+
"accordion",
|
|
3
|
+
"actions",
|
|
4
|
+
"admonition",
|
|
5
|
+
"alert",
|
|
6
|
+
"alert-body",
|
|
7
|
+
"alert-dismiss",
|
|
8
|
+
"alert-icon",
|
|
9
|
+
"alert-title",
|
|
10
|
+
"align-self-center",
|
|
11
|
+
"align-self-end",
|
|
12
|
+
"align-self-start",
|
|
13
|
+
"app-shell",
|
|
14
|
+
"aura",
|
|
15
|
+
"aura-glow",
|
|
16
|
+
"avatar",
|
|
17
|
+
"avatar-stack",
|
|
18
|
+
"background-raised",
|
|
19
|
+
"background-subtle",
|
|
20
|
+
"background-surface",
|
|
21
|
+
"badge",
|
|
22
|
+
"bleed",
|
|
23
|
+
"block-size-full",
|
|
24
|
+
"border-block-end",
|
|
25
|
+
"border-block-start",
|
|
26
|
+
"border-context",
|
|
27
|
+
"border-inline-end",
|
|
28
|
+
"border-inline-start",
|
|
29
|
+
"breadcrumb",
|
|
30
|
+
"btn",
|
|
31
|
+
"callout",
|
|
32
|
+
"card",
|
|
33
|
+
"center",
|
|
34
|
+
"chat",
|
|
35
|
+
"chat-avatar",
|
|
36
|
+
"chat-bubble",
|
|
37
|
+
"chat-end",
|
|
38
|
+
"chat-footer",
|
|
39
|
+
"chat-header",
|
|
40
|
+
"chat-start",
|
|
41
|
+
"check",
|
|
42
|
+
"choice",
|
|
43
|
+
"choice-card",
|
|
44
|
+
"circle",
|
|
45
|
+
"cluster",
|
|
46
|
+
"color",
|
|
47
|
+
"column-gap-context",
|
|
48
|
+
"column-layout",
|
|
49
|
+
"column-span-1",
|
|
50
|
+
"column-span-10",
|
|
51
|
+
"column-span-11",
|
|
52
|
+
"column-span-12",
|
|
53
|
+
"column-span-2",
|
|
54
|
+
"column-span-3",
|
|
55
|
+
"column-span-4",
|
|
56
|
+
"column-span-5",
|
|
57
|
+
"column-span-6",
|
|
58
|
+
"column-span-7",
|
|
59
|
+
"column-span-8",
|
|
60
|
+
"column-span-9",
|
|
61
|
+
"column-start-1",
|
|
62
|
+
"column-start-10",
|
|
63
|
+
"column-start-11",
|
|
64
|
+
"column-start-12",
|
|
65
|
+
"column-start-2",
|
|
66
|
+
"column-start-3",
|
|
67
|
+
"column-start-4",
|
|
68
|
+
"column-start-5",
|
|
69
|
+
"column-start-6",
|
|
70
|
+
"column-start-7",
|
|
71
|
+
"column-start-8",
|
|
72
|
+
"column-start-9",
|
|
73
|
+
"compact",
|
|
74
|
+
"container-query",
|
|
75
|
+
"cursor-pointer",
|
|
76
|
+
"danger",
|
|
77
|
+
"dialog-close",
|
|
78
|
+
"dialog-confirmation",
|
|
79
|
+
"dialog-icon",
|
|
80
|
+
"display-block",
|
|
81
|
+
"display-flex",
|
|
82
|
+
"display-grid",
|
|
83
|
+
"display-inline",
|
|
84
|
+
"display-inline-block",
|
|
85
|
+
"display-inline-flex",
|
|
86
|
+
"display-none",
|
|
87
|
+
"dot",
|
|
88
|
+
"drawer",
|
|
89
|
+
"drawer-close",
|
|
90
|
+
"fab",
|
|
91
|
+
"fab-action",
|
|
92
|
+
"fab-actions",
|
|
93
|
+
"fab-label",
|
|
94
|
+
"field",
|
|
95
|
+
"field-error",
|
|
96
|
+
"field-group",
|
|
97
|
+
"field-help",
|
|
98
|
+
"field-label",
|
|
99
|
+
"file",
|
|
100
|
+
"fit",
|
|
101
|
+
"flex-nowrap",
|
|
102
|
+
"flex-wrap",
|
|
103
|
+
"floating-field",
|
|
104
|
+
"flyout",
|
|
105
|
+
"flyout-trigger",
|
|
106
|
+
"font-weight-bold",
|
|
107
|
+
"font-weight-medium",
|
|
108
|
+
"font-weight-normal",
|
|
109
|
+
"font-weight-strong",
|
|
110
|
+
"form-actions",
|
|
111
|
+
"frame",
|
|
112
|
+
"gap-context",
|
|
113
|
+
"gap-lg",
|
|
114
|
+
"gap-md",
|
|
115
|
+
"gap-none",
|
|
116
|
+
"gap-sm",
|
|
117
|
+
"ghost",
|
|
118
|
+
"grid",
|
|
119
|
+
"grid-2",
|
|
120
|
+
"grid-3",
|
|
121
|
+
"grid-4",
|
|
122
|
+
"grid-6",
|
|
123
|
+
"grow",
|
|
124
|
+
"had-scrollbar",
|
|
125
|
+
"has-modal-open",
|
|
126
|
+
"icon-only",
|
|
127
|
+
"inline-size-full",
|
|
128
|
+
"input",
|
|
129
|
+
"input-icon",
|
|
130
|
+
"inverted",
|
|
131
|
+
"is-open",
|
|
132
|
+
"is-sheet",
|
|
133
|
+
"is-static",
|
|
134
|
+
"items-center",
|
|
135
|
+
"items-end",
|
|
136
|
+
"items-start",
|
|
137
|
+
"join",
|
|
138
|
+
"join-addon",
|
|
139
|
+
"justify-content-center",
|
|
140
|
+
"justify-content-end",
|
|
141
|
+
"justify-content-space-between",
|
|
142
|
+
"justify-content-start",
|
|
143
|
+
"key",
|
|
144
|
+
"lead",
|
|
145
|
+
"lg",
|
|
146
|
+
"link",
|
|
147
|
+
"link-muted",
|
|
148
|
+
"link-plain",
|
|
149
|
+
"list-reset",
|
|
150
|
+
"margin-block-end-auto",
|
|
151
|
+
"margin-block-start-auto",
|
|
152
|
+
"margin-inline-auto",
|
|
153
|
+
"margin-inline-end-auto",
|
|
154
|
+
"margin-inline-start-auto",
|
|
155
|
+
"max-inline-size-none",
|
|
156
|
+
"mbe",
|
|
157
|
+
"mbs",
|
|
158
|
+
"measure",
|
|
159
|
+
"media",
|
|
160
|
+
"menu",
|
|
161
|
+
"menu-item",
|
|
162
|
+
"menu-item-end",
|
|
163
|
+
"menu-item-icon",
|
|
164
|
+
"menu-item-text",
|
|
165
|
+
"menu-label",
|
|
166
|
+
"menu-separator",
|
|
167
|
+
"meter",
|
|
168
|
+
"min-block-size-0",
|
|
169
|
+
"min-inline-size-0",
|
|
170
|
+
"modal",
|
|
171
|
+
"muted",
|
|
172
|
+
"native",
|
|
173
|
+
"nav-link",
|
|
174
|
+
"nav-list",
|
|
175
|
+
"navbar",
|
|
176
|
+
"navbar-brand",
|
|
177
|
+
"navbar-nav",
|
|
178
|
+
"needs-validation",
|
|
179
|
+
"neutral",
|
|
180
|
+
"otp",
|
|
181
|
+
"outline",
|
|
182
|
+
"overflow-auto",
|
|
183
|
+
"overflow-clip",
|
|
184
|
+
"overflow-hidden",
|
|
185
|
+
"overflow-x-auto",
|
|
186
|
+
"overflow-y-auto",
|
|
187
|
+
"overline",
|
|
188
|
+
"padding-context",
|
|
189
|
+
"pagination",
|
|
190
|
+
"pill",
|
|
191
|
+
"pointer-events-none",
|
|
192
|
+
"position-absolute",
|
|
193
|
+
"position-fixed",
|
|
194
|
+
"position-relative",
|
|
195
|
+
"position-sticky",
|
|
196
|
+
"primary",
|
|
197
|
+
"progress",
|
|
198
|
+
"prose",
|
|
199
|
+
"px",
|
|
200
|
+
"py",
|
|
201
|
+
"radio",
|
|
202
|
+
"radius-context",
|
|
203
|
+
"radius-lg-context",
|
|
204
|
+
"radius-sm-context",
|
|
205
|
+
"raised",
|
|
206
|
+
"range",
|
|
207
|
+
"required-mark",
|
|
208
|
+
"row-gap-context",
|
|
209
|
+
"scroll-snap",
|
|
210
|
+
"scroll-target",
|
|
211
|
+
"scrollable",
|
|
212
|
+
"scroller",
|
|
213
|
+
"scrollspy",
|
|
214
|
+
"secondary",
|
|
215
|
+
"select",
|
|
216
|
+
"shadow-context",
|
|
217
|
+
"shadow-popout-context",
|
|
218
|
+
"sidebar-layout",
|
|
219
|
+
"skeleton",
|
|
220
|
+
"sm",
|
|
221
|
+
"soft",
|
|
222
|
+
"solid",
|
|
223
|
+
"spinner",
|
|
224
|
+
"sr-only",
|
|
225
|
+
"stable-gutter",
|
|
226
|
+
"stack",
|
|
227
|
+
"status-bar",
|
|
228
|
+
"sticky",
|
|
229
|
+
"stretch",
|
|
230
|
+
"subtle",
|
|
231
|
+
"success",
|
|
232
|
+
"surface-backdrop",
|
|
233
|
+
"switch",
|
|
234
|
+
"switcher",
|
|
235
|
+
"tab",
|
|
236
|
+
"table",
|
|
237
|
+
"table-wrap",
|
|
238
|
+
"tabs",
|
|
239
|
+
"text-balance",
|
|
240
|
+
"text-break",
|
|
241
|
+
"text-capitalize",
|
|
242
|
+
"text-center",
|
|
243
|
+
"text-display",
|
|
244
|
+
"text-end",
|
|
245
|
+
"text-lead",
|
|
246
|
+
"text-lowercase",
|
|
247
|
+
"text-nowrap",
|
|
248
|
+
"text-pretty",
|
|
249
|
+
"text-start",
|
|
250
|
+
"text-title",
|
|
251
|
+
"text-uppercase",
|
|
252
|
+
"textarea",
|
|
253
|
+
"tooltip",
|
|
254
|
+
"topbar",
|
|
255
|
+
"truncate",
|
|
256
|
+
"user-select-none",
|
|
257
|
+
"visibility-hidden",
|
|
258
|
+
"warning",
|
|
259
|
+
"was-validated",
|
|
260
|
+
"white-space-normal"
|
|
261
|
+
]
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
import { mkdir, readFile, writeFile } from "node:fs/promises";
|
|
4
|
+
import { dirname, resolve } from "node:path";
|
|
5
|
+
import { inlineImports, minifyCss } from "../tooling/css-bundle.js";
|
|
6
|
+
|
|
7
|
+
function usage() {
|
|
8
|
+
return [
|
|
9
|
+
"actual-css bundle INPUT --out FILE [--minify]",
|
|
10
|
+
"",
|
|
11
|
+
" -o, --out FILE write the bundle to FILE (required)",
|
|
12
|
+
" --minify collapse comments and whitespace",
|
|
13
|
+
" -h, --help show this message",
|
|
14
|
+
" --version print the actual-css version",
|
|
15
|
+
"",
|
|
16
|
+
"Bundle plain CSS @import chains from relative files and actual-css/css/* subpaths.",
|
|
17
|
+
"A layer or layer(name) import is flattened into the @layer block it stands for.",
|
|
18
|
+
"Remote imports are kept and hoisted to the top of the bundle.",
|
|
19
|
+
"Leaves modern CSS syntax untouched; this is a bundler, not a transpiler.",
|
|
20
|
+
].join("\n");
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
async function version() {
|
|
24
|
+
const pkg = await readFile(new URL("../../package.json", import.meta.url), "utf8");
|
|
25
|
+
return JSON.parse(pkg).version;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
function parseArgs(argv) {
|
|
29
|
+
const [command, ...rest] = argv;
|
|
30
|
+
|
|
31
|
+
if (!command || command === "--help" || command === "-h") {
|
|
32
|
+
return { help: true };
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
if (command === "--version" || command === "-v") {
|
|
36
|
+
return { version: true };
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
if (command !== "bundle") {
|
|
40
|
+
throw new Error(`Unknown command: ${command}`);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
let input = "";
|
|
44
|
+
let out = "";
|
|
45
|
+
let minify = false;
|
|
46
|
+
|
|
47
|
+
for (let i = 0; i < rest.length; i += 1) {
|
|
48
|
+
const arg = rest[i];
|
|
49
|
+
|
|
50
|
+
if (arg === "--help" || arg === "-h") {
|
|
51
|
+
return { help: true };
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
if (arg === "--minify") {
|
|
55
|
+
minify = true;
|
|
56
|
+
continue;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
if (arg === "--out" || arg === "-o") {
|
|
60
|
+
const value = rest[i + 1];
|
|
61
|
+
|
|
62
|
+
if (!value) {
|
|
63
|
+
throw new Error("Missing value for --out.");
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
out = value;
|
|
67
|
+
i += 1;
|
|
68
|
+
continue;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
if (arg.startsWith("-")) {
|
|
72
|
+
throw new Error(`Unknown option: ${arg}`);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
if (input) {
|
|
76
|
+
throw new Error(`Unexpected extra argument: ${arg}`);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
input = arg;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
if (!input) {
|
|
83
|
+
throw new Error("Missing input file.");
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
if (!out) {
|
|
87
|
+
throw new Error("Missing required --out FILE option.");
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
return { help: false, input, out, minify };
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
async function bundle({ input, out, minify }) {
|
|
94
|
+
const inputPath = resolve(input);
|
|
95
|
+
const outputPath = resolve(out);
|
|
96
|
+
const css = await inlineImports(inputPath);
|
|
97
|
+
const code = minify ? minifyCss(css) : css;
|
|
98
|
+
|
|
99
|
+
await mkdir(dirname(outputPath), { recursive: true });
|
|
100
|
+
await writeFile(outputPath, code);
|
|
101
|
+
|
|
102
|
+
console.log(`Bundled ${inputPath} -> ${outputPath}${minify ? " (minified)" : ""}`);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
async function main() {
|
|
106
|
+
let args;
|
|
107
|
+
|
|
108
|
+
try {
|
|
109
|
+
args = parseArgs(process.argv.slice(2));
|
|
110
|
+
} catch (error) {
|
|
111
|
+
console.error(error.message);
|
|
112
|
+
console.error("");
|
|
113
|
+
console.error(usage());
|
|
114
|
+
process.exit(1);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
if (args.help) {
|
|
118
|
+
console.log(usage());
|
|
119
|
+
return;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
if (args.version) {
|
|
123
|
+
console.log(await version());
|
|
124
|
+
return;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
await bundle(args);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
main().catch((error) => {
|
|
131
|
+
console.error(error.message);
|
|
132
|
+
process.exit(1);
|
|
133
|
+
});
|
package/src/css/actual.css
CHANGED
|
@@ -1,31 +1 @@
|
|
|
1
|
-
@import "./
|
|
2
|
-
@import "./tokens.css";
|
|
3
|
-
@import "./theme.css";
|
|
4
|
-
@import "./base.css";
|
|
5
|
-
@import "./intents.css";
|
|
6
|
-
/* Prose before layout: layout primitives (.stack, .cluster) reset child
|
|
7
|
-
margins and must win over .prose's flow margins at equal specificity —
|
|
8
|
-
source order is the tie-breaker, so prose loads first. */
|
|
9
|
-
@import "./prose.css";
|
|
10
|
-
@import "./layout.css";
|
|
11
|
-
@import "./grid.css";
|
|
12
|
-
@import "./variants.css";
|
|
13
|
-
@import "./components/index.css";
|
|
14
|
-
@import "./forms/index.css";
|
|
15
|
-
@import "./utilities.css";
|
|
16
|
-
/* Joined controls are a component, but must load after the controls it groups. */
|
|
17
|
-
@import "./components/join.css";
|
|
18
|
-
@import "./focus.css";
|
|
19
|
-
@import "./print.css";
|
|
20
|
-
|
|
21
|
-
/*
|
|
22
|
-
* NOTE: The 'optional/' directory contains layout and utility extensions
|
|
23
|
-
* (such as optional grids, split, visual effects, and extra utility classes
|
|
24
|
-
* like .gap-sm, .flex-nowrap, .shadow-sm, etc.). These are intentionally not
|
|
25
|
-
* bundled here. Two entry points ship them:
|
|
26
|
-
*
|
|
27
|
-
* actual-css/css/optional/index optional layer only
|
|
28
|
-
* actual-css/css/actual.full core + optional
|
|
29
|
-
*
|
|
30
|
-
* Import one of these paths in your project when you need them.
|
|
31
|
-
*/
|
|
1
|
+
@import "./core/index.css";
|
package/src/css/actual.full.css
CHANGED
|
@@ -1,2 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
/* Core, then every shipped functional family in cascade order. Typography
|
|
2
|
+
precedes Layout because direct-child layout resets intentionally win over
|
|
3
|
+
equal-specificity prose flow margins. Forms precede Components because of
|
|
4
|
+
join. Do not alphabetize these top-level imports. */
|
|
5
|
+
@import "./actual.css";
|
|
6
|
+
@import "./typography/index.css";
|
|
7
|
+
@import "./layout/index.css";
|
|
8
|
+
@import "./forms/index.css";
|
|
9
|
+
@import "./components/index.css";
|
|
10
|
+
@import "./effects/index.css";
|
|
11
|
+
@import "./utilities/index.css";
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
*
|
|
21
21
|
* Internal:
|
|
22
22
|
* --alert-default-bg
|
|
23
|
+
* --alert-default-fg
|
|
23
24
|
* --alert-default-border
|
|
24
25
|
* --alert-bg
|
|
25
26
|
* --alert-fg
|
|
@@ -42,9 +43,10 @@
|
|
|
42
43
|
--alert-font-size: var(--font-size-md);
|
|
43
44
|
--alert-icon-size: 1.25rem;
|
|
44
45
|
--alert-default-bg: var(--surface-subtle);
|
|
46
|
+
--alert-default-fg: var(--intent, var(--text));
|
|
45
47
|
--alert-default-border: var(--border);
|
|
46
48
|
--alert-bg: var(--ui-bg, var(--alert-default-bg));
|
|
47
|
-
--alert-fg: var(--ui-fg, var(--
|
|
49
|
+
--alert-fg: var(--ui-fg, var(--alert-default-fg));
|
|
48
50
|
--alert-border: var(--ui-border, var(--alert-default-border));
|
|
49
51
|
|
|
50
52
|
padding-block: var(--alert-pad-block);
|
|
@@ -76,15 +78,20 @@
|
|
|
76
78
|
.alert {
|
|
77
79
|
/* @sync soft-recipe */
|
|
78
80
|
--alert-default-bg: color-mix(
|
|
79
|
-
in
|
|
81
|
+
in oklab,
|
|
80
82
|
var(--surface) var(--soft-bg-mix),
|
|
81
83
|
var(--intent, var(--neutral))
|
|
82
84
|
);
|
|
83
85
|
--alert-default-border: color-mix(
|
|
84
|
-
in
|
|
86
|
+
in oklab,
|
|
85
87
|
var(--surface) var(--soft-border-mix),
|
|
86
88
|
var(--intent, var(--neutral))
|
|
87
89
|
);
|
|
90
|
+
--alert-default-fg: color-mix(
|
|
91
|
+
in oklab,
|
|
92
|
+
var(--text),
|
|
93
|
+
var(--intent, var(--text)) var(--soft-fg-mix)
|
|
94
|
+
);
|
|
88
95
|
/* @sync soft-recipe */
|
|
89
96
|
}
|
|
90
97
|
}
|
|
@@ -230,7 +237,7 @@
|
|
|
230
237
|
@supports (color: color-mix(in oklch, red, white)) {
|
|
231
238
|
.alert.admonition > .alert-title {
|
|
232
239
|
background: color-mix(
|
|
233
|
-
in
|
|
240
|
+
in oklab,
|
|
234
241
|
var(--surface) var(--soft-bg-mix),
|
|
235
242
|
var(--intent, var(--neutral))
|
|
236
243
|
);
|
|
@@ -258,3 +265,9 @@
|
|
|
258
265
|
.alert.admonition > .alert-body > :last-child {
|
|
259
266
|
margin-block-end: 0;
|
|
260
267
|
}
|
|
268
|
+
@media print {
|
|
269
|
+
.alert {
|
|
270
|
+
border: var(--border-width) solid CanvasText;
|
|
271
|
+
break-inside: avoid;
|
|
272
|
+
}
|
|
273
|
+
}
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
.badge {
|
|
36
36
|
--badge-size: var(--density-compact-size);
|
|
37
37
|
--badge-pad-x: 0.55em;
|
|
38
|
-
--badge-font-size:
|
|
38
|
+
--badge-font-size: var(--font-size-xs);
|
|
39
39
|
--badge-dot-size: 0.5rem;
|
|
40
40
|
--badge-default-bg: var(--surface-subtle);
|
|
41
41
|
--badge-default-fg: var(--intent, var(--text));
|
|
@@ -76,15 +76,20 @@
|
|
|
76
76
|
.badge {
|
|
77
77
|
/* @sync soft-recipe */
|
|
78
78
|
--badge-default-bg: color-mix(
|
|
79
|
-
in
|
|
79
|
+
in oklab,
|
|
80
80
|
var(--surface) var(--soft-bg-mix),
|
|
81
81
|
var(--intent, var(--neutral))
|
|
82
82
|
);
|
|
83
83
|
--badge-default-border: color-mix(
|
|
84
|
-
in
|
|
84
|
+
in oklab,
|
|
85
85
|
var(--surface) var(--soft-border-mix),
|
|
86
86
|
var(--intent, var(--neutral))
|
|
87
87
|
);
|
|
88
|
+
--badge-default-fg: color-mix(
|
|
89
|
+
in oklab,
|
|
90
|
+
var(--text),
|
|
91
|
+
var(--intent, var(--text)) var(--soft-fg-mix)
|
|
92
|
+
);
|
|
88
93
|
/* @sync soft-recipe */
|
|
89
94
|
}
|
|
90
95
|
}
|
|
@@ -104,8 +109,8 @@
|
|
|
104
109
|
display: inline-grid;
|
|
105
110
|
place-items: center;
|
|
106
111
|
flex: 0 0 auto;
|
|
107
|
-
min-inline-size:
|
|
108
|
-
min-block-size:
|
|
112
|
+
min-inline-size: var(--density-compact-size);
|
|
113
|
+
min-block-size: var(--density-compact-size);
|
|
109
114
|
margin-block: -0.25rem;
|
|
110
115
|
margin-inline-start: -0.15em;
|
|
111
116
|
margin-inline-end: -0.45em;
|
|
@@ -136,7 +141,7 @@
|
|
|
136
141
|
|
|
137
142
|
:is(a.badge, button.badge):where(:not(.solid, .outline, :empty)) {
|
|
138
143
|
--badge-default-hover-bg: color-mix(
|
|
139
|
-
in
|
|
144
|
+
in oklab,
|
|
140
145
|
var(--surface) calc(var(--soft-bg-mix) - var(--soft-hover-alpha)),
|
|
141
146
|
var(--intent, var(--neutral))
|
|
142
147
|
);
|
|
@@ -152,6 +157,7 @@
|
|
|
152
157
|
}
|
|
153
158
|
|
|
154
159
|
:where(a.badge, button.badge):not(:where(:disabled, [aria-disabled="true"], .outline)):hover {
|
|
160
|
+
/* Huge inset spread paints the overlay over the pill radius (see button.css). */
|
|
155
161
|
box-shadow: inset 0 0 0 999px var(--hover-overlay);
|
|
156
162
|
}
|
|
157
163
|
|
|
@@ -191,3 +197,9 @@ a.badge[aria-disabled="true"] {
|
|
|
191
197
|
color: GrayText;
|
|
192
198
|
}
|
|
193
199
|
}
|
|
200
|
+
@media print {
|
|
201
|
+
.badge {
|
|
202
|
+
border: var(--border-width) solid CanvasText;
|
|
203
|
+
break-inside: avoid;
|
|
204
|
+
}
|
|
205
|
+
}
|