@wordpress/block-library 7.3.3 → 7.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/build/comments-title/edit.js +7 -5
  2. package/build/comments-title/edit.js.map +1 -1
  3. package/build/navigation/edit/inner-blocks.js +5 -7
  4. package/build/navigation/edit/inner-blocks.js.map +1 -1
  5. package/build/navigation-link/edit.js +29 -30
  6. package/build/navigation-link/edit.js.map +1 -1
  7. package/build/navigation-submenu/edit.js +14 -14
  8. package/build/navigation-submenu/edit.js.map +1 -1
  9. package/build/post-content/edit.js +1 -1
  10. package/build/post-content/edit.js.map +1 -1
  11. package/build-module/comments-title/edit.js +7 -5
  12. package/build-module/comments-title/edit.js.map +1 -1
  13. package/build-module/navigation/edit/inner-blocks.js +5 -7
  14. package/build-module/navigation/edit/inner-blocks.js.map +1 -1
  15. package/build-module/navigation-link/edit.js +29 -30
  16. package/build-module/navigation-link/edit.js.map +1 -1
  17. package/build-module/navigation-submenu/edit.js +14 -14
  18. package/build-module/navigation-submenu/edit.js.map +1 -1
  19. package/build-module/post-content/edit.js +1 -1
  20. package/build-module/post-content/edit.js.map +1 -1
  21. package/build-style/comment-content/style-rtl.css +81 -0
  22. package/build-style/comment-content/style.css +81 -0
  23. package/build-style/cover/style-rtl.css +1 -1
  24. package/build-style/cover/style.css +1 -1
  25. package/build-style/latest-posts/style-rtl.css +2 -0
  26. package/build-style/latest-posts/style.css +4 -0
  27. package/build-style/style-rtl.css +3 -1
  28. package/build-style/style.css +5 -1
  29. package/package.json +8 -8
  30. package/src/comment-author-name/index.php +7 -5
  31. package/src/comment-content/index.php +25 -3
  32. package/src/comment-content/style.scss +5 -0
  33. package/src/comments-title/edit.js +20 -4
  34. package/src/comments-title/index.php +14 -7
  35. package/src/cover/index.php +1 -1
  36. package/src/cover/style.scss +1 -1
  37. package/src/latest-posts/style.scss +4 -0
  38. package/src/navigation/edit/inner-blocks.js +5 -7
  39. package/src/navigation-link/edit.js +40 -43
  40. package/src/navigation-submenu/edit.js +13 -17
  41. package/src/post-comments-form/index.php +4 -1
  42. package/src/post-content/edit.js +15 -1
@@ -0,0 +1,81 @@
1
+ /**
2
+ * Colors
3
+ */
4
+ /**
5
+ * Breakpoints & Media Queries
6
+ */
7
+ /**
8
+ * SCSS Variables.
9
+ *
10
+ * Please use variables from this sheet to ensure consistency across the UI.
11
+ * Don't add to this sheet unless you're pretty sure the value will be reused in many places.
12
+ * For example, don't add rules to this sheet that affect block visuals. It's purely for UI.
13
+ */
14
+ /**
15
+ * Colors
16
+ */
17
+ /**
18
+ * Fonts & basic variables.
19
+ */
20
+ /**
21
+ * Grid System.
22
+ * https://make.wordpress.org/design/2019/10/31/proposal-a-consistent-spacing-system-for-wordpress/
23
+ */
24
+ /**
25
+ * Dimensions.
26
+ */
27
+ /**
28
+ * Shadows.
29
+ */
30
+ /**
31
+ * Editor widths.
32
+ */
33
+ /**
34
+ * Block & Editor UI.
35
+ */
36
+ /**
37
+ * Block paddings.
38
+ */
39
+ /**
40
+ * React Native specific.
41
+ * These variables do not appear to be used anywhere else.
42
+ */
43
+ /**
44
+ * Converts a hex value into the rgb equivalent.
45
+ *
46
+ * @param {string} hex - the hexadecimal value to convert
47
+ * @return {string} comma separated rgb values
48
+ */
49
+ /**
50
+ * Breakpoint mixins
51
+ */
52
+ /**
53
+ * Long content fade mixin
54
+ *
55
+ * Creates a fading overlay to signify that the content is longer
56
+ * than the space allows.
57
+ */
58
+ /**
59
+ * Focus styles.
60
+ */
61
+ /**
62
+ * Applies editor left position to the selector passed as argument
63
+ */
64
+ /**
65
+ * Styles that are reused verbatim in a few places
66
+ */
67
+ /**
68
+ * Allows users to opt-out of animations via OS-level preferences.
69
+ */
70
+ /**
71
+ * Reset default styles for JavaScript UI based pages.
72
+ * This is a WP-admin agnostic reset
73
+ */
74
+ /**
75
+ * Reset the WP Admin page styles for Gutenberg-like pages.
76
+ */
77
+ .comment-awaiting-moderation {
78
+ display: block;
79
+ font-size: 0.875em;
80
+ line-height: 1.5;
81
+ }
@@ -0,0 +1,81 @@
1
+ /**
2
+ * Colors
3
+ */
4
+ /**
5
+ * Breakpoints & Media Queries
6
+ */
7
+ /**
8
+ * SCSS Variables.
9
+ *
10
+ * Please use variables from this sheet to ensure consistency across the UI.
11
+ * Don't add to this sheet unless you're pretty sure the value will be reused in many places.
12
+ * For example, don't add rules to this sheet that affect block visuals. It's purely for UI.
13
+ */
14
+ /**
15
+ * Colors
16
+ */
17
+ /**
18
+ * Fonts & basic variables.
19
+ */
20
+ /**
21
+ * Grid System.
22
+ * https://make.wordpress.org/design/2019/10/31/proposal-a-consistent-spacing-system-for-wordpress/
23
+ */
24
+ /**
25
+ * Dimensions.
26
+ */
27
+ /**
28
+ * Shadows.
29
+ */
30
+ /**
31
+ * Editor widths.
32
+ */
33
+ /**
34
+ * Block & Editor UI.
35
+ */
36
+ /**
37
+ * Block paddings.
38
+ */
39
+ /**
40
+ * React Native specific.
41
+ * These variables do not appear to be used anywhere else.
42
+ */
43
+ /**
44
+ * Converts a hex value into the rgb equivalent.
45
+ *
46
+ * @param {string} hex - the hexadecimal value to convert
47
+ * @return {string} comma separated rgb values
48
+ */
49
+ /**
50
+ * Breakpoint mixins
51
+ */
52
+ /**
53
+ * Long content fade mixin
54
+ *
55
+ * Creates a fading overlay to signify that the content is longer
56
+ * than the space allows.
57
+ */
58
+ /**
59
+ * Focus styles.
60
+ */
61
+ /**
62
+ * Applies editor left position to the selector passed as argument
63
+ */
64
+ /**
65
+ * Styles that are reused verbatim in a few places
66
+ */
67
+ /**
68
+ * Allows users to opt-out of animations via OS-level preferences.
69
+ */
70
+ /**
71
+ * Reset default styles for JavaScript UI based pages.
72
+ * This is a WP-admin agnostic reset
73
+ */
74
+ /**
75
+ * Reset the WP Admin page styles for Gutenberg-like pages.
76
+ */
77
+ .comment-awaiting-moderation {
78
+ display: block;
79
+ font-size: 0.875em;
80
+ line-height: 1.5;
81
+ }
@@ -101,7 +101,7 @@
101
101
  .wp-block-cover.has-parallax {
102
102
  background-attachment: fixed;
103
103
  }
104
- @supports (-webkit-overflow-scrolling: touch) {
104
+ @supports (-webkit-touch-callout: inherit) {
105
105
  .wp-block-cover-image.has-parallax,
106
106
  .wp-block-cover.has-parallax {
107
107
  background-attachment: scroll;
@@ -101,7 +101,7 @@
101
101
  .wp-block-cover.has-parallax {
102
102
  background-attachment: fixed;
103
103
  }
104
- @supports (-webkit-overflow-scrolling: touch) {
104
+ @supports (-webkit-touch-callout: inherit) {
105
105
  .wp-block-cover-image.has-parallax,
106
106
  .wp-block-cover.has-parallax {
107
107
  background-attachment: scroll;
@@ -150,9 +150,11 @@
150
150
  }
151
151
  .wp-block-latest-posts__featured-image.alignleft {
152
152
  margin-right: 1em;
153
+ float: left;
153
154
  }
154
155
  .wp-block-latest-posts__featured-image.alignright {
155
156
  margin-left: 1em;
157
+ float: right;
156
158
  }
157
159
  .wp-block-latest-posts__featured-image.aligncenter {
158
160
  margin-bottom: 1em;
@@ -153,10 +153,14 @@
153
153
  .wp-block-latest-posts__featured-image.alignleft {
154
154
  /*rtl:ignore*/
155
155
  margin-right: 1em;
156
+ /*rtl:ignore*/
157
+ float: left;
156
158
  }
157
159
  .wp-block-latest-posts__featured-image.alignright {
158
160
  /*rtl:ignore*/
159
161
  margin-left: 1em;
162
+ /*rtl:ignore*/
163
+ float: right;
160
164
  }
161
165
  .wp-block-latest-posts__featured-image.aligncenter {
162
166
  margin-bottom: 1em;
@@ -417,7 +417,7 @@
417
417
  .wp-block-cover.has-parallax {
418
418
  background-attachment: fixed;
419
419
  }
420
- @supports (-webkit-overflow-scrolling: touch) {
420
+ @supports (-webkit-touch-callout: inherit) {
421
421
  .wp-block-cover-image.has-parallax,
422
422
  .wp-block-cover.has-parallax {
423
423
  background-attachment: scroll;
@@ -1435,9 +1435,11 @@ ol.wp-block-latest-comments {
1435
1435
  }
1436
1436
  .wp-block-latest-posts__featured-image.alignleft {
1437
1437
  margin-right: 1em;
1438
+ float: left;
1438
1439
  }
1439
1440
  .wp-block-latest-posts__featured-image.alignright {
1440
1441
  margin-left: 1em;
1442
+ float: right;
1441
1443
  }
1442
1444
  .wp-block-latest-posts__featured-image.aligncenter {
1443
1445
  margin-bottom: 1em;
@@ -422,7 +422,7 @@
422
422
  .wp-block-cover.has-parallax {
423
423
  background-attachment: fixed;
424
424
  }
425
- @supports (-webkit-overflow-scrolling: touch) {
425
+ @supports (-webkit-touch-callout: inherit) {
426
426
  .wp-block-cover-image.has-parallax,
427
427
  .wp-block-cover.has-parallax {
428
428
  background-attachment: scroll;
@@ -1448,10 +1448,14 @@ ol.wp-block-latest-comments {
1448
1448
  .wp-block-latest-posts__featured-image.alignleft {
1449
1449
  /*rtl:ignore*/
1450
1450
  margin-right: 1em;
1451
+ /*rtl:ignore*/
1452
+ float: left;
1451
1453
  }
1452
1454
  .wp-block-latest-posts__featured-image.alignright {
1453
1455
  /*rtl:ignore*/
1454
1456
  margin-left: 1em;
1457
+ /*rtl:ignore*/
1458
+ float: right;
1455
1459
  }
1456
1460
  .wp-block-latest-posts__featured-image.aligncenter {
1457
1461
  margin-bottom: 1em;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wordpress/block-library",
3
- "version": "7.3.3",
3
+ "version": "7.3.4",
4
4
  "description": "Block library for the WordPress editor.",
5
5
  "author": "The WordPress Contributors",
6
6
  "license": "GPL-2.0-or-later",
@@ -37,11 +37,11 @@
37
37
  "@wordpress/api-fetch": "^6.3.1",
38
38
  "@wordpress/autop": "^3.6.1",
39
39
  "@wordpress/blob": "^3.6.1",
40
- "@wordpress/block-editor": "^8.5.3",
40
+ "@wordpress/block-editor": "^8.5.4",
41
41
  "@wordpress/blocks": "^11.5.3",
42
- "@wordpress/components": "^19.8.2",
42
+ "@wordpress/components": "^19.8.3",
43
43
  "@wordpress/compose": "^5.4.1",
44
- "@wordpress/core-data": "^4.4.3",
44
+ "@wordpress/core-data": "^4.4.4",
45
45
  "@wordpress/data": "^6.6.1",
46
46
  "@wordpress/date": "^4.6.1",
47
47
  "@wordpress/deprecated": "^3.6.1",
@@ -54,9 +54,9 @@
54
54
  "@wordpress/keycodes": "^3.6.1",
55
55
  "@wordpress/notices": "^3.6.1",
56
56
  "@wordpress/primitives": "^3.4.1",
57
- "@wordpress/reusable-blocks": "^3.4.3",
58
- "@wordpress/rich-text": "^5.4.1",
59
- "@wordpress/server-side-render": "^3.4.3",
57
+ "@wordpress/reusable-blocks": "^3.4.4",
58
+ "@wordpress/rich-text": "^5.4.2",
59
+ "@wordpress/server-side-render": "^3.4.4",
60
60
  "@wordpress/url": "^3.7.1",
61
61
  "@wordpress/viewport": "^4.4.1",
62
62
  "classnames": "^2.3.1",
@@ -74,5 +74,5 @@
74
74
  "publishConfig": {
75
75
  "access": "public"
76
76
  },
77
- "gitHead": "37e930b93fbba88fa024a91eb527a90f855c97f3"
77
+ "gitHead": "1fdd4758150247d6b690051aed18fa27c15f3a32"
78
78
  }
@@ -18,17 +18,16 @@ function render_block_core_comment_author_name( $attributes, $content, $block )
18
18
  return '';
19
19
  }
20
20
 
21
- $comment = get_comment( $block->context['commentId'] );
21
+ $comment = get_comment( $block->context['commentId'] );
22
+ $commenter = wp_get_current_commenter();
23
+ $show_pending_links = isset( $commenter['comment_author'] ) && $commenter['comment_author'];
22
24
  if ( empty( $comment ) ) {
23
25
  return '';
24
26
  }
25
27
 
26
28
  $classes = '';
27
29
  if ( isset( $attributes['textAlign'] ) ) {
28
- $classes .= 'has-text-align-' . esc_attr( $attributes['textAlign'] );
29
- }
30
- if ( isset( $attributes['fontSize'] ) ) {
31
- $classes .= 'has-' . esc_attr( $attributes['fontSize'] ) . '-font-size';
30
+ $classes .= 'has-text-align-' . $attributes['textAlign'];
32
31
  }
33
32
 
34
33
  $wrapper_attributes = get_block_wrapper_attributes( array( 'class' => $classes ) );
@@ -38,6 +37,9 @@ function render_block_core_comment_author_name( $attributes, $content, $block )
38
37
  if ( ! empty( $attributes['isLink'] ) && ! empty( $attributes['linkTarget'] ) ) {
39
38
  $comment_author = sprintf( '<a rel="external nofollow ugc" href="%1s" target="%2s" >%3s</a>', esc_url( $link ), esc_attr( $attributes['linkTarget'] ), $comment_author );
40
39
  }
40
+ if ( '0' === $comment->comment_approved && ! $show_pending_links ) {
41
+ $comment_author = wp_kses( $comment_author, array() );
42
+ }
41
43
 
42
44
  return sprintf(
43
45
  '<div %1$s>%2$s</div>',
@@ -18,16 +18,37 @@ function render_block_core_comment_content( $attributes, $content, $block ) {
18
18
  return '';
19
19
  }
20
20
 
21
- $comment = get_comment( $block->context['commentId'] );
21
+ $comment = get_comment( $block->context['commentId'] );
22
+ $commenter = wp_get_current_commenter();
23
+ $show_pending_links = isset( $commenter['comment_author'] ) && $commenter['comment_author'];
22
24
  if ( empty( $comment ) ) {
23
25
  return '';
24
26
  }
25
27
 
26
- $comment_text = get_comment_text( $comment );
28
+ $args = array();
29
+ $comment_text = get_comment_text( $comment, $args );
27
30
  if ( ! $comment_text ) {
28
31
  return '';
29
32
  }
30
33
 
34
+ /** This filter is documented in wp-includes/comment-template.php */
35
+ $comment_text = apply_filters( 'comment_text', $comment_text, $comment, $args );
36
+
37
+ $moderation_note = '';
38
+ if ( '0' === $comment->comment_approved ) {
39
+ $commenter = wp_get_current_commenter();
40
+
41
+ if ( $commenter['comment_author_email'] ) {
42
+ $moderation_note = __( 'Your comment is awaiting moderation.' );
43
+ } else {
44
+ $moderation_note = __( 'Your comment is awaiting moderation. This is a preview; your comment will be visible after it has been approved.' );
45
+ }
46
+ $moderation_note = '<p><em class="comment-awaiting-moderation">' . $moderation_note . '</em></p>';
47
+ if ( ! $show_pending_links ) {
48
+ $comment_text = wp_kses( $comment_text, array() );
49
+ }
50
+ }
51
+
31
52
  $classes = '';
32
53
  if ( isset( $attributes['textAlign'] ) ) {
33
54
  $classes .= 'has-text-align-' . $attributes['textAlign'];
@@ -36,8 +57,9 @@ function render_block_core_comment_content( $attributes, $content, $block ) {
36
57
  $wrapper_attributes = get_block_wrapper_attributes( array( 'class' => $classes ) );
37
58
 
38
59
  return sprintf(
39
- '<div %1$s>%2$s</div>',
60
+ '<div %1$s>%2$s%3$s</div>',
40
61
  $wrapper_attributes,
62
+ $moderation_note,
41
63
  $comment_text
42
64
  );
43
65
  }
@@ -0,0 +1,5 @@
1
+ .comment-awaiting-moderation {
2
+ display: block;
3
+ font-size: 0.875em;
4
+ line-height: 1.5;
5
+ }
@@ -140,7 +140,15 @@ export default function Edit( {
140
140
  ? __( 'One response to ' )
141
141
  : __( 'One response' );
142
142
 
143
+ const singlePlaceholderNoCount = showPostTitle
144
+ ? __( 'Response to ' )
145
+ : __( 'Response' );
146
+
143
147
  const multiplePlaceholder = showPostTitle
148
+ ? __( 'responses to ' )
149
+ : __( 'responses' );
150
+
151
+ const multiplePlaceholderNoCount = showPostTitle
144
152
  ? __( 'Responses to ' )
145
153
  : __( 'Responses' );
146
154
 
@@ -154,8 +162,16 @@ export default function Edit( {
154
162
  <PlainText
155
163
  __experimentalVersion={ 2 }
156
164
  tagName="span"
157
- aria-label={ singlePlaceholder }
158
- placeholder={ singlePlaceholder }
165
+ aria-label={
166
+ showCommentsCount
167
+ ? singlePlaceholder
168
+ : singlePlaceholderNoCount
169
+ }
170
+ placeholder={
171
+ showCommentsCount
172
+ ? singlePlaceholder
173
+ : singlePlaceholderNoCount
174
+ }
159
175
  value={ singleCommentLabel }
160
176
  onChange={ ( newLabel ) =>
161
177
  setAttributes( {
@@ -174,12 +190,12 @@ export default function Edit( {
174
190
  aria-label={
175
191
  showCommentsCount
176
192
  ? ` ${ multiplePlaceholder }`
177
- : multiplePlaceholder
193
+ : multiplePlaceholderNoCount
178
194
  }
179
195
  placeholder={
180
196
  showCommentsCount
181
197
  ? ` ${ multiplePlaceholder }`
182
- : multiplePlaceholder
198
+ : multiplePlaceholderNoCount
183
199
  }
184
200
  value={ multipleCommentsLabel }
185
201
  onChange={ ( newLabel ) =>
@@ -29,11 +29,18 @@ function render_block_core_comments_title( $attributes ) {
29
29
  return;
30
30
  }
31
31
 
32
- $single_default_comment_label = $show_post_title ? __( 'One response to' ) : __( 'One response' );
33
- $single_comment_label = ! empty( $attributes['singleCommentLabel'] ) ? $attributes['singleCommentLabel'] : $single_default_comment_label;
32
+ $single_default_comment_label = $show_post_title ? __( 'Response to' ) : __( 'Response' );
33
+ if ( $show_comments_count ) {
34
+ $single_default_comment_label = $show_post_title ? __( 'One response to' ) : __( 'One response' );
35
+ }
36
+ $single_comment_label = ! empty( $attributes['singleCommentLabel'] ) ? $attributes['singleCommentLabel'] : $single_default_comment_label;
34
37
 
35
38
  $multiple_default_comment_label = $show_post_title ? __( 'Responses to' ) : __( 'Responses' );
36
- $multiple_comment_label = ! empty( $attributes['multipleCommentsLabel'] ) ? $attributes['multipleCommentsLabel'] : $multiple_default_comment_label;
39
+ if ( $show_comments_count ) {
40
+ $multiple_default_comment_label = $show_post_title ? __( 'responses to' ) : __( 'responses' );
41
+ }
42
+
43
+ $multiple_comment_label = ! empty( $attributes['multipleCommentsLabel'] ) ? $attributes['multipleCommentsLabel'] : $multiple_default_comment_label;
37
44
 
38
45
  $comments_title = '%1$s %2$s %3$s';
39
46
 
@@ -53,9 +60,9 @@ function render_block_core_comments_title( $attributes ) {
53
60
  );
54
61
  }
55
62
 
56
- /**
57
- * Registers the `core/comments-title` block on the server.
58
- */
63
+ /**
64
+ * Registers the `core/comments-title` block on the server.
65
+ */
59
66
  function register_block_core_comments_title() {
60
67
  register_block_type_from_metadata(
61
68
  __DIR__ . '/comments-title',
@@ -65,4 +72,4 @@ function register_block_core_comments_title() {
65
72
  );
66
73
  }
67
74
 
68
- add_action( 'init', 'register_block_core_comments_title' );
75
+ add_action( 'init', 'register_block_core_comments_title' );
@@ -40,7 +40,7 @@ function render_block_core_cover( $attributes, $content ) {
40
40
  $object_position = '';
41
41
  if ( isset( $attributes['focalPoint'] ) ) {
42
42
  $object_position = round( $attributes['focalPoint']['x'] * 100 ) . '%' . ' ' .
43
- round( $attributes['focalPoint']['x'] * 100 ) . '%';
43
+ round( $attributes['focalPoint']['y'] * 100 ) . '%';
44
44
  }
45
45
 
46
46
  $image_template = '<img
@@ -18,7 +18,7 @@
18
18
  // Mobile Safari does not support fixed background attachment properly.
19
19
  // See also https://stackoverflow.com/questions/24154666/background-size-cover-not-working-on-ios
20
20
  // Chrome on Android does not appear to support the attachment at all: https://issuetracker.google.com/issues/36908439
21
- @supports (-webkit-overflow-scrolling: touch) {
21
+ @supports (-webkit-touch-callout: inherit) {
22
22
  background-attachment: scroll;
23
23
  }
24
24
 
@@ -63,10 +63,14 @@
63
63
  &.alignleft {
64
64
  /*rtl:ignore*/
65
65
  margin-right: 1em;
66
+ /*rtl:ignore*/
67
+ float: left;
66
68
  }
67
69
  &.alignright {
68
70
  /*rtl:ignore*/
69
71
  margin-left: 1em;
72
+ /*rtl:ignore*/
73
+ float: right;
70
74
  }
71
75
  &.aligncenter {
72
76
  margin-bottom: 1em;
@@ -44,12 +44,12 @@ export default function NavigationInnerBlocks( {
44
44
  } ) {
45
45
  const {
46
46
  isImmediateParentOfSelectedBlock,
47
- selectedBlockHasDescendants,
47
+ selectedBlockHasChildren,
48
48
  isSelected,
49
49
  } = useSelect(
50
50
  ( select ) => {
51
51
  const {
52
- getClientIdsOfDescendants,
52
+ getBlockCount,
53
53
  hasSelectedInnerBlock,
54
54
  getSelectedBlockClientId,
55
55
  } = select( blockEditorStore );
@@ -60,9 +60,7 @@ export default function NavigationInnerBlocks( {
60
60
  clientId,
61
61
  false
62
62
  ),
63
- selectedBlockHasDescendants: !! getClientIdsOfDescendants( [
64
- selectedBlockId,
65
- ] )?.length,
63
+ selectedBlockHasChildren: !! getBlockCount( selectedBlockId ),
66
64
 
67
65
  // This prop is already available but computing it here ensures it's
68
66
  // fresh compared to isImmediateParentOfSelectedBlock.
@@ -93,7 +91,7 @@ export default function NavigationInnerBlocks( {
93
91
  // appender.
94
92
  const parentOrChildHasSelection =
95
93
  isSelected ||
96
- ( isImmediateParentOfSelectedBlock && ! selectedBlockHasDescendants );
94
+ ( isImmediateParentOfSelectedBlock && ! selectedBlockHasChildren );
97
95
 
98
96
  const placeholder = useMemo( () => <PlaceholderPreview />, [] );
99
97
 
@@ -127,7 +125,7 @@ export default function NavigationInnerBlocks( {
127
125
  renderAppender:
128
126
  isSelected ||
129
127
  ( isImmediateParentOfSelectedBlock &&
130
- ! selectedBlockHasDescendants ) ||
128
+ ! selectedBlockHasChildren ) ||
131
129
  // Show the appender while dragging to allow inserting element between item and the appender.
132
130
  parentOrChildHasSelection
133
131
  ? InnerBlocks.ButtonBlockAppender