diff --git a/package.json b/package.json index a26079e..8a31dfd 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "version": "0.1.0", "private": true, "scripts": { - "serve": "vue-cli-service serve --port 3000", + "serve": "vue-cli-service serve --host 0.0.0.0 --port 3000", "build": "vue-cli-service build", "lint": "vue-cli-service lint" }, diff --git a/src/assets/img/backBtn.png b/src/assets/img/backBtn.png new file mode 100644 index 0000000..425206e Binary files /dev/null and b/src/assets/img/backBtn.png differ diff --git a/src/assets/img/backBtnWhite.png b/src/assets/img/backBtnWhite.png new file mode 100644 index 0000000..8a016f0 Binary files /dev/null and b/src/assets/img/backBtnWhite.png differ diff --git a/src/assets/img/beodomiLogoText.png b/src/assets/img/beodomiLogoText.png new file mode 100644 index 0000000..6878a2c Binary files /dev/null and b/src/assets/img/beodomiLogoText.png differ diff --git a/src/assets/img/wholeTextIcon.png b/src/assets/img/wholeTextIcon.png new file mode 100644 index 0000000..6304a68 Binary files /dev/null and b/src/assets/img/wholeTextIcon.png differ diff --git a/src/assets/img/wholeTextIconYellow.png b/src/assets/img/wholeTextIconYellow.png new file mode 100644 index 0000000..c0997ba Binary files /dev/null and b/src/assets/img/wholeTextIconYellow.png differ diff --git a/src/assets/scss/_variables.scss b/src/assets/scss/_variables.scss index 55de0a7..76b9c71 100644 --- a/src/assets/scss/_variables.scss +++ b/src/assets/scss/_variables.scss @@ -1,4 +1,4 @@ -$primary: #082220; +$primary: #152827; $secondary: #ffdb1d; $lightGray: #f3f3f3; $gray: #d9d9d9; diff --git a/src/components/NavComp.vue b/src/components/NavComp.vue new file mode 100644 index 0000000..f268dc2 --- /dev/null +++ b/src/components/NavComp.vue @@ -0,0 +1,129 @@ + + + + + diff --git a/src/store/passsengerStore.js b/src/store/passsengerStore.js index 862b28f..ca28b62 100644 --- a/src/store/passsengerStore.js +++ b/src/store/passsengerStore.js @@ -11,12 +11,9 @@ export const usePassengerStore = defineStore('passenger', () => { */ function announcePageContent(content, htmlElement) { htmlElement.setAttribute('aria-live', 'assertive'); - htmlElement.innerText = content; - console.log(content); setTimeout(function () { - htmlElement.removeAttribute(htmlElement); - htmlElement.innerText(''); + htmlElement.removeAttribute('aria-live'); }, 100); } return { diff --git a/src/views/passenger/BusSearchView.vue b/src/views/passenger/BusSearchView.vue index 93bad3d..c38cf23 100644 --- a/src/views/passenger/BusSearchView.vue +++ b/src/views/passenger/BusSearchView.vue @@ -1,19 +1,26 @@ @@ -22,14 +29,19 @@ import VoiceComp from '@/components/VoiceComp.vue'; import ToggleComp from '@/components/ToggleComp.vue'; import {useRouter} from 'vue-router'; + import NavComp from '@/components/NavComp.vue'; export default { name: 'BusSearchView', components: { VoiceComp, ToggleComp, + NavComp, }, setup() { + // 읽어줄 전체 텍스트 + const wholeText = ref('버튼을 누른 후 검색어를 말해주세요. 음성 검색 버튼 '); + const title = ref('버튼을 누른 후 검색어를 말해주세요'); const input = ref(''); const searchType = ref('voice'); @@ -59,39 +71,14 @@ }, 3000); }; }; - - // 전체 읽어주기 기능 - const ariaLive = ref('polite'); - const ariaHidden = ref(''); - const pageContent = ref(''); - - const readWholeText = () => { - const contentElement = document.getElementById('container'); - const content = contentElement.innerText; - - // 읽어주기 전 잠시 숨김처리 - ariaHidden.value = true; - - // 스크린 리더에게 전체 내용을 읽어달라는 요청 - ariaLive.value = 'assertive'; - pageContent.value = content; - - console.log(pageContent.value); - // pageContent.value = ''; - - // 읽기가 완료된 후 다시 숨김처리 해제 - setTimeout(() => { - ariaLive.value = 'polite'; - ariaHidden.value = ''; - }, 100); - }; - const getSearchType = value => { searchType.value = value; if (searchType.value == 'voice') { bg_color.value = '#fff'; + wholeText.value = '음성으로 버스 노선 검색. 버튼을 누른 후 검색어를 말해주세요. 음성 검색 버튼 '; } else { bg_color.value = '#082220'; + wholeText.value = '키보드로 버스 노선 검색. 검색어를 입력하세요.'; } }; @@ -103,15 +90,12 @@ }; return { + wholeText, title, searchType, input, bg_color, voice_result, - ariaLive, - ariaHidden, - pageContent, - readWholeText, getSearchType, search_keyboard, }; diff --git a/src/views/passenger/FavoriteStopView.vue b/src/views/passenger/FavoriteStopView.vue index 153a7cb..c160cf1 100644 --- a/src/views/passenger/FavoriteStopView.vue +++ b/src/views/passenger/FavoriteStopView.vue @@ -1,17 +1,19 @@