View | Details | Raw Unified | Return to bug 30136
Collapse All | Expand All

(-)a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss (+10 lines)
Lines 225-230 th { Link Here
225
    }
225
    }
226
}
226
}
227
227
228
#backtotop {
229
    display: inline-block;
230
    text-align: center;
231
    font-size: 120%;
232
    position: fixed;
233
    bottom: 40px;
234
    right: 40px;
235
    z-index: 1000;
236
}
237
228
#booleansearch {
238
#booleansearch {
229
    width: 80%;
239
    width: 80%;
230
}
240
}
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc (-14 lines)
Lines 213-232 Link Here
213
        return confirmDelete(MSG_DELETE_SEARCH_HISTORY);
213
        return confirmDelete(MSG_DELETE_SEARCH_HISTORY);
214
    });
214
    });
215
215
216
    $("body").append('<button id="backtotop" class="btn btn-primary"><i class="fa fa-arrow-up" aria-hidden="true"></i></button>');
217
    $("#backtotop").hide();
218
    $(window).scroll(function(){
219
        if ( $(window).scrollTop() < 300 ) {
220
            $("#backtotop").fadeOut();
221
        } else {
222
            $("#backtotop").fadeIn();
223
        }
224
    });
225
    $("#backtotop").click(function(e) {
226
        e.preventDefault();
227
        $("html,body").animate({scrollTop: 0}, "slow");
228
    });
229
230
</script>
216
</script>
231
217
232
[% IF Koha.Preference( 'opacbookbag' ) == 1 %]
218
[% IF Koha.Preference( 'opacbookbag' ) == 1 %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/js/global.js (-2 / +16 lines)
Lines 1-4 Link Here
1
/* global enquire readCookie updateBasket delCookie */
1
/* global enquire readCookie updateBasket delCookie __ */
2
(function( w ){
2
(function( w ){
3
    // if the class is already set, the font has already been loaded
3
    // if the class is already set, the font has already been loaded
4
    if( w.document.documentElement.className.indexOf( "fonts-loaded" ) > -1 ){
4
    if( w.document.documentElement.className.indexOf( "fonts-loaded" ) > -1 ){
Lines 231-234 $(document).ready(function(){ Link Here
231
    });
231
    });
232
232
233
    $('[data-toggle="tooltip"]').tooltip();
233
    $('[data-toggle="tooltip"]').tooltip();
234
235
    /* Scroll back to top button */
236
    $("body").append('<button id="backtotop" class="btn btn-primary" aria-label="' + __("Back to top") + '"><i class="fa fa-arrow-up" aria-hidden="true" title="' + __("Scroll to the top of the page") + '"></i></button>');
237
    $("#backtotop").hide();
238
    $(window).on("scroll", function(){
239
        if ( $(window).scrollTop() < 300 ) {
240
            $("#backtotop").fadeOut();
241
        } else {
242
            $("#backtotop").fadeIn();
243
        }
244
    });
245
    $("#backtotop").on("click", function(e) {
246
        e.preventDefault();
247
        $("html,body").animate({scrollTop: 0}, "slow");
248
    });
234
});
249
});
235
- 

Return to bug 30136