@hyperbrowser/agent
Version:
Hyperbrowsers Web Agent
65 lines (64 loc) • 1.31 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.CONTEXT_ATTRIBUTES = exports.CLICK_ATTRIBUTES = exports.INTERACTIVE_ARIA_PROPS = exports.INTERACTIVE_EVENTS = exports.INTERACTIVE_ROLES = exports.INTERACTIVE_ELEMENTS = void 0;
exports.INTERACTIVE_ELEMENTS = new Set([
"a",
"input",
"button",
"select",
"menu",
"menuitem",
"textarea",
"canvas",
"embed",
]);
exports.INTERACTIVE_ROLES = new Set([
"button",
"link",
"checkbox",
"radio",
"textbox",
"menuitem",
"tab",
"tabpanel",
"tooltip",
"slider",
"progressbar",
"switch",
"listbox",
"option",
"combobox",
"menu",
"treeitem",
"tree",
"spinbutton",
"scrollbar",
"menuitemcheckbox",
"menuitemradio",
"action",
]);
exports.INTERACTIVE_EVENTS = new Set([
"click",
"mousedown",
"mouseup",
"touchstart",
"touchend",
]);
exports.INTERACTIVE_ARIA_PROPS = [
"aria-expanded",
"aria-pressed",
"aria-selected",
"aria-checked",
];
exports.CLICK_ATTRIBUTES = ["onclick", "ng-click", "@click", "v-on:click"];
exports.CONTEXT_ATTRIBUTES = [
"title",
"type",
"name",
"role",
"aria-label",
"placeholder",
"value",
"alt",
"aria-expanded",
];