mirror of
https://github.com/Monadical-SAS/reflector.git
synced 2025-12-20 20:29:06 +00:00
prevent speaker reset when switching topic
This commit is contained in:
@@ -207,7 +207,8 @@ const ParticipantList = ({
|
||||
}
|
||||
};
|
||||
|
||||
const deleteParticipant = (participantId) => () => {
|
||||
const deleteParticipant = (participantId) => (e) => {
|
||||
e.stopPropagation();
|
||||
if (!loading) {
|
||||
api
|
||||
?.v1TranscriptDeleteParticipant({
|
||||
|
||||
@@ -9,7 +9,11 @@ import WaveformLoading from "../../waveformLoading";
|
||||
import { UseParticipants } from "../../useParticipants";
|
||||
import { Participant } from "../../../../api";
|
||||
import { UseTopicWithWords } from "../../useTopicWithWords";
|
||||
import { TimeSlice, selectedTextIsTimeSlice } from "./page";
|
||||
import {
|
||||
TimeSlice,
|
||||
selectedTextIsSpeaker,
|
||||
selectedTextIsTimeSlice,
|
||||
} from "./page";
|
||||
|
||||
// TODO shortcuts ?
|
||||
// TODO fix key (using indexes might act up, not sure as we don't re-order per say)
|
||||
@@ -31,8 +35,7 @@ const topicWords = ({
|
||||
const [selectedText, setSelectedText] = stateSelectedText;
|
||||
|
||||
useEffect(() => {
|
||||
if (topicWithWords.loading) {
|
||||
// setWordsBySpeaker([]);
|
||||
if (topicWithWords.loading && selectedTextIsTimeSlice(selectedText)) {
|
||||
setSelectedText(undefined);
|
||||
console.log("unsetting topic changed");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user