Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 63 additions & 0 deletions src/assets/app.scss
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,55 @@ h2 {
}
}

@media (max-width: 550px) {

.table-shadow-box {
padding: 10px !important;

thead {
display: none;
}

tbody {
.shadow-box {
background-color: white;
}
}

tr {
margin-top: 0 !important;
padding: 4px 10px !important;
display: block;
margin-bottom: 6px;

td:first-child {
font-weight: bold;
}

td:nth-child(-n+3) {
text-align: center;
}

td:last-child {
text-align: left;
}

td {
border-bottom: 1px solid $dark-font-color;
display: block;
padding: 4px;

.badge {
margin: auto;
display: block;
width: 30%;
}
}
}
}

}

// Dark Theme override here
.dark {
background-color: #090C10;
Expand Down Expand Up @@ -192,6 +241,20 @@ h2 {
.multiselect__option--selected {
background-color: $dark-bg;
}

@media (max-width: 550px) {
.table-shadow-box {
tbody {
.shadow-box {
background-color: $dark-bg2;

td {
border-bottom: 1px solid $dark-border-color;
}
}
}
}
}
}

/*
Expand Down
9 changes: 5 additions & 4 deletions src/pages/DashboardHome.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
</div>
</div>

<div class="shadow-box" style="margin-top: 25px;overflow-x: scroll">
<div class="shadow-box table-shadow-box" style="overflow-x: scroll">
<table class="table table-borderless table-hover">
<thead>
<tr>
Expand All @@ -37,11 +37,11 @@
</tr>
</thead>
<tbody>
<tr v-for="(beat, index) in displayedRecords" :key="index">
<tr v-for="(beat, index) in displayedRecords" :key="index" :class="{ 'shadow-box': $root.windowWidth <= 550}">
<td>{{ beat.name }}</td>
<td><Status :status="beat.status" /></td>
<td><Datetime :value="beat.time" /></td>
<td>{{ beat.msg }}</td>
<td :class="{ 'border-0':! beat.msg}"><Datetime :value="beat.time" /></td>
<td class="border-0">{{ beat.msg }}</td>
</tr>

<tr v-if="importantHeartBeatList.length === 0">
Expand Down Expand Up @@ -170,6 +170,7 @@ export default {

.shadow-box {
padding: 20px;
margin-top: 25px;
}

table {
Expand Down
8 changes: 4 additions & 4 deletions src/pages/Details.vue
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
</div>
</div>

<div class="shadow-box">
<div class="shadow-box table-shadow-box">
<table class="table table-borderless table-hover">
<thead>
<tr>
Expand All @@ -138,10 +138,10 @@
</tr>
</thead>
<tbody>
<tr v-for="(beat, index) in displayedRecords" :key="index">
<tr v-for="(beat, index) in displayedRecords" :key="index" :class="{ 'shadow-box': $root.windowWidth <= 550}" style="padding: 10px;">
<td><Status :status="beat.status" /></td>
<td><Datetime :value="beat.time" /></td>
<td>{{ beat.msg }}</td>
<td :class="{ 'border-0':! beat.msg}"><Datetime :value="beat.time" /></td>
<td class="border-0">{{ beat.msg }}</td>
</tr>

<tr v-if="importantHeartBeatList.length === 0">
Expand Down