mirror of
https://github.com/DI0IK/homepage-plus.git
synced 2025-07-17 18:29:48 +00:00
Allow widget field visibility to be configurable
This commit is contained in:
parent
756f6310af
commit
9b7d6b196f
30 changed files with 246 additions and 219 deletions
|
@ -17,26 +17,26 @@ export default function Component({ service }) {
|
|||
|
||||
if (!speedtestData) {
|
||||
return (
|
||||
<Container>
|
||||
<Block label={t("speedtest.download")} />
|
||||
<Block label={t("speedtest.upload")} />
|
||||
<Block label={t("speedtest.ping")} />
|
||||
<Container service={service}>
|
||||
<Block label="speedtest.download" />
|
||||
<Block label="speedtest.upload" />
|
||||
<Block label="speedtest.ping" />
|
||||
</Container>
|
||||
);
|
||||
}
|
||||
|
||||
return (
|
||||
<Container>
|
||||
<Container service={service}>
|
||||
<Block
|
||||
label={t("speedtest.download")}
|
||||
label="speedtest.download"
|
||||
value={t("common.bitrate", { value: speedtestData.data.download * 1024 * 1024 })}
|
||||
/>
|
||||
<Block
|
||||
label={t("speedtest.upload")}
|
||||
label="speedtest.upload"
|
||||
value={t("common.bitrate", { value: speedtestData.data.upload * 1024 * 1024 })}
|
||||
/>
|
||||
<Block
|
||||
label={t("speedtest.ping")}
|
||||
label="speedtest.ping"
|
||||
value={t("common.ms", {
|
||||
value: speedtestData.data.ping,
|
||||
style: "unit",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue