// Set the CSS variable to the column value, and the `gap` property to the combined gap value.
$gallery_styles = array(
array(
'selector' => ".wp-block-gallery.{$unique_gallery_classname}",
'declarations' => array(
'--wp--style--unstable-gallery-gap' => $gap_column,
'gap' => $gap_value,
),
),
);
wp_style_engine_get_stylesheet_from_css_rules(
$gallery_styles,
array(
'context' => 'block-supports',
)
);
return (string) $processed_content;
}
/**
* Registers the `core/gallery` block on server.
*/
function register_block_core_gallery() {