+
+ on-iron-select='viewSelected' scrollable=''>
[[locationName]]
@@ -49,22 +79,11 @@
-
-
-
-
-
-
+
diff --git a/src/layouts/partial-cards.js b/src/layouts/partial-cards.js
index 3d4d0a093a..4767938283 100644
--- a/src/layouts/partial-cards.js
+++ b/src/layouts/partial-cards.js
@@ -136,14 +136,31 @@ export default new Polymer({
voiceActions.listen();
},
+ headerScrollAdjust(ev) {
+ if (!this.hasViews) return;
+ Polymer.Base.transform(`translateY(-${ev.detail.y}px)`, this.$.menu);
+ },
+
+ computeHeaderHeight(hasViews) {
+ return hasViews ? 128 : 64;
+ },
+
+ computeCondensedHeaderHeight(hasViews) {
+ return hasViews ? 48 : 64;
+ },
+
computeMenuButtonClass(narrow, showMenu) {
- return !narrow && showMenu ? 'invisible' : '';
+ return !narrow && showMenu ? 'menu-icon invisible' : 'menu-icon';
},
computeRefreshButtonClass(isFetching) {
return isFetching ? 'ha-spin' : '';
},
+ computeTitle(hasViews, locationName) {
+ return hasViews ? 'Home Assistant' : locationName;
+ },
+
computeShowIntroduction(currentView, introductionLoaded, states) {
return currentView === '' && (introductionLoaded || states.size === 0);
},