Compare commits
No commits in common. "84baaff88a51257f16920201318ee78e535df5a6" and "f4bd302e9d47e31a91ea62afc3710812899652df" have entirely different histories.
84baaff88a
...
f4bd302e9d
@ -7,11 +7,10 @@
|
||||
</ul>
|
||||
</div>
|
||||
<div class="fixed-bottom form-inline">
|
||||
<textarea id="msgbox" class="form-control" style="width:85%; float: left;"></textarea>
|
||||
<textarea id="msgbox" class="form-control" style="min-width:80%"></textarea>
|
||||
<button id="btn-send"
|
||||
class="btn btn-info"
|
||||
type="button"
|
||||
style="width: 10%;"
|
||||
onclick="send_message()"
|
||||
disabled>
|
||||
<svg xmlns="http://www.w3.org/2000/svg"
|
||||
@ -51,17 +50,18 @@
|
||||
var li = document.createElement('li');
|
||||
var pre = document.createElement('pre');
|
||||
li.appendChild(pre)
|
||||
li.style.textAlign = "left"
|
||||
li.style.padding = "10px"
|
||||
li.style.clear = "both"
|
||||
li.style.marginBottom = "20px"
|
||||
if (msg.response == "" && msg.request != "") {
|
||||
li.style.textAlign = "right"
|
||||
pre.innerText = msg.request
|
||||
pre.style = "background-color: lightblue; border-radius: 10px; padding: 5px; white-space: pre-wrap; word-wrap: break-word; float: right;"
|
||||
pre.style.backgroundColor = "lightblue"
|
||||
} else if (msg.request != "") {
|
||||
li.style.textAlign = "left"
|
||||
pre.innerText = msg.response
|
||||
pre.style = "background-color: lightgreen; border-radius: 10px; padding: 5px; white-space: pre-wrap; word-wrap: break-word;"
|
||||
pre.style.backgroundColor = "lightgreen"
|
||||
}
|
||||
pre.style.borderRadius = "10px"
|
||||
pre.style.padding = "5px"
|
||||
msg_list.appendChild(li)
|
||||
})
|
||||
window.scrollTo(0,document.documentElement.scrollHeight)
|
||||
@ -82,11 +82,12 @@
|
||||
var li = document.createElement('li');
|
||||
var pre = document.createElement('pre');
|
||||
li.appendChild(pre)
|
||||
li.style.textAlign = "left"
|
||||
li.style.padding = "10px"
|
||||
li.style.clear = "both"
|
||||
pre.innerText = data.msg
|
||||
pre.style = "background-color: lightblue; border-radius: 10px; padding: 5px; white-space: pre-wrap; word-wrap: break-word; float: right;"
|
||||
li.style.textAlign="right"
|
||||
li.style.marginBottom="20px"
|
||||
pre.innerText=data.msg
|
||||
pre.style.backgroundColor="lightblue"
|
||||
pre.style.borderRadius="10px"
|
||||
pre.style.padding="5px"
|
||||
msg_list.appendChild(li)
|
||||
}
|
||||
msgbox.value=""
|
||||
@ -104,11 +105,12 @@
|
||||
var li = document.createElement('li');
|
||||
var pre = document.createElement('pre');
|
||||
li.appendChild(pre)
|
||||
pre.innerText = response.message
|
||||
li.style.textAlign = "left"
|
||||
li.style.padding = "10px"
|
||||
li.style.clear = "both"
|
||||
pre.style = "background-color: lightgreen; border-radius: 10px; padding: 5px; white-space: pre-wrap; word-wrap: break-word;"
|
||||
pre.innerText=response.message
|
||||
li.style.textAlign="left"
|
||||
li.style.marginBottom="20px"
|
||||
pre.style.backgroundColor="lightgreen"
|
||||
pre.style.borderRadius="10px"
|
||||
pre.style.padding="5px"
|
||||
msg_list.appendChild(li)
|
||||
msg_list.appendChild(document.createElement('br'))
|
||||
}
|
||||
|
Reference in New Issue
Block a user