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(treemap): Intent to ship treemap type #3012

Merged
merged 2 commits into from
Dec 29, 2022
Merged

Conversation

netil
Copy link
Member

@netil netil commented Dec 29, 2022

Issue

#123

Details

Implement Treemap chart type

bb.generate({
  data: {
    columns: [
	["data1", 1300],
	["data2", 200],
        ...
    ],
    type: "treemap", // for ESM specify as: treemap()
    labels: {
      colors: "#fff"
    }
  },
  treemap: {
    label: {
      show: true,
      threshold: 0.03,
      format: function(value, ratio, id) {
	    return value;
       }
    }
  },
});

image

@netil netil added the feature label Dec 29, 2022
@netil netil self-assigned this Dec 29, 2022
@coveralls
Copy link

Coverage Status

Coverage: 90.403% (-0.4%) from 90.77% when pulling 4457ab1 on netil:treemapType#123 into 337c7cb on naver:master.

@netil netil merged commit 9809ef1 into naver:master Dec 29, 2022
@@ -284,9 +285,9 @@ export default class ChartInternal {
$$.point = $$.generatePoint();
}

if (state.hasAxis) {
$$.initClip();
$$.initClip();
Copy link
Contributor

Choose a reason for hiding this comment

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

This breaks tree-shaken builds because initClip is not defined at this point. The clip internals are loaded when loading the axis feature. they are not imported in this file.

netil pushed a commit to netil/billboard.js that referenced this pull request Jan 13, 2023
- side-effect call from the treemap implementation naver#3012
- revert .initCall() call

Ref naver#3035
netil added a commit that referenced this pull request Jan 13, 2023
- side-effect call from the treemap implementation #3012
- revert .initCall() call

Fix #3035
github-actions bot pushed a commit that referenced this pull request Jan 13, 2023
## [3.7.1](3.7.0...3.7.1) (2023-01-13)

### Bug Fixes

* **internals:** Fix unexpected initClip() call ([162fbf7](162fbf7)), closes [#3012](#3012) [#3035](#3035)
@netil netil deleted the treemapType#123 branch September 8, 2023 06:17
@netil netil mentioned this pull request Jan 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants