@networkinternational/ni-card-management-sdk 1.0.2

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 (416) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +651 -0
  3. package/android/build.gradle +95 -0
  4. package/android/gradle.properties +5 -0
  5. package/android/src/main/AndroidManifest.xml +3 -0
  6. package/android/src/main/AndroidManifestNew.xml +2 -0
  7. package/android/src/main/java/com/nicardmanagement/JsonDeserialization.kt +24 -0
  8. package/android/src/main/java/com/nicardmanagement/NiCardManagementModule.kt +163 -0
  9. package/android/src/main/java/com/nicardmanagement/NiCardManagementPackage.kt +17 -0
  10. package/ios/NiCardManagement-Bridging-Header.h +2 -0
  11. package/ios/NiCardManagement.mm +29 -0
  12. package/ios/NiCardManagement.swift +142 -0
  13. package/lib/commonjs/NICardManagementComponents/CardDetailsComponent.js +71 -0
  14. package/lib/commonjs/NICardManagementComponents/CardDetailsComponent.js.map +1 -0
  15. package/lib/commonjs/NICardManagementComponents/ChangePinView.js +44 -0
  16. package/lib/commonjs/NICardManagementComponents/ChangePinView.js.map +1 -0
  17. package/lib/commonjs/NICardManagementComponents/NiInputInterfaces.js +17 -0
  18. package/lib/commonjs/NICardManagementComponents/NiInputInterfaces.js.map +1 -0
  19. package/lib/commonjs/NICardManagementComponents/SetPinView.js +44 -0
  20. package/lib/commonjs/NICardManagementComponents/SetPinView.js.map +1 -0
  21. package/lib/commonjs/NICardManagementComponents/VerifyPinView.js +44 -0
  22. package/lib/commonjs/NICardManagementComponents/VerifyPinView.js.map +1 -0
  23. package/lib/commonjs/NICardManagementComponents/ViewPinComponent.js +52 -0
  24. package/lib/commonjs/NICardManagementComponents/ViewPinComponent.js.map +1 -0
  25. package/lib/commonjs/assets/icons/content-copy.png +0 -0
  26. package/lib/commonjs/assets/icons/eye-off-outline.png +0 -0
  27. package/lib/commonjs/assets/icons/eye-outline.png +0 -0
  28. package/lib/commonjs/assets/icons/icons8-arrow-100.png +0 -0
  29. package/lib/commonjs/assets/icons/icons8-arrow-100_1.png +0 -0
  30. package/lib/commonjs/assets/icons/red-eye-off-outline.png +0 -0
  31. package/lib/commonjs/assets/icons/red-eye-outline.png +0 -0
  32. package/lib/commonjs/assets/images/grayCard.png +0 -0
  33. package/lib/commonjs/components/CardDetails/CardDetails.js +27 -0
  34. package/lib/commonjs/components/CardDetails/CardDetails.js.map +1 -0
  35. package/lib/commonjs/components/CardDetails/CardDetailsBackgroundImage.js +29 -0
  36. package/lib/commonjs/components/CardDetails/CardDetailsBackgroundImage.js.map +1 -0
  37. package/lib/commonjs/components/CardDetails/CardDetailsGroups.js +94 -0
  38. package/lib/commonjs/components/CardDetails/CardDetailsGroups.js.map +1 -0
  39. package/lib/commonjs/components/CardDetails/CardHolderNameGroups.js +67 -0
  40. package/lib/commonjs/components/CardDetails/CardHolderNameGroups.js.map +1 -0
  41. package/lib/commonjs/components/CardDetails/CardNumberGroup.js +69 -0
  42. package/lib/commonjs/components/CardDetails/CardNumberGroup.js.map +1 -0
  43. package/lib/commonjs/components/CardDetails/DateCVVGroupOneRow.js +104 -0
  44. package/lib/commonjs/components/CardDetails/DateCVVGroupOneRow.js.map +1 -0
  45. package/lib/commonjs/components/CardDetails/styles.js +98 -0
  46. package/lib/commonjs/components/CardDetails/styles.js.map +1 -0
  47. package/lib/commonjs/components/ChangePin/CaptureCurrentPin.js +50 -0
  48. package/lib/commonjs/components/ChangePin/CaptureCurrentPin.js.map +1 -0
  49. package/lib/commonjs/components/ChangePin/CaptureNewPin.js +50 -0
  50. package/lib/commonjs/components/ChangePin/CaptureNewPin.js.map +1 -0
  51. package/lib/commonjs/components/ChangePin/ChangePin.js +135 -0
  52. package/lib/commonjs/components/ChangePin/ChangePin.js.map +1 -0
  53. package/lib/commonjs/components/ChangePin/ConfirmPin.js +39 -0
  54. package/lib/commonjs/components/ChangePin/ConfirmPin.js.map +1 -0
  55. package/lib/commonjs/components/ChangePin/ReenterNewPin.js +53 -0
  56. package/lib/commonjs/components/ChangePin/ReenterNewPin.js.map +1 -0
  57. package/lib/commonjs/components/ChangePin/styles.js +29 -0
  58. package/lib/commonjs/components/ChangePin/styles.js.map +1 -0
  59. package/lib/commonjs/components/NIButton/NIButton.js +46 -0
  60. package/lib/commonjs/components/NIButton/NIButton.js.map +1 -0
  61. package/lib/commonjs/components/NIButton/styles.js +15 -0
  62. package/lib/commonjs/components/NIButton/styles.js.map +1 -0
  63. package/lib/commonjs/components/Pin/CapturePin.js +152 -0
  64. package/lib/commonjs/components/Pin/CapturePin.js.map +1 -0
  65. package/lib/commonjs/components/Pin/NextButton.js +40 -0
  66. package/lib/commonjs/components/Pin/NextButton.js.map +1 -0
  67. package/lib/commonjs/components/Pin/ShowHideButton.js +48 -0
  68. package/lib/commonjs/components/Pin/ShowHideButton.js.map +1 -0
  69. package/lib/commonjs/components/Pin/styles.js +61 -0
  70. package/lib/commonjs/components/Pin/styles.js.map +1 -0
  71. package/lib/commonjs/components/PinState/LoadingState.js +29 -0
  72. package/lib/commonjs/components/PinState/LoadingState.js.map +1 -0
  73. package/lib/commonjs/components/PinState/PinState.js +29 -0
  74. package/lib/commonjs/components/PinState/PinState.js.map +1 -0
  75. package/lib/commonjs/components/SetPin/ConfirmPin.js +39 -0
  76. package/lib/commonjs/components/SetPin/ConfirmPin.js.map +1 -0
  77. package/lib/commonjs/components/SetPin/ReenterCardPin.js +53 -0
  78. package/lib/commonjs/components/SetPin/ReenterCardPin.js.map +1 -0
  79. package/lib/commonjs/components/SetPin/SetPin.js +118 -0
  80. package/lib/commonjs/components/SetPin/SetPin.js.map +1 -0
  81. package/lib/commonjs/components/SetPin/SetUpNewCardPin.js +50 -0
  82. package/lib/commonjs/components/SetPin/SetUpNewCardPin.js.map +1 -0
  83. package/lib/commonjs/components/SetPin/styles.js +29 -0
  84. package/lib/commonjs/components/SetPin/styles.js.map +1 -0
  85. package/lib/commonjs/components/VerifyPin/CaptureVerifyPin.js +50 -0
  86. package/lib/commonjs/components/VerifyPin/CaptureVerifyPin.js.map +1 -0
  87. package/lib/commonjs/components/VerifyPin/ConfirmPin.js +40 -0
  88. package/lib/commonjs/components/VerifyPin/ConfirmPin.js.map +1 -0
  89. package/lib/commonjs/components/VerifyPin/VerifyPin.js +92 -0
  90. package/lib/commonjs/components/VerifyPin/VerifyPin.js.map +1 -0
  91. package/lib/commonjs/components/VerifyPin/styles.js +26 -0
  92. package/lib/commonjs/components/VerifyPin/styles.js.map +1 -0
  93. package/lib/commonjs/components/ViewPin/ViewPin.js +76 -0
  94. package/lib/commonjs/components/ViewPin/ViewPin.js.map +1 -0
  95. package/lib/commonjs/components/ViewPin/styles.js +19 -0
  96. package/lib/commonjs/components/ViewPin/styles.js.map +1 -0
  97. package/lib/commonjs/components/icons/PredeterminedIcon.js +43 -0
  98. package/lib/commonjs/components/icons/PredeterminedIcon.js.map +1 -0
  99. package/lib/commonjs/config/configCard.js +9 -0
  100. package/lib/commonjs/config/configCard.js.map +1 -0
  101. package/lib/commonjs/config/localization.js +47 -0
  102. package/lib/commonjs/config/localization.js.map +1 -0
  103. package/lib/commonjs/config/themeColors.js +34 -0
  104. package/lib/commonjs/config/themeColors.js.map +1 -0
  105. package/lib/commonjs/hooks/useChangePin.js +37 -0
  106. package/lib/commonjs/hooks/useChangePin.js.map +1 -0
  107. package/lib/commonjs/hooks/useGetCardDetails.js +37 -0
  108. package/lib/commonjs/hooks/useGetCardDetails.js.map +1 -0
  109. package/lib/commonjs/hooks/useSetPin.js +37 -0
  110. package/lib/commonjs/hooks/useSetPin.js.map +1 -0
  111. package/lib/commonjs/hooks/useVerifyPin.js +37 -0
  112. package/lib/commonjs/hooks/useVerifyPin.js.map +1 -0
  113. package/lib/commonjs/hooks/useViewPin.js +37 -0
  114. package/lib/commonjs/hooks/useViewPin.js.map +1 -0
  115. package/lib/commonjs/index.js +72 -0
  116. package/lib/commonjs/index.js.map +1 -0
  117. package/lib/commonjs/interfaces/NiCardManagementInterfaces.js +2 -0
  118. package/lib/commonjs/interfaces/NiCardManagementInterfaces.js.map +1 -0
  119. package/lib/commonjs/interfaces/NiInputInterfaces.js +39 -0
  120. package/lib/commonjs/interfaces/NiInputInterfaces.js.map +1 -0
  121. package/lib/commonjs/interfaces/NiInterfaces.js +14 -0
  122. package/lib/commonjs/interfaces/NiInterfaces.js.map +1 -0
  123. package/lib/commonjs/nativeComponents/NICardManagementSDKModule.js +9 -0
  124. package/lib/commonjs/nativeComponents/NICardManagementSDKModule.js.map +1 -0
  125. package/lib/commonjs/utils/formatInput.js +10 -0
  126. package/lib/commonjs/utils/formatInput.js.map +1 -0
  127. package/lib/commonjs/utils/localization.js +13 -0
  128. package/lib/commonjs/utils/localization.js.map +1 -0
  129. package/lib/module/NICardManagementComponents/CardDetailsComponent.js +57 -0
  130. package/lib/module/NICardManagementComponents/CardDetailsComponent.js.map +1 -0
  131. package/lib/module/NICardManagementComponents/ChangePinView.js +32 -0
  132. package/lib/module/NICardManagementComponents/ChangePinView.js.map +1 -0
  133. package/lib/module/NICardManagementComponents/NiInputInterfaces.js +3 -0
  134. package/lib/module/NICardManagementComponents/NiInputInterfaces.js.map +1 -0
  135. package/lib/module/NICardManagementComponents/SetPinView.js +32 -0
  136. package/lib/module/NICardManagementComponents/SetPinView.js.map +1 -0
  137. package/lib/module/NICardManagementComponents/VerifyPinView.js +32 -0
  138. package/lib/module/NICardManagementComponents/VerifyPinView.js.map +1 -0
  139. package/lib/module/NICardManagementComponents/ViewPinComponent.js +38 -0
  140. package/lib/module/NICardManagementComponents/ViewPinComponent.js.map +1 -0
  141. package/lib/module/assets/icons/content-copy.png +0 -0
  142. package/lib/module/assets/icons/eye-off-outline.png +0 -0
  143. package/lib/module/assets/icons/eye-outline.png +0 -0
  144. package/lib/module/assets/icons/icons8-arrow-100.png +0 -0
  145. package/lib/module/assets/icons/icons8-arrow-100_1.png +0 -0
  146. package/lib/module/assets/icons/red-eye-off-outline.png +0 -0
  147. package/lib/module/assets/icons/red-eye-outline.png +0 -0
  148. package/lib/module/assets/images/grayCard.png +0 -0
  149. package/lib/module/components/CardDetails/CardDetails.js +20 -0
  150. package/lib/module/components/CardDetails/CardDetails.js.map +1 -0
  151. package/lib/module/components/CardDetails/CardDetailsBackgroundImage.js +22 -0
  152. package/lib/module/components/CardDetails/CardDetailsBackgroundImage.js.map +1 -0
  153. package/lib/module/components/CardDetails/CardDetailsGroups.js +85 -0
  154. package/lib/module/components/CardDetails/CardDetailsGroups.js.map +1 -0
  155. package/lib/module/components/CardDetails/CardHolderNameGroups.js +60 -0
  156. package/lib/module/components/CardDetails/CardHolderNameGroups.js.map +1 -0
  157. package/lib/module/components/CardDetails/CardNumberGroup.js +62 -0
  158. package/lib/module/components/CardDetails/CardNumberGroup.js.map +1 -0
  159. package/lib/module/components/CardDetails/DateCVVGroupOneRow.js +97 -0
  160. package/lib/module/components/CardDetails/DateCVVGroupOneRow.js.map +1 -0
  161. package/lib/module/components/CardDetails/styles.js +92 -0
  162. package/lib/module/components/CardDetails/styles.js.map +1 -0
  163. package/lib/module/components/ChangePin/CaptureCurrentPin.js +43 -0
  164. package/lib/module/components/ChangePin/CaptureCurrentPin.js.map +1 -0
  165. package/lib/module/components/ChangePin/CaptureNewPin.js +43 -0
  166. package/lib/module/components/ChangePin/CaptureNewPin.js.map +1 -0
  167. package/lib/module/components/ChangePin/ChangePin.js +126 -0
  168. package/lib/module/components/ChangePin/ChangePin.js.map +1 -0
  169. package/lib/module/components/ChangePin/ConfirmPin.js +32 -0
  170. package/lib/module/components/ChangePin/ConfirmPin.js.map +1 -0
  171. package/lib/module/components/ChangePin/ReenterNewPin.js +46 -0
  172. package/lib/module/components/ChangePin/ReenterNewPin.js.map +1 -0
  173. package/lib/module/components/ChangePin/styles.js +23 -0
  174. package/lib/module/components/ChangePin/styles.js.map +1 -0
  175. package/lib/module/components/NIButton/NIButton.js +38 -0
  176. package/lib/module/components/NIButton/NIButton.js.map +1 -0
  177. package/lib/module/components/NIButton/styles.js +9 -0
  178. package/lib/module/components/NIButton/styles.js.map +1 -0
  179. package/lib/module/components/Pin/CapturePin.js +143 -0
  180. package/lib/module/components/Pin/CapturePin.js.map +1 -0
  181. package/lib/module/components/Pin/NextButton.js +33 -0
  182. package/lib/module/components/Pin/NextButton.js.map +1 -0
  183. package/lib/module/components/Pin/ShowHideButton.js +41 -0
  184. package/lib/module/components/Pin/ShowHideButton.js.map +1 -0
  185. package/lib/module/components/Pin/styles.js +55 -0
  186. package/lib/module/components/Pin/styles.js.map +1 -0
  187. package/lib/module/components/PinState/LoadingState.js +22 -0
  188. package/lib/module/components/PinState/LoadingState.js.map +1 -0
  189. package/lib/module/components/PinState/PinState.js +22 -0
  190. package/lib/module/components/PinState/PinState.js.map +1 -0
  191. package/lib/module/components/SetPin/ConfirmPin.js +32 -0
  192. package/lib/module/components/SetPin/ConfirmPin.js.map +1 -0
  193. package/lib/module/components/SetPin/ReenterCardPin.js +46 -0
  194. package/lib/module/components/SetPin/ReenterCardPin.js.map +1 -0
  195. package/lib/module/components/SetPin/SetPin.js +109 -0
  196. package/lib/module/components/SetPin/SetPin.js.map +1 -0
  197. package/lib/module/components/SetPin/SetUpNewCardPin.js +43 -0
  198. package/lib/module/components/SetPin/SetUpNewCardPin.js.map +1 -0
  199. package/lib/module/components/SetPin/styles.js +23 -0
  200. package/lib/module/components/SetPin/styles.js.map +1 -0
  201. package/lib/module/components/VerifyPin/CaptureVerifyPin.js +43 -0
  202. package/lib/module/components/VerifyPin/CaptureVerifyPin.js.map +1 -0
  203. package/lib/module/components/VerifyPin/ConfirmPin.js +33 -0
  204. package/lib/module/components/VerifyPin/ConfirmPin.js.map +1 -0
  205. package/lib/module/components/VerifyPin/VerifyPin.js +83 -0
  206. package/lib/module/components/VerifyPin/VerifyPin.js.map +1 -0
  207. package/lib/module/components/VerifyPin/styles.js +20 -0
  208. package/lib/module/components/VerifyPin/styles.js.map +1 -0
  209. package/lib/module/components/ViewPin/ViewPin.js +67 -0
  210. package/lib/module/components/ViewPin/ViewPin.js.map +1 -0
  211. package/lib/module/components/ViewPin/styles.js +13 -0
  212. package/lib/module/components/ViewPin/styles.js.map +1 -0
  213. package/lib/module/components/icons/PredeterminedIcon.js +35 -0
  214. package/lib/module/components/icons/PredeterminedIcon.js.map +1 -0
  215. package/lib/module/config/configCard.js +3 -0
  216. package/lib/module/config/configCard.js.map +1 -0
  217. package/lib/module/config/localization.js +41 -0
  218. package/lib/module/config/localization.js.map +1 -0
  219. package/lib/module/config/themeColors.js +29 -0
  220. package/lib/module/config/themeColors.js.map +1 -0
  221. package/lib/module/hooks/useChangePin.js +29 -0
  222. package/lib/module/hooks/useChangePin.js.map +1 -0
  223. package/lib/module/hooks/useGetCardDetails.js +29 -0
  224. package/lib/module/hooks/useGetCardDetails.js.map +1 -0
  225. package/lib/module/hooks/useSetPin.js +29 -0
  226. package/lib/module/hooks/useSetPin.js.map +1 -0
  227. package/lib/module/hooks/useVerifyPin.js +29 -0
  228. package/lib/module/hooks/useVerifyPin.js.map +1 -0
  229. package/lib/module/hooks/useViewPin.js +29 -0
  230. package/lib/module/hooks/useViewPin.js.map +1 -0
  231. package/lib/module/index.js +7 -0
  232. package/lib/module/index.js.map +1 -0
  233. package/lib/module/interfaces/NiCardManagementInterfaces.js +2 -0
  234. package/lib/module/interfaces/NiCardManagementInterfaces.js.map +1 -0
  235. package/lib/module/interfaces/NiInputInterfaces.js +33 -0
  236. package/lib/module/interfaces/NiInputInterfaces.js.map +1 -0
  237. package/lib/module/interfaces/NiInterfaces.js +8 -0
  238. package/lib/module/interfaces/NiInterfaces.js.map +1 -0
  239. package/lib/module/nativeComponents/NICardManagementSDKModule.js +3 -0
  240. package/lib/module/nativeComponents/NICardManagementSDKModule.js.map +1 -0
  241. package/lib/module/utils/formatInput.js +4 -0
  242. package/lib/module/utils/formatInput.js.map +1 -0
  243. package/lib/module/utils/localization.js +7 -0
  244. package/lib/module/utils/localization.js.map +1 -0
  245. package/lib/typescript/src/NICardManagementComponents/CardDetailsComponent.d.ts +7 -0
  246. package/lib/typescript/src/NICardManagementComponents/CardDetailsComponent.d.ts.map +1 -0
  247. package/lib/typescript/src/NICardManagementComponents/ChangePinView.d.ts +6 -0
  248. package/lib/typescript/src/NICardManagementComponents/ChangePinView.d.ts.map +1 -0
  249. package/lib/typescript/src/NICardManagementComponents/NiInputInterfaces.d.ts +4 -0
  250. package/lib/typescript/src/NICardManagementComponents/NiInputInterfaces.d.ts.map +1 -0
  251. package/lib/typescript/src/NICardManagementComponents/SetPinView.d.ts +6 -0
  252. package/lib/typescript/src/NICardManagementComponents/SetPinView.d.ts.map +1 -0
  253. package/lib/typescript/src/NICardManagementComponents/VerifyPinView.d.ts +6 -0
  254. package/lib/typescript/src/NICardManagementComponents/VerifyPinView.d.ts.map +1 -0
  255. package/lib/typescript/src/NICardManagementComponents/ViewPinComponent.d.ts +6 -0
  256. package/lib/typescript/src/NICardManagementComponents/ViewPinComponent.d.ts.map +1 -0
  257. package/lib/typescript/src/components/CardDetails/CardDetails.d.ts +4 -0
  258. package/lib/typescript/src/components/CardDetails/CardDetails.d.ts.map +1 -0
  259. package/lib/typescript/src/components/CardDetails/CardDetailsBackgroundImage.d.ts +4 -0
  260. package/lib/typescript/src/components/CardDetails/CardDetailsBackgroundImage.d.ts.map +1 -0
  261. package/lib/typescript/src/components/CardDetails/CardDetailsGroups.d.ts +4 -0
  262. package/lib/typescript/src/components/CardDetails/CardDetailsGroups.d.ts.map +1 -0
  263. package/lib/typescript/src/components/CardDetails/CardHolderNameGroups.d.ts +4 -0
  264. package/lib/typescript/src/components/CardDetails/CardHolderNameGroups.d.ts.map +1 -0
  265. package/lib/typescript/src/components/CardDetails/CardNumberGroup.d.ts +4 -0
  266. package/lib/typescript/src/components/CardDetails/CardNumberGroup.d.ts.map +1 -0
  267. package/lib/typescript/src/components/CardDetails/DateCVVGroupOneRow.d.ts +4 -0
  268. package/lib/typescript/src/components/CardDetails/DateCVVGroupOneRow.d.ts.map +1 -0
  269. package/lib/typescript/src/components/CardDetails/styles.d.ts +90 -0
  270. package/lib/typescript/src/components/CardDetails/styles.d.ts.map +1 -0
  271. package/lib/typescript/src/components/ChangePin/CaptureCurrentPin.d.ts +4 -0
  272. package/lib/typescript/src/components/ChangePin/CaptureCurrentPin.d.ts.map +1 -0
  273. package/lib/typescript/src/components/ChangePin/CaptureNewPin.d.ts +4 -0
  274. package/lib/typescript/src/components/ChangePin/CaptureNewPin.d.ts.map +1 -0
  275. package/lib/typescript/src/components/ChangePin/ChangePin.d.ts +5 -0
  276. package/lib/typescript/src/components/ChangePin/ChangePin.d.ts.map +1 -0
  277. package/lib/typescript/src/components/ChangePin/ConfirmPin.d.ts +4 -0
  278. package/lib/typescript/src/components/ChangePin/ConfirmPin.d.ts.map +1 -0
  279. package/lib/typescript/src/components/ChangePin/ReenterNewPin.d.ts +4 -0
  280. package/lib/typescript/src/components/ChangePin/ReenterNewPin.d.ts.map +1 -0
  281. package/lib/typescript/src/components/ChangePin/styles.d.ts +22 -0
  282. package/lib/typescript/src/components/ChangePin/styles.d.ts.map +1 -0
  283. package/lib/typescript/src/components/NIButton/NIButton.d.ts +13 -0
  284. package/lib/typescript/src/components/NIButton/NIButton.d.ts.map +1 -0
  285. package/lib/typescript/src/components/NIButton/styles.d.ts +8 -0
  286. package/lib/typescript/src/components/NIButton/styles.d.ts.map +1 -0
  287. package/lib/typescript/src/components/Pin/CapturePin.d.ts +4 -0
  288. package/lib/typescript/src/components/Pin/CapturePin.d.ts.map +1 -0
  289. package/lib/typescript/src/components/Pin/NextButton.d.ts +4 -0
  290. package/lib/typescript/src/components/Pin/NextButton.d.ts.map +1 -0
  291. package/lib/typescript/src/components/Pin/ShowHideButton.d.ts +4 -0
  292. package/lib/typescript/src/components/Pin/ShowHideButton.d.ts.map +1 -0
  293. package/lib/typescript/src/components/Pin/styles.d.ts +54 -0
  294. package/lib/typescript/src/components/Pin/styles.d.ts.map +1 -0
  295. package/lib/typescript/src/components/PinState/LoadingState.d.ts +7 -0
  296. package/lib/typescript/src/components/PinState/LoadingState.d.ts.map +1 -0
  297. package/lib/typescript/src/components/PinState/PinState.d.ts +8 -0
  298. package/lib/typescript/src/components/PinState/PinState.d.ts.map +1 -0
  299. package/lib/typescript/src/components/SetPin/ConfirmPin.d.ts +4 -0
  300. package/lib/typescript/src/components/SetPin/ConfirmPin.d.ts.map +1 -0
  301. package/lib/typescript/src/components/SetPin/ReenterCardPin.d.ts +4 -0
  302. package/lib/typescript/src/components/SetPin/ReenterCardPin.d.ts.map +1 -0
  303. package/lib/typescript/src/components/SetPin/SetPin.d.ts +5 -0
  304. package/lib/typescript/src/components/SetPin/SetPin.d.ts.map +1 -0
  305. package/lib/typescript/src/components/SetPin/SetUpNewCardPin.d.ts +4 -0
  306. package/lib/typescript/src/components/SetPin/SetUpNewCardPin.d.ts.map +1 -0
  307. package/lib/typescript/src/components/SetPin/styles.d.ts +22 -0
  308. package/lib/typescript/src/components/SetPin/styles.d.ts.map +1 -0
  309. package/lib/typescript/src/components/VerifyPin/CaptureVerifyPin.d.ts +4 -0
  310. package/lib/typescript/src/components/VerifyPin/CaptureVerifyPin.d.ts.map +1 -0
  311. package/lib/typescript/src/components/VerifyPin/ConfirmPin.d.ts +5 -0
  312. package/lib/typescript/src/components/VerifyPin/ConfirmPin.d.ts.map +1 -0
  313. package/lib/typescript/src/components/VerifyPin/VerifyPin.d.ts +5 -0
  314. package/lib/typescript/src/components/VerifyPin/VerifyPin.d.ts.map +1 -0
  315. package/lib/typescript/src/components/VerifyPin/styles.d.ts +19 -0
  316. package/lib/typescript/src/components/VerifyPin/styles.d.ts.map +1 -0
  317. package/lib/typescript/src/components/ViewPin/ViewPin.d.ts +5 -0
  318. package/lib/typescript/src/components/ViewPin/ViewPin.d.ts.map +1 -0
  319. package/lib/typescript/src/components/ViewPin/styles.d.ts +12 -0
  320. package/lib/typescript/src/components/ViewPin/styles.d.ts.map +1 -0
  321. package/lib/typescript/src/components/icons/PredeterminedIcon.d.ts +7 -0
  322. package/lib/typescript/src/components/icons/PredeterminedIcon.d.ts.map +1 -0
  323. package/lib/typescript/src/config/configCard.d.ts +3 -0
  324. package/lib/typescript/src/config/configCard.d.ts.map +1 -0
  325. package/lib/typescript/src/config/localization.d.ts +39 -0
  326. package/lib/typescript/src/config/localization.d.ts.map +1 -0
  327. package/lib/typescript/src/config/themeColors.d.ts +29 -0
  328. package/lib/typescript/src/config/themeColors.d.ts.map +1 -0
  329. package/lib/typescript/src/hooks/useChangePin.d.ts +9 -0
  330. package/lib/typescript/src/hooks/useChangePin.d.ts.map +1 -0
  331. package/lib/typescript/src/hooks/useGetCardDetails.d.ts +9 -0
  332. package/lib/typescript/src/hooks/useGetCardDetails.d.ts.map +1 -0
  333. package/lib/typescript/src/hooks/useSetPin.d.ts +9 -0
  334. package/lib/typescript/src/hooks/useSetPin.d.ts.map +1 -0
  335. package/lib/typescript/src/hooks/useVerifyPin.d.ts +9 -0
  336. package/lib/typescript/src/hooks/useVerifyPin.d.ts.map +1 -0
  337. package/lib/typescript/src/hooks/useViewPin.d.ts +9 -0
  338. package/lib/typescript/src/hooks/useViewPin.d.ts.map +1 -0
  339. package/lib/typescript/src/index.d.ts +7 -0
  340. package/lib/typescript/src/index.d.ts.map +1 -0
  341. package/lib/typescript/src/interfaces/NiCardManagementInterfaces.d.ts +37 -0
  342. package/lib/typescript/src/interfaces/NiCardManagementInterfaces.d.ts.map +1 -0
  343. package/lib/typescript/src/interfaces/NiInputInterfaces.d.ts +62 -0
  344. package/lib/typescript/src/interfaces/NiInputInterfaces.d.ts.map +1 -0
  345. package/lib/typescript/src/interfaces/NiInterfaces.d.ts +232 -0
  346. package/lib/typescript/src/interfaces/NiInterfaces.d.ts.map +1 -0
  347. package/lib/typescript/src/nativeComponents/NICardManagementSDKModule.d.ts +4 -0
  348. package/lib/typescript/src/nativeComponents/NICardManagementSDKModule.d.ts.map +1 -0
  349. package/lib/typescript/src/utils/formatInput.d.ts +4 -0
  350. package/lib/typescript/src/utils/formatInput.d.ts.map +1 -0
  351. package/lib/typescript/src/utils/localization.d.ts +20 -0
  352. package/lib/typescript/src/utils/localization.d.ts.map +1 -0
  353. package/package.json +167 -0
  354. package/react-native-ni-card-management.podspec +43 -0
  355. package/src/NICardManagementComponents/CardDetailsComponent.tsx +77 -0
  356. package/src/NICardManagementComponents/ChangePinView.tsx +41 -0
  357. package/src/NICardManagementComponents/NiInputInterfaces.ts +14 -0
  358. package/src/NICardManagementComponents/SetPinView.tsx +38 -0
  359. package/src/NICardManagementComponents/VerifyPinView.tsx +42 -0
  360. package/src/NICardManagementComponents/ViewPinComponent.tsx +48 -0
  361. package/src/assets/icons/content-copy.png +0 -0
  362. package/src/assets/icons/eye-off-outline.png +0 -0
  363. package/src/assets/icons/eye-outline.png +0 -0
  364. package/src/assets/icons/icons8-arrow-100.png +0 -0
  365. package/src/assets/icons/icons8-arrow-100_1.png +0 -0
  366. package/src/assets/icons/red-eye-off-outline.png +0 -0
  367. package/src/assets/icons/red-eye-outline.png +0 -0
  368. package/src/assets/images/grayCard.png +0 -0
  369. package/src/components/CardDetails/CardDetails.tsx +24 -0
  370. package/src/components/CardDetails/CardDetailsBackgroundImage.tsx +33 -0
  371. package/src/components/CardDetails/CardDetailsGroups.tsx +119 -0
  372. package/src/components/CardDetails/CardHolderNameGroups.tsx +101 -0
  373. package/src/components/CardDetails/CardNumberGroup.tsx +101 -0
  374. package/src/components/CardDetails/DateCVVGroupOneRow.tsx +146 -0
  375. package/src/components/CardDetails/styles.ts +105 -0
  376. package/src/components/ChangePin/CaptureCurrentPin.tsx +39 -0
  377. package/src/components/ChangePin/CaptureNewPin.tsx +39 -0
  378. package/src/components/ChangePin/ChangePin.tsx +153 -0
  379. package/src/components/ChangePin/ConfirmPin.tsx +47 -0
  380. package/src/components/ChangePin/ReenterNewPin.tsx +45 -0
  381. package/src/components/ChangePin/styles.ts +24 -0
  382. package/src/components/NIButton/NIButton.tsx +57 -0
  383. package/src/components/NIButton/styles.ts +10 -0
  384. package/src/components/Pin/CapturePin.tsx +227 -0
  385. package/src/components/Pin/NextButton.tsx +50 -0
  386. package/src/components/Pin/ShowHideButton.tsx +53 -0
  387. package/src/components/Pin/styles.ts +56 -0
  388. package/src/components/PinState/LoadingState.tsx +30 -0
  389. package/src/components/PinState/PinState.tsx +33 -0
  390. package/src/components/SetPin/ConfirmPin.tsx +47 -0
  391. package/src/components/SetPin/ReenterCardPin.tsx +45 -0
  392. package/src/components/SetPin/SetPin.tsx +140 -0
  393. package/src/components/SetPin/SetUpNewCardPin.tsx +39 -0
  394. package/src/components/SetPin/styles.ts +24 -0
  395. package/src/components/VerifyPin/CaptureVerifyPin.tsx +39 -0
  396. package/src/components/VerifyPin/ConfirmPin.tsx +49 -0
  397. package/src/components/VerifyPin/VerifyPin.tsx +105 -0
  398. package/src/components/VerifyPin/styles.ts +21 -0
  399. package/src/components/ViewPin/ViewPin.tsx +99 -0
  400. package/src/components/ViewPin/styles.ts +14 -0
  401. package/src/components/icons/PredeterminedIcon.tsx +41 -0
  402. package/src/config/configCard.ts +2 -0
  403. package/src/config/localization.ts +44 -0
  404. package/src/config/themeColors.ts +37 -0
  405. package/src/hooks/useChangePin.ts +39 -0
  406. package/src/hooks/useGetCardDetails.ts +38 -0
  407. package/src/hooks/useSetPin.ts +37 -0
  408. package/src/hooks/useVerifyPin.ts +37 -0
  409. package/src/hooks/useViewPin.ts +35 -0
  410. package/src/index.tsx +6 -0
  411. package/src/interfaces/NiCardManagementInterfaces.ts +61 -0
  412. package/src/interfaces/NiInputInterfaces.ts +78 -0
  413. package/src/interfaces/NiInterfaces.ts +259 -0
  414. package/src/nativeComponents/NICardManagementSDKModule.ts +5 -0
  415. package/src/utils/formatInput.ts +8 -0
  416. package/src/utils/localization.ts +10 -0
@@ -0,0 +1,152 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = CapturePin;
7
+ var _react = _interopRequireWildcard(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _ShowHideButton = _interopRequireDefault(require("./ShowHideButton"));
10
+ var _styles = _interopRequireDefault(require("./styles"));
11
+ var _NiInputInterfaces = require("../../interfaces/NiInputInterfaces");
12
+ var _themeColors = require("../../config/themeColors");
13
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
14
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
15
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
16
+ function CapturePin({
17
+ setPin: {
18
+ pin,
19
+ setPin,
20
+ initialPin,
21
+ pinEditable
22
+ },
23
+ setNextStep: {
24
+ step,
25
+ setNextStep,
26
+ onConfirmPin
27
+ },
28
+ pinType,
29
+ title,
30
+ pinLabel,
31
+ wrongPinLabel,
32
+ pinLabelIndex,
33
+ showHideLabels,
34
+ theme,
35
+ input,
36
+ showPin
37
+ }) {
38
+ const [isShowHide, setIsShowHide] = (0, _react.useState)(false);
39
+ const inputRef = (0, _react.useRef)(null);
40
+ const [keyboardWillShow, setKeyboardWillShow] = (0, _react.useState)(false);
41
+ (0, _react.useEffect)(() => {
42
+ _reactNative.Keyboard.addListener('keyboardDidShow', () => {
43
+ setKeyboardWillShow(false);
44
+ });
45
+ _reactNative.Keyboard.addListener('keyboardWillShow', () => {
46
+ setKeyboardWillShow(true);
47
+ });
48
+ }, []);
49
+ const pinLength = pinType === _NiInputInterfaces.NIPinTypeEnum.dynamicFourToSix ? _NiInputInterfaces.NIPinTypeEnum.sixDigits : pinType;
50
+ const pinChars = [...[...(pin.length ? pin.toString() : '').padEnd(pinLength, ' ')].join('|')];
51
+ const pinInputError = {
52
+ color: 'red'
53
+ };
54
+ function handleKeyPress(event) {
55
+ const key = event.nativeEvent.key.toLowerCase();
56
+ pin.length < pinLength && ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'].includes(key) && setPin(pin + key);
57
+ ['backspace'].includes(key) && setPin(pin.substring(0, pin.length - 1));
58
+ }
59
+ const isPinDone = pinType === _NiInputInterfaces.NIPinTypeEnum.dynamicFourToSix ? pin.length >= _NiInputInterfaces.NIPinTypeEnum.fourDigits : pin.length === pinLength;
60
+ const isErrorPin = initialPin && isPinDone && initialPin !== pin;
61
+ function onSubmitEditing() {
62
+ if (isPinDone && !isErrorPin) {
63
+ onConfirmPin && onConfirmPin();
64
+ setNextStep && setNextStep(++step);
65
+ } else {
66
+ _reactNative.Keyboard.dismiss;
67
+ }
68
+ }
69
+ const labelFonts = input && input.displayAttributes && input.displayAttributes.fonts && input.displayAttributes.fonts.filter(item => item.label === pinLabelIndex);
70
+ let font = labelFonts && labelFonts.length && labelFonts[0]?.font;
71
+ font = font || {
72
+ name: 'Helvetica',
73
+ size: 17
74
+ };
75
+ const pinInputStyle = {
76
+ width: pinType === _NiInputInterfaces.NIPinTypeEnum.fourDigits ? '14%' : pinType === _NiInputInterfaces.NIPinTypeEnum.fiveDigits ? '11%' : '9%',
77
+ color: theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.color : _themeColors.themeColors.dark.color
78
+ };
79
+ const pinInputBorder = {
80
+ borderColor: theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.color : _themeColors.themeColors.dark.color
81
+ };
82
+ const titleStyle = {
83
+ color: theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.color : _themeColors.themeColors.dark.color,
84
+ fontSize: font.size,
85
+ fontFamily: font.name,
86
+ fontWeight: 'bold'
87
+ };
88
+ const pinLabelStyle = {
89
+ color: theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.color : _themeColors.themeColors.dark.color,
90
+ fontSize: font.size,
91
+ fontFamily: font.name
92
+ };
93
+ const viewPinCapturePinSectionSizes = pinLabelIndex === _NiInputInterfaces.NILabels.viewPinDescriptionLabel ? {
94
+ height: undefined,
95
+ width: undefined
96
+ } : {};
97
+ const viewPinPinInputViewTopMargin = pinLabelIndex === _NiInputInterfaces.NILabels.viewPinDescriptionLabel ? {
98
+ marginTop: undefined
99
+ } : {};
100
+ const keyboardAppearance = theme === _NiInputInterfaces.NIThemeEnum.light ? _NiInputInterfaces.NIThemeEnum.light : _NiInputInterfaces.NIThemeEnum.dark;
101
+ return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
102
+ style: [_styles.default.capturePinSection, viewPinCapturePinSectionSizes]
103
+ }, pinLabelIndex !== _NiInputInterfaces.NILabels.viewPinDescriptionLabel && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
104
+ style: _styles.default.titleSection
105
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
106
+ style: titleStyle
107
+ }, title)), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
108
+ style: _styles.default.pinSection
109
+ }, pinLabelIndex !== _NiInputInterfaces.NILabels.viewPinDescriptionLabel && /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
110
+ style: [pinLabelStyle, isErrorPin ? pinInputError : {}]
111
+ }, isErrorPin ? wrongPinLabel : pinLabel), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableWithoutFeedback, null, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
112
+ style: [_styles.default.pinInputView, pinInputBorder, viewPinPinInputViewTopMargin, _reactNative.I18nManager.isRTL ? {
113
+ flexDirection: 'row-reverse'
114
+ } : {}],
115
+ onTouchEnd: () => {
116
+ const isIos = _reactNative.Platform.OS === 'ios';
117
+ if (!_reactNative.Keyboard.isVisible()) {
118
+ if (isIos && keyboardWillShow) {
119
+ return;
120
+ }
121
+ _reactNative.Keyboard.dismiss();
122
+ inputRef.current?.focus();
123
+ }
124
+ }
125
+ }, pinChars.map((pinChar, index) => /*#__PURE__*/_react.default.createElement(_reactNative.TextInput, {
126
+ ref: inputRef,
127
+ onLayout: () => {
128
+ index === 0 && inputRef.current && inputRef.current.focus();
129
+ },
130
+ editable: pinLabelIndex === _NiInputInterfaces.NILabels.viewPinDescriptionLabel ? false : pinEditable && index === 2 * (pinLength - 1),
131
+ key: index,
132
+ placeholder: '',
133
+ style: [_styles.default.pinInput, pinInputStyle, isErrorPin && !(index % 2) ? pinInputError : {}],
134
+ inputMode: "decimal",
135
+ keyboardType: "numeric",
136
+ textAlign: "center",
137
+ caretHidden: true,
138
+ value: index % 2 || pinChar === ' ' || isShowHide || showPin ? pinChar : '*',
139
+ onKeyPress: event => handleKeyPress(event),
140
+ onSubmitEditing: onSubmitEditing,
141
+ maxLength: 1,
142
+ keyboardAppearance: keyboardAppearance
143
+ })))), pinLabelIndex !== _NiInputInterfaces.NILabels.viewPinDescriptionLabel && /*#__PURE__*/_react.default.createElement(_ShowHideButton.default, {
144
+ setShowHide: {
145
+ isShowHide,
146
+ setIsShowHide
147
+ },
148
+ showHideLabels: showHideLabels,
149
+ theme: theme
150
+ })));
151
+ }
152
+ //# sourceMappingURL=CapturePin.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_ShowHideButton","_interopRequireDefault","_styles","_NiInputInterfaces","_themeColors","obj","__esModule","default","_getRequireWildcardCache","e","WeakMap","r","t","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","prototype","hasOwnProperty","call","i","set","CapturePin","setPin","pin","initialPin","pinEditable","setNextStep","step","onConfirmPin","pinType","title","pinLabel","wrongPinLabel","pinLabelIndex","showHideLabels","theme","input","showPin","isShowHide","setIsShowHide","useState","inputRef","useRef","keyboardWillShow","setKeyboardWillShow","useEffect","Keyboard","addListener","pinLength","NIPinTypeEnum","dynamicFourToSix","sixDigits","pinChars","length","toString","padEnd","join","pinInputError","color","handleKeyPress","event","key","nativeEvent","toLowerCase","includes","substring","isPinDone","fourDigits","isErrorPin","onSubmitEditing","dismiss","labelFonts","displayAttributes","fonts","filter","item","label","font","name","size","pinInputStyle","width","fiveDigits","NIThemeEnum","light","themeColors","dark","pinInputBorder","borderColor","titleStyle","fontSize","fontFamily","fontWeight","pinLabelStyle","viewPinCapturePinSectionSizes","NILabels","viewPinDescriptionLabel","height","undefined","viewPinPinInputViewTopMargin","marginTop","keyboardAppearance","createElement","View","style","styles","capturePinSection","titleSection","Text","pinSection","TouchableWithoutFeedback","pinInputView","I18nManager","isRTL","flexDirection","onTouchEnd","isIos","Platform","OS","isVisible","current","focus","map","pinChar","index","TextInput","ref","onLayout","editable","placeholder","pinInput","inputMode","keyboardType","textAlign","caretHidden","value","onKeyPress","maxLength","setShowHide"],"sourceRoot":"../../../../src","sources":["components/Pin/CapturePin.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAaA,IAAAE,eAAA,GAAAC,sBAAA,CAAAH,OAAA;AACA,IAAAI,OAAA,GAAAD,sBAAA,CAAAH,OAAA;AACA,IAAAK,kBAAA,GAAAL,OAAA;AAMA,IAAAM,YAAA,GAAAN,OAAA;AAAuD,SAAAG,uBAAAI,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAAA,SAAAG,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAZ,wBAAAY,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,C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PyI,WAAW,EAAE;MAAEpG,UAAU;MAAEC;IAAc,CAAE;IAC3CL,cAAc,EAAEA,cAAe;IAC/BC,KAAK,EAAEA;EAAM,CACd,CAEC,CACF,CAAC;AAEX"}
@@ -0,0 +1,40 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = NextButton;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _styles = _interopRequireDefault(require("./styles"));
10
+ var _NiInputInterfaces = require("../../interfaces/NiInputInterfaces");
11
+ var _NiInterfaces = require("../../interfaces/NiInterfaces");
12
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
13
+ function NextButton({
14
+ setNextStep: {
15
+ step,
16
+ setNextStep
17
+ },
18
+ disabled,
19
+ theme
20
+ }) {
21
+ const nextButtonSource = theme === _NiInputInterfaces.NIThemeEnum.light ? require('../../assets/icons/icons8-arrow-100_1.png') : require('../../assets/icons/icons8-arrow-100.png');
22
+ const pinButtonStyle = {
23
+ opacity: disabled ? 0.3 : 1
24
+ };
25
+ const nextButtonStyle = {
26
+ width: 50,
27
+ height: 50,
28
+ borderRadius: 20
29
+ };
30
+ return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, (step === _NiInterfaces.NIStepEnum.currentPinStep || step === _NiInterfaces.NIStepEnum.setupPinStep) && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
31
+ style: [_styles.default.pinButton, pinButtonStyle]
32
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
33
+ onPress: () => setNextStep && setNextStep(++step),
34
+ disabled: disabled
35
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.ImageBackground, {
36
+ source: nextButtonSource,
37
+ style: [_styles.default.nextButton, nextButtonStyle]
38
+ }))));
39
+ }
40
+ //# sourceMappingURL=NextButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_styles","_NiInputInterfaces","_NiInterfaces","obj","__esModule","default","NextButton","setNextStep","step","disabled","theme","nextButtonSource","NIThemeEnum","light","pinButtonStyle","opacity","nextButtonStyle","width","height","borderRadius","createElement","Fragment","NIStepEnum","currentPinStep","setupPinStep","View","style","styles","pinButton","TouchableOpacity","onPress","ImageBackground","source","nextButton"],"sourceRoot":"../../../../src","sources":["components/Pin/NextButton.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAOA,IAAAE,OAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,kBAAA,GAAAH,OAAA;AACA,IAAAI,aAAA,GAAAJ,OAAA;AAA8E,SAAAD,uBAAAM,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAE/D,SAASG,UAAUA,CAAC;EACjCC,WAAW,EAAE;IAAEC,IAAI;IAAED;EAAY,CAAC;EAClCE,QAAQ;EACRC;AACY,CAAC,EAAe;EAC5B,MAAMC,gBAAgB,GACpBD,KAAK,KAAKE,8BAAW,CAACC,KAAK,GACtBf,OAAO,CAAC,2CAA2C,CAAC,GACpDA,OAAO,CAAC,yCAAyC,CAAoB;EAE5E,MAAMgB,cAAc,GAAG;IACrBC,OAAO,EAAEN,QAAQ,GAAG,GAAG,GAAG;EAC5B,CAAC;EACD,MAAMO,eAAe,GAAG;IACtBC,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE,EAAE;IACVC,YAAY,EAAE;EAChB,CAAC;EAED,oBACEvB,MAAA,CAAAS,OAAA,CAAAe,aAAA,CAAAxB,MAAA,CAAAS,OAAA,CAAAgB,QAAA,QACG,CAACb,IAAI,KAAKc,wBAAU,CAACC,cAAc,IAClCf,IAAI,KAAKc,wBAAU,CAACE,YAAY,kBAChC5B,MAAA,CAAAS,OAAA,CAAAe,aAAA,CAACrB,YAAA,CAAA0B,IAAI;IAACC,KAAK,EAAE,CAACC,eAAM,CAACC,SAAS,EAAEd,cAAc;EAAE,gBAC9ClB,MAAA,CAAAS,OAAA,CAAAe,aAAA,CAACrB,YAAA,CAAA8B,gBAAgB;IACfC,OAAO,EAAEA,CAAA,KAAMvB,WAAW,IAAIA,WAAW,CAAC,EAAEC,IAAI,CAAE;IAClDC,QAAQ,EAAEA;EAAS,gBAEnBb,MAAA,CAAAS,OAAA,CAAAe,aAAA,CAACrB,YAAA,CAAAgC,eAAe;IACdC,MAAM,EAAErB,gBAAiB;IACzBe,KAAK,EAAE,CAACC,eAAM,CAACM,UAAU,EAAEjB,eAAe;EAAE,CAC7C,CACe,CACd,CAER,CAAC;AAEP"}
@@ -0,0 +1,48 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = ShowHide;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _styles = _interopRequireDefault(require("./styles"));
10
+ var _themeColors = require("../../config/themeColors");
11
+ var _NiInputInterfaces = require("../../interfaces/NiInputInterfaces");
12
+ var _PredeterminedIcon = require("../icons/PredeterminedIcon");
13
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
14
+ function ShowHide({
15
+ setShowHide: {
16
+ isShowHide,
17
+ setIsShowHide
18
+ },
19
+ showHideLabels: {
20
+ show,
21
+ hide
22
+ },
23
+ theme
24
+ }) {
25
+ const color = theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.buttonShowHideTextColor : _themeColors.themeColors.dark.buttonShowHideTextColor;
26
+ const showHideTextButton = {
27
+ color: color
28
+ };
29
+ return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
30
+ style: [_styles.default.showHideButton, _reactNative.I18nManager.isRTL ? {
31
+ flexDirection: 'row'
32
+ } : {}]
33
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
34
+ onPress: () => setIsShowHide(!isShowHide)
35
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
36
+ style: [_styles.default.row, _reactNative.I18nManager.isRTL ? {
37
+ flexDirection: 'row-reverse'
38
+ } : {}]
39
+ }, /*#__PURE__*/_react.default.createElement(_PredeterminedIcon.PredeterminedIcon, {
40
+ name: isShowHide ? 'red-eye-off' : 'red-eye',
41
+ size: 20
42
+ }), isShowHide && /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
43
+ style: showHideTextButton
44
+ }, hide), !isShowHide && /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
45
+ style: showHideTextButton
46
+ }, show))));
47
+ }
48
+ //# sourceMappingURL=ShowHideButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_styles","_themeColors","_NiInputInterfaces","_PredeterminedIcon","obj","__esModule","default","ShowHide","setShowHide","isShowHide","setIsShowHide","showHideLabels","show","hide","theme","color","NIThemeEnum","light","themeColors","buttonShowHideTextColor","dark","showHideTextButton","createElement","View","style","styles","showHideButton","I18nManager","isRTL","flexDirection","TouchableOpacity","onPress","row","PredeterminedIcon","name","size","Text"],"sourceRoot":"../../../../src","sources":["components/Pin/ShowHideButton.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAQA,IAAAE,OAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,YAAA,GAAAH,OAAA;AACA,IAAAI,kBAAA,GAAAJ,OAAA;AAEA,IAAAK,kBAAA,GAAAL,OAAA;AAA+D,SAAAD,uBAAAO,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEhD,SAASG,QAAQA,CAAC;EAC/BC,WAAW,EAAE;IAAEC,UAAU;IAAEC;EAAc,CAAC;EAC1CC,cAAc,EAAE;IAAEC,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AAC;AAEX"}
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _reactNative = require("react-native");
8
+ const styles = _reactNative.StyleSheet.create({
9
+ capturePinSection: {
10
+ flexDirection: 'column',
11
+ marginTop: 2,
12
+ width: '80%',
13
+ height: 225,
14
+ justifyContent: 'space-between'
15
+ },
16
+ titleSection: {
17
+ flexDirection: 'column',
18
+ marginTop: 20,
19
+ alignSelf: 'center'
20
+ },
21
+ pinSection: {
22
+ flexDirection: 'column'
23
+ },
24
+ pinInputView: {
25
+ flexDirection: 'row',
26
+ marginTop: 15,
27
+ borderColor: 'gray',
28
+ color: 'gray',
29
+ borderWidth: 1,
30
+ borderRadius: 15,
31
+ paddingLeft: 16,
32
+ paddingRight: 16,
33
+ fontSize: 16,
34
+ height: 50
35
+ },
36
+ pinInput: {
37
+ borderColor: 'gray',
38
+ color: 'gray',
39
+ fontSize: 18,
40
+ height: 50
41
+ },
42
+ showHideButton: {
43
+ alignItems: 'flex-end',
44
+ paddingTop: 10
45
+ },
46
+ row: {
47
+ flexDirection: 'row',
48
+ flexWrap: 'wrap',
49
+ justifyContent: 'flex-start',
50
+ gap: 5
51
+ },
52
+ pinButton: {
53
+ alignSelf: 'flex-end',
54
+ marginBottom: 24
55
+ },
56
+ nextButton: {
57
+ borderRadius: 20
58
+ }
59
+ });
60
+ var _default = exports.default = styles;
61
+ //# sourceMappingURL=styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_reactNative","require","styles","StyleSheet","create","capturePinSection","flexDirection","marginTop","width","height","justifyContent","titleSection","alignSelf","pinSection","pinInputView","borderColor","color","borderWidth","borderRadius","paddingLeft","paddingRight","fontSize","pinInput","showHideButton","alignItems","paddingTop","row","flexWrap","gap","pinButton","marginBottom","nextButton","_default","exports","default"],"sourceRoot":"../../../../src","sources":["components/Pin/styles.ts"],"mappings":";;;;;;AAAA,IAAAA,YA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 value: true
5
+ });
6
+ exports.default = LoadingState;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _themeColors = require("../../config/themeColors");
10
+ var _NiInputInterfaces = require("../../interfaces/NiInputInterfaces");
11
+ var _configCard = require("../../config/configCard");
12
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
13
+ function LoadingState({
14
+ isLoading,
15
+ theme,
16
+ isCardDetails
17
+ }) {
18
+ const color = theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.colorActivityIndicator : _themeColors.themeColors.dark.colorActivityIndicator;
19
+ const LoadingIndicator = {
20
+ top: isCardDetails ? -(_configCard.HEIGHT_CARD + 24) / 2 : 250
21
+ };
22
+ return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
23
+ style: LoadingIndicator
24
+ }, isLoading && /*#__PURE__*/_react.default.createElement(_reactNative.ActivityIndicator, {
25
+ size: "small",
26
+ color: color
27
+ }));
28
+ }
29
+ //# sourceMappingURL=LoadingState.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_themeColors","_NiInputInterfaces","_configCard","obj","__esModule","default","LoadingState","isLoading","theme","isCardDetails","color","NIThemeEnum","light","themeColors","colorActivityIndicator","dark","LoadingIndicator","top","HEIGHT_CARD","createElement","View","style","ActivityIndicator","size"],"sourceRoot":"../../../../src","sources":["components/PinState/LoadingState.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,YAAA,GAAAF,OAAA;AACA,IAAAG,kBAAA,GAAAH,OAAA;AACA,IAAAI,WAAA,GAAAJ,OAAA;AAAsD,SAAAD,uBAAAM,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEvC,SAASG,YAAYA,CAAC;EACnCC,SAAS;EACTC,KAAK;EACLC;AAKF,CAAC,EAAe;EACd,MAAMC,KAAK,GACTF,KAAK,KAAKG,8BAAW,CAACC,KAAK,GACvBC,wBAAW,CAACD,KAAK,CAACE,sBAAsB,GACxCD,wBAAW,CAACE,IAAI,CAACD,sBAAsB;EAE7C,MAAME,gBAA2B,GAAG;IAClCC,GAAG,EAAER,aAAa,GAAG,EAAES,uBAAW,GAAG,EAAE,CAAC,GAAG,CAAC,GAAG;EACjD,CAAC;EACD,oBACEtB,MAAA,CAAAS,OAAA,CAAAc,aAAA,CAACpB,YAAA,CAAAqB,IAAI;IAACC,KAAK,EAAEL;EAAiB,GAC3BT,SAAS,iBAAIX,MAAA,CAAAS,OAAA,CAAAc,aAAA,CAACpB,YAAA,CAAAuB,iBAAiB;IAACC,IAAI,EAAC,OAAO;IAACb,KAAK,EAAEA;EAAM,CAAE,CACzD,CAAC;AAEX"}
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _LoadingState = _interopRequireDefault(require("./LoadingState"));
10
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
+ function PinState({
12
+ isLoading,
13
+ theme,
14
+ isCardDetails
15
+ }) {
16
+ const pinState = isCardDetails ? {} : {
17
+ position: 'absolute',
18
+ width: '100%'
19
+ };
20
+ return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
21
+ style: pinState
22
+ }, /*#__PURE__*/_react.default.createElement(_LoadingState.default, {
23
+ isLoading: isLoading,
24
+ theme: theme,
25
+ isCardDetails: isCardDetails
26
+ }));
27
+ }
28
+ var _default = exports.default = PinState;
29
+ //# sourceMappingURL=PinState.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_LoadingState","obj","__esModule","default","PinState","isLoading","theme","isCardDetails","pinState","position","width","createElement","View","style","_default","exports"],"sourceRoot":"../../../../src","sources":["components/PinState/PinState.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,aAAA,GAAAH,sBAAA,CAAAC,OAAA;AAA0C,SAAAD,uBAAAI,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAE1C,SAASG,QAAQA,CAAC;EAChBC,SAAS;EACTC,KAAK;EACLC;AAKF,CAAC,EAAe;EACd,MAAMC,QAAmB,GAAGD,aAAa,GACrC,CAAC,CAAC,GACF;IACEE,QAAQ,EAAE,UAAU;IACpBC,KAAK,EAAE;EACT,CAAC;EAEL,oBACEd,MAAA,CAAAO,OAAA,CAAAQ,aAAA,CAACZ,YAAA,CAAAa,IAAI;IAACC,KAAK,EAAEL;EAAS,gBACpBZ,MAAA,CAAAO,OAAA,CAAAQ,aAAA,CAACX,aAAA,CAAAG,OAAY;IACXE,SAAS,EAAEA,SAAU;IACrBC,KAAK,EAAEA,KAAM;IACbC,aAAa,EAAEA;EAAc,CAC9B,CACG,CAAC;AAEX;AAAC,IAAAO,QAAA,GAAAC,OAAA,CAAAZ,OAAA,GAEcC,QAAQ"}
@@ -0,0 +1,39 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = ConfirmPin;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _NiInputInterfaces = require("../../interfaces/NiInputInterfaces");
10
+ var _themeColors = require("../../config/themeColors");
11
+ var _NIButton = require("../NIButton/NIButton");
12
+ var _styles = _interopRequireDefault(require("./styles"));
13
+ var _localization = _interopRequireDefault(require("../../utils/localization"));
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+ function ConfirmPin({
16
+ language,
17
+ theme,
18
+ disabled,
19
+ onConfirmPin
20
+ }) {
21
+ const buttonConfirmColorDisabled = theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.buttonConfirmColorDisabled : _themeColors.themeColors.dark.buttonConfirmColorDisabled;
22
+ const confirmButton = {
23
+ backgroundColor: buttonConfirmColorDisabled,
24
+ borderRadius: 20
25
+ };
26
+ const confirmPinButtonsLinearGradientColors = theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.confirmPinButtonsLinearGradientColors : _themeColors.themeColors.dark.confirmPinButtonsLinearGradientColors;
27
+ const textColor = theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.buttonConfirmTextColor : _themeColors.themeColors.dark.buttonConfirmTextColor;
28
+ return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
29
+ style: [_styles.default.confirmButton, confirmButton]
30
+ }, /*#__PURE__*/_react.default.createElement(_NIButton.NIButton, {
31
+ title: (0, _localization.default)(language).setPinButtonLabel,
32
+ mode: "text",
33
+ disabled: disabled,
34
+ textColor: textColor,
35
+ colors: confirmPinButtonsLinearGradientColors,
36
+ onPress: onConfirmPin
37
+ }));
38
+ }
39
+ //# sourceMappingURL=ConfirmPin.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_NiInputInterfaces","_themeColors","_NIButton","_styles","_localization","obj","__esModule","default","ConfirmPin","language","theme","disabled","onConfirmPin","buttonConfirmColorDisabled","NIThemeEnum","light","themeColors","dark","confirmButton","backgroundColor","borderRadius","confirmPinButtonsLinearGradientColors","textColor","buttonConfirmTextColor","createElement","View","style","styles","NIButton","title","localLabels","setPinButtonLabel","mode","colors","onPress"],"sourceRoot":"../../../../src","sources":["components/SetPin/ConfirmPin.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE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IACnBW,SAAS,EAAEA,SAAU;IACrBW,MAAM,EAAEZ,qCAAsC;IAC9Ca,OAAO,EAAEtB;EAAa,CACvB,CACG,CAAC;AAEX"}
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = ReenterCardPin;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _NiInputInterfaces = require("../../interfaces/NiInputInterfaces");
9
+ var _NiInterfaces = require("../../interfaces/NiInterfaces");
10
+ var _CapturePin = _interopRequireDefault(require("../Pin/CapturePin"));
11
+ var _localization = _interopRequireDefault(require("../../utils/localization"));
12
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
13
+ function ReenterCardPin({
14
+ setPin: {
15
+ confirmationPin,
16
+ setConfirmationPin,
17
+ pin,
18
+ pinEditable
19
+ },
20
+ setNextStep: {
21
+ step,
22
+ onConfirmPin
23
+ },
24
+ pinType,
25
+ language,
26
+ theme,
27
+ input
28
+ }) {
29
+ return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, step === _NiInterfaces.NIStepEnum.reEnterPinStep && /*#__PURE__*/_react.default.createElement(_CapturePin.default, {
30
+ setPin: {
31
+ pin: confirmationPin,
32
+ setPin: setConfirmationPin,
33
+ initialPin: pin,
34
+ pinEditable
35
+ },
36
+ setNextStep: {
37
+ step,
38
+ onConfirmPin
39
+ },
40
+ pinType: pinType,
41
+ title: (0, _localization.default)(language).setPinButtonLabel,
42
+ pinLabel: (0, _localization.default)(language).confirmCardPIN,
43
+ wrongPinLabel: (0, _localization.default)(language).wrongCardPin,
44
+ pinLabelIndex: _NiInputInterfaces.NILabels.setPinDescriptionLabel,
45
+ showHideLabels: {
46
+ show: (0, _localization.default)(language).show,
47
+ hide: (0, _localization.default)(language).hide
48
+ },
49
+ theme: theme,
50
+ input: input
51
+ }));
52
+ }
53
+ //# sourceMappingURL=ReenterCardPin.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_NiInputInterfaces","_NiInterfaces","_CapturePin","_localization","obj","__esModule","default","ReenterCardPin","setPin","confirmationPin","setConfirmationPin","pin","pinEditable","setNextStep","step","onConfirmPin","pinType","language","theme","input","createElement","Fragment","NIStepEnum","reEnterPinStep","initialPin","title","localLabels","setPinButtonLabel","pinLabel","confirmCardPIN","wrongPinLabel","wrongCardPin","pinLabelIndex","NILabels","setPinDescriptionLabel","showHideLabels","show","hide"],"sourceRoot":"../../../../src","sources":["components/SetPin/ReenterCardPin.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAEA,IAAAC,kBAAA,GAAAD,OAAA;AACA,IAAAE,aAAA,GAAAF,OAAA;AAIA,IAAAG,WAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,aAAA,GAAAL,sBAAA,CAAAC,OAAA;AAAmD,SAAAD,uBAAAM,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEpC,SAASG,cAAcA,CAAC;EACrCC,MAAM,EAAE;IAAEC,eAAe;IAAEC,kBAAkB;IAAEC,GAAG;IAAEC;EAAY,CAAC;EACjEC,WAAW,EAAE;IAAEC,IAAI;IAAEC;EAAa,CAAC;EACnCC,OAAO;EACPC,QAAQ;EACRC,KAAK;EACLC;AACgB,CAAC,EAAe;EAChC,oBACEtB,MAAA,CAAAS,OAAA,CAAAc,aAAA,CAAAvB,MAAA,CAAAS,OAAA,CAAAe,QAAA,QACGP,IAAI,KAAKQ,wBAAU,CAACC,cAAc,iBACjC1B,MAAA,CAAAS,OAAA,CAAAc,aAAA,CAAClB,WAAA,CAAAI,OAAU;IACTE,MAAM,EAAE;MACNG,GAAG,EAAEF,eAAe;MACpBD,MAAM,EAAEE,kBAAkB;MAC1Bc,UAAU,EAAEb,GAAG;MACfC;IACF,CAAE;IACFC,WAAW,EAAE;MAAEC,IAAI;MAAEC;IAAa,CAAE;IACpCC,OAAO,EAAEA,OAAQ;IACjBS,KAAK,EAAE,IAAAC,qBAAW,EAACT,QAAQ,CAAC,CAACU,iBAAkB;IAC/CC,QAAQ,EAAE,IAAAF,qBAAW,EAACT,QAAQ,CAAC,CAACY,cAAe;IAC/CC,aAAa,EAAE,IAAAJ,qBAAW,EAACT,QAAQ,CAAC,CAACc,YAAa;IAClDC,aAAa,EAAEC,2BAAQ,CAACC,sBAAuB;IAC/CC,cAAc,EAAE;MACdC,IAAI,EAAE,IAAAV,qBAAW,EAACT,QAAQ,CAAC,CAACmB,IAAI;MAChCC,IAAI,EAAE,IAAAX,qBAAW,EAACT,QAAQ,CAAC,CAACoB;IAC9B,CAAE;IACFnB,KAAK,EAAEA,KAAM;IACbC,KAAK,EAAEA;EAAM,CACd,CAEH,CAAC;AAEP"}
@@ -0,0 +1,118 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _react = _interopRequireWildcard(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _NiInputInterfaces = require("../../interfaces/NiInputInterfaces");
10
+ var _NiInterfaces = require("../../interfaces/NiInterfaces");
11
+ var _SetUpNewCardPin = _interopRequireDefault(require("./SetUpNewCardPin"));
12
+ var _ReenterCardPin = _interopRequireDefault(require("./ReenterCardPin"));
13
+ var _NextButton = _interopRequireDefault(require("../Pin/NextButton"));
14
+ var _ConfirmPin = _interopRequireDefault(require("./ConfirmPin"));
15
+ var _styles = _interopRequireDefault(require("./styles"));
16
+ var _themeColors = require("../../config/themeColors");
17
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
18
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
19
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
20
+ function SetPin({
21
+ input,
22
+ pinType,
23
+ result,
24
+ isLoading,
25
+ onSetPin,
26
+ callback
27
+ }) {
28
+ const [pin, setPin] = (0, _react.useState)('');
29
+ const [confirmationPin, setConfirmationPin] = (0, _react.useState)('');
30
+ const [step, setNextStep] = (0, _react.useState)(_NiInterfaces.NIStepEnum.setupPinStep);
31
+ const [pinEditable, setPinEditable] = (0, _react.useState)(true);
32
+ const [keyboardHeight, setKeyboardHeight] = (0, _react.useState)(0);
33
+ const [initialKeyboardHeight, setInitialKeyboardHeight] = (0, _react.useState)(0);
34
+ const language = input && input.displayAttributes?.language || _NiInputInterfaces.NILanguageEnum.english;
35
+ const theme = input?.displayAttributes?.theme || _NiInputInterfaces.NIThemeEnum.light;
36
+ const container = {
37
+ backgroundColor: theme === _NiInputInterfaces.NIThemeEnum.light ? _themeColors.themeColors.light.background : _themeColors.themeColors.dark.background,
38
+ paddingBottom: _reactNative.Platform.OS === 'ios' ? keyboardHeight : 0
39
+ };
40
+ const isVisibleConfirmationButtonStep = step === _NiInterfaces.NIStepEnum.reEnterPinStep;
41
+ const isVisibleConfirmationButton = isVisibleConfirmationButtonStep && pin === confirmationPin;
42
+ const disabled = !isVisibleConfirmationButton || isLoading || !!result;
43
+ const pinLength = pinType === _NiInputInterfaces.NIPinTypeEnum.dynamicFourToSix ? _NiInputInterfaces.NIPinTypeEnum.sixDigits : pinType;
44
+ const isPinDone = pinType === _NiInputInterfaces.NIPinTypeEnum.dynamicFourToSix ? pin.length >= _NiInputInterfaces.NIPinTypeEnum.fourDigits : pin.length === pinLength;
45
+ function onConfirmPin() {
46
+ !disabled && input && onSetPin && onSetPin(pin, input, callback);
47
+ setPinEditable(false);
48
+ }
49
+ (0, _react.useEffect)(() => {
50
+ _reactNative.Keyboard.addListener('keyboardDidShow', () => {
51
+ const metrics = _reactNative.Keyboard.metrics();
52
+ if (!initialKeyboardHeight) {
53
+ setInitialKeyboardHeight(metrics?.height || 0);
54
+ }
55
+ setKeyboardHeight(metrics?.height || 0);
56
+ });
57
+ _reactNative.Keyboard.addListener('keyboardWillHide', () => {
58
+ setKeyboardHeight(0);
59
+ });
60
+ _reactNative.Keyboard.addListener('keyboardWillShow', () => {
61
+ if (initialKeyboardHeight) {
62
+ setKeyboardHeight(initialKeyboardHeight);
63
+ }
64
+ });
65
+ }, [initialKeyboardHeight]);
66
+ return /*#__PURE__*/_react.default.createElement(_reactNative.TouchableWithoutFeedback, {
67
+ onPress: _reactNative.Keyboard.dismiss
68
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
69
+ style: [_styles.default.container, container]
70
+ }, /*#__PURE__*/_react.default.createElement(_SetUpNewCardPin.default, {
71
+ setPin: {
72
+ pin,
73
+ setPin,
74
+ pinEditable
75
+ },
76
+ setNextStep: {
77
+ step,
78
+ setNextStep
79
+ },
80
+ pinType: pinType,
81
+ language: language,
82
+ theme: theme,
83
+ input: input
84
+ }), /*#__PURE__*/_react.default.createElement(_ReenterCardPin.default, {
85
+ setPin: {
86
+ confirmationPin,
87
+ setConfirmationPin,
88
+ pin,
89
+ pinEditable
90
+ },
91
+ setNextStep: {
92
+ step,
93
+ onConfirmPin
94
+ },
95
+ pinType: pinType,
96
+ language: language,
97
+ theme: theme,
98
+ input: input
99
+ }), !isVisibleConfirmationButtonStep && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
100
+ style: [_styles.default.capturePinSection, _reactNative.I18nManager.isRTL ? {
101
+ flexDirection: 'row'
102
+ } : {}]
103
+ }, /*#__PURE__*/_react.default.createElement(_NextButton.default, {
104
+ setNextStep: {
105
+ step,
106
+ setNextStep
107
+ },
108
+ disabled: !isPinDone,
109
+ theme: theme
110
+ })), isVisibleConfirmationButtonStep && /*#__PURE__*/_react.default.createElement(_ConfirmPin.default, {
111
+ language: language,
112
+ theme: theme,
113
+ disabled: !pinEditable || disabled,
114
+ onConfirmPin: onConfirmPin
115
+ })));
116
+ }
117
+ var _default = exports.default = SetPin;
118
+ //# sourceMappingURL=SetPin.js.map