This commit is contained in:
KoalaSat 2023-01-25 19:52:22 +01:00
parent c0967558d4
commit f1524e14d9
No known key found for this signature in database
GPG Key ID: 2F7F61C6146AB157
8 changed files with 24 additions and 7 deletions

View File

@ -164,7 +164,14 @@ export const NoteCard: React.FC<NoteCardProps> = ({
numberOfLines={numberOfLines}
/>
)}
{showRepostPreview && repost && <NoteCard note={repost} showAction={false} showPreview={showPreview}/>}
{showRepostPreview && repost && (
<NoteCard
note={repost}
showAction={false}
showPreview={showPreview}
showRepostPreview={false}
/>
)}
</Card.Content>
</>
)

View File

@ -2,6 +2,7 @@ import React, { useEffect, useState } from 'react'
import { QuickSQLiteConnection } from 'react-native-quick-sqlite'
import { initDatabase } from '../Functions/DatabaseFunctions'
import SInfo from 'react-native-sensitive-info'
import { Linking } from 'react-native'
export interface AppContextProps {
init: () => void
@ -28,6 +29,7 @@ export const AppContextProvider = ({ children }: AppContextProviderProps): JSX.E
setDatabase(db)
SInfo.getItem('publicKey', {}).then((value) => {
setLoadingDb(false)
// Linking.addEventListener('url', this.handleOpenURL);
})
}

View File

@ -139,6 +139,8 @@
"notifications": {
"add": "Relay conectado",
"remove": "Relay borrado",
"active": "Relay acivado.",
"desactive": "Relay desactivado.",
"badFormat": "La URL del relay no tiene el formato adecuado."
}
},

View File

@ -138,6 +138,8 @@
"notifications": {
"add": "Relay connected.",
"remove": "Relay removed.",
"active": "Relay acivado.",
"desactive": "Relay desactivado.",
"badFormat": "Relay URL has a bad format."
}
},

View File

@ -81,6 +81,7 @@ export const AboutPage: React.FC = () => {
data={items}
renderItem={renderItem}
/>
// DeviceInfo.getVersion()
)
}

View File

@ -227,7 +227,7 @@ export const ContactsFeed: React.FC = () => {
ItemSeparatorComponent={Divider}
showsVerticalScrollIndicator={false}
/>
{following.length >= 10 && <ActivityIndicator animating={true} />}
{pageSize < following.length && <ActivityIndicator animating={true} />}
</View>
</ScrollView>
) : (
@ -265,7 +265,7 @@ export const ContactsFeed: React.FC = () => {
showsVerticalScrollIndicator={false}
/>
</View>
{followers.length >= 10 && <ActivityIndicator animating={true} />}
{pageSize < followers.length && <ActivityIndicator animating={true} />}
</ScrollView>
) : (
<View style={styles.blank}>

View File

@ -23,9 +23,12 @@ export const ProfileLoadPage: React.FC = () => {
useFocusEffect(
React.useCallback(() => {
if (publicKey && relayPoolReady) loadMeta()
if (publicKey && relayPoolReady) {
loadMeta()
loadPets()
}
return () => relayPool?.unsubscribe(['profile-load-notes'])
return () => relayPool?.unsubscribe(['profile-load-notes', 'profile-load-meta-pets'])
}, []),
)
@ -70,7 +73,7 @@ export const ProfileLoadPage: React.FC = () => {
{
kinds: [Kind.Text],
authors,
since: getUnixTime(new Date()) - 86400,
since: getUnixTime(new Date()) - 43200,
},
{
kinds: [Kind.Metadata],

View File

@ -108,7 +108,7 @@ export const RelaysPage: React.FC = () => {
return (
<View style={styles.container}>
<ScrollView horizontal={false}>
{myRelays && (
{myRelays.length > 0 && (
<>
<Text style={styles.title} variant='titleMedium'>
{t('relaysPage.myList')}