-
-
Notifications
You must be signed in to change notification settings - Fork 562
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
fix: exclude status checkboxes from being treated as iCheck elements #1910
Conversation
Signed-off-by: Lion Ralfs <[email protected]>
Signed-off-by: Adam Warner <[email protected]>
@jfb-pihole, as you were able to reproduce the issue that this PR fixes - can you please check that this fixes it? Thanks! |
Just to note, you wont be able to use
|
Hi. For this same bug, I use Approvers... please do consider merging this PR as-is though. EIther way, this modification fixes the #1849 problem. |
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.
I had a similar issue on iPadOS 15.1 both on Safari and Chrome. The would not display the relevant tables to all. This PR fixed the issue.
This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there: https://discourse.pi-hole.net/t/list-of-configured-groups-only-shows-a-green-square/51178/2 |
This pull request has been mentioned on Pi-hole Userspace. There might be relevant details there: https://discourse.pi-hole.net/t/pi-hole-ftl-v5-12-web-v5-9-and-core-v5-7-released/51795/1 |
By submitting this pull request, I confirm the following:
git rebase
)git commit --signoff
)What does this PR aim to accomplish?:
Fixes #1849.
In Safari, the toggle buttons under Group Management > Groups are broken.
This is due to the following phenomenon: The data table is rendered before these lines in footer.js:
https://github.com/pi-hole/AdminLTE/blob/50f43bde73d25211ac2c81e9092be67512611d2a/scripts/pi-hole/js/footer.js#L140-L143
This obviously leads to all classes being removed, along with their styling.
The more interesting question is: why does every other browser render the data table after these lines in footer.js? I honestly don't have a good answer.
Other pages don't cause this issue in Safari due to how the data fetching is implemented (an explicit
initTable
callback function which gets pushed onto the call stack). I considered using the same implementation here, butin my opinion this wouldn't avoid the issue from occurring, because it is still somewhat of a race condition.
How does this PR accomplish the above?:
To avoid race conditions in general, I added an exception to the initialization of iCheck elements by using a
:not
selector for all elements that have anid
attribute starting with "status_".What documentation changes (if any) are needed to support this PR?:
none