@jobber/components 6.103.2-JOB-135467-8ed574a.0 → 6.103.2-JOB-140609-9051081.26
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/Autocomplete/Autocomplete.types.d.ts +12 -1
- package/dist/Autocomplete/index.cjs +1 -13
- package/dist/Autocomplete/index.mjs +1 -13
- package/dist/Button/Button.d.ts +6 -757
- package/dist/Button-cjs.js +9 -15
- package/dist/Button-es.js +10 -16
- package/dist/Checkbox/Checkbox.types.d.ts +2 -9
- package/dist/Checkbox/index.cjs +3 -2
- package/dist/Checkbox/index.mjs +3 -2
- package/dist/Chips/InternalChipDismissible/hooks/index.cjs +2 -2
- package/dist/Chips/InternalChipDismissible/hooks/index.mjs +2 -2
- package/dist/Chips/InternalChipDismissible/index.cjs +2 -2
- package/dist/Chips/InternalChipDismissible/index.mjs +2 -2
- package/dist/Chips/index.cjs +2 -2
- package/dist/Chips/index.mjs +2 -2
- package/dist/DataList/components/DataListSearch/index.cjs +1 -12
- package/dist/DataList/components/DataListSearch/index.mjs +1 -12
- package/dist/DataList/index.cjs +0 -8
- package/dist/DataList/index.mjs +0 -8
- package/dist/DataTable/index.cjs +2 -2
- package/dist/DataTable/index.mjs +2 -2
- package/dist/DatePicker/index.cjs +2 -2
- package/dist/DatePicker/index.mjs +2 -2
- package/dist/FormField/FormFieldTypes.d.ts +217 -1
- package/dist/FormField-cjs.js +0 -1
- package/dist/FormField-es.js +1 -1
- package/dist/InputDate/index.cjs +8 -4
- package/dist/InputDate/index.mjs +8 -4
- package/dist/InputDate/useInputDateActivatorActions.d.ts +2 -2
- package/dist/InputEmail/InputEmail.types.d.ts +16 -21
- package/dist/InputEmail/hooks/useInputEmailActions.d.ts +1 -1
- package/dist/InputEmail/index.cjs +10 -45
- package/dist/InputEmail/index.mjs +10 -45
- package/dist/InputNumber/InputNumber.rebuilt.types.d.ts +23 -2
- package/dist/InputNumber/index.cjs +5 -2
- package/dist/InputNumber/index.mjs +5 -2
- package/dist/InputPhoneNumber/InputPhoneNumber.types.d.ts +15 -26
- package/dist/InputPhoneNumber/hooks/useInputPhoneActions.d.ts +1 -1
- package/dist/InputPhoneNumber/index.cjs +20 -35
- package/dist/InputPhoneNumber/index.mjs +20 -35
- package/dist/InputText/InputText.d.ts +2 -2
- package/dist/InputText/InputText.types.d.ts +27 -24
- package/dist/InputText/index.cjs +26 -55
- package/dist/InputText/index.mjs +27 -56
- package/dist/InputText/useInputTextActions.d.ts +1 -1
- package/dist/InputTime/InputTime.rebuilt.d.ts +1 -1
- package/dist/InputTime/InputTime.types.d.ts +21 -1
- package/dist/InputTime/index.cjs +30 -25
- package/dist/InputTime/index.d.ts +1 -1
- package/dist/InputTime/index.mjs +32 -27
- package/dist/List/index.cjs +2 -2
- package/dist/List/index.mjs +2 -2
- package/dist/RecurringSelect/index.cjs +2 -2
- package/dist/RecurringSelect/index.mjs +2 -2
- package/dist/Select/Select.rebuilt.d.ts +1 -1
- package/dist/Select/Select.types.d.ts +14 -1
- package/dist/Select/hooks/useSelectActions.d.ts +5 -5
- package/dist/Select/index.cjs +27 -41
- package/dist/Select/index.d.ts +7 -5
- package/dist/Select/index.mjs +29 -43
- package/dist/_baseEach-cjs.js +12 -12
- package/dist/_baseEach-es.js +1 -1
- package/dist/_baseFlatten-cjs.js +2 -2
- package/dist/_baseFlatten-es.js +1 -1
- package/dist/{_baseGet-cjs.js → _getAllKeys-cjs.js} +181 -181
- package/dist/{_baseGet-es.js → _getAllKeys-es.js} +182 -182
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +2 -2
- package/dist/omit-cjs.js +14 -14
- package/dist/omit-es.js +1 -1
- package/dist/useScrollToActive-cjs.js +3 -3
- package/dist/useScrollToActive-es.js +1 -1
- package/package.json +2 -2
- package/dist/InputEmail/hooks/useInputEmailFormField.d.ts +0 -32
- package/dist/InputPhoneNumber/hooks/useInputPhoneFormField.d.ts +0 -71
- package/dist/InputText/useInputTextFormField.d.ts +0 -352
- package/dist/Select/hooks/useSelectFormField.d.ts +0 -34
package/dist/Button-cjs.js
CHANGED
|
@@ -68,7 +68,12 @@ function ButtonLabel(_a) {
|
|
|
68
68
|
return (React.createElement(Typography.Typography, Object.assign({ element: element, fontWeight: fontWeight, fontFamily: fontFamily, size: getTypeSizes(size) }, props)));
|
|
69
69
|
}
|
|
70
70
|
|
|
71
|
-
|
|
71
|
+
function Button(props) {
|
|
72
|
+
const { size } = props;
|
|
73
|
+
return (React.createElement(ButtonProvider, { size: size },
|
|
74
|
+
React.createElement(ButtonWrapper, Object.assign({}, props))));
|
|
75
|
+
}
|
|
76
|
+
function ButtonWrapper(props) {
|
|
72
77
|
const { ariaControls, ariaHaspopup, ariaExpanded, ariaLabel, disabled = false, external, id, name, onClick, onMouseDown, loading, role, value, submit, to, url, UNSAFE_className = {}, UNSAFE_style = {}, children, } = props;
|
|
73
78
|
const { combined } = useButtonStyles(props);
|
|
74
79
|
const buttonType = submit ? "submit" : "button";
|
|
@@ -80,22 +85,11 @@ const ButtonWrapper = React.forwardRef((props, ref) => {
|
|
|
80
85
|
})), (url === undefined && to === undefined && { type: buttonType })), { "aria-controls": ariaControls, "aria-haspopup": ariaHaspopup, "aria-busy": loading, "aria-expanded": ariaExpanded, "aria-label": ariaLabel, role: role });
|
|
81
86
|
const buttonInternals = children || React.createElement(ButtonContent, Object.assign({}, props));
|
|
82
87
|
if (to) {
|
|
83
|
-
return (React.createElement(reactRouterDom.Link, Object.assign({}, tagProps, { to: to
|
|
88
|
+
return (React.createElement(reactRouterDom.Link, Object.assign({}, tagProps, { to: to }), buttonInternals));
|
|
84
89
|
}
|
|
85
90
|
const Tag = url ? "a" : "button";
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
});
|
|
89
|
-
ButtonWrapper.displayName = "ButtonWrapper";
|
|
90
|
-
const ButtonForwarded = React.forwardRef((props, ref) => {
|
|
91
|
-
const { size } = props;
|
|
92
|
-
return (React.createElement(ButtonProvider, { size: size },
|
|
93
|
-
React.createElement(ButtonWrapper, Object.assign({}, props, { ref: ref }))));
|
|
94
|
-
});
|
|
95
|
-
ButtonForwarded.displayName = "Button";
|
|
96
|
-
// Add function overloads for type-safe refs
|
|
97
|
-
const Button = ButtonForwarded;
|
|
98
|
-
// Attach namespace components (preserving existing API)
|
|
91
|
+
return React.createElement(Tag, Object.assign({}, tagProps), buttonInternals);
|
|
92
|
+
}
|
|
99
93
|
Button.Label = ButtonLabel;
|
|
100
94
|
Button.Icon = ButtonIcon;
|
|
101
95
|
|
package/dist/Button-es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React__default, { createContext, useContext
|
|
1
|
+
import React__default, { createContext, useContext } from 'react';
|
|
2
2
|
import { Link } from 'react-router-dom';
|
|
3
3
|
import classnames from 'classnames';
|
|
4
4
|
import { _ as __rest } from './tslib.es6-es.js';
|
|
@@ -66,7 +66,12 @@ function ButtonLabel(_a) {
|
|
|
66
66
|
return (React__default.createElement(Typography, Object.assign({ element: element, fontWeight: fontWeight, fontFamily: fontFamily, size: getTypeSizes(size) }, props)));
|
|
67
67
|
}
|
|
68
68
|
|
|
69
|
-
|
|
69
|
+
function Button(props) {
|
|
70
|
+
const { size } = props;
|
|
71
|
+
return (React__default.createElement(ButtonProvider, { size: size },
|
|
72
|
+
React__default.createElement(ButtonWrapper, Object.assign({}, props))));
|
|
73
|
+
}
|
|
74
|
+
function ButtonWrapper(props) {
|
|
70
75
|
const { ariaControls, ariaHaspopup, ariaExpanded, ariaLabel, disabled = false, external, id, name, onClick, onMouseDown, loading, role, value, submit, to, url, UNSAFE_className = {}, UNSAFE_style = {}, children, } = props;
|
|
71
76
|
const { combined } = useButtonStyles(props);
|
|
72
77
|
const buttonType = submit ? "submit" : "button";
|
|
@@ -78,22 +83,11 @@ const ButtonWrapper = forwardRef((props, ref) => {
|
|
|
78
83
|
})), (url === undefined && to === undefined && { type: buttonType })), { "aria-controls": ariaControls, "aria-haspopup": ariaHaspopup, "aria-busy": loading, "aria-expanded": ariaExpanded, "aria-label": ariaLabel, role: role });
|
|
79
84
|
const buttonInternals = children || React__default.createElement(ButtonContent, Object.assign({}, props));
|
|
80
85
|
if (to) {
|
|
81
|
-
return (React__default.createElement(Link, Object.assign({}, tagProps, { to: to
|
|
86
|
+
return (React__default.createElement(Link, Object.assign({}, tagProps, { to: to }), buttonInternals));
|
|
82
87
|
}
|
|
83
88
|
const Tag = url ? "a" : "button";
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
});
|
|
87
|
-
ButtonWrapper.displayName = "ButtonWrapper";
|
|
88
|
-
const ButtonForwarded = forwardRef((props, ref) => {
|
|
89
|
-
const { size } = props;
|
|
90
|
-
return (React__default.createElement(ButtonProvider, { size: size },
|
|
91
|
-
React__default.createElement(ButtonWrapper, Object.assign({}, props, { ref: ref }))));
|
|
92
|
-
});
|
|
93
|
-
ButtonForwarded.displayName = "Button";
|
|
94
|
-
// Add function overloads for type-safe refs
|
|
95
|
-
const Button = ButtonForwarded;
|
|
96
|
-
// Attach namespace components (preserving existing API)
|
|
89
|
+
return React__default.createElement(Tag, Object.assign({}, tagProps), buttonInternals);
|
|
90
|
+
}
|
|
97
91
|
Button.Label = ButtonLabel;
|
|
98
92
|
Button.Icon = ButtonIcon;
|
|
99
93
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { ReactElement, ReactNode } from "react";
|
|
2
2
|
import type { XOR } from "ts-xor";
|
|
3
|
-
|
|
3
|
+
import type { AriaInputProps, FocusEvents } from "../FormField/FormFieldTypes";
|
|
4
|
+
export interface BaseCheckboxProps extends AriaInputProps, FocusEvents<HTMLInputElement> {
|
|
4
5
|
/**
|
|
5
6
|
* Determines if the checkbox is checked or not.
|
|
6
7
|
*/
|
|
@@ -41,14 +42,6 @@ export interface BaseCheckboxProps {
|
|
|
41
42
|
* Called when the checkbox value changes
|
|
42
43
|
*/
|
|
43
44
|
onChange?(newValue: boolean): void;
|
|
44
|
-
/**
|
|
45
|
-
* Called when the checkbox is focused
|
|
46
|
-
*/
|
|
47
|
-
onFocus?(event: React.FocusEvent<HTMLInputElement>): void;
|
|
48
|
-
/**
|
|
49
|
-
* Called when the checkbox loses focus
|
|
50
|
-
*/
|
|
51
|
-
onBlur?(event: React.FocusEvent<HTMLInputElement>): void;
|
|
52
45
|
/**
|
|
53
46
|
* Whether the checkbox is invalid
|
|
54
47
|
*/
|
package/dist/Checkbox/index.cjs
CHANGED
|
@@ -54,7 +54,7 @@ function CheckboxLegacy({ checked, defaultChecked, disabled, label, name, value,
|
|
|
54
54
|
} }));
|
|
55
55
|
}
|
|
56
56
|
|
|
57
|
-
const CheckboxRebuilt = React.forwardRef(function CheckboxRebuiltInternal({ checked, defaultChecked, disabled, label, name, value, indeterminate = false, description, id, onBlur, onChange, onFocus, invalid, }, ref) {
|
|
57
|
+
const CheckboxRebuilt = React.forwardRef(function CheckboxRebuiltInternal({ checked, defaultChecked, disabled, label, name, value, indeterminate = false, description, id, onBlur, onChange, onFocus, invalid, ariaLabel, ariaDescribedBy, ariaInvalid, ariaRequired, }, ref) {
|
|
58
58
|
const descriptionIdentifier = React.useId();
|
|
59
59
|
const wrapperClassName = classnames(styles.wrapper, disabled && styles.disabled, invalid && styles.invalid);
|
|
60
60
|
const inputClassName = classnames(styles.input, {
|
|
@@ -70,7 +70,8 @@ const CheckboxRebuilt = React.forwardRef(function CheckboxRebuiltInternal({ chec
|
|
|
70
70
|
return (React.createElement("div", { className: styles.checkBoxParent },
|
|
71
71
|
React.createElement("label", { className: wrapperClassName },
|
|
72
72
|
React.createElement("span", { className: styles.checkHolder },
|
|
73
|
-
React.createElement("input", { ref: ref, type: "checkbox", id: id, className: inputClassName, name: name, "aria-
|
|
73
|
+
React.createElement("input", { ref: ref, type: "checkbox", id: id, className: inputClassName, name: name, "aria-label": ariaLabel, "aria-describedby": ariaDescribedBy ||
|
|
74
|
+
(description ? descriptionIdentifier : undefined), "aria-invalid": ariaInvalid, "aria-required": ariaRequired, checked: checked, value: value, defaultChecked: defaultChecked, disabled: disabled, onChange: handleChange, onFocus: onFocus, onBlur: onBlur }),
|
|
74
75
|
React.createElement("span", { className: styles.checkBox },
|
|
75
76
|
React.createElement(Icon.Icon, { name: iconName, color: "surface" }))),
|
|
76
77
|
labelContent && React.createElement("span", { className: styles.label }, labelContent)),
|
package/dist/Checkbox/index.mjs
CHANGED
|
@@ -52,7 +52,7 @@ function CheckboxLegacy({ checked, defaultChecked, disabled, label, name, value,
|
|
|
52
52
|
} }));
|
|
53
53
|
}
|
|
54
54
|
|
|
55
|
-
const CheckboxRebuilt = forwardRef(function CheckboxRebuiltInternal({ checked, defaultChecked, disabled, label, name, value, indeterminate = false, description, id, onBlur, onChange, onFocus, invalid, }, ref) {
|
|
55
|
+
const CheckboxRebuilt = forwardRef(function CheckboxRebuiltInternal({ checked, defaultChecked, disabled, label, name, value, indeterminate = false, description, id, onBlur, onChange, onFocus, invalid, ariaLabel, ariaDescribedBy, ariaInvalid, ariaRequired, }, ref) {
|
|
56
56
|
const descriptionIdentifier = useId();
|
|
57
57
|
const wrapperClassName = classnames(styles.wrapper, disabled && styles.disabled, invalid && styles.invalid);
|
|
58
58
|
const inputClassName = classnames(styles.input, {
|
|
@@ -68,7 +68,8 @@ const CheckboxRebuilt = forwardRef(function CheckboxRebuiltInternal({ checked, d
|
|
|
68
68
|
return (React__default.createElement("div", { className: styles.checkBoxParent },
|
|
69
69
|
React__default.createElement("label", { className: wrapperClassName },
|
|
70
70
|
React__default.createElement("span", { className: styles.checkHolder },
|
|
71
|
-
React__default.createElement("input", { ref: ref, type: "checkbox", id: id, className: inputClassName, name: name, "aria-
|
|
71
|
+
React__default.createElement("input", { ref: ref, type: "checkbox", id: id, className: inputClassName, name: name, "aria-label": ariaLabel, "aria-describedby": ariaDescribedBy ||
|
|
72
|
+
(description ? descriptionIdentifier : undefined), "aria-invalid": ariaInvalid, "aria-required": ariaRequired, checked: checked, value: value, defaultChecked: defaultChecked, disabled: disabled, onChange: handleChange, onFocus: onFocus, onBlur: onBlur }),
|
|
72
73
|
React__default.createElement("span", { className: styles.checkBox },
|
|
73
74
|
React__default.createElement(Icon, { name: iconName, color: "surface" }))),
|
|
74
75
|
labelContent && React__default.createElement("span", { className: styles.label }, labelContent)),
|
|
@@ -4,12 +4,12 @@ var useScrollToActive = require('../../../useScrollToActive-cjs.js');
|
|
|
4
4
|
require('react');
|
|
5
5
|
require('../../../_commonjsHelpers-cjs.js');
|
|
6
6
|
require('../../../_baseFlatten-cjs.js');
|
|
7
|
-
require('../../../
|
|
7
|
+
require('../../../_getAllKeys-cjs.js');
|
|
8
8
|
require('../../../isTypedArray-cjs.js');
|
|
9
9
|
require('../../../isObjectLike-cjs.js');
|
|
10
|
+
require('../../../isSymbol-cjs.js');
|
|
10
11
|
require('../../../identity-cjs.js');
|
|
11
12
|
require('../../../_getTag-cjs.js');
|
|
12
|
-
require('../../../isSymbol-cjs.js');
|
|
13
13
|
require('../../../_baseEach-cjs.js');
|
|
14
14
|
require('../../../_baseFor-cjs.js');
|
|
15
15
|
require('../../../_isIterateeCall-cjs.js');
|
|
@@ -2,12 +2,12 @@ export { b as useInView, u as useInternalChipDismissible, a as useInternalChipDi
|
|
|
2
2
|
import 'react';
|
|
3
3
|
import '../../../_commonjsHelpers-es.js';
|
|
4
4
|
import '../../../_baseFlatten-es.js';
|
|
5
|
-
import '../../../
|
|
5
|
+
import '../../../_getAllKeys-es.js';
|
|
6
6
|
import '../../../isTypedArray-es.js';
|
|
7
7
|
import '../../../isObjectLike-es.js';
|
|
8
|
+
import '../../../isSymbol-es.js';
|
|
8
9
|
import '../../../identity-es.js';
|
|
9
10
|
import '../../../_getTag-es.js';
|
|
10
|
-
import '../../../isSymbol-es.js';
|
|
11
11
|
import '../../../_baseEach-es.js';
|
|
12
12
|
import '../../../_baseFor-es.js';
|
|
13
13
|
import '../../../_isIterateeCall-es.js';
|
|
@@ -5,12 +5,12 @@ require('react');
|
|
|
5
5
|
require('../../useScrollToActive-cjs.js');
|
|
6
6
|
require('../../_commonjsHelpers-cjs.js');
|
|
7
7
|
require('../../_baseFlatten-cjs.js');
|
|
8
|
-
require('../../
|
|
8
|
+
require('../../_getAllKeys-cjs.js');
|
|
9
9
|
require('../../isTypedArray-cjs.js');
|
|
10
10
|
require('../../isObjectLike-cjs.js');
|
|
11
|
+
require('../../isSymbol-cjs.js');
|
|
11
12
|
require('../../identity-cjs.js');
|
|
12
13
|
require('../../_getTag-cjs.js');
|
|
13
|
-
require('../../isSymbol-cjs.js');
|
|
14
14
|
require('../../_baseEach-cjs.js');
|
|
15
15
|
require('../../_baseFor-cjs.js');
|
|
16
16
|
require('../../_isIterateeCall-cjs.js');
|
|
@@ -3,12 +3,12 @@ import 'react';
|
|
|
3
3
|
import '../../useScrollToActive-es.js';
|
|
4
4
|
import '../../_commonjsHelpers-es.js';
|
|
5
5
|
import '../../_baseFlatten-es.js';
|
|
6
|
-
import '../../
|
|
6
|
+
import '../../_getAllKeys-es.js';
|
|
7
7
|
import '../../isTypedArray-es.js';
|
|
8
8
|
import '../../isObjectLike-es.js';
|
|
9
|
+
import '../../isSymbol-es.js';
|
|
9
10
|
import '../../identity-es.js';
|
|
10
11
|
import '../../_getTag-es.js';
|
|
11
|
-
import '../../isSymbol-es.js';
|
|
12
12
|
import '../../_baseEach-es.js';
|
|
13
13
|
import '../../_baseFor-es.js';
|
|
14
14
|
import '../../_isIterateeCall-es.js';
|
package/dist/Chips/index.cjs
CHANGED
|
@@ -7,12 +7,12 @@ var Chips = require('../Chips-cjs.js');
|
|
|
7
7
|
require('../useScrollToActive-cjs.js');
|
|
8
8
|
require('../_commonjsHelpers-cjs.js');
|
|
9
9
|
require('../_baseFlatten-cjs.js');
|
|
10
|
-
require('../
|
|
10
|
+
require('../_getAllKeys-cjs.js');
|
|
11
11
|
require('../isTypedArray-cjs.js');
|
|
12
12
|
require('../isObjectLike-cjs.js');
|
|
13
|
+
require('../isSymbol-cjs.js');
|
|
13
14
|
require('../identity-cjs.js');
|
|
14
15
|
require('../_getTag-cjs.js');
|
|
15
|
-
require('../isSymbol-cjs.js');
|
|
16
16
|
require('../_baseEach-cjs.js');
|
|
17
17
|
require('../_baseFor-cjs.js');
|
|
18
18
|
require('../_isIterateeCall-cjs.js');
|
package/dist/Chips/index.mjs
CHANGED
|
@@ -5,12 +5,12 @@ export { C as Chips } from '../Chips-es.js';
|
|
|
5
5
|
import '../useScrollToActive-es.js';
|
|
6
6
|
import '../_commonjsHelpers-es.js';
|
|
7
7
|
import '../_baseFlatten-es.js';
|
|
8
|
-
import '../
|
|
8
|
+
import '../_getAllKeys-es.js';
|
|
9
9
|
import '../isTypedArray-es.js';
|
|
10
10
|
import '../isObjectLike-es.js';
|
|
11
|
+
import '../isSymbol-es.js';
|
|
11
12
|
import '../identity-es.js';
|
|
12
13
|
import '../_getTag-es.js';
|
|
13
|
-
import '../isSymbol-es.js';
|
|
14
14
|
import '../_baseEach-es.js';
|
|
15
15
|
import '../_baseFor-es.js';
|
|
16
16
|
import '../_isIterateeCall-es.js';
|
|
@@ -18,20 +18,9 @@ require('../../../useFormFieldFocus-cjs.js');
|
|
|
18
18
|
require('../../../InputValidation-cjs.js');
|
|
19
19
|
require('../../../Spinner-cjs.js');
|
|
20
20
|
require('react-hook-form');
|
|
21
|
-
require('../../../omit-cjs.js');
|
|
22
|
-
require('../../../_commonjsHelpers-cjs.js');
|
|
23
|
-
require('../../../_baseGet-cjs.js');
|
|
24
|
-
require('../../../isTypedArray-cjs.js');
|
|
25
|
-
require('../../../isObjectLike-cjs.js');
|
|
26
|
-
require('../../../identity-cjs.js');
|
|
27
|
-
require('../../../_getTag-cjs.js');
|
|
28
|
-
require('../../../isSymbol-cjs.js');
|
|
29
|
-
require('../../../keysIn-cjs.js');
|
|
30
|
-
require('../../../_baseAssignValue-cjs.js');
|
|
31
|
-
require('../../../_baseFlatten-cjs.js');
|
|
32
|
-
require('../../../_setToString-cjs.js');
|
|
33
21
|
require('../../../DataListContext-cjs.js');
|
|
34
22
|
require('../../../noop-cjs.js');
|
|
23
|
+
require('../../../_commonjsHelpers-cjs.js');
|
|
35
24
|
require('../../../DataList.const-cjs.js');
|
|
36
25
|
require('../../../AnimatedSwitcher-cjs.js');
|
|
37
26
|
|
|
@@ -16,19 +16,8 @@ import '../../../useFormFieldFocus-es.js';
|
|
|
16
16
|
import '../../../InputValidation-es.js';
|
|
17
17
|
import '../../../Spinner-es.js';
|
|
18
18
|
import 'react-hook-form';
|
|
19
|
-
import '../../../omit-es.js';
|
|
20
|
-
import '../../../_commonjsHelpers-es.js';
|
|
21
|
-
import '../../../_baseGet-es.js';
|
|
22
|
-
import '../../../isTypedArray-es.js';
|
|
23
|
-
import '../../../isObjectLike-es.js';
|
|
24
|
-
import '../../../identity-es.js';
|
|
25
|
-
import '../../../_getTag-es.js';
|
|
26
|
-
import '../../../isSymbol-es.js';
|
|
27
|
-
import '../../../keysIn-es.js';
|
|
28
|
-
import '../../../_baseAssignValue-es.js';
|
|
29
|
-
import '../../../_baseFlatten-es.js';
|
|
30
|
-
import '../../../_setToString-es.js';
|
|
31
19
|
import '../../../DataListContext-es.js';
|
|
32
20
|
import '../../../noop-es.js';
|
|
21
|
+
import '../../../_commonjsHelpers-es.js';
|
|
33
22
|
import '../../../DataList.const-es.js';
|
|
34
23
|
import '../../../AnimatedSwitcher-es.js';
|
package/dist/DataList/index.cjs
CHANGED
|
@@ -81,14 +81,6 @@ require('../InputText/index.cjs');
|
|
|
81
81
|
require('../FormField-cjs.js');
|
|
82
82
|
require('../useFormFieldFocus-cjs.js');
|
|
83
83
|
require('../InputValidation-cjs.js');
|
|
84
|
-
require('../omit-cjs.js');
|
|
85
|
-
require('../_baseGet-cjs.js');
|
|
86
|
-
require('../identity-cjs.js');
|
|
87
|
-
require('../isSymbol-cjs.js');
|
|
88
|
-
require('../keysIn-cjs.js');
|
|
89
|
-
require('../_baseAssignValue-cjs.js');
|
|
90
|
-
require('../_baseFlatten-cjs.js');
|
|
91
|
-
require('../_setToString-cjs.js');
|
|
92
84
|
require('../DataListEmptyState-cjs.js');
|
|
93
85
|
require('../DataListLoadMore-cjs.js');
|
|
94
86
|
require('../DataListAction-cjs.js');
|
package/dist/DataList/index.mjs
CHANGED
|
@@ -79,14 +79,6 @@ import '../InputText/index.mjs';
|
|
|
79
79
|
import '../FormField-es.js';
|
|
80
80
|
import '../useFormFieldFocus-es.js';
|
|
81
81
|
import '../InputValidation-es.js';
|
|
82
|
-
import '../omit-es.js';
|
|
83
|
-
import '../_baseGet-es.js';
|
|
84
|
-
import '../identity-es.js';
|
|
85
|
-
import '../isSymbol-es.js';
|
|
86
|
-
import '../keysIn-es.js';
|
|
87
|
-
import '../_baseAssignValue-es.js';
|
|
88
|
-
import '../_baseFlatten-es.js';
|
|
89
|
-
import '../_setToString-es.js';
|
|
90
82
|
import '../DataListEmptyState-es.js';
|
|
91
83
|
import '../DataListLoadMore-es.js';
|
|
92
84
|
import '../DataListAction-es.js';
|
package/dist/DataTable/index.cjs
CHANGED
|
@@ -13,12 +13,12 @@ require('../Content-cjs.js');
|
|
|
13
13
|
require('../Select/index.cjs');
|
|
14
14
|
require('../omit-cjs.js');
|
|
15
15
|
require('../_commonjsHelpers-cjs.js');
|
|
16
|
-
require('../
|
|
16
|
+
require('../_getAllKeys-cjs.js');
|
|
17
17
|
require('../isTypedArray-cjs.js');
|
|
18
18
|
require('../isObjectLike-cjs.js');
|
|
19
|
+
require('../isSymbol-cjs.js');
|
|
19
20
|
require('../identity-cjs.js');
|
|
20
21
|
require('../_getTag-cjs.js');
|
|
21
|
-
require('../isSymbol-cjs.js');
|
|
22
22
|
require('../keysIn-cjs.js');
|
|
23
23
|
require('../_baseAssignValue-cjs.js');
|
|
24
24
|
require('../_baseFlatten-cjs.js');
|
package/dist/DataTable/index.mjs
CHANGED
|
@@ -11,12 +11,12 @@ import '../Content-es.js';
|
|
|
11
11
|
import '../Select/index.mjs';
|
|
12
12
|
import '../omit-es.js';
|
|
13
13
|
import '../_commonjsHelpers-es.js';
|
|
14
|
-
import '../
|
|
14
|
+
import '../_getAllKeys-es.js';
|
|
15
15
|
import '../isTypedArray-es.js';
|
|
16
16
|
import '../isObjectLike-es.js';
|
|
17
|
+
import '../isSymbol-es.js';
|
|
17
18
|
import '../identity-es.js';
|
|
18
19
|
import '../_getTag-es.js';
|
|
19
|
-
import '../isSymbol-es.js';
|
|
20
20
|
import '../keysIn-es.js';
|
|
21
21
|
import '../_baseAssignValue-es.js';
|
|
22
22
|
import '../_baseFlatten-es.js';
|
|
@@ -16,12 +16,12 @@ require('../Icon-cjs.js');
|
|
|
16
16
|
require('@jobber/design');
|
|
17
17
|
require('../omit-cjs.js');
|
|
18
18
|
require('../_commonjsHelpers-cjs.js');
|
|
19
|
-
require('../
|
|
19
|
+
require('../_getAllKeys-cjs.js');
|
|
20
20
|
require('../isTypedArray-cjs.js');
|
|
21
21
|
require('../isObjectLike-cjs.js');
|
|
22
|
+
require('../isSymbol-cjs.js');
|
|
22
23
|
require('../identity-cjs.js');
|
|
23
24
|
require('../_getTag-cjs.js');
|
|
24
|
-
require('../isSymbol-cjs.js');
|
|
25
25
|
require('../keysIn-cjs.js');
|
|
26
26
|
require('../_baseAssignValue-cjs.js');
|
|
27
27
|
require('../_baseFlatten-cjs.js');
|
|
@@ -14,12 +14,12 @@ import '../Icon-es.js';
|
|
|
14
14
|
import '@jobber/design';
|
|
15
15
|
import '../omit-es.js';
|
|
16
16
|
import '../_commonjsHelpers-es.js';
|
|
17
|
-
import '../
|
|
17
|
+
import '../_getAllKeys-es.js';
|
|
18
18
|
import '../isTypedArray-es.js';
|
|
19
19
|
import '../isObjectLike-es.js';
|
|
20
|
+
import '../isSymbol-es.js';
|
|
20
21
|
import '../identity-es.js';
|
|
21
22
|
import '../_getTag-es.js';
|
|
22
|
-
import '../isSymbol-es.js';
|
|
23
23
|
import '../keysIn-es.js';
|
|
24
24
|
import '../_baseAssignValue-es.js';
|
|
25
25
|
import '../_baseFlatten-es.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ChangeEvent, ReactNode, RefObject } from "react";
|
|
1
|
+
import type { AriaAttributes, ChangeEvent, ReactNode, RefObject } from "react";
|
|
2
2
|
import type React from "react";
|
|
3
3
|
import type { RegisterOptions } from "react-hook-form";
|
|
4
4
|
import type { XOR } from "ts-xor";
|
|
@@ -7,6 +7,222 @@ import type { IconNames } from "../Icon";
|
|
|
7
7
|
export type FormFieldTypes = "text" | "password" | "number" | "time" | "textarea" | "select" | "tel" | "email";
|
|
8
8
|
export type KeyBoardTypes = "text" | "none" | "tel" | "url" | "email" | "numeric" | "decimal";
|
|
9
9
|
export type AutocompleteTypes = "one-time-code" | "address-line1" | "address-line2";
|
|
10
|
+
/**
|
|
11
|
+
* Core ARIA attributes for input elements.
|
|
12
|
+
* Uses camelCase naming for consistency with React props pattern.
|
|
13
|
+
* Based on React's canonical ARIA type definitions.
|
|
14
|
+
*/
|
|
15
|
+
export interface AriaInputProps {
|
|
16
|
+
/**
|
|
17
|
+
* Defines a string value that labels the current element.
|
|
18
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-label}
|
|
19
|
+
*/
|
|
20
|
+
readonly ariaLabel?: AriaAttributes["aria-label"];
|
|
21
|
+
/**
|
|
22
|
+
* Identifies the element (or elements) that labels the current element.
|
|
23
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-labelledby}
|
|
24
|
+
*/
|
|
25
|
+
readonly ariaLabelledBy?: AriaAttributes["aria-labelledby"];
|
|
26
|
+
/**
|
|
27
|
+
* Identifies the element (or elements) that describes the object.
|
|
28
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-describedby}
|
|
29
|
+
*/
|
|
30
|
+
readonly ariaDescribedBy?: AriaAttributes["aria-describedby"];
|
|
31
|
+
/**
|
|
32
|
+
* Identifies the element (or elements) that provide a detailed, extended description.
|
|
33
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-details}
|
|
34
|
+
*/
|
|
35
|
+
readonly ariaDetails?: AriaAttributes["aria-details"];
|
|
36
|
+
/**
|
|
37
|
+
* ID of the currently active descendant element.
|
|
38
|
+
* Used for composite widgets like combobox or listbox.
|
|
39
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-activedescendant}
|
|
40
|
+
*/
|
|
41
|
+
readonly ariaActiveDescendant?: AriaAttributes["aria-activedescendant"];
|
|
42
|
+
/**
|
|
43
|
+
* Indicates the entered value does not conform to the format expected.
|
|
44
|
+
* Supports boolean or specific error types: "grammar" | "spelling".
|
|
45
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-invalid}
|
|
46
|
+
*/
|
|
47
|
+
readonly ariaInvalid?: AriaAttributes["aria-invalid"];
|
|
48
|
+
/**
|
|
49
|
+
* Indicates the element that controls the current element.
|
|
50
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-controls}
|
|
51
|
+
*/
|
|
52
|
+
readonly ariaControls?: AriaAttributes["aria-controls"];
|
|
53
|
+
/**
|
|
54
|
+
* Indicates whether the element is expanded or collapsed.
|
|
55
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-expanded}
|
|
56
|
+
*/
|
|
57
|
+
readonly ariaExpanded?: AriaAttributes["aria-expanded"];
|
|
58
|
+
/**
|
|
59
|
+
* Indicates the type of autocomplete interaction.
|
|
60
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-autocomplete}
|
|
61
|
+
*/
|
|
62
|
+
readonly ariaAutocomplete?: AriaAttributes["aria-autocomplete"];
|
|
63
|
+
/**
|
|
64
|
+
* Indicates that user input is required before form submission.
|
|
65
|
+
* @see {@link https://www.w3.org/TR/wai-aria-1.2/#aria-required}
|
|
66
|
+
*/
|
|
67
|
+
readonly ariaRequired?: AriaAttributes["aria-required"];
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Focus event handlers for input elements.
|
|
71
|
+
* Generic interface that can be specialized for different element types.
|
|
72
|
+
*/
|
|
73
|
+
export interface FocusEvents<Target = HTMLElement> {
|
|
74
|
+
/**
|
|
75
|
+
* Focus event handler.
|
|
76
|
+
*/
|
|
77
|
+
readonly onFocus?: (event: React.FocusEvent<Target>) => void;
|
|
78
|
+
/**
|
|
79
|
+
* Blur event handler.
|
|
80
|
+
*/
|
|
81
|
+
readonly onBlur?: (event: React.FocusEvent<Target>) => void;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Keyboard event handlers for input elements.
|
|
85
|
+
* Generic interface that can be specialized for different element types.
|
|
86
|
+
*/
|
|
87
|
+
export interface KeyboardEvents<Target = HTMLElement> {
|
|
88
|
+
/**
|
|
89
|
+
* Key down event handler.
|
|
90
|
+
*/
|
|
91
|
+
readonly onKeyDown?: (event: React.KeyboardEvent<Target>) => void;
|
|
92
|
+
/**
|
|
93
|
+
* Key up event handler.
|
|
94
|
+
*/
|
|
95
|
+
readonly onKeyUp?: (event: React.KeyboardEvent<Target>) => void;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Curated set of HTML input attributes for rebuilt input components.
|
|
99
|
+
* This provides a whitelist of standard HTML/React props we want to support,
|
|
100
|
+
* avoiding the issues of extending React.InputHTMLAttributes directly.
|
|
101
|
+
* Note: Event handlers and ARIA attributes are separate - use FocusEvents, KeyboardEvents, and AriaInputProps.
|
|
102
|
+
*/
|
|
103
|
+
export interface HTMLInputBaseProps extends AriaInputProps {
|
|
104
|
+
/**
|
|
105
|
+
* The unique identifier for the input element.
|
|
106
|
+
*/
|
|
107
|
+
readonly id?: string;
|
|
108
|
+
/**
|
|
109
|
+
* The name attribute for the input element.
|
|
110
|
+
*/
|
|
111
|
+
readonly name?: string;
|
|
112
|
+
/**
|
|
113
|
+
* Placeholder text that appears when the input is empty.
|
|
114
|
+
*/
|
|
115
|
+
readonly placeholder?: string;
|
|
116
|
+
/**
|
|
117
|
+
* Whether the input is disabled.
|
|
118
|
+
*/
|
|
119
|
+
readonly disabled?: boolean;
|
|
120
|
+
/**
|
|
121
|
+
* Whether the input is required.
|
|
122
|
+
*/
|
|
123
|
+
readonly required?: boolean;
|
|
124
|
+
/**
|
|
125
|
+
* Whether the input is read-only (HTML standard casing).
|
|
126
|
+
*/
|
|
127
|
+
readonly readOnly?: boolean;
|
|
128
|
+
/**
|
|
129
|
+
* Whether the input should be auto-focused (React casing).
|
|
130
|
+
*/
|
|
131
|
+
readonly autoFocus?: boolean;
|
|
132
|
+
/**
|
|
133
|
+
* Autocomplete behavior for the input (React casing, string values only).
|
|
134
|
+
* Use standard HTML autocomplete values or "on"/"off".
|
|
135
|
+
*/
|
|
136
|
+
readonly autoComplete?: string;
|
|
137
|
+
/**
|
|
138
|
+
* Maximum character length for the input (HTML validation only).
|
|
139
|
+
* Note: In v2, this does NOT affect the visual width of the component.
|
|
140
|
+
* Use CSS or the size prop for width control.
|
|
141
|
+
*/
|
|
142
|
+
readonly maxLength?: number;
|
|
143
|
+
/**
|
|
144
|
+
* Minimum character length for the input.
|
|
145
|
+
*/
|
|
146
|
+
readonly minLength?: number;
|
|
147
|
+
/**
|
|
148
|
+
* Maximum numerical value (for number inputs).
|
|
149
|
+
*/
|
|
150
|
+
readonly max?: number | string;
|
|
151
|
+
/**
|
|
152
|
+
* Minimum numerical value (for number inputs).
|
|
153
|
+
*/
|
|
154
|
+
readonly min?: number | string;
|
|
155
|
+
/**
|
|
156
|
+
* Validation pattern (regex) for the input.
|
|
157
|
+
*/
|
|
158
|
+
readonly pattern?: string;
|
|
159
|
+
/**
|
|
160
|
+
* Input mode hint for virtual keyboards.
|
|
161
|
+
*/
|
|
162
|
+
readonly inputMode?: "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | "search";
|
|
163
|
+
/**
|
|
164
|
+
* Role attribute for accessibility.
|
|
165
|
+
*/
|
|
166
|
+
readonly role?: string;
|
|
167
|
+
/**
|
|
168
|
+
* Tab index for keyboard navigation.
|
|
169
|
+
*/
|
|
170
|
+
readonly tabIndex?: number;
|
|
171
|
+
}
|
|
172
|
+
/**
|
|
173
|
+
* Common props shared across all rebuilt input components.
|
|
174
|
+
* These are Atlantis-specific features not part of standard HTML inputs.
|
|
175
|
+
*/
|
|
176
|
+
export interface RebuiltInputCommonProps {
|
|
177
|
+
/**
|
|
178
|
+
* Error message to display. This also highlights the field red.
|
|
179
|
+
*/
|
|
180
|
+
readonly error?: string;
|
|
181
|
+
/**
|
|
182
|
+
* Highlights the field red to indicate an error.
|
|
183
|
+
*/
|
|
184
|
+
readonly invalid?: boolean;
|
|
185
|
+
/**
|
|
186
|
+
* Show a spinner to indicate loading.
|
|
187
|
+
*/
|
|
188
|
+
readonly loading?: boolean;
|
|
189
|
+
/**
|
|
190
|
+
* Add a clear action on the input that clears the value.
|
|
191
|
+
*/
|
|
192
|
+
readonly clearable?: Clearable;
|
|
193
|
+
/**
|
|
194
|
+
* Adjusts the interface to either have small or large spacing.
|
|
195
|
+
*/
|
|
196
|
+
readonly size?: "small" | "large";
|
|
197
|
+
/**
|
|
198
|
+
* Adjusts the form field to go inline with content.
|
|
199
|
+
*/
|
|
200
|
+
readonly inline?: boolean;
|
|
201
|
+
/**
|
|
202
|
+
* Determines the alignment of the text inside the input.
|
|
203
|
+
*/
|
|
204
|
+
readonly align?: "center" | "right";
|
|
205
|
+
/**
|
|
206
|
+
* Adds a prefix label and icon to the field.
|
|
207
|
+
*/
|
|
208
|
+
readonly prefix?: Affix;
|
|
209
|
+
/**
|
|
210
|
+
* Adds a suffix label and icon with an optional action to the field.
|
|
211
|
+
*/
|
|
212
|
+
readonly suffix?: XOR<Affix, Suffix>;
|
|
213
|
+
/**
|
|
214
|
+
* Further description of the input, can be used for a hint.
|
|
215
|
+
*/
|
|
216
|
+
readonly description?: ReactNode;
|
|
217
|
+
/**
|
|
218
|
+
* Children elements to render inside the component.
|
|
219
|
+
*/
|
|
220
|
+
readonly children?: ReactNode;
|
|
221
|
+
/**
|
|
222
|
+
* Version 2 is highly experimental. Avoid using it unless you have talked with Atlantis first.
|
|
223
|
+
*/
|
|
224
|
+
readonly version: 2;
|
|
225
|
+
}
|
|
10
226
|
export interface FieldActionsRef {
|
|
11
227
|
setValue(value: string | number): void;
|
|
12
228
|
}
|
package/dist/FormField-cjs.js
CHANGED
|
@@ -467,7 +467,6 @@ exports.FormFieldWrapper = FormFieldWrapper;
|
|
|
467
467
|
exports.FormFieldWrapperMain = FormFieldWrapperMain;
|
|
468
468
|
exports.FormFieldWrapperToolbar = FormFieldWrapperToolbar;
|
|
469
469
|
exports.mergeRefs = mergeRefs;
|
|
470
|
-
exports.styles = styles$1;
|
|
471
470
|
exports.useAtlantisFormField = useAtlantisFormField;
|
|
472
471
|
exports.useAtlantisFormFieldActions = useAtlantisFormFieldActions;
|
|
473
472
|
exports.useAtlantisFormFieldName = useAtlantisFormFieldName;
|
package/dist/FormField-es.js
CHANGED
|
@@ -454,4 +454,4 @@ function setAutocomplete(autocompleteSetting) {
|
|
|
454
454
|
return autocompleteSetting;
|
|
455
455
|
}
|
|
456
456
|
|
|
457
|
-
export { AffixIcon as A, FormFieldInputHorizontalWrapper as F, useAtlantisFormFieldActions as a, useAtlantisFormFieldName as b, useAtlantisReactHookForm as c, FormFieldInputWrapperStyles as d, FormFieldLabel as e, FormFieldWrapper as f, FormFieldWrapperMain as g, FormFieldWrapperToolbar as h, AffixLabel as i, useFormFieldWrapperStyles as j, FormField as k, FormFieldPostFix as l, mergeRefs as m,
|
|
457
|
+
export { AffixIcon as A, FormFieldInputHorizontalWrapper as F, useAtlantisFormFieldActions as a, useAtlantisFormFieldName as b, useAtlantisReactHookForm as c, FormFieldInputWrapperStyles as d, FormFieldLabel as e, FormFieldWrapper as f, FormFieldWrapperMain as g, FormFieldWrapperToolbar as h, AffixLabel as i, useFormFieldWrapperStyles as j, FormField as k, FormFieldPostFix as l, mergeRefs as m, useAtlantisFormField as u };
|