Skip to content

feat: add ZeroLineProperties support to ColumnChart and RowChart#171

Open
saadkhalidkhan wants to merge 4 commits into
ehsannarmani:masterfrom
saadkhalidkhan:feat/column-row-zero-line
Open

feat: add ZeroLineProperties support to ColumnChart and RowChart#171
saadkhalidkhan wants to merge 4 commits into
ehsannarmani:masterfrom
saadkhalidkhan:feat/column-row-zero-line

Conversation

@saadkhalidkhan

Copy link
Copy Markdown

Summary

  • Add zeroLineProperties parameter to ColumnChart and RowChart, reusing the existing ZeroLineProperties model from LineChart
  • Draw an animated horizontal zero line in column charts and a vertical zero line in row charts when negative values are supported
  • Support ZType.Under and ZType.Above layering, matching LineChart behavior
  • Enable zero line in negative-value demo samples (ColumnSample3, RowSample3)
  • Document usage in column and row chart guides

Closes #161

Commits

  1. feat(ColumnChart): add ZeroLineProperties parameter and drawing
  2. feat(RowChart): add ZeroLineProperties parameter and drawing
  3. demo: enable zero line in negative-value chart samples
  4. docs: document ZeroLineProperties for column and row charts

Test plan

  • :compose-charts:compileDebugKotlinAndroid builds successfully
  • :app:compileDebugKotlinAndroid builds successfully
  • Run app and open ColumnSample3 — zero line visible at y=0 between positive/negative bars
  • Run app and open RowSample3 — vertical zero line visible at x=0
  • Verify zero line animates on first render
  • Verify existing charts without zeroLineProperties are unchanged (default disabled)

Add zero line support for column charts with negative values, matching
the existing LineChart ZeroLineProperties API including animation and
under/above z-order.
Add vertical zero line support for row charts with negative values,
using the same ZeroLineProperties model and animation as LineChart.
Show ZeroLineProperties on ColumnSample3 and RowSample3 which already
use mixed positive and negative bar data.
Add zero line usage examples to the column and row chart guides.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] ZeroLineProperties for ColumnChart

1 participant