mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-07-17 13:15:24 +00:00
fix toplist
This commit is contained in:
parent
6ee0016710
commit
46136ab3a8
@ -35,7 +35,7 @@ limitations under the License. -->
|
||||
<el-progress
|
||||
:stroke-width="6"
|
||||
:percentage="(i.value / maxValue) * 100"
|
||||
:color="TextColors[config.color]"
|
||||
:color="TextColors[config.color || 'purple']"
|
||||
:show-text="false"
|
||||
/>
|
||||
</div>
|
||||
@ -61,9 +61,13 @@ const props = defineProps({
|
||||
},
|
||||
intervalTime: { type: Array as PropType<string[]>, default: () => [] },
|
||||
});
|
||||
console.log(props.config.color);
|
||||
const key = computed(() => Object.keys(props.data)[0] || "");
|
||||
const available = computed(
|
||||
() => Array.isArray(props.data[key.value]) && props.data[key.value][0].value
|
||||
() =>
|
||||
Array.isArray(props.data[key.value]) &&
|
||||
props.data[key.value][0] &&
|
||||
props.data[key.value][0].value
|
||||
);
|
||||
const maxValue = computed(() => {
|
||||
if (!(props.data[key.value] && props.data[key.value].length)) {
|
||||
|
Loading…
Reference in New Issue
Block a user