Skip to content

Instantly share code, notes, and snippets.

View kt3k's full-sized avatar

Yoshiya Hinosawa kt3k

View GitHub Profile
@kt3k
kt3k / color palette for JS logo
Created November 10, 2014 21:22
color palette for JS logo
@kt3k
kt3k / wait.js
Last active August 29, 2015 14:09
wait.js
var wait = function (n) {
return function () {
return new Promise(function (resolve) {
setTimeout(resolve, n);
});
};
};
@kt3k
kt3k / restartable.js
Created November 14, 2014 22:54
restartable css animation
$.fn.animation = function (animation) {
this.css('-webkit-animation', '').reflow().css('-webkit-animation', animation);
return this;
};
$.fn.reflow = function () {
this[0].offsetWidth = this[0].offsetWidth;
return this;
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@kt3k
kt3k / TODO.md
Last active August 29, 2015 14:10
TODO.md

TODO

  • 🐆 some tasks
    • 🐈 ▶️ buy milk @kt3k (due 2014/12/12) (25%)
    • 🚀 🆕 build a rocket

Note:

:octocat: | meaning

@kt3k
kt3k / journal.yml
Last active August 29, 2015 14:14 — forked from anonymous/journal.yml
- id: 0
date: 2015-01-05
name: 開業
dr:
預金: 2400
cr:
元入金: 2400
- id: 1
date: 2015-01-20
@kt3k
kt3k / README.md
Last active August 29, 2015 14:15 — forked from mbostock/.block

Enclosure diagrams use containment to represent the hierarchy. Although circle packing is not as space-efficient as a treemap, it better reveals the hierarchy. Implementation based on work by Jeff Heer. Data shows the Flare class hierarchy, also courtesy Jeff Heer.

See also this zoomable version.

@kt3k
kt3k / README.md
Last active August 29, 2015 14:15 — forked from mbostock/.block
@kt3k
kt3k / README.md
Last active August 29, 2015 14:15 — forked from robschmuecker/README.md

This example pulls together various examples of work with trees in D3.js.

The panning functionality can certainly be improved in my opinion and I would be thrilled to see better solutions contributed.

One can do all manner of housekeeping or server related calls on the drop event to manage a remote tree dataset for example.

Dragging can be performed on any node other than root (flare). Dropping can be done on any node.

Panning can either be done by dragging an empty part of the SVG around or dragging a node towards an edge.

@kt3k
kt3k / README.md
Last active August 29, 2015 14:15 — forked from mbostock/.block