@asantemedia-org/edwardsvacuum-design-system 1.4.0 → 1.4.2

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.css CHANGED
@@ -137,6 +137,11 @@
137
137
  text-decoration: none;
138
138
  color: inherit;
139
139
  }
140
+ .card-module__cmp-card__link___OdszC:focus {
141
+ box-shadow: inset 0 0 0 2px #000, 0 0 0 2px #000 !important;
142
+ outline: none;
143
+ color: inherit;
144
+ }
140
145
  .card-module__cmp-card__content-wrapper___gh335 {
141
146
  display: flex;
142
147
  flex-direction: column;
@@ -137,6 +137,11 @@
137
137
  text-decoration: none;
138
138
  color: inherit;
139
139
  }
140
+ .card-module__cmp-card__link___OdszC:focus {
141
+ box-shadow: inset 0 0 0 2px #000, 0 0 0 2px #000 !important;
142
+ outline: none;
143
+ color: inherit;
144
+ }
140
145
  .card-module__cmp-card__content-wrapper___gh335 {
141
146
  display: flex;
142
147
  flex-direction: column;
package/dist/index.esm.js CHANGED
@@ -4758,12 +4758,33 @@ var DynamicHeading = function (_a) {
4758
4758
  var Tag = ["h2", "h3", "h4", "h5", "h6"].includes(titleSize) ? titleSize : "h2";
4759
4759
  return /*#__PURE__*/React.createElement(Tag, props, children);
4760
4760
  };
4761
+ var getCallToActionProps = function (type, url) {
4762
+ var callType = type === null || type === void 0 ? void 0 : type.toLowerCase();
4763
+ var finalUrl = url || '';
4764
+ var target = '';
4765
+ switch (callType) {
4766
+ case 'external':
4767
+ target = '_blank';
4768
+ break;
4769
+ case 'email':
4770
+ finalUrl = "mailto:".concat(url);
4771
+ break;
4772
+ case 'phone':
4773
+ finalUrl = "tel:".concat(url);
4774
+ break;
4775
+ }
4776
+ return {
4777
+ finalUrl: finalUrl,
4778
+ target: target
4779
+ };
4780
+ };
4761
4781
  var AlgoliaDynamicSearch = function (_a) {
4762
4782
  var _b = _a.className,
4763
4783
  className = _b === void 0 ? '' : _b,
4764
4784
  heading = _a.heading,
4765
4785
  titleSize = _a.titleSize,
4766
4786
  subtext = _a.subtext,
4787
+ calltoactiontype = _a.calltoactiontype,
4767
4788
  callToActionText = _a.callToActionText,
4768
4789
  callToActionUrl = _a.callToActionUrl,
4769
4790
  _c = _a.queryType,
@@ -4829,7 +4850,12 @@ var AlgoliaDynamicSearch = function (_a) {
4829
4850
  style: widgetStyleProps.buttonStyle,
4830
4851
  label: callToActionText,
4831
4852
  onClick: function () {
4832
- return window.open(callToActionUrl, "_blank", "noopener,noreferrer");
4853
+ var _a = getCallToActionProps(calltoactiontype, callToActionUrl),
4854
+ finalUrl = _a.finalUrl,
4855
+ target = _a.target;
4856
+ if (finalUrl) {
4857
+ window.open(finalUrl, target || "_self", target === '_blank' ? "noopener,noreferrer" : undefined);
4858
+ }
4833
4859
  }
4834
4860
  }))), /*#__PURE__*/React.createElement("div", {
4835
4861
  className: styles$4.cmpAlgoliaDynamicSearchWidget__cards