fixed index.html centering and added segfault text
This commit is contained in:
parent
6991ab7641
commit
56c84c155a
2 changed files with 54 additions and 20 deletions
|
|
@ -4,14 +4,21 @@
|
||||||
<link rel="stylesheet" href="typing.css">
|
<link rel="stylesheet" href="typing.css">
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="centered heading typing-wrapper">
|
<div class="centered heading">
|
||||||
|
<div class="typing-wrapper">
|
||||||
|
<div>
|
||||||
<!-- Comment between divs is intentional and removes implicit spacing -->
|
<!-- Comment between divs is intentional and removes implicit spacing -->
|
||||||
<div class="typing-prompt">
|
<div class="typing-prompt">
|
||||||
$ 
|
$ 
|
||||||
</div><!--
|
</div><!--
|
||||||
--><div class="typing">
|
--><div class="typing-prompt typing-effect">
|
||||||
Do butterflies cry when they're sad?
|
Do butterflies cry when they're sad?
|
||||||
</div>
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="typing-result">
|
||||||
|
Segmentation fault (core dumped)
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,21 @@
|
||||||
body {
|
html, body {
|
||||||
|
height: 100%;
|
||||||
|
margin: 0;
|
||||||
background-color: #0e0d14;
|
background-color: #0e0d14;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.centered {
|
||||||
|
position: absolute;
|
||||||
|
inset: 0 0 0 0;
|
||||||
|
|
||||||
|
margin: auto;
|
||||||
|
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-content: center;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
.heading {
|
.heading {
|
||||||
font-family: monospace;
|
font-family: monospace;
|
||||||
font-size: 2em;
|
font-size: 2em;
|
||||||
|
|
@ -9,42 +23,55 @@ body {
|
||||||
color: #ac4aed;
|
color: #ac4aed;
|
||||||
}
|
}
|
||||||
|
|
||||||
.centered {
|
|
||||||
margin-top: 25%; /* terrible solution... */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* =========================================================== *
|
/* =========================================================== *
|
||||||
* Type Writer Effect *
|
* Type Writer Effect *
|
||||||
/* =========================================================== */
|
/* =========================================================== */
|
||||||
|
|
||||||
.typing-wrapper {
|
.typing-wrapper {
|
||||||
display: flex;
|
/* display: flex; */
|
||||||
text-align: center;
|
/* flex-direction: column; */
|
||||||
justify-content: center;
|
/* text-align: center; */
|
||||||
|
/* justify-items: flex-start; */
|
||||||
|
/* align-items: center; */
|
||||||
|
|
||||||
|
width: 39ch; /* length of typing-prompt + cursor */
|
||||||
|
|
||||||
|
border: 3px solid #ac4aed;
|
||||||
|
padding: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.typing-prompt {
|
.typing-prompt {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
text-align: center;
|
text-align: start;
|
||||||
}
|
}
|
||||||
|
|
||||||
.typing {
|
.typing-effect {
|
||||||
display: inline-block;
|
|
||||||
width: 36ch;
|
width: 36ch;
|
||||||
animation: typing 3s steps(36), blink 1s step-end 3s infinite alternate;
|
animation: typing 3s steps(36), cursor-blink 1s step-end 3s infinite alternate;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
border-right: 1ch solid;
|
border-right: 1ch solid;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.typing-result {
|
||||||
|
animation: unhide 1s 3.8s forwards;
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes typing {
|
@keyframes typing {
|
||||||
from {
|
from {
|
||||||
width: 0
|
width: 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes blink {
|
@keyframes cursor-blink {
|
||||||
50% {
|
50% {
|
||||||
border-color: transparent
|
border-color: transparent
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@keyframes unhide {
|
||||||
|
to {
|
||||||
|
visibility: visible
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue