@trebired/configs 0.3.1 → 0.5.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.
Files changed (36) hide show
  1. package/.trebired/code-discipline/config.ts +1 -1
  2. package/.trebired/frontend/action_control.ts +43 -0
  3. package/.trebired/frontend/button.ts +203 -0
  4. package/.trebired/frontend/choice.ts +19 -0
  5. package/.trebired/frontend/components.ts +21 -0
  6. package/.trebired/frontend/config.ts +40 -0
  7. package/.trebired/frontend/data.ts +33 -0
  8. package/.trebired/frontend/disclosure.ts +10 -0
  9. package/.trebired/frontend/dot.ts +5 -0
  10. package/.trebired/frontend/dropdown.ts +25 -0
  11. package/.trebired/frontend/feedback.ts +56 -0
  12. package/.trebired/frontend/input.ts +31 -0
  13. package/.trebired/frontend/loader.ts +8 -0
  14. package/.trebired/frontend/marquee.ts +19 -0
  15. package/.trebired/frontend/media.ts +63 -0
  16. package/.trebired/frontend/overlays.ts +111 -0
  17. package/.trebired/frontend/palette.ts +111 -0
  18. package/.trebired/frontend/pill.ts +12 -0
  19. package/.trebired/frontend/primitives.ts +39 -0
  20. package/.trebired/frontend/progress.ts +11 -0
  21. package/.trebired/frontend/quote.ts +13 -0
  22. package/.trebired/frontend/shell.ts +251 -0
  23. package/.trebired/frontend/steps.ts +6 -0
  24. package/.trebired/frontend/surfaces.ts +276 -0
  25. package/.trebired/frontend/systems.ts +20 -0
  26. package/.trebired/frontend/tabs.ts +42 -0
  27. package/.trebired/frontend/text_link.ts +37 -0
  28. package/.trebired/frontend/theme.ts +50 -0
  29. package/.trebired/frontend/toggle.ts +17 -0
  30. package/.trebired/frontend/tokens.ts +37 -0
  31. package/.trebired/frontend/typography.ts +20 -0
  32. package/.trebired/frontend/upload.ts +108 -0
  33. package/.trebired/frontend/wizard.ts +6 -0
  34. package/CHANGELOG.md +9 -0
  35. package/README.md +29 -4
  36. package/package.json +19 -2
@@ -0,0 +1,276 @@
1
+ import { semantic, token, ui } from "./tokens";
2
+
3
+ export const surfaces = {
4
+ brandCanvas: {
5
+ art: {
6
+ border: "1px solid color-mix(in srgb, currentColor 24%, transparent)",
7
+ },
8
+ caption: {
9
+ fontSize: ".8rem",
10
+ gap: "0.75rem",
11
+ },
12
+ clear: {
13
+ space: "2rem",
14
+ },
15
+ guide: {
16
+ border: "1px dashed color-mix(in srgb, currentColor 38%, transparent)",
17
+ },
18
+ measure: {
19
+ color: "color-mix(in srgb, currentColor 62%, transparent)",
20
+ fontSize: "0.68rem",
21
+ offset: "0.75rem",
22
+ },
23
+ root: {
24
+ gap: "0.75rem",
25
+ },
26
+ spec: {
27
+ color: "var(--tbf-text-muted, #666)",
28
+ fontSize: "0.72rem",
29
+ },
30
+ stage: {
31
+ background: "var(--tbf-page, #fff)",
32
+ border: "var(--border-width, 1px) solid color-mix(in srgb, currentColor 14%, transparent)",
33
+ color: "var(--tbf-text, #000)",
34
+ minHeight: "14rem",
35
+ padding: "2.5rem",
36
+ radius: "var(--tbf-radius, 0)",
37
+ },
38
+ tones: {
39
+ accent: {
40
+ background: "var(--tbf-focus, #000)",
41
+ color: "var(--tbf-page, #fff)",
42
+ },
43
+ inverse: {
44
+ background: "var(--tbf-ink, #000)",
45
+ color: "var(--tbf-page, #fff)",
46
+ },
47
+ muted: {
48
+ background: "var(--tbf-surface-muted, #eee)",
49
+ color: "var(--tbf-text, #000)",
50
+ },
51
+ },
52
+ },
53
+ button: {
54
+ root: {
55
+ background: token.color("gray", 900),
56
+ border: token.border(semantic.borderSurface2),
57
+ color: semantic.textColor,
58
+ fontFamily: "var(--tbf-font-sans, \"Inter\", sans-serif)",
59
+ fontSize: "12px",
60
+ fontWeight: "600",
61
+ gap: "8px",
62
+ height: "28px",
63
+ letterSpacing: "var(--tbf-ui-btn-root-letter-spacing, normal)",
64
+ minHeight: "var(--tbf-surf-btn-root-height, var(--tbf-ui-btn-root-height, 28px))",
65
+ padding: "0 12px",
66
+ paddingBlock: "0",
67
+ radius: ui.radiusMd,
68
+ textTransform: "var(--tbf-ui-btn-root-text-transform, none)",
69
+ transition: [
70
+ "var(--tbf-ui-btn-root-transition, background-color var(--tbf-transition-fast, .18s)",
71
+ "var(--tbf-transition-easing, ease), border-color var(--tbf-transition-fast, .18s)",
72
+ "var(--tbf-transition-easing, ease), color var(--tbf-transition-fast, .18s)",
73
+ "var(--tbf-transition-easing, ease))",
74
+ ].join(" "),
75
+ whiteSpace: "var(--tbf-ui-btn-root-white-space, nowrap)",
76
+ width: "var(--tbf-ui-btn-root-width, auto)",
77
+ },
78
+ sizes: {
79
+ lg: {
80
+ fontSize: "13px",
81
+ height: "34px",
82
+ paddingInline: "14px",
83
+ },
84
+ md: {
85
+ fontSize: "12px",
86
+ height: "28px",
87
+ paddingInline: "12px",
88
+ },
89
+ sm: {
90
+ fontSize: "11px",
91
+ height: "24px",
92
+ paddingInline: "9px",
93
+ },
94
+ },
95
+ slots: {
96
+ icon: {
97
+ color: token.color("gray", 300),
98
+ },
99
+ },
100
+ states: {
101
+ disabled: {
102
+ opacity: "0.55",
103
+ },
104
+ hover: {
105
+ background: token.color("gray", 800),
106
+ borderColor: token.color("gray", 700),
107
+ color: token.color("gray", 200),
108
+ iconColor: "currentColor",
109
+ },
110
+ },
111
+ tones: {
112
+ highlight: {
113
+ background: token.color("gray", 100),
114
+ borderColor: token.color("gray", 100),
115
+ color: token.color("gray", 950),
116
+ iconColor: token.color("gray", 800),
117
+ states: {
118
+ hover: {
119
+ background: token.color("gray", 200),
120
+ borderColor: token.color("gray", 100),
121
+ color: token.color("gray", 900),
122
+ iconColor: "currentColor",
123
+ },
124
+ },
125
+ },
126
+ },
127
+ },
128
+ card: {
129
+ body: {
130
+ divider: {
131
+ background: semantic.borderSurface1,
132
+ },
133
+ },
134
+ iconRadius: "var(--radius-md, var(--tbf-radius, 0))",
135
+ root: {
136
+ background: semantic.backgroundPage,
137
+ border: token.border(semantic.borderSurface1),
138
+ color: "var(--tbf-text, #000)",
139
+ minHeight: ui.heightXs4,
140
+ padding: "14px 14px 12px 14px",
141
+ radius: ui.radiusLg,
142
+ transition: [
143
+ "background-color var(--tbf-transition-fast, .18s) var(--tbf-transition-easing, ease),",
144
+ "border-color var(--tbf-transition-fast, .18s) var(--tbf-transition-easing, ease), color",
145
+ "var(--tbf-transition-fast, .18s) var(--tbf-transition-easing, ease)",
146
+ ].join(" "),
147
+ },
148
+ row: {
149
+ background: "transparent",
150
+ border: token.border(semantic.borderSurface1),
151
+ padding: "9px 12px",
152
+ radius: ui.radiusLg,
153
+ states: {
154
+ excluded: {
155
+ border: "var(--border-surface-1)",
156
+ },
157
+ hover: {
158
+ background: token.color("gray", 900),
159
+ },
160
+ selected: {
161
+ background: semantic.backgroundSurface1,
162
+ },
163
+ },
164
+ },
165
+ sectionPadding: "var(--tbf-surf-card-root-padding, 12px)",
166
+ sizes: {
167
+ lg: {
168
+ padding: "var(--tbf-gap-lg, 40px)",
169
+ },
170
+ md: {
171
+ padding: "var(--tbf-gap-md, 24px)",
172
+ },
173
+ sm: {
174
+ padding: "var(--tbf-gap-sm, 12px)",
175
+ },
176
+ },
177
+ states: {
178
+ hover: {
179
+ border: "var(--tbf-focus, #000)",
180
+ },
181
+ },
182
+ title: {
183
+ fontSize: "15px",
184
+ fontWeight: "700",
185
+ margin: "0 0 10px 0",
186
+ },
187
+ tones: {
188
+ accent: {
189
+ color: "var(--tbf-page, #fff)",
190
+ states: {
191
+ hover: {
192
+ background: "var(--tbf-ui-card-tone-accent-state-hover-bg, transparent)",
193
+ border: "var(--tbf-ui-card-tone-accent-state-hover-border, currentColor)",
194
+ },
195
+ },
196
+ textMuted: "color-mix(in srgb, currentColor 70%, transparent)",
197
+ },
198
+ inverse: {
199
+ color: "var(--tbf-page, #fff)",
200
+ states: {
201
+ hover: {
202
+ background: "var(--tbf-ui-card-tone-inverse-state-hover-bg, transparent)",
203
+ border: "var(--tbf-ui-card-tone-inverse-state-hover-border, currentColor)",
204
+ },
205
+ },
206
+ textMuted: "color-mix(in srgb, currentColor 62%, transparent)",
207
+ },
208
+ muted: {
209
+ color: "var(--tbf-text, #000)",
210
+ states: {
211
+ hover: {
212
+ background: "var(--tbf-ui-card-tone-muted-state-hover-bg, transparent)",
213
+ border: "var(--tbf-ui-card-tone-muted-state-hover-border, currentColor)",
214
+ },
215
+ },
216
+ },
217
+ surface: {
218
+ background: "var(--tbf-ui-card-tone-surface-bg, var(--tbf-ui-card-root-bg, transparent))",
219
+ border: "var(--tbf-ui-card-tone-surface-border, currentColor)",
220
+ states: {
221
+ hover: {
222
+ background: "var(--tbf-ui-card-tone-surface-state-hover-bg, transparent)",
223
+ border: "var(--tbf-ui-card-tone-surface-state-hover-border, currentColor)",
224
+ },
225
+ },
226
+ },
227
+ },
228
+ },
229
+ hairline: {
230
+ cell: {
231
+ background: "var(--tbf-page, #fff)",
232
+ backgroundInverse: "var(--tbf-ink, #000)",
233
+ color: "var(--tbf-text, #000)",
234
+ colorInverse: "var(--tbf-page, #fff)",
235
+ padding: "var(--tbf-gap-md, 24px)",
236
+ textMuted: "color-mix(in srgb, currentColor 62%, transparent)",
237
+ textMutedInverse: "color-mix(in srgb, currentColor 62%, transparent)",
238
+ },
239
+ motion: {
240
+ duration: "0.3s",
241
+ easing: "ease",
242
+ },
243
+ root: {
244
+ background: "var(--tbf-border, color-mix(in srgb, currentColor 10%, transparent))",
245
+ border: "var(--tbf-border-width, 1px) solid var(--tbf-border, currentColor)",
246
+ gap: "var(--border-width, 1px)",
247
+ min: "16rem",
248
+ radius: "var(--radius-lg, var(--tbf-radius, 0))",
249
+ },
250
+ },
251
+ logo: {
252
+ root: {
253
+ height: "2rem",
254
+ max: "100%",
255
+ },
256
+ },
257
+ motif: {
258
+ root: {
259
+ color: "inherit",
260
+ opacity: "1",
261
+ },
262
+ },
263
+ scrollbar: {
264
+ root: {
265
+ gutter: "stable",
266
+ scheme: "light dark",
267
+ thumb: "auto",
268
+ track: "transparent",
269
+ width: "auto",
270
+ },
271
+ },
272
+ visibility: {
273
+ duration: "320ms",
274
+ easing: "cubic-bezier(0.22, 1, 0.36, 1)",
275
+ },
276
+ };
@@ -0,0 +1,20 @@
1
+ import type { FrontendConfig } from "@trebired/frontend/config";
2
+
3
+ export const systems = {
4
+ actions: true,
5
+ flash: true,
6
+ fullscreen: true,
7
+ icons: true,
8
+ inputs: true,
9
+ layer: true,
10
+ language: true,
11
+ layout: true,
12
+ modal: true,
13
+ popover: true,
14
+ primitives: true,
15
+ progress: true,
16
+ sidebar: true,
17
+ surface: true,
18
+ theme: true,
19
+ tooltip: true,
20
+ } satisfies FrontendConfig["systems"];
@@ -0,0 +1,42 @@
1
+ import { semantic, token, ui } from "./tokens";
2
+
3
+ export const primitiveTabs = {
4
+ list: {
5
+ gap: "0.5rem",
6
+ },
7
+ motion: {
8
+ duration: "290ms",
9
+ easing: "cubic-bezier(0.22, 1, 0.36, 1)",
10
+ offset: "8px",
11
+ },
12
+ nestedIndicatorColor: "var(--tbf-text-muted, currentColor)",
13
+ responsive: {
14
+ mobile: {
15
+ fontSize: "0.8125rem",
16
+ height: "2.25rem",
17
+ },
18
+ },
19
+ root: {
20
+ background: "transparent",
21
+ border: token.border(semantic.borderSurface1),
22
+ color: semantic.textColor,
23
+ fontFamily: ui.fontSans,
24
+ fontSize: "14px",
25
+ fontWeight: "inherit",
26
+ height: "34px",
27
+ paddingInline: "14px",
28
+ radius: ui.radiusSm,
29
+ },
30
+ states: {
31
+ active: {
32
+ background: semantic.backgroundSurface1,
33
+ borderColor: semantic.borderSurface1,
34
+ color: "var(--tbf-text, currentColor)",
35
+ },
36
+ hover: {
37
+ background: semantic.backgroundSurface1,
38
+ borderColor: semantic.borderSurface1,
39
+ color: "var(--tbf-text, currentColor)",
40
+ },
41
+ },
42
+ };
@@ -0,0 +1,37 @@
1
+ import { semantic } from "./tokens";
2
+
3
+ export const primitiveTextLink = {
4
+ motion: {
5
+ duration: ".3s",
6
+ easing: "ease",
7
+ },
8
+ root: {
9
+ color: semantic.textMuted,
10
+ decorationUnderlineOffset: ".1875rem",
11
+ fontWeight: "inherit",
12
+ letterSpacing: "normal",
13
+ textDecorationColor: "currentColor",
14
+ textDecorationLine: "underline",
15
+ textDecorationStyle: "dotted",
16
+ textDecorationThickness: "1px",
17
+ textTransform: "none",
18
+ textUnderlineOffset: "3px",
19
+ underlineColor: "currentColor",
20
+ underlineGap: "calc(.35em + .375rem)",
21
+ underlineHeight: "max(1px, .0625em)",
22
+ underlineMidline: ".325em",
23
+ underlineRadius: ".3em",
24
+ },
25
+ states: {
26
+ active: {
27
+ color: "var(--tbf-ui-link-state-hover-color, var(--tbf-text, currentColor))",
28
+ underlineColor: "var(--tbf-ui-link-root-underline-color, currentColor)",
29
+ },
30
+ hover: {
31
+ color: semantic.textColor,
32
+ decorationLine: "var(--tbf-ui-link-root-decoration-line, none)",
33
+ textDecorationColor: "currentColor",
34
+ textDecorationStyle: "solid",
35
+ },
36
+ },
37
+ };
@@ -0,0 +1,50 @@
1
+ import type {
2
+ FrontendDesignConfig,
3
+ FrontendRuntimeConfig,
4
+ FrontendThemeConfig,
5
+ } from "@trebired/frontend/config";
6
+
7
+ import { token } from "./tokens";
8
+
9
+ export const semantics = {
10
+ selection: {
11
+ bg: token.colorMix(token.color("gray", 500), "50%"),
12
+ text: token.color("gray", 200),
13
+ },
14
+ status: {
15
+ error: { color: token.color("red", 500) },
16
+ success: { color: token.color("green", 500) },
17
+ warning: { color: token.color("yellow", 500) },
18
+ },
19
+ tone: {
20
+ blue: token.color("blue", 600),
21
+ cyan: token.color("cyan", 600),
22
+ error: token.color("red", 600),
23
+ gray: token.color("gray", 600),
24
+ green: token.color("green", 600),
25
+ info: token.color("blue", 600),
26
+ muted: token.color("gray", 600),
27
+ purple: token.color("ruby", 600),
28
+ red: token.color("red", 600),
29
+ success: token.color("green", 600),
30
+ warning: token.color("yellow", 600),
31
+ yellow: token.color("yellow", 600),
32
+ },
33
+ } satisfies NonNullable<FrontendDesignConfig["semantics"]>;
34
+
35
+ export const theme = {
36
+ dark: "dark",
37
+ defaultMode: "dark",
38
+ light: "light",
39
+ modes: {
40
+ dark: { scheme: "dark" },
41
+ light: { scheme: "light" },
42
+ },
43
+ } satisfies FrontendThemeConfig;
44
+
45
+ export const runtime = {
46
+ progress: {
47
+ color: token.color("gray", 600),
48
+ },
49
+ theme,
50
+ } satisfies FrontendRuntimeConfig;
@@ -0,0 +1,17 @@
1
+ import { token } from "./tokens";
2
+
3
+ export const primitiveToggle = {
4
+ active: {
5
+ color: token.color("gray", 100),
6
+ },
7
+ motion: {
8
+ duration: "140ms",
9
+ easing: "ease",
10
+ },
11
+ thumb: {
12
+ background: token.color("gray", 400),
13
+ },
14
+ track: {
15
+ background: token.color("gray", 100),
16
+ },
17
+ };
@@ -0,0 +1,37 @@
1
+ import { createFrontendTokenHelpers } from "@trebired/frontend/config";
2
+
3
+ import { palette } from "./palette";
4
+
5
+ const token = createFrontendTokenHelpers(palette);
6
+
7
+ const semantic = {
8
+ backgroundPage: token.semantic("background-page"),
9
+ backgroundSurface1: token.semantic("background-surface-1"),
10
+ backgroundSurface2: token.semantic("background-surface-2"),
11
+ borderSurface1: token.semantic("border-surface-1"),
12
+ borderSurface2: token.semantic("border-surface-2"),
13
+ focusColor: token.semantic("focus-color"),
14
+ scrollThumb: token.semantic("scroll-thumb"),
15
+ scrollThumbHover: token.semantic("scroll-thumb-hover"),
16
+ scrollTrack: token.semantic("scroll-track"),
17
+ surface1: token.semantic("surface-1"),
18
+ surface2: token.semantic("surface-2"),
19
+ textColor: token.semantic("text-color"),
20
+ textMuted: token.semantic("text-color-muted"),
21
+ };
22
+
23
+ const ui = {
24
+ borderWidth: token.variable("border-width"),
25
+ fontSans: token.variable("tbf-font-sans", "\"Inter\", sans-serif"),
26
+ gapSm: token.variable("tbf-gap-sm"),
27
+ heightXs4: token.variable("height-xs4", "35px"),
28
+ radiusSm: token.variable("radius-sm"),
29
+ radiusMd: token.variable("radius-md", token.variable("tbf-radius", "0")),
30
+ radiusLg: token.variable("radius-lg", token.variable("tbf-radius", "0")),
31
+ transitionFast: token.variable(
32
+ "transition-fast",
33
+ token.variable("tbf-transition-fast", "120ms ease"),
34
+ ),
35
+ };
36
+
37
+ export { semantic, token, ui };
@@ -0,0 +1,20 @@
1
+ export const typography = {
2
+ indent: {
3
+ border: "var(--tbf-border-width, 1px) solid var(--tbf-border, currentColor)",
4
+ flow: "0px",
5
+ size: "var(--tbf-gap-md, 24px)",
6
+ },
7
+ label: {
8
+ caps: {
9
+ color: "var(--tbf-text-muted, #000)",
10
+ fontSize: "0.72rem",
11
+ fontWeight: "600",
12
+ letterSpacing: "normal",
13
+ },
14
+ },
15
+ outline: {
16
+ color: "var(--tbf-text, #000)",
17
+ fill: "var(--tbf-page, #fff)",
18
+ width: "0.125rem",
19
+ },
20
+ };
@@ -0,0 +1,108 @@
1
+ import { semantic, token, ui } from "./tokens";
2
+
3
+ export const primitiveUpload = {
4
+ actions: {
5
+ gap: ui.gapSm,
6
+ },
7
+ content: {
8
+ gap: ui.gapSm,
9
+ },
10
+ cropper: {
11
+ actions: {
12
+ gap: ui.gapSm,
13
+ },
14
+ description: {
15
+ color: semantic.textMuted,
16
+ },
17
+ header: {
18
+ gap: "4px",
19
+ },
20
+ modal: {
21
+ maxHeight: "min(90vh, 920px)",
22
+ width: "min(960px, calc(100vw - 40px))",
23
+ },
24
+ rootGap: "var(--tbf-gap-md, 12px)",
25
+ stage: {
26
+ background: semantic.backgroundSurface1,
27
+ border: token.border(semantic.borderSurface1),
28
+ faceColor: token.colorMix(token.color("gray", 0), "14%"),
29
+ guideWidth: "1px",
30
+ height: "min(62vh, 640px)",
31
+ lineColor: token.color("gray", 0),
32
+ lineContrastColor: token.color("gray", 1000),
33
+ lineWidth: "1px",
34
+ minHeight: "320px",
35
+ overlayColor: token.colorMix(token.color("gray", 1000), "72%"),
36
+ pointBackground: token.color("gray", 0),
37
+ pointBorder: token.border(token.color("gray", 1000), "1px"),
38
+ pointInset: "0",
39
+ pointRadius: ui.radiusSm,
40
+ pointSize: "12px",
41
+ radius: ui.radiusLg,
42
+ },
43
+ },
44
+ filename: {
45
+ fontSize: "0.95rem",
46
+ lineHeight: "1.15",
47
+ },
48
+ hint: {
49
+ color: semantic.textMuted,
50
+ fontSize: "0.92rem",
51
+ lineHeight: "1.15",
52
+ },
53
+ list: {
54
+ gap: "4px",
55
+ maxHeight: "5.25rem",
56
+ paddingLeft: "18px",
57
+ },
58
+ meta: {
59
+ gap: "0.5rem",
60
+ },
61
+ preview: {
62
+ background: semantic.backgroundSurface2,
63
+ border: token.border(semantic.borderSurface1),
64
+ emptyColor: semantic.textMuted,
65
+ emptyFontSize: "0.82rem",
66
+ emptyLineHeight: "1.1",
67
+ emptyPadding: "4px",
68
+ radius: ui.radiusLg,
69
+ roundRadius: "999px",
70
+ size: "64px",
71
+ },
72
+ responsive: {
73
+ mobile: {
74
+ actionsGap: "0.25rem",
75
+ cropperModalMaxHeight: "calc(100vh - 24px)",
76
+ cropperModalWidth: "calc(100vw - 24px)",
77
+ cropperStageHeight: "min(52vh, 420px)",
78
+ cropperStageMinHeight: "260px",
79
+ surfaceGap: "0.5rem",
80
+ surfacePadding: "0.5rem",
81
+ },
82
+ },
83
+ root: {
84
+ color: semantic.textColor,
85
+ gap: ui.gapSm,
86
+ },
87
+ surface: {
88
+ background: semantic.backgroundSurface1,
89
+ border: token.border(semantic.borderSurface1),
90
+ color: semantic.textColor,
91
+ gap: "12px",
92
+ minHeight: "72px",
93
+ padding: "12px",
94
+ radius: ui.radiusLg,
95
+ states: {
96
+ drag: {
97
+ background: semantic.backgroundSurface2,
98
+ borderColor: semantic.focusColor,
99
+ shadow: "0 0 0 2px var(--tbf-focus, #000)",
100
+ },
101
+ dropBorderStyle: "dashed",
102
+ hasFiles: {
103
+ borderStyle: "solid",
104
+ },
105
+ },
106
+ transition: "border-color .14s ease, background .14s ease, box-shadow .14s ease",
107
+ },
108
+ };
@@ -0,0 +1,6 @@
1
+ export const primitiveWizard = {
2
+ motion: {
3
+ duration: "var(--tbf-transition-normal, 240ms)",
4
+ easing: "ease",
5
+ },
6
+ };
package/CHANGELOG.md CHANGED
@@ -4,6 +4,15 @@ All notable changes to `@trebired/configs` will be documented here.
4
4
 
5
5
  This project follows semantic versioning once published.
6
6
 
7
+ ## 0.5.0
8
+
9
+ - Added the `@trebired/frontend` preset at `.trebired/frontend/config.ts`. An application loads it with `presets: { use: ["@trebired/configs"] }`, the same shape as the Code Discipline preset. It sets fonts, icon packs, palette, semantic tokens, theme, runtime options, systems and every component token, motion included.
10
+ - Added `@trebired/frontend` `^29.10.0` as an optional peer dependency.
11
+
12
+ ## 0.4.0
13
+
14
+ - Retargeted the preset at `@trebired/code-discipline` 7.2.0. It named 7.1.2, so every project loading this preset failed its gate once code-discipline reached 7.2.
15
+
7
16
  ## 0.3.1
8
17
 
9
18
  ### Changed
package/README.md CHANGED
@@ -1,8 +1,8 @@
1
1
  # @trebired/configs
2
2
 
3
- Shared Trebired configuration presets for package tooling.
3
+ Shared Trebired configuration presets for Code Discipline and `@trebired/frontend`.
4
4
 
5
- This package owns reusable Trebired tool configuration payloads. Callers own their repository-specific overrides, banned patterns, source boundaries, and package-specific runtime configs.
5
+ This package owns reusable Trebired configuration payloads. Callers own their repository-specific overrides, banned patterns, source boundaries, and their own `@trebired/frontend` containers.
6
6
 
7
7
  ## Install
8
8
 
@@ -34,15 +34,40 @@ The root export points at `.trebired/code-discipline/config.ts`. The config decl
34
34
 
35
35
  Repositories add only their own overrides in `.trebired/code-discipline/config.ts`.
36
36
 
37
+ ### Frontend
38
+
39
+ `.trebired/frontend/config.ts` is a complete `@trebired/frontend` config: fonts, icon packs, the palette with its dark and light modes, semantic tokens, the theme, runtime options, systems, and every token of every package component, motion included. An application loads it the same way it loads the Code Discipline preset:
40
+
41
+ ```ts
42
+ import { defineConfig } from "@trebired/frontend/config";
43
+
44
+ import { containers } from "./containers";
45
+
46
+ export default defineConfig({
47
+ forVersion: "29.10.0",
48
+ presets: {
49
+ use: ["@trebired/configs"],
50
+ },
51
+ containers,
52
+ });
53
+ ```
54
+
55
+ `@trebired/frontend` reads the preset from this package's `.trebired/frontend/config.ts` and merges the application's own config over it. The preset declares the `@trebired/frontend` version it targets through `forVersion`.
56
+
57
+ The application installs the packages the preset names: `@fontsource/inter`, `remixicon`, `simple-icons` and `material-icon-theme`. A missing icon pack renders no icons from that pack.
58
+
59
+ `@trebired/frontend` is an optional peer dependency. A repository that loads only the Code Discipline preset does not install it.
60
+
37
61
  ## Public API
38
62
 
39
- The package exports one default config object from the package root. It does not export helper functions.
63
+ The package root default-exports the Code Discipline preset. The frontend preset is read from `.trebired/frontend/config.ts` by `@trebired/frontend`, not imported. The package exports no helper functions.
40
64
 
41
65
  ## What It Does Not Do
42
66
 
43
67
  This package does not:
44
68
 
45
69
  - Own application-specific banned patterns.
46
- - Own package runtime config.
70
+ - Own an application's frontend containers. The preset styles the package's components; each application declares its own boxes.
71
+ - Set `forVersion` for an application's frontend config. The application states the `@trebired/frontend` version it targets.
47
72
  - Wrap or replace `@trebired/code-discipline`.
48
73
  - Ship generated alias maps for consuming repositories.