@citygross/components 0.7.224 → 0.7.226

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.
@@ -1,3 +1,4 @@
1
- export declare const HeaderLinkContainer: import("styled-components").StyledComponent<"a", import("styled-components").DefaultTheme, {}, never>;
1
+ import { Link } from '../Links/Link';
2
+ export declare const HeaderLinkContainer: import("styled-components").StyledComponent<typeof Link, import("styled-components").DefaultTheme, {}, never>;
2
3
  export declare const TextContainer: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
3
4
  export declare const ArrowLeft: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
@@ -20,6 +20,8 @@ export declare type TLink = {
20
20
  icon?: JSX.Element;
21
21
  textDecoration?: 'none' | 'underline';
22
22
  target?: '_self' | '_blank';
23
+ borderRadius?: number;
23
24
  tabIndex?: number;
25
+ inverted?: boolean;
24
26
  };
25
- export declare function Link({ center, color, isDisabled, noWrap, onClick, hrefPath, icon, textDecoration, size, target, tabIndex, children }: TLink): JSX.Element;
27
+ export declare function Link({ center, color, isDisabled, noWrap, onClick, hrefPath, icon, textDecoration, size, target, borderRadius, tabIndex, inverted, children, ...props }: TLink): JSX.Element;
@@ -1,5 +1,6 @@
1
1
  import { TLink } from './Link';
2
2
  export declare const BaseLink: import("styled-components").StyledComponent<"a", import("styled-components").DefaultTheme, Omit<TLink, "color"> & {
3
3
  color: string;
4
+ borderRadius?: number | undefined;
4
5
  }, never>;
5
6
  export declare const IconWrapper: import("styled-components").StyledComponent<"span", import("styled-components").DefaultTheme, {}, never>;
@@ -4,6 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var React = require('react');
6
6
  var HeaderLink_styles = require('./HeaderLink.styles.js');
7
+ var typography = require('@citygross/typography');
7
8
 
8
9
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
9
10
 
@@ -11,7 +12,7 @@ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
11
12
 
12
13
  function HeaderLink(_a) {
13
14
  var linkHref = _a.linkHref, icon = _a.icon, linkLabel = _a.linkLabel;
14
- return (React__default["default"].createElement(HeaderLink_styles.HeaderLinkContainer, { href: linkHref },
15
+ return (React__default["default"].createElement(HeaderLink_styles.HeaderLinkContainer, { hrefPath: linkHref, size: typography.TextTypes.TextSize.SMALL, borderRadius: 0, inverted: true },
15
16
  React__default["default"].createElement(HeaderLink_styles.TextContainer, null,
16
17
  React__default["default"].createElement(HeaderLink_styles.ArrowLeft, null, icon),
17
18
  linkLabel)));
@@ -1 +1 @@
1
- {"version":3,"file":"HeaderLink.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"HeaderLink.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;"}
@@ -4,12 +4,13 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var _tslib = require('../../../../_virtual/_tslib.js');
6
6
  var styled = require('styled-components');
7
+ var Link = require('../Links/Link.js');
7
8
 
8
9
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
9
10
 
10
11
  var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
11
12
 
12
- var HeaderLinkContainer = styled__default["default"].a(templateObject_1 || (templateObject_1 = _tslib.__makeTemplateObject(["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n text-decoration: none;\n line-height: ", "px;\n"], ["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n text-decoration: none;\n line-height: ", "px;\n"])), function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.darker; }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.white; }, function (props) { var _a, _b; return "".concat((_a = props.theme.spacings) === null || _a === void 0 ? void 0 : _a.xs, "px ").concat((_b = props.theme.spacings) === null || _b === void 0 ? void 0 : _b.md, "px"); }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.size.s2; }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.lineHeight.s2; });
13
+ var HeaderLinkContainer = styled__default["default"](Link.Link)(templateObject_1 || (templateObject_1 = _tslib.__makeTemplateObject(["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n line-height: ", "px;\n"], ["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n line-height: ", "px;\n"])), function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.darker; }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.white; }, function (props) { var _a, _b; return "".concat((_a = props.theme.spacings) === null || _a === void 0 ? void 0 : _a.xs, "px ").concat((_b = props.theme.spacings) === null || _b === void 0 ? void 0 : _b.md, "px"); }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.size.s2; }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.lineHeight.s2; });
13
14
  var TextContainer = styled__default["default"].div(templateObject_2 || (templateObject_2 = _tslib.__makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
14
15
  var ArrowLeft = styled__default["default"].div(templateObject_3 || (templateObject_3 = _tslib.__makeTemplateObject(["\n display: flex;\n margin-right: ", "px;\n align-self: center;\n"], ["\n display: flex;\n margin-right: ", "px;\n align-self: center;\n"])), function (props) { var _a; return (_a = props.theme.spacings) === null || _a === void 0 ? void 0 : _a.xs; });
15
16
  var templateObject_1, templateObject_2, templateObject_3;
@@ -1 +1 @@
1
- {"version":3,"file":"HeaderLink.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"HeaderLink.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;"}
@@ -2,6 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
+ var _tslib = require('../../../../_virtual/_tslib.js');
5
6
  var React = require('react');
6
7
  var designTokens = require('@citygross/design-tokens');
7
8
  var typography = require('@citygross/typography');
@@ -22,8 +23,8 @@ exports.LinkColors = void 0;
22
23
  LinkColors[LinkColors["black"] = 1] = "black";
23
24
  })(exports.LinkColors || (exports.LinkColors = {}));
24
25
  function Link(_a) {
25
- var _b = _a.center, center = _b === void 0 ? true : _b, _c = _a.color, color = _c === void 0 ? 'link' : _c, isDisabled = _a.isDisabled, noWrap = _a.noWrap, onClick = _a.onClick, hrefPath = _a.hrefPath, icon = _a.icon, _d = _a.textDecoration, textDecoration = _d === void 0 ? 'none' : _d, _e = _a.size, size = _e === void 0 ? typography.TextTypes.TextSize.REGULAR : _e, _f = _a.target, target = _f === void 0 ? '_self' : _f, _g = _a.tabIndex, tabIndex = _g === void 0 ? 0 : _g, children = _a.children;
26
- return (React__default["default"].createElement(Link_styles.BaseLink, { center: center, tabIndex: isDisabled ? -1 : tabIndex, color: designTokens.theme && designTokens.theme.palette ? designTokens.theme === null || designTokens.theme === void 0 ? void 0 : designTokens.theme.palette[color] : 'black', href: hrefPath, isDisabled: isDisabled, textDecoration: textDecoration, noWrap: noWrap, onClick: onClick, size: size, icon: icon, target: target },
26
+ var _b = _a.center, center = _b === void 0 ? true : _b, _c = _a.color, color = _c === void 0 ? 'link' : _c, isDisabled = _a.isDisabled, noWrap = _a.noWrap, onClick = _a.onClick, hrefPath = _a.hrefPath, icon = _a.icon, _d = _a.textDecoration, textDecoration = _d === void 0 ? 'none' : _d, _e = _a.size, size = _e === void 0 ? typography.TextTypes.TextSize.REGULAR : _e, _f = _a.target, target = _f === void 0 ? '_self' : _f, borderRadius = _a.borderRadius, _g = _a.tabIndex, tabIndex = _g === void 0 ? 0 : _g, _h = _a.inverted, inverted = _h === void 0 ? false : _h, children = _a.children, props = _tslib.__rest(_a, ["center", "color", "isDisabled", "noWrap", "onClick", "hrefPath", "icon", "textDecoration", "size", "target", "borderRadius", "tabIndex", "inverted", "children"]);
27
+ return (React__default["default"].createElement(Link_styles.BaseLink, _tslib.__assign({ center: center, tabIndex: isDisabled ? -1 : tabIndex, color: designTokens.theme && designTokens.theme.palette ? designTokens.theme === null || designTokens.theme === void 0 ? void 0 : designTokens.theme.palette[color] : 'black', href: hrefPath, isDisabled: isDisabled, textDecoration: textDecoration, noWrap: noWrap, onClick: onClick, size: size, icon: icon, borderRadius: borderRadius, inverted: inverted, target: target }, props),
27
28
  React__default["default"].createElement(typography.LinkText, { size: size }, children),
28
29
  icon && React__default["default"].createElement(Link_styles.IconWrapper, null, icon)));
29
30
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Link.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"Link.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -9,7 +9,18 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
9
9
 
10
10
  var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
11
11
 
12
- var BaseLink = styled__default["default"].a(templateObject_1 || (templateObject_1 = _tslib.__makeTemplateObject(["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus {\n outline: 3px solid ", ";\n }\n"], ["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus {\n outline: 3px solid ", ";\n }\n"])), function (props) { return props.isDisabled && 'none'; }, function (props) { return (props.isDisabled ? 'none' : 'all'); }, function (props) { return props.textDecoration; }, function (props) { var _a; return props.isDisabled ? (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.medium : props.color; }, function (props) {
12
+ var BaseLink = styled__default["default"].a(templateObject_1 || (templateObject_1 = _tslib.__makeTemplateObject(["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus-visible {\n outline: 3px solid ", ";\n }\n"], ["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus-visible {\n outline: 3px solid ", ";\n }\n"])), function (props) { return props.isDisabled && 'none'; }, function (props) { return (props.isDisabled ? 'none' : 'all'); }, function (props) { return props.textDecoration; }, function (props) {
13
+ var _a, _b, _c, _d;
14
+ return props.inverted
15
+ ? (props === null || props === void 0 ? void 0 : props.isDisabled)
16
+ ? (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.disabledGray
17
+ : (_b = props.theme.palette) === null || _b === void 0 ? void 0 : _b.white
18
+ : (props === null || props === void 0 ? void 0 : props.isDisabled)
19
+ ? props.color === 'link'
20
+ ? (_c = props.theme.palette) === null || _c === void 0 ? void 0 : _c.blueMedium
21
+ : (_d = props.theme.palette) === null || _d === void 0 ? void 0 : _d.disabledGray
22
+ : props.color;
23
+ }, function (props) {
13
24
  var _a, _b;
14
25
  return props.size === 'small'
15
26
  ? ((_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.lineHeight.s2) + 'px'
@@ -23,7 +34,12 @@ var BaseLink = styled__default["default"].a(templateObject_1 || (templateObject_
23
34
  : props.textDecoration === 'underline'
24
35
  ? 'none'
25
36
  : 'underline';
26
- }, function (props) { var _a; return (_a = props.theme.attributes) === null || _a === void 0 ? void 0 : _a.borderRadius.small; }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.blueMedium; });
37
+ }, function (props) {
38
+ var _a;
39
+ return (props === null || props === void 0 ? void 0 : props.borderRadius) || (props === null || props === void 0 ? void 0 : props.borderRadius) === 0
40
+ ? props.borderRadius
41
+ : (_a = props.theme.attributes) === null || _a === void 0 ? void 0 : _a.borderRadius.small;
42
+ }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.blueMedium; });
27
43
  var IconWrapper = styled__default["default"].span(templateObject_2 || (templateObject_2 = _tslib.__makeTemplateObject(["\n display: flex;\n flex: 1;\n justify-content: flex-end;\n"], ["\n display: flex;\n flex: 1;\n justify-content: flex-end;\n"])));
28
44
  var templateObject_1, templateObject_2;
29
45
 
@@ -1 +1 @@
1
- {"version":3,"file":"Link.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"Link.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,9 +1,10 @@
1
1
  import React from 'react';
2
2
  import { HeaderLinkContainer, TextContainer, ArrowLeft } from './HeaderLink.styles.js';
3
+ import { TextTypes } from '@citygross/typography';
3
4
 
4
5
  function HeaderLink(_a) {
5
6
  var linkHref = _a.linkHref, icon = _a.icon, linkLabel = _a.linkLabel;
6
- return (React.createElement(HeaderLinkContainer, { href: linkHref },
7
+ return (React.createElement(HeaderLinkContainer, { hrefPath: linkHref, size: TextTypes.TextSize.SMALL, borderRadius: 0, inverted: true },
7
8
  React.createElement(TextContainer, null,
8
9
  React.createElement(ArrowLeft, null, icon),
9
10
  linkLabel)));
@@ -1 +1 @@
1
- {"version":3,"file":"HeaderLink.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;"}
1
+ {"version":3,"file":"HeaderLink.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;"}
@@ -1,7 +1,8 @@
1
1
  import { __makeTemplateObject } from '../../../../_virtual/_tslib.js';
2
2
  import styled from 'styled-components';
3
+ import { Link } from '../Links/Link.js';
3
4
 
4
- var HeaderLinkContainer = styled.a(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n text-decoration: none;\n line-height: ", "px;\n"], ["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n text-decoration: none;\n line-height: ", "px;\n"])), function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.darker; }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.white; }, function (props) { var _a, _b; return "".concat((_a = props.theme.spacings) === null || _a === void 0 ? void 0 : _a.xs, "px ").concat((_b = props.theme.spacings) === null || _b === void 0 ? void 0 : _b.md, "px"); }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.size.s2; }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.lineHeight.s2; });
5
+ var HeaderLinkContainer = styled(Link)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n line-height: ", "px;\n"], ["\n display: block;\n background: ", ";\n color: ", ";\n padding: ", ";\n font-size: ", "px;\n line-height: ", "px;\n"])), function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.darker; }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.white; }, function (props) { var _a, _b; return "".concat((_a = props.theme.spacings) === null || _a === void 0 ? void 0 : _a.xs, "px ").concat((_b = props.theme.spacings) === null || _b === void 0 ? void 0 : _b.md, "px"); }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.size.s2; }, function (props) { var _a; return (_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.lineHeight.s2; });
5
6
  var TextContainer = styled.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
6
7
  var ArrowLeft = styled.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n display: flex;\n margin-right: ", "px;\n align-self: center;\n"], ["\n display: flex;\n margin-right: ", "px;\n align-self: center;\n"])), function (props) { var _a; return (_a = props.theme.spacings) === null || _a === void 0 ? void 0 : _a.xs; });
7
8
  var templateObject_1, templateObject_2, templateObject_3;
@@ -1 +1 @@
1
- {"version":3,"file":"HeaderLink.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;"}
1
+ {"version":3,"file":"HeaderLink.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;"}
@@ -1,3 +1,4 @@
1
+ import { __rest, __assign } from '../../../../_virtual/_tslib.js';
1
2
  import React from 'react';
2
3
  import { theme } from '@citygross/design-tokens';
3
4
  import { TextTypes, LinkText } from '@citygross/typography';
@@ -14,8 +15,8 @@ var LinkColors;
14
15
  LinkColors[LinkColors["black"] = 1] = "black";
15
16
  })(LinkColors || (LinkColors = {}));
16
17
  function Link(_a) {
17
- var _b = _a.center, center = _b === void 0 ? true : _b, _c = _a.color, color = _c === void 0 ? 'link' : _c, isDisabled = _a.isDisabled, noWrap = _a.noWrap, onClick = _a.onClick, hrefPath = _a.hrefPath, icon = _a.icon, _d = _a.textDecoration, textDecoration = _d === void 0 ? 'none' : _d, _e = _a.size, size = _e === void 0 ? TextTypes.TextSize.REGULAR : _e, _f = _a.target, target = _f === void 0 ? '_self' : _f, _g = _a.tabIndex, tabIndex = _g === void 0 ? 0 : _g, children = _a.children;
18
- return (React.createElement(BaseLink, { center: center, tabIndex: isDisabled ? -1 : tabIndex, color: theme && theme.palette ? theme === null || theme === void 0 ? void 0 : theme.palette[color] : 'black', href: hrefPath, isDisabled: isDisabled, textDecoration: textDecoration, noWrap: noWrap, onClick: onClick, size: size, icon: icon, target: target },
18
+ var _b = _a.center, center = _b === void 0 ? true : _b, _c = _a.color, color = _c === void 0 ? 'link' : _c, isDisabled = _a.isDisabled, noWrap = _a.noWrap, onClick = _a.onClick, hrefPath = _a.hrefPath, icon = _a.icon, _d = _a.textDecoration, textDecoration = _d === void 0 ? 'none' : _d, _e = _a.size, size = _e === void 0 ? TextTypes.TextSize.REGULAR : _e, _f = _a.target, target = _f === void 0 ? '_self' : _f, borderRadius = _a.borderRadius, _g = _a.tabIndex, tabIndex = _g === void 0 ? 0 : _g, _h = _a.inverted, inverted = _h === void 0 ? false : _h, children = _a.children, props = __rest(_a, ["center", "color", "isDisabled", "noWrap", "onClick", "hrefPath", "icon", "textDecoration", "size", "target", "borderRadius", "tabIndex", "inverted", "children"]);
19
+ return (React.createElement(BaseLink, __assign({ center: center, tabIndex: isDisabled ? -1 : tabIndex, color: theme && theme.palette ? theme === null || theme === void 0 ? void 0 : theme.palette[color] : 'black', href: hrefPath, isDisabled: isDisabled, textDecoration: textDecoration, noWrap: noWrap, onClick: onClick, size: size, icon: icon, borderRadius: borderRadius, inverted: inverted, target: target }, props),
19
20
  React.createElement(LinkText, { size: size }, children),
20
21
  icon && React.createElement(IconWrapper, null, icon)));
21
22
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Link.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"Link.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,7 +1,18 @@
1
1
  import { __makeTemplateObject } from '../../../../_virtual/_tslib.js';
2
2
  import styled from 'styled-components';
3
3
 
4
- var BaseLink = styled.a(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus {\n outline: 3px solid ", ";\n }\n"], ["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus {\n outline: 3px solid ", ";\n }\n"])), function (props) { return props.isDisabled && 'none'; }, function (props) { return (props.isDisabled ? 'none' : 'all'); }, function (props) { return props.textDecoration; }, function (props) { var _a; return props.isDisabled ? (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.medium : props.color; }, function (props) {
4
+ var BaseLink = styled.a(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus-visible {\n outline: 3px solid ", ";\n }\n"], ["\n user-select: ", ";\n pointer-events: ", ";\n cursor: pointer;\n text-decoration: ", ";\n\n /* typography */\n color: ", ";\n line-height: ", ";\n white-space: ", ";\n ", "\n\n &:hover {\n text-decoration: ", ";\n }\n border-radius: ", "px;\n &:focus-visible {\n outline: 3px solid ", ";\n }\n"])), function (props) { return props.isDisabled && 'none'; }, function (props) { return (props.isDisabled ? 'none' : 'all'); }, function (props) { return props.textDecoration; }, function (props) {
5
+ var _a, _b, _c, _d;
6
+ return props.inverted
7
+ ? (props === null || props === void 0 ? void 0 : props.isDisabled)
8
+ ? (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.disabledGray
9
+ : (_b = props.theme.palette) === null || _b === void 0 ? void 0 : _b.white
10
+ : (props === null || props === void 0 ? void 0 : props.isDisabled)
11
+ ? props.color === 'link'
12
+ ? (_c = props.theme.palette) === null || _c === void 0 ? void 0 : _c.blueMedium
13
+ : (_d = props.theme.palette) === null || _d === void 0 ? void 0 : _d.disabledGray
14
+ : props.color;
15
+ }, function (props) {
5
16
  var _a, _b;
6
17
  return props.size === 'small'
7
18
  ? ((_a = props.theme.typography) === null || _a === void 0 ? void 0 : _a.lineHeight.s2) + 'px'
@@ -15,7 +26,12 @@ var BaseLink = styled.a(templateObject_1 || (templateObject_1 = __makeTemplateOb
15
26
  : props.textDecoration === 'underline'
16
27
  ? 'none'
17
28
  : 'underline';
18
- }, function (props) { var _a; return (_a = props.theme.attributes) === null || _a === void 0 ? void 0 : _a.borderRadius.small; }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.blueMedium; });
29
+ }, function (props) {
30
+ var _a;
31
+ return (props === null || props === void 0 ? void 0 : props.borderRadius) || (props === null || props === void 0 ? void 0 : props.borderRadius) === 0
32
+ ? props.borderRadius
33
+ : (_a = props.theme.attributes) === null || _a === void 0 ? void 0 : _a.borderRadius.small;
34
+ }, function (props) { var _a; return (_a = props.theme.palette) === null || _a === void 0 ? void 0 : _a.blueMedium; });
19
35
  var IconWrapper = styled.span(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n display: flex;\n flex: 1;\n justify-content: flex-end;\n"], ["\n display: flex;\n flex: 1;\n justify-content: flex-end;\n"])));
20
36
  var templateObject_1, templateObject_2;
21
37
 
@@ -1 +1 @@
1
- {"version":3,"file":"Link.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"Link.styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@citygross/components",
3
- "version": "0.7.224",
3
+ "version": "0.7.226",
4
4
  "license": "ISC",
5
5
  "sideEffects": false,
6
6
  "main": "./build/cjs/components/src/index.js",
@@ -74,5 +74,5 @@
74
74
  "react-slick": "^0.30.1",
75
75
  "slick-carousel": "^1.8.1"
76
76
  },
77
- "gitHead": "312f26673d6d9aaa68cbf82541dd4bd059932cf2"
77
+ "gitHead": "a52c00135abce03a6e8ee82b390e26b618adcdc3"
78
78
  }