Skip to content

Commit

Permalink
fix: chart responsiveness (#121)
Browse files Browse the repository at this point in the history
  • Loading branch information
andreiio authored Dec 1, 2024
1 parent 81343e6 commit b856727
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 1 addition & 2 deletions app/Livewire/Charts/TopCountiesChart.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ protected function getOptions(): RawJs

return RawJs::make(<<<'JS'
{
maintainAspectRatio: false,
aspectRatio: 0.15,
indexAxis: 'y',
scales: {
Expand All @@ -127,7 +126,7 @@ protected function getOptions(): RawJs
callbacks: {
label: (context) => {
let label = context.dataset.label;
console.log(context);
if (label) {
label += ': ';
}
Expand Down
1 change: 1 addition & 0 deletions app/Livewire/Charts/TopLocalitiesChart.php
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ protected function getOptions(): RawJs

return RawJs::make(<<<'JS'
{
aspectRatio: 1,
indexAxis: 'y',
scales: {
y: {
Expand Down

0 comments on commit b856727

Please sign in to comment.