@juspay/blend-design-system 0.0.29 → 0.0.30-beta
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/dist/components/ButtonGroup/accessibility/ButtonGroupAccessibility.d.ts +5 -0
- package/dist/components/ButtonGroup/accessibility/ButtonGroupAccessibilityReport.d.ts +44 -0
- package/dist/components/ButtonGroup/accessibility/index.d.ts +4 -0
- package/dist/components/Card/CardComponents.d.ts +3 -0
- package/dist/components/Card/accessibility/CardAccessibility.d.ts +5 -0
- package/dist/components/Card/accessibility/CardAccessibilityReport.d.ts +2 -0
- package/dist/components/Charts/accessibility/ChartsAccessibility.d.ts +5 -0
- package/dist/components/Charts/accessibility/ChartsAccessibilityReport.d.ts +2 -0
- package/dist/components/Charts/types.d.ts +1 -0
- package/dist/components/ChatInput/accessibility/ChatInputAccessibility.d.ts +5 -0
- package/dist/components/ChatInput/accessibility/ChatInputAccessibilityReport.d.ts +44 -0
- package/dist/components/ChatInput/accessibility/index.d.ts +4 -0
- package/dist/components/ChatInput/utils.d.ts +10 -0
- package/dist/components/CodeBlock/accessibility/CodeBlockAccessibility.d.ts +5 -0
- package/dist/components/CodeBlock/accessibility/CodeBlockAccessibilityReport.d.ts +2 -0
- package/dist/components/DataTable/TableBody/types.d.ts +5 -0
- package/dist/components/DataTable/TableCell/types.d.ts +8 -0
- package/dist/components/DataTable/TableHeader/DraggableColumnHeader.d.ts +2 -2
- package/dist/components/DataTable/TableHeader/FilterComponents.d.ts +3 -0
- package/dist/components/DataTable/TableHeader/types.d.ts +9 -0
- package/dist/components/DataTable/accessibility/DataTableAccessibility.d.ts +5 -0
- package/dist/components/DataTable/accessibility/DataTableAccessibilityReport.d.ts +44 -0
- package/dist/components/DataTable/accessibility/index.d.ts +4 -0
- package/dist/components/DataTable/dataTable.tokens.d.ts +2 -0
- package/dist/components/DataTable/types.d.ts +1 -0
- package/dist/components/DateRangePicker/TimeSelector.d.ts +2 -0
- package/dist/components/DateRangePicker/accessibility/DateRangePickerAccessibility.d.ts +5 -0
- package/dist/components/DateRangePicker/accessibility/DateRangePickerAccessibilityReport.d.ts +2 -0
- package/dist/components/DateRangePicker/accessibility/index.d.ts +4 -0
- package/dist/components/Directory/Directory.d.ts +1 -1
- package/dist/components/Directory/NavItem.d.ts +17 -3
- package/dist/components/Directory/Section.d.ts +1 -1
- package/dist/components/Directory/types.d.ts +6 -1
- package/dist/components/Drawer/accessibility/DrawerAccessibility.d.ts +5 -0
- package/dist/components/Drawer/accessibility/DrawerAccessibilityReport.d.ts +2 -0
- package/dist/components/Drawer/components/DrawerBase.d.ts +6 -2
- package/dist/components/Drawer/types.d.ts +12 -0
- package/dist/components/Inputs/NumberInput/types.d.ts +1 -1
- package/dist/components/Inputs/TextInput/TextInput.d.ts +1 -1
- package/dist/components/Inputs/TextInput/types.d.ts +1 -0
- package/dist/components/KeyValuePair/utils.d.ts +1 -1
- package/dist/components/Modal/types.d.ts +4 -0
- package/dist/components/MultiSelect/accessibility/index.d.ts +2 -0
- package/dist/components/ProgressBar/accessibility/ProgressBarAccessibility.d.ts +5 -0
- package/dist/components/ProgressBar/accessibility/ProgressBarAccessibilityReport.d.ts +44 -0
- package/dist/components/ProgressBar/types.d.ts +2 -0
- package/dist/components/ProgressBar/utils.d.ts +24 -0
- package/dist/components/Select/types.d.ts +1 -0
- package/dist/components/Sidebar/SidebarHeader.d.ts +1 -0
- package/dist/components/Sidebar/accessibility/SidebarAccessibility.d.ts +5 -0
- package/dist/components/Sidebar/accessibility/SidebarAccessibilityReport.d.ts +2 -0
- package/dist/components/Sidebar/types.d.ts +3 -0
- package/dist/components/Slider/accessibility/SliderAccessibility.d.ts +5 -0
- package/dist/components/Slider/accessibility/SliderAccessibilityReport.d.ts +44 -0
- package/dist/components/Slider/accessibility/index.d.ts +4 -0
- package/dist/components/Slider/utils.d.ts +24 -2
- package/dist/components/Snackbar/Snackbar.d.ts +1 -4
- package/dist/components/Snackbar/types.d.ts +7 -0
- package/dist/components/SplitTag/SplitTag.d.ts +1 -1
- package/dist/components/SplitTag/accessibility/SplitTagAccessibility.d.ts +5 -0
- package/dist/components/SplitTag/accessibility/SplitTagAccessibilityReport.d.ts +2 -0
- package/dist/components/StatCard/accessibility/StatCardAccessibility.d.ts +5 -0
- package/dist/components/StatCard/accessibility/StatCardAccessibilityReport.d.ts +44 -0
- package/dist/components/Stepper/accessibility/StepperAccessibility.d.ts +5 -0
- package/dist/components/Stepper/accessibility/StepperAccessibilityReport.d.ts +2 -0
- package/dist/components/Stepper/types.d.ts +1 -0
- package/dist/components/Tabs/Tabs.d.ts +0 -1
- package/dist/components/Tabs/TabsList.d.ts +0 -1
- package/dist/components/Tabs/types.d.ts +1 -2
- package/dist/components/Tooltip/Tooltip.d.ts +1 -1
- package/dist/components/Tooltip/types.d.ts +1 -0
- package/dist/components/Topbar/types.d.ts +2 -0
- package/dist/components/Upload/accessibility/UploadAccessibility.d.ts +5 -0
- package/dist/components/Upload/accessibility/UploadAccessibilityReport.d.ts +2 -0
- package/dist/components/Upload/accessibility/index.d.ts +3 -0
- package/dist/components/Upload/types.d.ts +12 -1
- package/dist/components/shared/accessibility/LightHouse-components/AccordionLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/AlertLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/AvatarGroupLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/AvatarLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/BreadcrumbLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/ButtonGroupLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/CardLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/ChartsLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/ChatInputLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/CheckboxLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/CodeBlockLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/DrawerLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/KeyValuePairLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/MenuLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/MultiSelectLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/ProgressBarLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/RadioLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/SidebarLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/SingleSelectLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/SliderLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/SnackbarLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/SplitTagLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/StatCardLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/StepperLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/SwitchLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/TabsLightHouse.d.ts +2 -0
- package/dist/components/shared/accessibility/LightHouse-components/UploadLightHouse.d.ts +2 -0
- package/dist/global-utils/GlobalUtils.d.ts +2 -0
- package/dist/main.js +31679 -29077
- package/package.json +1 -1
- package/dist/components/DataTable/DataTable.stories.d.ts +0 -16
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ProgressBarTokenType } from './progressbar.tokens';
|
|
2
|
+
import { ProgressBarSize } from './types';
|
|
3
|
+
export declare const clampValue: (value: number, min: number, max: number) => number;
|
|
4
|
+
export declare const calculatePercentage: (value: number, min: number, max: number) => number;
|
|
5
|
+
export declare const parseTokenValue: (tokenValue: string | number | undefined, fallback: number) => number;
|
|
6
|
+
export declare const extractAriaProps: (rest: Record<string, unknown> | undefined) => {
|
|
7
|
+
"aria-label"?: string;
|
|
8
|
+
"aria-labelledby"?: string;
|
|
9
|
+
restProps: Record<string, unknown>;
|
|
10
|
+
};
|
|
11
|
+
export declare const generateDefaultAriaLabel: (value: number, min: number, max: number) => string;
|
|
12
|
+
export declare const getCircularDimensions: (size: ProgressBarSize, tokens: ProgressBarTokenType) => {
|
|
13
|
+
circularSize: string;
|
|
14
|
+
sizeNum: number;
|
|
15
|
+
strokeWidth: number;
|
|
16
|
+
radius: number;
|
|
17
|
+
circumference: number;
|
|
18
|
+
center: number;
|
|
19
|
+
};
|
|
20
|
+
export declare const calculateCircularStroke: (type: "solid" | "segmented", circumference: number, percentage: number) => {
|
|
21
|
+
strokeDasharray: string;
|
|
22
|
+
strokeDashoffset: number;
|
|
23
|
+
dashArray: string;
|
|
24
|
+
};
|
|
@@ -99,6 +99,9 @@ export type SidebarProps = {
|
|
|
99
99
|
* Extends HTML button attributes
|
|
100
100
|
*/
|
|
101
101
|
primaryActionButtonProps?: Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'type'>;
|
|
102
|
+
activeItem?: string | null;
|
|
103
|
+
onActiveItemChange?: (item: string | null) => void;
|
|
104
|
+
defaultActiveItem?: string | null;
|
|
102
105
|
};
|
|
103
106
|
export type MobileNavigationItem = NavbarItem & {
|
|
104
107
|
sectionLabel?: string;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Slider Component Accessibility Report Data
|
|
3
|
+
* WCAG 2.0, 2.1, 2.2 Level A, AA Compliance Analysis
|
|
4
|
+
*
|
|
5
|
+
* Note: Items marked with "unsure" require manual verification
|
|
6
|
+
* Color contrast ratios verified using actual color values from theme tokens
|
|
7
|
+
*/
|
|
8
|
+
export type WCAGSuccessCriterion = {
|
|
9
|
+
id: string;
|
|
10
|
+
level: 'A' | 'AA' | 'AAA';
|
|
11
|
+
title: string;
|
|
12
|
+
status: 'compliant' | 'non-compliant' | 'unsure' | 'not-applicable';
|
|
13
|
+
description: string;
|
|
14
|
+
implementation: string;
|
|
15
|
+
testResults?: string;
|
|
16
|
+
notes?: string;
|
|
17
|
+
};
|
|
18
|
+
export type AccessibilityReport = {
|
|
19
|
+
componentName: string;
|
|
20
|
+
wcagVersion: string;
|
|
21
|
+
reportDate: string;
|
|
22
|
+
conformanceLevel: string;
|
|
23
|
+
overallStatus: 'compliant' | 'non-compliant' | 'partial' | 'unsure';
|
|
24
|
+
summary: string;
|
|
25
|
+
criteria: WCAGSuccessCriterion[];
|
|
26
|
+
strengths: string[];
|
|
27
|
+
recommendations: string[];
|
|
28
|
+
wcagVersions: {
|
|
29
|
+
'2.0': string[];
|
|
30
|
+
'2.1': string[];
|
|
31
|
+
'2.2': string[];
|
|
32
|
+
};
|
|
33
|
+
testMethodology: {
|
|
34
|
+
automated: string[];
|
|
35
|
+
manual: string[];
|
|
36
|
+
verificationTools: string[];
|
|
37
|
+
wcagLevels: {
|
|
38
|
+
A: string[];
|
|
39
|
+
AA: string[];
|
|
40
|
+
AAA: string[];
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
export declare const sliderAccessibilityReport: AccessibilityReport;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { default as SliderAccessibility } from './SliderAccessibility';
|
|
2
|
+
export type { SliderAccessibilityProps } from './SliderAccessibility';
|
|
3
|
+
export { sliderAccessibilityReport } from './SliderAccessibilityReport';
|
|
4
|
+
export type { AccessibilityReport, WCAGSuccessCriterion, } from './SliderAccessibilityReport';
|
|
@@ -8,6 +8,10 @@ type SliderCSSProperties = React.CSSProperties & {
|
|
|
8
8
|
outline?: string;
|
|
9
9
|
boxShadow?: string;
|
|
10
10
|
};
|
|
11
|
+
'&:focus-visible'?: {
|
|
12
|
+
outline?: string;
|
|
13
|
+
boxShadow?: string;
|
|
14
|
+
};
|
|
11
15
|
'&:active'?: {
|
|
12
16
|
cursor?: string;
|
|
13
17
|
};
|
|
@@ -16,12 +20,12 @@ type SliderCSSProperties = React.CSSProperties & {
|
|
|
16
20
|
opacity?: string | number;
|
|
17
21
|
};
|
|
18
22
|
};
|
|
19
|
-
|
|
23
|
+
type SliderTokenStyles = {
|
|
20
24
|
root: SliderCSSProperties;
|
|
21
25
|
track: SliderCSSProperties;
|
|
22
26
|
range: SliderCSSProperties;
|
|
23
27
|
thumb: SliderCSSProperties;
|
|
24
|
-
}
|
|
28
|
+
};
|
|
25
29
|
export declare const getSliderTokenStyles: (variant: SliderVariant, size: SliderSize) => SliderTokenStyles;
|
|
26
30
|
/**
|
|
27
31
|
* Formats a slider value according to the specified format configuration
|
|
@@ -42,6 +46,24 @@ export declare const createSliderRange: (min: number, max: number, step: number,
|
|
|
42
46
|
defaultValue: number[];
|
|
43
47
|
valueFormat: SliderValueFormatConfig;
|
|
44
48
|
};
|
|
49
|
+
/**
|
|
50
|
+
* Get label styles for value display
|
|
51
|
+
*/
|
|
52
|
+
/**
|
|
53
|
+
* Builds ARIA attributes for slider thumb elements
|
|
54
|
+
*/
|
|
55
|
+
export declare const buildThumbAriaAttributes: (options: {
|
|
56
|
+
min: number;
|
|
57
|
+
max: number;
|
|
58
|
+
value: number;
|
|
59
|
+
formattedValue: string;
|
|
60
|
+
disabled?: boolean;
|
|
61
|
+
ariaLabel?: string;
|
|
62
|
+
ariaLabelledBy?: string;
|
|
63
|
+
ariaDescribedBy?: string;
|
|
64
|
+
thumbIndex: number;
|
|
65
|
+
thumbCount: number;
|
|
66
|
+
}) => Record<string, string | undefined>;
|
|
45
67
|
/**
|
|
46
68
|
* Get label styles for value display
|
|
47
69
|
*/
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import { AddToastOptions, CustomToastProps,
|
|
2
|
+
import { AddToastOptions, CustomToastProps, SnackbarProps } from './types';
|
|
3
3
|
export declare const StyledToast: React.FC<CustomToastProps>;
|
|
4
4
|
export declare const addSnackbar: ({ header, description, variant, onClose, actionButton, duration, position, }: AddToastOptions) => string | number;
|
|
5
|
-
type SnackbarProps = {
|
|
6
|
-
position?: SnackbarPosition;
|
|
7
|
-
};
|
|
8
5
|
declare const Snackbar: React.FC<SnackbarProps>;
|
|
9
6
|
export default Snackbar;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SplitTagProps } from './types';
|
|
2
2
|
declare const SplitTag: {
|
|
3
|
-
({ primaryTag, secondaryTag, size, shape }: SplitTagProps): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
({ primaryTag, secondaryTag, size, shape, ...props }: SplitTagProps): import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
displayName: string;
|
|
5
5
|
};
|
|
6
6
|
export default SplitTag;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
export type WCAGSuccessCriterion = {
|
|
2
|
+
id: string;
|
|
3
|
+
level: 'A' | 'AA' | 'AAA';
|
|
4
|
+
title: string;
|
|
5
|
+
status: 'compliant' | 'non-compliant' | 'unsure' | 'not-applicable';
|
|
6
|
+
description: string;
|
|
7
|
+
implementation: string;
|
|
8
|
+
testResults?: string;
|
|
9
|
+
notes?: string;
|
|
10
|
+
};
|
|
11
|
+
export type AccessibilityReport = {
|
|
12
|
+
componentName: string;
|
|
13
|
+
wcagVersion: string;
|
|
14
|
+
reportDate: string;
|
|
15
|
+
conformanceLevel: string;
|
|
16
|
+
overallStatus: 'compliant' | 'non-compliant' | 'partial' | 'unsure';
|
|
17
|
+
summary: string;
|
|
18
|
+
criteria: WCAGSuccessCriterion[];
|
|
19
|
+
strengths: string[];
|
|
20
|
+
recommendations: string[];
|
|
21
|
+
wcagVersions: {
|
|
22
|
+
'2.0': string[];
|
|
23
|
+
'2.1': string[];
|
|
24
|
+
'2.2': string[];
|
|
25
|
+
};
|
|
26
|
+
testMethodology: {
|
|
27
|
+
automated: string[];
|
|
28
|
+
manual: string[];
|
|
29
|
+
verificationTools: string[];
|
|
30
|
+
wcagLevels: {
|
|
31
|
+
A: string[];
|
|
32
|
+
AA: string[];
|
|
33
|
+
AAA: string[];
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
accessibilityBestPractices?: {
|
|
37
|
+
[key: string]: {
|
|
38
|
+
status: 'compliant' | 'non-compliant' | 'unsure' | 'not-applicable';
|
|
39
|
+
implementation: string;
|
|
40
|
+
verification: string;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
export declare const statCardAccessibilityReport: AccessibilityReport;
|
|
@@ -11,7 +11,6 @@ declare const Tabs: React.ForwardRefExoticComponent<Omit<import('@radix-ui/react
|
|
|
11
11
|
showAddButton?: boolean;
|
|
12
12
|
dropdownTooltip?: string;
|
|
13
13
|
addButtonTooltip?: string;
|
|
14
|
-
maxDisplayTabs?: number;
|
|
15
14
|
disable?: boolean;
|
|
16
15
|
showSkeleton?: boolean;
|
|
17
16
|
skeletonVariant?: import('../Skeleton').SkeletonVariant;
|
|
@@ -13,7 +13,6 @@ declare const TabsList: React.ForwardRefExoticComponent<Omit<import('@radix-ui/r
|
|
|
13
13
|
showAddButton?: boolean;
|
|
14
14
|
dropdownTooltip?: string;
|
|
15
15
|
addButtonTooltip?: string;
|
|
16
|
-
maxDisplayTabs?: number;
|
|
17
16
|
onTabChange?: (value: string) => void;
|
|
18
17
|
activeTab?: string;
|
|
19
18
|
disable?: boolean;
|
|
@@ -22,6 +22,7 @@ export type TabItem = {
|
|
|
22
22
|
skeletonVariant?: SkeletonVariant;
|
|
23
23
|
leftSlot?: ReactNode;
|
|
24
24
|
rightSlot?: ReactNode;
|
|
25
|
+
newItem?: boolean;
|
|
25
26
|
};
|
|
26
27
|
export type TabsProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Root> & {
|
|
27
28
|
variant?: TabsVariant;
|
|
@@ -35,7 +36,6 @@ export type TabsProps = ComponentPropsWithoutRef<typeof TabsPrimitive.Root> & {
|
|
|
35
36
|
showAddButton?: boolean;
|
|
36
37
|
dropdownTooltip?: string;
|
|
37
38
|
addButtonTooltip?: string;
|
|
38
|
-
maxDisplayTabs?: number;
|
|
39
39
|
disable?: boolean;
|
|
40
40
|
showSkeleton?: boolean;
|
|
41
41
|
skeletonVariant?: SkeletonVariant;
|
|
@@ -53,7 +53,6 @@ export type TabsListProps = ComponentPropsWithoutRef<typeof TabsPrimitive.List>
|
|
|
53
53
|
showAddButton?: boolean;
|
|
54
54
|
dropdownTooltip?: string;
|
|
55
55
|
addButtonTooltip?: string;
|
|
56
|
-
maxDisplayTabs?: number;
|
|
57
56
|
onTabChange?: (value: string) => void;
|
|
58
57
|
activeTab?: string;
|
|
59
58
|
disable?: boolean;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { TooltipProps } from './types';
|
|
2
|
-
export declare const Tooltip: ({ children: trigger, content, side, align, showArrow, size, slot, slotDirection, delayDuration, offset, open, maxWidth, }: TooltipProps) => import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export declare const Tooltip: ({ children: trigger, content, side, align, showArrow, size, slot, slotDirection, delayDuration, offset, open, maxWidth, fullWidth, }: TooltipProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default Tooltip;
|
|
@@ -25,6 +25,15 @@ export type UploadedFileWithStatus = {
|
|
|
25
25
|
status: 'success' | 'error';
|
|
26
26
|
error?: string;
|
|
27
27
|
};
|
|
28
|
+
/**
|
|
29
|
+
* Form value type for Upload component
|
|
30
|
+
* - Single file: File | null
|
|
31
|
+
* - Multiple files: File[]
|
|
32
|
+
* Users can extract filenames and filemimes from File objects:
|
|
33
|
+
* - filenames: files.map(f => f.name)
|
|
34
|
+
* - filemimes: files.map(f => f.type)
|
|
35
|
+
*/
|
|
36
|
+
export type UploadFormValue = File | File[] | null;
|
|
28
37
|
export type UploadProps = {
|
|
29
38
|
multiple?: boolean;
|
|
30
39
|
accept?: string[];
|
|
@@ -44,6 +53,8 @@ export type UploadProps = {
|
|
|
44
53
|
uploadedFiles?: UploadedFileWithStatus[];
|
|
45
54
|
failedFiles?: UploadedFileWithStatus[];
|
|
46
55
|
enforceFileTypeConsistency?: boolean;
|
|
56
|
+
value?: UploadFormValue;
|
|
57
|
+
onChange?: (value: UploadFormValue) => void;
|
|
47
58
|
onDrop?: (acceptedFiles: File[], fileRejections: FileRejection[]) => void;
|
|
48
59
|
onDropAccepted?: (files: File[]) => void;
|
|
49
60
|
onDropRejected?: (fileRejections: FileRejection[]) => void;
|
|
@@ -53,4 +64,4 @@ export type UploadProps = {
|
|
|
53
64
|
isDragAccept?: boolean;
|
|
54
65
|
isDragReject?: boolean;
|
|
55
66
|
validator?: (file: File) => FileRejection['errors'][0] | null;
|
|
56
|
-
} & Omit<React.HTMLAttributes<HTMLDivElement>, 'onDrop' | 'onDragOver' | 'onDragLeave'>;
|
|
67
|
+
} & Omit<React.HTMLAttributes<HTMLDivElement>, 'onDrop' | 'onDragOver' | 'onDragLeave' | 'onChange'>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
1
2
|
export declare const toPixels: (value: string | number | undefined) => number;
|
|
2
3
|
export declare const capitalizeFirstLetter: (string: string) => string;
|
|
3
4
|
export declare const getTruncatedText: (text: string, limit?: number) => {
|
|
@@ -5,3 +6,4 @@ export declare const getTruncatedText: (text: string, limit?: number) => {
|
|
|
5
6
|
fullValue: string;
|
|
6
7
|
isTruncated: boolean;
|
|
7
8
|
};
|
|
9
|
+
export declare const formatTextWithLineBreaks: (content: ReactNode | string) => ReactNode;
|