fix input box issues (#15587)

This commit is contained in:
Alan Ren
2021-05-27 09:35:59 -07:00
committed by GitHub
parent b75e688a7e
commit 3946cee33c
4 changed files with 30 additions and 0 deletions

View File

@@ -93,6 +93,16 @@ export class InputBox extends vsInputBox {
public setHeight(value: string) {
if (this._isTextAreaInput) {
this.inputElement.style.height = value;
this.inputElement.style.whiteSpace = 'normal';
}
}
public setMaxLength(value: number | undefined) {
if (value === undefined) {
this.inputElement.removeAttribute('maxLength');
}
else {
this.inputElement.maxLength = value;
}
}