react-native-plaid-link-sdk 12.8.3 → 13.0.1

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.
Files changed (159) hide show
  1. package/CHANGELOG.md +1470 -0
  2. package/README.md +217 -239
  3. package/V13_MIGRATION_GUIDE.md +470 -0
  4. package/android/build.gradle +30 -98
  5. package/android/src/main/AndroidManifest.xml +1 -8
  6. package/android/src/main/java/expo/modules/plaidlinksdk/PlaidEmbeddedResultDispatcher.kt +19 -0
  7. package/android/src/main/java/expo/modules/plaidlinksdk/PlaidResultMappers.kt +217 -0
  8. package/android/src/main/java/expo/modules/plaidlinksdk/RNPlaidLinkSdkVersion.kt +5 -0
  9. package/android/src/main/java/expo/modules/plaidlinksdk/ReactNativePlaidLinkSdkModule.kt +183 -0
  10. package/android/src/main/java/expo/modules/plaidlinksdk/ReactNativePlaidLinkSdkView.kt +69 -0
  11. package/build/PlaidEmbeddedSearchView.d.ts +12 -0
  12. package/build/PlaidEmbeddedSearchView.d.ts.map +1 -0
  13. package/build/PlaidEmbeddedSearchView.js +8 -0
  14. package/build/PlaidEmbeddedSearchView.js.map +1 -0
  15. package/{dist/src/Types.d.ts → build/ReactNativePlaidLinkSdk.types.d.ts} +78 -47
  16. package/build/ReactNativePlaidLinkSdk.types.d.ts.map +1 -0
  17. package/{dist/build → build}/ReactNativePlaidLinkSdk.types.js +82 -71
  18. package/build/ReactNativePlaidLinkSdk.types.js.map +1 -0
  19. package/build/ReactNativePlaidLinkSdkModule.d.ts +16 -0
  20. package/build/ReactNativePlaidLinkSdkModule.d.ts.map +1 -0
  21. package/{dist/build → build}/ReactNativePlaidLinkSdkModule.js +1 -1
  22. package/build/ReactNativePlaidLinkSdkModule.js.map +1 -0
  23. package/build/index.d.ts +13 -0
  24. package/build/index.d.ts.map +1 -0
  25. package/build/index.js +82 -0
  26. package/build/index.js.map +1 -0
  27. package/expo-module.config.json +9 -0
  28. package/ios/Frameworks/LinkKit.xcframework/Info.plist +44 -0
  29. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Headers/LinkKit-Swift.h +327 -0
  30. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Headers/LinkKit.h +22 -0
  31. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Info.plist +0 -0
  32. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/LinkKit +0 -0
  33. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios.abi.json +53695 -0
  34. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios.private.swiftinterface +759 -0
  35. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
  36. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios.swiftinterface +759 -0
  37. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios.swiftmodule +0 -0
  38. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/Modules/module.modulemap +11 -0
  39. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/PrivacyInfo.xcprivacy +32 -0
  40. package/ios/Frameworks/LinkKit.xcframework/ios-arm64/LinkKit.framework/_CodeSignature/CodeResources +201 -0
  41. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Headers/LinkKit-Swift.h +650 -0
  42. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Headers/LinkKit.h +22 -0
  43. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Info.plist +0 -0
  44. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/LinkKit +0 -0
  45. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios-simulator.abi.json +53695 -0
  46. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +759 -0
  47. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios-simulator.swiftdoc +0 -0
  48. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios-simulator.swiftinterface +759 -0
  49. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/arm64-apple-ios-simulator.swiftmodule +0 -0
  50. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/x86_64-apple-ios-simulator.abi.json +53695 -0
  51. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +759 -0
  52. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/x86_64-apple-ios-simulator.swiftdoc +0 -0
  53. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +759 -0
  54. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/LinkKit.swiftmodule/x86_64-apple-ios-simulator.swiftmodule +0 -0
  55. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/Modules/module.modulemap +11 -0
  56. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/PrivacyInfo.xcprivacy +32 -0
  57. package/ios/Frameworks/LinkKit.xcframework/ios-arm64_x86_64-simulator/LinkKit.framework/_CodeSignature/CodeResources +256 -0
  58. package/ios/ReactNativePlaidLinkSdk.podspec +29 -0
  59. package/ios/src/PlaidEmbeddedSearchView.swift +101 -0
  60. package/ios/src/RNPlaidLinkSdkVersion.swift +19 -0
  61. package/ios/src/ReactNativePlaidLinkSdkModule.swift +555 -0
  62. package/package.json +65 -73
  63. package/src/PlaidEmbeddedSearchView.tsx +35 -0
  64. package/src/ReactNativePlaidLinkSdk.types.ts +894 -0
  65. package/src/ReactNativePlaidLinkSdkModule.ts +31 -0
  66. package/src/index.ts +166 -22
  67. package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
  68. package/android/gradle/wrapper/gradle-wrapper.properties +0 -6
  69. package/android/gradle.properties +0 -31
  70. package/android/gradlew +0 -174
  71. package/android/gradlew.bat +0 -89
  72. package/android/src/main/java/com/plaid/ActivityResultHandler.java +0 -7
  73. package/android/src/main/java/com/plaid/ActivityResultManager.java +0 -15
  74. package/android/src/main/java/com/plaid/GlobalFunctions.kt +0 -42
  75. package/android/src/main/java/com/plaid/PLKEmbeddedView.kt +0 -161
  76. package/android/src/main/java/com/plaid/PLKEmbeddedViewManager.kt +0 -50
  77. package/android/src/main/java/com/plaid/PlaidModule.kt +0 -291
  78. package/android/src/main/java/com/plaid/PlaidPackage.java +0 -117
  79. package/android/src/main/java/com/plaid/gson/PlaidJsonConverter.kt +0 -94
  80. package/android/src/main/java/com/plaid/gson/RNAccountAdapter.kt +0 -48
  81. package/android/src/main/java/com/plaid/gson/RNEventMetadataAdapter.kt +0 -49
  82. package/android/src/main/java/com/plaid/gson/RNLinkInstitutionAdapter.kt +0 -34
  83. package/android/src/main/res/layout/plk_embedded_view.xml +0 -5
  84. package/android/src/paper/java/com/facebook/react/viewmanagers/PLKEmbeddedViewManagerDelegate.java +0 -35
  85. package/android/src/paper/java/com/facebook/react/viewmanagers/PLKEmbeddedViewManagerInterface.java +0 -18
  86. package/android/src/paper/java/com/plaid/NativePlaidLinkModuleAndroidSpec.java +0 -64
  87. package/android/src/paper/java/com/plaid/NativePlaidLinkModuleiOSSpec.java +0 -59
  88. package/dist/build/EmbeddedLink/EmbeddedLinkView.d.ts +0 -2
  89. package/dist/build/EmbeddedLink/EmbeddedLinkView.js +0 -56
  90. package/dist/build/EmbeddedLink/EmbeddedLinkView.web.d.ts +0 -1
  91. package/dist/build/EmbeddedLink/EmbeddedLinkView.web.js +0 -2
  92. package/dist/build/EmbeddedLink/NativeEmbeddedLinkView.d.ts +0 -2
  93. package/dist/build/EmbeddedLink/NativeEmbeddedLinkView.js +0 -3
  94. package/dist/build/PlaidEmbeddedSearchView.d.ts +0 -2
  95. package/dist/build/PlaidEmbeddedSearchView.js +0 -25
  96. package/dist/build/PlaidLink.d.ts +0 -7
  97. package/dist/build/PlaidLink.js +0 -137
  98. package/dist/build/ReactNativePlaidLinkSdk.types.d.ts +0 -108
  99. package/dist/build/ReactNativePlaidLinkSdkModule.d.ts +0 -2
  100. package/dist/build/ReactNativePlaidLinkSdkView.d.ts +0 -2
  101. package/dist/build/ReactNativePlaidLinkSdkView.js +0 -7
  102. package/dist/build/Types.d.ts +0 -108
  103. package/dist/build/Types.js +0 -462
  104. package/dist/build/fabric/EmbeddedLinkViewNativeComponent.d.ts +0 -2
  105. package/dist/build/fabric/EmbeddedLinkViewNativeComponent.js +0 -3
  106. package/dist/build/fabric/NativePlaidLinkModuleAndroid.d.ts +0 -2
  107. package/dist/build/fabric/NativePlaidLinkModuleAndroid.js +0 -5
  108. package/dist/build/fabric/NativePlaidLinkModuleiOS.d.ts +0 -2
  109. package/dist/build/fabric/NativePlaidLinkModuleiOS.js +0 -5
  110. package/dist/build/fabric/fabricUtils.d.ts +0 -1
  111. package/dist/build/fabric/fabricUtils.js +0 -2
  112. package/dist/build/index.d.ts +0 -14
  113. package/dist/build/index.js +0 -154
  114. package/dist/scripts/check-package-entrypoints.d.ts +0 -1
  115. package/dist/scripts/check-package-entrypoints.js +0 -61
  116. package/dist/src/EmbeddedLink/EmbeddedLinkView.d.ts +0 -13
  117. package/dist/src/EmbeddedLink/EmbeddedLinkView.js +0 -55
  118. package/dist/src/EmbeddedLink/EmbeddedLinkView.web.d.ts +0 -1
  119. package/dist/src/EmbeddedLink/EmbeddedLinkView.web.js +0 -1
  120. package/dist/src/EmbeddedLink/NativeEmbeddedLinkView.d.ts +0 -2
  121. package/dist/src/EmbeddedLink/NativeEmbeddedLinkView.js +0 -2
  122. package/dist/src/PlaidLink.d.ts +0 -34
  123. package/dist/src/PlaidLink.js +0 -136
  124. package/dist/src/Types.js +0 -463
  125. package/dist/src/__tests__/Types.tests.d.ts +0 -1
  126. package/dist/src/__tests__/Types.tests.js +0 -14
  127. package/dist/src/fabric/EmbeddedLinkViewNativeComponent.d.ts +0 -15
  128. package/dist/src/fabric/EmbeddedLinkViewNativeComponent.js +0 -2
  129. package/dist/src/fabric/NativePlaidLinkModuleAndroid.d.ts +0 -15
  130. package/dist/src/fabric/NativePlaidLinkModuleAndroid.js +0 -4
  131. package/dist/src/fabric/NativePlaidLinkModuleiOS.d.ts +0 -15
  132. package/dist/src/fabric/NativePlaidLinkModuleiOS.js +0 -4
  133. package/dist/src/fabric/fabricUtils.d.ts +0 -1
  134. package/dist/src/fabric/fabricUtils.js +0 -1
  135. package/dist/src/index.d.ts +0 -4
  136. package/dist/src/index.js +0 -5
  137. package/ios/PLKEmbeddedView.m +0 -7
  138. package/ios/PLKEmbeddedView.swift +0 -116
  139. package/ios/PLKEmbeddedViewComponentView.h +0 -28
  140. package/ios/PLKEmbeddedViewComponentView.mm +0 -91
  141. package/ios/PLKEmbeddedViewManager.swift +0 -14
  142. package/ios/PLKFabricHelpers.h +0 -116
  143. package/ios/RNLinksdk-Bridging-Header.h +0 -8
  144. package/ios/RNLinksdk.h +0 -19
  145. package/ios/RNLinksdk.mm +0 -732
  146. package/ios/RNPlaidHelper.h +0 -15
  147. package/ios/RNPlaidHelper.m +0 -33
  148. package/ios/react_native_plaid_link_sdk.h +0 -2
  149. package/react-native-plaid-link-sdk.podspec +0 -40
  150. package/src/EmbeddedLink/EmbeddedLinkView.tsx +0 -95
  151. package/src/EmbeddedLink/EmbeddedLinkView.web.tsx +0 -5
  152. package/src/EmbeddedLink/NativeEmbeddedLinkView.tsx +0 -3
  153. package/src/PlaidLink.tsx +0 -167
  154. package/src/Types.ts +0 -634
  155. package/src/__tests__/Types.tests.ts +0 -15
  156. package/src/fabric/EmbeddedLinkViewNativeComponent.ts +0 -24
  157. package/src/fabric/NativePlaidLinkModuleAndroid.ts +0 -32
  158. package/src/fabric/NativePlaidLinkModuleiOS.ts +0 -33
  159. package/src/fabric/fabricUtils.ts +0 -2
package/package.json CHANGED
@@ -1,91 +1,83 @@
1
1
  {
2
2
  "name": "react-native-plaid-link-sdk",
3
- "version": "12.8.3",
4
- "description": "React Native Plaid Link SDK",
5
- "main": "dist/src/index.js",
6
- "types": "dist/src/index.d.ts",
7
- "react-native": "src/index.ts",
3
+ "version": "13.0.1",
4
+ "description": "React Native Plaid Link SDK (New Architecture & Expo)",
5
+ "main": "build/index.js",
6
+ "types": "build/index.d.ts",
7
+ "exports": {
8
+ ".": {
9
+ "types": "./build/index.d.ts",
10
+ "react-native": "./build/index.js",
11
+ "import": "./build/index.js",
12
+ "require": "./build/index.js",
13
+ "default": "./build/index.js"
14
+ },
15
+ "./package.json": "./package.json"
16
+ },
8
17
  "files": [
9
- "dist/**/*",
10
- "android/**/*",
11
- "ios/**/*",
12
- "react-native-plaid-link-sdk.podspec",
13
- "src/**/*"
18
+ "android/build.gradle",
19
+ "android/src/main/",
20
+ "build/",
21
+ "CHANGELOG.md",
22
+ "expo-module.config.json",
23
+ "ios/Frameworks/",
24
+ "ios/ReactNativePlaidLinkSdk.podspec",
25
+ "ios/src/",
26
+ "LICENSE",
27
+ "README.md",
28
+ "src/index.ts",
29
+ "src/PlaidEmbeddedSearchView.tsx",
30
+ "src/ReactNativePlaidLinkSdk.types.ts",
31
+ "src/ReactNativePlaidLinkSdkModule.ts",
32
+ "V13_MIGRATION_GUIDE.md"
14
33
  ],
34
+ "publishConfig": {
35
+ "registry": "https://registry.npmjs.org/"
36
+ },
15
37
  "scripts": {
16
- "build": "tsc",
38
+ "build": "expo-module build",
39
+ "check:linkkit": "node scripts/validate-linkkit-xcframework.js",
17
40
  "check:package": "node scripts/check-package-entrypoints.js",
18
- "lint": "eslint \"*.js\" \"scripts/**/*.js\" --fix",
19
- "prettier": "prettier \"./**/*.{js,jsx}\" --write",
20
- "test": "jest"
41
+ "clean": "expo-module clean",
42
+ "lint": "expo-module lint",
43
+ "pack:dry-run": "node scripts/npm-dry-run.js pack",
44
+ "test": "expo-module test --watchman=false",
45
+ "publish:dry-run": "node scripts/npm-dry-run.js publish",
46
+ "strip:linkkit-maccatalyst": "node scripts/strip-linkkit-maccatalyst.js",
47
+ "prepare": "expo-module prepare",
48
+ "prepublishOnly": "expo-module prepublishOnly",
49
+ "expo-module": "expo-module",
50
+ "open:ios": "xed example/ios",
51
+ "open:android": "open -a \"Android Studio\" example/android",
52
+ "format": "prettier --write \"**/*.{ts,tsx}\""
21
53
  },
22
54
  "keywords": [
23
55
  "react-native",
24
- "Plaid"
56
+ "expo",
57
+ "react-native-plaid-link-sdk",
58
+ "ReactNativePlaidLinkSdk"
25
59
  ],
26
- "husky": {
27
- "hooks": {
28
- "pre-commit": "lint-staged"
29
- }
30
- },
31
- "lint-staged": {
32
- "*.{js,jsx}": [
33
- "prettier --write",
34
- "eslint --fix",
35
- "git add"
36
- ]
60
+ "repository": {
61
+ "type": "git",
62
+ "url": "git+https://github.com/plaid/react-native-plaid-link-sdk.git"
37
63
  },
38
- "jest": {
39
- "testPathIgnorePatterns": [
40
- "/node_modules/",
41
- "/dist/",
42
- "/example/",
43
- "/FabricExample/",
44
- "/exampleReactNative76/"
45
- ]
64
+ "bugs": {
65
+ "url": "https://github.com/plaid/react-native-plaid-link-sdk/issues"
46
66
  },
47
67
  "author": "Plaid",
48
68
  "license": "MIT",
49
- "peerDependencies": {
50
- "react": "*",
51
- "react-native": "*"
52
- },
69
+ "homepage": "https://github.com/plaid/react-native-plaid-link-sdk#readme",
53
70
  "devDependencies": {
54
- "@babel/core": "^7.25.2",
55
- "@babel/eslint-parser": "^7.25.1",
56
- "@react-native-community/eslint-plugin": "^1.1.0",
57
- "@react-native/babel-preset": "^0.74.3",
58
- "@types/jest": "^26.0.14",
59
- "@types/react": "^18.2.6",
60
- "@types/react-native": "^0.71.3",
61
- "@types/react-test-renderer": "^16.9.3",
62
- "@typescript-eslint/eslint-plugin": "^4.33.0",
63
- "@typescript-eslint/parser": "^4.33.0",
64
- "babel-eslint": "^10.0.3",
65
- "eslint": "^7.32.0",
66
- "eslint-plugin-prettier": "^3.1.4",
67
- "eslint-plugin-react": "^7.16.0",
68
- "husky": "^3.1.0",
69
- "jest": "^29.6.1",
70
- "lint-staged": "^9.4.2",
71
- "prettier": "^1.18.2",
72
- "react": "18.2.0",
73
- "react-native": "0.84.1",
74
- "typescript": "^4.9.5"
71
+ "@testing-library/react-native": "^13.3.3",
72
+ "@types/jest": "^30.0.0",
73
+ "@types/react": "~19.1.1",
74
+ "expo": "^55.0.8",
75
+ "expo-module-scripts": "^55.0.2",
76
+ "react-native": "0.82.1"
75
77
  },
76
- "codegenConfig": {
77
- "name": "rnplaidlink",
78
- "type": "all",
79
- "jsSrcsDir": "./src/fabric",
80
- "android": {
81
- "javaPackageName": "com.plaid"
82
- },
83
- "ios": {
84
- "modules": {
85
- "RNLinksdk": {
86
- "className": "RNLinksdk"
87
- }
88
- }
89
- }
78
+ "peerDependencies": {
79
+ "expo": ">=52.0.0",
80
+ "react": ">=18.0.0",
81
+ "react-native": ">=0.76.0"
90
82
  }
91
83
  }
@@ -0,0 +1,35 @@
1
+ import { requireNativeViewManager } from "expo-modules-core";
2
+ import * as React from "react";
3
+ import { ViewProps } from "react-native";
4
+
5
+ import {
6
+ LinkExit,
7
+ LinkEvent,
8
+ LinkSuccess,
9
+ } from "./ReactNativePlaidLinkSdk.types";
10
+
11
+ export type PlaidEmbeddedSearchViewProps = {
12
+ token: string;
13
+ onSuccess?: (success: LinkSuccess) => void;
14
+ onExit?: (exit: LinkExit) => void;
15
+ onEvent?: (event: LinkEvent) => void;
16
+ onLoad?: () => void;
17
+ } & ViewProps;
18
+
19
+ const NativeView: React.ComponentType<any> = requireNativeViewManager(
20
+ "ReactNativePlaidLinkSdk",
21
+ );
22
+
23
+ export function PlaidEmbeddedSearchView(props: PlaidEmbeddedSearchViewProps) {
24
+ const { onSuccess, onExit, onEvent, onLoad, ...restProps } = props;
25
+
26
+ return (
27
+ <NativeView
28
+ {...restProps}
29
+ onSuccess={(event: any) => onSuccess?.(event.nativeEvent)}
30
+ onExit={(event: any) => onExit?.(event.nativeEvent)}
31
+ onEvent={(event: any) => onEvent?.(event.nativeEvent)}
32
+ onLoad={(event: any) => onLoad?.()}
33
+ />
34
+ );
35
+ }