import _extends from"babel-runtime/helpers/extends";import _defineProperty from"babel-runtime/helpers/defineProperty";import _classCallCheck from"babel-runtime/helpers/classCallCheck";import _createClass from"babel-runtime/helpers/createClass";import _possibleConstructorReturn from"babel-runtime/helpers/possibleConstructorReturn";import _inherits from"babel-runtime/helpers/inherits";var __rest=this&&this.__rest||function(e,r){var t={};for(var s in e)Object.prototype.hasOwnProperty.call(e,s)&&r.indexOf(s)<0&&(t[s]=e[s]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(s=Object.getOwnPropertySymbols(e);a<s.length;a++)r.indexOf(s[a])<0&&(t[s[a]]=e[s[a]])}return t};import*as React from"react";import classNames from"classnames";var CheckableTag=function(e){function r(){_classCallCheck(this,r);var e=_possibleConstructorReturn(this,(r.__proto__||Object.getPrototypeOf(r)).apply(this,arguments));return e.handleClick=function(){var r=e.props,t=r.checked,s=r.onChange;s&&s(!t)},e}return _inherits(r,e),_createClass(r,[{key:"render",value:function(){var e,r=this.props,t=r.prefixCls,s=void 0===t?"dt-tag":t,a=r.className,n=r.checked,o=__rest(r,["prefixCls","className","checked"]),l=classNames(s,(_defineProperty(e={},s+"-checkable",!0),_defineProperty(e,s+"-checkable-checked",n),e),a);return delete o.onChange,React.createElement("div",_extends({},o,{className:l,onClick:this.handleClick}))}}]),r}(React.Component);export default CheckableTag;