From b98ae212f0190fa0d9ca86aee833b03aa262eb1b Mon Sep 17 00:00:00 2001 From: Stefan Vuković Date: Sat, 29 Jun 2024 15:39:47 +0200 Subject: Add wiktionary commons audio source (#1143) * add audio source for wiktionary format filenames on commons * allow region codes * fix files being saved in anki as mp3 --- types/ext/audio-downloader.d.ts | 16 ++++++++-------- types/ext/settings.d.ts | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) (limited to 'types') diff --git a/types/ext/audio-downloader.d.ts b/types/ext/audio-downloader.d.ts index c7f7ecbe..bbf7afbc 100644 --- a/types/ext/audio-downloader.d.ts +++ b/types/ext/audio-downloader.d.ts @@ -55,28 +55,28 @@ export type CustomAudioListSource = { name?: string; }; -export type LinguaLibreLookupResponse = { +export type WikimediaCommonsLookupResponse = { query: { - search: LinguaLibreLookupResult[]; + search: WikimediaCommonsLookupResult[]; }; }; -export type LinguaLibreFileResponse = { +export type WikimediaCommonsFileResponse = { query: { - pages: Record; + pages: Record; }; }; -export type LinguaLibreLookupResult = { +export type WikimediaCommonsLookupResult = { title: string; }; -export type LinguaLibreFileResult = { +export type WikimediaCommonsFileResult = { title: string; - imageinfo: LinguaLibreFileResultImageInfo[]; + imageinfo: WikimediaCommonsFileResultImageInfo[]; }; -export type LinguaLibreFileResultImageInfo = { +export type WikimediaCommonsFileResultImageInfo = { url: string; user: string; }; diff --git a/types/ext/settings.d.ts b/types/ext/settings.d.ts index 9253efc3..559a27c4 100644 --- a/types/ext/settings.d.ts +++ b/types/ext/settings.d.ts @@ -383,7 +383,7 @@ export type PopupWindowType = 'normal' | 'popup'; export type PopupWindowState = 'normal' | 'maximized' | 'fullscreen'; -export type AudioSourceType = 'jpod101' | 'jpod101-alternate' | 'jisho' | 'lingua-libre' | 'text-to-speech' | 'text-to-speech-reading' | 'custom' | 'custom-json'; +export type AudioSourceType = 'jpod101' | 'jpod101-alternate' | 'jisho' | 'lingua-libre' | 'wiktionary' | 'text-to-speech' | 'text-to-speech-reading' | 'custom' | 'custom-json'; export type TranslationConvertType = 'false' | 'true' | 'variant'; -- cgit v1.2.3