feat: add manual video tagging
This commit is contained in:
@@ -8,14 +8,17 @@ interface TranscriptPanelProps {
|
||||
open: boolean;
|
||||
onClose: () => void;
|
||||
transcript: VideoTranscript | null;
|
||||
contentTags?: string[];
|
||||
}
|
||||
|
||||
export function TranscriptPanel({
|
||||
open,
|
||||
onClose,
|
||||
transcript,
|
||||
contentTags,
|
||||
}: TranscriptPanelProps) {
|
||||
const [copiedIndex, setCopiedIndex] = useState<number | null>(null);
|
||||
const displayTags = contentTags ?? transcript?.content_tags ?? [];
|
||||
const [copiedAll, setCopiedAll] = useState(false);
|
||||
|
||||
if (!open) return null;
|
||||
@@ -94,9 +97,9 @@ export function TranscriptPanel({
|
||||
语言: {transcript.language}
|
||||
</p>
|
||||
)}
|
||||
{transcript.content_tags?.length > 0 && (
|
||||
{displayTags.length > 0 && (
|
||||
<div className="mt-2 flex flex-wrap gap-1.5">
|
||||
{transcript.content_tags.map((tag) => (
|
||||
{displayTags.map((tag) => (
|
||||
<span
|
||||
key={tag}
|
||||
className="rounded bg-blue-500/15 px-2 py-0.5 text-xs text-blue-200"
|
||||
|
||||
Reference in New Issue
Block a user