Loss of focus on Submit buttons when hidden at any point when a course is Published

web-foley Community Member Posts: 62 ✶ Headliner ✶
I have a game-like page that has multiple questions on the page. Each Q would therefore need a unique Submit button, yet they must be "initially hidden" so that a screen reader does not pick them up (and/or read out of sequence).

When I created the page it worked in both a Run preview as well as Preview Page In (any) Browser. However, the moment the course was Published, that must have rendered the code differently as it breaks it. In short, when the course is Lectora 19 Published (HTML, SCORM etc.) the Submit buttons lose focus. Not only will they not be clickable (other than a visible mouseover state change), it will break the Accessibility focus for tab interaction.

I've recreated and attached a sample with a similar page as the broken functionality is easy to replicate. Since this HTML previews properly I'm inclined to think this is a publishing bug, as well as an Accessibility flaw, I'm still trying to find a workaround.


Best Answer

  • raung-naing
    raung-naing Moderator Posts: 12 eLearning ROCKSTAR Stage Manager
    Answer ✓
    @web-foley This replacement file is to fix: "Button that is initially hidden and disabled which fails to work after show and enabled."

    This file is ONLY for Lectora version 19.0.4


    Locate your installed directory similar to: C:\Program Files (x86)\eLearningBrothers\Lectora 19\Support Files
    Locate file trivantis-button.js and rename to trivantis-button.js.old
    Copy the downloaded file to this folder
    Rename the downloaded file to trivantis-button.js
    Restart Lectora and publish titles again.



  • web-foley
    web-foley Community Member Posts: 62 ✶ Headliner ✶
    A coworker has made some further observations. (thanks Trevor)
    If I compare the Preview in Browser (Left) source code to the Published to web source code on the right.
    After selected the question distractor, It appears that the published to web version is still set to disabled… even though it doesn’t look like it. That’s why you can’t click it.
    In Chrome Dev mode, when I removed the ‘disabled’ … BOOM it worked. So why is the set Button to Normal action not fully working.
    If you add some Jquery to the action sequence of each of the choice buttons to clear that nagging disabled attribute.
    triv$('[id*=button] button', getDisplayDocument()).removeAttr("disabled")
    And strangely you only need to add them to one.
    its also weird that if I remove the Enable Submit action. my code as a standalone doesnt work.

  • raung-naing
    raung-naing Moderator Posts: 12 eLearning ROCKSTAR Stage Manager
    edited April 14, 2021
    @web-foley we are looking into the issue and we'll keep you posted. Sorry about the inconvenience.