@gtkx/testing 1.6.0 → 2.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/README.md +5 -5
  2. package/dist/config.d.ts.map +1 -1
  3. package/dist/config.js +1 -3
  4. package/dist/config.js.map +1 -1
  5. package/dist/queries.d.ts +30 -126
  6. package/dist/queries.d.ts.map +1 -1
  7. package/dist/queries.js +30 -126
  8. package/dist/queries.js.map +1 -1
  9. package/dist/screenshot.d.ts.map +1 -1
  10. package/dist/screenshot.js +1 -3
  11. package/dist/screenshot.js.map +1 -1
  12. package/dist/user-event/adjustment.d.ts +2 -14
  13. package/dist/user-event/adjustment.d.ts.map +1 -1
  14. package/dist/user-event/adjustment.js +2 -14
  15. package/dist/user-event/adjustment.js.map +1 -1
  16. package/dist/user-event/click.d.ts +3 -41
  17. package/dist/user-event/click.d.ts.map +1 -1
  18. package/dist/user-event/click.js +3 -41
  19. package/dist/user-event/click.js.map +1 -1
  20. package/dist/user-event/gesture.d.ts +9 -43
  21. package/dist/user-event/gesture.d.ts.map +1 -1
  22. package/dist/user-event/gesture.js +9 -43
  23. package/dist/user-event/gesture.js.map +1 -1
  24. package/dist/user-event/index.d.ts +16 -85
  25. package/dist/user-event/index.d.ts.map +1 -1
  26. package/dist/user-event/index.js +1 -5
  27. package/dist/user-event/index.js.map +1 -1
  28. package/dist/user-event/keyboard.d.ts +1 -1
  29. package/dist/user-event/keyboard.d.ts.map +1 -1
  30. package/dist/user-event/keyboard.js +1 -1
  31. package/dist/user-event/keyboard.js.map +1 -1
  32. package/dist/user-event/selection.d.ts +2 -18
  33. package/dist/user-event/selection.d.ts.map +1 -1
  34. package/dist/user-event/selection.js +3 -21
  35. package/dist/user-event/selection.js.map +1 -1
  36. package/dist/user-event/text.d.ts +5 -34
  37. package/dist/user-event/text.d.ts.map +1 -1
  38. package/dist/user-event/text.js +5 -34
  39. package/dist/user-event/text.js.map +1 -1
  40. package/dist/widget-accessible-properties.d.ts.map +1 -1
  41. package/dist/widget-accessible-properties.js +14 -34
  42. package/dist/widget-accessible-properties.js.map +1 -1
  43. package/package.json +12 -8
  44. package/src/config.ts +1 -3
  45. package/src/queries.ts +30 -126
  46. package/src/screenshot.ts +1 -3
  47. package/src/user-event/adjustment.ts +2 -14
  48. package/src/user-event/click.ts +3 -41
  49. package/src/user-event/gesture.ts +9 -43
  50. package/src/user-event/index.ts +16 -85
  51. package/src/user-event/keyboard.ts +1 -1
  52. package/src/user-event/selection.ts +3 -21
  53. package/src/user-event/text.ts +5 -34
  54. package/src/widget-accessible-properties.ts +22 -44
package/README.md CHANGED
@@ -13,7 +13,7 @@
13
13
  <p align="center">
14
14
  <a href="https://www.npmjs.com/package/create-gtkx"><img src="https://img.shields.io/npm/v/create-gtkx?color=cb3837&logo=npm&label=create-gtkx" alt="npm version" /></a>
15
15
  <a href="https://www.npmjs.com/package/create-gtkx"><img src="https://img.shields.io/npm/dm/create-gtkx?color=cb3837&logo=npm&label=downloads" alt="npm downloads" /></a>
16
- <img src="https://img.shields.io/badge/node-%E2%89%A524-339933?logo=node.js&logoColor=white" alt="Node >= 24" />
16
+ <img src="https://img.shields.io/badge/node-%E2%89%A526.7-339933?logo=node.js&logoColor=white" alt="Node >= 26.7" />
17
17
  <a href="https://github.com/gtkx-org/gtkx/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MPL--2.0-blue.svg" alt="License: MPL-2.0" /></a>
18
18
  <a href="https://github.com/gtkx-org/gtkx/actions/workflows/ci.yml"><img src="https://img.shields.io/github/actions/workflow/status/gtkx-org/gtkx/ci.yml?branch=main&logo=github&label=CI" alt="CI status" /></a>
19
19
  <img src="https://img.shields.io/badge/TypeScript-strict-3178c6?logo=typescript&logoColor=white" alt="TypeScript" />
@@ -116,7 +116,7 @@ At runtime, the native Rust core calls straight into the system GTK4, Adwaita, a
116
116
 
117
117
  ## Quick start
118
118
 
119
- GTKX is Linux-only and needs Node.js 24 or later. See [Requirements](#requirements).
119
+ GTKX is Linux-only and needs Node.js 26.7 or later. See [Requirements](#requirements).
120
120
 
121
121
  Scaffold a new app with the `create-gtkx` initializer:
122
122
 
@@ -145,8 +145,8 @@ The documentation at **[gtkx.dev](https://gtkx.dev)** includes a step-by-step tu
145
145
 
146
146
  GTKX is Linux-only. You need:
147
147
 
148
- - Linux with the GTK4 (4.20 or later) and GLib development libraries, plus Adwaita (1.8 or later) once your project binds `Adw-1`
149
- - Node.js 24 or later
148
+ - Linux with the GTK4 (4.20 or later), Adwaita (1.8 or later), and GLib development libraries
149
+ - Node.js 26.7 or later
150
150
 
151
151
  The `@gtkx/native` addon ships prebuilt for x64 and arm64 glibc Linux; other targets need to build it from the GTKX repository, which requires a Rust toolchain.
152
152
 
@@ -167,7 +167,7 @@ GTKX is stable and ready for production use.
167
167
 
168
168
  ## Contributing
169
169
 
170
- Contributions are welcome. See [CONTRIBUTING.md](https://github.com/gtkx-org/gtkx/blob/main/CONTRIBUTING.md), the [Code of Conduct](https://github.com/gtkx-org/gtkx/blob/main/CODE_OF_CONDUCT.md), and the [security policy](https://github.com/gtkx-org/gtkx/blob/main/SECURITY.md). Building the repo needs Node.js 24 or later, pnpm, and a Rust toolchain.
170
+ Contributions are welcome. See [CONTRIBUTING.md](https://github.com/gtkx-org/gtkx/blob/main/CONTRIBUTING.md), the [Code of Conduct](https://github.com/gtkx-org/gtkx/blob/main/CODE_OF_CONDUCT.md), and the [security policy](https://github.com/gtkx-org/gtkx/blob/main/SECURITY.md). Building the repo needs Node.js 26.7 or later, pnpm, and a Rust toolchain.
171
171
 
172
172
  ## License
173
173
 
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAEhD;;;;GAIG;AACH,KAAK,MAAM,GAAG;IACV,+FAA+F;IAC/F,gBAAgB,EAAE,OAAO,CAAC;IAE1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AuB,CAAC;AAE9C;;;;;GAKG;AACH,QAAA,MAAM,SAAS,GAAI,WAAW,OAAO,CAAC,MAAM,CAAC,GAAG,QAAQ,KAAG,IAG1D,CAAC;AAMF,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,KAAK,MAAM,EAAE,KAAK,QAAQ,EAAE,CAAC"}
package/dist/config.js CHANGED
@@ -12,9 +12,7 @@ function defaultGetElementError(message) {
12
12
  /**
13
13
  * Returns the current global testing configuration.
14
14
  */
15
- const getConfig = () => {
16
- return currentConfig;
17
- };
15
+ const getConfig = () => currentConfig;
18
16
  /**
19
17
  * Merges the given overrides into the global testing configuration.
20
18
  *
@@ -1 +1 @@
1
- {"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAmCA,MAAM,aAAa,GAAW;IAC1B,gBAAgB,EAAE,KAAK;IACvB,eAAe,EAAE,sBAAsB;IACvC,gBAAgB,EAAE,IAAI;IACtB,oBAAoB,EAAE,GAAG;IACzB,uBAAuB,EAAE,IAAI;CAChC,CAAC;AAEF,MAAM,aAAa,GAAW,EAAE,GAAG,aAAa,EAAE,CAAC;AAEnD,SAAS,sBAAsB,CAAC,OAAe;IAC3C,OAAO,IAAI,YAAY,CAAC,OAAO,CAAC,CAAC;AACrC,CAAC;AAED;;GAEG;AACH,MAAM,SAAS,GAAG,GAAW,EAAE;IAC3B,OAAO,aAAa,CAAC;AACzB,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,SAAS,GAAG,CAAC,SAAqC,EAAQ,EAAE;IAC9D,MAAM,OAAO,GAAG,OAAO,SAAS,KAAK,UAAU,CAAC,CAAC,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;IACvF,MAAM,CAAC,MAAM,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;AAC1C,CAAC,CAAC;AAEF,MAAM,YAAa,SAAQ,KAAK;IACnB,IAAI,GAAG,cAAc,CAAC;CAClC;AAED,OAAO,EAAE,SAAS,EAAE,SAAS,EAA8B,CAAC","sourcesContent":["import type { Container } from \"./traversal.js\";\n\n/**\n * Global configuration for the testing harness, controlling query behavior,\n * error formatting, and the timeouts used by async utilities and actionability\n * checks.\n */\ntype Config = {\n /** Whether a successful query throws instead, naming a better query, when one is available. */\n throwSuggestions: boolean;\n\n /** Builds the error thrown when a query fails, given a message and optional container. */\n getElementError: (message: string, container?: Container) => Error;\n\n /** Default timeout in milliseconds for async utilities such as waitFor. */\n asyncUtilTimeout: number;\n\n /** Timeout in milliseconds a user event waits for its widget to become actionable. */\n actionabilityTimeout: number;\n\n /**\n * Timeout in milliseconds `render` waits for the window it shows the tree in to be laid out and\n * activated. A window becoming active is a round trip through the compositor rather than an\n * in-process check, so this is far longer than {@link Config.actionabilityTimeout}: it bounds\n * how long a window that never activates takes to report, and costs nothing when one does.\n */\n windowActivationTimeout: number;\n};\n\n/**\n * Function form of a configuration update: receives the current config and\n * returns the fields to override.\n */\ntype ConfigFn = (existingConfig: Config) => Partial<Config>;\n\nconst defaultConfig: Config = {\n throwSuggestions: false,\n getElementError: defaultGetElementError,\n asyncUtilTimeout: 1000,\n actionabilityTimeout: 500,\n windowActivationTimeout: 5000,\n};\n\nconst currentConfig: Config = { ...defaultConfig };\n\nfunction defaultGetElementError(message: string): Error {\n return new ElementError(message);\n}\n\n/**\n * Returns the current global testing configuration.\n */\nconst getConfig = (): Config => {\n return currentConfig;\n};\n\n/**\n * Merges the given overrides into the global testing configuration.\n *\n * @param newConfig Either a partial config object or a function that receives\n * the current config and returns the fields to override.\n */\nconst configure = (newConfig: Partial<Config> | ConfigFn): void => {\n const updates = typeof newConfig === \"function\" ? newConfig(currentConfig) : newConfig;\n Object.assign(currentConfig, updates);\n};\n\nclass ElementError extends Error {\n override name = \"ElementError\";\n}\n\nexport { getConfig, configure, type Config, type ConfigFn };\n"]}
1
+ {"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAmCA,MAAM,aAAa,GAAW;IAC1B,gBAAgB,EAAE,KAAK;IACvB,eAAe,EAAE,sBAAsB;IACvC,gBAAgB,EAAE,IAAI;IACtB,oBAAoB,EAAE,GAAG;IACzB,uBAAuB,EAAE,IAAI;CAChC,CAAC;AAEF,MAAM,aAAa,GAAW,EAAE,GAAG,aAAa,EAAE,CAAC;AAEnD,SAAS,sBAAsB,CAAC,OAAe;IAC3C,OAAO,IAAI,YAAY,CAAC,OAAO,CAAC,CAAC;AACrC,CAAC;AAED;;GAEG;AACH,MAAM,SAAS,GAAG,GAAW,EAAE,CAAC,aAAa,CAAC;AAE9C;;;;;GAKG;AACH,MAAM,SAAS,GAAG,CAAC,SAAqC,EAAQ,EAAE;IAC9D,MAAM,OAAO,GAAG,OAAO,SAAS,KAAK,UAAU,CAAC,CAAC,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;IACvF,MAAM,CAAC,MAAM,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;AAC1C,CAAC,CAAC;AAEF,MAAM,YAAa,SAAQ,KAAK;IACnB,IAAI,GAAG,cAAc,CAAC;CAClC;AAED,OAAO,EAAE,SAAS,EAAE,SAAS,EAA8B,CAAC","sourcesContent":["import type { Container } from \"./traversal.js\";\n\n/**\n * Global configuration for the testing harness, controlling query behavior,\n * error formatting, and the timeouts used by async utilities and actionability\n * checks.\n */\ntype Config = {\n /** Whether a successful query throws instead, naming a better query, when one is available. */\n throwSuggestions: boolean;\n\n /** Builds the error thrown when a query fails, given a message and optional container. */\n getElementError: (message: string, container?: Container) => Error;\n\n /** Default timeout in milliseconds for async utilities such as waitFor. */\n asyncUtilTimeout: number;\n\n /** Timeout in milliseconds a user event waits for its widget to become actionable. */\n actionabilityTimeout: number;\n\n /**\n * Timeout in milliseconds `render` waits for the window it shows the tree in to be laid out and\n * activated. A window becoming active is a round trip through the compositor rather than an\n * in-process check, so this is far longer than {@link Config.actionabilityTimeout}: it bounds\n * how long a window that never activates takes to report, and costs nothing when one does.\n */\n windowActivationTimeout: number;\n};\n\n/**\n * Function form of a configuration update: receives the current config and\n * returns the fields to override.\n */\ntype ConfigFn = (existingConfig: Config) => Partial<Config>;\n\nconst defaultConfig: Config = {\n throwSuggestions: false,\n getElementError: defaultGetElementError,\n asyncUtilTimeout: 1000,\n actionabilityTimeout: 500,\n windowActivationTimeout: 5000,\n};\n\nconst currentConfig: Config = { ...defaultConfig };\n\nfunction defaultGetElementError(message: string): Error {\n return new ElementError(message);\n}\n\n/**\n * Returns the current global testing configuration.\n */\nconst getConfig = (): Config => currentConfig;\n\n/**\n * Merges the given overrides into the global testing configuration.\n *\n * @param newConfig Either a partial config object or a function that receives\n * the current config and returns the fields to override.\n */\nconst configure = (newConfig: Partial<Config> | ConfigFn): void => {\n const updates = typeof newConfig === \"function\" ? newConfig(currentConfig) : newConfig;\n Object.assign(currentConfig, updates);\n};\n\nclass ElementError extends Error {\n override name = \"ElementError\";\n}\n\nexport { getConfig, configure, type Config, type ConfigFn };\n"]}
package/dist/queries.d.ts CHANGED
@@ -4,161 +4,65 @@ import { type Container } from "./traversal.js";
4
4
  /** The built-in queries in their unbound form, each taking the container to search as its first argument. */
5
5
  type BuiltinQueries = QueryFamilies<[container: Container]>;
6
6
  declare const builtinQueries: BuiltinQueries;
7
- /**
8
- * Returns the single mapped widget with a matching accessible role and options, or null when none
9
- * match. Widgets that are not mapped are never matched. Throws when more than one matches.
10
- */
7
+ /** Queries one mapped widget by accessible role. */
11
8
  declare const queryByRole: BuiltinQueries["queryByRole"];
12
- /**
13
- * Returns every mapped widget with a matching accessible role and options. Widgets that are not
14
- * mapped are never matched. Throws when none match.
15
- */
9
+ /** Gets all mapped widgets with an accessible role. */
16
10
  declare const getAllByRole: BuiltinQueries["getAllByRole"];
17
- /**
18
- * Returns the single mapped widget with a matching accessible role and options. Widgets that are not
19
- * mapped are never matched. Throws when none or more than one matches.
20
- */
11
+ /** Gets one mapped widget by accessible role. */
21
12
  declare const getByRole: BuiltinQueries["getByRole"];
22
- /**
23
- * Waits for and returns every mapped widget with a matching accessible role and options, retrying
24
- * until at least one appears or the timeout elapses. Widgets that are not mapped are never matched.
25
- */
13
+ /** Finds all mapped widgets with an accessible role. */
26
14
  declare const findAllByRole: BuiltinQueries["findAllByRole"];
27
- /**
28
- * Waits for and returns the single mapped widget with a matching accessible role and options,
29
- * retrying until it appears or the timeout elapses. Widgets that are not mapped are never matched.
30
- * Rejects when none or more than one matches.
31
- */
15
+ /** Finds one mapped widget by accessible role. */
32
16
  declare const findByRole: BuiltinQueries["findByRole"];
33
- /**
34
- * Returns the single mapped widget with matching associated label text, or null when none match.
35
- * Widgets that are not mapped are never matched. Throws when more than one matches.
36
- */
17
+ /** Queries one mapped widget by label text. */
37
18
  declare const queryByLabelText: BuiltinQueries["queryByLabelText"];
38
- /**
39
- * Returns every mapped widget with matching associated label text. Widgets that are not mapped are
40
- * never matched. Throws when none match.
41
- */
19
+ /** Gets all mapped widgets with label text. */
42
20
  declare const getAllByLabelText: BuiltinQueries["getAllByLabelText"];
43
- /**
44
- * Returns the single mapped widget with matching associated label text. Widgets that are not mapped
45
- * are never matched. Throws when none or more than one matches.
46
- */
21
+ /** Gets one mapped widget by label text. */
47
22
  declare const getByLabelText: BuiltinQueries["getByLabelText"];
48
- /**
49
- * Waits for and returns every mapped widget with matching associated label text, retrying until at
50
- * least one appears or the timeout elapses. Widgets that are not mapped are never matched.
51
- */
23
+ /** Finds all mapped widgets with label text. */
52
24
  declare const findAllByLabelText: BuiltinQueries["findAllByLabelText"];
53
- /**
54
- * Waits for and returns the single mapped widget with matching associated label text, retrying until
55
- * it appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when
56
- * none or more than one matches.
57
- */
25
+ /** Finds one mapped widget by label text. */
58
26
  declare const findByLabelText: BuiltinQueries["findByLabelText"];
59
- /**
60
- * Returns the single mapped widget with matching rendered text content, or null when none match.
61
- * Widgets that are not mapped are never matched. Throws when more than one matches.
62
- */
27
+ /** Queries one mapped widget by rendered text. */
63
28
  declare const queryByText: BuiltinQueries["queryByText"];
64
- /**
65
- * Returns every mapped widget with matching rendered text content. Widgets that are not mapped are
66
- * never matched. Throws when none match.
67
- */
29
+ /** Gets all mapped widgets with rendered text. */
68
30
  declare const getAllByText: BuiltinQueries["getAllByText"];
69
- /**
70
- * Returns the single mapped widget with matching rendered text content. Widgets that are not mapped
71
- * are never matched. Throws when none or more than one matches.
72
- */
31
+ /** Gets one mapped widget by rendered text. */
73
32
  declare const getByText: BuiltinQueries["getByText"];
74
- /**
75
- * Waits for and returns every mapped widget with matching rendered text content, retrying until at
76
- * least one appears or the timeout elapses. Widgets that are not mapped are never matched.
77
- */
33
+ /** Finds all mapped widgets with rendered text. */
78
34
  declare const findAllByText: BuiltinQueries["findAllByText"];
79
- /**
80
- * Waits for and returns the single mapped widget with matching rendered text content, retrying until
81
- * it appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when
82
- * none or more than one matches.
83
- */
35
+ /** Finds one mapped widget by rendered text. */
84
36
  declare const findByText: BuiltinQueries["findByText"];
85
- /**
86
- * Returns the single mapped widget with a matching widget name, or null when none match. Widgets
87
- * that are not mapped are never matched. Throws when more than one matches.
88
- */
37
+ /** Queries one mapped widget by GTK name. */
89
38
  declare const queryByName: BuiltinQueries["queryByName"];
90
- /**
91
- * Returns every mapped widget with a matching widget name. Widgets that are not mapped are never
92
- * matched. Throws when none match.
93
- */
39
+ /** Gets all mapped widgets with a GTK name. */
94
40
  declare const getAllByName: BuiltinQueries["getAllByName"];
95
- /**
96
- * Returns the single mapped widget with a matching widget name. Widgets that are not mapped are
97
- * never matched. Throws when none or more than one matches.
98
- */
41
+ /** Gets one mapped widget by GTK name. */
99
42
  declare const getByName: BuiltinQueries["getByName"];
100
- /**
101
- * Waits for and returns every mapped widget with a matching widget name, retrying until at least one
102
- * appears or the timeout elapses. Widgets that are not mapped are never matched.
103
- */
43
+ /** Finds all mapped widgets with a GTK name. */
104
44
  declare const findAllByName: BuiltinQueries["findAllByName"];
105
- /**
106
- * Waits for and returns the single mapped widget with a matching widget name, retrying until it
107
- * appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when none
108
- * or more than one matches.
109
- */
45
+ /** Finds one mapped widget by GTK name. */
110
46
  declare const findByName: BuiltinQueries["findByName"];
111
- /**
112
- * Returns the single mapped widget with matching placeholder text, or null when none match. Widgets
113
- * that are not mapped are never matched. Throws when more than one matches.
114
- */
47
+ /** Queries one mapped widget by placeholder text. */
115
48
  declare const queryByPlaceholderText: BuiltinQueries["queryByPlaceholderText"];
116
- /**
117
- * Returns every mapped widget with matching placeholder text. Widgets that are not mapped are never
118
- * matched. Throws when none match.
119
- */
49
+ /** Gets all mapped widgets with placeholder text. */
120
50
  declare const getAllByPlaceholderText: BuiltinQueries["getAllByPlaceholderText"];
121
- /**
122
- * Returns the single mapped widget with matching placeholder text. Widgets that are not mapped are
123
- * never matched. Throws when none or more than one matches.
124
- */
51
+ /** Gets one mapped widget by placeholder text. */
125
52
  declare const getByPlaceholderText: BuiltinQueries["getByPlaceholderText"];
126
- /**
127
- * Waits for and returns every mapped widget with matching placeholder text, retrying until at least
128
- * one appears or the timeout elapses. Widgets that are not mapped are never matched.
129
- */
53
+ /** Finds all mapped widgets with placeholder text. */
130
54
  declare const findAllByPlaceholderText: BuiltinQueries["findAllByPlaceholderText"];
131
- /**
132
- * Waits for and returns the single mapped widget with matching placeholder text, retrying until it
133
- * appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when none
134
- * or more than one matches.
135
- */
55
+ /** Finds one mapped widget by placeholder text. */
136
56
  declare const findByPlaceholderText: BuiltinQueries["findByPlaceholderText"];
137
- /**
138
- * Returns the single mapped widget with a matching display value, or null when none match. Widgets
139
- * that are not mapped are never matched. Throws when more than one matches.
140
- */
57
+ /** Queries one mapped widget by display value. */
141
58
  declare const queryByDisplayValue: BuiltinQueries["queryByDisplayValue"];
142
- /**
143
- * Returns every mapped widget with a matching display value. Widgets that are not mapped are never
144
- * matched. Throws when none match.
145
- */
59
+ /** Gets all mapped widgets with a display value. */
146
60
  declare const getAllByDisplayValue: BuiltinQueries["getAllByDisplayValue"];
147
- /**
148
- * Returns the single mapped widget with a matching display value. Widgets that are not mapped are
149
- * never matched. Throws when none or more than one matches.
150
- */
61
+ /** Gets one mapped widget by display value. */
151
62
  declare const getByDisplayValue: BuiltinQueries["getByDisplayValue"];
152
- /**
153
- * Waits for and returns every mapped widget with a matching display value, retrying until at least
154
- * one appears or the timeout elapses. Widgets that are not mapped are never matched.
155
- */
63
+ /** Finds all mapped widgets with a display value. */
156
64
  declare const findAllByDisplayValue: BuiltinQueries["findAllByDisplayValue"];
157
- /**
158
- * Waits for and returns the single mapped widget with a matching display value, retrying until it
159
- * appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when none
160
- * or more than one matches.
161
- */
65
+ /** Finds one mapped widget by display value. */
162
66
  declare const findByDisplayValue: BuiltinQueries["findByDisplayValue"];
163
67
  declare const isTextMatch: (actual: string | null, expected: Matcher, widget: Gtk.Widget, options?: MatcherOptions) => boolean;
164
68
  declare const isMatchingWidgetType: (widget: Gtk.Widget, options?: MatcherOptions) => boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../src/queries.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,GAAG,MAAM,cAAc,CAAC;AACpC,OAAO,KAAK,EACR,aAAa,EAEb,OAAO,EACP,cAAc,EAEd,aAAa,EAChB,MAAM,YAAY,CAAC;AAIpB,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,gBAAgB,CAAC;AAuBnE,6GAA6G;AAC7G,KAAK,cAAc,GAAG,aAAa,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC,CAAC;AA+D5D,QAAA,MAAM,cAAc,EAOf,cAAc,CAAC;AAEpB;;;GAGG;AACH,QAAA,MAAM,WAAW,EAAE,cAAc,CAAC,aAAa,CAA8B,CAAC;AAC9E;;;GAGG;AACH,QAAA,MAAM,YAA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iBAAS,cAAc,CAAC,SAAS,EAAE,SAAS,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,GAAG,CAAC,MAAM,EAAE,CAKnG;AAED;;;;;;GAMG;AACH,iBAAS,yBAAyB,CAC9B,SAAS,EAAE,SAAS,EACpB,IAAI,EAAE,OAAO,EACb,OAAO,CAAC,EAAE,cAAc,GACzB,GAAG,CAAC,MAAM,EAAE,CAOd;AAED;;;;;;GAMG;AACH,iBAAS,sBAAsB,CAAC,SAAS,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,GAAG,CAAC,MAAM,EAAE,CAO5G;AAED,OAAO,EACH,cAAc,EACd,oBAAoB,EACpB,WAAW,EACX,WAAW,EACX,YAAY,EACZ,SAAS,EACT,aAAa,EACb,UAAU,EACV,gBAAgB,EAChB,iBAAiB,EACjB,cAAc,EACd,kBAAkB,EAClB,eAAe,EACf,WAAW,EACX,YAAY,EACZ,SAAS,EACT,aAAa,EACb,UAAU,EACV,WAAW,EACX,YAAY,EACZ,SAAS,EACT,aAAa,EACb,UAAU,EACV,sBAAsB,EACtB,uBAAuB,EACvB,oBAAoB,EACpB,wBAAwB,EACxB,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,iBAAiB,EACjB,qBAAqB,EACrB,kBAAkB,EAClB,cAAc,EACd,mBAAmB,EACnB,cAAc,EACd,cAAc,EACd,yBAAyB,EACzB,sBAAsB,GACzB,CAAC"}
package/dist/queries.js CHANGED
@@ -18,161 +18,65 @@ const builtinQueries = {
18
18
  ...placeholderTextQueries,
19
19
  ...displayValueQueries,
20
20
  };
21
- /**
22
- * Returns the single mapped widget with a matching accessible role and options, or null when none
23
- * match. Widgets that are not mapped are never matched. Throws when more than one matches.
24
- */
21
+ /** Queries one mapped widget by accessible role. */
25
22
  const queryByRole = builtinQueries.queryByRole;
26
- /**
27
- * Returns every mapped widget with a matching accessible role and options. Widgets that are not
28
- * mapped are never matched. Throws when none match.
29
- */
23
+ /** Gets all mapped widgets with an accessible role. */
30
24
  const getAllByRole = builtinQueries.getAllByRole;
31
- /**
32
- * Returns the single mapped widget with a matching accessible role and options. Widgets that are not
33
- * mapped are never matched. Throws when none or more than one matches.
34
- */
25
+ /** Gets one mapped widget by accessible role. */
35
26
  const getByRole = builtinQueries.getByRole;
36
- /**
37
- * Waits for and returns every mapped widget with a matching accessible role and options, retrying
38
- * until at least one appears or the timeout elapses. Widgets that are not mapped are never matched.
39
- */
27
+ /** Finds all mapped widgets with an accessible role. */
40
28
  const findAllByRole = builtinQueries.findAllByRole;
41
- /**
42
- * Waits for and returns the single mapped widget with a matching accessible role and options,
43
- * retrying until it appears or the timeout elapses. Widgets that are not mapped are never matched.
44
- * Rejects when none or more than one matches.
45
- */
29
+ /** Finds one mapped widget by accessible role. */
46
30
  const findByRole = builtinQueries.findByRole;
47
- /**
48
- * Returns the single mapped widget with matching associated label text, or null when none match.
49
- * Widgets that are not mapped are never matched. Throws when more than one matches.
50
- */
31
+ /** Queries one mapped widget by label text. */
51
32
  const queryByLabelText = builtinQueries.queryByLabelText;
52
- /**
53
- * Returns every mapped widget with matching associated label text. Widgets that are not mapped are
54
- * never matched. Throws when none match.
55
- */
33
+ /** Gets all mapped widgets with label text. */
56
34
  const getAllByLabelText = builtinQueries.getAllByLabelText;
57
- /**
58
- * Returns the single mapped widget with matching associated label text. Widgets that are not mapped
59
- * are never matched. Throws when none or more than one matches.
60
- */
35
+ /** Gets one mapped widget by label text. */
61
36
  const getByLabelText = builtinQueries.getByLabelText;
62
- /**
63
- * Waits for and returns every mapped widget with matching associated label text, retrying until at
64
- * least one appears or the timeout elapses. Widgets that are not mapped are never matched.
65
- */
37
+ /** Finds all mapped widgets with label text. */
66
38
  const findAllByLabelText = builtinQueries.findAllByLabelText;
67
- /**
68
- * Waits for and returns the single mapped widget with matching associated label text, retrying until
69
- * it appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when
70
- * none or more than one matches.
71
- */
39
+ /** Finds one mapped widget by label text. */
72
40
  const findByLabelText = builtinQueries.findByLabelText;
73
- /**
74
- * Returns the single mapped widget with matching rendered text content, or null when none match.
75
- * Widgets that are not mapped are never matched. Throws when more than one matches.
76
- */
41
+ /** Queries one mapped widget by rendered text. */
77
42
  const queryByText = builtinQueries.queryByText;
78
- /**
79
- * Returns every mapped widget with matching rendered text content. Widgets that are not mapped are
80
- * never matched. Throws when none match.
81
- */
43
+ /** Gets all mapped widgets with rendered text. */
82
44
  const getAllByText = builtinQueries.getAllByText;
83
- /**
84
- * Returns the single mapped widget with matching rendered text content. Widgets that are not mapped
85
- * are never matched. Throws when none or more than one matches.
86
- */
45
+ /** Gets one mapped widget by rendered text. */
87
46
  const getByText = builtinQueries.getByText;
88
- /**
89
- * Waits for and returns every mapped widget with matching rendered text content, retrying until at
90
- * least one appears or the timeout elapses. Widgets that are not mapped are never matched.
91
- */
47
+ /** Finds all mapped widgets with rendered text. */
92
48
  const findAllByText = builtinQueries.findAllByText;
93
- /**
94
- * Waits for and returns the single mapped widget with matching rendered text content, retrying until
95
- * it appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when
96
- * none or more than one matches.
97
- */
49
+ /** Finds one mapped widget by rendered text. */
98
50
  const findByText = builtinQueries.findByText;
99
- /**
100
- * Returns the single mapped widget with a matching widget name, or null when none match. Widgets
101
- * that are not mapped are never matched. Throws when more than one matches.
102
- */
51
+ /** Queries one mapped widget by GTK name. */
103
52
  const queryByName = builtinQueries.queryByName;
104
- /**
105
- * Returns every mapped widget with a matching widget name. Widgets that are not mapped are never
106
- * matched. Throws when none match.
107
- */
53
+ /** Gets all mapped widgets with a GTK name. */
108
54
  const getAllByName = builtinQueries.getAllByName;
109
- /**
110
- * Returns the single mapped widget with a matching widget name. Widgets that are not mapped are
111
- * never matched. Throws when none or more than one matches.
112
- */
55
+ /** Gets one mapped widget by GTK name. */
113
56
  const getByName = builtinQueries.getByName;
114
- /**
115
- * Waits for and returns every mapped widget with a matching widget name, retrying until at least one
116
- * appears or the timeout elapses. Widgets that are not mapped are never matched.
117
- */
57
+ /** Finds all mapped widgets with a GTK name. */
118
58
  const findAllByName = builtinQueries.findAllByName;
119
- /**
120
- * Waits for and returns the single mapped widget with a matching widget name, retrying until it
121
- * appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when none
122
- * or more than one matches.
123
- */
59
+ /** Finds one mapped widget by GTK name. */
124
60
  const findByName = builtinQueries.findByName;
125
- /**
126
- * Returns the single mapped widget with matching placeholder text, or null when none match. Widgets
127
- * that are not mapped are never matched. Throws when more than one matches.
128
- */
61
+ /** Queries one mapped widget by placeholder text. */
129
62
  const queryByPlaceholderText = builtinQueries.queryByPlaceholderText;
130
- /**
131
- * Returns every mapped widget with matching placeholder text. Widgets that are not mapped are never
132
- * matched. Throws when none match.
133
- */
63
+ /** Gets all mapped widgets with placeholder text. */
134
64
  const getAllByPlaceholderText = builtinQueries.getAllByPlaceholderText;
135
- /**
136
- * Returns the single mapped widget with matching placeholder text. Widgets that are not mapped are
137
- * never matched. Throws when none or more than one matches.
138
- */
65
+ /** Gets one mapped widget by placeholder text. */
139
66
  const getByPlaceholderText = builtinQueries.getByPlaceholderText;
140
- /**
141
- * Waits for and returns every mapped widget with matching placeholder text, retrying until at least
142
- * one appears or the timeout elapses. Widgets that are not mapped are never matched.
143
- */
67
+ /** Finds all mapped widgets with placeholder text. */
144
68
  const findAllByPlaceholderText = builtinQueries.findAllByPlaceholderText;
145
- /**
146
- * Waits for and returns the single mapped widget with matching placeholder text, retrying until it
147
- * appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when none
148
- * or more than one matches.
149
- */
69
+ /** Finds one mapped widget by placeholder text. */
150
70
  const findByPlaceholderText = builtinQueries.findByPlaceholderText;
151
- /**
152
- * Returns the single mapped widget with a matching display value, or null when none match. Widgets
153
- * that are not mapped are never matched. Throws when more than one matches.
154
- */
71
+ /** Queries one mapped widget by display value. */
155
72
  const queryByDisplayValue = builtinQueries.queryByDisplayValue;
156
- /**
157
- * Returns every mapped widget with a matching display value. Widgets that are not mapped are never
158
- * matched. Throws when none match.
159
- */
73
+ /** Gets all mapped widgets with a display value. */
160
74
  const getAllByDisplayValue = builtinQueries.getAllByDisplayValue;
161
- /**
162
- * Returns the single mapped widget with a matching display value. Widgets that are not mapped are
163
- * never matched. Throws when none or more than one matches.
164
- */
75
+ /** Gets one mapped widget by display value. */
165
76
  const getByDisplayValue = builtinQueries.getByDisplayValue;
166
- /**
167
- * Waits for and returns every mapped widget with a matching display value, retrying until at least
168
- * one appears or the timeout elapses. Widgets that are not mapped are never matched.
169
- */
77
+ /** Finds all mapped widgets with a display value. */
170
78
  const findAllByDisplayValue = builtinQueries.findAllByDisplayValue;
171
- /**
172
- * Waits for and returns the single mapped widget with a matching display value, retrying until it
173
- * appears or the timeout elapses. Widgets that are not mapped are never matched. Rejects when none
174
- * or more than one matches.
175
- */
79
+ /** Finds one mapped widget by display value. */
176
80
  const findByDisplayValue = builtinQueries.findByDisplayValue;
177
81
  const buildNormalizer = (options) => {
178
82
  const { normalizer, trim, collapseWhitespace } = options ?? {};