aboutsummaryrefslogtreecommitdiff
path: root/public
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2020-10-22 20:27:55 -0400
committerPaul Duncan <pabs@pablotron.org>2020-10-22 20:27:55 -0400
commitd7f387ac1f49015922aeec7f5cb8fc29af832e05 (patch)
treef783540bb06d3cbded8d76c688a313ff48d0ef31 /public
parentb280f4d8dfacffe2ac8864334c69a48cfe03070e (diff)
downloadalonzo-mood-calculator-master.tar.bz2
alonzo-mood-calculator-master.zip
add wednesday-modeHEADmaster
Diffstat (limited to 'public')
-rw-r--r--public/face.css12
-rw-r--r--public/face.js14
-rw-r--r--public/index.html29
3 files changed, 53 insertions, 2 deletions
diff --git a/public/face.css b/public/face.css
index db8016b..77f3000 100644
--- a/public/face.css
+++ b/public/face.css
@@ -4,6 +4,18 @@ body {
font-family: arial, verdana, helvetica, sans-serif;
}
+body.wednesday-mode {
+ background: darkred;
+}
+
+body .wednesday-mode {
+ display: none;
+}
+
+body.wednesday-mode .wednesday-mode {
+ display: block;
+}
+
#help-toggle {
color: #ddd;
}
diff --git a/public/face.js b/public/face.js
index d565481..7d873ec 100644
--- a/public/face.js
+++ b/public/face.js
@@ -194,7 +194,7 @@ jQuery(function($) {
function tick() {
$('#face').css(get_frame(
(new Date()).getTime(),
- +$('#rate').val()
+ ($('#wednesday-mode').is(':checked') ? -20 : +$('#rate').val())
).css);
}
@@ -226,6 +226,18 @@ jQuery(function($) {
return false;
});
+ $('#wednesday-mode').click(function() {
+ var me = $(this);
+ setTimeout(function() {
+ $('body').toggleClass('wednesday-mode', me.is(':checked'));
+ }, 10);
+ });
+
+ // toggle wednesday mode on wednesdays
+ if ((new Date()).getDay() == 3) {
+ $('#wednesday-mode').click();
+ }
+
// fetch current price as percent and populate #rate
fetch(DATA_URL).then(function(r) {
return r.json();
diff --git a/public/index.html b/public/index.html
index 663b4d5..6987346 100644
--- a/public/index.html
+++ b/public/index.html
@@ -9,7 +9,10 @@
</head>
<body>
- <h1>Alonzo Mood Calculator</h1>
+ <h1>
+ Alonzo Mood Calculator
+ <span class='wednesday-mode'>(WEDNESDAY MODE)</span>
+ </h1>
<div id='text'>
<p>
@@ -34,6 +37,15 @@
The default value of the field is the current value according to
Yahoo Finance.
</p>
+
+ <p>
+ The new <b>Wendesday Mode</b> utilizes next-generation, state
+ of the art, real-time, gamification, snackable, hyper-local
+ heuristics to market-disrupt the mood calculation ideation
+ pipeline for the industry-leading, B2B, cloud-connected,
+ microservice-enabled, containerized, thought-leader-aware
+ office environment.
+ </p>
</div>
<p>
@@ -87,6 +99,21 @@
Max
</button>
</p>
+
+ <p class='controls'>
+ <label
+ for='wednesday-mode'
+ title='Enable Wednesday Mode'
+ style='text-align: center'
+ >
+ <input
+ type='checkbox'
+ id='wednesday-mode'
+ title='Enable Wednesday mode.'
+ />
+ Wednesday Mode
+ </label>
+ </p>
</div>
<div id='face'></div>