@gr4vy/secure-fields-react 1.3.0 → 1.5.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.
- package/CHANGELOG.md +12 -0
- package/README.md +1 -1
- package/lib/types.d.ts +6 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
# v1.4.0 (Wed Apr 12 2023)
|
|
2
|
+
|
|
3
|
+
#### 🐛 Bug Fix
|
|
4
|
+
|
|
5
|
+
- fix: return useful information on card vault failure [#248](https://github.com/gr4vy/secure-fields/pull/248) ([@theturboboy](https://github.com/theturboboy))
|
|
6
|
+
|
|
7
|
+
#### Authors: 1
|
|
8
|
+
|
|
9
|
+
- Andrei Haidukevich ([@theturboboy](https://github.com/theturboboy))
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
1
13
|
# v1.3.0 (Thu Feb 16 2023)
|
|
2
14
|
|
|
3
15
|
#### 🏠 Internal
|
package/README.md
CHANGED
|
@@ -32,7 +32,7 @@ const { SecureFields } = require(`@gr4vy/secure-fields-react`)
|
|
|
32
32
|
font="Lato"
|
|
33
33
|
onReady={(data) => console.log('Secure Fields loaded', data)}
|
|
34
34
|
onCardVaultSuccess={() => console.log('Card tokenization successful')}
|
|
35
|
-
onCardVaultFailure={() => console.error('Card tokenization failed')}
|
|
35
|
+
onCardVaultFailure={(data) => console.error('Card tokenization failed', data)}
|
|
36
36
|
>
|
|
37
37
|
<Form />
|
|
38
38
|
</SecureFields>
|
package/lib/types.d.ts
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import { Config as BaseConfig, Field as BaseField } from '@gr4vy/secure-fields';
|
|
2
2
|
import { MutableRefObject } from 'react';
|
|
3
|
+
export type CardVaultFailureData = {
|
|
4
|
+
status: number;
|
|
5
|
+
code: string;
|
|
6
|
+
message: string;
|
|
7
|
+
};
|
|
3
8
|
export type Config = BaseConfig & {
|
|
4
9
|
debug?: boolean;
|
|
5
10
|
font?: string;
|
|
@@ -7,7 +12,7 @@ export type Config = BaseConfig & {
|
|
|
7
12
|
version: string;
|
|
8
13
|
} & BaseConfig) => void;
|
|
9
14
|
onCardVaultSuccess?: () => void;
|
|
10
|
-
onCardVaultFailure?: () => void;
|
|
15
|
+
onCardVaultFailure?: (data: CardVaultFailureData) => void;
|
|
11
16
|
};
|
|
12
17
|
export type Field = BaseField & {
|
|
13
18
|
ref?: MutableRefObject<HTMLElement>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gr4vy/secure-fields-react",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.0",
|
|
4
4
|
"description": "Gr4vy-hosted secure fields offering advanced theming, PCI compliance, event handling, and more.",
|
|
5
5
|
"main": "lib/index",
|
|
6
6
|
"types": "lib/index",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"react-dom": ">=17.0.0"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@gr4vy/secure-fields": "^1.
|
|
42
|
+
"@gr4vy/secure-fields": "^1.5.0"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
45
|
"@testing-library/react-hooks": "^8.0.1",
|
|
@@ -51,5 +51,5 @@
|
|
|
51
51
|
"publishConfig": {
|
|
52
52
|
"access": "public"
|
|
53
53
|
},
|
|
54
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "885085223cf8f4633c30aa69dc266ba618b6c17f"
|
|
55
55
|
}
|