(()=>{"use strict";const t="switch_on_change",{getSupport:e}=JetFBActions,n=window.React,{__:o}=wp.i18n,{ToolbarButton:i}=wp.components,{SVG:a,Path:r}=wp.primitives,{useBlockAttributes:c}=JetFBHooks,l=function(){const[e,l]=c();return(0,n.createElement)(i,{icon:(0,n.createElement)(a,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,n.createElement)(r,{d:"M6.6 6L5.4 7l4.5 5-4.5 5 1.1 1 5.5-6-5.4-6zm6 0l-1.1 1 4.5 5-4.5 5 1.1 1 5.5-6-5.5-6z"})),title:e[t]?o("Click on the button to disable the \nautomatic transition to the next page when the values are changed","jet-form-builder"):o("Click on the button to enable automatic \ntransition to the next page when the values are changed","jet-form-builder"),onClick:()=>l({[t]:!e[t]}),isActive:e[t]})},{BlockControls:s}=wp.blockEditor,{addFilter:u}=wp.hooks;u("blocks.registerBlockType","jet-form-builder/switch-page-on-change-support",(function(n,o){return e(n,"jetFBSwitchPageOnChange")?(n.attributes={...n.attributes,[t]:{type:"boolean",default:!1}},n):n})),window.JetFBComponents={...window.JetFBComponents,SwitchPageOnChangeControls:function(){return(0,n.createElement)(s,{group:"other"},(0,n.createElement)(l,null))},SwitchPageOnChangeButton:l}})();