@patternfly/quickstarts 5.0.0-prerelease.0 → 5.0.0-prerelease.1

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/dist/index.es.js CHANGED
@@ -840,8 +840,8 @@ const CamelCaseWrap = ({ value, dataTest }) => {
840
840
  };
841
841
 
842
842
  class CatalogTile extends React.Component {
843
- constructor(props) {
844
- super(props);
843
+ constructor() {
844
+ super(...arguments);
845
845
  this.handleClick = (e) => {
846
846
  const { onClick, href } = this.props;
847
847
  if (!href) {
@@ -857,18 +857,13 @@ class CatalogTile extends React.Component {
857
857
  }
858
858
  return (React.createElement("div", { className: "catalog-tile-pf-badge-container" }, badges.map((badge, index) => (React.createElement("span", { key: `badge-${index}` }, badge)))));
859
859
  };
860
- this.generatedId = getUniqueId('pf-catalog-tile');
861
860
  }
862
861
  render() {
863
862
  const _a = this.props, { id, className, featured, onClick, href, icon, iconImg, iconAlt, iconClass, badges, title, vendor, description, footer,
864
863
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
865
864
  ref, children } = _a, props = __rest(_a, ["id", "className", "featured", "onClick", "href", "icon", "iconImg", "iconAlt", "iconClass", "badges", "title", "vendor", "description", "footer", "ref", "children"]);
866
- return (React.createElement(Card, Object.assign({ component: href ? 'a' : 'div', id: id || this.generatedId, href: href || '#', className: css('catalog-tile-pf', { featured }, className), isClickable: !!onClick }, props),
867
- (badges.length > 0 || iconImg || iconClass || icon || onClick) && (React.createElement(CardHeader, { actions: { actions: badges.length > 0 && this.renderBadges(badges) }, selectableActions: onClick && {
868
- selectableActionId: id + '-input',
869
- onClickAction: (e) => this.handleClick(e),
870
- selectableActionAriaLabelledby: id
871
- } },
865
+ return (React.createElement(Card, Object.assign({ component: href ? 'a' : 'div', id: id, href: href || '#', className: css('catalog-tile-pf', { featured }, className), isClickable: !!onClick }, props),
866
+ (badges.length > 0 || iconImg || iconClass || icon || onClick) && (React.createElement(CardHeader, { actions: { actions: badges.length > 0 && this.renderBadges(badges) }, selectableActions: onClick && { selectableActionId: id + '-input', onClickAction: (e) => this.handleClick(e), selectableActionAriaLabelledby: id } },
872
867
  iconImg && React.createElement("img", { className: "catalog-tile-pf-icon", src: iconImg, alt: iconAlt }),
873
868
  !iconImg && (iconClass || icon) && React.createElement("span", { className: `catalog-tile-pf-icon ${iconClass}` }, icon))),
874
869
  React.createElement(CardTitle, { className: "catalog-tile-pf-header" },
@@ -883,7 +878,7 @@ class CatalogTile extends React.Component {
883
878
  }
884
879
  CatalogTile.displayName = 'CatalogTile';
885
880
  CatalogTile.defaultProps = {
886
- id: null,
881
+ id: getUniqueId('pf-catalog-tile'),
887
882
  className: '',
888
883
  featured: false,
889
884
  onClick: null,
@@ -1716,7 +1711,7 @@ const QuickStartTile = ({ quickStart, status, isActive, onClick = () => { }, })
1716
1711
  }
1717
1712
  };
1718
1713
  return (React.createElement("div", { ref: ref },
1719
- React.createElement(CatalogTile, { style: {
1714
+ React.createElement(CatalogTile, { id: id + '-catalog-tile', style: {
1720
1715
  cursor: 'pointer',
1721
1716
  }, icon: quickStartIcon, className: "pfext-quick-start-tile", "data-testid": `qs-card-${camelize(displayName)}`, featured: isActive, title: React.createElement(QuickStartTileHeader, { name: displayName, status: status, duration: durationMinutes, type: type, quickStartId: id }), onClick: handleClick, onKeyDown: (event) => {
1722
1717
  if (event.key === 'Enter' || event.key === ' ') {