Edgewall Software
Modify

Opened 10 years ago

Closed 7 years ago

Last modified 7 years ago

#11841 closed enhancement (fixed)

Margin above Description text area on Basic Settings page

Reported by: Ryan J Ollos Owned by: Jun Omae
Priority: normal Milestone: 1.2.3
Component: admin/web Version:
Severity: normal Keywords:
Cc: Branch:
Release Notes:

Fixed poor layout of Basic Settings admin page.

API Changes:
Internal Changes:

Description (last modified by Ryan J Ollos)

The Description has a margin between the label and textarea on Firefox (test with version 33 on Ubuntu and 33.1 on Windows), but not on Chrome (version 38 on Ubuntu and Windows).

Firefox:

Chrome

Also the margin between Description and Default handler is different.

Attachments (3)

Chrome.png (10.1 KB ) - added by Ryan J Ollos 10 years ago.
Firefox.png (9.4 KB ) - added by Ryan J Ollos 10 years ago.
20170729T193247.png (6.6 KB ) - added by Jun Omae 7 years ago.

Download all attachments as: .zip

Change History (11)

by Ryan J Ollos, 10 years ago

Attachment: Chrome.png added

by Ryan J Ollos, 10 years ago

Attachment: Firefox.png added

comment:1 by Ryan J Ollos, 10 years ago

Description: modified (diff)

comment:2 by Ryan J Ollos, 8 years ago

Milestone: next-stable-1.0.xnext-stable-1.2.x

Moved ticket assigned to next-stable-1.0.x since maintenance of 1.0.x is coming to a close. Please move the ticket back if it's critical to fix on 1.0.x.

comment:3 by Ryan J Ollos, 7 years ago

Milestone: next-stable-1.2.xnext-dev-1.3.x

It seems the spacing between Description and the textarea can be fixed by removing the br:

  • trac/admin/templates/admin_basics.html

    diff --git a/trac/admin/templates/admin_basics.html b/trac/admin/templates/admin_basics.html
    index 867dfc779..02c1d4751 100644
    a b  
    3939            </label>
    4040          </div>
    4141          <div class="field">
    42             <label>${_("Description:")}<br />
     42            <label>${_("Description:")}
    4343              <textarea name="descr" class="trac-resizable" rows="3" cols="50">
    4444${project.descr}</textarea>
    4545            </label>
Last edited 7 years ago by Ryan J Ollos (previous) (diff)

in reply to:  description comment:4 by Ryan J Ollos, 7 years ago

Replying to Ryan J Ollos:

Also the margin between Description and Default handler is different.

It seems to be somehow due to the rule form.mod .field label { padding-left: .2em }.

by Jun Omae, 7 years ago

Attachment: 20170729T193247.png added

in reply to:  3 comment:5 by Jun Omae, 7 years ago

Replying to Ryan J Ollos:

It seems the spacing between Description and the textarea can be fixed by removing the br:

The following would be resulted if [trac] resizable_textareas is disabled:

Also, the original issue is occurred on 1.2-stable with Firefox 54 but it doesn't on 1.0-stable.

comment:6 by Jun Omae, 7 years ago

I consider Firefox renders a newline for br element if block element is after br element. Another workaround is to use display: inline-table rather than display: table.

  • trac/htdocs/css/trac.css

    diff --git a/trac/htdocs/css/trac.css b/trac/htdocs/css/trac.css
    index 66013e774..26c75f769 100644
    a b table.wiki tbody tr.odd { background-color: #f7f7f7 }  
    678678.wikitoolbar a#img { background-position: 0 -128px }
    679679
    680680/* Textarea resizer */
    681 div.trac-resizable { display: table; width: 100% }
     681div.trac-resizable { display: inline-table; width: 100% }
    682682div.trac-resizable > div { display: table-cell }
    683683div.trac-resizable textarea { display: block; margin-bottom: 0 }
    684684div.trac-grip {

comment:7 by Ryan J Ollos, 7 years ago

Milestone: next-dev-1.3.x1.2.3
Release Notes: modified (diff)
Resolution: fixed
Status: newclosed

Thanks, that works great and fixes both problems. Tested with FF 54, Chrome 59, Opera 46 and Safari 10 on OSX 10.12.6.

Committed to 1.2-stable in r16148, merged to trunk in r16149.

I'll rebase #11112 and re-evaluate those changes in light of this change.

Last edited 7 years ago by Ryan J Ollos (previous) (diff)

comment:8 by Ryan J Ollos, 7 years ago

Owner: set to Jun Omae

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jun Omae.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Jun Omae to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.