Created
March 29, 2018 14:09
-
-
Save diego3g/a3b8dc290750e928eb05e33a26670a0a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
html, body { | |
height: 100%; | |
} | |
* { | |
margin: 0; | |
padding: 0; | |
box-sizing: border-box; | |
} | |
#chat { | |
height: 100%; | |
display: flex; | |
justify-content: center; | |
align-items: center; | |
flex-direction: column; | |
} | |
input { | |
width: 600px; | |
border: 1px solid #ddd; | |
height: 50px; | |
padding: 0 20px; | |
font-size: 14px; | |
} | |
button { | |
width: 600px; | |
height: 50px; | |
font-size: 14px; | |
background: #069; | |
text-align: center; | |
line-height: 50px; | |
font-weight: bold; | |
color: #FFF; | |
margin-top: 10px; | |
} | |
.messages { | |
width: 600px; | |
height: 400px; | |
margin: 20px 0; | |
border: 1px solid #ddd; | |
padding: 20px; | |
} |
estilo responsivo:
html, body { height: 100%; } * { margin: 0; padding: 0; box-sizing: border-box; } #chat { height: 100%; display: flex; justify-content: center; align-items: center; flex-direction: column; padding: 2vw; } input { width: 60vw; border: 1px solid #ddd; height: 5vw; padding: 0 2vw; font-size: 1.5vw; } button { width: 60vw; height: 5vw; font-size: 1.5vw; background: #069; text-align: center; line-height: 5vw; font-weight: bold; color: #FFF; margin-top: 1vw; border: none; } .messages { width: 60vw; height: 40vw; margin: 2vw 0; border: 1px solid #ddd; padding: 2vw; }
Eu adicionei ao seu código
@media screen and (max-width: 990px) {
input,
button,
.messages {
width: 90%;
}
input,
button {
height: 2rem;
font-size: 1rem;
}
.messages {
height: 60%;
}
}
E deu uma melhorada para celulares, eu estava achando muito pequeno as coisas.
Muito boas as tuas correções. Mas o código é apenas para mostrar o uso de webSocket.. mas não é nada mal dares uma melhorada.. tanto um quanto o outro ajudou-me muito para entender a parada. muito grato
os estilos responsivos estao todos quebrados ... e e muito estranhos. kkkkkk quem fez nao testou.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
estilo responsivo: