Skip to content

Commit

Permalink
Fix text selection in budget heading
Browse files Browse the repository at this point in the history
The `inverted-selection` rules defined in the `%brand-background`
selector weren't being applied because we were using this selector in
`::before` and `::after` pseudoelements. Not sure about the reason, but
it looks like the saturation of `::after::selection` pseudoelements
resulted in invalid selectors and so the inverted selection rules were
ignored for every selection using `%brand-background`, like
`%budget-header`.

Using `@include brand-background` instead of `@extend %brand-background`
in pseudoelements solves the issue. The inverted selection might not
work in these pseudoelements, but we don't need it there since these
pseudoelements don't have content.
  • Loading branch information
javierm committed Jun 29, 2023
1 parent 59d260c commit 6892740
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -13,7 +13,7 @@
text-transform: uppercase;

&::before {
@extend %brand-background;
@include brand-background;
border-radius: 50%;
content: "";
height: 20px;
Expand Down
2 changes: 1 addition & 1 deletion app/assets/stylesheets/budgets/single_heading.scss
Expand Up @@ -4,7 +4,7 @@
position: relative;

&::after {
@extend %brand-background;
@include brand-background;
bottom: 0;
content: "";
height: rem-calc(6);
Expand Down

0 comments on commit 6892740

Please sign in to comment.