fcad-core-dragon 2.0.1-beta.1 → 2.0.1

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 (52) hide show
  1. package/.editorconfig +33 -33
  2. package/.eslintignore +29 -29
  3. package/.eslintrc.cjs +81 -81
  4. package/CHANGELOG +5 -0
  5. package/bk.scss +117 -117
  6. package/package.json +1 -1
  7. package/src/assets/data/onboardingMessages.json +47 -47
  8. package/src/components/AppBaseErrorDisplay.vue +438 -438
  9. package/src/components/AppBaseFlipCard.vue +84 -84
  10. package/src/components/AppBasePopover.vue +41 -41
  11. package/src/components/AppCompCarousel.vue +2 -2
  12. package/src/components/AppCompJauge.vue +74 -74
  13. package/src/components/AppCompPlayBarProgress.vue +82 -82
  14. package/src/components/AppCompSettingsMenu.vue +172 -172
  15. package/src/components/AppCompTableOfContent.vue +17 -4
  16. package/src/components/AppCompViewDisplay.vue +6 -6
  17. package/src/composables/useQuiz.js +206 -206
  18. package/src/externalComps/ModuleView.vue +22 -22
  19. package/src/externalComps/SummaryView.vue +91 -91
  20. package/src/mixins/$mediaMixins.js +819 -819
  21. package/src/module/xapi/Crypto/Hasher.js +241 -241
  22. package/src/module/xapi/Crypto/WordArray.js +278 -278
  23. package/src/module/xapi/Crypto/algorithms/BufferedBlockAlgorithm.js +103 -103
  24. package/src/module/xapi/Crypto/algorithms/C_algo.js +315 -315
  25. package/src/module/xapi/Crypto/algorithms/HMAC.js +9 -9
  26. package/src/module/xapi/Crypto/algorithms/SHA1.js +9 -9
  27. package/src/module/xapi/Crypto/encoders/Base.js +105 -105
  28. package/src/module/xapi/Crypto/encoders/Base64.js +99 -99
  29. package/src/module/xapi/Crypto/encoders/Hex.js +61 -61
  30. package/src/module/xapi/Crypto/encoders/Latin1.js +61 -61
  31. package/src/module/xapi/Crypto/encoders/Utf8.js +45 -45
  32. package/src/module/xapi/Crypto/index.js +53 -53
  33. package/src/module/xapi/Statement/activity.js +47 -47
  34. package/src/module/xapi/Statement/agent.js +55 -55
  35. package/src/module/xapi/Statement/group.js +26 -26
  36. package/src/module/xapi/Statement/index.js +259 -259
  37. package/src/module/xapi/Statement/statement.js +253 -253
  38. package/src/module/xapi/Statement/statementRef.js +23 -23
  39. package/src/module/xapi/Statement/substatement.js +22 -22
  40. package/src/module/xapi/Statement/verb.js +36 -36
  41. package/src/module/xapi/activitytypes.js +17 -17
  42. package/src/module/xapi/utils.js +167 -167
  43. package/src/module/xapi/verbs.js +294 -294
  44. package/src/module/xapi/xapiStatement.js +444 -444
  45. package/src/plugins/bus.js +8 -8
  46. package/src/plugins/gsap.js +14 -14
  47. package/src/plugins/i18n.js +44 -44
  48. package/src/plugins/save.js +37 -37
  49. package/src/plugins/scorm.js +287 -287
  50. package/src/plugins/xapi.js +11 -11
  51. package/src/public/index.html +33 -33
  52. package/src/shared/generalfuncs.js +210 -210
@@ -1,84 +1,84 @@
1
- <template>
2
- <!--
3
- inspire by : https://vuejsexamples.com/generic-flip-card-in-vue-that-allows-completely-arbitrary-content-on-each-side/
4
- -->
5
- <div class="flip-card" role="button" aria-pressed="false" @click="fnClick">
6
- <div class="inside-card" :class="{ flip: isFlipped }">
7
- <div class="front-card" name="front-card">
8
- <slot name="front-card" />
9
- </div>
10
- <div class="back-card">
11
- <slot name="back-card" />
12
- </div>
13
- </div>
14
- </div>
15
- </template>
16
- <script>
17
- export default {
18
- props: {
19
- isActive: {
20
- type: Boolean,
21
- default: false
22
- }
23
- },
24
- emits: ['click'],
25
- data() {
26
- return {
27
- isFlipped: false
28
- }
29
- },
30
- methods: {
31
- /**
32
- * @fires click to parent componant or page
33
- */
34
- fnClick() {
35
- this.$emit('click', this.$el)
36
- this.isFlipped = !this.isFlipped
37
- }
38
- }
39
- }
40
- </script>
41
- <style lang="scss">
42
- .flip-card {
43
- height: auto;
44
- cursor: pointer;
45
-
46
- /***** Parameretre modifiable *****/
47
- perspective: 100%;
48
- width: 90%;
49
-
50
- .inside-card {
51
- position: relative;
52
- width: 100%;
53
- height: 100%;
54
-
55
- /***** Parameretre modifiable *****/
56
- transform-style: preserve-3d;
57
- transition: transform 0.5s;
58
-
59
- &.flip {
60
- /***** Parameretre modifiable *****/
61
- transform: rotateY(180deg);
62
- }
63
-
64
- .front-card,
65
- .back-card {
66
- position: absolute;
67
- width: 100%;
68
- height: 100%;
69
- -webkit-backface-visibility: hidden;
70
- backface-visibility: hidden;
71
-
72
- .img-flip-card {
73
- width: 90%;
74
- height: auto;
75
- }
76
- }
77
-
78
- .back-card {
79
- /***** Parameretre modifiable *****/
80
- transform: rotateY(180deg);
81
- }
82
- }
83
- }
84
- </style>
1
+ <template>
2
+ <!--
3
+ inspire by : https://vuejsexamples.com/generic-flip-card-in-vue-that-allows-completely-arbitrary-content-on-each-side/
4
+ -->
5
+ <div class="flip-card" role="button" aria-pressed="false" @click="fnClick">
6
+ <div class="inside-card" :class="{ flip: isFlipped }">
7
+ <div class="front-card" name="front-card">
8
+ <slot name="front-card" />
9
+ </div>
10
+ <div class="back-card">
11
+ <slot name="back-card" />
12
+ </div>
13
+ </div>
14
+ </div>
15
+ </template>
16
+ <script>
17
+ export default {
18
+ props: {
19
+ isActive: {
20
+ type: Boolean,
21
+ default: false
22
+ }
23
+ },
24
+ emits: ['click'],
25
+ data() {
26
+ return {
27
+ isFlipped: false
28
+ }
29
+ },
30
+ methods: {
31
+ /**
32
+ * @fires click to parent componant or page
33
+ */
34
+ fnClick() {
35
+ this.$emit('click', this.$el)
36
+ this.isFlipped = !this.isFlipped
37
+ }
38
+ }
39
+ }
40
+ </script>
41
+ <style lang="scss">
42
+ .flip-card {
43
+ height: auto;
44
+ cursor: pointer;
45
+
46
+ /***** Parameretre modifiable *****/
47
+ perspective: 100%;
48
+ width: 90%;
49
+
50
+ .inside-card {
51
+ position: relative;
52
+ width: 100%;
53
+ height: 100%;
54
+
55
+ /***** Parameretre modifiable *****/
56
+ transform-style: preserve-3d;
57
+ transition: transform 0.5s;
58
+
59
+ &.flip {
60
+ /***** Parameretre modifiable *****/
61
+ transform: rotateY(180deg);
62
+ }
63
+
64
+ .front-card,
65
+ .back-card {
66
+ position: absolute;
67
+ width: 100%;
68
+ height: 100%;
69
+ -webkit-backface-visibility: hidden;
70
+ backface-visibility: hidden;
71
+
72
+ .img-flip-card {
73
+ width: 90%;
74
+ height: auto;
75
+ }
76
+ }
77
+
78
+ .back-card {
79
+ /***** Parameretre modifiable *****/
80
+ transform: rotateY(180deg);
81
+ }
82
+ }
83
+ }
84
+ </style>
@@ -1,41 +1,41 @@
1
- <!--
2
- @ Description: This component is used to create a popover that is accessible via keyboard navigation (tab + space/enter)
3
- -->
4
- <template>
5
- <v-tooltip
6
- ref="tooltip"
7
- v-bind="$attrs"
8
- v-model="show"
9
- transition="false"
10
- :open-on-click="true"
11
- :persistent="false"
12
- >
13
- <slot></slot>
14
- </v-tooltip>
15
- </template>
16
-
17
- <script>
18
- export default {
19
- name: 'AppBasePopover',
20
- data() {
21
- return {
22
- show: false,
23
- alertContainer: null
24
- }
25
- },
26
- watch: {
27
- show: {
28
- handler(newValue) {
29
- if (newValue) {
30
- const content = this.$refs.tooltip.contentEl.textContent
31
- this.alertContainer.textContent = ''
32
- this.alertContainer.textContent = content
33
- }
34
- }
35
- }
36
- },
37
- mounted() {
38
- this.alertContainer = document.getElementById('hiddenAlertContainer')
39
- }
40
- }
41
- </script>
1
+ <!--
2
+ @ Description: This component is used to create a popover that is accessible via keyboard navigation (tab + space/enter)
3
+ -->
4
+ <template>
5
+ <v-tooltip
6
+ ref="tooltip"
7
+ v-bind="$attrs"
8
+ v-model="show"
9
+ transition="false"
10
+ :open-on-click="true"
11
+ :persistent="false"
12
+ >
13
+ <slot></slot>
14
+ </v-tooltip>
15
+ </template>
16
+
17
+ <script>
18
+ export default {
19
+ name: 'AppBasePopover',
20
+ data() {
21
+ return {
22
+ show: false,
23
+ alertContainer: null
24
+ }
25
+ },
26
+ watch: {
27
+ show: {
28
+ handler(newValue) {
29
+ if (newValue) {
30
+ const content = this.$refs.tooltip.contentEl.textContent
31
+ this.alertContainer.textContent = ''
32
+ this.alertContainer.textContent = content
33
+ }
34
+ }
35
+ }
36
+ },
37
+ mounted() {
38
+ this.alertContainer = document.getElementById('hiddenAlertContainer')
39
+ }
40
+ }
41
+ </script>
@@ -50,9 +50,9 @@
50
50
  />
51
51
  </div>
52
52
  <div v-if="slide.title || slide.hypertext" class="carousel-text">
53
- <h3 v-if="slide.title">
53
+ <p v-if="slide.title" class="carousel-slide-title">
54
54
  {{ slide.title }}
55
- </h3>
55
+ </p>
56
56
  <div v-html="slide.hypertext"></div>
57
57
  </div>
58
58
  </div>
@@ -1,74 +1,74 @@
1
- <template>
2
- <div v-if="!error" class="box-g" :class="state">
3
- <v-progress-linear
4
- class="jauge"
5
- :model-value="value"
6
- :height="12"
7
- :max="maxValue"
8
- aria-hidden="true"
9
- ></v-progress-linear>
10
- <p class="prcnt">{{ getPourcent }} %</p>
11
- </div>
12
- <div v-else>
13
- <div class="warning">
14
- <p class="title">Attention</p>
15
- <p class="info">
16
- Attention les valeurs que vous donnez au composant ne sont pas des
17
- nombres.
18
- </p>
19
- </div>
20
- </div>
21
- </template>
22
- <script>
23
- export default {
24
- props: {
25
- // props Give value to show progress
26
- state: {
27
- type: String,
28
- default: 'started'
29
- },
30
- maxValue: {
31
- type: Number,
32
- default: 100
33
- },
34
- value: { type: Number, default: 0 },
35
- pourcent: { type: Boolean, default: false },
36
- fraction: { type: Boolean, default: false }
37
- },
38
- data() {
39
- return {}
40
- },
41
- computed: {
42
- getPourcent() {
43
- // Calculate on a 100%
44
- let result = (this.value * 100) / this.maxValue
45
- if (result > 100) return 100
46
- else return Math.round(result)
47
- },
48
- error() {
49
- if (typeof this.value != 'number' || typeof this.maxValue != 'number') {
50
- return true
51
- } else {
52
- return false
53
- }
54
- }
55
- },
56
- methods: {}
57
- }
58
- </script>
59
- <style lang="scss">
60
- .box-g {
61
- width: 100%;
62
- display: flex;
63
- flex-direction: row;
64
- flex-wrap: wrap;
65
-
66
- .jauge {
67
- width: 70%;
68
- }
69
-
70
- .prcnt {
71
- margin-left: 10px;
72
- }
73
- }
74
- </style>
1
+ <template>
2
+ <div v-if="!error" class="box-g" :class="state">
3
+ <v-progress-linear
4
+ class="jauge"
5
+ :model-value="value"
6
+ :height="12"
7
+ :max="maxValue"
8
+ aria-hidden="true"
9
+ ></v-progress-linear>
10
+ <p class="prcnt">{{ getPourcent }} %</p>
11
+ </div>
12
+ <div v-else>
13
+ <div class="warning">
14
+ <p class="title">Attention</p>
15
+ <p class="info">
16
+ Attention les valeurs que vous donnez au composant ne sont pas des
17
+ nombres.
18
+ </p>
19
+ </div>
20
+ </div>
21
+ </template>
22
+ <script>
23
+ export default {
24
+ props: {
25
+ // props Give value to show progress
26
+ state: {
27
+ type: String,
28
+ default: 'started'
29
+ },
30
+ maxValue: {
31
+ type: Number,
32
+ default: 100
33
+ },
34
+ value: { type: Number, default: 0 },
35
+ pourcent: { type: Boolean, default: false },
36
+ fraction: { type: Boolean, default: false }
37
+ },
38
+ data() {
39
+ return {}
40
+ },
41
+ computed: {
42
+ getPourcent() {
43
+ // Calculate on a 100%
44
+ let result = (this.value * 100) / this.maxValue
45
+ if (result > 100) return 100
46
+ else return Math.round(result)
47
+ },
48
+ error() {
49
+ if (typeof this.value != 'number' || typeof this.maxValue != 'number') {
50
+ return true
51
+ } else {
52
+ return false
53
+ }
54
+ }
55
+ },
56
+ methods: {}
57
+ }
58
+ </script>
59
+ <style lang="scss">
60
+ .box-g {
61
+ width: 100%;
62
+ display: flex;
63
+ flex-direction: row;
64
+ flex-wrap: wrap;
65
+
66
+ .jauge {
67
+ width: 70%;
68
+ }
69
+
70
+ .prcnt {
71
+ margin-left: 10px;
72
+ }
73
+ }
74
+ </style>
@@ -1,82 +1,82 @@
1
- <!--@ Description: This component is used to display the playbar associate with the videoPlayer
2
- @ What it does: The component is used to interacted with the videoPlayer via buttons.
3
- v-media class is used to identified which html elements trigger the playBar to be appear (with focus/click)-->
4
- <template>
5
- <!--------------------------------- PLAY-BAR Progress -------------------------------------->
6
- <div ref="$playbar-timeline" class="pb-timeline">
7
- <div ref="$progress-area" class="progress-area">
8
- <div
9
- id="progress-bar"
10
- ref="$progress-bar"
11
- draggable="false"
12
- tabindex="0"
13
- class="v-media pb-progress-bar"
14
- role="slider"
15
- aria-valuemin="0"
16
- :aria-label="mediaA11Y.label"
17
- :aria-valuenow="mediaA11Y.valNow"
18
- :aria-valuemax="mediaA11Y.valMax"
19
- :aria-valuetext="mediaA11Y.valueText"
20
- @focus="changeFocusState('progressBar', true)"
21
- @blur="changeFocusState('progressBar', false)"
22
- >
23
- <!--Class progress-animation is apply when we are not using the thumb to change the progression-->
24
- <div
25
- id="progress-indicator"
26
- ref="$progress-indicator"
27
- draggable="false"
28
- class="progress-indicator"
29
- :class="{ 'progress-animation': !progressThumbDown }"
30
- :style="{ width: progressBarPercentage + '%' }"
31
- >
32
- <!--Mousedown validate if the thumb is cliqued (if yes, the mouse is follow to modify the progress)
33
- MouseOver/MouseOut deactivate click event on progressBar if the mouse hovered the thumb-->
34
- <!-- <div
35
- ref="$progress-thumb"
36
- draggable="false"
37
- class="progress-thumb"
38
- style="z-index: 9"
39
- @mousedown="
40
- savedIsPlaying = isPlaying
41
- progressThumbDown = true
42
- "
43
- @mouseover="progressThumbHover = true"
44
- @mouseleave="progressThumbHover = false"
45
- ></div> -->
46
-
47
- <div
48
- ref="$progress-thumb"
49
- draggable="false"
50
- class="progress-thumb"
51
- style="z-index: 9"
52
- @mouseover="progressThumbHover = true"
53
- @mouseleave="progressThumbHover = false"
54
- ></div>
55
- </div>
56
- </div>
57
- <div
58
- v-if="tooTipTimeCode"
59
- id="seek-tooltip"
60
- ref="$seek-tooltip"
61
- aria-hidden="true"
62
- class="seek-tooltip"
63
- >
64
- {{ tooTipTimeCode }}
65
- </div>
66
- </div>
67
- </div>
68
- </template>
69
-
70
- <script>
71
- import $extendsMedia from '../mixins/$mediaMixins'
72
-
73
- export default {
74
- mixins: [$extendsMedia],
75
- data() {
76
- return {
77
- tooTipTimeCode: null
78
- }
79
- },
80
- mounted() {}
81
- }
82
- </script>
1
+ <!--@ Description: This component is used to display the playbar associate with the videoPlayer
2
+ @ What it does: The component is used to interacted with the videoPlayer via buttons.
3
+ v-media class is used to identified which html elements trigger the playBar to be appear (with focus/click)-->
4
+ <template>
5
+ <!--------------------------------- PLAY-BAR Progress -------------------------------------->
6
+ <div ref="$playbar-timeline" class="pb-timeline">
7
+ <div ref="$progress-area" class="progress-area">
8
+ <div
9
+ id="progress-bar"
10
+ ref="$progress-bar"
11
+ draggable="false"
12
+ tabindex="0"
13
+ class="v-media pb-progress-bar"
14
+ role="slider"
15
+ aria-valuemin="0"
16
+ :aria-label="mediaA11Y.label"
17
+ :aria-valuenow="mediaA11Y.valNow"
18
+ :aria-valuemax="mediaA11Y.valMax"
19
+ :aria-valuetext="mediaA11Y.valueText"
20
+ @focus="changeFocusState('progressBar', true)"
21
+ @blur="changeFocusState('progressBar', false)"
22
+ >
23
+ <!--Class progress-animation is apply when we are not using the thumb to change the progression-->
24
+ <div
25
+ id="progress-indicator"
26
+ ref="$progress-indicator"
27
+ draggable="false"
28
+ class="progress-indicator"
29
+ :class="{ 'progress-animation': !progressThumbDown }"
30
+ :style="{ width: progressBarPercentage + '%' }"
31
+ >
32
+ <!--Mousedown validate if the thumb is cliqued (if yes, the mouse is follow to modify the progress)
33
+ MouseOver/MouseOut deactivate click event on progressBar if the mouse hovered the thumb-->
34
+ <!-- <div
35
+ ref="$progress-thumb"
36
+ draggable="false"
37
+ class="progress-thumb"
38
+ style="z-index: 9"
39
+ @mousedown="
40
+ savedIsPlaying = isPlaying
41
+ progressThumbDown = true
42
+ "
43
+ @mouseover="progressThumbHover = true"
44
+ @mouseleave="progressThumbHover = false"
45
+ ></div> -->
46
+
47
+ <div
48
+ ref="$progress-thumb"
49
+ draggable="false"
50
+ class="progress-thumb"
51
+ style="z-index: 9"
52
+ @mouseover="progressThumbHover = true"
53
+ @mouseleave="progressThumbHover = false"
54
+ ></div>
55
+ </div>
56
+ </div>
57
+ <div
58
+ v-if="tooTipTimeCode"
59
+ id="seek-tooltip"
60
+ ref="$seek-tooltip"
61
+ aria-hidden="true"
62
+ class="seek-tooltip"
63
+ >
64
+ {{ tooTipTimeCode }}
65
+ </div>
66
+ </div>
67
+ </div>
68
+ </template>
69
+
70
+ <script>
71
+ import $extendsMedia from '../mixins/$mediaMixins'
72
+
73
+ export default {
74
+ mixins: [$extendsMedia],
75
+ data() {
76
+ return {
77
+ tooTipTimeCode: null
78
+ }
79
+ },
80
+ mounted() {}
81
+ }
82
+ </script>