@trackunit/react-form-components 0.0.66 → 0.0.70
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/index.cjs +14355 -1195
- package/index.js +14372 -1206
- package/package.json +5 -5
- package/src/components/ActionButton/ActionButton.d.ts +26 -26
- package/src/components/ActionButton/index.d.ts +1 -1
- package/src/components/BaseInput/BaseInput.d.ts +62 -62
- package/src/components/BaseInput/index.d.ts +1 -1
- package/src/components/Checkbox/CheckIcon.d.ts +12 -12
- package/src/components/Checkbox/Checkbox.d.ts +48 -48
- package/src/components/Checkbox/IndeterminateIcon.d.ts +10 -10
- package/src/components/Checkbox/index.d.ts +1 -1
- package/src/components/DateField/DateField.d.ts +19 -19
- package/src/components/DateInput/DateInput.d.ts +28 -28
- package/src/components/DropZone/DropZone.d.ts +34 -34
- package/src/components/EmailField/EmailField.d.ts +17 -17
- package/src/components/EmailInput/EmailInput.d.ts +13 -13
- package/src/components/EmailInput/index.d.ts +1 -1
- package/src/components/FormGroup/FormGroup.d.ts +39 -39
- package/src/components/Label/Label.d.ts +34 -34
- package/src/components/Label/index.d.ts +1 -1
- package/src/components/NumberField/NumberField.d.ts +19 -19
- package/src/components/NumberInput/NumberInput.d.ts +12 -12
- package/src/components/OptionCard/OptionCard.d.ts +24 -24
- package/src/components/PhoneField/PhoneField.d.ts +28 -28
- package/src/components/PhoneInput/CountryCodeSelect.d.ts +23 -23
- package/src/components/PhoneInput/CountryCodes.d.ts +5 -5
- package/src/components/PhoneInput/PhoneInput.d.ts +34 -34
- package/src/components/PhoneInput/PhoneNumberUtilities.d.ts +13 -13
- package/src/components/PhoneInput/index.d.ts +1 -1
- package/src/components/RadioGroup/RadioGroup.d.ts +57 -57
- package/src/components/RadioGroup/RadioGroupContext.d.ts +11 -11
- package/src/components/RadioGroup/RadioItem.d.ts +23 -23
- package/src/components/RadioGroup/index.d.ts +2 -2
- package/src/components/Schedule/Schedule.d.ts +45 -37
- package/src/components/Schedule/Schedule.variants.d.ts +2 -2
- package/src/components/Search/Search.d.ts +62 -62
- package/src/components/Search/index.d.ts +1 -1
- package/src/components/Select/CreatableSelect.d.ts +38 -38
- package/src/components/Select/FieldContainer.d.ts +20 -20
- package/src/components/Select/Select.d.ts +18 -18
- package/src/components/Select/SelectMenuItem/SelectMenuItem.d.ts +49 -49
- package/src/components/Select/TagWithWidth.d.ts +17 -17
- package/src/components/Select/TagsContainer.d.ts +45 -45
- package/src/components/Select/index.d.ts +7 -7
- package/src/components/Select/shared.d.ts +15 -15
- package/src/components/Select/useCustomComponents.d.ts +19 -19
- package/src/components/Select/useCustomStyles.d.ts +14 -14
- package/src/components/Select/useSelect.d.ts +143 -143
- package/src/components/TextArea/TextArea.d.ts +30 -30
- package/src/components/TextArea/index.d.ts +1 -1
- package/src/components/TextAreaField/TextAreaField.d.ts +18 -18
- package/src/components/TextAreaField/index.d.ts +1 -1
- package/src/components/TextField/TextField.d.ts +24 -24
- package/src/components/TextField/TextLenghtIndicator.d.ts +19 -19
- package/src/components/TextField/index.d.ts +1 -1
- package/src/components/TextInput/TextInput.d.ts +12 -12
- package/src/components/TimeRange/TimeRange.d.ts +52 -52
- package/src/components/TimeRange/TimeRange.variants.d.ts +1 -3
- package/src/components/TimeRange/index.d.ts +1 -1
- package/src/components/TimeRangeField/TimeRangeField.d.ts +18 -18
- package/src/components/Toggle/Toggle.d.ts +61 -61
- package/src/components/Toggle/index.d.ts +1 -1
- package/src/components/UploadField/UploadField.d.ts +15 -15
- package/src/components/UploadInput/UploadInput.d.ts +33 -33
- package/src/index.d.ts +28 -28
- package/src/test-utils/hooks.d.ts +4 -4
- package/src/test-utils/test-utils.d.ts +5 -5
- package/src/translation.d.ts +34 -34
- package/src/utilities/usePhoneInput.d.ts +56 -56
package/package.json
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trackunit/react-form-components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.70",
|
|
4
4
|
"repository": "https://github.com/Trackunit/manager",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"engines": {
|
|
7
7
|
"node": ">=16.x"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@trackunit/css-class-variance-utilities": "0.0.
|
|
11
|
-
"@trackunit/i18n-library-translation": "0.0.
|
|
12
|
-
"@trackunit/react-components": "0.1.
|
|
13
|
-
"@trackunit/tailwind-styled-components": "0.0.
|
|
10
|
+
"@trackunit/css-class-variance-utilities": "0.0.6",
|
|
11
|
+
"@trackunit/i18n-library-translation": "0.0.59",
|
|
12
|
+
"@trackunit/react-components": "0.1.119",
|
|
13
|
+
"@trackunit/tailwind-styled-components": "0.0.58",
|
|
14
14
|
"date-fns": "2.29.3",
|
|
15
15
|
"libphonenumber-js": "1.10.36",
|
|
16
16
|
"react": "18.2.0",
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ButtonCommonProps, CommonProps } from "@trackunit/react-components";
|
|
3
|
-
type ActionType = "PHONE_NUMBER" | "WEB_ADDRESS" | "EMAIL";
|
|
4
|
-
type FieldSize = "small" | "medium";
|
|
5
|
-
interface ActionButtonProps extends ButtonCommonProps, CommonProps {
|
|
6
|
-
/**
|
|
7
|
-
* The type of action performed when clicking the button.
|
|
8
|
-
*/
|
|
9
|
-
type: ActionType;
|
|
10
|
-
/**
|
|
11
|
-
* The value to be passed into the button.
|
|
12
|
-
*/
|
|
13
|
-
value?: string | null;
|
|
14
|
-
/**
|
|
15
|
-
* The size of the icon.
|
|
16
|
-
*/
|
|
17
|
-
iconSize?: FieldSize;
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* The ActionButton component is a wrapper over IconButton to perform an action when the onClick event is triggered.
|
|
21
|
-
*
|
|
22
|
-
* @param {ActionButtonProps} props - The props for the ActionButton component
|
|
23
|
-
* @returns {JSX.Element} ActionButton component
|
|
24
|
-
*/
|
|
25
|
-
export declare const ActionButton: ({ type, value, dataTestId, iconSize, disabled }: ActionButtonProps) => JSX.Element;
|
|
26
|
-
export {};
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ButtonCommonProps, CommonProps } from "@trackunit/react-components";
|
|
3
|
+
type ActionType = "PHONE_NUMBER" | "WEB_ADDRESS" | "EMAIL";
|
|
4
|
+
type FieldSize = "small" | "medium";
|
|
5
|
+
interface ActionButtonProps extends ButtonCommonProps, CommonProps {
|
|
6
|
+
/**
|
|
7
|
+
* The type of action performed when clicking the button.
|
|
8
|
+
*/
|
|
9
|
+
type: ActionType;
|
|
10
|
+
/**
|
|
11
|
+
* The value to be passed into the button.
|
|
12
|
+
*/
|
|
13
|
+
value?: string | null;
|
|
14
|
+
/**
|
|
15
|
+
* The size of the icon.
|
|
16
|
+
*/
|
|
17
|
+
iconSize?: FieldSize;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* The ActionButton component is a wrapper over IconButton to perform an action when the onClick event is triggered.
|
|
21
|
+
*
|
|
22
|
+
* @param {ActionButtonProps} props - The props for the ActionButton component
|
|
23
|
+
* @returns {JSX.Element} ActionButton component
|
|
24
|
+
*/
|
|
25
|
+
export declare const ActionButton: ({ type, value, dataTestId, iconSize, disabled }: ActionButtonProps) => JSX.Element;
|
|
26
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "./ActionButton";
|
|
1
|
+
export * from "./ActionButton";
|
|
@@ -1,62 +1,62 @@
|
|
|
1
|
-
import { CommonProps } from "@trackunit/react-components";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
type FilteredInputProps = Omit<React.InputHTMLAttributes<HTMLInputElement>, "prefix" | "suffix">;
|
|
4
|
-
type FieldSize = "small" | "medium";
|
|
5
|
-
export interface BaseInputProps extends FilteredInputProps, CommonProps {
|
|
6
|
-
/**
|
|
7
|
-
* A React element to render before the text in the input.
|
|
8
|
-
* This is typically used to render an icon.
|
|
9
|
-
* For elements other than icons, please consider using the addonBefore prop.
|
|
10
|
-
*/
|
|
11
|
-
prefix?: React.ReactNode;
|
|
12
|
-
/**
|
|
13
|
-
* A React element to render after the text in the input.
|
|
14
|
-
* This is typically used to render an icon.
|
|
15
|
-
* For other elements than icons, please consider using the addonAfter prop.
|
|
16
|
-
*/
|
|
17
|
-
suffix?: React.ReactNode;
|
|
18
|
-
/**
|
|
19
|
-
* A React element to render in a separate container before the text in the input.
|
|
20
|
-
* This is typically used to render text.
|
|
21
|
-
* For icons, please consider using the prefix prop.
|
|
22
|
-
*/
|
|
23
|
-
addonBefore?: React.ReactNode;
|
|
24
|
-
/**
|
|
25
|
-
* A React element to render in a separate container after the text in the input.
|
|
26
|
-
* This is typically used to render text.
|
|
27
|
-
* For icons, please consider using the suffix prop.
|
|
28
|
-
*/
|
|
29
|
-
addonAfter?: React.ReactNode;
|
|
30
|
-
/**
|
|
31
|
-
* A ReactNode to render at the end of the input field before the addonAfter.
|
|
32
|
-
* Mainly meant for the icon button actions for special input types.
|
|
33
|
-
*/
|
|
34
|
-
actions?: React.ReactNode;
|
|
35
|
-
/**
|
|
36
|
-
* The size of the input.
|
|
37
|
-
* Default == 40px, Small == 32px.
|
|
38
|
-
*/
|
|
39
|
-
fieldSize?: FieldSize;
|
|
40
|
-
/**
|
|
41
|
-
* If true the field is rendered in its invalid state.
|
|
42
|
-
*/
|
|
43
|
-
isInvalid?: boolean;
|
|
44
|
-
/**
|
|
45
|
-
* The Placeholder text for the input.
|
|
46
|
-
*/
|
|
47
|
-
placeholder?: string;
|
|
48
|
-
/**
|
|
49
|
-
* A flag to disable interaction with input for example if you want to use input as a child of higher component
|
|
50
|
-
*/
|
|
51
|
-
nonInteractive?: boolean;
|
|
52
|
-
}
|
|
53
|
-
/**
|
|
54
|
-
* A base input component that can be used for text inputs, password inputs, etc.
|
|
55
|
-
* A reference to the input element is provided as the `ref` prop.
|
|
56
|
-
* Extends props from [React.InputHTMLAttributes](https://reactjs.org/docs/dom-elements.html#input)
|
|
57
|
-
*
|
|
58
|
-
* For specific input types make sure to use the corresponding input component.
|
|
59
|
-
* This is a base used by our other input components such as TextInput, NumberInput, PasswordInput, etc.
|
|
60
|
-
*/
|
|
61
|
-
export declare const BaseInput: React.ForwardRefExoticComponent<BaseInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
62
|
-
export {};
|
|
1
|
+
import { CommonProps } from "@trackunit/react-components";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
type FilteredInputProps = Omit<React.InputHTMLAttributes<HTMLInputElement>, "prefix" | "suffix">;
|
|
4
|
+
type FieldSize = "small" | "medium";
|
|
5
|
+
export interface BaseInputProps extends FilteredInputProps, CommonProps {
|
|
6
|
+
/**
|
|
7
|
+
* A React element to render before the text in the input.
|
|
8
|
+
* This is typically used to render an icon.
|
|
9
|
+
* For elements other than icons, please consider using the addonBefore prop.
|
|
10
|
+
*/
|
|
11
|
+
prefix?: React.ReactNode;
|
|
12
|
+
/**
|
|
13
|
+
* A React element to render after the text in the input.
|
|
14
|
+
* This is typically used to render an icon.
|
|
15
|
+
* For other elements than icons, please consider using the addonAfter prop.
|
|
16
|
+
*/
|
|
17
|
+
suffix?: React.ReactNode;
|
|
18
|
+
/**
|
|
19
|
+
* A React element to render in a separate container before the text in the input.
|
|
20
|
+
* This is typically used to render text.
|
|
21
|
+
* For icons, please consider using the prefix prop.
|
|
22
|
+
*/
|
|
23
|
+
addonBefore?: React.ReactNode;
|
|
24
|
+
/**
|
|
25
|
+
* A React element to render in a separate container after the text in the input.
|
|
26
|
+
* This is typically used to render text.
|
|
27
|
+
* For icons, please consider using the suffix prop.
|
|
28
|
+
*/
|
|
29
|
+
addonAfter?: React.ReactNode;
|
|
30
|
+
/**
|
|
31
|
+
* A ReactNode to render at the end of the input field before the addonAfter.
|
|
32
|
+
* Mainly meant for the icon button actions for special input types.
|
|
33
|
+
*/
|
|
34
|
+
actions?: React.ReactNode;
|
|
35
|
+
/**
|
|
36
|
+
* The size of the input.
|
|
37
|
+
* Default == 40px, Small == 32px.
|
|
38
|
+
*/
|
|
39
|
+
fieldSize?: FieldSize;
|
|
40
|
+
/**
|
|
41
|
+
* If true the field is rendered in its invalid state.
|
|
42
|
+
*/
|
|
43
|
+
isInvalid?: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* The Placeholder text for the input.
|
|
46
|
+
*/
|
|
47
|
+
placeholder?: string;
|
|
48
|
+
/**
|
|
49
|
+
* A flag to disable interaction with input for example if you want to use input as a child of higher component
|
|
50
|
+
*/
|
|
51
|
+
nonInteractive?: boolean;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* A base input component that can be used for text inputs, password inputs, etc.
|
|
55
|
+
* A reference to the input element is provided as the `ref` prop.
|
|
56
|
+
* Extends props from [React.InputHTMLAttributes](https://reactjs.org/docs/dom-elements.html#input)
|
|
57
|
+
*
|
|
58
|
+
* For specific input types make sure to use the corresponding input component.
|
|
59
|
+
* This is a base used by our other input components such as TextInput, NumberInput, PasswordInput, etc.
|
|
60
|
+
*/
|
|
61
|
+
export declare const BaseInput: React.ForwardRefExoticComponent<BaseInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
62
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "./BaseInput";
|
|
1
|
+
export * from "./BaseInput";
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { CommonProps } from "@trackunit/react-components";
|
|
3
|
-
interface CheckIconProps extends CommonProps {
|
|
4
|
-
}
|
|
5
|
-
/**
|
|
6
|
-
* The CheckIcon component is used by the checkbox to display the checked state.
|
|
7
|
-
*
|
|
8
|
-
* @param {CheckIconProps} props - The props for the CheckIcon component
|
|
9
|
-
* @returns {JSX.Element} CheckIcon component
|
|
10
|
-
*/
|
|
11
|
-
export declare const CheckIcon: ({ className, dataTestId }: CheckIconProps) => JSX.Element;
|
|
12
|
-
export {};
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { CommonProps } from "@trackunit/react-components";
|
|
3
|
+
interface CheckIconProps extends CommonProps {
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* The CheckIcon component is used by the checkbox to display the checked state.
|
|
7
|
+
*
|
|
8
|
+
* @param {CheckIconProps} props - The props for the CheckIcon component
|
|
9
|
+
* @returns {JSX.Element} CheckIcon component
|
|
10
|
+
*/
|
|
11
|
+
export declare const CheckIcon: ({ className, dataTestId }: CheckIconProps) => JSX.Element;
|
|
12
|
+
export {};
|
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
import { CommonProps } from "@trackunit/react-components";
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
export interface CheckboxProps extends CommonProps, React.InputHTMLAttributes<HTMLInputElement> {
|
|
4
|
-
/**
|
|
5
|
-
* A string element to be displayed as a label
|
|
6
|
-
*/
|
|
7
|
-
label?: React.ReactNode;
|
|
8
|
-
/**
|
|
9
|
-
* An element to display after the label
|
|
10
|
-
*/
|
|
11
|
-
suffix?: React.ReactNode;
|
|
12
|
-
/**
|
|
13
|
-
* An boolean flag to set checkbox to checked state
|
|
14
|
-
*/
|
|
15
|
-
checked?: boolean;
|
|
16
|
-
/**
|
|
17
|
-
* An boolean flag to set checkbox to disabled state
|
|
18
|
-
*/
|
|
19
|
-
disabled?: boolean;
|
|
20
|
-
/**
|
|
21
|
-
* An boolean flag to set invalid mode
|
|
22
|
-
* can be used for indicating errors
|
|
23
|
-
*/
|
|
24
|
-
isInvalid?: boolean;
|
|
25
|
-
/**
|
|
26
|
-
* An boolean flag to set checkbox to readonly mode
|
|
27
|
-
*/
|
|
28
|
-
readOnly?: boolean;
|
|
29
|
-
/**
|
|
30
|
-
* An boolean flag to set checkbox to intermediate state
|
|
31
|
-
*/
|
|
32
|
-
indeterminate?: boolean;
|
|
33
|
-
}
|
|
34
|
-
/**
|
|
35
|
-
* Checkboxes are used when there are multiple items to select in a list. Users can select zero, one, or any number of items.
|
|
36
|
-
*
|
|
37
|
-
* Checkboxes are used for multiple choices, not for mutually exclusive choices. Each checkbox works independently from other checkboxes in the list, therefore checking an additional box does not affect any other selections.
|
|
38
|
-
*
|
|
39
|
-
* _**Do use** checkboxes to allow selection in a form, for filtering, terms and conditions to indicate agreement, and bulk actions in lists or tables._
|
|
40
|
-
*
|
|
41
|
-
* _**Do not use** checkboxes if the user can only select one option from a list, radio buttons should be used instead of checkboxes._
|
|
42
|
-
*
|
|
43
|
-
* @description A reference to the input element is provided as the `ref` prop.
|
|
44
|
-
* @augments props from [React.InputHTMLAttributes](https://reactjs.org/docs/dom-elements.html#input)
|
|
45
|
-
* @param {CheckboxProps} props - The props for the Checkbox component
|
|
46
|
-
* @returns {JSX.Element} Checkbox component
|
|
47
|
-
*/
|
|
48
|
-
export declare const Checkbox: React.ForwardRefExoticComponent<CheckboxProps & React.RefAttributes<HTMLInputElement>>;
|
|
1
|
+
import { CommonProps } from "@trackunit/react-components";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
export interface CheckboxProps extends CommonProps, React.InputHTMLAttributes<HTMLInputElement> {
|
|
4
|
+
/**
|
|
5
|
+
* A string element to be displayed as a label
|
|
6
|
+
*/
|
|
7
|
+
label?: React.ReactNode;
|
|
8
|
+
/**
|
|
9
|
+
* An element to display after the label
|
|
10
|
+
*/
|
|
11
|
+
suffix?: React.ReactNode;
|
|
12
|
+
/**
|
|
13
|
+
* An boolean flag to set checkbox to checked state
|
|
14
|
+
*/
|
|
15
|
+
checked?: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* An boolean flag to set checkbox to disabled state
|
|
18
|
+
*/
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* An boolean flag to set invalid mode
|
|
22
|
+
* can be used for indicating errors
|
|
23
|
+
*/
|
|
24
|
+
isInvalid?: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* An boolean flag to set checkbox to readonly mode
|
|
27
|
+
*/
|
|
28
|
+
readOnly?: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* An boolean flag to set checkbox to intermediate state
|
|
31
|
+
*/
|
|
32
|
+
indeterminate?: boolean;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Checkboxes are used when there are multiple items to select in a list. Users can select zero, one, or any number of items.
|
|
36
|
+
*
|
|
37
|
+
* Checkboxes are used for multiple choices, not for mutually exclusive choices. Each checkbox works independently from other checkboxes in the list, therefore checking an additional box does not affect any other selections.
|
|
38
|
+
*
|
|
39
|
+
* _**Do use** checkboxes to allow selection in a form, for filtering, terms and conditions to indicate agreement, and bulk actions in lists or tables._
|
|
40
|
+
*
|
|
41
|
+
* _**Do not use** checkboxes if the user can only select one option from a list, radio buttons should be used instead of checkboxes._
|
|
42
|
+
*
|
|
43
|
+
* @description A reference to the input element is provided as the `ref` prop.
|
|
44
|
+
* @augments props from [React.InputHTMLAttributes](https://reactjs.org/docs/dom-elements.html#input)
|
|
45
|
+
* @param {CheckboxProps} props - The props for the Checkbox component
|
|
46
|
+
* @returns {JSX.Element} Checkbox component
|
|
47
|
+
*/
|
|
48
|
+
export declare const Checkbox: React.ForwardRefExoticComponent<CheckboxProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
/**
|
|
3
|
-
* The IndeterminateIcon component is used by the checkbox to display the Indeterminate state.
|
|
4
|
-
*
|
|
5
|
-
* @param {IndeterminateIconProps} props - The props for the IndeterminateIcon component
|
|
6
|
-
* @returns {JSX.Element} IndeterminateIcon component
|
|
7
|
-
*/
|
|
8
|
-
export declare const IndeterminateIcon: ({ className }: {
|
|
9
|
-
className?: string | undefined;
|
|
10
|
-
}) => JSX.Element;
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* The IndeterminateIcon component is used by the checkbox to display the Indeterminate state.
|
|
4
|
+
*
|
|
5
|
+
* @param {IndeterminateIconProps} props - The props for the IndeterminateIcon component
|
|
6
|
+
* @returns {JSX.Element} IndeterminateIcon component
|
|
7
|
+
*/
|
|
8
|
+
export declare const IndeterminateIcon: ({ className }: {
|
|
9
|
+
className?: string | undefined;
|
|
10
|
+
}) => JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "./Checkbox";
|
|
1
|
+
export * from "./Checkbox";
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { DateInputProps } from "../DateInput/DateInput";
|
|
3
|
-
import { FormGroupProps } from "../FormGroup/FormGroup";
|
|
4
|
-
type FormGroupExposedProps = Pick<FormGroupProps, "label" | "tip" | "helpText" | "helpAddon">;
|
|
5
|
-
export interface DateFieldProps extends DateInputProps, FormGroupExposedProps {
|
|
6
|
-
/**
|
|
7
|
-
* If a value is set, the field is rendered in its invalid state.
|
|
8
|
-
*/
|
|
9
|
-
errorMessage?: string;
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* The date field component is used for entering date values.
|
|
13
|
-
*
|
|
14
|
-
* _**Do use**_ the DateField for date input.
|
|
15
|
-
*
|
|
16
|
-
* _**Do not use**_ this fields for non-serialized dates. Use TextField instead.
|
|
17
|
-
*/
|
|
18
|
-
export declare const DateField: import("react").ForwardRefExoticComponent<DateFieldProps & import("react").RefAttributes<HTMLInputElement>>;
|
|
19
|
-
export {};
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { DateInputProps } from "../DateInput/DateInput";
|
|
3
|
+
import { FormGroupProps } from "../FormGroup/FormGroup";
|
|
4
|
+
type FormGroupExposedProps = Pick<FormGroupProps, "label" | "tip" | "helpText" | "helpAddon">;
|
|
5
|
+
export interface DateFieldProps extends DateInputProps, FormGroupExposedProps {
|
|
6
|
+
/**
|
|
7
|
+
* If a value is set, the field is rendered in its invalid state.
|
|
8
|
+
*/
|
|
9
|
+
errorMessage?: string;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* The date field component is used for entering date values.
|
|
13
|
+
*
|
|
14
|
+
* _**Do use**_ the DateField for date input.
|
|
15
|
+
*
|
|
16
|
+
* _**Do not use**_ this fields for non-serialized dates. Use TextField instead.
|
|
17
|
+
*/
|
|
18
|
+
export declare const DateField: import("react").ForwardRefExoticComponent<DateFieldProps & import("react").RefAttributes<HTMLInputElement>>;
|
|
19
|
+
export {};
|
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { BaseInputProps } from "../BaseInput";
|
|
3
|
-
type BaseInputExposedProps = Omit<BaseInputProps, "defaultValue" | "min" | "max" | "value">;
|
|
4
|
-
export interface DateInputProps extends BaseInputExposedProps {
|
|
5
|
-
/**
|
|
6
|
-
* A min value with type Date added
|
|
7
|
-
*/
|
|
8
|
-
min?: Date | string | number;
|
|
9
|
-
/**
|
|
10
|
-
* A max value with type Date added
|
|
11
|
-
*/
|
|
12
|
-
max?: Date | string | number;
|
|
13
|
-
/**
|
|
14
|
-
* A default value with type Date added
|
|
15
|
-
*/
|
|
16
|
-
defaultValue?: Date | string | number;
|
|
17
|
-
/**
|
|
18
|
-
* A value with type Date added
|
|
19
|
-
*/
|
|
20
|
-
value?: Date | string | number;
|
|
21
|
-
}
|
|
22
|
-
/**
|
|
23
|
-
* A wrapper around BaseInput with a pop-up day picker.
|
|
24
|
-
*
|
|
25
|
-
* NOTE: If shown with a label, please use the `DateField` component instead.
|
|
26
|
-
*/
|
|
27
|
-
export declare const DateInput: import("react").ForwardRefExoticComponent<DateInputProps & import("react").RefAttributes<HTMLInputElement>>;
|
|
28
|
-
export {};
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { BaseInputProps } from "../BaseInput";
|
|
3
|
+
type BaseInputExposedProps = Omit<BaseInputProps, "defaultValue" | "min" | "max" | "value">;
|
|
4
|
+
export interface DateInputProps extends BaseInputExposedProps {
|
|
5
|
+
/**
|
|
6
|
+
* A min value with type Date added
|
|
7
|
+
*/
|
|
8
|
+
min?: Date | string | number;
|
|
9
|
+
/**
|
|
10
|
+
* A max value with type Date added
|
|
11
|
+
*/
|
|
12
|
+
max?: Date | string | number;
|
|
13
|
+
/**
|
|
14
|
+
* A default value with type Date added
|
|
15
|
+
*/
|
|
16
|
+
defaultValue?: Date | string | number;
|
|
17
|
+
/**
|
|
18
|
+
* A value with type Date added
|
|
19
|
+
*/
|
|
20
|
+
value?: Date | string | number;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* A wrapper around BaseInput with a pop-up day picker.
|
|
24
|
+
*
|
|
25
|
+
* NOTE: If shown with a label, please use the `DateField` component instead.
|
|
26
|
+
*/
|
|
27
|
+
export declare const DateInput: import("react").ForwardRefExoticComponent<DateInputProps & import("react").RefAttributes<HTMLInputElement>>;
|
|
28
|
+
export {};
|
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { CommonProps, Size } from "@trackunit/react-components";
|
|
3
|
-
import { BaseInputProps } from "../BaseInput";
|
|
4
|
-
type BaseInputExposedProps = Omit<BaseInputProps, "type" | "suffix" | "prefix" | "addonAfter" | "addonBefore" | "actions" | "placeholder" | "fieldSize" | "size" | "nonInteractive">;
|
|
5
|
-
export interface DropZoneProps extends BaseInputExposedProps, CommonProps {
|
|
6
|
-
/**
|
|
7
|
-
* A string to set the label in Drop Zone.
|
|
8
|
-
*/
|
|
9
|
-
label: string;
|
|
10
|
-
/**
|
|
11
|
-
* A flag to disable the drop zone.
|
|
12
|
-
*/
|
|
13
|
-
disabled?: boolean;
|
|
14
|
-
/**
|
|
15
|
-
* The size of the dropZone
|
|
16
|
-
* small - padding:8px, medium - padding:16px large - padding:32px
|
|
17
|
-
*/
|
|
18
|
-
size?: Size;
|
|
19
|
-
/**
|
|
20
|
-
* The files dropped can be accessed within filesSelected
|
|
21
|
-
*
|
|
22
|
-
* @param file
|
|
23
|
-
* @returns
|
|
24
|
-
*/
|
|
25
|
-
filesSelected: (file: FileList) => void;
|
|
26
|
-
}
|
|
27
|
-
/**
|
|
28
|
-
* The Drop Zone can be used to drag and drop files
|
|
29
|
-
*
|
|
30
|
-
* @param {DropZoneProps} props - The props for the DropZone component
|
|
31
|
-
* @returns {JSX.Element} DropZone component
|
|
32
|
-
*/
|
|
33
|
-
export declare const DropZone: ({ className, dataTestId, filesSelected, label, size, isInvalid, disabled, ...rest }: DropZoneProps) => JSX.Element;
|
|
34
|
-
export {};
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { CommonProps, Size } from "@trackunit/react-components";
|
|
3
|
+
import { BaseInputProps } from "../BaseInput";
|
|
4
|
+
type BaseInputExposedProps = Omit<BaseInputProps, "type" | "suffix" | "prefix" | "addonAfter" | "addonBefore" | "actions" | "placeholder" | "fieldSize" | "size" | "nonInteractive">;
|
|
5
|
+
export interface DropZoneProps extends BaseInputExposedProps, CommonProps {
|
|
6
|
+
/**
|
|
7
|
+
* A string to set the label in Drop Zone.
|
|
8
|
+
*/
|
|
9
|
+
label: string;
|
|
10
|
+
/**
|
|
11
|
+
* A flag to disable the drop zone.
|
|
12
|
+
*/
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* The size of the dropZone
|
|
16
|
+
* small - padding:8px, medium - padding:16px large - padding:32px
|
|
17
|
+
*/
|
|
18
|
+
size?: Size;
|
|
19
|
+
/**
|
|
20
|
+
* The files dropped can be accessed within filesSelected
|
|
21
|
+
*
|
|
22
|
+
* @param file
|
|
23
|
+
* @returns
|
|
24
|
+
*/
|
|
25
|
+
filesSelected: (file: FileList) => void;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* The Drop Zone can be used to drag and drop files
|
|
29
|
+
*
|
|
30
|
+
* @param {DropZoneProps} props - The props for the DropZone component
|
|
31
|
+
* @returns {JSX.Element} DropZone component
|
|
32
|
+
*/
|
|
33
|
+
export declare const DropZone: ({ className, dataTestId, filesSelected, label, size, isInvalid, disabled, ...rest }: DropZoneProps) => JSX.Element;
|
|
34
|
+
export {};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { BaseInputProps } from "../BaseInput";
|
|
3
|
-
import { FormGroupProps } from "../FormGroup/FormGroup";
|
|
4
|
-
type FormGroupExposedProps = Pick<FormGroupProps, "label" | "tip" | "helpText" | "helpAddon">;
|
|
5
|
-
export interface EmailFieldProps extends FormGroupExposedProps, BaseInputProps {
|
|
6
|
-
/**
|
|
7
|
-
* If a value is set, the field is rendered in its invalid state.
|
|
8
|
-
*/
|
|
9
|
-
errorMessage?: string;
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* The EmailField component is used to enter email.
|
|
13
|
-
* EmailField validates that user enters a valid email address.
|
|
14
|
-
*
|
|
15
|
-
*/
|
|
16
|
-
export declare const EmailField: import("react").ForwardRefExoticComponent<EmailFieldProps & import("react").RefAttributes<HTMLInputElement>>;
|
|
17
|
-
export {};
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { BaseInputProps } from "../BaseInput";
|
|
3
|
+
import { FormGroupProps } from "../FormGroup/FormGroup";
|
|
4
|
+
type FormGroupExposedProps = Pick<FormGroupProps, "label" | "tip" | "helpText" | "helpAddon">;
|
|
5
|
+
export interface EmailFieldProps extends FormGroupExposedProps, BaseInputProps {
|
|
6
|
+
/**
|
|
7
|
+
* If a value is set, the field is rendered in its invalid state.
|
|
8
|
+
*/
|
|
9
|
+
errorMessage?: string;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* The EmailField component is used to enter email.
|
|
13
|
+
* EmailField validates that user enters a valid email address.
|
|
14
|
+
*
|
|
15
|
+
*/
|
|
16
|
+
export declare const EmailField: import("react").ForwardRefExoticComponent<EmailFieldProps & import("react").RefAttributes<HTMLInputElement>>;
|
|
17
|
+
export {};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { BaseInputProps } from "../BaseInput";
|
|
3
|
-
/**
|
|
4
|
-
* A Email Input component is used for input of the type Email.
|
|
5
|
-
*
|
|
6
|
-
* It has an ActionButton which sends an email to the specified address using "mailto:" link.
|
|
7
|
-
*
|
|
8
|
-
* Extends props of BaseInput.
|
|
9
|
-
*
|
|
10
|
-
* A reference to the input element is provided as the `ref` prop.
|
|
11
|
-
* For specific input types make sure to use the corresponding input component.
|
|
12
|
-
*/
|
|
13
|
-
export declare const EmailInput: React.ForwardRefExoticComponent<BaseInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { BaseInputProps } from "../BaseInput";
|
|
3
|
+
/**
|
|
4
|
+
* A Email Input component is used for input of the type Email.
|
|
5
|
+
*
|
|
6
|
+
* It has an ActionButton which sends an email to the specified address using "mailto:" link.
|
|
7
|
+
*
|
|
8
|
+
* Extends props of BaseInput.
|
|
9
|
+
*
|
|
10
|
+
* A reference to the input element is provided as the `ref` prop.
|
|
11
|
+
* For specific input types make sure to use the corresponding input component.
|
|
12
|
+
*/
|
|
13
|
+
export declare const EmailInput: React.ForwardRefExoticComponent<BaseInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "./EmailInput";
|
|
1
|
+
export * from "./EmailInput";
|