(()=>{"use strict";var e={n:n=>{var t=n&&n.__esModule?()=>n.default:()=>n;return e.d(t,{a:t}),t},d:(n,t)=>{for(var a in t)e.o(t,a)&&!e.o(n,a)&&Object.defineProperty(n,a,{enumerable:!0,get:t[a]})},o:(e,n)=>Object.prototype.hasOwnProperty.call(e,n)};const n=window.wp.blocks,t=JSON.parse('{"UU":"events-manager/calendar"}'),a=window.React,l=window.wp.i18n,r=window.wp.blockEditor,o=window.wp.components,s=window.wp.serverSideRender;var c=e.n(s);const g=[{label:(0,l.__)("Responsive","events-manager"),value:"auto"},{label:(0,l.__)("Large","events-manager"),value:"large"},{label:(0,l.__)("Medium","events-manager"),value:"medium"},{label:(0,l.__)("Small","events-manager"),value:"small"}];(0,n.registerBlockType)(t.UU,{edit:function({attributes:e,setAttributes:n}){const{title:t,long_events:s,category:v,scope:i,calendar_size:m}=e;return(0,a.createElement)(a.Fragment,null,(0,a.createElement)(r.InspectorControls,null,(0,a.createElement)(o.PanelBody,{title:(0,l.__)("Calendar settings","events-manager")},(0,a.createElement)(o.TextControl,{label:(0,l.__)("Title","events-manager"),value:t,onChange:e=>n({title:e})}),(0,a.createElement)(o.ToggleControl,{label:(0,l.__)("Show long events","events-manager"),checked:!!s,onChange:e=>n({long_events:!!e})}),(0,a.createElement)(o.ToggleControl,{label:(0,l.__)("Future events only","events-manager"),checked:"future"===i,onChange:e=>n({scope:e?"future":"all"})}),(0,a.createElement)(o.TextControl,{label:(0,l.__)("Category IDs","events-manager"),help:(0,l.__)("1,2,3 or 2 (0 = all)","events-manager"),value:v,onChange:e=>n({category:e})}),(0,a.createElement)(o.SelectControl,{label:(0,l.__)("Calendar size","events-manager"),value:m,options:g,onChange:e=>n({calendar_size:e})}))),(0,a.createElement)("div",{...(0,r.useBlockProps)()},(0,a.createElement)(c(),{block:"events-manager/calendar",attributes:e})))},save:()=>null})})();