-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathprimaryMatchInputDynamic.js
44 lines (38 loc) · 1.04 KB
/
primaryMatchInputDynamic.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
var keyPressOk = true;
var mode = true;
$(function(){
$('#teleopscouting').hide();
});
function autotele(){
if(mode == true){
$('#autoscouting').hide();
$('#teleopscouting').show();
document.getElementById("Switch").innerHTML = "Auto";
}
else{
$('#autoscouting').show();
$('#teleopscouting').hide();
document.getElementById("Switch").innerHTML="Teleop";
}
mode = !mode;
}
function toggleColor(){
var colorTog = document.getElementById("allianceColor");
if (colorTog.innerHTML !== "Blue <b>(a)</b>") {
colorTog.innerHTML = "Blue <b>(a)</b>";
document.getElementById("allianceColor").value="Blue";
}
else {
colorTog.innerHTML = "Red <b>(a)</b>";
document.getElementById("allianceColor").value="Red";
}
}
function saveUserName1(){
console.log("SETTING USERNAME");
localStorage.setItem("userName", $("#userName").val());
}
$(document).ready(function(){
orangePersist.initializeApp();
console.log("GETTING USERNAME");
$("#userName").val(localStorage.getItem("userName"));
});