fixed mobile page design

This commit is contained in:
2024-01-25 17:06:37 +01:00
parent 0e38f4891b
commit 4f165b9767
3 changed files with 37 additions and 38 deletions

View File

@@ -1,7 +1,7 @@
<template> <template>
<v-app> <v-app>
<v-sheet :style="`width: ${contentWidth}px; margin-left: ${offsetLeft}px;`" color="transparent"> <v-container style="max-width: 1440px" color="transparent">
<main-nav :style="`padding-left: ${offsetLeft}px; padding-right: ${offsetLeft}px;`" /> <main-nav />
<v-main> <v-main>
<build-server-stats /> <build-server-stats />
@@ -10,7 +10,7 @@
<packages /> <packages />
</v-main> </v-main>
</v-sheet> </v-container>
</v-app> </v-app>
</template> </template>
@@ -18,14 +18,6 @@
import MainNav from '@/components/MainNav.vue' import MainNav from '@/components/MainNav.vue'
import BuildServerStats from '@/components/BuildServerStats.vue' import BuildServerStats from '@/components/BuildServerStats.vue'
import Packages from '@/components/Packages.vue' import Packages from '@/components/Packages.vue'
import { onMounted, ref } from 'vue'
import CurrentlyBuilding from '@/components/CurrentlyBuilding.vue' import CurrentlyBuilding from '@/components/CurrentlyBuilding.vue'
const contentWidth = ref(1440)
const offsetLeft = ref(0)
onMounted(() => {
const innerWidth = window.innerWidth
offsetLeft.value = (innerWidth - contentWidth.value) / 2
})
</script> </script>

View File

@@ -5,35 +5,40 @@
rounded rounded
style="border-radius: 10px; border: 2px solid grey" style="border-radius: 10px; border: 2px solid grey"
variant="elevated"> variant="elevated">
<v-card-title class="d-flex align-center justify-space-between w-100"> <v-card-title>
<span v-if="packageCount.building > 0" class="d-flex"> <v-row style="width: 100%" class="mt-2" align="center" no-gutters>
<v-col class="ms-2" cols="2" v-if="packageCount.building > 0" style="max-width: 130px">
<v-row no-gutters>
<div class="pulsating-circle-amber me-4" style="transform: translateY(10px)" /> <div class="pulsating-circle-amber me-4" style="transform: translateY(10px)" />
<span>Building</span> <span>Building</span>
</span> </v-row>
<span v-else class="d-flex"> </v-col>
<v-col class="ms-2" cols="2" v-else>
<v-row no-gutters>
<div class="pulsating-circle-green me-4" style="transform: translateY(10px)" /> <div class="pulsating-circle-green me-4" style="transform: translateY(10px)" />
<span>Idle</span> <span>Idle</span>
</span> </v-row>
<v-sheet class="d-flex align-center w-100"> </v-col>
<v-col>
<v-progress-linear <v-progress-linear
:max="packageCount.built + packageCount.building + packageCount.queued" :max="packageCount.built + packageCount.building + packageCount.queued"
:model-value="packageCount.built" :model-value="packageCount.built"
color="light-blue" color="light-blue"
height="10" height="10"
rounded rounded
striped striped></v-progress-linear>
style="transform: translateX(-620px)"></v-progress-linear> </v-col>
<span <v-col class="text-grey me-2 justify-end pl-4 text-end"
class="text-grey me-2" style="font-size: 13px; min-width: 200px"
style="font-size: 13px; min-width: 220px; width: 220px; padding-left: 60px"> cols="1">
Last updated Last updated
{{ {{
lastUpdatedSeconds > 59 lastUpdatedSeconds > 59
? rtf.format(-Math.floor(lastUpdatedSeconds / 60), 'minutes') ? rtf.format(-Math.floor(lastUpdatedSeconds / 60), 'minutes')
: rtf.format(-lastUpdatedSeconds, 'seconds') : rtf.format(-lastUpdatedSeconds, 'seconds')
}} }}
</span> </v-col>
</v-sheet> </v-row>
</v-card-title> </v-card-title>
<v-card-text v-if="packageCount.building > 0 || packageCount.queued > 0" class="d-flex"> <v-card-text v-if="packageCount.building > 0 || packageCount.queued > 0" class="d-flex">

View File

@@ -4,7 +4,9 @@ import BuildStats from '@/components/BuildStats.vue'
<template> <template>
<v-app-bar color="#191c2a" style="background: #0d1538"> <v-app-bar color="#191c2a" style="background: #0d1538">
<v-app-bar-title style="margin-left: 0 !important"> <v-container style="max-width: 1440px">
<v-row>
<v-app-bar-title style="align-self: center">
<span style="font-size: 20px"> <span style="font-size: 20px">
ALHP Status ALHP Status
<a <a
@@ -17,9 +19,9 @@ import BuildStats from '@/components/BuildStats.vue'
</span> </span>
</v-app-bar-title> </v-app-bar-title>
<template v-slot:append>
<build-stats /> <build-stats />
</template> </v-row>
</v-container>
</v-app-bar> </v-app-bar>
</template> </template>