Skip to content

Commit

Permalink
Update colorapp.js
Browse files Browse the repository at this point in the history
  • Loading branch information
jonodjlee committed Dec 6, 2020
1 parent 856aa57 commit 0a37757
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion assets/js/colorapp.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@
}, this.setSiteColor = function (r) {
r = r || !1;
var t = this.currentColor,
n = "#" + this.RGBtoHEX(t[0], t[1], t[2]);
n = "#" + this.RGBtoHEX(t[0], t[1], t[2]),
u = this.HEXtoRGB;
if (this.RGBlightness(t[0], t[1], t[2]) < 180) var a = this.blendColors(n, "#FFFFFF", .75);
else a = this.blendColors(n, "#000000", .5);
$("body").css("backgroundColor", "rgb(" + t + ")"), $(".color-field, body, a").css("color", a), $(".color-field, .field").css("borderColor", a), $(".rw-monogram").css("fill", a), r && (location.hash = "/hex/" + String(n).replace(/[^0-9a-f]/gi, ""))
Expand Down

0 comments on commit 0a37757

Please sign in to comment.