-
Notifications
You must be signed in to change notification settings - Fork 7
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
tweak(tupaiaWeb): RN-249: getting x-Name in viz export #5886
Conversation
@@ -252,7 +252,6 @@ export const CartesianChart = ({ | |||
<Legend | |||
verticalAlign={verticalAlign} | |||
align={align} | |||
layout={layout} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'layout' property (whether 'horizontal' or 'vertical') does not affect the custom component as expected. This is because the component already has its own styling, including alignment and flex properties. Therefore, the layout property is not needed in this case.
return { | ||
value: label, | ||
fill: fillColor, | ||
offset: -5, | ||
offset: isExporting ? -50 : -5, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is intended to prevent overlapping between tick labels and the x-axis. Given the tick labels are restricted to a maximum number of characters (using ellipses for longer text) this approach should resolve the issue.
@@ -76,6 +76,7 @@ interface XAxisProps { | |||
|
|||
export const XAxis = ({ config, report, isExporting = false, isEnlarged = false }: XAxisProps) => { | |||
const fillColor = isExporting ? DARK_BLUE : getContrastTextColor(); | |||
const tickMargin = isExporting ? 20 : 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the space between the x-axis label and tick label.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, nice work
* tweak(centralServer): RN-1351: Handle bad DHIS2 sync requests (#5887) Throw an error and register bad requests on dhis sync queue * tweak(datatrakWeb): RN-1438: Upgrade React Query to V4 (#5868) * Bumping react-query * Update render.tsx * fixing Reports.test.tsx * navigation bug fix * removed logging * tweak(adminPanel): RN-1439: Upgrade React Query to V4 (#5875) * bumping to v4 * Update yarn.lock * tweak(psss): RN-1442: Upgrade React Query to V4 (#5874) * upgrade * Update yarn.lock * tweak(lesmis): RN-1441: Upgrade React Query to V4 (#5873) * upgrade * Update yarn.lock * tweak(tupaiaWeb): RN-1440: Upgrade React Query to V4 (#5870) * Bumping react-query * Bumping react-query to v4 * Update render.tsx * GitAction fix * fixing Reports.test.tsx * navigation bug fix * review update * removed logging * Update yarn.lock * Update yarn.lock * Update VerifyEmailPage.tsx * Update useReportPreview.js * fix(adminPanel): Miscellaneous Bug fixes (Tiny) (#5891) * bugfix * update * updates * tweak(tupaiaWeb): RN-1437: Download files visual restyle (#5889) * Common download files component * PR fix --------- Co-authored-by: Salman <114740396+hrazasalman@users.noreply.github.com>
merge: update branch with latest dev
merge: update branch with latest dev
Issue #: RN-249
Changes:
Screenshots:
Before:
After: