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

ENH: Standardize header buttons #490

Merged
merged 4 commits into from
Feb 23, 2022

Conversation

choldgraf
Copy link
Member

@choldgraf choldgraf commented Feb 20, 2022

This standardizes our header button behavior, to automate more things, and ensure standard structure, style, and behavior. The user-facing API shouldn't change at all, this is all under-the-hood stuff. However, this should make it much less work to create a "pluggable" header infrastructure when the time comes (ref: #470)

Major changes:

  • We now have macros that create different kinds of topbar buttons, and we re-use these throughout
  • The header button logic now creates a list of dictionaries that define metadata for the header buttons - this is then rendered into the proper HTML at the end
  • Updated the style of the header buttons so that it doesn't use alternating background colors
  • The timing of the tooltips is a bit more delayed now so they don't pop up immediately
  • Rename the "topbar" to the "article header", in line with the basic-ng theme and more specific.
  • Had to update (and in some cases simplify) a bunch of test infrastructure to accommodate the more standard buttons

supercedes #425

OLD:

chrome_seWZ5sxM4t

NEW:

chrome_kmEDOUCOK9

@choldgraf choldgraf marked this pull request as ready for review February 20, 2022 21:14
@choldgraf choldgraf merged commit 6e4ff41 into executablebooks:master Feb 23, 2022
@choldgraf choldgraf deleted the maint-simplify-buttons2 branch February 23, 2022 22:54
@choldgraf
Copy link
Member Author

Will merge this one in so that we can cut a pre-release and give others a chance to try it out. I took another look and don't think there are any regressions, but something might pop up (if there is something, I suspect it'd be the launch button URL generation)

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

Successfully merging this pull request may close these issues.

1 participant