@fto-consult/expo-ui 8.24.2 → 8.24.3
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 +1 -1
- package/src/App.js +0 -1
- package/src/components/Table/index.js +4 -3
package/package.json
CHANGED
package/src/App.js
CHANGED
@@ -62,8 +62,8 @@ const TableComponent = React.forwardRef(({containerProps,tableHeadId,fixedHeader
|
|
62
62
|
const listRef = React.useRef(null),scrollViewRef = React.useRef(null),headerScrollViewRef = React.useRef(null);
|
63
63
|
const layoutRef = React.useRef({});
|
64
64
|
const {testID,withDatagridContext,getRowByIndex,itemsChanged,hasFooters:stateHasFooters,bordered,totalWidths,keyExtractor,items,data} = useTable();
|
65
|
-
const hasData = !!Object.size(
|
66
|
-
const emptyData = !hasData && renderListContent === false ?null : typeof renderEmpty =='function' ? renderEmpty() : null;
|
65
|
+
const hasData = !!Object.size(items,true);
|
66
|
+
const emptyData = !hasData && (renderListContent === false ?null : typeof renderEmpty =='function' ? renderEmpty() : null) || null;
|
67
67
|
const hasEmptyData = emptyData && React.isValidElement(emptyData);
|
68
68
|
const emptyContent = <View onRender={onComponentRender} testID={testID+"_EmptyData"} style={styles.hasNotData}>
|
69
69
|
{emptyData}
|
@@ -165,7 +165,8 @@ const TableComponent = React.forwardRef(({containerProps,tableHeadId,fixedHeader
|
|
165
165
|
</View>
|
166
166
|
</ScrollView>
|
167
167
|
</RNView>}
|
168
|
-
{hasEmptyData && isNative ? emptyContent :
|
168
|
+
{hasEmptyData && isNative ? emptyContent : null}
|
169
|
+
{<ScrollNative {...scrollViewProps} scrollEventThrottle = {scrollEventThrottle} horizontal contentContainerStyle={[scrollContentContainerStyle,scrollViewProps.contentContainerStyle,{height:'100%'}]} showsVerticalScrollIndicator={false}
|
169
170
|
onScroll = {getOnScrollCb([headerScrollViewRef,footerScrollViewRef],null,(args)=>{
|
170
171
|
const nativeEvent = args.nativeEvent;
|
171
172
|
if(absoluteScrollViewRef.current && absoluteScrollViewRef.current.checkVisibility){
|