@exsto/ds 0.0.0-stage → 0.0.1-rc.10
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/LICENSE +202 -0
- package/README.md +165 -2
- package/dist/chunks/date-range-picker-CWVcHgy2.js +204 -0
- package/dist/chunks/date-range-picker-CWVcHgy2.js.map +1 -0
- package/dist/chunks/input-syWxjY2U.js +172 -0
- package/dist/chunks/input-syWxjY2U.js.map +1 -0
- package/dist/chunks/toggle-CVnIkJVC.js +484 -0
- package/dist/chunks/toggle-CVnIkJVC.js.map +1 -0
- package/dist/date-picker.js +345 -0
- package/dist/date-picker.js.map +1 -0
- package/dist/ds/src/date-picker.d.ts +9 -0
- package/dist/ds/src/index.d.ts +7 -0
- package/dist/ds/src/rich-text-editor.d.ts +8 -0
- package/dist/index.js +4512 -0
- package/dist/index.js.map +1 -0
- package/dist/rich-text-editor.js +905 -0
- package/dist/rich-text-editor.js.map +1 -0
- package/dist/styles.css +8167 -0
- package/dist/styles.css.d.ts +2 -0
- package/dist/theme/src/index.d.ts +4 -0
- package/dist/theme.css +308 -0
- package/dist/theme.css.d.ts +2 -0
- package/dist/ui/src/components/edyn/animated-number/animated-number.d.ts +30 -0
- package/dist/ui/src/components/edyn/animated-number/animated-number.test.d.ts +9 -0
- package/dist/ui/src/components/edyn/animated-number/index.d.ts +1 -0
- package/dist/ui/src/components/edyn/audio-player/audio-player.d.ts +30 -0
- package/dist/ui/src/components/edyn/audio-player/index.d.ts +1 -0
- package/dist/ui/src/components/edyn/date-picker/date-picker.d.ts +76 -0
- package/dist/ui/src/components/edyn/date-picker/date-picker.state.test.d.ts +9 -0
- package/dist/ui/src/components/edyn/date-picker/date-text.d.ts +40 -0
- package/dist/ui/src/components/edyn/date-picker/date-text.test.d.ts +1 -0
- package/dist/ui/src/components/edyn/date-picker/index.d.ts +2 -0
- package/dist/ui/src/components/edyn/date-range-picker/date-range-picker.d.ts +28 -0
- package/dist/ui/src/components/edyn/date-range-picker/date-range-picker.test.d.ts +9 -0
- package/dist/ui/src/components/edyn/date-range-picker/index.d.ts +1 -0
- package/dist/ui/src/components/edyn/initials-avatar/index.d.ts +1 -0
- package/dist/ui/src/components/edyn/initials-avatar/initials-avatar.d.ts +54 -0
- package/dist/ui/src/components/edyn/initials-avatar/initials-avatar.test.d.ts +10 -0
- package/dist/ui/src/components/edyn/multi-select/index.d.ts +1 -0
- package/dist/ui/src/components/edyn/multi-select/multi-select.d.ts +106 -0
- package/dist/ui/src/components/edyn/multi-select/multi-select.test.d.ts +9 -0
- package/dist/ui/src/components/edyn/progress-line/index.d.ts +1 -0
- package/dist/ui/src/components/edyn/progress-line/progress-line.d.ts +23 -0
- package/dist/ui/src/components/edyn/progress-line/progress-line.test.d.ts +9 -0
- package/dist/ui/src/components/edyn/rich-text-content/allow-list.d.ts +11 -0
- package/dist/ui/src/components/edyn/rich-text-content/index.d.ts +2 -0
- package/dist/ui/src/components/edyn/rich-text-content/rich-text-content.d.ts +22 -0
- package/dist/ui/src/components/edyn/rich-text-content/rich-text-content.test.d.ts +8 -0
- package/dist/ui/src/components/edyn/rich-text-editor/extensions.d.ts +18 -0
- package/dist/ui/src/components/edyn/rich-text-editor/index.d.ts +3 -0
- package/dist/ui/src/components/edyn/rich-text-editor/mention-list.d.ts +17 -0
- package/dist/ui/src/components/edyn/rich-text-editor/rich-text-editor.d.ts +53 -0
- package/dist/ui/src/components/edyn/rich-text-editor/rich-text-editor.test.d.ts +6 -0
- package/dist/ui/src/components/edyn/rich-text-editor/serialize.d.ts +13 -0
- package/dist/ui/src/components/edyn/rich-text-editor/sync.d.ts +19 -0
- package/dist/ui/src/components/edyn/rich-text-editor/sync.test.d.ts +11 -0
- package/dist/ui/src/components/edyn/rich-text-editor/toolbar.d.ts +20 -0
- package/dist/ui/src/components/edyn/rich-text-editor/types.d.ts +68 -0
- package/dist/ui/src/components/edyn/video-player/index.d.ts +1 -0
- package/dist/ui/src/components/edyn/video-player/video-player.d.ts +55 -0
- package/dist/ui/src/components/forwarded-props.test.d.ts +8 -0
- package/dist/ui/src/components/ui/accordion/accordion.behavior.test.d.ts +13 -0
- package/dist/ui/src/components/ui/accordion/accordion.d.ts +28 -0
- package/dist/ui/src/components/ui/accordion/index.d.ts +1 -0
- package/dist/ui/src/components/ui/alert/alert.d.ts +10 -0
- package/dist/ui/src/components/ui/alert/index.d.ts +1 -0
- package/dist/ui/src/components/ui/alert-dialog/alert-dialog.d.ts +17 -0
- package/dist/ui/src/components/ui/alert-dialog/index.d.ts +1 -0
- package/dist/ui/src/components/ui/aspect-ratio/aspect-ratio.d.ts +3 -0
- package/dist/ui/src/components/ui/aspect-ratio/index.d.ts +1 -0
- package/dist/ui/src/components/ui/attachment/attachment.d.ts +23 -0
- package/dist/ui/src/components/ui/attachment/index.d.ts +1 -0
- package/dist/ui/src/components/ui/avatar/avatar.d.ts +10 -0
- package/dist/ui/src/components/ui/avatar/index.d.ts +1 -0
- package/dist/ui/src/components/ui/badge/badge.d.ts +7 -0
- package/dist/ui/src/components/ui/badge/index.d.ts +1 -0
- package/dist/ui/src/components/ui/breadcrumb/breadcrumb.d.ts +9 -0
- package/dist/ui/src/components/ui/breadcrumb/index.d.ts +1 -0
- package/dist/ui/src/components/ui/bubble/bubble.d.ts +16 -0
- package/dist/ui/src/components/ui/bubble/index.d.ts +1 -0
- package/dist/ui/src/components/ui/button/button.behavior.test.d.ts +8 -0
- package/dist/ui/src/components/ui/button/button.d.ts +7 -0
- package/dist/ui/src/components/ui/button/index.d.ts +1 -0
- package/dist/ui/src/components/ui/button-group/button-group.d.ts +12 -0
- package/dist/ui/src/components/ui/button-group/index.d.ts +1 -0
- package/dist/ui/src/components/ui/calendar/calendar.d.ts +9 -0
- package/dist/ui/src/components/ui/calendar/index.d.ts +1 -0
- package/dist/ui/src/components/ui/card/card.d.ts +10 -0
- package/dist/ui/src/components/ui/card/index.d.ts +1 -0
- package/dist/ui/src/components/ui/carousel/carousel.d.ts +28 -0
- package/dist/ui/src/components/ui/carousel/index.d.ts +3 -0
- package/dist/ui/src/components/ui/chart/chart.d.ts +44 -0
- package/dist/ui/src/components/ui/chart/index.d.ts +3 -0
- package/dist/ui/src/components/ui/checkbox/checkbox.d.ts +2 -0
- package/dist/ui/src/components/ui/checkbox/index.d.ts +1 -0
- package/dist/ui/src/components/ui/collapsible/collapsible.d.ts +4 -0
- package/dist/ui/src/components/ui/collapsible/index.d.ts +1 -0
- package/dist/ui/src/components/ui/combobox/combobox.d.ts +15 -0
- package/dist/ui/src/components/ui/combobox/index.d.ts +1 -0
- package/dist/ui/src/components/ui/command/command.d.ts +34 -0
- package/dist/ui/src/components/ui/command/index.d.ts +1 -0
- package/dist/ui/src/components/ui/context-menu/context-menu.d.ts +28 -0
- package/dist/ui/src/components/ui/context-menu/index.d.ts +1 -0
- package/dist/ui/src/components/ui/dialog/dialog.d.ts +16 -0
- package/dist/ui/src/components/ui/dialog/index.d.ts +1 -0
- package/dist/ui/src/components/ui/direction/direction.d.ts +1 -0
- package/dist/ui/src/components/ui/direction/index.d.ts +1 -0
- package/dist/ui/src/components/ui/drawer/drawer.d.ts +15 -0
- package/dist/ui/src/components/ui/drawer/index.d.ts +1 -0
- package/dist/ui/src/components/ui/dropdown-menu/dropdown-menu.d.ts +39 -0
- package/dist/ui/src/components/ui/dropdown-menu/index.d.ts +1 -0
- package/dist/ui/src/components/ui/empty/empty.d.ts +11 -0
- package/dist/ui/src/components/ui/empty/index.d.ts +1 -0
- package/dist/ui/src/components/ui/field/field.d.ts +5 -0
- package/dist/ui/src/components/ui/field/index.d.ts +1 -0
- package/dist/ui/src/components/ui/hover-card/hover-card.d.ts +4 -0
- package/dist/ui/src/components/ui/hover-card/index.d.ts +1 -0
- package/dist/ui/src/components/ui/indicator/index.d.ts +1 -0
- package/dist/ui/src/components/ui/indicator/indicator.d.ts +10 -0
- package/dist/ui/src/components/ui/input/index.d.ts +1 -0
- package/dist/ui/src/components/ui/input/input.d.ts +2 -0
- package/dist/ui/src/components/ui/input-group/index.d.ts +1 -0
- package/dist/ui/src/components/ui/input-group/input-group.d.ts +26 -0
- package/dist/ui/src/components/ui/input-otp/index.d.ts +1 -0
- package/dist/ui/src/components/ui/input-otp/input-otp.d.ts +10 -0
- package/dist/ui/src/components/ui/item/index.d.ts +1 -0
- package/dist/ui/src/components/ui/item/item.d.ts +22 -0
- package/dist/ui/src/components/ui/kbd/index.d.ts +1 -0
- package/dist/ui/src/components/ui/kbd/kbd.d.ts +2 -0
- package/dist/ui/src/components/ui/label/index.d.ts +1 -0
- package/dist/ui/src/components/ui/label/label.d.ts +2 -0
- package/dist/ui/src/components/ui/marker/index.d.ts +1 -0
- package/dist/ui/src/components/ui/marker/marker.d.ts +9 -0
- package/dist/ui/src/components/ui/menubar/index.d.ts +1 -0
- package/dist/ui/src/components/ui/menubar/menubar.d.ts +28 -0
- package/dist/ui/src/components/ui/message/index.d.ts +1 -0
- package/dist/ui/src/components/ui/message/message.d.ts +9 -0
- package/dist/ui/src/components/ui/message-scroller/index.d.ts +1 -0
- package/dist/ui/src/components/ui/message-scroller/message-scroller.d.ts +10 -0
- package/dist/ui/src/components/ui/native-select/index.d.ts +1 -0
- package/dist/ui/src/components/ui/native-select/native-select.d.ts +8 -0
- package/dist/ui/src/components/ui/navigation-menu/index.d.ts +1 -0
- package/dist/ui/src/components/ui/navigation-menu/navigation-menu.d.ts +10 -0
- package/dist/ui/src/components/ui/pagination/index.d.ts +1 -0
- package/dist/ui/src/components/ui/pagination/pagination.behavior.test.d.ts +1 -0
- package/dist/ui/src/components/ui/pagination/pagination.d.ts +18 -0
- package/dist/ui/src/components/ui/pagination/pagination.test.d.ts +1 -0
- package/dist/ui/src/components/ui/popover/index.d.ts +1 -0
- package/dist/ui/src/components/ui/popover/popover.d.ts +8 -0
- package/dist/ui/src/components/ui/progress/index.d.ts +1 -0
- package/dist/ui/src/components/ui/progress/progress.behavior.test.d.ts +8 -0
- package/dist/ui/src/components/ui/progress/progress.d.ts +47 -0
- package/dist/ui/src/components/ui/questionnaire/index.d.ts +1 -0
- package/dist/ui/src/components/ui/questionnaire/questionnaire.d.ts +18 -0
- package/dist/ui/src/components/ui/radio-group/index.d.ts +1 -0
- package/dist/ui/src/components/ui/radio-group/radio-group.d.ts +10 -0
- package/dist/ui/src/components/ui/resizable/index.d.ts +1 -0
- package/dist/ui/src/components/ui/resizable/resizable.d.ts +6 -0
- package/dist/ui/src/components/ui/scroll-area/index.d.ts +1 -0
- package/dist/ui/src/components/ui/scroll-area/scroll-area.behavior.test.d.ts +12 -0
- package/dist/ui/src/components/ui/scroll-area/scroll-area.d.ts +85 -0
- package/dist/ui/src/components/ui/select/index.d.ts +1 -0
- package/dist/ui/src/components/ui/select/select.d.ts +17 -0
- package/dist/ui/src/components/ui/separator/index.d.ts +1 -0
- package/dist/ui/src/components/ui/separator/separator.behavior.test.d.ts +14 -0
- package/dist/ui/src/components/ui/separator/separator.d.ts +16 -0
- package/dist/ui/src/components/ui/sheet/index.d.ts +1 -0
- package/dist/ui/src/components/ui/sheet/sheet.d.ts +13 -0
- package/dist/ui/src/components/ui/sidebar/index.d.ts +1 -0
- package/dist/ui/src/components/ui/sidebar/sidebar.d.ts +63 -0
- package/dist/ui/src/components/ui/skeleton/index.d.ts +1 -0
- package/dist/ui/src/components/ui/skeleton/skeleton.d.ts +1 -0
- package/dist/ui/src/components/ui/slider/index.d.ts +1 -0
- package/dist/ui/src/components/ui/slider/slider.d.ts +17 -0
- package/dist/ui/src/components/ui/spinner/index.d.ts +1 -0
- package/dist/ui/src/components/ui/spinner/spinner.d.ts +5 -0
- package/dist/ui/src/components/ui/switch/index.d.ts +1 -0
- package/dist/ui/src/components/ui/switch/switch.d.ts +4 -0
- package/dist/ui/src/components/ui/table/index.d.ts +1 -0
- package/dist/ui/src/components/ui/table/table.behavior.test.d.ts +9 -0
- package/dist/ui/src/components/ui/table/table.d.ts +9 -0
- package/dist/ui/src/components/ui/tabs/index.d.ts +1 -0
- package/dist/ui/src/components/ui/tabs/tabs.behavior.test.d.ts +21 -0
- package/dist/ui/src/components/ui/tabs/tabs.d.ts +36 -0
- package/dist/ui/src/components/ui/textarea/index.d.ts +1 -0
- package/dist/ui/src/components/ui/textarea/textarea.d.ts +2 -0
- package/dist/ui/src/components/ui/toast/index.d.ts +1 -0
- package/dist/ui/src/components/ui/toast/toast.d.ts +15 -0
- package/dist/ui/src/components/ui/toggle/index.d.ts +1 -0
- package/dist/ui/src/components/ui/toggle/toggle.d.ts +8 -0
- package/dist/ui/src/components/ui/toggle-group/index.d.ts +1 -0
- package/dist/ui/src/components/ui/toggle-group/toggle-group.d.ts +7 -0
- package/dist/ui/src/components/ui/tooltip/index.d.ts +1 -0
- package/dist/ui/src/components/ui/tooltip/tooltip.d.ts +5 -0
- package/dist/ui/src/hooks/use-media-player.d.ts +29 -0
- package/dist/ui/src/hooks/use-merged-refs.d.ts +4 -0
- package/dist/ui/src/hooks/use-mobile.d.ts +1 -0
- package/dist/ui/src/index.d.ts +74 -0
- package/dist/ui/src/lib/first-weekday.d.ts +6 -0
- package/dist/ui/src/lib/first-weekday.test.d.ts +1 -0
- package/dist/ui/src/lib/focus-ring.test.d.ts +8 -0
- package/dist/ui/src/lib/popup-list.d.ts +47 -0
- package/dist/ui/src/lib/popup-list.test.d.ts +10 -0
- package/dist/ui/src/lib/utils.d.ts +13 -0
- package/package.json +95 -4
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A11y + keyboard-nav test for Tabs.
|
|
3
|
+
*
|
|
4
|
+
* PATH TAKEN: happy-dom unit test for roles/aria + onValueChange callback.
|
|
5
|
+
* Arrow-key navigation moves focus but does NOT auto-select in Base UI's default
|
|
6
|
+
* (activateOnFocus=false) mode; the user presses Enter/Space (or clicks) to
|
|
7
|
+
* activate. In happy-dom, native button click-from-keyboard is not fully
|
|
8
|
+
* emulated, so we:
|
|
9
|
+
* 1. Assert roles and aria attributes (role=tablist, role=tab, aria-selected,
|
|
10
|
+
* role=tabpanel) to confirm a11y-by-construction.
|
|
11
|
+
* 2. Assert that clicking a tab calls onValueChange with the correct value.
|
|
12
|
+
* 3. Assert that ArrowRight on the tablist fires a keydown and moves the
|
|
13
|
+
* composite highlight (the CompositeRoot processes the event). We verify
|
|
14
|
+
* this by confirming the tablist receives keydown and the handler runs
|
|
15
|
+
* without error.
|
|
16
|
+
* 4. For full browser-level arrow-key navigation proof, see the Playwright
|
|
17
|
+
* e2e suite (e2e/open-popups.spec.ts pattern); a dedicated tabs e2e test
|
|
18
|
+
* should be added there to verify roving tabindex focus movement in a real
|
|
19
|
+
* browser.
|
|
20
|
+
*/
|
|
21
|
+
export {};
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Tabs as BaseTabs } from '@base-ui/react/tabs';
|
|
2
|
+
import { VariantProps } from 'class-variance-authority';
|
|
3
|
+
import type * as React from 'react';
|
|
4
|
+
export interface ITabsProps extends Omit<BaseTabs.Root.Props, 'value' | 'defaultValue' | 'onValueChange' | 'className' | 'orientation' | 'children'> {
|
|
5
|
+
/** Controlled selected tab. Provide with `onValueChange`. */
|
|
6
|
+
value?: string;
|
|
7
|
+
/** Uncontrolled initial tab. Use this when the component should own its state. */
|
|
8
|
+
defaultValue?: string;
|
|
9
|
+
onValueChange?: (value: string) => void;
|
|
10
|
+
className?: string;
|
|
11
|
+
orientation?: 'horizontal' | 'vertical';
|
|
12
|
+
children: React.ReactNode;
|
|
13
|
+
}
|
|
14
|
+
export declare const Tabs: ({ value, defaultValue, onValueChange, className, orientation, children, ...props }: ITabsProps) => React.JSX.Element;
|
|
15
|
+
export declare const tabsListVariants: (props?: ({
|
|
16
|
+
variant?: "default" | "line" | null | undefined;
|
|
17
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
18
|
+
export interface ITabsListProps extends VariantProps<typeof tabsListVariants>, Omit<BaseTabs.List.Props, 'className' | 'children'> {
|
|
19
|
+
className?: string;
|
|
20
|
+
children: React.ReactNode;
|
|
21
|
+
}
|
|
22
|
+
export declare const TabsList: ({ className, variant, children, ...props }: ITabsListProps) => React.JSX.Element;
|
|
23
|
+
export interface ITabsTriggerProps extends Omit<BaseTabs.Tab.Props, 'value' | 'disabled' | 'className' | 'children'> {
|
|
24
|
+
value: string;
|
|
25
|
+
disabled?: boolean;
|
|
26
|
+
className?: string;
|
|
27
|
+
children: React.ReactNode;
|
|
28
|
+
}
|
|
29
|
+
export declare const TabsTrigger: ({ value, disabled, className, children, ...props }: ITabsTriggerProps) => React.JSX.Element;
|
|
30
|
+
export interface ITabsContentProps extends Omit<BaseTabs.Panel.Props, 'value' | 'keepMounted' | 'className' | 'children'> {
|
|
31
|
+
value: string;
|
|
32
|
+
keepMounted?: boolean;
|
|
33
|
+
className?: string;
|
|
34
|
+
children: React.ReactNode;
|
|
35
|
+
}
|
|
36
|
+
export declare const TabsContent: ({ value, keepMounted, className, children, ...props }: ITabsContentProps) => React.JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './textarea';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './toast';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Toast as ToastPrimitive } from '@base-ui/react/toast';
|
|
2
|
+
import type * as React from 'react';
|
|
3
|
+
export declare const toast: import('@base-ui/react').ToastManager<any>;
|
|
4
|
+
export declare const ToastProvider: ({ ...props }: ToastPrimitive.Provider.Props) => React.JSX.Element;
|
|
5
|
+
export declare const ToastPortal: ({ ...props }: ToastPrimitive.Portal.Props) => React.JSX.Element;
|
|
6
|
+
export declare const ToastViewport: ({ className, ...props }: ToastPrimitive.Viewport.Props) => React.JSX.Element;
|
|
7
|
+
export declare const Toast: ({ className, ...props }: ToastPrimitive.Root.Props) => React.JSX.Element;
|
|
8
|
+
export declare const ToastContent: ({ className, ...props }: ToastPrimitive.Content.Props) => React.JSX.Element;
|
|
9
|
+
export declare const ToastTitle: ({ className, ...props }: ToastPrimitive.Title.Props) => React.JSX.Element;
|
|
10
|
+
export declare const ToastDescription: ({ className, ...props }: ToastPrimitive.Description.Props) => React.JSX.Element;
|
|
11
|
+
export declare const ToastAction: ({ className, render, ...props }: ToastPrimitive.Action.Props) => React.JSX.Element;
|
|
12
|
+
export declare const ToastClose: ({ className, children, render, ...props }: ToastPrimitive.Close.Props) => React.JSX.Element;
|
|
13
|
+
export declare const Toaster: ({ children, toastManager, ...props }: ToastPrimitive.Provider.Props) => React.JSX.Element;
|
|
14
|
+
export declare const createToastManager: typeof ToastPrimitive.createToastManager;
|
|
15
|
+
export declare const useToastManager: typeof ToastPrimitive.useToastManager;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './toggle';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Toggle as TogglePrimitive } from '@base-ui/react/toggle';
|
|
2
|
+
import { VariantProps } from 'class-variance-authority';
|
|
3
|
+
export declare const toggleVariants: (props?: ({
|
|
4
|
+
variant?: "default" | "outline" | null | undefined;
|
|
5
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
6
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
7
|
+
export type TToggleVariants = VariantProps<typeof toggleVariants>;
|
|
8
|
+
export declare const Toggle: <Value extends string>({ className, variant, size, ...props }: TogglePrimitive.Props<Value> & TToggleVariants) => import('react').JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './toggle-group';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Toggle as TogglePrimitive } from '@base-ui/react/toggle';
|
|
2
|
+
import { ToggleGroup as ToggleGroupPrimitive } from '@base-ui/react/toggle-group';
|
|
3
|
+
import { TToggleVariants } from '../toggle/toggle';
|
|
4
|
+
export declare const ToggleGroup: <Value extends string>({ className, variant, size, spacing, orientation, children, ...props }: ToggleGroupPrimitive.Props<Value> & TToggleVariants & {
|
|
5
|
+
spacing?: number;
|
|
6
|
+
}) => import('react').JSX.Element;
|
|
7
|
+
export declare const ToggleGroupItem: <Value extends string>({ className, variant, size, ...props }: TogglePrimitive.Props<Value> & TToggleVariants) => import('react').JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './tooltip';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { Tooltip as TooltipPrimitive } from '@base-ui/react/tooltip';
|
|
2
|
+
export declare const TooltipProvider: ({ delay, ...props }: TooltipPrimitive.Provider.Props) => import('react').JSX.Element;
|
|
3
|
+
export declare const Tooltip: ({ ...props }: TooltipPrimitive.Root.Props) => import('react').JSX.Element;
|
|
4
|
+
export declare const TooltipTrigger: ({ ...props }: TooltipPrimitive.Trigger.Props) => import('react').JSX.Element;
|
|
5
|
+
export declare const TooltipContent: ({ className, side, sideOffset, align, alignOffset, children, ...props }: TooltipPrimitive.Popup.Props & Pick<TooltipPrimitive.Positioner.Props, "align" | "alignOffset" | "side" | "sideOffset">) => import('react').JSX.Element;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface IMediaPlayerState {
|
|
3
|
+
playing: boolean;
|
|
4
|
+
currentTime: number;
|
|
5
|
+
duration: number;
|
|
6
|
+
volume: number;
|
|
7
|
+
muted: boolean;
|
|
8
|
+
}
|
|
9
|
+
export interface IUseMediaPlayerOptions {
|
|
10
|
+
onPlay?: () => void;
|
|
11
|
+
onPause?: () => void;
|
|
12
|
+
onEnded?: () => void;
|
|
13
|
+
onTimeUpdate?: (currentTime: number, duration: number) => void;
|
|
14
|
+
}
|
|
15
|
+
export interface IUseMediaPlayerResult<TElement extends HTMLMediaElement> extends IMediaPlayerState {
|
|
16
|
+
refMedia: React.RefObject<TElement | null>;
|
|
17
|
+
toggle: () => void;
|
|
18
|
+
seek: (seconds: number) => void;
|
|
19
|
+
changeVolume: (volume: number) => void;
|
|
20
|
+
toggleMute: () => void;
|
|
21
|
+
}
|
|
22
|
+
/** `0:00` for anything that is not a finite, non-negative number, so a loading or errored source still renders. */
|
|
23
|
+
export declare const formatMediaTime: (seconds: number) => string;
|
|
24
|
+
/**
|
|
25
|
+
* Shared playback engine for the Audio and Video players. Both wrap the same
|
|
26
|
+
* HTMLMediaElement API, so the state machine lives here once and each component
|
|
27
|
+
* owns only its own layout and controls.
|
|
28
|
+
*/
|
|
29
|
+
export declare const useMediaPlayer: <TElement extends HTMLMediaElement>(options?: IUseMediaPlayerOptions) => IUseMediaPlayerResult<TElement>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const useIsMobile: () => boolean;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
export * from './components/edyn/animated-number';
|
|
2
|
+
export * from './components/edyn/audio-player';
|
|
3
|
+
export * from './components/edyn/date-range-picker';
|
|
4
|
+
export * from './components/edyn/initials-avatar';
|
|
5
|
+
export * from './components/edyn/multi-select';
|
|
6
|
+
export * from './components/edyn/progress-line';
|
|
7
|
+
export * from './components/edyn/rich-text-content';
|
|
8
|
+
export * from './components/edyn/video-player';
|
|
9
|
+
export * from './components/ui/accordion';
|
|
10
|
+
export * from './components/ui/alert';
|
|
11
|
+
export * from './components/ui/alert-dialog';
|
|
12
|
+
export * from './components/ui/aspect-ratio';
|
|
13
|
+
export * from './components/ui/attachment';
|
|
14
|
+
export * from './components/ui/avatar';
|
|
15
|
+
export * from './components/ui/badge';
|
|
16
|
+
export * from './components/ui/breadcrumb';
|
|
17
|
+
export * from './components/ui/bubble';
|
|
18
|
+
export * from './components/ui/button';
|
|
19
|
+
export * from './components/ui/button-group';
|
|
20
|
+
export * from './components/ui/calendar';
|
|
21
|
+
export * from './components/ui/card';
|
|
22
|
+
export * from './components/ui/carousel';
|
|
23
|
+
export * from './components/ui/chart';
|
|
24
|
+
export * from './components/ui/checkbox';
|
|
25
|
+
export * from './components/ui/collapsible';
|
|
26
|
+
export * from './components/ui/combobox';
|
|
27
|
+
export * from './components/ui/command';
|
|
28
|
+
export * from './components/ui/context-menu';
|
|
29
|
+
export * from './components/ui/dialog';
|
|
30
|
+
export * from './components/ui/direction';
|
|
31
|
+
export * from './components/ui/drawer';
|
|
32
|
+
export * from './components/ui/dropdown-menu';
|
|
33
|
+
export * from './components/ui/empty';
|
|
34
|
+
export * from './components/ui/field';
|
|
35
|
+
export * from './components/ui/hover-card';
|
|
36
|
+
export * from './components/ui/indicator';
|
|
37
|
+
export * from './components/ui/input';
|
|
38
|
+
export * from './components/ui/input-group';
|
|
39
|
+
export * from './components/ui/input-otp';
|
|
40
|
+
export * from './components/ui/item';
|
|
41
|
+
export * from './components/ui/kbd';
|
|
42
|
+
export * from './components/ui/label';
|
|
43
|
+
export * from './components/ui/marker';
|
|
44
|
+
export * from './components/ui/menubar';
|
|
45
|
+
export * from './components/ui/message';
|
|
46
|
+
export * from './components/ui/message-scroller';
|
|
47
|
+
export * from './components/ui/native-select';
|
|
48
|
+
export * from './components/ui/navigation-menu';
|
|
49
|
+
export * from './components/ui/pagination';
|
|
50
|
+
export * from './components/ui/popover';
|
|
51
|
+
export * from './components/ui/progress';
|
|
52
|
+
export * from './components/ui/questionnaire';
|
|
53
|
+
export * from './components/ui/radio-group';
|
|
54
|
+
export * from './components/ui/resizable';
|
|
55
|
+
export * from './components/ui/scroll-area';
|
|
56
|
+
export * from './components/ui/select';
|
|
57
|
+
export * from './components/ui/separator';
|
|
58
|
+
export * from './components/ui/sheet';
|
|
59
|
+
export * from './components/ui/sidebar';
|
|
60
|
+
export * from './components/ui/skeleton';
|
|
61
|
+
export * from './components/ui/slider';
|
|
62
|
+
export * from './components/ui/spinner';
|
|
63
|
+
export * from './components/ui/switch';
|
|
64
|
+
export * from './components/ui/table';
|
|
65
|
+
export * from './components/ui/tabs';
|
|
66
|
+
export * from './components/ui/textarea';
|
|
67
|
+
export * from './components/ui/toast';
|
|
68
|
+
export * from './components/ui/toggle';
|
|
69
|
+
export * from './components/ui/toggle-group';
|
|
70
|
+
export * from './components/ui/tooltip';
|
|
71
|
+
export * from './hooks/use-media-player';
|
|
72
|
+
export * from './hooks/use-merged-refs';
|
|
73
|
+
export * from './hooks/use-mobile';
|
|
74
|
+
export { cn } from './lib/utils';
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export type TWeekday = 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
2
|
+
/**
|
|
3
|
+
* The weekday a locale starts its week on, 0 for Sunday to 6 for Saturday, from Intl, so en-GB starts on Monday and en-US on
|
|
4
|
+
* Sunday with no locale data of our own shipped. A browser without week info gets the region's usual start.
|
|
5
|
+
*/
|
|
6
|
+
export declare const firstWeekdayOf: (locale: string) => TWeekday;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The default focus ring must be visible, not just present. WCAG 1.4.11 asks 3:1 for the
|
|
3
|
+
* parts of a control that show its state, and the ring is drawn outside the control, on
|
|
4
|
+
* whatever surface it sits on. This reads the real tokens.css, converts OKLCH to sRGB and
|
|
5
|
+
* measures the default --ring against every surface a control sits on, in both themes.
|
|
6
|
+
* An app that sets its own --ring (a brand) is outside this: it owns that colour.
|
|
7
|
+
*/
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The one look for a list in a popup or a menu: the command palette, Select,
|
|
3
|
+
* Combobox, MultiSelect and the dropdown menus.
|
|
4
|
+
*
|
|
5
|
+
* These lists used to disagree with each other in every detail that shows:
|
|
6
|
+
* three different radii, two different paddings, a grey fill for the highlight
|
|
7
|
+
* in one and the accent in another, and the chosen item marked by a check on
|
|
8
|
+
* the left in Select and on the right in the menus. Picking something from one
|
|
9
|
+
* list then felt like a different product from picking something in the next.
|
|
10
|
+
*
|
|
11
|
+
* It lives here as classes rather than as a stylesheet so a caller's own
|
|
12
|
+
* className still wins: an unlayered rule would beat every utility, including
|
|
13
|
+
* the one someone passes for a single list.
|
|
14
|
+
*
|
|
15
|
+
* ONE ITEM: transparent at rest, 32px tall, 6px radius (--radius-sm), 6px by
|
|
16
|
+
* 8px of padding, text-sm, its own icons 16px and muted. Under the pointer or
|
|
17
|
+
* the keyboard it takes one translucent fill of the text colour, and its icons
|
|
18
|
+
* the text colour. Chosen is medium weight with a check at the END, never a
|
|
19
|
+
* fill, so "where I am" and "what I picked" can be told apart at a glance.
|
|
20
|
+
*/
|
|
21
|
+
/**
|
|
22
|
+
* Which primitive renders the item, because the two disagree about the same
|
|
23
|
+
* attribute names in a way that silently breaks the styling:
|
|
24
|
+
*
|
|
25
|
+
* - cmdk writes `data-selected="false"` and `data-disabled="false"` on items
|
|
26
|
+
* that are neither, so a bare `data-selected:` variant matches EVERY item and
|
|
27
|
+
* highlights the whole list. Its states have to be matched by value.
|
|
28
|
+
* - Base UI omits the attribute instead, so presence is the test there. That
|
|
29
|
+
* needs the BRACKET form for `selected`: shadcn redefines the bare
|
|
30
|
+
* `data-selected:` variant to match only data-selected="true" (for the
|
|
31
|
+
* calendar), and Base UI writes it as an empty string, so the bare form
|
|
32
|
+
* compiles and silently never applies. `highlighted` and `disabled` have no
|
|
33
|
+
* such override, so those stay bare.
|
|
34
|
+
* - And the same name means different things: cmdk's `data-selected` is the
|
|
35
|
+
* keyboard cursor, Base UI's is the chosen value. In cmdk the chosen state is
|
|
36
|
+
* `data-checked`, which the DS's own CommandItem sets.
|
|
37
|
+
*/
|
|
38
|
+
export type TPopupItemFlavor = 'base-ui' | 'cmdk';
|
|
39
|
+
/** The shared item look. `checkable` leaves room at the end for the check. */
|
|
40
|
+
export declare const popupItemClass: (flavor?: TPopupItemFlavor, checkable?: boolean) => string;
|
|
41
|
+
/**
|
|
42
|
+
* The check's slot, at the end of the item and the same size whether or not the
|
|
43
|
+
* check is in it, so a list does not shift as the choice moves.
|
|
44
|
+
*/
|
|
45
|
+
export declare const POPUP_ITEM_INDICATOR_CLASS = "pointer-events-none absolute right-2 flex size-4 items-center justify-center text-foreground";
|
|
46
|
+
/** A group's heading in any of these lists. */
|
|
47
|
+
export declare const POPUP_GROUP_LABEL_CLASS = "px-2 py-1.5 text-xs font-medium text-muted-foreground";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The shared popup list style, and the trap it exists to keep closed.
|
|
3
|
+
*
|
|
4
|
+
* PATH TAKEN: the look itself is measured in a real browser across the lists and
|
|
5
|
+
* both themes (e2e/popup-lists.spec.ts), because computed padding and radius are
|
|
6
|
+
* the only honest proof of "one look". What is checked here is the part a
|
|
7
|
+
* stylesheet cannot: that each list takes its item look from one place, and that
|
|
8
|
+
* the two primitives' disagreeing attribute conventions are matched correctly.
|
|
9
|
+
*/
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ClassValue } from 'clsx';
|
|
2
|
+
export declare const cn: (...inputs: ClassValue[]) => string;
|
|
3
|
+
/** A CSS length as a component prop: a number is px, a string is used verbatim. */
|
|
4
|
+
export type TCssLength = number | string;
|
|
5
|
+
/**
|
|
6
|
+
* Normalise a size prop to a CSS length.
|
|
7
|
+
*
|
|
8
|
+
* Bare numbers become px, which is also what a bare numeric *string* means: an
|
|
9
|
+
* element attribute arrives as a string, so `width="480"` and `width={480}` have
|
|
10
|
+
* to land on the same value. Anything with a unit, a percentage or a keyword
|
|
11
|
+
* passes through untouched.
|
|
12
|
+
*/
|
|
13
|
+
export declare const cssLength: (value: TCssLength | null | undefined) => string | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,97 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@exsto/ds",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "0.0.1-rc.10",
|
|
4
|
+
"description": "The eDynamix design system: React components and design tokens.",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"keywords": [
|
|
7
|
+
"exsto",
|
|
8
|
+
"edynamix",
|
|
9
|
+
"design-system",
|
|
10
|
+
"react",
|
|
11
|
+
"components",
|
|
12
|
+
"ui",
|
|
13
|
+
"tailwind"
|
|
14
|
+
],
|
|
15
|
+
"type": "module",
|
|
16
|
+
"sideEffects": [
|
|
17
|
+
"**/*.css"
|
|
18
|
+
],
|
|
19
|
+
"files": [
|
|
20
|
+
"dist"
|
|
21
|
+
],
|
|
22
|
+
"publishConfig": {
|
|
23
|
+
"access": "public"
|
|
24
|
+
},
|
|
25
|
+
"exports": {
|
|
26
|
+
".": {
|
|
27
|
+
"types": "./dist/ds/src/index.d.ts",
|
|
28
|
+
"default": "./dist/index.js"
|
|
29
|
+
},
|
|
30
|
+
"./date-picker": {
|
|
31
|
+
"types": "./dist/ds/src/date-picker.d.ts",
|
|
32
|
+
"default": "./dist/date-picker.js"
|
|
33
|
+
},
|
|
34
|
+
"./rich-text-editor": {
|
|
35
|
+
"types": "./dist/ds/src/rich-text-editor.d.ts",
|
|
36
|
+
"default": "./dist/rich-text-editor.js"
|
|
37
|
+
},
|
|
38
|
+
"./styles.css": {
|
|
39
|
+
"types": "./dist/styles.css.d.ts",
|
|
40
|
+
"default": "./dist/styles.css"
|
|
41
|
+
},
|
|
42
|
+
"./theme.css": {
|
|
43
|
+
"types": "./dist/theme.css.d.ts",
|
|
44
|
+
"default": "./dist/theme.css"
|
|
45
|
+
},
|
|
46
|
+
"./package.json": "./package.json"
|
|
47
|
+
},
|
|
48
|
+
"scripts": {
|
|
49
|
+
"build": "vite build",
|
|
50
|
+
"typecheck": "tsc --noEmit"
|
|
51
|
+
},
|
|
52
|
+
"dependencies": {
|
|
53
|
+
"@base-ui/react": "~1.8.0",
|
|
54
|
+
"@shadcn/react": "^0.3.1",
|
|
55
|
+
"@tabler/icons-react": "^3.44.0",
|
|
56
|
+
"@tanstack/react-virtual": "^3.13.0",
|
|
57
|
+
"@tiptap/core": "3.32.2",
|
|
58
|
+
"@tiptap/extension-bold": "3.32.2",
|
|
59
|
+
"@tiptap/extension-document": "3.32.2",
|
|
60
|
+
"@tiptap/extension-hard-break": "3.32.2",
|
|
61
|
+
"@tiptap/extension-horizontal-rule": "3.32.2",
|
|
62
|
+
"@tiptap/extension-italic": "3.32.2",
|
|
63
|
+
"@tiptap/extension-link": "3.32.2",
|
|
64
|
+
"@tiptap/extension-list": "3.32.2",
|
|
65
|
+
"@tiptap/extension-mention": "3.32.2",
|
|
66
|
+
"@tiptap/extension-paragraph": "3.32.2",
|
|
67
|
+
"@tiptap/extension-text": "3.32.2",
|
|
68
|
+
"@tiptap/extension-underline": "3.32.2",
|
|
69
|
+
"@tiptap/extensions": "3.32.2",
|
|
70
|
+
"@tiptap/pm": "3.32.2",
|
|
71
|
+
"@tiptap/react": "3.32.2",
|
|
72
|
+
"@tiptap/suggestion": "3.32.2",
|
|
73
|
+
"class-variance-authority": "^0.7.1",
|
|
74
|
+
"clsx": "^2.1.1",
|
|
75
|
+
"cmdk": "^1.1.1",
|
|
76
|
+
"date-fns": "^4.4.0",
|
|
77
|
+
"embla-carousel-react": "^8.6.0",
|
|
78
|
+
"input-otp": "^1.4.2",
|
|
79
|
+
"react-day-picker": "^10.0.1",
|
|
80
|
+
"react-resizable-panels": "^4.12.4",
|
|
81
|
+
"recharts": "3.8.0",
|
|
82
|
+
"tailwind-merge": "^3.6.0"
|
|
83
|
+
},
|
|
84
|
+
"peerDependencies": {
|
|
85
|
+
"react": "^19.0.0",
|
|
86
|
+
"react-dom": "^19.0.0"
|
|
87
|
+
},
|
|
88
|
+
"devDependencies": {
|
|
89
|
+
"@edyn/theme": "workspace:*",
|
|
90
|
+
"@edyn/ui": "workspace:*",
|
|
91
|
+
"@tailwindcss/node": "catalog:",
|
|
92
|
+
"@tailwindcss/vite": "catalog:",
|
|
93
|
+
"@vitejs/plugin-react": "catalog:",
|
|
94
|
+
"vite": "catalog:",
|
|
95
|
+
"vite-plugin-dts": "^5.1.2"
|
|
96
|
+
}
|
|
97
|
+
}
|