@@ -41,6 +41,7 @@ import { getAllowedFormats } from './utils';
4141import { Content , valueToHTMLString } from './content' ;
4242import { withDeprecations } from './with-deprecations' ;
4343import BlockContext from '../block-context' ;
44+ import { PrivateBlockContext } from '../block-list/private-block-context' ;
4445
4546export const keyboardShortcutContext = createContext ( ) ;
4647keyboardShortcutContext . displayName = 'keyboardShortcutContext' ;
@@ -124,9 +125,10 @@ export function RichTextWrapper(
124125 const instanceId = useInstanceId ( RichTextWrapper ) ;
125126 const anchorRef = useRef ( ) ;
126127 const context = useBlockEditContext ( ) ;
127- const { clientId, isSelected : isBlockSelected , name : blockName } = context ;
128+ const { clientId, isSelected : isBlockSelected } = context ;
128129 const blockBindings = context [ blockBindingsKey ] ;
129130 const blockContext = useContext ( BlockContext ) ;
131+ const { bindableAttributes } = useContext ( PrivateBlockContext ) ;
130132 const registry = useRegistry ( ) ;
131133 const selector = ( select ) => {
132134 // Avoid subscribing to the block editor store if the block is not
@@ -171,15 +173,7 @@ export function RichTextWrapper(
171173
172174 const { disableBoundBlock, bindingsPlaceholder, bindingsLabel } = useSelect (
173175 ( select ) => {
174- const { __experimentalBlockBindingsSupportedAttributes } =
175- select ( blockEditorStore ) . getSettings ( ) ;
176-
177- if (
178- ! blockBindings ?. [ identifier ] ||
179- ! (
180- blockName in __experimentalBlockBindingsSupportedAttributes
181- )
182- ) {
176+ if ( ! blockBindings ?. [ identifier ] || ! bindableAttributes ) {
183177 return { } ;
184178 }
185179
@@ -252,7 +246,7 @@ export function RichTextWrapper(
252246 [
253247 blockBindings ,
254248 identifier ,
255- blockName ,
249+ bindableAttributes ,
256250 adjustedValue ,
257251 clientId ,
258252 blockContext ,
0 commit comments