fcad-core-dragon 2.0.0-beta.1 → 2.0.0-beta.10

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 (163) hide show
  1. package/.editorconfig +6 -31
  2. package/.prettierrc +11 -0
  3. package/.vscode/extensions.json +8 -0
  4. package/.vscode/settings.json +16 -0
  5. package/CHANGELOG +153 -0
  6. package/README.md +28 -43
  7. package/documentation/.vitepress/config.js +114 -0
  8. package/documentation/api-examples.md +49 -0
  9. package/documentation/composants/app-base-button.md +58 -0
  10. package/documentation/composants/app-base-error-display.md +59 -0
  11. package/documentation/composants/app-base-popover.md +68 -0
  12. package/documentation/composants/app-comp-audio.md +75 -0
  13. package/documentation/composants/app-comp-branch-buttons.md +111 -0
  14. package/documentation/composants/app-comp-button-progress.md +53 -0
  15. package/documentation/composants/app-comp-carousel.md +53 -0
  16. package/documentation/composants/app-comp-container.md +53 -0
  17. package/documentation/composants/app-comp-input-checkbox-next.md +42 -0
  18. package/documentation/composants/app-comp-input-dropdown-next.md +34 -0
  19. package/documentation/composants/app-comp-input-radio-next.md +39 -0
  20. package/documentation/composants/app-comp-input-text-next.md +35 -0
  21. package/documentation/composants/app-comp-input-text-table-next.md +34 -0
  22. package/documentation/composants/app-comp-input-text-to-fill-dropdown-next.md +53 -0
  23. package/documentation/composants/app-comp-input-text-to-fill-next.md +31 -0
  24. package/documentation/composants/app-comp-jauge.md +31 -0
  25. package/documentation/composants/app-comp-menu-item.md +55 -0
  26. package/documentation/composants/app-comp-menu.md +29 -0
  27. package/documentation/composants/app-comp-navigation.md +41 -0
  28. package/documentation/composants/app-comp-note-call.md +53 -0
  29. package/documentation/composants/app-comp-note-credit.md +53 -0
  30. package/documentation/composants/app-comp-play-bar-next.md +53 -0
  31. package/documentation/composants/app-comp-pop-up-next.md +93 -0
  32. package/documentation/composants/app-comp-quiz-next.md +235 -0
  33. package/documentation/composants/app-comp-quiz-recall.md +53 -0
  34. package/documentation/composants/app-comp-svg-next.md +53 -0
  35. package/documentation/composants/app-comp-table-of-content.md +50 -0
  36. package/documentation/composants/app-comp-video-player.md +82 -0
  37. package/documentation/composants.md +46 -0
  38. package/documentation/composants_critiques/ModelPageComposant.md +53 -0
  39. package/documentation/composants_critiques/app-base-module.md +43 -0
  40. package/documentation/composants_critiques/app-base-page.md +48 -0
  41. package/documentation/composants_critiques/app-base.md +311 -0
  42. package/documentation/composants_critiques/main.md +15 -0
  43. package/documentation/demarrage.md +50 -0
  44. package/documentation/deploiement.md +58 -0
  45. package/documentation/index.md +33 -0
  46. package/documentation/markdown-examples.md +85 -0
  47. package/documentation/public/npm_version.png +0 -0
  48. package/documentation/public/vite.svg +15 -0
  49. package/documentation/public/vuejs.svg +2 -0
  50. package/documentation/public/vuetify.svg +6 -0
  51. package/eslint.config.js +60 -0
  52. package/package.json +43 -47
  53. package/src/$locales/en.json +86 -108
  54. package/src/$locales/fr.json +66 -127
  55. package/src/assets/data/onboardingMessages.json +1 -1
  56. package/src/components/AppBase.vue +960 -405
  57. package/src/components/AppBaseButton.test.js +21 -0
  58. package/src/components/AppBaseButton.vue +42 -10
  59. package/src/components/AppBaseErrorDisplay.vue +207 -189
  60. package/src/components/AppBaseFlipCard.vue +1 -0
  61. package/src/components/AppBaseModule.vue +769 -977
  62. package/src/components/AppBasePage.vue +635 -81
  63. package/src/components/AppBasePopover.vue +41 -0
  64. package/src/components/AppBaseSkeleton.vue +66 -0
  65. package/src/components/AppCompAudio.vue +256 -0
  66. package/src/components/AppCompBranchButtons.vue +79 -153
  67. package/src/components/AppCompButtonProgress.vue +21 -36
  68. package/src/components/AppCompCarousel.vue +231 -87
  69. package/src/components/{AppCompTranscript.vue → AppCompContainer.vue} +12 -2
  70. package/src/components/AppCompInputCheckBoxNx.vue +323 -0
  71. package/src/components/AppCompInputDropdownNx.vue +299 -0
  72. package/src/components/AppCompInputRadioNx.vue +284 -0
  73. package/src/components/AppCompInputTextNx.vue +153 -0
  74. package/src/components/AppCompInputTextTableNx.vue +202 -0
  75. package/src/components/AppCompInputTextToFillDropdownNx.vue +340 -0
  76. package/src/components/AppCompInputTextToFillNx.vue +313 -0
  77. package/src/components/AppCompJauge.vue +36 -10
  78. package/src/components/AppCompMenu.vue +246 -32
  79. package/src/components/AppCompMenuItem.vue +87 -21
  80. package/src/components/AppCompNavigation.vue +470 -447
  81. package/src/components/AppCompNoteCall.vue +93 -58
  82. package/src/components/AppCompNoteCredit.vue +423 -96
  83. package/src/components/AppCompPlayBarNext.vue +2288 -0
  84. package/src/components/AppCompPopUpNext.vue +504 -0
  85. package/src/components/AppCompQuizNext.vue +510 -0
  86. package/src/components/AppCompQuizRecall.vue +199 -99
  87. package/src/components/AppCompSVGNext.vue +346 -0
  88. package/src/components/AppCompSettingsMenu.vue +17 -16
  89. package/src/components/AppCompTableOfContent.vue +262 -99
  90. package/src/components/AppCompVideoPlayer.vue +183 -142
  91. package/src/components/BaseModule.vue +8 -20
  92. package/src/components/tests__/AppBaseButton.spec.js +53 -0
  93. package/src/components/tests__/useTimer.spec.js +91 -0
  94. package/src/composables/useIdleDetector.js +56 -0
  95. package/src/composables/useQuiz.js +89 -0
  96. package/src/composables/useTimer.js +172 -0
  97. package/src/directives/nvdaFix.js +53 -0
  98. package/src/externalComps/ModuleView.vue +22 -0
  99. package/src/externalComps/SummaryView.vue +91 -0
  100. package/src/main.js +397 -148
  101. package/src/module/stores/appStore.js +947 -0
  102. package/src/module/xapi/ADL.js +241 -60
  103. package/src/module/xapi/Crypto/Hasher.js +8 -8
  104. package/src/module/xapi/Crypto/WordArray.js +6 -6
  105. package/src/module/xapi/Crypto/algorithms/BufferedBlockAlgorithm.js +4 -4
  106. package/src/module/xapi/Crypto/algorithms/C_algo.js +14 -18
  107. package/src/module/xapi/Crypto/algorithms/HMAC.js +1 -1
  108. package/src/module/xapi/Crypto/algorithms/SHA1.js +1 -1
  109. package/src/module/xapi/Crypto/encoders/Base.js +7 -7
  110. package/src/module/xapi/Crypto/encoders/Base64.js +3 -3
  111. package/src/module/xapi/Crypto/encoders/Hex.js +2 -2
  112. package/src/module/xapi/Crypto/encoders/Latin1.js +3 -3
  113. package/src/module/xapi/Crypto/encoders/Utf8.js +3 -3
  114. package/src/module/xapi/Statement/index.js +3 -3
  115. package/src/module/xapi/launch.js +10 -10
  116. package/src/module/xapi/utils.js +17 -17
  117. package/src/module/xapi/wrapper.js +219 -214
  118. package/src/module/xapi/xapiStatement.js +29 -29
  119. package/src/plugins/analytics.js +34 -0
  120. package/src/plugins/bus.js +7 -2
  121. package/src/plugins/gsap.js +5 -7
  122. package/src/plugins/helper.js +97 -34
  123. package/src/plugins/i18n.js +13 -18
  124. package/src/plugins/idb.js +45 -30
  125. package/src/plugins/save.js +1 -1
  126. package/src/plugins/scorm.js +15 -15
  127. package/src/plugins/xapi.js +2 -2
  128. package/src/public/index.html +22 -10
  129. package/src/router/index.js +29 -13
  130. package/src/router/routes.js +29 -54
  131. package/src/shared/generalfuncs.js +186 -30
  132. package/src/shared/validators.js +809 -40
  133. package/vitest.config.js +19 -0
  134. package/.eslintignore +0 -29
  135. package/.eslintrc.js +0 -86
  136. package/.prettierrc.js +0 -5
  137. package/babel.config.js +0 -3
  138. package/src/components/AppBaseDragChoice.vue +0 -91
  139. package/src/components/AppBaseDropZone.vue +0 -112
  140. package/src/components/AppCompBif.vue +0 -120
  141. package/src/components/AppCompDragAndDrop.vue +0 -339
  142. package/src/components/AppCompInputAssociation.vue +0 -332
  143. package/src/components/AppCompInputCheckBox.vue +0 -227
  144. package/src/components/AppCompInputDropdown.vue +0 -184
  145. package/src/components/AppCompInputRadio.vue +0 -169
  146. package/src/components/AppCompInputTextBox.vue +0 -91
  147. package/src/components/AppCompInputTextTable.vue +0 -155
  148. package/src/components/AppCompInputTextToFillDropdown.vue +0 -255
  149. package/src/components/AppCompInputTextToFillText.vue +0 -164
  150. package/src/components/AppCompMediaPlayer.vue +0 -397
  151. package/src/components/AppCompPlayBar.vue +0 -1319
  152. package/src/components/AppCompPopUp.vue +0 -522
  153. package/src/components/AppCompPopover.vue +0 -27
  154. package/src/components/AppCompQuiz.vue +0 -2989
  155. package/src/components/AppCompSVG.vue +0 -309
  156. package/src/mixins/$pageMixins.js +0 -459
  157. package/src/mixins/$quizMixins.js +0 -456
  158. package/src/mixins/timerMixin.js +0 -156
  159. package/src/module/store.js +0 -895
  160. package/src/plugins/timeManager.js +0 -77
  161. package/src/routes_bckp.js +0 -313
  162. package/src/routes_static.js +0 -344
  163. package/vue.config.js +0 -83
@@ -0,0 +1,504 @@
1
+ <!-- About this Component--
2
+ *@ Description: Application component to show instructions in a modal.
3
+ *@ What it does: This component uses the VDialog component to create a Popup. 2 types of popups can be display:
4
+ - end of activities popup (popup-endActivity). Default used by the application at the end of activities (AppCompNavigation)
5
+ - custom popup (popup-custom)- this allow user to defined custom popup using the power of VDialog. Must respect properties defined by VDialog. For more info, refer to https://vuetifyjs.com/en/components/dialogs/#usage.
6
+ It validates the content of the popup before rendering. Will render error view if there are some errors in content definition
7
+ * What it needs: data must contain:
8
+ - type(string) : 'popup-endAcivity' || 'popup-custom || popup-info'
9
+ - value (Object): {$bvArgs(Object), template (String)}
10
+
11
+ *⚠️@Note :There can only be Popup instance of this component in the application. You can ask the application to open the Popup with you defined popup
12
+ *@ Exemple: creating a custom popup using the VDialog props
13
+
14
+ const myCustomProp = {
15
+ type: 'popup-custom',
16
+ value: {
17
+ //⚠️IMPORTANT:Only props of VDialog must be listed in $bvArgs. Check VDialog documentation for full list of props
18
+ $bvArgs: {
19
+ centered: true,
20
+ width: 'auto',
21
+ scrollable: false,
22
+ 'max-width': '600'
23
+ }
24
+ //⚠️IMPORTANT:Must have a template attribute
25
+ tempate:`<div><h4>Exemple of custom popup</h4><p>Hello World</p></div>`
26
+ }
27
+ }
28
+ // Now we can ask the application to open our custom popup
29
+ this.$bus.$emit('open-popup', myCustomProp)
30
+ -->
31
+
32
+ <template>
33
+ <div>
34
+ <template v-if="!errors.length">
35
+ <!------------ End Activity --------------------------->
36
+
37
+ <v-dialog
38
+ id="popUp"
39
+ :model-value="popupType == 'popup-endActivity' && dialogue"
40
+ :class="pType"
41
+ width="auto"
42
+ scrollable
43
+ centered
44
+ @after-leave="$close(pContent.cb_$close)"
45
+ >
46
+ <focus-trap v-model:active="dialogue" :prevent-scroll="true">
47
+ <div class="pop-outside">
48
+ <div class="pop-header">
49
+ <app-base-button
50
+ id="close-pop"
51
+ class="btn-ghost-ico"
52
+ :title="$t('button.closePopUp')"
53
+ :aria-label="$t('button.closePopUp')"
54
+ @click="$close()"
55
+ >
56
+ <svg aria-hidden="true" focusable="false">
57
+ <use href="#close-square-icon" />
58
+ </svg>
59
+ </app-base-button>
60
+ </div>
61
+ <div class="pop-containt">
62
+ <div class="pop-box">
63
+ <div id="popHeader">
64
+ <div id="dialogTitle" class="p-title" v-html="pTitle"></div>
65
+ </div>
66
+ <div class="box-content-popUp"></div>
67
+ <div
68
+ id="end-activity"
69
+ :aria-hidden="pType !== 'popup-endActivity'"
70
+ class="popup-bottom-buttons"
71
+ ></div>
72
+ </div>
73
+ </div>
74
+ </div>
75
+ </focus-trap>
76
+ </v-dialog>
77
+ <!------------ POPUP INFO ----------------------------->
78
+ <v-dialog
79
+ id="popUp"
80
+ :model-value="popupType == 'popup-info' && dialogue"
81
+ :class="pType"
82
+ width="auto"
83
+ scrollable
84
+ centered
85
+ v-bind="pArgs"
86
+ @after-leave="$close(pContent.cb_$close)"
87
+ >
88
+ <focus-trap v-model:active="dialogue" :prevent-scroll="true">
89
+ <div class="pop-outside">
90
+ <div class="pop-header">
91
+ <app-base-button
92
+ id="close-pop"
93
+ class="btn-ghost-ico"
94
+ :title="$t('button.closePopUp')"
95
+ :aria-label="$t('button.closePopUp')"
96
+ @click="$close()"
97
+ >
98
+ <svg aria-hidden="true" focusable="false">
99
+ <use href="#close-square-icon" />
100
+ </svg>
101
+ </app-base-button>
102
+ </div>
103
+ <div class="pop-containt">
104
+ <div class="pop-box">
105
+ <div id="popHeader">
106
+ <p id="dialogTitle" class="p-title" v-html="pTitle"></p>
107
+ </div>
108
+ <div class="box-content-popUp">
109
+ <template v-if="contentLength > 0">
110
+ <template v-for="(content, _key, index) of pContent">
111
+ <!-------- Create TEXT element -------------->
112
+ <p
113
+ v-if="_key.includes('text') && !_key.includes('hyper')"
114
+ :id="`${_key}_${index}`"
115
+ :key="_key"
116
+ class="p-txt"
117
+ >
118
+ {{ content }}
119
+ </p>
120
+
121
+ <!-------- Create HTMLelement -------------->
122
+ <div
123
+ v-else-if="_key.includes('hypertext')"
124
+ :id="`${_key}_${index}`"
125
+ :key="`hyp_${_key}`"
126
+ v-html="content"
127
+ />
128
+
129
+ <!-------- Create IMAGE element ------------->
130
+ <img
131
+ v-else-if="_key.includes('image')"
132
+ :id="`${_key}_${index}`"
133
+ :key="`img_${_key}`"
134
+ class="p-img"
135
+ :src="content.path"
136
+ :alt="content.label || 'image'"
137
+ />
138
+
139
+ <!-------- Create LINK element -------------->
140
+ <a
141
+ v-else-if="_key.includes('link')"
142
+ :id="`${_key}_${index}`"
143
+ :key="`lnk_${_key}`"
144
+ :href="content.ref"
145
+ class="p-a"
146
+ target="_blank"
147
+ :title="`${content.label}`"
148
+ >
149
+ {{ content.label }}
150
+ </a>
151
+
152
+ <!-------- Create VIDEO element ------------->
153
+ <video
154
+ v-else-if="_key.includes('video')"
155
+ :id="`${_key}_${index}`"
156
+ :key="`vid_${_key}`"
157
+ :src="content"
158
+ class="p-vid"
159
+ controls
160
+ disablepictureinpicture
161
+ controlslist="nofullscreen nodownload"
162
+ />
163
+
164
+ <!--------Create AUDIO element--------------->
165
+ <audio
166
+ v-else-if="_key.includes('audio')"
167
+ :id="`${_key}_${index}`"
168
+ :key="`aud_${_key}`"
169
+ :src="content"
170
+ class="p-aud"
171
+ controls
172
+ controlslist="nodownload"
173
+ />
174
+ </template>
175
+ </template>
176
+ </div>
177
+ <div
178
+ id="end-activity"
179
+ :aria-hidden="pType !== 'popup-endActivity'"
180
+ class="popup-bottom-buttons"
181
+ ></div>
182
+ </div>
183
+ </div>
184
+ </div>
185
+ </focus-trap>
186
+ </v-dialog>
187
+ <!------------ POPUP CUSTOM --------------------------->
188
+ <v-dialog
189
+ id="popUp"
190
+ :model-value="popupType == 'popup-custom' && dialogue"
191
+ :class="pType"
192
+ v-bind="pArgs"
193
+ @after-leave="$close(pContent.cb_$close)"
194
+ >
195
+ <focus-trap v-model:active="dialogue" :prevent-scroll="true">
196
+ <component :is="{ template: pContent.template }"></component>
197
+ </focus-trap>
198
+ </v-dialog>
199
+ <!------------------------------- END POPUPS ------------------------------>
200
+ </template>
201
+ <app-base-error-display
202
+ v-show="errors.length"
203
+ :error-group="'component'"
204
+ :error-title="'ERREUR: COMPOSANT DE POPUP'"
205
+ :errors-list="errors"
206
+ />
207
+ </div>
208
+ </template>
209
+
210
+ <script>
211
+ import { mapState, mapActions } from 'pinia'
212
+ import { useAppStore } from '../module/stores/appStore'
213
+
214
+ export default {
215
+ name: 'AppCompPopUp',
216
+
217
+ data() {
218
+ return {
219
+ pType: null,
220
+ pName: 'noName',
221
+ pContent: {},
222
+ pArgs: null,
223
+ pTitle: '',
224
+ errors: [],
225
+ docLink:
226
+ 'https://fcaddocumentation.netlify.app/guide/ressources.html#creer-un-popup-custom',
227
+ animationOff: false,
228
+ dialogue: false
229
+ }
230
+ },
231
+ computed: {
232
+ ...mapState(useAppStore, ['getNotes', 'getWidgetOpen']),
233
+ contentLength() {
234
+ let size = null
235
+ if (!this.pType || this.pType !== 'popup-info') return
236
+
237
+ if (this.pContent && Object.keys(this.pContent).length > 0)
238
+ size = Object.keys(this.pContent).length
239
+ return size
240
+ },
241
+
242
+ popupType() {
243
+ if (!this.pType) return
244
+ return this.pType
245
+ }
246
+ },
247
+
248
+ mounted() {
249
+ this.$bus.$on('popup-open', this.validateContent)
250
+ this.$bus.$on('popup-close', this.$close)
251
+ },
252
+ beforeUnmount() {
253
+ this.$bus.$off('popup-open', this.validateContent)
254
+ this.$bus.$off('popup-close', this.$close)
255
+ },
256
+ methods: {
257
+ ...mapActions(useAppStore, ['updateEndPopUp']),
258
+ /**
259
+ * @description - Validate the data for the component
260
+ * @param {Object} data
261
+ */
262
+ validateContent(data) {
263
+ if (!data) return
264
+ const typeList = ['popup-custom', 'popup-endActivity', 'popup-info']
265
+
266
+ if (this.errors.length > 0) this.errors = []
267
+
268
+ if (data.type) {
269
+ // validate the type value of popup
270
+ const validType = typeList.includes(data.type)
271
+
272
+ if (!validType) this.errors.push('Invalid value for type')
273
+ } else this.errors.push('Missing argument: type')
274
+
275
+ // validate value of the popup according to popup type
276
+ // Content must be String|Object
277
+ if (data.value) {
278
+ let validObject = false
279
+ if (
280
+ data.value.constructor === Object &&
281
+ Object.keys(data.value).length > 0
282
+ )
283
+ validObject = true
284
+
285
+ if (validObject) {
286
+ let KeywordsList
287
+ //Validate the content accordint to popup type
288
+ switch (true) {
289
+ case data.type === 'popup-endActivity':
290
+ KeywordsList = ['template', 'title'] // accepted keywords in value declaration for pop-up end-Activity
291
+ break
292
+
293
+ case data.type === 'popup-custom':
294
+ KeywordsList = ['$bvArgs', 'template'] // accepted keywords in value declaration for pop-up custom
295
+ //Must have required keywords
296
+ for (const key of KeywordsList) {
297
+ if (data.value[key]) continue
298
+ this.errors.push(
299
+ `Missing required attribute 👉${key}👈. Required attributes are ${[...KeywordsList]}`
300
+ )
301
+ }
302
+
303
+ break
304
+ default:
305
+ KeywordsList = [
306
+ 'title',
307
+ 'text_',
308
+ 'image_',
309
+ 'video_',
310
+ 'audio_',
311
+ 'link_',
312
+ 'hypertext_',
313
+ '$bvArgs'
314
+ ] // accepted keyword in value declaration for pop-up custom
315
+ }
316
+ //validate each key in value content
317
+
318
+ for (let key of Object.keys(data.value)) {
319
+ let expectedKey = key
320
+ // search if key match lists
321
+ if (key.includes('_') && !key.includes('cb_$'))
322
+ expectedKey = `${key.split('_')[0]}_`
323
+
324
+ //===============================================
325
+ const test = (regexp) => regexp.test(expectedKey) //defining the testing function
326
+
327
+ switch (true) {
328
+ case ![...KeywordsList].includes(expectedKey):
329
+ this.errors.push(
330
+ `Invalid attribute declaration 👉${key}👈 . Expected attributes are ${[...KeywordsList]}`
331
+ )
332
+ break
333
+
334
+ case test(/link/):
335
+ // Validating content of link element
336
+ if (!data.value[key].ref) {
337
+ this.errors.push('Missing ref for link')
338
+ }
339
+ break
340
+
341
+ case test(/image/):
342
+ // Validating content of link element
343
+ if (!data.value[key].path) {
344
+ this.errors.push('Missing path for image')
345
+ }
346
+ break
347
+
348
+ case test(/cb_\$/):
349
+ // validating content of cb_$ keys to be a function
350
+ if (data.value[key].constructor != Function)
351
+ this.errors.push(
352
+ `Invalid assignment for attribute 👉${expectedKey} popup. Must be a Function`
353
+ )
354
+ break
355
+
356
+ case test(/\$bvArgs/):
357
+ // validating content of cb_$ keys to be a function
358
+
359
+ if (data.value[key].constructor != Object)
360
+ this.errors.push(
361
+ `Invalid assignment for attribute 👉${expectedKey} popup. Must be an Object`
362
+ )
363
+
364
+ break
365
+
366
+ default: {
367
+ if (data.value[key].constructor != String) {
368
+ this.errors.push(
369
+ `Invalid assignment for attribute 👉${key} in popup. Must be a String`
370
+ )
371
+ }
372
+ }
373
+ }
374
+ }
375
+ } else this.errors.push('Invalid object declaration for value')
376
+ } else this.errors.push('Missing argument - value')
377
+
378
+ if (import.meta.env.DEV) {
379
+ for (const err of this.errors)
380
+ console.warn(
381
+ `%c WARNING!>>> POP-UP: ${err} `,
382
+ 'background: orange; color: white; display: block; border-radius:5px; margin:5px;'
383
+ )
384
+ }
385
+
386
+ if (!this.errors.length) {
387
+ if (data.type === 'popup-endActivity') {
388
+ const { title, ...filtered } = data.value
389
+ this.pContent = filtered
390
+ this.pTitle = title
391
+ } else {
392
+ const { title, $bvArgs, ...filtered } = data.value
393
+ this.pContent = filtered
394
+ this.pTitle = title
395
+ this.pArgs = $bvArgs // native VDialog props
396
+ }
397
+ this.pType = data.type
398
+ this.pName = data.name
399
+
400
+ if (this.pType == 'popup-endActivity')
401
+ this.updateEndPopUp(true) //This will handle the activation of the element in the portal
402
+ else this.updateEndPopUp(false) //This will handle the activation of the element in the portal
403
+ if (this.getWidgetOpen) {
404
+ this.$bus.$emit('close-widget')
405
+ }
406
+ this.$open()
407
+ }
408
+ },
409
+
410
+ /**
411
+ * @description - method to open the popup
412
+ * @param {Function} cb
413
+ */
414
+ $open(cb) {
415
+ this.dialogue = true
416
+ },
417
+ /**
418
+ * @description - method to close the popup
419
+ * @param {Function} cb
420
+ */
421
+ $close(options, cb) {
422
+ if (this.pType === 'popup-endActivity') this.updateEndPopUp(false)
423
+ this.dialogue = false
424
+ }
425
+ }
426
+ }
427
+ </script>
428
+ <style lang="scss">
429
+ .v-overlay__scrim {
430
+ background: none !important;
431
+ }
432
+
433
+ .popup-info {
434
+ .v-overlay__content {
435
+ width: 565px !important;
436
+ padding: 16px 24px 24px 24px;
437
+ overflow: hidden;
438
+
439
+ .pop-outside {
440
+ .pop-header {
441
+ display: flex;
442
+ flex-direction: row;
443
+ justify-content: flex-end;
444
+ width: 100%;
445
+
446
+ #close-pop {
447
+ margin-right: 2px;
448
+ margin-top: 2px;
449
+ }
450
+ }
451
+ }
452
+ }
453
+ }
454
+
455
+ .popup-endActivity {
456
+ .v-overlay__content {
457
+ max-height: 277px !important;
458
+ margin: 0 !important;
459
+ width: 100% !important;
460
+ max-width: 100% !important;
461
+
462
+ .pop-outside {
463
+ display: flex;
464
+ flex-direction: column;
465
+ padding: 24px;
466
+
467
+ .pop-header {
468
+ display: flex;
469
+ justify-content: flex-end;
470
+ }
471
+ .pop-containt {
472
+ display: flex;
473
+ justify-content: center;
474
+ position: relative;
475
+ bottom: 8px;
476
+
477
+ #popHeader {
478
+ display: flex;
479
+ justify-content: center;
480
+ margin-bottom: 24px;
481
+ }
482
+
483
+ .popup-bottom-buttons {
484
+ display: flex;
485
+ justify-content: center;
486
+
487
+ .btn {
488
+ &:first-child {
489
+ margin-right: 24px;
490
+ }
491
+ }
492
+ }
493
+ }
494
+ }
495
+ }
496
+ }
497
+
498
+ .popup-custom {
499
+ .v-overlay__content {
500
+ margin: 0 !important;
501
+ width: 100% !important;
502
+ }
503
+ }
504
+ </style>