mirror of
https://gitee.com/baidu/amis.git
synced 2024-12-02 11:58:10 +08:00
Merge remote-tracking branch 'baidu/master'
This commit is contained in:
commit
b80057ba66
@ -156,6 +156,7 @@
|
||||
border-radius: 50%;
|
||||
background-color: var(--InputRange-track-dot-bg);
|
||||
position: absolute;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -444,7 +444,8 @@ export class Range extends React.Component<RangeItemProps, any> {
|
||||
if (isString(value) && MARKS_REG.test(value)) {
|
||||
return value;
|
||||
}
|
||||
return (+value * 100) / (max - min) + '%';
|
||||
value = Math.min(Math.max(+value, min), max);
|
||||
return ((value - min) * 100) / (max - min) + '%';
|
||||
}
|
||||
|
||||
render() {
|
||||
|
Loading…
Reference in New Issue
Block a user