@wordpress/block-editor 11.3.8 → 11.3.9

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.
@@ -164,6 +164,7 @@
164
164
  .block-editor-block-inspector .components-panel__body {
165
165
  border: none;
166
166
  border-top: 1px solid #e0e0e0;
167
+ margin-top: -1px;
167
168
  }
168
169
  .block-editor-block-inspector .block-editor-block-card {
169
170
  padding: 16px;
@@ -164,6 +164,7 @@
164
164
  .block-editor-block-inspector .components-panel__body {
165
165
  border: none;
166
166
  border-top: 1px solid #e0e0e0;
167
+ margin-top: -1px;
167
168
  }
168
169
  .block-editor-block-inspector .block-editor-block-card {
169
170
  padding: 16px;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wordpress/block-editor",
3
- "version": "11.3.8",
3
+ "version": "11.3.9",
4
4
  "description": "Generic block editor.",
5
5
  "author": "The WordPress Contributors",
6
6
  "license": "GPL-2.0-or-later",
@@ -83,5 +83,5 @@
83
83
  "publishConfig": {
84
84
  "access": "public"
85
85
  },
86
- "gitHead": "446428841b54f47e5373d6e9723ef7ec24cf11b3"
86
+ "gitHead": "f22a3cbf0cd8f48c7ef800a09b69212a893b99b8"
87
87
  }
@@ -27,6 +27,9 @@
27
27
  .components-panel__body {
28
28
  border: none;
29
29
  border-top: $border-width solid $gray-200;
30
+
31
+ // Ensures this PanelBody is treated like the ToolsPanel, removing double borders.
32
+ margin-top: -$border-width;
30
33
  }
31
34
 
32
35
  .block-editor-block-card {
@@ -23,6 +23,7 @@ export function BlockInvalidWarning( {
23
23
  block,
24
24
  } ) {
25
25
  const hasHTMLBlock = !! getBlockType( 'core/html' );
26
+ const hasClassicBlock = !! getBlockType( 'core/freeform' );
26
27
  const [ compare, setCompare ] = useState( false );
27
28
 
28
29
  const onCompare = useCallback( () => setCompare( true ), [] );
@@ -41,12 +42,18 @@ export function BlockInvalidWarning( {
41
42
  title: __( 'Convert to HTML' ),
42
43
  onClick: convertToHTML,
43
44
  },
44
- {
45
+ hasClassicBlock && {
45
46
  title: __( 'Convert to Classic Block' ),
46
47
  onClick: convertToClassic,
47
48
  },
48
49
  ].filter( Boolean ),
49
- [ onCompare, convertToHTML, convertToClassic ]
50
+ [
51
+ onCompare,
52
+ hasHTMLBlock,
53
+ convertToHTML,
54
+ hasClassicBlock,
55
+ convertToClassic,
56
+ ]
50
57
  );
51
58
 
52
59
  return (
@@ -2806,12 +2806,12 @@ export function __unstableHasActiveBlockOverlayActive( state, clientId ) {
2806
2806
  }
2807
2807
 
2808
2808
  export function __unstableIsWithinBlockOverlay( state, clientId ) {
2809
- let parent = state.blocks.parents[ clientId ];
2809
+ let parent = state.blocks.parents.get( clientId );
2810
2810
  while ( !! parent ) {
2811
2811
  if ( __unstableHasActiveBlockOverlayActive( state, parent ) ) {
2812
2812
  return true;
2813
2813
  }
2814
- parent = state.blocks.parents[ parent ];
2814
+ parent = state.blocks.parents.get( parent );
2815
2815
  }
2816
2816
  return false;
2817
2817
  }