UNPKG

playwright-fluent

Version:
13 lines (12 loc) 487 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.hasHandleAriaLabel = void 0; const get_attribute_of_handle_1 = require("../get-attribute-of-handle"); async function hasHandleAriaLabel(handle, expectedAriaLabel) { if (!handle) { return false; } const label = await (0, get_attribute_of_handle_1.getAttributeOfHandle)('aria-label', handle); return label === expectedAriaLabel; } exports.hasHandleAriaLabel = hasHandleAriaLabel;