tamagui 1.133.1 → 1.134.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.
- package/dist/native.js +23 -11
- package/dist/native.js.map +1 -1
- package/dist/test.native.js +16 -4
- package/dist/test.native.js.map +1 -1
- package/package.json +55 -55
package/dist/test.native.js
CHANGED
|
@@ -23786,7 +23786,8 @@ var require_Popper_native = __commonJS({
|
|
|
23786
23786
|
update: context.update,
|
|
23787
23787
|
context: context.context,
|
|
23788
23788
|
getFloatingProps: context.getFloatingProps,
|
|
23789
|
-
getReferenceProps: context.getReferenceProps
|
|
23789
|
+
getReferenceProps: context.getReferenceProps,
|
|
23790
|
+
open: context.open
|
|
23790
23791
|
};
|
|
23791
23792
|
}
|
|
23792
23793
|
var checkFloating = {
|
|
@@ -23855,9 +23856,11 @@ var require_Popper_native = __commonJS({
|
|
|
23855
23856
|
arrowStyle: middlewareData.arrow,
|
|
23856
23857
|
onArrowSize: setArrowSize,
|
|
23857
23858
|
hasFloating: (_middlewareData_checkFloating = middlewareData.checkFloating) === null || _middlewareData_checkFloating === void 0 ? void 0 : _middlewareData_checkFloating.hasFloating,
|
|
23859
|
+
open: !!open,
|
|
23858
23860
|
...floating
|
|
23859
23861
|
};
|
|
23860
23862
|
}, [
|
|
23863
|
+
open,
|
|
23861
23864
|
size2,
|
|
23862
23865
|
floating.x,
|
|
23863
23866
|
floating.y,
|
|
@@ -23929,7 +23932,7 @@ var require_Popper_native = __commonJS({
|
|
|
23929
23932
|
unstyled: process.env.TAMAGUI_HEADLESS === "1"
|
|
23930
23933
|
}
|
|
23931
23934
|
}), PopperContent = /* @__PURE__ */ React4.forwardRef(function(props, forwardedRef) {
|
|
23932
|
-
var { scope, enableAnimationForPositionChange, children, passThrough, ...rest } = props, { strategy, placement, refs, x, y, getFloatingProps, size: size2 } =
|
|
23935
|
+
var { scope, enableAnimationForPositionChange, children, passThrough, ...rest } = props, context = usePopperContext(scope), { strategy, placement, refs, x, y, getFloatingProps, size: size2, isPositioned } = context, contentRefs = (0, import_compose_refs.useComposedRefs)(refs.setFloating, forwardedRef), [needsMeasure, setNeedsMeasure] = React4.useState(enableAnimationForPositionChange);
|
|
23933
23936
|
(0, import_constants4.useIsomorphicLayoutEffect)(function() {
|
|
23934
23937
|
needsMeasure && x && y && setNeedsMeasure(!1);
|
|
23935
23938
|
}, [
|
|
@@ -23938,7 +23941,16 @@ var require_Popper_native = __commonJS({
|
|
|
23938
23941
|
x,
|
|
23939
23942
|
y
|
|
23940
23943
|
]);
|
|
23941
|
-
var hide2 = x === 0 && y === 0,
|
|
23944
|
+
var hide2 = x === 0 && y === 0, disableAnimationProp = (
|
|
23945
|
+
// if they want to animate also when re-positioning allow it
|
|
23946
|
+
enableAnimationForPositionChange === "even-when-repositioning" ? needsMeasure : !isPositioned || needsMeasure
|
|
23947
|
+
), [disableAnimation, setDisableAnimation] = React4.useState(disableAnimationProp);
|
|
23948
|
+
React4.useEffect(function() {
|
|
23949
|
+
setDisableAnimation(disableAnimationProp);
|
|
23950
|
+
}, [
|
|
23951
|
+
disableAnimationProp
|
|
23952
|
+
]);
|
|
23953
|
+
var frameProps = {
|
|
23942
23954
|
ref: contentRefs,
|
|
23943
23955
|
x: x || 0,
|
|
23944
23956
|
y: y || 0,
|
|
@@ -23948,7 +23960,7 @@ var require_Popper_native = __commonJS({
|
|
|
23948
23960
|
opacity: 1,
|
|
23949
23961
|
...enableAnimationForPositionChange && {
|
|
23950
23962
|
animation: rest.animation,
|
|
23951
|
-
animateOnly:
|
|
23963
|
+
animateOnly: disableAnimation ? [] : rest.animateOnly,
|
|
23952
23964
|
// apply animation but disable it on initial render to avoid animating from 0 to the first position
|
|
23953
23965
|
animatePresence: !1
|
|
23954
23966
|
},
|