Compare commits

...

3 Commits

Author SHA1 Message Date
1961047703 merge with Chatte 2023-12-18 21:29:35 +01:00
929c1fdeb3 merge with Chatte 2023-12-18 21:27:52 +01:00
609b045315 better css, add debug 2023-12-18 21:26:18 +01:00
6 changed files with 35 additions and 26 deletions

View File

@ -9,4 +9,4 @@
margin-right: auto;
margin-top: 90px;
border: 15px black solid;
}
}

View File

@ -1,7 +1,7 @@
body {
margin: 1vh;
margin: 20px;
font-family: 'Quicksand', sans-serif;
font-size: 3vh;
font-size: 60px;
}
a {

View File

@ -15,4 +15,4 @@
#app #main .profile
{
background-color: green;
}
}

View File

@ -1,13 +1,13 @@
#app img
{
max-height: 10vh;
max-width: 10vh;
max-height: 3em;
max-width: 3em;
}
#app ul
{
font-size: 2vh;
margin: 1vh 0 0 0;
font-size: 0.75em;
margin: 0.25em 0 0 0;
padding: 0 0 0 0;
list-style-type: none;
max-height: 80vh;
@ -16,7 +16,7 @@
#app li
{
margin: 1vh 1vh 0 0;
margin: 0.25em 0.25em 0 0;
}
#app #chats {
@ -25,37 +25,41 @@
text-align: left;
}
#app #users {
margin: 0vh 5vh 0vh 0.1vh;
margin: 0em 1.0em 0em 0.05em;
}
#app #chat {
position: relative;
max-height: 80vh;
width: 80vh;
max-height: 86vh;
width: 100vh;
/*border: 2px solid green;*/
overflow: hidden;
}
#app #members {
font-size: 1em;
}
#app #add_chat_off {
text-decoration: underline;
}
#app #messages {
max-height: 50vh;
max-height: 50em;
overflow: scroll;
overflow-y: scroll;
overflow-x: hidden;
font-size: 2vh;
font-size: 0.6em;
}
#app #input_user{
color: green;
width: 20vh;
height: 2.5vh;
font-size: 2vh;
width: 8.5em;
height: 1.1em;
font-size: 0.75em;
border: none;
outline: none;
border-bottom: 0.25vh solid green;
border-bottom: 0.15em solid green;
}
#app #input_chat{
@ -65,18 +69,18 @@
width: 100%;
border: none;
outline: none;
border-bottom: 0.25vh solid green;
border-bottom: 0.2em solid green;
caret-color: green;
color: green;
font-size: 2vh;
font-size: 0.65em;
}
#app #you {
text-align: left;
position: relative;
max-width: 48%;
left: 2vh;
margin: 1vh 0 0 0;
left: 0.5em;
margin: 0.5em 0 0 0;
color: green;
word-wrap: break-word;
@ -86,8 +90,8 @@
text-align: right;
position: relative;
max-width: 48%;
margin: 1vh 0 0 auto;
right: 2vh;
margin: 0.5em 0 0 auto;
right: 0.5em;
color: red;
/* permet le retour à la ligne à la place de dépasser*/

View File

@ -8,10 +8,13 @@ class Channels {
async createChannel(users_id, reload) {
let null_id = false;
users_id.forEach(user_id => {
if (user_id == null)
return console.log("createChannel error, null id;");
null_id = true;
});
if (null_id)
return console.log(users_id, "createChannel error, null id;");
let response = await this.client._post("/api/chat/", {
users_id:users_id

View File

@ -185,6 +185,9 @@ export default class extends AbstractView {
messages.appendChild(text);
});
// Scroll to the bottom of messages
messages.scrollTop = messages.scrollHeight;
}
async hideChat() {
@ -212,7 +215,6 @@ export default class extends AbstractView {
</ul>
</div>
</div>
`;
}
}