// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved. // See LICENSE.txt for license information. import React from 'react'; import {StyleSheet, View} from 'react-native'; import ErrorText from '@components/error_text'; type PostErrorProps = { errorLine?: string; errorExtra?: string; } const styles = StyleSheet.create({ errorContainerSplit: { paddingHorizontal: 15, flexDirection: 'row', justifyContent: 'space-between', width: '100%', }, errorContainer: { paddingHorizontal: 10, width: '100%', }, errorWrap: { flexShrink: 1, paddingRight: 20, }, errorWrapper: { alignItems: 'center', }, }); const PostError = ({errorLine, errorExtra}: PostErrorProps) => { return ( {Boolean(errorLine) && ( )} {Boolean(errorExtra) && ( )} ); }; export default PostError;