chore: general fixes

This commit is contained in:
2024-05-09 16:40:53 +02:00
parent 366ff91f60
commit 122532f0ed
5 changed files with 16 additions and 22 deletions
+5 -5
View File
@@ -1,8 +1,8 @@
<template> <template>
<div class="app_container"> <div class="app_container">
<UpdateModal <UpdateModal
:update-modal-open="updateModalOpen" :update-modal-open="isUpdateModalOpen"
@toggle-modal="() => (updateModalOpen = false)" @toggle-modal="() => (isUpdateModalOpen = false)"
/> />
<Tooltip /> <Tooltip />
@@ -27,7 +27,7 @@
&copy; &copy;
<a href="https://td2.info.pl/profile/?u=20777" target="_blank">Spythere</a> <a href="https://td2.info.pl/profile/?u=20777" target="_blank">Spythere</a>
{{ new Date().getUTCFullYear() }} | {{ new Date().getUTCFullYear() }} |
<button class="btn--text" @click="() => (updateModalOpen = true)"> <button class="btn--text" @click="() => (isUpdateModalOpen = true)">
v{{ VERSION }}{{ isOnProductionHost ? '' : 'dev' }} v{{ VERSION }}{{ isOnProductionHost ? '' : 'dev' }}
</button> </button>
@@ -78,7 +78,7 @@ export default defineComponent({
apiStore: useApiStore(), apiStore: useApiStore(),
tooltipStore: useTooltipStore(), tooltipStore: useTooltipStore(),
updateModalOpen: false, isUpdateModalOpen: false,
currentLang: 'pl', currentLang: 'pl',
isOnProductionHost: location.hostname == 'stacjownik-td2.web.app', isOnProductionHost: location.hostname == 'stacjownik-td2.web.app',
@@ -130,7 +130,7 @@ export default defineComponent({
releaseURL: releaseData.html_url releaseURL: releaseData.html_url
}; };
this.updateModalOpen = this.isUpdateModalOpen =
storageVersion != version || import.meta.env.VITE_UPDATE_TEST === 'test'; storageVersion != version || import.meta.env.VITE_UPDATE_TEST === 'test';
} catch (error) { } catch (error) {
console.error(`Wystąpił błąd podczas pobierania danych z API GitHuba: ${error}`); console.error(`Wystąpił błąd podczas pobierania danych z API GitHuba: ${error}`);
+6 -7
View File
@@ -3,7 +3,8 @@
<div class="modal-content"> <div class="modal-content">
<h1 style="margin-bottom: 0.5em">🚀 {{ $t('update.title') }}</h1> <h1 style="margin-bottom: 0.5em">🚀 {{ $t('update.title') }}</h1>
<div class="features-body" v-html="htmlChangelog"></div> <div class="features-body" v-if="htmlChangelog != ''" v-html="htmlChangelog"></div>
<div class="no-features" v-else>{{ $t('update.no-data') }}</div>
<button class="btn btn--action" ref="confirm-btn" @click="toggleModal(false)"> <button class="btn btn--action" ref="confirm-btn" @click="toggleModal(false)">
{{ $t('update.confirm') }} {{ $t('update.confirm') }}
@@ -93,16 +94,14 @@ export default defineComponent({
display: grid; display: grid;
grid-template-rows: auto 1fr auto; grid-template-rows: auto 1fr auto;
gap: 0.5em; gap: 0.5em;
padding: 1em 2em; padding: 1em;
min-height: 700px; min-height: 700px;
overflow: auto; overflow: auto;
text-align: justify;
} }
hr.separator { .no-features {
margin: 0.5em 0; text-align: center;
padding: 0;
height: 3px;
background-color: #fff;
} }
button { button {
@@ -69,8 +69,8 @@
minimumHours == 0 minimumHours == 0
? $t('filters.now') ? $t('filters.now')
: minimumHours < 8 : minimumHours < 8
? minimumHours + $t('filters.hour') ? minimumHours + $t('filters.hour')
: $t('filters.no-limit') : $t('filters.no-limit')
}}</span> }}</span>
<button class="btn--action" @click="addHour">+</button> <button class="btn--action" @click="addHour">+</button>
</span> </span>
@@ -442,23 +442,16 @@ h3.section-header {
} }
.card_actions { .card_actions {
width: 100%;
padding: 0.5em; padding: 0.5em;
.filter-option {
max-width: 50%;
margin: 0 auto;
}
.action-buttons { .action-buttons {
display: flex; display: flex;
gap: 0.5em; gap: 0.5em;
width: 100%;
margin-top: 0.5em; margin-top: 0.5em;
button { button {
width: 50%; width: 100%;
margin: 0 auto; margin: 0 auto;
padding: 0.5em; padding: 0.5em;
+1
View File
@@ -29,6 +29,7 @@
"update": { "update": {
"title": "Stacjownik update!", "title": "Stacjownik update!",
"confirm": "ROGER THAT!", "confirm": "ROGER THAT!",
"no-data": "No data about the latest app update has been found",
"info-1": "This changelog will be available to see once again after clicking the version number in the footer", "info-1": "This changelog will be available to see once again after clicking the version number in the footer",
"info-2": "The full app changelog available on <a href='https://github.com/Spythere/stacjownik' target='_blank'>the project's GitHub</a>" "info-2": "The full app changelog available on <a href='https://github.com/Spythere/stacjownik' target='_blank'>the project's GitHub</a>"
}, },
+1
View File
@@ -29,6 +29,7 @@
"update": { "update": {
"title": "Aktualizacja Stacjownika!", "title": "Aktualizacja Stacjownika!",
"confirm": "PRZYJĄŁEM!", "confirm": "PRZYJĄŁEM!",
"no-data": "Nie znaleziono informacji o ostatnich zmianach w aplikacji",
"info-1": "Ten changelog będzie zawsze dostępny po kliknięciu numeru wersji w stopce strony", "info-1": "Ten changelog będzie zawsze dostępny po kliknięciu numeru wersji w stopce strony",
"info-2": "Pełny changelog dostępny na <a href='https://github.com/Spythere/stacjownik' target='_blank'>GitHubie projektu</a>" "info-2": "Pełny changelog dostępny na <a href='https://github.com/Spythere/stacjownik' target='_blank'>GitHubie projektu</a>"
}, },