@digabi/exam-engine-core 23.2.1 → 23.2.2-alpha.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (90) hide show
  1. package/dist/__tests__/tsconfig.tsbuildinfo +1 -1
  2. package/dist/components/context/AnnotationProvider.d.ts +1 -1
  3. package/dist/components/exam/DNDAnswerContainer.d.ts +1 -3
  4. package/dist/components/exam/DNDAnswerContainer.d.ts.map +1 -1
  5. package/dist/components/exam/DNDAnswerContainer.js +1 -24
  6. package/dist/components/exam/DNDAnswerContainer.js.map +1 -1
  7. package/dist/components/grading-instructions/AutogradedAnswerOption.d.ts.map +1 -1
  8. package/dist/components/grading-instructions/AutogradedAnswerOption.js +2 -1
  9. package/dist/components/grading-instructions/AutogradedAnswerOption.js.map +1 -1
  10. package/dist/components/grading-instructions/GradingInstructions.d.ts.map +1 -1
  11. package/dist/components/grading-instructions/GradingInstructions.js +5 -1
  12. package/dist/components/grading-instructions/GradingInstructions.js.map +1 -1
  13. package/dist/components/grading-instructions/Recording.d.ts.map +1 -1
  14. package/dist/components/grading-instructions/Recording.js +3 -2
  15. package/dist/components/grading-instructions/Recording.js.map +1 -1
  16. package/dist/components/results/Results.js +2 -2
  17. package/dist/components/results/Results.js.map +1 -1
  18. package/dist/components/shared/DNDAnswerContainer.d.ts +6 -0
  19. package/dist/components/shared/DNDAnswerContainer.d.ts.map +1 -0
  20. package/dist/components/shared/DNDAnswerContainer.js +23 -0
  21. package/dist/components/shared/DNDAnswerContainer.js.map +1 -0
  22. package/dist/components/shared/DNDDroppable.d.ts +2 -2
  23. package/dist/components/shared/DNDDroppable.d.ts.map +1 -1
  24. package/dist/components/shared/DNDTitleAndDroppable.d.ts +2 -2
  25. package/dist/components/shared/DNDTitleAndDroppable.d.ts.map +1 -1
  26. package/dist/components/shared/DNDTitleAndDroppable.js +3 -1
  27. package/dist/components/shared/DNDTitleAndDroppable.js.map +1 -1
  28. package/dist/dom-utils.d.ts +6 -0
  29. package/dist/dom-utils.d.ts.map +1 -1
  30. package/dist/dom-utils.js +36 -0
  31. package/dist/dom-utils.js.map +1 -1
  32. package/dist/main-bundle.js +2 -2
  33. package/dist/main-bundle.js.LICENSE.txt +3 -3
  34. package/dist/types/ExamAnswer.d.ts +1 -0
  35. package/dist/types/ExamAnswer.d.ts.map +1 -1
  36. package/package.json +2 -2
  37. package/dist/__tests__/playwright/DNDAnswerContainer.test.d.ts +0 -2
  38. package/dist/__tests__/playwright/DNDAnswerContainer.test.d.ts.map +0 -1
  39. package/dist/__tests__/playwright/DNDAnswerContainer.test.js +0 -77
  40. package/dist/__tests__/playwright/DNDAnswerContainer.test.js.map +0 -1
  41. package/dist/__tests__/playwright/stories/DNDAnswerContainer.story.d.ts +0 -10
  42. package/dist/__tests__/playwright/stories/DNDAnswerContainer.story.d.ts.map +0 -1
  43. package/dist/__tests__/playwright/stories/DNDAnswerContainer.story.js +0 -21
  44. package/dist/__tests__/playwright/stories/DNDAnswerContainer.story.js.map +0 -1
  45. package/dist/__tests__/playwright/utils/ComponentWrapper.d.ts +0 -9
  46. package/dist/__tests__/playwright/utils/ComponentWrapper.d.ts.map +0 -1
  47. package/dist/__tests__/playwright/utils/ComponentWrapper.js +0 -26
  48. package/dist/__tests__/playwright/utils/ComponentWrapper.js.map +0 -1
  49. package/dist/assets/closeButton.svg +0 -1
  50. package/dist/assets/collapse.svg +0 -12
  51. package/dist/assets/expand.svg +0 -12
  52. package/dist/assets/helpButton.svg +0 -9
  53. package/dist/assets/redoButton.svg +0 -5
  54. package/dist/assets/undoButton.svg +0 -5
  55. package/dist/components/exam/AllDNDOptions.d.ts +0 -9
  56. package/dist/components/exam/AllDNDOptions.d.ts.map +0 -1
  57. package/dist/components/exam/AllDNDOptions.js +0 -12
  58. package/dist/components/exam/AllDNDOptions.js.map +0 -1
  59. package/dist/components/exam/DNDAnswer.d.ts +0 -20
  60. package/dist/components/exam/DNDAnswer.d.ts.map +0 -1
  61. package/dist/components/exam/DNDAnswer.js +0 -7
  62. package/dist/components/exam/DNDAnswer.js.map +0 -1
  63. package/dist/components/exam/DNDAnswerOption.d.ts +0 -4
  64. package/dist/components/exam/DNDAnswerOption.d.ts.map +0 -1
  65. package/dist/components/exam/DNDAnswerOption.js +0 -18
  66. package/dist/components/exam/DNDAnswerOption.js.map +0 -1
  67. package/dist/components/results/AudioPlaceholder.d.ts +0 -4
  68. package/dist/components/results/AudioPlaceholder.d.ts.map +0 -1
  69. package/dist/components/results/AudioPlaceholder.js +0 -25
  70. package/dist/components/results/AudioPlaceholder.js.map +0 -1
  71. package/dist/components/results/DNDAnswer.d.ts +0 -12
  72. package/dist/components/results/DNDAnswer.d.ts.map +0 -1
  73. package/dist/components/results/DNDAnswer.js +0 -21
  74. package/dist/components/results/DNDAnswer.js.map +0 -1
  75. package/dist/components/shared/DNDAnswerCommon.d.ts +0 -13
  76. package/dist/components/shared/DNDAnswerCommon.d.ts.map +0 -1
  77. package/dist/components/shared/DNDAnswerCommon.js +0 -30
  78. package/dist/components/shared/DNDAnswerCommon.js.map +0 -1
  79. package/dist/components/shared/DNDAnswerDroppable.d.ts +0 -13
  80. package/dist/components/shared/DNDAnswerDroppable.d.ts.map +0 -1
  81. package/dist/components/shared/DNDAnswerDroppable.js +0 -30
  82. package/dist/components/shared/DNDAnswerDroppable.js.map +0 -1
  83. package/dist/components/shared/DNDAnswerOptionCommon.d.ts +0 -7
  84. package/dist/components/shared/DNDAnswerOptionCommon.d.ts.map +0 -1
  85. package/dist/components/shared/DNDAnswerOptionCommon.js +0 -14
  86. package/dist/components/shared/DNDAnswerOptionCommon.js.map +0 -1
  87. package/dist/components/shared/DNDTitleAndAnswerCommon.d.ts +0 -13
  88. package/dist/components/shared/DNDTitleAndAnswerCommon.d.ts.map +0 -1
  89. package/dist/components/shared/DNDTitleAndAnswerCommon.js +0 -27
  90. package/dist/components/shared/DNDTitleAndAnswerCommon.js.map +0 -1
@@ -23,7 +23,7 @@
23
23
  */
24
24
 
25
25
  /*!
26
- * focus-trap 7.6.0
26
+ * focus-trap 7.6.2
27
27
  * @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
28
28
  */
29
29
 
@@ -54,9 +54,9 @@
54
54
 
55
55
  /**
56
56
  * @license React
57
- * use-sync-external-store-with-selector.production.min.js
57
+ * use-sync-external-store-with-selector.production.js
58
58
  *
59
- * Copyright (c) Facebook, Inc. and its affiliates.
59
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
60
60
  *
61
61
  * This source code is licensed under the MIT license found in the
62
62
  * LICENSE file in the root directory of this source tree.
@@ -1,4 +1,5 @@
1
1
  export type QuestionId = number;
2
+ export type ExamPage = 'exam' | 'results' | 'grading-instructions';
2
3
  interface AnswerCommon {
3
4
  questionId: QuestionId;
4
5
  value: string;
@@ -1 +1 @@
1
- {"version":3,"file":"ExamAnswer.d.ts","sourceRoot":"","sources":["../../src/types/ExamAnswer.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,UAAU,GAAG,MAAM,CAAA;AAE/B,UAAU,YAAY;IACpB,UAAU,EAAE,UAAU,CAAA;IACtB,KAAK,EAAE,MAAM,CAAA;IACb,oFAAoF;IACpF,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B;AAED,MAAM,WAAW,UAAW,SAAQ,YAAY;IAC9C,IAAI,EAAE,MAAM,CAAA;IACZ,cAAc,EAAE,MAAM,CAAA;CACvB;AAED,MAAM,WAAW,cAAe,SAAQ,YAAY;IAClD,IAAI,EAAE,UAAU,CAAA;IAChB,cAAc,EAAE,MAAM,CAAA;CACvB;AAED,MAAM,WAAW,YAAa,SAAQ,YAAY;IAChD,IAAI,EAAE,QAAQ,CAAA;CACf;AAED,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,cAAc,GAAG,YAAY,CAAA"}
1
+ {"version":3,"file":"ExamAnswer.d.ts","sourceRoot":"","sources":["../../src/types/ExamAnswer.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,UAAU,GAAG,MAAM,CAAA;AAE/B,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,SAAS,GAAG,sBAAsB,CAAA;AAElE,UAAU,YAAY;IACpB,UAAU,EAAE,UAAU,CAAA;IACtB,KAAK,EAAE,MAAM,CAAA;IACb,oFAAoF;IACpF,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B;AAED,MAAM,WAAW,UAAW,SAAQ,YAAY;IAC9C,IAAI,EAAE,MAAM,CAAA;IACZ,cAAc,EAAE,MAAM,CAAA;CACvB;AAED,MAAM,WAAW,cAAe,SAAQ,YAAY;IAClD,IAAI,EAAE,UAAU,CAAA;IAChB,cAAc,EAAE,MAAM,CAAA;CACvB;AAED,MAAM,WAAW,YAAa,SAAQ,YAAY;IAChD,IAAI,EAAE,QAAQ,CAAA;CACf;AAED,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,cAAc,GAAG,YAAY,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digabi/exam-engine-core",
3
- "version": "23.2.1",
3
+ "version": "23.2.2-alpha.1",
4
4
  "main": "dist/main-bundle.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "author": "Matriculation Examination Board, Finland",
@@ -59,5 +59,5 @@
59
59
  "webpack-bundle-analyzer": "^4.1.0",
60
60
  "webpack-cli": "^5.0.2"
61
61
  },
62
- "gitHead": "c8731ad5a91fe32e8782825b4cef39eb0ff1e29f"
62
+ "gitHead": "bee46ef601846818c68caf4f165feb38797476e3"
63
63
  }
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=DNDAnswerContainer.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerContainer.test.d.ts","sourceRoot":"","sources":["../../../__tests__/playwright/DNDAnswerContainer.test.tsx"],"names":[],"mappings":""}
@@ -1,77 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- const react_1 = __importDefault(require("react"));
7
- const fs_1 = require("fs");
8
- const path_1 = __importDefault(require("path"));
9
- const experimental_ct_react_1 = require("@playwright/experimental-ct-react");
10
- const exam_engine_exams_1 = require("@digabi/exam-engine-exams");
11
- const exam_engine_mastering_1 = require("@digabi/exam-engine-mastering");
12
- const DNDAnswerContainer_story_1 = require("./stories/DNDAnswerContainer.story");
13
- experimental_ct_react_1.test.describe('DNDAnswerContainer', () => {
14
- let masteredExam;
15
- experimental_ct_react_1.test.beforeAll(async () => {
16
- masteredExam = await setupMasteredExam();
17
- });
18
- for (const answerMediaType of ['text', 'image']) {
19
- (0, experimental_ct_react_1.test)(`Connect - basic drag and drop functionality for ${answerMediaType} answers`, async ({ mount }) => {
20
- const component = await mount(react_1.default.createElement(DNDAnswerContainer_story_1.DNDAnswerContainerStory, { masteredExam: masteredExam, answerMediaType: answerMediaType }));
21
- const { answerContainer, answerOptionsLocator, firstAnswerLocator, secondAnswerLocator, firstAnswerContent, secondAnswerContent } = await setupAnswerContext(component, answerMediaType);
22
- await experimental_ct_react_1.test.step('Drag first answer to answer container', async () => {
23
- const draggableLocator = firstAnswerLocator.locator('.drag-handle');
24
- await draggableLocator.dragTo(answerContainer);
25
- await assertContentMatches(answerContainer, firstAnswerContent, answerMediaType);
26
- });
27
- await experimental_ct_react_1.test.step('Replace first answer with second answer in answer container', async () => {
28
- const draggableLocator = secondAnswerLocator.locator('.drag-handle');
29
- await draggableLocator.dragTo(answerContainer);
30
- await assertContentMatches(answerContainer, secondAnswerContent, answerMediaType);
31
- });
32
- await experimental_ct_react_1.test.step('Drag second answer back to options', async () => {
33
- const draggableLocator = answerContainer.locator('.drag-handle');
34
- await draggableLocator.dragTo(answerOptionsLocator);
35
- await (0, experimental_ct_react_1.expect)(answerContainer).toContainText('Ei vastausta');
36
- });
37
- });
38
- }
39
- });
40
- async function setupMasteredExam() {
41
- const examPath = (0, exam_engine_exams_1.resolveExam)('SC/SC.xml');
42
- const resolveAttachment = (filename) => path_1.default.resolve(path_1.default.dirname(examPath), 'attachments', filename);
43
- const examXml = (0, fs_1.readFileSync)(examPath, 'utf-8');
44
- const [masteredExam] = await (0, exam_engine_mastering_1.masterExam)(examXml, () => '', (0, exam_engine_mastering_1.getMediaMetadataFromLocalFile)(resolveAttachment), {
45
- removeCorrectAnswers: true
46
- });
47
- return masteredExam;
48
- }
49
- async function assertContentMatches(answerContainer, content, mediaType) {
50
- if (mediaType === 'text') {
51
- await (0, experimental_ct_react_1.expect)(answerContainer).toContainText(content);
52
- }
53
- else if (mediaType === 'image') {
54
- await (0, experimental_ct_react_1.expect)(answerContainer.locator('img')).toHaveAttribute('src', content);
55
- }
56
- }
57
- async function setupAnswerContext(component, answerMediaType) {
58
- const answerContainer = component.getByTestId('dnd-droppable').first();
59
- const answerOptionsLocator = component.getByTestId('dnd-droppable').last();
60
- const firstAnswerLocator = component.getByTestId('dnd-answer-option').nth(0);
61
- const secondAnswerLocator = component.getByTestId('dnd-answer-option').nth(1);
62
- const firstAnswerContent = answerMediaType === 'text'
63
- ? await firstAnswerLocator.textContent()
64
- : await firstAnswerLocator.locator('img').getAttribute('src');
65
- const secondAnswerContent = answerMediaType === 'text'
66
- ? await secondAnswerLocator.textContent()
67
- : await secondAnswerLocator.locator('img').getAttribute('src');
68
- return {
69
- answerContainer,
70
- answerOptionsLocator,
71
- firstAnswerLocator,
72
- secondAnswerLocator,
73
- firstAnswerContent: firstAnswerContent,
74
- secondAnswerContent: secondAnswerContent
75
- };
76
- }
77
- //# sourceMappingURL=DNDAnswerContainer.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerContainer.test.js","sourceRoot":"","sources":["../../../__tests__/playwright/DNDAnswerContainer.test.tsx"],"names":[],"mappings":"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"}
@@ -1,10 +0,0 @@
1
- import React from 'react';
2
- import { MasteringResult } from '@digabi/exam-engine-mastering';
3
- export type answerMediaType = 'text' | 'image';
4
- interface DNDAnswerContainerStoryProps {
5
- masteredExam: MasteringResult;
6
- answerMediaType: answerMediaType;
7
- }
8
- export declare const DNDAnswerContainerStory: React.FC<DNDAnswerContainerStoryProps>;
9
- export {};
10
- //# sourceMappingURL=DNDAnswerContainer.story.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerContainer.story.d.ts","sourceRoot":"","sources":["../../../../__tests__/playwright/stories/DNDAnswerContainer.story.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAA;AAO/D,MAAM,MAAM,eAAe,GAAG,MAAM,GAAG,OAAO,CAAA;AAE9C,UAAU,4BAA4B;IACpC,YAAY,EAAE,eAAe,CAAA;IAC7B,eAAe,EAAE,eAAe,CAAA;CACjC;AAED,eAAO,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAAC,4BAA4B,CAc1E,CAAA"}
@@ -1,21 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.DNDAnswerContainerStory = void 0;
7
- /* eslint-disable @typescript-eslint/no-unsafe-assignment */
8
- const react_1 = __importDefault(require("react"));
9
- const Exam_1 = require("../../../src/components/exam/Exam");
10
- const DNDAnswerContainer_1 = require("../../../src/components/exam/DNDAnswerContainer");
11
- const ComponentWrapper_1 = require("../utils/ComponentWrapper");
12
- const parseExam_1 = __importDefault(require("../../../src/parser/parseExam"));
13
- const dom_utils_1 = require("../../../src/dom-utils");
14
- const DNDAnswerContainerStory = ({ masteredExam, answerMediaType }) => {
15
- const doc = (0, parseExam_1.default)(masteredExam.xml, true);
16
- const [textAnswers, imageAnswers] = (0, dom_utils_1.queryAll)(doc.documentElement, 'dnd-answer-container');
17
- return (react_1.default.createElement(ComponentWrapper_1.ComponentWrapper, { doc: doc, resolveAttachment: (filename) => `/${masteredExam.examCode}/attachments/${filename}` },
18
- react_1.default.createElement(DNDAnswerContainer_1.DNDAnswerContainer, { element: answerMediaType === 'text' ? textAnswers : imageAnswers, renderChildNodes: Exam_1.renderChildNodes })));
19
- };
20
- exports.DNDAnswerContainerStory = DNDAnswerContainerStory;
21
- //# sourceMappingURL=DNDAnswerContainer.story.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerContainer.story.js","sourceRoot":"","sources":["../../../../__tests__/playwright/stories/DNDAnswerContainer.story.tsx"],"names":[],"mappings":";;;;;;AAAA,4DAA4D;AAC5D,kDAAyB;AAEzB,4DAAoE;AACpE,wFAAoF;AACpF,gEAA4D;AAC5D,8EAAqD;AACrD,sDAAiD;AAS1C,MAAM,uBAAuB,GAA2C,CAAC,EAAE,YAAY,EAAE,eAAe,EAAE,EAAE,EAAE;IACnH,MAAM,GAAG,GAAG,IAAA,mBAAS,EAAC,YAAY,CAAC,GAAG,EAAE,IAAI,CAAC,CAAA;IAC7C,MAAM,CAAC,WAAW,EAAE,YAAY,CAAC,GAAG,IAAA,oBAAQ,EAAC,GAAG,CAAC,eAAe,EAAE,sBAAsB,CAAC,CAAA;IACzF,OAAO,CACL,8BAAC,mCAAgB,IACf,GAAG,EAAE,GAAG,EACR,iBAAiB,EAAE,CAAC,QAAgB,EAAE,EAAE,CAAC,IAAI,YAAY,CAAC,QAAQ,gBAAgB,QAAQ,EAAE;QAE5F,8BAAC,uCAAkB,IACjB,OAAO,EAAE,eAAe,KAAK,MAAM,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,YAAY,EAChE,gBAAgB,EAAE,uBAAgB,GACd,CACL,CACpB,CAAA;AACH,CAAC,CAAA;AAdY,QAAA,uBAAuB,2BAcnC"}
@@ -1,9 +0,0 @@
1
- import React from 'react';
2
- import { CommonExamProps } from '../../../src/components/exam/Exam';
3
- import '../../../src/css/main.less';
4
- export interface ComponentWrapperProps extends CommonExamProps {
5
- doc: XMLDocument;
6
- children: React.ReactElement;
7
- }
8
- export declare const ComponentWrapper: React.ComponentType<any>;
9
- //# sourceMappingURL=ComponentWrapper.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ComponentWrapper.d.ts","sourceRoot":"","sources":["../../../../__tests__/playwright/utils/ComponentWrapper.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAUzB,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAA;AACnE,OAAO,4BAA4B,CAAA;AAEnC,MAAM,WAAW,qBAAsB,SAAQ,eAAe;IAC5D,GAAG,EAAE,WAAW,CAAA;IAChB,QAAQ,EAAE,KAAK,CAAC,YAAY,CAAA;CAC7B;AAeD,eAAO,MAAM,gBAAgB,0BAA2D,CAAA"}
@@ -1,26 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.ComponentWrapper = void 0;
7
- const react_1 = __importDefault(require("react"));
8
- const react_redux_1 = require("react-redux");
9
- const react_i18next_1 = require("react-i18next");
10
- const store_1 = require("../../../src/store");
11
- const parseExamStructure_1 = require("../../../src/parser/parseExamStructure");
12
- const useCached_1 = require("../../../src/useCached");
13
- const examServerApi_1 = require("../../examServerApi");
14
- const i18n_1 = require("../../../src/i18n");
15
- const CommonExamContext_1 = require("../../../src/components/context/CommonExamContext");
16
- const ExamContext_1 = require("../../../src/components/context/ExamContext");
17
- require("../../../src/css/main.less");
18
- const WrappedComponent = ({ doc, children }) => {
19
- const i18n = (0, useCached_1.useCached)(() => (0, i18n_1.initI18n)('fi-FI'));
20
- const store = (0, useCached_1.useCached)(() => (0, store_1.initializeExamStore)((0, parseExamStructure_1.parseExamStructure)(doc), 'allowed', [], [], examServerApi_1.examServerApi));
21
- return (react_1.default.createElement(react_redux_1.Provider, { store: store },
22
- react_1.default.createElement(react_i18next_1.I18nextProvider, { i18n: i18n },
23
- react_1.default.createElement("div", { className: "e-exam" }, children))));
24
- };
25
- exports.ComponentWrapper = (0, ExamContext_1.withExamContext)((0, CommonExamContext_1.withCommonExamContext)(WrappedComponent));
26
- //# sourceMappingURL=ComponentWrapper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ComponentWrapper.js","sourceRoot":"","sources":["../../../../__tests__/playwright/utils/ComponentWrapper.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAAyB;AACzB,6CAAsC;AACtC,iDAA+C;AAC/C,8CAAwD;AACxD,+EAA2E;AAC3E,sDAAkD;AAClD,uDAAmD;AACnD,4CAA4C;AAC5C,yFAAyF;AACzF,6EAA6E;AAE7E,sCAAmC;AAOnC,MAAM,gBAAgB,GAAoC,CAAC,EAAE,GAAG,EAAE,QAAQ,EAAE,EAAE,EAAE;IAC9E,MAAM,IAAI,GAAG,IAAA,qBAAS,EAAC,GAAG,EAAE,CAAC,IAAA,eAAQ,EAAC,OAAO,CAAC,CAAC,CAAA;IAC/C,MAAM,KAAK,GAAG,IAAA,qBAAS,EAAC,GAAG,EAAE,CAAC,IAAA,2BAAmB,EAAC,IAAA,uCAAkB,EAAC,GAAG,CAAC,EAAE,SAAS,EAAE,EAAE,EAAE,EAAE,EAAE,6BAAa,CAAC,CAAC,CAAA;IAE7G,OAAO,CACL,8BAAC,sBAAQ,IAAC,KAAK,EAAE,KAAK;QACpB,8BAAC,+BAAe,IAAC,IAAI,EAAE,IAAI;YACzB,uCAAK,SAAS,EAAC,QAAQ,IAAE,QAAQ,CAAO,CACxB,CACT,CACZ,CAAA;AACH,CAAC,CAAA;AAEY,QAAA,gBAAgB,GAAG,IAAA,6BAAe,EAAC,IAAA,yCAAqB,EAAC,gBAAgB,CAAC,CAAC,CAAA"}
@@ -1 +0,0 @@
1
- <svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="30" height="30" viewBox="0 0 30 30"><defs><clipPath id="clip-path"><path d="M141.57-89.324v-2.34H143.2v2.34A2.3,2.3,0,0,1,140.9-87.03H130.1a2.3,2.3,0,0,1-2.292-2.294v-17.029a2.294,2.294,0,0,1,2.292-2.292h10.8a2.3,2.3,0,0,1,2.295,2.292v2.342H141.57v-2.342a.669.669,0,0,0-.67-.667H130.1a.667.667,0,0,0-.667.667v17.029a.668.668,0,0,0,.667.669h10.8A.67.67,0,0,0,141.57-89.324Zm3.271-13.579a1.069,1.069,0,0,1,1.825-.755l5.065,5.065a1.065,1.065,0,0,1,0,1.511l-5.065,5.067a1.07,1.07,0,0,1-1.825-.757v-2.412h-6.633a2.3,2.3,0,0,1-2.3-2.3v-.7a2.3,2.3,0,0,1,2.3-2.3h6.633V-102.9" fill="none" clip-rule="evenodd"/></clipPath><clipPath id="clip-path-2"><ellipse cx="10" cy="-29.606" rx="15" ry="14.933" fill="none"/></clipPath></defs><title>closeButton</title><rect width="30" height="30" fill="#fff" opacity="0"/><line x1="25" y1="5" x2="5" y2="25" fill="none" stroke="#6d6d6d" stroke-miterlimit="10" stroke-width="3"/><line x1="5" y1="5" x2="25" y2="25" fill="none" stroke="#6d6d6d" stroke-miterlimit="10" stroke-width="3"/></svg>
@@ -1,12 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
- <svg width="19px" height="12px" viewBox="0 0 19 12" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
3
- <!-- Generator: Sketch 43.2 (39069) - http://www.bohemiancoding.com/sketch -->
4
- <title>Page 1</title>
5
- <desc>Created with Sketch.</desc>
6
- <defs></defs>
7
- <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
8
- <g id="Kuuntelu-kokelas-painaa-nappia-Copy-18" transform="translate(-1068.000000, -19.000000)" stroke-width="3" stroke="#359BB7">
9
- <polyline id="Page-1" transform="translate(1077.999981, 26.000000) rotate(180.000000) translate(-1077.999981, -26.000000) " points="1085.99996 22 1077.99996 30 1070 22"></polyline>
10
- </g>
11
- </g>
12
- </svg>
@@ -1,12 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
- <svg width="18px" height="12px" viewBox="0 0 18 12" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
3
- <!-- Generator: Sketch 43.2 (39069) - http://www.bohemiancoding.com/sketch -->
4
- <title>Page 1</title>
5
- <desc>Created with Sketch.</desc>
6
- <defs></defs>
7
- <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
8
- <g id="Kuuntelu-kokelas-painaa-nappia-Copy-18" transform="translate(-1069.000000, -21.000000)" stroke-width="3" stroke="#359BB7">
9
- <polyline id="Page-1" points="1085.99996 22 1077.99996 30 1070 22"></polyline>
10
- </g>
11
- </g>
12
- </svg>
@@ -1,9 +0,0 @@
1
- <svg version="1.1"
2
- xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
3
- x="0px" y="0px" width="20px" height="20px" viewBox="0 0 20 20" enable-background="new 0 0 20 20" xml:space="preserve">
4
- <path fill="#359BB7" d="M10,20C4.48,20,0,15.52,0,10C0,4.48,4.48,0,10,0s10,4.48,10,10C20,15.52,15.52,20,10,20z M5.57,5.88
5
- c-0.14,0.21-0.09,0.5,0.11,0.66l1.4,1.06c0.21,0.16,0.51,0.12,0.67-0.09c0.72-0.91,1.21-1.44,2.31-1.44c0.82,0,1.84,0.53,1.84,1.33
6
- c0,0.6-0.5,0.91-1.31,1.37c-0.95,0.53-2.2,1.19-2.2,2.85v0.16c0,0.27,0.22,0.48,0.48,0.48h2.26c0.27,0,0.48-0.22,0.48-0.48v-0.05
7
- c0-1.15,3.35-1.2,3.35-4.3c0-2.34-2.43-4.11-4.7-4.11C8.07,3.31,6.67,4.23,5.57,5.88z M8.15,15.16c0,1.02,0.83,1.85,1.85,1.85
8
- s1.85-0.83,1.85-1.85s-0.83-1.85-1.85-1.85S8.15,14.14,8.15,15.16z"/>
9
- </svg>
@@ -1,5 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="20px" height="20px" viewBox="0 0 20 20" version="1.1">
2
- <g id="surface1">
3
- <path fill="#359BB7" d="M 18.316406 1.253906 C 18.859375 1.253906 19.378906 1.675781 19.378906 2.3125 L 19.378906 8.007812 C 19.378906 8.421875 19.042969 8.757812 18.628906 8.757812 L 12.9375 8.757812 C 12.300781 8.757812 11.882812 8.238281 11.882812 7.695312 C 11.882812 7.4375 11.976562 7.171875 12.191406 6.957031 L 13.953125 5.195312 C 12.851562 4.289062 11.460938 3.761719 9.996094 3.761719 C 6.554688 3.761719 3.753906 6.5625 3.753906 10.003906 C 3.753906 13.449219 6.554688 16.246094 9.996094 16.246094 C 12.851562 16.246094 13.488281 14.75 14.492188 14.75 C 15.214844 14.75 15.742188 15.335938 15.742188 15.996094 C 15.742188 17.367188 12.554688 18.75 10 18.75 C 5.179688 18.75 1.253906 14.824219 1.253906 10.003906 C 1.253906 5.183594 5.179688 1.265625 10 1.265625 C 12.132812 1.265625 14.148438 2.0625 15.71875 3.425781 L 17.578125 1.566406 C 17.792969 1.351562 18.058594 1.253906 18.316406 1.253906 Z M 18.316406 1.253906 "/>
4
- </g>
5
- </svg>
@@ -1,5 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="20px" height="20px" viewBox="0 0 20 20" version="1.1">
2
- <g id="surface1">
3
- <path fill="#359BB7" d="M 18.75 10 C 18.75 14.820312 14.824219 18.746094 10.003906 18.746094 C 8.097656 18.746094 6.285156 18.136719 4.761719 16.992188 C 4.210938 16.578125 4.097656 15.796875 4.511719 15.242188 C 4.925781 14.691406 5.707031 14.582031 6.261719 14.996094 C 7.351562 15.8125 8.644531 16.242188 10.007812 16.242188 C 13.449219 16.242188 16.25 13.441406 16.25 10 C 16.25 6.558594 13.449219 3.757812 10.007812 3.757812 C 8.542969 3.757812 7.152344 4.285156 6.050781 5.1875 L 7.8125 6.953125 C 8.476562 7.617188 8.007812 8.753906 7.066406 8.753906 L 1.375 8.753906 C 0.960938 8.753906 0.625 8.417969 0.625 8.003906 L 0.625 2.304688 C 0.625 1.367188 1.761719 0.898438 2.425781 1.5625 L 4.285156 3.421875 C 5.855469 2.058594 7.871094 1.253906 10.003906 1.253906 C 14.824219 1.253906 18.75 5.179688 18.75 10 Z M 18.75 10 "/>
4
- </g>
5
- </svg>
@@ -1,9 +0,0 @@
1
- import { UniqueIdentifier } from '@dnd-kit/core';
2
- import React from 'react';
3
- import { RenderChildNodes } from '../../createRenderChildNodes';
4
- export declare const AllDNDOptions: ({ items, renderChildNodes, answerOptionsByOptionId }: {
5
- items: UniqueIdentifier[];
6
- renderChildNodes: RenderChildNodes;
7
- answerOptionsByOptionId: Record<UniqueIdentifier, Element>;
8
- }) => React.JSX.Element;
9
- //# sourceMappingURL=AllDNDOptions.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AllDNDOptions.d.ts","sourceRoot":"","sources":["../../../src/components/exam/AllDNDOptions.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAgB,MAAM,eAAe,CAAA;AAE9D,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AAE/D,eAAO,MAAM,aAAa,yDAIvB;IACD,KAAK,EAAE,gBAAgB,EAAE,CAAA;IACzB,gBAAgB,EAAE,gBAAgB,CAAA;IAClC,uBAAuB,EAAE,MAAM,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAA;CAC3D,sBAgBA,CAAA"}
@@ -1,12 +0,0 @@
1
- import { useDroppable } from '@dnd-kit/core';
2
- import { SortableContext } from '@dnd-kit/sortable';
3
- import React from 'react';
4
- import { DNDAnswer } from './DNDAnswer';
5
- export const AllDNDOptions = ({ items, renderChildNodes, answerOptionsByOptionId }) => {
6
- const { setNodeRef } = useDroppable({ id: 'root' });
7
- return (React.createElement(SortableContext, { items: items },
8
- React.createElement("span", { className: "droppable-title" }, "Vastausvaihtoehdot:"),
9
- React.createElement("span", { ref: setNodeRef },
10
- React.createElement(DNDAnswer, { renderChildNodes: renderChildNodes, questionId: "root", items: items, answerOptionsByQuestionId: answerOptionsByOptionId }))));
11
- };
12
- //# sourceMappingURL=AllDNDOptions.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AllDNDOptions.js","sourceRoot":"","sources":["../../../src/components/exam/AllDNDOptions.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAoB,YAAY,EAAE,MAAM,eAAe,CAAA;AAC9D,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AAGvC,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,EAC5B,KAAK,EACL,gBAAgB,EAChB,uBAAuB,EAKxB,EAAE,EAAE;IACH,MAAM,EAAE,UAAU,EAAE,GAAG,YAAY,CAAC,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,CAAA;IAEnD,OAAO,CACL,oBAAC,eAAe,IAAC,KAAK,EAAE,KAAK;QAC3B,8BAAM,SAAS,EAAC,iBAAiB,0BAA2B;QAC5D,8BAAM,GAAG,EAAE,UAAU;YACnB,oBAAC,SAAS,IACR,gBAAgB,EAAE,gBAAgB,EAClC,UAAU,EAAC,MAAM,EACjB,KAAK,EAAE,KAAK,EACZ,yBAAyB,EAAE,uBAAuB,GAClD,CACG,CACS,CACnB,CAAA;AACH,CAAC,CAAA"}
@@ -1,20 +0,0 @@
1
- import { UniqueIdentifier } from '@dnd-kit/core';
2
- import React from 'react';
3
- import { ExamComponentProps } from '../..';
4
- export type ItemsState = {
5
- root: UniqueIdentifier[];
6
- [key: UniqueIdentifier]: UniqueIdentifier[];
7
- };
8
- export type PartialItemsState = {
9
- [key: UniqueIdentifier]: UniqueIdentifier[];
10
- };
11
- export declare const DNDAnswer: ({ renderChildNodes, items, answerOptionsByQuestionId, questionId, maxScore }: {
12
- items: UniqueIdentifier[];
13
- answerOptionsByQuestionId: Record<UniqueIdentifier, Element>;
14
- questionId: UniqueIdentifier;
15
- renderChildNodes: ExamComponentProps["renderChildNodes"];
16
- titleElement?: Element;
17
- displayNumber?: string;
18
- maxScore?: number;
19
- }) => React.JSX.Element;
20
- //# sourceMappingURL=DNDAnswer.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswer.d.ts","sourceRoot":"","sources":["../../../src/components/exam/DNDAnswer.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAA;AAChD,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,kBAAkB,EAAE,MAAM,OAAO,CAAA;AAI1C,MAAM,MAAM,UAAU,GAAG;IACvB,IAAI,EAAE,gBAAgB,EAAE,CAAA;IACxB,CAAC,GAAG,EAAE,gBAAgB,GAAG,gBAAgB,EAAE,CAAA;CAC5C,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG;IAC9B,CAAC,GAAG,EAAE,gBAAgB,GAAG,gBAAgB,EAAE,CAAA;CAC5C,CAAA;AAED,eAAO,MAAM,SAAS,iFAMnB;IACD,KAAK,EAAE,gBAAgB,EAAE,CAAA;IACzB,yBAAyB,EAAE,MAAM,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAA;IAC5D,UAAU,EAAE,gBAAgB,CAAA;IAC5B,gBAAgB,EAAE,kBAAkB,CAAC,kBAAkB,CAAC,CAAA;IACxD,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,sBAaA,CAAA"}
@@ -1,7 +0,0 @@
1
- import React from 'react';
2
- import { DNDAnswerCommon } from '../shared/DNDAnswerCommon';
3
- import { Score } from '../shared/Score';
4
- export const DNDAnswer = ({ renderChildNodes, items, answerOptionsByQuestionId, questionId, maxScore }) => (React.createElement(React.Fragment, null,
5
- React.createElement(DNDAnswerCommon, { renderChildNodes: renderChildNodes, items: items, answerOptionsByQuestionId: answerOptionsByQuestionId, classes: { root: questionId === 'root' }, isInExam: true, questionId: questionId }),
6
- maxScore ? React.createElement(Score, { score: maxScore, size: "small" }) : null));
7
- //# sourceMappingURL=DNDAnswer.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswer.js","sourceRoot":"","sources":["../../../src/components/exam/DNDAnswer.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAA;AAC3D,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAA;AAWvC,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,EACxB,gBAAgB,EAChB,KAAK,EACL,yBAAyB,EACzB,UAAU,EACV,QAAQ,EAST,EAAE,EAAE,CAAC,CACJ;IACE,oBAAC,eAAe,IACd,gBAAgB,EAAE,gBAAgB,EAClC,KAAK,EAAE,KAAK,EACZ,yBAAyB,EAAE,yBAAyB,EACpD,OAAO,EAAE,EAAE,IAAI,EAAE,UAAU,KAAK,MAAM,EAAE,EACxC,QAAQ,EAAE,IAAI,EACd,UAAU,EAAE,UAAU,GACtB;IAED,QAAQ,CAAC,CAAC,CAAC,oBAAC,KAAK,IAAC,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAC,OAAO,GAAG,CAAC,CAAC,CAAC,IAAI,CACzD,CACJ,CAAA"}
@@ -1,4 +0,0 @@
1
- import React from 'react';
2
- import { ExamComponentProps } from '../..';
3
- export declare const DNDAnswerOption: ({ element, renderChildNodes }: ExamComponentProps) => React.JSX.Element;
4
- //# sourceMappingURL=DNDAnswerOption.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerOption.d.ts","sourceRoot":"","sources":["../../../src/components/exam/DNDAnswerOption.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,kBAAkB,EAAE,MAAM,OAAO,CAAA;AAI1C,eAAO,MAAM,eAAe,kCAAmC,kBAAkB,sBAkBhF,CAAA"}
@@ -1,18 +0,0 @@
1
- import { useDraggable } from '@dnd-kit/core';
2
- import { faUpDownLeftRight } from '@fortawesome/free-solid-svg-icons';
3
- import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
4
- import React from 'react';
5
- import { getNumericAttribute } from '../../dom-utils';
6
- import { DNDAnswerOptionCommon } from '../shared/DNDAnswerOptionCommon';
7
- export const DNDAnswerOption = ({ element, renderChildNodes }) => {
8
- const optionId = getNumericAttribute(element, 'option-id');
9
- const { attributes, listeners, setNodeRef, isDragging, setActivatorNodeRef } = useDraggable({
10
- id: optionId
11
- });
12
- const style = { opacity: isDragging ? 0.3 : 1 };
13
- return (React.createElement("div", { ref: setNodeRef, className: "e-dnd-answer-option" },
14
- React.createElement(DNDAnswerOptionCommon, { element: element, renderChildNodes: renderChildNodes, style: style }),
15
- React.createElement("div", { ...listeners, ...attributes, ref: setActivatorNodeRef, className: "drag-handle" },
16
- React.createElement(FontAwesomeIcon, { size: "1x", icon: faUpDownLeftRight }))));
17
- };
18
- //# sourceMappingURL=DNDAnswerOption.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerOption.js","sourceRoot":"","sources":["../../../src/components/exam/DNDAnswerOption.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAA;AAC5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAA;AACrE,OAAO,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAA;AAChE,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAA;AACrD,OAAO,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAA;AAEvE,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,EAAE,OAAO,EAAE,gBAAgB,EAAsB,EAAE,EAAE;IACnF,MAAM,QAAQ,GAAG,mBAAmB,CAAC,OAAO,EAAE,WAAW,CAAE,CAAA;IAE3D,MAAM,EAAE,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,UAAU,EAAE,mBAAmB,EAAE,GAAG,YAAY,CAAC;QAC1F,EAAE,EAAE,QAAQ;KACb,CAAC,CAAA;IAEF,MAAM,KAAK,GAAG,EAAE,OAAO,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAA;IAE/C,OAAO,CACL,6BAAK,GAAG,EAAE,UAAU,EAAE,SAAS,EAAC,qBAAqB;QACnD,oBAAC,qBAAqB,IAAC,OAAO,EAAE,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,KAAK,EAAE,KAAK,GAAI;QAE7F,gCAAS,SAAS,KAAM,UAAU,EAAE,GAAG,EAAE,mBAAmB,EAAE,SAAS,EAAC,aAAa;YACnF,oBAAC,eAAe,IAAC,IAAI,EAAC,IAAI,EAAC,IAAI,EAAE,iBAAiB,GAAI,CAClD,CACF,CACP,CAAA;AACH,CAAC,CAAA"}
@@ -1,4 +0,0 @@
1
- import React from 'react';
2
- import { ExamComponentProps } from '../../createRenderChildNodes';
3
- export declare const AudioPlaceholder: React.FC<ExamComponentProps>;
4
- //# sourceMappingURL=AudioPlaceholder.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AudioPlaceholder.d.ts","sourceRoot":"","sources":["../../../src/components/results/AudioPlaceholder.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAA;AAQjE,eAAO,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CA2BzD,CAAA"}
@@ -1,25 +0,0 @@
1
- import React from 'react';
2
- import { getNumericAttribute } from '../../dom-utils';
3
- import { audioLabelId } from '../../ids';
4
- import Audio from '../shared/Audio';
5
- import { faPlay } from '@fortawesome/free-solid-svg-icons';
6
- import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
7
- import { formatDuration } from '../shared/internal/RestrictedAudioPlayer';
8
- export const AudioPlaceholder = ({ element, renderChildNodes }) => {
9
- const restricted = !!getNumericAttribute(element, 'times');
10
- const duration = getNumericAttribute(element, 'duration');
11
- const labelId = audioLabelId(element);
12
- if (restricted) {
13
- return (React.createElement("div", { className: "audio e-columns e-columns--center-v e-mrg-b-2" },
14
- React.createElement("div", { className: "e-pad-1 restricted-audio-player restricted-audio-player--disabled e-columns e-columns--center-v" },
15
- React.createElement("button", { className: "restricted-audio-player__play e-column e-column--narrow", disabled: true, onClick: () => undefined },
16
- React.createElement(FontAwesomeIcon, { icon: faPlay, fixedWidth: true })),
17
- React.createElement("span", { className: "e-column e-text-right e-column" }, formatDuration(duration))),
18
- React.createElement("span", { className: "e-pad-l-2", id: labelId },
19
- React.createElement("em", null, "Ei kuunneltavissa"))));
20
- }
21
- else {
22
- return React.createElement(Audio, { element: element, renderChildNodes: renderChildNodes });
23
- }
24
- };
25
- //# sourceMappingURL=AudioPlaceholder.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AudioPlaceholder.js","sourceRoot":"","sources":["../../../src/components/results/AudioPlaceholder.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAA;AACrD,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AACxC,OAAO,KAAK,MAAM,iBAAiB,CAAA;AACnC,OAAO,EAAE,MAAM,EAAE,MAAM,mCAAmC,CAAA;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAA;AAChE,OAAO,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAA;AAEzE,MAAM,CAAC,MAAM,gBAAgB,GAAiC,CAAC,EAAE,OAAO,EAAE,gBAAgB,EAAE,EAAE,EAAE;IAC9F,MAAM,UAAU,GAAG,CAAC,CAAC,mBAAmB,CAAC,OAAO,EAAE,OAAO,CAAC,CAAA;IAC1D,MAAM,QAAQ,GAAG,mBAAmB,CAAC,OAAO,EAAE,UAAU,CAAE,CAAA;IAC1D,MAAM,OAAO,GAAG,YAAY,CAAC,OAAO,CAAC,CAAA;IAErC,IAAI,UAAU,EAAE,CAAC;QACf,OAAO,CACL,6BAAK,SAAS,EAAC,+CAA+C;YAC5D,6BAAK,SAAS,EAAC,iGAAiG;gBAC9G,gCACE,SAAS,EAAC,yDAAyD,EACnE,QAAQ,EAAE,IAAI,EACd,OAAO,EAAE,GAAG,EAAE,CAAC,SAAS;oBAExB,oBAAC,eAAe,IAAC,IAAI,EAAE,MAAM,EAAE,UAAU,SAAG,CACrC;gBACT,8BAAM,SAAS,EAAC,gCAAgC,IAAE,cAAc,CAAC,QAAQ,CAAC,CAAQ,CAC9E;YAEN,8BAAM,SAAS,EAAC,WAAW,EAAC,EAAE,EAAE,OAAO;gBACrC,oDAA0B,CACrB,CACH,CACP,CAAA;IACH,CAAC;SAAM,CAAC;QACN,OAAO,oBAAC,KAAK,IAAC,OAAO,EAAE,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,GAAI,CAAA;IACxE,CAAC;AACH,CAAC,CAAA"}
@@ -1,12 +0,0 @@
1
- import { UniqueIdentifier } from '@dnd-kit/core';
2
- import React from 'react';
3
- import { ExamComponentProps } from '../..';
4
- export declare const DNDAnswer: ({ renderChildNodes, items, answerOptionsByQuestionId, questionId, displayNumber, maxScore }: {
5
- renderChildNodes: ExamComponentProps["renderChildNodes"];
6
- items: UniqueIdentifier[];
7
- answerOptionsByQuestionId: Record<UniqueIdentifier, Element>;
8
- questionId: UniqueIdentifier;
9
- displayNumber: string;
10
- maxScore?: number;
11
- }) => React.JSX.Element;
12
- //# sourceMappingURL=DNDAnswer.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswer.d.ts","sourceRoot":"","sources":["../../../src/components/results/DNDAnswer.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAA;AAChD,OAAO,KAAqB,MAAM,OAAO,CAAA;AACzC,OAAO,EAAuB,kBAAkB,EAAE,MAAM,OAAO,CAAA;AAK/D,eAAO,MAAM,SAAS,gGAOnB;IACD,gBAAgB,EAAE,kBAAkB,CAAC,kBAAkB,CAAC,CAAA;IACxD,KAAK,EAAE,gBAAgB,EAAE,CAAA;IACzB,yBAAyB,EAAE,MAAM,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAA;IAC5D,UAAU,EAAE,gBAAgB,CAAA;IAC5B,aAAa,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,sBAgCA,CAAA"}
@@ -1,21 +0,0 @@
1
- import React, { useContext } from 'react';
2
- import { findMultiChoiceFromGradingStructure, ResultsContext } from '../context/ResultsContext';
3
- import { DNDAnswerCommon } from '../shared/DNDAnswerCommon';
4
- import ResultsExamQuestionAutoScore from './internal/QuestionAutoScore';
5
- export const DNDAnswer = ({ renderChildNodes, items, answerOptionsByQuestionId, questionId, displayNumber, maxScore }) => {
6
- var _a, _b, _c;
7
- const questionIdNumber = Number(questionId);
8
- const { answersByQuestionId, gradingStructure } = useContext(ResultsContext);
9
- const answer = answersByQuestionId[questionIdNumber];
10
- const choice = findMultiChoiceFromGradingStructure(gradingStructure, questionIdNumber);
11
- const scoreValue = (answer === null || answer === void 0 ? void 0 : answer.value)
12
- ? undefined
13
- : ((_b = (_a = choice === null || choice === void 0 ? void 0 : choice.options.find(option => option.id === Number(answer.value) && option.correct)) === null || _a === void 0 ? void 0 : _a.score) !== null && _b !== void 0 ? _b : 0);
14
- const thisQuestion = gradingStructure.questions.find(q => q.displayNumber === displayNumber);
15
- const options = ((_c = thisQuestion.choices.find(c => c.id === questionIdNumber)) === null || _c === void 0 ? void 0 : _c.options) || [];
16
- const correctOptionIds = options.filter(o => o.correct).map(o => o.id);
17
- return (React.createElement(React.Fragment, null,
18
- React.createElement(DNDAnswerCommon, { renderChildNodes: renderChildNodes, items: items, answerOptionsByQuestionId: answerOptionsByQuestionId, correctIds: correctOptionIds, questionId: questionId }),
19
- React.createElement(ResultsExamQuestionAutoScore, { score: scoreValue, maxScore: maxScore, displayNumber: displayNumber, questionId: questionIdNumber })));
20
- };
21
- //# sourceMappingURL=DNDAnswer.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswer.js","sourceRoot":"","sources":["../../../src/components/results/DNDAnswer.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAEzC,OAAO,EAAE,mCAAmC,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAA;AAC/F,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAA;AAC3D,OAAO,4BAA4B,MAAM,8BAA8B,CAAA;AAEvE,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,EACxB,gBAAgB,EAChB,KAAK,EACL,yBAAyB,EACzB,UAAU,EACV,aAAa,EACb,QAAQ,EAQT,EAAE,EAAE;;IACH,MAAM,gBAAgB,GAAG,MAAM,CAAC,UAAU,CAAC,CAAA;IAE3C,MAAM,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,GAAG,UAAU,CAAC,cAAc,CAAC,CAAA;IAC5E,MAAM,MAAM,GAAG,mBAAmB,CAAC,gBAAgB,CAAC,CAAA;IACpD,MAAM,MAAM,GAAG,mCAAmC,CAAC,gBAAgB,EAAE,gBAAgB,CAAE,CAAA;IACvF,MAAM,UAAU,GAAG,CAAA,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,KAAK;QAC9B,CAAC,CAAC,SAAS;QACX,CAAC,CAAC,CAAC,MAAA,MAAA,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,EAAE,KAAK,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,0CAAE,KAAK,mCAAI,CAAC,CAAC,CAAA;IAEtG,MAAM,YAAY,GAAG,gBAAgB,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,aAAa,KAAK,aAAa,CAAwB,CAAA;IACnH,MAAM,OAAO,GAAG,CAAA,MAAA,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,gBAAgB,CAAC,0CAAE,OAAO,KAAI,EAAE,CAAA;IACxF,MAAM,gBAAgB,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAA;IAEtE,OAAO,CACL;QACE,oBAAC,eAAe,IACd,gBAAgB,EAAE,gBAAgB,EAClC,KAAK,EAAE,KAAK,EACZ,yBAAyB,EAAE,yBAAyB,EACpD,UAAU,EAAE,gBAAgB,EAC5B,UAAU,EAAE,UAAU,GACtB;QAEF,oBAAC,4BAA4B,IAC3B,KAAK,EAAE,UAAU,EACjB,QAAQ,EAAE,QAAQ,EAClB,aAAa,EAAE,aAAa,EAC5B,UAAU,EAAE,gBAAgB,GAC5B,CACD,CACJ,CAAA;AACH,CAAC,CAAA"}
@@ -1,13 +0,0 @@
1
- import { UniqueIdentifier } from '@dnd-kit/core';
2
- import React from 'react';
3
- import { ExamComponentProps } from '../..';
4
- export declare const DNDAnswerCommon: ({ renderChildNodes, items, answerOptionsByQuestionId, isInExam, correctIds, classes, questionId }: {
5
- items: UniqueIdentifier[];
6
- answerOptionsByQuestionId: Record<UniqueIdentifier, Element>;
7
- renderChildNodes: ExamComponentProps["renderChildNodes"];
8
- isInExam?: boolean;
9
- correctIds?: UniqueIdentifier[];
10
- classes?: Record<string, boolean>;
11
- questionId: UniqueIdentifier;
12
- }) => React.JSX.Element;
13
- //# sourceMappingURL=DNDAnswerCommon.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerCommon.d.ts","sourceRoot":"","sources":["../../../src/components/shared/DNDAnswerCommon.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAgB,MAAM,eAAe,CAAA;AAE9D,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,kBAAkB,EAAE,MAAM,OAAO,CAAA;AAK1C,eAAO,MAAM,eAAe,sGAQzB;IACD,KAAK,EAAE,gBAAgB,EAAE,CAAA;IACzB,yBAAyB,EAAE,MAAM,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAA;IAC5D,gBAAgB,EAAE,kBAAkB,CAAC,kBAAkB,CAAC,CAAA;IACxD,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,UAAU,CAAC,EAAE,gBAAgB,EAAE,CAAA;IAC/B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACjC,UAAU,EAAE,gBAAgB,CAAA;CAC7B,sBA8CA,CAAA"}
@@ -1,30 +0,0 @@
1
- import { useDroppable } from '@dnd-kit/core';
2
- import classNames from 'classnames';
3
- import React from 'react';
4
- import { query } from '../../dom-utils';
5
- import { DNDAnswerOption as DNDAnswerOptionExam } from '../exam/DNDAnswerOption';
6
- import { DNDAnswerOptionCommon } from './DNDAnswerOptionCommon';
7
- export const DNDAnswerCommon = ({ renderChildNodes, items, answerOptionsByQuestionId, isInExam, correctIds, classes, questionId }) => {
8
- const dndAnswerOptions = (items === null || items === void 0 ? void 0 : items.map(id => answerOptionsByQuestionId[id])) || [];
9
- const hasImages = dndAnswerOptions.some(option => query(option, 'image'));
10
- const hasAudio = dndAnswerOptions.some(option => query(option, 'audio'));
11
- const hasFormula = dndAnswerOptions.some(option => query(option, 'formula'));
12
- const { active, isOver } = useDroppable({ id: questionId });
13
- return (React.createElement("div", { className: classNames('e-dnd-answer-droppable', {
14
- 'has-images': hasImages,
15
- 'has-audio': hasAudio,
16
- 'has-formula': hasFormula,
17
- hovered: isOver,
18
- ...classes
19
- }) }, dndAnswerOptions === null || dndAnswerOptions === void 0 ? void 0 :
20
- dndAnswerOptions.map(element => {
21
- const optionId = Number(element.getAttribute('option-id'));
22
- const hasImage = query(element, 'image');
23
- const isCorrect = correctIds === null || correctIds === void 0 ? void 0 : correctIds.includes(optionId);
24
- return (React.createElement("div", { className: classNames({ 'has-image': hasImage }), key: element.getAttribute('option-id') }, isInExam ? (React.createElement(DNDAnswerOptionExam, { element: element, renderChildNodes: renderChildNodes, key: optionId })) : (React.createElement("div", { className: "e-dnd-answer-option" },
25
- React.createElement(DNDAnswerOptionCommon, { element: element, renderChildNodes: renderChildNodes, key: optionId, classes: [isCorrect ? 'correct-answer' : 'wrong-answer'] })))));
26
- }),
27
- !dndAnswerOptions.length &&
28
- (active ? (React.createElement("i", { className: "droppable-drop-here" }, "Pudota t\u00E4nne")) : (React.createElement("i", { className: "droppable-no-answer" }, "(Ei vastausta)")))));
29
- };
30
- //# sourceMappingURL=DNDAnswerCommon.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerCommon.js","sourceRoot":"","sources":["../../../src/components/shared/DNDAnswerCommon.tsx"],"names":[],"mappings":"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"}
@@ -1,13 +0,0 @@
1
- import { UniqueIdentifier } from '@dnd-kit/core';
2
- import React from 'react';
3
- import { ExamComponentProps } from '../..';
4
- export declare const DNDAnswerDroppable: ({ renderChildNodes, items, answerOptionsByQuestionId, correctIds, classes, questionId, page }: {
5
- items: UniqueIdentifier[];
6
- answerOptionsByQuestionId: Record<UniqueIdentifier, Element>;
7
- renderChildNodes: ExamComponentProps["renderChildNodes"];
8
- correctIds?: UniqueIdentifier[];
9
- classes?: Record<string, boolean>;
10
- questionId: UniqueIdentifier;
11
- page: "exam" | "results";
12
- }) => React.JSX.Element;
13
- //# sourceMappingURL=DNDAnswerDroppable.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DNDAnswerDroppable.d.ts","sourceRoot":"","sources":["../../../src/components/shared/DNDAnswerDroppable.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAgB,MAAM,eAAe,CAAA;AAE9D,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,kBAAkB,EAAE,MAAM,OAAO,CAAA;AAK1C,eAAO,MAAM,kBAAkB,kGAQ5B;IACD,KAAK,EAAE,gBAAgB,EAAE,CAAA;IACzB,yBAAyB,EAAE,MAAM,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAA;IAC5D,gBAAgB,EAAE,kBAAkB,CAAC,kBAAkB,CAAC,CAAA;IACxD,UAAU,CAAC,EAAE,gBAAgB,EAAE,CAAA;IAC/B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACjC,UAAU,EAAE,gBAAgB,CAAA;IAC5B,IAAI,EAAE,MAAM,GAAG,SAAS,CAAA;CACzB,sBAgDA,CAAA"}