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

Implemented title option for BannerImage plugin #572

Merged
merged 6 commits into from
Jan 20, 2022
Merged

Implemented title option for BannerImage plugin #572

merged 6 commits into from
Jan 20, 2022

Conversation

izzy-el
Copy link
Contributor

@izzy-el izzy-el commented Jan 19, 2022

Users can now specify if they want the image to be placed on the top or on the bottom of the BannerImage (center is the default). This is done by the css property align-items.


Contributor checklist

  • 🎉 This PR closes BannerImage plugin - title option #530 .
  • 📜 I have broken down my PR into the following tasks:
    • Implement the align-items property on _banner_image.py.
    • Remove align-items from webviz_config.css.
  • 🤖 I have added tests, or extended existing tests, to cover any new features or bugs fixed in this PR.
  • 📖 I have considered adding a new entry in CHANGELOG.md, and added it if should be communicated there.

Implemented the option to choose if the title of the Banner Image should stay on the top, on the bottom, or on the center. Previously, the title would always be placed in the center of the Image.
We are asking the user to pass if they want the text to be placed on the top or on the bottom of the image (center is the default). Therefore, align-items is passed on the style on the  and, because of that, this property was removed from the .
Copy link
Collaborator

@anders-kiaer anders-kiaer left a comment

Choose a reason for hiding this comment

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

Nice @izzy-el - this looks almost ready to merge 🎉 One small comment below, and perhaps add a short changelog entry in ./CHANGELOG.md?

@izzy-el izzy-el changed the title Impĺemented title option for BannerImage plugin Implemented title option for BannerImage plugin Jan 19, 2022
Implemented a try-except block for catching a KeyError and replaced the if statement by a constant dictionary.
@izzy-el izzy-el requested a review from anders-kiaer January 20, 2022 15:11
Copy link
Collaborator

@anders-kiaer anders-kiaer left a comment

Choose a reason for hiding this comment

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

Great @izzy-el - thanks for the contribution 🎉 We will include this in the upcoming pre-release and release.

@izzy-el
Copy link
Contributor Author

izzy-el commented Jan 20, 2022

Thank you! I appreciate it!

@anders-kiaer anders-kiaer merged commit 33ae509 into equinor:master Jan 20, 2022
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.

BannerImage plugin - title option
2 participants