Add dir='auto' to textfields, see #1116

This commit is contained in:
Pieter Vander Vennet 2022-11-14 00:45:08 +01:00
parent b68a140af9
commit f7953e46cf

View file

@ -131,6 +131,7 @@ export class TextField extends InputElement<string> {
el.rows = options.textAreaRows
el.cols = 50
el.style.width = "100%"
el.dir = "auto"
inputEl = el
if (placeholderStore) {
placeholderStore.addCallbackAndRunD((placeholder) => (el.placeholder = placeholder))
@ -141,6 +142,7 @@ export class TextField extends InputElement<string> {
el.inputMode = options.inputMode
el.placeholder = placeholder
el.style.cssText = options.inputStyle ?? "width: 100%;"
el.dir = "auto"
inputEl = el
if (placeholderStore) {
placeholderStore.addCallbackAndRunD((placeholder) => (el.placeholder = placeholder))