mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2025-07-26 22:26:08 +02:00
Fix Polar sizing
- Note: Not adaptive to viewport size, but will snap to grid
This commit is contained in:
@@ -22,8 +22,7 @@
|
||||
LineElement
|
||||
);
|
||||
|
||||
export let width
|
||||
export let height
|
||||
export let size
|
||||
export let metrics
|
||||
export let cluster
|
||||
export let jobMetrics
|
||||
@@ -88,8 +87,19 @@
|
||||
}
|
||||
|
||||
// No custom defined options but keep for clarity
|
||||
const options = {}
|
||||
const options = {
|
||||
maintainAspectRatio: false,
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<Radar {data} {options} {width} {height}/>
|
||||
<div class="chart-container">
|
||||
<Radar {data} {options} width={size} height={size}/>
|
||||
</div>
|
||||
|
||||
<style>
|
||||
.chart-container {
|
||||
margin: auto;
|
||||
position: relative;
|
||||
}
|
||||
</style>
|
Reference in New Issue
Block a user