webapp: apply card-table class to info view cards

the cards in all information views still used a div.card-body around the
table, which added a margin on all sides of the table. to achieve a
unified look, these cards and tables now look the same as the inverter
channel cards.
This commit is contained in:
Bernhard Kirchen 2024-10-26 21:29:38 +02:00 committed by Thomas Basler
parent ad73fd8abd
commit 68d2f7bf29
14 changed files with 18 additions and 16 deletions

View File

@ -1,5 +1,5 @@
<template> <template>
<div :class="['card', addSpace ? 'mt-5' : '']"> <div :class="['card', table ? 'card-table' : '', addSpace ? 'mt-5' : '']">
<div :class="['card-header', textVariant]">{{ text }}</div> <div :class="['card-header', textVariant]">{{ text }}</div>
<div :class="['card-body', 'card-text', centerContent ? 'text-center' : '']"> <div :class="['card-body', 'card-text', centerContent ? 'text-center' : '']">
<slot /> <slot />
@ -14,6 +14,7 @@ export default defineComponent({
props: { props: {
text: String, text: String,
textVariant: String, textVariant: String,
table: Boolean,
addSpace: Boolean, addSpace: Boolean,
centerContent: Boolean, centerContent: Boolean,
}, },

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('firmwareinfo.FirmwareInformation')" textVariant="text-bg-primary"> <CardElement :text="$t('firmwareinfo.FirmwareInformation')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('hardwareinfo.HardwareInformation')" textVariant="text-bg-primary"> <CardElement :text="$t('hardwareinfo.HardwareInformation')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('heapdetails.HeapDetails')" textVariant="text-bg-primary"> <CardElement :text="$t('heapdetails.HeapDetails')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('interfaceapinfo.NetworkInterface')" textVariant="text-bg-primary"> <CardElement :text="$t('interfaceapinfo.NetworkInterface')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -2,6 +2,7 @@
<CardElement <CardElement
:text="$t('interfacenetworkinfo.NetworkInterface', { iface: networkStatus.network_mode })" :text="$t('interfacenetworkinfo.NetworkInterface', { iface: networkStatus.network_mode })"
textVariant="text-bg-primary" textVariant="text-bg-primary"
table
> >
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('memoryinfo.MemoryInformation')" textVariant="text-bg-primary"> <CardElement :text="$t('memoryinfo.MemoryInformation')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<thead> <thead>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('pininfo.PinOverview')" textVariant="text-bg-primary"> <CardElement :text="$t('pininfo.PinOverview')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<thead> <thead>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('radioinfo.RadioInformation')" textVariant="text-bg-primary"> <CardElement :text="$t('radioinfo.RadioInformation')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('taskdetails.TaskDetails')" textVariant="text-bg-primary"> <CardElement :text="$t('taskdetails.TaskDetails')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('wifiapinfo.WifiApInfo')" textVariant="text-bg-primary"> <CardElement :text="$t('wifiapinfo.WifiApInfo')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -1,5 +1,5 @@
<template> <template>
<CardElement :text="$t('wifistationinfo.WifiStationInfo')" textVariant="text-bg-primary"> <CardElement :text="$t('wifistationinfo.WifiStationInfo')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -5,7 +5,7 @@
:show-reload="true" :show-reload="true"
@reload="getMqttInfo" @reload="getMqttInfo"
> >
<CardElement :text="$t('mqttinfo.ConfigurationSummary')" textVariant="text-bg-primary"> <CardElement :text="$t('mqttinfo.ConfigurationSummary')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>
@ -102,7 +102,7 @@
</div> </div>
</CardElement> </CardElement>
<CardElement :text="$t('mqttinfo.HassSummary')" textVariant="text-bg-primary" add-space> <CardElement :text="$t('mqttinfo.HassSummary')" textVariant="text-bg-primary" add-space table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>
@ -155,7 +155,7 @@
</div> </div>
</CardElement> </CardElement>
<CardElement :text="$t('mqttinfo.RuntimeSummary')" textVariant="text-bg-primary" add-space> <CardElement :text="$t('mqttinfo.RuntimeSummary')" textVariant="text-bg-primary" add-space table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>

View File

@ -1,6 +1,6 @@
<template> <template>
<BasePage :title="$t('ntpinfo.NtpInformation')" :isLoading="dataLoading" :show-reload="true" @reload="getNtpInfo"> <BasePage :title="$t('ntpinfo.NtpInformation')" :isLoading="dataLoading" :show-reload="true" @reload="getNtpInfo">
<CardElement :text="$t('ntpinfo.ConfigurationSummary')" textVariant="text-bg-primary"> <CardElement :text="$t('ntpinfo.ConfigurationSummary')" textVariant="text-bg-primary" table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>
@ -21,7 +21,7 @@
</div> </div>
</CardElement> </CardElement>
<CardElement :text="$t('ntpinfo.CurrentTime')" textVariant="text-bg-primary" add-space> <CardElement :text="$t('ntpinfo.CurrentTime')" textVariant="text-bg-primary" add-space table>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-hover table-condensed"> <table class="table table-hover table-condensed">
<tbody> <tbody>