@pagopa/io-app-design-system 1.3.1 → 1.4.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.
Files changed (128) hide show
  1. package/README.md +1 -0
  2. package/lib/commonjs/components/accordion/AccordionItem.js +137 -0
  3. package/lib/commonjs/components/accordion/AccordionItem.js.map +1 -0
  4. package/lib/commonjs/components/accordion/index.js +4 -4
  5. package/lib/commonjs/components/accordion/index.js.map +1 -1
  6. package/lib/commonjs/components/common/LogoPaymentWithFallback.js +49 -0
  7. package/lib/commonjs/components/common/LogoPaymentWithFallback.js.map +1 -0
  8. package/lib/commonjs/components/index.js +11 -0
  9. package/lib/commonjs/components/index.js.map +1 -1
  10. package/lib/commonjs/components/listitems/ListItemTransaction.js +47 -29
  11. package/lib/commonjs/components/listitems/ListItemTransaction.js.map +1 -1
  12. package/lib/commonjs/components/pictograms/svg/PictogramFocusOn.js +6 -6
  13. package/lib/commonjs/components/pictograms/svg/PictogramFocusOn.js.map +1 -1
  14. package/lib/commonjs/components/{accordion/IOAccordion.js → textInput/TextInput.js} +5 -27
  15. package/lib/commonjs/components/textInput/TextInput.js.map +1 -0
  16. package/lib/commonjs/components/textInput/TextInputBase.js +233 -0
  17. package/lib/commonjs/components/textInput/TextInputBase.js.map +1 -0
  18. package/lib/commonjs/components/textInput/TextInputPassword.js +36 -0
  19. package/lib/commonjs/components/textInput/TextInputPassword.js.map +1 -0
  20. package/lib/commonjs/components/textInput/TextInputValidation.js +57 -0
  21. package/lib/commonjs/components/textInput/TextInputValidation.js.map +1 -0
  22. package/lib/commonjs/components/textInput/index.js +39 -0
  23. package/lib/commonjs/components/textInput/index.js.map +1 -0
  24. package/lib/commonjs/core/IOAnimations.js +5 -0
  25. package/lib/commonjs/core/IOAnimations.js.map +1 -1
  26. package/lib/commonjs/core/IOShapes.js +3 -1
  27. package/lib/commonjs/core/IOShapes.js.map +1 -1
  28. package/lib/commonjs/utils/accessibility.js +19 -0
  29. package/lib/commonjs/utils/accessibility.js.map +1 -0
  30. package/lib/commonjs/utils/object.js +16 -0
  31. package/lib/commonjs/utils/object.js.map +1 -0
  32. package/lib/commonjs/utils/textInput/index.js +24 -0
  33. package/lib/commonjs/utils/textInput/index.js.map +1 -0
  34. package/lib/commonjs/utils/url.js +14 -0
  35. package/lib/commonjs/utils/url.js.map +1 -0
  36. package/lib/module/components/accordion/AccordionItem.js +126 -0
  37. package/lib/module/components/accordion/AccordionItem.js.map +1 -0
  38. package/lib/module/components/accordion/index.js +1 -1
  39. package/lib/module/components/accordion/index.js.map +1 -1
  40. package/lib/module/components/common/LogoPaymentWithFallback.js +40 -0
  41. package/lib/module/components/common/LogoPaymentWithFallback.js.map +1 -0
  42. package/lib/module/components/index.js +1 -0
  43. package/lib/module/components/index.js.map +1 -1
  44. package/lib/module/components/listitems/ListItemTransaction.js +48 -30
  45. package/lib/module/components/listitems/ListItemTransaction.js.map +1 -1
  46. package/lib/module/components/pictograms/svg/PictogramFocusOn.js +7 -7
  47. package/lib/module/components/pictograms/svg/PictogramFocusOn.js.map +1 -1
  48. package/lib/module/components/textInput/TextInput.js +4 -0
  49. package/lib/module/components/textInput/TextInput.js.map +1 -0
  50. package/lib/module/components/textInput/TextInputBase.js +225 -0
  51. package/lib/module/components/textInput/TextInputBase.js.map +1 -0
  52. package/lib/module/components/textInput/TextInputPassword.js +27 -0
  53. package/lib/module/components/textInput/TextInputPassword.js.map +1 -0
  54. package/lib/module/components/textInput/TextInputValidation.js +47 -0
  55. package/lib/module/components/textInput/TextInputValidation.js.map +1 -0
  56. package/lib/module/components/textInput/index.js +4 -0
  57. package/lib/module/components/textInput/index.js.map +1 -0
  58. package/lib/module/core/IOAnimations.js +5 -0
  59. package/lib/module/core/IOAnimations.js.map +1 -1
  60. package/lib/module/core/IOShapes.js +1 -0
  61. package/lib/module/core/IOShapes.js.map +1 -1
  62. package/lib/module/utils/accessibility.js +10 -0
  63. package/lib/module/utils/accessibility.js.map +1 -0
  64. package/lib/module/utils/object.js +7 -0
  65. package/lib/module/utils/object.js.map +1 -0
  66. package/lib/module/utils/textInput/index.js +17 -0
  67. package/lib/module/utils/textInput/index.js.map +1 -0
  68. package/lib/module/utils/url.js +7 -0
  69. package/lib/module/utils/url.js.map +1 -0
  70. package/lib/typescript/components/accordion/AccordionItem.d.ts +14 -0
  71. package/lib/typescript/components/accordion/AccordionItem.d.ts.map +1 -0
  72. package/lib/typescript/components/accordion/index.d.ts +1 -1
  73. package/lib/typescript/components/accordion/index.d.ts.map +1 -1
  74. package/lib/typescript/components/common/LogoPaymentWithFallback.d.ts +27 -0
  75. package/lib/typescript/components/common/LogoPaymentWithFallback.d.ts.map +1 -0
  76. package/lib/typescript/components/index.d.ts +1 -0
  77. package/lib/typescript/components/index.d.ts.map +1 -1
  78. package/lib/typescript/components/listitems/ListItemTransaction.d.ts +13 -5
  79. package/lib/typescript/components/listitems/ListItemTransaction.d.ts.map +1 -1
  80. package/lib/typescript/components/textInput/TextInput.d.ts +6 -0
  81. package/lib/typescript/components/textInput/TextInput.d.ts.map +1 -0
  82. package/lib/typescript/components/textInput/TextInputBase.d.ts +28 -0
  83. package/lib/typescript/components/textInput/TextInputBase.d.ts.map +1 -0
  84. package/lib/typescript/components/textInput/TextInputPassword.d.ts +6 -0
  85. package/lib/typescript/components/textInput/TextInputPassword.d.ts.map +1 -0
  86. package/lib/typescript/components/textInput/TextInputValidation.d.ts +9 -0
  87. package/lib/typescript/components/textInput/TextInputValidation.d.ts.map +1 -0
  88. package/lib/typescript/components/textInput/index.d.ts +4 -0
  89. package/lib/typescript/components/textInput/index.d.ts.map +1 -0
  90. package/lib/typescript/core/IOAnimations.d.ts +5 -0
  91. package/lib/typescript/core/IOAnimations.d.ts.map +1 -1
  92. package/lib/typescript/core/IOShapes.d.ts +1 -0
  93. package/lib/typescript/core/IOShapes.d.ts.map +1 -1
  94. package/lib/typescript/utils/accessibility.d.ts +6 -0
  95. package/lib/typescript/utils/accessibility.d.ts.map +1 -0
  96. package/lib/typescript/utils/object.d.ts +5 -0
  97. package/lib/typescript/utils/object.d.ts.map +1 -0
  98. package/lib/typescript/utils/textInput/index.d.ts +9 -0
  99. package/lib/typescript/utils/textInput/index.d.ts.map +1 -0
  100. package/lib/typescript/utils/types.d.ts +1 -0
  101. package/lib/typescript/utils/types.d.ts.map +1 -1
  102. package/lib/typescript/utils/url.d.ts +8 -0
  103. package/lib/typescript/utils/url.d.ts.map +1 -0
  104. package/package.json +1 -1
  105. package/src/components/accordion/AccordionItem.tsx +165 -0
  106. package/src/components/accordion/index.tsx +1 -1
  107. package/src/components/common/LogoPaymentWithFallback.tsx +60 -0
  108. package/src/components/index.tsx +1 -0
  109. package/src/components/listitems/ListItemTransaction.tsx +86 -39
  110. package/src/components/pictograms/svg/PictogramFocusOn.tsx +9 -9
  111. package/src/components/textInput/TextInput.tsx +15 -0
  112. package/src/components/textInput/TextInputBase.tsx +327 -0
  113. package/src/components/textInput/TextInputPassword.tsx +36 -0
  114. package/src/components/textInput/TextInputValidation.tsx +71 -0
  115. package/src/components/textInput/index.tsx +3 -0
  116. package/src/core/IOAnimations.ts +5 -0
  117. package/src/core/IOShapes.ts +1 -0
  118. package/src/utils/accessibility.ts +17 -0
  119. package/src/utils/object.ts +12 -0
  120. package/src/utils/textInput/index.ts +29 -0
  121. package/src/utils/types.ts +2 -0
  122. package/src/utils/url.ts +9 -0
  123. package/lib/commonjs/components/accordion/IOAccordion.js.map +0 -1
  124. package/lib/module/components/accordion/IOAccordion.js +0 -26
  125. package/lib/module/components/accordion/IOAccordion.js.map +0 -1
  126. package/lib/typescript/components/accordion/IOAccordion.d.ts +0 -13
  127. package/lib/typescript/components/accordion/IOAccordion.d.ts.map +0 -1
  128. package/src/components/accordion/IOAccordion.tsx +0 -35
@@ -0,0 +1,225 @@
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
+ /* eslint-disable functional/immutable-data */
3
+ import { Pressable, StyleSheet, TextInput, View } from "react-native";
4
+ import React, { useCallback, useEffect, useMemo, useRef } from "react";
5
+ import Animated, { Easing, useAnimatedStyle, useSharedValue, withTiming } from "react-native-reanimated";
6
+ import { IOColors, IOSpacingScale, IOStyles } from "../../core";
7
+ import { Icon } from "../icons";
8
+ import { HSpacer } from "../spacer";
9
+ import { LabelSmall } from "../typography";
10
+ import { getInputPropsByType } from "../../utils/textInput";
11
+ const styles = StyleSheet.create({
12
+ textInput: {
13
+ ...IOStyles.row,
14
+ alignItems: "center",
15
+ paddingVertical: 8,
16
+ height: 60,
17
+ borderRadius: 8,
18
+ paddingHorizontal: 12
19
+ },
20
+ textInputStyle: {
21
+ ...IOStyles.flex,
22
+ fontSize: 16,
23
+ marginTop: IOSpacingScale[2],
24
+ fontWeight: "400",
25
+ lineHeight: 24,
26
+ fontFamily: "Readex Pro",
27
+ height: "100%"
28
+ },
29
+ textInputLabelWrapper: {
30
+ position: "absolute",
31
+ paddingHorizontal: 12,
32
+ zIndex: 10,
33
+ bottom: 0,
34
+ top: 0,
35
+ justifyContent: "center"
36
+ }
37
+ });
38
+ const HelperRow = _ref => {
39
+ let {
40
+ value,
41
+ counterLimit,
42
+ bottomMessage,
43
+ bottomMessageColor = "grey-700"
44
+ } = _ref;
45
+ const valueCount = useMemo(() => value.length, [value]);
46
+ const helperRowStyle = useMemo(() => {
47
+ if (counterLimit && bottomMessage) {
48
+ return {
49
+ justifyContent: "space-between"
50
+ };
51
+ }
52
+ if (counterLimit) {
53
+ return {
54
+ justifyContent: "flex-end"
55
+ };
56
+ }
57
+ if (bottomMessage) {
58
+ return {
59
+ justifyContent: "flex-start"
60
+ };
61
+ }
62
+ return {};
63
+ }, [counterLimit, bottomMessage]);
64
+ return /*#__PURE__*/React.createElement(View, {
65
+ style: [IOStyles.row, {
66
+ alignItems: "center",
67
+ paddingHorizontal: 10
68
+ }, helperRowStyle]
69
+ }, bottomMessage && /*#__PURE__*/React.createElement(LabelSmall, {
70
+ weight: "Regular",
71
+ color: bottomMessageColor
72
+ }, bottomMessage), counterLimit && /*#__PURE__*/React.createElement(LabelSmall, {
73
+ weight: "Regular",
74
+ color: "grey-700"
75
+ }, `${valueCount} / ${counterLimit}`));
76
+ };
77
+ export const TextInputBase = _ref2 => {
78
+ let {
79
+ disabled = false,
80
+ placeholder,
81
+ value = "",
82
+ onChangeText,
83
+ accessibilityLabel,
84
+ textInputProps,
85
+ inputTyoe = "default",
86
+ status,
87
+ icon,
88
+ rightElement,
89
+ counterLimit,
90
+ bottomMessage,
91
+ bottomMessageColor,
92
+ onBlur,
93
+ onFocus,
94
+ isPassword
95
+ } = _ref2;
96
+ const labelSharedValue = useSharedValue(false);
97
+ const [inputStatus, setInputStatus] = React.useState(disabled ? "disabled" : "initial");
98
+ const isSecretInput = useMemo(() => isPassword, [isPassword]);
99
+ const inputRef = useRef(null);
100
+ useEffect(() => {
101
+ if (status) {
102
+ setInputStatus(status);
103
+ }
104
+ }, [status]);
105
+ const boxStyle = useMemo(() => {
106
+ if (inputStatus === "focused") {
107
+ return {
108
+ borderColor: IOColors["blueIO-500"],
109
+ borderWidth: 2
110
+ };
111
+ }
112
+ if (inputStatus === "error") {
113
+ return {
114
+ borderColor: IOColors["error-600"],
115
+ borderWidth: 1
116
+ };
117
+ }
118
+ return {
119
+ borderColor: IOColors["grey-200"],
120
+ borderWidth: 1
121
+ };
122
+ }, [inputStatus]);
123
+ const animatedLabelProps = useAnimatedStyle(() => ({
124
+ fontSize: withTiming(labelSharedValue.value ? 12 : 16, {
125
+ duration: 300,
126
+ easing: Easing.elastic(0.85)
127
+ }),
128
+ transform: [{
129
+ translateY: withTiming(labelSharedValue.value ? -14 : 0, {
130
+ duration: 300,
131
+ easing: Easing.elastic(0.85)
132
+ })
133
+ }]
134
+ }));
135
+ useEffect(() => {
136
+ if (value.length > 0) {
137
+ labelSharedValue.value = true;
138
+ } else {
139
+ if (inputStatus !== "focused") {
140
+ labelSharedValue.value = false;
141
+ }
142
+ }
143
+ }, [labelSharedValue, value, inputStatus]);
144
+ const onTextInputPress = () => {
145
+ var _inputRef$current;
146
+ if (disabled) {
147
+ return;
148
+ }
149
+ labelSharedValue.value = true;
150
+ setInputStatus("focused");
151
+ inputRef === null || inputRef === void 0 ? void 0 : (_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.focus();
152
+ };
153
+ const onChangeTextHandler = useCallback(text => {
154
+ if (counterLimit && text.length > counterLimit) {
155
+ return;
156
+ }
157
+ onChangeText(text);
158
+ }, [counterLimit, onChangeText]);
159
+ const onBlurHandler = useCallback(() => {
160
+ if (!value) {
161
+ labelSharedValue.value = false;
162
+ }
163
+ onBlur === null || onBlur === void 0 ? void 0 : onBlur();
164
+ setInputStatus("initial");
165
+ }, [value, labelSharedValue, onBlur]);
166
+ const derivedInputProps = useMemo(() => getInputPropsByType(inputTyoe), [inputTyoe]);
167
+ const inputValue = useMemo(() => derivedInputProps && derivedInputProps.valueFormat ? derivedInputProps.valueFormat(value) : value, [value, derivedInputProps]);
168
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Pressable, {
169
+ onPress: onTextInputPress,
170
+ style: [inputStatus === "disabled" ? {
171
+ opacity: 0.5
172
+ } : {}, boxStyle, styles.textInput],
173
+ accessible: false,
174
+ accessibilityRole: "none"
175
+ }, icon && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Icon, {
176
+ name: icon,
177
+ color: "grey-300",
178
+ size: 24
179
+ }), /*#__PURE__*/React.createElement(HSpacer, {
180
+ size: 8
181
+ })), /*#__PURE__*/React.createElement(TextInput, _extends({}, derivedInputProps ? derivedInputProps.textInputProps : textInputProps, {
182
+ accessible: true,
183
+ editable: !disabled,
184
+ secureTextEntry: isSecretInput,
185
+ disableFullscreenUI: true,
186
+ blurOnSubmit: true,
187
+ ref: inputRef,
188
+ accessibilityState: {
189
+ disabled
190
+ },
191
+ accessibilityLabel: accessibilityLabel ?? placeholder,
192
+ onFocus: () => {
193
+ setInputStatus("focused");
194
+ labelSharedValue.value = true;
195
+ onFocus === null || onFocus === void 0 ? void 0 : onFocus();
196
+ },
197
+ maxLength: counterLimit,
198
+ onBlur: onBlurHandler,
199
+ value: inputValue,
200
+ onChangeText: onChangeTextHandler,
201
+ style: styles.textInputStyle
202
+ })), /*#__PURE__*/React.createElement(Animated.View, {
203
+ style: [styles.textInputLabelWrapper, icon ? {
204
+ left: 32
205
+ } : {}]
206
+ }, /*#__PURE__*/React.createElement(Animated.Text, {
207
+ numberOfLines: 1,
208
+ accessible: false,
209
+ style: [animatedLabelProps, {
210
+ color: IOColors["grey-700"]
211
+ }]
212
+ }, placeholder)), rightElement && /*#__PURE__*/React.createElement(View, {
213
+ style: {
214
+ marginLeft: "auto"
215
+ }
216
+ }, /*#__PURE__*/React.createElement(HSpacer, {
217
+ size: 8
218
+ }), rightElement)), (bottomMessage || counterLimit) && /*#__PURE__*/React.createElement(HelperRow, {
219
+ value: value,
220
+ bottomMessage: bottomMessage,
221
+ bottomMessageColor: bottomMessageColor,
222
+ counterLimit: counterLimit
223
+ }));
224
+ };
225
+ //# sourceMappingURL=TextInputBase.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Pressable","StyleSheet","TextInput","View","React","useCallback","useEffect","useMemo","useRef","Animated","Easing","useAnimatedStyle","useSharedValue","withTiming","IOColors","IOSpacingScale","IOStyles","Icon","HSpacer","LabelSmall","getInputPropsByType","styles","create","textInput","row","alignItems","paddingVertical","height","borderRadius","paddingHorizontal","textInputStyle","flex","fontSize","marginTop","fontWeight","lineHeight","fontFamily","textInputLabelWrapper","position","zIndex","bottom","top","justifyContent","HelperRow","_ref","value","counterLimit","bottomMessage","bottomMessageColor","valueCount","length","helperRowStyle","createElement","style","weight","color","TextInputBase","_ref2","disabled","placeholder","onChangeText","accessibilityLabel","textInputProps","inputTyoe","status","icon","rightElement","onBlur","onFocus","isPassword","labelSharedValue","inputStatus","setInputStatus","useState","isSecretInput","inputRef","boxStyle","borderColor","borderWidth","animatedLabelProps","duration","easing","elastic","transform","translateY","onTextInputPress","_inputRef$current","current","focus","onChangeTextHandler","text","onBlurHandler","derivedInputProps","inputValue","valueFormat","Fragment","onPress","opacity","accessible","accessibilityRole","name","size","_extends","editable","secureTextEntry","disableFullscreenUI","blurOnSubmit","ref","accessibilityState","maxLength","left","Text","numberOfLines","marginLeft"],"sourceRoot":"../../../../src","sources":["components/textInput/TextInputBase.tsx"],"mappings":";AAAA;AACA,SACEA,SAAS,EACTC,UAAU,EACVC,SAAS,EACTC,IAAI,QAEC,cAAc;AACrB,OAAOC,KAAK,IAAIC,WAAW,EAAEC,SAAS,EAAEC,OAAO,EAAEC,MAAM,QAAQ,OAAO;AACtE,OAAOC,QAAQ,IACbC,MAAM,EACNC,gBAAgB,EAChBC,cAAc,EACdC,UAAU,QACL,yBAAyB;AAChC,SAASC,QAAQ,EAAEC,cAAc,EAAEC,QAAQ,QAAQ,YAAY;AAC/D,SAAkBC,IAAI,QAAQ,UAAU;AACxC,SAASC,OAAO,QAAQ,WAAW;AACnC,SAASC,UAAU,QAAQ,eAAe;AAE1C,SAASC,mBAAmB,QAAQ,uBAAuB;AA4B3D,MAAMC,MAAM,GAAGpB,UAAU,CAACqB,MAAM,CAAC;EAC/BC,SAAS,EAAE;IACT,GAAGP,QAAQ,CAACQ,GAAG;IACfC,UAAU,EAAE,QAAQ;IACpBC,eAAe,EAAE,CAAC;IAClBC,MAAM,EAAE,EAAE;IACVC,YAAY,EAAE,CAAC;IACfC,iBAAiB,EAAE;EACrB,CAAC;EACDC,cAAc,EAAE;IACd,GAAGd,QAAQ,CAACe,IAAI;IAChBC,QAAQ,EAAE,EAAE;IACZC,SAAS,EAAElB,cAAc,CAAC,CAAC,CAAC;IAC5BmB,UAAU,EAAE,KAAK;IACjBC,UAAU,EAAE,EAAE;IACdC,U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BACX9D,KAAA,CAAAgD,aAAA,CAACjD,IAAI;IAACkD,KAAK,EAAE;MAAE4D,UAAU,EAAE;IAAO;EAAE,gBAClC7G,KAAA,CAAAgD,aAAA,CAAClC,OAAO;IAACmF,IAAI,EAAE;EAAE,CAAE,CAAC,EACnBnC,YACG,CAEC,CAAC,EACX,CAACnB,aAAa,IAAID,YAAY,kBAC7B1C,KAAA,CAAAgD,aAAA,CAACT,SAAS;IACRE,KAAK,EAAEA,KAAM;IACbE,aAAa,EAAEA,aAAc;IAC7BC,kBAAkB,EAAEA,kBAAmB;IACvCF,YAAY,EAAEA;EAAa,CAC5B,CAEH,CAAC;AAEP,CAAC"}
@@ -0,0 +1,27 @@
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
+ import * as React from "react";
3
+ import { IconButton } from "../buttons";
4
+ import { TextInputBase } from "./TextInputBase";
5
+ export const TextInputPassword = props => {
6
+ const {
7
+ onBlur,
8
+ disabled
9
+ } = props;
10
+ const [showPassword, setShowPassword] = React.useState(false);
11
+ const rightElement = /*#__PURE__*/React.createElement(IconButton, {
12
+ icon: showPassword ? "eyeShow" : "eyeHide",
13
+ disabled: disabled,
14
+ onPress: () => setShowPassword(v => !v),
15
+ accessibilityLabel: "Toggle secret input"
16
+ });
17
+ const onBlurHandler = React.useCallback(() => {
18
+ setShowPassword(false);
19
+ onBlur === null || onBlur === void 0 ? void 0 : onBlur();
20
+ }, [onBlur]);
21
+ return /*#__PURE__*/React.createElement(TextInputBase, _extends({}, props, {
22
+ onBlur: onBlurHandler,
23
+ rightElement: rightElement,
24
+ isPassword: !showPassword
25
+ }));
26
+ };
27
+ //# sourceMappingURL=TextInputPassword.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","IconButton","TextInputBase","TextInputPassword","props","onBlur","disabled","showPassword","setShowPassword","useState","rightElement","createElement","icon","onPress","v","accessibilityLabel","onBlurHandler","useCallback","_extends","isPassword"],"sourceRoot":"../../../../src","sources":["components/textInput/TextInputPassword.tsx"],"mappings":";AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,UAAU,QAAQ,YAAY;AACvC,SAASC,aAAa,QAAQ,iBAAiB;AAO/C,OAAO,MAAMC,iBAAiB,GAAIC,KAA6B,IAAK;EAClE,MAAM;IAAEC,MAAM;IAAEC;EAAS,CAAC,GAAGF,KAAK;EAClC,MAAM,CAACG,YAAY,EAAEC,eAAe,CAAC,GAAGR,KAAK,CAACS,QAAQ,CAAU,KAAK,CAAC;EAEtE,MAAMC,YAAY,gBAChBV,KAAA,CAAAW,aAAA,CAACV,UAAU;IACTW,IAAI,EAAEL,YAAY,GAAG,SAAS,GAAG,SAAU;IAC3CD,QAAQ,EAAEA,QAAS;IACnBO,OAAO,EAAEA,CAAA,KAAML,eAAe,CAACM,CAAC,IAAI,CAACA,CAAC,CAAE;IACxCC,kBAAkB,EAAC;EAAqB,CACzC,CACF;EAED,MAAMC,aAAa,GAAGhB,KAAK,CAACiB,WAAW,CAAC,MAAM;IAC5CT,eAAe,CAAC,KAAK,CAAC;IACtBH,MAAM,aAANA,MAAM,uBAANA,MAAM,CAAG,CAAC;EACZ,CAAC,EAAE,CAACA,MAAM,CAAC,CAAC;EAEZ,oBACEL,KAAA,CAAAW,aAAA,CAACT,aAAa,EAAAgB,QAAA,KACRd,KAAK;IACTC,MAAM,EAAEW,aAAc;IACtBN,YAAY,EAAEA,YAAa;IAC3BS,UAAU,EAAE,CAACZ;EAAa,EAC3B,CAAC;AAEN,CAAC"}
@@ -0,0 +1,47 @@
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
+ import * as React from "react";
3
+ import { Icon } from "../icons";
4
+ import { triggerHaptic } from "../../functions";
5
+ import { TextInputBase } from "./TextInputBase";
6
+ export const TextInputValidation = props => {
7
+ const {
8
+ onValidate,
9
+ errorMessage,
10
+ value,
11
+ bottomMessage,
12
+ onBlur,
13
+ onFocus
14
+ } = props;
15
+ const [isValid, setIsValid] = React.useState(undefined);
16
+ const onBlurHandler = React.useCallback(() => {
17
+ const validation = onValidate(value);
18
+ setIsValid(validation);
19
+ if (!validation) {
20
+ triggerHaptic("notificationError");
21
+ } else {
22
+ triggerHaptic("notificationSuccess");
23
+ }
24
+ onBlur === null || onBlur === void 0 ? void 0 : onBlur();
25
+ }, [onValidate, value, onBlur]);
26
+ const onFocusHandler = React.useCallback(() => {
27
+ setIsValid(undefined);
28
+ onFocus === null || onFocus === void 0 ? void 0 : onFocus();
29
+ }, [onFocus]);
30
+ const labelError = React.useMemo(() => isValid === false && errorMessage ? errorMessage : bottomMessage, [isValid, errorMessage, bottomMessage]);
31
+ const labelErrorColor = React.useMemo(() => isValid === false && errorMessage ? "error-600" : undefined, [isValid, errorMessage]);
32
+ const rightIcon = React.useMemo(() => isValid !== undefined && /*#__PURE__*/React.createElement(Icon, {
33
+ name: isValid ? "success" : "errorFilled",
34
+ color: isValid ? "green" : "error-600",
35
+ size: 24
36
+ }), [isValid]);
37
+ return /*#__PURE__*/React.createElement(TextInputBase, _extends({}, props, {
38
+ status: isValid === false ? "error" : undefined,
39
+ bottomMessage: labelError,
40
+ bottomMessageColor: labelErrorColor,
41
+ rightElement: rightIcon,
42
+ onBlur: onBlurHandler,
43
+ onFocus: onFocusHandler
44
+ }));
45
+ };
46
+ export default TextInputValidation;
47
+ //# sourceMappingURL=TextInputValidation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","Icon","triggerHaptic","TextInputBase","TextInputValidation","props","onValidate","errorMessage","value","bottomMessage","onBlur","onFocus","isValid","setIsValid","useState","undefined","onBlurHandler","useCallback","validation","onFocusHandler","labelError","useMemo","labelErrorColor","rightIcon","createElement","name","color","size","_extends","status","bottomMessageColor","rightElement"],"sourceRoot":"../../../../src","sources":["components/textInput/TextInputValidation.tsx"],"mappings":";AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAAkBC,IAAI,QAAQ,UAAU;AAExC,SAASC,aAAa,QAAQ,iBAAiB;AAC/C,SAASC,aAAa,QAAQ,iBAAiB;AAU/C,OAAO,MAAMC,mBAAmB,GAAIC,KAA+B,IAAK;EACtE,MAAM;IAAEC,UAAU;IAAEC,YAAY;IAAEC,KAAK;IAAEC,aAAa;IAAEC,MAAM;IAAEC;EAAQ,CAAC,GACvEN,KAAK;EACP,MAAM,CAACO,OAAO,EAAEC,UAAU,CAAC,GAAGb,KAAK,CAACc,QAAQ,CAAsBC,SAAS,CAAC;EAE5E,MAAMC,aAAa,GAAGhB,KAAK,CAACiB,WAAW,CAAC,MAAM;IAC5C,MAAMC,UAAU,GAAGZ,UAAU,CAACE,KAAK,CAAC;IACpCK,UAAU,CAACK,UAAU,CAAC;IACtB,IAAI,CAACA,UAAU,EAAE;MACfhB,aAAa,CAAC,mBAAmB,CAAC;IACpC,CAAC,MAAM;MACLA,aAAa,CAAC,qBAAqB,CAAC;IACtC;IACAQ,MAAM,aAANA,MAAM,uBAANA,MAAM,CAAG,CAAC;EACZ,CAAC,EAAE,CAACJ,UAAU,EAAEE,KAAK,EAAEE,MAAM,CAAC,CAAC;EAE/B,MAAMS,cAAc,GAAGnB,KAAK,CAACiB,WAAW,CAAC,MAAM;IAC7CJ,UAAU,CAACE,SAAS,CAAC;IACrBJ,OAAO,aAAPA,OAAO,uBAAPA,OAAO,CAAG,CAAC;EACb,CAAC,EAAE,CAACA,OAAO,CAAC,CAAC;EAEb,MAAMS,UAAU,GAAGpB,KAAK,CAACqB,OAAO,CAC9B,MAAOT,OAAO,KAAK,KAAK,IAAIL,YAAY,GAAGA,YAAY,GAAGE,aAAc,EACxE,CAACG,OAAO,EAAEL,YAAY,EAAEE,aAAa,CACvC,CAAC;EAED,MAAMa,eAAqC,GAAGtB,KAAK,CAACqB,OAAO,CACzD,MAAOT,OAAO,KAAK,KAAK,IAAIL,YAAY,GAAG,WAAW,GAAGQ,SAAU,EACnE,CAACH,OAAO,EAAEL,YAAY,CACxB,CAAC;EAED,MAAMgB,SAAS,GAAGvB,KAAK,CAACqB,OAAO,CAC7B,MACET,OAAO,KAAKG,SAAS,iBACnBf,KAAA,CAAAwB,aAAA,CAACvB,IAAI;IACHwB,IAAI,EAAGb,OAAO,GAAG,SAAS,GAAG,aAA0B;IACvDc,KAAK,EAAGd,OAAO,GAAG,OAAO,GAAG,WAAyB;IACrDe,IAAI,EAAE;EAAG,CACV,CACF,EACH,CAACf,OAAO,CACV,CAAC;EAED,oBACEZ,KAAA,CAAAwB,aAAA,CAACrB,aAAa,EAAAyB,QAAA,KACRvB,KAAK;IACTwB,MAAM,EAAEjB,OAAO,KAAK,KAAK,GAAG,OAAO,GAAGG,SAAU;IAChDN,aAAa,EAAEW,UAAW;IAC1BU,kBAAkB,EAAER,eAAgB;IACpCS,YAAY,EAAER,SAAU;IACxBb,MAAM,EAAEM,aAAc;IACtBL,OAAO,EAAEQ;EAAe,EACzB,CAAC;AAEN,CAAC;AAED,eAAef,mBAAmB"}
@@ -0,0 +1,4 @@
1
+ export * from "./TextInput";
2
+ export * from "./TextInputPassword";
3
+ export * from "./TextInputValidation";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sourceRoot":"../../../../src","sources":["components/textInput/index.tsx"],"mappings":"AAAA,cAAc,aAAa;AAC3B,cAAc,qBAAqB;AACnC,cAAc,uBAAuB"}
@@ -9,6 +9,11 @@ export const IOSpringValues = {
9
9
  mass: 0.5,
10
10
  stiffness: 300
11
11
  },
12
+ accordion: {
13
+ damping: 30,
14
+ mass: 1,
15
+ stiffness: 325
16
+ },
12
17
  /* Used by selection items (checkbox, radio, etc…) */
13
18
  selection: {
14
19
  damping: 10,
@@ -1 +1 @@
1
- {"version":3,"names":["IOSpringValues","button","damping","mass","stiffness","selection","IOScaleValues","basicButton","pressedState","magnifiedButton","exaggeratedButton"],"sourceRoot":"../../../src","sources":["core/IOAnimations.ts"],"mappings":"AAAA;AACA;AACA;;AAEA,OAAO,MAAMA,cAAc,GAAG;EAC5B;EACAC,MAAM,EAAE;IACNC,OAAO,EAAE,EAAE;IACXC,IAAI,EAAE,GAAG;IACTC,SAAS,EAAE;EACb,CAAC;EACD;EACAC,SAAS,EAAE;IACTH,OAAO,EAAE,EAAE;IACXC,IAAI,EAAE,GAAG;IACTC,SAAS,EAAE;EACb;AACF,CAAC;AAED,OAAO,MAAME,aAAa,GAAG;EAC3B;EACAC,WAAW,EAAE;IACXC,YAAY,EAAE;EAChB,CAAC;EACD;EACAC,eAAe,EAAE;IACfD,YAAY,EAAE;EAChB,CAAC;EACD;EACAE,iBAAiB,EAAE;IACjBF,YAAY,EAAE;EAChB;AACF,CAAC"}
1
+ {"version":3,"names":["IOSpringValues","button","damping","mass","stiffness","accordion","selection","IOScaleValues","basicButton","pressedState","magnifiedButton","exaggeratedButton"],"sourceRoot":"../../../src","sources":["core/IOAnimations.ts"],"mappings":"AAAA;AACA;AACA;;AAEA,OAAO,MAAMA,cAAc,GAAG;EAC5B;EACAC,MAAM,EAAE;IACNC,OAAO,EAAE,EAAE;IACXC,IAAI,EAAE,GAAG;IACTC,SAAS,EAAE;EACb,CAAC;EACDC,SAAS,EAAE;IACTH,OAAO,EAAE,EAAE;IACXC,IAAI,EAAE,CAAC;IACPC,SAAS,EAAE;EACb,CAAC;EACD;EACAE,SAAS,EAAE;IACTJ,OAAO,EAAE,EAAE;IACXC,IAAI,EAAE,GAAG;IACTC,SAAS,EAAE;EACb;AACF,CAAC;AAED,OAAO,MAAMG,aAAa,GAAG;EAC3B;EACAC,WAAW,EAAE;IACXC,YAAY,EAAE;EAChB,CAAC;EACD;EACAC,eAAe,EAAE;IACfD,YAAY,EAAE;EAChB,CAAC;EACD;EACAE,iBAAiB,EAAE;IACjBF,YAAY,EAAE;EAChB;AACF,CAAC"}
@@ -16,4 +16,5 @@ export const IOTagRadius = 6;
16
16
  export const IOBottomSheetHeaderRadius = 24;
17
17
  export const IOListItemIDPRadius = IODefaultRadius;
18
18
  export const IOBadgeRadius = 24;
19
+ export const IOAccordionRadius = IODefaultRadius;
19
20
  //# sourceMappingURL=IOShapes.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["IORadiusScale","IODefaultRadius","IOAlertRadius","IOBannerRadius","IOTagRadius","IOBottomSheetHeaderRadius","IOListItemIDPRadius","IOBadgeRadius"],"sourceRoot":"../../../src","sources":["core/IOShapes.ts"],"mappings":"AAAA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMA,aAAa,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,CAAU;AAGpD,MAAMC,eAA8B,GAAG,CAAC;;AAExC;AACA;AACA;AACA,OAAO,MAAMC,aAA4B,GAAGD,eAAe;AAC3D,OAAO,MAAME,cAA6B,GAAGF,eAAe;AAC5D,OAAO,MAAMG,WAA0B,GAAG,CAAC;AAC3C,OAAO,MAAMC,yBAAwC,GAAG,EAAE;AAC1D,OAAO,MAAMC,mBAAkC,GAAGL,eAAe;AACjE,OAAO,MAAMM,aAA4B,GAAG,EAAE"}
1
+ {"version":3,"names":["IORadiusScale","IODefaultRadius","IOAlertRadius","IOBannerRadius","IOTagRadius","IOBottomSheetHeaderRadius","IOListItemIDPRadius","IOBadgeRadius","IOAccordionRadius"],"sourceRoot":"../../../src","sources":["core/IOShapes.ts"],"mappings":"AAAA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMA,aAAa,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,CAAU;AAGpD,MAAMC,eAA8B,GAAG,CAAC;;AAExC;AACA;AACA;AACA,OAAO,MAAMC,aAA4B,GAAGD,eAAe;AAC3D,OAAO,MAAME,cAA6B,GAAGF,eAAe;AAC5D,OAAO,MAAMG,WAA0B,GAAG,CAAC;AAC3C,OAAO,MAAMC,yBAAwC,GAAG,EAAE;AAC1D,OAAO,MAAMC,mBAAkC,GAAGL,eAAe;AACjE,OAAO,MAAMM,aAA4B,GAAG,EAAE;AAC9C,OAAO,MAAMC,iBAAgC,GAAGP,eAAe"}
@@ -0,0 +1,10 @@
1
+ import { pipe } from "fp-ts/lib/function";
2
+ import * as O from "fp-ts/lib/Option";
3
+ import I18n from "i18n-js";
4
+
5
+ /**
6
+ * This function is used to get the text that will be read by the screen reader
7
+ * with the correct minus symbol pronunciation.
8
+ */
9
+ export const getAccessibleAmountText = amount => pipe(amount, O.fromNullable, O.map(amount => amount.replace("-", I18n.t("global.accessibility.minusSymbol"))), O.getOrElseW(() => undefined));
10
+ //# sourceMappingURL=accessibility.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["pipe","O","I18n","getAccessibleAmountText","amount","fromNullable","map","replace","t","getOrElseW","undefined"],"sourceRoot":"../../../src","sources":["utils/accessibility.ts"],"mappings":"AAAA,SAASA,IAAI,QAAQ,oBAAoB;AACzC,OAAO,KAAKC,CAAC,MAAM,kBAAkB;AACrC,OAAOC,IAAI,MAAM,SAAS;;AAE1B;AACA;AACA;AACA;AACA,OAAO,MAAMC,uBAAuB,GAAIC,MAAe,IACrDJ,IAAI,CACFI,MAAM,EACNH,CAAC,CAACI,YAAY,EACdJ,CAAC,CAACK,GAAG,CAACF,MAAM,IACVA,MAAM,CAACG,OAAO,CAAC,GAAG,EAAEL,IAAI,CAACM,CAAC,CAAC,kCAAkC,CAAC,CAChE,CAAC,EACDP,CAAC,CAACQ,UAAU,CAAC,MAAMC,SAAS,CAC9B,CAAC"}
@@ -0,0 +1,7 @@
1
+ import * as A from "fp-ts/Array";
2
+ import { pipe } from "fp-ts/lib/function";
3
+ export const findFirstCaseInsensitive = obj => key => pipe(obj, Object.entries, A.findFirst(_ref => {
4
+ let [k, _] = _ref;
5
+ return k.toLowerCase() === key.toLowerCase();
6
+ }));
7
+ //# sourceMappingURL=object.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["A","pipe","findFirstCaseInsensitive","obj","key","Object","entries","findFirst","_ref","k","_","toLowerCase"],"sourceRoot":"../../../src","sources":["utils/object.ts"],"mappings":"AAAA,OAAO,KAAKA,CAAC,MAAM,aAAa;AAEhC,SAASC,IAAI,QAAQ,oBAAoB;AAEzC,OAAO,MAAMC,wBAAwB,GAC/BC,GAAyB,IAC5BC,GAAW,IACVH,IAAI,CACFE,GAAG,EACHE,MAAM,CAACC,OAAO,EACdN,CAAC,CAACO,SAAS,CAACC,IAAA;EAAA,IAAC,CAACC,CAAC,EAAEC,CAAC,CAAC,GAAAF,IAAA;EAAA,OAAKC,CAAC,CAACE,WAAW,CAAC,CAAC,KAAKP,GAAG,CAACO,WAAW,CAAC,CAAC;AAAA,EAC/D,CAAC"}
@@ -0,0 +1,17 @@
1
+ export const getInputPropsByType = type => {
2
+ switch (type) {
3
+ case "credit-card":
4
+ return {
5
+ valueFormat: v => v.replace(/\D/g, "").replace(/\d{4}?(?=.)/g, "$& "),
6
+ textInputProps: {
7
+ autoComplete: "cc-number",
8
+ keyboardType: "numeric",
9
+ textContentType: "creditCardNumber",
10
+ inputMode: "numeric"
11
+ }
12
+ };
13
+ default:
14
+ return undefined;
15
+ }
16
+ };
17
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["getInputPropsByType","type","valueFormat","v","replace","textInputProps","autoComplete","keyboardType","textContentType","inputMode","undefined"],"sourceRoot":"../../../../src","sources":["utils/textInput/index.ts"],"mappings":"AAWA,OAAO,MAAMA,mBAAmB,GAC9BC,IAAe,IACY;EAC3B,QAAQA,IAAI;IACV,KAAK,aAAa;MAChB,OAAO;QACLC,WAAW,EAAEC,CAAC,IAAIA,CAAC,CAACC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAACA,OAAO,CAAC,cAAc,EAAE,KAAK,CAAC;QACrEC,cAAc,EAAE;UACdC,YAAY,EAAE,WAAW;UACzBC,YAAY,EAAE,SAAS;UACvBC,eAAe,EAAE,kBAAkB;UACnCC,SAAS,EAAE;QACb;MACF,CAAC;IACH;MACE,OAAOC,SAAS;EACpB;AACF,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * type guard to check if a value is an ImageURISource
3
+ * @argument value the value to check, can be anything
4
+ * @returns boolean
5
+ */
6
+ export const isImageUri = value => typeof value === "object" && value !== null && "uri" in value;
7
+ //# sourceMappingURL=url.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["isImageUri","value"],"sourceRoot":"../../../src","sources":["utils/url.ts"],"mappings":"AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMA,UAAU,GAAIC,KAAc,IACvC,OAAOA,KAAK,KAAK,QAAQ,IAAIA,KAAK,KAAK,IAAI,IAAI,KAAK,IAAIA,KAAK"}
@@ -0,0 +1,14 @@
1
+ import React from "react";
2
+ export type AccordionItem = {
3
+ id: number;
4
+ title: string;
5
+ body: string | React.ReactNode;
6
+ };
7
+ type AccordionBody = {
8
+ children: React.ReactNode;
9
+ expanded: boolean;
10
+ };
11
+ export declare const AccordionBody: ({ children, expanded }: AccordionBody) => React.JSX.Element;
12
+ export declare const AccordionItem: ({ title, body }: AccordionItem) => React.JSX.Element;
13
+ export {};
14
+ //# sourceMappingURL=AccordionItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AccordionItem.d.ts","sourceRoot":"","sources":["../../../../src/components/accordion/AccordionItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAoBxC,MAAM,MAAM,aAAa,GAAG;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC;CAChC,CAAC;AAEF,KAAK,aAAa,GAAG;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC;AAUF,eAAO,MAAM,aAAa,2BAA4B,aAAa,sBA6BlE,CAAC;AAEF,eAAO,MAAM,aAAa,oBAAqB,aAAa,sBAgE3D,CAAC"}
@@ -1,3 +1,3 @@
1
1
  export * from "./RawAccordion";
2
- export * from "./IOAccordion";
2
+ export * from "./AccordionItem";
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/accordion/index.tsx"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/accordion/index.tsx"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC"}
@@ -0,0 +1,27 @@
1
+ import * as React from "react";
2
+ import { IOColors } from "../../core";
3
+ import { IOIconSizeScale } from "../icons";
4
+ import { IOLogoPaymentExtType } from "../logos";
5
+ export type LogoPaymentWithFallback = {
6
+ brand?: string;
7
+ fallbackIconColor?: IOColors;
8
+ size?: IOIconSizeScale;
9
+ isExtended?: boolean;
10
+ };
11
+ export type LogoPaymentExtOrDefaultIconProps = {
12
+ cardIcon?: IOLogoPaymentExtType;
13
+ fallbackIconColor?: IOColors;
14
+ size?: IOIconSizeScale;
15
+ };
16
+ /**
17
+ * This component renders either
18
+ * - a LogoPayment/LogoPaymentExt component
19
+ * - a default credit card icon
20
+ * @param cardIcon: IOLogoPaymentType icon
21
+ * @param size: the size of the icon (standard is 24/48)
22
+ * @param fallbackIconColor: default icon color (standard is grey-700)
23
+ * @param isExtended: if true, renders a LogoPaymentExt component
24
+ * @returns a LogoPayment/LogopaymentExt component if the cardIcon is supported, a default credit card icon otherwise
25
+ */
26
+ export declare const LogoPaymentWithFallback: ({ brand, fallbackIconColor, isExtended, size }: LogoPaymentWithFallback) => React.JSX.Element;
27
+ //# sourceMappingURL=LogoPaymentWithFallback.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LogoPaymentWithFallback.d.ts","sourceRoot":"","sources":["../../../../src/components/common/LogoPaymentWithFallback.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,eAAe,EAAQ,MAAM,UAAU,CAAC;AACjD,OAAO,EACL,oBAAoB,EAMrB,MAAM,UAAU,CAAC;AAElB,MAAM,MAAM,uBAAuB,GAAG;IACpC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,iBAAiB,CAAC,EAAE,QAAQ,CAAC;IAC7B,IAAI,CAAC,EAAE,eAAe,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,CAAC;AACF,MAAM,MAAM,gCAAgC,GAAG;IAC7C,QAAQ,CAAC,EAAE,oBAAoB,CAAC;IAChC,iBAAiB,CAAC,EAAE,QAAQ,CAAC;IAC7B,IAAI,CAAC,EAAE,eAAe,CAAC;CACxB,CAAC;AACF;;;;;;;;;GASG;AACH,eAAO,MAAM,uBAAuB,mDAKjC,uBAAuB,sBAkBzB,CAAC"}
@@ -17,4 +17,5 @@ export * from "./switch";
17
17
  export * from "./tag";
18
18
  export * from "./tabs";
19
19
  export * from "./typography";
20
+ export * from "./textInput";
20
21
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.tsx"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.tsx"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC"}
@@ -3,20 +3,28 @@ import { ImageURISource } from "react-native";
3
3
  import { WithTestID } from "../../utils/types";
4
4
  import { IOLogoPaymentType } from "../logos";
5
5
  import { PressableBaseProps } from "./PressableListItemsBase";
6
- type LogoNameOrUri = IOLogoPaymentType | ImageURISource;
6
+ export type ListItemTransactionStatus = "success" | "failure" | "pending" | "cancelled" | "refunded" | "reversal";
7
+ type PaymentLogoIcon = IOLogoPaymentType | ImageURISource | React.ReactNode;
7
8
  export type ListItemTransaction = WithTestID<PressableBaseProps & {
8
9
  hasChevronRight?: boolean;
9
10
  isLoading?: boolean;
10
- paymentLogoOrUrl?: LogoNameOrUri;
11
+ /**
12
+ * A logo that will be displayed on the left of the list item.
13
+ *
14
+ * Must be a {@link IOLogoPaymentType} or an {@link ImageURISource} or an {@link Icon}.
15
+ */
16
+ paymentLogoIcon?: PaymentLogoIcon;
11
17
  subtitle: string;
12
18
  title: string;
13
19
  } & ({
14
- transactionStatus: "success";
20
+ transactionStatus: "success" | "refunded";
21
+ badgeText?: string;
15
22
  transactionAmount: string;
16
23
  } | {
17
- transactionStatus: "failure" | "pending";
24
+ transactionStatus: "failure" | "pending" | "cancelled" | "reversal";
25
+ badgeText: string;
18
26
  transactionAmount?: string;
19
27
  })>;
20
- export declare const ListItemTransaction: ({ accessibilityLabel, hasChevronRight, isLoading, paymentLogoOrUrl, onPress, subtitle, testID, title, transactionAmount, transactionStatus }: ListItemTransaction) => React.JSX.Element;
28
+ export declare const ListItemTransaction: ({ accessibilityLabel, hasChevronRight, isLoading, paymentLogoIcon, onPress, subtitle, testID, title, transactionAmount, badgeText, transactionStatus }: ListItemTransaction) => React.JSX.Element;
21
29
  export {};
22
30
  //# sourceMappingURL=ListItemTransaction.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ListItemTransaction.d.ts","sourceRoot":"","sources":["../../../../src/components/listitems/ListItemTransaction.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAoB,MAAM,cAAc,CAAC;AAUhE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAI/C,OAAO,EAAE,iBAAiB,EAAe,MAAM,UAAU,CAAC;AAG1D,OAAO,EACL,kBAAkB,EAEnB,MAAM,0BAA0B,CAAC;AAElC,KAAK,aAAa,GAAG,iBAAiB,GAAG,cAAc,CAAC;AACxD,MAAM,MAAM,mBAAmB,GAAG,UAAU,CAC1C,kBAAkB,GAAG;IACnB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,gBAAgB,CAAC,EAAE,aAAa,CAAC;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;CACf,GAAG,CACE;IACE,iBAAiB,EAAE,SAAS,CAAC;IAC7B,iBAAiB,EAAE,MAAM,CAAC;CAC3B,GACD;IACE,iBAAiB,EAAE,SAAS,GAAG,SAAS,CAAC;IACzC,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,CACJ,CACJ,CAAC;AA8BF,eAAO,MAAM,mBAAmB,iJAW7B,mBAAmB,sBAgFrB,CAAC"}
1
+ {"version":3,"file":"ListItemTransaction.d.ts","sourceRoot":"","sources":["../../../../src/components/listitems/ListItemTransaction.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAoB,MAAM,cAAc,CAAC;AAehE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAK/C,OAAO,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAG7C,OAAO,EACL,kBAAkB,EAEnB,MAAM,0BAA0B,CAAC;AAElC,MAAM,MAAM,yBAAyB,GACjC,SAAS,GACT,SAAS,GACT,SAAS,GACT,WAAW,GACX,UAAU,GACV,UAAU,CAAC;AAEf,KAAK,eAAe,GAAG,iBAAiB,GAAG,cAAc,GAAG,KAAK,CAAC,SAAS,CAAC;AAE5E,MAAM,MAAM,mBAAmB,GAAG,UAAU,CAC1C,kBAAkB,GAAG;IACnB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;;OAIG;IACH,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;CACf,GAAG,CACE;IACE,iBAAiB,EAAE,SAAS,GAAG,UAAU,CAAC;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iBAAiB,EAAE,MAAM,CAAC;CAC3B,GACD;IACE,iBAAiB,EAAE,SAAS,GAAG,SAAS,GAAG,WAAW,GAAG,UAAU,CAAC;IACpE,SAAS,EAAE,MAAM,CAAC;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,CACJ,CACJ,CAAC;AA2BF,eAAO,MAAM,mBAAmB,2JAY7B,mBAAmB,sBA2GrB,CAAC"}
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ import { TextInputBase } from "./TextInputBase";
3
+ type TextInputProps = Omit<React.ComponentProps<typeof TextInputBase>, "rightElement" | "status" | "bottomMessageColor" | "isPassword" | "errorMessage">;
4
+ export declare const TextInput: (props: TextInputProps) => React.JSX.Element;
5
+ export {};
6
+ //# sourceMappingURL=TextInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../src/components/textInput/TextInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,KAAK,cAAc,GAAG,IAAI,CACxB,KAAK,CAAC,cAAc,CAAC,OAAO,aAAa,CAAC,EACxC,cAAc,GACd,QAAQ,GACR,oBAAoB,GACpB,YAAY,GACZ,cAAc,CACjB,CAAC;AAEF,eAAO,MAAM,SAAS,UAAW,cAAc,sBAE9C,CAAC"}
@@ -0,0 +1,28 @@
1
+ import { TextInput } from "react-native";
2
+ import React from "react";
3
+ import { IOColors } from "../../core";
4
+ import { IOIcons } from "../icons";
5
+ import { InputType } from "../../utils/types";
6
+ type InputStatus = "initial" | "focused" | "disabled" | "error";
7
+ type RNTextInputProps = Pick<React.ComponentProps<typeof TextInput>, "keyboardType" | "inputMode" | "textContentType" | "autoComplete">;
8
+ type InputTextProps = {
9
+ placeholder: string;
10
+ value: string;
11
+ onChangeText: (value: string) => void;
12
+ accessibilityLabel?: string;
13
+ textInputProps?: RNTextInputProps;
14
+ inputTyoe?: InputType;
15
+ status?: InputStatus;
16
+ icon?: IOIcons;
17
+ rightElement?: React.ReactNode;
18
+ counterLimit?: number;
19
+ bottomMessage?: string;
20
+ bottomMessageColor?: IOColors;
21
+ disabled?: boolean;
22
+ isPassword?: boolean;
23
+ onBlur?: () => void;
24
+ onFocus?: () => void;
25
+ };
26
+ export declare const TextInputBase: ({ disabled, placeholder, value, onChangeText, accessibilityLabel, textInputProps, inputTyoe, status, icon, rightElement, counterLimit, bottomMessage, bottomMessageColor, onBlur, onFocus, isPassword }: InputTextProps) => React.JSX.Element;
27
+ export {};
28
+ //# sourceMappingURL=TextInputBase.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextInputBase.d.ts","sourceRoot":"","sources":["../../../../src/components/textInput/TextInputBase.tsx"],"names":[],"mappings":"AACA,OAAO,EAGL,SAAS,EAGV,MAAM,cAAc,CAAC;AACtB,OAAO,KAAkD,MAAM,OAAO,CAAC;AAOvE,OAAO,EAAE,QAAQ,EAA4B,MAAM,YAAY,CAAC;AAChE,OAAO,EAAE,OAAO,EAAQ,MAAM,UAAU,CAAC;AAGzC,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAG9C,KAAK,WAAW,GAAG,SAAS,GAAG,SAAS,GAAG,UAAU,GAAG,OAAO,CAAC;AAEhE,KAAK,gBAAgB,GAAG,IAAI,CAC1B,KAAK,CAAC,cAAc,CAAC,OAAO,SAAS,CAAC,EACtC,cAAc,GAAG,WAAW,GAAG,iBAAiB,GAAG,cAAc,CAClE,CAAC;AAEF,KAAK,cAAc,GAAG;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,cAAc,CAAC,EAAE,gBAAgB,CAAC;IAClC,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,YAAY,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC/B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,kBAAkB,CAAC,EAAE,QAAQ,CAAC;IAC9B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB,CAAC;AAwFF,eAAO,MAAM,aAAa,4MAiBvB,cAAc,sBA+KhB,CAAC"}
@@ -0,0 +1,6 @@
1
+ import * as React from "react";
2
+ import { TextInputBase } from "./TextInputBase";
3
+ type TextInputPasswordProps = Omit<React.ComponentProps<typeof TextInputBase>, "isPassword">;
4
+ export declare const TextInputPassword: (props: TextInputPasswordProps) => React.JSX.Element;
5
+ export {};
6
+ //# sourceMappingURL=TextInputPassword.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextInputPassword.d.ts","sourceRoot":"","sources":["../../../../src/components/textInput/TextInputPassword.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,KAAK,sBAAsB,GAAG,IAAI,CAChC,KAAK,CAAC,cAAc,CAAC,OAAO,aAAa,CAAC,EAC1C,YAAY,CACb,CAAC;AAEF,eAAO,MAAM,iBAAiB,UAAW,sBAAsB,sBA0B9D,CAAC"}
@@ -0,0 +1,9 @@
1
+ import * as React from "react";
2
+ import { TextInputBase } from "./TextInputBase";
3
+ type TextInputValidationProps = Omit<React.ComponentProps<typeof TextInputBase>, "rightElement" | "status" | "bottomMessageColor" | "isPassword"> & {
4
+ onValidate: (value: string) => boolean;
5
+ errorMessage?: string;
6
+ };
7
+ export declare const TextInputValidation: (props: TextInputValidationProps) => React.JSX.Element;
8
+ export default TextInputValidation;
9
+ //# sourceMappingURL=TextInputValidation.d.ts.map