From 5c3b60eb588e971ff126ffc1c25ec5f825bb3bc9 Mon Sep 17 00:00:00 2001 From: Spythere Date: Sat, 11 Jul 2020 15:06:33 +0200 Subject: [PATCH] =?UTF-8?q?Poprawki=20wygl=C4=85du=20appbaru,=20dodanie=20?= =?UTF-8?q?wsparcia=20dla=20niewpisanych=20scenerii?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/index.html | 2 + src/App.vue | 76 ++++++++++++++++++++++++----- src/assets/icon-dispatcher.svg | 1 + src/assets/icon-train.svg | 1 + src/components/ui/Card.vue | 11 +++-- src/components/ui/Clock.vue | 32 ++++++++++++ src/components/ui/Options.vue | 2 +- src/components/utils/ListFilter.vue | 20 +++++--- src/data/stations.json | 23 +++++++++ src/store/modules/store.ts | 24 ++++++--- src/views/Home.vue | 2 + 11 files changed, 164 insertions(+), 30 deletions(-) create mode 100644 src/assets/icon-dispatcher.svg create mode 100644 src/assets/icon-train.svg create mode 100644 src/components/ui/Clock.vue diff --git a/public/index.html b/public/index.html index e17ed34..bfdcb6b 100644 --- a/public/index.html +++ b/public/index.html @@ -6,6 +6,8 @@ + Stacjownik diff --git a/src/App.vue b/src/App.vue index 28f6cda..8b163a0 100644 --- a/src/App.vue +++ b/src/App.vue @@ -7,16 +7,29 @@ trainlogo wnik - Scenerie online: {{stationCount}} | Maszyniści online: {{ trainCount }} -
-
+
+
-
+
+ +
+ +
+ + icon dispatcher + {{stationCount}} + + + + {{trainCount}} + icon train + +
@@ -38,11 +51,12 @@ import { mapGetters, mapActions } from "vuex"; import Error from "@/components/states/Error.vue"; import Loading from "@/components/states/Loading.vue"; import Options from "@/components/ui/Options.vue"; +import Clock from "@/components/ui/Clock.vue"; // import ListFilter from "@/components/utils/ListFilter.vue"; export default Vue.extend({ name: "App", - components: { Error, Loading, Options }, + components: { Error, Loading, Options, Clock }, computed: mapGetters({ stations: "getStations", trainCount: "getTrainCount", @@ -79,6 +93,19 @@ export default Vue.extend({ font-size: 16px; } +::-webkit-scrollbar { + width: 15px; + + &-track { + background: #222; + } + + &-thumb { + border-radius: 1rem; + background: #777; + } +} + html { scroll-behavior: smooth; } @@ -171,6 +198,8 @@ ul { align-items: center; justify-content: center; + width: 100%; + &-spaced { justify-content: space-between; } @@ -183,8 +212,8 @@ ul { .app { background: $bgCol; color: white; - width: 100%; - overflow: hidden; + + font-size: calc(1rem + 2.1vw); &-container { display: grid; @@ -197,29 +226,52 @@ ul { &-header { background: #333; - padding: 0.4rem; + padding: 0.1em; & > .brand-name { - font-size: calc(1rem + 3.5vw); + font-size: 1.1em; img { - width: calc(1rem + 2.3vw); + width: 0.8em; } } .online { - font-size: calc(0.3rem + 0.8vw); + font-size: 0.35em; } } &-bar { + display: flex; + justify-content: space-between; + position: sticky; - font-size: calc(0.8rem + 0.2vw); top: 0; + font-size: 0.3em; background: #222; } } +.bar { + &-right { + font-size: 1.35em; + display: flex; + } +} + +.counter { + display: flex; + align-items: center; + color: $accentCol; + + margin: 0 0.3em; + + img { + width: 1.4em; + margin: 0 0.1em; + } +} + footer { background: #111; padding: 0.3rem; diff --git a/src/assets/icon-dispatcher.svg b/src/assets/icon-dispatcher.svg new file mode 100644 index 0000000..9ef4fd6 --- /dev/null +++ b/src/assets/icon-dispatcher.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/assets/icon-train.svg b/src/assets/icon-train.svg new file mode 100644 index 0000000..352a90f --- /dev/null +++ b/src/assets/icon-train.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/components/ui/Card.vue b/src/components/ui/Card.vue index ece7e09..7a25944 100644 --- a/src/components/ui/Card.vue +++ b/src/components/ui/Card.vue @@ -1,7 +1,9 @@