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

Enable Button as ControlType #88

Closed
wants to merge 13 commits into from
Closed

Conversation

huong-li-nguyen
Copy link
Contributor

@huong-li-nguyen huong-li-nguyen commented Oct 2, 2023

Description

  • Add Button to ControlType

Screenshot

Checklist

  • I have not referenced individuals, products or companies in any commits, directly or indirectly
  • I have not added data or restricted code in any commits, directly or indirectly
  • I have updated the docstring of any public function/class/model changed
  • I have added the PR number to the change description in the changelog fragment, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1)) (if applicable)
  • I have added tests to cover my changes (if applicable)

Types of changes

  • Docs/refactoring (non-breaking change which improves codebase)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Notice

  • I acknowledge and agree that, by checking this box and clicking "Submit Pull Request":

    • I submit this contribution under the Apache 2.0 license and represent that I am entitled to do so on behalf of myself, my employer, or relevant third parties, as applicable.
    • I certify that (a) this contribution is my original creation and / or (b) to the extent it is not my original creation, I am authorised to submit this contribution on behalf of the original creator(s) or their licensees.
    • I certify that the use of this contribution as authorised by the Apache 2.0 license does not violate the intellectual property rights of anyone else.

@huong-li-nguyen huong-li-nguyen self-assigned this Oct 2, 2023
@huong-li-nguyen huong-li-nguyen changed the title Feat/button as control Enable Button as ControlType and make horizontal rulers visible Oct 2, 2023
@huong-li-nguyen huong-li-nguyen marked this pull request as ready for review October 2, 2023 17:15
@huong-li-nguyen huong-li-nguyen added Status: Ready for Review ☑️ Bug Report 🐛 Issue contains a bug report Feature Request 🤓 Issue contains a feature request labels Oct 2, 2023
Copy link
Contributor

@maxschulz-COL maxschulz-COL left a comment

Choose a reason for hiding this comment

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

Given that we have significantly extended our API, we should probably add this new type tp our user guides! It may duplicate our actions, but maybe we can find a good way to do so

@huong-li-nguyen
Copy link
Contributor Author

huong-li-nguyen commented Oct 2, 2023

Given that we have significantly extended our API, we should probably add this new type tp our user guides! It may duplicate our actions, but maybe we can find a good way to do so

Hmm.. I see your point but we would essentially duplicate our user guide on the Button (that is currently living under components) under controls as well. We could add in a section under controls and then link to the content in components? Just pushed that change - let me know what you think

Copy link
Contributor

@petar-qb petar-qb left a comment

Choose a reason for hiding this comment

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

Glad to see that ControlType supports vm.Button.
I left one comment, but other than that, the PR looks good!

vizro-core/src/vizro/static/css/layout.css Outdated Show resolved Hide resolved
@huong-li-nguyen huong-li-nguyen changed the title Enable Button as ControlType and make horizontal rulers visible Enable Button as ControlType Oct 3, 2023
@huong-li-nguyen huong-li-nguyen marked this pull request as draft October 3, 2023 10:06
@huong-li-nguyen
Copy link
Contributor Author

Closing due to decision to not add Button as an officially supported ControlType and instead go via the route of custom components such that the user can add the Button as a ControlType themselves via vm.Page.add_type("controls", vm.Button)

@huong-li-nguyen huong-li-nguyen added Type: Technical DR 💾 and removed Feature Request 🤓 Issue contains a feature request labels Oct 5, 2023
@huong-li-nguyen huong-li-nguyen deleted the feat/button_as_control branch October 5, 2023 13:47
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.

4 participants