Grammar corrections, translations added

master
RKBoss6 2025-08-02 23:01:37 -04:00 committed by GitHub
parent 78cc812235
commit 372a29cfad
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 16 additions and 16 deletions

View File

@ -24,7 +24,7 @@ let exerciseType = {
// add new exercises here: // add new exercises here:
const exerciseTypes = [{ const exerciseTypes = [{
"id": "pushup", "id": "pushup",
"name": "push ups", "name": /*LANG*/"Push-ups",
"useYaxis": true, "useYaxis": true,
"useZaxis": false, "useZaxis": false,
"threshold": 2500, "threshold": 2500,
@ -34,7 +34,7 @@ const exerciseTypes = [{
}, },
{ {
"id": "curl", "id": "curl",
"name": "curls", "name": /*LANG*/"Curls",
"useYaxis": true, "useYaxis": true,
"useZaxis": false, "useZaxis": false,
"threshold": 2500, "threshold": 2500,
@ -44,7 +44,7 @@ const exerciseTypes = [{
}, },
{ {
"id": "situp", "id": "situp",
"name": "sit ups", "name": /*LANG*/"Sit-ups",
"useYaxis": false, "useYaxis": false,
"useZaxis": true, "useZaxis": true,
"threshold": 3500, "threshold": 3500,
@ -88,7 +88,7 @@ function showMainMenu() {
menu["--------"] = { menu["--------"] = {
value: "" value: ""
}; };
menu["Last:"] = { menu[/*LANG*/"Last:"] = {
value: exerciseCounter + " " + exerciseType.name value: exerciseCounter + " " + exerciseType.name
}; };
} }
@ -189,10 +189,10 @@ function isValidExercise(slope, t) {
if (p1 > 0 && p2 < 0) { if (p1 > 0 && p2 < 0) {
if (lastZeroPassCameFromPositive == false) { if (lastZeroPassCameFromPositive == false) {
lastExerciseHalfCompletionTime = t; lastExerciseHalfCompletionTime = t;
console.log(t, exerciseName + " half complete..."); console.log(t, exerciseName + /*LANG*/" half complete...");
layout.progress.label = "½"; layout.progress.label = "½";
layout.recording.label = "TRAINING"; layout.recording.label = /*LANG*/"TRAINING";
g.clear(); g.clear();
layout.render(); layout.render();
} }
@ -204,7 +204,7 @@ function isValidExercise(slope, t) {
if (lastZeroPassCameFromPositive == true) { if (lastZeroPassCameFromPositive == true) {
const tDiffLastExercise = t - lastExerciseCompletionTime; const tDiffLastExercise = t - lastExerciseCompletionTime;
const tDiffStart = t - tStart; const tDiffStart = t - tStart;
console.log(t, exerciseName + " maybe complete?", Math.round(tDiffLastExercise), Math.round(tDiffStart)); console.log(t, exerciseName + /*LANG*/" maybe complete?", Math.round(tDiffLastExercise), Math.round(tDiffStart));
// check minimal time between exercises: // check minimal time between exercises:
if ((lastExerciseCompletionTime <= 0 && tDiffStart >= thresholdMinTime) || tDiffLastExercise >= thresholdMinTime) { if ((lastExerciseCompletionTime <= 0 && tDiffStart >= thresholdMinTime) || tDiffLastExercise >= thresholdMinTime) {
@ -222,7 +222,7 @@ function isValidExercise(slope, t) {
layout.count.label = exerciseCounter; layout.count.label = exerciseCounter;
layout.progress.label = ""; layout.progress.label = "";
layout.recording.label = "Good!"; layout.recording.label =/*LANG*/"Good!";
g.clear(); g.clear();
layout.render(); layout.render();
@ -230,26 +230,26 @@ function isValidExercise(slope, t) {
if (settings.buzz) if (settings.buzz)
Bangle.buzz(200, 0.5); Bangle.buzz(200, 0.5);
} else { } else {
console.log(t, exerciseName + " too quick for duration time threshold!"); // thresholdMinDurationTime console.log(t, exerciseName + /*LANG*/" too quick for duration time threshold!"); // thresholdMinDurationTime
lastExerciseCompletionTime = t; lastExerciseCompletionTime = t;
layout.recording.label = "Go slower!"; layout.recording.label = /*LANG*/"Go slower!";
g.clear(); g.clear();
layout.render(); layout.render();
} }
} else { } else {
console.log(t, exerciseName + " top slow for time threshold!"); // thresholdMaxTime console.log(t, exerciseName + /*LANG*/" top slow for time threshold!"); // thresholdMaxTime
lastExerciseCompletionTime = t; lastExerciseCompletionTime = t;
layout.recording.label = "Go faster!"; layout.recording.label = /*LANG*/"Go faster!";
g.clear(); g.clear();
layout.render(); layout.render();
} }
} else { } else {
console.log(t, exerciseName + " too quick for time threshold!"); // thresholdMinTime console.log(t, exerciseName + /*LANG*/" too quick for time threshold!"); // thresholdMinTime
lastExerciseCompletionTime = t; lastExerciseCompletionTime = t;
layout.recording.label = "Go slower!"; layout.recording.label = /*LANG*/"Go slower!";
g.clear(); g.clear();
layout.render(); layout.render();
} }
@ -337,7 +337,7 @@ function startTraining() {
type: "txt", type: "txt",
id: "recording", id: "recording",
font: "6x8:2", font: "6x8:2",
label: "TRAINING", label: /*LANG*/"TRAINING",
bgCol: "#f00", bgCol: "#f00",
pad: 5, pad: 5,
fillx: 1 fillx: 1
@ -345,7 +345,7 @@ function startTraining() {
] ]
}, { }, {
btns: [{ btns: [{
label: "STOP", label: /*LANG*/"STOP",
cb: () => { cb: () => {
stopTraining(); stopTraining();
} }