Skip to content

Commit 6074d36

Browse files
committed
Workaround build system issues with url() syntax in CSS files
1 parent 001821d commit 6074d36

5 files changed

Lines changed: 19 additions & 18 deletions

File tree

css/c3.css

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -211,12 +211,6 @@ html.grabbing * {
211211
.c3.butterfly .navigatable .node rect {
212212
cursor: pointer;
213213
}
214-
.c3.butterfly .link path.fade_right {
215-
mask: url(#mask_fade_right);
216-
}
217-
.c3.butterfly .link path.fade_left {
218-
mask: url(#mask_fade_left);
219-
}
220214
table.c3.table {
221215
border-collapse: collapse;
222216
}

css/c3.less

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -305,16 +305,6 @@ html.grabbing, html.grabbing * {
305305
cursor: pointer;
306306
}
307307
}
308-
309-
.link path {
310-
&.fade_right {
311-
mask: url(#mask_fade_right);
312-
}
313-
314-
&.fade_left {
315-
mask: url(#mask_fade_left);
316-
}
317-
}
318308
}
319309

320310

js/c3-graph.coffee

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -582,9 +582,15 @@ class c3.Sankey.Butterfly extends c3.Sankey
582582
d3.event.stopPropagation
583583
@focus datum
584584

585+
# Style links that fade out to unrendered nodes
585586
@paths.all.classed
586587
fade_left: (link)=> @link_source(link) not of @current_nodes
587588
fade_right: (link)=> @link_target(link) not of @current_nodes
589+
# Workaround packing/build issues for systems that don't like url() syntax in CSS files...
590+
@paths.all.attr 'mask', (link)=>
591+
if @link_source(link) not of @current_nodes then 'url(#mask_fade_left)'
592+
else if @link_target(link) not of @current_nodes then 'url(#mask_fade_right)'
593+
else null
588594

589595
_butterfly_layout: =>
590596
focus_key = @key @focal

js/c3-graph.js

Lines changed: 12 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)