@momo-kits/foundation 0.92.29-optimize.14 → 0.92.29-optimize.16

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.
@@ -297,7 +297,6 @@ const HeaderRightAction: React.FC<any> = ({children, ...restProps}) => {
297
297
  const HeaderToolkitAction: React.FC<any> = ({
298
298
  tintColor,
299
299
  pinnedTool,
300
- runtimeTools = [],
301
300
  preventClose,
302
301
  }) => {
303
302
  const {navigator} = useContext(ApplicationContext);
@@ -334,13 +333,15 @@ const HeaderToolkitAction: React.FC<any> = ({
334
333
  const onMore = () => {
335
334
  onAction?.('onMore');
336
335
  navigator?.maxApi?.dispatchFunction?.(
337
- 'showTools',
338
- {runtimeTools},
339
- (res: {item: {action?: string; key: string}}) => {
340
- const {item} = res;
341
- navigator?.toolkitCallback?.(item.key);
342
- getToolkitConfig();
343
- }
336
+ 'showToolkit',
337
+ {
338
+ tools: miniContext?.toolkitConfig?.oldTools ?? [
339
+ 'addFavorite',
340
+ 'addShortcut',
341
+ 'share',
342
+ ],
343
+ },
344
+ () => {}
344
345
  );
345
346
  };
346
347
 
@@ -385,7 +386,7 @@ const HeaderToolkitAction: React.FC<any> = ({
385
386
  onPress={() => {
386
387
  navigator?.maxApi?.dispatchFunction?.(
387
388
  'onToolAction',
388
- [pinTool?.key],
389
+ {item: pinTool},
389
390
  () => {
390
391
  getToolkitConfig();
391
392
  }
@@ -1,5 +1,5 @@
1
1
  import React, {FC, useContext, useRef, useState} from 'react';
2
- import {Animated, View} from 'react-native';
2
+ import {Animated, Dimensions, View} from 'react-native';
3
3
  import {ScrollIndicatorProps} from './types';
4
4
  import styles from './styles';
5
5
  import {ApplicationContext} from '../Application';
@@ -42,7 +42,7 @@ const PaginationScroll: FC<ScrollIndicatorProps> = ({
42
42
  },
43
43
  },
44
44
  ],
45
- {useNativeDriver: true},
45
+ {useNativeDriver: true}
46
46
  )}
47
47
  alwaysBounceHorizontal={false}
48
48
  showsHorizontalScrollIndicator={false}
@@ -80,7 +80,7 @@ const PaginationScroll: FC<ScrollIndicatorProps> = ({
80
80
  return (
81
81
  <View style={[style, styles.scrollContainer]}>
82
82
  {renderScrollView()}
83
- {renderIndicator()}
83
+ {scrollContentWidth > scrollViewWidth && renderIndicator()}
84
84
  </View>
85
85
  );
86
86
  };
@@ -29,7 +29,6 @@ export default StyleSheet.create({
29
29
  justifyContent: 'center',
30
30
  },
31
31
  scrollContainer: {
32
- alignItems: 'center',
33
32
  width: '100%',
34
33
  },
35
34
  scrollView: {
@@ -42,6 +41,7 @@ export default StyleSheet.create({
42
41
  borderRadius: Radius.XS,
43
42
  },
44
43
  indicatorContainer: {
44
+ alignSelf: 'center',
45
45
  width: 72,
46
46
  height: 4,
47
47
  borderRadius: Radius.XS,
@@ -195,7 +195,7 @@ const PopupNotify: React.FC<PopupNotifyProps> = ({
195
195
  ]}>
196
196
  {!!image && <Image source={{uri: image}} style={styles.image} />}
197
197
  <View style={styles.content}>
198
- <Text typography={'header_default_bold'} numberOfLines={1}>
198
+ <Text typography={'header_default_bold'} numberOfLines={3}>
199
199
  {title}
200
200
  </Text>
201
201
  <Description style={[styles.description, descriptionStyle]}>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@momo-kits/foundation",
3
- "version": "0.92.29-optimize.14",
3
+ "version": "0.92.29-optimize.16",
4
4
  "description": "React Native Component Kits",
5
5
  "main": "index.ts",
6
6
  "scripts": {},