@jiaozhiye/qm-design-react 1.10.0 → 1.10.2
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/lib/form/src/form.d.ts +5 -5
- package/lib/form/src/types.d.ts +5 -1
- package/lib/form/src/utils.d.ts +2 -2
- package/lib/index.esm.js +1 -1
- package/lib/index.full.js +1 -1
- package/lib/index.js +1 -1
- package/lib/style/index.css +29 -0
- package/lib/style/index.min.css +1 -1
- package/lib/table/src/table/props.d.ts +1 -1
- package/lib/table/src/table/types.d.ts +1 -1
- package/lib/table/style/table.less +373 -360
- package/lib/upload-file/src/upload-file.d.ts +20 -2
- package/lib/upload-file/style/index.less +11 -0
- package/lib/upload-img/src/upload-img.d.ts +8 -9
- package/lib/upload-img/style/index.less +3 -0
- package/package.json +2 -2
package/lib/form/src/form.d.ts
CHANGED
|
@@ -105,11 +105,11 @@ declare class QmForm extends Component<IProps, IState> {
|
|
|
105
105
|
initialHandle(): void;
|
|
106
106
|
checkFieldNames(): void;
|
|
107
107
|
getFormItemRequired(rules?: Record<string, any>[]): boolean;
|
|
108
|
-
createOtherValue(values: IFormData): IFormData
|
|
108
|
+
createOtherValue(values: IFormData): IFormData<string | number, string | number | (string | number)[] | undefined>;
|
|
109
109
|
createExtraValue(values: IExtraData): IExtraData;
|
|
110
110
|
createDividerExpand(): IExpandData;
|
|
111
|
-
getInitialValue(item: IFormItem, val?: ValueOf<IFormData>): string | number |
|
|
112
|
-
createFormValue(values: IFormData): IFormData
|
|
111
|
+
getInitialValue(item: IFormItem, val?: ValueOf<IFormData>): string | number | (string | number)[] | Record<string, string | number> | undefined;
|
|
112
|
+
createFormValue(values: IFormData): IFormData<string | number, string | number | (string | number)[] | undefined>;
|
|
113
113
|
createInitialValues(): void;
|
|
114
114
|
createInitialOthers(): void;
|
|
115
115
|
createInitialExtras(): void;
|
|
@@ -127,7 +127,7 @@ declare class QmForm extends Component<IProps, IState> {
|
|
|
127
127
|
type: any;
|
|
128
128
|
fieldName: any;
|
|
129
129
|
}): boolean;
|
|
130
|
-
formatFormValue(values: IFormData): IFormData
|
|
130
|
+
formatFormValue(values: IFormData): IFormData<string | number, string | number | (string | number)[] | undefined>;
|
|
131
131
|
setFieldAuth(key: string, value: IFieldAuthItem): void;
|
|
132
132
|
createFormAuth(): Promise<void>;
|
|
133
133
|
INPUT(option: IFormItem): JSXElement;
|
|
@@ -181,7 +181,7 @@ declare class QmForm extends Component<IProps, IState> {
|
|
|
181
181
|
errorFields: any;
|
|
182
182
|
}) => void;
|
|
183
183
|
set_fields_other(values: IFormData): void;
|
|
184
|
-
get_fields_other(fields?: string[]): IFormData
|
|
184
|
+
get_fields_other(fields?: string[]): IFormData<string | number, string | number | (string | number)[] | undefined>;
|
|
185
185
|
openValidateInfo: (errorFields: any) => void;
|
|
186
186
|
scrollToField: (fieldName?: string) => void;
|
|
187
187
|
formValidate(): Promise<IFormData>;
|
package/lib/form/src/types.d.ts
CHANGED
|
@@ -57,7 +57,7 @@ export declare enum ETimeFormat {
|
|
|
57
57
|
'hour-minute' = "HH:mm",
|
|
58
58
|
'hour-minute-second' = "HH:mm:ss"
|
|
59
59
|
}
|
|
60
|
-
export type IFormData =
|
|
60
|
+
export type IFormData<U = string | number, T = U | U[] | undefined> = Record<string, T | Record<string, U>>;
|
|
61
61
|
export type IFetchHeader = Record<string, string>;
|
|
62
62
|
export type IFetchParams = Record<string, any>;
|
|
63
63
|
export type IFieldData = {
|
|
@@ -183,11 +183,15 @@ export type IFormItem = {
|
|
|
183
183
|
maxCount?: number;
|
|
184
184
|
fileTypes?: string[];
|
|
185
185
|
fileSize?: number;
|
|
186
|
+
draggable?: boolean;
|
|
187
|
+
editable?: boolean;
|
|
186
188
|
fileDirection?: IFormLayout;
|
|
187
189
|
showTip?: boolean;
|
|
188
190
|
openCropper?: boolean;
|
|
189
191
|
onPreview?: (file: UploadFile, cb: (file?: UploadFile) => void) => void;
|
|
190
192
|
onRemove?: (file: UploadFile) => void;
|
|
193
|
+
onSortChange?: (fileList: UploadFile[]) => void;
|
|
194
|
+
onEditChange?: (file: UploadFile, fileList: UploadFile[]) => void;
|
|
191
195
|
fixedSize?: [number, number] | undefined;
|
|
192
196
|
quality?: number;
|
|
193
197
|
tinymce?: Record<string, any>;
|
package/lib/form/src/utils.d.ts
CHANGED
|
@@ -49,13 +49,13 @@ export declare const createShConfig: (data: any, fieldName: string, createFetch:
|
|
|
49
49
|
hideHeader?: boolean | undefined;
|
|
50
50
|
columns?: import("../..").QmTableColumn[] | undefined;
|
|
51
51
|
width?: string | number | undefined;
|
|
52
|
-
initialValue?: import("./types").IFormData | undefined;
|
|
52
|
+
initialValue?: import("./types").IFormData<string | number, string | number | (string | number)[] | undefined> | undefined;
|
|
53
53
|
onlySelect?: boolean | undefined;
|
|
54
54
|
autoQueryAssign?: boolean | undefined;
|
|
55
55
|
closeRemoteMatch?: boolean | undefined;
|
|
56
56
|
fieldAliasMap?: Record<string, string> | (() => Record<string, string>) | undefined;
|
|
57
57
|
extraAliasMap?: Record<string, string> | (() => Record<string, string>) | undefined;
|
|
58
58
|
filterAliasMap?: string[] | Record<string, (input: string) => string> | (() => string[] | Record<string, (input: string) => string>) | undefined;
|
|
59
|
-
beforeOpen?: ((formData: import("./types").IFormData) => boolean | void | Promise<void>) | undefined;
|
|
59
|
+
beforeOpen?: ((formData: import("./types").IFormData<string | number, string | number | (string | number)[] | undefined>) => boolean | void | Promise<void>) | undefined;
|
|
60
60
|
closed?: ((rowData: Record<string, any>) => void) | undefined;
|
|
61
61
|
};
|