Comparing version 2.9.0 to 2.9.1
# rc-rate | ||
## 2.9.0 | ||
`2020-11-02` | ||
- Update devDependencies include np/typescript/rc-tooltip | ||
- Add peerDependencies [#97](https://github.com/react-component/rate/pull/97) | ||
## 2.8.2 | ||
@@ -4,0 +11,0 @@ |
@@ -16,3 +16,3 @@ import React from 'react'; | ||
className?: string; | ||
character?: (props: StarProps) => React.ReactNode | React.ReactNode; | ||
character?: React.ReactNode; | ||
characterRender?: (origin: React.ReactElement, props: StarProps) => React.ReactNode; | ||
@@ -19,0 +19,0 @@ tabIndex?: number; |
@@ -275,3 +275,3 @@ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2"; | ||
for (var index = 0; index < count; index += 1) { | ||
stars.push(React.createElement(Star, { | ||
stars.push( /*#__PURE__*/React.createElement(Star, { | ||
ref: this.saveRef(index), | ||
@@ -294,3 +294,3 @@ index: index, | ||
var rateClassName = classNames(prefixCls, disabledClass, className, _defineProperty({}, "".concat(prefixCls, "-rtl"), direction === 'rtl')); | ||
return React.createElement("ul", { | ||
return /*#__PURE__*/React.createElement("ul", { | ||
className: rateClassName, | ||
@@ -297,0 +297,0 @@ style: style, |
@@ -10,3 +10,3 @@ import React from 'react'; | ||
onClick?: (e: React.MouseEvent<HTMLDivElement> | React.KeyboardEvent<HTMLDivElement>, index: number) => void; | ||
character?: (props: StarProps) => React.ReactNode | React.ReactNode; | ||
character?: React.ReactNode; | ||
characterRender?: (origin: React.ReactElement, props: StarProps) => React.ReactNode; | ||
@@ -13,0 +13,0 @@ focused?: boolean; |
@@ -91,5 +91,5 @@ import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck"; | ||
var characterNode = typeof character === 'function' ? character(this.props) : character; | ||
var start = React.createElement("li", { | ||
var start = /*#__PURE__*/React.createElement("li", { | ||
className: this.getClassName() | ||
}, React.createElement("div", { | ||
}, /*#__PURE__*/React.createElement("div", { | ||
onClick: disabled ? null : onClick, | ||
@@ -103,5 +103,5 @@ onKeyDown: disabled ? null : onKeyDown, | ||
tabIndex: disabled ? -1 : 0 | ||
}, React.createElement("div", { | ||
}, /*#__PURE__*/React.createElement("div", { | ||
className: "".concat(prefixCls, "-first") | ||
}, characterNode), React.createElement("div", { | ||
}, characterNode), /*#__PURE__*/React.createElement("div", { | ||
className: "".concat(prefixCls, "-second") | ||
@@ -108,0 +108,0 @@ }, characterNode))); |
@@ -16,3 +16,3 @@ import React from 'react'; | ||
className?: string; | ||
character?: (props: StarProps) => React.ReactNode | React.ReactNode; | ||
character?: React.ReactNode; | ||
characterRender?: (origin: React.ReactElement, props: StarProps) => React.ReactNode; | ||
@@ -19,0 +19,0 @@ tabIndex?: number; |
@@ -294,3 +294,3 @@ "use strict"; | ||
for (var index = 0; index < count; index += 1) { | ||
stars.push(_react.default.createElement(_Star.default, { | ||
stars.push( /*#__PURE__*/_react.default.createElement(_Star.default, { | ||
ref: this.saveRef(index), | ||
@@ -313,3 +313,3 @@ index: index, | ||
var rateClassName = (0, _classnames.default)(prefixCls, disabledClass, className, (0, _defineProperty2.default)({}, "".concat(prefixCls, "-rtl"), direction === 'rtl')); | ||
return _react.default.createElement("ul", { | ||
return /*#__PURE__*/_react.default.createElement("ul", { | ||
className: rateClassName, | ||
@@ -316,0 +316,0 @@ style: style, |
@@ -10,3 +10,3 @@ import React from 'react'; | ||
onClick?: (e: React.MouseEvent<HTMLDivElement> | React.KeyboardEvent<HTMLDivElement>, index: number) => void; | ||
character?: (props: StarProps) => React.ReactNode | React.ReactNode; | ||
character?: React.ReactNode; | ||
characterRender?: (origin: React.ReactElement, props: StarProps) => React.ReactNode; | ||
@@ -13,0 +13,0 @@ focused?: boolean; |
@@ -104,5 +104,5 @@ "use strict"; | ||
var start = _react.default.createElement("li", { | ||
var start = /*#__PURE__*/_react.default.createElement("li", { | ||
className: this.getClassName() | ||
}, _react.default.createElement("div", { | ||
}, /*#__PURE__*/_react.default.createElement("div", { | ||
onClick: disabled ? null : onClick, | ||
@@ -116,5 +116,5 @@ onKeyDown: disabled ? null : onKeyDown, | ||
tabIndex: disabled ? -1 : 0 | ||
}, _react.default.createElement("div", { | ||
}, /*#__PURE__*/_react.default.createElement("div", { | ||
className: "".concat(prefixCls, "-first") | ||
}, characterNode), _react.default.createElement("div", { | ||
}, characterNode), /*#__PURE__*/_react.default.createElement("div", { | ||
className: "".concat(prefixCls, "-second") | ||
@@ -121,0 +121,0 @@ }, characterNode))); |
{ | ||
"name": "rc-rate", | ||
"version": "2.9.0", | ||
"version": "2.9.1", | ||
"description": "React Star Rate Component", | ||
@@ -5,0 +5,0 @@ "engines": { |
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
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
43916