@clayui/button
Advanced tools
Comparing version 3.73.0 to 3.81.0
@@ -12,2 +12,4 @@ "use strict"; | ||
var _warning = _interopRequireDefault(require("warning")); | ||
var _Group = _interopRequireDefault(require("./Group")); | ||
@@ -28,3 +30,3 @@ | ||
var ClayButton = /*#__PURE__*/_react.default.forwardRef(function (_ref, ref) { | ||
var _classNames; | ||
var _childArray$0$type, _classNames; | ||
@@ -47,2 +49,6 @@ var alert = _ref.alert, | ||
var childArray = _react.default.Children.toArray(children); | ||
undefined !== "production" ? (0, _warning.default)(!(childArray.length === 1 && // @ts-ignore | ||
((_childArray$0$type = childArray[0].type) === null || _childArray$0$type === void 0 ? void 0 : _childArray$0$type.displayName) === 'ClayIcon' && typeof otherProps['aria-label'] !== 'string'), 'Button accessibility: component has only the Icon declared, defines an `aria-label` or `title` (consult your design team) attribute that labels the interactive button that screen readers can read.') : void 0; | ||
return /*#__PURE__*/_react.default.createElement("button", _extends({ | ||
@@ -49,0 +55,0 @@ className: (0, _classnames.default)(className, 'btn', (_classNames = { |
@@ -9,2 +9,6 @@ /** | ||
/** | ||
* Define a value that labels the button. | ||
*/ | ||
'aria-label': string; | ||
/** | ||
* Path to the location of the spritemap resource. | ||
@@ -11,0 +15,0 @@ */ |
{ | ||
"name": "@clayui/button", | ||
"version": "3.73.0", | ||
"version": "3.81.0", | ||
"description": "ClayButton component", | ||
@@ -30,3 +30,4 @@ "license": "BSD-3-Clause", | ||
"@clayui/icon": "^3.56.0", | ||
"classnames": "^2.2.6" | ||
"classnames": "^2.2.6", | ||
"warning": "^4.0.3" | ||
}, | ||
@@ -41,3 +42,3 @@ "peerDependencies": { | ||
], | ||
"gitHead": "a7e4596d46eb4790f06b719afd5bff5602e4123f" | ||
"gitHead": "ad8ecdbfe060ad7cec1128fb3d252bb660289519" | ||
} |
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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
28374
542
6
+ Addedwarning@^4.0.3