@tactics/toddle-styleguide 5.4.43 → 5.4.45

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tactics/toddle-styleguide",
3
- "version": "5.4.43",
3
+ "version": "5.4.45",
4
4
  "main": "index.tsx",
5
5
  "types": "index.d.ts",
6
6
  "prepublish": "tsc",
@@ -28,10 +28,10 @@ type PopOverActionProps = {
28
28
  };
29
29
 
30
30
  export const PopOverAction = ({
31
- isVisible,
32
- children,
33
- touchBackDrop,
34
- }: PopOverActionProps) => {
31
+ isVisible,
32
+ children,
33
+ touchBackDrop,
34
+ }: PopOverActionProps) => {
35
35
  const [windowHeight, setWindowHeight] = useState(
36
36
  Dimensions.get('window').height
37
37
  );
@@ -54,6 +54,12 @@ export const PopOverAction = ({
54
54
  updated[index] = layout;
55
55
  return updated;
56
56
  });
57
+
58
+ // Ensure element size is known for the currently visible child so the animation can open
59
+ // even if Swipe never emits onIndexChange (e.g., only one child or Swipe not implemented yet).
60
+ if (index === currentChildIndex) {
61
+ setElementSize({ width: layout.width, height: layout.height });
62
+ }
57
63
  };
58
64
 
59
65
  function renderChildrenWithLayout(