@pie-element/complex-rubric 0.0.2-next.4424 → 0.1.0

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 (204) hide show
  1. package/dist/author/defaults.d.ts +232 -0
  2. package/dist/author/defaults.d.ts.map +1 -0
  3. package/dist/author/defaults.js +177 -0
  4. package/dist/author/index.d.ts +35 -0
  5. package/dist/author/index.d.ts.map +1 -0
  6. package/dist/author/index.js +86 -0
  7. package/dist/author/main.d.ts +24 -0
  8. package/dist/author/main.d.ts.map +1 -0
  9. package/dist/author/main.js +106 -0
  10. package/dist/controller/defaults.d.ts +40 -0
  11. package/dist/controller/defaults.d.ts.map +1 -0
  12. package/dist/controller/defaults.js +42 -0
  13. package/dist/controller/index.d.ts +26 -0
  14. package/dist/controller/index.d.ts.map +1 -0
  15. package/dist/controller/index.js +107 -0
  16. package/dist/controller/utils.d.ts +10 -0
  17. package/dist/controller/utils.d.ts.map +1 -0
  18. package/dist/controller/utils.js +4 -0
  19. package/dist/delivery/index.d.ts +24 -0
  20. package/dist/delivery/index.d.ts.map +1 -0
  21. package/dist/delivery/index.js +96 -0
  22. package/dist/index.d.ts +2 -0
  23. package/dist/index.d.ts.map +1 -0
  24. package/dist/index.iife.d.ts +9 -0
  25. package/dist/index.iife.d.ts.map +1 -0
  26. package/dist/index.iife.js +145 -0
  27. package/dist/index.js +2 -0
  28. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_Symbol.js +5 -0
  29. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_apply.js +12 -0
  30. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_arrayLikeKeys.js +15 -0
  31. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseGetTag.js +10 -0
  32. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseIsArguments.js +9 -0
  33. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseIsNative.js +11 -0
  34. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseIsTypedArray.js +11 -0
  35. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseKeysIn.js +13 -0
  36. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseRest.js +9 -0
  37. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseSetToString.js +14 -0
  38. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseTimes.js +7 -0
  39. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_baseUnary.js +8 -0
  40. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_coreJsData.js +5 -0
  41. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_defineProperty.js +10 -0
  42. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_freeGlobal.js +4 -0
  43. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_getNative.js +9 -0
  44. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_getRawTag.js +14 -0
  45. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_getValue.js +6 -0
  46. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_isIndex.js +8 -0
  47. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_isIterateeCall.js +12 -0
  48. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_isMasked.js +11 -0
  49. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_isPrototype.js +8 -0
  50. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_nativeKeysIn.js +8 -0
  51. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_nodeUtil.js +9 -0
  52. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_objectToString.js +7 -0
  53. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_overRest.js +13 -0
  54. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_root.js +5 -0
  55. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_setToString.js +6 -0
  56. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_shortOut.js +14 -0
  57. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/_toSource.js +15 -0
  58. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/constant.js +8 -0
  59. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/defaults.js +16 -0
  60. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/eq.js +6 -0
  61. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/identity.js +6 -0
  62. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isArguments.js +10 -0
  63. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isArray.js +4 -0
  64. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isArrayLike.js +8 -0
  65. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isBuffer.js +6 -0
  66. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isFunction.js +11 -0
  67. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isLength.js +7 -0
  68. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isObject.js +7 -0
  69. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isObjectLike.js +6 -0
  70. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/isTypedArray.js +7 -0
  71. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/keysIn.js +9 -0
  72. package/dist/node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/stubFalse.js +6 -0
  73. package/dist/print/index.d.ts +25 -0
  74. package/dist/print/index.d.ts.map +1 -0
  75. package/dist/print/index.js +84 -0
  76. package/package.json +65 -16
  77. package/src/author/defaults.tsx +223 -0
  78. package/{configure/src/index.js → src/author/index.ts} +69 -28
  79. package/src/author/main.tsx +172 -0
  80. package/src/controller/defaults.ts +49 -0
  81. package/src/controller/index.ts +230 -0
  82. package/src/controller/utils.ts +13 -0
  83. package/src/{index.js → delivery/index.ts} +65 -9
  84. package/src/index.iife.ts +16 -0
  85. package/src/index.ts +1 -0
  86. package/src/print/index.ts +150 -0
  87. package/LICENSE.md +0 -5
  88. package/README.md +0 -3
  89. package/configure/lib/defaults.js +0 -99
  90. package/configure/lib/defaults.js.map +0 -1
  91. package/configure/lib/index.js +0 -232
  92. package/configure/lib/index.js.map +0 -1
  93. package/configure/lib/main.js +0 -165
  94. package/configure/lib/main.js.map +0 -1
  95. package/configure/node_modules/@pie-element/multi-trait-rubric/CHANGELOG.json +0 -1
  96. package/configure/node_modules/@pie-element/multi-trait-rubric/CHANGELOG.md +0 -376
  97. package/configure/node_modules/@pie-element/multi-trait-rubric/LICENSE.md +0 -5
  98. package/configure/node_modules/@pie-element/multi-trait-rubric/README.md +0 -55
  99. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/CHANGELOG.json +0 -1
  100. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/CHANGELOG.md +0 -344
  101. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/common.js +0 -455
  102. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/common.js.map +0 -1
  103. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/defaults.js +0 -82
  104. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/defaults.js.map +0 -1
  105. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/index.js +0 -112
  106. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/index.js.map +0 -1
  107. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/main.js +0 -438
  108. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/main.js.map +0 -1
  109. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/modals.js +0 -324
  110. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/modals.js.map +0 -1
  111. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/scale.js +0 -490
  112. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/scale.js.map +0 -1
  113. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/trait.js +0 -334
  114. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/trait.js.map +0 -1
  115. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/traitsHeader.js +0 -254
  116. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/traitsHeader.js.map +0 -1
  117. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/utils.js +0 -29
  118. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/lib/utils.js.map +0 -1
  119. package/configure/node_modules/@pie-element/multi-trait-rubric/configure/package.json +0 -22
  120. package/configure/node_modules/@pie-element/multi-trait-rubric/controller/CHANGELOG.json +0 -1
  121. package/configure/node_modules/@pie-element/multi-trait-rubric/controller/CHANGELOG.md +0 -66
  122. package/configure/node_modules/@pie-element/multi-trait-rubric/controller/lib/defaults.js +0 -9
  123. package/configure/node_modules/@pie-element/multi-trait-rubric/controller/lib/defaults.js.map +0 -1
  124. package/configure/node_modules/@pie-element/multi-trait-rubric/controller/lib/index.js +0 -122
  125. package/configure/node_modules/@pie-element/multi-trait-rubric/controller/lib/index.js.map +0 -1
  126. package/configure/node_modules/@pie-element/multi-trait-rubric/controller/package.json +0 -15
  127. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/config-schema.json +0 -226
  128. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/config-schema.json.md +0 -169
  129. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/demo/config.js +0 -8
  130. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/demo/generate.js +0 -108
  131. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/demo/index.html +0 -1
  132. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/demo/session.js +0 -6
  133. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/pie-schema.json +0 -282
  134. package/configure/node_modules/@pie-element/multi-trait-rubric/docs/pie-schema.json.md +0 -189
  135. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/index.js +0 -85
  136. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/index.js.map +0 -1
  137. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/main.js +0 -99
  138. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/main.js.map +0 -1
  139. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/scale.js +0 -209
  140. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/scale.js.map +0 -1
  141. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/trait.js +0 -103
  142. package/configure/node_modules/@pie-element/multi-trait-rubric/lib/trait.js.map +0 -1
  143. package/configure/node_modules/@pie-element/multi-trait-rubric/package.json +0 -24
  144. package/configure/node_modules/@pie-element/rubric/CHANGELOG.json +0 -257
  145. package/configure/node_modules/@pie-element/rubric/CHANGELOG.md +0 -731
  146. package/configure/node_modules/@pie-element/rubric/LICENSE.md +0 -5
  147. package/configure/node_modules/@pie-element/rubric/README.md +0 -3
  148. package/configure/node_modules/@pie-element/rubric/configure/CHANGELOG.json +0 -197
  149. package/configure/node_modules/@pie-element/rubric/configure/CHANGELOG.md +0 -615
  150. package/configure/node_modules/@pie-element/rubric/configure/lib/index.js +0 -93
  151. package/configure/node_modules/@pie-element/rubric/configure/lib/index.js.map +0 -1
  152. package/configure/node_modules/@pie-element/rubric/configure/package.json +0 -16
  153. package/configure/node_modules/@pie-element/rubric/configure/src/index.js +0 -38
  154. package/configure/node_modules/@pie-element/rubric/controller/CHANGELOG.json +0 -17
  155. package/configure/node_modules/@pie-element/rubric/controller/CHANGELOG.md +0 -105
  156. package/configure/node_modules/@pie-element/rubric/controller/lib/index.js +0 -14
  157. package/configure/node_modules/@pie-element/rubric/controller/lib/index.js.map +0 -1
  158. package/configure/node_modules/@pie-element/rubric/controller/package.json +0 -9
  159. package/configure/node_modules/@pie-element/rubric/controller/src/__tests__/index.test.js +0 -35
  160. package/configure/node_modules/@pie-element/rubric/controller/src/index.js +0 -6
  161. package/configure/node_modules/@pie-element/rubric/docs/config-schema.json +0 -24
  162. package/configure/node_modules/@pie-element/rubric/docs/config-schema.json.md +0 -19
  163. package/configure/node_modules/@pie-element/rubric/docs/demo/config.js +0 -8
  164. package/configure/node_modules/@pie-element/rubric/docs/demo/generate.js +0 -8
  165. package/configure/node_modules/@pie-element/rubric/docs/demo/index.html +0 -3
  166. package/configure/node_modules/@pie-element/rubric/docs/pie-schema.json +0 -62
  167. package/configure/node_modules/@pie-element/rubric/docs/pie-schema.json.md +0 -35
  168. package/configure/node_modules/@pie-element/rubric/lib/index.js +0 -88
  169. package/configure/node_modules/@pie-element/rubric/lib/index.js.map +0 -1
  170. package/configure/node_modules/@pie-element/rubric/lib/main.js +0 -171
  171. package/configure/node_modules/@pie-element/rubric/lib/main.js.map +0 -1
  172. package/configure/node_modules/@pie-element/rubric/lib/print.js +0 -114
  173. package/configure/node_modules/@pie-element/rubric/lib/print.js.map +0 -1
  174. package/configure/node_modules/@pie-element/rubric/package.json +0 -25
  175. package/configure/node_modules/@pie-element/rubric/src/__tests__/__snapshots__/rubric-view.test.jsx.snap +0 -22767
  176. package/configure/node_modules/@pie-element/rubric/src/__tests__/rubric-view.test.jsx +0 -48
  177. package/configure/node_modules/@pie-element/rubric/src/index.js +0 -38
  178. package/configure/node_modules/@pie-element/rubric/src/main.jsx +0 -117
  179. package/configure/node_modules/@pie-element/rubric/src/print.js +0 -63
  180. package/configure/package.json +0 -22
  181. package/configure/src/__tests__/__snapshots__/main.test.jsx.snap +0 -106
  182. package/configure/src/__tests__/index.test.js +0 -41
  183. package/configure/src/__tests__/main.test.jsx +0 -104
  184. package/configure/src/defaults.js +0 -122
  185. package/configure/src/main.jsx +0 -117
  186. package/controller/lib/defaults.js +0 -99
  187. package/controller/lib/defaults.js.map +0 -1
  188. package/controller/lib/index.js +0 -147
  189. package/controller/lib/index.js.map +0 -1
  190. package/controller/package.json +0 -12
  191. package/controller/src/__tests__/index.test.js +0 -58
  192. package/controller/src/defaults.js +0 -121
  193. package/controller/src/index.js +0 -81
  194. package/docs/config-schema.json +0 -427
  195. package/docs/config-schema.json.md +0 -315
  196. package/docs/demo/config.js +0 -8
  197. package/docs/demo/generate.js +0 -119
  198. package/docs/demo/index.html +0 -1
  199. package/docs/demo/session.js +0 -6
  200. package/docs/pie-schema.json +0 -994
  201. package/docs/pie-schema.json.md +0 -660
  202. package/lib/index.js +0 -176
  203. package/lib/index.js.map +0 -1
  204. package/src/__tests__/index.test.js +0 -166
@@ -0,0 +1,232 @@
1
+ /**
2
+ * @synced-from pie-elements/packages/complex-rubric/configure/src/defaults.js
3
+ * @auto-generated
4
+ *
5
+ * This file is automatically synced from pie-elements and converted to TypeScript.
6
+ * Manual edits will be overwritten on next sync.
7
+ * To make changes, edit the upstream JavaScript file and run sync again.
8
+ */
9
+ import { RUBRIC_TYPES } from '@pie-lib/rubric';
10
+ declare const _default: {
11
+ model: {
12
+ rubricType: string;
13
+ rubrics: {
14
+ [RUBRIC_TYPES.SIMPLE_RUBRIC]: {
15
+ points: string[];
16
+ sampleAnswers: null[];
17
+ maxPoints: number;
18
+ excludeZero: boolean;
19
+ };
20
+ [RUBRIC_TYPES.MULTI_TRAIT_RUBRIC]: {
21
+ description: boolean;
22
+ excludeZero: boolean;
23
+ halfScoring: boolean;
24
+ pointLabels: boolean;
25
+ scales: never[];
26
+ standards: boolean;
27
+ visibleToStudent: boolean;
28
+ };
29
+ [RUBRIC_TYPES.RUBRICLESS]: {
30
+ maxPoints: number;
31
+ excludeZero: boolean;
32
+ rubriclessInstructionEnabled: boolean;
33
+ };
34
+ };
35
+ };
36
+ configuration: {
37
+ [RUBRIC_TYPES.MULTI_TRAIT_RUBRIC]: {
38
+ baseInputConfiguration: {
39
+ h3: {
40
+ disabled: boolean;
41
+ };
42
+ audio: {
43
+ disabled: boolean;
44
+ };
45
+ video: {
46
+ disabled: boolean;
47
+ };
48
+ image: {
49
+ disabled: boolean;
50
+ };
51
+ textAlign: {
52
+ disabled: boolean;
53
+ };
54
+ showParagraphs: {
55
+ disabled: boolean;
56
+ };
57
+ };
58
+ expandedInput: {
59
+ inputConfiguration: {
60
+ math: {
61
+ disabled: boolean;
62
+ };
63
+ audio: {
64
+ disabled: boolean;
65
+ };
66
+ video: {
67
+ disabled: boolean;
68
+ };
69
+ image: {
70
+ disabled: boolean;
71
+ };
72
+ };
73
+ };
74
+ labelInput: {
75
+ inputConfiguration: {
76
+ math: {
77
+ disabled: boolean;
78
+ };
79
+ audio: {
80
+ disabled: boolean;
81
+ };
82
+ video: {
83
+ disabled: boolean;
84
+ };
85
+ image: {
86
+ disabled: boolean;
87
+ };
88
+ };
89
+ };
90
+ settingsPanelDisabled: boolean;
91
+ excludeZeroDialogBoxContent: {
92
+ title: string;
93
+ text: string;
94
+ };
95
+ includeZeroDialogBoxContent: {
96
+ title: string;
97
+ text: string;
98
+ };
99
+ deleteScaleDialogBoxContent: {
100
+ title: string;
101
+ text: string;
102
+ };
103
+ maxPointsDialogBoxContent: {
104
+ title: string;
105
+ text: string;
106
+ };
107
+ spellCheck: {
108
+ label: string;
109
+ settings: boolean;
110
+ enabled: boolean;
111
+ };
112
+ showExcludeZero: {
113
+ settings: boolean;
114
+ label: string;
115
+ };
116
+ showScorePointLabels: {
117
+ settings: boolean;
118
+ label: string;
119
+ };
120
+ showDescription: {
121
+ settings: boolean;
122
+ label: string;
123
+ };
124
+ showVisibleToStudent: {
125
+ settings: boolean;
126
+ label: string;
127
+ };
128
+ showHalfScoring: {
129
+ settings: boolean;
130
+ label: string;
131
+ };
132
+ showStandards: {
133
+ settings: boolean;
134
+ label: string;
135
+ };
136
+ showLevelTagInput: {
137
+ settings: boolean;
138
+ label: string;
139
+ enabled: boolean;
140
+ };
141
+ dragAndDrop: {
142
+ settings: boolean;
143
+ label: string;
144
+ enabled: boolean;
145
+ };
146
+ maxMaxPoints: number;
147
+ };
148
+ [RUBRIC_TYPES.SIMPLE_RUBRIC]: {
149
+ baseInputConfiguration: {
150
+ h3: {
151
+ disabled: boolean;
152
+ };
153
+ audio: {
154
+ disabled: boolean;
155
+ };
156
+ video: {
157
+ disabled: boolean;
158
+ };
159
+ image: {
160
+ disabled: boolean;
161
+ };
162
+ textAlign: {
163
+ disabled: boolean;
164
+ };
165
+ showParagraphs: {
166
+ disabled: boolean;
167
+ };
168
+ };
169
+ showExcludeZero: {
170
+ settings: boolean;
171
+ label: string;
172
+ };
173
+ showMaxPoint: {
174
+ settings: boolean;
175
+ label: string;
176
+ };
177
+ settingsPanelDisabled: boolean;
178
+ maxMaxPoints: number;
179
+ };
180
+ [RUBRIC_TYPES.RUBRICLESS]: {
181
+ baseInputConfiguration: {
182
+ h3: {
183
+ disabled: boolean;
184
+ };
185
+ audio: {
186
+ disabled: boolean;
187
+ };
188
+ video: {
189
+ disabled: boolean;
190
+ };
191
+ image: {
192
+ disabled: boolean;
193
+ };
194
+ textAlign: {
195
+ disabled: boolean;
196
+ };
197
+ showParagraphs: {
198
+ disabled: boolean;
199
+ };
200
+ };
201
+ showExcludeZero: {
202
+ settings: boolean;
203
+ label: string;
204
+ };
205
+ showMaxPoint: {
206
+ settings: boolean;
207
+ label: string;
208
+ };
209
+ settingsPanelDisabled: boolean;
210
+ rubricless: boolean;
211
+ rubriclessInstruction: {
212
+ settings: boolean;
213
+ label: string;
214
+ inputConfiguration: {
215
+ audio: {
216
+ disabled: boolean;
217
+ };
218
+ video: {
219
+ disabled: boolean;
220
+ };
221
+ image: {
222
+ disabled: boolean;
223
+ };
224
+ };
225
+ };
226
+ maxMaxPoints: number;
227
+ };
228
+ rubricOptions: string[];
229
+ };
230
+ };
231
+ export default _default;
232
+ //# sourceMappingURL=defaults.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"defaults.d.ts","sourceRoot":"","sources":["../../src/author/defaults.tsx"],"names":[],"mappings":"AACA;;;;;;;GAOG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;;;;;YAwMzC,CAAC,YAAY,CAAC,aAAa,CAAC;;;;;cAAoB;YAChD,CAAC,YAAY,CAAC,kBAAkB,CAAC;;;;;;;;cAAwB;YACzD,CAAC,YAAY,CAAC,UAAU,CAAC;;;;cAAwB;;;;QAMnD,CAAC,YAAY,CAAC,kBAAkB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAAgC;QACjE,CAAC,YAAY,CAAC,aAAa,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAA4B;QACxD,CAAC,YAAY,CAAC,UAAU,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAAgC;;;;AAd7D,wBAgBE"}
@@ -0,0 +1,177 @@
1
+ import { RUBRIC_TYPES as e } from "@pie-lib/rubric";
2
+ //#region src/author/defaults.tsx
3
+ var t = {
4
+ description: !1,
5
+ excludeZero: !1,
6
+ halfScoring: !1,
7
+ pointLabels: !0,
8
+ scales: [],
9
+ standards: !1,
10
+ visibleToStudent: !0
11
+ }, n = {
12
+ points: [
13
+ "",
14
+ "",
15
+ "",
16
+ ""
17
+ ],
18
+ sampleAnswers: [
19
+ null,
20
+ null,
21
+ null,
22
+ null
23
+ ],
24
+ maxPoints: 3,
25
+ excludeZero: !1
26
+ }, r = {
27
+ maxPoints: 100,
28
+ excludeZero: !1,
29
+ rubriclessInstructionEnabled: !0
30
+ }, i = {
31
+ baseInputConfiguration: {
32
+ h3: { disabled: !0 },
33
+ audio: { disabled: !1 },
34
+ video: { disabled: !1 },
35
+ image: { disabled: !1 },
36
+ textAlign: { disabled: !0 },
37
+ showParagraphs: { disabled: !1 }
38
+ },
39
+ expandedInput: { inputConfiguration: {
40
+ math: { disabled: !0 },
41
+ audio: { disabled: !1 },
42
+ video: { disabled: !1 },
43
+ image: { disabled: !1 }
44
+ } },
45
+ labelInput: { inputConfiguration: {
46
+ math: { disabled: !0 },
47
+ audio: { disabled: !0 },
48
+ video: { disabled: !0 },
49
+ image: { disabled: !0 }
50
+ } },
51
+ settingsPanelDisabled: !1,
52
+ excludeZeroDialogBoxContent: {
53
+ title: "Exclude 0 (Zero) from Score Point Values.",
54
+ text: "<div>\n You are about to exclude 0 from score point values.\n <br/>\n Some of the existing data has to be changed.\n <br/>\n Please choose if you want to:\n <ul>\n <li>\n shift Labels and Descriptions to the left\n </li>\n <li>\n remove 0 column with its Label and Description\n </li>\n </ul>\n </div>"
55
+ },
56
+ includeZeroDialogBoxContent: {
57
+ title: "Include 0 (Zero) in Score Point Values.",
58
+ text: "<div>\n You are about to include 0 in score point values.\n <br/>\n Some of the existing data has to be changed.\n <br/>\n Please choose if you want to:\n <ul>\n <li>\n shift Labels and Descriptions to the right\n </li>\n <li>\n add 0 column with empty Label and Descriptions\n </li>\n </ul>\n </div>"
59
+ },
60
+ deleteScaleDialogBoxContent: {
61
+ title: "Delete Scale",
62
+ text: "Are you sure you want to delete this scale?"
63
+ },
64
+ maxPointsDialogBoxContent: {
65
+ title: "Decreasing Max Points.",
66
+ text: " You are about to decrease max score point value.\n <br/>\n All the Labels and Descriptions for scores above Max Point will be deleted."
67
+ },
68
+ spellCheck: {
69
+ label: "Spellcheck",
70
+ settings: !1,
71
+ enabled: !0
72
+ },
73
+ showExcludeZero: {
74
+ settings: !0,
75
+ label: "Exclude Zero"
76
+ },
77
+ showScorePointLabels: {
78
+ settings: !0,
79
+ label: "Show Score Point Labels"
80
+ },
81
+ showDescription: {
82
+ settings: !0,
83
+ label: "Show Description"
84
+ },
85
+ showVisibleToStudent: {
86
+ settings: !0,
87
+ label: "Visible to Student"
88
+ },
89
+ showHalfScoring: {
90
+ settings: !0,
91
+ label: "Half Scoring"
92
+ },
93
+ showStandards: {
94
+ settings: !1,
95
+ label: "Show Standards"
96
+ },
97
+ showLevelTagInput: {
98
+ settings: !1,
99
+ label: "Show Level Tag Input",
100
+ enabled: !1
101
+ },
102
+ dragAndDrop: {
103
+ settings: !0,
104
+ label: "Enable Drag and Drop",
105
+ enabled: !1
106
+ },
107
+ maxMaxPoints: 9
108
+ }, a = {
109
+ baseInputConfiguration: {
110
+ h3: { disabled: !0 },
111
+ audio: { disabled: !1 },
112
+ video: { disabled: !1 },
113
+ image: { disabled: !1 },
114
+ textAlign: { disabled: !0 },
115
+ showParagraphs: { disabled: !1 }
116
+ },
117
+ showExcludeZero: {
118
+ settings: !0,
119
+ label: "Ability to exclude zero"
120
+ },
121
+ showMaxPoint: {
122
+ settings: !0,
123
+ label: "Show max points dropdown"
124
+ },
125
+ settingsPanelDisabled: !1,
126
+ maxMaxPoints: 9
127
+ }, o = {
128
+ baseInputConfiguration: {
129
+ h3: { disabled: !0 },
130
+ audio: { disabled: !1 },
131
+ video: { disabled: !1 },
132
+ image: { disabled: !1 },
133
+ textAlign: { disabled: !0 },
134
+ showParagraphs: { disabled: !1 }
135
+ },
136
+ showExcludeZero: {
137
+ settings: !0,
138
+ label: "Ability to exclude zero"
139
+ },
140
+ showMaxPoint: {
141
+ settings: !0,
142
+ label: "Show max points dropdown"
143
+ },
144
+ settingsPanelDisabled: !1,
145
+ rubricless: !0,
146
+ rubriclessInstruction: {
147
+ settings: !0,
148
+ label: "Instruction",
149
+ inputConfiguration: {
150
+ audio: { disabled: !1 },
151
+ video: { disabled: !1 },
152
+ image: { disabled: !1 }
153
+ }
154
+ },
155
+ maxMaxPoints: 100
156
+ }, s = {
157
+ model: {
158
+ rubricType: "simpleRubric",
159
+ rubrics: {
160
+ [e.SIMPLE_RUBRIC]: n,
161
+ [e.MULTI_TRAIT_RUBRIC]: t,
162
+ [e.RUBRICLESS]: r
163
+ }
164
+ },
165
+ configuration: {
166
+ rubricOptions: [
167
+ "simpleRubric",
168
+ "multiTraitRubric",
169
+ "rubricless"
170
+ ],
171
+ [e.MULTI_TRAIT_RUBRIC]: i,
172
+ [e.SIMPLE_RUBRIC]: a,
173
+ [e.RUBRICLESS]: o
174
+ }
175
+ };
176
+ //#endregion
177
+ export { s as default };
@@ -0,0 +1,35 @@
1
+ /**
2
+ * @synced-from pie-elements/packages/complex-rubric/configure/src/index.js
3
+ * @auto-generated
4
+ *
5
+ * This file is automatically synced from pie-elements and converted to TypeScript.
6
+ * Manual edits will be overwritten on next sync.
7
+ * To make changes, edit the upstream JavaScript file and run sync again.
8
+ */
9
+ export default class ComplexRubricConfigureElement extends HTMLElement {
10
+ static createDefaultModel: ({ rubrics: { simpleRubric, rubricless, multiTraitRubric }, ...model }?: {
11
+ rubrics?: {
12
+ simpleRubric?: {};
13
+ rubricless?: {};
14
+ multiTraitRubric?: {};
15
+ } | undefined;
16
+ }, currentModel?: {}) => {
17
+ rubrics: {
18
+ simpleRubric: any;
19
+ multiTraitRubric: any;
20
+ rubricless: any;
21
+ };
22
+ rubricType: string;
23
+ };
24
+ constructor();
25
+ set model(m: any);
26
+ dispatchModelUpdated(reset: any): void;
27
+ onModelChanged: any;
28
+ set configuration(c: any);
29
+ onConfigurationChanged(c: any): void;
30
+ onModelUpdated: any;
31
+ connectedCallback(): void;
32
+ _render(): void;
33
+ disconnectedCallback(): void;
34
+ }
35
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/author/index.ts"],"names":[],"mappings":"AACA;;;;;;;GAOG;AAyCH,MAAM,CAAC,OAAO,OAAO,6BAA8B,SAAQ,WAAW;IACpE,MAAM,CAAC,kBAAkB,GACvB;;;;;;KAGM,EACN,iBAAiB;;;;;;;MAyBhB;;IAeH,IAAI,KAAK,CAAC,CAAC,KAAA,EAKV;IAED,oBAAoB,CAAC,KAAK,KAAA;IAM1B,cAAc,EAAE,GAAG,CAMjB;IAEF,IAAI,aAAa,CAAC,CAAC,KAAA,EAKlB;IAED,sBAAsB,CAAC,CAAC,KAAA;IAUxB,cAAc,EAAE,GAAG,CAiBjB;IAEF,iBAAiB;IAKjB,OAAO;IAeP,oBAAoB;CAMrB"}
@@ -0,0 +1,86 @@
1
+ import e from "../node_modules/.bun/lodash-es@4.17.23/node_modules/lodash-es/defaults.js";
2
+ import t from "./main.js";
3
+ import n from "./defaults.js";
4
+ import { ModelUpdatedEvent as r } from "@pie-element/shared-configure-events";
5
+ import i from "react";
6
+ import { createRoot as a } from "react-dom/client";
7
+ import o from "@pie-element/rubric/author";
8
+ import s from "@pie-element/multi-trait-rubric/author";
9
+ import c from "debug";
10
+ //#region src/author/index.ts
11
+ var l = r.TYPE, u = "rubric-configure", d = "multi-trait-rubric-configure", f = class extends o {}, p = class extends s {};
12
+ customElements.get(u) || customElements.define(u, f), customElements.get(d) || customElements.define(d, p);
13
+ var m = (t, r) => ({
14
+ configuration: e(t, n.configuration),
15
+ model: r
16
+ }), h = class e extends HTMLElement {
17
+ static createDefaultModel = ({ rubrics: { simpleRubric: e = {}, rubricless: t = {}, multiTraitRubric: r = {} } = {
18
+ simpleRubric: {},
19
+ rubricless: {},
20
+ multiTraitRubric: {}
21
+ }, ...i } = {}, a = {}) => ({
22
+ ...n?.model || {},
23
+ ...a,
24
+ ...i,
25
+ rubrics: {
26
+ simpleRubric: {
27
+ ...(n?.model?.rubrics || {}).simpleRubric,
28
+ ...(a.rubrics || {}).simpleRubric,
29
+ ...e
30
+ },
31
+ multiTraitRubric: {
32
+ ...(n?.model?.rubrics || {}).multiTraitRubric,
33
+ ...(a.rubrics || {}).multiTraitRubric,
34
+ ...r
35
+ },
36
+ rubricless: {
37
+ ...(n?.model?.rubrics || {}).rubricless,
38
+ ...(a.rubrics || {}).rubricless,
39
+ ...t
40
+ }
41
+ }
42
+ });
43
+ constructor() {
44
+ super(), this._root = null, this.canUpdateModel = !1, c.log("constructor called"), this._model = e.createDefaultModel(), this._configuration = n.configuration, this.onConfigurationChanged = this.onConfigurationChanged.bind(this);
45
+ }
46
+ set model(t) {
47
+ this._model = e.createDefaultModel(t, this._model), this.canUpdateModel = !0, this._render();
48
+ }
49
+ dispatchModelUpdated(e) {
50
+ let t = !!e;
51
+ this.dispatchEvent(new r(this._model, t));
52
+ }
53
+ onModelChanged = (t, n) => {
54
+ this._model = e.createDefaultModel(t, this._model), this.dispatchModelUpdated(n), this._render();
55
+ };
56
+ set configuration(e) {
57
+ this._configuration = m(e, this._model).configuration, this._render();
58
+ }
59
+ onConfigurationChanged(e) {
60
+ this._configuration = m(e, this._model).configuration, this._model && this.onModelChanged(this._model), this._render();
61
+ }
62
+ onModelUpdated = (e) => {
63
+ if (e.target === this) return;
64
+ e.preventDefault(), e.stopImmediatePropagation();
65
+ let t = e.target && e.target.getAttribute("id");
66
+ t && (e.update && (this._model.rubrics[t] = e.update), this.dispatchEvent(new r(this._model)));
67
+ };
68
+ connectedCallback() {
69
+ this.addEventListener(l, this.onModelUpdated), this._render();
70
+ }
71
+ _render() {
72
+ let e = i.createElement(t, {
73
+ model: this._model,
74
+ configuration: this._configuration,
75
+ onModelChanged: this.onModelChanged,
76
+ onConfigurationChanged: this.onConfigurationChanged,
77
+ canUpdateModel: this.canUpdateModel
78
+ });
79
+ this._root ||= a(this), this._root.render(e);
80
+ }
81
+ disconnectedCallback() {
82
+ this.removeEventListener(l, this.onModelUpdated), this._root && this._root.unmount();
83
+ }
84
+ };
85
+ //#endregion
86
+ export { h as default };
@@ -0,0 +1,24 @@
1
+ /**
2
+ * @synced-from pie-elements/packages/complex-rubric/configure/src/main.jsx
3
+ * @auto-generated
4
+ *
5
+ * This file is automatically synced from pie-elements and converted to TypeScript.
6
+ * Manual edits will be overwritten on next sync.
7
+ * To make changes, edit the upstream JavaScript file and run sync again.
8
+ */
9
+ import React from 'react';
10
+ import PropTypes from 'prop-types';
11
+ export declare class Main extends React.Component {
12
+ static propTypes: {
13
+ canUpdateModel: PropTypes.Requireable<boolean>;
14
+ configuration: PropTypes.Requireable<object>;
15
+ model: PropTypes.Requireable<object>;
16
+ onModelChanged: PropTypes.Requireable<(...args: any[]) => any>;
17
+ onConfigurationChanged: PropTypes.Requireable<(...args: any[]) => any>;
18
+ };
19
+ onModelChanged: any;
20
+ onChangeRubricType: any;
21
+ render(): React.JSX.Element;
22
+ }
23
+ export default Main;
24
+ //# sourceMappingURL=main.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../src/author/main.tsx"],"names":[],"mappings":"AACA;;;;;;;GAOG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,SAAS,MAAM,YAAY,CAAC;AAgCnC,qBAAa,IAAK,SAAQ,KAAK,CAAC,SAAS;IACvC,MAAM,CAAC,SAAS;;;;;;MAMd;IAEF,cAAc,EAAE,GAAG,CAIjB;IAEF,kBAAkB,EAAE,GAAG,CAKrB;IAEF,MAAM;CAwGP;AAED,eAAe,IAAI,CAAC"}
@@ -0,0 +1,106 @@
1
+ import { RUBRIC_TYPES as e } from "@pie-lib/rubric";
2
+ import t from "react";
3
+ import n from "prop-types";
4
+ import { layout as r } from "@pie-lib/config-ui";
5
+ import i from "@mui/material/Radio";
6
+ import a from "@mui/material/RadioGroup";
7
+ import o from "@mui/material/FormControlLabel";
8
+ import { styled as s } from "@mui/material/styles";
9
+ import { color as c } from "@pie-lib/render-ui";
10
+ import { jsx as l, jsxs as u } from "react/jsx-runtime";
11
+ //#region src/author/main.tsx
12
+ var d = s(o)({ "&.MuiFormControlLabel-root": {
13
+ width: "fit-content",
14
+ paddingRight: "24px",
15
+ boxSizing: "border-box",
16
+ "&:hover": { background: "var(--pie-secondary-background, rgba(241,241,241,1))" }
17
+ } }), f = s(i)({ "&.MuiRadio-root": { color: `${c.tertiary()} !important` } }), p = {
18
+ [e.MULTI_TRAIT_RUBRIC]: "Multi Trait Rubric",
19
+ [e.SIMPLE_RUBRIC]: "Simple Rubric",
20
+ [e.RUBRICLESS]: "Rubricless"
21
+ }, m = class extends t.Component {
22
+ static propTypes = {
23
+ canUpdateModel: n.bool,
24
+ configuration: n.object,
25
+ model: n.object,
26
+ onModelChanged: n.func,
27
+ onConfigurationChanged: n.func
28
+ };
29
+ onModelChanged = (e) => {
30
+ let { onModelChanged: t } = this.props;
31
+ return t(e);
32
+ };
33
+ onChangeRubricType = (e) => {
34
+ let { model: t } = this.props, n = e.target.value;
35
+ this.onModelChanged({
36
+ ...t,
37
+ rubricType: n
38
+ });
39
+ };
40
+ render() {
41
+ let { model: t, configuration: n, canUpdateModel: i } = this.props, { extraCSSRules: o, rubrics: s = {} } = t || {}, { rubricType: c } = t, { contentDimensions: m = {}, rubricOptions: h = [], multiTraitRubric: g, simpleRubric: _, rubricless: v, width: y } = n, b = "";
42
+ c ||= e.SIMPLE_RUBRIC;
43
+ let x = h.indexOf(c) > -1;
44
+ if (i) switch (c) {
45
+ case e.SIMPLE_RUBRIC:
46
+ default:
47
+ b = /* @__PURE__ */ l("rubric-configure", {
48
+ id: "simpleRubric",
49
+ ref: (e) => {
50
+ e && (this.simpleRubric = e, this.simpleRubric.model = {
51
+ ...s.simpleRubric,
52
+ errors: t.errors || {}
53
+ }, this.simpleRubric.configuration = {
54
+ ..._,
55
+ width: y
56
+ });
57
+ }
58
+ }, "simple-rubric");
59
+ break;
60
+ case e.MULTI_TRAIT_RUBRIC:
61
+ b = /* @__PURE__ */ l("multi-trait-rubric-configure", {
62
+ id: "multiTraitRubric",
63
+ ref: (e) => {
64
+ e && (this.multiTraitRubric = e, this.multiTraitRubric.model = {
65
+ ...s.multiTraitRubric,
66
+ errors: t.errors || {}
67
+ }, this.multiTraitRubric.configuration = {
68
+ ...g,
69
+ width: y || g.width
70
+ });
71
+ }
72
+ }, "multi-trait-rubric");
73
+ break;
74
+ case e.RUBRICLESS:
75
+ b = /* @__PURE__ */ l("rubric-configure", {
76
+ id: "rubricless",
77
+ ref: (e) => {
78
+ e && (this.rubricless = e, this.rubricless.model = s.rubricless, this.rubricless.configuration = {
79
+ ...v,
80
+ width: y
81
+ });
82
+ }
83
+ }, "rubricless");
84
+ break;
85
+ }
86
+ return /* @__PURE__ */ u(r.ConfigLayout, {
87
+ extraCSSRules: o,
88
+ dimensions: m,
89
+ hideSettings: !0,
90
+ settings: null,
91
+ children: [/* @__PURE__ */ l(a, {
92
+ "aria-label": "rubric-type",
93
+ name: "rubricType",
94
+ value: t.rubricType,
95
+ onChange: this.onChangeRubricType,
96
+ children: h.length > 1 && h.map((e, t) => /* @__PURE__ */ l(d, {
97
+ value: e,
98
+ control: /* @__PURE__ */ l(f, { checked: c === e }),
99
+ label: p[e]
100
+ }, t))
101
+ }), x && b]
102
+ });
103
+ }
104
+ };
105
+ //#endregion
106
+ export { m as default };