@capillarytech/blaze-ui 5.21.0 → 5.22.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 (177) hide show
  1. package/CapLanguageProvider/actions.js +125 -0
  2. package/CapLanguageProvider/actions.js.map +1 -0
  3. package/CapLanguageProvider/constants.js +37 -0
  4. package/CapLanguageProvider/constants.js.map +1 -0
  5. package/package.json +1 -1
  6. package/CapActionBar/README.md +0 -11
  7. package/CapAdvancedIcon/README.md +0 -185
  8. package/CapAdvancedIcon/use-cases.md +0 -44
  9. package/CapAlert/README.md +0 -144
  10. package/CapAppNotEnabled/README.md +0 -84
  11. package/CapAskAira/README.md +0 -328
  12. package/CapBanner/README.md +0 -4
  13. package/CapBlock/README.md +0 -175
  14. package/CapBorderedBox/Status.md +0 -40
  15. package/CapCSVFileUploader/README.md +0 -124
  16. package/CapCSVFileUploader/Status.md +0 -47
  17. package/CapCard/README.md +0 -85
  18. package/CapCard/Status.md +0 -41
  19. package/CapCardBox/README.md +0 -169
  20. package/CapCardBox/Status.md +0 -52
  21. package/CapCarousel/README.md +0 -190
  22. package/CapCarousel/Status.md +0 -73
  23. package/CapCheckbox/README.md +0 -254
  24. package/CapCheckbox/Status.md +0 -41
  25. package/CapColorPicker/README.md +0 -112
  26. package/CapColorPicker/Status.md +0 -52
  27. package/CapColorPicker/tests/USE_CASES_ANALYSIS.md +0 -92
  28. package/CapColoredTag/README.md +0 -167
  29. package/CapColoredTag/Status.md +0 -49
  30. package/CapConditionPreview/MIGRATION_ANALYSIS.md +0 -70
  31. package/CapConditionPreview/README.md +0 -40
  32. package/CapConditionPreview/tests/USE_CASES_CapConditionPreview.md +0 -65
  33. package/CapCustomCard/README.md +0 -182
  34. package/CapCustomCard/Status.md +0 -40
  35. package/CapCustomCarousel/Status.md +0 -69
  36. package/CapCustomCheckboxList/README.md +0 -178
  37. package/CapCustomCheckboxList/Status.md +0 -52
  38. package/CapCustomCheckboxList/tests/USE_CASES_ANALYSIS.md +0 -174
  39. package/CapCustomList/README.md +0 -117
  40. package/CapCustomList/Status.md +0 -77
  41. package/CapCustomList/tests/USE_CASES_ANALYSIS.md +0 -124
  42. package/CapCustomSelect/README.md +0 -38
  43. package/CapDatePicker/README.md +0 -139
  44. package/CapDateRangePicker/README.md +0 -159
  45. package/CapDateTimePicker/README.md +0 -136
  46. package/CapDateTimeRangePicker/README.md +0 -243
  47. package/CapDivider/README.md +0 -122
  48. package/CapDrawer/README.md +0 -207
  49. package/CapDrawer/Status.md +0 -52
  50. package/CapDrawer/tests/MISSING_USE_CASES.md +0 -170
  51. package/CapDropdown/README.md +0 -515
  52. package/CapDropdown/Status.md +0 -45
  53. package/CapDropdown/tests/USE_CASES_ANALYSIS.md +0 -137
  54. package/CapError/README.md +0 -88
  55. package/CapErrorBoundary/CapErrorBoundary-use-cases.md +0 -89
  56. package/CapErrorBoundary/README.md +0 -150
  57. package/CapErrorStateIllustration/README.md +0 -222
  58. package/CapErrorStateIllustration/USE_CASES.md +0 -33
  59. package/CapExpressionEditor/README.md +0 -32
  60. package/CapForm/README.md +0 -132
  61. package/CapForm/Status.md +0 -40
  62. package/CapForm/tests/PHASE1_UNFULFILLED_USE_CASES.md +0 -113
  63. package/CapForm/tests/USE_CASES_ANALYSIS.md +0 -119
  64. package/CapFormItem/README.md +0 -320
  65. package/CapFormItem/Status.md +0 -73
  66. package/CapFormItem/tests/USE_CASES_ANALYSIS.md +0 -84
  67. package/CapGraph/README.md +0 -69
  68. package/CapGraph/USE_CASES.md +0 -66
  69. package/CapHamburgerMenu/README.md +0 -234
  70. package/CapHamburgerMenu/USE_CASES.md +0 -48
  71. package/CapHeader/Status.md +0 -41
  72. package/CapHeading/README.md +0 -220
  73. package/CapHeading/Status.md +0 -41
  74. package/CapIcon/README.md +0 -207
  75. package/CapIllustration/Status.md +0 -41
  76. package/CapImage/README.md +0 -50
  77. package/CapImportMFEComponent/README.md +0 -121
  78. package/CapInfoNote/Status.md +0 -40
  79. package/CapInfoNote/tests/USE_CASES_ANALYSIS.md +0 -114
  80. package/CapInput/README.md +0 -196
  81. package/CapInput/Status.md +0 -123
  82. package/CapInput/tests/USE_CASES_ANALYSIS.md +0 -169
  83. package/CapLanguageProvider/CapLanguageProvider-use-cases.md +0 -56
  84. package/CapLanguageProvider/README.md +0 -206
  85. package/CapLevelGraphRenderer/CapLevelGraphRenderer-test-cases.md +0 -50
  86. package/CapLevelGraphRenderer/README.md +0 -123
  87. package/CapLevelGraphRenderer/Tooltip_MIGRATION_ANALYSIS.md +0 -120
  88. package/CapLink/README.md +0 -203
  89. package/CapLink/Status.md +0 -32
  90. package/CapLink/tests/CapLink.missingUseCases.md +0 -95
  91. package/CapList/README.md +0 -129
  92. package/CapList/Status.md +0 -69
  93. package/CapListLayout/README.md +0 -7
  94. package/CapLogin/README.md +0 -7
  95. package/CapMenu/README.md +0 -86
  96. package/CapModal/README.md +0 -357
  97. package/CapModal/Status.md +0 -52
  98. package/CapModal/tests/USE_CASES_GAPS.md +0 -207
  99. package/CapMultiSelect/README.md +0 -170
  100. package/CapMultiSelect/tests/USE_CASES_ANALYSIS.md +0 -29
  101. package/CapMultiSelectDatePicker/README.md +0 -11
  102. package/CapNavigation/README.md +0 -72
  103. package/CapNotification/README.md +0 -228
  104. package/CapNotificationDropdown/README.md +0 -5
  105. package/CapPopover/README.md +0 -234
  106. package/CapProgress/Status.md +0 -40
  107. package/CapRadio/Status.md +0 -54
  108. package/CapRadioButton/README.md +0 -152
  109. package/CapRadioButton/Status.md +0 -70
  110. package/CapRadioButton/tests/USE_CASES_ANALYSIS.md +0 -120
  111. package/CapRadioCard/README.md +0 -161
  112. package/CapRadioCard/Status.md +0 -78
  113. package/CapRadioGroup/README.md +0 -141
  114. package/CapRadioGroup/Status.md +0 -59
  115. package/CapReorderComponent/README.md +0 -179
  116. package/CapReorderComponent/Status.md +0 -41
  117. package/CapRoadMap/README.md +0 -126
  118. package/CapRoadMap/Status.md +0 -53
  119. package/CapRoadMap/tests/USE_CASE_GAPS.md +0 -92
  120. package/CapRow/README.md +0 -424
  121. package/CapSKUUploader/README.md +0 -189
  122. package/CapSKUUploader/Status.md +0 -66
  123. package/CapSecondaryTopBar/README.md +0 -7
  124. package/CapSelect/README.md +0 -243
  125. package/CapSelectFilter/README.md +0 -121
  126. package/CapShape/README.md +0 -96
  127. package/CapShape/Status.md +0 -36
  128. package/CapShape/tests/USE_CASES_ANALYSIS.md +0 -120
  129. package/CapSideBar/README.md +0 -298
  130. package/CapSideBar/Status.md +0 -5
  131. package/CapSlideBox/README.md +0 -68
  132. package/CapSlider/README.md +0 -423
  133. package/CapSlider/Status.md +0 -48
  134. package/CapSlider/tests/TEST_COVERAGE.md +0 -118
  135. package/CapSnackBar/README.md +0 -222
  136. package/CapSnackBar/Status.md +0 -41
  137. package/CapSomethingWentWrong/README.md +0 -97
  138. package/CapSplit/README.md +0 -19
  139. package/CapStatisticCard/README.md +0 -138
  140. package/CapStatus/README.md +0 -148
  141. package/CapStatus/Status.md +0 -40
  142. package/CapSteps/Status.md +0 -40
  143. package/CapStepsAccordian/README.md +0 -305
  144. package/CapStepsAccordian/Status.md +0 -48
  145. package/CapSupportVideosWrapper/README.md +0 -14
  146. package/CapSwitch/README.md +0 -351
  147. package/CapTab/README.md +0 -406
  148. package/CapTab/Status.md +0 -104
  149. package/CapTab/tests/USE_CASE_GAPS.md +0 -143
  150. package/CapTabV3/ANALYSIS.md +0 -60
  151. package/CapTabV3/README.md +0 -156
  152. package/CapTabV3/Status.md +0 -52
  153. package/CapTabV3/tests/USE_CASE_GAPS.md +0 -149
  154. package/CapTable/README.md +0 -160
  155. package/CapTable/Status.md +0 -41
  156. package/CapTag/README.md +0 -16
  157. package/CapTagDropdown/README.md +0 -171
  158. package/CapTagDropdown/Status.md +0 -55
  159. package/CapTimePicker/README.md +0 -170
  160. package/CapTooltip/README.md +0 -336
  161. package/CapTooltipWithInfo/Status.md +0 -75
  162. package/CapTopBar/README.md +0 -146
  163. package/CapTree/README.md +0 -124
  164. package/CapTree/Status.md +0 -48
  165. package/CapTree/tests/STATUS.md +0 -154
  166. package/CapTreeSelect/README.md +0 -217
  167. package/CapTreeSelect/Status.md +0 -52
  168. package/CapTruncateList/README.md +0 -13
  169. package/CapUnifiedSelect/README.md +0 -40
  170. package/CapUploader/README.md +0 -313
  171. package/CapUploader/Status.md +0 -76
  172. package/CapUploader/tests/USE_CASES_ANALYSIS.md +0 -225
  173. package/CapUserProfile/README.md +0 -105
  174. package/CapUserProfile/Status.md +0 -95
  175. package/CapVirtualList/README.md +0 -162
  176. package/CapVirtualList/Status.md +0 -71
  177. package/assets/HOCs/ComponentWithLabelHOC/README.md +0 -230
@@ -1,423 +0,0 @@
1
- # CapSlider
2
-
3
- A slider component built on Ant Design v6 with Capillary-specific styling and custom tip formatter support.
4
-
5
- ## Summary of Changes from cap-ui-library
6
-
7
- The `CapSlider` component has been migrated from `cap-ui-library` to `blaze-ui` with the following updates:
8
-
9
- - **TypeScript**: Full TypeScript implementation with proper type definitions
10
- - **Ant Design v6**: Updated to use Ant Design v6 APIs while maintaining backward compatibility
11
- - **Functional Component**: Converted from class component to functional component
12
- - **SCSS Modules**: Converted from regular SCSS to SCSS modules
13
- - **Theme Tokens**: Migrated color overrides to Ant Design theme tokens
14
- - **Backward Compatible**: All deprecated props from Ant Design v3 still work with console warnings
15
-
16
- ## Breaking Changes
17
-
18
- **No breaking changes from cap-ui-library v8.x**
19
-
20
- The component maintains backward compatibility with deprecated props. However, deprecated props will show console warnings in development mode and should be migrated to the new API.
21
-
22
- ## Prop Changes
23
-
24
- ### New Props (v6 API)
25
-
26
- | Prop | Type | Default | Description |
27
- |------|------|---------|-------------|
28
- | `tooltip` | `{ formatter?: (value?: number) => React.ReactNode, ... }` | `undefined` | Tooltip configuration object (v6 API) |
29
-
30
- ### Deprecated Props (Still Supported)
31
-
32
- The following props are deprecated but still work for backward compatibility. They will show console warnings in development mode:
33
-
34
- #### Ant Design Slider Component Props
35
-
36
- These props are deprecated Ant Design `Slider` component props that have been replaced in v6:
37
-
38
- | Deprecated Prop | Type | Status | Replacement | Ant Design Component |
39
- |----------------|------|--------|-------------|---------------------|
40
- | `tipFormatter` | `((value?: number) => React.ReactNode) \| null` | ⚠️ Deprecated | Use `tooltip.formatter` instead | Slider |
41
- | `tooltipPlacement` | `string` | ⚠️ Deprecated | Use `tooltip.placement` instead | Slider |
42
- | `tooltipVisible` | `boolean` | ⚠️ Deprecated | Use `tooltip.open` instead | Slider |
43
- | `tooltipPrefixCls` | `string` | ⚠️ Deprecated | Use `tooltip.prefixCls` instead | Slider |
44
-
45
- **Reference**: These deprecations follow Ant Design v6 migration patterns documented in `ANTD_V6_MIGRATION.md` and `MIGRATION_CHANGELOG_TEMPLATE.md`.
46
-
47
- #### Cap Component Props
48
-
49
- | Deprecated Prop | Type | Status | Replacement | Notes |
50
- |----------------|------|--------|-------------|-------|
51
- | `type` | `'ratio' \| string` | ⚠️ Deprecated | Use `tooltip.formatter` instead | Cap-specific convenience prop |
52
-
53
- **Note**: Deprecated props will be removed in v10.0.0. Please migrate to the new prop names.
54
-
55
- ### Other Props
56
-
57
- | Prop | Type | Default | Description |
58
- |------|------|---------|-------------|
59
- | `value` | `number \| [number, number]` | `undefined` | Current value (controlled mode) |
60
- | `defaultValue` | `number \| [number, number]` | `undefined` | Default value (uncontrolled mode) |
61
- | `min` | `number` | `0` | Minimum value |
62
- | `max` | `number` | `100` | Maximum value |
63
- | `step` | `number \| null` | `1` | Step value |
64
- | `marks` | `Record<number, React.ReactNode>` | `undefined` | Marks on the slider |
65
- | `range` | `boolean` | `false` | Whether to use range slider |
66
- | `disabled` | `boolean` | `false` | Whether slider is disabled |
67
- | `vertical` | `boolean` | `false` | Whether slider is vertical |
68
- | `reverse` | `boolean` | `false` | Whether to reverse slider |
69
- | `included` | `boolean` | `true` | Whether marks are included in track |
70
- | `onChange` | `(value: number \| [number, number]) => void` | `undefined` | Callback when value changes |
71
- | `onAfterChange` | `(value: number \| [number, number]) => void` | `undefined` | Callback after value changes |
72
- | `sliderRaleColor` | `string` | `undefined` | Whether to apply slider rail color styling (note: typo preserved for backward compatibility) |
73
- | `className` | `string` | `undefined` | Additional CSS class name |
74
- | `children` | `React.ReactNode` | `undefined` | Slider children (marks or custom elements) |
75
-
76
- **Note**: The component accepts all other Ant Design v6 `Slider` props. See [Ant Design Slider documentation](https://ant.design/components/slider) for complete prop list.
77
-
78
- ## API Changes
79
-
80
- ### Ant Design Slider Component Prop Changes (v6 API)
81
-
82
- In Ant Design v6, several Slider component props have been consolidated into a `tooltip` object prop:
83
-
84
- #### tipFormatter → tooltip.formatter
85
-
86
- **Before (deprecated):**
87
- ```tsx
88
- <CapSlider
89
- tipFormatter={(value) => `${value}%`}
90
- defaultValue={50}
91
- />
92
- ```
93
-
94
- **After (recommended):**
95
- ```tsx
96
- <CapSlider
97
- tooltip={{ formatter: (value) => `${value}%` }}
98
- defaultValue={50}
99
- />
100
- ```
101
-
102
- #### tooltipPlacement → tooltip.placement
103
-
104
- **Before (deprecated):**
105
- ```tsx
106
- <CapSlider
107
- tipFormatter={(value) => `${value}%`}
108
- tooltipPlacement="top"
109
- defaultValue={50}
110
- />
111
- ```
112
-
113
- **After (recommended):**
114
- ```tsx
115
- <CapSlider
116
- tooltip={{
117
- formatter: (value) => `${value}%`,
118
- placement: 'top'
119
- }}
120
- defaultValue={50}
121
- />
122
- ```
123
-
124
- #### tooltipVisible → tooltip.open
125
-
126
- **Before (deprecated):**
127
- ```tsx
128
- <CapSlider
129
- tipFormatter={(value) => `${value}%`}
130
- tooltipVisible={true}
131
- defaultValue={50}
132
- />
133
- ```
134
-
135
- **After (recommended):**
136
- ```tsx
137
- <CapSlider
138
- tooltip={{
139
- formatter: (value) => `${value}%`,
140
- open: true
141
- }}
142
- defaultValue={50}
143
- />
144
- ```
145
-
146
- #### tooltipPrefixCls → tooltip.prefixCls
147
-
148
- **Before (deprecated):**
149
- ```tsx
150
- <CapSlider
151
- tipFormatter={(value) => `${value}%`}
152
- tooltipPrefixCls="custom-tooltip"
153
- defaultValue={50}
154
- />
155
- ```
156
-
157
- **After (recommended):**
158
- ```tsx
159
- <CapSlider
160
- tooltip={{
161
- formatter: (value) => `${value}%`,
162
- prefixCls: 'custom-tooltip'
163
- }}
164
- defaultValue={50}
165
- />
166
- ```
167
-
168
- ### Cap Component Prop Changes
169
-
170
- #### Type Prop Migration
171
-
172
- The `type` prop was a Cap-specific convenience prop that translated to `tipFormatter`. It's now deprecated:
173
-
174
- **Before (deprecated):**
175
- ```tsx
176
- <CapSlider
177
- type="ratio"
178
- defaultValue={30}
179
- />
180
- ```
181
-
182
- **After (recommended):**
183
- ```tsx
184
- <CapSlider
185
- tooltip={{ formatter: (value) => value !== undefined ? `${value} | ${100 - value}` : '' }}
186
- defaultValue={30}
187
- />
188
- ```
189
-
190
- ## Backward Compatibility
191
-
192
- The component maintains backward compatibility for deprecated props:
193
-
194
- ### Ant Design Slider Component Props
195
-
196
- - **`tipFormatter` prop**: Still works but logs a deprecation warning in development. Use `tooltip.formatter` instead.
197
- - **`tooltipPlacement` prop**: Still works but is deprecated. Use `tooltip.placement` instead.
198
- - **`tooltipVisible` prop**: Still works but is deprecated. Use `tooltip.open` instead.
199
- - **`tooltipPrefixCls` prop**: Still works but is deprecated. Use `tooltip.prefixCls` instead.
200
-
201
- **Note**: Deprecated Ant Design Slider props (`tooltipPlacement`, `tooltipVisible`, `tooltipPrefixCls`) are passed directly to the underlying Ant Design `Slider` component. Ant Design v6 may still accept these props but they are deprecated and should be migrated to the `tooltip` object API.
202
-
203
- ### Cap Component Props
204
-
205
- - **`type` prop**: Still works but logs a deprecation warning in development. Use `tooltip.formatter` instead.
206
-
207
- **Note**: If both `tooltip.formatter` and `tipFormatter` are provided, `tooltip.formatter` takes precedence. If `type` is provided, it will be translated to a formatter function and used if no other formatter is specified.
208
-
209
- ## Code Examples
210
-
211
- ### Basic Usage
212
-
213
- ```tsx
214
- import { CapSlider } from '@capillarytech/blaze-ui';
215
-
216
- function MyComponent() {
217
- const [value, setValue] = useState(50);
218
-
219
- return (
220
- <CapSlider
221
- value={value}
222
- onChange={setValue}
223
- />
224
- );
225
- }
226
- ```
227
-
228
- ### Uncontrolled Mode
229
-
230
- ```tsx
231
- <CapSlider
232
- defaultValue={30}
233
- onChange={(value) => {
234
- console.log('Slider value:', value);
235
- }}
236
- />
237
- ```
238
-
239
- ### Range Slider
240
-
241
- ```tsx
242
- <CapSlider
243
- range
244
- defaultValue={[20, 80]}
245
- onChange={(values) => {
246
- console.log('Range:', values);
247
- }}
248
- />
249
- ```
250
-
251
- ### With Marks
252
-
253
- ```tsx
254
- <CapSlider
255
- marks={{
256
- 0: '0°C',
257
- 26: '26°C',
258
- 37: '37°C',
259
- 100: '100°C',
260
- }}
261
- defaultValue={26}
262
- />
263
- ```
264
-
265
- ### Custom Tooltip Formatter (v6 API)
266
-
267
- ```tsx
268
- <CapSlider
269
- tooltip={{
270
- formatter: (value) => value !== undefined ? `$${value}` : ''
271
- }}
272
- defaultValue={50}
273
- />
274
- ```
275
-
276
- ### Ratio Type (Deprecated - Use tooltip.formatter instead)
277
-
278
- ```tsx
279
- // ⚠️ Deprecated but still works
280
- <CapSlider
281
- type="ratio"
282
- defaultValue={30}
283
- />
284
-
285
- // ✅ Recommended
286
- <CapSlider
287
- tooltip={{
288
- formatter: (value) => value !== undefined ? `${value} | ${100 - value}` : ''
289
- }}
290
- defaultValue={30}
291
- />
292
- ```
293
-
294
- ### With Custom Rail Color
295
-
296
- ```tsx
297
- <CapSlider
298
- sliderRaleColor="custom"
299
- defaultValue={50}
300
- />
301
- ```
302
-
303
- ### Disabled State
304
-
305
- ```tsx
306
- <CapSlider
307
- defaultValue={50}
308
- disabled
309
- />
310
- ```
311
-
312
- ### Vertical Slider
313
-
314
- ```tsx
315
- <CapSlider
316
- vertical
317
- defaultValue={50}
318
- style={{ height: 200 }}
319
- />
320
- ```
321
-
322
- ### With Step
323
-
324
- ```tsx
325
- <CapSlider
326
- step={10}
327
- defaultValue={30}
328
- />
329
- ```
330
-
331
- ## Migration Steps for Consumers
332
-
333
- ### Step 1: Update Imports
334
-
335
- **Before:**
336
- ```tsx
337
- import { CapSlider } from '@capillarytech/cap-ui-library';
338
- ```
339
-
340
- **After:**
341
- ```tsx
342
- import { CapSlider } from '@capillarytech/blaze-ui';
343
- ```
344
-
345
- ### Step 2: Update Tooltip Configuration (If Using tipFormatter or type)
346
-
347
- **Before:**
348
- ```tsx
349
- <CapSlider
350
- tipFormatter={(value) => `${value}%`}
351
- defaultValue={50}
352
- />
353
-
354
- // or
355
-
356
- <CapSlider
357
- type="ratio"
358
- defaultValue={30}
359
- />
360
- ```
361
-
362
- **After:**
363
- ```tsx
364
- <CapSlider
365
- tooltip={{ formatter: (value) => `${value}%` }}
366
- defaultValue={50}
367
- />
368
-
369
- // or for ratio type
370
-
371
- <CapSlider
372
- tooltip={{
373
- formatter: (value) => value !== undefined ? `${value} | ${100 - value}` : ''
374
- }}
375
- defaultValue={30}
376
- />
377
- ```
378
-
379
- ### Step 3: No Other Changes Required
380
-
381
- All other props and usage patterns remain the same. The component is fully backward compatible.
382
-
383
- ## Import Examples
384
-
385
- ### Default Import
386
-
387
- ```tsx
388
- import CapSlider from '@capillarytech/blaze-ui/components/CapSlider';
389
- ```
390
-
391
- ### Named Import
392
-
393
- ```tsx
394
- import { CapSlider } from '@capillarytech/blaze-ui';
395
- ```
396
-
397
- ### With TypeScript Types
398
-
399
- ```tsx
400
- import { CapSlider } from '@capillarytech/blaze-ui';
401
- import type { CapSliderProps } from '@capillarytech/blaze-ui';
402
-
403
- const props: CapSliderProps = {
404
- defaultValue: 50,
405
- min: 0,
406
- max: 100,
407
- };
408
- ```
409
-
410
- ## Notes
411
-
412
- - **No Breaking Changes**: The component is fully backward compatible with `cap-ui-library` v8.x
413
- - **Deprecated Ant Design Slider Props**: The following Ant Design `Slider` component props are deprecated: `tipFormatter`, `tooltipPlacement`, `tooltipVisible`, `tooltipPrefixCls`. These should be migrated to the `tooltip` object API (e.g., `tooltip.formatter`, `tooltip.placement`, `tooltip.open`, `tooltip.prefixCls`). They will be removed in Ant Design v7.
414
- - **Deprecated Cap Props**: `type` prop is deprecated but still supported. It will be removed in v10.0.0.
415
- - **Tooltip Configuration**: In Ant Design v6, tooltip configuration moved to a `tooltip` object prop. See [Ant Design Slider documentation](https://ant.design/components/slider) for complete `tooltip` API.
416
- - **Rail Color**: The `sliderRaleColor` prop name contains a typo but is preserved for backward compatibility
417
- - **Styling**: Uses SCSS modules with theme tokens for colors and custom CSS for dimensions/positioning
418
-
419
- ## Related Components
420
-
421
- - `CapInput` - Input component for numeric values
422
- - `CapInputNumber` - Number input component
423
- - `CapSwitch` - Switch component for boolean toggles
@@ -1,48 +0,0 @@
1
- # Migration Status: CapSlider
2
-
3
- **Last Updated**: 2026-02-04 09:56:53
4
-
5
- ## Migration Steps
6
-
7
- - [x] **Step 0**: Setup branch and remote tracking
8
- - [x] **Step 1**: Migration Prompt 1 (Main migration)
9
- - [x] **Step 1.5**: Export component in blaze-ui/components/index.ts
10
- - [x] **Step 2**: Migration Prompt 2 (Storybook support)
11
- - [x] **Step 2.5**: Verify deprecated props and prop changes (REQUIRED - enforced)
12
- - [x] **Step 3**: Migration Prompt 3 (Unit tests)
13
- - [x] **Step 4**: Migration Prompt 4 (Visual test cases)
14
- - [x] **Step 5**: Linting (ESLint)
15
- - [x] **Step 6**: Pre-build Validation
16
- - [x] **Step 7**: Build blaze-ui
17
- - [x] **Step 8**: Visual Testing
18
- - [ ] **Step 9**: CSS Analysis (if mismatches found)
19
- - [ ] **Step 9.5**: CSS Analysis Completed
20
- - [x] **Step 10**: Git Commit & Push to branch (pre-commit hook will run tests)
21
- - [x] **Step 11**: Create Pull Request
22
-
23
- ## Deprecated Props Verification
24
-
25
- _No deprecated props verification results yet._
26
-
27
- **Note**: Step 2.5 is REQUIRED and enforced.
28
- - Focus: **Ant Design component prop changes** (e.g., Dropdown, Input, Alert, Tooltip, etc.)
29
- - Reference: MIGRATION_CHANGELOG_TEMPLATE.md for format, ANTD_V6_MIGRATION.md for Ant Design deprecated APIs
30
- - Skip: If original component doesn't exist in cap-ui-library
31
- - All deprecated Ant Design props and prop changes must be documented before proceeding.
32
-
33
- ## Visual Testing Results
34
-
35
- **Last Test**: 2026-02-04 09:56:53
36
- **Maximum Mismatch**: 8.33%
37
-
38
- ### Mismatched Variants:
39
- - tooltip-hover (with 3 interactions):8.33%
40
-
41
-
42
- ## CSS Fixes Applied
43
-
44
- _No CSS fixes applied yet._
45
-
46
- ## Notes
47
-
48
- _No notes yet._
@@ -1,118 +0,0 @@
1
- # CapSlider Test Coverage Summary
2
-
3
- ## Phase 0: Use Cases Extraction
4
- **Status**: ⚠️ **Could not access Google Sheets MCP server**
5
- - Attempted to access spreadsheet via `google_sheets` MCP server
6
- - Server was not available/configured
7
- - Tests were created based on component code, README, and Storybook stories
8
-
9
- ## Phase 1: Missing Use Cases Analysis
10
- **Status**: ⚠️ **Cannot determine without Google Sheets data**
11
-
12
- Without access to the use cases spreadsheet, I cannot identify specific use cases the component is NOT fulfilling. However, based on the component implementation review:
13
-
14
- ### Component Capabilities (Verified):
15
- - ✅ Single and range slider modes
16
- - ✅ Controlled and uncontrolled modes
17
- - ✅ Custom min/max/step values
18
- - ✅ Marks/labels support
19
- - ✅ Tooltip formatters (v6 API and deprecated)
20
- - ✅ Disabled, vertical, reverse, included props
21
- - ✅ Backward compatibility for deprecated props
22
- - ✅ Custom className and styling
23
- - ✅ Children support
24
-
25
- ### Potential Gaps (Requires Google Sheets verification):
26
- - Unknown: Specific business use cases from spreadsheet
27
- - Unknown: Edge cases or requirements not in standard Ant Design Slider API
28
-
29
- ## Phase 2: Test Implementation
30
- **Status**: ✅ **Complete**
31
-
32
- ### Test File Structure:
33
- ```
34
- components/CapSlider/tests/
35
- ├── CapSlider.test.tsx (Main test file)
36
- └── CapSlider.mockData.ts (Mock data and helpers)
37
- ```
38
-
39
- ### Test Coverage Areas:
40
-
41
- 1. **Default rendering and initialization** ✅
42
- - Basic rendering
43
- - DisplayName verification
44
- - Default value handling
45
-
46
- 2. **Prop variations** ✅
47
- - Value and defaultValue (single and range)
48
- - Min, max, step values
49
- - Range, disabled, vertical, reverse, included
50
- - Marks with custom labels
51
- - Tooltip formatters (v6 API)
52
- - Deprecated props (tipFormatter, type)
53
- - className and sliderRaleColor
54
- - Children support
55
-
56
- 3. **User interactions** ✅
57
- - onChange callback acceptance
58
- - onAfterChange callback acceptance
59
- - Range slider callbacks
60
-
61
- 4. **Edge cases** ✅
62
- - Empty/null values
63
- - Boundary values (min/max)
64
- - Step edge cases (null, very small, large)
65
- - Undefined values
66
-
67
- 5. **Accessibility** ✅
68
- - Slider role verification
69
- - Disabled state accessibility
70
- - Focusable elements
71
-
72
- 6. **Backward compatibility** ✅
73
- - Deprecated tipFormatter prop
74
- - Deprecated type prop
75
- - Prop priority (tooltip.formatter > tipFormatter > type)
76
- - Deprecation warnings in development
77
-
78
- 7. **Data flow and state management** ✅
79
- - Controlled mode updates
80
- - Uncontrolled mode state
81
- - Value prop changes
82
-
83
- 8. **Conditional rendering logic** ✅
84
- - Single vs range slider
85
- - Tooltip config application
86
- - Deprecated prop fallbacks
87
-
88
- 9. **Integration tests** ✅
89
- - All props combined
90
- - Range slider with all props
91
-
92
- ### Test Statistics:
93
- - **Total test cases**: 60+
94
- - **Test patterns used**:
95
- - `it.each()` for repetitive prop variations
96
- - Reusable helper functions (`renderSlider`, `getSlider`)
97
- - Grouped `describe()` blocks by functionality
98
- - Mock data in separate file for reusability
99
-
100
- ### Code Quality:
101
- - ✅ DRY principles (reusable helpers)
102
- - ✅ No component source code modifications
103
- - ✅ Uses @testing-library/react
104
- - ✅ No mocking of Cap UI components
105
- - ✅ Focuses on functional behavior
106
- - ✅ No styling/CSS class testing
107
-
108
- ## Next Steps:
109
- 1. **Access Google Sheets** to complete Phase 0 and Phase 1
110
- 2. **Run tests** to verify coverage percentage
111
- 3. **Add missing use case tests** if any gaps are identified from spreadsheet
112
- 4. **Verify 90%+ coverage** target is met
113
-
114
- ## Notes:
115
- - Tests are designed to be maintainable and follow existing codebase patterns
116
- - All deprecated props are tested for backward compatibility
117
- - Edge cases cover boundary conditions and null/undefined handling
118
- - Integration tests verify complex prop combinations work correctly