var __awaiter=this&&this.__awaiter||function(t,e,n,i){function r(t){return t instanceof n?t:new n((function(e){e(t)}))}return new(n||(n=Promise))((function(n,o){function s(t){try{c(i.next(t))}catch(t){o(t)}}function u(t){try{c(i["throw"](t))}catch(t){o(t)}}function c(t){t.done?n(t.value):r(t.value).then(s,u)}c((i=i.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},i,r,o,s;return s={next:u(0),throw:u(1),return:u(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function u(t){return function(e){return c([t,e])}}function c(u){if(i)throw new TypeError("Generator is already executing.");while(s&&(s=0,u[0]&&(n=0)),n)try{if(i=1,r&&(o=u[0]&2?r["return"]:u[0]?r["throw"]||((o=r["return"])&&o.call(r),0):r.next)&&!(o=o.call(r,u[1])).done)return o;if(r=0,o)u=[u[0]&2,o.value];switch(u[0]){case 0:case 1:o=u;break;case 4:n.label++;return{value:u[1],done:false};case 5:n.label++;r=u[1];u=[0];continue;case 7:u=n.ops.pop();n.trys.pop();continue;default:if(!(o=n.trys,o=o.length>0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]<o[3])){n.label=u[1];break}if(u[0]===6&&n.label<o[1]){n.label=o[1];o=u;break}if(o&&n.label<o[2]){n.label=o[2];n.ops.push(u);break}if(o[2])n.ops.pop();n.trys.pop();continue}u=e.call(t,n)}catch(t){u=[6,t];r=0}finally{i=o=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:true}}};System.register(["./p-9744e7cb.system.js","./p-39f25a84.system.js"],(function(t){"use strict";var e,n,i,r,o,s;return{setters:[function(t){e=t.r;n=t.c;i=t.h;r=t.H},function(t){o=t.g;s=t.a}],execute:function(){var u=".menu{position:fixed;pointer-events:none;top:0;left:0;padding:2px;background-color:var(--color-surface-1, #F6F6F6);border-radius:8px;-webkit-box-shadow:0px 8px 12px rgba(0, 0, 0, 0.08);box-shadow:0px 8px 12px rgba(0, 0, 0, 0.08);width:240px;opacity:0;-webkit-transition:opacity 0.5s;-moz-transition:opacity 0.5s;transition:opacity 0.5s;z-index:90000}.menu__open{pointer-events:auto;opacity:1}.outzone{position:fixed;top:0;left:0;width:100%;height:100vh;z-index:80000}";var c=u;var a=t("bds_menu",function(){function t(t){var i=this;e(this,t);this.bdsToggle=n(this,"bdsToggle",7);this.refMenuElement=function(t){i.menuElement=t};this.onClickCloseButtom=function(t){i.open=false;t.stopPropagation()};this.refElement=null;this.intoView=null;this.menupositionTop=0;this.menupositionLeft=0;this.menu=null;this.position="right";this.open=false}t.prototype.componentWillLoad=function(){this.refElement=document.getElementById(this.menu);this.intoView=o(this.refElement)};t.prototype.toggle=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.open=!this.open;return[2]}))}))};t.prototype.openMenu=function(){this.bdsToggle.emit({value:this.open});if(this.open){var t=s({actionElement:this.refElement,changedElement:this.menuElement,intoView:this.intoView});this.menupositionTop=t.top;this.menupositionLeft=t.left}};t.prototype.render=function(){var t;var e=this;var n={top:"".concat(this.menupositionTop,"px"),left:"".concat(this.menupositionLeft,"px")};return i(r,{key:"c6d6665307bc889fce632b4dc0757319bd7d53f9"},i("div",{key:"e2fbdd3122c159f2e162e1050560c74c0e36860c",ref:this.refMenuElement,class:(t={menu:true},t["menu__".concat(this.position)]=true,t["menu__open"]=this.open,t),style:n},i("slot",{key:"e6ca6e31b4af181de7dd071f48a9026e3a68d458"})),this.open&&i("div",{key:"bdeffea095ddc8e81bde07fbc03b640a0ed7a45f",class:{outzone:true},onClick:function(t){return e.onClickCloseButtom(t)}}))};Object.defineProperty(t,"watchers",{get:function(){return{open:["openMenu"]}},enumerable:false,configurable:true});return t}());a.style=c}}}));
//# sourceMappingURL=p-60bf196e.system.entry.js.map