function ready(fn){
if(document.readyState!=="loading"){fn();}
else{document.addEventListener("DOMContentLoaded",fn,{once:true});}
}
ready(function(){
document.querySelectorAll('img[src*="Add-a-subheading"]').forEach(function(img){
if(!img.getAttribute("width")) img.setAttribute("width","744");
if(!img.getAttribute("height")) img.setAttribute("height","162");
if(!img.getAttribute("alt")) img.setAttribute("alt","Urban Home Guide");
});
document.querySelectorAll('a[href="https://urbanhomeguide.com/"],a[href="/"]').forEach(function(a){
if(a.querySelector('img') && !a.getAttribute("aria-label")){
a.setAttribute("aria-label","Urban Home Guide home");
}
});
document.querySelectorAll("a.pxl-post--link").forEach(function(a){
if(a.getAttribute("aria-label")) return;
var box=a.closest("article,.pxl-post,.pxl-grid-item,.item,.elementor-widget-container") || a.parentElement;
var t=box && box.querySelector(".pxl-item--title,.pxl-post--title,h2,h3,h4,.entry-title");
var label=t && t.textContent ? t.textContent.trim() : "";
a.setAttribute("aria-label", label ? "View " + label : "View details");
});
var social={"fa-facebook":"Facebook","fa-facebook-f":"Facebook","fa-twitter":"Twitter","fa-x-twitter":"X","fa-instagram":"Instagram","fa-linkedin":"LinkedIn","fa-pinterest":"Pinterest","fa-youtube":"YouTube"};
document.querySelectorAll("a").forEach(function(a){
var label=(a.getAttribute("aria-label")||a.getAttribute("title")||a.textContent||"").trim();
if(label) return;
if((a.getAttribute("href")||"")==="#"){
a.setAttribute("aria-label","Back to top");
return;
}
var img=a.querySelector("img");
if(img){
var alt=(img.getAttribute("alt")||"").trim();
a.setAttribute("aria-label", alt || labelFromFile(img.currentSrc || img.src || a.href));
return;
}
var icon=a.querySelector("i[class]");
if(!icon) return;
var cls=icon.className || "";
var matched=false;
Object.keys(social).some(function(k){
if(cls.indexOf(k)!==-1){a.setAttribute("aria-label",social[k]);matched=true;return true;}
return false;
});
if(!matched && cls.indexOf("arrow-up")!==-1){a.setAttribute("aria-label","Back to top");}
});
document.querySelectorAll("li.pxl-link__item").forEach(function(li){
var p=li.parentElement;
if(!p || /^(UL|OL|MENU)$/i.test(p.tagName)) return;
var ul=document.createElement("ul");
ul.className="pxl-link__wrap uhg-list-fix";
p.insertBefore(ul,li);
ul.appendChild(li);
});
});
})();
var vp=document.querySelector('meta[name="viewport"]');
if(vp){vp.setAttribute("content","width=device-width, initial-scale=1");}
var st=document.createElement("style");
st.textContent=".uhg-list-fix{list-style:none;margin:0;padding:0}";
document.head.appendChild(st);
function ready(fn){
if(document.readyState!=="loading"){fn();}
else{document.addEventListener("DOMContentLoaded",fn,{once:true});}
}
ready(function(){
document.querySelectorAll('img[src*="Add-a-subheading-11"]').forEach(function(img){
if(!img.getAttribute("width")) img.setAttribute("width","744");
if(!img.getAttribute("height")) img.setAttribute("height","162");
if(!img.getAttribute("alt")) img.setAttribute("alt","Urban Home Guide");
});
document.querySelectorAll('a[href="https://urbanhomeguide.com/"]').forEach(function(a){
if(a.querySelector('img[src*="Add-a-subheading"]') && !a.getAttribute("aria-label")){
a.setAttribute("aria-label","Urban Home Guide home");
}
});
document.querySelectorAll("a.pxl-post--link").forEach(function(a){
if(a.getAttribute("aria-label")) return;
var box=a.closest("article,.pxl-post,.pxl-grid-item,.item,.elementor-widget-container") || a.parentElement;
var t=box && box.querySelector(".pxl-item--title,.pxl-post--title,h2,h3,h4,.entry-title");
var label=t && t.textContent ? t.textContent.trim() : "";
a.setAttribute("aria-label", label ? "View " + label : "View details");
});
var social={"fa-facebook":"Facebook","fa-facebook-f":"Facebook","fa-twitter":"Twitter","fa-x-twitter":"X","fa-instagram":"Instagram","fa-linkedin":"LinkedIn","fa-pinterest":"Pinterest","fa-youtube":"YouTube"};
document.querySelectorAll("a").forEach(function(a){
var label=(a.getAttribute("aria-label")||a.getAttribute("title")||a.textContent||"").trim();
if(label) return;
var icon=a.querySelector("i[class*='fa-']");
if(!icon) return;
var cls=icon.className || "";
Object.keys(social).some(function(k){
if(cls.indexOf(k)!==-1){a.setAttribute("aria-label",social[k]);return true;}
return false;
});
});
document.querySelectorAll("li.pxl-link__item").forEach(function(li){
var p=li.parentElement;
if(!p || /^(UL|OL|MENU)$/i.test(p.tagName)) return;
var ul=document.createElement("ul");
ul.className="pxl-link__wrap uhg-list-fix";
p.insertBefore(ul,li);
ul.appendChild(li);
});
});
})();
Click outside to hide the comparison bar