// Copyright 1999-2020. Plesk International GmbH. All rights reserved.
import React, { cloneElement } from 'react';
import Menu, { MenuItem, MenuDivider, MenuHeader } from '.';
import Label from '../Label';
export const Basic = args => /*#__PURE__*/React.createElement(Menu, args);
Basic.args = {
  children: [/*#__PURE__*/React.createElement(MenuItem, {
    key: "1",
    "data-test": "one"
  }, 'One'), /*#__PURE__*/React.createElement(MenuItem, {
    key: "2",
    "data-test": "two"
  }, 'Two'), /*#__PURE__*/React.createElement(MenuItem, {
    key: "3",
    "data-test": "three",
    disabled: true
  }, 'Three')]
};
export const Tooltip = Basic.bind(null);
Tooltip.args = {
  children: Basic.args.children.map((item, index) => {
    if (index === 0) {
      return /*#__PURE__*/cloneElement(item, {
        tooltip: 'One tooltip!'
      });
    }

    return item;
  })
};
export const FullFeatured = Basic.bind(null);
FullFeatured.args = {
  children: [/*#__PURE__*/React.createElement(MenuHeader, {
    key: "1"
  }, 'Header 1'), /*#__PURE__*/React.createElement(MenuItem, {
    key: "2",
    "data-test": "2",
    onClick: () => {},
    icon: "folder-open"
  }, 'One'), /*#__PURE__*/React.createElement(MenuItem, {
    key: "3",
    "data-test": "3",
    onClick: () => {},
    icon: "folder-open",
    label: /*#__PURE__*/React.createElement(Label, {
      intent: "danger"
    }, '99')
  }, 'Two'), /*#__PURE__*/React.createElement(MenuDivider, {
    key: "4"
  }), /*#__PURE__*/React.createElement(MenuHeader, {
    key: "5"
  }, 'Header 2'), /*#__PURE__*/React.createElement(MenuItem, {
    key: "6",
    "data-test": "6",
    onClick: () => {},
    icon: "folder-open"
  }, 'Three'), /*#__PURE__*/React.createElement(MenuItem, {
    key: "7",
    "data-test": "7",
    onClick: () => {},
    icon: "folder-open"
  }, 'Four')]
};