@local-civics/mgmt-ui 0.1.187 → 0.1.188

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.js CHANGED
@@ -34,35 +34,35 @@ function _interopNamespaceDefault(e) {
34
34
  var React__namespace = /*#__PURE__*/_interopNamespaceDefault(React);
35
35
  var papa__namespace = /*#__PURE__*/_interopNamespaceDefault(papa);
36
36
 
37
- var __defProp$9 = Object.defineProperty;
38
- var __getOwnPropSymbols$9 = Object.getOwnPropertySymbols;
39
- var __hasOwnProp$9 = Object.prototype.hasOwnProperty;
40
- var __propIsEnum$9 = Object.prototype.propertyIsEnumerable;
41
- var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
42
- var __spreadValues$9 = (a, b) => {
37
+ var __defProp$a = Object.defineProperty;
38
+ var __getOwnPropSymbols$a = Object.getOwnPropertySymbols;
39
+ var __hasOwnProp$a = Object.prototype.hasOwnProperty;
40
+ var __propIsEnum$a = Object.prototype.propertyIsEnumerable;
41
+ var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
42
+ var __spreadValues$a = (a, b) => {
43
43
  for (var prop in b || (b = {}))
44
- if (__hasOwnProp$9.call(b, prop))
45
- __defNormalProp$9(a, prop, b[prop]);
46
- if (__getOwnPropSymbols$9)
47
- for (var prop of __getOwnPropSymbols$9(b)) {
48
- if (__propIsEnum$9.call(b, prop))
49
- __defNormalProp$9(a, prop, b[prop]);
44
+ if (__hasOwnProp$a.call(b, prop))
45
+ __defNormalProp$a(a, prop, b[prop]);
46
+ if (__getOwnPropSymbols$a)
47
+ for (var prop of __getOwnPropSymbols$a(b)) {
48
+ if (__propIsEnum$a.call(b, prop))
49
+ __defNormalProp$a(a, prop, b[prop]);
50
50
  }
51
51
  return a;
52
52
  };
53
53
  var __objRest$2 = (source, exclude) => {
54
54
  var target = {};
55
55
  for (var prop in source)
56
- if (__hasOwnProp$9.call(source, prop) && exclude.indexOf(prop) < 0)
56
+ if (__hasOwnProp$a.call(source, prop) && exclude.indexOf(prop) < 0)
57
57
  target[prop] = source[prop];
58
- if (source != null && __getOwnPropSymbols$9)
59
- for (var prop of __getOwnPropSymbols$9(source)) {
60
- if (exclude.indexOf(prop) < 0 && __propIsEnum$9.call(source, prop))
58
+ if (source != null && __getOwnPropSymbols$a)
59
+ for (var prop of __getOwnPropSymbols$a(source)) {
60
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$a.call(source, prop))
61
61
  target[prop] = source[prop];
62
62
  }
63
63
  return target;
64
64
  };
65
- const useStyles$v = core.createStyles((theme) => ({
65
+ const useStyles$w = core.createStyles((theme) => ({
66
66
  user: {
67
67
  display: "block",
68
68
  width: "100%",
@@ -73,8 +73,8 @@ const useStyles$v = core.createStyles((theme) => ({
73
73
  }));
74
74
  function UserButton(_a) {
75
75
  var _b = _a, { image, name, email, icon } = _b, others = __objRest$2(_b, ["image", "name", "email", "icon"]);
76
- const { classes } = useStyles$v();
77
- return /* @__PURE__ */ React__namespace.createElement(core.Group, __spreadValues$9({ className: classes.user }, others), /* @__PURE__ */ React__namespace.createElement(core.Avatar, { src: image, radius: "xl" }), /* @__PURE__ */ React__namespace.createElement("div", { style: { flex: 1 } }, /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "sm", weight: 500 }, name), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", size: "xs" }, email)));
76
+ const { classes } = useStyles$w();
77
+ return /* @__PURE__ */ React__namespace.createElement(core.Group, __spreadValues$a({ className: classes.user }, others), /* @__PURE__ */ React__namespace.createElement(core.Avatar, { src: image, radius: "xl" }), /* @__PURE__ */ React__namespace.createElement("div", { style: { flex: 1 } }, /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "sm", weight: 500 }, name), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", size: "xs" }, email)));
78
78
  }
79
79
 
80
80
  const compact = (num) => {
@@ -84,7 +84,7 @@ const compact = (num) => {
84
84
  }).format(num || 0);
85
85
  };
86
86
 
87
- const useStyles$u = core.createStyles((theme, _params, getRef) => {
87
+ const useStyles$v = core.createStyles((theme, _params, getRef) => {
88
88
  const icon = getRef("icon");
89
89
  return {
90
90
  control: {
@@ -137,7 +137,7 @@ const useStyles$u = core.createStyles((theme, _params, getRef) => {
137
137
  };
138
138
  });
139
139
  function LinksGroup({ icon: Icon, href, label, initiallyOpened, links, active, notifications }) {
140
- const { classes, theme, cx } = useStyles$u();
140
+ const { classes, theme, cx } = useStyles$v();
141
141
  const hasLinks = Array.isArray(links) && links.length > 0;
142
142
  const hasActiveLinks = Array.isArray(links) && links.map((l) => !!active && active === `${label}/${l.label}`).reduce((a, b) => a || b, false);
143
143
  const [opened, setOpened] = React.useState(initiallyOpened || hasActiveLinks || false);
@@ -182,26 +182,26 @@ function LinksGroup({ icon: Icon, href, label, initiallyOpened, links, active, n
182
182
  ), hasLinks ? /* @__PURE__ */ React__namespace.createElement(core.Collapse, { in: opened }, items) : null);
183
183
  }
184
184
 
185
- var __defProp$8 = Object.defineProperty;
186
- var __defProps$5 = Object.defineProperties;
187
- var __getOwnPropDescs$5 = Object.getOwnPropertyDescriptors;
188
- var __getOwnPropSymbols$8 = Object.getOwnPropertySymbols;
189
- var __hasOwnProp$8 = Object.prototype.hasOwnProperty;
190
- var __propIsEnum$8 = Object.prototype.propertyIsEnumerable;
191
- var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
192
- var __spreadValues$8 = (a, b) => {
185
+ var __defProp$9 = Object.defineProperty;
186
+ var __defProps$6 = Object.defineProperties;
187
+ var __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors;
188
+ var __getOwnPropSymbols$9 = Object.getOwnPropertySymbols;
189
+ var __hasOwnProp$9 = Object.prototype.hasOwnProperty;
190
+ var __propIsEnum$9 = Object.prototype.propertyIsEnumerable;
191
+ var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
192
+ var __spreadValues$9 = (a, b) => {
193
193
  for (var prop in b || (b = {}))
194
- if (__hasOwnProp$8.call(b, prop))
195
- __defNormalProp$8(a, prop, b[prop]);
196
- if (__getOwnPropSymbols$8)
197
- for (var prop of __getOwnPropSymbols$8(b)) {
198
- if (__propIsEnum$8.call(b, prop))
199
- __defNormalProp$8(a, prop, b[prop]);
194
+ if (__hasOwnProp$9.call(b, prop))
195
+ __defNormalProp$9(a, prop, b[prop]);
196
+ if (__getOwnPropSymbols$9)
197
+ for (var prop of __getOwnPropSymbols$9(b)) {
198
+ if (__propIsEnum$9.call(b, prop))
199
+ __defNormalProp$9(a, prop, b[prop]);
200
200
  }
201
201
  return a;
202
202
  };
203
- var __spreadProps$5 = (a, b) => __defProps$5(a, __getOwnPropDescs$5(b));
204
- const useStyles$t = core.createStyles((theme, _params, getRef) => {
203
+ var __spreadProps$6 = (a, b) => __defProps$6(a, __getOwnPropDescs$6(b));
204
+ const useStyles$u = core.createStyles((theme, _params, getRef) => {
205
205
  const icon = getRef("icon");
206
206
  return {
207
207
  navbar: {
@@ -232,7 +232,7 @@ const useStyles$t = core.createStyles((theme, _params, getRef) => {
232
232
  color: theme.colorScheme === "dark" ? theme.white : theme.black,
233
233
  borderBottom: `1px solid ${theme.colorScheme === "dark" ? theme.colors.dark[4] : theme.colors.gray[3]}`
234
234
  },
235
- link: __spreadProps$5(__spreadValues$8({}, theme.fn.focusStyles()), {
235
+ link: __spreadProps$6(__spreadValues$9({}, theme.fn.focusStyles()), {
236
236
  display: "flex",
237
237
  alignItems: "center",
238
238
  textDecoration: "none",
@@ -301,7 +301,7 @@ const TRIAL_PAGES = [
301
301
  "Badges"
302
302
  ];
303
303
  function Navbar(props) {
304
- const { classes, cx } = useStyles$t();
304
+ const { classes, cx } = useStyles$u();
305
305
  const [burgerOpen, setBurgerOpen] = React__namespace.useState(false);
306
306
  const toggle = () => setBurgerOpen(!burgerOpen);
307
307
  const links = data.map((item) => {
@@ -314,12 +314,12 @@ function Navbar(props) {
314
314
  }
315
315
  return /* @__PURE__ */ React__namespace.createElement(
316
316
  LinksGroup,
317
- __spreadProps$5(__spreadValues$8(__spreadValues$8({
317
+ __spreadProps$6(__spreadValues$9(__spreadValues$9({
318
318
  key: item.label,
319
319
  active: props.active
320
320
  }, item), context), {
321
321
  links: (item.links || []).map((link) => {
322
- return __spreadValues$8(__spreadValues$8({}, link), props.links[`${item.label}/${link.label}`] || { notifications: 0, href: "" });
322
+ return __spreadValues$9(__spreadValues$9({}, link), props.links[`${item.label}/${link.label}`] || { notifications: 0, href: "" });
323
323
  })
324
324
  })
325
325
  );
@@ -344,7 +344,7 @@ function Navbar(props) {
344
344
  } }, /* @__PURE__ */ React__namespace.createElement(icons.IconLogout, { className: classes.linkIcon, stroke: 1.5 }), /* @__PURE__ */ React__namespace.createElement("span", null, "Logout"))))));
345
345
  }
346
346
 
347
- const useStyles$s = core.createStyles((theme) => ({
347
+ const useStyles$t = core.createStyles((theme) => ({
348
348
  inner: {
349
349
  paddingTop: theme.spacing.xl,
350
350
  paddingBottom: theme.spacing.xl * 4
@@ -380,7 +380,7 @@ const useStyles$s = core.createStyles((theme) => ({
380
380
  }
381
381
  }));
382
382
  const GettingStarted = (props) => {
383
- const { classes } = useStyles$s();
383
+ const { classes } = useStyles$t();
384
384
  return /* @__PURE__ */ React__namespace.createElement(
385
385
  core.Modal,
386
386
  {
@@ -394,7 +394,7 @@ const GettingStarted = (props) => {
394
394
  );
395
395
  };
396
396
 
397
- const useStyles$r = core.createStyles((theme) => ({
397
+ const useStyles$s = core.createStyles((theme) => ({
398
398
  title: {
399
399
  fontSize: 34,
400
400
  fontWeight: 900,
@@ -435,7 +435,7 @@ const useStyles$r = core.createStyles((theme) => ({
435
435
  }
436
436
  }));
437
437
  const SwitchAccount = (props) => {
438
- const { classes, theme } = useStyles$r();
438
+ const { classes, theme } = useStyles$s();
439
439
  const options = props.accounts.map((a) => {
440
440
  return /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { onClick: () => props.onClick && props.onClick(a.accountId), key: a.accountId, p: theme.spacing.md }, /* @__PURE__ */ React__namespace.createElement(core.Card, { withBorder: true, shadow: "md", radius: "md", className: classes.card, p: "xl" }, a.isAdmin && /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement(icons.IconBatteryEco, { size: 50, stroke: 2, color: theme.fn.primaryColor() })), a.isGroupAdmin && !a.isAdmin && /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement(icons.IconBooks, { size: 50, stroke: 2, color: theme.fn.primaryColor() })), !a.isAdmin && !a.isGroupAdmin && /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement(icons.IconBackpack, { size: 50, stroke: 2, color: theme.fn.primaryColor() })), /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "lg", weight: 500, className: classes.cardTitle, mt: "md" }, a.name), /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "sm", color: "dimmed", mt: "sm" }, a.isAdmin ? "Admin" : a.isGroupAdmin ? "Educator" : "Student")));
441
441
  });
@@ -452,7 +452,7 @@ const SwitchAccount = (props) => {
452
452
  );
453
453
  };
454
454
 
455
- const useStyles$q = core.createStyles((theme) => ({
455
+ const useStyles$r = core.createStyles((theme) => ({
456
456
  root: {
457
457
  display: "flex",
458
458
  backgroundImage: `linear-gradient(-60deg, ${theme.colors[theme.primaryColor][4]} 0%, ${theme.colors[theme.primaryColor][7]} 100%)`,
@@ -496,7 +496,7 @@ const useStyles$q = core.createStyles((theme) => ({
496
496
  }
497
497
  }));
498
498
  const StatsGroup = ({ data, footer }) => {
499
- const { classes } = useStyles$q();
499
+ const { classes } = useStyles$r();
500
500
  const stats = data.map((stat) => {
501
501
  const value = (() => {
502
502
  if (stat.unit === "%") {
@@ -516,7 +516,7 @@ const Tabs = (props) => {
516
516
  return /* @__PURE__ */ React__namespace.createElement(core.Tabs, { value: props.value, onTabChange: props.onChange }, /* @__PURE__ */ React__namespace.createElement(core.Tabs.List, null, tabs));
517
517
  };
518
518
 
519
- const useStyles$p = core.createStyles((theme) => ({
519
+ const useStyles$q = core.createStyles((theme) => ({
520
520
  button: {
521
521
  borderTopRightRadius: 0,
522
522
  borderBottomRightRadius: 0,
@@ -531,7 +531,7 @@ const useStyles$p = core.createStyles((theme) => ({
531
531
  }
532
532
  }));
533
533
  const SplitButton$4 = (props) => {
534
- const { classes, theme } = useStyles$p();
534
+ const { classes, theme } = useStyles$q();
535
535
  theme.colors[theme.primaryColor][theme.colorScheme === "dark" ? 5 : 6];
536
536
  return /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "sm" }, /* @__PURE__ */ React__namespace.createElement(
537
537
  core.Button,
@@ -559,7 +559,7 @@ const SplitButton$4 = (props) => {
559
559
  ));
560
560
  };
561
561
 
562
- const useStyles$o = core.createStyles((theme) => ({
562
+ const useStyles$p = core.createStyles((theme) => ({
563
563
  wrapper: {
564
564
  display: "flex",
565
565
  alignItems: "center",
@@ -610,7 +610,7 @@ const useStyles$o = core.createStyles((theme) => ({
610
610
  }
611
611
  }));
612
612
  const PlaceholderBanner = (props) => {
613
- const { classes } = useStyles$o();
613
+ const { classes } = useStyles$p();
614
614
  const title = props.title || "Nothing to display";
615
615
  const description = props.description || "We don't have anything to show you here just yet. Add data, check back later, or adjust your search.";
616
616
  return /* @__PURE__ */ React__namespace.createElement("div", { className: classes.wrapper }, /* @__PURE__ */ React__namespace.createElement("div", { className: classes.body }, /* @__PURE__ */ React__namespace.createElement(core.Title, { className: classes.title }, props.loading ? "Loading..." : title), /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "sm", color: "dimmed" }, props.loading ? "Hold on, we're loading your data." : description)), /* @__PURE__ */ React__namespace.createElement(core.Image, { src: `https://cdn.localcivics.io/illustrations/${props.icon}.svg`, className: classes.image }));
@@ -682,7 +682,7 @@ function Table$i(props) {
682
682
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { verticalSpacing: "sm", sx: { minWidth: 700 }, highlightOnHover: true, striped: true }, /* @__PURE__ */ React__namespace.createElement("thead", null, /* @__PURE__ */ React__namespace.createElement("tr", null, /* @__PURE__ */ React__namespace.createElement("th", null, "Lesson Name"), /* @__PURE__ */ React__namespace.createElement("th", null, "Lesson Completion"))), /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
683
683
  }
684
684
 
685
- const useStyles$n = core.createStyles((theme) => ({
685
+ const useStyles$o = core.createStyles((theme) => ({
686
686
  title: {
687
687
  fontSize: 34,
688
688
  fontWeight: 900,
@@ -695,7 +695,7 @@ const useStyles$n = core.createStyles((theme) => ({
695
695
  }
696
696
  }));
697
697
  const Badge = (props) => {
698
- const { classes } = useStyles$n();
698
+ const { classes } = useStyles$o();
699
699
  const [tab, setTab] = React.useState("lessons");
700
700
  const numberOfStudents = props.students.length;
701
701
  const numberOfBadges = numberOfStudents > 0 ? props.students.filter((u) => u.isComplete).length : 0;
@@ -793,7 +793,7 @@ function Table$h(props) {
793
793
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { horizontalSpacing: 0, verticalSpacing: 0, sx: { minWidth: 700 } }, /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
794
794
  }
795
795
 
796
- const useStyles$m = core.createStyles((theme) => ({
796
+ const useStyles$n = core.createStyles((theme) => ({
797
797
  title: {
798
798
  fontSize: 34,
799
799
  fontWeight: 900,
@@ -806,7 +806,7 @@ const useStyles$m = core.createStyles((theme) => ({
806
806
  }
807
807
  }));
808
808
  const Badges = (props) => {
809
- const { classes } = useStyles$m();
809
+ const { classes } = useStyles$n();
810
810
  return /* @__PURE__ */ React__namespace.createElement(core.Container, { size: "lg", py: "xl" }, /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(core.Grid, null, /* @__PURE__ */ React__namespace.createElement(core.Grid.Col, { sm: "auto" }, /* @__PURE__ */ React__namespace.createElement(core.Badge, { variant: "filled", size: "lg" }, "Badges"), /* @__PURE__ */ React__namespace.createElement(core.Title, { order: 2, className: classes.title, mt: "md" }, "Badges and micro-credentials"), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", className: classes.description, mt: "sm" }, "Key milestones that reflect skill development, micro-credentials, or academic progress"))), /* @__PURE__ */ React__namespace.createElement(
811
811
  core.Autocomplete,
812
812
  {
@@ -1076,7 +1076,7 @@ function useSortableData(items, config = { key: "", direction: null }) {
1076
1076
  return { items: sortedItems, requestSort, sortConfig };
1077
1077
  }
1078
1078
 
1079
- const useStyles$l = core.createStyles((theme) => ({
1079
+ const useStyles$m = core.createStyles((theme) => ({
1080
1080
  th: { padding: "0 !important" },
1081
1081
  control: {
1082
1082
  width: "100%",
@@ -1086,10 +1086,10 @@ const useStyles$l = core.createStyles((theme) => ({
1086
1086
  }
1087
1087
  }
1088
1088
  }));
1089
- function Th$1({ children, reversed, sorted, onSort }) {
1090
- const { classes } = useStyles$l();
1089
+ function Th$2({ children, reversed, sorted, onSort }) {
1090
+ const { classes } = useStyles$m();
1091
1091
  const Icon = sorted ? reversed ? icons.IconChevronUp : icons.IconChevronDown : icons.IconSelector;
1092
- return /* @__PURE__ */ React__namespace.createElement("th", { className: classes.th }, /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { onClick: onSort, className: classes.control }, /* @__PURE__ */ React__namespace.createElement(core.Group, { position: "apart" }, /* @__PURE__ */ React__namespace.createElement(core.Text, { weight: 500, size: "sm" }, children), /* @__PURE__ */ React__namespace.createElement(core.Center, null, /* @__PURE__ */ React__namespace.createElement(Icon, { size: 14, stroke: 1.5 })))));
1092
+ return /* @__PURE__ */ React__namespace.createElement("th", { className: classes.th }, /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { onClick: onSort, className: classes.control }, /* @__PURE__ */ React__namespace.createElement(core.Group, { position: "apart", noWrap: true, spacing: "xs" }, /* @__PURE__ */ React__namespace.createElement(core.Text, { weight: 500, size: "sm", sx: { whiteSpace: "nowrap" } }, children), /* @__PURE__ */ React__namespace.createElement(core.Center, null, /* @__PURE__ */ React__namespace.createElement(Icon, { size: 14, stroke: 1.5 })))));
1093
1093
  }
1094
1094
  function Table$b(props) {
1095
1095
  const { items: sortedItems, requestSort, sortConfig } = useSortableData(props.items);
@@ -1122,7 +1122,7 @@ function Table$b(props) {
1122
1122
  }
1123
1123
  ))), /* @__PURE__ */ React__namespace.createElement("td", null, row.badgesEarned), /* @__PURE__ */ React__namespace.createElement("td", null, row.lessonsCompleted), /* @__PURE__ */ React__namespace.createElement("td", null, row.hasAccount && /* @__PURE__ */ React__namespace.createElement(icons.IconCheck, { color: "green" })), /* @__PURE__ */ React__namespace.createElement("td", null, row.lastActivity ? relativeTimeFromDates(row.lastActivity) : ""), /* @__PURE__ */ React__namespace.createElement("td", null, /* @__PURE__ */ React__namespace.createElement(core.Group, { noWrap: true, spacing: 0, position: "right" }, !row.readonly && !!props.onDelete && /* @__PURE__ */ React__namespace.createElement(core.ActionIcon, { color: "red" }, /* @__PURE__ */ React__namespace.createElement(icons.IconTrash, { onClick: () => openDeleteModal(row), size: 16, stroke: 1.5 }))))));
1124
1124
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea, null, /* @__PURE__ */ React__namespace.createElement(core.Table, { verticalSpacing: 20, sx: { minWidth: 700 }, highlightOnHover: true, striped: true }, /* @__PURE__ */ React__namespace.createElement("thead", null, /* @__PURE__ */ React__namespace.createElement("tr", null, /* @__PURE__ */ React__namespace.createElement(
1125
- Th$1,
1125
+ Th$2,
1126
1126
  {
1127
1127
  sorted: sortConfig.key === "givenName",
1128
1128
  reversed: sortConfig.direction === "desc",
@@ -1130,7 +1130,7 @@ function Table$b(props) {
1130
1130
  },
1131
1131
  "Name"
1132
1132
  ), /* @__PURE__ */ React__namespace.createElement(
1133
- Th$1,
1133
+ Th$2,
1134
1134
  {
1135
1135
  sorted: sortConfig.key === "isAdmin",
1136
1136
  reversed: sortConfig.direction === "desc",
@@ -1138,7 +1138,7 @@ function Table$b(props) {
1138
1138
  },
1139
1139
  "Role"
1140
1140
  ), /* @__PURE__ */ React__namespace.createElement(
1141
- Th$1,
1141
+ Th$2,
1142
1142
  {
1143
1143
  sorted: sortConfig.key === "badgesEarned",
1144
1144
  reversed: sortConfig.direction === "desc",
@@ -1146,7 +1146,7 @@ function Table$b(props) {
1146
1146
  },
1147
1147
  "Badges Earned"
1148
1148
  ), /* @__PURE__ */ React__namespace.createElement(
1149
- Th$1,
1149
+ Th$2,
1150
1150
  {
1151
1151
  sorted: sortConfig.key === "lessonsCompleted",
1152
1152
  reversed: sortConfig.direction === "desc",
@@ -1154,7 +1154,7 @@ function Table$b(props) {
1154
1154
  },
1155
1155
  "Lessons Completed"
1156
1156
  ), /* @__PURE__ */ React__namespace.createElement(
1157
- Th$1,
1157
+ Th$2,
1158
1158
  {
1159
1159
  sorted: sortConfig.key === "hasAccount",
1160
1160
  reversed: sortConfig.direction === "desc",
@@ -1162,7 +1162,7 @@ function Table$b(props) {
1162
1162
  },
1163
1163
  "Account Created?"
1164
1164
  ), /* @__PURE__ */ React__namespace.createElement(
1165
- Th$1,
1165
+ Th$2,
1166
1166
  {
1167
1167
  sorted: sortConfig.key === "lastActivity",
1168
1168
  reversed: sortConfig.direction === "desc",
@@ -1172,26 +1172,26 @@ function Table$b(props) {
1172
1172
  ), /* @__PURE__ */ React__namespace.createElement("th", null), " ")), /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
1173
1173
  }
1174
1174
 
1175
- var __defProp$7 = Object.defineProperty;
1176
- var __defProps$4 = Object.defineProperties;
1177
- var __getOwnPropDescs$4 = Object.getOwnPropertyDescriptors;
1178
- var __getOwnPropSymbols$7 = Object.getOwnPropertySymbols;
1179
- var __hasOwnProp$7 = Object.prototype.hasOwnProperty;
1180
- var __propIsEnum$7 = Object.prototype.propertyIsEnumerable;
1181
- var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1182
- var __spreadValues$7 = (a, b) => {
1175
+ var __defProp$8 = Object.defineProperty;
1176
+ var __defProps$5 = Object.defineProperties;
1177
+ var __getOwnPropDescs$5 = Object.getOwnPropertyDescriptors;
1178
+ var __getOwnPropSymbols$8 = Object.getOwnPropertySymbols;
1179
+ var __hasOwnProp$8 = Object.prototype.hasOwnProperty;
1180
+ var __propIsEnum$8 = Object.prototype.propertyIsEnumerable;
1181
+ var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1182
+ var __spreadValues$8 = (a, b) => {
1183
1183
  for (var prop in b || (b = {}))
1184
- if (__hasOwnProp$7.call(b, prop))
1185
- __defNormalProp$7(a, prop, b[prop]);
1186
- if (__getOwnPropSymbols$7)
1187
- for (var prop of __getOwnPropSymbols$7(b)) {
1188
- if (__propIsEnum$7.call(b, prop))
1189
- __defNormalProp$7(a, prop, b[prop]);
1184
+ if (__hasOwnProp$8.call(b, prop))
1185
+ __defNormalProp$8(a, prop, b[prop]);
1186
+ if (__getOwnPropSymbols$8)
1187
+ for (var prop of __getOwnPropSymbols$8(b)) {
1188
+ if (__propIsEnum$8.call(b, prop))
1189
+ __defNormalProp$8(a, prop, b[prop]);
1190
1190
  }
1191
1191
  return a;
1192
1192
  };
1193
- var __spreadProps$4 = (a, b) => __defProps$4(a, __getOwnPropDescs$4(b));
1194
- const useStyles$k = core.createStyles((theme) => ({
1193
+ var __spreadProps$5 = (a, b) => __defProps$5(a, __getOwnPropDescs$5(b));
1194
+ const useStyles$l = core.createStyles((theme) => ({
1195
1195
  title: {
1196
1196
  fontSize: 34,
1197
1197
  fontWeight: 900,
@@ -1224,7 +1224,7 @@ const useStyles$k = core.createStyles((theme) => ({
1224
1224
  }
1225
1225
  }));
1226
1226
  const Class = (props) => {
1227
- const { classes } = useStyles$k();
1227
+ const { classes } = useStyles$l();
1228
1228
  const form$1 = form.useForm({
1229
1229
  initialValues: {
1230
1230
  classId: "",
@@ -1256,27 +1256,27 @@ const Class = (props) => {
1256
1256
  padding: "xl",
1257
1257
  size: "xl"
1258
1258
  },
1259
- /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(DropzoneButton$1, __spreadProps$4(__spreadValues$7({}, props), { close: () => setOpened(false) })), /* @__PURE__ */ React__namespace.createElement(core.Divider, { label: "or", labelPosition: "center", my: "md", variant: "dashed" }), /* @__PURE__ */ React__namespace.createElement("form", { onSubmit: form$1.onSubmit(() => {
1259
+ /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(DropzoneButton$1, __spreadProps$5(__spreadValues$8({}, props), { close: () => setOpened(false) })), /* @__PURE__ */ React__namespace.createElement(core.Divider, { label: "or", labelPosition: "center", my: "md", variant: "dashed" }), /* @__PURE__ */ React__namespace.createElement("form", { onSubmit: form$1.onSubmit(() => {
1260
1260
  const values = form$1.values;
1261
1261
  form$1.reset();
1262
1262
  setOpened(false);
1263
1263
  props.onCreateMembers && props.onCreateMembers([values]);
1264
1264
  }) }, /* @__PURE__ */ React__namespace.createElement(core.Stack, null, /* @__PURE__ */ React__namespace.createElement(
1265
1265
  core.TextInput,
1266
- __spreadValues$7({
1266
+ __spreadValues$8({
1267
1267
  withAsterisk: true,
1268
1268
  label: "Email",
1269
1269
  placeholder: "Email"
1270
1270
  }, form$1.getInputProps("email"))
1271
1271
  ), /* @__PURE__ */ React__namespace.createElement(core.Group, { grow: true }, /* @__PURE__ */ React__namespace.createElement(
1272
1272
  core.TextInput,
1273
- __spreadValues$7({
1273
+ __spreadValues$8({
1274
1274
  label: "Given name",
1275
1275
  placeholder: "Given name"
1276
1276
  }, form$1.getInputProps("givenName"))
1277
1277
  ), /* @__PURE__ */ React__namespace.createElement(
1278
1278
  core.TextInput,
1279
- __spreadValues$7({
1279
+ __spreadValues$8({
1280
1280
  label: "Family name",
1281
1281
  placeholder: "Family name"
1282
1282
  }, form$1.getInputProps("familyName"))
@@ -1325,7 +1325,7 @@ const Class = (props) => {
1325
1325
  ))))));
1326
1326
  };
1327
1327
  const DropzoneButton$1 = (props) => {
1328
- const { classes, theme } = useStyles$k();
1328
+ const { classes, theme } = useStyles$l();
1329
1329
  const openRef = React__namespace.useRef(null);
1330
1330
  const [loading, setLoading] = React__namespace.useState(false);
1331
1331
  const onDrop = React__namespace.useCallback((acceptedFiles) => {
@@ -1371,7 +1371,7 @@ const DropzoneButton$1 = (props) => {
1371
1371
  } }, "Select file"));
1372
1372
  };
1373
1373
 
1374
- const useStyles$j = core.createStyles((theme) => ({
1374
+ const useStyles$k = core.createStyles((theme) => ({
1375
1375
  th: { padding: "0 !important" },
1376
1376
  control: {
1377
1377
  width: "100%",
@@ -1381,10 +1381,10 @@ const useStyles$j = core.createStyles((theme) => ({
1381
1381
  }
1382
1382
  }
1383
1383
  }));
1384
- function Th({ children, reversed, sorted, onSort }) {
1385
- const { classes } = useStyles$j();
1384
+ function Th$1({ children, reversed, sorted, onSort }) {
1385
+ const { classes } = useStyles$k();
1386
1386
  const Icon = sorted ? reversed ? icons.IconChevronUp : icons.IconChevronDown : icons.IconSelector;
1387
- return /* @__PURE__ */ React__namespace.createElement("th", { className: classes.th }, /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { onClick: onSort, className: classes.control }, /* @__PURE__ */ React__namespace.createElement(core.Group, { position: "apart" }, /* @__PURE__ */ React__namespace.createElement(core.Text, { weight: 500, size: "sm" }, children), /* @__PURE__ */ React__namespace.createElement(core.Center, null, /* @__PURE__ */ React__namespace.createElement(Icon, { size: 14, stroke: 1.5 })))));
1387
+ return /* @__PURE__ */ React__namespace.createElement("th", { className: classes.th }, /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { onClick: onSort, className: classes.control }, /* @__PURE__ */ React__namespace.createElement(core.Group, { position: "apart", noWrap: true, spacing: "xs" }, /* @__PURE__ */ React__namespace.createElement(core.Text, { weight: 500, size: "sm", sx: { whiteSpace: "nowrap" } }, children), /* @__PURE__ */ React__namespace.createElement(core.Center, null, /* @__PURE__ */ React__namespace.createElement(Icon, { size: 14, stroke: 1.5 })))));
1388
1388
  }
1389
1389
  function Table$a(props) {
1390
1390
  const { items: sortedItems, requestSort, sortConfig } = useSortableData(props.items);
@@ -1409,7 +1409,7 @@ function Table$a(props) {
1409
1409
  });
1410
1410
  const rows = sortedItems.map((row) => /* @__PURE__ */ React__namespace.createElement("tr", { key: row.classId }, /* @__PURE__ */ React__namespace.createElement("td", null, /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { component: reactRouterDom.Link, to: row.href }, /* @__PURE__ */ React__namespace.createElement(core.Text, { size: 14 }, row.name))), /* @__PURE__ */ React__namespace.createElement("td", null, /* @__PURE__ */ React__namespace.createElement(core.Text, { size: 14 }, row.description)), /* @__PURE__ */ React__namespace.createElement("td", null, /* @__PURE__ */ React__namespace.createElement(core.Text, { size: 14 }, row.numberOfStudents || 0)), /* @__PURE__ */ React__namespace.createElement("td", null, /* @__PURE__ */ React__namespace.createElement(core.Group, { noWrap: true, spacing: 0, position: "right" }, /* @__PURE__ */ React__namespace.createElement(core.ActionIcon, { color: "red" }, /* @__PURE__ */ React__namespace.createElement(icons.IconTrash, { onClick: () => openDeleteModal(row), size: 16, stroke: 1.5 }))))));
1411
1411
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { verticalSpacing: 20, sx: { minWidth: 700 }, highlightOnHover: true, striped: true }, /* @__PURE__ */ React__namespace.createElement("thead", null, /* @__PURE__ */ React__namespace.createElement("tr", null, /* @__PURE__ */ React__namespace.createElement(
1412
- Th,
1412
+ Th$1,
1413
1413
  {
1414
1414
  sorted: sortConfig.key === "name",
1415
1415
  reversed: sortConfig.direction === "desc",
@@ -1417,7 +1417,7 @@ function Table$a(props) {
1417
1417
  },
1418
1418
  "Class Name"
1419
1419
  ), /* @__PURE__ */ React__namespace.createElement("th", { style: { padding: "7px 16px" } }, /* @__PURE__ */ React__namespace.createElement(core.Text, { weight: 500, size: "sm" }, "Description")), /* @__PURE__ */ React__namespace.createElement(
1420
- Th,
1420
+ Th$1,
1421
1421
  {
1422
1422
  sorted: sortConfig.key === "numberOfStudents",
1423
1423
  reversed: sortConfig.direction === "desc",
@@ -1427,23 +1427,23 @@ function Table$a(props) {
1427
1427
  ), /* @__PURE__ */ React__namespace.createElement("th", null))), /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
1428
1428
  }
1429
1429
 
1430
- var __defProp$6 = Object.defineProperty;
1431
- var __getOwnPropSymbols$6 = Object.getOwnPropertySymbols;
1432
- var __hasOwnProp$6 = Object.prototype.hasOwnProperty;
1433
- var __propIsEnum$6 = Object.prototype.propertyIsEnumerable;
1434
- var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1435
- var __spreadValues$6 = (a, b) => {
1430
+ var __defProp$7 = Object.defineProperty;
1431
+ var __getOwnPropSymbols$7 = Object.getOwnPropertySymbols;
1432
+ var __hasOwnProp$7 = Object.prototype.hasOwnProperty;
1433
+ var __propIsEnum$7 = Object.prototype.propertyIsEnumerable;
1434
+ var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1435
+ var __spreadValues$7 = (a, b) => {
1436
1436
  for (var prop in b || (b = {}))
1437
- if (__hasOwnProp$6.call(b, prop))
1438
- __defNormalProp$6(a, prop, b[prop]);
1439
- if (__getOwnPropSymbols$6)
1440
- for (var prop of __getOwnPropSymbols$6(b)) {
1441
- if (__propIsEnum$6.call(b, prop))
1442
- __defNormalProp$6(a, prop, b[prop]);
1437
+ if (__hasOwnProp$7.call(b, prop))
1438
+ __defNormalProp$7(a, prop, b[prop]);
1439
+ if (__getOwnPropSymbols$7)
1440
+ for (var prop of __getOwnPropSymbols$7(b)) {
1441
+ if (__propIsEnum$7.call(b, prop))
1442
+ __defNormalProp$7(a, prop, b[prop]);
1443
1443
  }
1444
1444
  return a;
1445
1445
  };
1446
- const useStyles$i = core.createStyles((theme) => ({
1446
+ const useStyles$j = core.createStyles((theme) => ({
1447
1447
  title: {
1448
1448
  fontSize: 34,
1449
1449
  fontWeight: 900,
@@ -1456,7 +1456,7 @@ const useStyles$i = core.createStyles((theme) => ({
1456
1456
  }
1457
1457
  }));
1458
1458
  const Classes = (props) => {
1459
- const { classes } = useStyles$i();
1459
+ const { classes } = useStyles$j();
1460
1460
  const form$1 = form.useForm({
1461
1461
  initialValues: {
1462
1462
  classId: "",
@@ -1486,14 +1486,14 @@ const Classes = (props) => {
1486
1486
  props.onCreateClass && props.onCreateClass(values);
1487
1487
  }) }, /* @__PURE__ */ React__namespace.createElement(core.Stack, null, /* @__PURE__ */ React__namespace.createElement(
1488
1488
  core.TextInput,
1489
- __spreadValues$6({
1489
+ __spreadValues$7({
1490
1490
  withAsterisk: true,
1491
1491
  label: "Name",
1492
1492
  placeholder: "Class name"
1493
1493
  }, form$1.getInputProps("name"))
1494
1494
  ), /* @__PURE__ */ React__namespace.createElement(
1495
1495
  core.TextInput,
1496
- __spreadValues$6({
1496
+ __spreadValues$7({
1497
1497
  label: "Description",
1498
1498
  placeholder: "A class for my first period English students"
1499
1499
  }, form$1.getInputProps("description"))
@@ -1527,7 +1527,7 @@ const Classes = (props) => {
1527
1527
  ))))));
1528
1528
  };
1529
1529
 
1530
- const useStyles$h = core.createStyles((theme) => ({
1530
+ const useStyles$i = core.createStyles((theme) => ({
1531
1531
  title: {
1532
1532
  fontSize: 34,
1533
1533
  fontWeight: 900,
@@ -1541,7 +1541,7 @@ const useStyles$h = core.createStyles((theme) => ({
1541
1541
  }
1542
1542
  }));
1543
1543
  const UserInfo = (props) => {
1544
- const { classes } = useStyles$h();
1544
+ const { classes } = useStyles$i();
1545
1545
  return /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement(core.Title, { className: classes.title }, props.name), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", className: classes.description, mt: "xs" }, props.impactStatement));
1546
1546
  };
1547
1547
 
@@ -1679,7 +1679,7 @@ const Student = (props) => {
1679
1679
  ))))));
1680
1680
  };
1681
1681
 
1682
- const useStyles$g = core.createStyles((theme, props) => {
1682
+ const useStyles$h = core.createStyles((theme, props) => {
1683
1683
  const from = props.from || "blue";
1684
1684
  const to = props.to || "green";
1685
1685
  return {
@@ -1707,7 +1707,7 @@ const useStyles$g = core.createStyles((theme, props) => {
1707
1707
  };
1708
1708
  });
1709
1709
  function CardGradient(props) {
1710
- const { classes } = useStyles$g(props);
1710
+ const { classes } = useStyles$h(props);
1711
1711
  const from = props.from || "blue";
1712
1712
  const to = props.to || "green";
1713
1713
  const icon = props.icon || /* @__PURE__ */ React__namespace.createElement(icons.IconColorSwatch, { size: 28, stroke: 1.5 });
@@ -1723,35 +1723,35 @@ function CardGradient(props) {
1723
1723
  ), /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "xl", weight: 500, mt: "md" }, props.title), /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "sm", mt: "sm", color: "dimmed" }, props.description));
1724
1724
  }
1725
1725
 
1726
- var __defProp$5 = Object.defineProperty;
1727
- var __getOwnPropSymbols$5 = Object.getOwnPropertySymbols;
1728
- var __hasOwnProp$5 = Object.prototype.hasOwnProperty;
1729
- var __propIsEnum$5 = Object.prototype.propertyIsEnumerable;
1730
- var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1731
- var __spreadValues$5 = (a, b) => {
1726
+ var __defProp$6 = Object.defineProperty;
1727
+ var __getOwnPropSymbols$6 = Object.getOwnPropertySymbols;
1728
+ var __hasOwnProp$6 = Object.prototype.hasOwnProperty;
1729
+ var __propIsEnum$6 = Object.prototype.propertyIsEnumerable;
1730
+ var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1731
+ var __spreadValues$6 = (a, b) => {
1732
1732
  for (var prop in b || (b = {}))
1733
- if (__hasOwnProp$5.call(b, prop))
1734
- __defNormalProp$5(a, prop, b[prop]);
1735
- if (__getOwnPropSymbols$5)
1736
- for (var prop of __getOwnPropSymbols$5(b)) {
1737
- if (__propIsEnum$5.call(b, prop))
1738
- __defNormalProp$5(a, prop, b[prop]);
1733
+ if (__hasOwnProp$6.call(b, prop))
1734
+ __defNormalProp$6(a, prop, b[prop]);
1735
+ if (__getOwnPropSymbols$6)
1736
+ for (var prop of __getOwnPropSymbols$6(b)) {
1737
+ if (__propIsEnum$6.call(b, prop))
1738
+ __defNormalProp$6(a, prop, b[prop]);
1739
1739
  }
1740
1740
  return a;
1741
1741
  };
1742
1742
  var __objRest$1 = (source, exclude) => {
1743
1743
  var target = {};
1744
1744
  for (var prop in source)
1745
- if (__hasOwnProp$5.call(source, prop) && exclude.indexOf(prop) < 0)
1745
+ if (__hasOwnProp$6.call(source, prop) && exclude.indexOf(prop) < 0)
1746
1746
  target[prop] = source[prop];
1747
- if (source != null && __getOwnPropSymbols$5)
1748
- for (var prop of __getOwnPropSymbols$5(source)) {
1749
- if (exclude.indexOf(prop) < 0 && __propIsEnum$5.call(source, prop))
1747
+ if (source != null && __getOwnPropSymbols$6)
1748
+ for (var prop of __getOwnPropSymbols$6(source)) {
1749
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$6.call(source, prop))
1750
1750
  target[prop] = source[prop];
1751
1751
  }
1752
1752
  return target;
1753
1753
  };
1754
- const useStyles$f = core.createStyles((theme) => ({
1754
+ const useStyles$g = core.createStyles((theme) => ({
1755
1755
  card: {
1756
1756
  height: 240,
1757
1757
  backgroundSize: "cover",
@@ -1796,7 +1796,7 @@ const TenantBanner = (_a) => {
1796
1796
  "className",
1797
1797
  "code"
1798
1798
  ]);
1799
- const { classes, cx, theme } = useStyles$f();
1799
+ const { classes, cx, theme } = useStyles$g();
1800
1800
  const handleCopy = async () => {
1801
1801
  if (!code)
1802
1802
  return;
@@ -1813,9 +1813,9 @@ const TenantBanner = (_a) => {
1813
1813
  };
1814
1814
  return /* @__PURE__ */ React__namespace.createElement(
1815
1815
  core.Card,
1816
- __spreadValues$5({
1816
+ __spreadValues$6({
1817
1817
  radius: "md",
1818
- style: __spreadValues$5({ backgroundImage: `url(${image})` }, style),
1818
+ style: __spreadValues$6({ backgroundImage: `url(${image})` }, style),
1819
1819
  className: cx(classes.card, className)
1820
1820
  }, others),
1821
1821
  /* @__PURE__ */ React__namespace.createElement(
@@ -1913,7 +1913,7 @@ function Table$6(props) {
1913
1913
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { verticalSpacing: "sm", sx: { minWidth: 700 }, highlightOnHover: true, striped: true }, /* @__PURE__ */ React__namespace.createElement("thead", null, /* @__PURE__ */ React__namespace.createElement("tr", null, /* @__PURE__ */ React__namespace.createElement("th", null, "Student Name"), /* @__PURE__ */ React__namespace.createElement("th", null, "Reflection"), /* @__PURE__ */ React__namespace.createElement("th", null, "Rating"))), /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
1914
1914
  }
1915
1915
 
1916
- const useStyles$e = core.createStyles((theme) => ({
1916
+ const useStyles$f = core.createStyles((theme) => ({
1917
1917
  button: {
1918
1918
  borderTopRightRadius: 0,
1919
1919
  borderBottomRightRadius: 0,
@@ -1928,7 +1928,7 @@ const useStyles$e = core.createStyles((theme) => ({
1928
1928
  }
1929
1929
  }));
1930
1930
  const SplitButton$2 = (props) => {
1931
- const { classes, theme } = useStyles$e();
1931
+ const { classes, theme } = useStyles$f();
1932
1932
  theme.colors[theme.primaryColor][theme.colorScheme === "dark" ? 5 : 6];
1933
1933
  return /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "sm" }, /* @__PURE__ */ React__namespace.createElement(
1934
1934
  core.Button,
@@ -2072,7 +2072,7 @@ function Stack$1(props) {
2072
2072
  }
2073
2073
  const truncateWithEllipses = (text, max) => text.substr(0, max - 1) + (text.length > max ? "&hellip;" : "");
2074
2074
 
2075
- const useStyles$d = core.createStyles((theme) => ({
2075
+ const useStyles$e = core.createStyles((theme) => ({
2076
2076
  title: {
2077
2077
  fontSize: 34,
2078
2078
  fontWeight: 900,
@@ -2085,7 +2085,7 @@ const useStyles$d = core.createStyles((theme) => ({
2085
2085
  }
2086
2086
  }));
2087
2087
  const Lesson = (props) => {
2088
- const { classes } = useStyles$d();
2088
+ const { classes } = useStyles$e();
2089
2089
  const [tab, setTab] = React.useState("question");
2090
2090
  const numberOfStudents = props.students.length;
2091
2091
  const numberOfLessons = numberOfStudents > 0 ? props.students.filter((u) => u.isComplete).length : 0;
@@ -2229,7 +2229,7 @@ function Table$4(props) {
2229
2229
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { horizontalSpacing: 0, verticalSpacing: 0, sx: { minWidth: 700 } }, /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
2230
2230
  }
2231
2231
 
2232
- const useStyles$c = core.createStyles((theme) => ({
2232
+ const useStyles$d = core.createStyles((theme) => ({
2233
2233
  title: {
2234
2234
  fontSize: 34,
2235
2235
  fontWeight: 900,
@@ -2242,7 +2242,7 @@ const useStyles$c = core.createStyles((theme) => ({
2242
2242
  }
2243
2243
  }));
2244
2244
  const Lessons = (props) => {
2245
- const { classes } = useStyles$c();
2245
+ const { classes } = useStyles$d();
2246
2246
  return /* @__PURE__ */ React__namespace.createElement(core.Container, { size: "lg", py: "xl" }, /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(core.Grid, null, /* @__PURE__ */ React__namespace.createElement(core.Grid.Col, { sm: "auto" }, /* @__PURE__ */ React__namespace.createElement(core.Badge, { variant: "filled", size: "lg" }, "Lessons"), /* @__PURE__ */ React__namespace.createElement(core.Title, { order: 2, className: classes.title, mt: "md" }, "Lessons"), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", className: classes.description, mt: "sm" }, "Bite-sized activities and learning experiences accelerating students achievement"))), /* @__PURE__ */ React__namespace.createElement(
2247
2247
  core.Autocomplete,
2248
2248
  {
@@ -2259,7 +2259,7 @@ const Lessons = (props) => {
2259
2259
  ))));
2260
2260
  };
2261
2261
 
2262
- const useStyles$b = core.createStyles((theme) => ({
2262
+ const useStyles$c = core.createStyles((theme) => ({
2263
2263
  title: {
2264
2264
  fontSize: 22,
2265
2265
  fontWeight: 900,
@@ -2278,7 +2278,7 @@ const useStyles$b = core.createStyles((theme) => ({
2278
2278
  }
2279
2279
  }));
2280
2280
  function AccessCode(props) {
2281
- const { classes } = useStyles$b();
2281
+ const { classes } = useStyles$c();
2282
2282
  return /* @__PURE__ */ React__namespace.createElement(core.Container, { mx: "0", px: "0", size: 460, my: 30 }, /* @__PURE__ */ React__namespace.createElement(core.Title, { className: classes.title }, "Access code"), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", size: "sm" }, "Grant access to join your organization"), /* @__PURE__ */ React__namespace.createElement(core.Paper, { withBorder: true, shadow: "md", p: 30, radius: "md", mt: "xl" }, /* @__PURE__ */ React__namespace.createElement(core.TextInput, { value: props.value, readOnly: true }), /* @__PURE__ */ React__namespace.createElement(core.Group, { position: "apart", mt: "lg", className: classes.controls }, /* @__PURE__ */ React__namespace.createElement(
2283
2283
  core.Anchor,
2284
2284
  {
@@ -2306,7 +2306,7 @@ const monthNames = [
2306
2306
  "November",
2307
2307
  "December"
2308
2308
  ];
2309
- const useStyles$a = core.createStyles((theme) => ({
2309
+ const useStyles$b = core.createStyles((theme) => ({
2310
2310
  title: {
2311
2311
  fontSize: 34,
2312
2312
  fontWeight: 900,
@@ -2336,7 +2336,7 @@ const useStyles$a = core.createStyles((theme) => ({
2336
2336
  }
2337
2337
  }));
2338
2338
  const Organization = (props) => {
2339
- const { classes } = useStyles$a();
2339
+ const { classes } = useStyles$b();
2340
2340
  return /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement(core.Container, { size: "lg", py: "xl" }, /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(core.Grid, null, /* @__PURE__ */ React__namespace.createElement(core.Grid.Col, { sm: "auto" }, /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { onClick: props.onBackClick }, /* @__PURE__ */ React__namespace.createElement(
2341
2341
  core.Badge,
2342
2342
  {
@@ -2362,7 +2362,7 @@ const Organization = (props) => {
2362
2362
  ] }))))));
2363
2363
  };
2364
2364
 
2365
- const useStyles$9 = core.createStyles((theme) => ({
2365
+ const useStyles$a = core.createStyles((theme) => ({
2366
2366
  button: {
2367
2367
  borderTopRightRadius: 0,
2368
2368
  borderBottomRightRadius: 0,
@@ -2377,7 +2377,7 @@ const useStyles$9 = core.createStyles((theme) => ({
2377
2377
  }
2378
2378
  }));
2379
2379
  const SplitButton$1 = (props) => {
2380
- const { classes, theme } = useStyles$9();
2380
+ const { classes, theme } = useStyles$a();
2381
2381
  const menuIconColor = theme.colors[theme.primaryColor][theme.colorScheme === "dark" ? 5 : 6];
2382
2382
  const hasMenu = !!props.withOrganizationLink;
2383
2383
  return /* @__PURE__ */ React__namespace.createElement(core.Group, { noWrap: true, spacing: 0 }, /* @__PURE__ */ React__namespace.createElement(
@@ -2439,26 +2439,26 @@ function Table$3(props) {
2439
2439
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea, null, /* @__PURE__ */ React__namespace.createElement(core.Table, { verticalSpacing: 20, sx: { minWidth: 700 }, highlightOnHover: true, striped: true }, /* @__PURE__ */ React__namespace.createElement("thead", null, /* @__PURE__ */ React__namespace.createElement("tr", null, /* @__PURE__ */ React__namespace.createElement("th", null, "Name"), /* @__PURE__ */ React__namespace.createElement("th", null, "Role"), /* @__PURE__ */ React__namespace.createElement("th", null, "Account Created?"), /* @__PURE__ */ React__namespace.createElement("th", null, "# of Classes"), /* @__PURE__ */ React__namespace.createElement("th", null, "Last Active"), /* @__PURE__ */ React__namespace.createElement("th", null))), /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
2440
2440
  }
2441
2441
 
2442
- var __defProp$4 = Object.defineProperty;
2443
- var __defProps$3 = Object.defineProperties;
2444
- var __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors;
2445
- var __getOwnPropSymbols$4 = Object.getOwnPropertySymbols;
2446
- var __hasOwnProp$4 = Object.prototype.hasOwnProperty;
2447
- var __propIsEnum$4 = Object.prototype.propertyIsEnumerable;
2448
- var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2449
- var __spreadValues$4 = (a, b) => {
2442
+ var __defProp$5 = Object.defineProperty;
2443
+ var __defProps$4 = Object.defineProperties;
2444
+ var __getOwnPropDescs$4 = Object.getOwnPropertyDescriptors;
2445
+ var __getOwnPropSymbols$5 = Object.getOwnPropertySymbols;
2446
+ var __hasOwnProp$5 = Object.prototype.hasOwnProperty;
2447
+ var __propIsEnum$5 = Object.prototype.propertyIsEnumerable;
2448
+ var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2449
+ var __spreadValues$5 = (a, b) => {
2450
2450
  for (var prop in b || (b = {}))
2451
- if (__hasOwnProp$4.call(b, prop))
2452
- __defNormalProp$4(a, prop, b[prop]);
2453
- if (__getOwnPropSymbols$4)
2454
- for (var prop of __getOwnPropSymbols$4(b)) {
2455
- if (__propIsEnum$4.call(b, prop))
2456
- __defNormalProp$4(a, prop, b[prop]);
2451
+ if (__hasOwnProp$5.call(b, prop))
2452
+ __defNormalProp$5(a, prop, b[prop]);
2453
+ if (__getOwnPropSymbols$5)
2454
+ for (var prop of __getOwnPropSymbols$5(b)) {
2455
+ if (__propIsEnum$5.call(b, prop))
2456
+ __defNormalProp$5(a, prop, b[prop]);
2457
2457
  }
2458
2458
  return a;
2459
2459
  };
2460
- var __spreadProps$3 = (a, b) => __defProps$3(a, __getOwnPropDescs$3(b));
2461
- const useStyles$8 = core.createStyles((theme) => ({
2460
+ var __spreadProps$4 = (a, b) => __defProps$4(a, __getOwnPropDescs$4(b));
2461
+ const useStyles$9 = core.createStyles((theme) => ({
2462
2462
  title: {
2463
2463
  fontSize: 34,
2464
2464
  fontWeight: 900,
@@ -2488,7 +2488,7 @@ const useStyles$8 = core.createStyles((theme) => ({
2488
2488
  }
2489
2489
  }));
2490
2490
  const People = (props) => {
2491
- const { classes } = useStyles$8();
2491
+ const { classes } = useStyles$9();
2492
2492
  const form$1 = form.useForm({
2493
2493
  initialValues: {
2494
2494
  userId: "",
@@ -2519,27 +2519,27 @@ const People = (props) => {
2519
2519
  padding: "xl",
2520
2520
  size: "xl"
2521
2521
  },
2522
- /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(DropzoneButton, __spreadProps$3(__spreadValues$4({}, props), { close: () => setOpened(false) })), /* @__PURE__ */ React__namespace.createElement(core.Divider, { label: "or", labelPosition: "center", my: "md", variant: "dashed" }), /* @__PURE__ */ React__namespace.createElement("form", { onSubmit: form$1.onSubmit(() => {
2522
+ /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(DropzoneButton, __spreadProps$4(__spreadValues$5({}, props), { close: () => setOpened(false) })), /* @__PURE__ */ React__namespace.createElement(core.Divider, { label: "or", labelPosition: "center", my: "md", variant: "dashed" }), /* @__PURE__ */ React__namespace.createElement("form", { onSubmit: form$1.onSubmit(() => {
2523
2523
  const values = form$1.values;
2524
2524
  form$1.reset();
2525
2525
  setOpened(false);
2526
2526
  props.onCreateUsers && props.onCreateUsers([values]);
2527
2527
  }) }, /* @__PURE__ */ React__namespace.createElement(core.Stack, null, /* @__PURE__ */ React__namespace.createElement(
2528
2528
  core.TextInput,
2529
- __spreadValues$4({
2529
+ __spreadValues$5({
2530
2530
  withAsterisk: true,
2531
2531
  label: "Email",
2532
2532
  placeholder: "Email"
2533
2533
  }, form$1.getInputProps("email"))
2534
2534
  ), /* @__PURE__ */ React__namespace.createElement(core.Group, { grow: true }, /* @__PURE__ */ React__namespace.createElement(
2535
2535
  core.TextInput,
2536
- __spreadValues$4({
2536
+ __spreadValues$5({
2537
2537
  label: "Given name",
2538
2538
  placeholder: "Given name"
2539
2539
  }, form$1.getInputProps("givenName"))
2540
2540
  ), /* @__PURE__ */ React__namespace.createElement(
2541
2541
  core.TextInput,
2542
- __spreadValues$4({
2542
+ __spreadValues$5({
2543
2543
  label: "Family name",
2544
2544
  placeholder: "Family name"
2545
2545
  }, form$1.getInputProps("familyName"))
@@ -2592,7 +2592,7 @@ const People = (props) => {
2592
2592
  ))))));
2593
2593
  };
2594
2594
  const DropzoneButton = (props) => {
2595
- const { classes, theme } = useStyles$8();
2595
+ const { classes, theme } = useStyles$9();
2596
2596
  const openRef = React__namespace.useRef(null);
2597
2597
  const [loading, setLoading] = React__namespace.useState(false);
2598
2598
  const onDrop = React__namespace.useCallback((acceptedFiles) => {
@@ -2638,7 +2638,7 @@ const DropzoneButton = (props) => {
2638
2638
  } }, "Select file"));
2639
2639
  };
2640
2640
 
2641
- const useStyles$7 = core.createStyles((theme) => ({
2641
+ const useStyles$8 = core.createStyles((theme) => ({
2642
2642
  form: {
2643
2643
  backgroundColor: theme.white,
2644
2644
  padding: theme.spacing.xl,
@@ -2701,7 +2701,7 @@ const useStyles$7 = core.createStyles((theme) => ({
2701
2701
  }
2702
2702
  }));
2703
2703
  const StartAnonymousLesson = (props) => {
2704
- const { classes } = useStyles$7();
2704
+ const { classes } = useStyles$8();
2705
2705
  const [name, setName] = React__namespace.useState("");
2706
2706
  return /* @__PURE__ */ React__namespace.createElement("div", { className: classes.wrapper }, /* @__PURE__ */ React__namespace.createElement(core.Container, null, /* @__PURE__ */ React__namespace.createElement(core.SimpleGrid, { maw: 960, cols: 2, spacing: 15, breakpoints: [{ maxWidth: "sm", cols: 1 }] }, /* @__PURE__ */ React__namespace.createElement("div", { className: classes.content }, /* @__PURE__ */ React__namespace.createElement(core.Badge, { color: "violet" }, "Community"), /* @__PURE__ */ React__namespace.createElement(core.Title, { className: classes.title }, props.title), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", mt: "md" }, props.description), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", mt: "md" }, "You are now part of ", `${props.educatorName}'s`, " Class")), /* @__PURE__ */ React__namespace.createElement("div", { className: classes.form }, /* @__PURE__ */ React__namespace.createElement(
2707
2707
  core.TextInput,
@@ -2725,24 +2725,24 @@ const StartAnonymousLesson = (props) => {
2725
2725
  ))))));
2726
2726
  };
2727
2727
 
2728
- var __defProp$3 = Object.defineProperty;
2729
- var __getOwnPropSymbols$3 = Object.getOwnPropertySymbols;
2730
- var __hasOwnProp$3 = Object.prototype.hasOwnProperty;
2731
- var __propIsEnum$3 = Object.prototype.propertyIsEnumerable;
2732
- var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2733
- var __spreadValues$3 = (a, b) => {
2728
+ var __defProp$4 = Object.defineProperty;
2729
+ var __getOwnPropSymbols$4 = Object.getOwnPropertySymbols;
2730
+ var __hasOwnProp$4 = Object.prototype.hasOwnProperty;
2731
+ var __propIsEnum$4 = Object.prototype.propertyIsEnumerable;
2732
+ var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2733
+ var __spreadValues$4 = (a, b) => {
2734
2734
  for (var prop in b || (b = {}))
2735
- if (__hasOwnProp$3.call(b, prop))
2736
- __defNormalProp$3(a, prop, b[prop]);
2737
- if (__getOwnPropSymbols$3)
2738
- for (var prop of __getOwnPropSymbols$3(b)) {
2739
- if (__propIsEnum$3.call(b, prop))
2740
- __defNormalProp$3(a, prop, b[prop]);
2735
+ if (__hasOwnProp$4.call(b, prop))
2736
+ __defNormalProp$4(a, prop, b[prop]);
2737
+ if (__getOwnPropSymbols$4)
2738
+ for (var prop of __getOwnPropSymbols$4(b)) {
2739
+ if (__propIsEnum$4.call(b, prop))
2740
+ __defNormalProp$4(a, prop, b[prop]);
2741
2741
  }
2742
2742
  return a;
2743
2743
  };
2744
2744
  const BadgeGrid = (props) => {
2745
- const badges = props.badges.map((b) => /* @__PURE__ */ React__namespace.createElement(TaskCard, __spreadValues$3({ key: b.title }, b)));
2745
+ const badges = props.badges.map((b) => /* @__PURE__ */ React__namespace.createElement(TaskCard, __spreadValues$4({ key: b.title }, b)));
2746
2746
  return /* @__PURE__ */ React__namespace.createElement(core.SimpleGrid, { cols: 4, breakpoints: [{ maxWidth: "sm", cols: 1 }, { maxWidth: "md", cols: 3 }] }, badges);
2747
2747
  };
2748
2748
  function TaskCard(props) {
@@ -2758,7 +2758,7 @@ function TaskCard(props) {
2758
2758
  ));
2759
2759
  }
2760
2760
 
2761
- const useStyles$6 = core.createStyles((theme) => ({
2761
+ const useStyles$7 = core.createStyles((theme) => ({
2762
2762
  action: {
2763
2763
  backgroundColor: "inherit",
2764
2764
  ":hover": {
@@ -2777,7 +2777,7 @@ const useStyles$6 = core.createStyles((theme) => ({
2777
2777
  }
2778
2778
  }));
2779
2779
  const TrialHome = (props) => {
2780
- const { classes } = useStyles$6();
2780
+ const { classes } = useStyles$7();
2781
2781
  return /* @__PURE__ */ React__namespace.createElement(core.Container, { size: "lg" }, /* @__PURE__ */ React__namespace.createElement(core.Badge, null, props.daysRemaining, " day", props.daysRemaining !== 1 ? "s" : "", " left"), /* @__PURE__ */ React__namespace.createElement(
2782
2782
  core.Button,
2783
2783
  {
@@ -2806,38 +2806,38 @@ const TrialHome = (props) => {
2806
2806
  )), /* @__PURE__ */ React__namespace.createElement(core.Title, { maw: 500, mb: 20, mt: 20, className: classes.title }, "Based on the tags you selected, check out these lessons to get started with your students!"), /* @__PURE__ */ React__namespace.createElement(BadgeGrid, { onAssign: props.onAssign, badges: props.badges })));
2807
2807
  };
2808
2808
 
2809
- var __defProp$2 = Object.defineProperty;
2810
- var __defProps$2 = Object.defineProperties;
2811
- var __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors;
2812
- var __getOwnPropSymbols$2 = Object.getOwnPropertySymbols;
2813
- var __hasOwnProp$2 = Object.prototype.hasOwnProperty;
2814
- var __propIsEnum$2 = Object.prototype.propertyIsEnumerable;
2815
- var __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2816
- var __spreadValues$2 = (a, b) => {
2809
+ var __defProp$3 = Object.defineProperty;
2810
+ var __defProps$3 = Object.defineProperties;
2811
+ var __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors;
2812
+ var __getOwnPropSymbols$3 = Object.getOwnPropertySymbols;
2813
+ var __hasOwnProp$3 = Object.prototype.hasOwnProperty;
2814
+ var __propIsEnum$3 = Object.prototype.propertyIsEnumerable;
2815
+ var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2816
+ var __spreadValues$3 = (a, b) => {
2817
2817
  for (var prop in b || (b = {}))
2818
- if (__hasOwnProp$2.call(b, prop))
2819
- __defNormalProp$2(a, prop, b[prop]);
2820
- if (__getOwnPropSymbols$2)
2821
- for (var prop of __getOwnPropSymbols$2(b)) {
2822
- if (__propIsEnum$2.call(b, prop))
2823
- __defNormalProp$2(a, prop, b[prop]);
2818
+ if (__hasOwnProp$3.call(b, prop))
2819
+ __defNormalProp$3(a, prop, b[prop]);
2820
+ if (__getOwnPropSymbols$3)
2821
+ for (var prop of __getOwnPropSymbols$3(b)) {
2822
+ if (__propIsEnum$3.call(b, prop))
2823
+ __defNormalProp$3(a, prop, b[prop]);
2824
2824
  }
2825
2825
  return a;
2826
2826
  };
2827
- var __spreadProps$2 = (a, b) => __defProps$2(a, __getOwnPropDescs$2(b));
2827
+ var __spreadProps$3 = (a, b) => __defProps$3(a, __getOwnPropDescs$3(b));
2828
2828
  var __objRest = (source, exclude) => {
2829
2829
  var target = {};
2830
2830
  for (var prop in source)
2831
- if (__hasOwnProp$2.call(source, prop) && exclude.indexOf(prop) < 0)
2831
+ if (__hasOwnProp$3.call(source, prop) && exclude.indexOf(prop) < 0)
2832
2832
  target[prop] = source[prop];
2833
- if (source != null && __getOwnPropSymbols$2)
2834
- for (var prop of __getOwnPropSymbols$2(source)) {
2835
- if (exclude.indexOf(prop) < 0 && __propIsEnum$2.call(source, prop))
2833
+ if (source != null && __getOwnPropSymbols$3)
2834
+ for (var prop of __getOwnPropSymbols$3(source)) {
2835
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$3.call(source, prop))
2836
2836
  target[prop] = source[prop];
2837
2837
  }
2838
2838
  return target;
2839
2839
  };
2840
- const useStyles$5 = core.createStyles((theme, { checked }) => ({
2840
+ const useStyles$6 = core.createStyles((theme, { checked }) => ({
2841
2841
  button: {
2842
2842
  display: "flex",
2843
2843
  alignItems: "center",
@@ -2879,10 +2879,10 @@ function ImageCheckbox(_a) {
2879
2879
  finalValue: false,
2880
2880
  onChange
2881
2881
  });
2882
- const { classes, cx } = useStyles$5({ checked: value });
2882
+ const { classes, cx } = useStyles$6({ checked: value });
2883
2883
  return /* @__PURE__ */ React__namespace.createElement(
2884
2884
  core.UnstyledButton,
2885
- __spreadProps$2(__spreadValues$2({}, others), {
2885
+ __spreadProps$3(__spreadValues$3({}, others), {
2886
2886
  onClick: () => handleChange(!value),
2887
2887
  className: cx(classes.button, className)
2888
2888
  }),
@@ -2903,7 +2903,7 @@ function ImageCheckbox(_a) {
2903
2903
  function SelectGrid(props) {
2904
2904
  const items = props.items.map((item) => /* @__PURE__ */ React__namespace.createElement(
2905
2905
  ImageCheckbox,
2906
- __spreadProps$2(__spreadValues$2({}, item), {
2906
+ __spreadProps$3(__spreadValues$3({}, item), {
2907
2907
  key: item.title,
2908
2908
  onChange: (checked) => props.onChange(item.title, checked)
2909
2909
  })
@@ -2921,26 +2921,26 @@ function SelectGrid(props) {
2921
2921
  );
2922
2922
  }
2923
2923
 
2924
- var __defProp$1 = Object.defineProperty;
2925
- var __defProps$1 = Object.defineProperties;
2926
- var __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors;
2927
- var __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;
2928
- var __hasOwnProp$1 = Object.prototype.hasOwnProperty;
2929
- var __propIsEnum$1 = Object.prototype.propertyIsEnumerable;
2930
- var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2931
- var __spreadValues$1 = (a, b) => {
2924
+ var __defProp$2 = Object.defineProperty;
2925
+ var __defProps$2 = Object.defineProperties;
2926
+ var __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors;
2927
+ var __getOwnPropSymbols$2 = Object.getOwnPropertySymbols;
2928
+ var __hasOwnProp$2 = Object.prototype.hasOwnProperty;
2929
+ var __propIsEnum$2 = Object.prototype.propertyIsEnumerable;
2930
+ var __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2931
+ var __spreadValues$2 = (a, b) => {
2932
2932
  for (var prop in b || (b = {}))
2933
- if (__hasOwnProp$1.call(b, prop))
2934
- __defNormalProp$1(a, prop, b[prop]);
2935
- if (__getOwnPropSymbols$1)
2936
- for (var prop of __getOwnPropSymbols$1(b)) {
2937
- if (__propIsEnum$1.call(b, prop))
2938
- __defNormalProp$1(a, prop, b[prop]);
2933
+ if (__hasOwnProp$2.call(b, prop))
2934
+ __defNormalProp$2(a, prop, b[prop]);
2935
+ if (__getOwnPropSymbols$2)
2936
+ for (var prop of __getOwnPropSymbols$2(b)) {
2937
+ if (__propIsEnum$2.call(b, prop))
2938
+ __defNormalProp$2(a, prop, b[prop]);
2939
2939
  }
2940
2940
  return a;
2941
2941
  };
2942
- var __spreadProps$1 = (a, b) => __defProps$1(a, __getOwnPropDescs$1(b));
2943
- const useStyles$4 = core.createStyles((theme) => ({
2942
+ var __spreadProps$2 = (a, b) => __defProps$2(a, __getOwnPropDescs$2(b));
2943
+ const useStyles$5 = core.createStyles((theme) => ({
2944
2944
  wrapper: {
2945
2945
  minHeight: "100%",
2946
2946
  boxSizing: "border-box",
@@ -3003,7 +3003,7 @@ const OPTIONS = [
3003
3003
  { description: "project-based learning", title: "Project-Based Learning", icon: icons.IconTools }
3004
3004
  ];
3005
3005
  const TrialRegistration = (props) => {
3006
- const { classes } = useStyles$4();
3006
+ const { classes } = useStyles$5();
3007
3007
  const [firstName, setFirstName] = React__namespace.useState("");
3008
3008
  const [lastName, setLastName] = React__namespace.useState("");
3009
3009
  const [organization, setOrganization] = React__namespace.useState({ organizationId: "", displayName: "" });
@@ -3049,7 +3049,7 @@ const TrialRegistration = (props) => {
3049
3049
  label: "School/Organization Name",
3050
3050
  placeholder: "What's the name of your school?",
3051
3051
  data: props.organizations.map((o) => {
3052
- return __spreadProps$1(__spreadValues$1({}, o), { value: o.displayName });
3052
+ return __spreadProps$2(__spreadValues$2({}, o), { value: o.displayName });
3053
3053
  }),
3054
3054
  onItemSubmit: (item) => setOrganization({ organizationId: item.organizationId, displayName: item.displayName }),
3055
3055
  onChange: (next) => {
@@ -3061,7 +3061,7 @@ const TrialRegistration = (props) => {
3061
3061
  SelectGrid,
3062
3062
  {
3063
3063
  items: OPTIONS,
3064
- onChange: (e, checked) => setInterests(__spreadProps$1(__spreadValues$1({}, interests), { [e]: checked }))
3064
+ onChange: (e, checked) => setInterests(__spreadProps$2(__spreadValues$2({}, interests), { [e]: checked }))
3065
3065
  }
3066
3066
  ), /* @__PURE__ */ React__namespace.createElement(core.Group, { position: "right", mt: "md" }, /* @__PURE__ */ React__namespace.createElement(
3067
3067
  core.Button,
@@ -3099,26 +3099,26 @@ const AdminProvider = (props) => {
3099
3099
  );
3100
3100
  };
3101
3101
 
3102
- var __defProp = Object.defineProperty;
3103
- var __defProps = Object.defineProperties;
3104
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
3105
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
3106
- var __hasOwnProp = Object.prototype.hasOwnProperty;
3107
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
3108
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3109
- var __spreadValues = (a, b) => {
3102
+ var __defProp$1 = Object.defineProperty;
3103
+ var __defProps$1 = Object.defineProperties;
3104
+ var __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors;
3105
+ var __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;
3106
+ var __hasOwnProp$1 = Object.prototype.hasOwnProperty;
3107
+ var __propIsEnum$1 = Object.prototype.propertyIsEnumerable;
3108
+ var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3109
+ var __spreadValues$1 = (a, b) => {
3110
3110
  for (var prop in b || (b = {}))
3111
- if (__hasOwnProp.call(b, prop))
3112
- __defNormalProp(a, prop, b[prop]);
3113
- if (__getOwnPropSymbols)
3114
- for (var prop of __getOwnPropSymbols(b)) {
3115
- if (__propIsEnum.call(b, prop))
3116
- __defNormalProp(a, prop, b[prop]);
3111
+ if (__hasOwnProp$1.call(b, prop))
3112
+ __defNormalProp$1(a, prop, b[prop]);
3113
+ if (__getOwnPropSymbols$1)
3114
+ for (var prop of __getOwnPropSymbols$1(b)) {
3115
+ if (__propIsEnum$1.call(b, prop))
3116
+ __defNormalProp$1(a, prop, b[prop]);
3117
3117
  }
3118
3118
  return a;
3119
3119
  };
3120
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
3121
- const useStyles$3 = core.createStyles((theme, props) => ({
3120
+ var __spreadProps$1 = (a, b) => __defProps$1(a, __getOwnPropDescs$1(b));
3121
+ const useStyles$4 = core.createStyles((theme, props) => ({
3122
3122
  footer: {
3123
3123
  paddingTop: theme.spacing.md,
3124
3124
  paddingBottom: theme.spacing.md,
@@ -3205,7 +3205,7 @@ const useStyles$3 = core.createStyles((theme, props) => ({
3205
3205
  }
3206
3206
  }));
3207
3207
  const App = (props) => {
3208
- const { classes } = useStyles$3(props);
3208
+ const { classes } = useStyles$4(props);
3209
3209
  const account = useAccount(props.account, props.accounts, props.onAccountChange);
3210
3210
  return /* @__PURE__ */ React__namespace.createElement(
3211
3211
  core.AppShell,
@@ -3213,7 +3213,7 @@ const App = (props) => {
3213
3213
  padding: "xs",
3214
3214
  navbar: props.navbar && /* @__PURE__ */ React__namespace.createElement(
3215
3215
  Navbar,
3216
- __spreadProps(__spreadValues({}, props.navbar.props), {
3216
+ __spreadProps$1(__spreadValues$1({}, props.navbar.props), {
3217
3217
  onSwitchAccounts: account.accounts && account.accounts.length > 1 ? () => account.setChangeModalOpen(true) : void 0
3218
3218
  })
3219
3219
  ),
@@ -3332,7 +3332,7 @@ function Table$2(props) {
3332
3332
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { horizontalSpacing: 0, verticalSpacing: 0, sx: { minWidth: 700 } }, /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
3333
3333
  }
3334
3334
 
3335
- const useStyles$2 = core.createStyles((theme) => ({
3335
+ const useStyles$3 = core.createStyles((theme) => ({
3336
3336
  title: {
3337
3337
  fontSize: 34,
3338
3338
  fontWeight: 900,
@@ -3345,7 +3345,7 @@ const useStyles$2 = core.createStyles((theme) => ({
3345
3345
  }
3346
3346
  }));
3347
3347
  const Pathways = (props) => {
3348
- const { classes } = useStyles$2();
3348
+ const { classes } = useStyles$3();
3349
3349
  return /* @__PURE__ */ React__namespace.createElement(core.Container, { size: "lg", py: "xl" }, /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "md" }, /* @__PURE__ */ React__namespace.createElement(core.Grid, null, /* @__PURE__ */ React__namespace.createElement(core.Grid.Col, { sm: "auto" }, /* @__PURE__ */ React__namespace.createElement(core.Badge, { variant: "filled", size: "lg" }, "Pathways"), /* @__PURE__ */ React__namespace.createElement(core.Title, { order: 2, className: classes.title, mt: "md" }, "Pathways"), /* @__PURE__ */ React__namespace.createElement(core.Text, { color: "dimmed", className: classes.description, mt: "sm" }, "Explore all your unique pathway requirements in one clear space"))), /* @__PURE__ */ React__namespace.createElement("div", { style: { position: "relative" } }, /* @__PURE__ */ React__namespace.createElement(core.LoadingOverlay, { visible: props.loading, overlayBlur: 2 }), /* @__PURE__ */ React__namespace.createElement(
3350
3350
  Table$2,
3351
3351
  {
@@ -3355,7 +3355,7 @@ const Pathways = (props) => {
3355
3355
  ))));
3356
3356
  };
3357
3357
 
3358
- const useStyles$1 = core.createStyles((theme) => ({
3358
+ const useStyles$2 = core.createStyles((theme) => ({
3359
3359
  button: {
3360
3360
  borderTopRightRadius: 0,
3361
3361
  borderBottomRightRadius: 0,
@@ -3370,7 +3370,7 @@ const useStyles$1 = core.createStyles((theme) => ({
3370
3370
  }
3371
3371
  }));
3372
3372
  const SplitButton = (props) => {
3373
- const { classes, theme } = useStyles$1();
3373
+ const { classes, theme } = useStyles$2();
3374
3374
  theme.colors[theme.primaryColor][theme.colorScheme === "dark" ? 5 : 6];
3375
3375
  return /* @__PURE__ */ React__namespace.createElement(core.Stack, { spacing: "sm" }, /* @__PURE__ */ React__namespace.createElement(
3376
3376
  core.Button,
@@ -3406,7 +3406,32 @@ function Stack(props) {
3406
3406
  return /* @__PURE__ */ React__namespace.createElement(core.Grid, { grow: true, gutter: "lg", sx: { padding: 20, minWidth: 700 } }, rows);
3407
3407
  }
3408
3408
 
3409
+ var __defProp = Object.defineProperty;
3410
+ var __defProps = Object.defineProperties;
3411
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
3412
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
3413
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
3414
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
3415
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3416
+ var __spreadValues = (a, b) => {
3417
+ for (var prop in b || (b = {}))
3418
+ if (__hasOwnProp.call(b, prop))
3419
+ __defNormalProp(a, prop, b[prop]);
3420
+ if (__getOwnPropSymbols)
3421
+ for (var prop of __getOwnPropSymbols(b)) {
3422
+ if (__propIsEnum.call(b, prop))
3423
+ __defNormalProp(a, prop, b[prop]);
3424
+ }
3425
+ return a;
3426
+ };
3427
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
3409
3428
  function Table$1(props) {
3429
+ const preparedItems = React__namespace.useMemo(() => {
3430
+ return props.items.map((item) => __spreadValues(__spreadProps(__spreadValues({}, item), {
3431
+ status: item.isComplete
3432
+ }), item.categoryPoints));
3433
+ }, [props.items]);
3434
+ const { items: sortedItems, requestSort, sortConfig } = useSortableData(preparedItems);
3410
3435
  if (props.items.length === 0) {
3411
3436
  return /* @__PURE__ */ React__namespace.createElement(
3412
3437
  PlaceholderBanner,
@@ -3418,6 +3443,10 @@ function Table$1(props) {
3418
3443
  }
3419
3444
  );
3420
3445
  }
3446
+ const sortStatus = {
3447
+ columnAccessor: sortConfig.key,
3448
+ direction: sortConfig.direction === "desc" ? "desc" : "asc"
3449
+ };
3421
3450
  return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(
3422
3451
  mantineDatatable.DataTable,
3423
3452
  {
@@ -3428,24 +3457,33 @@ function Table$1(props) {
3428
3457
  withColumnBorders: true,
3429
3458
  striped: true,
3430
3459
  highlightOnHover: true,
3431
- records: props.items,
3460
+ records: sortedItems,
3432
3461
  idAccessor: "userId",
3462
+ sortStatus,
3463
+ onSortStatusChange: (status) => requestSort(status.columnAccessor),
3433
3464
  columns: [
3434
3465
  {
3435
3466
  accessor: "name",
3436
3467
  title: "Student Name",
3437
- render: (row) => /* @__PURE__ */ React__namespace.createElement(core.Group, { spacing: "sm" }, /* @__PURE__ */ React__namespace.createElement(core.Avatar, { size: 40, src: row.avatar, radius: 40 }), /* @__PURE__ */ React__namespace.createElement("div", null, /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "sm", weight: 500 }, row.name), /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "xs", color: "dimmed" }, row.email)))
3468
+ sortable: true,
3469
+ titleStyle: { whiteSpace: "nowrap" },
3470
+ render: (row) => /* @__PURE__ */ React__namespace.createElement(core.Group, { spacing: "sm", noWrap: true }, /* @__PURE__ */ React__namespace.createElement(core.Avatar, { size: 40, src: row.avatar, radius: 40 }), /* @__PURE__ */ React__namespace.createElement("div", null, /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "sm", weight: 500 }, row.name), /* @__PURE__ */ React__namespace.createElement(core.Text, { size: "xs", color: "dimmed" }, row.email)))
3438
3471
  },
3439
3472
  {
3440
3473
  accessor: "status",
3441
- render: (row) => /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, !!row.isComplete && /* @__PURE__ */ React__namespace.createElement(core.Badge, { variant: "filled" }, "Complete"), !row.isComplete && /* @__PURE__ */ React__namespace.createElement(core.Badge, { color: "red", variant: "filled" }, "Incomplete"))
3474
+ title: "Status",
3475
+ sortable: true,
3476
+ titleStyle: { whiteSpace: "nowrap" },
3477
+ render: (row) => /* @__PURE__ */ React__namespace.createElement(core.Badge, { color: row.isComplete ? "blue" : "red", variant: "filled" }, row.isComplete ? "Complete" : "Incomplete")
3442
3478
  },
3443
3479
  ...props.categories.map((category) => ({
3444
3480
  accessor: category.categoryId,
3445
3481
  title: category.name,
3482
+ sortable: true,
3483
+ titleStyle: { whiteSpace: "nowrap" },
3446
3484
  render: (row) => {
3447
3485
  var _a, _b;
3448
- return /* @__PURE__ */ React__namespace.createElement(core.Badge, { color: "blue", variant: "filled" }, (_b = (_a = row.categoryPoints) == null ? void 0 : _a[category.categoryId]) != null ? _b : 0);
3486
+ return /* @__PURE__ */ React__namespace.createElement(core.Badge, { color: "blue", variant: "filled" }, (_b = (_a = row.categoryPoints) == null ? void 0 : _a[category.categoryId]) != null ? _b : 0, " pts");
3449
3487
  }
3450
3488
  }))
3451
3489
  ],
@@ -3456,7 +3494,23 @@ function Table$1(props) {
3456
3494
  ));
3457
3495
  }
3458
3496
 
3497
+ const useStyles$1 = core.createStyles((theme) => ({
3498
+ th: { padding: "0 !important" },
3499
+ control: {
3500
+ width: "100%",
3501
+ padding: `${theme.spacing.xs}px ${theme.spacing.md}px`,
3502
+ "&:hover": {
3503
+ backgroundColor: theme.colorScheme === "dark" ? theme.colors.dark[6] : theme.colors.gray[0]
3504
+ }
3505
+ }
3506
+ }));
3507
+ function Th({ children, reversed, sorted, onSort }) {
3508
+ const { classes } = useStyles$1();
3509
+ const Icon = sorted ? reversed ? icons.IconChevronUp : icons.IconChevronDown : icons.IconSelector;
3510
+ return /* @__PURE__ */ React__namespace.createElement("th", { className: classes.th }, /* @__PURE__ */ React__namespace.createElement(core.UnstyledButton, { onClick: onSort, className: classes.control }, /* @__PURE__ */ React__namespace.createElement(core.Group, { position: "apart", noWrap: true, spacing: "xs" }, /* @__PURE__ */ React__namespace.createElement(core.Text, { weight: 500, size: "sm", sx: { whiteSpace: "nowrap" } }, children), /* @__PURE__ */ React__namespace.createElement(core.Center, null, /* @__PURE__ */ React__namespace.createElement(Icon, { size: 14, stroke: 1.5 })))));
3511
+ }
3459
3512
  function Table(props) {
3513
+ const { items: sortedItems, requestSort, sortConfig } = useSortableData(props.items);
3460
3514
  if (props.items.length === 0) {
3461
3515
  return /* @__PURE__ */ React__namespace.createElement(
3462
3516
  PlaceholderBanner,
@@ -3468,11 +3522,27 @@ function Table(props) {
3468
3522
  }
3469
3523
  );
3470
3524
  }
3471
- const rows = props.items.map((row) => {
3525
+ const rows = sortedItems.map((row) => {
3472
3526
  const percentageCompletion = Math.round((row.percentageCompletion + Number.EPSILON) * 100);
3473
- return /* @__PURE__ */ React__namespace.createElement("tr", { key: row.badgeName }, /* @__PURE__ */ React__namespace.createElement("td", null, /* @__PURE__ */ React__namespace.createElement(core.Text, { component: reactRouterDom.Link, to: row.href }, row.badgeName)), /* @__PURE__ */ React__namespace.createElement("td", null, percentageCompletion, "%"));
3527
+ return /* @__PURE__ */ React__namespace.createElement("tr", { key: row.badgeId }, /* @__PURE__ */ React__namespace.createElement("td", null, /* @__PURE__ */ React__namespace.createElement(core.Text, { component: reactRouterDom.Link, to: row.href }, row.badgeName)), /* @__PURE__ */ React__namespace.createElement("td", null, percentageCompletion, "%"));
3474
3528
  });
3475
- return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { verticalSpacing: "sm", sx: { minWidth: 700 }, highlightOnHover: true, striped: true }, /* @__PURE__ */ React__namespace.createElement("thead", null, /* @__PURE__ */ React__namespace.createElement("tr", null, /* @__PURE__ */ React__namespace.createElement("th", null, "Badge Name"), /* @__PURE__ */ React__namespace.createElement("th", null, "Badge Completion"))), /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
3529
+ return /* @__PURE__ */ React__namespace.createElement(core.ScrollArea.Autosize, { maxHeight: 600 }, /* @__PURE__ */ React__namespace.createElement(core.Table, { verticalSpacing: "sm", sx: { minWidth: 700 }, highlightOnHover: true, striped: true }, /* @__PURE__ */ React__namespace.createElement("thead", null, /* @__PURE__ */ React__namespace.createElement("tr", null, /* @__PURE__ */ React__namespace.createElement(
3530
+ Th,
3531
+ {
3532
+ sorted: sortConfig.key === "badgeName",
3533
+ reversed: sortConfig.direction === "desc",
3534
+ onSort: () => requestSort("badgeName")
3535
+ },
3536
+ "Badge Name"
3537
+ ), /* @__PURE__ */ React__namespace.createElement(
3538
+ Th,
3539
+ {
3540
+ sorted: sortConfig.key === "percentageCompletion",
3541
+ reversed: sortConfig.direction === "desc",
3542
+ onSort: () => requestSort("percentageCompletion")
3543
+ },
3544
+ "Badge Completion"
3545
+ ))), /* @__PURE__ */ React__namespace.createElement("tbody", null, rows)));
3476
3546
  }
3477
3547
 
3478
3548
  const useStyles = core.createStyles((theme) => ({