@webitel/ui-sdk 25.12.27 → 25.12.29

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 (74) hide show
  1. package/dist/{install-A9G4M7-6.js → install-BlgO8vvA.js} +70931 -66811
  2. package/dist/{plyr-dI1qsIWm.js → plyr-DJyswX07.js} +1 -1
  3. package/dist/ui-sdk.css +1 -1
  4. package/dist/ui-sdk.js +1 -1
  5. package/dist/ui-sdk.umd.cjs +264 -265
  6. package/dist/{vidstack-Bq6c3Bam-Bpshd13A.js → vidstack-Bq6c3Bam-DjwO73JH.js} +2 -2
  7. package/dist/{vidstack-D2pY00kU-DknwOKzI.js → vidstack-D2pY00kU-9GfP8TVc.js} +2 -2
  8. package/dist/{vidstack-DDXt6fpN-2JcEs0WE.js → vidstack-DDXt6fpN-DS4AECfL.js} +1 -1
  9. package/dist/{vidstack-D_-9AA6_-ltFyEXo5.js → vidstack-D_-9AA6_-bomzWQ4f.js} +1 -1
  10. package/dist/{vidstack-DqAw8m9J-CL4FNO5F.js → vidstack-DqAw8m9J-CDpaNq7k.js} +1 -1
  11. package/dist/{vidstack-audio-CnLJOsQb.js → vidstack-audio-kqV18cx_.js} +2 -2
  12. package/dist/{vidstack-dash-DE9OxUbu.js → vidstack-dash-CQ4hwM3M.js} +3 -3
  13. package/dist/{vidstack-google-cast-DUF-rvcM.js → vidstack-google-cast-DTdO4f40.js} +3 -3
  14. package/dist/{vidstack-hls-B5QgAztZ.js → vidstack-hls-f3oAxxux.js} +3 -3
  15. package/dist/{vidstack-video-DK5nUu2T.js → vidstack-video-D0EY01uq.js} +2 -2
  16. package/dist/{vidstack-vimeo-BPIRVQ20.js → vidstack-vimeo-X0J_rLd3.js} +3 -3
  17. package/dist/{vidstack-youtube-BBGQ_xiA.js → vidstack-youtube-Crx9X7UA.js} +2 -2
  18. package/dist/{vuex.esm-bundler-07IDl-KX.js → vuex.esm-bundler-hTIuzsPk.js} +1 -1
  19. package/package.json +3 -2
  20. package/src/components/wt-app-header/wt-header-actions.vue +4 -1
  21. package/src/components/wt-vidstack-player/components/{panels/media-control-panel/components/buttons → buttons}/fullscreen-button.vue +1 -1
  22. package/src/components/wt-vidstack-player/components/{panels/media-control-panel/media-control-panel.vue → controls-group/controls-group.vue} +15 -12
  23. package/src/components/wt-vidstack-player/components/index.ts +6 -0
  24. package/src/components/wt-vidstack-player/components/layouts/video-layout.vue +11 -36
  25. package/src/components/wt-vidstack-player/components/panels/media-controls-panel/components/buttons/fullscreen-button.vue +40 -0
  26. package/src/components/wt-vidstack-player/components/panels/media-controls-panel/components/buttons/play-button.vue +42 -0
  27. package/src/components/wt-vidstack-player/components/panels/{media-control-panel → media-controls-panel}/components/sliders/time-slider.vue +1 -1
  28. package/src/components/wt-vidstack-player/components/panels/media-controls-panel/media-controls-panel.vue +20 -0
  29. package/src/components/wt-vidstack-player/components/panels/screen-sharing-controls-panel/screen-sharing-controls-panel.vue +89 -0
  30. package/src/components/wt-vidstack-player/components/panels/video-call-controls-panel/video-call-controls-panel.vue +134 -0
  31. package/src/components/wt-vidstack-player/components/panels/video-display-panel/video-display-panel.vue +1 -1
  32. package/src/components/wt-vidstack-player/components/recording-indicator/recording-indicator.vue +64 -0
  33. package/src/components/wt-vidstack-player/wt-vidstack-player.vue +23 -40
  34. package/src/enums/FormatDateMode/FormatDateMode.ts +6 -0
  35. package/src/enums/index.ts +2 -0
  36. package/src/modules/AuditForm/components/form-answers/answer-editing-info/audit-form-answer-editing-info.vue +3 -1
  37. package/src/modules/CallSession/index.ts +4 -0
  38. package/src/modules/CallSession/modules/ScreenSharing/screen-sharing.vue +85 -0
  39. package/src/modules/CallSession/modules/VideoCall/video-call.vue +165 -0
  40. package/src/modules/CallSession/types/ScreenSharingSession.ts +7 -0
  41. package/src/modules/CallSession/types/index.ts +4 -0
  42. package/src/plugins/primevue/theme/extend/player/player.js +2 -3
  43. package/src/scripts/prettifyTime.js +5 -1
  44. package/src/utils/formatDate.ts +48 -0
  45. package/src/utils/index.ts +1 -0
  46. package/types/components/wt-datepicker/wt-datepicker.vue.d.ts +2 -2
  47. package/types/components/wt-vidstack-player/components/controls-group/controls-group.vue.d.ts +12 -0
  48. package/types/components/wt-vidstack-player/components/index.d.ts +6 -0
  49. package/types/components/wt-vidstack-player/components/layouts/video-layout.vue.d.ts +17 -11
  50. package/types/components/wt-vidstack-player/components/panels/media-controls-panel/components/buttons/fullscreen-button.vue.d.ts +6 -0
  51. package/types/components/wt-vidstack-player/components/panels/media-controls-panel/media-controls-panel.vue.d.ts +2 -0
  52. package/types/components/wt-vidstack-player/components/panels/{screen-sharing-control-panel/screen-sharing-control-panel.vue.d.ts → screen-sharing-controls-panel/screen-sharing-controls-panel.vue.d.ts} +2 -3
  53. package/types/components/wt-vidstack-player/components/panels/video-call-controls-panel/video-call-controls-panel.vue.d.ts +18 -0
  54. package/types/components/wt-vidstack-player/components/recording-indicator/recording-indicator.vue.d.ts +2 -0
  55. package/types/components/wt-vidstack-player/wt-vidstack-player.vue.d.ts +19 -15
  56. package/types/enums/FormatDateMode/FormatDateMode.d.ts +6 -0
  57. package/types/enums/index.d.ts +2 -1
  58. package/types/modules/CallSession/index.d.ts +3 -0
  59. package/types/modules/CallSession/modules/ScreenSharing/screen-sharing.vue.d.ts +16 -0
  60. package/types/modules/CallSession/modules/VideoCall/video-call.vue.d.ts +20 -0
  61. package/types/modules/CallSession/types/ScreenSharingSession.d.ts +7 -0
  62. package/types/modules/CallSession/types/index.d.ts +3 -0
  63. package/types/utils/formatDate.d.ts +2 -0
  64. package/types/utils/index.d.ts +1 -0
  65. package/src/components/wt-vidstack-player/components/panels/screen-sharing-control-panel/screen-sharing-control-panel.vue +0 -195
  66. /package/src/components/wt-vidstack-player/components/{panels/media-control-panel/components/buttons → buttons}/play-button.vue +0 -0
  67. /package/src/components/wt-vidstack-player/components/panels/{media-control-panel → media-controls-panel}/components/time-group.vue +0 -0
  68. /package/src/{components/wt-vidstack-player → modules/CallSession}/types/ScreenshotStatus.ts +0 -0
  69. /package/types/components/wt-vidstack-player/components/{panels/media-control-panel/components/buttons → buttons}/fullscreen-button.vue.d.ts +0 -0
  70. /package/types/components/wt-vidstack-player/components/{panels/media-control-panel/components/buttons → buttons}/play-button.vue.d.ts +0 -0
  71. /package/types/components/wt-vidstack-player/components/panels/{media-control-panel/components/sliders/time-slider.vue.d.ts → media-controls-panel/components/buttons/play-button.vue.d.ts} +0 -0
  72. /package/types/components/wt-vidstack-player/components/panels/{media-control-panel/components/time-group.vue.d.ts → media-controls-panel/components/sliders/time-slider.vue.d.ts} +0 -0
  73. /package/types/components/wt-vidstack-player/components/panels/{media-control-panel/media-control-panel.vue.d.ts → media-controls-panel/components/time-group.vue.d.ts} +0 -0
  74. /package/types/{components/wt-vidstack-player → modules/CallSession}/types/ScreenshotStatus.d.ts +0 -0
@@ -1,9 +1,13 @@
1
+ import { FormatDateMode } from '../enums';
2
+ import { formatDate } from '../utils';
3
+
1
4
  const prettifyTime = (time) => {
2
5
  let date;
3
6
  if (time instanceof Date) date = time;
4
7
  else if (typeof time === 'number') date = new Date(time);
5
8
  else date = new Date(+time);
6
- return date.toLocaleTimeString([], { hour: '2-digit', minute: '2-digit' });
9
+
10
+ return formatDate(date, FormatDateMode.TIME);
7
11
  };
8
12
 
9
13
  export default prettifyTime;
@@ -0,0 +1,48 @@
1
+ import type { Locale } from 'date-fns/locale';
2
+ import { enUS, es, kk, pl, ro, ru, uk, uz, vi } from 'date-fns/locale';
3
+ import { formatInTimeZone } from 'date-fns-tz';
4
+
5
+ import { FormatDateMode } from '../enums';
6
+ import { TIMEZONE_STORAGE_KEY } from '../modules/Userinfo/v2/constants/UserSettingsConstants';
7
+
8
+ const localeMap: Record<string, Locale> = {
9
+ en: enUS,
10
+ ru: ru,
11
+ uk: uk,
12
+ es: es,
13
+ kz: kk,
14
+ pl: pl,
15
+ ro: ro,
16
+ uz: uz,
17
+ vi: vi,
18
+ };
19
+
20
+ function getUserTimeZone(): string {
21
+ return (
22
+ localStorage.getItem(TIMEZONE_STORAGE_KEY) ||
23
+ Intl.DateTimeFormat().resolvedOptions().timeZone
24
+ );
25
+ }
26
+
27
+ function getUserLocale(): Locale {
28
+ const lang = localStorage.getItem('lang') || 'en';
29
+ return localeMap[lang] || enUS;
30
+ }
31
+
32
+ export function formatDate(
33
+ date: string | number | Date,
34
+ to: typeof FormatDateMode[keyof typeof FormatDateMode],
35
+ ): string {
36
+ const timeZone = getUserTimeZone();
37
+ const locale = getUserLocale();
38
+
39
+ // https://date-fns.org/v4.1.0/docs/format
40
+ const formatStaringMap = {
41
+ date: 'P', //MM/DD/YYYY 11/13/2025 | DD.MM.YYYY 13.11.2025
42
+ time: 'p', // 3:53 PM | 15:53
43
+ datetime: 'Ppp', // 11/13/2025, 3:53:00 PM | 13.11.2025, 15:53:00
44
+ datetimeShort: 'Pp', // 11/13/2025, 3:53 PM | 13.11.2025, 15:53
45
+ };
46
+
47
+ return formatInTimeZone(date, timeZone, formatStaringMap[to], { locale });
48
+ }
@@ -1 +1,2 @@
1
1
  export * from './displayText';
2
+ export * from './formatDate';
@@ -9,9 +9,9 @@ declare const __VLS_component: import("vue").DefineComponent<{}, {
9
9
  value: string | number;
10
10
  required: boolean;
11
11
  label: string;
12
+ lang: string;
12
13
  placeholder: string;
13
14
  mode: string;
14
- lang: string;
15
15
  clearable: boolean;
16
16
  v?: Record<string, any>;
17
17
  disabledDates?: Record<string, any>;
@@ -21,9 +21,9 @@ declare const __VLS_component: import("vue").DefineComponent<{}, {
21
21
  readonly value?: string | number;
22
22
  readonly required?: boolean;
23
23
  readonly label?: string;
24
+ readonly lang?: string;
24
25
  readonly placeholder?: string;
25
26
  readonly mode?: string;
26
- readonly lang?: string;
27
27
  readonly clearable?: boolean;
28
28
  readonly v?: Record<string, any>;
29
29
  readonly disabledDates?: Record<string, any>;
@@ -0,0 +1,12 @@
1
+ declare var __VLS_6: {};
2
+ type __VLS_Slots = {} & {
3
+ default?: (props: typeof __VLS_6) => any;
4
+ };
5
+ declare const __VLS_component: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
6
+ declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
7
+ export default _default;
8
+ type __VLS_WithSlots<T, S> = T & {
9
+ new (): {
10
+ $slots: S;
11
+ };
12
+ };
@@ -0,0 +1,6 @@
1
+ export { default as ControlsGroup } from './controls-group/controls-group.vue';
2
+ export { default as VideoLayout } from './layouts/video-layout.vue';
3
+ export { default as MediaControlsPanel } from './panels/media-controls-panel/media-controls-panel.vue';
4
+ export { default as ScreenSharingControlsPanel } from './panels/screen-sharing-controls-panel/screen-sharing-controls-panel.vue';
5
+ export { default as VideoCallControlsPanel } from './panels/video-call-controls-panel/video-call-controls-panel.vue';
6
+ export { default as RecordingIndicator } from './recording-indicator/recording-indicator.vue';
@@ -1,24 +1,30 @@
1
- import { ScreenshotStatus } from "../../types/ScreenshotStatus";
2
- import { WtVidstakPlayerControlsMode } from "../../types/WtVidstackPlayerControlsMode";
3
- import { WtVidstackPlayerSession } from "../../types/WtVidstackPlayerSession";
4
1
  type __VLS_Props = {
5
2
  title?: string;
6
3
  username?: string;
7
4
  closable?: boolean;
8
- mode: WtVidstakPlayerControlsMode;
9
- session: WtVidstackPlayerSession;
10
- screenshotStatus: ScreenshotStatus;
11
- screenshotIsLoading: boolean;
5
+ hideDisplayPanel?: boolean;
12
6
  };
13
- declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
7
+ declare var __VLS_16: {}, __VLS_18: {};
8
+ type __VLS_Slots = {} & {
9
+ content?: (props: typeof __VLS_16) => any;
10
+ } & {
11
+ 'controls-panel'?: (props: typeof __VLS_18) => any;
12
+ };
13
+ declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
14
+ "close-player": () => any;
14
15
  "close-session": () => any;
15
16
  "make-screenshot": () => any;
16
17
  "toggle-record": () => any;
17
- "close-player": () => any;
18
18
  }, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
19
+ "onClose-player"?: () => any;
19
20
  "onClose-session"?: () => any;
20
21
  "onMake-screenshot"?: () => any;
21
22
  "onToggle-record"?: () => any;
22
- "onClose-player"?: () => any;
23
- }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
23
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
24
+ declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
24
25
  export default _default;
26
+ type __VLS_WithSlots<T, S> = T & {
27
+ new (): {
28
+ $slots: S;
29
+ };
30
+ };
@@ -0,0 +1,6 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
2
+ toggle: (value: boolean) => any;
3
+ }, string, import("vue").PublicProps, Readonly<{}> & Readonly<{
4
+ onToggle?: (value: boolean) => any;
5
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
6
+ export default _default;
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ export default _default;
@@ -1,7 +1,6 @@
1
- import { ScreenshotStatus } from "../../../types/ScreenshotStatus";
2
- import { WtVidstackPlayerSession } from "../../../types/WtVidstackPlayerSession";
1
+ import { ScreenSharingSession, ScreenshotStatus } from "../../../types";
3
2
  interface Props {
4
- session: WtVidstackPlayerSession;
3
+ session: ScreenSharingSession;
5
4
  screenshotStatus: ScreenshotStatus | null;
6
5
  screenshotIsLoading: boolean;
7
6
  }
@@ -0,0 +1,18 @@
1
+ import { ScreenshotStatus } from '../../../../../modules/CallSession/types';
2
+ interface Props {
3
+ recordings: boolean;
4
+ isMicMuted: boolean;
5
+ isVideoMuted: boolean;
6
+ isCallStarted: boolean;
7
+ screenshotIsLoading: boolean;
8
+ screenshotStatus: ScreenshotStatus | null;
9
+ screenshotCallback?: () => void;
10
+ recordingsCallback?: () => void;
11
+ micCallback?: () => void;
12
+ videoCallback?: () => void;
13
+ settingsCallback?: () => void;
14
+ chatCallback?: () => void;
15
+ callStateCallback?: () => void;
16
+ }
17
+ declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
18
+ export default _default;
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ export default _default;
@@ -1,8 +1,5 @@
1
1
  import 'vidstack/player';
2
2
  import 'vidstack/player/ui';
3
- import { ScreenshotStatus } from "./types/ScreenshotStatus";
4
- import { WtVidstakPlayerControlsMode } from "./types/WtVidstackPlayerControlsMode";
5
- import { WtVidstackPlayerSession } from "./types/WtVidstackPlayerSession";
6
3
  interface Props {
7
4
  src: string | {
8
5
  src: string;
@@ -14,29 +11,36 @@ interface Props {
14
11
  title?: string;
15
12
  username?: string;
16
13
  closable?: boolean;
14
+ resizable?: boolean;
17
15
  stream?: MediaStream;
18
- mode: WtVidstakPlayerControlsMode;
19
- session?: WtVidstackPlayerSession;
20
- screenshotStatus: ScreenshotStatus;
21
- screenshotIsLoading: boolean;
22
16
  }
23
- declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
17
+ declare var __VLS_24: {
18
+ size: "sm";
19
+ }, __VLS_26: {
20
+ size: "sm";
21
+ };
22
+ type __VLS_Slots = {} & {
23
+ 'controls-panel'?: (props: typeof __VLS_24) => any;
24
+ } & {
25
+ content?: (props: typeof __VLS_26) => any;
26
+ };
27
+ declare const __VLS_component: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
24
28
  close: () => any;
25
- "close-session": () => any;
26
- "make-screenshot": () => any;
27
- "toggle-record": () => any;
28
29
  }, string, import("vue").PublicProps, Readonly<Props> & Readonly<{
29
30
  onClose?: () => any;
30
- "onClose-session"?: () => any;
31
- "onMake-screenshot"?: () => any;
32
- "onToggle-record"?: () => any;
33
31
  }>, {
34
32
  title: string;
35
- mode: WtVidstakPlayerControlsMode;
36
33
  username: string;
37
34
  autoplay: boolean;
38
35
  mime: string;
39
36
  closable: boolean;
40
37
  muted: boolean;
38
+ resizable: boolean;
41
39
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
40
+ declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
42
41
  export default _default;
42
+ type __VLS_WithSlots<T, S> = T & {
43
+ new (): {
44
+ $slots: S;
45
+ };
46
+ };
@@ -0,0 +1,6 @@
1
+ export declare const FormatDateMode: {
2
+ readonly DATE: "date";
3
+ readonly TIME: "time";
4
+ readonly DATETIME: "datetime";
5
+ readonly DATETIME_SHORT: "datetimeShort";
6
+ };
@@ -8,6 +8,7 @@ import { ChipColor } from './ChipColor/ChipColor';
8
8
  import { ComponentSize } from './ComponentSize/ComponentSize';
9
9
  import { CrudAction } from './CrudAction/CrudAction';
10
10
  import { EmptyCause } from './EmptyCause/EmptyCause';
11
+ import { FormatDateMode } from './FormatDateMode/FormatDateMode';
11
12
  import IconAction from './IconAction/IconAction.enum.js';
12
13
  import { IconColor } from './IconColor/IconColor';
13
14
  import { ProcessingTableColumnType } from './ProcessingTableColumnType/ProcessingTableColumnType';
@@ -23,4 +24,4 @@ import { WfmSections } from './WebitelApplications/WfmSections';
23
24
  import { WtApplication } from './WebitelApplications/WtApplication';
24
25
  import { WtObject } from './WtObject/WtObject';
25
26
  import { WtTypeExtensionFieldKind } from './WtTypeExtensionFieldKind/WtTypeExtensionFieldKind';
26
- export { AbstractUserStatus, AdminSections, AgentStatus, AuditorSections, ButtonColor, ButtonVariant, ChatGatewayProvider, ChipColor, ComponentSize, CrmSections, CrudAction, EmptyCause, IconAction, IconColor, ProcessingTableColumnType, ProviderIconType, QueueType, QueueTypeName, RelativeDatetimeValue, SupervisorSections, TypesExportedSettings, WebitelApplications, WfmSections, WtApplication, WtObject, WtTypeExtensionFieldKind, };
27
+ export { AbstractUserStatus, AdminSections, AgentStatus, AuditorSections, ButtonColor, ButtonVariant, ChatGatewayProvider, ChipColor, ComponentSize, CrmSections, CrudAction, EmptyCause, FormatDateMode, IconAction, IconColor, ProcessingTableColumnType, ProviderIconType, QueueType, QueueTypeName, RelativeDatetimeValue, SupervisorSections, TypesExportedSettings, WebitelApplications, WfmSections, WtApplication, WtObject, WtTypeExtensionFieldKind, };
@@ -0,0 +1,3 @@
1
+ import ScreenSharing from './modules/ScreenSharing/screen-sharing.vue';
2
+ import VideoCall from './modules/VideoCall/video-call.vue';
3
+ export { ScreenSharing, VideoCall };
@@ -0,0 +1,16 @@
1
+ import { ScreenSharingSession, ScreenshotStatus } from '../../types';
2
+ interface Props {
3
+ session: ScreenSharingSession;
4
+ screenshotStatus: ScreenshotStatus | null;
5
+ screenshotIsLoading: boolean;
6
+ }
7
+ declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
8
+ "close-session": () => any;
9
+ "make-screenshot": () => any;
10
+ "toggle-record": () => any;
11
+ }, string, import("vue").PublicProps, Readonly<Props> & Readonly<{
12
+ "onClose-session"?: () => any;
13
+ "onMake-screenshot"?: () => any;
14
+ "onToggle-record"?: () => any;
15
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
16
+ export default _default;
@@ -0,0 +1,20 @@
1
+ import { ScreenshotStatus } from '../../types';
2
+ interface Props {
3
+ sender: MediaStream;
4
+ receiver: MediaStream;
5
+ isMicMuted: boolean;
6
+ isVideoMuted: boolean;
7
+ isCallStarted: boolean;
8
+ recordings: boolean;
9
+ screenshotStatus: ScreenshotStatus | null;
10
+ screenshotIsLoading: boolean;
11
+ screenshotCallback?: () => void;
12
+ recordingsCallback?: () => void;
13
+ micCallback?: () => void;
14
+ videoCallback?: () => void;
15
+ settingsCallback?: () => void;
16
+ chatCallback?: () => void;
17
+ callStateCallback?: () => void;
18
+ }
19
+ declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
20
+ export default _default;
@@ -0,0 +1,7 @@
1
+ export interface ScreenSharingSession {
2
+ close: () => void;
3
+ screenshot: () => void;
4
+ stopRecord: () => void;
5
+ startRecord: () => void;
6
+ recordings: boolean;
7
+ }
@@ -0,0 +1,3 @@
1
+ import { ScreenSharingSession } from './ScreenSharingSession';
2
+ import { ScreenshotStatus } from './ScreenshotStatus';
3
+ export { ScreenSharingSession, ScreenshotStatus };
@@ -0,0 +1,2 @@
1
+ import { FormatDateMode } from '../enums';
2
+ export declare function formatDate(date: string | number | Date, to: typeof FormatDateMode[keyof typeof FormatDateMode]): string;
@@ -1 +1,2 @@
1
1
  export * from './displayText';
2
+ export * from './formatDate';
@@ -1,195 +0,0 @@
1
- <template>
2
- <media-controls-group
3
- class="screen-sharing-control-panel controls-group"
4
- :class="`screen-sharing-control-panel--${size}`"
5
- >
6
- <div
7
- class="screen-sharing-control-panel__actions"
8
- >
9
- <wt-button
10
- rounded
11
- contains-icon
12
- variant="outlined"
13
- color="secondary"
14
- :loading="props.screenshotIsLoading"
15
- :size="size"
16
- :icon="screenShotIcon"
17
- @click="makeScreenshot"
18
- />
19
-
20
- <wt-button
21
- rounded
22
- contains-icon
23
- variant="outlined"
24
- color="secondary"
25
- :size="size"
26
- :icon="recordIcon"
27
- @click="emit('toggle-record')"
28
- />
29
-
30
- <wt-button
31
- icon="sharing-end"
32
- class="screen-sharing-control-panel__sharing-end"
33
- color="error"
34
- variant="outlined"
35
- :size="size"
36
- rounded
37
- contains-icon
38
- @click="closeSession"
39
- />
40
- </div>
41
-
42
- <div
43
- v-if="isRecording" class="screen-sharing-control-panel__indicator"
44
- >
45
- <wt-indicator
46
- color="error"
47
- size="md"
48
- />
49
-
50
- <span class="screen-sharing-control-panel__time">{{ convertDuration(secondsElapsed) }}</span>
51
- </div>
52
- </media-controls-group>
53
- </template>
54
-
55
- <script setup lang="ts">
56
- import convertDuration from '@webitel/ui-sdk/src/scripts/convertDuration';
57
- import {computed, defineEmits, inject, onUnmounted, ref, watch} from 'vue';
58
-
59
- import {ScreenshotStatus} from "../../../types/ScreenshotStatus";
60
- import {WtVidstackPlayerSession} from "../../../types/WtVidstackPlayerSession";
61
-
62
- interface Props {
63
- session: WtVidstackPlayerSession
64
- screenshotStatus: ScreenshotStatus | null
65
- screenshotIsLoading: boolean
66
- }
67
-
68
- const props = defineProps<Props>();
69
-
70
- const emit = defineEmits<{
71
- 'close-session': [],
72
- 'make-screenshot': [],
73
- 'toggle-record': [],
74
- }>()
75
-
76
- const {size} = inject('size');
77
-
78
- const recordIcon = computed(() => (props.session.recordings ? 'record-stop' : 'record-start'));
79
-
80
- const screenShotIcon = computed(() => {
81
- switch (props.screenshotStatus) {
82
- case 'done':
83
- return 'screenshot-done';
84
- case 'error':
85
- return 'screenshot-false';
86
- default:
87
- return 'screenshot';
88
- }
89
- });
90
- const isRecording = computed(() => props.session.recordings);
91
-
92
- const secondsElapsed = ref(0);
93
- const timerId = ref<number | null>(null);
94
-
95
- function startTimer() {
96
- secondsElapsed.value = 0;
97
- stopTimer();
98
- timerId.value = window.setInterval(() => {
99
- secondsElapsed.value++;
100
- }, 1000);
101
- }
102
-
103
- function stopTimer() {
104
- if (timerId.value !== null) {
105
- clearInterval(timerId.value);
106
- timerId.value = null;
107
- }
108
- }
109
-
110
- const closeSession = () => {
111
- emit('close-session')
112
- };
113
-
114
- const makeScreenshot = () => {
115
- emit('make-screenshot')
116
- };
117
-
118
- onUnmounted(() => {
119
- stopTimer();
120
- });
121
-
122
- watch(isRecording, (newVal) => {
123
- if (newVal) {
124
- startTimer();
125
- } else {
126
- stopTimer();
127
- }
128
- });
129
- </script>
130
-
131
- <style scoped lang="scss">
132
- @use '@webitel/styleguide/typography' as *;
133
-
134
- .screen-sharing-control-panel {
135
- position: relative;
136
- display: flex;
137
- justify-content: center;
138
-
139
- &--sm {
140
- .screen-sharing-control-panel__actions {
141
- width: 100%;
142
- border-top-left-radius: 0 !important;
143
- border-top-right-radius: 0 !important;
144
- }
145
-
146
- .screen-sharing-control-panel__indicator {
147
- right: var(--p-player-counter-position-padding-sm);
148
- bottom: calc(100% + var(--p-player-counter-position-padding-sm));
149
- }
150
- }
151
-
152
- &--md {
153
- .screen-sharing-control-panel__indicator {
154
- right: var(--p-player-counter-position-padding-md);
155
- bottom: var(--p-player-counter-position-padding-md);
156
- }
157
- }
158
-
159
- &--lg {
160
- .screen-sharing-control-panel__indicator {
161
- right: var(--p-player-counter-position-padding-lg);
162
- bottom: var(--p-player-counter-position-padding-lg);
163
- }
164
- }
165
-
166
- &__actions {
167
- display: flex;
168
- align-items: center;
169
- justify-content: center;
170
- background: var(--p-player-control-bar-background);
171
- box-shadow: var(--elevation-10);
172
- }
173
-
174
- &__indicator {
175
- background: var(--content-wrapper-color);
176
- display: flex;
177
- align-items: center;
178
- justify-content: flex-start;
179
- gap: var(--p-player-counter-gap);
180
- padding: var(--p-player-counter-padding);
181
- border-radius: var(--p-player-counter-border-radius);
182
- box-shadow: var(--elevation-10);
183
- position: absolute;
184
-
185
- // Agreed with @Evgeniy Trahtenberg
186
- width: 100px;
187
- }
188
-
189
- &__time {
190
- @extend %typo-body-1;
191
- }
192
- }
193
- </style>
194
-
195
-