CSS
语言:
CSSSCSS
确定
body {
font-family: 'Roboto', sans-serif;
}
.emojify-input {
border: #DDD 1px solid;
box-shadow: inset 0px -1px 2px rgba(0, 0, 0, 0.1), inset 0px 1px 2px rgba(0, 0, 0, 0.1);
border-radius: 5px;
height: 150px;
width: 300px;
padding: 15px;
font-size: 12pt;
line-height: 18pt;
margin: 15% auto 0 auto;
outline: none;
}
.emojify-input .emojiChar {
padding: 0 0 0 3px;
}
.emojify-input span.detectedEmoji {
color: #ff9933;
font-weight: 500;
cursor: pointer;
display: inline-block;
position: relative;
background: -webkit-linear-gradient(0deg, #ff9933, #EF3D35, #ff9933);
background: linear-gradient(90deg, #ff9933, #EF3D35, #ff9933);
background-position: 0 0;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
-webkit-animation: shinny 5s infinite, bounce 500ms 1;
animation: shinny 5s infinite, bounce 500ms 1;
-webkit-transition: all 250ms ease-in-out;
transition: all 250ms ease-in-out;
-webkit-transform: translateY(0);
transform: translateY(0);
}
.emojify-input span.detectedEmoji .selector {
position: absolute;
background-color: #FFF;
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
width: auto;
border-radius: 5px;
padding: 5px 15px 5px 15px;
text-align: center;
top: -42px;
letter-spacing: 4px;
border-top: #EEE 1px solid;
z-index: 3;
-webkit-background-clip: none;
-webkit-text-fill-color: #333;
}
.emojify-input span.detectedEmoji .selector:before {
content: '';
position: absolute;
bottom: -7px;
left: 50%;
width: 0;
height: 0;
margin-left: -8px;
border-left: 8px solid transparent;
border-right: 8px solid transparent;
border-top: 8px solid #FFF;
z-index: 2;
}
.emojify-input span.detectedEmoji .selector:after {
content: '';
position: absolute;
bottom: -8px;
left: 50%;
width: 0;
height: 0;
margin-left: -8px;
border-left: 8px solid transparent;
border-right: 8px solid transparent;
border-top: 8px solid #CCC;
z-index: 1;
}
#emojifyIt {
height: 50px;
width: 300px;
padding: 15px;
font-size: 12pt;
margin: 10px auto;
display: block;
border: 0;
background-color: #FFF;
color: #2D72D9;
font-weight: 500;
text-transform: uppercase;
}
#emojifyIt:hover {
background-color: #2D72D9;
color: #FFF;
border-radius: 5px;
cursor: pointer;
}
@-webkit-keyframes shinny {
0% {
background-position: 0 0;
}
100% {
background-position: 150px 0;
}
}
@keyframes shinny {
0% {
background-position: 0 0;
}
100% {
background-position: 150px 0;
}
}
@-webkit-keyframes bounce {
0% {
-webkit-transform: scale(1) rotate(0);
transform: scale(1) rotate(0);
}
50% {
-webkit-transform: scale(1.1) rotate(-2deg);
transform: scale(1.1) rotate(-2deg);
}
100% {
-webkit-transform: scale(1) rotate(0);
transform: scale(1) rotate(0);
}
}
@keyframes bounce {
0% {
-webkit-transform: scale(1) rotate(0);
transform: scale(1) rotate(0);
}
50% {
-webkit-transform: scale(1.1) rotate(-2deg);
transform: scale(1.1) rotate(-2deg);
}
100% {
-webkit-transform: scale(1) rotate(0);
transform: scale(1) rotate(0);
}
}