• Resolved curtismchale

    (@curtismchale)


    1. Go to the website https://www.santa-ana.org/
    2. Hit tab until you focus on the translate button
    3. Hit enter to expand the dropdown
    4. Use arrow keys to hover over another language
    5. Hit Enter or Space. Neither select a new language

    I’d expect that either the arrow keys, or some type of keyboard navigation would allow us to select a different language. I do note that pressing a letter key, say A, will take me to the first language with that letter but then a user has to guess what languages are available.

    The page I need help with: [log in to see the link]

Viewing 14 replies - 1 through 14 (of 14 total)
  • Plugin Author edo888

    (@edo888)

    Hi,

    I have checked with Google Chrome on Windows and it works fine for me. I use the Enter button, Space does nothing for me.

    The regular dropdown (<select>) is controlled by the OS and we do not have full control on how it behaves.

    Thanks! 🙂

    Thread Starter curtismchale

    (@curtismchale)

    It also works for me in Chrome on Linux. It does not work for me in Firefox for Linux or macOS. On macOS in Chrome I’m also unable to select a different language from the keyboard.

    The non-working instances I can get the language select to highlight, but then pressing enter does not bring up the available languages for me to choose from.

    What is your browser support policy.

    Plugin Author edo888

    (@edo888)

    Hi,

    Can you try to change wp-content/plugins/gtranslate/dropdown.js file and change:

    if(current_lang != default_language)
        load_tlib();
    else
        document.querySelectorAll(u_class).forEach(function(e){e.addEventListener('pointerenter',load_tlib)});

    to

    if(current_lang != default_language)
        load_tlib();
    else
        document.querySelectorAll(u_class).forEach(function(e){['pointerenter','focus'].forEach(function(evt){e.addEventListener(evt,load_tlib)})});

    Let me know to check once it is done.

    I think the issue is that the js library is not being lazy loaded when needed, this change will try to load it also on focus event.

    Usually for such cases we recommend using the paid version, which doesn’t depend on js libraries.

    Thanks! 🙂

    Thread Starter curtismchale

    (@curtismchale)

    That doesn’t appear to fix it. For reference my customer reported this to me using:

    Browser: Google chrome version 140.0.7339.186
    OS: Windows 11 version 24H2

    Plugin Author edo888

    (@edo888)

    Hi,

    I have checked and I do not see the change.

    Thanks!

    Thread Starter curtismchale

    (@curtismchale)

    We run on Kubernetes and I tested on a different site with a single pod that didn’t create a full deploy cycle. I’ve now deployed it to the site linked above with a custom version of the plugin. I still am unable to access the language menu. I’ll leave the modified version up for you to look at.

    Plugin Author edo888

    (@edo888)

    OK, this should do the trick:

    if(current_lang != default_language)
        load_tlib();
    else {
        document.querySelectorAll(u_class).forEach(function(e){e.addEventListener('pointerenter',load_tlib)});
        document.querySelector(u_class + ' .gt_selector').addEventListener('focus',load_tlib);
    }

    Thanks! 🙂

    Thread Starter curtismchale

    (@curtismchale)

    Still works in Chrome on Linux.

    Does not work on Firefox on Linux.

    Does not work on macOS in Chrome or Firefox or Safari.

    I’m heading out for a few days from work so I may not get back to this till next Monday.

    Thread Starter curtismchale

    (@curtismchale)

    Are there any other updates on this?

    Plugin Author edo888

    (@edo888)

    Hi,

    I have checked and it worked for me on Windows. I cannot comment about other platforms as I haven’t tested.

    Thanks! 🙂

    Thread Starter curtismchale

    (@curtismchale)

    Yeah that’s not helpful. Is the official policy of gtranslate that you don’t support macOS and Linux based browsers?

    When will your testing protocol include macOS and Linux? Heck Linux is easy to test with a virtual machine and that’s free.

    Plugin Author edo888

    (@edo888)

    My suggestion is to use our paid version. I do not want to spend time on this testing all the platforms.

    Thanks! 🙂

    Thread Starter curtismchale

    (@curtismchale)

    Don’t love that. What if I find a bug in the paid version that affects browsers on macOS or Linux? Will those be supported?

    Plugin Author edo888

    (@edo888)

    Yes!

Viewing 14 replies - 1 through 14 (of 14 total)

You must be logged in to reply to this topic.