|
1 | | -diff --git a/lib/commonjs/toast.js b/lib/commonjs/toast.js |
2 | | -index 121816a452339c1088aeba87928ff63a0bdacca5..47e74bce47323201f0bb4e5ed9dc55b373c07b97 100644 |
3 | | ---- a/lib/commonjs/toast.js |
4 | | -+++ b/lib/commonjs/toast.js |
5 | | -@@ -264,7 +264,7 @@ const Toast = exports.Toast = /*#__PURE__*/React.forwardRef(({ |
| 1 | +diff --git a/lib/module/toast.js b/lib/module/toast.js |
| 2 | +index be089f3ff23017a6844e2010cedc547729e198aa..c2dd0fa2df93f929c33bf2bcc3e6f921941fa006 100644 |
| 3 | +--- a/lib/module/toast.js |
| 4 | ++++ b/lib/module/toast.js |
| 5 | +@@ -1,8 +1,8 @@ |
| 6 | + "use strict"; |
| 7 | + |
| 8 | + import * as React from 'react'; |
| 9 | +-import { ActivityIndicator, Pressable, Text, View } from 'react-native'; |
| 10 | +-import Animated, { useAnimatedStyle, useSharedValue, withRepeat, withTiming } from 'react-native-reanimated'; |
| 11 | ++import { ActivityIndicator, Pressable, Text, View, Platform } from 'react-native'; |
| 12 | ++import Animated, { useAnimatedStyle, useSharedValue, withRepeat, withTiming, FadeOut } from 'react-native-reanimated'; |
| 13 | + import { ANIMATION_DURATION, useToastLayoutAnimations } from "./animations.js"; |
| 14 | + import { toastDefaultValues } from "./constants.js"; |
| 15 | + import { useToastContext } from "./context.js"; |
| 16 | +@@ -258,7 +258,10 @@ export const Toast = /*#__PURE__*/React.forwardRef(({ |
6 | 17 | ...toastSwipeHandlerProps, |
7 | | - children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, { |
| 18 | + children: /*#__PURE__*/_jsx(Animated.View, { |
8 | 19 | entering: entering, |
9 | 20 | - exiting: exiting, |
10 | | -+ exiting: _reactNative.Platform.OS === 'android' ? undefined : exiting, |
| 21 | ++ exiting: Platform.select({ |
| 22 | ++ android: undefined, |
| 23 | ++ default: exiting |
| 24 | ++ }), |
11 | 25 | children: jsx |
12 | 26 | }) |
13 | 27 | }); |
14 | | -@@ -274,7 +274,7 @@ const Toast = exports.Toast = /*#__PURE__*/React.forwardRef(({ |
15 | | - children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, { |
| 28 | +@@ -268,7 +271,10 @@ export const Toast = /*#__PURE__*/React.forwardRef(({ |
| 29 | + children: /*#__PURE__*/_jsx(Animated.View, { |
16 | 30 | style: [unstyled ? undefined : elevationStyle, defaultStyles.toast, toastStyleCtx, styles?.toast, style, wiggleAnimationStyle], |
17 | 31 | entering: entering, |
18 | 32 | - exiting: exiting, |
19 | | -+ exiting: _reactNative.Platform.OS === 'android' ? undefined : exiting, |
20 | | - children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, { |
| 33 | ++ exiting: Platform.select({ |
| 34 | ++ android: undefined, |
| 35 | ++ default: exiting |
| 36 | ++ }), |
| 37 | + children: /*#__PURE__*/_jsxs(View, { |
21 | 38 | style: [defaultStyles.toastContent, toastContentStyleCtx, styles?.toastContent], |
22 | | - children: [promiseOptions || variant === 'loading' ? 'loading' in icons ? icons.loading : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ActivityIndicator, {}) : icon ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, { |
| 39 | + children: [promiseOptions || variant === 'loading' ? 'loading' in icons ? icons.loading : /*#__PURE__*/_jsx(ActivityIndicator, {}) : icon ? /*#__PURE__*/_jsx(View, { |
0 commit comments