-
Notifications
You must be signed in to change notification settings - Fork 419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Card Fan as a New Base Card #1194
Conversation
I've also added a fix for Issue #1188 |
Maybe a 4th remark, clicking on the button icon should toggle the fan on/off |
hi @wokkeltje13 - really appreciate you're feedback on this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Line 97 still contains the old var name in the exemple
Fixed oscillating button by adding extra var
and by changing the code to
1 issue still open, the button does not toggle color according to oscillating state |
var temp = Math.round(entity.attributes[variables.ulm_card_fan_temp_attribute]); | ||
let temp_str = ' • ' + (temp ? temp : '0') + '°C'; | ||
} else { | ||
let temp_str = '' | ||
} | ||
if (variables.ulm_card_fan_slider_hum_attribute != False) { | ||
if (variables.ulm_card_fan_slider_hum_attribute != false) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These should probably be null or empty checks. The attributes are strings
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have fixed this - however moving forwards I am personally focussing on the new card_fan and leaving the saxel fan behind.
@@ -78,13 +78,13 @@ custom_card_saxel_fan_common: | |||
label: |- | |||
[[[ | |||
if (entity.state != 'unavailable') { | |||
if (variables.ulm_card_fan_slider_temp_attribute != False) { | |||
if (variables.ulm_card_fan_slider_temp_attribute != false) { | |||
var temp = Math.round(entity.attributes[variables.ulm_card_fan_temp_attribute]); | |||
let temp_str = ' • ' + (temp ? temp : '0') + '°C'; | |||
} else { | |||
let temp_str = '' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also this and hum_str should be defined outside the if scope
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have fixed this - however moving forwards I am personally focussing on the new card_fan and leaving the saxel fan behind.
@wokkeltje13 > 1 issue still open, the button does not toggle color according to oscillating state I have copied across the code from the old Saxel Fan for this button color, won't be able to test for a few days now but feel free to test yourself if you can :) |
The oscillate button is working now, but the color is still not changing when toggle. |
I removed a part of the code and switched te colors and it seems to be working now. The last part of card_fan.yaml I use now is:
|
Thanks @wokkeltje13 - saved me some time! Looks like I left in some code from the light card that was taking over... In general, I'm still not too pleased with how un-adaptable this button is (both in services and color), but I can continue to work on it over time... for now we have a good baseline card to go off at least. |
tnx, seems to be working as expected |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can approve the new fan card and the changes to the cover card. No comment on the saxel card that is EOL with the new fan card
@benbur98 I have updated the color logic to be more inline with the example pictures |
Fix Issue #1191
I have created a new card based largely from @saxel fan card. This has been completely re-based to follow the modern format from the Light Card. I feel this card is now ready to be a base card and not a custom-card.
I believe this should Close and Replace PR #134.