@digabi/exam-engine-core 22.1.6-alpha.1 → 22.1.6-alpha.3
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/__tests__/EditableGradingInsatruction.test.d.ts +1 -0
- package/dist/__tests__/EditableGradingInsatruction.test.d.ts.map +1 -0
- package/dist/__tests__/EditableGradingInsatruction.test.js +2 -0
- package/dist/__tests__/EditableGradingInsatruction.test.js.map +1 -0
- package/dist/__tests__/editor/Formula.test.js +11 -0
- package/dist/__tests__/editor/Formula.test.js.map +1 -1
- package/dist/__tests__/editor/List.test.d.ts +2 -0
- package/dist/__tests__/editor/List.test.d.ts.map +1 -0
- package/dist/__tests__/editor/List.test.js +72 -0
- package/dist/__tests__/editor/List.test.js.map +1 -0
- package/dist/__tests__/editor/Table.test.d.ts +2 -0
- package/dist/__tests__/editor/Table.test.d.ts.map +1 -0
- package/dist/__tests__/editor/Table.test.js +172 -0
- package/dist/__tests__/editor/Table.test.js.map +1 -0
- package/dist/__tests__/editor/no-wrap.test.d.ts +2 -0
- package/dist/__tests__/editor/no-wrap.test.d.ts.map +1 -0
- package/dist/__tests__/editor/no-wrap.test.js +43 -0
- package/dist/__tests__/editor/no-wrap.test.js.map +1 -0
- package/dist/__tests__/tsconfig.tsbuildinfo +1 -1
- package/dist/__tests__/utils/EditableGradingInstructionsWrapper.d.ts +1 -0
- package/dist/__tests__/utils/EditableGradingInstructionsWrapper.d.ts.map +1 -0
- package/dist/__tests__/utils/EditableGradingInstructionsWrapper.js +2 -0
- package/dist/__tests__/utils/EditableGradingInstructionsWrapper.js.map +1 -0
- package/dist/__tests__/utils/renderEditableGradingInstructions.d.ts +1 -0
- package/dist/__tests__/utils/renderEditableGradingInstructions.d.ts.map +1 -0
- package/dist/__tests__/utils/renderEditableGradingInstructions.js +2 -0
- package/dist/__tests__/utils/renderEditableGradingInstructions.js.map +1 -0
- package/dist/components/LexicalEditor.d.ts +3 -0
- package/dist/components/LexicalEditor.d.ts.map +1 -0
- package/dist/components/LexicalEditor.js +44 -0
- package/dist/components/LexicalEditor.js.map +1 -0
- package/dist/components/RTE.d.ts +3 -0
- package/dist/components/RTE.d.ts.map +1 -0
- package/dist/components/RTE.js +23 -0
- package/dist/components/RTE.js.map +1 -0
- package/dist/components/TablePlugin.d.ts +1 -0
- package/dist/components/TablePlugin.d.ts.map +1 -0
- package/dist/components/TablePlugin.js +2 -0
- package/dist/components/TablePlugin.js.map +1 -0
- package/dist/components/ToolBarPlugin.d.ts +10 -0
- package/dist/components/ToolBarPlugin.d.ts.map +1 -0
- package/dist/components/ToolBarPlugin.js +111 -0
- package/dist/components/ToolBarPlugin.js.map +1 -0
- package/dist/components/context/AnnotationContext.d.ts +8 -0
- package/dist/components/context/AnnotationContext.d.ts.map +1 -0
- package/dist/components/context/AnnotationContext.js +3 -0
- package/dist/components/context/AnnotationContext.js.map +1 -0
- package/dist/components/context/AttachmentContext.d.ts.map +1 -1
- package/dist/components/context/ExamContext.d.ts.map +1 -1
- package/dist/components/context/QuestionContext.d.ts.map +1 -1
- package/dist/components/context/ResultsContext.d.ts.map +1 -1
- package/dist/components/context/SectionContext.d.ts.map +1 -1
- package/dist/components/exam/ExamineExam.d.ts +5 -0
- package/dist/components/exam/ExamineExam.d.ts.map +1 -0
- package/dist/components/exam/ExamineExam.js +20 -0
- package/dist/components/exam/ExamineExam.js.map +1 -0
- package/dist/components/exam/FinishExam.d.ts +5 -0
- package/dist/components/exam/FinishExam.d.ts.map +1 -0
- package/dist/components/exam/FinishExam.js +17 -0
- package/dist/components/exam/FinishExam.js.map +1 -0
- package/dist/components/grading/reactAnnotation.d.ts +4 -0
- package/dist/components/grading/reactAnnotation.d.ts.map +1 -0
- package/dist/components/grading/reactAnnotation.js +54 -0
- package/dist/components/grading/reactAnnotation.js.map +1 -0
- package/dist/components/grading-instructions/EditableGradingInstruction.d.ts.map +1 -1
- package/dist/components/grading-instructions/EditableGradingInstruction.js +26 -13
- package/dist/components/grading-instructions/EditableGradingInstruction.js.map +1 -1
- package/dist/components/grading-instructions/GradingInstructions.d.ts +1 -1
- package/dist/components/grading-instructions/SlateTableEditor.d.ts +22 -0
- package/dist/components/grading-instructions/SlateTableEditor.d.ts.map +1 -0
- package/dist/components/grading-instructions/SlateTableEditor.js +44 -0
- package/dist/components/grading-instructions/SlateTableEditor.js.map +1 -0
- package/dist/components/grading-instructions/SlateUtils.d.ts +5 -0
- package/dist/components/grading-instructions/SlateUtils.d.ts.map +1 -0
- package/dist/components/grading-instructions/SlateUtils.js +28 -0
- package/dist/components/grading-instructions/SlateUtils.js.map +1 -0
- package/dist/components/grading-instructions/editor/Formula.d.ts +0 -3
- package/dist/components/grading-instructions/editor/Formula.d.ts.map +1 -1
- package/dist/components/grading-instructions/editor/Formula.js +0 -54
- package/dist/components/grading-instructions/editor/Formula.js.map +1 -1
- package/dist/components/grading-instructions/editor/List.d.ts +9 -0
- package/dist/components/grading-instructions/editor/List.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/List.js +41 -0
- package/dist/components/grading-instructions/editor/List.js.map +1 -0
- package/dist/components/grading-instructions/editor/MathPopup.d.ts +10 -0
- package/dist/components/grading-instructions/editor/MathPopup.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/MathPopup.js +94 -0
- package/dist/components/grading-instructions/editor/MathPopup.js.map +1 -0
- package/dist/components/grading-instructions/editor/Menu.d.ts +1 -0
- package/dist/components/grading-instructions/editor/Menu.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/Menu.js +2 -0
- package/dist/components/grading-instructions/editor/Menu.js.map +1 -0
- package/dist/components/grading-instructions/editor/Table.d.ts +0 -2
- package/dist/components/grading-instructions/editor/Table.d.ts.map +1 -1
- package/dist/components/grading-instructions/editor/Table.js +3 -52
- package/dist/components/grading-instructions/editor/Table.js.map +1 -1
- package/dist/components/grading-instructions/editor/findNode.d.ts +3 -0
- package/dist/components/grading-instructions/editor/findNode.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/findNode.js +10 -0
- package/dist/components/grading-instructions/editor/findNode.js.map +1 -0
- package/dist/components/grading-instructions/editor/keymap.d.ts +2 -0
- package/dist/components/grading-instructions/editor/keymap.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/keymap.js +12 -0
- package/dist/components/grading-instructions/editor/keymap.js.map +1 -0
- package/dist/components/grading-instructions/editor/math-svg.d.ts +2 -0
- package/dist/components/grading-instructions/editor/math-svg.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/math-svg.js +22 -0
- package/dist/components/grading-instructions/editor/math-svg.js.map +1 -0
- package/dist/components/grading-instructions/editor/math.d.ts +4 -0
- package/dist/components/grading-instructions/editor/math.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/math.js +55 -0
- package/dist/components/grading-instructions/editor/math.js.map +1 -0
- package/dist/components/grading-instructions/editor/noWrap.d.ts +3 -0
- package/dist/components/grading-instructions/editor/noWrap.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/noWrap.js +13 -0
- package/dist/components/grading-instructions/editor/noWrap.js.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/formulaSchema.d.ts +4 -0
- package/dist/components/grading-instructions/editor/schemas/formulaSchema.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/formulaSchema.js +62 -0
- package/dist/components/grading-instructions/editor/schemas/formulaSchema.js.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/imageSchema.d.ts +4 -0
- package/dist/components/grading-instructions/editor/schemas/imageSchema.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/imageSchema.js +47 -0
- package/dist/components/grading-instructions/editor/schemas/imageSchema.js.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/listSchema.d.ts +72 -0
- package/dist/components/grading-instructions/editor/schemas/listSchema.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/listSchema.js +7 -0
- package/dist/components/grading-instructions/editor/schemas/listSchema.js.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/spanWithNowrapSchema.d.ts +3 -0
- package/dist/components/grading-instructions/editor/schemas/spanWithNowrapSchema.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/spanWithNowrapSchema.js +19 -0
- package/dist/components/grading-instructions/editor/schemas/spanWithNowrapSchema.js.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/tableSchema.d.ts +3 -0
- package/dist/components/grading-instructions/editor/schemas/tableSchema.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/schemas/tableSchema.js +43 -0
- package/dist/components/grading-instructions/editor/schemas/tableSchema.js.map +1 -0
- package/dist/components/grading-instructions/editor/spanWithClass.d.ts +3 -0
- package/dist/components/grading-instructions/editor/spanWithClass.d.ts.map +1 -0
- package/dist/components/grading-instructions/editor/spanWithClass.js +19 -0
- package/dist/components/grading-instructions/editor/spanWithClass.js.map +1 -0
- package/dist/components/grading-instructions/prosemirror.d.ts +8 -0
- package/dist/components/grading-instructions/prosemirror.d.ts.map +1 -0
- package/dist/components/grading-instructions/prosemirror.js +108 -0
- package/dist/components/grading-instructions/prosemirror.js.map +1 -0
- package/dist/components/results/isExamFinishPageHook.d.ts +2 -0
- package/dist/components/results/isExamFinishPageHook.d.ts.map +1 -0
- package/dist/components/results/isExamFinishPageHook.js +7 -0
- package/dist/components/results/isExamFinishPageHook.js.map +1 -0
- package/dist/components/shared/CreateAnnotationPopup.d.ts +6 -0
- package/dist/components/shared/CreateAnnotationPopup.d.ts.map +1 -0
- package/dist/components/shared/CreateAnnotationPopup.js +11 -0
- package/dist/components/shared/CreateAnnotationPopup.js.map +1 -0
- package/dist/components/shared/PopupUtils.d.ts +4 -0
- package/dist/components/shared/PopupUtils.d.ts.map +1 -0
- package/dist/components/shared/PopupUtils.js +26 -0
- package/dist/components/shared/PopupUtils.js.map +1 -0
- package/dist/main-bundle.js +1 -1
- package/dist/main-bundle.js.LICENSE.txt +1 -1
- package/dist/main.css +1 -1
- package/dist/store/listenerMiddleware.d.ts +89 -0
- package/dist/store/listenerMiddleware.d.ts.map +1 -0
- package/dist/store/listenerMiddleware.js +6 -0
- package/dist/store/listenerMiddleware.js.map +1 -0
- package/package.json +3 -2
- package/dist/components/Localization.d.ts +0 -5
- package/dist/components/Localization.d.ts.map +0 -1
- package/dist/components/Localization.js +0 -9
- package/dist/components/Localization.js.map +0 -1
- package/dist/components/grading-instructions/GradingInstruction.d.ts +0 -7
- package/dist/components/grading-instructions/GradingInstruction.d.ts.map +0 -1
- package/dist/components/grading-instructions/GradingInstruction.js +0 -9
- package/dist/components/grading-instructions/GradingInstruction.js.map +0 -1
- package/dist/components/grading-instructions/editor/AttributeToggleButton.d.ts +0 -9
- package/dist/components/grading-instructions/editor/AttributeToggleButton.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/AttributeToggleButton.js +0 -53
- package/dist/components/grading-instructions/editor/AttributeToggleButton.js.map +0 -1
- package/dist/components/grading-instructions/editor/CurrentElement.d.ts +0 -2
- package/dist/components/grading-instructions/editor/CurrentElement.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/CurrentElement.js +0 -8
- package/dist/components/grading-instructions/editor/CurrentElement.js.map +0 -1
- package/dist/components/grading-instructions/editor/CurrentLocalization.d.ts +0 -7
- package/dist/components/grading-instructions/editor/CurrentLocalization.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/CurrentLocalization.js +0 -13
- package/dist/components/grading-instructions/editor/CurrentLocalization.js.map +0 -1
- package/dist/components/grading-instructions/editor/LocalizationButtons.d.ts +0 -6
- package/dist/components/grading-instructions/editor/LocalizationButtons.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/LocalizationButtons.js +0 -14
- package/dist/components/grading-instructions/editor/LocalizationButtons.js.map +0 -1
- package/dist/components/grading-instructions/editor/localizatio.d.ts +0 -3
- package/dist/components/grading-instructions/editor/localizatio.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/localizatio.js +0 -36
- package/dist/components/grading-instructions/editor/localizatio.js.map +0 -1
- package/dist/components/grading-instructions/editor/localizationSpan.d.ts +0 -3
- package/dist/components/grading-instructions/editor/localizationSpan.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/localizationSpan.js +0 -36
- package/dist/components/grading-instructions/editor/localizationSpan.js.map +0 -1
- package/dist/components/grading-instructions/editor/spanWithPath.d.ts +0 -3
- package/dist/components/grading-instructions/editor/spanWithPath.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/spanWithPath.js +0 -24
- package/dist/components/grading-instructions/editor/spanWithPath.js.map +0 -1
- package/dist/components/grading-instructions/editor/util.d.ts +0 -6
- package/dist/components/grading-instructions/editor/util.d.ts.map +0 -1
- package/dist/components/grading-instructions/editor/util.js +0 -10
- package/dist/components/grading-instructions/editor/util.js.map +0 -1
- /package/dist/__tests__/editor/{nbsp.test.d.ts → NBSP.test.d.ts} +0 -0
- /package/dist/__tests__/editor/{nbsp.test.d.ts.map → NBSP.test.d.ts.map} +0 -0
- /package/dist/__tests__/editor/{nbsp.test.js → NBSP.test.js} +0 -0
- /package/dist/__tests__/editor/{nbsp.test.js.map → NBSP.test.js.map} +0 -0
- /package/dist/components/grading-instructions/editor/{Localization.d.ts → localization.d.ts} +0 -0
- /package/dist/components/grading-instructions/editor/{Localization.d.ts.map → localization.d.ts.map} +0 -0
- /package/dist/components/grading-instructions/editor/{Localization.js → localization.js} +0 -0
- /package/dist/components/grading-instructions/editor/{Localization.js.map → localization.js.map} +0 -0
@@ -0,0 +1 @@
|
|
1
|
+
//# sourceMappingURL=EditableGradingInsatruction.test.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"EditableGradingInsatruction.test.d.ts","sourceRoot":"","sources":["../../__tests__/EditableGradingInsatruction.test.tsx"],"names":[],"mappings":""}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"EditableGradingInsatruction.test.js","sourceRoot":"","sources":["../../__tests__/EditableGradingInsatruction.test.tsx"],"names":[],"mappings":""}
|
@@ -35,6 +35,17 @@ describe('Editor - Formula', () => {
|
|
35
35
|
expect(onContentChangeMock).toHaveBeenCalledTimes(1);
|
36
36
|
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
37
37
|
});
|
38
|
+
it('assistive-tile supports < and > characters correctly', async () => {
|
39
|
+
cleanup = (0, prosemirror_1.mockCreateRange)();
|
40
|
+
const inputData = '<p>bar</p><p><e:formula data-editor-id="e-formula" assistive-title="foobar > 0 < x">bar</e:formula></p>';
|
41
|
+
const expectedOutput = '<p>foo</p><p><e:formula assistive-title="foobar > 0 < x">bar</e:formula></p>';
|
42
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
43
|
+
await act(async () => {
|
44
|
+
(0, util_1.insertText)(await result.findByText('bar'), 'foo');
|
45
|
+
});
|
46
|
+
expect(onContentChangeMock).toHaveBeenCalledTimes(1);
|
47
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
48
|
+
});
|
38
49
|
it('Empty formula is removed when sending changed content', async () => {
|
39
50
|
cleanup = (0, prosemirror_1.mockCreateRange)();
|
40
51
|
const inputData = '<p>bar</p><p><e:formula data-editor-id="e-formula"></e:formula></p>';
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Formula.test.js","sourceRoot":"","sources":["../../../__tests__/editor/Formula.test.tsx"],"names":[],"mappings":";;AAAA,kDAAuD;AACvD,sDAAsD;AACtD,gGAAoF;AACpF,wCAA0C;AAE1C,MAAM,GAAG,GAAG,WAAuD,CAAA;AAEnE,QAAQ,CAAC,kBAAkB,EAAE,GAAG,EAAE;IAChC,IAAI,OAA4B,CAAA;IAChC,IAAI,mBAA8B,CAAA;IAElC,UAAU,CAAC,GAAG,EAAE;QACd,mBAAmB,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IACjC,CAAC,CAAC,CAAA;IAEF,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,OAAO,EAAE,CAAC;YACZ,OAAO,EAAE,CAAA;QACX,CAAC;QACD,OAAO,GAAG,IAAI,CAAA;IAChB,CAAC,CAAC,CAAA;IAEF,EA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AAA,6BAAe,GAAE,CAAA;QAC3B,MAAM,SAAS,GAAG,qEAAqE,CAAA;QACvF,MAAM,cAAc,GAAG,mBAAmB,CAAA;QAC1C,MAAM,MAAM,GAAG,IAAA,2DAAwB,EAAC,SAAS,EAAE,mBAAmB,CAAC,CAAA;QACvE,MAAM,GAAG,CAAC,KAAK,IAAI,EAAE;YACnB,IAAA,iBAAU,EAAC,MAAM,MAAM,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,CAAA;QACnD,CAAC,CAAC,CAAA;QACF,MAAM,CAAC,mBAAmB,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,CAAA;QACpD,MAAM,CAAC,mBAAmB,CAAC,CAAC,oBAAoB,CAAC,cAAc,EAAE,EAAE,CAAC,CAAA;IACtE,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"List.test.d.ts","sourceRoot":"","sources":["../../../__tests__/editor/List.test.tsx"],"names":[],"mappings":""}
|
@@ -0,0 +1,72 @@
|
|
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 = require("@testing-library/react");
|
7
|
+
const prosemirror_1 = require("../utils/prosemirror");
|
8
|
+
const renderEditableGradingInstruction_1 = require("../utils/renderEditableGradingInstruction");
|
9
|
+
const user_event_1 = __importDefault(require("@testing-library/user-event"));
|
10
|
+
const util_1 = require("../utils/util");
|
11
|
+
const act = react_1.act;
|
12
|
+
describe('Editor - List', () => {
|
13
|
+
let cleanup;
|
14
|
+
let onContentChangeMock;
|
15
|
+
beforeEach(() => {
|
16
|
+
onContentChangeMock = jest.fn();
|
17
|
+
});
|
18
|
+
afterEach(() => {
|
19
|
+
if (cleanup) {
|
20
|
+
cleanup();
|
21
|
+
}
|
22
|
+
cleanup = null;
|
23
|
+
});
|
24
|
+
it('Bullet list is rendered as expected', () => {
|
25
|
+
const inputData = '<p>bar</p><ul><li>foo</li></ul>';
|
26
|
+
const expectedDom = '<p>bar</p><ul><li><p>foo</p></li></ul>';
|
27
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
28
|
+
const table = result.container.querySelector('.ProseMirror');
|
29
|
+
expect(table.innerHTML).toBe(expectedDom);
|
30
|
+
});
|
31
|
+
it('Ordered list is rendered as expected', () => {
|
32
|
+
const inputData = '<p>bar</p><ol><li>foo</li></ol>';
|
33
|
+
const expectedDom = '<p>bar</p><ol><li><p>foo</p></li></ol>';
|
34
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
35
|
+
const table = result.container.querySelector('.ProseMirror');
|
36
|
+
expect(table.innerHTML).toBe(expectedDom);
|
37
|
+
});
|
38
|
+
it('Change in content causes bullet list to be returned as expected', async () => {
|
39
|
+
cleanup = (0, prosemirror_1.mockCreateRange)();
|
40
|
+
const inputData = '<p>bar</p><ul><li>foo</li></ul>';
|
41
|
+
const expectedOutput = '<p>foo</p><ul><li><p>foo</p></li></ul>';
|
42
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
43
|
+
await act(async () => {
|
44
|
+
(0, util_1.insertText)(await result.findByText('bar'), 'foo');
|
45
|
+
});
|
46
|
+
expect(onContentChangeMock).toHaveBeenCalledTimes(1);
|
47
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
48
|
+
});
|
49
|
+
it('Change in content causes ordered list to be returned as expected', async () => {
|
50
|
+
cleanup = (0, prosemirror_1.mockCreateRange)();
|
51
|
+
const inputData = '<p>bar</p><ol><li>foo</li></ol>';
|
52
|
+
const expectedOutput = '<p>foo</p><ol><li><p>foo</p></li></ol>';
|
53
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
54
|
+
await act(async () => {
|
55
|
+
(0, util_1.insertText)(await result.findByText('bar'), 'foo');
|
56
|
+
});
|
57
|
+
expect(onContentChangeMock).toHaveBeenCalledTimes(1);
|
58
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
59
|
+
});
|
60
|
+
it('Insert bullet list adds expected string', async () => {
|
61
|
+
cleanup = (0, prosemirror_1.mockCreateRange)();
|
62
|
+
const inputData = '<p>foo</p><p>bar</p>';
|
63
|
+
const expectedOutput = '<p></p><ul><li><p></p></li></ul><p>foo</p><p>bar</p>';
|
64
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
65
|
+
await act(async () => {
|
66
|
+
await user_event_1.default.click(await result.findByTestId('editor-menu-add-bullet_list'));
|
67
|
+
});
|
68
|
+
expect(onContentChangeMock).toHaveBeenCalledTimes(1);
|
69
|
+
expect(onContentChangeMock).toHaveBeenLastCalledWith(expectedOutput, '');
|
70
|
+
});
|
71
|
+
});
|
72
|
+
//# sourceMappingURL=List.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"List.test.js","sourceRoot":"","sources":["../../../__tests__/editor/List.test.tsx"],"names":[],"mappings":";;;;;AAAA,kDAAuD;AACvD,sDAAsD;AACtD,gGAAoF;AACpF,6EAAmD;AACnD,wCAA0C;AAE1C,MAAM,GAAG,GAAG,WAAuD,CAAA;AAEnE,QAAQ,CAAC,eAAe,EAAE,GAAG,EAAE;IAC7B,IAAI,OAA4B,CAAA;IAChC,IAAI,mBAA8B,CAAA;IAElC,UAAU,CAAC,GAAG,EAAE;QACd,mBAAmB,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IACjC,CAAC,CAAC,CAAA;IAEF,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,OAAO,EAAE,CAAC;YACZ,OAAO,EAAE,CAAA;QACX,CAAC;QACD,OAAO,GAAG,IAAI,CAAA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AAmB,CAAC,CAAC,wBAAwB,CAAC,cAAc,EAAE,EAAE,CAAC,CAAA;IAC1E,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Table.test.d.ts","sourceRoot":"","sources":["../../../__tests__/editor/Table.test.tsx"],"names":[],"mappings":"AAIA,OAAO,2BAA2B,CAAA"}
|
@@ -0,0 +1,172 @@
|
|
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 = require("@testing-library/react");
|
7
|
+
const user_event_1 = __importDefault(require("@testing-library/user-event"));
|
8
|
+
const renderEditableGradingInstruction_1 = require("../utils/renderEditableGradingInstruction");
|
9
|
+
const util_1 = require("../utils/util");
|
10
|
+
require("@testing-library/jest-dom");
|
11
|
+
const act = react_1.act;
|
12
|
+
describe('Table', () => {
|
13
|
+
let cleanup;
|
14
|
+
let onContentChangeMock;
|
15
|
+
beforeEach(() => {
|
16
|
+
onContentChangeMock = jest.fn();
|
17
|
+
});
|
18
|
+
afterEach(() => {
|
19
|
+
if (cleanup) {
|
20
|
+
cleanup();
|
21
|
+
}
|
22
|
+
cleanup = null;
|
23
|
+
});
|
24
|
+
it('Table is rendered as expected', () => {
|
25
|
+
const inputData = '<table class="e-table"><tbody><tr><td>foo</td></tr></tbody></table>';
|
26
|
+
const expectedOutput = '<table class="e-table"><tbody><tr><td>foo</td></tr></tbody></table>';
|
27
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData);
|
28
|
+
const table = result.container.querySelector('.ProseMirror');
|
29
|
+
expect(table.innerHTML).toBe(expectedOutput);
|
30
|
+
});
|
31
|
+
it('Change in table is returned as expected', async () => {
|
32
|
+
cleanup = mockCreateRange();
|
33
|
+
const inputData = '<table class="e-table"><tbody><tr><td>foo</td></tr></tbody></table>';
|
34
|
+
const expectedOutput = '<table class="e-table"><tbody><tr><td>bar</td></tr></tbody></table>';
|
35
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
36
|
+
await act(async () => {
|
37
|
+
(0, util_1.insertText)(await result.findByText('foo'), 'bar');
|
38
|
+
});
|
39
|
+
expect(onContentChangeMock).toHaveBeenCalledTimes(1);
|
40
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
41
|
+
});
|
42
|
+
it('Insert table adds expected table', async () => {
|
43
|
+
const inputData = '';
|
44
|
+
const expectedOutput = '<table class="e-table e-width-half"><tbody><tr><td></td><td></td></tr><tr><td></td><td></td></tr></tbody></table>';
|
45
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
46
|
+
await act(async () => {
|
47
|
+
await user_event_1.default.click(await result.findByTestId('editor-menu-add-table'));
|
48
|
+
});
|
49
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
50
|
+
});
|
51
|
+
it('Remove table removes table', async () => {
|
52
|
+
const inputData = '<table><tbody><tr><td>foo</td></tr></tbody></table>';
|
53
|
+
const expectedOutput = '<p></p>';
|
54
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
55
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Poista taulukko');
|
56
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
57
|
+
});
|
58
|
+
it('Insert column adds column', async () => {
|
59
|
+
const inputData = '<table><tbody><tr><td>foo</td></tr></tbody></table>';
|
60
|
+
const expectedOutput = '<table><tbody><tr><td>foo</td><td></td></tr></tbody></table>';
|
61
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
62
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Lisää sarake');
|
63
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
64
|
+
});
|
65
|
+
it('Remove column removes column', async () => {
|
66
|
+
const inputData = '<table><tbody><tr><td>foo</td><td>bar</td></tr></tbody></table>';
|
67
|
+
const expectedOutput = '<table><tbody><tr><td>bar</td></tr></tbody></table>';
|
68
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
69
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Poista sarake');
|
70
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
71
|
+
});
|
72
|
+
it('Insert row adds row', async () => {
|
73
|
+
const inputData = '<table><tbody><tr><td>foo</td></tr></tbody></table>';
|
74
|
+
const expectedOutput = '<table><tbody><tr><td>foo</td></tr><tr><td></td></tr></tbody></table>';
|
75
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
76
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Lisää rivi');
|
77
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
78
|
+
});
|
79
|
+
it('Remove row removes row', async () => {
|
80
|
+
const inputData = '<table><tbody><tr><td>foo</td></tr><tr><td>bar</td></tr></tbody></table>';
|
81
|
+
const expectedOutput = '<table><tbody><tr><td>bar</td></tr></tbody></table>';
|
82
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
83
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Poista rivi');
|
84
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
85
|
+
});
|
86
|
+
it('Full width changes full width class to table', async () => {
|
87
|
+
const inputData = '<table class="e-width-half"><tbody><tr><td>foo</td></tr></tbody></table>';
|
88
|
+
const expectedOutput = '<table class="e-width-full"><tbody><tr><td>foo</td></tr></tbody></table>';
|
89
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
90
|
+
expect(result.queryByText('Puolikas leveys')).not.toBeInTheDocument();
|
91
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Täysi leveys');
|
92
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
93
|
+
});
|
94
|
+
it('Half width changes half width class to table', async () => {
|
95
|
+
const inputData = '<table class="e-width-full"><tbody><tr><td>foo</td></tr></tbody></table>';
|
96
|
+
const expectedOutput = '<table class="e-width-half"><tbody><tr><td>foo</td></tr></tbody></table>';
|
97
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
98
|
+
expect(result.queryByText('Täysi leveys')).not.toBeInTheDocument();
|
99
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Puolikas leveys');
|
100
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
101
|
+
});
|
102
|
+
it('Remove borders adds e-table--borderless class to table', async () => {
|
103
|
+
const inputData = '<table><tbody><tr><td>foo</td></tr></tbody></table>';
|
104
|
+
const expectedOutput = '<table class="e-table--borderless"><tbody><tr><td>foo</td></tr></tbody></table>';
|
105
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
106
|
+
expect(result.queryByText('Lisää reunat')).not.toBeInTheDocument();
|
107
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Poista reunat');
|
108
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
109
|
+
});
|
110
|
+
it('Add borders removes e-table--borderless class from table', async () => {
|
111
|
+
const inputData = '<table class="e-table--borderless"><tbody><tr><td>foo</td></tr></tbody></table>';
|
112
|
+
const expectedOutput = '<table><tbody><tr><td>foo</td></tr></tbody></table>';
|
113
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
114
|
+
expect(result.queryByText('Poista reunat')).not.toBeInTheDocument();
|
115
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Lisää reunat');
|
116
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
117
|
+
});
|
118
|
+
it('Remove zebra removes class from table', async () => {
|
119
|
+
const inputData = '<table class="e-table--zebra"><tbody><tr><td>foo</td></tr></tbody></table>';
|
120
|
+
const expectedOutput = '<table><tbody><tr><td>foo</td></tr></tbody></table>';
|
121
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
122
|
+
expect(result.queryByText('Lisää raidat')).not.toBeInTheDocument();
|
123
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Poista raidat');
|
124
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
125
|
+
});
|
126
|
+
it('Add zebra adds e-table--zebra class to table', async () => {
|
127
|
+
const inputData = '<table><tbody><tr><td>foo</td></tr></tbody></table>';
|
128
|
+
const expectedOutput = '<table class="e-table--zebra"><tbody><tr><td>foo</td></tr></tbody></table>';
|
129
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
130
|
+
expect(result.queryByText('Poista raidat')).not.toBeInTheDocument();
|
131
|
+
await clickTableMenuButtonWithFocusOnCell(result, 'foo', 'Lisää raidat');
|
132
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
133
|
+
});
|
134
|
+
});
|
135
|
+
async function clickTableMenuButtonWithFocusOnCell(result, cellText, buttonText) {
|
136
|
+
await act(async () => {
|
137
|
+
await focusOnTablesCell(result, cellText);
|
138
|
+
await user_event_1.default.click(await result.findByText(buttonText));
|
139
|
+
});
|
140
|
+
}
|
141
|
+
async function focusOnTablesCell(result, text) {
|
142
|
+
// Replace cell's text with same text
|
143
|
+
// Hack to get focus on cell without need to mock createRange
|
144
|
+
(0, util_1.insertText)(await result.findByText(text), text);
|
145
|
+
}
|
146
|
+
function mockCreateRange() {
|
147
|
+
const originalCreateRange = global.window.document.createRange;
|
148
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
149
|
+
// @ts-expect-error
|
150
|
+
global.Range = function Range() { };
|
151
|
+
const createContextualFragment = (html) => {
|
152
|
+
const div = document.createElement('div');
|
153
|
+
div.innerHTML = html;
|
154
|
+
return div.children[0];
|
155
|
+
};
|
156
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
157
|
+
// @ts-expect-error
|
158
|
+
Range.prototype.createContextualFragment = (html) => createContextualFragment(html);
|
159
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
160
|
+
// @ts-expect-error
|
161
|
+
global.window.document.createRange = function createRange() {
|
162
|
+
return {
|
163
|
+
setEnd: () => { },
|
164
|
+
setStart: () => { },
|
165
|
+
getBoundingClientRect: () => ({ right: 0 }),
|
166
|
+
getClientRects: () => [],
|
167
|
+
createContextualFragment
|
168
|
+
};
|
169
|
+
};
|
170
|
+
return () => (global.window.document.createRange = originalCreateRange);
|
171
|
+
}
|
172
|
+
//# sourceMappingURL=Table.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Table.test.js","sourceRoot":"","sources":["../../../__tests__/editor/Table.test.tsx"],"names":[],"mappings":";;;;;AAAA,kDAAqE;AACrE,6EAAmD;AACnD,gGAAoF;AACpF,wCAA0C;AAC1C,qCAAkC;AAElC,MAAM,GAAG,GAAG,WAAuD,CAAA;AAEnE,QAAQ,CAAC,OAAO,EAAE,GAAG,EAAE;IACrB,IAAI,OAA4B,CAAA;IAChC,IAAI,mBAA8B,CAAA;IAElC,UAAU,CAAC,GAAG,EAAE;QACd,mBAAmB,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IACjC,CAAC,CAAC,CAAA;IAEF,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,OAAO,EAAE,CAAC;YACZ,OAAO,EAAE,CAAA;QACX,CAAC;QACD,OAAO,GAAG,IA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AAS,WAAW;QACvD,OAAO;YACL,MAAM,EAAE,GAAG,EAAE,GAAE,CAAC;YAChB,QAAQ,EAAE,GAAG,EAAE,GAAE,CAAC;YAClB,qBAAqB,EAAE,GAAG,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,CAAC;YAC3C,cAAc,EAAE,GAAG,EAAE,CAAC,EAAE;YACxB,wBAAwB;SACzB,CAAA;IACH,CAAC,CAAA;IACD,OAAO,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,WAAW,GAAG,mBAAmB,CAAC,CAAA;AACzE,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"no-wrap.test.d.ts","sourceRoot":"","sources":["../../../__tests__/editor/no-wrap.test.tsx"],"names":[],"mappings":""}
|
@@ -0,0 +1,43 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
const react_1 = require("@testing-library/react");
|
4
|
+
const prosemirror_1 = require("../utils/prosemirror");
|
5
|
+
const renderEditableGradingInstruction_1 = require("../utils/renderEditableGradingInstruction");
|
6
|
+
const act = react_1.act;
|
7
|
+
describe('Editor - e-no-wrap', () => {
|
8
|
+
let cleanup;
|
9
|
+
let onContentChangeMock;
|
10
|
+
beforeEach(() => {
|
11
|
+
onContentChangeMock = jest.fn();
|
12
|
+
});
|
13
|
+
afterEach(() => {
|
14
|
+
if (cleanup) {
|
15
|
+
cleanup();
|
16
|
+
}
|
17
|
+
cleanup = null;
|
18
|
+
});
|
19
|
+
it('HR is rendered as expected', () => {
|
20
|
+
const inputData = '<p>bar</p><hr/>';
|
21
|
+
const expectedOutput = '<p>bar</p><hr>';
|
22
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData);
|
23
|
+
const table = result.container.querySelector('.ProseMirror');
|
24
|
+
expect(table.innerHTML).toBe(expectedOutput);
|
25
|
+
});
|
26
|
+
it('Change in content causes HR to be returned as expected', async () => {
|
27
|
+
cleanup = (0, prosemirror_1.mockCreateRange)();
|
28
|
+
const inputData = '<p>foo</p><hr/><p>bar</p>';
|
29
|
+
const expectedOutput = '<p>foo</p><hr/><p>foo</p>';
|
30
|
+
const result = (0, renderEditableGradingInstruction_1.renderGradingInstruction)(inputData, onContentChangeMock);
|
31
|
+
await act(async () => {
|
32
|
+
insertText(await result.findByText('bar'), 'foo');
|
33
|
+
});
|
34
|
+
expect(onContentChangeMock).toHaveBeenCalledTimes(1);
|
35
|
+
expect(onContentChangeMock).toHaveBeenCalledWith(expectedOutput, '');
|
36
|
+
});
|
37
|
+
});
|
38
|
+
function insertText(element, text) {
|
39
|
+
react_1.fireEvent.input(element, {
|
40
|
+
target: { innerText: text, innerHTML: text }
|
41
|
+
});
|
42
|
+
}
|
43
|
+
//# sourceMappingURL=no-wrap.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"no-wrap.test.js","sourceRoot":"","sources":["../../../__tests__/editor/no-wrap.test.tsx"],"names":[],"mappings":";;AAAA,kDAAkE;AAClE,sDAAsD;AACtD,gGAAoF;AAEpF,MAAM,GAAG,GAAG,WAAuD,CAAA;AAEnE,QAAQ,CAAC,oBAAoB,EAAE,GAAG,EAAE;IAClC,IAAI,OAA4B,CAAA;IAChC,IAAI,mBAA8B,CAAA;IAElC,UAAU,CAAC,GAAG,EAAE;QACd,mBAAmB,GAAG,IAAI,CAAC,EAAE,EAAE,CAAA;IACjC,CAAC,CAAC,CAAA;IAEF,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,OAAO,EAAE,CAAC;YACZ,OAAO,EAAE,CAAA;QACX,CAAC;QACD,OAAO,GAAG,IAAI,CAAA;IAChB,CAAC,CAAC,CAAA;IAEF,EAAE,CAAC,4BAA4B,EAAE,GAAG,EAAE;QACpC,MAAM,SAAS,GAAG,iBAAiB,CAAA;QACnC,MAAM,cAAc,GAAG,gBAAgB,CAAA;QACvC,MAAM,MAAM,GAAG,IA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