"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
var _react = _interopRequireWildcard(require("react"));
var _styledComponents = _interopRequireWildcard(require("styled-components"));
var _sliderMonitor = require("@redux-devtools/slider-monitor");
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
const SliderWrapper = _styledComponents.default.div`
  border-color: ${props => props.theme.base02};
  border-style: solid;
  border-width: 1px 0;
`;
class Slider extends _react.Component {
  shouldComponentUpdate(nextProps) {
    return nextProps.liftedState !== this.props.liftedState || nextProps.theme.scheme !== this.props.theme.scheme;
  }
  render() {
    return /*#__PURE__*/_react.default.createElement(SliderWrapper, {
      className: "slider"
    }, /*#__PURE__*/_react.default.createElement(_sliderMonitor.SliderMonitor, (0, _extends2.default)({}, this.props.liftedState, {
      // eslint-disable-next-line @typescript-eslint/ban-ts-comment
      // @ts-ignore
      dispatch: this.props.dispatch,
      theme: this.props.theme,
      hideResetButton: true
    })));
  }
}
var _default = exports.default = (0, _styledComponents.withTheme)(Slider);