Wp-calypso: DevDocs: Primary Container gets cutoff when user not logged in (smaller screens)

Created on 17 Oct 2016  Â·  7Comments  Â·  Source: Automattic/wp-calypso

Steps to reproduce

  1. Make sure you are logged out of WordPress
  2. Go to https://wpcalypso.wordpress.com/devdocs/design

    Browser / OS version

Chrome/Windows
Firefox/Ubuntu

Screenshot / Video

image

DevDocs OSS Citizen [Type] Bug

All 7 comments

Good find @aladwig06 — want to take a look at a fix? CC @mtias

Hi Lance,

I'm actually looking into it right now. I looks like the intent was to only allow logged in users to be able to view the docs.

This is the line of code that lead me to that conclusion:

From: (https://github.com/Automattic/wp-calypso/blob/master/client/layout/logged-out.jsx)

const classes = classNames( 'layout', {
[ 'is-group-' + section.group ]: !! section,
[ 'is-section-' + section.name ]: !! section,
'focus-content': true,
'has-no-sidebar': true, // Logged-out never has a sidebar <----------
'wp-singletree-layout': !! primary,
} );

This implies that you should have to be logged in to see the devdocs or else you will only see the start screen which doesn't have the sidebar.

However, if I click on the devdocs link when I am on the start screen (without logging in), I am taken right to the devdocs and shown the screen displayed above (with the cut off sections).

Do you know if the intent is to require users log in to be able to access the devdocs or are logged out users supposed to have access too?

Thanks,

Andrew

Do you know if the intent is to require users log in to be able to access the devdocs or are logged out users supposed to have access too?

Logged-out users should have access to DevDocs, yes.

Ok thanks. I'll see if I can come up with a fix.

Ok. I've got a fix. I'm going to submit a pull request.

Thanks for reporting @aladwig06. As you've probably noticed, the fix in #8815 would break practically all other logged-out sections (such as /design or /theme). FYI, I've started working on a fix in #8454.

Ok. I didn't realize those sections were accessible when logged out also.

Was this page helpful?
0 / 5 - 0 ratings