@vokality/design-system 2.0.0 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -0
- package/README.md +49 -3
- package/dist/browser.d.ts +13 -0
- package/dist/browser.js +7 -0
- package/dist/charts/chart.d.ts +6 -5
- package/dist/charts/chart.js +44 -25
- package/dist/chat.d.ts +54 -0
- package/dist/chat.js +1 -0
- package/dist/components/Accordion/Accordion.js +1 -1
- package/dist/components/Alert/Alert.js +5 -2
- package/dist/components/AppShell/AppShell.js +10 -14
- package/dist/components/Avatar/Avatar.js +2 -2
- package/dist/components/AvatarGroup/AvatarGroup.js +2 -2
- package/dist/components/BarChart/BarChart.js +17 -15
- package/dist/components/Breadcrumbs/Breadcrumbs.js +6 -3
- package/dist/components/Calendar/Calendar.js +6 -5
- package/dist/components/Card/Card.js +2 -3
- package/dist/components/ChatInbox/ChatInbox.d.ts +11 -0
- package/dist/components/ChatInbox/ChatInbox.js +49 -0
- package/dist/components/ChatPanel/ChatPanel.d.ts +3 -0
- package/dist/components/ChatPanel/ChatPanel.js +13 -0
- package/dist/components/ChatPanel/composer.d.ts +5 -0
- package/dist/components/ChatPanel/composer.js +32 -0
- package/dist/components/ChatPanel/transcript.d.ts +13 -0
- package/dist/components/ChatPanel/transcript.js +39 -0
- package/dist/components/ChatWidget/ChatWidget.d.ts +12 -0
- package/dist/components/ChatWidget/ChatWidget.js +42 -0
- package/dist/components/Checkbox/Checkbox.d.ts +5 -10
- package/dist/components/Checkbox/Checkbox.js +5 -19
- package/dist/components/CodeBlock/CodeBlock.js +19 -5
- package/dist/components/Combobox/Combobox.js +22 -15
- package/dist/components/Combobox/ListPanel.js +20 -9
- package/dist/components/CommandPalette/CommandPalette.js +33 -14
- package/dist/components/ContextMenu/ContextMenu.d.ts +2 -2
- package/dist/components/ContextMenu/ContextMenu.js +5 -50
- package/dist/components/DatePicker/DatePicker.js +35 -29
- package/dist/components/DescriptionList/DescriptionList.js +1 -1
- package/dist/components/Dialog/Dialog.d.ts +24 -7
- package/dist/components/Dialog/Dialog.js +30 -41
- package/dist/components/Drawer/Drawer.d.ts +4 -2
- package/dist/components/EmptyState/EmptyState.js +2 -2
- package/dist/components/ErrorSummary/ErrorSummary.js +5 -3
- package/dist/components/FaqList/FaqList.js +1 -1
- package/dist/components/Field/Field.js +2 -2
- package/dist/components/FileUpload/FileUpload.js +17 -9
- package/dist/components/Grid/Grid.d.ts +5 -5
- package/dist/components/Grid/Grid.js +1 -1
- package/dist/components/Heading/Heading.js +2 -1
- package/dist/components/Icon/Icon.js +4 -2
- package/dist/components/Inline/Inline.d.ts +7 -7
- package/dist/components/LineChart/LineChart.js +17 -15
- package/dist/components/LinkProvider/LinkProvider.d.ts +1 -1
- package/dist/components/LinkProvider/LinkProvider.js +6 -2
- package/dist/components/List/List.js +1 -1
- package/dist/components/MediaCard/MediaCard.js +2 -2
- package/dist/components/Menu/Menu.js +6 -43
- package/dist/components/Menu/entries.d.ts +1 -30
- package/dist/components/Menu/entries.js +16 -100
- package/dist/components/MultiSelect/MultiSelect.js +43 -34
- package/dist/components/NumberInput/NumberInput.js +17 -18
- package/dist/components/OtpInput/OtpInput.d.ts +1 -1
- package/dist/components/OtpInput/OtpInput.js +10 -67
- package/dist/components/PageHeader/PageHeader.js +2 -2
- package/dist/components/Pagination/Pagination.js +3 -1
- package/dist/components/PasswordInput/PasswordInput.d.ts +1 -1
- package/dist/components/PasswordInput/PasswordInput.js +9 -4
- package/dist/components/Popover/Popover.d.ts +6 -7
- package/dist/components/Popover/Popover.js +2 -19
- package/dist/components/Progress/Progress.d.ts +1 -1
- package/dist/components/Progress/Progress.js +7 -11
- package/dist/components/Radio/Radio.d.ts +4 -2
- package/dist/components/RadioGroup/RadioGroup.d.ts +5 -12
- package/dist/components/RadioGroup/RadioGroup.js +6 -33
- package/dist/components/RichTextEditor/RichTextEditor.d.ts +63 -0
- package/dist/components/RichTextEditor/RichTextEditor.js +175 -0
- package/dist/components/RichTextEditor/toolbar.d.ts +15 -0
- package/dist/components/RichTextEditor/toolbar.js +142 -0
- package/dist/components/RichTextEditor/uploads.d.ts +41 -0
- package/dist/components/RichTextEditor/uploads.js +124 -0
- package/dist/components/SearchInput/SearchInput.js +4 -2
- package/dist/components/SectionHeader/SectionHeader.js +1 -3
- package/dist/components/SegmentedControl/SegmentedControl.js +2 -12
- package/dist/components/Select/Select.d.ts +15 -16
- package/dist/components/Select/Select.js +11 -252
- package/dist/components/Slider/Slider.js +11 -21
- package/dist/components/Sparkline/Sparkline.js +8 -3
- package/dist/components/Spinner/Spinner.js +5 -2
- package/dist/components/Stack/Stack.d.ts +5 -5
- package/dist/components/Stat/Stat.js +6 -3
- package/dist/components/Steps/Steps.js +6 -3
- package/dist/components/Switch/Switch.d.ts +7 -7
- package/dist/components/Switch/Switch.js +4 -10
- package/dist/components/Table/Table.js +38 -19
- package/dist/components/Tabs/Tabs.js +2 -22
- package/dist/components/Tag/Tag.js +3 -1
- package/dist/components/Text/Text.d.ts +1 -1
- package/dist/components/TileGrid/TileGrid.js +1 -1
- package/dist/components/TimePicker/TimePicker.js +35 -33
- package/dist/components/Timeline/Timeline.js +5 -4
- package/dist/components/Toaster/Toaster.js +21 -17
- package/dist/components/Tooltip/Tooltip.d.ts +6 -6
- package/dist/components/Tooltip/Tooltip.js +3 -17
- package/dist/components/TreeView/TreeView.js +15 -12
- package/dist/components.css +179 -8
- package/dist/hooks/useTheme.js +6 -6
- package/dist/icons/message-circle.svg +1 -0
- package/dist/internal/CharCount.js +3 -1
- package/dist/internal/choice.d.ts +10 -48
- package/dist/internal/choice.js +8 -96
- package/dist/internal/options.d.ts +10 -5
- package/dist/internal/options.js +25 -11
- package/dist/internal/status.d.ts +3 -2
- package/dist/internal/status.js +10 -2
- package/dist/internal/useScrollActive.js +2 -2
- package/dist/internal/useToday.d.ts +3 -0
- package/dist/internal/useToday.js +42 -0
- package/dist/lib/dates.js +25 -15
- package/dist/lib/format.js +11 -8
- package/dist/lib/icons.d.ts +5 -0
- package/dist/lib/icons.js +2 -0
- package/dist/lib/math.js +17 -5
- package/dist/lib/rich-text.d.ts +13 -0
- package/dist/lib/rich-text.js +62 -0
- package/dist/lib/space.d.ts +1 -2
- package/dist/lib/space.js +4 -1
- package/dist/lib/text.js +1 -1
- package/dist/lib/theme.js +1 -1
- package/dist/localization.d.ts +166 -0
- package/dist/localization.js +142 -0
- package/dist/vokality.css +179 -8
- package/dist/vokality.iife.js +35986 -9685
- package/docs/brand.md +6 -3
- package/docs/components/AppShell/README.md +1 -1
- package/docs/components/BarChart/README.md +1 -0
- package/docs/components/ChatInbox/README.md +41 -0
- package/docs/components/ChatWidget/README.md +47 -0
- package/docs/components/Checkbox/README.md +7 -3
- package/docs/components/ContextMenu/README.md +7 -3
- package/docs/components/Dialog/README.md +9 -4
- package/docs/components/Drawer/README.md +1 -1
- package/docs/components/Field/README.md +1 -1
- package/docs/components/Fieldset/README.md +2 -2
- package/docs/components/LineChart/README.md +1 -0
- package/docs/components/LocaleProvider/README.md +48 -0
- package/docs/components/Menu/README.md +13 -8
- package/docs/components/OtpInput/README.md +9 -5
- package/docs/components/PasswordInput/README.md +11 -2
- package/docs/components/Popover/README.md +6 -3
- package/docs/components/Progress/README.md +3 -1
- package/docs/components/RadioGroup/README.md +5 -2
- package/docs/components/RichTextEditor/README.md +84 -0
- package/docs/components/SegmentedControl/README.md +2 -0
- package/docs/components/Select/README.md +13 -17
- package/docs/components/Skeleton/README.md +1 -1
- package/docs/components/Slider/README.md +4 -2
- package/docs/components/Steps/README.md +1 -1
- package/docs/components/Switch/README.md +5 -2
- package/docs/components/Tabs/README.md +4 -2
- package/docs/components/Toaster/README.md +3 -1
- package/docs/components/Tooltip/README.md +5 -3
- package/package.json +49 -5
|
@@ -20,29 +20,25 @@ A custom drop-down for picking one option from a known list. Trigger and option
|
|
|
20
20
|
| Option | Selected | `primary-hover` text and check (4.7:1 on the active row) |
|
|
21
21
|
| Option | Disabled | `muted-subtle` text; skipped by arrow keys and type-to-jump |
|
|
22
22
|
|
|
23
|
-
##
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
| Enter, Space, ↓ | Opens on the selected option (the first enabled one if none) | Enter and Space choose the active option and close (Space typed within a second of a letter is part of the search) |
|
|
27
|
-
| ↑ | Opens on the selected option (the last one if none) | Moves up (Alt + ↑ chooses and closes) |
|
|
28
|
-
| ↓ | | Moves down |
|
|
29
|
-
| Home, End (PageUp, PageDown) | Opens at the first or last option | Jumps to the first or last option |
|
|
30
|
-
| Typing letters | Opens at the first match (without choosing it) | Jumps to the next match; letters typed within a second search together, a repeated letter cycles |
|
|
31
|
-
| Esc | | Closes without changing the value |
|
|
32
|
-
| Tab | Moves focus on | Chooses the active option, closes, moves focus on |
|
|
23
|
+
## Behavior
|
|
24
|
+
|
|
25
|
+
State, trigger gestures, focus, keyboard navigation, typeahead, dismissal and form participation come directly from [Radix Select](https://www.radix-ui.com/primitives/docs/components/select). This component adds tokens, layout, icons, descriptions and option-data mapping.
|
|
33
26
|
|
|
34
|
-
|
|
27
|
+
- Enter, Space and arrow keys open the list. Arrow keys and Home/End navigate open options; disabled options are skipped.
|
|
28
|
+
- Typing on a closed trigger changes the selected value using Radix typeahead. Typing in the open list moves focus to a matching option.
|
|
29
|
+
- Enter or Space selects. Escape dismisses and restores trigger focus. Radix prevents Tab while the list is open; dismiss before tabbing onward.
|
|
30
|
+
- Pointer opening, selection and outside dismissal use Radix's handlers. Clicking a native label activates its associated trigger.
|
|
35
31
|
|
|
36
32
|
## Accessibility
|
|
37
|
-
Implements the WAI-ARIA *select-only combobox* pattern with Radix Select: the trigger is a `<button>` with `role="combobox"`, `aria-expanded` and (while open) `aria-controls`, and the list has `role="listbox"` with `role="option"` items, each named by its label and described by its `description`. While the list is open, focus moves onto the active option (Radix's model, instead of `aria-activedescendant`) and the rest of the page is hidden from assistive technology; closing
|
|
33
|
+
Implements the WAI-ARIA *select-only combobox* pattern with Radix Select: the trigger is a `<button>` with `role="combobox"`, `aria-expanded` and (while open) `aria-controls`, and the list has `role="listbox"` with `role="option"` items, each named by its label and described by its `description`. While the list is open, focus moves onto the active option (Radix's model, instead of `aria-activedescendant`) and the rest of the page is hidden from assistive technology; closing restores trigger focus through Radix. Inside a `Field`, the label names the control and native label activation reaches the trigger.
|
|
38
34
|
|
|
39
35
|
## Props
|
|
40
36
|
- `options`: strings or `{ value, label, description, disabled }`.
|
|
41
|
-
- `placeholder`: shown until something is chosen
|
|
42
|
-
- `value` + `onChange(value, option)` to control it, or `defaultValue`. `value={null}` clears it to the placeholder.
|
|
43
|
-
- `name
|
|
44
|
-
- `
|
|
45
|
-
- `defaultOpen
|
|
37
|
+
- `placeholder`: shown until something is chosen; defaults to the localized select prompt. No value is selected unless supplied through `value` or `defaultValue`.
|
|
38
|
+
- `value` + `onChange(value, option)` to control it, or `defaultValue`. `value={null}` clears it to the placeholder. Option values must be non-empty strings, as required by Radix. `onChange` runs when the value changes (choosing the option that is already chosen doesn't call it); resetting the surrounding form puts an uncontrolled select back to its first value.
|
|
39
|
+
- `name`, `form`, `required` and `disabled` pass to Radix Root. Its native form select posts the value, participates in validation and handles reset; disabled controls are excluded.
|
|
40
|
+
- `aria-label` when there is no `Field`; `aria-labelledby`, `aria-describedby` and `aria-invalid` wire accessible presentation.
|
|
41
|
+
- `open`, `defaultOpen` and `onOpenChange` pass directly to Radix; `dir` and `autoComplete` are supported through its Root contract.
|
|
46
42
|
- The ref is the trigger `<button>`, so a `Select` can be a `Tooltip` trigger.
|
|
47
43
|
|
|
48
44
|
## Rules
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Placeholder blocks shown where content is loading, in its final shape, so the layout doesn't jump.
|
|
4
4
|
|
|
5
5
|
## Anatomy
|
|
6
|
-
`
|
|
6
|
+
`border-subtle` fill keeps placeholder shapes visible in every theme, with a faint `foreground` 5% shimmer moving left every 1.4s (still under reduced motion).
|
|
7
7
|
|
|
8
8
|
## Props
|
|
9
9
|
- `width`, `height` for a single block, or `lines` for a paragraph (the last line is shorter).
|
|
@@ -10,13 +10,15 @@ Picks a value from a continuous range by dragging or with the keyboard, for sett
|
|
|
10
10
|
5. **Limits** (optional, `showLimits`): minimum and maximum below the track.
|
|
11
11
|
|
|
12
12
|
## Keyboard
|
|
13
|
-
← → (or ↓ ↑) step by `step`, ten steps with Shift; PageUp / PageDown move
|
|
13
|
+
← → (or ↓ ↑) step by `step`, ten steps with Shift; PageUp / PageDown move ten steps; Home / End jump to the ends. Clicking the track jumps there; dragging follows the pointer.
|
|
14
14
|
|
|
15
15
|
## Accessibility
|
|
16
|
-
`role="slider"` with `aria-valuenow`, min and max, and `aria-valuetext` from `valueText` or `format` ("$1,200 per month").
|
|
16
|
+
`role="slider"` with Radix-managed `aria-valuenow`, min and max, and `aria-valuetext` from `valueText` or `format` ("$1,200 per month").
|
|
17
17
|
|
|
18
18
|
## Props
|
|
19
19
|
- `value` + `onChange`, or `defaultValue`. `min` (0), `max` (100), `step` (1), `format(v)`, `valueText(v)`, `showValue`, `showLimits`, `name` (submitted through a hidden input inside a `form`), `disabled`, `aria-label` or the `Field` label.
|
|
20
20
|
|
|
21
21
|
## Rules
|
|
22
22
|
- If people need an exact number, add a `NumberInput` beside it or use one instead.
|
|
23
|
+
|
|
24
|
+
The scalar value callback adapts Radix's one-thumb number array; Radix owns stepping, pointer handling, keyboard behavior, bounds and uncontrolled form reset. [Radix Slider documentation](https://www.radix-ui.com/primitives/docs/components/slider).
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Shows where someone is in a fixed sequence: onboarding, a checkout, a multi-page form.
|
|
4
4
|
|
|
5
5
|
## Anatomy
|
|
6
|
-
Each step has a 28px square marker with the number zero-padded in Space Grotesk, a label, and an optional description in `muted-subtle`. A 1px rule connects the markers. It runs horizontally by default
|
|
6
|
+
Each step has a 28px square marker with the number zero-padded in Space Grotesk, a label, and an optional description in `muted-subtle`. A 1px rule connects the markers. It runs horizontally by default and stacks vertically at viewport widths of 28rem or less so labels remain distinct. Use `orientation="vertical"` for a vertical sequence at every width.
|
|
7
7
|
|
|
8
8
|
## Step states
|
|
9
9
|
| State | Marker | Label | Rule after it |
|
|
@@ -18,9 +18,12 @@ A square on/off toggle for settings that take effect immediately.
|
|
|
18
18
|
| Disabled, on | `muted-subtle` fill and border | `background`, right |
|
|
19
19
|
|
|
20
20
|
## Props
|
|
21
|
-
- `label`, `description`, `checked` or `defaultChecked`, `
|
|
21
|
+
- `label`, `description`, `checked` or `defaultChecked`, `onCheckedChange`, `disabled`, `name`, `value`, `hideLabel`.
|
|
22
22
|
- Built on Radix Switch: the track is a `button` with `role="switch"` and `aria-checked`; Space or Enter toggles it. Inside a `form` a hidden checkbox carries `name` and `value`.
|
|
23
|
-
- `
|
|
23
|
+
- `onCheckedChange(checked)` receives a boolean directly. The ref and DOM callbacks refer to the actual `HTMLButtonElement`; no input event is synthesized.
|
|
24
|
+
- Migration: replace `onChange={event => setChecked(event.target.checked)}` with `onCheckedChange={setChecked}`. Radix owns uncontrolled state and form reset.
|
|
25
|
+
|
|
26
|
+
See [Radix Switch](https://www.radix-ui.com/primitives/docs/components/switch) for the public behavior and props.
|
|
24
27
|
|
|
25
28
|
## Rules
|
|
26
29
|
- Use a switch only when the change applies without a Save button. Inside a form that is submitted, use `Checkbox`.
|
|
@@ -16,11 +16,13 @@ Style state with Radix's attributes on `.vk-tab`: `[data-state=active|inactive]`
|
|
|
16
16
|
Tab lands on the selected tab. ← → move between tabs and select them (wrapping); Home and End (or Page Up and Page Down) jump to the first or last. Tab again moves into the panel.
|
|
17
17
|
|
|
18
18
|
## Accessibility
|
|
19
|
-
WAI-ARIA tabs with automatic activation: `tablist`, `tab` (`aria-selected`, `aria-controls`, roving `tabIndex`) and `tabpanel` (`aria-labelledby`).
|
|
19
|
+
WAI-ARIA tabs with automatic activation: `tablist`, `tab` (`aria-selected`, `aria-controls`, roving `tabIndex`) and `tabpanel` (`aria-labelledby`). Radix manages panel presence and selection. `keepMounted` maps to Radix `forceMount`; inactive panels remain hidden through their `data-state` styling.
|
|
20
20
|
|
|
21
21
|
## Props
|
|
22
|
-
- `tabs`: `{ id, label, content, count, disabled }`. `value` + `onChange`, or `defaultValue` (
|
|
22
|
+
- `tabs`: `{ id, label, content, count, disabled }`. `value` + `onChange`, or `defaultValue` (no selected tab unless supplied). `onChange(id)` maps directly to Radix `onValueChange` without filtering callbacks. `label` (the list's accessible name). `keepMounted` keeps hidden panels rendered.
|
|
23
23
|
|
|
24
24
|
## Rules
|
|
25
25
|
- Two to six tabs with short labels. Tabs never change the URL's page; use links for that.
|
|
26
26
|
- For switching how one thing is displayed (chart or table), use `SegmentedControl`.
|
|
27
|
+
|
|
28
|
+
[Radix Tabs documentation](https://www.radix-ui.com/primitives/docs/components/tabs) defines automatic activation and controlled/uncontrolled behavior.
|
|
@@ -9,7 +9,7 @@ Short, temporary notifications about an action someone just took ("Changes saved
|
|
|
9
9
|
|
|
10
10
|
## Timing
|
|
11
11
|
- Info, success and warning toasts dismiss after 5 seconds. Danger toasts stay until dismissed.
|
|
12
|
-
-
|
|
12
|
+
- Radix owns the timer and pauses it while the pointer is over the stack, focus is inside it, or the window is in the background. The `toast()` store only maps notification data to Radix instances; it has no timer or keyboard engine.
|
|
13
13
|
- Toasts slide up 0.5rem on entry; that motion stops under reduced motion.
|
|
14
14
|
|
|
15
15
|
## API
|
|
@@ -32,3 +32,5 @@ Each new toast is announced once through Radix's live region ("Notification", th
|
|
|
32
32
|
- One short sentence for the title, in the past tense for completed actions ("Invoice sent").
|
|
33
33
|
- Never put the only path to something important in a toast; it disappears. Use an `Alert` or `Dialog` for that.
|
|
34
34
|
- An action in a toast must also be available elsewhere (Undo is the classic case).
|
|
35
|
+
|
|
36
|
+
[Radix Toast documentation](https://www.radix-ui.com/primitives/docs/components/toast) defines timing, focus, hotkeys and swipe behavior.
|
|
@@ -6,14 +6,14 @@ A short text label that appears on hover or keyboard focus, for an icon-only con
|
|
|
6
6
|
Inverted for contrast: `foreground` fill with `background` text (14.6:1), 12px IBM Plex Sans 500, 0.35rem 0.55rem padding, square, at most 16rem wide. It sits 6px above the trigger (or below with `placement="bottom"`), flips when there's no room, and is centered (or start-aligned with `align="start"`).
|
|
7
7
|
|
|
8
8
|
## Behaviour
|
|
9
|
-
- Appears 400ms after the pointer enters (`delay`), immediately on keyboard focus.
|
|
9
|
+
- Appears 400ms after the pointer enters (`delay`), immediately on keyboard focus.
|
|
10
10
|
- Disappears when the pointer leaves, focus moves, or Esc is pressed.
|
|
11
11
|
|
|
12
12
|
## Props
|
|
13
|
-
- `content`, `children` (exactly one focusable element; a custom component must forward its ref, as every component in the system does), `placement` (`top` or `bottom`), `align`, `delay`.
|
|
13
|
+
- `content`, `children` (exactly one focusable element; a custom component must forward its ref, as every component in the system does), `placement` (`top` or `bottom`), `align`, `delay`, and native Radix `open`, `defaultOpen`, `onOpenChange`.
|
|
14
14
|
|
|
15
15
|
## Touch
|
|
16
|
-
|
|
16
|
+
Touch taps keep Radix Tooltip’s native behavior: they run the trigger action without opening a timed tooltip. `touchDuration` is removed. Nothing essential may live only in a tooltip.
|
|
17
17
|
|
|
18
18
|
## Accessibility
|
|
19
19
|
`role="tooltip"`, linked to the trigger with `aria-describedby` while visible. It describes; it doesn't name. An `IconButton` still needs its own `label`.
|
|
@@ -21,3 +21,5 @@ On touch screens a tap on the trigger runs its action and shows the tooltip for
|
|
|
21
21
|
## Rules
|
|
22
22
|
- Plain text only: no links, buttons or anything interactive. Use `Popover` for that.
|
|
23
23
|
- Never hide information someone needs to finish a task in a tooltip; touch screens can't hover.
|
|
24
|
+
|
|
25
|
+
[Radix Tooltip documentation](https://www.radix-ui.com/primitives/docs/components/tooltip) defines its hover, focus and dismissal contract.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vokality/design-system",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"description": "Vokality's design system: tokens, themes and React components for every Vokality project.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"private": false,
|
|
@@ -13,6 +13,14 @@
|
|
|
13
13
|
"types": "./dist/index.d.ts",
|
|
14
14
|
"import": "./dist/index.js"
|
|
15
15
|
},
|
|
16
|
+
"./localization": {
|
|
17
|
+
"types": "./dist/localization.d.ts",
|
|
18
|
+
"import": "./dist/localization.js"
|
|
19
|
+
},
|
|
20
|
+
"./rich-text": {
|
|
21
|
+
"types": "./dist/components/RichTextEditor/RichTextEditor.d.ts",
|
|
22
|
+
"import": "./dist/components/RichTextEditor/RichTextEditor.js"
|
|
23
|
+
},
|
|
16
24
|
"./vokality.css": "./dist/vokality.css",
|
|
17
25
|
"./tokens.css": "./dist/tokens.css",
|
|
18
26
|
"./components.css": "./dist/components.css",
|
|
@@ -22,7 +30,19 @@
|
|
|
22
30
|
"./tokens.dtcg.json": "./dist/tokens.dtcg.json",
|
|
23
31
|
"./icons/*": "./dist/icons/*",
|
|
24
32
|
"./fonts/*": "./dist/fonts/*",
|
|
25
|
-
"./iife": "./dist/vokality.iife.js"
|
|
33
|
+
"./iife": "./dist/vokality.iife.js",
|
|
34
|
+
"./chat-widget": {
|
|
35
|
+
"types": "./dist/components/ChatWidget/ChatWidget.d.ts",
|
|
36
|
+
"import": "./dist/components/ChatWidget/ChatWidget.js"
|
|
37
|
+
},
|
|
38
|
+
"./chat-inbox": {
|
|
39
|
+
"types": "./dist/components/ChatInbox/ChatInbox.d.ts",
|
|
40
|
+
"import": "./dist/components/ChatInbox/ChatInbox.js"
|
|
41
|
+
},
|
|
42
|
+
"./chat-models": {
|
|
43
|
+
"types": "./dist/chat.d.ts",
|
|
44
|
+
"import": "./dist/chat.js"
|
|
45
|
+
}
|
|
26
46
|
},
|
|
27
47
|
"files": [
|
|
28
48
|
"dist",
|
|
@@ -38,23 +58,38 @@
|
|
|
38
58
|
"build": "bun scripts/build.mjs",
|
|
39
59
|
"test": "bun run build && bun test test/",
|
|
40
60
|
"test:browser": "bun run build && bun test --timeout 30000 e2e/",
|
|
61
|
+
"test:visual": "bun run build && bunx playwright test -c validation/playwright.config.mjs",
|
|
62
|
+
"test:visual:update": "bun run build && bunx playwright test -c validation/playwright.config.mjs --update-snapshots",
|
|
63
|
+
"test:next": "bun run build && bun scripts/test-next.mjs build && VK_NEXT=1 bunx playwright test -c validation/playwright.config.mjs",
|
|
41
64
|
"typecheck": "tsc -p tsconfig.json",
|
|
65
|
+
"lint": "eslint src --max-warnings 0",
|
|
66
|
+
"doctor": "react-doctor --yes --scope full --blocking warning --no-supply-chain --no-score",
|
|
42
67
|
"preview": "bun run build && bun scripts/preview.mjs",
|
|
43
68
|
"artifact": "bun run build && bun scripts/build-artifact.mjs",
|
|
44
69
|
"prepack": "bun run build",
|
|
45
70
|
"verify:docs": "bun scripts/verify-docs-page.mjs"
|
|
46
71
|
},
|
|
47
72
|
"peerDependencies": {
|
|
48
|
-
"react": ">=18",
|
|
49
|
-
"react-dom": ">=18"
|
|
73
|
+
"react": ">=18.2",
|
|
74
|
+
"react-dom": ">=18.2"
|
|
50
75
|
},
|
|
51
76
|
"devDependencies": {
|
|
77
|
+
"@axe-core/playwright": "4.14.0",
|
|
78
|
+
"@eslint/js": "9.39.5",
|
|
79
|
+
"@playwright/test": "1.56.1",
|
|
80
|
+
"@types/node": "26.6.5",
|
|
52
81
|
"@types/react": "^18",
|
|
53
82
|
"@types/react-dom": "^18",
|
|
83
|
+
"eslint": "9.39.5",
|
|
84
|
+
"eslint-plugin-react": "7.37.5",
|
|
85
|
+
"eslint-plugin-react-hooks": "7.1.1",
|
|
86
|
+
"next": "16.4.2",
|
|
54
87
|
"playwright": "1.56.1",
|
|
55
88
|
"react": "18.3.1",
|
|
89
|
+
"react-doctor": "0.9.18",
|
|
56
90
|
"react-dom": "18.3.1",
|
|
57
|
-
"typescript": "
|
|
91
|
+
"typescript": "6.0.3",
|
|
92
|
+
"typescript-eslint": "8.71.2"
|
|
58
93
|
},
|
|
59
94
|
"publishConfig": {
|
|
60
95
|
"registry": "https://registry.npmjs.org",
|
|
@@ -73,6 +108,15 @@
|
|
|
73
108
|
"bun": ">=1.4.3"
|
|
74
109
|
},
|
|
75
110
|
"dependencies": {
|
|
111
|
+
"motion": "14.3.0",
|
|
112
|
+
"prosemirror-commands": "1.7.2",
|
|
113
|
+
"prosemirror-history": "1.5.1",
|
|
114
|
+
"prosemirror-keymap": "1.2.3",
|
|
115
|
+
"prosemirror-markdown": "1.13.8",
|
|
116
|
+
"prosemirror-model": "1.25.12",
|
|
117
|
+
"prosemirror-schema-list": "1.5.1",
|
|
118
|
+
"prosemirror-state": "1.4.4",
|
|
119
|
+
"prosemirror-view": "1.42.6",
|
|
76
120
|
"radix-ui": "1.8.0"
|
|
77
121
|
}
|
|
78
122
|
}
|