(()=>{"use strict";var e,r={830:()=>{const e=window.wp.blocks,r=window.wp.element,o=e=>({width:24,height:24,fill:"none",className:e&&"spectra-block-icon--colored"}),t={fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"},n=(e=!0)=>(0,r.createElement)("svg",{viewBox:"0 0 24 25",...o(e)},(0,r.createElement)("path",{d:"M6.8 6.14553L17.1999 6.19021M6.8 18.1455L17.1999 18.1902M5.4 1.96811H18.6C19.3732 1.96811 20 2.59491 20 3.36811V8.96811C20 9.74131 19.3732 10.3681 18.6 10.3681H5.4C4.6268 10.3681 4 9.74131 4 8.96811V3.36811C4 2.59491 4.6268 1.96811 5.4 1.96811ZM5.4 13.9681H18.6C19.3732 13.9681 20 14.5949 20 15.3681V20.9681C20 21.7413 19.3732 22.3681 18.6 22.3681H5.4C4.6268 22.3681 4 21.7413 4 20.9681V15.3681C4 14.5949 4.6268 13.9681 5.4 13.9681Z",...t})),s=window.ReactJSXRuntime,a=e=>{const{blockName:r,childPath:o="",pluginName:t="spectra"}=e;if(!["spectra","spectra-pro"].includes(t)||"spectra"===t&&!window?.uagb_blocks_info?.uagb_url||"spectra-pro"===t&&!window?.spectra_pro_blocks_info?.spectra_pro_url)return null;if(!r)return null;let n="";switch(t){case"spectra":n=`${window.uagb_blocks_info.uagb_url}/spectra-v3`;break;case"spectra-pro":n=`${window.spectra_pro_blocks_info.spectra_pro_url}/spectra-pro-v2`}const a=`${n}/assets/block-previews/${o?o+"/":""}${r}.webp`;return(0,s.jsx)("img",{width:"100%",src:a,alt:""})},l=window.wp.i18n,i=window.wp.blockEditor,c=e=>{var r;const{settings:o}=e,t=(0,i.__experimentalUseMultipleOriginColorsAndGradients)(),n=null!==(r=o?.map((e=>({...e,enableAlpha:!0,clearable:!0}))))&&void 0!==r?r:[];return(0,s.jsx)(i.InspectorControls,{group:"color",children:(0,s.jsx)(i.__experimentalColorGradientSettingsDropdown,{__experimentalIsRenderedInSidebar:!0,disableCustomColors:!1,disableCustomGradients:!1,...t,...e,settings:n})})},u=(0,r.memo)((e=>{const{clientId:r,setAttributes:o,attributes:{backgroundColorHover:t,backgroundGradientHover:n}}=e;return(0,s.jsx)(c,{settings:[{colorValue:t,gradientValue:n,label:(0,l.__)("Background Hover","ultimate-addons-for-gutenberg"),onColorChange:e=>o({backgroundColorHover:e}),onGradientChange:e=>o({backgroundGradientHover:e}),resetAllFilter:()=>o({backgroundColorHover:void 0,backgroundGradientHover:void 0})}],panelId:r})})),d=(0,r.memo)((e=>(0,s.jsx)(u,{...e}))),p=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),b=(0,r.memo)((e=>{const{attributes:o}=e,{style:t,classNames:n}=((e,o=[],t=[],n={})=>(0,r.useMemo)((()=>{const r=[...t],s={...n};return o.forEach((o=>{const{key:t,cssVar:n,className:a,value:l}=o;if(null===n&&null===a)return;const i=`--spectra-${p(t)}`,c=`spectra-${p(t)}`,u=void 0!==n?n:i,d=void 0!==a?a:c,b=e[t]||"",v=void 0!==l?l:b;v&&null!==u&&(s[u]=v),v&&null!==d&&r.push(d)})),{style:s,classNames:r}}),[e,o,t,n]))(o,[{key:"backgroundColor"},{key:"backgroundColorHover"},{key:"backgroundGradient"},{key:"backgroundGradientHover"}],["wp-block-button"]),a=(0,i.useBlockProps)({className:(c=n,c.filter(Boolean).join(" ")),style:t});var c;const u=(0,i.useInnerBlocksProps)(a,{allowedBlocks:["spectra/button"],template:[["spectra/button",{Placeholder:(0,l.__)("Add Text…","ultimate-addons-for-gutenberg")}]]});return(0,s.jsx)("div",{...u})})),v=JSON.parse('{"UU":"spectra/buttons"}');(0,e.registerBlockType)(v.UU,{icon:n(),edit:e=>{const{isSelected:r,attributes:{isPreview:o}}=e;return o?(0,s.jsx)(a,{blockName:"buttons"}):(0,s.jsxs)(s.Fragment,{children:[r&&(0,s.jsx)(d,{...e}),(0,s.jsx)(b,{...e})]})},save:()=>(0,s.jsx)(i.InnerBlocks.Content,{})})}},o={};function t(e){var n=o[e];if(void 0!==n)return n.exports;var s=o[e]={exports:{}};return r[e](s,s.exports,t),s.exports}t.m=r,e=[],t.O=(r,o,n,s)=>{if(!o){var a=1/0;for(u=0;u<e.length;u++){for(var[o,n,s]=e[u],l=!0,i=0;i<o.length;i++)(!1&s||a>=s)&&Object.keys(t.O).every((e=>t.O[e](o[i])))?o.splice(i--,1):(l=!1,s<a&&(a=s));if(l){e.splice(u--,1);var c=n();void 0!==c&&(r=c)}}return r}s=s||0;for(var u=e.length;u>0&&e[u-1][2]>s;u--)e[u]=e[u-1];e[u]=[o,n,s]},t.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),(()=>{var e={6178:0,7430:0};t.O.j=r=>0===e[r];var r=(r,o)=>{var n,s,[a,l,i]=o,c=0;if(a.some((r=>0!==e[r]))){for(n in l)t.o(l,n)&&(t.m[n]=l[n]);if(i)var u=i(t)}for(r&&r(o);c<a.length;c++)s=a[c],t.o(e,s)&&e[s]&&e[s][0](),e[s]=0;return t.O(u)},o=globalThis.webpackChunkspectra_v3=globalThis.webpackChunkspectra_v3||[];o.forEach(r.bind(null,0)),o.push=r.bind(null,o.push.bind(o))})();var n=t.O(void 0,[7430],(()=>t(830)));n=t.O(n)})();