@astral/ui 0.8.1 → 0.10.0

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.
Files changed (107) hide show
  1. package/Badge/styled.js +6 -6
  2. package/Button/styled.js +3 -3
  3. package/ButtonBase/styled.js +13 -13
  4. package/Checkbox/styled.js +1 -1
  5. package/DashboardLayout/Header/styled.js +10 -10
  6. package/DashboardLayout/SideBar/styled.js +3 -3
  7. package/Dialog/Dialog.d.ts +3 -0
  8. package/Dialog/Dialog.js +39 -0
  9. package/Dialog/index.d.ts +2 -0
  10. package/Dialog/index.js +14 -0
  11. package/Dialog/types.d.ts +7 -0
  12. package/Dialog/types.js +2 -0
  13. package/DialogActions/DialogActions.d.ts +3 -0
  14. package/DialogActions/DialogActions.js +33 -0
  15. package/DialogActions/index.d.ts +1 -0
  16. package/DialogActions/index.js +13 -0
  17. package/DialogContent/DialogContent.d.ts +1 -0
  18. package/DialogContent/DialogContent.js +5 -0
  19. package/DialogContent/index.d.ts +1 -0
  20. package/DialogContent/index.js +13 -0
  21. package/DialogContentText/DialogContentText.d.ts +1 -0
  22. package/DialogContentText/DialogContentText.js +5 -0
  23. package/DialogContentText/index.d.ts +1 -0
  24. package/DialogContentText/index.js +13 -0
  25. package/DialogTitle/DialogTitle.d.ts +3 -0
  26. package/DialogTitle/DialogTitle.js +34 -0
  27. package/DialogTitle/index.d.ts +2 -0
  28. package/DialogTitle/index.js +14 -0
  29. package/DialogTitle/types.d.ts +4 -0
  30. package/DialogTitle/types.js +2 -0
  31. package/FormControlLabel/styled.js +1 -1
  32. package/IconButton/styled.js +1 -1
  33. package/List/styled.js +1 -1
  34. package/ListItem/styled.js +3 -3
  35. package/ListItemButton/styled.js +3 -3
  36. package/MenuList/styled.js +1 -1
  37. package/Radio/styled.js +1 -1
  38. package/Select/styled.js +2 -2
  39. package/Tag/styled.js +5 -5
  40. package/Tooltip/styled.js +6 -6
  41. package/esm/Badge/styled.js +6 -6
  42. package/esm/Button/styled.js +3 -3
  43. package/esm/ButtonBase/styled.js +13 -13
  44. package/esm/Checkbox/styled.js +1 -1
  45. package/esm/DashboardLayout/Header/styled.js +10 -10
  46. package/esm/DashboardLayout/SideBar/styled.js +3 -3
  47. package/esm/Dialog/Dialog.d.ts +3 -0
  48. package/esm/Dialog/Dialog.js +35 -0
  49. package/esm/Dialog/index.d.ts +2 -0
  50. package/esm/Dialog/index.js +2 -0
  51. package/esm/Dialog/types.d.ts +7 -0
  52. package/esm/Dialog/types.js +1 -0
  53. package/esm/DialogActions/DialogActions.d.ts +3 -0
  54. package/esm/DialogActions/DialogActions.js +29 -0
  55. package/esm/DialogActions/index.d.ts +1 -0
  56. package/esm/DialogActions/index.js +1 -0
  57. package/esm/DialogContent/DialogContent.d.ts +1 -0
  58. package/esm/DialogContent/DialogContent.js +1 -0
  59. package/esm/DialogContent/index.d.ts +1 -0
  60. package/esm/DialogContent/index.js +1 -0
  61. package/esm/DialogContentText/DialogContentText.d.ts +1 -0
  62. package/esm/DialogContentText/DialogContentText.js +1 -0
  63. package/esm/DialogContentText/index.d.ts +1 -0
  64. package/esm/DialogContentText/index.js +1 -0
  65. package/esm/DialogTitle/DialogTitle.d.ts +3 -0
  66. package/esm/DialogTitle/DialogTitle.js +30 -0
  67. package/esm/DialogTitle/index.d.ts +2 -0
  68. package/esm/DialogTitle/index.js +2 -0
  69. package/esm/DialogTitle/types.d.ts +4 -0
  70. package/esm/DialogTitle/types.js +1 -0
  71. package/esm/FormControlLabel/styled.js +1 -1
  72. package/esm/IconButton/styled.js +1 -1
  73. package/esm/List/styled.js +1 -1
  74. package/esm/ListItem/styled.js +3 -3
  75. package/esm/ListItemButton/styled.js +3 -3
  76. package/esm/MenuList/styled.js +1 -1
  77. package/esm/Radio/styled.js +1 -1
  78. package/esm/Select/styled.js +2 -2
  79. package/esm/Tag/styled.js +5 -5
  80. package/esm/Tooltip/styled.js +6 -6
  81. package/esm/index.d.ts +5 -0
  82. package/esm/index.js +5 -0
  83. package/esm/theme/components/MuiDialog.d.ts +3 -0
  84. package/esm/theme/components/MuiDialog.js +16 -0
  85. package/esm/theme/components/MuiDialogActions.d.ts +3 -0
  86. package/esm/theme/components/MuiDialogActions.js +13 -0
  87. package/esm/theme/components/MuiDialogContent.d.ts +3 -0
  88. package/esm/theme/components/MuiDialogContent.js +10 -0
  89. package/esm/theme/components/MuiDialogTitle.d.ts +3 -0
  90. package/esm/theme/components/MuiDialogTitle.js +19 -0
  91. package/esm/theme/components/components.js +8 -0
  92. package/esm/theme/palette/palette.d.ts +1 -0
  93. package/esm/theme/palette/palette.js +1 -0
  94. package/index.d.ts +5 -0
  95. package/index.js +5 -0
  96. package/package.json +12 -2
  97. package/theme/components/MuiDialog.d.ts +3 -0
  98. package/theme/components/MuiDialog.js +19 -0
  99. package/theme/components/MuiDialogActions.d.ts +3 -0
  100. package/theme/components/MuiDialogActions.js +16 -0
  101. package/theme/components/MuiDialogContent.d.ts +3 -0
  102. package/theme/components/MuiDialogContent.js +13 -0
  103. package/theme/components/MuiDialogTitle.d.ts +3 -0
  104. package/theme/components/MuiDialogTitle.js +22 -0
  105. package/theme/components/components.js +8 -0
  106. package/theme/palette/palette.d.ts +1 -0
  107. package/theme/palette/palette.js +1 -0
package/esm/Tag/styled.js CHANGED
@@ -111,18 +111,18 @@ export var StyledTag = styled(Chip, {
111
111
  shouldForwardProp: function (prop) {
112
112
  return prop !== 'customColor' && prop !== 'customVariant' && prop !== 'rounded';
113
113
  },
114
- })(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n user-select: none;\n font-size: 14px;\n height: 20px;\n border-radius: ", ";\n background-color: ", ";\n\n &:hover {\n background-color: ", ";\n color: ", ";\n }\n &:active {\n background-color: ", ";\n color: ", ";\n }\n\n .MuiChip-label {\n padding: ", ";\n\n color: ", ";\n\n &:hover {\n color: ", ";\n }\n &:active {\n color: ", ";\n }\n }\n .MuiChip-deleteIcon {\n margin: 0;\n width: 20px;\n height: 20px;\n border-radius: ", ";\n color: ", ";\n background: ", ";\n\n &:hover {\n color: ", ";\n background: ", ";\n }\n &:active {\n color: ", ";\n background: ", ";\n }\n }\n .MuiChip-avatar {\n margin: 2px;\n width: 16px;\n height: 16px;\n }\n .MuiChip-icon {\n width: 16px;\n height: 16px;\n }\n"], ["\n user-select: none;\n font-size: 14px;\n height: 20px;\n border-radius: ", ";\n background-color: ", ";\n\n &:hover {\n background-color: ", ";\n color: ", ";\n }\n &:active {\n background-color: ", ";\n color: ", ";\n }\n\n .MuiChip-label {\n padding: ", ";\n\n color: ", ";\n\n &:hover {\n color: ", ";\n }\n &:active {\n color: ", ";\n }\n }\n .MuiChip-deleteIcon {\n margin: 0;\n width: 20px;\n height: 20px;\n border-radius: ", ";\n color: ", ";\n background: ", ";\n\n &:hover {\n color: ", ";\n background: ", ";\n }\n &:active {\n color: ", ";\n background: ", ";\n }\n }\n .MuiChip-avatar {\n margin: 2px;\n width: 16px;\n height: 16px;\n }\n .MuiChip-icon {\n width: 16px;\n height: 16px;\n }\n"])), function (props) { return getShape(__assign({}, props)); }, function (props) {
114
+ })(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n height: 20px;\n\n font-size: 14px;\n\n background-color: ", ";\n border-radius: ", ";\n\n user-select: none;\n\n &:hover {\n color: ", ";\n\n background-color: ", ";\n }\n\n &:active {\n color: ", ";\n\n background-color: ", ";\n }\n\n .MuiChip-label {\n padding: ", ";\n\n color: ", ";\n\n &:hover {\n color: ", ";\n }\n\n &:active {\n color: ", ";\n }\n }\n\n .MuiChip-deleteIcon {\n width: 20px;\n height: 20px;\n margin: 0;\n\n color: ", ";\n\n background: ", ";\n border-radius: ", ";\n\n &:hover {\n color: ", ";\n\n background: ", ";\n }\n\n &:active {\n color: ", ";\n\n background: ", ";\n }\n }\n\n .MuiChip-avatar {\n width: 16px;\n height: 16px;\n margin: 2px;\n }\n\n .MuiChip-icon {\n width: 16px;\n height: 16px;\n }\n"], ["\n height: 20px;\n\n font-size: 14px;\n\n background-color: ", ";\n border-radius: ", ";\n\n user-select: none;\n\n &:hover {\n color: ", ";\n\n background-color: ", ";\n }\n\n &:active {\n color: ", ";\n\n background-color: ", ";\n }\n\n .MuiChip-label {\n padding: ", ";\n\n color: ", ";\n\n &:hover {\n color: ", ";\n }\n\n &:active {\n color: ", ";\n }\n }\n\n .MuiChip-deleteIcon {\n width: 20px;\n height: 20px;\n margin: 0;\n\n color: ", ";\n\n background: ", ";\n border-radius: ", ";\n\n &:hover {\n color: ", ";\n\n background: ", ";\n }\n\n &:active {\n color: ", ";\n\n background: ", ";\n }\n }\n\n .MuiChip-avatar {\n width: 16px;\n height: 16px;\n margin: 2px;\n }\n\n .MuiChip-icon {\n width: 16px;\n height: 16px;\n }\n"])), function (props) {
115
115
  return getBgColor(__assign(__assign({}, props), { tagState: TagStates.DEFAULT }));
116
- }, function (props) {
116
+ }, function (props) { return getShape(__assign({}, props)); }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.HOVER })); }, function (props) {
117
117
  return getBgColor(__assign(__assign({}, props), { tagState: TagStates.HOVER }));
118
- }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.HOVER })); }, function (props) {
118
+ }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.ACTIVE })); }, function (props) {
119
119
  return getBgColor(__assign(__assign({}, props), { tagState: TagStates.ACTIVE }));
120
- }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.ACTIVE })); }, function (props) { return getTagLabelPadding(__assign({}, props)); }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.DEFAULT })); }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.HOVER })); }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.ACTIVE })); }, function (props) { return getDeleteIconBorderRadius(__assign({}, props)); }, function (_a) {
120
+ }, function (props) { return getTagLabelPadding(__assign({}, props)); }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.DEFAULT })); }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.HOVER })); }, function (props) { return getColor(__assign(__assign({}, props), { tagState: TagStates.ACTIVE })); }, function (_a) {
121
121
  var theme = _a.theme;
122
122
  return theme.palette.grey[800];
123
123
  }, function (props) {
124
124
  return getDeleteIconBgColor(__assign(__assign({}, props), { iconState: TagStates.DEFAULT }));
125
- }, function (_a) {
125
+ }, function (props) { return getDeleteIconBorderRadius(__assign({}, props)); }, function (_a) {
126
126
  var theme = _a.theme;
127
127
  return theme.palette.grey[800];
128
128
  }, function (props) {
@@ -31,12 +31,9 @@ import { TooltipSizes } from './constants';
31
31
  export var StyledTooltip = styled(function (_a) {
32
32
  var className = _a.className, props = __rest(_a, ["className"]);
33
33
  return (_jsx(Tooltip, __assign({}, props, { classes: { popper: className } }), void 0));
34
- })(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n & .MuiTooltip-tooltip {\n margin: 0;\n background-color: ", ";\n border-radius: ", ";\n font-size: ", ";\n line-height: ", ";\n font-weight: ", ";\n }\n\n & .MuiTooltip-arrow {\n color: ", ";\n }\n\n &&[data-popper-placement*='top'] .MuiTooltip-tooltip {\n margin-bottom: ", ";\n }\n\n &&[data-popper-placement*='bottom'] .MuiTooltip-tooltip {\n margin-top: ", ";\n }\n\n &&[data-popper-placement*='left'] .MuiTooltip-tooltip {\n margin-right: ", ";\n }\n\n &&[data-popper-placement*='right'] .MuiTooltip-tooltip {\n margin-left: ", ";\n }\n"], ["\n & .MuiTooltip-tooltip {\n margin: 0;\n background-color: ", ";\n border-radius: ", ";\n font-size: ", ";\n line-height: ", ";\n font-weight: ", ";\n }\n\n & .MuiTooltip-arrow {\n color: ", ";\n }\n\n &&[data-popper-placement*='top'] .MuiTooltip-tooltip {\n margin-bottom: ", ";\n }\n\n &&[data-popper-placement*='bottom'] .MuiTooltip-tooltip {\n margin-top: ", ";\n }\n\n &&[data-popper-placement*='left'] .MuiTooltip-tooltip {\n margin-right: ", ";\n }\n\n &&[data-popper-placement*='right'] .MuiTooltip-tooltip {\n margin-left: ", ";\n }\n"])), function (_a) {
34
+ })(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n & .MuiTooltip-tooltip {\n margin: 0;\n\n font-weight: ", ";\n font-size: ", ";\n line-height: ", ";\n\n background-color: ", ";\n border-radius: ", ";\n }\n\n & .MuiTooltip-arrow {\n color: ", ";\n }\n\n &&[data-popper-placement*='top'] .MuiTooltip-tooltip {\n margin-bottom: ", ";\n }\n\n &&[data-popper-placement*='bottom'] .MuiTooltip-tooltip {\n margin-top: ", ";\n }\n\n &&[data-popper-placement*='left'] .MuiTooltip-tooltip {\n margin-right: ", ";\n }\n\n &&[data-popper-placement*='right'] .MuiTooltip-tooltip {\n margin-left: ", ";\n }\n"], ["\n & .MuiTooltip-tooltip {\n margin: 0;\n\n font-weight: ", ";\n font-size: ", ";\n line-height: ", ";\n\n background-color: ", ";\n border-radius: ", ";\n }\n\n & .MuiTooltip-arrow {\n color: ", ";\n }\n\n &&[data-popper-placement*='top'] .MuiTooltip-tooltip {\n margin-bottom: ", ";\n }\n\n &&[data-popper-placement*='bottom'] .MuiTooltip-tooltip {\n margin-top: ", ";\n }\n\n &&[data-popper-placement*='left'] .MuiTooltip-tooltip {\n margin-right: ", ";\n }\n\n &&[data-popper-placement*='right'] .MuiTooltip-tooltip {\n margin-left: ", ";\n }\n"])), function (_a) {
35
35
  var theme = _a.theme;
36
- return theme.palette.grey[900];
37
- }, function (_a) {
38
- var theme = _a.theme;
39
- return theme.shape.small;
36
+ return theme.typography.fontWeightRegular;
40
37
  }, function (_a) {
41
38
  var size = _a.size, theme = _a.theme;
42
39
  return size === TooltipSizes.SMALL
@@ -49,7 +46,10 @@ export var StyledTooltip = styled(function (_a) {
49
46
  : theme.typography.ui.lineHeight;
50
47
  }, function (_a) {
51
48
  var theme = _a.theme;
52
- return theme.typography.fontWeightRegular;
49
+ return theme.palette.grey[900];
50
+ }, function (_a) {
51
+ var theme = _a.theme;
52
+ return theme.shape.small;
53
53
  }, function (_a) {
54
54
  var theme = _a.theme;
55
55
  return theme.palette.grey[900];
package/esm/index.d.ts CHANGED
@@ -22,3 +22,8 @@ export * from './TextArea';
22
22
  export * from './DashboardLayout';
23
23
  export * from './Autocomplete';
24
24
  export * from './Select';
25
+ export * from './Dialog';
26
+ export * from './DialogTitle';
27
+ export * from './DialogContent';
28
+ export * from './DialogContentText';
29
+ export * from './DialogActions';
package/esm/index.js CHANGED
@@ -22,3 +22,8 @@ export * from './TextArea';
22
22
  export * from './DashboardLayout';
23
23
  export * from './Autocomplete';
24
24
  export * from './Select';
25
+ export * from './Dialog';
26
+ export * from './DialogTitle';
27
+ export * from './DialogContent';
28
+ export * from './DialogContentText';
29
+ export * from './DialogActions';
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialog: Components<Theme>['MuiDialog'];
@@ -0,0 +1,16 @@
1
+ export var MuiDialog = {
2
+ styleOverrides: {
3
+ root: function (_a) {
4
+ var theme = _a.theme;
5
+ return {
6
+ background: theme.palette.background.modalShadow,
7
+ };
8
+ },
9
+ paper: function (_a) {
10
+ var theme = _a.theme;
11
+ return {
12
+ borderRadius: theme.shape.small,
13
+ };
14
+ },
15
+ },
16
+ };
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialogActions: Components<Theme>['MuiDialogActions'];
@@ -0,0 +1,13 @@
1
+ export var MuiDialogActions = {
2
+ styleOverrides: {
3
+ root: function (_a) {
4
+ var theme = _a.theme;
5
+ return {
6
+ padding: theme.spacing(4, 6, 6, 6),
7
+ '>div': {
8
+ width: '100%',
9
+ },
10
+ };
11
+ },
12
+ },
13
+ };
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialogContent: Components<Theme>['MuiDialogContent'];
@@ -0,0 +1,10 @@
1
+ export var MuiDialogContent = {
2
+ styleOverrides: {
3
+ root: function (_a) {
4
+ var theme = _a.theme;
5
+ return {
6
+ padding: theme.spacing(0, 6),
7
+ };
8
+ },
9
+ },
10
+ };
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialogTitle: Components<Theme>['MuiDialogTitle'];
@@ -0,0 +1,19 @@
1
+ export var MuiDialogTitle = {
2
+ styleOverrides: {
3
+ root: function (_a) {
4
+ var theme = _a.theme;
5
+ return {
6
+ padding: theme.spacing(6),
7
+ fontSize: theme.typography.h4.fontSize,
8
+ fontWeight: theme.typography.h4.fontWeight,
9
+ lineHeight: theme.typography.h4.lineHeight,
10
+ '& .ButtonUnstyled-root': {
11
+ position: 'absolute',
12
+ right: theme.spacing(5),
13
+ top: theme.spacing(5),
14
+ color: theme.palette.grey[800],
15
+ },
16
+ };
17
+ },
18
+ },
19
+ };
@@ -6,6 +6,10 @@ import { MuiInputLabel } from './MuiInputLabel';
6
6
  import { MuiOutlinedInput } from './MuiOutlinedInput';
7
7
  import { MuiTypography } from './MuiTypography';
8
8
  import { MuiAutocomplete } from './MuiAutocomplete';
9
+ import { MuiDialog } from './MuiDialog';
10
+ import { MuiDialogTitle } from './MuiDialogTitle';
11
+ import { MuiDialogContent } from './MuiDialogContent';
12
+ import { MuiDialogActions } from './MuiDialogActions';
9
13
  var getMuiCssBaseline = function (fontUrls) { return ({
10
14
  styleOverrides: "\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 300;\n font-display: swap;\n src: url(".concat(fontUrls.light.woff2, ") format('woff2'), url(").concat(fontUrls.light.woff, ") format('woff');\n }\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 400;\n font-display: swap;\n src: url(").concat(fontUrls.regular.woff2, ") format('woff2'), url(").concat(fontUrls.regular.woff, ") format('woff');\n }\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 500;\n font-display: swap;\n src: url(").concat(fontUrls.medium.woff2, ") format('woff2'), url(").concat(fontUrls.medium.woff, ") format('woff');\n }\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 700;\n font-display: swap;\n src: url(").concat(fontUrls.bold.woff2, ") format('woff2'), url(").concat(fontUrls.bold.woff, ") format('woff');\n }\n "),
11
15
  }); };
@@ -68,4 +72,8 @@ export var getComponents = function (fontUrls) { return ({
68
72
  MuiMenu: MuiMenu,
69
73
  MuiMenuItem: MuiMenuItem,
70
74
  MuiRadio: MuiRadio,
75
+ MuiDialog: MuiDialog,
76
+ MuiDialogTitle: MuiDialogTitle,
77
+ MuiDialogContent: MuiDialogContent,
78
+ MuiDialogActions: MuiDialogActions,
71
79
  }); };
@@ -16,6 +16,7 @@ export declare type PrimaryColorOptions = PaletteColorOptions & Color;
16
16
  export declare type Background = TypeBackground & {
17
17
  element: string;
18
18
  elementHover: string;
19
+ modalShadow: string;
19
20
  };
20
21
  declare type PaletteOptions = MuiPaletteOptions & {
21
22
  red: Color;
@@ -99,6 +99,7 @@ export var getPalette = function (brand) {
99
99
  paper: '#FFF',
100
100
  element: '#FAFBFC',
101
101
  elementHover: '#EBECF0',
102
+ modalShadow: '#142A438A',
102
103
  },
103
104
  };
104
105
  };
package/index.d.ts CHANGED
@@ -22,3 +22,8 @@ export * from './TextArea';
22
22
  export * from './DashboardLayout';
23
23
  export * from './Autocomplete';
24
24
  export * from './Select';
25
+ export * from './Dialog';
26
+ export * from './DialogTitle';
27
+ export * from './DialogContent';
28
+ export * from './DialogContentText';
29
+ export * from './DialogActions';
package/index.js CHANGED
@@ -34,3 +34,8 @@ __exportStar(require("./TextArea"), exports);
34
34
  __exportStar(require("./DashboardLayout"), exports);
35
35
  __exportStar(require("./Autocomplete"), exports);
36
36
  __exportStar(require("./Select"), exports);
37
+ __exportStar(require("./Dialog"), exports);
38
+ __exportStar(require("./DialogTitle"), exports);
39
+ __exportStar(require("./DialogContent"), exports);
40
+ __exportStar(require("./DialogContentText"), exports);
41
+ __exportStar(require("./DialogActions"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@astral/ui",
3
- "version": "0.8.1",
3
+ "version": "0.10.0",
4
4
  "browser": "./src/index.ts",
5
5
  "jest": {
6
6
  "moduleNameMapper": {
@@ -8,7 +8,7 @@
8
8
  }
9
9
  },
10
10
  "dependencies": {
11
- "@astral/icons": "^0.7.2",
11
+ "@astral/icons": "^0.9.0",
12
12
  "@emotion/cache": "11.7.1",
13
13
  "@emotion/react": "11.8.1",
14
14
  "@emotion/server": "11.4.0",
@@ -21,6 +21,16 @@
21
21
  "peerDependencies": {
22
22
  "react": "^17.0.0"
23
23
  },
24
+ "exports": {
25
+ ".": {
26
+ "import": "./esm/index.js",
27
+ "require": "./cjs/index.js"
28
+ },
29
+ "./server": {
30
+ "import": "./esm/server/index.js",
31
+ "require": "./cjs/server/index.js"
32
+ }
33
+ },
24
34
  "author": "Astral.Soft",
25
35
  "license": "MIT",
26
36
  "repository": {
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialog: Components<Theme>['MuiDialog'];
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MuiDialog = void 0;
4
+ exports.MuiDialog = {
5
+ styleOverrides: {
6
+ root: function (_a) {
7
+ var theme = _a.theme;
8
+ return {
9
+ background: theme.palette.background.modalShadow,
10
+ };
11
+ },
12
+ paper: function (_a) {
13
+ var theme = _a.theme;
14
+ return {
15
+ borderRadius: theme.shape.small,
16
+ };
17
+ },
18
+ },
19
+ };
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialogActions: Components<Theme>['MuiDialogActions'];
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MuiDialogActions = void 0;
4
+ exports.MuiDialogActions = {
5
+ styleOverrides: {
6
+ root: function (_a) {
7
+ var theme = _a.theme;
8
+ return {
9
+ padding: theme.spacing(4, 6, 6, 6),
10
+ '>div': {
11
+ width: '100%',
12
+ },
13
+ };
14
+ },
15
+ },
16
+ };
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialogContent: Components<Theme>['MuiDialogContent'];
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MuiDialogContent = void 0;
4
+ exports.MuiDialogContent = {
5
+ styleOverrides: {
6
+ root: function (_a) {
7
+ var theme = _a.theme;
8
+ return {
9
+ padding: theme.spacing(0, 6),
10
+ };
11
+ },
12
+ },
13
+ };
@@ -0,0 +1,3 @@
1
+ import { Components } from '@mui/material';
2
+ import type { Theme } from '../baseTheme';
3
+ export declare const MuiDialogTitle: Components<Theme>['MuiDialogTitle'];
@@ -0,0 +1,22 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MuiDialogTitle = void 0;
4
+ exports.MuiDialogTitle = {
5
+ styleOverrides: {
6
+ root: function (_a) {
7
+ var theme = _a.theme;
8
+ return {
9
+ padding: theme.spacing(6),
10
+ fontSize: theme.typography.h4.fontSize,
11
+ fontWeight: theme.typography.h4.fontWeight,
12
+ lineHeight: theme.typography.h4.lineHeight,
13
+ '& .ButtonUnstyled-root': {
14
+ position: 'absolute',
15
+ right: theme.spacing(5),
16
+ top: theme.spacing(5),
17
+ color: theme.palette.grey[800],
18
+ },
19
+ };
20
+ },
21
+ },
22
+ };
@@ -9,6 +9,10 @@ var MuiInputLabel_1 = require("./MuiInputLabel");
9
9
  var MuiOutlinedInput_1 = require("./MuiOutlinedInput");
10
10
  var MuiTypography_1 = require("./MuiTypography");
11
11
  var MuiAutocomplete_1 = require("./MuiAutocomplete");
12
+ var MuiDialog_1 = require("./MuiDialog");
13
+ var MuiDialogTitle_1 = require("./MuiDialogTitle");
14
+ var MuiDialogContent_1 = require("./MuiDialogContent");
15
+ var MuiDialogActions_1 = require("./MuiDialogActions");
12
16
  var getMuiCssBaseline = function (fontUrls) { return ({
13
17
  styleOverrides: "\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 300;\n font-display: swap;\n src: url(".concat(fontUrls.light.woff2, ") format('woff2'), url(").concat(fontUrls.light.woff, ") format('woff');\n }\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 400;\n font-display: swap;\n src: url(").concat(fontUrls.regular.woff2, ") format('woff2'), url(").concat(fontUrls.regular.woff, ") format('woff');\n }\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 500;\n font-display: swap;\n src: url(").concat(fontUrls.medium.woff2, ") format('woff2'), url(").concat(fontUrls.medium.woff, ") format('woff');\n }\n @font-face {\n font-family: 'Ubuntu';\n font-style: 'normal';\n font-weight: 700;\n font-display: swap;\n src: url(").concat(fontUrls.bold.woff2, ") format('woff2'), url(").concat(fontUrls.bold.woff, ") format('woff');\n }\n "),
14
18
  }); };
@@ -71,5 +75,9 @@ var getComponents = function (fontUrls) { return ({
71
75
  MuiMenu: MuiMenu,
72
76
  MuiMenuItem: MuiMenuItem,
73
77
  MuiRadio: MuiRadio,
78
+ MuiDialog: MuiDialog_1.MuiDialog,
79
+ MuiDialogTitle: MuiDialogTitle_1.MuiDialogTitle,
80
+ MuiDialogContent: MuiDialogContent_1.MuiDialogContent,
81
+ MuiDialogActions: MuiDialogActions_1.MuiDialogActions,
74
82
  }); };
75
83
  exports.getComponents = getComponents;
@@ -16,6 +16,7 @@ export declare type PrimaryColorOptions = PaletteColorOptions & Color;
16
16
  export declare type Background = TypeBackground & {
17
17
  element: string;
18
18
  elementHover: string;
19
+ modalShadow: string;
19
20
  };
20
21
  declare type PaletteOptions = MuiPaletteOptions & {
21
22
  red: Color;
@@ -102,6 +102,7 @@ var getPalette = function (brand) {
102
102
  paper: '#FFF',
103
103
  element: '#FAFBFC',
104
104
  elementHover: '#EBECF0',
105
+ modalShadow: '#142A438A',
105
106
  },
106
107
  };
107
108
  };