Skip to content

Commit

Permalink
fix (text & heading blocks): Apply text gradient color to spelling er…
Browse files Browse the repository at this point in the history
…rors (#3314)

* use ::spelling-error

* move styles to editor-block.scss
  • Loading branch information
mxkae authored Oct 8, 2024
1 parent 1b3c1d0 commit 8bd5380
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/styles/editor-block.scss
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,22 @@
margin-top: 0;
}

// Typography
// ::spelling-error is not supported by Firefox so we need to separate it to prevent the style rule above from being invalid
// and because :is() does not allow pseudo-elements inside it.
.stk--is-gradient::spelling-error,
.stk--is-gradient li::spelling-error,
.stk--is-gradient span::spelling-error,
.stk--is-gradient a::spelling-error {
background-clip: text;
-webkit-background-clip: text;
-moz-background-clip: text;
-o-background-clip: text;
-webkit-text-fill-color: transparent;
-moz-text-fill-color: transparent;
-o-text-fill-color: transparent;
}

// Deprecated styles.
@import "deprecated-editor-block";

Expand Down

0 comments on commit 8bd5380

Please sign in to comment.