@tonder.io/ionic-lite-sdk 0.0.35-beta.23 → 0.0.35-beta.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.
@@ -27,8 +27,7 @@ import {
27
27
  StartCheckoutResponse,
28
28
  } from "./responses";
29
29
 
30
- export class LiteCheckout {
31
- constructor(options: IInlineLiteCheckoutOptions);
30
+ export interface ILiteCheckout {
32
31
 
33
32
  /**
34
33
  * The configureCheckout function allows you to set initial information, such as the customer's email, which is used to retrieve a list of saved cards.
@@ -62,10 +61,10 @@ export class LiteCheckout {
62
61
 
63
62
  /**
64
63
  * Verifies the 3DS transaction status.
65
- * @returns {Promise<import("./index").ITransaction | void>} The result of the 3DS verification and checkout resumption.
64
+ * @returns {Promise<import("./index").ITransaction | import("./index").IStartCheckoutResponse | void>} The result of the 3DS verification and checkout resumption.
66
65
  * @public
67
66
  */
68
- verify3dsTransaction(): Promise<ITransaction | void>;
67
+ verify3dsTransaction(): Promise<ITransaction | IStartCheckoutResponse | void>;
69
68
 
70
69
  /**
71
70
  * Retrieves the list of cards associated with a customer.
@@ -189,7 +188,7 @@ export class LiteCheckout {
189
188
 
190
189
  /**
191
190
  * @deprecated This method is deprecated and will be removed in a future release.
192
- * It is no longer necessary to use this method as customer registration is now automatically handled
191
+ * It is no longer necessary to use this method as card registration or as checkout is now automatically handled
193
192
  * during the payment process or when using card management methods.
194
193
  */
195
194
  getSkyflowTokens({
@@ -210,5 +209,3 @@ export class LiteCheckout {
210
209
  ): Promise<string | ErrorResponse>;
211
210
  }
212
211
 
213
- export interface IInlineLiteCheckoutOptions
214
- extends IInlineCheckoutBaseOptions {}
@@ -1,7 +1,7 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
4
3
  import { constructorFields } from "../utils/defaultMock";
4
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
5
5
 
6
6
  declare global {
7
7
  interface Window {
@@ -11,7 +11,7 @@ declare global {
11
11
  }
12
12
 
13
13
  describe("LiteCheckout", () => {
14
- let checkoutConstructor: LiteCheckoutConstructor,
14
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
15
15
  liteCheckout: LiteCheckout,
16
16
  fetchSpy: jest.SpyInstance,
17
17
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,9 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
3
  import { ErrorResponse } from "../../src/classes/errorResponse";
4
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
5
- import { IErrorResponse } from "../../src/types/responses";
6
4
  import { constructorFields } from "../utils/defaultMock";
7
- import { OrderResponseClass, OrderClass, OrderClassEmptyValues, OrderEmptyValuesResponse } from "../utils/mockClasses";
5
+ import { OrderResponseClass, OrderClass, OrderEmptyValuesResponse } from "../utils/mockClasses";
6
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
7
 
9
8
  declare global {
10
9
  interface Window {
@@ -14,7 +13,7 @@ declare global {
14
13
  }
15
14
 
16
15
  describe("createOrder", () => {
17
- let checkoutConstructor: LiteCheckoutConstructor,
16
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
18
17
  liteCheckout: LiteCheckout,
19
18
  fetchSpy: jest.SpyInstance,
20
19
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,9 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
3
  import { ErrorResponse } from "../../src/classes/errorResponse";
4
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
5
- import { IErrorResponse } from "../../src/types/responses";
6
4
  import { constructorFields } from "../utils/defaultMock";
7
5
  import { CreatePaymentResponseClass, CreatePaymentRequestClass } from "../utils/mockClasses";
6
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
7
 
9
8
 
10
9
  declare global {
@@ -15,7 +14,7 @@ declare global {
15
14
  }
16
15
 
17
16
  describe("createPayment", () => {
18
- let checkoutConstructor: LiteCheckoutConstructor,
17
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
19
18
  liteCheckout: LiteCheckout,
20
19
  fetchSpy: jest.SpyInstance,
21
20
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,9 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
3
  import { ErrorResponse } from "../../src/classes/errorResponse";
4
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
5
- import { IErrorResponse } from "../../src/types/responses";
6
4
  import { constructorFields } from "../utils/defaultMock";
7
- import { BusinessClass, CustomerRegisterClass } from "../utils/mockClasses";
5
+ import { CustomerRegisterClass } from "../utils/mockClasses";
6
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
7
 
9
8
 
10
9
  declare global {
@@ -15,7 +14,7 @@ declare global {
15
14
  }
16
15
 
17
16
  describe("customerRegister", () => {
18
- let checkoutConstructor: LiteCheckoutConstructor,
17
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
19
18
  liteCheckout: LiteCheckout,
20
19
  fetchSpy: jest.SpyInstance,
21
20
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,9 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
3
  import { ErrorResponse } from "../../src/classes/errorResponse";
4
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
5
- import { IErrorResponse } from "../../src/types/responses";
6
4
  import { constructorFields } from "../utils/defaultMock";
7
5
  import { BusinessClass } from "../utils/mockClasses";
6
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
7
 
9
8
  declare global {
10
9
  interface Window {
@@ -14,7 +13,7 @@ declare global {
14
13
  }
15
14
 
16
15
  describe("getBusiness", () => {
17
- let checkoutConstructor: LiteCheckoutConstructor,
16
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
18
17
  liteCheckout: LiteCheckout,
19
18
  fetchSpy: jest.SpyInstance,
20
19
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,9 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
3
  import { ErrorResponse } from "../../src/classes/errorResponse";
4
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
5
- import { IErrorResponse } from "../../src/types/responses";
6
4
  import { constructorFields } from "../utils/defaultMock";
7
5
  import { GetCustomerCardsResponseClass } from "../utils/mockClasses";
6
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
7
 
9
8
  declare global {
10
9
  interface Window {
@@ -14,7 +13,7 @@ declare global {
14
13
  }
15
14
 
16
15
  describe("getCustomerCards", () => {
17
- let checkoutConstructor: LiteCheckoutConstructor,
16
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
18
17
  liteCheckout: LiteCheckout,
19
18
  fetchSpy: jest.SpyInstance,
20
19
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,10 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
4
3
  import { constructorFields } from "../utils/defaultMock";
5
4
  import { RegisterCustomerCardRequestClass, RegisterCustomerCardResponseClass } from "../utils/mockClasses";
6
5
  import { ErrorResponse } from "../../src/classes/errorResponse";
7
6
  import { IErrorResponse } from "../../src/types/responses";
7
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
8
 
9
9
  declare global {
10
10
  interface Window {
@@ -14,7 +14,7 @@ declare global {
14
14
  }
15
15
 
16
16
  describe("registerCustomerCard", () => {
17
- let checkoutConstructor: LiteCheckoutConstructor,
17
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
18
18
  liteCheckout: LiteCheckout,
19
19
  fetchSpy: jest.SpyInstance,
20
20
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,10 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
3
  import { ErrorResponse } from "../../src/classes/errorResponse";
4
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
5
4
  import { IErrorResponse } from "../../src/types/responses";
6
5
  import { constructorFields } from "../utils/defaultMock";
7
6
  import { StartCheckoutResponseClass, StartCheckoutRequestClass, CreatePaymentRequestClass } from "../utils/mockClasses";
7
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
8
 
9
9
  declare global {
10
10
  interface Window {
@@ -14,7 +14,7 @@ declare global {
14
14
  }
15
15
 
16
16
  describe("startCheckoutRouter", () => {
17
- let checkoutConstructor: LiteCheckoutConstructor,
17
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
18
18
  liteCheckout: LiteCheckout,
19
19
  fetchSpy: jest.SpyInstance,
20
20
  liteCheckoutSpy: jest.SpyInstance;
@@ -1,10 +1,10 @@
1
1
  import "../utils/defaultMock";
2
2
  import { LiteCheckout } from "../../src";
3
3
  import { ErrorResponse } from "../../src/classes/errorResponse";
4
- import { LiteCheckoutConstructor } from "../../src/classes/liteCheckout";
5
4
  import { IErrorResponse } from "../../src/types/responses";
6
5
  import { constructorFields } from "../utils/defaultMock";
7
6
  import { StartCheckoutResponseClass, StartCheckoutFullRequestClass, BusinessClass, CustomerRegisterClass, OrderResponseClass, CreatePaymentResponseClass } from "../utils/mockClasses";
7
+ import {IInlineLiteCheckoutOptions} from "../../src/types/commons";
8
8
 
9
9
  declare global {
10
10
  interface Window {
@@ -14,7 +14,7 @@ declare global {
14
14
  }
15
15
 
16
16
  describe("startCheckoutRouterFull", () => {
17
- let checkoutConstructor: LiteCheckoutConstructor,
17
+ let checkoutConstructor: IInlineLiteCheckoutOptions,
18
18
  liteCheckout: LiteCheckout,
19
19
  fetchSpy: jest.SpyInstance,
20
20
  liteCheckoutSpy: jest.SpyInstance;
package/.idea/aws.xml DELETED
@@ -1,17 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="accountSettings">
4
- <option name="activeProfile" value="profile:default" />
5
- <option name="activeRegion" value="us-east-1" />
6
- <option name="recentlyUsedProfiles">
7
- <list>
8
- <option value="profile:default" />
9
- </list>
10
- </option>
11
- <option name="recentlyUsedRegions">
12
- <list>
13
- <option value="us-east-1" />
14
- </list>
15
- </option>
16
- </component>
17
- </project>
@@ -1,6 +0,0 @@
1
- <component name="InspectionProjectProfileManager">
2
- <profile version="1.0">
3
- <option name="myName" value="Project Default" />
4
- <inspection_tool class="TsLint" enabled="true" level="WARNING" enabled_by_default="true" />
5
- </profile>
6
- </component>
@@ -1,6 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="PrettierConfiguration">
4
- <option name="myConfigurationMode" value="AUTOMATIC" />
5
- </component>
6
- </project>
package/.idea/vcs.xml DELETED
@@ -1,6 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="VcsDirectoryMappings">
4
- <mapping directory="" vcs="Git" />
5
- </component>
6
- </project>
@@ -1,127 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="AutoImportSettings">
4
- <option name="autoReloadType" value="SELECTIVE" />
5
- </component>
6
- <component name="ChangeListManager">
7
- <list default="true" id="49ce0c58-6ae2-4b0a-9ac0-48692c69c15e" name="Changes" comment="">
8
- <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
9
- <change beforePath="$PROJECT_DIR$/package-lock.json" beforeDir="false" afterPath="$PROJECT_DIR$/package-lock.json" afterDir="false" />
10
- <change beforePath="$PROJECT_DIR$/package.json" beforeDir="false" afterPath="$PROJECT_DIR$/package.json" afterDir="false" />
11
- <change beforePath="$PROJECT_DIR$/src/classes/BaseInlineCheckout.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/classes/BaseInlineCheckout.ts" afterDir="false" />
12
- <change beforePath="$PROJECT_DIR$/src/classes/errorResponse.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/classes/errorResponse.ts" afterDir="false" />
13
- <change beforePath="$PROJECT_DIR$/src/classes/liteCheckout.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/classes/liteCheckout.ts" afterDir="false" />
14
- <change beforePath="$PROJECT_DIR$/src/data/businessApi.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/data/businessApi.ts" afterDir="false" />
15
- <change beforePath="$PROJECT_DIR$/src/data/cardApi.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/data/cardApi.ts" afterDir="false" />
16
- <change beforePath="$PROJECT_DIR$/src/data/checkoutApi.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/data/checkoutApi.ts" afterDir="false" />
17
- <change beforePath="$PROJECT_DIR$/src/data/customerApi.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/data/customerApi.ts" afterDir="false" />
18
- <change beforePath="$PROJECT_DIR$/src/data/paymentMethodApi.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/data/paymentMethodApi.ts" afterDir="false" />
19
- <change beforePath="$PROJECT_DIR$/src/helpers/skyflow.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/helpers/skyflow.ts" afterDir="false" />
20
- <change beforePath="$PROJECT_DIR$/src/helpers/utils.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/helpers/utils.ts" afterDir="false" />
21
- <change beforePath="$PROJECT_DIR$/src/index.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/index.ts" afterDir="false" />
22
- <change beforePath="$PROJECT_DIR$/src/types/card.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/types/card.ts" afterDir="false" />
23
- <change beforePath="$PROJECT_DIR$/src/types/checkout.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/types/checkout.ts" afterDir="false" />
24
- <change beforePath="$PROJECT_DIR$/src/types/commons.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/types/commons.ts" afterDir="false" />
25
- <change beforePath="$PROJECT_DIR$/src/types/index.d.ts" beforeDir="false" />
26
- </list>
27
- <option name="SHOW_DIALOG" value="false" />
28
- <option name="HIGHLIGHT_CONFLICTS" value="true" />
29
- <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
30
- <option name="LAST_RESOLUTION" value="IGNORE" />
31
- </component>
32
- <component name="Git.Settings">
33
- <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
34
- </component>
35
- <component name="MarkdownSettingsMigration">
36
- <option name="stateVersion" value="1" />
37
- </component>
38
- <component name="ProjectColorInfo">{
39
- &quot;customColor&quot;: &quot;&quot;,
40
- &quot;associatedIndex&quot;: 1
41
- }</component>
42
- <component name="ProjectId" id="2lFWiEUFmmZczyeFIMfy8VbaFup" />
43
- <component name="ProjectViewState">
44
- <option name="autoscrollFromSource" value="true" />
45
- <option name="autoscrollToSource" value="true" />
46
- <option name="hideEmptyMiddlePackages" value="true" />
47
- <option name="showLibraryContents" value="true" />
48
- </component>
49
- <component name="PropertiesComponent"><![CDATA[{
50
- "keyToString": {
51
- "RunOnceActivity.OpenProjectViewOnStart": "true",
52
- "RunOnceActivity.ShowReadmeOnStart": "true",
53
- "git-widget-placeholder": "main",
54
- "last_opened_file_path": "/Users/davidhernandezalmagro/Desktop/Tonder/ionic-lite/src/types",
55
- "node.js.detected.package.eslint": "true",
56
- "node.js.detected.package.tslint": "true",
57
- "node.js.selected.package.eslint": "(autodetect)",
58
- "node.js.selected.package.tslint": "(autodetect)",
59
- "nodejs_package_manager_path": "npm",
60
- "prettierjs.PrettierConfiguration.Package": "/Users/davidhernandezalmagro/.nvm/versions/node/v21.2.0/lib/node_modules/prettier",
61
- "settings.editor.selected.configurable": "settings.javascript.prettier",
62
- "ts.external.directory.path": "/Users/davidhernandezalmagro/Desktop/Tonder/ionic-lite/node_modules/typescript/lib",
63
- "vue.rearranger.settings.migration": "true"
64
- }
65
- }]]></component>
66
- <component name="RecentsManager">
67
- <key name="CopyFile.RECENT_KEYS">
68
- <recent name="$PROJECT_DIR$/src/types" />
69
- </key>
70
- <key name="MoveFile.RECENT_KEYS">
71
- <recent name="$PROJECT_DIR$/src" />
72
- <recent name="$PROJECT_DIR$" />
73
- </key>
74
- </component>
75
- <component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
76
- <component name="TaskManager">
77
- <task active="true" id="Default" summary="Default task">
78
- <changelist id="49ce0c58-6ae2-4b0a-9ac0-48692c69c15e" name="Changes" comment="" />
79
- <created>1724776429568</created>
80
- <option name="number" value="Default" />
81
- <option name="presentableId" value="Default" />
82
- <updated>1724776429568</updated>
83
- <workItem from="1724776430626" duration="1847000" />
84
- <workItem from="1724790840744" duration="239000" />
85
- <workItem from="1725305433705" duration="21026000" />
86
- <workItem from="1725333899382" duration="2939000" />
87
- <workItem from="1725337022494" duration="3671000" />
88
- <workItem from="1725378545854" duration="14964000" />
89
- </task>
90
- <servers />
91
- </component>
92
- <component name="TypeScriptGeneratedFilesManager">
93
- <option name="version" value="3" />
94
- </component>
95
- <component name="Vcs.Log.Tabs.Properties">
96
- <option name="TAB_STATES">
97
- <map>
98
- <entry key="MAIN">
99
- <value>
100
- <State />
101
- </value>
102
- </entry>
103
- </map>
104
- </option>
105
- </component>
106
- <component name="XDebuggerManager">
107
- <breakpoint-manager>
108
- <breakpoints>
109
- <line-breakpoint enabled="true" type="javascript">
110
- <url>file://$PROJECT_DIR$/src/classes/liteCheckout.ts</url>
111
- <line>219</line>
112
- <option name="timeStamp" value="16" />
113
- </line-breakpoint>
114
- <line-breakpoint enabled="true" type="javascript">
115
- <url>file://$PROJECT_DIR$/src/types/commons.ts</url>
116
- <line>107</line>
117
- <option name="timeStamp" value="17" />
118
- </line-breakpoint>
119
- <line-breakpoint enabled="true" type="javascript">
120
- <url>file://$PROJECT_DIR$/src/classes/liteCheckout.ts</url>
121
- <line>223</line>
122
- <option name="timeStamp" value="18" />
123
- </line-breakpoint>
124
- </breakpoints>
125
- </breakpoint-manager>
126
- </component>
127
- </project>