@pocketprep/ui-kit 3.9.7 → 3.9.9
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/dist/@pocketprep/ui-kit.css +1 -1
- package/dist/@pocketprep/ui-kit.js +6869 -6846
- package/dist/@pocketprep/ui-kit.js.map +1 -1
- package/dist/@pocketprep/ui-kit.umd.cjs +12 -12
- package/dist/@pocketprep/ui-kit.umd.cjs.map +1 -1
- package/lib/components/Quiz/Question/ChoicesContainer.vue +3 -0
- package/lib/components/Quiz/Question/DropdownExplanation.vue +8 -0
- package/lib/components/Quiz/Question/MatrixChoicesContainer.vue +7 -2
- package/lib/components/Quiz/Question/MobileMatrixChoicesContainer.vue +15 -2
- package/lib/components/Quiz/Question.vue +10 -0
- package/lib/components/Quiz/QuizContainer.vue +1 -0
- package/package.json +1 -1
|
@@ -168,6 +168,9 @@
|
|
|
168
168
|
<template #explanationBottomExperiment>
|
|
169
169
|
<slot name="explanationBottomExperiment" />
|
|
170
170
|
</template>
|
|
171
|
+
<template #tutorChatExplanationPrompts>
|
|
172
|
+
<slot name="tutorChatExplanationPrompts" />
|
|
173
|
+
</template>
|
|
171
174
|
</DropdownExplanation>
|
|
172
175
|
</div>
|
|
173
176
|
<template v-if="!globalMetrics">
|
|
@@ -58,6 +58,13 @@
|
|
|
58
58
|
tabindex="-1"
|
|
59
59
|
v-html="explanationImageLongAlt"
|
|
60
60
|
/>
|
|
61
|
+
<div
|
|
62
|
+
v-if="showTutorChatExplanationPrompts"
|
|
63
|
+
v-dark="isDarkMode"
|
|
64
|
+
class="uikit-question-dropdown-explanation__tutor-chat-prompts"
|
|
65
|
+
>
|
|
66
|
+
<slot name="tutorChatExplanationPrompts" />
|
|
67
|
+
</div>
|
|
61
68
|
<div
|
|
62
69
|
v-if="reference && !hideReferences"
|
|
63
70
|
v-dark="isDarkMode"
|
|
@@ -98,6 +105,7 @@ const {
|
|
|
98
105
|
breakpointsWithEl,
|
|
99
106
|
keywordDefinitions,
|
|
100
107
|
showRightSideBar,
|
|
108
|
+
showTutorChatExplanationPrompts,
|
|
101
109
|
} = useQuestionContext()
|
|
102
110
|
|
|
103
111
|
const explanation = computed(() => {
|
|
@@ -214,6 +214,7 @@ const {
|
|
|
214
214
|
matrixAnswerKeys,
|
|
215
215
|
selectedMatrixChoices,
|
|
216
216
|
isTeachGroupReview,
|
|
217
|
+
showRightSideBar,
|
|
217
218
|
} = useQuestionContext()
|
|
218
219
|
|
|
219
220
|
const matrixCheckboxGrid = ref<boolean[][] | undefined>(undefined)
|
|
@@ -427,12 +428,16 @@ watch(matrixRadioGrid, () => {
|
|
|
427
428
|
}, { deep: true })
|
|
428
429
|
|
|
429
430
|
watch(selectedMatrixChoices, () => {
|
|
430
|
-
if (
|
|
431
|
+
if (
|
|
432
|
+
((reviewMode.value || showMatrixAnswers.value) || showRightSideBar)
|
|
433
|
+
&& question.value.type === 'Matrix Checkbox') {
|
|
431
434
|
const selectedCheckboxGrid = convertSelectedMatrixChoiceToCheckboxGrid()
|
|
432
435
|
matrixCheckboxGrid.value = selectedCheckboxGrid ? selectedCheckboxGrid : defaultCheckboxGrid.value
|
|
433
436
|
}
|
|
434
437
|
|
|
435
|
-
if (
|
|
438
|
+
if (
|
|
439
|
+
((reviewMode.value || showMatrixAnswers.value) || showRightSideBar)
|
|
440
|
+
&& question.value.type === 'Matrix Radio Button') {
|
|
436
441
|
const selectedRadioBtnGrid = convertSelectedMatrixChoiceToRadioBtnGrid()
|
|
437
442
|
matrixRadioGrid.value = selectedRadioBtnGrid
|
|
438
443
|
}
|
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
<div
|
|
3
3
|
v-dark="isDarkMode"
|
|
4
4
|
class="uikit-question-mobile-matrix-choices-container"
|
|
5
|
+
:class="{
|
|
6
|
+
'uikit-question-mobile-matrix-choices-container--is-showing-right-side-bar':
|
|
7
|
+
showRightSideBar,
|
|
8
|
+
}"
|
|
5
9
|
>
|
|
6
10
|
<div
|
|
7
11
|
class="uikit-question-mobile-matrix-choices-container__choices-container"
|
|
@@ -178,6 +182,7 @@ const {
|
|
|
178
182
|
showMatrixAnswers,
|
|
179
183
|
matrixAnswerKeys,
|
|
180
184
|
selectedMatrixChoices,
|
|
185
|
+
showRightSideBar,
|
|
181
186
|
} = useQuestionContext()
|
|
182
187
|
|
|
183
188
|
const matrixCheckboxGrid = ref<boolean[][] | undefined>(undefined)
|
|
@@ -520,12 +525,16 @@ watch(showMatrixAnswers, () => {
|
|
|
520
525
|
})
|
|
521
526
|
|
|
522
527
|
watch(selectedMatrixChoices, () => {
|
|
523
|
-
if (
|
|
528
|
+
if (
|
|
529
|
+
((reviewMode.value || showMatrixAnswers.value) || showRightSideBar)
|
|
530
|
+
&& question.value.type === 'Matrix Checkbox') {
|
|
524
531
|
const selectedCheckboxGrid = convertSelectedMatrixChoiceToCheckboxGrid()
|
|
525
532
|
matrixCheckboxGrid.value = selectedCheckboxGrid ? selectedCheckboxGrid : defaultCheckboxGrid.value
|
|
526
533
|
}
|
|
527
534
|
|
|
528
|
-
if (
|
|
535
|
+
if (
|
|
536
|
+
((reviewMode.value || showMatrixAnswers.value) || showRightSideBar)
|
|
537
|
+
&& question.value.type === 'Matrix Radio Button') {
|
|
529
538
|
const selectedRadioBtnGrid = convertSelectedMatrixChoiceToRadioBtnGrid()
|
|
530
539
|
matrixRadioGrid.value = selectedRadioBtnGrid
|
|
531
540
|
}
|
|
@@ -544,6 +553,10 @@ watch(selectedMatrixChoices, () => {
|
|
|
544
553
|
display: none
|
|
545
554
|
}
|
|
546
555
|
|
|
556
|
+
&--is-showing-right-side-bar#{&}--tablet-portrait {
|
|
557
|
+
display: block;
|
|
558
|
+
}
|
|
559
|
+
|
|
547
560
|
&__choices-container {
|
|
548
561
|
cursor: pointer;
|
|
549
562
|
position: relative;
|
|
@@ -213,10 +213,16 @@
|
|
|
213
213
|
<template #explanationBottomExperiment>
|
|
214
214
|
<slot name="explanationBottomExperiment" />
|
|
215
215
|
</template>
|
|
216
|
+
<template #tutorChatExplanationPrompts>
|
|
217
|
+
<slot name="tutorChatExplanationPrompts" />
|
|
218
|
+
</template>
|
|
216
219
|
</ChoicesContainer>
|
|
217
220
|
<MatrixChoicesContainer
|
|
218
221
|
v-if="question.type === 'Matrix Checkbox' || question.type === 'Matrix Radio Button'"
|
|
219
222
|
class="uikit-question__matrix-choices-container"
|
|
223
|
+
:class="{
|
|
224
|
+
'uikit-question__matrix-choices-container--right-side-bar-open': showRightSideBar,
|
|
225
|
+
}"
|
|
220
226
|
ref="uikit-question__matrix-choices-container"
|
|
221
227
|
v-breakpoint="breakpointsWithEl"
|
|
222
228
|
@emitSelectedMatrixChoice="selectMatrixChoice"
|
|
@@ -2281,6 +2287,10 @@ provide(InjectionKeys.showTutorChatExplanationPromptsKey, showTutorChatExplanati
|
|
|
2281
2287
|
&__matrix-choices-container {
|
|
2282
2288
|
display: block;
|
|
2283
2289
|
|
|
2290
|
+
&--right-side-bar-open#{&}--tablet-portrait {
|
|
2291
|
+
display: none;
|
|
2292
|
+
}
|
|
2293
|
+
|
|
2284
2294
|
@include breakpoint(black-bear) {
|
|
2285
2295
|
display: none;
|
|
2286
2296
|
}
|