@achyutlabsau/vue-payment-gateway 0.7.1 → 0.8.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.
@@ -540,7 +540,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
540
540
  createVNode(unref(QToolbarTitle), null, {
541
541
  default: withCtx(() => [
542
542
  renderSlot(_ctx.$slots, "title", {}, () => [
543
- _cache[2] || (_cache[2] = createTextVNode("Reprint Receipt"))
543
+ _cache[2] || (_cache[2] = createTextVNode("Reprint Receipt", -1))
544
544
  ])
545
545
  ]),
546
546
  _: 3
@@ -559,7 +559,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
559
559
  createVNode(unref(QCardSection), null, {
560
560
  default: withCtx(() => [
561
561
  createElementVNode("div", _hoisted_1$1, [
562
- _cache[3] || (_cache[3] = createTextVNode(" Txn Number: ")),
562
+ _cache[3] || (_cache[3] = createTextVNode(" Txn Number: ", -1)),
563
563
  createVNode(unref(QInput), {
564
564
  modelValue: txnNumber.value,
565
565
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => txnNumber.value = $event),
@@ -770,8 +770,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
770
770
  _: 1
771
771
  })
772
772
  ]),
773
- _: 1,
774
- __: [7]
773
+ _: 1
775
774
  }))
776
775
  ])),
777
776
  createVNode(_sfc_main$1, {
@@ -500,8 +500,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
500
500
  createElementVNode("div", _hoisted_9, toDisplayString(pairInfo.value.confirmationCode), 1),
501
501
  _cache[12] || (_cache[12] = createElementVNode("div", { class: "text-center text-sm text-gray-500 dark:text-gray-300" }, " Confirm the matching pairing code on the terminal ", -1))
502
502
  ]),
503
- _: 1,
504
- __: [11, 12]
503
+ _: 1
505
504
  })) : pairInfo.value.state === "FINISHED" ? (openBlock(), createBlock(unref(QCardSection), { key: 2 }, {
506
505
  default: withCtx(() => [
507
506
  createElementVNode("div", _hoisted_10, toDisplayString(pairInfo.value.message), 1),
@@ -526,8 +525,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
526
525
  _: 1
527
526
  }, 8, ["modelValue"])
528
527
  ]),
529
- _: 1,
530
- __: [13]
528
+ _: 1
531
529
  }))
532
530
  ]);
533
531
  };
@@ -331,7 +331,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
331
331
  ]),
332
332
  _cache[3] || (_cache[3] = createElementVNode("h2", { class: "mb-4 text-3xl font-bold" }, "Terminal Connected", -1)),
333
333
  createElementVNode("p", _hoisted_3, [
334
- _cache[2] || (_cache[2] = createTextVNode(" Pairing Code: ")),
334
+ _cache[2] || (_cache[2] = createTextVNode(" Pairing Code: ", -1)),
335
335
  createElementVNode("span", _hoisted_4, toDisplayString(unref(pairConfig).pairingCode), 1)
336
336
  ]),
337
337
  createElementVNode("p", _hoisted_5, " Last paired: " + toDisplayString(new Date(unref(pairConfig).lastPairedDate).toLocaleString()), 1),
@@ -392,8 +392,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
392
392
  ])
393
393
  ], 32)
394
394
  ]),
395
- _: 1,
396
- __: [4]
395
+ _: 1
397
396
  }))
398
397
  ]));
399
398
  };
@@ -569,7 +569,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
569
569
  createVNode(unref(QToolbarTitle), null, {
570
570
  default: withCtx(() => [
571
571
  renderSlot(_ctx.$slots, "title", {}, () => [
572
- _cache[2] || (_cache[2] = createTextVNode("Reprint Receipt"))
572
+ _cache[2] || (_cache[2] = createTextVNode("Reprint Receipt", -1))
573
573
  ])
574
574
  ]),
575
575
  _: 3
@@ -588,7 +588,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
588
588
  createVNode(unref(QCardSection), null, {
589
589
  default: withCtx(() => [
590
590
  createElementVNode("div", _hoisted_1$1, [
591
- _cache[3] || (_cache[3] = createTextVNode(" Txn Number: ")),
591
+ _cache[3] || (_cache[3] = createTextVNode(" Txn Number: ", -1)),
592
592
  createVNode(unref(QInput), {
593
593
  modelValue: txnNumber.value,
594
594
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => txnNumber.value = $event),
@@ -720,11 +720,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
720
720
  ]),
721
721
  _cache[6] || (_cache[6] = createElementVNode("h2", { class: "mb-4 text-3xl font-bold" }, "Terminal Connected", -1)),
722
722
  createElementVNode("p", _hoisted_3, [
723
- _cache[4] || (_cache[4] = createTextVNode(" Terminal ID: ")),
723
+ _cache[4] || (_cache[4] = createTextVNode(" Terminal ID: ", -1)),
724
724
  createElementVNode("b", null, toDisplayString(unref(pairConfig).terminalId), 1)
725
725
  ]),
726
726
  createElementVNode("p", _hoisted_4, [
727
- _cache[5] || (_cache[5] = createTextVNode(" Last paired: ")),
727
+ _cache[5] || (_cache[5] = createTextVNode(" Last paired: ", -1)),
728
728
  createElementVNode("b", null, toDisplayString(new Date(unref(pairConfig).lastPairedDate).toLocaleString()), 1)
729
729
  ]),
730
730
  createElementVNode("div", _hoisted_5, [
@@ -801,8 +801,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
801
801
  _: 1
802
802
  })
803
803
  ]),
804
- _: 1,
805
- __: [7]
804
+ _: 1
806
805
  }))
807
806
  ]),
808
807
  _: 1
@@ -138,11 +138,10 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
138
138
  createVNode(unref(QToolbar), { class: "bg-primary text-white" }, {
139
139
  default: withCtx(() => [
140
140
  createVNode(unref(QToolbarTitle), null, {
141
- default: withCtx(() => _cache[1] || (_cache[1] = [
142
- createTextVNode(" Tyro Client Logs ")
143
- ])),
144
- _: 1,
145
- __: [1]
141
+ default: withCtx(() => [..._cache[1] || (_cache[1] = [
142
+ createTextVNode(" Tyro Client Logs ", -1)
143
+ ])]),
144
+ _: 1
146
145
  }),
147
146
  withDirectives(createVNode(unref(QIcon), {
148
147
  class: "float-right cursor-pointer rounded p-2 transition-colors",
@@ -234,7 +233,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
234
233
  ]),
235
234
  _cache[5] || (_cache[5] = createElementVNode("h2", { class: "mb-4 text-3xl font-bold" }, "Terminal Connected", -1)),
236
235
  createElementVNode("p", _hoisted_3, [
237
- _cache[4] || (_cache[4] = createTextVNode(" Terminal ID: ")),
236
+ _cache[4] || (_cache[4] = createTextVNode(" Terminal ID: ", -1)),
238
237
  createElementVNode("span", _hoisted_4, toDisplayString(unref(pairConfig).terminalId), 1)
239
238
  ]),
240
239
  createElementVNode("p", _hoisted_5, " Last paired: " + toDisplayString(new Date(unref(pairConfig).lastPairedDate).toLocaleString()), 1),
@@ -317,8 +316,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
317
316
  ])
318
317
  ], 32)
319
318
  ]),
320
- _: 1,
321
- __: [6]
319
+ _: 1
322
320
  }))
323
321
  ]));
324
322
  };
package/dist/index.d.ts CHANGED
@@ -1,13 +1,5 @@
1
- import { ComponentOptionsMixin } from 'vue';
2
- import { ComponentProvideOptions } from 'vue';
3
- import { DefineComponent } from 'vue';
4
1
  import { FunctionPlugin } from 'vue';
5
- import { PublicProps } from 'vue';
6
-
7
- declare type __VLS_Props = {
8
- gateway: PaymentGateways;
9
- merchantId: string | number;
10
- };
2
+ import { default as PairingInterface } from './components/PairingInterface.vue';
11
3
 
12
4
  declare const _default: {
13
5
  install: FunctionPlugin<[InstallOptions]>;
@@ -38,22 +30,7 @@ declare interface InstallOptions extends POSConfig {
38
30
  onReceiptPrint?: (receipt: string, type: ReceiptTypes) => void;
39
31
  }
40
32
 
41
- export declare const PairingInterface: DefineComponent<__VLS_Props, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
42
- "pairing-success": (data: any, gateway: PaymentGateways) => any;
43
- "pairing-failure": (data: any) => any;
44
- }, string, PublicProps, Readonly<__VLS_Props> & Readonly<{
45
- "onPairing-success"?: ((data: any, gateway: PaymentGateways) => any) | undefined;
46
- "onPairing-failure"?: ((data: any) => any) | undefined;
47
- }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
48
-
49
- declare enum PaymentGateways {
50
- Tyro = "tyro",
51
- TillPayment = "till-instore",
52
- MX51 = "mx51-spi",
53
- Linkly = "linkly",
54
- SmartPay = "smartpay",
55
- ANZ = "anz-instore"
56
- }
33
+ export { PairingInterface }
57
34
 
58
35
  declare interface POSConfig {
59
36
  productName: string;
@@ -76,3 +53,29 @@ declare enum ReceiptTypes {
76
53
  }
77
54
 
78
55
  export { }
56
+
57
+
58
+ declare global {
59
+ interface HTMLElementEventMap extends CustomEventMap {
60
+ }
61
+ interface WindowEventMap extends CustomEventMap {
62
+ }
63
+ interface DocumentEventMap extends CustomEventMap {
64
+ }
65
+ }
66
+
67
+
68
+ declare global {
69
+ interface CustomEventMap {
70
+ [TimApiEvents.TxnCompleted]: CustomEvent<{
71
+ event: timapi.TimEvent;
72
+ data: timapi.TransactionResponse;
73
+ }>;
74
+ [TimApiEvents.BalanceCompleted]: CustomEvent<{
75
+ event: timapi.TimEvent;
76
+ data: timapi.TransactionResponse;
77
+ }>;
78
+ }
79
+ interface DocumentEventMap extends CustomEventMap {
80
+ }
81
+ }
package/dist/index.js CHANGED
@@ -1,19 +1,19 @@
1
1
  import { i as isPluginInitialized, s as setState, a as setEnvironment, P as PaymentGateways } from "./PairInstructions.vue_vue_type_script_setup_true_lang-gQoPMiBm.js";
2
2
  import "quasar";
3
- import { T as TYRO_CONSTANTS, _ as _sfc_main$1 } from "./PairTyro.vue_vue_type_script_setup_true_lang-_sTaWomK.js";
3
+ import { T as TYRO_CONSTANTS, _ as _sfc_main$1 } from "./PairTyro.vue_vue_type_script_setup_true_lang-cMWE2xPj.js";
4
4
  import { defineComponent, createElementBlock, openBlock, createBlock, createCommentVNode, unref } from "vue";
5
5
  import { useEventListener, useScriptTag } from "@vueuse/core";
6
- import { s as spi, _ as _sfc_main$2 } from "./PairMX51.vue_vue_type_script_setup_true_lang-WOcvKdRl.js";
6
+ import { s as spi, _ as _sfc_main$2 } from "./PairMX51.vue_vue_type_script_setup_true_lang-Cv8VxL-t.js";
7
7
  import "@mx51/spi-client-js";
8
8
  import "uuid";
9
9
  import "./emitter-B70DsNvX.js";
10
10
  import { TimApiEvents, timApi, PairTimapi as _sfc_main$4 } from "./worldline.js";
11
11
  import "axios";
12
12
  import "./TransactionDialog.vue_vue_type_script_setup_true_lang-DTIELKw0.js";
13
- import { _ as _sfc_main$3 } from "./PairLinkly.vue_vue_type_script_setup_true_lang-DMoZH_qZ.js";
14
- import { _ as _sfc_main$6 } from "./PairSmartPay.vue_vue_type_script_setup_true_lang--WeZf2Sw.js";
13
+ import { _ as _sfc_main$3 } from "./PairLinkly.vue_vue_type_script_setup_true_lang-DrddzJ84.js";
14
+ import { _ as _sfc_main$6 } from "./PairSmartPay.vue_vue_type_script_setup_true_lang-vW3iqk9q.js";
15
15
  import "dayjs";
16
- import { _ as _sfc_main$5 } from "./PairTillPayment.vue_vue_type_script_setup_true_lang-BZgsUFdv.js";
16
+ import { _ as _sfc_main$5 } from "./PairTillPayment.vue_vue_type_script_setup_true_lang-DNK3I79n.js";
17
17
  import { g } from "./index-e4lpzJsL.js";
18
18
  var ReceiptTypes = /* @__PURE__ */ ((ReceiptTypes2) => {
19
19
  ReceiptTypes2["MERCHANT_COPY"] = "MERCHANT_COPY";
package/dist/linkly.d.ts CHANGED
@@ -1,10 +1,4 @@
1
- import { ComponentOptionsMixin } from 'vue';
2
- import { ComponentProvideOptions } from 'vue';
3
- import { DefineComponent } from 'vue';
4
- import { LinklyTransactionResponse as LinklyTransactionResponse_2 } from './linkly.types';
5
- import { PinpadPairingResult as PinpadPairingResult_2 } from './linkly.types';
6
- import { PublicProps } from 'vue';
7
- import { ReceiptReprintReturn as ReceiptReprintReturn_2 } from './linkly.types';
1
+ import { default as PairLinkly } from './PairLinkly.vue';
8
2
 
9
3
  declare interface Basket {
10
4
  id: string;
@@ -225,11 +219,7 @@ export declare type PairingClientRequestError = Array<{
225
219
  field: string;
226
220
  }>;
227
221
 
228
- export declare const PairLinkly: DefineComponent< {}, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
229
- "pairing-success": (data: PinpadPairingResult) => any;
230
- }, string, PublicProps, Readonly<{}> & Readonly<{
231
- "onPairing-success"?: ((data: PinpadPairingResult) => any) | undefined;
232
- }>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
222
+ export { PairLinkly }
233
223
 
234
224
  export declare type PinpadPairingResult = {
235
225
  success: boolean;
@@ -377,7 +367,7 @@ export declare enum TransactionTypes {
377
367
 
378
368
  export declare const useLinkly: () => {
379
369
  linklyAPI: LinklyPaymentGateway;
380
- pairPinpad: (pairData: PinpadPairPayload) => Promise<PinpadPairingResult_2>;
370
+ pairPinpad: (pairData: PinpadPairPayload) => Promise<PinpadPairingResult>;
381
371
  unpairPinpad: () => boolean;
382
372
  initiatePurchase: (data: TransactionPayload) => Promise<{
383
373
  result: TransactionOutcome;
@@ -471,9 +461,35 @@ export declare const useLinkly: () => {
471
461
  };
472
462
  };
473
463
  }>;
474
- reprintReceipt: (txnRef?: string) => Promise<ReceiptReprintReturn_2>;
475
- getTransactionBySessionId: (transactionId: string) => Promise<LinklyTransactionResponse_2>;
476
- getLastTransaction: () => Promise<LinklyTransactionResponse_2>;
464
+ reprintReceipt: (txnRef?: string) => Promise<ReceiptReprintReturn>;
465
+ getTransactionBySessionId: (transactionId: string) => Promise<LinklyTransactionResponse>;
466
+ getLastTransaction: () => Promise<LinklyTransactionResponse>;
477
467
  };
478
468
 
479
469
  export { }
470
+
471
+
472
+ declare global {
473
+ interface HTMLElementEventMap extends CustomEventMap {
474
+ }
475
+ interface WindowEventMap extends CustomEventMap {
476
+ }
477
+ interface DocumentEventMap extends CustomEventMap {
478
+ }
479
+ }
480
+
481
+
482
+ declare global {
483
+ interface CustomEventMap {
484
+ [TimApiEvents.TxnCompleted]: CustomEvent<{
485
+ event: timapi.TimEvent;
486
+ data: timapi.TransactionResponse;
487
+ }>;
488
+ [TimApiEvents.BalanceCompleted]: CustomEvent<{
489
+ event: timapi.TimEvent;
490
+ data: timapi.TransactionResponse;
491
+ }>;
492
+ }
493
+ interface DocumentEventMap extends CustomEventMap {
494
+ }
495
+ }
package/dist/linkly.js CHANGED
@@ -1,4 +1,4 @@
1
- import { C, L, _, R, a, b, T, u } from "./PairLinkly.vue_vue_type_script_setup_true_lang-DMoZH_qZ.js";
1
+ import { C, L, _, R, a, b, T, u } from "./PairLinkly.vue_vue_type_script_setup_true_lang-DrddzJ84.js";
2
2
  export {
3
3
  C as CurrencyCodes,
4
4
  L as LinklyKeyType,
package/dist/mx51.d.ts CHANGED
@@ -1,8 +1,6 @@
1
- import { ComponentOptionsMixin } from 'vue';
2
- import { ComponentProvideOptions } from 'vue';
3
- import { DefineComponent } from 'vue';
4
- import { PublicProps } from 'vue';
1
+ import { default as PairMX51 } from './PairMX51.vue';
5
2
  import { Spi } from '@mx51/spi-client-js';
3
+ import { default as TransactionDialog } from './TransactionDialog.vue';
6
4
 
7
5
  /**
8
6
  * Let the Eftpos terminal know whether merchant accepted or declined the signature
@@ -30,7 +28,7 @@ export declare function getTransaction(posRefId?: string): void;
30
28
 
31
29
  export declare function log(message: string, event?: any): void;
32
30
 
33
- export declare const PairMX51: DefineComponent< {}, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
31
+ export { PairMX51 }
34
32
 
35
33
  /**
36
34
  * Initiates a purchase transaction
@@ -101,21 +99,7 @@ export declare function settlementEnquiry(): void;
101
99
  **/
102
100
  export declare const spi: Spi;
103
101
 
104
- export declare const TransactionDialog: DefineComponent< {}, {
105
- showDialog: (amount: number, type?: string) => void;
106
- }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
107
- "transaction-success": (ev: {
108
- purchaseAmount: number;
109
- surchargeAmount?: number;
110
- tipAmount?: number;
111
- }) => any;
112
- }, string, PublicProps, Readonly<{}> & Readonly<{
113
- "onTransaction-success"?: ((ev: {
114
- purchaseAmount: number;
115
- surchargeAmount?: number;
116
- tipAmount?: number;
117
- }) => any) | undefined;
118
- }>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
102
+ export { TransactionDialog }
119
103
 
120
104
  export declare const useMX51: () => {
121
105
  initiatePurchase: (options: PurchaseOptions) => Promise<void>;
@@ -123,3 +107,29 @@ export declare const useMX51: () => {
123
107
  };
124
108
 
125
109
  export { }
110
+
111
+
112
+ declare global {
113
+ interface HTMLElementEventMap extends CustomEventMap {
114
+ }
115
+ interface WindowEventMap extends CustomEventMap {
116
+ }
117
+ interface DocumentEventMap extends CustomEventMap {
118
+ }
119
+ }
120
+
121
+
122
+ declare global {
123
+ interface CustomEventMap {
124
+ [TimApiEvents.TxnCompleted]: CustomEvent<{
125
+ event: timapi.TimEvent;
126
+ data: timapi.TransactionResponse;
127
+ }>;
128
+ [TimApiEvents.BalanceCompleted]: CustomEvent<{
129
+ event: timapi.TimEvent;
130
+ data: timapi.TransactionResponse;
131
+ }>;
132
+ }
133
+ interface DocumentEventMap extends CustomEventMap {
134
+ }
135
+ }
package/dist/mx51.js CHANGED
@@ -1,5 +1,5 @@
1
- import { s as spi, r as receiptOptions } from "./PairMX51.vue_vue_type_script_setup_true_lang-WOcvKdRl.js";
2
- import { _, l } from "./PairMX51.vue_vue_type_script_setup_true_lang-WOcvKdRl.js";
1
+ import { s as spi, r as receiptOptions } from "./PairMX51.vue_vue_type_script_setup_true_lang-Cv8VxL-t.js";
2
+ import { _, l } from "./PairMX51.vue_vue_type_script_setup_true_lang-Cv8VxL-t.js";
3
3
  import { defineComponent, ref, onMounted, resolveDirective, createBlock, openBlock, unref, withCtx, createVNode, createCommentVNode, createElementVNode, toDisplayString, withDirectives } from "vue";
4
4
  import { SuccessState, TransactionType, SpiStatus } from "@mx51/spi-client-js";
5
5
  import { v4 } from "uuid";
@@ -175,8 +175,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
175
175
  _cache[5] || (_cache[5] = createElementVNode("div", { class: "text-center font-semibold uppercase text-gray-500 dark:text-gray-300" }, " Attempting to cancel transaction ", -1)),
176
176
  createElementVNode("div", _hoisted_3, toDisplayString(pairInfo.value.message), 1)
177
177
  ]),
178
- _: 1,
179
- __: [5]
178
+ _: 1
180
179
  })) : pairInfo.value.state === "MANUAL_RECOVERY" ? (openBlock(), createBlock(unref(QCardSection), { key: 2 }, {
181
180
  default: withCtx(() => [
182
181
  _cache[6] || (_cache[6] = createElementVNode("div", { class: "text-center font-semibold uppercase text-gray-500 dark:text-gray-300" }, " Was the transaction successful ", -1)),
@@ -204,8 +203,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
204
203
  })
205
204
  ])
206
205
  ]),
207
- _: 1,
208
- __: [6, 7]
206
+ _: 1
209
207
  })) : pairInfo.value.state === "AWAITING_SIGNATURE_CHECK" ? (openBlock(), createBlock(unref(QCardSection), { key: 3 }, {
210
208
  default: withCtx(() => [
211
209
  _cache[8] || (_cache[8] = createElementVNode("div", { class: "text-center font-semibold uppercase text-gray-500 dark:text-gray-300" }, " Confirm the customer's signature ", -1)),
@@ -233,8 +231,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
233
231
  })
234
232
  ])
235
233
  ]),
236
- _: 1,
237
- __: [8]
234
+ _: 1
238
235
  })) : pairInfo.value.state === "SUCCESS" ? (openBlock(), createBlock(unref(QCardSection), { key: 4 }, {
239
236
  default: withCtx(() => [
240
237
  _cache[9] || (_cache[9] = createElementVNode("div", { class: "text-center font-semibold uppercase text-gray-500 dark:text-gray-300" }, "Transaction Successful", -1)),
@@ -250,8 +247,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
250
247
  [_directive_close_popup]
251
248
  ])
252
249
  ]),
253
- _: 1,
254
- __: [9]
250
+ _: 1
255
251
  })) : pairInfo.value.state === "FAILED" ? (openBlock(), createBlock(unref(QCardSection), { key: 5 }, {
256
252
  default: withCtx(() => [
257
253
  _cache[10] || (_cache[10] = createElementVNode("div", { class: "text-center font-semibold uppercase text-gray-500 dark:text-gray-300" }, "Transaction Failed", -1)),
@@ -268,8 +264,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
268
264
  [_directive_close_popup]
269
265
  ])
270
266
  ]),
271
- _: 1,
272
- __: [10]
267
+ _: 1
273
268
  })) : createCommentVNode("", true)
274
269
  ]),
275
270
  _: 1
@@ -1,7 +1,4 @@
1
- import { ComponentOptionsMixin } from 'vue';
2
- import { ComponentProvideOptions } from 'vue';
3
- import { DefineComponent } from 'vue';
4
- import { PublicProps } from 'vue';
1
+ import { default as PairSmartPay } from './PairSmartPay.vue';
5
2
 
6
3
  export declare const DEV_SMARTPAY_API_URL = "https://api-dev.smart-connect.cloud/POS";
7
4
 
@@ -23,7 +20,7 @@ export declare interface PairingResponse {
23
20
  result: "success";
24
21
  }
25
22
 
26
- export declare const PairSmartPay: DefineComponent< {}, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
23
+ export { PairSmartPay }
27
24
 
28
25
  export declare interface PollingResponseData {
29
26
  transactionId: string;
@@ -155,3 +152,29 @@ export declare const useSmartPay: () => {
155
152
  };
156
153
 
157
154
  export { }
155
+
156
+
157
+ declare global {
158
+ interface HTMLElementEventMap extends CustomEventMap {
159
+ }
160
+ interface WindowEventMap extends CustomEventMap {
161
+ }
162
+ interface DocumentEventMap extends CustomEventMap {
163
+ }
164
+ }
165
+
166
+
167
+ declare global {
168
+ interface CustomEventMap {
169
+ [TimApiEvents.TxnCompleted]: CustomEvent<{
170
+ event: timapi.TimEvent;
171
+ data: timapi.TransactionResponse;
172
+ }>;
173
+ [TimApiEvents.BalanceCompleted]: CustomEvent<{
174
+ event: timapi.TimEvent;
175
+ data: timapi.TransactionResponse;
176
+ }>;
177
+ }
178
+ interface DocumentEventMap extends CustomEventMap {
179
+ }
180
+ }
package/dist/smartpay.js CHANGED
@@ -1,4 +1,4 @@
1
- import { D, P, _, R, S, T, b, a, c, u } from "./PairSmartPay.vue_vue_type_script_setup_true_lang--WeZf2Sw.js";
1
+ import { D, P, _, R, S, T, b, a, c, u } from "./PairSmartPay.vue_vue_type_script_setup_true_lang-vW3iqk9q.js";
2
2
  export {
3
3
  D as DEV_SMARTPAY_API_URL,
4
4
  P as PROD_SMARTPAY_API_URL,
@@ -1,8 +1,4 @@
1
- import { ComponentOptionsMixin } from 'vue';
2
- import { ComponentProvideOptions } from 'vue';
3
- import { DefineComponent } from 'vue';
4
- import { IError as IError_2 } from './till.utils';
5
- import { PublicProps } from 'vue';
1
+ import { default as PairTillPayment } from './PairTillPayment.vue';
6
2
 
7
3
  export declare interface ErrorResponse {
8
4
  statusCode: number;
@@ -122,7 +118,7 @@ export declare interface NftIntentRequestBody {
122
118
  parentIntentId?: string;
123
119
  }
124
120
 
125
- export declare const PairTillPayment: DefineComponent< {}, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
121
+ export { PairTillPayment }
126
122
 
127
123
  export declare interface PaymentIntentRequestBody {
128
124
  /**
@@ -338,8 +334,34 @@ export declare enum TransactionType {
338
334
  export declare const useTillPayment: () => {
339
335
  initiateTillPurchase: (paymentAmount: number) => Promise<TillPaymentReturn>;
340
336
  initiateTillRefund: (paymentAmount: number) => Promise<TillPaymentReturn>;
341
- reprintReceipt: (txnId: string) => Promise<IError_2>;
337
+ reprintReceipt: (txnId: string) => Promise<IError>;
342
338
  tillPayment: TillPaymentsApi;
343
339
  };
344
340
 
345
341
  export { }
342
+
343
+
344
+ declare global {
345
+ interface HTMLElementEventMap extends CustomEventMap {
346
+ }
347
+ interface WindowEventMap extends CustomEventMap {
348
+ }
349
+ interface DocumentEventMap extends CustomEventMap {
350
+ }
351
+ }
352
+
353
+
354
+ declare global {
355
+ interface CustomEventMap {
356
+ [TimApiEvents.TxnCompleted]: CustomEvent<{
357
+ event: timapi.TimEvent;
358
+ data: timapi.TransactionResponse;
359
+ }>;
360
+ [TimApiEvents.BalanceCompleted]: CustomEvent<{
361
+ event: timapi.TimEvent;
362
+ data: timapi.TransactionResponse;
363
+ }>;
364
+ }
365
+ interface DocumentEventMap extends CustomEventMap {
366
+ }
367
+ }
@@ -1,4 +1,4 @@
1
- import { _, S, T, b, a, u } from "./PairTillPayment.vue_vue_type_script_setup_true_lang-BZgsUFdv.js";
1
+ import { _, S, T, b, a, u } from "./PairTillPayment.vue_vue_type_script_setup_true_lang-DNK3I79n.js";
2
2
  export {
3
3
  _ as PairTillPayment,
4
4
  S as SettlementTypes,
package/dist/tyro.d.ts CHANGED
@@ -1,21 +1,7 @@
1
- import { ComponentOptionsMixin } from 'vue';
2
- import { ComponentProvideOptions } from 'vue';
3
- import { DefineComponent } from 'vue';
4
- import { PublicProps } from 'vue';
1
+ import { default as ClientLogsDialog } from './ClientLogsDialog.vue';
2
+ import { default as PairTyro } from './PairTyro.vue';
5
3
 
6
- declare type __VLS_Props = {
7
- merchantId: string | number;
8
- };
9
-
10
- declare type __VLS_PublicProps = {
11
- modelValue?: boolean;
12
- };
13
-
14
- export declare const ClientLogsDialog: DefineComponent<__VLS_PublicProps, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
15
- "update:modelValue": (value: boolean | undefined) => any;
16
- }, string, PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
17
- "onUpdate:modelValue"?: ((value: boolean | undefined) => any) | undefined;
18
- }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
4
+ export { ClientLogsDialog }
19
5
 
20
6
  export declare interface PairResponse {
21
7
  /**
@@ -32,7 +18,7 @@ export declare interface PairResponse {
32
18
  integrationKey: string;
33
19
  }
34
20
 
35
- export declare const PairTyro: DefineComponent<__VLS_Props, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
21
+ export { PairTyro }
36
22
 
37
23
  export declare type PairTyroCallback = (response: PairResponse) => void;
38
24
 
@@ -172,3 +158,29 @@ export declare const useTyro: () => {
172
158
  };
173
159
 
174
160
  export { }
161
+
162
+
163
+ declare global {
164
+ interface HTMLElementEventMap extends CustomEventMap {
165
+ }
166
+ interface WindowEventMap extends CustomEventMap {
167
+ }
168
+ interface DocumentEventMap extends CustomEventMap {
169
+ }
170
+ }
171
+
172
+
173
+ declare global {
174
+ interface CustomEventMap {
175
+ [TimApiEvents.TxnCompleted]: CustomEvent<{
176
+ event: timapi.TimEvent;
177
+ data: timapi.TransactionResponse;
178
+ }>;
179
+ [TimApiEvents.BalanceCompleted]: CustomEvent<{
180
+ event: timapi.TimEvent;
181
+ data: timapi.TransactionResponse;
182
+ }>;
183
+ }
184
+ interface DocumentEventMap extends CustomEventMap {
185
+ }
186
+ }
package/dist/tyro.js CHANGED
@@ -1,4 +1,4 @@
1
- import { a, _, T, b, u } from "./PairTyro.vue_vue_type_script_setup_true_lang-_sTaWomK.js";
1
+ import { a, _, T, b, u } from "./PairTyro.vue_vue_type_script_setup_true_lang-cMWE2xPj.js";
2
2
  export {
3
3
  a as ClientLogsDialog,
4
4
  _ as PairTyro,
@@ -1,12 +1,7 @@
1
- import { ComponentOptionsMixin } from 'vue';
2
- import { ComponentProvideOptions } from 'vue';
3
- import { DefineComponent } from 'vue';
4
1
  import { EventBus } from 'quasar';
5
- import { PublicProps } from 'vue';
6
-
7
- declare type __VLS_PublicProps = {
8
- modelValue?: boolean;
9
- };
2
+ import { default as PairTimapi } from './PairTimapi.vue';
3
+ import { default as TimApiDialog } from './TimApiDialog.vue';
4
+ import { default as TimApiLogs } from './TimApiLogs.vue';
10
5
 
11
6
  declare class AdvanceEcr {
12
7
  private _config;
@@ -61,7 +56,7 @@ declare interface PairingInput {
61
56
  autoCommit?: boolean;
62
57
  }
63
58
 
64
- export declare const PairTimapi: DefineComponent< {}, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
59
+ export { PairTimapi }
65
60
 
66
61
  export declare const timApi: AdvanceEcr;
67
62
 
@@ -73,18 +68,14 @@ declare interface TimApiConfig {
73
68
  integratorId: string;
74
69
  }
75
70
 
76
- export declare const TimApiDialog: DefineComponent< {}, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
71
+ export { TimApiDialog }
77
72
 
78
73
  export declare const TimApiEvents: Readonly<{
79
74
  TxnCompleted: "timTxnCompleted";
80
75
  BalanceCompleted: "timBalanceCompleted";
81
76
  }>;
82
77
 
83
- export declare const TimApiLogs: DefineComponent<__VLS_PublicProps, void, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
84
- "update:modelValue": (value: boolean | undefined) => any;
85
- }, string, PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
86
- "onUpdate:modelValue"?: ((value: boolean | undefined) => any) | undefined;
87
- }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
78
+ export { TimApiLogs }
88
79
 
89
80
  export declare const TransactionTypes: {
90
81
  Purchase: timapi.EnumValue;
@@ -92,3 +83,29 @@ export declare const TransactionTypes: {
92
83
  };
93
84
 
94
85
  export { }
86
+
87
+
88
+ declare global {
89
+ interface HTMLElementEventMap extends CustomEventMap {
90
+ }
91
+ interface WindowEventMap extends CustomEventMap {
92
+ }
93
+ interface DocumentEventMap extends CustomEventMap {
94
+ }
95
+ }
96
+
97
+
98
+ declare global {
99
+ interface CustomEventMap {
100
+ [TimApiEvents.TxnCompleted]: CustomEvent<{
101
+ event: timapi.TimEvent;
102
+ data: timapi.TransactionResponse;
103
+ }>;
104
+ [TimApiEvents.BalanceCompleted]: CustomEvent<{
105
+ event: timapi.TimEvent;
106
+ data: timapi.TransactionResponse;
107
+ }>;
108
+ }
109
+ interface DocumentEventMap extends CustomEventMap {
110
+ }
111
+ }
package/dist/worldline.js CHANGED
@@ -501,8 +501,7 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
501
501
  ripple: false
502
502
  }))
503
503
  ]),
504
- _: 1,
505
- __: [3]
504
+ _: 1
506
505
  }),
507
506
  createVNode(unref(QDialog), {
508
507
  modelValue: model.value,
@@ -668,8 +667,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
668
667
  _cache[2] || (_cache[2] = createElementVNode("div", { class: "text-center font-semibold uppercase text-gray-500" }, "Attempting to cancel transaction", -1)),
669
668
  createElementVNode("div", _hoisted_7, toDisplayString(pairInfo.value.message), 1)
670
669
  ]),
671
- _: 1,
672
- __: [2]
670
+ _: 1
673
671
  })) : pairInfo.value.state === "SUCCESS" ? (openBlock(), createBlock(unref(QCardSection), { key: 2 }, {
674
672
  default: withCtx(() => [
675
673
  createElementVNode("div", _hoisted_8, toDisplayString(pairInfo.value.message), 1),
@@ -694,8 +692,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
694
692
  [_directive_close_popup]
695
693
  ])
696
694
  ]),
697
- _: 1,
698
- __: [3]
695
+ _: 1
699
696
  })) : createCommentVNode("", true)
700
697
  ]),
701
698
  _: 1
@@ -740,11 +737,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
740
737
  createVNode(unref(QToolbar), { class: "bg-primary text-white" }, {
741
738
  default: withCtx(() => [
742
739
  createVNode(unref(QToolbarTitle), null, {
743
- default: withCtx(() => _cache[4] || (_cache[4] = [
744
- createTextVNode(" Tim API Logs ")
745
- ])),
746
- _: 1,
747
- __: [4]
740
+ default: withCtx(() => [..._cache[4] || (_cache[4] = [
741
+ createTextVNode(" Tim API Logs ", -1)
742
+ ])]),
743
+ _: 1
748
744
  }),
749
745
  withDirectives(createVNode(unref(QIcon), {
750
746
  class: "float-right cursor-pointer rounded p-2 transition-colors",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@achyutlabsau/vue-payment-gateway",
3
3
  "private": false,
4
- "version": "0.7.1",
4
+ "version": "0.8.0",
5
5
  "type": "module",
6
6
  "repository": {
7
7
  "type": "git",
@@ -56,12 +56,12 @@
56
56
  },
57
57
  "dependencies": {
58
58
  "@mx51/spi-client-js": "^2.9.13",
59
- "@vueuse/core": "^13.5",
60
- "@vueuse/rxjs": "^13.5.0",
61
- "axios": "1.10.0",
62
- "dayjs": "1.11.13",
63
- "dexie": "^4.0.11",
64
- "uuid": "^11.1.0"
59
+ "@vueuse/core": "^13.9",
60
+ "@vueuse/rxjs": "^13.9.0",
61
+ "axios": "1.12.2",
62
+ "dayjs": "1.11.18",
63
+ "dexie": "^4.2.0",
64
+ "uuid": "^13.0.0"
65
65
  },
66
66
  "peerDependencies": {
67
67
  "@vueuse/core": ">=13",
@@ -72,21 +72,21 @@
72
72
  "vue": ">=3.3.0"
73
73
  },
74
74
  "devDependencies": {
75
- "@microsoft/api-extractor": "^7.52.8",
75
+ "@microsoft/api-extractor": "^7.52.13",
76
76
  "@quasar/extras": "^1.17.0",
77
- "@tailwindcss/vite": "^4.1.11",
77
+ "@tailwindcss/vite": "^4.1.13",
78
78
  "@types/node": "*",
79
- "@vitejs/plugin-vue": "^6.0.0",
80
- "@vue/language-core": "^3.0.3",
79
+ "@vitejs/plugin-vue": "^6.0.1",
80
+ "@vue/language-core": "^3.0.7",
81
81
  "prettier": "^3.6.2",
82
82
  "prettier-plugin-tailwindcss": "^0.6.14",
83
- "quasar": "^2.18.2",
84
- "tailwindcss": "^4.1.11",
85
- "typescript": "5.8.3",
86
- "unplugin-dts": "^1.0.0-beta.4",
87
- "vite": "^7.0.5",
83
+ "quasar": "^2.18.5",
84
+ "tailwindcss": "^4.1.13",
85
+ "typescript": "5.8.2",
86
+ "unplugin-dts": "^1.0.0-beta.6",
87
+ "vite": "^7.1.6",
88
88
  "vitepress": "^2.0.0-alpha.8",
89
- "vue": "^3.5.17",
90
- "vue-tsc": "^3.0.3"
89
+ "vue": "^3.5.21",
90
+ "vue-tsc": "^3.0.7"
91
91
  }
92
92
  }