@jt-home/mfe-components 1.0.61 → 1.0.62-beta.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/dist/JtAttachmentPreview/index.cjs +2 -1
- package/dist/JtAttachmentPreview/index.mjs +6 -4
- package/dist/{index-D67nILVt.js → index-BdgCXrMw.js} +453 -667
- package/dist/index-DtqPcdZG.cjs +1 -0
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +1718 -1717
- package/dist/style.css +1 -1
- package/dist/types/components/JtAttachmentPreview/index.d.ts +3 -3
- package/dist/types/components/JtAttachmentPreview/types.d.ts +6 -4
- package/dist/types/components/form/types.d.ts +1 -4
- package/dist/types/components/globalInfo/model/slotIdentity.d.ts +1 -1
- package/dist/types/components/globalInfo/model/types.d.ts +1 -1
- package/dist/types/main.d.ts +1 -0
- package/package.json +6 -5
- package/readme.md +694 -694
- package/dist/JtAttachmentPreview/style.css +0 -1
- package/dist/index-DEbU13vV.cjs +0 -1
- package/dist/pdf-BmBuG7of.js +0 -18058
- package/dist/pdf-Da0bm_Ya.cjs +0 -55
- package/dist/pdf.worker.min-4PI-nNLo.js +0 -4
- package/dist/pdf.worker.min-BAJUPwg6.cjs +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import './
|
|
2
|
-
|
|
3
|
-
export type { JtAttachmentPreviewMode, JtAttachmentPreviewOptions, JtAttachmentPreviewDownloadContext, JtAttachmentPreviewDownloadHandler, JtAttachmentPreviewDownloadResult, JtAttachmentPreviewFileOptions, JtAttachmentPreviewHandler, JtAttachmentPreviewRequestConfig, JtAttachmentPreviewResolvedType, JtAttachmentPreviewService, } from './types';
|
|
1
|
+
import type { JtAttachmentPreviewHandler, JtAttachmentPreviewOptions, JtAttachmentPreviewRequestConfig, JtAttachmentPreviewResolveFileHandler } from './types';
|
|
2
|
+
export type { JtAttachmentPreviewMode, JtAttachmentPreviewOptions, JtAttachmentPreviewDownloadContext, JtAttachmentPreviewDownloadHandler, JtAttachmentPreviewDownloadResult, JtAttachmentPreviewFileOptions, JtAttachmentPreviewHandler, JtAttachmentPreviewRequestConfig, JtAttachmentPreviewResolveFileHandler, JtAttachmentPreviewResolvedType, JtAttachmentPreviewService, } from './types';
|
|
4
3
|
declare function openAttachmentPreview(options: string | JtAttachmentPreviewOptions): JtAttachmentPreviewHandler;
|
|
4
|
+
export declare function setupJtAttachmentPreview<Params = unknown>(resolveFile: JtAttachmentPreviewResolveFileHandler<Params>): void;
|
|
5
5
|
export declare function setupJtAttachmentPreview<Params = unknown, Response = unknown, DownloadResponse = unknown>(config: JtAttachmentPreviewRequestConfig<Params, Response, DownloadResponse>): void;
|
|
6
6
|
export declare function JtAttachmentPreviewByParams<Params = unknown>(params: Params): JtAttachmentPreviewHandler;
|
|
7
7
|
export declare const JtAttachmentPreview: typeof openAttachmentPreview & {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export type JtAttachmentPreviewMode = 'auto' | 'image' | 'pdf'
|
|
1
|
+
export type JtAttachmentPreviewMode = 'auto' | 'image' | 'pdf';
|
|
2
2
|
export interface JtAttachmentPreviewDownloadContext<Params = unknown> {
|
|
3
3
|
url: string;
|
|
4
4
|
name: string;
|
|
@@ -40,8 +40,6 @@ export interface JtAttachmentPreviewOptions {
|
|
|
40
40
|
download?: JtAttachmentPreviewDownloadHandler;
|
|
41
41
|
/** 弹窗层级。 */
|
|
42
42
|
zIndex?: number;
|
|
43
|
-
/** iframe sandbox 属性,不传则不限制 iframe。 */
|
|
44
|
-
sandbox?: string;
|
|
45
43
|
/** 按 Esc 时是否关闭弹窗。 */
|
|
46
44
|
closeOnPressEscape?: boolean;
|
|
47
45
|
/** 加载成功回调。 */
|
|
@@ -52,6 +50,7 @@ export interface JtAttachmentPreviewOptions {
|
|
|
52
50
|
onClose?: () => void;
|
|
53
51
|
}
|
|
54
52
|
export type JtAttachmentPreviewFileOptions = JtAttachmentPreviewOptions;
|
|
53
|
+
export type JtAttachmentPreviewResolveFileHandler<Params = unknown> = (params: Params) => JtAttachmentPreviewFileOptions | Promise<JtAttachmentPreviewFileOptions>;
|
|
55
54
|
export interface JtAttachmentPreviewRequestConfig<Params = unknown, Response = unknown, DownloadResponse = unknown> {
|
|
56
55
|
/** 根据业务参数请求文件信息。可以直接调用 axios、fetch 或项目内 request。 */
|
|
57
56
|
request: (params: Params) => Promise<Response>;
|
|
@@ -69,5 +68,8 @@ export interface JtAttachmentPreviewHandler {
|
|
|
69
68
|
export interface JtAttachmentPreviewService {
|
|
70
69
|
(options: string | JtAttachmentPreviewOptions): JtAttachmentPreviewHandler;
|
|
71
70
|
openByParams: <Params = unknown>(params: Params) => JtAttachmentPreviewHandler;
|
|
72
|
-
setup:
|
|
71
|
+
setup: {
|
|
72
|
+
<Params = unknown>(resolveFile: JtAttachmentPreviewResolveFileHandler<Params>): void;
|
|
73
|
+
<Params = unknown, Response = unknown, DownloadResponse = unknown>(config: JtAttachmentPreviewRequestConfig<Params, Response, DownloadResponse>): void;
|
|
74
|
+
};
|
|
73
75
|
}
|
|
@@ -21,7 +21,7 @@ interface JTFormItemBaseConfig {
|
|
|
21
21
|
prop: string;
|
|
22
22
|
/** 标签文本 */
|
|
23
23
|
label: string;
|
|
24
|
-
/**
|
|
24
|
+
/** 占几列,1-4 */
|
|
25
25
|
span?: number;
|
|
26
26
|
/** 是否显示当前表单项,false 时不渲染 */
|
|
27
27
|
show?: boolean;
|
|
@@ -66,9 +66,6 @@ export interface JTFormItemsProps {
|
|
|
66
66
|
configs: JTFormItemConfig[];
|
|
67
67
|
/** 表单数据对象 */
|
|
68
68
|
formData: JTFormItemsForm;
|
|
69
|
-
/** 表单 grid 总列数,默认 4,支持 1-24 */
|
|
70
|
-
gridColumns?: number;
|
|
71
|
-
/** 统一设置表单项占用列数,上限跟随 gridColumns */
|
|
72
69
|
span?: number;
|
|
73
70
|
}
|
|
74
71
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { GlobalInfoNode, GlobalInfoSection } from './types';
|
|
2
2
|
type SlotRegistry = Record<string, unknown>;
|
|
3
3
|
export declare function getNodeSlotIdentity(node: Pick<GlobalInfoNode, 'code'>): string;
|
|
4
|
-
export declare function getSectionSlotIdentity(node: Pick<GlobalInfoNode, 'code'
|
|
4
|
+
export declare function getSectionSlotIdentity(node: Partial<Pick<GlobalInfoNode, 'code' | 'infSetId' | 'setId'>>, section?: Pick<GlobalInfoSection, 'code'> | null): string;
|
|
5
5
|
export declare function findGlobalInfoSlotName(slotMap: SlotRegistry, prefix: string, identity: string): string;
|
|
6
6
|
export {};
|
|
@@ -418,7 +418,7 @@ export interface GlobalInfoField {
|
|
|
418
418
|
placeholder?: string;
|
|
419
419
|
/** 静态或动态加载后的选项。 */
|
|
420
420
|
options?: GlobalInfoFieldOption[];
|
|
421
|
-
/** 信息集枚举来源类型:
|
|
421
|
+
/** 信息集枚举来源类型:NULL 兼容旧接口,REST 调接口,ENUMS 使用详情响应内联枚举,NOTRANS 不处理。 */
|
|
422
422
|
valueListType?: string;
|
|
423
423
|
/** 字段动态接口描述,常用于级联下拉。 */
|
|
424
424
|
interface?: GlobalInfoApiOperation;
|
package/dist/types/main.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jt-home/mfe-components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.62-beta.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.cjs",
|
|
@@ -21,8 +21,7 @@
|
|
|
21
21
|
"import": "./dist/JtAttachmentPreview/index.mjs",
|
|
22
22
|
"require": "./dist/JtAttachmentPreview/index.cjs"
|
|
23
23
|
},
|
|
24
|
-
"./style.css": "./dist/style.css"
|
|
25
|
-
"./JtAttachmentPreview/style.css": "./dist/JtAttachmentPreview/style.css"
|
|
24
|
+
"./style.css": "./dist/style.css"
|
|
26
25
|
},
|
|
27
26
|
"files": [
|
|
28
27
|
"dist"
|
|
@@ -53,10 +52,10 @@
|
|
|
53
52
|
"test:cascader-props": "tsc --skipLibCheck --module NodeNext --moduleResolution NodeNext --target ES2020 --outDir tmp/unit-tests src/components/form/item/JtCascader/cascaderProps.ts src/components/form/item/JtCascader/cascaderProps.test.ts && node tmp/unit-tests/cascaderProps.test.js"
|
|
54
53
|
},
|
|
55
54
|
"dependencies": {
|
|
56
|
-
"@element-plus/icons-vue": "^2.3.2",
|
|
57
55
|
"@jt-home/jt-language-tools": "^1.0.2",
|
|
58
56
|
"@jt-home/sdk-tools": "1.2.1-beta.4",
|
|
59
|
-
"
|
|
57
|
+
"@vue-office/pdf": "^2.0.2",
|
|
58
|
+
"vue-demi": "0.14.6"
|
|
60
59
|
},
|
|
61
60
|
"devDependencies": {
|
|
62
61
|
"@babel/eslint-parser": "^7.24.5",
|
|
@@ -69,6 +68,7 @@
|
|
|
69
68
|
"@typescript-eslint/parser": "^7.9.0",
|
|
70
69
|
"@vitejs/plugin-vue": "^5.2.4",
|
|
71
70
|
"@vue/tsconfig": "^0.8.1",
|
|
71
|
+
"@element-plus/icons-vue": "^2.3.2",
|
|
72
72
|
"element-plus": "^2.14.0",
|
|
73
73
|
"eslint": "^8.57.0",
|
|
74
74
|
"eslint-config-prettier": "^9.1.0",
|
|
@@ -94,6 +94,7 @@
|
|
|
94
94
|
"vue-tsc": "^3.1.5"
|
|
95
95
|
},
|
|
96
96
|
"peerDependencies": {
|
|
97
|
+
"@element-plus/icons-vue": "^2.3.2",
|
|
97
98
|
"element-plus": "^2.14.0",
|
|
98
99
|
"vue": "^3.5.10"
|
|
99
100
|
}
|