The function isSafari() recognizes the Androids’ companion app as Safari Browser and the correction variable makes a mess then. The two functions isSafari() and isIOS() need to be updated. I will take a deeper look inside the code when I have more time…
Hello,
I’m facing the same problem right now
Have you _ or someone who is still reading it _ found a solution to the problem/error - whatever - and maybe you want to share the solution with me?
Greetings Juergen
I need your help: I want to change fill color of a text in layout:/states:/id: X/styles:/fill:
It works just fine if I provide a color name like green or red, but I want to make it conditional, depending of attr_state form a different entity. I’ve tried many different approaches but don’t know how to do it.
I solved this problem for my needs now. Mobile App is working now also.
The trick is to overwrite the Safari-Browser style via CSS, because the Mobile- / Companion-App is recognized as Safari (no clue why), so the code example above (from flex-horseshoe-card.js) is used.
This is the card mod style you have to set:
card_mod:
style: |
ha-icon {
--ha-icon-display: content;
}
foreignObject {
x: 76px; // Adjust this for your needs
y: 113px; // Adjust this for your needs
width: 48px; // Adjust this for your needs
height: 48px; // Adjust this for your needs
}
Since i started using Flexible Horseshoe component, i sometimes get “Custom element does not exist:flex-horseshoe-card” error on both mobile and desktop. As i see, whenever i get this error, most of you guys got the same error too at the same time. And it always comes back by its own after some time.
I myself suspect that the lines 21-26 on flex-horseshoe-card.js:
import {
LitElement,
html,
css,
svg
} from "https://unpkg.com/[email protected]/lit-element.js?module";
is using unpkg.com. And “unpkg.com” server is sometimes down and i suspect that this error occurs when the unpkg site is down. I am now testing:
from "https://cdn.jsdelivr.net/npm/[email protected]/lit-element.js?module";
as this seems a more reliable server. Will inform you guys about the outcome. Btw, i changed the code in flex-horseshoe-card. js but not in flex-horseshoe-card.gz. Do i need to change this zip file too?
EDIT: 1. Yes you should also change.gz file
2. jsdelivr instead of unpkg doesn’t work. Tried to use local litelement, that doesn’t work either.
It’s not unusual for custom elements to break when there is an update. It happens to my custom light entity card every time. There was a supervisor update yesterday and on the live call Frenk asked everyone to always update the cards as well. My Horseshoe card is working after the core update however without doing anything special though. Try unpacking the .js and reinstalling maybe?
Good morning
I want to embed a text data instead of a number in horseshoe card.
“sensor.mode_solaire” can take 2 text values: solar mode or EDF mode.
This is my configuration :
Does anyone know of a way to have two scales and use the color to show if it’s supplying or using?
So a red line starting at 0 when using power and a green line starting at zero showing the insertion of power.
I just tried and it’s fine with showing a text value in the card.
However, do not use the first entity. That one is used as the value to show the horseshoe line.
You can use it on the second entity without any problem.
Thank you for the reply.
You suggestions won’t do what I’m looking for.
I would like the horsehoe graph to change to different scales based on the value.
So one based on 0 to 15000, when I’m using energy from the grid (with the red color).
And one based on 0 to -15000, when I’m supplying energy to the grid (with the green color).