"use strict";(self.webpackChunkapp=self.webpackChunkapp||[]).push([[8875],{8875:(A,u,n)=>{n.r(u),n.d(u,{ListofpurchasesPageModule:()=>L});var l=n(6019),p=n(9133),e=n(4599),a=n(8699),s=n(3668),f=n(2670),g=n(6875);function m(t,r){if(1&t&&(s.TgZ(0,"ion-list"),s.TgZ(1,"ion-item"),s.TgZ(2,"ion-badge",3),s._uU(3),s.ALo(4,"translate"),s.ALo(5,"translate"),s.qZA(),s.TgZ(6,"ion-label"),s._uU(7),s.ALo(8,"translate"),s.ALo(9,"translate"),s.ALo(10,"translate"),s.TgZ(11,"p"),s._uU(12),s.qZA(),s.qZA(),s.qZA(),s.qZA()),2&t){const o=r.$implicit;s.xp6(2),s.Q6J("color",o.isPublic?"primary":"secondary"),s.xp6(1),s.hij(" ",o.isPublic?s.lcZ(4,4,"PUBLIC"):s.lcZ(5,6,"PRIVATE")," "),s.xp6(4),s.hij(" ","unlockquiz"===o.productId?s.lcZ(8,8,"UNLOCKQUIZ"):"unlockcourse"===o.productId?s.lcZ(9,10,"UNLOCKCOURSE"):s.lcZ(10,12,"UNLOCKPLATFORM")," "),s.xp6(5),s.Oqu(o.name)}}const d=[{path:"",component:(()=>{class t{constructor(o,i){this.route=o,this.gameService=i}ionViewWillEnter(){this.purchases=[],this.gameService.purchases.forEach(o=>{if("unlockquiz"===o.productId){const i=this.gameService.listOfQuizzes.find(c=>c.quizId===o.quizId);i&&(o.name=i.quizName)}else if("unlockcourse"===o.productId){const i=this.gameService.listOfCourses.find(c=>c.courseId===o.courseId);i&&(o.name=i.courseName)}this.purchases.push(o)}),this.purchases.sort(this.compare)}compare(o,i){return 1===o.isPublic&&0===i.isPublic?1:0===o.isPublic&&1===i.isPublic?-1:0}ngOnInit(){}}return t.\u0275fac=function(o){return new(o||t)(s.Y36(a.gz),s.Y36(f.B))},t.\u0275cmp=s.Xpm({type:t,selectors:[["app-listofpurchases"]],decls:12,vars:7,consts:[["routerLink","/inappstore"],["name","arrow-back","color","primary"],[4,"ngFor","ngForOf"],["slot","end",3,"color"]],template:function(o,i){1&o&&(s.TgZ(0,"ion-header"),s.TgZ(1,"ion-toolbar"),s.TgZ(2,"ion-buttons"),s.TgZ(3,"ion-button",0),s._UZ(4,"ion-icon",1),s._uU(5),s.ALo(6,"translate"),s.qZA(),s.qZA(),s.TgZ(7,"ion-title"),s._uU(8),s.ALo(9,"translate"),s.qZA(),s.qZA(),s.qZA(),s.TgZ(10,"ion-content"),s.YNc(11,m,13,14,"ion-list",2),s.qZA()),2&o&&(s.xp6(5),s.Oqu(s.lcZ(6,3,"BACK")),s.xp6(3),s.Oqu(s.lcZ(9,5,"PURCHASES")),s.xp6(3),s.Q6J("ngForOf",i.purchases))},directives:[e.Gu,e.sr,e.Sm,e.YG,e.YI,a.rH,e.gu,e.wd,e.W2,l.sg,e.q_,e.Ie,e.yp,e.Q$],pipes:[g.X$],styles:[""]}),t})()}];let h=(()=>{class t{}return t.\u0275fac=function(o){return new(o||t)},t.\u0275mod=s.oAB({type:t}),t.\u0275inj=s.cJS({imports:[[a.Bz.forChild(d)],a.Bz]}),t})();var Z=n(1382);let L=(()=>{class t{}return t.\u0275fac=function(o){return new(o||t)},t.\u0275mod=s.oAB({type:t}),t.\u0275inj=s.cJS({imports:[[Z.m,l.ez,p.u5,e.Pc,h]]}),t})()}}]);