mirror of
https://github.com/gradio-app/gradio.git
synced 2024-12-27 02:30:17 +08:00
decrease default step size
This commit is contained in:
parent
50de08b026
commit
d9adbd0cef
@ -292,7 +292,7 @@ class Slider(InputComponent):
|
||||
self.maximum = maximum
|
||||
if step is None:
|
||||
difference = maximum - minimum
|
||||
power = math.floor(math.log10(difference) - 1)
|
||||
power = math.floor(math.log10(difference) - 2)
|
||||
step = 10 ** power
|
||||
self.step = step
|
||||
self.default = minimum if default is None else default
|
||||
|
Loading…
Reference in New Issue
Block a user