Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
layout: data => {
return Hierarchy.dendrogram(data, {
direction: 'LR', // H / V / LR / RL / TB / BT
nodeSep: 50,
rankSep: 100
});
}
});
function transform(dataView: View, options) {
const root = dataView.root;
options = Object.assign({}, DEFAULT_OPTIONS, options);
if (dataView.dataType !== DataSet.CONSTANTS.HIERARCHY) {
throw new TypeError('Invalid DataView: This transform is for Hierarchy data only!');
}
dataView.root = hierarchy.dendrogram(root, options);
}
function transform(dataView: View, options) {
const root = dataView.root;
options = Object.assign({}, DEFAULT_OPTIONS, options);
if (dataView.dataType !== DataSet.CONSTANTS.HIERARCHY) {
throw new TypeError('Invalid DataView: This transform is for Hierarchy data only!');
}
dataView.root = hierarchy.compactBox(root, options);
}
function transform(dataView: View, options) {
const root = dataView.root;
options = Object.assign({}, DEFAULT_OPTIONS, options);
if (dataView.dataType !== DataSet.CONSTANTS.HIERARCHY) {
throw new TypeError('Invalid DataView: This transform is for Hierarchy data only!');
}
dataView.root = hierarchy.indented(root, options);
}
function transform(dataView, options) {
const root = dataView.root;
options = Object.assign({}, DEFAULT_OPTIONS, options);
if (dataView.dataType !== HIERARCHY) {
throw new TypeError('Invalid DataView: This transform is for Hierarchy data only!');
}
dataView.root = hierarchy.compactBox(root, options);
}
function transform(dataView, options) {
const root = dataView.root;
options = Object.assign({}, DEFAULT_OPTIONS, options);
if (dataView.dataType !== HIERARCHY) {
throw new TypeError('Invalid DataView: This transform is for Hierarchy data only!');
}
dataView.root = hierarchy.dendrogram(root, options);
}
function transform(dataView, options) {
const root = dataView.root;
options = Object.assign({}, DEFAULT_OPTIONS, options);
if (dataView.dataType !== HIERARCHY) {
throw new TypeError('Invalid DataView: This transform is for Hierarchy data only!');
}
dataView.root = hierarchy.indented(root, options);
}