@local-civics/mgmt-ui 0.1.72 → 0.1.73
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 +3 -0
- package/dist/index.js +19 -18
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +19 -18
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -1
package/dist/index.mjs
CHANGED
|
@@ -337,7 +337,7 @@ function NestedNavbar(props) {
|
|
|
337
337
|
const toggle = () => setBurgerOpen(!burgerOpen);
|
|
338
338
|
const links = data.map((item) => {
|
|
339
339
|
const context = props.links[item.label] || { notifications: 0, href: "" };
|
|
340
|
-
if (context.hidden) {
|
|
340
|
+
if (context.hidden || props.trial && item.label !== "Home") {
|
|
341
341
|
return null;
|
|
342
342
|
}
|
|
343
343
|
return /* @__PURE__ */ React.createElement(
|
|
@@ -352,7 +352,7 @@ function NestedNavbar(props) {
|
|
|
352
352
|
})
|
|
353
353
|
);
|
|
354
354
|
});
|
|
355
|
-
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Navbar$1, { width: { sm: 300 }, p: "md", className: cx(classes.navbar, { [classes.navHeader]: !burgerOpen }) }, /* @__PURE__ */ React.createElement(Navbar$1.Section, { className: classes.header }, /* @__PURE__ */ React.createElement(Group, { position: "apart" }, /* @__PURE__ */ React.createElement(Center, null, /* @__PURE__ */ React.createElement(Avatar, { color: "blue", radius: "sm" }, /* @__PURE__ */ React.createElement("div", { style: { width: 15, marginLeft: "auto", marginRight: "auto" } }, /* @__PURE__ */ React.createElement(Image, { fit: "contain", src: "https://cdn.localcivics.io/brand/l.png" })))), /* @__PURE__ */ React.createElement(Group, { position: "apart" }, /* @__PURE__ */ React.createElement(Code, { sx: { fontWeight: 700 } }, props.version), /* @__PURE__ */ React.createElement(Burger, { opened: burgerOpen, onClick: toggle, className: classes.burger, size: "sm" })))), /* @__PURE__ */ React.createElement("div", { className: cx({ [classes.navBody]: !burgerOpen }) }, /* @__PURE__ */ React.createElement(
|
|
355
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Navbar$1, { width: { sm: 300 }, p: "md", className: cx(classes.navbar, { [classes.navHeader]: !burgerOpen }) }, /* @__PURE__ */ React.createElement(Navbar$1.Section, { className: classes.header }, /* @__PURE__ */ React.createElement(Group, { position: "apart" }, /* @__PURE__ */ React.createElement(Center, null, /* @__PURE__ */ React.createElement(Avatar, { color: "blue", radius: "sm" }, /* @__PURE__ */ React.createElement("div", { style: { width: 15, marginLeft: "auto", marginRight: "auto" } }, /* @__PURE__ */ React.createElement(Image, { fit: "contain", src: "https://cdn.localcivics.io/brand/l.png" })))), /* @__PURE__ */ React.createElement(Group, { position: "apart" }, /* @__PURE__ */ React.createElement(Code, { sx: { fontWeight: 700 } }, props.version), !!props.trial && /* @__PURE__ */ React.createElement(Badge$1, { color: "violet", radius: "xs" }, "Trial"), /* @__PURE__ */ React.createElement(Burger, { opened: burgerOpen, onClick: toggle, className: classes.burger, size: "sm" })))), /* @__PURE__ */ React.createElement("div", { className: cx({ [classes.navBody]: !burgerOpen }) }, /* @__PURE__ */ React.createElement(
|
|
356
356
|
UserButton,
|
|
357
357
|
{
|
|
358
358
|
className: classes.user,
|
|
@@ -692,7 +692,7 @@ const Badge = (props) => {
|
|
|
692
692
|
leftSection: /* @__PURE__ */ React.createElement(ActionIcon, { color: "blue", size: "xs", radius: "xl", variant: "filled" }, /* @__PURE__ */ React.createElement(IconArrowLeft, { size: 14 })),
|
|
693
693
|
size: "lg"
|
|
694
694
|
},
|
|
695
|
-
"
|
|
695
|
+
"Go Back"
|
|
696
696
|
)), /* @__PURE__ */ React.createElement(Group, null, /* @__PURE__ */ React.createElement(Stack$3, { spacing: 0 }, /* @__PURE__ */ React.createElement(Title, { order: 2, className: classes.title, mt: "md" }, props.displayName || "Badge"), /* @__PURE__ */ React.createElement(Text, { color: "dimmed", className: classes.description, mt: "sm" }, props.description || "No description")), /* @__PURE__ */ React.createElement(Stack$3, { ml: "auto" }, /* @__PURE__ */ React.createElement(
|
|
697
697
|
SplitButton$3,
|
|
698
698
|
{
|
|
@@ -706,7 +706,7 @@ const Badge = (props) => {
|
|
|
706
706
|
value: percentageOfBadgesEarned,
|
|
707
707
|
unit: "%"
|
|
708
708
|
}
|
|
709
|
-
] }), /* @__PURE__ */ React.createElement(
|
|
709
|
+
] }), !props.trial && /* @__PURE__ */ React.createElement(
|
|
710
710
|
Select,
|
|
711
711
|
{
|
|
712
712
|
clearable: true,
|
|
@@ -721,7 +721,7 @@ const Badge = (props) => {
|
|
|
721
721
|
return { value: g.classId, label: g.name };
|
|
722
722
|
})
|
|
723
723
|
}
|
|
724
|
-
), /* @__PURE__ */ React.createElement(Stack$3, { spacing: 0 }, /* @__PURE__ */ React.createElement(
|
|
724
|
+
), /* @__PURE__ */ React.createElement(Stack$3, { spacing: 0 }, !props.trial && /* @__PURE__ */ React.createElement(
|
|
725
725
|
Tabs,
|
|
726
726
|
{
|
|
727
727
|
value: tab,
|
|
@@ -731,13 +731,13 @@ const Badge = (props) => {
|
|
|
731
731
|
],
|
|
732
732
|
onChange: setTab
|
|
733
733
|
}
|
|
734
|
-
), tab === "lessons" && /* @__PURE__ */ React.createElement(
|
|
734
|
+
), (!!props.trial || tab === "lessons") && /* @__PURE__ */ React.createElement(
|
|
735
735
|
Table$f,
|
|
736
736
|
{
|
|
737
737
|
loading: props.loading,
|
|
738
738
|
items: props.lessons
|
|
739
739
|
}
|
|
740
|
-
), tab === "students" && /* @__PURE__ */ React.createElement(
|
|
740
|
+
), !props.trial && tab === "students" && /* @__PURE__ */ React.createElement(
|
|
741
741
|
Table$g,
|
|
742
742
|
{
|
|
743
743
|
loading: props.loading,
|
|
@@ -1162,7 +1162,7 @@ const Class = (props) => {
|
|
|
1162
1162
|
leftSection: /* @__PURE__ */ React.createElement(ActionIcon, { color: "blue", size: "xs", radius: "xl", variant: "filled" }, /* @__PURE__ */ React.createElement(IconArrowLeft, { size: 14 })),
|
|
1163
1163
|
size: "lg"
|
|
1164
1164
|
},
|
|
1165
|
-
"
|
|
1165
|
+
"Go Back"
|
|
1166
1166
|
)), /* @__PURE__ */ React.createElement(Title, { order: 2, className: classes.title, mt: "md" }, props.displayName || "Class"), /* @__PURE__ */ React.createElement(Text, { color: "dimmed", className: classes.description, mt: "sm" }, props.description || "No description")), /* @__PURE__ */ React.createElement(Grid.Col, { sm: "content" }, !props.loading && /* @__PURE__ */ React.createElement(
|
|
1167
1167
|
SplitButton$2,
|
|
1168
1168
|
{
|
|
@@ -1465,7 +1465,7 @@ const Student = (props) => {
|
|
|
1465
1465
|
leftSection: /* @__PURE__ */ React.createElement(ActionIcon, { color: "blue", size: "xs", radius: "xl", variant: "filled" }, /* @__PURE__ */ React.createElement(IconArrowLeft, { size: 14 })),
|
|
1466
1466
|
size: "lg"
|
|
1467
1467
|
},
|
|
1468
|
-
"Back"
|
|
1468
|
+
"Go Back"
|
|
1469
1469
|
)), /* @__PURE__ */ React.createElement(
|
|
1470
1470
|
UserInfo,
|
|
1471
1471
|
{
|
|
@@ -1596,7 +1596,8 @@ const useStyles$8 = createStyles((theme) => ({
|
|
|
1596
1596
|
card: {
|
|
1597
1597
|
height: 240,
|
|
1598
1598
|
backgroundSize: "cover",
|
|
1599
|
-
backgroundPosition: "center"
|
|
1599
|
+
backgroundPosition: "center",
|
|
1600
|
+
whiteSpace: "pre-line"
|
|
1600
1601
|
},
|
|
1601
1602
|
content: {
|
|
1602
1603
|
position: "absolute",
|
|
@@ -1926,7 +1927,7 @@ const Lesson = (props) => {
|
|
|
1926
1927
|
leftSection: /* @__PURE__ */ React.createElement(ActionIcon, { color: "blue", size: "xs", radius: "xl", variant: "filled" }, /* @__PURE__ */ React.createElement(IconArrowLeft, { size: 14 })),
|
|
1927
1928
|
size: "lg"
|
|
1928
1929
|
},
|
|
1929
|
-
"
|
|
1930
|
+
"Go Back"
|
|
1930
1931
|
)), /* @__PURE__ */ React.createElement(Group, null, /* @__PURE__ */ React.createElement(Stack$3, { spacing: 0 }, /* @__PURE__ */ React.createElement(Title, { order: 2, className: classes.title, mt: "md" }, props.displayName || "Lesson"), /* @__PURE__ */ React.createElement(Text, { color: "dimmed", className: classes.description, mt: "sm" }, props.description || "No description")), /* @__PURE__ */ React.createElement(Stack$3, { ml: "auto" }, /* @__PURE__ */ React.createElement(
|
|
1931
1932
|
SplitButton$1,
|
|
1932
1933
|
{
|
|
@@ -1940,7 +1941,7 @@ const Lesson = (props) => {
|
|
|
1940
1941
|
value: percentageOfLessonsCompleted,
|
|
1941
1942
|
unit: "%"
|
|
1942
1943
|
}
|
|
1943
|
-
] }), /* @__PURE__ */ React.createElement(
|
|
1944
|
+
] }), !props.trial && /* @__PURE__ */ React.createElement(
|
|
1944
1945
|
Select,
|
|
1945
1946
|
{
|
|
1946
1947
|
clearable: true,
|
|
@@ -1955,7 +1956,7 @@ const Lesson = (props) => {
|
|
|
1955
1956
|
return { value: g.classId, label: g.name };
|
|
1956
1957
|
})
|
|
1957
1958
|
}
|
|
1958
|
-
), /* @__PURE__ */ React.createElement(Stack$3, { spacing: 0 }, /* @__PURE__ */ React.createElement(
|
|
1959
|
+
), /* @__PURE__ */ React.createElement(Stack$3, { spacing: 0 }, !props.trial && /* @__PURE__ */ React.createElement(
|
|
1959
1960
|
Tabs,
|
|
1960
1961
|
{
|
|
1961
1962
|
value: tab,
|
|
@@ -1966,19 +1967,19 @@ const Lesson = (props) => {
|
|
|
1966
1967
|
],
|
|
1967
1968
|
onChange: setTab
|
|
1968
1969
|
}
|
|
1969
|
-
), tab === "question" && /* @__PURE__ */ React.createElement(
|
|
1970
|
+
), (!!props.trial || tab === "question") && /* @__PURE__ */ React.createElement(
|
|
1970
1971
|
Stack,
|
|
1971
1972
|
{
|
|
1972
1973
|
loading: props.loading,
|
|
1973
1974
|
items: props.questions
|
|
1974
1975
|
}
|
|
1975
|
-
), tab === "reflections" && /* @__PURE__ */ React.createElement(
|
|
1976
|
+
), !props.trial && tab === "reflections" && /* @__PURE__ */ React.createElement(
|
|
1976
1977
|
Table$3,
|
|
1977
1978
|
{
|
|
1978
1979
|
loading: props.loading,
|
|
1979
1980
|
items: props.reflections
|
|
1980
1981
|
}
|
|
1981
|
-
), tab === "students" && /* @__PURE__ */ React.createElement(
|
|
1982
|
+
), !props.trial && tab === "students" && /* @__PURE__ */ React.createElement(
|
|
1982
1983
|
Table$2,
|
|
1983
1984
|
{
|
|
1984
1985
|
loading: props.loading,
|
|
@@ -2134,7 +2135,7 @@ const Organization = (props) => {
|
|
|
2134
2135
|
leftSection: /* @__PURE__ */ React.createElement(ActionIcon, { color: "blue", size: "xs", radius: "xl", variant: "filled" }, /* @__PURE__ */ React.createElement(IconArrowLeft, { size: 14 })),
|
|
2135
2136
|
size: "lg"
|
|
2136
2137
|
},
|
|
2137
|
-
"
|
|
2138
|
+
"Go Back"
|
|
2138
2139
|
)), /* @__PURE__ */ React.createElement(Title, { order: 2, className: classes.title, mt: "md" }, props.displayName || "Overview"), /* @__PURE__ */ React.createElement(Text, { color: "dimmed", className: classes.description, mt: "sm" }, props.description || "No description"))), /* @__PURE__ */ React.createElement(AccessCode, { value: props.accessCode, onCopyCode: props.onCopyAccessCode, peopleLink: props.peopleLink }), /* @__PURE__ */ React.createElement("div", { style: { position: "relative" } }, /* @__PURE__ */ React.createElement(LoadingOverlay, { visible: props.loading, overlayBlur: 2 }), /* @__PURE__ */ React.createElement(Stack$3, { spacing: "sm" }, /* @__PURE__ */ React.createElement(StatsGroup, { data: [
|
|
2139
2140
|
{
|
|
2140
2141
|
title: "# OF STUDENTS",
|
|
@@ -2341,7 +2342,7 @@ const People = (props) => {
|
|
|
2341
2342
|
leftSection: /* @__PURE__ */ React.createElement(ActionIcon, { color: "blue", size: "xs", radius: "xl", variant: "filled" }, /* @__PURE__ */ React.createElement(IconArrowLeft, { size: 14 })),
|
|
2342
2343
|
size: "lg"
|
|
2343
2344
|
},
|
|
2344
|
-
"
|
|
2345
|
+
"Go Back"
|
|
2345
2346
|
)), /* @__PURE__ */ React.createElement(Title, { order: 2, className: classes.title, mt: "md" }, "People"), /* @__PURE__ */ React.createElement(Text, { color: "dimmed", className: classes.description, mt: "sm" }, "Manage members of your organization")), /* @__PURE__ */ React.createElement(Grid.Col, { sm: "content" }, !props.loading && /* @__PURE__ */ React.createElement(
|
|
2346
2347
|
SplitButton,
|
|
2347
2348
|
{
|