Skip to content

Commit e4527a4

Browse files
committed
Update LCJS version
1 parent 3a92581 commit e4527a4

File tree

5 files changed

+17
-19
lines changed

5 files changed

+17
-19
lines changed

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -139,12 +139,12 @@ Direct developer email support can be purchased through a [Support Plan][4] or b
139139
© Arction Ltd 2009-2020. All rights reserved.
140140

141141

142-
[Pyramid Chart]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/classes/pyramidchart.html
143-
[Pyramid Chart Types]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/globals.html#pyramidcharttypes
144-
[Pyramid Label Side]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/enums/pyramidlabelside.html
145-
[Slice label formatter]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/globals.html#slicelabelformatter
146-
[Palette]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/globals.html#colorpalettes
147-
[SolidFillPalette]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/globals.html#solidfillpalette
148-
[Solid Line]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/classes/solidline.html
149-
[Solid Fill]: https://www.arction.com/lightningchart-js-api-documentation/v3.0.1/classes/solidfill.html
142+
[Pyramid Chart]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/classes/pyramidchart.html
143+
[Pyramid Chart Types]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/globals.html#pyramidcharttypes
144+
[Pyramid Label Side]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/enums/pyramidlabelside.html
145+
[Slice label formatter]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/globals.html#slicelabelformatter
146+
[Palette]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/globals.html#colorpalettes
147+
[SolidFillPalette]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/globals.html#solidfillpalette
148+
[Solid Line]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/classes/solidline.html
149+
[Solid Fill]: https://www.arction.com/lightningchart-js-api-documentation/v3.1.0/classes/solidfill.html
150150

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"webpack-dev-server": "^3.9.0"
1515
},
1616
"dependencies": {
17-
"@arction/lcjs": "^3.0.1",
17+
"@arction/lcjs": "^3.1.0",
1818
"@arction/xydata": "^1.4.0",
1919
"clean-webpack-plugin": "^3.0.0",
2020
"webpack": "^4.41.2",

simplePyramid.png

185 KB
Loading

src/index.js

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,13 @@ const {
1111
SliceLabelFormatters,
1212
lightningChart,
1313
LegendBoxBuilders,
14-
SolidFillPalette,
15-
ColorPalettes,
16-
UIOrigins,
1714
Themes
1815
} = lcjs
1916

2017
// Create a Pyramid chart
2118
const pyramid = lightningChart()
2219
.Pyramid({
23-
// theme: Themes.dark
20+
// theme: Themes.darkGold
2421
type: PyramidChartTypes.LabelsOnSides
2522
})
2623
.setTitle('Company staff growth')
@@ -52,17 +49,17 @@ const data = [
5249
// Add data to the slices
5350
pyramid.addSlices(data)
5451

55-
56-
// Create warm Palette for Pyramid (defines color of Slice filling)
57-
// const palette = SolidFillPalette(ColorPalettes.warm, data.length)
58-
// pyramid.setSliceFillStyle(palette)
59-
6052
// Set formatter of Slice Labels
6153
pyramid.setLabelFormatter(SliceLabelFormatters.NamePlusValue)
6254

6355
// Add LegendBox and define the position in the chart
6456
const lb = pyramid
6557
.addLegendBox(LegendBoxBuilders.HorizontalLegendBox)
58+
// Dispose example UI elements automatically if they take too much space. This is to avoid bad UI on mobile / etc. devices.
59+
.setAutoDispose({
60+
type: 'max-width',
61+
maxWidth: 0.80,
62+
})
6663

6764
// Add the Pyramid to the LegendBox and disable the button click functionality.
6865
lb.add(pyramid, { disposeOnClick: false })

webpack.config.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ module.exports = {
6969
}),
7070
new CopyWebpackPlugin({
7171
patterns: [
72-
{ from: './assets/**/*', to: './examples/assets', flatten: true, noErrorOnMissing: true }
72+
{ from: './assets/**/*', to: './examples/assets', flatten: true, noErrorOnMissing: true },
73+
{ from: './node_modules/@arction/lcjs/dist/resources', to: 'resources', noErrorOnMissing: true },
7374
]
7475
})
7576
]

0 commit comments

Comments
 (0)