cnhis-design-vue 3.3.3-release.8 → 3.3.3-release.9
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/README.md +87 -87
- package/es/components/audio-sdk/src/utils/recorder/fft.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/mp3-engine.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/mp3.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/recorder.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/wave.d.ts +4 -0
- package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
- package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
- package/es/components/bpmn-workflow/types/ModelingModule.d.ts +1 -0
- package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
- package/es/components/button-print/src/components/OldPrintComponent.vue2.js +1 -1
- package/es/components/card-render/src/components/index.d.ts +23 -23
- package/es/components/classification/src/components/table-modal/index.vue.d.ts +0 -3
- package/es/components/date-picker/src/DatePicker.vue2.js +8 -1
- package/es/components/field-set/src/FieldColor.vue.d.ts +4 -4
- package/es/components/field-set/src/FieldFilter.vue.d.ts +4 -4
- package/es/components/field-set/src/FieldSet.vue.d.ts +5 -5
- package/es/components/field-set/src/components/table-row.vue.d.ts +4 -4
- package/es/components/form-config/src/components/FormConfigEventSetting.vue2.js +1 -1
- package/es/components/form-render/src/components/renderer/searchCascade.js +3 -0
- package/es/components/form-render/src/hooks/useLowCodeReactions.js +2 -1
- package/es/components/iho-chat/index.d.ts +4 -4
- package/es/components/iho-chat/src/Index.vue.d.ts +4 -4
- package/es/components/iho-chat/src/components/ChatFile.vue.d.ts +2 -2
- package/es/components/iho-chat/src/components/ChatFile.vue2.js +5 -15
- package/es/components/iho-chat/src/components/ChatFooter.vue2.js +1 -1
- package/es/components/iho-chat/src/components/ChatHeader.vue.d.ts +2 -2
- package/es/components/iho-chat/src/components/ChatMain.vue.d.ts +3 -3
- package/es/components/iho-chat/src/components/ChatMain.vue2.js +7 -15
- package/es/components/iho-chat/src/components/ChatRecord.vue.d.ts +2 -2
- package/es/components/iho-chat/src/components/ChatRecord.vue2.js +3 -3
- package/es/components/iho-chat/src/components/ContextMenu.js +3 -11
- package/es/components/iho-chat/src/components/MessageMergeForward.vue.d.ts +2 -2
- package/es/components/iho-chat/src/components/MessageMergeForward.vue2.js +3 -3
- package/es/components/iho-chat/src/components/PersonProfile.vue2.js +1 -1
- package/es/components/iho-chat/src/hooks/useData.js +2 -7
- package/es/components/iho-chat/src/utils/index.d.ts +2 -3
- package/es/components/iho-chat/src/utils/index.js +20 -39
- package/es/components/iho-table/src/plugins/filterRenderPlugin/filter.vue2.js +8 -1
- package/es/components/iho-table/src/plugins/headerPlugin/index.js +5 -2
- package/es/components/iho-table/src/plugins/highLightSetPlugin.js +2 -1
- package/es/components/select-person/src/SelectPerson.vue2.js +1 -1
- package/es/env.d.ts +25 -25
- package/es/shared/assets/img/defaultCover/10review_successful.png.js +1 -1
- package/es/shared/assets/img/defaultCover/11review_fail.png.js +1 -1
- package/es/shared/assets/img/defaultCover/12no_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/13no_menu_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/14no_call_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/15no_use_tag.png.js +1 -1
- package/es/shared/assets/img/defaultCover/16no_table_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/1location.png.js +1 -1
- package/es/shared/assets/img/defaultCover/2notfound.png.js +1 -1
- package/es/shared/assets/img/defaultCover/3loading.png.js +1 -1
- package/es/shared/assets/img/defaultCover/4no_permission.png.js +1 -1
- package/es/shared/assets/img/defaultCover/5no_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/6no_network.png.js +1 -1
- package/es/shared/assets/img/defaultCover/7no_doctor.png.js +1 -1
- package/es/shared/assets/img/defaultCover/8system_error.png.js +1 -1
- package/es/shared/assets/img/defaultCover/9system_upgrade.png.js +1 -1
- package/es/shared/assets/img/failure.png.js +1 -1
- package/es/shared/assets/img/no-permission.png.js +1 -1
- package/es/shared/assets/img/nodata.png.js +1 -1
- package/es/shared/assets/img/notfound.png.js +1 -1
- package/es/shared/assets/img/qr.png.js +1 -1
- package/es/shared/assets/img/success.png.js +1 -1
- package/es/shared/assets/img/table_style_2.png.js +1 -1
- package/es/shared/assets/img/video.png.js +1 -1
- package/es/shared/assets/img/video_default_cover.png.js +1 -1
- package/es/shared/assets/img/xb_big.png.js +1 -1
- package/es/shared/assets/img/xb_small.png.js +1 -1
- package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +86 -0
- package/es/shared/package.json.js +1 -1
- package/es/shared/utils/fabricjs/index.d.ts +6823 -0
- package/es/shared/utils/tapable/index.d.ts +139 -0
- package/package.json +3 -3
package/README.md
CHANGED
@@ -1,87 +1,87 @@
|
|
1
|
-
# 安装
|
2
|
-
|
3
|
-
```shell
|
4
|
-
npm i cnhis-design-vue@[版本号]
|
5
|
-
# or
|
6
|
-
yarn add cnhis-design-vue@[版本号] #推荐
|
7
|
-
```
|
8
|
-
|
9
|
-
## 1.全局引入
|
10
|
-
|
11
|
-
```typescript
|
12
|
-
// main.ts
|
13
|
-
import { createApp } from 'vue';
|
14
|
-
import App from './App.vue';
|
15
|
-
import 'cnhis-design-vue/es/packages/index.css';
|
16
|
-
import cui from 'cnhis-design-vue';
|
17
|
-
|
18
|
-
const app = createApp(App);
|
19
|
-
app.use(cui).mount('#app');
|
20
|
-
```
|
21
|
-
|
22
|
-
## 2. 按需引入
|
23
|
-
|
24
|
-
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
25
|
-
|
26
|
-
### 2.1 样式处理方式1 (按需引入样式)
|
27
|
-
|
28
|
-
```shell
|
29
|
-
# 安装自动导入样式的插件
|
30
|
-
npm i -d vite-plugin-style-import
|
31
|
-
```
|
32
|
-
|
33
|
-
```typescript
|
34
|
-
// vite.config.ts
|
35
|
-
import { defineConfig } from 'vite';
|
36
|
-
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
37
|
-
|
38
|
-
export default defineConfig({
|
39
|
-
plugins: [
|
40
|
-
// ...otherPlugins
|
41
|
-
createStyleImportPlugin({
|
42
|
-
libs: [
|
43
|
-
{
|
44
|
-
libraryName: 'cnhis-design-vue',
|
45
|
-
esModule: true,
|
46
|
-
ensureStyleFile: true,
|
47
|
-
resolveStyle: name => {
|
48
|
-
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
49
|
-
}
|
50
|
-
}
|
51
|
-
]
|
52
|
-
})
|
53
|
-
]
|
54
|
-
});
|
55
|
-
```
|
56
|
-
|
57
|
-
### 2.2 样式处理方式2 (全局引入样式)
|
58
|
-
|
59
|
-
```typescript
|
60
|
-
// main.ts
|
61
|
-
import 'cnhis-design-vue/es/components/index.css';
|
62
|
-
```
|
63
|
-
|
64
|
-
## 3.FAQ
|
65
|
-
|
66
|
-
### 3.1 项目打包后样式丢失
|
67
|
-
|
68
|
-
处理方法, 将 cnhis-design-vue 从 vendor 包中移除 (没有出现此问题则不需要)
|
69
|
-
|
70
|
-
```typescript
|
71
|
-
// vite.config.ts
|
72
|
-
import { defineConfig } from 'vite';
|
73
|
-
|
74
|
-
export default defineConfig({
|
75
|
-
build: {
|
76
|
-
rollupOptions: {
|
77
|
-
// ..otherOptions
|
78
|
-
output: {
|
79
|
-
dir: './dist',
|
80
|
-
manualChunks: {
|
81
|
-
'cnhis-vendor': ['cnhis-design-vue']
|
82
|
-
}
|
83
|
-
}
|
84
|
-
}
|
85
|
-
}
|
86
|
-
});
|
87
|
-
```
|
1
|
+
# 安装
|
2
|
+
|
3
|
+
```shell
|
4
|
+
npm i cnhis-design-vue@[版本号]
|
5
|
+
# or
|
6
|
+
yarn add cnhis-design-vue@[版本号] #推荐
|
7
|
+
```
|
8
|
+
|
9
|
+
## 1.全局引入
|
10
|
+
|
11
|
+
```typescript
|
12
|
+
// main.ts
|
13
|
+
import { createApp } from 'vue';
|
14
|
+
import App from './App.vue';
|
15
|
+
import 'cnhis-design-vue/es/packages/index.css';
|
16
|
+
import cui from 'cnhis-design-vue';
|
17
|
+
|
18
|
+
const app = createApp(App);
|
19
|
+
app.use(cui).mount('#app');
|
20
|
+
```
|
21
|
+
|
22
|
+
## 2. 按需引入
|
23
|
+
|
24
|
+
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
25
|
+
|
26
|
+
### 2.1 样式处理方式1 (按需引入样式)
|
27
|
+
|
28
|
+
```shell
|
29
|
+
# 安装自动导入样式的插件
|
30
|
+
npm i -d vite-plugin-style-import
|
31
|
+
```
|
32
|
+
|
33
|
+
```typescript
|
34
|
+
// vite.config.ts
|
35
|
+
import { defineConfig } from 'vite';
|
36
|
+
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
37
|
+
|
38
|
+
export default defineConfig({
|
39
|
+
plugins: [
|
40
|
+
// ...otherPlugins
|
41
|
+
createStyleImportPlugin({
|
42
|
+
libs: [
|
43
|
+
{
|
44
|
+
libraryName: 'cnhis-design-vue',
|
45
|
+
esModule: true,
|
46
|
+
ensureStyleFile: true,
|
47
|
+
resolveStyle: name => {
|
48
|
+
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
49
|
+
}
|
50
|
+
}
|
51
|
+
]
|
52
|
+
})
|
53
|
+
]
|
54
|
+
});
|
55
|
+
```
|
56
|
+
|
57
|
+
### 2.2 样式处理方式2 (全局引入样式)
|
58
|
+
|
59
|
+
```typescript
|
60
|
+
// main.ts
|
61
|
+
import 'cnhis-design-vue/es/components/index.css';
|
62
|
+
```
|
63
|
+
|
64
|
+
## 3.FAQ
|
65
|
+
|
66
|
+
### 3.1 项目打包后样式丢失
|
67
|
+
|
68
|
+
处理方法, 将 cnhis-design-vue 从 vendor 包中移除 (没有出现此问题则不需要)
|
69
|
+
|
70
|
+
```typescript
|
71
|
+
// vite.config.ts
|
72
|
+
import { defineConfig } from 'vite';
|
73
|
+
|
74
|
+
export default defineConfig({
|
75
|
+
build: {
|
76
|
+
rollupOptions: {
|
77
|
+
// ..otherOptions
|
78
|
+
output: {
|
79
|
+
dir: './dist',
|
80
|
+
manualChunks: {
|
81
|
+
'cnhis-vendor': ['cnhis-design-vue']
|
82
|
+
}
|
83
|
+
}
|
84
|
+
}
|
85
|
+
}
|
86
|
+
});
|
87
|
+
```
|
File without changes
|
@@ -0,0 +1 @@
|
|
1
|
+
declare module 'bpmn-js/lib/Viewer';
|
@@ -0,0 +1 @@
|
|
1
|
+
declare module 'bpmn-js/lib/features/modeling';
|
@@ -0,0 +1 @@
|
|
1
|
+
declare module 'diagram-js/lib/navigation/movecanvas';
|
@@ -438,7 +438,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
438
438
|
params,
|
439
439
|
signature: props.signature
|
440
440
|
};
|
441
|
-
printInstance.downloadPDF(queryParams, (res) => callLocalServicesSuccessCb(res, "
|
441
|
+
printInstance.downloadPDF(queryParams, (res) => callLocalServicesSuccessCb(res, "download"), callLocalServicesErrorCb);
|
442
442
|
}).catch(() => {
|
443
443
|
prevFnError("download");
|
444
444
|
state.spinning = false;
|
@@ -143,6 +143,29 @@ declare function getComponent(type: COMPONENT_TYPE): import("vue").DefineCompone
|
|
143
143
|
default: () => {};
|
144
144
|
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
145
145
|
};
|
146
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "button-click"[], "button-click", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
147
|
+
config: {
|
148
|
+
default: () => {};
|
149
|
+
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
150
|
+
};
|
151
|
+
data: {
|
152
|
+
default: () => {};
|
153
|
+
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
154
|
+
};
|
155
|
+
}>> & {
|
156
|
+
"onButton-click"?: ((...args: any[]) => any) | undefined;
|
157
|
+
}, {
|
158
|
+
data: import("../../../../shared/types").AnyObject;
|
159
|
+
config: import("../../../../shared/types").AnyObject;
|
160
|
+
}> | import("vue").DefineComponent<{
|
161
|
+
config: {
|
162
|
+
default: () => {};
|
163
|
+
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
164
|
+
};
|
165
|
+
data: {
|
166
|
+
default: () => {};
|
167
|
+
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
168
|
+
};
|
146
169
|
}, {
|
147
170
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
148
171
|
config: {
|
@@ -468,29 +491,6 @@ declare function getComponent(type: COMPONENT_TYPE): import("vue").DefineCompone
|
|
468
491
|
default: () => {};
|
469
492
|
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
470
493
|
};
|
471
|
-
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "button-click"[], "button-click", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
472
|
-
config: {
|
473
|
-
default: () => {};
|
474
|
-
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
475
|
-
};
|
476
|
-
data: {
|
477
|
-
default: () => {};
|
478
|
-
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
479
|
-
};
|
480
|
-
}>> & {
|
481
|
-
"onButton-click"?: ((...args: any[]) => any) | undefined;
|
482
|
-
}, {
|
483
|
-
data: import("../../../../shared/types").AnyObject;
|
484
|
-
config: import("../../../../shared/types").AnyObject;
|
485
|
-
}> | import("vue").DefineComponent<{
|
486
|
-
config: {
|
487
|
-
default: () => {};
|
488
|
-
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
489
|
-
};
|
490
|
-
data: {
|
491
|
-
default: () => {};
|
492
|
-
type: import("vue").PropType<import("../../../../shared/types").AnyObject>;
|
493
|
-
};
|
494
494
|
}, {
|
495
495
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
496
496
|
config: {
|
@@ -235,7 +235,14 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
235
235
|
handleInputEvent(inputEls[1], end);
|
236
236
|
}
|
237
237
|
watch(() => props.formattedValue, (value) => {
|
238
|
-
placeholderRef.value = isAllowedInvalidValue(value) ? value : props.placeholder ? props.placeholder :
|
238
|
+
placeholderRef.value = isAllowedInvalidValue(value) ? value : props.placeholder ? props.placeholder : function() {
|
239
|
+
var _a, _b, _c;
|
240
|
+
try {
|
241
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.662")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.662")) || "\u9009\u62E9\u65E5\u671F\u65F6\u95F4";
|
242
|
+
} catch (e) {
|
243
|
+
return "\u9009\u62E9\u65E5\u671F\u65F6\u95F4";
|
244
|
+
}
|
245
|
+
}();
|
239
246
|
if (!isAllowedInvalidValue(value)) {
|
240
247
|
oldValue = value;
|
241
248
|
}
|
@@ -536,12 +536,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
536
536
|
}>;
|
537
537
|
developMode: boolean;
|
538
538
|
draggable: boolean;
|
539
|
-
|
540
|
-
isFieldSet: boolean;
|
541
|
-
hideExpressionOption: AnyObject[];
|
539
|
+
isHighlightRow: boolean;
|
542
540
|
idx: number;
|
543
541
|
isHighlight: boolean;
|
544
|
-
|
542
|
+
isFieldSet: boolean;
|
543
|
+
fieldDescribeMode: "column" | "tooltip";
|
544
|
+
hideExpressionOption: AnyObject[];
|
545
545
|
}>;
|
546
546
|
EditDialog: import("vue").DefineComponent<{
|
547
547
|
visible: {
|
@@ -565,12 +565,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
565
565
|
}>;
|
566
566
|
developMode: boolean;
|
567
567
|
draggable: boolean;
|
568
|
-
|
569
|
-
isFieldSet: boolean;
|
570
|
-
hideExpressionOption: AnyObject[];
|
568
|
+
isHighlightRow: boolean;
|
571
569
|
idx: number;
|
572
570
|
isHighlight: boolean;
|
573
|
-
|
571
|
+
isFieldSet: boolean;
|
572
|
+
fieldDescribeMode: "column" | "tooltip";
|
573
|
+
hideExpressionOption: AnyObject[];
|
574
574
|
}>;
|
575
575
|
setStyle: typeof setStyle;
|
576
576
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("close" | "save" | "reset")[], "close" | "save" | "reset", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
@@ -756,12 +756,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
756
756
|
}>;
|
757
757
|
developMode: boolean;
|
758
758
|
draggable: boolean;
|
759
|
-
|
760
|
-
isFieldSet: boolean;
|
761
|
-
hideExpressionOption: AnyObject[];
|
759
|
+
isHighlightRow: boolean;
|
762
760
|
idx: number;
|
763
761
|
isHighlight: boolean;
|
764
|
-
|
762
|
+
isFieldSet: boolean;
|
763
|
+
fieldDescribeMode: "column" | "tooltip";
|
764
|
+
hideExpressionOption: AnyObject[];
|
765
765
|
}>;
|
766
766
|
isArray: {
|
767
767
|
(value?: any): value is any[];
|
@@ -901,9 +901,9 @@ declare const _default: import("vue").DefineComponent<{
|
|
901
901
|
showSeq: boolean;
|
902
902
|
developMode: boolean;
|
903
903
|
footerFlag: boolean;
|
904
|
+
fieldDescribeMode: "column" | "tooltip";
|
904
905
|
customColumns: FieldSetColumnItem[];
|
905
906
|
showSortPriority: boolean;
|
906
907
|
showHeadFilter: boolean;
|
907
|
-
fieldDescribeMode: "column" | "tooltip";
|
908
908
|
}>;
|
909
909
|
export default _default;
|
@@ -383,11 +383,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
383
383
|
}>;
|
384
384
|
developMode: boolean;
|
385
385
|
draggable: boolean;
|
386
|
-
|
387
|
-
isFieldSet: boolean;
|
388
|
-
hideExpressionOption: AnyObject[];
|
386
|
+
isHighlightRow: boolean;
|
389
387
|
idx: number;
|
390
388
|
isHighlight: boolean;
|
391
|
-
|
389
|
+
isFieldSet: boolean;
|
390
|
+
fieldDescribeMode: "column" | "tooltip";
|
391
|
+
hideExpressionOption: AnyObject[];
|
392
392
|
}>;
|
393
393
|
export default _default;
|
@@ -254,7 +254,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
254
254
|
});
|
255
255
|
return res;
|
256
256
|
});
|
257
|
-
const setValueTypes = ["INPUT", "SELECT", "SEARCH", "REMOTE_SEARCH"];
|
257
|
+
const setValueTypes = ["INPUT", "SELECT", "SEARCH", "REMOTE_SEARCH", "DIGITAL"];
|
258
258
|
const setValueFieldOptions = computed(() => {
|
259
259
|
return fieldOptions.value.filter((item) => {
|
260
260
|
var _a;
|
@@ -253,6 +253,7 @@ const script = /* @__PURE__ */ defineComponent({
|
|
253
253
|
target.dispatchEvent(new CustomEvent("scroll"));
|
254
254
|
}
|
255
255
|
function filterValue(pattern, option) {
|
256
|
+
var _a;
|
256
257
|
if (!pattern || !option)
|
257
258
|
return false;
|
258
259
|
const {
|
@@ -260,6 +261,8 @@ const script = /* @__PURE__ */ defineComponent({
|
|
260
261
|
} = option;
|
261
262
|
if (props.checkStrategy.includes("child") && option.depth < maxDepthValue.value)
|
262
263
|
return false;
|
264
|
+
if (!mergeItemValue)
|
265
|
+
return (_a = option[labelKey.value]) == null ? void 0 : _a.includes(pattern.trim());
|
263
266
|
return mergeItemValue.length > 0 && mergeItemValue.some((item) => item.includes(pattern.trim()));
|
264
267
|
}
|
265
268
|
const {
|
@@ -29,7 +29,8 @@ function useLowCodeReactions(configListRef, formModel) {
|
|
29
29
|
const targetConfig = (_a = config.setValueField) == null ? void 0 : _a.find((item) => item.field === field.path.toString());
|
30
30
|
if (!targetConfig)
|
31
31
|
return;
|
32
|
-
|
32
|
+
const value = targetConfig.value === "null" ? null : targetConfig.value === "undefined" ? void 0 : targetConfig.value;
|
33
|
+
field.value = value;
|
33
34
|
})
|
34
35
|
};
|
35
36
|
function createFieldHandler(cb) {
|
@@ -933,7 +933,7 @@ declare const IhoChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
933
933
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
934
934
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
935
935
|
downloadFile: typeof import("./src/utils").downloadFile;
|
936
|
-
|
936
|
+
formatJsonstr: typeof import("./src/utils").formatJsonstr;
|
937
937
|
getFileType: typeof import("./src/utils").getFileType;
|
938
938
|
getDetail: typeof import("./src/utils").getDetail;
|
939
939
|
ChatAdd: import("vue").DefineComponent<{
|
@@ -1353,7 +1353,7 @@ declare const IhoChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1353
1353
|
formatTime: typeof import("./src/utils").formatTime;
|
1354
1354
|
isDoctorRole: typeof import("./src/utils").isDoctorRole;
|
1355
1355
|
getRoleName: typeof import("./src/utils").getRoleName;
|
1356
|
-
|
1356
|
+
formatJsonstr: typeof import("./src/utils").formatJsonstr;
|
1357
1357
|
getFileType: typeof import("./src/utils").getFileType;
|
1358
1358
|
getDetail: typeof import("./src/utils").getDetail;
|
1359
1359
|
showAudioAndVideoRecord: typeof import("./src/utils").showAudioAndVideoRecord;
|
@@ -1690,7 +1690,6 @@ declare const IhoChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1690
1690
|
renderToolbar: ({ nodes }: import("naive-ui").ImageRenderToolbarProps) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
1691
1691
|
[key: string]: any;
|
1692
1692
|
}>[];
|
1693
|
-
formatImage: (obj: string | import("../../shared/types").AnyObject, type: string) => any;
|
1694
1693
|
getHistoryRecord: () => Promise<void>;
|
1695
1694
|
handleSelectLabel: (event: MouseEvent, msgId: string) => void;
|
1696
1695
|
handleContextmenu: (event: MouseEvent, msgId: string) => Promise<void>;
|
@@ -1909,7 +1908,7 @@ declare const IhoChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1909
1908
|
getForwardTitle: typeof import("./src/utils").getForwardTitle;
|
1910
1909
|
isDoctorRole: typeof import("./src/utils").isDoctorRole;
|
1911
1910
|
getRoleName: typeof import("./src/utils").getRoleName;
|
1912
|
-
|
1911
|
+
formatJsonstr: typeof import("./src/utils").formatJsonstr;
|
1913
1912
|
getFileType: typeof import("./src/utils").getFileType;
|
1914
1913
|
getDetail: typeof import("./src/utils").getDetail;
|
1915
1914
|
showAudioAndVideoRecord: typeof import("./src/utils").showAudioAndVideoRecord;
|
@@ -2272,6 +2271,7 @@ declare const IhoChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
2272
2271
|
isAudioOrVideoMessage: typeof import("./src/utils").isAudioOrVideoMessage;
|
2273
2272
|
getAVTime: typeof import("./src/utils").getAVTime;
|
2274
2273
|
getForwardTitle: typeof import("./src/utils").getForwardTitle;
|
2274
|
+
formatJsonstr: typeof import("./src/utils").formatJsonstr;
|
2275
2275
|
MESSAGE_TYPE: typeof import("./src/constants").MESSAGE_TYPE;
|
2276
2276
|
ChatbubbleEllipsesOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
2277
2277
|
EllipsisHorizontal: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
@@ -934,7 +934,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
934
934
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
935
935
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
936
936
|
downloadFile: typeof import("./utils").downloadFile;
|
937
|
-
|
937
|
+
formatJsonstr: typeof import("./utils").formatJsonstr;
|
938
938
|
getFileType: typeof import("./utils").getFileType;
|
939
939
|
getDetail: typeof import("./utils").getDetail;
|
940
940
|
ChatAdd: import("vue").DefineComponent<{
|
@@ -1354,7 +1354,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
1354
1354
|
formatTime: typeof import("./utils").formatTime;
|
1355
1355
|
isDoctorRole: typeof import("./utils").isDoctorRole;
|
1356
1356
|
getRoleName: typeof import("./utils").getRoleName;
|
1357
|
-
|
1357
|
+
formatJsonstr: typeof import("./utils").formatJsonstr;
|
1358
1358
|
getFileType: typeof import("./utils").getFileType;
|
1359
1359
|
getDetail: typeof import("./utils").getDetail;
|
1360
1360
|
showAudioAndVideoRecord: typeof import("./utils").showAudioAndVideoRecord;
|
@@ -1691,7 +1691,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
1691
1691
|
renderToolbar: ({ nodes }: import("naive-ui").ImageRenderToolbarProps) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
1692
1692
|
[key: string]: any;
|
1693
1693
|
}>[];
|
1694
|
-
formatImage: (obj: string | AnyObject, type: string) => any;
|
1695
1694
|
getHistoryRecord: () => Promise<void>;
|
1696
1695
|
handleSelectLabel: (event: MouseEvent, msgId: string) => void;
|
1697
1696
|
handleContextmenu: (event: MouseEvent, msgId: string) => Promise<void>;
|
@@ -1910,7 +1909,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
1910
1909
|
getForwardTitle: typeof import("./utils").getForwardTitle;
|
1911
1910
|
isDoctorRole: typeof import("./utils").isDoctorRole;
|
1912
1911
|
getRoleName: typeof import("./utils").getRoleName;
|
1913
|
-
|
1912
|
+
formatJsonstr: typeof import("./utils").formatJsonstr;
|
1914
1913
|
getFileType: typeof import("./utils").getFileType;
|
1915
1914
|
getDetail: typeof import("./utils").getDetail;
|
1916
1915
|
showAudioAndVideoRecord: typeof import("./utils").showAudioAndVideoRecord;
|
@@ -2273,6 +2272,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
2273
2272
|
isAudioOrVideoMessage: typeof import("./utils").isAudioOrVideoMessage;
|
2274
2273
|
getAVTime: typeof import("./utils").getAVTime;
|
2275
2274
|
getForwardTitle: typeof import("./utils").getForwardTitle;
|
2275
|
+
formatJsonstr: typeof import("./utils").formatJsonstr;
|
2276
2276
|
MESSAGE_TYPE: typeof import("./constants").MESSAGE_TYPE;
|
2277
2277
|
ChatbubbleEllipsesOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
2278
2278
|
EllipsisHorizontal: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { PropType } from 'vue';
|
2
2
|
import { AnyObject } from '../../../../shared/types';
|
3
|
-
import { downloadFile,
|
3
|
+
import { downloadFile, formatJsonstr, getFileType, getDetail } from '../utils';
|
4
4
|
declare const _default: import("vue").DefineComponent<{
|
5
5
|
type: {
|
6
6
|
type: StringConstructor;
|
@@ -82,7 +82,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
82
82
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
83
83
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
84
84
|
downloadFile: typeof downloadFile;
|
85
|
-
|
85
|
+
formatJsonstr: typeof formatJsonstr;
|
86
86
|
getFileType: typeof getFileType;
|
87
87
|
getDetail: typeof getDetail;
|
88
88
|
ChatAdd: import("vue").DefineComponent<{
|
@@ -13,7 +13,7 @@ import { useScrollLoading } from '../../../../shared/hooks/useScrollLoading.js';
|
|
13
13
|
import { useData } from '../hooks/useData.js';
|
14
14
|
import 'stompjs';
|
15
15
|
import 'sockjs-client/dist/sockjs.min.js';
|
16
|
-
import {
|
16
|
+
import { formatJsonstr, getFileType, getDetail, downloadFile } from '../utils/index.js';
|
17
17
|
import 'trtc-sdk-v5';
|
18
18
|
import ChatAdd from './ChatAdd.vue.js';
|
19
19
|
|
@@ -103,17 +103,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
103
103
|
const newList = formatImageList(_list);
|
104
104
|
imageList.value = pageInfo.page > 1 ? imageList.value.concat(newList) : newList;
|
105
105
|
} else {
|
106
|
-
|
107
|
-
return new Promise(async (resolve) => {
|
108
|
-
const size = await getFileSize(item.content.fileUrl);
|
109
|
-
resolve({
|
110
|
-
...item,
|
111
|
-
size
|
112
|
-
});
|
113
|
-
});
|
114
|
-
});
|
115
|
-
const newList = await Promise.all(promiseList);
|
116
|
-
fileList.value = pageInfo.page > 1 ? fileList.value.concat(newList) : newList;
|
106
|
+
fileList.value = pageInfo.page > 1 ? fileList.value.concat(_list) : _list;
|
117
107
|
}
|
118
108
|
} catch (error) {
|
119
109
|
} finally {
|
@@ -209,7 +199,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
209
199
|
key: image,
|
210
200
|
width: "80",
|
211
201
|
height: "80",
|
212
|
-
src: unref(
|
202
|
+
src: unref(formatJsonstr)(image, "fileUrl")
|
213
203
|
}, null, 8, ["src"]);
|
214
204
|
}), 128))])]);
|
215
205
|
}), 128))]),
|
@@ -246,7 +236,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
246
236
|
return openBlock(), createElementBlock("div", {
|
247
237
|
class: "file-item",
|
248
238
|
key: i
|
249
|
-
}, [createElementVNode("span", _hoisted_3, toDisplayString(unref(getFileType)(item.content.msg)), 1), createElementVNode("div", _hoisted_4, [createElementVNode("span", _hoisted_5, toDisplayString(unref(
|
239
|
+
}, [createElementVNode("span", _hoisted_3, toDisplayString(unref(getFileType)(item.content.msg)), 1), createElementVNode("div", _hoisted_4, [createElementVNode("span", _hoisted_5, toDisplayString(unref(formatJsonstr)(item.content.msg, "fileName")), 1), createElementVNode("span", _hoisted_6, toDisplayString(unref(getDetail)(item, true)), 1)]), createElementVNode("div", _hoisted_7, [createVNode(ChatAdd, {
|
250
240
|
title: function() {
|
251
241
|
var _a, _b, _c;
|
252
242
|
try {
|
@@ -286,7 +276,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
286
276
|
trigger: withCtx(() => [createVNode(unref(NIcon), {
|
287
277
|
size: 16,
|
288
278
|
component: unref(DownloadOutline),
|
289
|
-
onClick: () => unref(downloadFile)(item.content.
|
279
|
+
onClick: () => unref(downloadFile)(item.content.msg)
|
290
280
|
}, null, 8, ["component", "onClick"])]),
|
291
281
|
default: withCtx(() => [createTextVNode(function() {
|
292
282
|
var _a, _b, _c;
|
@@ -292,7 +292,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
292
292
|
msg,
|
293
293
|
chatMessageType
|
294
294
|
};
|
295
|
-
if (
|
295
|
+
if ([MESSAGE_TYPE.FILE, MESSAGE_TYPE.IMAGE].includes(chatMessageType)) {
|
296
296
|
_content.fileUrl = url;
|
297
297
|
}
|
298
298
|
if (origin === "btn") {
|
@@ -401,7 +401,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
401
401
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
402
402
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
403
403
|
downloadFile: typeof import("../utils").downloadFile;
|
404
|
-
|
404
|
+
formatJsonstr: typeof import("../utils").formatJsonstr;
|
405
405
|
getFileType: typeof import("../utils").getFileType;
|
406
406
|
getDetail: typeof import("../utils").getDetail;
|
407
407
|
ChatAdd: import("vue").DefineComponent<{
|
@@ -821,7 +821,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
821
821
|
formatTime: typeof import("../utils").formatTime;
|
822
822
|
isDoctorRole: typeof import("../utils").isDoctorRole;
|
823
823
|
getRoleName: typeof import("../utils").getRoleName;
|
824
|
-
|
824
|
+
formatJsonstr: typeof import("../utils").formatJsonstr;
|
825
825
|
getFileType: typeof import("../utils").getFileType;
|
826
826
|
getDetail: typeof import("../utils").getDetail;
|
827
827
|
showAudioAndVideoRecord: typeof import("../utils").showAudioAndVideoRecord;
|