@webitel/ui-sdk 23.12.113 → 23.12.114

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": "23.12.113",
3
+ "version": "23.12.114",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "dev": "vite",
@@ -38,8 +38,8 @@
38
38
  >
39
39
  <img
40
40
  :alt="`${app.name}-pic`"
41
- class="wt-app-navigator__card__img"
42
41
  :src="app.img"
42
+ class="wt-app-navigator__card__img"
43
43
  >
44
44
  <p
45
45
  class="wt-app-navigator__card__title"
@@ -64,12 +64,12 @@ import AgentDark from './assets/agent-dark.svg';
64
64
  import AgentLight from './assets/agent-light.svg';
65
65
  import AnalyticsDark from './assets/analytics-dark.svg';
66
66
  import AnalyticsLight from './assets/analytics-light.svg';
67
+ import AuditDark from './assets/audit-dark.svg';
68
+ import AuditLight from './assets/audit-light.svg';
67
69
  import CrmDark from './assets/crm-dark.svg';
68
70
  import CrmLight from './assets/crm-light.svg';
69
71
  import HistoryDark from './assets/history-dark.svg';
70
72
  import HistoryLight from './assets/history-light.svg';
71
- import AuditDark from './assets/audit-dark.svg';
72
- import AuditLight from './assets/audit-light.svg';
73
73
  import SupervisorDark from './assets/supervisor-dark.svg';
74
74
  import SupervisorLight from './assets/supervisor-light.svg';
75
75
 
@@ -120,14 +120,24 @@ const props = defineProps({
120
120
 
121
121
  const isOpened = ref(false);
122
122
 
123
- const formattedApps = computed(() => props.apps.reduce((apps, app) => ({
123
+ const order = [
124
+ WebitelApplications.AGENT,
125
+ WebitelApplications.SUPERVISOR,
126
+ WebitelApplications.HISTORY,
127
+ WebitelApplications.ADMIN,
128
+ WebitelApplications.ANALYTICS,
129
+ WebitelApplications.AUDIT,
130
+ WebitelApplications.CRM,
131
+ ];
132
+
133
+ const formattedApps = computed(() => props.apps.reduce((apps, app) => ([
124
134
  ...apps,
125
- [app.name]: {
135
+ {
126
136
  ...app,
127
137
  img: props.darkMode ? pics[app.name].dark : pics[app.name].light,
128
138
  currentApp: props.currentApp === app.name,
129
139
  },
130
- }), {}));
140
+ ]), []).sort((a, b) => order.indexOf(a.name) - order.indexOf(b.name)));
131
141
 
132
142
  function close() {
133
143
  isOpened.value = false;
@@ -189,14 +199,14 @@ function close() {
189
199
 
190
200
  // a tag
191
201
  .wt-app-navigator__card__link {
192
- box-sizing: border-box;
193
202
  display: inline-flex;
194
203
  flex-direction: column;
195
204
  justify-content: space-between;
205
+ box-sizing: border-box;
196
206
  width: 100%;
197
207
  height: 100%;
198
- cursor: pointer;
199
208
  padding: var(--wt-app-navigator-item-padding);
209
+ cursor: pointer;
200
210
  }
201
211
 
202
212
  // img inside a