mirror of
https://github.com/rishikanthc/Scriberr.git
synced 2026-06-28 06:46:25 +00:00
drop the any
This commit is contained in:
committed by
Rishikanth Chandrasekaran
parent
410e6ea91b
commit
ff41bd7dc6
@@ -12,7 +12,7 @@ import { EmberPlayer, type EmberPlayerRef } from "@/components/audio/EmberPlayer
|
||||
import { cn } from "@/lib/utils";
|
||||
|
||||
// Custom Hooks
|
||||
import { useAudioDetail, useUpdateTitle, useTranscript } from "@/features/transcription/hooks/useAudioDetail";
|
||||
import { useAudioDetail, useUpdateTitle, useTranscript, type TranscriptSegment } from "@/features/transcription/hooks/useAudioDetail";
|
||||
import { useSpeakerMappings } from "@/features/transcription/hooks/useTranscriptionSpeakers";
|
||||
import { useTranscriptDownload } from "@/features/transcription/hooks/useTranscriptDownload";
|
||||
|
||||
@@ -312,13 +312,12 @@ export const AudioDetailView = function AudioDetailView({ audioId: propAudioId }
|
||||
<MessageCircle className={cn("mr-2 h-4 w-4 opacity-70", chatOpen && "text-[var(--brand-solid)]")} />
|
||||
Chat with Audio
|
||||
</DropdownMenuItem>
|
||||
{transcript?.segments?.some((s: any) => s.speaker) && (
|
||||
{transcript?.segments?.some((s: TranscriptSegment) => s.speaker) && (
|
||||
<DropdownMenuItem onClick={() => setSpeakerRenameOpen(true)} className="rounded-[8px] cursor-pointer">
|
||||
<Users className="mr-2 h-4 w-4 opacity-70" />
|
||||
Rename Speakers
|
||||
</DropdownMenuItem>
|
||||
)}
|
||||
<DropdownMenuSeparator className="bg-[var(--border-subtle)] my-1" />
|
||||
<DropdownMenuItem onClick={() => setSummaryDialogOpen(true)} className="rounded-[8px] cursor-pointer text-[var(--brand-solid)] focus:text-[var(--brand-solid)] focus:bg-[var(--brand-light)]">
|
||||
<Bot className="mr-2 h-4 w-4" /> AI Summary
|
||||
</DropdownMenuItem>
|
||||
|
||||
@@ -75,14 +75,16 @@ export interface WordSegment {
|
||||
speaker?: string;
|
||||
}
|
||||
|
||||
export interface TranscriptSegment {
|
||||
start: number;
|
||||
end: number;
|
||||
text: string;
|
||||
speaker?: string;
|
||||
}
|
||||
|
||||
export interface Transcript {
|
||||
text: string;
|
||||
segments?: Array<{
|
||||
start: number;
|
||||
end: number;
|
||||
text: string;
|
||||
speaker?: string;
|
||||
}>;
|
||||
segments?: TranscriptSegment[];
|
||||
word_segments?: WordSegment[];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user