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

feat: add initial Popover component implementation #6332

Merged
merged 11 commits into from
Jun 2, 2024

Conversation

web-padawan
Copy link
Member

@web-padawan web-padawan commented May 29, 2024

Description

Part of vaadin/platform#5271

The following logic is implemented:

  • adding children
    • the logic and PopoverChildrenTest copied from Dialog
  • implementing HasStyle
    • the logic and PopoverHasStyleTest copied from Dialog
  • setTarget() and getTarget()
    • including a logic that checks for target detach / reattach
  • setFor() and getFor()
  • setPosition() and getPosition()
    • the PopoverPosition enum is a copy of TooltipPosition

Type of change

  • Feature

@web-padawan web-padawan force-pushed the feat/popover-initial branch 4 times, most recently from 61ddb5c to a69ab61 Compare May 29, 2024 12:49
@web-padawan web-padawan marked this pull request as ready for review May 30, 2024 08:25
@web-padawan web-padawan requested review from tomivirkki and vursen May 30, 2024 08:26
* Constructs an empty popover.
*/
public Popover() {
getElement().getNode().addAttachListener(this::attachComponentRenderer);
Copy link
Contributor

Choose a reason for hiding this comment

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

Could be moved to onAttach?

Copy link
Member Author

Choose a reason for hiding this comment

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

This was added in Dialog in this PR: vaadin/vaadin-dialog-flow#128. I'm not sure if onAttach works the same as getNode().addAttachListener() so I'd prefer to keep this in line with the Dialog logic.

Copy link

sonarqubecloud bot commented Jun 1, 2024

Quality Gate Passed Quality Gate passed

Issues
26 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
3.1% Duplication on New Code

See analysis details on SonarCloud

@web-padawan web-padawan merged commit 836f59b into main Jun 2, 2024
5 checks passed
@web-padawan web-padawan deleted the feat/popover-initial branch June 2, 2024 13:43
@vaadin-bot
Copy link
Collaborator

This ticket/PR has been released with Vaadin 24.5.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants