diff --git a/src/components/Global/ActionButton.vue b/src/components/Global/ActionButton.vue index 02b0464..f744817 100644 --- a/src/components/Global/ActionButton.vue +++ b/src/components/Global/ActionButton.vue @@ -1,6 +1,8 @@ @@ -15,9 +17,6 @@ export default defineComponent({}); @import "../../styles/responsive"; .action-btn { - display: flex; - align-items: center; - background: #333; border: none; @@ -58,4 +57,9 @@ export default defineComponent({}); background: #5c5c5c; } } + +.button_content { + display: flex; + align-items: center; +} \ No newline at end of file diff --git a/src/components/StationsView/StationFilterCard.vue b/src/components/StationsView/StationFilterCard.vue index 274dbcd..37ec8a4 100644 --- a/src/components/StationsView/StationFilterCard.vue +++ b/src/components/StationsView/StationFilterCard.vue @@ -1,57 +1,60 @@ @@ -82,13 +87,15 @@ import FilterOption from "./FilterOption.vue"; export default defineComponent({ components: { ActionButton, FilterOption }, - props: ["showCard", "exit"], emits: ["changeFilterValue", "invertFilters", "resetFilters"], data: () => ({ + filterIcon: require("@/assets/icon-filter2.svg"), + inputs: { ...inputData }, saveOptions: false, STORAGE_KEY: "options_saved", + isVisible: false, }), mounted() { @@ -160,7 +167,11 @@ export default defineComponent({ }, closeCard() { - this.exit(); + this.isVisible = false; + }, + + toggleCard() { + this.isVisible = !this.isVisible; }, }, }); @@ -170,6 +181,19 @@ export default defineComponent({ @import "../../styles/responsive"; @import "../../styles/card"; +.card-anim { + &-enter-active, + &-leave-active { + transition: all $animDuration $animType; + } + + &-enter-from, + &-leave-to { + transform: translate(-50%, -50%) scale(0.85); + opacity: 0; + } +} + .card { > section { margin-top: 1em; diff --git a/src/components/TrainsView/TrainStats.vue b/src/components/TrainsView/TrainStats.vue index 46a0567..83c262f 100644 --- a/src/components/TrainsView/TrainStats.vue +++ b/src/components/TrainsView/TrainStats.vue @@ -1,11 +1,9 @@ @@ -68,7 +61,6 @@ export default defineComponent({ trainIcon: require("@/assets/icon-train.svg"), timetableIcon: require("@/assets/icon-timetable.svg"), dolarIcon: require("@/assets/icon-dolar.svg"), - filterIcon: require("@/assets/icon-filter2.svg"), filterCardOpen: false, modalHidden: true, STORAGE_KEY: "options_saved", @@ -151,7 +143,7 @@ export default defineComponent({ this.filterManager.invertFilters(); }, closeCard() { - this.focusedStationName = ""; + this.filterCardOpen = false; }, setFocusedStation(name: string) { this.focusedStationName = this.focusedStationName == name ? "" : name; @@ -164,19 +156,6 @@ export default defineComponent({ @import "../styles/variables.scss"; @import "../styles/responsive.scss"; -.card-anim { - &-enter-active, - &-leave-active { - transition: all $animDuration $animType; - } - - &-enter-from, - &-leave-to { - transform: translate(-50%, -50%) scale(0.85); - opacity: 0; - } -} - @keyframes blinkAnim { 0%, 100% {