!function(){"use strict";var e={};function n(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}(function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})})(e);var t=window.wp.element,o=window.lodash,r=window.wp.plugins,i=window.wp.hooks,u=window.nisje.pluginEvents,s=window.nisje.settings,c=window.nisje.components;function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,o)}return t}function l(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?a(Object(o),!0).forEach((function(t){n(e,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):a(Object(o)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(o,n))}))}return e}(0,i.addFilter)("EventFormEditInitialState","normisjon-event-taxonomies",(function(e,n){return(0,s.getOption)("normisjonEventTaxonomies",[]).forEach((function(t){var r=(0,o.get)(n,t.key,[]);(0,o.isEmpty)(r)||(e[t.key]=r[0])})),e})),(0,r.registerPlugin)("normisjon",{render:function(){var e=(0,s.getOption)("normisjonEventTaxonomies",[]);return(0,t.createElement)(u.EventCreateControls,null,(function(r){var i=r.values,u=r.setValues;return e.map((function(e){var r=(0,o.get)(i,e.key,0);return(0,t.createElement)(c.SelectControl,{key:e.key,label:e.name,value:r,options:e.options,onChange:function(t){return u(l(l({},i),{},n({},e.key,t)))}})}))}))}}),(window.nisje=window.nisje||{}).pluginNormisjon=e}();