@ozen-ui/kit 0.79.0 → 0.80.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (165) hide show
  1. package/__inner__/cjs/components/AutocompleteBase/modules/AutocompleteBaseInput/components/AutocompleteBaseRenderRight/AutocompleteBaseRenderRight.js +2 -2
  2. package/__inner__/cjs/components/AutocompleteBase/modules/AutocompleteBaseInputIcon/types.d.ts +2 -3
  3. package/__inner__/cjs/components/AutocompleteNext/components/AutocompleteRenderRight/AutocompleteRenderRight.js +2 -2
  4. package/__inner__/cjs/components/BottomSheetBase/modules/BottomSheetBaseBlock/BottomSheetBaseBlock.d.ts +2 -3
  5. package/__inner__/cjs/components/BottomSheetBase/modules/BottomSheetBaseBlock/types.d.ts +2 -2
  6. package/__inner__/cjs/components/BottomSheetBase/modules/BottomSheetBaseFooter/BottomSheetBaseFooter.d.ts +1 -3
  7. package/__inner__/cjs/components/BottomSheetBase/modules/BottomSheetBaseHeader/BottomSheetBaseHeader.d.ts +1 -3
  8. package/__inner__/cjs/components/ButtonNext/Button.css +26 -26
  9. package/__inner__/cjs/components/ChipGroup/ChipGroup.d.ts +2 -2
  10. package/__inner__/cjs/components/ChipGroup/ChipGroup.js +77 -10
  11. package/__inner__/cjs/components/ChipGroup/ChipGroupContext.d.ts +2 -1
  12. package/__inner__/cjs/components/ChipGroup/constants.d.ts +5 -3
  13. package/__inner__/cjs/components/ChipGroup/constants.js +8 -1
  14. package/__inner__/cjs/components/ChipGroup/entities/direction.d.ts +2 -0
  15. package/__inner__/cjs/components/ChipGroup/entities/direction.js +5 -0
  16. package/__inner__/cjs/components/ChipGroup/entities/index.d.ts +4 -0
  17. package/__inner__/cjs/components/ChipGroup/entities/index.js +7 -0
  18. package/__inner__/cjs/components/ChipGroup/entities/mode.d.ts +2 -0
  19. package/__inner__/cjs/components/ChipGroup/entities/mode.js +4 -0
  20. package/__inner__/cjs/components/ChipGroup/entities/onChange.d.ts +4 -0
  21. package/__inner__/cjs/components/ChipGroup/entities/onChange.js +2 -0
  22. package/__inner__/cjs/components/ChipGroup/entities/value.d.ts +3 -0
  23. package/__inner__/cjs/components/ChipGroup/entities/value.js +2 -0
  24. package/__inner__/cjs/components/ChipGroup/index.d.ts +2 -0
  25. package/__inner__/cjs/components/ChipGroup/index.js +2 -0
  26. package/__inner__/cjs/components/ChipGroup/types.d.ts +21 -12
  27. package/__inner__/cjs/components/ChipNext/Chip.css +6 -0
  28. package/__inner__/cjs/components/ChipNext/Chip.js +2 -2
  29. package/__inner__/cjs/components/ChipNext/entities/color.d.ts +2 -0
  30. package/__inner__/cjs/components/ChipNext/entities/color.js +10 -0
  31. package/__inner__/cjs/components/ChipNext/entities/events.d.ts +5 -0
  32. package/__inner__/cjs/components/ChipNext/entities/events.js +2 -0
  33. package/__inner__/cjs/components/ChipNext/entities/icon.d.ts +3 -0
  34. package/__inner__/cjs/components/ChipNext/entities/icon.js +2 -0
  35. package/__inner__/cjs/components/ChipNext/entities/index.d.ts +4 -0
  36. package/__inner__/cjs/components/ChipNext/entities/index.js +7 -0
  37. package/__inner__/cjs/components/ChipNext/entities/size.d.ts +2 -0
  38. package/__inner__/cjs/components/ChipNext/entities/size.js +4 -0
  39. package/__inner__/cjs/components/ChipNext/index.d.ts +2 -0
  40. package/__inner__/cjs/components/ChipNext/index.js +2 -0
  41. package/__inner__/cjs/components/ChipNext/types.d.ts +3 -12
  42. package/__inner__/cjs/components/ChipNext/types.js +0 -10
  43. package/__inner__/cjs/components/DatePicker/components/DatePickerRenderRight/DatePickerRenderRight.js +1 -1
  44. package/__inner__/cjs/components/DialogNext/Dialog.d.ts +1 -0
  45. package/__inner__/cjs/components/DialogNext/Dialog.js +1 -0
  46. package/__inner__/cjs/components/DialogNext/components/DialogBottomSheet/DialogBottomSheet.d.ts +2 -1
  47. package/__inner__/cjs/components/DialogNext/components/DialogBottomSheet/DialogBottomSheet.js +2 -2
  48. package/__inner__/cjs/components/DialogNext/components/DialogBottomSheet/types.d.ts +2 -1
  49. package/__inner__/cjs/components/DialogNext/modules/DialogFooter/index.d.ts +2 -1
  50. package/__inner__/cjs/components/DialogNext/modules/DialogFooter/index.js +2 -1
  51. package/__inner__/cjs/components/DialogNext/modules/DialogHeader/index.d.ts +1 -0
  52. package/__inner__/cjs/components/DialogNext/modules/DialogHeader/index.js +1 -0
  53. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/DialogIllustration.css +5 -0
  54. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/DialogIllustration.d.ts +3 -0
  55. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/DialogIllustration.js +13 -0
  56. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/constants.d.ts +1 -0
  57. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/constants.js +4 -0
  58. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/index.d.ts +3 -0
  59. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/index.js +6 -0
  60. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/types.d.ts +9 -0
  61. package/__inner__/cjs/components/DialogNext/modules/DialogIllustration/types.js +2 -0
  62. package/__inner__/cjs/components/DialogNext/modules/DialogTitle/index.d.ts +1 -0
  63. package/__inner__/cjs/components/DialogNext/modules/DialogTitle/index.js +1 -0
  64. package/__inner__/cjs/components/DialogNext/modules/index.d.ts +1 -0
  65. package/__inner__/cjs/components/DialogNext/modules/index.js +1 -0
  66. package/__inner__/cjs/components/DialogNext/types.d.ts +1 -1
  67. package/__inner__/cjs/components/FilePicker/FilePicker.js +1 -1
  68. package/__inner__/cjs/components/IconButtonNext/IconButton.css +26 -30
  69. package/__inner__/cjs/components/OzenProvider/providers/theme/entities/defaultProps.d.ts +2 -1
  70. package/__inner__/cjs/components/Select/components/SelectInputRenderRight/SelectInputRenderRight.js +10 -2
  71. package/__inner__/cjs/components/Select/index.d.ts +1 -0
  72. package/__inner__/cjs/components/Select/index.js +1 -0
  73. package/__inner__/cjs/components/Select/modules/SelectIconButton/SelectIconButton.d.ts +3 -0
  74. package/__inner__/cjs/components/Select/modules/SelectIconButton/SelectIconButton.js +26 -0
  75. package/__inner__/cjs/components/Select/modules/SelectIconButton/constants.d.ts +3 -0
  76. package/__inner__/cjs/components/Select/modules/SelectIconButton/constants.js +7 -0
  77. package/__inner__/cjs/components/Select/modules/SelectIconButton/index.d.ts +3 -0
  78. package/__inner__/cjs/components/Select/modules/SelectIconButton/index.js +6 -0
  79. package/__inner__/cjs/components/Select/modules/SelectIconButton/types.d.ts +7 -0
  80. package/__inner__/cjs/components/Select/modules/SelectIconButton/types.js +2 -0
  81. package/__inner__/cjs/components/Select/modules/index.d.ts +1 -0
  82. package/__inner__/cjs/components/Select/modules/index.js +4 -0
  83. package/__inner__/esm/components/AutocompleteBase/modules/AutocompleteBaseInput/components/AutocompleteBaseRenderRight/AutocompleteBaseRenderRight.js +2 -2
  84. package/__inner__/esm/components/AutocompleteBase/modules/AutocompleteBaseInputIcon/types.d.ts +2 -3
  85. package/__inner__/esm/components/AutocompleteNext/components/AutocompleteRenderRight/AutocompleteRenderRight.js +2 -2
  86. package/__inner__/esm/components/BottomSheetBase/modules/BottomSheetBaseBlock/BottomSheetBaseBlock.d.ts +2 -3
  87. package/__inner__/esm/components/BottomSheetBase/modules/BottomSheetBaseBlock/types.d.ts +2 -2
  88. package/__inner__/esm/components/BottomSheetBase/modules/BottomSheetBaseFooter/BottomSheetBaseFooter.d.ts +1 -3
  89. package/__inner__/esm/components/BottomSheetBase/modules/BottomSheetBaseHeader/BottomSheetBaseHeader.d.ts +1 -3
  90. package/__inner__/esm/components/ButtonNext/Button.css +26 -26
  91. package/__inner__/esm/components/ChipGroup/ChipGroup.d.ts +2 -2
  92. package/__inner__/esm/components/ChipGroup/ChipGroup.js +78 -11
  93. package/__inner__/esm/components/ChipGroup/ChipGroupContext.d.ts +2 -1
  94. package/__inner__/esm/components/ChipGroup/constants.d.ts +5 -3
  95. package/__inner__/esm/components/ChipGroup/constants.js +7 -0
  96. package/__inner__/esm/components/ChipGroup/entities/direction.d.ts +2 -0
  97. package/__inner__/esm/components/ChipGroup/entities/direction.js +2 -0
  98. package/__inner__/esm/components/ChipGroup/entities/index.d.ts +4 -0
  99. package/__inner__/esm/components/ChipGroup/entities/index.js +4 -0
  100. package/__inner__/esm/components/ChipGroup/entities/mode.d.ts +2 -0
  101. package/__inner__/esm/components/ChipGroup/entities/mode.js +1 -0
  102. package/__inner__/esm/components/ChipGroup/entities/onChange.d.ts +4 -0
  103. package/__inner__/esm/components/ChipGroup/entities/onChange.js +1 -0
  104. package/__inner__/esm/components/ChipGroup/entities/value.d.ts +3 -0
  105. package/__inner__/esm/components/ChipGroup/entities/value.js +1 -0
  106. package/__inner__/esm/components/ChipGroup/index.d.ts +2 -0
  107. package/__inner__/esm/components/ChipGroup/index.js +2 -0
  108. package/__inner__/esm/components/ChipGroup/types.d.ts +21 -12
  109. package/__inner__/esm/components/ChipNext/Chip.css +6 -0
  110. package/__inner__/esm/components/ChipNext/Chip.js +2 -2
  111. package/__inner__/esm/components/ChipNext/entities/color.d.ts +2 -0
  112. package/__inner__/esm/components/ChipNext/entities/color.js +7 -0
  113. package/__inner__/esm/components/ChipNext/entities/events.d.ts +5 -0
  114. package/__inner__/esm/components/ChipNext/entities/events.js +1 -0
  115. package/__inner__/esm/components/ChipNext/entities/icon.d.ts +3 -0
  116. package/__inner__/esm/components/ChipNext/entities/icon.js +1 -0
  117. package/__inner__/esm/components/ChipNext/entities/index.d.ts +4 -0
  118. package/__inner__/esm/components/ChipNext/entities/index.js +4 -0
  119. package/__inner__/esm/components/ChipNext/entities/size.d.ts +2 -0
  120. package/__inner__/esm/components/ChipNext/entities/size.js +1 -0
  121. package/__inner__/esm/components/ChipNext/index.d.ts +2 -0
  122. package/__inner__/esm/components/ChipNext/index.js +2 -0
  123. package/__inner__/esm/components/ChipNext/types.d.ts +3 -12
  124. package/__inner__/esm/components/ChipNext/types.js +1 -9
  125. package/__inner__/esm/components/DatePicker/components/DatePickerRenderRight/DatePickerRenderRight.js +1 -1
  126. package/__inner__/esm/components/DialogNext/Dialog.d.ts +1 -0
  127. package/__inner__/esm/components/DialogNext/Dialog.js +1 -0
  128. package/__inner__/esm/components/DialogNext/components/DialogBottomSheet/DialogBottomSheet.d.ts +2 -1
  129. package/__inner__/esm/components/DialogNext/components/DialogBottomSheet/DialogBottomSheet.js +2 -2
  130. package/__inner__/esm/components/DialogNext/components/DialogBottomSheet/types.d.ts +2 -1
  131. package/__inner__/esm/components/DialogNext/modules/DialogFooter/index.d.ts +2 -1
  132. package/__inner__/esm/components/DialogNext/modules/DialogFooter/index.js +2 -1
  133. package/__inner__/esm/components/DialogNext/modules/DialogHeader/index.d.ts +1 -0
  134. package/__inner__/esm/components/DialogNext/modules/DialogHeader/index.js +1 -0
  135. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/DialogIllustration.css +5 -0
  136. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/DialogIllustration.d.ts +3 -0
  137. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/DialogIllustration.js +10 -0
  138. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/constants.d.ts +1 -0
  139. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/constants.js +1 -0
  140. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/index.d.ts +3 -0
  141. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/index.js +3 -0
  142. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/types.d.ts +9 -0
  143. package/__inner__/esm/components/DialogNext/modules/DialogIllustration/types.js +1 -0
  144. package/__inner__/esm/components/DialogNext/modules/DialogTitle/index.d.ts +1 -0
  145. package/__inner__/esm/components/DialogNext/modules/DialogTitle/index.js +1 -0
  146. package/__inner__/esm/components/DialogNext/modules/index.d.ts +1 -0
  147. package/__inner__/esm/components/DialogNext/modules/index.js +1 -0
  148. package/__inner__/esm/components/DialogNext/types.d.ts +1 -1
  149. package/__inner__/esm/components/FilePicker/FilePicker.js +1 -1
  150. package/__inner__/esm/components/IconButtonNext/IconButton.css +26 -30
  151. package/__inner__/esm/components/OzenProvider/providers/theme/entities/defaultProps.d.ts +2 -1
  152. package/__inner__/esm/components/Select/components/SelectInputRenderRight/SelectInputRenderRight.js +10 -2
  153. package/__inner__/esm/components/Select/index.d.ts +1 -0
  154. package/__inner__/esm/components/Select/index.js +1 -0
  155. package/__inner__/esm/components/Select/modules/SelectIconButton/SelectIconButton.d.ts +3 -0
  156. package/__inner__/esm/components/Select/modules/SelectIconButton/SelectIconButton.js +23 -0
  157. package/__inner__/esm/components/Select/modules/SelectIconButton/constants.d.ts +3 -0
  158. package/__inner__/esm/components/Select/modules/SelectIconButton/constants.js +4 -0
  159. package/__inner__/esm/components/Select/modules/SelectIconButton/index.d.ts +3 -0
  160. package/__inner__/esm/components/Select/modules/SelectIconButton/index.js +3 -0
  161. package/__inner__/esm/components/Select/modules/SelectIconButton/types.d.ts +7 -0
  162. package/__inner__/esm/components/Select/modules/SelectIconButton/types.js +1 -0
  163. package/__inner__/esm/components/Select/modules/index.d.ts +1 -0
  164. package/__inner__/esm/components/Select/modules/index.js +1 -0
  165. package/package.json +4 -4
@@ -1,5 +1,3 @@
1
1
  import React from 'react';
2
2
  export declare const cnBottomSheetBaseHeader: import("@bem-react/classname").ClassNameFormatter;
3
- export declare const BottomSheetBaseHeader: React.ForwardRefExoticComponent<{
4
- expandOnDrag?: boolean;
5
- } & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "expandOnDrag"> & React.RefAttributes<HTMLDivElement>>;
3
+ export declare const BottomSheetBaseHeader: React.ForwardRefExoticComponent<Omit<import("../BottomSheetBaseBlock").BottomSheetBaseBlockProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
@@ -101,10 +101,10 @@
101
101
  --button-bg-color-hover: var(--color-background-action-secondary-hover);
102
102
  --button-bg-color-active: var(--color-background-action-secondary-pressed);
103
103
  --button-bg-color-focus: var(--color-background-action-secondary-hover);
104
- --button-font-color: var(--color-content-action-on);
105
- --button-font-color-hover: var(--color-content-action-on);
106
- --button-font-color-active: var(--color-content-action-on);
107
- --button-font-color-focus: var(--color-content-action-on);
104
+ --button-font-color: var(--color-content-primary-inverse);
105
+ --button-font-color-hover: var(--color-content-primary-inverse);
106
+ --button-font-color-active: var(--color-content-primary-inverse);
107
+ --button-font-color-focus: var(--color-content-primary-inverse);
108
108
  }
109
109
  .ButtonNext_variant_contained.ButtonNext_color_tertiary {
110
110
  --button-bg-color: var(--color-background-tertiary);
@@ -132,16 +132,16 @@
132
132
  --button-bg-color-hover: var(--color-background-action-light-hover);
133
133
  --button-bg-color-active: var(--color-background-action-light-pressed);
134
134
  --button-bg-color-focus: var(--color-background-action-light-hover);
135
- --button-font-color: var(--color-content-action);
136
- --button-font-color-hover: var(--color-content-action);
137
- --button-font-color-active: var(--color-content-action);
138
- --button-font-color-focus: var(--color-content-action);
135
+ --button-font-color: var(--color-content-action-dark);
136
+ --button-font-color-hover: var(--color-content-action-dark);
137
+ --button-font-color-active: var(--color-content-action-dark);
138
+ --button-font-color-focus: var(--color-content-action-dark);
139
139
  }
140
140
  .ButtonNext_variant_contained-additional.ButtonNext_color_secondary {
141
- --button-bg-color: var(--color-background-secondary);
142
- --button-bg-color-hover: var(--color-background-secondary-hover);
143
- --button-bg-color-active: var(--color-background-secondary-pressed);
144
- --button-bg-color-focus: var(--color-background-secondary-hover);
141
+ --button-bg-color: var(--color-background-action-secondary-light);
142
+ --button-bg-color-hover: var(--color-background-action-secondary-light-hover);
143
+ --button-bg-color-active: var(--color-background-action-secondary-light-pressed);
144
+ --button-bg-color-focus: var(--color-background-action-secondary-light-hover);
145
145
  --button-font-color: var(--color-content-primary);
146
146
  --button-font-color-hover: var(--color-content-primary);
147
147
  --button-font-color-active: var(--color-content-primary);
@@ -162,10 +162,10 @@
162
162
  --button-bg-color-hover: var(--color-background-error-light-hover);
163
163
  --button-bg-color-active: var(--color-background-error-light-pressed);
164
164
  --button-bg-color-focus: var(--color-background-error-light-hover);
165
- --button-font-color: var(--color-content-error);
166
- --button-font-color-hover: var(--color-content-error);
167
- --button-font-color-active: var(--color-content-error);
168
- --button-font-color-focus: var(--color-content-error);
165
+ --button-font-color: var(--color-content-error-dark);
166
+ --button-font-color-hover: var(--color-content-error-dark);
167
+ --button-font-color-active: var(--color-content-error-dark);
168
+ --button-font-color-focus: var(--color-content-error-dark);
169
169
  }
170
170
  /** ghost */
171
171
  .ButtonNext_variant_ghost.ButtonNext_color_primary {
@@ -180,13 +180,13 @@
180
180
  }
181
181
  .ButtonNext_variant_ghost.ButtonNext_color_secondary {
182
182
  --button-bg-color: transparent;
183
- --button-bg-color-hover: var(--color-background-secondary-hover);
184
- --button-bg-color-active: var(--color-background-secondary-pressed);
185
- --button-bg-color-focus: var(--color-background-secondary-hover);
186
- --button-font-color: var(--color-content-primary);
187
- --button-font-color-hover: var(--color-content-primary);
188
- --button-font-color-active: var(--color-content-primary);
189
- --button-font-color-focus: var(--color-content-primary);
183
+ --button-bg-color-hover: var(--color-background-action-secondary-light-hover);
184
+ --button-bg-color-active: var(--color-background-action-secondary-light-pressed);
185
+ --button-bg-color-focus: var(--color-background-action-secondary-light-hover);
186
+ --button-font-color: var(--color-content-action-secondary);
187
+ --button-font-color-hover: var(--color-content-action-secondary);
188
+ --button-font-color-active: var(--color-content-action-secondary);
189
+ --button-font-color-focus: var(--color-content-action-secondary);
190
190
  }
191
191
  .ButtonNext_variant_ghost.ButtonNext_color_tertiary {
192
192
  --button-bg-color: transparent;
@@ -228,13 +228,13 @@
228
228
  --button-font-color: var(--color-content-action);
229
229
  --button-font-color-hover: var(--color-background-action-hover);
230
230
  --button-font-color-active: var(--color-background-action-pressed);
231
- --button-font-color-focus: var(--color-background-action-pressed);
231
+ --button-font-color-focus: var(--color-background-action-hover);
232
232
  }
233
233
  .ButtonNext_variant_function.ButtonNext_color_secondary {
234
234
  --button-font-color: var(--color-content-action-secondary);
235
235
  --button-font-color-hover: var(--color-content-action-secondary-hover);
236
236
  --button-font-color-active: var(--color-content-action-secondary-pressed);
237
- --button-font-color-focus: var(--color-content-action-secondary-pressed);
237
+ --button-font-color-focus: var(--color-content-action-secondary-hover);
238
238
  }
239
239
  .ButtonNext_variant_function.ButtonNext_color_tertiary {
240
240
  --button-font-color: var(--color-content-secondary);
@@ -246,7 +246,7 @@
246
246
  --button-font-color: var(--color-content-error);
247
247
  --button-font-color-hover: var(--color-content-error-hover);
248
248
  --button-font-color-active: var(--color-content-error-pressed);
249
- --button-font-color-focus: var(--color-content-error-pressed);
249
+ --button-font-color-focus: var(--color-content-error-hover);
250
250
  }
251
251
  /** disabled & loading */
252
252
  .ButtonNext_variant_contained.ButtonNext_disabled,
@@ -1,4 +1,4 @@
1
1
  import './ChipGroup.css';
2
- import type { ChipGroupBaseProps } from './types';
2
+ import type { ChipGroupComponent } from './types';
3
3
  export declare const cnChipGroup: import("@bem-react/classname").ClassNameFormatter;
4
- export declare const ChipGroup: import("../../utils/polymorphicComponentWithRef").PolymorphicComponentWithRef<ChipGroupBaseProps, "div", "as">;
4
+ export declare const ChipGroup: ChipGroupComponent;
@@ -1,49 +1,116 @@
1
1
  import { __assign, __read, __rest, __spreadArray } from "tslib";
2
2
  import './ChipGroup.css';
3
- import React from 'react';
3
+ import React, { useEffect, useMemo } from 'react';
4
4
  import { useControlled } from '../../hooks/useControlled';
5
5
  import { useThemeProps } from '../../hooks/useThemeProps';
6
+ import { isArray, isString } from '../../utils';
6
7
  import { cn } from '../../utils/classname';
7
8
  import { polymorphicComponentWithRef } from '../../utils/polymorphicComponentWithRef';
9
+ import { FieldHint } from '../FieldHint';
8
10
  import { FormGroup } from '../FormGroup';
9
11
  import { FormTitle } from '../FormTitle';
10
12
  import { ChipGroupContext } from './ChipGroupContext';
11
- import { CHIP_GROUP_DEFAULT_AS, CHIP_GROUP_DEFAULT_DIRECTION, CHIP_GROUP_DEFAULT_SIZE, } from './constants';
13
+ import { CHIP_GROUP_DEFAULT_AS, CHIP_GROUP_DEFAULT_DIRECTION, CHIP_GROUP_DEFAULT_MODE, CHIP_GROUP_DEFAULT_SIZE, CHIP_GROUP_SIZE_TO_HINT_SIZE, } from './constants';
14
+ import { chipGroupModeVariant } from './entities';
12
15
  export var cnChipGroup = cn('ChipGroup');
13
16
  export var ChipGroup = polymorphicComponentWithRef(function (inProps, ref) {
14
17
  var props = useThemeProps({
15
18
  props: inProps,
16
19
  name: 'ChipGroup',
17
20
  });
18
- var _a = props.direction, direction = _a === void 0 ? CHIP_GROUP_DEFAULT_DIRECTION : _a, _b = props.size, size = _b === void 0 ? CHIP_GROUP_DEFAULT_SIZE : _b, _c = props.as, Tag = _c === void 0 ? CHIP_GROUP_DEFAULT_AS : _c, color = props.color, title = props.title, className = props.className, children = props.children, valueProp = props.value, _d = props.defaultValue, defaultValue = _d === void 0 ? [] : _d, onChange = props.onChange, disabled = props.disabled, titleProps = props.titleProps, groupProps = props.groupProps, other = __rest(props, ["direction", "size", "as", "color", "title", "className", "children", "value", "defaultValue", "onChange", "disabled", "titleProps", "groupProps"]);
21
+ var _a = props.direction, direction = _a === void 0 ? CHIP_GROUP_DEFAULT_DIRECTION : _a, _b = props.size, size = _b === void 0 ? CHIP_GROUP_DEFAULT_SIZE : _b, _c = props.as, Tag = _c === void 0 ? CHIP_GROUP_DEFAULT_AS : _c, color = props.color, title = props.title, className = props.className, children = props.children, valueProp = props.value, defaultValueProp = props.defaultValue, onChange = props.onChange, disabled = props.disabled, titleProps = props.titleProps, groupProps = props.groupProps, _d = props.mode, mode = _d === void 0 ? CHIP_GROUP_DEFAULT_MODE : _d, hint = props.hint, other = __rest(props, ["direction", "size", "as", "color", "title", "className", "children", "value", "defaultValue", "onChange", "disabled", "titleProps", "groupProps", "mode", "hint"]);
22
+ var defaultValue = useMemo(function () {
23
+ if (defaultValueProp !== undefined) {
24
+ return defaultValueProp;
25
+ }
26
+ if (mode === 'checkbox') {
27
+ return [];
28
+ }
29
+ if (mode === 'radio') {
30
+ return null;
31
+ }
32
+ throw new Error("\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0431\u0440\u0430\u0431\u043E\u0442\u0430\u0442\u044C mode \"".concat(mode, "\""));
33
+ }, []);
19
34
  var _e = __read(useControlled({
20
35
  value: valueProp,
21
36
  defaultValue: defaultValue,
22
37
  name: 'ChipGroup',
23
38
  state: 'value',
24
39
  }), 2), valueState = _e[0], setValueState = _e[1];
40
+ var setValue = function (value, event) {
41
+ setValueState(value);
42
+ onChange === null || onChange === void 0 ? void 0 : onChange(value, event);
43
+ };
44
+ useEffect(function () {
45
+ if (mode === 'checkbox') {
46
+ if (isString(valueState)) {
47
+ var value = [valueState];
48
+ setValue(value, null);
49
+ return;
50
+ }
51
+ if (valueState === null) {
52
+ setValue([], null);
53
+ return;
54
+ }
55
+ return;
56
+ }
57
+ if (mode === 'radio') {
58
+ if (!isArray(valueState)) {
59
+ return;
60
+ }
61
+ if (valueState.length > 0) {
62
+ setValue(valueState[0], null);
63
+ return;
64
+ }
65
+ setValue(null, null);
66
+ return;
67
+ }
68
+ throw new Error("\u041D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0431\u0440\u0430\u0431\u043E\u0442\u0430\u0442\u044C \u0440\u0435\u0436\u0438\u043C \"".concat(mode, "\"."));
69
+ }, [mode]);
70
+ var valueArray = (function () {
71
+ if (!valueState) {
72
+ return [];
73
+ }
74
+ if (isString(valueState)) {
75
+ return [valueState];
76
+ }
77
+ return valueState;
78
+ })();
25
79
  var onClick = function (event, payload) {
26
80
  var itemValue = payload.value;
27
81
  if (itemValue === undefined) {
28
82
  return;
29
83
  }
30
- var requiredValueState = valueState !== null && valueState !== void 0 ? valueState : [];
31
- var isValueAlreadyChecked = requiredValueState.includes(itemValue);
32
- var value = isValueAlreadyChecked
33
- ? requiredValueState.filter(function (item) { return item !== itemValue; })
34
- : __spreadArray(__spreadArray([], __read(requiredValueState), false), [itemValue], false);
35
- setValueState(value);
36
- onChange === null || onChange === void 0 ? void 0 : onChange(value, event);
84
+ var isValueAlreadyChecked = valueArray.includes(itemValue);
85
+ if (mode === 'checkbox') {
86
+ var value = isValueAlreadyChecked
87
+ ? valueArray.filter(function (item) { return item !== itemValue; })
88
+ : __spreadArray(__spreadArray([], __read(valueArray), false), [itemValue], false);
89
+ setValueState(value);
90
+ onChange === null || onChange === void 0 ? void 0 : onChange(value, event);
91
+ return;
92
+ }
93
+ if (mode === 'radio') {
94
+ if (isValueAlreadyChecked) {
95
+ return;
96
+ }
97
+ setValueState(itemValue);
98
+ onChange === null || onChange === void 0 ? void 0 : onChange(itemValue, event);
99
+ return;
100
+ }
101
+ throw new Error("\u041D\u0435\u043E\u0436\u0438\u0434\u0430\u043D\u043D\u044B\u0439 mode \"".concat(mode, "\". \u0414\u043E\u0441\u0442\u0443\u043F\u043D\u044B\u0435 \u0432\u0430\u0440\u0438\u0430\u043D\u0442\u044B: ").concat(JSON.stringify(chipGroupModeVariant)));
37
102
  };
38
103
  return (React.createElement(Tag, __assign({ className: cnChipGroup({ size: size }, [className]), role: "group" }, other, { ref: ref }),
39
104
  React.createElement(ChipGroupContext.Provider, { value: {
40
105
  value: valueState,
106
+ valueArray: valueArray,
41
107
  onClick: onClick,
42
108
  size: size,
43
109
  disabled: disabled,
44
110
  color: color,
45
111
  } },
46
112
  title && (React.createElement(FormTitle, __assign({ size: size }, titleProps), title)),
47
- React.createElement(FormGroup, __assign({ direction: direction, size: size }, groupProps), children))));
113
+ React.createElement(FormGroup, __assign({ direction: direction, size: size }, groupProps), children),
114
+ React.createElement(FieldHint, { size: CHIP_GROUP_SIZE_TO_HINT_SIZE[size], error: color === 'error', disabled: disabled }, hint))));
48
115
  });
49
116
  ChipGroup.displayName = 'ChipGroup';
@@ -1,9 +1,10 @@
1
1
  import type { ChipColorVariant, ChipOnClick, ChipSizeVariant } from '../ChipNext';
2
- import type { ChipGroupValue } from './types';
2
+ import type { ChipGroupValue, ChipGroupValueArray } from './entities';
3
3
  export type ChipGroupContextValue = {
4
4
  onClick: ChipOnClick;
5
5
  disabled?: boolean;
6
6
  value?: ChipGroupValue;
7
+ valueArray?: ChipGroupValueArray;
7
8
  size?: ChipSizeVariant;
8
9
  color?: ChipColorVariant;
9
10
  };
@@ -1,5 +1,7 @@
1
+ import type { FormElementSizeVariant } from '../../types';
1
2
  import type { ChipSizeVariant } from '../ChipNext';
2
- import type { FormGroupDirectionVariant } from '../FormGroup';
3
- export declare const CHIP_GROUP_DEFAULT_DIRECTION: FormGroupDirectionVariant;
4
- export declare const CHIP_GROUP_DEFAULT_SIZE: ChipSizeVariant;
3
+ export declare const CHIP_GROUP_DEFAULT_DIRECTION = "row";
4
+ export declare const CHIP_GROUP_DEFAULT_SIZE = "m";
5
5
  export declare const CHIP_GROUP_DEFAULT_AS = "div";
6
+ export declare const CHIP_GROUP_DEFAULT_MODE = "checkbox";
7
+ export declare const CHIP_GROUP_SIZE_TO_HINT_SIZE: Readonly<Record<ChipSizeVariant, FormElementSizeVariant>>;
@@ -1,3 +1,10 @@
1
1
  export var CHIP_GROUP_DEFAULT_DIRECTION = 'row';
2
2
  export var CHIP_GROUP_DEFAULT_SIZE = 'm';
3
3
  export var CHIP_GROUP_DEFAULT_AS = 'div';
4
+ export var CHIP_GROUP_DEFAULT_MODE = 'checkbox';
5
+ export var CHIP_GROUP_SIZE_TO_HINT_SIZE = {
6
+ xs: 's',
7
+ s: 's',
8
+ m: 'l',
9
+ l: 'l',
10
+ };
@@ -0,0 +1,2 @@
1
+ export declare const chipGroupDirection: readonly ["row", "column", "rowReverse", "columnReverse"];
2
+ export type ChipGroupDirection = (typeof chipGroupDirection)[number];
@@ -0,0 +1,2 @@
1
+ import { formGroupDirectionVariant } from '../../FormGroup';
2
+ export var chipGroupDirection = formGroupDirectionVariant;
@@ -0,0 +1,4 @@
1
+ export * from './direction';
2
+ export * from './mode';
3
+ export * from './onChange';
4
+ export * from './value';
@@ -0,0 +1,4 @@
1
+ export * from './direction';
2
+ export * from './mode';
3
+ export * from './onChange';
4
+ export * from './value';
@@ -0,0 +1,2 @@
1
+ export declare const chipGroupModeVariant: readonly ["checkbox", "radio"];
2
+ export type ChipGroupModeVariant = (typeof chipGroupModeVariant)[number];
@@ -0,0 +1 @@
1
+ export var chipGroupModeVariant = ['checkbox', 'radio'];
@@ -0,0 +1,4 @@
1
+ import type { MouseEvent } from 'react';
2
+ import type { ChipGroupModeVariant } from './mode';
3
+ import type { ChipGroupValue } from './value';
4
+ export type ChipGroupOnChange<Mode extends ChipGroupModeVariant = ChipGroupModeVariant> = (value: ChipGroupValue<Mode>, event: MouseEvent<HTMLElement> | null) => void;
@@ -0,0 +1,3 @@
1
+ import type { ChipGroupModeVariant } from './mode';
2
+ export type ChipGroupValueArray = string[];
3
+ export type ChipGroupValue<Mode extends ChipGroupModeVariant = ChipGroupModeVariant> = Mode extends 'checkbox' ? ChipGroupValueArray : string | null;
@@ -1,2 +1,4 @@
1
+ export * from './entities';
2
+ export * from './constants';
1
3
  export * from './ChipGroup';
2
4
  export * from './types';
@@ -1,2 +1,4 @@
1
+ export * from './entities';
2
+ export * from './constants';
1
3
  export * from './ChipGroup';
2
4
  export * from './types';
@@ -1,16 +1,17 @@
1
- import type { ElementType, MouseEvent, ReactNode } from 'react';
2
- import type { PolymorphicComponentPropsWithoutRef } from '../../utils/polymorphicComponentWithRef';
1
+ import type { ComponentRef, ElementType, ReactNode } from 'react';
2
+ import type { WithDisplayName } from '../../types';
3
+ import type { PolymorphicComponentPropsWithoutRef, PolymorphicComponentPropsWithRef } from '../../utils/polymorphicComponentWithRef';
3
4
  import type { ChipColorVariant, ChipSizeVariant } from '../ChipNext';
4
- import type { FormGroupDirectionVariant, FormGroupProps } from '../FormGroup';
5
+ import type { FieldHintProps } from '../FieldHint';
6
+ import type { FormGroupProps } from '../FormGroup';
5
7
  import type { FormTitleProps } from '../FormTitle';
6
- import type { CHIP_GROUP_DEFAULT_AS } from './constants';
7
- export type ChipGroupValue = string[];
8
- export type ChipGroupOnChange = (value: ChipGroupValue, event: MouseEvent<HTMLElement>) => void;
9
- export type ChipGroupBaseProps = {
8
+ import type { CHIP_GROUP_DEFAULT_AS, CHIP_GROUP_DEFAULT_MODE } from './constants';
9
+ import type { ChipGroupValue, ChipGroupOnChange, ChipGroupModeVariant, ChipGroupDirection } from './entities';
10
+ export type ChipGroupBaseProps<Mode extends ChipGroupModeVariant = ChipGroupModeVariant> = {
10
11
  /** Значение по умолчанию (неконтролируемое состояние) */
11
- defaultValue?: ChipGroupValue;
12
+ defaultValue?: ChipGroupValue<Mode>;
12
13
  /** Текущее значение */
13
- value?: ChipGroupValue;
14
+ value?: ChipGroupValue<Mode>;
14
15
  /** Вариант представления компонента */
15
16
  color?: ChipColorVariant;
16
17
  /** Размер */
@@ -18,9 +19,9 @@ export type ChipGroupBaseProps = {
18
19
  /** Содержимое компонента */
19
20
  children?: ReactNode;
20
21
  /** Направление */
21
- direction?: FormGroupDirectionVariant;
22
+ direction?: ChipGroupDirection;
22
23
  /** Событие изменения состояния */
23
- onChange?: ChipGroupOnChange;
24
+ onChange?: ChipGroupOnChange<Mode>;
24
25
  /** Если `true` делает элементы неактивными */
25
26
  disabled?: boolean;
26
27
  /** Идентификатор компонента для тестов */
@@ -29,5 +30,13 @@ export type ChipGroupBaseProps = {
29
30
  titleProps?: FormTitleProps;
30
31
  /** Свойства FormGroup */
31
32
  groupProps?: FormGroupProps;
33
+ /** Режим работы */
34
+ mode?: Mode;
35
+ /** Дополнительное описание */
36
+ hint?: ReactNode;
37
+ /** Параметры дополнительного описания */
38
+ hintProps?: FieldHintProps;
32
39
  };
33
- export type ChipGroupProps<As extends ElementType = typeof CHIP_GROUP_DEFAULT_AS> = PolymorphicComponentPropsWithoutRef<ChipGroupBaseProps, As>;
40
+ export type ChipGroupProps<Mode extends ChipGroupModeVariant = typeof CHIP_GROUP_DEFAULT_MODE, As extends ElementType = typeof CHIP_GROUP_DEFAULT_AS> = PolymorphicComponentPropsWithoutRef<ChipGroupBaseProps<Mode>, As>;
41
+ export type ChipGroupComponent = WithDisplayName<(<Mode extends ChipGroupModeVariant = typeof CHIP_GROUP_DEFAULT_MODE, As extends ElementType = typeof CHIP_GROUP_DEFAULT_AS>(props: PolymorphicComponentPropsWithRef<ChipGroupBaseProps<Mode>, As>) => ReactNode)>;
42
+ export type ChipGroupRef<As extends ElementType = typeof CHIP_GROUP_DEFAULT_AS> = ComponentRef<As>;
@@ -96,6 +96,12 @@
96
96
  --chip-bg-color-active: var(--color-background-overlay);
97
97
  --chip-text-color: var(--color-content-action-on);
98
98
  }
99
+ .ChipNext_color_error {
100
+ --chip-bg-color: var(--color-background-error-light);
101
+ --chip-bg-color-hover: var(--color-background-error-light);
102
+ --chip-bg-color-active: var(--color-background-error-light);
103
+ --chip-text-color: var(--color-content-error);
104
+ }
99
105
  .ChipNext_color_primary.ChipNext_checked {
100
106
  --chip-bg-color: var(--color-background-action);
101
107
  --chip-bg-color-hover: var(--color-background-action);
@@ -23,8 +23,8 @@ export var Chip = polymorphicComponentWithRef(function (inProps, ref) {
23
23
  if (isDev && value === undefined) {
24
24
  logger.error('Отсутствует параметр "value" для Chip, находящегося в ChipGroup.');
25
25
  }
26
- if (checked === undefined && chipGroup.value) {
27
- checked = chipGroup === null || chipGroup === void 0 ? void 0 : chipGroup.value.includes(value);
26
+ if (checked === undefined && chipGroup.valueArray) {
27
+ checked = chipGroup.valueArray.includes(value);
28
28
  }
29
29
  if (inProps.size === undefined && chipGroup.size) {
30
30
  size = chipGroup.size;
@@ -0,0 +1,2 @@
1
+ export declare const chipColorVariant: readonly ["primary", "secondary", "main", "overlay", "error"];
2
+ export type ChipColorVariant = (typeof chipColorVariant)[number];
@@ -0,0 +1,7 @@
1
+ export var chipColorVariant = [
2
+ 'primary',
3
+ 'secondary',
4
+ 'main',
5
+ 'overlay',
6
+ 'error',
7
+ ];
@@ -0,0 +1,5 @@
1
+ import type { MouseEvent } from 'react';
2
+ export type ChipOnClick = (event: MouseEvent<HTMLElement>, payload: {
3
+ checked: boolean;
4
+ value: string | undefined;
5
+ }) => void;
@@ -0,0 +1,3 @@
1
+ import type { IconProps } from '@ozen-ui/icons';
2
+ import type { RenderContentType } from '../../../utils';
3
+ export type ChipIcon = RenderContentType<IconProps>['content'];
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ export * from './color';
2
+ export * from './events';
3
+ export * from './icon';
4
+ export * from './size';
@@ -0,0 +1,4 @@
1
+ export * from './color';
2
+ export * from './events';
3
+ export * from './icon';
4
+ export * from './size';
@@ -0,0 +1,2 @@
1
+ export declare const chipSizeVariant: readonly ["xs", "s", "m", "l"];
2
+ export type ChipSizeVariant = (typeof chipSizeVariant)[number];
@@ -0,0 +1 @@
1
+ export var chipSizeVariant = ['xs', 's', 'm', 'l'];
@@ -1,2 +1,4 @@
1
+ export * from './entities';
2
+ export * from './constants';
1
3
  export * from './Chip';
2
4
  export * from './types';
@@ -1,2 +1,4 @@
1
+ export * from './entities';
2
+ export * from './constants';
1
3
  export * from './Chip';
2
4
  export * from './types';
@@ -1,17 +1,7 @@
1
- import type { ElementType, MouseEvent, ReactNode } from 'react';
2
- import type { IconProps } from '@ozen-ui/icons';
1
+ import type { ComponentRef, ElementType, ReactNode } from 'react';
3
2
  import type { PolymorphicComponentPropsWithRef } from '../../utils/polymorphicComponentWithRef';
4
- import type { RenderContentType } from '../../utils/renderContent';
5
3
  import type { CHIP_DEFAULT_TAG } from './constants';
6
- export declare const chipColorVariant: readonly ["primary", "secondary", "main", "overlay"];
7
- export type ChipColorVariant = (typeof chipColorVariant)[number];
8
- export declare const chipSizeVariant: readonly ["xs", "s", "m", "l"];
9
- export type ChipSizeVariant = (typeof chipSizeVariant)[number];
10
- export type ChipIcon = RenderContentType<IconProps>['content'];
11
- export type ChipOnClick = (event: MouseEvent<HTMLElement>, payload: {
12
- checked: boolean;
13
- value: string | undefined;
14
- }) => void;
4
+ import type { ChipColorVariant, ChipSizeVariant, ChipOnClick, ChipIcon } from './entities';
15
5
  export type ChipBaseProps = {
16
6
  /** Размер компонента */
17
7
  size?: ChipSizeVariant;
@@ -39,3 +29,4 @@ export type ChipBaseProps = {
39
29
  'data-testid'?: string;
40
30
  };
41
31
  export type ChipProps<As extends ElementType = typeof CHIP_DEFAULT_TAG> = PolymorphicComponentPropsWithRef<ChipBaseProps, As>;
32
+ export type ChipRef<As extends ElementType = typeof CHIP_DEFAULT_TAG> = ComponentRef<As>;
@@ -1,9 +1 @@
1
- // ---- COLOR ----
2
- export var chipColorVariant = [
3
- 'primary',
4
- 'secondary',
5
- 'main',
6
- 'overlay',
7
- ];
8
- // ---- SIZE ----
9
- export var chipSizeVariant = ['xs', 's', 'm', 'l'];
1
+ export {};
@@ -14,7 +14,7 @@ export var DatePickerRenderRight = function (_a) {
14
14
  onClear === null || onClear === void 0 ? void 0 : onClear(e);
15
15
  };
16
16
  return (React.createElement("div", { className: cnDatePicker('RenderRight') },
17
- !disableClearButton && (React.createElement(IconButton, { size: size, type: "button", tabIndex: -1, icon: CrossIcon, title: clearText, variant: "function", onClick: handleClear, "aria-label": clearText, className: cnDatePicker('ClearButton', {
17
+ !disableClearButton && (React.createElement(IconButton, { size: size, type: "button", tabIndex: -1, icon: CrossIcon, title: clearText, variant: "function", color: "tertiary", onClick: handleClear, "aria-label": clearText, className: cnDatePicker('ClearButton', {
18
18
  visibility: isVisibleClearButton,
19
19
  }), compressed: true })),
20
20
  React.createElement(FieldIcon, { icon: renderRight }),
@@ -5,6 +5,7 @@ import './modules/DialogBody/DialogBody.css';
5
5
  import './modules/DialogFooter/DialogFooter.css';
6
6
  import './modules/DialogFooterButtonsGroup/DialogFooterButtonsGroup.css';
7
7
  import './modules/DialogHeader/DialogHeader.css';
8
+ import './modules/DialogIllustration/DialogIllustration.css';
8
9
  import './modules/DialogSubtitle/DialogSubtitle.css';
9
10
  import './modules/DialogTitle/DialogTitle.css';
10
11
  import React from 'react';
@@ -6,6 +6,7 @@ import './modules/DialogBody/DialogBody.css';
6
6
  import './modules/DialogFooter/DialogFooter.css';
7
7
  import './modules/DialogFooterButtonsGroup/DialogFooterButtonsGroup.css';
8
8
  import './modules/DialogHeader/DialogHeader.css';
9
+ import './modules/DialogIllustration/DialogIllustration.css';
9
10
  import './modules/DialogSubtitle/DialogSubtitle.css';
10
11
  import './modules/DialogTitle/DialogTitle.css';
11
12
  import React, { forwardRef } from 'react';
@@ -9,4 +9,5 @@ export declare const DialogBottomSheet: React.ForwardRefExoticComponent<{
9
9
  hideCloseButton: boolean | undefined;
10
10
  className: string | undefined;
11
11
  onClose: (() => void) | undefined;
12
- } & Omit<Omit<import("../../../BottomSheetBase").BottomSheetBaseProps, "snaps">, "className" | "size" | "open" | "variant" | "onClose" | "hideCloseButton" | "closeButton"> & React.RefAttributes<HTMLDivElement>>;
12
+ headerProps?: Omit<import("../../../BottomSheetBase").BottomSheetBaseHeaderProps, "children">;
13
+ } & Omit<Omit<import("../../../BottomSheetBase").BottomSheetBaseProps, "snaps">, "className" | "size" | "open" | "variant" | "onClose" | "hideCloseButton" | "closeButton" | "headerProps"> & React.RefAttributes<HTMLDivElement>>;
@@ -6,11 +6,11 @@ import { BottomSheetBase, BottomSheetBaseHeader, } from '../../../BottomSheetBas
6
6
  import { DIALOG_BOTTOM_SHEET_MAX_HEIGHT_BY_VARIANT, DIALOG_BOTTOM_SHEET_SNAPS_BY_VARIANT, } from './constants';
7
7
  export var cnDialogBottomSheet = cn('DialogNextBottomSheet');
8
8
  export var DialogBottomSheet = forwardRef(function (_a, ref) {
9
- var children = _a.children, open = _a.open, closeButton = _a.closeButton, onClose = _a.onClose, size = _a.size, variant = _a.variant, className = _a.className, hideCloseButton = _a.hideCloseButton, other = __rest(_a, ["children", "open", "closeButton", "onClose", "size", "variant", "className", "hideCloseButton"]);
9
+ var children = _a.children, open = _a.open, closeButton = _a.closeButton, onClose = _a.onClose, size = _a.size, variant = _a.variant, className = _a.className, hideCloseButton = _a.hideCloseButton, headerProps = _a.headerProps, other = __rest(_a, ["children", "open", "closeButton", "onClose", "size", "variant", "className", "hideCloseButton", "headerProps"]);
10
10
  return (React.createElement(BottomSheetBase, __assign({ ref: ref, className: cnDialogBottomSheet({
11
11
  size: size,
12
12
  }, [className]), bottomSheetClassName: cnDialogBottomSheet('BottomSheet'), snaps: DIALOG_BOTTOM_SHEET_SNAPS_BY_VARIANT[variant], maxHeight: DIALOG_BOTTOM_SHEET_MAX_HEIGHT_BY_VARIANT[variant], open: open, onClose: onClose, role: "dialog" }, other),
13
- React.createElement(BottomSheetBaseHeader, { className: cnDialogBottomSheet('Header') }, !hideCloseButton && (React.createElement("div", { className: cnDialogBottomSheet('CloseButton') }, closeButton))),
13
+ React.createElement(BottomSheetBaseHeader, __assign({}, headerProps, { className: cnDialogBottomSheet('Header', [headerProps === null || headerProps === void 0 ? void 0 : headerProps.className]) }), !hideCloseButton && (React.createElement("div", { className: cnDialogBottomSheet('CloseButton') }, closeButton))),
14
14
  children));
15
15
  });
16
16
  DialogBottomSheet.displayName = 'DialogBottomSheet';
@@ -1,6 +1,6 @@
1
1
  import type { ReactNode } from 'react';
2
2
  import type { ExtendableProps } from '../../../../types/ExtendableProps';
3
- import type { BottomSheetBaseProps } from '../../../BottomSheetBase';
3
+ import type { BottomSheetBaseHeaderProps, BottomSheetBaseProps } from '../../../BottomSheetBase';
4
4
  import type { DialogVariant, DialogSizeAllVariants } from '../../entities';
5
5
  import type { DialogRef } from '../../types';
6
6
  export type DialogBottomSheetRef = DialogRef;
@@ -12,4 +12,5 @@ export type DialogBottomSheetProps = ExtendableProps<{
12
12
  hideCloseButton: boolean | undefined;
13
13
  className: string | undefined;
14
14
  onClose: (() => void) | undefined;
15
+ headerProps?: Omit<BottomSheetBaseHeaderProps, 'children'>;
15
16
  }, Omit<BottomSheetBaseProps, 'snaps'>>;
@@ -1,3 +1,4 @@
1
- export * from './DialogFooter';
2
1
  export * from './entities';
2
+ export * from './constants';
3
+ export * from './DialogFooter';
3
4
  export * from './types';
@@ -1,3 +1,4 @@
1
- export * from './DialogFooter';
2
1
  export * from './entities';
2
+ export * from './constants';
3
+ export * from './DialogFooter';
3
4
  export * from './types';
@@ -1,2 +1,3 @@
1
+ export * from './constants';
1
2
  export * from './DialogHeader';
2
3
  export * from './types';