added JSDocs

This commit is contained in:
liyunze 2023-12-13 20:05:22 +08:00
parent ef6c25e60a
commit 4de7edf03f
2 changed files with 18 additions and 17 deletions

View file

@ -9,6 +9,9 @@ const configs = (function () {
const pointsPerTask = 10; // integer
const taskSeparator = [";", ","]; // array of strings
// SETTING THIS 'TRUE' WILL RESET EXISTING TASKS
const testTasks = true; // true or false
// animation
const scrollSpeed = 40; // milliseconds
const gapBetweenScrolls = 0; // px
@ -60,7 +63,7 @@ const configs = (function () {
const taskWidth = "100%";
const taskBackgroundColor = "#fff"; // hex only
const taskBackgroundColor = "#000"; // hex only
const taskBackgroundOpacity = 0; // 0.0 - 1.0
const taskFontFamily = "Poppins"; // font name
@ -360,6 +363,7 @@ const configs = (function () {
taskSeparator,
headerGoogleFont,
taskGoogleFont,
testTasks,
};
const styles = {

View file

@ -1318,7 +1318,7 @@ function checkTasks(username) {
) + 1;
reply += `${taskIndex}. ${
incompleteTasks[i].focus ? "(FOCUSED)" : ""
incompleteTasks[i].focus ? "(ongoing)" : ""
} ${incompleteTasks[i].text} | `;
}
reply = reply.slice(0, -3);
@ -1562,22 +1562,15 @@ function sleep(ms) {
}
// unit tests
async function tests1() {
async function tests() {
let listOfStreamers = [
`cloudydayzzz`,
`berryspace`,
`MohFocus`,
`xeno_hiraeth`,
`euphie___`,
`unknownnie`,
`theyolotato`,
// `charliosaurus`,
// `jutstreams`,
// `mikewhatwhere`,
// `studypaws`,
// `pcc_lanezzz`,
// `workwithjandj`,
// `studylena`,
`followRythonDev1`,
`followRythonDev2`,
`followRythonDev3`,
`followRythonDev4`,
`followRythonDev5`,
`followRythonDev6`,
`followRythonDev7`,
];
for (let i = 0; i < listOfStreamers.length; i++) {
@ -1681,6 +1674,10 @@ function cancelAnimation() {
(function () {
setupDB();
if (settings.testTasks) {
resetDB();
tests();
}
importStyles();
renderTaskListToDOM();
})();