mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-07-17 04:15:25 +00:00
fix table
This commit is contained in:
parent
fe3a40e397
commit
b78414a307
@ -16,17 +16,11 @@ limitations under the License. -->
|
||||
<template>
|
||||
<div class="chart-table">
|
||||
<div ref="chartTable">
|
||||
<div
|
||||
class="row header flex-h"
|
||||
:style="`width: ${nameWidth + initWidth}px`"
|
||||
>
|
||||
<div class="row header flex-h" :style="`width: 100%`">
|
||||
<div class="name" :style="`width: ${nameWidth}px`">
|
||||
{{ config.tableHeaderCol1 || t("name") }}
|
||||
<i class="r cp" ref="draggerName">
|
||||
<Icon iconName="settings_ethernet" size="middle" />
|
||||
</i>
|
||||
</div>
|
||||
<div class="value-col" v-if="showTableValues">
|
||||
<div class="value-col" v-if="config.showTableValues">
|
||||
{{ config.tableHeaderCol2 || t("value") }}
|
||||
</div>
|
||||
</div>
|
||||
@ -34,10 +28,10 @@ limitations under the License. -->
|
||||
class="row flex-h"
|
||||
v-for="key in dataKeys"
|
||||
:key="key"
|
||||
:style="`width: ${nameWidth + initWidth}px`"
|
||||
:style="`width: 100%`"
|
||||
>
|
||||
<div :style="`width: ${nameWidth}px`">{{ key }}</div>
|
||||
<div class="value-col" v-if="showTableValues">
|
||||
<div class="value-col" v-if="config.showTableValues">
|
||||
{{
|
||||
config.metricTypes[0] === "readMetricsValue"
|
||||
? data[key]
|
||||
@ -75,7 +69,6 @@ const chartTable = ref<Nullable<HTMLElement>>(null);
|
||||
const initWidth = ref<number>(0);
|
||||
const nameWidth = ref<number>(0);
|
||||
const draggerName = ref<Nullable<HTMLElement>>(null);
|
||||
const showTableValues = ref<boolean>(props.config.showTableValues || false);
|
||||
onMounted(() => {
|
||||
if (!chartTable.value) {
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user