Feature: Combine dynamic month label with moving month label in x axis

Co-authored-by: @livgm
This commit is contained in:
bl00dymarie
2024-04-03 20:39:59 +02:00
parent 35224ba722
commit a54e48b17e
3 changed files with 38 additions and 7 deletions
+3 -1
View File
@@ -14,13 +14,14 @@ const YAxis = ({
symptomsSectionHeight,
shouldShowTemperatureColumn,
xAxisHeight,
computedDate,
}) => {
const symptomIconHeight = symptomsSectionHeight / symptomsToDisplay.length
return (
<View>
{shouldShowTemperatureColumn && <TickList height={height} />}
<ChartLegend height={xAxisHeight} />
<ChartLegend height={xAxisHeight} currentDate={computedDate} />
<View style={[styles.yAxis, { height: symptomsSectionHeight }]}>
{symptomsToDisplay.map((symptom) => (
<SymptomIcon
@@ -40,6 +41,7 @@ YAxis.propTypes = {
symptomsSectionHeight: PropTypes.number,
shouldShowTemperatureColumn: PropTypes.bool,
xAxisHeight: PropTypes.number.isRequired,
computedDate: PropTypes.string,
}
const styles = StyleSheet.create({