Merge pull request #440 from wanhose/v7.0.1

7.0.1
This commit is contained in:
wanhose 2024-03-19 19:29:05 +01:00 committed by GitHub
commit d6d1dff869
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 9 additions and 11 deletions

View File

@ -1,7 +1,7 @@
{
"manifest_version": 3,
"name": "Cookie Dialog Monster",
"version": "7.0.0",
"version": "7.0.1",
"default_locale": "en",
"description": "__MSG_appDesc__",
"icons": {

View File

@ -106,17 +106,15 @@ function forceClean(element) {
*/
function forceElementStyles(mutations, observer) {
for (const mutation of mutations) {
if (mutation.type === 'attributes' && dataAttributeName === mutation.attributeName) {
const element = mutation.target;
const value = element.getAttribute(dataAttributeName);
const element = mutation.target;
const value = element.getAttribute(dataAttributeName);
if (value === null) {
observer.disconnect();
element.removeAttribute(dataAttributeName);
element.style.removeProperty('display');
} else {
element.style.setProperty('display', 'none', 'important');
}
if (value === null) {
observer.disconnect();
element.removeAttribute(dataAttributeName);
element.style.removeProperty('display');
} else {
element.style.setProperty('display', 'none', 'important');
}
}
}