Ticket #25271 - Active tab Menu

Is there a way to make the tabs of the menu being bold if active? for example if menu has three categories to have in bold the one in which you currently are.

Comments

Fred 02 Feb 2024, 14:27

Hi, Prisma Ingenieria y Diseno S.L..
There is no such option.
Try to add this script into Theme Settings → Customer JS

document.addEventListener('DOMContentLoaded', function () {
    const currentPageUrl = window.location.href;
    const menuLinks = document.querySelectorAll('#top-menu > li > a');
    menuLinks.forEach(function (link) {
        const linkUrl = link.getAttribute('href');
        if (currentPageUrl.includes(linkUrl)) {
            link.querySelector('span').classList.add('font-weight-bold');
        }
    });
});
Prisma Ingenieria y Diseno S.L. 02 Feb 2024, 14:42

That worked as charm, thanks! Also, the images in the category pages appear blurred, I`ll attach an image to ilustrate. We are using the body img {image-rendering: auto !important;} instruction but doesnt seems to affect this type of page in particular. Could it be the wrong image size in settings or something tied to the category page in particular?

Attachments:

Fred 03 Feb 2024, 12:02

Can you please give me a link to a page where I can see the issue?
Please fill out all necessary fields in your profile https://support.promokit.eu/myprofile to access to your Back-office to let me check your configuration

Prisma Ingenieria y Diseno S.L. 05 Feb 2024, 09:21

Hi, info is filled and the link is the following: https://neveraweb.com/benditatinta/4-personaliza It happens in every category page. Thanks!

Fred 05 Feb 2024, 10:32

Ok, I see now.
Go to Theme Settings → Product Miniature and change the image type https://take.ms/lttzg

Prisma Ingenieria y Diseno S.L. 05 Feb 2024, 15:45

okay, thanks, everything solved!!

Fred 05 Feb 2024, 16:43

You are welcome!