Comments (5)
Goedenavond Tom,
Tnx for getting back so swiftly.
OK, you could successfully safe the lovelace card, I can't. This has nothing to do with the compass card, obviously another issue somewhere in HA.
I got insecure reading
https://github.com/tomvanswam/compass-card#style-band-object
but yeah, you just proven hex color codes are working. Maybe add a he color in the an example to prevent future questions like this?
Closing this PR since there's nothing to improve in the compass card. Again, tnx for all the efforts, very much appreciated.
from compass-card.
Hi andildge, thanks I did, I hope you did as well.
Your config only changes the icon color. And in my test env with this config:
type: custom:compass-card
indicator_sensors:
- sensor: input_number.wind
value_sensors:
- sensor: input_number.wind
language: en
header:
title:
value: Wind
icon:
color: '#d4d4d4'
dynamic_style:
sensor: input_number.wind
bands:
- from_value: 1
color: '#cdfffe'
- from_value: 2
color: '#99ffcd'
- from_value: 3
color: '#99ff99'
- from_value: 4
color: '#98ff66'
- from_value: 5
color: '#9afe00'
- from_value: 6
color: '#ccff00'
- from_value: 7
color: '#ffff01'
- from_value: 8
color: '#ffcc00'
- from_value: 9
color: '#fe9900'
- from_value: 10'
color: '#ff6600'
- from_value: 11
color: '#ff3300'
- from_value: 12
color: '#fe0000'
I do see a different icon color when changing the sensor value.
So I'm guessing something else is off. Might be your icon is invalid for the sensor. Or your sensor is not numerical perhaps, but string based.
If you want to have something else change color, you need to add the dynamic_styling to another key in the yaml.
You could post the output on the developer console in your browser when you add the debug: true
config option. Maybe I can find something in there.
from compass-card.
Well if your yaml is the complete one, it is missing the value and indicator node, might that be the reason you can't save it?
from compass-card.
nah, it was wrong code in the lovelace card, my bad. Here the working example
type: custom:compass-card
language: de
tap_action:
action: more-info
entity: sensor.weatherbit_wind_speed_km_h
header:
title:
value: Wind
icon:
color: '#777777'
dynamic_style:
sensor: sensor.weatherbit_beaufort
bands:
- from_value: 1
color: '#cdfffe'
- from_value: 2
color: '#99ffcd'
- from_value: 3
color: '#99ff99'
- from_value: 4
color: '#98ff66'
- from_value: 5
color: '#9afe00'
- from_value: 6
color: '#ccff00'
- from_value: 7
color: '#ffff01'
- from_value: 8
color: '#ffcc00'
- from_value: 9
color: '#fe9900'
- from_value: 10'
color: '#ff6600'
- from_value: 11
color: '#ff3300'
- from_value: 12
color: '#fe0000'
value_sensors:
- sensor: sensor.weatherbit_wind_speed_km_h
decimals: 0
indicator_sensors:
- sensor: sensor.weatherbit_wind_direction
indicator:
type: arrow_inward
dynamic_style:
sensor: sensor.weatherbit_wind_direction
show: true
compass:
north:
color: '#777777'
dynamic_style:
sensor: sensor.weatherbit_beaufort
bands:
- from_value: 1
color: '#cdfffe'
- from_value: 2
color: '#99ffcd'
- from_value: 3
color: '#99ff99'
- from_value: 4
color: '#98ff66'
- from_value: 5
color: '#9afe00'
- from_value: 6
color: '#ccff00'
- from_value: 7
color: '#ffff01'
- from_value: 8
color: '#ffcc00'
- from_value: 9
color: '#fe9900'
- from_value: 10'
color: '#ff6600'
- from_value: 11
color: '#ff3300'
- from_value: 12
color: '#fe0000'
circle:
color: '#777777'
dynamic_style:
sensor: sensor.weatherbit_beaufort
bands:
- from_value: 1
color: '#cdfffe'
- from_value: 2
color: '#99ffcd'
- from_value: 3
color: '#99ff99'
- from_value: 4
color: '#98ff66'
- from_value: 5
color: '#9afe00'
- from_value: 6
color: '#ccff00'
- from_value: 7
color: '#ffff01'
- from_value: 8
color: '#ffcc00'
- from_value: 9
color: '#fe9900'
- from_value: 10'
color: '#ff6600'
- from_value: 11
color: '#ff3300'
- from_value: 12
color: '#fe0000'
from compass-card.
No problem, happy it works ;-)
from compass-card.
Related Issues (20)
- Sensor Value outside of circle HOT 3
- Provide tap_action for every sensor in value_sensors HOT 2
- Change color HOT 2
- Height of Card customisation. HOT 1
- GUI config in HA 2022.3+ pulldown menu's not working as intended HOT 2
- Suppress direction HOT 3
- GUI editor not working HOT 1
- Rotate only the background image HOT 1
- Change sun aspect after sunset HOT 2
- Wind directions in other languages
- Are these possible? HOT 1
- Are these possible? HOT 1
- Indicator object icon selectable HOT 4
- Templating HOT 1
- Compass abbreviation not hiding and not colored HOT 4
- Second compass ring HOT 5
- Windspeed 0 shows invalid HOT 9
- Two enhancement suggestions
- tap_action HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from compass-card.