aboutsummaryrefslogtreecommitdiffstats
path: root/apps/mobile/components/bookmarks/BookmarkTextMarkdown.tsx
blob: 80ea007c9be236b2499cc5ca4fd745b3ff51958f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
import Markdown from "react-native-markdown-display";
import { TailwindResolver } from "@/components/TailwindResolver";

export default function BookmarkTextMarkdown({ text }: { text: string }) {
  return (
    <TailwindResolver
      className="text-foreground"
      comp={(styles) => (
        <Markdown
          style={{
            text: {
              color: styles?.color?.toString(),
            },
          }}
        >
          {text}
        </Markdown>
      )}
    />
  );
}