@@ -112,12 +112,8 @@ protected function filter_edit_form_params(
112112 $ params ['columns ' ]['selector ' ]['args ' ]['attributes ' ]['data-default ' ] = $ this ->get_default_class ( $ post ->ID );
113113 $ params ['columns ' ]['selector ' ]['default ' ] = $ params ['columns ' ]['selector ' ]['args ' ]['attributes ' ]['data-default ' ];
114114
115- $ params ['name_prefix ' ] = $ assets ->get_name_prefix ();
116- $ params ['id_prefix ' ] = $ assets ->get_id_prefix ();
117- if ( ! $ this ->app ->utility ->can_use_block_editor () ) {
118- unset( $ params ['columns ' ]['is_valid_button_block_editor ' ] );
119- }
120-
115+ $ params ['name_prefix ' ] = $ assets ->get_name_prefix ();
116+ $ params ['id_prefix ' ] = $ assets ->get_id_prefix ();
121117 $ params ['target_selector ' ] = '.marker-animation-option ' ;
122118 $ params ['marker_target_selector ' ] = '.marker-setting-preview .marker-animation ' ;
123119
@@ -293,16 +289,11 @@ private function others_callback(
293289 /** @noinspection PhpUnusedParameterInspection */
294290 $ value , $ data , $ post
295291 ) {
296- $ details = [
297- 'is valid block editor button ' => empty ( $ data ['is_valid_button_block_editor ' ] ) ? $ this ->translate ( 'No ' ) : $ this ->translate ( 'Yes ' ),
298- 'selector ' => $ this ->get_default_class ( $ post ->ID ) . ( empty ( $ data ['selector ' ] ) ? '' : ', ' . $ data ['selector ' ] ),
299- ];
300- if ( ! $ this ->app ->utility ->can_use_block_editor () ) {
301- unset( $ details ['is valid block editor button ' ] );
302- }
303-
304292 return $ this ->get_view ( 'admin/custom_post/setting/others ' , [
305- 'details ' => $ details ,
293+ 'details ' => [
294+ 'is valid block editor button ' => empty ( $ data ['is_valid_button_block_editor ' ] ) ? $ this ->translate ( 'No ' ) : $ this ->translate ( 'Yes ' ),
295+ 'selector ' => $ this ->get_default_class ( $ post ->ID ) . ( empty ( $ data ['selector ' ] ) ? '' : ', ' . $ data ['selector ' ] ),
296+ ],
306297 ] );
307298 }
308299
0 commit comments