@intellias/menu 1.0.2 → 1.0.5

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 (175) hide show
  1. package/README.md +44 -9
  2. package/dist/css/main.css +155 -2
  3. package/dist/index.html +9 -0
  4. package/dist/js/{1.js → kudosForm.js} +24 -58
  5. package/dist/js/main.js +654 -689
  6. package/dist/js/rejectComponent.js +363 -0
  7. package/dist/js/{6.js → vendors~kudosForm.js} +5 -5
  8. package/dist/js/{0.js → vendors~kudosForm~rejectComponent.js} +27 -27
  9. package/dist/js/vue.js +2 -2
  10. package/package.json +100 -112
  11. package/Menu.ts +0 -625
  12. package/assets/icons/arrow-down.svg +0 -13
  13. package/assets/icons/arrow-left.svg +0 -3
  14. package/assets/icons/arrow-submenu.svg +0 -8
  15. package/assets/icons/close.svg +0 -3
  16. package/assets/icons/delete.svg +0 -13
  17. package/assets/icons/faq-new.svg +0 -4
  18. package/assets/icons/kudos.svg +0 -14
  19. package/assets/icons/loading-spinner.svg +0 -40
  20. package/assets/icons/notification.svg +0 -11
  21. package/assets/icons/notifications/assessment.svg +0 -10
  22. package/assets/icons/notifications/buddy_program.svg +0 -8
  23. package/assets/icons/notifications/compensation_packages.svg +0 -10
  24. package/assets/icons/notifications/dsat.svg +0 -8
  25. package/assets/icons/notifications/feedback.svg +0 -7
  26. package/assets/icons/notifications/kudos.svg +0 -4
  27. package/assets/icons/notifications/overtime_requests.svg +0 -15
  28. package/assets/icons/notifications/pdu_program.svg +0 -4
  29. package/assets/icons/notifications/profile_update.svg +0 -6
  30. package/assets/icons/notifications/recommendation_program.svg +0 -7
  31. package/assets/icons/notifications/reminders.svg +0 -4
  32. package/assets/icons/notifications/sick_leaves.svg +0 -5
  33. package/assets/icons/notifications/smarts.svg +0 -4
  34. package/assets/icons/notifications/survey.svg +0 -8
  35. package/assets/icons/notifications/unpaid_leave.svg +0 -4
  36. package/assets/icons/notifications/vacations.svg +0 -4
  37. package/assets/icons/pause.svg +0 -13
  38. package/assets/icons/play.svg +0 -13
  39. package/assets/icons/smart.svg +0 -14
  40. package/assets/icons/smarts-kudos.svg +0 -11
  41. package/assets/icons/spinner-solid.svg +0 -1
  42. package/assets/icons/vacation.svg +0 -14
  43. package/assets/icons/visibility.svg +0 -1
  44. package/assets/intems-logo.svg +0 -3
  45. package/babel.config.js +0 -6
  46. package/buses/eventBus.ts +0 -19
  47. package/buses/events/GiveKudosEvent.ts +0 -7
  48. package/components/buttons/action-button/ActionButton.scss +0 -133
  49. package/components/buttons/action-button/ActionButton.ts +0 -57
  50. package/components/buttons/action-button/ActionButton.vue +0 -50
  51. package/components/buttons/secondary-button/SecondaryButton.scss +0 -48
  52. package/components/buttons/secondary-button/SecondaryButton.ts +0 -28
  53. package/components/buttons/secondary-button/SecondaryButton.vue +0 -27
  54. package/components/confirm/Confirm.scss +0 -44
  55. package/components/confirm/Confirm.ts +0 -82
  56. package/components/confirm/Confirm.vue +0 -64
  57. package/components/give-kudos-form/GiveKudosForm.scss +0 -114
  58. package/components/give-kudos-form/GiveKudosForm.ts +0 -159
  59. package/components/give-kudos-form/GiveKudosForm.vue +0 -131
  60. package/components/give-kudos-form/mixins/UserSelectMixin.ts +0 -57
  61. package/components/give-kudos-form/models/KudosShareModel.ts +0 -6
  62. package/components/give-kudos-form/models/UserListModel.ts +0 -5
  63. package/components/give-kudos-form/validators/InEnglishValidatorRegex.ts +0 -17
  64. package/components/give-kudos-form/validators/KudosBalance.ts +0 -10
  65. package/components/modal/Modal.scss +0 -53
  66. package/components/modal/Modal.ts +0 -70
  67. package/components/modal/Modal.vue +0 -28
  68. package/components/notifications-sidebar/NotificationsSidebar.scss +0 -665
  69. package/components/notifications-sidebar/NotificationsSidebar.ts +0 -203
  70. package/components/notifications-sidebar/NotificationsSidebar.vue +0 -171
  71. package/components/notifications-sidebar/models/BroadcastNotificationPayload.ts +0 -8
  72. package/components/notifications-sidebar/models/TotalCounter.ts +0 -50
  73. package/components/notifications-sidebar/notification/Notification.ts +0 -17
  74. package/components/notifications-sidebar/notification/Notification.vue +0 -87
  75. package/components/play-pause/PlayPause.scss +0 -33
  76. package/components/play-pause/PlayPause.ts +0 -156
  77. package/components/play-pause/PlayPause.vue +0 -36
  78. package/components/play-pause/PlayPauseStatus.ts +0 -4
  79. package/components/play-pause/helpers/LatestTrackedTimeDurationHelper.ts +0 -55
  80. package/components/play-pause/helpers/PauseHelper.ts +0 -55
  81. package/components/play-pause/helpers/TrackedTimeHelper.ts +0 -80
  82. package/components/preloader/Preloader.vue +0 -34
  83. package/components/request-loader/RequestLoader.scss +0 -20
  84. package/components/request-loader/RequestLoader.ts +0 -80
  85. package/components/request-loader/RequestLoader.vue +0 -15
  86. package/components/sub-menu/SubMenu.scss +0 -33
  87. package/components/sub-menu/SubMenu.ts +0 -38
  88. package/components/sub-menu/SubMenu.vue +0 -21
  89. package/components/time-ago/TimeAgo.ts +0 -34
  90. package/components/time-ago/TimeAgo.vue +0 -9
  91. package/components/user-picture/UserPicture.scss +0 -62
  92. package/components/user-picture/UserPicture.ts +0 -105
  93. package/components/user-picture/UserPicture.vue +0 -23
  94. package/components/v-select-intems/VSelectIntems.ts +0 -112
  95. package/components/v-select-intems/VSelectIntems.vue +0 -68
  96. package/components/v-select-intems/open-indicator/OpenIndicator.vue +0 -3
  97. package/dist/css/1.css +0 -85
  98. package/dist/css/2.css +0 -34
  99. package/dist/css/3.css +0 -34
  100. package/dist/css/4.css +0 -34
  101. package/dist/css/5.css +0 -34
  102. package/dist/html/app.html +0 -19
  103. package/dist/html/styles.html +0 -1
  104. package/dist/js/2.js +0 -217
  105. package/dist/js/3.js +0 -181
  106. package/dist/js/4.js +0 -181
  107. package/dist/js/5.js +0 -181
  108. package/helpers/GeneralHelper.ts +0 -61
  109. package/helpers/PublisherSubscriber.ts +0 -34
  110. package/helpers/QueryFilter.ts +0 -204
  111. package/helpers/TimeHelper.ts +0 -54
  112. package/helpers/Validations.ts +0 -7
  113. package/helpers/model/ModelHelper.ts +0 -155
  114. package/helpers/model/decorators/AsCollection.ts +0 -26
  115. package/helpers/model/decorators/AsModel.ts +0 -25
  116. package/helpers/model/decorators/DateTime.ts +0 -26
  117. package/helpers/model/decorators/TimeDuration.ts +0 -33
  118. package/helpers/moment/Duration.ts +0 -64
  119. package/helpers/moment/Moment.ts +0 -17
  120. package/helpers/moment/index.d.ts +0 -20
  121. package/helpers/response/AxiosProxy.ts +0 -72
  122. package/helpers/response/ErrorsToToastHelper.ts +0 -42
  123. package/helpers/response/ResponseCode.ts +0 -16
  124. package/helpers/response/ResponseHelper.ts +0 -42
  125. package/helpers/response/ResponseInterface.ts +0 -34
  126. package/helpers/response/ResponseState.ts +0 -6
  127. package/jsconfig.json +0 -19
  128. package/mixins/IntemsMath.ts +0 -29
  129. package/mixins/notifications/ActionProcessing.ts +0 -134
  130. package/mixins/notifications/confirms/AssetRejectionConfirm.vue +0 -59
  131. package/mixins/notifications/confirms/SickLeaveRejectionConfirm.vue +0 -31
  132. package/mixins/notifications/confirms/UnpaidLeaveRejectionConfirm.vue +0 -31
  133. package/mixins/notifications/confirms/VacationRejectionConfirm.vue +0 -31
  134. package/models/AssetModel.ts +0 -80
  135. package/models/AssetRequestModel.ts +0 -25
  136. package/models/ConfigModel.ts +0 -20
  137. package/models/EmployeeStartEndDateModel.ts +0 -16
  138. package/models/EmploymentTypeModel.ts +0 -95
  139. package/models/LogoutModel.ts +0 -3
  140. package/models/Model.ts +0 -12
  141. package/models/ModuleOptions.ts +0 -24
  142. package/models/PublicInfoModel.ts +0 -38
  143. package/models/PublicLocationModel.ts +0 -36
  144. package/models/StatusModel.ts +0 -8
  145. package/models/TrackedTimeModel.ts +0 -32
  146. package/models/location/PublicLocationModel.ts +0 -36
  147. package/models/timezones/LocalTimezoneHistoryModel.ts +0 -8
  148. package/models/timezones/TimezoneModel.ts +0 -9
  149. package/models/user/ExtendedInfoModel.ts +0 -37
  150. package/models/user/NotificationActionModel.ts +0 -53
  151. package/models/user/NotificationModel.ts +0 -84
  152. package/models/user/PublicInfoModel.ts +0 -38
  153. package/models/user/WelcomeProgram.ts +0 -4
  154. package/repositories/BaseRepository.ts +0 -42
  155. package/repositories/BaseUrl.ts +0 -107
  156. package/repositories/Repository.ts +0 -291
  157. package/repositories/ResourceRepository.ts +0 -99
  158. package/repositories/TrackedTimeRepository.ts +0 -43
  159. package/repositories/UserRepository.ts +0 -75
  160. package/repositories/subscribers/CreateSubscribers.ts +0 -28
  161. package/repositories/subscribers/DefaultSubscribers.ts +0 -82
  162. package/repositories/subscribers/DeleteSubscribers.ts +0 -28
  163. package/repositories/subscribers/DownloadSubscribers.ts +0 -28
  164. package/repositories/subscribers/Subscribers.ts +0 -13
  165. package/repositories/subscribers/UpdateSubscribers.ts +0 -32
  166. package/scss/components/_global.scss +0 -66
  167. package/scss/components/_mixins.scss +0 -31
  168. package/scss/components/_tooltip.scss +0 -45
  169. package/scss/components/_utils.scss +0 -26
  170. package/scss/components/_variables.scss +0 -103
  171. package/scss/main.scss +0 -7
  172. package/shims-vue.d.ts +0 -9
  173. package/tsconfig.json +0 -31
  174. package/webpack.config.js +0 -126
  175. package/wrapper.ts +0 -51
@@ -1,203 +0,0 @@
1
- import { mapGetters, mapActions, mapMutations } from "vuex";
2
- import VueCustomScrollbar from "vue-custom-scrollbar";
3
- import QueryFilter from "../../helpers/QueryFilter";
4
- import {
5
- NotificationRejectionData,
6
- NotificationStatus,
7
- NotificationType,
8
- } from "../../models/user/NotificationModel";
9
- import Notification from "./notification/Notification.vue";
10
- import ActionButton from "../buttons/action-button/ActionButton.vue";
11
- import RequestLoader from "../request-loader/RequestLoader.vue";
12
- import Preloader from "../preloader/Preloader.vue";
13
- import { map } from "../../helpers/model/ModelHelper";
14
- import BroadcastNotificationPayload from "./models/BroadcastNotificationPayload";
15
- import ConfigModel from "../../models/ConfigModel";
16
- import DropdownMenu from "v-dropdown-menu/vue2";
17
- import "v-dropdown-menu/dist/vue2/v-dropdown-menu.css";
18
- import Tabs from "vue-tabs-with-active-line";
19
- import { ProjectName } from "../../wrapper";
20
-
21
- export default {
22
- components: {
23
- Preloader,
24
- RequestLoader,
25
- ActionButton,
26
- Notification,
27
- VueCustomScrollbar,
28
- DropdownMenu,
29
- Tabs,
30
- },
31
- inject: ["projectName", "storeAdapter"],
32
- mounted(): void {
33
- this.initListener();
34
- },
35
- methods: {
36
- ...mapActions("User/Notifications", [
37
- "readAll",
38
- "newNotification",
39
- "markAsProcessed",
40
- ]),
41
- ...mapActions("User/Notifications/SidebarModule", [
42
- "fetchSidebarNotifications",
43
- "dismissAll",
44
- ]),
45
- ...mapMutations("User/Notifications/SidebarModule", [
46
- "unsetNotifications",
47
- "changeStatus",
48
- ]),
49
- initListener(): void {
50
- this.$echo
51
- .private(`employee.${this.getUser.employee_id}`)
52
- .notification((payload) => {
53
- this.newNotification(map(BroadcastNotificationPayload, payload));
54
- if (localStorage.activeBrowserTab === "false") {
55
- localStorage.pendingAnimation = true;
56
- } else {
57
- this.bellAnimation();
58
- }
59
- });
60
- this.$echo
61
- .private(`employee.${this.getUser.employee_id}`)
62
- .listen("NotificationProcessed", (payload) => {
63
- const notification = this.find(payload.notification_id);
64
- if (
65
- notification &&
66
- notification.status !== NotificationStatus.processed
67
- ) {
68
- this.markAsProcessed(notification);
69
- }
70
- });
71
- localStorage.activeBrowserTab = true;
72
- document.addEventListener("visibilitychange", () => {
73
- localStorage.activeBrowserTab = !document.hidden;
74
- if (
75
- localStorage.activeBrowserTab === "true" &&
76
- localStorage.pendingAnimation === "true"
77
- ) {
78
- this.bellAnimation();
79
- }
80
- });
81
- },
82
- async initData(): void {
83
- Promise.all([
84
- this.unsetNotifications(),
85
- this.fetchSidebarNotifications(this.queryAll.unsetPagination()),
86
- this.fetchSidebarNotifications(this.queryPending.unsetPagination()),
87
- ]).then(() => {
88
- this.updateScrollbar();
89
- });
90
- },
91
- loadAllNotifications(): void {
92
- if (!this.dropDownOpen || this.currentTab !== "all") {
93
- return;
94
- }
95
- this.fetchSidebarNotifications(
96
- this.queryAll.offset(this.notices.count())
97
- );
98
- },
99
- loadPendingRequests(): void {
100
- if (!this.dropDownOpen || this.currentTab !== "pending_approval") {
101
- return;
102
- }
103
- this.fetchSidebarNotifications(
104
- this.queryPending.offset(this.pendingRequests.count())
105
- );
106
- },
107
- changeActiveTab(newTab): void {
108
- this.currentTab = newTab;
109
- },
110
- bellAnimation(): void {
111
- this.displayAnimation = true;
112
- setTimeout(() => {
113
- this.displayAnimation = false;
114
- }, 5600);
115
-
116
- localStorage.pendingAnimation = false;
117
- },
118
- closeSidebar(): void {
119
- this.dropDownOpen = false;
120
- },
121
- updateScrollbar(): void {
122
- this.$refs.scrollBar.update();
123
- },
124
- emitRejectionComponent(rejectionData: NotificationRejectionData): void {
125
- this.$emit("rejection-component", rejectionData);
126
- },
127
- },
128
- computed: {
129
- ...mapGetters("User", ["getUser"]),
130
- ...mapGetters("User/Notifications/SidebarModule", [
131
- "notices",
132
- "pendingRequests",
133
- "find",
134
- ]),
135
- ...mapGetters("User/Notifications", ["hasUnread", "totalUnread"]),
136
- hasUnreadNotifications(): boolean {
137
- return this.hasUnread !== undefined
138
- ? this.hasUnread
139
- : this.getUser.has_unread_notifications;
140
- },
141
- isLiteDomain(): boolean {
142
- return this.projectName === ProjectName.Lite;
143
- },
144
- intemsConfig(): ConfigModel {
145
- return this.storeAdapter.Config.state.data;
146
- },
147
- },
148
- watch: {
149
- "totalUnread.notice": {
150
- handler(notice: number): void {
151
- const tab = this.$refs.tabs.$el.children[0];
152
- if (this.totalUnread.notice) {
153
- tab.innerHTML = `All
154
- <span class="counter" >${notice}</span>`;
155
- } else {
156
- tab.innerHTML = "All";
157
- }
158
- },
159
- },
160
- "totalUnread.pending_request": {
161
- handler(request: number): void {
162
- const tab = this.$refs.tabs.$el.children[1];
163
- if (this.totalUnread.pending_request) {
164
- tab.innerHTML = `Pending approval
165
- <span class="counter" >${request}</span>`;
166
- } else {
167
- tab.innerHTML = "Pending approval";
168
- }
169
- },
170
- },
171
- },
172
- data(): Record<string, unknown> {
173
- return {
174
- queryAll: new QueryFilter()
175
- .notIn("status", [
176
- NotificationStatus.hidden,
177
- NotificationStatus.hidden_processed,
178
- ])
179
- .scope("type", NotificationType.notice),
180
- queryPending: new QueryFilter()
181
- .notIn("status", [
182
- NotificationStatus.hidden,
183
- NotificationStatus.hidden_processed,
184
- ])
185
- .scope("type", NotificationType.pending_request),
186
- dropDownOpen: false,
187
- tabs: [
188
- {
189
- title: "All",
190
- value: "all",
191
- },
192
- {
193
- title: "Pending approval",
194
- value: "pending_approval",
195
- },
196
- ],
197
- currentTab: "all",
198
- preloaderSize: "small",
199
- scrollBarSettings: { suppressScrollX: true, minScrollbarLength: 50 },
200
- displayAnimation: false,
201
- };
202
- },
203
- };
@@ -1,171 +0,0 @@
1
- <template>
2
- <div class="notifications-sidebar dropdown-menu">
3
- <dropdown-menu
4
- direction="center"
5
- :overlay="false"
6
- :isOpen="dropDownOpen"
7
- @opened="initData"
8
- >
9
- <template #trigger>
10
- <a class="notification-href pointer" ref="notifications_sidebar">
11
- <i
12
- class="icon notification"
13
- :class="{ 'bell-animation': displayAnimation }"
14
- ></i>
15
- <transition name="fade" :duration="{ enter: 4000, leave: 1 }">
16
- <span v-show="hasUnreadNotifications" class="has-unread"></span>
17
- </transition>
18
- </a>
19
- </template>
20
- <template #header>
21
- <div class="row note-title-row">
22
- <div class="col s10">
23
- <span class="primary-text">Notifications</span>
24
- </div>
25
- <div class="col s2">
26
- <dropdown-menu direction="left" :overlay="false">
27
- <template #trigger>
28
- <a
29
- class="pointer"
30
- ref="manage_dropdown"
31
- :data-target="`manage_dropdown_${_uid}`"
32
- >
33
- <div
34
- class="overflowed-menu-toggler notification-manage-toggler"
35
- >
36
- <span></span>
37
- <span></span>
38
- <span></span>
39
- </div>
40
- </a>
41
- </template>
42
- <template #body>
43
- <ul class="sub-menu">
44
- <li>
45
- <a
46
- @click="readAll"
47
- :class="{
48
- 'is-disabled':
49
- !totalUnread.notice && !totalUnread.pending_request,
50
- }"
51
- >
52
- Mark all as read
53
- </a>
54
- </li>
55
- <li>
56
- <a
57
- @click="dismissAll"
58
- :class="{
59
- 'is-disabled':
60
- !notices.count() && !pendingRequests.count(),
61
- }"
62
- >
63
- Dismiss all
64
- </a>
65
- </li>
66
- </ul>
67
- </template>
68
- </dropdown-menu>
69
- </div>
70
- </div>
71
- </template>
72
- <template #body>
73
- <div class="main-dropdown">
74
- <div class="row">
75
- <tabs
76
- :tabs="tabs"
77
- :currentTab="currentTab"
78
- :wrapper-class="'default-tabs'"
79
- :tab-class="'tab'"
80
- :tab-active-class="'active'"
81
- :line-class="'indicator'"
82
- @onClick="changeActiveTab"
83
- ref="tabs"
84
- />
85
- <div class="notification-content">
86
- <div class="row notifications-list" v-show="currentTab === 'all'">
87
- <vue-custom-scrollbar
88
- ref="scrollBar"
89
- class="col tab-content"
90
- :options="scrollBarSettings"
91
- @ps-y-reach-end="loadAllNotifications"
92
- >
93
- <notification
94
- v-for="notification in notices"
95
- @rejection-component="emitRejectionComponent"
96
- :key="notification.id"
97
- :notification="notification"
98
- ></notification>
99
- <preloader
100
- v-if="queryAll.loading"
101
- :size="preloaderSize"
102
- ></preloader>
103
- <div
104
- v-else-if="!notices.count()"
105
- class="main-text margin-top-50 align-center"
106
- >
107
- You have no new notifications
108
- </div>
109
- </vue-custom-scrollbar>
110
- </div>
111
- <div
112
- class="row notifications-list"
113
- v-show="currentTab === 'pending_approval'"
114
- >
115
- <vue-custom-scrollbar
116
- class="col tab-content"
117
- :options="scrollBarSettings"
118
- @ps-y-reach-end="loadPendingRequests"
119
- >
120
- <notification
121
- v-for="notification in pendingRequests"
122
- @rejection-component="emitRejectionComponent"
123
- :key="notification.id"
124
- :notification="notification"
125
- ></notification>
126
- <preloader
127
- v-if="queryAll.loading"
128
- :size="preloaderSize"
129
- ></preloader>
130
- <div
131
- v-else-if="!pendingRequests.count()"
132
- class="main-text margin-top-50 align-center"
133
- >
134
- You have no pending requests
135
- </div>
136
- </vue-custom-scrollbar>
137
- </div>
138
- </div>
139
- </div>
140
- <div class="row view-all-row align-center">
141
- <action-button
142
- v-if="isLiteDomain"
143
- :to="{ name: 'Employee Notifications' }"
144
- is-link
145
- @click.native="closeSidebar"
146
- >
147
- View all
148
- </action-button>
149
- <action-button
150
- v-else
151
- :href="`${intemsConfig.liteSiteUrl}`"
152
- is-link
153
- @click.native="closeSidebar"
154
- >
155
- View all
156
- </action-button>
157
- </div>
158
- </div>
159
- </template>
160
- </dropdown-menu>
161
- </div>
162
- </template>
163
-
164
- <script>
165
- import NotificationsSidebar from "./NotificationsSidebar";
166
-
167
- export default NotificationsSidebar;
168
- </script>
169
- <style lang="scss">
170
- @import "NotificationsSidebar";
171
- </style>
@@ -1,8 +0,0 @@
1
- import { NotificationType } from "../../../models/user/NotificationModel";
2
-
3
- export default class {
4
- comment = undefined as string;
5
- id = undefined as string;
6
- notification_type = undefined as NotificationType;
7
- type = undefined as string;
8
- }
@@ -1,50 +0,0 @@
1
- import { NotificationType } from "../../../models/user/NotificationModel";
2
-
3
- export type NotificationTotal = {
4
- notification: number;
5
- pending_request: number;
6
- };
7
- export default class {
8
- notice = 0 as number;
9
- pending_request = 0 as number;
10
- private has_unread = undefined;
11
-
12
- constructor(total?: NotificationTotal) {
13
- if (!total) {
14
- return;
15
- }
16
- this.notice = total.notification;
17
- this.pending_request = total.pending_request;
18
- this.checkHasUnread();
19
- }
20
-
21
- decrement(type: NotificationType): this {
22
- this[type.toString()] = this[type.toString()] - 1;
23
- this.checkHasUnread();
24
-
25
- return this;
26
- }
27
-
28
- increment(type: NotificationType | string): this {
29
- this[type.toString()] = this[type.toString()] + 1;
30
- this.checkHasUnread();
31
-
32
- return this;
33
- }
34
-
35
- private checkHasUnread(): void {
36
- this.has_unread = this.notice > 0 || this.pending_request > 0;
37
- }
38
-
39
- get hasUnread(): boolean {
40
- return this.has_unread;
41
- }
42
-
43
- readAll(): this {
44
- this.notice = 0;
45
- this.pending_request = 0;
46
- this.checkHasUnread();
47
-
48
- return this;
49
- }
50
- }
@@ -1,17 +0,0 @@
1
- import { mapActions } from "vuex";
2
- import ActionButton from "../../buttons/action-button/ActionButton.vue";
3
- import ActionProcessing from "../../../mixins/notifications/ActionProcessing";
4
- import TimeAgo from "../../time-ago/TimeAgo.vue";
5
- import NotificationModel from "../../../models/user/NotificationModel";
6
-
7
- export default {
8
- components: { TimeAgo, ActionButton },
9
- props: {
10
- notification: NotificationModel,
11
- },
12
- mixins: [ActionProcessing],
13
- methods: {
14
- ...mapActions("User/Notifications", ["read"]),
15
- ...mapActions("User/Notifications/SidebarModule", ["dismiss"]),
16
- },
17
- };
@@ -1,87 +0,0 @@
1
- <template>
2
- <div class="note" :class="{ read: !notification.isNew }">
3
- <div class="row">
4
- <div class="col s2 margin-top-5">
5
- <i class="icon category-icon" :class="notification.icon"></i>
6
- </div>
7
- <div class="col s8 note-title-col">
8
- <span class="primary-text" v-html="notification.title"></span><br />
9
- <span class="text-muted"
10
- ><time-ago :time="notification.created_at"></time-ago
11
- ></span>
12
- </div>
13
- <span class="manage-notification">
14
- <a
15
- v-if="notification.isNew && !actionProcessing"
16
- @click="read(notification)"
17
- class="pointer"
18
- title="Mark as read"
19
- >
20
- <i class="icon icon-small visibility"></i>
21
- </a>
22
- <a
23
- v-if="!actionProcessing"
24
- @click="dismiss(notification)"
25
- class="margin-left-10 pointer"
26
- >
27
- <i class="icon icon-small delete" title="Dismiss"></i>
28
- </a>
29
- </span>
30
- </div>
31
- <div class="row margin-top-15">
32
- <div
33
- class="col semi-primary-text"
34
- v-html="notification.description"
35
- ></div>
36
- </div>
37
- <div class="row margin-top-15" v-if="notification.actions.count()">
38
- <div class="col s10 action-buttons">
39
- <template v-for="(action, index) in notification.actions">
40
- <action-button
41
- v-if="
42
- !notification.isProcessed && !action.isLink && !actionProcessing
43
- "
44
- :key="index"
45
- class="margin-right-10"
46
- :class="{ 'reject-color': action.isReject }"
47
- btn-link
48
- @click.native="submitAction(action)"
49
- >
50
- {{ title(action) }}
51
- </action-button>
52
- <action-button
53
- v-else-if="action.isLink"
54
- :key="index"
55
- :is-disabled="isExpired(action)"
56
- btn-link
57
- class="margin-right-10"
58
- @click.native="proceedToView(action)"
59
- >
60
- {{ title(action) }}
61
- </action-button>
62
- <action-button
63
- v-else
64
- is-disabled
65
- btn-link
66
- class="margin-right-10"
67
- :key="index"
68
- >
69
- {{ title(action) }}
70
- </action-button>
71
- </template>
72
- </div>
73
- <div class="col s2 align-right">
74
- <i
75
- v-show="actionProcessing"
76
- class="icon icon-small2 loading-spinner loading"
77
- ></i>
78
- </div>
79
- </div>
80
- </div>
81
- </template>
82
-
83
- <script>
84
- import Notification from "./Notification";
85
-
86
- export default Notification;
87
- </script>
@@ -1,33 +0,0 @@
1
- @use "sass:map";
2
- @import "../../scss/components/variables";
3
-
4
- #modalTracked {
5
- color: map.get($intems-colors, "dark");
6
- .modal-content {
7
- #tracked-content {
8
- display: flex;
9
- align-items: center;
10
- p {
11
- margin: 0;
12
- line-height: initial;
13
- }
14
- }
15
- #span-clock {
16
- margin-right: 10px;
17
- i {
18
- font-size: 54px;
19
- }
20
- }
21
- }
22
- }
23
- .play-pause {
24
- display: flex;
25
- i.spinner-solid {
26
- animation: spin 1s linear infinite;
27
- }
28
- }
29
- @keyframes spin {
30
- 100% {
31
- transform: rotate(360deg);
32
- }
33
- }