@superdispatch/ui 0.50.11 → 0.50.12
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.
|
@@ -22,6 +22,7 @@ export function AppDrawer(_ref) {
|
|
|
22
22
|
title,
|
|
23
23
|
subtitle,
|
|
24
24
|
children,
|
|
25
|
+
footer,
|
|
25
26
|
open,
|
|
26
27
|
onClose,
|
|
27
28
|
onBack,
|
|
@@ -59,7 +60,9 @@ export function AppDrawer(_ref) {
|
|
|
59
60
|
})
|
|
60
61
|
}), disableContentPadding ? children : /*#__PURE__*/_jsx(DrawerContent, {
|
|
61
62
|
children: children
|
|
62
|
-
}),
|
|
63
|
+
}), footer && /*#__PURE__*/_jsx(DrawerActions, {
|
|
64
|
+
children: footer
|
|
65
|
+
}), (primaryAction || secondaryAction) && !footer && /*#__PURE__*/_jsx(DrawerActions, {
|
|
63
66
|
children: /*#__PURE__*/_jsxs(StyledActionsLayout, {
|
|
64
67
|
children: [primaryAction && /*#__PURE__*/_jsx(Button, _objectSpread(_objectSpread({
|
|
65
68
|
type: "button",
|
package/dist-types/index.d.ts
CHANGED
|
@@ -61,6 +61,7 @@ interface AppDrawerProps {
|
|
|
61
61
|
title: React.ReactNode;
|
|
62
62
|
subtitle?: React.ReactNode;
|
|
63
63
|
children: React.ReactNode;
|
|
64
|
+
footer?: React.ReactNode;
|
|
64
65
|
primaryAction?: DrawerActionDef;
|
|
65
66
|
secondaryAction?: DrawerActionDef;
|
|
66
67
|
size?: AppDrawerSize;
|
|
@@ -81,7 +82,7 @@ interface AppDrawerProps {
|
|
|
81
82
|
open: boolean;
|
|
82
83
|
onClose: () => void;
|
|
83
84
|
}
|
|
84
|
-
declare function AppDrawer({ title, subtitle, children, open, onClose, onBack, primaryAction, secondaryAction, disableContentPadding, disableCloseButton, size, }: AppDrawerProps): JSX.Element;
|
|
85
|
+
declare function AppDrawer({ title, subtitle, children, footer, open, onClose, onBack, primaryAction, secondaryAction, disableContentPadding, disableCloseButton, size, }: AppDrawerProps): JSX.Element;
|
|
85
86
|
|
|
86
87
|
declare type AvatarButtonClassKey = 'button' | 'overlay' | 'progress' | 'withIcon' | 'sizeLarge' | Exclude<AvatarClassKey, 'circle'>;
|
|
87
88
|
interface AvatarButtonProps extends RefAttributes<HTMLButtonElement>, ButtonHTMLAttributes<HTMLButtonElement> {
|
package/dist-web/index.js
CHANGED
|
@@ -1101,6 +1101,7 @@ function AppDrawer(_ref) {
|
|
|
1101
1101
|
title,
|
|
1102
1102
|
subtitle,
|
|
1103
1103
|
children,
|
|
1104
|
+
footer,
|
|
1104
1105
|
open,
|
|
1105
1106
|
onClose,
|
|
1106
1107
|
onBack,
|
|
@@ -1138,7 +1139,9 @@ function AppDrawer(_ref) {
|
|
|
1138
1139
|
})
|
|
1139
1140
|
}), disableContentPadding ? children : /*#__PURE__*/jsx(DrawerContent, {
|
|
1140
1141
|
children: children
|
|
1141
|
-
}),
|
|
1142
|
+
}), footer && /*#__PURE__*/jsx(DrawerActions, {
|
|
1143
|
+
children: footer
|
|
1144
|
+
}), (primaryAction || secondaryAction) && !footer && /*#__PURE__*/jsx(DrawerActions, {
|
|
1142
1145
|
children: /*#__PURE__*/jsxs(StyledActionsLayout, {
|
|
1143
1146
|
children: [primaryAction && /*#__PURE__*/jsx(Button, _objectSpread(_objectSpread({
|
|
1144
1147
|
type: "button",
|