sailfork / t3code-github / apps/ mobile/ src/ components/ MediaSourceCaption.tsx

import { ScrollView } from "react-native";

import { AppText } from "./ui/AppText";

export function MediaSourceCaption(props: { readonly source: string | undefined }) {
  if (!props.source) return null;
  return (
    <ScrollView
      style={{ maxHeight: 88, flexGrow: 0 }}
      contentContainerStyle={{ paddingHorizontal: 16, paddingBottom: 8 }}
      nestedScrollEnabled
    >
      <AppText selectable className="text-xs text-white/70">
        {props.source}
      </AppText>
    </ScrollView>
  );
}