Skip to content

Releases: Abhinandan-Kushwaha/react-native-gifted-charts

v1.4.30

23 Aug 22:07
918c25a
Compare
Choose a tag to compare

🎉 1.4.30

✨ Features added-

animateOnDataChange now works evevn if the lehgth of data array is changed. Earlier it worked for data changes with same length and threw error on changing the length of data array.

See- #791

This is solved by adding dummy points to the data having lesser number of points. Dummy points are added carefully using the pointsWithPaddedRepititions util function from gifted-charts-core.

v1.4.29

12 Aug 23:33
26ca0be
Compare
Choose a tag to compare

🎉 1.4.29

✨ Features added-

  1. The prop topLabelTextStyle now works for stacked Bar charts just like it used to work for simple Bar charts. See #446 (comment)

  2. Secondary Y axis with negative values in secondary data or dataSet with isSecondary: true sets are now supported. Independent height, stepHeight, stepValue, mostNegativeValue, noOfSectionsBelowXAxis for primary and secondary Y-axes below origin supported.

🐛 Bug fixes

Fixed the issue- Negative steps and values in in second y axis are incorrect position. See #775

🔨 Refactor

  1. Removed unnecessary interpolation for animations in Line charts.

  2. Passed containerHeightIncludingBelowXAxis to the renderChartContent method from the BarAndLineChartsWrapper component. This will ensure a consistent value of containerHeightIncludingBelowXAxis.

  3. Updated the util (maxAndMinUtil) to compute the value of minItem in case of roundToDigits:true in gifted-charts-core.

  4. Moved the computation of below variables from getHorizSectionVals to useBarAndLineChartsWrapper in gifted-charts-core.

    1. secondaryMaxItem
    2. secondaryMinItem
    3. secondaryStepValue
    4. secondaryNegativeStepValue
    5. secondaryNoOfSectionsBelowXAxis

v1.4.28

05 Aug 21:42
093712a
Compare
Choose a tag to compare

🎉 1.4.28

✨ Features added-

  1. Added the prop referenceLinesOverChartContent to Line and Area charts (earlier available for Bar charts only). See #761

  2. Added support for external Labels in Pie and Donut charts. See #763

    It uses the below props-

    1. showExternalLabels (boolean)
    2. labelLineConfig (object of LabelLineConfig type)
    3. externalLabelComponent (svg component for label, a callback function with 2 parameters- item and index)

The labelLineConfig prop is an object of LabelLineConfig type described below-

type LabelLineConfig = {
  length?: number; // default 10
  tailLength?: number; // default 8
  color?: ColorValue; // default 'black'
  thickness?: number; // default 1
  labelComponentWidth?: number; // default 20
  labelComponentHeight?: number; // default 10
  labelComponentMargin?: number; // default 4
};

🔨 Refactor

Renamed the extraRadiusForFocused to extraRadius in Pie and Donut charts.

v1.4.26

04 Aug 19:01
dece9e1
Compare
Choose a tag to compare

🎉 1.4.26

✨ Features added-

Added the property hidePointers to the objects of the dataSet array. This will let us hide the pointers for individual sets.

Also, we can now add the property hidePointer inside individual data items of any dataSet.

See #755

🐛 Bug fixes

  1. Fixed the issue- areaChart given in dataSet array of line chart doesn't work. See #758
  2. Fixed the issue- Crash when I click to datapoint doesn't have any value. See #757

v1.4.25

03 Aug 19:06
eaebe80
Compare
Choose a tag to compare

🎉 1.4.25

✨ Features added-

Added the prop intersectionAreaConfig that defines properties for intersection area of data and data2 (1st & 2nd areas). See https://stackoverflow.com/questions/78435388/react-native-area-chart

🐛 Bug fixes

Fixed the issue- pointerLabelComponent's second parameter (representing secondaryItem) is undefined. See #752

🔨 Refactor

Reused activatePointers function, thus removing many lines of repetitive code in the LineChart component.

v1.4.24

02 Aug 23:43
024b0be
Compare
Choose a tag to compare

🎉 1.4.24

✨ Features added-

  1. Line charts can now have data arrays of different lengths. This means that data, data2, data3 don't need to be of same length. Same applies to the sets of dataSet.

  2. Added the prop labelWidth to stacked Bar charts. Thanks to Nathan Karmer for his PR- #748

🐛 Bug fixes

  1. Fixed the issue- Datapoint in secondary lines are incorrect position in pointerConfig. See #749

  2. Fixed the issue- Data points visible even if an area chart is hidded under some other area chart.

  3. Fixed the issue- Crash due to replacing findLastIndex with slice().reverse().findIndex in gifted-charts-core. I was reversing only the array and forgot to reverse the index. Thanks to dumihi313 for his PR- Abhinandan-Kushwaha/gifted-charts-core#37

v1.4.23

31 Jul 02:04
70015e4
Compare
Choose a tag to compare

🎉 1.4.23

✨ Features added-

  1. Added pointerIndex to the parameter list of pointerLabelComponent. This will help conditionally format the pointerLabelComponent based on pointerIndex.

    pointerLabelComponent now accepts 3 parameters- items, secondaryDataItem and pointerIndex.
    One use case would be to position the first and last pointerLabelComponents such that they don't overflow the chart area.

    See https://stackoverflow.com/questions/78472182/changer-pointerlable-style-on-a-certain-index-in-react-native-gifted-chart-linec

  2. Refactored the animateOnDataChange for Line and Area charts to make the animation smooth. animateOnDataChange is now suppported for curved charts as well! See https://stackoverflow.com/questions/78546970/react-native-gifted-charts-not-animating-on-data-change

🔨 Refactor

In gifted-charts-core, replaced findLastIndex() with slice().reverse().findIndex().

See the issue- Abhinandan-Kushwaha/gifted-charts-core#31 and its fix PR- Abhinandan-Kushwaha/gifted-charts-core#33

v1.4.22

28 Jul 19:24
e6dc86f
Compare
Choose a tag to compare

Added type declarations (.d.ts files)

v1.4.21

28 Jul 18:11
b58d7fa
Compare
Choose a tag to compare

🎉 1.4.21 Mega Release ⭐️

✨ Features added-

  1. Added the prop verticalLinesStrokeLinecap to Bar and Line charts that takes the values 'butt', 'round' and 'square' ('butt' being the default). See the stroke-linecap property in svg.

🔨 Refactor

The library now ships js binary obtained after compiling using babel. This should fix all typescript issues like these-

  1. #722
  2. #691
  3. #651
  4. #625
  5. #546
  6. #473

Note: Since we are now shipping compiled js, you may need to install the gifted-charts-core dependency.