@local-civics/mgmt-ui 0.1.212 → 0.1.214

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/dist/index.d.ts CHANGED
@@ -5,7 +5,7 @@ import * as React from 'react';
5
5
  * NavbarProps
6
6
  */
7
7
  interface NavbarProps {
8
- active: string;
8
+ active?: string;
9
9
  version: string;
10
10
  image: string;
11
11
  name: string;
@@ -21,6 +21,16 @@ interface NavbarProps {
21
21
  onGettingStarted: () => void;
22
22
  onSwitchAccounts?: () => void;
23
23
  }
24
+ /**
25
+ * The educator/admin left nav. Same behavior as before this round's restyle — item list, per-item
26
+ * notification counts, the `hidden`/trial visibility rules, the Organization sub-menu — only the
27
+ * markup/styling moved from Mantine's `createStyles` theme to Tailwind utility classes (matching
28
+ * the flat cyan/mint/gold system already shipped on the student side), plus `active` is now
29
+ * optional rather than required (it was forcing at least one caller to pass an empty string just
30
+ * to satisfy the type, which meant no row ever highlighted for it).
31
+ * @param props
32
+ * @constructor
33
+ */
24
34
  declare function Navbar(props: NavbarProps): JSX.Element;
25
35
 
26
36
  /**
@@ -69,7 +79,7 @@ declare const SwitchAccount: (props: SwitchAccountProps) => JSX.Element;
69
79
  /**
70
80
  * Item
71
81
  */
72
- interface Item$p {
82
+ interface Item$o {
73
83
  lessonName: string;
74
84
  completion: number;
75
85
  isStarted?: boolean;
@@ -79,19 +89,19 @@ interface Item$p {
79
89
  /**
80
90
  * Item
81
91
  */
82
- interface Item$o {
92
+ interface Item$n {
83
93
  userId: string;
84
94
  avatar: string;
85
95
  name: string;
86
96
  email: string;
87
97
  isComplete?: boolean;
88
- lessons: Item$p[];
98
+ lessons: Item$o[];
89
99
  }
90
100
 
91
101
  /**
92
102
  * Item
93
103
  */
94
- interface Item$n {
104
+ interface Item$m {
95
105
  lessonId: string;
96
106
  lessonName: string;
97
107
  percentageCompletion: number;
@@ -101,7 +111,7 @@ interface Item$n {
101
111
  /**
102
112
  * BadgeUserItem
103
113
  */
104
- type BadgeUserItem = Item$o;
114
+ type BadgeUserItem = Item$n;
105
115
  /**
106
116
  * BadgeClass
107
117
  */
@@ -118,7 +128,7 @@ type BadgeProps = {
118
128
  displayName: string;
119
129
  description: string;
120
130
  classes: BadgeClass[];
121
- lessons: Item$n[];
131
+ lessons: Item$m[];
122
132
  classId: string;
123
133
  students: BadgeUserItem[];
124
134
  href: string;
@@ -139,7 +149,7 @@ declare const Badge: (props: BadgeProps) => JSX.Element;
139
149
  /**
140
150
  * Item
141
151
  */
142
- interface Item$m {
152
+ interface Item$l {
143
153
  badgeId: string;
144
154
  name: string;
145
155
  description: string;
@@ -149,7 +159,7 @@ interface Item$m {
149
159
  /**
150
160
  * BadgeItem
151
161
  */
152
- type BadgeItem = Item$m;
162
+ type BadgeItem = Item$l;
153
163
  /**
154
164
  * BadgesProps
155
165
  */
@@ -168,7 +178,7 @@ declare const Badges: (props: BadgesProps) => JSX.Element;
168
178
  /**
169
179
  * Item
170
180
  */
171
- interface Item$l {
181
+ interface Item$k {
172
182
  studentId: string;
173
183
  studentName: string;
174
184
  className: string;
@@ -177,7 +187,7 @@ interface Item$l {
177
187
  /**
178
188
  * Item
179
189
  */
180
- interface Item$k {
190
+ interface Item$j {
181
191
  lessonName: string;
182
192
  studentName: string;
183
193
  reflection: string;
@@ -187,7 +197,7 @@ interface Item$k {
187
197
  /**
188
198
  * Item
189
199
  */
190
- interface Item$j {
200
+ interface Item$i {
191
201
  studentName: string;
192
202
  impactStatement: string;
193
203
  }
@@ -195,7 +205,7 @@ interface Item$j {
195
205
  /**
196
206
  * Item
197
207
  */
198
- interface Item$i {
208
+ interface Item$h {
199
209
  badgeId: string;
200
210
  name: string;
201
211
  description: string;
@@ -205,7 +215,7 @@ interface Item$i {
205
215
  /**
206
216
  * Item
207
217
  */
208
- interface Item$h {
218
+ interface Item$g {
209
219
  lessonId: string;
210
220
  name: string;
211
221
  description: string;
@@ -224,20 +234,20 @@ type DashboardClass = {
224
234
  */
225
235
  type DashboardProps = {
226
236
  loading: boolean;
227
- students: Item$l[];
228
- impacts: Item$j[];
229
- reflections: Item$k[];
237
+ students: Item$k[];
238
+ impacts: Item$i[];
239
+ reflections: Item$j[];
230
240
  classes: DashboardClass[];
231
- badges: Item$i[];
232
- lessons: Item$h[];
241
+ badges: Item$h[];
242
+ lessons: Item$g[];
233
243
  classId: string;
234
244
  percentageOfAccountsCreated: number;
235
245
  numberOfBadgesEarned: number;
236
246
  numberOfLessonsCompleted: number;
237
247
  onClassChange: (classId: string) => void;
238
- onViewStudentProfile: (student: Item$l) => void;
239
- onBadgeClick: (badge: Item$i) => void;
240
- onLessonClick: (lesson: Item$h) => void;
248
+ onViewStudentProfile: (student: Item$k) => void;
249
+ onBadgeClick: (badge: Item$h) => void;
250
+ onLessonClick: (lesson: Item$g) => void;
241
251
  };
242
252
  /**
243
253
  * Dashboard
@@ -249,7 +259,7 @@ declare const Dashboard: (props: DashboardProps) => JSX.Element;
249
259
  /**
250
260
  * Item
251
261
  */
252
- type Item$g = {
262
+ type Item$f = {
253
263
  classId: string;
254
264
  userId: string;
255
265
  avatar: string;
@@ -268,7 +278,7 @@ type Item$g = {
268
278
  /**
269
279
  * MemberItem
270
280
  */
271
- type MemberItem = Item$g;
281
+ type MemberItem = Item$f;
272
282
  /**
273
283
  * ClassProps
274
284
  */
@@ -288,13 +298,15 @@ type ClassProps = {
288
298
  onExportDataClick: () => void;
289
299
  };
290
300
  /**
291
- * Class
301
+ * Class. Chrome (header, actions, stat bar, table) is restyled to match the redesigned educator
302
+ * sidebar/shell; the Add Students drawer (CSV bulk upload + manual entry) and its underlying
303
+ * `onCreateMembers`/Dropzone/form logic are unchanged from before this round.
292
304
  * @param props
293
305
  * @constructor
294
306
  */
295
307
  declare const Class: (props: ClassProps) => JSX.Element;
296
308
 
297
- type Item$f = {
309
+ type Item$e = {
298
310
  href: string;
299
311
  classId: string;
300
312
  name: string;
@@ -305,7 +317,7 @@ type Item$f = {
305
317
  /**
306
318
  * ClassItem
307
319
  */
308
- type ClassItem = Item$f;
320
+ type ClassItem = Item$e;
309
321
  /**
310
322
  * ClassesProps
311
323
  */
@@ -326,7 +338,7 @@ declare const Classes: (props: ClassesProps) => JSX.Element;
326
338
  /**
327
339
  * Item
328
340
  */
329
- interface Item$e {
341
+ interface Item$d {
330
342
  badgeId: string;
331
343
  badgeName: string;
332
344
  isComplete?: boolean;
@@ -335,7 +347,7 @@ interface Item$e {
335
347
  /**
336
348
  * Item
337
349
  */
338
- interface Item$d {
350
+ interface Item$c {
339
351
  lessonId: string;
340
352
  lessonName: string;
341
353
  questionName: string;
@@ -346,7 +358,7 @@ interface Item$d {
346
358
  /**
347
359
  * Item
348
360
  */
349
- interface Item$c {
361
+ interface Item$b {
350
362
  lessonId: string;
351
363
  lessonName: string;
352
364
  reflection: string;
@@ -364,10 +376,10 @@ type StudentProps = {
364
376
  numberOfProblemsSolved: number;
365
377
  percentageOfLessonsCompleted: number;
366
378
  numberOfLessonsCompleted: number;
367
- badges: Item$e[];
379
+ badges: Item$d[];
368
380
  lessons: LessonItem$1[];
369
- answers: Item$d[];
370
- reflections: Item$c[];
381
+ answers: Item$c[];
382
+ reflections: Item$b[];
371
383
  onBackClick: () => void;
372
384
  };
373
385
  type LessonItem$1 = {
@@ -409,7 +421,7 @@ declare const Home: (props: HomeProps) => JSX.Element;
409
421
  /**
410
422
  * Item
411
423
  */
412
- interface Item$b {
424
+ interface Item$a {
413
425
  studentName: string;
414
426
  reflection: string;
415
427
  rating: number;
@@ -418,7 +430,7 @@ interface Item$b {
418
430
  /**
419
431
  * Item
420
432
  */
421
- interface Item$a {
433
+ interface Item$9 {
422
434
  questionName: string;
423
435
  answer: string[];
424
436
  }
@@ -426,12 +438,12 @@ interface Item$a {
426
438
  /**
427
439
  * Item
428
440
  */
429
- interface Item$9 {
441
+ interface Item$8 {
430
442
  userId: string;
431
443
  avatar: string;
432
444
  name: string;
433
445
  email: string;
434
- answers: Item$a[];
446
+ answers: Item$9[];
435
447
  isStarted?: boolean;
436
448
  isComplete?: boolean;
437
449
  href: string;
@@ -440,7 +452,7 @@ interface Item$9 {
440
452
  /**
441
453
  * Item
442
454
  */
443
- interface Item$8 {
455
+ interface Item$7 {
444
456
  question: string;
445
457
  answers: string[][];
446
458
  choices?: string[];
@@ -450,7 +462,7 @@ interface Item$8 {
450
462
  /**
451
463
  * LessonUserItem
452
464
  */
453
- type LessonUserItem = Item$9;
465
+ type LessonUserItem = Item$8;
454
466
  /**
455
467
  * LessonClass
456
468
  */
@@ -470,8 +482,8 @@ type LessonProps = {
470
482
  classId: string;
471
483
  classes: LessonClass[];
472
484
  students: LessonUserItem[];
473
- reflections: Item$b[];
474
- questions: Item$8[];
485
+ reflections: Item$a[];
486
+ questions: Item$7[];
475
487
  trial?: boolean;
476
488
  lessonsCompleted?: number;
477
489
  contributors?: {
@@ -492,17 +504,18 @@ declare const Lesson: (props: LessonProps) => JSX.Element;
492
504
  /**
493
505
  * Item
494
506
  */
495
- interface Item$7 {
507
+ interface Item$6 {
496
508
  lessonId: string;
497
509
  name: string;
498
510
  description: string;
511
+ pathway?: string;
499
512
  href: string;
500
513
  }
501
514
 
502
515
  /**
503
516
  * LessonItem
504
517
  */
505
- type LessonItem = Item$7;
518
+ type LessonItem = Item$6;
506
519
  /**
507
520
  * LessonsProps
508
521
  */
@@ -543,7 +556,7 @@ declare const Organization: (props: OrganizationProps) => JSX.Element;
543
556
  /**
544
557
  * Item
545
558
  */
546
- type Item$6 = {
559
+ type Item$5 = {
547
560
  userId: string;
548
561
  avatar: string;
549
562
  email: string;
@@ -561,7 +574,7 @@ type Item$6 = {
561
574
  /**
562
575
  * UserItem
563
576
  */
564
- type UserItem = Item$6;
577
+ type UserItem = Item$5;
565
578
  /**
566
579
  * PeopleProps
567
580
  */
@@ -694,7 +707,7 @@ declare const App: (props: AppProps) => JSX.Element;
694
707
  /**
695
708
  * Item
696
709
  */
697
- interface Item$5 {
710
+ interface Item$4 {
698
711
  badgeId: string;
699
712
  name: string;
700
713
  description: string;
@@ -704,7 +717,7 @@ interface Item$5 {
704
717
  /**
705
718
  * PathwaysItem
706
719
  */
707
- type PathwaysItem = Item$5;
720
+ type PathwaysItem = Item$4;
708
721
  /**
709
722
  * PathwaysProps
710
723
  */
@@ -722,7 +735,7 @@ declare const Pathways: (props: PathwaysProps) => JSX.Element;
722
735
  /**
723
736
  * Item
724
737
  */
725
- interface Item$4 {
738
+ interface Item$3 {
726
739
  badgeName: string;
727
740
  completion: number;
728
741
  isStarted?: boolean;
@@ -732,13 +745,13 @@ interface Item$4 {
732
745
  /**
733
746
  * Item
734
747
  */
735
- interface Item$3 {
748
+ interface Item$2 {
736
749
  userId: string;
737
750
  avatar: string;
738
751
  name: string;
739
752
  email: string;
740
753
  isComplete?: boolean;
741
- badges: Item$4[];
754
+ badges: Item$3[];
742
755
  categoryPoints?: Record<string, number>;
743
756
  [key: string]: any;
744
757
  }
@@ -746,7 +759,7 @@ interface Item$3 {
746
759
  /**
747
760
  * Item
748
761
  */
749
- interface Item$2 {
762
+ interface Item$1 {
750
763
  badgeId: string;
751
764
  badgeName: string;
752
765
  percentageCompletion: number;
@@ -756,7 +769,7 @@ interface Item$2 {
756
769
  /**
757
770
  * PathwayUserItem
758
771
  */
759
- type PathwayUserItem = Item$3;
772
+ type PathwayUserItem = Item$2;
760
773
  /**
761
774
  * PathwayClass
762
775
  */
@@ -773,7 +786,7 @@ type PathwayProps = {
773
786
  title: string;
774
787
  description: string;
775
788
  classes: PathwayClass[];
776
- badges: Item$2[];
789
+ badges: Item$1[];
777
790
  classId: string;
778
791
  students: PathwayUserItem[];
779
792
  categories: {
@@ -793,12 +806,12 @@ type PathwayProps = {
793
806
  * @param props
794
807
  * @constructor
795
808
  */
796
- declare const Pathway$1: (props: PathwayProps) => JSX.Element;
809
+ declare const Pathway: (props: PathwayProps) => JSX.Element;
797
810
 
798
811
  /**
799
812
  * Item
800
813
  */
801
- interface Item$1 {
814
+ interface Item {
802
815
  userId: string;
803
816
  avatar: string;
804
817
  name: string;
@@ -811,35 +824,14 @@ interface SubmissionItem {
811
824
  badgeId: string;
812
825
  lessonName: string;
813
826
  question: string;
827
+ updatedAt?: string;
828
+ pathwayName?: string;
814
829
  }
815
830
 
816
- /**
817
- * Item
818
- */
819
- interface Item {
820
- lessonId: string;
821
- lessonName: string;
822
- percentageCompletion: number;
823
- href: string;
824
- }
825
-
826
- type Pathway = {
827
- pathwayId: string;
828
- title: string;
829
- description: string;
830
- };
831
- type PathwayTableProps = {
832
- pathways: Pathway[];
833
- badges: any[];
834
- students: FileLockerUserItem[];
835
- };
836
- declare const PathwayTable: React.FC<PathwayTableProps & {
837
- loading: boolean;
838
- }>;
839
831
  /**
840
832
  * FileLockerUserItem
841
833
  */
842
- type FileLockerUserItem = Item$1;
834
+ type FileLockerUserItem = Item;
843
835
  /**
844
836
  * FileLockerClass
845
837
  */
@@ -856,7 +848,10 @@ type FileLockerProps = {
856
848
  displayName: string;
857
849
  description: string;
858
850
  classes: FileLockerClass[];
859
- lessons: Item[];
851
+ lessons: {
852
+ lessonId: string;
853
+ lessonName: string;
854
+ }[];
860
855
  classId: string;
861
856
  students: FileLockerUserItem[];
862
857
  href: string;
@@ -871,6 +866,7 @@ type FileLockerProps = {
871
866
  badgeId: string;
872
867
  displayName: string;
873
868
  categories?: string[];
869
+ lessonIds?: string[];
874
870
  }[];
875
871
  onBackClick: () => void;
876
872
  onClassChange: (classId: string) => void;
@@ -884,4 +880,4 @@ type FileLockerProps = {
884
880
  */
885
881
  declare const FileLocker: (props: FileLockerProps) => JSX.Element;
886
882
 
887
- export { AccountItem, AdminProvider, AdminProviderProps, App, AppProps, Badge, BadgeClass, BadgeItem, BadgeProps, BadgeUserItem, Badges, BadgesProps, Class, ClassItem, ClassProps, Classes, ClassesProps, Dashboard, DashboardClass, DashboardProps, FileLocker, FileLockerClass, FileLockerProps, FileLockerUserItem, GettingStarted, GettingStartedProps, Home, HomeProps, Lesson, LessonClass, LessonItem, LessonProps, LessonUserItem, Lessons, LessonsProps, MemberItem, Navbar, NavbarProps, NewTrialRegistration, Organization, OrganizationProps, Pathway$1 as Pathway, PathwayClass, PathwayProps, PathwayTable, PathwayUserItem, Pathways, PathwaysItem, PathwaysProps, People, PeopleProps, StartAnonymousLesson, StartAnonymousLessonProps, Student, StudentProps, SwitchAccount, SwitchAccountProps, TrialHome, TrialHomeProps, TrialRegistration, TrialRegistrationProps, UserItem };
883
+ export { AccountItem, AdminProvider, AdminProviderProps, App, AppProps, Badge, BadgeClass, BadgeItem, BadgeProps, BadgeUserItem, Badges, BadgesProps, Class, ClassItem, ClassProps, Classes, ClassesProps, Dashboard, DashboardClass, DashboardProps, FileLocker, FileLockerClass, FileLockerProps, FileLockerUserItem, GettingStarted, GettingStartedProps, Home, HomeProps, Lesson, LessonClass, LessonItem, LessonProps, LessonUserItem, Lessons, LessonsProps, MemberItem, Navbar, NavbarProps, NewTrialRegistration, Organization, OrganizationProps, Pathway, PathwayClass, PathwayProps, PathwayUserItem, Pathways, PathwaysItem, PathwaysProps, People, PeopleProps, StartAnonymousLesson, StartAnonymousLessonProps, Student, StudentProps, SwitchAccount, SwitchAccountProps, TrialHome, TrialHomeProps, TrialRegistration, TrialRegistrationProps, UserItem };
@@ -0,0 +1,44 @@
1
+ @charset "UTF-8";
2
+ @font-face {
3
+ font-family: "ProximaNova";
4
+ src: url(https://cdn.localcivics.io/fonts/ProximaNova.otf) format("opentype");
5
+ }
6
+ @font-face {
7
+ font-family: "ProximaNova";
8
+ font-weight: bold;
9
+ src: url(https://cdn.localcivics.io/fonts/ProximaNovaBold.otf) format("opentype");
10
+ }
11
+ @tailwind base;
12
+ @tailwind components;
13
+ @tailwind utilities;
14
+ /*
15
+ * Tailwind's preflight is disabled here (see tailwind.config.cjs) to avoid fighting Mantine's own
16
+ * global reset on the pages this round doesn't touch. But every Tailwind `border`/`border-{color}`
17
+ * utility silently depends on preflight's `border-style: solid` default — without it, the browser's
18
+ * native default (`border-style: none`) means border-width and border-color render with no visible
19
+ * effect at all. This is the one rule from preflight actually needed; using the lowest-specificity
20
+ * selector (`*`) so it never overrides a component's own more specific border-style (e.g. Mantine's
21
+ * dashed Dropzone).
22
+ */
23
+ *, ::before, ::after {
24
+ border-width: 0;
25
+ border-style: solid;
26
+ }
27
+
28
+ /*
29
+ * Same root cause as the border-style rule above: with preflight disabled, a button with no
30
+ * explicit background class falls back to native OS button chrome (gray background, black text)
31
+ * instead of transparent. Restoring just the specific preflight button rules every unstyled button
32
+ * depends on — buttons that already set their own background/padding via Tailwind classes are
33
+ * unaffected, since a class selector beats this bare element selector.
34
+ */
35
+ button {
36
+ background-color: transparent;
37
+ background-image: none;
38
+ padding: 0;
39
+ margin: 0;
40
+ font: inherit;
41
+ color: inherit;
42
+ text-transform: none;
43
+ cursor: pointer;
44
+ }