var __awaiter=this&&this.__awaiter||function(t,e,i,n){function r(t){return t instanceof i?t:new i((function(e){e(t)}))}return new(i||(i=Promise))((function(i,o){function a(t){try{c(n.next(t))}catch(t){o(t)}}function s(t){try{c(n["throw"](t))}catch(t){o(t)}}function c(t){t.done?i(t.value):r(t.value).then(a,s)}c((n=n.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var i={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,r,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(t){return function(e){return c([t,e])}}function c(a){if(n)throw new TypeError("Generator is already executing.");while(i)try{if(n=1,r&&(o=a[0]&2?r["return"]:a[0]?r["throw"]||((o=r["return"])&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;if(r=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:i.label++;return{value:a[1],done:false};case 5:i.label++;r=a[1];a=[0];continue;case 7:a=i.ops.pop();i.trys.pop();continue;default:if(!(o=i.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){i=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){i.label=a[1];break}if(a[0]===6&&i.label<o[1]){i.label=o[1];o=a;break}if(o&&i.label<o[2]){i.label=o[2];i.ops.push(a);break}if(o[2])i.ops.pop();i.trys.pop();continue}a=e.call(t,i)}catch(t){a=[6,t];r=0}finally{n=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};import{r as registerInstance,h,H as Host}from"./index-ecdfb761.js";import{S as SozlukApi}from"./index-3bf9b308.js";import"./apiBase-648a161d.js";import"./data-transfer-field-2f305919.js";import"./filter-cbaa3d7d.js";import{c as createMentornityApiInstance}from"./instance-db63ecb7.js";import{g as getSessionDetails,s as sozlukEntries,a as mentornityApiEndpoint}from"./session-a602596d.js";import"./BaseField-0b01dc2c.js";import"./FieldModelGenerator-03c7516c.js";import"./reference-field-a5b414d1.js";import"./index-61dcd269.js";import"./FieldGenerator-3ae403b2.js";import"./date-1bc489bd.js";import"./index-4e451db4.js";import"./index-32d8b974.js";import"./index-23baeeef.js";import"./index-09efdc01.js";import"./index-150b6a59.js";import"./membership-24db029a.js";import"./data-model-f7ccf826.js";import"./table-config-3820fb34.js";import"./string-3065a411.js";import"./User-9f1f4513.js";import"./UserSettings-27df01e6.js";import"./cookie-9f22e0fb.js";import"./kimlik-api-66e341bd.js";import"./_commonjsHelpers-27f122dd.js";import"./index-d3bd30bd.js";import"./mentorinty-bridge-api-f70621dd.js";import"./index-5f14b4fc.js";import"./attachment-d13ad547.js";import"./CalendarConfig-f8d4a70d.js";import"./i18n-4dcb85fe.js";import"./i18n-73c2e20d.js";import"./calendar-470c802a.js";import"./index-a3ca021c.js";import"./moment-65eca6b3.js";var MentornityAcceptInvitationWrapper=function(){function t(t){var e=this;registerInstance(this,t);this.getInvitation=function(){return __awaiter(e,void 0,void 0,(function(){var t;return __generator(this,(function(e){switch(e.label){case 0:t=this;return[4,this.api.getInvitation(this.paramsId)];case 1:t.invitation=e.sent();return[2]}}))}))}}t.prototype.componentWillLoad=function(){var t=getSessionDetails().headers;this.api=createMentornityApiInstance(mentornityApiEndpoint,t);this.apiSozluk=(new SozlukApi).setLanguage(this.language).setContents(sozlukEntries);this.getInvitation()};t.prototype.render=function(){if(!this.invitation)return;var t=this,e=t.invitation,i=t.apiSozluk,n=t.isLoggedIn,r=t.api,o=t.language;var a=e.organisation;return h(Host,null,h("mentornity-root-wrapper",{class:"d-block"},h("div",{class:"pt-2",style:{background:"var(--color-background-secondary)"}},h("mentornity-accept-invitation-widget",{organisation:a,invitation:e,apiSozluk:i,api:r,isLoggedIn:n,language:o}))))};return t}();export{MentornityAcceptInvitationWrapper as mentornity_accept_invitation_wrapper};