@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.
- package/build/components/block-list/block-invalid-warning.js +3 -2
- package/build/components/block-list/block-invalid-warning.js.map +1 -1
- package/build/store/selectors.js +2 -2
- package/build/store/selectors.js.map +1 -1
- package/build-module/components/block-list/block-invalid-warning.js +3 -2
- package/build-module/components/block-list/block-invalid-warning.js.map +1 -1
- package/build-module/store/selectors.js +2 -2
- package/build-module/store/selectors.js.map +1 -1
- package/build-style/style-rtl.css +1 -0
- package/build-style/style.css +1 -0
- package/package.json +2 -2
- package/src/components/block-inspector/style.scss +3 -0
- package/src/components/block-list/block-invalid-warning.js +9 -2
- package/src/store/selectors.js +2 -2
package/build-style/style.css
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wordpress/block-editor",
|
|
3
|
-
"version": "11.3.
|
|
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": "
|
|
86
|
+
"gitHead": "f22a3cbf0cd8f48c7ef800a09b69212a893b99b8"
|
|
87
87
|
}
|
|
@@ -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
|
-
[
|
|
50
|
+
[
|
|
51
|
+
onCompare,
|
|
52
|
+
hasHTMLBlock,
|
|
53
|
+
convertToHTML,
|
|
54
|
+
hasClassicBlock,
|
|
55
|
+
convertToClassic,
|
|
56
|
+
]
|
|
50
57
|
);
|
|
51
58
|
|
|
52
59
|
return (
|
package/src/store/selectors.js
CHANGED
|
@@ -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
|
|
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
|
|
2814
|
+
parent = state.blocks.parents.get( parent );
|
|
2815
2815
|
}
|
|
2816
2816
|
return false;
|
|
2817
2817
|
}
|