bee-switch
Advanced tools
Comparing version 0.1.4 to 0.2.1
@@ -78,10 +78,10 @@ 'use strict'; | ||
Switch.prototype.render = function render() { | ||
var _props = this.props, | ||
checkedChildren = _props.checkedChildren, | ||
unCheckedChildren = _props.unCheckedChildren, | ||
onChangeHandler = _props.onChangeHandler, | ||
size = _props.size, | ||
className = _props.className, | ||
clsPrefix = _props.clsPrefix, | ||
colors = _props.colors; | ||
var _props = this.props; | ||
var checkedChildren = _props.checkedChildren; | ||
var unCheckedChildren = _props.unCheckedChildren; | ||
var onChangeHandler = _props.onChangeHandler; | ||
var size = _props.size; | ||
var className = _props.className; | ||
var clsPrefix = _props.clsPrefix; | ||
var colors = _props.colors; | ||
//获取checked | ||
@@ -102,13 +102,9 @@ | ||
return _react2["default"].createElement( | ||
'div', | ||
null, | ||
'span', | ||
{ onClick: this.clickHandler, className: (0, _classnames2["default"])(className, classNames), tabIndex: '0' }, | ||
_react2["default"].createElement( | ||
'span', | ||
{ onClick: this.clickHandler, className: (0, _classnames2["default"])(className, classNames), tabIndex: '0' }, | ||
_react2["default"].createElement( | ||
'span', | ||
{ | ||
className: clsPrefix + '-inner' }, | ||
checked ? checkedChildren : unCheckedChildren | ||
) | ||
{ | ||
className: clsPrefix + '-inner' }, | ||
checked ? checkedChildren : unCheckedChildren | ||
) | ||
@@ -115,0 +111,0 @@ ); |
@@ -0,0 +0,0 @@ /** |
@@ -0,0 +0,0 @@ /** |
@@ -0,0 +0,0 @@ /** |
@@ -0,0 +0,0 @@ |
@@ -0,0 +0,0 @@ |
@@ -0,0 +0,0 @@ import Switch from '../src'; |
@@ -0,0 +0,0 @@ ## Switch 开关 |
{ | ||
"name": "bee-switch", | ||
"version": "0.1.4", | ||
"version": "0.2.1", | ||
"description": "switch ui component for react", | ||
@@ -36,4 +36,5 @@ "keywords": [ | ||
"dependencies": { | ||
"babel-runtime": "^6.20.0", | ||
"classnames": "^2.2.5", | ||
"tinper-bee-core": "^0.1.3" | ||
"tinper-bee-core": "^0.2.1" | ||
}, | ||
@@ -40,0 +41,0 @@ "devDependencies": { |
@@ -0,0 +0,0 @@ # bee-switch |
@@ -0,0 +0,0 @@ |
@@ -59,5 +59,4 @@ import React, { Component,PropTypes } from 'react' | ||
return( | ||
<div> | ||
<span onClick = {this.clickHandler} className={classnames(className,classNames)} tabIndex="0"> | ||
<span | ||
<span | ||
className={`${clsPrefix}-inner`}> | ||
@@ -67,3 +66,2 @@ { checked?checkedChildren : unCheckedChildren} | ||
</span> | ||
</div> | ||
) | ||
@@ -74,2 +72,2 @@ } | ||
Switch.defaultProps = defaultProps; | ||
export default Switch; | ||
export default Switch; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1270299
3
13477
1
+ Addedbabel-runtime@^6.20.0
+ Addedasap@2.0.6(transitive)
+ Addedbabel-runtime@6.26.0(transitive)
+ Addedcore-js@1.2.72.6.12(transitive)
+ Addedcreate-react-class@15.7.0(transitive)
+ Addedencoding@0.1.13(transitive)
+ Addedfbjs@0.8.18(transitive)
+ Addediconv-lite@0.6.3(transitive)
+ Addedis-stream@1.1.0(transitive)
+ Addedisomorphic-fetch@2.2.1(transitive)
+ Addednode-fetch@1.7.3(transitive)
+ Addedpromise@7.3.1(transitive)
+ Addedprop-types@15.6.015.8.1(transitive)
+ Addedreact@16.14.0(transitive)
+ Addedreact-dom@16.14.0(transitive)
+ Addedreact-is@16.13.1(transitive)
+ Addedregenerator-runtime@0.11.1(transitive)
+ Addedsafer-buffer@2.1.2(transitive)
+ Addedscheduler@0.19.1(transitive)
+ Addedsetimmediate@1.0.5(transitive)
+ Addedtinper-bee-core@0.2.11(transitive)
+ Addedua-parser-js@0.7.39(transitive)
+ Addedwhatwg-fetch@3.6.20(transitive)
- Removedtinper-bee-core@0.1.9(transitive)
Updatedtinper-bee-core@^0.2.1