@pie-element/match 4.9.8 → 4.10.1-beta.1443
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.
- package/CHANGELOG.md +362 -0
- package/configure/CHANGELOG.md +339 -0
- package/configure/lib/add-row.js.map +1 -1
- package/configure/lib/answer-config-block.js +76 -65
- package/configure/lib/answer-config-block.js.map +1 -1
- package/configure/lib/configure.js +88 -45
- package/configure/lib/configure.js.map +1 -1
- package/configure/lib/defaults.js +29 -1
- package/configure/lib/defaults.js.map +1 -1
- package/configure/lib/general-config-block.js +51 -7
- package/configure/lib/general-config-block.js.map +1 -1
- package/configure/lib/index.js +16 -2
- package/configure/lib/index.js.map +1 -1
- package/configure/lib/row.js +69 -60
- package/configure/lib/row.js.map +1 -1
- package/configure/package.json +7 -7
- package/configure/utils.js +12 -0
- package/controller/CHANGELOG.md +60 -0
- package/controller/lib/defaults.js.map +1 -1
- package/controller/lib/index.js +112 -5
- package/controller/lib/index.js.map +1 -1
- package/controller/package.json +3 -3
- package/docs/config-schema.json +153 -0
- package/docs/config-schema.json.md +117 -1
- package/docs/demo/config.js +2 -2
- package/docs/demo/generate.js +11 -10
- package/docs/pie-schema.json +38 -0
- package/docs/pie-schema.json.md +28 -0
- package/lib/answer-grid.js +2 -2
- package/lib/answer-grid.js.map +1 -1
- package/lib/index.js +4 -1
- package/lib/index.js.map +1 -1
- package/lib/main.js +2 -2
- package/lib/main.js.map +1 -1
- package/package.json +5 -5
package/configure/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,345 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [5.5.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.4.0...@pie-element/match-configure@5.5.0) (2023-01-17)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* update pie-libs ([6423903](https://github.com/pie-framework/pie-elements/commit/6423903898b041f56db2111de2e4aac4ee9f1fd3))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# [5.4.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.3.1...@pie-element/match-configure@5.4.0) (2023-01-05)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Bug Fixes
|
|
21
|
+
|
|
22
|
+
* **match:** increase default value of maxLengthQuestionsHeading, maxLengthAnswers, maxLengthFirstColumnHeading ([f663d9d](https://github.com/pie-framework/pie-elements/commit/f663d9daba7998e26d5d8c1849c219d284e2d4bf))
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Features
|
|
26
|
+
|
|
27
|
+
* added width property in match configuration ([6436fc6](https://github.com/pie-framework/pie-elements/commit/6436fc63b404dc4d25ac55aadcc5b84985421800))
|
|
28
|
+
* PD-2417 wip ([01dc129](https://github.com/pie-framework/pie-elements/commit/01dc129e1cda7e1a4bc27a3b874c56c20ff92618))
|
|
29
|
+
* update pie-libs ([b174476](https://github.com/pie-framework/pie-elements/commit/b174476729119a0689f1f8adfc8c235246676cab))
|
|
30
|
+
* update pie-libs ([f72c3c8](https://github.com/pie-framework/pie-elements/commit/f72c3c8d8bc9bbf061bb81502317157a63c22972))
|
|
31
|
+
* update pie-libs ([8490729](https://github.com/pie-framework/pie-elements/commit/8490729a2389d36fd3968f0806119fde96577842))
|
|
32
|
+
* **match:** add validation PD-2417 ([157c19b](https://github.com/pie-framework/pie-elements/commit/157c19b4ceee5decfd47c50e23a7004d27136ca0))
|
|
33
|
+
* **match:** added configuration prop to hide the settings panel PD-1999 + refactoring ([b7087c6](https://github.com/pie-framework/pie-elements/commit/b7087c652df0172ee0f3a1d4041e4c1b144bafa0))
|
|
34
|
+
* **match:** added some configurable validation PD-2417. Started to update validation method ([dc459a1](https://github.com/pie-framework/pie-elements/commit/dc459a140a54772e6d9ec5dfaa1c620215cdf4c2))
|
|
35
|
+
* **match:** clean up ([40809d9](https://github.com/pie-framework/pie-elements/commit/40809d9a29baeba7f50f4f5510a0e18537224930))
|
|
36
|
+
* **match:** wip add validation PD-2417 ([f8a4b88](https://github.com/pie-framework/pie-elements/commit/f8a4b886ee42125ff2cef4abc0e29c8132010a98))
|
|
37
|
+
* **match:** wip PD-2417 ([6d392f7](https://github.com/pie-framework/pie-elements/commit/6d392f76efbbefa2ef71b439dd5123d6a8c31974))
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
## [5.3.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.3.0...@pie-element/match-configure@5.3.1) (2022-12-21)
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
### Bug Fixes
|
|
47
|
+
|
|
48
|
+
* updated pie-libs ([8cb5b90](https://github.com/pie-framework/pie-elements/commit/8cb5b90d501ccbdf5ffd764e6555faa48b8f54d6))
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
# [5.3.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.2.4...@pie-element/match-configure@5.3.0) (2022-12-20)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
### Bug Fixes
|
|
58
|
+
|
|
59
|
+
* updated pie-libs ([6549302](https://github.com/pie-framework/pie-elements/commit/65493026fbf356c5ab752ae6a14d961d4b256368))
|
|
60
|
+
* **match:** remove unnessesary prop that causes performance issues PD-2412 ([d27bc44](https://github.com/pie-framework/pie-elements/commit/d27bc44bbf7f6b55eefc525d6ab1afb1425f7b2d))
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
### Features
|
|
64
|
+
|
|
65
|
+
* **match:** reduce the width of the input widgets for selecting the number of columns & the response type ([c176761](https://github.com/pie-framework/pie-elements/commit/c17676155ae0e9f4c98b1374401a9900e589e2ed))
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
## [5.2.4](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.2.3...@pie-element/match-configure@5.2.4) (2022-12-07)
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
### Bug Fixes
|
|
75
|
+
|
|
76
|
+
* update libs ([441f403](https://github.com/pie-framework/pie-elements/commit/441f403870b7bec0d61fab58b8d93dbe0ead4c32))
|
|
77
|
+
* update libs for PD-2030 PD-2031 ([3174022](https://github.com/pie-framework/pie-elements/commit/3174022d45603ed217bbe8804a142b07084636a5))
|
|
78
|
+
* updated lib PD-1715 ([42e788d](https://github.com/pie-framework/pie-elements/commit/42e788db0c792838994e55001952da7701251a8e))
|
|
79
|
+
* updated libs ([c20de3a](https://github.com/pie-framework/pie-elements/commit/c20de3a6ba4499a090c809e18e52588d2a585fa0))
|
|
80
|
+
* updated libs ([0eed79a](https://github.com/pie-framework/pie-elements/commit/0eed79a32c3b777c16c8cabf201513fc1d2726a0))
|
|
81
|
+
* updated libs ([343c9ec](https://github.com/pie-framework/pie-elements/commit/343c9ec3dccba7f781e90ae2bd195cac6f78f467))
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
## [5.2.3](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.2.2...@pie-element/match-configure@5.2.3) (2022-11-15)
|
|
88
|
+
|
|
89
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
## [5.2.2](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.2.1...@pie-element/match-configure@5.2.2) (2022-11-11)
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
### Bug Fixes
|
|
99
|
+
|
|
100
|
+
* **match:** add sanity checks for withRubric ([0b4226d](https://github.com/pie-framework/pie-elements/commit/0b4226d1fdf898c5aafd567b8fd01ed3fbe7d2e7))
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
## [5.2.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.2.0...@pie-element/match-configure@5.2.1) (2022-10-31)
|
|
107
|
+
|
|
108
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
# [5.2.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.9...@pie-element/match-configure@5.2.0) (2022-10-17)
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
### Features
|
|
118
|
+
|
|
119
|
+
* enable spanish and special characters in author PD-2120 ([85fd3dd](https://github.com/pie-framework/pie-elements/commit/85fd3dd0fc10da1a2dfd5a842809c625790f8ba9))
|
|
120
|
+
* set withRubric to false in item default configurations. Set rubricEnabled to true if it's enabled for drawing-response and extended-text-entry ([a209057](https://github.com/pie-framework/pie-elements/commit/a209057f5a3fa5438efc8595453c89c11959a8f5))
|
|
121
|
+
* update libs ([7e174fb](https://github.com/pie-framework/pie-elements/commit/7e174fba75e7ea668900ad5c103751cefe33e2af))
|
|
122
|
+
* **match:** add pie-api config PD-23 ([ac5ccb9](https://github.com/pie-framework/pie-elements/commit/ac5ccb90252590e4af2a2a65913800e86d95c467))
|
|
123
|
+
* **match:** add settings to enable rubric. Add withRubric prop to configuration and rubricEnabled prop to model PD-2102 ([b0e09f9](https://github.com/pie-framework/pie-elements/commit/b0e09f94e582d6e9c18b1c34dd5517e907f0078d))
|
|
124
|
+
* **match:** add uploadSoundSupport property PD-23-updated ([7bbc65f](https://github.com/pie-framework/pie-elements/commit/7bbc65f63df9d247b870e0c948024ded87493c2c))
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
## [5.1.9](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.8...@pie-element/match-configure@5.1.9) (2022-09-29)
|
|
131
|
+
|
|
132
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
## [5.1.8](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.7...@pie-element/match-configure@5.1.8) (2022-09-14)
|
|
139
|
+
|
|
140
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
141
|
+
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
## [5.1.7](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.6...@pie-element/match-configure@5.1.7) (2022-08-31)
|
|
147
|
+
|
|
148
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
|
|
153
|
+
|
|
154
|
+
## [5.1.6](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.5...@pie-element/match-configure@5.1.6) (2022-08-16)
|
|
155
|
+
|
|
156
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
## [5.1.5](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.4...@pie-element/match-configure@5.1.5) (2022-08-08)
|
|
163
|
+
|
|
164
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
165
|
+
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
## [5.1.4](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.3...@pie-element/match-configure@5.1.4) (2022-08-02)
|
|
171
|
+
|
|
172
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
## [5.1.3](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.2...@pie-element/match-configure@5.1.3) (2022-07-22)
|
|
179
|
+
|
|
180
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
## [5.1.2](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.1...@pie-element/match-configure@5.1.2) (2022-07-20)
|
|
187
|
+
|
|
188
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
## [5.1.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.1.0...@pie-element/match-configure@5.1.1) (2022-07-19)
|
|
195
|
+
|
|
196
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
|
|
202
|
+
# [5.1.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@5.0.0...@pie-element/match-configure@5.1.0) (2022-06-28)
|
|
203
|
+
|
|
204
|
+
|
|
205
|
+
### Features
|
|
206
|
+
|
|
207
|
+
* **match:** add maxImageWidth and maxImageHeight props PD-1801 ([d98c0db](https://github.com/pie-framework/pie-elements/commit/d98c0dbe6a7acb5d115a71a102553cd20b5a63d5))
|
|
208
|
+
* **match:** implement validation ui/ux PD-1711 ([85cdff1](https://github.com/pie-framework/pie-elements/commit/85cdff133bb3373c33733b0e627241bf6880a738))
|
|
209
|
+
|
|
210
|
+
|
|
211
|
+
|
|
212
|
+
|
|
213
|
+
|
|
214
|
+
# [5.0.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.12...@pie-element/match-configure@5.0.0) (2022-06-28)
|
|
215
|
+
|
|
216
|
+
|
|
217
|
+
### chore
|
|
218
|
+
|
|
219
|
+
* Merge master with develop. ([cdca48a](https://github.com/pie-framework/pie-elements/commit/cdca48abaa1d4179e4a961e13d171e14b7ed2444))
|
|
220
|
+
|
|
221
|
+
|
|
222
|
+
### BREAKING CHANGES
|
|
223
|
+
|
|
224
|
+
* Image percent buttons were removed from toolbar.
|
|
225
|
+
New properties maxImageWidth and maxImageHeight were added.
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
## [4.5.12](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.11...@pie-element/match-configure@4.5.12) (2022-06-13)
|
|
232
|
+
|
|
233
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
|
|
237
|
+
|
|
238
|
+
|
|
239
|
+
## [4.5.11](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.10...@pie-element/match-configure@4.5.11) (2022-05-30)
|
|
240
|
+
|
|
241
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
242
|
+
|
|
243
|
+
|
|
244
|
+
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
## [4.5.10](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.9...@pie-element/match-configure@4.5.10) (2022-05-16)
|
|
248
|
+
|
|
249
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
|
|
253
|
+
|
|
254
|
+
|
|
255
|
+
## [4.5.9](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.8...@pie-element/match-configure@4.5.9) (2022-05-09)
|
|
256
|
+
|
|
257
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
258
|
+
|
|
259
|
+
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
|
|
263
|
+
## [4.5.8](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.7...@pie-element/match-configure@4.5.8) (2022-05-03)
|
|
264
|
+
|
|
265
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
|
|
269
|
+
|
|
270
|
+
|
|
271
|
+
## [4.5.7](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.6...@pie-element/match-configure@4.5.7) (2022-04-12)
|
|
272
|
+
|
|
273
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
274
|
+
|
|
275
|
+
|
|
276
|
+
|
|
277
|
+
|
|
278
|
+
|
|
279
|
+
## [4.5.6](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.5...@pie-element/match-configure@4.5.6) (2022-03-28)
|
|
280
|
+
|
|
281
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
282
|
+
|
|
283
|
+
|
|
284
|
+
|
|
285
|
+
|
|
286
|
+
|
|
287
|
+
## [4.5.5](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.4...@pie-element/match-configure@4.5.5) (2022-03-22)
|
|
288
|
+
|
|
289
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
290
|
+
|
|
291
|
+
|
|
292
|
+
|
|
293
|
+
|
|
294
|
+
|
|
295
|
+
## [4.5.4](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.3...@pie-element/match-configure@4.5.4) (2022-03-08)
|
|
296
|
+
|
|
297
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
298
|
+
|
|
299
|
+
|
|
300
|
+
|
|
301
|
+
|
|
302
|
+
|
|
303
|
+
## [4.5.3](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.2...@pie-element/match-configure@4.5.3) (2022-03-08)
|
|
304
|
+
|
|
305
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
306
|
+
|
|
307
|
+
|
|
308
|
+
|
|
309
|
+
|
|
310
|
+
|
|
311
|
+
## [4.5.2](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.1...@pie-element/match-configure@4.5.2) (2022-02-21)
|
|
312
|
+
|
|
313
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
314
|
+
|
|
315
|
+
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
|
|
319
|
+
## [4.5.1](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.5.0...@pie-element/match-configure@4.5.1) (2022-02-04)
|
|
320
|
+
|
|
321
|
+
**Note:** Version bump only for package @pie-element/match-configure
|
|
322
|
+
|
|
323
|
+
|
|
324
|
+
|
|
325
|
+
|
|
326
|
+
|
|
327
|
+
# [4.5.0](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.4.8...@pie-element/match-configure@4.5.0) (2022-01-24)
|
|
328
|
+
|
|
329
|
+
|
|
330
|
+
### Bug Fixes
|
|
331
|
+
|
|
332
|
+
* match - after the player gives all the responses, feedback is 'you have not entered a response' PD-902 ([6bbcac9](https://github.com/pie-framework/pie-elements/commit/6bbcac9d4349e59b221471ea1b07957ea2c608e0))
|
|
333
|
+
* **match:** set default false for lock choice order settings PD-1333 ([4f07002](https://github.com/pie-framework/pie-elements/commit/4f07002ceece8b82450cc6fff13515923df370cc))
|
|
334
|
+
|
|
335
|
+
|
|
336
|
+
### Features
|
|
337
|
+
|
|
338
|
+
* **match:** change drag-and-drop behavior from swap to push PD-1336 ([0383630](https://github.com/pie-framework/pie-elements/commit/0383630ba588fed54aa9ff0b9a936f1c8d773eff))
|
|
339
|
+
* **match:** remove list buttons from question text PD-1335 ([671d0fb](https://github.com/pie-framework/pie-elements/commit/671d0fbbf79e343dc9a89dc6f820309edcccbaaf))
|
|
340
|
+
|
|
341
|
+
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
|
|
6
345
|
## [4.4.8](https://github.com/pie-framework/pie-elements/compare/@pie-element/match-configure@4.4.7...@pie-element/match-configure@4.4.8) (2022-01-10)
|
|
7
346
|
|
|
8
347
|
**Note:** Version bump only for package @pie-element/match-configure
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/add-row.jsx"],"names":["AddRowButton","props","classes","onAddClick","button","React","Component","PropTypes","object","isRequired","func","styles","theme","display","alignSelf","margin","marginBottom","spacing","unit"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;;;IAEaA,Y;;;;;;;;;;;;WAMX,kBAAS;AACP,wBAAgC,KAAKC,KAArC;AAAA,UAAQC,OAAR,eAAQA,OAAR;AAAA,UAAiBC,UAAjB,eAAiBA,UAAjB;AAEA,0BACE,gCAAC,kBAAD;AAAQ,QAAA,SAAS,EAAED,OAAO,CAACE,MAA3B;AAAmC,QAAA,QAAQ,EAAE,KAA7C;AAAoD,QAAA,OAAO,EAAED;AAA7D,sBACE,gCAAC,eAAD,OADF,oBADF;AAMD;;;EAf+BE,kBAAMC,S;;;iCAA3BN,Y,eACQ;AACjBE,EAAAA,OAAO,EAAEK,sBAAUC,MAAV,CAAiBC,UADT;AAEjBN,EAAAA,UAAU,EAAEI,sBAAUG,IAAV,CAAeD;AAFV,C;;AAiBrB,IAAME,MAAM,GAAG,SAATA,MAAS,
|
|
1
|
+
{"version":3,"sources":["../src/add-row.jsx"],"names":["AddRowButton","props","classes","onAddClick","button","React","Component","PropTypes","object","isRequired","func","styles","theme","display","alignSelf","margin","marginBottom","spacing","unit"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;;;IAEaA,Y;;;;;;;;;;;;WAMX,kBAAS;AACP,wBAAgC,KAAKC,KAArC;AAAA,UAAQC,OAAR,eAAQA,OAAR;AAAA,UAAiBC,UAAjB,eAAiBA,UAAjB;AAEA,0BACE,gCAAC,kBAAD;AAAQ,QAAA,SAAS,EAAED,OAAO,CAACE,MAA3B;AAAmC,QAAA,QAAQ,EAAE,KAA7C;AAAoD,QAAA,OAAO,EAAED;AAA7D,sBACE,gCAAC,eAAD,OADF,oBADF;AAMD;;;EAf+BE,kBAAMC,S;;;iCAA3BN,Y,eACQ;AACjBE,EAAAA,OAAO,EAAEK,sBAAUC,MAAV,CAAiBC,UADT;AAEjBN,EAAAA,UAAU,EAAEI,sBAAUG,IAAV,CAAeD;AAFV,C;;AAiBrB,IAAME,MAAM,GAAG,SAATA,MAAS,CAACC,KAAD;AAAA,SAAY;AACzBR,IAAAA,MAAM,EAAE;AACNS,MAAAA,OAAO,EAAE,MADH;AAENC,MAAAA,SAAS,EAAE,YAFL;AAGNC,MAAAA,MAAM,EAAE,CAHF;AAINC,MAAAA,YAAY,EAAEJ,KAAK,CAACK,OAAN,CAAcC,IAAd,GAAqB;AAJ7B;AADiB,GAAZ;AAAA,CAAf;;eASe,wBAAWP,MAAX,EAAmBX,YAAnB,C","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport Button from '@material-ui/core/Button';\nimport { withStyles } from '@material-ui/core/styles';\nimport AddButton from '@material-ui/icons/Add';\n\nexport class AddRowButton extends React.Component {\n static propTypes = {\n classes: PropTypes.object.isRequired,\n onAddClick: PropTypes.func.isRequired,\n };\n\n render() {\n const { classes, onAddClick } = this.props;\n\n return (\n <Button className={classes.button} disabled={false} onClick={onAddClick}>\n <AddButton />\n Add Another Row\n </Button>\n );\n }\n}\n\nconst styles = (theme) => ({\n button: {\n display: 'flex',\n alignSelf: 'flex-start',\n margin: 0,\n marginBottom: theme.spacing.unit * 2,\n },\n});\n\nexport default withStyles(styles)(AddRowButton);\n"],"file":"add-row.js"}
|
|
@@ -31,8 +31,6 @@ var _classnames = _interopRequireDefault(require("classnames"));
|
|
|
31
31
|
|
|
32
32
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
33
33
|
|
|
34
|
-
var _Button = _interopRequireDefault(require("@material-ui/core/Button"));
|
|
35
|
-
|
|
36
34
|
var _Typography = _interopRequireDefault(require("@material-ui/core/Typography"));
|
|
37
35
|
|
|
38
36
|
var _styles = require("@material-ui/core/styles");
|
|
@@ -47,15 +45,13 @@ var _lodash = _interopRequireDefault(require("lodash"));
|
|
|
47
45
|
|
|
48
46
|
var _editableHtml = _interopRequireWildcard(require("@pie-lib/editable-html"));
|
|
49
47
|
|
|
50
|
-
var _common = require("./common");
|
|
51
|
-
|
|
52
48
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
53
49
|
|
|
54
50
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
55
51
|
|
|
56
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
52
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
57
53
|
|
|
58
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
54
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
59
55
|
|
|
60
56
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2["default"])(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2["default"])(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2["default"])(this, result); }; }
|
|
61
57
|
|
|
@@ -71,29 +67,36 @@ var styles = function styles(theme) {
|
|
|
71
67
|
flexDirection: 'column'
|
|
72
68
|
},
|
|
73
69
|
rowContainer: {
|
|
74
|
-
marginTop: theme.spacing.unit * 2,
|
|
75
70
|
display: 'flex',
|
|
76
71
|
alignItems: 'center',
|
|
77
|
-
flex: 1
|
|
72
|
+
flex: 1,
|
|
73
|
+
width: 'fit-content',
|
|
74
|
+
borderBottom: '2px solid lightgray',
|
|
75
|
+
paddingBottom: theme.spacing.unit * 2,
|
|
76
|
+
marginTop: theme.spacing.unit * 2,
|
|
77
|
+
marginBottom: theme.spacing.unit
|
|
78
78
|
},
|
|
79
79
|
rowItem: {
|
|
80
80
|
flex: 1,
|
|
81
81
|
display: 'flex',
|
|
82
82
|
justifyContent: 'center',
|
|
83
|
+
flexDirection: 'column',
|
|
83
84
|
'&> div': {
|
|
84
85
|
width: '150px',
|
|
85
|
-
padding:
|
|
86
|
+
padding: "0 ".concat(theme.spacing.unit, "px"),
|
|
86
87
|
textAlign: 'center'
|
|
87
88
|
}
|
|
88
89
|
},
|
|
89
90
|
deleteIcon: {
|
|
90
91
|
flex: 0.5,
|
|
91
|
-
minWidth: '
|
|
92
|
+
minWidth: '48px',
|
|
93
|
+
padding: "0 ".concat(theme.spacing.unit, "px")
|
|
92
94
|
},
|
|
93
95
|
questionText: {
|
|
94
96
|
flex: 2,
|
|
95
97
|
display: 'flex',
|
|
96
98
|
justifyContent: 'flex-start',
|
|
99
|
+
marginRight: theme.spacing.unit,
|
|
97
100
|
'&> div': {
|
|
98
101
|
width: '100%',
|
|
99
102
|
padding: 0,
|
|
@@ -106,16 +109,16 @@ var styles = function styles(theme) {
|
|
|
106
109
|
display: 'flex',
|
|
107
110
|
flexDirection: 'column'
|
|
108
111
|
},
|
|
109
|
-
separator: {
|
|
110
|
-
marginTop: theme.spacing.unit * 2,
|
|
111
|
-
border: 0,
|
|
112
|
-
borderTop: '2px solid lightgray',
|
|
113
|
-
width: '100%'
|
|
114
|
-
},
|
|
115
112
|
headerInput: {
|
|
116
113
|
'&> div': {
|
|
117
114
|
fontWeight: 'bold'
|
|
118
115
|
}
|
|
116
|
+
},
|
|
117
|
+
errorText: {
|
|
118
|
+
fontSize: theme.typography.fontSize - 2,
|
|
119
|
+
color: 'red',
|
|
120
|
+
paddingTop: "".concat(theme.spacing.unit, "px !important"),
|
|
121
|
+
width: 'fit-content !important'
|
|
119
122
|
}
|
|
120
123
|
};
|
|
121
124
|
};
|
|
@@ -135,11 +138,6 @@ var AnswerConfigBlock = /*#__PURE__*/function (_React$Component) {
|
|
|
135
138
|
}
|
|
136
139
|
|
|
137
140
|
_this = _super.call.apply(_super, [this].concat(args));
|
|
138
|
-
(0, _defineProperty2["default"])((0, _assertThisInitialized2["default"])(_this), "state", {
|
|
139
|
-
dialog: {
|
|
140
|
-
open: false
|
|
141
|
-
}
|
|
142
|
-
});
|
|
143
141
|
(0, _defineProperty2["default"])((0, _assertThisInitialized2["default"])(_this), "moveRow", function (from, to) {
|
|
144
142
|
var _this$props = _this.props,
|
|
145
143
|
model = _this$props.model,
|
|
@@ -203,32 +201,8 @@ var AnswerConfigBlock = /*#__PURE__*/function (_React$Component) {
|
|
|
203
201
|
return;
|
|
204
202
|
}
|
|
205
203
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
var sameValue = headers.filter(function (header) {
|
|
209
|
-
var wasChanged = currentHeader !== value && "<div>".concat(currentHeader, "</div>") !== value;
|
|
210
|
-
var sameValueEntered = header === value || "<div>".concat(header, "</div>") === value;
|
|
211
|
-
return wasChanged && sameValueEntered;
|
|
212
|
-
});
|
|
213
|
-
var empty = value === '<div></div>';
|
|
214
|
-
|
|
215
|
-
if (sameValue.length || empty) {
|
|
216
|
-
_this.setState({
|
|
217
|
-
dialog: {
|
|
218
|
-
open: true,
|
|
219
|
-
onOk: function onOk() {
|
|
220
|
-
_this.setState({
|
|
221
|
-
dialog: {
|
|
222
|
-
open: false
|
|
223
|
-
}
|
|
224
|
-
});
|
|
225
|
-
}
|
|
226
|
-
}
|
|
227
|
-
});
|
|
228
|
-
} else {
|
|
229
|
-
newModel.headers[headerIndex] = value;
|
|
230
|
-
onChange(newModel);
|
|
231
|
-
}
|
|
204
|
+
newModel.headers[headerIndex] = value;
|
|
205
|
+
onChange(newModel);
|
|
232
206
|
};
|
|
233
207
|
});
|
|
234
208
|
return _this;
|
|
@@ -245,13 +219,28 @@ var AnswerConfigBlock = /*#__PURE__*/function (_React$Component) {
|
|
|
245
219
|
onAddRow = _this$props4.onAddRow,
|
|
246
220
|
imageSupport = _this$props4.imageSupport,
|
|
247
221
|
configuration = _this$props4.configuration,
|
|
248
|
-
toolbarOpts = _this$props4.toolbarOpts
|
|
222
|
+
toolbarOpts = _this$props4.toolbarOpts,
|
|
223
|
+
spellCheck = _this$props4.spellCheck,
|
|
224
|
+
uploadSoundSupport = _this$props4.uploadSoundSupport;
|
|
249
225
|
|
|
250
226
|
var _ref2 = configuration || {},
|
|
251
227
|
_ref2$headers = _ref2.headers,
|
|
252
|
-
headers = _ref2$headers === void 0 ? {} : _ref2$headers
|
|
228
|
+
headers = _ref2$headers === void 0 ? {} : _ref2$headers,
|
|
229
|
+
_ref2$maxImageWidth = _ref2.maxImageWidth,
|
|
230
|
+
maxImageWidth = _ref2$maxImageWidth === void 0 ? {} : _ref2$maxImageWidth,
|
|
231
|
+
_ref2$maxImageHeight = _ref2.maxImageHeight,
|
|
232
|
+
maxImageHeight = _ref2$maxImageHeight === void 0 ? {} : _ref2$maxImageHeight;
|
|
233
|
+
|
|
234
|
+
var _ref3 = model || {},
|
|
235
|
+
errors = _ref3.errors;
|
|
236
|
+
|
|
237
|
+
var _ref4 = errors || {},
|
|
238
|
+
correctResponseError = _ref4.correctResponseError,
|
|
239
|
+
rowsErrors = _ref4.rowsErrors,
|
|
240
|
+
columnsErrors = _ref4.columnsErrors,
|
|
241
|
+
noOfRowsError = _ref4.noOfRowsError,
|
|
242
|
+
columnsLengthError = _ref4.columnsLengthError;
|
|
253
243
|
|
|
254
|
-
var dialog = this.state.dialog;
|
|
255
244
|
var filteredDefaultPlugins = (_editableHtml.DEFAULT_PLUGINS || []).filter(function (p) {
|
|
256
245
|
return p !== 'table' && p !== 'bulleted-list' && p !== 'numbered-list';
|
|
257
246
|
});
|
|
@@ -263,13 +252,25 @@ var AnswerConfigBlock = /*#__PURE__*/function (_React$Component) {
|
|
|
263
252
|
disabled: true
|
|
264
253
|
}
|
|
265
254
|
};
|
|
255
|
+
var defaultImageMaxWidth = maxImageWidth && maxImageWidth.prompt;
|
|
256
|
+
var defaultImageMaxHeight = maxImageHeight && maxImageHeight.prompt;
|
|
266
257
|
return /*#__PURE__*/React.createElement("div", {
|
|
267
258
|
className: classes.container
|
|
268
259
|
}, /*#__PURE__*/React.createElement(_Typography["default"], {
|
|
269
260
|
type: "body1",
|
|
270
261
|
component: "div"
|
|
271
|
-
}, "Click on the labels to edit or remove. Set the correct answers by clicking each correct answer per row."), /*#__PURE__*/React.createElement("div", {
|
|
272
|
-
className: classes.
|
|
262
|
+
}, "Click on the labels to edit or remove. Set the correct answers by clicking each correct answer per row."), correctResponseError && /*#__PURE__*/React.createElement("div", {
|
|
263
|
+
className: classes.errorText
|
|
264
|
+
}, correctResponseError), noOfRowsError && /*#__PURE__*/React.createElement("div", {
|
|
265
|
+
className: classes.errorText
|
|
266
|
+
}, noOfRowsError), columnsLengthError && /*#__PURE__*/React.createElement("div", {
|
|
267
|
+
className: classes.errorText
|
|
268
|
+
}, columnsLengthError), /*#__PURE__*/React.createElement("div", {
|
|
269
|
+
className: classes.rowTable,
|
|
270
|
+
style: configuration.width ? {
|
|
271
|
+
width: configuration.width,
|
|
272
|
+
overflow: 'scroll'
|
|
273
|
+
} : {}
|
|
273
274
|
}, /*#__PURE__*/React.createElement("div", {
|
|
274
275
|
className: classes.rowContainer
|
|
275
276
|
}, headers.settings && (model.headers || []).map(function (header, idx) {
|
|
@@ -284,15 +285,20 @@ var AnswerConfigBlock = /*#__PURE__*/function (_React$Component) {
|
|
|
284
285
|
activePlugins: filteredDefaultPlugins,
|
|
285
286
|
pluginProps: labelPlugins,
|
|
286
287
|
autoWidthToolbar: true,
|
|
287
|
-
|
|
288
|
-
|
|
288
|
+
spellCheck: spellCheck,
|
|
289
|
+
uploadSoundSupport: uploadSoundSupport,
|
|
290
|
+
languageCharactersProps: [{
|
|
291
|
+
language: 'spanish'
|
|
292
|
+
}, {
|
|
293
|
+
language: 'special'
|
|
294
|
+
}],
|
|
295
|
+
error: columnsErrors && columnsErrors[idx]
|
|
296
|
+
}), columnsErrors && columnsErrors[idx] && /*#__PURE__*/React.createElement("div", {
|
|
297
|
+
className: classes.errorText
|
|
298
|
+
}, columnsErrors[idx]));
|
|
289
299
|
}), /*#__PURE__*/React.createElement("div", {
|
|
290
300
|
className: classes.deleteIcon
|
|
291
|
-
},
|
|
292
|
-
disabled: true
|
|
293
|
-
}, /*#__PURE__*/React.createElement("div", null)))), /*#__PURE__*/React.createElement("hr", {
|
|
294
|
-
className: classes.separator
|
|
295
|
-
}), model.rows.map(function (row, idx) {
|
|
301
|
+
})), model.rows.map(function (row, idx) {
|
|
296
302
|
return /*#__PURE__*/React.createElement(_row["default"], {
|
|
297
303
|
key: idx,
|
|
298
304
|
model: model,
|
|
@@ -303,15 +309,16 @@ var AnswerConfigBlock = /*#__PURE__*/function (_React$Component) {
|
|
|
303
309
|
onMoveRow: _this2.moveRow,
|
|
304
310
|
imageSupport: imageSupport,
|
|
305
311
|
enableImages: model.enableImages,
|
|
306
|
-
toolbarOpts: toolbarOpts
|
|
312
|
+
toolbarOpts: toolbarOpts,
|
|
313
|
+
spellCheck: spellCheck,
|
|
314
|
+
error: rowsErrors === null || rowsErrors === void 0 ? void 0 : rowsErrors[row.id],
|
|
315
|
+
maxImageWidth: maxImageWidth && maxImageWidth.rowTitles || defaultImageMaxWidth,
|
|
316
|
+
maxImageHeight: maxImageHeight && maxImageHeight.rowTitles || defaultImageMaxHeight,
|
|
317
|
+
uploadSoundSupport: uploadSoundSupport
|
|
307
318
|
});
|
|
308
319
|
}), /*#__PURE__*/React.createElement(_addRow["default"], {
|
|
309
320
|
onAddClick: onAddRow
|
|
310
|
-
}))
|
|
311
|
-
title: 'The column headings must be non-blank and unique.',
|
|
312
|
-
open: dialog.open,
|
|
313
|
-
onOk: dialog.onOk
|
|
314
|
-
}));
|
|
321
|
+
})));
|
|
315
322
|
}
|
|
316
323
|
}]);
|
|
317
324
|
return AnswerConfigBlock;
|
|
@@ -328,6 +335,10 @@ var AnswerConfigBlock = /*#__PURE__*/function (_React$Component) {
|
|
|
328
335
|
add: _propTypes["default"].func.isRequired,
|
|
329
336
|
"delete": _propTypes["default"].func.isRequired
|
|
330
337
|
}),
|
|
338
|
+
uploadSoundSupport: _propTypes["default"].shape({
|
|
339
|
+
add: _propTypes["default"].func.isRequired,
|
|
340
|
+
"delete": _propTypes["default"].func.isRequired
|
|
341
|
+
}),
|
|
331
342
|
toolbarOpts: _propTypes["default"].object
|
|
332
343
|
});
|
|
333
344
|
|