@luminati-io/uikit 3.8.1 → 3.8.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -44788,7 +44788,8 @@ var Tooltip = function Tooltip(props) {
44788
44788
  noWrap = props.noWrap,
44789
44789
  interactive = props.interactive,
44790
44790
  trigger = props.trigger,
44791
- className = props.className;
44791
+ className = props.className,
44792
+ variant = props.variant;
44792
44793
  var _useState = (0,react__WEBPACK_IMPORTED_MODULE_1__.useState)(null),
44793
44794
  _useState2 = _slicedToArray(_useState, 2),
44794
44795
  referenceElement = _useState2[0],
@@ -44854,10 +44855,11 @@ var Tooltip = function Tooltip(props) {
44854
44855
  var tooltipNode = visible ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledTooltipBody, _extends({
44855
44856
  ref: setPopperElement,
44856
44857
  role: "tooltip",
44858
+ $variant: variant,
44857
44859
  style: styles.popper
44858
44860
  }, attributes.popper, interactive ? triggerProps : {}), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_typography__WEBPACK_IMPORTED_MODULE_4__.Label, {
44859
44861
  variant: "sm",
44860
- color: "white"
44862
+ color: variant == 'white' ? 'black' : 'white'
44861
44863
  }, tooltip), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledTooltipArrow, _extends({
44862
44864
  ref: setArrowElement,
44863
44865
  style: styles.arrow
@@ -44875,14 +44877,16 @@ var Tooltip = function Tooltip(props) {
44875
44877
  };
44876
44878
  Tooltip.defaultProps = {
44877
44879
  placement: 'top',
44878
- trigger: 'hover'
44880
+ trigger: 'hover',
44881
+ variant: 'black'
44879
44882
  };
44880
44883
  Tooltip.propTypes = {
44881
44884
  tooltip: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().node),
44882
44885
  placement: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOf(_util__WEBPACK_IMPORTED_MODULE_5__.tooltipPlacement),
44883
44886
  noWrap: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool),
44884
44887
  interactive: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool),
44885
- trigger: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOf(['hover', 'focus'])
44888
+ trigger: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOf(['hover', 'focus']),
44889
+ variant: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOf(['black', 'white'])
44886
44890
  };
44887
44891
  var withTooltip = function withTooltip(Comp, tooltipProps) {
44888
44892
  return function WithTooltip(props) {
@@ -44892,7 +44896,9 @@ var withTooltip = function withTooltip(Comp, tooltipProps) {
44892
44896
  var StyledTooltipBody = styled_components__WEBPACK_IMPORTED_MODULE_2___default().div.withConfig({
44893
44897
  displayName: "StyledTooltipBody",
44894
44898
  componentId: "sc-146jrck-0"
44895
- })(["background-color:", ";padding:", ";width:fit-content;max-width:500px;border-radius:", ";transition:opacity 200ms;z-index:", ";"], _theme__WEBPACK_IMPORTED_MODULE_3__["default"].color.gray_11_50, _theme__WEBPACK_IMPORTED_MODULE_3__["default"].spacing['03'], _theme__WEBPACK_IMPORTED_MODULE_3__["default"].spacing['02'], _constants__WEBPACK_IMPORTED_MODULE_6__.Z_INDEX.tooltip);
44899
+ })(["background-color:", ";padding:", ";width:fit-content;max-width:500px;border-radius:", ";transition:opacity 200ms;z-index:", ";", ";"], _theme__WEBPACK_IMPORTED_MODULE_3__["default"].color.gray_11_50, _theme__WEBPACK_IMPORTED_MODULE_3__["default"].spacing['03'], _theme__WEBPACK_IMPORTED_MODULE_3__["default"].spacing['02'], _constants__WEBPACK_IMPORTED_MODULE_6__.Z_INDEX.tooltip, function (props) {
44900
+ return props.$variant == 'white' && (0,styled_components__WEBPACK_IMPORTED_MODULE_2__.css)(["background-color:", ";border:1px solid ", ";box-shadow:", ";"], _theme__WEBPACK_IMPORTED_MODULE_3__["default"].color.white, _theme__WEBPACK_IMPORTED_MODULE_3__["default"].color.gray_4, _theme__WEBPACK_IMPORTED_MODULE_3__["default"].box_shadow['md']);
44901
+ });
44896
44902
  var StyledTooltipArrow = styled_components__WEBPACK_IMPORTED_MODULE_2___default().div.withConfig({
44897
44903
  displayName: "StyledTooltipArrow",
44898
44904
  componentId: "sc-146jrck-1"