diff --git a/pxtblocks/plugins/math/fieldSlider.ts b/pxtblocks/plugins/math/fieldSlider.ts index 69860a1d4b36..1b634166c334 100644 --- a/pxtblocks/plugins/math/fieldSlider.ts +++ b/pxtblocks/plugins/math/fieldSlider.ts @@ -167,6 +167,11 @@ export class FieldSlider extends Blockly.FieldNumber { Blockly.hideChaff(); break; } + case "ArrowDown": { + e.preventDefault(); + e.stopPropagation(); + break; + } } } @@ -181,6 +186,10 @@ export class FieldSlider extends Blockly.FieldNumber { // editor on mobile devices. super.showEditor_(_e, true); + if (typeof this.min_ === "number" && typeof this.max_ === "number") { + this.htmlInput_.ariaLabel = lf("Enter a value between {0} and {1}", this.min_, this.max_); + } + Blockly.DropDownDiv.hideWithoutAnimation(); Blockly.DropDownDiv.clearContent(); Blockly.DropDownDiv.getContentDiv().style.height = "";