Базовая версия голосовых сообщений и аудиоплеер. Кодирование OPUS

This commit is contained in:
RoyceDa
2026-04-10 17:20:44 +02:00
parent 93ef692eb5
commit b596d36543
11 changed files with 1204 additions and 96 deletions

View File

@@ -0,0 +1,10 @@
import { useContext } from "react";
import { PlayerContext, PlayerContextValue } from "./PlayerProvider";
export function usePlayerContext() : PlayerContextValue {
const context = useContext(PlayerContext);
if (!context) {
throw new Error("useAudioPlayer must be used within a PlayerProvider");
}
return context;
}