mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2026-07-16 00:00:04 +08:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2377b979ad | ||
|
|
0e3304e00e | ||
|
|
e2c7c93fed | ||
|
|
3fcaed8c46 | ||
|
|
83cb98f115 | ||
|
|
f64b67310a | ||
|
|
944d25147f | ||
|
|
4f13426a6d | ||
|
|
c5d606633e | ||
|
|
9dd719bb07 | ||
|
|
0dcbace822 | ||
|
|
383a88463a | ||
|
|
5a42e8cadf | ||
|
|
f19ddc7cde | ||
|
|
7736ca7747 |
@@ -1,3 +1,22 @@
|
||||
# [5.34.0](https://github.com/ionic-team/ionic-native/compare/v5.33.1...v5.34.0) (2021-06-29)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **android-full-screen:** add correct return type ([#3677](https://github.com/ionic-team/ionic-native/issues/3677)) ([c5d6066](https://github.com/ionic-team/ionic-native/commit/c5d606633e0ce69c94eb99d205c655c5a0d94523)), closes [/github.com/mesmotronic/cordova-plugin-fullscreen/blob/master/src/android/com/mesmotronic/plugins/FullScreenPlugin.java#L129](https://github.com//github.com/mesmotronic/cordova-plugin-fullscreen/blob/master/src/android/com/mesmotronic/plugins/FullScreenPlugin.java/issues/L129)
|
||||
* **mobile-messaging:** revision of optional parameters ([#3667](https://github.com/ionic-team/ionic-native/issues/3667)) ([944d251](https://github.com/ionic-team/ionic-native/commit/944d25147f2c0b89d0e7acb1fa1a6fe7fa4941f7))
|
||||
* **smartlook:** fix SmartlookResetSession.resetUser type to boolean ([#3692](https://github.com/ionic-team/ionic-native/issues/3692)) ([5a42e8c](https://github.com/ionic-team/ionic-native/commit/5a42e8cadfc0d5269c4e06149c2d1ecf4ad721f7))
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **branch-io:** add sendBranchEvent method; deprecated sendCommerceEvent ([#3675](https://github.com/ionic-team/ionic-native/issues/3675)) ([4f13426](https://github.com/ionic-team/ionic-native/commit/4f13426a6dd820880f21c6e52a30a4db5f0c5c0a))
|
||||
* **checkout:** add plugin ([#3687](https://github.com/ionic-team/ionic-native/issues/3687)) ([0dcbace](https://github.com/ionic-team/ionic-native/commit/0dcbace8223c5c9a4c3474c7bff291e00da06b0b))
|
||||
* **in-app-purchase-2:** added manageBilling method ([#3690](https://github.com/ionic-team/ionic-native/issues/3690)) ([383a884](https://github.com/ionic-team/ionic-native/commit/383a88463a16b47da8aeb79707f342411028f889))
|
||||
* **paytabs:** add plugin ([#3678](https://github.com/ionic-team/ionic-native/issues/3678)) ([9dd719b](https://github.com/ionic-team/ionic-native/commit/9dd719bb07a1278f38e188fa075283e54e0654d1))
|
||||
|
||||
|
||||
|
||||
## [5.33.1](https://github.com/ionic-team/ionic-native/compare/v5.33.0...v5.33.1) (2021-05-28)
|
||||
|
||||
|
||||
|
||||
Generated
+587
-605
File diff suppressed because it is too large
Load Diff
+9
-9
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "ionic-native",
|
||||
"version": "5.33.1",
|
||||
"version": "5.34.0",
|
||||
"description": "Native plugin wrappers for Cordova and Ionic with TypeScript, ES6+, Promise and Observable support",
|
||||
"homepage": "https://ionicframework.com/",
|
||||
"author": "Ionic Team <hi@ionic.io> (https://ionic.io)",
|
||||
@@ -24,7 +24,7 @@
|
||||
"prettier": "prettier src/**/* --write"
|
||||
},
|
||||
"dependencies": {
|
||||
"tslib": "^2.2.0"
|
||||
"tslib": "^2.3.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@angular/common": "^11.2.14",
|
||||
@@ -35,7 +35,7 @@
|
||||
"@types/fs-extra": "^9.0.11",
|
||||
"@types/jest": "^26.0.23",
|
||||
"@types/lodash": "^4.14.170",
|
||||
"@types/node": "^12.20.13",
|
||||
"@types/node": "^12.20.15",
|
||||
"@types/rimraf": "^3.0.0",
|
||||
"@types/webpack": "^5.28.0",
|
||||
"async-promise-queue": "^1.0.5",
|
||||
@@ -50,26 +50,26 @@
|
||||
"gulp-tslint": "^8.1.4",
|
||||
"husky": "^6.0.0",
|
||||
"is-ci": "^3.0.0",
|
||||
"jest": "^27.0.1",
|
||||
"jest": "^27.0.6",
|
||||
"lint-staged": "^11.0.0",
|
||||
"lodash": "^4.17.21",
|
||||
"minimist": "^1.2.5",
|
||||
"natives": "^1.1.6",
|
||||
"prettier": "^2.3.0",
|
||||
"prettier": "^2.3.2",
|
||||
"rimraf": "^3.0.2",
|
||||
"rollup": "^2.50.3",
|
||||
"rollup": "^2.52.3",
|
||||
"rxjs": "^6.6.7",
|
||||
"ts-jest": "^27.0.1",
|
||||
"ts-jest": "^27.0.3",
|
||||
"ts-node": "^10.0.0",
|
||||
"tslint": "~6.1.0",
|
||||
"tslint-config-prettier": "^1.18.0",
|
||||
"tslint-ionic-rules": "0.0.21",
|
||||
"typedoc": "^0.18.0",
|
||||
"typescript": "~4.1.5",
|
||||
"typescript": "^4.1.6",
|
||||
"typescript-tslint-plugin": "^1.0.1",
|
||||
"uglifyjs-webpack-plugin": "^2.2.0",
|
||||
"unminified-webpack-plugin": "^3.0.0",
|
||||
"webpack": "^5.38.1",
|
||||
"webpack": "^5.41.0",
|
||||
"winston": "^3.3.3",
|
||||
"zone.js": "^0.11.4"
|
||||
},
|
||||
|
||||
@@ -71,7 +71,7 @@ export class AndroidFullScreen extends IonicNativePlugin {
|
||||
* @return {Promise<void>}
|
||||
*/
|
||||
@Cordova()
|
||||
isImmersiveModeSupported(): Promise<void> {
|
||||
isImmersiveModeSupported(): Promise<boolean> {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -89,16 +89,6 @@ export interface AppRatePreferences {
|
||||
*/
|
||||
showPromptForInAppReview?: boolean;
|
||||
|
||||
/**
|
||||
* leave app or no when application page opened in app store (now supported only for iOS). Defaults to `false`
|
||||
*/
|
||||
inAppReview?: boolean;
|
||||
|
||||
/**
|
||||
* use custom view for rate dialog. Defaults to `false`
|
||||
*/
|
||||
useCustomRateDialog?: boolean;
|
||||
|
||||
/**
|
||||
* Custom locale object
|
||||
*/
|
||||
@@ -158,7 +148,7 @@ export interface AppRateCustomLocale {
|
||||
export interface AppRateLocales {
|
||||
addLocale(localeObject: AppRateCustomLocale): AppRateCustomLocale;
|
||||
|
||||
getLocale(language: string, applicationTitle?: string, customLocale?: AppRateCustomLocale);
|
||||
getLocale(language: string, applicationTitle?: string, customLocale?: AppRateCustomLocale): AppRateCustomLocale;
|
||||
|
||||
getLocalesNames(): { [prop: string]: AppRateCustomLocale };
|
||||
}
|
||||
|
||||
@@ -184,6 +184,7 @@ export class BranchIo extends IonicNativePlugin {
|
||||
|
||||
/**
|
||||
* Send Commerce Event
|
||||
* @deprecated since v.3.1.0. As of https://help.branch.io/developers-hub/docs/cordova-phonegap-ionic#track-commerce
|
||||
* @param {string} event
|
||||
* @param {any} metaData
|
||||
* @return {Promise<any>}
|
||||
@@ -193,6 +194,17 @@ export class BranchIo extends IonicNativePlugin {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Send Branch Event
|
||||
* @param {string} event
|
||||
* @param {any} metaData
|
||||
* @return {Promise<any>}
|
||||
*/
|
||||
@Cordova({ otherPromise: true })
|
||||
sendBranchEvent(event: string, metaData: any): Promise<any> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* create a branchUniversalObj variable to reference with other Branch methods
|
||||
* @param {BranchIoProperties} properties
|
||||
|
||||
@@ -0,0 +1,221 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Plugin, Cordova, IonicNativePlugin } from '@ionic-native/core';
|
||||
|
||||
export interface CkoCardTokenRequest {
|
||||
/**
|
||||
* The card number
|
||||
*/
|
||||
number: string;
|
||||
/**
|
||||
* The expiry month of the card
|
||||
*/
|
||||
expiry_month: string;
|
||||
/**
|
||||
* The expiry year of the card
|
||||
*/
|
||||
expiry_year: string;
|
||||
/**
|
||||
* The card verification value/code. 3 digits, except for Amex (4 digits)
|
||||
*/
|
||||
cvv?: string;
|
||||
/**
|
||||
* The cardholder's name
|
||||
*/
|
||||
name?: string;
|
||||
/**
|
||||
* The cardholder's billing address
|
||||
*/
|
||||
billing_address?: Address;
|
||||
/**
|
||||
* The cardholder's phone number
|
||||
*/
|
||||
phone?: Phone;
|
||||
}
|
||||
|
||||
export interface CkoCardTokenResponse {
|
||||
/**
|
||||
* The token type
|
||||
*/
|
||||
type: string;
|
||||
/**
|
||||
* The token value
|
||||
*/
|
||||
token: string;
|
||||
/**
|
||||
* The expiration datetime of the token
|
||||
*/
|
||||
expires_on: string;
|
||||
/**
|
||||
* The expiry month of the card
|
||||
*/
|
||||
expiry_month: number;
|
||||
/**
|
||||
* The expiry year of the card
|
||||
*/
|
||||
expiry_year: number;
|
||||
/**
|
||||
* The cardholder's name
|
||||
*/
|
||||
name: string;
|
||||
/**
|
||||
* The card scheme
|
||||
*/
|
||||
scheme: string;
|
||||
/**
|
||||
* The last 4 digit of the card number
|
||||
*/
|
||||
last4: string;
|
||||
/**
|
||||
* The bin range of the card
|
||||
*/
|
||||
bin: string;
|
||||
/**
|
||||
* The card type
|
||||
*/
|
||||
card_type: string;
|
||||
/**
|
||||
* The card category
|
||||
*/
|
||||
card_category: string;
|
||||
/**
|
||||
* The card issuer name
|
||||
*/
|
||||
issuer: string;
|
||||
/**
|
||||
* The card issuer country (two-letter ISO)
|
||||
*/
|
||||
issuer_country: string;
|
||||
/**
|
||||
* The card product id
|
||||
*/
|
||||
product_id: string;
|
||||
/**
|
||||
* The card product type
|
||||
*/
|
||||
product_type: string;
|
||||
/**
|
||||
* The cardholder's billing address
|
||||
*/
|
||||
billing_address: Address;
|
||||
/**
|
||||
* The cardholder's phone number
|
||||
*/
|
||||
phone: Phone;
|
||||
}
|
||||
|
||||
export interface Address {
|
||||
/**
|
||||
* The first line of the address
|
||||
*/
|
||||
address_line1?: string;
|
||||
/**
|
||||
* The second line of the address
|
||||
*/
|
||||
address_line2?: string;
|
||||
/**
|
||||
* The address city
|
||||
*/
|
||||
city?: string;
|
||||
/**
|
||||
* The address state
|
||||
*/
|
||||
state?: string;
|
||||
/**
|
||||
* The address zip/postal code
|
||||
*/
|
||||
zip?: string;
|
||||
/**
|
||||
* The two-letter ISO country code of the address
|
||||
*/
|
||||
country?: string;
|
||||
}
|
||||
|
||||
export interface Phone {
|
||||
/**
|
||||
* The international country calling code. Required for some risk checks
|
||||
*/
|
||||
country_code: string;
|
||||
/**
|
||||
* The phone number
|
||||
*/
|
||||
number: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* @name Checkout
|
||||
* @description
|
||||
* Checkout.com cordova plugin
|
||||
*
|
||||
* @usage
|
||||
* ```typescript
|
||||
* import { Checkout } from '@ionic-native/checkout/ngx';
|
||||
*
|
||||
*
|
||||
* constructor(private checkout: Checkout) { }
|
||||
*
|
||||
* ...
|
||||
*
|
||||
*
|
||||
* this.checkout.initSandboxClient("pk_test_7d395871-0d66-4b62-85b6-8424df78b125")
|
||||
* .then(() => this.label = "CKO init completed")
|
||||
* .catch(err => this.label = err)
|
||||
*
|
||||
* ...
|
||||
*
|
||||
* let tokenRequest: CkoCardTokenRequest = {
|
||||
* number: "4543474002249996",
|
||||
* cvv: "010",
|
||||
* expiry_month: "08",
|
||||
* expiry_year: "2025",
|
||||
* billing_address: {
|
||||
* country: "FR"
|
||||
* }
|
||||
* }
|
||||
*
|
||||
*
|
||||
* this.cko.generateToken(tokenRequest)
|
||||
* .then(tokenResponse => this.label = "Token: " + tokenResponse.token)
|
||||
* .catch(err => this.label = err)
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
pluginName: 'Checkout',
|
||||
plugin: 'cordova-plugin-checkout',
|
||||
pluginRef: 'cordova.plugins.Checkout',
|
||||
repo: 'https://github.com/checkout/frames-cordova',
|
||||
install: '',
|
||||
installVariables: [],
|
||||
platforms: ['Android', 'iOS'],
|
||||
})
|
||||
@Injectable()
|
||||
export class Checkout extends IonicNativePlugin {
|
||||
/**
|
||||
* Initialize Frames plugin in Sandbox mode
|
||||
* @param publicKey {string} Merchant's sandbox public key
|
||||
* @return {Promise<any>} Returns a promise that resolves when Frames initiation is completed
|
||||
*/
|
||||
@Cordova()
|
||||
initSandboxClient(publicKey: string): Promise<any> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize Frames plugin in Live mode
|
||||
* @param publicKey {string} Merchant's live public key
|
||||
* @return {Promise<any>} Returns a promise that resolves when Frames initiation is completed
|
||||
*/
|
||||
@Cordova()
|
||||
initLiveClient(publicKey: string): Promise<any> {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Exchange card details for a reference token that can be used later to request a card payment from your backend. Tokens are single use and expire after 15 minutes.
|
||||
* @param ckoCardTokenRequest {CkoCardTokenRequest} Card tokenization request object
|
||||
* @return {Promise<CkoCardTokenResponse>} Returns a promise that resolves when Token response object
|
||||
*/
|
||||
@Cordova()
|
||||
generateToken(ckoCardTokenRequest: CkoCardTokenRequest): Promise<CkoCardTokenResponse> {
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -903,4 +903,8 @@ export class InAppPurchase2 extends IonicNativePlugin {
|
||||
/** Opens the Code Redemption Sheet on iOS. (AppStore). */
|
||||
@Cordova({ sync: true })
|
||||
redeem(): void {}
|
||||
|
||||
/** Opens the Manage Billing page (AppStore, Play, Microsoft, ...), where the user can update his/her payment methods. */
|
||||
@Cordova({ sync: true })
|
||||
manageBilling(): void {}
|
||||
}
|
||||
|
||||
@@ -35,14 +35,14 @@ export interface Configuration {
|
||||
messageStorage?: string;
|
||||
defaultMessageStorage?: boolean;
|
||||
ios?: {
|
||||
notificationTypes?: string[];
|
||||
notificationTypes?: string[]; // ['alert', 'badge', 'sound']
|
||||
forceCleanup?: boolean;
|
||||
logging?: boolean;
|
||||
};
|
||||
android?: {
|
||||
notificationIcon: string; // a resource name for a status bar icon (without extension), located in '/platforms/android/app/src/main/res/mipmap'
|
||||
multipleNotifications: boolean;
|
||||
notificationAccentColor: string;
|
||||
notificationIcon?: string; // a resource name for a status bar icon (without extension), located in '/platforms/android/app/src/main/res/mipmap'
|
||||
multipleNotifications?: boolean; // set to 'true' to enable multiple notifications
|
||||
notificationAccentColor?: string; // set to hex color value in format '#RRGGBB' or '#AARRGGBB'
|
||||
};
|
||||
privacySettings?: {
|
||||
applicationCodePersistingDisabled?: boolean;
|
||||
@@ -91,7 +91,7 @@ export interface Installation {
|
||||
sdkVersion?: string;
|
||||
appVersion?: string;
|
||||
os?: OS;
|
||||
osVersion: string;
|
||||
osVersion?: string;
|
||||
deviceManufacturer?: string;
|
||||
deviceModel?: string;
|
||||
deviceSecure?: boolean;
|
||||
@@ -102,10 +102,13 @@ export interface Installation {
|
||||
customAttributes?: Record<string, string | number | boolean>;
|
||||
}
|
||||
|
||||
/**
|
||||
* User's unique ID. One UserIdentity parameter must be provided if used.
|
||||
*/
|
||||
export interface UserIdentity {
|
||||
phones?: string[];
|
||||
emails?: string[];
|
||||
externalUserId: string;
|
||||
externalUserId?: string;
|
||||
}
|
||||
|
||||
export interface PersonalizeContext {
|
||||
|
||||
@@ -0,0 +1,481 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Cordova, IonicNativePlugin, Plugin } from '@ionic-native/core';
|
||||
|
||||
/**
|
||||
* PaymentSDKConfiguration: payment request configuration
|
||||
*/
|
||||
export interface PaymentSDKConfiguration {
|
||||
/**
|
||||
* merchant profile id
|
||||
*/
|
||||
profileID: string;
|
||||
/**
|
||||
* merchant server key
|
||||
*/
|
||||
serverKey: string;
|
||||
/**
|
||||
* merchant client key
|
||||
*/
|
||||
clientKey: string;
|
||||
/**
|
||||
* transaction type: refer to TransactionType enum
|
||||
*/
|
||||
transactionType?: string;
|
||||
/**
|
||||
* transaction class: refer to TransactionClass enum
|
||||
*/
|
||||
transactionClass?: string;
|
||||
/**
|
||||
* order or cart id
|
||||
*/
|
||||
cartID: string;
|
||||
/**
|
||||
* payment currency
|
||||
*/
|
||||
currency: string;
|
||||
/**
|
||||
* amount
|
||||
*/
|
||||
amount: number;
|
||||
/**
|
||||
* order or cart description
|
||||
*/
|
||||
cartDescription: string;
|
||||
/**
|
||||
* user interface language code(en, ar, ..)
|
||||
*/
|
||||
languageCode?: string;
|
||||
/**
|
||||
* validate shipping info
|
||||
*/
|
||||
forceShippingInfo?: boolean;
|
||||
/**
|
||||
* validate billing info
|
||||
*/
|
||||
showBillingInfo?: boolean;
|
||||
/**
|
||||
* handle missing shipping info by showing shipping info section
|
||||
*/
|
||||
showShippingInfo?: boolean;
|
||||
/**
|
||||
* configured billing details
|
||||
*/
|
||||
billingDetails?: PaymentSDKBillingDetails;
|
||||
/**
|
||||
* configured shipping details
|
||||
*/
|
||||
shippingDetails?: PaymentSDKShippingDetails;
|
||||
/**
|
||||
* merchant country code
|
||||
*/
|
||||
merchantCountryCode: string;
|
||||
/**
|
||||
* title of the screen
|
||||
*/
|
||||
screenTitle?: string;
|
||||
/**
|
||||
* merchant name
|
||||
*/
|
||||
merchantName?: string;
|
||||
/**
|
||||
* server ip
|
||||
*/
|
||||
serverIP?: string;
|
||||
/**
|
||||
* tokenise type: refer to TokeiseType enum
|
||||
*/
|
||||
tokeniseType?: string;
|
||||
/**
|
||||
* token format: refer to TokeiseFormat enum
|
||||
*/
|
||||
tokenFormat?: string;
|
||||
/**
|
||||
* option to hide or show card scanner button
|
||||
*/
|
||||
hideCardScanner?: string;
|
||||
/**
|
||||
* merchant apple pay bundle id
|
||||
*/
|
||||
merchantApplePayIdentifier?: string;
|
||||
/**
|
||||
* minize the vlaidation on apple pay billing and shipping info
|
||||
*/
|
||||
simplifyApplePayValidation?: string;
|
||||
/**
|
||||
* supported apple pay networks
|
||||
*/
|
||||
supportedApplePayNetworks?: [string];
|
||||
/**
|
||||
* returned token
|
||||
*/
|
||||
token?: string;
|
||||
/**
|
||||
* returned transaction reference
|
||||
*/
|
||||
transactionReference?: string;
|
||||
/**
|
||||
* samsung Token
|
||||
*/
|
||||
samsungToken?: string;
|
||||
/**
|
||||
* customized theme
|
||||
*/
|
||||
theme?: PaymentSDKTheme;
|
||||
/**
|
||||
* list of alternative payment methods
|
||||
*/
|
||||
alternativePaymentMethods?: [string];
|
||||
}
|
||||
|
||||
/**
|
||||
* PaymentSDKBillingDetails
|
||||
*/
|
||||
export interface PaymentSDKBillingDetails {
|
||||
/**
|
||||
* billing: customer name
|
||||
*/
|
||||
name?: string;
|
||||
/**
|
||||
* billing: customer email
|
||||
*/
|
||||
email?: string;
|
||||
/**
|
||||
* billing: customer phone
|
||||
*/
|
||||
phone?: string;
|
||||
/**
|
||||
* billing: customer address line
|
||||
*/
|
||||
addressLine?: string;
|
||||
/**
|
||||
* billing: customer city
|
||||
*/
|
||||
city?: string;
|
||||
/**
|
||||
* billing: customer state
|
||||
*/
|
||||
state?: string;
|
||||
/**
|
||||
* billing: customer country code
|
||||
*/
|
||||
countryCode?: string;
|
||||
/**
|
||||
* billing: customer zip code
|
||||
*/
|
||||
zip?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* PaymentSDKShippingDetails
|
||||
*/
|
||||
export interface PaymentSDKShippingDetails {
|
||||
/**
|
||||
* shipping: customer name
|
||||
*/
|
||||
name?: string;
|
||||
/**
|
||||
* shipping: customer email
|
||||
*/
|
||||
email?: string;
|
||||
/**
|
||||
* shipping: customer phone
|
||||
*/
|
||||
phone?: string;
|
||||
/**
|
||||
* shipping: customer address line
|
||||
*/
|
||||
addressLine?: string;
|
||||
/**
|
||||
* shipping: customer city
|
||||
*/
|
||||
city?: string;
|
||||
/**
|
||||
* shipping: customer state
|
||||
*/
|
||||
state?: string;
|
||||
/**
|
||||
* shipping: customer country code
|
||||
*/
|
||||
countryCode?: string;
|
||||
/**
|
||||
* shipping: customer zip code
|
||||
*/
|
||||
zip?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* PaymentSDKTheme
|
||||
*/
|
||||
export interface PaymentSDKTheme {
|
||||
/**
|
||||
* theme: primary color
|
||||
*/
|
||||
primaryColor?: string;
|
||||
/**
|
||||
* theme: primary font color
|
||||
*/
|
||||
primaryFontColor?: string;
|
||||
/**
|
||||
* theme: primary font
|
||||
*/
|
||||
primaryFont?: string;
|
||||
/**
|
||||
* theme: secondary color
|
||||
*/
|
||||
secondaryColor?: string;
|
||||
/**
|
||||
* theme: secondary font color
|
||||
*/
|
||||
secondaryFontColor?: string;
|
||||
/**
|
||||
* theme: secondary font
|
||||
*/
|
||||
secondaryFont?: string;
|
||||
/**
|
||||
* theme: stroke color
|
||||
*/
|
||||
strokeColor?: string;
|
||||
/**
|
||||
* theme: primary color
|
||||
*/
|
||||
strokeThinckness?: number;
|
||||
/**
|
||||
* theme: input corner radius
|
||||
*/
|
||||
inputsCornerRadius?: number;
|
||||
/**
|
||||
* theme: button color
|
||||
*/
|
||||
buttonColor?: string;
|
||||
/**
|
||||
* theme: button font color
|
||||
*/
|
||||
buttonFontColor?: string;
|
||||
/**
|
||||
* theme: button font
|
||||
*/
|
||||
buttonFont?: string;
|
||||
/**
|
||||
* theme: title font color
|
||||
*/
|
||||
titleFontColor?: string;
|
||||
/**
|
||||
* theme: title font
|
||||
*/
|
||||
titleFont?: string;
|
||||
/**
|
||||
* theme: background color
|
||||
*/
|
||||
backgroundColor?: string;
|
||||
/**
|
||||
* theme: placeholder color
|
||||
*/
|
||||
placeholderColor?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* TokeniseType: define the behaviour of of saving card option inside the SDKs.
|
||||
*/
|
||||
export enum TokeniseType {
|
||||
/**
|
||||
* none: tokenise is off
|
||||
*/
|
||||
none = 'none',
|
||||
/**
|
||||
* merchantMandatory: tokenise is forced
|
||||
*/
|
||||
merchantMandatory = 'merchantMandatory',
|
||||
/**
|
||||
* userMandatory: tokenise is forced as per user approval
|
||||
*/
|
||||
userMandatory = 'userMandatory',
|
||||
/**
|
||||
* userOptinoal: tokenise if optional as per user approval
|
||||
*/
|
||||
userOptinoal = 'userOptinoal',
|
||||
}
|
||||
|
||||
/**
|
||||
* TokeniseFromat: the returned token format
|
||||
*/
|
||||
export enum TokeniseFromat {
|
||||
/**
|
||||
* none: no format
|
||||
*/
|
||||
none = '1',
|
||||
/**
|
||||
* hex32: Hex with 32 length
|
||||
*/
|
||||
hex32 = '2',
|
||||
/**
|
||||
* alphaNum20: alpha numeric 20 length
|
||||
*/
|
||||
alphaNum20 = '3',
|
||||
/**
|
||||
* digit22: digits with 22 length
|
||||
*/
|
||||
digit22 = '3',
|
||||
/**
|
||||
* digit16: digits with 16 length
|
||||
*/
|
||||
digit16 = '5',
|
||||
/**
|
||||
* alphaNum32: alpha numeric 32 length
|
||||
*/
|
||||
alphaNum32 = '6',
|
||||
}
|
||||
|
||||
/**
|
||||
* TransactionType
|
||||
*/
|
||||
export enum TransactionType {
|
||||
/**
|
||||
* sale
|
||||
*/
|
||||
sale = 'sale',
|
||||
/**
|
||||
* authorize / capture option
|
||||
*/
|
||||
authorize = 'auth',
|
||||
}
|
||||
|
||||
/**
|
||||
* TransactionClass
|
||||
*/
|
||||
export enum TransactionClass {
|
||||
/**
|
||||
* ecom: default transaction
|
||||
*/
|
||||
ecom = 'ecom',
|
||||
/**
|
||||
* recurring: recurring transaction
|
||||
*/
|
||||
recurring = 'recur',
|
||||
}
|
||||
|
||||
/**
|
||||
* AlternativePaymentMethod
|
||||
*/
|
||||
export enum AlternativePaymentMethod {
|
||||
/**
|
||||
* unionpay: for supporting payment with unionpay
|
||||
*/
|
||||
unionPay = 'unionpay',
|
||||
/**
|
||||
* stcpay: for supporting payment with stcpay
|
||||
*/
|
||||
stcPay = 'stcpay',
|
||||
/**
|
||||
* valu: for supporting payment with valu
|
||||
*/
|
||||
valu = 'valu',
|
||||
/**
|
||||
* meezaqr: for supporting payment with meezaqr
|
||||
*/
|
||||
meezaQR = 'meezaqr',
|
||||
/**
|
||||
* omannet: for supporting payment with omannet
|
||||
*/
|
||||
omannet = 'omannet',
|
||||
/**
|
||||
* knetcredit: for supporting payment with knetcredit
|
||||
*/
|
||||
knetCredit = 'knetcredit',
|
||||
/**
|
||||
* knetdebit: for supporting payment with knetdebit
|
||||
*/
|
||||
knetDebit = 'knetdebit',
|
||||
/**
|
||||
* fawry: for supporting payment with fawry
|
||||
*/
|
||||
fawry = 'fawry',
|
||||
}
|
||||
|
||||
/**
|
||||
* @name PayTabs
|
||||
* @description
|
||||
* A plugin that allows you to use PayTabs's Native SDKs for Android and iOS.
|
||||
*
|
||||
* @usage
|
||||
* ```typescript
|
||||
* import { PayTabs } from '@ionic-native/paytabs/ngx';
|
||||
*
|
||||
* constructor(private paytabs: PayTabs) { }
|
||||
*
|
||||
* ...
|
||||
* let billingDetails: PaymentSDKBillingDetails = {
|
||||
* name: "John Smith",
|
||||
* email: "email@domain.com",
|
||||
* phone: "+201111111111",
|
||||
* addressLine: "Address line",
|
||||
* city: "Dubai",
|
||||
* state: "Dubai",
|
||||
* countryCode: "AE",
|
||||
* zip: "1234"
|
||||
* };
|
||||
*
|
||||
* var configuration: PaymentSDKConfiguration = {
|
||||
* profileID: "*profile id*",
|
||||
* serverKey: "*server key*",
|
||||
* clientKey: "*cleint key*",
|
||||
* cartID: "12345",
|
||||
* currency: "USD",
|
||||
* cartDescription: "Flowers",
|
||||
* merchantCountryCode: "ae",
|
||||
* merchantName: "Flowers Store",
|
||||
* amount: 20,
|
||||
* screenTitle:"Pay with Card",
|
||||
* billingDetails: billingDetails
|
||||
* }
|
||||
*
|
||||
* this.paytabs.startCardPayment(configuration)
|
||||
* .then(result => console.log(result))
|
||||
* .catch(error => console.error(error));
|
||||
*
|
||||
* this.paytabs.startApplePayPayment(configuration)
|
||||
* .then(result => console.log(result))
|
||||
* .catch(error => console.error(error));
|
||||
*
|
||||
* this.paytabs.startAlternativePaymentMethod(configuration)
|
||||
* .then(result => console.log(result))
|
||||
* .catch(error => console.error(error));
|
||||
*
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
pluginName: 'PayTabs',
|
||||
plugin: 'com.paytabs.cordova.plugin',
|
||||
pluginRef: 'com.paytabs.cordova.plugin',
|
||||
repo: 'https://github.com/paytabscom/paytabs-cordova',
|
||||
platforms: ['Android', 'iOS'],
|
||||
})
|
||||
@Injectable()
|
||||
export class PayTabs extends IonicNativePlugin {
|
||||
/**
|
||||
* Start Card Payment
|
||||
* @param params {PaymentSDKConfiguration} payment request configuration
|
||||
* @return {Promise<any>} returns a promise that resolves with transaction details, or rejects with an error
|
||||
*/
|
||||
@Cordova()
|
||||
startCardPayment(configuration: PaymentSDKConfiguration): Promise<any> {
|
||||
return;
|
||||
}
|
||||
/**
|
||||
* Start ApplePay Payment
|
||||
* @param params {PaymentSDKConfiguration} payment request configuration
|
||||
* @return {Promise<any>} returns a promise that resolves with transaction details, or rejects with an error
|
||||
*/
|
||||
@Cordova()
|
||||
startApplePayPayment(configuration: PaymentSDKConfiguration): Promise<any> {
|
||||
return;
|
||||
}
|
||||
/**
|
||||
* Start Alternative Payment Method
|
||||
* @param params {PaymentSDKConfiguration} payment request configuration
|
||||
* @return {Promise<any>} returns a promise that resolves with transaction details, or rejects with an error
|
||||
*/
|
||||
@Cordova()
|
||||
startAlternativePaymentMethod(configuration: PaymentSDKConfiguration): Promise<any> {
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -52,9 +52,9 @@ export class SmartlookSetupConfig {
|
||||
}
|
||||
|
||||
export class SmartlookResetSession {
|
||||
private resetUser: string;
|
||||
private resetUser: boolean;
|
||||
|
||||
constructor(resetUser: string) {
|
||||
constructor(resetUser: boolean) {
|
||||
this.resetUser = resetUser;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user