[ Launch: Pub Time ] 5799837 by petabyte
-
-
Save petabyte/5799837 to your computer and use it in GitHub Desktop.
Pub Time
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"description":"Pub Time","endpoint":"","display":"svg","public":true,"require":[],"fileconfigs":{"inlet.js":{"default":true,"vim":false,"emacs":false,"fontSize":12},"steps.json":{"default":true,"vim":false,"emacs":false,"fontSize":12},"_.md":{"default":true,"vim":false,"emacs":false,"fontSize":12},"config.json":{"default":true,"vim":false,"emacs":false,"fontSize":12},"styles.css":{"default":true,"vim":false,"emacs":false,"fontSize":12},"types.json":{"default":true,"vim":false,"emacs":false,"fontSize":12}},"fullscreen":false,"play":false,"loop":false,"restart":false,"autoinit":true,"pause":true,"loop_type":"period","bv":false,"nclones":15,"clone_opacity":0.4,"duration":3000,"ease":"linear","dt":0.01} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var types = tributary.types; | |
var svg = d3.select("svg"); | |
var yscale = d3.scale.linear() | |
.domain([0, 10000]) | |
.range([50,55]); | |
var duration = 100; | |
// | |
var xscale = d3.scale.ordinal() | |
.domain(d3.range(types.length)) | |
.rangeBands([0, types.length*30],1) | |
// Get all nodes to snap to grid. | |
var xscalebins = d3.scale.linear() | |
.domain(d3.range(types.length)) | |
.range([90,200]) | |
var xf = function(d,i) { | |
if(!d.x) | |
d.x = xscale(i); | |
return xscalebins(i); | |
} | |
var yf = function(d,i) { | |
if(!d.y) | |
d.y = yscale(d.value); | |
return d.y; | |
} | |
var drag = d3.behavior.drag() | |
.on("drag", function(d,i) { | |
var dx = d3.event.dx; | |
var dy = d3.event.dy; | |
d.x += dx; | |
d.y += dy; | |
update(); | |
}) | |
var curve = d3.svg.line() | |
.x(xf) | |
.y(yf) | |
.interpolate("cardinal") | |
function update() { | |
types.sort(function(a, b) { | |
return a.x - b.x | |
}) | |
var circles = svg.selectAll("circle") | |
.data(types) | |
circles.enter() | |
.append("circle") | |
.call(drag) | |
.attr({ | |
cx: xf, | |
cy: yf, | |
r: 10 | |
}) | |
circles | |
.attr("cy", yf) | |
.transition() | |
.duration(duration) | |
.attr({ | |
cx: xf, | |
r: 10 | |
}) | |
var texts = svg.selectAll("text") | |
.data(types) | |
texts.enter() | |
.append("text") | |
texts | |
.text(function(d) { return d.step }) | |
.transition() | |
.duration(duration) | |
.attr("transform", function(d,i) { | |
var x = xf(d,i) + 12 | |
var y = yf(d,i) + -10 | |
return "translate(" + [x,y] + ")rotate(-36)"; | |
}).style({ | |
"font-size": 10 | |
}) | |
var paths = svg.selectAll("path") | |
.data([types]) | |
paths | |
.enter() | |
.append("path") | |
paths | |
.transition() | |
.duration(duration) | |
.attr("d", curve(types)); | |
} | |
update() | |
svg.append("path") | |
console.log(types) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
path { | |
fill: none; | |
stroke: #000000; | |
stroke-width: 3; | |
pointer-events: none; | |
} | |
circle { | |
opacity: 0.2 | |
} | |
text { | |
pointer-events: none; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{"step":"Retrieve relationships ready for publishing for the collection id", "value":3404}, | |
{"step":"Create, send MDC request message and parse the response", "value":9913}, | |
{"step":"Determine document type and assign to the relationship", "value":20}, | |
{"step":"Create, send MDC request message and parse the response for information pertaining to certain DocTypes", "value":824}, | |
{"step":"Calculate Sort Key and assign to the relationship", "value":11}, | |
{"step":"Perform publishing supression and set the suppression add override flag", "value":1}, | |
{"step":"Determine dates and assign to the relationship", "value":990}, | |
{"step":"Create Norm Payload and Publish Object from List of Relationship Models", "value":844}, | |
{"step":"Create KC output file legacy feed in temp folder", "value":294}, | |
{"step":"Save Publish and Related Relationship information to DB", "value":335}, | |
{"step":"Create and send LTC Request message for file", "value":576} | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment