diff --git a/homeassistant/components/frontend/www_static/polymer/components/recent-states.html b/homeassistant/components/frontend/www_static/polymer/components/recent-states.html deleted file mode 100644 index 408c0448836dce024c1b6fd1a8a266cc25ab77e3..0000000000000000000000000000000000000000 --- a/homeassistant/components/frontend/www_static/polymer/components/recent-states.html +++ /dev/null @@ -1,50 +0,0 @@ -<link rel="import" href="../bower_components/polymer/polymer.html"> -<link rel="import" href="../bower_components/core-style/core-style.html"> - -<link rel="import" href="./loading-box.html"> -<link rel="import" href="relative-ha-datetime.html"> - -<polymer-element name="recent-states" attributes="stateObj"> - <template> - <core-style ref='ha-data-table'></core-style> - - <template if="{{recentStates === null}}"> - <loading-box text="Loading recent states"></loading-box> - </template> - - <template if="{{recentStates !== null}}"> - <div layout vertical> - <template repeat="{{recentStates as state}}"> - <div layout justified horizontal class='data-entry'> - <div> - {{state.state}} - </div> - <div class='data'> - <relative-ha-datetime datetime="{{stateObj.last_changed}}"> - </relative-ha-datetime> - </div> - </div> - </template> - - <template if="{{recentStates.length == 0}}"> - There are no recent states. - </template> - </div> - </template> - </template> - <script> - Polymer({ - recentStates: null, - - stateObjChanged: function() { - this.recentStates = null; - - window.hass.callApi( - 'GET', 'history/entity/' + this.stateObj.entityId + '/recent_states').then( - function(states) { - this.recentStates = states.slice(1); - }.bind(this)); - }, - }); - </script> -</polymer-element> diff --git a/homeassistant/components/frontend/www_static/polymer/dialogs/ha-dialog.html b/homeassistant/components/frontend/www_static/polymer/dialogs/ha-dialog.html deleted file mode 100644 index 2cf8de644f06322d727b8bad6a82e3be3ed79d97..0000000000000000000000000000000000000000 --- a/homeassistant/components/frontend/www_static/polymer/dialogs/ha-dialog.html +++ /dev/null @@ -1,18 +0,0 @@ -<link rel="import" href="../bower_components/polymer/polymer.html"> -<link rel="import" href="../bower_components/core-style/core-style.html"> -<link rel="import" href="../bower_components/paper-dialog/paper-dialog.html"> -<link rel="import" href="../bower_components/paper-dialog/paper-dialog-transition.html"> - -<polymer-element name="ha-dialog" extends="paper-dialog"> -<template> - <core-style ref='ha-dialog'></core-style> - <shadow></shadow> -</template> -<script> - Polymer({ - layered: true, - backdrop: true, - transition: 'core-transition-bottom', - }); -</script> -</polymer-element> diff --git a/homeassistant/components/frontend/www_static/polymer/layouts/home-assistant-main.html b/homeassistant/components/frontend/www_static/polymer/layouts/home-assistant-main.html index b5343052e1d1be4b4bc0bc3e9b5b8c948d72e675..11ecff37f8ab5961c313dfc5243989890fe18363 100644 --- a/homeassistant/components/frontend/www_static/polymer/layouts/home-assistant-main.html +++ b/homeassistant/components/frontend/www_static/polymer/layouts/home-assistant-main.html @@ -120,14 +120,12 @@ </paper-menu> </paper-header-panel> - <!-- - This is the main partial, never remove it from the DOM but hide it - to speed up when people click on states. - --> - <partial-states hidden$='[[hideStates]]' - main narrow='[[narrow]]' - filter='[[stateFilter]]'> - </partial-states> + <template is='dom-if' if='[[!hideStates]]'> + <partial-states + main narrow='[[narrow]]' + filter='[[stateFilter]]'> + </partial-states> + </template> <template is='dom-if' if='[[isSelectedLogbook]]'> <partial-logbook main narrow='[[narrow]]'></partial-logbook> diff --git a/homeassistant/components/frontend/www_static/polymer/resources/home-assistant-style.html b/homeassistant/components/frontend/www_static/polymer/resources/home-assistant-style.html index bf2d7280eb2c85ad151f6f3212e424bdc33f3800..473e3445d64ef62e3f14c22e6a6b07c531fee61e 100644 --- a/homeassistant/components/frontend/www_static/polymer/resources/home-assistant-style.html +++ b/homeassistant/components/frontend/www_static/polymer/resources/home-assistant-style.html @@ -44,77 +44,3 @@ animation: ha-spin 2s infinite linear; } </style> - -<core-style id="ha-dialog"> - :host { - font-family: RobotoDraft, 'Helvetica Neue', Helvetica, Arial; - - min-width: 350px; - max-width: 700px; - - /* First two are from core-transition-bottom */ - transition: - transform 0.2s ease-in-out, - opacity 0.2s ease-in, - top .3s, - left .3s !important; - } - - :host .sidebar { - margin-left: 30px; - } - - @media all and (max-width: 620px) { - :host.two-column { - margin: 0; - width: 100%; - max-height: calc(100% - 64px); - bottom: 0px; - left: 0px; - right: 0px; - } - - :host .sidebar { - display: none; - } - } - - @media all and (max-width: 464px) { - :host { - margin: 0; - width: 100%; - max-height: calc(100% - 64px); - bottom: 0px; - left: 0px; - right: 0px; - } - } - - html /deep/ .ha-form paper-input { - display: block; - } - - html /deep/ .ha-form paper-input:first-child { - padding-top: 0; - } -</core-style> - -<core-style id='ha-key-value-table'> - .data-entry { - margin-bottom: 8px; - } - - .data-entry:last-child { - margin-bottom: 0; - } - - .data-entry .key { - margin-right: 8px; - } - - .data-entry .value { - text-align: right; - word-break: break-all; - } -</core-style> -