mirror of
https://github.com/hack-chat/main.git
synced 2024-03-22 13:20:33 +08:00
Merge pull request #18 from OpSimple/master
Solved the sidebar scroll for mobile users
This commit is contained in:
commit
8b86f3a8f4
|
@ -24,7 +24,7 @@ var frontpage = [
|
||||||
"",
|
"",
|
||||||
"Legacy GitHub: https://github.com/AndrewBelt/hack.chat",
|
"Legacy GitHub: https://github.com/AndrewBelt/hack.chat",
|
||||||
"Android apps: https://goo.gl/UkbKYy https://goo.gl/qasdSu https://goo.gl/fGQFQN",
|
"Android apps: https://goo.gl/UkbKYy https://goo.gl/qasdSu https://goo.gl/fGQFQN",
|
||||||
"Other Softwares: https://github.com/hack-chat/3rd-party-software-list"
|
"Other Softwares: https://github.com/hack-chat/3rd-party-software-list",
|
||||||
"",
|
"",
|
||||||
"Server and web client released under the WTFPL and MIT open source license.",
|
"Server and web client released under the WTFPL and MIT open source license.",
|
||||||
"No message history is retained on the hack.chat server."
|
"No message history is retained on the hack.chat server."
|
||||||
|
@ -414,12 +414,14 @@ updateInputSize();
|
||||||
|
|
||||||
$('#sidebar').onmouseenter = $('#sidebar').ontouchstart = function (e) {
|
$('#sidebar').onmouseenter = $('#sidebar').ontouchstart = function (e) {
|
||||||
$('#sidebar-content').classList.remove('hidden');
|
$('#sidebar-content').classList.remove('hidden');
|
||||||
|
$('#sidebar').classList.add('expand');
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
}
|
}
|
||||||
|
|
||||||
$('#sidebar').onmouseleave = document.ontouchstart = function () {
|
$('#sidebar').onmouseleave = document.ontouchstart = function () {
|
||||||
if (!$('#pin-sidebar').checked) {
|
if (!$('#pin-sidebar').checked) {
|
||||||
$('#sidebar-content').classList.add('hidden');
|
$('#sidebar-content').classList.add('hidden');
|
||||||
|
$('#sidebar').classList.remove('expand');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -52,6 +52,9 @@ ul li {
|
||||||
.hidden {
|
.hidden {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
.expand {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
.container {
|
.container {
|
||||||
max-width: 600px;
|
max-width: 600px;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
|
@ -108,6 +111,7 @@ ul li {
|
||||||
}
|
}
|
||||||
#sidebar-content {
|
#sidebar-content {
|
||||||
width: 180px;
|
width: 180px;
|
||||||
|
padding-bottom: 10%;
|
||||||
}
|
}
|
||||||
@media only screen and (max-width: 600px) {
|
@media only screen and (max-width: 600px) {
|
||||||
.messages {
|
.messages {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user