allow scrolling for displaying more search results #110
3 changed files with 6 additions and 10 deletions
|
@ -134,9 +134,7 @@ const Constants = {
|
||||||
|
|
||||||
ORDER_BY_EFFECTIVE_AMOUNT: 'effective_amount',
|
ORDER_BY_EFFECTIVE_AMOUNT: 'effective_amount',
|
||||||
|
|
||||||
DEFAULT_PAGE_SIZE: 10,
|
DEFAULT_PAGE_SIZE: 20,
|
||||||
|
|
||||||
SEARCH_RESULTS_PAGE_SIZE: 25,
|
|
||||||
|
|
||||||
ALL_PLACEHOLDER: '_all',
|
ALL_PLACEHOLDER: '_all',
|
||||||
|
|
||||||
|
|
|
@ -24,17 +24,15 @@ const select = state => ({
|
||||||
isSearching: selectIsSearching(state),
|
isSearching: selectIsSearching(state),
|
||||||
query: selectSearchValue(state),
|
query: selectSearchValue(state),
|
||||||
resolvingUris: selectResolvingUris(state),
|
resolvingUris: selectResolvingUris(state),
|
||||||
uris: makeSelectSearchUris(makeSelectQueryWithOptions(null, Constants.SEARCH_RESULTS_PAGE_SIZE)(state))(state),
|
uris: makeSelectSearchUris(makeSelectQueryWithOptions(null, Constants.DEFAULT_PAGE_SIZE)(state))(state),
|
||||||
results: makeSelectResolvedSearchResults(makeSelectQueryWithOptions(null, Constants.SEARCH_RESULTS_PAGE_SIZE)(state))(
|
results: makeSelectResolvedSearchResults(makeSelectQueryWithOptions(null, Constants.DEFAULT_PAGE_SIZE)(state))(state),
|
||||||
state,
|
|
||||||
),
|
|
||||||
lastPageReached: makeSelectResolvedSearchResultsLastPageReached(
|
lastPageReached: makeSelectResolvedSearchResultsLastPageReached(
|
||||||
makeSelectQueryWithOptions(null, Constants.SEARCH_RESULTS_PAGE_SIZE)(state),
|
makeSelectQueryWithOptions(null, Constants.DEFAULT_PAGE_SIZE)(state),
|
||||||
)(state),
|
)(state),
|
||||||
});
|
});
|
||||||
|
|
||||||
const perform = dispatch => ({
|
const perform = dispatch => ({
|
||||||
search: (query, from) => dispatch(doResolvedSearch(query, Constants.SEARCH_RESULTS_PAGE_SIZE, from, false, {})),
|
search: (query, from) => dispatch(doResolvedSearch(query, Constants.DEFAULT_PAGE_SIZE, from, false, {})),
|
||||||
claimSearch: options => dispatch(doClaimSearch(options)),
|
claimSearch: options => dispatch(doClaimSearch(options)),
|
||||||
updateSearchQuery: query => dispatch(doUpdateSearchQuery(query)),
|
updateSearchQuery: query => dispatch(doUpdateSearchQuery(query)),
|
||||||
pushDrawerStack: () => dispatch(doPushDrawerStack(Constants.DRAWER_ROUTE_SEARCH)),
|
pushDrawerStack: () => dispatch(doPushDrawerStack(Constants.DRAWER_ROUTE_SEARCH)),
|
||||||
|
|
|
@ -243,7 +243,7 @@ class SearchPage extends React.PureComponent {
|
||||||
)}
|
)}
|
||||||
{this.state.currentFrom > 0 && isSearching && (
|
{this.state.currentFrom > 0 && isSearching && (
|
||||||
<View style={searchStyle.moreLoading}>
|
<View style={searchStyle.moreLoading}>
|
||||||
<ActivityIndicator size="small" coolor={Colors.NextLbryGreen} />
|
<ActivityIndicator size="small" color={Colors.NextLbryGreen} />
|
||||||
</View>
|
</View>
|
||||||
)}
|
)}
|
||||||
<FloatingWalletBalance navigation={navigation} />
|
<FloatingWalletBalance navigation={navigation} />
|
||||||
|
|
Loading…
Reference in a new issue