: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
'wpforms_frontend_container_class',
static function ( $classes ) {
$classes[] = 'wpforms-gutenberg-form-selector';
'wpforms_frontend_output',
echo '<fieldset disabled>';
'wpforms_frontend_output',
* Output CSS variables for the particular form.
* @param array $attr Attributes passed by WPForms Gutenberg block.
private function output_css_vars( $attr ) {
if ( empty( $this->css_vars_obj ) || ! method_exists( $this->css_vars_obj, 'get_vars' ) ) {
$this->css_vars_obj->output_root();
if ( $this->render_engine === 'classic' || $this->disable_css_setting !== 1 ) {
$css_vars = $this->css_vars_obj->get_customized_css_vars( $attr );
if ( empty( $css_vars ) ) {
$style_id = "#wpforms-css-vars-{$attr['formId']}-block-{$attr['clientId']}";
* Filter the CSS selector for output CSS variables for styling the GB block form.
* @param string $selector The CSS selector for output CSS variables for styling the GB block form.
* @param array $attr Attributes passed by WPForms Gutenberg block.
* @param array $css_vars CSS variables data.
$vars_selector = apply_filters(
'wpforms_integrations_gutenberg_form_selector_output_css_vars_selector',
"#wpforms-{$attr['formId']}.wpforms-block-{$attr['clientId']}",
$this->css_vars_obj->output_selector_vars( $vars_selector, $css_vars, $style_id, $this->current_form_id );
* Output custom CSS styles.
* @param array $attr Attributes passed by WPForms Gutenberg block.
private function output_custom_css( $attr ) {
if ( wpforms_get_render_engine() === 'classic' ) {
$custom_css = trim( $attr['customCss'] ?? '' );
if ( empty( $custom_css ) ) {
$style_id = "#wpforms-custom-css-{$attr['formId']}-block-{$attr['clientId']}";
sanitize_key( $style_id ),