Revert CTA always-rebuild, keep combined text detection for RMD quality
The always-rebuild approach caused the CTA to disappear when the observer fired a second time. Reverted to only rebuild on FRN change. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
31a84b95e3
commit
c0adeec663
1 changed files with 2 additions and 3 deletions
|
|
@ -409,12 +409,11 @@ Send reset link
|
|||
// Remediation CTA — rebuild if FRN changed (user searched new company)
|
||||
var currentFrn = (document.getElementById("entity-frn").textContent || "").replace(/\D/g, "");
|
||||
var existingCta = document.getElementById("pw-remediation-cta");
|
||||
if (existingCta) {
|
||||
// Remove CTA if FRN changed or if we need to rebuild
|
||||
if (existingCta && existingCta.dataset.frn && existingCta.dataset.frn !== currentFrn) {
|
||||
existingCta.remove();
|
||||
existingCta = null;
|
||||
}
|
||||
{
|
||||
if (!existingCta) {
|
||||
var actionCards = checks.querySelectorAll(":scope > .bg-red-50, :scope > .bg-amber-50");
|
||||
if (actionCards.length > 0) {
|
||||
var services = [];
|
||||
|
|
|
|||
Loading…
Reference in a new issue