From 87ed7c8affd3ade9d3cd2d9ed1a61dd5f224e473 Mon Sep 17 00:00:00 2001 From: toasted-nutbread Date: Wed, 31 Jan 2024 08:38:30 -0500 Subject: Module refactoring (#588) * Convert PronunciationGenerator into static functions * Convert DictionaryDataUtil into static functions * Convert AnkiNoteDataCreator into static functions * Convert MediaUtil into static functions * Convert RegexUtil into static functions * Convert StringUtil into static functions * Convert ArrayBufferUtil into static functions * Convert AnkiUtil into static functions * Convert PermissionsUtil into static functions * Convert ProfileConditionsUtil into static functions --- test/utilities/anki.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'test/utilities') diff --git a/test/utilities/anki.js b/test/utilities/anki.js index e30d578f..69f4ce8b 100644 --- a/test/utilities/anki.js +++ b/test/utilities/anki.js @@ -16,16 +16,16 @@ */ import {AnkiNoteBuilder} from '../../ext/js/data/anki-note-builder.js'; +import {createAnkiNoteData} from '../../ext/js/data/sandbox/anki-note-data-creator.js'; import {AnkiTemplateRenderer} from '../../ext/js/templates/sandbox/anki-template-renderer.js'; /** - * @param {import('../../ext/js/data/sandbox/anki-note-data-creator.js').AnkiNoteDataCreator} ankiNoteDataCreator * @param {import('dictionary').DictionaryEntry} dictionaryEntry * @param {import('settings').ResultOutputMode} mode * @returns {import('anki-templates').NoteData} * @throws {Error} */ -export function createTestAnkiNoteData(ankiNoteDataCreator, dictionaryEntry, mode) { +export function createTestAnkiNoteData(dictionaryEntry, mode) { const marker = '{marker}'; /** @type {import('anki-templates-internal').CreateDetails} */ const data = { @@ -43,7 +43,7 @@ export function createTestAnkiNoteData(ankiNoteDataCreator, dictionaryEntry, mod }, media: {} }; - return ankiNoteDataCreator.create(marker, data); + return createAnkiNoteData(marker, data); } /** -- cgit v1.2.3