hy-dispatch-ui-v3 0.1.6 → 0.2.1

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.
Files changed (160) hide show
  1. package/README.md +47 -0
  2. package/dist/tailwind.css +349 -4
  3. package/es/components/appAudioPlayer/appAudioPlayer.vue.mjs +462 -0
  4. package/es/components/appAudioPlayer/index.mjs +6 -0
  5. package/es/components/appAudioPlayer/js/index.mjs +327 -0
  6. package/es/components/appAudioPlayer/style/appAudioPlayer.scss +319 -0
  7. package/es/components/appButton/style/appButton.scss +0 -1
  8. package/es/components/appConfigProvider/appConfigProvider.vue.mjs +22 -1
  9. package/es/components/appCutter/appCutter.vue.mjs +202 -129
  10. package/es/components/appDatePicker/appDatePicker.vue.mjs +1 -1
  11. package/es/components/appForm/appForm.vue.mjs +132 -209
  12. package/es/components/appForm/cpns/appFormItem.vue.mjs +312 -0
  13. package/es/components/appForm/cpns/arrayItem.vue.mjs +305 -0
  14. package/es/components/appForm/cpns/extraItem.vue.mjs +140 -0
  15. package/es/components/appForm/js/index.mjs +46 -24
  16. package/es/components/appForm/js/useAppForm.mjs +30 -6
  17. package/es/components/appForm/style/appForm.scss +53 -0
  18. package/es/components/appIcon/appIcon.vue.mjs +0 -1
  19. package/es/components/appIconBox/style/appIconBox.scss +0 -1
  20. package/es/components/appInput/appInput.vue.mjs +99 -0
  21. package/es/components/appInput/index.mjs +6 -0
  22. package/es/components/appMenu/appMenu.vue.mjs +129 -0
  23. package/es/components/appMenu/index.mjs +6 -0
  24. package/es/components/appMenu/style/appMenu.scss +145 -0
  25. package/es/components/appOrgCascader/appOrgCascader.vue.mjs +14 -10
  26. package/es/components/appSearch/appSearch.vue.mjs +55 -211
  27. package/es/components/appSearch/cpns/appSearchItem.vue.mjs +238 -0
  28. package/es/components/appSearch/js/index.mjs +20 -8
  29. package/es/components/appSearch/js/useAppSearch.mjs +10 -5
  30. package/es/components/appSearch/style/appSearch.scss +10 -0
  31. package/es/components/appTable/appTable.vue.mjs +312 -158
  32. package/es/components/appTable/cpns/columnSelect.vue.mjs +151 -156
  33. package/es/components/appTable/cpns/columnSelectItem.vue2.mjs +104 -110
  34. package/es/components/appTable/cpns/headerItem.vue.mjs +98 -0
  35. package/es/components/appTable/cpns/virtualTable.vue.mjs +560 -0
  36. package/es/components/appTable/js/index.mjs +46 -20
  37. package/es/components/appTable/js/search.mjs +1 -2
  38. package/es/components/appTable/js/useAppTable.mjs +58 -14
  39. package/es/components/appTable/style/appTable.scss +16 -0
  40. package/es/components/appTooltip/appTooltip.vue.mjs +24 -13
  41. package/es/components/appTree/appTree.vue.mjs +304 -0
  42. package/es/components/appTree/index.mjs +6 -0
  43. package/es/components/appTree/js/index.mjs +531 -0
  44. package/es/components/appUserAvatar/appUserAvatar.vue.mjs +9 -8
  45. package/es/components/appUserAvatar/style/appUserAvatar.scss +0 -1
  46. package/es/components/appVideoPlayer/appVideoPlayer.vue.mjs +645 -0
  47. package/es/components/appVideoPlayer/cpns/mediaLoading.vue.mjs +35 -0
  48. package/es/components/appVideoPlayer/index.mjs +6 -0
  49. package/es/components/appVideoPlayer/js/index.mjs +426 -0
  50. package/es/components/appVideoPlayer/style/appVideoPlayer.scss +275 -0
  51. package/es/components/appVideoPlayer/style/mediaLoading.scss +62 -0
  52. package/es/components/index.mjs +5 -0
  53. package/es/hooks/index.mjs +3 -0
  54. package/es/hooks/useApi.mjs +4 -4
  55. package/es/hooks/useAudioPlayerConfig.mjs +12 -0
  56. package/es/hooks/useGlobalConfig.mjs +18 -7
  57. package/es/hooks/useLocale.mjs +3 -11
  58. package/es/hooks/useMixins.mjs +1 -1
  59. package/es/hooks/usePermissionMap.mjs +12 -0
  60. package/es/hooks/useUserAvatarMap.mjs +2 -3
  61. package/es/hooks/useVideoPlayerConfig.mjs +12 -0
  62. package/es/index.mjs +13 -4
  63. package/es/locale/en.mjs +52 -3
  64. package/es/locale/zh_CN.mjs +48 -3
  65. package/es/make-installer.mjs +2 -0
  66. package/es/static/hy-svg-icons.js +462 -0
  67. package/es/static/index.js +2 -0
  68. package/es/static/protocolcheck.js +247 -0
  69. package/es/style/element/element.scss +9 -0
  70. package/es/style/element/index.scss +6 -3
  71. package/es/style/index.scss +11 -0
  72. package/es/style/theme.scss +73 -0
  73. package/es/utils/date.mjs +25 -1
  74. package/es/utils/file.mjs +5 -4
  75. package/es/utils/form.mjs +52 -0
  76. package/es/utils/handler.mjs +22 -2
  77. package/es/utils/index.mjs +5 -4
  78. package/es/utils/is.mjs +23 -2
  79. package/es/version.mjs +1 -1
  80. package/lib/components/appAudioPlayer/appAudioPlayer.vue.js +466 -0
  81. package/lib/components/appAudioPlayer/index.js +11 -0
  82. package/lib/components/appAudioPlayer/js/index.js +329 -0
  83. package/lib/components/appAudioPlayer/style/appAudioPlayer.scss +319 -0
  84. package/lib/components/appButton/style/appButton.scss +0 -1
  85. package/lib/components/appConfigProvider/appConfigProvider.vue.js +22 -1
  86. package/lib/components/appCutter/appCutter.vue.js +201 -128
  87. package/lib/components/appDatePicker/appDatePicker.vue.js +1 -1
  88. package/lib/components/appForm/appForm.vue.js +129 -206
  89. package/lib/components/appForm/cpns/appFormItem.vue.js +316 -0
  90. package/lib/components/appForm/cpns/arrayItem.vue.js +309 -0
  91. package/lib/components/appForm/cpns/extraItem.vue.js +144 -0
  92. package/lib/components/appForm/js/index.js +48 -23
  93. package/lib/components/appForm/js/useAppForm.js +30 -6
  94. package/lib/components/appForm/style/appForm.scss +53 -0
  95. package/lib/components/appIcon/appIcon.vue.js +0 -1
  96. package/lib/components/appIconBox/style/appIconBox.scss +0 -1
  97. package/lib/components/appInput/appInput.vue.js +103 -0
  98. package/lib/components/appInput/index.js +11 -0
  99. package/lib/components/appMenu/appMenu.vue.js +133 -0
  100. package/lib/components/appMenu/index.js +11 -0
  101. package/lib/components/appMenu/style/appMenu.scss +145 -0
  102. package/lib/components/appOrgCascader/appOrgCascader.vue.js +14 -10
  103. package/lib/components/appSearch/appSearch.vue.js +51 -207
  104. package/lib/components/appSearch/cpns/appSearchItem.vue.js +242 -0
  105. package/lib/components/appSearch/js/index.js +20 -7
  106. package/lib/components/appSearch/js/useAppSearch.js +10 -5
  107. package/lib/components/appSearch/style/appSearch.scss +10 -0
  108. package/lib/components/appTable/appTable.vue.js +319 -165
  109. package/lib/components/appTable/cpns/columnSelect.vue.js +151 -156
  110. package/lib/components/appTable/cpns/columnSelectItem.vue2.js +105 -111
  111. package/lib/components/appTable/cpns/headerItem.vue.js +102 -0
  112. package/lib/components/appTable/cpns/virtualTable.vue.js +564 -0
  113. package/lib/components/appTable/js/index.js +47 -19
  114. package/lib/components/appTable/js/search.js +1 -2
  115. package/lib/components/appTable/js/useAppTable.js +57 -13
  116. package/lib/components/appTable/style/appTable.scss +16 -0
  117. package/lib/components/appTooltip/appTooltip.vue.js +23 -12
  118. package/lib/components/appTree/appTree.vue.js +308 -0
  119. package/lib/components/appTree/index.js +11 -0
  120. package/lib/components/appTree/js/index.js +533 -0
  121. package/lib/components/appUserAvatar/appUserAvatar.vue.js +9 -8
  122. package/lib/components/appUserAvatar/style/appUserAvatar.scss +0 -1
  123. package/lib/components/appVideoPlayer/appVideoPlayer.vue.js +649 -0
  124. package/lib/components/appVideoPlayer/cpns/mediaLoading.vue.js +39 -0
  125. package/lib/components/appVideoPlayer/index.js +11 -0
  126. package/lib/components/appVideoPlayer/js/index.js +429 -0
  127. package/lib/components/appVideoPlayer/style/appVideoPlayer.scss +275 -0
  128. package/lib/components/appVideoPlayer/style/mediaLoading.scss +62 -0
  129. package/lib/components/index.js +42 -32
  130. package/lib/hooks/index.js +9 -0
  131. package/lib/hooks/useApi.js +4 -4
  132. package/lib/hooks/useAudioPlayerConfig.js +15 -0
  133. package/lib/hooks/useGlobalConfig.js +18 -7
  134. package/lib/hooks/useLocale.js +3 -11
  135. package/lib/hooks/useMixins.js +1 -1
  136. package/lib/hooks/usePermissionMap.js +15 -0
  137. package/lib/hooks/useUserAvatarMap.js +1 -2
  138. package/lib/hooks/useVideoPlayerConfig.js +15 -0
  139. package/lib/index.js +59 -33
  140. package/lib/locale/en.js +52 -3
  141. package/lib/locale/zh_CN.js +48 -3
  142. package/lib/make-installer.js +2 -0
  143. package/lib/static/hy-svg-icons.js +459 -8
  144. package/lib/static/index.js +5 -0
  145. package/lib/static/protocolcheck.js +249 -0
  146. package/lib/style/element/element.scss +9 -0
  147. package/lib/style/element/index.scss +6 -3
  148. package/lib/style/index.scss +11 -0
  149. package/lib/style/theme.scss +73 -0
  150. package/lib/utils/date.js +25 -0
  151. package/lib/utils/file.js +4 -4
  152. package/lib/utils/form.js +57 -0
  153. package/lib/utils/handler.js +22 -1
  154. package/lib/utils/index.js +8 -1
  155. package/lib/utils/is.js +23 -1
  156. package/lib/version.js +1 -1
  157. package/package.json +25 -9
  158. package/es/config/index.mjs +0 -1
  159. package/es/static/hy-svg-icons.mjs +0 -11
  160. package/lib/config/index.js +0 -2
@@ -0,0 +1,329 @@
1
+ 'use strict';
2
+
3
+ var vue = require('vue');
4
+ var elementPlus = require('element-plus');
5
+ var useAudioPlayerConfig = require('../../../hooks/useAudioPlayerConfig.js');
6
+ var useLocale = require('../../../hooks/useLocale.js');
7
+ var date = require('../../../utils/date.js');
8
+
9
+ const useAudioPlayer = (hy) => {
10
+ const { props, emits, audioRef } = hy;
11
+ const { t } = useLocale.useLocale();
12
+ const { audioPlayerConfig } = useAudioPlayerConfig.useAudioPlayerConfig();
13
+ const speed = vue.ref(1);
14
+ const playRules = vue.ref(1);
15
+ const loading = vue.ref(false);
16
+ const audioItem = vue.ref({});
17
+ const audioUrl = vue.ref("");
18
+ const totalTime = vue.ref(0);
19
+ const curTime = vue.ref(0);
20
+ const progress = vue.ref(0);
21
+ const isDrop = vue.ref(false);
22
+ const isFullScreen = vue.ref(false);
23
+ const volumeValue = vue.ref(100);
24
+ const audioState = vue.ref("NO_LOAD");
25
+ const speedList = [
26
+ { value: 0.5, label: "0.5 X" },
27
+ { value: 1, label: "1.0 X" },
28
+ { value: 1.5, label: "1.5 X" },
29
+ { value: 2, label: "2.0 X" },
30
+ { value: 3, label: "3.0 X" }
31
+ ];
32
+ const playRulesList = [
33
+ {
34
+ value: 1,
35
+ label: t("audioPlayer.stopAfterPlayback"),
36
+ svgName: "player-mediaCenter_stopPlaying"
37
+ },
38
+ {
39
+ value: 2,
40
+ label: t("audioPlayer.continuousPlayback"),
41
+ svgName: "player-mediaCenter_autoplay"
42
+ },
43
+ {
44
+ value: 3,
45
+ label: t("audioPlayer.loopPlayback"),
46
+ svgName: "player-mediaCenter_loopPlayback"
47
+ }
48
+ ];
49
+ const isAnalyseType = vue.computed(() => {
50
+ return props.type === "analyse";
51
+ });
52
+ const speedLabel = vue.computed(() => {
53
+ if (speed.value === 1) {
54
+ return t("audioPlayer.multiples");
55
+ } else {
56
+ return speedList.find((item) => item.value === speed.value).label;
57
+ }
58
+ });
59
+ const isCanPlay = vue.computed(() => {
60
+ return audioState.value !== "NO_LOAD" || audioState.value !== "CAN_NOT_PLAY";
61
+ });
62
+ const isPlaying = vue.computed(() => {
63
+ return audioState.value === "PLAYING";
64
+ });
65
+ const currentDuration = vue.computed(() => {
66
+ const time = date.formatDuration(curTime.value, true);
67
+ if (!time) return "- -";
68
+ return `${time}"`;
69
+ });
70
+ const totalDuration = vue.computed(() => {
71
+ const time = date.formatDuration(totalTime.value, true);
72
+ if (!time) return "- -";
73
+ return `${time}"`;
74
+ });
75
+ async function initPlayer() {
76
+ await vue.nextTick();
77
+ audioRef.value.addEventListener("canplay", (e) => {
78
+ loading.value = false;
79
+ audioState.value = "IS_LOAD";
80
+ totalTime.value = Math.floor(audioRef.value.duration);
81
+ emits("canplay", e);
82
+ });
83
+ audioRef.value.addEventListener("play", () => {
84
+ audioRef.value.playbackRate = speed.value;
85
+ audioState.value = "PLAYING";
86
+ if (audioUrl.value && audioItem.value) {
87
+ emits("play-start", audioUrl.value, audioItem.value);
88
+ }
89
+ });
90
+ audioRef.value.addEventListener("pause", (e) => {
91
+ audioState.value = "PAUSE";
92
+ });
93
+ audioRef.value.addEventListener("volumechange", () => {
94
+ volumeValue.value = audioRef.value.volume * 100;
95
+ });
96
+ audioRef.value.addEventListener("ended", () => {
97
+ audioState.value = "PLAY_END";
98
+ if (playRules.value === 2) {
99
+ playNext();
100
+ } else if (playRules.value === 3) {
101
+ audioRef.value.load();
102
+ audioRef.value.play();
103
+ }
104
+ emits("play-ended");
105
+ });
106
+ audioRef.value.addEventListener(
107
+ "timeupdate",
108
+ (e) => {
109
+ audioState.value = "PLAYING";
110
+ if (!isDrop.value && audioRef.value) {
111
+ const currentTime = audioRef.value.currentTime;
112
+ if (audioRef.value) {
113
+ curTime.value = Math.floor(currentTime);
114
+ } else {
115
+ setTimeout(() => {
116
+ if (audioRef.value) {
117
+ curTime.value = Math.floor(currentTime);
118
+ }
119
+ }, 1e3);
120
+ }
121
+ progress.value = curTime.value / totalTime.value * 100;
122
+ emits("timeupdate", e);
123
+ }
124
+ },
125
+ false
126
+ );
127
+ audioRef.value.addEventListener("error", (e) => {
128
+ loading.value = false;
129
+ audioState.value = "CAN_NOT_PLAY";
130
+ console.error("error", e);
131
+ audioRef.value = null;
132
+ });
133
+ }
134
+ async function playAudio(filePath, item) {
135
+ if (audioState.value === "CAN_NOT_PLAY") {
136
+ audioState.value = "NO_LOAD";
137
+ await vue.nextTick();
138
+ initPlayer();
139
+ }
140
+ if (item) {
141
+ if (item.id !== audioItem.value.id || !audioRef.value.src) {
142
+ loading.value = true;
143
+ audioItem.value = item;
144
+ audioUrl.value = filePath;
145
+ audioRef.value.src = filePath;
146
+ }
147
+ } else if (audioUrl.value === "") {
148
+ return false;
149
+ }
150
+ if (audioItem.value.playSeconds) {
151
+ jumpDuration(audioItem.value.playSeconds);
152
+ }
153
+ await vue.nextTick();
154
+ audioRef.value.play();
155
+ audioState.value = "PLAYING";
156
+ }
157
+ function pauseAudio() {
158
+ if (audioState.value === "CAN_NOT_PLAY") return;
159
+ audioRef.value && audioRef.value.pause();
160
+ audioState.value = "PAUSE";
161
+ }
162
+ function playPrevious() {
163
+ if (props.type === "default") {
164
+ const index = props.playList.findIndex(
165
+ (item) => item.id === audioItem.value.id
166
+ );
167
+ if (index > 0 && index !== props.playList.length) {
168
+ const item = props.playList[index - 1];
169
+ playAudio(item.filePath, item);
170
+ emits("play-previous");
171
+ } else {
172
+ elementPlus.ElMessage.warning(t("audioPlayer.currentIsTheFirstItem"));
173
+ }
174
+ } else if (isAnalyseType.value) {
175
+ if (!isCanPlay.value) return;
176
+ emits("play-previous");
177
+ }
178
+ }
179
+ function playNext() {
180
+ if (props.type === "default") {
181
+ const index = props.playList.findIndex(
182
+ (item) => item.id === audioItem.value.id
183
+ );
184
+ if (index !== props.playList.length - 1) {
185
+ const item = props.playList[index + 1];
186
+ playAudio(item.filePath, item);
187
+ emits("play-next");
188
+ } else {
189
+ elementPlus.ElMessage.warning(t("audioPlayer.currentIsTheLastItem"));
190
+ }
191
+ } else if (isAnalyseType.value) {
192
+ if (!isCanPlay.value) return;
193
+ emits("play-next");
194
+ }
195
+ }
196
+ function playRulesHandler(value) {
197
+ if (value === 3) {
198
+ playRules.value = 1;
199
+ } else {
200
+ playRules.value = value + 1;
201
+ }
202
+ }
203
+ function speedHandler(value) {
204
+ speed.value = value;
205
+ if (!audioRef.value) return;
206
+ audioRef.value.playbackRate = value;
207
+ }
208
+ function changeVolume() {
209
+ if (!audioRef.value) return;
210
+ audioRef.value.volume = volumeValue.value / 100;
211
+ }
212
+ function getNowWh() {
213
+ curTime.value = totalTime.value * (progress.value / 100);
214
+ audioRef.value.currentTime = curTime.value;
215
+ isDrop.value = false;
216
+ }
217
+ function setAudioCurrentTime(currentTime) {
218
+ if (!audioRef.value || typeof currentTime !== "number") return;
219
+ audioRef.value.currentTime = currentTime;
220
+ }
221
+ function getPercent(num, total) {
222
+ num = parseFloat(num);
223
+ total = parseFloat(total);
224
+ if (isNaN(num) || isNaN(total)) {
225
+ return 0;
226
+ }
227
+ return total <= 0 ? 0 : Math.round(num / total * 1e4) / 100;
228
+ }
229
+ function isCantPlayType(e) {
230
+ if (e.target.error) {
231
+ const { code, message } = e.target.error;
232
+ return code === 4 && !message.includes("Format error") || message.includes("PIPELINE_ERROR_DECODE");
233
+ }
234
+ return false;
235
+ }
236
+ function jumpDuration(s) {
237
+ audioRef.value.currentTime = s;
238
+ }
239
+ function initFullScreenEvent() {
240
+ document.addEventListener("fullscreenchange", fullscreenchangeHandler);
241
+ }
242
+ function destroyFullScreenEvent() {
243
+ document.removeEventListener("fullscreenchange", fullscreenchangeHandler);
244
+ }
245
+ function fullscreenchangeHandler(e) {
246
+ if (document.fullscreenElement) ; else {
247
+ isFullScreen.value = false;
248
+ }
249
+ }
250
+ function onFullScreenHandler() {
251
+ if (isFullScreen.value) {
252
+ const el = document;
253
+ if (el.exitFullscreen) {
254
+ el.exitFullscreen();
255
+ }
256
+ } else {
257
+ const el = document.documentElement;
258
+ if (el.requestFullscreen) {
259
+ isFullScreen.value = true;
260
+ el.requestFullscreen();
261
+ }
262
+ }
263
+ }
264
+ function audioCutting() {
265
+ const canvas = document.createElement("canvas");
266
+ const img = document.getElementById("img");
267
+ const audio = audioRef.value;
268
+ audio.setAttribute("crossOrigin", "anonymous");
269
+ canvas.width = audio.clientWidth;
270
+ canvas.height = audio.clientHeight;
271
+ canvas.getContext("2d").drawImage(audio, 0, 0, canvas.width, canvas.height);
272
+ const dataURL = canvas.toDataURL("image/png");
273
+ img.setAttribute("src", dataURL);
274
+ }
275
+ function onDownloadHandler() {
276
+ if (props.downloadFn) {
277
+ props.downloadFn(audioItem.value, props.playList);
278
+ return;
279
+ }
280
+ if (audioPlayerConfig.value.downloadFn) {
281
+ audioPlayerConfig.value.downloadFn(audioItem.value, props.playList);
282
+ return;
283
+ }
284
+ }
285
+ playRulesHandler(props.playRules);
286
+ speedHandler(props.speed);
287
+ initPlayer();
288
+ return {
289
+ speed,
290
+ playRules,
291
+ loading,
292
+ audioItem,
293
+ audioUrl,
294
+ currentDuration,
295
+ totalDuration,
296
+ progress,
297
+ isDrop,
298
+ isFullScreen,
299
+ volumeValue,
300
+ audioState,
301
+ speedLabel,
302
+ isCanPlay,
303
+ isPlaying,
304
+ isAnalyseType,
305
+ // 配置
306
+ speedList,
307
+ playRulesList,
308
+ // 函数
309
+ playAudio,
310
+ pauseAudio,
311
+ playPrevious,
312
+ playNext,
313
+ playRulesHandler,
314
+ speedHandler,
315
+ changeVolume,
316
+ getNowWh,
317
+ setAudioCurrentTime,
318
+ getPercent,
319
+ isCantPlayType,
320
+ jumpDuration,
321
+ initFullScreenEvent,
322
+ destroyFullScreenEvent,
323
+ onFullScreenHandler,
324
+ audioCutting,
325
+ onDownloadHandler
326
+ };
327
+ };
328
+
329
+ exports.useAudioPlayer = useAudioPlayer;
@@ -0,0 +1,319 @@
1
+ .audio-player {
2
+ width: 100%;
3
+ height: 256px;
4
+ display: flex;
5
+ flex-direction: column;
6
+ border: 1px solid rgba(var(--hy-border));
7
+ border-radius: 12px;
8
+ overflow: hidden;
9
+ .audio-play-box {
10
+ width: 100%;
11
+ height: 0;
12
+ flex: 1;
13
+ display: flex;
14
+ justify-content: center;
15
+ align-items: center;
16
+ background: rgba(var(--hy-background-3));
17
+ box-shadow: rgba(var(--hy-dialog-box-shadow));
18
+ border: 1px solid rgba(var(--hy-dialog-border));
19
+ border-radius: rgba(var(--hy-dialog-border-radius))
20
+ rgba(var(--hy-dialog-border-radius)) 0px 0px;
21
+
22
+ .point_area {
23
+ text-align: center;
24
+ position: relative;
25
+ width: 160px;
26
+ height: 160px;
27
+ transition: opacity 0.5s ease-out;
28
+ .point {
29
+ position: absolute !important;
30
+ top: 0;
31
+ left: 0;
32
+ right: 0;
33
+ bottom: 0;
34
+ width: 60%;
35
+ height: 60%;
36
+ margin: auto;
37
+ -webkit-border-radius: 50%;
38
+ -webkit-background-clip: padding-box;
39
+ -moz-border-radius: 50%;
40
+ -moz-background-clip: padding;
41
+ }
42
+ .point_dot {
43
+ width: 96px;
44
+ height: 96px;
45
+ display: flex;
46
+ align-items: center;
47
+ justify-content: center;
48
+ border-radius: 50%;
49
+ color: rgba(var(--hy-main));
50
+ background-color: rgba(var(--hy-background-2));
51
+ z-index: 1;
52
+ .app-icon {
53
+ width: 58px;
54
+ height: 58px;
55
+ }
56
+ }
57
+ .point_10 {
58
+ width: 100%;
59
+ height: 100%;
60
+ }
61
+ .point_10:after {
62
+ content: '';
63
+ display: block;
64
+ position: absolute;
65
+ top: 0;
66
+ right: 0;
67
+ bottom: 0;
68
+ left: 0;
69
+ border-radius: 50%;
70
+ border: 4px solid rgba(var(--hy-theme));
71
+ opacity: 0;
72
+ -webkit-animation: ripple 4.5s ease-out 225ms infinite;
73
+ animation: ripple 4.5s ease-out 225ms infinite;
74
+ }
75
+ .point_40 {
76
+ width: 100%;
77
+ height: 100%;
78
+ }
79
+ .point_40:after {
80
+ content: '';
81
+ display: block;
82
+ position: absolute;
83
+ top: 0;
84
+ right: 0;
85
+ bottom: 0;
86
+ left: 0;
87
+ border-radius: 50%;
88
+ border: 4px solid rgba(var(--hy-theme));
89
+ opacity: 0;
90
+ -webkit-animation: ripple 4.5s ease-out 0.9s infinite;
91
+ animation: ripple 4.5s ease-out 0.9s infinite;
92
+ }
93
+ .point_80 {
94
+ width: 100%;
95
+ height: 100%;
96
+ }
97
+ .point_80:after {
98
+ content: '';
99
+ display: block;
100
+ position: absolute;
101
+ top: 0;
102
+ right: 0;
103
+ bottom: 0;
104
+ left: 0;
105
+ border-radius: 50%;
106
+ border: 4px solid rgba(var(--hy-theme));
107
+ opacity: 0;
108
+ -webkit-animation: ripple 4.5s ease-out 1.8s infinite;
109
+ animation: ripple 4.5s ease-out 1.8s infinite;
110
+ }
111
+ }
112
+ }
113
+
114
+ .operator-box {
115
+ width: 100%;
116
+ height: 54px;
117
+ display: flex;
118
+ align-items: center;
119
+ justify-content: space-between;
120
+ column-gap: 20px;
121
+ position: relative;
122
+ padding: 0 12px 0;
123
+ color: rgba(var(--hy-main));
124
+ background: #040814;
125
+
126
+ .progress-operator {
127
+ display: flex;
128
+
129
+ input[type='range'] {
130
+ width: 100%;
131
+ height: 4px;
132
+ outline: none;
133
+ border-radius: 20px;
134
+ -webkit-appearance: none; /*清除系统默认样式*/
135
+ background-color: #eaf5f9;
136
+ }
137
+
138
+ input[type='range']::-webkit-slider-thumb {
139
+ -webkit-appearance: none; /*清除系统默认样式*/
140
+ width: 6px;
141
+ height: 6px;
142
+ border-radius: 20px;
143
+ background: rgba(var(--hy-main));
144
+ box-shadow: 0px 0px 6px 3px rgba(var(--hy-theme));
145
+ cursor: pointer;
146
+ }
147
+
148
+ input[type='range']::-ms-fill-lower {
149
+ -webkit-appearance: none;
150
+ }
151
+
152
+ &.progress-analyse {
153
+ width: 100%;
154
+ height: 6px;
155
+ position: absolute;
156
+ left: 0px;
157
+ top: 13px;
158
+ padding: 0 12px;
159
+ }
160
+ &:not(.progress-analyse) {
161
+ width: 0;
162
+ flex: 1;
163
+ flex-direction: column;
164
+ row-gap: 6px;
165
+
166
+ input[type='range'] {
167
+ height: 6px;
168
+ }
169
+
170
+ input[type='range']::-webkit-slider-thumb {
171
+ width: 14px;
172
+ height: 14px;
173
+ }
174
+ }
175
+ }
176
+
177
+ .duration-operator {
178
+ display: flex;
179
+ align-items: center;
180
+ column-gap: 4px;
181
+ font-size: 12px;
182
+ color: rgba(var(--hy-auxiliary));
183
+ white-space: nowrap;
184
+ }
185
+
186
+ .play-operator {
187
+ display: flex;
188
+ align-items: center;
189
+ column-gap: 10px;
190
+ & > div {
191
+ display: flex;
192
+ align-items: center;
193
+ justify-content: center;
194
+ cursor: pointer;
195
+ }
196
+ .app-icon {
197
+ width: 26px;
198
+ height: 26px;
199
+ }
200
+ &.play-analyse {
201
+ position: absolute;
202
+ top: calc(50% + 8px);
203
+ left: 50%;
204
+ transform: translate(-50%, -50%);
205
+ .app-icon {
206
+ &.last-icon,
207
+ &.next-icon {
208
+ width: 22px;
209
+ height: 22px;
210
+ }
211
+ }
212
+ }
213
+ }
214
+
215
+ .tools-operator {
216
+ display: flex;
217
+ align-items: center;
218
+ justify-content: flex-end;
219
+ column-gap: 10px;
220
+ .speed-box {
221
+ min-width: 60px;
222
+ height: 24px;
223
+ font-size: 12px;
224
+ color: rgba(var(--hy-auxiliary));
225
+ display: flex;
226
+ align-items: center;
227
+ justify-content: center;
228
+ cursor: pointer;
229
+ user-select: none;
230
+ padding: 0 6px;
231
+ border: 1px solid rgba(var(--hy-border));
232
+ border-radius: 4px;
233
+ background-color: rgba(var(--hy-background-2));
234
+ }
235
+ .app-icon {
236
+ width: 26px;
237
+ height: 26px;
238
+ cursor: pointer;
239
+ }
240
+ &.tools-analyse {
241
+ .speed-box {
242
+ height: 20px;
243
+ }
244
+ .app-icon {
245
+ width: 20px;
246
+ height: 20px;
247
+ }
248
+ }
249
+ }
250
+
251
+ &.operator-analyse {
252
+ padding-top: 20px;
253
+ }
254
+ }
255
+
256
+ &.audio-player-analyse {
257
+ height: 56px;
258
+ }
259
+ }
260
+
261
+ .popover-volume-slider {
262
+ min-width: auto !important;
263
+ width: 40px !important;
264
+ padding: 16px 0;
265
+ }
266
+
267
+ .popover-speed {
268
+ min-width: auto !important;
269
+ width: 62px !important;
270
+ padding: 0px !important;
271
+ .speed-list {
272
+ width: 100%;
273
+ color: rgba(var(--hy-auxiliary));
274
+ font-size: 12px;
275
+ li {
276
+ transition: 0.5s;
277
+ height: 26px;
278
+ line-height: 26px;
279
+ text-align: center;
280
+ &:after {
281
+ transition: 0s;
282
+ }
283
+ &:hover,
284
+ &.selectBox {
285
+ color: rgba(var(--hy-theme));
286
+ background: rgba(var(--hy-background-3));
287
+ }
288
+ }
289
+ }
290
+ }
291
+
292
+ @-webkit-keyframes ripple {
293
+ 0% {
294
+ opacity: 0;
295
+ -webkit-transform: scale(0.1);
296
+ }
297
+ 5% {
298
+ opacity: 1;
299
+ }
300
+ to {
301
+ opacity: 0;
302
+ -webkit-transform: scale(1);
303
+ }
304
+ }
305
+ @keyframes ripple {
306
+ 0% {
307
+ opacity: 0;
308
+ -webkit-transform: scale(0.1);
309
+ transform: scale(0.1);
310
+ }
311
+ 5% {
312
+ opacity: 1;
313
+ }
314
+ to {
315
+ opacity: 0;
316
+ -webkit-transform: scale(1);
317
+ transform: scale(1);
318
+ }
319
+ }
@@ -7,7 +7,6 @@
7
7
  margin: 0;
8
8
  font: inherit;
9
9
  color: inherit;
10
- box-sizing: border-box;
11
10
  white-space: nowrap;
12
11
  font-size: 14px;
13
12
 
@@ -45,6 +45,11 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
45
45
  required: false,
46
46
  default: () => /* @__PURE__ */ new Map()
47
47
  },
48
+ permissionMap: {
49
+ type: Map,
50
+ required: false,
51
+ default: () => /* @__PURE__ */ new Map()
52
+ },
48
53
  size: {
49
54
  type: String,
50
55
  required: false,
@@ -81,13 +86,29 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
81
86
  table: {
82
87
  type: Object,
83
88
  required: false
89
+ },
90
+ audioPlayer: {
91
+ type: Object,
92
+ required: false
93
+ },
94
+ videoPlayer: {
95
+ type: Object,
96
+ required: false
84
97
  }
85
98
  },
86
99
  setup(__props) {
87
100
  const props = __props;
88
101
  const globalConfig = useGlobalConfig.provideGlobalConfig(props, null, !vue.unref(useGlobalConfig.useGlobalConfig()));
89
102
  const config = vue.computed(() => {
90
- const { locale, api, userAvatarMap, ...config2 } = globalConfig.value;
103
+ const {
104
+ locale,
105
+ api,
106
+ userAvatarMap,
107
+ permissionMap,
108
+ audioPlayer,
109
+ videoPlayer,
110
+ ...config2
111
+ } = globalConfig.value;
91
112
  return {
92
113
  locale: ElementLocale__namespace[locale] || ElementLocale__namespace["zhCn"],
93
114
  ...config2