Lars #158

Merged
11291680 merged 1 commits from lars into master 2017-01-31 10:33:21 +01:00
11 changed files with 125 additions and 25 deletions

View File

@@ -60,7 +60,6 @@ function adminSearch() {
"API/adminSearchUsers.php", "API/adminSearchUsers.php",
$("#admin-searchform").serialize() $("#admin-searchform").serialize()
).done(function (data) { ).done(function (data) {
console.log(data);
$("#usertable").html(data); $("#usertable").html(data);
}) })
} }

View File

@@ -48,9 +48,6 @@ function placeFriendButtons() {
text2 = "Weiger"; text2 = "Weiger";
icon2 = "fa-times"; icon2 = "fa-times";
break; break;
default:
console.log(friendshipStatus);
break;
} }
$buttonContainer.append( $buttonContainer.append(

View File

@@ -1,25 +1,37 @@
$(document).ready(function() { $(document).ready(function() {
// Toggle menu // Toggle menu
$("#own-profile-picture, #open-notifications").click(function() { $("#own-profile-picture, #open-notifications").click(function() {
if ($("#notification-center").css('right') == "-256px") { if ($("#notification-center").css('display') == "none") {
// Make the menu visible and move the content to the left. // Make the menu visible and move the content to the left.
$("#chat-history").width("calc(100% - 587px)"); $(".modal").width("calc(100% - 512px)");
$(".modal").width("calc(100% - 512px)"); $(".content").css("margin-right", "256px");
$(".content").css("margin-right", "256px"); $("#notification-center").css("right", "0px");
$("#notification-center").css("right", "0px"); $("#notification-center").css("display", "block");
$("#contact-menu").css("display", "block");
// Add cookie so the menu stays open on other pages // Add cookie so the menu stays open on other pages
document.cookie = "menu=open; path=/"; if (window.innerWidth > 1080) {
} else { $("#chat-history").width("calc(100% - 587px)");
// Make the menu invisible and move the content to the right. document.cookie = "menu=open; path=/";
$("#chat-history").width("calc(100% - 331px)"); } else {
$(".modal").width("calc(100% - 256px)"); document.cookie = "menu=closed; path=/";
$(".content").css("margin-right", "0px"); }
$("#notification-center").css("right", "-256px"); } else {
$(".modal").width("calc(100% - 256px)");
$(".content").css("margin-right", "0px");
$("#notification-center").css("display", "none");
// Change menu cookie to close if (window.innerWidth > 1080) {
document.cookie = "menu=closed; path=/"; $("#chat-history").width("calc(100% - 331px)");
} } else {
// Make the menu invisible and move the content to the right.
$("#contact-menu").css("display", "none");
}
// Change menu cookie to close
document.cookie = "menu=closed; path=/";
}
}); });
if (getCookie("menu") == "open") { if (getCookie("menu") == "open") {

View File

@@ -146,8 +146,20 @@ body {
text-align: right; text-align: right;
} }
@media only screen and (max-width: 1200px) { @media only screen and (max-width: 1080px) {
.chat-message-self, .chat-message-other { .chat-message-self, .chat-message-other {
max-width: 75%; max-width: 75%;
} }
.chat {
left: 0;
width: 100%;
}
#chat-recent-panel {
left: 0;
width: 320px;
}
#chat-history {
left: 50%;
width: calc(100% - 390px);
}
} }

View File

@@ -26,7 +26,8 @@ header {
} }
#header-search { #header-search {
padding-left: 42px; margin: 24px 0 24px 32px;
vertical-align: middle;
} }
@@ -50,3 +51,9 @@ header div {
#open-notifications { #open-notifications {
padding: 5px 20px 5px 0px; padding: 5px 20px 5px 0px;
} }
@media only screen and (max-width: 1080px) {
#header-logo {
display: none;
}
}

View File

@@ -294,3 +294,13 @@ div[data-title]:hover:after {
border-radius: 20px; border-radius: 20px;
background: #4CAF50; background: #4CAF50;
} }
@media only screen and (max-width: 1080px) {
body {
font-size: 28px!important;
}
button {
font-size: 28px;
}
}

View File

@@ -87,3 +87,17 @@
padding: 0; padding: 0;
text-align: left; text-align: left;
} }
@media only screen and (max-width: 1080px) {
#contact-menu, #notification-center {
display: none;
background: rgba(0, 0, 0, 0.4);
width: calc(50% - 20px);
}
.content {
margin-left: 0;
}
#quick-links i {
font-size: 48px!important;
}
}

View File

@@ -0,0 +1,47 @@
/* MAIN */
body {
font-size: 28px!important;
}
button {
font-size: 28px;
}
/* HEADER */
#header-logo {
display: none;
}
/* PROFILE */
.post-box {
width: calc(100% - 65px);
}
/* MENU */
#contact-menu, #notification-center {
display: none;
background: rgba(0, 0, 0, 0.4);
width: calc(50% - 20px);
}
.content {
margin-left: 0;
}
#quick-links i {
font-size: 48px!important;
}
/* CHAT */
.chat-message-self, .chat-message-other {
max-width: 75%;
}
.chat {
left: 0;
width: 100%;
}
#chat-recent-panel {
left: 0;
width: 320px;
}
#chat-history {
left: 50%;
width: calc(100% - 390px);
}

View File

@@ -116,7 +116,7 @@ div.posts .post form textarea.newpost {
} }
/* mobile */ /* mobile */
@media only screen and (max-width: 1000px) { @media only screen and (max-width: 1080px) {
.post-box { .post-box {
width: calc(100% - 65px); width: calc(100% - 65px);
} }

View File

@@ -12,6 +12,8 @@
@import url("styles/header.css"); @import url("styles/header.css");
@import url("styles/menu.css"); @import url("styles/menu.css");
@import url("styles/footer.css"); @import url("styles/footer.css");
@import url("styles/mobilefriendly.css") screen and (orientation: portrait);
</style> </style>
<?php <?php

View File

@@ -1,4 +1,4 @@
<nav class="menu"> <nav class="menu" id="contact-menu">
<section id="friends-menu-section"> <section id="friends-menu-section">
<h4> <h4>
Recente vrienden Recente vrienden