@sincpro/mobile-ui 2.0.1 → 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (198) hide show
  1. package/README.md +7 -2
  2. package/dist/Actions/Actions.Button.d.ts +2 -1
  3. package/dist/Actions/Actions.Button.js +31 -37
  4. package/dist/Actions/Actions.Dock.d.ts +6 -6
  5. package/dist/Actions/Actions.Dock.js +14 -72
  6. package/dist/Actions/Actions.FAB.d.ts +2 -1
  7. package/dist/Actions/Actions.FilterButton.js +1 -1
  8. package/dist/Actions/Actions.IconButton.d.ts +3 -4
  9. package/dist/Actions/Actions.IconButton.js +2 -2
  10. package/dist/Dialog/Confirmation.context.d.ts +5 -14
  11. package/dist/Dialog/Confirmation.context.js +11 -51
  12. package/dist/Dialog/Dialog.ActionSheet.d.ts +8 -7
  13. package/dist/Dialog/Dialog.ActionSheet.js +45 -19
  14. package/dist/Dialog/Dialog.Confirmation.d.ts +14 -11
  15. package/dist/Dialog/Dialog.Confirmation.js +38 -14
  16. package/dist/Dialog/Dialog.EditValue.d.ts +21 -16
  17. package/dist/Dialog/Dialog.EditValue.js +73 -14
  18. package/dist/Dialog/Dialog.Sheet.d.ts +8 -24
  19. package/dist/Dialog/Dialog.Sheet.js +15 -60
  20. package/dist/Dialog/index.d.ts +14 -14
  21. package/dist/Dialog/index.js +5 -3
  22. package/dist/Dialog/requestConfirmation.d.ts +3 -0
  23. package/dist/Dialog/requestConfirmation.js +13 -0
  24. package/dist/Display/Display.Accordion.js +1 -1
  25. package/dist/Display/Display.Avatar.d.ts +6 -6
  26. package/dist/Display/Display.Avatar.js +2 -2
  27. package/dist/Display/Display.Badge.js +4 -4
  28. package/dist/Display/Display.Card.js +5 -2
  29. package/dist/Display/Display.Carousel.js +1 -1
  30. package/dist/Display/Display.CircleButton.d.ts +3 -8
  31. package/dist/Display/Display.CircleButton.js +2 -2
  32. package/dist/Display/Display.CopyableText.js +1 -5
  33. package/dist/Display/Display.Date.d.ts +3 -2
  34. package/dist/Display/Display.Date.js +3 -3
  35. package/dist/Display/Display.GradientSurface.d.ts +52 -9
  36. package/dist/Display/Display.GradientSurface.js +9 -14
  37. package/dist/Display/Display.Icon.d.ts +7 -11
  38. package/dist/Display/Display.Icon.js +15 -30
  39. package/dist/Display/Display.Image.d.ts +2 -1
  40. package/dist/Display/Display.Image.js +1 -1
  41. package/dist/Display/Display.KeyValue.js +1 -1
  42. package/dist/Display/Display.ListItem.js +1 -1
  43. package/dist/Display/Display.MenuButton.js +4 -4
  44. package/dist/Display/Display.MenuCard.d.ts +3 -8
  45. package/dist/Display/Display.MenuCard.js +2 -2
  46. package/dist/Display/Display.MenuGrid.d.ts +2 -7
  47. package/dist/Display/Display.MenuGrid.js +1 -1
  48. package/dist/Display/Display.Monetary.d.ts +2 -6
  49. package/dist/Display/Display.Monetary.js +2 -2
  50. package/dist/Display/Display.PriceTag.js +1 -1
  51. package/dist/Display/Display.Rating.js +1 -1
  52. package/dist/Display/Display.SearchHistory.d.ts +2 -1
  53. package/dist/Display/Display.SearchHistory.js +1 -1
  54. package/dist/Display/Display.StatCard.d.ts +2 -1
  55. package/dist/Display/Display.StatCard.js +1 -1
  56. package/dist/Display/Display.StoryViewer.js +10 -6
  57. package/dist/Display/Display.SwipeableRow.d.ts +2 -1
  58. package/dist/Display/Display.Timeline.js +1 -1
  59. package/dist/Display/icon-map.d.ts +344 -0
  60. package/dist/Display/icon-map.js +86 -0
  61. package/dist/Display/index.d.ts +2 -0
  62. package/dist/Display/index.js +1 -0
  63. package/dist/Feedback/Feedback.Banner.js +13 -12
  64. package/dist/Feedback/Feedback.Empty.js +1 -1
  65. package/dist/Feedback/Feedback.EmptyState.d.ts +2 -1
  66. package/dist/Feedback/Feedback.EmptyState.js +1 -1
  67. package/dist/Feedback/Feedback.Error.js +1 -1
  68. package/dist/Feedback/Feedback.PermissionCard.d.ts +2 -1
  69. package/dist/Feedback/Feedback.PermissionCard.js +2 -2
  70. package/dist/Feedback/Toast.context.js +3 -3
  71. package/dist/Form/Form.ControlledDropdown.d.ts +5 -11
  72. package/dist/Form/Form.ControlledDropdown.js +5 -2
  73. package/dist/Form/Form.DatePicker.d.ts +5 -9
  74. package/dist/Form/Form.DatePicker.js +116 -21
  75. package/dist/Form/Form.Dropdown.d.ts +11 -16
  76. package/dist/Form/Form.Dropdown.js +54 -90
  77. package/dist/Form/Form.FractionalQuantityInput.js +4 -11
  78. package/dist/Form/Form.Input.d.ts +3 -3
  79. package/dist/Form/Form.KeyboardForm.d.ts +2 -2
  80. package/dist/Form/Form.KeyboardForm.js +2 -2
  81. package/dist/Form/Form.KeyboardToolbar.d.ts +2 -1
  82. package/dist/Form/Form.KeyboardToolbar.js +3 -7
  83. package/dist/Form/Form.PasswordInput.js +1 -1
  84. package/dist/Form/Form.QuantitySelector.js +1 -1
  85. package/dist/Form/Form.Select.d.ts +12 -8
  86. package/dist/Form/Form.Select.js +64 -31
  87. package/dist/Form/Form.Slider.d.ts +4 -7
  88. package/dist/Form/Form.Slider.js +11 -10
  89. package/dist/Form/Form.Switch.js +2 -1
  90. package/dist/Form/index.d.ts +6 -14
  91. package/dist/Form/index.js +0 -11
  92. package/dist/Navigation/Navigation.AppBar.d.ts +2 -1
  93. package/dist/Navigation/Navigation.AppBar.js +2 -2
  94. package/dist/Navigation/Navigation.BottomNav.d.ts +4 -8
  95. package/dist/Navigation/Navigation.BottomNav.js +2 -2
  96. package/dist/Navigation/Navigation.CollapsingHeader.js +3 -2
  97. package/dist/Navigation/Navigation.Menu.d.ts +16 -11
  98. package/dist/Navigation/Navigation.Menu.js +97 -42
  99. package/dist/Navigation/Navigation.Search.js +2 -2
  100. package/dist/Navigation/Navigation.SearchBar.js +3 -4
  101. package/dist/Navigation/Navigation.SegmentedControl.d.ts +7 -25
  102. package/dist/Navigation/Navigation.SegmentedControl.js +18 -39
  103. package/dist/Navigation/Navigation.Steps.js +1 -1
  104. package/dist/Navigation/Navigation.Tabs.d.ts +2 -1
  105. package/dist/Navigation/index.d.ts +0 -6
  106. package/dist/Navigation/index.js +0 -8
  107. package/dist/Typography/Typography.SelectableText.js +3 -7
  108. package/dist/Typography/Typography.Text.d.ts +1 -6
  109. package/dist/Typography/Typography.Text.js +3 -6
  110. package/dist/index.d.ts +1 -4
  111. package/dist/index.js +1 -4
  112. package/dist/layouts/AuthContainer.d.ts +4 -2
  113. package/dist/layouts/AuthContainer.js +3 -4
  114. package/dist/layouts/Container.d.ts +0 -4
  115. package/dist/layouts/Container.js +3 -4
  116. package/dist/layouts/ScrollContainer.d.ts +7 -3
  117. package/dist/layouts/ScrollContainer.js +5 -4
  118. package/dist/primitives/BaseButton.d.ts +2 -1
  119. package/dist/theme/build.js +0 -4
  120. package/dist/theme/css-vars.js +0 -4
  121. package/dist/theme/dark.js +2 -6
  122. package/dist/theme/default.js +1 -5
  123. package/dist/theme/index.d.ts +1 -1
  124. package/dist/theme/index.js +1 -1
  125. package/dist/theme/types.d.ts +0 -11
  126. package/dist/theme/typography.d.ts +8 -7
  127. package/dist/theme/typography.js +25 -4
  128. package/dist/utils/timezone.d.ts +0 -5
  129. package/dist/views/AuthFormView.d.ts +3 -1
  130. package/dist/views/AuthFormView.js +2 -2
  131. package/dist/views/FormViewV2.d.ts +6 -13
  132. package/dist/views/FormViewV2.js +29 -25
  133. package/dist/views/ListViewV2.context.d.ts +5 -5
  134. package/dist/views/ListViewV2.d.ts +23 -18
  135. package/dist/views/ListViewV2.js +45 -48
  136. package/dist/views/types/IListView.d.ts +5 -4
  137. package/dist/views/types/IListView.js +18 -15
  138. package/dist/widgets/CollectionOptions.d.ts +2 -2
  139. package/dist/widgets/CollectionOptions.js +92 -65
  140. package/dist/widgets/FilterBar.js +1 -1
  141. package/dist/widgets/PromoModal.js +10 -4
  142. package/dist/widgets/QuickActions.d.ts +2 -7
  143. package/dist/widgets/QuickActions.js +1 -1
  144. package/dist/widgets/ReorderableList.js +3 -3
  145. package/dist/widgets/TimeZoneSelectorModal.d.ts +1 -6
  146. package/dist/widgets/TimeZoneSelectorModal.js +17 -12
  147. package/dist/widgets/index.d.ts +0 -11
  148. package/dist/widgets/index.js +0 -7
  149. package/package.json +35 -38
  150. package/tailwind.preset.js +0 -4
  151. package/dist/Dialog/BottomSheet/BottomSheet.Root.d.ts +0 -324
  152. package/dist/Dialog/BottomSheet/BottomSheet.Root.js +0 -373
  153. package/dist/Dialog/BottomSheet/index.d.ts +0 -1
  154. package/dist/Dialog/BottomSheet/index.js +0 -1
  155. package/dist/Dialog/Dialog.NativeSheet.d.ts +0 -10
  156. package/dist/Dialog/Dialog.NativeSheet.js +0 -21
  157. package/dist/Form/Form.Button.d.ts +0 -3
  158. package/dist/Form/Form.Button.js +0 -1
  159. package/dist/Form/Form.FAB.d.ts +0 -3
  160. package/dist/Form/Form.FAB.js +0 -1
  161. package/dist/Form/Form.FilterButton.d.ts +0 -3
  162. package/dist/Form/Form.FilterButton.js +0 -1
  163. package/dist/Form/Form.IconButton.d.ts +0 -3
  164. package/dist/Form/Form.IconButton.js +0 -1
  165. package/dist/Form/Form.SearchBar.d.ts +0 -13
  166. package/dist/Form/Form.SearchBar.js +0 -26
  167. package/dist/Navigation/Navigation.Header.d.ts +0 -16
  168. package/dist/Navigation/Navigation.Header.js +0 -17
  169. package/dist/Navigation/Navigation.HeaderToolbar.d.ts +0 -15
  170. package/dist/Navigation/Navigation.HeaderToolbar.js +0 -18
  171. package/dist/Navigation/Navigation.TabIcon.d.ts +0 -18
  172. package/dist/Navigation/Navigation.TabIcon.js +0 -12
  173. package/dist/Navigation/Navigation.TabItem.d.ts +0 -19
  174. package/dist/Navigation/Navigation.TabItem.js +0 -13
  175. package/dist/icons/OdooIcon.d.ts +0 -11
  176. package/dist/icons/OdooIcon.js +0 -11
  177. package/dist/icons/PrinterIcon.d.ts +0 -9
  178. package/dist/icons/PrinterIcon.js +0 -9
  179. package/dist/layouts/TabNavigatorLayout.d.ts +0 -26
  180. package/dist/layouts/TabNavigatorLayout.js +0 -60
  181. package/dist/utils/icon.d.ts +0 -1
  182. package/dist/utils/icon.js +0 -1
  183. package/dist/widgets/CircleButton.d.ts +0 -3
  184. package/dist/widgets/CircleButton.js +0 -1
  185. package/dist/widgets/GeoPermissionCard.d.ts +0 -13
  186. package/dist/widgets/GeoPermissionCard.js +0 -24
  187. package/dist/widgets/HomeHeader.d.ts +0 -15
  188. package/dist/widgets/HomeHeader.js +0 -13
  189. package/dist/widgets/MenuCard.d.ts +0 -3
  190. package/dist/widgets/MenuCard.js +0 -1
  191. package/dist/widgets/MenuGrid.d.ts +0 -5
  192. package/dist/widgets/MenuGrid.js +0 -1
  193. package/dist/widgets/MenuSection.d.ts +0 -3
  194. package/dist/widgets/MenuSection.js +0 -1
  195. package/dist/widgets/ScreenHeader.d.ts +0 -25
  196. package/dist/widgets/ScreenHeader.js +0 -32
  197. package/dist/widgets/TimeZoneSelector.d.ts +0 -12
  198. package/dist/widgets/TimeZoneSelector.js +0 -24
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sincpro/mobile-ui",
3
- "version": "2.0.1",
3
+ "version": "3.0.1",
4
4
  "description": "Sincpro Mobile design system: generic, presentational React Native components (no domain logic)",
5
5
  "main": "expo/AppEntry.js",
6
6
  "types": "./dist/index.d.ts",
@@ -18,9 +18,7 @@
18
18
  "./branding": "./dist/branding.js",
19
19
  "./theme": "./dist/theme/index.js",
20
20
  "./Dialog": "./dist/Dialog/index.js",
21
- "./Dialog/BottomSheet": "./dist/Dialog/BottomSheet/index.js",
22
21
  "./Dialog/Sheet": "./dist/Dialog/Dialog.Sheet.js",
23
- "./Dialog/NativeSheet": "./dist/Dialog/Dialog.NativeSheet.js",
24
22
  "./Actions": "./dist/Actions/index.js",
25
23
  "./Display": "./dist/Display/index.js",
26
24
  "./Display/ExpoImage": "./dist/Display/Display.ExpoImage.js",
@@ -56,39 +54,36 @@
56
54
  "node": ">=26"
57
55
  },
58
56
  "peerDependencies": {
59
- "@expo-google-fonts/ibm-plex-mono": ">=0.4",
60
- "@expo-google-fonts/ibm-plex-sans": ">=0.4",
61
- "@expo/ui": "*",
62
- "@expo/vector-icons": ">=15.0.2",
63
- "@react-native-community/datetimepicker": ">=9.2",
64
- "@react-native-community/slider": ">=5.2",
65
- "expo-checkbox": ">=58.0.0",
66
- "expo-clipboard": ">=58.0.0",
67
- "expo-linear-gradient": ">=58.0.0",
68
- "expo-image": ">=58.0.0",
69
- "expo-localization": ">=58.0.0",
70
- "nativewind": ">=4.2.7",
71
- "react": ">=19.3",
72
- "react-hook-form": ">=7",
73
- "react-native": ">=0.88",
74
- "react-native-currency-input": ">=1.1",
75
- "react-native-gesture-handler": ">=3.3",
76
- "react-native-keyboard-controller": ">=1.22",
77
- "react-native-reanimated": ">=4.7",
78
- "react-native-safe-area-context": ">=5.11",
57
+ "@expo-google-fonts/ibm-plex-mono": ">=0.4.1 <1",
58
+ "@expo-google-fonts/ibm-plex-sans": ">=0.4.1 <1",
59
+ "@expo/ui": ">=58.0.27 <59",
60
+ "@shopify/flash-list": ">=2.3.2 <3",
61
+ "expo-checkbox": ">=58.0.2 <59",
62
+ "expo-clipboard": ">=58.0.4 <59",
63
+ "expo-image": ">=58.0.18 <59",
64
+ "expo-linear-gradient": ">=58.0.3 <59",
65
+ "expo-localization": ">=58.0.5 <59",
66
+ "expo-symbols": ">=58.0.4 <59",
67
+ "nativewind": "^4.2.7",
68
+ "react": ">=19.3.0 <20",
69
+ "react-hook-form": ">=7.62.0 <8",
70
+ "react-native": ">=0.88.1 <0.89",
71
+ "react-native-currency-input": ">=1.1.1 <2",
72
+ "react-native-gesture-handler": ">=3.3.0 <4",
73
+ "react-native-keyboard-controller": ">=1.22.7 <2",
74
+ "react-native-reanimated": ">=4.7.1 <5",
75
+ "react-native-safe-area-context": ">=5.11.1 <6",
79
76
  "react-native-sortables": ">=1.10.1 <2",
80
- "react-native-svg": ">=15.16",
81
- "react-native-worklets": ">=0.13"
77
+ "react-native-svg": ">=15.16.0 <16",
78
+ "react-native-worklets": ">=0.13.0 <0.14"
82
79
  },
83
80
  "peerDependenciesMeta": {
84
- "@expo/ui": {
85
- "optional": true
86
- },
87
81
  "react-native-sortables": {
88
82
  "optional": true
89
83
  }
90
84
  },
91
85
  "dependencies": {
86
+ "@babel/runtime": "^7.29.13",
92
87
  "big.js": "^7.0.1",
93
88
  "clsx": "^2.1.1",
94
89
  "dayjs": "^1.11.21",
@@ -96,23 +91,18 @@
96
91
  "tailwind-variants": "^3.2.2"
97
92
  },
98
93
  "devDependencies": {
99
- "@jest/globals": "^30.0.0",
100
- "@testing-library/react-native": "14.1.0",
101
- "@react-native/jest-preset": "^0.88.1",
102
- "jest": "^30.0.0",
103
- "jest-expo": "~58.0.14",
104
- "test-renderer": "^1.0.0",
94
+ "@babel/core": "^7.29.13",
105
95
  "@expo-google-fonts/ibm-plex-mono": "^0.4.1",
106
96
  "@expo-google-fonts/ibm-plex-sans": "^0.4.1",
107
97
  "@expo/ui": "~58.0.27",
108
- "@expo/vector-icons": "^15.0.3",
109
98
  "@gorhom/bottom-sheet": "^5",
99
+ "@jest/globals": "^30.0.0",
110
100
  "@react-native-async-storage/async-storage": "2.2.0",
111
- "@react-native-community/datetimepicker": "9.2.1",
112
- "@react-native-community/slider": "5.2.1",
101
+ "@react-native/jest-preset": "^0.88.1",
102
+ "@shopify/flash-list": "2.3.2",
113
103
  "@storybook/addon-ondevice-actions": "10.7.1",
114
- "@storybook/addon-ondevice-controls": "10.7.1",
115
104
  "@storybook/react-native": "10.7.1",
105
+ "@testing-library/react-native": "14.1.0",
116
106
  "@types/big.js": "^6.2.2",
117
107
  "@types/node": "^26.6.6",
118
108
  "@types/react": "~19.3.0",
@@ -122,6 +112,7 @@
122
112
  "eslint-config-prettier": "^10.1.8",
123
113
  "eslint-plugin-prettier": "^5.5.4",
124
114
  "eslint-plugin-react": "^7.37.2",
115
+ "eslint-plugin-react-hooks": "^7.1.1",
125
116
  "eslint-plugin-simple-import-sort": "^12.1.1",
126
117
  "expo": "~58.0.23",
127
118
  "expo-checkbox": "~58.0.2",
@@ -131,6 +122,10 @@
131
122
  "expo-linear-gradient": "~58.0.3",
132
123
  "expo-localization": "~58.0.5",
133
124
  "expo-status-bar": "~58.0.4",
125
+ "expo-symbols": "~58.0.4",
126
+ "expo-system-ui": "~58.0.7",
127
+ "jest": "^30.0.0",
128
+ "jest-expo": "~58.0.14",
134
129
  "nativewind": "4.2.7",
135
130
  "patch-package": "^8.0.1",
136
131
  "prettier": "^3.9.8",
@@ -147,11 +142,13 @@
147
142
  "react-native-worklets": "0.13.0",
148
143
  "storybook": "10.6.6",
149
144
  "tailwindcss": "3.4.19",
145
+ "test-renderer": "^1.0.0",
150
146
  "tsc-alias": "^1.8.17",
151
147
  "tsx": "^4",
152
148
  "typescript": "~6.0.3"
153
149
  },
154
150
  "scripts": {
151
+ "postinstall": "if command -v patch-package >/dev/null; then patch-package; fi",
155
152
  "start": "expo start",
156
153
  "android": "expo run:android",
157
154
  "ios": "expo run:ios"
@@ -69,10 +69,6 @@ module.exports = {
69
69
  warning: "rgb(var(--warning) / <alpha-value>)",
70
70
  danger: "rgb(var(--danger) / <alpha-value>)",
71
71
  info: "rgb(var(--info) / <alpha-value>)",
72
- "success-light": "rgb(var(--success-light) / <alpha-value>)",
73
- "warning-light": "rgb(var(--warning-light) / <alpha-value>)",
74
- "danger-light": "rgb(var(--danger-light) / <alpha-value>)",
75
- "info-light": "rgb(var(--info-light) / <alpha-value>)",
76
72
  container: {
77
73
  primary: "rgb(var(--container-primary) / <alpha-value>)",
78
74
  "on-primary": "rgb(var(--container-on-primary) / <alpha-value>)",
@@ -1,324 +0,0 @@
1
- import { type ReactNode } from "react";
2
- import { type GestureResponderHandlers } from "react-native";
3
- /**
4
- * Available sizes for the BottomSheet.
5
- * - `auto`: Fits content height (max 90% screen)
6
- * - `small`: 30% of screen height
7
- * - `medium`: 50% of screen height
8
- * - `large`: 75% of screen height
9
- * - `full`: 90% of screen height
10
- */
11
- type BottomSheetSize = "auto" | "small" | "medium" | "large" | "full";
12
- export interface BottomSheetContextValue {
13
- close: () => void;
14
- panHandlers: GestureResponderHandlers;
15
- }
16
- /**
17
- * Hook to access BottomSheet context from compound components.
18
- * Provides `close()` function and `panHandlers` for gesture support.
19
- *
20
- * @throws Error if used outside BottomSheet.Root
21
- *
22
- * @example
23
- * ```tsx
24
- * function CustomHeader() {
25
- * const { close, panHandlers } = BottomSheet.useBottomSheet();
26
- * return (
27
- * <View {...panHandlers}>
28
- * <Button onPress={close} title="Close" />
29
- * </View>
30
- * );
31
- * }
32
- * ```
33
- */
34
- declare function useBottomSheet(): BottomSheetContextValue;
35
- export interface RootProps {
36
- visible: boolean;
37
- onClose: () => void;
38
- size?: BottomSheetSize;
39
- dismissible?: boolean;
40
- children: ReactNode;
41
- }
42
- /**
43
- * Root container for the BottomSheet modal with swipe-to-dismiss gesture support.
44
- *
45
- * Features:
46
- * - Spring animation on open/close
47
- * - Swipe down to dismiss (configurable)
48
- * - Backdrop tap to dismiss (configurable)
49
- * - Safe area insets handling
50
- * - Configurable sizes
51
- *
52
- * @param visible - Controls visibility of the bottom sheet
53
- * @param onClose - Callback when sheet is dismissed (swipe, backdrop tap, or programmatic)
54
- * @param size - Height preset: 'auto' | 'small' | 'medium' | 'large' | 'full'
55
- * @param dismissible - If false, disables swipe and backdrop dismiss (default: true)
56
- * @param children - Compound components (Header, Content, Actions, etc.)
57
- *
58
- * @example Basic usage with Header and Content
59
- * ```tsx
60
- * <BottomSheet.Root visible={isOpen} onClose={() => setIsOpen(false)}>
61
- * <BottomSheet.Header>
62
- * <BottomSheet.Title>Select Option</BottomSheet.Title>
63
- * </BottomSheet.Header>
64
- * <BottomSheet.Content>
65
- * <Text>Your content here</Text>
66
- * </BottomSheet.Content>
67
- * </BottomSheet.Root>
68
- * ```
69
- *
70
- * @example With Actions footer
71
- * ```tsx
72
- * <BottomSheet.Root visible={isOpen} onClose={close} size="medium">
73
- * <BottomSheet.Header>
74
- * <BottomSheet.Title subtitle="Choose one">Options</BottomSheet.Title>
75
- * </BottomSheet.Header>
76
- * <BottomSheet.Content scrollable>
77
- * {items.map(item => <ItemRow key={item.id} item={item} />)}
78
- * </BottomSheet.Content>
79
- * <BottomSheet.Actions layout="horizontal">
80
- * <Button title="Cancel" onPress={close} />
81
- * <Button title="Confirm" onPress={handleConfirm} />
82
- * </BottomSheet.Actions>
83
- * </BottomSheet.Root>
84
- * ```
85
- *
86
- * @example Non-dismissible (must use button to close)
87
- * ```tsx
88
- * <BottomSheet.Root visible={isOpen} onClose={close} dismissible={false}>
89
- * <BottomSheet.Content>
90
- * <Text>You must tap the button to close</Text>
91
- * <Button title="Close" onPress={close} />
92
- * </BottomSheet.Content>
93
- * </BottomSheet.Root>
94
- * ```
95
- */
96
- /**
97
- * @deprecated Custom PanResponder implementation (limited gestures/scroll). The modern
98
- * replacement is `Dialog.Sheet` (on RN Modal, no provider). Kept for backwards compatibility.
99
- */
100
- declare function Root({ visible, onClose, size, dismissible, children }: RootProps): import("react").JSX.Element;
101
- export interface HandleProps {
102
- children?: ReactNode;
103
- }
104
- /**
105
- * Standalone drag handle for minimal bottom sheets without a header.
106
- * Includes the visual "pill" indicator and swipe gesture support.
107
- *
108
- * Use this when you want a simple drag indicator without a full header.
109
- * For sheets with titles, use `BottomSheet.Header` instead.
110
- *
111
- * @param children - Optional content below the handle pill
112
- *
113
- * @example Minimal sheet with just a handle
114
- * ```tsx
115
- * <BottomSheet.Root visible={isOpen} onClose={close}>
116
- * <BottomSheet.Handle />
117
- * <BottomSheet.Content>
118
- * <Text>Simple content</Text>
119
- * </BottomSheet.Content>
120
- * </BottomSheet.Root>
121
- * ```
122
- */
123
- declare function Handle({ children }: HandleProps): import("react").JSX.Element;
124
- export interface HeaderProps {
125
- children: ReactNode;
126
- }
127
- /**
128
- * Header section with integrated drag handle and bottom border.
129
- * Automatically includes the drag pill indicator and gesture support.
130
- *
131
- * Use with `BottomSheet.Title` for consistent styling, or provide custom content.
132
- *
133
- * @param children - Header content (typically BottomSheet.Title or custom layout)
134
- *
135
- * @example With Title component
136
- * ```tsx
137
- * <BottomSheet.Header>
138
- * <BottomSheet.Title subtitle="Select your preference">
139
- * Settings
140
- * </BottomSheet.Title>
141
- * </BottomSheet.Header>
142
- * ```
143
- *
144
- * @example Custom header content
145
- * ```tsx
146
- * <BottomSheet.Header>
147
- * <View className="flex-row justify-between px-4 py-2">
148
- * <Text>Custom Title</Text>
149
- * <TouchableOpacity onPress={close}>
150
- * <Icon name="close" />
151
- * </TouchableOpacity>
152
- * </View>
153
- * </BottomSheet.Header>
154
- * ```
155
- */
156
- declare function Header({ children }: HeaderProps): import("react").JSX.Element;
157
- export interface TitleProps {
158
- children: ReactNode;
159
- subtitle?: string;
160
- }
161
- /**
162
- * Title component for use inside BottomSheet.Header.
163
- * Provides consistent text styling with optional subtitle.
164
- *
165
- * @param children - Main title text (typically a string or Text component)
166
- * @param subtitle - Optional secondary text below the title
167
- *
168
- * @example Simple title
169
- * ```tsx
170
- * <BottomSheet.Title>Select Device</BottomSheet.Title>
171
- * ```
172
- *
173
- * @example Title with subtitle
174
- * ```tsx
175
- * <BottomSheet.Title subtitle="Choose from available devices">
176
- * Bluetooth Printer
177
- * </BottomSheet.Title>
178
- * ```
179
- */
180
- declare function Title({ children, subtitle }: TitleProps): import("react").JSX.Element;
181
- export interface ContentProps {
182
- children: ReactNode;
183
- scrollable?: boolean;
184
- }
185
- /**
186
- * Main content area for the bottom sheet.
187
- * Can be static or scrollable depending on content needs.
188
- *
189
- * @param children - Content to display
190
- * @param scrollable - Enable ScrollView wrapper for long content (default: false)
191
- *
192
- * @example Static content
193
- * ```tsx
194
- * <BottomSheet.Content>
195
- * <View className="p-4">
196
- * <Text>Short content that fits</Text>
197
- * </View>
198
- * </BottomSheet.Content>
199
- * ```
200
- *
201
- * @example Scrollable list
202
- * ```tsx
203
- * <BottomSheet.Content scrollable>
204
- * {items.map(item => (
205
- * <TouchableOpacity key={item.id} onPress={() => onSelect(item)}>
206
- * <Text>{item.name}</Text>
207
- * </TouchableOpacity>
208
- * ))}
209
- * </BottomSheet.Content>
210
- * ```
211
- */
212
- declare function Content({ children, scrollable }: ContentProps): import("react").JSX.Element;
213
- export interface ActionsProps {
214
- children: ReactNode;
215
- layout?: "auto" | "horizontal" | "vertical";
216
- }
217
- /**
218
- * Action buttons section with top border, typically at the bottom of the sheet.
219
- * Use for confirm/cancel buttons or multiple action options.
220
- *
221
- * @param children - Button components
222
- * @param layout - Button arrangement: 'auto' | 'horizontal' | 'vertical' (default: 'auto')
223
- *
224
- * @example Vertical buttons (default)
225
- * ```tsx
226
- * <BottomSheet.Actions>
227
- * <Button title="Option 1" onPress={handleOption1} />
228
- * <Button title="Option 2" onPress={handleOption2} />
229
- * <Button title="Cancel" variant="outline" onPress={close} />
230
- * </BottomSheet.Actions>
231
- * ```
232
- *
233
- * @example Horizontal buttons (confirm/cancel pattern)
234
- * ```tsx
235
- * <BottomSheet.Actions layout="horizontal">
236
- * <Button title="Cancel" variant="outline" onPress={close} flex={1} />
237
- * <Button title="Confirm" variant="primary" onPress={confirm} flex={1} />
238
- * </BottomSheet.Actions>
239
- * ```
240
- */
241
- declare function Actions({ children, layout }: ActionsProps): import("react").JSX.Element;
242
- export interface FooterProps {
243
- children: ReactNode;
244
- }
245
- /**
246
- * Footer section with gray background, for secondary information or status.
247
- * Different from Actions - use Footer for non-interactive content.
248
- *
249
- * @param children - Footer content (text, status indicators, etc.)
250
- *
251
- * @example Status footer
252
- * ```tsx
253
- * <BottomSheet.Footer>
254
- * <Text className="text-text-secondary text-sm">
255
- * Last updated: 5 minutes ago
256
- * </Text>
257
- * </BottomSheet.Footer>
258
- * ```
259
- *
260
- * @example Help text footer
261
- * ```tsx
262
- * <BottomSheet.Footer>
263
- * <View className="flex-row items-center">
264
- * <Icon name="info" size={16} />
265
- * <Text className="ml-2 text-text-secondary">Swipe down to dismiss</Text>
266
- * </View>
267
- * </BottomSheet.Footer>
268
- * ```
269
- */
270
- declare function Footer({ children }: FooterProps): import("react").JSX.Element;
271
- /**
272
- * BottomSheet Compound Components
273
- *
274
- * A flexible, gesture-enabled bottom sheet modal system following compound component pattern.
275
- * Supports swipe-to-dismiss, configurable sizes, and composable sections.
276
- *
277
- * ## Components
278
- *
279
- * | Component | Purpose |
280
- * |-----------|---------|
281
- * | `Root` | Container with gesture handling and animations |
282
- * | `Handle` | Standalone drag pill (minimal sheets) |
283
- * | `Header` | Header with integrated drag handle |
284
- * | `Title` | Styled title with optional subtitle |
285
- * | `Content` | Main content area (static or scrollable) |
286
- * | `Actions` | Action buttons section |
287
- * | `Footer` | Secondary info footer |
288
- * | `useBottomSheet` | Hook for custom components |
289
- *
290
- * ## Basic Structure
291
- *
292
- * ```tsx
293
- * <BottomSheet.Root visible={isOpen} onClose={close}>
294
- * <BottomSheet.Header>
295
- * <BottomSheet.Title>Title</BottomSheet.Title>
296
- * </BottomSheet.Header>
297
- * <BottomSheet.Content>
298
- * {content}
299
- * </BottomSheet.Content>
300
- * <BottomSheet.Actions>
301
- * {buttons}
302
- * </BottomSheet.Actions>
303
- * </BottomSheet.Root>
304
- * ```
305
- *
306
- * ## Usage in Atomic Design
307
- *
308
- * - **Molecules**: Use BottomSheet to create selector modals (e.g., BluetoothDeviceSelectorModal)
309
- * - **Organisms**: Compose Card + SelectorModal for complete features (e.g., BluetoothPrinterSelector)
310
- *
311
- * @see BluetoothDeviceSelectorModal - Example molecule implementation
312
- * @see TimeZoneSelectorModal - Example molecule implementation
313
- */
314
- export declare const BottomSheet: {
315
- Root: typeof Root;
316
- Handle: typeof Handle;
317
- Header: typeof Header;
318
- Title: typeof Title;
319
- Content: typeof Content;
320
- Actions: typeof Actions;
321
- Footer: typeof Footer;
322
- useBottomSheet: typeof useBottomSheet;
323
- };
324
- export {};