Closed fabianmichael closed 5 years ago
I used the range slider in another project and found some more related glitches:
default
parameter is not 0
.0
, the range field will display a dash -
as value when used outside of a structure field. When used inside a structure field, the default value is not set and the right-sided label displays NaN
.✅
I still have the same behavior in Kirby 3.8.3:
BackgroundGradientAngle:
label: Angle
type: range
default: 90
step: 1
min: 0
max: 359
tooltip:
after: degree
@musterknabe did you add the range field/its default in the blueprint after the page got created? Defaults are only applied during the creation of a page.
Yes I did. I was building my blueprint, while reloading the already created page.
When creating a new page, after the blueprint, the default gets applied to the tooltip, too.
But it's still strange, because the default value was applied to the slider itself correctly. Only the tooltip was missing it.
Describe the bug When a range field is added to a blueprint, the slider element reflects its current value correctly, but the right-sided label only displays the value after the slider knob has been moved.
To Reproduce Steps to reproduce the behavior:
Expected behavior If a default value is set, the slider should behave like that number has been set automatically and not complain about an invalid field. I am aware, that this would mean that a permanent save bar will be displayed after a blueprint has changed, but I find it rather less intuitive if there is a default value, that requires user interaction for becoming saveable.
Screenshots
Kirby Version 3.0.0
Console output
Desktop (please complete the following information):