@elliemae/ds-mobile 2.0.0-next.8 → 2.0.0-rc.3
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/cjs/Accordion/Accordion.js +5 -5
- package/cjs/Accordion/index.js +5 -5
- package/cjs/CategoryBox/CategoryBox.js +12 -11
- package/cjs/CollectionBox/CollectionBox.js +14 -13
- package/cjs/FullPageContainer/FullPageContainer.js +7 -2
- package/cjs/FullPageContainer/FullPageContainerScroll.js +7 -2
- package/cjs/GlobalHeader/MobileGlobalHeader.js +28 -24
- package/cjs/GroupBox/GroupBox.js +13 -12
- package/cjs/InfiniteLoader/Infiniteloader.js +11 -9
- package/cjs/InfiniteLoader/Loader.js +12 -9
- package/cjs/InfiniteLoader/VirtualizedInfiniteLoader.js +49 -22
- package/cjs/LoadingPage/Page.js +24 -12
- package/cjs/MobileActionToolbar/MobileActionToolbar.js +8 -7
- package/cjs/MobileActionToolbar/MobileActionToolbarItem.js +6 -1
- package/cjs/MobileBanner/MobileBanner.js +21 -16
- package/cjs/MobileBanner/styles.js +128 -59
- package/cjs/MobileBanner/utils/icons.js +5 -12
- package/cjs/MobileBanner/utils/styleHelpers.js +8 -4
- package/cjs/MobileCard/ActionAddon.js +16 -14
- package/cjs/MobileCard/Card.js +26 -22
- package/cjs/MobileCard/CardIcons.js +21 -16
- package/cjs/MobileCard/ExpandChevron.js +8 -10
- package/cjs/MobileCard/ExpandableRegion.js +5 -4
- package/cjs/MobileCard/Group.js +22 -16
- package/cjs/MobileContextMenu/MobileContextMenu.js +33 -25
- package/cjs/MobileContextMenu/MobileContextMenuGroup.js +35 -25
- package/cjs/MobileContextMenu/MobileContextMenuItem.js +29 -25
- package/cjs/MobileDatePicker/Input.js +5 -0
- package/cjs/MobileDatePicker/MobileDatePicker.js +15 -16
- package/cjs/MobileDropdownMenu/MobileDropdownInput.js +27 -17
- package/cjs/MobileDropdownMenu/MobileDropdownMenu.js +19 -16
- package/cjs/MobileEmtpyState/MobileEmptyState.js +10 -8
- package/cjs/MobileFilterbar/Filterbar.js +13 -10
- package/cjs/MobileFilterbar/FilterbarItem.js +15 -12
- package/cjs/MobileFilterbar/FilterbarSort.js +17 -14
- package/cjs/MobileFooter/Action.js +27 -24
- package/cjs/MobileFooter/Footer.js +15 -8
- package/cjs/MobileFooter/Text.js +6 -3
- package/cjs/MobileListItem/MobileListItem.js +14 -13
- package/cjs/MobilePageHeader/MobilePageHeader.js +35 -35
- package/cjs/MobileSelectList/MobileSelectList.js +29 -22
- package/cjs/MobileSelectList/styled.js +9 -11
- package/cjs/MobileSeparator/Separator.js +30 -18
- package/cjs/MobileTimePicker/Input.js +5 -0
- package/cjs/MobileTimePicker/MobileTimePicker.js +15 -16
- package/cjs/MobileTimePicker/MobileTimePicker.stories.js +2 -2
- package/cjs/MobileTouchable/MobileTouchable.js +7 -2
- package/cjs/Modal/Modal.js +30 -25
- package/cjs/Modal/styled.js +7 -7
- package/cjs/PageFilter/PageFilter.js +20 -15
- package/cjs/PageForm/PageForm.js +22 -15
- package/cjs/PageList/PageList.js +12 -11
- package/cjs/PageSearch/PageSearch.js +14 -13
- package/cjs/PageSummary/PageSummary.js +34 -21
- package/cjs/PageSummary/Tags.js +12 -6
- package/cjs/SideNav/SideNav.js +42 -34
- package/cjs/SwipeToRefresh/ProgressIndicator.js +6 -5
- package/cjs/SwipeToRefresh/SwipeToRefresh.js +8 -7
- package/cjs/SwipeToRefresh/styled.js +4 -4
- package/cjs/SwipeToRefresh/useSwipe.js +5 -4
- package/cjs/Tabs/index.js +8 -3
- package/cjs/index.js +9 -5
- package/esm/Accordion/Accordion.js +1 -1
- package/esm/Accordion/index.js +1 -1
- package/esm/CategoryBox/CategoryBox.js +9 -8
- package/esm/CollectionBox/CollectionBox.js +9 -8
- package/esm/FullPageContainer/FullPageContainer.js +6 -1
- package/esm/FullPageContainer/FullPageContainerScroll.js +6 -1
- package/esm/GlobalHeader/MobileGlobalHeader.js +20 -14
- package/esm/GroupBox/GroupBox.js +10 -9
- package/esm/InfiniteLoader/Infiniteloader.js +9 -7
- package/esm/InfiniteLoader/Loader.js +12 -9
- package/esm/InfiniteLoader/VirtualizedInfiniteLoader.js +50 -23
- package/esm/LoadingPage/Page.js +24 -12
- package/esm/MobileActionToolbar/MobileActionToolbar.js +7 -6
- package/esm/MobileActionToolbar/MobileActionToolbarItem.js +6 -1
- package/esm/MobileBanner/MobileBanner.js +20 -14
- package/esm/MobileBanner/styles.js +128 -59
- package/esm/MobileBanner/utils/icons.js +1 -4
- package/esm/MobileBanner/utils/styleHelpers.js +8 -4
- package/esm/MobileCard/ActionAddon.js +16 -13
- package/esm/MobileCard/Card.js +20 -16
- package/esm/MobileCard/CardIcons.js +20 -15
- package/esm/MobileCard/ExpandChevron.js +8 -8
- package/esm/MobileCard/ExpandableRegion.js +5 -4
- package/esm/MobileCard/Group.js +20 -14
- package/esm/MobileContextMenu/MobileContextMenu.js +26 -18
- package/esm/MobileContextMenu/MobileContextMenuGroup.js +35 -25
- package/esm/MobileContextMenu/MobileContextMenuItem.js +25 -19
- package/esm/MobileDatePicker/Input.js +5 -0
- package/esm/MobileDatePicker/MobileDatePicker.js +12 -11
- package/esm/MobileDropdownMenu/MobileDropdownInput.js +27 -16
- package/esm/MobileDropdownMenu/MobileDropdownMenu.js +19 -16
- package/esm/MobileEmtpyState/MobileEmptyState.js +10 -7
- package/esm/MobileFilterbar/Filterbar.js +13 -10
- package/esm/MobileFilterbar/FilterbarItem.js +15 -12
- package/esm/MobileFilterbar/FilterbarSort.js +17 -14
- package/esm/MobileFooter/Action.js +26 -23
- package/esm/MobileFooter/Footer.js +12 -5
- package/esm/MobileFooter/Text.js +6 -3
- package/esm/MobileListItem/MobileListItem.js +10 -9
- package/esm/MobilePageHeader/MobilePageHeader.js +17 -16
- package/esm/MobileSelectList/MobileSelectList.js +25 -17
- package/esm/MobileSelectList/styled.js +4 -4
- package/esm/MobileSeparator/Separator.js +28 -16
- package/esm/MobileTimePicker/Input.js +5 -0
- package/esm/MobileTimePicker/MobileTimePicker.js +12 -11
- package/esm/MobileTimePicker/MobileTimePicker.stories.js +1 -1
- package/esm/MobileTouchable/MobileTouchable.js +6 -1
- package/esm/Modal/Modal.js +25 -19
- package/esm/Modal/styled.js +1 -1
- package/esm/PageFilter/PageFilter.js +15 -10
- package/esm/PageForm/PageForm.js +18 -11
- package/esm/PageList/PageList.js +10 -9
- package/esm/PageSearch/PageSearch.js +10 -9
- package/esm/PageSummary/PageSummary.js +32 -19
- package/esm/PageSummary/Tags.js +12 -6
- package/esm/SideNav/SideNav.js +38 -29
- package/esm/SwipeToRefresh/ProgressIndicator.js +5 -4
- package/esm/SwipeToRefresh/SwipeToRefresh.js +7 -6
- package/esm/SwipeToRefresh/styled.js +1 -1
- package/esm/SwipeToRefresh/useSwipe.js +5 -4
- package/esm/Tabs/index.js +6 -1
- package/esm/index.js +4 -3
- package/package.json +15 -7
- package/types/Accordion/Accordion.d.ts +1 -1
- package/types/CategoryBox/CategoryBox.d.ts +1 -1
- package/types/CollectionBox/CollectionBox.d.ts +1 -1
- package/types/GroupBox/GroupBox.d.ts +1 -1
- package/types/InfiniteLoader/Infiniteloader.d.ts +1 -1
- package/types/MobileBanner/styles.d.ts +60 -1
- package/types/MobileDatePicker/MobileDatePicker.d.ts +1 -1
- package/types/MobileSelectList/styled.d.ts +4 -4
- package/types/MobileTimePicker/MobileTimePicker.d.ts +1 -1
- package/types/Modal/styled.d.ts +7 -6
- package/types/SideNav/SideNav.d.ts +1 -1
- package/types/SwipeToRefresh/styled.d.ts +4 -3
- package/types/index.d.ts +5 -1
|
@@ -2,11 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
+
require('core-js/modules/esnext.async-iterator.filter.js');
|
|
6
|
+
require('core-js/modules/esnext.iterator.constructor.js');
|
|
7
|
+
require('core-js/modules/esnext.iterator.filter.js');
|
|
8
|
+
require('core-js/modules/esnext.async-iterator.for-each.js');
|
|
9
|
+
require('core-js/modules/esnext.iterator.for-each.js');
|
|
5
10
|
var _defineProperty = require('@babel/runtime/helpers/defineProperty');
|
|
6
11
|
var _objectWithoutProperties = require('@babel/runtime/helpers/objectWithoutProperties');
|
|
7
12
|
var React = require('react');
|
|
8
13
|
var reactDesc = require('react-desc');
|
|
9
|
-
var DSButton = require('@elliemae/ds-
|
|
14
|
+
var DSButton = require('@elliemae/ds-button');
|
|
10
15
|
var jsxRuntime = require('react/jsx-runtime');
|
|
11
16
|
|
|
12
17
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
@@ -5,8 +5,13 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var _defineProperty = require('@babel/runtime/helpers/defineProperty');
|
|
6
6
|
var _jsx = require('@babel/runtime/helpers/jsx');
|
|
7
7
|
require('core-js/modules/web.dom-collections.iterator.js');
|
|
8
|
+
require('core-js/modules/esnext.async-iterator.filter.js');
|
|
9
|
+
require('core-js/modules/esnext.iterator.constructor.js');
|
|
10
|
+
require('core-js/modules/esnext.iterator.filter.js');
|
|
11
|
+
require('core-js/modules/esnext.async-iterator.for-each.js');
|
|
12
|
+
require('core-js/modules/esnext.iterator.for-each.js');
|
|
8
13
|
var React = require('react');
|
|
9
|
-
var
|
|
14
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
10
15
|
var reactDesc = require('react-desc');
|
|
11
16
|
var icons = require('./utils/icons.js');
|
|
12
17
|
var propTypes = require('./propTypes.js');
|
|
@@ -18,7 +23,6 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
18
23
|
|
|
19
24
|
var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_defineProperty);
|
|
20
25
|
var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
|
|
21
|
-
var CloseX__default = /*#__PURE__*/_interopDefaultLegacy(CloseX);
|
|
22
26
|
|
|
23
27
|
var _CloseX;
|
|
24
28
|
|
|
@@ -26,19 +30,20 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
|
|
|
26
30
|
|
|
27
31
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
28
32
|
|
|
29
|
-
const DSMobileBanner =
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
33
|
+
const DSMobileBanner = _ref => {
|
|
34
|
+
let {
|
|
35
|
+
type,
|
|
36
|
+
isOpen,
|
|
37
|
+
closeButtonOnClick,
|
|
38
|
+
label,
|
|
39
|
+
body,
|
|
40
|
+
actionLinkLabel,
|
|
41
|
+
actionLinkHref,
|
|
42
|
+
actionLinkOnClick,
|
|
43
|
+
showCloseButton,
|
|
44
|
+
containerProps,
|
|
45
|
+
focusOnOpen
|
|
46
|
+
} = _ref;
|
|
42
47
|
const innerContainerRef = React.useRef(null);
|
|
43
48
|
const closeRef = React.useRef(null);
|
|
44
49
|
const [current, setCurrent] = React.useState(isOpen);
|
|
@@ -87,7 +92,7 @@ const DSMobileBanner = ({
|
|
|
87
92
|
buttonType: "link",
|
|
88
93
|
onClick: closeButtonOnClick,
|
|
89
94
|
"aria-label": "Close Banner",
|
|
90
|
-
icon: _CloseX || (_CloseX = /*#__PURE__*/_jsx__default["default"](
|
|
95
|
+
icon: _CloseX || (_CloseX = /*#__PURE__*/_jsx__default["default"](dsIcons.CloseX, {
|
|
91
96
|
width: "12px",
|
|
92
97
|
height: "12px"
|
|
93
98
|
})),
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var styled = require('styled-components');
|
|
6
6
|
var dsSystem = require('@elliemae/ds-system');
|
|
7
|
-
var DSButton = require('@elliemae/ds-
|
|
7
|
+
var DSButton = require('@elliemae/ds-button');
|
|
8
8
|
var styleHelpers = require('./utils/styleHelpers.js');
|
|
9
9
|
|
|
10
10
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
@@ -14,84 +14,153 @@ var DSButton__default = /*#__PURE__*/_interopDefaultLegacy(DSButton);
|
|
|
14
14
|
|
|
15
15
|
const StyledInnerContainer = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
16
16
|
componentId: "sc-4jnp92-0"
|
|
17
|
-
})(["display:flex;min-height:68px;width:100%;background-color:", ";border-bottom:4px solid ", ";transform:translateY(", ");", ";"],
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
theme
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
17
|
+
})(["display:flex;min-height:68px;width:100%;background-color:", ";border-bottom:4px solid ", ";transform:translateY(", ");", ";"], _ref => {
|
|
18
|
+
let {
|
|
19
|
+
theme
|
|
20
|
+
} = _ref;
|
|
21
|
+
return theme.colors.neutral['000'];
|
|
22
|
+
}, _ref2 => {
|
|
23
|
+
let {
|
|
24
|
+
type,
|
|
25
|
+
theme
|
|
26
|
+
} = _ref2;
|
|
27
|
+
return styleHelpers.handleBorderColor(type, theme);
|
|
28
|
+
}, _ref3 => {
|
|
29
|
+
let {
|
|
30
|
+
isOpen
|
|
31
|
+
} = _ref3;
|
|
32
|
+
return isOpen ? '0' : '-100%';
|
|
33
|
+
}, _ref4 => {
|
|
34
|
+
let {
|
|
35
|
+
isAnimating,
|
|
36
|
+
isOpen
|
|
37
|
+
} = _ref4;
|
|
38
|
+
return styleHelpers.handleAnimation(isAnimating, isOpen);
|
|
39
|
+
});
|
|
28
40
|
const StyledTextContent = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
29
41
|
componentId: "sc-4jnp92-1"
|
|
30
42
|
})(["width:100%;"]);
|
|
31
43
|
const StyledTitle = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
32
44
|
componentId: "sc-4jnp92-2"
|
|
33
|
-
})(["color:", ";font-size:", ";font-weight:", ";margin-bottom:", ";@media not all and (min-resolution:0.001dpcm){@media{-webkit-font-smoothing:subpixel-antialiased;-webkit-text-stroke:0.4px ", ";}}@media screen and (min--moz-device-pixel-ratio:0){-webkit-font-smoothing:subpixel-antialiased;-webkit-text-stroke:0.4px ", ";}"],
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
}
|
|
42
|
-
theme
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
|
|
45
|
+
})(["color:", ";font-size:", ";font-weight:", ";margin-bottom:", ";@media not all and (min-resolution:0.001dpcm){@media{-webkit-font-smoothing:subpixel-antialiased;-webkit-text-stroke:0.4px ", ";}}@media screen and (min--moz-device-pixel-ratio:0){-webkit-font-smoothing:subpixel-antialiased;-webkit-text-stroke:0.4px ", ";}"], _ref5 => {
|
|
46
|
+
let {
|
|
47
|
+
theme
|
|
48
|
+
} = _ref5;
|
|
49
|
+
return theme.colors.neutral[700];
|
|
50
|
+
}, _ref6 => {
|
|
51
|
+
let {
|
|
52
|
+
theme
|
|
53
|
+
} = _ref6;
|
|
54
|
+
return dsSystem.toMobile(theme.fontSizes.title[700]);
|
|
55
|
+
}, _ref7 => {
|
|
56
|
+
let {
|
|
57
|
+
theme
|
|
58
|
+
} = _ref7;
|
|
59
|
+
return theme.fontWeights.semibold;
|
|
60
|
+
}, _ref8 => {
|
|
61
|
+
let {
|
|
62
|
+
theme
|
|
63
|
+
} = _ref8;
|
|
64
|
+
return theme.space.xxs;
|
|
65
|
+
}, _ref9 => {
|
|
66
|
+
let {
|
|
67
|
+
theme
|
|
68
|
+
} = _ref9;
|
|
69
|
+
return theme.colors.neutral[700];
|
|
70
|
+
}, _ref10 => {
|
|
71
|
+
let {
|
|
72
|
+
theme
|
|
73
|
+
} = _ref10;
|
|
74
|
+
return theme.colors.neutral[700];
|
|
75
|
+
});
|
|
46
76
|
const StyledSubTitle = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
47
77
|
componentId: "sc-4jnp92-3"
|
|
48
|
-
})(["font-size:", ";font-weight:", ";"],
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
78
|
+
})(["font-size:", ";font-weight:", ";"], _ref11 => {
|
|
79
|
+
let {
|
|
80
|
+
theme
|
|
81
|
+
} = _ref11;
|
|
82
|
+
return dsSystem.toMobile(theme.fontSizes.title[600]);
|
|
83
|
+
}, _ref12 => {
|
|
84
|
+
let {
|
|
85
|
+
theme
|
|
86
|
+
} = _ref12;
|
|
87
|
+
return theme.fontWeights.regular;
|
|
88
|
+
});
|
|
53
89
|
const StyledIconContainer = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
54
90
|
componentId: "sc-4jnp92-4"
|
|
55
|
-
})(["margin-top:10px;margin-right:", ";margin-left:", ";"],
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
91
|
+
})(["margin-top:10px;margin-right:", ";margin-left:", ";"], _ref13 => {
|
|
92
|
+
let {
|
|
93
|
+
theme
|
|
94
|
+
} = _ref13;
|
|
95
|
+
return theme.space.xxs;
|
|
96
|
+
}, _ref14 => {
|
|
97
|
+
let {
|
|
98
|
+
theme
|
|
99
|
+
} = _ref14;
|
|
100
|
+
return theme.space.xs;
|
|
101
|
+
});
|
|
60
102
|
const StyledContent = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
61
103
|
componentId: "sc-4jnp92-5"
|
|
62
|
-
})(["width:100%;display:flex;flex-direction:column;margin:", " 0;margin-right:", ";"],
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
104
|
+
})(["width:100%;display:flex;flex-direction:column;margin:", " 0;margin-right:", ";"], _ref15 => {
|
|
105
|
+
let {
|
|
106
|
+
theme
|
|
107
|
+
} = _ref15;
|
|
108
|
+
return theme.space.xxs2;
|
|
109
|
+
}, _ref16 => {
|
|
110
|
+
let {
|
|
111
|
+
showCloseButton
|
|
112
|
+
} = _ref16;
|
|
113
|
+
return !showCloseButton ? '28px' : '0';
|
|
114
|
+
});
|
|
67
115
|
const StyledCloseButtonContainer = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
68
116
|
componentId: "sc-4jnp92-6"
|
|
69
117
|
})(["display:flex;align-items:flex-start;margin-top:6px;margin-right:6px;"]);
|
|
70
118
|
const StyledCloseButton = /*#__PURE__*/styled__default["default"](DSButton__default["default"]).withConfig({
|
|
71
119
|
componentId: "sc-4jnp92-7"
|
|
72
|
-
})(["position:relative;&:focus{&:after{display:block;content:' ';position:absolute;top:0;left:0;width:100%;height:100%;border:2px solid ", ";border-radius:2px;pointer-events:none;}}"],
|
|
73
|
-
|
|
74
|
-
|
|
120
|
+
})(["position:relative;&:focus{&:after{display:block;content:' ';position:absolute;top:0;left:0;width:100%;height:100%;border:2px solid ", ";border-radius:2px;pointer-events:none;}}"], _ref17 => {
|
|
121
|
+
let {
|
|
122
|
+
theme
|
|
123
|
+
} = _ref17;
|
|
124
|
+
return theme.colors.brand[700];
|
|
125
|
+
});
|
|
75
126
|
const StyledActionLink = /*#__PURE__*/styled__default["default"].a.withConfig({
|
|
76
127
|
componentId: "sc-4jnp92-8"
|
|
77
|
-
})(["text-decoration:none;float:right;margin-left:", ";line-height:1.1;font-size:", ";font-weight:", ";color:", ";"],
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
}
|
|
128
|
+
})(["text-decoration:none;float:right;margin-left:", ";line-height:1.1;font-size:", ";font-weight:", ";color:", ";"], _ref18 => {
|
|
129
|
+
let {
|
|
130
|
+
theme
|
|
131
|
+
} = _ref18;
|
|
132
|
+
return theme.space.xs;
|
|
133
|
+
}, _ref19 => {
|
|
134
|
+
let {
|
|
135
|
+
theme
|
|
136
|
+
} = _ref19;
|
|
137
|
+
return dsSystem.toMobile(theme.fontSizes.title[600]);
|
|
138
|
+
}, _ref20 => {
|
|
139
|
+
let {
|
|
140
|
+
theme
|
|
141
|
+
} = _ref20;
|
|
142
|
+
return theme.fontWeights.regular;
|
|
143
|
+
}, _ref21 => {
|
|
144
|
+
let {
|
|
145
|
+
theme
|
|
146
|
+
} = _ref21;
|
|
147
|
+
return theme.colors.brand[600];
|
|
148
|
+
});
|
|
86
149
|
const StyledBannerContainer = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
87
150
|
componentId: "sc-4jnp92-9"
|
|
88
|
-
})(["overflow:hidden;height:", ";", ";"],
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
isOpen
|
|
93
|
-
|
|
94
|
-
|
|
151
|
+
})(["overflow:hidden;height:", ";", ";"], _ref22 => {
|
|
152
|
+
let {
|
|
153
|
+
isOpen
|
|
154
|
+
} = _ref22;
|
|
155
|
+
return isOpen ? 'auto' : '0px';
|
|
156
|
+
}, _ref23 => {
|
|
157
|
+
let {
|
|
158
|
+
isAnimating,
|
|
159
|
+
isOpen,
|
|
160
|
+
height
|
|
161
|
+
} = _ref23;
|
|
162
|
+
return styleHelpers.handleAnimation(isAnimating, isOpen, height);
|
|
163
|
+
});
|
|
95
164
|
|
|
96
165
|
exports.StyledActionLink = StyledActionLink;
|
|
97
166
|
exports.StyledBannerContainer = StyledBannerContainer;
|
|
@@ -4,32 +4,25 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var _jsx = require('@babel/runtime/helpers/jsx');
|
|
6
6
|
require('react');
|
|
7
|
-
var
|
|
8
|
-
var InfoFill = require('@elliemae/ds-icons/InfoFill');
|
|
9
|
-
var AlertsDetailFill = require('@elliemae/ds-icons/AlertsDetailFill');
|
|
10
|
-
var WarningSquare = require('@elliemae/ds-icons/WarningSquare');
|
|
7
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
11
8
|
|
|
12
9
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
13
10
|
|
|
14
11
|
var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
|
|
15
|
-
var SuccessFill__default = /*#__PURE__*/_interopDefaultLegacy(SuccessFill);
|
|
16
|
-
var InfoFill__default = /*#__PURE__*/_interopDefaultLegacy(InfoFill);
|
|
17
|
-
var AlertsDetailFill__default = /*#__PURE__*/_interopDefaultLegacy(AlertsDetailFill);
|
|
18
|
-
var WarningSquare__default = /*#__PURE__*/_interopDefaultLegacy(WarningSquare);
|
|
19
12
|
|
|
20
13
|
const icons = {
|
|
21
|
-
success: /*#__PURE__*/_jsx__default["default"](
|
|
14
|
+
success: /*#__PURE__*/_jsx__default["default"](dsIcons.SuccessFill, {
|
|
22
15
|
fill: "#207e56"
|
|
23
16
|
}),
|
|
24
|
-
info: /*#__PURE__*/_jsx__default["default"](
|
|
17
|
+
info: /*#__PURE__*/_jsx__default["default"](dsIcons.InfoFill, {
|
|
25
18
|
fill: "#1e79c2"
|
|
26
19
|
}),
|
|
27
|
-
error: /*#__PURE__*/_jsx__default["default"](
|
|
20
|
+
error: /*#__PURE__*/_jsx__default["default"](dsIcons.AlertsDetailFill, {
|
|
28
21
|
width: "24px",
|
|
29
22
|
height: "24px",
|
|
30
23
|
fill: "#c64252"
|
|
31
24
|
}),
|
|
32
|
-
warning: /*#__PURE__*/_jsx__default["default"](
|
|
25
|
+
warning: /*#__PURE__*/_jsx__default["default"](dsIcons.WarningSquare, {
|
|
33
26
|
width: "24px",
|
|
34
27
|
height: "24px",
|
|
35
28
|
fill: "#d17a00"
|
|
@@ -15,9 +15,11 @@ const slideIn = dsSystem.kfrm(_templateObject || (_templateObject = _taggedTempl
|
|
|
15
15
|
const slideOut = dsSystem.kfrm(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral__default["default"](["\n 0% {\n transform: translate3d(0, 0, 0);\n opacity: 1;\n }\n 60% {\n opacity: 0;\n }\n 100% {\n opacity: 0;\n transform: translate3d(0, -100%, 0);\n }\n"])));
|
|
16
16
|
const spanContainer = height => dsSystem.kfrm(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral__default["default"](["\n 0% {\n height: 0px;\n }\n 100% {\n height: ", "px;\n }\n"])), height);
|
|
17
17
|
const shrinkContainer = height => dsSystem.kfrm(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral__default["default"](["\n 0% {\n height: ", "px;\n }\n 100% {\n height: 0px;\n }\n"])), height);
|
|
18
|
-
const handleBorderColor = (type, {
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
const handleBorderColor = (type, _ref) => {
|
|
19
|
+
let {
|
|
20
|
+
colors
|
|
21
|
+
} = _ref;
|
|
22
|
+
|
|
21
23
|
switch (type) {
|
|
22
24
|
case bannerTypes.MOBILE_BANNER_TYPES.SUCCESS:
|
|
23
25
|
return colors.success[900];
|
|
@@ -32,7 +34,9 @@ const handleBorderColor = (type, {
|
|
|
32
34
|
return colors.danger[900];
|
|
33
35
|
}
|
|
34
36
|
};
|
|
35
|
-
const handleAnimation = (isAnimating, isOpen
|
|
37
|
+
const handleAnimation = function (isAnimating, isOpen) {
|
|
38
|
+
let height = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
39
|
+
|
|
36
40
|
if (isAnimating) {
|
|
37
41
|
if (isOpen) {
|
|
38
42
|
return dsSystem.css(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral__default["default"](["\n animation: ", " 0.5s ease-in;\n "])), height ? spanContainer(height) : slideIn);
|
|
@@ -5,29 +5,31 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var _jsx = require('@babel/runtime/helpers/jsx');
|
|
6
6
|
require('react');
|
|
7
7
|
var styled = require('styled-components');
|
|
8
|
-
var
|
|
9
|
-
var DSButton = require('@elliemae/ds-
|
|
8
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
9
|
+
var DSButton = require('@elliemae/ds-button');
|
|
10
10
|
|
|
11
11
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
12
12
|
|
|
13
13
|
var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
|
|
14
14
|
var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
|
|
15
|
-
var ChevronSmallDown__default = /*#__PURE__*/_interopDefaultLegacy(ChevronSmallDown);
|
|
16
15
|
var DSButton__default = /*#__PURE__*/_interopDefaultLegacy(DSButton);
|
|
17
16
|
|
|
18
17
|
const Addon = /*#__PURE__*/styled__default["default"](DSButton__default["default"]).withConfig({
|
|
19
18
|
componentId: "sc-afblfw-0"
|
|
20
19
|
})(["background-color:transparent;padding-right:4px;height:100%;border:none;font-size:12px;font-weight:", ";color:", ";cursor:pointer;&:focus,&::after{background-color:transparent;box-shadow:none !important;border:none !important;}"], props => props.theme.fontWeights.semibold, props => props.theme.colors.brand['700']);
|
|
21
|
-
const ActionAddon =
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
20
|
+
const ActionAddon = _ref => {
|
|
21
|
+
let {
|
|
22
|
+
label,
|
|
23
|
+
onClick,
|
|
24
|
+
icon
|
|
25
|
+
} = _ref;
|
|
26
|
+
return /*#__PURE__*/_jsx__default["default"](Addon, {
|
|
27
|
+
onClick: onClick,
|
|
28
|
+
labelText: label,
|
|
29
|
+
icon: icon || /*#__PURE__*/_jsx__default["default"](dsIcons.ChevronSmallDown, {
|
|
30
|
+
color: ['brand-primary', 700]
|
|
31
|
+
})
|
|
32
|
+
});
|
|
33
|
+
};
|
|
32
34
|
|
|
33
35
|
exports.ActionAddon = ActionAddon;
|
package/cjs/MobileCard/Card.js
CHANGED
|
@@ -3,13 +3,15 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var _jsx = require('@babel/runtime/helpers/jsx');
|
|
6
|
+
require('core-js/modules/esnext.async-iterator.map.js');
|
|
7
|
+
require('core-js/modules/esnext.iterator.map.js');
|
|
6
8
|
var React = require('react');
|
|
7
9
|
var reactDesc = require('react-desc');
|
|
8
10
|
var styled = require('styled-components');
|
|
9
11
|
var styledSystem = require('styled-system');
|
|
10
12
|
var dsSystem = require('@elliemae/ds-system');
|
|
11
13
|
var GroupItem = require('@elliemae/ds-shared/GroupContext/GroupItem');
|
|
12
|
-
var
|
|
14
|
+
var dsGrid = require('@elliemae/ds-grid');
|
|
13
15
|
var StyledCard = require('./StyledCard.js');
|
|
14
16
|
var ExpandChevron = require('./ExpandChevron.js');
|
|
15
17
|
var useHeight = require('./useHeight.js');
|
|
@@ -37,35 +39,37 @@ const SubText = /*#__PURE__*/styled__default["default"].span.withConfig({
|
|
|
37
39
|
const SubTextWrap = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
38
40
|
componentId: "sc-10tpzm8-4"
|
|
39
41
|
})(["", " border-top:", ";margin-top:6px;margin-bottom:2px;padding-bottom:", ";font-size:", ";", " font-weight:", ";display:flex;justify-content:space-between;"], dsSystem.truncate(), props => dsSystem.border(props.theme.colors.neutral['300']), props => dsSystem.__UNSAFE_SPACE_TO_DIMSUM(props.theme.space.xxs), props => dsSystem.toMobile(props.theme.fontSizes.subTitle[400]), dsSystem.color('neutral', '500'), props => props.theme.fontWeights.regular);
|
|
40
|
-
const LeftIcon = /*#__PURE__*/styled__default["default"](
|
|
42
|
+
const LeftIcon = /*#__PURE__*/styled__default["default"](dsGrid.Grid).withConfig({
|
|
41
43
|
componentId: "sc-10tpzm8-5"
|
|
42
44
|
})(["& > span{height:", ";width:", ";}& > span > svg,svg:not([fill]){height:", ";width:", ";}"], props => props.halfM, props => props.halfM, props => props.halfM, props => props.halfM);
|
|
43
45
|
const CenterWrap = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
44
46
|
componentId: "sc-10tpzm8-6"
|
|
45
47
|
})(["display:flex;align-items:center;", ""], dsSystem.truncate());
|
|
46
48
|
|
|
47
|
-
const MobileCard =
|
|
48
|
-
children,
|
|
49
|
-
height = 'm',
|
|
50
|
-
leftAddOn,
|
|
51
|
-
leftProp,
|
|
52
|
-
rightProp,
|
|
53
|
-
subText,
|
|
54
|
-
subIcons,
|
|
55
|
-
details,
|
|
56
|
-
theme,
|
|
57
|
-
expandable = false,
|
|
58
|
-
expandedContent,
|
|
59
|
-
value
|
|
60
|
-
}) => {
|
|
49
|
+
const MobileCard = _ref => {
|
|
61
50
|
var _TitleEllipsis, _SubText;
|
|
62
51
|
|
|
52
|
+
let {
|
|
53
|
+
children,
|
|
54
|
+
height = 'm',
|
|
55
|
+
leftAddOn,
|
|
56
|
+
leftProp,
|
|
57
|
+
rightProp,
|
|
58
|
+
subText,
|
|
59
|
+
subIcons,
|
|
60
|
+
details,
|
|
61
|
+
theme,
|
|
62
|
+
expandable = false,
|
|
63
|
+
expandedContent,
|
|
64
|
+
value
|
|
65
|
+
} = _ref;
|
|
63
66
|
const subTextRef = React.useRef(null);
|
|
64
67
|
const subTextHeight = useHeight.useHeight(subTextRef);
|
|
65
68
|
const isJustChildren = !(subText || subIcons || details);
|
|
66
69
|
const halfM = dsSystem.op('/', dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.m), 2);
|
|
67
70
|
return /*#__PURE__*/_jsx__default["default"](GroupItem__default["default"], {
|
|
68
|
-
render: (
|
|
71
|
+
render: function () {
|
|
72
|
+
let context = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
69
73
|
const {
|
|
70
74
|
activeValue,
|
|
71
75
|
onChange
|
|
@@ -85,30 +89,30 @@ const MobileCard = ({
|
|
|
85
89
|
});
|
|
86
90
|
},
|
|
87
91
|
align: subText || subIcons ? 'top' : 'center'
|
|
88
|
-
}), /*#__PURE__*/_jsx__default["default"](
|
|
92
|
+
}), /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
89
93
|
pb: (subText || subIcons) && subTextHeight,
|
|
90
94
|
cols: ['auto', 'auto'],
|
|
91
95
|
alignItems: "center"
|
|
92
|
-
}, void 0, leftProp && /*#__PURE__*/_jsx__default["default"](
|
|
96
|
+
}, void 0, leftProp && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
93
97
|
ml: dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.s)
|
|
94
98
|
}, void 0, leftProp), leftAddOn && /*#__PURE__*/_jsx__default["default"](LeftIcon, {
|
|
95
99
|
ml: dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.s),
|
|
96
100
|
halfM: halfM
|
|
97
|
-
}, void 0, leftAddOn)), /*#__PURE__*/_jsx__default["default"](
|
|
101
|
+
}, void 0, leftAddOn)), /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
98
102
|
pl: !leftAddOn ? dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.s) : dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.xs),
|
|
99
103
|
pr: dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.s),
|
|
100
104
|
width: "100%"
|
|
101
105
|
}, void 0, /*#__PURE__*/_jsx__default["default"](CenterWrap, {}, void 0, /*#__PURE__*/_jsx__default["default"](Title, {
|
|
102
106
|
pt: !isJustChildren && halfM,
|
|
103
107
|
"data-testid": "card-title"
|
|
104
|
-
}, void 0, _TitleEllipsis || (_TitleEllipsis = /*#__PURE__*/_jsx__default["default"](TitleEllipsis, {}, void 0, children)), details && /*#__PURE__*/_jsx__default["default"](
|
|
108
|
+
}, void 0, _TitleEllipsis || (_TitleEllipsis = /*#__PURE__*/_jsx__default["default"](TitleEllipsis, {}, void 0, children)), details && /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
105
109
|
"data-testid": "card-details",
|
|
106
110
|
cols: details.map(() => 'min-content'),
|
|
107
111
|
mb: !(subText || subIcons) && halfM,
|
|
108
112
|
pt: dsSystem.op('/', dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.xxs), 2)
|
|
109
113
|
}, void 0, details.map((d, i) => /*#__PURE__*/_jsx__default["default"](Detail, {}, i, d, i < details.length - 1 && /*#__PURE__*/_jsx__default["default"](Detail, {
|
|
110
114
|
px: dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.xxs)
|
|
111
|
-
}, void 0, "\u2022"))))), rightProp && rightProp.map((prop, i) => /*#__PURE__*/_jsx__default["default"](
|
|
115
|
+
}, void 0, "\u2022"))))), rightProp && rightProp.map((prop, i) => /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {
|
|
112
116
|
ml: dsSystem.__UNSAFE_SPACE_TO_DIMSUM(theme.space.s)
|
|
113
117
|
}, i, prop))), subIcons && /*#__PURE__*/jsxRuntime.jsxs(SubTextWrap, {
|
|
114
118
|
ref: subTextRef,
|
|
@@ -3,31 +3,36 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var _jsx = require('@babel/runtime/helpers/jsx');
|
|
6
|
+
require('core-js/modules/esnext.async-iterator.map.js');
|
|
7
|
+
require('core-js/modules/esnext.iterator.map.js');
|
|
6
8
|
require('react');
|
|
7
9
|
var styled = require('styled-components');
|
|
8
|
-
var
|
|
10
|
+
var dsGrid = require('@elliemae/ds-grid');
|
|
9
11
|
|
|
10
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
11
13
|
|
|
12
14
|
var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
|
|
13
15
|
var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
|
|
14
16
|
|
|
15
|
-
const CardIconsWrapper = /*#__PURE__*/styled__default["default"](
|
|
17
|
+
const CardIconsWrapper = /*#__PURE__*/styled__default["default"](dsGrid.Grid).withConfig({
|
|
16
18
|
componentId: "sc-1vqygz1-0"
|
|
17
19
|
})(["align-items:center;span,svg{width:12px !important;height:12px !important;}span.icon-color-muted svg,svg:not([fill]){fill:", ";height:12px !important;width:12px !important;& *{fill:", ";}}span.icon-color-warn svg,svg:not([fill]){fill:", ";height:12px !important;width:12px !important;& *{fill:", ";}}span.icon-color-error svg,svg:not([fill]){fill:", ";height:12px !important;width:12px !important;& *{fill:", ";}}span.icon-color-success svg,svg:not([fill]){fill:", ";height:12px !important;width:12px !important;& *{fill:", ";}}span.icon-color-primary svg,svg:not([fill]){fill:", ";}span.icon-color-primary svg,svg:not([fill]){fill:", ";}"], props => props.theme.colors.neutral['600'], props => props.theme.colors.neutral['600'], props => props.theme.colors.warning['600'], props => props.theme.colors.warning['600'], props => props.theme.colors.danger['900'], props => props.theme.colors.danger['900'], props => props.theme.colors.success['900'], props => props.theme.colors.success['900'], props => props.theme.colors.brand[600], props => props.theme.colors.brand[600]);
|
|
18
|
-
const SubIcons =
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
20
|
+
const SubIcons = _ref => {
|
|
21
|
+
let {
|
|
22
|
+
icons = [],
|
|
23
|
+
colors = []
|
|
24
|
+
} = _ref;
|
|
25
|
+
return /*#__PURE__*/_jsx__default["default"](CardIconsWrapper, {
|
|
26
|
+
cols: icons.map(() => '12px'),
|
|
27
|
+
gutter: "6px",
|
|
28
|
+
height: "14px",
|
|
29
|
+
"data-testid": "card-subIcons"
|
|
30
|
+
}, void 0, icons.map((Icon, i) =>
|
|
31
|
+
/*#__PURE__*/
|
|
32
|
+
// eslint-disable-next-line react/no-array-index-key
|
|
33
|
+
_jsx__default["default"](Icon, {
|
|
34
|
+
className: "icon-color-".concat(colors[i] || 'muted')
|
|
35
|
+
}, i)));
|
|
36
|
+
};
|
|
32
37
|
|
|
33
38
|
exports.SubIcons = SubIcons;
|
|
@@ -5,25 +5,23 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var _jsx = require('@babel/runtime/helpers/jsx');
|
|
6
6
|
require('react');
|
|
7
7
|
var styled = require('styled-components');
|
|
8
|
-
var
|
|
9
|
-
var ChevronRight = require('@elliemae/ds-icons/ChevronRight');
|
|
8
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
10
9
|
|
|
11
10
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
12
11
|
|
|
13
12
|
var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
|
|
14
13
|
var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
|
|
15
|
-
var ChevronDownIcon__default = /*#__PURE__*/_interopDefaultLegacy(ChevronDownIcon);
|
|
16
|
-
var ChevronRight__default = /*#__PURE__*/_interopDefaultLegacy(ChevronRight);
|
|
17
14
|
|
|
18
15
|
const ChevronWrap = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
19
16
|
componentId: "sc-1l0ask2-0"
|
|
20
17
|
})(["margin-top:", ";align-self:", ";margin-left:", ";"], props => props.align === 'top' ? '18px' : '0', props => props.align === 'top' ? 'flex-start' : 'center', props => props.theme.space.xs);
|
|
21
|
-
const ExpandChevron =
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
18
|
+
const ExpandChevron = _ref => {
|
|
19
|
+
let {
|
|
20
|
+
isExpanded,
|
|
21
|
+
onClick,
|
|
22
|
+
align
|
|
23
|
+
} = _ref;
|
|
24
|
+
const Chevron = isExpanded ? dsIcons.ChevronDown : dsIcons.ChevronRight;
|
|
27
25
|
return /*#__PURE__*/_jsx__default["default"](ChevronWrap, {
|
|
28
26
|
"data-testid": "ds-card-expand-chevron",
|
|
29
27
|
align: align
|
|
@@ -20,12 +20,13 @@ const RegionWrapper = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
|
20
20
|
const Region = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
21
21
|
componentId: "sc-mduzz9-1"
|
|
22
22
|
})(["display:flex;", " transition:max-height ", " linear;max-height:0;", " align-items:center;", ";border-top:", ";font-weight:", ";"], props => props.hide ? 'visibility: hidden;' : '', props => props.animate ? '0.25s' : '0.20s', props => props.animate ? "\n max-height: ".concat(props.refHeight, "px;\n ") : '', dsSystem.truncate(), props => dsSystem.border(props.theme.colors.neutral['300']), props => props.theme.fontWeights.regular);
|
|
23
|
-
const ExpandableRegion =
|
|
24
|
-
show,
|
|
25
|
-
content
|
|
26
|
-
}) => {
|
|
23
|
+
const ExpandableRegion = _ref => {
|
|
27
24
|
var _ref$current;
|
|
28
25
|
|
|
26
|
+
let {
|
|
27
|
+
show,
|
|
28
|
+
content
|
|
29
|
+
} = _ref;
|
|
29
30
|
const ref = React.useRef(null); // triggers transition
|
|
30
31
|
|
|
31
32
|
const [animate, setAnimate] = React.useState(show); // needed to properly handle the transition. Hide after transition ends
|