Function: findByLabelText()
findByLabelText(
container,text,options?):Promise<Widget>
Defined in: queries.ts:408
Finds a single element that is labelled by a GtkLabel whose text matches.
Waits for the element to appear, throwing if not found within timeout. Uses GtkLabel's mnemonic widget association to find form elements.
Parameters
| Parameter | Type | Description |
|---|---|---|
container | Container | The container to search within |
text | TextMatch | Label text to match (string, RegExp, or custom matcher) |
options? | TextMatchOptions | Query options including normalization and timeout |
Returns
Promise<Widget>
Promise resolving to the labelled widget
Example
const input = await findByLabelText(container, "Username");