diff options
author | 2022-07-28 19:30:36 +0200 | |
---|---|---|
committer | 2022-07-28 19:30:36 +0200 | |
commit | 4f599b699901a93444bcc67cbb3b3556a0561ae4 (patch) | |
tree | 472c8d5b23eb576c9f81419fd28354e0cc94e3a0 /src | |
parent | 138149e6f0be91255907a6083887898e5c68882e (diff) | |
download | it-tools-4f599b699901a93444bcc67cbb3b3556a0561ae4.tar.gz it-tools-4f599b699901a93444bcc67cbb3b3556a0561ae4.tar.zst it-tools-4f599b699901a93444bcc67cbb3b3556a0561ae4.zip |
fix(device-information): handle of unknown values
Diffstat (limited to 'src')
-rw-r--r-- | src/tools/device-information/device-information.vue | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/tools/device-information/device-information.vue b/src/tools/device-information/device-information.vue index 4ae939d..d099125 100644 --- a/src/tools/device-information/device-information.vue +++ b/src/tools/device-information/device-information.vue @@ -1,16 +1,17 @@ <template> <n-card v-for="{ name, information } in sections" :key="name" :title="name"> <n-grid cols="1 400:2" x-gap="12" y-gap="12"> - <n-gi v-for="{ label, value } in information" :key="label" class="information"> + <n-gi v-for="{ label, value: { value } } in information" :key="label" class="information"> <n-card :bordered="false" embedded> <div class="label"> {{ label }} </div> <div class="value"> - <n-ellipsis> - {{ value.value }} + <n-ellipsis v-if="value"> + {{ value }} </n-ellipsis> + <div v-else class="undefined-value">unknown</div> </div> </n-card> </n-gi> @@ -90,5 +91,9 @@ const sections = [ font-size: 20px; font-weight: 400; } + + .undefined-value { + opacity: 0.8; + } } </style> |