@ccs-ui/rc-pro 2.5.1-beta.2 → 2.5.1-beta.4
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/docs-dist/404.html +1 -1
- package/docs-dist/guide/index.html +1 -1
- package/docs-dist/index.html +1 -1
- package/docs-dist/{meta__packages.e03a7670.async.js → meta__packages.24368d30.async.js} +32 -19
- package/docs-dist/plugins/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/enumerations/DataEvent.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomCheckboxApiProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomCheckboxProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomEllipsisProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomFullScreenProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomLoadingProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomMultiStateProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/interfaces/ResizeSize.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomCountdownInstance.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomCountdownProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFilterInstance.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFilterProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFormItem.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFormItems.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomOperationProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomPageRequestProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomResizeProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomTitleProps.md/index.html +1 -1
- package/docs-dist/rc-pro/atom/_api/type-aliases/TableEventHandle.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/interfaces/ButtonGroupProps.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/interfaces/DropdownProps.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/interfaces/GroupButtonItem.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/type-aliases/ButtonProps.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/type-aliases/DropdownClick.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/type-aliases/DropdownMenuItemType.md/index.html +1 -1
- package/docs-dist/rc-pro/button/_api/type-aliases/GroupClick.md/index.html +1 -1
- package/docs-dist/rc-pro/cascader/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/cascader/_api/type-aliases/ApiCascaderProps.md/index.html +1 -1
- package/docs-dist/rc-pro/context/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/context/_api/type-aliases/AppConfigType.md/index.html +1 -1
- package/docs-dist/rc-pro/context/_api/type-aliases/AppFieldNames.md/index.html +1 -1
- package/docs-dist/rc-pro/context/_api/type-aliases/FnContextType.md/index.html +1 -1
- package/docs-dist/rc-pro/context/_api/type-aliases/PageContextType.md/index.html +1 -1
- package/docs-dist/rc-pro/context/_api/type-aliases/PageFieldNames.md/index.html +1 -1
- package/docs-dist/rc-pro/date-picker/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/date-picker/_api/type-aliases/DatePickerProps.md/index.html +1 -1
- package/docs-dist/rc-pro/date-picker/_api/type-aliases/RangePickerProps.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogContextType.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogDrawer.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogInterface.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogModal.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogProps.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/type-aliases/DialogButtonsProps.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/type-aliases/DialogDrawerProps.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/type-aliases/DialogModalProps.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/type-aliases/OkBtnProps.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/type-aliases/OkEvent.md/index.html +1 -1
- package/docs-dist/rc-pro/dialog/_api/type-aliases/Service.md/index.html +1 -1
- package/docs-dist/rc-pro/editor/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/editor/_api/type-aliases/EditorCodeProps.md/index.html +1 -1
- package/docs-dist/rc-pro/editor/_api/type-aliases/EditorRichProps.md/index.html +1 -1
- package/docs-dist/rc-pro/editor/_api/type-aliases/LexicalEditorBaseProps.md/index.html +1 -1
- package/docs-dist/rc-pro/editor/_api/type-aliases/RichImageUpload.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/FormItem.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/FormItemChildren.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/FormItemProps.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/FormListProps.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/ListItemBtnProps.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/RenderItem.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/RenderItemButton.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/RenderItemProps.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/RuleType.md/index.html +1 -1
- package/docs-dist/rc-pro/form/_api/type-aliases/ShowValidateEvent.md/index.html +1 -1
- package/docs-dist/rc-pro/index.html +1 -1
- package/docs-dist/rc-pro/index.md/index.html +1 -1
- package/docs-dist/rc-pro/page-layout/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/page-layout/_api/interfaces/KeepAliveTabsProps.md/index.html +1 -1
- package/docs-dist/rc-pro/page-layout/_api/interfaces/SinglePageProps.md/index.html +1 -1
- package/docs-dist/rc-pro/page-layout/_api/type-aliases/MenuType.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/interfaces/ProTableProps.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/interfaces/TableInstance.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/interfaces/TableProps.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/LeafVerify.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableColumn.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableColumns.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableData.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableFormItems.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableInstanceRef.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TreeInstance.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-tabs/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-tabs/_api/interfaces/TabsChangeProps.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-tabs/_api/interfaces/TabsContextType.md/index.html +1 -1
- package/docs-dist/rc-pro/pro-tabs/_api/type-aliases/TabProps.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/interfaces/ApiRequestProps.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/interfaces/RequestType.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/type-aliases/ApiSelectProps.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/type-aliases/CacheType.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/type-aliases/CustomizeSelectProps.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/type-aliases/ModalSelectProps.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/type-aliases/SelectChildrenProps.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/type-aliases/SelectFieldNames.md/index.html +1 -1
- package/docs-dist/rc-pro/select/_api/type-aliases/SelectProps.md/index.html +1 -1
- package/docs-dist/rc-pro/upload/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/upload/_api/interfaces/ImageInfo.md/index.html +1 -1
- package/docs-dist/rc-pro/upload/_api/type-aliases/FileUploadList.md/index.html +1 -1
- package/docs-dist/rc-pro/upload/_api/type-aliases/UploadImageProps.md/index.html +1 -1
- package/docs-dist/rc-pro/upload/_api/type-aliases/UploadProps.md/index.html +1 -1
- package/docs-dist/rc-pro/upload/_api/type-aliases/UploadRequest.md/index.html +1 -1
- package/docs-dist/rc-pro/water-mark/_api/index.md/index.html +1 -1
- package/docs-dist/rc-pro/water-mark/_api/type-aliases/WaterMarkProps.md/index.html +1 -1
- package/docs-dist/rc-pros/atom/index.html +1 -1
- package/docs-dist/rc-pros/auth/index.html +1 -1
- package/docs-dist/rc-pros/button/index.html +1 -1
- package/docs-dist/rc-pros/cascader/index.html +1 -1
- package/docs-dist/rc-pros/date-picker/index.html +1 -1
- package/docs-dist/rc-pros/dialog/index.html +1 -1
- package/docs-dist/rc-pros/editor/index.html +1 -1
- package/docs-dist/rc-pros/form/index.html +1 -1
- package/docs-dist/rc-pros/index.html +1 -1
- package/docs-dist/rc-pros/page-layout/index.html +1 -1
- package/docs-dist/rc-pros/pro-table/index.html +1 -1
- package/docs-dist/rc-pros/pro-tabs/index.html +1 -1
- package/docs-dist/rc-pros/result/index.html +1 -1
- package/docs-dist/rc-pros/select/index.html +1 -1
- package/docs-dist/rc-pros/time-picker/index.html +1 -1
- package/docs-dist/rc-pros/upload/index.html +1 -1
- package/docs-dist/rc-pros/water-mark/index.html +1 -1
- package/docs-dist/{umi.92e3e869.js → umi.140d02ff.js} +1 -1
- package/docs-dist/utils/index.html +1 -1
- package/docs-dist/~demos/:id/index.html +1 -1
- package/docs-dist/~demos/atom-demo-base/index.html +1 -1
- package/docs-dist/~demos/atom-demo-checkbox/index.html +1 -1
- package/docs-dist/~demos/atom-demo-ellipsis/index.html +1 -1
- package/docs-dist/~demos/atom-demo-filter/index.html +1 -1
- package/docs-dist/~demos/atom-demo-state/index.html +1 -1
- package/docs-dist/~demos/auth-demo-basic/index.html +1 -1
- package/docs-dist/~demos/button-demo-button/index.html +1 -1
- package/docs-dist/~demos/button-demo-group/index.html +1 -1
- package/docs-dist/~demos/cascader-demo-basic/index.html +1 -1
- package/docs-dist/~demos/cascader-demo-cache/index.html +1 -1
- package/docs-dist/~demos/date-picker-demo-basic/index.html +1 -1
- package/docs-dist/~demos/date-picker-demo-range/index.html +1 -1
- package/docs-dist/~demos/dialog-demo-demos/index.html +1 -1
- package/docs-dist/~demos/dialog-demo-form/index.html +1 -1
- package/docs-dist/~demos/dialog-demo-prompt/index.html +1 -1
- package/docs-dist/~demos/editor-demo-demos/index.html +1 -1
- package/docs-dist/~demos/editor-demo-rich/index.html +1 -1
- package/docs-dist/~demos/form-demo-demos/index.html +1 -1
- package/docs-dist/~demos/packages-utils-src-demo-demos/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-basic/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-cascade/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-extra/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-filter/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-fixed/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-refresh/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-selection/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-show-depend/index.html +1 -1
- package/docs-dist/~demos/pro-table-demo-tree-async/index.html +1 -1
- package/docs-dist/~demos/pro-tabs-demo-basic/index.html +1 -1
- package/docs-dist/~demos/pro-tabs-demo-tab/index.html +1 -1
- package/docs-dist/~demos/result-demo-basic/index.html +1 -1
- package/docs-dist/~demos/select-demo-api/index.html +1 -1
- package/docs-dist/~demos/select-demo-basic/index.html +1 -1
- package/docs-dist/~demos/select-demo-customize/index.html +1 -1
- package/docs-dist/~demos/select-demo-customize-label/index.html +1 -1
- package/docs-dist/~demos/time-picker-demo-basic/index.html +1 -1
- package/docs-dist/~demos/upload-demo-basic/index.html +1 -1
- package/docs-dist/~demos/upload-demo-image/index.html +1 -1
- package/docs-dist/~demos/water-mark-demo-basic/index.html +1 -1
- package/es/dialog/button.d.ts +1 -1
- package/es/upload/_api.d.ts +2 -0
- package/es/upload/index.d.ts +2 -2
- package/es/upload/index.js +9 -6
- package/es/upload/upload-image.d.ts +1 -1
- package/es/upload/upload-image.js +4 -3
- package/package.json +1 -1
package/es/dialog/button.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ import { DialogFormRef } from './form';
|
|
|
5
5
|
export type DialogButtonRef = {
|
|
6
6
|
onSetButtons: (e: React.ReactElement) => void;
|
|
7
7
|
};
|
|
8
|
-
export declare const DialogButtonHolder: <TParams, TData>({ auth, extraBtn, formRef, request, onOk, onClose, buttonRef, requestFieldNames, formInitialValues, preventRequestHandle, }: Pick<DialogModalProps<TParams, TData>, "
|
|
8
|
+
export declare const DialogButtonHolder: <TParams, TData>({ auth, extraBtn, formRef, request, onOk, onClose, buttonRef, requestFieldNames, formInitialValues, preventRequestHandle, }: Pick<DialogModalProps<TParams, TData>, "onClose" | "onOk" | "request" | "auth" | "extraBtn" | "requestFieldNames" | "preventRequestHandle"> & {
|
|
9
9
|
formRef: React.RefObject<DialogFormRef<TParams>>;
|
|
10
10
|
formInitialValues: FormProps['initialValues'];
|
|
11
11
|
buttonRef: RefObject<DialogButtonRef>;
|
package/es/upload/_api.d.ts
CHANGED
|
@@ -26,6 +26,8 @@ export type UploadProps = Pick<AntUploadProps, 'maxCount' | 'data' | 'multiple'
|
|
|
26
26
|
onChange?: (value: any) => void;
|
|
27
27
|
/** 上传请求 */
|
|
28
28
|
uploadRequest: UploadRequest;
|
|
29
|
+
/** 获取文件真实url */
|
|
30
|
+
onRealUrl?: (fileId: string) => string;
|
|
29
31
|
};
|
|
30
32
|
export type FileUploadList = UploadChangeParam['fileList'][0] & {
|
|
31
33
|
fileId?: string;
|
package/es/upload/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { FileUploadList, UploadProps } from './_api';
|
|
2
2
|
import { ImageUpload } from './upload-image';
|
|
3
3
|
/** 生成图片默认值 */
|
|
4
|
-
export declare function uploadDefaultFlies(value: UploadProps['value']): FileUploadList[];
|
|
5
|
-
declare function CustomUpload({ value, disabled, uploadText, maxCount, maxFileSize, uploadRequest, onChange, ...otherProps }: UploadProps): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export declare function uploadDefaultFlies(value: UploadProps['value'], onRealUrl?: UploadProps['onRealUrl']): FileUploadList[];
|
|
5
|
+
declare function CustomUpload({ value, disabled, uploadText, onRealUrl, maxCount, maxFileSize, uploadRequest, onChange, ...otherProps }: UploadProps): import("react/jsx-runtime").JSX.Element;
|
|
6
6
|
declare namespace CustomUpload {
|
|
7
7
|
var Image: typeof ImageUpload;
|
|
8
8
|
var displayName: string;
|
package/es/upload/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _excluded = ["value", "disabled", "uploadText", "maxCount", "maxFileSize", "uploadRequest", "onChange"];
|
|
1
|
+
var _excluded = ["value", "disabled", "uploadText", "onRealUrl", "maxCount", "maxFileSize", "uploadRequest", "onChange"];
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
@@ -26,14 +26,15 @@ import { ImageUpload } from "./upload-image";
|
|
|
26
26
|
|
|
27
27
|
/** 生成图片默认值 */
|
|
28
28
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
29
|
-
export function uploadDefaultFlies(value) {
|
|
29
|
+
export function uploadDefaultFlies(value, onRealUrl) {
|
|
30
30
|
if (Array.isArray(value)) {
|
|
31
31
|
return value.map(function (v) {
|
|
32
32
|
if (typeof v === 'string') {
|
|
33
33
|
return {
|
|
34
34
|
uid: v,
|
|
35
35
|
name: v,
|
|
36
|
-
fileId: v
|
|
36
|
+
fileId: v,
|
|
37
|
+
url: onRealUrl === null || onRealUrl === void 0 ? void 0 : onRealUrl(v)
|
|
37
38
|
};
|
|
38
39
|
}
|
|
39
40
|
|
|
@@ -42,7 +43,7 @@ export function uploadDefaultFlies(value) {
|
|
|
42
43
|
return {
|
|
43
44
|
uid: v.fileId,
|
|
44
45
|
name: v.name,
|
|
45
|
-
url: v.url,
|
|
46
|
+
url: v.url || (onRealUrl === null || onRealUrl === void 0 ? void 0 : onRealUrl(v.fileId)),
|
|
46
47
|
fileId: v.fileId
|
|
47
48
|
};
|
|
48
49
|
}
|
|
@@ -55,7 +56,8 @@ export function uploadDefaultFlies(value) {
|
|
|
55
56
|
return [{
|
|
56
57
|
uid: value,
|
|
57
58
|
name: value,
|
|
58
|
-
fileId: value
|
|
59
|
+
fileId: value,
|
|
60
|
+
url: onRealUrl === null || onRealUrl === void 0 ? void 0 : onRealUrl(value)
|
|
59
61
|
}];
|
|
60
62
|
}
|
|
61
63
|
return [];
|
|
@@ -64,6 +66,7 @@ function CustomUpload(_ref) {
|
|
|
64
66
|
var value = _ref.value,
|
|
65
67
|
disabled = _ref.disabled,
|
|
66
68
|
uploadText = _ref.uploadText,
|
|
69
|
+
onRealUrl = _ref.onRealUrl,
|
|
67
70
|
_ref$maxCount = _ref.maxCount,
|
|
68
71
|
maxCount = _ref$maxCount === void 0 ? 1 : _ref$maxCount,
|
|
69
72
|
_ref$maxFileSize = _ref.maxFileSize,
|
|
@@ -72,7 +75,7 @@ function CustomUpload(_ref) {
|
|
|
72
75
|
onChange = _ref.onChange,
|
|
73
76
|
otherProps = _objectWithoutProperties(_ref, _excluded);
|
|
74
77
|
var _useState = useState(function () {
|
|
75
|
-
return uploadDefaultFlies(value);
|
|
78
|
+
return uploadDefaultFlies(value, onRealUrl);
|
|
76
79
|
}),
|
|
77
80
|
_useState2 = _slicedToArray(_useState, 2),
|
|
78
81
|
files = _useState2[0],
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { UploadImageProps } from './_api';
|
|
2
|
-
export declare function ImageUpload({ uploadText, maxCount, maxFileSize, crop, value, disabled, uploadRequest, onChange, onImageInfo, accept, ...otherProps }: UploadImageProps): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export declare function ImageUpload({ uploadText, maxCount, maxFileSize, crop, value, disabled, onRealUrl, uploadRequest, onChange, onImageInfo, accept, ...otherProps }: UploadImageProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
-
var _excluded = ["uploadText", "maxCount", "maxFileSize", "crop", "value", "disabled", "uploadRequest", "onChange", "onImageInfo", "accept"];
|
|
2
|
+
var _excluded = ["uploadText", "maxCount", "maxFileSize", "crop", "value", "disabled", "onRealUrl", "uploadRequest", "onChange", "onImageInfo", "accept"];
|
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
5
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
@@ -49,6 +49,7 @@ export function ImageUpload(_ref) {
|
|
|
49
49
|
crop = _ref.crop,
|
|
50
50
|
value = _ref.value,
|
|
51
51
|
disabled = _ref.disabled,
|
|
52
|
+
onRealUrl = _ref.onRealUrl,
|
|
52
53
|
uploadRequest = _ref.uploadRequest,
|
|
53
54
|
onChange = _ref.onChange,
|
|
54
55
|
onImageInfo = _ref.onImageInfo,
|
|
@@ -56,7 +57,7 @@ export function ImageUpload(_ref) {
|
|
|
56
57
|
accept = _ref$accept === void 0 ? 'image/*' : _ref$accept,
|
|
57
58
|
otherProps = _objectWithoutProperties(_ref, _excluded);
|
|
58
59
|
var _useState = useState(function () {
|
|
59
|
-
return uploadDefaultFlies(value);
|
|
60
|
+
return uploadDefaultFlies(value, onRealUrl);
|
|
60
61
|
}),
|
|
61
62
|
_useState2 = _slicedToArray(_useState, 2),
|
|
62
63
|
files = _useState2[0],
|
|
@@ -210,7 +211,7 @@ export function ImageUpload(_ref) {
|
|
|
210
211
|
};
|
|
211
212
|
}();
|
|
212
213
|
var renderUpload = /*#__PURE__*/_jsx(Upload, _objectSpread(_objectSpread({
|
|
213
|
-
disabled:
|
|
214
|
+
disabled: disabled,
|
|
214
215
|
name: "fileName",
|
|
215
216
|
onChange: handleOnChange,
|
|
216
217
|
onPreview: handlePreview,
|