Close popover
Regina Siochi (ReginaS9)
Sky Solutions LLC

Sky Solutions LLC
ReginaS9 Member since 2019 22 posts
Sky Solutions LLC
Posted: July 15, 2020
Last activity: July 15, 2020

Reason for tabindex attr associated with harnessBody


We have a requirement to remove the tabindex=0 from <body> class=harnessBody to meet accessibility guidelines.  Having tabindex=0 associated with the <body> sets focus on the <body> with no visible focus indicator when user presses Tab key to navigate the portal.  (image attached)

I have tried to apply some code to remove the tabindex attribute or set tabindex="-1" to remove the <body> from the tab order, which runs on window.onload  but the tabindex reverts back to a value of "0" once the user presses the Tab key.  (code below applied to harness) 


function setTabIndex(){   $(".harnessBody").attr("tabindex", "-1"); }

  • Is there a particular reason why Pega sets the <body> with tabindex="0"? 
  • Does anyone have any OOTB suggestions on how to remove tabindex or set "tabindex" to "-1"?
  • Does anyone have any suggestion on how to edit the code so that it prevents the tabindex from reverting back to tabindex="0"?  
Pega Customer Service 8.3 User Experience System Architect