@webitel/ui-sdk 25.10.12 → 25.10.14

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webitel/ui-sdk",
3
- "version": "25.10.12",
3
+ "version": "25.10.14",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "make-all": "npm version patch --git-tag-version false && npm run build && (npm run build:types || true) && (npm run lint:fix || true) && npm run publish-lib",
@@ -56,8 +56,20 @@
56
56
  :hidden="isColumnHidden(col)"
57
57
  >
58
58
  <template #header>
59
- <div style="width: 0;" class="wt-table__th__content">
59
+ <div class="wt-table__th__content">
60
60
  {{ col.text }}
61
+ <wt-icon
62
+ v-if="col.sort === 'asc'"
63
+ class="wt-table__th__sort-arrow wt-table__th__sort-arrow--asc"
64
+ icon="sort-arrow-up"
65
+ size="sm"
66
+ />
67
+ <wt-icon
68
+ v-else-if="col.sort === 'desc'"
69
+ class="wt-table__th__sort-arrow wt-table__th__sort-arrow--desc"
70
+ icon="sort-arrow-down"
71
+ size="sm"
72
+ />
61
73
  </div>
62
74
  </template>
63
75
 
@@ -80,19 +92,8 @@
80
92
  >{{ row[col.value] }}</slot>
81
93
  </div>
82
94
  </template>
95
+ <!-- empty sorticon slot for hiding default sort icon, custom icon is rendered in header -->
83
96
  <template #sorticon>
84
- <wt-icon
85
- v-if="col.sort === 'asc'"
86
- class="wt-table__th__sort-arrow wt-table__th__sort-arrow--asc"
87
- icon="sort-arrow-up"
88
- size="sm"
89
- />
90
- <wt-icon
91
- v-else-if="col.sort === 'desc'"
92
- class="wt-table__th__sort-arrow wt-table__th__sort-arrow--desc"
93
- icon="sort-arrow-down"
94
- size="sm"
95
- />
96
97
  </template>
97
98
  <template
98
99
  v-if="isTableColumnFooters"
@@ -335,10 +336,13 @@ const handleSelection = (row, select) => {
335
336
  .wt-table__th__content {
336
337
  @extend %typo-body-1-bold;
337
338
  white-space: nowrap;
339
+ width: 0;
338
340
  }
339
341
 
340
342
  .wt-table__td__content {
341
343
  @extend %typo-body-1;
344
+ display: flex;
345
+ align-items: center;
342
346
  }
343
347
 
344
348
  .wt-table__td__actions {
@@ -347,4 +351,10 @@ const handleSelection = (row, select) => {
347
351
  align-items: flex-start;
348
352
  gap: var(--spacing-xs);
349
353
  }
354
+
355
+ .wt-table__th__sort-arrow {
356
+ position: absolute;
357
+ transform: translateY(-50%);
358
+ top: 50%;
359
+ }
350
360
  </style>
@@ -0,0 +1,22 @@
1
+ /**
2
+ * @author @dlohvinov
3
+ *
4
+ * @description
5
+ * List of available locales
6
+ */
7
+ export const TranslationLocale = {
8
+ // supported by BA team
9
+ en: 'en',
10
+ uk: 'uk',
11
+ ru: 'ru',
12
+
13
+ // ai generated by frontend team
14
+ es: 'es',
15
+ kz: 'kz',
16
+ vi: 'vi',
17
+ pl: 'pl',
18
+ ro: 'ro',
19
+ uz: 'uz',
20
+ } as const;
21
+
22
+ export type TranslationLocale = (typeof TranslationLocale)[keyof typeof TranslationLocale];
@@ -1,3 +1,4 @@
1
+ import deepmerge from 'deepmerge';
1
2
  import {
2
3
  AgentStatus,
3
4
  CallDirection,
@@ -20,8 +21,9 @@ import {
20
21
  } from '../../enums';
21
22
  import { AccessMode } from '../../modules/ObjectPermissions/_internals/enums/AccessMode.enum.js';
22
23
  import { snakeToCamel } from '../../scripts';
24
+ import notTranslatable from './notTranslatable.en';
23
25
 
24
- export default {
26
+ export default deepmerge(notTranslatable, {
25
27
  // describes reusable buttons, actions, default titles, and other ui elements
26
28
  reusable: {
27
29
  comment: 'Comment',
@@ -52,13 +54,6 @@ export default {
52
54
  expand: 'Expand',
53
55
  collapse: 'Collapse',
54
56
  generate: 'Generate',
55
- lang: {
56
- en: 'English',
57
- es: 'Español',
58
- ru: 'Русский',
59
- uk: 'Українська',
60
- kz: 'Қазақ',
61
- },
62
57
  from: 'From',
63
58
  to: 'To',
64
59
  tts: 'Text-to-Speech',
@@ -762,4 +757,4 @@ export default {
762
757
  chatHistoryApi: 'There was an error loading the chat history',
763
758
  markChatProcessed: 'Failed to move the chat to “Closed”',
764
759
  },
765
- };
760
+ });
@@ -0,0 +1,27 @@
1
+ import { TranslationLocale } from '../_enums/TranslationLocale.enum';
2
+
3
+ /**
4
+ * @author @dlohvinov
5
+ *
6
+ * @description
7
+ * These keys should not be translated to different langs,
8
+ * but moved to separate file to avoid main lang file lines
9
+ * count increase related to other langs so that it's easier
10
+ * to compare any missing translations between langs
11
+ */
12
+
13
+ export default {
14
+ reusable: {
15
+ lang: {
16
+ [TranslationLocale.en]: 'English',
17
+ [TranslationLocale.es]: 'Español',
18
+ [TranslationLocale.ru]: 'Русский',
19
+ [TranslationLocale.uk]: 'Українська',
20
+ [TranslationLocale.kz]: 'Қазақ',
21
+ [TranslationLocale.vi]: 'Tiếng Việt',
22
+ [TranslationLocale.pl]: 'Polski',
23
+ [TranslationLocale.ro]: 'Română',
24
+ [TranslationLocale.uz]: "O'zbek",
25
+ },
26
+ },
27
+ };
@@ -51,13 +51,6 @@ export default {
51
51
  expand: 'Expandir',
52
52
  collapse: 'Colapsar',
53
53
  generate: 'Generar',
54
- lang: {
55
- en: 'Inglés',
56
- es: 'Español',
57
- ru: 'Ruso',
58
- uk: 'Ucraniano',
59
- kz: 'Kazajo',
60
- },
61
54
  from: 'Desde',
62
55
  to: 'Hasta',
63
56
  tts: 'Texto a Voz',
@@ -1,3 +1,5 @@
1
+ export * from './_enums/TranslationLocale.enum';
2
+
1
3
  import en from './en/en';
2
4
  import es from './es/es';
3
5
  import kz from './kz/kz';
@@ -52,13 +52,6 @@ export default {
52
52
  expand: 'Кеңейту',
53
53
  collapse: 'Жігу',
54
54
  generate: 'Жасау',
55
- lang: {
56
- en: 'English',
57
- es: 'Español',
58
- ru: 'Русский',
59
- uk: 'Українська',
60
- kz: 'Қазақ',
61
- },
62
55
  from: 'Бастап',
63
56
  to: 'Дейін',
64
57
  tts: 'Мәтін-дауыс',
@@ -52,13 +52,6 @@ export default {
52
52
  expand: 'Rozwiń',
53
53
  collapse: 'Zwiń',
54
54
  generate: 'Generuj',
55
- lang: {
56
- en: 'English',
57
- es: 'Español',
58
- ru: 'Русский',
59
- uk: 'Українська',
60
- kz: 'Қазақ',
61
- },
62
55
  from: 'Od',
63
56
  to: 'Do',
64
57
  tts: 'Tekst na mowę',
@@ -52,13 +52,6 @@ export default {
52
52
  expand: 'Extinde',
53
53
  collapse: 'Restrânge',
54
54
  generate: 'Generează',
55
- lang: {
56
- en: 'English',
57
- es: 'Español',
58
- ru: 'Русский',
59
- uk: 'Українська',
60
- kz: 'Қазақ',
61
- },
62
55
  from: 'De la',
63
56
  to: 'Până la',
64
57
  tts: 'Text-to-Speech',
@@ -52,13 +52,6 @@ export default {
52
52
  expand: 'Развернуть',
53
53
  collapse: 'Свернуть',
54
54
  generate: 'Сгенерировать',
55
- lang: {
56
- en: 'English',
57
- es: 'Español',
58
- ru: 'Русский',
59
- uk: 'Українська',
60
- kz: 'Қазақ',
61
- },
62
55
  from: 'От',
63
56
  to: 'До',
64
57
  tts: 'Text-to-Speech',
@@ -52,13 +52,6 @@ export default {
52
52
  expand: 'Розгорнути',
53
53
  collapse: 'Згорнути',
54
54
  generate: 'Згенерувати',
55
- lang: {
56
- en: 'English',
57
- es: 'Español',
58
- ru: 'Русский',
59
- uk: 'Українська',
60
- kz: 'Қазақ',
61
- },
62
55
  from: 'Від',
63
56
  to: 'До',
64
57
  tts: 'Text-to-Speech',
@@ -52,13 +52,6 @@ export default {
52
52
  expand: 'Kengaytirish',
53
53
  collapse: 'Yigʻish',
54
54
  generate: 'Generatsiya',
55
- lang: {
56
- en: 'English',
57
- es: 'Español',
58
- ru: 'Русский',
59
- uk: 'Українська',
60
- kz: 'Қазақ',
61
- },
62
55
  from: 'Dan',
63
56
  to: 'Gacha',
64
57
  tts: 'Matnni ovozga aylantirish',
@@ -52,13 +52,6 @@ export default {
52
52
  expand: 'Mở rộng',
53
53
  collapse: 'Thu gọn',
54
54
  generate: 'Tạo',
55
- lang: {
56
- en: 'Tiếng Anh',
57
- es: 'Tiếng Tây Ban Nha',
58
- ru: 'Tiếng Nga',
59
- uk: 'Tiếng Ukraina',
60
- kz: 'Tiếng Kazakh',
61
- },
62
55
  from: 'Từ',
63
56
  to: 'Đến',
64
57
  tts: 'Chuyển văn bản thành giọng nói',
@@ -14,6 +14,7 @@ const table = {
14
14
  .p-datatable-tbody > tr > td {
15
15
  word-break: break-all;
16
16
  overflow-wrap: break-word;
17
+ vertical-align: top;
17
18
  }
18
19
 
19
20
  .p-datatable-thead > tr > th {
@@ -62,7 +62,7 @@ declare const isColSortable: ({ sort }: {
62
62
  declare const selectAll: () => void;
63
63
  declare const handleSelection: (row: any, select: any) => void;
64
64
  declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
65
- declare var __VLS_45: string, __VLS_46: {
65
+ declare var __VLS_53: string, __VLS_54: {
66
66
  index: any;
67
67
  item: any;
68
68
  }, __VLS_57: `${string}-footer`, __VLS_58: {}, __VLS_64: {}, __VLS_66: {
@@ -70,7 +70,7 @@ declare var __VLS_45: string, __VLS_46: {
70
70
  item: any;
71
71
  }, __VLS_68: {};
72
72
  type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
73
- [K in NonNullable<typeof __VLS_45>]?: (props: typeof __VLS_46) => any;
73
+ [K in NonNullable<typeof __VLS_53>]?: (props: typeof __VLS_54) => any;
74
74
  } & {
75
75
  [K in NonNullable<typeof __VLS_57>]?: (props: typeof __VLS_58) => any;
76
76
  } & {
@@ -0,0 +1,18 @@
1
+ /**
2
+ * @author @dlohvinov
3
+ *
4
+ * @description
5
+ * List of available locales
6
+ */
7
+ export declare const TranslationLocale: {
8
+ readonly en: "en";
9
+ readonly uk: "uk";
10
+ readonly ru: "ru";
11
+ readonly es: "es";
12
+ readonly kz: "kz";
13
+ readonly vi: "vi";
14
+ readonly pl: "pl";
15
+ readonly ro: "ro";
16
+ readonly uz: "uz";
17
+ };
18
+ export type TranslationLocale = (typeof TranslationLocale)[keyof typeof TranslationLocale];