"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
exports.__esModule = true;
exports.default = exports.Basic = void 0;
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
var _react = _interopRequireDefault(require("react"));
var _wixUiIconsCommon = require("@wix/wix-ui-icons-common");
var _NestableList = _interopRequireDefault(require("./NestableList"));
var _Text = _interopRequireDefault(require("../Text"));
var _Box = _interopRequireDefault(require("../Box"));
var _PopoverMenu = _interopRequireDefault(require("../PopoverMenu"));
var _IconButton = _interopRequireDefault(require("../IconButton"));
var _jsxFileName = "/home/builduser/work/57e038ea7326c1ec/packages/wix-design-system/dist/cjs/NestableList/NestableList.story.tsx";
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
var _default = exports.default = {
  title: 'NestableList',
  component: _NestableList.default
};
var Template = args => /*#__PURE__*/_react.default.createElement(_NestableList.default, (0, _extends2.default)({}, args, {
  __self: void 0,
  __source: {
    fileName: _jsxFileName,
    lineNumber: 17,
    columnNumber: 3
  }
}));
var TableListItemContent = _ref => {
  var {
    title,
    description
  } = _ref;
  return /*#__PURE__*/_react.default.createElement(_Box.default, {
    align: "space-between",
    verticalAlign: "middle",
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 27,
      columnNumber: 3
    }
  }, /*#__PURE__*/_react.default.createElement(_Box.default, {
    marginLeft: "SP3",
    direction: "vertical",
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 28,
      columnNumber: 5
    }
  }, /*#__PURE__*/_react.default.createElement(_Text.default, {
    weight: "normal",
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 29,
      columnNumber: 7
    }
  }, title), /*#__PURE__*/_react.default.createElement(_Text.default, {
    size: "small",
    secondary: true,
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 30,
      columnNumber: 7
    }
  }, description)), /*#__PURE__*/_react.default.createElement(_PopoverMenu.default, {
    placement: "left",
    triggerElement: /*#__PURE__*/_react.default.createElement(_IconButton.default, {
      skin: "light",
      __self: void 0,
      __source: {
        fileName: _jsxFileName,
        lineNumber: 37,
        columnNumber: 9
      }
    }, /*#__PURE__*/_react.default.createElement(_wixUiIconsCommon.More, {
      __self: void 0,
      __source: {
        fileName: _jsxFileName,
        lineNumber: 38,
        columnNumber: 11
      }
    })),
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 34,
      columnNumber: 5
    }
  }, /*#__PURE__*/_react.default.createElement(_PopoverMenu.default.MenuItem, {
    text: "Edit Category",
    prefixIcon: /*#__PURE__*/_react.default.createElement(_wixUiIconsCommon.Edit, {
      __self: void 0,
      __source: {
        fileName: _jsxFileName,
        lineNumber: 42,
        columnNumber: 62
      }
    }),
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 42,
      columnNumber: 7
    }
  }), /*#__PURE__*/_react.default.createElement(_PopoverMenu.default.MenuItem, {
    text: "Move Category",
    prefixIcon: /*#__PURE__*/_react.default.createElement(_wixUiIconsCommon.FolderMove, {
      __self: void 0,
      __source: {
        fileName: _jsxFileName,
        lineNumber: 43,
        columnNumber: 62
      }
    }),
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 43,
      columnNumber: 7
    }
  }), /*#__PURE__*/_react.default.createElement(_PopoverMenu.default.MenuItem, {
    text: "Delete Category",
    prefixIcon: /*#__PURE__*/_react.default.createElement(_wixUiIconsCommon.Delete, {
      __self: void 0,
      __source: {
        fileName: _jsxFileName,
        lineNumber: 44,
        columnNumber: 64
      }
    }),
    __self: void 0,
    __source: {
      fileName: _jsxFileName,
      lineNumber: 44,
      columnNumber: 7
    }
  })));
};
var commonItemProps = {
  verticalPadding: 'tiny'
};
var commonProps = {
  items: [_objectSpread(_objectSpread({}, commonItemProps), {}, {
    id: '1',
    options: [{
      value: /*#__PURE__*/_react.default.createElement(TableListItemContent, {
        title: "Sports",
        description: "1 post \xB7 60 views",
        __self: void 0,
        __source: {
          fileName: _jsxFileName,
          lineNumber: 61,
          columnNumber: 13
        }
      })
    }],
    children: [_objectSpread(_objectSpread({}, commonItemProps), {}, {
      id: '2',
      options: [{
        value: /*#__PURE__*/_react.default.createElement(TableListItemContent, {
          title: "Equipment",
          description: "5 posts \xB7 100 views",
          __self: void 0,
          __source: {
            fileName: _jsxFileName,
            lineNumber: 75,
            columnNumber: 17
          }
        })
      }]
    }), _objectSpread(_objectSpread({}, commonItemProps), {}, {
      id: '3',
      options: [{
        value: /*#__PURE__*/_react.default.createElement(TableListItemContent, {
          title: "Courts",
          description: "3 posts \xB7 120 views",
          __self: void 0,
          __source: {
            fileName: _jsxFileName,
            lineNumber: 89,
            columnNumber: 17
          }
        })
      }]
    })]
  }), _objectSpread(_objectSpread({}, commonItemProps), {}, {
    id: '4',
    options: [{
      value: /*#__PURE__*/_react.default.createElement(TableListItemContent, {
        title: "Tournaments",
        description: "15 posts \xB7 160 views",
        __self: void 0,
        __source: {
          fileName: _jsxFileName,
          lineNumber: 105,
          columnNumber: 13
        }
      })
    }]
  })],
  onChange: () => {}
};
var Basic = exports.Basic = Template.bind({});
Basic.args = _objectSpread({}, commonProps);
//# sourceMappingURL=NestableList.story.js.map