Giter Site home page Giter Site logo

dtreemap's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dtreemap's Issues

`dtreemap` is not repositioned when DOM is changed

dtreemap is not repositioned when DOM is changed. It could be only a CSS issue.
Below is an example that illustrates it.

  1. when some long text is inserted before the treemap is built
    1
  2. when the same long text is inserted after the treemap is built (ie DOM is modified after treemap is built)
    2

To reproduce this:

require(["dojo/ready", "dojo/dom", "dojox/treemap/TreeMap",
        "dojo/store/Memory", "dojox/color/MeanColorModel", "dojo/_base/Color"],
        function(ready, dom, TreeMap, Memory, MeanColorModel, Color) {
            ready(function(){

                // example from documentation
                var dataStore = new Memory({idProperty: "label", data:
                    [
                { label: "France", sales: 500, profit: 50, region: "EU" },
                { label: "Germany", sales: 450, profit: 48, region: "EU" },
                { label: "UK", sales: 700, profit: 60, region: "EU" },
                { label: "USA", sales: 2000, profit: 250, region: "America" },
                { label: "Canada", sales: 600, profit: 30, region: "America" },
                { label: "Brazil", sales: 450, profit: 30, region: "America" },
                { label: "China", sales: 500, profit: 40, region: "Asia" },
                { label: "Japan", sales: 900, profit: 100, region: "Asia" }
                ]});
                var colorModel = new MeanColorModel(new Color(Color.named.red), new Color(Color.named.green));
                new TreeMap({store: dataStore,
                    areaAttr: "sales", colorAttr: "profit", groupAttrs: ["region"],
                    colorModel: colorModel }, dom.byId("treeMap"));

                // changing the upper part of the DOM
                var longText = "Lorem ipsum dolor sit ame..."
                setTimeout(function(){
                    document.getElementById("text").innerText = longText;
                }, 500)
            });
        });
<p id="text"></p>
<div>
    <div id="treeMap" style="width:600px;height:600px"></div>
</div>

RTL support

It is already working, however one might want to reverse the treemap layout direction in RTL which is not feasible.

Support store with hierarchy (getChildren method)

In addition to supporting flat stores on which we build ourselves the hierarchy support as well hierarchical stores with getChildren method.

Would require at least an implementation of such as store in Dojo for proper testing (there is none right now).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.