Skip to content

Commit

Permalink
Merge pull request #28 from abstrxtInfinity/ram_ram
Browse files Browse the repository at this point in the history
animation added
  • Loading branch information
abstrxtInfinity committed Oct 6, 2022
2 parents c546bc8 + c6d85ef commit 681f431
Showing 1 changed file with 60 additions and 0 deletions.
60 changes: 60 additions & 0 deletions hoverAnim/index.html
@@ -0,0 +1,60 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Document</title>
<style>
h1::before {
transform: scaleX(0);
transform-origin: bottom right;
}

h1:hover::before {
transform: scaleX(1);
transform-origin: bottom left;
}

h1::before {
content: " ";
display: block;
position: absolute;
top: 0; right: 0; bottom: 0; left: 0;
inset: 0 0 0 0;
background: hsl(200 100% 80%);
z-index: -1;
transition: transform .3s ease;
}

h1 {
position: relative;
font-size: 5rem;
}

html {
block-size: 100%;
inline-size: 100%;
}

body {
min-block-size: 100%;
min-inline-size: 100%;
margin: 0;
box-sizing: border-box;
display: grid;
place-content: center;
font-family: system-ui, sans-serif;
}

@media (orientation: landscape) {
body {
grid-auto-flow: column;
}
}
</style>
</head>
<body>
<h1>Hover Me</h1>
</body>
</html>

0 comments on commit 681f431

Please sign in to comment.