@saasquatch/mint-components 1.11.1-65 → 1.11.1-67

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 (117) hide show
  1. package/dist/cjs/sqm-asset-card.cjs.entry.js +1 -1
  2. package/dist/cjs/sqm-banking-info-form_16.cjs.entry.js +1 -1
  3. package/dist/cjs/sqm-big-stat_38.cjs.entry.js +2 -2
  4. package/dist/cjs/sqm-instant-access-registration.cjs.entry.js +1 -1
  5. package/dist/cjs/sqm-logout-current-user.cjs.entry.js +1 -1
  6. package/dist/cjs/sqm-navigation-sidebar-item.cjs.entry.js +1 -1
  7. package/dist/cjs/sqm-pagination_3.cjs.entry.js +3 -1
  8. package/dist/cjs/sqm-password-field.cjs.entry.js +1 -1
  9. package/dist/cjs/sqm-portal-email-verification.cjs.entry.js +1 -1
  10. package/dist/cjs/sqm-portal-forgot-password.cjs.entry.js +1 -1
  11. package/dist/cjs/sqm-portal-profile.cjs.entry.js +1 -1
  12. package/dist/cjs/sqm-portal-registration-form.cjs.entry.js +1 -1
  13. package/dist/cjs/sqm-portal-reset-password.cjs.entry.js +1 -1
  14. package/dist/cjs/sqm-portal-verify-email.cjs.entry.js +1 -1
  15. package/dist/cjs/sqm-referral-table_11.cjs.entry.js +1 -1
  16. package/dist/cjs/sqm-referred-registration.cjs.entry.js +1 -1
  17. package/dist/cjs/sqm-rewards-table_9.cjs.entry.js +1 -1
  18. package/dist/cjs/sqm-stencilbook.cjs.entry.js +2 -2
  19. package/dist/collection/collection-manifest.json +2 -2
  20. package/dist/collection/components/sqm-pagination/sqm-pagination-view.js +2 -0
  21. package/dist/collection/components/sqm-pagination/sqm-pagination.js +10 -6
  22. package/dist/collection/components/sqm-referral-codes/sqm-referral-codes.js +2 -2
  23. package/dist/esm/sqm-asset-card.entry.js +1 -1
  24. package/dist/esm/sqm-banking-info-form_16.entry.js +1 -1
  25. package/dist/esm/sqm-big-stat_38.entry.js +2 -2
  26. package/dist/esm/sqm-instant-access-registration.entry.js +1 -1
  27. package/dist/esm/sqm-logout-current-user.entry.js +1 -1
  28. package/dist/esm/sqm-navigation-sidebar-item.entry.js +1 -1
  29. package/dist/esm/sqm-pagination_3.entry.js +3 -1
  30. package/dist/esm/sqm-password-field.entry.js +1 -1
  31. package/dist/esm/sqm-portal-email-verification.entry.js +1 -1
  32. package/dist/esm/sqm-portal-forgot-password.entry.js +1 -1
  33. package/dist/esm/sqm-portal-profile.entry.js +1 -1
  34. package/dist/esm/sqm-portal-registration-form.entry.js +1 -1
  35. package/dist/esm/sqm-portal-reset-password.entry.js +1 -1
  36. package/dist/esm/sqm-portal-verify-email.entry.js +1 -1
  37. package/dist/esm/sqm-referral-table_11.entry.js +1 -1
  38. package/dist/esm/sqm-referred-registration.entry.js +1 -1
  39. package/dist/esm/sqm-rewards-table_9.entry.js +1 -1
  40. package/dist/esm/sqm-stencilbook.entry.js +2 -2
  41. package/dist/esm-es5/{ShadowViewAddon-bc74643a.js → ShadowViewAddon-1c2c3383.js} +1 -1
  42. package/dist/esm-es5/sqm-asset-card.entry.js +1 -1
  43. package/dist/esm-es5/sqm-banking-info-form_16.entry.js +1 -1
  44. package/dist/esm-es5/sqm-big-stat_38.entry.js +1 -1
  45. package/dist/esm-es5/sqm-instant-access-registration.entry.js +1 -1
  46. package/dist/esm-es5/sqm-logout-current-user.entry.js +1 -1
  47. package/dist/esm-es5/sqm-navigation-sidebar-item.entry.js +1 -1
  48. package/dist/esm-es5/sqm-pagination_3.entry.js +1 -1
  49. package/dist/esm-es5/sqm-password-field.entry.js +1 -1
  50. package/dist/esm-es5/sqm-portal-email-verification.entry.js +1 -1
  51. package/dist/esm-es5/sqm-portal-forgot-password.entry.js +1 -1
  52. package/dist/esm-es5/sqm-portal-profile.entry.js +1 -1
  53. package/dist/esm-es5/sqm-portal-registration-form.entry.js +1 -1
  54. package/dist/esm-es5/sqm-portal-reset-password.entry.js +1 -1
  55. package/dist/esm-es5/sqm-portal-verify-email.entry.js +1 -1
  56. package/dist/esm-es5/sqm-referral-table_11.entry.js +1 -1
  57. package/dist/esm-es5/sqm-referred-registration.entry.js +1 -1
  58. package/dist/esm-es5/sqm-rewards-table_9.entry.js +1 -1
  59. package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
  60. package/dist/mint-components/mint-components.esm.js +1 -1
  61. package/dist/mint-components/{p-2d688fe9.entry.js → p-00105748.entry.js} +2 -2
  62. package/dist/mint-components/{p-f9680769.system.entry.js → p-1e1c87a2.system.entry.js} +1 -1
  63. package/dist/mint-components/{p-5dcd7fc9.system.entry.js → p-1e8bafbc.system.entry.js} +1 -1
  64. package/dist/mint-components/{p-5073b8c9.entry.js → p-23bc62d8.entry.js} +6 -6
  65. package/dist/mint-components/{p-4c1b1914.system.entry.js → p-25720e4b.system.entry.js} +1 -1
  66. package/dist/mint-components/p-367b6513.entry.js +1 -0
  67. package/dist/mint-components/{p-6dab9a17.entry.js → p-3c62ed18.entry.js} +2 -2
  68. package/dist/mint-components/{p-3973cf23.system.entry.js → p-46aaa8b9.system.entry.js} +1 -1
  69. package/dist/mint-components/{p-119e24fd.system.entry.js → p-4b5ff38d.system.entry.js} +1 -1
  70. package/dist/mint-components/{p-51dba12d.system.entry.js → p-566dc091.system.entry.js} +1 -1
  71. package/dist/mint-components/{p-c134af86.system.entry.js → p-607b75ef.system.entry.js} +1 -1
  72. package/dist/mint-components/{p-ffdb1310.entry.js → p-63f2aad0.entry.js} +1 -1
  73. package/dist/mint-components/{p-1c45b7d0.entry.js → p-6dadd556.entry.js} +1 -1
  74. package/dist/mint-components/{p-c3b8765c.system.entry.js → p-707884d9.system.entry.js} +1 -1
  75. package/dist/mint-components/{p-c3188365.system.entry.js → p-7d8b3d62.system.entry.js} +1 -1
  76. package/dist/mint-components/{p-752fd47b.entry.js → p-8b97c4f8.entry.js} +1 -1
  77. package/dist/mint-components/{p-e92f0fbb.entry.js → p-8c1e39ea.entry.js} +1 -1
  78. package/dist/mint-components/{p-34a6dea7.system.entry.js → p-8d9ff497.system.entry.js} +1 -1
  79. package/dist/mint-components/{p-f5c3a8cf.system.entry.js → p-902a70fb.system.entry.js} +1 -1
  80. package/dist/mint-components/{p-26383fdd.entry.js → p-9114b10e.entry.js} +1 -1
  81. package/dist/mint-components/{p-87113437.entry.js → p-9a4a5702.entry.js} +2 -2
  82. package/dist/mint-components/p-9ed09b3a.system.js +1 -1
  83. package/dist/mint-components/{p-bd1975cb.system.entry.js → p-a17fe959.system.entry.js} +1 -1
  84. package/dist/mint-components/{p-4be053fb.entry.js → p-a1c4b92d.entry.js} +2 -2
  85. package/dist/mint-components/{p-7d7084f0.entry.js → p-a2e71bdf.entry.js} +9 -9
  86. package/dist/mint-components/{p-9041bce0.entry.js → p-a91c4564.entry.js} +2 -2
  87. package/dist/mint-components/{p-c65f5d44.js → p-b2718cfe.js} +4 -4
  88. package/dist/mint-components/{p-cc1ffc0c.entry.js → p-b6a7b4cf.entry.js} +1 -1
  89. package/dist/mint-components/{p-bab29c11.entry.js → p-b8b7632b.entry.js} +1 -1
  90. package/dist/mint-components/{p-7f43c280.system.entry.js → p-ba734685.system.entry.js} +1 -1
  91. package/dist/mint-components/{p-9a1a4d71.system.entry.js → p-c721e692.system.entry.js} +1 -1
  92. package/dist/mint-components/{p-ca182259.system.entry.js → p-cd2f57bb.system.entry.js} +1 -1
  93. package/dist/mint-components/p-cdbc9b2b.system.entry.js +1 -0
  94. package/dist/mint-components/p-dbf3a976.entry.js +1 -0
  95. package/dist/mint-components/p-e029c250.entry.js +1 -0
  96. package/dist/mint-components/{p-25ebf256.system.js → p-e7f5d3b2.system.js} +1 -1
  97. package/dist/mint-components/{p-e909906f.entry.js → p-ecad6d86.entry.js} +1 -1
  98. package/dist/mint-components/{p-e3411b86.system.entry.js → p-f3978cec.system.entry.js} +1 -1
  99. package/dist/mint-components/{p-f246f7dd.system.entry.js → p-fe516032.system.entry.js} +1 -1
  100. package/dist/types/components/sqm-pagination/sqm-pagination.d.ts +2 -2
  101. package/dist/types/components/sqm-pagination/usePagination.d.ts +1 -0
  102. package/dist/types/components/sqm-referral-codes/sqm-referral-codes.d.ts +2 -2
  103. package/dist/types/components.d.ts +3 -2
  104. package/dist/types/global/android.d.ts +7 -0
  105. package/dist/types/global/demo.d.ts +2 -0
  106. package/dist/types/stories/features.d.ts +4 -0
  107. package/dist/types/stories/templates.d.ts +4 -0
  108. package/docs/docs.docx +0 -0
  109. package/docs/raisins.json +1 -1
  110. package/grapesjs/grapesjs.js +1 -1
  111. package/package.json +1 -1
  112. package/dist/mint-components/p-2474c5c6.entry.js +0 -1
  113. package/dist/mint-components/p-61e74000.system.entry.js +0 -1
  114. package/dist/mint-components/p-62cdc746.entry.js +0 -1
  115. package/dist/mint-components/p-8925f3c5.entry.js +0 -1
  116. package/dist/cjs/{ShadowViewAddon-d714d857.js → ShadowViewAddon-d17dd153.js} +1 -1
  117. package/dist/esm/{ShadowViewAddon-bc74643a.js → ShadowViewAddon-1c2c3383.js} +1 -1
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@saasquatch/mint-components",
3
3
  "title": "Mint Components",
4
- "version": "1.11.1-65",
4
+ "version": "1.11.1-67",
5
5
  "description": "A minimal design library with components for referral and loyalty experiences. Built with Shoelace components by Saasquatch.",
6
6
  "icon": "https://res.cloudinary.com/saasquatch/image/upload/v1652219900/squatch-assets/For_Mint.svg",
7
7
  "raisins": "docs/raisins.json",
@@ -1 +0,0 @@
1
- import{r as e,h as i}from"./p-61d5f26e.js";import{k as o,f as a,n as t}from"./p-019506c4.js";import{Q as s,o as r,f as n,c as l,i as d}from"./p-8c765c81.js";import{s as c,g as v}from"./p-9ec99ced.js";import"./p-cef45012.js";import{c as u}from"./p-c1086930.js";import"./p-02be1a88.js";import"./p-ee343d0b.js";import{P as f}from"./p-b7705066.js";let m=null;const p=class{constructor(i){e(this,i),this.ignored=!0,this.nextPage="/",this.failedPage="/",this.verifyEmailText="Verify your email",this.verifySuccessText="Your email has been verified and you are being redirected. If you are not redirected, please click Continue.",this.verifyInvalidText="The email verification code is invalid or has expired, please try again.",this.continueText="Continue",this.networkErrorMessage="An error occurred while verifying your email. Please refresh the page and try again.",t(this)}disconnectedCallback(){}render(){const{states:e,data:t,callbacks:p,content:h}=d()?(y=v(this),u({states:{error:"",loading:!1,success:!0},data:{oobCode:"code"},callbacks:{failed:()=>{console.log("failed")},gotoNextPage:()=>{}},content:{verifySuccessText:y.verifySuccessText,verifyEmailText:y.verifyEmailText,verifyInvalidText:y.verifyInvalidText,continueText:y.continueText}},y.demoData||{},{arrayMerge:(e,i)=>i})):function({nextPage:e,failedPage:i,verifySuccessText:t,verifyEmailText:d,verifyInvalidText:v,networkErrorMessage:u,continueText:f}){var p,h,y,g,x,b,T,j,P,k;const[C,E]=o(!1),[w,I]=o(!1),S=s(),[_,{loading:M,data:N,errors:q}]=r(),A=new URLSearchParams(n.location.search),L=A.get("oobCode"),R=A.get("email"),U=A.get("nextPage"),V=void 0===N&&void 0===q&&!!L,Y=!!((null===(p=null==S?void 0:S.managedIdentity)||void 0===p?void 0:p.emailVerified)||(null===(h=null==N?void 0:N.verifyManagedIdentityEmail)||void 0===h?void 0:h.success)||w),z=(null===(y=null==S?void 0:S.managedIdentity)||void 0===y?void 0:y.email)===R,B=()=>{A.delete("nextPage");const i=c(U||e);n.push(i.href)};return a((()=>{(async()=>{m||(m=_({oobCode:L}));const e=await m;e instanceof Error||!e.verifyManagedIdentityEmail.success||I(!0),E(!0)})()}),[]),a((()=>{C&&(Y&&z?setTimeout(B,3e3):setTimeout((()=>{l(void 0),B()}),3e3))}),[C,Y]),{states:{loading:M||!C,disableContinue:V,error:(null===(T=null===(b=null===(x=null===(g=null==q?void 0:q.response)||void 0===g?void 0:g.errors)||void 0===x?void 0:x[0])||void 0===b?void 0:b.extensions)||void 0===T?void 0:T.message)||(null===(k=null===(P=null===(j=null==q?void 0:q.response)||void 0===j?void 0:j.errors)||void 0===P?void 0:P[0])||void 0===k?void 0:k.message)||((null==q?void 0:q.message)||!z)&&u,success:C&&(Y||z)},data:{oobCode:L},callbacks:{failed:()=>n.push({pathname:i,search:A.toString()&&"?"+A.toString()}),gotoNextPage:B},content:{verifySuccessText:t,verifyEmailText:d,verifyInvalidText:v,continueText:f}}}(v(this));var y;return i(f,{states:e,data:t,callbacks:p,content:h})}};export{p as sqm_portal_verify_email}
@@ -1 +0,0 @@
1
- var __makeTemplateObject=this&&this.__makeTemplateObject||function(t,e){if(Object.defineProperty){Object.defineProperty(t,"raw",{value:e})}else{t.raw=e}return t};var __assign=this&&this.__assign||function(){__assign=Object.assign||function(t){for(var e,n=1,a=arguments.length;n<a;n++){e=arguments[n];for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r))t[r]=e[r]}return t};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(t,e,n,a){function r(t){return t instanceof n?t:new n((function(e){e(t)}))}return new(n||(n=Promise))((function(n,i){function o(t){try{l(a.next(t))}catch(t){i(t)}}function s(t){try{l(a["throw"](t))}catch(t){i(t)}}function l(t){t.done?n(t.value):r(t.value).then(o,s)}l((a=a.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var n={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},a,r,i,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(t){return function(e){return l([t,e])}}function l(o){if(a)throw new TypeError("Generator is already executing.");while(n)try{if(a=1,r&&(i=o[0]&2?r["return"]:o[0]?r["throw"]||((i=r["return"])&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;if(r=0,i)o=[o[0]&2,i.value];switch(o[0]){case 0:case 1:i=o;break;case 4:n.label++;return{value:o[1],done:false};case 5:n.label++;r=o[1];o=[0];continue;case 7:o=n.ops.pop();n.trys.pop();continue;default:if(!(i=n.trys,i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){n=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){n.label=o[1];break}if(o[0]===6&&n.label<i[1]){n.label=i[1];i=o;break}if(i&&n.label<i[2]){n.label=i[2];n.ops.push(o);break}if(i[2])n.ops.pop();n.trys.pop();continue}o=e.call(t,n)}catch(t){o=[6,t];r=0}finally{a=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};System.register(["./p-21d94eab.system.js","./p-45d71b2a.system.js","./p-f6c279d8.system.js","./p-1e68fa26.system.js","./p-6333265f.system.js","./p-1a673057.system.js","./p-099b57de.system.js","./p-4bd679a7.system.js","./p-f6934a55.system.js"],(function(t){"use strict";var e,n,a,r,i,o,s,l,c,u,d,f,p,v,g,h,m,y,x,b,C,T;return{setters:[function(t){e=t.h;n=t.F;a=t.r},function(t){r=t.n;i=t.k},function(t){o=t.i},function(t){s=t.I;l=t.i;c=t.d;u=t.H;d=t.Q;f=t.y;p=t.$;v=t.B},function(t){g=t.g},function(t){h=t.c},function(t){m=t.R;y=t.a;x=t.S;b=t.C;C=t.u},function(t){T=t.c},function(){}],execute:function(){var _={Container:{display:"flex",justifyContent:"flex-end",alignItems:"center",gap:"var(--sl-spacing-small)",width:"100%"},TextContainer:{display:"flex",gap:"var(--sl-spacing-xx-small)"}};var w=h(_);var P=w.toString();function S(t){var a=t.states,r=t.callbacks,i=t.text;var o=r.onNext,s=r.onPrev;var l=a.currentPage,c=a.totalPages,u=a.loading;return e("span",{class:w.classes.Container,part:"sqm-base"},e("style",{type:"text/css"},P),!u&&e(n,null,e("sl-button",{onClick:s,part:"sqm-pagination-button",circle:true,disabled:l===1},e("sl-icon",{name:"chevron-left",label:"Previous Page"})),e("div",{class:w.classes.TextContainer},i.paginationText)),e("sl-button",{onClick:o,part:"sqm-pagination-button",circle:true,disabled:l===c},e("sl-icon",{name:"chevron-right",label:"Previous Page"})))}function j(t){var e;var n=s(m);var a=n.states.currentPage+1;var r=(e=n.states)===null||e===void 0?void 0:e.pageCount;return{states:{currentPage:a,totalPages:r,loading:n.states.loading},callbacks:{onNext:function(){var t,e;return(t=n.callbacks)===null||t===void 0?void 0:t.setCurrentPage(((e=n.states)===null||e===void 0?void 0:e.currentPage)+1)},onPrev:function(){var t,e;return(t=n.callbacks)===null||t===void 0?void 0:t.setCurrentPage(((e=n.states)===null||e===void 0?void 0:e.currentPage)-1)}},text:{paginationText:o.formatMessage({id:"paginationText",defaultMessage:t.paginationText},{currentPage:a,totalPages:r})}}}var k=t("sqm_pagination",function(){function t(t){a(this,t);this.ignored=true;this.paginationText="{currentPage} of {totalPages}";r(this)}t.prototype.disconnectedCallback=function(){};t.prototype.render=function(){var t=l()?I(g(this)):j(g(this));return e(S,Object.assign({},t))};return t}());function I(t){var e=i(1),n=e[0],a=e[1];return T({states:{currentPage:n,totalPages:5,loading:false},callbacks:{onNext:function(){return a(n+1)},onPrev:function(){return a(n-1)}},text:{paginationText:o.formatMessage({id:"paginationText",defaultMessage:t.paginationText||"{currentPage} of {totalPages}"},{currentPage:n,totalPages:5})}},t.demoData||{},{arrayMerge:function(t,e){return e}})}var E=c.gql(__makeTemplateObject(["\n query getReferralCode($programId: ID) {\n user: viewer {\n ... on User {\n referralCode(programId: $programId)\n }\n }\n }\n"],["\n query getReferralCode($programId: ID) {\n user: viewer {\n ... on User {\n referralCode(programId: $programId)\n }\n }\n }\n"]));var M=c.gql(__makeTemplateObject(["\n mutation loadEvent($eventMeta: UserAnalyticsEvent!) {\n createUserAnalyticsEvent(eventMeta: $eventMeta)\n }\n"],["\n mutation loadEvent($eventMeta: UserAnalyticsEvent!) {\n createUserAnalyticsEvent(eventMeta: $eventMeta)\n }\n"]));function q(t){var e,n;var a=t.programId,r=a===void 0?u():a;var o=d();var l=v();var c=s(y);var g=f(E,{programId:r},!(o===null||o===void 0?void 0:o.jwt)||(c===null||c===void 0?void 0:c.referralCode)!==undefined).data;var h=p(M)[0];var m=p(x)[0];var b=(n=(c===null||c===void 0?void 0:c.referralCode)||((e=g===null||g===void 0?void 0:g.user)===null||e===void 0?void 0:e.referralCode))!==null&&n!==void 0?n:"...";var C=i(false),T=C[0],_=C[1];function w(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:if(!c)return[3,2];return[4,m({referralCode:c.referralCode})];case 1:e.sent();c.refresh();e.label=2;case 2:navigator.clipboard.writeText(b);_(true);setTimeout((function(){return _(false)}),t.tooltiplifespan);h({eventMeta:{programId:r,id:o===null||o===void 0?void 0:o.id,accountId:o===null||o===void 0?void 0:o.accountId,type:"USER_REFERRAL_PROGRAM_ENGAGEMENT_EVENT",meta:{engagementMedium:l,shareMedium:"DIRECT"}}});return[2]}}))}))}return __assign(__assign({},t),{onClick:w,open:T,copyString:b,isCopied:c===null||c===void 0?void 0:c.isCopied})}var A=t("sqm_referral_code",function(){function t(t){a(this,t);this.tooltiptext="Copied to Clipboard";this.showNotificationText=false;this.notificationText="You've copied this code before";this.tooltiplifespan=1e3;this.textAlign="left";this.copyButtonLabel="Copy Code";this.buttonStyle="icon";r(this)}t.prototype.disconnectedCallback=function(){};t.prototype.render=function(){var t=g(this);var n=l()?O(t):q(t);return e(b,Object.assign({},n))};return t}());function O(t){var e=i(false),n=e[0],a=e[1];var r="REFERRALCODE001";return T({copyString:r,tooltiptext:t.tooltiptext,textAlign:t.textAlign,copyButtonLabel:t.copyButtonLabel,buttonStyle:t.buttonStyle,notificationText:t.notificationText,showNotificationText:t.showNotificationText,isCopied:t.showNotificationText,isUsed:false,rewardStatus:"AVAILABLE",open:n,onClick:function(){navigator.clipboard.writeText(r);a(true);setTimeout((function(){return a(false)}),t.tooltiplifespan)}},t.demoData||{},{arrayMerge:function(t,e){return e}})}var R={Wrapper:{width:"100%",display:"flex",alignItems:"flex-start",justifyContent:"center",flexDirection:"column",gap:"var(--sl-spacing-large)"},HeaderContainer:{display:"flex",alignItems:"center",justifyContent:"space-between",width:"100%"},ShareCodeContainer:{width:"100%",display:"flex",alignItems:"flex-start",justifyContent:"center",flexDirection:"column"},ShareButtonContainer:{width:"100%",display:"flex",alignItems:"flex-start",justifyContent:"center",flexDirection:"column"},TitleText:{color:"var(--sl-color-neutral-700)",fontSize:"var(--sl-font-size-large)",margin:"0"}};var D="\n:host {\n display: block;\n}\n:host([hidden]): {\n display: none;\n}\n";var U=h(R);var B=U.toString();function N(t){var n=t.slots,a=t.titleText,r=t.states;var i=function(t){if(t.noCodes){return n.empty}if(t.loading){return n.loading}return e("div",{class:U.classes.Wrapper},e("div",{class:U.classes.ShareCodeContainer},n.shareCodes),e("div",{class:U.classes.ShareButtonContainer},n.shareButtons))};return e("div",{class:U.classes.Wrapper,part:"sqm-base"},e("style",{type:"text/css"},D,B),e("div",{class:U.classes.HeaderContainer},e("h2",{class:U.classes.TitleText},a),!r.noCodes&&!r.loading&&n.pagination),i(r))}var $=t("sqm_referral_codes",function(){function t(t){a(this,t);this.titleText="Start sharing";this.emptyStateHeaderText="Your new codes and links aren’t ready yet";this.emptyStateDescriptionText="Please contact our program support team to let them know you’re out of codes.";this.emptyStateImageUrl="https://res.cloudinary.com/saasquatch/image/upload/v1644360953/squatch-assets/empty_leaderboard2.png";r(this)}t.prototype.disconnectedCallback=function(){};t.prototype.render=function(){var t=g(this);var n=l()?F(t):C(t);var a={shareButtons:e("slot",{name:"shareButtons"}),shareCodes:e("slot",{name:"shareCodes"}),pagination:e("slot",{name:"pagination"}),empty:e(L,{headerText:this.emptyStateHeaderText,descriptionText:this.emptyStateDescriptionText,imageUrl:this.emptyStateImageUrl}),loading:e(H,null)};var r=__assign(__assign({slots:a},n),{loading:n.states.loading,noCodes:n.states.noCodes});return e(N,Object.assign({},r))};return t}());function L(t){var n=t.headerText,a=t.descriptionText,r=t.imageUrl;return e("slot",{name:"empty"},e("sqm-empty",{emptyStateHeader:n,emptyStateText:a,emptyStateImage:r}))}function H(){return e("slot",{name:"loading"},e(G,null),e(G,null),e(G,null),e(G,null))}function G(){return e("sl-skeleton",{style:{width:"100%"}})}function F(t){return T({titleText:t.titleText,states:{noCodes:false,loading:false}},t.demoData||{},{arrayMerge:function(t,e){return e}})}}}}));
@@ -1 +0,0 @@
1
- import{r as e,h as t,g as a,c as s}from"./p-61d5f26e.js";import{n as l,j as r,u as i,f as n}from"./p-019506c4.js";import{i as d}from"./p-66c7b15c.js";import{i as o}from"./p-8c765c81.js";import{l as u}from"./p-9ec99ced.js";import{c}from"./p-cef45012.js";import{c as E}from"./p-c1086930.js";import"./p-02be1a88.js";import{G as p}from"./p-a9ff5495.js";import{a as h,u as v}from"./p-134424df.js";import{u as N}from"./p-0ebd104c.js";import{l as m}from"./p-1a4e5a3a.js";import{g as P}from"./p-7ae55645.js";import{u as I,t as _}from"./p-195e306e.js";import{T as D}from"./p-ee343d0b.js";const A=[["AVAILABLE"],["PENDING"],["CANCELLED"],["EXPIRED"],["REDEEMED"]],f=["Rajesh","Pierre","Ji-Ho","Chinua","Charleston","Sally","Gael","Jill","Jane","Khadija"],y=["Smith","Parker","Kent","Chew","Stark","Banner","Jones","Odinson","Pym","Rogers"],R=class{constructor(t){e(this,t),this.perPage=4,this.hideLabels=!1,this.prevLabel="Prev",this.moreLabel="Next",this.showReferrer=!1,this.hiddenColumns="0",this.smBreakpoint=599,this.mdBreakpoint=799,l(this)}disconnectedCallback(){}render(){const e=t(g,null),a=t(T,null),{states:s,data:l,callbacks:d,elements:u}=o()?function(e,t,a){const[s,l]=r(((e,t)=>({...e,...t})),{columns:[],rows:[],loading:!1,page:0}),d=v(),o=i((()=>{var t;return(null===(t=e.demoData)||void 0===t?void 0:t.mockData)||((e=4)=>({totalCount:6,count:e,referredByReferral:{dateConverted:null,dateReferralStarted:1643912659850,referrerUser:{firstName:"John",lastName:"Snow",rewards:[]}},data:[...Array(e)].map((()=>({id:"5cae6b0fcc540e209db45b53",referredUser:{id:"5cae6b0ce4b0d81c67b78e82",accountId:"SPX1MZBIPTFL3E1H",firstName:f[Math.floor(Math.random()*f.length)],lastName:y[Math.floor(Math.random()*y.length)],email:"example.uexwltgh@mailosaur.io",programGoals:[]},shareLinkUsed:null,referralCodeUsed:"JIMBONEUTRON2",moderationStatus:"PENDING",dateConverted:Math.floor(10*Math.random())>=5?m.DateTime.now().minus({days:6}).toMillis():null,dateFraudChecksCompleted:null,dateModerated:1558730033306,dateModified:1554934543447,dateReferralEnded:null,dateReferralPaid:null,dateReferralStarted:m.DateTime.now().minus({days:8}).toMillis(),dateUserModified:null,programId:"sam-partner-test-2",program:{id:"sam-partner-test-2",name:"Partner Program 2.0"},rewards:Math.floor(10*Math.random())>=5?[{id:"5cae6b16cc540e209db45cfa",type:"CREDIT",value:1,unit:"POINT",name:"Partner Reward",dateGiven:1554934550726,dateExpires:null,dateCancelled:null,dateRedeemed:1637004373582,dateScheduledFor:null,fuelTankCode:null,fuelTankType:null,currency:null,prettyValue:"1 Point",statuses:A[Math.floor(Math.random()*A.length)],globalRewardKey:null,programRewardKey:"partnerReward",meta:{...P()},rewardRedemptionTransactions:{data:[{exchangedRewards:{data:[{prettyValue:"CAD10.00 Visa* Prepaid Card CAD",type:"INTEGRATION",fuelTankCode:null,globalRewardKey:"gc1"}]}}]}}]:[],childNodes:{data:[{data:{id:"5cae6b16cc540e209db45cb3",statuses:A[Math.floor(Math.random()*A.length)],type:"PCT_DISCOUNT",value:50},depth:1},{data:{id:"5cae6b16cc540e209db45cfa",statuses:A[Math.floor(Math.random()*A.length)],type:"CREDIT",value:1},depth:1}]}})))}))(e.perPage)}),[e.perPage]),u=N();return n((()=>{l({loading:!0}),(null==o?void 0:o.data)&&async function(t){var a;let s;const r=null==o?void 0:o.referredByReferral,i=e.showReferrer&&!!(null===(a=null==o?void 0:o.referredByReferral)||void 0===a?void 0:a.dateReferralStarted);s=o.data.slice(0,i?e.perPage-1:e.perPage);const n=t.filter((e=>{var t,a;return"loading"!==e.slot&&"empty"!==e.slot&&"loading"!==(null===(t=null==e?void 0:e.firstElementChild)||void 0===t?void 0:t.getAttribute("slot"))&&"empty"!==(null===(a=null==e?void 0:e.firstElementChild)||void 0===a?void 0:a.getAttribute("slot"))})),d=null==n?void 0:n.map((async(e,t)=>{var a;const s=null===(a=null==e?void 0:e.firstElementChild)||void 0===a?void 0:a.getAttribute("slot");if("RAISINS-PLOP-TARGET"===e.tagName&&"loading"!==s&&"empty"!==s){e.setAttribute("slot","column-"+t),e.style.position="absolute";const a=e.firstElementChild.childNodes[1];return a.innerHTML="+",a.style.lineHeight="20px",_(e,(()=>e.renderLabel(t)))}return _(e,(()=>e.renderLabel()))}));let u;if(i){const e=null==n?void 0:n.map((async e=>_(e,(function(){return e.renderCell(r,e)}))));u=await Promise.all(e)}const c=null==s?void 0:s.map((async e=>{const t=null==n?void 0:n.map((async t=>_(t,(()=>t.renderCell(e,void 0)))));return await Promise.all(t)})),E=c&&[u,...await Promise.all(c)].filter((e=>e));l({rows:E});const p=d&&await Promise.all(d);l({columns:p,loading:!1,page:0})}(u)}),[null==o?void 0:o.data,u,d]),E({states:{hasPrev:!1,hasNext:!1,loading:!1,show:"rows"},callbacks:{prevPage:()=>console.log("Prev"),nextPage:()=>console.log("Next")},data:{textOverrides:{showLabels:!e.hideLabels,prevLabel:e.prevLabel,moreLabel:e.moreLabel},hiddenColumns:e.hiddenColumns,referralData:[],mdBreakpoint:799,smBreakpoint:599},elements:{columns:s.columns,rows:s.rows,emptyElement:t,loadingElement:a}},e.demoData||{},{arrayMerge:(e,t)=>t})}(this,e,a):I(this,e,a);return h([this.showReferrer,this.perPage]),t(p,{states:s,data:l,callbacks:d,elements:u})}};function g(){return t("slot",{name:"empty"},t("sqm-empty",{"empty-state-image":"https://res.cloudinary.com/saasquatch/image/upload/v1644000223/squatch-assets/empty_referral2.png","empty-state-header":"View your referral details","empty-state-text":"Refer a friend to view the status of your referrals and rewards earned"}))}function T(){return t("slot",{name:"loading"},t(C,null),t(C,null),t(C,null),t(C,null))}function C(){return t("sqm-table-row",null,t("sqm-table-cell",{colspan:5},t("sl-skeleton",null)))}const b=class{constructor(t){e(this,t),this.ignored=!0,l(this)}disconnectedCallback(){}render(){return t("div",{innerHTML:this.innerTemplate})}},L=class{constructor(t){e(this,t),l(this)}disconnectedCallback(){}async renderCell(e){return t("sqm-referral-table-cell",{"inner-template":a(this).innerHTML})}async renderLabel(){return Promise.resolve(this.columnTitle)}render(){return h([this.columnTitle]),t(s,{style:{display:"none"}},t("slot",null))}},O=class{constructor(t){e(this,t),this.ignored=!0,this.locale="en",l(this)}disconnectedCallback(){}render(){var e;return this.date?null===(e=m.DateTime.fromMillis(this.date))||void 0===e?void 0:e.setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED):"-"}},w=class{constructor(t){e(this,t),this.columnTitle="Date converted",this.dateShown="dateConverted",l(this)}disconnectedCallback(){}async renderCell(e,a){return t("sqm-referral-table-date-cell",{date:e[this.dateShown],locale:null==a?void 0:a.locale})}async renderLabel(){return this.columnTitle}async renderReferrerCell(e){return t("sqm-referral-table-date-cell",{date:e[this.dateShown]})}render(){return h([this.dateShown,this.columnTitle]),t(s,{style:{display:"none"}})}},x=class{constructor(t){e(this,t),this.statusText="{status, select, AVAILABLE {Available} CANCELLED {Cancelled} PENDING {Pending} PENDING_REVIEW {Pending} PAYOUT_APPROVED {Payout Approved} PAYOUT_FAILED {Payout Failed} PAYOUT_CANCELLED {Payout Cancelled} PENDING_TAX_REVIEW {Pending} PENDING_NEW_TAX_FORM {Pending} PENDING_TAX_SUBMISSION {Pending} PENDING_PARTNER_CREATION {Pending} DENIED {Denied} EXPIRED {Expired} REDEEMED {Redeemed} other {Not available} }",this.statusLongText="{status, select, AVAILABLE {Reward expiring on} CANCELLED {Reward cancelled on} PENDING {Available on} PENDING_REVIEW {Pending since} PAYOUT_APPROVED {Reward approved for payout and was scheduled for payment based on your settings.} PAYOUT_FAILED {Payout failed due to a fulfillment issue and is currently being retried.} PAYOUT_CANCELLED {If you think this is a mistake, contact our Support team.} PENDING_TAX_REVIEW {Awaiting tax form review} PENDING_NEW_TAX_FORM {Invalid tax form. Submit a new form to receive your rewards.} PENDING_TAX_SUBMISSION {Submit your tax documents to receive your rewards} PENDING_PARTNER_CREATION {Complete your tax and cash payout setup to receive your rewards} DENIED {Denied on} EXPIRED {Reward expired on} other {Not available} }",this.locale="en"}render(){var e;d.locale=this.locale;const a=c({"@keyframes slideRight":{from:{opacity:0},to:{opacity:1}},DetailsContainer:{width:"100%",display:"flex","align-items":"center","justify-content":"space-between","margin-right":"var(--sl-spacing-small)","flex-wrap":"wrap"},Details:{"padding-bottom":"var(--sl-spacing-small)","max-width":"500px","&::part(header)":{padding:"var(--sl-spacing-x-small)",cursor:this.hideDetails?"default":"pointer"},"&::part(content)":{padding:"var(--sl-spacing-x-small) var(--sl-spacing-medium)"},"&::part(base)":{opacity:"1"},"&::part(summary-icon)":{display:this.hideDetails?"none":"flex"},"&::part(summary-icon[open])":{transform:"rotate(-90deg)",background:"red"}},BadgeContainer:{"& > :not(:last-child)":{"margin-right":"var(--sl-spacing-x-small)"}},BoldText:{"font-weight":"var(--sl-font-weight-semibold)"},StatusBadge:{paddingLeft:"var(--sl-spacing-xxx-small)","&::part(base)":{textAlign:"center",maxWidth:"170px",whiteSpace:"pre-line"}},RedeemBadge:{paddingLeft:"var(--sl-spacing-xxx-small)","&::part(base)":{background:"var(--sl-color-blue-600)"}}}),s=a.toString(),l=e=>m.DateTime.fromMillis(e).setLocale(u(this.locale)).toRelative().replace("in","").trim();return null===(e=this.rewards)||void 0===e?void 0:e.map((e=>{var r,i;const n=((e,t)=>{var a,s,l,r,i,n,d,o,u,c,E,p;if("APPROVED"!==(null===(s=null===(a=e.referral)||void 0===a?void 0:a.fraudData)||void 0===s?void 0:s.moderationStatus)){if("PENDING"===(null===(r=null===(l=e.referral)||void 0===l?void 0:l.fraudData)||void 0===r?void 0:r.moderationStatus))return"PENDING_REVIEW";if("DENIED"===(null===(n=null===(i=e.referral)||void 0===i?void 0:i.fraudData)||void 0===n?void 0:n.moderationStatus))return"DENIED"}const h=null===(d=e.partnerFundsTransfer)||void 0===d?void 0:d.status;if("NOT_YET_DUE"===h||"TRANSFERRED"===h)return"PAYOUT_APPROVED";if("OVERDUE"===h)return"PAYOUT_FAILED";if("REVERSED"===h)return"PAYOUT_CANCELLED";if(null===(o=null==e?void 0:e.pendingReasons)||void 0===o?void 0:o.includes("US_TAX")){if(!(null==t?void 0:t.taxHandlingEnabled))return"PENDING";if(!(null==t?void 0:t.connected))return"PENDING_PARTNER_CREATION";if(null===(u=null==t?void 0:t.publisher)||void 0===u?void 0:u.requiredTaxDocumentType){if(!(null===(c=null==t?void 0:t.publisher)||void 0===c?void 0:c.currentTaxDocument))return"PENDING_TAX_SUBMISSION";const e=t.publisher.currentTaxDocument.status;if("INACTIVE"===e)return"PENDING_NEW_TAX_FORM";if("NOT_VERIFIED"===e)return"PENDING_TAX_REVIEW"}if(!(null===(E=null==t?void 0:t.publisher)||void 0===E?void 0:E.withdrawalSettings))return"PENDING_PARTNER_CREATION"}return(null===(p=null==e?void 0:e.pendingReasons)||void 0===p?void 0:p.includes("PAYOUT_CONFIGURATION_MISSING"))?"PENDING_PARTNER_CREATION":1===e.statuses.length?e.statuses[0]:["REDEEMED","CANCELLED","EXPIRED","PENDING","AVAILABLE","PENDING_REVIEW","DENIED","PAYOUT_APPROVED","PAYOUT_CANCELLED","PAYOUT_FAILED","PENDING_TAX_REVIEW","PENDING_NEW_TAX_FORM","PENDING_TAX_SUBMISSION","PENDING_PARTNER_CREATION"].find((t=>e.statuses.includes(t)&&t))})(e,this.taxConnection),o=(e=>{switch(e){case"REDEEMED":case"PAYOUT_APPROVED":return"primary";case"DENIED":case"EXPIRED":case"CANCELLED":case"PAYOUT_FAILED":case"PAYOUT_CANCELLED":return"danger";case"PENDING":case"PENDING_REVIEW":case"PENDING_TAX_REVIEW":case"PENDING_NEW_TAX_FORM":case"PENDING_TAX_SUBMISSION":case"PENDING_PARTNER_CREATION":return"warning";case"AVAILABLE":return"success"}})(n),c=d.formatMessage({id:"statusShortMessage",defaultMessage:this.statusText},{status:n}),E=d.formatMessage({id:"statusLongMessage",defaultMessage:this.statusLongText},{status:n});return t("sl-details",{class:a.classes.Details,disabled:this.hideDetails},t("style",{type:"text/css"},s),t("div",{slot:"summary",class:a.classes.DetailsContainer},t(D,{type:"p"},t("span",{part:"sqm-cell-value",class:a.classes.BoldText},e.prettyValue)),t("div",{class:a.classes.BadgeContainer},t("sl-badge",{class:"primary"===o?a.classes.RedeemBadge:a.classes.StatusBadge,type:o,pill:!0},"PENDING"===n&&e.dateScheduledFor?d.formatMessage({id:"pendingForText",defaultMessage:this.pendingForText},{status:c,date:l(e.dateScheduledFor)}):c),e.dateExpires&&"AVAILABLE"===n&&t("sl-badge",{class:"primary"===o?a.classes.RedeemBadge:a.classes.StatusBadge,type:"info",pill:!0},this.expiringText,` ${l(e.dateExpires)}`))),t("div",null,"PENDING_REVIEW"===n&&(null===(r=e.referral)||void 0===r?void 0:r.dateModerated)&&t("div",null,t(D,{type:"p"},E," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},m.DateTime.fromMillis(e.referral.dateModerated).setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED)))),"PAYOUT_APPROVED"===n&&t("div",null,t(D,{type:"p"},E)),"PAYOUT_FAILED"===n&&t("div",null,t(D,{type:"p"},E)),"PAYOUT_CANCELLED"===n&&t("div",null,t(D,{type:"p"},E)),"PENDING_TAX_REVIEW"===n&&t("div",null,t(D,{type:"p"},E)),"PENDING_NEW_TAX_FORM"===n&&t("div",null,t(D,{type:"p"},E)),"PENDING_TAX_SUBMISSION"===n&&t("div",null,t(D,{type:"p"},E)),"PENDING_PARTNER_CREATION"===n&&t("div",null,t(D,{type:"p"},E)),"DENIED"===n&&(null===(i=e.referral)||void 0===i?void 0:i.dateModerated)&&t("div",null,t(D,{type:"p"},E," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},m.DateTime.fromMillis(e.referral.dateModerated).setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED)),".",this.deniedHelpText?` ${this.deniedHelpText}`:"")),e.dateGiven&&t("div",null,t(D,{type:"p"},this.rewardReceivedText," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},m.DateTime.fromMillis(e.dateGiven).setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED)))),"EXPIRED"===n&&e.dateExpires&&t("div",null,t(D,{type:"p"},E," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},m.DateTime.fromMillis(e.dateExpires).setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED)))),"CANCELLED"===n&&e.dateCancelled&&t("div",null,t(D,{type:"p"},E," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},m.DateTime.fromMillis(e.dateCancelled).setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED)))),"PENDING"===n&&e.dateScheduledFor&&t("div",null,t(D,{type:"p"},E," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},m.DateTime.fromMillis(e.dateScheduledFor).setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED))))," ","AVAILABLE"===n&&e.dateExpires&&t("div",null,t(D,{type:"p"},E," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},m.DateTime.fromMillis(e.dateExpires).setLocale(u(this.locale)).toLocaleString(m.DateTime.DATE_MED)))),e.fuelTankCode&&t("div",null,this.fuelTankText," ",t("span",{class:a.classes.BoldText,part:"sqm-cell-value"},e.fuelTankCode))))}))}},G=class{constructor(t){e(this,t),this.columnTitle="Rewards",this.statusText="{status, select, AVAILABLE {Available} CANCELLED {Cancelled} PENDING {Pending} PENDING_REVIEW {Pending} PAYOUT_APPROVED {Payout Approved} PAYOUT_FAILED {Payout Failed} PAYOUT_CANCELLED {Payout Cancelled} PENDING_TAX_REVIEW {Pending} PENDING_NEW_TAX_FORM {Pending} PENDING_TAX_SUBMISSION {Pending} PENDING_PARTNER_CREATION {Pending} DENIED {Denied} EXPIRED {Expired} REDEEMED {Redeemed} other {Not available} }",this.statusLongText="{status, select, AVAILABLE {Reward expiring on} CANCELLED {Reward cancelled on} PENDING {Available on} PENDING_REVIEW {Pending since} PAYOUT_APPROVED {Reward approved for payout and was scheduled for payment based on your settings.} PAYOUT_FAILED {Payout failed due to a fulfillment issue and is currently being retried.} PAYOUT_CANCELLED {If you think this is a mistake, contact our Support team.} PENDING_TAX_REVIEW {Awaiting tax form review} PENDING_NEW_TAX_FORM {Invalid tax form. Submit a new form to receive your rewards.} PENDING_TAX_SUBMISSION {Submit your tax documents to receive your rewards} PENDING_PARTNER_CREATION {Complete your tax and cash payout setup to receive your rewards} DENIED {Denied on} EXPIRED {Reward expired on} other {Not available} }",this.fuelTankText="Your code is",this.rewardReceivedText="Reward received on",this.expiringText="Expiring in",this.pendingForText="{status} for {date}",this.deniedHelpText="Contact support if you think this is a mistake.",this.hideDetails=!1,l(this)}disconnectedCallback(){}async renderCell(e,a){return t("sqm-referral-table-rewards-cell",{rewards:e.rewards,taxConnection:null==a?void 0:a.taxConnection,statusText:this.statusText,statusLongText:this.statusLongText,fuelTankText:this.fuelTankText,rewardReceivedText:this.rewardReceivedText,expiringText:this.expiringText,pendingForText:this.pendingForText,hideDetails:this.hideDetails,deniedHelpText:this.deniedHelpText,locale:null==a?void 0:a.locale,exportparts:"sqm-cell-value"})}async renderLabel(){return this.columnTitle}async renderReferrerCell(e){return t("sqm-referral-table-rewards-cell",{rewards:e.rewards,exportparts:"sqm-cell-value"})}render(){return h([this.columnTitle,this.statusText,this.statusLongText,this.fuelTankText,this.rewardReceivedText,this.expiringText,this.pendingForText,this.hideDetails]),t(s,{style:{display:"none"}})}},S=c({Badge:{"&::part(base)":{fontSize:"var(--sl-font-size-small)",padding:"4px 8px",whiteSpace:"pre-line"}},SubText:{fontSize:"var(--sl-font-size-small)",color:"var(--sl-color-neutral-500)",margin:"0"}}),M=S.toString(),U=class{constructor(t){e(this,t)}render(){return t("div",null,t("style",{type:"text/css"},M),t("sl-badge",{pill:!0,type:(e=>"PENDING"===e?"warning":"DENIED"===e?"danger":this.converted?"success":"warning")(this.fraudStatus),class:S.classes.Badge},this.statusText),this.statusSubText?t("p",{class:S.classes.SubText},this.statusSubText):null)}},V=class{constructor(t){e(this,t),this.columnTitle="Status",this.convertedStatusText="Converted",this.inProgressStatusText="In Progress",this.pendingReviewStatusText="Pending",this.deniedStatusText="Denied",this.pendingReviewStatusSubText="Awaiting review",this.deniedStatusSubText="Detected self-referral",l(this)}disconnectedCallback(){}async renderCell(e){var a;let s,l;const r=null===(a=null==e?void 0:e.fraudData)||void 0===a?void 0:a.moderationStatus;return"DENIED"===r?(s=this.deniedStatusText,l=this.deniedStatusSubText):"PENDING"===r?(s=this.pendingReviewStatusText,l=this.pendingReviewStatusSubText):s=e.dateConverted?this.convertedStatusText:this.inProgressStatusText,t("sqm-referral-table-status-cell",{"status-text":s,"status-sub-text":l,"fraud-status":r,converted:!!e.dateConverted})}async renderLabel(){return this.columnTitle}async renderReferrerCell(e){return t("sqm-referral-table-status-cell",{"status-text":e.dateConverted?this.convertedStatusText:this.inProgressStatusText,converted:!!e.dateConverted})}render(){return h([this.columnTitle,this.convertedStatusText,this.inProgressStatusText]),t(s,{style:{display:"none"}})}},q=class{constructor(t){e(this,t)}render(){return this.name}},X=class{constructor(t){e(this,t),this.columnTitle="Customer",this.anonymousUser="Anonymous User",this.deletedUser="Deleted User",l(this)}disconnectedCallback(){}async renderCell(e){var a,s,l,r,i,n,d,o;let u;return u=(null==e?void 0:e.referredUser)||(null==e?void 0:e.referrerUser)?(null===(a=null==e?void 0:e.referredUser)||void 0===a?void 0:a.firstName)||(null===(s=null==e?void 0:e.referredUser)||void 0===s?void 0:s.lastName)||(null===(l=null==e?void 0:e.referrerUser)||void 0===l?void 0:l.firstName)||(null===(r=null==e?void 0:e.referrerUser)||void 0===r?void 0:r.lastName)?(null==e?void 0:e.referrerUser)?`${null===(i=null==e?void 0:e.referrerUser)||void 0===i?void 0:i.firstName} ${null===(n=null==e?void 0:e.referrerUser)||void 0===n?void 0:n.lastName}`:`${null===(d=null==e?void 0:e.referredUser)||void 0===d?void 0:d.firstName} ${null===(o=null==e?void 0:e.referredUser)||void 0===o?void 0:o.lastName}`:this.anonymousUser:this.deletedUser,t("sqm-referral-table-user-cell",{name:u})}async renderLabel(){return this.columnTitle}async renderReferrerCell(e){var a,s,l,r;let i;return i=e?(null===(a=null==e?void 0:e.referrerUser)||void 0===a?void 0:a.firstName)||(null===(s=e.referrerUser)||void 0===s?void 0:s.lastName)?`${null===(l=null==e?void 0:e.referrerUser)||void 0===l?void 0:l.firstName} ${null===(r=null==e?void 0:e.referrerUser)||void 0===r?void 0:r.lastName}`:this.anonymousUser:this.deletedUser,t("sqm-referral-table-user-cell",{name:i})}render(){return h([this.deletedUser,this.anonymousUser,this.columnTitle]),t(s,{style:{display:"none"}})}};export{R as sqm_referral_table,b as sqm_referral_table_cell,L as sqm_referral_table_column,O as sqm_referral_table_date_cell,w as sqm_referral_table_date_column,x as sqm_referral_table_rewards_cell,G as sqm_referral_table_rewards_column,U as sqm_referral_table_status_cell,V as sqm_referral_table_status_column,q as sqm_referral_table_user_cell,X as sqm_referral_table_user_column}
@@ -1 +0,0 @@
1
- import{r as s,h as t}from"./p-61d5f26e.js";import{n as a}from"./p-019506c4.js";import{S as r,i as o}from"./p-8c765c81.js";import{g as e}from"./p-9ec99ced.js";import"./p-cef45012.js";import{c as i}from"./p-c1086930.js";import"./p-02be1a88.js";import{N as c}from"./p-fd04355d.js";const n=class{constructor(t){s(this,t),a(this)}disconnectedCallback(){}render(){const s=o()?function(s){return i({states:{active:!1},data:{label:s.label||"Dashboard",icon:s.icon||"house"}},s.demoData||{},{arrayMerge:(s,t)=>t})}(e(this)):function(s){return{states:{active:r().pathname===s.path},data:{label:s.label,icon:s.icon,path:s.path}}}(e(this));return t(c,Object.assign({},s))}};export{n as sqm_navigation_sidebar_item}
@@ -4,10 +4,10 @@ const index = require('./index-ff72278c.js');
4
4
  const stencilHooks_module = require('./stencil-hooks.module-8f69ed33.js');
5
5
  const global = require('./global-e067aa06.js');
6
6
  const index_module = require('./index.module-224d7b8d.js');
7
+ const cjs = require('./cjs-1066ec21.js');
7
8
  const utils = require('./utils-6847bc06.js');
8
9
  const JSS = require('./JSS-8503a151.js');
9
10
  const copyTextView = require('./copy-text-view-bb2d108f.js');
10
- const cjs = require('./cjs-1066ec21.js');
11
11
  const mixins = require('./mixins-fe9d4112.js');
12
12
  const useChildElements = require('./useChildElements-176ac928.js');
13
13
  const luxon = require('./luxon-45228ff5.js');
@@ -2,10 +2,10 @@ import { h, c as Host, d as getAssetPath, g as getElement } from './index-014ddf
2
2
  import { k as useState, b as browser, u as useMemo } from './stencil-hooks.module-576d7f01.js';
3
3
  import { i as intl } from './global-701bd5b0.js';
4
4
  import { d as dist, H, Q, I as In, y as yn, $ as $e, B, a as getEnvironmentSDK, L } from './index.module-5eb0926c.js';
5
+ import { c as cjs } from './cjs-bdfb4486.js';
5
6
  import { l as luxonLocale } from './utils-334c1e34.js';
6
7
  import { c as createStyleSheet, j as jss, a as create } from './JSS-67b5cff8.js';
7
8
  import { a as REFERRAL_CODES_NAMESPACE, S as SET_CODE_COPIED, C as CopyTextView } from './copy-text-view-32aad903.js';
8
- import { c as cjs } from './cjs-bdfb4486.js';
9
9
  import { H as HostBlock, A as AuthWrapper, a as AuthColumn, b as AuthButtonsContainer, E as ErrorStyles } from './mixins-f60a614c.js';
10
10
  import { u as useChildElements } from './useChildElements-ebcfbc19.js';
11
11
  import { l as luxon } from './luxon-12195d94.js';