/* * Copyright (c) 2022, Tobias Christiansen * Copyright (c) 2022, Tim Flynn * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include #include #include #include namespace Web::WebDriver { // https://w3c.github.io/webdriver/#dfn-table-of-location-strategies enum class LocationStrategy { CssSelector, LinkText, PartialLinkText, TagName, XPath, }; Optional location_strategy_from_string(StringView type); ErrorOr, Error> invoke_location_strategy(LocationStrategy type, DOM::ParentNode& start_node, StringView selector); }