@churchapps/apphelper 0.2.78 → 0.2.80
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/components/DisplayBox.d.ts +12 -0
- package/dist/components/DisplayBox.d.ts.map +1 -1
- package/dist/components/DisplayBox.js +9 -2
- package/dist/components/DisplayBox.js.map +1 -1
- package/dist/components/InputBox.d.ts +12 -0
- package/dist/components/InputBox.d.ts.map +1 -1
- package/dist/components/InputBox.js +12 -3
- package/dist/components/InputBox.js.map +1 -1
- package/dist/components/wrapper/Drawers.d.ts +2 -2
- package/dist/components/wrapper/Drawers.d.ts.map +1 -1
- package/dist/components/wrapper/Drawers.js +5 -3
- package/dist/components/wrapper/Drawers.js.map +1 -1
- package/dist/components/wrapper/SiteWrapper.js +1 -1
- package/dist/components/wrapper/SiteWrapper.js.map +1 -1
- package/package.json +1 -1
- package/src/components/DisplayBox.tsx +25 -3
- package/src/components/InputBox.tsx +28 -4
- package/src/components/wrapper/Drawers.tsx +3 -3
- package/src/components/wrapper/SiteWrapper.tsx +1 -1
|
@@ -1,4 +1,16 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
+
declare module '@mui/material/styles' {
|
|
3
|
+
interface Palette {
|
|
4
|
+
InputBox: {
|
|
5
|
+
headerText: string;
|
|
6
|
+
};
|
|
7
|
+
}
|
|
8
|
+
interface PaletteOptions {
|
|
9
|
+
InputBox?: {
|
|
10
|
+
headerText?: string;
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
}
|
|
2
14
|
interface Props {
|
|
3
15
|
id?: string;
|
|
4
16
|
children: React.ReactNode;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DisplayBox.d.ts","sourceRoot":"","sources":["../../src/components/DisplayBox.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"DisplayBox.d.ts","sourceRoot":"","sources":["../../src/components/DisplayBox.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,OAAO,QAAQ,sBAAsB,CAAC;IACpC,UAAU,OAAO;QACf,QAAQ,EAAE;YACR,UAAU,EAAE,MAAM,CAAC;SACpB,CAAC;KACH;IACD,UAAU,cAAc;QACtB,QAAQ,CAAC,EAAE;YACT,UAAU,CAAC,EAAE,MAAM,CAAC;SACrB,CAAC;KACH;CACF;AAUD,UAAU,KAAK;IACb,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAChC,IAAI,CAAC,EAAE,MAAM,CAAA;CACd;AAsBD,eAAO,MAAM,UAAU,8EA2BrB,CAAA"}
|
|
@@ -9,6 +9,13 @@ const react_1 = __importDefault(require("react"));
|
|
|
9
9
|
const material_1 = require("@mui/material");
|
|
10
10
|
const HelpIcon_1 = require("./HelpIcon");
|
|
11
11
|
const SmallButton_1 = require("./SmallButton");
|
|
12
|
+
const theme = (0, material_1.createTheme)({
|
|
13
|
+
palette: {
|
|
14
|
+
InputBox: {
|
|
15
|
+
headerText: "primary"
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
});
|
|
12
19
|
/* "& p": { color: "#666" }, */
|
|
13
20
|
const CustomContextBox = (0, material_1.styled)(material_1.Box)({
|
|
14
21
|
marginTop: 10,
|
|
@@ -39,8 +46,8 @@ exports.DisplayBox = react_1.default.forwardRef((props, ref) => {
|
|
|
39
46
|
props.help && react_1.default.createElement(HelpIcon_1.HelpIcon, { article: props.help }),
|
|
40
47
|
react_1.default.createElement(material_1.Box, { sx: { display: "flex", justifyContent: "space-between", alignItems: "center" } },
|
|
41
48
|
react_1.default.createElement(material_1.Box, { sx: { display: "flex", alignItems: "center" } },
|
|
42
|
-
props.headerIcon && react_1.default.createElement(material_1.Icon, { sx: { color:
|
|
43
|
-
react_1.default.createElement(material_1.Typography, { component: "h2", sx: { display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }, variant: "h6", color:
|
|
49
|
+
props.headerIcon && react_1.default.createElement(material_1.Icon, { sx: { color: theme.palette.InputBox.headerText } }, props.headerIcon),
|
|
50
|
+
react_1.default.createElement(material_1.Typography, { component: "h2", sx: { display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }, variant: "h6", color: theme.palette.InputBox.headerText }, props.headerText)),
|
|
44
51
|
react_1.default.createElement(material_1.Box, null, editContent)),
|
|
45
52
|
react_1.default.createElement(CustomContextBox, { ref: ref, "data-cy": "content" }, props.children),
|
|
46
53
|
props.footerContent && (react_1.default.createElement("div", { style: { marginLeft: -16, marginRight: -16, marginBottom: -15, marginTop: 15 } }, props.footerContent))));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DisplayBox.js","sourceRoot":"","sources":["../../src/components/DisplayBox.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;AAEb,kDAA0B;AAC1B,
|
|
1
|
+
{"version":3,"file":"DisplayBox.js","sourceRoot":"","sources":["../../src/components/DisplayBox.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;AAEb,kDAA0B;AAC1B,4CAAkF;AAClF,yCAAsC;AACtC,+CAA4C;AAgB5C,MAAM,KAAK,GAAG,IAAA,sBAAW,EAAC;IACxB,OAAO,EAAE;QACP,QAAQ,EAAE;YACR,UAAU,EAAE,SAAS;SACtB;KACF;CACF,CAAC,CAAC;AAeH,+BAA+B;AAC/B,MAAM,gBAAgB,GAAG,IAAA,iBAAM,EAAC,cAAG,CA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+
InputBox: {
|
|
6
|
+
headerText: string;
|
|
7
|
+
};
|
|
8
|
+
}
|
|
9
|
+
interface PaletteOptions {
|
|
10
|
+
InputBox?: {
|
|
11
|
+
headerText?: string;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
}
|
|
3
15
|
interface Props {
|
|
4
16
|
id?: string;
|
|
5
17
|
children?: React.ReactNode;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InputBox.d.ts","sourceRoot":"","sources":["../../src/components/InputBox.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAuD,UAAU,
|
|
1
|
+
{"version":3,"file":"InputBox.d.ts","sourceRoot":"","sources":["../../src/components/InputBox.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAuD,UAAU,EAAe,MAAM,eAAe,CAAC;AAI7G,OAAO,QAAQ,sBAAsB,CAAC;IACpC,UAAU,OAAO;QACf,QAAQ,EAAE;YACR,UAAU,EAAE,MAAM,CAAC;SACpB,CAAC;KACH;IACD,UAAU,cAAc;QACtB,QAAQ,CAAC,EAAE;YACT,UAAU,CAAC,EAAE,MAAM,CAAC;SACrB,CAAC;KACH;CACF;AAUD,UAAU,KAAK;IACb,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,mBAAmB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACtC,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,QAAQ,GAAG,QAAQ,CAAC;IACrC,qBAAqB,CAAC,EAAE,UAAU,CAAC;CACpC;AAoBD,wBAAgB,QAAQ,CAAC,EAAE,qBAA0B,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,qBAiCvE"}
|
|
@@ -20,7 +20,16 @@ const react_1 = __importDefault(require("react"));
|
|
|
20
20
|
const material_1 = require("@mui/material");
|
|
21
21
|
const HelpIcon_1 = require("./HelpIcon");
|
|
22
22
|
const helpers_1 = require("../helpers");
|
|
23
|
+
const theme = (0, material_1.createTheme)({
|
|
24
|
+
palette: {
|
|
25
|
+
InputBox: {
|
|
26
|
+
headerText: "primary"
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
});
|
|
23
30
|
const CustomContextBox = (0, material_1.styled)(material_1.Box)({
|
|
31
|
+
name: "InputBox",
|
|
32
|
+
slot: "root",
|
|
24
33
|
marginTop: 10,
|
|
25
34
|
overflowX: "hidden",
|
|
26
35
|
"& p": { color: "#666" },
|
|
@@ -50,9 +59,9 @@ function InputBox(_a) {
|
|
|
50
59
|
return (react_1.default.createElement(material_1.Paper, Object.assign({ id: props.id, sx: { padding: 2, marginBottom: 4 }, "data-cy": props["data-cy"] }, mainContainerCssProps),
|
|
51
60
|
props.help && react_1.default.createElement(HelpIcon_1.HelpIcon, { article: props.help }),
|
|
52
61
|
react_1.default.createElement(material_1.Box, { sx: { display: "flex", justifyContent: "space-between", alignItems: "center", position: "relative" }, "data-cy": "header" },
|
|
53
|
-
react_1.default.createElement(material_1.Box, {
|
|
54
|
-
props.headerIcon && react_1.default.createElement(material_1.Icon, { sx: { color:
|
|
55
|
-
props.headerText && (react_1.default.createElement(material_1.Typography, { component: "h2", sx: { display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }, variant: "h6", color:
|
|
62
|
+
react_1.default.createElement(material_1.Box, { display: "flex", alignItems: "center" },
|
|
63
|
+
props.headerIcon && react_1.default.createElement(material_1.Icon, { sx: { color: theme.palette.InputBox.headerText } }, props.headerIcon),
|
|
64
|
+
props.headerText && (react_1.default.createElement(material_1.Typography, { component: "h2", sx: { display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }, variant: "h6", color: theme.palette.InputBox.headerText }, props.headerText))),
|
|
56
65
|
react_1.default.createElement(material_1.Box, null, props.headerActionContent)),
|
|
57
66
|
react_1.default.createElement(CustomContextBox, null, props.children),
|
|
58
67
|
react_1.default.createElement(material_1.Stack, { direction: "row", sx: { marginTop: 1 }, spacing: 1, justifyContent: "end" }, buttons)));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InputBox.js","sourceRoot":"","sources":["../../src/components/InputBox.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;;;AAEb,kDAA0B;AAC1B,
|
|
1
|
+
{"version":3,"file":"InputBox.js","sourceRoot":"","sources":["../../src/components/InputBox.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;;;AAEb,kDAA0B;AAC1B,4CAA6G;AAC7G,yCAAsC;AACtC,wCAAoC;AAepC,MAAM,KAAK,GAAG,IAAA,sBAAW,EAAC;IACxB,OAAO,EAAE;QACP,QAAQ,EAAE;YACR,UAAU,EAAE,SAAS;SACtB;KACF;CACF,CAAC,CAAC;AAwBH,MAAM,gBAAgB,GAAG,IAAA,iBAAM,EAAC,cAAG,CAAC,CAAC;IACnC,IAAI,EAAE,UAAU;IAChB,IAAI,EAAE,MAAM;IACZ,SAAS,EAAE,EAAE;IACb,SAAS,EAAE,QAAQ;IACnB,KA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CACnB,8BAAC,qBAAU,IAAC,SAAS,EAAC,IAAI,EAAC,EAAE,EAAE,EAAE,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,EAAE,OAAO,EAAC,IAAI,EAAC,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,UAAU,IACpJ,KAAK,CAAC,UAAU,CACN,CACd,CACG;YACN,8BAAC,cAAG,QACD,KAAK,CAAC,mBAAmB,CACtB,CACF;QACN,8BAAC,gBAAgB,QAAE,KAAK,CAAC,QAAQ,CAAoB;QACrD,8BAAC,gBAAK,IAAC,SAAS,EAAC,KAAK,EAAC,EAAE,EAAE,EAAE,SAAS,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,CAAC,EAAE,cAAc,EAAC,KAAK,IAC1E,OAAO,CACF,CACF,CACT,CAAC;AACJ,CAAC;AAjCD,4BAiCC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export declare const OpenDrawer: import("@emotion/styled").StyledComponent<import("@mui/material").DrawerProps & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
3
|
-
export declare const ClosedDrawer: import("@emotion/styled").StyledComponent<import("@mui/material").DrawerProps & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
2
|
+
export declare const OpenDrawer: (styles: any) => import("@emotion/styled").StyledComponent<import("@mui/material").DrawerProps & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
3
|
+
export declare const ClosedDrawer: (styles: any) => import("@emotion/styled").StyledComponent<import("@mui/material").DrawerProps & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
4
4
|
export declare const ClosedDrawerAppBar: import("@emotion/styled").StyledComponent<{
|
|
5
5
|
classes?: Partial<import("@mui/material").AppBarClasses>;
|
|
6
6
|
color?: import("@mui/types").OverridableStringUnion<"transparent" | import("@mui/material").PropTypes.Color, import("@mui/material").AppBarPropsColorOverrides>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Drawers.d.ts","sourceRoot":"","sources":["../../../src/components/wrapper/Drawers.tsx"],"names":[],"mappings":";AAIA,eAAO,MAAM,UAAU,
|
|
1
|
+
{"version":3,"file":"Drawers.d.ts","sourceRoot":"","sources":["../../../src/components/wrapper/Drawers.tsx"],"names":[],"mappings":";AAIA,eAAO,MAAM,UAAU,WAAW,GAAG,uKAkBpC,CAAC;AAEF,eAAO,MAAM,YAAY,WAAW,GAAG,uKActC,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;6PAS9B,CAAC;AAEF,eAAO,MAAM,gBAAgB;;;;;;;;6PAS5B,CAAC"}
|
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.OpenDrawerAppBar = exports.ClosedDrawerAppBar = exports.ClosedDrawer = exports.OpenDrawer = void 0;
|
|
5
5
|
const material_1 = require("@mui/material");
|
|
6
|
-
|
|
6
|
+
const OpenDrawer = (styles) => (0, material_1.styled)(material_1.Drawer)(({ theme }) => ({
|
|
7
7
|
"& .MuiDrawer-paper": {
|
|
8
8
|
position: "relative",
|
|
9
|
-
backgroundColor: theme.palette.primary.main,
|
|
9
|
+
backgroundColor: styles.backgroundColor || theme.palette.primary.main,
|
|
10
10
|
color: "#FFFFFF",
|
|
11
11
|
whiteSpace: "nowrap",
|
|
12
12
|
width: "100vw",
|
|
@@ -20,7 +20,8 @@ exports.OpenDrawer = (0, material_1.styled)(material_1.Drawer)(({ theme }) => ({
|
|
|
20
20
|
},
|
|
21
21
|
"& .MuiListItemButton-root, & .MuiListItemIcon-root": { color: "#FFFFFF" }
|
|
22
22
|
}));
|
|
23
|
-
exports.
|
|
23
|
+
exports.OpenDrawer = OpenDrawer;
|
|
24
|
+
const ClosedDrawer = (styles) => (0, material_1.styled)((0, exports.OpenDrawer)(styles))(({ theme }) => ({
|
|
24
25
|
overflowX: "hidden",
|
|
25
26
|
transition: theme.transitions.create("width", {
|
|
26
27
|
easing: theme.transitions.easing.sharp,
|
|
@@ -33,6 +34,7 @@ exports.ClosedDrawer = (0, material_1.styled)(exports.OpenDrawer)(({ theme }) =>
|
|
|
33
34
|
opacity: 0
|
|
34
35
|
}
|
|
35
36
|
}));
|
|
37
|
+
exports.ClosedDrawer = ClosedDrawer;
|
|
36
38
|
exports.ClosedDrawerAppBar = (0, material_1.styled)(material_1.AppBar)(({ theme }) => ({
|
|
37
39
|
zIndex: theme.zIndex.drawer + 1,
|
|
38
40
|
transition: theme.transitions.create(["width", "margin"], {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Drawers.js","sourceRoot":"","sources":["../../../src/components/wrapper/Drawers.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;AAEb,4CAAuD;
|
|
1
|
+
{"version":3,"file":"Drawers.js","sourceRoot":"","sources":["../../../src/components/wrapper/Drawers.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;AAEb,4CAAuD;AAEhD,MAAM,UAAU,GAAG,CAAC,MAAU,EAAE,EAAE,CAAC,IAAA,iBAAM,EAAC,iBAAM,CAAC,CACtD,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,CAAC;IACd,oBAAoB,EAAE;QACpB,QAAQ,EAAE,UAAU;QACpB,eAAe,EAAE,MAAM,CAAC,eAAe,IAAI,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI;QACrE,KAAK,EAAE,SAAS;QAChB,UAAU,EAAE,QAAQ;QACpB,KAAK,EAAE,OAAO;QACd,MAAM,EAAE,IAAI;QACZ,CAAC,KAAK,CAAC,WAAW,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE;QAC5C,UAAU,EAAE,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M,CAAC,CAAC,OAAO,EAAE,QAAQ,CAAC,EAAE;QACxD,MAAM,EAAE,KAAK,CAAC,WAAW,CAAC,MAAM,CAAC,KAAK;QACtC,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,aAAa;KACnD,CAAC;IACF,iBAAiB,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE;CACxC,CAAC,CACH,CAAC;AAEW,QAAA,gBAAgB,GAAG,IAAA,iBAAM,EAAC,0BAAkB,CAAC,CACxD,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,CAAC;IACd,UAAU,EAAE,GAAG;IACf,KAAK,EAAE,eAAe,GAAG,KAAK;IAC9B,UAAU,EAAE,KAAK,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,OAAO,EAAE,QAAQ,CAAC,EAAE;QACxD,MAAM,EAAE,KAAK,CAAC,WAAW,CAAC,MAAM,CAAC,KAAK;QACtC,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc;KACpD,CAAC;CACH,CAAC,CACH,CAAC"}
|
|
@@ -28,7 +28,7 @@ const SiteWrapper = props => {
|
|
|
28
28
|
const [notificationCounts, setNotificationCounts] = react_1.default.useState({ notificationCount: 0, pmCount: 0 });
|
|
29
29
|
const toggleDrawer = () => { setOpen(!open); };
|
|
30
30
|
const isMounted = (0, useMountedState_1.useMountedState)();
|
|
31
|
-
const CustomDrawer = (open) ? Drawers_1.OpenDrawer : Drawers_1.ClosedDrawer;
|
|
31
|
+
const CustomDrawer = (open) ? (0, Drawers_1.OpenDrawer)({ backgroundColor: props.appearance.wrapperBackground }) : (0, Drawers_1.ClosedDrawer)({ backgroundColor: props.appearance.wrapperBackground });
|
|
32
32
|
const CustomAppBar = (open) ? Drawers_1.OpenDrawerAppBar : Drawers_1.ClosedDrawerAppBar;
|
|
33
33
|
const loadCounts = () => {
|
|
34
34
|
helpers_1.ApiHelper.get("/notifications/unreadCount", "MessagingApi").then(data => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SiteWrapper.js","sourceRoot":"","sources":["../../../src/components/wrapper/SiteWrapper.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;AAEb,kDAA6C;AAC7C,4CAA4F;AAC5F,2CAA2G;AAC3G,yCAAsC;AAEtC,iEAA8D;AAC9D,6DAA0D;AAC1D,uCAA2F;AAYpF,MAAM,WAAW,GAAoB,KAAK,CAAC,EAAE;;IAClD,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,eAAK,CAAC,QAAQ,EAAU,CAAC;IAC7D,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,eAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IAC9C,MAAM,CAAC,kBAAkB,EAAE,qBAAqB,CAAC,GAAG,eAAK,CAAC,QAAQ,CAAC,EAAC,iBAAiB,EAAC,CAAC,EAAE,OAAO,EAAC,CAAC,EAAC,CAAC,CAAC;IACrG,MAAM,YAAY,GAAG,GAAG,EAAE,GAAG,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;IAC/C,MAAM,SAAS,GAAG,IAAA,iCAAe,GAAE,CAAC;IAEpC,MAAM,YAAY,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,oBAAU,CAAC,CAAC,CAAC,sBAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"SiteWrapper.js","sourceRoot":"","sources":["../../../src/components/wrapper/SiteWrapper.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;AAEb,kDAA6C;AAC7C,4CAA4F;AAC5F,2CAA2G;AAC3G,yCAAsC;AAEtC,iEAA8D;AAC9D,6DAA0D;AAC1D,uCAA2F;AAYpF,MAAM,WAAW,GAAoB,KAAK,CAAC,EAAE;;IAClD,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,eAAK,CAAC,QAAQ,EAAU,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A,WAAW,eAgFtB"}
|
package/package.json
CHANGED
|
@@ -1,10 +1,32 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import React from "react";
|
|
4
|
-
import { Paper, Box, Typography, styled, Icon } from "@mui/material";
|
|
4
|
+
import { Paper, Box, Typography, styled, Icon, createTheme } from "@mui/material";
|
|
5
5
|
import { HelpIcon } from "./HelpIcon";
|
|
6
6
|
import { SmallButton } from "./SmallButton";
|
|
7
7
|
|
|
8
|
+
|
|
9
|
+
declare module '@mui/material/styles' {
|
|
10
|
+
interface Palette {
|
|
11
|
+
InputBox: {
|
|
12
|
+
headerText: string;
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
interface PaletteOptions {
|
|
16
|
+
InputBox?: {
|
|
17
|
+
headerText?: string;
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const theme = createTheme({
|
|
23
|
+
palette: {
|
|
24
|
+
InputBox: {
|
|
25
|
+
headerText: "primary"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
|
|
8
30
|
interface Props {
|
|
9
31
|
id?: string,
|
|
10
32
|
children: React.ReactNode,
|
|
@@ -51,8 +73,8 @@ export const DisplayBox = React.forwardRef<HTMLDivElement, Props>((props, ref) =
|
|
|
51
73
|
{props.help && <HelpIcon article={props.help} />}
|
|
52
74
|
<Box sx={{ display: "flex", justifyContent: "space-between", alignItems: "center" }}>
|
|
53
75
|
<Box sx={{ display: "flex", alignItems: "center" }}>
|
|
54
|
-
{props.headerIcon && <Icon sx={{ color:
|
|
55
|
-
<Typography component="h2" sx={{ display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }} variant="h6" color=
|
|
76
|
+
{props.headerIcon && <Icon sx={{ color: theme.palette.InputBox.headerText }}>{props.headerIcon}</Icon>}
|
|
77
|
+
<Typography component="h2" sx={{ display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }} variant="h6" color={theme.palette.InputBox.headerText}>
|
|
56
78
|
{props.headerText}
|
|
57
79
|
</Typography>
|
|
58
80
|
|
|
@@ -1,10 +1,31 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import React from "react";
|
|
4
|
-
import { Paper, Box, Typography, Stack, styled, Button, Icon, PaperProps } from "@mui/material";
|
|
4
|
+
import { Paper, Box, Typography, Stack, styled, Button, Icon, PaperProps, createTheme } from "@mui/material";
|
|
5
5
|
import { HelpIcon } from "./HelpIcon";
|
|
6
6
|
import { Locale } from "../helpers";
|
|
7
7
|
|
|
8
|
+
declare module '@mui/material/styles' {
|
|
9
|
+
interface Palette {
|
|
10
|
+
InputBox: {
|
|
11
|
+
headerText: string;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
interface PaletteOptions {
|
|
15
|
+
InputBox?: {
|
|
16
|
+
headerText?: string;
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
const theme = createTheme({
|
|
22
|
+
palette: {
|
|
23
|
+
InputBox: {
|
|
24
|
+
headerText: "primary"
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
|
|
8
29
|
interface Props {
|
|
9
30
|
id?: string;
|
|
10
31
|
children?: React.ReactNode;
|
|
@@ -28,6 +49,8 @@ interface Props {
|
|
|
28
49
|
}
|
|
29
50
|
|
|
30
51
|
const CustomContextBox = styled(Box)({
|
|
52
|
+
name: "InputBox",
|
|
53
|
+
slot: "root",
|
|
31
54
|
marginTop: 10,
|
|
32
55
|
overflowX: "hidden",
|
|
33
56
|
"& p": { color: "#666" },
|
|
@@ -42,6 +65,7 @@ const CustomContextBox = styled(Box)({
|
|
|
42
65
|
}
|
|
43
66
|
})
|
|
44
67
|
|
|
68
|
+
|
|
45
69
|
export function InputBox({ mainContainerCssProps = {}, ...props }: Props) {
|
|
46
70
|
let buttons = [];
|
|
47
71
|
if (props.cancelFunction) buttons.push(<Button key="cancel" onClick={props.cancelFunction} color="warning" sx={{ "&:focus": { outline: "none" } }}>{props.cancelText || Locale.label("common.cancel")}</Button>);
|
|
@@ -57,10 +81,10 @@ export function InputBox({ mainContainerCssProps = {}, ...props }: Props) {
|
|
|
57
81
|
<Paper id={props.id} sx={{ padding: 2, marginBottom: 4 }} data-cy={props["data-cy"]} {...mainContainerCssProps}>
|
|
58
82
|
{props.help && <HelpIcon article={props.help} />}
|
|
59
83
|
<Box sx={{ display: "flex", justifyContent: "space-between", alignItems: "center", position: "relative" }} data-cy="header">
|
|
60
|
-
<Box
|
|
61
|
-
{props.headerIcon && <Icon sx={{ color:
|
|
84
|
+
<Box display="flex" alignItems="center">
|
|
85
|
+
{props.headerIcon && <Icon sx={{ color: theme.palette.InputBox.headerText }}>{props.headerIcon}</Icon>}
|
|
62
86
|
{props.headerText && (
|
|
63
|
-
<Typography component="h2" sx={{ display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }} variant="h6" color=
|
|
87
|
+
<Typography component="h2" sx={{ display: "inline-block", marginLeft: props.headerIcon ? 1 : 0 }} variant="h6" color={theme.palette.InputBox.headerText}>
|
|
64
88
|
{props.headerText}
|
|
65
89
|
</Typography>
|
|
66
90
|
)}
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
import { AppBar, Drawer, styled } from "@mui/material";
|
|
4
4
|
|
|
5
|
-
export const OpenDrawer = styled(Drawer)(
|
|
5
|
+
export const OpenDrawer = (styles:any) => styled(Drawer)(
|
|
6
6
|
({ theme }) => ({
|
|
7
7
|
"& .MuiDrawer-paper": {
|
|
8
8
|
position: "relative",
|
|
9
|
-
backgroundColor: theme.palette.primary.main,
|
|
9
|
+
backgroundColor: styles.backgroundColor || theme.palette.primary.main,
|
|
10
10
|
color: "#FFFFFF",
|
|
11
11
|
whiteSpace: "nowrap",
|
|
12
12
|
width: "100vw",
|
|
@@ -22,7 +22,7 @@ export const OpenDrawer = styled(Drawer)(
|
|
|
22
22
|
})
|
|
23
23
|
);
|
|
24
24
|
|
|
25
|
-
export const ClosedDrawer = styled(OpenDrawer)(
|
|
25
|
+
export const ClosedDrawer = (styles:any) => styled(OpenDrawer(styles))(
|
|
26
26
|
({ theme }) => ({
|
|
27
27
|
overflowX: "hidden",
|
|
28
28
|
transition: theme.transitions.create("width", {
|
|
@@ -26,7 +26,7 @@ export const SiteWrapper: React.FC<Props> = props => {
|
|
|
26
26
|
const toggleDrawer = () => { setOpen(!open); };
|
|
27
27
|
const isMounted = useMountedState();
|
|
28
28
|
|
|
29
|
-
const CustomDrawer = (open) ? OpenDrawer : ClosedDrawer;
|
|
29
|
+
const CustomDrawer = (open) ? OpenDrawer({backgroundColor:props.appearance.wrapperBackground}) : ClosedDrawer({backgroundColor:props.appearance.wrapperBackground});
|
|
30
30
|
const CustomAppBar = (open) ? OpenDrawerAppBar : ClosedDrawerAppBar;
|
|
31
31
|
|
|
32
32
|
const loadCounts = () => {
|