Skip to content

Commit

Permalink
Merge pull request #43 from Gamify-IT/feature/background_music_and_so…
Browse files Browse the repository at this point in the history
…unds

Feature/background music and sounds
  • Loading branch information
katyaganina committed Jul 22, 2024
2 parents 0f2cec6 + 5478871 commit 5658745
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 17 deletions.
19 changes: 12 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions src/components/GamePanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ import { computed, onMounted, ref, watch } from "vue";
import MemoryCard from "./MemoryCard.vue";
import ContentModal from "./ContentModal.vue";
import PairItem from "./PairItem.vue";
import { CardData, CardPair, CardSelection } from "../types/data-models";
import { CardData, CardPair, CardSelection } from "@/types/data-models";
import { MemoryController } from "@/types/memory-controller";
import swipeSoundSource from '/src/assets/music/swipe_sound.mp3';
import successSoundSource from '/src/assets/music/success_sound.mp3';
import clickSoundSource from '/src/assets/music/click_sound.mp3';
import wrongAnswerSoundSource from '/src/assets/music/wrong_answer_sound.mp3';
import swipeSoundSource from '@/assets/music/swipe_sound.mp3';
import successSoundSource from '@/assets/music/success_sound.mp3';
import clickSoundSource from '@/assets/music/click_sound.mp3';
import wrongAnswerSoundSource from '@/assets/music/wrong_answer_sound.mp3';
const router = useRouter();
const cards = ref([] as CardData[]);
Expand Down
4 changes: 2 additions & 2 deletions src/components/MemoryCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@
import { PropType, ref, watch, computed, onMounted } from "vue";
import katex from "katex";
import markedKatex from "marked-katex-extension";
import { CardData, CardType, CardSelection } from "../types/data-models";
import { CardData, CardType, CardSelection } from "@/types/data-models";
import { marked } from "marked";
import hljs from "highlight.js";
import "highlight.js/styles/vs.css";
import "katex/dist/katex.min.css";
import clickSoundSource from '/src/assets/music/click_sound.mp3';
import clickSoundSource from "@/assets/music/click_sound.mp3";
const clickSound = new Audio(clickSoundSource);
const props = defineProps({
Expand Down
2 changes: 1 addition & 1 deletion src/components/StartGameScene.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

<script setup lang="ts">
import { useRoute, useRouter } from "vue-router";
import clickSoundSource from '/src/assets/music/click_sound.mp3';
import clickSoundSource from '@/assets/music/click_sound.mp3';
const router = useRouter();
const route = useRoute();
Expand Down
1 change: 1 addition & 0 deletions src/shims-vue.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ declare module "*.vue" {
const component: DefineComponent<{}, {}, any>;
export default component;
}
declare module '*.mp3';
4 changes: 2 additions & 2 deletions vue.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const { defineConfig } = require("@vue/cli-service");
const { defineConfig } = require('@vue/cli-service');
module.exports = defineConfig({
publicPath: "/minigames/memory",
publicPath: '/minigames/memory',
transpileDependencies: true,
devServer: {
port: 8000,
Expand Down

0 comments on commit 5658745

Please sign in to comment.