luci-theme: html title: swap hostname <-> page title

hostname first to differentiate units from at-a-glance
browser tab view.

follow-up to 18d14980dd

Signed-off-by: Paul Donald <newtwen+github@gmail.com>
This commit is contained in:
Paul Donald
2026-02-09 22:13:56 +01:00
parent 5a7ee4322e
commit ce358ad411
4 changed files with 4 additions and 4 deletions

View File

@@ -18,7 +18,7 @@
<html lang="{{ dispatcher.lang }}" {{ darkpref ? `data-darkmode="${darkpref}"` : '' }}>
<head>
<meta charset="utf-8">
<title>{{ striptags(`${boardinfo.hostname ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} | LuCI</title>
<title>{{ striptags(`${boardinfo.hostname + ' | ' ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} LuCI</title>
{% if (!darkpref): %}
<script>
var mediaQuery = window.matchMedia('(prefers-color-scheme: dark)'),

View File

@@ -46,7 +46,7 @@
{% endif %}
<script src="{{ dispatcher.build_url('admin/translations', dispatcher.lang) }}"></script>
<script src="{{ resource }}/cbi.js"></script>
<title>{{ striptags(`${boardinfo.hostname ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} | LuCI</title>
<title>{{ striptags(`${boardinfo.hostname + ' | ' ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} LuCI</title>
{% if (css): %}
<style title="text/css">{{ css }}</style>
{% endif %}

View File

@@ -22,7 +22,7 @@
<link rel="icon" href="{{ media }}/logo.svg" sizes="any">
<script src="{{ dispatcher.build_url('admin/translations', dispatcher.lang) }}"></script>
<script src="{{ resource }}/cbi.js"></script>
<title>{{ striptags(`${boardinfo.hostname ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} | LuCI</title>
<title>{{ striptags(`${boardinfo.hostname + ' | ' ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} LuCI</title>
{% if (css): %}
<style title="text/css">{{ css }}</style>
{% endif %}

View File

@@ -28,7 +28,7 @@
<script src="{{ dispatcher.build_url('admin/translations', dispatcher.lang) }}"></script>
<script src="{{ resource }}/cbi.js"></script>
<title>{{ striptags(`${boardinfo.hostname ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} | LuCI</title>
<title>{{ striptags(`${boardinfo.hostname + ' | ' ?? '?'}${dispatched?.title ? `${_(dispatched.title)} | ` : ''}`) }} LuCI</title>
</head>
<body class="lang_{{ dispatcher.lang }}" data-page="{{ entityencode(join('-', ctx.request_path), true) }}">