Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
savayer committed Feb 19, 2024
2 parents e7aa699 + 8daf0d0 commit a2409dc
Show file tree
Hide file tree
Showing 24 changed files with 39 additions and 39 deletions.
4 changes: 2 additions & 2 deletions components/Quiz.vue
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@
</template>

<script lang="ts" setup>
import { Ref } from 'vue';
import { quizQuestion } from '~/repository/modules/quiz/types';
import type { Ref } from 'vue';
import type { quizQuestion } from '~/repository/modules/quiz/types';
interface Props {
questions: quizQuestion[];
Expand Down
2 changes: 1 addition & 1 deletion components/Speech.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</template>

<script setup lang="ts">
import { wordVoiceActing } from '~/repository/modules/types';
import type { wordVoiceActing } from '~/repository/modules/types';
import { PlayIcon, PauseIcon } from '@heroicons/vue/24/outline';
interface Props {
Expand Down
4 changes: 2 additions & 2 deletions components/TrainingPacks.vue
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,8 @@
</template>

<script lang="ts" setup>
import { Ref } from 'vue';
import { trainingPackQuiz } from '~/repository/modules/types';
import type { Ref } from 'vue';
import type { trainingPackQuiz } from '~/repository/modules/types';
import getWordImage from '~/utils/getWordImage';
interface Props {
Expand Down
2 changes: 1 addition & 1 deletion components/UI/PackWord.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
<script setup lang="ts">
import getWordImage from '~/utils/getWordImage';
import { CameraIcon, TrashIcon } from '@heroicons/vue/24/outline';
import { Word } from '~/repository/modules/types';
import type { Word } from '~/repository/modules/types';
interface Props {
showDeleteButton?: boolean;
Expand Down
4 changes: 2 additions & 2 deletions components/Widget/AddingNewWordModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
</template>

<script setup lang="ts">
import { Ref } from 'vue';
import { FoundWord } from '~/repository/modules/user/types';
import type { Ref } from 'vue';
import type { FoundWord } from '~/repository/modules/user/types';
import { PlusIcon } from '@heroicons/vue/20/solid';
interface Props {
Expand Down
2 changes: 1 addition & 1 deletion components/Widget/SelectingImageModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
</template>

<script setup lang="ts">
import { Word as wordType } from '~/repository/modules/types';
import type { Word as wordType } from '~/repository/modules/types';
import { ArrowTopRightOnSquareIcon } from '@heroicons/vue/20/solid';
interface Props {
Expand Down
4 changes: 2 additions & 2 deletions pages/admin/logs.vue
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,8 @@

<script lang="ts" setup>
import { useAsyncData } from '#app';
import { Ref } from 'vue';
import { TranslationLog } from '~/repository/modules/admin/types';
import type { Ref } from 'vue';
import type { TranslationLog } from '~/repository/modules/admin/types';
import { TrashIcon } from '@heroicons/vue/24/outline';
import detectDevice from '../../utils/detectDevice';
import dateFormat from 'dateformat/lib/dateformat';
Expand Down
6 changes: 3 additions & 3 deletions pages/packs/[slug].vue
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@

<script setup lang="ts">
import { useI18n } from 'vue-i18n';
import { Ref } from 'vue';
import type { Ref } from 'vue';
import type { Pack } from '~/repository/modules/user/types';
import type { Word as wordType } from '~/repository/modules/types';
import { useUserStore } from '~/store/user';
import { Pack } from '~/repository/modules/user/types';
import { TrashIcon, CameraIcon } from '@heroicons/vue/24/outline';
import { Word as wordType } from '~/repository/modules/types';
import getWordImage from '~/utils/getWordImage';
import { definePageMeta } from '#imports';
import PackWord from '~/components/UI/PackWord.vue';
Expand Down
4 changes: 2 additions & 2 deletions pages/packs/edit/[slug].vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@

<script lang="ts" setup>
import { useI18n } from 'vue-i18n';
import { Ref } from 'vue';
import { Pack } from '~/repository/modules/user/types';
import type { Ref } from 'vue';
import type { Pack } from '~/repository/modules/user/types';
import { useUserStore } from '~/store/user';
import { definePageMeta } from '#imports';
import { useAsyncData } from '#app';
Expand Down
4 changes: 2 additions & 2 deletions pages/packs/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
</template>

<script setup lang="ts">
import { Ref } from 'vue';
import type { Ref } from 'vue';
import type { Pack } from '~/repository/modules/user/types';
import { useI18n } from 'vue-i18n';
import { Pack } from '~/repository/modules/user/types';
import { definePageMeta } from '#imports';
import { useAsyncData } from '#app';
Expand Down
6 changes: 3 additions & 3 deletions pages/packs/training/[packSlug].vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
</template>

<script setup lang="ts">
import type { Ref } from 'vue';
import type { Pack } from '~/repository/modules/user/types';
import type { trainingPackQuiz } from '~/repository/modules/types';
import { useI18n } from 'vue-i18n';
import { Ref } from 'vue';
import { useUserStore } from '~/store/user';
import { Pack } from '~/repository/modules/user/types';
import TrainingPacks from '~/components/TrainingPacks.vue';
import { trainingPackQuiz } from '~/repository/modules/types';
import { definePageMeta } from '#imports';
import { useAsyncData } from '#app';
Expand Down
4 changes: 2 additions & 2 deletions pages/public-packs/[slug].vue
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@

<script setup lang="ts">
import { useI18n } from 'vue-i18n';
import { Ref } from 'vue';
import { Pack } from '~/repository/modules/user/types';
import type { Ref } from 'vue';
import type { Pack } from '~/repository/modules/user/types';
import PackWord from '~/components/UI/PackWord.vue';
import { useAsyncData } from '#app';
Expand Down
4 changes: 2 additions & 2 deletions pages/quiz.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
</template>

<script setup lang="ts">
import { Ref } from 'vue';
import { quizQuestion } from '~/repository/modules/quiz/types';
import type { Ref } from 'vue';
import type { quizQuestion } from '~/repository/modules/quiz/types';
import { useI18n } from 'vue-i18n';
const { t } = useI18n();
Expand Down
2 changes: 1 addition & 1 deletion pages/words/[slug].vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
</template>

<script setup lang="ts">
import { Word as wordType } from '~/repository/modules/types';
import type { Word as wordType } from '~/repository/modules/types';
import { useAsyncData } from '#app';
const route = useRoute();
Expand Down
2 changes: 1 addition & 1 deletion repository/modules/admin/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import HttpFactory from '~/repository/factory';
import { TranslationLog } from '~/repository/modules/admin/types';
import type { TranslationLog } from '~/repository/modules/admin/types';

class AdminModule extends HttpFactory {
public RESOURCE = '/api/jwt/admin';
Expand Down
2 changes: 1 addition & 1 deletion repository/modules/auth/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import HttpFactory from '~/repository/factory';
import { IAuthModule, tokenType } from '~/repository/modules/auth/types';
import type { IAuthModule, tokenType } from '~/repository/modules/auth/types';

class AuthModule extends HttpFactory implements IAuthModule {
public RESOURCE_LOGIN = '/api/jwt/login';
Expand Down
2 changes: 1 addition & 1 deletion repository/modules/quiz/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import HttpFactory from '~/repository/factory';
import {
import type {
IQuiz,
quizQuestionsApiResponse,
} from '~/repository/modules/quiz/types';
Expand Down
2 changes: 1 addition & 1 deletion repository/modules/statistic/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import HttpFactory from '~/repository/factory';
import {
import type {
IStatistic,
translationsAmountApiResponse,
} from '~/repository/modules/statistic/types';
Expand Down
2 changes: 1 addition & 1 deletion repository/modules/translate/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import HttpFactory from '~/repository/factory';
import {
import type {
ITranslateModule,
translationType,
translationApiResponse,
Expand Down
6 changes: 3 additions & 3 deletions repository/modules/user/index.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import HttpFactory from '~/repository/factory';
import {
import type {
FoundWord,
IUser,
IUserModule,
Pack,
} from '~/repository/modules/user/types';
import { useUserStore } from '~/store/user';
// @todo don't use axios here
import { AxiosError } from 'axios';
import { trainingPackQuiz } from '~/repository/modules/types';
import type { AxiosError } from 'axios';
import type { trainingPackQuiz } from '~/repository/modules/types';

class UserModule extends HttpFactory implements IUserModule {
public RESOURCE = '/api/jwt/user';
Expand Down
4 changes: 2 additions & 2 deletions repository/modules/words/index.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import HttpFactory from '~/repository/factory';
import {
import type {
IWordsModule,
oneWordApiResponse,
wordsApiResponse,
} from '~/repository/modules/words/types';
import { Word } from '~/repository/modules/types';
import type { Word } from '~/repository/modules/types';

class WordsModule extends HttpFactory implements IWordsModule {
public readonly RESOURCE = '/api/words';
Expand Down
2 changes: 1 addition & 1 deletion repository/modules/words/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { metaResponse, Word } from '~/repository/modules/types';
import type { metaResponse, Word } from '~/repository/modules/types';

export type wordsApiResponse = {
data: Word[];
Expand Down
2 changes: 1 addition & 1 deletion store/user.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { defineStore } from 'pinia';
import { IUser } from '~/repository/modules/user/types';
import type { IUser } from '~/repository/modules/user/types';

export const useUserStore = defineStore('user', {
state: () => ({
Expand Down
2 changes: 1 addition & 1 deletion utils/getWordImage.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Word as wordType } from '~/repository/modules/types';
import type { Word as wordType } from '~/repository/modules/types';

export default function getWordImage(word: wordType) {
if (word.pivot.bur_word_image_id) {
Expand Down

0 comments on commit a2409dc

Please sign in to comment.