Closed ildar170975 closed 1 year ago
Seems to be working for rows only:
Same here. After update restrictiuons are no longer working. The Lock is shown, but restrictions are ignored.
type: entities
entities:
- entity: switch.ladestation_switch
name: Ladestation
icon: mdi:usb
- entity: switch.fernseher
icon: hass:television
- card:
entity: switch.3d_drucker_switch
name: 3D-Drucker
icon: mdi:printer-3d-nozzle
duration: 10
state_color: true
restrictions:
confirm:
text: ' Sicher?'
type: custom:restriction-card
row: true
duration: 10
state_color: true
show_header_toggle: false
title: Wohnen
@criticallimit
Do not confirm.
The bug seems to be related only to row: false
case.
@ildar:
sorry, but here it is no longer working after the update. Even after removing and installing it´s not working. And so I posted it here under the topic-title "The updated version does not work"
Going back to 1.2.7 it´s working fine
@criticallimit Strange... Well, I will also downgrade to 1.2.7. May be someone will make a fix.
I can also confirm there's absolutely no restriction effect performed anymore after updating to https://github.com/iantrich/restriction-card/releases/tag/1.2.8.
HA 2022.12.9 so frontend might be a bit old. How can the minimal change in 1.2.8 have such a breaking change effect?
Downgrade, downgrade, downgrade.
The thing that I have seen is that z-index in the code was removed and just by setting that again to 1 fixes the problem for me.
@henkall
Where did you changed the z-index? In the "restriction-card.js"? I tried to add it, change it to 1 or 50. No changes. Even when I install 1.2.7 and remove z-index in restriction-card.js, the restrictions are working.
After any change of js-file you need to be sure that THIS code is used in a browser. Clear cache, delete gz. Since version is stuck in 1.2.6 (and nobody cares about changing it in js-file), no way to check if the changed plugin is loaded.
Yes, I know. Done all this without success
@henkall
Where did you changed the z-index? In the "restriction-card.js"? I tried to add it, change it to 1 or 50. No changes. Even when I install 1.2.7 and remove z-index in restriction-card.js, the restrictions are working.
I tested it just in the developer tool build in to chrome. (F12) There you can add it and remove z-index to #Overlay And that was how I found out that the z-index should be set to 1 for my setup to work. It also works fine with 50 but then it seems to overlap with other windows.
@criticallimit you need to modify the gz file which is the one that gets served to browsers, if you only modify the js file no changes get sent to the client, aka Modify JS file, delete GZ and recreate GZ from the JS file
I vote for fixing this in the source and providing a new version instead of fiddling around on an individual basis.
A (for me the only) workaround is to downgrade, sit and wait.
If someone can submit a PR, I'll get it merged in, but I don't have the capacity to work on this myself at the moment.
Same here.. it ignores the lock.. have a simple button card
Installed the latest 1.2.8 (although Code inspector says 1.2.6)
No "lock" button is displayed.