Skip to content
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

bad formatting for node.js API on firefox #32

Closed
jmarca opened this issue Nov 20, 2015 · 13 comments
Closed

bad formatting for node.js API on firefox #32

jmarca opened this issue Nov 20, 2015 · 13 comments

Comments

@jmarca
Copy link

jmarca commented Nov 20, 2015

Hi I couldn't figure out where the node api docs repo is, so hopefully this bug report can be redirected to the right place.

I love the node.js API docs. Stellar job there for years. However, the latest revision is quite unusable under firefox (42.0, running on slackware-current).

Here is a screen shot. Note that several words worth of left hand content are obscured by the menu column:

node_api_firefox

As you might expect, the API docs look fine under Chromium (version 46.0.2490.71), with the content properly not hiding underneath the menu.

node_api_chromium

Since I use firefox, not chromium, and since the website should be legible no matter the browser, it would be great if the API site's styles could be fixed.

I'd be happy to hack away, but again, I can't find the repo to pull and edit.

Regards,
James

@Trott
Copy link
Member

Trott commented Nov 21, 2015

/cc @nodejs/website

@therebelrobot
Copy link

I'm pretty sure this is being maintained over at nodejs/docs by the @nodejs/documentation team, as opposed to the website WG. I could be wrong though.

@silverwind
Copy link

The stylesheet in question is at https://github.com/nodejs/node/blob/master/doc/api_assets/style.css

As for this issue, I cannot reproduce in Firefox 42 and 44 on Windows, but it looks like a miscalculation between em and px units. Does this CSS work, @jmarca?

#column1.interior {
    border-left: 234px solid #f2f5f0;
}

@jmarca
Copy link
Author

jmarca commented Nov 21, 2015

@silverwind yes indeed that works.

And the response times here are astonishing. Great work.

@silverwind
Copy link

Thanks, filed nodejs/node#3948 to fix this!

@jmarca
Copy link
Author

jmarca commented Nov 21, 2015

One thing I noticed playing around is that if I change the body font-size style from 62.5% to 100%, then the formatting of the column 1 is fine at 13em.

(But I only know enough about CSS to annoy designers)

@silverwind
Copy link

@jmarca did you set a custom default font size in Firefox? (Options - Content - Fonts & Colors - Advanced)? Also, I'd be interested if the bug shows when running in Safe Mode.

@jmarca
Copy link
Author

jmarca commented Nov 21, 2015

@silverwind I only have a minimum font size of 10 set, otherwise I allow pages to set their own fonts and sizes. Unchecking the minimum font size made no difference.

What is safe mode? Is that a firefox setting?

@silverwind
Copy link

@jmarca yes, go to Menu - Help - Restart with Add-ons Disabled. This will start Firefox in Safe Mode, so we can make sure no Extensions/Settings are interfering.

@jmarca
Copy link
Author

jmarca commented Nov 21, 2015

Thanks. Restarted in safe mode and the same broken layout (main content under left hand menu)

@jmarca
Copy link
Author

jmarca commented Nov 21, 2015

Yeah it seems on my machine firefox computes the 13em border width to 134px, while chromium translates 13em to 234px. But with the body font size style changed to 100%, then firefox computes 13em as 234px.

I've no idea which browser is doing the right thing here, but chromium thinks the font size of the word "index" at the top of the page is 14.4px, while firefox with the 62.5% body font size style set thinks the word "index" is 9px, but when bfs is set to 100%, it also thinks index is 14.4px font size.

@silverwind
Copy link

@jmarca I still don't see this bug in any of my Firefox installations. Could you give it a try using a fresh Firefox profile (backing up your old one of course)?

@jmarca
Copy link
Author

jmarca commented Nov 21, 2015

As I noted in the other thread. Not a bug, my bad. A fresh firefox profile makes the layout issue go away. Accumulated cruft somewhere along the line I guess.

@jmarca jmarca closed this as completed Nov 21, 2015
silverwind added a commit to nodejs/node that referenced this issue Nov 27, 2015
By using the same unit for the offset of the main column as used for the
left column width, we ensure that browsers render the columns
conistently.

Ref: nodejs/help#32

PR-URL: #3948
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
silverwind added a commit to nodejs/node that referenced this issue Dec 1, 2015
By using the same unit for the offset of the main column as used for the
left column width, we ensure that browsers render the columns
conistently.

Ref: nodejs/help#32

PR-URL: #3948
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
silverwind added a commit to nodejs/node that referenced this issue Dec 4, 2015
By using the same unit for the offset of the main column as used for the
left column width, we ensure that browsers render the columns
conistently.

Ref: nodejs/help#32

PR-URL: #3948
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
silverwind added a commit to nodejs/node that referenced this issue Dec 5, 2015
By using the same unit for the offset of the main column as used for the
left column width, we ensure that browsers render the columns
conistently.

Ref: nodejs/help#32

PR-URL: #3948
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
silverwind added a commit to nodejs/node that referenced this issue Dec 17, 2015
By using the same unit for the offset of the main column as used for the
left column width, we ensure that browsers render the columns
conistently.

Ref: nodejs/help#32

PR-URL: #3948
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
silverwind added a commit to nodejs/node that referenced this issue Dec 23, 2015
By using the same unit for the offset of the main column as used for the
left column width, we ensure that browsers render the columns
conistently.

Ref: nodejs/help#32

PR-URL: #3948
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
scovetta pushed a commit to scovetta/node that referenced this issue Apr 2, 2016
By using the same unit for the offset of the main column as used for the
left column width, we ensure that browsers render the columns
conistently.

Ref: nodejs/help#32

PR-URL: nodejs#3948
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants