@momo-kits/foundation 0.158.1-beta.3 → 0.158.1-beta.4

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.
@@ -42,13 +42,16 @@ const Modal: React.FC<ModalParams> = props => {
42
42
  * Fire auto_popup_displayed tracking event on mount
43
43
  */
44
44
  useEffect(() => {
45
- context.autoTracking({
46
- componentName: 'Modal',
47
- description,
48
- title,
45
+ navigator?.maxApi?.getDataObserver?.('current_screen', (curScreen: any) => {
46
+ context.autoTracking({
47
+ ...context,
48
+ screenName: curScreen?.screenName,
49
+ componentName: 'Modal',
50
+ description,
51
+ title,
52
+ });
49
53
  });
50
- // eslint-disable-next-line react-hooks/exhaustive-deps
51
- }, []);
54
+ }, [context, description, navigator?.maxApi, title]);
52
55
 
53
56
  const opacity = useRef(new Animated.Value(0)).current;
54
57
  const scale = useRef(new Animated.Value(0.8)).current;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@momo-kits/foundation",
3
- "version": "0.158.1-beta.3",
3
+ "version": "0.158.1-beta.4",
4
4
  "description": "React Native Component Kits",
5
5
  "main": "index.ts",
6
6
  "scripts": {},