@superdispatch/ui 0.21.5-alpha.4 → 0.21.8
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-node/index.js +1359 -1442
- package/dist-node/index.js.map +1 -1
- package/dist-src/adaptive-toolbar/AdaptiveToolbar.js +12 -14
- package/dist-src/adaptive-vertical-toolbar/AdaptiveVerticalToolbar.js +3 -3
- package/dist-src/app-bar/AppBarOverrides.js +4 -6
- package/dist-src/autocomplete/AutocompleteOverrides.js +18 -14
- package/dist-src/avatar/AvatarOverrides.js +12 -14
- package/dist-src/avatar-button/AvatarButton.js +92 -80
- package/dist-src/button/Button.js +15 -11
- package/dist-src/button/ButtonOverrides.js +149 -147
- package/dist-src/card/CardOverrides.js +6 -10
- package/dist-src/card-button/CardButton.js +75 -78
- package/dist-src/checkbox/CheckboxField.js +1 -1
- package/dist-src/checkbox/CheckboxGroudField.js +1 -1
- package/dist-src/checkbox/CheckboxOverrides.js +50 -60
- package/dist-src/chip/ChipOverrides.js +85 -88
- package/dist-src/description-list/DescriptionList.js +55 -58
- package/dist-src/dialog/DialogOverrides.js +25 -31
- package/dist-src/drawer/DrawerActions.js +34 -32
- package/dist-src/drawer/DrawerContent.js +26 -10
- package/dist-src/drawer/DrawerList.js +27 -8
- package/dist-src/drawer/DrawerOverrides.js +10 -12
- package/dist-src/drawer/DrawerTitle.js +40 -46
- package/dist-src/dropdown-button/DropdownButton.js +1 -1
- package/dist-src/grid/GridStack.js +1 -1
- package/dist-src/grid/InlineGrid.js +2 -2
- package/dist-src/icon-button/IconButtonOverrides.js +32 -48
- package/dist-src/info-card/InfoCard.js +37 -27
- package/dist-src/link/LinkOverrides.js +26 -29
- package/dist-src/list/ListOverrides.js +7 -10
- package/dist-src/menu/MenuOverrides.js +14 -28
- package/dist-src/number-field/NumberField.js +3 -2
- package/dist-src/overflow-text/OverflowText.js +34 -35
- package/dist-src/pagination/PaginationOverrides.js +32 -27
- package/dist-src/paper/PaperOverrides.js +6 -8
- package/dist-src/radio/RadioField.js +1 -1
- package/dist-src/radio/RadioGroupField.js +1 -1
- package/dist-src/radio/RadioOverrides.js +36 -38
- package/dist-src/responsive/ResponsiveContext.js +1 -1
- package/dist-src/snackbar/Snackbar.js +1 -1
- package/dist-src/snackbar/SnackbarContent.js +3 -3
- package/dist-src/snackbar/SnackbarOverrides.js +18 -28
- package/dist-src/svg-icon/SvgIconOverrides.js +18 -28
- package/dist-src/switch/SwitchOverrides.js +71 -72
- package/dist-src/tabs/TabsOverrides.js +30 -34
- package/dist-src/tag/Tag.js +2 -2
- package/dist-src/text-field/TextFieldOverrides.js +137 -158
- package/dist-src/theme/ThemeProvider.js +28 -25
- package/dist-src/tiles/Tiles.js +3 -4
- package/dist-src/toolbar/ToolbarOverrides.js +8 -10
- package/dist-src/tooltip/TooltipOverrides.js +30 -33
- package/dist-src/typography/TypographyOverrides.js +2 -12
- package/dist-types/index.d.ts +381 -385
- package/dist-web/index.js +1291 -1374
- package/dist-web/index.js.map +1 -1
- package/package.json +39 -39
- package/dist-src/theme/CssBaselineOverrides.js +0 -8
|
@@ -1,70 +1,60 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SvgIcon } from '@material-ui/core';
|
|
2
2
|
import { Color } from "../theme/Color.js";
|
|
3
3
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
4
4
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
5
5
|
export function overrideCheckbox(theme) {
|
|
6
|
-
theme.
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
rx: "1.5"
|
|
18
|
-
})
|
|
19
|
-
}),
|
|
20
|
-
checkedIcon: /*#__PURE__*/_jsxs(SvgIcon, {
|
|
21
|
-
children: [/*#__PURE__*/_jsx("rect", {
|
|
22
|
-
width: "18",
|
|
23
|
-
height: "18",
|
|
24
|
-
x: "3",
|
|
25
|
-
y: "3",
|
|
26
|
-
fill: "currentColor",
|
|
27
|
-
rx: "2"
|
|
28
|
-
}), /*#__PURE__*/_jsx("path", {
|
|
29
|
-
fill: Color.White,
|
|
30
|
-
d: "M15.73 8l-.63.63c-1.43 1.43-2.94 3.05-4.37 4.5l-1.9-1.57-.7-.57L7 12.38l.7.57 2.53 2.09.63.52.58-.58c1.6-1.62 3.35-3.5 4.93-5.08l.63-.63L15.73 8z"
|
|
31
|
-
})]
|
|
32
|
-
}),
|
|
33
|
-
indeterminateIcon: /*#__PURE__*/_jsxs(SvgIcon, {
|
|
34
|
-
children: [/*#__PURE__*/_jsx("rect", {
|
|
35
|
-
width: "18",
|
|
36
|
-
height: "18",
|
|
37
|
-
x: "3",
|
|
38
|
-
y: "3",
|
|
39
|
-
fill: "currentIcon",
|
|
40
|
-
rx: "2"
|
|
41
|
-
}), /*#__PURE__*/_jsx("path", {
|
|
42
|
-
fill: Color.White,
|
|
43
|
-
d: "M7 11h10v2H7v-2z"
|
|
44
|
-
})]
|
|
6
|
+
theme.props.MuiCheckbox = {
|
|
7
|
+
color: 'primary',
|
|
8
|
+
icon: /*#__PURE__*/_jsx(SvgIcon, {
|
|
9
|
+
children: /*#__PURE__*/_jsx("rect", {
|
|
10
|
+
width: "17",
|
|
11
|
+
height: "17",
|
|
12
|
+
x: "3.5",
|
|
13
|
+
y: "3.5",
|
|
14
|
+
fill: Color.White,
|
|
15
|
+
stroke: "currentColor",
|
|
16
|
+
rx: "1.5"
|
|
45
17
|
})
|
|
18
|
+
}),
|
|
19
|
+
checkedIcon: /*#__PURE__*/_jsxs(SvgIcon, {
|
|
20
|
+
children: [/*#__PURE__*/_jsx("rect", {
|
|
21
|
+
width: "18",
|
|
22
|
+
height: "18",
|
|
23
|
+
x: "3",
|
|
24
|
+
y: "3",
|
|
25
|
+
fill: "currentColor",
|
|
26
|
+
rx: "2"
|
|
27
|
+
}), /*#__PURE__*/_jsx("path", {
|
|
28
|
+
fill: Color.White,
|
|
29
|
+
d: "M15.73 8l-.63.63c-1.43 1.43-2.94 3.05-4.37 4.5l-1.9-1.57-.7-.57L7 12.38l.7.57 2.53 2.09.63.52.58-.58c1.6-1.62 3.35-3.5 4.93-5.08l.63-.63L15.73 8z"
|
|
30
|
+
})]
|
|
31
|
+
}),
|
|
32
|
+
indeterminateIcon: /*#__PURE__*/_jsxs(SvgIcon, {
|
|
33
|
+
children: [/*#__PURE__*/_jsx("rect", {
|
|
34
|
+
width: "18",
|
|
35
|
+
height: "18",
|
|
36
|
+
x: "3",
|
|
37
|
+
y: "3",
|
|
38
|
+
fill: "currentIcon",
|
|
39
|
+
rx: "2"
|
|
40
|
+
}), /*#__PURE__*/_jsx("path", {
|
|
41
|
+
fill: Color.White,
|
|
42
|
+
d: "M7 11h10v2H7v-2z"
|
|
43
|
+
})]
|
|
44
|
+
})
|
|
45
|
+
};
|
|
46
|
+
theme.overrides.MuiCheckbox = {
|
|
47
|
+
root: {
|
|
48
|
+
color: Color.Dark100,
|
|
49
|
+
marginTop: theme.spacing(-0.625),
|
|
50
|
+
marginBottom: theme.spacing(-0.625)
|
|
46
51
|
},
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
color: Color.
|
|
50
|
-
marginTop: theme.spacing(-0.625),
|
|
51
|
-
marginBottom: theme.spacing(-0.625)
|
|
52
|
-
},
|
|
53
|
-
indeterminate: {
|
|
54
|
-
["&:not(.".concat(checkboxClasses.checked, ")")]: {
|
|
55
|
-
color: Color.Dark100
|
|
56
|
-
},
|
|
57
|
-
["&.".concat(checkboxClasses.disabled)]: {
|
|
58
|
-
color: Color.Silver400
|
|
59
|
-
}
|
|
52
|
+
colorPrimary: {
|
|
53
|
+
'&$checked$disabled': {
|
|
54
|
+
color: Color.Silver500
|
|
60
55
|
},
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
color: Color.Silver500
|
|
64
|
-
},
|
|
65
|
-
["&:hover:not(.".concat(checkboxClasses.checked, ")")]: {
|
|
66
|
-
color: Color.Dark100
|
|
67
|
-
}
|
|
56
|
+
'&:hover:not($checked)': {
|
|
57
|
+
color: Color.Dark100
|
|
68
58
|
}
|
|
69
59
|
}
|
|
70
60
|
};
|
|
@@ -1,105 +1,102 @@
|
|
|
1
1
|
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
-
import {
|
|
2
|
+
import { SvgIcon } from '@material-ui/core';
|
|
3
3
|
import { Color } from "../theme/Color.js";
|
|
4
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
5
5
|
export function overrideChip(theme) {
|
|
6
6
|
var sm = theme.breakpoints.up('sm');
|
|
7
|
-
theme.
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
children: /*#__PURE__*/_jsx(
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
fill: "currentColor"
|
|
17
|
-
})
|
|
7
|
+
theme.props.MuiChip = {
|
|
8
|
+
size: 'small',
|
|
9
|
+
deleteIcon: /*#__PURE__*/_jsx("div", {
|
|
10
|
+
children: /*#__PURE__*/_jsx(SvgIcon, {
|
|
11
|
+
children: /*#__PURE__*/_jsx("path", {
|
|
12
|
+
fillRule: "evenodd",
|
|
13
|
+
clipRule: "evenodd",
|
|
14
|
+
d: "M13.239 12L17 8.239 15.761 7 12 10.761 8.239 7 7 8.239 10.761 12 7 15.761 8.239 17 12 13.239 15.761 17 17 15.761 13.239 12z",
|
|
15
|
+
fill: "currentColor"
|
|
18
16
|
})
|
|
19
17
|
})
|
|
18
|
+
})
|
|
19
|
+
};
|
|
20
|
+
theme.overrides.MuiChip = {
|
|
21
|
+
root: _objectSpread(_objectSpread({}, theme.typography.body2), {}, {
|
|
22
|
+
color: undefined,
|
|
23
|
+
height: undefined,
|
|
24
|
+
borderRadius: 4,
|
|
25
|
+
backgroundColor: Color.Silver200,
|
|
26
|
+
'&$disabled': {
|
|
27
|
+
opacity: undefined,
|
|
28
|
+
color: Color.Dark100
|
|
29
|
+
}
|
|
30
|
+
}),
|
|
31
|
+
sizeSmall: {
|
|
32
|
+
height: undefined
|
|
20
33
|
},
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
sizeSmall: {
|
|
33
|
-
height: 'unset'
|
|
34
|
-
},
|
|
35
|
-
labelSmall: {
|
|
36
|
-
paddingLeft: 6,
|
|
37
|
-
paddingRight: 6,
|
|
38
|
-
[sm]: {
|
|
39
|
-
paddingLeft: 4,
|
|
40
|
-
paddingRight: 4
|
|
41
|
-
}
|
|
34
|
+
labelSmall: {
|
|
35
|
+
paddingLeft: 6,
|
|
36
|
+
paddingRight: 6,
|
|
37
|
+
[sm]: {
|
|
38
|
+
paddingLeft: 4,
|
|
39
|
+
paddingRight: 4
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
clickable: {
|
|
43
|
+
'&:hover, &:focus': {
|
|
44
|
+
backgroundColor: undefined
|
|
42
45
|
},
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
backgroundColor: Color.Silver200
|
|
46
|
-
},
|
|
47
|
-
'&:active': {
|
|
48
|
-
boxShadow: 'unset'
|
|
49
|
-
},
|
|
50
|
-
'&:focus': {
|
|
51
|
-
boxShadow: "0 0 0 2px ".concat(Color.Silver300)
|
|
52
|
-
},
|
|
53
|
-
'&:active, &:hover': {
|
|
54
|
-
backgroundColor: Color.Silver300
|
|
55
|
-
}
|
|
46
|
+
'&:active': {
|
|
47
|
+
boxShadow: undefined
|
|
56
48
|
},
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
backgroundColor: Color.Silver200,
|
|
60
|
-
boxShadow: "0 0 0 2px ".concat(Color.Silver300)
|
|
61
|
-
}
|
|
49
|
+
'&:focus': {
|
|
50
|
+
boxShadow: "0 0 0 2px ".concat(Color.Silver300)
|
|
62
51
|
},
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
52
|
+
'&:active, &:hover': {
|
|
53
|
+
backgroundColor: Color.Silver300
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
deletable: {
|
|
57
|
+
'&:focus': {
|
|
58
|
+
backgroundColor: undefined,
|
|
59
|
+
boxShadow: "0 0 0 2px ".concat(Color.Silver300)
|
|
60
|
+
}
|
|
61
|
+
},
|
|
62
|
+
deleteIcon: {
|
|
63
|
+
width: undefined,
|
|
64
|
+
height: undefined,
|
|
65
|
+
display: 'flex',
|
|
66
|
+
transition: theme.transitions.create('background-color'),
|
|
67
|
+
'&:active, &:hover, &:focus': {
|
|
74
68
|
'& > svg': {
|
|
75
|
-
|
|
76
|
-
color: Color.Dark200,
|
|
77
|
-
fontSize: '1em'
|
|
78
|
-
}
|
|
79
|
-
},
|
|
80
|
-
deleteIconSmall: {
|
|
81
|
-
width: 'unset',
|
|
82
|
-
height: 'unset',
|
|
83
|
-
padding: theme.spacing(0.5),
|
|
84
|
-
marginLeft: theme.spacing(-0.5),
|
|
85
|
-
marginRight: theme.spacing(0.25),
|
|
86
|
-
[sm]: {
|
|
87
|
-
marginRight: 0
|
|
69
|
+
backgroundColor: Color.Silver400
|
|
88
70
|
}
|
|
89
71
|
},
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
72
|
+
'& > svg': {
|
|
73
|
+
borderRadius: '50%',
|
|
74
|
+
color: Color.Dark200,
|
|
75
|
+
fontSize: '1em'
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
deleteIconSmall: {
|
|
79
|
+
width: undefined,
|
|
80
|
+
height: undefined,
|
|
81
|
+
padding: theme.spacing(0.5),
|
|
82
|
+
marginLeft: theme.spacing(-0.5),
|
|
83
|
+
marginRight: theme.spacing(0.25),
|
|
84
|
+
[sm]: {
|
|
85
|
+
marginRight: 0
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
icon: {
|
|
89
|
+
color: Color.Dark100,
|
|
90
|
+
fontSize: '1em',
|
|
91
|
+
marginRight: undefined
|
|
92
|
+
},
|
|
93
|
+
iconSmall: {
|
|
94
|
+
width: undefined,
|
|
95
|
+
height: undefined,
|
|
96
|
+
marginLeft: 8,
|
|
97
|
+
marginRight: undefined,
|
|
98
|
+
[sm]: {
|
|
99
|
+
marginLeft: 4
|
|
103
100
|
}
|
|
104
101
|
}
|
|
105
102
|
};
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
2
1
|
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
3
|
var _excluded = ["size"];
|
|
4
|
-
import {
|
|
4
|
+
import { SvgIcon, Typography } from '@material-ui/core';
|
|
5
|
+
import { makeStyles } from '@material-ui/styles';
|
|
6
|
+
import clsx from 'clsx';
|
|
5
7
|
import { forwardRef } from 'react';
|
|
6
8
|
import { OverflowText } from "../overflow-text/OverflowText.js";
|
|
7
9
|
import { Color } from "../theme/Color.js";
|
|
@@ -9,18 +11,29 @@ import { isEmptyReactNode } from "../utils/isEmptyReactNode.js";
|
|
|
9
11
|
import { useUID } from "../utils/useUID.js";
|
|
10
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
11
13
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
slot: 'Root'
|
|
15
|
-
})({
|
|
16
|
-
display: 'flex',
|
|
17
|
-
alignItems: 'center'
|
|
18
|
-
});
|
|
19
|
-
var DescriptionListItemIcon = /*#__PURE__*/styled('div')(_ref => {
|
|
20
|
-
var {
|
|
21
|
-
theme
|
|
22
|
-
} = _ref;
|
|
14
|
+
|
|
15
|
+
function sizeVariant(theme, mobileSpacing, desktopSpacing) {
|
|
23
16
|
return {
|
|
17
|
+
'& > $list, & > $item': {
|
|
18
|
+
'&:not(:last-child)': {
|
|
19
|
+
paddingBottom: theme.spacing(mobileSpacing),
|
|
20
|
+
[theme.breakpoints.up('sm')]: {
|
|
21
|
+
paddingBottom: theme.spacing(desktopSpacing)
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
var useStyles = /*#__PURE__*/makeStyles(theme => ({
|
|
29
|
+
list: sizeVariant(theme, 2, 1),
|
|
30
|
+
listSmall: sizeVariant(theme, 1, 0.5),
|
|
31
|
+
listLarge: sizeVariant(theme, 3, 2),
|
|
32
|
+
item: {
|
|
33
|
+
display: 'flex',
|
|
34
|
+
alignItems: 'center'
|
|
35
|
+
},
|
|
36
|
+
icon: {
|
|
24
37
|
display: 'inline-flex',
|
|
25
38
|
marginRight: theme.spacing(1),
|
|
26
39
|
'& > .MuiSvgIcon-root': {
|
|
@@ -30,11 +43,33 @@ var DescriptionListItemIcon = /*#__PURE__*/styled('div')(_ref => {
|
|
|
30
43
|
fontSize: theme.spacing(2)
|
|
31
44
|
}
|
|
32
45
|
}
|
|
33
|
-
}
|
|
46
|
+
}
|
|
47
|
+
}), {
|
|
48
|
+
name: 'SD-DescriptionList'
|
|
49
|
+
}); //
|
|
50
|
+
// DescriptionList
|
|
51
|
+
//
|
|
52
|
+
|
|
53
|
+
export var DescriptionList = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
54
|
+
var {
|
|
55
|
+
size
|
|
56
|
+
} = _ref,
|
|
57
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
58
|
+
|
|
59
|
+
var styles = useStyles();
|
|
60
|
+
return /*#__PURE__*/_jsx("div", _objectSpread(_objectSpread({}, props), {}, {
|
|
61
|
+
ref: ref,
|
|
62
|
+
"data-size": size,
|
|
63
|
+
className: clsx(styles.list, {
|
|
64
|
+
'small': styles.listSmall,
|
|
65
|
+
'large': styles.listLarge
|
|
66
|
+
}[size])
|
|
67
|
+
}));
|
|
34
68
|
}); //
|
|
35
69
|
// DescriptionListItem
|
|
36
70
|
//
|
|
37
71
|
|
|
72
|
+
if (process.env.NODE_ENV !== "production") DescriptionList.displayName = "DescriptionList";
|
|
38
73
|
export var DescriptionListItem = /*#__PURE__*/forwardRef((_ref2, ref) => {
|
|
39
74
|
var _ref3, _contentTypographyPro, _contentTypographyPro2;
|
|
40
75
|
|
|
@@ -47,12 +82,15 @@ export var DescriptionListItem = /*#__PURE__*/forwardRef((_ref2, ref) => {
|
|
|
47
82
|
contentTypographyProps,
|
|
48
83
|
fallback
|
|
49
84
|
} = _ref2;
|
|
85
|
+
var styles = useStyles();
|
|
50
86
|
var labelID = useUID(labelTypographyProps === null || labelTypographyProps === void 0 ? void 0 : labelTypographyProps.id);
|
|
51
87
|
var shouldRenderFallback = isEmptyReactNode(content);
|
|
52
|
-
return /*#__PURE__*/_jsxs(
|
|
88
|
+
return /*#__PURE__*/_jsxs("div", {
|
|
53
89
|
ref: ref,
|
|
90
|
+
className: styles.item,
|
|
54
91
|
"aria-labelledby": label != null ? labelID : undefined,
|
|
55
|
-
children: [!!icon && /*#__PURE__*/_jsx(
|
|
92
|
+
children: [!!icon && /*#__PURE__*/_jsx("div", {
|
|
93
|
+
className: styles.icon,
|
|
56
94
|
children: icon
|
|
57
95
|
}), /*#__PURE__*/_jsxs(OverflowText, _objectSpread(_objectSpread({}, contentTypographyProps), {}, {
|
|
58
96
|
component: "span",
|
|
@@ -69,46 +107,5 @@ export var DescriptionListItem = /*#__PURE__*/forwardRef((_ref2, ref) => {
|
|
|
69
107
|
})), label != null && ' ', !shouldRenderFallback ? content : fallback]
|
|
70
108
|
}))]
|
|
71
109
|
});
|
|
72
|
-
}); //
|
|
73
|
-
// DescriptionList
|
|
74
|
-
//
|
|
75
|
-
|
|
76
|
-
if (process.env.NODE_ENV !== "production") DescriptionListItem.displayName = "DescriptionListItem";
|
|
77
|
-
var DescriptionListRoot = /*#__PURE__*/styled('div', {
|
|
78
|
-
name: 'SD-DescriptionList',
|
|
79
|
-
slot: 'Root'
|
|
80
|
-
})(_ref4 => {
|
|
81
|
-
var {
|
|
82
|
-
theme
|
|
83
|
-
} = _ref4;
|
|
84
|
-
return _objectSpread(_objectSpread({}, sizeVariant(theme, 2, 1)), {}, {
|
|
85
|
-
'&[data-size="small"]': sizeVariant(theme, 1, 0.5),
|
|
86
|
-
'&[data-size="large"]': sizeVariant(theme, 3, 2)
|
|
87
|
-
});
|
|
88
|
-
});
|
|
89
|
-
|
|
90
|
-
function sizeVariant(theme, mobileSpacing, desktopSpacing) {
|
|
91
|
-
return {
|
|
92
|
-
["& > ".concat(DescriptionListRoot.toString(), ", & > ").concat(DescriptionListItemRoot.toString())]: {
|
|
93
|
-
'&:not(:last-child)': {
|
|
94
|
-
paddingBottom: theme.spacing(mobileSpacing),
|
|
95
|
-
[theme.breakpoints.up('sm')]: {
|
|
96
|
-
paddingBottom: theme.spacing(desktopSpacing)
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
};
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
export var DescriptionList = /*#__PURE__*/forwardRef((_ref5, ref) => {
|
|
104
|
-
var {
|
|
105
|
-
size
|
|
106
|
-
} = _ref5,
|
|
107
|
-
props = _objectWithoutProperties(_ref5, _excluded);
|
|
108
|
-
|
|
109
|
-
return /*#__PURE__*/_jsx(DescriptionListRoot, _objectSpread(_objectSpread({}, props), {}, {
|
|
110
|
-
ref: ref,
|
|
111
|
-
"data-size": size
|
|
112
|
-
}));
|
|
113
110
|
});
|
|
114
|
-
if (process.env.NODE_ENV !== "production")
|
|
111
|
+
if (process.env.NODE_ENV !== "production") DescriptionListItem.displayName = "DescriptionListItem";
|
|
@@ -1,42 +1,36 @@
|
|
|
1
|
-
import
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
2
|
export function overrideDialog(theme) {
|
|
3
|
-
theme.
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
3
|
+
theme.props.MuiDialogTitle = {
|
|
4
|
+
disableTypography: true
|
|
5
|
+
};
|
|
6
|
+
theme.overrides.MuiDialog = {
|
|
7
|
+
paper: {
|
|
8
|
+
margin: theme.spacing(3)
|
|
9
|
+
},
|
|
10
|
+
paperWidthXs: {
|
|
11
|
+
maxWidth: Math.max(theme.breakpoints.values.xs, 360),
|
|
12
|
+
'&$paperScrollBody': {
|
|
13
|
+
[theme.breakpoints.down(Math.max(theme.breakpoints.values.xs, 360) + 32 * 2)]: {
|
|
14
|
+
maxWidth: 'calc(100% - 64px)'
|
|
14
15
|
}
|
|
15
16
|
}
|
|
16
17
|
}
|
|
17
18
|
};
|
|
18
|
-
theme.
|
|
19
|
-
|
|
20
|
-
// @ts-expect-error DialogTitleProps has missing type def
|
|
21
|
-
variant: 'h3'
|
|
22
|
-
}
|
|
19
|
+
theme.overrides.MuiDialogTitle = {
|
|
20
|
+
root: _objectSpread({}, theme.typography.h3)
|
|
23
21
|
};
|
|
24
|
-
theme.
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
padding: theme.spacing(0, 3)
|
|
28
|
-
}
|
|
22
|
+
theme.overrides.MuiDialogContent = {
|
|
23
|
+
root: {
|
|
24
|
+
padding: theme.spacing(0, 3)
|
|
29
25
|
}
|
|
30
26
|
};
|
|
31
|
-
theme.
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
marginLeft: theme.spacing(2)
|
|
39
|
-
}
|
|
27
|
+
theme.overrides.MuiDialogActions = {
|
|
28
|
+
root: {
|
|
29
|
+
padding: theme.spacing(3)
|
|
30
|
+
},
|
|
31
|
+
spacing: {
|
|
32
|
+
'& > :not(:first-child)': {
|
|
33
|
+
marginLeft: theme.spacing(2)
|
|
40
34
|
}
|
|
41
35
|
}
|
|
42
36
|
};
|
|
@@ -1,34 +1,31 @@
|
|
|
1
1
|
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
-
var _excluded = ["children"];
|
|
4
|
-
import { AppBar,
|
|
3
|
+
var _excluded = ["children", "className"];
|
|
4
|
+
import { AppBar, Toolbar } from '@material-ui/core';
|
|
5
|
+
import { makeStyles } from '@material-ui/styles';
|
|
6
|
+
import clsx from 'clsx';
|
|
5
7
|
import { forwardRef } from 'react';
|
|
6
8
|
import { Color } from "../theme/Color.js";
|
|
7
9
|
import { VisibilityObserver } from "../utils/VisibilityObserver.js";
|
|
8
10
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
11
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
10
12
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
11
|
-
var
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
borderTopColor: Color.Transparent
|
|
13
|
+
var useStyles = /*#__PURE__*/makeStyles(theme => ({
|
|
14
|
+
appBar: {
|
|
15
|
+
'&&': {
|
|
16
|
+
bottom: 0,
|
|
17
|
+
top: 'auto',
|
|
18
|
+
borderLeft: 'none',
|
|
19
|
+
borderRight: 'none',
|
|
20
|
+
borderBottom: 'none',
|
|
21
|
+
transition: theme.transitions.create(['border-color']),
|
|
22
|
+
'&:not($appBarSticky)': {
|
|
23
|
+
borderTopColor: Color.Transparent
|
|
24
|
+
}
|
|
24
25
|
}
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
var {
|
|
29
|
-
theme
|
|
30
|
-
} = _ref2;
|
|
31
|
-
return {
|
|
26
|
+
},
|
|
27
|
+
appBarSticky: {},
|
|
28
|
+
toolbar: {
|
|
32
29
|
'&.MuiToolbar-gutters': {
|
|
33
30
|
paddingLeft: theme.spacing(3),
|
|
34
31
|
paddingRight: theme.spacing(3),
|
|
@@ -37,26 +34,31 @@ var StyledToolbar = /*#__PURE__*/styled(Toolbar)(_ref2 => {
|
|
|
37
34
|
paddingRight: theme.spacing(4)
|
|
38
35
|
}
|
|
39
36
|
}
|
|
40
|
-
}
|
|
37
|
+
}
|
|
38
|
+
}), {
|
|
39
|
+
name: 'SD-DrawerActions'
|
|
41
40
|
});
|
|
42
|
-
export var DrawerActions = /*#__PURE__*/forwardRef((
|
|
41
|
+
export var DrawerActions = /*#__PURE__*/forwardRef((_ref, appBarRef) => {
|
|
43
42
|
var {
|
|
44
|
-
children
|
|
45
|
-
|
|
46
|
-
|
|
43
|
+
children,
|
|
44
|
+
className
|
|
45
|
+
} = _ref,
|
|
46
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
47
47
|
|
|
48
|
+
var styles = useStyles();
|
|
48
49
|
return /*#__PURE__*/_jsx(VisibilityObserver, {
|
|
49
|
-
render:
|
|
50
|
+
render: _ref2 => {
|
|
50
51
|
var {
|
|
51
52
|
ref,
|
|
52
53
|
visibility
|
|
53
|
-
} =
|
|
54
|
+
} = _ref2;
|
|
54
55
|
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
55
|
-
children: [/*#__PURE__*/_jsx(
|
|
56
|
+
children: [/*#__PURE__*/_jsx(AppBar, _objectSpread(_objectSpread({}, props), {}, {
|
|
56
57
|
ref: appBarRef,
|
|
57
58
|
position: "sticky",
|
|
58
|
-
|
|
59
|
-
children: /*#__PURE__*/_jsx(
|
|
59
|
+
className: clsx(className, styles.appBar, visibility === 'invisible' && styles.appBarSticky),
|
|
60
|
+
children: /*#__PURE__*/_jsx(Toolbar, {
|
|
61
|
+
className: styles.toolbar,
|
|
60
62
|
children: children
|
|
61
63
|
})
|
|
62
64
|
})), /*#__PURE__*/_jsx("div", {
|
|
@@ -1,15 +1,31 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["className"];
|
|
4
|
+
import { makeStyles } from '@material-ui/styles';
|
|
5
|
+
import clsx from 'clsx';
|
|
6
|
+
import { forwardRef } from 'react';
|
|
7
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
|
+
var useStyles = /*#__PURE__*/makeStyles(theme => ({
|
|
9
|
+
root: {
|
|
9
10
|
maxWidth: '100%',
|
|
10
11
|
padding: theme.spacing(2, 3),
|
|
11
12
|
[theme.breakpoints.up('md')]: {
|
|
12
13
|
padding: theme.spacing(2, 4)
|
|
13
14
|
}
|
|
14
|
-
}
|
|
15
|
-
})
|
|
15
|
+
}
|
|
16
|
+
}), {
|
|
17
|
+
name: 'SD-DrawerContent'
|
|
18
|
+
});
|
|
19
|
+
export var DrawerContent = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
20
|
+
var {
|
|
21
|
+
className
|
|
22
|
+
} = _ref,
|
|
23
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
24
|
+
|
|
25
|
+
var styles = useStyles();
|
|
26
|
+
return /*#__PURE__*/_jsx("div", _objectSpread(_objectSpread({}, props), {}, {
|
|
27
|
+
ref: ref,
|
|
28
|
+
className: clsx(styles.root, className)
|
|
29
|
+
}));
|
|
30
|
+
});
|
|
31
|
+
if (process.env.NODE_ENV !== "production") DrawerContent.displayName = "DrawerContent";
|