This commit is contained in:
2025-05-01 14:37:08 -06:00
parent b6008d462e
commit 5cd4571a92
91 changed files with 1009 additions and 36 deletions
View File
+11
View File
@@ -0,0 +1,11 @@
div {
position: absolute;
top: 0px;
height: 100px;
width: 100px;
background-color: black;
}
button {
float: right;
}
View File
View File
+15
View File
@@ -0,0 +1,15 @@
<!doctype html>
<html lang="en">
<head>
<title>Dummy Title</title>
<link href="css/styles.css" type="text/css" rel="stylesheet">
<script src="js/index.js" defer></script>
</head>
<body>
<button>Button</button>
<div></div>
</body>
</html>
View File
+9
View File
@@ -0,0 +1,9 @@
const div = document.querySelector('div');
const button = document.querySelector('button')
let times = 1;
button.addEventListener('click', (e) => {
let px = 300 * times;
times++;
div.style.top = px + 'px';
});