From 811c7be6cdb6648ac8520321bb16711707fff558 Mon Sep 17 00:00:00 2001 From: Julie Lala Date: Sat, 29 Nov 2014 03:43:10 -0500 Subject: colors --- unicode/test.html | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'unicode/test.html') diff --git a/unicode/test.html b/unicode/test.html index 0c964b9..5100bf9 100644 --- a/unicode/test.html +++ b/unicode/test.html @@ -1,7 +1,9 @@ @@ -17,6 +19,9 @@ function paginate (a, n){ } return aa.map(function(k){ return "&#" + k.join(";&#") + ";" }).join("
") } +colors = "eijln" +var lastColor = "a" +function choice(a){ return a[(Math.random()*a.length)|0] } requestAnimationFrame(function(){ var ranges = unicode_blocks.findGroups(fixedsys_characters) console.log(ranges) @@ -29,6 +34,14 @@ requestAnimationFrame(function(){ html += "
" html += "
" r.innerHTML = html + while (1) { + var color = choice(colors) + if (color != lastColor) { + lastColor = color + break + } + } + r.className = "f" + lastColor document.body.appendChild(r) }) }) -- cgit v1.2.3-70-g09d2