1
0
mirror of https://github.com/tooot-app/app synced 2025-06-05 22:19:13 +02:00

Notifications working

This commit is contained in:
Zhiyuan Zheng
2020-10-24 18:07:09 +02:00
parent c8b40017d8
commit 8f6c5af0fd
9 changed files with 150 additions and 38 deletions

View File

@ -5,7 +5,7 @@ import HTML from 'react-native-render-html'
import relativeTime from 'src/utils/relativeTime'
export default function TootTimeline ({ item }) {
export default function TootTimeline ({ item, notification }) {
return (
<View style={styles.tootTimeline}>
<View style={styles.header}>
@ -36,7 +36,13 @@ export default function TootTimeline ({ item }) {
</View>
</View>
</View>
{item.content ? <HTML html={item.content} /> : <></>}
{notification ? (
<HTML html={item.status.content} />
) : item.content ? (
<HTML html={item.content} />
) : (
<></>
)}
</View>
)
}
@ -54,7 +60,8 @@ TootTimeline.propTypes = {
website: PropTypes.string
}),
content: PropTypes.string
}).isRequired
}).isRequired,
notification: PropTypes.bool
}
const styles = StyleSheet.create({