orcs-design-system 3.3.61 → 3.3.63
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/es/GlobalStyles.js +1 -1
- package/es/assets/Colour/index.js +1 -1
- package/es/components/ActionsMenu/ActionsMenu.animations.js +9 -9
- package/es/components/ActionsMenu/index.js +19 -19
- package/es/components/Avatar/index.js +74 -43
- package/es/components/Badge/index.js +2 -2
- package/es/components/Box/index.js +2 -2
- package/es/components/Breadcrumbs/index.js +6 -6
- package/es/components/Button/index.js +20 -11
- package/es/components/ButtonGroup/index.js +8 -8
- package/es/components/Card/index.js +6 -6
- package/es/components/Checkbox/index.js +16 -16
- package/es/components/DatePicker/index.js +4 -4
- package/es/components/Divider/index.js +2 -2
- package/es/components/Expandable/index.js +10 -10
- package/es/components/Flex/index.js +4 -4
- package/es/components/FloatingPanels/FloatingPanels.styles.js +20 -20
- package/es/components/Grid/index.js +4 -4
- package/es/components/Header/Header.styles.js +20 -20
- package/es/components/HeaderSimple/index.js +6 -6
- package/es/components/Icon/index.js +10 -6
- package/es/components/Loading/index.js +12 -12
- package/es/components/Modal/index.js +14 -14
- package/es/components/Notification/index.js +8 -8
- package/es/components/Popover/index.js +6 -6
- package/es/components/ProgressBar/index.js +5 -5
- package/es/components/RadioButton/index.js +12 -12
- package/es/components/Range/index.js +6 -6
- package/es/components/Select/index.js +5 -5
- package/es/components/SideNavV2/NavItem.js +11 -11
- package/es/components/SideNavV2/SideNav.js +7 -12
- package/es/components/SideNavV2/SideNavV2.stories.js +3 -1
- package/es/components/SideNavV2/__tests__/interaction-scenarios.test.js +64 -261
- package/es/components/SideNavV2/__tests__/resize.test.js +1 -1
- package/es/components/SideNavV2/__tests__/sections.test.js +12 -0
- package/es/components/SideNavV2/components/BaseSection.js +19 -13
- package/es/components/SideNavV2/components/ExpandedPanel.js +6 -9
- package/es/components/SideNavV2/components/PanelControl.js +1 -0
- package/es/components/SideNavV2/constants/sideNav.js +6 -0
- package/es/components/SideNavV2/hooks/useSideNavState.js +15 -288
- package/es/components/SideNavV2/sections/SideNavCurrentViewSection.js +8 -8
- package/es/components/SideNavV2/styles/SideNavV2.styles.js +54 -124
- package/es/components/Spacer/index.js +2 -2
- package/es/components/StatusDot/index.js +2 -2
- package/es/components/StyledLink/index.js +2 -2
- package/es/components/Table/getExpandColumnConfig.js +2 -2
- package/es/components/Tabs/index.js +13 -13
- package/es/components/TabsAlt/TabsAlt.stories.js +60 -0
- package/es/components/TabsAlt/index.js +52 -27
- package/es/components/Tag/Tag.stories.js +86 -71
- package/es/components/Tag/index.js +243 -90
- package/es/components/TextArea/index.js +6 -6
- package/es/components/TextInput/index.js +11 -11
- package/es/components/Toggle/index.js +8 -8
- package/es/components/TreeNav/index.js +2 -2
- package/es/components/Typography/index.js +22 -22
- package/es/components.test.js +0 -8
- package/es/index.js +0 -3
- package/es/interplayIndex.js +0 -1
- package/es/systemThemeCollapsed.js +3 -3
- package/es/systemtheme.js +3 -0
- package/package.json +20 -18
- package/es/components/HeaderComplex/HeaderComplex.stories.js +0 -186
- package/es/components/HeaderComplex/index.js +0 -928
- package/es/components/SideNav/NavItem.js +0 -211
- package/es/components/SideNav/SideNav.stories.js +0 -213
- package/es/components/SideNav/index.js +0 -341
- package/es/components/Sidebar/Sidebar.stories.js +0 -70
- package/es/components/Sidebar/index.js +0 -261
package/es/GlobalStyles.js
CHANGED
|
@@ -3,5 +3,5 @@ import { themeGet } from "@styled-system/theme-get";
|
|
|
3
3
|
// GLOBAL STYLES
|
|
4
4
|
// For browser reset, setting global box sizing and font sizing etc.
|
|
5
5
|
|
|
6
|
-
const GlobalStyles = createGlobalStyle(["html{box-sizing:border-box;line-height:1.15;line-height:calc(2px + 2ex + 2px);}html *{line-height:calc(2px + 2ex + 2px);}*,*:before,*:after{box-sizing:inherit;}html,body{height:100%;width:100%;margin:", ";}body{font-family:", ";color:", ";}html{font-size:62.5%;}body{font-size:", ";}main{display:flex;align-items:stretch;align-content:stretch;width:100%;}section{height:auto;width:100%;overflow-y:auto;}img{border-style:none;}small{font-size:80%;}p{margin:", ";}h1,h2,h3,h4,h5,h6{font-weight:", ";font-family:", ";margin:", ";}h1{font-size:", "}h2{font-size:", "}h3{font-size:", "}h4{font-size:", "}h5{font-size:", "}h6{font-size:", "}a,p,small,li,h1,h2,h3,h4,h5,h6{word-break:break-word;}"], props => themeGet("space.0")(props), props => themeGet("fonts.main")(props), props => themeGet("colors.greyDarkest")(props), props => themeGet("fontSizes.2")(props), props => themeGet("space.0")(props), props => themeGet("fontWeights.1")(props), props => themeGet("fonts.main")(props), props => themeGet("space.0")(props), props => themeGet("fontSizes.6")(props), props => themeGet("fontSizes.5")(props), props => themeGet("fontSizes.4")(props), props => themeGet("fontSizes.3")(props), props => themeGet("fontSizes.2")(props), props => themeGet("fontSizes.1")(props));
|
|
6
|
+
const GlobalStyles = /*#__PURE__*/createGlobalStyle(["html{box-sizing:border-box;line-height:1.15;line-height:calc(2px + 2ex + 2px);}html *{line-height:calc(2px + 2ex + 2px);}*,*:before,*:after{box-sizing:inherit;}html,body{height:100%;width:100%;margin:", ";}body{font-family:", ";color:", ";}html{font-size:62.5%;}body{font-size:", ";}main{display:flex;align-items:stretch;align-content:stretch;width:100%;}section{height:auto;width:100%;overflow-y:auto;}img{border-style:none;}small{font-size:80%;}p{margin:", ";}h1,h2,h3,h4,h5,h6{font-weight:", ";font-family:", ";margin:", ";}h1{font-size:", "}h2{font-size:", "}h3{font-size:", "}h4{font-size:", "}h5{font-size:", "}h6{font-size:", "}a,p,small,li,h1,h2,h3,h4,h5,h6{word-break:break-word;}"], props => themeGet("space.0")(props), props => themeGet("fonts.main")(props), props => themeGet("colors.greyDarkest")(props), props => themeGet("fontSizes.2")(props), props => themeGet("space.0")(props), props => themeGet("fontWeights.1")(props), props => themeGet("fonts.main")(props), props => themeGet("space.0")(props), props => themeGet("fontSizes.6")(props), props => themeGet("fontSizes.5")(props), props => themeGet("fontSizes.4")(props), props => themeGet("fontSizes.3")(props), props => themeGet("fontSizes.2")(props), props => themeGet("fontSizes.1")(props));
|
|
7
7
|
export default GlobalStyles;
|
|
@@ -2,7 +2,7 @@ import styled from "styled-components";
|
|
|
2
2
|
import { themeGet } from "@styled-system/theme-get";
|
|
3
3
|
import shouldForwardProp from "@styled-system/should-forward-prop";
|
|
4
4
|
import { css } from "styled-components";
|
|
5
|
-
export const Colour = styled("div").withConfig({
|
|
5
|
+
export const Colour = /*#__PURE__*/styled("div").withConfig({
|
|
6
6
|
shouldForwardProp,
|
|
7
7
|
displayName: "Colour",
|
|
8
8
|
componentId: "sc-uyvdow-0"
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { keyframes } from "styled-components";
|
|
2
|
-
export const crossFadeIn = keyframes(["0%{opacity:0;}75%{opacity:0;}100%{opacity:1;}"]);
|
|
3
|
-
export const beforeDotCollapsing = keyframes(["0%{transform:translate(0,-6px);}50%{transform:translate(0,0);}100%{transform:translate(0,0);}"]);
|
|
4
|
-
export const beforeDotExpanding = keyframes(["0%{transform:translate(0,0);}50%{transform:translate(0,0);}100%{transform:translate(0,-6px);}"]);
|
|
5
|
-
export const afterDotCollapsing = keyframes(["0%{transform:translate(0,6px);}50%{transform:translate(0,0);}100%{transform:translate(0,0);}"]);
|
|
6
|
-
export const afterDotExpanding = keyframes(["0%{transform:translate(0,0);}50%{transform:translate(0,0);}100%{transform:translate(0,6px);}"]);
|
|
7
|
-
export const beforeCrossExpanding = keyframes(["0%{height:4px;transform:rotate(-45deg);}50%{height:4px;transform:rotate(-45deg);}100%{height:18px;transform:translate(0,-7px) rotate(-45deg);}"]);
|
|
8
|
-
export const beforeCrossCollapsing = keyframes(["0%{height:18px;transform:translate(0,-7px) rotate(-45deg);}50%{height:4px;transform:rotate(-45deg);}100%{height:4px;transform:rotate(-45deg);}"]);
|
|
9
|
-
export const afterCrossExpanding = keyframes(["0%{height:4px;transform:rotate(45deg);}50%{height:4px;transform:rotate(45deg);}100%{height:18px;transform:translate(0,-7px) rotate(45deg);}"]);
|
|
10
|
-
export const afterCrossCollapsing = keyframes(["0%{height:18px;transform:translate(0,-7px) rotate(45deg);}50%{height:4px;transform:rotate(45deg);}100%{height:4px;transform:rotate(45deg);}"]);
|
|
2
|
+
export const crossFadeIn = /*#__PURE__*/keyframes(["0%{opacity:0;}75%{opacity:0;}100%{opacity:1;}"]);
|
|
3
|
+
export const beforeDotCollapsing = /*#__PURE__*/keyframes(["0%{transform:translate(0,-6px);}50%{transform:translate(0,0);}100%{transform:translate(0,0);}"]);
|
|
4
|
+
export const beforeDotExpanding = /*#__PURE__*/keyframes(["0%{transform:translate(0,0);}50%{transform:translate(0,0);}100%{transform:translate(0,-6px);}"]);
|
|
5
|
+
export const afterDotCollapsing = /*#__PURE__*/keyframes(["0%{transform:translate(0,6px);}50%{transform:translate(0,0);}100%{transform:translate(0,0);}"]);
|
|
6
|
+
export const afterDotExpanding = /*#__PURE__*/keyframes(["0%{transform:translate(0,0);}50%{transform:translate(0,0);}100%{transform:translate(0,6px);}"]);
|
|
7
|
+
export const beforeCrossExpanding = /*#__PURE__*/keyframes(["0%{height:4px;transform:rotate(-45deg);}50%{height:4px;transform:rotate(-45deg);}100%{height:18px;transform:translate(0,-7px) rotate(-45deg);}"]);
|
|
8
|
+
export const beforeCrossCollapsing = /*#__PURE__*/keyframes(["0%{height:18px;transform:translate(0,-7px) rotate(-45deg);}50%{height:4px;transform:rotate(-45deg);}100%{height:4px;transform:rotate(-45deg);}"]);
|
|
9
|
+
export const afterCrossExpanding = /*#__PURE__*/keyframes(["0%{height:4px;transform:rotate(45deg);}50%{height:4px;transform:rotate(45deg);}100%{height:18px;transform:translate(0,-7px) rotate(45deg);}"]);
|
|
10
|
+
export const afterCrossCollapsing = /*#__PURE__*/keyframes(["0%{height:18px;transform:translate(0,-7px) rotate(45deg);}50%{height:4px;transform:rotate(45deg);}100%{height:4px;transform:rotate(45deg);}"]);
|
|
@@ -11,31 +11,31 @@ import { FloatingFocusManager, FloatingPortal, useMergeRefs } from "@floating-ui
|
|
|
11
11
|
import { getFloatingUiRootElement, getFloatingUiZIndex } from "../../utils/floatingUiHelpers";
|
|
12
12
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
13
|
const ActionMenuContext = /*#__PURE__*/createContext({});
|
|
14
|
-
const StyledActionsMenuContainer = styled.div.withConfig({
|
|
15
|
-
displayName: "
|
|
14
|
+
const StyledActionsMenuContainer = /*#__PURE__*/styled.div.withConfig({
|
|
15
|
+
displayName: "StyledActionsMenuContainer",
|
|
16
16
|
componentId: "sc-yvbni2-0"
|
|
17
17
|
})(["pointer-events:none;opacity:0;visibility:hidden;&.hack-for-legacy-tests{position:absolute;pointer-events:none;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);clip-path:inset(50%);white-space:nowrap;border-width:0;}&.visible{visibility:visible;opacity:1;pointer-events:auto;}"]);
|
|
18
|
-
const Wrapper = styled.div.withConfig({
|
|
19
|
-
displayName: "
|
|
18
|
+
const Wrapper = /*#__PURE__*/styled.div.withConfig({
|
|
19
|
+
displayName: "Wrapper",
|
|
20
20
|
componentId: "sc-yvbni2-1"
|
|
21
21
|
})(["", " ", " position:relative;width:auto;"], space, layout);
|
|
22
|
-
const Control = styled.button.withConfig({
|
|
23
|
-
displayName: "
|
|
22
|
+
const Control = /*#__PURE__*/styled.button.withConfig({
|
|
23
|
+
displayName: "Control",
|
|
24
24
|
componentId: "sc-yvbni2-2"
|
|
25
25
|
})(["position:relative;display:flex;align-items:center;justify-content:center;-moz-appearance:none;-webkit-appearance:none;appearance:none;box-shadow:none;text-decoration:none;text-align:center;border-radius:", ";transition:", ";cursor:", ";width:", ";height:", ";border-radius:", ";border:", ";", " ", " &:hover,&:focus{outline:0;border-color:", ";}&[data-state=\"open\"] .actionsMenu__dots{&:before{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}&:after{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}}&[data-state=\"open\"] .actionsMenu__cross{&:before{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}&:after{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}}&[data-state=\"closed\"] .actionsMenu__dots{&:before{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}&:after{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}}&[data-state=\"closed\"] .actionsMenu__cross{&:before{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}&:after{animation:500ms ", " cubic-bezier(0.68,-0.6,0.32,1.6) forwards;}}"], props => themeGet("radii.2")(props), props => themeGet("transition.transitionDefault")(props), props => props.disabled ? "not-allowed" : "pointer", props => props.variant === "circle" ? "35px" : "30px", props => props.variant === "circle" ? "35px" : "30px", props => props.variant === "circle" ? "50%" : themeGet("radii.2")(props), props => props.variant === "circle" ? "solid 2px" : "solid 1px", props => props.variant === "default" && css(["background-color:", ";border-color:", ";"], props.disabled ? themeGet("colors.greyLighter")(props) : "white", props.disabled ? themeGet("colors.greyLighter")(props) : themeGet("colors.greyLight")(props)), props => props.variant === "circle" && css(["background-color:", ";border-color:", ";"], props.disabled ? themeGet("colors.greyLighter")(props) : themeGet("colors.greyDarkest")(props), props.disabled ? themeGet("colors.greyLighter")(props) : themeGet("colors.greyDarkest")(props)), props => props.disabled ? themeGet("colors.greyLighter")(props) : themeGet("colors.primary")(props), beforeDotCollapsing, afterDotCollapsing, beforeCrossExpanding, afterCrossExpanding, beforeDotExpanding, afterDotExpanding, beforeCrossCollapsing, afterCrossCollapsing);
|
|
26
|
-
const Dots = styled.div.withConfig({
|
|
27
|
-
displayName: "
|
|
26
|
+
const Dots = /*#__PURE__*/styled.div.withConfig({
|
|
27
|
+
displayName: "Dots",
|
|
28
28
|
componentId: "sc-yvbni2-3"
|
|
29
29
|
})(["border-radius:2px;height:4px;width:4px;background-color:", ";&:before,&:after{content:\"\";display:block;position:absolute;border-radius:2px;height:4px;width:4px;background-color:", ";}&:before{transform:translate(0,-6px);}&:after{transform:translate(0,6px);}"], props => props.variant === "circle" ? themeGet("colors.white")(props) : themeGet("colors.greyDarker")(props), props => props.variant === "circle" ? themeGet("colors.white")(props) : themeGet("colors.greyDarker")(props));
|
|
30
|
-
const Cross = styled.div.withConfig({
|
|
31
|
-
displayName: "
|
|
30
|
+
const Cross = /*#__PURE__*/styled.div.withConfig({
|
|
31
|
+
displayName: "Cross",
|
|
32
32
|
componentId: "sc-yvbni2-4"
|
|
33
33
|
})(["animation:1500ms ", " ease-in-out forwards;opacity:0;position:absolute;left:calc(50% - 2px);top:calc(50% - 2px);&:before,&:after{content:\"\";display:block;position:absolute;border-radius:2px;height:4px;width:4px;background-color:", ";}&:before{transform:rotate(-45deg);}&:after{transform:rotate(45deg);}"], crossFadeIn, props => props.variant === "circle" ? themeGet("colors.white")(props) : themeGet("colors.greyDarker")(props));
|
|
34
|
-
const Menu = styled.div.withConfig({
|
|
35
|
-
displayName: "
|
|
34
|
+
const Menu = /*#__PURE__*/styled.div.withConfig({
|
|
35
|
+
displayName: "Menu",
|
|
36
36
|
componentId: "sc-yvbni2-5"
|
|
37
37
|
})(["display:block;width:", ";z-index:5;background-color:", ";border:1px solid ", ";box-shadow:", ";border-radius:", ";"], props => props.menuWidth ? props.menuWidth : "auto", themeGet("colors.white"), themeGet("colors.greyLight"), themeGet("shadows.boxDefault"), props => themeGet("radii.2")(props));
|
|
38
|
-
export const ActionsMenuHeading = styled(props => {
|
|
38
|
+
export const ActionsMenuHeading = /*#__PURE__*/styled(props => {
|
|
39
39
|
const {
|
|
40
40
|
actionMenu
|
|
41
41
|
} = useContext(ActionMenuContext);
|
|
@@ -59,15 +59,15 @@ export const ActionsMenuHeading = styled(props => {
|
|
|
59
59
|
tabIndex: "0",
|
|
60
60
|
role: "button"
|
|
61
61
|
}).withConfig({
|
|
62
|
-
displayName: "
|
|
62
|
+
displayName: "ActionsMenuHeading",
|
|
63
63
|
componentId: "sc-yvbni2-6"
|
|
64
64
|
})(["color:", ";padding:8px;width:100%;font-size:", ";font-weight:", ";border-bottom:solid 1px ", ";white-space:nowrap;cursor:", ";"], props => themeGet("colors.greyDark")(props), props => themeGet("fontSizes.0")(props), props => themeGet("fontWeights.1")(props), props => themeGet("colors.greyLighter")(props), props => props.canClick ? "pointer" : "default");
|
|
65
|
-
const ActionMenuItemStyles = css(["white-space:nowrap;display:block;width:100%;text-align:left;cursor:pointer;margin:0;padding:8px;appearance:none;background-color:", ";border:none;border-bottom:solid 1px ", ";border-radius:0;color:", ";font-size:", ";line-height:", ";font-family:", ";font-weight:", ";text-decoration:none;transition:", ";&:hover{background-color:", ";}&:first-child{border-radius:", " ", " 0 0;}&:last-child{border:0;border-radius:0 0 ", " ", ";}&:only-child{border-radius:", ";}&#other{padding:6px 8px;}"], props => props.selected ? themeGet("colors.success20")(props) : "transparent", themeGet("colors.white"), themeGet("colors.greyDarkest"), themeGet("fontSizes.0"), themeGet("fontSizes.0"), themeGet("fonts.main"), themeGet("fontWeights.2"), themeGet("transition.transitionDefault"), themeGet("colors.primaryLightest"), themeGet("radii.2"), themeGet("radii.2"), themeGet("radii.2"), themeGet("radii.2"), themeGet("radii.2"));
|
|
66
|
-
const StyledNavLink = styled(NavLink).withConfig({
|
|
67
|
-
displayName: "
|
|
65
|
+
const ActionMenuItemStyles = /*#__PURE__*/css(["white-space:nowrap;display:block;width:100%;text-align:left;cursor:pointer;margin:0;padding:8px;appearance:none;background-color:", ";border:none;border-bottom:solid 1px ", ";border-radius:0;color:", ";font-size:", ";line-height:", ";font-family:", ";font-weight:", ";text-decoration:none;transition:", ";&:hover{background-color:", ";}&:first-child{border-radius:", " ", " 0 0;}&:last-child{border:0;border-radius:0 0 ", " ", ";}&:only-child{border-radius:", ";}&#other{padding:6px 8px;}"], props => props.selected ? themeGet("colors.success20")(props) : "transparent", themeGet("colors.white"), themeGet("colors.greyDarkest"), themeGet("fontSizes.0"), themeGet("fontSizes.0"), themeGet("fonts.main"), themeGet("fontWeights.2"), themeGet("transition.transitionDefault"), themeGet("colors.primaryLightest"), themeGet("radii.2"), themeGet("radii.2"), themeGet("radii.2"), themeGet("radii.2"), themeGet("radii.2"));
|
|
66
|
+
const StyledNavLink = /*#__PURE__*/styled(NavLink).withConfig({
|
|
67
|
+
displayName: "StyledNavLink",
|
|
68
68
|
componentId: "sc-yvbni2-7"
|
|
69
69
|
})(["text-decoration:none;"]);
|
|
70
|
-
export const ActionsMenuItem = styled(props => {
|
|
70
|
+
export const ActionsMenuItem = /*#__PURE__*/styled(props => {
|
|
71
71
|
const {
|
|
72
72
|
id,
|
|
73
73
|
onItemClick,
|
|
@@ -119,7 +119,7 @@ export const ActionsMenuItem = styled(props => {
|
|
|
119
119
|
}).attrs({
|
|
120
120
|
role: "menuitem"
|
|
121
121
|
}).withConfig({
|
|
122
|
-
displayName: "
|
|
122
|
+
displayName: "ActionsMenuItem",
|
|
123
123
|
componentId: "sc-yvbni2-8"
|
|
124
124
|
})(["", ""], _ref => {
|
|
125
125
|
let {
|
|
@@ -10,7 +10,7 @@ import css from "@styled-system/css";
|
|
|
10
10
|
import { themeGet } from "@styled-system/theme-get";
|
|
11
11
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
12
12
|
const avatarStyles = compose(space, layout, position);
|
|
13
|
-
export const COLOR_CHANGE = keyframes(["0%{background-position:-468px 0;}100%{background-position:468px 0;}"]);
|
|
13
|
+
export const COLOR_CHANGE = /*#__PURE__*/keyframes(["0%{background-position:-468px 0;}100%{background-position:468px 0;}"]);
|
|
14
14
|
|
|
15
15
|
// Helper function to resolve customSize values
|
|
16
16
|
const resolveCustomSize = (customSize, props) => {
|
|
@@ -24,8 +24,8 @@ const resolveCustomSize = (customSize, props) => {
|
|
|
24
24
|
return themeGet(`avatarScale.${customSize}`)(props) || customSize;
|
|
25
25
|
}
|
|
26
26
|
};
|
|
27
|
-
const AvatarWrapper = styled("div").withConfig({
|
|
28
|
-
displayName: "
|
|
27
|
+
const AvatarWrapper = /*#__PURE__*/styled("div").withConfig({
|
|
28
|
+
displayName: "AvatarWrapper",
|
|
29
29
|
componentId: "sc-1wtet2j-0"
|
|
30
30
|
})(css({
|
|
31
31
|
boxSizing: "border-box",
|
|
@@ -49,8 +49,8 @@ const AvatarWrapper = styled("div").withConfig({
|
|
|
49
49
|
inverted: {}
|
|
50
50
|
}
|
|
51
51
|
}), avatarStyles);
|
|
52
|
-
const TextContent = styled("div").withConfig({
|
|
53
|
-
displayName: "
|
|
52
|
+
const TextContent = /*#__PURE__*/styled("div").withConfig({
|
|
53
|
+
displayName: "TextContent",
|
|
54
54
|
componentId: "sc-1wtet2j-1"
|
|
55
55
|
})(css({
|
|
56
56
|
marginLeft: "s",
|
|
@@ -74,8 +74,8 @@ const TextContent = styled("div").withConfig({
|
|
|
74
74
|
}
|
|
75
75
|
}
|
|
76
76
|
}));
|
|
77
|
-
const Image = styled("img").withConfig({
|
|
78
|
-
displayName: "
|
|
77
|
+
const Image = /*#__PURE__*/styled("img").withConfig({
|
|
78
|
+
displayName: "Image",
|
|
79
79
|
componentId: "sc-1wtet2j-2"
|
|
80
80
|
})(props => css({
|
|
81
81
|
width: resolveCustomSize(props.customSize, props) || themeGet("avatarScale.avatarDefault")(props),
|
|
@@ -116,8 +116,8 @@ const Image = styled("img").withConfig({
|
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
118
|
}));
|
|
119
|
-
const Shape = styled("div").withConfig({
|
|
120
|
-
displayName: "
|
|
119
|
+
const Shape = /*#__PURE__*/styled("div").withConfig({
|
|
120
|
+
displayName: "Shape",
|
|
121
121
|
componentId: "sc-1wtet2j-3"
|
|
122
122
|
})(props => css({
|
|
123
123
|
width: resolveCustomSize(props.customSize, props) || themeGet("avatarScale.avatarDefault")(props),
|
|
@@ -178,7 +178,7 @@ const Shape = styled("div").withConfig({
|
|
|
178
178
|
}
|
|
179
179
|
}
|
|
180
180
|
}));
|
|
181
|
-
const Title = styled(_ref => {
|
|
181
|
+
const Title = /*#__PURE__*/styled(_ref => {
|
|
182
182
|
let {
|
|
183
183
|
titleLevel,
|
|
184
184
|
...props
|
|
@@ -186,7 +186,7 @@ const Title = styled(_ref => {
|
|
|
186
186
|
const Heading = Header[titleLevel];
|
|
187
187
|
return /*#__PURE__*/React.cloneElement(/*#__PURE__*/_jsx(Heading, {}), props);
|
|
188
188
|
}).withConfig({
|
|
189
|
-
displayName: "
|
|
189
|
+
displayName: "Title",
|
|
190
190
|
componentId: "sc-1wtet2j-4"
|
|
191
191
|
})(props => css({
|
|
192
192
|
fontSize: themeGet("fontSizes.2")(props),
|
|
@@ -238,8 +238,8 @@ const Title = styled(_ref => {
|
|
|
238
238
|
}
|
|
239
239
|
}
|
|
240
240
|
}));
|
|
241
|
-
const Subtitle = styled(Text).withConfig({
|
|
242
|
-
displayName: "
|
|
241
|
+
const Subtitle = /*#__PURE__*/styled(Text).withConfig({
|
|
242
|
+
displayName: "Subtitle",
|
|
243
243
|
componentId: "sc-1wtet2j-5"
|
|
244
244
|
})(props => css({
|
|
245
245
|
color: themeGet("colors.greyDark")(props),
|
|
@@ -265,14 +265,14 @@ const Subtitle = styled(Text).withConfig({
|
|
|
265
265
|
default: {}
|
|
266
266
|
}
|
|
267
267
|
}));
|
|
268
|
-
const LocalTime = styled(Popover).withConfig({
|
|
269
|
-
displayName: "
|
|
268
|
+
const LocalTime = /*#__PURE__*/styled(Popover).withConfig({
|
|
269
|
+
displayName: "LocalTime",
|
|
270
270
|
componentId: "sc-1wtet2j-6"
|
|
271
271
|
})(["position:absolute;top:0;left:0;"]);
|
|
272
272
|
|
|
273
273
|
// HeaderAvatar specific styles
|
|
274
|
-
const HeaderAvatarWrapper = styled("div").withConfig({
|
|
275
|
-
displayName: "
|
|
274
|
+
const HeaderAvatarWrapper = /*#__PURE__*/styled("div").withConfig({
|
|
275
|
+
displayName: "HeaderAvatarWrapper",
|
|
276
276
|
componentId: "sc-1wtet2j-7"
|
|
277
277
|
})(_ref2 => {
|
|
278
278
|
let {
|
|
@@ -292,8 +292,8 @@ const HeaderAvatarWrapper = styled("div").withConfig({
|
|
|
292
292
|
background: "transparent"
|
|
293
293
|
};
|
|
294
294
|
}, avatarStyles);
|
|
295
|
-
const HeaderAvatarBorder = styled("div").withConfig({
|
|
296
|
-
displayName: "
|
|
295
|
+
const HeaderAvatarBorder = /*#__PURE__*/styled("div").withConfig({
|
|
296
|
+
displayName: "HeaderAvatarBorder",
|
|
297
297
|
componentId: "sc-1wtet2j-8"
|
|
298
298
|
})(_ref3 => {
|
|
299
299
|
let {
|
|
@@ -314,8 +314,8 @@ const HeaderAvatarBorder = styled("div").withConfig({
|
|
|
314
314
|
background: "#fff"
|
|
315
315
|
};
|
|
316
316
|
});
|
|
317
|
-
const HeaderAvatarLoading = styled("div").withConfig({
|
|
318
|
-
displayName: "
|
|
317
|
+
const HeaderAvatarLoading = /*#__PURE__*/styled("div").withConfig({
|
|
318
|
+
displayName: "HeaderAvatarLoading",
|
|
319
319
|
componentId: "sc-1wtet2j-9"
|
|
320
320
|
})(["width:", ";height:", ";background:linear-gradient( to right,rgba(0,0,0,0.1) 5%,rgba(0,0,0,0.05) 65%,rgba(0,0,0,0.1) 70% );background-size:200px;animation:", " 20s linear infinite;"], _ref4 => {
|
|
321
321
|
let {
|
|
@@ -328,8 +328,8 @@ const HeaderAvatarLoading = styled("div").withConfig({
|
|
|
328
328
|
} = _ref5;
|
|
329
329
|
return $size;
|
|
330
330
|
}, COLOR_CHANGE);
|
|
331
|
-
const HeaderAvatarImage = styled("img").withConfig({
|
|
332
|
-
displayName: "
|
|
331
|
+
const HeaderAvatarImage = /*#__PURE__*/styled("img").withConfig({
|
|
332
|
+
displayName: "HeaderAvatarImage",
|
|
333
333
|
componentId: "sc-1wtet2j-10"
|
|
334
334
|
})(_ref6 => {
|
|
335
335
|
let {
|
|
@@ -347,8 +347,8 @@ const HeaderAvatarImage = styled("img").withConfig({
|
|
|
347
347
|
display: "block"
|
|
348
348
|
};
|
|
349
349
|
});
|
|
350
|
-
const HeaderAvatarShape = styled("div").withConfig({
|
|
351
|
-
displayName: "
|
|
350
|
+
const HeaderAvatarShape = /*#__PURE__*/styled("div").withConfig({
|
|
351
|
+
displayName: "HeaderAvatarShape",
|
|
352
352
|
componentId: "sc-1wtet2j-11"
|
|
353
353
|
})(_ref7 => {
|
|
354
354
|
let {
|
|
@@ -371,7 +371,7 @@ const HeaderAvatarShape = styled("div").withConfig({
|
|
|
371
371
|
alignItems: "center",
|
|
372
372
|
justifyContent: "center",
|
|
373
373
|
...backgroundStyles,
|
|
374
|
-
color: "#
|
|
374
|
+
color: "#fff",
|
|
375
375
|
fontWeight: 600,
|
|
376
376
|
fontSize: `calc(${$size} / 2.5)`,
|
|
377
377
|
borderRadius: $shape === "circle" || !$shape ? "50%" : $shape === "square" ? "6px" : "0",
|
|
@@ -383,8 +383,8 @@ const HeaderAvatarShape = styled("div").withConfig({
|
|
|
383
383
|
})
|
|
384
384
|
};
|
|
385
385
|
});
|
|
386
|
-
const HeaderAvatarAction = styled("button").withConfig({
|
|
387
|
-
displayName: "
|
|
386
|
+
const HeaderAvatarAction = /*#__PURE__*/styled("button").withConfig({
|
|
387
|
+
displayName: "HeaderAvatarAction",
|
|
388
388
|
componentId: "sc-1wtet2j-12"
|
|
389
389
|
})(_ref8 => {
|
|
390
390
|
let {
|
|
@@ -413,8 +413,8 @@ const HeaderAvatarAction = styled("button").withConfig({
|
|
|
413
413
|
}
|
|
414
414
|
};
|
|
415
415
|
});
|
|
416
|
-
const IconContainer = styled("div").withConfig({
|
|
417
|
-
displayName: "
|
|
416
|
+
const IconContainer = /*#__PURE__*/styled("div").withConfig({
|
|
417
|
+
displayName: "IconContainer",
|
|
418
418
|
componentId: "sc-1wtet2j-13"
|
|
419
419
|
})(_ref9 => {
|
|
420
420
|
let {
|
|
@@ -455,6 +455,7 @@ const Avatar = _ref0 => {
|
|
|
455
455
|
sizing,
|
|
456
456
|
image,
|
|
457
457
|
gradient,
|
|
458
|
+
fallbackGradient,
|
|
458
459
|
imageAlt,
|
|
459
460
|
initials,
|
|
460
461
|
title,
|
|
@@ -483,6 +484,10 @@ const Avatar = _ref0 => {
|
|
|
483
484
|
}
|
|
484
485
|
}, [imageAlt, title]);
|
|
485
486
|
|
|
487
|
+
// Resolve a default icon color suitable on accent/gradient backgrounds
|
|
488
|
+
// Prefer theme tokens if available to avoid hard-coded colors
|
|
489
|
+
const defaultIconColor = theme?.colors?.iconOnAccent || theme?.colors?.iconDefault || theme?.colors?.white || "white";
|
|
490
|
+
|
|
486
491
|
// HeaderAvatar logic
|
|
487
492
|
if (headerAvatar) {
|
|
488
493
|
// Sizing logic
|
|
@@ -503,15 +508,19 @@ const Avatar = _ref0 => {
|
|
|
503
508
|
}) : /*#__PURE__*/_jsx(HeaderAvatarShape, {
|
|
504
509
|
$size: size,
|
|
505
510
|
$shape: shape,
|
|
506
|
-
$gradient: gradient,
|
|
511
|
+
$gradient: gradient || fallbackGradient,
|
|
507
512
|
children: initials ? initials : shape === "hexagon" ? /*#__PURE__*/_jsx(Icon, {
|
|
508
|
-
icon: ["fas", "users"]
|
|
513
|
+
icon: ["fas", "users"],
|
|
514
|
+
color: defaultIconColor
|
|
509
515
|
}) : shape === "tag" ? /*#__PURE__*/_jsx(Icon, {
|
|
510
|
-
icon: ["fas", "tag"]
|
|
516
|
+
icon: ["fas", "tag"],
|
|
517
|
+
color: defaultIconColor
|
|
511
518
|
}) : shape === "square" ? /*#__PURE__*/_jsx(Icon, {
|
|
512
|
-
icon: ["fas", "users"]
|
|
519
|
+
icon: ["fas", "users"],
|
|
520
|
+
color: defaultIconColor
|
|
513
521
|
}) : /*#__PURE__*/_jsx(Icon, {
|
|
514
|
-
icon: ["fas", "user"]
|
|
522
|
+
icon: ["fas", "user"],
|
|
523
|
+
color: defaultIconColor
|
|
515
524
|
})
|
|
516
525
|
});
|
|
517
526
|
const avatarContent = /*#__PURE__*/_jsx(HeaderAvatarWrapper, {
|
|
@@ -548,11 +557,11 @@ const Avatar = _ref0 => {
|
|
|
548
557
|
children: shape === "circle" ? /*#__PURE__*/_jsx(Icon, {
|
|
549
558
|
icon: ["fas", "camera"],
|
|
550
559
|
size: sizing === "large" ? "lg" : "1x",
|
|
551
|
-
color:
|
|
560
|
+
color: defaultIconColor
|
|
552
561
|
}) : /*#__PURE__*/_jsx(Icon, {
|
|
553
562
|
icon: ["fas", "image"],
|
|
554
563
|
size: sizing === "large" ? "lg" : "1x",
|
|
555
|
-
color:
|
|
564
|
+
color: defaultIconColor
|
|
556
565
|
})
|
|
557
566
|
}), avatarContent]
|
|
558
567
|
})
|
|
@@ -577,15 +586,19 @@ const Avatar = _ref0 => {
|
|
|
577
586
|
type: type,
|
|
578
587
|
className: type == "inverted" ? "inverted" : "",
|
|
579
588
|
uppercase: uppercase,
|
|
580
|
-
gradient: gradient,
|
|
589
|
+
gradient: gradient || fallbackGradient,
|
|
581
590
|
children: initials ? initials : shape === "hexagon" ? /*#__PURE__*/_jsx(Icon, {
|
|
582
|
-
icon: ["fas", "users"]
|
|
591
|
+
icon: ["fas", "users"],
|
|
592
|
+
color: defaultIconColor
|
|
583
593
|
}) : shape === "tag" ? /*#__PURE__*/_jsx(Icon, {
|
|
584
|
-
icon: ["fas", "tag"]
|
|
594
|
+
icon: ["fas", "tag"],
|
|
595
|
+
color: defaultIconColor
|
|
585
596
|
}) : shape === "square" ? /*#__PURE__*/_jsx(Icon, {
|
|
586
|
-
icon: ["fas", "users"]
|
|
597
|
+
icon: ["fas", "users"],
|
|
598
|
+
color: defaultIconColor
|
|
587
599
|
}) : /*#__PURE__*/_jsx(Icon, {
|
|
588
|
-
icon: ["fas", "user"]
|
|
600
|
+
icon: ["fas", "user"],
|
|
601
|
+
color: defaultIconColor
|
|
589
602
|
})
|
|
590
603
|
}), (hasTitle || hasSubtitle) && /*#__PURE__*/_jsxs(TextContent, {
|
|
591
604
|
type: type,
|
|
@@ -611,7 +624,7 @@ const Avatar = _ref0 => {
|
|
|
611
624
|
icon: true,
|
|
612
625
|
children: /*#__PURE__*/_jsx(Icon, {
|
|
613
626
|
icon: ["fas", "clock"],
|
|
614
|
-
color:
|
|
627
|
+
color: defaultIconColor,
|
|
615
628
|
transform: "grow-2"
|
|
616
629
|
})
|
|
617
630
|
})
|
|
@@ -634,6 +647,10 @@ Avatar.propTypes = {
|
|
|
634
647
|
type: PropTypes.oneOf(["inverted", "default"]),
|
|
635
648
|
/** Specifies a source path for an image */
|
|
636
649
|
image: PropTypes.string,
|
|
650
|
+
/** Specifies the gradient for the avatar background */
|
|
651
|
+
gradient: PropTypes.string,
|
|
652
|
+
/** Specifies the fallback gradient when no image is provided */
|
|
653
|
+
fallbackGradient: PropTypes.string,
|
|
637
654
|
/** Specifies the alt text for an image. This must be specified if image prop is used and title prop is not a string. */
|
|
638
655
|
imageAlt: (props, propName) => {
|
|
639
656
|
if (props.image && props.title && typeof props.title !== "string" && (props[propName] == null || props[propName] === "")) {
|
|
@@ -804,6 +821,20 @@ Avatar.__docgenInfo = {
|
|
|
804
821
|
},
|
|
805
822
|
"required": false
|
|
806
823
|
},
|
|
824
|
+
"gradient": {
|
|
825
|
+
"description": "Specifies the gradient for the avatar background",
|
|
826
|
+
"type": {
|
|
827
|
+
"name": "string"
|
|
828
|
+
},
|
|
829
|
+
"required": false
|
|
830
|
+
},
|
|
831
|
+
"fallbackGradient": {
|
|
832
|
+
"description": "Specifies the fallback gradient when no image is provided",
|
|
833
|
+
"type": {
|
|
834
|
+
"name": "string"
|
|
835
|
+
},
|
|
836
|
+
"required": false
|
|
837
|
+
},
|
|
807
838
|
"imageAlt": {
|
|
808
839
|
"description": "Specifies the alt text for an image. This must be specified if image prop is used and title prop is not a string.",
|
|
809
840
|
"type": {
|
|
@@ -7,9 +7,9 @@ import shouldForwardProp from "@styled-system/should-forward-prop";
|
|
|
7
7
|
import { themeGet } from "@styled-system/theme-get";
|
|
8
8
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
9
|
const BadgeStyles = compose(space, layout, color);
|
|
10
|
-
const Item = styled("span").withConfig({
|
|
10
|
+
const Item = /*#__PURE__*/styled("span").withConfig({
|
|
11
11
|
shouldForwardProp,
|
|
12
|
-
displayName: "
|
|
12
|
+
displayName: "Item",
|
|
13
13
|
componentId: "sc-9r75kj-0"
|
|
14
14
|
}).attrs(props => ({
|
|
15
15
|
"data-testid": props["data-testid"] ? props["data-testid"] : null
|
|
@@ -7,9 +7,9 @@ import PropTypes from "prop-types";
|
|
|
7
7
|
import { themeGet } from "@styled-system/theme-get";
|
|
8
8
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
9
|
const boxStyles = compose(space, layout, flexbox, color, border, position, background);
|
|
10
|
-
const BoxWrapper = styled("div").withConfig({
|
|
10
|
+
const BoxWrapper = /*#__PURE__*/styled("div").withConfig({
|
|
11
11
|
shouldForwardProp,
|
|
12
|
-
displayName: "
|
|
12
|
+
displayName: "BoxWrapper",
|
|
13
13
|
componentId: "sc-jr1api-0"
|
|
14
14
|
}).attrs(props => ({
|
|
15
15
|
"data-testid": props.dataTestId ? props.dataTestId : props["data-testid"] ? props["data-testid"] : null
|
|
@@ -6,16 +6,16 @@ import { themeGet } from "@styled-system/theme-get";
|
|
|
6
6
|
import StyledLink from "../StyledLink";
|
|
7
7
|
import Popover from "../Popover";
|
|
8
8
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
-
const BreadcrumbsWrapper = styled("nav").attrs({
|
|
9
|
+
const BreadcrumbsWrapper = /*#__PURE__*/styled("nav").attrs({
|
|
10
10
|
"aria-label": "breadcrumb"
|
|
11
11
|
}).withConfig({
|
|
12
|
-
displayName: "
|
|
12
|
+
displayName: "BreadcrumbsWrapper",
|
|
13
13
|
componentId: "sc-qbw4kn-0"
|
|
14
14
|
})(["", " ", ""], space, layout);
|
|
15
|
-
const List = styled("ol").withConfig({
|
|
15
|
+
const List = /*#__PURE__*/styled("ol").withConfig({
|
|
16
16
|
shouldForwardProp: prop => !["variant"].includes(prop)
|
|
17
17
|
}).withConfig({
|
|
18
|
-
displayName: "
|
|
18
|
+
displayName: "List",
|
|
19
19
|
componentId: "sc-qbw4kn-1"
|
|
20
20
|
})(["display:flex;flex-direction:", ";flex-wrap:wrap;list-style:none;margin:0;padding:0;gap:5px;text-shadow:", ";", ""], _ref => {
|
|
21
21
|
let {
|
|
@@ -28,10 +28,10 @@ const List = styled("ol").withConfig({
|
|
|
28
28
|
} = _ref2;
|
|
29
29
|
return variant === "white" ? "0 0px 5px rgba(0,0,0,0.2)" : "none";
|
|
30
30
|
}, space);
|
|
31
|
-
const Item = styled("li").withConfig({
|
|
31
|
+
const Item = /*#__PURE__*/styled("li").withConfig({
|
|
32
32
|
shouldForwardProp: prop => !["variant", "isLast"].includes(prop)
|
|
33
33
|
}).withConfig({
|
|
34
|
-
displayName: "
|
|
34
|
+
displayName: "Item",
|
|
35
35
|
componentId: "sc-qbw4kn-2"
|
|
36
36
|
})(["display:flex;gap:5px;align-items:center;color:", ";font-size:", ";line-height:1.5;font-weight:", ";& > a{color:inherit;text-decoration:none;&:hover{text-decoration:underline;}}", ""], _ref3 => {
|
|
37
37
|
let {
|
|
@@ -8,7 +8,16 @@ import Loading from "../Loading";
|
|
|
8
8
|
import { themeGet } from "@styled-system/theme-get";
|
|
9
9
|
import { Link } from "react-router-dom";
|
|
10
10
|
import { omit } from "lodash";
|
|
11
|
+
|
|
12
|
+
// Custom shouldForwardProp that also filters out borderRadius and borderColor
|
|
11
13
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
|
+
const customShouldForwardProp = prop => {
|
|
15
|
+
// Filter out styled-system props that shouldn't go to DOM
|
|
16
|
+
if (["borderRadius", "borderColor"].includes(prop)) {
|
|
17
|
+
return false;
|
|
18
|
+
}
|
|
19
|
+
return shouldForwardProp(prop);
|
|
20
|
+
};
|
|
12
21
|
export const VARIANT_COLORS = {
|
|
13
22
|
default: {
|
|
14
23
|
background: "colors.primary",
|
|
@@ -156,7 +165,7 @@ const getVariantStyle = props => {
|
|
|
156
165
|
return styles[props.variant] || styles.default;
|
|
157
166
|
};
|
|
158
167
|
const getSpace = getter => props => themeGet(`space.${getter(props)}`)(props);
|
|
159
|
-
const buttonStyles = css(["background:", ";color:", ";border-color:", ";display:flex;align-items:center;justify-content:center;appearance:none;box-shadow:none;margin:0;text-decoration:none;text-align:center;font-family:", ";font-weight:", ";border-radius:", ";transition:", ";border-width:", ";cursor:", ";width:", ";height:auto;font-size:", ";padding:", " ", ";svg{margin-right:", ";margin-left:", ";}&:hover{background:", ";border-color:", ";border-width:", ";border-style:solid;}&:focus{outline:0;box-shadow:", " ", ";}", " ", ""], themeGet(VARIANT_COLORS.default.background), themeGet(VARIANT_COLORS.default.color), themeGet("colors.primary"), themeGet("fonts.main"), themeGet("fontWeights.2"), themeGet("radii.2"), themeGet("transition.transitionDefault"), themeGet("borderWidths.1"), props => props.disabled ? "not-allowed" : props.isLoading ? "progress" : "pointer", props => props.fullWidth ? "100%" : "auto", props => {
|
|
168
|
+
const buttonStyles = /*#__PURE__*/css(["background:", ";color:", ";border-color:", ";display:flex;align-items:center;justify-content:center;appearance:none;box-shadow:none;margin:0;text-decoration:none;text-align:center;font-family:", ";font-weight:", ";border-radius:", ";transition:", ";border-width:", ";cursor:", ";width:", ";height:auto;font-size:", ";padding:", " ", ";svg{margin-right:", ";margin-left:", ";}&:hover{background:", ";border-color:", ";border-width:", ";border-style:solid;}&:focus{outline:0;box-shadow:", " ", ";}", " ", ""], themeGet(VARIANT_COLORS.default.background), themeGet(VARIANT_COLORS.default.color), themeGet("colors.primary"), themeGet("fonts.main"), themeGet("fontWeights.2"), themeGet("radii.2"), themeGet("transition.transitionDefault"), themeGet("borderWidths.1"), props => props.disabled ? "not-allowed" : props.isLoading ? "progress" : "pointer", props => props.fullWidth ? "100%" : "auto", props => {
|
|
160
169
|
let fontSize = 2;
|
|
161
170
|
if (props.large && props.iconOnly) fontSize = 5;
|
|
162
171
|
if (props.large) fontSize = 3;
|
|
@@ -168,23 +177,23 @@ const attrs = props => ({
|
|
|
168
177
|
disabled: props.disabled || props.variant == "disabled",
|
|
169
178
|
className: `${props.className || ""} variant-${props.variant || "default"}`
|
|
170
179
|
});
|
|
171
|
-
const StyledButton = styled("button").withConfig({
|
|
172
|
-
shouldForwardProp
|
|
180
|
+
const StyledButton = /*#__PURE__*/styled("button").withConfig({
|
|
181
|
+
shouldForwardProp: customShouldForwardProp
|
|
173
182
|
}).attrs(attrs).withConfig({
|
|
174
|
-
displayName: "
|
|
183
|
+
displayName: "StyledButton",
|
|
175
184
|
componentId: "sc-10uojnk-0"
|
|
176
185
|
})(["", ""], buttonStyles);
|
|
177
|
-
const linkStyles = css(["width:", ";display:", ";align-items:", ";"], props => props.width || "fit-content", props => props.height || props.width ? "flex" : props.display || "inline-block", props => props.alignItems || "center");
|
|
178
|
-
const StyledButtonLink = styled.a.withConfig({
|
|
179
|
-
shouldForwardProp
|
|
186
|
+
const linkStyles = /*#__PURE__*/css(["width:", ";display:", ";align-items:", ";"], props => props.width || "fit-content", props => props.height || props.width ? "flex" : props.display || "inline-block", props => props.alignItems || "center");
|
|
187
|
+
const StyledButtonLink = /*#__PURE__*/styled.a.withConfig({
|
|
188
|
+
shouldForwardProp: customShouldForwardProp
|
|
180
189
|
}).attrs(attrs).withConfig({
|
|
181
|
-
displayName: "
|
|
190
|
+
displayName: "StyledButtonLink",
|
|
182
191
|
componentId: "sc-10uojnk-1"
|
|
183
192
|
})(["", " ", ""], buttonStyles, linkStyles);
|
|
184
|
-
const StyledReactButtonLink = styled(Link).withConfig({
|
|
185
|
-
shouldForwardProp
|
|
193
|
+
const StyledReactButtonLink = /*#__PURE__*/styled(Link).withConfig({
|
|
194
|
+
shouldForwardProp: customShouldForwardProp
|
|
186
195
|
}).attrs(attrs).withConfig({
|
|
187
|
-
displayName: "
|
|
196
|
+
displayName: "StyledReactButtonLink",
|
|
188
197
|
componentId: "sc-10uojnk-2"
|
|
189
198
|
})(["", " ", ""], buttonStyles, linkStyles);
|
|
190
199
|
const buttonPropTypes = {
|
|
@@ -5,8 +5,8 @@ import { themeGet } from "@styled-system/theme-get";
|
|
|
5
5
|
import Flex from "../Flex/";
|
|
6
6
|
import { css } from "@styled-system/css";
|
|
7
7
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
8
|
-
const ButtonGroupControlLabel = styled("div").withConfig({
|
|
9
|
-
displayName: "
|
|
8
|
+
const ButtonGroupControlLabel = /*#__PURE__*/styled("div").withConfig({
|
|
9
|
+
displayName: "ButtonGroupControlLabel",
|
|
10
10
|
componentId: "sc-g7627n-0"
|
|
11
11
|
})(props => css({
|
|
12
12
|
color: props.labelDark ? themeGet("colors.greyDark") : themeGet("colors.white")(props),
|
|
@@ -14,8 +14,8 @@ const ButtonGroupControlLabel = styled("div").withConfig({
|
|
|
14
14
|
fontWeight: themeGet("fontWeights.1")(props),
|
|
15
15
|
marginRight: themeGet("space.3")(props)
|
|
16
16
|
}));
|
|
17
|
-
const ButtonGroupWrapper = styled("div").withConfig({
|
|
18
|
-
displayName: "
|
|
17
|
+
const ButtonGroupWrapper = /*#__PURE__*/styled("div").withConfig({
|
|
18
|
+
displayName: "ButtonGroupWrapper",
|
|
19
19
|
componentId: "sc-g7627n-1"
|
|
20
20
|
})(props => css({
|
|
21
21
|
display: "flex",
|
|
@@ -25,10 +25,10 @@ const ButtonGroupWrapper = styled("div").withConfig({
|
|
|
25
25
|
padding: "4px",
|
|
26
26
|
height: themeGet("appScale.inputHeightDefault")(props)
|
|
27
27
|
}));
|
|
28
|
-
const ButtonGroupRadio = styled.input.attrs({
|
|
28
|
+
const ButtonGroupRadio = /*#__PURE__*/styled.input.attrs({
|
|
29
29
|
type: "radio"
|
|
30
30
|
}).withConfig({
|
|
31
|
-
displayName: "
|
|
31
|
+
displayName: "ButtonGroupRadio",
|
|
32
32
|
componentId: "sc-g7627n-2"
|
|
33
33
|
})(props => css({
|
|
34
34
|
opacity: "0",
|
|
@@ -48,8 +48,8 @@ const ButtonGroupRadio = styled.input.attrs({
|
|
|
48
48
|
}
|
|
49
49
|
}
|
|
50
50
|
}));
|
|
51
|
-
const ButtonGroupLabel = styled("label").withConfig({
|
|
52
|
-
displayName: "
|
|
51
|
+
const ButtonGroupLabel = /*#__PURE__*/styled("label").withConfig({
|
|
52
|
+
displayName: "ButtonGroupLabel",
|
|
53
53
|
componentId: "sc-g7627n-3"
|
|
54
54
|
})(props => css({
|
|
55
55
|
height: "100%",
|
|
@@ -7,16 +7,16 @@ import Flex from "../Flex/";
|
|
|
7
7
|
import { H3, H4 } from "../Typography";
|
|
8
8
|
import { themeGet } from "@styled-system/theme-get";
|
|
9
9
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
|
-
const Item = styled(Box).withConfig({
|
|
11
|
-
displayName: "
|
|
10
|
+
const Item = /*#__PURE__*/styled(Box).withConfig({
|
|
11
|
+
displayName: "Item",
|
|
12
12
|
componentId: "sc-yfq75p-0"
|
|
13
13
|
})(["word-break:break-word;"]);
|
|
14
|
-
const ChangeIcon = styled.div.withConfig({
|
|
15
|
-
displayName: "
|
|
14
|
+
const ChangeIcon = /*#__PURE__*/styled.div.withConfig({
|
|
15
|
+
displayName: "ChangeIcon",
|
|
16
16
|
componentId: "sc-yfq75p-1"
|
|
17
17
|
})(["display:inline-block;width:14px;height:2px;background-size:14px 14px;background-color:", ";margin:0 0 0 ", ";", ""], props => themeGet("colors.greyDark")(props), props => themeGet("space.3")(props), props => props.changeIcon === "arrowUp" ? css(["background-color:transparent;background-image:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' version='1.1'%3E%3Cg stroke='none' stroke-width='1' fill='none' fill-rule='evenodd'%3E%3Cg transform='translate(-1173.000000, -214.000000)' fill='%2378797D'%3E%3Cg transform='translate(1173.000000, 210.000000)'%3E%3Cpath d='M0.1 12.1L0.8 12.8C1 13 1.3 13 1.4 12.8L6.9 7.3 6.9 19.4C6.9 19.6 7.1 19.8 7.3 19.8L8.3 19.8C8.6 19.8 8.8 19.6 8.8 19.4L8.8 7.3 14.3 12.8C14.4 13 14.7 13 14.9 12.8L15.6 12.1C15.7 11.9 15.7 11.7 15.6 11.5L8.1 4.1C8 4 7.7 4 7.5 4.1L0.1 11.5C0 11.7 0 11.9 0.1 12.1Z'/%3E%3C/g%3E%3C/g%3E%3C/g%3E%3C/svg%3E\");height:14px;"]) : props.changeIcon === "arrowDown" ? css(["background-color:transparent;background-image:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' version='1.1'%3E%3Cg stroke='none' stroke-width='1' fill='none' fill-rule='evenodd'%3E%3Cg transform='translate(-1173.000000, -214.000000)' fill='%2378797D'%3E%3Cg transform='translate(1173.000000, 210.000000)'%3E%3Cpath d='M0.1 12.1L0.8 12.8C1 13 1.3 13 1.4 12.8L6.9 7.3 6.9 19.4C6.9 19.6 7.1 19.8 7.3 19.8L8.3 19.8C8.6 19.8 8.8 19.6 8.8 19.4L8.8 7.3 14.3 12.8C14.4 13 14.7 13 14.9 12.8L15.6 12.1C15.7 11.9 15.7 11.7 15.6 11.5L8.1 4.1C8 4 7.7 4 7.5 4.1L0.1 11.5C0 11.7 0 11.9 0.1 12.1Z'/%3E%3C/g%3E%3C/g%3E%3C/g%3E%3C/svg%3E\");height:14px;transform:rotate(180deg);"]) : css([""]));
|
|
18
|
-
const ChangeValue = styled.small.withConfig({
|
|
19
|
-
displayName: "
|
|
18
|
+
const ChangeValue = /*#__PURE__*/styled.small.withConfig({
|
|
19
|
+
displayName: "ChangeValue",
|
|
20
20
|
componentId: "sc-yfq75p-2"
|
|
21
21
|
})(["display:flex;align-items:center;font-size:", ";font-weight:", ";color:", ";margin:0 0 0 ", ";"], props => themeGet("fontSizes.2")(props), props => themeGet("fontWeights.0")(props), props => themeGet("colors.greyDark")(props), props => themeGet("space.3")(props));
|
|
22
22
|
|