mirror of
https://github.com/getpaseo/paseo.git
synced 2026-07-29 12:01:31 +00:00
fix: correct typescript ref types for bottom sheet and audio player
This commit is contained in:
@@ -42,7 +42,7 @@ export function AgentStreamView({
|
||||
onPermissionResponse,
|
||||
}: AgentStreamViewProps) {
|
||||
const scrollViewRef = useRef<ScrollView>(null);
|
||||
const bottomSheetRef = useRef<BottomSheetModal>(null);
|
||||
const bottomSheetRef = useRef<BottomSheetModal | null>(null);
|
||||
const insets = useSafeAreaInsets();
|
||||
const [selectedToolCall, setSelectedToolCall] = useState<{
|
||||
toolName: string;
|
||||
|
||||
@@ -20,7 +20,7 @@ interface OrchestratorMessagesViewProps {
|
||||
export const OrchestratorMessagesView = forwardRef<ScrollView, OrchestratorMessagesViewProps>(
|
||||
function OrchestratorMessagesView({ messages, currentAssistantMessage, onArtifactClick }, ref) {
|
||||
const { theme } = useUnistyles();
|
||||
const bottomSheetRef = useRef<BottomSheetModal>(null);
|
||||
const bottomSheetRef = useRef<BottomSheetModal | null>(null);
|
||||
const [selectedToolCall, setSelectedToolCall] = useState<{
|
||||
toolName: string;
|
||||
status: 'executing' | 'completed' | 'failed';
|
||||
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
} from "@gorhom/bottom-sheet";
|
||||
|
||||
interface ToolCallBottomSheetProps {
|
||||
bottomSheetRef: React.RefObject<BottomSheetModal>;
|
||||
bottomSheetRef: React.RefObject<BottomSheetModal | null>;
|
||||
toolName?: string;
|
||||
status?: "pending" | "in_progress" | "executing" | "completed" | "failed";
|
||||
args?: any;
|
||||
|
||||
@@ -50,7 +50,7 @@ export function useAudioPlayer() {
|
||||
const [audioInitialized, setAudioInitialized] = useState(false);
|
||||
const queueRef = useRef<QueuedAudio[]>([]);
|
||||
const isProcessingQueueRef = useRef(false);
|
||||
const playbackTimeoutRef = useRef<NodeJS.Timeout | null>(null);
|
||||
const playbackTimeoutRef = useRef<number | null>(null);
|
||||
|
||||
async function play(audioData: Blob): Promise<number> {
|
||||
return new Promise((resolve, reject) => {
|
||||
|
||||
Reference in New Issue
Block a user