mirror of
https://github.com/janeczku/calibre-web
synced 2025-11-02 08:13:02 +00:00
Merge branch 'master' into development
# Conflicts: # cps/static/css/style.css
This commit is contained in:
@@ -677,7 +677,7 @@ $(".navbar-collapse.collapse.in").before('<div class="sidebar-backdrop"></div>')
|
||||
// Get rid of leading white space
|
||||
recentlyAdded = $("#nav_new a:contains('Recently')").text().trim();
|
||||
$("#nav_new a:contains('Recently')").contents().filter(function () {
|
||||
return this.nodeType == 3
|
||||
return this.nodeType === 3
|
||||
}).each(function () {
|
||||
this.textContent = this.textContent.replace(" Recently Added", recentlyAdded);
|
||||
});
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/**
|
||||
* Created by SpeedProg on 05.04.2015.
|
||||
*/
|
||||
/* global Bloodhound, language, Modernizr, tinymce */
|
||||
/* global Bloodhound, language, Modernizr, tinymce, getPath */
|
||||
|
||||
if ($("#description").length) {
|
||||
tinymce.init({
|
||||
@@ -250,14 +250,14 @@ promisePublishers.done(function() {
|
||||
});
|
||||
|
||||
$("#search").on("change input.typeahead:selected", function(event) {
|
||||
if (event.target.type == "search" && event.target.tagName == "INPUT") {
|
||||
if (event.target.type === "search" && event.target.tagName === "INPUT") {
|
||||
return;
|
||||
}
|
||||
var form = $("form").serialize();
|
||||
$.getJSON( getPath() + "/get_matching_tags", form, function( data ) {
|
||||
$(".tags_click").each(function() {
|
||||
if ($.inArray(parseInt($(this).val(), 10), data.tags) === -1) {
|
||||
if(!$(this).prop("selected")) {
|
||||
if (!$(this).prop("selected")) {
|
||||
$(this).prop("disabled", true);
|
||||
}
|
||||
} else {
|
||||
@@ -265,10 +265,10 @@ $("#search").on("change input.typeahead:selected", function(event) {
|
||||
}
|
||||
});
|
||||
$("#include_tag option:selected").each(function () {
|
||||
$("#exclude_tag").find("[value="+$(this).val()+"]").prop("disabled", true);
|
||||
$("#exclude_tag").find("[value="+$(this).val() + "]").prop("disabled", true);
|
||||
});
|
||||
$('#include_tag').selectpicker("refresh");
|
||||
$('#exclude_tag').selectpicker("refresh");
|
||||
$("#include_tag").selectpicker("refresh");
|
||||
$("#exclude_tag").selectpicker("refresh");
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@@ -88,7 +88,7 @@ $("#desc").click(function() {
|
||||
// Find count of middle element
|
||||
var count = $(".row:visible").length;
|
||||
if (count > 20) {
|
||||
middle = parseInt(count / 2) + (count % 2);
|
||||
middle = parseInt(count / 2, 10) + (count % 2);
|
||||
|
||||
//var middle = parseInt(count / 2) + (count % 2);
|
||||
// search for the middle of all visible elements
|
||||
@@ -135,7 +135,7 @@ $("#asc").click(function() {
|
||||
// Find count of middle element
|
||||
var count = $(".row:visible").length;
|
||||
if (count > 20) {
|
||||
var middle = parseInt(count / 2) + (count % 2);
|
||||
var middle = parseInt(count / 2, 10) + (count % 2);
|
||||
|
||||
//var middle = parseInt(count / 2) + (count % 2);
|
||||
// search for the middle of all visible elements
|
||||
|
||||
@@ -146,6 +146,9 @@ kthoom.ImageFile = function(file) {
|
||||
case "jpeg":
|
||||
this.mimeType = "image/jpeg";
|
||||
break;
|
||||
case "png":
|
||||
this.mimeType = "image/png";
|
||||
break;
|
||||
case "gif":
|
||||
this.mimeType = "image/gif";
|
||||
break;
|
||||
|
||||
@@ -38,10 +38,10 @@ $(document).on("change", "input[type=\"checkbox\"][data-control]", function () {
|
||||
$(document).on("change", "select[data-control]", function() {
|
||||
var $this = $(this);
|
||||
var name = $this.data("control");
|
||||
var showOrHide = parseInt($this.val());
|
||||
var showOrHide = parseInt($this.val(), 10);
|
||||
// var showOrHideLast = $("#" + name + " option:last").val()
|
||||
for (var i = 0; i < $(this)[0].length; i++) {
|
||||
var element = parseInt($(this)[0][i].value);
|
||||
var element = parseInt($(this)[0][i].value, 10);
|
||||
if (element === showOrHide) {
|
||||
$("[data-related^=" + name + "][data-related*=-" + element + "]").show();
|
||||
} else {
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
*/
|
||||
|
||||
/* exported TableActions, RestrictionActions, EbookActions, responseHandler */
|
||||
/* global getPath, ConfirmDialog */
|
||||
|
||||
var selections = [];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user