sag_components 2.0.0-beta290 → 2.0.0-beta291

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.esm.js CHANGED
@@ -58043,7 +58043,7 @@ const OverlayDropdown = _ref => {
58043
58043
  if (!showLabelOnTop && open) {
58044
58044
  return "";
58045
58045
  }
58046
- if (hasValue) {
58046
+ if (hasValue || customDisplayText) {
58047
58047
  return label;
58048
58048
  }
58049
58049
  return labelEmptyValue;
@@ -58065,15 +58065,15 @@ const OverlayDropdown = _ref => {
58065
58065
  return "";
58066
58066
  };
58067
58067
  const getDisplayText = () => {
58068
+ if (open) {
58069
+ return placeHolder;
58070
+ }
58068
58071
  if (customDisplayText) {
58069
58072
  return customDisplayText;
58070
58073
  }
58071
58074
  if (selected) {
58072
58075
  return selected.label;
58073
58076
  }
58074
- if (open) {
58075
- return placeHolder;
58076
- }
58077
58077
  return '';
58078
58078
  };
58079
58079
  return /*#__PURE__*/React$1.createElement(DropdownContainer, {
@@ -58084,7 +58084,7 @@ const OverlayDropdown = _ref => {
58084
58084
  className: "Label",
58085
58085
  isFocused: open,
58086
58086
  labelColor: labelColor,
58087
- hasValue: hasValue,
58087
+ hasValue: hasValue || !!customDisplayText,
58088
58088
  disabled: disabled,
58089
58089
  showLabelOnTop: showLabelOnTop,
58090
58090
  isDarkerBackground: isDarkerBackground
@@ -58103,7 +58103,7 @@ const OverlayDropdown = _ref => {
58103
58103
  className: "selected",
58104
58104
  onMouseEnter: () => setHoveredText(customDisplayText || selected?.label),
58105
58105
  onMouseLeave: () => setHoveredText(null),
58106
- color: !selected && open ? placeHolderColor : "inherit"
58106
+ color: !hasValue && !customDisplayText && open ? placeHolderColor : "inherit"
58107
58107
  }, getDisplayText()), open ? /*#__PURE__*/React$1.createElement(MenuItemUpIcon, {
58108
58108
  width: "12px",
58109
58109
  height: "12px",