Live data from Hacker News

Add dir=“auto” to your inputs and textareas

mough.xyz

21–30 of 114 posts

Re: Add dir=“auto” to your inputs and textareas

#21
post #2

This is indeed an easy way to fix text rendering in your inputs and textareas. However, you'll also need to do the same for elements that render the submitted text. And once you encounter bidirectional text (e.g. an English product name within an Arabic paragraph), that opens up another whole can of worms... Note also that there's currently a regression in Chrome that affects how RTL text is rendered in inputs with d…

[flagged]

Re: Add dir=“auto” to your inputs and textareas

#23

Why in 2023 is this still an issue? Frameworks and browsers should be designed that if you totally ignore rtl support, the browser/framework just does some usable default. Just like if you don't set a font size, the browser chooses one for you. Or if you don't specify the background color, one is chosen for you.

Because just rtl doesn't solve it and makes things a mess.

Full RTL flips the entire application, and most styling & libraries had a hard time with that.

For instance in react native, the react native flatlist will have some weird quirks doing that.

Re: Add dir=“auto” to your inputs and textareas

#28
post #6

Why in 2023 is this still an issue? Frameworks and browsers should be designed that if you totally ignore rtl support, the browser/framework just does some usable default. Just like if you don't set a font size, the browser chooses one for you. Or if you don't specify the background color, one is chosen for you.

> Why in 2023 is this still an issue? I mean Safari and Firefox only recently (2021) got datetime / datetime-local input support and afaik they still aren’t feature complete (html5). Date pickers have been one of the most popular / important widgets in Javascript for like the last 20 years or so. The only reason edge has it is because it’s backed by chrome (IE / MS was notorious for foot dragging in the space).

Yeah, it took a strangely long time for Safari to get a date picker.

Now if Chrome could come onboard with hanging-punctuation{}, I'd be set!

Re: Add dir=“auto” to your inputs and textareas

#30

This should be the operating systems problem to solve not developers of every website ever. Same with spellchecking, emojis, copy/paste etc.

This should be the operating systems problem to solve not developers of every website ever. Same with spellchecking, emojis, copy/paste etc.

From from your mouth to God's ear.

I wish every program would default to system-wide settings. But unfortunately, too many do their own things.

Why does Microsoft Office need a separate dictionary from the rest of my computer? Why does Wrike intercept ⇧⌘N? Why doesn't Adobe Photoshop use ⌘, for preferences like every other Mac program for the last 38 years?

It's the thousand little annoyances users run into every day that make them hate computers.

Post reply on HN