mirror of
https://github.com/Monadical-SAS/reflector.git
synced 2025-12-20 20:29:06 +00:00
Upgrade to latest openapi codegen
This commit is contained in:
@@ -32,7 +32,7 @@ const TranscriptRecord = (details: TranscriptDetails) => {
|
||||
const router = useRouter();
|
||||
|
||||
const [status, setStatus] = useState(
|
||||
webSockets.status.value || transcript.response?.status || "idle"
|
||||
webSockets.status.value || transcript.response?.status || "idle",
|
||||
);
|
||||
|
||||
useEffect(() => {
|
||||
|
||||
@@ -41,8 +41,8 @@ export default function ShareAndPrivacy(props: ShareAndPrivacyProps) {
|
||||
const [isOwner, setIsOwner] = useState(false);
|
||||
const [shareMode, setShareMode] = useState<ShareOption>(
|
||||
shareOptions.find(
|
||||
(option) => option.value === props.transcriptResponse.share_mode
|
||||
) || shareOptions[0]
|
||||
(option) => option.value === props.transcriptResponse.share_mode,
|
||||
) || shareOptions[0],
|
||||
);
|
||||
const [shareLoading, setShareLoading] = useState(false);
|
||||
const requireLogin = featureEnabled("requireLogin");
|
||||
@@ -59,12 +59,12 @@ export default function ShareAndPrivacy(props: ShareAndPrivacyProps) {
|
||||
|
||||
const updatedTranscript = await api.v1TranscriptUpdate(
|
||||
props.transcriptResponse.id,
|
||||
requestBody
|
||||
requestBody,
|
||||
);
|
||||
setShareMode(
|
||||
shareOptions.find(
|
||||
(option) => option.value === updatedTranscript.share_mode
|
||||
) || shareOptions[0]
|
||||
(option) => option.value === updatedTranscript.share_mode,
|
||||
) || shareOptions[0],
|
||||
);
|
||||
setShareLoading(false);
|
||||
};
|
||||
|
||||
@@ -42,7 +42,7 @@ export function TopicList({
|
||||
|
||||
const scrollToTopic = () => {
|
||||
const topicDiv = document.getElementById(
|
||||
`accordion-button-topic-${activeTopic?.id}`
|
||||
`accordion-button-topic-${activeTopic?.id}`,
|
||||
);
|
||||
|
||||
setTimeout(() => {
|
||||
@@ -63,7 +63,7 @@ export function TopicList({
|
||||
const toggleScroll = (element) => {
|
||||
const bottom =
|
||||
Math.abs(
|
||||
element.scrollHeight - element.clientHeight - element.scrollTop
|
||||
element.scrollHeight - element.clientHeight - element.scrollTop,
|
||||
) < 2 || element.scrollHeight == element.clientHeight;
|
||||
if (!bottom && autoscrollEnabled) {
|
||||
setAutoscrollEnabled(false);
|
||||
@@ -97,7 +97,7 @@ export function TopicList({
|
||||
if (!participants.response) return;
|
||||
return (
|
||||
participants.response.find(
|
||||
(participant) => participant.speaker == speakerNumber
|
||||
(participant) => participant.speaker == speakerNumber,
|
||||
)?.name || `Speaker ${speakerNumber}`
|
||||
);
|
||||
};
|
||||
@@ -157,7 +157,7 @@ export function TopicList({
|
||||
<AccordionButton
|
||||
onClick={() => {
|
||||
setActiveTopic(
|
||||
activeTopic?.id == topic.id ? null : topic
|
||||
activeTopic?.id == topic.id ? null : topic,
|
||||
);
|
||||
}}
|
||||
>
|
||||
@@ -200,7 +200,7 @@ export function TopicList({
|
||||
fontSize={"sm"}
|
||||
color={generateHighContrastColor(
|
||||
`Speaker ${segment.speaker}`,
|
||||
[96, 165, 250]
|
||||
[96, 165, 250],
|
||||
)}
|
||||
>
|
||||
{" "}
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
import type { BaseHttpRequest } from "./core/BaseHttpRequest";
|
||||
import type { OpenAPIConfig } from "./core/OpenAPI";
|
||||
import { FetchHttpRequest } from "./core/FetchHttpRequest";
|
||||
|
||||
import { DefaultService } from "./services/DefaultService";
|
||||
|
||||
type HttpRequestConstructor = new (config: OpenAPIConfig) => BaseHttpRequest;
|
||||
|
||||
export class Api {
|
||||
public readonly default: DefaultService;
|
||||
|
||||
public readonly request: BaseHttpRequest;
|
||||
|
||||
constructor(
|
||||
config?: Partial<OpenAPIConfig>,
|
||||
HttpRequest: HttpRequestConstructor = FetchHttpRequest,
|
||||
) {
|
||||
this.request = new HttpRequest({
|
||||
BASE: config?.BASE ?? "",
|
||||
VERSION: config?.VERSION ?? "0.1.0",
|
||||
WITH_CREDENTIALS: config?.WITH_CREDENTIALS ?? false,
|
||||
CREDENTIALS: config?.CREDENTIALS ?? "include",
|
||||
TOKEN: config?.TOKEN,
|
||||
USERNAME: config?.USERNAME,
|
||||
PASSWORD: config?.PASSWORD,
|
||||
HEADERS: config?.HEADERS,
|
||||
ENCODE_PATH: config?.ENCODE_PATH,
|
||||
});
|
||||
|
||||
this.default = new DefaultService(this.request);
|
||||
}
|
||||
}
|
||||
@@ -1,20 +1,15 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
import type { BaseHttpRequest } from "./core/BaseHttpRequest";
|
||||
import type { OpenAPIConfig } from "./core/OpenAPI";
|
||||
import { FetchHttpRequest } from "./core/FetchHttpRequest";
|
||||
|
||||
import { DefaultService } from "./services/DefaultService";
|
||||
|
||||
type HttpRequestConstructor = new (config: OpenAPIConfig) => BaseHttpRequest;
|
||||
|
||||
export class OpenApi {
|
||||
public readonly default: DefaultService;
|
||||
|
||||
public readonly request: BaseHttpRequest;
|
||||
|
||||
constructor(
|
||||
config?: Partial<OpenAPIConfig>,
|
||||
HttpRequest: HttpRequestConstructor = FetchHttpRequest,
|
||||
@@ -30,7 +25,6 @@ export class OpenApi {
|
||||
HEADERS: config?.HEADERS,
|
||||
ENCODE_PATH: config?.ENCODE_PATH,
|
||||
});
|
||||
|
||||
this.default = new DefaultService(this.request);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
@@ -50,7 +50,7 @@ export class CancelablePromise<T> implements Promise<T> {
|
||||
return;
|
||||
}
|
||||
this.#isResolved = true;
|
||||
this.#resolve?.(value);
|
||||
if (this.#resolve) this.#resolve(value);
|
||||
};
|
||||
|
||||
const onReject = (reason?: any): void => {
|
||||
@@ -58,7 +58,7 @@ export class CancelablePromise<T> implements Promise<T> {
|
||||
return;
|
||||
}
|
||||
this.#isRejected = true;
|
||||
this.#reject?.(reason);
|
||||
if (this.#reject) this.#reject(reason);
|
||||
};
|
||||
|
||||
const onCancel = (cancelHandler: () => void): void => {
|
||||
@@ -121,7 +121,7 @@ export class CancelablePromise<T> implements Promise<T> {
|
||||
}
|
||||
}
|
||||
this.#cancelHandlers.length = 0;
|
||||
this.#reject?.(new CancelError("Request aborted"));
|
||||
if (this.#reject) this.#reject(new CancelError("Request aborted"));
|
||||
}
|
||||
|
||||
public get isCancelled(): boolean {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
@@ -147,10 +147,12 @@ export const getHeaders = async (
|
||||
config: OpenAPIConfig,
|
||||
options: ApiRequestOptions,
|
||||
): Promise<Headers> => {
|
||||
const token = await resolve(options, config.TOKEN);
|
||||
const username = await resolve(options, config.USERNAME);
|
||||
const password = await resolve(options, config.PASSWORD);
|
||||
const additionalHeaders = await resolve(options, config.HEADERS);
|
||||
const [token, username, password, additionalHeaders] = await Promise.all([
|
||||
resolve(options, config.TOKEN),
|
||||
resolve(options, config.USERNAME),
|
||||
resolve(options, config.PASSWORD),
|
||||
resolve(options, config.HEADERS),
|
||||
]);
|
||||
|
||||
const headers = Object.entries({
|
||||
Accept: "application/json",
|
||||
@@ -175,7 +177,7 @@ export const getHeaders = async (
|
||||
headers["Authorization"] = `Basic ${credentials}`;
|
||||
}
|
||||
|
||||
if (options.body) {
|
||||
if (options.body !== undefined) {
|
||||
if (options.mediaType) {
|
||||
headers["Content-Type"] = options.mediaType;
|
||||
} else if (isBlob(options.body)) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type AudioWaveform = {
|
||||
data: Array<number>;
|
||||
};
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type Body_transcript_record_upload_v1_transcripts__transcript_id__record_upload_post =
|
||||
{
|
||||
file: Blob;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type CreateParticipant = {
|
||||
speaker?: number | null;
|
||||
name: string;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type CreateTranscript = {
|
||||
name: string;
|
||||
source_language?: string;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type DeletionStatus = {
|
||||
status: string;
|
||||
};
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { TranscriptParticipant } from "./TranscriptParticipant";
|
||||
|
||||
export type GetTranscript = {
|
||||
id: string;
|
||||
user_id: string | null;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type GetTranscriptSegmentTopic = {
|
||||
text: string;
|
||||
start: number;
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { GetTranscriptSegmentTopic } from "./GetTranscriptSegmentTopic";
|
||||
|
||||
export type GetTranscriptTopic = {
|
||||
id: string;
|
||||
title: string;
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { GetTranscriptSegmentTopic } from "./GetTranscriptSegmentTopic";
|
||||
import type { Word } from "./Word";
|
||||
|
||||
export type GetTranscriptTopicWithWords = {
|
||||
id: string;
|
||||
title: string;
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { GetTranscriptSegmentTopic } from "./GetTranscriptSegmentTopic";
|
||||
import type { SpeakerWords } from "./SpeakerWords";
|
||||
|
||||
export type GetTranscriptTopicWithWordsPerSpeaker = {
|
||||
id: string;
|
||||
title: string;
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { ValidationError } from "./ValidationError";
|
||||
|
||||
export type HTTPValidationError = {
|
||||
detail?: Array<ValidationError>;
|
||||
};
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { GetTranscript } from "./GetTranscript";
|
||||
|
||||
export type Page_GetTranscript_ = {
|
||||
items: Array<GetTranscript>;
|
||||
total: number;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type Participant = {
|
||||
id: string;
|
||||
speaker: number | null;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type RtcOffer = {
|
||||
sdp: string;
|
||||
type: string;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type SpeakerAssignment = {
|
||||
speaker?: number | null;
|
||||
participant?: string | null;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type SpeakerAssignmentStatus = {
|
||||
status: string;
|
||||
};
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type SpeakerMerge = {
|
||||
speaker_from: number;
|
||||
speaker_to: number;
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { Word } from "./Word";
|
||||
|
||||
export type SpeakerWords = {
|
||||
speaker: number;
|
||||
words: Array<Word>;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type TranscriptParticipant = {
|
||||
id?: string;
|
||||
speaker: number | null;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type UpdateParticipant = {
|
||||
speaker?: number | null;
|
||||
name?: string | null;
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import type { TranscriptParticipant } from "./TranscriptParticipant";
|
||||
|
||||
export type UpdateTranscript = {
|
||||
name?: string | null;
|
||||
locked?: boolean | null;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type UserInfo = {
|
||||
sub: string;
|
||||
email: string | null;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type ValidationError = {
|
||||
loc: Array<string | number>;
|
||||
msg: string;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
export type Word = {
|
||||
text: string;
|
||||
start: number;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* generated using openapi-typescript-codegen -- do no edit */
|
||||
/* generated using openapi-typescript-codegen -- do not edit */
|
||||
/* istanbul ignore file */
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
@@ -20,13 +20,10 @@ import type { SpeakerMerge } from "../models/SpeakerMerge";
|
||||
import type { UpdateParticipant } from "../models/UpdateParticipant";
|
||||
import type { UpdateTranscript } from "../models/UpdateTranscript";
|
||||
import type { UserInfo } from "../models/UserInfo";
|
||||
|
||||
import type { CancelablePromise } from "../core/CancelablePromise";
|
||||
import type { BaseHttpRequest } from "../core/BaseHttpRequest";
|
||||
|
||||
export class DefaultService {
|
||||
constructor(public readonly httpRequest: BaseHttpRequest) {}
|
||||
|
||||
/**
|
||||
* Metrics
|
||||
* Endpoint that serves Prometheus metrics.
|
||||
@@ -39,7 +36,6 @@ export class DefaultService {
|
||||
url: "/metrics",
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcripts List
|
||||
* @param page Page number
|
||||
@@ -63,7 +59,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcripts Create
|
||||
* @param requestBody
|
||||
@@ -83,7 +78,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get
|
||||
* @param transcriptId
|
||||
@@ -104,7 +98,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Update
|
||||
* @param transcriptId
|
||||
@@ -129,7 +122,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Delete
|
||||
* @param transcriptId
|
||||
@@ -150,7 +142,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Topics
|
||||
* @param transcriptId
|
||||
@@ -171,7 +162,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Topics With Words
|
||||
* @param transcriptId
|
||||
@@ -192,7 +182,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Topics With Words Per Speaker
|
||||
* @param transcriptId
|
||||
@@ -216,7 +205,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Audio Mp3
|
||||
* @param transcriptId
|
||||
@@ -242,7 +230,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Audio Mp3
|
||||
* @param transcriptId
|
||||
@@ -268,7 +255,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Audio Waveform
|
||||
* @param transcriptId
|
||||
@@ -289,7 +275,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Participants
|
||||
* @param transcriptId
|
||||
@@ -310,7 +295,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Add Participant
|
||||
* @param transcriptId
|
||||
@@ -335,7 +319,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Participant
|
||||
* @param transcriptId
|
||||
@@ -359,7 +342,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Update Participant
|
||||
* @param transcriptId
|
||||
@@ -387,7 +369,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Delete Participant
|
||||
* @param transcriptId
|
||||
@@ -411,7 +392,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Assign Speaker
|
||||
* @param transcriptId
|
||||
@@ -436,7 +416,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Merge Speaker
|
||||
* @param transcriptId
|
||||
@@ -461,7 +440,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Record Upload
|
||||
* @param transcriptId
|
||||
@@ -486,7 +464,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Get Websocket Events
|
||||
* @param transcriptId
|
||||
@@ -507,7 +484,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Transcript Record Webrtc
|
||||
* @param transcriptId
|
||||
@@ -532,7 +508,6 @@ export class DefaultService {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* User Me
|
||||
* @returns any Successful Response
|
||||
|
||||
@@ -5,7 +5,7 @@ import { extractDomain } from "./utils";
|
||||
export async function sendZulipMessage(
|
||||
stream: string,
|
||||
topic: string,
|
||||
message: string
|
||||
message: string,
|
||||
) {
|
||||
console.log("Sendiing zulip message", stream, topic);
|
||||
try {
|
||||
@@ -28,14 +28,14 @@ export const ZULIP_MSG_MAX_LENGTH = 10000;
|
||||
export function getZulipMessage(
|
||||
transcript: GetTranscript,
|
||||
topics: GetTranscriptTopic[] | null,
|
||||
includeTopics: boolean
|
||||
includeTopics: boolean,
|
||||
) {
|
||||
const date = new Date(transcript.created_at);
|
||||
|
||||
// Get the timezone offset in minutes and convert it to hours and minutes
|
||||
const timezoneOffset = -date.getTimezoneOffset();
|
||||
const offsetHours = String(
|
||||
Math.floor(Math.abs(timezoneOffset) / 60)
|
||||
Math.floor(Math.abs(timezoneOffset) / 60),
|
||||
).padStart(2, "0");
|
||||
const offsetMinutes = String(Math.abs(timezoneOffset) % 60).padStart(2, "0");
|
||||
const offsetSign = timezoneOffset >= 0 ? "+" : "-";
|
||||
|
||||
Reference in New Issue
Block a user