@cloudbase/weda-ui 3.7.6 → 3.7.7
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/configs/components/button.d.ts +2 -2
- package/dist/configs/components/chart/line.d.ts +1 -1
- package/dist/configs/components/customer-service.d.ts +1 -1
- package/dist/configs/components/form-input.d.ts +2 -2
- package/dist/configs/components/form-location.d.ts +4 -4
- package/dist/configs/components/wd-bubble.d.ts +6 -6
- package/dist/configs/components/wd-cascader.d.ts +3 -3
- package/dist/configs/components/wd-checkbox.d.ts +1 -1
- package/dist/configs/components/wd-code-editor.d.ts +1 -1
- package/dist/configs/components/wd-date-range.d.ts +1 -1
- package/dist/configs/components/wd-date.d.ts +1 -1
- package/dist/configs/components/wd-department.d.ts +1 -1
- package/dist/configs/components/wd-form-arr.d.ts +1 -1
- package/dist/configs/components/wd-form-detail.d.ts +1 -1
- package/dist/configs/components/wd-form-obj.d.ts +1 -1
- package/dist/configs/components/wd-icon.d.ts +1 -1
- package/dist/configs/components/wd-input-email.d.ts +3 -3
- package/dist/configs/components/wd-input-number.d.ts +2 -2
- package/dist/configs/components/wd-input-phone.d.ts +3 -3
- package/dist/configs/components/wd-input-url.d.ts +3 -3
- package/dist/configs/components/wd-input.d.ts +1 -1
- package/dist/configs/components/wd-location.d.ts +1 -1
- package/dist/configs/components/wd-member.d.ts +1 -1
- package/dist/configs/components/wd-progress.d.ts +2 -2
- package/dist/configs/components/wd-radio.d.ts +1 -1
- package/dist/configs/components/wd-rating.d.ts +4 -2
- package/dist/configs/components/wd-rating.js +9 -0
- package/dist/configs/components/wd-region.d.ts +1 -1
- package/dist/configs/components/wd-rich-text.d.ts +1 -1
- package/dist/configs/components/wd-select-multiple.d.ts +1 -1
- package/dist/configs/components/wd-select.d.ts +1 -1
- package/dist/configs/components/wd-switch.d.ts +2 -2
- package/dist/configs/components/wd-tag-select.d.ts +1 -1
- package/dist/configs/components/wd-textarea.d.ts +1 -1
- package/dist/configs/components/wd-time.d.ts +1 -1
- package/dist/configs/components/wd-upload-file.d.ts +3 -3
- package/dist/configs/components/wd-upload-image.d.ts +1 -1
- package/dist/configs/index.d.ts +96 -94
- package/dist/configs/type-utils/index.d.ts +1 -1
- package/dist/iconConfig.json +1 -1
- package/dist/style/index.scss +1 -1
- package/dist/web/components/flow/process/constants.d.ts +3 -3
- package/dist/web/components/form-date/index.d.ts +1 -1
- package/dist/web/components/form-depart-tree-select/index.d.ts +1 -1
- package/dist/web/components/form-email/index.d.ts +2 -2
- package/dist/web/components/form-image-uploader/index.d.ts +1 -1
- package/dist/web/components/form-input/index.d.ts +5 -5
- package/dist/web/components/form-input-hooks/index.d.ts +1 -1
- package/dist/web/components/form-location/index.d.ts +4 -4
- package/dist/web/components/form-multi-region/index.d.ts +1 -1
- package/dist/web/components/form-phone/index.d.ts +2 -2
- package/dist/web/components/form-radio/index.d.ts +2 -2
- package/dist/web/components/form-region/index.d.ts +1 -1
- package/dist/web/components/form-rich-text/index.d.ts +1 -1
- package/dist/web/components/form-select/index.d.ts +2 -2
- package/dist/web/components/form-select-multiple/index.d.ts +2 -2
- package/dist/web/components/form-switch/index.d.ts +1 -1
- package/dist/web/components/form-text-area/index.d.ts +2 -2
- package/dist/web/components/form-time/index.d.ts +1 -1
- package/dist/web/components/form-upload-file/index.d.ts +1 -1
- package/dist/web/components/form-url/index.d.ts +2 -2
- package/dist/web/components/form-user-tree-select/index.d.ts +1 -1
- package/dist/web/components/index.js +1 -0
- package/dist/web/components/wd-icon/wd-icon.js +0 -2
- package/dist/web/components/wd-input/wd-input.d.ts +3 -3
- package/dist/web/components/wd-input-email/wd-input-email.d.ts +1 -1
- package/dist/web/components/wd-input-phone/wd-input-phone.d.ts +3 -3
- package/dist/web/components/wd-input-url/wd-input-url.d.ts +1 -1
- package/dist/web/components/wd-textarea/wd-textarea.js +6 -3
- package/dist/web/utils/loadIconCss.d.ts +1 -0
- package/dist/web/{components/wd-icon/useLoadCss.js → utils/loadIconCss.js} +11 -12
- package/package.json +3 -2
- package/dist/web/components/wd-icon/useLoadCss.d.ts +0 -1
|
@@ -83,11 +83,11 @@ declare const OPERATION_NODE_STATUS: readonly [{
|
|
|
83
83
|
/** 操作节点状态相关映射关系转换 */
|
|
84
84
|
declare const
|
|
85
85
|
/** 状态码-状态名称映射 */
|
|
86
|
-
CODE_NAME_MAPPING: Record<number, "stop" | "
|
|
86
|
+
CODE_NAME_MAPPING: Record<number, "stop" | "drop" | "end" | "start" | "down" | "pending" | "revoke" | "cc" | "pass" | "turn" | "trans" | "countersign" | "skip_pass" | "skip_down" | "handled" | "handling">,
|
|
87
87
|
/** 状态名称-状态码映射 */
|
|
88
|
-
NAME_CODE_MAPPING: Record<"CC" | "REVOKE" | "STOP" | "
|
|
88
|
+
NAME_CODE_MAPPING: Record<"CC" | "REVOKE" | "STOP" | "DROP" | "END" | "START" | "DOWN" | "PENDING" | "PASS" | "TURN" | "TRANS" | "COUNTERSIGN" | "SKIP_PASS" | "SKIP_DOWN" | "HANDLED" | "HANDLING", number>,
|
|
89
89
|
/** 状态名称映射 */
|
|
90
|
-
NAME_MAPPING: Record<"CC" | "REVOKE" | "STOP" | "
|
|
90
|
+
NAME_MAPPING: Record<"CC" | "REVOKE" | "STOP" | "DROP" | "END" | "START" | "DOWN" | "PENDING" | "PASS" | "TURN" | "TRANS" | "COUNTERSIGN" | "SKIP_PASS" | "SKIP_DOWN" | "HANDLED" | "HANDLING", "stop" | "drop" | "end" | "start" | "down" | "pending" | "revoke" | "cc" | "pass" | "turn" | "trans" | "countersign" | "skip_pass" | "skip_down" | "handled" | "handling">,
|
|
91
91
|
/** 状态名称-状态文本信息映射 */
|
|
92
92
|
NAME_TEXT_MAPPING: Record<string, {
|
|
93
93
|
theme: string;
|
|
@@ -8,8 +8,8 @@ export type FormDateProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormDate: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
size: "s" | "m" | "l" | "full";
|
|
15
15
|
disabled: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormDepartTreeSelectProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormDepartTreeSelect: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
size: "s" | "m" | "l" | "full";
|
|
15
15
|
disabled: boolean;
|
|
@@ -8,15 +8,15 @@ export type PropsType = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormEmail: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
focus: boolean;
|
|
13
|
+
name: string;
|
|
13
14
|
required: boolean;
|
|
14
15
|
size: "s" | "m" | "l" | "full";
|
|
15
16
|
disabled: boolean;
|
|
16
17
|
maxLength: number;
|
|
17
18
|
placeholder: string;
|
|
18
19
|
layout: "" | "vertical" | "horizontal";
|
|
19
|
-
focus: boolean;
|
|
20
20
|
labelVisible: boolean;
|
|
21
21
|
clearable: boolean;
|
|
22
22
|
requiredFlag: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormImageUploaderProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormImageUploader: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
title: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string[];
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
disabled: boolean;
|
|
15
15
|
layout: "" | "vertical" | "horizontal";
|
|
@@ -8,26 +8,26 @@ export type PropsType = CommonPropsType & DataType & {
|
|
|
8
8
|
};
|
|
9
9
|
declare const WdInput: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
|
-
type: "number" | "text" | "idcard" | "digit";
|
|
13
11
|
value: string;
|
|
12
|
+
type: "number" | "text" | "idcard" | "digit";
|
|
13
|
+
focus: boolean;
|
|
14
|
+
name: string;
|
|
14
15
|
required: boolean;
|
|
15
16
|
size: "s" | "m" | "l" | "full";
|
|
16
17
|
disabled: boolean;
|
|
17
18
|
maxLength: number;
|
|
18
19
|
placeholder: string;
|
|
19
20
|
layout: "" | "vertical" | "horizontal";
|
|
20
|
-
focus: boolean;
|
|
21
21
|
labelVisible: boolean;
|
|
22
22
|
isNickNameType: boolean;
|
|
23
23
|
clearable: boolean;
|
|
24
24
|
password: boolean;
|
|
25
25
|
rules: {
|
|
26
26
|
pattern: string;
|
|
27
|
-
message: string;
|
|
28
27
|
format: string;
|
|
28
|
+
message: string;
|
|
29
29
|
}[];
|
|
30
|
-
validateStatus: "
|
|
30
|
+
validateStatus: "error" | "success" | "warn";
|
|
31
31
|
requiredFlag: boolean;
|
|
32
32
|
requiredMsg: string;
|
|
33
33
|
}> & {
|
|
@@ -37,7 +37,7 @@ export declare function useFormInputTrait<Value = unknown>(inputParams: FormInpu
|
|
|
37
37
|
readOnly: boolean;
|
|
38
38
|
required: boolean;
|
|
39
39
|
name: string;
|
|
40
|
-
validateState: "
|
|
40
|
+
validateState: "error" | "success" | "warn";
|
|
41
41
|
validateErrorMsg: string;
|
|
42
42
|
/**
|
|
43
43
|
* @deprecated 在Wd组件中应该直接用输入的那个,通过css联动而不是js
|
|
@@ -8,7 +8,6 @@ export type FormLocationProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormLocation: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: {
|
|
13
12
|
address: string;
|
|
14
13
|
geopoint: {
|
|
@@ -16,16 +15,17 @@ declare const FormLocation: React.ForwardRefExoticComponent<CommonPropsType & im
|
|
|
16
15
|
coordinates: [number, number];
|
|
17
16
|
};
|
|
18
17
|
};
|
|
18
|
+
drag: boolean;
|
|
19
|
+
name: string;
|
|
19
20
|
required: boolean;
|
|
20
21
|
disabled: boolean;
|
|
21
22
|
layout: "" | "vertical" | "horizontal";
|
|
22
23
|
zoom: boolean;
|
|
23
|
-
|
|
24
|
-
locationType: 2 | 1;
|
|
24
|
+
locationType: 1 | 2;
|
|
25
25
|
labelVisible: boolean;
|
|
26
26
|
showLngLat: boolean;
|
|
27
27
|
showMap: boolean;
|
|
28
|
-
validateStatus: "
|
|
28
|
+
validateStatus: "error" | "success" | "warn";
|
|
29
29
|
locationRange: 0 | -1 | 100 | 1000 | 500 | 300 | 2000;
|
|
30
30
|
customRange: number;
|
|
31
31
|
requiredFlag: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormMultiRegionProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormMultiRegion: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
size: "s" | "m" | "l" | "full";
|
|
15
15
|
disabled: boolean;
|
|
@@ -8,14 +8,14 @@ export type PropsType = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormPhone: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
focus: boolean;
|
|
13
|
+
name: string;
|
|
13
14
|
required: boolean;
|
|
14
15
|
size: "s" | "m" | "l" | "full";
|
|
15
16
|
disabled: boolean;
|
|
16
17
|
placeholder: string;
|
|
17
18
|
layout: "" | "vertical" | "horizontal";
|
|
18
|
-
focus: boolean;
|
|
19
19
|
labelVisible: boolean;
|
|
20
20
|
clearable: boolean;
|
|
21
21
|
requiredFlag: boolean;
|
|
@@ -12,9 +12,9 @@ declare const FormRadio: React.ForwardRefExoticComponent<CommonPropsType & {
|
|
|
12
12
|
readOnly: boolean;
|
|
13
13
|
} & import("type-fest").Simplify<{
|
|
14
14
|
label: string;
|
|
15
|
-
name: string;
|
|
16
|
-
format: string;
|
|
17
15
|
value: string;
|
|
16
|
+
format: string;
|
|
17
|
+
name: string;
|
|
18
18
|
required: boolean;
|
|
19
19
|
disabled: boolean;
|
|
20
20
|
layout: "" | "vertical" | "horizontal";
|
|
@@ -8,8 +8,8 @@ export type FormRegionProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormRegion: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string[];
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
size: "s" | "m" | "l" | "full";
|
|
15
15
|
disabled: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormRichTextProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FromRichText: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
title: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
disabled: boolean;
|
|
15
15
|
layout: "" | "vertical" | "horizontal";
|
|
@@ -8,9 +8,9 @@ export type FormSelectProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormSelect: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
|
-
format: "x-enum" | "related" | "father-son" | "many-one";
|
|
13
11
|
value: string;
|
|
12
|
+
format: "x-enum" | "related" | "father-son" | "many-one";
|
|
13
|
+
name: string;
|
|
14
14
|
required: boolean;
|
|
15
15
|
size: "s" | "m" | "l" | "full";
|
|
16
16
|
disabled: boolean;
|
|
@@ -8,9 +8,9 @@ export type FormSelectMultipleProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormSelectMultiple: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
|
-
format: "many-many" | "one-many";
|
|
13
11
|
value: string[];
|
|
12
|
+
format: "many-many" | "one-many";
|
|
13
|
+
name: string;
|
|
14
14
|
required: boolean;
|
|
15
15
|
size: "s" | "m" | "l" | "full";
|
|
16
16
|
disabled: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormSwitchProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormSwitch: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: boolean;
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
disabled: boolean;
|
|
15
15
|
layout: "" | "vertical" | "horizontal";
|
|
@@ -8,15 +8,15 @@ export type FormTextAreaProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormTextArea: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
focus: boolean;
|
|
13
|
+
name: string;
|
|
13
14
|
required: boolean;
|
|
14
15
|
size: "s" | "m" | "l" | "full";
|
|
15
16
|
disabled: boolean;
|
|
16
17
|
maxLength: number;
|
|
17
18
|
placeholder: string;
|
|
18
19
|
layout: "" | "vertical" | "horizontal";
|
|
19
|
-
focus: boolean;
|
|
20
20
|
labelVisible: boolean;
|
|
21
21
|
counterVisible: boolean;
|
|
22
22
|
requiredFlag: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormTimeProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormTime: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
size: "s" | "m" | "l" | "full";
|
|
15
15
|
disabled: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormUploadFileProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormUploadFile: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string[];
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
disabled: boolean;
|
|
15
15
|
layout: "" | "vertical" | "horizontal";
|
|
@@ -8,15 +8,15 @@ export type PropsType = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormUrl: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
focus: boolean;
|
|
13
|
+
name: string;
|
|
13
14
|
required: boolean;
|
|
14
15
|
size: "s" | "m" | "l" | "full";
|
|
15
16
|
disabled: boolean;
|
|
16
17
|
maxLength: number;
|
|
17
18
|
placeholder: string;
|
|
18
19
|
layout: "" | "vertical" | "horizontal";
|
|
19
|
-
focus: boolean;
|
|
20
20
|
labelVisible: boolean;
|
|
21
21
|
clearable: boolean;
|
|
22
22
|
requiredFlag: boolean;
|
|
@@ -8,8 +8,8 @@ export type FormUserTreeSelectProps = CommonPropsType & DataType & {
|
|
|
8
8
|
} & EventsType;
|
|
9
9
|
declare const FormUserTreeSelect: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
10
10
|
label: string;
|
|
11
|
-
name: string;
|
|
12
11
|
value: string;
|
|
12
|
+
name: string;
|
|
13
13
|
required: boolean;
|
|
14
14
|
size: "s" | "m" | "l" | "full";
|
|
15
15
|
disabled: boolean;
|
|
@@ -11,6 +11,7 @@ import './style';
|
|
|
11
11
|
// }
|
|
12
12
|
import loadable from '@loadable/component';
|
|
13
13
|
import { fallback } from '../utils/loading-fallback';
|
|
14
|
+
import '../utils/loadIconCss';
|
|
14
15
|
export { default as Button } from './button';
|
|
15
16
|
// export { default as Text } from './text';
|
|
16
17
|
export const Text = loadable(() => import('./text'), { fallback });
|
|
@@ -7,10 +7,8 @@ import { usePlatform } from '../../utils/platform';
|
|
|
7
7
|
import { convertLegacyEnum } from '../../utils/tool';
|
|
8
8
|
import { WD_ICON_TYPE, WD_ICON_SIZE } from '../../../enum';
|
|
9
9
|
import WdImage from '../wd-image';
|
|
10
|
-
import { useLoadCss } from './useLoadCss';
|
|
11
10
|
import '../style';
|
|
12
11
|
export const WdIcon = forwardRef(function WdIcon({ type: _type = 'inner', name = 'success', src, size: _size = 'md', sizeSelfAdaptive: _sizeSelfAdaptive = false, events = emptyObject, className, style: _style, id, color: _color, ...props }, ref) {
|
|
13
|
-
useLoadCss(); // 加载远程样式
|
|
14
12
|
const platform = usePlatform();
|
|
15
13
|
// 兼容旧版组件的属性值 size/color
|
|
16
14
|
const remdiff = 2;
|
|
@@ -7,8 +7,9 @@ import type { DataType, EventsType } from '../../../configs/components/wd-input'
|
|
|
7
7
|
export declare const WdInput: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
8
8
|
label?: string;
|
|
9
9
|
template?: string;
|
|
10
|
-
name?: string;
|
|
11
10
|
type?: string;
|
|
11
|
+
focus?: boolean;
|
|
12
|
+
name?: string;
|
|
12
13
|
required?: boolean;
|
|
13
14
|
extra?: string;
|
|
14
15
|
size?: string;
|
|
@@ -17,7 +18,6 @@ export declare const WdInput: React.ForwardRefExoticComponent<CommonPropsType &
|
|
|
17
18
|
status?: string;
|
|
18
19
|
layout?: string;
|
|
19
20
|
after?: string;
|
|
20
|
-
focus?: boolean;
|
|
21
21
|
before?: string;
|
|
22
22
|
prefixType?: string;
|
|
23
23
|
prefixIcon?: string;
|
|
@@ -41,8 +41,8 @@ export declare const WdInput: React.ForwardRefExoticComponent<CommonPropsType &
|
|
|
41
41
|
borderedPc?: boolean;
|
|
42
42
|
rules?: {
|
|
43
43
|
pattern?: string;
|
|
44
|
-
message: string;
|
|
45
44
|
format: string;
|
|
45
|
+
message: string;
|
|
46
46
|
}[];
|
|
47
47
|
requiredFlag?: boolean;
|
|
48
48
|
requiredMsg?: string;
|
|
@@ -7,6 +7,7 @@ import type { DataType, EventsType } from '../../../configs/components/wd-input-
|
|
|
7
7
|
export declare const WdInputEmail: React.ForwardRefExoticComponent<CommonPropsType & import("type-fest").Simplify<{
|
|
8
8
|
label?: string;
|
|
9
9
|
template?: string;
|
|
10
|
+
focus?: boolean;
|
|
10
11
|
name?: string;
|
|
11
12
|
required?: boolean;
|
|
12
13
|
extra?: string;
|
|
@@ -16,7 +17,6 @@ export declare const WdInputEmail: React.ForwardRefExoticComponent<CommonPropsTy
|
|
|
16
17
|
status?: string;
|
|
17
18
|
layout?: string;
|
|
18
19
|
after?: string;
|
|
19
|
-
focus?: boolean;
|
|
20
20
|
before?: string;
|
|
21
21
|
prefixType?: string;
|
|
22
22
|
prefixIcon?: string;
|
|
@@ -38,8 +38,9 @@ export declare const WdInputPhone: React.ForwardRefExoticComponent<CommonPropsTy
|
|
|
38
38
|
}]>> & import("type-fest").Simplify<{
|
|
39
39
|
label?: string;
|
|
40
40
|
template?: string;
|
|
41
|
-
name?: string;
|
|
42
41
|
type?: string;
|
|
42
|
+
focus?: boolean;
|
|
43
|
+
name?: string;
|
|
43
44
|
required?: boolean;
|
|
44
45
|
extra?: string;
|
|
45
46
|
size?: string;
|
|
@@ -48,7 +49,6 @@ export declare const WdInputPhone: React.ForwardRefExoticComponent<CommonPropsTy
|
|
|
48
49
|
status?: string;
|
|
49
50
|
layout?: string;
|
|
50
51
|
after?: string;
|
|
51
|
-
focus?: boolean;
|
|
52
52
|
before?: string;
|
|
53
53
|
prefixType?: string;
|
|
54
54
|
prefixIcon?: string;
|
|
@@ -72,8 +72,8 @@ export declare const WdInputPhone: React.ForwardRefExoticComponent<CommonPropsTy
|
|
|
72
72
|
borderedPc?: boolean;
|
|
73
73
|
rules?: {
|
|
74
74
|
pattern?: string;
|
|
75
|
-
message: string;
|
|
76
75
|
format: string;
|
|
76
|
+
message: string;
|
|
77
77
|
}[];
|
|
78
78
|
requiredFlag?: boolean;
|
|
79
79
|
requiredMsg?: string;
|
|
@@ -38,6 +38,7 @@ export declare const WdInputUrl: React.ForwardRefExoticComponent<CommonPropsType
|
|
|
38
38
|
}]>> & import("type-fest").Simplify<{
|
|
39
39
|
label?: string;
|
|
40
40
|
template?: string;
|
|
41
|
+
focus?: boolean;
|
|
41
42
|
name?: string;
|
|
42
43
|
required?: boolean;
|
|
43
44
|
extra?: string;
|
|
@@ -47,7 +48,6 @@ export declare const WdInputUrl: React.ForwardRefExoticComponent<CommonPropsType
|
|
|
47
48
|
status?: string;
|
|
48
49
|
layout?: string;
|
|
49
50
|
after?: string;
|
|
50
|
-
focus?: boolean;
|
|
51
51
|
before?: string;
|
|
52
52
|
prefixType?: string;
|
|
53
53
|
prefixIcon?: string;
|
|
@@ -37,7 +37,7 @@ export const WdTextarea = forwardRef(function WdTextarea(props, ref) {
|
|
|
37
37
|
});
|
|
38
38
|
const countCls = `${textareaWrap}__label ${root}-${classRoot}__count-text`;
|
|
39
39
|
const displayValue = (_a = (zhRef.current ? zhValue : value)) !== null && _a !== void 0 ? _a : '';
|
|
40
|
-
//
|
|
40
|
+
// 输入自动滚动,关闭自动增高,value 变化不应该去改变样式
|
|
41
41
|
const autoScroll = function (isManual) {
|
|
42
42
|
if (!textareaRef.current)
|
|
43
43
|
return;
|
|
@@ -52,7 +52,11 @@ export const WdTextarea = forwardRef(function WdTextarea(props, ref) {
|
|
|
52
52
|
useEffect(() => {
|
|
53
53
|
autoScroll();
|
|
54
54
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
55
|
-
}, [autoHeight
|
|
55
|
+
}, [autoHeight]);
|
|
56
|
+
useEffect(() => {
|
|
57
|
+
autoScroll(true);
|
|
58
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
59
|
+
}, [value]);
|
|
56
60
|
/** 内部事件 */
|
|
57
61
|
const onChange = function (e) {
|
|
58
62
|
var _a;
|
|
@@ -63,7 +67,6 @@ export const WdTextarea = forwardRef(function WdTextarea(props, ref) {
|
|
|
63
67
|
else {
|
|
64
68
|
onChangeForm(text);
|
|
65
69
|
(_a = events.change) === null || _a === void 0 ? void 0 : _a.call(events, { value: text }, { originEvent: e });
|
|
66
|
-
autoScroll(true);
|
|
67
70
|
}
|
|
68
71
|
};
|
|
69
72
|
const onFocus = function (e) {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { getUrlPath } from '../../utils/tool';
|
|
1
|
+
import cfg from '../../iconConfig.json';
|
|
2
|
+
import { getUrlPath } from './tool';
|
|
4
3
|
// 加载样式,失败抛出错误
|
|
5
4
|
function loadLink(url, className) {
|
|
6
5
|
return new Promise((resolve, reject) => {
|
|
@@ -21,12 +20,12 @@ function loadLink(url, className) {
|
|
|
21
20
|
}
|
|
22
21
|
});
|
|
23
22
|
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
loadLink(getUrlPath(cfg.path, cfg.cssFile), 'wd-load-remote-icon')
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
}
|
|
23
|
+
// 组件库加载后默认挂载图标库
|
|
24
|
+
(function () {
|
|
25
|
+
try {
|
|
26
|
+
loadLink(getUrlPath(cfg.path, cfg.cssFile), 'wd-load-remote-icon');
|
|
27
|
+
}
|
|
28
|
+
catch (e) {
|
|
29
|
+
console.error('加载图标库失败', e);
|
|
30
|
+
}
|
|
31
|
+
})();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudbase/weda-ui",
|
|
3
|
-
"version": "3.7.
|
|
3
|
+
"version": "3.7.7",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"module": "./dist/index",
|
|
6
6
|
"miniprogram": "mpdist",
|
|
@@ -24,7 +24,8 @@
|
|
|
24
24
|
"src/web/components/form/select/moment-locale.{ts,js}",
|
|
25
25
|
"src/web/components/form-input-hooks/validator.ts",
|
|
26
26
|
"dist/web/**/style.{js,ts}",
|
|
27
|
-
"dist/style/**/*"
|
|
27
|
+
"dist/style/**/*",
|
|
28
|
+
"src/web/utils/loadIconCss.js"
|
|
28
29
|
],
|
|
29
30
|
"publishConfig": {
|
|
30
31
|
"access": "public"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function useLoadCss(): boolean;
|