Still trying to get my floorplan up and running again. I have reverted to the default files from the repo and I am getting the following error which continually repeats:
Uncaught ReferenceError: moment is not defined
URL: http://192.168.1.165:8123/local/custom_ui/floorplan/ha-floorplan.html
Line: 163, column: 36
Error: {}
In the past I have found fleeting reference to this issue from others but nothing has helped me. I have reverted to the repo files as I said and cleared the cache by SHIFT-F5 but still the problem. Help?!
// Store the time difference between the local web browser and the Home Assistant server
if (data.event && data.event.time_fired) {
let lastEventFiredTime = moment(data.event.time_fired).toDate();
this.timeDifference = moment().diff(moment(lastEventFiredTime), ‘milliseconds’);
}
I haven’t done exhaustive tests, but it seems to be much more reliable on Android. I haven’t found any configuration that keeps the Floorplan/Kiosk on Fire working properly.
Hi guys, is anyone else experiencing the ame problem with running floorplan in full screen since the button “<” got replaced with the hamburger button ON the top blue bar? I have set it up so when I load the Floorplan, the top blue bar hides away to make space to the floorplan then I used to click the “<” button to colapse the menu to the left , then with an F11 in Chrome have a nice full screen of my Floorplan. Now just having the hamburger button it is useless as when I load Floorplan the blue bar hides away with the button so I can no longer collapse the left menu… any thoughts on how to overcome this in Chrome? (Hass.io v 0.76.2 ) Thanks
Yup, I have the same problem. I couldn’t figure out a work around, so I rolled back to an earlier rev that still had the “<“ button. I’d be very interested in any other ideas for dealing with this.
Yeah, I had the same issue with my wall mounted tablet.
I simply call the floorplan directly via http://ha_ip_adress:port/floorplan
to get rid of the hamburger menu
Since the new authentication module my floorplan needs username and password everytime I reboot my display. Anyone got it working with chrome kiosk auto logging in? What am I missing?
I was having issues with floorplan. I kept getting a blank screen, so I’ve updated to the latest floorplan (version 1.0.13) and HA (version 0.77.3). This got floorplan to show up again.
However, I now have the issue where I constantly get the ‘more info’ dialog when I click on a room / light. I didn’t get this before.
I’m using floorplan as a custom panel. I know using ‘input_text’ fixes this, but how do I do this when using floorplan as a custom panel? This is basically my floorplan configuration:
Im having several issues which have stumped me. I believe they are fairly newb issues and should be simple to solve so hoping to get some help here. Ill post my issues first and then my code below and also voice my appreciation now for any help you guys provide! Thank you!!!
edit: trying to get it to format properly so you guys arent disgusted with me
Using examples from the floorplan GitHub i have the weather icon and temperature to be posted on the floorpan.
1-A. The icons are svg, but appear different sizes in different browsers and are usually too small to be effective.
1-B. The temperature text is not displaying. The background changes appropriately, and hover shows the temperature and i can click to view the sensor, but other than that the area is blank. Ill attempt to add a screenshot.
I would like to show the moon phase icon and pihole sensor and weather card as well, but none are appearing. Again hover shows them and i can click on them to view details, same as issue 1, but no visual.
Code and screenshots:
floorpan.yaml
name: Floorplan
image: /local/custom_ui/floorplan/floorplan.svg
stylesheet: /local/custom_ui/floorplan/floorplan.css
# warnings:
# These options are optional
# warnings: # enable warnings (to find out why things might ot be working correctly)
# pan_zoom: # enable experimental panning / zooming
# hide_app_toolbar: # hide the application toolbar (when used as a custom panel)
# date_format: DD-MMM-YYYY # Date format to use in hover-over text
last_motion_entity: sensor.template_last_motion
last_motion_class: last-motion
groups:
- name: Sensors
entities:
- sensor.dark_sky_temperature
text_template: '${entity.state ? entity.state : "unknown"}'
# An example of rounding up a number, i.e. a temperature of 90.1 becomes 91
text_template: '${entity.state ? entity.state : "unknown"}¡F'
class_template: '
var temp = parseFloat(entity.state.replace("¡", ""));
if (temp < 33)
return "temp-very-low";
else if (temp > 32 && temp < 69)
return "temp-low";
else if (temp > 68 && temp < 90)
return "temp-nice";
else if (temp > 89 && temp < 100)
return "temp-high";
else
return "temp-very-high";
'
- name: Fans
entities:
- fan.ge_14287_fan_control_switch_level
- fan.ge_14287_fan_control_switch_level_3
states:
- state: 'on'
class: 'fan-on'
- state: 'off'
class: 'fan-off'
action:
domain: homeassistant # This optional parameter allows you to use other services such as homeassistant.toggle like here.
service: toggle
- name: Lights
entities:
- switch.ge_14292_inwall_smart_toggle_switch_switch
- switch.ge_14292_inwall_smart_toggle_switch_switch_2
- switch.ge_14292_inwall_smart_toggle_switch_switch_3
- switch.ge_14292_inwall_smart_toggle_switch_switch_4
- switch.ge_14292_inwall_smart_toggle_switch_switch_5
- switch.ge_14292_inwall_smart_toggle_switch_switch_6
- switch.ge_14292_inwall_smart_toggle_switch_switch_7
- switch.ge_14292_inwall_smart_toggle_switch_switch_8
- switch.ge_14292_inwall_smart_toggle_switch_switch_9
- switch.hank_hkzwso03_smart_plug_switch_3
- switch.hank_hkzwso03_smart_plug_switch_2
- light.ge_14295_inwall_smart_toggle_dimmer_level
states:
- state: 'on'
class: 'light-on'
- state: 'off'
class: 'light-off'
action:
domain: homeassistant # This optional parameter allows you to use other services such as homeassistant.toggle like here.
service: toggle
- name: Switches
entities:
- switch.doorbell
states:
- state: 'on'
class: 'doorbell-on'
- state: 'off'
class: 'doorbell-off'
- name: Alarm Panel
entities:
- alarm_control_panel.alarm
states:
- state: 'armed_away'
class: 'alarm-armed'
- state: 'armed_home'
class: 'alarm-armed'
- state: 'disarmed'
class: 'alarm-disarmed'
- name: Binary sensors
entities:
- binary_sensor.front_hallway
- binary_sensor.kitchen
- binary_sensor.master_bedroom
- binary_sensor.theatre_room
states:
- state: 'off'
class: 'info-background'
- state: 'on'
class: 'warning-background'
state_transitions:
- name: On to off
from_state: 'on'
to_state: 'off'
duration: 10
- name: Cameras
entities:
- camera.hallway
- camera.driveway
- camera.front_door
- camera.backyard
states:
- state: 'idle'
class: 'camera-idle'
- name: TV
entities:
- media_player.samsung_living_room
states:
- state: 'on'
class: 'tv-on'
- state: 'off'
class: 'tv-off'
- name: PiHole
entities:
- sensor.pihole_ads_blocked_today
- name: Moon
entities:
- sensor.moon
- name: Dark Sky Weather
entities:
- weather.dark_sky
- name: Dark Sky Sensors
entities:
- sensor.dark_sky_icon
image_template: '
var imageName = "";
switch (entity.state) {
case "clear-day":
imageName = "day";
break;
case "clear-night":
imageName = "night";
break;
case "partly-cloudy-day":
imageName = "cloudy-day-1";
break;
case "partly-cloudy-night":
imageName = "cloudy-night-1";
break;
case "cloudy":
imageName = "cloudy";
break;
case "rain":
imageName = "rainy-1";
break;
case "snow":
imageName = "snowy-1";
break;
}
return "/local/icons/weather_icons/animated/" + imageName + ".svg";
'
- name: people
entities:
- device_tracker.girl
- device_tracker.guy
text_template: '${entity.state ? entity.state : "unknown"}'
class_template: '
if (entity.state == "home")
return "clear-foreground";
else
return "graying-foreground";
'
thank you ; this is great idea
i have a question
i want buy raspberry with a screen ; is it possible to show the floor plan only in the screen and control lights ON/OFF ?
I followed all the instructions to put a second floorplan on the side panel, but it only shows the main floorplan, the second one with the modified html file didn’t work, although it works if I set it as a custom card.
The only difference I see is the next text:
<script>
Polymer({
is: 'ha-panel-groundfloor',
This is how it appears on your repo:
<script>
class HaPanelFloorplan extends Polymer.Element {
static get is() { return 'ha-panel-floorcontrol'; }