@astral/ui 4.70.0 → 4.71.1

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 (159) hide show
  1. package/components/Accordion/styles.d.ts +1 -0
  2. package/components/Alert/styles.d.ts +2 -0
  3. package/components/AutoSaveIndicator/styles.d.ts +2 -0
  4. package/components/BottomDrawer/styles.d.ts +1 -0
  5. package/components/Chip/styles.d.ts +1 -0
  6. package/components/CodeField/styles.d.ts +1 -0
  7. package/components/CollapsibleTypography/CollapsibleTypography.d.ts +1 -0
  8. package/components/CollapsibleTypography/styles.d.ts +1 -0
  9. package/components/ConfirmAction/styles.d.ts +1 -0
  10. package/components/CopyTypography/styles.d.ts +1 -0
  11. package/components/CopyTypography/useLogic/useLogic.d.ts +1 -0
  12. package/components/DashboardSidebarPopover/styles.d.ts +1 -0
  13. package/components/DataGrid/Cell/Cell.js +5 -2
  14. package/components/DataGrid/Cell/constants.d.ts +1 -0
  15. package/components/DataGrid/Cell/constants.js +1 -0
  16. package/components/DataGrid/Cell/styles.d.ts +1 -0
  17. package/components/DataGrid/Cell/styles.js +4 -0
  18. package/components/DataGrid/Cell/useLogic/useLogic.d.ts +1 -0
  19. package/components/DataGrid/Cell/useLogic/useLogic.js +6 -2
  20. package/components/DataGrid/DataGrid.js +2 -2
  21. package/components/DataGrid/DataGridContext/DataGridContext.d.ts +1 -0
  22. package/components/DataGrid/DataGridContext/DataGridContext.js +1 -0
  23. package/components/DataGrid/DataGridContext/DataGridProvider/DataGridProvider.d.ts +2 -1
  24. package/components/DataGrid/DataGridContext/DataGridProvider/DataGridProvider.js +3 -1
  25. package/components/DataGrid/Row/styles.d.ts +1 -0
  26. package/components/DataGrid/types.d.ts +8 -0
  27. package/components/DataGridPagination/styles.d.ts +1 -0
  28. package/components/DataGridPaginationContainer/styles.d.ts +1 -0
  29. package/components/DatePicker/DateCalendar/DateCalendarHead/styles.d.ts +1 -0
  30. package/components/Description/Description.d.ts +4 -0
  31. package/components/Description/Description.js +5 -2
  32. package/components/Description/Value/Value.d.ts +1 -1
  33. package/components/Description/Value/styles.d.ts +2 -0
  34. package/components/Description/constants.d.ts +1 -0
  35. package/components/Description/constants.js +1 -0
  36. package/components/Description/styles.js +4 -0
  37. package/components/DescriptionList/DescriptionList.d.ts +1 -1
  38. package/components/DescriptionList/DescriptionList.js +4 -3
  39. package/components/DescriptionList/styles.d.ts +2 -1
  40. package/components/DescriptionList/types.d.ts +2 -2
  41. package/components/Fieldset/styles.d.ts +2 -0
  42. package/components/Filename/styles.d.ts +1 -0
  43. package/components/FlowButton/styles.d.ts +1 -0
  44. package/components/JsonViewer/NodeValue/styles.d.ts +3 -0
  45. package/components/LegacyNotification/NotificationTemplate/styles.d.ts +2 -0
  46. package/components/MenuGroup/styles.d.ts +1 -0
  47. package/components/MenuOrganization/OrganizationButton/styles.d.ts +1 -0
  48. package/components/MenuOrganization/OrganizationGroup/styles.d.ts +1 -0
  49. package/components/MenuOrganization/styles.d.ts +1 -0
  50. package/components/MinimalisticPagination/styles.d.ts +1 -0
  51. package/components/NavMenu/Item/ItemButton/styles.d.ts +1 -0
  52. package/components/NewStepper/Step/Description/styles.d.ts +1 -0
  53. package/components/NewStepper/Step/Label/styles.d.ts +2 -0
  54. package/components/NotFoundPage/styles.d.ts +2 -0
  55. package/components/Notification/NotificationTemplate/styles.d.ts +2 -0
  56. package/components/NotificationList/ListItem/styles.d.ts +1 -0
  57. package/components/OverflowTypography/OverflowTypography.d.ts +1 -0
  58. package/components/OverflowTypography/styles.d.ts +2 -0
  59. package/components/PageContent/PageContentHeader/Title/styles.d.ts +1 -0
  60. package/components/PageHeader/HeaderContent/Description/styles.d.ts +1 -0
  61. package/components/PageHeader/Title/styles.d.ts +1 -0
  62. package/components/Pagination/PaginationItem/styles.d.ts +1 -0
  63. package/components/PinButton/styles.d.ts +1 -0
  64. package/components/ProductSwitcher/Content/styles.d.ts +1 -0
  65. package/components/Tree/TreeItem/styles.d.ts +2 -0
  66. package/components/Typography/Typography.d.ts +1 -0
  67. package/components/Typography/Typography.js +13 -4
  68. package/components/Typography/constants.d.ts +1 -0
  69. package/components/Typography/constants.js +2 -1
  70. package/components/Typography/styles.js +4 -0
  71. package/components/Typography/types.d.ts +4 -0
  72. package/components/WelcomeScreen/styles.d.ts +2 -0
  73. package/components/fileUploading/FileInfo/styles.d.ts +1 -0
  74. package/components/fileUploading/restrictions/restrictFileType/restrictFileType.js +9 -6
  75. package/components/fileUploading/services/MimeTypeRegistry/MimeTypeRegistry.d.ts +8 -0
  76. package/components/fileUploading/services/MimeTypeRegistry/MimeTypeRegistry.js +35 -1
  77. package/components/placeholders/Placeholder/styles.d.ts +2 -0
  78. package/hook-form/EditableText/EditingForm/styles.d.ts +1 -0
  79. package/hook-form/EditableText/styles.d.ts +1 -0
  80. package/node/components/Accordion/styles.d.ts +1 -0
  81. package/node/components/Alert/styles.d.ts +2 -0
  82. package/node/components/AutoSaveIndicator/styles.d.ts +2 -0
  83. package/node/components/BottomDrawer/styles.d.ts +1 -0
  84. package/node/components/Chip/styles.d.ts +1 -0
  85. package/node/components/CodeField/styles.d.ts +1 -0
  86. package/node/components/CollapsibleTypography/CollapsibleTypography.d.ts +1 -0
  87. package/node/components/CollapsibleTypography/styles.d.ts +1 -0
  88. package/node/components/ConfirmAction/styles.d.ts +1 -0
  89. package/node/components/CopyTypography/styles.d.ts +1 -0
  90. package/node/components/CopyTypography/useLogic/useLogic.d.ts +1 -0
  91. package/node/components/DashboardSidebarPopover/styles.d.ts +1 -0
  92. package/node/components/DataGrid/Cell/Cell.js +5 -2
  93. package/node/components/DataGrid/Cell/constants.d.ts +1 -0
  94. package/node/components/DataGrid/Cell/constants.js +1 -0
  95. package/node/components/DataGrid/Cell/styles.d.ts +1 -0
  96. package/node/components/DataGrid/Cell/styles.js +4 -0
  97. package/node/components/DataGrid/Cell/useLogic/useLogic.d.ts +1 -0
  98. package/node/components/DataGrid/Cell/useLogic/useLogic.js +5 -1
  99. package/node/components/DataGrid/DataGrid.js +2 -2
  100. package/node/components/DataGrid/DataGridContext/DataGridContext.d.ts +1 -0
  101. package/node/components/DataGrid/DataGridContext/DataGridContext.js +1 -0
  102. package/node/components/DataGrid/DataGridContext/DataGridProvider/DataGridProvider.d.ts +2 -1
  103. package/node/components/DataGrid/DataGridContext/DataGridProvider/DataGridProvider.js +3 -1
  104. package/node/components/DataGrid/Row/styles.d.ts +1 -0
  105. package/node/components/DataGrid/types.d.ts +8 -0
  106. package/node/components/DataGridPagination/styles.d.ts +1 -0
  107. package/node/components/DataGridPaginationContainer/styles.d.ts +1 -0
  108. package/node/components/DatePicker/DateCalendar/DateCalendarHead/styles.d.ts +1 -0
  109. package/node/components/Description/Description.d.ts +4 -0
  110. package/node/components/Description/Description.js +5 -2
  111. package/node/components/Description/Value/Value.d.ts +1 -1
  112. package/node/components/Description/Value/styles.d.ts +2 -0
  113. package/node/components/Description/constants.d.ts +1 -0
  114. package/node/components/Description/constants.js +1 -0
  115. package/node/components/Description/styles.js +4 -0
  116. package/node/components/DescriptionList/DescriptionList.d.ts +1 -1
  117. package/node/components/DescriptionList/DescriptionList.js +4 -3
  118. package/node/components/DescriptionList/styles.d.ts +2 -1
  119. package/node/components/DescriptionList/types.d.ts +2 -2
  120. package/node/components/Fieldset/styles.d.ts +2 -0
  121. package/node/components/Filename/styles.d.ts +1 -0
  122. package/node/components/FlowButton/styles.d.ts +1 -0
  123. package/node/components/JsonViewer/NodeValue/styles.d.ts +3 -0
  124. package/node/components/LegacyNotification/NotificationTemplate/styles.d.ts +2 -0
  125. package/node/components/MenuGroup/styles.d.ts +1 -0
  126. package/node/components/MenuOrganization/OrganizationButton/styles.d.ts +1 -0
  127. package/node/components/MenuOrganization/OrganizationGroup/styles.d.ts +1 -0
  128. package/node/components/MenuOrganization/styles.d.ts +1 -0
  129. package/node/components/MinimalisticPagination/styles.d.ts +1 -0
  130. package/node/components/NavMenu/Item/ItemButton/styles.d.ts +1 -0
  131. package/node/components/NewStepper/Step/Description/styles.d.ts +1 -0
  132. package/node/components/NewStepper/Step/Label/styles.d.ts +2 -0
  133. package/node/components/NotFoundPage/styles.d.ts +2 -0
  134. package/node/components/Notification/NotificationTemplate/styles.d.ts +2 -0
  135. package/node/components/NotificationList/ListItem/styles.d.ts +1 -0
  136. package/node/components/OverflowTypography/OverflowTypography.d.ts +1 -0
  137. package/node/components/OverflowTypography/styles.d.ts +2 -0
  138. package/node/components/PageContent/PageContentHeader/Title/styles.d.ts +1 -0
  139. package/node/components/PageHeader/HeaderContent/Description/styles.d.ts +1 -0
  140. package/node/components/PageHeader/Title/styles.d.ts +1 -0
  141. package/node/components/Pagination/PaginationItem/styles.d.ts +1 -0
  142. package/node/components/PinButton/styles.d.ts +1 -0
  143. package/node/components/ProductSwitcher/Content/styles.d.ts +1 -0
  144. package/node/components/Tree/TreeItem/styles.d.ts +2 -0
  145. package/node/components/Typography/Typography.d.ts +1 -0
  146. package/node/components/Typography/Typography.js +13 -4
  147. package/node/components/Typography/constants.d.ts +1 -0
  148. package/node/components/Typography/constants.js +2 -1
  149. package/node/components/Typography/styles.js +4 -0
  150. package/node/components/Typography/types.d.ts +4 -0
  151. package/node/components/WelcomeScreen/styles.d.ts +2 -0
  152. package/node/components/fileUploading/FileInfo/styles.d.ts +1 -0
  153. package/node/components/fileUploading/restrictions/restrictFileType/restrictFileType.js +9 -6
  154. package/node/components/fileUploading/services/MimeTypeRegistry/MimeTypeRegistry.d.ts +8 -0
  155. package/node/components/fileUploading/services/MimeTypeRegistry/MimeTypeRegistry.js +35 -1
  156. package/node/components/placeholders/Placeholder/styles.d.ts +2 -0
  157. package/node/hook-form/EditableText/EditingForm/styles.d.ts +1 -0
  158. package/node/hook-form/EditableText/styles.d.ts +1 -0
  159. package/package.json +1 -1
@@ -6,6 +6,7 @@ export declare const PageItem: import("../styled").StyledComponent<import("../Ty
6
6
  component?: import("../Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  }, {}, {}>;
@@ -632,6 +632,7 @@ export declare const NavMenuItemButtonText: import("../../../styled").StyledComp
632
632
  component?: import("../../../Typography/types").ComponentProp | undefined;
633
633
  isUpperCase?: boolean | undefined;
634
634
  withoutCalt?: boolean | undefined;
635
+ isTabularNums?: boolean | undefined;
635
636
  } & import("react").HTMLAttributes<HTMLParagraphElement> & {
636
637
  children?: import("react").ReactNode;
637
638
  } & import("react").RefAttributes<HTMLElement> & {
@@ -6,6 +6,7 @@ export declare const StyledTypography: import("../../../styled").StyledComponent
6
6
  component?: import("../../../Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  }, {}, {}>;
@@ -10,6 +10,7 @@ export declare const MobileCompactLabel: import("../../../styled").StyledCompone
10
10
  component?: import("../../../Typography/types").ComponentProp | undefined;
11
11
  isUpperCase?: boolean | undefined;
12
12
  withoutCalt?: boolean | undefined;
13
+ isTabularNums?: boolean | undefined;
13
14
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
14
15
  theme?: import("@emotion/react").Theme | undefined;
15
16
  }, {}, {}>;
@@ -20,6 +21,7 @@ export declare const DesktopLabel: import("../../../styled").StyledComponent<imp
20
21
  component?: import("../../../Typography/types").ComponentProp | undefined;
21
22
  isUpperCase?: boolean | undefined;
22
23
  withoutCalt?: boolean | undefined;
24
+ isTabularNums?: boolean | undefined;
23
25
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
24
26
  theme?: import("@emotion/react").Theme | undefined;
25
27
  }, {}, {}>;
@@ -10,6 +10,7 @@ export declare const Header: import("../styled").StyledComponent<import("../Typo
10
10
  component?: import("../Typography/types").ComponentProp | undefined;
11
11
  isUpperCase?: boolean | undefined;
12
12
  withoutCalt?: boolean | undefined;
13
+ isTabularNums?: boolean | undefined;
13
14
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
14
15
  theme?: import("@emotion/react").Theme | undefined;
15
16
  }, {}, {}>;
@@ -20,6 +21,7 @@ export declare const Subheader: import("../styled").StyledComponent<import("../T
20
21
  component?: import("../Typography/types").ComponentProp | undefined;
21
22
  isUpperCase?: boolean | undefined;
22
23
  withoutCalt?: boolean | undefined;
24
+ isTabularNums?: boolean | undefined;
23
25
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
24
26
  theme?: import("@emotion/react").Theme | undefined;
25
27
  }, {}, {}>;
@@ -21,6 +21,7 @@ export declare const Content: import("../../styled").StyledComponent<import("../
21
21
  component?: import("../../Typography/types").ComponentProp | undefined;
22
22
  isUpperCase?: boolean | undefined;
23
23
  withoutCalt?: boolean | undefined;
24
+ isTabularNums?: boolean | undefined;
24
25
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
25
26
  theme?: import("@emotion/react").Theme | undefined;
26
27
  }, {}, {}>;
@@ -49,6 +50,7 @@ export declare const Title: import("../../styled").StyledComponent<import("../..
49
50
  component?: import("../../Typography/types").ComponentProp | undefined;
50
51
  isUpperCase?: boolean | undefined;
51
52
  withoutCalt?: boolean | undefined;
53
+ isTabularNums?: boolean | undefined;
52
54
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
53
55
  theme?: import("@emotion/react").Theme | undefined;
54
56
  }, {}, {}>;
@@ -11,6 +11,7 @@ export declare const Title: import("../../styled").StyledComponent<import("../..
11
11
  component?: import("../../Typography/types").ComponentProp | undefined;
12
12
  isUpperCase?: boolean | undefined;
13
13
  withoutCalt?: boolean | undefined;
14
+ isTabularNums?: boolean | undefined;
14
15
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
15
16
  theme?: import("@emotion/react").Theme | undefined;
16
17
  }, {}, {}>;
@@ -344,6 +344,7 @@ export declare const OverflowTypography: import("react").ForwardRefExoticCompone
344
344
  component?: import("../Typography/types").ComponentProp | undefined;
345
345
  isUpperCase?: boolean | undefined;
346
346
  withoutCalt?: boolean | undefined;
347
+ isTabularNums?: boolean | undefined;
347
348
  } & import("react").HTMLAttributes<HTMLParagraphElement> & {
348
349
  children?: import("react").ReactNode;
349
350
  } & import("react").RefAttributes<HTMLElement>>;
@@ -10,6 +10,7 @@ export declare const StyledTypography: import("../styled").StyledComponent<impor
10
10
  component?: import("../Typography/types").ComponentProp | undefined;
11
11
  isUpperCase?: boolean | undefined;
12
12
  withoutCalt?: boolean | undefined;
13
+ isTabularNums?: boolean | undefined;
13
14
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
14
15
  theme?: import("@emotion/react").Theme | undefined;
15
16
  } & OverflowTypographyWrapperProps, {}, {}>;
@@ -20,6 +21,7 @@ export declare const Wrapper: import("../styled").StyledComponent<import("../Typ
20
21
  component?: import("../Typography/types").ComponentProp | undefined;
21
22
  isUpperCase?: boolean | undefined;
22
23
  withoutCalt?: boolean | undefined;
24
+ isTabularNums?: boolean | undefined;
23
25
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
24
26
  theme?: import("@emotion/react").Theme | undefined;
25
27
  } & {
@@ -6,6 +6,7 @@ export declare const TitleWrapper: import("../../../styled").StyledComponent<imp
6
6
  component?: import("../../../Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  }, {}, {}>;
@@ -6,6 +6,7 @@ export declare const StyledTypography: import("../../../styled").StyledComponent
6
6
  component?: import("../../../Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  }, {}, {}>;
@@ -6,6 +6,7 @@ export declare const TitleWrapper: import("../../styled").StyledComponent<import
6
6
  component?: import("../../Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  } & {
@@ -6,6 +6,7 @@ export declare const Ellipsis: import("../../styled").StyledComponent<import("..
6
6
  component?: import("../../Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  }, {}, {}>;
@@ -16,6 +16,7 @@ export declare const Content: import("../styled").StyledComponent<import("../Typ
16
16
  component?: import("../Typography/types").ComponentProp | undefined;
17
17
  isUpperCase?: boolean | undefined;
18
18
  withoutCalt?: boolean | undefined;
19
+ isTabularNums?: boolean | undefined;
19
20
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
20
21
  theme?: import("@emotion/react").Theme | undefined;
21
22
  }, {}, {}>;
@@ -20,6 +20,7 @@ export declare const ProductName: import("../../styled").StyledComponent<import(
20
20
  component?: import("../../Typography/types").ComponentProp | undefined;
21
21
  isUpperCase?: boolean | undefined;
22
22
  withoutCalt?: boolean | undefined;
23
+ isTabularNums?: boolean | undefined;
23
24
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
24
25
  theme?: import("@emotion/react").Theme | undefined;
25
26
  }, {}, {}>;
@@ -49,6 +49,7 @@ export declare const Label: import("../../styled").StyledComponent<import("../..
49
49
  component?: import("../../Typography/types").ComponentProp | undefined;
50
50
  isUpperCase?: boolean | undefined;
51
51
  withoutCalt?: boolean | undefined;
52
+ isTabularNums?: boolean | undefined;
52
53
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
53
54
  theme?: import("@emotion/react").Theme | undefined;
54
55
  }, {}, {}>;
@@ -395,6 +396,7 @@ export declare const Note: import("../../styled").StyledComponent<import("../../
395
396
  component?: import("../../Typography/types").ComponentProp | undefined;
396
397
  isUpperCase?: boolean | undefined;
397
398
  withoutCalt?: boolean | undefined;
399
+ isTabularNums?: boolean | undefined;
398
400
  } & import("react").HTMLAttributes<HTMLParagraphElement> & {
399
401
  children?: import("react").ReactNode;
400
402
  } & import("react").RefAttributes<HTMLElement> & {
@@ -13,4 +13,5 @@ export declare const Typography: import("react").ForwardRefExoticComponent<impor
13
13
  component?: ComponentProp | undefined;
14
14
  isUpperCase?: boolean | undefined;
15
15
  withoutCalt?: boolean | undefined;
16
+ isTabularNums?: boolean | undefined;
16
17
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement>>;
@@ -1,12 +1,21 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { forwardRef } from 'react';
3
3
  import { classNames } from '../utils/classNames';
4
+ import { cva } from '../utils/cva';
4
5
  import { typographyClassnames } from './constants';
5
6
  import { useTypographyColor } from './hooks';
6
7
  import { TypographyWrapper } from './styles';
7
- export const Typography = forwardRef(({ children, color, colorIntensity = '800', component, withoutCalt, className, ...props }, ref) => {
8
+ const typographyCva = cva(typographyClassnames.root, {
9
+ variants: {
10
+ isTabularNums: {
11
+ true: typographyClassnames.tabularNums,
12
+ },
13
+ withoutCalt: {
14
+ true: typographyClassnames.withoutCalt,
15
+ },
16
+ },
17
+ });
18
+ export const Typography = forwardRef(({ children, color, colorIntensity = '800', component, withoutCalt, className, isTabularNums, ...props }, ref) => {
8
19
  const typographyColor = useTypographyColor({ color, colorIntensity });
9
- return (_jsx(TypographyWrapper, { ref: ref, ...props, component: component, color: typographyColor, className: classNames(typographyClassnames.root, className, {
10
- [typographyClassnames.withoutCalt]: withoutCalt,
11
- }), children: children }));
20
+ return (_jsx(TypographyWrapper, { ref: ref, ...props, component: component, color: typographyColor, className: classNames(typographyCva({ isTabularNums, withoutCalt }), className), children: children }));
12
21
  });
@@ -1,4 +1,5 @@
1
1
  export declare const typographyClassnames: {
2
2
  root: string;
3
3
  withoutCalt: string;
4
+ tabularNums: string;
4
5
  };
@@ -1,5 +1,6 @@
1
1
  import { createUIKitClassname } from '../utils/createUIKitClassname';
2
2
  export const typographyClassnames = {
3
3
  root: createUIKitClassname('typography'),
4
- withoutCalt: 'typography_without-calt',
4
+ withoutCalt: createUIKitClassname('typography_without-calt'),
5
+ tabularNums: createUIKitClassname('typography_tabular-nums'),
5
6
  };
@@ -9,4 +9,8 @@ export const TypographyWrapper = styled(Typography, {
9
9
  .${typographyClassnames.withoutCalt} {
10
10
  font-feature-settings: "calt" 0;
11
11
  }
12
+
13
+ &.${typographyClassnames.tabularNums} {
14
+ font-feature-settings: "tnum" 1;
15
+ }
12
16
  `;
@@ -35,4 +35,8 @@ export type TypographyProps = TypographyPropsBase & {
35
35
  * Отключает контекстные альтернативы шрифта. Подробнее в [документации](https://ui-kit.astral.ru/?path=/docs/getting-started-fonts--docs)
36
36
  */
37
37
  withoutCalt?: boolean;
38
+ /**
39
+ * Включает моноширинные цифры.
40
+ */
41
+ isTabularNums?: boolean;
38
42
  } & HTMLAttributes<HTMLParagraphElement>;
@@ -22,6 +22,7 @@ export declare const Greeting: import("../styled").StyledComponent<import("../Ty
22
22
  component?: import("../Typography/types").ComponentProp | undefined;
23
23
  isUpperCase?: boolean | undefined;
24
24
  withoutCalt?: boolean | undefined;
25
+ isTabularNums?: boolean | undefined;
25
26
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
26
27
  theme?: import("@emotion/react").Theme | undefined;
27
28
  }, {}, {}>;
@@ -32,6 +33,7 @@ export declare const UserName: import("../styled").StyledComponent<import("../Ty
32
33
  component?: import("../Typography/types").ComponentProp | undefined;
33
34
  isUpperCase?: boolean | undefined;
34
35
  withoutCalt?: boolean | undefined;
36
+ isTabularNums?: boolean | undefined;
35
37
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
36
38
  theme?: import("@emotion/react").Theme | undefined;
37
39
  }, {}, {}>;
@@ -350,6 +350,7 @@ export declare const FileSize: import("../../styled").StyledComponent<import("..
350
350
  component?: import("../../Typography/types").ComponentProp | undefined;
351
351
  isUpperCase?: boolean | undefined;
352
352
  withoutCalt?: boolean | undefined;
353
+ isTabularNums?: boolean | undefined;
353
354
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
354
355
  theme?: import("@emotion/react").Theme | undefined;
355
356
  }, {}, {}>;
@@ -1,9 +1,14 @@
1
1
  import { MimeTypeRegistry } from '../../services/MimeTypeRegistry';
2
2
  import { FILE_TYPE_ERROR_INFO, INCONSISTENCY_EXTENSION_AND_MIME_TYPE_ERROR_INFO, } from './constants';
3
3
  import { getFileMeta } from './utils';
4
- const getAcceptMimeTypes = (acceptMeta) => acceptMeta.mimeTypes.concat(...acceptMeta.extensions
5
- .map((extension) => MimeTypeRegistry.getInstance().getMimeTypeByExtension(extension))
6
- .filter((value) => typeof value === 'string'));
4
+ const getAcceptMimeTypes = (acceptMeta) => {
5
+ return [
6
+ ...new Set([
7
+ ...acceptMeta.mimeTypes,
8
+ ...acceptMeta.extensions.flatMap((extension) => MimeTypeRegistry.getInstance().getMimeTypesByExtension(extension)),
9
+ ]),
10
+ ];
11
+ };
7
12
  const checkEmptyAccept = (acceptMeta) => !acceptMeta.extensions.length &&
8
13
  !acceptMeta.mimeTypes.length &&
9
14
  !acceptMeta.generalMimeTypes.length;
@@ -20,9 +25,7 @@ export const restrictFileType = (acceptMeta) => (file) => {
20
25
  }
21
26
  return undefined;
22
27
  }
23
- const isInconsistencyExtensionAndMimeType = !MimeTypeRegistry.getInstance()
24
- .getExtensionsByMimeType(fileMeta.mimeType)
25
- ?.includes(fileMeta.extension);
28
+ const isInconsistencyExtensionAndMimeType = !MimeTypeRegistry.getInstance().isExtensionValidForMimeType(fileMeta.mimeType, fileMeta.extension);
26
29
  if (isInconsistencyExtensionAndMimeType) {
27
30
  return INCONSISTENCY_EXTENSION_AND_MIME_TYPE_ERROR_INFO;
28
31
  }
@@ -5,5 +5,13 @@ export declare class MimeTypeRegistry {
5
5
  private constructor();
6
6
  getMimeTypeByExtension(extension: string): string | null;
7
7
  getExtensionsByMimeType(mimeType: string): string[] | null;
8
+ /**
9
+ * Проверяет, что расширение файла допустимо для указанного MIME-типа.
10
+ * Учитывает wildcard-расширения из mime-db (например, `*xml` для `text/xml`).
11
+ */
12
+ isExtensionValidForMimeType(mimeType: string, extension: string): boolean;
13
+ getMimeTypesByExtension(extension: string): string[];
14
+ private normalizeExtension;
15
+ private matchExtension;
8
16
  static getInstance(): MimeTypeRegistry;
9
17
  }
@@ -10,11 +10,45 @@ export class MimeTypeRegistry {
10
10
  }
11
11
  }
12
12
  getMimeTypeByExtension(extension) {
13
- return (this.extensionsMap.get(extension.toLowerCase().replace('.', '')) || null);
13
+ return this.extensionsMap.get(this.normalizeExtension(extension)) || null;
14
14
  }
15
15
  getExtensionsByMimeType(mimeType) {
16
16
  return this.mimeTypesMap[mimeType] || null;
17
17
  }
18
+ /**
19
+ * Проверяет, что расширение файла допустимо для указанного MIME-типа.
20
+ * Учитывает wildcard-расширения из mime-db (например, `*xml` для `text/xml`).
21
+ */
22
+ isExtensionValidForMimeType(mimeType, extension) {
23
+ const extensions = this.getExtensionsByMimeType(mimeType);
24
+ if (!extensions) {
25
+ return false;
26
+ }
27
+ return extensions.some((registeredExtension) => this.matchExtension(registeredExtension, extension));
28
+ }
29
+ getMimeTypesByExtension(extension) {
30
+ const normalizedExtension = this.normalizeExtension(extension);
31
+ const mimeTypes = [];
32
+ for (const [mimeType, extensions] of Object.entries(this.mimeTypesMap)) {
33
+ if (extensions.some((registeredExtension) => this.matchExtension(registeredExtension, normalizedExtension))) {
34
+ mimeTypes.push(mimeType);
35
+ }
36
+ }
37
+ return mimeTypes;
38
+ }
39
+ normalizeExtension(extension) {
40
+ return extension.toLowerCase().replace(/^\./, '');
41
+ }
42
+ matchExtension(registeredExtension, fileExtension) {
43
+ const normalizedFile = this.normalizeExtension(fileExtension);
44
+ const normalizedRegistered = registeredExtension.toLowerCase();
45
+ // Отдельная обработка для wildcard mime types, например xml === *xml
46
+ if (normalizedRegistered.startsWith('*')) {
47
+ const suffix = normalizedRegistered.slice(1);
48
+ return normalizedFile === suffix || normalizedFile.endsWith(suffix);
49
+ }
50
+ return normalizedRegistered === normalizedFile;
51
+ }
18
52
  static getInstance() {
19
53
  const instance = this.instanceRef?.deref();
20
54
  if (instance) {
@@ -18,6 +18,7 @@ export declare const Title: import("../../styled").StyledComponent<import("../..
18
18
  component?: import("../../Typography/types").ComponentProp | undefined;
19
19
  isUpperCase?: boolean | undefined;
20
20
  withoutCalt?: boolean | undefined;
21
+ isTabularNums?: boolean | undefined;
21
22
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
22
23
  theme?: import("@emotion/react").Theme | undefined;
23
24
  } & WithSize, {}, {}>;
@@ -28,6 +29,7 @@ export declare const Description: import("../../styled").StyledComponent<import(
28
29
  component?: import("../../Typography/types").ComponentProp | undefined;
29
30
  isUpperCase?: boolean | undefined;
30
31
  withoutCalt?: boolean | undefined;
32
+ isTabularNums?: boolean | undefined;
31
33
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
32
34
  theme?: import("@emotion/react").Theme | undefined;
33
35
  } & WithSize, {}, {}>;
@@ -10,6 +10,7 @@ export declare const Description: import("../../../components/styled").StyledCom
10
10
  component?: import("../../../components/Typography/types").ComponentProp | undefined;
11
11
  isUpperCase?: boolean | undefined;
12
12
  withoutCalt?: boolean | undefined;
13
+ isTabularNums?: boolean | undefined;
13
14
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
14
15
  theme?: import("@emotion/react").Theme | undefined;
15
16
  }, {}, {}>;
@@ -6,6 +6,7 @@ export declare const DisplayValue: import("../../components/styled").StyledCompo
6
6
  component?: import("../../components/Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  } & {
@@ -26,6 +26,7 @@ export declare const Summary: import("@emotion/styled/dist/declarations/src/type
26
26
  component?: import("../Typography/types").ComponentProp | undefined;
27
27
  isUpperCase?: boolean | undefined;
28
28
  withoutCalt?: boolean | undefined;
29
+ isTabularNums?: boolean | undefined;
29
30
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
30
31
  theme?: import("@emotion/react").Theme | undefined;
31
32
  }, {}, {}>;
@@ -31,6 +31,7 @@ export declare const StyledTypography: import("@emotion/styled/dist/declarations
31
31
  component?: import("../Typography/types").ComponentProp | undefined;
32
32
  isUpperCase?: boolean | undefined;
33
33
  withoutCalt?: boolean | undefined;
34
+ isTabularNums?: boolean | undefined;
34
35
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
35
36
  theme?: import("@emotion/react").Theme | undefined;
36
37
  }, {}, {}>;
@@ -41,6 +42,7 @@ export declare const Title: import("@emotion/styled/dist/declarations/src/types"
41
42
  component?: import("../Typography/types").ComponentProp | undefined;
42
43
  isUpperCase?: boolean | undefined;
43
44
  withoutCalt?: boolean | undefined;
45
+ isTabularNums?: boolean | undefined;
44
46
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
45
47
  theme?: import("@emotion/react").Theme | undefined;
46
48
  }, {}, {}>;
@@ -14,6 +14,7 @@ export declare const StyledTypography: import("@emotion/styled/dist/declarations
14
14
  component?: import("../Typography/types").ComponentProp | undefined;
15
15
  isUpperCase?: boolean | undefined;
16
16
  withoutCalt?: boolean | undefined;
17
+ isTabularNums?: boolean | undefined;
17
18
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
18
19
  theme?: import("@emotion/react").Theme | undefined;
19
20
  }, {}, {}>;
@@ -34,6 +35,7 @@ export declare const IndicatorTypography: import("@emotion/styled/dist/declarati
34
35
  component?: import("../Typography/types").ComponentProp | undefined;
35
36
  isUpperCase?: boolean | undefined;
36
37
  withoutCalt?: boolean | undefined;
38
+ isTabularNums?: boolean | undefined;
37
39
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
38
40
  theme?: import("@emotion/react").Theme | undefined;
39
41
  }, {}, {}>;
@@ -18,6 +18,7 @@ export declare const HeaderTitle: import("@emotion/styled/dist/declarations/src/
18
18
  component?: import("../Typography/types").ComponentProp | undefined;
19
19
  isUpperCase?: boolean | undefined;
20
20
  withoutCalt?: boolean | undefined;
21
+ isTabularNums?: boolean | undefined;
21
22
  } & import("react").HTMLAttributes<HTMLParagraphElement>, {}, {}>;
22
23
  export declare const Body: import("@emotion/styled/dist/declarations/src/types").StyledComponent<{
23
24
  theme?: import("@emotion/react").Theme | undefined;
@@ -22,6 +22,7 @@ export declare const AdornmentWrapper: import("@emotion/styled/dist/declarations
22
22
  component?: import("../Typography/types").ComponentProp | undefined;
23
23
  isUpperCase?: boolean | undefined;
24
24
  withoutCalt?: boolean | undefined;
25
+ isTabularNums?: boolean | undefined;
25
26
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
26
27
  theme?: import("@emotion/react").Theme | undefined;
27
28
  }, {}, {}>;
@@ -24,6 +24,7 @@ export declare const FieldLabel: import("@emotion/styled/dist/declarations/src/t
24
24
  component?: import("../Typography/types").ComponentProp | undefined;
25
25
  isUpperCase?: boolean | undefined;
26
26
  withoutCalt?: boolean | undefined;
27
+ isTabularNums?: boolean | undefined;
27
28
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
28
29
  theme?: import("@emotion/react").Theme | undefined;
29
30
  }, {}, {}>;
@@ -30,6 +30,7 @@ export declare const CollapsibleTypography: import("react").ForwardRefExoticComp
30
30
  component?: import("../Typography/types").ComponentProp | undefined;
31
31
  isUpperCase?: boolean | undefined;
32
32
  withoutCalt?: boolean | undefined;
33
+ isTabularNums?: boolean | undefined;
33
34
  } & import("react").HTMLAttributes<HTMLParagraphElement> & {
34
35
  children?: import("react").ReactNode;
35
36
  } & import("react").RefAttributes<HTMLElement>>;
@@ -15,6 +15,7 @@ export declare const Wrapper: import("@emotion/styled/dist/declarations/src/type
15
15
  component?: import("../Typography/types").ComponentProp | undefined;
16
16
  isUpperCase?: boolean | undefined;
17
17
  withoutCalt?: boolean | undefined;
18
+ isTabularNums?: boolean | undefined;
18
19
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
19
20
  theme?: import("@emotion/react").Theme | undefined;
20
21
  } & CollapsibleTypographyWrapperProps, {}, {}>;
@@ -10,6 +10,7 @@ export declare const StyledTypography: import("@emotion/styled/dist/declarations
10
10
  component?: import("../Typography/types").ComponentProp | undefined;
11
11
  isUpperCase?: boolean | undefined;
12
12
  withoutCalt?: boolean | undefined;
13
+ isTabularNums?: boolean | undefined;
13
14
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
14
15
  theme?: import("@emotion/react").Theme | undefined;
15
16
  }, {}, {}>;
@@ -6,6 +6,7 @@ export declare const Wrapper: import("@emotion/styled/dist/declarations/src/type
6
6
  component?: import("../Typography/types").ComponentProp | undefined;
7
7
  isUpperCase?: boolean | undefined;
8
8
  withoutCalt?: boolean | undefined;
9
+ isTabularNums?: boolean | undefined;
9
10
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
10
11
  theme?: import("@emotion/react").Theme | undefined;
11
12
  }, {}, {}>;
@@ -16,6 +16,7 @@ export declare const useLogic: ({ children, copyPosition, copyText, isShowCopyTe
16
16
  component?: import("../../Typography/types").ComponentProp | undefined;
17
17
  isUpperCase?: boolean | undefined;
18
18
  withoutCalt?: boolean | undefined;
19
+ isTabularNums?: boolean | undefined;
19
20
  defaultChecked?: boolean | undefined;
20
21
  defaultValue?: string | number | readonly string[] | undefined;
21
22
  suppressContentEditableWarning?: boolean | undefined;
@@ -10,6 +10,7 @@ export declare const Title: import("@emotion/styled/dist/declarations/src/types"
10
10
  component?: import("../Typography/types").ComponentProp | undefined;
11
11
  isUpperCase?: boolean | undefined;
12
12
  withoutCalt?: boolean | undefined;
13
+ isTabularNums?: boolean | undefined;
13
14
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
14
15
  theme?: import("@emotion/react").Theme | undefined;
15
16
  }, {}, {}>;
@@ -33,6 +33,9 @@ const cellContentCva = (0, cva_1.cva)(constants_1.dataGridCellClassnames.cellCon
33
33
  isActionColumn: {
34
34
  true: constants_1.dataGridCellClassnames.actionColumn,
35
35
  },
36
+ isTabularNums: {
37
+ true: constants_1.dataGridCellClassnames.tabularNums,
38
+ },
36
39
  },
37
40
  });
38
41
  const columnLabelCva = (0, cva_1.cva)(constants_1.dataGridCellClassnames.columnLabel, {
@@ -43,7 +46,7 @@ const columnLabelCva = (0, cva_1.cva)(constants_1.dataGridCellClassnames.columnL
43
46
  },
44
47
  });
45
48
  const Cell = (props) => {
46
- const { formattedValue, hasStartAdornment, isActionColumn, label, hideTitleOnMobile, } = (0, useLogic_1.useLogic)(props);
49
+ const { formattedValue, hasStartAdornment, isActionColumn, label, hideTitleOnMobile, isTabularNums, } = (0, useLogic_1.useLogic)(props);
47
50
  const { className, startAdornment, row, cell, isDisabled, isHidePersonalData, isHideOnMobile, } = props;
48
51
  const { renderCell, align = 'left' } = cell;
49
52
  const hidePersonalDataClassname = (0, personalDataSecurity_1.useHidePersonalData)({
@@ -54,7 +57,7 @@ const Cell = (props) => {
54
57
  isDisabled,
55
58
  withStartAdornment: hasStartAdornment,
56
59
  align,
57
- })), ...(0, getInertProps_1.getInertProps)(isDisabled), children: [startAdornment && startAdornment, (0, jsx_runtime_1.jsxs)(styles_1.CellContent, { className: cellContentCva({ isActionColumn }), children: [(0, jsx_runtime_1.jsx)(styles_1.ColumnLabel, { variant: "caption", color: "textSecondary", className: columnLabelCva({
60
+ })), ...(0, getInertProps_1.getInertProps)(isDisabled), children: [startAdornment && startAdornment, (0, jsx_runtime_1.jsxs)(styles_1.CellContent, { className: cellContentCva({ isActionColumn, isTabularNums }), children: [(0, jsx_runtime_1.jsx)(styles_1.ColumnLabel, { variant: "caption", color: "textSecondary", className: columnLabelCva({
58
61
  hidden: hideTitleOnMobile || isActionColumn,
59
62
  }), children: label }), renderCell?.(row), !renderCell && ((0, jsx_runtime_1.jsx)(OverflowTypography_1.OverflowTypography, { rowsCount: 2, tooltipProps: { className: hidePersonalDataClassname }, children: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: formattedValue }) }))] })] }));
60
63
  };
@@ -11,4 +11,5 @@ export declare const dataGridCellClassnames: {
11
11
  alignCenter: string;
12
12
  alignRight: string;
13
13
  grouped: string;
14
+ tabularNums: string;
14
15
  };
@@ -15,4 +15,5 @@ exports.dataGridCellClassnames = {
15
15
  alignCenter: (0, createUIKitClassname_1.createUIKitClassname)('data-grid__cell_align-center'),
16
16
  alignRight: (0, createUIKitClassname_1.createUIKitClassname)('data-grid__cell_align-right'),
17
17
  grouped: (0, createUIKitClassname_1.createUIKitClassname)('data-grid__cell_grouped'),
18
+ tabularNums: (0, createUIKitClassname_1.createUIKitClassname)('data-grid__cell_tabular-nums'),
18
19
  };
@@ -10,6 +10,7 @@ export declare const ColumnLabel: import("@emotion/styled/dist/declarations/src/
10
10
  component?: import("../../Typography/types").ComponentProp | undefined;
11
11
  isUpperCase?: boolean | undefined;
12
12
  withoutCalt?: boolean | undefined;
13
+ isTabularNums?: boolean | undefined;
13
14
  } & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
14
15
  theme?: import("@emotion/react").Theme | undefined;
15
16
  }, {}, {}>;
@@ -86,6 +86,10 @@ exports.ColumnLabel = (0, styled_1.styled)(Typography_1.Typography) `
86
86
  exports.CellContent = styled_1.styled.div `
87
87
  min-width: 0;
88
88
 
89
+ &.${constants_3.dataGridCellClassnames.tabularNums} {
90
+ font-feature-settings: "tnum" 1;
91
+ }
92
+
89
93
  ${({ theme }) => theme.breakpoints.down('sm')} {
90
94
  display: flex;
91
95
  flex-direction: column;
@@ -7,5 +7,6 @@ export declare const useLogic: <TData extends Record<string, unknown>>({ row, ce
7
7
  isActionColumn: boolean;
8
8
  label: string | undefined;
9
9
  hideTitleOnMobile: boolean | undefined;
10
+ isTabularNums: boolean | undefined;
10
11
  };
11
12
  export {};