Skip to content

Text animations #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jul 3, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions applications/spacious/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Spacious Animation</title>
<link rel="stylesheet" href="./styles.css"/>
</head>
<body>
<div class="main">
<span>S</span>
<span>P</span>
<span>A</span>
<span>C</span>
<span>I</span>
<span class="letter"></span>
<span>U</span>
<span>S</span>
</div>
</body>
</html>
47 changes: 47 additions & 0 deletions applications/spacious/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
*{
padding: 0;
margin: 0;
box-sizing: border-box;
}
body{
width: 100%;
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
font-family: 'Quicksand', sans-serif;
font-size: 42px;
background: #f7f7f7;
}
span{
margin: 0 15px;
line-height: .7;
text-shadow: 0 0 2px rgba(0, 0, 0, .45);
animation: span 3s ease-in infinite alternate;
}
.main{
display: flex;
justify-content: center;
align-items: flex-start;
}
.letter{
display: inline-flex;
height: 30px;
width: 27px;
/* border: 2.5px solid #FF1EAD; */
border: 2.35px solid black;
border-radius: 14px;
box-shadow:
0 0 2px rgba(0, 0, 0, .75),
inset 0 0 2px rgba(0, 0, 0, .45);

animation: letter 3s ease-in-out infinite alternate;
}
@keyframes span {
0%,30%{ margin: 0 15px; }
70%,100%{ margin: 0 5px; }
}
@keyframes letter {
0%,30%{ width: 27px; }
70%,100%{ width: 30vw; }
}