MCPcopy Create free account
hub / github.com/plotly/plotly.js / style

Function style

src/traces/treemap/style.js:10–27  ·  view source on GitHub ↗
(gd)

Source from the content-addressed store, hash-verified

8var fillOne = require('../sunburst/fill_one');
9
10function style(gd) {
11 var s = gd._fullLayout._treemaplayer.selectAll('.trace');
12 resizeText(gd, s, 'treemap');
13
14 s.each(function(cd) {
15 var gTrace = d3.select(this);
16 var cd0 = cd[0];
17 var trace = cd0.trace;
18
19 gTrace.style('opacity', trace.opacity);
20
21 gTrace.selectAll('path.surface').each(function(pt) {
22 d3.select(this).call(styleOne, pt, trace, gd, {
23 hovered: false
24 });
25 });
26 });
27}
28
29function styleOne(s, pt, trace, gd, opts) {
30 var hovered = (opts || {}).hovered;

Callers

nothing calls this directly

Calls 1

resizeTextFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…