"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.WithIcon = exports.Dark = exports.Regular = exports.default = void 0;

var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));

var _react = _interopRequireDefault(require("react"));

var _Tooltip = _interopRequireDefault(require("./Tooltip"));

var _README = _interopRequireDefault(require("./README.mdx"));

var _iconsReact = require("@wfp/icons-react");

var _default = {
  title: 'Components/UI Elements/Tooltip',
  component: _Tooltip.default,
  parameters: {
    status: 'released',
    mdx: _README.default
  }
};
exports.default = _default;

var Regular = function Regular(args) {
  return /*#__PURE__*/_react.default.createElement(_Tooltip.default // options
  , args, "Hover here to show tooltip");
};

exports.Regular = Regular;
Regular.args = {
  content: 'Label text',
  children: 'This is a helper text'
};

var Dark = function Dark(args) {
  return /*#__PURE__*/_react.default.createElement(_Tooltip.default // options
  , (0, _extends2.default)({}, args, {
    trigger: "click"
  }), /*#__PURE__*/_react.default.createElement("span", null, "Click here to show tooltip"));
};

exports.Dark = Dark;
Dark.args = {
  content: 'Label text',
  children: 'This is a helper text',
  dark: true
};
Dark.story = {
  parameters: {
    docs: {
      storyDescription: "Use the `dark` style as an alternative for small tooltips"
    }
  }
};

var WithIcon = function WithIcon(args) {
  return /*#__PURE__*/_react.default.createElement(_Tooltip.default, (0, _extends2.default)({}, args, {
    trigger: "click",
    placement: 'bottom',
    createRefWrapper: true,
    content: "Label Text"
  }), /*#__PURE__*/_react.default.createElement(_iconsReact.MenuGlyph, {
    description: "options"
  }));
};

exports.WithIcon = WithIcon;
WithIcon.story = {
  parameters: {
    docs: {
      storyDescription: "By using the `createRefWrapper` prop a html element around the trigger will be added. This is useful for components without `forwardRef` support."
    }
  }
};
WithIcon.args = {
  content: 'Label text',
  children: 'This is a helper text'
};