@trackunit/react-form-components 1.3.195 → 1.3.196
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/package.json +8 -8
- package/src/components/BaseInput/InputLockReasonTooltip.d.ts +1 -1
- package/src/components/PhoneInput/PhoneNumberUtilities.d.ts +1 -1
- package/src/components/Schedule/Schedule.d.ts +3 -3
- package/src/components/Schedule/ScheduleParser.d.ts +1 -1
- package/src/components/Select/TagsContainer.d.ts +1 -1
- package/src/components/SelectField/FormFieldSelectAdapter.d.ts +1 -1
- package/src/utilities/ColorFieldValidationUtils.d.ts +1 -1
- package/src/utilities/EmailFieldValidationUtils.d.ts +1 -1
- package/src/utilities/UrlFieldValidationUtils.d.ts +1 -1
- package/src/utilities/typeUtils.d.ts +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trackunit/react-form-components",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.196",
|
|
4
4
|
"repository": "https://github.com/Trackunit/manager",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"engines": {
|
|
@@ -17,14 +17,14 @@
|
|
|
17
17
|
"zod": "3.23.4",
|
|
18
18
|
"react-hook-form": "7.53.1",
|
|
19
19
|
"tailwind-merge": "^2.0.0",
|
|
20
|
-
"@trackunit/css-class-variance-utilities": "1.3.
|
|
21
|
-
"@trackunit/react-components": "1.4.
|
|
22
|
-
"@trackunit/ui-icons": "1.3.
|
|
23
|
-
"@trackunit/shared-utils": "1.5.
|
|
24
|
-
"@trackunit/ui-design-tokens": "1.3.
|
|
25
|
-
"@trackunit/i18n-library-translation": "1.3.
|
|
20
|
+
"@trackunit/css-class-variance-utilities": "1.3.141",
|
|
21
|
+
"@trackunit/react-components": "1.4.172",
|
|
22
|
+
"@trackunit/ui-icons": "1.3.141",
|
|
23
|
+
"@trackunit/shared-utils": "1.5.141",
|
|
24
|
+
"@trackunit/ui-design-tokens": "1.3.139",
|
|
25
|
+
"@trackunit/i18n-library-translation": "1.3.160",
|
|
26
26
|
"string-ts": "^2.0.0",
|
|
27
|
-
"@trackunit/react-test-setup": "1.0.
|
|
27
|
+
"@trackunit/react-test-setup": "1.0.31"
|
|
28
28
|
},
|
|
29
29
|
"module": "./index.esm.js",
|
|
30
30
|
"main": "./index.cjs.js",
|
|
@@ -11,7 +11,7 @@ export declare const checkIfPhoneNumberHasPlus: (phoneNumber: string) => boolean
|
|
|
11
11
|
* @returns {string|number} the phone number with a plus sign in front of it
|
|
12
12
|
* @example getPhoneNumberWithPlus("123456789") // "+123456789"
|
|
13
13
|
*/
|
|
14
|
-
export declare const getPhoneNumberWithPlus: (phoneNumber: string | number |
|
|
14
|
+
export declare const getPhoneNumberWithPlus: (phoneNumber: string | number | ReadonlyArray<string>) => string;
|
|
15
15
|
/**
|
|
16
16
|
* Generates a flag emoji based on the given country code.
|
|
17
17
|
*
|
|
@@ -30,18 +30,18 @@ export interface ScheduleProps extends CommonProps {
|
|
|
30
30
|
/**
|
|
31
31
|
* List of schedule rows.
|
|
32
32
|
*/
|
|
33
|
-
schedule: ScheduleItem
|
|
33
|
+
schedule: Array<ScheduleItem>;
|
|
34
34
|
/**
|
|
35
35
|
* List of invalid keys.
|
|
36
36
|
*/
|
|
37
|
-
invalidKeys?: string
|
|
37
|
+
invalidKeys?: Array<string>;
|
|
38
38
|
/**
|
|
39
39
|
* Called when time range or checkbox changes state.
|
|
40
40
|
*
|
|
41
41
|
* @param {ScheduleItem[]} schedules Updated schedule entries
|
|
42
42
|
* @returns {void}
|
|
43
43
|
*/
|
|
44
|
-
onChange: (schedules: ScheduleItem
|
|
44
|
+
onChange: (schedules: Array<ScheduleItem>) => void;
|
|
45
45
|
}
|
|
46
46
|
/**
|
|
47
47
|
* Schedule is used to create a time range entries.
|
|
@@ -25,7 +25,7 @@ export interface DaySchedule extends RawSchedule {
|
|
|
25
25
|
}
|
|
26
26
|
export interface WeekSchedule {
|
|
27
27
|
variant: ScheduleVariant;
|
|
28
|
-
schedule: DaySchedule
|
|
28
|
+
schedule: Array<DaySchedule>;
|
|
29
29
|
}
|
|
30
30
|
/**
|
|
31
31
|
* Parse a string of week range schedule string to human readable schedule range.
|
|
@@ -17,7 +17,7 @@ interface TagsContainerProps {
|
|
|
17
17
|
/**
|
|
18
18
|
* An items to be rendered inside container if they fit available space. If they overlap then the counter will be displayed.
|
|
19
19
|
*/
|
|
20
|
-
items: TagsContainerItem
|
|
20
|
+
items: Array<TagsContainerItem>;
|
|
21
21
|
/**
|
|
22
22
|
* An css property to set a custom width for container
|
|
23
23
|
* Default behavior is to take 100% width of parent element
|
|
@@ -2,4 +2,4 @@ export type UrlValidationErrorCode = "REQUIRED" | "INVALID_HEX_CODE" | undefined
|
|
|
2
2
|
/**
|
|
3
3
|
* Validates a url
|
|
4
4
|
*/
|
|
5
|
-
export declare const validateColorCode: (colorCode?: string | number |
|
|
5
|
+
export declare const validateColorCode: (colorCode?: string | number | ReadonlyArray<string>, required?: boolean | undefined) => UrlValidationErrorCode;
|
|
@@ -2,4 +2,4 @@ export type EmailValidationErrorCode = "REQUIRED" | "INVALID_EMAIL" | undefined;
|
|
|
2
2
|
/**
|
|
3
3
|
* Validates a email id
|
|
4
4
|
*/
|
|
5
|
-
export declare const validateEmailId: (emailId?: string | number |
|
|
5
|
+
export declare const validateEmailId: (emailId?: string | number | ReadonlyArray<string>, required?: boolean | undefined) => EmailValidationErrorCode;
|
|
@@ -2,4 +2,4 @@ export type UrlValidationErrorCode = "REQUIRED" | "INVALID_URL" | undefined;
|
|
|
2
2
|
/**
|
|
3
3
|
* Validates a url
|
|
4
4
|
*/
|
|
5
|
-
export declare const validateUrl: (url?: string | number |
|
|
5
|
+
export declare const validateUrl: (url?: string | number | ReadonlyArray<string>, required?: boolean | undefined) => UrlValidationErrorCode;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* @param inputValue - value to check if it is a string
|
|
4
4
|
* @returns {boolean} - true if value is a string
|
|
5
5
|
*/
|
|
6
|
-
export declare const isString: (inputValue: string | number |
|
|
6
|
+
export declare const isString: (inputValue: string | number | ReadonlyArray<string> | undefined) => inputValue is string;
|
|
7
7
|
/**
|
|
8
8
|
*
|
|
9
9
|
* @param inputValue - value to check if it is a number
|