@digabi/exam-engine-core 19.0.4-alpha.3 → 19.0.4-alpha.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,6 @@
1
+ /// <reference types="react" />
2
+ export declare function AnswerCharacterCounter({ characterCount, maxLength, }: {
3
+ characterCount: number;
4
+ maxLength: number | undefined;
5
+ }): JSX.Element;
6
+ //# sourceMappingURL=AnswerCharacterCounter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AnswerCharacterCounter.d.ts","sourceRoot":"","sources":["../../../src/components/grading/AnswerCharacterCounter.tsx"],"names":[],"mappings":";AAGA,wBAAgB,sBAAsB,CAAC,EACrC,cAAc,EACd,SAAS,GACV,EAAE;IACD,cAAc,EAAE,MAAM,CAAA;IACtB,SAAS,EAAE,MAAM,GAAG,SAAS,CAAA;CAC9B,eAqBA"}
@@ -0,0 +1,21 @@
1
+ import React from 'react';
2
+ import { useExamTranslation } from '../../i18n';
3
+ export function AnswerCharacterCounter({ characterCount, maxLength, }) {
4
+ const { t } = useExamTranslation();
5
+ const percentage = countSurplusPercentage(characterCount, maxLength);
6
+ return (React.createElement("div", { className: "e-font-size-xs e-grading-answer-length" },
7
+ t('answer-length', {
8
+ count: characterCount,
9
+ }),
10
+ percentage > 0 ? (React.createElement("span", { className: "e-grading-answer-max-length-surplus" }, t('max-length-surplus', {
11
+ maxLength,
12
+ percentage,
13
+ }))) : ('')));
14
+ }
15
+ function countSurplusPercentage(characters, maxCharacters) {
16
+ if (!maxCharacters || characters <= maxCharacters) {
17
+ return 0;
18
+ }
19
+ return Math.floor((100 * characters) / maxCharacters - 100);
20
+ }
21
+ //# sourceMappingURL=AnswerCharacterCounter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AnswerCharacterCounter.js","sourceRoot":"","sources":["../../../src/components/grading/AnswerCharacterCounter.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAA;AAE/C,MAAM,UAAU,sBAAsB,CAAC,EACrC,cAAc,EACd,SAAS,GAIV;IACC,MAAM,EAAE,CAAC,EAAE,GAAG,kBAAkB,EAAE,CAAA;IAClC,MAAM,UAAU,GAAG,sBAAsB,CAAC,cAAc,EAAE,SAAS,CAAC,CAAA;IAEpE,OAAO,CACL,6BAAK,SAAS,EAAC,wCAAwC;QACpD,CAAC,CAAC,eAAe,EAAE;YAClB,KAAK,EAAE,cAAc;SACtB,CAAC;QACD,UAAU,GAAG,CAAC,CAAC,CAAC,CAAC,CAChB,8BAAM,SAAS,EAAC,qCAAqC,IAClD,CAAC,CAAC,oBAAoB,EAAE;YACvB,SAAS;YACT,UAAU;SACX,CAAC,CACG,CACR,CAAC,CAAC,CAAC,CACF,EAAE,CACH,CACG,CACP,CAAA;AACH,CAAC;AAED,SAAS,sBAAsB,CAAC,UAAkB,EAAE,aAAwC;IAC1F,IAAI,CAAC,aAAa,IAAI,UAAU,IAAI,aAAa,EAAE;QACjD,OAAO,CAAC,CAAA;KACT;IACD,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,GAAG,UAAU,CAAC,GAAG,aAAa,GAAG,GAAG,CAAC,CAAA;AAC7D,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"Grading.d.ts","sourceRoot":"","sources":["../../../src/components/grading/Grading.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkD,MAAM,OAAO,CAAA;;AAyGtE,wBAA6E"}
1
+ {"version":3,"file":"Grading.d.ts","sourceRoot":"","sources":["../../../src/components/grading/Grading.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkD,MAAM,OAAO,CAAA;;AAmHtE,wBAA6E"}
@@ -49,29 +49,29 @@ function Grading() {
49
49
  pregrading: [],
50
50
  censoring: [],
51
51
  });
52
- const { questionId, type, value, displayNumber } = answersByQuestionId[answerId];
53
- if (type === 'choice') {
52
+ useEffect(() => {
53
+ setAnnotations(annotationsStorage.current[answerId]);
54
+ });
55
+ const { type: answerType, value } = answersByQuestionId[answerId];
56
+ if (answerType === 'choice') {
54
57
  return React.createElement("div", null, "choice answer");
55
58
  }
56
- function selectQuestion(id) {
59
+ function selectQuestion(e, id) {
60
+ e.preventDefault();
57
61
  setAnswerId(id);
58
62
  setAnnotations(annotationsStorage.current[id]);
59
63
  }
60
64
  function saveAnnotations(annotations) {
61
65
  annotationsStorage.current[answerId] = annotations;
62
- console.log('saving: ', annotationsStorage.current);
66
+ setAnnotations({ ...annotationsStorage.current[answerId] });
63
67
  }
64
68
  return (React.createElement(I18nextProvider, { i18n: i18n },
65
69
  React.createElement("main", { className: "e-exam" },
66
- React.createElement("div", null, answerIds.map((id) => (React.createElement("button", { onClick: () => selectQuestion(id), key: id }, answersByQuestionId[id].displayNumber)))),
67
- React.createElement("div", null,
68
- "Teht\u00E4v\u00E4 ",
69
- displayNumber,
70
- " (",
71
- questionId,
72
- ")"),
70
+ React.createElement("div", { className: "grading-navi" }, answerIds.map((id) => id === answerId ? (React.createElement("span", { key: id, className: "grading-navi-item" }, answersByQuestionId[id].displayNumber)) : (React.createElement("a", { className: "grading-navi-item", href: "", onClick: (e) => selectQuestion(e, id), key: id }, answersByQuestionId[id].displayNumber)))),
73
71
  React.createElement(GradingAnswer, { ...{
74
- type,
72
+ isReadOnly: false,
73
+ answerType,
74
+ gradingRole: 'censoring',
75
75
  value,
76
76
  annotations,
77
77
  saveAnnotations,
@@ -1 +1 @@
1
- {"version":3,"file":"Grading.js","sourceRoot":"","sources":["../../../src/components/grading/Grading.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACtE,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAA;AAC/C,OAAO,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAA;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAA;AAC3C,OAAO,EAAE,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E;QACzF,kBAAkB,CAAC,OAAO,CAAC,QAAQ,CAAC,GAAG,WAAW,CAAA;QAClD,cAAc,CAAC,EAAE,GAAG,kBAAkB,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAA;IAC7D,CAAC;IAED,OAAO,CACL,oBAAC,eAAe,IAAC,IAAI,EAAE,IAAI;QACzB,8BAAM,SAAS,EAAC,QAAQ;YACtB,6BAAK,SAAS,EAAC,cAAc,IAC1B,SAAS,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,CACpB,EAAE,KAAK,QAAQ,CAAC,CAAC,CAAC,CAChB,8BAAM,GAAG,EAAE,EAAE,EAAE,SAAS,EAAC,mBAAmB,IACzC,mBAAmB,CAAC,EAAE,CAAC,CAAC,aAAa,CACjC,CACR,CAAC,CAAC,CAAC,CACF,2BAAG,SAAS,EAAC,mBAAmB,EAAC,IAAI,EAAC,EAAE,EAAC,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,cAAc,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,GAAG,EAAE,EAAE,IACpF,mBAAmB,CAAC,EAAE,CAAC,CAAC,aAAa,CACpC,CACL,CACF,CACG;YAEN,oBAAC,aAAa,OACR;oBACF,UAAU,EAAE,KAAK;oBACjB,UAAU;oBACV,WAAW,EAAE,WAAW;oBACxB,KAAK;oBACL,WAAW;oBACX,eAAe;iBAChB,GACD,CACG,CACS,CACnB,CAAA;AACH,CAAC;AAED,eAAe,KAAK,CAAC,IAAI,CAAC,kBAAkB,CAAC,qBAAqB,CAAC,OAAO,CAAC,CAAC,CAAC,CAAA"}
@@ -4,15 +4,16 @@ type Annotations = {
4
4
  pregrading: Annotation[];
5
5
  censoring: Annotation[];
6
6
  };
7
- type GradingType = 'pregrading' | 'censoring';
8
- export declare function GradingAnswer({ answer: { type, characterCount, value }, isReadOnly, gradingRole, annotations, saveAnnotations, maxLength, }: {
7
+ type GradingRole = 'pregrading' | 'censoring';
8
+ export declare function GradingAnswer({ answer: { type, characterCount, value }, language, isReadOnly, gradingRole, annotations, saveAnnotations, maxLength, }: {
9
9
  answer: {
10
10
  type: 'richText' | 'text';
11
11
  characterCount: number;
12
12
  value: string;
13
13
  };
14
+ language: string;
14
15
  isReadOnly: boolean;
15
- gradingRole: GradingType;
16
+ gradingRole: GradingRole;
16
17
  maxLength?: number;
17
18
  annotations: Annotations;
18
19
  saveAnnotations: (annotations: Annotations) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"GradingAnswer.d.ts","sourceRoot":"","sources":["../../../src/components/grading/GradingAnswer.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAqBlC,KAAK,WAAW,GAAG;IAAE,UAAU,EAAE,UAAU,EAAE,CAAC;IAAC,SAAS,EAAE,UAAU,EAAE,CAAA;CAAE,CAAA;AAExE,KAAK,WAAW,GAAG,YAAY,GAAG,WAAW,CAAA;AAC7C,wBAAgB,aAAa,CAAC,EAC5B,MAAM,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,EAAE,EACvC,UAAU,EACV,WAAW,EACX,WAAW,EACX,eAAe,EACf,SAAS,GACV,EAAE;IACD,MAAM,EAAE;QAAE,IAAI,EAAE,UAAU,GAAG,MAAM,CAAC;QAAC,cAAc,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAA;IAC5E,UAAU,EAAE,OAAO,CAAA;IACnB,WAAW,EAAE,WAAW,CAAA;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,WAAW,EAAE,WAAW,CAAA;IACxB,eAAe,EAAE,CAAC,WAAW,EAAE,WAAW,KAAK,IAAI,CAAA;CACpD,eAwRA"}
1
+ {"version":3,"file":"GradingAnswer.d.ts","sourceRoot":"","sources":["../../../src/components/grading/GradingAnswer.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAyBlC,KAAK,WAAW,GAAG;IAAE,UAAU,EAAE,UAAU,EAAE,CAAC;IAAC,SAAS,EAAE,UAAU,EAAE,CAAA;CAAE,CAAA;AAExE,KAAK,WAAW,GAAG,YAAY,GAAG,WAAW,CAAA;AAC7C,wBAAgB,aAAa,CAAC,EAC5B,MAAM,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,EAAE,EACvC,QAAQ,EACR,UAAU,EACV,WAAW,EACX,WAAW,EACX,eAAe,EACf,SAAS,GACV,EAAE;IACD,MAAM,EAAE;QAAE,IAAI,EAAE,UAAU,GAAG,MAAM,CAAC;QAAC,cAAc,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAA;IAC5E,QAAQ,EAAE,MAAM,CAAA;IAChB,UAAU,EAAE,OAAO,CAAA;IACnB,WAAW,EAAE,WAAW,CAAA;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,WAAW,EAAE,WAAW,CAAA;IACxB,eAAe,EAAE,CAAC,WAAW,EAAE,WAAW,KAAK,IAAI,CAAA;CACpD,eAkSA"}
@@ -1,10 +1,13 @@
1
- import React, { useLayoutEffect, useRef } from 'react';
2
- import { annotationFromMousePosition, hasTextSelectedInAnswerText, imageAnnotationMouseDownInfo, mergeAnnotation, selectionHasNothingToUnderline, showAndPositionPopup, textAnnotationFromRange, } from './editAnnotations';
1
+ import React, { useEffect, useLayoutEffect, useRef } from 'react';
2
+ import { annotationFromMousePosition, getOverlappingMessages, hasTextSelectedInAnswerText, imageAnnotationMouseDownInfo, mergeAnnotation, selectionHasNothingToUnderline, showAndPositionElement, textAnnotationFromRange, } from './editAnnotations';
3
3
  import { renderAnnotations, renderImageAnnotationByImage, updateImageAnnotationMarkSize, wrapAllImages, } from '../../renderAnnotations';
4
4
  import GradingAnswerAnnotationList from './GradingAnswerAnnotationList';
5
- import { useExamTranslation } from '../../i18n';
5
+ import { changeLanguage, initI18n } from '../../i18n';
6
6
  import { updateLargeImageWarnings } from './largeImageDetector';
7
- export function GradingAnswer({ answer: { type, characterCount, value }, isReadOnly, gradingRole, annotations, saveAnnotations, maxLength, }) {
7
+ import { I18nextProvider } from 'react-i18next';
8
+ import { useCached } from '../../useCached';
9
+ import { AnswerCharacterCounter } from './AnswerCharacterCounter';
10
+ export function GradingAnswer({ answer: { type, characterCount, value }, language, isReadOnly, gradingRole, annotations, saveAnnotations, maxLength, }) {
8
11
  const answerRef = useRef(null);
9
12
  const popupRef = useRef(null);
10
13
  const messageRef = useRef(null);
@@ -12,15 +15,33 @@ export function GradingAnswer({ answer: { type, characterCount, value }, isReadO
12
15
  let newAnnotationObject;
13
16
  let savedAnnotations;
14
17
  const imgAnnotationState = { start: undefined, element: undefined, img: undefined };
15
- let isPopupVisible = false;
16
- let closeTooltipTimeout;
18
+ let isEditAnnotationPopupVisible = false;
17
19
  let annotationDataForTooltip;
20
+ let annotationPositionForPopup;
21
+ let hideTooltipTimeout;
18
22
  let windowResizeTimeout;
19
- let popupPosition;
23
+ function onAnnotationOrListClick(e) {
24
+ var _a;
25
+ const element = e.target;
26
+ if (element instanceof HTMLElement) {
27
+ if (element.tagName === 'MARK') {
28
+ showTooltip(element);
29
+ }
30
+ else if (element.tagName === 'LI') {
31
+ const index = (_a = element.dataset.listNumber) === null || _a === void 0 ? void 0 : _a.replace(')', '');
32
+ const mark = document.querySelector(`.e-annotation[data-index="${index}"]`);
33
+ showTooltip(mark);
34
+ mark.scrollIntoView({ block: 'center', behavior: 'smooth' });
35
+ }
36
+ else if (annotationDataForTooltip) {
37
+ hideTooltip();
38
+ }
39
+ }
40
+ }
20
41
  function editExistingAnnotation(e) {
21
42
  if (e.target.closest('.editable')) {
22
43
  toggle(tooltipRef.current, false);
23
- showOldAnnotationPopup(popupPosition);
44
+ showExistingAnnotationPopup(annotationPositionForPopup);
24
45
  }
25
46
  }
26
47
  useLayoutEffect(() => {
@@ -35,98 +56,98 @@ export function GradingAnswer({ answer: { type, characterCount, value }, isReadO
35
56
  windowResizeTimeout = setTimeout(() => updateLargeImageWarnings(answerRef.current), 1000);
36
57
  };
37
58
  });
38
- const { t } = useExamTranslation();
39
- const percentage = countSurplusPercentage(characterCount, maxLength);
40
- return (React.createElement("div", { className: "e-grading-answer-wrapper" },
41
- React.createElement("div", { className: "e-grading-answer e-line-height-l e-mrg-b-1", ref: answerRef, onMouseDown: (e) => onMouseDown(e), onMouseOver: (e) => onMouseOver(e.target) }),
42
- React.createElement("div", { className: "e-font-size-xs e-grading-answer-length" },
43
- t('answer-length', {
44
- count: characterCount,
45
- }),
46
- percentage > 0 ? (React.createElement("span", { className: "e-grading-answer-max-length-surplus" }, t('max-length-surplus', {
47
- maxLength,
48
- percentage,
49
- }))) : ('')),
50
- React.createElement(GradingAnswerAnnotationList, { censoring: annotations.censoring, pregrading: annotations.pregrading, singleGrading: false }),
51
- React.createElement("form", { style: { display: 'none' }, ref: popupRef, className: "e-grading-answer-popup e-grading-answer-add-annotation", onSubmit: (e) => onSubmit(e) },
52
- React.createElement("input", { name: "message", className: "e-grading-answer-add-annotation-text", type: "text", ref: messageRef }),
53
- React.createElement("button", { className: "e-grading-answer-add-annotation-button", type: "submit", "data-i18n": "arpa.annotate" }, "Merkitse")),
54
- React.createElement("div", { style: { display: 'none' }, ref: tooltipRef, className: "e-grading-answer-tooltip e-grading-answer-popup", onMouseOver: onMouseOverTooltip, onMouseOut: closeTooltip },
55
- React.createElement("span", { onClick: (e) => editExistingAnnotation(e), className: "e-grading-answer-tooltip-label" }, "tooltip text"),
56
- React.createElement("button", { onClick: (e) => removeAnnotation(e), className: "e-grading-answer-tooltip-remove" }, "\u00D7"))));
59
+ const i18n = useCached(() => initI18n(language));
60
+ useEffect(changeLanguage(i18n, language));
61
+ return (React.createElement(I18nextProvider, { i18n: i18n },
62
+ React.createElement("div", { onClick: (e) => onAnnotationOrListClick(e), className: "e-grading-answer-wrapper" },
63
+ React.createElement("div", { className: "e-grading-answer e-line-height-l e-mrg-b-1", ref: answerRef, onMouseDown: (e) => onAnswerMouseDown(e), onMouseOver: (e) => onMouseOverAnnotation(e.target) }),
64
+ React.createElement(AnswerCharacterCounter, { characterCount: characterCount, maxLength: maxLength }),
65
+ React.createElement(GradingAnswerAnnotationList, { censoring: annotations.censoring, pregrading: annotations.pregrading, singleGrading: false }),
66
+ React.createElement("form", { style: { display: 'none' }, ref: popupRef, className: "e-grading-answer-popup e-grading-answer-add-annotation", onSubmit: (e) => onSubmitAnnotation(e) },
67
+ React.createElement("input", { name: "message", className: "e-grading-answer-add-annotation-text", type: "text", ref: messageRef }),
68
+ React.createElement("button", { className: "e-grading-answer-add-annotation-button", type: "submit", "data-i18n": "arpa.annotate" }, "Merkitse"),
69
+ React.createElement("button", { className: "e-grading-answer-close-popup", onClick: (e) => {
70
+ e.preventDefault();
71
+ hideAnnotationPopupAndRefresh();
72
+ } }, "\u00D7")),
73
+ React.createElement("div", { style: { display: 'none' }, ref: tooltipRef, className: "e-grading-answer-tooltip e-grading-answer-popup", onMouseOver: onMouseOverTooltip, onMouseOut: hideTooltip },
74
+ React.createElement("span", { onClick: (e) => editExistingAnnotation(e), className: "e-grading-answer-tooltip-label" }, "tooltip text"),
75
+ React.createElement("button", { onClick: (e) => removeAnnotation(e), className: "e-grading-answer-tooltip-remove" }, "\u00D7")))));
57
76
  function removeAnnotation(e) {
58
77
  e.preventDefault();
59
- closeTooltip();
60
- savedAnnotations[annotationDataForTooltip.type].splice(annotationDataForTooltip.index, 1);
78
+ hideTooltip();
79
+ savedAnnotations[annotationDataForTooltip.role].splice(annotationDataForTooltip.index, 1);
61
80
  annotationDataForTooltip = undefined;
62
81
  saveAnnotations(savedAnnotations);
63
82
  }
64
- function closeTooltip() {
65
- closeTooltipTimeout = setTimeout(() => {
83
+ function hideTooltip() {
84
+ hideTooltipTimeout = setTimeout(() => {
66
85
  toggle(tooltipRef.current, false);
67
86
  }, 400);
68
87
  }
69
88
  function onMouseOverTooltip() {
70
- clearTimeout(closeTooltipTimeout);
89
+ clearTimeout(hideTooltipTimeout);
71
90
  }
72
- function onMouseOut(e) {
91
+ function onMouseOutFromTooltip(e) {
73
92
  const target = e.target;
74
93
  if (target.tagName === 'MARK') {
75
- clearTimeout(closeTooltipTimeout);
76
- closeTooltip();
94
+ clearTimeout(hideTooltipTimeout);
95
+ hideTooltip();
77
96
  }
78
- answerRef.current.removeEventListener('mouseout', onMouseOut);
97
+ answerRef.current.removeEventListener('mouseout', onMouseOutFromTooltip);
79
98
  }
80
99
  function showTooltip(target) {
81
- clearTimeout(closeTooltipTimeout);
100
+ clearTimeout(hideTooltipTimeout);
82
101
  const tooltip = tooltipRef.current;
83
102
  const { type, listIndex, message } = target.dataset;
84
103
  tooltip.classList.toggle('editable', !isReadOnly && type === gradingRole);
85
- const rect = target.getBoundingClientRect();
86
- popupPosition = rect;
87
- Object.assign(tooltip.style, showAndPositionPopup(rect, answerRef.current));
104
+ annotationPositionForPopup = target.getBoundingClientRect();
105
+ showAndPositionElement(annotationPositionForPopup, answerRef.current, tooltip);
88
106
  tooltip.querySelector('.e-grading-answer-tooltip-label').textContent = message || '–';
89
- annotationDataForTooltip = { index: Number(listIndex), type: type, message: message || '' };
90
- answerRef.current.addEventListener('mouseout', onMouseOut);
107
+ annotationDataForTooltip = { index: Number(listIndex), role: type, message: message || '' };
108
+ answerRef.current.addEventListener('mouseout', onMouseOutFromTooltip);
91
109
  }
92
- function onMouseOver(target) {
110
+ function onMouseOverAnnotation(target) {
93
111
  if (target.tagName === 'MARK' &&
94
- !isPopupVisible &&
112
+ !isEditAnnotationPopupVisible &&
95
113
  (!hasTextSelectedInAnswerText() || isReadOnly) &&
96
114
  !imgAnnotationState.element) {
97
115
  showTooltip(target);
98
116
  }
99
117
  }
100
- function showAnnotationPopup(rect) {
118
+ function showAnnotationPopup(rect, message) {
101
119
  annotationDataForTooltip = undefined;
102
- setupAnnotationPopup(rect, '');
120
+ setupAnnotationPopup(rect, message);
103
121
  }
104
- function showOldAnnotationPopup(rect) {
122
+ function showExistingAnnotationPopup(rect) {
105
123
  setupAnnotationPopup(rect, annotationDataForTooltip.message);
106
124
  }
107
125
  function setupAnnotationPopup(rect, message) {
108
- Object.assign(popupRef.current.style, showAndPositionPopup(rect, answerRef.current));
126
+ // Could be active from previous popup
127
+ window.removeEventListener('keydown', onKeyUpInAnnotationPopup);
128
+ showAndPositionElement(rect, answerRef.current, popupRef.current);
109
129
  const inputElement = messageRef.current;
110
130
  inputElement.value = message;
111
131
  inputElement.focus();
112
- isPopupVisible = true;
113
- window.addEventListener('keydown', onKeyUp);
132
+ isEditAnnotationPopupVisible = true;
133
+ window.addEventListener('keydown', onKeyUpInAnnotationPopup);
114
134
  }
115
- function closePopupAndRefresh() {
135
+ function hideAnnotationPopupAndRefresh() {
116
136
  newAnnotationObject = undefined;
117
137
  imgAnnotationState.element = undefined;
118
138
  imgAnnotationState.img = undefined;
119
- isPopupVisible = false;
120
- window.removeEventListener('keydown', onKeyUp);
139
+ isEditAnnotationPopupVisible = false;
140
+ window.removeEventListener('keydown', onKeyUpInAnnotationPopup);
121
141
  toggle(popupRef.current, false);
122
142
  renderAnswerWithAnnotations(savedAnnotations);
123
143
  }
124
- function onMouseDown(e) {
144
+ function onAnswerMouseDown(e) {
125
145
  var _a;
126
146
  if (isReadOnly) {
127
147
  return;
128
148
  }
129
- window.addEventListener('mouseup', onWindowMouseUp);
149
+ window.addEventListener('mouseup', onWindowMouseUpAfterAnswerMouseDown);
150
+ // Do annotations only with left mouse buttons
130
151
  if (e.button !== 0) {
131
152
  return;
132
153
  }
@@ -135,27 +156,22 @@ export function GradingAnswer({ answer: { type, characterCount, value }, isReadO
135
156
  if (!img) {
136
157
  return;
137
158
  }
138
- img.addEventListener('dragstart', preventDefaults);
159
+ img.addEventListener('dragstart', preventDefaults); // Prevent dragging images when marking image annotations
139
160
  imgAnnotationState.start = imageAnnotationMouseDownInfo(e, img);
140
161
  imgAnnotationState.img = img;
141
162
  window.addEventListener('mousemove', onMouseMoveForImageAnnotation);
142
163
  }
143
- function onWindowMouseUp(e) {
164
+ function onWindowMouseUpAfterAnswerMouseDown() {
144
165
  var _a, _b;
145
166
  (_a = imgAnnotationState.img) === null || _a === void 0 ? void 0 : _a.removeEventListener('dragstart', preventDefaults);
146
167
  window.removeEventListener('mousemove', onMouseMoveForImageAnnotation);
147
- window.removeEventListener('mouseup', onWindowMouseUp);
148
- if (isPopupVisible && e.target.closest('.popup') === null) {
149
- closePopupAndRefresh();
150
- return;
151
- }
168
+ window.removeEventListener('mouseup', onWindowMouseUpAfterAnswerMouseDown);
169
+ // Image annotation is being created since shape exists
152
170
  if (imgAnnotationState.element) {
153
- showAnnotationPopup((_b = imgAnnotationState.element) === null || _b === void 0 ? void 0 : _b.getBoundingClientRect());
154
- return;
155
- }
156
- if (isPopupVisible) {
171
+ showAnnotationPopup((_b = imgAnnotationState.element) === null || _b === void 0 ? void 0 : _b.getBoundingClientRect(), '');
157
172
  return;
158
173
  }
174
+ // Text annotation
159
175
  const selection = window.getSelection();
160
176
  if (selection && answerRef.current !== null && hasTextSelectedInAnswerText()) {
161
177
  const range = selection.getRangeAt(0);
@@ -163,8 +179,9 @@ export function GradingAnswer({ answer: { type, characterCount, value }, isReadO
163
179
  return;
164
180
  }
165
181
  const position = textAnnotationFromRange(answerRef.current, range);
166
- newAnnotationObject = { ...position, type: 'text', message: '' };
167
- showAnnotationPopup(range.getBoundingClientRect());
182
+ const message = getOverlappingMessages(savedAnnotations[gradingRole], position.startIndex, position.length);
183
+ newAnnotationObject = { ...position, type: 'text', message };
184
+ showAnnotationPopup(range.getBoundingClientRect(), message);
168
185
  const newAnnotations = { ...savedAnnotations };
169
186
  newAnnotations[gradingRole] = mergeAnnotation(answerRef.current, newAnnotationObject, savedAnnotations[gradingRole]);
170
187
  renderAnswerWithAnnotations(newAnnotations);
@@ -173,6 +190,7 @@ export function GradingAnswer({ answer: { type, characterCount, value }, isReadO
173
190
  function onMouseMoveForImageAnnotation(e) {
174
191
  preventDefaults(e);
175
192
  newAnnotationObject = annotationFromMousePosition(e, imgAnnotationState.start);
193
+ // Create shape on first mouse move and resize after that
176
194
  if (imgAnnotationState.element) {
177
195
  updateImageAnnotationMarkSize(imgAnnotationState.element, newAnnotationObject);
178
196
  }
@@ -190,25 +208,25 @@ export function GradingAnswer({ answer: { type, characterCount, value }, isReadO
190
208
  else {
191
209
  container.textContent = value;
192
210
  }
193
- renderAnnotations(container, annotations.pregrading, annotations.censoring);
194
- //TODO make titles optional for annotation rendering
195
- container.querySelectorAll('mark').forEach((mark) => mark.removeAttribute('title'));
211
+ renderAnnotations(container, annotations.pregrading, annotations.censoring, false);
196
212
  }
197
- function onSubmit(e) {
213
+ function onSubmitAnnotation(e) {
198
214
  e.preventDefault();
199
215
  const message = messageRef.current.value;
200
216
  if (annotationDataForTooltip) {
201
- savedAnnotations[annotationDataForTooltip.type][annotationDataForTooltip.index].message = message;
217
+ // Editing existing annotation message by clicking tooltip
218
+ savedAnnotations[annotationDataForTooltip.role][annotationDataForTooltip.index].message = message;
202
219
  }
203
220
  else {
221
+ // Saving new annotation
204
222
  savedAnnotations[gradingRole] = mergeAnnotation(answerRef.current, { ...newAnnotationObject, message }, savedAnnotations[gradingRole] || []);
205
223
  }
206
224
  toggle(popupRef.current, false);
207
225
  saveAnnotations(savedAnnotations);
208
226
  }
209
- function onKeyUp(e) {
210
- if (e.key === 'Escape' && isPopupVisible) {
211
- closePopupAndRefresh();
227
+ function onKeyUpInAnnotationPopup(e) {
228
+ if (e.key === 'Escape' && isEditAnnotationPopupVisible) {
229
+ hideAnnotationPopupAndRefresh();
212
230
  }
213
231
  }
214
232
  }
@@ -216,12 +234,6 @@ function preventDefaults(e) {
216
234
  e.preventDefault();
217
235
  e.stopPropagation();
218
236
  }
219
- function countSurplusPercentage(characters, maxCharacters) {
220
- if (!maxCharacters || characters <= maxCharacters) {
221
- return 0;
222
- }
223
- return Math.floor((100 * characters) / maxCharacters - 100);
224
- }
225
237
  function toggle(element, isVisible) {
226
238
  if (element instanceof HTMLElement) {
227
239
  element.style.display = isVisible ?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AAc,EAAE,CAAA;QAClB,MAAM,OAAO,GAAG,UAAU,CAAC,OAAQ,CAAC,KAAK,CAAA;QACzC,IAAI,wBAAwB,EAAE;YAC5B,0DAA0D;YAC1D,gBAAgB,CAAC,wBAAwB,CAAC,IAAI,CAAC,CAAC,wBAAwB,CAAC,KAAK,CAAC,CAAC,OAAO,GAAG,OAAO,CAAA;SAClG;aAAM;YACL,wBAAwB;YACxB,gBAAgB,CAAC,WAAW,CAAC,GAAG,eAAe,CAC7C,SAAS,CAAC,OAAQ,EAClB,EAAE,GAAG,mBAAoB,EAAE,OAAO,EAAE,EACpC,gBAAgB,CAAC,WAAW,CAAC,IAAI,EAAE,CACpC,CAAA;SACF;QACD,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,KAAK,CAAC,CAAA;QAC/B,eAAe,CAAC,gBAAgB,CAAC,CAAA;IACnC,CAAC;IAED,SAAS,wBAAwB,CAAC,CAAgB;QAChD,IAAI,CAAC,CAAC,GAAG,KAAK,QAAQ,IAAI,4BAA4B,EAAE;YACtD,6BAA6B,EAAE,CAAA;SAChC;IACH,CAAC;AACH,CAAC;AAED,SAAS,eAAe,CAAC,CAAQ;IAC/B,CAAC,CAAC,cAAc,EAAE,CAAA;IAClB,CAAC,CAAC,eAAe,EAAE,CAAA;AACrB,CAAC;AAED,SAAS,MAAM,CAAC,OAA2B,EAAE,SAAkB;IAC7D,IAAI,OAAO,YAAY,WAAW,EAAE;QAClC,OAAO,CAAC,KAAK,CAAC,OAAO,GAAG,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,CAAA;KACvD;AACH,CAAC"}
@@ -1,16 +1,14 @@
1
- import { Annotation, ImageAnnotation } from '../../types/Score';
1
+ import { Annotation, ImageAnnotation, TextAnnotation } from '../../types/Score';
2
2
  import React from 'react';
3
3
  export declare function textAnnotationFromRange(answerTextNode: Element, range: Range): {
4
4
  startIndex: number;
5
5
  length: number;
6
6
  };
7
+ export declare function getOverlappingMessages(currentAnnotations: Annotation[], start: number, length: number): string;
8
+ export declare function getOverlappingMessagesFromTextAnnotations(currentAnnotations: TextAnnotation[], start: number, length: number): string;
7
9
  export declare function toNodeLength(node: Node): number | undefined;
8
10
  export declare function allNodesUnder(el: Node, documentObject?: Document): Node[];
9
- export declare function showAndPositionPopup(boundingRect: DOMRect, container: HTMLDivElement): {
10
- display: string;
11
- top: string;
12
- left: string;
13
- };
11
+ export declare function showAndPositionElement(annotationRect: DOMRect, container: HTMLElement, popup: HTMLElement): void;
14
12
  export declare function hasTextSelectedInAnswerText(): boolean;
15
13
  export declare function selectionHasNothingToUnderline(range: Range): boolean;
16
14
  export declare function mergeAnnotation($answerText: Element, newAnnotation: Annotation, annotations: Annotation[]): Annotation[];
@@ -1 +1 @@
1
- {"version":3,"file":"editAnnotations.d.ts","sourceRoot":"","sources":["../../../src/components/grading/editAnnotations.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,eAAe,EAAkB,MAAM,mBAAmB,CAAA;AAC/E,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,wBAAgB,uBAAuB,CAAC,cAAc,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK;;;EAgB5E;AAED,wBAAgB,YAAY,CAAC,IAAI,EAAE,IAAI,sBAEtC;AAED,wBAAgB,aAAa,CAAC,EAAE,EAAE,IAAI,EAAE,cAAc,WAAW,GAAG,IAAI,EAAE,CAQzE;AAED,wBAAgB,oBAAoB,CAAC,YAAY,EAAE,OAAO,EAAE,SAAS,EAAE,cAAc;;;;EAepF;AAED,wBAAgB,2BAA2B,IAAI,OAAO,CAqCrD;AAED,wBAAgB,8BAA8B,CAAC,KAAK,EAAE,KAAK,WAM1D;AAED,wBAAgB,eAAe,CAAC,WAAW,EAAE,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,gBA0BzG;AAqBD,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,OAAO,EAAE,WAAW,EAAE,OA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E,WAAW,EAAE,KAAK,EAAE,WAAW,QAczG;AAED,wBAAgB,2BAA2B,IAAI,OAAO,CAqCrD;AAED,wBAAgB,8BAA8B,CAAC,KAAK,EAAE,KAAK,WAM1D;AAED,wBAAgB,eAAe,CAAC,WAAW,EAAE,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,gBA0BzG;AAqBD,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,OAAO,EAAE,WAAW,EAAE,OAAO,UAKvE;AAED,MAAM,MAAM,kBAAkB,GAAG;IAC/B,IAAI,EAAE,OAAO,CAAA;IACb,eAAe,EAAE,MAAM,CAAA;IACvB,MAAM,EAAE,MAAM,CAAA;IACd,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,EAAE,MAAM,CAAA;IACf,OAAO,EAAE,MAAM,CAAA;CAChB,CAAA;AACD,wBAAgB,2BAA2B,CACzC,CAAC,EAAE,UAAU,EACb,EAAE,IAAI,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,EAAE,EAAE,kBAAkB,GAC9E,eAAe,CA+BjB;AACD,wBAAgB,4BAA4B,CAC1C,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,cAAc,EAAE,UAAU,CAAC,EAC/C,KAAK,EAAE,gBAAgB,GACtB,kBAAkB,CAUpB"}
@@ -15,6 +15,14 @@ export function textAnnotationFromRange(answerTextNode, range) {
15
15
  return offsetInside + _.sum(nodesBeforeContainer.map(toNodeLength));
16
16
  }
17
17
  }
18
+ export function getOverlappingMessages(currentAnnotations, start, length) {
19
+ const textAnnotations = currentAnnotations.filter((a) => a.type === 'text');
20
+ return getOverlappingMessagesFromTextAnnotations(textAnnotations, start, length);
21
+ }
22
+ export function getOverlappingMessagesFromTextAnnotations(currentAnnotations, start, length) {
23
+ const parted = getOverlappingAnnotations(currentAnnotations, { startIndex: start, length, message: '' });
24
+ return _.compact(parted.overlapping.map((anno) => anno.message)).reduceRight((msg, str) => `${str} / ${msg}`, '');
25
+ }
18
26
  export function toNodeLength(node) {
19
27
  var _a;
20
28
  return node.nodeType === Node.TEXT_NODE ? (_a = node.textContent) === null || _a === void 0 ? void 0 : _a.length : node.nodeName === 'IMG' ? 1 : 0;
@@ -28,21 +36,18 @@ export function allNodesUnder(el, documentObject = document) {
28
36
  }
29
37
  return a;
30
38
  }
31
- export function showAndPositionPopup(boundingRect, container) {
39
+ export function showAndPositionElement(annotationRect, container, popup) {
40
+ const style = popup.style;
32
41
  if (container) {
42
+ style.display = 'block';
33
43
  const containerRect = container.getBoundingClientRect();
34
- return {
35
- display: 'block',
36
- top: String(boundingRect.bottom - containerRect.top + 10) + 'px',
37
- left: String(boundingRect.left - containerRect.left) + 'px',
38
- };
39
- }
40
- else {
41
- return {
42
- display: 'block',
43
- top: '0px',
44
- left: '0px',
45
- };
44
+ const popupRect = popup.getBoundingClientRect();
45
+ const left = annotationRect.left - containerRect.left;
46
+ const top = annotationRect.bottom - containerRect.top + 25;
47
+ style.top = String(top) + 'px';
48
+ style.left =
49
+ String(left + popupRect.width < containerRect.width ? left + 20 : containerRect.width - popupRect.width + 15) +
50
+ 'px';
46
51
  }
47
52
  }
48
53
  export function hasTextSelectedInAnswerText() {
@@ -1 +1 @@
1
- {"version":3,"file":"editAnnotations.js","sourceRoot":"","sources":["../../../src/components/grading/editAnnotations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,WAAW,CAAA;AAI9B,MAAM,UAAU,uBAAuB,CAAC,cAAuB,EAAE,KAAY;IAC3E,MAAM,WAAW,GAAG,aAAa,CAAC,cAAc,CAAC,CAAA;IACjD,MAAM,gBAAgB,GAAG,yBAAyB,CAAC,KAAK,CAAC,cAAc,EAAE,KAAK,CAAC,WAAW,CAAC,CAAA;IAC3F,MAAM,kBAAkB,GAAG,yBAAyB,CAAC,KAAK,CAAC,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,CAAA;IACzF,OAAO;QACL,UAAU,EA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