fix: set tab title to container/app name
Updates the HTML page title to display the app name instead of a generic 'Textual Web Terminal' title. Resolves TODO item #1.
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
- [ ] Set tab title to the container name
|
||||
- [ ] screenshots are still showing the tmux bar creeping up and slowly taking over the screenshot
|
||||
@@ -724,11 +724,12 @@ class LocalServer:
|
||||
route_key = RouteKey(generate().lower())
|
||||
|
||||
ws_url = self._get_ws_url_from_request(request, route_key)
|
||||
page_title = available_app.name if available_app else "Textual Web Terminal"
|
||||
|
||||
html_content = f"""<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Textual Web Terminal</title>
|
||||
<title>{page_title}</title>
|
||||
<link rel=\"stylesheet\" href=\"/static/css/xterm.css\">
|
||||
<link rel=\"stylesheet\" href=\"/static-webterm/monospace.css\">
|
||||
<script src=\"/static/js/textual.js\"></script>
|
||||
|
||||
@@ -494,6 +494,7 @@ class TestLocalServerMoreCoverage:
|
||||
assert "/static-webterm/monospace.css" in resp.text
|
||||
assert "data-session-websocket-url" in resp.text
|
||||
assert "data-font-size" in resp.text
|
||||
assert "<title>Known</title>" in resp.text
|
||||
|
||||
def test_rewrite_svg_fonts_removes_font_face_and_forces_stack(self):
|
||||
svg = (
|
||||
|
||||
Reference in New Issue
Block a user