@classic-homes/theme-styles 0.6.0 → 0.10.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 +283 -8
- package/dist/components.css +1967 -0
- package/dist/components.json +1163 -0
- package/dist/tailwind-v4.css +999 -0
- package/package.json +13 -5
- package/src/accessibility.css +59 -0
package/package.json
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@classic-homes/theme-styles",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"description": "Base styles and utilities for the Classic Theme design system",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
7
|
-
"build": "
|
|
8
|
-
"test": "vitest run"
|
|
7
|
+
"build": "node scripts/build-tailwind-v4.mjs && node scripts/build-components-css.mjs",
|
|
8
|
+
"test": "vitest run",
|
|
9
|
+
"clean": "node ../../scripts/rm.mjs dist"
|
|
9
10
|
},
|
|
10
11
|
"exports": {
|
|
11
12
|
".": "./src/index.css",
|
|
@@ -13,13 +14,18 @@
|
|
|
13
14
|
"./fonts": "./src/fonts.css",
|
|
14
15
|
"./base": "./src/base.css",
|
|
15
16
|
"./accessibility": "./src/accessibility.css",
|
|
16
|
-
"./utilities": "./src/utilities.css"
|
|
17
|
+
"./utilities": "./src/utilities.css",
|
|
18
|
+
"./tailwind-v4": "./dist/tailwind-v4.css",
|
|
19
|
+
"./tailwind-v4.css": "./dist/tailwind-v4.css",
|
|
20
|
+
"./components.css": "./dist/components.css",
|
|
21
|
+
"./components.json": "./dist/components.json"
|
|
17
22
|
},
|
|
18
23
|
"sideEffects": [
|
|
19
24
|
"*.css"
|
|
20
25
|
],
|
|
21
26
|
"files": [
|
|
22
|
-
"src"
|
|
27
|
+
"src",
|
|
28
|
+
"dist"
|
|
23
29
|
],
|
|
24
30
|
"keywords": [
|
|
25
31
|
"styles",
|
|
@@ -46,7 +52,9 @@
|
|
|
46
52
|
"@classic-homes/theme-tokens": "*",
|
|
47
53
|
"postcss": "^8.4.0",
|
|
48
54
|
"postcss-import": "^16.1.1",
|
|
55
|
+
"prettier": "~3.7.4",
|
|
49
56
|
"tailwindcss": "^3.4.0",
|
|
57
|
+
"tailwindcss-v4": "npm:tailwindcss@4.3.4",
|
|
50
58
|
"vitest": "^4.0.0"
|
|
51
59
|
}
|
|
52
60
|
}
|
package/src/accessibility.css
CHANGED
|
@@ -68,6 +68,65 @@
|
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
70
|
|
|
71
|
+
/* ===== Touch Field Size (no iOS zoom-on-focus) ===== */
|
|
72
|
+
|
|
73
|
+
/* iOS (Safari and home-screen web apps) zooms the page to a focused field
|
|
74
|
+
whose font is under 16px, and compact fields (text-sm/text-xs) are. Touch
|
|
75
|
+
devices get 16px text fields; desktop keeps the compact sizes. Unlayered
|
|
76
|
+
and !important so it beats per-field utilities and inline sizes. Use this
|
|
77
|
+
rather than viewport maximum-scale, which also blocks pinch-zoom on
|
|
78
|
+
Android. The media query covers phones and tablets; the @supports block
|
|
79
|
+
(iOS/iPadOS WebKit only) covers an iPad with a trackpad, which reports
|
|
80
|
+
pointer: fine but still zooms.
|
|
81
|
+
|
|
82
|
+
Opt out with data-keep-field-size on a field or container, e.g. a canvas
|
|
83
|
+
whose text boxes are always rendered at a designed size (stop the zoom
|
|
84
|
+
there another way, such as maximum-scale while the canvas is shown). */
|
|
85
|
+
|
|
86
|
+
@media (hover: none) and (pointer: coarse) {
|
|
87
|
+
:is(
|
|
88
|
+
input:not(
|
|
89
|
+
[type='checkbox'],
|
|
90
|
+
[type='radio'],
|
|
91
|
+
[type='range'],
|
|
92
|
+
[type='color'],
|
|
93
|
+
[type='file'],
|
|
94
|
+
[type='button'],
|
|
95
|
+
[type='submit'],
|
|
96
|
+
[type='reset'],
|
|
97
|
+
[type='image'],
|
|
98
|
+
[type='hidden']
|
|
99
|
+
),
|
|
100
|
+
textarea,
|
|
101
|
+
select,
|
|
102
|
+
[contenteditable]:not([contenteditable='false'])
|
|
103
|
+
):not([data-keep-field-size], [data-keep-field-size] *) {
|
|
104
|
+
font-size: 16px !important;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
@supports (-webkit-touch-callout: none) {
|
|
109
|
+
:is(
|
|
110
|
+
input:not(
|
|
111
|
+
[type='checkbox'],
|
|
112
|
+
[type='radio'],
|
|
113
|
+
[type='range'],
|
|
114
|
+
[type='color'],
|
|
115
|
+
[type='file'],
|
|
116
|
+
[type='button'],
|
|
117
|
+
[type='submit'],
|
|
118
|
+
[type='reset'],
|
|
119
|
+
[type='image'],
|
|
120
|
+
[type='hidden']
|
|
121
|
+
),
|
|
122
|
+
textarea,
|
|
123
|
+
select,
|
|
124
|
+
[contenteditable]:not([contenteditable='false'])
|
|
125
|
+
):not([data-keep-field-size], [data-keep-field-size] *) {
|
|
126
|
+
font-size: 16px !important;
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
71
130
|
@layer classic-theme.utilities {
|
|
72
131
|
/* ===== Skip Link (WCAG 2.4.1) ===== */
|
|
73
132
|
|