please remove forminator classes or allow override
-
For people using gutenberg and other default global styles, there is no simple way to make forminator forms inherit the button styles. for example, if i turn off forminator styling and use basic option or none, the button shows as plain html button. it will not inherit the global button styles for the site.
your none option removes the styling but does not remove your classes or allow them to be replaced at the form/plugin level as other plugins do. example: https://www.billerickson.net/wpforms-submit-button-match-gutenberg-button-style/
please change your plugin to not output css classes for forminator if people set to none and want to inherit all their global styles. other plugins allow users to simply replace the class on an element with the global class name at the plugin level:
“wp-block-button__link wp-element-button”
thanks! i love this plugin but this aspect makes it very outdated and not up to FSE block theming standards for 2026 and beyond.
if anyone else finds this thread, here’s a functions.php solution gemini made that strips the forminator class and replaces with the default global styles:
/**
* Replace Forminator submit button classes with Gutenberg global style classes.
*/
add_filter( 'forminator_render_button_markup', 'inherit_gutenberg_button_classes_in_forminator', 10, 2 );
function inherit_gutenberg_button_classes_in_forminator( $html, $button ) {
// 1. Ensure we only target the submit button
if ( strpos( $html, 'forminator-button-submit' ) !== false ) {
// 2. Replace Forminator's submit button element wrapper with Gutenberg's button block wrapper
$html = str_replace( 'forminator-field', 'forminator-field wp-block-button', $html );
// 3. Replace the native Forminator button classes with Gutenberg block button classes
$html = str_replace(
'class="forminator-button forminator-button-submit"',
'class="wp-block-button__link wp-element-button forminator-button-submit"',
$html
);
}
return $html;
}
You must be logged in to reply to this topic.

