feat: estendi badge match alle ricerche per tag su edit_ruleset

Le pagine edit_ruleset aperte da una ricerca per hosttag usano
title="Matches" invece di title^="This rule matches". Esteso il
selettore CSS per coprire entrambi i casi.

bump version to 2.7.1
This commit is contained in:
Luigi D'Acunto 2026-06-17 15:17:31 +02:00
parent 40878df517
commit 8093f2f1c8

View file

@ -1,7 +1,7 @@
// ==UserScript==
// @name Checkmk SwissKnife
// @namespace https://luigidacunto.com/
// @version 2.7.0
// @version 2.7.1
// @description Raccolta di miglioramenti all'interfaccia di Checkmk WATO. Ogni fix o enhancement viene aggiunto qui come feature indipendente.
// @author Luigi D'Acunto
// @homepageURL https://git.luigidacunto.com/tools/checkmk-swissknife
@ -638,7 +638,7 @@
function highlightRuleMatchStatus(doc) {
if (doc.body.dataset.cmkMatchHighlight === '1') return;
const matchImgs = doc.querySelectorAll('img.icon[title^="This rule matches"]');
const matchImgs = doc.querySelectorAll('img.icon[title^="This rule matches"], img.icon[title="Matches"]');
const noMatchImgs = doc.querySelectorAll('img.icon[title^="This rule does not match"]');
if (!matchImgs.length && !noMatchImgs.length) return;