mirror of
https://github.com/wassname/slider.git
synced 2026-09-11 12:42:49 +08:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
926d5aeb91 | ||
|
|
b2ae1bc0fc |
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "rc-slider",
|
"name": "rc-slider",
|
||||||
"version": "3.7.4",
|
"version": "3.8.0",
|
||||||
"description": "slider ui component for react",
|
"description": "slider ui component for react",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"react",
|
"react",
|
||||||
|
|||||||
+13
-2
@@ -337,15 +337,26 @@ class Slider extends React.Component {
|
|||||||
const lowerOffset = this.calcOffset(lowerBound);
|
const lowerOffset = this.calcOffset(lowerBound);
|
||||||
|
|
||||||
const handleClassName = prefixCls + '-handle';
|
const handleClassName = prefixCls + '-handle';
|
||||||
|
|
||||||
|
const upperClassName = classNames({
|
||||||
|
[handleClassName]: true,
|
||||||
|
[handleClassName + '-upper']: true,
|
||||||
|
});
|
||||||
|
|
||||||
|
const lowerClassName = classNames({
|
||||||
|
[handleClassName]: true,
|
||||||
|
[handleClassName + '-lower']: true,
|
||||||
|
});
|
||||||
|
|
||||||
const isNoTip = (step === null) || (tipFormatter === null);
|
const isNoTip = (step === null) || (tipFormatter === null);
|
||||||
|
|
||||||
const upper = cloneElement(customHandle, { className: handleClassName,
|
const upper = cloneElement(customHandle, { className: upperClassName,
|
||||||
noTip: isNoTip, tipTransitionName: tipTransitionName, tipFormatter: tipFormatter,
|
noTip: isNoTip, tipTransitionName: tipTransitionName, tipFormatter: tipFormatter,
|
||||||
vertical: vertical, offset: upperOffset, value: upperBound, dragging: handle === 'upperBound' });
|
vertical: vertical, offset: upperOffset, value: upperBound, dragging: handle === 'upperBound' });
|
||||||
|
|
||||||
let lower = null;
|
let lower = null;
|
||||||
if (range) {
|
if (range) {
|
||||||
lower = cloneElement(customHandle, { className: handleClassName,
|
lower = cloneElement(customHandle, { className: lowerClassName,
|
||||||
noTip: isNoTip, tipTransitionName: tipTransitionName, tipFormatter: tipFormatter,
|
noTip: isNoTip, tipTransitionName: tipTransitionName, tipFormatter: tipFormatter,
|
||||||
vertical: vertical, offset: lowerOffset, value: lowerBound, dragging: handle === 'lowerBound' });
|
vertical: vertical, offset: lowerOffset, value: lowerBound, dragging: handle === 'lowerBound' });
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user