From fe568132a13a9a10e07d437f7aac4f8a122c0e76 Mon Sep 17 00:00:00 2001 From: SRP-mango Date: Thu, 23 Nov 2023 01:39:14 +0700 Subject: [PATCH] add next stage of destinationcard --- src/components/DestinationInfoCard.vue | 248 ++++++++++++++++++++++++- src/iconsets/adwaita.ts | 0 src/views/Home.vue | 8 +- 3 files changed, 240 insertions(+), 16 deletions(-) create mode 100644 src/iconsets/adwaita.ts diff --git a/src/components/DestinationInfoCard.vue b/src/components/DestinationInfoCard.vue index c453c03..f4b2f9d 100644 --- a/src/components/DestinationInfoCard.vue +++ b/src/components/DestinationInfoCard.vue @@ -2,13 +2,18 @@ - +
+ + + + {{nearestStructureData.display_name}} + {{destination.subTitle}} + + - {{detial[1].title}} + {{nearestStructureData.lat}} , {{nearestStructureData.lon}} @@ -49,15 +54,150 @@ เพิ่มลงในสถานที่โปรด - + ดูเส้นทาง - + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 นาที + + + + + ย้อนกลับ + + เริ่มการนำทาง + + +
+ + - @@ -65,6 +205,7 @@ import findLocation from '../../icons/Material/find-location.svg'; import clock from '../../icons/Material/clock.svg'; import check from '../../icons/Material/check-round.svg'; +import DestinationInfoCard from '@/components/DestinationInfoCard.vue'; const destination = { title: "อนุสาวรีย์ชัยสมรภูมิ", subTitle: "ราชเทวี , กรุงเทพมหานคร" @@ -97,14 +238,28 @@ export default { data() { return { showPopup: true, + showRoute: false, }; }, + computed: { + cardHeight() { + return this.showRoute ? '45vh' : '60vh'; + }, + }, methods: { closePopup() { this.showPopup = false; this.onClose(); }, + viewRoute() { + this.showRoute = true; + }, + viewPopup(){ + this.showPopup = true; + this.showRoute = false; + } }, + }; @@ -145,5 +300,80 @@ export default { width: 100%; height: 45vh; } + +.title-text +{ + color: rgba(0, 0, 0, 1); + font-style: normal; + font-size: 24px; + font-weight: 700; + line-height: 1.2; + letter-spacing: 0px; + text-decoration: none; + text-transform: none; +} + +.sutitle-text{ + color: rgba(155, 155, 155, 1); + font-style: normal; + font-size: 16px; + font-weight: 400; + line-height: 1.2; + letter-spacing: 0px; + text-decoration: none; + text-transform: none; +} + +.icon-walk { + background-color: #000000; + -webkit-mask: url(icons/Adwaita/walk.svg) no-repeat center; + mask: url(icons/Adwaita/walk.svg) no-repeat center; +} +.icon-wheelchair { + background-color: #000000; + -webkit-mask: url(icons/Adwaita/wheelchair.svg) no-repeat center; + mask: url(icons/Adwaita/wheelchair.svg) no-repeat center; +} +.icon-plus { + background-color: #000000; + -webkit-mask: url(icons/Adwaita/plus.svg) no-repeat center; + mask: url(icons/Adwaita/plus.svg) no-repeat center; +} +.icon-vertical-arrows { + background-color: #000000; + -webkit-mask: url(icons/Adwaita/vertical-arrows.svg) no-repeat center; + mask: url(icons/Adwaita/vertical-arrows.svg) no-repeat center; +} +.icon-flag { + background-color: #000000; + -webkit-mask: url(icons/Adwaita/flag.svg) no-repeat center; + mask: url(icons/Adwaita/flag.svg) no-repeat center; +} + +.btn-toggle +{ + border-radius: 10px; + background-color: rgba(230, 230, 230, 1); +} + +.btn-toggle .btn +{ + border-radius: 0px; + background-color: rgba(230, 230, 230, 1); +} + +.v-input__control +{ + + max-height: 6vh; + max-width: 50vw; +} + +.v-field__input +{ + /* font-size: 14px; */ + padding: 0; +} + \ No newline at end of file diff --git a/src/iconsets/adwaita.ts b/src/iconsets/adwaita.ts new file mode 100644 index 0000000..e69de29 diff --git a/src/views/Home.vue b/src/views/Home.vue index 86c00a9..71bf7c1 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -5,12 +5,6 @@ class="router-view" /> - - { const lon = parseFloat(result.lon); center.value = [lon, lat]; showSearchBar.value = false; - popupData.value = result; // Set the selected search result as popupData + popupData.value = result; }; const performSearch = async () => {