apply everything to ts; add temp layout
This commit is contained in:
@ -0,0 +1,33 @@
|
||||
|
||||
document.addEventListener("DOMContentLoaded", () => {
|
||||
console.log("DOM Loaded");
|
||||
|
||||
const main = document.getElementById("main");
|
||||
const time = document.getElementById("time");
|
||||
if(!main||!time)
|
||||
return;
|
||||
let currentDate = new Date();
|
||||
|
||||
|
||||
setInterval( () => {
|
||||
currentDate = new Date();
|
||||
time.innerText = "" + ( currentDate.getHours() < 10 ? "0" + currentDate.getHours() : currentDate.getHours() ) + ":" + ( currentDate.getMinutes() < 10 ? "0" + currentDate.getMinutes() : currentDate.getMinutes() );
|
||||
}, 1000 );
|
||||
|
||||
let maxI = 20;
|
||||
|
||||
main.style.gridTemplateRows = `repeat(${Math.round(maxI/3)}, calc(90%/2))`;
|
||||
|
||||
|
||||
for( let i = 0; i<maxI; i++ )
|
||||
{
|
||||
let testDrink = document.createElement("div");
|
||||
testDrink.classList.add("drink");
|
||||
|
||||
main.append(testDrink);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
});
|
@ -1,22 +0,0 @@
|
||||
{
|
||||
"extends": "../../tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"target": "ES6",
|
||||
"module": "CommonJS",
|
||||
"lib": [
|
||||
"es5",
|
||||
"es6",
|
||||
"dom",
|
||||
"dom.iterable"
|
||||
],
|
||||
"allowJs": true,
|
||||
"sourceMap": true,
|
||||
"downlevelIteration": true,
|
||||
"baseUrl": "src/web/",
|
||||
"paths": {
|
||||
"*": [
|
||||
"src/web/*",
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user