Skip to content

Commit

Permalink
fix: align visualization in chart mode
Browse files Browse the repository at this point in the history
Signed-off-by: Luca Bretting <[email protected]>
  • Loading branch information
luca-dot-sh committed Jan 21, 2025
1 parent 06cfb36 commit 9a7d16c
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@

package de.amosproj3.ziofa.ui.visualization.composables.viewers

import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import de.amosproj3.ziofa.ui.visualization.composables.chart.VicoBar
import de.amosproj3.ziofa.ui.visualization.composables.chart.VicoTimeSeries
import de.amosproj3.ziofa.ui.visualization.data.GraphedData
Expand All @@ -13,7 +15,11 @@ import de.amosproj3.ziofa.ui.visualization.data.GraphedData
fun ChartViewer(data: GraphedData) {

Check warning

Code scanning / detekt

This @Composable function emits content but doesn't have a modifier parameter. See https://twitter.github.io/compose-rules/rules/#when-should-i-expose-modifier-parameters for more information. Warning

This @Composable function emits content but doesn't have a modifier parameter. See https://twitter.github.io/compose-rules/rules/#when-should-i-expose-modifier-parameters for more information.
when (data) {
is GraphedData.TimeSeriesData ->
VicoTimeSeries(seriesData = data.seriesData, chartMetadata = data.metaData)
VicoTimeSeries(
seriesData = data.seriesData,
chartMetadata = data.metaData,
modifier = Modifier.fillMaxSize(),
)

is GraphedData.HistogramData ->
VicoBar(seriesData = data.seriesData, chartMetadata = data.metaData)
Expand Down

0 comments on commit 9a7d16c

Please sign in to comment.