New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@entur/button

Package Overview
Dependencies
Maintainers
13
Versions
169
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@entur/button - npm Package Compare versions

Comparing version 2.10.6 to 2.10.7

CHANGELOG.md

86

dist/button.cjs.development.js

@@ -38,2 +38,3 @@ 'use strict';

var source = arguments[i];
for (var key in source) {

@@ -45,6 +46,9 @@ if (Object.prototype.hasOwnProperty.call(source, key)) {

}
return target;
};
return _extends.apply(this, arguments);
}
function _objectWithoutPropertiesLoose(source, excluded) {

@@ -55,2 +59,3 @@ if (source == null) return {};

var key, i;
for (i = 0; i < sourceKeys.length; i++) {

@@ -61,2 +66,3 @@ key = sourceKeys[i];

}
return target;

@@ -69,15 +75,17 @@ }

var _cx;
var as = _ref.as,
variant = _ref.variant,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
loading = _ref.loading,
className = _ref.className,
children = _ref.children,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$width = _ref.width,
width = _ref$width === void 0 ? 'auto' : _ref$width,
ariaLabel = _ref['aria-label'],
rest = _objectWithoutPropertiesLoose(_ref, _excluded$4);
variant = _ref.variant,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
loading = _ref.loading,
className = _ref.className,
children = _ref.children,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$width = _ref.width,
width = _ref$width === void 0 ? 'auto' : _ref$width,
ariaLabel = _ref['aria-label'],
rest = _objectWithoutPropertiesLoose(_ref, _excluded$4);
var Element = as || defaultElement$a;

@@ -90,2 +98,3 @@ var childrenArray = React__namespace.Children.toArray(children);

}).join(' ');
var ariaLabelValue = function ariaLabelValue() {

@@ -96,2 +105,3 @@ if (ariaLabel) return ariaLabel;

};
return React__namespace.createElement(Element, _extends({

@@ -167,5 +177,6 @@ className: classNames__default["default"]('eds-button', (_cx = {}, _cx["eds-button--variant-" + variant] = variant, _cx["eds-button--size-" + size] = size, _cx['eds-button--width-fluid'] = width === 'fluid', _cx['eds-button--loading'] = loading, _cx['eds-button--leading-icon'] = hasLeadingIcon, _cx['eds-button--trailing-icon'] = hasTrailingIcon, _cx), className),

var _ref$as = _ref.as,
Element = _ref$as === void 0 ? 'div' : _ref$as,
className = _ref.className,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$3);
Element = _ref$as === void 0 ? 'div' : _ref$as,
className = _ref.className,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$3);
return React__default["default"].createElement(Element, _extends({

@@ -179,6 +190,7 @@ className: classNames__default["default"]('eds-button-group', className)

var className = _ref.className,
children = _ref.children,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$2);
children = _ref.children,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$2);
return React__default["default"].createElement("button", _extends({

@@ -193,2 +205,3 @@ className: classNames__default["default"]('eds-floating-button', {

};
var wrapStringsInSpans = function wrapStringsInSpans(children) {

@@ -204,10 +217,11 @@ return React__default["default"].Children.map(children, function (child) {

var children = _ref.children,
className = _ref.className,
variant = _ref.variant,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$loading = _ref.loading,
loading = _ref$loading === void 0 ? false : _ref$loading,
as = _ref.as,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$1);
className = _ref.className,
variant = _ref.variant,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$loading = _ref.loading,
loading = _ref$loading === void 0 ? false : _ref$loading,
as = _ref.as,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$1);
var Element = as || defaultElement$4;

@@ -234,2 +248,3 @@ return React__namespace.createElement(Element, _extends({

}
return React__namespace.createElement("span", {

@@ -280,9 +295,10 @@ className: "eds-square-button__icon"

var children = _ref.children,
className = _ref.className,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
size = _ref.size,
as = _ref.as,
loading = _ref.loading,
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
className = _ref.className,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
size = _ref.size,
as = _ref.as,
loading = _ref.loading,
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
var Element = as || defaultElement;

@@ -298,2 +314,3 @@ var iconButtonElement = React__default["default"].createElement(Element, _extends({

}, rest), loading ? React__default["default"].createElement(loader.LoadingDots, null) : children);
if (disabled) {

@@ -304,2 +321,3 @@ return React__default["default"].createElement("div", {

}
return React__default["default"].createElement(React__default["default"].Fragment, null, iconButtonElement);

@@ -306,0 +324,0 @@ });

@@ -11,2 +11,3 @@ import { warnAboutMissingStyles } from '@entur/utils';

var source = arguments[i];
for (var key in source) {

@@ -18,6 +19,9 @@ if (Object.prototype.hasOwnProperty.call(source, key)) {

}
return target;
};
return _extends.apply(this, arguments);
}
function _objectWithoutPropertiesLoose(source, excluded) {

@@ -28,2 +32,3 @@ if (source == null) return {};

var key, i;
for (i = 0; i < sourceKeys.length; i++) {

@@ -34,2 +39,3 @@ key = sourceKeys[i];

}
return target;

@@ -42,15 +48,17 @@ }

var _cx;
var as = _ref.as,
variant = _ref.variant,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
loading = _ref.loading,
className = _ref.className,
children = _ref.children,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$width = _ref.width,
width = _ref$width === void 0 ? 'auto' : _ref$width,
ariaLabel = _ref['aria-label'],
rest = _objectWithoutPropertiesLoose(_ref, _excluded$4);
variant = _ref.variant,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
loading = _ref.loading,
className = _ref.className,
children = _ref.children,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$width = _ref.width,
width = _ref$width === void 0 ? 'auto' : _ref$width,
ariaLabel = _ref['aria-label'],
rest = _objectWithoutPropertiesLoose(_ref, _excluded$4);
var Element = as || defaultElement$a;

@@ -63,2 +71,3 @@ var childrenArray = React.Children.toArray(children);

}).join(' ');
var ariaLabelValue = function ariaLabelValue() {

@@ -69,2 +78,3 @@ if (ariaLabel) return ariaLabel;

};
return React.createElement(Element, _extends({

@@ -140,5 +150,6 @@ className: classNames('eds-button', (_cx = {}, _cx["eds-button--variant-" + variant] = variant, _cx["eds-button--size-" + size] = size, _cx['eds-button--width-fluid'] = width === 'fluid', _cx['eds-button--loading'] = loading, _cx['eds-button--leading-icon'] = hasLeadingIcon, _cx['eds-button--trailing-icon'] = hasTrailingIcon, _cx), className),

var _ref$as = _ref.as,
Element = _ref$as === void 0 ? 'div' : _ref$as,
className = _ref.className,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$3);
Element = _ref$as === void 0 ? 'div' : _ref$as,
className = _ref.className,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$3);
return React__default.createElement(Element, _extends({

@@ -152,6 +163,7 @@ className: classNames('eds-button-group', className)

var className = _ref.className,
children = _ref.children,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$2);
children = _ref.children,
_ref$size = _ref.size,
size = _ref$size === void 0 ? 'medium' : _ref$size,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$2);
return React__default.createElement("button", _extends({

@@ -166,2 +178,3 @@ className: classNames('eds-floating-button', {

};
var wrapStringsInSpans = function wrapStringsInSpans(children) {

@@ -177,10 +190,11 @@ return React__default.Children.map(children, function (child) {

var children = _ref.children,
className = _ref.className,
variant = _ref.variant,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$loading = _ref.loading,
loading = _ref$loading === void 0 ? false : _ref$loading,
as = _ref.as,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$1);
className = _ref.className,
variant = _ref.variant,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
_ref$loading = _ref.loading,
loading = _ref$loading === void 0 ? false : _ref$loading,
as = _ref.as,
rest = _objectWithoutPropertiesLoose(_ref, _excluded$1);
var Element = as || defaultElement$4;

@@ -207,2 +221,3 @@ return React.createElement(Element, _extends({

}
return React.createElement("span", {

@@ -253,9 +268,10 @@ className: "eds-square-button__icon"

var children = _ref.children,
className = _ref.className,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
size = _ref.size,
as = _ref.as,
loading = _ref.loading,
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
className = _ref.className,
_ref$disabled = _ref.disabled,
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
size = _ref.size,
as = _ref.as,
loading = _ref.loading,
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
var Element = as || defaultElement;

@@ -271,2 +287,3 @@ var iconButtonElement = React__default.createElement(Element, _extends({

}, rest), loading ? React__default.createElement(LoadingDots, null) : children);
if (disabled) {

@@ -277,2 +294,3 @@ return React__default.createElement("div", {

}
return React__default.createElement(React__default.Fragment, null, iconButtonElement);

@@ -279,0 +297,0 @@ });

{
"name": "@entur/button",
"version": "2.10.6",
"version": "2.10.7",
"license": "EUPL-1.2",

@@ -20,6 +20,6 @@ "main": "dist/index.js",

"scripts": {
"start": "yarn run dts watch --noClean",
"build": "yarn run dts build",
"test": "yarn run dts test --env=jsdom",
"lint": "yarn run dts lint"
"start": "dts watch --noClean",
"build": "dts build",
"test": "dts test --env=jsdom",
"lint": "dts lint"
},

@@ -31,15 +31,10 @@ "peerDependencies": {

"dependencies": {
"@entur/loader": "^0.4.14",
"@entur/utils": "^0.4.7",
"@entur/loader": "^0.4.15",
"@entur/utils": "^0.4.8",
"classnames": "^2.3.1"
},
"devDependencies": {
"@entur/tokens": "^3.4.2",
"dts-cli": "^1.1.6",
"jest": "^27.0.0",
"jest-watch-typeahead": "^2.2.0",
"ts-jest": "^27.0.0",
"typescript": "^4.8.0"
"@entur/tokens": "^3.4.3"
},
"gitHead": "8915b1630bd936740ba9a4a88883f3432948a80e"
"gitHead": "103844c30bdc32296f3998a360cf6066492173e9"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc