@allxsmith/bestax-bulma 5.54.1 → 5.56.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.
- package/dist/bestax.css +1 -1
- package/dist/bestax.css.map +1 -1
- package/dist/esm/components/Command.js +22 -22
- package/dist/esm/components/Command.js.map +1 -1
- package/dist/esm/components/DataTable.js +215 -0
- package/dist/esm/components/DataTable.js.map +1 -0
- package/dist/esm/components/useDataTable.js +509 -0
- package/dist/esm/components/useDataTable.js.map +1 -0
- package/dist/esm/elements/ColorSwatch.js +49 -0
- package/dist/esm/elements/ColorSwatch.js.map +1 -0
- package/dist/esm/elements/RingProgress.js +3 -3
- package/dist/esm/elements/Td.js +4 -2
- package/dist/esm/elements/Td.js.map +1 -1
- package/dist/esm/elements/Th.js +13 -5
- package/dist/esm/elements/Th.js.map +1 -1
- package/dist/esm/elements/Tr.js.map +1 -1
- package/dist/esm/form/ColorInput.js +68 -0
- package/dist/esm/form/ColorInput.js.map +1 -0
- package/dist/esm/form/ColorInputBase.js +198 -0
- package/dist/esm/form/ColorInputBase.js.map +1 -0
- package/dist/esm/form/ColorPicker.js +524 -0
- package/dist/esm/form/ColorPicker.js.map +1 -0
- package/dist/esm/form/Combobox.js +18 -18
- package/dist/esm/form/Combobox.js.map +1 -1
- package/dist/esm/form/Dropzone.js +524 -0
- package/dist/esm/form/Dropzone.js.map +1 -0
- package/dist/esm/form/_colorInternals/EyeDropperButton.js +40 -0
- package/dist/esm/form/_colorInternals/EyeDropperButton.js.map +1 -0
- package/dist/esm/form/_colorInternals/colorMath.js +292 -0
- package/dist/esm/form/_colorInternals/colorMath.js.map +1 -0
- package/dist/esm/form/_colorInternals/pickerState.js +160 -0
- package/dist/esm/form/_colorInternals/pickerState.js.map +1 -0
- package/dist/esm/helpers/statusRegion.js +3 -3
- package/dist/esm/helpers/statusRegion.js.map +1 -1
- package/dist/esm/helpers/useFocusTrap.js +2 -2
- package/dist/extras.css +1 -1
- package/dist/extras.css.map +1 -1
- package/dist/index.cjs +3054 -586
- package/dist/index.cjs.map +1 -1
- package/dist/index.esm.js +7 -0
- package/dist/index.esm.js.map +1 -1
- package/dist/types/components/DataTable.d.ts +120 -0
- package/dist/types/components/useDataTable.d.ts +481 -0
- package/dist/types/elements/ColorSwatch.d.ts +54 -0
- package/dist/types/elements/Td.d.ts +9 -1
- package/dist/types/elements/Th.d.ts +14 -2
- package/dist/types/elements/Tr.d.ts +10 -1
- package/dist/types/form/ColorInput.d.ts +76 -0
- package/dist/types/form/ColorInputBase.d.ts +108 -0
- package/dist/types/form/ColorPicker.d.ts +271 -0
- package/dist/types/form/Dropzone.d.ts +138 -0
- package/dist/types/form/_colorInternals/EyeDropperButton.d.ts +8 -0
- package/dist/types/form/_colorInternals/colorMath.d.ts +63 -0
- package/dist/types/form/_colorInternals/pickerState.d.ts +68 -0
- package/dist/types/index.d.ts +8 -0
- package/dist/types-cjs/components/DataTable.d.ts +120 -0
- package/dist/types-cjs/components/useDataTable.d.ts +481 -0
- package/dist/types-cjs/elements/ColorSwatch.d.ts +54 -0
- package/dist/types-cjs/elements/Td.d.ts +9 -1
- package/dist/types-cjs/elements/Th.d.ts +14 -2
- package/dist/types-cjs/elements/Tr.d.ts +10 -1
- package/dist/types-cjs/form/ColorInput.d.ts +76 -0
- package/dist/types-cjs/form/ColorInputBase.d.ts +108 -0
- package/dist/types-cjs/form/ColorPicker.d.ts +271 -0
- package/dist/types-cjs/form/Dropzone.d.ts +138 -0
- package/dist/types-cjs/form/_colorInternals/EyeDropperButton.d.ts +8 -0
- package/dist/types-cjs/form/_colorInternals/colorMath.d.ts +63 -0
- package/dist/types-cjs/form/_colorInternals/pickerState.d.ts +68 -0
- package/dist/types-cjs/index.d.ts +8 -0
- package/dist/versions/bestax-no-dark-mode.css +1 -1
- package/dist/versions/bestax-no-dark-mode.css.map +1 -1
- package/dist/versions/bestax-no-helpers-prefixed.css +1 -1
- package/dist/versions/bestax-no-helpers-prefixed.css.map +1 -1
- package/dist/versions/bestax-no-helpers.css +1 -1
- package/dist/versions/bestax-no-helpers.css.map +1 -1
- package/dist/versions/bestax-prefixed.css +1 -1
- package/dist/versions/bestax-prefixed.css.map +1 -1
- package/package.json +1 -1
- package/src/scss/components/_datatable.scss +152 -0
- package/src/scss/components/_index.scss +1 -0
- package/src/scss/elements/_colorswatch.scss +100 -0
- package/src/scss/elements/_index.scss +1 -0
- package/src/scss/form/_checkbox.scss +53 -0
- package/src/scss/form/_colorinput.scss +109 -0
- package/src/scss/form/_colorpicker.scss +354 -0
- package/src/scss/form/_dropzone.scss +233 -0
- package/src/scss/form/_index.scss +3 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { ColorFormat, Hsva } from './colorMath.js';
|
|
2
|
+
import type { ColorPickerLabels, ColorPickerSwatch } from '../ColorPicker.js';
|
|
3
|
+
/** The labels with each one left out, or empty, at its default. */
|
|
4
|
+
export declare const mergeColorLabels: (labels: ColorPickerLabels | undefined) => Required<ColorPickerLabels>;
|
|
5
|
+
export declare const BLACK: Hsva;
|
|
6
|
+
/**
|
|
7
|
+
* A color read from outside the picker, written as `source`, with the hue
|
|
8
|
+
* and saturation the picker had where the new color has none, so the thumbs
|
|
9
|
+
* don't jump to 0. A gray written as hex, `rgb()` or a name has no hue, so
|
|
10
|
+
* it keeps the picker's; one written as `hsl()` names its hue, which wins.
|
|
11
|
+
* Black has no saturation in the square either way, and keeps the picker's,
|
|
12
|
+
* which writes no differently.
|
|
13
|
+
*/
|
|
14
|
+
export declare const keepingChannels: (next: Hsva, previous: Hsva, source: string) => Hsva;
|
|
15
|
+
/** What a picker's parts read from the picker around them. */
|
|
16
|
+
export interface ColorPickerContextValue {
|
|
17
|
+
/** The color shown, alpha at 1 unless the picker takes alpha. */
|
|
18
|
+
color: Hsva;
|
|
19
|
+
/** The color written in the picker's format. */
|
|
20
|
+
text: string;
|
|
21
|
+
format: ColorFormat;
|
|
22
|
+
alpha: boolean;
|
|
23
|
+
disabled: boolean;
|
|
24
|
+
labels: Required<ColorPickerLabels>;
|
|
25
|
+
swatches: ColorPickerSwatch[] | 'bulma' | undefined;
|
|
26
|
+
eyeDropper: boolean;
|
|
27
|
+
/** Whether a touch screen reader is likely, so both square inputs show. */
|
|
28
|
+
touch: boolean;
|
|
29
|
+
/** Writes a percentage, in the locale of a LocaleProvider when there is one. */
|
|
30
|
+
percent: (value: number) => string;
|
|
31
|
+
/** Writes a hue in degrees, in the locale of a LocaleProvider when there is one. */
|
|
32
|
+
degrees: (value: number) => string;
|
|
33
|
+
/** Sets the color: `onChange`, and `onChangeEnd` too when `end` is set. */
|
|
34
|
+
change: (next: Hsva, end?: boolean) => void;
|
|
35
|
+
/** Ends a drag: `onChangeEnd` with the latest value. */
|
|
36
|
+
end: () => void;
|
|
37
|
+
}
|
|
38
|
+
export declare const ColorPickerContext: import("react").Context<ColorPickerContextValue | null>;
|
|
39
|
+
/** Does nothing, for a part outside a picker and a cancelled eye dropper. */
|
|
40
|
+
export declare const noop: () => void;
|
|
41
|
+
export declare const standalone: ColorPickerContextValue;
|
|
42
|
+
/** The picker around a part, or null with a development warning. */
|
|
43
|
+
export declare function usePicker(part: string): ColorPickerContextValue | null;
|
|
44
|
+
/** What a picker is given: ColorPicker's props, or the ones ColorInput passes on. */
|
|
45
|
+
export interface PickerOptions {
|
|
46
|
+
value: string | undefined;
|
|
47
|
+
defaultValue: string | undefined;
|
|
48
|
+
onChange: ((value: string) => void) | undefined;
|
|
49
|
+
onChangeEnd: ((value: string) => void) | undefined;
|
|
50
|
+
format: ColorFormat;
|
|
51
|
+
alpha: boolean;
|
|
52
|
+
disabled: boolean;
|
|
53
|
+
swatches: ColorPickerSwatch[] | 'bulma' | undefined;
|
|
54
|
+
eyeDropper: boolean;
|
|
55
|
+
labels: ColorPickerLabels | undefined;
|
|
56
|
+
/**
|
|
57
|
+
* Whether the field the picker serves is empty, as ColorInput's can be.
|
|
58
|
+
* The picker still shows a color then, and any change, even to that same
|
|
59
|
+
* color, is reported, so it fills the field.
|
|
60
|
+
*/
|
|
61
|
+
empty?: boolean;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Holds a picker's color and builds what its parts read. Controlled, the
|
|
65
|
+
* color shown follows `value`; a value the picker handed out comes back as
|
|
66
|
+
* the exact color it was, thumbs and all.
|
|
67
|
+
*/
|
|
68
|
+
export declare function useColorPicker({ value, defaultValue, onChange, onChangeEnd, format, alpha, disabled, swatches, eyeDropper, labels, empty, }: PickerOptions): ColorPickerContextValue;
|
|
@@ -32,6 +32,7 @@ export * from './components/Reveal.js';
|
|
|
32
32
|
export * from './components/TreeView.js';
|
|
33
33
|
export * from './components/ScrollArea.js';
|
|
34
34
|
export * from './components/Command.js';
|
|
35
|
+
export * from './components/DataTable.js';
|
|
35
36
|
export * from './elements/Block.js';
|
|
36
37
|
export * from './elements/Box.js';
|
|
37
38
|
export * from './elements/Button.js';
|
|
@@ -39,6 +40,7 @@ export * from './elements/Buttons.js';
|
|
|
39
40
|
export * from './elements/LinkButton.js';
|
|
40
41
|
export * from './elements/ToggleButton.js';
|
|
41
42
|
export * from './elements/Code.js';
|
|
43
|
+
export * from './elements/ColorSwatch.js';
|
|
42
44
|
export * from './elements/Content.js';
|
|
43
45
|
export * from './elements/Delete.js';
|
|
44
46
|
export * from './elements/DescriptionList.js';
|
|
@@ -77,6 +79,7 @@ export * from './form/Checkbox.js';
|
|
|
77
79
|
export * from './form/CheckboxCard.js';
|
|
78
80
|
export * from './form/Checkboxes.js';
|
|
79
81
|
export * from './form/Control.js';
|
|
82
|
+
export * from './form/Dropzone.js';
|
|
80
83
|
export * from './form/Field.js';
|
|
81
84
|
export * from './form/Fieldset.js';
|
|
82
85
|
export * from './form/File.js';
|
|
@@ -91,6 +94,7 @@ export * from './form/Rate.js';
|
|
|
91
94
|
export * from './form/Autocomplete.js';
|
|
92
95
|
export * from './form/Combobox.js';
|
|
93
96
|
export * from './form/Taginput.js';
|
|
97
|
+
export * from './form/ColorPicker.js';
|
|
94
98
|
export { InputBase } from './form/InputBase.js';
|
|
95
99
|
export type { InputBaseProps } from './form/InputBase.js';
|
|
96
100
|
export { SelectBase } from './form/SelectBase.js';
|
|
@@ -119,6 +123,10 @@ export { DateRangeInputBase } from './form/DateRangeInputBase.js';
|
|
|
119
123
|
export type { DateRangeInputBaseProps, DateRangeValue, } from './form/DateRangeInputBase.js';
|
|
120
124
|
export { DateRangeInput } from './form/DateRangeInput.js';
|
|
121
125
|
export type { DateRangeInputProps } from './form/DateRangeInput.js';
|
|
126
|
+
export { ColorInputBase } from './form/ColorInputBase.js';
|
|
127
|
+
export type { ColorInputBaseProps } from './form/ColorInputBase.js';
|
|
128
|
+
export { ColorInput } from './form/ColorInput.js';
|
|
129
|
+
export type { ColorInputProps } from './form/ColorInput.js';
|
|
122
130
|
export { useInsideField, useInsideControl } from './form/FormContext.js';
|
|
123
131
|
export type { FormFieldProps } from './form/fieldProps.js';
|
|
124
132
|
export * from './grid/Cell.js';
|