Skip to content

Commit

Permalink
3D Pop Up Animation (#2733)
Browse files Browse the repository at this point in the history
* Added the Welcome animation

* Fixed link tag

* Added a Pop uptext animation on hover

* Corrected the spelling
  • Loading branch information
KC1064 authored Oct 13, 2024
1 parent 967aef6 commit 71becdf
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Art/KC1064-Pop_Up_Text/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Text 02</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<h1 data-text="Hacktoberfest">HacktoberFest</h1>
</body>
</html>
4 changes: 4 additions & 0 deletions Art/KC1064-Pop_Up_Text/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"githubHandle": "KC1064",
"artName": "Pop Up Text Animation"
}
52 changes: 52 additions & 0 deletions Art/KC1064-Pop_Up_Text/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@600;700;800&display=swap");

*,
*::before,
*::after {
margin: 0;
padding: 0;
box-sizing: border-box;
}

body {
font-family: "Poppins", sans-serif;
background-color: #14141f;
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
}

h1 {
font-size: 88px;
font-weight: 800;
letter-spacing: 8px;
text-transform: uppercase;
text-decoration: none;
color: transparent;
-webkit-text-stroke-width: 1px;
-webkit-text-stroke-color: white;
text-align: center;
position: relative;
}

h1::before,
h1::after {
content: attr(data-text);
position: absolute;
top: 0;
left: 0;
transition: 0.3s ease-out;
}
h1:hover::before {
color: #bb0000;
transform: translate(12px, -12px);
-webkit-text-stroke-width: 1px;
-webkit-text-stroke-color: black;
}
h1:hover::after {
color: #77efff;
transform: translate(24px, -24px);
-webkit-text-stroke-width: 1px;
-webkit-text-stroke-color: black;
}

0 comments on commit 71becdf

Please sign in to comment.