Skip to content

Commit

Permalink
Adds a privacy notice (#12)
Browse files Browse the repository at this point in the history
Add privacy notice
  • Loading branch information
Terkwood authored Jan 21, 2019
1 parent 7673b1c commit cf4c016
Showing 1 changed file with 29 additions and 5 deletions.
34 changes: 29 additions & 5 deletions static/draw.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ const FONT = "30px Arial";
const GREEN = "rgb(0,255,0)";
const HUD_X = 50;
const HUD_Y = 50;
const PRIVACY_Y = 20;

var readyCheck = setInterval(function() {
var canvas = document.querySelector("#canvas");
Expand All @@ -15,13 +16,36 @@ var readyCheck = setInterval(function() {
ctx.fillStyle = "black";
ctx.fill();

ctx.beginPath();
ctx.font = "24px Arial";
ctx.fillStyle = GREEN;
ctx.fillText("TAP to start.", HUD_X / 3, HUD_Y);
ctx.fillText("Then TAP to take a photo.", HUD_X / 3, HUD_Y * 2);
ctx.fillText("Photo processing may take", HUD_X / 3, HUD_Y * 4);
ctx.fillText(" up to 10 seconds!", HUD_X / 3, HUD_Y * 5);
var howToLines = [
"TAP to start,",
" then TAP to take a photo.",
"",
"Photo processing may take",
" up to 10 seconds!",
];
var howToIdx = 1;
howToLines.forEach(function(l) {
ctx.fillText(l, HUD_X / 3, HUD_Y * howToIdx);
howToIdx += 1;
});

ctx.font = "14px Arial";
const PRIVACY_Y_OFFSET = HUD_Y * 7;
var privacyLines = [
"PRIVACY NOTICE: This educational project",
"does not collect ANY data about you.",
"Images created with this app do not leave",
"your device, and are under your control.",
"The code may be reviewed by visiting",
"https://github.com/Terkwood/vision",
];
var privacyIdx = 0;
privacyLines.forEach(function(l) {
ctx.fillText(l, HUD_X / 3, PRIVACY_Y_OFFSET + PRIVACY_Y * privacyIdx);
privacyIdx += 1;
});
}
}, 50);

Expand Down

0 comments on commit cf4c016

Please sign in to comment.