@zero-library/common 2.2.4 → 2.2.5

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/index.d.mts CHANGED
@@ -1,4 +1,5 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { EmptyProps } from 'antd';
2
3
  import * as react from 'react';
3
4
  import { ReactNode } from 'react';
4
5
  import dayjs from 'dayjs';
@@ -64,6 +65,7 @@ declare const _default$n: ({ suffix, fontSize }: FileIconProps) => react_jsx_run
64
65
  * 文件预览组件属性接口
65
66
  */
66
67
  interface FilePreviewProps {
68
+ emptyProps?: EmptyProps;
67
69
  /** 文件URL地址 */
68
70
  fileUrl: string;
69
71
  /** 文件后缀名 */
@@ -93,7 +95,7 @@ interface FilePreviewProps {
93
95
  * 支持图片、PDF、视频、音频、Markdown等文件格式的预览
94
96
  * @param props - 组件属性
95
97
  */
96
- declare const _default$m: ({ suffix, fileUrl, pdfParams, password, searchValue }: FilePreviewProps) => react_jsx_runtime.JSX.Element;
98
+ declare const _default$m: ({ suffix, fileUrl, pdfParams, password, searchValue, emptyProps }: FilePreviewProps) => react_jsx_runtime.JSX.Element;
97
99
 
98
100
  /**
99
101
  * 文件预览抽屉组件属性接口
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { EmptyProps } from 'antd';
2
3
  import * as react from 'react';
3
4
  import { ReactNode } from 'react';
4
5
  import dayjs from 'dayjs';
@@ -64,6 +65,7 @@ declare const _default$n: ({ suffix, fontSize }: FileIconProps) => react_jsx_run
64
65
  * 文件预览组件属性接口
65
66
  */
66
67
  interface FilePreviewProps {
68
+ emptyProps?: EmptyProps;
67
69
  /** 文件URL地址 */
68
70
  fileUrl: string;
69
71
  /** 文件后缀名 */
@@ -93,7 +95,7 @@ interface FilePreviewProps {
93
95
  * 支持图片、PDF、视频、音频、Markdown等文件格式的预览
94
96
  * @param props - 组件属性
95
97
  */
96
- declare const _default$m: ({ suffix, fileUrl, pdfParams, password, searchValue }: FilePreviewProps) => react_jsx_runtime.JSX.Element;
98
+ declare const _default$m: ({ suffix, fileUrl, pdfParams, password, searchValue, emptyProps }: FilePreviewProps) => react_jsx_runtime.JSX.Element;
97
99
 
98
100
  /**
99
101
  * 文件预览抽屉组件属性接口
package/dist/index.esm.js CHANGED
@@ -2011,10 +2011,10 @@ var PdfPreview_default = ({ password, fileUrl, pageNo = 1, scale = 1, isHasThumb
2011
2011
  ] }) })
2012
2012
  ] }) }) });
2013
2013
  };
2014
- var FilePreview_default = ({ suffix, fileUrl, pdfParams, password, searchValue }) => {
2014
+ var FilePreview_default = ({ suffix, fileUrl, pdfParams, password, searchValue, emptyProps }) => {
2015
2015
  const Preview = useMemo(() => {
2016
2016
  if (!fileUrl) {
2017
- return /* @__PURE__ */ jsx(Empty, {});
2017
+ return /* @__PURE__ */ jsx(Empty, { ...emptyProps });
2018
2018
  }
2019
2019
  switch (suffix?.toUpperCase()) {
2020
2020
  case "PNG":