@tamagui/dialog 2.0.0-rc.8 → 2.0.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.
@@ -1,502 +0,0 @@
1
- import {
2
- Adapt,
3
- AdaptParent,
4
- AdaptPortalContents,
5
- ProvideAdaptContext,
6
- useAdaptContext,
7
- useAdaptIsActive
8
- } from "@tamagui/adapt";
9
- import { Animate } from "@tamagui/animate";
10
- import { composeRefs, useComposedRefs } from "@tamagui/compose-refs";
11
- import { isWeb, useIsomorphicLayoutEffect } from "@tamagui/constants";
12
- import {
13
- createStyledContext,
14
- getExpandedShorthand,
15
- LayoutMeasurementController,
16
- styled,
17
- Theme,
18
- useThemeName,
19
- View
20
- } from "@tamagui/core";
21
- import { createContext } from "@tamagui/create-context";
22
- import { Dismissable } from "@tamagui/dismissable";
23
- import { FocusScope, FocusScopeController } from "@tamagui/focus-scope";
24
- import { composeEventHandlers, withStaticProperties } from "@tamagui/helpers";
25
- import {
26
- needsPortalRepropagation,
27
- Portal,
28
- PortalItem,
29
- resolveViewZIndex
30
- } from "@tamagui/portal";
31
- import { RemoveScroll } from "@tamagui/remove-scroll";
32
- import { SheetController } from "@tamagui/sheet/controller";
33
- import { ButtonNestingContext, ThemeableStack, YStack } from "@tamagui/stacks";
34
- import { H2, Paragraph } from "@tamagui/text";
35
- import { useControllableState } from "@tamagui/use-controllable-state";
36
- import { StackZIndexContext } from "@tamagui/z-index-stack";
37
- import * as React from "react";
38
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
39
- const DialogContext = createStyledContext(
40
- // since we always provide this we can avoid setting here
41
- {},
42
- "Dialog__"
43
- ), { useStyledContext: useDialogContext, Provider: DialogProvider } = DialogContext, DialogTriggerFrame = styled(View, {
44
- name: "DialogTrigger"
45
- }), DialogTrigger = DialogTriggerFrame.styleable(
46
- function(props, forwardedRef) {
47
- const { scope, ...triggerProps } = props, isInsideButton = React.useContext(ButtonNestingContext), context = useDialogContext(scope), composedTriggerRef = useComposedRefs(forwardedRef, context.triggerRef);
48
- return /* @__PURE__ */ jsx(ButtonNestingContext.Provider, { value: !0, children: /* @__PURE__ */ jsx(
49
- DialogTriggerFrame,
50
- {
51
- render: isInsideButton ? "span" : "button",
52
- "aria-haspopup": "dialog",
53
- "aria-expanded": context.open,
54
- "aria-controls": context.contentId,
55
- "data-state": getState(context.open),
56
- ...triggerProps,
57
- ref: composedTriggerRef,
58
- onPress: composeEventHandlers(props.onPress, context.onOpenToggle)
59
- }
60
- ) });
61
- }
62
- ), DialogPortalFrame = styled(YStack, {
63
- pointerEvents: "none",
64
- render: "dialog",
65
- variants: {
66
- unstyled: {
67
- false: {
68
- alignItems: "center",
69
- justifyContent: "center",
70
- fullscreen: !0,
71
- "$platform-web": {
72
- // undo dialog styles
73
- borderWidth: 0,
74
- backgroundColor: "transparent",
75
- color: "inherit",
76
- maxInlineSize: "none",
77
- margin: 0,
78
- width: "auto",
79
- height: "auto",
80
- // ensure always in frame and right height
81
- maxHeight: "100vh",
82
- position: "fixed",
83
- // ensure dialog inherits stacking context from portal wrapper
84
- zIndex: 1
85
- }
86
- }
87
- }
88
- },
89
- defaultVariants: {
90
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
91
- }
92
- }), needsRepropagation = needsPortalRepropagation(), DialogPortalItem = ({
93
- context,
94
- children
95
- }) => {
96
- const themeName = useThemeName(), isAdapted = useAdaptIsActive(context.adaptScope), adaptContext = useAdaptContext(context.adaptScope);
97
- let content = /* @__PURE__ */ jsx(Theme, { name: themeName, children });
98
- return needsRepropagation && (content = /* @__PURE__ */ jsx(ProvideAdaptContext, { ...adaptContext, children: /* @__PURE__ */ jsx(DialogProvider, { ...context, children: content }) })), isAdapted ? /* @__PURE__ */ jsx(AdaptPortalContents, { scope: context.adaptScope, children: content }) : context.modal ? /* @__PURE__ */ jsx(PortalItem, { hostName: context.modal ? "root" : context.adaptScope, children: content }) : content;
99
- }, DialogPortal = React.forwardRef(
100
- (props, forwardRef) => {
101
- const { scope, forceMount, children, ...frameProps } = props, dialogRef = React.useRef(null), ref = composeRefs(dialogRef, forwardRef), context = useDialogContext(scope), keepMounted = forceMount || context.keepChildrenMounted, isAdapted = useAdaptIsActive(context.adaptScope), [isFullyHidden, setIsFullyHidden] = React.useState(!context.open);
102
- context.open && isFullyHidden && setIsFullyHidden(!1);
103
- const isVisible = context.open ? !0 : !isFullyHidden;
104
- isWeb && useIsomorphicLayoutEffect(() => {
105
- const node = dialogRef.current;
106
- node instanceof HTMLDialogElement && (isVisible ? node.show?.() : node.close?.());
107
- }, [isVisible]);
108
- const handleExitComplete = React.useCallback(() => {
109
- setIsFullyHidden(!0);
110
- }, []), zIndex = getExpandedShorthand("zIndex", props), contents = /* @__PURE__ */ jsx(StackZIndexContext, { zIndex: resolveViewZIndex(zIndex), children: /* @__PURE__ */ jsx(
111
- Animate,
112
- {
113
- type: "presence",
114
- present: !!context.open,
115
- keepChildrenMounted: !!keepMounted,
116
- onExitComplete: handleExitComplete,
117
- passThrough: isAdapted,
118
- children
119
- }
120
- ) }), framedContents = isFullyHidden && !keepMounted && !isAdapted ? null : /* @__PURE__ */ jsx(LayoutMeasurementController, { disable: !context.open, children: /* @__PURE__ */ jsx(
121
- DialogPortalFrame,
122
- {
123
- ref,
124
- ...isWeb && context.open && {
125
- "aria-modal": !0
126
- },
127
- pointerEvents: context.open ? "auto" : "none",
128
- ...frameProps,
129
- className: "_no_backdrop " + (frameProps.className || ""),
130
- children: contents
131
- }
132
- ) });
133
- return isWeb ? /* @__PURE__ */ jsx(
134
- Portal,
135
- {
136
- zIndex,
137
- stackZIndex: 1e5,
138
- passThrough: isAdapted,
139
- children: /* @__PURE__ */ jsx(PassthroughTheme, { passThrough: isAdapted, children: framedContents })
140
- }
141
- ) : isAdapted ? framedContents : /* @__PURE__ */ jsx(DialogPortalItem, { context, children: framedContents });
142
- }
143
- ), PassthroughTheme = ({
144
- children,
145
- passThrough
146
- }) => {
147
- const themeName = useThemeName();
148
- return /* @__PURE__ */ jsx(Theme, { passThrough, name: themeName, forceClassName: !0, children });
149
- }, OVERLAY_NAME = "DialogOverlay", DialogOverlayFrame = styled(YStack, {
150
- name: OVERLAY_NAME,
151
- variants: {
152
- open: {
153
- true: {
154
- pointerEvents: "auto"
155
- },
156
- false: {
157
- pointerEvents: "none"
158
- }
159
- },
160
- unstyled: {
161
- false: {
162
- fullscreen: !0,
163
- position: "absolute",
164
- backgroundColor: "$background",
165
- zIndex: 99999,
166
- pointerEvents: "auto"
167
- }
168
- }
169
- },
170
- defaultVariants: {
171
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
172
- }
173
- }), DialogOverlay = DialogOverlayFrame.styleable(
174
- function({ scope, ...props }, forwardedRef) {
175
- const context = useDialogContext(scope), { forceMount = context.forceMount, ...overlayProps } = props, isAdapted = useAdaptIsActive(context.adaptScope);
176
- return !forceMount && (!context.modal || isAdapted) ? null : /* @__PURE__ */ jsx(
177
- DialogOverlayFrame,
178
- {
179
- "data-state": getState(context.open),
180
- pointerEvents: context.open ? "auto" : "none",
181
- ...overlayProps,
182
- ref: forwardedRef
183
- }
184
- );
185
- }
186
- ), CONTENT_NAME = "DialogContent", DialogContentFrame = styled(ThemeableStack, {
187
- name: CONTENT_NAME,
188
- variants: {
189
- size: {
190
- "...size": (val, extras) => ({})
191
- },
192
- unstyled: {
193
- false: {
194
- position: "relative",
195
- backgroundColor: "$background",
196
- borderWidth: 1,
197
- borderColor: "$borderColor",
198
- padding: "$true",
199
- borderRadius: "$true",
200
- elevate: !0,
201
- zIndex: 1e5,
202
- // Ensure content receives pointer events (fixes React 19 + display:contents inheritance)
203
- pointerEvents: "auto"
204
- }
205
- }
206
- },
207
- defaultVariants: {
208
- size: "$true",
209
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
210
- }
211
- }), DialogContent = DialogContentFrame.styleable(
212
- function({ scope, ...props }, forwardedRef) {
213
- const context = useDialogContext(scope), contents = /* @__PURE__ */ jsx(Fragment, { children: context.modal ? /* @__PURE__ */ jsx(DialogContentModal, { context, ...props, ref: forwardedRef }) : /* @__PURE__ */ jsx(DialogContentNonModal, { context, ...props, ref: forwardedRef }) });
214
- return !isWeb || context.disableRemoveScroll ? contents : /* @__PURE__ */ jsx(RemoveScroll, { enabled: context.open, children: /* @__PURE__ */ jsx("div", { "data-remove-scroll-container": !0, className: "_dsp_contents", children: contents }) });
215
- }
216
- ), DialogContentModal = React.forwardRef(
217
- ({ children, context, ...props }, forwardedRef) => {
218
- const contentRef = React.useRef(null), composedRefs = useComposedRefs(forwardedRef, context.contentRef, contentRef);
219
- return /* @__PURE__ */ jsx(
220
- DialogContentImpl,
221
- {
222
- ...props,
223
- context,
224
- ref: composedRefs,
225
- trapFocus: context.open,
226
- disableOutsidePointerEvents: !0,
227
- onCloseAutoFocus: composeEventHandlers(props.onCloseAutoFocus, (event) => {
228
- event.preventDefault(), context.triggerRef.current?.focus();
229
- }),
230
- onPointerDownOutside: composeEventHandlers(
231
- props.onPointerDownOutside,
232
- (event) => {
233
- const originalEvent = event.detail.originalEvent, ctrlLeftClick = originalEvent.button === 0 && originalEvent.ctrlKey === !0;
234
- (originalEvent.button === 2 || ctrlLeftClick) && event.preventDefault();
235
- }
236
- ),
237
- onFocusOutside: composeEventHandlers(
238
- props.onFocusOutside,
239
- (event) => event.preventDefault()
240
- ),
241
- ...!props.unstyled && {
242
- outlineStyle: "none"
243
- },
244
- children
245
- }
246
- );
247
- }
248
- ), DialogContentNonModal = React.forwardRef(
249
- (props, forwardedRef) => {
250
- const hasInteractedOutsideRef = React.useRef(!1);
251
- return /* @__PURE__ */ jsx(
252
- DialogContentImpl,
253
- {
254
- ...props,
255
- ref: forwardedRef,
256
- trapFocus: !1,
257
- disableOutsidePointerEvents: !1,
258
- onCloseAutoFocus: (event) => {
259
- props.onCloseAutoFocus?.(event), event.defaultPrevented || (hasInteractedOutsideRef.current || props.context.triggerRef.current?.focus(), event.preventDefault()), hasInteractedOutsideRef.current = !1;
260
- },
261
- onInteractOutside: (event) => {
262
- props.onInteractOutside?.(event), event.defaultPrevented || (hasInteractedOutsideRef.current = !0);
263
- const target = event.target, trigger = props.context.triggerRef.current;
264
- if (!(trigger instanceof HTMLElement)) return;
265
- trigger.contains(target) && event.preventDefault();
266
- }
267
- }
268
- );
269
- }
270
- ), DialogContentImpl = React.forwardRef(
271
- (props, forwardedRef) => {
272
- const {
273
- trapFocus,
274
- onOpenAutoFocus,
275
- onCloseAutoFocus,
276
- disableOutsidePointerEvents,
277
- onEscapeKeyDown,
278
- onPointerDownOutside,
279
- onFocusOutside,
280
- onInteractOutside,
281
- context,
282
- ...contentProps
283
- } = props, contentRef = React.useRef(null), composedRefs = useComposedRefs(forwardedRef, contentRef);
284
- if (useAdaptIsActive(context.adaptScope))
285
- return !isWeb && !context.open ? null : /* @__PURE__ */ jsx(DialogPortalItem, { context, children: contentProps.children });
286
- const contents = /* @__PURE__ */ jsx(
287
- DialogContentFrame,
288
- {
289
- ref: composedRefs,
290
- id: context.contentId,
291
- role: "dialog",
292
- "aria-modal": context.modal,
293
- "aria-describedby": context.descriptionId,
294
- "aria-labelledby": context.titleId,
295
- "data-state": getState(context.open),
296
- pointerEvents: context.open ? "auto" : "none",
297
- ...contentProps
298
- }
299
- );
300
- return isWeb ? /* @__PURE__ */ jsxs(Fragment, { children: [
301
- /* @__PURE__ */ jsx(
302
- Dismissable,
303
- {
304
- disableOutsidePointerEvents: context.open && disableOutsidePointerEvents,
305
- forceUnmount: !context.open,
306
- onEscapeKeyDown,
307
- onPointerDownOutside,
308
- onFocusOutside,
309
- onInteractOutside,
310
- onDismiss: () => context?.onOpenChange?.(!1),
311
- children: /* @__PURE__ */ jsx(
312
- FocusScope,
313
- {
314
- loop: !0,
315
- enabled: context.open,
316
- trapped: trapFocus,
317
- onMountAutoFocus: onOpenAutoFocus,
318
- forceUnmount: !context.open,
319
- onUnmountAutoFocus: onCloseAutoFocus,
320
- children: contents
321
- }
322
- )
323
- }
324
- ),
325
- process.env.NODE_ENV === "development" && /* @__PURE__ */ jsxs(Fragment, { children: [
326
- /* @__PURE__ */ jsx(TitleWarning, { titleId: context.titleId }),
327
- /* @__PURE__ */ jsx(
328
- DescriptionWarning,
329
- {
330
- contentRef,
331
- descriptionId: context.descriptionId
332
- }
333
- )
334
- ] })
335
- ] }) : contents;
336
- }
337
- ), DialogTitleFrame = styled(H2, {
338
- name: "DialogTitle"
339
- }), DialogTitle = DialogTitleFrame.styleable(
340
- function(props, forwardedRef) {
341
- const { scope, ...titleProps } = props, context = useDialogContext(scope);
342
- return /* @__PURE__ */ jsx(DialogTitleFrame, { id: context.titleId, ...titleProps, ref: forwardedRef });
343
- }
344
- ), DialogDescriptionFrame = styled(Paragraph, {
345
- name: "DialogDescription"
346
- }), DialogDescription = DialogDescriptionFrame.styleable(
347
- function(props, forwardedRef) {
348
- const { scope, ...descriptionProps } = props, context = useDialogContext(scope);
349
- return /* @__PURE__ */ jsx(
350
- DialogDescriptionFrame,
351
- {
352
- id: context.descriptionId,
353
- ...descriptionProps,
354
- ref: forwardedRef
355
- }
356
- );
357
- }
358
- ), CLOSE_NAME = "DialogClose", DialogCloseFrame = styled(View, {
359
- name: CLOSE_NAME,
360
- render: "button"
361
- }), DialogClose = DialogCloseFrame.styleable(
362
- (props, forwardedRef) => {
363
- const { scope, displayWhenAdapted, ...closeProps } = props, context = useDialogContext(scope), isAdapted = useAdaptIsActive(context.adaptScope), isInsideButton = React.useContext(ButtonNestingContext);
364
- return isAdapted && !displayWhenAdapted ? null : /* @__PURE__ */ jsx(
365
- DialogCloseFrame,
366
- {
367
- "aria-label": "Dialog Close",
368
- render: isInsideButton ? "span" : "button",
369
- ...closeProps,
370
- ref: forwardedRef,
371
- onPress: composeEventHandlers(props.onPress, () => {
372
- context.onOpenChange(!1);
373
- })
374
- }
375
- );
376
- }
377
- );
378
- function getState(open) {
379
- return open ? "open" : "closed";
380
- }
381
- const TITLE_WARNING_NAME = "DialogTitleWarning", [DialogWarningProvider, useWarningContext] = createContext(TITLE_WARNING_NAME, {
382
- contentName: CONTENT_NAME,
383
- titleName: "DialogTitle",
384
- docsSlug: "dialog"
385
- }), TitleWarning = ({ titleId }) => {
386
- if (process.env.NODE_ENV === "development") {
387
- const titleWarningContext = useWarningContext(TITLE_WARNING_NAME), MESSAGE = `\`${titleWarningContext.contentName}\` wants a \`${titleWarningContext.titleName}\` to be accessible. If you want to hide the \`${titleWarningContext.titleName}\`, wrap it with <VisuallyHidden />.`;
388
- React.useEffect(() => {
389
- isWeb && titleId && (document.getElementById(titleId) || console.warn(MESSAGE));
390
- }, [MESSAGE, titleId]);
391
- }
392
- return null;
393
- }, DESCRIPTION_WARNING_NAME = "DialogDescriptionWarning", DescriptionWarning = ({
394
- contentRef,
395
- descriptionId
396
- }) => {
397
- if (process.env.NODE_ENV === "development") {
398
- const MESSAGE = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${useWarningContext(DESCRIPTION_WARNING_NAME).contentName}}.`;
399
- React.useEffect(() => {
400
- if (!isWeb) return;
401
- const contentNode = contentRef.current;
402
- if (!(contentNode instanceof HTMLElement))
403
- return;
404
- const describedById = contentNode.getAttribute("aria-describedby");
405
- descriptionId && describedById && (document.getElementById(descriptionId) || console.warn(MESSAGE));
406
- }, [MESSAGE, contentRef, descriptionId]);
407
- }
408
- return null;
409
- }, Dialog = withStaticProperties(
410
- React.forwardRef(
411
- function(props, ref) {
412
- const {
413
- scope = "",
414
- children,
415
- open: openProp,
416
- defaultOpen = !1,
417
- onOpenChange,
418
- modal = !0,
419
- keepChildrenMounted,
420
- disableRemoveScroll = !1
421
- } = props, baseId = React.useId(), dialogId = `Dialog-${scope}-${baseId}`, contentId = `${dialogId}-content`, titleId = `${dialogId}-title`, descriptionId = `${dialogId}-description`, triggerRef = React.useRef(null), contentRef = React.useRef(null), [open, setOpen] = useControllableState({
422
- prop: openProp,
423
- defaultProp: defaultOpen,
424
- onChange: onOpenChange
425
- }), onOpenToggle = React.useCallback(() => {
426
- setOpen((prevOpen) => !prevOpen);
427
- }, [setOpen]), adaptScope = `DialogAdapt${scope}`, context = {
428
- dialogScope: scope,
429
- adaptScope,
430
- triggerRef,
431
- contentRef,
432
- contentId,
433
- titleId,
434
- descriptionId,
435
- open,
436
- onOpenChange: setOpen,
437
- onOpenToggle,
438
- modal,
439
- keepChildrenMounted,
440
- disableRemoveScroll
441
- };
442
- return React.useImperativeHandle(
443
- ref,
444
- () => ({
445
- open: setOpen
446
- }),
447
- [setOpen]
448
- ), /* @__PURE__ */ jsx(
449
- AdaptParent,
450
- {
451
- scope: adaptScope,
452
- portal: {
453
- forwardProps: props
454
- },
455
- children: /* @__PURE__ */ jsx(DialogProvider, { scope, ...context, children: /* @__PURE__ */ jsx(DialogSheetController, { onOpenChange: setOpen, scope, children }) })
456
- }
457
- );
458
- }
459
- ),
460
- {
461
- Trigger: DialogTrigger,
462
- Portal: DialogPortal,
463
- Overlay: DialogOverlay,
464
- Content: DialogContent,
465
- Title: DialogTitle,
466
- Description: DialogDescription,
467
- Close: DialogClose,
468
- FocusScope: FocusScopeController,
469
- Adapt
470
- }
471
- );
472
- const DialogSheetController = (props) => {
473
- const context = useDialogContext(props.scope), isAdapted = useAdaptIsActive(context.adaptScope);
474
- return /* @__PURE__ */ jsx(
475
- SheetController,
476
- {
477
- onOpenChange: (val) => {
478
- isAdapted && props.onOpenChange?.(val);
479
- },
480
- open: context.open,
481
- hidden: !isAdapted,
482
- children: props.children
483
- }
484
- );
485
- };
486
- export {
487
- Dialog,
488
- DialogClose,
489
- DialogContent,
490
- DialogContext,
491
- DialogDescription,
492
- DialogOverlay,
493
- DialogOverlayFrame,
494
- DialogPortal,
495
- DialogPortalFrame,
496
- DialogProvider,
497
- DialogTitle,
498
- DialogTrigger,
499
- DialogWarningProvider,
500
- useDialogContext
501
- };
502
- //# sourceMappingURL=Dialog.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/Dialog.tsx"],
4
- "mappings": "AAAA;AAAA,EACE;AAAA,EACA;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