@placeholderco/placeholder-ui 2.6.7 → 2.7.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.
Files changed (35) hide show
  1. package/README.md +58 -10
  2. package/dist/app.css +67 -33
  3. package/dist/cards/GitCard.svelte +1 -1
  4. package/dist/display/Avatar.svelte +2 -2
  5. package/dist/display/LinkCollection.svelte +1 -1
  6. package/dist/display/alert/Alert.svelte +1 -1
  7. package/dist/display/filetree/FileTreeItem.svelte +1 -1
  8. package/dist/editors/tiptap/LinkActionMenu.svelte +11 -6
  9. package/dist/editors/tiptap/TipTap.svelte +3 -3
  10. package/dist/editors/tiptap/TipTapBubble.svelte +5 -5
  11. package/dist/editors/tiptap/buttonLink.d.ts +1 -1
  12. package/dist/editors/tiptap/buttonLink.js +3 -1
  13. package/dist/editors/tiptap/toolbar/AlertButton.svelte +2 -2
  14. package/dist/editors/tiptap/toolbar/ButtonLinkButton.svelte +5 -3
  15. package/dist/editors/tiptap/toolbar/ColorButton.svelte +6 -6
  16. package/dist/editors/tiptap/toolbar/LinkButton.svelte +9 -9
  17. package/dist/editors/tiptap/toolbar/TableButton.svelte +2 -2
  18. package/dist/editors/tiptap/toolbar/ToolbarButton.svelte +3 -3
  19. package/dist/form/CronBuilder.svelte +3 -3
  20. package/dist/form/DatePicker.svelte +8 -8
  21. package/dist/form/DateRangePicker.svelte +9 -9
  22. package/dist/form/DateTimePicker.svelte +8 -8
  23. package/dist/layout/Navbar.svelte +5 -5
  24. package/dist/layout/NavbarItemView.svelte +4 -4
  25. package/dist/ui/AccordionItem.svelte +20 -14
  26. package/dist/ui/Badge.svelte +69 -41
  27. package/dist/ui/Button.svelte +72 -64
  28. package/dist/ui/ButtonVariant.d.ts +1 -1
  29. package/dist/ui/Dropdown.svelte +1 -1
  30. package/dist/ui/Loader.svelte +1 -1
  31. package/dist/ui/ProgressBar.svelte +3 -3
  32. package/dist/ui/Tabs.svelte +1 -1
  33. package/dist/uiTheme.svelte.d.ts +39 -25
  34. package/dist/uiTheme.svelte.js +39 -45
  35. package/package.json +7 -7
package/README.md CHANGED
@@ -37,6 +37,7 @@ Or skip `AppShell` and import the token stylesheet yourself:
37
37
  ```ts
38
38
  import '@placeholderco/placeholder-ui/app.css';
39
39
  ```
40
+
40
41
  ## Branding
41
42
 
42
43
  Everything colour- and font-related resolves to `--ui-*` custom properties, so
@@ -53,16 +54,46 @@ applyTheme({
53
54
  colors: {
54
55
  primary: '#1e3a5f', // dark brand colour: solid buttons, headings
55
56
  accent: '#93c5fd', // light brand colour: highlights, dark-mode accent
56
- tertiary: '#a5f3fc' // supporting colour: links use its dark shade
57
+ tertiary: '#a5f3fc' // supporting color: links use its readable text color
57
58
  },
58
59
  fontFamily: "'Inter', system-ui, sans-serif",
59
60
  logo // raw SVG, rendered by <Logo />
60
61
  });
61
62
  ```
62
63
 
63
- Darker and lighter shades are derived automatically. Set `primaryDark`,
64
- `accentDark`, `tertiaryDark`, `tertiaryLight`, `link`, `linkHover` and the
65
- `*Contrast` text colours explicitly when you want full control.
64
+ Each brand color has independent `*HoverColor` and `*PressedColor` settings:
65
+ `primaryHoverColor`, `accentHoverColor`, `tertiaryHoverColor`,
66
+ `primaryPressedColor`, `accentPressedColor` and `tertiaryPressedColor`.
67
+ They are shared by solid, outline and subtle controls; subtle variants use
68
+ translucent hover fills where appropriate.
69
+
70
+ All three colors have the same two text roles:
71
+
72
+ | Setting | Used for |
73
+ | --- | --- |
74
+ | `primaryTextColor`, `accentTextColor`, `tertiaryTextColor` | Colored text and outline borders on page/paper surfaces. |
75
+ | `primaryContrastColor`, `accentContrastColor`, `tertiaryContrastColor` | Text and icons on the matching solid fill, including hover and pressed fills. |
76
+
77
+ For example, `primaryTextColor` styles a primary outline button at rest, while
78
+ `primaryContrastColor` styles the label on a filled primary button.
79
+ `focusColor`, `link` and `linkHover` control keyboard focus rings and links
80
+ independently. Changing a hover color does not change these other roles.
81
+
82
+ All role overrides are optional. By default, primary hover uses the accent text
83
+ color, accent hover uses tertiary, and tertiary hover uses accent. Primary pressed
84
+ is darkened from its base color. Primary text defaults to primary; accent and
85
+ tertiary text colors are darkened from their base colors. Accent and tertiary
86
+ pressed colors are lightened from tertiary (or accent when tertiary is omitted).
87
+ Primary contrast defaults to white; accent and tertiary contrast default to primary.
88
+
89
+ For existing configs, replace `primaryDark` with `primaryPressedColor`,
90
+ `accentDark` with `accentTextColor`, and `tertiaryDark` with `tertiaryTextColor`.
91
+ Replace `tertiaryLight` with both `accentPressedColor` and `tertiaryPressedColor`
92
+ to preserve both sets of pressed states. Set the hover colors separately when
93
+ customizing interactions. Rename `primaryContrast` and `accentContrast` to
94
+ `primaryContrastColor` and `accentContrastColor`. Their CSS tokens also gain the
95
+ `-color` suffix. CSS overrides use the corresponding kebab-case names,
96
+ such as `--ui-primary-hover-color` and `--ui-tertiary-text-color`.
66
97
 
67
98
  ### Light and dark values
68
99
 
@@ -104,13 +135,23 @@ Override the tokens in any stylesheet loaded after the library:
104
135
  --ui-primary-rgb: 30 58 95;
105
136
  --ui-primary-rgbc: 30, 58, 95;
106
137
  --ui-primary: rgb(var(--ui-primary-rgb));
107
- --ui-primary-dark: #12253d;
138
+ --ui-primary-hover-color: #1d4ed8;
139
+ --ui-primary-pressed-color: #12253d;
140
+ --ui-primary-text-color: #1e3a5f;
141
+ --ui-primary-contrast-color: #ffffff;
108
142
  --ui-accent-rgb: 147 197 253;
109
143
  --ui-accent-rgbc: 147, 197, 253;
110
144
  --ui-accent: rgb(var(--ui-accent-rgb));
111
- --ui-accent-dark: #1d4ed8;
145
+ --ui-accent-hover-color: #a5f3fc;
146
+ --ui-accent-pressed-color: #cffafe;
147
+ --ui-accent-text-color: #1d4ed8;
148
+ --ui-accent-contrast-color: #1e3a5f;
112
149
  --ui-tertiary: #a5f3fc;
113
- --ui-tertiary-dark: #0e7490;
150
+ --ui-tertiary-hover-color: #93c5fd;
151
+ --ui-tertiary-pressed-color: #cffafe;
152
+ --ui-tertiary-text-color: #0e7490;
153
+ --ui-tertiary-contrast-color: #1e3a5f;
154
+ --ui-focus-color: #1d4ed8;
114
155
  --ui-font-family: 'Inter', system-ui, sans-serif;
115
156
  }
116
157
  ```
@@ -118,15 +159,15 @@ Override the tokens in any stylesheet loaded after the library:
118
159
  The full token list, with comments on each role, is at the top of
119
160
  [src/lib/app.css](src/lib/app.css).
120
161
 
121
- ### Colour roles
162
+ ### Color roles
122
163
 
123
164
  Keep these relationships when choosing colours, because components assume them:
124
165
 
125
166
  | Token | Role |
126
167
  | --------------- | ------------------------------------------------------------ |
127
- | `--ui-primary` | Dark. Solid buttons, active states, headings. White text. |
168
+ | `--ui-primary` | Dark by default. Solid buttons and active backgrounds. |
128
169
  | `--ui-accent` | Light. Hovers, highlights, the accent in dark mode. |
129
- | `--ui-tertiary` | Light. Supporting fills; its `-dark` shade is used for links |
170
+ | `--ui-tertiary` | Light. Supporting fills; its text color is used for links |
130
171
 
131
172
  ### Fonts
132
173
 
@@ -147,6 +188,13 @@ variants named after the tokens: `primary`, `accent`, `tertiary`, plus
147
188
  `-outline` and `-subtle` forms, and the neutral `secondary`, `white`, `danger`
148
189
  and `auto-*` variants.
149
190
 
191
+ The additional coloured buttons use `tertiary`, `tertiary-outline` and
192
+ `tertiary-subtle`, configured through `colors.tertiary` and the existing
193
+ `--ui-tertiary*` tokens. The `secondary`, `secondary-subtle` and
194
+ `secondary-selected` variants retain their original neutral styles; existing
195
+ apps do not need to rename them. Existing tertiary colours and button styles
196
+ are preserved, with outline support added to the family.
197
+
150
198
  ## Theme (light / dark)
151
199
 
152
200
  ```ts
package/dist/app.css CHANGED
@@ -6,14 +6,18 @@
6
6
  * `applyTheme()` / `themeToCss()` from the package to generate them from a
7
7
  * `ThemeConfig` object.
8
8
  *
9
- * Colour roles (keep these relationships when re-branding):
10
- * --ui-primary dark brand colour. Used for solid buttons, headings, active
11
- * states. Text on top of it uses --ui-primary-contrast.
12
- * --ui-accent light brand colour. Used for highlights, hover states and as
9
+ * Color roles (keep these relationships when re-branding):
10
+ * --ui-primary dark brand color. Used for solid buttons and active
11
+ * states. Text on top of it uses --ui-primary-contrast-color.
12
+ * --ui-accent light brand color. Used for highlights, hover states and as
13
13
  * the adaptive accent in dark mode. Text on top of it uses
14
- * --ui-accent-contrast.
15
- * --ui-tertiary light supporting colour. Its *-dark shade is used for links
16
- * and subtle text.
14
+ * --ui-accent-contrast-color.
15
+ * --ui-tertiary light supporting color. Its text color is used for links
16
+ * and subtle text. Hover and pressed colors are separate
17
+ * from readable text and keyboard focus colors.
18
+ * Each color has the same roles: base fill, hover fill, pressed fill,
19
+ * text on page/paper surfaces (-text-color), and foreground on its filled
20
+ * controls (-contrast-color). Text and contrast colors are independent.
17
21
  */
18
22
 
19
23
  :root {
@@ -22,29 +26,37 @@
22
26
  ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif, 'Apple Color Emoji',
23
27
  'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
24
28
 
25
- /* ---- Brand colours (neutral defaults) ---- */
29
+ /* ---- Brand colors (neutral defaults) ---- */
26
30
  --ui-primary-rgb: 30 58 95;
27
31
  --ui-primary-rgbc: 30, 58, 95;
28
32
  --ui-primary: rgb(var(--ui-primary-rgb));
29
- --ui-primary-dark: #12253d;
30
- --ui-primary-contrast: #ffffff;
33
+ --ui-primary-hover-color: var(--ui-accent-text-color);
34
+ --ui-primary-pressed-color: #12253d;
35
+ --ui-primary-text-color: var(--ui-primary);
36
+ --ui-primary-contrast-color: #ffffff;
31
37
 
32
38
  --ui-accent-rgb: 147 197 253;
33
39
  --ui-accent-rgbc: 147, 197, 253;
34
40
  --ui-accent: rgb(var(--ui-accent-rgb));
35
- --ui-accent-dark: #1d4ed8;
36
- --ui-accent-contrast: var(--ui-primary);
41
+ --ui-accent-hover-color: var(--ui-tertiary);
42
+ --ui-accent-pressed-color: #cffafe;
43
+ --ui-accent-text-color: #1d4ed8;
44
+ --ui-accent-contrast-color: var(--ui-primary);
37
45
 
38
46
  --ui-tertiary-rgb: 165 243 252;
39
47
  --ui-tertiary-rgbc: 165, 243, 252;
40
48
  --ui-tertiary: rgb(var(--ui-tertiary-rgb));
41
- --ui-tertiary-dark-rgbc: 14, 116, 144;
42
- --ui-tertiary-dark: rgb(var(--ui-tertiary-dark-rgbc));
43
- --ui-tertiary-light: #cffafe;
49
+ --ui-tertiary-hover-color: var(--ui-accent);
50
+ --ui-tertiary-pressed-color: #cffafe;
51
+ --ui-tertiary-text-color: #0e7490;
52
+ --ui-tertiary-contrast-color: var(--ui-primary);
44
53
 
45
- /* ---- Link colours ---- */
46
- --ui-link-color: var(--ui-tertiary-dark);
47
- --ui-link-hover-color: var(--ui-accent-dark);
54
+ /* ---- Keyboard focus ---- */
55
+ --ui-focus-color: var(--ui-accent-text-color);
56
+
57
+ /* ---- Link colors ---- */
58
+ --ui-link-color: var(--ui-tertiary-text-color);
59
+ --ui-link-hover-color: var(--ui-accent-text-color);
48
60
 
49
61
  /* ---- Surfaces and text (light mode) ---- */
50
62
  --off-white: rgb(221, 221, 221);
@@ -125,7 +137,7 @@ textarea {
125
137
 
126
138
  header a {
127
139
  text-decoration: none;
128
- color: var(--ui-primary);
140
+ color: var(--ui-primary-text-color);
129
141
  transition: color 200ms;
130
142
  }
131
143
 
@@ -178,11 +190,11 @@ a:hover {
178
190
  The classes live here rather than in the editor so the saved HTML looks the
179
191
  same wherever it is rendered. The look follows the Button component. */
180
192
  .editor-button {
181
- --editor-button-fg: var(--ui-primary-contrast);
193
+ --editor-button-fg: var(--ui-primary-contrast-color);
182
194
  --editor-button-bg: var(--ui-primary);
183
195
  --editor-button-border: transparent;
184
- --editor-button-hover-fg: var(--ui-primary-contrast);
185
- --editor-button-hover-bg: var(--ui-accent-dark);
196
+ --editor-button-hover-fg: var(--ui-primary-contrast-color);
197
+ --editor-button-hover-bg: var(--ui-primary-hover-color);
186
198
  --editor-button-hover-border: transparent;
187
199
  display: inline-block;
188
200
  padding: 0.5rem 1rem;
@@ -209,45 +221,67 @@ a:hover {
209
221
  }
210
222
 
211
223
  .editor-button:focus-visible {
212
- outline: solid 0.125rem var(--ui-accent-dark);
224
+ outline: solid 0.125rem var(--ui-focus-color);
213
225
  outline-offset: 2px;
214
226
  }
215
227
 
216
228
  .editor-button-accent {
217
- --editor-button-fg: var(--ui-accent-contrast);
229
+ --editor-button-fg: var(--ui-accent-contrast-color);
218
230
  --editor-button-bg: var(--ui-accent);
219
- --editor-button-hover-fg: var(--ui-primary);
220
- --editor-button-hover-bg: var(--ui-tertiary);
231
+ --editor-button-hover-fg: var(--ui-accent-contrast-color);
232
+ --editor-button-hover-bg: var(--ui-accent-hover-color);
221
233
  }
222
234
 
223
235
  .editor-button-tertiary {
224
- --editor-button-fg: var(--ui-primary);
236
+ --editor-button-fg: var(--ui-tertiary-contrast-color);
225
237
  --editor-button-bg: var(--ui-tertiary);
226
- --editor-button-hover-fg: var(--ui-primary);
227
- --editor-button-hover-bg: var(--ui-accent);
238
+ --editor-button-hover-fg: var(--ui-tertiary-contrast-color);
239
+ --editor-button-hover-bg: var(--ui-tertiary-hover-color);
228
240
  }
229
241
 
230
242
  .editor-button-primary-outline,
243
+ .editor-button-tertiary-outline,
231
244
  .editor-button-accent-outline {
232
245
  border: 1px solid var(--editor-button-border);
233
246
  --editor-button-bg: transparent;
234
- --editor-button-hover-bg: transparent;
235
247
  }
236
248
 
237
249
  .editor-button-primary-outline {
238
250
  --editor-button-fg: var(--ui-primary);
239
251
  --editor-button-border: var(--ui-primary);
240
- --editor-button-hover-fg: var(--ui-accent-dark);
241
- --editor-button-hover-border: var(--ui-accent-dark);
252
+ --editor-button-hover-fg: var(--ui-primary-contrast-color);
253
+ --editor-button-hover-bg: var(--ui-primary);
254
+ --editor-button-hover-border: var(--ui-primary);
242
255
  }
243
256
 
244
257
  .editor-button-accent-outline {
245
258
  --editor-button-fg: var(--ui-accent);
246
259
  --editor-button-border: var(--ui-accent);
247
- --editor-button-hover-fg: var(--ui-tertiary);
260
+ --editor-button-hover-fg: var(--ui-accent-contrast-color);
261
+ --editor-button-hover-bg: var(--ui-accent);
262
+ --editor-button-hover-border: var(--ui-accent);
263
+ }
264
+
265
+ .editor-button-tertiary-outline {
266
+ --editor-button-fg: var(--ui-tertiary);
267
+ --editor-button-border: var(--ui-tertiary);
268
+ --editor-button-hover-fg: var(--ui-tertiary-contrast-color);
269
+ --editor-button-hover-bg: var(--ui-tertiary);
248
270
  --editor-button-hover-border: var(--ui-tertiary);
249
271
  }
250
272
 
273
+ .editor-button-tertiary-subtle {
274
+ --editor-button-fg: var(--ui-tertiary);
275
+ --editor-button-bg: transparent;
276
+ --editor-button-hover-fg: var(--ui-tertiary-contrast-color);
277
+ --editor-button-hover-bg: var(--ui-tertiary);
278
+ }
279
+
280
+ .editor-button-tertiary-outline:focus-visible,
281
+ .editor-button-tertiary-subtle:focus-visible {
282
+ outline-color: var(--ui-focus-color);
283
+ }
284
+
251
285
  .editor-button-sm {
252
286
  padding: 0.375rem 0.75rem;
253
287
  font-size: 0.8125rem;
@@ -83,7 +83,7 @@
83
83
  font-size: 1.25rem;
84
84
  font-style: normal;
85
85
  font-weight: 600;
86
- color: var(--ui-primary);
86
+ color: var(--ui-primary-text-color);
87
87
  }
88
88
 
89
89
  .git-jobtitle {
@@ -121,7 +121,7 @@
121
121
 
122
122
  &:hover {
123
123
  background: var(--ui-primary);
124
- color: var(--text-color);
124
+ color: var(--ui-primary-contrast-color);
125
125
  }
126
126
  }
127
127
 
@@ -166,7 +166,7 @@
166
166
  .avatar {
167
167
  &:hover {
168
168
  background: var(--ui-accent);
169
- color: black;
169
+ color: var(--ui-accent-contrast-color);
170
170
  }
171
171
  }
172
172
  }
@@ -135,7 +135,7 @@
135
135
  align-items: center;
136
136
  gap: 0.5rem;
137
137
  text-decoration: none;
138
- color: var(--ui-tertiary-dark);
138
+ color: var(--ui-link-color);
139
139
  font-weight: normal;
140
140
 
141
141
  &:hover {
@@ -67,7 +67,7 @@
67
67
 
68
68
  .alert-title,
69
69
  .icon {
70
- color: var(--ui-primary);
70
+ color: var(--ui-primary-text-color);
71
71
  }
72
72
  }
73
73
 
@@ -350,7 +350,7 @@
350
350
  .ft-icon {
351
351
  display: inline-flex;
352
352
  flex-shrink: 0;
353
- color: var(--ui-primary);
353
+ color: var(--ui-primary-text-color);
354
354
  }
355
355
 
356
356
  :global(.dark) .ft-icon {
@@ -202,7 +202,7 @@
202
202
  border: 1px solid var(--border-color);
203
203
  border-radius: 4px;
204
204
  background: var(--paper-body-bg);
205
- color: var(--ui-tertiary-dark);
205
+ color: var(--ui-link-color);
206
206
  cursor: pointer;
207
207
  font: inherit;
208
208
  font-size: 13px;
@@ -263,7 +263,7 @@
263
263
 
264
264
  .link-icon-button:hover {
265
265
  background: rgba(var(--ui-primary-rgbc), 0.1);
266
- color: var(--ui-primary);
266
+ color: var(--ui-primary-text-color);
267
267
  }
268
268
 
269
269
  :global(.dark) .link-icon-button:hover {
@@ -273,17 +273,22 @@
273
273
 
274
274
  .link-icon-button.primary {
275
275
  background: var(--ui-primary);
276
- color: white;
276
+ color: var(--ui-primary-contrast-color);
277
277
  }
278
278
 
279
279
  .link-icon-button.primary:hover {
280
- background: var(--ui-tertiary-dark);
281
- color: white;
280
+ background: var(--ui-primary-hover-color);
281
+ color: var(--ui-primary-contrast-color);
282
282
  }
283
283
 
284
284
  :global(.dark) .link-icon-button.primary {
285
285
  background: var(--ui-accent);
286
- color: var(--ui-primary);
286
+ color: var(--ui-accent-contrast-color);
287
+ }
288
+
289
+ :global(.dark) .link-icon-button.primary:hover {
290
+ background: var(--ui-accent-hover-color);
291
+ color: var(--ui-accent-contrast-color);
287
292
  }
288
293
 
289
294
  .link-icon-button.danger:hover {
@@ -609,7 +609,7 @@
609
609
  border-radius: 3px;
610
610
  font-family: 'Monaco', 'Courier New', monospace;
611
611
  font-size: 0.9em;
612
- color: var(--ui-accent-dark);
612
+ color: var(--ui-accent-text-color);
613
613
  }
614
614
 
615
615
  :global(.dark) .editor-content :global(.ProseMirror code) {
@@ -617,7 +617,7 @@
617
617
  }
618
618
 
619
619
  .editor-content :global(.ProseMirror a) {
620
- color: var(--ui-tertiary-dark);
620
+ color: var(--ui-link-color);
621
621
  text-decoration: underline;
622
622
  cursor: pointer;
623
623
  pointer-events: auto;
@@ -780,7 +780,7 @@
780
780
  }
781
781
 
782
782
  .editor-content :global(.ProseMirror .alert-default .alert-title) {
783
- color: var(--ui-primary);
783
+ color: var(--ui-primary-text-color);
784
784
  }
785
785
 
786
786
  /* Danger variant */
@@ -287,7 +287,7 @@
287
287
 
288
288
  if (bubbleMenuElement && editable) {
289
289
  extensions.push(
290
- BubbleMenu.configure({
290
+ BubbleMenu.extend({ name: 'formatBubbleMenu' }).configure({
291
291
  pluginKey: 'formatBubbleMenu',
292
292
  element: bubbleMenuElement,
293
293
  shouldShow: ({ editor, state }) => {
@@ -300,7 +300,7 @@
300
300
 
301
301
  if (linkBubbleMenuElement) {
302
302
  extensions.push(
303
- BubbleMenu.configure({
303
+ BubbleMenu.extend({ name: 'linkActionBubbleMenu' }).configure({
304
304
  pluginKey: 'linkActionBubbleMenu',
305
305
  element: linkBubbleMenuElement,
306
306
  shouldShow: ({ editor }) => Boolean(editor.getAttributes('link').href),
@@ -546,7 +546,7 @@
546
546
  border-radius: 3px;
547
547
  font-family: 'Monaco', 'Courier New', monospace;
548
548
  font-size: 0.9em;
549
- color: var(--ui-accent-dark);
549
+ color: var(--ui-accent-text-color);
550
550
  }
551
551
 
552
552
  :global(.dark) .editor-content :global(.ProseMirror code) {
@@ -554,7 +554,7 @@
554
554
  }
555
555
 
556
556
  .editor-content :global(.ProseMirror a) {
557
- color: var(--ui-tertiary-dark);
557
+ color: var(--ui-link-color);
558
558
  text-decoration: underline;
559
559
  cursor: pointer;
560
560
  pointer-events: auto;
@@ -702,7 +702,7 @@
702
702
  }
703
703
 
704
704
  .editor-content :global(.ProseMirror .alert-default .alert-title) {
705
- color: var(--ui-primary);
705
+ color: var(--ui-primary-text-color);
706
706
  }
707
707
 
708
708
  .editor-content :global(.ProseMirror .alert-danger) {
@@ -6,7 +6,7 @@
6
6
  * (global, built on the `--ui-*` tokens) so the saved HTML looks the same in
7
7
  * the editor and wherever the consumer renders it.
8
8
  */
9
- export declare const editorButtonVariants: readonly ["primary", "accent", "tertiary", "primary-outline", "accent-outline"];
9
+ export declare const editorButtonVariants: readonly ["primary", "accent", "tertiary", "primary-outline", "accent-outline", "tertiary-outline", "tertiary-subtle"];
10
10
  export type EditorButtonVariant = (typeof editorButtonVariants)[number];
11
11
  export declare const editorButtonSizes: readonly ["sm", "md", "lg"];
12
12
  export type EditorButtonSize = (typeof editorButtonSizes)[number];
@@ -11,7 +11,9 @@ export const editorButtonVariants = [
11
11
  'accent',
12
12
  'tertiary',
13
13
  'primary-outline',
14
- 'accent-outline'
14
+ 'accent-outline',
15
+ 'tertiary-outline',
16
+ 'tertiary-subtle'
15
17
  ];
16
18
  export const editorButtonSizes = ['sm', 'md', 'lg'];
17
19
  export const EDITOR_BUTTON_CLASS = 'editor-button';
@@ -248,7 +248,7 @@
248
248
 
249
249
  .btn-primary {
250
250
  background: var(--ui-primary);
251
- color: var(--off-white);
251
+ color: var(--ui-primary-contrast-color);
252
252
  }
253
253
 
254
254
  .btn-primary:hover {
@@ -257,6 +257,6 @@
257
257
 
258
258
  :global(.dark) .btn-primary {
259
259
  background: var(--ui-accent);
260
- color: var(--ui-primary);
260
+ color: var(--ui-accent-contrast-color);
261
261
  }
262
262
  </style>
@@ -31,7 +31,9 @@
31
31
  { value: 'accent', label: 'Accent' },
32
32
  { value: 'tertiary', label: 'Tertiary' },
33
33
  { value: 'primary-outline', label: 'Primary outline' },
34
- { value: 'accent-outline', label: 'Accent outline' }
34
+ { value: 'accent-outline', label: 'Accent outline' },
35
+ { value: 'tertiary-outline', label: 'Tertiary outline' },
36
+ { value: 'tertiary-subtle', label: 'Tertiary subtle' }
35
37
  ];
36
38
 
37
39
  const sizes: { value: EditorButtonSize; label: string }[] = [
@@ -403,7 +405,7 @@
403
405
 
404
406
  .btn-primary {
405
407
  background: var(--ui-primary);
406
- color: var(--off-white);
408
+ color: var(--ui-primary-contrast-color);
407
409
  }
408
410
 
409
411
  .btn-primary:hover {
@@ -412,7 +414,7 @@
412
414
 
413
415
  :global(.dark) .btn-primary {
414
416
  background: var(--ui-accent);
415
- color: var(--ui-primary);
417
+ color: var(--ui-accent-contrast-color);
416
418
  }
417
419
 
418
420
  .btn-remove {
@@ -23,9 +23,9 @@
23
23
  export const defaultBrandColors: ColorSwatch[] = [
24
24
  { value: 'var(--ui-primary)', label: 'Primary' },
25
25
  { value: 'var(--ui-accent)', label: 'Accent' },
26
- { value: 'var(--ui-accent-dark)', label: 'Accent Dark' },
26
+ { value: 'var(--ui-accent-text-color)', label: 'Accent Text' },
27
27
  { value: 'var(--ui-tertiary)', label: 'Tertiary' },
28
- { value: 'var(--ui-tertiary-dark)', label: 'Tertiary Dark' }
28
+ { value: 'var(--ui-tertiary-text-color)', label: 'Tertiary Text' }
29
29
  ];
30
30
 
31
31
  let { editor, brandColors = defaultBrandColors }: Props = $props();
@@ -291,7 +291,7 @@
291
291
  padding: 6px 12px;
292
292
  border: none;
293
293
  background: var(--ui-tertiary);
294
- color: var(--ui-primary);
294
+ color: var(--ui-tertiary-contrast-color);
295
295
  border-radius: 4px;
296
296
  cursor: pointer;
297
297
  font-size: 13px;
@@ -301,15 +301,15 @@
301
301
  }
302
302
 
303
303
  .color-remove-button:hover {
304
- background: var(--ui-tertiary-dark);
304
+ background: var(--ui-tertiary-hover-color);
305
305
  }
306
306
 
307
307
  :global(.dark) .color-remove-button {
308
308
  background: var(--ui-accent);
309
- color: var(--ui-primary);
309
+ color: var(--ui-accent-contrast-color);
310
310
  }
311
311
 
312
312
  :global(.dark) .color-remove-button:hover {
313
- background: var(--ui-accent-dark);
313
+ background: var(--ui-accent-hover-color);
314
314
  }
315
315
  </style>
@@ -194,7 +194,7 @@
194
194
  }
195
195
 
196
196
  .link-checkbox-label:hover {
197
- color: var(--ui-primary);
197
+ color: var(--ui-primary-text-color);
198
198
  }
199
199
 
200
200
  :global(.dark) .link-checkbox-label:hover {
@@ -208,7 +208,7 @@
208
208
  padding: 6px 12px;
209
209
  border: none;
210
210
  background: var(--ui-primary);
211
- color: white;
211
+ color: var(--ui-primary-contrast-color);
212
212
  border-radius: 4px;
213
213
  cursor: pointer;
214
214
  font-size: 16px;
@@ -217,16 +217,16 @@
217
217
  }
218
218
 
219
219
  .link-submit-button:hover {
220
- background: var(--ui-tertiary-dark);
220
+ background: var(--ui-primary-hover-color);
221
221
  }
222
222
 
223
223
  :global(.dark) .link-submit-button {
224
224
  background: var(--ui-accent);
225
- color: var(--ui-primary);
225
+ color: var(--ui-accent-contrast-color);
226
226
  }
227
227
 
228
228
  :global(.dark) .link-submit-button:hover {
229
- background: var(--ui-accent-dark);
229
+ background: var(--ui-accent-hover-color);
230
230
  }
231
231
 
232
232
  .link-remove-button {
@@ -236,7 +236,7 @@
236
236
  padding: 6px 12px;
237
237
  border: none;
238
238
  background: var(--ui-tertiary);
239
- color: var(--ui-primary);
239
+ color: var(--ui-tertiary-contrast-color);
240
240
  border-radius: 4px;
241
241
  cursor: pointer;
242
242
  font-size: 16px;
@@ -245,15 +245,15 @@
245
245
  }
246
246
 
247
247
  .link-remove-button:hover {
248
- background: var(--ui-tertiary-dark);
248
+ background: var(--ui-tertiary-hover-color);
249
249
  }
250
250
 
251
251
  :global(.dark) .link-remove-button {
252
252
  background: var(--ui-accent);
253
- color: var(--ui-primary);
253
+ color: var(--ui-accent-contrast-color);
254
254
  }
255
255
 
256
256
  :global(.dark) .link-remove-button:hover {
257
- background: var(--ui-accent-dark);
257
+ background: var(--ui-accent-hover-color);
258
258
  }
259
259
  </style>
@@ -248,12 +248,12 @@
248
248
 
249
249
  .size-cell.highlighted {
250
250
  background: var(--ui-tertiary);
251
- border-color: var(--ui-tertiary-dark);
251
+ border-color: var(--ui-tertiary-text-color);
252
252
  }
253
253
 
254
254
  :global(.dark) .size-cell.highlighted {
255
255
  background: var(--ui-accent);
256
- border-color: var(--ui-accent-dark);
256
+ border-color: var(--ui-accent-text-color);
257
257
  }
258
258
 
259
259
  .size-label {