@wise/dynamic-flow-client 3.25.1 → 3.26.0
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/build/i18n/de.json +2 -0
- package/build/i18n/en.json +2 -0
- package/build/i18n/es.json +2 -0
- package/build/i18n/fr.json +2 -0
- package/build/i18n/hu.json +2 -0
- package/build/i18n/id.json +2 -0
- package/build/i18n/it.json +2 -0
- package/build/i18n/ja.json +2 -0
- package/build/i18n/pl.json +2 -0
- package/build/i18n/pt.json +2 -0
- package/build/i18n/ro.json +2 -0
- package/build/i18n/ru.json +2 -0
- package/build/i18n/th.json +2 -0
- package/build/i18n/tr.json +2 -0
- package/build/i18n/zh_CN.json +2 -0
- package/build/i18n/zh_HK.json +2 -0
- package/build/main.js +281 -168
- package/build/main.min.js +1 -1
- package/build/main.mjs +220 -107
- package/build/types/common/messages/file-upload.messages.d.ts +13 -0
- package/build/types/legacy/common/utils/schema-utils.d.ts +1 -1
- package/build/types/revamp/domain/features/validation/value-checks.d.ts +3 -0
- package/build/types/revamp/domain/mappers/schema/stringSchemaToComponent/stringSchemaToComponent.d.ts +1 -1
- package/build/types/revamp/domain/mappers/schema/stringSchemaToComponent/stringSchemaToUploadInputComponent.d.ts +5 -3
- package/build/types/revamp/domain/mappers/types.d.ts +2 -0
- package/build/types/revamp/utils/type-utils.d.ts +2 -2
- package/package.json +32 -32
|
@@ -23,4 +23,4 @@ export declare function isFileUploadSchema(schema: {
|
|
|
23
23
|
}): schema is FileUploadSchema;
|
|
24
24
|
export declare const isMultipleFileUploadSchema: (schema: Schema) => schema is MultipleFileUploadSchema;
|
|
25
25
|
export declare const isMultiSelectConstSchema: (schema: Schema) => schema is MultiSelectSchema;
|
|
26
|
-
export declare const getSchemaType: (schema: Schema) => "object" | "readOnly" | "
|
|
26
|
+
export declare const getSchemaType: (schema: Schema) => "object" | "readOnly" | "persistAsync" | "array" | "allOf" | "oneOf" | "validationAsync" | "promotedOneOf" | "basic" | null;
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import type { ArraySchemaList, IntegerSchema, NumberSchema, Schema, StringSchema } from '@wise/dynamic-flow-types/build/next';
|
|
2
2
|
import type { ErrorMessageFunctions } from '../../mappers/types';
|
|
3
3
|
import type { LocalValue, LocalValueArray } from '../../types';
|
|
4
|
+
import { PersistAsyncWithUploadSchema, StringSchemaWithUpload } from '../../../utils/type-utils';
|
|
4
5
|
export type IsInvalidCheck<V extends LocalValue> = (value: V | null) => string | null;
|
|
5
6
|
type GetIsInvalidCheck<S extends Schema, V extends LocalValue> = (schema: S, messageFunctions: ErrorMessageFunctions) => IsInvalidCheck<V>;
|
|
6
7
|
export declare const getAboveMaxItemsCheck: GetIsInvalidCheck<ArraySchemaList, LocalValueArray | null>;
|
|
7
8
|
export declare const getBelowMinFilesCheck: GetIsInvalidCheck<ArraySchemaList, LocalValueArray | null>;
|
|
8
9
|
export declare const getAboveMaxFilesCheck: GetIsInvalidCheck<ArraySchemaList, LocalValueArray | null>;
|
|
10
|
+
export declare const getFileSizeCheck: GetIsInvalidCheck<PersistAsyncWithUploadSchema | StringSchemaWithUpload, File | null>;
|
|
11
|
+
export declare const getFileTypeCheck: GetIsInvalidCheck<PersistAsyncWithUploadSchema | StringSchemaWithUpload, File | null>;
|
|
9
12
|
export declare const getBelowMinItemsCheck: GetIsInvalidCheck<ArraySchemaList, LocalValueArray | null>;
|
|
10
13
|
export declare const getAboveMaxLengthCheck: GetIsInvalidCheck<StringSchema, string | null>;
|
|
11
14
|
export declare const getBelowMinLengthCheck: GetIsInvalidCheck<StringSchema, string | null>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { StringSchema } from '@wise/dynamic-flow-types/build/next';
|
|
2
2
|
import type { MapperProps, SchemaMapperProps } from '../types';
|
|
3
|
-
export declare const stringSchemaToComponent: (schemaMapperProps: SchemaMapperProps & {
|
|
3
|
+
export declare const stringSchemaToComponent: (schemaMapperProps: Omit<SchemaMapperProps, "schema"> & {
|
|
4
4
|
schema: StringSchema;
|
|
5
5
|
}, mapperProps: MapperProps) => import("../../../components/DateInputComponent").DateInputComponent | import("../../../components/TextInputComponent").TextInputComponent | import("../../../components/UploadInputComponent").UploadInputComponent;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { StringSchema } from '@wise/dynamic-flow-types/build/next';
|
|
2
2
|
import type { MapperProps, SchemaMapperProps } from '../types';
|
|
3
|
-
export declare const stringSchemaToUploadInputComponent: (schemaMapperProps: SchemaMapperProps & {
|
|
4
|
-
schema: StringSchema
|
|
3
|
+
export declare const stringSchemaToUploadInputComponent: (schemaMapperProps: Omit<SchemaMapperProps, "schema"> & {
|
|
4
|
+
schema: StringSchema & {
|
|
5
|
+
format: "base64url";
|
|
6
|
+
};
|
|
5
7
|
}, mapperProps: MapperProps) => import("../../../components/UploadInputComponent").UploadInputComponent;
|
|
@@ -12,6 +12,8 @@ export type ErrorMessageFunctions = {
|
|
|
12
12
|
minFiles: (minFiles: number) => string;
|
|
13
13
|
maxItems: (maxItems: number) => string;
|
|
14
14
|
minItems: (minItems: number) => string;
|
|
15
|
+
maxSize: () => string;
|
|
16
|
+
accepts: () => string;
|
|
15
17
|
pattern: () => string;
|
|
16
18
|
required: () => string;
|
|
17
19
|
genericError: () => string;
|
|
@@ -6,9 +6,9 @@ import type { DomainComponent, LocalValue, LocalValueArray, LocalValueObject } f
|
|
|
6
6
|
type SchemaWithPersistAsync = (ArraySchemaList | ArraySchemaTuple | BooleanSchema | IntegerSchema | NumberSchema | StringSchema) & {
|
|
7
7
|
persistAsync: PersistAsync;
|
|
8
8
|
};
|
|
9
|
-
export type StringSchemaWithUpload = StringSchema & {
|
|
9
|
+
export type StringSchemaWithUpload = Omit<StringSchema & {
|
|
10
10
|
format: 'base64url';
|
|
11
|
-
}
|
|
11
|
+
}, 'persistAsync'>;
|
|
12
12
|
export type PersistAsyncWithUploadSchema = Schema & {
|
|
13
13
|
persistAsync: PersistAsync & {
|
|
14
14
|
schema: BlobSchema | StringSchemaWithUpload;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wise/dynamic-flow-client",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.26.0",
|
|
4
4
|
"description": "Dynamic Flow web client",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"main": "./build/main.min.js",
|
|
@@ -27,36 +27,36 @@
|
|
|
27
27
|
"url": "git+https://github.com/transferwise/dynamic-flow.git"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@babel/core": "7.
|
|
31
|
-
"@babel/plugin-syntax-flow": "7.
|
|
32
|
-
"@babel/plugin-transform-react-jsx": "7.25.
|
|
33
|
-
"@babel/preset-env": "7.
|
|
34
|
-
"@babel/preset-react": "7.25.
|
|
35
|
-
"@babel/preset-typescript": "7.
|
|
36
|
-
"@chromatic-com/storybook": "2.
|
|
37
|
-
"@formatjs/cli": "^6.3.
|
|
38
|
-
"@storybook/addon-a11y": "^8.
|
|
39
|
-
"@storybook/addon-actions": "^8.
|
|
40
|
-
"@storybook/addon-essentials": "^8.
|
|
41
|
-
"@storybook/addon-interactions": "^8.
|
|
42
|
-
"@storybook/addon-links": "^8.
|
|
30
|
+
"@babel/core": "7.26.0",
|
|
31
|
+
"@babel/plugin-syntax-flow": "7.26.0",
|
|
32
|
+
"@babel/plugin-transform-react-jsx": "7.25.9",
|
|
33
|
+
"@babel/preset-env": "7.26.0",
|
|
34
|
+
"@babel/preset-react": "7.25.9",
|
|
35
|
+
"@babel/preset-typescript": "7.26.0",
|
|
36
|
+
"@chromatic-com/storybook": "3.2.2",
|
|
37
|
+
"@formatjs/cli": "^6.3.8",
|
|
38
|
+
"@storybook/addon-a11y": "^8.4.2",
|
|
39
|
+
"@storybook/addon-actions": "^8.4.2",
|
|
40
|
+
"@storybook/addon-essentials": "^8.4.2",
|
|
41
|
+
"@storybook/addon-interactions": "^8.4.2",
|
|
42
|
+
"@storybook/addon-links": "^8.4.2",
|
|
43
43
|
"@storybook/addon-webpack5-compiler-babel": "^3.0.3",
|
|
44
|
-
"@storybook/manager-api": "^8.
|
|
45
|
-
"@storybook/react": "^8.
|
|
46
|
-
"@storybook/react-webpack5": "^8.
|
|
47
|
-
"@storybook/test": "^8.
|
|
48
|
-
"@storybook/types": "^8.
|
|
44
|
+
"@storybook/manager-api": "^8.4.2",
|
|
45
|
+
"@storybook/react": "^8.4.2",
|
|
46
|
+
"@storybook/react-webpack5": "^8.4.2",
|
|
47
|
+
"@storybook/test": "^8.4.2",
|
|
48
|
+
"@storybook/types": "^8.4.2",
|
|
49
49
|
"@testing-library/dom": "10.4.0",
|
|
50
|
-
"@testing-library/jest-dom": "6.6.
|
|
50
|
+
"@testing-library/jest-dom": "6.6.3",
|
|
51
51
|
"@testing-library/react": "16.0.1",
|
|
52
52
|
"@testing-library/user-event": "14.5.2",
|
|
53
53
|
"@transferwise/components": "46.72.2",
|
|
54
54
|
"@transferwise/formatting": "^2.13.0",
|
|
55
55
|
"@transferwise/icons": "3.14.0",
|
|
56
56
|
"@transferwise/neptune-css": "14.19.1",
|
|
57
|
-
"@types/node": "22.
|
|
58
|
-
"@types/jest": "29.5.
|
|
59
|
-
"@types/react": "18.3.
|
|
57
|
+
"@types/node": "22.9.0",
|
|
58
|
+
"@types/jest": "29.5.14",
|
|
59
|
+
"@types/react": "18.3.12",
|
|
60
60
|
"@types/react-dom": "18.3.1",
|
|
61
61
|
"@types/react-intl": "3.0.0",
|
|
62
62
|
"@wise/art": "2.16.3",
|
|
@@ -67,22 +67,22 @@
|
|
|
67
67
|
"jest-environment-jsdom": "29.7.0",
|
|
68
68
|
"jest-fetch-mock": "^3.0.3",
|
|
69
69
|
"jest-watch-typeahead": "^2.2.2",
|
|
70
|
-
"nanoid": "5.0.
|
|
71
|
-
"npm-run-all2": "6.2.
|
|
72
|
-
"postcss": "^8.4.
|
|
70
|
+
"nanoid": "5.0.8",
|
|
71
|
+
"npm-run-all2": "6.2.6",
|
|
72
|
+
"postcss": "^8.4.48",
|
|
73
73
|
"postcss-cli": "^11.0.0",
|
|
74
74
|
"postcss-import": "^15.1.0",
|
|
75
75
|
"react": "18.3.1",
|
|
76
76
|
"react-dom": "18.3.1",
|
|
77
|
-
"react-intl": "6.8.
|
|
78
|
-
"storybook": "^8.
|
|
77
|
+
"react-intl": "6.8.7",
|
|
78
|
+
"storybook": "^8.4.2",
|
|
79
79
|
"stylelint": "16.10.0",
|
|
80
80
|
"stylelint-config-standard": "36.0.1",
|
|
81
|
-
"stylelint-no-unsupported-browser-features": "8.0.
|
|
81
|
+
"stylelint-no-unsupported-browser-features": "8.0.2",
|
|
82
82
|
"stylelint-value-no-unknown-custom-properties": "6.0.1",
|
|
83
|
-
"tsx": "4.19.
|
|
83
|
+
"tsx": "4.19.2",
|
|
84
84
|
"typescript": "5.6.3",
|
|
85
|
-
"webpack": "5.
|
|
85
|
+
"webpack": "5.96.1",
|
|
86
86
|
"@wise/dynamic-flow-fixtures": "0.0.1",
|
|
87
87
|
"@wise/dynamic-flow-renderers": "0.0.0"
|
|
88
88
|
},
|
|
@@ -98,7 +98,7 @@
|
|
|
98
98
|
},
|
|
99
99
|
"dependencies": {
|
|
100
100
|
"classnames": "2.5.1",
|
|
101
|
-
"nanoid": "5.0.
|
|
101
|
+
"nanoid": "5.0.8",
|
|
102
102
|
"react-webcam": "^7.2.0",
|
|
103
103
|
"screenfull": "^5.2.0",
|
|
104
104
|
"@wise/dynamic-flow-types": "2.27.0"
|