@hexure/ui 1.7.0 → 1.8.1

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/cjs/index.js CHANGED
@@ -22,16 +22,6 @@ PERFORMANCE OF THIS SOFTWARE.
22
22
  ***************************************************************************** */
23
23
  /* global Reflect, Promise */
24
24
 
25
- var __assign = function () {
26
- __assign = Object.assign || function __assign(t) {
27
- for (var s, i = 1, n = arguments.length; i < n; i++) {
28
- s = arguments[i];
29
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
30
- }
31
- return t;
32
- };
33
- return __assign.apply(this, arguments);
34
- };
35
25
  function __rest(s, e) {
36
26
  var t = {};
37
27
  for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
@@ -40,25 +30,6 @@ function __rest(s, e) {
40
30
  }
41
31
  return t;
42
32
  }
43
- function __spreadArray(to, from, pack) {
44
- if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
45
- if (ar || !(i in from)) {
46
- if (!ar) ar = Array.prototype.slice.call(from, 0, i);
47
- ar[i] = from[i];
48
- }
49
- }
50
- return to.concat(ar || Array.prototype.slice.call(from));
51
- }
52
- function __makeTemplateObject(cooked, raw) {
53
- if (Object.defineProperty) {
54
- Object.defineProperty(cooked, "raw", {
55
- value: raw
56
- });
57
- } else {
58
- cooked.raw = raw;
59
- }
60
- return cooked;
61
- }
62
33
 
63
34
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
64
35
 
@@ -1993,7 +1964,7 @@ var qe = function (e) {
1993
1964
  "production" !== process.env.NODE_ENV && "undefined" != typeof navigator && "ReactNative" === navigator.product && console.warn("It looks like you've imported 'styled-components' on React Native.\nPerhaps you're looking to import 'styled-components/native'?\nRead more about this at https://www.styled-components.com/docs/basics#react-native"), "production" !== process.env.NODE_ENV && "test" !== process.env.NODE_ENV && "undefined" != typeof window && (window["__styled-components-init__"] = window["__styled-components-init__"] || 0, 1 === window["__styled-components-init__"] && console.warn("It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.\n\nSee https://s-c.sh/2BAXzed for more info."), window["__styled-components-init__"] += 1);
1994
1965
  var styled = qe;
1995
1966
 
1996
- var Colors = {
1967
+ const Colors = {
1997
1968
  PRIMARY: {
1998
1969
  Hex: '#0193D7',
1999
1970
  Rgb: '1, 147, 215',
@@ -2031,28 +2002,44 @@ var Colors = {
2031
2002
  Rgb: '245, 245, 245',
2032
2003
  },
2033
2004
  };
2034
- var FontStyles = {
2005
+ const FontStyles = {
2035
2006
  DEFAULT: '"Roboto", Helvetica, Arial, sans-serif',
2036
2007
  HEADING: '"Roboto Slab", "Roboto", Helvetica, Arial, sans-serif',
2037
2008
  };
2038
- var FontSizes = {
2009
+ const FontSizes = {
2039
2010
  DEFAULT: '14px',
2040
2011
  SMALL: '13px',
2041
2012
  };
2042
2013
 
2043
- var Header$3 = styled.div(templateObject_1$q || (templateObject_1$q = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: space-between;\n box-sizing: border-box;\n background: #f5f5f5;\n border: 1px solid #e5e5e5;\n padding: 14px 20px;\n height: 50px;\n cursor: pointer;\n"], ["\n display: flex;\n align-items: center;\n justify-content: space-between;\n box-sizing: border-box;\n background: #f5f5f5;\n border: 1px solid #e5e5e5;\n padding: 14px 20px;\n height: 50px;\n cursor: pointer;\n"])));
2044
- var Title$1 = styled.div(templateObject_2$n || (templateObject_2$n = __makeTemplateObject(["\n font-size: ", ";\n font-weight: 400;\n color: ", ";\n line-height: 1.6em;\n font-family: ", ";\n box-sizing: border-box;\n"], ["\n font-size: ", ";\n font-weight: 400;\n color: ", ";\n line-height: 1.6em;\n font-family: ", ";\n box-sizing: border-box;\n"])), FontSizes.DEFAULT, Colors.BLACK.Hex, FontStyles.DEFAULT);
2045
- var Accordion = function (_a) {
2046
- var title = _a.title, children = _a.children, open = _a.open, onClick = _a.onClick, accessibleProps = __rest(_a, ["title", "children", "open", "onClick"]);
2014
+ const Header$3 = styled.div `
2015
+ display: flex;
2016
+ align-items: center;
2017
+ justify-content: space-between;
2018
+ box-sizing: border-box;
2019
+ background: #f5f5f5;
2020
+ border: 1px solid #e5e5e5;
2021
+ padding: 14px 20px;
2022
+ height: 50px;
2023
+ cursor: pointer;
2024
+ `;
2025
+ const Title$1 = styled.div `
2026
+ font-size: ${FontSizes.DEFAULT};
2027
+ font-weight: 400;
2028
+ color: ${Colors.BLACK.Hex};
2029
+ line-height: 1.6em;
2030
+ font-family: ${FontStyles.DEFAULT};
2031
+ box-sizing: border-box;
2032
+ `;
2033
+ const Accordion = (_a) => {
2034
+ var { title, children, open, onClick } = _a, accessibleProps = __rest(_a, ["title", "children", "open", "onClick"]);
2047
2035
  return (React.createElement(React.Fragment, null,
2048
- React.createElement(Header$3, __assign({ onClick: onClick }, accessibleProps),
2036
+ React.createElement(Header$3, Object.assign({ onClick: onClick }, accessibleProps),
2049
2037
  React.createElement(Title$1, null, title),
2050
2038
  React.createElement(Icon, { color: Colors.BLACK.Hex, path: open ? js.mdiChevronUp : js.mdiChevronDown, size: '24px' })),
2051
2039
  open ? children : null));
2052
- };
2053
- var templateObject_1$q, templateObject_2$n;
2040
+ };
2054
2041
 
2055
- var button_type_mapping = {
2042
+ const button_type_mapping = {
2056
2043
  primary: {
2057
2044
  background_color: Colors.PRIMARY.Hex,
2058
2045
  border_color: Colors.PRIMARY.Hex,
@@ -2075,7 +2062,12 @@ var button_type_mapping = {
2075
2062
  badge_content_color: Colors.RED.Hex,
2076
2063
  },
2077
2064
  };
2078
- var StyledButton = styled.button(templateObject_1$p || (templateObject_1$p = __makeTemplateObject(["\n height: ", ";\n line-height: 1em;\n border-radius: ", ";\n margin: ", ";\n padding: ", ";\n outline: none;\n background: ", ";\n width: ", ";\n cursor: ", ";\n display: flex;\n align-items: center;\n justify-content: center;\n opacity: ", ";\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n box-sizing: border-box;\n &:hover {\n opacity: ", ";\n }\n"], ["\n height: ", ";\n line-height: 1em;\n border-radius: ", ";\n margin: ", ";\n padding: ", ";\n outline: none;\n background: ", ";\n width: ", ";\n cursor: ", ";\n display: flex;\n align-items: center;\n justify-content: center;\n opacity: ", ";\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n box-sizing: border-box;\n &:hover {\n opacity: ", ";\n }\n"])), function (props) { return (props.$small ? '30px' : '40px'); }, function (props) { return (props.$small ? '15px' : '20px'); }, function (props) { return props.$margin || '0px'; }, function (props) {
2065
+ const StyledButton = styled.button `
2066
+ height: ${props => (props.$small ? '30px' : '40px')};
2067
+ line-height: 1em;
2068
+ border-radius: ${props => (props.$small ? '15px' : '20px')};
2069
+ margin: ${props => props.$margin || '0px'};
2070
+ padding: ${props => {
2079
2071
  if (props.$hasChildren) {
2080
2072
  if (props.$small) {
2081
2073
  return '0 10px';
@@ -2085,9 +2077,10 @@ var StyledButton = styled.button(templateObject_1$p || (templateObject_1$p = __m
2085
2077
  }
2086
2078
  }
2087
2079
  return '0px';
2088
- }, function (props) {
2089
- return props.$format ? button_type_mapping[props.$format].background_color : Colors.PRIMARY.Hex;
2090
- }, function (props) {
2080
+ }};
2081
+ outline: none;
2082
+ background: ${props => props.$format ? button_type_mapping[props.$format].background_color : Colors.PRIMARY.Hex};
2083
+ width: ${props => {
2091
2084
  if (props.$hasChildren) {
2092
2085
  return 'auto';
2093
2086
  }
@@ -2095,84 +2088,201 @@ var StyledButton = styled.button(templateObject_1$p || (templateObject_1$p = __m
2095
2088
  return '30px';
2096
2089
  }
2097
2090
  return '40px';
2098
- }, function (props) { return (props.$disabled ? 'default' : 'pointer'); }, function (props) { return (props.$disabled ? 0.6 : 0.9); }, function (props) {
2099
- return props.$format ? button_type_mapping[props.$format].border_color : Colors.PRIMARY.Hex;
2100
- }, function (props) { return (props.$disabled ? 0.6 : 1); });
2101
- var Label$4 = styled.span(templateObject_2$m || (templateObject_2$m = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n font-family: ", ";\n font-weight: 500;\n line-height: 1;\n"], ["\n color: ", ";\n font-size: ", ";\n font-family: ", ";\n font-weight: 500;\n line-height: 1;\n"])), function (props) { return (props.$format ? button_type_mapping[props.$format].content_color : '#fff'); }, function (props) { return (props.$small ? FontSizes.SMALL : FontSizes.DEFAULT); }, FontStyles.DEFAULT);
2102
- var StyledIcon$3 = styled.span(templateObject_3$i || (templateObject_3$i = __makeTemplateObject(["\n margin-left: ", ";\n margin-right: ", ";\n display: flex;\n align-items: center;\n box-sizing: border-box;\n"], ["\n margin-left: ", ";\n margin-right: ", ";\n display: flex;\n align-items: center;\n box-sizing: border-box;\n"])), function (props) { return (props.$hasChildren ? '6px' : '0px'); }, function (props) { return (props.$hasChildren ? '-4px' : '0px'); });
2103
- var Badge$1 = styled.span(templateObject_4$9 || (templateObject_4$9 = __makeTemplateObject(["\n width: ", ";\n height: ", ";\n line-height: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n border-radius: 100%;\n background-color: ", ";\n color: ", ";\n font-size: ", ";\n font-weight: 600;\n font-family: ", ";\n letter-spacing: -1px;\n margin-left: ", ";\n margin-right: ", ";\n"], ["\n width: ", ";\n height: ", ";\n line-height: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n border-radius: 100%;\n background-color: ", ";\n color: ", ";\n font-size: ", ";\n font-weight: 600;\n font-family: ", ";\n letter-spacing: -1px;\n margin-left: ", ";\n margin-right: ", ";\n"])), function (props) { return (props.$small ? '20px' : '24px'); }, function (props) { return (props.$small ? '20px' : '24px'); }, function (props) {
2104
- return props.$format ? button_type_mapping[props.$format].badge_bg_color : '#fff';
2105
- }, function (props) {
2106
- return props.$format ? button_type_mapping[props.$format].badge_content_color : Colors.PRIMARY.Hex;
2107
- }, function (props) { return (props.$small ? '10px' : '12px'); }, FontStyles.DEFAULT, function (props) { return (props.$small ? '5px' : '10px'); }, function (props) { return (props.$small ? '-5px' : '-10px'); });
2108
- var Button = function (_a) {
2109
- var badge = _a.badge, children = _a.children, _b = _a.disabled, disabled = _b === void 0 ? false : _b, icon = _a.icon, _c = _a.isForm, isForm = _c === void 0 ? false : _c, _d = _a.loading, loading = _d === void 0 ? false : _d, _e = _a.margin, margin = _e === void 0 ? '' : _e, onClick = _a.onClick, _f = _a.small, small = _f === void 0 ? false : _f, _g = _a.format, format = _g === void 0 ? 'primary' : _g, accessibleProps = __rest(_a, ["badge", "children", "disabled", "icon", "isForm", "loading", "margin", "onClick", "small", "format"]);
2110
- var has_children = children && children.length > 0;
2111
- return (React.createElement(StyledButton, __assign({ "$disabled": disabled || loading, "$format": format, "$hasChildren": !!has_children, "$margin": margin, "$small": small, onClick: disabled || loading ? undefined : onClick, type: isForm ? 'submit' : undefined }, accessibleProps),
2091
+ }};
2092
+ cursor: ${props => (props.$disabled ? 'default' : 'pointer')};
2093
+ display: flex;
2094
+ align-items: center;
2095
+ justify-content: center;
2096
+ opacity: ${props => (props.$disabled ? 0.6 : 0.9)};
2097
+ border-width: 1px;
2098
+ border-style: solid;
2099
+ border-color: ${props => props.$format ? button_type_mapping[props.$format].border_color : Colors.PRIMARY.Hex};
2100
+ box-sizing: border-box;
2101
+ &:hover {
2102
+ opacity: ${props => (props.$disabled ? 0.6 : 1)};
2103
+ }
2104
+ `;
2105
+ const Label$4 = styled.span `
2106
+ color: ${props => (props.$format ? button_type_mapping[props.$format].content_color : '#fff')};
2107
+ font-size: ${props => (props.$small ? FontSizes.SMALL : FontSizes.DEFAULT)};
2108
+ font-family: ${FontStyles.DEFAULT};
2109
+ font-weight: 500;
2110
+ line-height: 1;
2111
+ `;
2112
+ const StyledIcon$3 = styled.span `
2113
+ margin-left: ${props => (props.$hasChildren ? '6px' : '0px')};
2114
+ margin-right: ${props => (props.$hasChildren ? '-4px' : '0px')};
2115
+ display: flex;
2116
+ align-items: center;
2117
+ box-sizing: border-box;
2118
+ `;
2119
+ const Badge$1 = styled.span `
2120
+ width: ${props => (props.$small ? '20px' : '24px')};
2121
+ height: ${props => (props.$small ? '20px' : '24px')};
2122
+ line-height: 1;
2123
+ display: flex;
2124
+ align-items: center;
2125
+ justify-content: center;
2126
+ border-radius: 100%;
2127
+ background-color: ${props => props.$format ? button_type_mapping[props.$format].badge_bg_color : '#fff'};
2128
+ color: ${props => props.$format ? button_type_mapping[props.$format].badge_content_color : Colors.PRIMARY.Hex};
2129
+ font-size: ${props => (props.$small ? '10px' : '12px')};
2130
+ font-weight: 600;
2131
+ font-family: ${FontStyles.DEFAULT};
2132
+ letter-spacing: -1px;
2133
+ margin-left: ${props => (props.$small ? '5px' : '10px')};
2134
+ margin-right: ${props => (props.$small ? '-5px' : '-10px')};
2135
+ `;
2136
+ const Button = (_a) => {
2137
+ var { badge, children, disabled = false, icon, isForm = false, loading = false, margin = '', onClick, small = false, format = 'primary' } = _a, accessibleProps = __rest(_a, ["badge", "children", "disabled", "icon", "isForm", "loading", "margin", "onClick", "small", "format"]);
2138
+ const has_children = children && children.length > 0;
2139
+ return (React.createElement(StyledButton, Object.assign({ "$disabled": disabled || loading, "$format": format, "$hasChildren": !!has_children, "$margin": margin, "$small": small, onClick: disabled || loading ? undefined : onClick, type: isForm ? 'submit' : undefined }, accessibleProps),
2112
2140
  children ? (React.createElement(Label$4, { "$format": format, "$small": small }, children)) : null,
2113
2141
  icon && !badge ? (React.createElement(StyledIcon$3, { "$hasChildren": !!has_children },
2114
2142
  React.createElement(Icon, { color: format ? button_type_mapping[format].content_color : '#fff', path: loading ? js.mdiLoading : icon, size: small ? '20px' : '24px', spin: loading }))) : null,
2115
2143
  badge && !icon ? (React.createElement(Badge$1, { "$format": format, "$small": small }, badge)) : null));
2116
- };
2117
- var templateObject_1$p, templateObject_2$m, templateObject_3$i, templateObject_4$9;
2144
+ };
2118
2145
 
2119
- var StyledComponent = styled.p(templateObject_1$o || (templateObject_1$o = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n letter-spacing: ", ";\n font-weight: ", ";\n font-style: ", ";\n text-decoration: ", ";\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n text-align: ", ";\n box-sizing: border-box;\n"], ["\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n letter-spacing: ", ";\n font-weight: ", ";\n font-style: ", ";\n text-decoration: ", ";\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n text-align: ", ";\n box-sizing: border-box;\n"])), function (props) { return Colors[props.$color || 'BLACK'].Hex; }, function (props) { return (props.$type === 'small' ? FontSizes.SMALL : FontSizes.DEFAULT); }, function (props) { return (props.$type === 'small' ? '1.5em' : '1.6em'); }, function (props) { return (props.$type === 'small' ? '1px' : '0px'); }, function (props) { return (props.$type === 'bold' ? '500' : '400'); }, function (props) { return (props.$type === 'italic' ? 'italic' : 'normal'); }, function (props) {
2120
- return ['underline', 'line-through'].includes(props.$type) ? props.$type : 'none';
2121
- }, function (props) { return props.$margin || '0px'; }, function (props) { return props.$padding || '0px'; }, function (props) { return props.$align || 'left'; });
2122
- var Copy = function (_a) {
2123
- var children = _a.children, _b = _a.align, align = _b === void 0 ? '' : _b, _c = _a.margin, margin = _c === void 0 ? '' : _c, _d = _a.padding, padding = _d === void 0 ? '' : _d, _e = _a.type, type = _e === void 0 ? 'default' : _e, _f = _a.color, color = _f === void 0 ? 'BLACK' : _f;
2146
+ const StyledComponent = styled.p `
2147
+ color: ${props => Colors[props.$color || 'BLACK'].Hex};
2148
+ font-size: ${props => (props.$type === 'small' ? FontSizes.SMALL : FontSizes.DEFAULT)};
2149
+ line-height: ${props => (props.$type === 'small' ? '1.5em' : '1.6em')};
2150
+ letter-spacing: ${props => (props.$type === 'small' ? '1px' : '0px')};
2151
+ font-weight: ${props => (props.$type === 'bold' ? '500' : '400')};
2152
+ font-style: ${props => (props.$type === 'italic' ? 'italic' : 'normal')};
2153
+ text-decoration: ${props => ['underline', 'line-through'].includes(props.$type) ? props.$type : 'none'};
2154
+ font-family: 'Roboto', Helvetica, Arial, sans-serif;
2155
+ margin: ${props => props.$margin || '0px'};
2156
+ padding: ${props => props.$padding || '0px'};
2157
+ text-align: ${props => props.$align || 'left'};
2158
+ box-sizing: border-box;
2159
+ `;
2160
+ const Copy = ({ children, align = '', margin = '', padding = '', type = 'default', color = 'BLACK', }) => {
2124
2161
  return (React.createElement(StyledComponent, { "$align": align, "$color": color, "$margin": margin, "$padding": padding, "$type": type }, children));
2125
2162
  };
2126
2163
  Copy.defaultProps = {
2127
2164
  type: 'default',
2128
- };
2129
- var templateObject_1$o;
2165
+ };
2130
2166
 
2131
- var H1 = styled.h1(templateObject_1$n || (templateObject_1$n = __makeTemplateObject(["\n color: ", ";\n font-size: 30px;\n font-weight: ", ";\n line-height: 1.4em;\n font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n box-sizing: border-box;\n"], ["\n color: ", ";\n font-size: 30px;\n font-weight: ", ";\n line-height: 1.4em;\n font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n box-sizing: border-box;\n"])), Colors.BLACK.Hex, function (props) { return (props.$bold ? '500' : '400'); }, function (props) { return props.$margin || '0px'; }, function (props) { return props.$padding || '0px'; });
2132
- var H2 = styled.h2(templateObject_2$l || (templateObject_2$l = __makeTemplateObject(["\n color: ", ";\n font-size: 24px;\n font-weight: ", ";\n line-height: 1.33em;\n font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n box-sizing: border-box;\n"], ["\n color: ", ";\n font-size: 24px;\n font-weight: ", ";\n line-height: 1.33em;\n font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n box-sizing: border-box;\n"])), Colors.BLACK.Hex, function (props) { return (props.$bold ? '500' : '400'); }, function (props) { return props.$margin || '0px'; }, function (props) { return props.$padding || '0px'; });
2133
- var H3 = styled.h3(templateObject_3$h || (templateObject_3$h = __makeTemplateObject(["\n color: ", ";\n font-size: 18px;\n font-weight: ", ";\n line-height: 1.33em;\n font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n box-sizing: border-box;\n"], ["\n color: ", ";\n font-size: 18px;\n font-weight: ", ";\n line-height: 1.33em;\n font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;\n margin: ", ";\n padding: ", ";\n box-sizing: border-box;\n"])), Colors.BLACK.Hex, function (props) { return (props.$bold ? '500' : '400'); }, function (props) { return props.$margin || '0px'; }, function (props) { return props.$padding || '0px'; });
2134
- var Heading = function (_a) {
2135
- var bold = _a.bold, children = _a.children, margin = _a.margin, padding = _a.padding, type = _a.type, accessibleProps = __rest(_a, ["bold", "children", "margin", "padding", "type"]);
2167
+ const H1 = styled.h1 `
2168
+ color: ${Colors.BLACK.Hex};
2169
+ font-size: 30px;
2170
+ font-weight: ${props => (props.$bold ? '500' : '400')};
2171
+ line-height: 1.4em;
2172
+ font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;
2173
+ margin: ${props => props.$margin || '0px'};
2174
+ padding: ${props => props.$padding || '0px'};
2175
+ box-sizing: border-box;
2176
+ `;
2177
+ const H2 = styled.h2 `
2178
+ color: ${Colors.BLACK.Hex};
2179
+ font-size: 24px;
2180
+ font-weight: ${props => (props.$bold ? '500' : '400')};
2181
+ line-height: 1.33em;
2182
+ font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;
2183
+ margin: ${props => props.$margin || '0px'};
2184
+ padding: ${props => props.$padding || '0px'};
2185
+ box-sizing: border-box;
2186
+ `;
2187
+ const H3 = styled.h3 `
2188
+ color: ${Colors.BLACK.Hex};
2189
+ font-size: 18px;
2190
+ font-weight: ${props => (props.$bold ? '500' : '400')};
2191
+ line-height: 1.33em;
2192
+ font-family: 'Roboto Slab', Roboto, Helvetica, Arial, sans-serif;
2193
+ margin: ${props => props.$margin || '0px'};
2194
+ padding: ${props => props.$padding || '0px'};
2195
+ box-sizing: border-box;
2196
+ `;
2197
+ const Heading = (_a) => {
2198
+ var { bold, children, margin, padding, type } = _a, accessibleProps = __rest(_a, ["bold", "children", "margin", "padding", "type"]);
2136
2199
  switch (type) {
2137
2200
  case 'secondary': {
2138
- return (React.createElement(H2, __assign({ "$bold": bold, "$margin": margin, "$padding": padding }, accessibleProps), children));
2201
+ return (React.createElement(H2, Object.assign({ "$bold": bold, "$margin": margin, "$padding": padding }, accessibleProps), children));
2139
2202
  }
2140
2203
  case 'tertiary': {
2141
- return (React.createElement(H3, __assign({ "$bold": bold, "$margin": margin, "$padding": padding }, accessibleProps), children));
2204
+ return (React.createElement(H3, Object.assign({ "$bold": bold, "$margin": margin, "$padding": padding }, accessibleProps), children));
2142
2205
  }
2143
2206
  default: {
2144
- return (React.createElement(H1, __assign({ "$bold": bold, "$margin": margin, "$padding": padding }, accessibleProps), children));
2207
+ return (React.createElement(H1, Object.assign({ "$bold": bold, "$margin": margin, "$padding": padding }, accessibleProps), children));
2145
2208
  }
2146
2209
  }
2147
2210
  };
2148
2211
  Heading.defaultProps = {
2149
2212
  bold: false,
2150
2213
  type: 'primary',
2151
- };
2152
- var templateObject_1$n, templateObject_2$l, templateObject_3$h;
2153
-
2154
- var Wrapper$g = styled.div(templateObject_1$m || (templateObject_1$m = __makeTemplateObject(["\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 9999;\n background: rgba(0, 0, 0, 0.8);\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n"], ["\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 9999;\n background: rgba(0, 0, 0, 0.8);\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n"])));
2155
- var Container$3 = styled.dialog(templateObject_2$k || (templateObject_2$k = __makeTemplateObject(["\n max-width: 600px;\n width: auto;\n border-radius: 8px;\n overflow: hidden;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n outline: none;\n border: none;\n position: relative;\n padding: 40px;\n text-align: center;\n box-sizing: border-box;\n"], ["\n max-width: 600px;\n width: auto;\n border-radius: 8px;\n overflow: hidden;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n outline: none;\n border: none;\n position: relative;\n padding: 40px;\n text-align: center;\n box-sizing: border-box;\n"])));
2156
- var Buttons = styled.div(templateObject_3$g || (templateObject_3$g = __makeTemplateObject(["\n display: flex;\n gap: 10px;\n align-items: center;\n justify-content: center;\n margin-top: 30px;\n box-sizing: border-box;\n"], ["\n display: flex;\n gap: 10px;\n align-items: center;\n justify-content: center;\n margin-top: 30px;\n box-sizing: border-box;\n"])));
2157
- var ActionDialog = function (_a) {
2158
- var description = _a.description, title = _a.title, primaryButton = _a.primaryButton, secondaryButton = _a.secondaryButton, tertiaryButton = _a.tertiaryButton, accessibleProps = __rest(_a, ["description", "title", "primaryButton", "secondaryButton", "tertiaryButton"]);
2159
- return (React.createElement(Wrapper$g, __assign({}, accessibleProps),
2214
+ };
2215
+
2216
+ const Wrapper$h = styled.div `
2217
+ position: fixed;
2218
+ top: 0;
2219
+ right: 0;
2220
+ bottom: 0;
2221
+ left: 0;
2222
+ z-index: 9999;
2223
+ background: rgba(0, 0, 0, 0.8);
2224
+ display: flex;
2225
+ align-items: center;
2226
+ justify-content: center;
2227
+ box-sizing: border-box;
2228
+ `;
2229
+ const Container$3 = styled.dialog `
2230
+ max-width: 600px;
2231
+ width: auto;
2232
+ border-radius: 8px;
2233
+ overflow: hidden;
2234
+ box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);
2235
+ outline: none;
2236
+ border: none;
2237
+ position: relative;
2238
+ padding: 40px;
2239
+ text-align: center;
2240
+ box-sizing: border-box;
2241
+ `;
2242
+ const Buttons = styled.div `
2243
+ display: flex;
2244
+ gap: 10px;
2245
+ align-items: center;
2246
+ justify-content: center;
2247
+ margin-top: 30px;
2248
+ box-sizing: border-box;
2249
+ `;
2250
+ const ActionDialog = (_a) => {
2251
+ var { description, title, primaryButton, secondaryButton, tertiaryButton } = _a, accessibleProps = __rest(_a, ["description", "title", "primaryButton", "secondaryButton", "tertiaryButton"]);
2252
+ return (React.createElement(Wrapper$h, Object.assign({}, accessibleProps),
2160
2253
  React.createElement(Container$3, { open: true },
2161
2254
  title ? (React.createElement(Heading, { margin: '0px 0px 20px 0px', type: 'secondary' }, title)) : null,
2162
2255
  description ? React.createElement(Copy, { align: 'center' }, description) : null,
2163
2256
  primaryButton || secondaryButton || tertiaryButton ? (React.createElement(Buttons, null,
2164
- tertiaryButton ? React.createElement(Button, __assign({}, tertiaryButton, { format: 'secondary' })) : null,
2165
- secondaryButton ? React.createElement(Button, __assign({}, secondaryButton, { format: 'secondary' })) : null,
2166
- primaryButton ? (React.createElement(Button, __assign({}, primaryButton, { format: primaryButton.format === 'red' ? 'red' : 'primary' }))) : null)) : null)));
2167
- };
2168
- var templateObject_1$m, templateObject_2$k, templateObject_3$g;
2169
-
2170
- var Wrapper$f = styled.div(templateObject_1$l || (templateObject_1$l = __makeTemplateObject(["\n border: 1px solid #f1f1f1;\n border-radius: 4px;\n border-left-width: 4px;\n box-shadow: 0px 4px 12px -6px rgba(0, 0, 0, 0.2);\n display: flex;\n align-items: flex-start;\n padding: 20px;\n box-sizing: border-box;\n"], ["\n border: 1px solid #f1f1f1;\n border-radius: 4px;\n border-left-width: 4px;\n box-shadow: 0px 4px 12px -6px rgba(0, 0, 0, 0.2);\n display: flex;\n align-items: flex-start;\n padding: 20px;\n box-sizing: border-box;\n"])));
2171
- var Content$2 = styled.div(templateObject_2$j || (templateObject_2$j = __makeTemplateObject(["\n margin-left: 20px;\n"], ["\n margin-left: 20px;\n"])));
2172
- var Action$1 = styled.div(templateObject_3$f || (templateObject_3$f = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n font-family: ", ";\n font-weight: 500;\n cursor: pointer;\n margin-top: 6px;\n"], ["\n color: ", ";\n font-size: ", ";\n font-family: ", ";\n font-weight: 500;\n cursor: pointer;\n margin-top: 6px;\n"])), Colors.PRIMARY.Hex, FontSizes.DEFAULT, FontStyles.DEFAULT);
2173
- var Alert = function (_a) {
2174
- var action = _a.action, _b = _a.type, type = _b === void 0 ? 'info' : _b, title = _a.title, description = _a.description, accessibleProps = __rest(_a, ["action", "type", "title", "description"]);
2175
- var type_mapping = {
2257
+ tertiaryButton ? React.createElement(Button, Object.assign({}, tertiaryButton, { format: 'secondary' })) : null,
2258
+ secondaryButton ? React.createElement(Button, Object.assign({}, secondaryButton, { format: 'secondary' })) : null,
2259
+ primaryButton ? (React.createElement(Button, Object.assign({}, primaryButton, { format: primaryButton.format === 'red' ? 'red' : 'primary' }))) : null)) : null)));
2260
+ };
2261
+
2262
+ const Wrapper$g = styled.div `
2263
+ border: 1px solid #f1f1f1;
2264
+ border-radius: 4px;
2265
+ border-left-width: 4px;
2266
+ box-shadow: 0px 4px 12px -6px rgba(0, 0, 0, 0.2);
2267
+ display: flex;
2268
+ align-items: flex-start;
2269
+ padding: 20px;
2270
+ box-sizing: border-box;
2271
+ `;
2272
+ const Content$3 = styled.div `
2273
+ margin-left: 20px;
2274
+ `;
2275
+ const Action$1 = styled.div `
2276
+ color: ${Colors.PRIMARY.Hex};
2277
+ font-size: ${FontSizes.DEFAULT};
2278
+ font-family: ${FontStyles.DEFAULT};
2279
+ font-weight: 500;
2280
+ cursor: pointer;
2281
+ margin-top: 6px;
2282
+ `;
2283
+ const Alert = (_a) => {
2284
+ var { action, type = 'info', title, description } = _a, accessibleProps = __rest(_a, ["action", "type", "title", "description"]);
2285
+ const type_mapping = {
2176
2286
  info: {
2177
2287
  color: Colors.PRIMARY.Hex,
2178
2288
  icon: js.mdiInformationOutline,
@@ -2190,90 +2300,237 @@ var Alert = function (_a) {
2190
2300
  icon: js.mdiCheckboxMarkedCircleOutline,
2191
2301
  },
2192
2302
  };
2193
- return (React.createElement(Wrapper$f, __assign({}, accessibleProps, { style: { borderLeftColor: type_mapping[type].color } }),
2303
+ return (React.createElement(Wrapper$g, Object.assign({}, accessibleProps, { style: { borderLeftColor: type_mapping[type].color } }),
2194
2304
  React.createElement("div", { style: { flexShrink: 0 } },
2195
2305
  React.createElement(Icon, { color: type_mapping[type].color, path: type_mapping[type].icon, size: '30px' })),
2196
- React.createElement(Content$2, null,
2306
+ React.createElement(Content$3, null,
2197
2307
  title ? (React.createElement(Heading, { bold: true, margin: '2px 0 0 0', type: 'tertiary' }, title)) : null,
2198
2308
  description ? React.createElement(Copy, { margin: '6px 0 0 0 !important' }, description) : null,
2199
2309
  action ? React.createElement(Action$1, { onClick: action.onClick }, action.label) : null)));
2200
- };
2201
- var templateObject_1$l, templateObject_2$j, templateObject_3$f;
2202
-
2203
- var Wrapper$e = styled.div(templateObject_1$k || (templateObject_1$k = __makeTemplateObject(["\n border: 1px solid ", ";\n border-radius: 8px;\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 16px 20px;\n"], ["\n border: 1px solid ", ";\n border-radius: 8px;\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 16px 20px;\n"])), Colors.PRIMARY.Hex);
2204
- var Left = styled.div(templateObject_2$i || (templateObject_2$i = __makeTemplateObject(["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: space-between;\n flex-shrink: 0;\n"], ["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: space-between;\n flex-shrink: 0;\n"])));
2205
- var Info = styled.div(templateObject_3$e || (templateObject_3$e = __makeTemplateObject(["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n margin-right: 30px;\n"], ["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n margin-right: 30px;\n"])));
2206
- var Selected = styled.span(templateObject_4$8 || (templateObject_4$8 = __makeTemplateObject(["\n font-size: 14px;\n font-weight: 400;\n font-family: ", ";\n color: ", ";\n line-height: 1;\n"], ["\n font-size: 14px;\n font-weight: 400;\n font-family: ", ";\n color: ", ";\n line-height: 1;\n"])), FontStyles.DEFAULT, Colors.BLACK.Hex);
2207
- var Clear = styled.span(templateObject_5$6 || (templateObject_5$6 = __makeTemplateObject(["\n font-size: 14px;\n font-weight: 400;\n font-family: ", ";\n color: ", ";\n line-height: 1;\n cursor: pointer;\n padding-left: 10px;\n margin-left: 10px;\n border-left: 1px solid #ccc;\n"], ["\n font-size: 14px;\n font-weight: 400;\n font-family: ", ";\n color: ", ";\n line-height: 1;\n cursor: pointer;\n padding-left: 10px;\n margin-left: 10px;\n border-left: 1px solid #ccc;\n"])), FontStyles.DEFAULT, Colors.PRIMARY.Hex);
2208
- var Actions = styled.div(templateObject_6$4 || (templateObject_6$4 = __makeTemplateObject(["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n column-gap: 10px;\n"], ["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n column-gap: 10px;\n"])));
2209
- var Error$1 = styled.div(templateObject_7$2 || (templateObject_7$2 = __makeTemplateObject(["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n background: rgba(", ", 0.1);\n border-radius: 4px;\n padding: 6px 8px;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n margin-left: 30px;\n"], ["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n background: rgba(", ", 0.1);\n border-radius: 4px;\n padding: 6px 8px;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n margin-left: 30px;\n"])), Colors.RED.Rgb);
2210
- var ErrorMsg = styled.span(templateObject_8$2 || (templateObject_8$2 = __makeTemplateObject(["\n font-size: 14px;\n font-weight: 500;\n font-family: ", ";\n line-height: 1em;\n color: ", ";\n margin-left: 8px;\n"], ["\n font-size: 14px;\n font-weight: 500;\n font-family: ", ";\n line-height: 1em;\n color: ", ";\n margin-left: 8px;\n"])), FontStyles.DEFAULT, Colors.RED.Hex);
2211
- var BulkActionBar = function (_a) {
2212
- var _b = _a.actions, actions = _b === void 0 ? [] : _b, errorMsg = _a.errorMsg, onClear = _a.onClear, _c = _a.selectedCount, selectedCount = _c === void 0 ? 0 : _c, accessibleProps = __rest(_a, ["actions", "errorMsg", "onClear", "selectedCount"]);
2213
- return (React.createElement(Wrapper$e, __assign({}, accessibleProps),
2310
+ };
2311
+
2312
+ const Wrapper$f = styled.div `
2313
+ border: 1px solid ${Colors.PRIMARY.Hex};
2314
+ border-radius: 8px;
2315
+ box-sizing: border-box;
2316
+ display: flex;
2317
+ align-items: center;
2318
+ justify-content: space-between;
2319
+ padding: 16px 20px;
2320
+ `;
2321
+ const Left = styled.div `
2322
+ box-sizing: border-box;
2323
+ display: flex;
2324
+ align-items: center;
2325
+ justify-content: space-between;
2326
+ flex-shrink: 0;
2327
+ `;
2328
+ const Info$1 = styled.div `
2329
+ box-sizing: border-box;
2330
+ display: flex;
2331
+ align-items: center;
2332
+ margin-right: 30px;
2333
+ `;
2334
+ const Selected = styled.span `
2335
+ font-size: 14px;
2336
+ font-weight: 400;
2337
+ font-family: ${FontStyles.DEFAULT};
2338
+ color: ${Colors.BLACK.Hex};
2339
+ line-height: 1;
2340
+ `;
2341
+ const Clear = styled.span `
2342
+ font-size: 14px;
2343
+ font-weight: 400;
2344
+ font-family: ${FontStyles.DEFAULT};
2345
+ color: ${Colors.PRIMARY.Hex};
2346
+ line-height: 1;
2347
+ cursor: pointer;
2348
+ padding-left: 10px;
2349
+ margin-left: 10px;
2350
+ border-left: 1px solid #ccc;
2351
+ `;
2352
+ const Actions$1 = styled.div `
2353
+ box-sizing: border-box;
2354
+ display: flex;
2355
+ align-items: center;
2356
+ column-gap: 10px;
2357
+ `;
2358
+ const Error$1 = styled.div `
2359
+ box-sizing: border-box;
2360
+ display: flex;
2361
+ align-items: center;
2362
+ background: rgba(${Colors.RED.Rgb}, 0.1);
2363
+ border-radius: 4px;
2364
+ padding: 6px 8px;
2365
+ text-overflow: ellipsis;
2366
+ white-space: nowrap;
2367
+ overflow: hidden;
2368
+ margin-left: 30px;
2369
+ `;
2370
+ const ErrorMsg = styled.span `
2371
+ font-size: 14px;
2372
+ font-weight: 500;
2373
+ font-family: ${FontStyles.DEFAULT};
2374
+ line-height: 1em;
2375
+ color: ${Colors.RED.Hex};
2376
+ margin-left: 8px;
2377
+ `;
2378
+ const BulkActionBar = (_a) => {
2379
+ var { actions = [], errorMsg, onClear, selectedCount = 0 } = _a, accessibleProps = __rest(_a, ["actions", "errorMsg", "onClear", "selectedCount"]);
2380
+ return (React.createElement(Wrapper$f, Object.assign({}, accessibleProps),
2214
2381
  React.createElement(Left, null,
2215
- React.createElement(Info, null,
2382
+ React.createElement(Info$1, null,
2216
2383
  React.createElement(Selected, null,
2217
2384
  selectedCount,
2218
2385
  " Selected"),
2219
2386
  onClear ? React.createElement(Clear, { onClick: onClear }, "Clear") : null),
2220
- React.createElement(Actions, null, actions.map(function (action) { return (React.createElement(Button, __assign({}, action, { small: true }))); }))),
2387
+ React.createElement(Actions$1, null, actions.map(action => (React.createElement(Button, Object.assign({}, action, { small: true })))))),
2221
2388
  errorMsg ? (React.createElement(Error$1, null,
2222
2389
  React.createElement(Icon, { color: Colors.RED.Hex, path: js.mdiInformationOutline, size: '20px' }),
2223
2390
  React.createElement(ErrorMsg, null, errorMsg))) : null));
2224
- };
2225
- var templateObject_1$k, templateObject_2$i, templateObject_3$e, templateObject_4$8, templateObject_5$6, templateObject_6$4, templateObject_7$2, templateObject_8$2;
2226
-
2227
- var Wrapper$d = styled.label(templateObject_1$j || (templateObject_1$j = __makeTemplateObject(["\n padding: 4px 0;\n cursor: ", ";\n display: flex;\n align-items: flex-start;\n font-size: ", ";\n line-height: 1.6em;\n box-sizing: border-box;\n"], ["\n padding: 4px 0;\n cursor: ", ";\n display: flex;\n align-items: flex-start;\n font-size: ", ";\n line-height: 1.6em;\n box-sizing: border-box;\n"])), function (props) { return (props.$disabled ? 'default' : 'pointer'); }, FontSizes.DEFAULT);
2228
- var Input$2 = styled.input(templateObject_2$h || (templateObject_2$h = __makeTemplateObject(["\n font-size: 20px;\n margin: 5px 0px 0px 0px;\n line-height: 1.1em;\n box-sizing: border-box;\n"], ["\n font-size: 20px;\n margin: 5px 0px 0px 0px;\n line-height: 1.1em;\n box-sizing: border-box;\n"])));
2229
- var Label$3 = styled.span(templateObject_3$d || (templateObject_3$d = __makeTemplateObject(["\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n line-height: 1.6em;\n color: ", ";\n margin-left: 6px;\n box-sizing: border-box;\n"], ["\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n line-height: 1.6em;\n color: ", ";\n margin-left: 6px;\n box-sizing: border-box;\n"])), FontStyles.DEFAULT, FontSizes.DEFAULT, Colors.BLACK.Hex);
2230
- var Checkbox = function (_a) {
2231
- var children = _a.children, disabled = _a.disabled, checked = _a.checked, onChange = _a.onChange, accessibleProps = __rest(_a, ["children", "disabled", "checked", "onChange"]);
2232
- return (React.createElement(Wrapper$d, __assign({}, accessibleProps),
2391
+ };
2392
+
2393
+ const Wrapper$e = styled.div `
2394
+ background: #fff;
2395
+ border-radius: 8px;
2396
+ box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);
2397
+ display: flex;
2398
+ flex-direction: column;
2399
+ gap: 4px;
2400
+ max-height: ${props => props.$maxHeight || '312px'};
2401
+ padding: 10px;
2402
+ width: 200px;
2403
+ `;
2404
+ const MenuItem = styled.div `
2405
+ align-items: center;
2406
+ border-radius: 8px;
2407
+ border: 1px solid transparent;
2408
+ display: flex;
2409
+ gap: 8px;
2410
+ height: 38px;
2411
+ padding: 8px;
2412
+ &:hover {
2413
+ background: rgba(1, 147, 215, 0.1);
2414
+ cursor: pointer;
2415
+
2416
+ svg,
2417
+ path {
2418
+ fill: ${Colors.PRIMARY.Hex} !important;
2419
+ }
2420
+ }
2421
+ `;
2422
+ const Title = styled.span `
2423
+ font-family: Roboto;
2424
+ font-size: 14px;
2425
+ font-weight: 400;
2426
+ height: auto;
2427
+ letter-spacing: 0px;
2428
+ line-height: 22px;
2429
+ text-align: left;
2430
+ `;
2431
+ const MoreMenu = (_a) => {
2432
+ var { maxHeight, menuItems = [] } = _a, accessibleProps = __rest(_a, ["maxHeight", "menuItems"]);
2433
+ return (React.createElement(Wrapper$e, Object.assign({ "$maxHeight": maxHeight }, accessibleProps), menuItems.map((item) => {
2434
+ return (React.createElement(MenuItem, { onClick: item.onClick },
2435
+ item.icon ? (React.createElement(Icon, { color: Colors.MEDIUM_GRAY.Hex, path: item.icon, size: '20px' })) : null,
2436
+ React.createElement(Title, null, item.label)));
2437
+ })));
2438
+ };
2439
+
2440
+ const Wrapper$d = styled.div `
2441
+ position: relative;
2442
+ display: inline-block;
2443
+ `;
2444
+ const StyledMoreMenu = styled(MoreMenu) `
2445
+ position: absolute;
2446
+ right: ${props => (props.$position === 'right' ? '0px' : 'auto')};
2447
+ left: ${props => (props.$position === 'left' ? '0px' : 'auto')};
2448
+ top: ${props => (props.$small ? '30px' : '40px')};
2449
+ z-index: 10;
2450
+ `;
2451
+ const ButtonMenu = ({ disabled, label, maxHeight, menuItems, small, position = 'right', }) => {
2452
+ const [show_menu, toggleMenu] = React.useState(false);
2453
+ return (React.createElement(Wrapper$d, { onMouseEnter: disabled ? undefined : toggleMenu.bind(null, true), onMouseLeave: disabled ? undefined : toggleMenu.bind(null, false) },
2454
+ React.createElement(Button, { disabled: disabled, format: 'primary', icon: js.mdiDotsHorizontal, small: small }, label),
2455
+ show_menu ? (React.createElement(StyledMoreMenu, { "$position": position, "$small": small, maxHeight: maxHeight, menuItems: menuItems })) : null));
2456
+ };
2457
+
2458
+ const Wrapper$c = styled.label `
2459
+ padding: 4px 0;
2460
+ cursor: ${props => (props.$disabled ? 'default' : 'pointer')};
2461
+ display: flex;
2462
+ align-items: flex-start;
2463
+ font-size: ${FontSizes.DEFAULT};
2464
+ line-height: 1.6em;
2465
+ box-sizing: border-box;
2466
+ `;
2467
+ const Input$2 = styled.input `
2468
+ font-size: 20px;
2469
+ margin: 5px 0px 0px 0px;
2470
+ line-height: 1.1em;
2471
+ box-sizing: border-box;
2472
+ `;
2473
+ const Label$3 = styled.span `
2474
+ font-family: ${FontStyles.DEFAULT};
2475
+ font-size: ${FontSizes.DEFAULT};
2476
+ font-weight: 400;
2477
+ line-height: 1.6em;
2478
+ color: ${Colors.BLACK.Hex};
2479
+ margin-left: 6px;
2480
+ box-sizing: border-box;
2481
+ `;
2482
+ const Checkbox = (_a) => {
2483
+ var { children, disabled, checked, onChange } = _a, accessibleProps = __rest(_a, ["children", "disabled", "checked", "onChange"]);
2484
+ return (React.createElement(Wrapper$c, Object.assign({}, accessibleProps),
2233
2485
  React.createElement(Input$2, { checked: checked, disabled: disabled, name: accessibleProps.name, onChange: disabled ? undefined : onChange, type: 'checkbox' }),
2234
2486
  children ? React.createElement(Label$3, null, children) : null));
2235
- };
2236
- var templateObject_1$j, templateObject_2$h, templateObject_3$d;
2237
-
2238
- var SelectAll = styled.div(templateObject_1$i || (templateObject_1$i = __makeTemplateObject(["\n padding: 8px 12px;\n border-bottom: 1px solid ", ";\n box-sizing: border-box;\n"], ["\n padding: 8px 12px;\n border-bottom: 1px solid ", ";\n box-sizing: border-box;\n"])), Colors.LIGHT_GRAY.Hex);
2239
- var Options$1 = styled.div(templateObject_2$g || (templateObject_2$g = __makeTemplateObject(["\n padding: 12px;\n box-sizing: border-box;\n"], ["\n padding: 12px;\n box-sizing: border-box;\n"])));
2240
- var Checklist = function (_a) {
2241
- var disabled = _a.disabled, onChange = _a.onChange, options = _a.options, _b = _a.selected, selected = _b === void 0 ? [] : _b, showSelectAll = _a.showSelectAll, accessibleProps = __rest(_a, ["disabled", "onChange", "options", "selected", "showSelectAll"]);
2242
- var values = options.map(function (option) { return option.value; });
2243
- var selected_options = options.filter(function (o) { return selected.includes(o.value); });
2244
- var handleToggleAll = function () {
2487
+ };
2488
+
2489
+ const SelectAll = styled.div `
2490
+ padding: 8px 12px;
2491
+ border-bottom: 1px solid ${Colors.LIGHT_GRAY.Hex};
2492
+ box-sizing: border-box;
2493
+ `;
2494
+ const Options$1 = styled.div `
2495
+ padding: 12px;
2496
+ box-sizing: border-box;
2497
+ `;
2498
+ const Checklist = (_a) => {
2499
+ var { disabled, onChange, options, selected = [], showSelectAll } = _a, accessibleProps = __rest(_a, ["disabled", "onChange", "options", "selected", "showSelectAll"]);
2500
+ const values = options.map((option) => option.value);
2501
+ const selected_options = options.filter(o => selected.includes(o.value));
2502
+ const handleToggleAll = () => {
2245
2503
  if (selected_options.length === options.length) {
2246
2504
  triggerChange([]);
2247
2505
  }
2248
2506
  else {
2249
- triggerChange(options.map(function (option) { return option.value; }));
2507
+ triggerChange(options.map((option) => option.value));
2250
2508
  }
2251
2509
  };
2252
- var handleChange = function (option) {
2253
- var new_selected = selected_options.filter(function (o) { return o.value !== option.value; }).map(function (o) { return o.value; });
2510
+ const handleChange = (option) => {
2511
+ const new_selected = selected_options.filter(o => o.value !== option.value).map(o => o.value);
2254
2512
  if (!selected.includes(option.value)) {
2255
2513
  new_selected.push(option.value);
2256
2514
  }
2257
2515
  // Mimic input event so it's easier to share onChange methods
2258
2516
  triggerChange(new_selected);
2259
2517
  };
2260
- var triggerChange = function (value) {
2518
+ const triggerChange = (value) => {
2261
2519
  onChange({
2262
2520
  target: {
2263
- value: value,
2521
+ value,
2264
2522
  },
2265
2523
  });
2266
2524
  };
2267
2525
  return (React.createElement(React.Fragment, null,
2268
2526
  showSelectAll && values.length ? (React.createElement(SelectAll, null,
2269
2527
  React.createElement(Checkbox, { checked: selected.length === values.length, disabled: disabled, onChange: handleToggleAll }, "Select All"))) : null,
2270
- React.createElement(Options$1, null, options.map(function (option, i) {
2271
- var label = "".concat(option.label || option.value);
2272
- var checked = selected.includes(option.value);
2273
- return (React.createElement(Checkbox, __assign({ key: i }, accessibleProps, { checked: checked, disabled: disabled, onChange: handleChange.bind(null, option) }), label));
2528
+ React.createElement(Options$1, null, options.map((option, i) => {
2529
+ const label = `${option.label || option.value}`;
2530
+ const checked = selected.includes(option.value);
2531
+ return (React.createElement(Checkbox, Object.assign({ key: i }, accessibleProps, { checked: checked, disabled: disabled, onChange: handleChange.bind(null, option) }), label));
2274
2532
  }))));
2275
- };
2276
- var templateObject_1$i, templateObject_2$g;
2533
+ };
2277
2534
 
2278
2535
  var dayjs_min = {exports: {}};
2279
2536
 
@@ -2593,51 +2850,82 @@ var dayjs_min = {exports: {}};
2593
2850
  var dayjs_minExports = dayjs_min.exports;
2594
2851
  var dayjs = /*@__PURE__*/getDefaultExportFromCjs(dayjs_minExports);
2595
2852
 
2596
- var Wrapper$c = styled.div(templateObject_1$h || (templateObject_1$h = __makeTemplateObject(["\n border-radius: 4px;\n height: 40px;\n background-color: ", ";\n position: relative;\n cursor: pointer;\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n border-radius: ", ";\n flex-grow: ", ";\n box-sizing: border-box;\n padding: 10px 0px;\n display: flex;\n align-items: center;\n width: ", ";\n"], ["\n border-radius: 4px;\n height: 40px;\n background-color: ", ";\n position: relative;\n cursor: pointer;\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n border-radius: ", ";\n flex-grow: ", ";\n box-sizing: border-box;\n padding: 10px 0px;\n display: flex;\n align-items: center;\n width: ", ";\n"])), function (props) { return (props.$readOnly ? '#f5f5f5' : '#ffffff'); }, function (props) { return (props.$invalid ? Colors.RED.Hex : '#cccccc'); }, function (_a) {
2597
- var $style = _a.$style;
2598
- return ($style === null || $style === void 0 ? void 0 : $style.borderRadius) || '4px';
2599
- }, function (_a) {
2600
- var $style = _a.$style;
2601
- return ($style === null || $style === void 0 ? void 0 : $style.flexGrow) || 0;
2602
- }, function (_a) {
2603
- var $style = _a.$style;
2604
- return ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto';
2605
- });
2606
- var Trigger$1 = styled.select(templateObject_2$f || (templateObject_2$f = __makeTemplateObject(["\n appearance: none;\n box-shadow: none;\n outline: none;\n border: none;\n color: ", ";\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 2.9em;\n background-color: transparent;\n background-image: none;\n cursor: pointer;\n width: 100%;\n box-sizing: border-box;\n padding: 0px 30px 0px 10px;\n box-sizing: border-box;\n position: relative;\n z-index: 2;\n"], ["\n appearance: none;\n box-shadow: none;\n outline: none;\n border: none;\n color: ", ";\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 2.9em;\n background-color: transparent;\n background-image: none;\n cursor: pointer;\n width: 100%;\n box-sizing: border-box;\n padding: 0px 30px 0px 10px;\n box-sizing: border-box;\n position: relative;\n z-index: 2;\n"])), Colors.BLACK.Hex, FontSizes.DEFAULT, FontStyles.DEFAULT);
2607
- var IconWrapper$2 = styled(Icon)(templateObject_3$c || (templateObject_3$c = __makeTemplateObject(["\n position: absolute;\n right: 9px;\n z-index: 1;\n"], ["\n position: absolute;\n right: 9px;\n z-index: 1;\n"])));
2608
- var Select = function (_a) {
2609
- var options = _a.options, optionGroups = _a.optionGroups, placeholder = _a.placeholder, readOnly = _a.readOnly, invalid = _a.invalid, value = _a.value, onChange = _a.onChange, style = _a.style, accessibleProps = __rest(_a, ["options", "optionGroups", "placeholder", "readOnly", "invalid", "value", "onChange", "style"]);
2610
- return (React.createElement(Wrapper$c, { "$invalid": invalid, "$readOnly": readOnly, "$style": style },
2611
- React.createElement(Trigger$1, __assign({ disabled: readOnly, onChange: onChange, placeholder: placeholder, value: value }, accessibleProps),
2853
+ const Wrapper$b = styled.div `
2854
+ border-radius: 4px;
2855
+ height: 40px;
2856
+ background-color: ${props => (props.$readOnly ? '#f5f5f5' : '#ffffff')};
2857
+ position: relative;
2858
+ cursor: pointer;
2859
+ border-width: 1px;
2860
+ border-style: solid;
2861
+ border-color: ${props => (props.$invalid ? Colors.RED.Hex : '#cccccc')};
2862
+ border-radius: ${({ $style }) => ($style === null || $style === void 0 ? void 0 : $style.borderRadius) || '4px'};
2863
+ flex-grow: ${({ $style }) => ($style === null || $style === void 0 ? void 0 : $style.flexGrow) || 0};
2864
+ box-sizing: border-box;
2865
+ padding: 10px 0px;
2866
+ display: flex;
2867
+ align-items: center;
2868
+ width: ${({ $style }) => ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto'};
2869
+ `;
2870
+ const Trigger$1 = styled.select `
2871
+ appearance: none;
2872
+ box-shadow: none;
2873
+ outline: none;
2874
+ border: none;
2875
+ color: ${Colors.BLACK.Hex};
2876
+ font-size: ${FontSizes.DEFAULT};
2877
+ font-weight: 400;
2878
+ font-family: ${FontStyles.DEFAULT};
2879
+ line-height: 2.9em;
2880
+ background-color: transparent;
2881
+ background-image: none;
2882
+ cursor: pointer;
2883
+ width: 100%;
2884
+ box-sizing: border-box;
2885
+ padding: 0px 30px 0px 10px;
2886
+ box-sizing: border-box;
2887
+ position: relative;
2888
+ z-index: 2;
2889
+ `;
2890
+ const IconWrapper$2 = styled(Icon) `
2891
+ position: absolute;
2892
+ right: 9px;
2893
+ z-index: 1;
2894
+ `;
2895
+ const Select = (_a) => {
2896
+ var { options, optionGroups, placeholder, readOnly, invalid, value, onChange, style } = _a, accessibleProps = __rest(_a, ["options", "optionGroups", "placeholder", "readOnly", "invalid", "value", "onChange", "style"]);
2897
+ return (React.createElement(Wrapper$b, { "$invalid": invalid, "$readOnly": readOnly, "$style": style },
2898
+ React.createElement(Trigger$1, Object.assign({ disabled: readOnly, onChange: onChange, placeholder: placeholder, value: value }, accessibleProps),
2612
2899
  placeholder ? (React.createElement("option", { disabled: true, value: '' }, placeholder)) : null,
2613
2900
  optionGroups &&
2614
- optionGroups.map(function (group, i) {
2615
- return (React.createElement("optgroup", { key: i, label: group.label || "Group ".concat(i) }, group.options.map(function (option, i) {
2901
+ optionGroups.map((group, i) => {
2902
+ return (React.createElement("optgroup", { key: i, label: group.label || `Group ${i}` }, group.options.map((option, i) => {
2616
2903
  return (React.createElement("option", { key: i, value: option.value }, option.label || option.value));
2617
2904
  })));
2618
2905
  }),
2619
2906
  options &&
2620
- options.map(function (option, i) {
2907
+ options.map((option, i) => {
2621
2908
  return (React.createElement("option", { key: i, value: option.value }, option.label || option.value));
2622
2909
  })),
2623
2910
  React.createElement(IconWrapper$2, { color: Colors.BLACK.Hex, path: js.mdiChevronDown, size: '22px' })));
2624
- };
2625
- var templateObject_1$h, templateObject_2$f, templateObject_3$c;
2626
-
2627
- var DatePickerWrapper = styled.div(templateObject_1$g || (templateObject_1$g = __makeTemplateObject(["\n display: flex;\n width: ", ";\n"], ["\n display: flex;\n width: ", ";\n"])), function (_a) {
2628
- var $style = _a.$style;
2629
- return ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto';
2630
- });
2631
- var Middle = styled.div(templateObject_2$e || (templateObject_2$e = __makeTemplateObject(["\n margin: 0px -1px;\n flex-grow: 1;\n"], ["\n margin: 0px -1px;\n flex-grow: 1;\n"])));
2632
- var DatePicker = function (_a) {
2633
- var _b = _a.readOnly, readOnly = _b === void 0 ? false : _b, _c = _a.invalid, invalid = _c === void 0 ? false : _c, _d = _a.maxDate, maxDate = _d === void 0 ? null : _d, _e = _a.minDate, minDate = _e === void 0 ? null : _e, date = _a.date, onChange = _a.onChange, style = _a.style;
2634
- var dMaxDate = maxDate ? dayjs(maxDate) : dayjs();
2635
- var dMinDate = minDate ? dayjs(minDate) : dMaxDate.subtract(100, 'year');
2636
- var _f = React.useState(dayjs(date)), dDate = _f[0], setDate = _f[1];
2637
- var _g = React.useState(Array.from({ length: dDate.daysInMonth() - 1 }, function (_, i) { return ({
2911
+ };
2912
+
2913
+ const DatePickerWrapper = styled.div `
2914
+ display: flex;
2915
+ width: ${({ $style }) => ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto'};
2916
+ `;
2917
+ const Middle = styled.div `
2918
+ margin: 0px -1px;
2919
+ flex-grow: 1;
2920
+ `;
2921
+ const DatePicker = ({ readOnly = false, invalid = false, maxDate = null, minDate = null, date, onChange, style, }) => {
2922
+ const dMaxDate = maxDate ? dayjs(maxDate) : dayjs();
2923
+ const dMinDate = minDate ? dayjs(minDate) : dMaxDate.subtract(100, 'year');
2924
+ const [dDate, setDate] = React.useState(dayjs(date));
2925
+ const [dayOptions, setDayOptions] = React.useState(Array.from({ length: dDate.daysInMonth() - 1 }, (_, i) => ({
2638
2926
  value: i + 1,
2639
- }); })), dayOptions = _g[0], setDayOptions = _g[1];
2640
- var months = [
2927
+ })));
2928
+ const months = [
2641
2929
  { label: 'January', value: 1 },
2642
2930
  { label: 'Feburary', value: 2 },
2643
2931
  { label: 'March', value: 3 },
@@ -2651,14 +2939,14 @@ var DatePicker = function (_a) {
2651
2939
  { label: 'November', value: 11 },
2652
2940
  { label: 'December', value: 12 },
2653
2941
  ];
2654
- var years = Array.from({ length: dMaxDate.year() - dMinDate.year() + 1 }, function (_, i) { return ({
2942
+ const years = Array.from({ length: dMaxDate.year() - dMinDate.year() + 1 }, (_, i) => ({
2655
2943
  label: (dMinDate.year() + i).toString(),
2656
2944
  value: dMinDate.year() + i,
2657
- }); });
2658
- React.useEffect(function () {
2659
- setDayOptions(Array.from({ length: dDate.daysInMonth() }, function (_, i) { return ({
2945
+ }));
2946
+ React.useEffect(() => {
2947
+ setDayOptions(Array.from({ length: dDate.daysInMonth() }, (_, i) => ({
2660
2948
  value: i + 1,
2661
- }); }));
2949
+ })));
2662
2950
  // Mimicing browser event structure
2663
2951
  onChange({
2664
2952
  target: {
@@ -2666,19 +2954,19 @@ var DatePicker = function (_a) {
2666
2954
  },
2667
2955
  });
2668
2956
  }, [dDate]);
2669
- var handleDayChange = function (e) {
2670
- var date = parseInt(e.target.value, 10);
2671
- var new_date = dDate.date(date);
2957
+ const handleDayChange = (e) => {
2958
+ const date = parseInt(e.target.value, 10);
2959
+ const new_date = dDate.date(date);
2672
2960
  setDate(new_date);
2673
2961
  };
2674
- var handleMonthChange = function (e) {
2675
- var month = parseInt(e.target.value, 10);
2676
- var new_date = dDate.month(month - 1); // dayjs month is zero based
2962
+ const handleMonthChange = (e) => {
2963
+ const month = parseInt(e.target.value, 10);
2964
+ const new_date = dDate.month(month - 1); // dayjs month is zero based
2677
2965
  setDate(new_date);
2678
2966
  };
2679
- var handleYearChange = function (e) {
2680
- var year = parseInt(e.target.value, 10);
2681
- var new_date = dDate.year(year);
2967
+ const handleYearChange = (e) => {
2968
+ const year = parseInt(e.target.value, 10);
2969
+ const new_date = dDate.year(year);
2682
2970
  setDate(new_date);
2683
2971
  };
2684
2972
  return (React.createElement(React.Fragment, null,
@@ -2687,37 +2975,71 @@ var DatePicker = function (_a) {
2687
2975
  React.createElement(Middle, null,
2688
2976
  React.createElement(Select, { invalid: invalid, onChange: handleDayChange, options: dayOptions, readOnly: readOnly, style: { borderRadius: '0px' }, value: dDate.format('D') })),
2689
2977
  React.createElement(Select, { invalid: invalid, onChange: handleYearChange, options: years, readOnly: readOnly, style: { borderRadius: '0px 4px 4px 0px', flexGrow: 2 }, value: dDate.format('YYYY') }))));
2690
- };
2691
- var templateObject_1$g, templateObject_2$e;
2692
-
2693
- var Scrim$1 = styled.div(templateObject_1$f || (templateObject_1$f = __makeTemplateObject(["\n position: ", ";\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: ", ";\n background: ", ";\n"], ["\n position: ", ";\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: ", ";\n background: ", ";\n"])), function (_a) {
2694
- var $position = _a.$position;
2695
- return $position;
2696
- }, function (_a) {
2697
- var $position = _a.$position;
2698
- return ($position === 'fixed' ? 9998 : 10);
2699
- }, function (_a) {
2700
- var $scrim = _a.$scrim;
2701
- return ($scrim === 'dark' ? 'rgba(0,0,0,0.8)' : 'transparent');
2702
- });
2703
- var Container$2 = styled.div(templateObject_2$d || (templateObject_2$d = __makeTemplateObject(["\n z-index: ", ";\n min-width: 400px;\n width: ", ";\n overflow: hidden;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n outline: none;\n border: none;\n position: ", ";\n top: 0;\n right: 0;\n bottom: 0;\n padding: 0px;\n display: flex;\n flex-direction: column;\n box-sizing: border-box;\n background: #fff;\n"], ["\n z-index: ", ";\n min-width: 400px;\n width: ", ";\n overflow: hidden;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n outline: none;\n border: none;\n position: ", ";\n top: 0;\n right: 0;\n bottom: 0;\n padding: 0px;\n display: flex;\n flex-direction: column;\n box-sizing: border-box;\n background: #fff;\n"])), function (_a) {
2704
- var $position = _a.$position;
2705
- return ($position === 'fixed' ? 9999 : 11);
2706
- }, function (_a) {
2707
- var $width = _a.$width;
2708
- return $width || '400px';
2709
- }, function (_a) {
2710
- var $position = _a.$position;
2711
- return $position;
2712
- });
2713
- var Header$2 = styled.div(templateObject_3$b || (templateObject_3$b = __makeTemplateObject(["\n padding: 30px 20px;\n display: flex;\n align-items: flex-start;\n box-sizing: border-box;\n flex-shrink: 0;\n background: #fff;\n"], ["\n padding: 30px 20px;\n display: flex;\n align-items: flex-start;\n box-sizing: border-box;\n flex-shrink: 0;\n background: #fff;\n"])));
2714
- var Close$1 = styled.div(templateObject_4$7 || (templateObject_4$7 = __makeTemplateObject(["\n margin-left: auto;\n display: flex;\n align-items: center;\n padding-left: 20px;\n cursor: pointer;\n"], ["\n margin-left: auto;\n display: flex;\n align-items: center;\n padding-left: 20px;\n cursor: pointer;\n"])));
2715
- var ContentWrapper$1 = styled.div(templateObject_5$5 || (templateObject_5$5 = __makeTemplateObject(["\n overflow-x: hidden;\n overflow-y: auto;\n box-sizing: border-box;\n flex: 1;\n background: #fff;\n"], ["\n overflow-x: hidden;\n overflow-y: auto;\n box-sizing: border-box;\n flex: 1;\n background: #fff;\n"])));
2716
- var ButtonBar$1 = styled.div(templateObject_6$3 || (templateObject_6$3 = __makeTemplateObject(["\n padding: 20px;\n display: flex;\n align-items: center;\n justify-content: flex-end;\n box-sizing: border-box;\n gap: 10px;\n flex-shrink: 0;\n background: #fff;\n"], ["\n padding: 20px;\n display: flex;\n align-items: center;\n justify-content: flex-end;\n box-sizing: border-box;\n gap: 10px;\n flex-shrink: 0;\n background: #fff;\n"])));
2717
- var Drawer = function (_a) {
2718
- var children = _a.children, description = _a.description, title = _a.title, onClose = _a.onClose, primaryButton = _a.primaryButton, _b = _a.position, position = _b === void 0 ? 'fixed' : _b, secondaryButton = _a.secondaryButton, tertiaryButton = _a.tertiaryButton, _c = _a.scrim, scrim = _c === void 0 ? 'dark' : _c, width = _a.width, accessibleProps = __rest(_a, ["children", "description", "title", "onClose", "primaryButton", "position", "secondaryButton", "tertiaryButton", "scrim", "width"]);
2719
- React.useEffect(function () {
2720
- document.onkeydown = function (e) {
2978
+ };
2979
+
2980
+ const Scrim$1 = styled.div `
2981
+ position: ${({ $position }) => $position};
2982
+ top: 0;
2983
+ right: 0;
2984
+ bottom: 0;
2985
+ left: 0;
2986
+ z-index: ${({ $position }) => ($position === 'fixed' ? 9998 : 10)};
2987
+ background: ${({ $scrim }) => ($scrim === 'dark' ? 'rgba(0,0,0,0.8)' : 'transparent')};
2988
+ `;
2989
+ const Container$2 = styled.div `
2990
+ z-index: ${({ $position }) => ($position === 'fixed' ? 9999 : 11)};
2991
+ min-width: 400px;
2992
+ width: ${({ $width }) => $width || '400px'};
2993
+ overflow: hidden;
2994
+ box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);
2995
+ outline: none;
2996
+ border: none;
2997
+ position: ${({ $position }) => $position};
2998
+ top: 0;
2999
+ right: 0;
3000
+ bottom: 0;
3001
+ padding: 0px;
3002
+ display: flex;
3003
+ flex-direction: column;
3004
+ box-sizing: border-box;
3005
+ background: #fff;
3006
+ `;
3007
+ const Header$2 = styled.div `
3008
+ padding: 30px 20px;
3009
+ display: flex;
3010
+ align-items: flex-start;
3011
+ box-sizing: border-box;
3012
+ flex-shrink: 0;
3013
+ background: #fff;
3014
+ `;
3015
+ const Close$1 = styled.div `
3016
+ margin-left: auto;
3017
+ display: flex;
3018
+ align-items: center;
3019
+ padding-left: 20px;
3020
+ cursor: pointer;
3021
+ `;
3022
+ const ContentWrapper$1 = styled.div `
3023
+ overflow-x: hidden;
3024
+ overflow-y: auto;
3025
+ box-sizing: border-box;
3026
+ flex: 1;
3027
+ background: #fff;
3028
+ `;
3029
+ const ButtonBar$1 = styled.div `
3030
+ padding: 20px;
3031
+ display: flex;
3032
+ align-items: center;
3033
+ justify-content: flex-end;
3034
+ box-sizing: border-box;
3035
+ gap: 10px;
3036
+ flex-shrink: 0;
3037
+ background: #fff;
3038
+ `;
3039
+ const Drawer = (_a) => {
3040
+ var { children, description, title, onClose, primaryButton, position = 'fixed', secondaryButton, tertiaryButton, scrim = 'dark', width } = _a, accessibleProps = __rest(_a, ["children", "description", "title", "onClose", "primaryButton", "position", "secondaryButton", "tertiaryButton", "scrim", "width"]);
3041
+ React.useEffect(() => {
3042
+ document.onkeydown = e => {
2721
3043
  if (e.key === 'Escape') {
2722
3044
  onClose();
2723
3045
  }
@@ -2727,7 +3049,7 @@ var Drawer = function (_a) {
2727
3049
  };
2728
3050
  }, []);
2729
3051
  return (React.createElement(React.Fragment, null,
2730
- React.createElement(Container$2, __assign({}, accessibleProps, { "$position": position, "$width": width }),
3052
+ React.createElement(Container$2, Object.assign({}, accessibleProps, { "$position": position, "$width": width }),
2731
3053
  React.createElement(Header$2, null,
2732
3054
  React.createElement("div", null,
2733
3055
  title ? React.createElement(Heading, { type: 'secondary' }, title) : null,
@@ -2736,16 +3058,25 @@ var Drawer = function (_a) {
2736
3058
  React.createElement(Button, { format: 'secondary', icon: js.mdiClose, small: true }))),
2737
3059
  React.createElement(ContentWrapper$1, null, children),
2738
3060
  primaryButton || secondaryButton || tertiaryButton ? (React.createElement(ButtonBar$1, null,
2739
- tertiaryButton ? React.createElement(Button, __assign({}, tertiaryButton, { format: 'secondary' })) : null,
2740
- secondaryButton ? React.createElement(Button, __assign({}, secondaryButton, { format: 'secondary' })) : null,
2741
- primaryButton ? React.createElement(Button, __assign({}, primaryButton, { format: 'primary' })) : null)) : null),
3061
+ tertiaryButton ? React.createElement(Button, Object.assign({}, tertiaryButton, { format: 'secondary' })) : null,
3062
+ secondaryButton ? React.createElement(Button, Object.assign({}, secondaryButton, { format: 'secondary' })) : null,
3063
+ primaryButton ? React.createElement(Button, Object.assign({}, primaryButton, { format: 'primary' })) : null)) : null),
2742
3064
  scrim ? React.createElement(Scrim$1, { "$position": position, "$scrim": scrim, onClick: onClose }) : null));
2743
- };
2744
- var templateObject_1$f, templateObject_2$d, templateObject_3$b, templateObject_4$7, templateObject_5$5, templateObject_6$3;
3065
+ };
2745
3066
 
2746
- var Wrapper$b = styled.div(templateObject_1$e || (templateObject_1$e = __makeTemplateObject(["\n display: inline-block;\n position: relative;\n height: 16px;\n"], ["\n display: inline-block;\n position: relative;\n height: 16px;\n"])));
2747
- var StyledIcon$2 = styled(Icon)(templateObject_2$c || (templateObject_2$c = __makeTemplateObject(["\n width: 16px;\n height: 16px;\n padding: 0px 6px;\n color: ", ";\n cursor: pointer;\n"], ["\n width: 16px;\n height: 16px;\n padding: 0px 6px;\n color: ", ";\n cursor: pointer;\n"])), Colors.PRIMARY.Hex);
2748
- var positions = {
3067
+ const Wrapper$a = styled.div `
3068
+ display: inline-block;
3069
+ position: relative;
3070
+ height: 16px;
3071
+ `;
3072
+ const StyledIcon$2 = styled(Icon) `
3073
+ width: 16px;
3074
+ height: 16px;
3075
+ padding: 0px 6px;
3076
+ color: ${Colors.PRIMARY.Hex};
3077
+ cursor: pointer;
3078
+ `;
3079
+ const positions = {
2749
3080
  'right-top': {
2750
3081
  top: '0px',
2751
3082
  left: '28px',
@@ -2773,177 +3104,357 @@ var positions = {
2773
3104
  transform: 'translateY(-50%)',
2774
3105
  },
2775
3106
  };
2776
- var Content$1 = styled.div(function (props) { return (__assign({ position: 'absolute', borderRadius: '4px', borderWidth: '1px', borderStyle: 'solid', borderColor: Colors.PRIMARY.Hex, background: '#ffffff', boxShadow: '0px 5px 30px -10px rgba(0, 0, 0, 0.5)', width: props.$width || '240px', padding: '10px 12px', zIndex: 10 }, positions[props.$position])); });
2777
- var Tooltip = function (_a) {
2778
- var children = _a.children, _b = _a.position, position = _b === void 0 ? 'right-top' : _b, _c = _a.width, width = _c === void 0 ? '240px' : _c;
2779
- var _d = React.useState(false), show_content = _d[0], toggleContent = _d[1];
2780
- return (React.createElement(Wrapper$b, { onMouseEnter: toggleContent.bind(null, true), onMouseLeave: toggleContent.bind(null, false) },
3107
+ const Content$2 = styled.div(props => (Object.assign({ position: 'absolute', borderRadius: '4px', borderWidth: '1px', borderStyle: 'solid', borderColor: Colors.PRIMARY.Hex, background: '#ffffff', boxShadow: '0px 5px 30px -10px rgba(0, 0, 0, 0.5)', width: props.$width || '240px', padding: '10px 12px', zIndex: 10 }, positions[props.$position])));
3108
+ const Tooltip = ({ children, position = 'right-top', width = '240px' }) => {
3109
+ const [show_content, toggleContent] = React.useState(false);
3110
+ return (React.createElement(Wrapper$a, { onMouseEnter: toggleContent.bind(null, true), onMouseLeave: toggleContent.bind(null, false) },
2781
3111
  React.createElement(StyledIcon$2, { path: js.mdiInformationOutline }),
2782
- show_content ? (React.createElement(Content$1, { "$position": position, "$width": width }, children && React.createElement(Copy, { type: 'small' }, children))) : null));
2783
- };
2784
- var templateObject_1$e, templateObject_2$c;
2785
-
2786
- var Wrapper$a = styled.div(function (props) { return (__assign({ margin: '0px 0px 18px 0px' }, props.style)); });
2787
- var LabelRow = styled.div(templateObject_1$d || (templateObject_1$d = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin: 0 0 4px 0;\n box-sizing: border-box;\n"], ["\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin: 0 0 4px 0;\n box-sizing: border-box;\n"])));
2788
- var Label$2 = styled.label(templateObject_2$b || (templateObject_2$b = __makeTemplateObject(["\n font-size: ", ";\n font-weight: 500;\n line-height: 1em;\n font-family: ", ";\n color: ", ";\n display: flex;\n align-items: center;\n"], ["\n font-size: ", ";\n font-weight: 500;\n line-height: 1em;\n font-family: ", ";\n color: ", ";\n display: flex;\n align-items: center;\n"])), FontSizes.DEFAULT, FontStyles.DEFAULT, Colors.BLACK.Hex);
2789
- var Required = styled.span(templateObject_3$a || (templateObject_3$a = __makeTemplateObject(["\n color: ", ";\n margin-left: 4px;\n"], ["\n color: ", ";\n margin-left: 4px;\n"])), Colors.RED.Hex);
2790
- var Action = styled.span(templateObject_4$6 || (templateObject_4$6 = __makeTemplateObject(["\n font-size: ", ";\n font-weight: 500;\n line-height: 1em;\n font-family: ", ";\n color: ", ";\n cursor: pointer;\n"], ["\n font-size: ", ";\n font-weight: 500;\n line-height: 1em;\n font-family: ", ";\n color: ", ";\n cursor: pointer;\n"])), FontSizes.DEFAULT, FontStyles.DEFAULT, Colors.PRIMARY.Hex);
2791
- var Description = styled.div(templateObject_5$4 || (templateObject_5$4 = __makeTemplateObject(["\n font-size: ", ";\n font-weight: 400;\n line-height: 1.3em;\n font-family: ", ";\n color: ", ";\n margin: 0 0 8px 0;\n box-sizing: border-box;\n"], ["\n font-size: ", ";\n font-weight: 400;\n line-height: 1.3em;\n font-family: ", ";\n color: ", ";\n margin: 0 0 8px 0;\n box-sizing: border-box;\n"])), FontSizes.SMALL, FontStyles.DEFAULT, Colors.BLACK.Hex);
2792
- var Validation = styled.div(templateObject_6$2 || (templateObject_6$2 = __makeTemplateObject(["\n font-size: ", ";\n font-weight: 400;\n line-height: 1.3em;\n font-family: ", ";\n color: ", ";\n margin: 4px 0 0 0;\n box-sizing: border-box;\n"], ["\n font-size: ", ";\n font-weight: 400;\n line-height: 1.3em;\n font-family: ", ";\n color: ", ";\n margin: 4px 0 0 0;\n box-sizing: border-box;\n"])), FontSizes.SMALL, FontStyles.DEFAULT, Colors.RED.Hex);
2793
- var Field = function (_a) {
2794
- var action = _a.action, children = _a.children, validationText = _a.validationText, label = _a.label, description = _a.description, required = _a.required, htmlFor = _a.htmlFor, style = _a.style, tooltip = _a.tooltip, accessibleProps = __rest(_a, ["action", "children", "validationText", "label", "description", "required", "htmlFor", "style", "tooltip"]);
2795
- return (React.createElement(Wrapper$a, __assign({ style: style }, accessibleProps),
3112
+ show_content ? (React.createElement(Content$2, { "$position": position, "$width": width }, children && React.createElement(Copy, { type: 'small' }, children))) : null));
3113
+ };
3114
+
3115
+ const Wrapper$9 = styled.div(props => (Object.assign({ margin: '0px 0px 18px 0px' }, props.style)));
3116
+ const LabelRow = styled.div `
3117
+ display: flex;
3118
+ align-items: center;
3119
+ justify-content: space-between;
3120
+ margin: 0 0 4px 0;
3121
+ box-sizing: border-box;
3122
+ `;
3123
+ const Label$2 = styled.label `
3124
+ font-size: ${FontSizes.DEFAULT};
3125
+ font-weight: 500;
3126
+ line-height: 1em;
3127
+ font-family: ${FontStyles.DEFAULT};
3128
+ color: ${Colors.BLACK.Hex};
3129
+ display: flex;
3130
+ align-items: center;
3131
+ `;
3132
+ const Required = styled.span `
3133
+ color: ${Colors.RED.Hex};
3134
+ margin-left: 4px;
3135
+ `;
3136
+ const Action = styled.span `
3137
+ font-size: ${FontSizes.DEFAULT};
3138
+ font-weight: 500;
3139
+ line-height: 1em;
3140
+ font-family: ${FontStyles.DEFAULT};
3141
+ color: ${Colors.PRIMARY.Hex};
3142
+ cursor: pointer;
3143
+ `;
3144
+ const Description = styled.div `
3145
+ font-size: ${FontSizes.SMALL};
3146
+ font-weight: 400;
3147
+ line-height: 1.3em;
3148
+ font-family: ${FontStyles.DEFAULT};
3149
+ color: ${Colors.BLACK.Hex};
3150
+ margin: 0 0 8px 0;
3151
+ box-sizing: border-box;
3152
+ `;
3153
+ const Validation = styled.div `
3154
+ font-size: ${FontSizes.SMALL};
3155
+ font-weight: 400;
3156
+ line-height: 1.3em;
3157
+ font-family: ${FontStyles.DEFAULT};
3158
+ color: ${Colors.RED.Hex};
3159
+ margin: 4px 0 0 0;
3160
+ box-sizing: border-box;
3161
+ `;
3162
+ const Field = (_a) => {
3163
+ var { action, children, validationText, label, description, required, htmlFor, style, tooltip } = _a, accessibleProps = __rest(_a, ["action", "children", "validationText", "label", "description", "required", "htmlFor", "style", "tooltip"]);
3164
+ return (React.createElement(Wrapper$9, Object.assign({ style: style }, accessibleProps),
2796
3165
  React.createElement(LabelRow, null,
2797
3166
  React.createElement(Label$2, { htmlFor: htmlFor },
2798
3167
  label,
2799
3168
  required ? React.createElement(Required, null, "*") : null,
2800
- tooltip ? React.createElement(Tooltip, __assign({}, tooltip)) : null),
3169
+ tooltip ? React.createElement(Tooltip, Object.assign({}, tooltip)) : null),
2801
3170
  action ? React.createElement(Action, { onClick: action.onClick }, action.label) : null),
2802
3171
  description ? React.createElement(Description, null, description) : null,
2803
3172
  children,
2804
3173
  validationText ? React.createElement(Validation, null, validationText) : null));
2805
- };
2806
- var templateObject_1$d, templateObject_2$b, templateObject_3$a, templateObject_4$6, templateObject_5$4, templateObject_6$2;
2807
-
2808
- var Wrapper$9 = styled.div(templateObject_1$c || (templateObject_1$c = __makeTemplateObject(["\n display: flex;\n gap: 16px;\n padding: 20px;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n border-radius: 8px;\n border: 1px dashed ", ";\n background-color: ", ";\n"], ["\n display: flex;\n gap: 16px;\n padding: 20px;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n border-radius: 8px;\n border: 1px dashed ", ";\n background-color: ", ";\n"])), function (_a) {
2809
- var $isDragOver = _a.$isDragOver;
2810
- return ($isDragOver ? "".concat(Colors.PRIMARY.Hex) : '#ccc');
2811
- }, function (_a) {
2812
- var $isDragOver = _a.$isDragOver;
2813
- return $isDragOver ? "rgba(".concat(Colors.PRIMARY.Rgb, ", 0.05)") : '#ffffff';
2814
- });
2815
- var StyledIcon$1 = styled.div(templateObject_2$a || (templateObject_2$a = __makeTemplateObject(["\n width: 80px;\n height: 80px;\n cursor: pointer;\n flex-shrink: 0;\n background-color: ", ";\n border-radius: 80px;\n display: flex;\n margin: auto;\n justify-content: center;\n align-items: center;\n"], ["\n width: 80px;\n height: 80px;\n cursor: pointer;\n flex-shrink: 0;\n background-color: ", ";\n border-radius: 80px;\n display: flex;\n margin: auto;\n justify-content: center;\n align-items: center;\n"])), function (_a) {
2816
- var $isDragOver = _a.$isDragOver;
2817
- return ($isDragOver ? '#fff' : '#f5f5f5');
2818
- });
2819
- var Files = styled.div(templateObject_3$9 || (templateObject_3$9 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n gap: 10px;\n"], ["\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n gap: 10px;\n"])));
2820
- var File = styled.div(templateObject_4$5 || (templateObject_4$5 = __makeTemplateObject(["\n display: flex;\n justify-content: space-between;\n width: 300px;\n padding: 10px;\n align-items: center;\n gap: 2px;\n list-style-type: none;\n border-radius: 4px;\n border: 1px solid #ccc;\n"], ["\n display: flex;\n justify-content: space-between;\n width: 300px;\n padding: 10px;\n align-items: center;\n gap: 2px;\n list-style-type: none;\n border-radius: 4px;\n border: 1px solid #ccc;\n"])));
2821
- var CopyWrapper = styled.div(templateObject_5$3 || (templateObject_5$3 = __makeTemplateObject(["\n padding: ", ";\n margin-top: ", ";\n"], ["\n padding: ", ";\n margin-top: ", ";\n"])), function (_a) {
2822
- var $fileState = _a.$fileState;
2823
- return ($fileState ? '20px 0px' : '');
2824
- }, function (_a) {
2825
- var $fileState = _a.$fileState;
2826
- return ($fileState ? '' : '16px');
2827
- });
2828
- var IconWrapper$1 = styled.div(templateObject_6$1 || (templateObject_6$1 = __makeTemplateObject(["\n cursor: pointer;\n"], ["\n cursor: pointer;\n"])));
2829
- var ProgressBar = styled.div(templateObject_7$1 || (templateObject_7$1 = __makeTemplateObject(["\n width: 100px;\n height: 14px;\n border-radius: 4px;\n background: #f5f5f5;\n overflow-x: hidden;\n"], ["\n width: 100px;\n height: 14px;\n border-radius: 4px;\n background: #f5f5f5;\n overflow-x: hidden;\n"])));
2830
- var Progress = styled.div(templateObject_8$1 || (templateObject_8$1 = __makeTemplateObject(["\n width: ", ";\n height: 100%;\n border-radius: 4px 0px 0px 4px;\n background: ", ";\n"], ["\n width: ", ";\n height: 100%;\n border-radius: 4px 0px 0px 4px;\n background: ", ";\n"])), function (_a) {
2831
- var $width = _a.$width;
2832
- return "".concat($width, "%");
2833
- }, Colors.GREEN.Hex);
2834
- var FileUpload = function (_a) {
2835
- var acceptFiles = _a.acceptFiles, onChange = _a.onChange, onFileDelete = _a.onFileDelete, _b = _a.maxFileSize, maxFileSize = _b === void 0 ? 10 : _b, _c = _a.multiple, multiple = _c === void 0 ? false : _c, _d = _a.progress, progress = _d === void 0 ? false : _d, UploadProgress = _a.UploadProgress, accessibleProps = __rest(_a, ["acceptFiles", "onChange", "onFileDelete", "maxFileSize", "multiple", "progress", "UploadProgress"]);
2836
- var MAX_FILE_SIZE = maxFileSize * 1024 * 1024;
2837
- var _e = React.useState([]), files = _e[0], setFiles = _e[1];
2838
- var _f = React.useState(false), dragOver = _f[0], setDragOver = _f[1];
2839
- var inputField = React.useRef(null);
2840
- React.useEffect(function () {
2841
- if (UploadProgress) {
2842
- var updatedFiles = files.map(function (file, index) {
2843
- if (index === UploadProgress.index) {
2844
- return __assign(__assign({}, file), { uploadUpdate: UploadProgress.progress });
2845
- }
2846
- else {
2847
- return file;
3174
+ };
3175
+
3176
+ const Dropzone = styled.div `
3177
+ border-radius: 8px;
3178
+ border-width: 1px;
3179
+ border-style: dashed;
3180
+ border-color: ${props => (props.$dragging ? Colors.PRIMARY.Hex : '#cccccc')};
3181
+ background: ${props => (props.$dragging ? `rgba(${Colors.PRIMARY.Rgb}, 0.05)` : '#ffffff')};
3182
+ cursor: copy;
3183
+ `;
3184
+ const IconWrapper$1 = styled.div `
3185
+ width: 80px;
3186
+ height: 80px;
3187
+ border-radius: 40px;
3188
+ background: ${props => (props.$dragging ? '#ffffff' : '#f5f5f5')};
3189
+ display: flex;
3190
+ align-items: center;
3191
+ justify-content: center;
3192
+ `;
3193
+ const StyledIcon$1 = styled(Icon) `
3194
+ width: 40px !important;
3195
+ height: 40px !important;
3196
+
3197
+ > path {
3198
+ fill: ${Colors.GRAY.Hex} !important;
3199
+ }
3200
+ `;
3201
+ const ClickZone = styled.div `
3202
+ margin: 40px 20px;
3203
+ display: flex;
3204
+ flex-direction: column;
3205
+ align-items: center;
3206
+ gap: 16px;
3207
+ `;
3208
+ const Content$1 = styled.div `
3209
+ display: flex;
3210
+ flex-direction: column;
3211
+ align-items: center;
3212
+ gap: 2px;
3213
+ `;
3214
+ const Files = styled.div `
3215
+ display: flex;
3216
+ flex-direction: column;
3217
+ align-self: stretch;
3218
+ gap: 10px;
3219
+ margin: 20px;
3220
+ `;
3221
+ const File = styled.div `
3222
+ display: flex;
3223
+ padding: 10px;
3224
+ align-items: center;
3225
+ justify-content: space-between;
3226
+ gap: 10px;
3227
+ border-radius: 4px;
3228
+ border: 1px solid #cccccc;
3229
+ background: #ffffff;
3230
+ `;
3231
+ const Remove$1 = styled(Icon) `
3232
+ width: 24px;
3233
+ height: 24px;
3234
+ cursor: pointer;
3235
+
3236
+ > path {
3237
+ fill: ${Colors.RED.Hex} !important;
3238
+ }
3239
+ `;
3240
+ const FileUpload = ({ accept, onChange, onError, maxFiles = 10, maxSize = 2, message, validateFile, }) => {
3241
+ const inputRef = React.useRef(null);
3242
+ const [files, setFiles] = React.useState([]);
3243
+ const [dragging, setDragging] = React.useState(false);
3244
+ const [allowMoreFiles, setAllowMoreFiles] = React.useState(true);
3245
+ const handleDrag = (e) => {
3246
+ e.preventDefault();
3247
+ e.stopPropagation();
3248
+ if (e.type === 'dragenter' || e.type === 'dragover') {
3249
+ setDragging(true);
3250
+ }
3251
+ else if (e.type === 'dragleave') {
3252
+ setDragging(false);
3253
+ }
3254
+ };
3255
+ const handleDrop = (e) => {
3256
+ var _a, _b;
3257
+ e.preventDefault();
3258
+ e.stopPropagation();
3259
+ setDragging(true);
3260
+ if ((_a = e.dataTransfer) === null || _a === void 0 ? void 0 : _a.items) {
3261
+ const newFiles = [];
3262
+ [...e.dataTransfer.items].forEach(file => {
3263
+ if (file.kind === 'file') {
3264
+ const f = file.getAsFile();
3265
+ if (f) {
3266
+ newFiles.push(f);
3267
+ }
2848
3268
  }
2849
3269
  });
2850
- setFiles(updatedFiles);
3270
+ addFiles(newFiles);
2851
3271
  }
2852
- }, [UploadProgress]);
2853
- React.useEffect(function () {
2854
- onChange(files);
2855
- }, [files]);
2856
- var assignFiles = function (newFiles) {
2857
- var _loop_1 = function (i) {
2858
- if (newFiles[i].size < MAX_FILE_SIZE) {
2859
- setFiles(function (files) { return __spreadArray(__spreadArray([], files, true), [{ file: newFiles[i], uploadProgress: 0 }], false); });
2860
- }
2861
- };
2862
- for (var i = 0; i < newFiles.length; i++) {
2863
- _loop_1(i);
3272
+ else if ((_b = e.dataTransfer) === null || _b === void 0 ? void 0 : _b.files) {
3273
+ addFiles([...e.dataTransfer.files]);
2864
3274
  }
3275
+ setDragging(false);
2865
3276
  };
2866
- var onFileSelect = function (e) {
2867
- assignFiles(Array.from(e.target.files || []));
2868
- };
2869
- var handleDrop = function (e) {
2870
- e === null || e === void 0 ? void 0 : e.preventDefault();
2871
- assignFiles(Array.from(e.dataTransfer.files || []));
3277
+ const handleChange = (e) => {
3278
+ const input = e.target;
3279
+ if (input.files) {
3280
+ addFiles([...input.files]);
3281
+ }
2872
3282
  };
2873
- var handleDragOver = function (e) {
2874
- e === null || e === void 0 ? void 0 : e.preventDefault();
2875
- setDragOver(true);
3283
+ const addFiles = (addedFiles) => {
3284
+ const newFiles = [];
3285
+ const errors = [];
3286
+ addedFiles.forEach(file => {
3287
+ let valid = true;
3288
+ if (accept) {
3289
+ if (!accept.includes(file.type)) {
3290
+ valid = false;
3291
+ errors.push({
3292
+ file,
3293
+ message: 'File type is not permitted.',
3294
+ });
3295
+ }
3296
+ }
3297
+ if (file.size > maxSize * 1000000 || files.length + newFiles.length === maxFiles) {
3298
+ valid = false;
3299
+ errors.push({
3300
+ file,
3301
+ message: 'File size exceeds limit.',
3302
+ });
3303
+ }
3304
+ if (validateFile && !validateFile(file)) {
3305
+ valid = false;
3306
+ }
3307
+ if (valid) {
3308
+ newFiles.push(file);
3309
+ }
3310
+ });
3311
+ if (errors.length && onError) {
3312
+ onError(errors);
3313
+ }
3314
+ setFiles([...files, ...newFiles]);
2876
3315
  };
2877
- var handleDragLeave = function (e) {
2878
- e === null || e === void 0 ? void 0 : e.preventDefault();
2879
- setDragOver(false);
3316
+ const triggerFileExplorer = () => {
3317
+ if (inputRef.current) {
3318
+ inputRef.current.click();
3319
+ }
2880
3320
  };
2881
- var removeItem = function (index) {
2882
- var newArray = __spreadArray([], files, true);
2883
- newArray.splice(index, 1);
2884
- setFiles(newArray);
2885
- onFileDelete(files[index]);
3321
+ const handleRemove = (file) => {
3322
+ setFiles(files.filter(f => f !== file));
2886
3323
  };
3324
+ React.useEffect(() => {
3325
+ if (onChange) {
3326
+ onChange(files);
3327
+ }
3328
+ if (files.length < maxFiles) {
3329
+ setAllowMoreFiles(true);
3330
+ }
3331
+ else {
3332
+ setAllowMoreFiles(false);
3333
+ }
3334
+ }, [files]);
2887
3335
  return (React.createElement(React.Fragment, null,
2888
- React.createElement(Wrapper$9, __assign({ "$isDragOver": dragOver, onDragLeave: handleDragLeave, onDragOver: handleDragOver, onDrop: handleDrop }, accessibleProps),
2889
- files.length > 0 && (React.createElement(Files, null, Array.from(files).map(function (singleFile, index) {
2890
- var _a;
2891
- return (React.createElement(File, { key: index },
2892
- React.createElement(Copy, { children: (_a = singleFile.file) === null || _a === void 0 ? void 0 : _a.name, type: 'bold' }),
2893
- singleFile.uploadUpdate === 100 || !progress ? (React.createElement(IconWrapper$1, { onClick: function () { return removeItem(index); } },
2894
- React.createElement(Icon, { color: 'red', path: js.mdiMinusCircle, size: 1 }))) : (React.createElement(ProgressBar, null,
2895
- React.createElement(Progress, { "$width": (singleFile === null || singleFile === void 0 ? void 0 : singleFile.uploadUpdate) || 0, role: 'progressbar' })))));
2896
- }))),
2897
- React.createElement("div", { onClick: function () { var _a; return (_a = inputField === null || inputField === void 0 ? void 0 : inputField.current) === null || _a === void 0 ? void 0 : _a.click(); } },
2898
- !(files.length > 0) && (React.createElement(StyledIcon$1, { "$isDragOver": dragOver },
2899
- React.createElement(Icon, { color: dragOver ? "".concat(Colors.PRIMARY.Hex) : "".concat(Colors.GRAY.Hex), path: js.mdiFolderPlusOutline, size: 1.667 }))),
2900
- React.createElement("input", { accept: acceptFiles, hidden: true, multiple: multiple, onChange: onFileSelect, ref: inputField, type: 'file' }),
2901
- React.createElement(CopyWrapper, { "$fileState": files.length > 0 },
2902
- React.createElement(Copy, { align: 'center', children: 'Drag & drop files here or click to choose', type: 'bold' }),
2903
- React.createElement(Copy, { align: 'center', children: "".concat(maxFileSize, " MB max file size"), color: 'GRAY' }))))));
2904
- };
2905
- var templateObject_1$c, templateObject_2$a, templateObject_3$9, templateObject_4$5, templateObject_5$3, templateObject_6$1, templateObject_7$1, templateObject_8$1;
3336
+ React.createElement("input", { accept: accept, multiple: true, onChange: allowMoreFiles ? handleChange : undefined, ref: inputRef, style: { display: 'none' }, type: 'file' }),
3337
+ React.createElement(Dropzone, { "$dragging": dragging, onDragEnter: allowMoreFiles ? handleDrag : undefined, onDragLeave: allowMoreFiles ? handleDrag : undefined, onDragOver: allowMoreFiles ? handleDrag : undefined, onDrop: allowMoreFiles ? handleDrop : undefined },
3338
+ files.length ? (React.createElement(Files, null, files.map(file => {
3339
+ return (React.createElement(File, { key: file.name },
3340
+ React.createElement(Copy, { type: 'bold' }, file.name),
3341
+ React.createElement(Remove$1, { onClick: handleRemove.bind(null, file), path: js.mdiMinusCircle })));
3342
+ }))) : null,
3343
+ allowMoreFiles ? (React.createElement(ClickZone, { onClick: triggerFileExplorer },
3344
+ files.length ? null : (React.createElement(IconWrapper$1, { "$dragging": dragging },
3345
+ React.createElement(StyledIcon$1, { path: js.mdiFolderPlusOutline }))),
3346
+ React.createElement(Content$1, null,
3347
+ React.createElement(Copy, { align: 'center', type: 'bold' }, "Drag & drop files here or click to select files"),
3348
+ message ? (React.createElement(Copy, { align: 'center', color: 'GRAY' }, message)) : null))) : null)));
3349
+ };
2906
3350
 
2907
- var formatAsPhone = function (number) {
2908
- var formatted_value = "".concat(number).replace(/[^0-9.]/g, '');
2909
- var size = formatted_value.length;
3351
+ const formatAsPhone = (number) => {
3352
+ let formatted_value = `${number}`.replace(/[^0-9.]/g, '');
3353
+ const size = formatted_value.length;
2910
3354
  if (size < 1) ;
2911
3355
  else if (size < 4) {
2912
- formatted_value = "(".concat(formatted_value);
3356
+ formatted_value = `(${formatted_value}`;
2913
3357
  }
2914
3358
  else if (size < 7) {
2915
- formatted_value = "(".concat(formatted_value.substring(0, 3), ") ").concat(formatted_value.substring(3, 6));
3359
+ formatted_value = `(${formatted_value.substring(0, 3)}) ${formatted_value.substring(3, 6)}`;
2916
3360
  }
2917
3361
  else {
2918
- formatted_value = "(".concat(formatted_value.substring(0, 3), ") ").concat(formatted_value.substring(3, 6), "-").concat(formatted_value.substring(6, 10));
3362
+ formatted_value = `(${formatted_value.substring(0, 3)}) ${formatted_value.substring(3, 6)}-${formatted_value.substring(6, 10)}`;
2919
3363
  }
2920
3364
  return formatted_value;
2921
3365
  };
2922
- var formatAsSsn = function (number) {
2923
- var formatted_value = "".concat(number).replace(/[^0-9.]/g, '');
2924
- var size = formatted_value.length;
3366
+ const formatAsSsn = (number) => {
3367
+ let formatted_value = `${number}`.replace(/[^0-9.]/g, '');
3368
+ const size = formatted_value.length;
2925
3369
  if (size > 3 && size < 6) {
2926
- formatted_value = "".concat(formatted_value.substring(0, 3), "-").concat(formatted_value.substring(3, 5));
3370
+ formatted_value = `${formatted_value.substring(0, 3)}-${formatted_value.substring(3, 5)}`;
2927
3371
  }
2928
3372
  else if (size > 5) {
2929
- formatted_value = "".concat(formatted_value.substring(0, 3), "-").concat(formatted_value.substring(3, 5), "-").concat(formatted_value.substring(5, 9));
3373
+ formatted_value = `${formatted_value.substring(0, 3)}-${formatted_value.substring(3, 5)}-${formatted_value.substring(5, 9)}`;
2930
3374
  }
2931
3375
  return formatted_value;
2932
3376
  };
2933
3377
 
2934
- var StyledInput = styled.input(templateObject_1$b || (templateObject_1$b = __makeTemplateObject(["\n background-color: ", ";\n border-radius: ", ";\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 1.28em;\n color: ", ";\n position: relative;\n height: auto;\n padding: 10px;\n opacity: ", ";\n box-shadow: none;\n outline: none;\n margin: 0px;\n text-indent: 0px;\n --webkit-appearance: none;\n box-sizing: border-box;\n display: block;\n width: 100%;\n &:focus {\n border-color: ", ";\n }\n"], ["\n background-color: ", ";\n border-radius: ", ";\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 1.28em;\n color: ", ";\n position: relative;\n height: auto;\n padding: 10px;\n opacity: ", ";\n box-shadow: none;\n outline: none;\n margin: 0px;\n text-indent: 0px;\n --webkit-appearance: none;\n box-sizing: border-box;\n display: block;\n width: 100%;\n &:focus {\n border-color: ", ";\n }\n"])), function (props) { return (props.$readOnly ? '#f5f5f5' : '#ffffff'); }, function (props) { return (props.$suffix ? '4px 0px 0px 4px' : '4px'); }, function (props) { return (props.$invalid && !props.$readOnly ? Colors.RED.Hex : '#cccccc'); }, FontSizes.DEFAULT, FontStyles.DEFAULT, function (props) { return (props.$invalid && !props.$readOnly ? Colors.RED.Hex : Colors.BLACK.Hex); }, function (props) { return (props.$readOnly ? 0.6 : 1); }, function (props) { return (props.$readOnly ? '#cccccc' : Colors.PRIMARY.Hex); });
2935
- var StyledSuffix = styled.div(templateObject_2$9 || (templateObject_2$9 = __makeTemplateObject(["\n box-sizing: border-box;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 10px;\n height: auto;\n background: #f5f5f5;\n border-width: 1px 1px 1px 0px;\n border-style: solid;\n border-color: #cccccc;\n border-radius: 0px 4px 4px 0px;\n font-family: ", ";\n font-style: normal;\n font-weight: 400;\n font-size: ", ";\n color: Colors.BLACK.Hex;\n"], ["\n box-sizing: border-box;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 10px;\n height: auto;\n background: #f5f5f5;\n border-width: 1px 1px 1px 0px;\n border-style: solid;\n border-color: #cccccc;\n border-radius: 0px 4px 4px 0px;\n font-family: ", ";\n font-style: normal;\n font-weight: 400;\n font-size: ", ";\n color: Colors.BLACK.Hex;\n"])), FontStyles.DEFAULT, FontSizes.DEFAULT);
2936
- var StyledWrapper = styled.div(templateObject_3$8 || (templateObject_3$8 = __makeTemplateObject(["\n display: flex;\n width: ", ";\n"], ["\n display: flex;\n width: ", ";\n"])), function (_a) {
2937
- var $style = _a.$style;
2938
- return ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto';
2939
- });
2940
- var StyledTextarea = styled.textarea(templateObject_4$4 || (templateObject_4$4 = __makeTemplateObject(["\n background-color: ", ";\n border-radius: 4px;\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 1.6em;\n color: ", ";\n position: relative;\n height: ", ";\n padding: 10px;\n opacity: ", ";\n box-shadow: none;\n outline: none;\n padding: 10px,\n margin: 0px,\n text-indent: 0px,\n --webkit-appearance: none;\n box-sizing: border-box;\n display: block;\n width: ", ";\n &:focus {\n border-color: ", ";\n }\n"], ["\n background-color: ", ";\n border-radius: 4px;\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 1.6em;\n color: ", ";\n position: relative;\n height: ", ";\n padding: 10px;\n opacity: ", ";\n box-shadow: none;\n outline: none;\n padding: 10px,\n margin: 0px,\n text-indent: 0px,\n --webkit-appearance: none;\n box-sizing: border-box;\n display: block;\n width: ", ";\n &:focus {\n border-color: ", ";\n }\n"])), function (props) { return (props.$readOnly ? '#f5f5f5' : '#ffffff'); }, function (props) { return (props.$invalid && !props.$readOnly ? Colors.RED.Hex : '#cccccc'); }, FontSizes.DEFAULT, FontStyles.DEFAULT, function (props) { return (props.$invalid && !props.$readOnly ? Colors.RED.Hex : Colors.BLACK.Hex); }, function (props) { return props.$height || '40px'; }, function (props) { return (props.$readOnly ? 0.6 : 1); }, function (_a) {
2941
- var $style = _a.$style;
2942
- return ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto';
2943
- }, function (props) { return (props.$readOnly ? '#cccccc' : Colors.PRIMARY.Hex); });
2944
- var Input$1 = function (_a) {
2945
- var format = _a.format, suffix = _a.suffix, height = _a.height, invalid = _a.invalid, max = _a.max, maxLength = _a.maxLength, min = _a.min, onBlur = _a.onBlur, onChange = _a.onChange, onKeyDown = _a.onKeyDown, placeholder = _a.placeholder, readOnly = _a.readOnly, step = _a.step, style = _a.style, _b = _a.type, type = _b === void 0 ? 'text' : _b, _c = _a.value, value = _c === void 0 ? '' : _c, accessibleProps = __rest(_a, ["format", "suffix", "height", "invalid", "max", "maxLength", "min", "onBlur", "onChange", "onKeyDown", "placeholder", "readOnly", "step", "style", "type", "value"]);
2946
- var handleInputChange = function (e) {
3378
+ const StyledInput = styled.input `
3379
+ background-color: ${props => (props.$readOnly ? '#f5f5f5' : '#ffffff')};
3380
+ border-radius: ${props => (props.$suffix ? '4px 0px 0px 4px' : '4px')};
3381
+ border-width: 1px;
3382
+ border-style: solid;
3383
+ border-color: ${props => (props.$invalid && !props.$readOnly ? Colors.RED.Hex : '#cccccc')};
3384
+ font-size: ${FontSizes.DEFAULT};
3385
+ font-weight: 400;
3386
+ font-family: ${FontStyles.DEFAULT};
3387
+ line-height: 1.28em;
3388
+ color: ${props => (props.$invalid && !props.$readOnly ? Colors.RED.Hex : Colors.BLACK.Hex)};
3389
+ position: relative;
3390
+ height: auto;
3391
+ padding: 10px;
3392
+ opacity: ${props => (props.$readOnly ? 0.6 : 1)};
3393
+ box-shadow: none;
3394
+ outline: none;
3395
+ margin: 0px;
3396
+ text-indent: 0px;
3397
+ --webkit-appearance: none;
3398
+ box-sizing: border-box;
3399
+ display: block;
3400
+ width: 100%;
3401
+ &:focus {
3402
+ border-color: ${props => (props.$readOnly ? '#cccccc' : Colors.PRIMARY.Hex)};
3403
+ }
3404
+ `;
3405
+ const StyledSuffix = styled.div `
3406
+ box-sizing: border-box;
3407
+ display: flex;
3408
+ justify-content: center;
3409
+ align-items: center;
3410
+ padding: 10px;
3411
+ height: auto;
3412
+ background: #f5f5f5;
3413
+ border-width: 1px 1px 1px 0px;
3414
+ border-style: solid;
3415
+ border-color: #cccccc;
3416
+ border-radius: 0px 4px 4px 0px;
3417
+ font-family: ${FontStyles.DEFAULT};
3418
+ font-style: normal;
3419
+ font-weight: 400;
3420
+ font-size: ${FontSizes.DEFAULT};
3421
+ color: Colors.BLACK.Hex;
3422
+ `;
3423
+ const StyledWrapper = styled.div `
3424
+ display: flex;
3425
+ width: ${({ $style }) => ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto'};
3426
+ `;
3427
+ const StyledTextarea = styled.textarea `
3428
+ background-color: ${props => (props.$readOnly ? '#f5f5f5' : '#ffffff')};
3429
+ border-radius: 4px;
3430
+ border-width: 1px;
3431
+ border-style: solid;
3432
+ border-color: ${props => (props.$invalid && !props.$readOnly ? Colors.RED.Hex : '#cccccc')};
3433
+ font-size: ${FontSizes.DEFAULT};
3434
+ font-weight: 400;
3435
+ font-family: ${FontStyles.DEFAULT};
3436
+ line-height: 1.6em;
3437
+ color: ${props => (props.$invalid && !props.$readOnly ? Colors.RED.Hex : Colors.BLACK.Hex)};
3438
+ position: relative;
3439
+ height: ${props => props.$height || '40px'};
3440
+ padding: 10px;
3441
+ opacity: ${props => (props.$readOnly ? 0.6 : 1)};
3442
+ box-shadow: none;
3443
+ outline: none;
3444
+ padding: 10px,
3445
+ margin: 0px,
3446
+ text-indent: 0px,
3447
+ --webkit-appearance: none;
3448
+ box-sizing: border-box;
3449
+ display: block;
3450
+ width: ${({ $style }) => ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto'};
3451
+ &:focus {
3452
+ border-color: ${props => (props.$readOnly ? '#cccccc' : Colors.PRIMARY.Hex)};
3453
+ }
3454
+ `;
3455
+ const Input$1 = (_a) => {
3456
+ var { format, suffix, height, invalid, max, maxLength, min, onBlur, onChange, onKeyDown, placeholder, readOnly, step, style, type = 'text', value = '' } = _a, accessibleProps = __rest(_a, ["format", "suffix", "height", "invalid", "max", "maxLength", "min", "onBlur", "onChange", "onKeyDown", "placeholder", "readOnly", "step", "style", "type", "value"]);
3457
+ const handleInputChange = (e) => {
2947
3458
  if (format === 'currency' || format === 'currency_decimal') {
2948
3459
  e.target.value = e.target.value.replace(/[^0-9.]/g, '');
2949
3460
  }
@@ -2957,44 +3468,55 @@ var Input$1 = function (_a) {
2957
3468
  e.target.value = e.target.value.toLowerCase();
2958
3469
  }
2959
3470
  if (type === 'number' && max && parseInt(e.target.value, 10) > parseInt(max, 10)) {
2960
- e.target.value = "".concat(max);
3471
+ e.target.value = `${max}`;
2961
3472
  }
2962
3473
  if (!readOnly && onChange)
2963
3474
  onChange(e);
2964
3475
  };
2965
- var handleTextareaChange = function (e) {
3476
+ const handleTextareaChange = (e) => {
2966
3477
  if (!readOnly && onChange)
2967
3478
  onChange(e);
2968
3479
  };
2969
- var formatted_value = value;
3480
+ let formatted_value = value;
2970
3481
  if (format === 'phone') {
2971
3482
  formatted_value = formatAsPhone(value);
2972
3483
  }
2973
3484
  if (format === 'currency') {
2974
- if ("".concat(value).length) {
3485
+ if (`${value}`.length) {
2975
3486
  formatted_value = Numeral(value).format('$0,0');
2976
3487
  }
2977
3488
  }
2978
3489
  if (format === 'currency_decimal') {
2979
- formatted_value = "$".concat(formatted_value);
3490
+ formatted_value = `$${formatted_value}`;
2980
3491
  }
2981
3492
  if (format === 'ssn' && type !== 'password') {
2982
3493
  formatted_value = formatAsSsn(value);
2983
3494
  }
2984
- return type === 'textarea' ? (React.createElement(StyledTextarea, __assign({ "$height": height, "$invalid": invalid, "$readOnly": readOnly, "$style": style, maxLength: maxLength, onBlur: onBlur, onChange: handleTextareaChange, placeholder: placeholder, value: value }, accessibleProps))) : (React.createElement(StyledWrapper, { "$style": style },
2985
- React.createElement(StyledInput, __assign({ "$invalid": invalid, "$readOnly": readOnly, "$suffix": suffix, max: max, maxLength: maxLength, min: min, onBlur: onBlur, onChange: handleInputChange, onKeyDown: onKeyDown, placeholder: placeholder, step: step, type: type, value: formatted_value }, accessibleProps)),
3495
+ return type === 'textarea' ? (React.createElement(StyledTextarea, Object.assign({ "$height": height, "$invalid": invalid, "$readOnly": readOnly, "$style": style, maxLength: maxLength, onBlur: onBlur, onChange: handleTextareaChange, placeholder: placeholder, value: value }, accessibleProps))) : (React.createElement(StyledWrapper, { "$style": style },
3496
+ React.createElement(StyledInput, Object.assign({ "$invalid": invalid, "$readOnly": readOnly, "$suffix": suffix, max: max, maxLength: maxLength, min: min, onBlur: onBlur, onChange: handleInputChange, onKeyDown: onKeyDown, placeholder: placeholder, step: step, type: type, value: formatted_value }, accessibleProps)),
2986
3497
  suffix && React.createElement(StyledSuffix, null, suffix)));
2987
- };
2988
- var templateObject_1$b, templateObject_2$9, templateObject_3$8, templateObject_4$4;
3498
+ };
2989
3499
 
2990
- var Wrapper$8 = styled.a(templateObject_1$a || (templateObject_1$a = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n letter-spacing: ", ";\n font-weight: 500;\n font-style: normal;\n text-decoration: 'none';\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n margin: 0px;\n padding: 0px;\n box-sizing: border-box;\n cursor: pointer;\n"], ["\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n letter-spacing: ", ";\n font-weight: 500;\n font-style: normal;\n text-decoration: 'none';\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n margin: 0px;\n padding: 0px;\n box-sizing: border-box;\n cursor: pointer;\n"])), Colors.PRIMARY.Hex, function (props) { return (props.$small ? FontSizes.SMALL : FontSizes.DEFAULT); }, function (props) { return (props.$small ? '1.5em' : '1.6em'); }, function (props) { return (props.$small ? '1px' : '0px'); });
2991
- var Link = function (_a) {
2992
- var children = _a.children, onClick = _a.onClick, small = _a.small, accessibleProps = __rest(_a, ["children", "onClick", "small"]);
2993
- return (React.createElement(Wrapper$8, __assign({ "$small": small, onClick: onClick }, accessibleProps), children));
2994
- };
2995
- var templateObject_1$a;
3500
+ const Wrapper$8 = styled.a `
3501
+ color: ${Colors.PRIMARY.Hex};
3502
+ font-size: ${props => (props.$small ? FontSizes.SMALL : FontSizes.DEFAULT)};
3503
+ line-height: ${props => (props.$small ? '1.5em' : '1.6em')};
3504
+ letter-spacing: ${props => (props.$small ? '1px' : '0px')};
3505
+ font-weight: 500;
3506
+ font-style: normal;
3507
+ text-decoration: 'none';
3508
+ font-family: 'Roboto', Helvetica, Arial, sans-serif;
3509
+ margin: 0px;
3510
+ padding: 0px;
3511
+ box-sizing: border-box;
3512
+ cursor: pointer;
3513
+ `;
3514
+ const Link = (_a) => {
3515
+ var { children, onClick, small } = _a, accessibleProps = __rest(_a, ["children", "onClick", "small"]);
3516
+ return (React.createElement(Wrapper$8, Object.assign({ "$small": small, onClick: onClick }, accessibleProps), children));
3517
+ };
2996
3518
 
2997
- var colorMapping = {
3519
+ const colorMapping = {
2998
3520
  black: {
2999
3521
  fill_1: '#000000',
3000
3522
  fill_2: '#000000',
@@ -3016,15 +3538,15 @@ var colorMapping = {
3016
3538
  fill_3: '#E82425',
3017
3539
  },
3018
3540
  };
3019
- var Logo = function (_a) {
3020
- var _b = _a.type, type = _b === void 0 ? 'standard_full' : _b, _c = _a.height, height = _c === void 0 ? '50px' : _c, accessibleProps = __rest(_a, ["type", "height"]);
3021
- var type_parts = type.split('_');
3541
+ const Logo = (_a) => {
3542
+ var { type = 'standard_full', height = '50px' } = _a, accessibleProps = __rest(_a, ["type", "height"]);
3543
+ const type_parts = type.split('_');
3022
3544
  switch (type_parts[0]) {
3023
3545
  case 'mark':
3024
- return (React.createElement("svg", __assign({ fill: 'none', height: height, viewBox: '0 0 58 51', width: '100%', xmlns: 'http://www.w3.org/2000/svg' }, accessibleProps),
3546
+ return (React.createElement("svg", Object.assign({ fill: 'none', height: height, viewBox: '0 0 58 51', width: '100%', xmlns: 'http://www.w3.org/2000/svg' }, accessibleProps),
3025
3547
  React.createElement("path", { d: 'M43.9348 -1.14441e-05H13.3724L0 25.2376L7.27148 38.0136L14.1215 50.0487H43.1856L57.3077 25.2376L43.9348 -1.14441e-05ZM38.206 9.49903L46.459 25.0743L37.6507 40.5497H19.6567L15.5417 33.3199L10.8487 25.0743L19.1013 9.49903H38.206Z', fill: type_parts[1] })));
3026
3548
  default:
3027
- return (React.createElement("svg", __assign({ fill: 'none', height: height, preserveAspectRatio: 'xMidYMid meet', viewBox: '0 0 236 50', width: '100%', xmlns: 'http://www.w3.org/2000/svg' }, accessibleProps),
3549
+ return (React.createElement("svg", Object.assign({ fill: 'none', height: height, preserveAspectRatio: 'xMidYMid meet', viewBox: '0 0 236 50', width: '100%', xmlns: 'http://www.w3.org/2000/svg' }, accessibleProps),
3028
3550
  React.createElement("path", { d: 'M230.794 29.59H219.306L214.279 39.0907L217.012 43.9001L219.587 48.4308H230.512L235.821 39.0907L230.794 29.59V29.59ZM228.641 33.1659L231.743 39.0292L228.432 44.8549H221.668L220.121 42.1332L218.356 39.0292L221.459 33.1659H228.641Z', fill: colorMapping[type_parts[1]].fill_3 }),
3029
3551
  React.createElement("path", { d: 'M211.662 42.6033L199.206 42.6319C196.339 42.6319 193.862 41.6095 191.846 39.5923C189.828 37.5755 188.805 35.0985 188.805 32.2321C188.805 29.3656 189.828 26.8886 191.846 24.8718C193.848 22.8332 196.325 21.7975 199.206 21.7975C202.072 21.7975 204.549 22.8199 206.566 24.8374C207.613 25.8847 208.391 27.093 208.944 28.5312L209.253 29.3327H197.87L196.325 32.2579L197.921 35.0969H211.458L215.015 28.6192C214.296 25.5702 212.835 22.9293 210.672 20.7657C207.531 17.6257 203.674 16.0333 199.206 16.0333C194.737 16.0333 190.88 17.6257 187.739 20.7657C184.555 23.9501 183.007 27.7011 183.007 32.2321C183.007 36.7001 184.599 40.5577 187.739 43.6981C190.88 46.8384 194.737 48.4308 199.206 48.4308H210.095L214.745 48.3297L211.662 42.6033', fill: colorMapping[type_parts[1]].fill_1 }),
3030
3552
  React.createElement("path", { d: 'M160.945 19.133L158.826 20.8384C155.734 23.9359 154.141 27.8058 154.141 32.2967L154.141 47.7903L156.985 49.407L159.939 47.8778L159.94 32.2967C159.94 29.6632 160.778 27.3706 162.432 25.4846C162.615 25.2739 162.811 25.0666 163.018 24.8639C163.074 24.8155 164.138 24.0061 164.811 23.5592C166.321 22.5576 168.076 21.9876 170.024 21.8632L170.166 21.8621C172.923 21.8621 175.32 22.7325 177.301 24.4494L180.146 23.0088L180.246 19.3426C177.44 17.1664 174.132 16.0633 170.408 16.0633C166.909 16.0633 163.725 17.0962 160.945 19.133', fill: colorMapping[type_parts[1]].fill_1 }),
@@ -3036,21 +3558,111 @@ var Logo = function (_a) {
3036
3558
  }
3037
3559
  };
3038
3560
 
3039
- var Wrapper$7 = styled.div(templateObject_1$9 || (templateObject_1$9 = __makeTemplateObject(["\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 9999;\n background: rgba(0, 0, 0, 0.8);\n display: flex;\n align-items: center;\n justify-content: center;\n"], ["\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 9999;\n background: rgba(0, 0, 0, 0.8);\n display: flex;\n align-items: center;\n justify-content: center;\n"])));
3040
- var Container$1 = styled.dialog(templateObject_2$8 || (templateObject_2$8 = __makeTemplateObject(["\n max-width: ", ";\n width: auto;\n border-radius: 8px;\n overflow: hidden;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n outline: none;\n border: none;\n position: relative;\n padding: 0px;\n box-sizing: border-box;\n"], ["\n max-width: ", ";\n width: auto;\n border-radius: 8px;\n overflow: hidden;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n outline: none;\n border: none;\n position: relative;\n padding: 0px;\n box-sizing: border-box;\n"])), function (props) { return props.$maxWidth || '90vw'; });
3041
- var Header$1 = styled.div(templateObject_3$7 || (templateObject_3$7 = __makeTemplateObject(["\n position: sticky;\n top: 0;\n padding: 20px;\n border-bottom: 1px solid #e7e6e6;\n display: flex;\n align-items: center;\n background: #ffffff;\n box-sizing: border-box;\n"], ["\n position: sticky;\n top: 0;\n padding: 20px;\n border-bottom: 1px solid #e7e6e6;\n display: flex;\n align-items: center;\n background: #ffffff;\n box-sizing: border-box;\n"])));
3042
- var Close = styled.div(templateObject_4$3 || (templateObject_4$3 = __makeTemplateObject(["\n margin-left: auto;\n display: flex;\n align-items: center;\n padding-left: 20px;\n cursor: pointer;\n"], ["\n margin-left: auto;\n display: flex;\n align-items: center;\n padding-left: 20px;\n cursor: pointer;\n"])));
3043
- var CloseMsg = styled.span(templateObject_5$2 || (templateObject_5$2 = __makeTemplateObject(["\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 1em;\n color: ", ";\n"], ["\n font-size: ", ";\n font-weight: 400;\n font-family: ", ";\n line-height: 1em;\n color: ", ";\n"])), FontSizes.SMALL, FontStyles.DEFAULT, Colors.MEDIUM_GRAY.Hex);
3044
- var Steps = styled.div(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n padding: 20px;\n border-bottom: 1px solid #e7e6e6;\n background: #f5f5f5;\n display: flex;\n gap: 30px;\n align-items: center;\n"], ["\n padding: 20px;\n border-bottom: 1px solid #e7e6e6;\n background: #f5f5f5;\n display: flex;\n gap: 30px;\n align-items: center;\n"])));
3045
- var Step = styled.div(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n gap: 8px;\n"], ["\n display: flex;\n align-items: center;\n gap: 8px;\n"])));
3046
- var StepIndicator = styled.div(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n width: 30px;\n height: 30px;\n border-radius: 15px;\n background: ", ";\n color: ", ";\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n font-size: 14px;\n font-weight: 500;\n line-height: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n"], ["\n width: 30px;\n height: 30px;\n border-radius: 15px;\n background: ", ";\n color: ", ";\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n font-size: 14px;\n font-weight: 500;\n line-height: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n"])), function (props) { return (props.$active ? Colors.PRIMARY.Hex : Colors.LIGHT_GRAY.Hex); }, function (props) { return (props.$active ? '#fff' : Colors.MEDIUM_GRAY.Hex); });
3047
- var StepLabel = styled.div(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n color: #000;\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n font-size: 14px;\n font-weight: 500;\n line-height: 1;\n"], ["\n color: #000;\n font-family: 'Roboto', Helvetica, Arial, sans-serif;\n font-size: 14px;\n font-weight: 500;\n line-height: 1;\n"])));
3048
- var ContentWrapper = styled.div(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n overflow-x: hidden;\n overflow-y: auto;\n background: #ffffff;\n max-height: calc(100vh - 260px);\n box-sizing: border-box;\n"], ["\n overflow-x: hidden;\n overflow-y: auto;\n background: #ffffff;\n max-height: calc(100vh - 260px);\n box-sizing: border-box;\n"])));
3049
- var ButtonBar = styled.div(templateObject_11 || (templateObject_11 = __makeTemplateObject(["\n position: sticky;\n bottom: 0;\n background: #ffffff;\n padding: 20px;\n border-top: 1px solid #e7e6e6;\n display: flex;\n align-items: center;\n justify-self: flex-end;\n box-sizing: border-box;\n"], ["\n position: sticky;\n bottom: 0;\n background: #ffffff;\n padding: 20px;\n border-top: 1px solid #e7e6e6;\n display: flex;\n align-items: center;\n justify-self: flex-end;\n box-sizing: border-box;\n"])));
3050
- var Modal = function (_a) {
3051
- var children = _a.children, title = _a.title, onClose = _a.onClose, maxWidth = _a.maxWidth, steps = _a.steps, primaryButton = _a.primaryButton, secondaryButton = _a.secondaryButton, tertiaryButton = _a.tertiaryButton, accessibleProps = __rest(_a, ["children", "title", "onClose", "maxWidth", "steps", "primaryButton", "secondaryButton", "tertiaryButton"]);
3052
- React.useEffect(function () {
3053
- document.onkeydown = function (e) {
3561
+ const Wrapper$7 = styled.div `
3562
+ position: fixed;
3563
+ top: 0;
3564
+ right: 0;
3565
+ bottom: 0;
3566
+ left: 0;
3567
+ z-index: 9999;
3568
+ background: rgba(0, 0, 0, 0.8);
3569
+ display: flex;
3570
+ align-items: center;
3571
+ justify-content: center;
3572
+ `;
3573
+ const Container$1 = styled.dialog `
3574
+ max-width: ${props => props.$maxWidth || '90vw'};
3575
+ width: auto;
3576
+ border-radius: 8px;
3577
+ overflow: hidden;
3578
+ box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);
3579
+ outline: none;
3580
+ border: none;
3581
+ position: relative;
3582
+ padding: 0px;
3583
+ box-sizing: border-box;
3584
+ `;
3585
+ const Header$1 = styled.div `
3586
+ position: sticky;
3587
+ top: 0;
3588
+ padding: 20px;
3589
+ border-bottom: 1px solid #e7e6e6;
3590
+ display: flex;
3591
+ align-items: center;
3592
+ background: #ffffff;
3593
+ box-sizing: border-box;
3594
+ `;
3595
+ const Close = styled.div `
3596
+ margin-left: auto;
3597
+ display: flex;
3598
+ align-items: center;
3599
+ padding-left: 20px;
3600
+ cursor: pointer;
3601
+ `;
3602
+ const CloseMsg = styled.span `
3603
+ font-size: ${FontSizes.SMALL};
3604
+ font-weight: 400;
3605
+ font-family: ${FontStyles.DEFAULT};
3606
+ line-height: 1em;
3607
+ color: ${Colors.MEDIUM_GRAY.Hex};
3608
+ `;
3609
+ const Steps = styled.div `
3610
+ padding: 20px;
3611
+ border-bottom: 1px solid #e7e6e6;
3612
+ background: #f5f5f5;
3613
+ display: flex;
3614
+ gap: 30px;
3615
+ align-items: center;
3616
+ `;
3617
+ const Step = styled.div `
3618
+ display: flex;
3619
+ align-items: center;
3620
+ gap: 8px;
3621
+ `;
3622
+ const StepIndicator = styled.div `
3623
+ width: 30px;
3624
+ height: 30px;
3625
+ border-radius: 15px;
3626
+ background: ${props => (props.$active ? Colors.PRIMARY.Hex : Colors.LIGHT_GRAY.Hex)};
3627
+ color: ${props => (props.$active ? '#fff' : Colors.MEDIUM_GRAY.Hex)};
3628
+ font-family: 'Roboto', Helvetica, Arial, sans-serif;
3629
+ font-size: 14px;
3630
+ font-weight: 500;
3631
+ line-height: 1;
3632
+ display: flex;
3633
+ align-items: center;
3634
+ justify-content: center;
3635
+ flex-shrink: 0;
3636
+ `;
3637
+ const StepLabel = styled.div `
3638
+ color: #000;
3639
+ font-family: 'Roboto', Helvetica, Arial, sans-serif;
3640
+ font-size: 14px;
3641
+ font-weight: 500;
3642
+ line-height: 1;
3643
+ `;
3644
+ const ContentWrapper = styled.div `
3645
+ overflow-x: hidden;
3646
+ overflow-y: auto;
3647
+ background: #ffffff;
3648
+ max-height: calc(100vh - 260px);
3649
+ box-sizing: border-box;
3650
+ `;
3651
+ const ButtonBar = styled.div `
3652
+ position: sticky;
3653
+ bottom: 0;
3654
+ background: #ffffff;
3655
+ padding: 20px;
3656
+ border-top: 1px solid #e7e6e6;
3657
+ display: flex;
3658
+ align-items: center;
3659
+ justify-self: flex-end;
3660
+ box-sizing: border-box;
3661
+ `;
3662
+ const Modal = (_a) => {
3663
+ var { children, title, onClose, maxWidth, steps, primaryButton, secondaryButton, tertiaryButton } = _a, accessibleProps = __rest(_a, ["children", "title", "onClose", "maxWidth", "steps", "primaryButton", "secondaryButton", "tertiaryButton"]);
3664
+ React.useEffect(() => {
3665
+ document.onkeydown = e => {
3054
3666
  if (e.key === 'Escape') {
3055
3667
  onClose();
3056
3668
  }
@@ -3060,49 +3672,44 @@ var Modal = function (_a) {
3060
3672
  };
3061
3673
  }, []);
3062
3674
  return (React.createElement(Wrapper$7, null,
3063
- React.createElement(Container$1, __assign({ "$maxWidth": maxWidth, open: true }, accessibleProps),
3675
+ React.createElement(Container$1, Object.assign({ "$maxWidth": maxWidth, open: true }, accessibleProps),
3064
3676
  React.createElement(Header$1, null,
3065
3677
  title ? React.createElement(Heading, { type: 'secondary' }, title) : null,
3066
3678
  React.createElement(Close, { onClick: onClose },
3067
3679
  React.createElement(CloseMsg, null, "(Esc)"),
3068
3680
  React.createElement(Icon, { color: Colors.BLACK.Hex, path: js.mdiClose, size: '24px' }))),
3069
- steps ? (React.createElement(Steps, null, steps.map(function (step, i) {
3681
+ steps ? (React.createElement(Steps, null, steps.map((step, i) => {
3070
3682
  return (React.createElement(Step, { key: i },
3071
3683
  step.complete ? (React.createElement(Icon, { color: Colors.PRIMARY.Hex, path: js.mdiCheckboxMarkedCircleOutline, size: '32px' })) : (React.createElement(StepIndicator, { "$active": step.active }, i + 1)),
3072
3684
  React.createElement(StepLabel, null, step.label)));
3073
3685
  }))) : null,
3074
3686
  React.createElement(ContentWrapper, null, children),
3075
3687
  primaryButton || secondaryButton || tertiaryButton ? (React.createElement(ButtonBar, null,
3076
- tertiaryButton ? React.createElement(Button, __assign({}, tertiaryButton, { format: 'secondary' })) : null,
3688
+ tertiaryButton ? React.createElement(Button, Object.assign({}, tertiaryButton, { format: 'secondary' })) : null,
3077
3689
  primaryButton || secondaryButton ? (React.createElement("div", { style: {
3078
3690
  marginLeft: 'auto',
3079
3691
  paddingLeft: 40,
3080
3692
  display: 'flex',
3081
3693
  alignItems: 'center',
3082
3694
  } },
3083
- secondaryButton ? React.createElement(Button, __assign({}, secondaryButton, { format: 'secondary' })) : null,
3084
- primaryButton ? (React.createElement(Button, __assign({}, primaryButton, { format: 'primary', margin: '0px 0px 0px 10px' }))) : null)) : null)) : null)));
3085
- };
3086
- var templateObject_1$9, templateObject_2$8, templateObject_3$7, templateObject_4$3, templateObject_5$2, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10, templateObject_11;
3087
-
3088
- var Wrapper$6 = styled.div(templateObject_1$8 || (templateObject_1$8 = __makeTemplateObject(["\n background: #fff;\n border-radius: 8px;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n display: flex;\n flex-direction: column;\n gap: 4px;\n max-height: ", ";\n padding: 10px;\n width: 200px;\n"], ["\n background: #fff;\n border-radius: 8px;\n box-shadow: 0px 10px 30px -15px rgba(0, 0, 0, 0.2);\n display: flex;\n flex-direction: column;\n gap: 4px;\n max-height: ", ";\n padding: 10px;\n width: 200px;\n"])), function (props) { return props.$maxHeight || '312px'; });
3089
- var MenuItem = styled.div(templateObject_2$7 || (templateObject_2$7 = __makeTemplateObject(["\n align-items: center;\n border-radius: 8px;\n border: 1px solid transparent;\n display: flex;\n gap: 8px;\n height: 38px;\n padding: 8px;\n &:hover {\n background: rgba(1, 147, 215, 0.1);\n cursor: pointer;\n\n svg,\n path {\n fill: ", " !important;\n }\n }\n"], ["\n align-items: center;\n border-radius: 8px;\n border: 1px solid transparent;\n display: flex;\n gap: 8px;\n height: 38px;\n padding: 8px;\n &:hover {\n background: rgba(1, 147, 215, 0.1);\n cursor: pointer;\n\n svg,\n path {\n fill: ", " !important;\n }\n }\n"])), Colors.PRIMARY.Hex);
3090
- var Title = styled.span(templateObject_3$6 || (templateObject_3$6 = __makeTemplateObject(["\n font-family: Roboto;\n font-size: 14px;\n font-weight: 400;\n height: auto;\n letter-spacing: 0px;\n line-height: 22px;\n text-align: left;\n"], ["\n font-family: Roboto;\n font-size: 14px;\n font-weight: 400;\n height: auto;\n letter-spacing: 0px;\n line-height: 22px;\n text-align: left;\n"])));
3091
- var MoreMenu = function (_a) {
3092
- var maxHeight = _a.maxHeight, _b = _a.menuItems, menuItems = _b === void 0 ? [] : _b, accessibleProps = __rest(_a, ["maxHeight", "menuItems"]);
3093
- return (React.createElement(Wrapper$6, __assign({ "$maxHeight": maxHeight }, accessibleProps), menuItems.map(function (item) {
3094
- return (React.createElement(MenuItem, { onClick: item.onClick },
3095
- item.icon ? (React.createElement(Icon, { color: Colors.MEDIUM_GRAY.Hex, path: item.icon, size: '20px' })) : null,
3096
- React.createElement(Title, null, item.label)));
3097
- })));
3098
- };
3099
- var templateObject_1$8, templateObject_2$7, templateObject_3$6;
3695
+ secondaryButton ? React.createElement(Button, Object.assign({}, secondaryButton, { format: 'secondary' })) : null,
3696
+ primaryButton ? (React.createElement(Button, Object.assign({}, primaryButton, { format: 'primary', margin: '0px 0px 0px 10px' }))) : null)) : null)) : null)));
3697
+ };
3100
3698
 
3101
- var Wrapper$5 = styled.div(templateObject_1$7 || (templateObject_1$7 = __makeTemplateObject(["\n position: relative;\n width: ", ";\n"], ["\n position: relative;\n width: ", ";\n"])), function (_a) {
3102
- var $style = _a.$style;
3103
- return ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto';
3104
- });
3105
- var Trigger = styled.div(templateObject_2$6 || (templateObject_2$6 = __makeTemplateObject(["\n box-sizing: border-box;\n border-radius: ", ";\n height: 40px;\n padding: 0 10px;\n position: relative;\n cursor: pointer;\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n background-color: ", ";\n background-image: none;\n display: flex;\n width: 100%;\n align-items: center;\n justify-content: space-between;\n z-index: 1;\n"], ["\n box-sizing: border-box;\n border-radius: ", ";\n height: 40px;\n padding: 0 10px;\n position: relative;\n cursor: pointer;\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n background-color: ", ";\n background-image: none;\n display: flex;\n width: 100%;\n align-items: center;\n justify-content: space-between;\n z-index: 1;\n"])), function (props) { return (props.$showOptions ? '4px 4px 0px 0px' : '4px'); }, function (props) {
3699
+ const Wrapper$6 = styled.div `
3700
+ position: relative;
3701
+ width: ${({ $style }) => ($style === null || $style === void 0 ? void 0 : $style.width) || 'auto'};
3702
+ `;
3703
+ const Trigger = styled.div `
3704
+ box-sizing: border-box;
3705
+ border-radius: ${props => (props.$showOptions ? '4px 4px 0px 0px' : '4px')};
3706
+ height: 40px;
3707
+ padding: 0 10px;
3708
+ position: relative;
3709
+ cursor: pointer;
3710
+ border-width: 1px;
3711
+ border-style: solid;
3712
+ border-color: ${props => {
3106
3713
  if (props.$invalid) {
3107
3714
  return Colors.RED.Hex;
3108
3715
  }
@@ -3112,162 +3719,415 @@ var Trigger = styled.div(templateObject_2$6 || (templateObject_2$6 = __makeTempl
3112
3719
  else {
3113
3720
  return '#cccccc';
3114
3721
  }
3115
- }, function (props) { return (props.$readOnly ? '#f5f5f5' : '#ffffff'); });
3116
- var Value = styled.div(templateObject_3$5 || (templateObject_3$5 = __makeTemplateObject(["\n color: ", ";\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n line-height: 2.9em;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n width: 100%;\n"], ["\n color: ", ";\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n line-height: 2.9em;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n width: 100%;\n"])), Colors.BLACK.Hex, FontStyles.DEFAULT, FontSizes.DEFAULT);
3117
- var Options = styled.div(templateObject_4$2 || (templateObject_4$2 = __makeTemplateObject(["\n background: #fff;\n box-shadow: 0px 5px 30px -15px rgba(0, 0, 0, 0.2);\n border-color: ", ";\n border-radius: 0px 0px 4px 4px;\n border-style: solid;\n border-top: none;\n border-width: 1px;\n left: 0;\n position: absolute;\n right: 0;\n z-index: 10;\n max-height: 220px;\n overflow: auto;\n"], ["\n background: #fff;\n box-shadow: 0px 5px 30px -15px rgba(0, 0, 0, 0.2);\n border-color: ", ";\n border-radius: 0px 0px 4px 4px;\n border-style: solid;\n border-top: none;\n border-width: 1px;\n left: 0;\n position: absolute;\n right: 0;\n z-index: 10;\n max-height: 220px;\n overflow: auto;\n"])), Colors.PRIMARY.Hex);
3118
- var Scrim = styled.div(templateObject_5$1 || (templateObject_5$1 = __makeTemplateObject(["\n bottom: 0;\n left: 0;\n position: fixed;\n right: 0;\n top: 0;\n z-index: 9;\n"], ["\n bottom: 0;\n left: 0;\n position: fixed;\n right: 0;\n top: 0;\n z-index: 9;\n"])));
3119
- var MultiSelect = function (_a) {
3120
- var readOnly = _a.readOnly, _b = _a.displayCount, displayCount = _b === void 0 ? 3 : _b, invalid = _a.invalid, onChange = _a.onChange, _c = _a.options, options = _c === void 0 ? [] : _c, _d = _a.selected, selected = _d === void 0 ? [] : _d, showSelectAll = _a.showSelectAll, style = _a.style, accessibleProps = __rest(_a, ["readOnly", "displayCount", "invalid", "onChange", "options", "selected", "showSelectAll", "style"]);
3121
- var _e = React.useState(false), showOptions = _e[0], setShowOptions = _e[1];
3122
- var selected_options = options.filter(function (o) { return selected.includes(o.value); });
3123
- return (React.createElement(Wrapper$5, { "$style": style },
3124
- React.createElement(Trigger, __assign({ "$invalid": invalid, "$readOnly": readOnly, "$showOptions": showOptions, onClick: readOnly ? undefined : setShowOptions.bind(null, !showOptions) }, accessibleProps),
3722
+ }};
3723
+ background-color: ${props => (props.$readOnly ? '#f5f5f5' : '#ffffff')};
3724
+ background-image: none;
3725
+ display: flex;
3726
+ width: 100%;
3727
+ align-items: center;
3728
+ justify-content: space-between;
3729
+ z-index: 1;
3730
+ `;
3731
+ const Value = styled.div `
3732
+ color: ${Colors.BLACK.Hex};
3733
+ font-family: ${FontStyles.DEFAULT};
3734
+ font-size: ${FontSizes.DEFAULT};
3735
+ font-weight: 400;
3736
+ line-height: 2.9em;
3737
+ overflow: hidden;
3738
+ text-overflow: ellipsis;
3739
+ white-space: nowrap;
3740
+ width: 100%;
3741
+ `;
3742
+ const Options = styled.div `
3743
+ background: #fff;
3744
+ box-shadow: 0px 5px 30px -15px rgba(0, 0, 0, 0.2);
3745
+ border-color: ${Colors.PRIMARY.Hex};
3746
+ border-radius: 0px 0px 4px 4px;
3747
+ border-style: solid;
3748
+ border-top: none;
3749
+ border-width: 1px;
3750
+ left: 0;
3751
+ position: absolute;
3752
+ right: 0;
3753
+ z-index: 10;
3754
+ max-height: 220px;
3755
+ overflow: auto;
3756
+ `;
3757
+ const Scrim = styled.div `
3758
+ bottom: 0;
3759
+ left: 0;
3760
+ position: fixed;
3761
+ right: 0;
3762
+ top: 0;
3763
+ z-index: 9;
3764
+ `;
3765
+ const MultiSelect = (_a) => {
3766
+ var { readOnly, displayCount = 3, invalid, onChange, options = [], selected = [], showSelectAll, style } = _a, accessibleProps = __rest(_a, ["readOnly", "displayCount", "invalid", "onChange", "options", "selected", "showSelectAll", "style"]);
3767
+ const [showOptions, setShowOptions] = React.useState(false);
3768
+ const selected_options = options.filter(o => selected.includes(o.value));
3769
+ return (React.createElement(Wrapper$6, { "$style": style },
3770
+ React.createElement(Trigger, Object.assign({ "$invalid": invalid, "$readOnly": readOnly, "$showOptions": showOptions, onClick: readOnly ? undefined : setShowOptions.bind(null, !showOptions) }, accessibleProps),
3125
3771
  React.createElement(Value, null, selected.length > 0 && selected.length <= displayCount
3126
- ? selected_options.map(function (o) { return o.label || o.value; }).join(', ')
3127
- : "".concat(selected_options.length, " Selected")),
3772
+ ? selected_options.map(o => o.label || o.value).join(', ')
3773
+ : `${selected_options.length} Selected`),
3128
3774
  React.createElement(Icon, { color: Colors.BLACK.Hex, path: showOptions ? js.mdiChevronUp : js.mdiChevronDown, size: '22px' })),
3129
3775
  showOptions ? (React.createElement(Options, null,
3130
3776
  React.createElement(Checklist, { onChange: onChange, options: options, selected: selected, showSelectAll: showSelectAll }))) : null,
3131
3777
  showOptions ? React.createElement(Scrim, { onClick: setShowOptions.bind(null, !showOptions) }) : null));
3132
- };
3133
- var templateObject_1$7, templateObject_2$6, templateObject_3$5, templateObject_4$2, templateObject_5$1;
3134
-
3135
- var Wrapper$4 = styled.nav(templateObject_1$6 || (templateObject_1$6 = __makeTemplateObject(["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n column-gap: 10px;\n"], ["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n column-gap: 10px;\n"])));
3136
- var Pagination = function (_a) {
3137
- var _b = _a.currentPage, currentPage = _b === void 0 ? 1 : _b, onClick = _a.onClick, _c = _a.pageCount, pageCount = _c === void 0 ? 0 : _c, accessibleProps = __rest(_a, ["currentPage", "onClick", "pageCount"]);
3138
- var is_first_page = currentPage === 1;
3139
- var is_last_page = currentPage === pageCount;
3140
- var handlePrevClick = function () {
3778
+ };
3779
+
3780
+ const Wrapper$5 = styled.div `
3781
+ display: flex;
3782
+ padding: 16px 30px;
3783
+ align-items: center;
3784
+ gap: 20px;
3785
+ align-self: stretch;
3786
+ border-bottom: 1px solid ${Colors.LIGHT_GRAY.Hex};
3787
+ `;
3788
+ const Info = styled.div `
3789
+ display: flex;
3790
+ flex-direction: column;
3791
+ align-items: flex-start;
3792
+ gap: 4px;
3793
+ flex: 1 0 0;
3794
+ `;
3795
+ const Breadcrumbs = styled.div `
3796
+ display: flex;
3797
+ align-items: center;
3798
+ gap: 4px;
3799
+ `;
3800
+ const Actions = styled.div `
3801
+ display: flex;
3802
+ align-items: center;
3803
+ gap: 8px;
3804
+ `;
3805
+ const PageHeader = ({ title = '', breadcrumbs, actions, buttonMenu }) => {
3806
+ const { menuItems = [], label = '', } = buttonMenu || {};
3807
+ return (React.createElement(Wrapper$5, null,
3808
+ React.createElement(Info, null,
3809
+ React.createElement(Heading, { type: 'secondary' }, title),
3810
+ breadcrumbs ? (React.createElement(Breadcrumbs, null, breadcrumbs.map((crumb, i) => {
3811
+ return (React.createElement(React.Fragment, null,
3812
+ crumb.onClick ? (React.createElement(Link, { onClick: crumb.onClick, small: true }, crumb.label)) : (React.createElement(Copy, { type: 'small' }, crumb.label)),
3813
+ i + 1 < breadcrumbs.length ? React.createElement(Icon.Icon, { path: js.mdiChevronRight, size: '14px' }) : null));
3814
+ }))) : null),
3815
+ actions ? (React.createElement(Actions, null,
3816
+ actions.map(action => {
3817
+ const { label } = action, buttonProps = __rest(action, ["label"]);
3818
+ return (React.createElement(Button, Object.assign({}, buttonProps, { small: true }), label));
3819
+ }),
3820
+ menuItems.length ? (React.createElement(ButtonMenu, { label: label, menuItems: menuItems, small: true })) : null)) : null));
3821
+ };
3822
+
3823
+ const Wrapper$4 = styled.nav `
3824
+ box-sizing: border-box;
3825
+ display: flex;
3826
+ align-items: center;
3827
+ column-gap: 10px;
3828
+ `;
3829
+ const Pagination = (_a) => {
3830
+ var { currentPage = 1, onClick, pageCount = 0 } = _a, accessibleProps = __rest(_a, ["currentPage", "onClick", "pageCount"]);
3831
+ const is_first_page = currentPage === 1;
3832
+ const is_last_page = currentPage === pageCount;
3833
+ const handlePrevClick = () => {
3141
3834
  if (!is_first_page) {
3142
3835
  onClick(currentPage - 1);
3143
3836
  }
3144
3837
  };
3145
- var handleNextClick = function () {
3838
+ const handleNextClick = () => {
3146
3839
  if (!is_last_page) {
3147
3840
  onClick(currentPage + 1);
3148
3841
  }
3149
3842
  };
3150
- var handlePageChange = function (e) {
3151
- var new_page = parseInt(e.target.value, 10);
3843
+ const handlePageChange = (e) => {
3844
+ const new_page = parseInt(e.target.value, 10);
3152
3845
  if (new_page !== currentPage) {
3153
3846
  onClick(new_page);
3154
3847
  }
3155
3848
  };
3156
- return (React.createElement(Wrapper$4, __assign({}, accessibleProps),
3849
+ return (React.createElement(Wrapper$4, Object.assign({}, accessibleProps),
3157
3850
  React.createElement(Button, { disabled: is_first_page, icon: js.mdiChevronLeft, onClick: handlePrevClick, small: true }),
3158
- React.createElement(Select, { onChange: handlePageChange, options: Array.from(Array(pageCount).keys(), function (p) { return p + 1; }).map(function (p) { return ({
3159
- label: "Page ".concat(p),
3160
- value: "".concat(p),
3161
- }); }), value: "".concat(currentPage) }),
3851
+ React.createElement(Select, { onChange: handlePageChange, options: Array.from(Array(pageCount).keys(), p => p + 1).map(p => ({
3852
+ label: `Page ${p}`,
3853
+ value: `${p}`,
3854
+ })), value: `${currentPage}` }),
3162
3855
  React.createElement(Button, { disabled: is_last_page, icon: js.mdiChevronRight, onClick: handleNextClick, small: true })));
3163
- };
3164
- var templateObject_1$6;
3165
-
3166
- var Wrapper$3 = styled.label(templateObject_1$5 || (templateObject_1$5 = __makeTemplateObject(["\n padding: 4px 0;\n cursor: ", ";\n display: flex;\n align-items: center;\n font-size: ", ";\n line-height: 1.6rm;\n box-sizing: border-box;\n"], ["\n padding: 4px 0;\n cursor: ", ";\n display: flex;\n align-items: center;\n font-size: ", ";\n line-height: 1.6rm;\n box-sizing: border-box;\n"])), function (props) { return (props.$disabled ? 'default' : 'pointer'); }, FontSizes.DEFAULT);
3167
- var Input = styled.input(templateObject_2$5 || (templateObject_2$5 = __makeTemplateObject(["\n font-size: 20px;\n margin: 0px 0px 2px 0px;\n line-height: 1.1em;\n"], ["\n font-size: 20px;\n margin: 0px 0px 2px 0px;\n line-height: 1.1em;\n"])));
3168
- var Label$1 = styled.span(templateObject_3$4 || (templateObject_3$4 = __makeTemplateObject(["\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n color: ", ";\n line-height: 1.6em;\n margin-left: 6px;\n"], ["\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n color: ", ";\n line-height: 1.6em;\n margin-left: 6px;\n"])), FontStyles.DEFAULT, FontSizes.DEFAULT, Colors.BLACK.Hex);
3169
- var Radio = function (_a) {
3170
- var children = _a.children, disabled = _a.disabled, checked = _a.checked, onChange = _a.onChange, value = _a.value, accessibleProps = __rest(_a, ["children", "disabled", "checked", "onChange", "value"]);
3171
- return (React.createElement(Wrapper$3, __assign({ "$disabled": disabled }, accessibleProps),
3856
+ };
3857
+
3858
+ const Wrapper$3 = styled.label `
3859
+ padding: 4px 0;
3860
+ cursor: ${props => (props.$disabled ? 'default' : 'pointer')};
3861
+ display: flex;
3862
+ align-items: center;
3863
+ font-size: ${FontSizes.DEFAULT};
3864
+ line-height: 1.6rm;
3865
+ box-sizing: border-box;
3866
+ `;
3867
+ const Input = styled.input `
3868
+ font-size: 20px;
3869
+ margin: 0px 0px 2px 0px;
3870
+ line-height: 1.1em;
3871
+ `;
3872
+ const Label$1 = styled.span `
3873
+ font-family: ${FontStyles.DEFAULT};
3874
+ font-size: ${FontSizes.DEFAULT};
3875
+ font-weight: 400;
3876
+ color: ${Colors.BLACK.Hex};
3877
+ line-height: 1.6em;
3878
+ margin-left: 6px;
3879
+ `;
3880
+ const Radio = (_a) => {
3881
+ var { children, disabled, checked, onChange, value } = _a, accessibleProps = __rest(_a, ["children", "disabled", "checked", "onChange", "value"]);
3882
+ return (React.createElement(Wrapper$3, Object.assign({ "$disabled": disabled }, accessibleProps),
3172
3883
  React.createElement(Input, { checked: checked, disabled: disabled, name: accessibleProps.name, onChange: disabled ? undefined : onChange, type: 'radio', value: value }),
3173
3884
  React.createElement(Label$1, null, children)));
3174
- };
3175
- var templateObject_1$5, templateObject_2$5, templateObject_3$4;
3885
+ };
3176
3886
 
3177
- var RadioList = function (_a) {
3178
- var disabled = _a.disabled, onChange = _a.onChange, options = _a.options, value = _a.value, accessibleProps = __rest(_a, ["disabled", "onChange", "options", "value"]);
3179
- return (React.createElement(React.Fragment, null, options.map(function (option) {
3180
- var label = option.label || option.value;
3181
- return (React.createElement(Radio, __assign({ checked: value === option.value, disabled: disabled, onChange: onChange, value: option.value }, accessibleProps), label));
3887
+ const RadioList = (_a) => {
3888
+ var { disabled, onChange, options, value } = _a, accessibleProps = __rest(_a, ["disabled", "onChange", "options", "value"]);
3889
+ return (React.createElement(React.Fragment, null, options.map((option) => {
3890
+ const label = option.label || option.value;
3891
+ return (React.createElement(Radio, Object.assign({ checked: value === option.value, disabled: disabled, onChange: onChange, value: option.value }, accessibleProps), label));
3182
3892
  })));
3183
3893
  };
3184
3894
 
3185
- var StyledTable = styled.table(templateObject_1$4 || (templateObject_1$4 = __makeTemplateObject(["\n width: 100%;\n margin-top: 1px;\n table-layout: ", ";\n border-collapse: collapse;\n text-indent: 0px;\n border-spacing: 0px;\n border-color: none;\n box-sizing: border-box;\n"], ["\n width: 100%;\n margin-top: 1px;\n table-layout: ", ";\n border-collapse: collapse;\n text-indent: 0px;\n border-spacing: 0px;\n border-color: none;\n box-sizing: border-box;\n"])), function (props) { return props.$tableLayout || 'auto'; });
3186
- var Header = styled.th(templateObject_2$4 || (templateObject_2$4 = __makeTemplateObject(["\n padding: 12px !important;\n text-align: left;\n font-weight: 500;\n border-bottom: 1px solid #e5e5e5;\n border-top: 1px solid #e5e5e5;\n text-transform: uppercase;\n font-size: 12px;\n font-family: ", ";\n letter-spacing: 1px;\n white-space: nowrap;\n line-height: 1;\n position: relative;\n box-sizing: border-box;\n width: ", ";\n cursor: ", ";\n color: ", ";\n"], ["\n padding: 12px !important;\n text-align: left;\n font-weight: 500;\n border-bottom: 1px solid #e5e5e5;\n border-top: 1px solid #e5e5e5;\n text-transform: uppercase;\n font-size: 12px;\n font-family: ", ";\n letter-spacing: 1px;\n white-space: nowrap;\n line-height: 1;\n position: relative;\n box-sizing: border-box;\n width: ", ";\n cursor: ", ";\n color: ", ";\n"])), FontStyles.DEFAULT, function (props) { return props.$width || 'auto'; }, function (props) { return (props.$isSortable ? 'pointer' : 'default'); }, function (props) { return (props.$isSortable ? Colors.PRIMARY.Hex : Colors.BLACK.Hex); });
3187
- var Row = styled.tr(templateObject_3$3 || (templateObject_3$3 = __makeTemplateObject(["\n cursor: ", ";\n transition: all 0.2s;\n background-color: ", ";\n box-sizing: border-box;\n &:hover {\n background-color: ", ";\n }\n"], ["\n cursor: ", ";\n transition: all 0.2s;\n background-color: ", ";\n box-sizing: border-box;\n &:hover {\n background-color: ", ";\n }\n"])), function (props) { return (props.$isClickable ? 'pointer' : 'default'); }, function (props) { return props.$bgColor; }, function (props) {
3188
- return props.$isClickable ? "rgba(".concat(Colors.PRIMARY.Rgb, ", 0.1)") : props.$bgColor;
3189
- });
3190
- var Column = styled.td(templateObject_4$1 || (templateObject_4$1 = __makeTemplateObject(["\n padding: 16px 12px !important;\n font-size: ", " !important;\n font-weight: 400 !important;\n font-family: ", ";\n border: none !important;\n word-break: break-word;\n line-height: 1.4em;\n box-sizing: border-box;\n width: ", ";\n"], ["\n padding: 16px 12px !important;\n font-size: ", " !important;\n font-weight: 400 !important;\n font-family: ", ";\n border: none !important;\n word-break: break-word;\n line-height: 1.4em;\n box-sizing: border-box;\n width: ", ";\n"])), FontSizes.DEFAULT, FontStyles.DEFAULT, function (props) { return props.$width || 'auto'; });
3191
- var IconWrapper = styled.span(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n margin-left: 2px;\n"], ["\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n margin-left: 2px;\n"])));
3192
- var Table = function (_a) {
3193
- var _b = _a.columns, columns = _b === void 0 ? [] : _b, _c = _a.data, data = _c === void 0 ? [] : _c, sortBy = _a.sortBy, sortDirection = _a.sortDirection, hideHeaders = _a.hideHeaders, onRowClick = _a.onRowClick, onSortChange = _a.onSortChange, tableLayout = _a.tableLayout, accessibleProps = __rest(_a, ["columns", "data", "sortBy", "sortDirection", "hideHeaders", "onRowClick", "onSortChange", "tableLayout"]);
3194
- return (React.createElement(StyledTable, __assign({ "$tableLayout": tableLayout }, accessibleProps),
3895
+ const StyledTable = styled.table `
3896
+ width: 100%;
3897
+ margin-top: 1px;
3898
+ table-layout: ${props => props.$tableLayout || 'auto'};
3899
+ border-collapse: collapse;
3900
+ text-indent: 0px;
3901
+ border-spacing: 0px;
3902
+ border-color: none;
3903
+ box-sizing: border-box;
3904
+ `;
3905
+ const Header = styled.th `
3906
+ padding: 12px !important;
3907
+ text-align: left;
3908
+ font-weight: 500;
3909
+ border-bottom: 1px solid #e5e5e5;
3910
+ border-top: 1px solid #e5e5e5;
3911
+ text-transform: uppercase;
3912
+ font-size: 12px;
3913
+ font-family: ${FontStyles.DEFAULT};
3914
+ letter-spacing: 1px;
3915
+ white-space: nowrap;
3916
+ line-height: 1;
3917
+ position: relative;
3918
+ box-sizing: border-box;
3919
+ width: ${props => props.$width || 'auto'};
3920
+ cursor: ${props => (props.$isSortable ? 'pointer' : 'default')};
3921
+ color: ${props => (props.$isSortable ? Colors.PRIMARY.Hex : Colors.BLACK.Hex)};
3922
+ `;
3923
+ const Row = styled.tr `
3924
+ cursor: ${props => (props.$isClickable ? 'pointer' : 'default')};
3925
+ transition: all 0.2s;
3926
+ background-color: ${props => props.$bgColor};
3927
+ box-sizing: border-box;
3928
+ &:hover {
3929
+ background-color: ${props => props.$isClickable ? `rgba(${Colors.PRIMARY.Rgb}, 0.1)` : props.$bgColor};
3930
+ }
3931
+ `;
3932
+ const Column = styled.td `
3933
+ padding: 16px 12px !important;
3934
+ font-size: ${FontSizes.DEFAULT} !important;
3935
+ font-weight: 400 !important;
3936
+ font-family: ${FontStyles.DEFAULT};
3937
+ border: none !important;
3938
+ word-break: break-word;
3939
+ line-height: 1.4em;
3940
+ box-sizing: border-box;
3941
+ width: ${props => props.$width || 'auto'};
3942
+ `;
3943
+ const IconWrapper = styled.span `
3944
+ position: absolute;
3945
+ top: 50%;
3946
+ transform: translateY(-50%);
3947
+ margin-left: 2px;
3948
+ `;
3949
+ const Table = (_a) => {
3950
+ var { columns = [], data = [], sortBy, sortDirection, hideHeaders, onRowClick, onSortChange, tableLayout } = _a, accessibleProps = __rest(_a, ["columns", "data", "sortBy", "sortDirection", "hideHeaders", "onRowClick", "onSortChange", "tableLayout"]);
3951
+ return (React.createElement(StyledTable, Object.assign({ "$tableLayout": tableLayout }, accessibleProps),
3195
3952
  hideHeaders ? null : (React.createElement("thead", null,
3196
- React.createElement("tr", null, columns.map(function (column, i) {
3953
+ React.createElement("tr", null, columns.map((column, i) => {
3197
3954
  return (React.createElement(Header, { "$isSortable": column.isSortable, "$width": column.width, key: i, onClick: onSortChange === null || onSortChange === void 0 ? void 0 : onSortChange.bind(null, column.id) },
3198
3955
  column.label,
3199
3956
  column.isSortable && sortBy === column.id ? (React.createElement(IconWrapper, null,
3200
3957
  React.createElement(Icon, { color: Colors.PRIMARY.Hex, path: sortDirection === 'asc' ? js.mdiChevronUp : js.mdiChevronDown, size: '20px' }))) : null));
3201
3958
  })))),
3202
- data.length ? (React.createElement("tbody", null, data.map(function (row, i) {
3203
- return (React.createElement(Row, { "$bgColor": i % 2 === 0 ? '#ffffff' : '#f9f9f9', "$isClickable": !!onRowClick, key: i, onClick: onRowClick ? onRowClick.bind(null, row) : undefined }, columns.map(function (column, i) {
3959
+ data.length ? (React.createElement("tbody", null, data.map((row, i) => {
3960
+ return (React.createElement(Row, { "$bgColor": i % 2 === 0 ? '#ffffff' : '#f9f9f9', "$isClickable": !!onRowClick, key: i, onClick: onRowClick ? onRowClick.bind(null, row) : undefined }, columns.map((column, i) => {
3204
3961
  return (React.createElement(Column, { "$width": columns[i].width, key: i }, column.render ? column.render(row) : row[column.id] || 'N/A'));
3205
3962
  })));
3206
3963
  }))) : null));
3207
- };
3208
- var templateObject_1$4, templateObject_2$4, templateObject_3$3, templateObject_4$1, templateObject_5;
3209
-
3210
- var Wrapper$2 = styled.div(templateObject_1$3 || (templateObject_1$3 = __makeTemplateObject(["\n display: flex;\n box-sizing: border-box;\n align-items: flex-end;\n border-top: 1px solid #e5e5e5;\n border-bottom: 1px solid #e5e5e5;\n flex-shrink: 0;\n align-self: stretch;\n padding: 0;\n margin: 0;\n"], ["\n display: flex;\n box-sizing: border-box;\n align-items: flex-end;\n border-top: 1px solid #e5e5e5;\n border-bottom: 1px solid #e5e5e5;\n flex-shrink: 0;\n align-self: stretch;\n padding: 0;\n margin: 0;\n"])));
3211
- var Tab = styled.div(templateObject_2$3 || (templateObject_2$3 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: ", ";\n font-family: ", ";\n font-weight: ", ";\n color: ", ";\n line-height: 1em;\n padding: 16px 30px 12px;\n margin: 0 0 -1px 0;\n border-bottom-width: 4px;\n border-bottom-style: solid;\n border-bottom-color: ", ";\n cursor: ", ";\n box-sizing: border-box;\n &:hover {\n color: ", ";\n font-weight: 500;\n }\n"], ["\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: ", ";\n font-family: ", ";\n font-weight: ", ";\n color: ", ";\n line-height: 1em;\n padding: 16px 30px 12px;\n margin: 0 0 -1px 0;\n border-bottom-width: 4px;\n border-bottom-style: solid;\n border-bottom-color: ", ";\n cursor: ", ";\n box-sizing: border-box;\n &:hover {\n color: ", ";\n font-weight: 500;\n }\n"])), FontSizes.DEFAULT, FontStyles.DEFAULT, function (props) { return (props.$isActive ? 500 : 400); }, function (props) { return (props.$isActive ? Colors.BLACK.Hex : Colors.MEDIUM_GRAY.Hex); }, function (props) { return (props.$isActive ? Colors.PRIMARY.Hex : 'transparent'); }, function (props) { return (props.$isActive ? 'default' : 'pointer'); }, function (props) { return (props.$isActive ? Colors.BLACK.Hex : Colors.PRIMARY.Hex); });
3212
- var Badge = styled.div(templateObject_3$2 || (templateObject_3$2 = __makeTemplateObject(["\n display: flex;\n width: 18px;\n height: 18px;\n justify-content: center;\n align-items: center;\n border-radius: 9px;\n background: ", ";\n color: #fff;\n font-family: ", ";\n font-size: 12px;\n font-weight: 500;\n line-height: 1;\n letter-spacing: 1px;\n"], ["\n display: flex;\n width: 18px;\n height: 18px;\n justify-content: center;\n align-items: center;\n border-radius: 9px;\n background: ", ";\n color: #fff;\n font-family: ", ";\n font-size: 12px;\n font-weight: 500;\n line-height: 1;\n letter-spacing: 1px;\n"])), function (props) { return (props.$isError ? Colors.RED.Hex : Colors.PRIMARY.Hex); }, FontStyles.DEFAULT);
3213
- var Tabs = function (_a) {
3214
- var tabs = _a.tabs, accessibleProps = __rest(_a, ["tabs"]);
3215
- return (React.createElement(Wrapper$2, __assign({}, accessibleProps), tabs.map(function (_a, i) {
3216
- var isActive = _a.isActive, label = _a.label, badgeCount = _a.badgeCount, errorBadge = _a.errorBadge, onClick = _a.onClick, accessibleProps = __rest(_a, ["isActive", "label", "badgeCount", "errorBadge", "onClick"]);
3217
- return (React.createElement(Tab, __assign({ "$isActive": isActive || false, key: i, onClick: isActive ? undefined : onClick }, accessibleProps),
3964
+ };
3965
+
3966
+ const Wrapper$2 = styled.div `
3967
+ display: flex;
3968
+ box-sizing: border-box;
3969
+ align-items: flex-end;
3970
+ border-top: 1px solid #e5e5e5;
3971
+ border-bottom: 1px solid #e5e5e5;
3972
+ flex-shrink: 0;
3973
+ align-self: stretch;
3974
+ padding: 0;
3975
+ margin: 0;
3976
+ `;
3977
+ const Tab = styled.div `
3978
+ display: flex;
3979
+ align-items: center;
3980
+ gap: 6px;
3981
+ font-size: ${FontSizes.DEFAULT};
3982
+ font-family: ${FontStyles.DEFAULT};
3983
+ font-weight: ${props => (props.$isActive ? 500 : 400)};
3984
+ color: ${props => (props.$isActive ? Colors.BLACK.Hex : Colors.MEDIUM_GRAY.Hex)};
3985
+ line-height: 1em;
3986
+ padding: 16px 30px 12px;
3987
+ margin: 0 0 -1px 0;
3988
+ border-bottom-width: 4px;
3989
+ border-bottom-style: solid;
3990
+ border-bottom-color: ${props => (props.$isActive ? Colors.PRIMARY.Hex : 'transparent')};
3991
+ cursor: ${props => (props.$isActive ? 'default' : 'pointer')};
3992
+ box-sizing: border-box;
3993
+ &:hover {
3994
+ color: ${props => (props.$isActive ? Colors.BLACK.Hex : Colors.PRIMARY.Hex)};
3995
+ font-weight: 500;
3996
+ }
3997
+ `;
3998
+ const Badge = styled.div `
3999
+ display: flex;
4000
+ width: 18px;
4001
+ height: 18px;
4002
+ justify-content: center;
4003
+ align-items: center;
4004
+ border-radius: 9px;
4005
+ background: ${props => (props.$isError ? Colors.RED.Hex : Colors.PRIMARY.Hex)};
4006
+ color: #fff;
4007
+ font-family: ${FontStyles.DEFAULT};
4008
+ font-size: 12px;
4009
+ font-weight: 500;
4010
+ line-height: 1;
4011
+ letter-spacing: 1px;
4012
+ `;
4013
+ const Tabs = (_a) => {
4014
+ var { tabs } = _a, accessibleProps = __rest(_a, ["tabs"]);
4015
+ return (React.createElement(Wrapper$2, Object.assign({}, accessibleProps), tabs.map((_a, i) => {
4016
+ var { isActive, label, badgeCount, errorBadge, onClick } = _a, accessibleProps = __rest(_a, ["isActive", "label", "badgeCount", "errorBadge", "onClick"]);
4017
+ return (React.createElement(Tab, Object.assign({ "$isActive": isActive || false, key: i, onClick: isActive ? undefined : onClick }, accessibleProps),
3218
4018
  badgeCount ? React.createElement(Badge, { "$isError": errorBadge || false }, badgeCount) : null,
3219
4019
  label));
3220
4020
  })));
3221
4021
  };
3222
- Tabs.defaultProps = {};
3223
- var templateObject_1$3, templateObject_2$3, templateObject_3$2;
3224
-
3225
- var Wrapper$1 = styled.div(templateObject_1$2 || (templateObject_1$2 = __makeTemplateObject(["\n display: inline-block;\n border-radius: 4px;\n padding: 4px 6px;\n background: ", ";\n color: #ffffff;\n box-sizing: border-box;\n cursor: ", ";\n"], ["\n display: inline-block;\n border-radius: 4px;\n padding: 4px 6px;\n background: ", ";\n color: #ffffff;\n box-sizing: border-box;\n cursor: ", ";\n"])), function (props) { return Colors[props.$color].Hex; }, function (props) { return (props.$removable ? 'pointer' : 'default'); });
3226
- var Content = styled.div(templateObject_2$2 || (templateObject_2$2 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
3227
- var Label = styled.div(templateObject_3$1 || (templateObject_3$1 = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n font-weight: 500;\n font-family: ", ";\n line-height: 1.2em;\n"], ["\n color: ", ";\n font-size: ", ";\n font-weight: 500;\n font-family: ", ";\n line-height: 1.2em;\n"])), function (props) { return (props.$color === 'SUBTLE_GRAY' ? '#000000' : '#ffffff'); }, FontSizes.SMALL, FontStyles.DEFAULT);
3228
- var Remove = styled.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n margin-left: 10px;\n display: flex;\n align-items: center;\n"], ["\n margin-left: 10px;\n display: flex;\n align-items: center;\n"])));
3229
- var Tag = function (_a) {
3230
- var children = _a.children, _b = _a.color, color = _b === void 0 ? 'PRIMARY' : _b, removable = _a.removable, onClick = _a.onClick, accessibleProps = __rest(_a, ["children", "color", "removable", "onClick"]);
3231
- return (React.createElement(Wrapper$1, __assign({ "$color": color, "$removable": removable, onClick: onClick }, accessibleProps),
4022
+ Tabs.defaultProps = {};
4023
+
4024
+ const Wrapper$1 = styled.div `
4025
+ display: inline-block;
4026
+ border-radius: 4px;
4027
+ padding: 4px 6px;
4028
+ background: ${props => Colors[props.$color].Hex};
4029
+ color: #ffffff;
4030
+ box-sizing: border-box;
4031
+ cursor: ${props => (props.$removable ? 'pointer' : 'default')};
4032
+ `;
4033
+ const Content = styled.div `
4034
+ display: flex;
4035
+ align-items: center;
4036
+ `;
4037
+ const Label = styled.div `
4038
+ color: ${props => (props.$color === 'SUBTLE_GRAY' ? '#000000' : '#ffffff')};
4039
+ font-size: ${FontSizes.SMALL};
4040
+ font-weight: 500;
4041
+ font-family: ${FontStyles.DEFAULT};
4042
+ line-height: 1.2em;
4043
+ `;
4044
+ const Remove = styled.div `
4045
+ margin-left: 10px;
4046
+ display: flex;
4047
+ align-items: center;
4048
+ `;
4049
+ const Tag = (_a) => {
4050
+ var { children, color = 'PRIMARY', removable, onClick } = _a, accessibleProps = __rest(_a, ["children", "color", "removable", "onClick"]);
4051
+ return (React.createElement(Wrapper$1, Object.assign({ "$color": color, "$removable": removable, onClick: onClick }, accessibleProps),
3232
4052
  React.createElement(Content, null,
3233
4053
  React.createElement(Label, { "$color": color }, children),
3234
4054
  removable ? (React.createElement(Remove, null,
3235
4055
  React.createElement(Icon, { color: color === 'SUBTLE_GRAY' ? '#000000' : '#ffffff', path: js.mdiClose, size: '15px' }))) : null)));
3236
- };
3237
- var templateObject_1$2, templateObject_2$2, templateObject_3$1, templateObject_4;
4056
+ };
3238
4057
 
3239
- var Track = styled.div(templateObject_1$1 || (templateObject_1$1 = __makeTemplateObject(["\n height: 24px;\n border-radius: 12px;\n background: ", ";\n display: flex;\n align-items: center;\n cursor: pointer;\n width: 40px;\n padding: 2px;\n box-sizing: border-box;\n"], ["\n height: 24px;\n border-radius: 12px;\n background: ", ";\n display: flex;\n align-items: center;\n cursor: pointer;\n width: 40px;\n padding: 2px;\n box-sizing: border-box;\n"])), function (props) { return (props.$on ? Colors.GREEN.Hex : Colors.BLACK.Hex); });
3240
- var Handle = styled.div(templateObject_2$1 || (templateObject_2$1 = __makeTemplateObject(["\n width: 20px;\n height: 20px;\n border-radius: 10px;\n background: #ffffff;\n margin-left: ", ";\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n"], ["\n width: 20px;\n height: 20px;\n border-radius: 10px;\n background: #ffffff;\n margin-left: ", ";\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n"])), function (props) { return (props.$on ? 'auto' : '0px'); });
3241
- var Toggle = function (_a) {
3242
- var onClick = _a.onClick, on = _a.on, accessibleProps = __rest(_a, ["onClick", "on"]);
3243
- return (React.createElement(Track, __assign({ "$on": on, onClick: onClick }, accessibleProps),
4058
+ const Track = styled.div `
4059
+ height: 24px;
4060
+ border-radius: 12px;
4061
+ background: ${props => (props.$on ? Colors.GREEN.Hex : Colors.BLACK.Hex)};
4062
+ display: flex;
4063
+ align-items: center;
4064
+ cursor: pointer;
4065
+ width: 40px;
4066
+ padding: 2px;
4067
+ box-sizing: border-box;
4068
+ `;
4069
+ const Handle = styled.div `
4070
+ width: 20px;
4071
+ height: 20px;
4072
+ border-radius: 10px;
4073
+ background: #ffffff;
4074
+ margin-left: ${props => (props.$on ? 'auto' : '0px')};
4075
+ display: flex;
4076
+ align-items: center;
4077
+ justify-content: center;
4078
+ box-sizing: border-box;
4079
+ `;
4080
+ const Toggle = (_a) => {
4081
+ var { onClick, on } = _a, accessibleProps = __rest(_a, ["onClick", "on"]);
4082
+ return (React.createElement(Track, Object.assign({ "$on": on, onClick: onClick }, accessibleProps),
3244
4083
  React.createElement("input", { checked: on, name: accessibleProps.name, type: 'hidden' }),
3245
4084
  React.createElement(Handle, { "$on": on },
3246
4085
  React.createElement(Icon, { color: on ? Colors.GREEN.Hex : Colors.BLACK.Hex, path: on ? js.mdiCheck : js.mdiClose, size: '16px' }))));
3247
4086
  };
3248
- Toggle.defaultProps = {};
3249
- var templateObject_1$1, templateObject_2$1;
3250
-
3251
- var Container = styled.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n width: 100%;\n padding: 40px auto;\n gap: 20px;\n display: flex;\n flex-direction: column;\n justify-items: center;\n align-items: center;\n"], ["\n width: 100%;\n padding: 40px auto;\n gap: 20px;\n display: flex;\n flex-direction: column;\n justify-items: center;\n align-items: center;\n"])));
3252
- var Wrapper = styled.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n gap: 10px;\n display: flex;\n flex-direction: column;\n justify-items: center;\n align-items: center;\n"], ["\n gap: 10px;\n display: flex;\n flex-direction: column;\n justify-items: center;\n align-items: center;\n"])));
3253
- var StyledIcon = styled.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: center;\n width: 80px;\n height: 80px;\n border-radius: 40px;\n background: #f5f5f5;\n"], ["\n display: flex;\n align-items: center;\n justify-content: center;\n width: 80px;\n height: 80px;\n border-radius: 40px;\n background: #f5f5f5;\n"])));
3254
- var ZeroState = function (_a) {
3255
- var icon = _a.icon, title = _a.title, description = _a.description, action = _a.action, accessibleProps = __rest(_a, ["icon", "title", "description", "action"]);
3256
- return (React.createElement(Container, __assign({}, accessibleProps),
4087
+ Toggle.defaultProps = {};
4088
+
4089
+ const Container = styled.div `
4090
+ width: 100%;
4091
+ padding: 40px auto;
4092
+ gap: 20px;
4093
+ display: flex;
4094
+ flex-direction: column;
4095
+ justify-items: center;
4096
+ align-items: center;
4097
+ `;
4098
+ const Wrapper = styled.div `
4099
+ gap: 10px;
4100
+ display: flex;
4101
+ flex-direction: column;
4102
+ justify-items: center;
4103
+ align-items: center;
4104
+ `;
4105
+ const StyledIcon = styled.div `
4106
+ display: flex;
4107
+ align-items: center;
4108
+ justify-content: center;
4109
+ width: 80px;
4110
+ height: 80px;
4111
+ border-radius: 40px;
4112
+ background: #f5f5f5;
4113
+ `;
4114
+ const ZeroState = (_a) => {
4115
+ var { icon, title, description, action } = _a, accessibleProps = __rest(_a, ["icon", "title", "description", "action"]);
4116
+ return (React.createElement(Container, Object.assign({}, accessibleProps),
3257
4117
  React.createElement(StyledIcon, null,
3258
4118
  React.createElement(Icon, { color: Colors.MEDIUM_GRAY.Hex, path: icon, size: '40px' })),
3259
4119
  React.createElement(Wrapper, null,
3260
4120
  React.createElement(Heading, { children: title, type: 'tertiary' }),
3261
4121
  description && React.createElement(Copy, { align: 'center', children: description, color: 'GRAY', type: 'default' })),
3262
4122
  action && (React.createElement(Button, { children: action === null || action === void 0 ? void 0 : action.children, icon: action === null || action === void 0 ? void 0 : action.icon, onClick: action === null || action === void 0 ? void 0 : action.onClick }))));
3263
- };
3264
- var templateObject_1, templateObject_2, templateObject_3;
4123
+ };
3265
4124
 
3266
4125
  exports.Accordion = Accordion;
3267
4126
  exports.ActionDialog = ActionDialog;
3268
4127
  exports.Alert = Alert;
3269
4128
  exports.BulkActionBar = BulkActionBar;
3270
4129
  exports.Button = Button;
4130
+ exports.ButtonMenu = ButtonMenu;
3271
4131
  exports.Checkbox = Checkbox;
3272
4132
  exports.Checklist = Checklist;
3273
4133
  exports.Copy = Copy;
@@ -3282,6 +4142,7 @@ exports.Logo = Logo;
3282
4142
  exports.Modal = Modal;
3283
4143
  exports.MoreMenu = MoreMenu;
3284
4144
  exports.MultiSelect = MultiSelect;
4145
+ exports.PageHeader = PageHeader;
3285
4146
  exports.Pagination = Pagination;
3286
4147
  exports.Radio = Radio;
3287
4148
  exports.RadioList = RadioList;