Skip to content

Commit d3630e7

Browse files
committed
Final polish: Increase chart heights and improve duration fill
1. Increased all chart heights from h-96 (384px) to h-[28rem] (448px) 2. Changed duration chart fill from 'true' to 'origin' for proper rendering 3. Increased backgroundColor opacity from 0.15 to 0.2 for better visibility Charts now have more vertical space and duration chart has visible fill.
1 parent ae86d3b commit d3630e7

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

addon/components/widget/api-metrics.hbs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<h4 class="mb-4 text-sm font-semibold text-gray-700 dark:text-gray-200">
55
{{t "developers.component.widget.api-metrics.api-requests"}}
66
</h4>
7-
<div class="h-96">
7+
<div class="h-[28rem]">
88
<Chart @type="line" @datasets={{this.apiRequestData}} @options={{this.chartOptions}} />
99
</div>
1010
</div>
@@ -13,7 +13,7 @@
1313
<h4 class="mb-4 text-sm font-semibold text-gray-700 dark:text-gray-200">
1414
{{t "developers.component.widget.api-metrics.api-error"}}
1515
</h4>
16-
<div class="h-96">
16+
<div class="h-[28rem]">
1717
<Chart @type="line" @datasets={{this.apiErrorDistributionData}} @options={{this.chartOptions}} />
1818
</div>
1919
</div>
@@ -22,7 +22,7 @@
2222
<h4 class="mb-4 text-sm font-semibold text-gray-700 dark:text-gray-200">
2323
{{t "developers.component.widget.api-metrics.webhooks"}}
2424
</h4>
25-
<div class="h-96">
25+
<div class="h-[28rem]">
2626
<Chart @type="line" @datasets={{this.webhookRequestData}} @options={{this.chartOptions}} />
2727
</div>
2828
</div>
@@ -31,7 +31,7 @@
3131
<h4 class="mb-4 text-sm font-semibold text-gray-700 dark:text-gray-200">
3232
{{t "developers.component.widget.api-metrics.webhooks-response"}}
3333
</h4>
34-
<div class="h-96">
34+
<div class="h-[28rem]">
3535
<Chart @type="line" @datasets={{this.webhookRequestTimingData}} @options={{this.chartOptions}} />
3636
</div>
3737
</div>

addon/components/widget/api-metrics.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -283,10 +283,10 @@ export default class WidgetApiMetricsComponent extends Component {
283283
{
284284
label: this.intl.t('developers.component.widget.api-metrics.duration-ms'),
285285
data,
286-
backgroundColor: 'rgba(168, 85, 247, 0.15)',
286+
backgroundColor: 'rgba(168, 85, 247, 0.2)',
287287
borderColor: 'rgb(168, 85, 247)',
288288
borderWidth: 3,
289-
fill: true,
289+
fill: 'origin',
290290
tension: 0.4,
291291
pointRadius: showPoints ? 3 : 0,
292292
pointBackgroundColor: 'rgb(168, 85, 247)',

0 commit comments

Comments
 (0)