Files
frontend/src/html/index.html.template
Bram Kragten dda7de3301 Fix issues with develop and serve (#24602)
* fix issues with develop and serve

* fix get image data, use hassUrl

* save picture-upload

* Update bundje.cjs

* Prettier

* Fix profile picture in dev serve mode

* person badge too

---------

Co-authored-by: Wendelin <w@pe8.at>
2025-03-12 16:59:40 +01:00

119 lines
4.4 KiB
Plaintext

<!DOCTYPE html>
<html>
<head>
<title>Home Assistant</title>
<%= renderTemplate("_header.html.template") %>
<link rel="mask-icon" href="/static/icons/mask-icon.svg" color="#18bcf2" />
<link
rel="apple-touch-icon"
href="/static/icons/favicon-apple-180x180.png"
/>
<meta name="apple-itunes-app" content="app-id=1099568401" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="default">
<meta name="apple-mobile-web-app-title" content="Home Assistant">
<meta name="msapplication-config" content="/static/icons/browserconfig.xml" />
<meta name="mobile-web-app-capable" content="yes" />
<meta name="application-name" content="Home Assistant">
<meta name="referrer" content="same-origin" />
<meta name="theme-color" content="{{ theme_color }}" />
<meta name="color-scheme" content="dark light" />
<%= renderTemplate("_style_base.html.template") %>
<style>
html {
background-color: var(--primary-background-color, #fafafa);
color: var(--primary-text-color, #212121);
height: 100vh;
}
@media (prefers-color-scheme: dark) {
html {
background-color: var(--primary-background-color, #111111);
color: var(--primary-text-color, #e1e1e1);
}
}
#ha-launch-screen {
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
#ha-launch-screen svg {
width: 112px;
flex-shrink: 0;
}
#ha-launch-screen .ha-launch-screen-spacer-top {
flex: 1;
margin-top: calc( 2 * max(env(safe-area-inset-bottom), 48px) + 46px );
padding-top: 48px;
}
#ha-launch-screen .ha-launch-screen-spacer-bottom {
flex: 1;
padding-top: 48px;
}
.ohf-logo {
margin: max(env(safe-area-inset-bottom), 48px) 0;
display: flex;
flex-direction: column;
align-items: center;
opacity: .66;
}
@media (prefers-color-scheme: dark) {
.ohf-logo {
filter: invert(1);
}
}
</style>
</head>
<body>
<div id="ha-launch-screen">
<div class="ha-launch-screen-spacer-top"></div>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240">
<path fill="#18BCF2" d="M240 224.762a15 15 0 0 1-15 15H15a15 15 0 0 1-15-15v-90c0-8.25 4.77-19.769 10.61-25.609l98.78-98.7805c5.83-5.83 15.38-5.83 21.21 0l98.79 98.7895c5.83 5.83 10.61 17.36 10.61 25.61v90-.01Z"/>
<path fill="#F2F4F9" d="m107.27 239.762-40.63-40.63c-2.09.72-4.32 1.13-6.64 1.13-11.3 0-20.5-9.2-20.5-20.5s9.2-20.5 20.5-20.5 20.5 9.2 20.5 20.5c0 2.33-.41 4.56-1.13 6.65l31.63 31.63v-115.88c-6.8-3.3395-11.5-10.3195-11.5-18.3895 0-11.3 9.2-20.5 20.5-20.5s20.5 9.2 20.5 20.5c0 8.07-4.7 15.05-11.5 18.3895v81.27l31.46-31.46c-.62-1.96-.96-4.04-.96-6.2 0-11.3 9.2-20.5 20.5-20.5s20.5 9.2 20.5 20.5-9.2 20.5-20.5 20.5c-2.5 0-4.88-.47-7.09-1.29L129 208.892v30.88z"/>
</svg>
<div id="ha-launch-screen-info-box" class="ha-launch-screen-spacer-bottom"></div>
<div class="ohf-logo">
<img src="/static/images/ohf-badge.svg" alt="Home Assistant is a project by the Open Home Foundation" height="46">
</div>
</div>
<home-assistant></home-assistant>
<%= renderTemplate("_js_base.html.template") %>
<%= renderTemplate("_preload_roboto.html.template") %>
<script crossorigin="use-credentials">
if (isModern) {
<% for (const entry of latestEntryJS) { %>
import("<%= entry %>");
<% } %>
window.customPanelJS = "<%= latestCustomPanelJS %>";
window.latestJS = true;
}
</script>
<% if (obj.hassUrl === "") { %>
<script>
{%- for extra_module in extra_modules -%}
import("{{ extra_module }}");
{%- endfor -%}
</script>
<% } %>
<script>
if (!window.latestJS) {
window.customPanelJS = "<%= es5CustomPanelJS %>";
<% for (const entry of es5EntryJS) { %>
_ls("<%= entry %>", true);
<% } %>
}
</script>
<% if (obj.hassUrl === "") { %>
<script>
if (!window.latestJS) {
{%- for extra_script in extra_js_es5 -%}
_ls("{{ extra_script }}");
{%- endfor -%}
}
</script>
<% } %>
</body>
</html>