bits-ui 2.15.2 → 2.15.3
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.
|
@@ -39,7 +39,23 @@
|
|
|
39
39
|
onCloseAutoFocus: boxWith(() => onCloseAutoFocus),
|
|
40
40
|
});
|
|
41
41
|
|
|
42
|
-
const mergedProps = $derived(
|
|
42
|
+
const mergedProps = $derived(
|
|
43
|
+
mergeProps(restProps, contentState.props, {
|
|
44
|
+
side,
|
|
45
|
+
sideOffset,
|
|
46
|
+
align,
|
|
47
|
+
onOpenAutoFocus,
|
|
48
|
+
isValidEvent,
|
|
49
|
+
trapFocus,
|
|
50
|
+
loop,
|
|
51
|
+
id,
|
|
52
|
+
ref: contentState.opts.ref,
|
|
53
|
+
preventScroll,
|
|
54
|
+
onInteractOutside: handleInteractOutside,
|
|
55
|
+
onEscapeKeydown: handleEscapeKeydown,
|
|
56
|
+
shouldRender: contentState.shouldRender,
|
|
57
|
+
})
|
|
58
|
+
);
|
|
43
59
|
|
|
44
60
|
function handleInteractOutside(e: PointerEvent) {
|
|
45
61
|
onInteractOutside(e);
|
|
@@ -76,20 +92,7 @@
|
|
|
76
92
|
<PopperLayerForceMount
|
|
77
93
|
{...mergedProps}
|
|
78
94
|
{...contentState.popperProps}
|
|
79
|
-
ref={contentState.opts.ref}
|
|
80
|
-
{side}
|
|
81
|
-
{sideOffset}
|
|
82
|
-
{align}
|
|
83
95
|
enabled={contentState.parentMenu.opts.open.current}
|
|
84
|
-
{preventScroll}
|
|
85
|
-
onInteractOutside={handleInteractOutside}
|
|
86
|
-
onEscapeKeydown={handleEscapeKeydown}
|
|
87
|
-
{onOpenAutoFocus}
|
|
88
|
-
{isValidEvent}
|
|
89
|
-
{trapFocus}
|
|
90
|
-
{loop}
|
|
91
|
-
{id}
|
|
92
|
-
shouldRender={contentState.shouldRender}
|
|
93
96
|
>
|
|
94
97
|
{#snippet popper({ props, wrapperProps })}
|
|
95
98
|
{@const finalProps = mergeProps(props, {
|
|
@@ -110,20 +113,7 @@
|
|
|
110
113
|
<PopperLayer
|
|
111
114
|
{...mergedProps}
|
|
112
115
|
{...contentState.popperProps}
|
|
113
|
-
ref={contentState.opts.ref}
|
|
114
|
-
side="right"
|
|
115
|
-
sideOffset={2}
|
|
116
|
-
align="start"
|
|
117
116
|
open={contentState.parentMenu.opts.open.current}
|
|
118
|
-
{preventScroll}
|
|
119
|
-
onInteractOutside={handleInteractOutside}
|
|
120
|
-
onEscapeKeydown={handleEscapeKeydown}
|
|
121
|
-
{onOpenAutoFocus}
|
|
122
|
-
{isValidEvent}
|
|
123
|
-
{trapFocus}
|
|
124
|
-
{loop}
|
|
125
|
-
{id}
|
|
126
|
-
shouldRender={contentState.shouldRender}
|
|
127
117
|
>
|
|
128
118
|
{#snippet popper({ props, wrapperProps })}
|
|
129
119
|
{@const finalProps = mergeProps(props, {
|