@cypress-design/react-tooltip 0.7.0 → 0.7.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.umd.js CHANGED
@@ -36,7 +36,7 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
36
36
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
37
37
  PERFORMANCE OF THIS SOFTWARE.
38
38
  ***************************************************************************** */
39
- /* global Reflect, Promise */
39
+ /* global Reflect, Promise, SuppressedError, Symbol */
40
40
 
41
41
 
42
42
  var __assign = function() {
@@ -70,7 +70,12 @@ function __spreadArray(to, from, pack) {
70
70
  }
71
71
  }
72
72
  return to.concat(ar || Array.prototype.slice.call(from));
73
- }
73
+ }
74
+
75
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
76
+ var e = new Error(message);
77
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
78
+ };
74
79
 
75
80
  function getSide(placement) {
76
81
  return placement.split('-')[0];
@@ -33572,6 +33577,7 @@ var Tooltip = function (_a) {
33572
33577
  ],
33573
33578
  whileElementsMounted: autoUpdate,
33574
33579
  }), x = _f.x, y = _f.y, reference = _f.reference, floating = _f.floating, strategy = _f.strategy, calculatedPlacement = _f.placement, context = _f.context, _g = _f.middlewareData.arrow, _h = _g === void 0 ? {} : _g, arrowX = _h.x, arrowY = _h.y;
33580
+ var contextHook = useDismiss(context);
33575
33581
  var _j = useInteractions(__spreadArray([
33576
33582
  useHover(context, {
33577
33583
  handleClose: interactive ? safePolygon() : undefined,
@@ -33581,7 +33587,7 @@ var Tooltip = function (_a) {
33581
33587
  enabled: !disabled && !forceOpen,
33582
33588
  }),
33583
33589
  useRole(context, { role: 'tooltip' })
33584
- ], (!forceOpen ? [useDismiss(context)] : []), true)), getReferenceProps = _j.getReferenceProps, getFloatingProps = _j.getFloatingProps;
33590
+ ], (!forceOpen ? [contextHook] : []), true)), getReferenceProps = _j.getReferenceProps, getFloatingProps = _j.getFloatingProps;
33585
33591
  var placementSide = calculatedPlacement.split('-')[0];
33586
33592
  var arrowRotate = ROTATE_MAP[placementSide];
33587
33593
  var arrowXRule = 'left', arrowYRule = 'top';