{"id":713,"date":"2017-01-11T21:28:32","date_gmt":"2017-01-11T12:28:32","guid":{"rendered":"http:\/\/okamurax.com\/?p=713"},"modified":"2017-01-17T02:13:35","modified_gmt":"2017-01-16T17:13:35","slug":"ds-min-js","status":"publish","type":"post","link":"https:\/\/appbay.org\/?p=713","title":{"rendered":"ds.min.js"},"content":{"rendered":"<pre class=\"lang:js decode:true  \">&lt;!DOCTYPE html&gt;\r\n&lt;meta charset=\"utf-8\"&gt;\r\n&lt;style&gt;\r\n\r\nbody {\r\n  margin: 0;\r\n  background: #222;\r\n  min-width: 960px;\r\n}\r\n\r\nrect {\r\n  fill: none;\r\n  pointer-events: all;\r\n}\r\n\r\ncircle {\r\n  fill: none;\r\n  stroke-width: 2.5px;\r\n}\r\n\r\n&lt;\/style&gt;\r\n&lt;body&gt;\r\n&lt;script src=\"http:\/\/d3js.org\/d3.v3.min.js\"&gt;&lt;\/script&gt;\r\n&lt;script&gt;window.d3 || document.write('&lt;script src=\"d3.min.js\"&gt;&lt;\\\/script&gt;')&lt;\/script&gt;\r\n&lt;script&gt;\r\n\r\nvar width = Math.max(960, innerWidth),\r\n    height = Math.max(500, innerHeight);\r\n\r\nvar i = 0;\r\n\r\nvar svg = d3.select(\"body\").append(\"svg\")\r\n    .attr(\"width\", width)\r\n    .attr(\"height\", height);\r\n\r\nsvg.append(\"rect\")\r\n    .attr(\"width\", width)\r\n    .attr(\"height\", height)\r\n    .on(\"ontouchstart\" in document ? \"touchmove\" : \"mousemove\", particle);\r\n\r\nfunction particle() {\r\n  var m = d3.mouse(this);\r\n\r\n  svg.insert(\"circle\", \"rect\")\r\n      .attr(\"cx\", m[0])\r\n      .attr(\"cy\", m[1])\r\n      .attr(\"r\", 1e-6)\r\n      .style(\"stroke\", d3.hsl((i = (i + 1) % 360), 1, .5))\r\n      .style(\"stroke-opacity\", 1)\r\n    .transition()\r\n      .duration(2000)\r\n      .ease(Math.sqrt)\r\n      .attr(\"r\", 100)\r\n      .style(\"stroke-opacity\", 1e-6)\r\n      .remove();\r\n\r\n  d3.event.preventDefault();\r\n}\r\n\r\n&lt;\/script&gt;<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>&lt;!DOCTYPE html&gt; &lt;meta charset=&#8221;utf-8&#8243;&gt; &lt;style&gt; body { margin: 0; background: #222; min-width &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/appbay.org\/?p=713\" class=\"more-link\"><span class=\"screen-reader-text\">&#8220;ds.min.js&#8221; \u306e<\/span>\u7d9a\u304d\u3092\u8aad\u3080<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[4],"class_list":["post-713","post","type-post","status-publish","format-standard","hentry","category-1","tag-javascript-typescript"],"_links":{"self":[{"href":"https:\/\/appbay.org\/index.php?rest_route=\/wp\/v2\/posts\/713","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/appbay.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/appbay.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/appbay.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/appbay.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=713"}],"version-history":[{"count":1,"href":"https:\/\/appbay.org\/index.php?rest_route=\/wp\/v2\/posts\/713\/revisions"}],"predecessor-version":[{"id":714,"href":"https:\/\/appbay.org\/index.php?rest_route=\/wp\/v2\/posts\/713\/revisions\/714"}],"wp:attachment":[{"href":"https:\/\/appbay.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=713"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/appbay.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=713"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/appbay.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=713"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}