Skip to content

Commit

Permalink
Synopsis db refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
anwolosz committed Sep 2, 2024
1 parent d766597 commit 0932212
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 11 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
18 changes: 10 additions & 8 deletions src/stores/SynopsisStore.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
import { defineStore } from 'pinia'
import synopsis_szit from '@/assets/synopsis_szit.json'
import synopsis_esv from '@/assets/synopsis_esv.json'
import dictionary_en from '@/assets/translation/en.json'
import dictionary_hu from '@/assets/translation/hu.json'
import type { SectionScheme, SynopsisScheme } from '@/interfaces/synopsisInterface'
import type { DictionaryScheme } from '@/interfaces/dictionaryInterface'
import router from '../router';
const synopsisSZIT: SynopsisScheme = synopsis_szit
const synopsisESV: SynopsisScheme = synopsis_esv
const dictionaryEn: DictionaryScheme = dictionary_en
const dictionaryHu: DictionaryScheme = dictionary_hu

import szit from '@/assets/translations/szit.json'
import esv from '@/assets/translations/esv.json'
import en from '@/assets/languages/en.json'
import hu from '@/assets/languages/hu.json'
const synopsisSZIT: SynopsisScheme = szit
const synopsisESV: SynopsisScheme = esv
const dictionaryEn: DictionaryScheme = en
const dictionaryHu: DictionaryScheme = hu
// TODO: proper typing
const dictionary: any = {
en: dictionaryEn,
hu: dictionaryHu
Expand Down
4 changes: 2 additions & 2 deletions tests/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
set -ex
SCRIPT_FOLDER=$(dirname "${0}")
WORKSPACE_FOLDER=$(readlink -e "${SCRIPT_FOLDER}/../")
JSON_FOLDER="$WORKSPACE_FOLDER/src/assets/"
python3 "$SCRIPT_FOLDER"/json_test.py "$JSON_FOLDER"
TRANSLATION_FOLDER="$WORKSPACE_FOLDER/src/assets/translations/"
python3 "$SCRIPT_FOLDER"/json_test.py "$TRANSLATION_FOLDER"
echo "All tests passed"
2 changes: 1 addition & 1 deletion tsconfig.app.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": "@vue/tsconfig/tsconfig.dom.json",
"include": ["env.d.ts", "src/**/*", "src/**/*.vue", "src/assets/synopsis_szit.json", "src/assets/synopsis_esv.json", "src/assets/translation/hu.json", "src/assets/translation/en.json", "src/stores/*"],
"include": ["env.d.ts", "src/**/*", "src/**/*.vue", "src/assets/translations/*.json", "src/assets/languages/*.json", "src/stores/*"],
"exclude": ["src/**/__tests__/*"],
"compilerOptions": {
"composite": true,
Expand Down

0 comments on commit 0932212

Please sign in to comment.