@pocketprep/ui-kit 3.4.51 → 3.4.52
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.js +9 -6
- package/dist/@pocketprep/ui-kit.js.map +1 -1
- package/dist/@pocketprep/ui-kit.umd.cjs +1 -1
- package/dist/@pocketprep/ui-kit.umd.cjs.map +1 -1
- package/dist/style.css +1 -1
- package/lib/components/Quiz/Question.vue +73 -3
- package/lib/components/Quiz/QuizContainer.vue +15 -1
- package/package.json +1 -1
|
@@ -739,9 +739,12 @@ export default class Question extends Vue {
|
|
|
739
739
|
if (target.classList.contains('keyword-highlight')) {
|
|
740
740
|
const keyword = target.innerHTML
|
|
741
741
|
const location = target.getAttribute('data-location')
|
|
742
|
+
const clickLocation = { x: event.clientX, y: event.clientY }
|
|
742
743
|
return {
|
|
743
744
|
keyword,
|
|
744
745
|
location,
|
|
746
|
+
clickLocation,
|
|
747
|
+
target,
|
|
745
748
|
}
|
|
746
749
|
}
|
|
747
750
|
}
|
|
@@ -1311,13 +1314,80 @@ export default class Question extends Vue {
|
|
|
1311
1314
|
}
|
|
1312
1315
|
}
|
|
1313
1316
|
|
|
1317
|
+
.keyword-highlight--dark.keyword-highlight--active {
|
|
1318
|
+
height: 22px;
|
|
1319
|
+
background-color: rgba($banana-bread, 0.4);
|
|
1320
|
+
border-bottom: none;
|
|
1321
|
+
border-radius: 2px;
|
|
1322
|
+
|
|
1323
|
+
&[data-location="explanation"] {
|
|
1324
|
+
height: 20px;
|
|
1325
|
+
background-color: rgba($banana-bread, 0.4);
|
|
1326
|
+
}
|
|
1327
|
+
}
|
|
1328
|
+
|
|
1314
1329
|
.keyword-highlight {
|
|
1315
|
-
|
|
1316
|
-
|
|
1330
|
+
box-sizing: border-box;
|
|
1331
|
+
background-color: rgba($banana-bread, 0.25);
|
|
1332
|
+
border-radius: 2px 2px 0 0;
|
|
1333
|
+
border-bottom: 1.5px solid $banana-bread;
|
|
1334
|
+
height: 21px;
|
|
1335
|
+
line-height: 22px;
|
|
1336
|
+
padding: 0 2px 0 1px;
|
|
1337
|
+
margin: 0 -2px 0 -1px;
|
|
1317
1338
|
cursor: pointer;
|
|
1339
|
+
|
|
1340
|
+
&[data-location="explanation"] {
|
|
1341
|
+
height: 20px;
|
|
1342
|
+
line-height: 21px;
|
|
1343
|
+
background-color: $manilla;
|
|
1344
|
+
border-radius: 1px 1px 0 0;
|
|
1345
|
+
}
|
|
1346
|
+
|
|
1347
|
+
&:hover:not(&--active) {
|
|
1348
|
+
background-color: rgba($banana-bread, 0.4);
|
|
1349
|
+
border-color: $butterscotch;
|
|
1350
|
+
|
|
1351
|
+
&[data-location="explanation"] {
|
|
1352
|
+
background-color: $buttermilk;
|
|
1353
|
+
border-radius: 2px 2px 0 0;
|
|
1354
|
+
}
|
|
1355
|
+
}
|
|
1356
|
+
|
|
1357
|
+
&--active {
|
|
1358
|
+
height: 22px;
|
|
1359
|
+
line-height: 23px;
|
|
1360
|
+
background-color: $beach-sand;
|
|
1361
|
+
border-bottom: none;
|
|
1362
|
+
border-radius: 2px;
|
|
1363
|
+
|
|
1364
|
+
&[data-location="explanation"] {
|
|
1365
|
+
height: 20px;
|
|
1366
|
+
line-height: 21px;
|
|
1367
|
+
background-color: $beach-sand;
|
|
1368
|
+
border-radius: 2px;
|
|
1369
|
+
}
|
|
1370
|
+
}
|
|
1318
1371
|
|
|
1319
1372
|
&--dark {
|
|
1320
|
-
|
|
1373
|
+
color: $white;
|
|
1374
|
+
background-color: rgba($banana-bread, 0.3);
|
|
1375
|
+
border-color: rgba($banana-bread, 0.6);
|
|
1376
|
+
|
|
1377
|
+
&[data-location="explanation"] {
|
|
1378
|
+
background-color: rgba($banana-bread, 0.3);
|
|
1379
|
+
border-color: rgba($banana-bread, 0.6);
|
|
1380
|
+
}
|
|
1381
|
+
|
|
1382
|
+
&:hover:not(&--active) {
|
|
1383
|
+
background-color: rgba($banana-bread, 0.4);
|
|
1384
|
+
border-color: rgba($banana-bread, 0.8);
|
|
1385
|
+
|
|
1386
|
+
&[data-location="explanation"] {
|
|
1387
|
+
background-color: rgba($banana-bread, 0.4);
|
|
1388
|
+
border-color: rgba($banana-bread, 0.8);
|
|
1389
|
+
}
|
|
1390
|
+
}
|
|
1321
1391
|
}
|
|
1322
1392
|
}
|
|
1323
1393
|
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
<div
|
|
9
9
|
v-breakpoint:quizContainerEl
|
|
10
10
|
class="uikit-quiz-container__header"
|
|
11
|
+
:class="{'uikit-quiz-container__header--dark': isDarkMode}"
|
|
11
12
|
:style="customHeaderStyles"
|
|
12
13
|
>
|
|
13
14
|
<slot name="header" />
|
|
@@ -19,6 +20,7 @@
|
|
|
19
20
|
v-dark="isDarkMode"
|
|
20
21
|
class="uikit-quiz-container__side"
|
|
21
22
|
>
|
|
23
|
+
<slot name="definition"></slot>
|
|
22
24
|
<slot name="side" />
|
|
23
25
|
</div>
|
|
24
26
|
<div
|
|
@@ -35,6 +37,7 @@
|
|
|
35
37
|
<div
|
|
36
38
|
v-breakpoint:quizContainerEl
|
|
37
39
|
class="uikit-quiz-container__footer"
|
|
40
|
+
:class="{'uikit-quiz-container__footer--dark': isDarkMode}"
|
|
38
41
|
:style="customFooterStyles"
|
|
39
42
|
>
|
|
40
43
|
<slot name="footer" />
|
|
@@ -117,6 +120,8 @@ export default class QuizContainer extends Vue {
|
|
|
117
120
|
width: 100%;
|
|
118
121
|
height: 65px;
|
|
119
122
|
color: $white;
|
|
123
|
+
background-color: $brand-black;
|
|
124
|
+
z-index: 4;
|
|
120
125
|
position: relative;
|
|
121
126
|
|
|
122
127
|
&--mobile {
|
|
@@ -124,6 +129,10 @@ export default class QuizContainer extends Vue {
|
|
|
124
129
|
padding: 0 10px;
|
|
125
130
|
box-sizing: border-box;
|
|
126
131
|
}
|
|
132
|
+
|
|
133
|
+
&--dark {
|
|
134
|
+
background-color: $jet;
|
|
135
|
+
}
|
|
127
136
|
}
|
|
128
137
|
|
|
129
138
|
&__main {
|
|
@@ -143,7 +152,6 @@ export default class QuizContainer extends Vue {
|
|
|
143
152
|
height: 100%;
|
|
144
153
|
margin-right: 23px;
|
|
145
154
|
border-radius: 6px;
|
|
146
|
-
z-index: 2;
|
|
147
155
|
|
|
148
156
|
&--dark {
|
|
149
157
|
background-color: $mariner;
|
|
@@ -198,6 +206,12 @@ export default class QuizContainer extends Vue {
|
|
|
198
206
|
width: 100%;
|
|
199
207
|
height: 65px;
|
|
200
208
|
color: $white;
|
|
209
|
+
background-color: $brand-black;
|
|
210
|
+
z-index: 3;
|
|
211
|
+
|
|
212
|
+
&--dark {
|
|
213
|
+
background-color: $jet;
|
|
214
|
+
}
|
|
201
215
|
|
|
202
216
|
&--mobile {
|
|
203
217
|
height: 54px;
|