Closed ivdimitro closed 2 years ago
I guess it should be enough to change the cap of maximum chars for this page. More than 4 chars won't fit there anyways.
I changed it to 4 chars and released the change with v3.0.5
Hi, the fix will not work in all cases. I have a "navigation" entity in the grid and the number is shown via sensor status:
- entity: navigate.cardThermo_bathRad
status: sensor.bath_rad_air_temperature
name: bathroom
I saw in the code that you are reducing the number of displayed chars only in the case when the sensor is the grid item directly:
if cardType == "cardGrid" and entityType == "sensor":
I think you should add "or entityType == "navigation"
this change should help, can you give this a try
https://github.com/joBr99/nspanel-lovelace-ui/commit/2b252d4327ed7d197341e5b40f072d261ae6026a
Hi, I tested the change and it fixed the issue with navigate items. I would prefer the keep the number of chars to 4. Otherwise if the limit is 3 and you have only one digit after the dot it removes it and we lose precision.
Even if you have a number with 4 digits it displays correctly.
The position of the decimal dot doesn't make difference.
Wdym? the limit should be 4 chars, never changed it to 3 (only if the last char is an dot)
At least in patch you included above the char limit is 3. Maybe a typo.
I guess you are right, decreased the limit from 4 to 3 on you initial message, wasn't aware that this was only an issue on navigate items, try to download main in HACS and restart AppDeamon, should be fixed.
Now it is OK. Thanks.
Describe the solution you'd like I have some temperature sensors which display temperature with two digits after the decimal point. When added on a grid card the last digit is not fully rendered in the grid slot. (see the attachment) I would like to be possible to define the accuracy of the sensor or automatically round the number.
Additional context I know it is possible to create new sensor which copies the values from my sensors and reduce the accuracy in HA but this seems like clunkier solution.
Panel / Firmware Version 3.0 EU