@allxsmith/bestax-bulma 5.26.0 → 5.26.2
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/index.cjs +80 -28
- package/dist/index.cjs.map +1 -1
- package/dist/index.esm.js +80 -28
- package/dist/index.esm.js.map +1 -1
- package/dist/types/form/DateInputBase.d.ts +6 -1
- package/dist/types/form/DateTimeInputBase.d.ts +6 -1
- package/dist/types/form/TimeInputBase.d.ts +6 -1
- package/dist/types/form/_pickerInternals/PickerPopover.d.ts +7 -0
- package/dist/types/form/_pickerInternals/useSegmentedEntry.d.ts +5 -0
- package/dist/types/helpers/Theme.d.ts +9 -0
- package/dist/types-cjs/form/DateInputBase.d.ts +6 -1
- package/dist/types-cjs/form/DateTimeInputBase.d.ts +6 -1
- package/dist/types-cjs/form/TimeInputBase.d.ts +6 -1
- package/dist/types-cjs/form/_pickerInternals/PickerPopover.d.ts +7 -0
- package/dist/types-cjs/form/_pickerInternals/useSegmentedEntry.d.ts +5 -0
- package/dist/types-cjs/helpers/Theme.d.ts +9 -0
- package/package.json +1 -1
|
@@ -74,7 +74,12 @@ export interface DateInputBaseProps extends Omit<React.InputHTMLAttributes<HTMLI
|
|
|
74
74
|
editable?: boolean;
|
|
75
75
|
/** Whether the calendar popover exists. `false` makes the field input-only (segmented typing, no popover). */
|
|
76
76
|
popover?: boolean;
|
|
77
|
-
/**
|
|
77
|
+
/**
|
|
78
|
+
* Open the popover when the input is focused. Focus that a closing popover
|
|
79
|
+
* hands back to the input leaves it closed. Dismissing it commits nothing:
|
|
80
|
+
* an empty field stays empty, and leaving afterwards commits only what was
|
|
81
|
+
* typed since.
|
|
82
|
+
*/
|
|
78
83
|
openOnFocus?: boolean;
|
|
79
84
|
/** Close the popover after a date is selected. */
|
|
80
85
|
closeOnSelect?: boolean;
|
|
@@ -45,7 +45,12 @@ export interface DateTimeInputBaseProps extends Omit<React.InputHTMLAttributes<H
|
|
|
45
45
|
editable?: boolean;
|
|
46
46
|
/** Whether the calendar + time popover exists. `false` makes the field input-only (segmented typing with no popover). Default `true`. */
|
|
47
47
|
popover?: boolean;
|
|
48
|
-
/**
|
|
48
|
+
/**
|
|
49
|
+
* Open the popover on focus. Default `true`. Focus that a closing popover
|
|
50
|
+
* hands back to the input leaves it closed. Dismissing it commits nothing:
|
|
51
|
+
* an empty field stays empty, and leaving afterwards commits only what was
|
|
52
|
+
* typed since.
|
|
53
|
+
*/
|
|
49
54
|
openOnFocus?: boolean;
|
|
50
55
|
/** Off by default — users typically tweak both halves before committing. */
|
|
51
56
|
closeOnSelect?: boolean;
|
|
@@ -44,7 +44,12 @@ export interface TimeInputBaseProps extends Omit<React.InputHTMLAttributes<HTMLI
|
|
|
44
44
|
editable?: boolean;
|
|
45
45
|
/** Whether the spinner popover exists. `false` makes the field input-only (segmented typing, no popover). */
|
|
46
46
|
popover?: boolean;
|
|
47
|
-
/**
|
|
47
|
+
/**
|
|
48
|
+
* Open the popover when the input is focused. Focus that a closing popover
|
|
49
|
+
* hands back to the input leaves it closed. Dismissing it commits nothing:
|
|
50
|
+
* an empty field stays empty, and leaving afterwards commits only what was
|
|
51
|
+
* typed since.
|
|
52
|
+
*/
|
|
48
53
|
openOnFocus?: boolean;
|
|
49
54
|
/** Close the popover after a time is selected (off by default). */
|
|
50
55
|
closeOnSelect?: boolean;
|
|
@@ -15,6 +15,13 @@ export interface PickerPopoverProps {
|
|
|
15
15
|
ariaLabelledBy?: string;
|
|
16
16
|
role?: 'dialog' | 'group';
|
|
17
17
|
id?: string;
|
|
18
|
+
/**
|
|
19
|
+
* Where focus goes when the popover closes. Without it, focus goes back to
|
|
20
|
+
* whatever had it when the focus trap turned on, which is read after the
|
|
21
|
+
* panel's content mounts: a calendar that focuses a cell as it mounts
|
|
22
|
+
* would be recorded instead, and that cell leaves with the panel.
|
|
23
|
+
*/
|
|
24
|
+
restoreFocusRef?: React.RefObject<HTMLElement | null>;
|
|
18
25
|
}
|
|
19
26
|
export declare const PickerPopover: React.FC<PickerPopoverProps>;
|
|
20
27
|
export default PickerPopover;
|
|
@@ -46,6 +46,11 @@ export interface UseSegmentedEntryParams {
|
|
|
46
46
|
openOnFocus?: boolean;
|
|
47
47
|
closeOnSelect?: boolean;
|
|
48
48
|
isOpen: boolean;
|
|
49
|
+
/**
|
|
50
|
+
* The host's open-state setter. The hook asks it to open on focus, click
|
|
51
|
+
* or ArrowDown, but not on the focus the popover's focus trap hands back
|
|
52
|
+
* to the input as it closes, which is not the user arriving.
|
|
53
|
+
*/
|
|
49
54
|
setOpen: (next: boolean) => void;
|
|
50
55
|
inputRef: React.RefObject<HTMLInputElement | null>;
|
|
51
56
|
containerRef: React.RefObject<HTMLElement | null>;
|
|
@@ -55,11 +55,20 @@ type BulmaVars = Partial<Record<BulmaVarKey, string>>;
|
|
|
55
55
|
*/
|
|
56
56
|
export interface ThemeProps extends Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
57
57
|
children: ReactNode;
|
|
58
|
+
/**
|
|
59
|
+
* Additional CSS classes for the wrapper div. A root Theme (`isRoot`) has no
|
|
60
|
+
* wrapper, so there this does nothing, and says so in development.
|
|
61
|
+
*/
|
|
58
62
|
className?: string;
|
|
59
63
|
/**
|
|
60
64
|
* Inject the variables globally at `:root` instead of scoping them to a
|
|
61
65
|
* wrapper div. Default: false.
|
|
62
66
|
*
|
|
67
|
+
* A root Theme renders its children with no wrapper, so `className` and the
|
|
68
|
+
* helper props, such as `m` or `shadow`, have no element to land on. They
|
|
69
|
+
* do nothing, and say so in development. `radius` and `columnGap` describe
|
|
70
|
+
* what each does at the root.
|
|
71
|
+
*
|
|
63
72
|
* Several root Themes can be mounted at once, and each contributes its own
|
|
64
73
|
* variables. Where two set the same one, the inner or later-mounted Theme
|
|
65
74
|
* wins, as with nested scoped Themes, and unmounting a Theme removes only
|
|
@@ -74,7 +74,12 @@ export interface DateInputBaseProps extends Omit<React.InputHTMLAttributes<HTMLI
|
|
|
74
74
|
editable?: boolean;
|
|
75
75
|
/** Whether the calendar popover exists. `false` makes the field input-only (segmented typing, no popover). */
|
|
76
76
|
popover?: boolean;
|
|
77
|
-
/**
|
|
77
|
+
/**
|
|
78
|
+
* Open the popover when the input is focused. Focus that a closing popover
|
|
79
|
+
* hands back to the input leaves it closed. Dismissing it commits nothing:
|
|
80
|
+
* an empty field stays empty, and leaving afterwards commits only what was
|
|
81
|
+
* typed since.
|
|
82
|
+
*/
|
|
78
83
|
openOnFocus?: boolean;
|
|
79
84
|
/** Close the popover after a date is selected. */
|
|
80
85
|
closeOnSelect?: boolean;
|
|
@@ -45,7 +45,12 @@ export interface DateTimeInputBaseProps extends Omit<React.InputHTMLAttributes<H
|
|
|
45
45
|
editable?: boolean;
|
|
46
46
|
/** Whether the calendar + time popover exists. `false` makes the field input-only (segmented typing with no popover). Default `true`. */
|
|
47
47
|
popover?: boolean;
|
|
48
|
-
/**
|
|
48
|
+
/**
|
|
49
|
+
* Open the popover on focus. Default `true`. Focus that a closing popover
|
|
50
|
+
* hands back to the input leaves it closed. Dismissing it commits nothing:
|
|
51
|
+
* an empty field stays empty, and leaving afterwards commits only what was
|
|
52
|
+
* typed since.
|
|
53
|
+
*/
|
|
49
54
|
openOnFocus?: boolean;
|
|
50
55
|
/** Off by default — users typically tweak both halves before committing. */
|
|
51
56
|
closeOnSelect?: boolean;
|
|
@@ -44,7 +44,12 @@ export interface TimeInputBaseProps extends Omit<React.InputHTMLAttributes<HTMLI
|
|
|
44
44
|
editable?: boolean;
|
|
45
45
|
/** Whether the spinner popover exists. `false` makes the field input-only (segmented typing, no popover). */
|
|
46
46
|
popover?: boolean;
|
|
47
|
-
/**
|
|
47
|
+
/**
|
|
48
|
+
* Open the popover when the input is focused. Focus that a closing popover
|
|
49
|
+
* hands back to the input leaves it closed. Dismissing it commits nothing:
|
|
50
|
+
* an empty field stays empty, and leaving afterwards commits only what was
|
|
51
|
+
* typed since.
|
|
52
|
+
*/
|
|
48
53
|
openOnFocus?: boolean;
|
|
49
54
|
/** Close the popover after a time is selected (off by default). */
|
|
50
55
|
closeOnSelect?: boolean;
|
|
@@ -15,6 +15,13 @@ export interface PickerPopoverProps {
|
|
|
15
15
|
ariaLabelledBy?: string;
|
|
16
16
|
role?: 'dialog' | 'group';
|
|
17
17
|
id?: string;
|
|
18
|
+
/**
|
|
19
|
+
* Where focus goes when the popover closes. Without it, focus goes back to
|
|
20
|
+
* whatever had it when the focus trap turned on, which is read after the
|
|
21
|
+
* panel's content mounts: a calendar that focuses a cell as it mounts
|
|
22
|
+
* would be recorded instead, and that cell leaves with the panel.
|
|
23
|
+
*/
|
|
24
|
+
restoreFocusRef?: React.RefObject<HTMLElement | null>;
|
|
18
25
|
}
|
|
19
26
|
export declare const PickerPopover: React.FC<PickerPopoverProps>;
|
|
20
27
|
export default PickerPopover;
|
|
@@ -46,6 +46,11 @@ export interface UseSegmentedEntryParams {
|
|
|
46
46
|
openOnFocus?: boolean;
|
|
47
47
|
closeOnSelect?: boolean;
|
|
48
48
|
isOpen: boolean;
|
|
49
|
+
/**
|
|
50
|
+
* The host's open-state setter. The hook asks it to open on focus, click
|
|
51
|
+
* or ArrowDown, but not on the focus the popover's focus trap hands back
|
|
52
|
+
* to the input as it closes, which is not the user arriving.
|
|
53
|
+
*/
|
|
49
54
|
setOpen: (next: boolean) => void;
|
|
50
55
|
inputRef: React.RefObject<HTMLInputElement | null>;
|
|
51
56
|
containerRef: React.RefObject<HTMLElement | null>;
|
|
@@ -55,11 +55,20 @@ type BulmaVars = Partial<Record<BulmaVarKey, string>>;
|
|
|
55
55
|
*/
|
|
56
56
|
export interface ThemeProps extends Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
57
57
|
children: ReactNode;
|
|
58
|
+
/**
|
|
59
|
+
* Additional CSS classes for the wrapper div. A root Theme (`isRoot`) has no
|
|
60
|
+
* wrapper, so there this does nothing, and says so in development.
|
|
61
|
+
*/
|
|
58
62
|
className?: string;
|
|
59
63
|
/**
|
|
60
64
|
* Inject the variables globally at `:root` instead of scoping them to a
|
|
61
65
|
* wrapper div. Default: false.
|
|
62
66
|
*
|
|
67
|
+
* A root Theme renders its children with no wrapper, so `className` and the
|
|
68
|
+
* helper props, such as `m` or `shadow`, have no element to land on. They
|
|
69
|
+
* do nothing, and say so in development. `radius` and `columnGap` describe
|
|
70
|
+
* what each does at the root.
|
|
71
|
+
*
|
|
63
72
|
* Several root Themes can be mounted at once, and each contributes its own
|
|
64
73
|
* variables. Where two set the same one, the inner or later-mounted Theme
|
|
65
74
|
* wins, as with nested scoped Themes, and unmounting a Theme removes only
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@allxsmith/bestax-bulma",
|
|
3
|
-
"version": "5.26.
|
|
3
|
+
"version": "5.26.2",
|
|
4
4
|
"description": "A fully-typed React component library for the Bulma CSS framework. Build modern UIs quickly with reusable, accessible, and customizable Bulma-based React components.",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.esm.js",
|