diff --git a/apps/mobile/app/components/list-items/headers/section-header.tsx b/apps/mobile/app/components/list-items/headers/section-header.tsx index 19c4ba1ca..543912b41 100644 --- a/apps/mobile/app/components/list-items/headers/section-header.tsx +++ b/apps/mobile/app/components/list-items/headers/section-header.tsx @@ -25,7 +25,7 @@ import { useIsCompactModeEnabled } from "../../../hooks/use-is-compact-mode-enab import { presentSheet } from "../../../services/event-manager"; import SettingsService from "../../../services/settings"; import { RouteName } from "../../../stores/use-navigation-store"; -import { ColorValues } from "../../../utils/colors"; +import { ColorValues, getContainerBorder } from "../../../utils/colors"; import { GROUP } from "../../../utils/constants"; import { SIZE } from "../../../utils/size"; import Sort from "../../sheets/sort"; @@ -80,7 +80,8 @@ export const SectionHeader = React.memo< backgroundColor: colors.secondary.background, alignSelf: "center", borderRadius: 5, - marginVertical: 5 + marginVertical: 5, + ...getContainerBorder(colors.secondary.background, 0.8) }} > { width: 40 * fontScale, backgroundColor: messageBoardState.type === "error" - ? hexToRGBA(colors.static.red, 0.15) + ? hexToRGBA(colors.error.accent, 0.15) : hexToRGBA(color, 0.15), height: 40 * fontScale, borderRadius: 100, alignItems: "center", - justifyContent: "center" + justifyContent: "center", + ...getContainerBorder( + messageBoardState.type === "error" + ? colors.error.accent + : color || colors.primary.accent, + 0.4 + ) }} > . +*/ +import { useThemeColors } from "@notesnook/theme"; +import React from "react"; +import { ColorValue, TextProps } from "react-native"; +import Icon from "react-native-vector-icons/MaterialCommunityIcons"; +import { SIZE } from "../../../utils/size"; + +export interface IconProps extends TextProps { + /** + * Size of the icon, can also be passed as fontSize in the style object. + * + * @default 12 + */ + size?: number | undefined; + + /** + * Name of the icon to show + * + * See Icon Explorer app + * {@link https://github.com/oblador/react-native-vector-icons/tree/master/Examples/IconExplorer} + */ + name: string; + + /** + * Color of the icon + * + */ + color?: ColorValue | number | undefined; +} + +export default function AppIcon(props: IconProps) { + const { colors } = useThemeColors(); + return ( + + ); +} diff --git a/apps/mobile/app/components/ui/pressable/index.tsx b/apps/mobile/app/components/ui/pressable/index.tsx index 04268e58e..5a9363203 100644 --- a/apps/mobile/app/components/ui/pressable/index.tsx +++ b/apps/mobile/app/components/ui/pressable/index.tsx @@ -142,8 +142,16 @@ const buttonTypes = ( text: text || colors.primary.accentForeground, selected: accent || colors.primary.accent, borderWidth: 0.8, - borderColor: getColorLinearShade(colors.primary.accent, 0.3, false), - borderSelectedColor: getColorLinearShade(colors.primary.accent, 0.3, false) + borderColor: getColorLinearShade( + accent || colors.primary.accent, + 0.3, + false + ), + borderSelectedColor: getColorLinearShade( + accent || colors.primary.accent, + 0.3, + false + ) }, inverted: { primary: colors.primary.background,