(()=>{var e={942:(e,t)=>{var n;!function(){"use strict";var o={}.hasOwnProperty;function r(){for(var e="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(e=s(e,l(n)))}return e}function l(e){if("string"==typeof e||"number"==typeof e)return e;if("object"!=typeof e)return"";if(Array.isArray(e))return r.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var t="";for(var n in e)o.call(e,n)&&e[n]&&(t=s(t,n));return t}function s(e,t){return t?e?e+" "+t:e+t:e}e.exports?(r.default=r,e.exports=r):void 0===(n=function(){return r}.apply(t,[]))||(e.exports=n)}()}},t={};function n(o){var r=t[o];if(void 0!==r)return r.exports;var l=t[o]={exports:{}};return e[o](l,l.exports,n),l.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var o in t)n.o(t,o)&&!n.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=window.wp.blocks,t=window.wp.element;var o=n(942),r=n.n(o);const l=window.wp.i18n,s=window.wp.blockEditor,i=(window.lodash,window.moment,window.wp.data);window.wp.date;const a=window.wp.components;function c(e){const{attributes:n,setAttributes:o,isSelected:r,clientId:i,name:c}=e,d="mailster-workflow/condition-yes"===c;return(0,t.createElement)(s.InspectorControls,null,(0,t.createElement)(a.Panel,null,(0,t.createElement)(a.PanelBody,null,(0,t.createElement)(a.PanelRow,null,d?(0,l.__)("These steps run if the condition is fullfilled.","mailster"):(0,l.__)("These steps run if the condition is not fullfilled.","mailster")))))}const d=(0,t.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,t.createElement)("g",{fill:"none"},(0,t.createElement)("path",{d:"M24 24H0V0h24v24z"}),(0,t.createElement)("path",{stroke:"#c3232d",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",d:"M17.1 5H19c.5 0 1 .5 1 1.1v7.4c0 .6-.5 1.1-1.1 1.1H17c-.6 0-1.1-.5-1.1-1.1V6.1c.1-.6.6-1.1 1.2-1.1z"}),(0,t.createElement)("path",{stroke:"#c3232d",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",d:"M16 13.4l-3.6 4.8c-.7.9-2 .9-2.7 0h0c-.3-.3-.4-.7-.4-1.1v-3.3H6.1c-.6 0-1.2-.3-1.5-.8l-.3-.5c-.3-.4-.4-1-.2-1.5l1.4-4.7c.2-.8.9-1.3 1.7-1.3h6.3c.5 0 1 .2 1.3.6L16 6.9"}))),u=JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"mailster-workflow/condition-no","title":"Condition not fulfilled","category":"mailster-automation-fields","parent":["mailster-workflow/conditions-no"],"example":{},"supports":{"html":false,"inserter":false,"className":false,"customClassName":false,"reusable":false,"lock":false},"attributes":{"lock":{"type":"object","default":{"remove":true,"move":true}}},"usesContext":["mailster-workflow/weight"],"textdomain":"mailster","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css"}'),{name:m,...p}=u;(0,e.registerBlockType)(m,{...p,icon:d,edit:function(e){const{attributes:n,setAttributes:o,isSelected:a,clientId:d,context:u,name:m}=e,p=["mailster-step-condition","canvas-handle"],f="mailster-workflow/condition-yes"===m;(e=>function(e,t,n=!0){const o=function(e,t=null,n=!0){const{getBlocks:o,getBlockRootClientId:r}=(0,i.select)("core/block-editor"),l=o(t);let s=[];return function t(o){o.forEach((o=>{o.name&&new RegExp(e,"g").test(o.name)&&(o.rootClientId=r(o.clientId),s.push(o)),n&&o.innerBlocks.length>0&&t(o.innerBlocks)}))}(l),s}("mailster-workflow/stop",t,n);return!!o.length&&o[0]}(0,e,!1))(d)&&p.push("mailster-has-stop"),p.push(f?"yes":"no");const w=f?(0,l.__)("Condition is fullfilled","mailster"):(0,l.__)("Condition is not fullfilled","mailster"),h=(0,s.useBlockProps)({className:r()({},p)}),k=(0,s.useInnerBlocksProps)({className:"canvas-handle"},{allowedBlocks:["mailster-workflow/stop"],templateLock:!1});return(0,t.createElement)(t.Fragment,null,(0,t.createElement)("div",h,(0,t.createElement)("div",{className:"line line-in canvas-handle"},(0,t.createElement)("span",{className:"condition-label",title:w})),(0,t.createElement)("div",k),(0,t.createElement)("div",{className:"line line-out canvas-handle"})),(0,t.createElement)(c,e))},save:function(e){return(0,t.createElement)(s.InnerBlocks.Content,s.useBlockProps.save())}})})()})();