Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

docs: add an example of how to use "+" key as part of a shortcut (#29221)

Bruno Mańczak3e2d5b2800e3
diff --git a/docs/src/api/class-elementhandle.md b/docs/src/api/class-elementhandle.md
index 2ee1a77d4e..6d727f675a 100644
--- a/docs/src/api/class-elementhandle.md
+++ b/docs/src/api/class-elementhandle.md
@@ -699,7 +699,7 @@ Holding down `Shift` will type the text that corresponds to the [`param: key`] i
If [`param: key`] is a single character, it is case-sensitive, so the values `a` and `A` will generate different
respective texts.
-Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
+Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When specified with the
modifier, modifier is pressed and being held while the subsequent key is being pressed.
### param: ElementHandle.press.key
diff --git a/docs/src/api/class-frame.md b/docs/src/api/class-frame.md
index 336ba55bd3..8bf0530dda 100644
--- a/docs/src/api/class-frame.md
+++ b/docs/src/api/class-frame.md
@@ -1400,7 +1400,7 @@ Holding down `Shift` will type the text that corresponds to the [`param: key`] i
If [`param: key`] is a single character, it is case-sensitive, so the values `a` and `A` will generate different
respective texts.
-Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
+Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When specified with the
modifier, modifier is pressed and being held while the subsequent key is being pressed.
### param: Frame.press.selector = %%-input-selector-%%
diff --git a/docs/src/api/class-keyboard.md b/docs/src/api/class-keyboard.md
index 87ba51ec37..a37869df75 100644
--- a/docs/src/api/class-keyboard.md
+++ b/docs/src/api/class-keyboard.md
@@ -234,7 +234,7 @@ Holding down `Shift` will type the text that corresponds to the [`param: key`] i
If [`param: key`] is a single character, it is case-sensitive, so the values `a` and `A` will generate different
respective texts.
-Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
+Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When specified with the
modifier, modifier is pressed and being held while the subsequent key is being pressed.
**Usage**
diff --git a/docs/src/api/class-locator.md b/docs/src/api/class-locator.md
index f59e0f09f3..bea8507def 100644
--- a/docs/src/api/class-locator.md
+++ b/docs/src/api/class-locator.md
@@ -1720,7 +1720,7 @@ Holding down `Shift` will type the text that corresponds to the [`param: key`] i
If [`param: key`] is a single character, it is case-sensitive, so the values `a` and `A` will generate different
respective texts.
-Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
+Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When specified with the
modifier, modifier is pressed and being held while the subsequent key is being pressed.
### param: Locator.press.key
diff --git a/docs/src/api/class-page.md b/docs/src/api/class-page.md
index 3b9a6d42e2..4f4b444a0b 100644
--- a/docs/src/api/class-page.md
+++ b/docs/src/api/class-page.md
@@ -3009,7 +3009,7 @@ Holding down `Shift` will type the text that corresponds to the [`param: key`] i
If [`param: key`] is a single character, it is case-sensitive, so the values `a` and `A` will generate different
respective texts.
-Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
+Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When specified with the
modifier, modifier is pressed and being held while the subsequent key is being pressed.
**Usage**
diff --git a/packages/playwright-core/types/types.d.ts b/packages/playwright-core/types/types.d.ts
index e4a5f8d230..d2061f7857 100644
--- a/packages/playwright-core/types/types.d.ts
+++ b/packages/playwright-core/types/types.d.ts
@@ -3532,8 +3532,8 @@ export interface Page {
* If `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective
* texts.
*
- * Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
- * modifier, modifier is pressed and being held while the subsequent key is being pressed.
+ * Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When
+ * specified with the modifier, modifier is pressed and being held while the subsequent key is being pressed.
*
* **Usage**
*
@@ -6819,8 +6819,8 @@ export interface Frame {
* If `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective
* texts.
*
- * Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
- * modifier, modifier is pressed and being held while the subsequent key is being pressed.
+ * Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When
+ * specified with the modifier, modifier is pressed and being held while the subsequent key is being pressed.
* @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be
* used.
* @param key Name of the key to press or a character to generate, such as `ArrowLeft` or `a`.
@@ -10099,8 +10099,8 @@ export interface ElementHandle<T=Node> extends JSHandle<T> {
* If `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective
* texts.
*
- * Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
- * modifier, modifier is pressed and being held while the subsequent key is being pressed.
+ * Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When
+ * specified with the modifier, modifier is pressed and being held while the subsequent key is being pressed.
* @param key Name of the key to press or a character to generate, such as `ArrowLeft` or `a`.
* @param options
*/
@@ -12291,8 +12291,8 @@ export interface Locator {
* If `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective
* texts.
*
- * Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
- * modifier, modifier is pressed and being held while the subsequent key is being pressed.
+ * Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When
+ * specified with the modifier, modifier is pressed and being held while the subsequent key is being pressed.
* @param key Name of the key to press or a character to generate, such as `ArrowLeft` or `a`.
* @param options
*/
@@ -18116,8 +18116,8 @@ export interface Keyboard {
* If `key` is a single character, it is case-sensitive, so the values `a` and `A` will generate different respective
* texts.
*
- * Shortcuts such as `key: "Control+o"` or `key: "Control+Shift+T"` are supported as well. When specified with the
- * modifier, modifier is pressed and being held while the subsequent key is being pressed.
+ * Shortcuts such as `key: "Control+o"`, `key: "Control++` or `key: "Control+Shift+T"` are supported as well. When
+ * specified with the modifier, modifier is pressed and being held while the subsequent key is being pressed.
*
* **Usage**
*