Refactor layout (#1063)
* sidebar collapsable * resizable panel for audio page * rename components * refacotr * refactor media panels * refactor * auto resize waveform * refactor: rename files * refactor media components * refactor * rename * fix media provider * refactor wavefor action buttons * clean code * refactor media recording player * clean up * fix hotkeys * refactor * fix style * fix style * fix chat input * fix shadow player in course * fix style * fix style
This commit is contained in:
@@ -51,6 +51,7 @@ export const ChatInput = () => {
|
||||
isPaused,
|
||||
askAgent,
|
||||
onCreateMessage,
|
||||
shadowing,
|
||||
} = useContext(ChatSessionProviderContext);
|
||||
const { EnjoyApp } = useContext(AppSettingsProviderContext);
|
||||
const inputRef = useRef<HTMLTextAreaElement>(null);
|
||||
@@ -96,6 +97,7 @@ export const ChatInput = () => {
|
||||
useHotkeys(
|
||||
currentHotkeys.StartOrStopRecording,
|
||||
() => {
|
||||
if (shadowing) return;
|
||||
if (isRecording) {
|
||||
stopRecording();
|
||||
} else {
|
||||
@@ -107,9 +109,16 @@ export const ChatInput = () => {
|
||||
}
|
||||
);
|
||||
|
||||
useHotkeys(currentHotkeys.PlayNextSegment, () => askAgent(), {
|
||||
preventDefault: true,
|
||||
});
|
||||
useHotkeys(
|
||||
currentHotkeys.PlayNextSegment,
|
||||
() => {
|
||||
if (shadowing) return;
|
||||
askAgent();
|
||||
},
|
||||
{
|
||||
preventDefault: true,
|
||||
}
|
||||
);
|
||||
|
||||
if (isRecording) {
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user