Open JohnBerd opened 1 year ago
I don't have time at the moment for making a PR, but it seems like values are not declared in the typescript part even they are read in the Swift code, here is my patch. center should be the default value as it is in the Android side.
diff --git a/node_modules/@types/react-native-charts-wrapper/index.d.ts b/node_modules/@types/react-native-charts-wrapper/index.d.ts
index 48e804a..2fcb5a5 100755
--- a/node_modules/@types/react-native-charts-wrapper/index.d.ts
+++ b/node_modules/@types/react-native-charts-wrapper/index.d.ts
@@ -4,7 +4,7 @@
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
import { Component } from 'react';
-import { ViewProps, NativeSyntheticEvent, processColor } from 'react-native';
+import { NativeSyntheticEvent, processColor, ViewProps } from 'react-native';
export type EasingType =
| 'Linear'
@@ -195,6 +195,7 @@ export interface ChartBase extends ViewProps {
markerColor?: Color | undefined;
textColor?: Color | undefined;
textSize?: number | undefined;
+ textAlign?: 'auto' | 'justify' | 'center' | 'left' | 'right'
} | undefined;
highlights?: Array<{
So the marker props can take a textAlign value.
*Do read files under `lib/` before reporting issues, you can find all the config there, all of them are straightforward.**
Expected Behavior
Text should be in center of the marker
Actual Behavior
Text is at the left
Screenshots
Steps to Reproduce the Problem
Create a chart with markers
Specifications