Closed Bug 1688325 Opened 3 years ago Closed 3 years ago

The new non-native widget theme doesn't have any padding between blinking cursor & border, in a textarea

Categories

(Core :: Widget, defect)

defect

Tracking

()

RESOLVED FIXED
87 Branch
Tracking Status
firefox87 --- fixed

People

(Reporter: dholbert, Assigned: emilio)

References

Details

Attachments

(3 files)

+++ This bug was initially created as a clone of Bug #1686606 +++

STR:

  1. Run Firefox with about:config widget.disable-native-theme-for-content set to true.
  2. View https://bugzilla.mozilla.org/attachment.cgi?id=9196980
  3. Focus the textarea (the lower/taller form control)

ACTUAL RESULTS:
In the textarea, the blinking cursor is flush with (or maybe even overlaps?) the top border. This makes it look a bit misaligned / overflowing.

For comparison: in the textfield (the first widget), there's a little bit of space between the cursor and the borders, as of today's Nightly (thanks to bug 1686606).

EXPECTED RESULTS:
There should be a little bit of blank padding-area between the blinking cursor and the textarea's border, to visually separate them.

ni=emilio in case he's up for taking a look, since he just landed a fix for related bug 1686606.

Flags: needinfo?(emilio)

We don't have any padding on textareas by default. I see the same behavior on other themes. We could certainly add some (Chrome seems to have 2px padding by default). But this doesn't seem like a non-native theme specific thing, unless I'm missing something?

Flags: needinfo?(emilio) → needinfo?(dholbert)

Hmm -- on Ubuntu and MacOS, I do indeed see that there's no padding by default.

However, on Windows (where most of our users are), there does seem to be 2px of padding, in the default theme on Firefox release. (screenshot coming up). So we probably don't want to regress that; and given that it seems webcompat-friendly (per Chrome's behavior), maybe we should adopt it as our cross-platform standard behavior in the new non-native theme?

Flags: needinfo?(dholbert)
Attachment #9198793 - Attachment description: screenshot of textarea on Win10 with Firefox release (v84) → screenshot of rough expected rendering, using textarea on Win10 with Firefox release (v84)

Here's the default computed 'padding' styles of a textarea, in current Firefox on Win10 -- as you can see, it's 2px on all sides.

(On Ubuntu [not shown here], I do see that we have 0px padding on the top and bottom, by default. But on Win10, we seem to use 2px on all sides.)

This matches other browsers, and the default themed textareas on Windows
too.

To be landed after the soft freeze, just in case, of course.

Assignee: nobody → emilio
Status: NEW → ASSIGNED
Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/64682b454ac6
Make textarea default padding 2px on all platforms. r=dholbert
See Also: → 1688611
Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/f2cef92ec339
Make textarea default padding 2px on all platforms. r=dholbert,jdescottes
Flags: needinfo?(emilio)
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 87 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: