@popmenu/common-ui 0.87.0 → 0.88.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/build/index.js CHANGED
@@ -438,7 +438,8 @@ var classNames = classnames.exports;
438
438
  var iconStaticClassName = 'pop-icon';
439
439
  var Icon = function (props) {
440
440
  var icon = props.icon, className = props.className, restProps = __rest(props, ["icon", "className"]);
441
- if (!restProps['aria-label'] && restProps['aria-hidden'] === undefined) {
441
+ var hasAccessibleAttr = Boolean(restProps['aria-describedby'] || restProps['aria-label']);
442
+ if (!hasAccessibleAttr && restProps['aria-hidden'] === undefined) {
442
443
  restProps['aria-hidden'] = true;
443
444
  }
444
445
  var classes = useIconStyles(props);