@charcuterie/ui 4.26.2 → 4.27.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.
- package/dist/ColorPicker/ColorPicker.d.ts +74 -0
- package/dist/ColorPicker/ColorPicker.d.ts.map +1 -0
- package/dist/ColorPicker/ColorPicker.js +133 -0
- package/dist/ColorPicker/ColorPicker.js.map +1 -0
- package/dist/ColorPicker/ColorPickerCustomPanel.d.ts +35 -0
- package/dist/ColorPicker/ColorPickerCustomPanel.d.ts.map +1 -0
- package/dist/ColorPicker/ColorPickerCustomPanel.js +93 -0
- package/dist/ColorPicker/ColorPickerCustomPanel.js.map +1 -0
- package/dist/ColorPicker/parseHexColor.d.ts +17 -0
- package/dist/ColorPicker/parseHexColor.d.ts.map +1 -0
- package/dist/ColorPicker/parseHexColor.js +31 -0
- package/dist/ColorPicker/parseHexColor.js.map +1 -0
- package/dist/SegmentedControl/SegmentedOption.js +1 -1
- package/dist/SegmentedControl/SegmentedOption.js.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/ColorPicker/ColorPicker.mdx +70 -0
- package/src/ColorPicker/ColorPicker.stories.tsx +289 -0
- package/src/ColorPicker/ColorPicker.test.tsx +385 -0
- package/src/ColorPicker/ColorPicker.tsx +347 -0
- package/src/ColorPicker/ColorPickerCustomPanel.tsx +224 -0
- package/src/ColorPicker/parseHexColor.ts +37 -0
- package/src/SegmentedControl/SegmentedControl.stories.tsx +41 -0
- package/src/SegmentedControl/SegmentedControl.test.tsx +38 -3
- package/src/SegmentedControl/SegmentedOption.tsx +1 -1
- package/src/index.ts +6 -0
- package/src/sourceRules.test.ts +3 -1
|
@@ -66,7 +66,7 @@ export const SegmentedOption = ({
|
|
|
66
66
|
<button
|
|
67
67
|
aria-checked={isChecked}
|
|
68
68
|
className={toClassName(
|
|
69
|
-
"cursor-pointer rounded-sm border border-transparent font-medium tabular-nums transition-colors duration-(--duration-fast) ease-standard",
|
|
69
|
+
"inline-flex cursor-pointer items-center justify-center rounded-sm border border-transparent font-medium tabular-nums transition-colors duration-(--duration-fast) ease-standard",
|
|
70
70
|
// In a very narrow board, three full labels cannot share
|
|
71
71
|
// one row. The minimum lets two fit, then the final option
|
|
72
72
|
// takes a full second row instead of wrapping its label or
|
package/src/index.ts
CHANGED
|
@@ -121,6 +121,12 @@ export type { ChartProps } from "./Chart/Chart.tsx"
|
|
|
121
121
|
export { Chart } from "./Chart/Chart.tsx"
|
|
122
122
|
export type { CheckboxProps } from "./Checkbox/Checkbox.tsx"
|
|
123
123
|
export { Checkbox } from "./Checkbox/Checkbox.tsx"
|
|
124
|
+
export type {
|
|
125
|
+
ColorPickerProps,
|
|
126
|
+
ColorPreset,
|
|
127
|
+
} from "./ColorPicker/ColorPicker.tsx"
|
|
128
|
+
export { ColorPicker } from "./ColorPicker/ColorPicker.tsx"
|
|
129
|
+
export { parseHexColor } from "./ColorPicker/parseHexColor.ts"
|
|
124
130
|
export type { ColorSchemeSwitcherProps } from "./ColorSchemeSwitcher/ColorSchemeSwitcher.tsx"
|
|
125
131
|
export { ColorSchemeSwitcher } from "./ColorSchemeSwitcher/ColorSchemeSwitcher.tsx"
|
|
126
132
|
export type {
|
package/src/sourceRules.test.ts
CHANGED
|
@@ -627,7 +627,9 @@ test("the barrel is the only place components are re-exported", async () => {
|
|
|
627
627
|
// and whereabouts each drew it by hand. `GroupedListRow.tsx` is its
|
|
628
628
|
// member and stays out of this count by the `<Name>/<Name>.tsx` rule.
|
|
629
629
|
// CommandPalette composes Modal and SearchInput into the launcher.
|
|
630
|
-
|
|
630
|
+
// ColorPicker composes Combobox and Swatch with a custom-color panel;
|
|
631
|
+
// `ColorPickerCustomPanel.tsx` is its member.
|
|
632
|
+
expect(componentNames.length).toBe(80)
|
|
631
633
|
|
|
632
634
|
for (const name of componentNames) {
|
|
633
635
|
expect(barrel).toContain(`export { ${name} }`)
|