@journ/bloom 0.3.1 → 0.3.3

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 (58) hide show
  1. package/DESIGN.md +81 -80
  2. package/dist/avatar-parts.d.ts +2 -1
  3. package/dist/avatar-parts.js +6 -1
  4. package/dist/avatar.d.ts +2 -1
  5. package/dist/avatar.js +3 -2
  6. package/dist/breadcrumbs.d.ts +4 -0
  7. package/dist/breadcrumbs.js +15 -1
  8. package/dist/button.d.ts +7 -6
  9. package/dist/button.js +22 -13
  10. package/dist/card.d.ts +7 -2
  11. package/dist/card.js +2 -2
  12. package/dist/carousel-parts.d.ts +5 -2
  13. package/dist/carousel-parts.js +10 -1
  14. package/dist/carousel.d.ts +3 -1
  15. package/dist/carousel.js +4 -2
  16. package/dist/character-count-parts.d.ts +14 -0
  17. package/dist/character-count-parts.js +23 -0
  18. package/dist/character-count.d.ts +12 -0
  19. package/dist/character-count.js +12 -0
  20. package/dist/dropdown-menu-parts.d.ts +5 -1
  21. package/dist/dropdown-menu-parts.js +15 -1
  22. package/dist/dropdown-menu.d.ts +4 -1
  23. package/dist/dropdown-menu.js +5 -2
  24. package/dist/field-parts.d.ts +8 -1
  25. package/dist/field-parts.js +19 -1
  26. package/dist/field.d.ts +3 -1
  27. package/dist/field.js +4 -2
  28. package/dist/icon-button.d.ts +1 -1
  29. package/dist/icon-button.js +2 -1
  30. package/dist/lib/icon-tile.d.ts +3 -2
  31. package/dist/lib/icon-tile.js +6 -1
  32. package/dist/lib/text-styles.d.ts +3 -1
  33. package/dist/lib/text-styles.js +3 -1
  34. package/dist/lib/theme.d.ts +5 -1
  35. package/dist/lib/theme.js +5 -1
  36. package/dist/message.d.ts +6 -0
  37. package/dist/message.js +19 -1
  38. package/dist/nav-bar.js +2 -2
  39. package/dist/quantity-input-parts.d.ts +7 -3
  40. package/dist/quantity-input-parts.js +21 -4
  41. package/dist/quantity-input.d.ts +2 -1
  42. package/dist/quantity-input.js +3 -2
  43. package/dist/radio-parts.d.ts +7 -1
  44. package/dist/radio-parts.js +25 -2
  45. package/dist/radio.d.ts +3 -1
  46. package/dist/radio.js +4 -2
  47. package/dist/sidebar.d.ts +4 -0
  48. package/dist/sidebar.js +17 -0
  49. package/dist/stepper-parts.d.ts +4 -1
  50. package/dist/stepper-parts.js +17 -1
  51. package/dist/stepper.d.ts +4 -1
  52. package/dist/stepper.js +5 -2
  53. package/dist/styles.css +1 -1
  54. package/dist/toggle-group-parts.d.ts +3 -1
  55. package/dist/toggle-group-parts.js +12 -2
  56. package/dist/toggle-group.d.ts +3 -1
  57. package/dist/toggle-group.js +4 -2
  58. package/package.json +3 -3
package/DESIGN.md CHANGED
@@ -191,86 +191,87 @@ The typeface is `--font-bloom-display`. Load Hedvig Letters Sans (or your own fa
191
191
 
192
192
  Import per file (`@journ/bloom/card`). The library named in parentheses is what the nude part is built on.
193
193
 
194
- | Component | Parts |
195
- | ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
196
- | `Accordion` (Radix, animejs) | `Root` (`type`), `Item`, `Trigger`, `Content` |
197
- | `AlertDialog` (Radix) | `Root`, `Trigger`, `Content` (`tone`), `Title`, `Description`, `Actions`, `Cancel`, `Action` |
198
- | `Alert` | `Root` (`tone`), `Icon`, `Body`, `Title`, `Description`, `Actions` |
199
- | `AnimatedSize` (animejs) | single element, `width`, `height`. Glides to its content's size |
200
- | `Avatar` (Radix) | `Root`, `Image`, `Fallback` |
201
- | `Badge` | single element, `tone` |
202
- | `Breadcrumbs` | `Root`, `List`, `Item`, `Link`, `Page`, `Separator` |
203
- | `BulkBar` | `Root`, `Count`, `Actions` |
204
- | `Button` | single element, `tone`, `pending`, renders `<a>` with `href` |
205
- | `Calendar` | `Provider`, `Root`, `Frame`, `Header`, `Heading`, `Previous`, `Next`, `Weekdays`, `Days`, `Months`, `Years`, `useCalendar` |
206
- | `Card` | `Root` (`tone`), `Icon`, `Header`, `Title`, `Description`, `Content`, `Footer` |
207
- | `Checkbox` (Radix) | `Root` (supports `checked="indeterminate"`), `Indicator` |
208
- | `Carousel` (Embla) | `Root` (`opts`, `orientation`), `Content`, `Item`, `Previous`, `Next` |
209
- | `Chip` | `Root` (`tone`), `Dot`, `Remove`, `Tag` |
210
- | `Collapsible` (Radix, animejs) | `Root`, `Trigger`, `Content` |
211
- | `ContextMenu` (Radix) | `Root`, `Trigger`, `Content`, `Group`, `Label`, `Item`, `Separator` |
212
- | `Combobox` (cmdk) | `Provider`, `Root`, `Trigger`, `Value`, `Content`, `Title`, `Description`, `Frame`, `Input`, `List`, `Empty`, `Group`, `Item`, `ItemIndicator`, `useCombobox` |
213
- | `CommandPalette` (cmdk, Radix) | `Root` (`onSelect`, `shortcut`), `Trigger`, `Content`, plus the Combobox list parts `Frame`, `Input`, `List`, `Empty`, `Group`, `Item`, `ItemIndicator` |
214
- | `Composer` | `Root`, `Input` |
215
- | `DatePicker` | `Provider`, `Root`, `Trigger`, `Value`, `Content`, `Title`, `Description`, `Calendar` (wraps `Calendar.Root`), `useDatePicker` |
216
- | `DescriptionList` | `Root`, `Term`, `Details` |
217
- | `DateRangePicker` | `Root` (`value`, `locale`), `Trigger`, `Value`, `Content`, `Title`, `Description`, `Calendar`. Two clicks make a range |
218
- | `CurrencyInput` | `Root` (`value`, `currency`, `locale`, `min`, `max`), `Field` |
219
- | `DataTable` (TanStack Table v9) | `Root` (`data`, `columns`, `pageSize`, `onSelectionChange`), `Toolbar`, `ColumnPicker`, `Table`, `Pager`, `SelectionBar`. Helpers: `dataTableColumns`, `selectColumn`, `useDataTable` |
220
- | `DateInput` | `Root` (`value`, `locale`), `Field`. Parses typed dates in the locale's order |
221
- | `Dialog` (Radix) | `Root`, `Trigger`, `Close`, `Content` (`tone`), `Title`, `Description`, `Body`, `Actions` |
222
- | `FileDropzone` | `Root` (`accept`, `maxSize`, `multiple`, `onFilesAccepted`, `onFilesRejected`), `Icon`, `Title`, `Description` |
223
- | `Divider` (Radix) | single element, `orientation` |
224
- | `Drawer` (vaul) | `Root`, `Trigger`, `Close`, `Content`, `Title`, `Description`, `Body`, `Actions` |
225
- | `DropdownMenu` (Radix) | `Root`, `Trigger`, `Content`, `Group`, `Label`, `Item`, `Separator` |
226
- | `EmptyState` | `Root`, `Icon`, `Title`, `Description`, `Actions` |
227
- | `Field` (Radix) | `Root` (`invalid`), `Label`, `Control`, `Description`, `Error` |
228
- | `Heading` | single element, `level` (outline) and `size` (look) |
229
- | `Icon` | sizes any svg child, `size` |
230
- | `HoverCard` (Radix) | `Root`, `Trigger`, `Content` |
231
- | `IconButton` | single element, `tone`, `size` |
232
- | `Input` | single element, native `<input>` |
233
- | `Link` | single element, `asChild` styles a router link |
234
- | `ListRow` | `Root` (static), `Button` or `Link` (pressable), each with `tone`; `Leading`, `Content`, `Title`, `Subtitle`, `Trailing` |
235
- | `Markdown` (react-markdown) | single element, `components` overrides |
236
- | `MonthStepper` | `Root` (`value`, `locale`), `Previous`, `Label`, `Next` |
237
- | `Message` | `Root` (`from`), `Bubble`, `Highlight` |
238
- | `NavBar` | `Root`, `Item` (`aria-current="page"` marks active) |
239
- | `OtpInput` (Radix) | `Root`, `Slot` (one per character), `Hidden` |
240
- | `MultipleSelector` (cmdk) | `Root` (`value`, `fixed`, `max`), `Trigger`, `Value`, `Tags`, `Content`, then Combobox's `Frame`, `Input`, `List`, `Empty`, `Group`, `Item`, `ItemIndicator`, plus `Create` |
241
- | `NavigationMenu` (Radix) | `Root` (includes the viewport), `List`, `Item`, `Trigger`, `Content`, `Link` |
242
- | `Page` | `Root` (`tone`), `Content`, `Footer` |
243
- | `MonthPicker` | `Root` (`value`, `locale`), then the Calendar parts `Frame`, `Header`, `Heading`, `Previous`, `Next`, `Months`, `Years` |
244
- | `PageHeader` | `Root`, `Title`, `Actions` |
245
- | `Pagination` | `Root`, `Previous`, `List`, `Page`, `Gap`, `Next` |
246
- | `PillSelect` | single element, native `<select>` |
247
- | `Popover` (Radix) | `Root`, `Trigger`, `Content`, `Close` |
248
- | `Portal` | single element, `container`. Renders children outside the tree (copied from midday). Radix overlays already portal themselves |
249
- | `Progress` (Radix) | `Root` (`value`, `max`), `Indicator` (`tone`) |
250
- | `Radio` (Radix) | `Group`, `Item` |
251
- | `ScrollArea` (Radix) | `Root` (`type`), `Viewport`, `Scrollbar` (`orientation`), `Corner` |
252
- | `QuantityInput` | `Root` (`value`, `min`, `max`, `step`), `Decrement`, `Field`, `Increment` |
253
- | `Select` (Radix) | `Root`, `Trigger`, `Value`, `Content`, `Group`, `Label`, `Item`, `Separator` |
254
- | `Sidebar` | `Layout`, `Root`, `Header`, `Body`, `Section`, `Heading`, `Item`, `Footer`, `Content` (desktop only) |
255
- | `Skeleton` | single element |
256
- | `Spinner` | single element |
257
- | `Stepper` | `Root` (`value`), `Item` (`step`), `Indicator`, `Label`, `Description` |
258
- | `Sheet` (Radix) | `Root`, `Trigger`, `Close`, `Content` (`side`: right, left, top, bottom), `Title`, `Description`, `Body`, `Actions` |
259
- | `Slider` (Radix) | `Root`, `Track`, `Range`, `Thumb` (one per value) |
260
- | `Stack` (animejs) | `Root` (`defaultValue`), `Item` (`value`, `tone`), `Trigger`, `Content` |
261
- | `Stat` | `Root`, `Label`, `Value`, `Hint` |
262
- | `Switch` (Radix) | `Root`, `Thumb` |
263
- | `Table` | `Root`, `Caption`, `Head`, `Body`, `Row`, `Header`, `Cell` |
264
- | `TagInput` | `Root` (`validate`), `Tags`, `Tag`, `Field`. Enter or comma adds, Backspace removes, paste splits |
265
- | `Tabs` (Radix) | `Root`, `List`, `Trigger`, `Content` |
266
- | `Text` | single element, `size`, `tone` |
267
- | `Textarea` | single element, native `<textarea>` |
268
- | `ToggleGroup` (Radix) | `Root` (`type`), `Item` |
269
- | `TextMorph` (animejs) | single element, `as`. Only changed characters animate |
270
- | `TextShimmer` | single element, `as`. Loading text, CSS only |
271
- | `TimeRange` | `Root` (`value` as `{ start, stop }`), `Start`, `Stop`, `Duration` |
272
- | `Toast` (sonner) | `Provider`, `show`, `Root`, `Title`, `Description`, `Action` |
273
- | `Tooltip` (Radix) | `Root` (includes its provider), `Trigger`, `Content`, `Provider` |
194
+ | Component | Parts |
195
+ | ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
196
+ | `Accordion` (Radix, animejs) | `Root` (`type`), `Item`, `Trigger`, `Content` |
197
+ | `AlertDialog` (Radix) | `Root`, `Trigger`, `Content` (`tone`), `Title`, `Description`, `Actions`, `Cancel`, `Action` |
198
+ | `Alert` | `Root` (`tone`), `Icon`, `Body`, `Title`, `Description`, `Actions` |
199
+ | `AnimatedSize` (animejs) | single element, `width`, `height`. Glides to its content's size |
200
+ | `Avatar` (Radix) | `Root`, `Image`, `Fallback`, `Group`. `Group` overlaps its avatars and rings each in the surface color |
201
+ | `Badge` | single element, `tone` |
202
+ | `Breadcrumbs` | `Root`, `List` or `Display` (title type), `Item`, `Link`, `Page`, `Separator` (chevron) or `Slash` |
203
+ | `BulkBar` | `Root`, `Count`, `Actions` |
204
+ | `Button` | single element, `tone`, `size` (`md`, `lg`), `pending`, renders `<a>` with `href`. `lg` is the footer call to action |
205
+ | `Calendar` | `Provider`, `Root`, `Frame`, `Header`, `Heading`, `Previous`, `Next`, `Weekdays`, `Days`, `Months`, `Years`, `useCalendar` |
206
+ | `Card` | `Root` (`tone`), `Icon` (`tone`: `outline`, `coral`, `yellow`, `indigo`, `mint`, `sky`; outline by default, the colours are a faint wash), `Header`, `Title`, `Description`, `Content`, `Footer` |
207
+ | `Checkbox` (Radix) | `Root` (supports `checked="indeterminate"`), `Indicator` |
208
+ | `Carousel` (Embla) | `Root` (`opts`, `orientation`), `Content`, `Item`, `Previous`, `Next`, `Dots`, `Dot` (`index`). Dots take the text colour, square, the active one is a bar |
209
+ | `CharacterCount` | `Root` (`value`, `max`) or `Provider`, `Frame`, `Control` (wraps the input or textarea), `Count`, `Max`. `Max` draws the slash; the count turns coral past the limit |
210
+ | `Chip` | `Root` (`tone`), `Dot`, `Remove`, `Tag` |
211
+ | `Collapsible` (Radix, animejs) | `Root`, `Trigger`, `Content` |
212
+ | `ContextMenu` (Radix) | `Root`, `Trigger`, `Content`, `Group`, `Label`, `Item`, `Separator` |
213
+ | `Combobox` (cmdk) | `Provider`, `Root`, `Trigger`, `Value`, `Content`, `Title`, `Description`, `Frame`, `Input`, `List`, `Empty`, `Group`, `Item`, `ItemIndicator`, `useCombobox` |
214
+ | `CommandPalette` (cmdk, Radix) | `Root` (`onSelect`, `shortcut`), `Trigger`, `Content`, plus the Combobox list parts `Frame`, `Input`, `List`, `Empty`, `Group`, `Item`, `ItemIndicator` |
215
+ | `Composer` | `Root`, `Input` |
216
+ | `DatePicker` | `Provider`, `Root`, `Trigger`, `Value`, `Content`, `Title`, `Description`, `Calendar` (wraps `Calendar.Root`), `useDatePicker` |
217
+ | `DescriptionList` | `Root`, `Term`, `Details` |
218
+ | `DateRangePicker` | `Root` (`value`, `locale`), `Trigger`, `Value`, `Content`, `Title`, `Description`, `Calendar`. Two clicks make a range |
219
+ | `CurrencyInput` | `Root` (`value`, `currency`, `locale`, `min`, `max`), `Field` |
220
+ | `DataTable` (TanStack Table v9) | `Root` (`data`, `columns`, `pageSize`, `onSelectionChange`), `Toolbar`, `ColumnPicker`, `Table`, `Pager`, `SelectionBar`. Helpers: `dataTableColumns`, `selectColumn`, `useDataTable` |
221
+ | `DateInput` | `Root` (`value`, `locale`), `Field`. Parses typed dates in the locale's order |
222
+ | `Dialog` (Radix) | `Root`, `Trigger`, `Close`, `Content` (`tone`), `Title`, `Description`, `Body`, `Actions` |
223
+ | `FileDropzone` | `Root` (`accept`, `maxSize`, `multiple`, `onFilesAccepted`, `onFilesRejected`), `Icon`, `Title`, `Description` |
224
+ | `Divider` (Radix) | single element, `orientation` |
225
+ | `Drawer` (vaul) | `Root`, `Trigger`, `Close`, `Content`, `Title`, `Description`, `Body`, `Actions` |
226
+ | `DropdownMenu` (Radix) | `Root`, `Trigger`, `Content`, `Group`, `Label`, `Item`, `Separator`; `RadioGroup` (`value`, controlled), `RadioItem`, `ItemIndicator` (check on the selected item) |
227
+ | `EmptyState` | `Root`, `Icon`, `Title`, `Description`, `Actions` |
228
+ | `Field` (Radix) | `Root` (`invalid`), `Label`, `Control`, `Description`, `Error`, `Frame` (`tone`), `Action`. `Frame` is the inset-label tile |
229
+ | `Heading` | single element, `level` (outline) and `size` (look) |
230
+ | `Icon` | sizes any svg child, `size` |
231
+ | `HoverCard` (Radix) | `Root`, `Trigger`, `Content` |
232
+ | `IconButton` | single element, `tone`, `size` (`sm`, `md`, `lg`) |
233
+ | `Input` | single element, native `<input>` |
234
+ | `Link` | single element, `asChild` styles a router link |
235
+ | `ListRow` | `Root` (static), `Button` or `Link` (pressable), each with `tone`; `Leading`, `Content`, `Title`, `Subtitle`, `Trailing` |
236
+ | `Markdown` (react-markdown) | single element, `components` overrides |
237
+ | `MonthStepper` | `Root` (`value`, `locale`), `Previous`, `Label`, `Next` |
238
+ | `Message` | `Root` (`from`), `Bubble`, `Highlight`, `Sources`, `Suggestions`, `Suggestion`. A source row is a `ListRow.Link` |
239
+ | `NavBar` | `Root`, `Item` (`aria-current="page"` marks active). Items share the bar width equally |
240
+ | `OtpInput` (Radix) | `Root`, `Slot` (one per character), `Hidden` |
241
+ | `MultipleSelector` (cmdk) | `Root` (`value`, `fixed`, `max`), `Trigger`, `Value`, `Tags`, `Content`, then Combobox's `Frame`, `Input`, `List`, `Empty`, `Group`, `Item`, `ItemIndicator`, plus `Create` |
242
+ | `NavigationMenu` (Radix) | `Root` (includes the viewport), `List`, `Item`, `Trigger`, `Content`, `Link` |
243
+ | `Page` | `Root` (`tone`), `Content`, `Footer` |
244
+ | `MonthPicker` | `Root` (`value`, `locale`), then the Calendar parts `Frame`, `Header`, `Heading`, `Previous`, `Next`, `Months`, `Years` |
245
+ | `PageHeader` | `Root`, `Title`, `Actions` |
246
+ | `Pagination` | `Root`, `Previous`, `List`, `Page`, `Gap`, `Next` |
247
+ | `PillSelect` | single element, native `<select>` |
248
+ | `Popover` (Radix) | `Root`, `Trigger`, `Content`, `Close` |
249
+ | `Portal` | single element, `container`. Renders children outside the tree (copied from midday). Radix overlays already portal themselves |
250
+ | `Progress` (Radix) | `Root` (`value`, `max`), `Indicator` (`tone`) |
251
+ | `Radio` (Radix) | `Group`, `Item`, `Card` (`shape`: row, tile), `CardIndicator` |
252
+ | `ScrollArea` (Radix) | `Root` (`type`), `Viewport`, `Scrollbar` (`orientation`), `Corner` |
253
+ | `QuantityInput` | `Root` (`value`, `min`, `max`, `step`, `size`), `Decrement`, `Field`, `Increment`, `Unit`. `size='lg'` is the display stepper |
254
+ | `Select` (Radix) | `Root`, `Trigger`, `Value`, `Content`, `Group`, `Label`, `Item`, `Separator` |
255
+ | `Sidebar` | `Layout`, `Root` or `Rail` (icon only), `Header`, `Body`, `Section`, `Heading`, `Item` or `RailItem` (needs `aria-label`), `Footer`, `Content` (desktop only) |
256
+ | `Skeleton` | single element |
257
+ | `Spinner` | single element |
258
+ | `Stepper` | `Root` (`value`), `Item` (`step`), `Indicator`, `Label`, `Description` for a step list; `Pills` (`value`), `PillItem` (`step`), `Pill` for a row of milestone pills with the `Label` above |
259
+ | `Sheet` (Radix) | `Root`, `Trigger`, `Close`, `Content` (`side`: right, left, top, bottom), `Title`, `Description`, `Body`, `Actions` |
260
+ | `Slider` (Radix) | `Root`, `Track`, `Range`, `Thumb` (one per value) |
261
+ | `Stack` (animejs) | `Root` (`defaultValue`), `Item` (`value`, `tone`), `Trigger`, `Content` |
262
+ | `Stat` | `Root`, `Label`, `Value`, `Hint` |
263
+ | `Switch` (Radix) | `Root`, `Thumb` |
264
+ | `Table` | `Root`, `Caption`, `Head`, `Body`, `Row`, `Header`, `Cell` |
265
+ | `TagInput` | `Root` (`validate`), `Tags`, `Tag`, `Field`. Enter or comma adds, Backspace removes, paste splits |
266
+ | `Tabs` (Radix) | `Root`, `List`, `Trigger`, `Content` |
267
+ | `Text` | single element, `size`, `tone` |
268
+ | `Textarea` | single element, native `<textarea>` |
269
+ | `ToggleGroup` (Radix) | `Root` (`type`), `Item` for the segmented control; `Chips` (`type`), `Chip` for filter chips, with a `Chip.Dot` child for the colour |
270
+ | `TextMorph` (animejs) | single element, `as`. Only changed characters animate |
271
+ | `TextShimmer` | single element, `as`. Loading text, CSS only |
272
+ | `TimeRange` | `Root` (`value` as `{ start, stop }`), `Start`, `Stop`, `Duration` |
273
+ | `Toast` (sonner) | `Provider`, `show`, `Root`, `Title`, `Description`, `Action` |
274
+ | `Tooltip` (Radix) | `Root` (includes its provider), `Trigger`, `Content`, `Provider` |
274
275
 
275
276
  Card tones: `surface` (default, follows the theme), `coral`, `yellow`, `indigo`, `mint`, `sky`.
276
277
 
@@ -7,5 +7,6 @@ declare const Image: ({ className, alt, ...props }: ComponentPropsWithRef<typeof
7
7
  alt: string;
8
8
  }) => JSX.Element;
9
9
  declare const Fallback: Styled<typeof Nude.Fallback>;
10
+ declare const Group: Styled<"div">;
10
11
  //#endregion
11
- export { Fallback, Image, Root };
12
+ export { Fallback, Group, Image, Root };
@@ -1,5 +1,6 @@
1
1
  "use client";
2
2
  import { cn } from "./lib/cn.js";
3
+ import { stackedFill, stackedRing } from "./lib/theme.js";
3
4
  import { jsx } from "react/jsx-runtime";
4
5
  import * as Nude from "@journ/nude/avatar-parts";
5
6
  //#region src/avatar-parts.tsx
@@ -16,5 +17,9 @@ const Fallback = ({ className, ...props }) => /* @__PURE__ */ jsx(Nude.Fallback,
16
17
  ...props,
17
18
  className: cn("text-xs font-medium uppercase", className)
18
19
  });
20
+ const Group = ({ className, ...props }) => /* @__PURE__ */ jsx(Nude.Group, {
21
+ ...props,
22
+ className: cn("flex items-center [&>*+*]:-ml-2.5 [&>*]:bg-linear-to-b [&>*]:from-current/10 [&>*]:to-current/10", stackedFill, stackedRing, className)
23
+ });
19
24
  //#endregion
20
- export { Fallback, Image, Root };
25
+ export { Fallback, Group, Image, Root };
package/dist/avatar.d.ts CHANGED
@@ -1,9 +1,10 @@
1
- import { Fallback, Image, Root } from "./avatar-parts.js";
1
+ import { Fallback, Group, Image, Root } from "./avatar-parts.js";
2
2
  //#region src/avatar.d.ts
3
3
  declare const Avatar: {
4
4
  Root: typeof Root;
5
5
  Image: typeof Image;
6
6
  Fallback: typeof Fallback;
7
+ Group: typeof Group;
7
8
  };
8
9
  //#endregion
9
10
  export { Avatar };
package/dist/avatar.js CHANGED
@@ -1,9 +1,10 @@
1
- import { Fallback, Image, Root } from "./avatar-parts.js";
1
+ import { Fallback, Group, Image, Root } from "./avatar-parts.js";
2
2
  //#region src/avatar.tsx
3
3
  const Avatar = {
4
4
  Root,
5
5
  Image,
6
- Fallback
6
+ Fallback,
7
+ Group
7
8
  };
8
9
  //#endregion
9
10
  export { Avatar };
@@ -2,17 +2,21 @@ import { Styled } from "@journ/nude/styled";
2
2
  //#region src/breadcrumbs.d.ts
3
3
  declare const Root: Styled<"nav">;
4
4
  declare const List: Styled<"ol">;
5
+ declare const Display: Styled<"ol">;
5
6
  declare const Item: Styled<"li">;
6
7
  declare const Link: Styled<"a">;
7
8
  declare const Page: Styled<"span">;
8
9
  declare const Separator: Styled<"li">;
10
+ declare const Slash: Styled<"li">;
9
11
  declare const Breadcrumbs: {
10
12
  Root: typeof Root;
11
13
  List: typeof List;
14
+ Display: typeof Display;
12
15
  Item: typeof Item;
13
16
  Link: typeof Link;
14
17
  Page: typeof Page;
15
18
  Separator: typeof Separator;
19
+ Slash: typeof Slash;
16
20
  };
17
21
  //#endregion
18
22
  export { Breadcrumbs };
@@ -1,4 +1,5 @@
1
1
  import { cn } from "./lib/cn.js";
2
+ import { displayTitle } from "./lib/text-styles.js";
2
3
  import { ChevronRight } from "lucide-react";
3
4
  import { jsx } from "react/jsx-runtime";
4
5
  import { Breadcrumbs as Breadcrumbs$1 } from "@journ/nude/breadcrumbs";
@@ -12,6 +13,10 @@ const List = ({ className, ...props }) => /* @__PURE__ */ jsx(Breadcrumbs$1.List
12
13
  ...props,
13
14
  className: cn("flex flex-wrap items-center gap-1.5 text-sm/6", className)
14
15
  });
16
+ const Display = ({ className, ...props }) => /* @__PURE__ */ jsx(Breadcrumbs$1.List, {
17
+ ...props,
18
+ className: cn(displayTitle, "flex flex-wrap items-center gap-2", className)
19
+ });
15
20
  const Item = ({ className, ...props }) => /* @__PURE__ */ jsx(Breadcrumbs$1.Item, {
16
21
  ...props,
17
22
  className: cn("inline-flex items-center gap-1.5", className)
@@ -32,13 +37,22 @@ const Separator = ({ className, ...props }) => /* @__PURE__ */ jsx(Breadcrumbs$1
32
37
  className: cn("opacity-40 [&>svg]:size-4", className),
33
38
  children: /* @__PURE__ */ jsx(ChevronRight, {})
34
39
  });
40
+ const Slash = ({ className, ...props }) => /* @__PURE__ */ jsx(Breadcrumbs$1.Separator, {
41
+ role: "presentation",
42
+ "aria-hidden": true,
43
+ ...props,
44
+ className: cn("opacity-25", className),
45
+ children: "/"
46
+ });
35
47
  const Breadcrumbs = {
36
48
  Root,
37
49
  List,
50
+ Display,
38
51
  Item,
39
52
  Link,
40
53
  Page,
41
- Separator
54
+ Separator,
55
+ Slash
42
56
  };
43
57
  //#endregion
44
58
  export { Breadcrumbs };
package/dist/button.d.ts CHANGED
@@ -3,13 +3,14 @@ import { JSX, ReactNode } from "react";
3
3
  import { ButtonProps as ButtonProps$1 } from "@journ/nude/button";
4
4
  //#region src/button.d.ts
5
5
  type ButtonTone = "neutral" | "field" | "coral" | "yellow" | "ink" | "ghost" | "outline";
6
- declare const button: Recipe<{
6
+ type ButtonSize = "md" | "lg";
7
+ type ButtonVariants = {
7
8
  tone?: ButtonTone;
8
- }>;
9
- type ButtonProps = {
10
- tone?: ButtonTone;
11
- } & ButtonProps$1;
9
+ size?: ButtonSize;
10
+ };
11
+ declare const button: Recipe<ButtonVariants>;
12
+ type ButtonProps = ButtonVariants & ButtonProps$1;
12
13
  declare const buttonContent: (children: ReactNode, pending?: boolean) => JSX.Element;
13
- declare const Button: ({ tone, pending, className, children, ...props }: ButtonProps) => JSX.Element;
14
+ declare const Button: ({ tone, size, pending, className, children, ...props }: ButtonProps) => JSX.Element;
14
15
  //#endregion
15
16
  export { Button, type ButtonProps, button, buttonContent };
package/dist/button.js CHANGED
@@ -12,27 +12,36 @@ import { Button as Button$1 } from "@journ/nude/button";
12
12
  const button = tv({
13
13
  base: [
14
14
  interactive,
15
- controlSize,
16
15
  "rounded-bloom inline-flex items-center justify-center gap-x-2 px-4 font-medium",
17
- "[&>svg]:size-5 [&>svg]:shrink-0 sm:[&>svg]:size-4"
16
+ "[&>svg]:shrink-0"
18
17
  ],
19
- variants: { tone: {
20
- neutral: solidTones.neutral,
21
- field: control,
22
- coral: solidTones.coral,
23
- yellow: solidTones.yellow,
24
- ink: inkTone,
25
- ghost: "bg-transparent text-inherit",
26
- outline: "border border-current/20 bg-transparent text-inherit"
27
- } },
28
- defaultVariants: { tone: "neutral" }
18
+ variants: {
19
+ tone: {
20
+ neutral: solidTones.neutral,
21
+ field: control,
22
+ coral: solidTones.coral,
23
+ yellow: solidTones.yellow,
24
+ ink: inkTone,
25
+ ghost: "bg-transparent text-inherit",
26
+ outline: "border border-current/20 bg-transparent text-inherit"
27
+ },
28
+ size: {
29
+ md: `${controlSize} [&>svg]:size-5 sm:[&>svg]:size-4`,
30
+ lg: "h-12 gap-x-2.5 px-6 text-base/6 [&>svg]:size-4.5"
31
+ }
32
+ },
33
+ defaultVariants: {
34
+ tone: "neutral",
35
+ size: "md"
36
+ }
29
37
  });
30
38
  const buttonContent = (children, pending = false) => /* @__PURE__ */ jsxs(TouchTarget, { children: [pending && /* @__PURE__ */ jsx(Spinner, { "aria-hidden": true }), children] });
31
- const Button = ({ tone, pending = false, className, children, ...props }) => /* @__PURE__ */ jsx(Button$1, {
39
+ const Button = ({ tone, size, pending = false, className, children, ...props }) => /* @__PURE__ */ jsx(Button$1, {
32
40
  ...props,
33
41
  pending,
34
42
  className: button({
35
43
  tone,
44
+ size,
36
45
  class: cn(pending && "aria-busy:pointer-events-none", className)
37
46
  }),
38
47
  children: buttonContent(children, pending)
package/dist/card.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import { SurfaceTone } from "./lib/tones.js";
2
+ import { IconTileTone } from "./lib/icon-tile.js";
2
3
  import { ComponentPropsWithRef, JSX } from "react";
3
4
  import { Styled } from "@journ/nude/styled";
4
5
  //#region src/card.d.ts
@@ -11,7 +12,11 @@ declare const Title: Styled<"h3">;
11
12
  declare const Description: Styled<"p">;
12
13
  declare const Content: Styled<"div">;
13
14
  declare const Footer: Styled<"footer">;
14
- declare const Icon: Styled<"span">;
15
+ type CardIconTone = Exclude<IconTileTone, "soft">;
16
+ type IconProps = ComponentPropsWithRef<"span"> & {
17
+ tone?: CardIconTone;
18
+ };
19
+ declare const Icon: ({ tone, className, ...props }: IconProps) => JSX.Element;
15
20
  declare const Card: {
16
21
  Root: typeof Root;
17
22
  Icon: typeof Icon;
@@ -23,4 +28,4 @@ declare const Card: {
23
28
  };
24
29
  type CardProps = RootProps;
25
30
  //#endregion
26
- export { Card, type CardProps };
31
+ export { Card, type CardIconTone, type CardProps };
package/dist/card.js CHANGED
@@ -42,11 +42,11 @@ const Footer = ({ className, ...props }) => /* @__PURE__ */ jsx(Card$1.Footer, {
42
42
  ...props,
43
43
  className: cardFooter({ class: className })
44
44
  });
45
- const Icon = ({ className, ...props }) => /* @__PURE__ */ jsx(Card$1.Icon, {
45
+ const Icon = ({ tone = "outline", className, ...props }) => /* @__PURE__ */ jsx(Card$1.Icon, {
46
46
  ...props,
47
47
  className: iconTile({
48
48
  size: "md",
49
- tone: "outline",
49
+ tone,
50
50
  class: className
51
51
  })
52
52
  });
@@ -1,5 +1,5 @@
1
1
  import { IconButtonProps } from "./icon-button.js";
2
- import { JSX } from "react";
2
+ import { ComponentProps, JSX } from "react";
3
3
  import * as Nude from "@journ/nude/carousel-parts";
4
4
  import { Styled } from "@journ/nude/styled";
5
5
  //#region src/carousel-parts.d.ts
@@ -10,5 +10,8 @@ declare const Content: Styled<"div">;
10
10
  declare const Item: Styled<"div">;
11
11
  declare const Previous: ({ tone, size, className, children, ...props }: IconButtonProps) => JSX.Element;
12
12
  declare const Next: ({ tone, size, className, children, ...props }: IconButtonProps) => JSX.Element;
13
+ declare const Dots: Styled<"div">;
14
+ type DotProps = ComponentProps<typeof Nude.Dot>;
15
+ declare const Dot: ({ className, ...props }: DotProps) => JSX.Element;
13
16
  //#endregion
14
- export { Content, Item, Next, Previous, Root, type RootProps, useCarousel };
17
+ export { Content, Dot, Dots, Item, Next, Previous, Root, type RootProps, useCarousel };
@@ -1,5 +1,6 @@
1
1
  "use client";
2
2
  import { cn } from "./lib/cn.js";
3
+ import { interactive } from "./lib/interactive.js";
3
4
  import { stepButton } from "./step-button.js";
4
5
  import { ChevronLeft, ChevronRight } from "lucide-react";
5
6
  import { jsx } from "react/jsx-runtime";
@@ -49,5 +50,13 @@ const Next = ({ tone, size, className, children, ...props }) => {
49
50
  })
50
51
  });
51
52
  };
53
+ const Dots = ({ className, ...props }) => /* @__PURE__ */ jsx(Nude.Dots, {
54
+ ...props,
55
+ className: cn("flex items-center gap-1.5", className)
56
+ });
57
+ const Dot = ({ className, ...props }) => /* @__PURE__ */ jsx(Nude.Dot, {
58
+ ...props,
59
+ className: cn(interactive, "h-1.75 w-1.75 bg-current opacity-30 transition-[width,opacity,transform] duration-200 before:absolute before:-inset-x-0.75 before:-inset-y-4.75 data-[state=active]:w-5.5 data-[state=active]:opacity-100 pointer-fine:before:hidden", className)
60
+ });
52
61
  //#endregion
53
- export { Content, Item, Next, Previous, Root, useCarousel };
62
+ export { Content, Dot, Dots, Item, Next, Previous, Root, useCarousel };
@@ -1,4 +1,4 @@
1
- import { Content, Item, Next, Previous, Root, RootProps, useCarousel } from "./carousel-parts.js";
1
+ import { Content, Dot, Dots, Item, Next, Previous, Root, RootProps, useCarousel } from "./carousel-parts.js";
2
2
  //#region src/carousel.d.ts
3
3
  declare const Carousel: {
4
4
  Root: typeof Root;
@@ -6,6 +6,8 @@ declare const Carousel: {
6
6
  Item: typeof Item;
7
7
  Previous: typeof Previous;
8
8
  Next: typeof Next;
9
+ Dots: typeof Dots;
10
+ Dot: typeof Dot;
9
11
  };
10
12
  //#endregion
11
13
  export { Carousel, type RootProps as CarouselProps, useCarousel };
package/dist/carousel.js CHANGED
@@ -1,11 +1,13 @@
1
- import { Content, Item, Next, Previous, Root, useCarousel } from "./carousel-parts.js";
1
+ import { Content, Dot, Dots, Item, Next, Previous, Root, useCarousel } from "./carousel-parts.js";
2
2
  //#region src/carousel.tsx
3
3
  const Carousel = {
4
4
  Root,
5
5
  Content,
6
6
  Item,
7
7
  Previous,
8
- Next
8
+ Next,
9
+ Dots,
10
+ Dot
9
11
  };
10
12
  //#endregion
11
13
  export { Carousel, useCarousel };
@@ -0,0 +1,14 @@
1
+ import * as Nude from "@journ/nude/character-count-parts";
2
+ import { Styled } from "@journ/nude/styled";
3
+ //#region src/character-count-parts.d.ts
4
+ declare const useCharacterCount: typeof Nude.useCharacterCount;
5
+ declare const Provider: typeof Nude.Provider;
6
+ declare const Root: typeof Nude.Root;
7
+ declare const Control: typeof Nude.Control;
8
+ type RootProps = Nude.RootProps;
9
+ type CharacterCountContextValue = Nude.CharacterCountContextValue;
10
+ declare const Frame: Styled<"div">;
11
+ declare const Count: Styled<"span">;
12
+ declare const Max: typeof Nude.Max;
13
+ //#endregion
14
+ export { type CharacterCountContextValue, Control, Count, Frame, Max, Provider, Root, type RootProps, useCharacterCount };
@@ -0,0 +1,23 @@
1
+ import { cn } from "./lib/cn.js";
2
+ import { jsx } from "react/jsx-runtime";
3
+ import * as Nude from "@journ/nude/character-count-parts";
4
+ //#region src/character-count-parts.tsx
5
+ const useCharacterCount = Nude.useCharacterCount;
6
+ const Provider = Nude.Provider;
7
+ const Root = Nude.Root;
8
+ const Control = Nude.Control;
9
+ const readout = "font-mono text-[0.625rem]/[0.875rem] tracking-wider tabular-nums opacity-60";
10
+ const Frame = ({ className, ...props }) => /* @__PURE__ */ jsx(Nude.Frame, {
11
+ ...props,
12
+ className: cn("flex flex-col gap-2", className)
13
+ });
14
+ const Count = ({ className, ...props }) => /* @__PURE__ */ jsx(Nude.Count, {
15
+ ...props,
16
+ className: cn(readout, "data-over:text-bloom-coral data-over:opacity-100", className)
17
+ });
18
+ const Max = ({ className, ...props }) => /* @__PURE__ */ jsx(Nude.Max, {
19
+ ...props,
20
+ className: cn(readout, "before:mx-1 before:content-['/']", className)
21
+ });
22
+ //#endregion
23
+ export { Control, Count, Frame, Max, Provider, Root, useCharacterCount };
@@ -0,0 +1,12 @@
1
+ import { CharacterCountContextValue, Control, Count, Frame, Max, Provider, Root, RootProps, useCharacterCount } from "./character-count-parts.js";
2
+ //#region src/character-count.d.ts
3
+ declare const CharacterCount: {
4
+ Provider: typeof Provider;
5
+ Root: typeof Root;
6
+ Frame: typeof Frame;
7
+ Control: typeof Control;
8
+ Count: typeof Count;
9
+ Max: typeof Max;
10
+ };
11
+ //#endregion
12
+ export { CharacterCount, type CharacterCountContextValue, type RootProps as CharacterCountProps, useCharacterCount };
@@ -0,0 +1,12 @@
1
+ import { Control, Count, Frame, Max, Provider, Root, useCharacterCount } from "./character-count-parts.js";
2
+ //#region src/character-count.tsx
3
+ const CharacterCount = {
4
+ Provider,
5
+ Root,
6
+ Frame,
7
+ Control,
8
+ Count,
9
+ Max
10
+ };
11
+ //#endregion
12
+ export { CharacterCount, useCharacterCount };