-
-
Notifications
You must be signed in to change notification settings - Fork 290
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MBS-9323: Fix long URLs distorting page layout. #505
Conversation
Can one of the admins verify this patch? |
root/static/styles/layout.less
Outdated
@@ -18,6 +18,7 @@ body { | |||
a { | |||
color:@link-default; | |||
text-decoration: none; | |||
word-break: keep-all; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
word-break: break-all;
should be a better choice here, IMO. works in most browsers, including webkit-based ones
|
Agreed. |
Unfortunately this overrides our other |
@mwiencek I will make it specific - as offered in the original description. |
root/static/styles/layout.less
Outdated
@@ -18,6 +18,10 @@ body { | |||
a { | |||
color:@link-default; | |||
text-decoration: none; | |||
|
|||
&#sidebar { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That matches a#sidebar
, i.e. a link with id="sidebar"
. :) You need an a
rule inside the #sidebar
block instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh - yes - you are right. Apologies.
root/static/styles/layout.less
Outdated
@@ -18,7 +18,7 @@ body { | |||
a { | |||
color:@link-default; | |||
text-decoration: none; | |||
|
|||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Random whitespace? :(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:-(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Property word-break: break-all
of element a
is ignored by the current version of Firefox. It should be applied it to one of its ancestors instead, ul.external_links
for example.
@yvanzo: Just tested this with Firefox and you are indeed right. |
root/static/styles/layout.less
Outdated
@@ -386,6 +386,10 @@ div.warning img.warning { | |||
margin-top: 0; | |||
} | |||
|
|||
#sidebar ul.external_links { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have a block for #sidebar ul.external_links
right below this on line 398, so it'd be good to put this rule inside the existing block.
* master: MBS-9403: Output track position in JSON WS MBS-9391: Update import_db.sh to retry downloading dumps. Remove old/unused deployment files Fix User::Edit tests for MBS-9355 Update User::Edit tests for MBS-9355 MBS-9355: Disable bio and website of limited users MBS-9353: Requires login for /collection and /user MBS-9372: Allow notes from voting-disabled editor MBS-9323: Fix long URLs distorting page layout. (#505) MBS-9369: Support for importing dumps in the test-database image Add workaround for packet #104949 Fix alias merge logic MBS-9365: Create event_meta_fk_id for old standalone DBs Remove redundant command MBS-9342: Fix imports with DBD::Pg 3.6.0 Remove pg_enable_utf8 Clarify comment about pg_server_prepare
* beta: Fix instrument table names in DropTriggers.sql MBS-9403: Output track position in JSON WS MBS-9401: Fix sql query to fetch releases in dump-entities-sql.pl MBS-9391: Update import_db.sh to retry downloading dumps. Remove old/unused deployment files Fix User::Edit tests for MBS-9355 Update User::Edit tests for MBS-9355 MBS-9355: Disable bio and website of limited users MBS-9353: Requires login for /collection and /user MBS-9372: Allow notes from voting-disabled editor MBS-9323: Fix long URLs distorting page layout. (#505) MBS-9369: Support for importing dumps in the test-database image Add workaround for packet #104949 Fix alias merge logic MBS-9365: Create event_meta_fk_id for old standalone DBs Remove redundant command MBS-9342: Fix imports with DBD::Pg 3.6.0 Remove pg_enable_utf8 Clarify comment about pg_server_prepare
Long URLs do not wrap and cause page distortion e.g. in https://musicbrainz.org/artist/f2b1690b-7b7a-4364-9764-098ecf87f794 a Wikipedia url with a very long #id caused the sidebar to take c. 80% of page width.
This proposed fix is applied to all
<a>
tags on every page. Further selectors can be added to e.g. restrict this to the sidebar if that is prefered. e.g.Resolves https://tickets.metabrainz.org/browse/MBS-9323