Development

This commit is contained in:
Matthew Grotke 2026-05-23 17:02:41 -04:00
parent d004026285
commit bccb260ed0
2 changed files with 8 additions and 3 deletions

View file

@ -905,8 +905,9 @@ def _render_item(item, tokens, inherited_req=None):
return f'<div class="info-bar info-bar-{e(variant)}">{text}</div>'
if t == 'pre_block':
text = e(apply_tokens(item.get('text', ''), tokens))
return f'<pre class="pre-block">{text}</pre>'
text = e(apply_tokens(item.get('text', ''), tokens))
extra = ' data-scroll-bottom' if item.get('scroll_to_bottom') else ''
return f'<pre class="pre-block"{extra}>{text}</pre>'
if t == 'credential_fields':
psel = e(item.get('provider_select', 'provider'))
@ -2485,6 +2486,9 @@ function startApplyPoller(uuid, bar, mine) {
};
macInput._triggerValidate();
})();
document.querySelectorAll('.pre-block[data-scroll-bottom]').forEach(function(el) {
el.scrollTop = el.scrollHeight;
});
"""

View file

@ -458,7 +458,8 @@
"items": [
{
"type": "pre_block",
"text": "%DDNS_LOG_TAIL%"
"text": "%DDNS_LOG_TAIL%",
"scroll_to_bottom": true
},
{
"type": "raw_html",