(()=>{var e={6942(e,t){var n;!function(){"use strict";var o={}.hasOwnProperty;function s(){for(var e="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(e=i(e,r(n)))}return e}function r(e){if("string"==typeof e||"number"==typeof e)return e;if("object"!=typeof e)return"";if(Array.isArray(e))return s.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=i(t,n));return t}function i(e,t){return t?e?e+" "+t:e+t:e}e.exports?(s.default=s,e.exports=s):void 0===(n=function(){return s}.apply(t,[]))||(e.exports=n)}()}},t={};function n(o){var s=t[o];if(void 0!==s)return s.exports;var r=t[o]={exports:{}};return e[o](r,r.exports,n),r.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;var t=n(6942),o=n.n(t);const s=window.wp.i18n,r=window.wp.blockEditor,i=(window.lodash,window.moment,window.wp.element,window.wp.data),l=window.ReactJSXRuntime;const a=window.wp.components;function c(e){const{attributes:t,setAttributes:n,isSelected:o,clientId:i,name:c}=e,d="mailster-workflow/condition-yes"===c;return(0,l.jsx)(r.InspectorControls,{children:(0,l.jsx)(a.Panel,{children:(0,l.jsx)(a.PanelBody,{children:(0,l.jsx)(a.PanelRow,{children:d?(0,s.__)("These steps run if the condition is fullfilled.","mailster"):(0,s.__)("These steps run if the condition is not fullfilled.","mailster")})})})})}const d=(0,l.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,l.jsxs)("g",{fill:"none",children:[(0,l.jsx)("path",{d:"M24 24H0V0h24v24z"}),(0,l.jsx)("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,l.jsx)("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-workflow-steps","parent":["mailster-workflow/conditions"],"example":{},"supports":{"html":false,"inserter":false,"className":false,"customClassName":false,"reusable":false,"renaming":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:p,...f}=u;(0,e.registerBlockType)(p,{...f,icon:d,edit:function(e){const{attributes:t,setAttributes:n,isSelected:a,clientId:d,context:u,name:p}=e,f=["mailster-step-condition","canvas-handle"],w="mailster-workflow/condition-yes"===p;(e=>function(e,t,n=!0){const o=function(e,t=null,n=!0){const{getBlocks:o,getBlockRootClientId:s}=(0,i.select)("core/block-editor"),r=o(t),l=[];return function t(o){o.forEach(o=>{o.name&&new RegExp(e,"g").test(o.name)&&(o.rootClientId=s(o.clientId),l.push(o)),n&&o.innerBlocks.length>0&&t(o.innerBlocks)})}(r||[]),l}("mailster-workflow/stop",t,n);return!!o.length&&o[0]}(0,e,!1))(d)&&f.push("mailster-has-stop"),f.push(w?"yes":"no");const m=w?(0,s.__)("Condition is fullfilled","mailster"):(0,s.__)("Condition is not fullfilled","mailster"),h=(0,r.useBlockProps)({className:o()({},f)}),k=(0,r.useInnerBlocksProps)({className:"canvas-handle"},{allowedBlocks:["mailster-workflow/stop"],templateLock:!1});return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)("div",{...h,children:[(0,l.jsx)("div",{className:"line line-in canvas-handle",children:(0,l.jsx)("span",{className:"condition-label",title:m})}),(0,l.jsx)("div",{...k}),(0,l.jsx)("div",{className:"line line-out canvas-handle"})]}),(0,l.jsx)(c,{...e})]})},save:function(e){return(0,l.jsx)(r.InnerBlocks.Content,{...r.useBlockProps.save()})}})})()})();