"use strict";

require("./demo17.css");

var _propTypes = _interopRequireDefault(require("prop-types"));

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

var _reactDom = _interopRequireDefault(require("react-dom"));

var _ = _interopRequireDefault(require(".."));

var _excluded = ["children"];

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }

function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }

function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }

var pages = [1, 2, 3, 4];

function Inner(_ref) {
  var children = _ref.children,
      others = _objectWithoutProperties(_ref, _excluded);

  // Note that to transparently pass other attributes to the lower node, the Slider needs to perform the element's clone operation.
  return /*#__PURE__*/_react["default"].createElement("div", others, children);
}

Inner.propTypes = {
  children: _propTypes["default"].any
};

var slider = /*#__PURE__*/_react["default"].createElement(_["default"], null, pages.map(function (page, index) {
  return /*#__PURE__*/_react["default"].createElement(Inner, {
    className: "custom-inner",
    key: index
  }, "custom ", page);
}));

_reactDom["default"].render( /*#__PURE__*/_react["default"].createElement("div", null, slider), document.getElementById('slider-demo-17'));