Merge pull request #9850 from Extarys/frio-formating
frio: formating, otherwise untouched
This commit is contained in:
commit
1a9bc9e444
25 changed files with 3291 additions and 2928 deletions
|
@ -13,9 +13,21 @@ This file applies Font Awesome icons to some friendica standard classes
|
|||
font-size: 1.4em;
|
||||
}
|
||||
/* media icons */
|
||||
.icon.type-image:before { content: "\f1c5"; }
|
||||
.icon.type-video:before { content: "\f1c8"; }
|
||||
.icon.type-audio:before { content: "\f1c7"; }
|
||||
.icon.type-text:before { content: "\f0f6"; }
|
||||
.icon.type-application:before { content: "\f016"; }
|
||||
.icon.type-unkn:before { content: "\f016"; }
|
||||
.icon.type-image:before {
|
||||
content: "\f1c5";
|
||||
}
|
||||
.icon.type-video:before {
|
||||
content: "\f1c8";
|
||||
}
|
||||
.icon.type-audio:before {
|
||||
content: "\f1c7";
|
||||
}
|
||||
.icon.type-text:before {
|
||||
content: "\f0f6";
|
||||
}
|
||||
.icon.type-application:before {
|
||||
content: "\f016";
|
||||
}
|
||||
.icon.type-unkn:before {
|
||||
content: "\f016";
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
.hovercard {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
|
@ -202,7 +201,6 @@
|
|||
text-decoration: none !important;
|
||||
}
|
||||
|
||||
|
||||
/* Basic hovercard */
|
||||
.basic-content {
|
||||
padding: 9px;
|
||||
|
@ -285,7 +283,6 @@
|
|||
|
||||
.hover-card-header h4 {
|
||||
display: block;
|
||||
|
||||
}
|
||||
|
||||
.hover-card-header h4 a {
|
||||
|
|
|
@ -1,17 +1,33 @@
|
|||
#adminpage.adminpage > h1 { padding: 0 15px; }
|
||||
#adminpage.adminpage > h1 {
|
||||
padding: 0 15px;
|
||||
}
|
||||
|
||||
#users th:first-of-type { width: 1em; }
|
||||
#users th:nth-of-type(2) { width: 40px; }
|
||||
#users th:last-of-type { width: 1em; }
|
||||
.admin-settings-footer-elements { padding-left: 8px; padding-right: 8px; }
|
||||
#users th:first-of-type {
|
||||
width: 1em;
|
||||
}
|
||||
#users th:nth-of-type(2) {
|
||||
width: 40px;
|
||||
}
|
||||
#users th:last-of-type {
|
||||
width: 1em;
|
||||
}
|
||||
.admin-settings-footer-elements {
|
||||
padding-left: 8px;
|
||||
padding-right: 8px;
|
||||
}
|
||||
|
||||
#deleted th:first-of-type { width: 40px; }
|
||||
#deleted th:first-of-type {
|
||||
width: 40px;
|
||||
}
|
||||
|
||||
#users img.avatar-nano,
|
||||
#deleted img.avatar-nano {
|
||||
height: 24px; width: 24px;
|
||||
height: 24px;
|
||||
width: 24px;
|
||||
}
|
||||
.opened .caret {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
.opened .caret { transform: rotate(180deg); }
|
||||
tr.details td,
|
||||
tr.details th {
|
||||
border-top: 0 !important;
|
||||
|
@ -21,4 +37,6 @@ tr.details th {
|
|||
.adminpage th > .checkbox {
|
||||
margin: 0;
|
||||
}
|
||||
.adminpage td { word-break: break-all; }
|
||||
.adminpage td {
|
||||
word-break: break-all;
|
||||
}
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -1,51 +1,53 @@
|
|||
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPLv3-or-later
|
||||
$(function () {
|
||||
// Jot attachment live preview.
|
||||
let $textarea = $('textarea[name=body]');
|
||||
let $textarea = $("textarea[name=body]");
|
||||
$textarea.linkPreview();
|
||||
$textarea.keyup(function () {
|
||||
var textlen = $(this).val().length;
|
||||
$('#character-counter').text(textlen);
|
||||
$("#character-counter").text(textlen);
|
||||
});
|
||||
$textarea.editor_autocomplete(baseurl + '/search/acl');
|
||||
$textarea.bbco_autocomplete('bbcode');
|
||||
$textarea.editor_autocomplete(baseurl + "/search/acl");
|
||||
$textarea.bbco_autocomplete("bbcode");
|
||||
|
||||
let location_button = document.getElementById('profile-location');
|
||||
let location_input = document.getElementById('jot-location');
|
||||
let location_button = document.getElementById("profile-location");
|
||||
let location_input = document.getElementById("jot-location");
|
||||
|
||||
if (location_button && location_input) {
|
||||
updateLocationButtonDisplay(location_button, location_input);
|
||||
|
||||
location_input.addEventListener('change', function () {
|
||||
location_input.addEventListener("change", function () {
|
||||
updateLocationButtonDisplay(location_button, location_input);
|
||||
});
|
||||
location_input.addEventListener('keyup', function () {
|
||||
location_input.addEventListener("keyup", function () {
|
||||
updateLocationButtonDisplay(location_button, location_input);
|
||||
});
|
||||
|
||||
location_button.addEventListener('click', function() {
|
||||
location_button.addEventListener("click", function () {
|
||||
if (location_input.value) {
|
||||
location_input.value = '';
|
||||
location_input.value = "";
|
||||
updateLocationButtonDisplay(location_button, location_input);
|
||||
} else if ("geolocation" in navigator) {
|
||||
navigator.geolocation.getCurrentPosition(function(position) {
|
||||
location_input.value = position.coords.latitude + ', ' + position.coords.longitude;
|
||||
navigator.geolocation.getCurrentPosition(
|
||||
function (position) {
|
||||
location_input.value = position.coords.latitude + ", " + position.coords.longitude;
|
||||
updateLocationButtonDisplay(location_button, location_input);
|
||||
}, function (error) {
|
||||
},
|
||||
function (error) {
|
||||
location_button.disabled = true;
|
||||
updateLocationButtonDisplay(location_button, location_input);
|
||||
});
|
||||
},
|
||||
);
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
function updateLocationButtonDisplay(location_button, location_input)
|
||||
{
|
||||
location_button.classList.remove('btn-primary');
|
||||
function updateLocationButtonDisplay(location_button, location_input) {
|
||||
location_button.classList.remove("btn-primary");
|
||||
if (location_input.value) {
|
||||
location_button.disabled = false;
|
||||
location_button.classList.add('btn-primary');
|
||||
location_button.classList.add("btn-primary");
|
||||
location_button.title = location_button.dataset.titleClear;
|
||||
} else if (!"geolocation" in navigator) {
|
||||
location_button.disabled = true;
|
||||
|
|
|
@ -1,36 +1,42 @@
|
|||
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPLv3-or-later
|
||||
$(document).ready(function () {
|
||||
// Go to the permissions tab if the checkbox is checked.
|
||||
$('body').on("click", "#id_share", function() {
|
||||
if ($('#id_share').is(':checked') && !( $('#id_share').attr("disabled"))) {
|
||||
$('#acl-wrapper').show();
|
||||
$("body")
|
||||
.on("click", "#id_share", function () {
|
||||
if ($("#id_share").is(":checked") && !$("#id_share").attr("disabled")) {
|
||||
$("#acl-wrapper").show();
|
||||
$("a#event-perms-lnk").parent("li").show();
|
||||
toggleEventNav("a#event-perms-lnk");
|
||||
eventAclActive();
|
||||
}
|
||||
else {
|
||||
$('#acl-wrapper').hide();
|
||||
} else {
|
||||
$("#acl-wrapper").hide();
|
||||
$("a#event-perms-lnk").parent("li").hide();
|
||||
}
|
||||
}).trigger('change');
|
||||
})
|
||||
.trigger("change");
|
||||
|
||||
// Disable the finish time input if the user disable it.
|
||||
$('body').on("change", "#id_nofinish", function() {
|
||||
enableDisableFinishDate()
|
||||
}).trigger('change');
|
||||
$("body")
|
||||
.on("change", "#id_nofinish", function () {
|
||||
enableDisableFinishDate();
|
||||
})
|
||||
.trigger("change");
|
||||
|
||||
// JS for the permission section.
|
||||
$('#contact_allow, #contact_deny, #group_allow, #group_deny').change(function() {
|
||||
$("#contact_allow, #contact_deny, #group_allow, #group_deny")
|
||||
.change(function () {
|
||||
var selstr;
|
||||
$('#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected').each( function() {
|
||||
$(
|
||||
"#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected",
|
||||
).each(function () {
|
||||
selstr = $(this).html();
|
||||
$('#jot-public').hide();
|
||||
$("#jot-public").hide();
|
||||
});
|
||||
if (selstr == null) {
|
||||
$('#jot-public').show();
|
||||
$("#jot-public").show();
|
||||
}
|
||||
|
||||
}).trigger('change');
|
||||
})
|
||||
.trigger("change");
|
||||
|
||||
// Change the event nav menu.tabs on click.
|
||||
$("body").on("click", "#event-nav > li > a", function (e) {
|
||||
|
@ -46,7 +52,7 @@ $(document).ready(function() {
|
|||
|
||||
// Clear some elements (e.g. the event-preview container) when
|
||||
// selecting a event nav link so it don't appear more than once.
|
||||
$('body').on("click", "#event-nav a", function(e) {
|
||||
$("body").on("click", "#event-nav a", function (e) {
|
||||
$("#event-preview").empty();
|
||||
e.preventDefault();
|
||||
});
|
||||
|
@ -55,14 +61,13 @@ $(document).ready(function() {
|
|||
// Load the html of the actual event and incect the output to the
|
||||
// event-edit section.
|
||||
function doEventPreview() {
|
||||
$('#event-edit-preview').val(1);
|
||||
$.post('events',$('#event-edit-form').serialize(), function(data) {
|
||||
$("#event-edit-preview").val(1);
|
||||
$.post("events", $("#event-edit-form").serialize(), function (data) {
|
||||
$("#event-preview").append(data);
|
||||
});
|
||||
$('#event-edit-preview').val(0);
|
||||
$("#event-edit-preview").val(0);
|
||||
}
|
||||
|
||||
|
||||
// The following functions show/hide the specific event-edit content
|
||||
// in dependence of the selected nav.
|
||||
function eventAclActive() {
|
||||
|
@ -70,7 +75,6 @@ function eventAclActive() {
|
|||
$("#event-acl-wrapper").show();
|
||||
}
|
||||
|
||||
|
||||
function eventPreviewActive() {
|
||||
$("#event-acl-wrapper, #event-edit-wrapper, #event-desc-wrapper").hide();
|
||||
$("#event-preview").show();
|
||||
|
@ -99,13 +103,9 @@ function toggleEventNav (elm) {
|
|||
$(elm).parent("li").addClass("active");
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Disable the input for the finish date if it is not available.
|
||||
function enableDisableFinishDate() {
|
||||
if( $('#id_nofinish').is(':checked'))
|
||||
$('#id_finish_text').prop("disabled", true);
|
||||
else
|
||||
$('#id_finish_text').prop("disabled", false);
|
||||
if ($("#id_nofinish").is(":checked")) $("#id_finish_text").prop("disabled", true);
|
||||
else $("#id_finish_text").prop("disabled", false);
|
||||
}
|
||||
// @license-end
|
||||
|
|
|
@ -52,7 +52,6 @@
|
|||
* });
|
||||
**/
|
||||
|
||||
|
||||
/*
|
||||
* IMPORTANT
|
||||
*
|
||||
|
@ -64,7 +63,6 @@
|
|||
*
|
||||
*/
|
||||
|
||||
|
||||
var FileBrowser = {
|
||||
nickname: "",
|
||||
type: "",
|
||||
|
@ -86,7 +84,7 @@ var FileBrowser = {
|
|||
// Get the comment textimput field
|
||||
var commentElm = document.getElementById("comment-edit-text-" + FileBrowser.id);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
console.log("FileBrowser: " + nickname, type, FileBrowser.event, FileBrowser.id);
|
||||
|
||||
|
@ -100,14 +98,20 @@ var FileBrowser = {
|
|||
// Click on album link
|
||||
$(".fbrowser").on("click", ".folders a, .path a", function (e) {
|
||||
e.preventDefault();
|
||||
var url = baseurl + "/fbrowser/" + FileBrowser.type + "/" + encodeURIComponent(this.dataset.folder) + "?mode=none&theme=frio";
|
||||
var url =
|
||||
baseurl +
|
||||
"/fbrowser/" +
|
||||
FileBrowser.type +
|
||||
"/" +
|
||||
encodeURIComponent(this.dataset.folder) +
|
||||
"?mode=none&theme=frio";
|
||||
FileBrowser.folder = this.dataset.folder;
|
||||
|
||||
FileBrowser.loadContent(url);
|
||||
});
|
||||
|
||||
//Embed on click
|
||||
$(".fbrowser").on('click', ".photo-album-photo-link", function(e) {
|
||||
$(".fbrowser").on("click", ".photo-album-photo-link", function (e) {
|
||||
e.preventDefault();
|
||||
|
||||
var embed = "";
|
||||
|
@ -123,36 +127,34 @@ var FileBrowser = {
|
|||
// Note: not the best solution but function commentOpenUI don't
|
||||
// work as expected (we need a way to wait until commentOpenUI would be finished).
|
||||
// As for now we insert pieces of this function here
|
||||
if ((commentElm !== null) && (typeof commentElm !== "undefined")) {
|
||||
if (commentElm !== null && typeof commentElm !== "undefined") {
|
||||
if (commentElm.value === "") {
|
||||
$("#comment-edit-text-" + FileBrowser.id).addClass("comment-edit-text-full").removeClass("comment-edit-text-empty");
|
||||
$("#comment-edit-text-" + FileBrowser.id)
|
||||
.addClass("comment-edit-text-full")
|
||||
.removeClass("comment-edit-text-empty");
|
||||
$("#comment-edit-submit-wrapper-" + FileBrowser.id).show();
|
||||
$("#comment-edit-text-" + FileBrowser.id).attr('tabindex','9');
|
||||
$("#comment-edit-submit-" + FileBrowser.id).attr('tabindex','10');
|
||||
$("#comment-edit-text-" + FileBrowser.id).attr("tabindex", "9");
|
||||
$("#comment-edit-submit-" + FileBrowser.id).attr("tabindex", "10");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
console.log(FileBrowser.event, this.dataset.filename, embed, FileBrowser.id);
|
||||
|
||||
$("body").trigger(FileBrowser.event, [
|
||||
this.dataset.filename,
|
||||
embed,
|
||||
FileBrowser.id,
|
||||
this.dataset.img
|
||||
]);
|
||||
$("body").trigger(FileBrowser.event, [this.dataset.filename, embed, FileBrowser.id, this.dataset.img]);
|
||||
|
||||
// Close model
|
||||
$('#modal').modal('hide');
|
||||
$("#modal").modal("hide");
|
||||
// Update autosize for this textarea
|
||||
autosize.update($(".text-autosize"));
|
||||
});
|
||||
|
||||
// EventListener for switching between image and file mode
|
||||
$(".fbrowser").on('click', ".fbswitcher .btn", function(e) {
|
||||
$(".fbrowser").on("click", ".fbswitcher .btn", function (e) {
|
||||
e.preventDefault();
|
||||
FileBrowser.type = this.getAttribute("data-mode");
|
||||
$(".fbrowser").removeClass().addClass("fbrowser " + FileBrowser.type);
|
||||
$(".fbrowser")
|
||||
.removeClass()
|
||||
.addClass("fbrowser " + FileBrowser.type);
|
||||
url = baseurl + "/fbrowser/" + FileBrowser.type + "?mode=none&theme=frio";
|
||||
|
||||
FileBrowser.loadContent(url);
|
||||
|
@ -163,49 +165,56 @@ var FileBrowser = {
|
|||
uploadButtons: function () {
|
||||
if ($("#upload-image").length) {
|
||||
//AjaxUpload for images
|
||||
var image_uploader = new window.AjaxUpload(
|
||||
'upload-image',
|
||||
{
|
||||
action: 'wall_upload/' + FileBrowser.nickname + '?response=json&album=' + encodeURIComponent(FileBrowser.folder),
|
||||
name: 'userfile',
|
||||
responseType: 'json',
|
||||
var image_uploader = new window.AjaxUpload("upload-image", {
|
||||
action:
|
||||
"wall_upload/" +
|
||||
FileBrowser.nickname +
|
||||
"?response=json&album=" +
|
||||
encodeURIComponent(FileBrowser.folder),
|
||||
name: "userfile",
|
||||
responseType: "json",
|
||||
onSubmit: function (file, ext) {
|
||||
$(".fbrowser-content").hide();
|
||||
$(".fbrowser .profile-rotator-wrapper").show();
|
||||
$(".error").addClass('hidden');
|
||||
$(".error").addClass("hidden");
|
||||
},
|
||||
onComplete: function (file, response) {
|
||||
if (response['error'] != undefined) {
|
||||
$(".error span").html(response['error']);
|
||||
$(".error").removeClass('hidden');
|
||||
if (response["error"] != undefined) {
|
||||
$(".error span").html(response["error"]);
|
||||
$(".error").removeClass("hidden");
|
||||
$(".fbrowser .profile-rotator-wrapper").hide();
|
||||
$(".fbrowser-content").show();
|
||||
return;
|
||||
}
|
||||
|
||||
// load new content to fbrowser window
|
||||
FileBrowser.loadContent(baseurl + '/fbrowser/' + FileBrowser.type + '/' + encodeURIComponent(FileBrowser.folder) + '?mode=none&theme=frio');
|
||||
}
|
||||
}
|
||||
FileBrowser.loadContent(
|
||||
baseurl +
|
||||
"/fbrowser/" +
|
||||
FileBrowser.type +
|
||||
"/" +
|
||||
encodeURIComponent(FileBrowser.folder) +
|
||||
"?mode=none&theme=frio",
|
||||
);
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
if ($("#upload-file").length) {
|
||||
//AjaxUpload for files
|
||||
var file_uploader = new window.AjaxUpload(
|
||||
'upload-file',
|
||||
{ action: 'wall_attach/' + FileBrowser.nickname + '?response=json',
|
||||
name: 'userfile',
|
||||
var file_uploader = new window.AjaxUpload("upload-file", {
|
||||
action: "wall_attach/" + FileBrowser.nickname + "?response=json",
|
||||
name: "userfile",
|
||||
onSubmit: function (file, ext) {
|
||||
$(".fbrowser-content").hide();
|
||||
$(".fbrowser .profile-rotator-wrapper").show();
|
||||
$(".error").addClass('hidden');
|
||||
$(".error").addClass("hidden");
|
||||
},
|
||||
onComplete: function (file, response) {
|
||||
if (response['error']!= undefined) {
|
||||
$(".error span").html(response['error']);
|
||||
$(".error").removeClass('hidden');
|
||||
$('#profile-rotator').hide();
|
||||
if (response["error"] != undefined) {
|
||||
$(".error span").html(response["error"]);
|
||||
$(".error").removeClass("hidden");
|
||||
$("#profile-rotator").hide();
|
||||
$(".fbrowser-content").show();
|
||||
return;
|
||||
}
|
||||
|
@ -213,9 +222,8 @@ var FileBrowser = {
|
|||
var url = baseurl + "/fbrowser/" + FileBrowser.type + "?mode=none&theme=frio";
|
||||
// Load new content to fbrowser window
|
||||
FileBrowser.loadContent(url);
|
||||
}
|
||||
}
|
||||
);
|
||||
},
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -236,7 +244,7 @@ var FileBrowser = {
|
|||
// load new content to fbrowser window
|
||||
$(".fbrowser").load(url, function (responseText, textStatus) {
|
||||
$(".profile-rotator-wrapper").hide();
|
||||
if (textStatus === 'success') {
|
||||
if (textStatus === "success") {
|
||||
$(".fbrowser_content").show();
|
||||
FileBrowser.postLoad();
|
||||
}
|
||||
|
@ -246,10 +254,10 @@ var FileBrowser = {
|
|||
// Initialize justified Gallery
|
||||
initGallery: function () {
|
||||
$(".fbrowser.image .fbrowser-content-container").justifiedGallery({
|
||||
'rowHeight': 80,
|
||||
'margins': 4,
|
||||
'border': 0
|
||||
rowHeight: 80,
|
||||
margins: 4,
|
||||
border: 0,
|
||||
});
|
||||
}
|
||||
},
|
||||
};
|
||||
// @license-end
|
||||
|
|
|
@ -9,16 +9,16 @@
|
|||
*
|
||||
*/
|
||||
$(document).ready(function () {
|
||||
let $body = $('body');
|
||||
let $body = $("body");
|
||||
// Prevents normal click action on click hovercard elements
|
||||
$body.on('click', '.userinfo.click-card', function (e) {
|
||||
$body.on("click", ".userinfo.click-card", function (e) {
|
||||
e.preventDefault();
|
||||
});
|
||||
// This event listener needs to be declared before the one that removes
|
||||
// all cards so that we can stop the immediate propagation of the event
|
||||
// Since the manual popover appears instantly and the hovercard removal is
|
||||
// on a 100ms delay, leaving event propagation immediately hides any click hovercard
|
||||
$body.on('mousedown', '.userinfo.click-card', function (e) {
|
||||
$body.on("mousedown", ".userinfo.click-card", function (e) {
|
||||
e.stopImmediatePropagation();
|
||||
let timeNow = new Date().getTime();
|
||||
|
||||
|
@ -26,14 +26,14 @@ $(document).ready(function () {
|
|||
let targetElement = $(this);
|
||||
|
||||
// get href-attribute
|
||||
if (targetElement.is('[href]')) {
|
||||
contactUrl = targetElement.attr('href');
|
||||
if (targetElement.is("[href]")) {
|
||||
contactUrl = targetElement.attr("href");
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
|
||||
// no hovercard for anchor links
|
||||
if (contactUrl.substring(0, 1) === '#') {
|
||||
if (contactUrl.substring(0, 1) === "#") {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -41,59 +41,62 @@ $(document).ready(function () {
|
|||
});
|
||||
|
||||
// hover cards should be removed very easily, e.g. when any of these events happens
|
||||
$body.on('mouseleave touchstart scroll mousedown submit keydown', function (e) {
|
||||
$body.on("mouseleave touchstart scroll mousedown submit keydown", function (e) {
|
||||
// remove hover card only for desktiop user, since on mobile we open the hovercards
|
||||
// by click event insteadof hover
|
||||
removeAllHovercards(e, new Date().getTime());
|
||||
});
|
||||
|
||||
$body.on('mouseover', '.userinfo.hover-card, .wall-item-responses a, .wall-item-bottom .mention a', function (e) {
|
||||
$body
|
||||
.on("mouseover", ".userinfo.hover-card, .wall-item-responses a, .wall-item-bottom .mention a", function (e) {
|
||||
let timeNow = new Date().getTime();
|
||||
removeAllHovercards(e, timeNow);
|
||||
let contactUrl = false;
|
||||
let targetElement = $(this);
|
||||
|
||||
// get href-attribute
|
||||
if (targetElement.is('[href]')) {
|
||||
contactUrl = targetElement.attr('href');
|
||||
if (targetElement.is("[href]")) {
|
||||
contactUrl = targetElement.attr("href");
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
|
||||
// no hover card if the element has the no-hover-card class
|
||||
if (targetElement.hasClass('no-hover-card')) {
|
||||
if (targetElement.hasClass("no-hover-card")) {
|
||||
return true;
|
||||
}
|
||||
|
||||
// no hovercard for anchor links
|
||||
if (contactUrl.substring(0, 1) === '#') {
|
||||
if (contactUrl.substring(0, 1) === "#") {
|
||||
return true;
|
||||
}
|
||||
|
||||
targetElement.attr('data-awaiting-hover-card', timeNow);
|
||||
targetElement.attr("data-awaiting-hover-card", timeNow);
|
||||
|
||||
// Delay until the hover-card does appear
|
||||
setTimeout(function () {
|
||||
if (
|
||||
targetElement.is(':hover')
|
||||
&& parseInt(targetElement.attr('data-awaiting-hover-card'), 10) === timeNow
|
||||
&& $('.hovercard').length === 0
|
||||
targetElement.is(":hover") &&
|
||||
parseInt(targetElement.attr("data-awaiting-hover-card"), 10) === timeNow &&
|
||||
$(".hovercard").length === 0
|
||||
) {
|
||||
openHovercard(targetElement, contactUrl, timeNow);
|
||||
}
|
||||
}, 500);
|
||||
}).on('mouseleave', '.userinfo.hover-card, .wall-item-responses a, .wall-item-bottom .mention a', function (e) { // action when mouse leaves the hover-card
|
||||
})
|
||||
.on("mouseleave", ".userinfo.hover-card, .wall-item-responses a, .wall-item-bottom .mention a", function (e) {
|
||||
// action when mouse leaves the hover-card
|
||||
removeAllHovercards(e, new Date().getTime());
|
||||
});
|
||||
|
||||
// if we're hovering a hover card, give it a class, so we don't remove it
|
||||
$body.on('mouseover', '.hovercard', function (e) {
|
||||
$(this).addClass('dont-remove-card');
|
||||
$body.on("mouseover", ".hovercard", function (e) {
|
||||
$(this).addClass("dont-remove-card");
|
||||
});
|
||||
|
||||
$body.on('mouseleave', '.hovercard', function (e) {
|
||||
$(this).removeClass('dont-remove-card');
|
||||
$(this).popover('hide');
|
||||
$body.on("mouseleave", ".hovercard", function (e) {
|
||||
$(this).removeClass("dont-remove-card");
|
||||
$(this).popover("hide");
|
||||
});
|
||||
}); // End of $(document).ready
|
||||
|
||||
|
@ -101,20 +104,20 @@ $(document).ready(function () {
|
|||
function removeAllHovercards(event, priorTo) {
|
||||
// don't remove hovercards until after 100ms, so user have time to move the cursor to it (which gives it the dont-remove-card class)
|
||||
setTimeout(function () {
|
||||
$.each($('.hovercard'), function () {
|
||||
let title = $(this).attr('data-orig-title');
|
||||
$.each($(".hovercard"), function () {
|
||||
let title = $(this).attr("data-orig-title");
|
||||
// don't remove card if it was created after removeAllhoverCards() was called
|
||||
if ($(this).data('card-created') < priorTo) {
|
||||
if ($(this).data("card-created") < priorTo) {
|
||||
// don't remove it if we're hovering it right now!
|
||||
if (!$(this).hasClass('dont-remove-card')) {
|
||||
let $handle = $('[data-hover-card-active="' + $(this).data('card-created') + '"]');
|
||||
$handle.removeAttr('data-hover-card-active');
|
||||
if (!$(this).hasClass("dont-remove-card")) {
|
||||
let $handle = $('[data-hover-card-active="' + $(this).data("card-created") + '"]');
|
||||
$handle.removeAttr("data-hover-card-active");
|
||||
|
||||
// Restoring the popover handle title
|
||||
let title = $handle.attr('data-orig-title');
|
||||
$handle.attr({'data-orig-title': '', title: title});
|
||||
let title = $handle.attr("data-orig-title");
|
||||
$handle.attr({ "data-orig-title": "", title: title });
|
||||
|
||||
$(this).popover('hide');
|
||||
$(this).popover("hide");
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -124,16 +127,17 @@ function removeAllHovercards(event, priorTo) {
|
|||
function openHovercard(targetElement, contactUrl, timeNow) {
|
||||
// store the title in a data attribute because Bootstrap
|
||||
// popover destroys the title attribute.
|
||||
let title = targetElement.attr('title');
|
||||
targetElement.attr({'data-orig-title': title, title: ''});
|
||||
let title = targetElement.attr("title");
|
||||
targetElement.attr({ "data-orig-title": title, title: "" });
|
||||
|
||||
// get an additional data atribute if the card is active
|
||||
targetElement.attr('data-hover-card-active', timeNow);
|
||||
targetElement.attr("data-hover-card-active", timeNow);
|
||||
// get the whole html content of the hover card and
|
||||
// push it to the bootstrap popover
|
||||
getHoverCardContent(contactUrl, function (data) {
|
||||
if (data) {
|
||||
targetElement.popover({
|
||||
targetElement
|
||||
.popover({
|
||||
html: true,
|
||||
placement: function () {
|
||||
// Calculate the placement of the the hovercard (if top or bottom)
|
||||
|
@ -141,18 +145,22 @@ function openHovercard(targetElement, contactUrl, timeNow) {
|
|||
// which triggers the hover-card
|
||||
let get_position = $(targetElement).offset().top - $(window).scrollTop();
|
||||
if (get_position < 270) {
|
||||
return 'bottom';
|
||||
return "bottom";
|
||||
}
|
||||
return 'top';
|
||||
return "top";
|
||||
},
|
||||
trigger: 'manual',
|
||||
template: '<div class="popover hovercard" data-card-created="' + timeNow + '"><div class="arrow"></div><div class="popover-content hovercard-content"></div></div>',
|
||||
trigger: "manual",
|
||||
template:
|
||||
'<div class="popover hovercard" data-card-created="' +
|
||||
timeNow +
|
||||
'"><div class="arrow"></div><div class="popover-content hovercard-content"></div></div>',
|
||||
content: data,
|
||||
container: 'body',
|
||||
container: "body",
|
||||
sanitizeFn: function (content) {
|
||||
return DOMPurify.sanitize(content)
|
||||
return DOMPurify.sanitize(content);
|
||||
},
|
||||
}).popover('show');
|
||||
})
|
||||
.popover("show");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -176,7 +184,7 @@ function getHoverCardContent(contact_url, callback) {
|
|||
}
|
||||
|
||||
$.ajax({
|
||||
url: baseurl + '/contact/hovercard',
|
||||
url: baseurl + "/contact/hovercard",
|
||||
data: postdata,
|
||||
success: function (data, textStatus, request) {
|
||||
getHoverCardContent.cache[nurl] = data;
|
||||
|
|
|
@ -11,28 +11,28 @@ var linkPreview;
|
|||
*/
|
||||
function jotGetLink() {
|
||||
var currentText = $("#profile-jot-text").val();
|
||||
var noAttachment = '';
|
||||
var noAttachment = "";
|
||||
reply = prompt(aStr.linkurl);
|
||||
if (reply && reply.length) {
|
||||
// There should be only one attachment per post.
|
||||
// So we need to remove the old one.
|
||||
$('#jot-attachment-preview').empty();
|
||||
$('#profile-rotator').show();
|
||||
$("#jot-attachment-preview").empty();
|
||||
$("#profile-rotator").show();
|
||||
if (currentText.includes("[attachment") && currentText.includes("[/attachment]")) {
|
||||
noAttachment = '&noAttachment=1';
|
||||
noAttachment = "&noAttachment=1";
|
||||
}
|
||||
|
||||
// We use the linkPreview library to have a preview
|
||||
// of the attachments.
|
||||
if (typeof linkPreview === 'object') {
|
||||
if (typeof linkPreview === "object") {
|
||||
linkPreview.crawlText(reply + noAttachment);
|
||||
|
||||
// Fallback: insert the attachment bbcode directly into the textarea
|
||||
// if the attachment live preview isn't available
|
||||
} else {
|
||||
$.get('parse_url?binurl=' + bin2hex(reply) + noAttachment, function(data) {
|
||||
$.get("parse_url?binurl=" + bin2hex(reply) + noAttachment, function (data) {
|
||||
addeditortext(data);
|
||||
$('#profile-rotator').hide();
|
||||
$("#profile-rotator").hide();
|
||||
});
|
||||
}
|
||||
autosize.update($("#profile-jot-text"));
|
||||
|
|
|
@ -3,37 +3,35 @@
|
|||
* Javascript for the admin module
|
||||
*/
|
||||
$(function () {
|
||||
let $body = $('body');
|
||||
$body.on('click', '.selectall', function() {
|
||||
selectall($(this).data('selectAll'));
|
||||
let $body = $("body");
|
||||
$body.on("click", ".selectall", function () {
|
||||
selectall($(this).data("selectAll"));
|
||||
});
|
||||
$body.on('click', '.selectnone', function() {
|
||||
selectnone($(this).data('selectNone'));
|
||||
$body.on("click", ".selectnone", function () {
|
||||
selectnone($(this).data("selectNone"));
|
||||
});
|
||||
|
||||
// Toggle checkbox status to all or none for all checkboxes of a specific
|
||||
// css class.
|
||||
$body.on('change', 'input[type=checkbox].selecttoggle', function() {
|
||||
$body.on("change", "input[type=checkbox].selecttoggle", function () {
|
||||
$this = $(this);
|
||||
if ($this.prop('checked')) {
|
||||
selectall($this.data('selectClass'));
|
||||
$this.attr('title', $this.data('selectNone'));
|
||||
if ($this.prop("checked")) {
|
||||
selectall($this.data("selectClass"));
|
||||
$this.attr("title", $this.data("selectNone"));
|
||||
} else {
|
||||
selectnone($this.data('selectClass'));
|
||||
$this.attr('title', $this.data('selectAll'));
|
||||
selectnone($this.data("selectClass"));
|
||||
$this.attr("title", $this.data("selectAll"));
|
||||
}
|
||||
});
|
||||
|
||||
function selectall(cls) {
|
||||
$('.' + cls).prop('checked', true);
|
||||
$("." + cls).prop("checked", true);
|
||||
return false;
|
||||
}
|
||||
function selectnone(cls) {
|
||||
$('.' + cls).prop('checked', false);
|
||||
$("." + cls).prop("checked", false);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
// Users
|
||||
|
|
|
@ -6,18 +6,16 @@ $(document).ready(function() {
|
|||
// Initiale autosize for the textareas.
|
||||
autosize($("textarea.text-autosize"));
|
||||
|
||||
|
||||
// Replace the drop contact link of the photo menu
|
||||
// with a confirmation modal.
|
||||
$("body").on("click", ".contact-photo-menu a", function (e) {
|
||||
var photoMenuLink = $(this).attr('href');
|
||||
var photoMenuLink = $(this).attr("href");
|
||||
if (typeof photoMenuLink !== "undefined" && photoMenuLink.indexOf("/drop?confirm=1") !== -1) {
|
||||
e.preventDefault();
|
||||
addToModal(photoMenuLink);
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
/**
|
||||
|
|
|
@ -8,6 +8,6 @@ var itemGuid = window.location.pathname.split("/").pop();
|
|||
|
||||
$(window).load(function () {
|
||||
// Scroll to the Item by its GUID
|
||||
scrollToItem('item-' + itemGuid);
|
||||
scrollToItem("item-" + itemGuid);
|
||||
});
|
||||
// @license-end
|
||||
|
|
|
@ -6,69 +6,80 @@
|
|||
|
||||
$(document).ready(function () {
|
||||
// start the fullCalendar
|
||||
$('#events-calendar').fullCalendar({
|
||||
$("#events-calendar").fullCalendar({
|
||||
firstDay: aStr.firstDay,
|
||||
monthNames: aStr['monthNames'],
|
||||
monthNamesShort: aStr['monthNamesShort'],
|
||||
dayNames: aStr['dayNames'],
|
||||
dayNamesShort: aStr['dayNamesShort'],
|
||||
monthNames: aStr["monthNames"],
|
||||
monthNamesShort: aStr["monthNamesShort"],
|
||||
dayNames: aStr["dayNames"],
|
||||
dayNamesShort: aStr["dayNamesShort"],
|
||||
allDayText: aStr.allday,
|
||||
noEventsMessage: aStr.noevent,
|
||||
buttonText: {
|
||||
today: aStr.today,
|
||||
month: aStr.month,
|
||||
week: aStr.week,
|
||||
day: aStr.day
|
||||
day: aStr.day,
|
||||
},
|
||||
events: baseurl + moduleUrl + '/json/',
|
||||
events: baseurl + moduleUrl + "/json/",
|
||||
header: {
|
||||
left: '',
|
||||
left: "",
|
||||
// center: 'title',
|
||||
right: ''
|
||||
right: "",
|
||||
},
|
||||
timeFormat: 'H:mm',
|
||||
timeFormat: "H:mm",
|
||||
eventClick: function (calEvent, jsEvent, view) {
|
||||
showEvent(calEvent.id);
|
||||
},
|
||||
loading: function (isLoading, view) {
|
||||
if (!isLoading) {
|
||||
$('td.fc-day').dblclick(function() { addToModal('/events/new?start='+$(this).data('date')); });
|
||||
$("td.fc-day").dblclick(function () {
|
||||
addToModal("/events/new?start=" + $(this).data("date"));
|
||||
});
|
||||
}
|
||||
},
|
||||
defaultView: 'month',
|
||||
defaultView: "month",
|
||||
aspectRatio: 1,
|
||||
eventRender: function (event, element, view) {
|
||||
//console.log(view.name);
|
||||
switch (view.name) {
|
||||
case "month":
|
||||
element.find(".fc-title").html(
|
||||
element
|
||||
.find(".fc-title")
|
||||
.html(
|
||||
"<span class='item-desc'>{2}</span>".format(
|
||||
event.item['author-avatar'],
|
||||
event.item['author-name'],
|
||||
event.item["author-avatar"],
|
||||
event.item["author-name"],
|
||||
event.title,
|
||||
event.item.desc,
|
||||
event.item.location
|
||||
));
|
||||
event.item.location,
|
||||
),
|
||||
);
|
||||
break;
|
||||
case "agendaWeek":
|
||||
if (event.item['author-name'] == null) return;
|
||||
element.find(".fc-title").html(
|
||||
if (event.item["author-name"] == null) return;
|
||||
element
|
||||
.find(".fc-title")
|
||||
.html(
|
||||
"<img src='{0}' style='height:12px; width:12px'>{1}<p>{2}</p><p>{3}</p>".format(
|
||||
event.item['author-avatar'],
|
||||
event.item['author-name'],
|
||||
event.item["author-avatar"],
|
||||
event.item["author-name"],
|
||||
event.item.desc,
|
||||
htmlToText(event.item.location)
|
||||
));
|
||||
htmlToText(event.item.location),
|
||||
),
|
||||
);
|
||||
break;
|
||||
case "agendaDay":
|
||||
if (event.item['author-name'] == null) return;
|
||||
element.find(".fc-title").html(
|
||||
if (event.item["author-name"] == null) return;
|
||||
element
|
||||
.find(".fc-title")
|
||||
.html(
|
||||
"<img src='{0}' style='height:24px;width:24px'>{1}<p>{2}</p><p>{3}</p>".format(
|
||||
event.item['author-avatar'],
|
||||
event.item['author-name'],
|
||||
event.item["author-avatar"],
|
||||
event.item["author-name"],
|
||||
event.item.desc,
|
||||
htmlToText(event.item.location)
|
||||
));
|
||||
htmlToText(event.item.location),
|
||||
),
|
||||
);
|
||||
break;
|
||||
case "listMonth":
|
||||
element.find(".fc-list-item-title").html(formatListViewEvent(event));
|
||||
|
@ -82,54 +93,53 @@ $(document).ready(function() {
|
|||
html: true,
|
||||
trigger: "hover",
|
||||
placement: "auto",
|
||||
template: '<div class="popover hovercard event-card"><div class="arrow"></div><div class="popover-content hovercard-content"></div></div>',
|
||||
template:
|
||||
'<div class="popover hovercard event-card"><div class="arrow"></div><div class="popover-content hovercard-content"></div></div>',
|
||||
sanitizeFn: function (content) {
|
||||
return DOMPurify.sanitize(content)
|
||||
return DOMPurify.sanitize(content);
|
||||
},
|
||||
});
|
||||
},
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
// center on date
|
||||
var args = location.href.replace(baseurl, "").split("/");
|
||||
if (modparams == 2) {
|
||||
if (args.length >= 5) {
|
||||
$("#events-calendar").fullCalendar('gotoDate',args[3] , args[4]-1);
|
||||
$("#events-calendar").fullCalendar("gotoDate", args[3], args[4] - 1);
|
||||
}
|
||||
} else {
|
||||
if (args.length >= 4) {
|
||||
$("#events-calendar").fullCalendar('gotoDate',args[2] , args[3]-1);
|
||||
$("#events-calendar").fullCalendar("gotoDate", args[2], args[3] - 1);
|
||||
}
|
||||
}
|
||||
|
||||
// echo the title
|
||||
var view = $('#events-calendar').fullCalendar('getView');
|
||||
$('#fc-title').text(view.title);
|
||||
var view = $("#events-calendar").fullCalendar("getView");
|
||||
$("#fc-title").text(view.title);
|
||||
|
||||
// show event popup
|
||||
var hash = location.hash.split("-")
|
||||
var hash = location.hash.split("-");
|
||||
if (hash.length == 2 && hash[0] == "#link") showEvent(hash[1]);
|
||||
|
||||
});
|
||||
|
||||
// loads the event into a modal
|
||||
function showEvent(eventid) {
|
||||
addToModal(baseurl + moduleUrl + '/?id=' + eventid);
|
||||
addToModal(baseurl + moduleUrl + "/?id=" + eventid);
|
||||
}
|
||||
|
||||
function changeView(action, viewName) {
|
||||
$('#events-calendar').fullCalendar(action, viewName);
|
||||
var view = $('#events-calendar').fullCalendar('getView');
|
||||
$('#fc-title').text(view.title);
|
||||
$("#events-calendar").fullCalendar(action, viewName);
|
||||
var view = $("#events-calendar").fullCalendar("getView");
|
||||
$("#fc-title").text(view.title);
|
||||
}
|
||||
|
||||
// The template for the bootstrap popover for displaying the event title and
|
||||
// author (it's the nearly the same template we use in frio for the contact
|
||||
// hover cards. So be careful when changing the css)
|
||||
function eventHoverBodyTemplate() {
|
||||
var template = '\
|
||||
var template =
|
||||
'\
|
||||
<div class="event-card-basic-content media">\
|
||||
<div class="event-card-details">\
|
||||
<div class="event-card-header">\
|
||||
|
@ -154,13 +164,15 @@ function eventHoverBodyTemplate() {
|
|||
|
||||
// The template for presenting the event location in the event hover-card
|
||||
function eventHoverLocationTemplate() {
|
||||
var template = '<span role="presentation" aria-hidden="true"> · </span>\
|
||||
var template =
|
||||
'<span role="presentation" aria-hidden="true"> · </span>\
|
||||
<span class="event-card-location"> {0}</span></div>';
|
||||
return template;
|
||||
}
|
||||
|
||||
function eventHoverProfileNameTemplate() {
|
||||
var template = '\
|
||||
var template =
|
||||
'\
|
||||
<div class="event-card-profile-name profile-entry-name">\
|
||||
<a href="{0}" class="userinfo">{1}</a>\
|
||||
</div>';
|
||||
|
@ -168,23 +180,23 @@ function eventHoverProfileNameTemplate() {
|
|||
}
|
||||
// transform the event data to html so we can use it in the event hover-card
|
||||
function eventHoverHtmlContent(event) {
|
||||
var eventLocation = '';
|
||||
var eventProfileName = '';
|
||||
var eventLocation = "";
|
||||
var eventProfileName = "";
|
||||
// Get the Browser language
|
||||
var locale = window.navigator.userLanguage || window.navigator.language;
|
||||
var data = '';
|
||||
var data = "";
|
||||
|
||||
// Use the browser language for date formatting
|
||||
moment.locale(locale);
|
||||
|
||||
// format dates to different styles
|
||||
var startDate = moment(event.item.start).format('dd HH:mm');
|
||||
var endDate = moment(event.item.finsih).format('dd HH:mm');
|
||||
var monthShort = moment(event.item.start).format('MMM');
|
||||
var dayNumberStart = moment(event.item.start).format('DD');
|
||||
var dayNumberEnd = moment(event.item.finish).format('DD');
|
||||
var startTime = moment(event.item.start).format('HH:mm');
|
||||
var endTime = moment(event.item.finish).format('HH:mm');
|
||||
var startDate = moment(event.item.start).format("dd HH:mm");
|
||||
var endDate = moment(event.item.finsih).format("dd HH:mm");
|
||||
var monthShort = moment(event.item.start).format("MMM");
|
||||
var dayNumberStart = moment(event.item.start).format("DD");
|
||||
var dayNumberEnd = moment(event.item.finish).format("DD");
|
||||
var startTime = moment(event.item.start).format("HH:mm");
|
||||
var endTime = moment(event.item.finish).format("HH:mm");
|
||||
var monthNumber;
|
||||
|
||||
var formattedDate = startDate;
|
||||
|
@ -192,14 +204,13 @@ function eventHoverHtmlContent(event) {
|
|||
// We only need the to format the end date if the event does have
|
||||
// a finish date.
|
||||
if (event.item.nofinish == 0) {
|
||||
formattedDate = startDate + ' - ' + endTime;
|
||||
formattedDate = startDate + " - " + endTime;
|
||||
|
||||
// use a different Format (15. Feb - 18. Feb) if the events end date
|
||||
// is not the start date
|
||||
if (dayNumberStart != dayNumberEnd) {
|
||||
formattedDate = moment(event.item.start).format('Do MMM') +
|
||||
' - ' +
|
||||
moment(event.item.finish).format('Do MMM');
|
||||
formattedDate =
|
||||
moment(event.item.start).format("Do MMM") + " - " + moment(event.item.finish).format("Do MMM");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -213,31 +224,26 @@ function eventHoverHtmlContent(event) {
|
|||
var eventLocationTemplate = eventHoverLocationTemplate();
|
||||
// Format the event location data according to the the event location
|
||||
// template
|
||||
eventLocation = eventLocationTemplate.format(
|
||||
eventLocationText
|
||||
);
|
||||
eventLocation = eventLocationTemplate.format(eventLocationText);
|
||||
}
|
||||
|
||||
// Get only template data if there exists a profile name
|
||||
if (event.item['author-name']) {
|
||||
if (event.item["author-name"]) {
|
||||
// Get the template
|
||||
var eventProfileNameTemplate = eventHoverProfileNameTemplate();
|
||||
// Insert the data into the template
|
||||
eventProfileName = eventProfileNameTemplate.format(
|
||||
event.item['author-link'],
|
||||
event.item['author-name']
|
||||
);
|
||||
eventProfileName = eventProfileNameTemplate.format(event.item["author-link"], event.item["author-name"]);
|
||||
}
|
||||
|
||||
// Format the event data according to the event hover template
|
||||
var formatted = data.format(
|
||||
event.item['author-avatar'], // this isn't used at the present time
|
||||
event.item["author-avatar"], // this isn't used at the present time
|
||||
eventProfileName,
|
||||
event.title,
|
||||
eventLocation,
|
||||
formattedDate,
|
||||
monthShort.replace('.', ''), // Get rid of possible dots in the string
|
||||
dayNumberStart
|
||||
monthShort.replace(".", ""), // Get rid of possible dots in the string
|
||||
dayNumberStart,
|
||||
);
|
||||
|
||||
return formatted;
|
||||
|
@ -246,7 +252,8 @@ function eventHoverHtmlContent(event) {
|
|||
// transform the the list view event element into formatted html
|
||||
function formatListViewEvent(event) {
|
||||
// The basic template for list view
|
||||
var template = '<td class="fc-list-item-title fc-widget-content">\
|
||||
var template =
|
||||
'<td class="fc-list-item-title fc-widget-content">\
|
||||
<hr class="seperator"></hr>\
|
||||
<div class="event-card">\
|
||||
<div class="popover-content hovercard-content">{0}</div>\
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
* The javascript for the group module
|
||||
*/
|
||||
|
||||
|
||||
$(document).ready(function () {
|
||||
// Add an event listeners on buttons for switching the contact list view
|
||||
$("body").on("click", ".group-list-switcher", function () {
|
||||
|
@ -28,7 +27,7 @@ function groupChangeMember(gid, cid, sec_token) {
|
|||
$(".tooltip").tooltip("hide");
|
||||
$("body").css("cursor", "wait");
|
||||
|
||||
$.get('group/' + gid + '/' + cid + "?t=" + sec_token, function(data) {
|
||||
$.get("group/" + gid + "/" + cid + "?t=" + sec_token, function (data) {
|
||||
// Insert the new group member list
|
||||
$("#group-update-wrapper").html(data);
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@ $(document).ready(function(){
|
|||
$(window).load(function () {
|
||||
// Scroll to the intro by its intro ID.
|
||||
if (isIntroID()) {
|
||||
scrollToItem('intro-' + introID);
|
||||
scrollToItem("intro-" + introID);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -1,32 +1,34 @@
|
|||
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPLv3-or-later
|
||||
|
||||
$(document).ready(function () {
|
||||
|
||||
$('#contact_allow, #contact_deny, #group_allow, #group_deny').change(function() {
|
||||
$("#contact_allow, #contact_deny, #group_allow, #group_deny")
|
||||
.change(function () {
|
||||
var selstr;
|
||||
$('#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected').each( function() {
|
||||
$(
|
||||
"#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected",
|
||||
).each(function () {
|
||||
selstr = $(this).html();
|
||||
$('#jot-perms-icon').removeClass('unlock').addClass('lock');
|
||||
$('#jot-public').hide();
|
||||
$("#jot-perms-icon").removeClass("unlock").addClass("lock");
|
||||
$("#jot-public").hide();
|
||||
});
|
||||
if (selstr == null) {
|
||||
$('#jot-perms-icon').removeClass('lock').addClass('unlock');
|
||||
$('#jot-public').show();
|
||||
$("#jot-perms-icon").removeClass("lock").addClass("unlock");
|
||||
$("#jot-public").show();
|
||||
}
|
||||
|
||||
}).trigger('change');
|
||||
})
|
||||
.trigger("change");
|
||||
|
||||
// Click event listener for the album edit link/button.
|
||||
$("body").on('click', '#album-edit-link', function() {
|
||||
$("body").on("click", "#album-edit-link", function () {
|
||||
var modalUrl = $(this).attr("data-modal-url");
|
||||
|
||||
if (typeof modalUrl !== "undefined") {
|
||||
addToModal(modalUrl, 'photo-album-edit-wrapper');
|
||||
addToModal(modalUrl, "photo-album-edit-wrapper");
|
||||
}
|
||||
});
|
||||
|
||||
// Click event listener for the album drop link/button.
|
||||
$("body").on('click', '#album-drop-link', function() {
|
||||
$("body").on("click", "#album-drop-link", function () {
|
||||
var modalUrl = $(this).attr("data-modal-url");
|
||||
|
||||
if (typeof modalUrl !== "undefined") {
|
||||
|
@ -43,8 +45,8 @@ $(window).load(function() {
|
|||
// Append the diminsons of the picture to the css of the photo-photo div
|
||||
// we do this to make it possible to have overlay navigation buttons for the photo
|
||||
$("#photo-photo").css({
|
||||
"width": pwidth,
|
||||
"height": pheight
|
||||
width: pwidth,
|
||||
height: pheight,
|
||||
});
|
||||
});
|
||||
// @license-end
|
||||
|
|
|
@ -5,10 +5,10 @@
|
|||
$(document).ready(function () {
|
||||
// Clear bs modal on close.
|
||||
// We need this to prevent that the modal displays old content.
|
||||
$('body, footer').on('hidden.bs.modal', '.modal', function () {
|
||||
$(this).removeData('bs.modal');
|
||||
$("body, footer").on("hidden.bs.modal", ".modal", function () {
|
||||
$(this).removeData("bs.modal");
|
||||
$("#modal-title").empty();
|
||||
$('#modal-body').empty();
|
||||
$("#modal-body").empty();
|
||||
// Remove the file browser from jot (else we would have problems
|
||||
// with AjaxUpload.
|
||||
$(".fbrowser").remove();
|
||||
|
@ -18,13 +18,13 @@ $(document).ready(function(){
|
|||
|
||||
// Clear bs modal on close.
|
||||
// We need this to prevent that the modal displays old content.
|
||||
$('body').on('hidden.bs.modal', '#jot-modal', function () {
|
||||
$("body").on("hidden.bs.modal", "#jot-modal", function () {
|
||||
// Restore cached jot at its hidden position ("#jot-content").
|
||||
$("#jot-content").append(jotcache);
|
||||
// Clear the jotcache.
|
||||
jotcache = '';
|
||||
jotcache = "";
|
||||
// Destroy the attachment linkPreviw for Jot.
|
||||
if (typeof linkPreview === 'object') {
|
||||
if (typeof linkPreview === "object") {
|
||||
linkPreview.destroy();
|
||||
}
|
||||
});
|
||||
|
@ -40,7 +40,6 @@ $(document).ready(function(){
|
|||
// .../photo/ab803d8eg08daf85023adfec08 (with nothing more following), in hopes
|
||||
// that that will be unique enough.
|
||||
if (imgHref.match(/\/photo\/[a-fA-F0-9]+(-[0-9]\.[\w]+?)?$/)) {
|
||||
|
||||
// Add a unique class to all the images of a certain post, to allow scrolling through
|
||||
var cBoxClass = $(this).closest(".wall-item-body").attr("id") + "-lightbox";
|
||||
$(this).addClass(cBoxClass);
|
||||
|
@ -50,9 +49,9 @@ $(document).ready(function(){
|
|||
// }
|
||||
|
||||
aElem.colorbox({
|
||||
maxHeight: '90%',
|
||||
maxHeight: "90%",
|
||||
photo: true, // Colorbox doesn't recognize a URL that don't end in .jpg, etc. as a photo.
|
||||
rel: cBoxClass //$(this).attr("class").match(/wall-item-body-[\d]+-lightbox/)[0].
|
||||
rel: cBoxClass, //$(this).attr("class").match(/wall-item-body-[\d]+-lightbox/)[0].
|
||||
});
|
||||
}
|
||||
});
|
||||
|
@ -92,15 +91,14 @@ $(document).ready(function(){
|
|||
elm.removeAttr("image-input");
|
||||
// Insert the link from the image into the input field.
|
||||
input.val(img);
|
||||
|
||||
});
|
||||
|
||||
// Generic delegated event to open an anchor URL in a modal.
|
||||
// Used in the hovercard.
|
||||
document.getElementsByTagName('body')[0].addEventListener('click', function(e) {
|
||||
document.getElementsByTagName("body")[0].addEventListener("click", function (e) {
|
||||
var target = e.target;
|
||||
while (target) {
|
||||
if (target.matches && target.matches('a.add-to-modal')) {
|
||||
if (target.matches && target.matches("a.add-to-modal")) {
|
||||
addToModal(target.href);
|
||||
e.preventDefault();
|
||||
return false;
|
||||
|
@ -113,21 +111,19 @@ $(document).ready(function(){
|
|||
|
||||
// Overwrite Dialog.show from main js to load the filebrowser into a bs modal.
|
||||
Dialog.show = function (url, title) {
|
||||
if (typeof(title) === 'undefined') {
|
||||
if (typeof title === "undefined") {
|
||||
title = "";
|
||||
}
|
||||
|
||||
var modal = $('#modal').modal();
|
||||
var modal = $("#modal").modal();
|
||||
modal.find("#modal-header h4").html(title);
|
||||
modal
|
||||
.find('#modal-body')
|
||||
.load(url, function (responseText, textStatus) {
|
||||
if ( textStatus === 'success' ||
|
||||
textStatus === 'notmodified')
|
||||
{
|
||||
modal.find("#modal-body").load(url, function (responseText, textStatus) {
|
||||
if (textStatus === "success" || textStatus === "notmodified") {
|
||||
modal.show();
|
||||
|
||||
$(function() {Dialog._load(url);});
|
||||
$(function () {
|
||||
Dialog._load(url);
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
|
@ -145,13 +141,13 @@ Dialog.showJot = function() {
|
|||
var name = "main";
|
||||
|
||||
var url = Dialog._get_url(type, name);
|
||||
if(($(".modal-body #jot-fbrowser-wrapper .fbrowser").length) < 1 ) {
|
||||
if ($(".modal-body #jot-fbrowser-wrapper .fbrowser").length < 1) {
|
||||
// Load new content to fbrowser window.
|
||||
$("#jot-fbrowser-wrapper").load(url, function (responseText, textStatus) {
|
||||
if ( textStatus === 'success' ||
|
||||
textStatus === 'notmodified')
|
||||
{
|
||||
$(function() {Dialog._load(url);});
|
||||
if (textStatus === "success" || textStatus === "notmodified") {
|
||||
$(function () {
|
||||
Dialog._load(url);
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -160,7 +156,7 @@ Dialog.showJot = function() {
|
|||
// Init the filebrowser after page load.
|
||||
Dialog._load = function (url) {
|
||||
// Get nickname & filebrowser type from the modal content.
|
||||
let filebrowser = document.getElementById('filebrowser');
|
||||
let filebrowser = document.getElementById("filebrowser");
|
||||
|
||||
// Try to fetch the hash form the url.
|
||||
let match = url.match(/fbrowser\/[a-z]+\/.*(#.*)/);
|
||||
|
@ -207,7 +203,6 @@ function loadModalTitle() {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This function loads html content from a friendica page into a modal.
|
||||
*
|
||||
|
@ -218,20 +213,16 @@ function loadModalTitle() {
|
|||
function addToModal(url, id) {
|
||||
var char = qOrAmp(url);
|
||||
|
||||
url = url + char + 'mode=none';
|
||||
var modal = $('#modal').modal();
|
||||
url = url + char + "mode=none";
|
||||
var modal = $("#modal").modal();
|
||||
|
||||
// Only search for an element if we have an ID.
|
||||
if (typeof id !== "undefined") {
|
||||
url = url + " div#" + id;
|
||||
}
|
||||
|
||||
modal
|
||||
.find('#modal-body')
|
||||
.load(url, function (responseText, textStatus) {
|
||||
if ( textStatus === 'success' ||
|
||||
textStatus === 'notmodified')
|
||||
{
|
||||
modal.find("#modal-body").load(url, function (responseText, textStatus) {
|
||||
if (textStatus === "success" || textStatus === "notmodified") {
|
||||
modal.show();
|
||||
|
||||
//Get first element with the class "heading"
|
||||
|
@ -240,7 +231,7 @@ function addToModal(url, id) {
|
|||
|
||||
// We need to initialize autosize again for new
|
||||
// modal conent.
|
||||
autosize($('.modal .text-autosize'));
|
||||
autosize($(".modal .text-autosize"));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -248,12 +239,9 @@ function addToModal(url, id) {
|
|||
// Add an element (by its id) to a bootstrap modal.
|
||||
function addElmToModal(id) {
|
||||
var elm = $(id).html();
|
||||
var modal = $('#modal').modal();
|
||||
var modal = $("#modal").modal();
|
||||
|
||||
modal
|
||||
.find('#modal-body')
|
||||
.append(elm)
|
||||
.modal.show;
|
||||
modal.find("#modal-body").append(elm).modal.show;
|
||||
|
||||
loadModalTitle();
|
||||
}
|
||||
|
@ -269,12 +257,12 @@ function editpost(url) {
|
|||
// Test if in the url path containing "events/event". If the path containing this
|
||||
// expression then we will call the addToModal function and exit this function at
|
||||
// this point.
|
||||
if (splitURL.path.indexOf('events/event') > -1) {
|
||||
if (splitURL.path.indexOf("events/event") > -1) {
|
||||
addToModal(splitURL.path);
|
||||
return;
|
||||
}
|
||||
|
||||
var modal = $('#jot-modal').modal();
|
||||
var modal = $("#jot-modal").modal();
|
||||
url = url + " #jot-sections";
|
||||
|
||||
$(".jot-nav .jot-perms-lnk").parent("li").addClass("hidden");
|
||||
|
@ -293,16 +281,11 @@ function editpost(url) {
|
|||
|
||||
jotreset();
|
||||
|
||||
modal
|
||||
.find('#jot-modal-content')
|
||||
.load(url, function (responseText, textStatus) {
|
||||
if ( textStatus === 'success' ||
|
||||
textStatus === 'notmodified')
|
||||
{
|
||||
modal.find("#jot-modal-content").load(url, function (responseText, textStatus) {
|
||||
if (textStatus === "success" || textStatus === "notmodified") {
|
||||
// get the item type and hide the input for title and category if it isn't needed.
|
||||
var type = $(responseText).find("#profile-jot-form input[name='type']").val();
|
||||
if(type === "wall-comment" || type === "remote-comment")
|
||||
{
|
||||
if (type === "wall-comment" || type === "remote-comment") {
|
||||
// Hide title and category input fields because we don't.
|
||||
$("#profile-jot-form #jot-title-wrap").hide();
|
||||
$("#profile-jot-form #jot-category-wrap").hide();
|
||||
|
@ -310,7 +293,7 @@ function editpost(url) {
|
|||
|
||||
modal.show();
|
||||
$("#jot-popup").show();
|
||||
linkPreview = $('#profile-jot-text').linkPreview();
|
||||
linkPreview = $("#profile-jot-text").linkPreview();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -319,8 +302,8 @@ function editpost(url) {
|
|||
function jotreset() {
|
||||
// Clear bs modal on close.
|
||||
// We need this to prevent that the modal displays old content.
|
||||
$('body').on('hidden.bs.modal', '#jot-modal.edit-jot', function () {
|
||||
$(this).removeData('bs.modal');
|
||||
$("body").on("hidden.bs.modal", "#jot-modal.edit-jot", function () {
|
||||
$(this).removeData("bs.modal");
|
||||
$(".jot-nav .jot-perms-lnk").parent("li").removeClass("hidden");
|
||||
$("#profile-jot-form #jot-title-wrap").show();
|
||||
$("#profile-jot-form #jot-category-wrap").show();
|
||||
|
@ -344,8 +327,10 @@ function toggleJotNav (elm) {
|
|||
|
||||
// Minimize all tab content wrapper and activate only the selected
|
||||
// tab panel.
|
||||
$('#profile-jot-form > [role=tabpanel]').addClass("minimize").attr("aria-hidden" ,"true");
|
||||
$('#' + tabpanel).removeClass("minimize").attr("aria-hidden" ,"false");
|
||||
$("#profile-jot-form > [role=tabpanel]").addClass("minimize").attr("aria-hidden", "true");
|
||||
$("#" + tabpanel)
|
||||
.removeClass("minimize")
|
||||
.attr("aria-hidden", "false");
|
||||
|
||||
// Set the aria-selected states
|
||||
$("#jot-modal .modal-header .nav-tabs .jot-nav-lnk").attr("aria-selected", "false");
|
||||
|
@ -355,7 +340,7 @@ function toggleJotNav (elm) {
|
|||
if (tabpanel === "jot-preview-content") {
|
||||
preview_post();
|
||||
// Make Share button visivle in preview
|
||||
$('#jot-preview-share').removeClass("minimize").attr("aria-hidden" ,"false");
|
||||
$("#jot-preview-share").removeClass("minimize").attr("aria-hidden", "false");
|
||||
} else if (tabpanel === "jot-fbrowser-wrapper") {
|
||||
$(function () {
|
||||
Dialog.showJot();
|
||||
|
@ -377,7 +362,7 @@ function openWallMessage(url) {
|
|||
|
||||
// If the host isn't the same we can't load it in a modal.
|
||||
// So we will go to to the url directly.
|
||||
if( ("host" in parts) && (parts.host !== window.location.host)) {
|
||||
if ("host" in parts && parts.host !== window.location.host) {
|
||||
window.location.href = url;
|
||||
} else {
|
||||
// Otherwise load the wall message into a modal.
|
||||
|
@ -389,7 +374,7 @@ function openWallMessage(url) {
|
|||
/// @todo Rename this function because it can be used for more than events.
|
||||
function eventEdit(url) {
|
||||
var char = qOrAmp(url);
|
||||
url = url + char + 'mode=none';
|
||||
url = url + char + "mode=none";
|
||||
|
||||
$.get(url, function (data) {
|
||||
$("#modal-body").empty();
|
||||
|
|
|
@ -40,7 +40,7 @@ function commentGetLink(id, prompttext) {
|
|||
reply = prompt(prompttext);
|
||||
if (reply && reply.length) {
|
||||
reply = bin2hex(reply);
|
||||
$.get('parse_url?noAttachment=1&binurl=' + reply, function(data) {
|
||||
$.get("parse_url?noAttachment=1&binurl=" + reply, function (data) {
|
||||
addCommentText(data, id);
|
||||
});
|
||||
}
|
||||
|
@ -64,7 +64,7 @@ function commentLinkDrop(event, id) {
|
|||
event.preventDefault();
|
||||
if (reply && reply.length) {
|
||||
reply = bin2hex(reply);
|
||||
$.get('parse_url?noAttachment=1&binurl=' + reply, function(data) {
|
||||
$.get("parse_url?noAttachment=1&binurl=" + reply, function (data) {
|
||||
addCommentText(data, id);
|
||||
});
|
||||
}
|
||||
|
@ -86,12 +86,12 @@ function insertFormattingToPost(BBCode) {
|
|||
}
|
||||
|
||||
function showThread(id) {
|
||||
$("#collapsed-comments-" + id).show()
|
||||
$("#collapsed-comments-" + id + " .collapsed-comments").show()
|
||||
$("#collapsed-comments-" + id).show();
|
||||
$("#collapsed-comments-" + id + " .collapsed-comments").show();
|
||||
}
|
||||
function hideThread(id) {
|
||||
$("#collapsed-comments-" + id).hide()
|
||||
$("#collapsed-comments-" + id + " .collapsed-comments").hide()
|
||||
$("#collapsed-comments-" + id).hide();
|
||||
$("#collapsed-comments-" + id + " .collapsed-comments").hide();
|
||||
}
|
||||
|
||||
function cmtBbOpen(id) {
|
||||
|
@ -101,8 +101,7 @@ function cmtBbClose(id) {
|
|||
$("#comment-edit-bb-" + id).hide();
|
||||
}
|
||||
|
||||
function commentExpand(id)
|
||||
{
|
||||
function commentExpand(id) {
|
||||
$("#mod-cmnt-wrap-" + id).show();
|
||||
closeMenu("comment-fake-form-" + id);
|
||||
openMenu("item-comments-" + id);
|
||||
|
@ -114,9 +113,8 @@ function commentExpand(id)
|
|||
return true;
|
||||
}
|
||||
|
||||
function commentClose(obj, id)
|
||||
{
|
||||
if (obj.value === '' || obj.value === obj.dataset.default) {
|
||||
function commentClose(obj, id) {
|
||||
if (obj.value === "" || obj.value === obj.dataset.default) {
|
||||
$("#comment-edit-text-" + id)
|
||||
.removeClass("comment-edit-text-full")
|
||||
.addClass("comment-edit-text-empty");
|
||||
|
@ -129,8 +127,8 @@ function commentClose(obj, id)
|
|||
}
|
||||
|
||||
function showHideCommentBox(id) {
|
||||
var $el = $('#comment-edit-form-' + id);
|
||||
if ($el.is(':visible')) {
|
||||
var $el = $("#comment-edit-form-" + id);
|
||||
if ($el.is(":visible")) {
|
||||
$el.hide();
|
||||
} else {
|
||||
$el.show();
|
||||
|
@ -142,19 +140,21 @@ function commentOpenUI(obj, id) {
|
|||
openMenu("item-comments-" + id);
|
||||
$("#comment-edit-text-" + id)
|
||||
.putCursorAtEnd()
|
||||
.addClass("comment-edit-text-full").removeClass("comment-edit-text-empty")
|
||||
.attr('tabindex', '9'); // Choose an arbitrary tab index that's greater than what we're using in jot (3 of them)
|
||||
$("#comment-edit-submit-" + id).attr('tabindex', '10'); // The submit button gets tabindex + 1
|
||||
.addClass("comment-edit-text-full")
|
||||
.removeClass("comment-edit-text-empty")
|
||||
.attr("tabindex", "9"); // Choose an arbitrary tab index that's greater than what we're using in jot (3 of them)
|
||||
$("#comment-edit-submit-" + id).attr("tabindex", "10"); // The submit button gets tabindex + 1
|
||||
// initialize autosize for this comment
|
||||
autosize($("#comment-edit-text-" + id + ".text-autosize"));
|
||||
}
|
||||
|
||||
function commentCloseUI(obj, id) {
|
||||
if (obj.value === '' || obj.value === obj.dataset.default) {
|
||||
if (obj.value === "" || obj.value === obj.dataset.default) {
|
||||
$("#comment-edit-text-" + id)
|
||||
.removeClass("comment-edit-text-full").addClass("comment-edit-text-empty")
|
||||
.removeAttr('tabindex');
|
||||
$("#comment-edit-submit-" + id).removeAttr('tabindex');
|
||||
.removeClass("comment-edit-text-full")
|
||||
.addClass("comment-edit-text-empty")
|
||||
.removeAttr("tabindex");
|
||||
$("#comment-edit-submit-" + id).removeAttr("tabindex");
|
||||
openMenu("comment-fake-form-" + id);
|
||||
closeMenu("item-comments-" + id);
|
||||
// destroy the automatic textarea resizing
|
||||
|
@ -163,7 +163,7 @@ function commentCloseUI(obj, id) {
|
|||
}
|
||||
|
||||
function jotTextOpenUI(obj) {
|
||||
if (obj.value === '' || obj.value === obj.dataset.default) {
|
||||
if (obj.value === "" || obj.value === obj.dataset.default) {
|
||||
var $el = $(".modal-body #profile-jot-text");
|
||||
$el.addClass("profile-jot-text-full").removeClass("profile-jot-text-empty");
|
||||
// initiale autosize for the jot
|
||||
|
@ -172,7 +172,7 @@ function jotTextOpenUI(obj) {
|
|||
}
|
||||
|
||||
function jotTextCloseUI(obj) {
|
||||
if (obj.value === '' || obj.value === obj.dataset.default) {
|
||||
if (obj.value === "" || obj.value === obj.dataset.default) {
|
||||
var $el = $(".modal-body #profile-jot-text");
|
||||
$el.removeClass("profile-jot-text-full").addClass("profile-jot-text-empty");
|
||||
// destroy the automatic textarea resizing
|
||||
|
@ -181,7 +181,7 @@ function jotTextCloseUI(obj) {
|
|||
}
|
||||
|
||||
function commentOpen(obj, id) {
|
||||
if (obj.value === '' || obj.value === obj.dataset.default) {
|
||||
if (obj.value === "" || obj.value === obj.dataset.default) {
|
||||
$("#comment-edit-text-" + id)
|
||||
.putCursorAtEnd()
|
||||
.addClass("comment-edit-text-full")
|
||||
|
@ -210,18 +210,21 @@ function dropItem(url, elementId) {
|
|||
var confirm = confirmDelete();
|
||||
|
||||
if (confirm) {
|
||||
$('body').css('cursor', 'wait');
|
||||
$("body").css("cursor", "wait");
|
||||
|
||||
var $el = $(document.getElementById(elementId));
|
||||
|
||||
$el.fadeTo('fast', 0.33, function () {
|
||||
$.get(url).then(function() {
|
||||
$el.fadeTo("fast", 0.33, function () {
|
||||
$.get(url)
|
||||
.then(function () {
|
||||
$el.remove();
|
||||
}).fail(function() {
|
||||
})
|
||||
.fail(function () {
|
||||
// @todo Show related error message
|
||||
$el.show();
|
||||
}).always(function() {
|
||||
$('body').css('cursor', 'auto');
|
||||
})
|
||||
.always(function () {
|
||||
$("body").css("cursor", "auto");
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPLv3-or-later
|
||||
|
||||
var jotcache = ''; //The jot cache. We use it as cache to restore old/original jot content
|
||||
var jotcache = ""; //The jot cache. We use it as cache to restore old/original jot content
|
||||
|
||||
$(document).ready(function () {
|
||||
// Destroy unused perfect scrollbar in aside element
|
||||
$('aside').perfectScrollbar('destroy');
|
||||
$("aside").perfectScrollbar("destroy");
|
||||
|
||||
//fade in/out based on scrollTop value
|
||||
var scrollStart;
|
||||
|
@ -27,9 +27,12 @@ $(document).ready(function(){
|
|||
|
||||
// scroll body to 0px on click
|
||||
$("#back-to-top").click(function () {
|
||||
$("body,html").animate({
|
||||
scrollTop: 0
|
||||
}, 400);
|
||||
$("body,html").animate(
|
||||
{
|
||||
scrollTop: 0,
|
||||
},
|
||||
400,
|
||||
);
|
||||
return false;
|
||||
});
|
||||
|
||||
|
@ -64,17 +67,17 @@ $(document).ready(function(){
|
|||
// So we apply the correct url (with the link to the id of the mask) after the page is loaded.
|
||||
if ($("#logo-img").length) {
|
||||
var pageurl = "url('" + window.location.href + "#logo-mask')";
|
||||
$("#logo-img").css({"mask": pageurl});
|
||||
$("#logo-img").css({ mask: pageurl });
|
||||
}
|
||||
|
||||
// make responsive tabmenu with flexmenu.js
|
||||
// the menupoints which doesn't fit in the second nav bar will moved to a
|
||||
// dropdown menu. Look at common_tabs.tpl
|
||||
$("ul.tabs.flex-nav").flexMenu({
|
||||
'cutoff': 2,
|
||||
'popupClass': "dropdown-menu pull-right",
|
||||
'popupAbsolute': false,
|
||||
'target': ".flex-target"
|
||||
cutoff: 2,
|
||||
popupClass: "dropdown-menu pull-right",
|
||||
popupAbsolute: false,
|
||||
target: ".flex-target",
|
||||
});
|
||||
|
||||
// add Jot button to the second navbar
|
||||
|
@ -84,13 +87,13 @@ $(document).ready(function(){
|
|||
if ($("#jot-popup").is(":hidden")) {
|
||||
$jotButton.hide();
|
||||
}
|
||||
$jotButton.on('click', function (e) {
|
||||
$jotButton.on("click", function (e) {
|
||||
e.preventDefault();
|
||||
jotShow();
|
||||
});
|
||||
}
|
||||
|
||||
let $body = $('body');
|
||||
let $body = $("body");
|
||||
|
||||
// show bulk deletion button at network page if checkbox is checked
|
||||
$body.change("input.item-select", function () {
|
||||
|
@ -99,8 +102,8 @@ $(document).ready(function(){
|
|||
// We need to get all checked items, so it would close the delete button
|
||||
// if we uncheck one item and others are still checked.
|
||||
// So return checked = true if there is any checked item
|
||||
$('input.item-select').each( function() {
|
||||
if($(this).is(':checked')) {
|
||||
$("input.item-select").each(function () {
|
||||
if ($(this).is(":checked")) {
|
||||
checked = true;
|
||||
return false;
|
||||
}
|
||||
|
@ -119,22 +122,22 @@ $(document).ready(function(){
|
|||
// initialize the bootstrap tooltips
|
||||
$body.tooltip({
|
||||
selector: '[data-toggle="tooltip"]',
|
||||
container: 'body',
|
||||
container: "body",
|
||||
animation: true,
|
||||
html: true,
|
||||
placement: 'auto',
|
||||
trigger: 'hover',
|
||||
placement: "auto",
|
||||
trigger: "hover",
|
||||
delay: {
|
||||
show: 500,
|
||||
hide: 100
|
||||
hide: 100,
|
||||
},
|
||||
sanitizeFn: function (content) {
|
||||
return DOMPurify.sanitize(content)
|
||||
return DOMPurify.sanitize(content);
|
||||
},
|
||||
});
|
||||
|
||||
// initialize the bootstrap-select
|
||||
$('.selectpicker').selectpicker();
|
||||
$(".selectpicker").selectpicker();
|
||||
|
||||
// add search-heading to the second navbar
|
||||
if ($(".search-heading").length) {
|
||||
|
@ -155,7 +158,7 @@ $(document).ready(function(){
|
|||
searchText = "No results";
|
||||
}
|
||||
// insert the plain text in a <h4> heading and give it a class
|
||||
var newText = '<h4 class="search-heading">'+searchText+'</h4>';
|
||||
var newText = '<h4 class="search-heading">' + searchText + "</h4>";
|
||||
// append the new heading to the navbar
|
||||
$("#topbar-second > .container > #tabmenu").append(newText);
|
||||
|
||||
|
@ -166,11 +169,11 @@ $(document).ready(function(){
|
|||
// if the orignal search value isn't available use the location path as value
|
||||
if (typeof searchValue === "undefined") {
|
||||
// get the location path
|
||||
var urlPath = window.location.search
|
||||
var urlPath = window.location.search;
|
||||
// and split it up in its parts
|
||||
var splitPath = urlPath.split(/(\?search?=)(.*$)/);
|
||||
|
||||
if(typeof splitPath[2] !== 'undefined') {
|
||||
if (typeof splitPath[2] !== "undefined") {
|
||||
// decode the path (e.g to decode %40 to the character @)
|
||||
var searchValue = decodeURIComponent(splitPath[2]);
|
||||
}
|
||||
|
@ -207,7 +210,9 @@ $(document).ready(function(){
|
|||
// Note: We need the first() element with this class since at the present time we
|
||||
// store also the js template information in the html code and thats why
|
||||
// there are two elements with this class but we don't want the js template
|
||||
$(".network-content-wrapper > #viewcontact_wrapper-network .contact-wrapper").first().appendTo("#nav-short-info");
|
||||
$(".network-content-wrapper > #viewcontact_wrapper-network .contact-wrapper")
|
||||
.first()
|
||||
.appendTo("#nav-short-info");
|
||||
}
|
||||
|
||||
// move heading from network stream to the second navbar nav-short-info section
|
||||
|
@ -217,7 +222,8 @@ $(document).ready(function(){
|
|||
// get the text of the heading
|
||||
var headingContent = heading.html();
|
||||
// create a new element with the content of the heading
|
||||
var newText = '<h4 class="heading" data-toggle="tooltip" title="'+headingContent+'">'+headingContent+'</h4>';
|
||||
var newText =
|
||||
'<h4 class="heading" data-toggle="tooltip" title="' + headingContent + '">' + headingContent + "</h4>";
|
||||
// remove the old heading element
|
||||
heading.remove(),
|
||||
// put the new element to the second nav bar
|
||||
|
@ -230,7 +236,7 @@ $(document).ready(function(){
|
|||
// get the text of the heading
|
||||
var headingContent = heading.html();
|
||||
// create a new element with the content of the heading
|
||||
var newText = '<h4 class="heading">'+headingContent+'</h4>';
|
||||
var newText = '<h4 class="heading">' + headingContent + "</h4>";
|
||||
// remove the old heading element
|
||||
heading.remove(),
|
||||
// put the new element to the second nav bar
|
||||
|
@ -239,7 +245,7 @@ $(document).ready(function(){
|
|||
|
||||
// Dropdown menus with the class "dropdown-head" will display the active tab
|
||||
// as button text
|
||||
$body.on('click', '.dropdown-head .dropdown-menu li a, .dropdown-head .dropdown-menu li button', function(){
|
||||
$body.on("click", ".dropdown-head .dropdown-menu li a, .dropdown-head .dropdown-menu li button", function () {
|
||||
toggleDropdownText(this);
|
||||
});
|
||||
|
||||
|
@ -257,9 +263,11 @@ $(document).ready(function(){
|
|||
|
||||
// According to the value of the input element we need to decide
|
||||
// which class need to be added and removed when changing the switch
|
||||
var removedclass = (val == 0 ? onstyle : offstyle);
|
||||
var addedclass = (val == 0 ? offstyle : onstyle)
|
||||
$("#"+id+"_onoff").addClass(addedclass).removeClass(removedclass);
|
||||
var removedclass = val == 0 ? onstyle : offstyle;
|
||||
var addedclass = val == 0 ? offstyle : onstyle;
|
||||
$("#" + id + "_onoff")
|
||||
.addClass(addedclass)
|
||||
.removeClass(removedclass);
|
||||
|
||||
// After changing the switch the input element is getting
|
||||
// the newvalue
|
||||
|
@ -273,19 +281,18 @@ $(document).ready(function(){
|
|||
// to the input element where the padding value would be at least the width
|
||||
// of the button. Otherwise long user input would be invisible because it is
|
||||
// behind the button.
|
||||
$body.on('click', '.form-group-search > input', function() {
|
||||
$body.on("click", ".form-group-search > input", function () {
|
||||
// Get the width of the button (if the button isn't available
|
||||
// buttonWidth will be null
|
||||
var buttonWidth = $(this).next('.form-button-search').outerWidth();
|
||||
var buttonWidth = $(this).next(".form-button-search").outerWidth();
|
||||
|
||||
if (buttonWidth) {
|
||||
// Take the width of the button and ad 5px
|
||||
var newWidth = buttonWidth + 5;
|
||||
// Set the padding of the input element according
|
||||
// to the width of the button
|
||||
$(this).css('padding-right', newWidth);
|
||||
$(this).css("padding-right", newWidth);
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
/*
|
||||
|
@ -295,18 +302,18 @@ $(document).ready(function(){
|
|||
* We are making an exception for buttons because of a race condition with the
|
||||
* comment opening button that results in an already closed comment UI.
|
||||
*/
|
||||
$(document).on('mousedown', function(event) {
|
||||
if (event.target.type === 'button') {
|
||||
$(document).on("mousedown", function (event) {
|
||||
if (event.target.type === "button") {
|
||||
return true;
|
||||
}
|
||||
|
||||
var $dontclosethis = $(event.target).closest('.wall-item-comment-wrapper').find('.comment-edit-form');
|
||||
$('.wall-item-comment-wrapper .comment-edit-submit-wrapper:visible').each(function() {
|
||||
var $parent = $(this).parent('.comment-edit-form');
|
||||
var itemId = $parent.data('itemId');
|
||||
var $dontclosethis = $(event.target).closest(".wall-item-comment-wrapper").find(".comment-edit-form");
|
||||
$(".wall-item-comment-wrapper .comment-edit-submit-wrapper:visible").each(function () {
|
||||
var $parent = $(this).parent(".comment-edit-form");
|
||||
var itemId = $parent.data("itemId");
|
||||
|
||||
if ($dontclosethis[0] != $parent[0]) {
|
||||
var textarea = $parent.find('textarea').get(0)
|
||||
var textarea = $parent.find("textarea").get(0);
|
||||
|
||||
commentCloseUI(textarea, itemId);
|
||||
}
|
||||
|
@ -314,10 +321,10 @@ $(document).ready(function(){
|
|||
});
|
||||
|
||||
// Customize some elements when the app is used in standalone mode on Android
|
||||
if (window.matchMedia('(display-mode: standalone)').matches) {
|
||||
if (window.matchMedia("(display-mode: standalone)").matches) {
|
||||
// Open links to source outside of the webview
|
||||
$('body').on('click', '.plink', function (e) {
|
||||
$(e.target).attr('target', '_blank');
|
||||
$("body").on("click", ".plink", function (e) {
|
||||
$(e.target).attr("target", "_blank");
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -325,7 +332,7 @@ $(document).ready(function(){
|
|||
* This event listeners ensures that the textarea size is updated event if the
|
||||
* value is changed externally (textcomplete, insertFormatting, fbrowser...)
|
||||
*/
|
||||
$(document).on('change', 'textarea', function(event) {
|
||||
$(document).on("change", "textarea", function (event) {
|
||||
autosize.update(event.target);
|
||||
});
|
||||
|
||||
|
@ -343,7 +350,7 @@ $(document).ready(function(){
|
|||
if ($(window).width() > 976) {
|
||||
$("aside").stick_in_parent({
|
||||
offset_top: 100, // px, header + tab bar + spacing
|
||||
recalc_every: 10
|
||||
recalc_every: 10,
|
||||
});
|
||||
// recalculate sticky aside on clicks on <a> elements
|
||||
// this handle height changes on expanding submenus
|
||||
|
@ -372,9 +379,9 @@ $(document).ready(function(){
|
|||
});
|
||||
|
||||
// Comment form submit
|
||||
$body.on('submit', '.comment-edit-form', function(e) {
|
||||
$body.on("submit", ".comment-edit-form", function (e) {
|
||||
let $form = $(this);
|
||||
let id = $form.data('item-id');
|
||||
let id = $form.data("item-id");
|
||||
|
||||
// Compose page form exception: id is always 0 and form must not be submitted asynchronously
|
||||
if (id === 0) {
|
||||
|
@ -383,21 +390,17 @@ $(document).ready(function(){
|
|||
|
||||
e.preventDefault();
|
||||
|
||||
let $commentSubmit = $form.find('.comment-edit-submit').button('loading');
|
||||
let $commentSubmit = $form.find(".comment-edit-submit").button("loading");
|
||||
|
||||
unpause();
|
||||
commentBusy = true;
|
||||
|
||||
$.post(
|
||||
'item',
|
||||
$form.serialize(),
|
||||
'json'
|
||||
)
|
||||
$.post("item", $form.serialize(), "json")
|
||||
.then(function (data) {
|
||||
if (data.success) {
|
||||
$('#comment-edit-wrapper-' + id).hide();
|
||||
let $textarea = $('#comment-edit-text-' + id);
|
||||
$textarea.val('');
|
||||
$("#comment-edit-wrapper-" + id).hide();
|
||||
let $textarea = $("#comment-edit-text-" + id);
|
||||
$textarea.val("");
|
||||
if ($textarea.get(0)) {
|
||||
commentClose($textarea.get(0), id);
|
||||
}
|
||||
|
@ -413,56 +416,49 @@ $(document).ready(function(){
|
|||
}
|
||||
})
|
||||
.always(function () {
|
||||
$commentSubmit.button('reset');
|
||||
$commentSubmit.button("reset");
|
||||
});
|
||||
});
|
||||
|
||||
$body.on('submit', '.modal-body #poke-wrapper', function(e) {
|
||||
$body.on("submit", ".modal-body #poke-wrapper", function (e) {
|
||||
e.preventDefault();
|
||||
|
||||
let $form = $(this);
|
||||
let $pokeSubmit = $form.find('button[type=submit]').button('loading');
|
||||
let $pokeSubmit = $form.find("button[type=submit]").button("loading");
|
||||
|
||||
$.post(
|
||||
$form.attr('action'),
|
||||
$form.serialize(),
|
||||
'json'
|
||||
)
|
||||
$.post($form.attr("action"), $form.serialize(), "json")
|
||||
.then(function (data) {
|
||||
if (data.success) {
|
||||
$('#modal').modal('hide');
|
||||
$("#modal").modal("hide");
|
||||
}
|
||||
})
|
||||
.always(function () {
|
||||
$pokeSubmit.button('reset');
|
||||
$pokeSubmit.button("reset");
|
||||
});
|
||||
});
|
||||
})
|
||||
});
|
||||
|
||||
function openClose(theID) {
|
||||
var elem = document.getElementById(theID);
|
||||
|
||||
if( $(elem).is(':visible')) {
|
||||
if ($(elem).is(":visible")) {
|
||||
$(elem).slideUp(200);
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
$(elem).slideDown(200);
|
||||
}
|
||||
}
|
||||
|
||||
function showHide(theID) {
|
||||
var elem = document.getElementById(theID);
|
||||
var edit = document.getElementById("comment-edit-submit-wrapper-" + theID.match('[0-9$]+'));
|
||||
var edit = document.getElementById("comment-edit-submit-wrapper-" + theID.match("[0-9$]+"));
|
||||
|
||||
if ($(elem).is(':visible')) {
|
||||
if (!$(edit).is(':visible')) {
|
||||
if ($(elem).is(":visible")) {
|
||||
if (!$(edit).is(":visible")) {
|
||||
edit.style.display = "block";
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
elem.style.display = "none";
|
||||
}
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
elem.style.display = "block";
|
||||
}
|
||||
}
|
||||
|
@ -471,27 +467,27 @@ function showHide(theID) {
|
|||
function showHideEventMap(elm) {
|
||||
// Get the id of the map element - it should be provided through
|
||||
// the atribute "data-map-id".
|
||||
var mapID = elm.getAttribute('data-map-id');
|
||||
var mapID = elm.getAttribute("data-map-id");
|
||||
|
||||
// Get translation labels.
|
||||
var mapshow = elm.getAttribute('data-show-label');
|
||||
var maphide = elm.getAttribute('data-hide-label');
|
||||
var mapshow = elm.getAttribute("data-show-label");
|
||||
var maphide = elm.getAttribute("data-hide-label");
|
||||
|
||||
// Change the button labels.
|
||||
if (elm.innerText == mapshow) {
|
||||
$('#' + elm.id).text(maphide);
|
||||
$("#" + elm.id).text(maphide);
|
||||
} else {
|
||||
$('#' + elm.id).text(mapshow);
|
||||
$("#" + elm.id).text(mapshow);
|
||||
}
|
||||
// Because maps are iframe elements, we cant hide it through css (display: none).
|
||||
// We solve this issue by putting the map outside the screen with css.
|
||||
// So the first time the 'Show map' button is pressed we move the map
|
||||
// element into the screen area.
|
||||
var mappos = $('#' + mapID).css('position');
|
||||
var mappos = $("#" + mapID).css("position");
|
||||
|
||||
if (mappos === 'absolute') {
|
||||
$('#' + mapID).hide();
|
||||
$('#' + mapID).css({position: 'relative', left: 'auto', top: 'auto'});
|
||||
if (mappos === "absolute") {
|
||||
$("#" + mapID).hide();
|
||||
$("#" + mapID).css({ position: "relative", left: "auto", top: "auto" });
|
||||
openClose(mapID);
|
||||
} else {
|
||||
openClose(mapID);
|
||||
|
@ -501,18 +497,22 @@ function showHideEventMap(elm) {
|
|||
|
||||
function justifyPhotos() {
|
||||
justifiedGalleryActive = true;
|
||||
$('#photo-album-contents').justifiedGallery({
|
||||
$("#photo-album-contents")
|
||||
.justifiedGallery({
|
||||
margins: 3,
|
||||
border: 0,
|
||||
sizeRangeSuffixes: {
|
||||
'lt48': '-6',
|
||||
'lt80': '-5',
|
||||
'lt300': '-4',
|
||||
'lt320': '-2',
|
||||
'lt640': '-1',
|
||||
'lt1024': '-0'
|
||||
}
|
||||
}).on('jg.complete', function(e){ justifiedGalleryActive = false; });
|
||||
lt48: "-6",
|
||||
lt80: "-5",
|
||||
lt300: "-4",
|
||||
lt320: "-2",
|
||||
lt640: "-1",
|
||||
lt1024: "-0",
|
||||
},
|
||||
})
|
||||
.on("jg.complete", function (e) {
|
||||
justifiedGalleryActive = false;
|
||||
});
|
||||
}
|
||||
|
||||
// Load a js script to the html head.
|
||||
|
@ -525,9 +525,9 @@ function loadScript(url, callback) {
|
|||
oscript.remove();
|
||||
}
|
||||
// Adding the script tag to the head as suggested before.
|
||||
var head = document.getElementsByTagName('head')[0];
|
||||
var script = document.createElement('script');
|
||||
script.type = 'text/javascript';
|
||||
var head = document.getElementsByTagName("head")[0];
|
||||
var script = document.createElement("script");
|
||||
script.type = "text/javascript";
|
||||
script.src = url;
|
||||
|
||||
// Then bind the event to the callback function.
|
||||
|
@ -541,16 +541,16 @@ function loadScript(url, callback) {
|
|||
|
||||
// Does we need a ? or a & to append values to a url
|
||||
function qOrAmp(url) {
|
||||
if(url.search('\\?') < 0) {
|
||||
return '?';
|
||||
if (url.search("\\?") < 0) {
|
||||
return "?";
|
||||
} else {
|
||||
return '&';
|
||||
return "&";
|
||||
}
|
||||
}
|
||||
|
||||
String.prototype.normalizeLink = function () {
|
||||
var ret = this.replace('https:', 'http:');
|
||||
var ret = ret.replace('//www', '//');
|
||||
var ret = this.replace("https:", "http:");
|
||||
var ret = ret.replace("//www", "//");
|
||||
return ret.rtrim();
|
||||
};
|
||||
|
||||
|
@ -578,7 +578,8 @@ function cleanContactUrl(url) {
|
|||
return newUrl;
|
||||
}
|
||||
|
||||
function parseUrl (str, component) { // eslint-disable-line camelcase
|
||||
function parseUrl(str, component) {
|
||||
// eslint-disable-line camelcase
|
||||
// discuss at: http://locutusjs.io/php/parse_url/
|
||||
// original by: Steven Levithan (http://blog.stevenlevithan.com)
|
||||
// reimplemented by: Brett Zamir (http://brett-zamir.me)
|
||||
|
@ -603,82 +604,91 @@ function parseUrl (str, component) { // eslint-disable-line camelcase
|
|||
// example 4: parse_url('https://gooduser:secretpassword@www.example.com/a@b.c/folder?foo=bar')
|
||||
// returns 4: { scheme: 'https', host: 'www.example.com', path: '/a@b.c/folder', query: 'foo=bar', user: 'gooduser', pass: 'secretpassword' }
|
||||
|
||||
var query
|
||||
var query;
|
||||
|
||||
var mode = (typeof require !== 'undefined' ? require('../info/ini_get')('locutus.parse_url.mode') : undefined) || 'php'
|
||||
var mode =
|
||||
(typeof require !== "undefined" ? require("../info/ini_get")("locutus.parse_url.mode") : undefined) || "php";
|
||||
|
||||
var key = [
|
||||
'source',
|
||||
'scheme',
|
||||
'authority',
|
||||
'userInfo',
|
||||
'user',
|
||||
'pass',
|
||||
'host',
|
||||
'port',
|
||||
'relative',
|
||||
'path',
|
||||
'directory',
|
||||
'file',
|
||||
'query',
|
||||
'fragment'
|
||||
]
|
||||
"source",
|
||||
"scheme",
|
||||
"authority",
|
||||
"userInfo",
|
||||
"user",
|
||||
"pass",
|
||||
"host",
|
||||
"port",
|
||||
"relative",
|
||||
"path",
|
||||
"directory",
|
||||
"file",
|
||||
"query",
|
||||
"fragment",
|
||||
];
|
||||
|
||||
// For loose we added one optional slash to post-scheme to catch file:/// (should restrict this)
|
||||
var parser = {
|
||||
php: new RegExp([
|
||||
'(?:([^:\\/?#]+):)?',
|
||||
'(?:\\/\\/()(?:(?:()(?:([^:@\\/]*):?([^:@\\/]*))?@)?([^:\\/?#]*)(?::(\\d*))?))?',
|
||||
'()',
|
||||
'(?:(()(?:(?:[^?#\\/]*\\/)*)()(?:[^?#]*))(?:\\?([^#]*))?(?:#(.*))?)'
|
||||
].join('')),
|
||||
strict: new RegExp([
|
||||
'(?:([^:\\/?#]+):)?',
|
||||
'(?:\\/\\/((?:(([^:@\\/]*):?([^:@\\/]*))?@)?([^:\\/?#]*)(?::(\\d*))?))?',
|
||||
'((((?:[^?#\\/]*\\/)*)([^?#]*))(?:\\?([^#]*))?(?:#(.*))?)'
|
||||
].join('')),
|
||||
loose: new RegExp([
|
||||
'(?:(?![^:@]+:[^:@\\/]*@)([^:\\/?#.]+):)?',
|
||||
'(?:\\/\\/\\/?)?',
|
||||
'((?:(([^:@\\/]*):?([^:@\\/]*))?@)?([^:\\/?#]*)(?::(\\d*))?)',
|
||||
'(((\\/(?:[^?#](?![^?#\\/]*\\.[^?#\\/.]+(?:[?#]|$)))*\\/?)?([^?#\\/]*))',
|
||||
'(?:\\?([^#]*))?(?:#(.*))?)'
|
||||
].join(''))
|
||||
}
|
||||
php: new RegExp(
|
||||
[
|
||||
"(?:([^:\\/?#]+):)?",
|
||||
"(?:\\/\\/()(?:(?:()(?:([^:@\\/]*):?([^:@\\/]*))?@)?([^:\\/?#]*)(?::(\\d*))?))?",
|
||||
"()",
|
||||
"(?:(()(?:(?:[^?#\\/]*\\/)*)()(?:[^?#]*))(?:\\?([^#]*))?(?:#(.*))?)",
|
||||
].join(""),
|
||||
),
|
||||
strict: new RegExp(
|
||||
[
|
||||
"(?:([^:\\/?#]+):)?",
|
||||
"(?:\\/\\/((?:(([^:@\\/]*):?([^:@\\/]*))?@)?([^:\\/?#]*)(?::(\\d*))?))?",
|
||||
"((((?:[^?#\\/]*\\/)*)([^?#]*))(?:\\?([^#]*))?(?:#(.*))?)",
|
||||
].join(""),
|
||||
),
|
||||
loose: new RegExp(
|
||||
[
|
||||
"(?:(?![^:@]+:[^:@\\/]*@)([^:\\/?#.]+):)?",
|
||||
"(?:\\/\\/\\/?)?",
|
||||
"((?:(([^:@\\/]*):?([^:@\\/]*))?@)?([^:\\/?#]*)(?::(\\d*))?)",
|
||||
"(((\\/(?:[^?#](?![^?#\\/]*\\.[^?#\\/.]+(?:[?#]|$)))*\\/?)?([^?#\\/]*))",
|
||||
"(?:\\?([^#]*))?(?:#(.*))?)",
|
||||
].join(""),
|
||||
),
|
||||
};
|
||||
|
||||
var m = parser[mode].exec(str)
|
||||
var uri = {}
|
||||
var i = 14
|
||||
var m = parser[mode].exec(str);
|
||||
var uri = {};
|
||||
var i = 14;
|
||||
|
||||
while (i--) {
|
||||
if (m[i]) {
|
||||
uri[key[i]] = m[i]
|
||||
uri[key[i]] = m[i];
|
||||
}
|
||||
}
|
||||
|
||||
if (component) {
|
||||
return uri[component.replace('PHP_URL_', '').toLowerCase()]
|
||||
return uri[component.replace("PHP_URL_", "").toLowerCase()];
|
||||
}
|
||||
|
||||
if (mode !== 'php') {
|
||||
var name = (typeof require !== 'undefined' ? require('../info/ini_get')('locutus.parse_url.queryKey') : undefined) || 'queryKey'
|
||||
parser = /(?:^|&)([^&=]*)=?([^&]*)/g
|
||||
uri[name] = {}
|
||||
query = uri[key[12]] || ''
|
||||
if (mode !== "php") {
|
||||
var name =
|
||||
(typeof require !== "undefined" ? require("../info/ini_get")("locutus.parse_url.queryKey") : undefined) ||
|
||||
"queryKey";
|
||||
parser = /(?:^|&)([^&=]*)=?([^&]*)/g;
|
||||
uri[name] = {};
|
||||
query = uri[key[12]] || "";
|
||||
query.replace(parser, function ($0, $1, $2) {
|
||||
if ($1) {
|
||||
uri[name][$1] = $2
|
||||
uri[name][$1] = $2;
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
delete uri.source
|
||||
return uri
|
||||
delete uri.source;
|
||||
return uri;
|
||||
}
|
||||
|
||||
// trim function to replace whithespace after the string
|
||||
String.prototype.rtrim = function () {
|
||||
var trimmed = this.replace(/\s+$/g, '');
|
||||
var trimmed = this.replace(/\s+$/g, "");
|
||||
return trimmed;
|
||||
};
|
||||
|
||||
|
@ -695,34 +705,40 @@ function scrollToItem(elementId) {
|
|||
return;
|
||||
}
|
||||
|
||||
var $el = $('#' + elementId + ' > .media');
|
||||
var $el = $("#" + elementId + " > .media");
|
||||
// Test if the Item exists
|
||||
if (!$el.length) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Define the colors which are used for highlighting
|
||||
var colWhite = {backgroundColor:'#F5F5F5'};
|
||||
var colShiny = {backgroundColor:'#FFF176'};
|
||||
var colWhite = { backgroundColor: "#F5F5F5" };
|
||||
var colShiny = { backgroundColor: "#FFF176" };
|
||||
|
||||
// Get the Item Position (we need to substract 100 to match correct position
|
||||
var itemPos = $el.offset().top - 100;
|
||||
|
||||
// Scroll to the DIV with the ID (GUID)
|
||||
$('html, body').animate({
|
||||
scrollTop: itemPos
|
||||
}, 400).promise().done( function() {
|
||||
$("html, body")
|
||||
.animate(
|
||||
{
|
||||
scrollTop: itemPos,
|
||||
},
|
||||
400,
|
||||
)
|
||||
.promise()
|
||||
.done(function () {
|
||||
// Highlight post/commenent with ID (GUID)
|
||||
$el.animate(colWhite, 1000).animate(colShiny).animate({backgroundColor: 'transparent'}, 600);
|
||||
$el.animate(colWhite, 1000).animate(colShiny).animate({ backgroundColor: "transparent" }, 600);
|
||||
});
|
||||
}
|
||||
|
||||
// format a html string to pure text
|
||||
function htmlToText(htmlString) {
|
||||
// Replace line breaks with spaces
|
||||
var text = htmlString.replace(/<br>/g, ' ');
|
||||
var text = htmlString.replace(/<br>/g, " ");
|
||||
// Strip the text out of the html string
|
||||
text = text.replace(/<[^>]*>/g, '');
|
||||
text = text.replace(/<[^>]*>/g, "");
|
||||
|
||||
return text;
|
||||
}
|
||||
|
@ -736,10 +752,10 @@ function htmlToText(htmlString) {
|
|||
* @param {boolean} un Whether to perform an activity removal instead of creation
|
||||
*/
|
||||
function doLikeAction(ident, verb, un) {
|
||||
if (verb.indexOf('attend') === 0) {
|
||||
$('.item-' + ident + ' .button-event:not(#' + verb + '-' + ident + ')').removeClass('active');
|
||||
if (verb.indexOf("attend") === 0) {
|
||||
$(".item-" + ident + " .button-event:not(#" + verb + "-" + ident + ")").removeClass("active");
|
||||
}
|
||||
$('#' + verb + '-' + ident).toggleClass('active');
|
||||
$("#" + verb + "-" + ident).toggleClass("active");
|
||||
|
||||
dolike(ident, verb, un);
|
||||
}
|
||||
|
@ -757,7 +773,7 @@ function hex2bin (s) {
|
|||
var ret = [];
|
||||
var i = 0;
|
||||
var l;
|
||||
s += '';
|
||||
s += "";
|
||||
|
||||
for (l = s.length; i < l; i += 2) {
|
||||
var c = parseInt(s.substr(i, 1), 16);
|
||||
|
@ -782,7 +798,10 @@ function bin2hex (s) {
|
|||
// * example 2: bin2hex(String.fromCharCode(0x00));
|
||||
// * returns 2: '00'
|
||||
|
||||
var i, l, o = "", n;
|
||||
var i,
|
||||
l,
|
||||
o = "",
|
||||
n;
|
||||
|
||||
s += "";
|
||||
|
||||
|
@ -797,8 +816,11 @@ function bin2hex (s) {
|
|||
// Dropdown menus with the class "dropdown-head" will display the active tab
|
||||
// as button text
|
||||
function toggleDropdownText(elm) {
|
||||
$(elm).closest(".dropdown").find('.btn').html($(elm).html() + ' <span class="caret"></span>');
|
||||
$(elm).closest(".dropdown").find('.btn').val($(elm).data('value'));
|
||||
$(elm)
|
||||
.closest(".dropdown")
|
||||
.find(".btn")
|
||||
.html($(elm).html() + ' <span class="caret"></span>');
|
||||
$(elm).closest(".dropdown").find(".btn").val($(elm).data("value"));
|
||||
$(elm).closest("ul").children("li").show();
|
||||
$(elm).parent("li").hide();
|
||||
}
|
||||
|
|
|
@ -29,17 +29,20 @@
|
|||
border_color: $link_color;
|
||||
}
|
||||
|
||||
.dropdown-menu, .account .dropdown-menu {
|
||||
.dropdown-menu,
|
||||
.account .dropdown-menu {
|
||||
background-color: $background_color;
|
||||
}
|
||||
.dropdown-menu>li>a:focus, .dropdown-menu>li>a:hover {
|
||||
.dropdown-menu > li > a:focus,
|
||||
.dropdown-menu > li > a:hover {
|
||||
color: $link_color;
|
||||
}
|
||||
.account .dropdown-menu li {
|
||||
border-color: $background_color;
|
||||
}
|
||||
|
||||
.dropdown-menu > li > a:focus, .dropdown-menu > li > a:hover {
|
||||
.dropdown-menu > li > a:focus,
|
||||
.dropdown-menu > li > a:hover {
|
||||
background-image: none;
|
||||
background-color: rgba(232, 232, 232, $contentbg_transp);
|
||||
}
|
||||
|
@ -61,9 +64,9 @@
|
|||
border-color: #a0a0a0;
|
||||
}
|
||||
|
||||
input[type=text],
|
||||
input[type=submit],
|
||||
button[type=submit]:not(.btn),
|
||||
input[type="text"],
|
||||
input[type="submit"],
|
||||
button[type="submit"]:not(.btn),
|
||||
select,
|
||||
textarea,
|
||||
.form-control {
|
||||
|
@ -73,11 +76,13 @@ textarea,
|
|||
box-shadow: 0 0 3px #dadada;
|
||||
-webkit-box-shadow: 0 0 3px #dadada;
|
||||
}
|
||||
input[type=range] {
|
||||
input[type="range"] {
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.form-control[disabled], .form-control[readonly], fieldset[disabled] .form-control {
|
||||
.form-control[disabled],
|
||||
.form-control[readonly],
|
||||
fieldset[disabled] .form-control {
|
||||
background-color: $background_color;
|
||||
color: $font_color_darker;
|
||||
}
|
||||
|
@ -97,7 +102,8 @@ main .nav-tabs>li.active>a:hover {
|
|||
color: $font_color_darker;
|
||||
}
|
||||
|
||||
.nav > li > a:focus, .nav > li > a:hover {
|
||||
.nav > li > a:focus,
|
||||
.nav > li > a:hover {
|
||||
background-color: rgba(238, 238, 238, $contentbg_transp);
|
||||
}
|
||||
|
||||
|
@ -126,7 +132,8 @@ main .nav-tabs>li.active>a:hover {
|
|||
color: $font_color;
|
||||
}
|
||||
|
||||
.pagination>li>a:hover, .pagination>li>span:hover {
|
||||
.pagination > li > a:hover,
|
||||
.pagination > li > span:hover {
|
||||
background-color: $nav_bg;
|
||||
}
|
||||
|
||||
|
@ -139,7 +146,8 @@ main .nav-tabs>li.active>a:hover {
|
|||
color: $font_color;
|
||||
text-shadow: 0 1px 0 $nav_bg;
|
||||
}
|
||||
.close:focus, .close:hover {
|
||||
.close:focus,
|
||||
.close:hover {
|
||||
color: $link_color;
|
||||
}
|
||||
|
||||
|
@ -174,19 +182,23 @@ main .nav-tabs>li.active>a:hover {
|
|||
background: none;
|
||||
color: $font_color_darker;
|
||||
}
|
||||
.btn.focus, .btn:focus, .btn:hover {
|
||||
.btn.focus,
|
||||
.btn:focus,
|
||||
.btn:hover {
|
||||
color: $font_color;
|
||||
}
|
||||
.btn-default:focus, .btn-default:hover {
|
||||
.btn-default:focus,
|
||||
.btn-default:hover {
|
||||
background: $nav_bg;
|
||||
}
|
||||
.btn-default.active, .btn-default:active {
|
||||
.btn-default.active,
|
||||
.btn-default:active {
|
||||
background-color: $nav_bg;
|
||||
color: $font_color;
|
||||
}
|
||||
|
||||
button[type=submit]:not(.btn),
|
||||
input[type=submit],
|
||||
button[type="submit"]:not(.btn),
|
||||
input[type="submit"],
|
||||
.btn.btn-primary {
|
||||
border: 1px solid $link_color;
|
||||
}
|
||||
|
@ -285,7 +297,8 @@ input[type=submit],
|
|||
box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
|
||||
-webkit-box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
.hovercard, .hover-card-footer {
|
||||
.hovercard,
|
||||
.hover-card-footer {
|
||||
background-color: $nav_bg;
|
||||
}
|
||||
.hovercard.top > .arrow:after {
|
||||
|
@ -305,14 +318,13 @@ input[type=submit],
|
|||
color: inherit;
|
||||
}
|
||||
|
||||
|
||||
code {
|
||||
color: $font_color;
|
||||
background-color: rgba(255, 255, 255, .2);
|
||||
background-color: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
pre {
|
||||
color: $font_color_darker;
|
||||
background-color: rgba(255, 255, 255, .05);
|
||||
background-color: rgba(255, 255, 255, 0.05);
|
||||
}
|
||||
|
||||
legend {
|
||||
|
@ -334,7 +346,8 @@ section > .generic-page-wrapper,
|
|||
.delegation-content-wrapper,
|
||||
.notes-content-wrapper,
|
||||
.message-content-wrapper,
|
||||
.apps-content-wrapper, #adminpage,
|
||||
.apps-content-wrapper,
|
||||
#adminpage,
|
||||
.delegate-content-wrapper,
|
||||
.uexport-content-wrapper,
|
||||
.dfrn_request-content-wrapper,
|
||||
|
@ -348,13 +361,12 @@ section > .generic-page-wrapper,
|
|||
.panel,
|
||||
aside .widget,
|
||||
.nav-container .widget,
|
||||
#back-to-top
|
||||
{
|
||||
#back-to-top {
|
||||
box-shadow: 0 0 3px $link_color;
|
||||
-webkit-box-shadow: 0 0 3px $link_color;
|
||||
}
|
||||
|
||||
input[type=text].tt-input {
|
||||
input[type="text"].tt-input {
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
|
|
|
@ -29,17 +29,20 @@
|
|||
border_color: $link_color;
|
||||
}
|
||||
|
||||
.dropdown-menu, .account .dropdown-menu {
|
||||
.dropdown-menu,
|
||||
.account .dropdown-menu {
|
||||
background-color: $background_color;
|
||||
}
|
||||
.dropdown-menu>li>a:focus, .dropdown-menu>li>a:hover {
|
||||
.dropdown-menu > li > a:focus,
|
||||
.dropdown-menu > li > a:hover {
|
||||
color: $link_color;
|
||||
}
|
||||
.account .dropdown-menu li {
|
||||
border-color: $background_color;
|
||||
}
|
||||
|
||||
.dropdown-menu > li > a:focus, .dropdown-menu > li > a:hover {
|
||||
.dropdown-menu > li > a:focus,
|
||||
.dropdown-menu > li > a:hover {
|
||||
background-image: none;
|
||||
background-color: rgba(232, 232, 232, $contentbg_transp);
|
||||
}
|
||||
|
@ -60,9 +63,9 @@
|
|||
-webkit-box-shadow: 0 0 3px #dadada;
|
||||
}
|
||||
|
||||
input[type=text],
|
||||
input[type=submit],
|
||||
button[type=submit]:not(.btn),
|
||||
input[type="text"],
|
||||
input[type="submit"],
|
||||
button[type="submit"]:not(.btn),
|
||||
select,
|
||||
textarea,
|
||||
.form-control {
|
||||
|
@ -72,7 +75,7 @@ textarea,
|
|||
box-shadow: 0 0 3px #dadada;
|
||||
-webkit-box-shadow: 0 0 3px #dadada;
|
||||
}
|
||||
input[type=range] {
|
||||
input[type="range"] {
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
|
@ -183,8 +186,8 @@ main .nav-tabs>li.active>a:hover {
|
|||
color: $font_color;
|
||||
}
|
||||
|
||||
button[type=submit]:not(.btn),
|
||||
input[type=submit],
|
||||
button[type="submit"]:not(.btn),
|
||||
input[type="submit"],
|
||||
.btn.btn-primary {
|
||||
border: 1px solid $link_color;
|
||||
}
|
||||
|
@ -304,14 +307,13 @@ input[type=submit],
|
|||
color: inherit;
|
||||
}
|
||||
|
||||
|
||||
code {
|
||||
color: $font_color;
|
||||
background-color: rgba(255, 255, 255, .2);
|
||||
background-color: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
pre {
|
||||
color: $font_color_darker;
|
||||
background-color: rgba(255, 255, 255, .05);
|
||||
background-color: rgba(255, 255, 255, 0.05);
|
||||
}
|
||||
|
||||
legend {
|
||||
|
@ -324,7 +326,7 @@ legend {
|
|||
background-color: $nav_bg;
|
||||
}
|
||||
|
||||
input[type=text].tt-input {
|
||||
input[type="text"].tt-input {
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
|
|
|
@ -5,17 +5,27 @@
|
|||
Author : koyu
|
||||
*/
|
||||
|
||||
#topbar-first, #topbar-second, body {
|
||||
#topbar-first,
|
||||
#topbar-second,
|
||||
body {
|
||||
background: #111;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
#topbar-first .dropdown.account > a, #topbar-first .dropdown.account.open > a, #topbar-first .dropdown.account > button, #topbar-first .dropdown.account.open > button, #topbar-first .dropdown.account > :hover, #topbar-first .dropdown.account.open > :hover {
|
||||
#topbar-first .dropdown.account > a,
|
||||
#topbar-first .dropdown.account.open > a,
|
||||
#topbar-first .dropdown.account > button,
|
||||
#topbar-first .dropdown.account.open > button,
|
||||
#topbar-first .dropdown.account > :hover,
|
||||
#topbar-first .dropdown.account.open > :hover {
|
||||
background: #111;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.nav-pills .dropdown-menu, .nav-tabs .dropdown-menu, .account .dropdown-menu, .contact-photo-wrapper .dropdown-menu {
|
||||
.nav-pills .dropdown-menu,
|
||||
.nav-tabs .dropdown-menu,
|
||||
.account .dropdown-menu,
|
||||
.contact-photo-wrapper .dropdown-menu {
|
||||
background: #111;
|
||||
-webkit-box-shadow: 0px 0px 69px 4px rgba(0, 0, 0, 0.25);
|
||||
-moz-box-shadow: 0px 0px 69px 4px rgba(0, 0, 0, 0.25);
|
||||
|
@ -23,7 +33,8 @@
|
|||
border: 0;
|
||||
}
|
||||
|
||||
.account .dropdown-menu li, .account .dropdown-menu li:hover {
|
||||
.account .dropdown-menu li,
|
||||
.account .dropdown-menu li:hover {
|
||||
border: 0;
|
||||
background: #111;
|
||||
}
|
||||
|
|
|
@ -50,17 +50,19 @@ aside .widget li.selected,
|
|||
.panel,
|
||||
aside .widget,
|
||||
.nav-container .widget,
|
||||
#profile-page, .photos-content-wrapper,
|
||||
#profile-page,
|
||||
.photos-content-wrapper,
|
||||
.settings-content-wrapper {
|
||||
border-style: solid solid solid solid;
|
||||
border-width: 1px;
|
||||
border-color: #DDDDDD;
|
||||
border-color: #dddddd;
|
||||
box-shadow: none;
|
||||
border-radius: 15px;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
aside .widget li a, aside .widget li a:hover,
|
||||
aside .widget li a,
|
||||
aside .widget li a:hover,
|
||||
.panel .panel-body .wall-item-content,
|
||||
.toplevel_item .wall-item-container .btn-link {
|
||||
color: #000;
|
||||
|
|
|
@ -16,13 +16,25 @@ body {
|
|||
height: auto;
|
||||
}
|
||||
|
||||
aside .widget, .form-control, .panel, .nav-container, .wall-item-content, .e-content, .p-name, .topbar, post, shiny, tread-wrapper, #topbar-second {
|
||||
aside .widget,
|
||||
.form-control,
|
||||
.panel,
|
||||
.nav-container,
|
||||
.wall-item-content,
|
||||
.e-content,
|
||||
.p-name,
|
||||
.topbar,
|
||||
post,
|
||||
shiny,
|
||||
tread-wrapper,
|
||||
#topbar-second {
|
||||
color: #000;
|
||||
background-color: #f5f5f5;
|
||||
}
|
||||
|
||||
.form-control {
|
||||
font-family: ".SFNSText-Regular","San Francisco","Roboto","Segoe UI","Helvetica Neue","Lucida Grande",Helvetica,Arial,sans-serif;
|
||||
font-family: ".SFNSText-Regular", "San Francisco", "Roboto", "Segoe UI", "Helvetica Neue", "Lucida Grande",
|
||||
Helvetica, Arial, sans-serif;
|
||||
}
|
||||
|
||||
#topbar-first #nav-notifications-menu li.notification-unseen {
|
||||
|
@ -93,7 +105,23 @@ aside .widget, .form-control, .panel, .nav-container, .wall-item-content, .e-con
|
|||
font-size: 12px;
|
||||
}
|
||||
|
||||
.wall-item-content .clearfix .post .comment-container .well .well-sm .wall-item-body .e-content .p-name .media .comment .wall-item-bottom .wall-item-links .wall-item-tags .wall-item-actions .wall-item-responses #hr {
|
||||
.wall-item-content
|
||||
.clearfix
|
||||
.post
|
||||
.comment-container
|
||||
.well
|
||||
.well-sm
|
||||
.wall-item-body
|
||||
.e-content
|
||||
.p-name
|
||||
.media
|
||||
.comment
|
||||
.wall-item-bottom
|
||||
.wall-item-links
|
||||
.wall-item-tags
|
||||
.wall-item-actions
|
||||
.wall-item-responses
|
||||
#hr {
|
||||
box-sizing: border-box;
|
||||
margin-top: 0px;
|
||||
margin-bottom: 0px;
|
||||
|
|
|
@ -7,31 +7,39 @@
|
|||
<div id="banner" class="hidden-sm hidden-xs">
|
||||
{{* show on remote/visitor connections an other logo which symols that fact*}}
|
||||
{{if $nav.remote}}
|
||||
<a href="{{$baseurl}}"><div id="remote-logo-img" aria-label="{{$home}}"></div></a>
|
||||
<a hruf="{{$baseurl}}">
|
||||
<div id="remote-logo-img" aria-label="{{$home}}"></div>
|
||||
</a>
|
||||
{{else}}
|
||||
{{* #logo-img is the the placeholder to insert a mask (friendica logo) into this div
|
||||
For Firefox we have to call the paths of the mask (look at the bottom of this file).
|
||||
Because for FF we need relative paths we apply them with js after the page is loaded (look at theme.js *}}
|
||||
<a href="{{$baseurl}}"><div id="logo-img" aria-label="{{$home}}"></div></a>
|
||||
<a href="{{$baseurl}}">
|
||||
<div id="logo-img" aria-label="{{$home}}"></div>
|
||||
</a>
|
||||
{{/if}}
|
||||
</div>
|
||||
</header>
|
||||
<nav id="topbar-first" class="topbar">
|
||||
<div class="container">
|
||||
<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 no-padding"><!-- div for navbar width-->
|
||||
<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 no-padding">
|
||||
<!-- div for navbar width-->
|
||||
<!-- Brand and toggle get grouped for better mobile display -->
|
||||
<div class="topbar-nav" role="navigation">
|
||||
|
||||
{{* Buttons for the mobile view *}}
|
||||
<button type="button" class="navbar-toggle collapsed pull-right" data-toggle="offcanvas" data-target="#myNavmenu" aria-controls="myNavmenu" aria-haspopup="true">
|
||||
<button type="button" class="navbar-toggle collapsed pull-right" data-toggle="offcanvas"
|
||||
data-target="#myNavmenu" aria-controls="myNavmenu" aria-haspopup="true">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<i class="fa fa-ellipsis-v fa-fw fa-lg" aria-hidden="true"></i>
|
||||
</button>
|
||||
<button type="button" class="navbar-toggle collapsed pull-right" data-toggle="collapse" data-target="#search-mobile" aria-expanded="false" aria-controls="search-mobile">
|
||||
<button type="button" class="navbar-toggle collapsed pull-right" data-toggle="collapse"
|
||||
data-target="#search-mobile" aria-expanded="false" aria-controls="search-mobile">
|
||||
<span class="sr-only">Toggle Search</span>
|
||||
<i class="fa fa-search fa-fw fa-lg" aria-hidden="true" style="color:#FFF;"></i>
|
||||
</button>
|
||||
<button type="button" class="navbar-toggle collapsed pull-left visible-sm visible-xs" data-toggle="offcanvas" data-target="aside" aria-haspopup="true">
|
||||
<button type="button" class="navbar-toggle collapsed pull-left visible-sm visible-xs"
|
||||
data-toggle="offcanvas" data-target="aside" aria-haspopup="true">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<i class="fa fa-ellipsis-v fa-fw fa-lg" aria-hidden="true"></i>
|
||||
</button>
|
||||
|
@ -40,54 +48,77 @@
|
|||
<ul class="nav navbar-left" role="menubar">
|
||||
{{if $nav.network}}
|
||||
<li class="nav-segment">
|
||||
<a accesskey="n" class="nav-menu {{$sel.network}}" href="{{$nav.network.0}}" data-toggle="tooltip" aria-label="{{$nav.network.3}}" title="{{$nav.network.3}}"><i class="fa fa-lg fa-th fa-fw" aria-hidden="true"></i><span id="net-update" class="nav-network-badge badge nav-notification"></span></a>
|
||||
<a accesskey="n" class="nav-menu {{$sel.network}}" href="{{$nav.network.0}}"
|
||||
data-toggle="tooltip" aria-label="{{$nav.network.3}}" title="{{$nav.network.3}}"><i
|
||||
class="fa fa-lg fa-th fa-fw" aria-hidden="true"></i><span id="net-update"
|
||||
class="nav-network-badge badge nav-notification"></span></a>
|
||||
</li>
|
||||
{{/if}}
|
||||
{{if $nav.home}}
|
||||
<li class="nav-segment">
|
||||
<a accesskey="p" class="nav-menu {{$sel.home}}" href="{{$nav.home.0}}" data-toggle="tooltip" aria-label="{{$nav.home.3}}" title="{{$nav.home.3}}"><i class="fa fa-lg fa-home fa-fw" aria-hidden="true"></i><span id="home-update" class="nav-home-badge badge nav-notification"></span></a>
|
||||
<a accesskey="p" class="nav-menu {{$sel.home}}" href="{{$nav.home.0}}" data-toggle="tooltip"
|
||||
aria-label="{{$nav.home.3}}" title="{{$nav.home.3}}"><i class="fa fa-lg fa-home fa-fw"
|
||||
aria-hidden="true"></i><span id="home-update"
|
||||
class="nav-home-badge badge nav-notification"></span></a>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{if $nav.community}}
|
||||
<li class="nav-segment">
|
||||
<a accesskey="c" class="nav-menu {{$sel.community}}" href="{{$nav.community.0}}" data-toggle="tooltip" aria-label="{{$nav.community.3}}" title="{{$nav.community.3}}"><i class="fa fa-lg fa-bullseye fa-fw" aria-hidden="true"></i></a>
|
||||
<a accesskey="c" class="nav-menu {{$sel.community}}" href="{{$nav.community.0}}"
|
||||
data-toggle="tooltip" aria-label="{{$nav.community.3}}" title="{{$nav.community.3}}"><i
|
||||
class="fa fa-lg fa-bullseye fa-fw" aria-hidden="true"></i></a>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{if $nav.messages}}
|
||||
<li class="nav-segment hidden-xs">
|
||||
<a accesskey="m" id="nav-messages-link" href="{{$nav.messages.0}}" data-toggle="tooltip" aria-label="{{$nav.messages.1}}" title="{{$nav.messages.1}}" class="nav-menu {{$sel.messages}}"><i class="fa fa-envelope fa-lg fa-fw" aria-hidden="true"></i><span id="mail-update" class="nav-mail-badge badge nav-notification"></span></a>
|
||||
<a accesskey="m" id="nav-messages-link" href="{{$nav.messages.0}}" data-toggle="tooltip"
|
||||
aria-label="{{$nav.messages.1}}" title="{{$nav.messages.1}}"
|
||||
class="nav-menu {{$sel.messages}}"><i class="fa fa-envelope fa-lg fa-fw"
|
||||
aria-hidden="true"></i><span id="mail-update"
|
||||
class="nav-mail-badge badge nav-notification"></span></a>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{if $nav.events}}
|
||||
<li class="nav-segment hidden-xs">
|
||||
<a accesskey="e" id="nav-events-link" href="{{$nav.events.0}}" data-toggle="tooltip" aria-label="{{$nav.events.1}}" title="{{$nav.events.1}}" class="nav-menu"><i class="fa fa-lg fa-calendar fa-fw"></i></a>
|
||||
<a accesskey="e" id="nav-events-link" href="{{$nav.events.0}}" data-toggle="tooltip"
|
||||
aria-label="{{$nav.events.1}}" title="{{$nav.events.1}}" class="nav-menu"><i
|
||||
class="fa fa-lg fa-calendar fa-fw"></i></a>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{if $nav.contacts}}
|
||||
<li class="nav-segment hidden-xs">
|
||||
<a accesskey="k" id="nav-contacts-link" href="{{$nav.contacts.0}}" data-toggle="tooltip" aria-label="{{$nav.contacts.1}}" title="{{$nav.contacts.1}}"class="nav-menu {{$sel.contacts}} {{$nav.contacts.2}}"><i class="fa fa-users fa-lg fa-fw"></i></a>
|
||||
<a accesskey="k" id="nav-contacts-link" href="{{$nav.contacts.0}}" data-toggle="tooltip"
|
||||
aria-label="{{$nav.contacts.1}}" title="{{$nav.contacts.1}}"
|
||||
class="nav-menu {{$sel.contacts}} {{$nav.contacts.2}}"><i
|
||||
class="fa fa-users fa-lg fa-fw"></i></a>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{* The notifications dropdown *}}
|
||||
{{if $nav.notifications}}
|
||||
<li id="nav-notification" class="nav-segment dropdown" role="presentation">
|
||||
<button id="nav-notifications-menu-btn" class="btn-link dropdown-toggle" data-toggle="dropdown" type="button" aria-haspopup="true" aria-expanded="false" aria-controls="nav-notifications-menu">
|
||||
<button id="nav-notifications-menu-btn" class="btn-link dropdown-toggle" data-toggle="dropdown"
|
||||
type="button" aria-haspopup="true" aria-expanded="false"
|
||||
aria-controls="nav-notifications-menu">
|
||||
<span id="notification-update" class="nav-notification-badge badge nav-notification"></span>
|
||||
<i class="fa fa-bell fa-lg" aria-label="{{$nav.notifications.1}}"></i>
|
||||
</button>
|
||||
{{* The notifications dropdown menu. There are two parts of menu. The second is at the bottom of this file. It is loaded via js. Look at nav-notifications-template *}}
|
||||
<ul id="nav-notifications-menu" class="dropdown-menu menu-popup" role="menu" aria-labelledby="nav-notifications-menu-btn">
|
||||
<ul id="nav-notifications-menu" class="dropdown-menu menu-popup" role="menu"
|
||||
aria-labelledby="nav-notifications-menu-btn">
|
||||
{{* the following list entry must have the id "nav-notificaionts-mark-all". Without it this isn't visable. ....strange behavior :-/ *}}
|
||||
<li role="presentation" id="nav-notifications-mark-all" class="dropdown-header">
|
||||
<div class="arrow"></div>
|
||||
{{$nav.notifications.1}}
|
||||
<div class="dropdown-header-link">
|
||||
<button role="menuitem" type="button" class="btn-link" onclick="notificationMarkAll();" data-toggle="tooltip" aria-label="{{$nav.notifications.mark.3}}" title="{{$nav.notifications.mark.3}}">{{$nav.notifications.mark.1}}</button>
|
||||
<button role="menuitem" type="button" class="btn-link"
|
||||
onclick="notificationMarkAll();" data-toggle="tooltip"
|
||||
aria-label="{{$nav.notifications.mark.3}}"
|
||||
title="{{$nav.notifications.mark.3}}">{{$nav.notifications.mark.1}}</button>
|
||||
</div>
|
||||
|
||||
</li>
|
||||
|
@ -112,8 +143,11 @@
|
|||
<form class="navbar-form" role="search" method="get" action="{{$nav.search.0}}">
|
||||
<!-- <img class="hidden-xs" src="{{$nav.userinfo.icon}}" alt="{{$nav.userinfo.name}}" style="max-width:33px; max-height:33px; min-width:33px; min-height:33px; width:33px; height:33px;"> -->
|
||||
<div class="form-group form-group-search">
|
||||
<input accesskey="s" id="nav-search-input-field" class="form-control form-search" type="text" name="q" data-toggle="tooltip" title="{{$search_hint}}" placeholder="{{$nav.search.1}}">
|
||||
<button class="btn btn-default btn-sm form-button-search" type="submit">{{$nav.search.1}}</button>
|
||||
<input accesskey="s" id="nav-search-input-field" class="form-control form-search"
|
||||
type="text" name="q" data-toggle="tooltip" title="{{$search_hint}}"
|
||||
placeholder="{{$nav.search.1}}">
|
||||
<button class="btn btn-default btn-sm form-button-search"
|
||||
type="submit">{{$nav.search.1}}</button>
|
||||
</div>
|
||||
</form>
|
||||
</li>
|
||||
|
@ -122,7 +156,9 @@
|
|||
{{* The user dropdown menu *}}
|
||||
{{if $nav.userinfo}}
|
||||
<li id="nav-user-linkmenu" class="dropdown account nav-menu hidden-xs">
|
||||
<button accesskey="u" id="main-menu" class="btn-link dropdown-toggle nav-avatar" data-toggle="dropdown" type="button" aria-haspopup="true" aria-expanded="false" aria-controls="nav-user-menu">
|
||||
<button accesskey="u" id="main-menu" class="btn-link dropdown-toggle nav-avatar"
|
||||
data-toggle="dropdown" type="button" aria-haspopup="true" aria-expanded="false"
|
||||
aria-controls="nav-user-menu">
|
||||
<div aria-hidden="true" class="user-title pull-left hidden-xs hidden-sm hidden-md">
|
||||
<strong>{{$nav.userinfo.name}}</strong><br>
|
||||
{{if $nav.remote}}<span class="trunctate">{{$nav.remote}}</span>{{/if}}
|
||||
|
@ -133,52 +169,91 @@
|
|||
</button>
|
||||
|
||||
{{* The list of available usermenu links *}}
|
||||
<ul id="nav-user-menu" class="dropdown-menu pull-right menu-popup" role="menu" aria-labelledby="main-menu">
|
||||
{{if $nav.remote}}{{if $nav.sitename}}
|
||||
<ul id="nav-user-menu" class="dropdown-menu pull-right menu-popup" role="menu"
|
||||
aria-labelledby="main-menu">
|
||||
{{if $nav.remote}}
|
||||
{{if $nav.sitename}}
|
||||
<li id="nav-sitename" role="menuitem">{{$nav.sitename}}</li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
{{/if}}{{/if}}
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
{{foreach $nav.usermenu as $usermenu}}
|
||||
<li role="presentation"><a role="menuitem" class="{{$usermenu.2}}" href="{{$usermenu.0}}" title="{{$usermenu.3}}">{{$usermenu.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" class="{{$usermenu.2}}" href="{{$usermenu.0}}"
|
||||
title="{{$usermenu.3}}">{{$usermenu.1}}</a></li>
|
||||
{{/foreach}}
|
||||
<li role="presentation" class="divider"></li>
|
||||
{{if $nav.notifications}}
|
||||
<li role="presentation"><a role="menuitem" href="{{$nav.notifications.all.0}}" title="{{$nav.notifications.1}}"><i class="fa fa-bell fa-fw" aria-hidden="true"></i> {{$nav.notifications.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" href="{{$nav.notifications.all.0}}"
|
||||
title="{{$nav.notifications.1}}"><i class="fa fa-bell fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.notifications.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.messages}}
|
||||
<li role="presentation"><a role="menuitem" class="nav-commlink {{$nav.messages.2}} {{$sel.messages}}" href="{{$nav.messages.0}}" title="{{$nav.messages.3}}" ><i class="fa fa-envelope fa-fw" aria-hidden="true"></i> {{$nav.messages.1}} <span id="mail-update-li" class="nav-mail-badge badge nav-notification"></span></a></li>
|
||||
<li role="presentation"><a role="menuitem"
|
||||
class="nav-commlink {{$nav.messages.2}} {{$sel.messages}}"
|
||||
href="{{$nav.messages.0}}" title="{{$nav.messages.3}}"><i
|
||||
class="fa fa-envelope fa-fw" aria-hidden="true"></i> {{$nav.messages.1}} <span
|
||||
id="mail-update-li" class="nav-mail-badge badge nav-notification"></span></a>
|
||||
</li>
|
||||
{{/if}}
|
||||
<li role="presentation" class="divider"></li>
|
||||
{{if $nav.contacts}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-menu-contacts-link" class="nav-link {{$nav.contacts.2}}" href="{{$nav.contacts.0}}" title="{{$nav.contacts.3}}"><i class="fa fa-users fa-fw" aria-hidden="true"></i> {{$nav.contacts.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-menu-contacts-link"
|
||||
class="nav-link {{$nav.contacts.2}}" href="{{$nav.contacts.0}}"
|
||||
title="{{$nav.contacts.3}}"><i class="fa fa-users fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.contacts.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.delegation}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-delegation-link" class="nav-commlink {{$nav.delegation.2}} {{$sel.delegation}}" href="{{$nav.delegation.0}}" title="{{$nav.delegation.3}}"><i class="fa fa-flag fa-fw" aria-hidden="true"></i> {{$nav.delegation.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-delegation-link"
|
||||
class="nav-commlink {{$nav.delegation.2}} {{$sel.delegation}}"
|
||||
href="{{$nav.delegation.0}}" title="{{$nav.delegation.3}}"><i
|
||||
class="fa fa-flag fa-fw" aria-hidden="true"></i> {{$nav.delegation.1}}</a></li>
|
||||
{{/if}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-directory-link" class="nav-link {{$nav.directory.2}}" href="{{$nav.directory.0}}" title="{{$nav.directory.3}}"><i class="fa fa-sitemap fa-fw" aria-hidden="true"></i>{{$nav.directory.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-directory-link"
|
||||
class="nav-link {{$nav.directory.2}}" href="{{$nav.directory.0}}"
|
||||
title="{{$nav.directory.3}}"><i class="fa fa-sitemap fa-fw"
|
||||
aria-hidden="true"></i>{{$nav.directory.1}}</a></li>
|
||||
<li role="presentation" class="divider"></li>
|
||||
{{if $nav.apps}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-apps-link" class="nav-link {{$nav.apps.2}}" href="{{$nav.apps.0}}" title="{{$nav.apps.3}}" ><i class="fa fa-puzzle-piece fa-fw" aria-hidden="true"></i> {{$nav.apps.1}}</a>
|
||||
<li role="presentation"><a role="menuitem" id="nav-apps-link"
|
||||
class="nav-link {{$nav.apps.2}}" href="{{$nav.apps.0}}" title="{{$nav.apps.3}}"><i
|
||||
class="fa fa-puzzle-piece fa-fw" aria-hidden="true"></i> {{$nav.apps.1}}</a>
|
||||
<li role="presentation" class="divider"></li>
|
||||
{{/if}}
|
||||
{{if $nav.help}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-help-link" class="nav-link {{$nav.help.2}}" href="{{$nav.help.0}}" title="{{$nav.help.3}}" ><i class="fa fa-question-circle fa-fw" aria-hidden="true"></i> {{$nav.help.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-help-link"
|
||||
class="nav-link {{$nav.help.2}}" href="{{$nav.help.0}}" title="{{$nav.help.3}}"><i
|
||||
class="fa fa-question-circle fa-fw" aria-hidden="true"></i> {{$nav.help.1}}</a>
|
||||
</li>
|
||||
{{/if}}
|
||||
{{if $nav.settings}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-settings-link" class="nav-link {{$nav.settings.2}}" href="{{$nav.settings.0}}" title="{{$nav.settings.3}}"><i class="fa fa-cog fa-fw" aria-hidden="true"></i> {{$nav.settings.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-settings-link"
|
||||
class="nav-link {{$nav.settings.2}}" href="{{$nav.settings.0}}"
|
||||
title="{{$nav.settings.3}}"><i class="fa fa-cog fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.settings.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.admin}}
|
||||
<li role="presentation"><a accesskey="a" role="menuitem" id="nav-admin-link" class="nav-link {{$nav.admin.2}}" href="{{$nav.admin.0}}" title="{{$nav.admin.3}}" ><i class="fa fa-user-secret fa-fw" aria-hidden="true"></i> {{$nav.admin.1}}</a></li>
|
||||
<li role="presentation"><a accesskey="a" role="menuitem" id="nav-admin-link"
|
||||
class="nav-link {{$nav.admin.2}}" href="{{$nav.admin.0}}"
|
||||
title="{{$nav.admin.3}}"><i class="fa fa-user-secret fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.admin.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.tos}}
|
||||
<li role="presentation" class="divider"></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-tos-link" class="nav-link {{$nav.tos.2}}" href="{{$nav.tos.0}}" title="{{$nav.tos.3}}" ><i class="fa fa-file-text" aria-hidden="true"></i> {{$nav.tos.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-tos-link" class="nav-link {{$nav.tos.2}}"
|
||||
href="{{$nav.tos.0}}" title="{{$nav.tos.3}}"><i class="fa fa-file-text"
|
||||
aria-hidden="true"></i> {{$nav.tos.1}}</a></li>
|
||||
{{/if}}
|
||||
<li role="presentation" class="divider"></li>
|
||||
{{if $nav.logout}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-logout-link" class="nav-link {{$nav.logout.2}}" href="{{$nav.logout.0}}" title="{{$nav.logout.3}}" ><i class="fa fa fa-sign-out fa-fw" aria-hidden="true"></i> {{$nav.logout.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-logout-link"
|
||||
class="nav-link {{$nav.logout.2}}" href="{{$nav.logout.0}}"
|
||||
title="{{$nav.logout.3}}"><i class="fa fa fa-sign-out fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.logout.1}}</a></li>
|
||||
{{else}}
|
||||
<li role="presentation"><a role="menuitem" id="nav-login-link" class="nav-login-link {{$nav.login.2}}" href="{{$nav.login.0}}" title="{{$nav.login.3}}" ><i class="fa fa-power-off fa-fw" aria-hidden="true"></i> {{$nav.login.1}}</a></li>
|
||||
<li role="presentation"><a role="menuitem" id="nav-login-link"
|
||||
class="nav-login-link {{$nav.login.2}}" href="{{$nav.login.0}}"
|
||||
title="{{$nav.login.3}}"><i class="fa fa-power-off fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.login.1}}</a></li>
|
||||
{{/if}}
|
||||
</ul>
|
||||
</li>{{* End of userinfo dropdown menu *}}
|
||||
|
@ -194,39 +269,67 @@
|
|||
<div id="myNavmenu" class="navmenu navmenu-default navmenu-fixed-right offcanvas">
|
||||
<div class="nav-container">
|
||||
<ul role="menu" class="list-group">
|
||||
{{if $nav.remote}}{{if $nav.sitename}}
|
||||
{{if $nav.remote}}
|
||||
{{if $nav.sitename}}
|
||||
<li role="menuitem" class="nav-sitename list-group-item">{{$nav.sitename}}</li>
|
||||
{{/if}}{{/if}}
|
||||
<li role="presentation" class="list-group-item"><img src="{{$nav.userinfo.icon}}" alt="{{$nav.userinfo.name}}" style="max-width:15px; max-height:15px; min-width:15px; min-height:15px; width:15px; height:15px;"> {{$nav.userinfo.name}}{{if $nav.remote}} ({{$nav.remote}}){{/if}}</li>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
<li role="presentation" class="list-group-item"><img src="{{$nav.userinfo.icon}}"
|
||||
alt="{{$nav.userinfo.name}}"
|
||||
style="max-width:15px; max-height:15px; min-width:15px; min-height:15px; width:15px; height:15px;">
|
||||
{{$nav.userinfo.name}}{{if $nav.remote}} ({{$nav.remote}}){{/if}}</li>
|
||||
{{foreach $nav.usermenu as $usermenu}}
|
||||
<li role="menuitem" class="list-group-item"><a role="menuitem" class="{{$usermenu.2}}" href="{{$usermenu.0}}" title="{{$usermenu.3}}">{{$usermenu.1}}</a></li>
|
||||
<li role="menuitem" class="list-group-item"><a role="menuitem" class="{{$usermenu.2}}"
|
||||
href="{{$usermenu.0}}" title="{{$usermenu.3}}">{{$usermenu.1}}</a></li>
|
||||
{{/foreach}}
|
||||
{{if $nav.notifications}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" href="{{$nav.notifications.all.0}}" title="{{$nav.notifications.1}}"><i class="fa fa-bell fa-fw" aria-hidden="true"></i> {{$nav.notifications.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
href="{{$nav.notifications.all.0}}" title="{{$nav.notifications.1}}"><i
|
||||
class="fa fa-bell fa-fw" aria-hidden="true"></i> {{$nav.notifications.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.contacts}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" class="nav-link {{$nav.contacts.2}}" href="{{$nav.contacts.0}}" title="{{$nav.contacts.3}}"><i class="fa fa-users fa-fw" aria-hidden="true"></i> {{$nav.contacts.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
class="nav-link {{$nav.contacts.2}}" href="{{$nav.contacts.0}}"
|
||||
title="{{$nav.contacts.3}}"><i class="fa fa-users fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.contacts.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.messages}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" class="nav-link {{$nav.messages.2}} {{$sel.messages}}" href="{{$nav.messages.0}}" title="{{$nav.messages.3}}" ><i class="fa fa-envelope fa-fw" aria-hidden="true"></i> {{$nav.messages.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
class="nav-link {{$nav.messages.2}} {{$sel.messages}}" href="{{$nav.messages.0}}"
|
||||
title="{{$nav.messages.3}}"><i class="fa fa-envelope fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.messages.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.delegation}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" class="nav-commlink {{$nav.delegation.2}} {{$sel.delegation}}" href="{{$nav.delegation.0}}" title="{{$nav.delegation.3}}"><i class="fa fa-flag fa-fw" aria-hidden="true"></i> {{$nav.delegation.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
class="nav-commlink {{$nav.delegation.2}} {{$sel.delegation}}"
|
||||
href="{{$nav.delegation.0}}" title="{{$nav.delegation.3}}"><i class="fa fa-flag fa-fw"
|
||||
aria-hidden="true"></i> {{$nav.delegation.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.settings}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" class="nav-link {{$nav.settings.2}}" href="{{$nav.settings.0}}" title="{{$nav.settings.3}}"><i class="fa fa-cog fa-fw" aria-hidden="true"></i> {{$nav.settings.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
class="nav-link {{$nav.settings.2}}" href="{{$nav.settings.0}}"
|
||||
title="{{$nav.settings.3}}"><i class="fa fa-cog fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.settings.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.admin}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" class="nav-link {{$nav.admin.2}}" href="{{$nav.admin.0}}" title="{{$nav.admin.3}}" ><i class="fa fa-user-secret fa-fw" aria-hidden="true"></i> {{$nav.admin.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
class="nav-link {{$nav.admin.2}}" href="{{$nav.admin.0}}" title="{{$nav.admin.3}}"><i
|
||||
class="fa fa-user-secret fa-fw" aria-hidden="true"></i> {{$nav.admin.1}}</a></li>
|
||||
{{/if}}
|
||||
{{if $nav.logout}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" class="nav-link {{$nav.logout.2}}" href="{{$nav.logout.0}}" title="{{$nav.logout.3}}" ><i class="fa fa fa-sign-out fa-fw" aria-hidden="true"></i> {{$nav.logout.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
class="nav-link {{$nav.logout.2}}" href="{{$nav.logout.0}}" title="{{$nav.logout.3}}"><i
|
||||
class="fa fa fa-sign-out fa-fw" aria-hidden="true"></i> {{$nav.logout.1}}</a></li>
|
||||
{{else}}
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem" class="nav-login-link {{$nav.login.2}}" href="{{$nav.login.0}}" title="{{$nav.login.3}}" ><i class="fa fa-power-off fa-fw" aria-hidden="true"></i> {{$nav.login.1}}</a></li>
|
||||
<li role="presentation" class="list-group-item"><a role="menuitem"
|
||||
class="nav-login-link {{$nav.login.2}}" href="{{$nav.login.0}}"
|
||||
title="{{$nav.login.3}}"><i class="fa fa-power-off fa-fw" aria-hidden="true"></i>
|
||||
{{$nav.login.1}}</a></li>
|
||||
{{/if}}
|
||||
</ul>
|
||||
</div>
|
||||
</div><!--/.sidebar-offcanvas-->
|
||||
</div>
|
||||
<!--/.sidebar-offcanvas-->
|
||||
</div><!-- end of div for navbar width-->
|
||||
</div><!-- /.container -->
|
||||
</nav><!-- /.navbar -->
|
||||
|
@ -238,21 +341,24 @@
|
|||
<nav class="navbar navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header pull-left">
|
||||
<a class="navbar-brand" href="#"><div id="navbrand-container">
|
||||
<a class="navbar-brand" href="#">
|
||||
<div id="navbrand-container">
|
||||
<div id="logo-img"></div>
|
||||
<div id="navbar-brand-text"> Friendica</div></div>
|
||||
<div id="navbar-brand-text"> Friendica</div>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<div class="pull-right">
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li role="presentation">
|
||||
<a href="login?mode=none" id="nav-login"
|
||||
data-toggle="tooltip" aria-label="{{$nav.login.3}}" title="{{$nav.login.3}}">
|
||||
<a href="login?mode=none" id="nav-login" data-toggle="tooltip" aria-label="{{$nav.login.3}}"
|
||||
title="{{$nav.login.3}}">
|
||||
<i class="fa fa-sign-in fa-fw" aria-hidden="true"></i>
|
||||
</a>
|
||||
</li>
|
||||
<li role="presentation">
|
||||
<a href="{{$nav.about.0}}" id="nav-about" data-toggle="tooltip" aria-label="{{$nav.about.3}}" title="{{$nav.about.3}}">
|
||||
<a href="{{$nav.about.0}}" id="nav-about" data-toggle="tooltip" aria-label="{{$nav.about.3}}"
|
||||
title="{{$nav.about.3}}">
|
||||
<i class="fa fa-info fa-fw" aria-hidden="true"></i>
|
||||
</a>
|
||||
</li>
|
||||
|
@ -269,7 +375,8 @@
|
|||
<form class="navbar-form" role="search" method="get" action="{{$nav.search.0}}">
|
||||
<!-- <img class="hidden-xs" src="{{$nav.userinfo.icon}}" alt="{{$nav.userinfo.name}}" style="max-width:33px; max-height:33px; min-width:33px; min-height:33px; width:33px; height:33px;"> -->
|
||||
<div class="form-group form-group-search">
|
||||
<input id="nav-search-input-field-mobile" class="form-control form-search" type="text" name="q" data-toggle="tooltip" title="{{$search_hint}}" placeholder="{{$nav.search.1}}">
|
||||
<input id="nav-search-input-field-mobile" class="form-control form-search" type="text" name="q"
|
||||
data-toggle="tooltip" title="{{$search_hint}}" placeholder="{{$nav.search.1}}">
|
||||
<button class="btn btn-default btn-sm form-button-search" type="submit">{{$nav.search.1}}</button>
|
||||
</div>
|
||||
</form>
|
||||
|
@ -290,7 +397,8 @@
|
|||
<ul id="nav-notifications-template" class="media-list" style="display:none;" rel="template">
|
||||
<li class="{4} notif-entry">
|
||||
<div class="notif-entry-wrapper media">
|
||||
<div class="notif-photo-wrapper media-object pull-left" aria-hidden="true"><a href="{6}" class="userinfo click-card" tabIndex="-1"><img data-src="{1}"></a></div>
|
||||
<div class="notif-photo-wrapper media-object pull-left" aria-hidden="true"><a href="{6}"
|
||||
class="userinfo click-card" tabIndex="-1"><img data-src="{1}"></a></div>
|
||||
<a href="{0}" class="notif-desc-wrapper media-body">
|
||||
{2}
|
||||
<div><time class="notif-when time" data-toggle="tooltip" title="{5}">{3}</time></div>
|
||||
|
@ -305,7 +413,9 @@ The result is a friendica logo in the user icon color.*}}
|
|||
<svg id="friendica-logo-mask" x="0px" y="0px" width="0px" height="0px" viewBox="0 0 250 250">
|
||||
<defs>
|
||||
<mask id="logo-mask" maskUnits="objectBoundingBox" maskContentUnits="objectBoundingBox">
|
||||
<path style="fill-rule:evenodd;clip-rule:evenodd;fill:#ffffff;" d="M0.796,0L0.172,0.004C0.068,0.008,0.008,0.068,0,0.172V0.824c0,0.076,0.06,0.16,0.168,0.172h0.652c0.072,0,0.148-0.06,0.172-0.144V0.14C1,0.06,0.908,0,0.796,0zM0.812,0.968H0.36v-0.224h0.312v-0.24H0.36V0.3h0.316l0-0.264l0.116-0c0.088,0,0.164,0.044,0.164,0.096l0,0.696C0.96,0.912,0.876,0.968,0.812,0.968z"></path>
|
||||
<path style="fill-rule:evenodd;clip-rule:evenodd;fill:#ffffff;"
|
||||
d="M0.796,0L0.172,0.004C0.068,0.008,0.008,0.068,0,0.172V0.824c0,0.076,0.06,0.16,0.168,0.172h0.652c0.072,0,0.148-0.06,0.172-0.144V0.14C1,0.06,0.908,0,0.796,0zM0.812,0.968H0.36v-0.224h0.312v-0.24H0.36V0.3h0.316l0-0.264l0.116-0c0.088,0,0.164,0.044,0.164,0.096l0,0.696C0.96,0.912,0.876,0.968,0.812,0.968z">
|
||||
</path>
|
||||
</mask>
|
||||
</defs>
|
||||
</svg>
|
Loading…
Reference in a new issue