@caltho/site-kit 0.2.10 → 0.2.11
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 +61 -12
- package/dist/cli/check.js +31 -1
- package/dist/content/index.d.ts +310 -23
- package/dist/content/index.js +142 -15
- package/dist/content/look.d.ts +260 -9
- package/dist/content/look.js +386 -22
- package/dist/finish.js +9 -1
- package/dist/fonts/families/dm-sans/LICENSE +93 -0
- package/dist/fonts/families/dm-sans/dm-sans-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/dm-sans/dm-sans-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/dm-sans/dm-sans-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/dm-sans/dm-sans-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/fraunces/LICENSE +93 -0
- package/dist/fonts/families/fraunces/fraunces-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/fraunces/fraunces-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/fraunces/fraunces-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/fraunces/fraunces-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/inter/LICENSE +93 -0
- package/dist/fonts/families/inter/inter-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/inter/inter-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/inter/inter-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/inter/inter-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/lora/LICENSE +93 -0
- package/dist/fonts/families/lora/lora-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/lora/lora-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/lora/lora-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/lora/lora-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/manrope/LICENSE +93 -0
- package/dist/fonts/families/manrope/manrope-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/manrope/manrope-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/newsreader/LICENSE +93 -0
- package/dist/fonts/families/newsreader/newsreader-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/newsreader/newsreader-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/newsreader/newsreader-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/newsreader/newsreader-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/outfit/LICENSE +93 -0
- package/dist/fonts/families/outfit/outfit-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/outfit/outfit-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/playfair-display/LICENSE +93 -0
- package/dist/fonts/families/playfair-display/playfair-display-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/playfair-display/playfair-display-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/playfair-display/playfair-display-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/playfair-display/playfair-display-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/source-serif-4/LICENSE +93 -0
- package/dist/fonts/families/source-serif-4/source-serif-4-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/source-serif-4/source-serif-4-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/source-serif-4/source-serif-4-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/source-serif-4/source-serif-4-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/families/work-sans/LICENSE +93 -0
- package/dist/fonts/families/work-sans/work-sans-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/families/work-sans/work-sans-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/families/work-sans/work-sans-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/families/work-sans/work-sans-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/google.json +1 -0
- package/dist/fonts-google.d.ts +35 -0
- package/dist/fonts-google.js +70 -0
- package/dist/fonts.css +365 -0
- package/dist/frame.test.d.ts +1 -0
- package/dist/frame.test.js +33 -0
- package/dist/migrate.d.ts +45 -0
- package/dist/migrate.js +284 -0
- package/dist/next/block-mark.d.ts +7 -0
- package/dist/next/block-mark.js +16 -0
- package/dist/next/blocks.d.ts +11 -0
- package/dist/next/blocks.js +35 -0
- package/dist/next/data.d.ts +4 -0
- package/dist/next/data.js +4 -0
- package/dist/next/frame.d.ts +34 -0
- package/dist/next/frame.js +70 -0
- package/dist/next/index.d.ts +6 -2
- package/dist/next/index.js +7 -3
- package/dist/next/menu-group.d.ts +11 -0
- package/dist/next/menu-group.js +33 -0
- package/dist/next/parts/LookStyle.js +3 -1
- package/dist/next/preview.js +282 -25
- package/dist/next/sections.d.ts +19 -10
- package/dist/next/sections.js +129 -17
- package/dist/prepare.d.ts +5 -1
- package/dist/prepare.js +59 -1
- package/dist/preview-match.d.ts +8 -0
- package/dist/preview-match.js +33 -1
- package/dist/schema.d.ts +10 -0
- package/dist/schema.js +26 -0
- package/dist/sections/icons.d.ts +47 -0
- package/dist/sections/icons.js +51 -0
- package/dist/sections/index.d.ts +165 -11
- package/dist/sections/index.js +129 -8
- package/dist/sections/presets.d.ts +13 -0
- package/dist/sections/presets.js +300 -0
- package/dist/sections.css +1260 -41
- package/dist/sections.test.js +276 -14
- package/package.json +8 -3
package/dist/fonts.css
ADDED
|
@@ -0,0 +1,365 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* The kit's fonts (@caltho/site-kit/fonts.css): variable fonts, every weight, self-hosted, Latin and
|
|
3
|
+
* Latin Extended, normal and italic. Only those a page uses are downloaded (font-face is lazy).
|
|
4
|
+
* Each is under the SIL Open Font License (fonts/families/<name>/LICENSE).
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
/* fraunces-latin-ext-wght-normal */
|
|
8
|
+
@font-face {
|
|
9
|
+
font-family: 'Fraunces Variable';
|
|
10
|
+
font-style: normal;
|
|
11
|
+
font-display: swap;
|
|
12
|
+
font-weight: 100 900;
|
|
13
|
+
src: url(./fonts/families/fraunces/fraunces-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
14
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/* fraunces-latin-wght-normal */
|
|
18
|
+
@font-face {
|
|
19
|
+
font-family: 'Fraunces Variable';
|
|
20
|
+
font-style: normal;
|
|
21
|
+
font-display: swap;
|
|
22
|
+
font-weight: 100 900;
|
|
23
|
+
src: url(./fonts/families/fraunces/fraunces-latin-wght-normal.woff2) format('woff2-variations');
|
|
24
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/* fraunces-latin-ext-wght-italic */
|
|
28
|
+
@font-face {
|
|
29
|
+
font-family: 'Fraunces Variable';
|
|
30
|
+
font-style: italic;
|
|
31
|
+
font-display: swap;
|
|
32
|
+
font-weight: 100 900;
|
|
33
|
+
src: url(./fonts/families/fraunces/fraunces-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
34
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/* fraunces-latin-wght-italic */
|
|
38
|
+
@font-face {
|
|
39
|
+
font-family: 'Fraunces Variable';
|
|
40
|
+
font-style: italic;
|
|
41
|
+
font-display: swap;
|
|
42
|
+
font-weight: 100 900;
|
|
43
|
+
src: url(./fonts/families/fraunces/fraunces-latin-wght-italic.woff2) format('woff2-variations');
|
|
44
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/* inter-latin-ext-wght-normal */
|
|
48
|
+
@font-face {
|
|
49
|
+
font-family: 'Inter Variable';
|
|
50
|
+
font-style: normal;
|
|
51
|
+
font-display: swap;
|
|
52
|
+
font-weight: 100 900;
|
|
53
|
+
src: url(./fonts/families/inter/inter-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
54
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/* inter-latin-wght-normal */
|
|
58
|
+
@font-face {
|
|
59
|
+
font-family: 'Inter Variable';
|
|
60
|
+
font-style: normal;
|
|
61
|
+
font-display: swap;
|
|
62
|
+
font-weight: 100 900;
|
|
63
|
+
src: url(./fonts/families/inter/inter-latin-wght-normal.woff2) format('woff2-variations');
|
|
64
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/* inter-latin-ext-wght-italic */
|
|
68
|
+
@font-face {
|
|
69
|
+
font-family: 'Inter Variable';
|
|
70
|
+
font-style: italic;
|
|
71
|
+
font-display: swap;
|
|
72
|
+
font-weight: 100 900;
|
|
73
|
+
src: url(./fonts/families/inter/inter-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
74
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
/* inter-latin-wght-italic */
|
|
78
|
+
@font-face {
|
|
79
|
+
font-family: 'Inter Variable';
|
|
80
|
+
font-style: italic;
|
|
81
|
+
font-display: swap;
|
|
82
|
+
font-weight: 100 900;
|
|
83
|
+
src: url(./fonts/families/inter/inter-latin-wght-italic.woff2) format('woff2-variations');
|
|
84
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/* newsreader-latin-ext-wght-normal */
|
|
88
|
+
@font-face {
|
|
89
|
+
font-family: 'Newsreader Variable';
|
|
90
|
+
font-style: normal;
|
|
91
|
+
font-display: swap;
|
|
92
|
+
font-weight: 200 800;
|
|
93
|
+
src: url(./fonts/families/newsreader/newsreader-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
94
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/* newsreader-latin-wght-normal */
|
|
98
|
+
@font-face {
|
|
99
|
+
font-family: 'Newsreader Variable';
|
|
100
|
+
font-style: normal;
|
|
101
|
+
font-display: swap;
|
|
102
|
+
font-weight: 200 800;
|
|
103
|
+
src: url(./fonts/families/newsreader/newsreader-latin-wght-normal.woff2) format('woff2-variations');
|
|
104
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
/* newsreader-latin-ext-wght-italic */
|
|
108
|
+
@font-face {
|
|
109
|
+
font-family: 'Newsreader Variable';
|
|
110
|
+
font-style: italic;
|
|
111
|
+
font-display: swap;
|
|
112
|
+
font-weight: 200 800;
|
|
113
|
+
src: url(./fonts/families/newsreader/newsreader-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
114
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/* newsreader-latin-wght-italic */
|
|
118
|
+
@font-face {
|
|
119
|
+
font-family: 'Newsreader Variable';
|
|
120
|
+
font-style: italic;
|
|
121
|
+
font-display: swap;
|
|
122
|
+
font-weight: 200 800;
|
|
123
|
+
src: url(./fonts/families/newsreader/newsreader-latin-wght-italic.woff2) format('woff2-variations');
|
|
124
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
/* source-serif-4-latin-ext-wght-normal */
|
|
128
|
+
@font-face {
|
|
129
|
+
font-family: 'Source Serif 4 Variable';
|
|
130
|
+
font-style: normal;
|
|
131
|
+
font-display: swap;
|
|
132
|
+
font-weight: 200 900;
|
|
133
|
+
src: url(./fonts/families/source-serif-4/source-serif-4-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
134
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C4,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/* source-serif-4-latin-wght-normal */
|
|
138
|
+
@font-face {
|
|
139
|
+
font-family: 'Source Serif 4 Variable';
|
|
140
|
+
font-style: normal;
|
|
141
|
+
font-display: swap;
|
|
142
|
+
font-weight: 200 900;
|
|
143
|
+
src: url(./fonts/families/source-serif-4/source-serif-4-latin-wght-normal.woff2) format('woff2-variations');
|
|
144
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
/* source-serif-4-latin-ext-wght-italic */
|
|
148
|
+
@font-face {
|
|
149
|
+
font-family: 'Source Serif 4 Variable';
|
|
150
|
+
font-style: italic;
|
|
151
|
+
font-display: swap;
|
|
152
|
+
font-weight: 200 900;
|
|
153
|
+
src: url(./fonts/families/source-serif-4/source-serif-4-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
154
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C4,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
/* source-serif-4-latin-wght-italic */
|
|
158
|
+
@font-face {
|
|
159
|
+
font-family: 'Source Serif 4 Variable';
|
|
160
|
+
font-style: italic;
|
|
161
|
+
font-display: swap;
|
|
162
|
+
font-weight: 200 900;
|
|
163
|
+
src: url(./fonts/families/source-serif-4/source-serif-4-latin-wght-italic.woff2) format('woff2-variations');
|
|
164
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/* playfair-display-latin-ext-wght-normal */
|
|
168
|
+
@font-face {
|
|
169
|
+
font-family: 'Playfair Display Variable';
|
|
170
|
+
font-style: normal;
|
|
171
|
+
font-display: swap;
|
|
172
|
+
font-weight: 400 900;
|
|
173
|
+
src: url(./fonts/families/playfair-display/playfair-display-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
174
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
/* playfair-display-latin-wght-normal */
|
|
178
|
+
@font-face {
|
|
179
|
+
font-family: 'Playfair Display Variable';
|
|
180
|
+
font-style: normal;
|
|
181
|
+
font-display: swap;
|
|
182
|
+
font-weight: 400 900;
|
|
183
|
+
src: url(./fonts/families/playfair-display/playfair-display-latin-wght-normal.woff2) format('woff2-variations');
|
|
184
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
/* playfair-display-latin-ext-wght-italic */
|
|
188
|
+
@font-face {
|
|
189
|
+
font-family: 'Playfair Display Variable';
|
|
190
|
+
font-style: italic;
|
|
191
|
+
font-display: swap;
|
|
192
|
+
font-weight: 400 900;
|
|
193
|
+
src: url(./fonts/families/playfair-display/playfair-display-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
194
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
/* playfair-display-latin-wght-italic */
|
|
198
|
+
@font-face {
|
|
199
|
+
font-family: 'Playfair Display Variable';
|
|
200
|
+
font-style: italic;
|
|
201
|
+
font-display: swap;
|
|
202
|
+
font-weight: 400 900;
|
|
203
|
+
src: url(./fonts/families/playfair-display/playfair-display-latin-wght-italic.woff2) format('woff2-variations');
|
|
204
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
/* lora-latin-ext-wght-normal */
|
|
208
|
+
@font-face {
|
|
209
|
+
font-family: 'Lora Variable';
|
|
210
|
+
font-style: normal;
|
|
211
|
+
font-display: swap;
|
|
212
|
+
font-weight: 400 700;
|
|
213
|
+
src: url(./fonts/families/lora/lora-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
214
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
/* lora-latin-wght-normal */
|
|
218
|
+
@font-face {
|
|
219
|
+
font-family: 'Lora Variable';
|
|
220
|
+
font-style: normal;
|
|
221
|
+
font-display: swap;
|
|
222
|
+
font-weight: 400 700;
|
|
223
|
+
src: url(./fonts/families/lora/lora-latin-wght-normal.woff2) format('woff2-variations');
|
|
224
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
/* lora-latin-ext-wght-italic */
|
|
228
|
+
@font-face {
|
|
229
|
+
font-family: 'Lora Variable';
|
|
230
|
+
font-style: italic;
|
|
231
|
+
font-display: swap;
|
|
232
|
+
font-weight: 400 700;
|
|
233
|
+
src: url(./fonts/families/lora/lora-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
234
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
/* lora-latin-wght-italic */
|
|
238
|
+
@font-face {
|
|
239
|
+
font-family: 'Lora Variable';
|
|
240
|
+
font-style: italic;
|
|
241
|
+
font-display: swap;
|
|
242
|
+
font-weight: 400 700;
|
|
243
|
+
src: url(./fonts/families/lora/lora-latin-wght-italic.woff2) format('woff2-variations');
|
|
244
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
/* dm-sans-latin-ext-wght-normal */
|
|
248
|
+
@font-face {
|
|
249
|
+
font-family: 'DM Sans Variable';
|
|
250
|
+
font-style: normal;
|
|
251
|
+
font-display: swap;
|
|
252
|
+
font-weight: 100 1000;
|
|
253
|
+
src: url(./fonts/families/dm-sans/dm-sans-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
254
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
/* dm-sans-latin-wght-normal */
|
|
258
|
+
@font-face {
|
|
259
|
+
font-family: 'DM Sans Variable';
|
|
260
|
+
font-style: normal;
|
|
261
|
+
font-display: swap;
|
|
262
|
+
font-weight: 100 1000;
|
|
263
|
+
src: url(./fonts/families/dm-sans/dm-sans-latin-wght-normal.woff2) format('woff2-variations');
|
|
264
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
/* dm-sans-latin-ext-wght-italic */
|
|
268
|
+
@font-face {
|
|
269
|
+
font-family: 'DM Sans Variable';
|
|
270
|
+
font-style: italic;
|
|
271
|
+
font-display: swap;
|
|
272
|
+
font-weight: 100 1000;
|
|
273
|
+
src: url(./fonts/families/dm-sans/dm-sans-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
274
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
/* dm-sans-latin-wght-italic */
|
|
278
|
+
@font-face {
|
|
279
|
+
font-family: 'DM Sans Variable';
|
|
280
|
+
font-style: italic;
|
|
281
|
+
font-display: swap;
|
|
282
|
+
font-weight: 100 1000;
|
|
283
|
+
src: url(./fonts/families/dm-sans/dm-sans-latin-wght-italic.woff2) format('woff2-variations');
|
|
284
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
/* manrope-latin-ext-wght-normal */
|
|
288
|
+
@font-face {
|
|
289
|
+
font-family: 'Manrope Variable';
|
|
290
|
+
font-style: normal;
|
|
291
|
+
font-display: swap;
|
|
292
|
+
font-weight: 200 800;
|
|
293
|
+
src: url(./fonts/families/manrope/manrope-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
294
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
/* manrope-latin-wght-normal */
|
|
298
|
+
@font-face {
|
|
299
|
+
font-family: 'Manrope Variable';
|
|
300
|
+
font-style: normal;
|
|
301
|
+
font-display: swap;
|
|
302
|
+
font-weight: 200 800;
|
|
303
|
+
src: url(./fonts/families/manrope/manrope-latin-wght-normal.woff2) format('woff2-variations');
|
|
304
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
/* work-sans-latin-ext-wght-normal */
|
|
308
|
+
@font-face {
|
|
309
|
+
font-family: 'Work Sans Variable';
|
|
310
|
+
font-style: normal;
|
|
311
|
+
font-display: swap;
|
|
312
|
+
font-weight: 100 900;
|
|
313
|
+
src: url(./fonts/families/work-sans/work-sans-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
314
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
/* work-sans-latin-wght-normal */
|
|
318
|
+
@font-face {
|
|
319
|
+
font-family: 'Work Sans Variable';
|
|
320
|
+
font-style: normal;
|
|
321
|
+
font-display: swap;
|
|
322
|
+
font-weight: 100 900;
|
|
323
|
+
src: url(./fonts/families/work-sans/work-sans-latin-wght-normal.woff2) format('woff2-variations');
|
|
324
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
/* work-sans-latin-ext-wght-italic */
|
|
328
|
+
@font-face {
|
|
329
|
+
font-family: 'Work Sans Variable';
|
|
330
|
+
font-style: italic;
|
|
331
|
+
font-display: swap;
|
|
332
|
+
font-weight: 100 900;
|
|
333
|
+
src: url(./fonts/families/work-sans/work-sans-latin-ext-wght-italic.woff2) format('woff2-variations');
|
|
334
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
/* work-sans-latin-wght-italic */
|
|
338
|
+
@font-face {
|
|
339
|
+
font-family: 'Work Sans Variable';
|
|
340
|
+
font-style: italic;
|
|
341
|
+
font-display: swap;
|
|
342
|
+
font-weight: 100 900;
|
|
343
|
+
src: url(./fonts/families/work-sans/work-sans-latin-wght-italic.woff2) format('woff2-variations');
|
|
344
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
/* outfit-latin-ext-wght-normal */
|
|
348
|
+
@font-face {
|
|
349
|
+
font-family: 'Outfit Variable';
|
|
350
|
+
font-style: normal;
|
|
351
|
+
font-display: swap;
|
|
352
|
+
font-weight: 100 900;
|
|
353
|
+
src: url(./fonts/families/outfit/outfit-latin-ext-wght-normal.woff2) format('woff2-variations');
|
|
354
|
+
unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
/* outfit-latin-wght-normal */
|
|
358
|
+
@font-face {
|
|
359
|
+
font-family: 'Outfit Variable';
|
|
360
|
+
font-style: normal;
|
|
361
|
+
font-display: swap;
|
|
362
|
+
font-weight: 100 900;
|
|
363
|
+
src: url(./fonts/families/outfit/outfit-latin-wght-normal.woff2) format('woff2-variations');
|
|
364
|
+
unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
|
|
365
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { describe, expect, it } from "bun:test";
|
|
3
|
+
import { renderToStaticMarkup } from "react-dom/server";
|
|
4
|
+
import { KitFrame } from "./next/frame.js";
|
|
5
|
+
const site = {
|
|
6
|
+
business: { name: "Acme Plumbing", phone: "(215) 555-0100", social: {}, hours: [] },
|
|
7
|
+
pages: [
|
|
8
|
+
{ path: "/", title: "Home", menu: "Home", blocks: [] },
|
|
9
|
+
{ path: "/services/", title: "Services", menu: "Services", blocks: [] },
|
|
10
|
+
],
|
|
11
|
+
};
|
|
12
|
+
describe("the kit's frame", () => {
|
|
13
|
+
it("draws the header as the Look says, the page in main, and the footer, without a style attribute", () => {
|
|
14
|
+
const html = renderToStaticMarkup(_jsx(KitFrame, { site: { ...site, look: { header: { style: "floating", layout: "centered", sticky: false } } }, current: "/services/", look: { header: {} }, children: _jsx("p", { children: "Page" }) }));
|
|
15
|
+
expect(html).toMatch(/<a class="kit-skip" href="#main">/);
|
|
16
|
+
expect(html).toMatch(/<header class="kit-header kit-header-floating kit-header-centered">/);
|
|
17
|
+
expect(html).toMatch(/<main id="main" tabindex="-1"><p>Page<\/p><\/main>/);
|
|
18
|
+
expect(html).toMatch(/href="\/services\/" aria-current="page"/);
|
|
19
|
+
expect(html).toMatch(/<footer class="kit-footer">/);
|
|
20
|
+
expect(html).toMatch(/href="tel:/);
|
|
21
|
+
expect(html).not.toMatch(/\sstyle=/);
|
|
22
|
+
});
|
|
23
|
+
it("draws the header's button in the style the business chose: the theme's accent", () => {
|
|
24
|
+
const styled = { ...site, menu: { links: [], button: { label: "Get in touch", href: "/contact/", style: "accent" } } };
|
|
25
|
+
expect(renderToStaticMarkup(_jsx(KitFrame, { site: styled, current: "/", look: {}, children: "x" }))).toContain('class="kit-button kit-header-action kit-button-accent" href="/contact/"');
|
|
26
|
+
});
|
|
27
|
+
it("is sticky with a line under it until the Look says otherwise, and a site's own header takes its place", () => {
|
|
28
|
+
expect(renderToStaticMarkup(_jsx(KitFrame, { site: site, current: "/", look: {}, children: "x" }))).toMatch(/<header class="kit-header kit-header-line kit-header-spread is-sticky">/);
|
|
29
|
+
const own = renderToStaticMarkup(_jsx(KitFrame, { site: site, current: "/", look: {}, header: _jsx("header", { className: "mine" }), footer: null, children: "x" }));
|
|
30
|
+
expect(own).toMatch(/<header class="mine">/);
|
|
31
|
+
expect(own).not.toMatch(/kit-header|kit-footer/);
|
|
32
|
+
});
|
|
33
|
+
});
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/** A file the migration writes, or removes. */
|
|
2
|
+
export type MigratedFile = {
|
|
3
|
+
path: string;
|
|
4
|
+
text: string;
|
|
5
|
+
} | {
|
|
6
|
+
path: string;
|
|
7
|
+
remove: true;
|
|
8
|
+
};
|
|
9
|
+
export type Migration = {
|
|
10
|
+
id: string;
|
|
11
|
+
/** The kit version it moves a site to: run when the site moves to this version or later. */
|
|
12
|
+
since: string;
|
|
13
|
+
/** What it does, for the person who looks at the branch. */
|
|
14
|
+
title: string;
|
|
15
|
+
run(read: (path: string) => Promise<string | null>): Promise<{
|
|
16
|
+
files: MigratedFile[];
|
|
17
|
+
} | {
|
|
18
|
+
manual: string;
|
|
19
|
+
} | {
|
|
20
|
+
done: true;
|
|
21
|
+
}>;
|
|
22
|
+
};
|
|
23
|
+
export declare const MIGRATIONS_FILE = ".caltho/migrations.json";
|
|
24
|
+
/** Every migration, oldest first. */
|
|
25
|
+
export declare const MIGRATIONS: Migration[];
|
|
26
|
+
export type MigrationResult = {
|
|
27
|
+
/** Every file to write or remove, the record of what it has had among them. */
|
|
28
|
+
files: MigratedFile[];
|
|
29
|
+
/** Those it had now (or had already, by its code). */
|
|
30
|
+
applied: {
|
|
31
|
+
id: string;
|
|
32
|
+
title: string;
|
|
33
|
+
}[];
|
|
34
|
+
/** Those a person moves by hand, and why. Not recorded: they're tried again next time. */
|
|
35
|
+
manual: {
|
|
36
|
+
id: string;
|
|
37
|
+
title: string;
|
|
38
|
+
why: string;
|
|
39
|
+
}[];
|
|
40
|
+
};
|
|
41
|
+
/**
|
|
42
|
+
* What moving a site to kit `version` changes in its own files: each migration up to that version it
|
|
43
|
+
* hasn't had, in order, each seeing the files as the ones before it left them.
|
|
44
|
+
*/
|
|
45
|
+
export declare function migrateSite(read: (path: string) => Promise<string | null>, version: string, migrations?: Migration[]): Promise<MigrationResult>;
|