Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/audio overview #458

Merged
merged 3 commits into from
Aug 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions license-checker-template.json

This file was deleted.

12 changes: 9 additions & 3 deletions src/components/shared/AudioViewer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -338,13 +338,19 @@ const AudioViewer = ({
]);

useEffect(() => {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
(waveform.current?.backend as any).media.loop = repeat;
if (isReady && autoplay && !waveform.current?.isPlaying()) {
switchActiveWidget();
waveform.current?.play();
}
}, [isReady, autoplay, repeat]);
}, [isReady, autoplay]);

useEffect(() => {
const backend = waveform.current?.backend;
if (backend) {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
(backend as any).media.loop = repeat;
}
}, [isReady, repeat]);

useEffect(() => {
if (!waveform.current?.isReady) return;
Expand Down
2 changes: 1 addition & 1 deletion src/lib.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export { default as api } from './api';
export type { App } from './stores/pluginStore';
export { useDataset, convertValue } from './stores/dataset';
export { useColors } from './stores/colors';
export { isAudio, isBoolean, getNullValue, isCategorical } from './datatypes';
export { isAudio, isBoolean, getNullValue, isCategorical, isWindow } from './datatypes';
export type {
EmbeddingDataType,
DataType,
Expand Down