Skip to content

Commit

Permalink
move dictionary files to dictionary folder
Browse files Browse the repository at this point in the history
  • Loading branch information
StefanVukovic99 committed Dec 22, 2023
1 parent c18141a commit e161c24
Show file tree
Hide file tree
Showing 21 changed files with 21 additions and 21 deletions.
10 changes: 5 additions & 5 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@
"ext/js/general/regex-util.js",
"ext/js/general/text-source-map.js",
"ext/js/language/deinflector.js",
"ext/js/language/dictionary-database.js",
"ext/js/dictionary/dictionary-database.js",
"ext/js/language/sandbox/dictionary-data-util.js",
"ext/js/language/sandbox/japanese-util.js",
"ext/js/language/translator.js",
Expand Down Expand Up @@ -741,10 +741,10 @@
"ext/js/data/database.js",
"ext/js/data/json-schema.js",
"ext/js/general/cache-map.js",
"ext/js/language/dictionary-database.js",
"ext/js/language/dictionary-importer.js",
"ext/js/language/dictionary-worker-handler.js",
"ext/js/language/dictionary-worker-media-loader.js",
"ext/js/dictionary/dictionary-database.js",
"ext/js/dictionary/dictionary-importer.js",
"ext/js/dictionary/dictionary-worker-handler.js",
"ext/js/dictionary/dictionary-worker-media-loader.js",
"ext/js/media/media-util.js"
],
"env": {
Expand Down
4 changes: 2 additions & 2 deletions dev/jsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@
"../ext/js/general/regex-util.js",
"../ext/js/general/text-source-map.js",
"../ext/js/language/deinflector.js",
"../ext/js/language/dictionary-importer.js",
"../ext/js/language/dictionary-database.js",
"../ext/js/dictionary/dictionary-importer.js",
"../ext/js/dictionary/dictionary-database.js",
"../ext/js/language/sandbox/dictionary-data-util.js",
"../ext/js/language/sandbox/japanese-util.js",
"../ext/js/language/translator.js",
Expand Down
2 changes: 1 addition & 1 deletion ext/js/background/backend.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ import {AnkiUtil} from '../data/anki-util.js';
import {OptionsUtil} from '../data/options-util.js';
import {PermissionsUtil} from '../data/permissions-util.js';
import {ArrayBufferUtil} from '../data/sandbox/array-buffer-util.js';
import {DictionaryDatabase} from '../dictionary/dictionary-database.js';
import {Environment} from '../extension/environment.js';
import {ObjectPropertyAccessor} from '../general/object-property-accessor.js';
import {DictionaryDatabase} from '../language/dictionary-database.js';
import {JapaneseUtil} from '../language/sandbox/japanese-util.js';
import {Translator} from '../language/translator.js';
import {AudioDownloader} from '../media/audio-downloader.js';
Expand Down
2 changes: 1 addition & 1 deletion ext/js/background/offscreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import {ClipboardReader} from '../comm/clipboard-reader.js';
import {invokeMessageHandler} from '../core.js';
import {createApiMap, getApiMapHandler} from '../core/api-map.js';
import {ArrayBufferUtil} from '../data/sandbox/array-buffer-util.js';
import {DictionaryDatabase} from '../language/dictionary-database.js';
import {DictionaryDatabase} from '../dictionary/dictionary-database.js';
import {JapaneseUtil} from '../language/sandbox/japanese-util.js';
import {Translator} from '../language/translator.js';

Expand Down
2 changes: 1 addition & 1 deletion ext/js/data/sandbox/anki-note-data-creator.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/

import {DictionaryDataUtil} from '../../language/sandbox/dictionary-data-util.js';
import {DictionaryDataUtil} from '../../dictionary/dictionary-data-util.js';

/**
* This class is used to convert the internal dictionary entry format to the
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export class DictionaryWorker {
*/
_invoke(action, params, transfer, onProgress, formatResult) {
return new Promise((resolve, reject) => {
const worker = new Worker('/js/language/dictionary-worker-main.js', {type: 'module'});
const worker = new Worker('/js/dictionary/dictionary-worker-main.js', {type: 'module'});
/** @type {import('dictionary-worker').InvokeDetails<TResponseRaw, TResponse>} */
const details = {
complete: false,
Expand Down
2 changes: 1 addition & 1 deletion ext/js/display/display-generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

import {isObject} from '../core.js';
import {ExtensionError} from '../core/extension-error.js';
import {DictionaryDataUtil} from '../dictionary/dictionary-data-util.js';
import {HtmlTemplateCollection} from '../dom/html-template-collection.js';
import {DictionaryDataUtil} from '../language/sandbox/dictionary-data-util.js';
import {yomitan} from '../yomitan.js';
import {PronunciationGenerator} from './sandbox/pronunciation-generator.js';
import {StructuredContentGenerator} from './sandbox/structured-content-generator.js';
Expand Down
2 changes: 1 addition & 1 deletion ext/js/language/translator.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export class Translator {
constructor({japaneseUtil, database}) {
/** @type {import('./sandbox/japanese-util.js').JapaneseUtil} */
this._japaneseUtil = japaneseUtil;
/** @type {import('./dictionary-database.js').DictionaryDatabase} */
/** @type {import('../dictionary/dictionary-database.js').DictionaryDatabase} */
this._database = database;
/** @type {?Deinflector} */
this._deinflector = null;
Expand Down
2 changes: 1 addition & 1 deletion ext/js/pages/settings/dictionary-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
*/

import {EventListenerCollection, log} from '../../core.js';
import {DictionaryWorker} from '../../dictionary/dictionary-worker.js';
import {querySelectorNotNull} from '../../dom/query-selector.js';
import {DictionaryWorker} from '../../language/dictionary-worker.js';
import {yomitan} from '../../yomitan.js';

class DictionaryEntry {
Expand Down
2 changes: 1 addition & 1 deletion ext/js/pages/settings/dictionary-import-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

import {log} from '../../core.js';
import {ExtensionError} from '../../core/extension-error.js';
import {DictionaryWorker} from '../../dictionary/dictionary-worker.js';
import {querySelectorNotNull} from '../../dom/query-selector.js';
import {DictionaryWorker} from '../../language/dictionary-worker.js';
import {yomitan} from '../../yomitan.js';
import {DictionaryController} from './dictionary-controller.js';

Expand Down
2 changes: 1 addition & 1 deletion ext/js/templates/sandbox/anki-template-renderer.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@

import {Handlebars} from '../../../lib/handlebars.js';
import {AnkiNoteDataCreator} from '../../data/sandbox/anki-note-data-creator.js';
import {DictionaryDataUtil} from '../../dictionary/dictionary-data-util.js';
import {PronunciationGenerator} from '../../display/sandbox/pronunciation-generator.js';
import {StructuredContentGenerator} from '../../display/sandbox/structured-content-generator.js';
import {CssStyleApplier} from '../../dom/sandbox/css-style-applier.js';
import {DictionaryDataUtil} from '../../language/sandbox/dictionary-data-util.js';
import {JapaneseUtil} from '../../language/sandbox/japanese-util.js';
import {AnkiTemplateRendererContentManager} from './anki-template-renderer-content-manager.js';
import {TemplateRendererMediaProvider} from './template-renderer-media-provider.js';
Expand Down
4 changes: 2 additions & 2 deletions test/database.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ import path from 'path';
import {beforeEach, describe, expect, test, vi} from 'vitest';
import {parseJson} from '../dev/json.js';
import {createDictionaryArchive} from '../dev/util.js';
import {DictionaryDatabase} from '../ext/js/language/dictionary-database.js';
import {DictionaryImporter} from '../ext/js/language/dictionary-importer.js';
import {DictionaryDatabase} from '../ext/js/dictionary/dictionary-database.js';
import {DictionaryImporter} from '../ext/js/dictionary/dictionary-importer.js';
import {DictionaryImporterMediaLoader} from './mocks/dictionary-importer-media-loader.js';

const dirname = path.dirname(fileURLToPath(import.meta.url));
Expand Down
4 changes: 2 additions & 2 deletions test/fixtures/translator-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ import {expect, vi} from 'vitest';
import {parseJson} from '../../dev/json.js';
import {createDictionaryArchive} from '../../dev/util.js';
import {AnkiNoteDataCreator} from '../../ext/js/data/sandbox/anki-note-data-creator.js';
import {DictionaryDatabase} from '../../ext/js/language/dictionary-database.js';
import {DictionaryImporter} from '../../ext/js/language/dictionary-importer.js';
import {DictionaryDatabase} from '../../ext/js/dictionary/dictionary-database.js';
import {DictionaryImporter} from '../../ext/js/dictionary/dictionary-importer.js';
import {JapaneseUtil} from '../../ext/js/language/sandbox/japanese-util.js';
import {Translator} from '../../ext/js/language/translator.js';
import {chrome, fetch} from '../mocks/common.js';
Expand Down
2 changes: 1 addition & 1 deletion types/ext/translator.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/

import type {DictionaryDatabase} from '../../ext/js/language/dictionary-database';
import type {DictionaryDatabase} from '../../ext/js/dictionary/dictionary-database';
import type {JapaneseUtil} from '../../ext/js/language/sandbox/japanese-util';
import type * as Dictionary from './dictionary';
import type * as DictionaryDatabaseTypes from './dictionary-database';
Expand Down

0 comments on commit e161c24

Please sign in to comment.