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

[AAE-5362] Add option to make actions button visible only on hover #7117

Merged
merged 3 commits into from
Jun 22, 2021

Conversation

TomikaArome
Copy link
Contributor

Please check if the PR fulfills these requirements

  • The commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)

What kind of change does this PR introduce? (check one with "x")

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation
  • Other... Please describe:

What is the current behaviour? (You can also link to an open issue here)

https://alfresco.atlassian.net/browse/AAE-5362

What is the new behaviour?

A new option "actionsVisibleOnHover" makes it so that the action button will only be visible on row hover, or while the menu button is open.

Does this PR introduce a breaking change? (check one with "x")

  • Yes
  • No

If this PR contains a breaking change, please describe the impact and migration path for existing applications: ...

Other information:

@pr-triage pr-triage bot added the PR: draft label Jun 21, 2021
@TomikaArome TomikaArome marked this pull request as ready for review June 21, 2021 14:57
@@ -72,7 +72,8 @@
[attr.data-automation-id]="'datatable-row-' + idx">
<!-- Actions (left) -->
<div *ngIf="actions && actionsPosition === 'left'" role="gridcell" class="adf-datatable-cell">
<button mat-icon-button [matMenuTriggerFor]="menu"
<button mat-icon-button [matMenuTriggerFor]="menu" #matMenuTrigger="matMenuTrigger"
[ngClass]="{'adf-datatable-hide-actions-without-hover': actionsVisibleOnHover && !matMenuTrigger.menuOpen}"
Copy link
Contributor

Choose a reason for hiding this comment

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

It seems like it can be extracted to a class method, as it seems to be duplicated in the template

@TomikaArome TomikaArome merged commit e2b8557 into develop Jun 22, 2021
@TomikaArome TomikaArome deleted the dev-thunter-AAE-5362 branch June 22, 2021 15:28
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.

2 participants