Skip to content

Commit 9c84a7e

Browse files
Merge pull request #1 from wptrainingteam/update/editor-styles
Retarged CSS to account for editorial experience
2 parents 9737323 + d7b53c4 commit 9c84a7e

File tree

3 files changed

+9
-6
lines changed

3 files changed

+9
-6
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ Feel free to fork it and use it however you like!
1818

1919
## Changelog
2020

21+
### August 19, 2024 - v1.0.1
22+
23+
Update CSS to account for editing experience: remove hiding/showing of elements by targeting `:not(.has-child-selected)`.
24+
2125
### July 18, 2024 - v1.0.0
2226

2327
Initial launch.

assets/styles/core-blocks/cover-card--interactive.css

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
position: static;
1212
}
1313
/* Make whole card clickable */
14-
.is-style-card--interactive :where(.wp-block-heading) a:after {
14+
.is-style-card--interactive:not(.has-child-selected) :where(.wp-block-heading) a:after {
1515
content: "";
1616
inset: 0;
1717
position: absolute;
@@ -23,8 +23,8 @@
2323
transform: scale(1);
2424
transition: all 0.35s ease;
2525
}
26-
.is-style-card--interactive:focus-within :where(.wp-block-cover__image-background),
27-
.is-style-card--interactive:hover :where(.wp-block-cover__image-background) {
26+
.is-style-card--interactive:not(.has-child-selected):focus-within :where(.wp-block-cover__image-background),
27+
.is-style-card--interactive:not(.has-child-selected):hover :where(.wp-block-cover__image-background) {
2828
filter: saturate(200%) brightness(40%);
2929
transform: scale(1.15);
3030
}
@@ -42,7 +42,7 @@
4242
transform: scale(1) translateX(0);
4343
}
4444
/* Animate content area */
45-
.is-style-card--interactive :where(.is-vertical) .wp-block-group:first-of-type + .wp-block-group p {
45+
.is-style-card--interactive:not(.has-child-selected) :where(.is-vertical) .wp-block-group:first-of-type + .wp-block-group p {
4646
max-height: 0;
4747
opacity: 0;
4848
overflow: hidden;

hover-reveal-card.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* Description: Extends the Cover block for an animating card effect.
55
* Requires at least: 6.6
66
* Requires PHP: 8.0
7-
* Version: 1.0.0
7+
* Version: 1.0.1
88
* Author: Damon Cook
99
* License: GPL-2.0-or-later
1010
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
@@ -15,7 +15,6 @@
1515
exit; // Exit if accessed directly.
1616
}
1717

18-
1918
/**
2019
* Enqueues the block styles for the plugin.
2120
*/

0 commit comments

Comments
 (0)