Skip to content

Commit e38a94c

Browse files
Create styles.css
1 parent 7f3da1b commit e38a94c

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

CSS Typewriter/styles.css

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
.wrapper {
2+
height: 100vh;
3+
/*This part is important for centering*/
4+
display: grid;
5+
place-items: center;
6+
}
7+
8+
.typing-demo {
9+
width: 22ch;
10+
animation: typing 2s steps(22), blink .5s step-end infinite alternate;
11+
white-space: nowrap;
12+
overflow: hidden;
13+
border-right: 3px solid;
14+
font-family: monospace;
15+
font-size: 2em;
16+
}
17+
18+
@keyframes typing {
19+
from {
20+
width: 0
21+
}
22+
}
23+
24+
@keyframes blink {
25+
50% {
26+
border-color: transparent
27+
}
28+
}

0 commit comments

Comments
 (0)