diff --git a/README.md b/README.md
index b2c7bb5..5f7570f 100644
--- a/README.md
+++ b/README.md
@@ -167,16 +167,16 @@ available for users to choose from. For example, the list of supported
card networks can be filtered by setting the
CardParameters.allowedCardNetworks property.
-| Prop | Type | Description | Default |
-| ------------------------------ | ----------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ |
-| **`allowedAuthMethods`** | CardAuthMethod[]
| Allowed authentication methods. This field specifies what set of fields or your gateway/processor supports for authenticating a card transaction. Please note that some of your processor's capabilities may vary by market, so consult your processor to determine the authentication forms they support. In general, you should list/support as many authentication methods possible as to increase the chances that a user will be able to complete a purchase. Not all cards support all authentication methods, so the more methods you or your processor support the better. This field is required. | |
-| **`allowedCardNetworks`** | CardNetwork[]
| Allowed card networks. This field specifies what set of card networks your gateway/processor supports for a card transaction. Note: Some cards may contain multiple brands and be processed across different networks. In particular when TransactionInfo.countryCode is set to "BR", users will be prompted to choose whether to process the transaction over a debit network or credit network and you should use this field to know which network to process the transaction with. For all other markets, this field will be set to a suggestion of a card network to use for processing, but you or your processor may choose to use different rails. This card network value **should not** be displayed. This field is required. | |
-| **`allowPrepaidCards`** | boolean
| Whether a prepaid card may be used for this transaction. If omitted, defaults to `true`. | true
|
-| **`allowCreditCards`** | boolean
| Whether a credit card may be used for this transaction. If omitted, defaults to `true`. | true
|
-| **`assuranceDetailsRequired`** | boolean
| Set to `true` to request assuranceDetails. If omitted, defaults to `false`. You may set if you need object provides information about the validation performed on the returned payment data. | false
|
-| **`billingAddressRequired`** | boolean
| Whether a billing address is required from the buyer. If omitted, defaults to `false`. Note: you should only set this field to `true` when billing address is required to process the order. Additional form entry or customer data requests can increase friction during the checkout process and can lead to a lower conversion rate. | false
|
-| **`billingAddressParameters`** | BillingAddressParameters
| Optional billing address parameters. If omitted, the default values specified in BillingAddressParameters will be assumed. | |
-| **`cardNetworkParameters`** | CardNetworkParameters[]
| List of card network parameters. This field is optional. You may set it when network specific parameters are needed to complete a transaction. | |
+| Prop | Type | Description | Default |
+| ------------------------------ | ----------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ |
+| **`allowedAuthMethods`** | CardAuthMethod[]
| Allowed authentication methods. This field specifies what set of fields or your gateway/processor supports for authenticating a card transaction. Please note that some of your processor's capabilities may vary by market, so consult your processor to determine the authentication forms they support. In general, you should list/support as many authentication methods possible as to increase the chances that a user will be able to complete a purchase. Not all cards support all authentication methods, so the more methods you or your processor support the better. This field is required. | |
+| **`allowedCardNetworks`** | CardNetwork[]
| Allowed card networks. This field specifies what set of card networks your gateway/processor supports for a card transaction. Note: Some cards may contain multiple brands and be processed across different networks. In particular when TransactionInfo.countryCode is set to "BR", users will be prompted to choose whether to process the transaction over a debit network or credit network, and you should use this field to know which network to process the transaction with. For all other markets, this field will be set to a suggestion of a card network to use for processing, but you or your processor may choose to use different rails. This card network value **should not** be displayed. This field is required. | |
+| **`allowPrepaidCards`** | boolean
| Whether a prepaid card may be used for this transaction. If omitted, defaults to `true`. | true
|
+| **`allowCreditCards`** | boolean
| Whether a credit card may be used for this transaction. If omitted, defaults to `true`. | true
|
+| **`assuranceDetailsRequired`** | boolean
| Set to `true` to request assuranceDetails. If omitted, defaults to `false`. You may set if you need object provides information about the validation performed on the returned payment data. | false
|
+| **`billingAddressRequired`** | boolean
| Whether a billing address is required from the buyer. If omitted, defaults to `false`. Note: you should only set this field to `true` when billing address is required to process the order. Additional form entry or customer data requests can increase friction during the checkout process and can lead to a lower conversion rate. | false
|
+| **`billingAddressParameters`** | BillingAddressParameters
| Optional billing address parameters. If omitted, the default values specified in BillingAddressParameters will be assumed. | |
+| **`cardNetworkParameters`** | CardNetworkParameters[]
| List of card network parameters. This field is optional. You may set it when network specific parameters are needed to complete a transaction. | |
#### BillingAddressParameters
@@ -271,7 +271,7 @@ verification and decryption of a payment response.
| Prop | Type | Description |
| --------------------- | ------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **`protocolVersion`** | string
| The version of the encryption/signature protocol being used. This field is required when the payment method requires encryption. Unless you were already using an older `protocolVersion`, you should be using the latest version defined in https://developers.google.com/pay/api/web/payment-data-cryptography. |
-| **`publicKey`** | string
| Elliptic Curve public key suitable for using with the NIST P-126 curve. This public key will used to encrypt the sensitive payment method information. This field is required when the payment method requires encryption. |
+| **`publicKey`** | string
| Elliptic Curve public key suitable for using with the NIST P-126 curve. This public key will be used to encrypt the sensitive payment method information. This field is required when the payment method requires encryption. |
#### PaymentData
@@ -415,7 +415,7 @@ Detailed information about the transaction.
| **`currencyCode`** | string
| ISO 4217 alphabetic currency code of the transaction. This is a required field. | |
| **`countryCode`** | string
| ISO 3166-1 alpha-2 country code for the country where the transaction will be completed/processed. This is an optional field. We recommend setting this field to allow country-specific customizations (for example, in some countries we may need to provide extra information to you or your processor in order to complete a transaction). | |
| **`totalPrice`** | string
| Total price of this transaction. The format of this string should follow the regular expression format: `[0-9]+(\.[0-9][0-9])?` (e.g., `"10.45"`) This field is required if CheckoutOption.TransactionInfo.totalPriceStatus is set to TotalPriceStatus.ESTIMATED or TotalPriceStatus.FINAL. | |
-| **`totalPriceLabel`** | string
| Total price label of this transaction. The string will be shown as the total price label on the cart modal dialog page. This field is optional, but required if developer wants to show cart information. Otherwise the cart modal dialog will not be rendered even if transactionInfo.displayItems is set. | |
+| **`totalPriceLabel`** | string
| Total price label of this transaction. The string will be shown as the total price label on the cart modal dialog page. This field is optional, but required if developer wants to show cart information. Otherwise, the cart modal dialog will not be rendered even if transactionInfo.displayItems is set. | |
| **`totalPriceStatus`** | TotalPriceStatus
| Status of this transaction's total price. This field is required. Note: some payment methods require that this field be set to [TotalPriceStatus\|`FINAL`] and that the total price to be specified and final. | |
| **`checkoutOption`** | CheckoutOption
| Optional checkout option parameter. Whether to use the 'Continue' or the 'Pay Now' button for a buy flow. If omitted, defaults to CheckoutOption.DEFAULT and renders the 'Continue' button for a buy flow. | "DEFAULT"
|
@@ -589,7 +589,7 @@ Options:
- Address.name
- Address.countryCode
- Address.postalCode
- - Address.phoneNumber if BillingAddressParameters.phoneNumberRequired is set to `true`.
+ - Address.phoneNumber if BillingAddressParameters.phoneNumberRequired is set to `true`.
Note: some countries do not use postal codes. The postal code field
will be empty in those countries.
diff --git a/package.json b/package.json
index 66b717c..dcfbaa8 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "@fresha/capacitor-plugin-googlepay",
- "version": "1.0.0",
+ "version": "1.0.1",
"description": "Google Pay plugin for Capacitor",
"main": "dist/plugin.cjs.js",
"module": "dist/esm/index.js",
@@ -34,11 +34,12 @@
"eslint": "eslint . --ext ts",
"prettier": "prettier \"**/*.{css,html,ts,js,java}\"",
"docgen": "docgen --api GooglePayPlugin --output-readme README.md --output-json dist/docs.json",
- "build": "npm run clean && npm run docgen && tsc && rollup -c rollup.config.js",
+ "build": "npm run clean && npm run docgen && tsc && rollup -c rollup.config.js && npm run copy-ts-definitions",
"clean": "rimraf ./dist",
"watch": "tsc --watch",
"prepare": "npm run build",
- "prepublishOnly": "npm run build"
+ "prepublishOnly": "npm run build",
+ "copy-ts-definitions": "mkdir dist/types && cp types/* dist/types/"
},
"devDependencies": {
"@capacitor/android": "^3.0.0",
@@ -68,4 +69,4 @@
"publishConfig": {
"access": "public"
}
-}
+}
\ No newline at end of file