@sparkle-learning/core 0.0.53 → 0.0.55

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 (177) hide show
  1. package/dist/cjs/{PrivateRoute-074c584e.js → PrivateRoute-f97245ce.js} +18 -30
  2. package/dist/cjs/{feed.service-b4f09441.js → appdata.service-c8d71e05.js} +4 -56
  3. package/dist/cjs/{assets.service-0c759d51.js → assets.service-bfa75092.js} +1 -1
  4. package/dist/cjs/assignment.service-690fb59c.js +19 -0
  5. package/dist/cjs/{environment-config.service-0e02b049.js → environment-config.service-c8ff1f3d.js} +0 -1
  6. package/dist/cjs/{facilitator.service-9e990274.js → facilitator.service-ff0e1659.js} +1 -1
  7. package/dist/cjs/feed.service-8eca4de6.js +57 -0
  8. package/dist/cjs/header-mobile-collapse_61.cjs.entry.js +76 -87
  9. package/dist/cjs/{httpService-7211d93b.js → httpService-d2e7bf8f.js} +13 -11
  10. package/dist/cjs/index.cjs.js +5 -4
  11. package/dist/cjs/{ion-action-sheet_4.cjs.entry.js → ion-action-sheet_7.cjs.entry.js} +728 -0
  12. package/dist/cjs/loader.cjs.js +1 -1
  13. package/dist/cjs/media.service-8a1b9bc5.js +40 -0
  14. package/dist/cjs/{signalR.service-5672eebc.js → signalR.service-bd6b42f9.js} +18 -20
  15. package/dist/cjs/sparkle-animation-player.cjs.entry.js +1 -1
  16. package/dist/cjs/sparkle-assignment.cjs.entry.js +110 -0
  17. package/dist/cjs/sparkle-character-intro.cjs.entry.js +2 -2
  18. package/dist/cjs/sparkle-core.cjs.js +1 -1
  19. package/dist/cjs/sparkle-discussion-questions_2.cjs.entry.js +20 -11
  20. package/dist/cjs/sparkle-discussion.cjs.entry.js +6 -4
  21. package/dist/cjs/sparkle-facilitator-notes-form.cjs.entry.js +5 -3
  22. package/dist/cjs/sparkle-feed-post.cjs.entry.js +116 -0
  23. package/dist/cjs/sparkle-feedback.cjs.entry.js +5 -3
  24. package/dist/cjs/sparkle-file-upload.cjs.entry.js +53 -0
  25. package/dist/cjs/sparkle-goal-form.cjs.entry.js +11 -8
  26. package/dist/cjs/sparkle-input.cjs.entry.js +56 -0
  27. package/dist/cjs/sparkle-quiz-container.cjs.entry.js +1 -1
  28. package/dist/cjs/sparkle-quiz-old.cjs.entry.js +120 -0
  29. package/dist/cjs/sparkle-quiz.cjs.entry.js +31 -48
  30. package/dist/cjs/{student.service-2e58f237.js → student.service-7e5385be.js} +1 -1
  31. package/dist/cjs/token.service-7a41953d.js +97 -0
  32. package/dist/cjs/{util-d383acb8.js → util-47e320b2.js} +2 -2
  33. package/dist/collection/PrivateRoute.js +2 -2
  34. package/dist/collection/collection-manifest.json +5 -2
  35. package/dist/collection/components/layout/facilitator/facilitator-page.js +2 -3
  36. package/dist/collection/components/layout/page/page.css +4 -0
  37. package/dist/collection/components/layout/page/page.js +39 -26
  38. package/dist/collection/components/sparkle-assignment/sparkle-assignment.css +30 -0
  39. package/dist/collection/components/sparkle-assignment/sparkle-assignment.js +159 -0
  40. package/dist/collection/components/sparkle-character-intro/sparkle-character-intro.css +8 -1
  41. package/dist/collection/components/sparkle-character-intro/sparkle-character-intro.js +10 -6
  42. package/dist/collection/components/sparkle-course-root/sparkle-course-root.js +13 -2
  43. package/dist/collection/components/sparkle-discussion/sparkle-discussion-questions/sparkle-discussion-questions.js +4 -2
  44. package/dist/collection/components/sparkle-discussion/sparkle-discussion-results/sparkle-discussion-results.js +15 -9
  45. package/dist/collection/components/sparkle-discussion/sparkle-discussion.css +5 -0
  46. package/dist/collection/components/sparkle-discussion/sparkle-discussion.js +5 -3
  47. package/dist/collection/components/sparkle-feed-post/sparkle-feed-post.js +54 -75
  48. package/dist/collection/components/sparkle-file-upload/sparkle-file-upload.css +0 -0
  49. package/dist/collection/components/sparkle-file-upload/sparkle-file-upload.js +105 -0
  50. package/dist/collection/components/sparkle-input/sparkle-input.css +0 -0
  51. package/dist/collection/components/sparkle-input/sparkle-input.js +212 -0
  52. package/dist/collection/components/sparkle-login/sparkle-login.js +2 -1
  53. package/dist/collection/components/sparkle-quiz/{sparkle-quiz/sparkle-quiz.css → sparkle-quiz-old/sparkle-quiz-old.css} +1 -1
  54. package/dist/collection/components/sparkle-quiz/{sparkle-quiz/sparkle-quiz.js → sparkle-quiz-old/sparkle-quiz-old.js} +4 -4
  55. package/dist/collection/components/sparkle-quiz/{sparkle-quiz-v1.js → sparkle-quiz.js} +23 -25
  56. package/dist/collection/components/sparkle-quiz-container/sparkle-quiz-container.js +1 -1
  57. package/dist/collection/components/sparkle-root/sparkle-root.js +12 -10
  58. package/dist/collection/services/assignment.service.js +14 -0
  59. package/dist/collection/services/auth/auth.service.js +15 -14
  60. package/dist/collection/services/environment/environment-config.js +1 -1
  61. package/dist/collection/services/environment/environment-config.service.js +0 -1
  62. package/dist/collection/services/httpService.js +12 -10
  63. package/dist/collection/services/signalR.service.js +17 -19
  64. package/dist/collection/services/token.service.js +79 -0
  65. package/dist/collection/util.js +5 -2
  66. package/dist/esm/{PrivateRoute-c5441f35.js → PrivateRoute-90ac95b8.js} +17 -29
  67. package/dist/esm/{feed.service-8fbe4ce3.js → appdata.service-2e84e167.js} +5 -55
  68. package/dist/esm/{assets.service-66e848b8.js → assets.service-def1d63c.js} +1 -1
  69. package/dist/esm/assignment.service-8d31f141.js +17 -0
  70. package/dist/esm/{environment-config.service-2b5d692b.js → environment-config.service-b191f276.js} +0 -1
  71. package/dist/esm/{facilitator.service-b0292f7f.js → facilitator.service-18c47bdf.js} +1 -1
  72. package/dist/esm/feed.service-b4f3cae4.js +54 -0
  73. package/dist/esm/header-mobile-collapse_61.entry.js +71 -82
  74. package/dist/esm/{httpService-7b75b095.js → httpService-7986aeed.js} +14 -12
  75. package/dist/esm/index.js +6 -5
  76. package/dist/esm/{ion-action-sheet_4.entry.js → ion-action-sheet_7.entry.js} +729 -4
  77. package/dist/esm/ion-loading.entry.js +1 -1
  78. package/dist/esm/ion-menu.entry.js +1 -1
  79. package/dist/esm/ion-modal.entry.js +1 -1
  80. package/dist/esm/ion-picker.entry.js +1 -1
  81. package/dist/esm/ion-toast.entry.js +1 -1
  82. package/dist/esm/loader.js +1 -1
  83. package/dist/esm/media.service-6e90bc41.js +37 -0
  84. package/dist/esm/{overlays-3b4dca92.js → overlays-4233a39d.js} +1 -1
  85. package/dist/esm/{signalR.service-9d5b9f36.js → signalR.service-c33fba50.js} +18 -20
  86. package/dist/esm/sparkle-animation-player.entry.js +1 -1
  87. package/dist/esm/sparkle-assignment.entry.js +106 -0
  88. package/dist/esm/sparkle-character-intro.entry.js +3 -3
  89. package/dist/esm/sparkle-core.js +1 -1
  90. package/dist/esm/sparkle-discussion-questions_2.entry.js +20 -11
  91. package/dist/esm/sparkle-discussion.entry.js +6 -4
  92. package/dist/esm/sparkle-facilitator-notes-form.entry.js +6 -4
  93. package/dist/esm/sparkle-feed-post.entry.js +112 -0
  94. package/dist/esm/sparkle-feedback.entry.js +6 -4
  95. package/dist/esm/sparkle-file-upload.entry.js +49 -0
  96. package/dist/esm/sparkle-goal-form.entry.js +9 -6
  97. package/dist/esm/sparkle-input.entry.js +52 -0
  98. package/dist/esm/sparkle-quiz-container.entry.js +1 -1
  99. package/dist/esm/sparkle-quiz-old.entry.js +116 -0
  100. package/dist/esm/sparkle-quiz.entry.js +31 -48
  101. package/dist/esm/{student.service-0746418b.js → student.service-08af124f.js} +1 -1
  102. package/dist/esm/token.service-71a5d33f.js +94 -0
  103. package/dist/esm/{util-6ef753e9.js → util-57cc8006.js} +2 -2
  104. package/dist/sparkle-core/index.esm.js +1 -1
  105. package/dist/sparkle-core/p-08420531.entry.js +1 -0
  106. package/dist/sparkle-core/p-08cca80d.entry.js +1 -0
  107. package/dist/sparkle-core/p-0e8e539f.entry.js +1 -0
  108. package/dist/sparkle-core/p-13ec39db.entry.js +1 -0
  109. package/dist/sparkle-core/p-1adc98f6.js +1 -0
  110. package/dist/sparkle-core/p-38c842d5.entry.js +1 -0
  111. package/dist/sparkle-core/{p-fbccd30c.js → p-39a31e43.js} +1 -1
  112. package/dist/sparkle-core/{p-0a5d7c4f.entry.js → p-3daf2915.entry.js} +26 -26
  113. package/dist/sparkle-core/{p-9a443f51.js → p-408176ba.js} +1 -1
  114. package/dist/sparkle-core/p-42ed7d5f.entry.js +1 -0
  115. package/dist/sparkle-core/p-4b4a8703.js +1 -0
  116. package/dist/sparkle-core/p-4d1cfcbe.entry.js +1 -0
  117. package/dist/sparkle-core/p-4fba3e4c.js +1 -0
  118. package/dist/sparkle-core/{p-54dd894f.entry.js → p-6bde0192.entry.js} +1 -1
  119. package/dist/sparkle-core/{p-6faa194c.entry.js → p-6d2f4093.entry.js} +1 -1
  120. package/dist/sparkle-core/{p-162bff1a.entry.js → p-72053ae0.entry.js} +1 -1
  121. package/dist/sparkle-core/p-7dae0f0e.js +1 -0
  122. package/dist/sparkle-core/{p-18cdd458.entry.js → p-85d4cd5c.entry.js} +1 -1
  123. package/dist/sparkle-core/p-973fe404.entry.js +22 -0
  124. package/dist/sparkle-core/{p-ff0e0d4e.entry.js → p-98daeddb.entry.js} +1 -1
  125. package/dist/sparkle-core/p-b06e2bef.js +1 -0
  126. package/dist/sparkle-core/{p-e863bf1d.entry.js → p-b6fec622.entry.js} +1 -1
  127. package/dist/sparkle-core/p-b8d71ff4.js +1 -0
  128. package/dist/sparkle-core/p-bd90903e.js +1 -0
  129. package/dist/sparkle-core/{p-a49ab4e8.entry.js → p-c64a34cd.entry.js} +1 -1
  130. package/dist/sparkle-core/{p-5efc6566.js → p-c9f753a4.js} +1 -1
  131. package/dist/sparkle-core/p-da391f3f.js +1 -0
  132. package/dist/sparkle-core/p-e0cad1bb.js +1 -0
  133. package/dist/sparkle-core/{p-ce4b22f7.entry.js → p-f196c124.entry.js} +1 -1
  134. package/dist/sparkle-core/p-f47fe1fe.entry.js +1 -0
  135. package/dist/sparkle-core/p-f714f77a.entry.js +1 -0
  136. package/dist/sparkle-core/p-f891c79a.entry.js +1 -0
  137. package/dist/sparkle-core/{p-377b04c2.entry.js → p-ff080f82.entry.js} +1 -1
  138. package/dist/sparkle-core/{p-2ff67662.js → p-ff7a8a71.js} +1 -1
  139. package/dist/sparkle-core/sparkle-core.esm.js +1 -1
  140. package/dist/types/components/layout/page/page.d.ts +2 -0
  141. package/dist/types/components/sparkle-assignment/sparkle-assignment.d.ts +16 -0
  142. package/dist/types/components/sparkle-course-root/sparkle-course-root.d.ts +1 -0
  143. package/dist/types/components/sparkle-feed-post/sparkle-feed-post.d.ts +4 -3
  144. package/dist/types/components/sparkle-file-upload/sparkle-file-upload.d.ts +15 -0
  145. package/dist/types/components/sparkle-input/sparkle-input.d.ts +23 -0
  146. package/dist/types/components/sparkle-quiz/{sparkle-quiz/sparkle-quiz.d.ts → sparkle-quiz-old/sparkle-quiz-old.d.ts} +1 -1
  147. package/dist/types/components/sparkle-quiz/{sparkle-quiz-v1.d.ts → sparkle-quiz.d.ts} +1 -1
  148. package/dist/types/components.d.ts +111 -36
  149. package/dist/types/models/class.model.d.ts +4 -0
  150. package/dist/types/services/assignment.service.d.ts +8 -0
  151. package/dist/types/services/auth/auth.service.d.ts +1 -1
  152. package/dist/types/services/environment/environment-config.d.ts +3 -0
  153. package/dist/types/services/token.service.d.ts +13 -0
  154. package/dist/types/util.d.ts +1 -0
  155. package/package.json +1 -1
  156. package/dist/cjs/ion-select_3.cjs.entry.js +0 -618
  157. package/dist/cjs/ion-textarea.cjs.entry.js +0 -248
  158. package/dist/cjs/sparkle-quiz-v1.cjs.entry.js +0 -105
  159. package/dist/esm/ion-select_3.entry.js +0 -612
  160. package/dist/esm/ion-textarea.entry.js +0 -244
  161. package/dist/esm/sparkle-quiz-v1.entry.js +0 -101
  162. package/dist/sparkle-core/p-0f1c5899.entry.js +0 -18
  163. package/dist/sparkle-core/p-1d4c7c11.js +0 -1
  164. package/dist/sparkle-core/p-30767c1c.entry.js +0 -1
  165. package/dist/sparkle-core/p-3265ed87.entry.js +0 -1
  166. package/dist/sparkle-core/p-370609ba.entry.js +0 -1
  167. package/dist/sparkle-core/p-44334ef3.entry.js +0 -4
  168. package/dist/sparkle-core/p-462bffba.js +0 -1
  169. package/dist/sparkle-core/p-4c9f994f.js +0 -1
  170. package/dist/sparkle-core/p-58e4bbe5.entry.js +0 -1
  171. package/dist/sparkle-core/p-600cf6a3.js +0 -1
  172. package/dist/sparkle-core/p-641bfc92.entry.js +0 -1
  173. package/dist/sparkle-core/p-80d6b0e6.entry.js +0 -1
  174. package/dist/sparkle-core/p-af3cc111.entry.js +0 -1
  175. package/dist/sparkle-core/p-b226f54d.js +0 -1
  176. /package/dist/collection/components/sparkle-quiz/{sparkle-quiz-v1.css → sparkle-quiz.css} +0 -0
  177. /package/dist/sparkle-core/{p-935e7cfc.js → p-8b56f734.js} +0 -0
@@ -23,6 +23,9 @@ export namespace Components {
23
23
  "playAnimation": () => Promise<void>;
24
24
  "src": string;
25
25
  }
26
+ interface SparkleAssignment {
27
+ "name": string;
28
+ }
26
29
  interface SparkleCharacterIntro {
27
30
  "character": string;
28
31
  "position": 'left' | 'right';
@@ -93,6 +96,10 @@ export namespace Components {
93
96
  }
94
97
  interface SparkleFeedback {
95
98
  }
99
+ interface SparkleFileUpload {
100
+ "name": string;
101
+ "value": string;
102
+ }
96
103
  interface SparkleForgotPassword {
97
104
  "history": RouterHistory;
98
105
  }
@@ -123,6 +130,15 @@ export namespace Components {
123
130
  interface SparkleHealth {
124
131
  "history": RouterHistory;
125
132
  }
133
+ interface SparkleInput {
134
+ "checked": boolean;
135
+ "label": string;
136
+ "name": string;
137
+ "options": { value: string; label: string }[] | string;
138
+ "placeholder": string;
139
+ "type": 'text' | 'textarea' | 'checkbox' | 'select';
140
+ "value": string | boolean;
141
+ }
126
142
  interface SparkleIntro {
127
143
  }
128
144
  interface SparkleLogin {
@@ -151,14 +167,9 @@ export namespace Components {
151
167
  }
152
168
  interface SparkleQuiz {
153
169
  "correct": boolean;
154
- "feedback": string;
155
170
  "questionId": number;
156
- "questionText": string;
157
- "scale": 'FIVE-POINTS' | 'TEN-POINTS';
158
171
  "showInstantResult": boolean;
159
- "showOptionNumber": boolean;
160
172
  "submitted": boolean;
161
- "type": 'MULTIPLE-CHOICE' | 'TEXT' | 'FEEDBACK' | 'OPINION' | 'POLL';
162
173
  }
163
174
  interface SparkleQuizContainer {
164
175
  "questionIds": string;
@@ -170,6 +181,17 @@ export namespace Components {
170
181
  interface SparkleQuizInput {
171
182
  "question": SparkleQuizQuestion;
172
183
  }
184
+ interface SparkleQuizOld {
185
+ "correct": boolean;
186
+ "feedback": string;
187
+ "questionId": number;
188
+ "questionText": string;
189
+ "scale": 'FIVE-POINTS' | 'TEN-POINTS';
190
+ "showInstantResult": boolean;
191
+ "showOptionNumber": boolean;
192
+ "submitted": boolean;
193
+ "type": 'MULTIPLE-CHOICE' | 'TEXT' | 'FEEDBACK' | 'OPINION' | 'POLL';
194
+ }
173
195
  interface SparkleQuizOpinion {
174
196
  "question": SparkleQuizQuestion;
175
197
  }
@@ -180,12 +202,6 @@ export namespace Components {
180
202
  "allowMultiple": boolean;
181
203
  "question": SparkleQuizQuestion;
182
204
  }
183
- interface SparkleQuizV1 {
184
- "correct": boolean;
185
- "questionId": number;
186
- "showInstantResult": boolean;
187
- "submitted": boolean;
188
- }
189
205
  interface SparkleResetPassword {
190
206
  "history": RouterHistory;
191
207
  }
@@ -210,6 +226,10 @@ export namespace Components {
210
226
  "src": string;
211
227
  }
212
228
  }
229
+ export interface SparkleAssignmentCustomEvent<T> extends CustomEvent<T> {
230
+ detail: T;
231
+ target: HTMLSparkleAssignmentElement;
232
+ }
213
233
  export interface SparkleCourseRootCustomEvent<T> extends CustomEvent<T> {
214
234
  detail: T;
215
235
  target: HTMLSparkleCourseRootElement;
@@ -218,10 +238,18 @@ export interface SparkleFacilitatorPageCustomEvent<T> extends CustomEvent<T> {
218
238
  detail: T;
219
239
  target: HTMLSparkleFacilitatorPageElement;
220
240
  }
241
+ export interface SparkleFileUploadCustomEvent<T> extends CustomEvent<T> {
242
+ detail: T;
243
+ target: HTMLSparkleFileUploadElement;
244
+ }
221
245
  export interface SparkleGwwCustomEvent<T> extends CustomEvent<T> {
222
246
  detail: T;
223
247
  target: HTMLSparkleGwwElement;
224
248
  }
249
+ export interface SparkleInputCustomEvent<T> extends CustomEvent<T> {
250
+ detail: T;
251
+ target: HTMLSparkleInputElement;
252
+ }
225
253
  export interface SparkleLoginCustomEvent<T> extends CustomEvent<T> {
226
254
  detail: T;
227
255
  target: HTMLSparkleLoginElement;
@@ -242,6 +270,10 @@ export interface SparkleQuizInputCustomEvent<T> extends CustomEvent<T> {
242
270
  detail: T;
243
271
  target: HTMLSparkleQuizInputElement;
244
272
  }
273
+ export interface SparkleQuizOldCustomEvent<T> extends CustomEvent<T> {
274
+ detail: T;
275
+ target: HTMLSparkleQuizOldElement;
276
+ }
245
277
  export interface SparkleQuizOpinionCustomEvent<T> extends CustomEvent<T> {
246
278
  detail: T;
247
279
  target: HTMLSparkleQuizOpinionElement;
@@ -254,10 +286,6 @@ export interface SparkleQuizSelectCustomEvent<T> extends CustomEvent<T> {
254
286
  detail: T;
255
287
  target: HTMLSparkleQuizSelectElement;
256
288
  }
257
- export interface SparkleQuizV1CustomEvent<T> extends CustomEvent<T> {
258
- detail: T;
259
- target: HTMLSparkleQuizV1Element;
260
- }
261
289
  declare global {
262
290
  interface HTMLCompassSvgElement extends Components.CompassSvg, HTMLStencilElement {
263
291
  }
@@ -271,6 +299,12 @@ declare global {
271
299
  prototype: HTMLSparkleAnimationPlayerElement;
272
300
  new (): HTMLSparkleAnimationPlayerElement;
273
301
  };
302
+ interface HTMLSparkleAssignmentElement extends Components.SparkleAssignment, HTMLStencilElement {
303
+ }
304
+ var HTMLSparkleAssignmentElement: {
305
+ prototype: HTMLSparkleAssignmentElement;
306
+ new (): HTMLSparkleAssignmentElement;
307
+ };
274
308
  interface HTMLSparkleCharacterIntroElement extends Components.SparkleCharacterIntro, HTMLStencilElement {
275
309
  }
276
310
  var HTMLSparkleCharacterIntroElement: {
@@ -367,6 +401,12 @@ declare global {
367
401
  prototype: HTMLSparkleFeedbackElement;
368
402
  new (): HTMLSparkleFeedbackElement;
369
403
  };
404
+ interface HTMLSparkleFileUploadElement extends Components.SparkleFileUpload, HTMLStencilElement {
405
+ }
406
+ var HTMLSparkleFileUploadElement: {
407
+ prototype: HTMLSparkleFileUploadElement;
408
+ new (): HTMLSparkleFileUploadElement;
409
+ };
370
410
  interface HTMLSparkleForgotPasswordElement extends Components.SparkleForgotPassword, HTMLStencilElement {
371
411
  }
372
412
  var HTMLSparkleForgotPasswordElement: {
@@ -427,6 +467,12 @@ declare global {
427
467
  prototype: HTMLSparkleHealthElement;
428
468
  new (): HTMLSparkleHealthElement;
429
469
  };
470
+ interface HTMLSparkleInputElement extends Components.SparkleInput, HTMLStencilElement {
471
+ }
472
+ var HTMLSparkleInputElement: {
473
+ prototype: HTMLSparkleInputElement;
474
+ new (): HTMLSparkleInputElement;
475
+ };
430
476
  interface HTMLSparkleIntroElement extends Components.SparkleIntro, HTMLStencilElement {
431
477
  }
432
478
  var HTMLSparkleIntroElement: {
@@ -493,6 +539,12 @@ declare global {
493
539
  prototype: HTMLSparkleQuizInputElement;
494
540
  new (): HTMLSparkleQuizInputElement;
495
541
  };
542
+ interface HTMLSparkleQuizOldElement extends Components.SparkleQuizOld, HTMLStencilElement {
543
+ }
544
+ var HTMLSparkleQuizOldElement: {
545
+ prototype: HTMLSparkleQuizOldElement;
546
+ new (): HTMLSparkleQuizOldElement;
547
+ };
496
548
  interface HTMLSparkleQuizOpinionElement extends Components.SparkleQuizOpinion, HTMLStencilElement {
497
549
  }
498
550
  var HTMLSparkleQuizOpinionElement: {
@@ -511,12 +563,6 @@ declare global {
511
563
  prototype: HTMLSparkleQuizSelectElement;
512
564
  new (): HTMLSparkleQuizSelectElement;
513
565
  };
514
- interface HTMLSparkleQuizV1Element extends Components.SparkleQuizV1, HTMLStencilElement {
515
- }
516
- var HTMLSparkleQuizV1Element: {
517
- prototype: HTMLSparkleQuizV1Element;
518
- new (): HTMLSparkleQuizV1Element;
519
- };
520
566
  interface HTMLSparkleResetPasswordElement extends Components.SparkleResetPassword, HTMLStencilElement {
521
567
  }
522
568
  var HTMLSparkleResetPasswordElement: {
@@ -568,6 +614,7 @@ declare global {
568
614
  interface HTMLElementTagNameMap {
569
615
  "compass-svg": HTMLCompassSvgElement;
570
616
  "sparkle-animation-player": HTMLSparkleAnimationPlayerElement;
617
+ "sparkle-assignment": HTMLSparkleAssignmentElement;
571
618
  "sparkle-character-intro": HTMLSparkleCharacterIntroElement;
572
619
  "sparkle-compass": HTMLSparkleCompassElement;
573
620
  "sparkle-compass-post": HTMLSparkleCompassPostElement;
@@ -584,6 +631,7 @@ declare global {
584
631
  "sparkle-facilitator-page": HTMLSparkleFacilitatorPageElement;
585
632
  "sparkle-feed-post": HTMLSparkleFeedPostElement;
586
633
  "sparkle-feedback": HTMLSparkleFeedbackElement;
634
+ "sparkle-file-upload": HTMLSparkleFileUploadElement;
587
635
  "sparkle-forgot-password": HTMLSparkleForgotPasswordElement;
588
636
  "sparkle-goal-form": HTMLSparkleGoalFormElement;
589
637
  "sparkle-goal-item": HTMLSparkleGoalItemElement;
@@ -594,6 +642,7 @@ declare global {
594
642
  "sparkle-gww-graph": HTMLSparkleGwwGraphElement;
595
643
  "sparkle-gww-item": HTMLSparkleGwwItemElement;
596
644
  "sparkle-health": HTMLSparkleHealthElement;
645
+ "sparkle-input": HTMLSparkleInputElement;
597
646
  "sparkle-intro": HTMLSparkleIntroElement;
598
647
  "sparkle-login": HTMLSparkleLoginElement;
599
648
  "sparkle-modal-image": HTMLSparkleModalImageElement;
@@ -605,10 +654,10 @@ declare global {
605
654
  "sparkle-quiz-container": HTMLSparkleQuizContainerElement;
606
655
  "sparkle-quiz-feedback": HTMLSparkleQuizFeedbackElement;
607
656
  "sparkle-quiz-input": HTMLSparkleQuizInputElement;
657
+ "sparkle-quiz-old": HTMLSparkleQuizOldElement;
608
658
  "sparkle-quiz-opinion": HTMLSparkleQuizOpinionElement;
609
659
  "sparkle-quiz-poll": HTMLSparkleQuizPollElement;
610
660
  "sparkle-quiz-select": HTMLSparkleQuizSelectElement;
611
- "sparkle-quiz-v1": HTMLSparkleQuizV1Element;
612
661
  "sparkle-reset-password": HTMLSparkleResetPasswordElement;
613
662
  "sparkle-root": HTMLSparkleRootElement;
614
663
  "sparkle-signup": HTMLSparkleSignupElement;
@@ -627,6 +676,10 @@ declare namespace LocalJSX {
627
676
  "initialClassMode"?: boolean;
628
677
  "src"?: string;
629
678
  }
679
+ interface SparkleAssignment {
680
+ "name"?: string;
681
+ "onFormSubmitted"?: (event: SparkleAssignmentCustomEvent<any>) => void;
682
+ }
630
683
  interface SparkleCharacterIntro {
631
684
  "character"?: string;
632
685
  "position"?: 'left' | 'right';
@@ -696,6 +749,11 @@ declare namespace LocalJSX {
696
749
  }
697
750
  interface SparkleFeedback {
698
751
  }
752
+ interface SparkleFileUpload {
753
+ "name"?: string;
754
+ "onFileUploaded"?: (event: SparkleFileUploadCustomEvent<any>) => void;
755
+ "value"?: string;
756
+ }
699
757
  interface SparkleForgotPassword {
700
758
  "history"?: RouterHistory;
701
759
  }
@@ -727,6 +785,17 @@ declare namespace LocalJSX {
727
785
  interface SparkleHealth {
728
786
  "history": RouterHistory;
729
787
  }
788
+ interface SparkleInput {
789
+ "checked"?: boolean;
790
+ "label"?: string;
791
+ "name"?: string;
792
+ "onCheckedChanged"?: (event: SparkleInputCustomEvent<boolean>) => void;
793
+ "onValueChanged"?: (event: SparkleInputCustomEvent<string | boolean>) => void;
794
+ "options"?: { value: string; label: string }[] | string;
795
+ "placeholder"?: string;
796
+ "type"?: 'text' | 'textarea' | 'checkbox' | 'select';
797
+ "value"?: string | boolean;
798
+ }
730
799
  interface SparkleIntro {
731
800
  }
732
801
  interface SparkleLogin {
@@ -757,15 +826,10 @@ declare namespace LocalJSX {
757
826
  }
758
827
  interface SparkleQuiz {
759
828
  "correct"?: boolean;
760
- "feedback"?: string;
761
829
  "onQuizAnswerChanged"?: (event: SparkleQuizCustomEvent<{ answer: any; question: SparkleQuizQuestion }>) => void;
762
830
  "questionId"?: number;
763
- "questionText"?: string;
764
- "scale"?: 'FIVE-POINTS' | 'TEN-POINTS';
765
831
  "showInstantResult"?: boolean;
766
- "showOptionNumber"?: boolean;
767
832
  "submitted"?: boolean;
768
- "type"?: 'MULTIPLE-CHOICE' | 'TEXT' | 'FEEDBACK' | 'OPINION' | 'POLL';
769
833
  }
770
834
  interface SparkleQuizContainer {
771
835
  "questionIds"?: string;
@@ -779,6 +843,18 @@ declare namespace LocalJSX {
779
843
  "onQuizInputChange"?: (event: SparkleQuizInputCustomEvent<{ value: string, question: SparkleQuizQuestion }>) => void;
780
844
  "question"?: SparkleQuizQuestion;
781
845
  }
846
+ interface SparkleQuizOld {
847
+ "correct"?: boolean;
848
+ "feedback"?: string;
849
+ "onQuizAnswerChanged"?: (event: SparkleQuizOldCustomEvent<{ answer: any; question: SparkleQuizQuestion }>) => void;
850
+ "questionId"?: number;
851
+ "questionText"?: string;
852
+ "scale"?: 'FIVE-POINTS' | 'TEN-POINTS';
853
+ "showInstantResult"?: boolean;
854
+ "showOptionNumber"?: boolean;
855
+ "submitted"?: boolean;
856
+ "type"?: 'MULTIPLE-CHOICE' | 'TEXT' | 'FEEDBACK' | 'OPINION' | 'POLL';
857
+ }
782
858
  interface SparkleQuizOpinion {
783
859
  "onQuizOpinionChange"?: (event: SparkleQuizOpinionCustomEvent<{ value: any, question: SparkleQuizQuestion }>) => void;
784
860
  "question"?: SparkleQuizQuestion;
@@ -792,13 +868,6 @@ declare namespace LocalJSX {
792
868
  "onQuizSelectChange"?: (event: SparkleQuizSelectCustomEvent<{ value: any[], question: SparkleQuizQuestion }>) => void;
793
869
  "question"?: SparkleQuizQuestion;
794
870
  }
795
- interface SparkleQuizV1 {
796
- "correct"?: boolean;
797
- "onQuizAnswerChanged"?: (event: SparkleQuizV1CustomEvent<{ answer: any, question: SparkleQuizQuestion }>) => void;
798
- "questionId"?: number;
799
- "showInstantResult"?: boolean;
800
- "submitted"?: boolean;
801
- }
802
871
  interface SparkleResetPassword {
803
872
  "history"?: RouterHistory;
804
873
  }
@@ -824,6 +893,7 @@ declare namespace LocalJSX {
824
893
  interface IntrinsicElements {
825
894
  "compass-svg": CompassSvg;
826
895
  "sparkle-animation-player": SparkleAnimationPlayer;
896
+ "sparkle-assignment": SparkleAssignment;
827
897
  "sparkle-character-intro": SparkleCharacterIntro;
828
898
  "sparkle-compass": SparkleCompass;
829
899
  "sparkle-compass-post": SparkleCompassPost;
@@ -840,6 +910,7 @@ declare namespace LocalJSX {
840
910
  "sparkle-facilitator-page": SparkleFacilitatorPage;
841
911
  "sparkle-feed-post": SparkleFeedPost;
842
912
  "sparkle-feedback": SparkleFeedback;
913
+ "sparkle-file-upload": SparkleFileUpload;
843
914
  "sparkle-forgot-password": SparkleForgotPassword;
844
915
  "sparkle-goal-form": SparkleGoalForm;
845
916
  "sparkle-goal-item": SparkleGoalItem;
@@ -850,6 +921,7 @@ declare namespace LocalJSX {
850
921
  "sparkle-gww-graph": SparkleGwwGraph;
851
922
  "sparkle-gww-item": SparkleGwwItem;
852
923
  "sparkle-health": SparkleHealth;
924
+ "sparkle-input": SparkleInput;
853
925
  "sparkle-intro": SparkleIntro;
854
926
  "sparkle-login": SparkleLogin;
855
927
  "sparkle-modal-image": SparkleModalImage;
@@ -861,10 +933,10 @@ declare namespace LocalJSX {
861
933
  "sparkle-quiz-container": SparkleQuizContainer;
862
934
  "sparkle-quiz-feedback": SparkleQuizFeedback;
863
935
  "sparkle-quiz-input": SparkleQuizInput;
936
+ "sparkle-quiz-old": SparkleQuizOld;
864
937
  "sparkle-quiz-opinion": SparkleQuizOpinion;
865
938
  "sparkle-quiz-poll": SparkleQuizPoll;
866
939
  "sparkle-quiz-select": SparkleQuizSelect;
867
- "sparkle-quiz-v1": SparkleQuizV1;
868
940
  "sparkle-reset-password": SparkleResetPassword;
869
941
  "sparkle-root": SparkleRoot;
870
942
  "sparkle-signup": SparkleSignup;
@@ -881,6 +953,7 @@ declare module "@stencil/core" {
881
953
  interface IntrinsicElements {
882
954
  "compass-svg": LocalJSX.CompassSvg & JSXBase.HTMLAttributes<HTMLCompassSvgElement>;
883
955
  "sparkle-animation-player": LocalJSX.SparkleAnimationPlayer & JSXBase.HTMLAttributes<HTMLSparkleAnimationPlayerElement>;
956
+ "sparkle-assignment": LocalJSX.SparkleAssignment & JSXBase.HTMLAttributes<HTMLSparkleAssignmentElement>;
884
957
  "sparkle-character-intro": LocalJSX.SparkleCharacterIntro & JSXBase.HTMLAttributes<HTMLSparkleCharacterIntroElement>;
885
958
  "sparkle-compass": LocalJSX.SparkleCompass & JSXBase.HTMLAttributes<HTMLSparkleCompassElement>;
886
959
  "sparkle-compass-post": LocalJSX.SparkleCompassPost & JSXBase.HTMLAttributes<HTMLSparkleCompassPostElement>;
@@ -897,6 +970,7 @@ declare module "@stencil/core" {
897
970
  "sparkle-facilitator-page": LocalJSX.SparkleFacilitatorPage & JSXBase.HTMLAttributes<HTMLSparkleFacilitatorPageElement>;
898
971
  "sparkle-feed-post": LocalJSX.SparkleFeedPost & JSXBase.HTMLAttributes<HTMLSparkleFeedPostElement>;
899
972
  "sparkle-feedback": LocalJSX.SparkleFeedback & JSXBase.HTMLAttributes<HTMLSparkleFeedbackElement>;
973
+ "sparkle-file-upload": LocalJSX.SparkleFileUpload & JSXBase.HTMLAttributes<HTMLSparkleFileUploadElement>;
900
974
  "sparkle-forgot-password": LocalJSX.SparkleForgotPassword & JSXBase.HTMLAttributes<HTMLSparkleForgotPasswordElement>;
901
975
  "sparkle-goal-form": LocalJSX.SparkleGoalForm & JSXBase.HTMLAttributes<HTMLSparkleGoalFormElement>;
902
976
  "sparkle-goal-item": LocalJSX.SparkleGoalItem & JSXBase.HTMLAttributes<HTMLSparkleGoalItemElement>;
@@ -907,6 +981,7 @@ declare module "@stencil/core" {
907
981
  "sparkle-gww-graph": LocalJSX.SparkleGwwGraph & JSXBase.HTMLAttributes<HTMLSparkleGwwGraphElement>;
908
982
  "sparkle-gww-item": LocalJSX.SparkleGwwItem & JSXBase.HTMLAttributes<HTMLSparkleGwwItemElement>;
909
983
  "sparkle-health": LocalJSX.SparkleHealth & JSXBase.HTMLAttributes<HTMLSparkleHealthElement>;
984
+ "sparkle-input": LocalJSX.SparkleInput & JSXBase.HTMLAttributes<HTMLSparkleInputElement>;
910
985
  "sparkle-intro": LocalJSX.SparkleIntro & JSXBase.HTMLAttributes<HTMLSparkleIntroElement>;
911
986
  "sparkle-login": LocalJSX.SparkleLogin & JSXBase.HTMLAttributes<HTMLSparkleLoginElement>;
912
987
  "sparkle-modal-image": LocalJSX.SparkleModalImage & JSXBase.HTMLAttributes<HTMLSparkleModalImageElement>;
@@ -918,10 +993,10 @@ declare module "@stencil/core" {
918
993
  "sparkle-quiz-container": LocalJSX.SparkleQuizContainer & JSXBase.HTMLAttributes<HTMLSparkleQuizContainerElement>;
919
994
  "sparkle-quiz-feedback": LocalJSX.SparkleQuizFeedback & JSXBase.HTMLAttributes<HTMLSparkleQuizFeedbackElement>;
920
995
  "sparkle-quiz-input": LocalJSX.SparkleQuizInput & JSXBase.HTMLAttributes<HTMLSparkleQuizInputElement>;
996
+ "sparkle-quiz-old": LocalJSX.SparkleQuizOld & JSXBase.HTMLAttributes<HTMLSparkleQuizOldElement>;
921
997
  "sparkle-quiz-opinion": LocalJSX.SparkleQuizOpinion & JSXBase.HTMLAttributes<HTMLSparkleQuizOpinionElement>;
922
998
  "sparkle-quiz-poll": LocalJSX.SparkleQuizPoll & JSXBase.HTMLAttributes<HTMLSparkleQuizPollElement>;
923
999
  "sparkle-quiz-select": LocalJSX.SparkleQuizSelect & JSXBase.HTMLAttributes<HTMLSparkleQuizSelectElement>;
924
- "sparkle-quiz-v1": LocalJSX.SparkleQuizV1 & JSXBase.HTMLAttributes<HTMLSparkleQuizV1Element>;
925
1000
  "sparkle-reset-password": LocalJSX.SparkleResetPassword & JSXBase.HTMLAttributes<HTMLSparkleResetPasswordElement>;
926
1001
  "sparkle-root": LocalJSX.SparkleRoot & JSXBase.HTMLAttributes<HTMLSparkleRootElement>;
927
1002
  "sparkle-signup": LocalJSX.SparkleSignup & JSXBase.HTMLAttributes<HTMLSparkleSignupElement>;
@@ -20,6 +20,10 @@ export interface ClassFeedPostViewModel {
20
20
  MiniAppId: number;
21
21
  ProfileImageUrl: string;
22
22
  }
23
+ export interface CreateAssignmentRequestModel {
24
+ AssignmentName: string;
25
+ AssignmentData: string;
26
+ }
23
27
  export declare enum PostVisibility {
24
28
  Private = 0,
25
29
  Public = 1
@@ -0,0 +1,8 @@
1
+ import { IResult } from './httpService';
2
+ import { ClassFeedPostViewModel, CreateAssignmentRequestModel } from '../models/class.model';
3
+ export declare class AssignmentService {
4
+ private static instance;
5
+ private constructor();
6
+ static getInstance(): AssignmentService;
7
+ createAssignment(payload: CreateAssignmentRequestModel): Promise<IResult<ClassFeedPostViewModel>>;
8
+ }
@@ -1,4 +1,4 @@
1
- import { AuthUser } from "../../models/auth/auth.user";
1
+ import { AuthUser } from '../../models/auth/auth.user';
2
2
  interface AuthenticationModel {
3
3
  Email: string;
4
4
  Password: string;
@@ -1,3 +1,5 @@
1
+ export interface EnvironmentAuthConfig {
2
+ }
1
3
  export interface EnvironmentSparkleConfig {
2
4
  prod: boolean;
3
5
  appUrl: string;
@@ -11,6 +13,7 @@ export interface EnvironmentSparkleConfig {
11
13
  showModuleIndex: boolean;
12
14
  showSessionIndex: boolean;
13
15
  };
16
+ auth?: EnvironmentAuthConfig;
14
17
  }
15
18
  export interface EnvironmentConfig {
16
19
  sparkle: EnvironmentSparkleConfig;
@@ -0,0 +1,13 @@
1
+ import { AuthUser } from '../models/auth/auth.user';
2
+ export declare class TokenService {
3
+ private static instance;
4
+ static getInstance(): TokenService;
5
+ getToken(): Promise<string>;
6
+ getAuthUser(): Promise<AuthUser>;
7
+ getAuthUserSync(): AuthUser;
8
+ getTokenSync(): string;
9
+ isAuthenticated(): boolean;
10
+ getTokenExpiry(): Promise<number>;
11
+ saveAuthUser(authUser: AuthUser): Promise<void>;
12
+ removeAuthUser(): Promise<void>;
13
+ }
@@ -15,6 +15,7 @@ export declare function MyHealthTemplate(heartRate: number): string;
15
15
  export declare function MyHealthTemplateJSON(heartRate: number): string;
16
16
  export declare function MyGoalTemplate(goalName: string, text: string, progress: number): string;
17
17
  export declare function MyGoalTemplateJSON(goalName: string, goalUpdateText: string, progress: number): string;
18
+ export declare function FeedPostJSON(postText: string): string;
18
19
  export declare class SparkleGlobal {
19
20
  static MY_GOALS_APP_ID: number;
20
21
  static MY_HEALTH_APP_ID: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sparkle-learning/core",
3
- "version": "0.0.53",
3
+ "version": "0.0.55",
4
4
  "description": "sparkle",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",