@brissoto/pay-react-native 1.6.0 → 1.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -90,8 +90,9 @@ export function SheetForm({ core, phoneRef, cardFields, store, }) {
90
90
  on && [styles.tabOn, { backgroundColor: colors.tabOn }],
91
91
  ], children: _jsx(SheetText, { weight: FigtreeEnum.SEMI_BOLD, size: 13.5, color: on ? colors.ink : colors.muted, numberOfLines: 1, adjustsFontSizeToFit: true, minimumFontScale: 0.8, children: label }) }));
92
92
  };
93
- // Only Mobile Money methods have a country; with one, there is nothing to pick.
94
- const pickCountry = !onCard && !onStore && derived.countries.length > 1;
93
+ // Only Mobile Money methods have a country. Shown from one, as on the web:
94
+ // the payer sees where they pay from, whatever their own country.
95
+ const pickCountry = !onCard && !onStore && derived.countries.length > 0;
95
96
  return (_jsxs(View, { style: styles.form, children: [_jsxs(View, { style: styles.payWith, children: [_jsx(SheetText, { weight: FigtreeEnum.BOLD, size: 15, children: t('pay_with') }), pickCountry && (_jsx(SheetPillSelect, { value: ui.country, options: derived.countries.map((country) => ({
96
97
  value: country,
97
98
  label: t(`countries.${country}`),
@@ -42,7 +42,9 @@ export function SheetLayout({ children, foot, secure = true, }) {
42
42
  ];
43
43
  return () => listeners.forEach((listener) => listener.remove());
44
44
  }, []);
45
- return (_jsxs(_Fragment, { children: [_jsx(ScrollView, { ref: scroller, style: styles.body, contentContainerStyle: styles.content, keyboardShouldPersistTaps: "handled", keyboardDismissMode: "interactive", scrollEnabled: !pinned, onLayout: ({ nativeEvent }) => setHeight(nativeEvent.layout.height), onContentSizeChange: (_width, tall) => setContent(tall), testID: "sheet-body", children: _jsx(SheetRoomContext, { value: sheetRoom, children: children }) }), (foot || secure) && (_jsxs(View, { testID: "sheet-foot", style: [
45
+ return (_jsxs(_Fragment, { children: [_jsx(ScrollView, { ref: scroller, style: styles.body, contentContainerStyle: styles.content, keyboardShouldPersistTaps: "handled", keyboardDismissMode: "interactive", scrollEnabled: !pinned,
46
+ // iOS: the content stops at its ends; the sheet itself does not stretch.
47
+ bounces: false, onLayout: ({ nativeEvent }) => setHeight(nativeEvent.layout.height), onContentSizeChange: (_width, tall) => setContent(tall), testID: "sheet-body", children: _jsx(SheetRoomContext, { value: sheetRoom, children: children }) }), (foot || secure) && (_jsxs(View, { testID: "sheet-foot", style: [
46
48
  styles.foot,
47
49
  keyboard && styles.footOnKeyboard,
48
50
  { borderColor: colors.line },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brissoto/pay-react-native",
3
- "version": "1.6.0",
3
+ "version": "1.6.1",
4
4
  "description": "Brissoto Pay for Expo and React Native apps: the payment sheet.",
5
5
  "license": "MIT",
6
6
  "sideEffects": false,