mirror of
https://github.com/home-assistant/core.git
synced 2025-04-23 16:57:53 +00:00
Frontend: show message if no states
This commit is contained in:
parent
5f0f06b22d
commit
dd38621352
@ -1,2 +1,2 @@
|
||||
""" DO NOT MODIFY. Auto-generated by build_frontend script """
|
||||
VERSION = "a82c6e4bf6b91042a6e891d46464275d"
|
||||
VERSION = "951c0a4e0adb70ec1f0f7e4c76955ed9"
|
||||
|
File diff suppressed because one or more lines are too long
@ -6,7 +6,6 @@
|
||||
<template>
|
||||
<style>
|
||||
:host {
|
||||
background-color: #fff;
|
||||
border-radius: 2px;
|
||||
box-shadow: rgba(0, 0, 0, 0.098) 0px 2px 4px, rgba(0, 0, 0, 0.098) 0px 0px 3px;
|
||||
transition: all 0.30s ease-out;
|
||||
|
@ -33,6 +33,15 @@
|
||||
width: calc(25% - 42px);
|
||||
}
|
||||
}
|
||||
|
||||
.no-states-content {
|
||||
max-width: 500px;
|
||||
background-color: #fff;
|
||||
border-radius: 2px;
|
||||
box-shadow: rgba(0, 0, 0, 0.098) 0px 2px 4px, rgba(0, 0, 0, 0.098) 0px 0px 3px;
|
||||
padding: 16px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
</style>
|
||||
|
||||
<div horizontal layout wrap>
|
||||
@ -41,6 +50,12 @@
|
||||
<state-card class="state-card" stateObj={{state}} api={{api}}></state-card>
|
||||
</template>
|
||||
|
||||
<template if="{{states.length == 0}}">
|
||||
<div class='no-states-content'>
|
||||
<content></content>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
|
@ -108,7 +108,15 @@
|
||||
<state-cards
|
||||
api="{{api}}"
|
||||
filter="{{selectedFilter}}"
|
||||
class="content"></state-cards>
|
||||
class="content">
|
||||
<h3>Hi there!</h3>
|
||||
<p>
|
||||
It looks like we have nothing to show you right now. It could be that we have not yet discovered all your devices but it is more likely that you have not configured Home Assistant yet.
|
||||
</p>
|
||||
<p>
|
||||
Please see the <a href='https://home-assistant.io/getting-started/' target='_blank'>Getting Started</a> section on how to setup your devices.
|
||||
</p>
|
||||
</state-cards>
|
||||
|
||||
</core-header-panel>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user