• Resolved frzsombor

    (@frzsombor)


    As the title says, please add support for Block Editor API 3 in your “fluentfom/guten-block” block. Currently, without this, when your block is registered, the Block Editor is not loading in “iframe mode” by default, and in my stack, only this plugin is registering a block that does not support v3 yet.

    It is as simple as adding apiVersion: 3 to “fluentform/assets/js/fluent_gutenblock.js” in the block definition object, however, I’ve tested it and it caused some minor layout issues. Also, make sure to disable the submit buttons on each form in the Block Editor.

    Related: https://github.com/fluentform/fluentform/issues/653

    Notes: I’ve reported a similar issue at “WP Social Ninja”. This plugin is even more popular, just like how the Block Editor is getting more traction. Please update both to follow the latest standards.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Amimul Ihsan

    (@amimulihsanmahdi)

    Hello @frzsombor,

    Thanks for sharing the details. I have discussed this with our developers and I would like to inform you that this is planned for the future update and our team will add the compatibility in the upcoming updates.

    Thank you

    Plugin Support Amimul Ihsan

    (@amimulihsanmahdi)

    Hi there,

    Our development team has reviewed this, and the current implementation is intentional. We are aware that apiVersion3 is not yet supported for the Fluent Forms block.

    The primary reason is that apiVersion3 enforces loading the block within an iframe in the editor. This iframe environment unfortunately prevents the block from loading all the necessary CSS that Fluent Forms relies on for styling.

    As you rightly observed, this results in layout and styling issues. To ensure the form preview displays correctly and functionally within the editor, we’ve had to stick with the current API version for now.

    While it’s not a bug, we understand this affects workflows that depend on the iframe mode, and we appreciate you bringing it to our attention. We are tracking this for future updates as the Block Editor and our integration evolve.

    Thank you

    Thread Starter frzsombor

    (@frzsombor)

    Hi @amimulihsanmahdi,

    Thanks for the update!

    I honestly think that this can be solved with the current Block Editor API without waiting for any updates of it. There are so many other plugins that provide custom blocks and they are able to load all the related and necessary custom CSS properly – the API is complete.

    Also, I do think the current implementation has bugs, because when someone switches the “View” in Block Editor from “Desktop” to “Tablet” or “Mobile”, the blocks are forced to load in iframe and Fluent Forms blocks will break (because they will be forced to behave as v3 blocks).

    I checked the source code and noticed that in app/Hooks/actions.php you’re using the enqueue_block_editor_assets hook, which is why the styles aren’t loading in the iframe. You might want to look into enqueue_block_assets and the difference between the two. I replaced the former with the latter, and now it works with API v3, the styles load correctly inside the iframe. A few other small tweaks might still be needed, such as adding the wp-block class to flueform-guten-wrapper, but full compatibility looks achievable.

    Hope these help!

Viewing 3 replies - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.