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

Expand header_widget to include doc path, citation and help text #70

Merged
merged 2 commits into from
Apr 11, 2024

Conversation

K-Meech
Copy link
Contributor

@K-Meech K-Meech commented Apr 11, 2024

Description

What is this PR

  • Bug fix
  • Addition of a new feature
  • Other

Why is this PR needed?
The header_widget currently doesn't support some of the required features for existing brainglobe headers like cellfinder and brainrender-napari

What does this PR do?
This PR adds new features to the header_widget:

  • Makes tutorial links optional
  • Adds option for documentation links
  • Adds option for citation doi
  • Adds option for help text
  • Adds option for github repo name (if not the same as the package name)

References

For brainglobe/cellfinder#327

How has this PR been tested?

All tests pass locally.

Is this a breaking change?

No

Does this PR require an update to the documentation?

Relevant docstrings have been updated.

Checklist:

  • The code has been tested locally
  • Tests have been added to cover all new functionality (unit & integration)
  • The documentation has been updated to reflect any changes
  • The code has been formatted with pre-commit

@K-Meech K-Meech requested a review from a team April 11, 2024 10:33
Copy link

codecov bot commented Apr 11, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.70%. Comparing base (17e5ebc) to head (3556a72).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #70      +/-   ##
==========================================
+ Coverage   89.07%   90.70%   +1.62%     
==========================================
  Files          35       35              
  Lines        1355     1377      +22     
==========================================
+ Hits         1207     1249      +42     
+ Misses        148      128      -20     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@K-Meech
Copy link
Contributor Author

K-Meech commented Apr 11, 2024

Example usage for cellfinder in this draft PR

Copy link
Contributor

@willGraham01 willGraham01 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few minor docstring things, and technically PEP wants us to include the Optional keyword in the typehints (personally I still believe it's overkill but the PEP overlords have spoken).

brainglobe_utils/qtpy/logo.py Outdated Show resolved Hide resolved
brainglobe_utils/qtpy/logo.py Outdated Show resolved Hide resolved
brainglobe_utils/qtpy/logo.py Outdated Show resolved Hide resolved
@K-Meech
Copy link
Contributor Author

K-Meech commented Apr 11, 2024

All fixed now @willGraham01 ! Hopefully the PEP overlords are satisfied 😆. Feel free to merge if you're happy with it

@willGraham01 willGraham01 merged commit d27d63d into main Apr 11, 2024
12 checks passed
@willGraham01 willGraham01 deleted the fix_html_headers branch April 11, 2024 14:42
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.

2 participants