All Downloads are FREE. Search and download functionalities are using the official Maven repository.
Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
package.dist.prod.util.isElementClickable.js.map Maven / Gradle / Ivy
{
"version": 3,
"sources": ["../../../src/util/isElementClickable.ts"],
"sourcesContent": ["const rClickable = /^(?:a|area)$/i;\nconst rFocusable = /^(?:input|select|textarea|button)$/i;\n\nconst isElementClickable = (el: HTMLElement): boolean => {\n\tif ((el as HTMLButtonElement).disabled) {\n\t\treturn false;\n\t}\n\n\tconst tabIndex = el.getAttribute(\"tabindex\");\n\tif (tabIndex !== null && tabIndex !== undefined) {\n\t\treturn parseInt(tabIndex) >= 0;\n\t}\n\n\treturn rFocusable.test(el.nodeName)\n\t\t|| (rClickable.test(el.nodeName)\n\t\t&& !!(el as HTMLLinkElement).href);\n};\n\nexport default isElementClickable;\n"],
"mappings": "aAAA,MAAMA,EAAa,gBACbC,EAAa,sCAEbC,EAAsBC,GAA6B,CACxD,GAAKA,EAAyB,SAC7B,MAAO,GAGR,MAAMC,EAAWD,EAAG,aAAa,UAAU,EAC3C,OAAIC,GAAa,KACT,SAASA,CAAQ,GAAK,EAGvBH,EAAW,KAAKE,EAAG,QAAQ,GAC7BH,EAAW,KAAKG,EAAG,QAAQ,GAC5B,CAAC,CAAEA,EAAuB,IAC/B,EAEA,eAAeD",
"names": ["rClickable", "rFocusable", "isElementClickable", "el", "tabIndex"]
}