@janiscommerce/ui-web 0.2.1 → 0.4.0
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/index.umd.js +3 -8
- package/index.umd.js.map +1 -1
- package/package.json +1 -1
package/index.umd.js
CHANGED
|
@@ -20282,7 +20282,7 @@
|
|
|
20282
20282
|
})(["text-overflow:ellipsis;overflow:hidden;"])
|
|
20283
20283
|
};
|
|
20284
20284
|
|
|
20285
|
-
var _excluded$4 = ["backgroundColor", "borderColor", "children", "disabled", "icon", "iconColor", "onClick", "onDelete", "selected", "
|
|
20285
|
+
var _excluded$4 = ["backgroundColor", "borderColor", "children", "disabled", "icon", "iconColor", "onClick", "onDelete", "selected", "textColor", "variant", "hasLink"];
|
|
20286
20286
|
|
|
20287
20287
|
var Chip = function Chip(_ref) {
|
|
20288
20288
|
var backgroundColor = _ref.backgroundColor,
|
|
@@ -20294,7 +20294,6 @@
|
|
|
20294
20294
|
onClick = _ref.onClick,
|
|
20295
20295
|
onDelete = _ref.onDelete,
|
|
20296
20296
|
selected = _ref.selected,
|
|
20297
|
-
styles = _ref.styles,
|
|
20298
20297
|
textColor = _ref.textColor,
|
|
20299
20298
|
variant = _ref.variant,
|
|
20300
20299
|
hasLink = _ref.hasLink,
|
|
@@ -20310,7 +20309,6 @@
|
|
|
20310
20309
|
clickable: (onClick || onDelete) && !disabled,
|
|
20311
20310
|
onClick: disabled ? undefined : onClick,
|
|
20312
20311
|
selected: selected,
|
|
20313
|
-
styles: styles,
|
|
20314
20312
|
textColor: textColor,
|
|
20315
20313
|
variant: variant,
|
|
20316
20314
|
iconColor: iconColor,
|
|
@@ -22466,19 +22464,16 @@
|
|
|
22466
22464
|
icon = _ref.icon,
|
|
22467
22465
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
22468
22466
|
|
|
22469
|
-
if (href.startsWith('/')) return;
|
|
22470
|
-
|
|
22471
22467
|
var renderIcon = function renderIcon() {
|
|
22472
22468
|
return icon ? /*#__PURE__*/React__default["default"].createElement(styled.StyledIcon, {
|
|
22473
22469
|
name: icon
|
|
22474
22470
|
}) : null;
|
|
22475
22471
|
};
|
|
22476
22472
|
|
|
22477
|
-
var validHref = href.startsWith('http') ? href : "https://".concat(href);
|
|
22478
22473
|
return /*#__PURE__*/React__default["default"].createElement(styled.LinkWrapper, props, renderIcon(), /*#__PURE__*/React__default["default"].createElement("a", {
|
|
22479
|
-
href:
|
|
22474
|
+
href: href,
|
|
22480
22475
|
target: target
|
|
22481
|
-
}, children ||
|
|
22476
|
+
}, children || href));
|
|
22482
22477
|
};
|
|
22483
22478
|
|
|
22484
22479
|
Link.defaultProps = {
|