@jobber/components 4.67.2-JOB-84261.6 → 4.67.2-pre.25
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/AnimatedSwitcher/index.js +2 -2
- package/dist/{AnimatedSwitcher-d1e1ddcf.js → AnimatedSwitcher-879d0d6f.js} +1 -1
- package/dist/Autocomplete/index.js +13 -15
- package/dist/Avatar/index.js +2 -3
- package/dist/{Avatar-76a799fa.js → Avatar-765d6e45.js} +1 -4
- package/dist/Banner/index.js +4 -9
- package/dist/Button/index.js +3 -4
- package/dist/Button-8bde6560.js +54 -0
- package/dist/ButtonDismiss/index.js +4 -5
- package/dist/{ButtonDismiss-2b98d075.js → ButtonDismiss-af17d76d.js} +1 -1
- package/dist/Card/index.js +7 -8
- package/dist/Card-9dfc98d3.js +88 -0
- package/dist/Checkbox/index.js +5 -7
- package/dist/{Checkbox-ad7ec2e7.js → Checkbox-2d7c43d9.js} +5 -8
- package/dist/Chip/index.js +8 -7
- package/dist/Chip-dca6c22b.js +86 -0
- package/dist/Chips/index.js +12 -16
- package/dist/ClientOnly-4f3e136d.js +23 -0
- package/dist/Combobox/index.js +11 -10
- package/dist/{Combobox-eb1e5817.js → Combobox-35a3ea22.js} +43 -24
- package/dist/ConfirmationModal/index.js +14 -13
- package/dist/{ConfirmationModal-0f85d96c.js → ConfirmationModal-f6c0afc7.js} +3 -3
- package/dist/Content/index.js +1 -2
- package/dist/{Content-2ca1ffe1.js → Content-80486307.js} +0 -5
- package/dist/DataDump/index.js +9 -10
- package/dist/DataList/components/DataListHeader/DataListHeaderCheckbox.d.ts +1 -2
- package/dist/DataList/components/DataListHeaderTile/DataListSortingArrows.d.ts +1 -1
- package/dist/DataList/hooks/useMediaQuery.d.ts +3 -1
- package/dist/DataList/index.js +31 -56
- package/dist/DataTable/DataTable.d.ts +1 -1
- package/dist/DataTable/index.js +18 -22
- package/dist/DatePicker/index.js +4 -5
- package/dist/DatePicker-9399cc69.js +131 -0
- package/dist/DescriptionList/index.js +1 -4
- package/dist/Disclosure/index.js +2 -5
- package/dist/Divider/index.js +0 -3
- package/dist/Drawer/index.js +5 -10
- package/dist/Emphasis/index.js +2 -3
- package/dist/{Emphasis-b2d1b3aa.js → Emphasis-7a2893bb.js} +1 -1
- package/dist/FeatureSwitch/index.js +11 -13
- package/dist/Flex/index.js +6 -4
- package/dist/Form/index.js +1 -1
- package/dist/FormField/FormFieldTypes.d.ts +8 -0
- package/dist/FormField/FormFieldWrapper.d.ts +3 -1
- package/dist/FormField/components/ClearAction.d.ts +9 -0
- package/dist/FormField/index.js +9 -10
- package/dist/FormField-18eda132.js +252 -0
- package/dist/FormatDate/index.js +1 -1
- package/dist/FormatEmail/index.js +0 -3
- package/dist/FormatFile/index.js +17 -17
- package/dist/FormatFile-317b158a.js +116 -0
- package/dist/FormatTime/FormatTime.d.ts +1 -2
- package/dist/FormatTime/index.js +11 -6
- package/dist/Gallery/index.js +18 -20
- package/dist/Glimmer/index.js +3 -4
- package/dist/Glimmer-f5c31401.js +68 -0
- package/dist/Grid/index.js +0 -7
- package/dist/Heading/index.js +2 -3
- package/dist/{Heading-0f4ecb0c.js → Heading-f066883a.js} +1 -1
- package/dist/Icon/index.js +1 -1
- package/dist/InlineLabel/index.js +2 -3
- package/dist/InlineLabel-4c2fec47.js +25 -0
- package/dist/InputAvatar/index.js +8 -12
- package/dist/InputDate/InputDate.d.ts +1 -1
- package/dist/InputDate/index.js +10 -11
- package/dist/InputEmail/index.js +9 -10
- package/dist/InputFile/InputFile.d.ts +5 -1
- package/dist/InputFile/index.js +6 -8
- package/dist/{InputFile-540c1657.js → InputFile-5c44f0b4.js} +8 -11
- package/dist/InputGroup/index.js +1 -2
- package/dist/InputGroup-88bec8c9.js +30 -0
- package/dist/InputNumber/index.js +10 -11
- package/dist/{InputNumber-d9ebabaa.js → InputNumber-ed655bae.js} +1 -1
- package/dist/InputPassword/index.js +9 -10
- package/dist/InputPhoneNumber/index.js +9 -12
- package/dist/InputText/InputText.d.ts +2 -0
- package/dist/InputText/index.js +11 -11
- package/dist/InputText/useSafeLayoutEffect.d.ts +2 -0
- package/dist/{InputText-f7c45ee5.js → InputText-c68964ff.js} +3 -2
- package/dist/InputTime/InputTime.d.ts +3 -1
- package/dist/InputTime/InputTime.disabledTest.d.ts +1 -0
- package/dist/InputTime/InputTimeProps.d.ts +1 -1
- package/dist/InputTime/InternalInputTime.d.ts +3 -0
- package/dist/InputTime/SupportsTimePolyfill.d.ts +2 -0
- package/dist/InputTime/TimeInputPolyfill.client.d.ts +2 -0
- package/dist/InputTime/index.js +58 -724
- package/dist/InputValidation/index.js +4 -5
- package/dist/{InputValidation-179f0926.js → InputValidation-fdc891af.js} +2 -5
- package/dist/LightBox/ClientOnly.d.ts +6 -0
- package/dist/LightBox/LightBox.d.ts +2 -2
- package/dist/LightBox/index.js +6 -6
- package/dist/{LightBox-3f4dbc33.js → LightBox-d5aea313.js} +5 -6
- package/dist/List/index.js +9 -15
- package/dist/Markdown/Markdown.d.ts +1 -1
- package/dist/Markdown/index.js +8 -8
- package/dist/Markdown-10fc9d3e.js +90 -0
- package/dist/Menu/Menu.d.ts +4 -4
- package/dist/Menu/index.js +5 -6
- package/dist/{Menu-d7ea093c.js → Menu-7b7aa325.js} +7 -10
- package/dist/Modal/Modal.d.ts +2 -2
- package/dist/Modal/index.js +7 -7
- package/dist/{Modal-70daa0e2.js → Modal-357fd1df.js} +6 -9
- package/dist/MultiSelect/index.js +5 -11
- package/dist/{Option-469029b5.js → Option-c84f28a6.js} +1 -1
- package/dist/Page/index.js +12 -14
- package/dist/Popover/Popover.d.ts +2 -2
- package/dist/Popover/index.js +8 -8
- package/dist/ProgressBar/index.js +1 -2
- package/dist/ProgressBar-5c577dc0.js +38 -0
- package/dist/RadioGroup/index.js +3 -5
- package/dist/RadioGroup-9dded55d.js +44 -0
- package/dist/RecurringSelect/components/DayOfMonthSelect.d.ts +2 -2
- package/dist/RecurringSelect/components/WeeklySelect.d.ts +2 -2
- package/dist/RecurringSelect/index.js +16 -29
- package/dist/Select/index.js +10 -11
- package/dist/Spinner/index.js +1 -2
- package/dist/Spinner-cac356ee.js +21 -0
- package/dist/StatusLabel/index.js +2 -5
- package/dist/SupportsTimePolyfill-466a30f9.js +21 -0
- package/dist/Switch/index.js +2 -3
- package/dist/Switch-588c5e70.js +53 -0
- package/dist/Table/index.js +0 -5
- package/dist/Tabs/index.js +1 -4
- package/dist/Text/index.js +2 -3
- package/dist/{Text-4a2bc89f.js → Text-9f261dde.js} +1 -1
- package/dist/TimeInputPolyfill.client-1dfc8ab1.js +687 -0
- package/dist/Toast/index.js +3 -6
- package/dist/Tooltip/index.js +3 -2
- package/dist/{Tooltip-6b12f1c2.js → Tooltip-99440954.js} +14 -12
- package/dist/Typography/index.js +1 -2
- package/dist/Typography-75f58b60.js +43 -0
- package/dist/styles.css +8107 -0
- package/dist/useSafeLayoutEffect-b63708b1.js +16 -0
- package/package.json +4 -4
- package/rollup.config.js +3 -1
- package/dist/Button-163a0641.js +0 -57
- package/dist/Card-3178033c.js +0 -93
- package/dist/Chip-168acf3e.js +0 -89
- package/dist/DatePicker-c18f1739.js +0 -134
- package/dist/FormField-dfc061ca.js +0 -227
- package/dist/FormatFile-3b650d02.js +0 -121
- package/dist/Glimmer-cfa92a88.js +0 -77
- package/dist/InlineLabel-9a517c19.js +0 -28
- package/dist/InputGroup-8d4fd4eb.js +0 -33
- package/dist/Markdown-96070121.js +0 -62
- package/dist/ProgressBar-b68edc8f.js +0 -43
- package/dist/RadioGroup-ebaa4f87.js +0 -47
- package/dist/Spinner-9d8fc7ff.js +0 -24
- package/dist/Switch-b85272bf.js +0 -56
- package/dist/Typography-973b122e.js +0 -62
- package/dist/style-inject.es-9d2f5f4e.js +0 -30
- /package/dist/{FormatDate-70ea5b43.js → FormatDate-6fc94218.js} +0 -0
- /package/dist/{Icon-405a216c.js → Icon-361343e0.js} +0 -0
- /package/dist/{tslib.es6-5b8768b7.js → tslib.es6-a575af05.js} +0 -0
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var tslib_es6 = require('./tslib.es6-
|
|
3
|
+
var tslib_es6 = require('./tslib.es6-a575af05.js');
|
|
4
4
|
var React = require('react');
|
|
5
5
|
var classnames = require('classnames');
|
|
6
6
|
var reactDropzone = require('react-dropzone');
|
|
7
7
|
var axios = require('axios');
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var Content = require('./Content-2ca1ffe1.js');
|
|
12
|
-
var Typography = require('./Typography-973b122e.js');
|
|
8
|
+
var Button = require('./Button-8bde6560.js');
|
|
9
|
+
var Content = require('./Content-80486307.js');
|
|
10
|
+
var Typography = require('./Typography-75f58b60.js');
|
|
13
11
|
|
|
14
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
15
13
|
|
|
@@ -17,11 +15,10 @@ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
|
17
15
|
var classnames__default = /*#__PURE__*/_interopDefaultLegacy(classnames);
|
|
18
16
|
var axios__default = /*#__PURE__*/_interopDefaultLegacy(axios);
|
|
19
17
|
|
|
20
|
-
var css_248z = ".grljXfTWj84- {\n font-size: 0;\n line-height: 0;\n -webkit-user-select: none;\n -ms-user-select: none;\n user-select: none;\n cursor: pointer;\n}\n\n.grljXfTWj84-:focus,\n.grljXfTWj84-:focus-within {\n border-color: rgb(147, 161, 169);\n border-color: var(--color-focus);\n outline: none;\n}\n\n.WHhHWgaoXk4- {\n padding: calc(16px * 1);\n padding: var(--space-base);\n border: rgb(217, 223, 225) dashed calc(16px / 8);\n border: var(--color-border) dashed var(--border-thick);\n border-radius: calc(16px / 2);\n border-radius: var(--radius-larger);\n text-align: center;\n}\n\n.WHhHWgaoXk4-.n1h-T2metRA- {\n border-color: rgb(147, 161, 169);\n border-color: var(--color-focus);\n background-color: rgb(244, 246, 250);\n background-color: var(--color-surface--hover);\n}\n";
|
|
21
18
|
var styles = {"dropZoneBase":"grljXfTWj84-","dropZone":"WHhHWgaoXk4-","active":"n1h-T2metRA-"};
|
|
22
|
-
styleInject_es.styleInject(css_248z);
|
|
23
19
|
|
|
24
|
-
function InputFile({ variation = "dropzone", size = "base", buttonLabel: providedButtonLabel, allowMultiple = false, allowedTypes = "all", getUploadParams, onUploadStart, onUploadProgress, onUploadComplete, }) {
|
|
20
|
+
function InputFile({ variation = "dropzone", size = "base", buttonLabel: providedButtonLabel, allowMultiple = false, allowedTypes = "all", getUploadParams, name, onUploadStart, onUploadProgress, onUploadComplete, }) {
|
|
21
|
+
const id = React.useId();
|
|
25
22
|
const options = {
|
|
26
23
|
multiple: allowMultiple,
|
|
27
24
|
onDrop: React.useCallback(handleDrop, []),
|
|
@@ -39,7 +36,7 @@ function InputFile({ variation = "dropzone", size = "base", buttonLabel: provide
|
|
|
39
36
|
[styles.active]: isDragActive,
|
|
40
37
|
});
|
|
41
38
|
return (React__default["default"].createElement("div", Object.assign({}, getRootProps({ className: dropZone }), { tabIndex: variation === "button" ? -1 : 0 }),
|
|
42
|
-
React__default["default"].createElement("input", Object.assign({}, getInputProps())),
|
|
39
|
+
React__default["default"].createElement("input", Object.assign({ name: name }, getInputProps())),
|
|
43
40
|
variation === "dropzone" && (React__default["default"].createElement(Content.Content, { spacing: "small" },
|
|
44
41
|
React__default["default"].createElement(Button.Button, { label: buttonLabel, size: "small", type: "secondary" }),
|
|
45
42
|
size === "base" && (React__default["default"].createElement(Typography.Typography, { size: "small", textColor: "textSecondary" }, hintText)))),
|
|
@@ -51,7 +48,7 @@ function InputFile({ variation = "dropzone", size = "base", buttonLabel: provide
|
|
|
51
48
|
}
|
|
52
49
|
function uploadFile(file) {
|
|
53
50
|
return tslib_es6.__awaiter(this, void 0, void 0, function* () {
|
|
54
|
-
const { url, key =
|
|
51
|
+
const { url, key = id, fields = {}, httpMethod = "POST", } = yield getUploadParams(file);
|
|
55
52
|
const fileUpload = getFileUpload(file, key, url);
|
|
56
53
|
onUploadStart && onUploadStart(Object.assign({}, fileUpload));
|
|
57
54
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
package/dist/InputGroup/index.js
CHANGED
|
@@ -2,10 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var InputGroup = require('../InputGroup-
|
|
5
|
+
var InputGroup = require('../InputGroup-88bec8c9.js');
|
|
6
6
|
require('react');
|
|
7
7
|
require('classnames');
|
|
8
|
-
require('../style-inject.es-9d2f5f4e.js');
|
|
9
8
|
|
|
10
9
|
|
|
11
10
|
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var React = require('react');
|
|
4
|
+
var classnames = require('classnames');
|
|
5
|
+
|
|
6
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
7
|
+
|
|
8
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
9
|
+
var classnames__default = /*#__PURE__*/_interopDefaultLegacy(classnames);
|
|
10
|
+
|
|
11
|
+
var styles = {"vertical":"_4bvHwa3-qBA-","horizontal":"bHm4WuX8ToY-","inputGroup":"nmDPgrXofeE-"};
|
|
12
|
+
|
|
13
|
+
function InputGroup({ children, flowDirection = "vertical", }) {
|
|
14
|
+
if (isInvalidGroupNesting(children))
|
|
15
|
+
return React__default["default"].createElement(React__default["default"].Fragment, null);
|
|
16
|
+
const className = classnames__default["default"](styles.inputGroup, styles[flowDirection]);
|
|
17
|
+
return React__default["default"].createElement("div", { className: className }, children);
|
|
18
|
+
}
|
|
19
|
+
function isInvalidGroupNesting(childs) {
|
|
20
|
+
return React__default["default"].Children.toArray(childs).some(child => {
|
|
21
|
+
if (child.type === InputGroup &&
|
|
22
|
+
child.props.flowDirection != "horizontal") {
|
|
23
|
+
console.error(`ERROR: InputGroup not rendered: nesting 'flowDirection="vertical"' columns not supported.`, `https://atlantis.getjobber.com/?path=/story/components-forms-and-inputs-inputgroup-web--nested`);
|
|
24
|
+
return true;
|
|
25
|
+
}
|
|
26
|
+
return false;
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
exports.InputGroup = InputGroup;
|
|
@@ -2,23 +2,22 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var InputNumber = require('../InputNumber-
|
|
5
|
+
var InputNumber = require('../InputNumber-ed655bae.js');
|
|
6
6
|
require('react');
|
|
7
|
-
require('../FormField-
|
|
8
|
-
require('../tslib.es6-
|
|
9
|
-
require('uuid');
|
|
7
|
+
require('../FormField-18eda132.js');
|
|
8
|
+
require('../tslib.es6-a575af05.js');
|
|
10
9
|
require('react-hook-form');
|
|
11
|
-
require('../style-inject.es-9d2f5f4e.js');
|
|
12
10
|
require('classnames');
|
|
13
|
-
require('
|
|
11
|
+
require('@jobber/hooks/useShowClear');
|
|
12
|
+
require('../Button-8bde6560.js');
|
|
14
13
|
require('react-router-dom');
|
|
15
|
-
require('../Icon-
|
|
14
|
+
require('../Icon-361343e0.js');
|
|
16
15
|
require('@jobber/design');
|
|
17
|
-
require('../Typography-
|
|
18
|
-
require('../Text-
|
|
19
|
-
require('../InputValidation-
|
|
16
|
+
require('../Typography-75f58b60.js');
|
|
17
|
+
require('../Text-9f261dde.js');
|
|
18
|
+
require('../InputValidation-fdc891af.js');
|
|
20
19
|
require('framer-motion');
|
|
21
|
-
require('../Spinner-
|
|
20
|
+
require('../Spinner-cac356ee.js');
|
|
22
21
|
|
|
23
22
|
|
|
24
23
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var React = require('react');
|
|
4
|
-
var FormField = require('./FormField-
|
|
4
|
+
var FormField = require('./FormField-18eda132.js');
|
|
5
5
|
|
|
6
6
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
7
7
|
|
|
@@ -3,21 +3,20 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var React = require('react');
|
|
6
|
-
var FormField = require('../FormField-
|
|
7
|
-
require('../tslib.es6-
|
|
8
|
-
require('uuid');
|
|
6
|
+
var FormField = require('../FormField-18eda132.js');
|
|
7
|
+
require('../tslib.es6-a575af05.js');
|
|
9
8
|
require('react-hook-form');
|
|
10
|
-
require('../style-inject.es-9d2f5f4e.js');
|
|
11
9
|
require('classnames');
|
|
12
|
-
require('
|
|
10
|
+
require('@jobber/hooks/useShowClear');
|
|
11
|
+
require('../Button-8bde6560.js');
|
|
13
12
|
require('react-router-dom');
|
|
14
|
-
require('../Icon-
|
|
13
|
+
require('../Icon-361343e0.js');
|
|
15
14
|
require('@jobber/design');
|
|
16
|
-
require('../Typography-
|
|
17
|
-
require('../Text-
|
|
18
|
-
require('../InputValidation-
|
|
15
|
+
require('../Typography-75f58b60.js');
|
|
16
|
+
require('../Text-9f261dde.js');
|
|
17
|
+
require('../InputValidation-fdc891af.js');
|
|
19
18
|
require('framer-motion');
|
|
20
|
-
require('../Spinner-
|
|
19
|
+
require('../Spinner-cac356ee.js');
|
|
21
20
|
|
|
22
21
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
23
22
|
|
|
@@ -2,30 +2,27 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var tslib_es6 = require('../tslib.es6-
|
|
5
|
+
var tslib_es6 = require('../tslib.es6-a575af05.js');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var reactHookForm = require('react-hook-form');
|
|
8
|
-
var
|
|
9
|
-
var FormField = require('../FormField-dfc061ca.js');
|
|
10
|
-
require('uuid');
|
|
8
|
+
var FormField = require('../FormField-18eda132.js');
|
|
11
9
|
require('classnames');
|
|
12
|
-
require('
|
|
10
|
+
require('@jobber/hooks/useShowClear');
|
|
11
|
+
require('../Button-8bde6560.js');
|
|
13
12
|
require('react-router-dom');
|
|
14
|
-
require('../Icon-
|
|
13
|
+
require('../Icon-361343e0.js');
|
|
15
14
|
require('@jobber/design');
|
|
16
|
-
require('../Typography-
|
|
17
|
-
require('../Text-
|
|
18
|
-
require('../InputValidation-
|
|
15
|
+
require('../Typography-75f58b60.js');
|
|
16
|
+
require('../Text-9f261dde.js');
|
|
17
|
+
require('../InputValidation-fdc891af.js');
|
|
19
18
|
require('framer-motion');
|
|
20
|
-
require('../Spinner-
|
|
19
|
+
require('../Spinner-cac356ee.js');
|
|
21
20
|
|
|
22
21
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
23
22
|
|
|
24
23
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
25
24
|
|
|
26
|
-
var css_248z = ".L7WK-i5uaOk- {\n display: -ms-flexbox;\n display: flex;\n -ms-flex-align: center;\n align-items: center;\n position: absolute;\n top: 0;\n right: 0;\n left: 0;\n z-index: 1;\n z-index: var(--elevation-base);\n height: var(--field--height);\n padding-top: var(--field--padding-top);\n padding-bottom: var(--field--padding-bottom);\n padding-left: var(--field--padding-left);\n padding-right: var(--field--padding-right);\n color: rgb(181, 181, 181);\n color: var(--color-grey);\n font-family: inherit;\n font-size: inherit;\n line-height: var(--field--value-lineHeight);\n pointer-events: none;\n}\n\n.q1wXBupm5Xc- {\n visibility: hidden;\n opacity: 0;\n}\n";
|
|
27
25
|
var styles = {"mask":"L7WK-i5uaOk-","hiddenValue":"q1wXBupm5Xc-"};
|
|
28
|
-
styleInject_es.styleInject(css_248z);
|
|
29
26
|
|
|
30
27
|
function InputMask({ children, delimiter = "*", pattern, strict = true, }) {
|
|
31
28
|
const { value: inputValue, onChange } = children.props;
|
|
@@ -24,6 +24,7 @@ export declare const InputText: React.ForwardRefExoticComponent<({
|
|
|
24
24
|
readonly placeholder?: string | undefined;
|
|
25
25
|
readonly size?: "large" | "small" | undefined;
|
|
26
26
|
readonly value?: string | number | Date | undefined;
|
|
27
|
+
readonly clearable?: "always" | "never" | undefined;
|
|
27
28
|
onFocus?: (() => void) | undefined;
|
|
28
29
|
onBlur?: (() => void) | undefined;
|
|
29
30
|
readonly defaultValue?: string | Date | undefined;
|
|
@@ -61,6 +62,7 @@ export declare const InputText: React.ForwardRefExoticComponent<({
|
|
|
61
62
|
readonly placeholder?: string | undefined;
|
|
62
63
|
readonly size?: "large" | "small" | undefined;
|
|
63
64
|
readonly value?: string | number | Date | undefined;
|
|
65
|
+
readonly clearable?: "always" | "never" | undefined;
|
|
64
66
|
onFocus?: (() => void) | undefined;
|
|
65
67
|
onBlur?: (() => void) | undefined;
|
|
66
68
|
readonly defaultValue?: string | Date | undefined;
|
package/dist/InputText/index.js
CHANGED
|
@@ -2,23 +2,23 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var InputText = require('../InputText-
|
|
5
|
+
var InputText = require('../InputText-c68964ff.js');
|
|
6
6
|
require('react');
|
|
7
|
-
require('../
|
|
8
|
-
require('../
|
|
9
|
-
require('
|
|
7
|
+
require('../useSafeLayoutEffect-b63708b1.js');
|
|
8
|
+
require('../FormField-18eda132.js');
|
|
9
|
+
require('../tslib.es6-a575af05.js');
|
|
10
10
|
require('react-hook-form');
|
|
11
|
-
require('../style-inject.es-9d2f5f4e.js');
|
|
12
11
|
require('classnames');
|
|
13
|
-
require('
|
|
12
|
+
require('@jobber/hooks/useShowClear');
|
|
13
|
+
require('../Button-8bde6560.js');
|
|
14
14
|
require('react-router-dom');
|
|
15
|
-
require('../Icon-
|
|
15
|
+
require('../Icon-361343e0.js');
|
|
16
16
|
require('@jobber/design');
|
|
17
|
-
require('../Typography-
|
|
18
|
-
require('../Text-
|
|
19
|
-
require('../InputValidation-
|
|
17
|
+
require('../Typography-75f58b60.js');
|
|
18
|
+
require('../Text-9f261dde.js');
|
|
19
|
+
require('../InputValidation-fdc891af.js');
|
|
20
20
|
require('framer-motion');
|
|
21
|
-
require('../Spinner-
|
|
21
|
+
require('../Spinner-cac356ee.js');
|
|
22
22
|
|
|
23
23
|
|
|
24
24
|
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var React = require('react');
|
|
4
|
-
var
|
|
4
|
+
var useSafeLayoutEffect = require('./useSafeLayoutEffect-b63708b1.js');
|
|
5
|
+
var FormField = require('./FormField-18eda132.js');
|
|
5
6
|
|
|
6
7
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
7
8
|
|
|
@@ -34,7 +35,7 @@ function InputTextInternal(props, ref) {
|
|
|
34
35
|
}
|
|
35
36
|
},
|
|
36
37
|
}));
|
|
37
|
-
|
|
38
|
+
useSafeLayoutEffect.useSafeLayoutEffect(() => {
|
|
38
39
|
if (inputRef && inputRef.current instanceof HTMLTextAreaElement) {
|
|
39
40
|
resize(inputRef.current);
|
|
40
41
|
}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { InputTimeProps } from "./InputTimeProps";
|
|
3
|
-
|
|
3
|
+
declare function InputTimeSafe(props: InputTimeProps): JSX.Element;
|
|
4
|
+
export declare const InputTime: typeof InputTimeSafe | (() => null);
|
|
5
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CivilTime } from "@std-proposal/temporal";
|
|
2
2
|
import { CommonFormFieldProps, FormFieldProps } from "../FormField";
|
|
3
|
-
export interface InputTimeProps extends Pick<CommonFormFieldProps, "align" | "description" | "disabled" | "invalid" | "inline" | "loading" | "name" | "onValidation" | "placeholder" | "size">, Pick<FormFieldProps, "maxLength" | "readonly" | "autocomplete" | "max" | "min" | "onEnter" | "onFocus" | "onBlur" | "inputRef" | "validations"> {
|
|
3
|
+
export interface InputTimeProps extends Pick<CommonFormFieldProps, "align" | "description" | "disabled" | "invalid" | "inline" | "loading" | "name" | "onValidation" | "placeholder" | "size" | "clearable">, Pick<FormFieldProps, "maxLength" | "readonly" | "autocomplete" | "max" | "min" | "onEnter" | "onFocus" | "onBlur" | "inputRef" | "validations"> {
|
|
4
4
|
/**
|
|
5
5
|
* Intial value of the input. Only use this when you need to prepopulate the
|
|
6
6
|
* field with a data that is not controlled by the components state. If a
|