wip: style changes

This commit is contained in:
Victor Westerlund 2022-03-25 18:39:06 +01:00
parent cfc8d68840
commit cb87de3895
2 changed files with 10 additions and 8 deletions

View file

@ -11,28 +11,29 @@ body {
} }
img { img {
position: relative;
z-index: 1;
width: clamp(20px, 50vh, 80vw); width: clamp(20px, 50vh, 80vw);
image-rendering: pixelated; image-rendering: pixelated;
pointer-events: none; pointer-events: none;
} }
#pattern { section {
position: fixed; position: fixed;
inset: 0; inset: 0;
width: 100%; width: 100%;
height: 100%; height: 100%;
z-index: -1;
} }
#pattern p { section p {
margin: 0; margin: 0;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
} }
#pattern p span { section p span {
font-size: clamp(10px, 4vh, 10vw); font-size: clamp(10px, 4vh, 10vw);
font-family: monospace; font-family: monospace;
font-weight: bold; font-weight: bold;
color: black; color: rgba(0, 0, 0, .15);
} }

View file

@ -17,12 +17,13 @@
</head> </head>
<body> <body>
<img src="assets/media/wrongplace.gif"/> <img src="assets/media/wrongplace.gif"/>
<div id="pattern"></div>
<script type="module"> <script type="module">
import { default as WrongPlace } from "./assets/js/WrongPlace.mjs"; import { default as WrongPlace } from "./assets/js/WrongPlace.mjs";
const main = document.getElementById("pattern"); const pattern = document.createElement("section");
window._wrongplace = new WrongPlace(main); document.documentElement.appendChild(pattern);
window._wrongplace = new WrongPlace(pattern);
</script> </script>
</body> </body>
</html> </html>