zhytech-ui 1.1.37 → 1.1.38
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 +5 -0
- package/dist/src/components/filePreview/components/videoPreview.vue.d.ts +67 -0
- package/dist/src/components/filePreview/index.d.ts +2 -2
- package/dist/src/components/filePreview/types/filePreviewType.d.ts +155 -1
- package/dist/src/index.d.ts +2 -2
- package/dist/style.css +1 -1
- package/dist/zhytech-ui.es.js +15942 -7280
- package/dist/zhytech-ui.umd.js +32 -11
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -70,6 +70,11 @@ setTheme("dark");
|
|
|
70
70
|
|
|
71
71
|
> #### 版本更新清单:
|
|
72
72
|
|
|
73
|
+
**V 1.1.38**
|
|
74
|
+
```html
|
|
75
|
+
1.优化文件预览,视频播放器参数,支持设置开始播放时间、支持禁用快进快退、支持设置宽高、支持设置自动播放、支持设置循环播放、支持设置静音、支持设置全屏、支持设置音量、支持设置播放速度、支持画中画、支持直播
|
|
76
|
+
```
|
|
77
|
+
|
|
73
78
|
**V 1.1.37**
|
|
74
79
|
```html
|
|
75
80
|
1.富文本组件(richTextEditor)新增隐藏顶部工具栏、显示浮动工具栏、自动获取焦点属性,暴漏option类型richTextConfigOption
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { videoConfigType } from '../types/filePreviewType';
|
|
2
|
+
declare const _default: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
|
|
3
|
+
src: {
|
|
4
|
+
type: StringConstructor;
|
|
5
|
+
required: true;
|
|
6
|
+
};
|
|
7
|
+
options: {
|
|
8
|
+
type: globalThis.PropType<videoConfigType>;
|
|
9
|
+
default: () => {};
|
|
10
|
+
};
|
|
11
|
+
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
12
|
+
canplay: (...args: any[]) => void;
|
|
13
|
+
canplaythrough: (...args: any[]) => void;
|
|
14
|
+
durationchange: (...args: any[]) => void;
|
|
15
|
+
ended: (...args: any[]) => void;
|
|
16
|
+
error: (...args: any[]) => void;
|
|
17
|
+
loadeddata: (...args: any[]) => void;
|
|
18
|
+
loadedmetadata: (...args: any[]) => void;
|
|
19
|
+
loadstart: (...args: any[]) => void;
|
|
20
|
+
pause: (...args: any[]) => void;
|
|
21
|
+
play: (...args: any[]) => void;
|
|
22
|
+
playing: (...args: any[]) => void;
|
|
23
|
+
progress: (...args: any[]) => void;
|
|
24
|
+
ratechange: (...args: any[]) => void;
|
|
25
|
+
stalled: (...args: any[]) => void;
|
|
26
|
+
timeupdate: (...args: any[]) => void;
|
|
27
|
+
volumechange: (...args: any[]) => void;
|
|
28
|
+
waiting: (...args: any[]) => void;
|
|
29
|
+
mirrorChange: (...args: any[]) => void;
|
|
30
|
+
loopChange: (...args: any[]) => void;
|
|
31
|
+
lightOffChange: (...args: any[]) => void;
|
|
32
|
+
}, string, import('vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
33
|
+
src: {
|
|
34
|
+
type: StringConstructor;
|
|
35
|
+
required: true;
|
|
36
|
+
};
|
|
37
|
+
options: {
|
|
38
|
+
type: globalThis.PropType<videoConfigType>;
|
|
39
|
+
default: () => {};
|
|
40
|
+
};
|
|
41
|
+
}>> & Readonly<{
|
|
42
|
+
onCanplay?: ((...args: any[]) => any) | undefined;
|
|
43
|
+
onCanplaythrough?: ((...args: any[]) => any) | undefined;
|
|
44
|
+
onDurationchange?: ((...args: any[]) => any) | undefined;
|
|
45
|
+
onEnded?: ((...args: any[]) => any) | undefined;
|
|
46
|
+
onError?: ((...args: any[]) => any) | undefined;
|
|
47
|
+
onLoadeddata?: ((...args: any[]) => any) | undefined;
|
|
48
|
+
onLoadedmetadata?: ((...args: any[]) => any) | undefined;
|
|
49
|
+
onLoadstart?: ((...args: any[]) => any) | undefined;
|
|
50
|
+
onPause?: ((...args: any[]) => any) | undefined;
|
|
51
|
+
onPlay?: ((...args: any[]) => any) | undefined;
|
|
52
|
+
onPlaying?: ((...args: any[]) => any) | undefined;
|
|
53
|
+
onProgress?: ((...args: any[]) => any) | undefined;
|
|
54
|
+
onRatechange?: ((...args: any[]) => any) | undefined;
|
|
55
|
+
onStalled?: ((...args: any[]) => any) | undefined;
|
|
56
|
+
onTimeupdate?: ((...args: any[]) => any) | undefined;
|
|
57
|
+
onVolumechange?: ((...args: any[]) => any) | undefined;
|
|
58
|
+
onWaiting?: ((...args: any[]) => any) | undefined;
|
|
59
|
+
onMirrorChange?: ((...args: any[]) => any) | undefined;
|
|
60
|
+
onLoopChange?: ((...args: any[]) => any) | undefined;
|
|
61
|
+
onLightOffChange?: ((...args: any[]) => any) | undefined;
|
|
62
|
+
}>, {
|
|
63
|
+
options: videoConfigType;
|
|
64
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
|
|
65
|
+
videoPlayer: unknown;
|
|
66
|
+
}, HTMLDivElement>;
|
|
67
|
+
export default _default;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { default as filePreview } from './index.vue';
|
|
2
|
-
import { fileView, previewOption } from './types/filePreviewType';
|
|
2
|
+
import { fileView, previewOption, videoConfigType } from './types/filePreviewType';
|
|
3
3
|
export { filePreview };
|
|
4
|
-
export type { fileView, previewOption };
|
|
4
|
+
export type { fileView, previewOption, videoConfigType };
|
|
@@ -15,6 +15,160 @@ export interface fileView {
|
|
|
15
15
|
*/
|
|
16
16
|
extensionName: string;
|
|
17
17
|
}
|
|
18
|
+
export interface videoConfigType {
|
|
19
|
+
/**
|
|
20
|
+
* 播放器宽度,默认800px
|
|
21
|
+
*/
|
|
22
|
+
width?: string;
|
|
23
|
+
/**
|
|
24
|
+
* 播放器高度,默认450px
|
|
25
|
+
*/
|
|
26
|
+
height?: string;
|
|
27
|
+
/**
|
|
28
|
+
* 主题色,默认#409eff
|
|
29
|
+
*/
|
|
30
|
+
color?: string;
|
|
31
|
+
/**
|
|
32
|
+
* 视频名称,默认空
|
|
33
|
+
*/
|
|
34
|
+
title?: string;
|
|
35
|
+
/**
|
|
36
|
+
* 视频类型,默认video/mp4
|
|
37
|
+
*/
|
|
38
|
+
type?: string;
|
|
39
|
+
/**
|
|
40
|
+
* 视频封面,默认空
|
|
41
|
+
*/
|
|
42
|
+
poster?: string;
|
|
43
|
+
/**
|
|
44
|
+
* 静音,默认false
|
|
45
|
+
*/
|
|
46
|
+
muted?: boolean;
|
|
47
|
+
/**
|
|
48
|
+
* 跳转到固定播放时间(s),默认0
|
|
49
|
+
*/
|
|
50
|
+
currentTime?: number;
|
|
51
|
+
/**
|
|
52
|
+
* 是否支持快进快退,默认true
|
|
53
|
+
*/
|
|
54
|
+
speed?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* 播放倍速,默认['0.5','0.75','1','1.25','1.5','2']
|
|
57
|
+
*/
|
|
58
|
+
speedRate?: string[];
|
|
59
|
+
/**
|
|
60
|
+
* 自动播放,默认false
|
|
61
|
+
*/
|
|
62
|
+
autoPlay?: boolean;
|
|
63
|
+
/**
|
|
64
|
+
* 循环播放,默认false
|
|
65
|
+
*/
|
|
66
|
+
loop?: boolean;
|
|
67
|
+
/**
|
|
68
|
+
* 预加载,默认auto
|
|
69
|
+
*/
|
|
70
|
+
preload?: "none" | "meta" | "auto";
|
|
71
|
+
/**
|
|
72
|
+
* 镜像画面,默认false
|
|
73
|
+
*/
|
|
74
|
+
mirror?: boolean;
|
|
75
|
+
/**
|
|
76
|
+
* 关灯模式,默认false
|
|
77
|
+
*/
|
|
78
|
+
ligthOff?: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* 视频音量大小,默认1
|
|
81
|
+
*/
|
|
82
|
+
volume?: number;
|
|
83
|
+
/**
|
|
84
|
+
* 是否显示控制条,默认true
|
|
85
|
+
*/
|
|
86
|
+
control?: boolean;
|
|
87
|
+
/**
|
|
88
|
+
* 控制条显示的按钮,默认['speedRate', 'volume', 'setting', 'pip', 'fullScreen']
|
|
89
|
+
*/
|
|
90
|
+
controlBtns?: ("speedRate" | "volume" | "setting" | "pip" | "fullScreen")[];
|
|
91
|
+
/**
|
|
92
|
+
* 镜像翻转事件
|
|
93
|
+
*/
|
|
94
|
+
onMirrorChange?: Function;
|
|
95
|
+
/**
|
|
96
|
+
* 循环播放开关事件
|
|
97
|
+
*/
|
|
98
|
+
onLoopChange?: Function;
|
|
99
|
+
/**
|
|
100
|
+
* 关灯模式事件
|
|
101
|
+
*/
|
|
102
|
+
onLightOffChange?: Function;
|
|
103
|
+
/**
|
|
104
|
+
* 客户端开始请求数据
|
|
105
|
+
*/
|
|
106
|
+
onLoadstart?: Function;
|
|
107
|
+
/**
|
|
108
|
+
* 客户端正在请求数据
|
|
109
|
+
*/
|
|
110
|
+
onProgress?: Function;
|
|
111
|
+
/**
|
|
112
|
+
* 请求数据时遇到错误
|
|
113
|
+
*/
|
|
114
|
+
onError?: Function;
|
|
115
|
+
/**
|
|
116
|
+
* 网速失速
|
|
117
|
+
*/
|
|
118
|
+
onStalled?: Function;
|
|
119
|
+
/**
|
|
120
|
+
* 开始播放时触发
|
|
121
|
+
*/
|
|
122
|
+
onPlay?: Function;
|
|
123
|
+
/**
|
|
124
|
+
* 暂停时触发
|
|
125
|
+
*/
|
|
126
|
+
onPause?: Function;
|
|
127
|
+
/**
|
|
128
|
+
* 成功获取资源长度
|
|
129
|
+
*/
|
|
130
|
+
onLoadedmetadata?: Function;
|
|
131
|
+
/**
|
|
132
|
+
* 缓冲中
|
|
133
|
+
*/
|
|
134
|
+
onLoadeddata?: Function;
|
|
135
|
+
/**
|
|
136
|
+
* 等待数据,并非错误
|
|
137
|
+
*/
|
|
138
|
+
onWaiting?: Function;
|
|
139
|
+
/**
|
|
140
|
+
* 开始回放
|
|
141
|
+
*/
|
|
142
|
+
onPlaying?: Function;
|
|
143
|
+
/**
|
|
144
|
+
* 暂停状态下可以播放
|
|
145
|
+
*/
|
|
146
|
+
onCanplay?: Function;
|
|
147
|
+
/**
|
|
148
|
+
* 可以持续播放
|
|
149
|
+
*/
|
|
150
|
+
onCanplaythrough?: Function;
|
|
151
|
+
/**
|
|
152
|
+
* 更新播放时间
|
|
153
|
+
*/
|
|
154
|
+
onTimeupdate?: Function;
|
|
155
|
+
/**
|
|
156
|
+
* 播放结束
|
|
157
|
+
*/
|
|
158
|
+
onEnded?: Function;
|
|
159
|
+
/**
|
|
160
|
+
* 播放速率改变
|
|
161
|
+
*/
|
|
162
|
+
onRatechange?: Function;
|
|
163
|
+
/**
|
|
164
|
+
* 资源长度改变
|
|
165
|
+
*/
|
|
166
|
+
onDurationchange?: Function;
|
|
167
|
+
/**
|
|
168
|
+
* 音量改变
|
|
169
|
+
*/
|
|
170
|
+
onVolumechange?: Function;
|
|
171
|
+
}
|
|
18
172
|
/**
|
|
19
173
|
* @description: 文档管理中文件上传参数类型
|
|
20
174
|
*/
|
|
@@ -30,7 +184,7 @@ export interface previewOption {
|
|
|
30
184
|
/**
|
|
31
185
|
* 自动播放视频
|
|
32
186
|
*/
|
|
33
|
-
|
|
187
|
+
videoConfig?: videoConfigType;
|
|
34
188
|
/**
|
|
35
189
|
* 自动播放音频
|
|
36
190
|
*/
|
package/dist/src/index.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { MessageType, filterConditionTypes, componentType } from './types/enum';
|
|
|
2
2
|
import { dynamicFilter as zhyDynamicFilter, conditionType, filterConditionPropType, filterConditionType, filterItemType, propOptionType } from './components/dynamicFilter/index';
|
|
3
3
|
import { documentView, dynamicFormData, formAttribute, dictionaryData, dictionaryItem, uploadOption, batchAddComponentParam, getFormTemplateMethod, formListView, searchParam, formDesigner as zhyFormDesigner, formRenderer as zhyFormRenderer } from './components/dynamicForm/index';
|
|
4
4
|
import { icon as zhyIcon } from './components/icon/index';
|
|
5
|
-
import { filePreview as zhyFilePreview, fileView, previewOption } from './components/filePreview/index';
|
|
5
|
+
import { filePreview as zhyFilePreview, fileView, previewOption, videoConfigType } from './components/filePreview/index';
|
|
6
6
|
import { richTextEditor as zhyRichTextEditor, richTextConfigOption } from './components/richTextEditor/index';
|
|
7
7
|
import { puzzleVcode as zhyPuzzleVcode, vcodeConfigOption } from './components/puzzleVCode/index';
|
|
8
8
|
/**
|
|
@@ -13,7 +13,7 @@ import { puzzleVcode as zhyPuzzleVcode, vcodeConfigOption } from './components/p
|
|
|
13
13
|
declare const setTheme: (theme: string) => void;
|
|
14
14
|
type optionView = OptionView;
|
|
15
15
|
type selectOptionsView = SelectOptionsView;
|
|
16
|
-
export type { optionView, selectOptionsView, conditionType, filterConditionPropType, filterConditionType, filterItemType, propOptionType, dynamicFormData, formAttribute, dictionaryData, dictionaryItem, uploadOption, documentView, batchAddComponentParam, getFormTemplateMethod, formListView, searchParam, fileView, previewOption, richTextConfigOption, vcodeConfigOption };
|
|
16
|
+
export type { optionView, selectOptionsView, conditionType, filterConditionPropType, filterConditionType, filterItemType, propOptionType, dynamicFormData, formAttribute, dictionaryData, dictionaryItem, uploadOption, documentView, batchAddComponentParam, getFormTemplateMethod, formListView, searchParam, fileView, previewOption, videoConfigType, richTextConfigOption, vcodeConfigOption };
|
|
17
17
|
export { MessageType, filterConditionTypes, componentType };
|
|
18
18
|
export { setTheme };
|
|
19
19
|
export { zhyFormDesigner, zhyFormRenderer, zhyDynamicFilter, zhyIcon, zhyFilePreview, zhyRichTextEditor, zhyPuzzleVcode };
|