@qti-components/test 2.0.0-next.13 → 2.0.0-next.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (107) hide show
  1. package/dist/components/index.d.ts +0 -2
  2. package/dist/components/index.js +0 -2
  3. package/dist/components/index.js.map +1 -1
  4. package/dist/components/qti-assessment-item-ref/qti-assessment-item-ref.js +1 -1
  5. package/dist/components/qti-assessment-item-ref/qti-assessment-item-ref.js.map +1 -1
  6. package/dist/components/qti-assessment-test/qti-assessment-test.d.ts +1 -1
  7. package/dist/components/qti-assessment-test/qti-assessment-test.js +1 -1
  8. package/dist/components/qti-assessment-test/qti-assessment-test.js.map +1 -1
  9. package/dist/components/qti-number-presented/qti-number-presented.js +1 -1
  10. package/dist/components/qti-number-presented/qti-number-presented.js.map +1 -1
  11. package/dist/components/qti-number-selected/qti-number-selected.js +2 -2
  12. package/dist/components/qti-number-selected/qti-number-selected.js.map +1 -1
  13. package/dist/components/qti-test/qti-test.d.ts +2 -2
  14. package/dist/components/qti-test/qti-test.js +2 -2
  15. package/dist/components/qti-test/qti-test.js.map +1 -1
  16. package/dist/components/qti-test-variables/qti-test-variables.js +2 -2
  17. package/dist/components/qti-test-variables/qti-test-variables.js.map +1 -1
  18. package/dist/components/styles.js +64 -34
  19. package/dist/components/styles.js.map +1 -1
  20. package/dist/components/test-container/test-container.js +1 -1
  21. package/dist/components/test-container/test-container.js.map +1 -1
  22. package/dist/components/test-end-attempt/test-end-attempt.d.ts +1 -1
  23. package/dist/components/test-end-attempt/test-end-attempt.js +2 -2
  24. package/dist/components/test-end-attempt/test-end-attempt.js.map +1 -1
  25. package/dist/components/test-navigation/test-navigation.js +4 -4
  26. package/dist/components/test-navigation/test-navigation.js.map +1 -1
  27. package/dist/components/test-next/test-next.js +1 -1
  28. package/dist/components/test-next/test-next.js.map +1 -1
  29. package/dist/components/test-prev/test-prev.js +1 -1
  30. package/dist/components/test-prev/test-prev.js.map +1 -1
  31. package/dist/components/test-submit/test-submit.d.ts +1 -1
  32. package/dist/components/test-submit/test-submit.js +2 -2
  33. package/dist/components/test-submit/test-submit.js.map +1 -1
  34. package/dist/elements.d.ts +1 -63
  35. package/dist/elements.js +1 -5
  36. package/dist/elements.js.map +1 -1
  37. package/dist/mixins/test-base.js +3 -3
  38. package/dist/mixins/test-base.js.map +1 -1
  39. package/dist/mixins/test-navigation.mixin.js +13 -13
  40. package/dist/mixins/test-navigation.mixin.js.map +1 -1
  41. package/dist/mixins/test-processing.mixin.js +3 -3
  42. package/dist/mixins/test-processing.mixin.js.map +1 -1
  43. package/dist/mixins/test-state.mixin.d.ts +2 -7
  44. package/dist/mixins/test-state.mixin.js +6 -6
  45. package/dist/mixins/test-state.mixin.js.map +1 -1
  46. package/dist/mixins/test-view.mixin.js +2 -2
  47. package/dist/mixins/test-view.mixin.js.map +1 -1
  48. package/dist/plugin-api.d.ts +10 -0
  49. package/dist/plugin-api.js +9 -0
  50. package/dist/plugin-api.js.map +1 -0
  51. package/dist/plugin-state.d.ts +1 -1
  52. package/dist/plugin-state.js +1 -1
  53. package/dist/plugin-state.js.map +1 -1
  54. package/dist/plugins/elements.d.ts +5 -72
  55. package/dist/plugins/elements.js +6 -33
  56. package/dist/plugins/elements.js.map +1 -1
  57. package/dist/plugins/index.d.ts +1 -1
  58. package/dist/plugins/index.js +1 -1
  59. package/dist/plugins/index.js.map +1 -1
  60. package/dist/public-events.d.ts +22 -20
  61. package/dist/public-events.js +16 -20
  62. package/dist/public-events.js.map +1 -1
  63. package/dist/types/qti-test-state.d.ts +1 -1
  64. package/dist/types/qti-test-state.js.map +1 -1
  65. package/package.json +10 -6
  66. package/dist/components/test-bookmark/test-bookmark.d.ts +0 -48
  67. package/dist/components/test-bookmark/test-bookmark.js +0 -132
  68. package/dist/components/test-bookmark/test-bookmark.js.map +0 -1
  69. package/dist/components/test-check-item/test-check-item.d.ts +0 -20
  70. package/dist/components/test-check-item/test-check-item.js +0 -35
  71. package/dist/components/test-check-item/test-check-item.js.map +0 -1
  72. package/dist/components/test-item-link/test-item-link.d.ts +0 -13
  73. package/dist/components/test-item-link/test-item-link.js +0 -28
  74. package/dist/components/test-item-link/test-item-link.js.map +0 -1
  75. package/dist/components/test-print-context/test-print-context.d.ts +0 -11
  76. package/dist/components/test-print-context/test-print-context.js +0 -20
  77. package/dist/components/test-print-context/test-print-context.js.map +0 -1
  78. package/dist/components/test-print-item-variables/test-print-item-variables.d.ts +0 -17
  79. package/dist/components/test-print-item-variables/test-print-item-variables.js +0 -95
  80. package/dist/components/test-print-item-variables/test-print-item-variables.js.map +0 -1
  81. package/dist/components/test-print-state/test-print-state.d.ts +0 -27
  82. package/dist/components/test-print-state/test-print-state.js +0 -87
  83. package/dist/components/test-print-state/test-print-state.js.map +0 -1
  84. package/dist/components/test-scoring-buttons/test-scoring-buttons.d.ts +0 -19
  85. package/dist/components/test-scoring-buttons/test-scoring-buttons.js +0 -95
  86. package/dist/components/test-scoring-buttons/test-scoring-buttons.js.map +0 -1
  87. package/dist/components/test-scoring-feedback/test-scoring-feedback.d.ts +0 -13
  88. package/dist/components/test-scoring-feedback/test-scoring-feedback.js +0 -54
  89. package/dist/components/test-scoring-feedback/test-scoring-feedback.js.map +0 -1
  90. package/dist/components/test-section-link/test-section-link.d.ts +0 -13
  91. package/dist/components/test-section-link/test-section-link.js +0 -28
  92. package/dist/components/test-section-link/test-section-link.js.map +0 -1
  93. package/dist/components/test-stamp/test-stamp.d.ts +0 -29
  94. package/dist/components/test-stamp/test-stamp.js +0 -105
  95. package/dist/components/test-stamp/test-stamp.js.map +0 -1
  96. package/dist/components/test-view-toggle/test-view-toggle.d.ts +0 -16
  97. package/dist/components/test-view-toggle/test-view-toggle.js +0 -49
  98. package/dist/components/test-view-toggle/test-view-toggle.js.map +0 -1
  99. package/dist/components/test-view-toggle/test-view.d.ts +0 -20
  100. package/dist/components/test-view-toggle/test-view.js +0 -73
  101. package/dist/components/test-view-toggle/test-view.js.map +0 -1
  102. package/dist/tts/elements.d.ts +0 -28
  103. package/dist/tts/elements.js +0 -14
  104. package/dist/tts/elements.js.map +0 -1
  105. package/dist/tts/test-item-to-speech.d.ts +0 -252
  106. package/dist/tts/test-item-to-speech.js +0 -1053
  107. package/dist/tts/test-item-to-speech.js.map +0 -1
@@ -1,95 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- import { html, LitElement, nothing } from 'lit';
8
- import { consume } from '@lit/context';
9
- import { property } from 'lit/decorators.js';
10
- import { prepareTemplate } from '@heximal/templates';
11
- import { computedContext } from '@qti-components/base';
12
- import { dispatchPublic } from '../../public-events';
13
- export class TestScoringButtons extends LitElement {
14
- createRenderRoot() {
15
- return this;
16
- }
17
- connectedCallback() {
18
- super.connectedCallback();
19
- const templateElement = this.querySelector('template');
20
- if (!templateElement) {
21
- this.myTemplate = null;
22
- return;
23
- }
24
- this.myTemplate = prepareTemplate(templateElement);
25
- }
26
- #changeOutcomeScore(value) {
27
- const testPart = this.computedContext?.testParts.find(testPart => testPart.active);
28
- const sectionItems = testPart.sections.flatMap(section => section.items);
29
- const currentItemIdentifier = sectionItems.find(item => item.active)?.identifier;
30
- dispatchPublic(this, 'cito-test-update-outcome', {
31
- assessmentItemRefId: currentItemIdentifier,
32
- outcomeVariableId: 'SCORE',
33
- value
34
- });
35
- }
36
- render() {
37
- const activeItem = this.computedContext?.testParts
38
- .flatMap(testPart => testPart.sections.flatMap(section => section.items))
39
- .find(item => item.active);
40
- if (!activeItem || !activeItem.variables)
41
- return html ``;
42
- const maxScore = activeItem.variables.find(vr => vr.identifier == 'MAXSCORE')?.value;
43
- const scoreOutcome = activeItem.variables.find(vr => vr.identifier == 'SCORE');
44
- const score = scoreOutcome?.value;
45
- const disabled = !(scoreOutcome?.externalScored === 'human');
46
- if (!maxScore || !scoreOutcome)
47
- return nothing;
48
- const scores = [...Array(Number(maxScore) + 1).keys()];
49
- return html `${this.myTemplate ? this.myTemplate({ scores, score, disabled }) : nothing}`;
50
- }
51
- constructor() {
52
- super();
53
- this.view = ''; // is only an attribute, but this is here because.. react
54
- this.disabled = false;
55
- this.myTemplate = null;
56
- this.addEventListener('click', e => {
57
- const target = e.target;
58
- const value = parseFloat(target.value);
59
- if (target.tagName === 'INPUT') {
60
- this.#changeOutcomeScore(value);
61
- }
62
- });
63
- // return maxScore
64
- // ? html`
65
- // <form part="form">
66
- // ${[...Array(Number(maxScore) + 1).keys()].map(itemIndex => {
67
- // const identifier = `scoring-buttons${itemIndex}${activeItem.identifier}`;
68
- // return html` <input
69
- // part="input"
70
- // type="radio"
71
- // ?disabled=${this.disabled}
72
- // .checked=${itemIndex === Number(score)}
73
- // @change=${() => this._changeOutcomeScore(itemIndex)}
74
- // id=${identifier}
75
- // name=${`scoring-buttons-${activeItem.identifier}`}
76
- // value=${itemIndex}
77
- // />
78
- // <label part="label" for=${identifier}>${itemIndex}</label>`;
79
- // })}
80
- // </form>
81
- // <slot></slot>
82
- // `
83
- // : nothing;
84
- }
85
- }
86
- __decorate([
87
- property({ type: String, attribute: 'view' })
88
- ], TestScoringButtons.prototype, "view", void 0);
89
- __decorate([
90
- property({ type: Boolean })
91
- ], TestScoringButtons.prototype, "disabled", void 0);
92
- __decorate([
93
- consume({ context: computedContext, subscribe: true })
94
- ], TestScoringButtons.prototype, "computedContext", void 0);
95
- //# sourceMappingURL=test-scoring-buttons.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"test-scoring-buttons.js","sourceRoot":"","sources":["../../../src/components/test-scoring-buttons/test-scoring-buttons.ts"],"names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AAC,CAAC,yDAAyD;QACtF,aAAQ,GAAY,KAAK,CAAC;QACvD,eAAU,GAA4B,IAAI,CAAC;QAqDzC,IAAI,CAAC,gBAAgB,CAAC,OAAO,EAAE,CAAC,CAAC,EAAE;YACjC,MAAM,MAAM,GAAG,CAAC,CAAC,MAA0B,CAAC;YAC5C,MAAM,KAAK,GAAG,UAAU,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YACvC,IAAI,MAAM,CAAC,OAAO,KAAK,OAAO,EAAE,CAAC;gBAC/B,IAAI,CAAC,mBAAmB,CAAC,KAAK,CAAC,CAAC;YAClC,CAAC;QACH,CAAC,CAAC,CAAC;QAEH,kBAAkB;QAClB,YAAY;QACZ,2BAA2B;QAC3B,uEAAuE;QACvE,sFAAsF;QACtF,gCAAgC;QAChC,6BAA6B;QAC7B,6BAA6B;QAC7B,2CAA2C;QAC3C,wDAAwD;QACxD,qEAAqE;QACrE,iCAAiC;QACjC,mEAAmE;QACnE,mCAAmC;QACnC,iBAAiB;QAEjB,2EAA2E;QAC3E,cAAc;QACd,gBAAgB;QAChB,sBAAsB;QACtB,QAAQ;QACR,eAAe;IACjB,CAAC;CACF;AAtFgD;IAA9C,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,CAAC;gDAAW;AAC5B;IAA5B,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;oDAA2B;AAkB7C;IADT,OAAO,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;2DACX","sourcesContent":["import { html, LitElement, nothing } from 'lit';\nimport { consume } from '@lit/context';\nimport { property } from 'lit/decorators.js';\nimport { prepareTemplate } from '@heximal/templates';\n\nimport { computedContext } from '@qti-components/base';\n\nimport { dispatchPublic } from '../../public-events';\n\nimport type { TemplateFunction } from '@heximal/templates';\nimport type { OutcomeVariable } from '@qti-components/base';\nimport type { ComputedContext } from '@qti-components/base';\n\nexport class TestScoringButtons extends LitElement {\n @property({ type: String, attribute: 'view' }) view = ''; // is only an attribute, but this is here because.. react\n @property({ type: Boolean }) disabled: boolean = false;\n myTemplate: TemplateFunction | null = null;\n\n protected override createRenderRoot(): HTMLElement | DocumentFragment {\n return this;\n }\n\n override connectedCallback(): void {\n super.connectedCallback();\n const templateElement = this.querySelector<HTMLTemplateElement>('template');\n if (!templateElement) {\n this.myTemplate = null;\n return;\n }\n this.myTemplate = prepareTemplate(templateElement);\n }\n\n @consume({ context: computedContext, subscribe: true })\n protected computedContext?: ComputedContext;\n\n #changeOutcomeScore(value: number) {\n const testPart = this.computedContext?.testParts.find(testPart => testPart.active);\n const sectionItems = testPart.sections.flatMap(section => section.items);\n const currentItemIdentifier = sectionItems.find(item => item.active)?.identifier;\n\n dispatchPublic(this, 'cito-test-update-outcome', {\n assessmentItemRefId: currentItemIdentifier,\n outcomeVariableId: 'SCORE',\n value\n });\n }\n\n override render() {\n const activeItem = this.computedContext?.testParts\n .flatMap(testPart => testPart.sections.flatMap(section => section.items))\n .find(item => item.active);\n\n if (!activeItem || !activeItem.variables) return html``;\n\n const maxScore = activeItem.variables.find(vr => vr.identifier == 'MAXSCORE')?.value;\n const scoreOutcome = activeItem.variables.find(vr => vr.identifier == 'SCORE') as OutcomeVariable;\n\n const score = scoreOutcome?.value;\n\n const disabled = !(scoreOutcome?.externalScored === 'human');\n\n if (!maxScore || !scoreOutcome) return nothing;\n const scores = [...Array(Number(maxScore) + 1).keys()];\n\n return html`${this.myTemplate ? this.myTemplate({ scores, score, disabled }) : nothing}`;\n }\n\n constructor() {\n super();\n this.addEventListener('click', e => {\n const target = e.target as HTMLInputElement;\n const value = parseFloat(target.value);\n if (target.tagName === 'INPUT') {\n this.#changeOutcomeScore(value);\n }\n });\n\n // return maxScore\n // ? html`\n // <form part=\"form\">\n // ${[...Array(Number(maxScore) + 1).keys()].map(itemIndex => {\n // const identifier = `scoring-buttons${itemIndex}${activeItem.identifier}`;\n // return html` <input\n // part=\"input\"\n // type=\"radio\"\n // ?disabled=${this.disabled}\n // .checked=${itemIndex === Number(score)}\n // @change=${() => this._changeOutcomeScore(itemIndex)}\n // id=${identifier}\n // name=${`scoring-buttons-${activeItem.identifier}`}\n // value=${itemIndex}\n // />\n\n // <label part=\"label\" for=${identifier}>${itemIndex}</label>`;\n // })}\n // </form>\n // <slot></slot>\n // `\n // : nothing;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-scoring-buttons': TestScoringButtons;\n }\n}\n"]}
@@ -1,13 +0,0 @@
1
- import { LitElement } from 'lit';
2
- import type { View } from '@qti-components/base';
3
- import type { ComputedContext } from '@qti-components/base';
4
- export declare class TestScoringFeedback extends LitElement {
5
- protected computedContext?: ComputedContext;
6
- view: View;
7
- render(): import("lit").TemplateResult<1>;
8
- }
9
- declare global {
10
- interface HTMLElementTagNameMap {
11
- 'test-scoring-feedback': TestScoringFeedback;
12
- }
13
- }
@@ -1,54 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- import { consume } from '@lit/context';
8
- import { html, LitElement } from 'lit';
9
- import { property } from 'lit/decorators.js';
10
- import { computedContext } from '@qti-components/base';
11
- export class TestScoringFeedback extends LitElement {
12
- constructor() {
13
- super(...arguments);
14
- this.view = null;
15
- }
16
- render() {
17
- const activeItem = this.computedContext?.testParts
18
- .flatMap(testPart => testPart.sections.flatMap(section => section.items))
19
- .find(item => item.active);
20
- if (!activeItem || !activeItem.variables)
21
- return html ``;
22
- if (activeItem['category'] === 'dep-informational')
23
- return html `<div>${this.dataset.informational}</div>`;
24
- const scoreOutcome = activeItem?.variables.find(vr => vr.identifier == 'SCORE');
25
- const score = parseFloat(scoreOutcome?.value);
26
- const externalScored = activeItem['externalScored'];
27
- const feedbackText = () => {
28
- // No (valid) answer: completionStatus is QTI's, set by response processing, not "answered".
29
- if (activeItem.valid === false || activeItem.isDefaultResponse) {
30
- return this.dataset.textNoResponse;
31
- }
32
- if (!externalScored && score !== undefined && !Number.isNaN(score)) {
33
- return score > 0 ? this.dataset.textCorrect : this.dataset.textIncorrect;
34
- }
35
- if (externalScored === 'externalMachine') {
36
- return Number.isNaN(score) || score === undefined
37
- ? this.dataset.scoreUnknown
38
- : `We hebben je antwoord ${score === 0 ? 'geen punten' : score == 1 ? 'één punt' : `${score} punten`} gegeven. Je kunt je score zelf aanpassen als je denkt dat dat niet klopt.`;
39
- }
40
- if (externalScored === 'human') {
41
- return Number.isNaN(score) ? '' : 'Deze score heb je zelf toegekend.';
42
- }
43
- return this.dataset.inProgress;
44
- };
45
- return html `<div>${feedbackText()}</div>`;
46
- }
47
- }
48
- __decorate([
49
- consume({ context: computedContext, subscribe: true })
50
- ], TestScoringFeedback.prototype, "computedContext", void 0);
51
- __decorate([
52
- property({ type: String, attribute: 'view' })
53
- ], TestScoringFeedback.prototype, "view", void 0);
54
- //# sourceMappingURL=test-scoring-feedback.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"test-scoring-feedback.js","sourceRoot":"","sources":["../../../src/components/test-scoring-feedback/test-scoring-feedback.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAE7C,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAMvD,MAAM,OAAO,mBAAoB,SAAQ,UAAU;IAAnD;;QA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,CAAC;YAED,IAAI,cAAc,KAAK,iBAAiB,EAAE,CAAC;gBACzC,OAAO,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,KAAK,KAAK,SAAS;oBAC/C,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,YAAY;oBAC3B,CAAC,CAAC,yBAAyB,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,GAAG,KAAK,SAAS,4EAA4E,CAAC;YACrL,CAAC;YAED,IAAI,cAAc,KAAK,OAAO,EAAE,CAAC;gBAC/B,OAAO,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,mCAAmC,CAAC;YACxE,CAAC;YAED,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC;QACjC,CAAC,CAAC;QAEF,OAAO,IAAI,CAAA,QAAQ,YAAY,EAAE,QAAQ,CAAC;IAC5C,CAAC;CACF;AA5CW;IADT,OAAO,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;4DACX;AAGrC;IADN,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,CAAC;iDACrB","sourcesContent":["import { consume } from '@lit/context';\nimport { html, LitElement } from 'lit';\nimport { property } from 'lit/decorators.js';\n\nimport { computedContext } from '@qti-components/base';\n\nimport type { View } from '@qti-components/base';\nimport type { OutcomeVariable } from '@qti-components/base';\nimport type { ComputedContext } from '@qti-components/base';\n\nexport class TestScoringFeedback extends LitElement {\n @consume({ context: computedContext, subscribe: true })\n protected computedContext?: ComputedContext;\n\n @property({ type: String, attribute: 'view' })\n public view: View = null;\n\n override render() {\n const activeItem = this.computedContext?.testParts\n .flatMap(testPart => testPart.sections.flatMap(section => section.items))\n .find(item => item.active);\n\n if (!activeItem || !activeItem.variables) return html``;\n\n if ((activeItem as any)['category'] === 'dep-informational') return html`<div>${this.dataset.informational}</div>`;\n\n const scoreOutcome = activeItem?.variables.find(vr => vr.identifier == 'SCORE') as OutcomeVariable;\n\n const score = parseFloat(scoreOutcome?.value as string);\n const externalScored = (activeItem as any)['externalScored'];\n\n const feedbackText = () => {\n // No (valid) answer: completionStatus is QTI's, set by response processing, not \"answered\".\n if (activeItem.valid === false || activeItem.isDefaultResponse) {\n return this.dataset.textNoResponse;\n }\n\n if (!externalScored && score !== undefined && !Number.isNaN(score)) {\n return score > 0 ? this.dataset.textCorrect : this.dataset.textIncorrect;\n }\n\n if (externalScored === 'externalMachine') {\n return Number.isNaN(score) || score === undefined\n ? this.dataset.scoreUnknown\n : `We hebben je antwoord ${score === 0 ? 'geen punten' : score == 1 ? 'één punt' : `${score} punten`} gegeven. Je kunt je score zelf aanpassen als je denkt dat dat niet klopt.`;\n }\n\n if (externalScored === 'human') {\n return Number.isNaN(score) ? '' : 'Deze score heb je zelf toegekend.';\n }\n\n return this.dataset.inProgress;\n };\n\n return html`<div>${feedbackText()}</div>`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-scoring-feedback': TestScoringFeedback;\n }\n}\n"]}
@@ -1,13 +0,0 @@
1
- import { LitElement } from 'lit';
2
- export declare class TestSectionLink extends LitElement {
3
- #private;
4
- static styles: import("lit").CSSResult;
5
- private sectionId;
6
- constructor();
7
- render(): import("lit").TemplateResult<1>;
8
- }
9
- declare global {
10
- interface HTMLElementTagNameMap {
11
- 'test-section-link': TestSectionLink;
12
- }
13
- }
@@ -1,28 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- import { LitElement } from 'lit';
8
- import { property } from 'lit/decorators.js';
9
- import * as styles from '../styles';
10
- import { dispatchPublic } from '../../public-events';
11
- export class TestSectionLink extends LitElement {
12
- static { this.styles = styles.button; }
13
- #requestItem(identifier) {
14
- dispatchPublic(this, 'cito-test-navigate', { type: 'section', id: identifier });
15
- }
16
- constructor() {
17
- super();
18
- this.sectionId = null;
19
- this.addEventListener('click', () => this.#requestItem(this.sectionId));
20
- }
21
- render() {
22
- return styles.control;
23
- }
24
- }
25
- __decorate([
26
- property({ type: String, attribute: 'section-id' })
27
- ], TestSectionLink.prototype, "sectionId", void 0);
28
- //# sourceMappingURL=test-section-link.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"test-section-link.js","sourceRoot":"","sources":["../../../src/components/test-section-link/test-section-link.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AACjC,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAE7C,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAErD,MAAM,OAAO,eAAgB,SAAQ,UAAU;aAC7B,WAAM,GAAG,MAAM,CAAC,MAAM,AAAhB,CAAiB;IAKvC,YAAY,CAAC,UAAkB;QAC7B,cAAc,CAAC,IAAI,EAAE,oBAAoB,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,EAAE,EAAE,UAAU,EAAE,CAAC,CAAC;IAClF,CAAC;IAED;QACE,KAAK,EAAE,CAAC;QAPF,cAAS,GAAW,IAAI,CAAC;QAQ/B,IAAI,CAAC,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC;IAC1E,CAAC;IAEQ,MAAM;QACb,OAAO,MAAM,CAAC,OAAO,CAAC;IACxB,CAAC;;AAbO;IADP,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,YAAY,EAAE,CAAC;kDACnB","sourcesContent":["import { LitElement } from 'lit';\nimport { property } from 'lit/decorators.js';\n\nimport * as styles from '../styles';\nimport { dispatchPublic } from '../../public-events';\n\nexport class TestSectionLink extends LitElement {\n static override styles = styles.button;\n\n @property({ type: String, attribute: 'section-id' })\n private sectionId: string = null;\n\n #requestItem(identifier: string) {\n dispatchPublic(this, 'cito-test-navigate', { type: 'section', id: identifier });\n }\n\n constructor() {\n super();\n this.addEventListener('click', () => this.#requestItem(this.sectionId));\n }\n\n override render() {\n return styles.control;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-section-link': TestSectionLink;\n }\n}\n"]}
@@ -1,29 +0,0 @@
1
- import { LitElement } from 'lit';
2
- import type { PropertyValues } from 'lit';
3
- import type { TemplateFunction } from '@heximal/templates';
4
- /**
5
- * The stamp plugin: renders its `<template>` child with the state of the test (`test`,
6
- * `activeTestpart`, `activeSection`, `activeItem`, `view`), again on every change, so a player
7
- * can show progress or numbered navigation without writing a component.
8
- * @customElement
9
- * @extends {LitElement}
10
- */
11
- export declare class TestStamp extends LitElement {
12
- /**
13
- * Indicates whether the component is in debug mode.
14
- * When set to `true`, the available objects and properties (i.e.: stampContext) is displayed.
15
- */
16
- debug: boolean;
17
- private computedContext;
18
- private stampContext;
19
- myTemplate: TemplateFunction;
20
- protected createRenderRoot(): HTMLElement | DocumentFragment;
21
- connectedCallback(): void;
22
- protected willUpdate(_changedProperties: PropertyValues): void;
23
- render(): import("lit").TemplateResult<1>;
24
- }
25
- declare global {
26
- interface HTMLElementTagNameMap {
27
- 'test-stamp': TestStamp;
28
- }
29
- }
@@ -1,105 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- import { html, LitElement, nothing } from 'lit';
8
- import { property, state } from 'lit/decorators.js';
9
- import { prepareTemplate } from '@heximal/templates';
10
- import { consume } from '@lit/context';
11
- import { computedContext } from '@qti-components/base';
12
- /**
13
- * The stamp plugin: renders its `<template>` child with the state of the test (`test`,
14
- * `activeTestpart`, `activeSection`, `activeItem`, `view`), again on every change, so a player
15
- * can show progress or numbered navigation without writing a component.
16
- * @customElement
17
- * @extends {LitElement}
18
- */
19
- export class TestStamp extends LitElement {
20
- constructor() {
21
- super(...arguments);
22
- /**
23
- * Indicates whether the component is in debug mode.
24
- * When set to `true`, the available objects and properties (i.e.: stampContext) is displayed.
25
- */
26
- this.debug = false;
27
- this.stampContext = {
28
- view: 'candidate',
29
- activeItem: {},
30
- activeSection: {
31
- items: []
32
- },
33
- activeTestpart: {
34
- items: [],
35
- sections: []
36
- },
37
- test: {}
38
- };
39
- }
40
- createRenderRoot() {
41
- return this;
42
- }
43
- connectedCallback() {
44
- super.connectedCallback();
45
- const templateElement = this.querySelector('template');
46
- if (!templateElement) {
47
- this.myTemplate = null;
48
- return;
49
- }
50
- this.myTemplate = prepareTemplate(templateElement);
51
- }
52
- willUpdate(_changedProperties) {
53
- if (!this.computedContext) {
54
- return;
55
- }
56
- const activeTestPart = this.computedContext.testParts.find(testPart => testPart.active);
57
- const activeSection = activeTestPart?.sections.find(section => section.active);
58
- const activeItem = activeSection?.items.find(item => item.active);
59
- // In `navigate="section"` the test shows a section, not one item, so there may be no active item.
60
- const { variables, ...augmentedItem } = activeItem || {};
61
- if (!activeTestPart) {
62
- return;
63
- }
64
- const augmentedTestPart = {
65
- ...activeTestPart,
66
- items: activeTestPart.sections.flatMap(section => section.items.map(({ variables, ...rest }) => rest)),
67
- sections: activeTestPart.sections.map(section => ({
68
- ...section,
69
- items: section.items.map(({ variables, ...rest }) => rest)
70
- }))
71
- };
72
- const augmentedSection = {
73
- ...activeSection,
74
- items: (activeSection?.items ?? []).map(({ variables, ...rest }) => rest)
75
- };
76
- const { testParts, ...activeTest } = this.computedContext;
77
- this.stampContext = {
78
- view: this.computedContext.view,
79
- activeItem: augmentedItem,
80
- activeSection: augmentedSection,
81
- activeTestpart: augmentedTestPart,
82
- test: activeTest
83
- };
84
- this.dispatchEvent(new CustomEvent('qti-stamp-context-updated', {
85
- detail: this.stampContext,
86
- bubbles: true
87
- }));
88
- }
89
- render() {
90
- // if (!this.stampContext) return nothing;
91
- return html ` ${this.debug ? html `<small><pre>${JSON.stringify(this.stampContext, null, 2)}</pre></small>` : nothing}
92
- ${this.myTemplate ? this.myTemplate(this.stampContext) : nothing}`;
93
- }
94
- }
95
- __decorate([
96
- property({ type: Boolean, reflect: true })
97
- ], TestStamp.prototype, "debug", void 0);
98
- __decorate([
99
- state(),
100
- consume({ context: computedContext, subscribe: true })
101
- ], TestStamp.prototype, "computedContext", void 0);
102
- __decorate([
103
- state()
104
- ], TestStamp.prototype, "stampContext", void 0);
105
- //# sourceMappingURL=test-stamp.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"test-stamp.js","sourceRoot":"","sources":["../../../src/components/test-stamp/test-stamp.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,KAAK,CAAC;AAChD,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,OAAO,EAAE,eAAe,E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AEQ,MAAM;QACb,0CAA0C;QAC1C,OAAO,IAAI,CAAA,IAAI,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAA,eAAe,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,YAAY,EAAE,IAAI,EAAE,CAAC,CAAC,gBAAgB,CAAC,CAAC,CAAC,OAAO;MACjH,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;IACrE,CAAC;CACF;AA3FQ;IADN,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;wCACtB;AAIb;IAFP,KAAK,EAAE;IACP,OAAO,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;kDACd;AAGjC;IADP,KAAK,EAAE;+CAkBN","sourcesContent":["import { html, LitElement, nothing } from 'lit';\nimport { property, state } from 'lit/decorators.js';\nimport { prepareTemplate } from '@heximal/templates';\nimport { consume } from '@lit/context';\n\nimport { computedContext } from '@qti-components/base';\n\nimport type { View } from '@qti-components/base';\nimport type { PropertyValues } from 'lit';\nimport type { ComputedContext } from '@qti-components/base';\nimport type { TemplateFunction } from '@heximal/templates';\n\n/**\n * The stamp plugin: renders its `<template>` child with the state of the test (`test`,\n * `activeTestpart`, `activeSection`, `activeItem`, `view`), again on every change, so a player\n * can show progress or numbered navigation without writing a component.\n * @customElement\n * @extends {LitElement}\n */\n\nexport class TestStamp extends LitElement {\n /**\n * Indicates whether the component is in debug mode.\n * When set to `true`, the available objects and properties (i.e.: stampContext) is displayed.\n */\n @property({ type: Boolean, reflect: true })\n public debug = false;\n\n @state()\n @consume({ context: computedContext, subscribe: true })\n private computedContext: ComputedContext;\n\n @state()\n private stampContext: {\n view?: View;\n test?: unknown;\n activeTestpart?: unknown;\n activeSection?: unknown;\n activeItem?: unknown;\n } = {\n view: 'candidate',\n activeItem: {},\n activeSection: {\n items: []\n },\n activeTestpart: {\n items: [],\n sections: []\n },\n test: {}\n };\n\n myTemplate: TemplateFunction;\n\n protected override createRenderRoot(): HTMLElement | DocumentFragment {\n return this;\n }\n\n override connectedCallback(): void {\n super.connectedCallback();\n const templateElement = this.querySelector<HTMLTemplateElement>('template');\n if (!templateElement) {\n this.myTemplate = null;\n return;\n }\n this.myTemplate = prepareTemplate(templateElement);\n }\n\n protected override willUpdate(_changedProperties: PropertyValues): void {\n if (!this.computedContext) {\n return;\n }\n const activeTestPart = this.computedContext.testParts.find(testPart => testPart.active);\n const activeSection = activeTestPart?.sections.find(section => section.active);\n const activeItem = activeSection?.items.find(item => item.active);\n // In `navigate=\"section\"` the test shows a section, not one item, so there may be no active item.\n const { variables, ...augmentedItem } = activeItem || {};\n\n if (!activeTestPart) {\n return;\n }\n\n const augmentedTestPart = {\n ...activeTestPart,\n items: activeTestPart.sections.flatMap(section => section.items.map(({ variables, ...rest }) => rest)),\n sections: activeTestPart.sections.map(section => ({\n ...section,\n items: section.items.map(({ variables, ...rest }) => rest)\n }))\n };\n\n const augmentedSection = {\n ...activeSection,\n items: (activeSection?.items ?? []).map(({ variables, ...rest }) => rest)\n };\n const { testParts, ...activeTest } = this.computedContext;\n\n this.stampContext = {\n view: this.computedContext.view,\n activeItem: augmentedItem,\n activeSection: augmentedSection,\n activeTestpart: augmentedTestPart,\n test: activeTest\n };\n this.dispatchEvent(\n new CustomEvent('qti-stamp-context-updated', {\n detail: this.stampContext,\n bubbles: true\n })\n );\n }\n\n override render() {\n // if (!this.stampContext) return nothing;\n return html` ${this.debug ? html`<small><pre>${JSON.stringify(this.stampContext, null, 2)}</pre></small>` : nothing}\n ${this.myTemplate ? this.myTemplate(this.stampContext) : nothing}`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-stamp': TestStamp;\n }\n}\n"]}
@@ -1,16 +0,0 @@
1
- import { LitElement } from 'lit';
2
- import type { PropertyValues } from 'lit';
3
- export declare class TestViewToggle extends LitElement {
4
- myTemplate: any;
5
- protected createRenderRoot(): HTMLElement | DocumentFragment;
6
- private sessionContext;
7
- connectedCallback(): void;
8
- _switchView(view: string): void;
9
- protected firstUpdated(_changedProperties: PropertyValues): void;
10
- render(): import("lit").TemplateResult<1>;
11
- }
12
- declare global {
13
- interface HTMLElementTagNameMap {
14
- 'test-view-toggle': TestViewToggle;
15
- }
16
- }
@@ -1,49 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- import { consume } from '@lit/context';
8
- import { html, LitElement, nothing } from 'lit';
9
- import { prepareTemplate } from '@heximal/templates';
10
- import { sessionContext } from '@qti-components/base';
11
- import { dispatchPublic } from '../../public-events';
12
- export class TestViewToggle extends LitElement {
13
- createRenderRoot() {
14
- return this;
15
- }
16
- connectedCallback() {
17
- super.connectedCallback();
18
- const templateElement = this.querySelector('template');
19
- if (!templateElement) {
20
- this.myTemplate = null;
21
- return;
22
- }
23
- this.myTemplate = prepareTemplate(templateElement);
24
- }
25
- _switchView(view) {
26
- dispatchPublic(this, 'cito-test-switch-view', view);
27
- }
28
- firstUpdated(_changedProperties) {
29
- this.addEventListener('click', () => {
30
- if (this.sessionContext?.view === 'scorer') {
31
- this._switchView('candidate');
32
- }
33
- else {
34
- this._switchView('scorer');
35
- }
36
- });
37
- }
38
- render() {
39
- return html `${this.myTemplate
40
- ? this.myTemplate({
41
- view: this.sessionContext?.view
42
- })
43
- : nothing}`;
44
- }
45
- }
46
- __decorate([
47
- consume({ context: sessionContext, subscribe: true })
48
- ], TestViewToggle.prototype, "sessionContext", void 0);
49
- //# sourceMappingURL=test-view-toggle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"test-view-toggle.js","sourceRoot":"","sources":["../../../src/components/test-view-toggle/test-view-toggle.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,KAAK,CAAC;AAChD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAEtD,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAMrD,MAAM,OAAO,cAAe,SAAQ,UAAU;IAGzB,gBAAgB;QACjC,OAAO,IAAI,CAAC;IACd,CAAC;IAKQ,iBAAiB;QACxB,KAAK,CAAC,iBAAiB,EAAE,CAAC;QAC1B,MAAM,eAAe,GAAG,IAAI,CAAC,aAAa,CAAsB,UAAU,CAAC,CAAC;QAC5E,IAAI,CAAC,eAAe,EAAE,CAAC;YACrB,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;YACvB,OAAO;QACT,CAAC;QACD,IAAI,CAAC,UAAU,GAAG,eAAe,CAAC,eAAe,CAAC,CAAC;IACrD,CAAC;IAED,WAAW,CAAC,IAAY;QACtB,cAAc,CAAC,IAAI,EAAE,uBAAuB,EAAE,IAAY,CAAC,CAAC;IAC9D,CAAC;IAEkB,YAAY,CAAC,kBAAkC;QAChE,IAAI,CAAC,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE;YAClC,IAAI,IAAI,CAAC,cAAc,EAAE,IAAI,KAAK,QAAQ,EAAE,CAAC;gBAC3C,IAAI,CAAC,WAAW,CAAC,WAAW,CAAC,CAAC;YAChC,CAAC;iBAAM,CAAC;gBACN,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC;YAC7B,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IAEQ,MAAM;QACb,OAAO,IAAI,CAAA,GAAG,IAAI,CAAC,UAAU;YAC3B,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC;gBACd,IAAI,EAAE,IAAI,CAAC,cAAc,EAAE,IAAI;aAChC,CAAC;YACJ,CAAC,CAAC,OAAO,EAAE,CAAC;IAChB,CAAC;CACF;AAjCS;IADP,OAAO,CAAC,EAAE,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;sDACf","sourcesContent":["import { consume } from '@lit/context';\nimport { html, LitElement, nothing } from 'lit';\nimport { prepareTemplate } from '@heximal/templates';\n\nimport { sessionContext } from '@qti-components/base';\n\nimport { dispatchPublic } from '../../public-events';\n\nimport type { PropertyValues } from 'lit';\nimport type { SessionContext } from '@qti-components/base';\nimport type { View } from '@qti-components/base';\n\nexport class TestViewToggle extends LitElement {\n myTemplate: any;\n\n protected override createRenderRoot(): HTMLElement | DocumentFragment {\n return this;\n }\n\n @consume({ context: sessionContext, subscribe: true })\n private sessionContext: SessionContext;\n\n override connectedCallback(): void {\n super.connectedCallback();\n const templateElement = this.querySelector<HTMLTemplateElement>('template');\n if (!templateElement) {\n this.myTemplate = null;\n return;\n }\n this.myTemplate = prepareTemplate(templateElement);\n }\n\n _switchView(view: string) {\n dispatchPublic(this, 'cito-test-switch-view', view as View);\n }\n\n protected override firstUpdated(_changedProperties: PropertyValues): void {\n this.addEventListener('click', () => {\n if (this.sessionContext?.view === 'scorer') {\n this._switchView('candidate');\n } else {\n this._switchView('scorer');\n }\n });\n }\n\n override render() {\n return html`${this.myTemplate\n ? this.myTemplate({\n view: this.sessionContext?.view\n })\n : nothing}`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-view-toggle': TestViewToggle;\n }\n}\n"]}
@@ -1,20 +0,0 @@
1
- import { LitElement } from 'lit';
2
- export declare class TestView extends LitElement {
3
- #private;
4
- static DEFAULT_VIEW_OPTIONS: string[];
5
- private sessionContext;
6
- /** label accompanying the select view dropdown */
7
- label: string;
8
- /** The options to display in the dropdown, default: ['author', 'candidate', 'proctor', 'scorer', 'testConstructor', 'tutor'] */
9
- viewOptions: string;
10
- protected _handleViewOptionsChange: () => void;
11
- connectedCallback(): void;
12
- private _viewOptions;
13
- protected _switchView(view: string): void;
14
- render(): import("lit").TemplateResult<1>;
15
- }
16
- declare global {
17
- interface HTMLElementTagNameMap {
18
- 'test-view': TestView;
19
- }
20
- }
@@ -1,73 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- var _a;
8
- import { html, LitElement } from 'lit';
9
- import { property, state } from 'lit/decorators.js';
10
- import { consume } from '@lit/context';
11
- import { watch } from '@qti-components/utilities';
12
- import { sessionContext } from '@qti-components/base';
13
- import { dispatchPublic } from '../../public-events';
14
- export class TestView extends LitElement {
15
- constructor() {
16
- super(...arguments);
17
- /** label accompanying the select view dropdown */
18
- this.label = 'view';
19
- this._handleViewOptionsChange = () => {
20
- this.#updateViewOptions();
21
- };
22
- this._viewOptions = _a.DEFAULT_VIEW_OPTIONS;
23
- }
24
- static { this.DEFAULT_VIEW_OPTIONS = ['author', 'candidate', 'proctor', 'scorer', 'testConstructor', 'tutor']; }
25
- connectedCallback() {
26
- super.connectedCallback();
27
- this.#updateViewOptions();
28
- }
29
- #updateViewOptions() {
30
- if (this.viewOptions) {
31
- const options = this.viewOptions.split(',').map(opt => opt.trim());
32
- this._viewOptions = options.filter(opt => _a.DEFAULT_VIEW_OPTIONS.includes(opt));
33
- }
34
- else {
35
- this._viewOptions = _a.DEFAULT_VIEW_OPTIONS;
36
- }
37
- }
38
- _switchView(view) {
39
- dispatchPublic(this, 'cito-test-switch-view', view);
40
- }
41
- render() {
42
- return html `
43
- <label part="label" for="viewSelect">${this.label}</label>
44
- <select
45
- part="select"
46
- id="viewSelect"
47
- @change=${(e) => {
48
- const el = e.target;
49
- this._switchView(el.value);
50
- }}
51
- >
52
- ${this._viewOptions.map(v => html `<option value="${v}" ?selected=${v === this.sessionContext.view}>${v}</option>`)}
53
- </select>
54
- `;
55
- }
56
- }
57
- _a = TestView;
58
- __decorate([
59
- consume({ context: sessionContext, subscribe: true })
60
- ], TestView.prototype, "sessionContext", void 0);
61
- __decorate([
62
- property({ type: String })
63
- ], TestView.prototype, "label", void 0);
64
- __decorate([
65
- property({ type: String, attribute: 'view-options' })
66
- ], TestView.prototype, "viewOptions", void 0);
67
- __decorate([
68
- watch('viewOptions', { waitUntilFirstUpdate: true })
69
- ], TestView.prototype, "_handleViewOptionsChange", void 0);
70
- __decorate([
71
- state()
72
- ], TestView.prototype, "_viewOptions", void 0);
73
- //# sourceMappingURL=test-view.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"test-view.js","sourceRoot":"","sources":["../../../src/components/test-view-toggle/test-view.ts"],"names":[],"mappings":";;;;;;;AAAA,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAEtD,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAKrD,MAAM,OAAO,QAAS,SAAQ,UAAU;IAAxC;;QAME,mDA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B,CAAC,CAAC,EAAE,CAAC,IAAI,CAAA,kBAAkB,CAAC,eAAe,CAAC,KAAK,IAAI,CAAC,cAAc,CAAC,IAAI,IAAI,CAAC,WAAW,CAC1F;;KAEJ,CAAC;IACJ,CAAC;;;AAlDO;IADP,OAAO,CAAC,EAAE,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;gDACf;AAIvC;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;uCACZ;AAGwC;IAAtD,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,cAAc,EAAE,CAAC;6CAAqB;AAEjE;IADT,KAAK,CAAC,aAAa,EAAE,EAAE,oBAAoB,EAAE,IAAI,EAAE,CAAC;0DAGnD;AAQM;IADP,KAAK,EAAE;8CACuD","sourcesContent":["import { html, LitElement } from 'lit';\nimport { property, state } from 'lit/decorators.js';\nimport { consume } from '@lit/context';\n\nimport { watch } from '@qti-components/utilities';\nimport { sessionContext } from '@qti-components/base';\n\nimport { dispatchPublic } from '../../public-events';\n\nimport type { SessionContext } from '@qti-components/base';\nimport type { View } from '@qti-components/base';\n\nexport class TestView extends LitElement {\n static DEFAULT_VIEW_OPTIONS = ['author', 'candidate', 'proctor', 'scorer', 'testConstructor', 'tutor'];\n\n @consume({ context: sessionContext, subscribe: true })\n private sessionContext: SessionContext;\n\n /** label accompanying the select view dropdown */\n @property({ type: String })\n label = 'view';\n\n /** The options to display in the dropdown, default: ['author', 'candidate', 'proctor', 'scorer', 'testConstructor', 'tutor'] */\n @property({ type: String, attribute: 'view-options' }) viewOptions: string;\n @watch('viewOptions', { waitUntilFirstUpdate: true })\n protected _handleViewOptionsChange = () => {\n this.#updateViewOptions();\n };\n\n override connectedCallback(): void {\n super.connectedCallback();\n this.#updateViewOptions();\n }\n\n @state()\n private _viewOptions: string[] = TestView.DEFAULT_VIEW_OPTIONS;\n\n #updateViewOptions() {\n if (this.viewOptions) {\n const options = this.viewOptions.split(',').map(opt => opt.trim());\n this._viewOptions = options.filter(opt => TestView.DEFAULT_VIEW_OPTIONS.includes(opt));\n } else {\n this._viewOptions = TestView.DEFAULT_VIEW_OPTIONS;\n }\n }\n\n protected _switchView(view: string) {\n dispatchPublic(this, 'cito-test-switch-view', view as View);\n }\n\n override render() {\n return html`\n <label part=\"label\" for=\"viewSelect\">${this.label}</label>\n <select\n part=\"select\"\n id=\"viewSelect\"\n @change=${(e: Event) => {\n const el = e.target as HTMLSelectElement;\n this._switchView(el.value);\n }}\n >\n ${this._viewOptions.map(\n v => html`<option value=\"${v}\" ?selected=${v === this.sessionContext.view}>${v}</option>`\n )}\n </select>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-view': TestView;\n }\n}\n"]}
@@ -1,28 +0,0 @@
1
- import { TestItemToSpeech, TestTtsNext, TestTtsPause, TestTtsPick, TestTtsPlay, TestTtsPrev, TestTtsResume, TestTtsStop } from './test-item-to-speech';
2
- export { TestItemToSpeech, TestTtsNext, TestTtsPause, TestTtsPick, TestTtsPlay, TestTtsPrev, TestTtsResume, TestTtsStop };
3
- /** The text-to-speech elements, for registering them yourself (e.g. in a scoped registry). Defines nothing. */
4
- export declare const ttsElements: readonly [{
5
- readonly tag: "test-item-to-speech";
6
- readonly ctor: typeof TestItemToSpeech;
7
- }, {
8
- readonly tag: "test-tts-next";
9
- readonly ctor: typeof TestTtsNext;
10
- }, {
11
- readonly tag: "test-tts-pause";
12
- readonly ctor: typeof TestTtsPause;
13
- }, {
14
- readonly tag: "test-tts-pick";
15
- readonly ctor: typeof TestTtsPick;
16
- }, {
17
- readonly tag: "test-tts-play";
18
- readonly ctor: typeof TestTtsPlay;
19
- }, {
20
- readonly tag: "test-tts-prev";
21
- readonly ctor: typeof TestTtsPrev;
22
- }, {
23
- readonly tag: "test-tts-resume";
24
- readonly ctor: typeof TestTtsResume;
25
- }, {
26
- readonly tag: "test-tts-stop";
27
- readonly ctor: typeof TestTtsStop;
28
- }];
@@ -1,14 +0,0 @@
1
- import { TestItemToSpeech, TestTtsNext, TestTtsPause, TestTtsPick, TestTtsPlay, TestTtsPrev, TestTtsResume, TestTtsStop } from './test-item-to-speech';
2
- export { TestItemToSpeech, TestTtsNext, TestTtsPause, TestTtsPick, TestTtsPlay, TestTtsPrev, TestTtsResume, TestTtsStop };
3
- /** The text-to-speech elements, for registering them yourself (e.g. in a scoped registry). Defines nothing. */
4
- export const ttsElements = [
5
- { tag: 'test-item-to-speech', ctor: TestItemToSpeech },
6
- { tag: 'test-tts-next', ctor: TestTtsNext },
7
- { tag: 'test-tts-pause', ctor: TestTtsPause },
8
- { tag: 'test-tts-pick', ctor: TestTtsPick },
9
- { tag: 'test-tts-play', ctor: TestTtsPlay },
10
- { tag: 'test-tts-prev', ctor: TestTtsPrev },
11
- { tag: 'test-tts-resume', ctor: TestTtsResume },
12
- { tag: 'test-tts-stop', ctor: TestTtsStop }
13
- ];
14
- //# sourceMappingURL=elements.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"elements.js","sourceRoot":"","sources":["../../src/tts/elements.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAChB,WAAW,EACX,YAAY,EACZ,WAAW,EACX,WAAW,EACX,WAAW,EACX,aAAa,EACb,WAAW,EACZ,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EACL,gBAAgB,EAChB,WAAW,EACX,YAAY,EACZ,WAAW,EACX,WAAW,EACX,WAAW,EACX,aAAa,EACb,WAAW,EACZ,CAAC;AAEF,+GAA+G;AAC/G,MAAM,CAAC,MAAM,WAAW,GAAG;IACzB,EAAE,GAAG,EAAE,qBAAqB,EAAE,IAAI,EAAE,gBAAgB,EAAE;IACtD,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,WAAW,EAAE;IAC3C,EAAE,GAAG,EAAE,gBAAgB,EAAE,IAAI,EAAE,YAAY,EAAE;IAC7C,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,WAAW,EAAE;IAC3C,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,WAAW,EAAE;IAC3C,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,WAAW,EAAE;IAC3C,EAAE,GAAG,EAAE,iBAAiB,EAAE,IAAI,EAAE,aAAa,EAAE;IAC/C,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,WAAW,EAAE;CACnC,CAAC","sourcesContent":["import {\n TestItemToSpeech,\n TestTtsNext,\n TestTtsPause,\n TestTtsPick,\n TestTtsPlay,\n TestTtsPrev,\n TestTtsResume,\n TestTtsStop\n} from './test-item-to-speech';\n\nexport {\n TestItemToSpeech,\n TestTtsNext,\n TestTtsPause,\n TestTtsPick,\n TestTtsPlay,\n TestTtsPrev,\n TestTtsResume,\n TestTtsStop\n};\n\n/** The text-to-speech elements, for registering them yourself (e.g. in a scoped registry). Defines nothing. */\nexport const ttsElements = [\n { tag: 'test-item-to-speech', ctor: TestItemToSpeech },\n { tag: 'test-tts-next', ctor: TestTtsNext },\n { tag: 'test-tts-pause', ctor: TestTtsPause },\n { tag: 'test-tts-pick', ctor: TestTtsPick },\n { tag: 'test-tts-play', ctor: TestTtsPlay },\n { tag: 'test-tts-prev', ctor: TestTtsPrev },\n { tag: 'test-tts-resume', ctor: TestTtsResume },\n { tag: 'test-tts-stop', ctor: TestTtsStop }\n] as const;\n"]}