@jetthai/cuora 1.1.34 → 1.1.35

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [1.1.35](https://github.com/jetthai/cuora-module/compare/v1.1.34...v1.1.35) (2023-01-12)
6
+
5
7
  ### [1.1.34](https://github.com/jetthai/cuora-module/compare/v1.1.32...v1.1.34) (2023-01-10)
6
8
 
7
9
  ### [1.1.33](https://github.com/jetthai/cuora-module/compare/v1.1.32...v1.1.33) (2023-01-10)
package/dist/bundle.mjs CHANGED
@@ -16560,9 +16560,9 @@ function loadcard_vn (request) {
16560
16560
  },
16561
16561
  },
16562
16562
  checking: {
16563
- always: [{ target: 'promotionApplyMode', cond: 'isPromotionApplyMode' }, { target: 'defaultMode' }],
16563
+ always: [{ target: 'newWalletMode', cond: 'isNewWalletMode' }, { target: 'defaultMode' }],
16564
16564
  },
16565
- promotionApplyMode: {
16565
+ newWalletMode: {
16566
16566
  initial: 'loaded',
16567
16567
  states: {
16568
16568
  loaded: {
@@ -16572,12 +16572,12 @@ function loadcard_vn (request) {
16572
16572
  actions: 'setCard',
16573
16573
  },
16574
16574
  SELECT_AMOUNT: {
16575
- target: 'submittable',
16575
+ target: 'pending',
16576
16576
  actions: 'setAmount',
16577
16577
  },
16578
16578
  },
16579
16579
  },
16580
- submittable: {
16580
+ pending: {
16581
16581
  on: {
16582
16582
  SELECT_AMOUNT: {
16583
16583
  actions: 'setAmount',
@@ -16854,7 +16854,7 @@ function loadcard_vn (request) {
16854
16854
  }),
16855
16855
  },
16856
16856
  guards: {
16857
- isPromotionApplyMode: (context, event) => {
16857
+ isNewWalletMode: (context, event) => {
16858
16858
  return context.siteConfig?.walletMode === '2'
16859
16859
  },
16860
16860
  isSubmittable: (context, event) => {
@@ -17143,9 +17143,9 @@ function qrcode_v2 (request) {
17143
17143
  },
17144
17144
  },
17145
17145
  checking: {
17146
- always: [{ target: 'promotionApplyMode', cond: 'isPromotionApplyMode' }, { target: 'defaultMode' }],
17146
+ always: [{ target: 'newWalletMode', cond: 'isNewWalletMode' }, { target: 'defaultMode' }],
17147
17147
  },
17148
- promotionApplyMode: {
17148
+ newWalletMode: {
17149
17149
  initial: 'loaded',
17150
17150
  states: {
17151
17151
  loaded: {
@@ -17156,12 +17156,12 @@ function qrcode_v2 (request) {
17156
17156
  },
17157
17157
  SELECT_AMOUNT: [
17158
17158
  {
17159
- target: 'submittable',
17159
+ target: 'pending',
17160
17160
  actions: 'addAmount',
17161
17161
  cond: (context, event) => context.grandTotalEnable === 1,
17162
17162
  },
17163
17163
  {
17164
- target: 'submittable',
17164
+ target: 'pending',
17165
17165
  actions: 'setAmount',
17166
17166
  },
17167
17167
  ],
@@ -17170,7 +17170,7 @@ function qrcode_v2 (request) {
17170
17170
  },
17171
17171
  },
17172
17172
  },
17173
- submittable: {
17173
+ pending: {
17174
17174
  on: {
17175
17175
  SELECT_AMOUNT: [
17176
17176
  {
@@ -17265,7 +17265,7 @@ function qrcode_v2 (request) {
17265
17265
  actions: 'setResult',
17266
17266
  },
17267
17267
  onError: {
17268
- target: 'submittable',
17268
+ target: 'pending',
17269
17269
  },
17270
17270
  },
17271
17271
  },
@@ -17477,7 +17477,7 @@ function qrcode_v2 (request) {
17477
17477
  }),
17478
17478
  },
17479
17479
  guards: {
17480
- isPromotionApplyMode: (context, event) => {
17480
+ isNewWalletMode: (context, event) => {
17481
17481
  return context.siteConfig?.walletMode === '2'
17482
17482
  },
17483
17483
  },
@@ -18423,9 +18423,9 @@ function crypto_button (request) {
18423
18423
  },
18424
18424
  },
18425
18425
  checking: {
18426
- always: [{ target: 'promotionApplyMode', cond: 'isPromotionApplyMode' }, { target: 'defaultMode' }],
18426
+ always: [{ target: 'newWalletMode', cond: 'isNewWalletMode' }, { target: 'defaultMode' }],
18427
18427
  },
18428
- promotionApplyMode: {
18428
+ newWalletMode: {
18429
18429
  initial: 'loaded',
18430
18430
  states: {
18431
18431
  loaded: {
@@ -18778,7 +18778,7 @@ function crypto_button (request) {
18778
18778
  }),
18779
18779
  },
18780
18780
  guards: {
18781
- isPromotionApplyMode: (context, event) => {
18781
+ isNewWalletMode: (context, event) => {
18782
18782
  return context.siteConfig?.walletMode === '2'
18783
18783
  },
18784
18784
  isConfirmable: (context, event) => {
@@ -20424,25 +20424,25 @@ function promotions (request) {
20424
20424
  pending: {
20425
20425
  on: {
20426
20426
  CONFIRM: {
20427
- target: 'joinning',
20427
+ target: 'applying',
20428
20428
  },
20429
20429
  BACK: {
20430
20430
  target: 'loaded',
20431
20431
  },
20432
20432
  },
20433
20433
  },
20434
- joinning: {
20434
+ applying: {
20435
20435
  invoke: {
20436
20436
  src: 'applyPromotion',
20437
20437
  onDone: {
20438
- target: 'joined',
20438
+ target: 'applied',
20439
20439
  },
20440
20440
  onError: {
20441
20441
  target: 'loaded',
20442
20442
  },
20443
20443
  },
20444
20444
  },
20445
- joined: {},
20445
+ applied: {},
20446
20446
  fail: {},
20447
20447
  },
20448
20448
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jetthai/cuora",
3
- "version": "1.1.34",
3
+ "version": "1.1.35",
4
4
  "description": "",
5
5
  "main": "./src/index.js",
6
6
  "type": "module",
@@ -45,9 +45,9 @@ export default function (request) {
45
45
  },
46
46
  },
47
47
  checking: {
48
- always: [{ target: 'promotionApplyMode', cond: 'isPromotionApplyMode' }, { target: 'defaultMode' }],
48
+ always: [{ target: 'newWalletMode', cond: 'isNewWalletMode' }, { target: 'defaultMode' }],
49
49
  },
50
- promotionApplyMode: {
50
+ newWalletMode: {
51
51
  initial: 'loaded',
52
52
  states: {
53
53
  loaded: {
@@ -400,7 +400,7 @@ export default function (request) {
400
400
  }),
401
401
  },
402
402
  guards: {
403
- isPromotionApplyMode: (context, event) => {
403
+ isNewWalletMode: (context, event) => {
404
404
  return context.siteConfig?.walletMode === '2'
405
405
  },
406
406
  isConfirmable: (context, event) => {
@@ -40,9 +40,9 @@ export default function (request) {
40
40
  },
41
41
  },
42
42
  checking: {
43
- always: [{ target: 'promotionApplyMode', cond: 'isPromotionApplyMode' }, { target: 'defaultMode' }],
43
+ always: [{ target: 'newWalletMode', cond: 'isNewWalletMode' }, { target: 'defaultMode' }],
44
44
  },
45
- promotionApplyMode: {
45
+ newWalletMode: {
46
46
  initial: 'loaded',
47
47
  states: {
48
48
  loaded: {
@@ -52,12 +52,12 @@ export default function (request) {
52
52
  actions: 'setCard',
53
53
  },
54
54
  SELECT_AMOUNT: {
55
- target: 'submittable',
55
+ target: 'pending',
56
56
  actions: 'setAmount',
57
57
  },
58
58
  },
59
59
  },
60
- submittable: {
60
+ pending: {
61
61
  on: {
62
62
  SELECT_AMOUNT: {
63
63
  actions: 'setAmount',
@@ -334,7 +334,7 @@ export default function (request) {
334
334
  }),
335
335
  },
336
336
  guards: {
337
- isPromotionApplyMode: (context, event) => {
337
+ isNewWalletMode: (context, event) => {
338
338
  return context.siteConfig?.walletMode === '2'
339
339
  },
340
340
  isSubmittable: (context, event) => {
@@ -40,9 +40,9 @@ export default function (request) {
40
40
  },
41
41
  },
42
42
  checking: {
43
- always: [{ target: 'promotionApplyMode', cond: 'isPromotionApplyMode' }, { target: 'defaultMode' }],
43
+ always: [{ target: 'newWalletMode', cond: 'isNewWalletMode' }, { target: 'defaultMode' }],
44
44
  },
45
- promotionApplyMode: {
45
+ newWalletMode: {
46
46
  initial: 'loaded',
47
47
  states: {
48
48
  loaded: {
@@ -53,12 +53,12 @@ export default function (request) {
53
53
  },
54
54
  SELECT_AMOUNT: [
55
55
  {
56
- target: 'submittable',
56
+ target: 'pending',
57
57
  actions: 'addAmount',
58
58
  cond: (context, event) => context.grandTotalEnable === 1,
59
59
  },
60
60
  {
61
- target: 'submittable',
61
+ target: 'pending',
62
62
  actions: 'setAmount',
63
63
  },
64
64
  ],
@@ -67,7 +67,7 @@ export default function (request) {
67
67
  },
68
68
  },
69
69
  },
70
- submittable: {
70
+ pending: {
71
71
  on: {
72
72
  SELECT_AMOUNT: [
73
73
  {
@@ -162,7 +162,7 @@ export default function (request) {
162
162
  actions: 'setResult',
163
163
  },
164
164
  onError: {
165
- target: 'submittable',
165
+ target: 'pending',
166
166
  },
167
167
  },
168
168
  },
@@ -374,7 +374,7 @@ export default function (request) {
374
374
  }),
375
375
  },
376
376
  guards: {
377
- isPromotionApplyMode: (context, event) => {
377
+ isNewWalletMode: (context, event) => {
378
378
  return context.siteConfig?.walletMode === '2'
379
379
  },
380
380
  },
@@ -56,25 +56,25 @@ export default function (request) {
56
56
  pending: {
57
57
  on: {
58
58
  CONFIRM: {
59
- target: 'joinning',
59
+ target: 'applying',
60
60
  },
61
61
  BACK: {
62
62
  target: 'loaded',
63
63
  },
64
64
  },
65
65
  },
66
- joinning: {
66
+ applying: {
67
67
  invoke: {
68
68
  src: 'applyPromotion',
69
69
  onDone: {
70
- target: 'joined',
70
+ target: 'applied',
71
71
  },
72
72
  onError: {
73
73
  target: 'loaded',
74
74
  },
75
75
  },
76
76
  },
77
- joined: {},
77
+ applied: {},
78
78
  fail: {},
79
79
  },
80
80
  },