mirror of
https://github.com/amiaopensource/ffmprovisr.git
synced 2024-11-06 13:37:24 +01:00
parent
62cf86c125
commit
3f42736f98
31
js/js.js
31
js/js.js
@ -1,3 +1,28 @@
|
||||
$(function () {
|
||||
$('[data-toggle="tooltip"]').tooltip()
|
||||
})
|
||||
$(document).ready(function() {
|
||||
|
||||
$(function () {
|
||||
$('[data-toggle="tooltip"]').tooltip()
|
||||
});
|
||||
|
||||
// open modal window if a hash is found in URL
|
||||
if(window.location.hash) {
|
||||
$(window.location.hash).modal('show');
|
||||
// add direct link to modal window
|
||||
$(".link").empty();
|
||||
$(".link").append("<small>Link to this command: "+window.location.href+"</small>");
|
||||
}
|
||||
|
||||
// add hash to URL when modal is opened
|
||||
$('span[data-toggle="modal"]').on("click", function(){
|
||||
window.location.hash = $(this).attr("data-target");
|
||||
// add direct link to modal window
|
||||
$(".link").empty();
|
||||
$(".link").append("<small>Link to this command: "+window.location.href+"</small>");
|
||||
});
|
||||
|
||||
// remove hash from URL when modal is closed
|
||||
$(document).on('hide.bs.modal', function (e) {
|
||||
history.pushState("", document.title, window.location.pathname);
|
||||
});
|
||||
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user