From f63f91625d087b3a9fcdf5242fcd5bfb4403ede9 Mon Sep 17 00:00:00 2001 From: "Felix A. Epp" Date: Mon, 23 Jan 2017 00:52:09 +0100 Subject: [PATCH 1/3] Remove obsolete/faulty css for the top right button Signed-off-by: Felix A. Epp --- css/gallerybutton.css | 5 ----- 1 file changed, 5 deletions(-) diff --git a/css/gallerybutton.css b/css/gallerybutton.css index 6473d27a1..06963b608 100644 --- a/css/gallerybutton.css +++ b/css/gallerybutton.css @@ -6,11 +6,7 @@ #controls .button.view-switcher { float: right; margin-top: 5px; - font-weight: normal; - width: 40px; padding: 6px 11px; - background-color: transparent; - border: 1px solid transparent; } #controls .button.view-switcher img{ @@ -21,7 +17,6 @@ float: none; margin-right: 4px; padding: 7px 11px; - background-color: rgba(240, 240, 240, .9); } #controls .button.view-switcher.gallery img{ From 523d28203336bd1a2214e78da9d56b4751c6b283 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Molakvo=C3=A6=20=28skjnldsv=29?= Date: Tue, 24 Jan 2017 12:24:09 +0100 Subject: [PATCH 2/3] Fix button element MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: John Molakvoæ (skjnldsv) --- css/gallerybutton.css | 9 +++------ js/gallerybutton.js | 4 +--- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/css/gallerybutton.css b/css/gallerybutton.css index 06963b608..8420a5c45 100644 --- a/css/gallerybutton.css +++ b/css/gallerybutton.css @@ -9,18 +9,15 @@ padding: 6px 11px; } -#controls .button.view-switcher img{ - opacity: .3; -} - #controls .button.view-switcher.gallery { float: none; margin-right: 4px; padding: 7px 11px; } -#controls .button.view-switcher.gallery img{ - opacity: .5; +/* TODO: move to core */ +.icon-toggle-pictures { + background-image: url('../../../core/img/actions/toggle-pictures.svg?v=1'); } #controls .button.sorting { diff --git a/js/gallerybutton.js b/js/gallerybutton.js index 8b9ddbe87..b795c0b79 100644 --- a/js/gallerybutton.js +++ b/js/gallerybutton.js @@ -72,9 +72,7 @@ $(document).ready(function () { GalleryButton.button = $(''); GalleryButton.button.click(function () { From 8074f5c95fe3f3a34254d181502c9edc0b1b026d Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Thu, 27 Jul 2017 17:19:05 +0200 Subject: [PATCH 3/3] Adjust all buttons to the server style of Nextcloud 12 Signed-off-by: Morris Jobke --- css/gallerybutton.css | 31 ++++++------------------------- js/gallery.js | 3 ++- js/gallerybutton.js | 5 +++-- js/galleryview.js | 4 ++-- templates/part.content.php | 2 +- templates/public.php | 2 +- 6 files changed, 15 insertions(+), 32 deletions(-) diff --git a/css/gallerybutton.css b/css/gallerybutton.css index 8420a5c45..5dbf1f86f 100644 --- a/css/gallerybutton.css +++ b/css/gallerybutton.css @@ -12,12 +12,11 @@ #controls .button.view-switcher.gallery { float: none; margin-right: 4px; - padding: 7px 11px; + padding: 9px 11px; } -/* TODO: move to core */ -.icon-toggle-pictures { - background-image: url('../../../core/img/actions/toggle-pictures.svg?v=1'); +.icon-toggle-pictures.hidden { + opacity: 0 !important; } #controls .button.sorting { @@ -34,8 +33,6 @@ border-radius: 3px 0 0 3px; margin-left: 3px; margin-right: 0; - border-right: 0; - border-right: 1px solid rgba(216, 216, 216, 0.9); } #controls .button.right-switch-button { @@ -72,23 +69,8 @@ } #controls .button.view-switcher:hover { - background-color: rgba(255, 255, 255, .9); - color: #111; - border: 1px solid rgba(240, 240, 240, .9); -} - -#controls .button.sorting.active-button { - background-color: rgba(255, 255, 255, .9); - color: #111; - border: 1px solid rgba(240, 240, 240, .9); - border-right-color: rgba(216, 216, 216, 0.9); -} - -#controls .button.sorting.active-button:hover { - background-color: rgba(255, 255, 255, .9); color: #111; border: 1px solid rgba(240, 240, 240, .9); - border-right-color: rgba(216, 216, 216, 0.9); } /* Original Flip CSS by David Walsh @@ -132,7 +114,7 @@ http://davidwalsh.name/css-flip*/ } #controls .button.sorting .front, -#controls .button.sorting.active-button.hover .back { +#controls .button.sorting.active.hover .back { z-index: 2; -webkit-transform: rotateX(0deg); @@ -152,12 +134,11 @@ http://davidwalsh.name/css-flip*/ position: absolute; width: 24px; height: 24px; - background-size: 24px 24px; margin-left: -4px; - margin-top: -3px; + margin-top: -5px; } -#controls .button.sorting.active-button.hover .front { +#controls .button.sorting.active.hover .front { -webkit-transform: rotateX(180deg); -moz-transform: rotateX(180deg); transform: rotateX(180deg); diff --git a/js/gallery.js b/js/gallery.js index a4a42b653..f37c3686f 100644 --- a/js/gallery.js +++ b/js/gallery.js @@ -187,7 +187,8 @@ } var button = $('#filelist-button'); - button.children('#button-loading').addClass('loading'); + button.children('img').addClass('hidden'); + button.children('#button-loading').removeClass('hidden').addClass('icon-loading-small'); OC.redirect(OC.generateUrl(subUrl, params)); }, diff --git a/js/gallerybutton.js b/js/gallerybutton.js index b795c0b79..491929379 100644 --- a/js/gallerybutton.js +++ b/js/gallerybutton.js @@ -71,12 +71,13 @@ $(document).ready(function () { // Button for opening files list as gallery view GalleryButton.button = $(''); GalleryButton.button.click(function () { - $(this).children('#button-loading').addClass('loading'); + $(this).children('span').addClass('hidden'); + $(this).children('#button-loading').removeClass('hidden').addClass('icon-loading-small'); window.location.href = GalleryButton.url; }); diff --git a/js/galleryview.js b/js/galleryview.js index 511a217d0..a1d17c49a 100644 --- a/js/galleryview.js +++ b/js/galleryview.js @@ -511,7 +511,7 @@ _setSortButton: function (sortType, sortOrder, active) { var button = $('#sort-' + sortType + '-button'); // Removing all the classes which control the image in the button - button.removeClass('active-button'); + button.removeClass('active'); button.find('img').removeClass('front'); button.find('img').removeClass('back'); @@ -527,7 +527,7 @@ // The active button needs a hover action for the flip effect if (active) { - button.addClass('active-button'); + button.addClass('active'); if (button.is(":hover")) { button.removeClass('hover'); } diff --git a/templates/part.content.php b/templates/part.content.php index 58bda6384..82105ef77 100644 --- a/templates/part.content.php +++ b/templates/part.content.php @@ -95,7 +95,7 @@