@oxyhq/bloom 0.14.0 → 0.16.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 (212) hide show
  1. package/lib/commonjs/alert-dialog/AlertDialog.js +35 -27
  2. package/lib/commonjs/alert-dialog/AlertDialog.js.map +1 -1
  3. package/lib/commonjs/alert-dialog/index.js +1 -1
  4. package/lib/commonjs/alert-dialog/index.js.map +1 -1
  5. package/lib/commonjs/alert-dialog/index.web.js +1 -1
  6. package/lib/commonjs/alert-dialog/index.web.js.map +1 -1
  7. package/lib/commonjs/command/Command.js +27 -16
  8. package/lib/commonjs/command/Command.js.map +1 -1
  9. package/lib/commonjs/command/index.js +1 -1
  10. package/lib/commonjs/command/index.js.map +1 -1
  11. package/lib/commonjs/command/index.web.js +1 -1
  12. package/lib/commonjs/command/index.web.js.map +1 -1
  13. package/lib/commonjs/dialog/Dialog.js +336 -43
  14. package/lib/commonjs/dialog/Dialog.js.map +1 -1
  15. package/lib/commonjs/dialog/Dialog.web.js +420 -66
  16. package/lib/commonjs/dialog/Dialog.web.js.map +1 -1
  17. package/lib/commonjs/dialog/index.js +2 -9
  18. package/lib/commonjs/dialog/index.js.map +1 -1
  19. package/lib/commonjs/dialog/index.web.js +2 -15
  20. package/lib/commonjs/dialog/index.web.js.map +1 -1
  21. package/lib/commonjs/dialog/placement.js +104 -0
  22. package/lib/commonjs/dialog/placement.js.map +1 -0
  23. package/lib/commonjs/index.js +7 -29
  24. package/lib/commonjs/index.js.map +1 -1
  25. package/lib/commonjs/index.web.js +13 -35
  26. package/lib/commonjs/index.web.js.map +1 -1
  27. package/lib/module/alert-dialog/AlertDialog.js +35 -27
  28. package/lib/module/alert-dialog/AlertDialog.js.map +1 -1
  29. package/lib/module/alert-dialog/index.js +2 -2
  30. package/lib/module/alert-dialog/index.js.map +1 -1
  31. package/lib/module/alert-dialog/index.web.js +2 -2
  32. package/lib/module/alert-dialog/index.web.js.map +1 -1
  33. package/lib/module/command/Command.js +27 -16
  34. package/lib/module/command/Command.js.map +1 -1
  35. package/lib/module/command/index.js +2 -2
  36. package/lib/module/command/index.js.map +1 -1
  37. package/lib/module/command/index.web.js +2 -2
  38. package/lib/module/command/index.web.js.map +1 -1
  39. package/lib/module/dialog/Dialog.js +335 -46
  40. package/lib/module/dialog/Dialog.js.map +1 -1
  41. package/lib/module/dialog/Dialog.web.js +418 -68
  42. package/lib/module/dialog/Dialog.web.js.map +1 -1
  43. package/lib/module/dialog/index.js +1 -2
  44. package/lib/module/dialog/index.js.map +1 -1
  45. package/lib/module/dialog/index.web.js +1 -2
  46. package/lib/module/dialog/index.web.js.map +1 -1
  47. package/lib/module/dialog/placement.js +100 -0
  48. package/lib/module/dialog/placement.js.map +1 -0
  49. package/lib/module/index.js +1 -3
  50. package/lib/module/index.js.map +1 -1
  51. package/lib/module/index.web.js +1 -3
  52. package/lib/module/index.web.js.map +1 -1
  53. package/lib/typescript/commonjs/alert-dialog/AlertDialog.d.ts +13 -12
  54. package/lib/typescript/commonjs/alert-dialog/AlertDialog.d.ts.map +1 -1
  55. package/lib/typescript/commonjs/alert-dialog/index.d.ts.map +1 -1
  56. package/lib/typescript/commonjs/alert-dialog/index.web.d.ts.map +1 -1
  57. package/lib/typescript/commonjs/command/Command.d.ts +8 -8
  58. package/lib/typescript/commonjs/command/Command.d.ts.map +1 -1
  59. package/lib/typescript/commonjs/command/index.d.ts.map +1 -1
  60. package/lib/typescript/commonjs/command/index.web.d.ts.map +1 -1
  61. package/lib/typescript/commonjs/dialog/Dialog.d.ts +17 -15
  62. package/lib/typescript/commonjs/dialog/Dialog.d.ts.map +1 -1
  63. package/lib/typescript/commonjs/dialog/Dialog.web.d.ts +18 -5
  64. package/lib/typescript/commonjs/dialog/Dialog.web.d.ts.map +1 -1
  65. package/lib/typescript/commonjs/dialog/index.d.ts +2 -4
  66. package/lib/typescript/commonjs/dialog/index.d.ts.map +1 -1
  67. package/lib/typescript/commonjs/dialog/index.web.d.ts +2 -4
  68. package/lib/typescript/commonjs/dialog/index.web.d.ts.map +1 -1
  69. package/lib/typescript/commonjs/dialog/placement.d.ts +71 -0
  70. package/lib/typescript/commonjs/dialog/placement.d.ts.map +1 -0
  71. package/lib/typescript/commonjs/dialog/types.d.ts +66 -3
  72. package/lib/typescript/commonjs/dialog/types.d.ts.map +1 -1
  73. package/lib/typescript/commonjs/index.d.ts +2 -4
  74. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  75. package/lib/typescript/commonjs/index.web.d.ts +2 -4
  76. package/lib/typescript/commonjs/index.web.d.ts.map +1 -1
  77. package/lib/typescript/module/alert-dialog/AlertDialog.d.ts +13 -12
  78. package/lib/typescript/module/alert-dialog/AlertDialog.d.ts.map +1 -1
  79. package/lib/typescript/module/alert-dialog/index.d.ts.map +1 -1
  80. package/lib/typescript/module/alert-dialog/index.web.d.ts.map +1 -1
  81. package/lib/typescript/module/command/Command.d.ts +8 -8
  82. package/lib/typescript/module/command/Command.d.ts.map +1 -1
  83. package/lib/typescript/module/command/index.d.ts.map +1 -1
  84. package/lib/typescript/module/command/index.web.d.ts.map +1 -1
  85. package/lib/typescript/module/dialog/Dialog.d.ts +17 -15
  86. package/lib/typescript/module/dialog/Dialog.d.ts.map +1 -1
  87. package/lib/typescript/module/dialog/Dialog.web.d.ts +18 -5
  88. package/lib/typescript/module/dialog/Dialog.web.d.ts.map +1 -1
  89. package/lib/typescript/module/dialog/index.d.ts +2 -4
  90. package/lib/typescript/module/dialog/index.d.ts.map +1 -1
  91. package/lib/typescript/module/dialog/index.web.d.ts +2 -4
  92. package/lib/typescript/module/dialog/index.web.d.ts.map +1 -1
  93. package/lib/typescript/module/dialog/placement.d.ts +71 -0
  94. package/lib/typescript/module/dialog/placement.d.ts.map +1 -0
  95. package/lib/typescript/module/dialog/types.d.ts +66 -3
  96. package/lib/typescript/module/dialog/types.d.ts.map +1 -1
  97. package/lib/typescript/module/index.d.ts +2 -4
  98. package/lib/typescript/module/index.d.ts.map +1 -1
  99. package/lib/typescript/module/index.web.d.ts +2 -4
  100. package/lib/typescript/module/index.web.d.ts.map +1 -1
  101. package/package.json +1 -18
  102. package/src/__tests__/AlertDialog.test.tsx +122 -0
  103. package/src/__tests__/Command.test.tsx +107 -0
  104. package/src/__tests__/DialogPlacement.test.tsx +144 -0
  105. package/src/alert-dialog/AlertDialog.tsx +46 -36
  106. package/src/alert-dialog/index.ts +2 -2
  107. package/src/alert-dialog/index.web.ts +2 -2
  108. package/src/command/Command.tsx +30 -19
  109. package/src/command/index.ts +2 -2
  110. package/src/command/index.web.ts +2 -2
  111. package/src/dialog/Dialog.tsx +406 -50
  112. package/src/dialog/Dialog.web.tsx +496 -78
  113. package/src/dialog/index.ts +4 -3
  114. package/src/dialog/index.web.ts +4 -7
  115. package/src/dialog/placement.ts +113 -0
  116. package/src/dialog/types.ts +69 -3
  117. package/src/index.ts +4 -11
  118. package/src/index.web.ts +4 -11
  119. package/lib/commonjs/dialog/CenteredDialog.js +0 -250
  120. package/lib/commonjs/dialog/CenteredDialog.js.map +0 -1
  121. package/lib/commonjs/dialog/CenteredDialog.web.js +0 -328
  122. package/lib/commonjs/dialog/CenteredDialog.web.js.map +0 -1
  123. package/lib/commonjs/dialog/centered-dialog-tokens.js +0 -62
  124. package/lib/commonjs/dialog/centered-dialog-tokens.js.map +0 -1
  125. package/lib/commonjs/dialog/centered-dialog-types.js +0 -6
  126. package/lib/commonjs/dialog/centered-dialog-types.js.map +0 -1
  127. package/lib/commonjs/responsive-sheet/ResponsiveSheet.js +0 -300
  128. package/lib/commonjs/responsive-sheet/ResponsiveSheet.js.map +0 -1
  129. package/lib/commonjs/responsive-sheet/ResponsiveSheet.native.js +0 -226
  130. package/lib/commonjs/responsive-sheet/ResponsiveSheet.native.js.map +0 -1
  131. package/lib/commonjs/responsive-sheet/const.js +0 -60
  132. package/lib/commonjs/responsive-sheet/const.js.map +0 -1
  133. package/lib/commonjs/responsive-sheet/index.js +0 -19
  134. package/lib/commonjs/responsive-sheet/index.js.map +0 -1
  135. package/lib/commonjs/responsive-sheet/index.web.js +0 -19
  136. package/lib/commonjs/responsive-sheet/index.web.js.map +0 -1
  137. package/lib/commonjs/responsive-sheet/types.js +0 -6
  138. package/lib/commonjs/responsive-sheet/types.js.map +0 -1
  139. package/lib/module/dialog/CenteredDialog.js +0 -244
  140. package/lib/module/dialog/CenteredDialog.js.map +0 -1
  141. package/lib/module/dialog/CenteredDialog.web.js +0 -322
  142. package/lib/module/dialog/CenteredDialog.web.js.map +0 -1
  143. package/lib/module/dialog/centered-dialog-tokens.js +0 -58
  144. package/lib/module/dialog/centered-dialog-tokens.js.map +0 -1
  145. package/lib/module/dialog/centered-dialog-types.js +0 -4
  146. package/lib/module/dialog/centered-dialog-types.js.map +0 -1
  147. package/lib/module/responsive-sheet/ResponsiveSheet.js +0 -293
  148. package/lib/module/responsive-sheet/ResponsiveSheet.js.map +0 -1
  149. package/lib/module/responsive-sheet/ResponsiveSheet.native.js +0 -219
  150. package/lib/module/responsive-sheet/ResponsiveSheet.native.js.map +0 -1
  151. package/lib/module/responsive-sheet/const.js +0 -56
  152. package/lib/module/responsive-sheet/const.js.map +0 -1
  153. package/lib/module/responsive-sheet/index.js +0 -4
  154. package/lib/module/responsive-sheet/index.js.map +0 -1
  155. package/lib/module/responsive-sheet/index.web.js +0 -14
  156. package/lib/module/responsive-sheet/index.web.js.map +0 -1
  157. package/lib/module/responsive-sheet/types.js +0 -4
  158. package/lib/module/responsive-sheet/types.js.map +0 -1
  159. package/lib/typescript/commonjs/dialog/CenteredDialog.d.ts +0 -20
  160. package/lib/typescript/commonjs/dialog/CenteredDialog.d.ts.map +0 -1
  161. package/lib/typescript/commonjs/dialog/CenteredDialog.web.d.ts +0 -29
  162. package/lib/typescript/commonjs/dialog/CenteredDialog.web.d.ts.map +0 -1
  163. package/lib/typescript/commonjs/dialog/centered-dialog-tokens.d.ts +0 -47
  164. package/lib/typescript/commonjs/dialog/centered-dialog-tokens.d.ts.map +0 -1
  165. package/lib/typescript/commonjs/dialog/centered-dialog-types.d.ts +0 -70
  166. package/lib/typescript/commonjs/dialog/centered-dialog-types.d.ts.map +0 -1
  167. package/lib/typescript/commonjs/responsive-sheet/ResponsiveSheet.d.ts +0 -26
  168. package/lib/typescript/commonjs/responsive-sheet/ResponsiveSheet.d.ts.map +0 -1
  169. package/lib/typescript/commonjs/responsive-sheet/ResponsiveSheet.native.d.ts +0 -20
  170. package/lib/typescript/commonjs/responsive-sheet/ResponsiveSheet.native.d.ts.map +0 -1
  171. package/lib/typescript/commonjs/responsive-sheet/const.d.ts +0 -43
  172. package/lib/typescript/commonjs/responsive-sheet/const.d.ts.map +0 -1
  173. package/lib/typescript/commonjs/responsive-sheet/index.d.ts +0 -3
  174. package/lib/typescript/commonjs/responsive-sheet/index.d.ts.map +0 -1
  175. package/lib/typescript/commonjs/responsive-sheet/index.web.d.ts +0 -3
  176. package/lib/typescript/commonjs/responsive-sheet/index.web.d.ts.map +0 -1
  177. package/lib/typescript/commonjs/responsive-sheet/types.d.ts +0 -55
  178. package/lib/typescript/commonjs/responsive-sheet/types.d.ts.map +0 -1
  179. package/lib/typescript/module/dialog/CenteredDialog.d.ts +0 -20
  180. package/lib/typescript/module/dialog/CenteredDialog.d.ts.map +0 -1
  181. package/lib/typescript/module/dialog/CenteredDialog.web.d.ts +0 -29
  182. package/lib/typescript/module/dialog/CenteredDialog.web.d.ts.map +0 -1
  183. package/lib/typescript/module/dialog/centered-dialog-tokens.d.ts +0 -47
  184. package/lib/typescript/module/dialog/centered-dialog-tokens.d.ts.map +0 -1
  185. package/lib/typescript/module/dialog/centered-dialog-types.d.ts +0 -70
  186. package/lib/typescript/module/dialog/centered-dialog-types.d.ts.map +0 -1
  187. package/lib/typescript/module/responsive-sheet/ResponsiveSheet.d.ts +0 -26
  188. package/lib/typescript/module/responsive-sheet/ResponsiveSheet.d.ts.map +0 -1
  189. package/lib/typescript/module/responsive-sheet/ResponsiveSheet.native.d.ts +0 -20
  190. package/lib/typescript/module/responsive-sheet/ResponsiveSheet.native.d.ts.map +0 -1
  191. package/lib/typescript/module/responsive-sheet/const.d.ts +0 -43
  192. package/lib/typescript/module/responsive-sheet/const.d.ts.map +0 -1
  193. package/lib/typescript/module/responsive-sheet/index.d.ts +0 -3
  194. package/lib/typescript/module/responsive-sheet/index.d.ts.map +0 -1
  195. package/lib/typescript/module/responsive-sheet/index.web.d.ts +0 -3
  196. package/lib/typescript/module/responsive-sheet/index.web.d.ts.map +0 -1
  197. package/lib/typescript/module/responsive-sheet/types.d.ts +0 -55
  198. package/lib/typescript/module/responsive-sheet/types.d.ts.map +0 -1
  199. package/src/__tests__/CenteredDialog.test.tsx +0 -108
  200. package/src/__tests__/ResponsiveSheet.test.tsx +0 -104
  201. package/src/dialog/CenteredDialog.stories.tsx +0 -125
  202. package/src/dialog/CenteredDialog.tsx +0 -303
  203. package/src/dialog/CenteredDialog.web.tsx +0 -372
  204. package/src/dialog/centered-dialog-tokens.ts +0 -68
  205. package/src/dialog/centered-dialog-types.ts +0 -70
  206. package/src/responsive-sheet/ResponsiveSheet.native.tsx +0 -257
  207. package/src/responsive-sheet/ResponsiveSheet.stories.tsx +0 -54
  208. package/src/responsive-sheet/ResponsiveSheet.tsx +0 -327
  209. package/src/responsive-sheet/const.ts +0 -53
  210. package/src/responsive-sheet/index.ts +0 -6
  211. package/src/responsive-sheet/index.web.ts +0 -16
  212. package/src/responsive-sheet/types.ts +0 -57
@@ -1,19 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- Object.defineProperty(exports, "RESPONSIVE_SHEET_BACKDROP_TESTID", {
7
- enumerable: true,
8
- get: function () {
9
- return _ResponsiveSheet.RESPONSIVE_SHEET_BACKDROP_TESTID;
10
- }
11
- });
12
- Object.defineProperty(exports, "ResponsiveSheet", {
13
- enumerable: true,
14
- get: function () {
15
- return _ResponsiveSheet.ResponsiveSheet;
16
- }
17
- });
18
- var _ResponsiveSheet = require("./ResponsiveSheet");
19
- //# sourceMappingURL=index.web.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_ResponsiveSheet","require"],"sourceRoot":"../../../src","sources":["responsive-sheet/index.web.ts"],"mappings":";;;;;;;;;;;;;;;;;AAUA,IAAAA,gBAAA,GAAAC,OAAA","ignoreList":[]}
@@ -1,6 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- //# sourceMappingURL=types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":[],"sourceRoot":"../../../src","sources":["responsive-sheet/types.ts"],"mappings":"","ignoreList":[]}
@@ -1,244 +0,0 @@
1
- "use strict";
2
-
3
- import React, { useMemo } from 'react';
4
- import { Modal, Pressable, ScrollView, StyleSheet, View } from 'react-native';
5
- import { useInteractionState } from "../hooks/useInteractionState.js";
6
- import { TimesLarge_Stroke2_Corner0_Rounded as CloseIcon } from "../icons/Times.js";
7
- import { useTheme } from "../theme/use-theme.js";
8
- import { Text } from "../typography/index.js";
9
- import { CARD_RADIUS, DEFAULT_MAX_WIDTH, MAX_HEIGHT_FRACTION, resolveSpacing, VIEWPORT_GUTTER } from "./centered-dialog-tokens.js";
10
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
11
- const CLOSE_HIT_SLOP = {
12
- top: 8,
13
- bottom: 8,
14
- left: 8,
15
- right: 8
16
- };
17
-
18
- /** Stable testID for the dimmed backdrop. Overridden when a `testID` is set. */
19
- export const CENTERED_DIALOG_BACKDROP_TESTID = 'bloom-centered-dialog-backdrop';
20
-
21
- /**
22
- * Native variant of `<CenteredDialog>`.
23
- *
24
- * A controlled, centered modal: a transparent RN `Modal` (fade animation,
25
- * own native window) hosting a dimmed full-screen backdrop and a centered,
26
- * rounded card styled entirely from Bloom theme tokens.
27
- *
28
- * The backdrop is a sibling `Pressable` rendered BEHIND the card (absolute
29
- * filled), never a parent of it — so a tap on the card never bubbles to the
30
- * backdrop's close handler and the card never ends up nested inside the
31
- * backdrop's pressable on web.
32
- *
33
- * Dismissal: backdrop tap (when `dismissible`), the header close button, and
34
- * the Android hardware back button (`onRequestClose`) all call `onClose`.
35
- */
36
- export function CenteredDialog({
37
- visible,
38
- onClose,
39
- title,
40
- dismissible = true,
41
- maxWidth = DEFAULT_MAX_WIDTH,
42
- compact = true,
43
- showClose,
44
- children,
45
- footer,
46
- accessibilityLabel,
47
- closeAccessibilityLabel = 'Close dialog',
48
- backdropAccessibilityLabel = 'Dismiss dialog',
49
- cardStyle,
50
- contentStyle,
51
- testID
52
- }) {
53
- const theme = useTheme();
54
- const backdropPress = useInteractionState();
55
- const spacing = useMemo(() => resolveSpacing(compact), [compact]);
56
- const resolvedShowClose = showClose ?? Boolean(title);
57
- const hasHeader = Boolean(title) || resolvedShowClose;
58
- const handleBackdropPress = dismissible ? onClose : undefined;
59
- // Android's hardware back must always be answerable; when the dialog is
60
- // non-dismissible we still need a handler (RN requires one for transparent
61
- // modals) — make it a no-op so back does nothing rather than crash.
62
- const handleRequestClose = dismissible ? onClose : noop;
63
- return /*#__PURE__*/_jsx(Modal, {
64
- visible: visible,
65
- transparent: true,
66
- animationType: "fade",
67
- statusBarTranslucent: true,
68
- onRequestClose: handleRequestClose,
69
- children: /*#__PURE__*/_jsxs(View, {
70
- style: [styles.root, {
71
- padding: VIEWPORT_GUTTER
72
- }],
73
- children: [/*#__PURE__*/_jsx(Pressable, {
74
- testID: testID ? `${testID}-backdrop` : CENTERED_DIALOG_BACKDROP_TESTID,
75
- style: [styles.backdrop, {
76
- backgroundColor: theme.colors.overlay
77
- }, backdropPress.state && styles.backdropPressed],
78
- onPress: handleBackdropPress,
79
- onPressIn: backdropPress.onIn,
80
- onPressOut: backdropPress.onOut,
81
- disabled: !dismissible,
82
- accessibilityRole: "button",
83
- accessibilityLabel: backdropAccessibilityLabel
84
- }), /*#__PURE__*/_jsxs(View, {
85
- testID: testID,
86
- accessibilityLabel: accessibilityLabel ?? title,
87
- style: [styles.card, {
88
- maxWidth,
89
- maxHeight: `${MAX_HEIGHT_FRACTION * 100}%`,
90
- backgroundColor: theme.colors.card,
91
- borderColor: theme.colors.border,
92
- shadowColor: theme.colors.shadow
93
- }, cardStyle],
94
- children: [hasHeader ? /*#__PURE__*/_jsx(DialogHeader, {
95
- title: title,
96
- showClose: resolvedShowClose,
97
- padding: spacing.pad,
98
- gap: spacing.headerGap,
99
- closeAccessibilityLabel: closeAccessibilityLabel,
100
- onClose: onClose
101
- }) : null, /*#__PURE__*/_jsx(ScrollView, {
102
- style: styles.bodyScroll,
103
- contentContainerStyle: [{
104
- padding: spacing.pad,
105
- paddingTop: hasHeader ? spacing.headerGap : spacing.pad,
106
- gap: spacing.contentGap
107
- }, contentStyle],
108
- showsVerticalScrollIndicator: false,
109
- keyboardShouldPersistTaps: "handled",
110
- children: children
111
- }), footer ? /*#__PURE__*/_jsx(View, {
112
- style: [styles.footer, {
113
- padding: spacing.pad,
114
- paddingTop: spacing.footerGap,
115
- borderTopColor: theme.colors.borderLight
116
- }],
117
- children: footer
118
- }) : null]
119
- })]
120
- })
121
- });
122
- }
123
- function DialogHeader({
124
- title,
125
- showClose,
126
- padding,
127
- gap,
128
- closeAccessibilityLabel,
129
- onClose
130
- }) {
131
- const theme = useTheme();
132
- return /*#__PURE__*/_jsxs(View, {
133
- style: [styles.header, {
134
- paddingHorizontal: padding,
135
- paddingTop: padding,
136
- gap
137
- }],
138
- children: [title ? /*#__PURE__*/_jsx(Text, {
139
- accessibilityRole: "header",
140
- numberOfLines: 2,
141
- style: [styles.title, {
142
- color: theme.colors.text
143
- }],
144
- children: title
145
- }) : /*#__PURE__*/_jsx(View, {
146
- style: styles.titleSpacer
147
- }), showClose ? /*#__PURE__*/_jsx(CloseButton, {
148
- accessibilityLabel: closeAccessibilityLabel,
149
- onPress: onClose
150
- }) : null]
151
- });
152
- }
153
- function CloseButton({
154
- accessibilityLabel,
155
- onPress
156
- }) {
157
- const theme = useTheme();
158
- const press = useInteractionState();
159
- return /*#__PURE__*/_jsx(Pressable, {
160
- onPress: onPress,
161
- onPressIn: press.onIn,
162
- onPressOut: press.onOut,
163
- hitSlop: CLOSE_HIT_SLOP,
164
- accessibilityRole: "button",
165
- accessibilityLabel: accessibilityLabel,
166
- style: [styles.closeButton, {
167
- backgroundColor: theme.colors.contrast50
168
- }, press.state && styles.closeButtonPressed],
169
- children: /*#__PURE__*/_jsx(CloseIcon, {
170
- size: "sm",
171
- fill: theme.colors.textSecondary
172
- })
173
- });
174
- }
175
- function noop() {
176
- /* non-dismissible: hardware back is intentionally inert */
177
- }
178
- const styles = StyleSheet.create({
179
- root: {
180
- flex: 1,
181
- alignItems: 'center',
182
- justifyContent: 'center'
183
- },
184
- backdrop: {
185
- // Spell out the absolute-fill rect (matches `Fill`'s canonical style)
186
- // rather than spreading the deprecated `StyleSheet.absoluteFillObject`,
187
- // which RN 0.83's generated types no longer surface on the `StyleSheet`
188
- // namespace and which downstream type-checks reject.
189
- position: 'absolute',
190
- top: 0,
191
- right: 0,
192
- bottom: 0,
193
- left: 0
194
- },
195
- // A subtle deepening on press confirms the tap-to-dismiss affordance.
196
- backdropPressed: {
197
- opacity: 0.92
198
- },
199
- card: {
200
- width: '100%',
201
- borderRadius: CARD_RADIUS,
202
- borderWidth: StyleSheet.hairlineWidth,
203
- overflow: 'hidden',
204
- shadowOpacity: 0.18,
205
- shadowRadius: 24,
206
- shadowOffset: {
207
- width: 0,
208
- height: 8
209
- },
210
- elevation: 12
211
- },
212
- header: {
213
- flexDirection: 'row',
214
- alignItems: 'flex-start',
215
- justifyContent: 'space-between'
216
- },
217
- title: {
218
- flex: 1,
219
- fontSize: 17,
220
- fontWeight: '700',
221
- lineHeight: 22
222
- },
223
- titleSpacer: {
224
- flex: 1
225
- },
226
- closeButton: {
227
- width: 28,
228
- height: 28,
229
- borderRadius: 14,
230
- alignItems: 'center',
231
- justifyContent: 'center'
232
- },
233
- closeButtonPressed: {
234
- opacity: 0.7
235
- },
236
- bodyScroll: {
237
- flexGrow: 0,
238
- flexShrink: 1
239
- },
240
- footer: {
241
- borderTopWidth: StyleSheet.hairlineWidth
242
- }
243
- });
244
- //# sourceMappingURL=CenteredDialog.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["React","useMemo","Modal","Pressable","ScrollView","StyleSheet","View","useInteractionState","TimesLarge_Stroke2_Corner0_Rounded","CloseIcon","useTheme","Text","CARD_RADIUS","DEFAULT_MAX_WIDTH","MAX_HEIGHT_FRACTION","resolveSpacing","VIEWPORT_GUTTER","jsx","_jsx","jsxs","_jsxs","CLOSE_HIT_SLOP","top","bottom","left","right","CENTERED_DIALOG_BACKDROP_TESTID","CenteredDialog","visible","onClose","title","dismissible","maxWidth","compact","showClose","children","footer","accessibilityLabel","closeAccessibilityLabel","backdropAccessibilityLabel","cardStyle","contentStyle","testID","theme","backdropPress","spacing","resolvedShowClose","Boolean","hasHeader","handleBackdropPress","undefined","handleRequestClose","noop","transparent","animationType","statusBarTranslucent","onRequestClose","style","styles","root","padding","backdrop","backgroundColor","colors","overlay","state","backdropPressed","onPress","onPressIn","onIn","onPressOut","onOut","disabled","accessibilityRole","card","maxHeight","borderColor","border","shadowColor","shadow","DialogHeader","pad","gap","headerGap","bodyScroll","contentContainerStyle","paddingTop","contentGap","showsVerticalScrollIndicator","keyboardShouldPersistTaps","footerGap","borderTopColor","borderLight","header","paddingHorizontal","numberOfLines","color","text","titleSpacer","CloseButton","press","hitSlop","closeButton","contrast50","closeButtonPressed","size","fill","textSecondary","create","flex","alignItems","justifyContent","position","opacity","width","borderRadius","borderWidth","hairlineWidth","overflow","shadowOpacity","shadowRadius","shadowOffset","height","elevation","flexDirection","fontSize","fontWeight","lineHeight","flexGrow","flexShrink","borderTopWidth"],"sourceRoot":"../../../src","sources":["dialog/CenteredDialog.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,OAAO,QAAQ,OAAO;AACtC,SACEC,KAAK,EACLC,SAAS,EACTC,UAAU,EACVC,UAAU,EACVC,IAAI,QACC,cAAc;AAEr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,EAAE,EAAE;IAChBL,UAAU,EAAE,QAAQ;IACpBC,cAAc,EAAE;EAClB,CAAC;EACDP,kBAAkB,EAAE;IAClBS,OAAO,EAAE;EACX,CAAC;EACD7B,UAAU,EAAE;IACV4C,QAAQ,EAAE,CAAC;IACXC,UAAU,EAAE;EACd,CAAC;EACD7F,MAAM,EAAE;IACN8F,cAAc,EAAE7H,UAAU,CAACgH;EAC7B;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1,322 +0,0 @@
1
- "use strict";
2
-
3
- import React, { useEffect, useMemo, useState } from 'react';
4
- import { Pressable, ScrollView, StyleSheet, View } from 'react-native';
5
- import { RemoveScrollBar } from 'react-remove-scroll-bar';
6
- import { useInteractionStates } from "../hooks/useInteractionState.js";
7
- import { TimesLarge_Stroke2_Corner0_Rounded as CloseIcon } from "../icons/Times.js";
8
- import { Portal } from "../portal/index.web.js";
9
- import { createOverlayZIndex } from "../styles/z-index.js";
10
- import { useTheme } from "../theme/use-theme.js";
11
- import { Text } from "../typography/index.js";
12
- import { CARD_RADIUS, DEFAULT_MAX_WIDTH, MAX_HEIGHT_FRACTION, resolveSpacing, VIEWPORT_GUTTER } from "./centered-dialog-tokens.js";
13
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
14
- const FADE_OUT_DURATION = 150;
15
- const CLOSE_HIT_SLOP = {
16
- top: 8,
17
- bottom: 8,
18
- left: 8,
19
- right: 8
20
- };
21
- const dialogZIndex = createOverlayZIndex();
22
-
23
- /** Stable testID for the dimmed backdrop. Overridden when a `testID` is set. */
24
- export const CENTERED_DIALOG_BACKDROP_TESTID = 'bloom-centered-dialog-backdrop';
25
- const stopPropagation = e => e.stopPropagation();
26
-
27
- /**
28
- * Web variant of `<CenteredDialog>`.
29
- *
30
- * A centered modal card rendered into the Bloom Portal at the end of
31
- * `document.body`. Identical prop surface to native — `visible`, `onClose`,
32
- * `title`, `compact`, etc. — so call sites are platform agnostic.
33
- *
34
- * Differences from the native fork (necessary, not behavioural):
35
- * - Portal + `RemoveScrollBar` lock the underlying page while open.
36
- * - `Escape` dismisses (when `dismissible`).
37
- * - A `role="dialog"` panel with `aria-label`/`aria-modal` for a11y.
38
- * - A CSS fade/zoom keyframe matches the native modal's `fade` animation;
39
- * the keyframes are injected once (idempotent) into `<head>`.
40
- *
41
- * The backdrop is a sibling element BEHIND the card, and the card stops
42
- * click/press propagation so a tap on the card never dismisses.
43
- */
44
- export function CenteredDialog({
45
- visible,
46
- onClose,
47
- title,
48
- dismissible = true,
49
- maxWidth = DEFAULT_MAX_WIDTH,
50
- compact = true,
51
- showClose,
52
- children,
53
- footer,
54
- accessibilityLabel,
55
- closeAccessibilityLabel = 'Close dialog',
56
- backdropAccessibilityLabel = 'Dismiss dialog',
57
- cardStyle,
58
- contentStyle,
59
- testID
60
- }) {
61
- const theme = useTheme();
62
- // `rendered` keeps the dialog mounted through its fade-out so a controlled
63
- // `visible` flip to `false` still plays an exit animation (matching the
64
- // native `Modal animationType="fade"`, which animates both directions).
65
- const [rendered, setRendered] = useState(visible);
66
- const isClosing = rendered && !visible;
67
- useKeyframes();
68
-
69
- // Mount immediately when opened; defer unmount until the exit animation
70
- // has played when closed.
71
- useEffect(() => {
72
- if (visible) {
73
- setRendered(true);
74
- return;
75
- }
76
- if (!rendered) return;
77
- const timer = setTimeout(() => setRendered(false), FADE_OUT_DURATION);
78
- return () => clearTimeout(timer);
79
- }, [visible, rendered]);
80
-
81
- // Escape-to-close while open. Scoped to the open lifetime so stacked
82
- // dialogs don't fight for the keydown — the top-most one wins via
83
- // document-level event order.
84
- useEffect(() => {
85
- if (!visible || !dismissible || typeof document === 'undefined') return;
86
- const handler = e => {
87
- if (e.key === 'Escape') {
88
- e.stopPropagation();
89
- onClose();
90
- }
91
- };
92
- document.addEventListener('keydown', handler);
93
- return () => document.removeEventListener('keydown', handler);
94
- }, [visible, dismissible, onClose]);
95
- const spacing = useMemo(() => resolveSpacing(compact), [compact]);
96
- const resolvedShowClose = showClose ?? Boolean(title);
97
- const hasHeader = Boolean(title) || resolvedShowClose;
98
- if (!rendered) return null;
99
-
100
- // While closing, the backdrop must not re-trigger onClose (it's mid-exit).
101
- const handleBackdropPress = dismissible && !isClosing ? onClose : undefined;
102
- return /*#__PURE__*/_jsxs(Portal, {
103
- children: [/*#__PURE__*/_jsx(RemoveScrollBar, {}), /*#__PURE__*/_jsxs(View, {
104
- style: [styles.root, {
105
- padding: VIEWPORT_GUTTER
106
- }],
107
- children: [/*#__PURE__*/_jsx(Pressable, {
108
- testID: testID ? `${testID}-backdrop` : CENTERED_DIALOG_BACKDROP_TESTID,
109
- onPress: handleBackdropPress,
110
- disabled: !dismissible,
111
- accessibilityRole: "button",
112
- accessibilityLabel: backdropAccessibilityLabel,
113
- style: [styles.backdrop, {
114
- backgroundColor: theme.colors.overlay
115
- }, backdropAnimation(isClosing)]
116
- }), /*#__PURE__*/_jsxs(View, {
117
- testID: testID,
118
- role: "dialog",
119
- "aria-modal": true,
120
- "aria-label": accessibilityLabel ?? title,
121
- onStartShouldSetResponder: returnsTrue,
122
- onResponderRelease: stopPropagation,
123
- onClick: stopPropagation,
124
- style: [styles.card, {
125
- maxWidth,
126
- maxHeight: `${MAX_HEIGHT_FRACTION * 100}%`,
127
- backgroundColor: theme.colors.card,
128
- borderColor: theme.colors.border,
129
- shadowColor: theme.colors.shadow
130
- }, cardAnimation(isClosing), cardStyle],
131
- children: [hasHeader ? /*#__PURE__*/_jsx(DialogHeader, {
132
- title: title,
133
- showClose: resolvedShowClose,
134
- padding: spacing.pad,
135
- gap: spacing.headerGap,
136
- closeAccessibilityLabel: closeAccessibilityLabel,
137
- onClose: onClose
138
- }) : null, /*#__PURE__*/_jsx(ScrollView, {
139
- style: styles.bodyScroll,
140
- contentContainerStyle: [{
141
- padding: spacing.pad,
142
- paddingTop: hasHeader ? spacing.headerGap : spacing.pad,
143
- gap: spacing.contentGap
144
- }, contentStyle],
145
- showsVerticalScrollIndicator: false,
146
- keyboardShouldPersistTaps: "handled",
147
- children: children
148
- }), footer ? /*#__PURE__*/_jsx(View, {
149
- style: [styles.footer, {
150
- padding: spacing.pad,
151
- paddingTop: spacing.footerGap,
152
- borderTopColor: theme.colors.borderLight
153
- }],
154
- children: footer
155
- }) : null]
156
- })]
157
- })]
158
- });
159
- }
160
- function DialogHeader({
161
- title,
162
- showClose,
163
- padding,
164
- gap,
165
- closeAccessibilityLabel,
166
- onClose
167
- }) {
168
- const theme = useTheme();
169
- return /*#__PURE__*/_jsxs(View, {
170
- style: [styles.header, {
171
- paddingHorizontal: padding,
172
- paddingTop: padding,
173
- gap
174
- }],
175
- children: [title ? /*#__PURE__*/_jsx(Text, {
176
- accessibilityRole: "header",
177
- numberOfLines: 2,
178
- style: [styles.title, {
179
- color: theme.colors.text
180
- }],
181
- children: title
182
- }) : /*#__PURE__*/_jsx(View, {
183
- style: styles.titleSpacer
184
- }), showClose ? /*#__PURE__*/_jsx(CloseButton, {
185
- accessibilityLabel: closeAccessibilityLabel,
186
- onPress: onClose
187
- }) : null]
188
- });
189
- }
190
- function CloseButton({
191
- accessibilityLabel,
192
- onPress
193
- }) {
194
- const theme = useTheme();
195
- const {
196
- hovered,
197
- pressed,
198
- hoverHandlers,
199
- pressHandlers
200
- } = useInteractionStates();
201
- return /*#__PURE__*/_jsx(Pressable, {
202
- onPress: onPress,
203
- ...hoverHandlers,
204
- ...pressHandlers,
205
- hitSlop: CLOSE_HIT_SLOP,
206
- accessibilityRole: "button",
207
- accessibilityLabel: accessibilityLabel,
208
- style: [styles.closeButton, {
209
- backgroundColor: theme.colors.contrast50
210
- }, (hovered || pressed) && styles.closeButtonActive],
211
- children: /*#__PURE__*/_jsx(CloseIcon, {
212
- size: "sm",
213
- fill: theme.colors.textSecondary
214
- })
215
- });
216
- }
217
- const returnsTrue = () => true;
218
- function backdropAnimation(isClosing) {
219
- return isClosing ? {
220
- animation: `bloomCenteredDialogFadeOut ease-in ${FADE_OUT_DURATION}ms forwards`
221
- } : {
222
- animation: 'bloomCenteredDialogFadeIn ease-out 150ms'
223
- };
224
- }
225
- function cardAnimation(isClosing) {
226
- return isClosing ? {
227
- animation: `bloomCenteredDialogZoomOut ease-in ${FADE_OUT_DURATION}ms forwards`
228
- } : {
229
- animation: 'bloomCenteredDialogZoomIn cubic-bezier(0.16, 1, 0.3, 1) 200ms'
230
- };
231
- }
232
- const KEYFRAMES_ID = 'bloom-centered-dialog-keyframes';
233
-
234
- /**
235
- * CSS keyframes powering the web enter/exit animation. Injected once into
236
- * `<head>` on first mount (keyed by id so re-mounts and multiple dialogs
237
- * don't duplicate the rule). Mirrors the native modal's `fade` feel with a
238
- * subtle zoom on the card.
239
- */
240
- export const BLOOM_CENTERED_DIALOG_CSS = `
241
- @keyframes bloomCenteredDialogFadeIn { from { opacity: 0; } to { opacity: 1; } }
242
- @keyframes bloomCenteredDialogFadeOut { from { opacity: 1; } to { opacity: 0; } }
243
- @keyframes bloomCenteredDialogZoomIn { from { opacity: 0; transform: scale(0.96); } to { opacity: 1; transform: scale(1); } }
244
- @keyframes bloomCenteredDialogZoomOut { from { opacity: 1; transform: scale(1); } to { opacity: 0; transform: scale(0.96); } }
245
- `;
246
- function useKeyframes() {
247
- useEffect(() => {
248
- if (typeof document === 'undefined') return;
249
- if (document.getElementById(KEYFRAMES_ID)) return;
250
- const style = document.createElement('style');
251
- style.id = KEYFRAMES_ID;
252
- style.textContent = BLOOM_CENTERED_DIALOG_CSS;
253
- document.head.appendChild(style);
254
- }, []);
255
- }
256
- const styles = StyleSheet.create({
257
- root: {
258
- position: 'fixed',
259
- top: 0,
260
- left: 0,
261
- right: 0,
262
- bottom: 0,
263
- zIndex: dialogZIndex.backdrop,
264
- alignItems: 'center',
265
- justifyContent: 'center',
266
- pointerEvents: 'auto'
267
- },
268
- backdrop: {
269
- position: 'fixed',
270
- top: 0,
271
- left: 0,
272
- right: 0,
273
- bottom: 0
274
- },
275
- card: {
276
- position: 'relative',
277
- width: '100%',
278
- borderRadius: CARD_RADIUS,
279
- borderWidth: 1,
280
- overflow: 'hidden',
281
- shadowOpacity: 0.18,
282
- shadowRadius: 24,
283
- shadowOffset: {
284
- width: 0,
285
- height: 8
286
- },
287
- zIndex: dialogZIndex.surface
288
- },
289
- header: {
290
- flexDirection: 'row',
291
- alignItems: 'flex-start',
292
- justifyContent: 'space-between'
293
- },
294
- title: {
295
- flex: 1,
296
- fontSize: 17,
297
- fontWeight: '700',
298
- lineHeight: 22
299
- },
300
- titleSpacer: {
301
- flex: 1
302
- },
303
- closeButton: {
304
- width: 28,
305
- height: 28,
306
- borderRadius: 14,
307
- alignItems: 'center',
308
- justifyContent: 'center',
309
- cursor: 'pointer'
310
- },
311
- closeButtonActive: {
312
- opacity: 0.7
313
- },
314
- bodyScroll: {
315
- flexGrow: 0,
316
- flexShrink: 1
317
- },
318
- footer: {
319
- borderTopWidth: 1
320
- }
321
- });
322
- //# sourceMappingURL=CenteredDialog.web.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["React","useEffect","useMemo","useState","Pressable","ScrollView","StyleSheet","View","RemoveScrollBar","useInteractionStates","TimesLarge_Stroke2_Corner0_Rounded","CloseIcon","Portal","createOverlayZIndex","useTheme","Text","CARD_RADIUS","DEFAULT_MAX_WIDTH","MAX_HEIGHT_FRACTION","resolveSpacing","VIEWPORT_GUTTER","jsx","_jsx","jsxs","_jsxs","FADE_OUT_DURATION","CLOSE_HIT_SLOP","top","bottom","left","right","dialogZIndex","CENTERED_DIALOG_BACKDROP_TESTID","stopPropagation","e","CenteredDialog","visible","onClose","title","dismissible","maxWidth","compact","showClose","children","footer","accessibilityLabel","closeAccessibilityLabel","backdropAccessibilityLabel","cardStyle","contentStyle","testID","theme","rendered","setRendered","isClosing","useKeyframes","timer","setTimeout","clearTimeout","document","handler","key","addEventListener","removeEventListener","spacing","resolvedShowClose","Boolean","hasHeader","handleBackdropPress","undefined","style","styles","root","padding","onPress","disabled","accessibilityRole","backdrop","backgroundColor","colors","overlay","backdropAnimation","role","onStartShouldSetResponder","returnsTrue","onResponderRelease","onClick","card","maxHeight","borderColor","border","shadowColor","shadow","cardAnimation","DialogHeader","pad","gap","headerGap","bodyScroll","contentContainerStyle","paddingTop","contentGap","showsVerticalScrollIndicator","keyboardShouldPersistTaps","footerGap","borderTopColor","borderLight","header","paddingHorizontal","numberOfLines","color","text","titleSpacer","CloseButton","hovered","pressed","hoverHandlers","pressHandlers","hitSlop","closeButton","contrast50","closeButtonActive","size","fill","textSecondary","animation","KEYFRAMES_ID","BLOOM_CENTERED_DIALOG_CSS","getElementById","createElement","id","textContent","head","appendChild","create","position","zIndex","alignItems","justifyContent","pointerEvents","width","borderRadius","borderWidth","overflow","shadowOpacity","shadowRadius","shadowOffset","height","surface","flexDirection","flex","fontSize","fontWeight","lineHeight","cursor","opacity","flexGrow","flexShrink","borderTopWidth"],"sourceRoot":"../../../src","sources":["dialog/CenteredDialog.web.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,OAAO,EAAEC,QAAQ,QAAQ,OAAO;AAC3D,SAASC,SAAS,EAAEC,UAAU,EAAEC,UAAU,EAAEC,IAAI,QAAwB,cAAc;AACtF,SAASC,eAAe,QAAQ,yBAAyB;AAEzD,SAASC,oBAAoB,QAAQ,iCAA8B;AACnE,SAASC,kCAAkC,IAAIC,SAAS,QAAQ,mBAAgB;AAChF,SAASC,MAAM,QAAQ,wBAAqB;AAC5C,SAASC,mBAAmB,QAAQ,sBAAmB;AACvD,SAASC,QAAQ,QAAQ,uBAAoB;AAC7C,SAASC,IAAI,QAAQ,wBAAe;AAEpC,SACEC,WAAW,EACXC,iBAAiB,EACjBC,mBAAmB,EACnBC,cAAc,EACdC,eAAe,QACV,6BAA0B;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAElC,MAAMC,iBAAiB,GAAG,GAAG;AAC7B,MAAMC,cAAc,GAAG;EAAEC,GAAG,EAAE,CAAC;EAAEC,MAAM,EAAE,CAAC;EAAEC,IAAI,EAAE,CA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