-
Notifications
You must be signed in to change notification settings - Fork 65
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
3911 do not render empty lists on article page #4293
base: master
Are you sure you want to change the base?
3911 do not render empty lists on article page #4293
Conversation
To Remove Empty Sections or Not to Remove...For Checksum and Download, I have left the section there but added a statement that there are none available. This is because these are standard sections that a reader might 'look for' and so they should not be hidden but state clearly that they are empty. But for the automated table of contents, I have removed the section entirely when it is empty. This is because the table of contents listing the sections does not make any sense in the context of an article without contents - and a reader would not look for it when there is no contents to navigate. To follow the pattern above with downloads and checksums would add to user confusion not prevent it. |
Closes #3911 |
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.
Nice one! I like the design decision to consistently display sections that are standard and often expected, like downloads and checksums.
I noticed a few things that we probably want to fix up for consistency between themes and screen sizes.
@joemull please note response #4293 (comment) for testing, I have tried all combinations of:
Following this, it seems both Clean and Material use the same toc.js. So now updating and rechecking that. |
Summary of Changes:
|
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.
Amazingly thorough! I just noticed one proofreader note that got left out of one of the galley checks.
Updated django templates to check that there are galleys before creating download and checksum lists, across all three themes. Material already checked for galleys for download lists, but not for checksums.
For empty autogenerated tables of contents in OLH theme, updated the JS to remove the
toc
element if no headings were found, i.e. if list not populated.Marked as draft as it is the end of the day, and I have yet to test this, so that must be done before sending for review.