Closed Bug 1563115 Opened 9 months ago Closed 7 months ago

Use HTML input instead of XUL textbox in mail/base/content/

Categories

(Thunderbird :: General, task)

task
Not set

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 71.0

People

(Reporter: aleca, Assigned: aleca)

References

Details

Attachments

(2 files, 2 obsolete files)

  • mail/base/content/editContactPanel.inc.xul
  • mail/base/content/FilterListDialog.xul
  • mail/base/content/mailWidgets.js
  • mail/base/content/mainMailToolbox.inc.xul
  • mail/base/content/messenger.xul
  • mail/base/content/newTagDialog.xul
Assignee: nobody → alessandro
Mentor: alessandro
Status: NEW → ASSIGNED
Attached patch 1563115-textbox-html-input.patch (obsolete) — Splinter Review
Attachment #9095270 - Flags: review?(mkmelin+mozilla)
Attached patch 1563115-textbox-html-input.patch (obsolete) — Splinter Review
Attachment #9095270 - Attachment is obsolete: true
Attachment #9095270 - Flags: review?(mkmelin+mozilla)
Attachment #9095326 - Flags: review?(mkmelin+mozilla)
Comment on attachment 9095326 [details] [diff] [review]
1563115-textbox-html-input.patch

Review of attachment 9095326 [details] [diff] [review]:
-----------------------------------------------------------------

LGTM. r=mkmelin with a few smaller changes.

::: mail/base/content/editContactPanel.inc.xul
@@ +56,5 @@
>      <vbox>
> +      <html:input id="editContactName" class="editContactTextbox" type="text"
> +                  onkeypress="editContactInlineUI.onKeyPress(event, true);"/>
> +      <html:input id="editContactEmail" readonly="readonly"
> +                  class="editContactTextbox" type="text"

type="email"

::: mail/base/content/mailWidgets.js
@@ +749,5 @@
>          // presented on XULComboboxAccessible generated from <menulist>;
>          // hide these nodes from the accessibility tree.
>          return document.importNode(
>            MozXULElement.parseXULToFragment(`
> +            <html:input type="text" class="menulist-input" allowevents="true"/>

please remove allowevents="true" - that would only do something for xul

::: mail/themes/shared/mail/compacttheme.css
@@ +50,5 @@
>  .editContactTextbox {
>    background-color: var(--lwt-toolbar-field-background-color);
>    color: var(--lwt-toolbar-field-color);
>  }
> +.editContactTextbox:not([readonly="readonly"]):not(:focus) {

[readonly] will do. (it's boolean, so the attribute is set or not)

::: mail/themes/shared/mail/messageHeader.css
@@ +20,5 @@
>    background-color: var(--lwt-toolbar-field-background-color);
>    color: var(--lwt-toolbar-field-color);
>  }
>  :root[lwt-default-theme-in-dark-mode]
> +  html|input.editContactTextbox:not([readonly="readonly"]):not(:focus) {

same here

::: mail/themes/windows/mail/editContactPanel.css
@@ +58,4 @@
>    border-color: Highlight;
>  }
>  
> +html|input.editContactTextbox[readonly="readonly"] {

and here
Attachment #9095326 - Flags: review?(mkmelin+mozilla) → review+

please remove allowevents="true" - that would only do something for xul

Without this it's not possible to edit the email address in the compose window after clicking "Customize..."

Ok, sounds like a good reason to leave it in ;)

Attachment #9095326 - Attachment is obsolete: true
Attachment #9096033 - Flags: review+
Keywords: checkin-needed

Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/580590b5d1b4
Convert textbox to HTML input in mail/base/content/. r=mkmelin

Status: ASSIGNED → RESOLVED
Closed: 7 months ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 71.0
Status: RESOLVED → REOPENED
Resolution: FIXED → ---

This patch takes care of the little regression introduced in the previous patch where input fields inside menulist were getting restyled and flattened.
This flat style needs to happen only in the "From" field in the compose dialog.
Fields inside other menulist, like the "Add new Category" in the New Event dialog, shouldn't be affected.

Attachment #9096433 - Flags: review?(mkmelin+mozilla)
Attachment #9096433 - Flags: review?(mkmelin+mozilla) → review+
Keywords: checkin-needed

Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/bd90ce2c4947
Follow-up: Restore class textbox-input for menulists to prevent affecting all inputs nested in a menulist. r=mkmelin

Status: REOPENED → RESOLVED
Closed: 7 months ago7 months ago
Keywords: checkin-needed
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.