Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit 708fff9

Browse files
Splaktarmmalerba
authored andcommitted
fix(list): case where user is unable to interact w/ secondary actions (#11539)
<!-- Filling out this template is required! Do not delete it when submitting a Pull Request! Without this information, your Pull Request may be auto-closed. --> ## PR Checklist Please check that your PR fulfills the following requirements: - [x] The commit message follows [our guidelines](https://github.com/angular/material/blob/master/.github/CONTRIBUTING.md#-commit-message-format) - [ ] Tests for the changes have been added or this is not a bug fix / enhancement - [x] Docs have been added, updated, or were not required ## PR Type What kind of change does this PR introduce? <!-- Please check the one that applies to this PR using "x". --> ``` [x] Bugfix [ ] Enhancement [ ] Documentation content changes [ ] Code style update (formatting, local variables) [ ] Refactoring (no functional changes, no api changes) [ ] Build related changes [ ] CI related changes [ ] Infrastructure changes [ ] Other... Please describe: ``` ## What is the current behavior? If the secondary actions' template was provided by a directive, then the actions would be behind the primary button. This meant that tooltips and clicks were not activated. <!-- Please describe the current behavior that you are modifying and link to one or more relevant issues. --> Issue Number: Fixes #9676 ## What is the new behavior? Secondary action tooltips and clicks were are activated when the template is provided by a directive. ## Does this PR introduce a breaking change? ``` [ ] Yes [x] No ``` <!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below. --> <!-- Note that breaking changes are highly unlikely to get merged to master unless the validation is clear and the use case is critical. --> ## Other information #9676 proposed adding a `z-index` to the `md-secondary-container`, but the container did not have a position. By the spec, `z-index` should only be on "positioned" elements. Adding positioning resolved the issue w/o needing to define a `z-index`.
1 parent bf5bbfc commit 708fff9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/components/list/list.scss

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,9 @@ md-list-item {
284284
.md-secondary-container {
285285
display: flex;
286286
align-items: center;
287+
// Ensure the secondary button is not behind the primary button if its template is provided by
288+
// a directive.
289+
position: relative;
287290

288291
// Per W3C: https://www.w3.org/TR/css-flexbox/#flex-common
289292
// By default, flex items won’t shrink below their minimum content size.

0 commit comments

Comments
 (0)