dealpos 25.46.1 → 25.47.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (114) hide show
  1. package/browser/{chunk-UF4JB7JY.js → chunk-2JZS4BMV.js} +1 -1
  2. package/browser/{chunk-NORSMLUM.js → chunk-2LSFBE4Q.js} +1 -1
  3. package/browser/chunk-3GPGJFQV.js +1 -0
  4. package/browser/{chunk-DMQGQTA7.js → chunk-3HS4V7LK.js} +1 -1
  5. package/browser/{chunk-TXTD756I.js → chunk-474F5EIO.js} +1 -1
  6. package/browser/chunk-4ZXLS56M.js +4 -0
  7. package/browser/{chunk-ZOP4QRJ5.js → chunk-5OKSTEWQ.js} +1 -1
  8. package/browser/{chunk-JO2HRK4G.js → chunk-5PUIMWNW.js} +1 -1
  9. package/browser/{chunk-ZNSETEMV.js → chunk-647PQZMJ.js} +1 -1
  10. package/browser/chunk-66MCBKC7.js +1 -0
  11. package/browser/{chunk-XNJI57TR.js → chunk-6SC4T77S.js} +1 -1
  12. package/browser/{chunk-SUIJKKNU.js → chunk-6TGKH2KC.js} +1 -1
  13. package/browser/{chunk-TCCZCKU3.js → chunk-7P3E5NJO.js} +1 -1
  14. package/browser/chunk-AIM6VG2H.js +1 -0
  15. package/browser/{chunk-PCBQ5MJX.js → chunk-BALKIB67.js} +1 -1
  16. package/browser/chunk-BATVMTNZ.js +1 -0
  17. package/browser/{chunk-U35DBD6P.js → chunk-BCD363QF.js} +1 -1
  18. package/browser/{chunk-L75QJKLP.js → chunk-C5S5BG57.js} +1 -1
  19. package/browser/{chunk-Q45XVCPE.js → chunk-CAGQRIPG.js} +1 -1
  20. package/browser/{chunk-MJMWJ6KM.js → chunk-CX7CJIXK.js} +3 -3
  21. package/browser/{chunk-HZQHCXRX.js → chunk-D6Y2NJT7.js} +1 -1
  22. package/browser/{chunk-2YRHUGAG.js → chunk-DGF2U27C.js} +2 -2
  23. package/browser/chunk-DLNZDHGS.js +1 -0
  24. package/browser/{chunk-LKMXVSXC.js → chunk-DM4PGQEH.js} +8 -8
  25. package/browser/{chunk-5UZJWGXF.js → chunk-DSQH2UQV.js} +2 -2
  26. package/browser/chunk-E3LGKC33.js +1 -0
  27. package/browser/{chunk-5NDXC2Q2.js → chunk-EAFSL5ZF.js} +1 -1
  28. package/browser/{chunk-GEGFHXYS.js → chunk-EKORPCX3.js} +1 -1
  29. package/browser/{chunk-MRLNJIME.js → chunk-EZ5EW4QK.js} +1 -1
  30. package/browser/{chunk-IMSP4CUG.js → chunk-FIMFYHCK.js} +1 -1
  31. package/browser/chunk-FQSAJFS6.js +1 -0
  32. package/browser/{chunk-HUQCWL5X.js → chunk-FR66DARJ.js} +1 -1
  33. package/browser/{chunk-7JXTBPO6.js → chunk-GK4I3EKQ.js} +1 -1
  34. package/browser/{chunk-34YS4QAG.js → chunk-GNODCFOP.js} +1 -1
  35. package/browser/{chunk-U5KSGGL5.js → chunk-H4DUHWPT.js} +1 -1
  36. package/browser/{chunk-CB4INKRH.js → chunk-HLML4BKF.js} +1 -1
  37. package/browser/{chunk-3KHAUY4Q.js → chunk-HTJJDQ3V.js} +1 -1
  38. package/browser/{chunk-6SFTCH6L.js → chunk-HU3YNBXW.js} +15 -15
  39. package/browser/{chunk-JBA2HEME.js → chunk-HV4KV3DJ.js} +1 -1
  40. package/browser/{chunk-YII66PEK.js → chunk-I2P6B3IK.js} +1 -1
  41. package/browser/{chunk-QCWVOQ4U.js → chunk-IQDT5K5I.js} +1 -1
  42. package/browser/{chunk-NCBSJKWK.js → chunk-IR2QPNXA.js} +2 -2
  43. package/browser/{chunk-T6SKNBS4.js → chunk-IT6GHGT4.js} +1 -1
  44. package/browser/chunk-IUDUQNN7.js +24 -0
  45. package/browser/{chunk-H6OK7AN4.js → chunk-JEFUIFY4.js} +1 -1
  46. package/browser/chunk-JKMJAL6Y.js +3 -0
  47. package/browser/chunk-JVEVLEGH.js +2 -0
  48. package/browser/{chunk-X4NTI6VE.js → chunk-JWH2AZ3Z.js} +1 -1
  49. package/browser/{chunk-4UXONUIZ.js → chunk-KBISFX5T.js} +1 -1
  50. package/browser/{chunk-K4BVYUUE.js → chunk-KUYGPZRD.js} +1 -1
  51. package/browser/{chunk-5KZDUBOJ.js → chunk-L32BGRA6.js} +1 -1
  52. package/browser/{chunk-AKU4AVU5.js → chunk-LWA7CCEY.js} +4 -4
  53. package/browser/{chunk-IR7BRACV.js → chunk-M5KE2CW7.js} +1 -1
  54. package/browser/{chunk-QQS5ITUF.js → chunk-MA6NB2EZ.js} +1 -1
  55. package/browser/chunk-ME5KGPYC.js +1 -0
  56. package/browser/chunk-MHVF2KXK.js +1 -0
  57. package/browser/{chunk-YGE2LJY6.js → chunk-MSW23AJV.js} +1 -1
  58. package/browser/{chunk-6CFANTH2.js → chunk-NN2EFVJK.js} +1 -1
  59. package/browser/chunk-O5IZN23R.js +14 -0
  60. package/browser/{chunk-EWDEAX6M.js → chunk-OFTORAX4.js} +1 -1
  61. package/browser/chunk-ON47ICI3.js +1 -0
  62. package/browser/{chunk-PTLVRO2T.js → chunk-ORQ3JDJE.js} +1 -1
  63. package/browser/{chunk-F464PNNI.js → chunk-P53EATPC.js} +1 -1
  64. package/browser/{chunk-FHI2YRID.js → chunk-P632SS2L.js} +1 -1
  65. package/browser/{chunk-B4CTAXRS.js → chunk-P7UMAIIW.js} +1 -1
  66. package/browser/{chunk-FV5QAPSD.js → chunk-Q473GHR5.js} +1 -1
  67. package/browser/{chunk-QIHNG7HJ.js → chunk-QIFQFG3V.js} +1 -1
  68. package/browser/{chunk-FDKCQIES.js → chunk-QQ4DCXLE.js} +1 -1
  69. package/browser/{chunk-4PALKQ75.js → chunk-QRTOTG7S.js} +1 -1
  70. package/browser/{chunk-T475ZPAG.js → chunk-QVJJGWXC.js} +16 -16
  71. package/browser/{chunk-25YHVZV6.js → chunk-ROLAW5XO.js} +1 -1
  72. package/browser/chunk-RONQFUCZ.js +1 -0
  73. package/browser/{chunk-F7J5TUAB.js → chunk-RSN23KAR.js} +2 -2
  74. package/browser/{chunk-SCBXIGUC.js → chunk-RYTM3LHN.js} +1 -1
  75. package/browser/chunk-SGSO4UVM.js +1 -0
  76. package/browser/{chunk-IDKR4Z5E.js → chunk-SKE3MW2D.js} +1 -1
  77. package/browser/chunk-T5FBPKPS.js +1 -0
  78. package/browser/{chunk-GJZAWVWD.js → chunk-TH7SO4LD.js} +1 -1
  79. package/browser/{chunk-R4H3DENZ.js → chunk-UBCB4G4S.js} +1 -1
  80. package/browser/{chunk-EOQ6TLK6.js → chunk-UBXEYFKJ.js} +1 -1
  81. package/browser/{chunk-HC2WTBU3.js → chunk-W3EZ4JHD.js} +2 -2
  82. package/browser/{chunk-JGVE3GME.js → chunk-WA4WWHYW.js} +1 -1
  83. package/browser/{chunk-DX24F37F.js → chunk-WBO7PC7R.js} +1 -1
  84. package/browser/{chunk-RNEHGC5X.js → chunk-WDD7INF4.js} +1 -1
  85. package/browser/chunk-WY6RTBDA.js +3 -0
  86. package/browser/{chunk-Q3MH2WHW.js → chunk-XE46ZDV6.js} +1 -1
  87. package/browser/{chunk-2BOU7MZT.js → chunk-YG6ODXQF.js} +1 -1
  88. package/browser/chunk-YMLCHH2G.js +1 -0
  89. package/browser/chunk-YV6MAUKK.js +1 -0
  90. package/browser/{chunk-V77HSR6D.js → chunk-ZSW24KNO.js} +1 -1
  91. package/browser/index.html +2 -2
  92. package/browser/main-VVZRGXWB.js +3 -0
  93. package/package.json +1 -1
  94. package/browser/chunk-2WXO2CVP.js +0 -1
  95. package/browser/chunk-3EJP6UEJ.js +0 -3
  96. package/browser/chunk-56HGOK5G.js +0 -3
  97. package/browser/chunk-7GUNPVLF.js +0 -1
  98. package/browser/chunk-BNFYSCGM.js +0 -1
  99. package/browser/chunk-FR3YFIOJ.js +0 -1
  100. package/browser/chunk-GVPC56QQ.js +0 -4
  101. package/browser/chunk-J4TPORWI.js +0 -1
  102. package/browser/chunk-K6ZANPDY.js +0 -1
  103. package/browser/chunk-LDALTRKQ.js +0 -2
  104. package/browser/chunk-LKBRVKIZ.js +0 -14
  105. package/browser/chunk-LR6FISWP.js +0 -1
  106. package/browser/chunk-NA5O2ACR.js +0 -24
  107. package/browser/chunk-PGCDKIOX.js +0 -1
  108. package/browser/chunk-QBUTQU3U.js +0 -1
  109. package/browser/chunk-TCKWGMV7.js +0 -1
  110. package/browser/chunk-VV564BYL.js +0 -1
  111. package/browser/chunk-VVRBBTBO.js +0 -1
  112. package/browser/chunk-XVDRWDA2.js +0 -1
  113. package/browser/chunk-YFKW562E.js +0 -1
  114. package/browser/main-VEM3F6IE.js +0 -3
@@ -1 +1 @@
1
- import{a as c}from"./chunk-USJ6ILEE.js";import{a as t}from"./chunk-GVPC56QQ.js";import{la as i}from"./chunk-JYZTRN6N.js";import{a}from"./chunk-SNAKHGZS.js";var n=class o{constructor(){}inititalizeIntercom(){let e=this.getFromLocalStorage();e?.Enabled&&window.Intercom("boot",{app_id:t.intercom.appId,name:e.Name,email:e.Email,created_at:e.Created,user_hash:e.Hash})}shutdown(){this.getFromLocalStorage()?.Enabled&&(window.Intercom("shutdown"),this.clearStorage())}clearStorage(){localStorage.removeItem("Intercom")}updateLocalStorage(e){localStorage.setItem("Intercom",JSON.stringify(e))}getFromLocalStorage(){let e=localStorage.getItem("Intercom");return JSON.parse(e)}hideLauncher(){let e=this.getFromLocalStorage();e?.Enabled&&(e.hide_default_launcher=!0,window.Intercom("update",a({app_id:t.intercom.appId},e)),this.updateLocalStorage(e))}showLauncher(){let e=this.getFromLocalStorage();e?.Enabled&&(e.hide_default_launcher=!1,window.Intercom("update",a({app_id:t.intercom.appId},e)),this.updateLocalStorage(e))}isHideLauncher(){let e=this.getFromLocalStorage();return c.IsEmpty(e?.hide_default_launcher)?!1:e?.hide_default_launcher}static \u0275fac=function(r){return new(r||o)};static \u0275prov=i({token:o,factory:o.\u0275fac,providedIn:"root"})};export{n as a};
1
+ import{a as c}from"./chunk-USJ6ILEE.js";import{a as t}from"./chunk-4ZXLS56M.js";import{la as i}from"./chunk-JYZTRN6N.js";import{a}from"./chunk-SNAKHGZS.js";var n=class o{constructor(){}inititalizeIntercom(){let e=this.getFromLocalStorage();e?.Enabled&&window.Intercom("boot",{app_id:t.intercom.appId,name:e.Name,email:e.Email,created_at:e.Created,user_hash:e.Hash})}shutdown(){this.getFromLocalStorage()?.Enabled&&(window.Intercom("shutdown"),this.clearStorage())}clearStorage(){localStorage.removeItem("Intercom")}updateLocalStorage(e){localStorage.setItem("Intercom",JSON.stringify(e))}getFromLocalStorage(){let e=localStorage.getItem("Intercom");return JSON.parse(e)}hideLauncher(){let e=this.getFromLocalStorage();e?.Enabled&&(e.hide_default_launcher=!0,window.Intercom("update",a({app_id:t.intercom.appId},e)),this.updateLocalStorage(e))}showLauncher(){let e=this.getFromLocalStorage();e?.Enabled&&(e.hide_default_launcher=!1,window.Intercom("update",a({app_id:t.intercom.appId},e)),this.updateLocalStorage(e))}isHideLauncher(){let e=this.getFromLocalStorage();return c.IsEmpty(e?.hide_default_launcher)?!1:e?.hide_default_launcher}static \u0275fac=function(r){return new(r||o)};static \u0275prov=i({token:o,factory:o.\u0275fac,providedIn:"root"})};export{n as a};
@@ -0,0 +1 @@
1
+ import{Ab as g,Bb as h,Ca as I,Gb as l,Hb as c,Ib as w,Mb as v,Nb as b,Pb as y,Qb as o,Xa as r,ac as P,cc as T,dc as s,fc as _,gc as A,hb as E,ta as u,tb as S,ua as C,vb as m,xb as p,yb as f}from"./chunk-JYZTRN6N.js";function M(n,e){if(n&1&&s(0),n&2){let t=o().$implicit,i=o(3);_(" x",i.items[0][t]," ")}}function O(n,e){if(n&1&&s(0),n&2){let t=o().$implicit,i=o(3);_(" ",i.items[0][t]," ")}}function F(n,e){if(n&1&&m(0,M,1,1)(1,O,1,1),n&2){let t=e.$implicit,i=o(3);p(i.isQuantityProperty(t)&&i.items[0][t]>1?0:i.isQuantityProperty(t)?-1:1)}}function $(n,e){if(n&1&&g(0,F,2,1,null,null,f),n&2){let t=o(2);h(t.columnShow)}}function V(n,e){if(n&1&&s(0),n&2){let t=o(2);_(" ",t.items[0]," ")}}function L(n,e){if(n&1&&(l(0,"span",7),s(1),c()),n&2){let t=o(2);r(),A("",t.items.length," ",`${t.badgeLabel}`)}}function j(n,e){if(n&1){let t=v();l(0,"button",13),y("click",function(){u(t);let a=o(2);return C(a.initializeFiltered(a.items))}),c()}if(n&2){let t=o(2);S("data-bs-target","#panelCollapse-"+t.index)("aria-controls","panelCollapse-"+t.index)}}function Q(n,e){if(n&1){let t=v();l(0,"div",11),w(1,"i",14),l(2,"input",15,0),y("input",function(a){u(t);let d=o(2);return C(d.onSearchItems(a,d.items))})("keyup.enter",function(a){u(t);let d=o(2);return C(d.onSearchItems(a,d.items))}),c()()}if(n&2){let t=o(2);r(2),b("placeholder",`${"Search "+t.label+"..."}`)}}function z(n,e){if(n&1&&(l(0,"div",12)(1,"p",16),s(2),c()()),n&2){let t=o(2);r(2),_(" No ",t.label," found ")}}function D(n,e){if(n&1&&s(0),n&2){let t=o(2).$implicit,i=o(2).$implicit;_(" x",i.value[t]," ")}}function N(n,e){if(n&1&&s(0),n&2){let t=o(2).$implicit,i=o(2).$implicit;_(" ",i.value[t]," ")}}function B(n,e){if(n&1&&(l(0,"div",22),m(1,D,1,1)(2,N,1,1),c()),n&2){let t=o(),i=t.$implicit,a=t.$index,d=o(2).$implicit,x=o(3);P("text-end",a>0),r(),p(x.isQuantityProperty(i)&&d.value[i]>1?1:x.isQuantityProperty(i)?-1:2)}}function W(n,e){if(n&1&&m(0,B,3,3,"div",21),n&2){let t=e.$implicit,i=o(2).$implicit,a=o(3);p(a.isQuantityProperty(t)&&i.value[t]<=1?-1:0)}}function q(n,e){if(n&1&&(l(0,"div",18),g(1,W,1,1,null,null,f),c()),n&2){let t=o(4);r(),h(t.columnShow)}}function Y(n,e){if(n&1&&s(0),n&2){let t=o().$implicit;_(" ",t.value," ")}}function G(n,e){if(n&1&&(l(0,"div",17)(1,"div",18)(2,"div",19),s(3),c(),l(4,"div",20),m(5,q,3,0,"div",18)(6,Y,1,1),c()()()),n&2){let t=e.$implicit,i=o(3);r(3),_(" ",t.index," "),r(2),p(i.columnShow&&i.columnShow.length>0&&typeof t.value=="object"?5:6)}}function H(n,e){if(n&1&&g(0,G,7,2,"div",17,f),n&2){let t=o(2);h(t.filteredItems())}}function J(n,e){if(n&1&&(l(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"span"),w(5,"i",5),c(),l(6,"span",6),s(7),m(8,$,2,0)(9,V,1,1),c(),m(10,L,2,2,"span",7),c(),m(11,j,1,2,"button",8),c(),l(12,"div",9)(13,"div",10),m(14,Q,4,1,"div",11),m(15,z,3,1,"div",12)(16,H,2,0),c()()()()),n&2){let t=o();b("id","accordion-"+t.index),r(5),T(t.icon),r(2),_("",t.label,": "),r(),p(t.columnShow&&t.columnShow.length>0&&typeof t.items[0]=="object"?8:9),r(2),p(t.items.length>1?10:-1),r(),p(t.items.length>1?11:-1),r(),b("id","panelCollapse-"+t.index),r(2),p(t.items.length>10?14:-1),r(),p(t.filteredItems().length==0?15:16)}}var k=class n{items;label;badgeLabel;keyValue;index;fullWidth=!1;columnShow=[];icon;filteredItems=I([]);ngOnInit(){if(this.items&&this.items.length>0){if(this.columnShow&&this.columnShow.length>0){this.items=this.items;return}if(typeof this.items[0]=="object"&&this.keyValue){this.items=this.items.map(e=>e[this.keyValue]);return}this.items=this.items}}initializeFiltered(e){this.filteredItems.set(e.map((t,i)=>({index:i+1,value:t})))}onSearchItems(e,t){let i=e.target.value.toString().toLowerCase();if(!i){this.filteredItems.set(t.map((a,d)=>({index:d+1,value:a})));return}this.filteredItems.set(t.map((a,d)=>({index:d+1,value:a})).filter(a=>typeof a.value=="object"&&this.columnShow&&this.columnShow.length>0?this.columnShow.some(d=>{let x=a.value[d];return x&&x.toString().toLowerCase().includes(i)}):a.value.toString().toLowerCase().includes(i)))}isShowColumn(e){if(this.columnShow&&this.columnShow.length>0)return this.columnShow.includes(e)}isQuantityProperty(e){if(!e)return!1;let t=e.toLowerCase();return t.includes("quantity")||t.includes("qty")}static \u0275fac=function(t){return new(t||n)};static \u0275cmp=E({type:n,selectors:[["POS-item-accordion"]],inputs:{items:"items",label:"label",badgeLabel:"badgeLabel",keyValue:"keyValue",index:"index",fullWidth:"fullWidth",columnShow:"columnShow",icon:"icon"},decls:1,vars:1,consts:[["searchInput",""],[1,"accordion","accordion-wrapper",3,"id"],[1,"accordion-item","accordion-item-wrapper"],[1,"d-flex","align-items-center","justify-content-between"],[1,"d-flex","gap-4","align-items-center"],["aria-hidden","true"],[1,"text-muted"],[1,"ms-2","badge","total-badge","text-dark","rounded-pill"],["type","button","data-bs-toggle","collapse","aria-expanded","false",1,"accordion-button","d-flex","justify-content-center","align-items-center","accordion-button-wrapper","collapsed"],[1,"accordion-collapse","collapse",3,"id"],[1,"accordion-body","accordion-body-wrapper"],[1,"input-wrapper"],[1,"no-data-wrapper"],["type","button","data-bs-toggle","collapse","aria-expanded","false",1,"accordion-button","d-flex","justify-content-center","align-items-center","accordion-button-wrapper","collapsed",3,"click"],[1,"fa","fa-search","search-icon"],["type","text",3,"input","keyup.enter","placeholder"],[1,"text-center","fst-italic","text-muted",2,"margin-top","18px"],[1,"accordion-body-item"],[1,"row"],[1,"col-2","number-wrapper"],[1,"col-10"],[1,"col",2,"padding","0","padding-right","16px",3,"text-end"],[1,"col",2,"padding","0","padding-right","16px"]],template:function(t,i){t&1&&m(0,J,17,10,"div",1),t&2&&p(i.items&&i.items.length>0?0:-1)},styles:[".accordion-wrapper[_ngcontent-%COMP%]{border:0px!important}.accordion-item-wrapper[_ngcontent-%COMP%]{border:none!important;padding:0}.accordion-button-wrapper[_ngcontent-%COMP%]{padding:0;margin-left:10px;width:20px;height:20px;box-shadow:none!important;border:1px solid #d4d8db!important;border-radius:100%;min-height:auto;position:relative;background-color:#ddd;transition:all .3s ease}.accordion-button-wrapper[_ngcontent-%COMP%]:after{filter:brightness(0)!important}.accordion-button-wrapper[_ngcontent-%COMP%]:hover{background-color:#6c757d;scale:1.1}.accordion-button-wrapper[_ngcontent-%COMP%]:hover:after{filter:brightness(0) invert(1)!important}.accordion-body-wrapper[_ngcontent-%COMP%]{border-left:3px solid #6c757d!important;background-color:#f8f9fa!important;padding:12px;margin-top:10px;border-radius:10px}.accordion-button[_ngcontent-%COMP%]:after{display:flex;align-items:center!important;justify-content:center!important;position:static!important;margin:0!important;width:.8rem!important;height:.8rem!important;background-size:.8rem!important;color:#000!important}.total-badge[_ngcontent-%COMP%]{background-color:#d7dade;height:fit-content}.accordion-body-item[_ngcontent-%COMP%]{padding:8px;border:1px solid #dee2e6;border-radius:5px;background-color:#fff;margin-bottom:4px;transition:all .2s ease-in-out}.accordion-body-item[_ngcontent-%COMP%]:hover{box-shadow:0 4px 8px #0000001a;border:1px solid #6c757d}.input-wrapper[_ngcontent-%COMP%]{position:relative;width:100%;margin-bottom:12px}.input-wrapper[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{width:100%;padding-left:32px;height:40px;border:1px solid #ced4da;border-radius:6px;outline:none}.search-icon[_ngcontent-%COMP%]{position:absolute;top:50%;left:10px;transform:translateY(-50%);font-size:12px;color:#6c757d}.number-wrapper[_ngcontent-%COMP%]{padding-right:0;padding-left:16px;text-wrap:nowrap}"]})};export{k as a};
@@ -1,4 +1,4 @@
1
- import{a as Mt,d as kt}from"./chunk-6SGN7MNX.js";import{c as Et,j as It,k as F,l as St}from"./chunk-L76WVZW6.js";import{a as P}from"./chunk-2FWFPV5I.js";import{oa as Tt,pa as k,xa as Ot}from"./chunk-O5SLP4JK.js";import{F as bt,G as vt,a as ft,c as _t,h as ht,i as wt,k as Ct,o as xt,p as yt}from"./chunk-RNLSEEMX.js";import{a as mt}from"./chunk-GVPC56QQ.js";import{Cb as m,Db as o,Eb as s,Fb as M,Ia as A,Jb as I,Kb as S,Kc as ot,Lb as Z,Lc as rt,Mb as h,Ob as g,Pc as j,Qb as r,Qc as at,Tb as N,Vb as D,Wb as B,Xa as l,Xc as L,Ya as T,Yb as J,Yd as ct,Zb as X,be as gt,cc as x,cd as st,db as Q,dc as c,ec as tt,ed as pt,ee as Pt,fc as et,fd as lt,hb as O,ib as K,ic as y,jc as b,jd as dt,ka as W,kc as v,la as z,lb as Y,ma as U,mb as $,na as q,nb as E,pa as w,pc as H,rd as ut,sc as nt,ta as d,tb as G,ua as u,vb as f,vc as R,wc as it,xb as _}from"./chunk-JYZTRN6N.js";import"./chunk-WFMAM73Y.js";import"./chunk-SNAKHGZS.js";var Ft=`
1
+ import{a as Mt,d as kt}from"./chunk-6SGN7MNX.js";import{c as Et,j as It,k as F,l as St}from"./chunk-L76WVZW6.js";import{a as P}from"./chunk-2FWFPV5I.js";import{oa as Tt,pa as k,xa as Ot}from"./chunk-O5SLP4JK.js";import{F as bt,G as vt,a as ft,c as _t,h as ht,i as wt,k as Ct,o as xt,p as yt}from"./chunk-RNLSEEMX.js";import{a as mt}from"./chunk-4ZXLS56M.js";import{Cb as m,Db as o,Eb as s,Fb as M,Ia as A,Jb as I,Kb as S,Kc as ot,Lb as Z,Lc as rt,Mb as h,Ob as g,Pc as j,Qb as r,Qc as at,Tb as N,Vb as D,Wb as B,Xa as l,Xc as L,Ya as T,Yb as J,Yd as ct,Zb as X,be as gt,cc as x,cd as st,db as Q,dc as c,ec as tt,ed as pt,ee as Pt,fc as et,fd as lt,hb as O,ib as K,ic as y,jc as b,jd as dt,ka as W,kc as v,la as z,lb as Y,ma as U,mb as $,na as q,nb as E,pa as w,pc as H,rd as ut,sc as nt,ta as d,tb as G,ua as u,vb as f,vc as R,wc as it,xb as _}from"./chunk-JYZTRN6N.js";import"./chunk-WFMAM73Y.js";import"./chunk-SNAKHGZS.js";var Ft=`
2
2
  .p-inputotp {
3
3
  display: flex;
4
4
  align-items: center;
@@ -19,4 +19,4 @@ import{a as Mt,d as kt}from"./chunk-6SGN7MNX.js";import{c as Et,j as It,k as F,l
19
19
  text-align: center;
20
20
  width: dt('inputotp.input.lg.width');
21
21
  }
22
- `;var Rt=["input"],jt=(i,a,t)=>({$implicit:i,events:a,index:t});function Lt(i,a){if(i&1){let t=h();I(0),o(1,"input",2),g("input",function(n){d(t);let p=r().$implicit,C=r();return u(C.onInput(n,p-1))})("focus",function(n){d(t);let p=r(2);return u(p.onInputFocus(n))})("blur",function(n){d(t);let p=r(2);return u(p.onInputBlur(n))})("paste",function(n){d(t);let p=r(2);return u(p.onPaste(n))})("keydown",function(n){d(t);let p=r(2);return u(p.onKeyDown(n))}),s(),S()}if(i&2){let t=r().$implicit,e=r();l(),x(e.cn(e.cx("pcInputText"),e.styleClass)),m("value",e.getModelValue(t))("pSize",e.size())("variant",e.$variant())("invalid",e.invalid())("pAutoFocus",e.getAutofocus(t))("pt",e.ptm("pcInputText")),G("maxlength",t===1?e.length:1)("type",e.inputType)("name",e.name())("tabindex",e.tabindex)("required",e.required()?"":void 0)("readonly",e.readonly?"":void 0)("disabled",e.$disabled()?"":void 0)}}function Wt(i,a){i&1&&Z(0)}function zt(i,a){if(i&1&&(I(0),E(1,Wt,1,0,"ng-container",3),S()),i&2){let t=r().$implicit,e=r();l(),m("ngTemplateOutlet",e.inputTemplate||e._inputTemplate)("ngTemplateOutletContext",it(2,jt,e.getToken(t-1),e.getTemplateEvents(t-1),t))}}function Ut(i,a){if(i&1&&(I(0),E(1,Lt,2,15,"ng-container",1)(2,zt,2,6,"ng-container",1),S()),i&2){let t=r();l(),m("ngIf",!t.inputTemplate&&!t._inputTemplate),l(),m("ngIf",t.inputTemplate||t._inputTemplate)}}var qt={root:"p-inputotp p-component",pcInputText:"p-inputotp-input"},Vt=(()=>{class i extends Ot{name="inputotp";style=Ft;classes=qt;static \u0275fac=(()=>{let t;return function(n){return(t||(t=A(i)))(n||i)}})();static \u0275prov=z({token:i,factory:i.\u0275fac})}return i})();var At=new q("INPUTOTP_INSTANCE"),Qt={provide:ft,useExisting:W(()=>V),multi:!0},V=(()=>{class i extends It{_componentStyle=w(Vt);$pcInputOtp=w(At,{optional:!0,skipSelf:!0})??void 0;bindDirectiveInstance=w(F,{self:!0});onAfterViewChecked(){this.bindDirectiveInstance.setAttrs(this.ptms(["host","root"]))}readonly;tabindex=null;length=4;styleClass;mask=!1;integerOnly=!1;autofocus;variant=j();size=j();onChange=new T;onFocus=new T;onBlur=new T;inputTemplate;templates;_inputTemplate;tokens=[];value;$variant=ot(()=>this.variant()||this.config.inputStyle()||this.config.inputVariant());get inputMode(){return this.integerOnly?"numeric":"text"}get inputType(){return this.mask?"password":"text"}onAfterContentInit(){this.templates.forEach(t=>{switch(t.getType()){case"input":this._inputTemplate=t.template;break;default:this._inputTemplate=t.template;break}})}getToken(t){return this.tokens[t]}getTemplateEvents(t){return{input:e=>this.onInput(e,t),keydown:e=>this.onKeyDown(e),focus:e=>this.onFocus.emit(e),blur:e=>this.onBlur.emit(e),paste:e=>this.onPaste(e)}}onInput(t,e){let n=t.target.value;if(e===0&&n.length>1){this.handleOnPaste(n,t),t.stopPropagation();return}this.tokens[e]=n,this.updateModel(t),t.inputType==="deleteContentBackward"?this.moveToPrev(t):(t.inputType==="insertText"||t.inputType==="deleteContentForward")&&this.moveToNext(t)}updateModel(t){let e=this.tokens.join("");this.writeModelValue(e),this.onModelChange(e),this.onChange.emit({originalEvent:t,value:e})}updateTokens(){this.value!==null&&this.value!==void 0?Array.isArray(this.value)?this.tokens=[...this.value]:this.tokens=this.value.toString().split(""):this.tokens=[]}getModelValue(t){return this.tokens[t-1]||""}getAutofocus(t){return t===1&&this.autofocus||!1}moveToPrev(t){let e=this.findPrevInput(t.target);e&&(e.focus(),e.select())}moveToNext(t){let e=this.findNextInput(t.target);e&&(e.focus(),e.select())}findNextInput(t){let e=t.nextElementSibling;if(e)return e.nodeName==="INPUT"?e:this.findNextInput(e)}findPrevInput(t){let e=t.previousElementSibling;if(e)return e.nodeName==="INPUT"?e:this.findPrevInput(e)}onInputFocus(t){t.target.select(),this.onFocus.emit(t)}onInputBlur(t){this.onBlur.emit(t)}onKeyDown(t){if(!(t.altKey||t.ctrlKey||t.metaKey))switch(t.code){case"ArrowLeft":this.moveToPrev(t),t.preventDefault();break;case"ArrowUp":case"ArrowDown":t.preventDefault();break;case"Backspace":t.target.value.length===0&&(this.moveToPrev(t),t.preventDefault());break;case"ArrowRight":this.moveToNext(t),t.preventDefault();break;default:(this.integerOnly&&!(Number(t.key)>=0&&Number(t.key)<=9)||this.tokens.join("").length>=this.length&&t.code!=="Delete")&&t.preventDefault();break}}onPaste(t){if(!this.$disabled()&&!this.readonly){let e=t.clipboardData.getData("text");e.length&&this.handleOnPaste(e,t),t.preventDefault()}}handleOnPaste(t,e){let n=t.substring(0,this.length+1);(!this.integerOnly||!isNaN(n))&&(this.tokens=n.split(""),this.updateModel(e))}getRange(t){return Array.from({length:t},(e,n)=>n+1)}trackByFn(t){return t}writeControlValue(t,e){t?Array.isArray(t)&&t.length>0?this.value=t.slice(0,this.length):this.value=t.toString().split("").slice(0,this.length):this.value=t,e(this.value),this.updateTokens(),this.cd.markForCheck()}static \u0275fac=(()=>{let t;return function(n){return(t||(t=A(i)))(n||i)}})();static \u0275cmp=O({type:i,selectors:[["p-inputOtp"],["p-inputotp"],["p-input-otp"]],contentQueries:function(e,n,p){if(e&1&&(N(p,Rt,4),N(p,Tt,4)),e&2){let C;D(C=B())&&(n.inputTemplate=C.first),D(C=B())&&(n.templates=C)}},hostVars:2,hostBindings:function(e,n){e&2&&x(n.cx("root"))},inputs:{readonly:[2,"readonly","readonly",L],tabindex:"tabindex",length:"length",styleClass:"styleClass",mask:"mask",integerOnly:"integerOnly",autofocus:[2,"autofocus","autofocus",L],variant:[1,"variant"],size:[1,"size"]},outputs:{onChange:"onChange",onFocus:"onFocus",onBlur:"onBlur"},features:[nt([Qt,Vt,{provide:At,useExisting:i},{provide:Et,useExisting:i}]),$([F]),Y],decls:1,vars:2,consts:[[4,"ngFor","ngForOf","ngForTrackBy"],[4,"ngIf"],["type","text","pInputText","",3,"input","focus","blur","paste","keydown","value","pSize","variant","invalid","pAutoFocus","pt"],[4,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(e,n){e&1&&E(0,Ut,3,2,"ng-container",0),e&2&&m("ngForOf",n.getRange(n.length))("ngForTrackBy",n.trackByFn)},dependencies:[ut,pt,lt,dt,kt,Mt,k,St],encapsulation:2,changeDetection:0})}return i})(),Nt=(()=>{class i{static \u0275fac=function(e){return new(e||i)};static \u0275mod=K({type:i});static \u0275inj=U({imports:[V,k,k]})}return i})();var Yt=["otpInput"],Dt=(i,a)=>({"rounded-end":i,"border-end-0":a});function $t(i,a){if(i&1){let t=h();o(0,"form",11),g("submit",function(){d(t);let n=r();return u(n.requestOtp(n.Email))}),o(1,"h1",12),c(2,"Forgot Password"),s(),o(3,"h6",13),c(4,"Enter the username or email address to reset password"),s(),o(5,"div",14)(6,"div",15)(7,"span"),M(8,"i",16),s()(),o(9,"input",17),v("ngModelChange",function(n){d(t);let p=r();return b(p.Email,n)||(p.Email=n),u(n)}),s()(),o(10,"div",18)(11,"button",19),c(12,"Reset Password"),s()(),o(13,"a",20),c(14,"Return to log in"),s()()}if(i&2){let t=r();l(9),y("ngModel",t.Email),l(2),m("disabled",!t.Email)}}function Gt(i,a){if(i&1){let t=h();o(0,"form",11),g("submit",function(){d(t);let n=r();return u(n.verifyOtp(n.otpEmail,n.otp))}),o(1,"h1",21),c(2,"OTP Code Verification"),s(),o(3,"h6",13),c(4,"Please enter the 6 digit code sent to "),o(5,"span",22),c(6),s()(),o(7,"div",23)(8,"p-inputOtp",24,0),v("ngModelChange",function(n){d(t);let p=r();return b(p.otp,n)||(p.otp=n),u(n)}),g("ngModelChange",function(){d(t);let n=r();return u(n.onInputOtp())}),s()(),o(10,"h6",25),c(11,"Didn't get a code? "),o(12,"span",26),g("click",function(){d(t);let n=r();return u(n.requestOtp(n.otpEmail))}),c(13,"Click to resend"),s()(),o(14,"div",18)(15,"button",19),c(16,"Verify"),s()()()}if(i&2){let t=r();l(6),tt(t.otpEmail),l(2),m("integerOnly",!0),y("ngModel",t.otp),m("autofocus",!0),l(7),m("disabled",!t.otp)}}function Zt(i,a){if(i&1){let t=h();o(0,"i",33),g("click",function(){d(t);let n=r(3);return u(n.showPassword())}),s()}if(i&2){let t=r(3);x(H("",t.showHideClass," fas"))}}function Jt(i,a){if(i&1&&(o(0,"span",30),f(1,Zt,1,3,"i",32),s()),i&2){let t=r(2);l(),_(t.password?1:-1)}}function Xt(i,a){if(i&1){let t=h();o(0,"i",33),g("click",function(){d(t);let n=r(3);return u(n.showPassword())}),s()}if(i&2){let t=r(3);x(H("",t.showHideClassConfirm," fas"))}}function te(i,a){if(i&1&&(o(0,"span",30),f(1,Xt,1,3,"i",32),s()),i&2){let t=r(2);l(),_(t.password?1:-1)}}function ee(i,a){if(i&1){let t=h();o(0,"form",11),g("submit",function(){d(t);let n=r();return u(n.changePassword(n.otpEmail,n.otp,n.password))}),o(1,"h1",21),c(2,"Create New Password"),s(),o(3,"h6",13),c(4,"Create a strong password to keep your account safe"),s(),o(5,"div",27)(6,"div",28)(7,"input",29),v("ngModelChange",function(n){d(t);let p=r();return b(p.password,n)||(p.password=n),u(n)}),s(),f(8,Jt,2,1,"span",30),s(),o(9,"div",28)(10,"input",31),v("ngModelChange",function(n){d(t);let p=r();return b(p.confirmPassword,n)||(p.confirmPassword=n),u(n)}),s(),f(11,te,2,1,"span",30),s()(),o(12,"div",18)(13,"button",19),c(14,"Change Password"),s()()()}if(i&2){let t=r();l(7),m("type",t.inputType)("ngClass",R(9,Dt,t.browserType=="edge",t.browserType!="edge")),y("ngModel",t.password),l(),_(t.browserType!="edge"?8:-1),l(2),m("type",t.inputConfirm)("ngClass",R(12,Dt,t.browserType=="edge",t.browserType!="edge")),y("ngModel",t.confirmPassword),l(),_(t.browserType!="edge"?11:-1),l(2),m("disabled",(!t.password||!t.confirmPassword)&&t.password!=t.confirmPassword)}}var Bt=class i{constructor(a){this.httpService=a;document.title="Outlet | Forgot Password Form",this.alert={Visible:!1,Message:null,Success:!1},this.showHideClass="fas fa-eye fas",this.showHideClassConfirm="fas fa-eye fas",this.browserType=this.findname_browser(),rt(()=>{let t=e=>{e.key==="Enter"&&(e.preventDefault(),this.verifyOtp(this.otpEmail,this.otp))};this.otpInputEl()?document.querySelector(".otp-input input:last-child").addEventListener("keyup",t):document.removeEventListener("keyup",t)})}otpInputEl=at("otpInput");appVersion=mt.version;showHideClass;showHideClassConfirm;inputType="password";inputConfirm="password";password;confirmPassword;browserType;Email;alert;toastr=w(gt);state="Email";otp="";otpEmail="";router=w(ct);findname_browser(){var a=window.navigator.userAgent;if(a.indexOf("Edg/")>-1)return"edge";var t={chrome:/chrome/i,safari:/safari/i,firefox:/firefox/i,ie:/internet explorer/i,edge:/edg/i};for(var e in t)if(t[e].test(a))return e;return"unknown"}ngOnInit(){document.body.classList.add("login-body")}ngOnDestroy(){document.body.classList.remove("login-body")}showPassword(){this.showHideClass=this.showHideClass=="fas fa-eye fas"?"fas fas fa-eye-slash":"fas fa-eye fas",this.inputType=this.showHideClass=="fas fa-eye fas"?"password":"text",this.showHideClassConfirm=this.showHideClassConfirm=="fas fa-eye fas"?"fas fas fa-eye-slash":"fas fa-eye fas",this.inputConfirm=this.showHideClassConfirm=="fas fa-eye fas"?"password":"text"}Submit(){let a={Email:this.Email};this.httpService.post("/api/login/SubmitForgotPassword",a).subscribe({next:t=>{this.alert.Visible=!0,this.alert.Success=!0,this.alert.Message=t.Message},error:t=>{this.alert.Visible=!0,this.alert.Message=t?.error?.Message?t?.error?.Message:t?.error}})}requestOtp(a){this.httpService.post("/api/password/requestotp",{email:a}).subscribe(t=>{this.toastr.info(`OTP sent to ${t.otpEmailTarget}`,P.Info),this.otpEmail=t.otpEmailTarget,this.state="OTP"})}onInputOtp(){this.otp.length==6&&this.verifyOtp(this.otpEmail,this.otp)}verifyOtp(a,t){this.httpService.post("/api/password/verifyotp",{email:a,otp:t}).subscribe(e=>{e.success?(this.toastr.info("You can update your password",P.Info),this.state="Password"):this.toastr.info("You input the wrong OTP",P.Error)})}changePassword(a,t,e){this.httpService.post("/api/password/change",{email:a,otp:t,newPassword:e}).subscribe(()=>{this.toastr.info("Your password has been changed",P.Info),this.router.navigate(["/"])})}static \u0275fac=function(t){return new(t||i)(Q(Pt))};static \u0275cmp=O({type:i,selectors:[["POS-auth-forgot-password"]],viewQuery:function(t,e){t&1&&J(e.otpInputEl,Yt,5),t&2&&X()},decls:15,vars:4,consts:[["otpInput",""],[1,"container-fluid"],[1,"d-flex","justify-content-center","align-items-center","vh-100"],[1,"card",2,"width","30rem"],[1,"card-body","p-12"],[1,"d-flex","copyright",2,"margin-left","20px"],[1,"align-self-center","me-5"],["target","_blank","href","http://www.dealpos.com"],[1,"version",2,"margin-right","18px"],["target","_blank","href","https://changelog.dealpos.com/?categories=cat_gAZdRhBYU7QVl&view=complete&v",1,"text-dark","fst-italic"],[1,"fa-solid","fa-circle-exclamation","ms-2",2,"font-size","16px"],[3,"submit"],[1,"mt-8","fw-normal",2,"margin-bottom","1.3rem"],[1,"fw-normal","text-start",2,"font-size","0.8rem"],[1,"input-group","input-group-lg","mb-3","my-5"],[1,"input-group-text","input-group-text","rounded-start"],[1,"fas","fa-user","fa-lg"],["type","text","data-cy","username","placeholder","Username / Email","aria-label","Username","name","email","aria-describedby","basic-addon1",1,"form-control","form-control-lg","rounded-end","ps-2","border-start-0",2,"height","50px",3,"ngModelChange","ngModel"],[1,"my-6"],["type","submit",1,"btn","btn-primary","w-100",3,"disabled"],["href","/",1,"mt-6"],[1,"mt-8","fw-normal",2,"margin-bottom","3rem"],[1,"fw-bold"],[1,"mb-3","my-5","d-flex","justify-content-center"],["length","6","name","otp",1,"otp-input",3,"ngModelChange","integerOnly","ngModel","autofocus"],[1,"fw-normal","text-start"],[1,"text-primary","pointer",3,"click"],[1,"mb-3","my-5"],[1,"input-group","input-group-lg","mt-8"],["id","txtPassword","data-cy","password","placeholder","New Password","aria-label","Password","aria-describedby","basic-addon1","autofocus","","name","password",1,"form-control","form-control-lg","rounded-end","ps-5",2,"height","50px",3,"ngModelChange","type","ngClass","ngModel"],[1,"input-group-text","border-start-0","rounded-end"],["id","txtPassword","data-cy","password","placeholder","Confirm New Password","aria-label","Password","aria-describedby","basic-addon1","autofocus","","name","password",1,"form-control","form-control-lg","rounded-end","ps-5",2,"height","50px",3,"ngModelChange","type","ngClass","ngModel"],[3,"class"],[3,"click"]],template:function(t,e){t&1&&(o(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4),f(4,$t,15,2,"form"),f(5,Gt,17,5,"form"),f(6,ee,15,15,"form"),s()()(),o(7,"div",5)(8,"span",6),c(9,"powered by :"),s(),M(10,"a",7),s(),o(11,"div",8)(12,"a",9),c(13),M(14,"i",10),s()()()),t&2&&(l(4),_(e.state=="Email"?4:-1),l(),_(e.state=="OTP"?5:-1),l(),_(e.state=="Password"?6:-1),l(7),et("version ",e.appVersion))},dependencies:[st,vt,yt,_t,ht,wt,bt,xt,Ct,Nt,V],styles:["input[type=submit][_ngcontent-%COMP%]{font-size:1.125rem;width:11.25rem;font-family:Roboto Slab,serif}@media screen and (max-width: 768px){.footer-mobile[_ngcontent-%COMP%]{display:flex!important;justify-content:center!important}div.vh-100[_ngcontent-%COMP%]{height:40vh!important}.fixed-bottom[_ngcontent-%COMP%]{position:static!important}input[type=submit][_ngcontent-%COMP%]{width:98%}.card[_ngcontent-%COMP%]{border:none}} p-inputOtp{width:100%} p-inputOtp input{flex-grow:1;height:42px}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}"]})};export{Bt as AuthForgotPasswordComponent};
22
+ `;var Rt=["input"],jt=(i,a,t)=>({$implicit:i,events:a,index:t});function Lt(i,a){if(i&1){let t=h();I(0),o(1,"input",2),g("input",function(n){d(t);let p=r().$implicit,C=r();return u(C.onInput(n,p-1))})("focus",function(n){d(t);let p=r(2);return u(p.onInputFocus(n))})("blur",function(n){d(t);let p=r(2);return u(p.onInputBlur(n))})("paste",function(n){d(t);let p=r(2);return u(p.onPaste(n))})("keydown",function(n){d(t);let p=r(2);return u(p.onKeyDown(n))}),s(),S()}if(i&2){let t=r().$implicit,e=r();l(),x(e.cn(e.cx("pcInputText"),e.styleClass)),m("value",e.getModelValue(t))("pSize",e.size())("variant",e.$variant())("invalid",e.invalid())("pAutoFocus",e.getAutofocus(t))("pt",e.ptm("pcInputText")),G("maxlength",t===1?e.length:1)("type",e.inputType)("name",e.name())("tabindex",e.tabindex)("required",e.required()?"":void 0)("readonly",e.readonly?"":void 0)("disabled",e.$disabled()?"":void 0)}}function Wt(i,a){i&1&&Z(0)}function zt(i,a){if(i&1&&(I(0),E(1,Wt,1,0,"ng-container",3),S()),i&2){let t=r().$implicit,e=r();l(),m("ngTemplateOutlet",e.inputTemplate||e._inputTemplate)("ngTemplateOutletContext",it(2,jt,e.getToken(t-1),e.getTemplateEvents(t-1),t))}}function Ut(i,a){if(i&1&&(I(0),E(1,Lt,2,15,"ng-container",1)(2,zt,2,6,"ng-container",1),S()),i&2){let t=r();l(),m("ngIf",!t.inputTemplate&&!t._inputTemplate),l(),m("ngIf",t.inputTemplate||t._inputTemplate)}}var qt={root:"p-inputotp p-component",pcInputText:"p-inputotp-input"},Vt=(()=>{class i extends Ot{name="inputotp";style=Ft;classes=qt;static \u0275fac=(()=>{let t;return function(n){return(t||(t=A(i)))(n||i)}})();static \u0275prov=z({token:i,factory:i.\u0275fac})}return i})();var At=new q("INPUTOTP_INSTANCE"),Qt={provide:ft,useExisting:W(()=>V),multi:!0},V=(()=>{class i extends It{_componentStyle=w(Vt);$pcInputOtp=w(At,{optional:!0,skipSelf:!0})??void 0;bindDirectiveInstance=w(F,{self:!0});onAfterViewChecked(){this.bindDirectiveInstance.setAttrs(this.ptms(["host","root"]))}readonly;tabindex=null;length=4;styleClass;mask=!1;integerOnly=!1;autofocus;variant=j();size=j();onChange=new T;onFocus=new T;onBlur=new T;inputTemplate;templates;_inputTemplate;tokens=[];value;$variant=ot(()=>this.variant()||this.config.inputStyle()||this.config.inputVariant());get inputMode(){return this.integerOnly?"numeric":"text"}get inputType(){return this.mask?"password":"text"}onAfterContentInit(){this.templates.forEach(t=>{switch(t.getType()){case"input":this._inputTemplate=t.template;break;default:this._inputTemplate=t.template;break}})}getToken(t){return this.tokens[t]}getTemplateEvents(t){return{input:e=>this.onInput(e,t),keydown:e=>this.onKeyDown(e),focus:e=>this.onFocus.emit(e),blur:e=>this.onBlur.emit(e),paste:e=>this.onPaste(e)}}onInput(t,e){let n=t.target.value;if(e===0&&n.length>1){this.handleOnPaste(n,t),t.stopPropagation();return}this.tokens[e]=n,this.updateModel(t),t.inputType==="deleteContentBackward"?this.moveToPrev(t):(t.inputType==="insertText"||t.inputType==="deleteContentForward")&&this.moveToNext(t)}updateModel(t){let e=this.tokens.join("");this.writeModelValue(e),this.onModelChange(e),this.onChange.emit({originalEvent:t,value:e})}updateTokens(){this.value!==null&&this.value!==void 0?Array.isArray(this.value)?this.tokens=[...this.value]:this.tokens=this.value.toString().split(""):this.tokens=[]}getModelValue(t){return this.tokens[t-1]||""}getAutofocus(t){return t===1&&this.autofocus||!1}moveToPrev(t){let e=this.findPrevInput(t.target);e&&(e.focus(),e.select())}moveToNext(t){let e=this.findNextInput(t.target);e&&(e.focus(),e.select())}findNextInput(t){let e=t.nextElementSibling;if(e)return e.nodeName==="INPUT"?e:this.findNextInput(e)}findPrevInput(t){let e=t.previousElementSibling;if(e)return e.nodeName==="INPUT"?e:this.findPrevInput(e)}onInputFocus(t){t.target.select(),this.onFocus.emit(t)}onInputBlur(t){this.onBlur.emit(t)}onKeyDown(t){if(!(t.altKey||t.ctrlKey||t.metaKey))switch(t.code){case"ArrowLeft":this.moveToPrev(t),t.preventDefault();break;case"ArrowUp":case"ArrowDown":t.preventDefault();break;case"Backspace":t.target.value.length===0&&(this.moveToPrev(t),t.preventDefault());break;case"ArrowRight":this.moveToNext(t),t.preventDefault();break;default:(this.integerOnly&&!(Number(t.key)>=0&&Number(t.key)<=9)||this.tokens.join("").length>=this.length&&t.code!=="Delete")&&t.preventDefault();break}}onPaste(t){if(!this.$disabled()&&!this.readonly){let e=t.clipboardData.getData("text");e.length&&this.handleOnPaste(e,t),t.preventDefault()}}handleOnPaste(t,e){let n=t.substring(0,this.length+1);(!this.integerOnly||!isNaN(n))&&(this.tokens=n.split(""),this.updateModel(e))}getRange(t){return Array.from({length:t},(e,n)=>n+1)}trackByFn(t){return t}writeControlValue(t,e){t?Array.isArray(t)&&t.length>0?this.value=t.slice(0,this.length):this.value=t.toString().split("").slice(0,this.length):this.value=t,e(this.value),this.updateTokens(),this.cd.markForCheck()}static \u0275fac=(()=>{let t;return function(n){return(t||(t=A(i)))(n||i)}})();static \u0275cmp=O({type:i,selectors:[["p-inputOtp"],["p-inputotp"],["p-input-otp"]],contentQueries:function(e,n,p){if(e&1&&(N(p,Rt,4),N(p,Tt,4)),e&2){let C;D(C=B())&&(n.inputTemplate=C.first),D(C=B())&&(n.templates=C)}},hostVars:2,hostBindings:function(e,n){e&2&&x(n.cx("root"))},inputs:{readonly:[2,"readonly","readonly",L],tabindex:"tabindex",length:"length",styleClass:"styleClass",mask:"mask",integerOnly:"integerOnly",autofocus:[2,"autofocus","autofocus",L],variant:[1,"variant"],size:[1,"size"]},outputs:{onChange:"onChange",onFocus:"onFocus",onBlur:"onBlur"},features:[nt([Qt,Vt,{provide:At,useExisting:i},{provide:Et,useExisting:i}]),$([F]),Y],decls:1,vars:2,consts:[[4,"ngFor","ngForOf","ngForTrackBy"],[4,"ngIf"],["type","text","pInputText","",3,"input","focus","blur","paste","keydown","value","pSize","variant","invalid","pAutoFocus","pt"],[4,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(e,n){e&1&&E(0,Ut,3,2,"ng-container",0),e&2&&m("ngForOf",n.getRange(n.length))("ngForTrackBy",n.trackByFn)},dependencies:[ut,pt,lt,dt,kt,Mt,k,St],encapsulation:2,changeDetection:0})}return i})(),Nt=(()=>{class i{static \u0275fac=function(e){return new(e||i)};static \u0275mod=K({type:i});static \u0275inj=U({imports:[V,k,k]})}return i})();var Yt=["otpInput"],Dt=(i,a)=>({"rounded-end":i,"border-end-0":a});function $t(i,a){if(i&1){let t=h();o(0,"form",11),g("submit",function(){d(t);let n=r();return u(n.requestOtp(n.Email))}),o(1,"h1",12),c(2,"Forgot Password"),s(),o(3,"h6",13),c(4,"Enter the username or email address to reset password"),s(),o(5,"div",14)(6,"div",15)(7,"span"),M(8,"i",16),s()(),o(9,"input",17),v("ngModelChange",function(n){d(t);let p=r();return b(p.Email,n)||(p.Email=n),u(n)}),s()(),o(10,"div",18)(11,"button",19),c(12,"Reset Password"),s()(),o(13,"a",20),c(14,"Return to log in"),s()()}if(i&2){let t=r();l(9),y("ngModel",t.Email),l(2),m("disabled",!t.Email)}}function Gt(i,a){if(i&1){let t=h();o(0,"form",11),g("submit",function(){d(t);let n=r();return u(n.verifyOtp(n.otpEmail,n.otp))}),o(1,"h1",21),c(2,"OTP Code Verification"),s(),o(3,"h6",13),c(4,"Please enter the 6 digit code sent to "),o(5,"span",22),c(6),s()(),o(7,"div",23)(8,"p-inputOtp",24,0),v("ngModelChange",function(n){d(t);let p=r();return b(p.otp,n)||(p.otp=n),u(n)}),g("ngModelChange",function(){d(t);let n=r();return u(n.onInputOtp())}),s()(),o(10,"h6",25),c(11,"Didn't get a code? "),o(12,"span",26),g("click",function(){d(t);let n=r();return u(n.requestOtp(n.otpEmail))}),c(13,"Click to resend"),s()(),o(14,"div",18)(15,"button",19),c(16,"Verify"),s()()()}if(i&2){let t=r();l(6),tt(t.otpEmail),l(2),m("integerOnly",!0),y("ngModel",t.otp),m("autofocus",!0),l(7),m("disabled",!t.otp)}}function Zt(i,a){if(i&1){let t=h();o(0,"i",33),g("click",function(){d(t);let n=r(3);return u(n.showPassword())}),s()}if(i&2){let t=r(3);x(H("",t.showHideClass," fas"))}}function Jt(i,a){if(i&1&&(o(0,"span",30),f(1,Zt,1,3,"i",32),s()),i&2){let t=r(2);l(),_(t.password?1:-1)}}function Xt(i,a){if(i&1){let t=h();o(0,"i",33),g("click",function(){d(t);let n=r(3);return u(n.showPassword())}),s()}if(i&2){let t=r(3);x(H("",t.showHideClassConfirm," fas"))}}function te(i,a){if(i&1&&(o(0,"span",30),f(1,Xt,1,3,"i",32),s()),i&2){let t=r(2);l(),_(t.password?1:-1)}}function ee(i,a){if(i&1){let t=h();o(0,"form",11),g("submit",function(){d(t);let n=r();return u(n.changePassword(n.otpEmail,n.otp,n.password))}),o(1,"h1",21),c(2,"Create New Password"),s(),o(3,"h6",13),c(4,"Create a strong password to keep your account safe"),s(),o(5,"div",27)(6,"div",28)(7,"input",29),v("ngModelChange",function(n){d(t);let p=r();return b(p.password,n)||(p.password=n),u(n)}),s(),f(8,Jt,2,1,"span",30),s(),o(9,"div",28)(10,"input",31),v("ngModelChange",function(n){d(t);let p=r();return b(p.confirmPassword,n)||(p.confirmPassword=n),u(n)}),s(),f(11,te,2,1,"span",30),s()(),o(12,"div",18)(13,"button",19),c(14,"Change Password"),s()()()}if(i&2){let t=r();l(7),m("type",t.inputType)("ngClass",R(9,Dt,t.browserType=="edge",t.browserType!="edge")),y("ngModel",t.password),l(),_(t.browserType!="edge"?8:-1),l(2),m("type",t.inputConfirm)("ngClass",R(12,Dt,t.browserType=="edge",t.browserType!="edge")),y("ngModel",t.confirmPassword),l(),_(t.browserType!="edge"?11:-1),l(2),m("disabled",(!t.password||!t.confirmPassword)&&t.password!=t.confirmPassword)}}var Bt=class i{constructor(a){this.httpService=a;document.title="Outlet | Forgot Password Form",this.alert={Visible:!1,Message:null,Success:!1},this.showHideClass="fas fa-eye fas",this.showHideClassConfirm="fas fa-eye fas",this.browserType=this.findname_browser(),rt(()=>{let t=e=>{e.key==="Enter"&&(e.preventDefault(),this.verifyOtp(this.otpEmail,this.otp))};this.otpInputEl()?document.querySelector(".otp-input input:last-child").addEventListener("keyup",t):document.removeEventListener("keyup",t)})}otpInputEl=at("otpInput");appVersion=mt.version;showHideClass;showHideClassConfirm;inputType="password";inputConfirm="password";password;confirmPassword;browserType;Email;alert;toastr=w(gt);state="Email";otp="";otpEmail="";router=w(ct);findname_browser(){var a=window.navigator.userAgent;if(a.indexOf("Edg/")>-1)return"edge";var t={chrome:/chrome/i,safari:/safari/i,firefox:/firefox/i,ie:/internet explorer/i,edge:/edg/i};for(var e in t)if(t[e].test(a))return e;return"unknown"}ngOnInit(){document.body.classList.add("login-body")}ngOnDestroy(){document.body.classList.remove("login-body")}showPassword(){this.showHideClass=this.showHideClass=="fas fa-eye fas"?"fas fas fa-eye-slash":"fas fa-eye fas",this.inputType=this.showHideClass=="fas fa-eye fas"?"password":"text",this.showHideClassConfirm=this.showHideClassConfirm=="fas fa-eye fas"?"fas fas fa-eye-slash":"fas fa-eye fas",this.inputConfirm=this.showHideClassConfirm=="fas fa-eye fas"?"password":"text"}Submit(){let a={Email:this.Email};this.httpService.post("/api/login/SubmitForgotPassword",a).subscribe({next:t=>{this.alert.Visible=!0,this.alert.Success=!0,this.alert.Message=t.Message},error:t=>{this.alert.Visible=!0,this.alert.Message=t?.error?.Message?t?.error?.Message:t?.error}})}requestOtp(a){this.httpService.post("/api/password/requestotp",{email:a}).subscribe(t=>{this.toastr.info(`OTP sent to ${t.otpEmailTarget}`,P.Info),this.otpEmail=t.otpEmailTarget,this.state="OTP"})}onInputOtp(){this.otp.length==6&&this.verifyOtp(this.otpEmail,this.otp)}verifyOtp(a,t){this.httpService.post("/api/password/verifyotp",{email:a,otp:t}).subscribe(e=>{e.success?(this.toastr.info("You can update your password",P.Info),this.state="Password"):this.toastr.info("You input the wrong OTP",P.Error)})}changePassword(a,t,e){this.httpService.post("/api/password/change",{email:a,otp:t,newPassword:e}).subscribe(()=>{this.toastr.info("Your password has been changed",P.Info),this.router.navigate(["/"])})}static \u0275fac=function(t){return new(t||i)(Q(Pt))};static \u0275cmp=O({type:i,selectors:[["POS-auth-forgot-password"]],viewQuery:function(t,e){t&1&&J(e.otpInputEl,Yt,5),t&2&&X()},decls:15,vars:4,consts:[["otpInput",""],[1,"container-fluid"],[1,"d-flex","justify-content-center","align-items-center","vh-100"],[1,"card",2,"width","30rem"],[1,"card-body","p-12"],[1,"d-flex","copyright",2,"margin-left","20px"],[1,"align-self-center","me-5"],["target","_blank","href","http://www.dealpos.com"],[1,"version",2,"margin-right","18px"],["target","_blank","href","https://changelog.dealpos.com/?categories=cat_gAZdRhBYU7QVl&view=complete&v",1,"text-dark","fst-italic"],[1,"fa-solid","fa-circle-exclamation","ms-2",2,"font-size","16px"],[3,"submit"],[1,"mt-8","fw-normal",2,"margin-bottom","1.3rem"],[1,"fw-normal","text-start",2,"font-size","0.8rem"],[1,"input-group","input-group-lg","mb-3","my-5"],[1,"input-group-text","input-group-text","rounded-start"],[1,"fas","fa-user","fa-lg"],["type","text","data-cy","username","placeholder","Username / Email","aria-label","Username","name","email","aria-describedby","basic-addon1",1,"form-control","form-control-lg","rounded-end","ps-2","border-start-0",2,"height","50px",3,"ngModelChange","ngModel"],[1,"my-6"],["type","submit",1,"btn","btn-primary","w-100",3,"disabled"],["href","/",1,"mt-6"],[1,"mt-8","fw-normal",2,"margin-bottom","3rem"],[1,"fw-bold"],[1,"mb-3","my-5","d-flex","justify-content-center"],["length","6","name","otp",1,"otp-input",3,"ngModelChange","integerOnly","ngModel","autofocus"],[1,"fw-normal","text-start"],[1,"text-primary","pointer",3,"click"],[1,"mb-3","my-5"],[1,"input-group","input-group-lg","mt-8"],["id","txtPassword","data-cy","password","placeholder","New Password","aria-label","Password","aria-describedby","basic-addon1","autofocus","","name","password",1,"form-control","form-control-lg","rounded-end","ps-5",2,"height","50px",3,"ngModelChange","type","ngClass","ngModel"],[1,"input-group-text","border-start-0","rounded-end"],["id","txtPassword","data-cy","password","placeholder","Confirm New Password","aria-label","Password","aria-describedby","basic-addon1","autofocus","","name","password",1,"form-control","form-control-lg","rounded-end","ps-5",2,"height","50px",3,"ngModelChange","type","ngClass","ngModel"],[3,"class"],[3,"click"]],template:function(t,e){t&1&&(o(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4),f(4,$t,15,2,"form"),f(5,Gt,17,5,"form"),f(6,ee,15,15,"form"),s()()(),o(7,"div",5)(8,"span",6),c(9,"powered by :"),s(),M(10,"a",7),s(),o(11,"div",8)(12,"a",9),c(13),M(14,"i",10),s()()()),t&2&&(l(4),_(e.state=="Email"?4:-1),l(),_(e.state=="OTP"?5:-1),l(),_(e.state=="Password"?6:-1),l(7),et("version ",e.appVersion))},dependencies:[st,vt,yt,_t,ht,wt,bt,xt,Ct,Nt,V],styles:["input[type=submit][_ngcontent-%COMP%]{font-size:1.125rem;width:11.25rem;font-family:Roboto Slab,serif}@media screen and (max-width: 768px){.footer-mobile[_ngcontent-%COMP%]{display:flex!important;justify-content:center!important}div.vh-100[_ngcontent-%COMP%]{height:40vh!important}.fixed-bottom[_ngcontent-%COMP%]{position:static!important}input[type=submit][_ngcontent-%COMP%]{width:98%}.card[_ngcontent-%COMP%]{border:none}} p-inputOtp{width:100%} p-inputOtp input{flex-grow:1;height:42px}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(https://cdn.dealpos.app/public/logo/dealpos_130.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}"]})};export{Bt as AuthForgotPasswordComponent};
@@ -1 +1 @@
1
- import{b as c}from"./chunk-U5KSGGL5.js";import{la as r,pa as s}from"./chunk-JYZTRN6N.js";var i=class{to;from;constructor(){this.to=new Date,this.from=new Date}};var n=class o{cookiesService=s(c);_cookiesName="PaymentDate";dateFilter={from:new Date,to:new Date};set(e){this.saveFilterToCookie(e),this.dateFilter=e}initFilterDate(e){let t;if(this.checkCookieExists())t=this.get();else{let a=e.From||new Date,m=e.To||new Date;t={from:a,to:m}}return e.From=t.from,e.To=t.to,e}get(){return this.checkCookieExists()?this.dateFilter=JSON.parse(this.cookiesService.get(this._cookiesName)):this.dateFilter=new i,this.dateFilter}checkCookieExists(){return this.cookiesService.check(this._cookiesName)}saveFilterToCookie(e){this.cookiesService.set(this._cookiesName,JSON.stringify(e),this.getExpiredDate(),"/")}clear(){this.cookiesService.delete(this._cookiesName,"/"),this.dateFilter=new i}getExpiredDate(){let e=new Date,a=1*60*60*1e3;return e.setTime(e.getTime()+a),e}static \u0275fac=function(t){return new(t||o)};static \u0275prov=r({token:o,factory:o.\u0275fac,providedIn:"root"})};export{n as a};
1
+ import{b as c}from"./chunk-H4DUHWPT.js";import{la as r,pa as s}from"./chunk-JYZTRN6N.js";var i=class{to;from;constructor(){this.to=new Date,this.from=new Date}};var n=class o{cookiesService=s(c);_cookiesName="PaymentDate";dateFilter={from:new Date,to:new Date};set(e){this.saveFilterToCookie(e),this.dateFilter=e}initFilterDate(e){let t;if(this.checkCookieExists())t=this.get();else{let a=e.From||new Date,m=e.To||new Date;t={from:a,to:m}}return e.From=t.from,e.To=t.to,e}get(){return this.checkCookieExists()?this.dateFilter=JSON.parse(this.cookiesService.get(this._cookiesName)):this.dateFilter=new i,this.dateFilter}checkCookieExists(){return this.cookiesService.check(this._cookiesName)}saveFilterToCookie(e){this.cookiesService.set(this._cookiesName,JSON.stringify(e),this.getExpiredDate(),"/")}clear(){this.cookiesService.delete(this._cookiesName,"/"),this.dateFilter=new i}getExpiredDate(){let e=new Date,a=1*60*60*1e3;return e.setTime(e.getTime()+a),e}static \u0275fac=function(t){return new(t||o)};static \u0275prov=r({token:o,factory:o.\u0275fac,providedIn:"root"})};export{n as a};