mirror of
https://github.com/pretix/pretix.git
synced 2026-08-14 11:26:26 +00:00
Max height for timeline
This commit is contained in:
@@ -1,18 +1,20 @@
|
||||
/*global $,gettext*/
|
||||
/* global $,gettext */
|
||||
|
||||
$(function () {
|
||||
if ($("div[data-lazy-id]").length == 0) {
|
||||
return;
|
||||
}
|
||||
$.getJSON("widgets.json" + ($("select[name='subevent']").val() ? "?subevent=" + $("select[name='subevent']").val() : ""), function (data) {
|
||||
$.each(data.widgets, function (k, v) {
|
||||
$("[data-lazy-id=" + v.lazy + "]").removeClass("widget-lazy-loading");
|
||||
$("[data-lazy-id=" + v.lazy + "] .widget").html(v.content);
|
||||
});
|
||||
});
|
||||
});
|
||||
if ($('div[data-lazy-id]').length == 0) {
|
||||
return
|
||||
}
|
||||
$.getJSON('widgets.json' + ($('select[name=\'subevent\']').val() ? '?subevent=' + $('select[name=\'subevent\']').val() : ''), function (data) {
|
||||
$.each(data.widgets, function (k, v) {
|
||||
$('[data-lazy-id=' + v.lazy + ']').removeClass('widget-lazy-loading')
|
||||
$('[data-lazy-id=' + v.lazy + '] .widget').html(v.content)
|
||||
})
|
||||
})
|
||||
})
|
||||
$(function () {
|
||||
if ($("#logs_target").length == 0) {
|
||||
return;
|
||||
}
|
||||
});
|
||||
$('.timeline').each(function () {
|
||||
let $tl = $(this)
|
||||
let $first = $(this).find('.row:not(.text-muted)').first()
|
||||
$tl.scrollTop($tl.scrollTop() + Math.max($first.position().top - 50, 0))
|
||||
})
|
||||
})
|
||||
|
||||
@@ -727,6 +727,10 @@ h1 .label {
|
||||
}
|
||||
|
||||
.timeline {
|
||||
max-height: 200px;
|
||||
overflow-y: auto;
|
||||
position: relative;
|
||||
|
||||
.col-date {
|
||||
position: relative;
|
||||
min-height: 1px;
|
||||
|
||||
Reference in New Issue
Block a user