* Add Report a Problem functionality * update cache pinned SHA version from 4.0.2 to 4.2.0 * Address feedback * Fix tests * Fix some issues and update kotlin coroutines version * Fix delete file for iOS * Bump 1 more version for coroutines * Use rxjava instead of kotlin coroutines to avoid security issue * Move path prefix to avoid test error * Address feedback * Address feedback * Address feedback * Use mailto on iOS * Fix tests related to button changes * Address feedback * Update icon and fix onboarding buttons * Fix test --------- Co-authored-by: Angelos Kyratzakos <angelos.kyratzakos@mattermost.com> Co-authored-by: Mattermost Build <build@mattermost.com>
38 lines
1.1 KiB
TypeScript
38 lines
1.1 KiB
TypeScript
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
|
// See LICENSE.txt for license information.
|
|
|
|
import React, {useMemo} from 'react';
|
|
import {View} from 'react-native';
|
|
|
|
import {useTheme} from '@context/theme';
|
|
import {makeStyleSheetFromTheme} from '@utils/theme';
|
|
|
|
const getStyleSheet = makeStyleSheetFromTheme((theme) => ({
|
|
divider: {
|
|
backgroundColor: theme.centerChannelColor,
|
|
height: 1,
|
|
opacity: 0.08,
|
|
},
|
|
}));
|
|
|
|
type Props = {
|
|
marginTop?: number;
|
|
marginBottom?: number;
|
|
marginLeft?: number;
|
|
marginRight?: number;
|
|
}
|
|
|
|
// Menu divider as per https://www.figma.com/design/ZV4NeVyUZoKfKRcRGyFJiT/Components---Mobile---Menu-Divider?node-id=1215-1535&t=qHU2DwCWm5cSbiq4-0
|
|
const MenuDivider = ({marginTop = 8, marginBottom = 8, marginLeft = 0, marginRight = 0}: Props) => {
|
|
const theme = useTheme();
|
|
const styles = getStyleSheet(theme);
|
|
|
|
const style = useMemo(() => [
|
|
styles.divider,
|
|
{marginTop, marginBottom, marginLeft, marginRight},
|
|
], [styles.divider, marginTop, marginBottom, marginLeft, marginRight]);
|
|
|
|
return (<View style={style}/>);
|
|
};
|
|
|
|
export default MenuDivider;
|