Download & Extend

Tips for Text format filters have excessive left|right padding on narrow screens

Project:Drupal core
Version:8.x-dev
Component:CSS
Category:task
Priority:normal
Assigned:Unassigned
Status:closed (fixed)
Issue tags:d8mux, d8mux-admin, mobile, Responsive Design, Usability

Issue Summary

Meta Issue:#1870944: [Meta] Mobile friendly admin pages

Problem/Motivation

When viewing node/add pages (node/add/%) in small screens, the text formatter block has misaligned text and excessive padding on its list of text formats.

screenshot of text formatter showing the bugs

Note: the odd wrapping on “More information on text formats” link and the excessive indenting on the bulleted list.

Proposed resolution

Catch suggested that we didn't need the bullet list padding for any viewport sizes (not just a mobile thing.) So we need to remove the padding from the bullet list and also remove the padding from the left side of the more info link.

Remaining tasks

None.

AttachmentSizeStatusTest resultOperations
node add- text formats.PNG10.06 KBIgnored: Check issue status.NoneNone

Comments

#1

Status:active» needs review
AttachmentSizeStatusTest resultOperations
filter-tips-narrow-1902872.patch871 bytesIdlePASSED: [[SimpleTest]]: [MySQL] 48,645 pass(es).View details
filter-tips.png35.65 KBIgnored: Check issue status.NoneNone

#2

Status:needs review» needs work

The last submitted patch, filter-tips-narrow-1902872.patch, failed testing.

#3

Status:needs work» needs review

#1: filter-tips-narrow-1902872.patch queued for re-testing.

#4

Title:Text formatter alignment in node/add pages, narrow screens» Text format filter tips alignment on narrow screens

#5

It's not clear to me what the issue actually is. When I added the the padding from the patch to the tips class (via Firebug and/or in Chrome's Developer tools) I didn't see any change, even for very narrow viewports.

#6

@jmarkel, I do see it as the screenshots show the before (in issue summary) + after (in #1). There's a browser default 40px margin on a ul. The patch removes it on narrow viewports. Sometimes you need to reload while in the narrow width to see it as it would load narrow.

#7

Title:Text format filter tips alignment on narrow screens» Tips for Text format filters have excessive left|right padding on narrow screens
Status:needs review» reviewed & tested by the community

Got it - it wasn't obvious what to look for even when looking at the screenshots, since the text wasn't really mis-aligned at all, there was just too much whitespace to the left (or right on rtl).

Looks good!

Thanks!

#8

Status:reviewed & tested by the community» needs review

Is the padding really needed for wider screen sizes?

#9

#catch, I figured indented is normal list display, but it will certainly be just as readable either way.

#10

Agreed - the padding could certainly be eliminated for all widths but, in the interest of treading lightly with UX changes, perhaps it shouldn't be...

#11

Assigned to:Anonymous» keyhitman

#12

keyhitman - why are you assigning to yourself? There's a good patch - just a question about whether it should apply for all viewports or only narrow ones. Do you have an opinion on that?

#13

Following discussion at #10 I reworked the patch to apply to all viewports.

AttachmentSizeStatusTest resultOperations
1902872-filter-tips-padding.patch733 bytesIdleFAILED: [[SimpleTest]]: [MySQL] Unable to apply patch 1902872-filter-tips-padding.patch. Unable to apply patch. See the log in the details link for more information.View details

#14

Assigned to:keyhitman» Anonymous

Attached screenshots of before and after.

Desktop wide - before.png

Desktop wide - after.png

AttachmentSizeStatusTest resultOperations
Desktop wide - before.png34.81 KBIgnored: Check issue status.NoneNone
Desktop wide - after.png34.73 KBIgnored: Check issue status.NoneNone

#15

The "More information about text formats" link was also displaying weirdly in the mobile screenshot in the initial summary. Can I get a screenshot for narrow viewports after the patch?

#16

Fixed the "More Information about text formats" link as per #15. Screenshots are attached
more info - before.png

more info - after.png

AttachmentSizeStatusTest resultOperations
filter-tips-padding-1902872-16.patch944 bytesIdleFAILED: [[SimpleTest]]: [MySQL] Unable to apply patch filter-tips-padding-1902872-16.patch. Unable to apply patch. See the log in the details link for more information.View details
more info - before.png13.6 KBIgnored: Check issue status.NoneNone
more info - after.png13.02 KBIgnored: Check issue status.NoneNone

#17

Status:needs review» needs work

+++ b/core/modules/filter/filter.admin.css
@@ -32,7 +32,7 @@
-  padding: 0 20px;
+  padding: 0 20px 0 0;

This is exactly the change we need to make. But it adds a left-to-right specific styling. So you need to add a /* LTR */ comment after the declaration and then add the -rtl version to filter.admin-rtl.css.

#18

Status:needs work» needs review

Have added -rtl version styling and a /* LTR */ comment as per #17.

AttachmentSizeStatusTest resultOperations
filter-tips-padding-1902872-18.patch981 bytesIdleFAILED: [[SimpleTest]]: [MySQL] Unable to apply patch filter-tips-padding-1902872-18.patch. Unable to apply patch. See the log in the details link for more information.View details

#19

Status:needs review» reviewed & tested by the community

Drupal.org is pissing me off. I'm uploading the image from the initial posting again, so I can embed it.

[edit: whoops. didn't mean to RTBC it yet.]

AttachmentSizeStatusTest resultOperations
node add- text formats.PNG10.06 KBIgnored: Check issue status.NoneNone

#20

Ok. I've updated the issue summary because I've confirmed that the patch uses the proper solution.

The patch is still in the testing bot queue, but it is a CSS-only fix, so it can't possibly affect any tests. This is RTBC and safe to commit. :-)

#21

Status:reviewed & tested by the community» fixed

Wow, that looks much better! RTL support too! :D

Committed and pushed to 8.x. Thanks!

#22

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

nobody click here