(()=>{"use strict";const e=window.wp.blocks,t=window.wp.i18n,o=window.wp.blockEditor,n=window.wp.components,s=window.ReactJSXRuntime,r=JSON.parse('{"UU":"suredash/notification"}');(0,e.registerBlockType)(r.UU,{icon:(0,s.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"lucide lucide-bell",style:{fill:"none",width:"16px"},children:[(0,s.jsx)("path",{d:"M10.268 21a2 2 0 0 0 3.464 0"}),(0,s.jsx)("path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326"})]}),edit:e=>{const{attributes:{draweropenverposition:r,draweropenhorposition:i,drawerhorpositionoffset:l,drawerverpositionoffset:a},setAttributes:d}=e,p=(0,o.useBlockProps)({style:{fontFamily:"var(--portal-font-family)"},className:"suredash-portal__editor-content"}),c=e?.attributes?.style?.elements?.iconcolor?.color?.stroke||"";return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(o.InspectorControls,{children:(0,s.jsxs)(n.PanelBody,{children:[(0,s.jsxs)(n.__experimentalToggleGroupControl,{__nextHasNoMarginBottom:!0,label:(0,t.__)("Drawer Open Vertically","suredash"),value:r,onChange:e=>d({draweropenverposition:e}),isBlock:!0,children:[(0,s.jsx)(n.__experimentalToggleGroupControlOption,{value:"top",label:(0,t._x)("Top","Open at top direction","suredash")}),(0,s.jsx)(n.__experimentalToggleGroupControlOption,{value:"bottom",label:(0,t._x)("Bottom","Open at bottom direction","suredash")})]}),(0,s.jsx)(o.__experimentalUnitControl,{label:(0,t.__)("Vertical Position Offset","suredash"),labelPosition:"top",__unstableInputWidth:"80px",value:a,onChange:e=>d({drawerverpositionoffset:e})}),(0,s.jsxs)(n.__experimentalToggleGroupControl,{__nextHasNoMarginBottom:!0,label:(0,t.__)("Drawer Open Horizontally","suredash"),value:i,onChange:e=>d({draweropenhorposition:e}),isBlock:!0,children:[(0,s.jsx)(n.__experimentalToggleGroupControlOption,{value:"left",label:(0,t._x)("Left","Open at left position","suredash")}),(0,s.jsx)(n.__experimentalToggleGroupControlOption,{value:"right",label:(0,t._x)("Right","Open at right position","suredash")})]}),(0,s.jsx)(o.__experimentalUnitControl,{label:(0,t.__)("Horizontal Position Offset","suredash"),labelPosition:"top",__unstableInputWidth:"80px",value:l,onChange:e=>d({drawerhorpositionoffset:e})})]})}),(0,s.jsxs)("div",{...p,children:[(0,s.jsx)("style",{children:`\n\t\t\t\t\t\t.wp-block-suredash-notification .portal-notification-trigger svg {\n\t\t\t\t\t\t\tstroke: ${c};\n\t\t\t\t\t\t}\n\t\t\t\t\t`}),(0,s.jsxs)("a",{href:"javascript:void(0)",className:"portal-notification-trigger portal-content",children:[" ",(0,s.jsx)("span",{className:"portal-svg-icon portal-icon-md","aria-hidden":"true","aria-label":"Bell",children:(0,s.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"lucide lucide-bell",children:[(0,s.jsx)("path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9"}),(0,s.jsx)("path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0"})]})}),(0,s.jsx)("span",{className:"notification-unread-count sd-absolute sd-flex sd-items-center sd-justify-center sd-font-12 sd-max-h-20 sd-font-medium sd-bg-danger sd-color-white sd-min-w-20 sd-nowrap sd-radius-9999",children:" 4 "})]})]})]})},save:function(){return(0,s.jsx)(o.InnerBlocks.Content,{})}})})();