mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Minor tweaks to the meteor/non-core/bundle-visualizer package.
This commit is contained in:
@@ -9,7 +9,7 @@ import * as classes from "./classNames.js";
|
||||
import "./style.css";
|
||||
|
||||
Meteor.startup(() => {
|
||||
import("./sunburst.js").then(({ Sunburst }) => main(Sunburst));
|
||||
import("./sunburst.js").then(s => main(s.Sunburst));
|
||||
});
|
||||
|
||||
function main(builder) {
|
||||
@@ -29,7 +29,7 @@ function main(builder) {
|
||||
|
||||
// Load the JSON, which is `d3-hierarchy` digestible.
|
||||
if (result) {
|
||||
(new builder({ container })).loadJson(result);
|
||||
new builder({ container }).loadJson(result);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ Npm.depends({
|
||||
});
|
||||
|
||||
Package.onUse(function(api) {
|
||||
api.versionsFrom('1.4.4.1');
|
||||
api.use('isobuild:dynamic-import@1.5.0');
|
||||
api.use([
|
||||
'ecmascript',
|
||||
'dynamic-import',
|
||||
|
||||
@@ -59,12 +59,10 @@ const DEFAULT_COLORS = {
|
||||
};
|
||||
|
||||
export class Sunburst {
|
||||
constructor(
|
||||
{
|
||||
container,
|
||||
colors = DEFAULT_COLORS,
|
||||
} = {}
|
||||
) {
|
||||
constructor({
|
||||
container,
|
||||
colors = DEFAULT_COLORS,
|
||||
} = {}) {
|
||||
this.elements = {};
|
||||
this.colors = colors;
|
||||
this.totalSize = 0;
|
||||
|
||||
Reference in New Issue
Block a user