Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/custom bar width #238

Merged
merged 6 commits into from
Apr 30, 2024
Merged

Feat/custom bar width #238

merged 6 commits into from
Apr 30, 2024

Conversation

zibs
Copy link
Contributor

@zibs zibs commented Apr 18, 2024

Description

Adds barWidth prop to Bar and BarGroup. This prop lets you adjust the specific bar width in points
Adds barCount prop to Bar and BarGroup. This prop lets you adjust the bar width based on the amount of data points present. So if you had only one data point, but wanted the width to be as if you had 4 data points, you would add barCount={4} as mentioned in: #196 (comment)

Gotta update docs.

Fixes #196

Without the prop and single data point:
Simulator Screenshot - iPhone 15 Pro - 2024-04-18 at 12 38 35

With!

Simulator Screenshot - iPhone 15 Pro - 2024-04-18 at 12 38 44
Simulator Screenshot - iPhone 15 Pro - 2024-04-18 at 12 41 16
Simulator Screenshot - iPhone 15 Pro - 2024-04-18 at 12 41 23

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Checklist: (Feel free to delete this section upon completion)

  • I have included a changeset if this change will require a version change to one of the packages.
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have run yarn run check:code and all checks pass
  • I have created a changeset for new features, patches, or major changes
  • I have added tests that prove my fix is effective or that my feature works
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules

@zibs zibs requested a review from keithluchtel April 18, 2024 19:48
Copy link

changeset-bot bot commented Apr 18, 2024

🦋 Changeset detected

Latest commit: b8ebfb7

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
victory-native Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

vercel bot commented Apr 18, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
victory-native-xl-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 30, 2024 8:49pm

Copy link
Contributor

@masiddee masiddee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. 🚀

One question: do we want to update the example app in this PR?

@zibs zibs merged commit 7fdb397 into main Apr 30, 2024
3 checks passed
@zibs zibs deleted the feat/custom-bar-width branch April 30, 2024 20:50
@github-actions github-actions bot mentioned this pull request Apr 30, 2024
@zibs zibs mentioned this pull request May 9, 2024
10 tasks
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.

Making multiple Bar Charts with bars of a fixed width
3 participants