@juspay/blend-design-system 0.0.33 → 0.0.34-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.
Files changed (61) hide show
  1. package/dist/components/AlertV2/AlertV2.d.ts +19 -0
  2. package/dist/components/AlertV2/alertV2.dark.tokens.d.ts +3 -0
  3. package/dist/components/AlertV2/alertV2.light.tokens.d.ts +3 -0
  4. package/dist/components/AlertV2/alertV2.tokens.d.ts +87 -0
  5. package/dist/components/AlertV2/alertV2.types.d.ts +54 -0
  6. package/dist/components/AlertV2/index.d.ts +3 -0
  7. package/dist/components/ButtonV2/utils.d.ts +46 -0
  8. package/dist/components/Drawer/components/DrawerBase.d.ts +1 -0
  9. package/dist/components/MultiSelect/MultiSelect.d.ts +1 -1
  10. package/dist/components/MultiSelect/types.d.ts +1 -0
  11. package/dist/components/MultiSelect/utils.d.ts +7 -1
  12. package/dist/components/MultiSelectGroup/MultiSelectGroup.d.ts +3 -0
  13. package/dist/components/MultiSelectGroup/MultiselectGroupProps.types.d.ts +7 -0
  14. package/dist/components/MultiSelectGroup/index.d.ts +3 -0
  15. package/dist/components/Primitives/Block/Block.d.ts +17 -3
  16. package/dist/components/Primitives/PrimitiveButton/PrimitiveButton.d.ts +20 -4
  17. package/dist/components/SelectorsContent/SelectorsContent.types.d.ts +45 -0
  18. package/dist/components/SelectorsContent/SelectorsLabel.d.ts +3 -0
  19. package/dist/components/SelectorsContent/SelectorsSubLabel.d.ts +6 -0
  20. package/dist/components/SelectorsContent/index.d.ts +3 -0
  21. package/dist/components/Sidebar/SidebarContent.d.ts +24 -0
  22. package/dist/components/Sidebar/SidebarFooter.d.ts +1 -0
  23. package/dist/components/Sidebar/SidebarHeader.d.ts +1 -0
  24. package/dist/components/Sidebar/TenantPanel.d.ts +1 -1
  25. package/dist/components/Sidebar/types.d.ts +1 -72
  26. package/dist/components/Sidebar/utils.d.ts +1 -7
  27. package/dist/components/SingleSelect/SingleSelect.d.ts +1 -1
  28. package/dist/components/SingleSelect/types.d.ts +1 -0
  29. package/dist/components/SingleSelect/utils.d.ts +6 -4
  30. package/dist/components/SingleSelectGroup/SingleSelectGroup.d.ts +3 -0
  31. package/dist/components/SingleSelectGroup/SingleSelectGroupProps.types.d.ts +7 -0
  32. package/dist/components/SingleSelectGroup/index.d.ts +3 -0
  33. package/dist/components/SnackbarV2/SnackbarV2.d.ts +6 -0
  34. package/dist/components/SnackbarV2/index.d.ts +4 -0
  35. package/dist/components/SnackbarV2/snackbarV2.dark.tokens.d.ts +3 -0
  36. package/dist/components/SnackbarV2/snackbarV2.light.tokens.d.ts +3 -0
  37. package/dist/components/SnackbarV2/snackbarV2.tokens.d.ts +73 -0
  38. package/dist/components/SnackbarV2/snackbarV2.types.d.ts +56 -0
  39. package/dist/components/Switch/switch.token.d.ts +0 -1
  40. package/dist/components/SwitchV2/SwitchV2.d.ts +19 -0
  41. package/dist/components/SwitchV2/index.d.ts +3 -0
  42. package/dist/components/SwitchV2/switchV2.dark.tokens.d.ts +3 -0
  43. package/dist/components/SwitchV2/switchV2.light.tokens.d.ts +3 -0
  44. package/dist/components/SwitchV2/switchV2.tokens.d.ts +76 -0
  45. package/dist/components/SwitchV2/switchV2.types.d.ts +53 -0
  46. package/dist/components/TagV2/TagV2.d.ts +4 -4
  47. package/dist/components/TagV2/TagV2.types.d.ts +11 -5
  48. package/dist/components/TagV2/tagV2.tokens.d.ts +2 -3
  49. package/dist/components/Tags/tag.dark.tokens.d.ts +3 -0
  50. package/dist/components/Tags/tag.light.tokens.d.ts +3 -0
  51. package/dist/components/Upload/utils.d.ts +3 -10
  52. package/dist/components/common/Seperator.d.ts +8 -0
  53. package/dist/context/ThemeContext.d.ts +8 -2
  54. package/dist/context/useComponentToken.d.ts +4 -1
  55. package/dist/global-utils/GlobalUtils.d.ts +2 -1
  56. package/dist/hooks/index.d.ts +1 -0
  57. package/dist/hooks/usePreventParentScroll.d.ts +3 -0
  58. package/dist/main.js +28763 -27270
  59. package/dist/tokens/font.tokens.d.ts +2 -0
  60. package/dist/tokens/unit.tokens.d.ts +1 -0
  61. package/package.json +1 -1
@@ -113,4 +113,5 @@ export type SingleSelectProps = {
113
113
  minTriggerWidth?: number;
114
114
  allowCustomValue?: boolean;
115
115
  customValueLabel?: string;
116
+ singleSelectGroupPosition?: 'center' | 'left' | 'right';
116
117
  };
@@ -1,7 +1,5 @@
1
- /**
2
- * Utility functions for SingleSelect component accessibility
3
- * WCAG 4.1.2 (Name, Role, Value), 3.3.2 (Labels or Instructions), 4.1.3 (Status Messages)
4
- */
1
+ import { SingleSelectTokensType } from './singleSelect.tokens';
2
+ import { SelectMenuSize, SelectMenuVariant } from './types';
5
3
  export type AriaAttributes = {
6
4
  'aria-describedby'?: string;
7
5
  'aria-label'?: string;
@@ -15,6 +13,10 @@ export type ExtractedAriaProps = {
15
13
  'aria-labelledby'?: string;
16
14
  restProps: Record<string, unknown>;
17
15
  };
16
+ export declare function getBorderRadius(size: SelectMenuSize, varient: SelectMenuVariant, singleSelectGroupPosition: 'center' | 'left' | 'right' | undefined, tokens: SingleSelectTokensType): {
17
+ borderRadius: string;
18
+ borderRight?: string;
19
+ };
18
20
  export type AccessibilitySetupOptions = {
19
21
  name?: string;
20
22
  generatedId: string;
@@ -0,0 +1,3 @@
1
+ import { SingleSelectGroupProps } from './SingleSelectGroupProps.types';
2
+ declare const SingleSelectGroup: import('react').ForwardRefExoticComponent<SingleSelectGroupProps & import('react').RefAttributes<HTMLDivElement>>;
3
+ export default SingleSelectGroup;
@@ -0,0 +1,7 @@
1
+ import { ReactElement } from 'react';
2
+ import { SingleSelectProps } from '../SingleSelect/types';
3
+ export type SingleSelectGroupProps = {
4
+ stacked?: boolean;
5
+ gap?: string | number;
6
+ children: ReactElement<SingleSelectProps> | ReactElement<SingleSelectProps>[];
7
+ };
@@ -0,0 +1,3 @@
1
+ import { default as SingleSelectGroup } from './SingleSelectGroup';
2
+ export { SingleSelectGroup };
3
+ export type * from './SingleSelectGroupProps.types';
@@ -0,0 +1,6 @@
1
+ import { default as React } from 'react';
2
+ import { SnackbarV2ToastOptions, SnackbarV2ToastProps, SnackbarV2Props } from './snackbarV2.types';
3
+ export declare const StyledToast: React.FC<SnackbarV2ToastProps>;
4
+ export declare const addSnackbarV2: ({ header, description, variant, slot, onClose, actionButton, duration, position, width, maxWidth, minWidth, }: SnackbarV2ToastOptions) => string | number;
5
+ declare const SnackbarV2: React.ForwardRefExoticComponent<SnackbarV2Props & React.RefAttributes<HTMLDivElement>>;
6
+ export default SnackbarV2;
@@ -0,0 +1,4 @@
1
+ export { default as SnackbarV2 } from './SnackbarV2';
2
+ export { addSnackbarV2, StyledToast } from './SnackbarV2';
3
+ export * from './snackbarV2.tokens';
4
+ export * from './snackbarV2.types';
@@ -0,0 +1,3 @@
1
+ import { FoundationTokenType } from '../../tokens/theme.token';
2
+ import { ResponsiveSnackbarV2Tokens } from './snackbarV2.tokens';
3
+ export declare const getSnackbarV2DarkTokens: (foundationToken: FoundationTokenType) => ResponsiveSnackbarV2Tokens;
@@ -0,0 +1,3 @@
1
+ import { FoundationTokenType } from '../../tokens/theme.token';
2
+ import { ResponsiveSnackbarV2Tokens } from './snackbarV2.tokens';
3
+ export declare const getSnackbarV2LightTokens: (foundationToken: FoundationTokenType) => ResponsiveSnackbarV2Tokens;
@@ -0,0 +1,73 @@
1
+ import { CSSObject } from 'styled-components';
2
+ import { SnackbarV2Variant } from './snackbarV2.types';
3
+ import { FoundationTokenType } from '../../tokens/theme.token';
4
+ import { BreakpointType } from '../../breakpoints/breakPoints';
5
+ import { Theme } from '../../context/theme.enum';
6
+ export declare enum SnackbarV2PaddingDirection {
7
+ TOP = "top",
8
+ BOTTOM = "bottom",
9
+ LEFT = "left",
10
+ RIGHT = "right"
11
+ }
12
+ export type SnackbarV2TokensType = {
13
+ width: CSSObject['width'];
14
+ maxWidth: CSSObject['maxWidth'];
15
+ minWidth: CSSObject['minWidth'];
16
+ backgroundColor: CSSObject['backgroundColor'];
17
+ borderRadius: CSSObject['borderRadius'];
18
+ padding: CSSObject['padding'];
19
+ boxShadow: CSSObject['boxShadow'];
20
+ gap: CSSObject['gap'];
21
+ slot: {
22
+ height: CSSObject['height'];
23
+ width: CSSObject['width'];
24
+ color: {
25
+ [key in SnackbarV2Variant]: CSSObject['color'];
26
+ };
27
+ };
28
+ mainContainer: {
29
+ gap: CSSObject['gap'];
30
+ content: {
31
+ gap: CSSObject['gap'];
32
+ textContainer: {
33
+ gap: CSSObject['gap'];
34
+ header: {
35
+ color: {
36
+ [key in SnackbarV2Variant]: CSSObject['color'];
37
+ };
38
+ fontSize: CSSObject['fontSize'];
39
+ fontWeight: CSSObject['fontWeight'];
40
+ lineHeight: CSSObject['lineHeight'];
41
+ };
42
+ description: {
43
+ color: {
44
+ [key in SnackbarV2Variant]: CSSObject['color'];
45
+ };
46
+ fontSize: CSSObject['fontSize'];
47
+ fontWeight: CSSObject['fontWeight'];
48
+ lineHeight: CSSObject['lineHeight'];
49
+ };
50
+ };
51
+ actionContainer: {
52
+ primaryAction: {
53
+ color: {
54
+ [key in SnackbarV2Variant]: CSSObject['color'];
55
+ };
56
+ fontSize: CSSObject['fontSize'];
57
+ fontWeight: CSSObject['fontWeight'];
58
+ lineHeight: CSSObject['lineHeight'];
59
+ };
60
+ };
61
+ };
62
+ closeButton: {
63
+ height: CSSObject['height'];
64
+ color: {
65
+ [key in SnackbarV2Variant]: CSSObject['color'];
66
+ };
67
+ };
68
+ };
69
+ };
70
+ export type ResponsiveSnackbarV2Tokens = {
71
+ [key in keyof BreakpointType]: SnackbarV2TokensType;
72
+ };
73
+ export declare const getSnackbarV2Tokens: (foundationToken: FoundationTokenType, theme?: Theme | string) => ResponsiveSnackbarV2Tokens;
@@ -0,0 +1,56 @@
1
+ import { default as React, ReactElement } from 'react';
2
+ import { CSSObject } from 'styled-components';
3
+ export declare enum SnackbarV2Variant {
4
+ INFO = "info",
5
+ SUCCESS = "success",
6
+ WARNING = "warning",
7
+ ERROR = "error"
8
+ }
9
+ export declare enum SnackbarV2Position {
10
+ TOP_LEFT = "top-left",
11
+ TOP_RIGHT = "top-right",
12
+ BOTTOM_LEFT = "bottom-left",
13
+ BOTTOM_RIGHT = "bottom-right",
14
+ TOP_CENTER = "top-center",
15
+ BOTTOM_CENTER = "bottom-center"
16
+ }
17
+ export type SnackbarV2Action = {
18
+ label: string;
19
+ onClick: () => void;
20
+ autoDismiss?: boolean;
21
+ };
22
+ export type SnackbarV2Dimensions = {
23
+ width?: CSSObject['width'];
24
+ maxWidth?: CSSObject['maxWidth'];
25
+ minWidth?: CSSObject['minWidth'];
26
+ };
27
+ export type SnackbarV2ToastOptions = {
28
+ header: string;
29
+ description?: string;
30
+ variant?: SnackbarV2Variant;
31
+ slot?: ReactElement;
32
+ onClose?: () => void;
33
+ actionButton?: SnackbarV2Action;
34
+ duration?: number;
35
+ position?: SnackbarV2Position;
36
+ maxWidth?: string | number;
37
+ width?: string | number;
38
+ minWidth?: string | number;
39
+ };
40
+ export type SnackbarV2Props = {
41
+ position?: SnackbarV2Position;
42
+ dismissOnClickAway?: boolean;
43
+ maxWidth?: string | number;
44
+ };
45
+ export type SnackbarV2ToastProps = {
46
+ header: string;
47
+ description?: string;
48
+ variant: SnackbarV2Variant;
49
+ slot?: ReactElement;
50
+ onClose?: () => void;
51
+ actionButton?: SnackbarV2Action;
52
+ toastId?: string | number;
53
+ } & Omit<React.HTMLAttributes<HTMLDivElement>, 'slot' | 'className' | 'style'> & SnackbarV2Dimensions;
54
+ export type SnackbarV2IconProps = {
55
+ variant: SnackbarV2Variant;
56
+ };
@@ -31,7 +31,6 @@ export type SwitchTokensType = {
31
31
  };
32
32
  };
33
33
  thumb: {
34
- marginTop: CSSObject['marginTop'];
35
34
  backgroundColor: CSSObject['backgroundColor'];
36
35
  border: {
37
36
  color: CSSObject['borderColor'];
@@ -0,0 +1,19 @@
1
+ import { SwitchV2Size } from './switchV2.types';
2
+ declare const SwitchV2: import('react').ForwardRefExoticComponent<{
3
+ checked?: boolean;
4
+ onChange?: (checked: boolean) => void;
5
+ required?: boolean;
6
+ error?: boolean;
7
+ label?: string;
8
+ subLabel?: string;
9
+ size?: SwitchV2Size;
10
+ slot?: {
11
+ slot: import('react').ReactElement;
12
+ maxHeight?: import('styled-components').CSSObject["maxHeight"];
13
+ };
14
+ maxLength?: {
15
+ label?: number;
16
+ subLabel?: number;
17
+ };
18
+ } & Omit<import('react').ButtonHTMLAttributes<HTMLButtonElement>, "style" | "className" | "slot" | "onChange"> & import('react').RefAttributes<HTMLButtonElement>>;
19
+ export default SwitchV2;
@@ -0,0 +1,3 @@
1
+ export { default as SwitchV2 } from './SwitchV2';
2
+ export * from './switchV2.types';
3
+ export * from './switchV2.tokens';
@@ -0,0 +1,3 @@
1
+ import { FoundationTokenType } from '../../tokens/theme.token';
2
+ import { ResponsiveSwitchV2Tokens } from './switchV2.tokens';
3
+ export declare const getSwitchV2DarkTokens: (foundationToken: FoundationTokenType) => ResponsiveSwitchV2Tokens;
@@ -0,0 +1,3 @@
1
+ import { FoundationTokenType } from '../../tokens/theme.token';
2
+ import { ResponsiveSwitchV2Tokens } from './switchV2.tokens';
3
+ export declare const getSwitchV2LightTokens: (foundationToken: FoundationTokenType) => ResponsiveSwitchV2Tokens;
@@ -0,0 +1,76 @@
1
+ import { Theme } from '../../context/theme.enum';
2
+ import { CSSObject } from 'styled-components';
3
+ import { SwitchV2Size, SwitchV2State, SwitchV2Variant } from './switchV2.types';
4
+ import { BreakpointType } from '../../breakpoints/breakPoints';
5
+ import { FoundationTokenType } from '../../tokens/theme.token';
6
+ export type SwitchV2TokensType = {
7
+ gap: CSSObject['gap'];
8
+ switch: {
9
+ height: {
10
+ [key in SwitchV2Size]: CSSObject['height'];
11
+ };
12
+ width: {
13
+ [key in SwitchV2Size]: CSSObject['width'];
14
+ };
15
+ backgroundColor: {
16
+ [key in SwitchV2Variant]: {
17
+ [key in SwitchV2State]: CSSObject['backgroundColor'];
18
+ };
19
+ };
20
+ thumb: {
21
+ backgroundColor: CSSObject['backgroundColor'];
22
+ border: CSSObject['border'];
23
+ width: {
24
+ [key in SwitchV2Size]: CSSObject['width'];
25
+ };
26
+ height: {
27
+ [key in SwitchV2Size]: CSSObject['height'];
28
+ };
29
+ outline: CSSObject['outline'];
30
+ };
31
+ };
32
+ content: {
33
+ gap: CSSObject['gap'];
34
+ label: {
35
+ gap: CSSObject['gap'];
36
+ color: {
37
+ [key in SwitchV2State]: CSSObject['color'];
38
+ };
39
+ fontSize: {
40
+ [key in SwitchV2Size]: CSSObject['fontSize'];
41
+ };
42
+ fontWeight: {
43
+ [key in SwitchV2Size]: CSSObject['fontWeight'];
44
+ };
45
+ lineHeight: {
46
+ [key in SwitchV2Size]: CSSObject['lineHeight'];
47
+ };
48
+ slot: {
49
+ maxHeight: {
50
+ [key in SwitchV2Size]: CSSObject['maxHeight'];
51
+ };
52
+ };
53
+ };
54
+ subLabel: {
55
+ color: {
56
+ [key in SwitchV2State]: CSSObject['color'];
57
+ };
58
+ fontSize: {
59
+ [key in SwitchV2Size]: CSSObject['fontSize'];
60
+ };
61
+ fontWeight: {
62
+ [key in SwitchV2Size]: CSSObject['fontWeight'];
63
+ };
64
+ lineHeight: {
65
+ [key in SwitchV2Size]: CSSObject['lineHeight'];
66
+ };
67
+ };
68
+ required: {
69
+ color: CSSObject['color'];
70
+ };
71
+ };
72
+ };
73
+ export type ResponsiveSwitchV2Tokens = {
74
+ [key in keyof BreakpointType]: SwitchV2TokensType;
75
+ };
76
+ export declare const getSwitchV2Tokens: (foundationToken: FoundationTokenType, theme?: Theme | string) => ResponsiveSwitchV2Tokens;
@@ -0,0 +1,53 @@
1
+ import { ButtonHTMLAttributes, ReactElement } from 'react';
2
+ import { SwitchV2TokensType } from './switchV2.tokens';
3
+ import { CSSObject } from 'styled-components';
4
+ export declare enum SwitchV2Size {
5
+ SM = "sm",
6
+ MD = "md"
7
+ }
8
+ export type SwitchV2State = 'default' | 'hover' | 'disabled' | 'error';
9
+ export type SwitchV2Variant = 'checked' | 'unchecked';
10
+ export type SwitchV2ButtonProps = {
11
+ id: string;
12
+ checked?: boolean;
13
+ disabled: boolean;
14
+ size: SwitchV2Size;
15
+ tokens: SwitchV2TokensType;
16
+ onToggle: () => void;
17
+ buttonProps?: Record<string, unknown>;
18
+ ref?: React.Ref<HTMLButtonElement>;
19
+ };
20
+ export type SwitchV2ContentProps = {
21
+ uniqueId: string;
22
+ disabled: boolean;
23
+ error: boolean;
24
+ required: boolean;
25
+ size: SwitchV2Size;
26
+ label?: string;
27
+ subLabel?: string;
28
+ slot?: {
29
+ slot: ReactElement;
30
+ maxHeight?: CSSObject['maxHeight'];
31
+ };
32
+ tokens: SwitchV2TokensType;
33
+ labelMaxLength?: number;
34
+ subLabelMaxLength?: number;
35
+ subLabelId?: string;
36
+ };
37
+ export type SwitchV2Props = {
38
+ checked?: boolean;
39
+ onChange?: (checked: boolean) => void;
40
+ required?: boolean;
41
+ error?: boolean;
42
+ label?: string;
43
+ subLabel?: string;
44
+ size?: SwitchV2Size;
45
+ slot?: {
46
+ slot: ReactElement;
47
+ maxHeight?: CSSObject['maxHeight'];
48
+ };
49
+ maxLength?: {
50
+ label?: number;
51
+ subLabel?: number;
52
+ };
53
+ } & Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'className' | 'style' | 'slot' | 'onChange'>;
@@ -6,12 +6,12 @@ declare const TagV2: import('react').ForwardRefExoticComponent<{
6
6
  subType?: TagV2SubType;
7
7
  color?: TagV2Color;
8
8
  leftSlot?: {
9
- slot: import('react').ReactNode;
10
- maxHeight: import('styled-components').CSSObject["maxHeight"];
9
+ slot: import('react').ReactElement;
10
+ maxHeight?: import('styled-components').CSSObject["maxHeight"];
11
11
  };
12
12
  rightSlot?: {
13
- slot: import('react').ReactNode;
14
- maxHeight: import('styled-components').CSSObject["maxHeight"];
13
+ slot: import('react').ReactElement;
14
+ maxHeight?: import('styled-components').CSSObject["maxHeight"];
15
15
  };
16
16
  skeleton?: {
17
17
  showSkeleton?: boolean;
@@ -1,6 +1,12 @@
1
- import { ReactNode } from 'react';
1
+ import { ReactElement } from 'react';
2
2
  import { SkeletonVariant } from '../Skeleton/skeleton.tokens';
3
3
  import { CSSObject } from 'styled-components';
4
+ export declare enum TagV2PaddingDirection {
5
+ TOP = "top",
6
+ BOTTOM = "bottom",
7
+ LEFT = "left",
8
+ RIGHT = "right"
9
+ }
4
10
  export declare enum TagV2Type {
5
11
  NO_FILL = "noFill",
6
12
  ATTENTIVE = "attentive",
@@ -31,12 +37,12 @@ export type TagV2Props = {
31
37
  subType?: TagV2SubType;
32
38
  color?: TagV2Color;
33
39
  leftSlot?: {
34
- slot: ReactNode;
35
- maxHeight: CSSObject['maxHeight'];
40
+ slot: ReactElement;
41
+ maxHeight?: CSSObject['maxHeight'];
36
42
  };
37
43
  rightSlot?: {
38
- slot: ReactNode;
39
- maxHeight: CSSObject['maxHeight'];
44
+ slot: ReactElement;
45
+ maxHeight?: CSSObject['maxHeight'];
40
46
  };
41
47
  skeleton?: {
42
48
  showSkeleton?: boolean;
@@ -1,9 +1,8 @@
1
1
  import { CSSObject } from 'styled-components';
2
- import { TagV2Color, TagV2Size, TagV2Type, TagV2SubType } from './TagV2.types';
2
+ import { TagV2Color, TagV2Size, TagV2Type, TagV2SubType, TagV2PaddingDirection } from './TagV2.types';
3
3
  import { BreakpointType } from '../../breakpoints/breakPoints';
4
4
  import { FoundationTokenType } from '../../tokens/theme.token';
5
5
  import { Theme } from '../../context/theme.enum';
6
- import { PaddingDirection } from '../ButtonV2';
7
6
  export type TagV2TokensType = Readonly<{
8
7
  border: {
9
8
  [key in TagV2Type]: {
@@ -24,7 +23,7 @@ export type TagV2TokensType = Readonly<{
24
23
  [key in TagV2Size]: CSSObject['height'];
25
24
  };
26
25
  padding: {
27
- [key in PaddingDirection]: {
26
+ [key in TagV2PaddingDirection]: {
28
27
  [key in TagV2Size]: CSSObject['padding'];
29
28
  };
30
29
  };
@@ -0,0 +1,3 @@
1
+ import { FoundationTokenType } from '../../tokens/theme.token';
2
+ import { ResponsiveTagTokens } from './tag.tokens';
3
+ export declare const getTagDarkTokens: (foundationToken: FoundationTokenType) => ResponsiveTagTokens;
@@ -0,0 +1,3 @@
1
+ import { FoundationTokenType } from '../../tokens/theme.token';
2
+ import { ResponsiveTagTokens } from './tag.tokens';
3
+ export declare const getTagLightTokens: (foundationToken: FoundationTokenType) => ResponsiveTagTokens;
@@ -72,16 +72,8 @@ export declare const getUploadStateDescription: (state: UploadState, multiple: b
72
72
  status: string;
73
73
  }[], userDescription?: string, fileName?: string) => string;
74
74
  export declare const getVisualUploadState: (disabled: boolean, isDragReject: boolean, isDragAccept: boolean, isDragActive: boolean, state: UploadState) => string;
75
- export declare const truncateFileList: (files: {
76
- id: string;
77
- file: File;
78
- status: string;
79
- }[]) => {
80
- displayFiles: {
81
- id: string;
82
- file: File;
83
- status: string;
84
- }[];
75
+ export declare const truncateFileList: (files: UploadedFileWithStatus[]) => {
76
+ displayFiles: UploadedFileWithStatus[];
85
77
  truncatedCount: number;
86
78
  };
87
79
  export declare const createEnhancedValidator: (accept: string[], maxSize?: number, validator?: (file: File) => FileRejection["errors"][0] | null) => (file: File) => FileRejection["errors"];
@@ -112,3 +104,4 @@ export declare const createUploadManager: () => {
112
104
  export declare const createComplexDropHandler: (multiple: boolean, maxFiles: number | undefined, disabled: boolean, uploadingFiles: UploadFile[], uploadedFiles: UploadedFileWithStatus[], failedFiles: UploadedFileWithStatus[], setInternalState: (state: UploadState) => void, setInternalUploadingFiles: React.Dispatch<React.SetStateAction<UploadFile[]>>, setInternalUploadedFiles: React.Dispatch<React.SetStateAction<UploadedFileWithStatus[]>>, setInternalFailedFiles: React.Dispatch<React.SetStateAction<UploadedFileWithStatus[]>>, uploadManager: ReturnType<typeof createUploadManager>, progressSpeed?: number) => (acceptedFiles: File[], rejectedFiles: FileRejection[]) => void;
113
105
  export declare const createFileRemovalHandler: (setInternalUploadedFiles: React.Dispatch<React.SetStateAction<UploadedFileWithStatus[]>>, setInternalFailedFiles: React.Dispatch<React.SetStateAction<UploadedFileWithStatus[]>>, setInternalState: (state: UploadState) => void) => (fileId: string) => void;
114
106
  export declare const createFileReplacementHandler: (setInternalState: (state: UploadState) => void, setInternalUploadedFiles: React.Dispatch<React.SetStateAction<UploadedFileWithStatus[]>>, setInternalFailedFiles: React.Dispatch<React.SetStateAction<UploadedFileWithStatus[]>>) => () => void;
107
+ export declare const getMbfromKb: (bytes: number) => number;
@@ -0,0 +1,8 @@
1
+ type SeperatorProps = {
2
+ orientation?: 'horizontal' | 'vertical';
3
+ height?: string;
4
+ width?: string;
5
+ color?: string;
6
+ };
7
+ declare const Seperator: ({ height, width, color, }: SeperatorProps) => import("react/jsx-runtime").JSX.Element;
8
+ export default Seperator;
@@ -1,3 +1,5 @@
1
+ import { Theme } from './theme.enum';
2
+ import { ThemeType } from '../tokens';
1
3
  import { ResponsiveSearchInputTokens } from '../components/Inputs/SearchInput/searchInput.tokens';
2
4
  import { ResponsiveTagTokens } from '../components/Tags/tag.tokens';
3
5
  import { ResponsiveTextAreaTokens } from '../components/Inputs/TextArea/textarea.token';
@@ -38,14 +40,15 @@ import { ResponsiveSidebarTokens } from '../components/Sidebar/sidebar.tokens';
38
40
  import { ResponsiveDirectoryTokens } from '../components/Directory/directory.tokens';
39
41
  import { ResponsiveUploadTokens } from '../components/Upload/upload.tokens';
40
42
  import { ResponsiveCodeBlockTokens } from '../components/CodeBlock/codeBlock.token';
41
- import { ThemeType } from '../tokens';
42
43
  import { ResponsiveSkeletonTokens } from '../components/Skeleton/skeleton.tokens';
43
44
  import { BREAKPOINTS } from '../breakpoints/breakPoints';
44
45
  import { ResponsiveMobileNavigationTokens } from '../components/Sidebar/SidebarMobile/mobile.tokens';
45
46
  import { ResponsiveStepperTokens } from '../components/Stepper/stepper.tokens';
46
- import { Theme } from './theme.enum';
47
47
  import { ResponsiveChatInputTokensType } from '../components/ChatInput/chatInput.tokens';
48
48
  import { ResponsiveTagV2Tokens } from '../components/TagV2/tagV2.tokens';
49
+ import { ResponsiveAlertV2Tokens } from '../components/AlertV2/alertV2.tokens';
50
+ import { ResponsiveSnackbarV2Tokens } from '../components/SnackbarV2/snackbarV2.tokens';
51
+ import { ResponsiveSwitchV2Tokens } from '../components/SwitchV2/switchV2.tokens';
49
52
  export type ComponentTokenType = {
50
53
  TAGS?: ResponsiveTagTokens;
51
54
  SEARCH_INPUT?: ResponsiveSearchInputTokens;
@@ -92,6 +95,9 @@ export type ComponentTokenType = {
92
95
  CHAT_INPUT?: ResponsiveChatInputTokensType;
93
96
  BUTTONV2?: ResponsiveButtonV2Tokens;
94
97
  TAGV2?: ResponsiveTagV2Tokens;
98
+ ALERTV2?: ResponsiveAlertV2Tokens;
99
+ SNACKBARV2?: ResponsiveSnackbarV2Tokens;
100
+ SWITCHV2?: ResponsiveSwitchV2Tokens;
95
101
  };
96
102
  type ThemeContextType = {
97
103
  foundationTokens: ThemeType;
@@ -44,4 +44,7 @@ import { ResponsiveMobileNavigationTokens } from '../components/Sidebar/SidebarM
44
44
  import { ResponsiveDirectoryTokens } from '../components/Directory/directory.tokens';
45
45
  import { ResponsiveChatInputTokensType } from '../components/ChatInput/chatInput.tokens';
46
46
  import { ResponsiveTagV2Tokens } from '../components/TagV2/tagV2.tokens';
47
- export declare const useComponentToken: (component: keyof ComponentTokenType) => ResponsiveSearchInputTokens | ResponsiveTagTokens | ResponsiveTextAreaTokens | ResponsiveTextInputTokens | ResponsiveNumberInputTokens | ResponsiveAlertTokens | ResponsiveRadioTokens | ResponsiveOTPInputTokens | ResponsiveUnitInputTokens | ResponsiveMultiValueInputTokens | ResponsiveSwitchTokens | ResponsiveCheckboxTokens | ResponsiveTabsTokens | ResponsiveTooltipTokens | ResponsiveDropdownInputTokens | ResponsiveModalTokens | ResponsiveBreadcrumbTokens | ResponsivePopoverTokens | ResponsiveMenuTokensType | ResponsiveMultiSelectTokens | ResponsiveSingleSelectTokens | ResponsiveTableTokens | ResponsiveCalendarTokens | ResponsiveAccordionTokens | ResponsiveStatCardTokens | ResponsiveProgressBarTokens | ResponsiveDrawerTokens | ResponsiveChartTokens | ResponsiveSnackbarTokens | ResponsiveStepperTokens | ResponsiveKeyValuePairTokens | ResponsiveCardTokens | ResponsiveSkeletonTokens | ResponsiveTopbarTokens | ResponsiveAvatarTokens | ResponsiveAvatarGroupTokens | ResponsiveSidebarTokens | ResponsiveUploadTokens | ResponsiveCodeBlockTokens | ResponsiveMobileNavigationTokens | ResponsiveDirectoryTokens | ResponsiveChatInputTokensType | ResponsiveButtonTokens | ResponsiveButtonV2Tokens | ResponsiveChatInputTokensType | ResponsiveTagV2Tokens;
47
+ import { ResponsiveAlertV2Tokens } from '../components/AlertV2';
48
+ import { ResponsiveSnackbarV2Tokens } from '../components/SnackbarV2';
49
+ import { ResponsiveSwitchV2Tokens } from '../components/SwitchV2/switchV2.tokens';
50
+ export declare const useComponentToken: (component: keyof ComponentTokenType) => ResponsiveSearchInputTokens | ResponsiveTagTokens | ResponsiveTextAreaTokens | ResponsiveTextInputTokens | ResponsiveNumberInputTokens | ResponsiveAlertTokens | ResponsiveRadioTokens | ResponsiveOTPInputTokens | ResponsiveUnitInputTokens | ResponsiveMultiValueInputTokens | ResponsiveSwitchTokens | ResponsiveCheckboxTokens | ResponsiveTabsTokens | ResponsiveTooltipTokens | ResponsiveDropdownInputTokens | ResponsiveModalTokens | ResponsiveBreadcrumbTokens | ResponsivePopoverTokens | ResponsiveMenuTokensType | ResponsiveMultiSelectTokens | ResponsiveSingleSelectTokens | ResponsiveTableTokens | ResponsiveCalendarTokens | ResponsiveAccordionTokens | ResponsiveStatCardTokens | ResponsiveProgressBarTokens | ResponsiveDrawerTokens | ResponsiveChartTokens | ResponsiveSnackbarTokens | ResponsiveStepperTokens | ResponsiveKeyValuePairTokens | ResponsiveCardTokens | ResponsiveSkeletonTokens | ResponsiveTopbarTokens | ResponsiveAvatarTokens | ResponsiveAvatarGroupTokens | ResponsiveSidebarTokens | ResponsiveUploadTokens | ResponsiveCodeBlockTokens | ResponsiveMobileNavigationTokens | ResponsiveDirectoryTokens | ResponsiveChatInputTokensType | ResponsiveButtonTokens | ResponsiveButtonV2Tokens | ResponsiveChatInputTokensType | ResponsiveTagV2Tokens | ResponsiveAlertV2Tokens | ResponsiveSnackbarV2Tokens | ResponsiveSwitchV2Tokens;
@@ -1,4 +1,4 @@
1
- import { ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
2
2
  export declare const toPixels: (value: string | number | undefined) => number;
3
3
  export declare const capitalizeFirstLetter: (string: string) => string;
4
4
  export declare const getTruncatedText: (text: string, limit?: number) => {
@@ -8,3 +8,4 @@ export declare const getTruncatedText: (text: string, limit?: number) => {
8
8
  };
9
9
  export declare const formatTextWithLineBreaks: (content: ReactNode | string) => ReactNode;
10
10
  export declare const addPxToValue: (value?: number | string) => string;
11
+ export declare const flattenChildren: (children: React.ReactNode) => React.ReactElement<unknown>[];
@@ -1,2 +1,3 @@
1
1
  export { default as useClickOutside } from './useClickOutside';
2
2
  export { default as useScrollLock } from './useScrollLock';
3
+ export { default as usePreventParentScroll } from './usePreventParentScroll';
@@ -0,0 +1,3 @@
1
+ import { RefObject } from 'react';
2
+ declare const usePreventParentScroll: (isOpen: boolean, contentRef?: RefObject<HTMLElement | null>, selectors?: string[]) => void;
3
+ export default usePreventParentScroll;