MCPcopy Index your code
hub / github.com/microsoft/playwright-python / select_text

Method select_text

playwright/async_api/_generated.py:19837–19865  ·  view source on GitHub ↗

Locator.select_text This method waits for [actionability](https://playwright.dev/python/docs/actionability) checks, then focuses the element and selects all its text content. If the element is inside the ` ` element that has an associated [control](https://dev

(
        self,
        *,
        force: typing.Optional[bool] = None,
        timeout: typing.Optional[typing.Union[float, datetime.timedelta]] = None,
    )

Source from the content-addressed store, hash-verified

19835 )
19836
19837 async def select_text(
19838 self,
19839 *,
19840 force: typing.Optional[bool] = None,
19841 timeout: typing.Optional[typing.Union[float, datetime.timedelta]] = None,
19842 ) -> None:
19843 """Locator.select_text
19844
19845 This method waits for [actionability](https://playwright.dev/python/docs/actionability) checks, then focuses the element and selects all its
19846 text content.
19847
19848 If the element is inside the `<label>` element that has an associated
19849 [control](https://developer.mozilla.org/en-US/docs/Web/API/HTMLLabelElement/control), focuses and selects text in
19850 the control instead.
19851
19852 Parameters
19853 ----------
19854 force : Union[bool, None]
19855 Whether to bypass the [actionability](../actionability.md) checks. Defaults to `false`.
19856 timeout : Union[float, None]
19857 Maximum time in milliseconds. Defaults to `30000` (30 seconds). Pass `0` to disable timeout. The default value can
19858 be changed by using the `browser_context.set_default_timeout()` or `page.set_default_timeout()` methods.
19859 """
19860
19861 return mapping.from_maybe_impl(
19862 await self._impl_obj.select_text(
19863 force=force, timeout=to_milliseconds(timeout)
19864 )
19865 )
19866
19867 async def set_input_files(
19868 self,

Callers 1

select_textMethod · 0.45

Calls 2

to_millisecondsFunction · 0.90
from_maybe_implMethod · 0.80

Tested by

no test coverage detected