favesalon-embed 1.0.23 → 1.0.25

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 (32) hide show
  1. package/dist/favesalon-embed/activate-form.entry.js +1 -1
  2. package/dist/favesalon-embed/buy-giftcard-form.entry.js +169 -19
  3. package/dist/favesalon-embed/buy-giftcard-verification.entry.js +1 -1
  4. package/dist/favesalon-embed/change-password-form.entry.js +1 -1
  5. package/dist/favesalon-embed/chat-box.entry.js +1 -1
  6. package/dist/favesalon-embed/chat-button.entry.js +1 -1
  7. package/dist/favesalon-embed/chat-form.entry.js +1 -1
  8. package/dist/favesalon-embed/chat-messages.entry.js +1 -1
  9. package/dist/favesalon-embed/chat-rooms.entry.js +1 -1
  10. package/dist/favesalon-embed/login-form.entry.js +1 -1
  11. package/dist/favesalon-embed/register-form.entry.js +1 -1
  12. package/dist/favesalon-embed/reset-password-form.entry.js +1 -1
  13. package/dist/favesalon-embed/salon-info.entry.js +1 -1
  14. package/dist/favesalon-embed/salon-latest-reviews.entry.js +1 -1
  15. package/dist/favesalon-embed/salon-latest-styles.entry.js +1 -1
  16. package/dist/favesalon-embed/salon-locations.entry.js +1 -1
  17. package/dist/favesalon-embed/salon-lookbook.entry.js +1 -1
  18. package/dist/favesalon-embed/salon-reviews.entry.js +1 -1
  19. package/dist/favesalon-embed/salon-schedules.entry.js +1 -1
  20. package/dist/favesalon-embed/salon-services.entry.js +1 -1
  21. package/dist/favesalon-embed/salon-stylists.entry.js +1 -1
  22. package/dist/favesalon-embed/services-2993bf2a.js +24157 -0
  23. package/dist/favesalon-embed/services-54b63d13.js +24157 -0
  24. package/dist/favesalon-embed/services-97ad3e3d.js +24157 -0
  25. package/dist/favesalon-embed/{services-415497f0.js → services-a7506d8c.js} +13 -9
  26. package/dist/favesalon-embed/{services-42acb174.js → services-cb90384e.js} +11 -8
  27. package/dist/favesalon-embed/style-detail.entry.js +1 -1
  28. package/dist/favesalon-embed/wizard-existing-user.entry.js +1 -1
  29. package/dist/favesalon-embed/wizard-new-user.entry.js +1 -1
  30. package/dist/types/components/buy-giftcard-form/buy-giftcard-form.d.ts +2 -0
  31. package/dist/types/services/services.d.ts +5 -13
  32. package/package.json +1 -1
@@ -23677,7 +23677,7 @@ function createGiftCardSettings(blob) {
23677
23677
  isMagensaPayment: false,
23678
23678
  acceptCustomAmount: Boolean(blob.accept_custom_amount),
23679
23679
  acceptPaymentOnline: Boolean(blob.accept_payment_online),
23680
- giftCardTerms: null,
23680
+ giftCardTerms: blob.gift_card_terms,
23681
23681
  giftCardStyles: blob.gift_card_styles.map((style, idx) => {
23682
23682
  return { id: `${style.id}-${idx + 1}`, imageUrl: style.image_url };
23683
23683
  }),
@@ -24098,14 +24098,18 @@ class HttpService {
24098
24098
  .catch(() => ({}));
24099
24099
  }
24100
24100
  fetchMagensaCredentials(salonId) {
24101
- return Promise.resolve(salonId ? {
24102
- customerCode: 'SK90173281',
24103
- username: 'MAG437582692',
24104
- password: `y^5OxmbSnP7Th7`,
24105
- // TEC credentials
24106
- processorName: 'TSYS - Production',
24107
- token: `WEcyNjgxNDM5MS9NQUc1NTU2OTUxODM6WTR0REFaRiQ=`,
24108
- } : {});
24101
+ if (salonId) {
24102
+ const credentials = {
24103
+ customerCode: window.atob('U0s5MDE3MzI4MQ=='),
24104
+ username: window.atob('TUFHNDM3NTgyNjky'),
24105
+ password: window.atob('eV41T3htYlNuUDdUaDc='),
24106
+ processorName: window.atob('VFNZUyAtIFByb2R1Y3Rpb24='),
24107
+ token: window.atob('V0VjeU5qZ3hORE01TVM5TlFVYzFOVFUyT1RVeE9ETTZXVFIwUkVGYVJpUT0='),
24108
+ };
24109
+ debugger;
24110
+ return Promise.resolve(credentials);
24111
+ }
24112
+ return Promise.resolve({});
24109
24113
  }
24110
24114
  magensaProcessToken(salonId, options) {
24111
24115
  const url = `${apiV2Prefix}/magensa/${salonId}/process-token`;
@@ -24098,14 +24098,17 @@ class HttpService {
24098
24098
  .catch(() => ({}));
24099
24099
  }
24100
24100
  fetchMagensaCredentials(salonId) {
24101
- return Promise.resolve(salonId ? {
24102
- customerCode: 'SK90173281',
24103
- username: 'MAG437582692',
24104
- password: `y^5OxmbSnP7Th7`,
24105
- // TEC credentials
24106
- processorName: 'TSYS - Production',
24107
- token: `WEcyNjgxNDM5MS9NQUc1NTU2OTUxODM6WTR0REFaRiQ=`,
24108
- } : {});
24101
+ if (salonId) {
24102
+ const credentials = {
24103
+ customerCode: window.atob('U0s5MDE3MzI4MQ=='),
24104
+ username: window.atob('TUFHNDM3NTgyNjky'),
24105
+ password: window.atob('eV41T3htYlNuUDdUaDc='),
24106
+ processorName: window.atob('VFNZUyAtIFByb2R1Y3Rpb24='),
24107
+ token: window.atob('V0VjeU5qZ3hORE01TVM5TlFVYzFOVFUyT1RVeE9ETTZXVFIwUkVGYVJpUT0='),
24108
+ };
24109
+ return Promise.resolve(credentials);
24110
+ }
24111
+ return Promise.resolve({});
24109
24112
  }
24110
24113
  magensaProcessToken(salonId, options) {
24111
24114
  const url = `${apiV2Prefix}/magensa/${salonId}/process-token`;
@@ -1,5 +1,5 @@
1
1
  import { r as registerInstance, h } from './index-888e99e3.js';
2
- import { d as dayjs_min, H as HttpService, j as isVideoMedia, c as getSalonImage, f as shortDateYearFormat } from './services-42acb174.js';
2
+ import { d as dayjs_min, H as HttpService, k as isVideoMedia, e as getSalonImage, h as shortDateYearFormat } from './services-2993bf2a.js';
3
3
  import { r as relativeTime } from './relativeTime-15477f02.js';
4
4
  import { C as Colors } from './colors-ea36347a.js';
5
5
  import './_commonjsHelpers-9bc404fc.js';
@@ -1,5 +1,5 @@
1
1
  import { r as registerInstance, h } from './index-888e99e3.js';
2
- import { H as HttpService, g as get_1 } from './services-42acb174.js';
2
+ import { H as HttpService, g as get_1 } from './services-2993bf2a.js';
3
3
  import { C as Colors } from './colors-ea36347a.js';
4
4
  import './_commonjsHelpers-9bc404fc.js';
5
5
 
@@ -1,5 +1,5 @@
1
1
  import { r as registerInstance, h } from './index-888e99e3.js';
2
- import { H as HttpService, g as get_1 } from './services-42acb174.js';
2
+ import { H as HttpService, g as get_1 } from './services-2993bf2a.js';
3
3
  import { C as Colors } from './colors-ea36347a.js';
4
4
  import './_commonjsHelpers-9bc404fc.js';
5
5
 
@@ -10,6 +10,7 @@ declare enum FormStep {
10
10
  PaymentSucceed = "Payment Succeed"
11
11
  }
12
12
  export declare class BuyGiftcardForm {
13
+ trackingEvents: any[];
13
14
  deliveryInput?: HTMLInputElement;
14
15
  deliveryReenterInput?: HTMLInputElement;
15
16
  salonId: string;
@@ -37,6 +38,7 @@ export declare class BuyGiftcardForm {
37
38
  isDeliveryDoneVisible: boolean;
38
39
  isTermsAccepted: boolean;
39
40
  componentDidLoad(): Promise<void>;
41
+ private saveTrackingData;
40
42
  private fetchMagensaCredentials;
41
43
  private fetchSalonInfo;
42
44
  private fetchGiftCardSettings;
@@ -129,21 +129,13 @@ declare class HttpService {
129
129
  onBuyGiftCard(salonId: number, options: any): Promise<import("axios").AxiosResponse<any>>;
130
130
  fetchGiftCardSettings(salonId: any): Promise<any>;
131
131
  fetchSalonClientInfo(salonId: any, mobilePhone: any): Promise<{} | {}>;
132
- fetchMagensaCredentials(salonId: any): Promise<{
133
- customerCode: string;
134
- username: string;
135
- password: string;
136
- processorName: string;
137
- token: string;
138
- } | {
139
- customerCode?: undefined;
140
- username?: undefined;
141
- password?: undefined;
142
- processorName?: undefined;
143
- token?: undefined;
144
- }>;
132
+ fetchMagensaCredentials(salonId: any): Promise<{}>;
145
133
  magensaProcessToken(salonId: any, options: any): Promise<any>;
146
134
  magensaConfirmTransaction(options: any): Promise<any>;
135
+ private fetchAWSPresigned;
136
+ private uploadFileToAWS;
137
+ uploadFile(file: any, accessToken: any): Promise<string>;
138
+ log(options: any, accessToken: any): Promise<import("axios").AxiosResponse<any>>;
147
139
  }
148
140
  declare const _default: () => HttpService;
149
141
  export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "favesalon-embed",
3
- "version": "1.0.23",
3
+ "version": "1.0.25",
4
4
  "description": "Favesalon Embed",
5
5
  "author": "Trung Luu <trung@favesalon.com> (https://favesalon.com)",
6
6
  "main": "dist/index.cjs.js",