(()=>{"use strict";var e={n:o=>{var n=o&&o.__esModule?()=>o.default:()=>o;return e.d(n,{a:n}),n},d:(o,n)=>{for(var s in n)e.o(n,s)&&!e.o(o,s)&&Object.defineProperty(o,s,{enumerable:!0,get:n[s]})},o:(e,o)=>Object.prototype.hasOwnProperty.call(e,o)};const o=window.wp.blocks,n=JSON.parse('{"UU":"snow-monkey-blocks/like-me-box","uK":{"$":{"A":"inc2734.monkey.wrench"}}}'),s=window.ReactJSXRuntime,a=(0,s.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,s.jsx)("rect",{width:"24",height:"24",fill:"none"}),(0,s.jsx)("path",{d:"M5.11,20.39H4.18A1.18,1.18,0,0,1,3,19.22V10.91A1.18,1.18,0,0,1,4.18,9.74h.93a1.17,1.17,0,0,1,1.17,1.17v8.31A1.17,1.17,0,0,1,5.11,20.39Zm-.93-9.56a.09.09,0,0,0-.09.08v8.31a.09.09,0,0,0,.09.08h.93a.09.09,0,0,0,.08-.08V10.91a.09.09,0,0,0-.08-.08Z"}),(0,s.jsx)("path",{d:"M17.49,20.61H8.34a1,1,0,0,1-1-1V11a1.23,1.23,0,0,1,1.15-1.3H9.85L13.3,4.06a1.36,1.36,0,0,1,1.16-.67h.9a1.3,1.3,0,0,1,1,.48,1.44,1.44,0,0,1,.29,1.21l-.9,4.66H20a.94.94,0,0,1,.76.37A1.24,1.24,0,0,1,21,11.19l-2.32,8.53A1.23,1.23,0,0,1,17.49,20.61ZM8.4,19.52h9.09a.18.18,0,0,0,.08-.09l2.32-8.53a.2.2,0,0,0,0-.07H14.43l1.16-6a.41.41,0,0,0-.07-.31.22.22,0,0,0-.16-.08h-.9a.27.27,0,0,0-.22.15l-3.77,6.2h-2A.26.26,0,0,0,8.4,11Z"})]}),t=window.wp.components,l=window.wp.blockEditor,r=window.wp.i18n,i=window.wp.serverSideRender;var c=e.n(i);window.lodash;const w=window.wp.compose;(0,o.registerBlockType)(n.UU,{icon:{foreground:"#cd162c",src:a},edit:function({attributes:e,setAttributes:o}){const{pageName:a}=e,i=(0,w.useViewportMatch)("medium","<")?{}:{popoverProps:{placement:"left-start",offset:259}};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(l.InspectorControls,{children:(0,s.jsx)(t.__experimentalToolsPanel,{label:(0,r.__)("Block settings","snow-monkey-blocks"),dropdownMenuProps:i,children:(0,s.jsx)(t.__experimentalToolsPanelItem,{hasValue:()=>a!==n.uK.$.A,isShownByDefault:!0,label:(0,r.__)("Facebook page name","snow-monkey-blocks"),onDeselect:()=>o({pageName:n.uK.$.A}),children:(0,s.jsx)(t.TextControl,{__next40pxDefaultSize:!0,__nextHasNoMarginBottom:!0,label:(0,r.__)("Facebook page name","snow-monkey-blocks"),value:a,onChange:e=>o({pageName:e})})})})}),(0,s.jsx)("div",{...(0,l.useBlockProps)(),children:a?(0,s.jsx)(c(),{block:"snow-monkey-blocks/like-me-box",attributes:e}):(0,s.jsx)(t.Placeholder,{icon:"thumbs-up",label:(0,r.__)("Like me box","snow-monkey-blocks"),children:(0,r.__)('Please input "Facebook page name"',"snow-monkey-blocks")})})]})},save:function(){return null}})})();